{# @description One outstanding document as a row of the list on the page that asks: its name, whether it is required, its version in force with a link to it, what changed since the reader last agreed to it, and the toggle that agrees to it. #} {# @prop document:object | description:"The outstanding document." #} {# @prop version:object | description:"Its version in force, the one the toggle agrees to and the link opens." #} {# @prop field:object | description:"The attributes of the toggle: name, value, id, and checked when it was on." #} {# @prop since:object | description:"The newest version of this document the reader accepted, offered for comparison with the one asked about; empty when they never accepted one." #} {# @prop optional:boolean | description:"The reader may continue without agreeing to this document." #} {# @prop changes:list | description:"The versions published since the one the reader last agreed to that carry a summary, newest first. Empty for a reader who never agreed to the document." #} {% load i18n %}
  • {# The growing column has to be the row's first child: the list sizes its columns by position, and that is what holds every toggle at the end of its row. #}
    {{ document.name }}
    {% if optional %} {% else %} {% endif %} {% blocktranslate with number=version.number %}Version {{ number }}{% endblocktranslate %}
    {% translate "View document in full" %} {% translate "(opens in a new tab)" %} {% if since %} {% translate "See what's changed" %} {% translate "(opens in a new tab)" %} {% endif %} {% if changes %}
    {% translate "What changed since you last agreed" %}
    {% for change in changes %}
    {% blocktranslate with number=change.number %}Version {{ number }}{% endblocktranslate %}
    {{ change.summary|linebreaksbr }}
    {% endfor %}
    {% endif %}