Move into nested docroot

This commit is contained in:
Rob Davies 2017-02-13 15:31:17 +00:00
parent 83a0d3a149
commit c8b70abde9
13405 changed files with 0 additions and 0 deletions

View file

@ -0,0 +1,34 @@
{#
/**
* @file
* Default theme implementation for the content of an administrative block.
*
* Available variables:
* - content: A list containing information about the block. Each element
* of the array represents an administrative menu item, and must at least
* contain the keys 'title', 'link_path', and 'localized_options', which are
* passed to l(). A 'description' key may also be provided.
* - attributes: HTML attributes to be added to the element.
* - compact: Boolean indicating whether compact mode is turned on or not.
*
* @see template_preprocess_admin_block_content()
*
* @ingroup themeable
*/
#}
{%
set classes = [
'list-group',
compact ? 'compact',
]
%}
{% if content %}
<dl{{ attributes.addClass(classes) }}>
{% for item in content %}
<dt class="list-group__link">{{ item.link }}</dt>
{% if item.description %}
<dd class="list-group__description">{{ item.description }}</dd>
{% endif %}
{% endfor %}
</dl>
{% endif %}

View file

@ -0,0 +1,26 @@
{#
/**
* @file
* Default theme implementation for an administrative block.
*
* Available variables:
* - block: An array of information about the block, including:
* - show: A flag indicating if the block should be displayed.
* - title: The block title.
* - content: (optional) The content of the block.
* - description: (optional) A description of the block.
* (Description should only be output if content is not available).
*
* @ingroup themeable
*/
#}
<div class="panel">
{% if block.title %}
<h3 class="panel__title">{{ block.title }}</h3>
{% endif %}
{% if block.content %}
<div class="panel__content">{{ block.content }}</div>
{% elseif block.description %}
<div class="panel__description">{{ block.description }}</div>
{% endif %}
</div>

View file

@ -0,0 +1,27 @@
{#
/**
* @file
* Default theme implementation for an administrative page.
*
* Available variables:
* - system_compact_link: Themed link to toggle compact view.
* - containers: An list of administrative blocks keyed by position: left or
* right. Contains:
* - blocks: A list of blocks within a container.
*
* @see template_preprocess_admin_page()
*
* @ingroup themeable
*/
#}
<div class="clearfix">
{{ system_compact_link }}
{% for container in containers %}
<div class="layout-column layout-column--half">
{% for block in container.blocks %}
{{ block }}
{% endfor %}
</div>
{% endfor %}
</div>

View file

@ -0,0 +1,23 @@
{#
/**
* @file
* Default theme implementation for authorize.php operation report templates.
*
* This report displays the results of an operation run via authorize.php.
*
* Available variables:
* - messages: A list of result messages.
* - attributes: HTML attributes for the element.
*
* @see template_preprocess_authorize_report()
*
* @ingroup themeable
*/
#}
{% if messages %}
<div{{ attributes.addClass('authorize-results') }}>
{% for message_group in messages %}
{{ message_group }}
{% endfor %}
</div>
{% endif %}

View file

@ -0,0 +1,12 @@
{% extends "block.html.twig" %}
{#
/**
* @file
* Theme override for local actions (primary admin actions.)
*/
#}
{% block content %}
{% if content %}
<nav>{{ content }}</nav>
{% endif %}
{% endblock %}

View file

@ -0,0 +1,28 @@
{% extends "block.html.twig" %}
{#
/**
* @file
* Default theme implementation for a branding block.
*
* Each branding element variable (logo, name, slogan) is only available if
* enabled in the block configuration.
*
* Available variables:
* - site_logo: Logo for site as defined in Appearance or theme settings.
* - site_name: Name for site as defined in Site information settings.
* - site_slogan: Slogan for site as defined in Site information settings.
*
* @ingroup themeable
*/
#}
{% block content %}
{% if site_logo %}
<a href="{{ path('<front>') }}" title="{{ 'Home'|t }}" rel="home">
<img src="{{ site_logo }}" alt="{{ 'Home'|t }}" />
</a>
{% endif %}
{% if site_name %}
<a href="{{ path('<front>') }}" title="{{ 'Home'|t }}" rel="home">{{ site_name }}</a>
{% endif %}
{{ site_slogan }}
{% endblock %}

View file

@ -0,0 +1,50 @@
{#
/**
* @file
* Default theme implementation for a menu block.
*
* Available variables:
* - plugin_id: The ID of the block implementation.
* - label: The configured label of the block if visible.
* - configuration: A list of the block's configuration values.
* - label: The configured label for the block.
* - label_display: The display settings for the label.
* - provider: The module or other provider that provided this block plugin.
* - Block plugin specific settings will also be stored here.
* - content: The content of this block.
* - attributes: HTML attributes for the containing element.
* - id: A valid HTML ID and guaranteed unique.
* - title_attributes: HTML attributes for the title element.
* - content_attributes: HTML attributes for the content element.
* - title_prefix: Additional output populated by modules, intended to be
* displayed in front of the main title tag that appears in the template.
* - title_suffix: Additional output populated by modules, intended to be
* displayed after the main title tag that appears in the template.
*
* Headings should be used on navigation menus that consistently appear on
* multiple pages. When this menu block's label is configured to not be
* displayed, it is automatically made invisible using the 'visually-hidden' CSS
* class, which still keeps it visible for screen-readers and assistive
* technology. Headings allow screen-reader and keyboard only users to navigate
* to or skip the links.
* See http://juicystudio.com/article/screen-readers-display-none.php and
* http://www.w3.org/TR/WCAG-TECHS/H42.html for more information.
*
* @ingroup themeable
*/
#}
{% set heading_id = attributes.id ~ '-menu'|clean_id %}
<nav role="navigation" aria-labelledby="{{ heading_id }}"{{ attributes|without('role', 'aria-labelledby') }}>
{# Label. If not displayed, we still provide it for screen readers. #}
{% if not configuration.label_display %}
{% set title_attributes = title_attributes.addClass('visually-hidden') %}
{% endif %}
{{ title_prefix }}
<h2{{ title_attributes.setAttribute('id', heading_id) }}>{{ configuration.label }}</h2>
{{ title_suffix }}
{# Menu. #}
{% block content %}
{{ content }}
{% endblock %}
</nav>

View file

@ -0,0 +1,15 @@
{#
/**
* @file
* Default theme implementation for the messages block.
*
* Removes wrapper elements from block so that empty block does not appear when
* there are no messages.
*
* Available variables:
* - content: The content of this block.
*
* @ingroup themeable
*/
#}
{{ content }}

View file

@ -0,0 +1,27 @@
{#
/**
* @file
* Default theme implementation for a breadcrumb trail.
*
* Available variables:
* - breadcrumb: Breadcrumb trail items.
*
* @ingroup themeable
*/
#}
{% if breadcrumb %}
<nav role="navigation" aria-labelledby="system-breadcrumb">
<h2 id="system-breadcrumb" class="visually-hidden">{{ 'Breadcrumb'|t }}</h2>
<ol>
{% for item in breadcrumb %}
<li>
{% if item.url %}
<a href="{{ item.url }}">{{ item.text }}</a>
{% else %}
{{ item.text }}
{% endif %}
</li>
{% endfor %}
</ol>
</nav>
{% endif %}

View file

@ -0,0 +1,17 @@
{#
/**
* @file
* Default theme implementation for a 'checkboxes' #type form element.
*
* Available variables
* - attributes: A list of HTML attributes for the wrapper element.
* - children: The rendered checkboxes.
*
* @see template_preprocess_checkboxes()
*
* @ingroup themeable
*/
@todo: remove this file once https://www.drupal.org/node/1819284 is resolved.
This is identical to core/modules/system/templates/container.html.twig
#}
<div{{ attributes.addClass('form-checkboxes') }}>{{ children }}</div>

View file

@ -0,0 +1,15 @@
{#
/**
* @file
* Default theme implementation for confirm form.
*
* By default this does not alter the appearance of a form at all,
* but is provided as a convenience for themers.
*
* Available variables:
* - form: The confirm form.
*
* @ingroup themeable
*/
#}
{{ form }}

View file

@ -0,0 +1,30 @@
{#
/**
* @file
* Default theme implementation of a container used to wrap child elements.
*
* Used for grouped form items. Can also be used as a theme wrapper for any
* renderable element, to surround it with a <div> and HTML attributes.
* See \Drupal\Core\Render\Element\RenderElement for more
* information on the #theme_wrappers render array property, and
* \Drupal\Core\Render\Element\container for usage of the container render
* element.
*
* Available variables:
* - attributes: HTML attributes for the containing element.
* - children: The rendered child elements of the container.
* - has_parent: A flag to indicate that the container has one or more parent
containers.
*
* @see template_preprocess_container()
*
* @ingroup themeable
*/
#}
{%
set classes = [
has_parent ? 'js-form-wrapper',
has_parent ? 'form-wrapper',
]
%}
<div{{ attributes.addClass(classes) }}>{{ children }}</div>

View file

@ -0,0 +1,17 @@
{#
/**
* @file
* Default theme implementation of a datetime form element.
*
* Available variables:
* - attributes: HTML attributes for the datetime form element.
* - content: The datelist form element to be output.
*
* @see template_preprocess_datetime_form()
*
* @ingroup themeable
*/
#}
<div{{ attributes }}>
{{ content }}
</div>

View file

@ -0,0 +1,33 @@
{#
/**
* @file
* Default theme implementation of a datetime form wrapper.
*
* Available variables:
* - content: The form element to be output, usually a datelist, or datetime.
* - title: The title of the form element.
* - title_attributes: HTML attributes for the title wrapper.
* - description: Description text for the form element.
* - required: An indicator for whether the associated form element is required.
*
* @see template_preprocess_datetime_wrapper()
*
* @ingroup themeable
*/
#}
{%
set title_classes = [
required ? 'js-form-required',
required ? 'form-required',
]
%}
{% if title %}
<h4{{ title_attributes.addClass(title_classes) }}>{{ title }}</h4>
{% endif %}
{{ content }}
{% if errors %}
<div>
{{ errors }}
</div>
{% endif %}
{{ description }}

View file

@ -0,0 +1,39 @@
{#
/**
* @file
* Default theme implementation for a details element.
*
* Available variables
* - attributes: A list of HTML attributes for the details element.
* - errors: (optional) Any errors for this details element, may not be set.
* - title: (optional) The title of the element, may not be set.
* - description: (optional) The description of the element, may not be set.
* - children: (optional) The children of the element, may not be set.
* - value: (optional) The value of the element, may not be set.
*
* @see template_preprocess_details()
*
* @ingroup themeable
*/
#}
<details{{ attributes }}>
{%
set summary_classes = [
required ? 'js-form-required',
required ? 'form-required',
]
%}
{%- if title -%}
<summary{{ summary_attributes.addClass(summary_classes) }}>{{ title }}</summary>
{%- endif -%}
{% if errors %}
<div>
{{ errors }}
</div>
{% endif %}
{{ description }}
{{ children }}
{{ value }}
</details>

View file

@ -0,0 +1,22 @@
{#
/**
* @file
* Default theme implementation for a dropbutton wrapper.
*
* Available variables:
* - children: Contains the child elements of the dropbutton menu.
*
* @see template_preprocess()
*
* @ingroup themeable
*/
#}
{% if children %}
{% spaceless %}
<div class="dropbutton-wrapper">
<div class="dropbutton-widget">
{{ children }}
</div>
</div>
{% endspaceless %}
{% endif %}

View file

@ -0,0 +1,30 @@
{#
/**
* @file
* Default theme implementation to present a list of available bundles.
*
* Available variables:
* - bundles: A list of bundles, each with the following properties:
* - label: Bundle label.
* - description: Bundle description.
* - add_link: Link to create an entity of this bundle.
* - add_bundle_message: The message shown when there are no bundles. Only
* available if the entity type uses bundle entities.
*
* @see template_preprocess_entity_add_list()
*
* @ingroup themeable
*/
#}
{% if bundles is not empty %}
<dl>
{% for bundle in bundles %}
<dt>{{ bundle.add_link }}</dt>
<dd>{{ bundle.description }}</dd>
{% endfor %}
</dl>
{% elseif add_bundle_message is not empty %}
<p>
{{ add_bundle_message }}
</p>
{% endif %}

View file

@ -0,0 +1,17 @@
{#
/**
* @file
* Default theme implementation for a feed icon.
*
* Available variables:
* - url: An internal system path or a fully qualified external URL of the feed.
* - attributes: Remaining HTML attributes for the feed link.
* - title: A descriptive title of the feed link.
* - class: HTML classes to be applied to the feed link.
*
* @ingroup themeable
*/
#}
<a href="{{ url }}"{{ attributes.addClass('feed-icon') }}>
{{ 'Subscribe to @title'|t({'@title': title}) }}
</a>

View file

@ -0,0 +1,38 @@
{#
/**
* @file
* Default theme implementation for an individual form element.
*
* Available variables for all fields:
* - multiple: Whether there are multiple instances of the field.
*
* Available variables for single cardinality fields:
* - elements: Form elements to be rendered.
*
* Available variables when there are multiple fields.
* - table: Table of field items.
* - description: The description element containing the following properties:
* - content: The description content of the form element.
* - attributes: HTML attributes to apply to the description container.
* - button: "Add another item" button.
*
* @see template_preprocess_field_multiple_value_form()
*
* @ingroup themeable
*/
#}
{% if multiple %}
<div class="js-form-item form-item">
{{ table }}
{% if description.content %}
<div{{ description.attributes.addClass('description') }} >{{ description.content }}</div>
{% endif %}
{% if button %}
<div class="clearfix">{{ button }}</div>
{% endif %}
</div>
{% else %}
{% for element in elements %}
{{ element }}
{% endfor %}
{% endif %}

View file

@ -0,0 +1,67 @@
{#
/**
* @file
* Default theme implementation for a field.
*
* To override output, copy the "field.html.twig" from the templates directory
* to your theme's directory and customize it, just like customizing other
* Drupal templates such as page.html.twig or node.html.twig.
*
* Instead of overriding the theming for all fields, you can also just override
* theming for a subset of fields using
* @link themeable Theme hook suggestions. @endlink For example,
* here are some theme hook suggestions that can be used for a field_foo field
* on an article node type:
* - field--node--field-foo--article.html.twig
* - field--node--field-foo.html.twig
* - field--node--article.html.twig
* - field--field-foo.html.twig
* - field--text-with-summary.html.twig
* - field.html.twig
*
* Available variables:
* - attributes: HTML attributes for the containing element.
* - label_hidden: Whether to show the field label or not.
* - title_attributes: HTML attributes for the title.
* - label: The label for the field.
* - multiple: TRUE if a field can contain multiple items.
* - items: List of all the field items. Each item contains:
* - attributes: List of HTML attributes for each item.
* - content: The field item's content.
* - entity_type: The entity type to which the field belongs.
* - field_name: The name of the field.
* - field_type: The type of the field.
* - label_display: The display settings for the label.
*
* @see template_preprocess_field()
*
* @ingroup themeable
*/
#}
{% if label_hidden %}
{% if multiple %}
<div{{ attributes }}>
{% for item in items %}
<div{{ item.attributes }}>{{ item.content }}</div>
{% endfor %}
</div>
{% else %}
{% for item in items %}
<div{{ attributes }}>{{ item.content }}</div>
{% endfor %}
{% endif %}
{% else %}
<div{{ attributes }}>
<div{{ title_attributes }}>{{ label }}</div>
{% if multiple %}
<div>
{% endif %}
{% for item in items %}
<div{{ item.attributes }}>{{ item.content }}</div>
{% endfor %}
{% if multiple %}
</div>
{% endif %}
</div>
{% endif %}

View file

@ -0,0 +1,63 @@
{#
/**
* @file
* Default theme implementation for a fieldset element and its children.
*
* Available variables:
* - attributes: HTML attributes for the <fieldset> element.
* - errors: (optional) Any errors for this <fieldset> element, may not be set.
* - required: Boolean indicating whether the <fieldeset> element is required.
* - legend: The <legend> element containing the following properties:
* - title: Title of the <fieldset>, intended for use as the text
of the <legend>.
* - attributes: HTML attributes to apply to the <legend> element.
* - description: The description element containing the following properties:
* - content: The description content of the <fieldset>.
* - attributes: HTML attributes to apply to the description container.
* - children: The rendered child elements of the <fieldset>.
* - prefix: The content to add before the <fieldset> children.
* - suffix: The content to add after the <fieldset> children.
*
* @see template_preprocess_fieldset()
*
* @ingroup themeable
*/
#}
{%
set classes = [
'js-form-item',
'form-item',
'js-form-wrapper',
'form-wrapper',
]
%}
<fieldset{{ attributes.addClass(classes) }}>
{%
set legend_span_classes = [
'fieldset-legend',
required ? 'js-form-required',
required ? 'form-required',
]
%}
{# Always wrap fieldset legends in a <span> for CSS positioning. #}
<legend{{ legend.attributes }}>
<span{{ legend_span.attributes.addClass(legend_span_classes) }}>{{ legend.title }}</span>
</legend>
<div class="fieldset-wrapper">
{% if errors %}
<div>
{{ errors }}
</div>
{% endif %}
{% if prefix %}
<span class="field-prefix">{{ prefix }}</span>
{% endif %}
{{ children }}
{% if suffix %}
<span class="field-suffix">{{ suffix }}</span>
{% endif %}
{% if description.content %}
<div{{ description.attributes.addClass('description') }}>{{ description.content }}</div>
{% endif %}
</div>
</fieldset>

View file

@ -0,0 +1,27 @@
{#
/**
* @file
* Default theme implementation for a form element label.
*
* Available variables:
* - title: The label's text.
* - title_display: Elements title_display setting.
* - required: An indicator for whether the associated form element is required.
* - attributes: A list of HTML attributes for the label.
*
* @see template_preprocess_form_element_label()
*
* @ingroup themeable
*/
#}
{%
set classes = [
title_display == 'after' ? 'option',
title_display == 'invisible' ? 'visually-hidden',
required ? 'js-form-required',
required ? 'form-required',
]
%}
{% if title is not empty or required -%}
<label{{ attributes.addClass(classes) }}>{{ title }}</label>
{%- endif %}

View file

@ -0,0 +1,96 @@
{#
/**
* @file
* Default theme implementation for a form element.
*
* Available variables:
* - attributes: HTML attributes for the containing element.
* - errors: (optional) Any errors for this form element, may not be set.
* - prefix: (optional) The form element prefix, may not be set.
* - suffix: (optional) The form element suffix, may not be set.
* - required: The required marker, or empty if the associated form element is
* not required.
* - type: The type of the element.
* - name: The name of the element.
* - label: A rendered label element.
* - label_display: Label display setting. It can have these values:
* - before: The label is output before the element. This is the default.
* The label includes the #title and the required marker, if #required.
* - after: The label is output after the element. For example, this is used
* for radio and checkbox #type elements. If the #title is empty but the
* field is #required, the label will contain only the required marker.
* - invisible: Labels are critical for screen readers to enable them to
* properly navigate through forms but can be visually distracting. This
* property hides the label for everyone except screen readers.
* - attribute: Set the title attribute on the element to create a tooltip but
* output no label element. This is supported only for checkboxes and radios
* in \Drupal\Core\Render\Element\CompositeFormElementTrait::preRenderCompositeFormElement().
* It is used where a visual label is not needed, such as a table of
* checkboxes where the row and column provide the context. The tooltip will
* include the title and required marker.
* - description: (optional) A list of description properties containing:
* - content: A description of the form element, may not be set.
* - attributes: (optional) A list of HTML attributes to apply to the
* description content wrapper. Will only be set when description is set.
* - description_display: Description display setting. It can have these values:
* - before: The description is output before the element.
* - after: The description is output after the element. This is the default
* value.
* - invisible: The description is output after the element, hidden visually
* but available to screen readers.
* - disabled: True if the element is disabled.
* - title_display: Title display setting.
*
* @see template_preprocess_form_element()
*
* @ingroup themeable
*/
#}
{%
set classes = [
'js-form-item',
'form-item',
'js-form-type-' ~ type|clean_class,
'form-item-' ~ name|clean_class,
'js-form-item-' ~ name|clean_class,
title_display not in ['after', 'before'] ? 'form-no-label',
disabled == 'disabled' ? 'form-disabled',
errors ? 'form-item--error',
]
%}
{%
set description_classes = [
'description',
description_display == 'invisible' ? 'visually-hidden',
]
%}
<div{{ attributes.addClass(classes) }}>
{% if label_display in ['before', 'invisible'] %}
{{ label }}
{% endif %}
{% if prefix is not empty %}
<span class="field-prefix">{{ prefix }}</span>
{% endif %}
{% if description_display == 'before' and description.content %}
<div{{ description.attributes }}>
{{ description.content }}
</div>
{% endif %}
{{ children }}
{% if suffix is not empty %}
<span class="field-suffix">{{ suffix }}</span>
{% endif %}
{% if label_display == 'after' %}
{{ label }}
{% endif %}
{% if errors %}
<div class="form-item--error-message">
{{ errors }}
</div>
{% endif %}
{% if description_display in ['after', 'invisible'] and description.content %}
<div{{ description.attributes.addClass(description_classes) }}>
{{ description.content }}
</div>
{% endif %}
</div>

View file

@ -0,0 +1,17 @@
{#
/**
* @file
* Default theme implementation for a 'form' element.
*
* Available variables
* - attributes: A list of HTML attributes for the wrapper element.
* - children: The child elements of the form.
*
* @see template_preprocess_form()
*
* @ingroup themeable
*/
#}
<form{{ attributes }}>
{{ children }}
</form>

View file

@ -0,0 +1,49 @@
{#
/**
* @file
* Default theme implementation for the basic structure of a single Drupal page.
*
* Variables:
* - logged_in: A flag indicating if user is logged in.
* - root_path: The root path of the current page (e.g., node, admin, user).
* - node_type: The content type for the current node, if the page is a node.
* - head_title: List of text elements that make up the head_title variable.
* May contain one or more of the following:
* - title: The title of the page.
* - name: The name of the site.
* - slogan: The slogan of the site.
* - page_top: Initial rendered markup. This should be printed before 'page'.
* - page: The rendered page markup.
* - page_bottom: Closing rendered markup. This variable should be printed after
* 'page'.
* - db_offline: A flag indicating if the database is offline.
* - placeholder_token: The token for generating head, css, js and js-bottom
* placeholders.
*
* @see template_preprocess_html()
*
* @ingroup themeable
*/
#}
<!DOCTYPE html>
<html{{ html_attributes }}>
<head>
<head-placeholder token="{{ placeholder_token }}">
<title>{{ head_title|safe_join(' | ') }}</title>
<css-placeholder token="{{ placeholder_token }}">
<js-placeholder token="{{ placeholder_token }}">
</head>
<body{{ attributes }}>
{#
Keyboard navigation/accessibility link to main content section in
page.html.twig.
#}
<a href="#main-content" class="visually-hidden focusable">
{{ 'Skip to main content'|t }}
</a>
{{ page_top }}
{{ page }}
{{ page_bottom }}
<js-bottom-placeholder token="{{ placeholder_token }}">
</body>
</html>

View file

@ -0,0 +1,15 @@
{#
/**
* @file
* Default theme implementation of an image.
*
* Available variables:
* - attributes: HTML attributes for the img tag.
* - style_name: (optional) The name of the image style applied.
*
* @see template_preprocess_image()
*
* @ingroup themeable
*/
#}
<img{{ attributes }} />

View file

@ -0,0 +1,14 @@
{#
/**
* @file
* Default theme implementation for a set of indentation divs.
*
* These <div> tags are used for drag and drop tables.
*
* Available variables:
* - size: Optional. The number of indentations to create.
*
* @ingroup themeable
*/
#}
{% for i in 1..size if size > 0 %}<div class="js-indentation indentation">&nbsp;</div>{% endfor %}

View file

@ -0,0 +1,15 @@
{#
/**
* @file
* Default theme implementation for an 'input' #type form element.
*
* Available variables:
* - attributes: A list of HTML attributes for the input element.
* - children: Optional additional rendered elements.
*
* @see template_preprocess_input()
*
* @ingroup themeable
*/
#}
<input{{ attributes }} />{{ children }}

View file

@ -0,0 +1,55 @@
{#
/**
* @file
* Default theme implementation to display a Drupal installation page.
*
* All available variables are mirrored in page.html.twig.
* Some may be blank but they are provided for consistency.
*
* @see template_preprocess_install_page()
*
* @ingroup themeable
*/
#}
<div class="layout-container">
<header role="banner">
{% if site_name or site_slogan %}
<div class="name-and-slogan">
{% if site_name %}
<h1>{{ site_name }}</h1>
{% endif %}
{% if site_slogan %}
<div class="site-slogan">{{ site_slogan }}</div>
{% endif %}
</div>{# /.name-and-slogan #}
{% endif %}
</header>
<main role="main">
{% if title %}
<h2>{{ title }}</h2>
{% endif %}
{{ page.highlighted }}
{{ page.content }}
</main>
{% if page.sidebar_first %}
<aside class="layout-sidebar-first" role="complementary">
{{ page.sidebar_first }}
</aside>{# /.layout-sidebar-first #}
{% endif %}
{% if page.sidebar_second %}
<aside class="layout-sidebar-second" role="complementary">
{{ page.sidebar_second }}
</aside>{# /.layout-sidebar-second #}
{% endif %}
{% if page.footer %}
<footer role="contentinfo">
{{ page.footer }}
</footer>
{% endif %}
</div>{# /.layout-container #}

View file

@ -0,0 +1,41 @@
{#
/**
* @file
* Default theme implementation for an item list.
*
* Available variables:
* - items: A list of items. Each item contains:
* - attributes: HTML attributes to be applied to each list item.
* - value: The content of the list element.
* - title: The title of the list.
* - list_type: The tag for list element ("ul" or "ol").
* - wrapper_attributes: HTML attributes to be applied to the list wrapper.
* - attributes: HTML attributes to be applied to the list.
* - empty: A message to display when there are no items. Allowed value is a
* string or render array.
* - context: A list of contextual data associated with the list. May contain:
* - list_style: The custom list style.
*
* @see template_preprocess_item_list()
*
* @ingroup themeable
*/
#}
{% if context.list_style %}
{%- set attributes = attributes.addClass('item-list__' ~ context.list_style) %}
{% endif %}
{% if items or empty %}
{%- if title is not empty -%}
<h3>{{ title }}</h3>
{%- endif -%}
{%- if items -%}
<{{ list_type }}{{ attributes }}>
{%- for item in items -%}
<li{{ item.attributes }}>{{ item.value }}</li>
{%- endfor -%}
</{{ list_type }}>
{%- else -%}
{{- empty -}}
{%- endif -%}
{%- endif %}

View file

@ -0,0 +1,57 @@
{#
/**
* @file
* Default theme implementation for a set of links.
*
* Available variables:
* - attributes: Attributes for the UL containing the list of links.
* - links: Links to be output.
* Each link will have the following elements:
* - title: The link text.
* - url: The link URL. If omitted, the 'title' is shown as a plain text
* item in the links list. If 'url' is supplied, the entire link is passed
* to l() as its $options parameter.
* - attributes: (optional) HTML attributes for the anchor, or for the <span>
* tag if no 'url' is supplied.
* - heading: (optional) A heading to precede the links.
* - text: The heading text.
* - level: The heading level (e.g. 'h2', 'h3').
* - attributes: (optional) A keyed list of attributes for the heading.
* If the heading is a string, it will be used as the text of the heading and
* the level will default to 'h2'.
*
* Headings should be used on navigation menus and any list of links that
* consistently appears on multiple pages. To make the heading invisible use
* the 'visually-hidden' CSS class. Do not use 'display:none', which
* removes it from screen readers and assistive technology. Headings allow
* screen reader and keyboard only users to navigate to or skip the links.
* See http://juicystudio.com/article/screen-readers-display-none.php and
* http://www.w3.org/TR/WCAG-TECHS/H42.html for more information.
*
* @see template_preprocess_links()
*
* @ingroup themeable
*/
#}
{% if links -%}
{%- if heading -%}
{%- if heading.level -%}
<{{ heading.level }}{{ heading.attributes }}>{{ heading.text }}</{{ heading.level }}>
{%- else -%}
<h2{{ heading.attributes }}>{{ heading.text }}</h2>
{%- endif -%}
{%- endif -%}
<ul{{ attributes }}>
{%- for item in links -%}
<li{{ item.attributes }}>
{%- if item.link -%}
{{ item.link }}
{%- elseif item.text_attributes -%}
<span{{ item.text_attributes }}>{{ item.text }}</span>
{%- else -%}
{{ item.text }}
{%- endif -%}
</li>
{%- endfor -%}
</ul>
{%- endif %}

View file

@ -0,0 +1,60 @@
{#
/**
* @file
* Default theme implementation to display a single Drupal page while offline.
*
* All available variables are mirrored in page.html.twig.
* Some may be blank but they are provided for consistency.
*
* @see template_preprocess_maintenance_page()
*
* @ingroup themeable
*/
#}
<header role="banner">
{% if logo %}
<a href="{{ front_page }}" title="{{ 'Home'|t }}" rel="home">
<img src="{{ logo }}" alt="{{ 'Home'|t }}"/>
</a>
{% endif %}
{% if site_name or site_slogan %}
{% if site_name %}
<h1>
<a href="{{ front_page }}" title="{{ 'Home'|t }}" rel="home">{{ site_name }}</a>
</h1>
{% endif %}
{% if site_slogan %}
<div>{{ site_slogan }}</div>
{% endif %}
{% endif %}
</header>
<main role="main">
{% if title %}
<h1>{{ title }}</h1>
{% endif %}
{{ page.highlighted }}
{{ page.content }}
</main>
{% if page.sidebar_first %}
<aside role="complementary">
{{ page.sidebar_first }}
</aside>
{% endif %}
{% if page.sidebar_second %}
<aside role="complementary">
{{ page.sidebar_second }}
</aside>
{% endif %}
{% if page.footer %}
<footer role="contentinfo">
{{ page.footer }}
</footer>
{% endif %}

View file

@ -0,0 +1,25 @@
{#
/**
* @file
* Default theme implementation for a list of maintenance tasks to perform.
*
* Available variables:
* - tasks: A list of maintenance tasks to perform. Each item in the list has
* the following variables:
* - item: The maintenance task.
* - attributes: HTML attributes for the maintenance task.
* - status: (optional) Text describing the status of the maintenance task,
* 'active' or 'done'.
*
* @ingroup themeable
*/
#}
<h2 class="visually-hidden">{{ 'Installation tasks'|t }}</h2>
<ol class="task-list">
{% for task in tasks %}
<li{{ task.attributes }}>
{{ task.item }}
{% if task.status %}<span class="visually-hidden"> ({{ task.status }})</span>{% endif %}
</li>
{% endfor %}
</ol>

View file

@ -0,0 +1,22 @@
{#
/**
* @file
* Default theme implementation for a marker for new or updated content.
*
* Available variables:
* - status: Number representing the marker status to display. Use the constants
* below for comparison:
* - MARK_NEW
* - MARK_UPDATED
* - MARK_READ
*
* @ingroup themeable
*/
#}
{% if logged_in %}
{% if status is constant('MARK_NEW') %}
{{ 'New'|t }}
{% elseif status is constant('MARK_UPDATED') %}
{{ 'Updated'|t }}
{% endif %}
{% endif %}

View file

@ -0,0 +1,15 @@
{#
/**
* @file
* Default theme implementation for a single local action link.
*
* Available variables:
* - attributes: HTML attributes for the wrapper element.
* - link: A rendered link element.
*
* @see template_preprocess_menu_local_action()
*
* @ingroup themeable
*/
#}
<li{{ attributes }}>{{ link }}</li>

View file

@ -0,0 +1,19 @@
{#
/**
* @file
* Default theme implementation for a local task link.
*
* Available variables:
* - attributes: HTML attributes for the wrapper element.
* - is_active: Whether the task item is an active tab.
* - link: A rendered link element.
*
* Note: This template renders the content for each task item in
* menu-local-tasks.html.twig.
*
* @see template_preprocess_menu_local_task()
*
* @ingroup themeable
*/
#}
<li{{ attributes }}>{{ link }}</li>

View file

@ -0,0 +1,23 @@
{#
/**
* @file
* Default theme implementation to display primary and secondary local tasks.
*
* Available variables:
* - primary: HTML list items representing primary tasks.
* - secondary: HTML list items representing primary tasks.
*
* Each item in these variables (primary and secondary) can be individually
* themed in menu-local-task.html.twig.
* @ingroup themeable
*/
#}
{% if primary %}
<h2 class="visually-hidden">{{ 'Primary tabs'|t }}</h2>
<ul>{{ primary }}</ul>
{% endif %}
{% if secondary %}
<h2 class="visually-hidden">{{ 'Secondary tabs'|t }}</h2>
<ul>{{ secondary }}</ul>
{% endif %}

View file

@ -0,0 +1,49 @@
{#
/**
* @file
* Default theme implementation to display a menu.
*
* Available variables:
* - menu_name: The machine name of the menu.
* - items: A nested list of menu items. Each menu item contains:
* - attributes: HTML attributes for the menu item.
* - below: The menu item child items.
* - title: The menu link title.
* - url: The menu link url, instance of \Drupal\Core\Url
* - localized_options: Menu link localized options.
* - is_expanded: TRUE if the link has visible children within the current
* menu tree.
* - is_collapsed: TRUE if the link has children within the current menu tree
* that are not currently visible.
* - in_active_trail: TRUE if the link is in the active trail.
*
* @ingroup themeable
*/
#}
{% import _self as menus %}
{#
We call a macro which calls itself to render the full tree.
@see http://twig.sensiolabs.org/doc/tags/macro.html
#}
{{ menus.menu_links(items, attributes, 0) }}
{% macro menu_links(items, attributes, menu_level) %}
{% import _self as menus %}
{% if items %}
{% if menu_level == 0 %}
<ul{{ attributes }}>
{% else %}
<ul>
{% endif %}
{% for item in items %}
<li{{ item.attributes }}>
{{ link(item.title, item.url) }}
{% if item.below %}
{{ menus.menu_links(item.below, attributes, menu_level + 1) }}
{% endif %}
</li>
{% endfor %}
</ul>
{% endif %}
{% endmacro %}

View file

@ -0,0 +1,21 @@
{#
/**
* @file
* Default theme implementation for page titles.
*
* Available variables:
* - title_attributes: HTML attributes for the page title element.
* - title_prefix: Additional output populated by modules, intended to be
* displayed in front of the main title tag that appears in the template.
* - title: The page title, for use in the actual content.
* - title_suffix: Additional output populated by modules, intended to be
* displayed after the main title tag that appears in the template.
*
* @ingroup themeable
*/
#}
{{ title_prefix }}
{% if title %}
<h1{{ title_attributes }}>{{ title }}</h1>
{% endif %}
{{ title_suffix }}

View file

@ -0,0 +1,90 @@
{#
/**
* @file
* Default theme implementation to display a single page.
*
* The doctype, html, head and body tags are not in this template. Instead they
* can be found in the html.html.twig template in this directory.
*
* Available variables:
*
* General utility variables:
* - base_path: The base URL path of the Drupal installation. Will usually be
* "/" unless you have installed Drupal in a sub-directory.
* - is_front: A flag indicating if the current page is the front page.
* - logged_in: A flag indicating if the user is registered and signed in.
* - is_admin: A flag indicating if the user has permission to access
* administration pages.
*
* Site identity:
* - front_page: The URL of the front page. Use this instead of base_path when
* linking to the front page. This includes the language domain or prefix.
*
* Page content (in order of occurrence in the default page.html.twig):
* - messages: Status and error messages. Should be displayed prominently.
* - node: Fully loaded node, if there is an automatically-loaded node
* associated with the page and the node ID is the second argument in the
* page's path (e.g. node/12345 and node/12345/revisions, but not
* comment/reply/12345).
*
* Regions:
* - page.header: Items for the header region.
* - page.primary_menu: Items for the primary menu region.
* - page.secondary_menu: Items for the secondary menu region.
* - page.highlighted: Items for the highlighted content region.
* - page.help: Dynamic help text, mostly for admin pages.
* - page.content: The main content of the current page.
* - page.sidebar_first: Items for the first sidebar.
* - page.sidebar_second: Items for the second sidebar.
* - page.footer: Items for the footer region.
* - page.breadcrumb: Items for the breadcrumb region.
*
* @see template_preprocess_page()
* @see html.html.twig
*
* @ingroup themeable
*/
#}
<div class="layout-container">
<header role="banner">
{{ page.header }}
</header>
{{ page.primary_menu }}
{{ page.secondary_menu }}
{{ page.breadcrumb }}
{{ page.highlighted }}
{{ page.help }}
<main role="main">
<a id="main-content" tabindex="-1"></a>{# link is in html.html.twig #}
<div class="layout-content">
{{ page.content }}
</div>{# /.layout-content #}
{% if page.sidebar_first %}
<aside class="layout-sidebar-first" role="complementary">
{{ page.sidebar_first }}
</aside>
{% endif %}
{% if page.sidebar_second %}
<aside class="layout-sidebar-second" role="complementary">
{{ page.sidebar_second }}
</aside>
{% endif %}
</main>
{% if page.footer %}
<footer role="contentinfo">
{{ page.footer }}
</footer>
{% endif %}
</div>{# /.layout-container #}

View file

@ -0,0 +1,100 @@
{#
/**
* @file
* Default theme implementation to display a pager.
*
* Available variables:
* - items: List of pager items.
* The list is keyed by the following elements:
* - first: Item for the first page; not present on the first page of results.
* - previous: Item for the previous page; not present on the first page
* of results.
* - next: Item for the next page; not present on the last page of results.
* - last: Item for the last page; not present on the last page of results.
* - pages: List of pages, keyed by page number.
* Sub-sub elements:
* items.first, items.previous, items.next, items.last, and each item inside
* items.pages contain the following elements:
* - href: URL with appropriate query parameters for the item.
* - attributes: A keyed list of HTML attributes for the item.
* - text: The visible text used for the item link, such as " Previous"
* or "Next ".
* - current: The page number of the current page.
* - ellipses: If there are more pages than the quantity allows, then an
* ellipsis before or after the listed pages may be present.
* - previous: Present if the currently visible list of pages does not start
* at the first page.
* - next: Present if the visible list of pages ends before the last page.
*
* @see template_preprocess_pager()
*
* @ingroup themeable
*/
#}
{% if items %}
<nav class="pager" role="navigation" aria-labelledby="pagination-heading">
<h4 id="pagination-heading" class="visually-hidden">{{ 'Pagination'|t }}</h4>
<ul class="pager__items js-pager__items">
{# Print first item if we are not on the first page. #}
{% if items.first %}
<li class="pager__item pager__item--first">
<a href="{{ items.first.href }}" title="{{ 'Go to first page'|t }}"{{ items.first.attributes|without('href', 'title') }}>
<span class="visually-hidden">{{ 'First page'|t }}</span>
<span aria-hidden="true">{{ items.first.text|default('« First'|t) }}</span>
</a>
</li>
{% endif %}
{# Print previous item if we are not on the first page. #}
{% if items.previous %}
<li class="pager__item pager__item--previous">
<a href="{{ items.previous.href }}" title="{{ 'Go to previous page'|t }}" rel="prev"{{ items.previous.attributes|without('href', 'title', 'rel') }}>
<span class="visually-hidden">{{ 'Previous page'|t }}</span>
<span aria-hidden="true">{{ items.previous.text|default(' Previous'|t) }}</span>
</a>
</li>
{% endif %}
{# Add an ellipsis if there are further previous pages. #}
{% if ellipses.previous %}
<li class="pager__item pager__item--ellipsis" role="presentation">&hellip;</li>
{% endif %}
{# Now generate the actual pager piece. #}
{% for key, item in items.pages %}
<li class="pager__item{{ current == key ? ' is-active' : '' }}">
{% if current == key %}
{% set title = 'Current page'|t %}
{% else %}
{% set title = 'Go to page @key'|t({'@key': key}) %}
{% endif %}
<a href="{{ item.href }}" title="{{ title }}"{{ item.attributes|without('href', 'title') }}>
<span class="visually-hidden">
{{ current == key ? 'Current page'|t : 'Page'|t }}
</span>
{{- key -}}
</a>
</li>
{% endfor %}
{# Add an ellipsis if there are further next pages. #}
{% if ellipses.next %}
<li class="pager__item pager__item--ellipsis" role="presentation">&hellip;</li>
{% endif %}
{# Print next item if we are not on the last page. #}
{% if items.next %}
<li class="pager__item pager__item--next">
<a href="{{ items.next.href }}" title="{{ 'Go to next page'|t }}" rel="next"{{ items.next.attributes|without('href', 'title', 'rel') }}>
<span class="visually-hidden">{{ 'Next page'|t }}</span>
<span aria-hidden="true">{{ items.next.text|default('Next '|t) }}</span>
</a>
</li>
{% endif %}
{# Print last item if we are not on the last page. #}
{% if items.last %}
<li class="pager__item pager__item--last">
<a href="{{ items.last.href }}" title="{{ 'Go to last page'|t }}"{{ items.last.attributes|without('href', 'title') }}>
<span class="visually-hidden">{{ 'Last page'|t }}</span>
<span aria-hidden="true">{{ items.last.text|default('Last »'|t) }}</span>
</a>
</li>
{% endif %}
</ul>
</nav>
{% endif %}

View file

@ -0,0 +1,23 @@
{#
/**
* @file
* Default theme implementation for a progress bar.
*
* Note that the core Batch API uses this only for non-JavaScript batch jobs.
*
* Available variables:
* - label: The label of the working task.
* - percent: The percentage of the progress.
* - message: A string containing information to be displayed.
*
* @ingroup themeable
*/
#}
<div class="progress" data-drupal-progress>
{% if label %}
<div class="progress__label">{{ label }}</div>
{% endif %}
<div class="progress__track"><div class="progress__bar" style="width: {{ percent }}%"></div></div>
<div class="progress__percentage">{{ percent }}%</div>
<div class="progress__description">{{ message }}</div>
</div>

View file

@ -0,0 +1,15 @@
{#
/**
* @file
* Default theme implementation for a 'radios' #type form element.
*
* Available variables
* - attributes: A list of HTML attributes for the wrapper element.
* - children: The rendered radios.
*
* @see template_preprocess_radios()
*
* @ingroup themeable
*/
#}
<div{{ attributes }}>{{ children }}</div>

View file

@ -0,0 +1,21 @@
{#
/**
* @file
* Default theme implementation to display a region.
*
* Available variables:
* - content: The content for this region, typically blocks.
* - attributes: HTML attributes for the region <div>.
* - region: The name of the region variable as defined in the theme's
* .info.yml file.
*
* @see template_preprocess_region()
*
* @ingroup themeable
*/
#}
{% if content %}
<div{{ attributes }}>
{{ content }}
</div>
{% endif %}

View file

@ -0,0 +1,29 @@
{#
/**
* @file
* Default theme implementation for a select element.
*
* Available variables:
* - attributes: HTML attributes for the <select> tag.
* - options: The <option> element children.
*
* @see template_preprocess_select()
*
* @ingroup themeable
*/
#}
{% spaceless %}
<select{{ attributes }}>
{% for option in options %}
{% if option.type == 'optgroup' %}
<optgroup label="{{ option.label }}">
{% for sub_option in option.options %}
<option value="{{ sub_option.value }}"{{ sub_option.selected ? ' selected="selected"' }}>{{ sub_option.label }}</option>
{% endfor %}
</optgroup>
{% elseif option.type == 'option' %}
<option value="{{ option.value }}"{{ option.selected ? ' selected="selected"' }}>{{ option.label }}</option>
{% endif %}
{% endfor %}
</select>
{% endspaceless %}

View file

@ -0,0 +1,47 @@
{#
/**
* @file
* Default theme implementation for status messages.
*
* Displays status, error, and warning messages, grouped by type.
*
* An invisible heading identifies the messages for assistive technology.
* Sighted users see a colored box. See http://www.w3.org/TR/WCAG-TECHS/H69.html
* for info.
*
* Add an ARIA label to the contentinfo area so that assistive technology
* user agents will better describe this landmark.
*
* Available variables:
* - message_list: List of messages to be displayed, grouped by type.
* - status_headings: List of all status types.
* - display: (optional) May have a value of 'status' or 'error' when only
* displaying messages of that specific type.
* - attributes: HTML attributes for the element, including:
* - class: HTML classes.
*
* @ingroup themeable
*/
#}
{% for type, messages in message_list %}
<div role="contentinfo" aria-label="{{ status_headings[type] }}"{{ attributes|without('role', 'aria-label') }}>
{% if type == 'error' %}
<div role="alert">
{% endif %}
{% if status_headings[type] %}
<h2 class="visually-hidden">{{ status_headings[type] }}</h2>
{% endif %}
{% if messages|length > 1 %}
<ul>
{% for message in messages %}
<li>{{ message }}</li>
{% endfor %}
</ul>
{% else %}
{{ messages|first }}
{% endif %}
{% if type == 'error' %}
</div>
{% endif %}
</div>
{% endfor %}

View file

@ -0,0 +1,41 @@
{#
/**
* @file
* Default theme implementation for the status report.
*
* Available variables:
* - requirements: Contains multiple requirement instances.
* Each requirement contains:
* - title: The title of the requirement.
* - value: (optional) The requirement's status.
* - description: (optional) The requirement's description.
* - severity_title: The title of the severity.
* - severity_status: Indicates the severity status.
*
* @see template_preprocess_status_report()
*
* @ingroup themeable
*/
#}
<table class="system-status-report">
<tbody>
{% for requirement in requirements %}
<tr class="system-status-report__entry system-status-report__entry--{{ requirement.severity_status }} color-{{ requirement.severity_status }}">
{% if requirement.severity_status in ['warning', 'error'] %}
<th class="system-status-report__status-title system-status-report__status-icon system-status-report__status-icon--{{ requirement.severity_status }}">
<span class="visually-hidden">{{ requirement.severity_title }}</span>
{% else %}
<th class="system-status-report__status-title">
{% endif %}
{{ requirement.title }}
</th>
<td>
{{ requirement.value }}
{% if requirement.description %}
<div class="description">{{ requirement.description }}</div>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>

View file

@ -0,0 +1,27 @@
{#
/**
* @file
* Default theme implementation for the admin index page.
*
* Available variables:
* - system_compact_link: Themed link to toggle compact view.
* - containers: A list of administrative containers keyed by position: left or
* right. Each container in the list contains:
* - blocks: A list of administrative blocks, rendered
* through admin-block.html.twig.
*
* @see template_preprocess_system_admin_index()
*
* @ingroup themeable
*/
#}
<div class="admin clearfix">
{{ system_compact_link }}
{% for position, blocks in containers %}
<div class="{{ position }} clearfix">
{% for block in blocks %}
{{ block }}
{% endfor %}
</div>
{% endfor %}
</div>

View file

@ -0,0 +1,17 @@
{#
/**
* @file
* Default theme implementation for a system settings form.
*
* This template will be used when a system config form specifies 'config_form'
* as its #theme callback. Otherwise, by default, system config forms will be
* themed by form.html.twig. This does not alter the appearance of a form at
* all, but is provided as a convenience for themers.
*
* Available variables:
* - form: The confirm form.
*
* @ingroup themeable
*/
#}
{{ form }}

View file

@ -0,0 +1,76 @@
{#
/**
* @file
* Default theme implementation for the modules listing page.
*
* Displays a list of all packages in a project.
*
* Available variables:
* - modules: Contains multiple module instances. Each module contains:
* - attributes: Attributes on the row.
* - checkbox: A checkbox for enabling the module.
* - name: The human-readable name of the module.
* - id: A unique identifier for interacting with the details element.
* - enable_id: A unique identifier for interacting with the checkbox element.
* - description: The description of the module.
* - machine_name: The module's machine name.
* - version: Information about the module version.
* - requires: A list of modules that this module requires.
* - required_by: A list of modules that require this module.
* - links: A list of administration links provided by the module.
*
* @see template_preprocess_system_modules_details()
*
* @ingroup themeable
*/
#}
<table class="responsive-enabled" data-striping="1">
<thead>
<tr>
<th class="checkbox visually-hidden">{{ 'Installed'|t }}</th>
<th class="name visually-hidden">{{ 'Name'|t }}</th>
<th class="description visually-hidden priority-low">{{ 'Description'|t }}</th>
</tr>
</thead>
<tbody>
{% for module in modules %}
{% set zebra = cycle(['odd', 'even'], loop.index0) %}
<tr{{ module.attributes.addClass(zebra) }}>
<td class="checkbox">
{{ module.checkbox }}
</td>
<td class="module">
<label id="{{ module.id }}" for="{{ module.enable_id }}" class="module-name table-filter-text-source">{{ module.name }}</label>
</td>
<td class="description expand priority-low">
<details class="js-form-wrapper form-wrapper" id="{{ module.enable_id }}-description">
<summary aria-controls="{{ module.enable_id }}-description" role="button" aria-expanded="false"><span class="text module-description">{{ module.description }}</span></summary>
<div class="details-wrapper">
<div class="details-description">
<div class="requirements">
<div class="admin-requirements">{{ 'Machine name: <span dir="ltr" class="table-filter-text-source">@machine-name</span>'|t({'@machine-name': module.machine_name }) }}</div>
{% if module.version %}
<div class="admin-requirements">{{ 'Version: @module-version'|t({'@module-version': module.version }) }}</div>
{% endif %}
{% if module.requires %}
<div class="admin-requirements">{{ 'Requires: @module-list'|t({'@module-list': module.requires }) }}</div>
{% endif %}
{% if module.required_by %}
<div class="admin-requirements">{{ 'Required by: @module-list'|t({'@module-list': module.required_by }) }}</div>
{% endif %}
</div>
{% if module.links %}
<div class="links">
{% for link_type in ['help', 'permissions', 'configure'] %}
{{ module.links[link_type] }}
{% endfor %}
</div>
{% endif %}
</div>
</div>
</details>
</td>
</tr>
{% endfor %}
</tbody>
</table>

View file

@ -0,0 +1,75 @@
{#
/**
* @file
* Default theme implementation for the modules uninstall page.
*
* Available variables:
* - form: The modules uninstall form.
* - modules: Contains multiple module instances. Each module contains:
* - attributes: Attributes on the row.
* - module_name: The name of the module.
* - checkbox: A checkbox for uninstalling the module.
* - checkbox_id: A unique identifier for interacting with the checkbox
* element.
* - name: The human-readable name of the module.
* - description: The description of the module.
* - disabled_reasons: (optional) A list of reasons why this module cannot be
* uninstalled.
*
* @see template_preprocess_system_modules_uninstall()
*
* @ingroup themeable
*/
#}
{{ form.filters }}
<table class="responsive-enabled" data-striping="1">
<thead>
<tr>
<th>{{ 'Uninstall'|t }}</th>
<th>{{ 'Name'|t }}</th>
<th>{{ 'Description'|t }}</th>
</tr>
</thead>
<tbody>
{% for module in modules %}
{% set zebra = cycle(['odd', 'even'], loop.index0) -%}
<tr{{ module.attributes.addClass(zebra) }}>
<td align="center">
{{- module.checkbox -}}
</td>
<td>
<label for="{{ module.checkbox_id }}" class="module-name table-filter-text-source">{{ module.name }}</label>
</td>
<td class="description">
<span class="text module-description">{{ module.description }}</span>
{% if module.reasons_count > 0 %}
<div class="admin-requirements">
{%- trans -%}
The following reason prevents {{ module.module_name }} from being uninstalled:
{%- plural module.reasons_count -%}
The following reasons prevent {{ module.module_name }} from being uninstalled:
{%- endtrans %}
<div class="item-list">
<ul>
{%- for reason in module.validation_reasons -%}
<li>{{ reason }}</li>
{%- endfor -%}
{%- if module.required_by -%}
<li>{{ 'Required by: @module-list'|t({'@module-list': module.required_by|safe_join(', ') }) }}</li>
{%- endif -%}
</ul>
</div>
</div>
{% endif %}
</td>
</tr>
{% else %}
<tr class="odd">
<td colspan="3" class="empty message">{{ 'No modules are available to uninstall.'|t }}</td>
</tr>
{% endfor %}
</tbody>
</table>
{{ form|without('filters', 'modules', 'uninstall') }}

View file

@ -0,0 +1,76 @@
{#
/**
* @file
* Default theme implementation for the Appearance page.
*
* Available variables:
* - attributes: HTML attributes for the main container.
* - theme_groups: A list of theme groups. Each theme group contains:
* - attributes: HTML attributes specific to this theme group.
* - title: Title for the theme group.
* - state: State of the theme group, e.g. installed or uninstalled.
* - themes: A list of themes within the theme group. Each theme contains:
* - attributes: HTML attributes specific to this theme.
* - screenshot: A screenshot representing the theme.
* - description: Description of the theme.
* - name: Theme name.
* - version: The theme's version number.
* - is_default: Boolean indicating whether the theme is the default theme
* or not.
* - is_admin: Boolean indicating whether the theme is the admin theme or
* not.
* - notes: Identifies what context this theme is being used in, e.g.,
* default theme, admin theme.
* - incompatible: Text describing any compatibility issues.
* - operations: A list of operation links, e.g., Settings, Enable, Disable,
* etc. these links should only be displayed if the theme is compatible.
*
* @see template_preprocess_system_themes_page()
*
* @ingroup themeable
*/
#}
<div{{ attributes }}>
{% for theme_group in theme_groups %}
{%
set theme_group_classes = [
'system-themes-list',
'system-themes-list-' ~ theme_group.state,
'clearfix',
]
%}
<div{{ theme_group.attributes.addClass(theme_group_classes) }}>
<h2 class="system-themes-list__header">{{ theme_group.title }}</h2>
{% for theme in theme_group.themes %}
{%
set theme_classes = [
theme.is_default ? 'theme-default',
theme.is_admin ? 'theme-admin',
'theme-selector',
'clearfix',
]
%}
<div{{ theme.attributes.addClass(theme_classes) }}>
{% if theme.screenshot %}
{{ theme.screenshot }}
{% endif %}
<div class="theme-info">
<h3 class="theme-info__header">
{{- theme.name }} {{ theme.version -}}
{% if theme.notes %}
({{ theme.notes|safe_join(', ') }})
{%- endif -%}
</h3>
<div class="theme-info__description">{{ theme.description }}</div>
{# Display operation links if the theme is compatible. #}
{% if theme.incompatible %}
<div class="incompatible">{{ theme.incompatible }}</div>
{% else %}
{{ theme.operations }}
{% endif %}
</div>
</div>
{% endfor %}
</div>
{% endfor %}
</div>

View file

@ -0,0 +1,105 @@
{#
/**
* @file
* Default theme implementation to display a table.
*
* Available variables:
* - attributes: HTML attributes to apply to the <table> tag.
* - caption: A localized string for the <caption> tag.
* - colgroups: Column groups. Each group contains the following properties:
* - attributes: HTML attributes to apply to the <col> tag.
* Note: Drupal currently supports only one table header row, see
* https://www.drupal.org/node/893530 and
* http://api.drupal.org/api/drupal/includes!theme.inc/function/theme_table/7#comment-5109.
* - header: Table header cells. Each cell contains the following properties:
* - tag: The HTML tag name to use; either 'th' or 'td'.
* - attributes: HTML attributes to apply to the tag.
* - content: A localized string for the title of the column.
* - field: Field name (required for column sorting).
* - sort: Default sort order for this column ("asc" or "desc").
* - sticky: A flag indicating whether to use a "sticky" table header.
* - rows: Table rows. Each row contains the following properties:
* - attributes: HTML attributes to apply to the <tr> tag.
* - data: Table cells.
* - no_striping: A flag indicating that the row should receive no
* 'even / odd' styling. Defaults to FALSE.
* - cells: Table cells of the row. Each cell contains the following keys:
* - tag: The HTML tag name to use; either 'th' or 'td'.
* - attributes: Any HTML attributes, such as "colspan", to apply to the
* table cell.
* - content: The string to display in the table cell.
* - active_table_sort: A boolean indicating whether the cell is the active
table sort.
* - footer: Table footer rows, in the same format as the rows variable.
* - empty: The message to display in an extra row if table does not have
* any rows.
* - no_striping: A boolean indicating that the row should receive no striping.
* - header_columns: The number of columns in the header.
*
* @see template_preprocess_table()
*
* @ingroup themeable
*/
#}
<table{{ attributes }}>
{% if caption %}
<caption>{{ caption }}</caption>
{% endif %}
{% for colgroup in colgroups %}
{% if colgroup.cols %}
<colgroup{{ colgroup.attributes }}>
{% for col in colgroup.cols %}
<col{{ col.attributes }} />
{% endfor %}
</colgroup>
{% else %}
<colgroup{{ colgroup.attributes }} />
{% endif %}
{% endfor %}
{% if header %}
<thead>
<tr>
{% for cell in header %}
<{{ cell.tag }}{{ cell.attributes }}>
{{- cell.content -}}
</{{ cell.tag }}>
{% endfor %}
</tr>
</thead>
{% endif %}
{% if rows %}
<tbody>
{% for row in rows %}
<tr{{ row.attributes }}>
{% for cell in row.cells %}
<{{ cell.tag }}{{ cell.attributes }}>
{{- cell.content -}}
</{{ cell.tag }}>
{% endfor %}
</tr>
{% endfor %}
</tbody>
{% elseif empty %}
<tbody>
<tr>
<td colspan="{{ header_columns }}">{{ empty }}</td>
</tr>
</tbody>
{% endif %}
{% if footer %}
<tfoot>
{% for row in footer %}
<tr{{ row.attributes }}>
{% for cell in row.cells %}
<{{ cell.tag }}{{ cell.attributes }}>
{{- cell.content -}}
</{{ cell.tag }}>
{% endfor %}
</tr>
{% endfor %}
</tfoot>
{% endif %}
</table>

View file

@ -0,0 +1,26 @@
{#
/**
* @file
* Default theme implementation for displaying a tablesort indicator.
*
* Available variables:
* - style: Either 'asc' or 'desc', indicating the sorting direction.
*
* @ingroup themeable
*/
#}
{%
set classes = [
'tablesort',
'tablesort--' ~ style,
]
%}
<span{{ attributes.addClass(classes) }}>
<span class="visually-hidden">
{% if style == 'asc' -%}
{{ 'Sort ascending'|t }}
{% else -%}
{{ 'Sort descending'|t }}
{% endif %}
</span>
</span>

View file

@ -0,0 +1,20 @@
{#
/**
* @file
* Default theme implementation for a 'textarea' #type form element.
*
* Available variables
* - wrapper_attributes: A list of HTML attributes for the wrapper element.
* - attributes: A list of HTML attributes for the <textarea> element.
* - resizable: An indicator for whether the textarea is resizable.
* - required: An indicator for whether the textarea is required.
* - value: The textarea content.
*
* @see template_preprocess_textarea()
*
* @ingroup themeable
*/
#}
<div{{ wrapper_attributes }}>
<textarea{{ attributes }}>{{ value }}</textarea>
</div>

View file

@ -0,0 +1,22 @@
{#
/**
* @file
* Default theme implementation for a date / time element.
*
* Available variables
* - timestamp: (optional) A UNIX timestamp for the datetime attribute. If the
* datetime cannot be represented as a UNIX timestamp, use a valid datetime
* attribute value in attributes.datetime.
* - text: (optional) The content to display within the <time> element.
* Defaults to a human-readable representation of the timestamp value or the
* datetime attribute value using format_date().
* - attributes: (optional) HTML attributes to apply to the <time> element.
* A datetime attribute in 'attributes' overrides the 'timestamp'. To
* create a valid datetime attribute value from a UNIX timestamp, use
* format_date() with one of the predefined 'html_*' formats.
*
* @see template_preprocess_time()
* @see http://www.w3.org/TR/html5-author/the-time-element.html#attr-time-datetime
*/
#}
<time{{ attributes }}>{{ text }}</time>

View file

@ -0,0 +1,15 @@
{#
/**
* @file
* Default theme implementation for vertical tabs.
*
* Available variables
* - attributes: A list of HTML attributes for the wrapper element.
* - children: The rendered tabs.
*
* @see template_preprocess_vertical_tabs()
*
* @ingroup themeable
*/
#}
<div{{ attributes.setAttribute('data-vertical-tabs-panes', TRUE) }}>{{ children }}</div>