Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make criticalmass.in translateable #40

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions templates/Track/draw.html.twig
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% extends 'Template/StandardTemplate.html.twig' %}

{% block title %}Deine Tracks{% endblock %}
{% block title %}{{ 'track.draw_page.title'|trans }}{% endblock %}

{% block breadcrumb %}
<li>
Expand Down Expand Up @@ -33,7 +33,7 @@
<input type="hidden" id="geojson" name="geojson"/>

<button type="submit" id="save-track" class="btn btn-default">
Speichern
{{ 'track.draw_page.form.submit.caption'|trans }}
</button>
</form>
</div>
Expand Down
2 changes: 1 addition & 1 deletion templates/Track/list.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</li>

<li class="active">
Deine Tracks

</li>
{% endblock %}

Expand Down
14 changes: 4 additions & 10 deletions templates/Track/range.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -25,20 +25,14 @@
<div class="row">
<div class="col-md-12">
<h2>
Track beschneiden
{{ 'track.range_page.title'|trans }}
</h2>
</div>
</div>

<div class="row">
<div class="col-md-12">
<p>Weniger ist manchmal mehr. Hier kannst du Anfang und Ende deiner Tour festlegen, falls du
versehentlich zu viel aufgezeichnet hast und nicht möchtest, dass dir jemand nach Hause folgt.</p>

<p>
Das Beschneiden beschädigt deinen Track nicht, du kannst den für andere Nutzer sichtbaren Bereich
jederzeit wieder ändern.
</p>
<p>{{ 'track.range_page.intro'|trans }}</p>
</div>
</div>

Expand All @@ -59,10 +53,10 @@
{{ form_start(form) }}
<div class="btn-group pull-right" role="group" aria-label="...">
<button class="btn btn-success" type="submit">
Speichern
{{ 'track.range_page.form.submit'|trans }}
</button>
<a class="btn btn-default" href="{{ path('caldera_criticalmass_track_list') }}">
Abbrechen
{{ 'track.range_page.form.cancel'|trans }}
</a>
</div>
{{ form_end(form) }}
Expand Down
24 changes: 12 additions & 12 deletions templates/Track/view.html.twig
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% extends 'Template/StandardTemplate.html.twig' %}

{% block title %}Deine Tracks{% endblock %}
{% block title %}{{ 'track.view_page.title'|trans }}{% endblock %}

{% block breadcrumb %}
<li>
Expand Down Expand Up @@ -70,7 +70,7 @@
<div class="col-md-3">
<dl>
<dt>
Tour:
{{ 'track.properties.ride'|trans }}
</dt>
<dd>
<a href="{{ objectPath(track.ride) }}">
Expand All @@ -83,7 +83,7 @@
<div class="col-md-2">
<dl>
<dt>
Datum:
{{ 'track.properties.date'|trans }}
</dt>
<dd>
{{ track.ride.dateTime|date('d.m.Y H:i', track.ride.city.timezone) }}&nbsp;Uhr
Expand All @@ -94,13 +94,13 @@
<div class="col-md-3">
<dl>
<dt>
Treffpunkt:
{{ 'track.properties.ride_location'|trans }}
</dt>
<dd>
{% if track.ride.location and track.ride.latitude and track.ride.longitude %}
{{ track.ride.location }}
{% else %}
nicht bekannt
{{ 'track.properties.ride_location_unknown'|trans }}
{% endif %}
</dd>
</dl>
Expand All @@ -109,18 +109,18 @@
<div class="col-md-2">
<dl>
<dt>
Distanz:
{{ 'track.properties.distance'|trans }}
</dt>
<dd>
{{ track.distance|round(2) }}&nbsp;Kilometer
{{ track.distance|round(2) }}&nbsp;km
</dd>
</dl>
</div>

<div class="col-md-2">
<dl>
<dt>
Dauer:
{{ 'track.properties.durantion'|trans }}
</dt>
<dd>
{{ human_duration(track.getDurationInSeconds()) }}
Expand All @@ -137,24 +137,24 @@
{% if previous_track %}
<li class="previous">
<a href="{{ objectPath(previous_track) }}">
&larr; Voriger Track
&larr; {{ 'track.previous'|trans }}
</a>
</li>
{% else %}
<li class="previous disabled">
<a href="#">&larr; Voriger Track</a>
<a href="#">&larr; {{ 'track.previous'|trans }}</a>
</li>
{% endif %}

{% if next_track %}
<li class="next">
<a href="{{ objectPath(next_track) }}">
Nächster Track &rarr;
{{ 'track.next'|trans }} &rarr;
</a>
</li>
{% else %}
<li class="next disabled">
<a href="#">Nächster Track &rarr;</a>
<a href="#">{{ 'track.next'|trans }} &rarr;</a>
</li>
{% endif %}
</ul>
Expand Down
25 changes: 25 additions & 0 deletions translations/messages.de.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,3 +92,28 @@ hint_modal:
post_add_button:
title: Kommentar verfassen
text: '<p>Gefällt dir dieses Foto? Hast du etwas lustiges während der Tour erlebt? Mit einem criticalmass.in-Benutzerkonto kannst du an dieser Stelle einen Kommentar verfassen.</p>'

track:
draw_page:
title: Track zeichnen
form:
submit:
caption: Speichern
view_page:
title: Track anzeigen

list_page:
title: Deine Tracks

range_page:
title: Track beschneiden
intro: Weniger ist manchmal mehr. Hier kannst du Anfang und Ende deiner Tour festlegen, falls du versehentlich zu viel aufgezeichnet hast und nicht möchtest, dass dir jemand nach Hause folgt.
form:
submit: Speichern
cancel: Abbrechen

properties:
ride: Tour
date: Datum
ride_location: Treffpunkt
ride_location_unknown: unbekannt