2020-09-29 06:54:54 +02:00
|
|
|
{% if include.params.article %}
|
|
|
|
{% assign article = include.params.article %}
|
2020-07-16 13:24:05 +02:00
|
|
|
{% endif %}
|
|
|
|
|
2021-01-11 04:18:35 +01:00
|
|
|
{% if include.params.lang %}
|
|
|
|
{% assign lang = include.params.lang %}
|
|
|
|
{% else %}
|
|
|
|
{% assign lang = lang | default: site.lang | default: "en" %}
|
|
|
|
{% endif %}
|
|
|
|
|
2020-09-29 06:54:54 +02:00
|
|
|
{% if include.params.speed %}
|
|
|
|
{% assign speed = include.params.speed %}
|
2020-07-16 13:24:05 +02:00
|
|
|
{% else %}
|
|
|
|
{% assign speed = 160 %}
|
|
|
|
{% endif %}
|
|
|
|
|
2021-01-11 11:34:51 +01:00
|
|
|
{%- include functions.html func='get_article_words' -%}
|
|
|
|
{% assign words = return %}
|
2021-01-11 04:18:35 +01:00
|
|
|
|
|
|
|
{% assign total_mins = words
|
2020-07-16 13:24:05 +02:00
|
|
|
| divided_by: speed
|
|
|
|
| at_least: 1 %}
|
|
|
|
|
|
|
|
{% assign hours = total_mins | divided_by: 60 %}
|
|
|
|
{% assign mins = total_mins | modulo: 60 %}
|
|
|
|
|
|
|
|
{% assign return = "About" %}
|
|
|
|
|
|
|
|
{% if hours > 0 %}
|
|
|
|
{% assign unit = "hour" %}
|
|
|
|
{% if hours > 1 %}
|
|
|
|
{% assign unit = unit | append: "s" %}
|
|
|
|
{% endif %}
|
|
|
|
{% assign return = return
|
|
|
|
| append: " "
|
|
|
|
| append: hours
|
|
|
|
| append: " "
|
|
|
|
| append: unit %}
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
{% assign unit = "min" %}
|
|
|
|
{% if mins > 1 %}
|
|
|
|
{% assign unit = unit | append: "s" %}
|
|
|
|
{% endif %}
|
|
|
|
{% assign return = return
|
|
|
|
| append: " "
|
|
|
|
| append: mins
|
|
|
|
| append: " "
|
|
|
|
| append: unit %}
|