diff options
Diffstat (limited to 'templates')
| -rw-r--r-- | templates/_checked_in.html.ep | 8 | ||||
| -rw-r--r-- | templates/_public_status_card.html.ep | 14 | ||||
| -rw-r--r-- | templates/_wagons.html.ep | 8 | ||||
| -rw-r--r-- | templates/account.html.ep | 37 | ||||
| -rw-r--r-- | templates/landingpage.html.ep | 4 | ||||
| -rw-r--r-- | templates/language.html.ep | 36 | ||||
| -rw-r--r-- | templates/layouts/default.html.ep | 14 | ||||
| -rw-r--r-- | templates/login.html.ep | 10 | ||||
| -rw-r--r-- | templates/register.html.ep | 18 | 
9 files changed, 97 insertions, 52 deletions
diff --git a/templates/_checked_in.html.ep b/templates/_checked_in.html.ep index e1cefe6..c798393 100644 --- a/templates/_checked_in.html.ep +++ b/templates/_checked_in.html.ep @@ -32,13 +32,13 @@  					% }  					% elsif (defined $journey->{arrival_countdown}) {  						% if ($journey->{arrival_countdown} > 60) { -							Ankunft in <%= journeys->min_to_human(int($journey->{arrival_countdown} / 60)) %> +							<%= L('status.arrival-in') %> <%= journeys->min_to_human(int($journey->{arrival_countdown} / 60)) %>  						% }  						% elsif ($journey->{arrival_countdown} > 0) { -							Ankunft in weniger als einer Minute +							%= L('status.arrival-soon')  						% }  						% else { -							Ziel erreicht +							%= L('status.arrived')  						% }  						% if ($journey->{arrival_countdown} < (60 * 15) and $journey->{arr_platform}) {  							% if ($journey->{arr_direction} and $journey->{arr_direction} eq 'r') { @@ -311,7 +311,7 @@  						data-url="<%= url_for('/status')->to_abs->scheme('https') %>/<%= $user->{name} %>/<%= $journey->{sched_departure}->epoch %>?token=<%= $journey->{dep_eva} %>-<%= $journey->{timestamp}->epoch % 337 %>"  					% }  					> -					<i class="material-icons left" aria-hidden="true">share</i> Teilen +					<i class="material-icons left" aria-hidden="true">share</i> <%= L('status.share') %>  				</a>  			% }  			% else { diff --git a/templates/_public_status_card.html.ep b/templates/_public_status_card.html.ep index 32b193a..73840b3 100644 --- a/templates/_public_status_card.html.ep +++ b/templates/_public_status_card.html.ep @@ -11,7 +11,7 @@  					<a href="/status/<%= $name %>"><%= $name %></a>: <%= include '_format_train', journey => $journey %>  				% }  				% else { -					<a href="/p/<%= $name %>"><%= $name %></a> ist unterwegs +					<a href="/p/<%= $name %>"><%= $name %></a> <%= L('status.is-checked-in') %>  				% }  				<i class="material-icons right"><%= visibility_icon($journey->{effective_visibility_str}) %></i>  				% if (not $journey->{extra_data}{rt}) { @@ -41,10 +41,10 @@  					% }  					% elsif (defined $journey->{arrival_countdown}) {  						% if ($journey->{arrival_countdown} > 60) { -							Ankunft in <%= journeys->min_to_human(int($journey->{arrival_countdown} / 60)) %> +							<%= L('status.arrival-in') %> <%= journeys->min_to_human(int($journey->{arrival_countdown} / 60)) %>  						% }  						% elsif ($journey->{arrival_countdown} > 0) { -							Ankunft in weniger als einer Minute +							%= L('status.arrival-soon')  						% }  						% else {  							Ziel erreicht @@ -54,7 +54,7 @@  						% }  					% }  					% elsif ($journey->{arr_name}) { -						Ankunft in mehr als zwei Stunden +						%= L('status.arrival-unknown')  					% }  				</div>  				<div class="progress" style="height: 1ex;"> @@ -216,14 +216,14 @@  				% }  				% else {  					<div class="wagons" style="margin-top: 2ex;"> -						Wagen:<br/> +						<%= L('status.carriages') %>:<br/>  						%= include '_wagons', wagongroups => $journey->{wagongroups};  					</div>  				% }  			% }  			% if (not stash('from_timeline')) {  				<div style="margin-top: 2ex;"> -					Route:<br/> +					<%= L('status.route') %>:<br/>  					% my $before = 1;  					% my $within = 0;  					% my $at_startstop = 0; @@ -280,7 +280,7 @@  				<span class="card-title">Aktuell nicht eingecheckt</span>  			% }  			% else { -				<span class="card-title"><a href="/p/<%= $name %>"><%= $name %></a> ist gerade nicht eingecheckt</span> +				<span class="card-title"><a href="/p/<%= $name %>"><%= $name %></a> <%= L('status.is-not-checked-in') %></span>  			% }  			<div>  			% if ($journey->{arr_name}) { diff --git a/templates/_wagons.html.ep b/templates/_wagons.html.ep index 4090f11..926aac1 100644 --- a/templates/_wagons.html.ep +++ b/templates/_wagons.html.ep @@ -7,12 +7,12 @@  	% elsif ($wagon_number and my $group_name = app->ice_name->{$wagon_number}) {  		„<%= $group_name %>“  	% } -	als <b><%= $wagongroup->{type} // $journey->{type} %> <%= $wagongroup->{no} %></b> +	<%= L('wagons.name-as-type') %> <b><%= $wagongroup->{type} // $journey->{type} %> <%= $wagongroup->{no} %></b>  	% if ($wagongroup->{from}) { -		von <b><%= $wagongroup->{from} %></b> +		<%= L('wagons.from') %> <b><%= $wagongroup->{from} %></b>  	% }  	% if ($wagongroup->{to}) { -		nach <b><%= $wagongroup->{to} %></b> +		<%= L('wagons.to') %> <b><%= $wagongroup->{to} %></b>  	% }  	<br/>  	% for my $wagon (@{$wagongroup->{wagons}}) { @@ -24,7 +24,7 @@  		% }  		%= $wagon->{type}  		% if ($wagon->{number}) { -			– Wagen <%= $wagon->{number} %> +			– <%= L('wagons.carriage') %> <%= $wagon->{number} %>  		% }  		<br/>  	% } diff --git a/templates/account.html.ep b/templates/account.html.ep index e4bf38d..837f219 100644 --- a/templates/account.html.ep +++ b/templates/account.html.ep @@ -16,6 +16,9 @@  					% elsif ($success eq 'password') {  						<span class="card-title">Passwort geändert</span>  					% } +					% elsif ($success eq 'language') { +						<span class="card-title">Sprache geändert</span> +					% }  					% elsif ($success eq 'privacy') {  						<span class="card-title">Einstellungen zu öffentlichen Account-Daten geändert</span>  					% } @@ -46,34 +49,38 @@  % my $use_history = users->use_history(uid => $acc->{id});  <div class="row">  	<div class="col s12"> -		<h2>Account</h2> +		<h2><%= L('account.account') %></h2>  		<table class="striped">  			<tr> -				<th scope="row">Name</th> +				<th scope="row"><%= L('account.name') %></th>  				<td><a href="/account/name"><i class="material-icons">edit</i></a><%= $acc->{name} %></td>  			</tr>  			<tr> -				<th scope="row">Mail</th> +				<th scope="row"><%= L('account.mail') %></th>  				<td><a href="/account/mail"><i class="material-icons">edit</i></a><%= $acc->{email} %></td>  			</tr>  			<tr> -				<th scope="row">Passwort</th> +				<th scope="row"><%= L('account.password') %></th>  				<td><a href="/account/password"><i class="material-icons">edit</i></a></td>  			</tr>  			<tr> -				<th scope="row">Verbindungen</th> +				<th scope="row"><%= L('account.language') %></th> +				<td><a href="/account/language"><i class="material-icons">edit</i></a><%= $acc->{languages}[0] // q{} %></td> +			</tr> +			<tr> +				<th scope="row"><%= L('account.connections') %></th>  				<td>  					<a href="/account/insight"><i class="material-icons">edit</i></a>  					% if ($use_history & 0x03) { -						Vorschläge aktiv +						%= L('account.connections.enabled')  					% }  					% else { -						<span style="color: #999999;">Vorschläge deaktiviert</span> +						<span style="color: #999999;"><%= L('account.connections.disabled') %></span>  					% }  				</td>  			</tr>  			<tr> -				<th scope="row">Sichtbarkeit</th> +				<th scope="row"><%= L('account.visibility') %></th>  				<td>  					<a href="/account/privacy"><i class="material-icons">edit</i></a>  					<i class="material-icons">check</i><i class="material-icons"><%= visibility_icon($acc->{default_visibility_str}) %></i> @@ -81,23 +88,23 @@  				</td>  			</tr>  			<tr> -				<th scope="row">Interaktion</th> +				<th scope="row"><%= L('account.interaction') %></th>  				<td>  					<a href="/account/social"><i class="material-icons">edit</i></a>  					% if ($acc->{accept_follows}) { -						<span>Accounts können dir direkt folgen</span> +						<span><%= L('account.interaction.accept-follows') %></span>  					% }  					% elsif ($acc->{accept_follow_requests}) { -						<span>Accounts können dir auf Anfrage folgen +						<span><%= L('account.interaction.accept-follow-requests') %>  						% if ($num_rx_follow_requests == 1) { -							– <a href="/account/social/follow-requests-received"><strong>eine</strong> offene Anfrage</a> +							– <a href="/account/social/follow-requests-received"><strong><%= L('account.interaction.one') %></strong> <%= L('account.interaction.open-request') %></a>  						% } elsif ($num_rx_follow_requests) { -							– <a href="/account/social/follow-requests-received"><strong><%= $num_rx_follow_requests %></strong> offene Anfragen</a> +							– <a href="/account/social/follow-requests-received"><strong><%= $num_rx_follow_requests %></strong> <%= L('account.interaction.open-requests') %></a>  						% }  						</span>  					% }  					% else { -						<span style="color: #999999;">Accounts können dir nicht folgen</span> +						<span style="color: #999999;"><%= L('account.interaction.disabled') %></span>  					% }  				</td>  			</tr> @@ -163,7 +170,7 @@  		%= form_for 'logout' => begin  			%= csrf_field  			<button class="btn waves-effect waves-light" type="submit" name="action" value="logout"> -				Abmelden +				%= L('button.logout')  			</button>  		%= end  	</div> diff --git a/templates/landingpage.html.ep b/templates/landingpage.html.ep index 5ca0e9e..9c2ccde 100644 --- a/templates/landingpage.html.ep +++ b/templates/landingpage.html.ep @@ -144,9 +144,9 @@  		</div>  		<div class="col s10 m10 l6 center-align">  			% if (not app->config->{registration}{disabled}) { -				<a href="/register" class="waves-effect waves-light btn"><i class="material-icons left" aria-hidden="true">add</i>Registrieren</a> +				<a href="/register" class="waves-effect waves-light btn"><i class="material-icons left" aria-hidden="true">add</i><%= L('button.register') %></a>  			% } -			<a href="/login" class="waves-effect waves-light btn"><i class="material-icons left" aria-hidden="true">account_circle</i>Anmelden</a> +			<a href="/login" class="waves-effect waves-light btn"><i class="material-icons left" aria-hidden="true">account_circle</i><%= L('button.login') %></a>  		</div>  		<div class="col s1 m1 l3">  		</div> diff --git a/templates/language.html.ep b/templates/language.html.ep new file mode 100644 index 0000000..75df054 --- /dev/null +++ b/templates/language.html.ep @@ -0,0 +1,36 @@ +<h1>Sprache</h1> +%= form_for '/account/language' => (method => 'POST') => begin +	%= csrf_field +	<div class="row"> +		<div class="input-field col s12"> +			<div> +				<label> +					%= radio_button language => 'de-DE' +					<span>de-DE: Deutsch (hochdeutsch)</span> +				</label> +			</div> +		</div> +	</div> +	<div class="row"> +		<div class="input-field col s12"> +			<div> +				<label> +					%= radio_button language => 'en-GB' +					<span>en-GB: English (Great Britain)</span> +				</label> +			</div> +		</div> +	</div> +	<div class="row"> +		<div class="col s3 m3 l3"> +		</div> +		<div class="col s6 m6 l6 center-align"> +			<button class="btn waves-effect waves-light" type="submit" name="action" value="save"> +				Speichern +				<i class="material-icons right">send</i> +			</button> +		</div> +		<div class="col s3 m3 l3"> +		</div> +	</div> +%= end diff --git a/templates/layouts/default.html.ep b/templates/layouts/default.html.ep index 2279789..ec3b5e0 100644 --- a/templates/layouts/default.html.ep +++ b/templates/layouts/default.html.ep @@ -131,21 +131,21 @@  		<div class="col s12 center-align grey-text">  			<a href="/about">travelynx</a> v<%= $version // '???' %>  			<span style="margin-left: 0.5em; margin-right: 0.5em;">–</span> -			<a href="/impressum">Impressum</a> +			<a href="/impressum"><%= L('footer.imprint') %></a>  			<span style="margin-left: 0.5em; margin-right: 0.5em;">–</span> -			<a href="/impressum">Datenschutz</a> +			<a href="/impressum"><%= L('footer.privacy') %></a>  			<span style="margin-left: 0.5em; margin-right: 0.5em;">–</span> -			<a href="/legend">Legende</a> +			<a href="/legend"><%= L('footer.legend') %></a>  		</div>  	</div>  	<div class="row">  		<div class="col s12 center-align grey-text config"> -			Farbschema: -			<a onClick="javascript:setTheme('light')">hell</a> +			<%= L('footer.colour-scheme') %>: +			<a onClick="javascript:setTheme('light')"><%= L('footer.colour-scheme.light') %></a>  			· -			<a onClick="javascript:setTheme('dark')">dunkel</a> +			<a onClick="javascript:setTheme('dark')"><%= L('footer.colour-scheme.dark') %></a>  			· -			<a onClick="javascript:setTheme('default')">automatisch</a> +			<a onClick="javascript:setTheme('default')"><%= L('footer.colour-scheme.auto') %></a>  		</div>  	</div>  </div> diff --git a/templates/login.html.ep b/templates/login.html.ep index 3a9cc1f..21f14d3 100644 --- a/templates/login.html.ep +++ b/templates/login.html.ep @@ -75,7 +75,9 @@  	</div>  	<div class="row">  		<div class="col s12 m12 l12"> -			Mit der Anmeldung stimmst du den <a href="/tos">Nutzungsbedingungen</a> zu. +			%= L('login.accept-tos-pre') +			<a href="/tos"><%= L('login.tos') %></a> +			%= L('login.accept-tos-post')  		</div>  	</div>  	<div class="row"> @@ -83,7 +85,7 @@  		</div>  		<div class="col s6 m6 l6 center-align">  			<button class="btn waves-effect waves-light" type="submit" name="action" value="login"> -				Anmelden +				%= L('button.login')  				<i class="material-icons right">send</i>  			</button>  		</div> @@ -95,7 +97,7 @@  		</div>  		<div class="col s6 m6 l6 center-align">  			<a href="/recover"> -				Passwort vergessen +				%= L('login.forgot-password')  			</a>  		</div>  		<div class="col s3 m3 l3"> @@ -104,7 +106,7 @@  	% if (app->config->{registration}{disabled}) {  	<div class="row" style="margin-top: 2em;">  		<div class="col s12 center-align"> -			<em>Diese Instanz erlaubt derzeit keine Registrierung neuer Accounts</em> +			<em><%= L('login.registration-disabled') %></em>  		</div>  	</div>  	% } diff --git a/templates/register.html.ep b/templates/register.html.ep index f9a486a..e7064da 100644 --- a/templates/register.html.ep +++ b/templates/register.html.ep @@ -8,27 +8,29 @@  		<div class="input-field col l6 m12 s12">  			<i class="material-icons prefix">account_circle</i>  			%= text_field 'user', id => 'account', class => 'validate', required => undef, pattern => '[0-9a-zA-Z_-]+', maxlength => 60, autocomplete => 'username' -			<label for="account">Name (alphanumerisch)</label> +			<label for="account"><%= L('register.name') %></label>  		</div>  		<div class="input-field col l6 m12 s12">  			<i class="material-icons prefix">email</i>  			%= email_field 'email', id => 'email', class => 'validate', required => undef, maxlength => 250 -			<label for="email">Mail-Adresse</label> +			<label for="email"><%= L('register.mail') %></label>  		</div>  		<div class="input-field col l6 m12 s12">  			<i class="material-icons prefix">lock</i>  			%= password_field 'password', id => 'password', class => 'validate', required => undef, minlength => 8, maxlength => 10000, autocomplete => 'new-password' -			<label for="password">Passwort</label> +			<label for="password"><%= L('register.password') %></label>  		</div>  		<div class="input-field col l6 m12 s12">  			<i class="material-icons prefix">lock</i>  			%= password_field 'password2', id => 'password2', class => 'validate', required => undef, minlength => 8, maxlength => 10000, autocomplete => 'new-password' -			<label for="password2">Passwort wiederholen</label> +			<label for="password2"><%= L('register.repeat-password') %></label>  		</div>  	</div>  	<div class="row">  		<div class="col s12 m12 l12"> -			Mit deiner Registrierung stimmst du den <a href="/tos">Nutzungsbedingungen</a> zu. +			%= L('register.accept-tos-pre') +			<a href="/tos"><%= L('register.tos') %></a> +			%= L('register.accept-tos-post')  		</div>  	</div>  	<div class="row"> @@ -36,7 +38,7 @@  		</div>  		<div class="col s6 m6 l6 center-align">  			<button class="btn waves-effect waves-light" type="submit" name="action" value="register"> -				Registrieren +				%= L('button.register')  				<i class="material-icons right">send</i>  			</button>  		</div> @@ -47,9 +49,7 @@  <div class="row">  	<div class="col s12">  		<p> -			Nach der Registrierung wird ein für 48 Stunden gültiger -			Bestätigungslink an die angegebene Mail-Adresse geschickt. Eine -			Anmeldung ist erst nach Bestätigung der Mail-Adresse möglich. +			%= L('register.expect-confirmation-link')  		</p>  		<p>  			Die Mail-Adresse wird ausschließlich zur Bestätigung der Anmeldung,  | 
