Chris@0: {# Chris@0: /** Chris@0: * @file Chris@0: * Default theme implementation for status messages. Chris@0: * Chris@0: * Displays status, error, and warning messages, grouped by type. Chris@0: * Chris@0: * An invisible heading identifies the messages for assistive technology. Chris@0: * Sighted users see a colored box. See http://www.w3.org/TR/WCAG-TECHS/H69.html Chris@0: * for info. Chris@0: * Chris@0: * Add an ARIA label to the contentinfo area so that assistive technology Chris@0: * user agents will better describe this landmark. Chris@0: * Chris@0: * Available variables: Chris@0: * - message_list: List of messages to be displayed, grouped by type. Chris@0: * - status_headings: List of all status types. Chris@0: * - attributes: HTML attributes for the element, including: Chris@0: * - class: HTML classes. Chris@0: * Chris@0: * @ingroup themeable Chris@0: */ Chris@0: #} Chris@18:
Chris@0: {% for type, messages in message_list %} Chris@0:
Chris@0: {% if type == 'error' %} Chris@0:
Chris@0: {% endif %} Chris@18: {% if status_headings[type] %} Chris@18:

{{ status_headings[type] }}

Chris@18: {% endif %} Chris@18: {% if messages|length > 1 %} Chris@18:
    Chris@18: {% for message in messages %} Chris@18:
  • {{ message }}
  • Chris@18: {% endfor %} Chris@18:
Chris@18: {% else %} Chris@18: {{ messages|first }} Chris@18: {% endif %} Chris@0: {% if type == 'error' %} Chris@0:
Chris@0: {% endif %} Chris@0:
Chris@0: {% endfor %} Chris@18: