{% macro print_readout_body(readout, locale=None, max_rows=10, product=None) %} {% if not readout.hide_readout %} {% if readout.description %}

{{ readout.description }}

{% endif %} {{ readout.render(max_rows=max_rows)|safe }}
{% endif %} {% endmacro %} {% macro print_readout(readout, locale=None, max_rows=10, product=None) %} {% if not readout.hide_readout %}
{{ readout.title }} {{ print_readout_body(readout, locale, max_rows, product) }}
{% endif %} {% endmacro %} {% macro overview_section(readouts, printed_rows) %} {# printed_rows is a tuple of pairs, (row, should_color), like so: ((row1, True/False), (row2, True/False), ... etc) #}
{{ _('Overview') }} {% for row, should_color in printed_rows %} {% if row.title == _('Top 100 Articles') %} {% else %} {% endif %} {% endfor %}
{{ row.title }}
{{ row.description }}
{% trans numerator=number(row.numerator), denominator=number(row.denominator) %} {{ numerator }} of {{ denominator }} {% endtrans %} {{ row.percent }}%
{{ row.title }}
{{ row.description }}
{% trans numerator=number(row.numerator), denominator=number(row.denominator) %} {{ numerator }} of {{ denominator }} {% endtrans %} {{ row.percent }}%
{{ _('User Interface') }}
{% trans url=_('https://pontoon.mozilla.org/projects/sumo/', context='L10n: Link to a site with information on how to translate the UI into your language.') %} A fully translated user interface improves the experience for site visitors in your language. Help translate the interface. {% endtrans %}
{% endmacro %} {% macro print_checkbox_row(label, on_default_locale, is_watching_default, is_watching_other, watch_view, unwatch_view, default_locale, show_default=True, show_other=True, product=None) %} {{ label }} {% if show_default %} {% if product %} {% set watch_url = url(watch_view, locale=default_locale, product=product.slug) %} {% set unwatch_url = url(unwatch_view, locale=default_locale, product=product.slug) %} {% else %} {% set watch_url = url(watch_view, locale=default_locale) %} {% set unwatch_url = url(unwatch_view, locale=default_locale) %} {% endif %} {% endif %} {% if not on_default_locale and show_other %} {% if product %} {% set watch_url = url(watch_view, product=product.slug) %} {% set unwatch_url = url(unwatch_view, product=product.slug) %} {% else %} {% set watch_url = url(watch_view) %} {% set unwatch_url = url(unwatch_view) %} {% endif %} {% endif %} {% endmacro %} {% macro print_subscription_menu(default_locale_name, current_locale_name, on_default_locale, is_watching_default_locale, is_watching_other_locale, is_watching_default_approved, is_watching_other_approved, default_locale, show_default_waiting=True, show_default_approved=True, product=None) %}
{% csrf_token %} {% if not on_default_locale %} {% endif %} {{ print_checkbox_row(_('Waiting for review'), on_default_locale, is_watching_default_locale, is_watching_other_locale, 'wiki.locale_watch', 'wiki.locale_unwatch', default_locale, show_default=show_default_waiting, product=product) }} {{ print_checkbox_row(_('Approved'), on_default_locale, is_watching_default_approved, is_watching_other_approved, 'wiki.approved_watch', 'wiki.approved_unwatch', default_locale, show_default=show_default_approved, product=product) }} {{ print_checkbox_row(_('Ready for localization'), on_default_locale, is_watching_default_ready, False, 'wiki.ready_watch', 'wiki.ready_unwatch', default_locale, show_other=False, product=product) }}
{{ _(default_locale_name) }}{{ current_locale_name }}

{% if product %} {{ _('Please note that these selections are specific to the current product selected.') }} {% else %} {{ _('Please note that you will be subscribed to these notifications for all products. If you are only interested in specific products, please go to the dashboard for that product.') }} {% endif %}

{% endmacro %} {% macro product_selector(products, current) %}
{% endmacro %} {% macro product_choice_list(products, current, url_) %} {% endmacro %} {% macro topic_selector(topics, current) %}
{% endmacro %} {% macro category_filter() %}
{% if product %} {% endif %}
{% endmacro %} {% macro localization_sidebar_nav(locale, active, is_default_locale=False) %} {% endmacro %}