diff options
author | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2016-03-08 16:44:25 +0100 |
---|---|---|
committer | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2016-03-14 13:01:31 +0100 |
commit | bca5485946a72942c76dbb65c29e40818dca4976 (patch) | |
tree | 8788b0ae66e6561b256a26917a848e7f53b5cda9 /src/Wallabag/CoreBundle/Resources | |
parent | 17b3d026fd6262d48a038d90bacea44a9be339e0 (diff) | |
download | wallabag-bca5485946a72942c76dbb65c29e40818dca4976.tar.gz wallabag-bca5485946a72942c76dbb65c29e40818dca4976.tar.zst wallabag-bca5485946a72942c76dbb65c29e40818dca4976.zip |
Added setting to have a personal reading time
Diffstat (limited to 'src/Wallabag/CoreBundle/Resources')
-rw-r--r-- | src/Wallabag/CoreBundle/Resources/views/themes/material/Config/index.html.twig | 8 | ||||
-rw-r--r-- | src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig | 5 |
2 files changed, 11 insertions, 2 deletions
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Config/index.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Config/index.html.twig index e388f2c8..31931ca2 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Config/index.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Config/index.html.twig | |||
@@ -44,6 +44,14 @@ | |||
44 | 44 | ||
45 | <div class="row"> | 45 | <div class="row"> |
46 | <div class="input-field col s12"> | 46 | <div class="input-field col s12"> |
47 | {{ form_label(form.config.reading_speed) }} | ||
48 | {{ form_errors(form.config.reading_speed) }} | ||
49 | {{ form_widget(form.config.reading_speed) }} | ||
50 | </div> | ||
51 | </div> | ||
52 | |||
53 | <div class="row"> | ||
54 | <div class="input-field col s12"> | ||
47 | {{ form_label(form.config.language) }} | 55 | {{ form_label(form.config.language) }} |
48 | {{ form_errors(form.config.language) }} | 56 | {{ form_errors(form.config.language) }} |
49 | {{ form_widget(form.config.language) }} | 57 | {{ form_widget(form.config.language) }} |
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig index c3fd4d28..371992df 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig | |||
@@ -50,8 +50,9 @@ | |||
50 | 50 | ||
51 | <div class="estimatedTime grey-text"> | 51 | <div class="estimatedTime grey-text"> |
52 | <span class="tool reading-time"> | 52 | <span class="tool reading-time"> |
53 | {% if entry.readingTime > 0 %} | 53 | {% set readingTime = entry.readingTime / app.user.config.readingSpeed %} |
54 | {% trans with {'%readingTime%': entry.readingTime } %}estimated reading time: %readingTime% min{% endtrans %} | 54 | {% if readingTime > 0 %} |
55 | {% trans with {'%readingTime%': readingTime } %}estimated reading time: %readingTime% min{% endtrans %} | ||
55 | {% else %} | 56 | {% else %} |
56 | {% trans with {'%inferior%': '<small class="inferieur"><</small>'} %}estimated reading time: %inferior% 1 min{% endtrans %} | 57 | {% trans with {'%inferior%': '<small class="inferieur"><</small>'} %}estimated reading time: %inferior% 1 min{% endtrans %} |
57 | {% endif %} | 58 | {% endif %} |