translate estimated time minutes

This commit is contained in:
Thomas Citharel 2016-02-18 01:36:02 +01:00
parent 93d0aa40bb
commit f37c9c3348
3 changed files with 17 additions and 5 deletions

View file

@ -88,7 +88,8 @@ Rule: "Règle"
FAQ: "FAQ"
# Entries
'estimated reading time': 'durée de lecture'
"estimated reading time: %readingTime% min": "durée de lecture : %readingTime% min"
"estimated reading time: %inferior% 1 min": "durée de lecture : %inferior% 1 min"
original: "original"
Toggle mark as read: 'Marquer comme lu/non lu'
Toggle favorite: 'Marquer comme favori'

View file

@ -27,9 +27,17 @@
<div id="entry-{{ entry.id|e }}" class="entry">
<h2><a href="{{ path('view', { 'id': entry.id }) }}">{{ entry.title|raw }}</a></h2>
{% if entry.readingTime > 0 %}
<div class="estimatedTime"><span class="tool reading-time">{% trans %}estimated reading time :{% endtrans %} {{ entry.readingTime }} min</span></div>
<div class="estimatedTime">
<span class="tool reading-time">
{% trans with {'%readingTime%': entry.readingTime } %}estimated reading time: %readingTime% min{% endtrans %}
</span>
</div>
{% else %}
<div class="estimatedTime"><span class="tool reading-time">{% trans %}estimated reading time :{% endtrans %} <small class="inferieur">&lt;</small> 1 min</span></div>
<div class="estimatedTime">
<span class="tool reading-time">
{% trans with {'%inferior%': '<small class="inferieur">&lt;</small>'} %}estimated reading time: %inferior% 1 min{% endtrans %}
</span>
</div>
{% endif %}
<ul class="tools links">

View file

@ -50,8 +50,11 @@
<div class="estimatedTime grey-text">
<span class="tool reading-time">
{% trans %}estimated reading time{% endtrans %}:
{% if entry.readingTime > 0 %}{{ entry.readingTime }}{% else %}<small class="inferieur">&lt;</small> 1{% endif %} min
{% if entry.readingTime > 0 %}
{% trans with {'%readingTime%': entry.readingTime } %}estimated reading time: %readingTime% min{% endtrans %}
{% else %}
{% trans with {'%inferior%': '<small class="inferieur">&lt;</small>'} %}estimated reading time: %inferior% 1 min{% endtrans %}
{% endif %}
</span>
</div>