first commit

This commit is contained in:
2024-07-15 12:33:27 +02:00
commit ce50ae282b
22084 changed files with 2623791 additions and 0 deletions

View File

@@ -0,0 +1,34 @@
{#
/**
* @file
* Theme override for the content of an administrative block.
*
* Available variables:
* - content: List of administrative menu items. Each menu item contains:
* - link: Link to the admin section.
* - title: Short name of the section.
* - description: Description of the administrative menu item.
* - url: URI to the admin section.
* - options: URL options. See \Drupal\Core\Url::fromUri() for details.
* - 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()
*/
#}
{%
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,30 @@
{#
/**
* @file
* Theme override 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).
* - attributes: HTML attributes for the containing div element.
*/
#}
{%
set classes = [
'panel',
]
%}
<div{{ attributes.addClass(classes) }}>
{% 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,25 @@
{#
/**
* @file
* Theme override 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()
*/
#}
<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,21 @@
{#
/**
* @file
* Theme override 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()
*/
#}
{% if messages %}
<div{{ attributes.addClass('authorize-results') }}>
{% for message_group in messages %}
{{ message_group }}
{% endfor %}
</div>
{% endif %}

View File

@@ -0,0 +1,22 @@
{#
/**
* @file
* Theme override to present a list of content block types.
*
* Available variables:
* - types: A collection of all the available content block types.
* Each block type contains the following:
* - link: A link to add a block of this type.
* - description: A description of this content block type.
*
* @see template_preprocess_block_content_add_list()
*/
#}
{% apply spaceless %}
<dl>
{% for type in types %}
<dt>{{ type.link }}</dt>
<dd>{{ type.description }}</dd>
{% endfor %}
</dl>
{% endapply %}

View File

@@ -0,0 +1,21 @@
{#
/**
* @file
* Theme override for a form element in config_translation.
*
* Available variables:
* - element: Array that represents the element shown in the form.
* - source: The source of the translation.
* - translation: The translation for the target language.
*
* @see template_preprocess()
*/
#}
<div class="translation-set clearfix">
<div class="layout-column layout-column--half translation-set__source">
{{ element.source }}
</div>
<div class="layout-column layout-column--half translation-set__translated">
{{ element.translation }}
</div>
</div>

View File

@@ -0,0 +1,45 @@
{#
/**
* @file
* Theme override to display a Field UI 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_field_ui_table()
*/
#}
{# Add Ajax wrapper. #}
<div id="field-display-overview-wrapper">
{% include 'table.html.twig' %}
</div>

View File

@@ -0,0 +1,46 @@
{#
/**
* @file
* Theme override for a storage type option form element.
*
* Available variables:
* - attributes: HTML attributes for the containing element.
* - errors: (optional) Any errors for this form element, may not be set.
* - label: A rendered label element.
* - 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.
* - variant: specifies option type. Typically 'field-option' or 'field-suboption'.
*
* @see template_preprocess_form_element()
*
* @ingroup themeable
*/
#}
{%
set classes = [
errors ? 'form-item--error',
variant ? variant ~ '__item'
]
%}
<div{{ attributes.addClass(classes) }}>
{% if variant == 'field-option' %}
{{ label }}
<div{{ description.attributes }}>
{{ description.content }}
</div>
{% endif %}
{{ children }}
{% if variant == 'field-suboption' %}
{{ label }}
<div{{ description.attributes.addClass(description_classes) }}>
{{ description.content }}
</div>
{% endif %}
{% if errors %}
<div class="form-item--error-message">
{{ errors }}
</div>
{% endif %}
</div>

View File

@@ -0,0 +1,23 @@
{#
/**
* @file
* Theme override for a section of the help page.
*
* Available variables:
* - title: The section title.
* - description: The description text for the section.
* - links: Links to display in the section.
* - empty: Text to display if there are no links.
*/
#}
<h2>{{ title }}</h2>
<p>{{ description }}</p>
{% if links %}
<ul>
{% for link in links %}
<li>{{ link }}</li>
{% endfor %}
</ul>
{% else %}
<p>{{ empty }}</p>
{% endif %}

View File

@@ -0,0 +1,14 @@
{#
/**
* @file
* Theme override for a help topic.
*
* Available variables:
* - body: The body of the topic.
* - related: List of related topic links.
*/
#}
<article>
{{ body }}
{{ related }}
</article>

View File

@@ -0,0 +1,12 @@
{#
/**
* @file
* Theme override for a 3x3 grid of checkboxes for image anchors.
*
* Available variables:
* - table: HTML for the table of image anchors.
*
* @see template_preprocess_image_anchor()
*/
#}
{{ table }}

View File

@@ -0,0 +1,30 @@
{#
/**
* @file
* Theme override for a summary of an image crop effect.
*
* Available variables:
* - data: The current configuration for this resize effect, including:
* - width: The width of the resized image.
* - height: The height of the resized image.
* - anchor: The part of the image that will be retained after cropping.
* - anchor_label: The translated label of the crop anchor.
* - effect: The effect information, including:
* - id: The effect identifier.
* - label: The effect name.
* - description: The effect description.
*/
#}
{% if data.width and data.height -%}
{{ data.width }}×{{ data.height }}
{%- else -%}
{% if data.width %}
{% trans %}
width {{ data.width }}
{% endtrans %}
{% elseif data.height %}
{% trans %}
height {{ data.height }}
{% endtrans %}
{% endif %}
{%- endif %}

View File

@@ -0,0 +1,28 @@
{#
/**
* @file
* Theme override for a summary of an image resize effect.
*
* Available variables:
* - data: The current configuration for this resize effect, including:
* - width: The width of the resized image.
* - height: The height of the resized image.
* - effect: The effect information, including:
* - id: The effect identifier.
* - label: The effect name.
* - description: The effect description.
*/
#}
{% if data.width and data.height -%}
{{ data.width }}×{{ data.height }}
{%- else -%}
{% if data.width %}
{% trans %}
width {{ data.width }}
{% endtrans %}
{% elseif data.height %}
{% trans %}
height {{ data.height }}
{% endtrans %}
{% endif %}
{%- endif %}

View File

@@ -0,0 +1,26 @@
{#
/**
* @file
* Theme override for a summary of an image rotate effect.
*
* Available variables:
* - data: The current configuration for this resize effect, including:
* - degrees: Degrees to rotate the image, positive values will rotate the
* image clockwise, negative values counter-clockwise.
* - bgcolor: The hex background color of the new areas created as consequence
* of rotation.
* - random: If the rotation angle is randomized.
* - effect: The effect information, including:
* - id: The effect identifier.
* - label: The effect name.
* - description: The effect description.
*/
#}
{% if data.random %}
{% set degrees = data.degrees|abs %}
{% trans %}
random between -{{ degrees }}° and {{ degrees }}°
{% endtrans %}
{% else %}
{{ data.degrees }}°
{% endif %}

View File

@@ -0,0 +1,30 @@
{#
/**
* @file
* Theme override for a summary of an image scale and crop effect.
*
* Available variables:
* - data: The current configuration for this resize effect, including:
* - width: The width of the resized image.
* - height: The height of the resized image.
* - anchor: The part of the image that will be retained after cropping.
* - anchor_label: The translated label of the crop anchor.
* - effect: The effect information, including:
* - id: The effect identifier.
* - label: The effect name.
* - description: The effect description.
*/
#}
{% if data.width and data.height -%}
{{ data.width }}×{{ data.height }}
{%- else -%}
{% if data.width %}
{% trans %}
width {{ data.width }}
{% endtrans %}
{% elseif data.height %}
{% trans %}
height {{ data.height }}
{% endtrans %}
{% endif %}
{%- endif %}

View File

@@ -0,0 +1,35 @@
{#
/**
* @file
* Theme override for a summary of an image scale effect.
*
* Available variables:
* - data: The current configuration for this resize effect, including:
* - width: The width of the resized image.
* - height: The height of the resized image.
* - upscale: If images larger than their original size can scale.
* - effect: The effect information, including:
* - id: The effect identifier.
* - label: The effect name.
* - description: The effect description.
*/
#}
{% if data.width and data.height -%}
{{ data.width }}×{{ data.height }}
{%- else -%}
{% if data.width %}
{% trans %}
width {{ data.width }}
{% endtrans %}
{% elseif data.height %}
{% trans %}
height {{ data.height }}
{% endtrans %}
{% endif %}
{%- endif %}
{% if data.upscale %}
{% trans %}
(upscaling allowed)
{% endtrans %}
{% endif %}

View File

@@ -0,0 +1,55 @@
{#
/**
* @file
* Theme override to display a preview of an image style.
*
* Available variables:
* - style_id: The ID of the image style.
* - style_name: The name of the image style.
* - cache_bypass: A timestamp token used to avoid browser caching of images.
* - original: An associative array containing:
* - url: The URL of the original image.
* - width: The width in pixels of the original image.
* - height: The height in pixels of the original image.
* - rendered: The render array for the original image.
* - derivative: An associative array containing:
* - url: The URL of the derivative image.
* - width: The width in pixels of the derivative image.
* - height: The height in pixels of the derivative image.
* - rendered: The rendered derivative image.
* - preview: An associative array containing:
* - original: An associative array containing:
* - width: The width in pixels of the original image in the preview.
* - height: The height in pixels of the original image in the preview.
* - derivative: An associative array containing:
* - width: The width in pixels of the derivative image in the preview.
* - height: The height in pixels of the derivative image in the preview.
*
* @see template_preprocess_image_style_preview()
*/
#}
<div class="image-style-preview preview clearfix">
{# Preview of the original image. #}
<div class="preview-image-wrapper">
{{ 'original'|t }} (<a href="{{ original.url }}">{{ 'view actual size'|t }}</a>)
<div class="preview-image original-image" style="width: {{ preview.original.width }}px; height: {{ preview.original.height }}px;">
<a href="{{ original.url }}">
{{ original.rendered }}
</a>
<div class="height" style="height: {{ preview.original.height }}px"><span>{{ original.height }}px</span></div>
<div class="width" style="width: {{ preview.original.width }}px"><span>{{ original.width }}px</span></div>
</div>
</div>
{# Derivative of the image style. #}
<div class="preview-image-wrapper">
{{ style_name }} (<a href="{{ derivative.url }}?{{ cache_bypass }}">{{ 'view actual size'|t }}</a>)
<div class="preview-image modified-image" style="width: {{ preview.derivative.width }}px; height: {{ preview.derivative.height }}px;">
<a href="{{ derivative.url }}?{{ cache_bypass }}">
{{ derivative.rendered }}
</a>
<div class="height" style="height: {{ preview.derivative.height }}px"><span>{{ derivative.height }}px</span></div>
<div class="width" style="width: {{ preview.derivative.width }}px"><span>{{ derivative.width }}px</span></div>
</div>
</div>
</div>

View File

@@ -0,0 +1,12 @@
{#
/**
* @file
* Theme override 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.
*/
#}
{% if size > 0 %}{% for i in 1..size %}<div class="js-indentation indentation">&nbsp;</div>{% endfor %}{% endif %}

View File

@@ -0,0 +1,14 @@
{#
/**
* @file
* Theme override to display a language content settings table.
*
* Available variables:
* - title: The title of the table.
* - build: Table of content language settings.
*
* @see template_preprocess_language_content_settings_table()
*/
#}
<h4>{{ title }}</h4>
{{ build }}

View File

@@ -0,0 +1,39 @@
{#
/**
* @file
* Theme override for a language negotiation configuration form.
*
* Available variables:
* - language_types: A list of language negotiation types. Each language type
* contains the following:
* - type: The machine name for the negotiation type.
* - title: The language negotiation type name.
* - description: A description for how the language negotiation type
* operates.
* - configurable: A radio element to toggle the table.
* - table: A draggable table for the language detection methods of this type.
* - children: Remaining form items for the group.
* - attributes: A list of HTML attributes for the wrapper element.
* - children: Remaining form items for all groups.
*
* @see template_preprocess_language_negotiation_configure_form()
*/
#}
{% for language_type in language_types %}
{%
set language_classes = [
'js-form-item',
'form-item',
'table-language-group',
'table-' ~ language_type.type ~ '-wrapper',
]
%}
<div{{ language_type.attributes.addClass(language_classes) }}>
<h2>{{ language_type.title }}</h2>
<div class="description">{{ language_type.description }}</div>
{{ language_type.configurable }}
{{ language_type.table }}
{{ language_type.children }}
</div>
{% endfor %}
{{ children }}

View File

@@ -0,0 +1,23 @@
{#
/**
* @file
* Theme override for the last time we checked for update data.
*
* Available variables:
* - last_checked: Whether or not locale updates have been checked before.
* - time: The formatted time ago when the site last checked for available
* updates.
* - link: A link to manually check available updates.
*
* @see template_preprocess_locale_translation_last_check()
*/
#}
<div class="locale checked">
<p>
{% if last_checked %}
{% trans %} Last checked: {{ time }} ago {% endtrans %}
{% else %}
{{ 'Last checked: never'|t }}
{% endif %}
<span class="check-manually">({{ link }})</span></p>
</div>

View File

@@ -0,0 +1,57 @@
{#
/**
* @file
* Theme override for displaying translation status information.
*
* Displays translation status information per language.
*
* Available variables:
* - modules: A list of modules names that have available translation updates.
* - updates: A list of available translation updates.
* - not_found: A list of modules missing translation updates.
*
* @see template_preprocess_locale_translation_update_info()
*/
#}
<div class="locale-translation-update__wrapper" tabindex="0" role="button">
<span class="locale-translation-update__prefix visually-hidden">Show description</span>
{% if modules %}
{% set module_list = modules|safe_join(', ') %}
<span class="locale-translation-update__message">{% trans %}Updates for: {{ module_list }}{% endtrans %}</span>
{% elseif not_found %}
<span class="locale-translation-update__message">
{%- trans -%}
Missing translations for one project
{%- plural not_found|length -%}
Missing translations for @count projects
{%- endtrans -%}
</span>
{% endif %}
{% if updates or not_found %}
<div class="locale-translation-update__details">
{% if updates %}
<ul>
{% for update in updates %}
<li>{{ update.name }} ({{ update.timestamp|format_date('html_date') }})</li>
{% endfor %}
</ul>
{% endif %}
{% if not_found %}
{#
Prefix the missing updates list if there is an available updates lists
before it.
#}
{% if updates %}
{{ 'Missing translations for:'|t }}
{% endif %}
{% if not_found %}
<ul>
{% for update in not_found %}
<li>{{ update.name }} ({{ update.version|default('no version'|t) }}). {{ update.info }}</li>
{% endfor %}
</ul>
{% endif %}
{% endif %}
</div>
{% endif %}
</div>

View File

@@ -0,0 +1,23 @@
{#
/**
* @file
* Theme override 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'.
*/
#}
<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,16 @@
{#
/**
* @file
* Theme override for menu_link_form.
*
* Two-column template for the menu link add/edit form.
*
* This template will be used when a menu link form specifies
* 'menu_link_form' as its #theme callback. Otherwise, by default,
* menu_link add/edit forms will be themed by form.html.twig.
*
* Available variables:
* - form: The menu link add/edit form.
*/
#}
{{ form }}

View File

@@ -0,0 +1,14 @@
{#
/**
* @file
* Theme override for the status report counter.
*
* Available variables:
* - amount: The number shown on counter.
* - text: The text shown on counter.
* - severity: The severity of the counter.
*/
#}
<span class="system-status-counter__status-icon system-status-counter__status-icon--{{ severity }}"></span>
<span>{{ amount }} {{ text }}</span>
<a href="#{{ severity }}"><span class="visually-hidden">{{ text }} </span>{{ 'Details'|t }}</a>

View File

@@ -0,0 +1,81 @@
{#
/**
* @file
* Theme override for the status report general info.
*
* Available variables:
* - drupal: The status of Drupal installation:
* - value: The current status of Drupal installation.
* - description: The description for current status of Drupal installation.
* - cron: The status of cron:
* - value: The current status of cron.
* - description: The description for current status of cron.
* - cron.run_cron: An array to render a button for running cron.
* - database_system: The status of database system:
* - value: The current status of database system.
* - description: The description for current status of cron.
* - database_system_version: The info about current database version:
* - value: The current version of database.
* - description: The description for current version of database.
* - php: The current version of PHP:
* - value: The status of currently installed PHP version.
* - description: The description for current installed PHP version.
* - php_memory_limit: The info about current PHP memory limit:
* - value: The status of currently set PHP memory limit.
* - description: The description for currently set PHP memory limit.
* - webserver: The info about currently installed web server:
* - value: The status of currently installed web server.
* - description: The description for the status of currently installed web
* server.
*/
#}
<h2>{{ 'General System Information'|t }}</h2>
<div class="system-status-general-info__item">
<h3 class="system-status-general-info__item-title">{{ 'Drupal Version'|t }}</h3>
{{ drupal.value }}
{% if drupal.description %}
{{ drupal.description }}
{% endif %}
</div>
<div class="system-status-general-info__item">
<h3 class="system-status-general-info__item-title">{{ 'Last Cron Run'|t }}</h3>
{{ cron.value }}
{% if cron.run_cron %}
{{ cron.run_cron }}
{% endif %}
{% if cron.description %}
{{ cron.description }}
{% endif %}
</div>
<div class="system-status-general-info__item">
<h3 class="system-status-general-info__item-title">{{ 'Web Server'|t }}</h3>
{{ webserver.value }}
{% if webserver.description %}
{{ webserver.description }}
{% endif %}
</div>
<div class="system-status-general-info__item">
<h3 class="system-status-general-info__item-title">{{ 'PHP'|t }}</h3>
<h4>{{ 'Version'|t }}</h4> {{ php.value }}
{% if php.description %}
{{ php.description }}
{% endif %}
<h4>{{ 'Memory limit'|t }}</h4>{{ php_memory_limit.value }}
{% if php_memory_limit.description %}
{{ php_memory_limit.description }}
{% endif %}
</div>
<div class="system-status-general-info__item">
<h3 class="system-status-general-info__item-title">{{ 'Database'|t }}</h3>
<h4>{{ 'Version'|t }}</h4>{{ database_system_version.value }}
{% if database_system_version.description %}
{{ database_system_version.description }}
{% endif %}
<h4>{{ 'System'|t }}</h4>{{ database_system.value }}
{% if database_system.description %}
{{ database_system.description }}
{% endif %}
</div>

View File

@@ -0,0 +1,49 @@
{#
/**
* @file
* Theme override of grouped status report requirements.
*
* - grouped_requirements: Contains grouped requirements.
* Each group contains:
* - title: The title of the group.
* - type: The severity of the group.
* - items: The requirement instances.
* Each requirement item 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.
*/
#}
{{ attach_library('core/drupal.collapse') }}
<div>
{% for group in grouped_requirements %}
<div>
<h3 id="{{ group.type }}">{{ group.title }}</h3>
{% for requirement in group.items %}
<details class="system-status-report__entry" open>
{%
set summary_classes = [
'system-status-report__status-title',
group.type in ['warning', 'error'] ? 'system-status-report__status-icon system-status-report__status-icon--' ~ group.type
]
%}
<summary{{ create_attribute({'class': summary_classes}) }} role="button">
{% if requirement.severity_title %}
<span class="visually-hidden">{{ requirement.severity_title }}</span>
{% endif %}
{{ requirement.title }}
</summary>
<div class="system-status-report__entry__value">
{{ requirement.value }}
{% if requirement.description %}
<div class="description">{{ requirement.description }}</div>
{% endif %}
</div>
</details>
{% endfor %}
</div>
{% endfor %}
</div>

View File

@@ -0,0 +1,28 @@
{#
/**
* @file
* Theme override for the status report page.
*
* Available variables:
* - counters: The list of counter elements.
* - general_info: A render array to create general info element.
* - requirements: A render array to create requirements table.
*
* @see template_preprocess_status_report()
*/
#}
{% if counters|length == 3 %}
{% set element_width_class = ' system-status-report-counters__item--third-width' %}
{% elseif counters|length == 2 %}
{% set element_width_class = ' system-status-report-counters__item--half-width' %}
{% endif %}
<div class="system-status-report-counters">
{% for counter in counters %}
<div class="system-status-report-counters__item{{ element_width_class }}">
{{ counter }}
</div>
{% endfor %}
</div>
{{ general_info }}
{{ requirements }}

View File

@@ -0,0 +1,37 @@
{#
/**
* @file
* Theme override for the status report.
*
* Available variables:
* - grouped_requirements: Contains grouped requirements.
* Each group contains:
* - title: The title of the group.
* - type: The severity of the group.
* - items: The requirement instances.
* Each requirement item 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.
* - requirements: Ungrouped requirements
*/
#}
{% for group in grouped_requirements %}
<h3 id="{{ group.type }}">{{ group.title }}</h3>
{% for requirement in group.items %}
<details>
<summary role="button">
{% if requirement.severity_title %}
<span class="visually-hidden">{{ requirement.severity_title }}</span>
{% endif %}
{{ requirement.title }}
</summary>
{{ requirement.value }}
{% if requirement.description %}
<div>{{ requirement.description }}</div>
{% endif %}
</details>
{% endfor %}
{% endfor %}

View File

@@ -0,0 +1,25 @@
{#
/**
* @file
* Theme override 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()
*/
#}
<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,15 @@
{#
/**
* @file
* Theme override 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.
*/
#}
{{ form }}

View File

@@ -0,0 +1,74 @@
{#
/**
* @file
* Theme override 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()
*/
#}
<table class="responsive-enabled">
<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,73 @@
{#
/**
* @file
* Theme override 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()
*/
#}
{{ form.filters }}
<table class="responsive-enabled">
<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,16 @@
{#
/**
* @file
* Theme override for the message when fetching security advisories fails.
*
* This error message is displayed on the status report page.
*
* Available variables:
* - error_message: A render array containing the appropriate error message.
*
* @see template_preprocess_system_security_advisories_fetch_error_message()
*
* @ingroup themeable
*/
#}
{{ error_message }}

View File

@@ -0,0 +1,74 @@
{#
/**
* @file
* Theme override 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()
*/
#}
<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,24 @@
{#
/**
* @file
* Theme override for displaying a tablesort indicator.
*
* Available variables:
* - style: Either 'asc' or 'desc', indicating the sorting direction.
*/
#}
{%
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,14 @@
{#
/**
* @file
* Default theme implementation for the message when fetching data fails.
*
* Available variables:
* - error_message: A render array containing the appropriate error message.
*
* @see template_preprocess_update_fetch_error_message()
*
* @ingroup themeable
*/
#}
{{ error_message }}

View File

@@ -0,0 +1,21 @@
{#
/**
* @file
* Theme override for the last time update data was checked.
*
* Available variables:
* - last: The timestamp that the site was last checked for updates.
* - time: The formatted time since the site last checked for updates.
* - link: A link to check for updates manually.
*
* @see template_preprocess_update_last_check()
*/
#}
<p>
{% if last %}
{{ 'Last checked: @time ago'|t({'@time': time}) }}
{% else %}
{{ 'Last checked: never'|t }}
{% endif %}
({{ link }})
</p>

View File

@@ -0,0 +1,104 @@
{#
/**
* @file
* Theme override for the project status report.
*
* Available variables:
* - title: The project title.
* - url: The project URL.
* - status: The project status.
* - label: The project status label.
* - attributes: HTML attributes for the project status.
* - reason: The reason you should update the project.
* - icon: The project status version indicator icon.
* - existing_version: The version of the installed project.
* - versions: The available versions of the project.
* - install_type: The type of project (e.g., dev).
* - datestamp: The date/time of a project version's release.
* - extras: HTML attributes and additional information about the project.
* - attributes: HTML attributes for the extra item.
* - label: The label for an extra item.
* - data: The data about an extra item.
* - includes: The projects within the project.
* - disabled: The currently disabled projects in the project.
*
* @see template_preprocess_update_project_status()
*/
#}
{%
set status_classes = [
project.status == constant('Drupal\\update\\UpdateManagerInterface::NOT_SECURE') ? 'project-update__status--security-error',
project.status == constant('Drupal\\update\\UpdateManagerInterface::REVOKED') ? 'project-update__status--revoked',
project.status == constant('Drupal\\update\\UpdateManagerInterface::NOT_SUPPORTED') ? 'project-update__status--not-supported',
project.status == constant('Drupal\\update\\UpdateManagerInterface::NOT_CURRENT') ? 'project-update__status--not-current',
project.status == constant('Drupal\\update\\UpdateManagerInterface::CURRENT') ? 'project-update__status--current',
]
%}
<div{{ status.attributes.addClass('project-update__status', status_classes) }}>
{%- if status.label -%}
<span>{{ status.label }}</span>
{%- else -%}
{{ status.reason }}
{%- endif %}
<span class="project-update__status-icon">
{{ status.icon }}
</span>
</div>
<div class="project-update__title">
{%- if url -%}
<a href="{{ url }}">{{ title }}</a>
{%- else -%}
{{ title }}
{%- endif %}
{{ existing_version }}
{% if install_type == 'dev' and datestamp %}
<span class="project-update__version-date">({{ datestamp }})</span>
{% endif %}
</div>
{% if versions %}
{% for version in versions %}
{{ version }}
{% endfor %}
{% endif %}
{%
set extra_classes = [
project.status == constant('Drupal\\update\\UpdateManagerInterface::NOT_SECURE') ? 'project-not-secure',
project.status == constant('Drupal\\update\\UpdateManagerInterface::REVOKED') ? 'project-revoked',
project.status == constant('Drupal\\update\\UpdateManagerInterface::NOT_SUPPORTED') ? 'project-not-supported',
]
%}
<div class="project-updates__details">
{% if extras %}
<div class="extra">
{% for extra in extras %}
<div{{ extra.attributes.addClass(extra_classes) }}>
{{ extra.label }}: {{ extra.data }}
</div>
{% endfor %}
</div>
{% endif %}
{% set includes = includes|join(', ') %}
{% if disabled %}
{{ 'Includes:'|t }}
<ul>
<li>
{% trans %}
Enabled: {{ includes|placeholder }}
{% endtrans %}
</li>
<li>
{% set disabled = disabled|join(', ') %}
{% trans %}
Disabled: {{ disabled|placeholder }}
{% endtrans %}
</li>
</ul>
{% else %}
{% trans %}
Includes: {{ includes|placeholder }}
{% endtrans %}
{% endif %}
</div>

View File

@@ -0,0 +1,23 @@
{#
/**
* @file
* Theme override for the project status report.
*
* Available variables:
* - last_checked: Themed last time update data was checked.
* - no_updates_message: Message when there are no project updates.
* - project_types: A list of project types.
* - label: The project type label.
* - table: The project status table.
*
* @see template_preprocess_update_report()
*/
#}
{{ last_checked }}
{% for project_type in project_types %}
<h3>{{ project_type.label }}</h3>
{{ project_type.table }}
{% else %}
<p>{{ no_updates_message }}</p>
{% endfor %}

View File

@@ -0,0 +1,51 @@
{#
/**
* @file
* Theme override for the version display of a project.
*
* Available variables:
* - attributes: HTML attributes suitable for a container element.
* - title: The title of the project.
* - core_compatibility_details: Render array of core compatibility details.
* - version: A list of data about the latest released version, containing:
* - version: The version number.
* - date: The date of the release.
* - download_link: The URL for the downloadable file.
* - release_link: The URL for the release notes.
* - core_compatible: A flag indicating whether the project is compatible
* with the currently installed version of Drupal core. This flag is not
* set for the Drupal core project itself.
* - core_compatibility_message: A message indicating the versions of Drupal
* core with which this project is compatible. This message is also
* contained within the 'core_compatibility_details' variable documented
* above. This message is not set for the Drupal core project itself.
*
* @see template_preprocess_update_version()
*/
#}
<div class="{{ attributes.class }} project-update__version"{{ attributes|without('class') }}>
<div class="clearfix">
<div class="project-update__version-title layout-column layout-column--quarter">{{ title }}</div>
<div class="project-update__version-details layout-column layout-column--quarter">
<a href="{{ version.release_link }}">{{ version.version }}</a>
<span class="project-update__version-date">({{ version.date|date('Y-M-d') }})</span>
</div>
<div class="layout-column layout-column--half">
<ul class="project-update__version-links">
{% if version.core_compatible is not defined or version.core_compatible %}
<li class="project-update__download-link">
<a href="{{ version.download_link }}">{{ 'Download'|t }}</a>
</li>
{% endif %}
<li class="project-update__release-notes-link">
<a href="{{ version.release_link }}">{{ 'Release notes'|t }}</a>
</li>
{% if core_compatibility_details %}
<li class="project-update__compatibility-details">
{{ core_compatibility_details }}
</li>
{% endif %}
</ul>
</div>
</div>
</div>

View File

@@ -0,0 +1,55 @@
{#
/**
* @file
* Theme override for Views UI build group filter form.
*
* Available variables:
* - form: A render element representing the form. Contains the following:
* - form_description: The exposed filter's description.
* - expose_button: The button to toggle the expose filter form.
* - group_button: Toggle options between single and grouped filters.
* - label: A filter label input field.
* - description: A filter description field.
* - value: The filters available values.
* - optional: A checkbox to require this filter or not.
* - remember: A checkbox to remember selected filter value(s) (per user).
* - widget: Radio Buttons to select the filter widget.
* - add_group: A button to add another row to the table.
* - more: A details element for additional field exposed filter fields.
* - table: A rendered table element of the group filter form.
*
* @see template_preprocess_views_ui_build_group_filter_form()
*/
#}
{{ form.form_description }}
{{ form.expose_button }}
{{ form.group_button }}
<div class="views-left-40">
{{ form.optional }}
{{ form.remember }}
</div>
<div class="views-right-60">
{{ form.widget }}
{{ form.label }}
{{ form.description }}
</div>
{#
Render the rest of the form elements excluding elements that are rendered
elsewhere.
#}
{{ form|without(
'form_description',
'expose_button',
'group_button',
'optional',
'remember',
'widget',
'label',
'description',
'add_group',
'more'
)
}}
{{ table }}
{{ form.add_group }}
{{ form.more }}

View File

@@ -0,0 +1,11 @@
{#
/**
* @file
* Theme override for a generic views UI container/wrapper.
*
* Available variables:
* - attributes: HTML attributes to apply to the container element.
* - children: The remaining elements such as dropbuttons and tabs.
*/
#}
<div{{ attributes }}>{{ children }}</div>

View File

@@ -0,0 +1,33 @@
{#
/**
* @file
* Theme override for each "box" on the display query edit screen.
*
* Available variables:
* - attributes: HTML attributes to apply to the container element.
* - actions: Action links such as "Add", "And/Or, Rearrange" for the content.
* - title: The title of the bucket, e.g. "Fields", "Filter Criteria", etc.
* - content: Content items such as fields or settings in this container.
* - name: The name of the bucket, e.g. "Fields", "Filter Criteria", etc.
* - overridden: A boolean indicating the setting has been overridden from the
* default.
*
* @see template_preprocess_views_ui_display_tab_bucket()
*/
#}
{%
set classes = [
'views-ui-display-tab-bucket',
name ? name|clean_class,
overridden ? 'overridden',
]
%}
<div{{ attributes.addClass(classes) }}>
{% if title -%}
<h3 class="views-ui-display-tab-bucket__title">{{ title }}</h3>
{%- endif %}
{% if actions -%}
{{ actions }}
{%- endif %}
{{ content }}
</div>

View File

@@ -0,0 +1,35 @@
{#
/**
* @file
* Theme override for Views UI display tab settings.
*
* Template for each row inside the "boxes" on the display query edit screen.
*
* Available variables:
* - attributes: HTML attributes such as class for the container.
* - description: The description or label for this setting.
* - settings_links: A list of links for this setting.
* - defaulted: A boolean indicating the setting is in its default state.
* - overridden: A boolean indicating the setting has been overridden from the
* default.
*
* @see template_preprocess_views_ui_display_tab_setting()
*/
#}
{%
set classes = [
'views-display-setting',
'clearfix',
'views-ui-display-tab-setting',
defaulted ? 'defaulted',
overridden ? 'overridden',
]
%}
<div{{ attributes.addClass(classes) }}>
{% if description -%}
<span class="label">{{ description }}</span>
{%- endif %}
{% if settings_links %}
{{ settings_links|safe_join('<span class="label">&nbsp;|&nbsp;</span>') }}
{% endif %}
</div>

View File

@@ -0,0 +1,65 @@
{#
/**
* @file
* Theme override for exposed filter form.
*
* Available variables:
* - form_description: The exposed filter's description.
* - expose_button: The button to toggle the expose filter form.
* - group_button: Toggle options between single and grouped filters.
* - required: A checkbox to require this filter or not.
* - label: A filter label input field.
* - description: A filter description field.
* - operator: The operators for how the filters value should be treated.
* - #type: The operator type.
* - value: The filters available values.
* - use_operator: Checkbox to allow the user to expose the operator.
* - more: A details element for additional field exposed filter fields.
*/
#}
{{ form.form_description }}
{{ form.expose_button }}
{{ form.group_button }}
{{ form.required }}
{{ form.label }}
{{ form.description }}
{{ form.operator }}
{{ form.value }}
{% if form.use_operator %}
<div class="views-left-40">
{{ form.use_operator }}
</div>
{% endif %}
{#
Collect a list of elements printed to exclude when printing the
remaining elements.
#}
{% set remaining_form = form|without(
'form_description',
'expose_button',
'group_button',
'required',
'label',
'description',
'operator',
'value',
'use_operator',
'more'
)
%}
{#
Only output the right column markup if there's a left column to begin with.
#}
{% if form.operator['#type'] %}
<div class="views-right-60">
{{ remaining_form }}
</div>
{% else %}
{{ remaining_form }}
{% endif %}
{{ form.more }}

View File

@@ -0,0 +1,25 @@
{#
/**
* @file
* Theme override for Views UI rearrange filter form.
*
* Available variables:
* - form: A render element representing the form.
* - grouping: A flag whether or not there is more than one group.
* - ungroupable_table: The ungroupable filter table.
* - table: The groupable filter table.
*
* @see template_preprocess_views_ui_rearrange_filter_form()
*/
#}
{{ form.override }}
<div class="scroll" data-drupal-views-scroll>
{% if grouping %}
{{ form.filter_groups.operator }}
{% else %}
{{ form.filter_groups.groups.0 }}
{% endif %}
{{ ungroupable_table }}
{{ table }}
</div>
{{ form|without('override', 'filter_groups', 'remove_groups', 'filters') }}

View File

@@ -0,0 +1,16 @@
{#
/**
* @file
* Theme override for the settings of a table style views display.
*
* Available variables:
* - table: A table of options for each field in this display.
* - form: Any remaining form fields not included in the table.
* - description_markup: An overview for the settings of this display.
*
* @see template_preprocess_views_ui_style_plugin_table()
*/
#}
{{ form.description_markup }}
{{ table }}
{{ form }}

View File

@@ -0,0 +1,22 @@
{#
/**
* @file
* Theme override for views displays on the views listing page.
*
* Available variables:
* - displays: Contains multiple display instances. Each display contains:
* - display: Display name.
* - path: Path to display, if any.
*/
#}
<ul>
{% for display in displays %}
<li>
{% if display.path %}
{{ display.display }} <span data-drupal-selector="views-table-filter-text-source">({{ display.path }})</span>
{% else %}
{{ display.display }}
{% endif %}
</li>
{% endfor %}
</ul>

View File

@@ -0,0 +1,26 @@
{#
/**
* @file
* Theme override for basic administrative info about a View.
*
* Available variables:
* - displays: List of displays.
*/
#}
<h3 class="views-ui-view-title" data-drupal-selector="views-table-filter-text-source">{{ view.label }}</h3>
<div class="views-ui-view-displays">
{% if displays %}
{% trans %}
Display
{% plural displays %}
Displays
{% endtrans %}:
<em>{{ displays|safe_join(', ') }}</em>
{% else %}
{{ 'None'|t }}
{% endif %}
</div>
<div class="views-ui-view-machine-name">
{{ 'Machine name:'|t }}
<span data-drupal-selector="views-table-filter-text-source">{{ view.id }}</span>
</div>

View File

@@ -0,0 +1,18 @@
{#
/**
* @file
* Theme override for a views UI preview section.
*
* Available variables:
* - title: The human readable section title.
* - links: A list of contextual links.
* - content: The content for this section preview.
*
* @see template_preprocess_views_ui_view_preview_section()
*/
#}
<h1 class="section-title">{{ title }}</h1>
{% if links %}
<div class="contextual">{{ links }}</div>
{% endif %}
<div class="preview-section">{{ content }}</div>

View File

@@ -0,0 +1,47 @@
{#
/**
* @file
* Theme override for views listing table.
*
* Available variables:
* - headers: Contains table headers.
* - rows: Contains multiple rows. Each row contains:
* - view_name: The human-readable name of the view.
* - machine_name: Machine name of the view.
* - description: The description of the view.
* - displays: List of displays attached to the view.
* - operations: List of available operations.
*
* @see template_preprocess_views_ui_views_listing_table()
*/
#}
<table{{ attributes.addClass('responsive-enabled') }}>
<thead>
<tr>
{% for header in headers %}
<th{{ header.attributes }}>{{ header.data }}</th>
{% endfor %}
</tr>
</thead>
<tbody>
{% for row in rows %}
<tr{{ row.attributes }}>
<td class="views-ui-view-name">
<strong data-drupal-selector="views-table-filter-text-source">{{ row.data.view_name.data }}</strong>
</td>
<td class="views-ui-view-machine-name" data-drupal-selector="views-table-filter-text-source">
{{ row.data.machine_name.data }}
</td>
<td class="views-ui-view-description" data-drupal-selector="views-table-filter-text-source">
{{ row.data.description.data }}
</td>
<td class="views-ui-view-displays">
{{ row.data.displays.data }}
</td>
<td class="views-ui-view-operations">
{{ row.data.operations.data }}
</td>
</tr>
{% endfor %}
</tbody>
</table>

View File

@@ -0,0 +1,27 @@
{#
/**
* @file
* Template file for the theming of announcement_feed admin page.
*
* This template will get rendered when the user gets navigated to the announcements_feed.announcement route.
*
* Available variables:
* - count: Contains the total number of announcements.
* - featured: A list of featured announcement objects.
* - standard: A list of non-featured announcement objects.
*
* Announcement objects have the following variables:
* - id: Unique id of the announcement.
* - title: Title of the standard announcement.
* - content: Short description of the announcement.
* - datePublishedTimestamp: Timestamp of the announcement.
* - url: Learn more link of the standard announcement.
*
* @see announcements_feed_theme()
*
* @ingroup themeable
*/
#}
{{ attach_library('announcements_feed/drupal.announcements_feed.page') }}
{% include '@announcements_feed/announcements.html.twig' %}

View File

@@ -0,0 +1,25 @@
{#
/**
* @file
* Template file for the theming of announcement_feed off-canvas dialog.
*
* This template will get rendered when the user clicks the announcement button in the toolbar.
*
* Available variables:
* - count: Contains the total number of announcements.
* - featured: A list of featured announcement objects.
* - standard: A list of non-featured announcement objects.
*
* Announcement objects have the following variables:
* - id: Unique id of the announcement.
* - title: Title of the standard announcement.
* - content: Short description of the announcement.
* - datePublishedTimestamp: Timestamp of the announcement.
* - url: Learn more link of the standard announcement.
*
* @see announcements_feed_theme()
*
* @ingroup themeable
*/
#}
{% include '@announcements_feed/announcements.html.twig' %}

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,26 @@
{% extends "block.html.twig" %}
{#
/**
* @file
* Theme override 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.
*/
#}
{% block content %}
{% if site_logo %}
<a href="{{ path('<front>') }}" rel="home">
<img src="{{ site_logo }}" alt="{{ 'Home'|t }}" fetchpriority="high" />
</a>
{% endif %}
{% if site_name %}
<a href="{{ path('<front>') }}" rel="home">{{ site_name }}</a>
{% endif %}
{{ site_slogan }}
{% endblock %}

View File

@@ -0,0 +1,49 @@
{#
/**
* @file
* Theme override 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.
* - in_preview: Whether the plugin is being rendered in preview mode.
* - 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.
*/
#}
{% 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,13 @@
{#
/**
* @file
* Theme override 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.
*/
#}
{{ content }}

View File

@@ -0,0 +1,38 @@
{#
/**
* @file
* Theme override to display a 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.
* - in_preview: Whether the plugin is being rendered in preview mode.
* - content: The content of this block.
* - attributes: array of HTML attributes populated by modules, intended to
* be added to the main container tag of this template.
* - id: A valid HTML ID and guaranteed unique.
* - title_attributes: Same as attributes, except applied to the main title
* tag that appears in the template.
* - 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.
*
* @see template_preprocess_block()
*/
#}
<div{{ attributes }}>
{{ title_prefix }}
{% if label %}
<h2{{ title_attributes }}>{{ label }}</h2>
{% endif %}
{{ title_suffix }}
{% block content %}
{{ content }}
{% endblock %}
</div>

View File

@@ -0,0 +1,28 @@
{#
/**
* @file
* Theme override 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()
*/
#}
{% 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,7 @@
<ul class="entity-moderation-form">
<li class="entity-moderation-form__item">{{ form.current }}</li>
<li class="entity-moderation-form__item">{{ form.new_state }}</li>
<li class="entity-moderation-form__item">{{ form.revision_log }}</li>
<li class="entity-moderation-form__item">{{ form.submit }}</li>
</ul>
{{ form|without('current', 'new_state', 'revision_log', 'submit') }}

View File

@@ -0,0 +1,21 @@
{#
/**
* @file
* Theme override to display a file form widget.
*
* Available variables:
* - element: Form element for the file upload.
* - attributes: HTML attributes for the containing element.
*
* @see template_preprocess_file_managed_file()
*/
#}
{%
set classes = [
'js-form-managed-file',
'form-managed-file',
]
%}
<div{{ attributes.addClass(classes) }}>
{{ element }}
</div>

View File

@@ -0,0 +1,12 @@
{#
/**
* @file
* Theme override to display help text for file fields.
*
* Available variables:
* - descriptions: Lines of help text for uploading a file.
*
* @see template_preprocess_file_upload_help()
*/
#}
{{ descriptions|safe_join('<br />') }}

View File

@@ -0,0 +1,14 @@
{#
/**
* @file
* Theme override to display a multi file form widget.
*
* Available variables:
* - table: Table of previously uploaded files.
* - element: The form element for uploading another file.
*
* @see template_preprocess_file_widget_multiple()
*/
#}
{{ table }}
{{ element }}

View File

@@ -0,0 +1,18 @@
{#
/**
* @file
* Theme override for a filter caption.
*
* Returns HTML for a captioned image, audio, video or other tag.
*
* Available variables
* - string node: The complete HTML tag whose contents are being captioned.
* - string tag: The name of the HTML tag whose contents are being captioned.
* - string caption: The caption text.
* - string classes: The classes of the captioned HTML tag.
*/
#}
<figure role="group"{%- if classes %} class="{{ classes }}"{%- endif %}>
{{ node }}
<figcaption>{{ caption }}</figcaption>
</figure>

View File

@@ -0,0 +1,23 @@
{#
/**
* @file
* Theme override for guidelines for a text format.
*
* Available variables:
* - format: Contains information about the current text format, including the
* following:
* - name: The name of the text format, potentially unsafe and needs to be
* escaped.
* - format: The machine name of the text format, e.g. 'basic_html'.
* - attributes: HTML attributes for the containing element.
* - tips: Descriptions and a CSS ID in the form of 'module-name/filter-id'
* (only used when 'long' is TRUE) for each filter in one or more text
* formats.
*
* @see template_preprocess_filter_tips()
*/
#}
<div{{ attributes }}>
<h4>{{ format.label }}</h4>
{{ tips }}
</div>

View File

@@ -0,0 +1,44 @@
{#
/**
* @file
* Theme override for a set of filter tips.
*
* Available variables:
* - tips: Descriptions and a CSS ID in the form of 'module-name/filter-id'
* (only used when 'long' is TRUE) for each filter in one or more text
* formats.
* - long: A flag indicating whether the passed-in filter tips contain extended
* explanations, i.e. intended to be output on the path 'filter/tips'
* (TRUE), or are in a short format, i.e. suitable to be displayed below a
* form element. Defaults to FALSE.
* - multiple: A flag indicating there is more than one filter tip.
*
* @see template_preprocess_filter_tips()
*/
#}
{% if multiple %}
<h2>{{ 'Text Formats'|t }}</h2>
{% endif %}
{% if tips|length %}
{% for name, tip in tips %}
{% if multiple %}
<div{{ attributes }}>
<h3>{{ tip.name }}</h3>
{% endif %}
{% if tip.list|length %}
<ul>
{% for item in tip.list %}
<li{{ tip.attributes }}>{{ item.tip }}</li>
{% endfor %}
</ul>
{% endif %}
{% if multiple %}
</div>
{% endif %}
{% endfor %}
{% endif %}

View File

@@ -0,0 +1,17 @@
{#
/**
* @file
* Theme override for an image field widget.
*
* Available variables:
* - attributes: HTML attributes for the containing element.
* - data: Render elements of the image widget.
*
* @see template_preprocess_image_widget()
*/
#}
<div{{ attributes }}>
{{ data.preview }}
{# Render widget data without the image preview that was output already. #}
{{ data|without('preview') }}
</div>

View File

@@ -0,0 +1,30 @@
{#
/**
* @file
* Theme override to list node types available for adding content.
*
* This list is displayed on the Add content admin page.
*
* Available variables:
* - types: A list of content types, each with the following properties:
* - add_link: Link to create a piece of content of this type.
* - description: Description of this type of content.
*
* @see template_preprocess_node_add_list()
*/
#}
{% if types is not empty %}
<dl>
{% for type in types %}
<dt>{{ type.add_link }}</dt>
<dd>{{ type.description }}</dd>
{% endfor %}
</dl>
{% else %}
<p>
{% set create_content = path('node.type_add') %}
{% trans %}
You have not created any content types yet. Go to the <a href="{{ create_content }}">content type creation page</a> to add a new content type.
{% endtrans %}
</p>
{% endif %}

View File

@@ -0,0 +1,16 @@
{#
/**
* @file
* Theme override for a node edit form.
*
* Two column template for the node add/edit form.
*
* This template will be used when a node edit form specifies 'node_edit_form'
* as its #theme callback. Otherwise, by default, node add/edit forms will be
* themed by form.html.twig.
*
* Available variables:
* - form: The node add/edit form.
*/
#}
{{ form }}

View File

@@ -0,0 +1,21 @@
{#
/**
* @file
* Theme override for a text format-enabled form element.
*
* Available variables:
* - children: Text format element children.
* - description: Text format element description.
* - attributes: HTML attributes for the containing element.
* - aria_description: Flag for whether or not an ARIA description has been
* added to the description container.
*
* @see template_preprocess_text_format_wrapper()
*/
#}
<div class="js-text-format-wrapper js-form-item form-item">
{{ children }}
{% if description %}
<div{{ attributes }}>{{ description }}</div>
{% endif %}
</div>

View File

@@ -0,0 +1,9 @@
{#
/**
* @file
* Theme override for a BigPipe JS placeholder interface preview.
*
* @see \Drupal\big_pipe\Render\Placeholder\BigPipeStrategy::createBigPipeJsPlaceholder()
*/
#}
{{ preview }}

View File

@@ -0,0 +1,20 @@
{#
/**
* @file
* Theme override for a single node in a printer-friendly outline.
*
* Available variables:
* - node: Fully loaded node.
* - depth: Depth of the current node inside the outline.
* - title: Node title.
* - content: Node content.
* - children: All the child nodes recursively rendered through this file.
*
* @see template_preprocess_book_node_export_html()
*/
#}
<article>
<h1>{{ title }}</h1>
{{ content }}
{{ children }}
</article>

View File

@@ -0,0 +1,100 @@
{#
/**
* @file
* Theme override for comments.
*
* Available variables:
* - author: Comment author. Can be a link or plain text.
* - content: The content-related items for the comment display. Use
* {{ content }} to print them all, or print a subset such as
* {{ content.field_example }}. Use the following code to temporarily suppress
* the printing of a given child element:
* @code
* {{ content|without('field_example') }}
* @endcode
* - created: Formatted date and time for when the comment was created.
* Preprocess functions can reformat it by calling DateFormatter::format()
* with the desired parameters on the 'comment.created' variable.
* - changed: Formatted date and time for when the comment was last changed.
* Preprocess functions can reformat it by calling DateFormatter::format()
* with the desired parameters on the 'comment.changed' variable.
* - permalink: Comment permalink.
* - submitted: Submission information created from author and created
* during template_preprocess_comment().
* - user_picture: The comment author's profile picture.
* - status: Comment status. Possible values are:
* unpublished, published, or preview.
* - title: Comment title, linked to the comment.
* - attributes: HTML attributes for the containing element.
* The attributes.class may contain one or more of the following classes:
* - comment: The current template type; for instance, 'theming hook'.
* - by-anonymous: Comment by an unregistered user.
* - by-{entity-type}-author: Comment by the author of the parent entity,
* eg. by-node-author.
* - preview: When previewing a new or edited comment.
* The following applies only to viewers who are registered users:
* - unpublished: An unpublished comment visible only to administrators.
* - 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.
* - content_attributes: List of classes for the styling of the comment content.
* - title_attributes: Same as attributes, except applied to the main title
* tag that appears in the template.
* - threaded: A flag indicating whether the comments are threaded or not.
*
* These variables are provided to give context about the parent comment (if
* any):
* - parent_comment: Full parent comment entity (if any).
* - parent_author: Equivalent to author for the parent comment.
* - parent_created: Equivalent to created for the parent comment.
* - parent_changed: Equivalent to changed for the parent comment.
* - parent_title: Equivalent to title for the parent comment.
* - parent_permalink: Equivalent to permalink for the parent comment.
* - parent: A text string of parent comment submission information created from
* 'parent_author' and 'parent_created' during template_preprocess_comment().
* This information is presented to help screen readers follow lengthy
* discussion threads. You can hide this from sighted users using the class
* visually-hidden.
*
* These two variables are provided for context:
* - comment: Full comment object.
* - commented_entity: Entity the comments are attached to.
*
* @see template_preprocess_comment()
*/
#}
<article{{ attributes.addClass('js-comment') }}>
{#
Hide the "new" indicator by default, let a piece of JavaScript ask the
server which comments are new for the user. Rendering the final "new"
indicator here would break the render cache.
#}
<mark class="hidden" data-comment-timestamp="{{ new_indicator_timestamp }}"></mark>
<footer>
{{ user_picture }}
<p>{{ submitted }}</p>
{#
Indicate the semantic relationship between parent and child comments for
accessibility. The list is difficult to navigate in a screen reader
without this information.
#}
{% if parent %}
<p class="visually-hidden">{{ parent }}</p>
{% endif %}
{{ permalink }}
</footer>
<div{{ content_attributes }}>
{% if title %}
{{ title_prefix }}
<h3{{ title_attributes }}>{{ title }}</h3>
{{ title_suffix }}
{% endif %}
{{ content }}
</div>
</article>

View File

@@ -0,0 +1,20 @@
{#
/**
* @file
* Theme override 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
*/
#}
{% 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,18 @@
{#
/**
* @file
* Theme override for a missing media error.
*
* Available variables
* - message: The message text.
* - attributes: HTML attributes for the containing element.
*
* When a response from the back end can't be returned, a related error message
* is displayed from JavaScript.
*
* @see Drupal.theme.mediaEmbedPreviewError
*/
#}
<div{{ attributes }}>
{{ message }}
</div>

View File

@@ -0,0 +1,15 @@
{#
/**
* @file
* Theme override to display an oEmbed resource in an iframe.
*/
#}
<!DOCTYPE html>
<html>
<head>
<css-placeholder token="{{ placeholder_token }}">
</head>
<body style="margin: 0">
{{ media|raw }}
</body>
</html>

View File

@@ -0,0 +1,65 @@
{#
/**
* @file
* Theme override for media reference fields.
*
* @see template_preprocess_field_multiple_value_form()
*/
#}
{%
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) }}>{{ original_label }}</span>
</legend>
<div class="js-form-item form-item">
{% if media_add_help %}
<h4{{ header_attributes.addClass('label') }}>
{% trans %}
Create new media
{% endtrans %}
</h4><br />
<div class="description">
{{ media_add_help }}
</div>
{% endif %}
{% if multiple %}
{{ table }}
{% else %}
{% for element in elements %}
{{ element }}
{% endfor %}
{% endif %}
<div{{ description.attributes.addClass('description') }}>
{% if multiple and description.content %}
<ul>
<li>{{ media_list_help }} {{ media_list_link }} {{ allowed_types_help }}</li>
<li>{{ description.content }}</li>
</ul>
{% else %}
{{ media_list_help }} {{ media_list_link }} {{ allowed_types_help }}
{% endif %}
{% if multiple and button %}
<div class="clearfix">{{ button }}</div>
{% endif %}
</div>
</div>
</fieldset>

View File

@@ -0,0 +1,35 @@
{#
/**
* @file
* Theme override to present a media item.
*
* Available variables:
* - media: The media item, with limited access to object properties and
* methods. Only method names starting with "get", "has", or "is" and
* a few common methods such as "id", "label", and "bundle" are available.
* For example:
* - entity.getEntityTypeId() will return the entity type ID.
* - entity.hasField('field_example') returns TRUE if the entity includes
* field_example. (This does not indicate the presence of a value in this
* field.)
* Calling other methods, such as entity.delete(), will result in
* an exception.
* See \Drupal\Core\Entity\EntityInterface for a full list of methods.
* - name: Name of the media item.
* - content: Media content.
* - 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.
* - view_mode: View mode; for example, "teaser" or "full".
* - attributes: HTML attributes for the containing element.
* - title_attributes: Same as attributes, except applied to the main title
* tag that appears in the template.
*
* @see template_preprocess_media()
*/
#}
<div{{ attributes }}>
{{ title_suffix.contextual_links }}
{{ content }}
</div>

View File

@@ -0,0 +1,94 @@
{#
/**
* @file
* Theme override to display a node.
*
* Available variables:
* - node: The node entity with limited access to object properties and methods.
* Only method names starting with "get", "has", or "is" and a few common
* methods such as "id", "label", and "bundle" are available. For example:
* - node.getCreatedTime() will return the node creation timestamp.
* - node.hasField('field_example') returns TRUE if the node bundle includes
* field_example. (This does not indicate the presence of a value in this
* field.)
* - node.isPublished() will return whether the node is published or not.
* Calling other methods, such as node.delete(), will result in an exception.
* See \Drupal\node\Entity\Node for a full list of public properties and
* methods for the node object.
* - label: (optional) The title of the node.
* - content: All node items. Use {{ content }} to print them all,
* or print a subset such as {{ content.field_example }}. Use
* {{ content|without('field_example') }} to temporarily suppress the printing
* of a given child element.
* - author_picture: The node author user entity, rendered using the "compact"
* view mode.
* - metadata: Metadata for this node.
* - date: (optional) Themed creation date field.
* - author_name: (optional) Themed author name field.
* - url: Direct URL of the current node.
* - display_submitted: Whether submission information should be displayed.
* - attributes: HTML attributes for the containing element.
* The attributes.class element may contain one or more of the following
* classes:
* - node: The current template type (also known as a "theming hook").
* - node--type-[type]: The current node type. For example, if the node is an
* "Article" it would result in "node--type-article". Note that the machine
* name will often be in a short form of the human readable label.
* - node--view-mode-[view_mode]: The View Mode of the node; for example, a
* teaser would result in: "node--view-mode-teaser", and
* full: "node--view-mode-full".
* The following are controlled through the node publishing options.
* - node--promoted: Appears on nodes promoted to the front page.
* - node--sticky: Appears on nodes ordered above other non-sticky nodes in
* teaser listings.
* - node--unpublished: Appears on unpublished nodes visible only to site
* admins.
* - title_attributes: Same as attributes, except applied to the main title
* tag that appears in the template.
* - content_attributes: Same as attributes, except applied to the main
* content tag that appears in the template.
* - author_attributes: Same as attributes, except applied to the author of
* the node tag that appears in the template.
* - 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.
* - view_mode: View mode; for example, "teaser" or "full".
* - teaser: Flag for the teaser state. Will be true if view_mode is 'teaser'.
* - page: Flag for the full page state. Will be true if view_mode is 'full'.
* - readmore: Flag for more state. Will be true if the teaser content of the
* node cannot hold the main body content.
* - logged_in: Flag for authenticated user status. Will be true when the
* current user is a logged-in member.
* - is_admin: Flag for admin user status. Will be true when the current user
* is an administrator.
*
* @see template_preprocess_node()
*
*/
#}
<article{{ attributes }}>
{{ title_prefix }}
{% if label and not page %}
<h2{{ title_attributes }}>
<a href="{{ url }}" rel="bookmark">{{ label }}</a>
</h2>
{% endif %}
{{ title_suffix }}
{% if display_submitted %}
<footer>
{{ author_picture }}
<div{{ author_attributes }}>
{% trans %}Submitted by {{ author_name }} on {{ date }}{% endtrans %}
{{ metadata }}
</div>
</footer>
{% endif %}
<div{{ content_attributes }}>
{{ content }}
</div>
</article>

View File

@@ -0,0 +1,24 @@
{#
/**
* @file
* Theme override for a page wrapper.
*
* For consistent wrapping to {{ page }} render in all themes. The
* "data-off-canvas-main-canvas" attribute is required by the off-canvas dialog.
* This is used by the core/drupal.dialog.off_canvas library to select the
* "main canvas" page element as opposed to the "off canvas" which is the dialog
* itself. The "main canvas" element must be resized according to the width of
* the "off canvas" dialog so that no portion of the "main canvas" is obstructed
* by the off-canvas dialog. The off-canvas dialog can vary in width when opened
* and can be resized by the user. The "data-off-canvas-main-canvas" attribute
* cannot be removed without breaking the off-canvas dialog functionality.
*
* Available variables:
* - children: Contains the child elements of the page.
*/
#}
{% if children %}
<div class="dialog-off-canvas-main-canvas" data-off-canvas-main-canvas>
{{ children }}
</div>
{% endif %}

View File

@@ -0,0 +1,19 @@
{#
/**
* @file
* Theme override 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.
*/
#}
{{ title_prefix }}
{% if title %}
<h1{{ title_attributes }}>{{ title }}</h1>
{% endif %}
{{ title_suffix }}

View File

@@ -0,0 +1,69 @@
{#
/**
* @file
* Theme override for displaying a single search result.
*
* This template renders a single search result. The list of results is
* rendered using '#theme' => 'item_list', with suggestions of:
* - item_list__search_results__(plugin_id)
* - item_list__search_results
*
* Available variables:
* - url: URL of the result.
* - title: Title of the result.
* - snippet: A small preview of the result. Does not apply to user searches.
* - info: String of all the meta information ready for print. Does not apply
* to user searches.
* - plugin_id: The machine-readable name of the plugin being executed,such
* as "node_search" or "user_search".
* - 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.
* - info_split: Contains same data as info, but split into separate parts.
* - info_split.type: Node type (or item type string supplied by module).
* - info_split.user: Author of the node linked to users profile. Depends
* on permission.
* - info_split.date: Last update of the node. Short formatted.
* - info_split.comment: Number of comments output as "% comments", %
* being the count. (Depends on comment.module).
* @todo The info variable needs to be made drillable and each of these sub
* items should instead be within info and renamed info.foo, info.bar, etc.
*
* Other variables:
* - title_attributes: HTML attributes for the title.
* - content_attributes: HTML attributes for the content.
*
* Since info_split is keyed, a direct print of the item is possible.
* This array does not apply to user searches so it is recommended to check
* for its existence before printing. The default keys of 'type', 'user' and
* 'date' always exist for node searches. Modules may provide other data.
* @code
* {% if (info_split.comment) %}
* <span class="info-comment">
* {{ info_split.comment }}
* </span>
* {% endif %}
* @endcode
*
* To check for all available data within info_split, use the code below.
* @code
* <pre>
* {{ dump(info_split) }}
* </pre>
* @endcode
*
* @see template_preprocess_search_result()
*/
#}
{{ title_prefix }}
<h3{{ title_attributes }}>
<a href="{{ url }}">{{ title }}</a>
</h3>
{{ title_suffix }}
{% if snippet %}
<p{{ content_attributes }}>{{ snippet }}</p>
{% endif %}
{% if info %}
<p>{{ info }}</p>
{% endif %}

View File

@@ -0,0 +1,33 @@
{#
/**
* @file
* Theme override to display a taxonomy term.
*
* Available variables:
* - url: URL of the current term.
* - name: (optional) Name of the current term.
* - content: Items for the content of the term (fields and description).
* Use 'content' to print them all, or print a subset such as
* 'content.description'. Use the following code to exclude the
* printing of a given child element:
* @code
* {{ content|without('description') }}
* @endcode
* - attributes: HTML attributes for the wrapper.
* - page: Flag for the full page state.
* - term: The taxonomy term entity, including:
* - id: The ID of the taxonomy term.
* - bundle: Machine name of the current vocabulary.
* - view_mode: View mode, e.g. 'full', 'teaser', etc.
*
* @see template_preprocess_taxonomy_term()
*/
#}
<div{{ attributes }}>
{{ title_prefix }}
{% if name and not page %}
<h2><a href="{{ url }}">{{ name }}</a></h2>
{% endif %}
{{ title_suffix }}
{{ content }}
</div>

View File

@@ -0,0 +1,24 @@
{#
/**
* @file
* Theme override to display a status icon for a forum post.
*
* Available variables:
* - attributes: HTML attributes to be applied to the wrapper element.
* - class: HTML classes that determine which icon to display. May be one of
* 'hot', 'hot-new', 'new', 'default', 'closed', or 'sticky'.
* - title: Text alternative for the forum icon.
* - icon_title: Text alternative for the forum icon, same as above.
* - new_posts: '1' when this topic contains new posts, otherwise '0'.
* - first_new: '1' when this is the first topic with new posts, otherwise '0'.
* - icon_status: Indicates which status icon should be used.
*
* @see template_preprocess_forum_icon()
*/
#}
<div{{ attributes }}>
{% if first_new -%}
<a id="new"></a>
{%- endif %}
<span class="visually-hidden">{{ icon_title }}</span>
</div>

View File

@@ -0,0 +1,75 @@
{#
/**
* @file
* Theme override to display a list of forums and containers.
*
* Available variables:
* - forums: A collection of forums and containers to display. It is keyed to
* the numeric IDs of all child forums and containers. Each forum in forums
* contains:
* - is_container: A flag indicating if the forum can contain other
* forums. Otherwise, the forum can only contain topics.
* - depth: How deep the forum is in the current hierarchy.
* - zebra: 'even' or 'odd', used for row class.
* - icon_class: 'default' or 'new', used for forum icon class.
* - icon_title: Text alternative for the forum icon.
* - name: The name of the forum.
* - link: The URL to link to this forum.
* - description: The description field for the forum, containing:
* - value: The descriptive text for the forum.
* - new_topics: A flag indicating if the forum contains unread posts.
* - new_url: A URL to the forum's unread posts.
* - new_text: Text for the above URL, which tells how many new posts.
* - old_topics: A count of posts that have already been read.
* - num_posts: The total number of posts in the forum.
* - last_reply: Text representing the last time a forum was posted or
* commented in.
* - forum_id: Forum ID for the current forum. Parent to all items within the
* forums array.
*
* @see template_preprocess_forum_list()
*/
#}
<table>
<thead>
<tr>
<th>{{ 'Forum'|t }}</th>
<th>{{ 'Topics'|t }}</th>
<th>{{ 'Posts'|t }}</th>
<th>{{ 'Last post'|t }}</th>
</tr>
</thead>
<tbody>
{% for child_id, forum in forums %}
<tr>
<td{% if forum.is_container == true %} colspan="4"{% endif %}>
{#
Enclose the contents of this cell with X divs, where X is the
depth this forum resides at. This will allow us to use CSS
left-margin for indenting.
#}
{% if forum.depth > 0 %}{% for i in 1..forum.depth %}<div class="indent">{% endfor %}{% endif %}
<div title="{{ forum.icon_title }}">
<span class="visually-hidden">{{ forum.icon_title }}</span>
</div>
<div><a href="{{ forum.link }}">{{ forum.label }}</a></div>
{% if forum.description.value %}
<div>{{ forum.description.value }}</div>
{% endif %}
{% if forum.depth > 0 %}{% for i in 1..forum.depth %}</div>{% endfor %}{% endif %}
</td>
{% if forum.is_container == false %}
<td>
{{ forum.num_topics }}
{% if forum.new_topics == true %}
<br />
<a href="{{ forum.new_url }}">{{ forum.new_text }}</a>
{% endif %}
</td>
<td>{{ forum.num_posts }}</td>
<td>{{ forum.last_reply }}</td>
{% endif %}
</tr>
{% endfor %}
</tbody>
</table>

View File

@@ -0,0 +1,18 @@
{#
/**
* @file
* Default theme implementation to display a forum topic.
*
* Available variables:
* - title_link: The forum title link to display.
* - submitted: Indicates when and by whom a topic was submitted.
*
* @see template_preprocess_forums()
*
* @ingroup themeable
*/
#}
<div class="forum__title">
<div>{{ title_link }}</div>
<div>{{ submitted }}</div>
</div>

View File

@@ -0,0 +1,22 @@
{#
/**
* @file
* Theme override to display a forum.
*
* May contain forum containers as well as forum topics.
*
* Available variables:
* - forums: The forums to display (as processed by forum-list.html.twig).
* - topics: The topics to display.
* - topics_original: Original topics data before modification.
* - topics_pager: The topics pager.
* - forums_defined: A flag to indicate that the forums are configured.
*
* @see template_preprocess_forums()
*/
#}
{% if forums_defined %}
{{ forums }}
{{ topics }}
{{ topics_pager }}
{% endif %}

View File

@@ -0,0 +1,39 @@
{#
/**
* @file
* Theme override 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()
*/
#}
{% 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,105 @@
{#
/**
* @file
* Theme override 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.
* - header: Boolean indicating whether the cell should be rendered as a
* header (<th>) or not (<td>).
* - 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()
*/
#}
<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,22 @@
{#
/**
* @file
* Theme override for entity page title.
*
* This output from this template is nested within the page-title template as
* the title variable. This allows a further refinement of the page title
* specific to an entity.
*
* This template is only used if the additional entity type property
* 'enable_page_title_template' is set to TRUE.
*
* Available variables:
* - attributes: HTML attributes for the containing span element.
* - title: Entity label.
* - entity: Entity having a label field.
* - view_mode: View mode; for example, "teaser" or "full".
*/
#}
<span{{ attributes }}>
{{ title }}
</span>

View File

@@ -0,0 +1,43 @@
{#
/**
* @file
* Theme override for comment fields.
*
* 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.
* - 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 title output populated by modules, intended to
* be displayed after the main title tag that appears in the template.
* - comments: List of comments rendered through comment.html.twig.
* - content_attributes: HTML attributes for the form title.
* - comment_form: The 'Add new comment' form.
* - comment_display_mode: Is the comments are threaded.
* - comment_type: The comment type bundle ID for the comment field.
* - 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()
* @see comment_preprocess_field()
*/
#}
<section{{ attributes }}>
{% if comments and not label_hidden %}
{{ title_prefix }}
<h2{{ title_attributes }}>{{ label }}</h2>
{{ title_suffix }}
{% endif %}
{{ comments }}
{% if comment_form %}
<h2{{ content_attributes }}>{{ 'Add new comment'|t }}</h2>
{{ comment_form }}
{% endif %}
</section>

View File

@@ -0,0 +1,36 @@
{#
/**
* @file
* Theme override for the node created field.
*
* This is an override of field.html.twig for the node created field. See that
* template for documentation about its details and overrides.
*
* Available variables:
* - attributes: HTML attributes for the containing span element.
* - items: List of all the field items. Each item contains:
* - attributes: List of HTML attributes for each item.
* - content: The field item 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.
* - is_inline: If false, display an ordinary field.
* If true, display an inline format, suitable for inside elements such as
* <span>, <h2> and so on.
*
* @see field.html.twig
* @see node_preprocess_field__node()
*
* @todo Delete as part of https://www.drupal.org/node/3015623
*/
#}
{% if not is_inline %}
{% include "field.html.twig" %}
{% else %}
<span{{ attributes }}>
{%- for item in items -%}
{{ item.content }}
{%- endfor -%}
</span>
{% endif %}

View File

@@ -0,0 +1,36 @@
{#
/**
* @file
* Theme override for the node title field.
*
* This is an override of field.html.twig for the node title field. See that
* template for documentation about its details and overrides.
*
* Available variables:
* - attributes: HTML attributes for the containing span element.
* - items: List of all the field items. Each item contains:
* - attributes: List of HTML attributes for each item.
* - content: The field item 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.
* - is_inline: If false, display an ordinary field.
* If true, display an inline format, suitable for inside elements such as
* <span>, <h2> and so on.
*
* @see field.html.twig
* @see node_preprocess_field__node()
*
* @todo Delete as part of https://www.drupal.org/node/3015623
*/
#}
{% if not is_inline %}
{% include "field.html.twig" %}
{% else %}
<span{{ attributes }}>
{%- for item in items -%}
{{ item.content }}
{%- endfor -%}
</span>
{% endif %}

View File

@@ -0,0 +1,36 @@
{#
/**
* @file
* Theme override for the node user field.
*
* This is an override of field.html.twig for the node user field. See that
* template for documentation about its details and overrides.
*
* Available variables:
* - attributes: HTML attributes for the containing span element.
* - items: List of all the field items. Each item contains:
* - attributes: List of HTML attributes for each item.
* - content: The field item 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.
* - is_inline: If false, display an ordinary field.
* If true, display an inline format, suitable for inside elements such as
* <span>, <h2> and so on.
*
* @see field.html.twig
* @see node_preprocess_field__node()
*
* @todo Delete as part of https://www.drupal.org/node/3015623
*/
#}
{% if not is_inline %}
{% include "field.html.twig" %}
{% else %}
<span{{ attributes }}>
{%- for item in items -%}
{{ item.content }}
{%- endfor -%}
</span>
{% endif %}

View File

@@ -0,0 +1,70 @@
{#
/**
* @file
* Theme override 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()
*/
#}
{%
set title_classes = [
label_display == 'visually_hidden' ? 'visually-hidden',
]
%}
{% 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.addClass(title_classes) }}>{{ 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,20 @@
{#
/**
* @file
* Theme override to display the file entity as an audio tag.
*
* Available variables:
* - attributes: An array of HTML attributes, intended to be added to the
* audio tag.
* - files: And array of files to be added as sources for the audio tag. Each
* element is an array with the following elements:
* - file: The full file object.
* - source_attributes: An array of HTML attributes for to be added to the
* source tag.
*/
#}
<audio {{ attributes }}>
{% for file in files %}
<source {{ file.source_attributes }} />
{% endfor %}
</audio>

View File

@@ -0,0 +1,17 @@
{#
/**
* @file
* Theme override for a link to a file.
*
* Available variables:
* - attributes: The HTML attributes for the containing element.
* - link: A link to the file.
* - file_size: The size of the file.
*
* @see template_preprocess_file_link()
*/
#}
<span{{ attributes }}>{{ link }}</span>
{% if file_size %}
<span>({{ file_size }})</span>
{% endif %}

View File

@@ -0,0 +1,20 @@
{#
/**
* @file
* Theme override to display the file entity as a video tag.
*
* Available variables:
* - attributes: An array of HTML attributes, intended to be added to the
* video tag.
* - files: And array of files to be added as sources for the video tag. Each
* element is an array with the following elements:
* - file: The full file object.
* - source_attributes: An array of HTML attributes for to be added to the
* source tag.
*/
#}
<video {{ attributes }}>
{% for file in files %}
<source {{ file.source_attributes }} />
{% endfor %}
</video>

View File

@@ -0,0 +1,18 @@
{#
/**
* @file
* Theme override to display a formatted image field.
*
* Available variables:
* - image: A collection of image data.
* - image_style: An optional image style.
* - url: An optional URL the image can be linked to.
*
* @see template_preprocess_image_formatter()
*/
#}
{% if url %}
{{ link(image, url) }}
{% else %}
{{ image }}
{% endif %}

Some files were not shown because too many files have changed in this diff Show More