Chris@0
|
1 {#
|
Chris@0
|
2 /**
|
Chris@0
|
3 * @file
|
Chris@0
|
4 * Theme override to display node links.
|
Chris@0
|
5 *
|
Chris@0
|
6 * Available variables:
|
Chris@0
|
7 * - attributes: Attributes for the UL containing the list of links.
|
Chris@0
|
8 * - links: Links to be output.
|
Chris@0
|
9 * Each link will have the following elements:
|
Chris@0
|
10 * - title: The link text.
|
Chris@0
|
11 * - href: The link URL. If omitted, the 'title' is shown as a plain text
|
Chris@0
|
12 * item in the links list. If 'href' is supplied, the entire link is passed
|
Chris@0
|
13 * to l() as its $options parameter.
|
Chris@0
|
14 * - attributes: (optional) HTML attributes for the anchor, or for the <span>
|
Chris@0
|
15 * tag if no 'href' is supplied.
|
Chris@0
|
16 * - heading: (optional) A heading to precede the links.
|
Chris@0
|
17 * - text: The heading text.
|
Chris@0
|
18 * - level: The heading level (e.g. 'h2', 'h3').
|
Chris@0
|
19 * - attributes: (optional) A keyed list of attributes for the heading.
|
Chris@0
|
20 * If the heading is a string, it will be used as the text of the heading and
|
Chris@0
|
21 * the level will default to 'h2'.
|
Chris@0
|
22 *
|
Chris@0
|
23 * Headings should be used on navigation menus and any list of links that
|
Chris@0
|
24 * consistently appears on multiple pages. To make the heading invisible use
|
Chris@0
|
25 * the 'visually-hidden' CSS class. Do not use 'display:none', which
|
Chris@0
|
26 * removes it from screen readers and assistive technology. Headings allow
|
Chris@0
|
27 * screen reader and keyboard only users to navigate to or skip the links.
|
Chris@0
|
28 * See http://juicystudio.com/article/screen-readers-display-none.php and
|
Chris@0
|
29 * http://www.w3.org/TR/WCAG-TECHS/H42.html for more information.
|
Chris@0
|
30 *
|
Chris@0
|
31 * @see template_preprocess_links()
|
Chris@0
|
32 *
|
Chris@0
|
33 * @ingroup themeable
|
Chris@0
|
34 */
|
Chris@0
|
35 #}
|
Chris@0
|
36 {% if links %}
|
Chris@0
|
37 <div class="node__links">
|
Chris@0
|
38 {% include "links.html.twig" %}
|
Chris@0
|
39 </div>
|
Chris@0
|
40 {% endif %}
|