annotate core/modules/system/templates/time.html.twig @ 19:fa3358dc1485 tip

Add ndrum files
author Chris Cannam
date Wed, 28 Aug 2019 13:14:47 +0100
parents af1871eacc83
children
rev   line source
Chris@0 1 {#
Chris@0 2 /**
Chris@0 3 * @file
Chris@0 4 * Default theme implementation for a date / time element.
Chris@0 5 *
Chris@0 6 * Available variables
Chris@0 7 * - timestamp: (optional) A UNIX timestamp for the datetime attribute. If the
Chris@0 8 * datetime cannot be represented as a UNIX timestamp, use a valid datetime
Chris@0 9 * attribute value in attributes.datetime.
Chris@0 10 * - text: (optional) The content to display within the <time> element.
Chris@0 11 * Defaults to a human-readable representation of the timestamp value or the
Chris@18 12 * datetime attribute value using DateFormatter::format().
Chris@0 13 * - attributes: (optional) HTML attributes to apply to the <time> element.
Chris@0 14 * A datetime attribute in 'attributes' overrides the 'timestamp'. To
Chris@0 15 * create a valid datetime attribute value from a UNIX timestamp, use
Chris@18 16 * DateFormatter::format() with one of the predefined 'html_*' formats.
Chris@0 17 *
Chris@0 18 * @see template_preprocess_time()
Chris@0 19 * @see http://www.w3.org/TR/html5-author/the-time-element.html#attr-time-datetime
Chris@0 20 */
Chris@0 21 #}
Chris@0 22 <time{{ attributes }}>{{ text }}</time>