diff --git a/css/ckeditor-iframe.css b/css/ckeditor-iframe.css deleted file mode 100755 index 22ec3d4..0000000 --- a/css/ckeditor-iframe.css +++ /dev/null @@ -1,39 +0,0 @@ -@charset "UTF-8"; -/** - * @file - * Approximate CLF's style in CKEditor instances on the Drupal back-end. - */ -/* Captions */ -.caption > * { - background: #f3f3f3; - padding: 0.5ex; - border: 1px solid #ccc; -} - -.caption > figcaption { - border: 1px solid #ccc; - border-top: none; - padding-top: 0.5ex; - font-size: small; - text-align: center; -} - -/* Override clf's default blockquote and pre styles when captioned. */ -.caption-pre > pre, -.caption-blockquote > blockquote { - margin: 0; -} - -.caption-blockquote > figcaption::before { - content: "— "; -} - -.caption-blockquote > figcaption { - text-align: left; -} - -[dir=rtl] .caption-blockquote > figcaption { - text-align: right; -} - -/*# sourceMappingURL=ckeditor-iframe.css.map */ diff --git a/css/ckeditor5-iframe.css b/css/ckeditor5.css similarity index 84% rename from css/ckeditor5-iframe.css rename to css/ckeditor5.css index 8f48feb..3312028 100644 --- a/css/ckeditor5-iframe.css +++ b/css/ckeditor5.css @@ -4,10 +4,6 @@ * Approximate CLF's style in CKEditor instances on the Drupal back-end. */ .ck-content { - /** - * @file - * Approximate CLF's style in CKEditor instances on the Drupal back-end. - */ /* Captions */ /* Override clf's default blockquote and pre styles when captioned. */ } @@ -37,4 +33,4 @@ text-align: right; } -/*# sourceMappingURL=ckeditor5-iframe.css.map */ +/*# sourceMappingURL=ckeditor5.css.map */ diff --git a/css/components/action-links.css b/css/components/action-links.css index 274d798..7e648df 100644 --- a/css/components/action-links.css +++ b/css/components/action-links.css @@ -29,13 +29,13 @@ text-decoration: none; line-height: 160%; } -.button-action:before { +.button-action::before { margin-left: -0.1em; /* LTR */ padding-right: 0.2em; /* LTR */ content: "+"; font-weight: 900; } -[dir="rtl"] .button-action:before { +[dir="rtl"] .button-action::before { margin-right: -0.1em; margin-left: 0; padding-right: 0; diff --git a/css/components/book-navigation.css b/css/components/book-navigation.css deleted file mode 100644 index 08728e2..0000000 --- a/css/components/book-navigation.css +++ /dev/null @@ -1,40 +0,0 @@ -/** - * @file - * Styling for the Book module. - */ - -.book-navigation .menu { - padding-top: 1em; - padding-bottom: 0; -} -.book-navigation .book-pager { - overflow: auto; - margin: 0; - padding: 0.5em 0; -} -.book-pager__item { - display: inline-block; - list-style-type: none; - vertical-align: top; -} -.book-pager__item--previous { - width: 45%; - text-align: left; /* LTR */ -} -[dir="rtl"] .book-pager__item--previous { - float: right; - text-align: right; -} -.book-pager__item--center { - width: 8%; - text-align: center; -} -.book-pager__item--next { - float: right; /* LTR */ - width: 45%; - text-align: right; /* LTR */ -} -[dir="rtl"] .book-pager__item--next { - float: left; - text-align: left; -} diff --git a/css/components/breadcrumb.css b/css/components/breadcrumb.css index 1e6a7fa..1a20eaf 100644 --- a/css/components/breadcrumb.css +++ b/css/components/breadcrumb.css @@ -21,9 +21,9 @@ list-style-type: none; } /* IE8 does not support :not() and :last-child. */ -.breadcrumb li:before { +.breadcrumb li::before { content: " \BB "; } -.breadcrumb li:first-child:before { +.breadcrumb li:first-child::before { content: none; } diff --git a/css/components/collapse-processed.css b/css/components/collapse-processed.css deleted file mode 100644 index aca4c29..0000000 --- a/css/components/collapse-processed.css +++ /dev/null @@ -1,32 +0,0 @@ -/** - * @file - * Visual styles for collapsible fieldsets. - */ - -.collapse-processed > summary { - padding-right: 0.5em; - padding-left: 0.5em; -} -.collapse-processed > summary:before { - float: left; /* LTR */ - width: 1em; - height: 1em; - content: ""; - background: url(../../img/misc/menu-expanded.png) 0 100% no-repeat; /* LTR */ -} -[dir="rtl"] .collapse-processed > summary:before { - float: right; - background-position: 100% 100%; -} -.collapse-processed:not([open]) > summary:before { - -ms-transform: rotate(-90deg); - -webkit-transform: rotate(-90deg); - transform: rotate(-90deg); - background-position: 25% 35%; /* LTR */ -} -[dir="rtl"] .collapse-processed:not([open]) > summary:before { - -ms-transform: rotate(90deg); - -webkit-transform: rotate(90deg); - transform: rotate(90deg); - background-position: 75% 35%; -} diff --git a/css/components/container-inline.css b/css/components/container-inline.css index 64b78f6..1a91f17 100644 --- a/css/components/container-inline.css +++ b/css/components/container-inline.css @@ -3,12 +3,12 @@ * Inline items. */ -.container-inline label:after, -.container-inline .label:after { +.container-inline label::after, +.container-inline .label::after { content: ":"; } -.form-type-radios .container-inline label:after, -.form-type-checkboxes .container-inline label:after { +.form-type-radios .container-inline label::after, +.form-type-checkboxes .container-inline label::after { content: ""; } .form-type-radios .container-inline .form-type-radio, diff --git a/css/components/details.css b/css/components/details.css index a546363..b4165dc 100644 --- a/css/components/details.css +++ b/css/components/details.css @@ -14,9 +14,6 @@ details { details > .details-wrapper { padding: 0.5em 1.5em; } -/* @todo Regression: The summary of uncollapsible details are no longer - vertically aligned with the .details-wrapper in browsers without native - details support. */ summary { padding: 0.2em 0.5em; cursor: pointer; diff --git a/css/components/dialog.css b/css/components/dialog.css index 1afb1db..700b1a2 100644 --- a/css/components/dialog.css +++ b/css/components/dialog.css @@ -13,7 +13,8 @@ background: #fff; } -@media all and (max-width: 48em) { /* 768px */ +@media all and (max-width: 48em) { + /* 768px */ .ui-dialog { width: 92% !important; } @@ -62,7 +63,7 @@ opacity: 0.9; border-radius: 7px; background-color: #232323; - background-image: url(../../img/misc/loading-small.gif); + background-image: url(../../img/icons/loading-small.gif); background-repeat: no-repeat; background-position: center center; } diff --git a/css/components/form.css b/css/components/form.css index d4cdcb0..e3dced1 100644 --- a/css/components/form.css +++ b/css/components/form.css @@ -70,7 +70,7 @@ label.option { .marker { color: #e00; } -.form-required:after { +.form-required::after { display: inline-block; width: 6px; height: 6px; @@ -78,7 +78,7 @@ label.option { content: ""; vertical-align: super; /* Use a background image to prevent screen readers from announcing the text. */ - background-image: url(../../img/icons/ee0000/required.svg); + background-image: url(../../img/icons/required.svg); background-repeat: no-repeat; background-size: 6px 6px; } @@ -93,12 +93,12 @@ abbr.ajax-changed { } /* Inline error messages. */ -.form-item--error-message:before { +.form-item--error-message::before { display: inline-block; width: 14px; height: 14px; content: ""; vertical-align: sub; - background: url(../../img/icons/e32700/error.svg) no-repeat; + background: url(../../img/icons/error.svg) no-repeat; background-size: contain; } diff --git a/css/components/forum.css b/css/components/forum.css deleted file mode 100644 index 824cd27..0000000 --- a/css/components/forum.css +++ /dev/null @@ -1,46 +0,0 @@ -/** - * @file - * Styling for the Forum module. - */ - -.forum__description { - margin: 0.5em; - font-size: 0.9em; -} -.forum__icon { - float: left; /* LTR */ - width: 24px; - height: 24px; - margin: 0 9px 0 0; /* LTR */ - background-image: url(../../img/icons/forum-icons.png); - background-repeat: no-repeat; -} -[dir="rtl"] .forum__icon { - float: right; - margin: 0 0 0 9px; -} -.forum__title { - overflow: hidden; -} -.forum .indented { - margin-left: 20px; /* LTR */ -} -[dir="rtl"] .forum .indented { - margin-right: 20px; - margin-left: 0; -} -.forum__topic-status--new { - background-position: -24px 0; -} -.forum__topic-status--hot { - background-position: -48px 0; -} -.forum__topic-status--hot-new { - background-position: -72px 0; -} -.forum__topic-status--sticky { - background-position: -96px 0; -} -.forum__topic-status--closed { - background-position: -120px 0; -} diff --git a/css/components/icons.css b/css/components/icons.css index bed1bc9..c83cc44 100644 --- a/css/components/icons.css +++ b/css/components/icons.css @@ -5,7 +5,7 @@ .icon-help { padding: 1px 0 1px 20px; /* LTR */ - background: url(../../img/misc/help.png) 0 50% no-repeat; /* LTR */ + background: url(../../img/icons/help.png) 0 50% no-repeat; /* LTR */ } [dir="rtl"] .icon-help { padding: 1px 20px 1px 0; @@ -17,5 +17,5 @@ width: 16px; height: 16px; text-indent: -9999px; - background: url(../../img/misc/feed.svg) no-repeat; + background: url(../../img/icons/feed.svg) no-repeat; } diff --git a/css/components/image-widget.css b/css/components/image-widget.css index 56777c4..72e52a2 100644 --- a/css/components/image-widget.css +++ b/css/components/image-widget.css @@ -1,17 +1,6 @@ /** * @file * Image upload widget. - * - * This CSS file is not used in this theme (Classy). It was intended to be used, - * but due to a bug, Drupal 8 shipped with it not being used. To not break - * backwards compatibility, we continue to not load it in Classy. Every - * subtheme of Classy is encouraged to use it, by attaching the - * classy/image-widget asset library in their image-widget.html.twig file. - * - * @see core/themes/seven/templates/content-edit/image-widget.html.twig. - * - * @todo In Drupal 9, let core/themes/classy/templates/content-edit/image-widget.html.twig - * attach the classy/image-widget asset library. */ .image-preview { diff --git a/css/components/media-embed-error.css b/css/components/media-embed-error.css deleted file mode 100644 index 1125d5e..0000000 --- a/css/components/media-embed-error.css +++ /dev/null @@ -1,20 +0,0 @@ -/** - * @file - * Media Embed filter: default styling for media embed errors. - */ - -/** - * The caption filter's styling overrides ours, so add a more specific selector - * to account for that. - */ -.media-embed-error, -.caption > .media-embed-error { - max-width: 200px; - padding: 100px 20px 20px; - text-align: center; - background-color: #ebebeb; - background-image: url(../../img/icons/no-thumbnail.png); - background-repeat: no-repeat; - background-position: center top; - background-size: 100px 100px; -} diff --git a/css/components/menu.css b/css/components/menu.css index 8cf72a6..a0783e3 100644 --- a/css/components/menu.css +++ b/css/components/menu.css @@ -16,14 +16,14 @@ ul.menu { } .menu-item--expanded { list-style-type: circle; - list-style-image: url(../../img/misc/menu-expanded.png); + list-style-image: url(../../img/icons/menu-expanded.png); } .menu-item--collapsed { list-style-type: disc; - list-style-image: url(../../img/misc/menu-collapsed.png); /* LTR */ + list-style-image: url(../../img/icons/menu-collapsed.png); /* LTR */ } [dir="rtl"] .menu-item--collapsed { - list-style-image: url(../../img/misc/menu-collapsed-rtl.png); + list-style-image: url(../../img/icons/menu-collapsed-rtl.png); } .menu-item { margin: 0; diff --git a/css/components/messages.css b/css/components/messages.css index bc7c1e2..c4f5d2c 100644 --- a/css/components/messages.css +++ b/css/components/messages.css @@ -7,9 +7,9 @@ padding: 15px 20px 15px 35px; /* LTR */ word-wrap: break-word; border: 1px solid; - border-width: 1px 1px 1px 0; /* LTR */ + border-width: 1px 1px 1px 0; /* LTR */ border-radius: 2px; - background: no-repeat 10px 17px; /* LTR */ + background: no-repeat 10px 17px; /* LTR */ overflow-wrap: break-word; } [dir="rtl"] .messages { @@ -30,12 +30,11 @@ .messages__item + .messages__item { margin-top: 0.769em; } -/* See .color-success in Seven's colors.css */ .messages--status { color: #325e1c; - border-color: #c9e1bd #c9e1bd #c9e1bd transparent; /* LTR */ + border-color: #c9e1bd #c9e1bd #c9e1bd transparent; /* LTR */ background-color: #f3faef; - background-image: url(../../img/icons/73b355/check.svg); + background-image: url(../../img/icons/check.svg); box-shadow: -8px 0 0 #77b259; /* LTR */ } [dir="rtl"] .messages--status { @@ -43,24 +42,22 @@ border-color: #c9e1bd transparent #c9e1bd #c9e1bd; box-shadow: 8px 0 0 #77b259; } -/* See .color-warning in Seven's colors.css */ .messages--warning { color: #734c00; - border-color: #f4daa6 #f4daa6 #f4daa6 transparent; /* LTR */ + border-color: #f4daa6 #f4daa6 #f4daa6 transparent; /* LTR */ background-color: #fdf8ed; - background-image: url(../../img/icons/e29700/warning.svg); + background-image: url(../../img/icons/warning.svg); box-shadow: -8px 0 0 #e09600; /* LTR */ } [dir="rtl"] .messages--warning { border-color: #f4daa6 transparent #f4daa6 #f4daa6; box-shadow: 8px 0 0 #e09600; } -/* See .color-error in Seven's colors.css */ .messages--error { color: #a51b00; - border-color: #f9c9bf #f9c9bf #f9c9bf transparent; /* LTR */ + border-color: #f9c9bf #f9c9bf #f9c9bf transparent; /* LTR */ background-color: #fcf4f2; - background-image: url(../../img/icons/e32700/error.svg); + background-image: url(../../img/icons/error.svg); box-shadow: -8px 0 0 #e62600; /* LTR */ } [dir="rtl"] .messages--error { diff --git a/css/components/progress.css b/css/components/progress.css index 47da889..f8561b2 100644 --- a/css/components/progress.css +++ b/css/components/progress.css @@ -9,7 +9,6 @@ border-color: #b3b3b3; border-radius: 10em; background-color: #f2f1eb; - background-image: -webkit-linear-gradient(#e7e7df, #f0f0f0); background-image: linear-gradient(#e7e7df, #f0f0f0); box-shadow: inset 0 1px 3px hsla(0, 0%, 0%, 0.16); } @@ -21,23 +20,16 @@ -webkit-transition: width 0.5s ease-out; transition: width 0.5s ease-out; -webkit-animation: animate-stripes 3s linear infinite; - -moz-animation: animate-stripes 3s linear infinite; border: 1px #07629a solid; border-radius: 10em; background: #057ec9; - background-image: - -webkit-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15)), - -webkit-linear-gradient(left top, #0094f0 0%, #0094f0 25%, #007ecc 25%, #007ecc 50%, #0094f0 50%, #0094f0 75%, #0094f0 100%); - background-image: - linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15)), - linear-gradient(to right bottom, #0094f0 0%, #0094f0 25%, #007ecc 25%, #007ecc 50%, #0094f0 50%, #0094f0 75%, #0094f0 100%); + background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15)), linear-gradient(to right bottom, #0094f0 0%, #0094f0 25%, #007ecc 25%, #007ecc 50%, #0094f0 50%, #0094f0 75%, #0094f0 100%); background-size: 40px 40px; } [dir="rtl"] .progress__bar { margin-right: -1px; margin-left: 0; -webkit-animation-direction: reverse; - -moz-animation-direction: reverse; animation-direction: reverse; } @@ -46,24 +38,21 @@ -webkit-transition: none; transition: none; -webkit-animation: none; - -moz-animation: none; } } /** * Progress bar animations. */ -@-webkit-keyframes animate-stripes { - 0% { background-position: 0 0, 0 0; } - 100% { background-position: 0 0, -80px 0; } -} - -@-ms-keyframes animate-stripes { - 0% { background-position: 0 0, 0 0; } - 100% { background-position: 0 0, -80px 0; } -} - @keyframes animate-stripes { - 0% { background-position: 0 0, 0 0; } - 100% { background-position: 0 0, -80px 0; } + 0% { + background-position: + 0 0, + 0 0; + } + 100% { + background-position: + 0 0, + -80px 0; + } } diff --git a/css/components/ui-dialog.css b/css/components/ui-dialog.css index 476c21f..164ca86 100644 --- a/css/components/ui-dialog.css +++ b/css/components/ui-dialog.css @@ -1,6 +1,6 @@ /** * @file - * Styles for Classy's modal windows. + * Styles for modal windows. */ .ui-dialog--narrow { diff --git a/css/components/user.css b/css/components/user.css index 8baa8f8..7892fd6 100644 --- a/css/components/user.css +++ b/css/components/user.css @@ -29,7 +29,8 @@ .password-confirm, .password-field, .password-strength, -.password-confirm-match { +.password-confirm-match, +.password-confirm-message { width: 55%; } diff --git a/css/layout/media-library.css b/css/layout/media-library.css deleted file mode 100644 index 84dee10..0000000 --- a/css/layout/media-library.css +++ /dev/null @@ -1,28 +0,0 @@ -/** - * @file - * Contains minimal layout styling for the media library. - */ - -.media-library-wrapper { - display: flex; -} - -.media-library-menu { - flex-basis: 20%; - flex-shrink: 0; -} - -.media-library-content { - flex-grow: 1; -} - -.media-library-views-form { - display: flex; - flex-wrap: wrap; -} - -.media-library-views-form .media-library-item { - justify-content: space-between; - max-width: 23%; - margin: 1%; -} diff --git a/css/local-tasks.css b/css/local-tasks.css old mode 100755 new mode 100644 diff --git a/css/maintenance-page.css b/css/maintenance-page.css old mode 100755 new mode 100644 diff --git a/galactus.info.yml b/galactus.info.yml index 4e7ec22..cfbce7b 100644 --- a/galactus.info.yml +++ b/galactus.info.yml @@ -3,10 +3,12 @@ type: theme 'base theme': false description: 'Galactus is a Drupal base theme that provides integration with the UBC CLF (Common Look and Feel) for UBC-branded units. We recommend against using this theme for any customizations or modifications. If you require a customized UBC CLF theme, please consider the Drupal CLF theme' package: ubc-web-services -version: '2.1.0' -core_version_requirement: ^9.4 || ^10 -generator: 'starterkit_theme:9.5.1' +version: '3.0.0' +core_version_requirement: '>=10' + +generator: 'starterkit_theme:11.0.1' starterkit: true + libraries: - galactus/messages - core/normalize @@ -23,17 +25,9 @@ libraries-extend: - galactus/file core/drupal.progress: - galactus/progress - media/media_embed_ckeditor_theme: - - galactus/media_embed_ckeditor_theme - media_library/view: - - galactus/media_library - media_library/widget: - - galactus/media_library -ckeditor_stylesheets: - - css/components/media-embed-error.css - - css/ckeditor-iframe.css + ckeditor5-stylesheets: - - css/ckeditor5-iframe.css + - css/ckeditor5.css regions: primary_menu: 'Primary menu' diff --git a/galactus.libraries.yml b/galactus.libraries.yml index 6f1af6e..3a5423e 100644 --- a/galactus.libraries.yml +++ b/galactus.libraries.yml @@ -1,12 +1,9 @@ -# galactus.libraries.yml - base: css: component: css/components/action-links.css: {} css/components/breadcrumb.css: {} css/components/button.css: {} - css/components/collapse-processed.css: {} css/components/container-inline.css: {} css/components/details.css: {} css/components/exposed-filters.css: {} @@ -26,10 +23,7 @@ base: css/components/tabs.css: {} css/components/textarea.css: {} css/components/ui-dialog.css: {} -book-navigation: - css: - component: - css/components/book-navigation.css: {} + dialog: css: component: @@ -42,10 +36,6 @@ file: css: component: css/components/file.css: {} -forum: - css: - component: - css/components/forum.css: {} image-widget: css: component: @@ -54,10 +44,6 @@ indented: css: component: css/components/indented.css: {} -media_library: - css: - layout: - css/layout/media-library.css: {} messages: css: component: @@ -78,13 +64,6 @@ user: css: component: css/components/user.css: {} -media_embed_error: - css: - component: - css/components/media-embed-error.css: {} -media_embed_ckeditor_theme: - js: - js/media_embed_ckeditor.theme.js: {} ### Global Styles & Scripts ### global: diff --git a/galactus.theme b/galactus.theme index 1c42125..cb9ca10 100644 --- a/galactus.theme +++ b/galactus.theme @@ -438,3 +438,36 @@ function galactus_preprocess_image_widget(array &$variables) { unset($data['preview']); } } + +/** + * Implements template_preprocess_HOOK() for fieldset. + */ +function galactus_preprocess_fieldset(&$variables) { + $element = $variables['element']; + $composite_types = ['checkboxes', 'radios']; + + if (!empty($element['#type']) && in_array($element['#type'], $composite_types) && !empty($variables['element']['#children_errors'])) { + $variables['legend_span']['attributes']->addClass('has-error'); + } + + if (!empty($element['#disabled'])) { + $variables['legend_span']['attributes']->addClass('is-disabled'); + + if (!empty($variables['description']) && !empty($variables['description']['attributes'])) { + $variables['description']['attributes']->addClass('is-disabled'); + } + } + + // Remove 'container-inline' class from the main attributes and add a flag + // instead. + // @todo Remove this after https://www.drupal.org/node/3059593 has been + // resolved. + if (!empty($variables['attributes']['class'])) { + $container_inline_key = array_search('container-inline', $variables['attributes']['class']); + + if ($container_inline_key !== FALSE) { + unset($variables['attributes']['class'][$container_inline_key]); + $variables['inline_items'] = TRUE; + } + } +} diff --git a/img/icons/73b355/check.svg b/img/icons/check.svg similarity index 100% rename from img/icons/73b355/check.svg rename to img/icons/check.svg diff --git a/img/icons/e32700/error.svg b/img/icons/error.svg similarity index 100% rename from img/icons/e32700/error.svg rename to img/icons/error.svg diff --git a/img/misc/feed.svg b/img/icons/feed.svg similarity index 100% rename from img/misc/feed.svg rename to img/icons/feed.svg diff --git a/img/misc/help.png b/img/icons/help.png similarity index 100% rename from img/misc/help.png rename to img/icons/help.png diff --git a/img/misc/loading-small.gif b/img/icons/loading-small.gif similarity index 100% rename from img/misc/loading-small.gif rename to img/icons/loading-small.gif diff --git a/img/misc/menu-collapsed-rtl.png b/img/icons/menu-collapsed-rtl.png similarity index 100% rename from img/misc/menu-collapsed-rtl.png rename to img/icons/menu-collapsed-rtl.png diff --git a/img/misc/menu-collapsed.png b/img/icons/menu-collapsed.png similarity index 100% rename from img/misc/menu-collapsed.png rename to img/icons/menu-collapsed.png diff --git a/img/misc/menu-expanded.png b/img/icons/menu-expanded.png similarity index 100% rename from img/misc/menu-expanded.png rename to img/icons/menu-expanded.png diff --git a/img/icons/ee0000/required.svg b/img/icons/required.svg similarity index 100% rename from img/icons/ee0000/required.svg rename to img/icons/required.svg diff --git a/img/icons/e29700/warning.svg b/img/icons/warning.svg similarity index 100% rename from img/icons/e29700/warning.svg rename to img/icons/warning.svg diff --git a/js/media_embed_ckeditor.theme.es6.js b/js/media_embed_ckeditor.theme.es6.js deleted file mode 100644 index a33d18f..0000000 --- a/js/media_embed_ckeditor.theme.es6.js +++ /dev/null @@ -1,22 +0,0 @@ -/** - * @file - * Classy theme overrides for the Media Embed CKEditor plugin. - */ - -((Drupal) => { - /** - * Themes the error displayed when the media embed preview fails. - * - * @param {string} error - * The error message to display - * - * @return {string} - * A string representing a DOM fragment. - * - * @see media-embed-error.html.twig - */ - Drupal.theme.mediaEmbedPreviewError = () => - `
${Drupal.t( - 'An error occurred while trying to preview the media. Please save your work and reload this page.', - )}
`; -})(Drupal); diff --git a/js/media_embed_ckeditor.theme.js b/js/media_embed_ckeditor.theme.js deleted file mode 100644 index 0b9d959..0000000 --- a/js/media_embed_ckeditor.theme.js +++ /dev/null @@ -1,12 +0,0 @@ -/** -* DO NOT EDIT THIS FILE. -* See the following change record for more information, -* https://www.drupal.org/node/2815083 -* @preserve -**/ - -(function (Drupal) { - Drupal.theme.mediaEmbedPreviewError = function () { - return "
".concat(Drupal.t('An error occurred while trying to preview the media. Please save your work and reload this page.'), "
"); - }; -})(Drupal); \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 002d949..6214a4c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,6 +13,7 @@ "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", "dev": true, + "license": "ISC", "dependencies": { "normalize-path": "^3.0.0", "picomatch": "^2.0.4" @@ -26,6 +27,7 @@ "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz", "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==", "dev": true, + "license": "MIT", "engines": { "node": ">=8" }, @@ -38,6 +40,7 @@ "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", "dev": true, + "license": "MIT", "dependencies": { "fill-range": "^7.1.1" }, @@ -50,6 +53,7 @@ "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz", "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==", "dev": true, + "license": "MIT", "dependencies": { "anymatch": "~3.1.2", "braces": "~3.0.2", @@ -74,6 +78,7 @@ "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", "dev": true, + "license": "MIT", "dependencies": { "to-regex-range": "^5.0.1" }, @@ -87,6 +92,7 @@ "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, "hasInstallScript": true, + "license": "MIT", "optional": true, "os": [ "darwin" @@ -100,6 +106,7 @@ "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", "dev": true, + "license": "ISC", "dependencies": { "is-glob": "^4.0.1" }, @@ -108,16 +115,18 @@ } }, "node_modules/immutable": { - "version": "4.3.6", - "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.3.6.tgz", - "integrity": "sha512-Ju0+lEMyzMVZarkTn/gqRpdqd5dOPaz1mCZ0SH3JV6iFw81PldE/PEB1hWVEA288HPt4WXW8O7AWxB10M+03QQ==", - "dev": true + "version": "4.3.7", + "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.3.7.tgz", + "integrity": "sha512-1hqclzwYwjRDFLjcFxOM5AYkkG0rpFPpr1RLPMEuGczoS7YA8gLhy8SWXYRAA/XwfEHpfo3cw5JGioS32fnMRw==", + "dev": true, + "license": "MIT" }, "node_modules/is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", "dev": true, + "license": "MIT", "dependencies": { "binary-extensions": "^2.0.0" }, @@ -130,6 +139,7 @@ "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } @@ -139,6 +149,7 @@ "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", "dev": true, + "license": "MIT", "dependencies": { "is-extglob": "^2.1.1" }, @@ -151,6 +162,7 @@ "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.12.0" } @@ -160,6 +172,7 @@ "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.10.0" } @@ -169,6 +182,7 @@ "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", "dev": true, + "license": "MIT", "engines": { "node": ">=8.6" }, @@ -181,6 +195,7 @@ "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", "dev": true, + "license": "MIT", "dependencies": { "picomatch": "^2.2.1" }, @@ -193,6 +208,7 @@ "resolved": "https://registry.npmjs.org/sass/-/sass-1.77.8.tgz", "integrity": "sha512-4UHg6prsrycW20fqLGPShtEvo/WyHRVRHwOP4DzkUrObWoWI05QBSfzU71TVB7PFaL104TwNaHpjlWXAZbQiNQ==", "dev": true, + "license": "MIT", "dependencies": { "chokidar": ">=3.0.0 <4.0.0", "immutable": "^4.0.0", @@ -210,6 +226,7 @@ "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.0.tgz", "integrity": "sha512-itJW8lvSA0TXEphiRoawsCksnlf8SyvmFzIhltqAHluXd88pkCd+cXJVHTDwdCr0IzwptSm035IHQktUu1QUMg==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=0.10.0" } @@ -219,6 +236,7 @@ "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", "dev": true, + "license": "MIT", "dependencies": { "is-number": "^7.0.0" }, diff --git a/sass/ckeditor-iframe.scss b/sass/ckeditor-iframe.scss deleted file mode 100644 index 8c9b6b6..0000000 --- a/sass/ckeditor-iframe.scss +++ /dev/null @@ -1,34 +0,0 @@ -/** - * @file - * Approximate CLF's style in CKEditor instances on the Drupal back-end. - */ - -/* Captions */ -.caption > * { - background: #f3f3f3; - padding: 0.5ex; - border: 1px solid #ccc; -} - -.caption > figcaption { - border: 1px solid #ccc; - border-top: none; - padding-top: 0.5ex; - font-size: small; - text-align: center; -} - -/* Override clf's default blockquote and pre styles when captioned. */ -.caption-pre > pre, -.caption-blockquote > blockquote { - margin: 0; -} -.caption-blockquote > figcaption::before { - content: "— "; -} -.caption-blockquote > figcaption { - text-align: left; -} -[dir="rtl"] .caption-blockquote > figcaption { - text-align: right; -} diff --git a/sass/ckeditor5-iframe.scss b/sass/ckeditor5-iframe.scss deleted file mode 100644 index f82f92d..0000000 --- a/sass/ckeditor5-iframe.scss +++ /dev/null @@ -1,8 +0,0 @@ -/** - * @file - * Approximate CLF's style in CKEditor instances on the Drupal back-end. - */ - -.ck-content { - @import 'ckeditor-iframe'; -} diff --git a/sass/ckeditor5.scss b/sass/ckeditor5.scss new file mode 100644 index 0000000..760c1de --- /dev/null +++ b/sass/ckeditor5.scss @@ -0,0 +1,36 @@ +/** + * @file + * Approximate CLF's style in CKEditor instances on the Drupal back-end. + */ + +.ck-content { + /* Captions */ + .caption > * { + background: #f3f3f3; + padding: 0.5ex; + border: 1px solid #ccc; + } + + .caption > figcaption { + border: 1px solid #ccc; + border-top: none; + padding-top: 0.5ex; + font-size: small; + text-align: center; + } + + /* Override clf's default blockquote and pre styles when captioned. */ + .caption-pre > pre, + .caption-blockquote > blockquote { + margin: 0; + } + .caption-blockquote > figcaption::before { + content: "— "; + } + .caption-blockquote > figcaption { + text-align: left; + } + [dir="rtl"] .caption-blockquote > figcaption { + text-align: right; + } +} diff --git a/templates/block/block--search-form-block.html.twig b/templates/block/block--search-form-block.html.twig old mode 100755 new mode 100644 index 661eadc..9709c10 --- a/templates/block/block--search-form-block.html.twig +++ b/templates/block/block--search-form-block.html.twig @@ -1,31 +1,38 @@ -{# % extends "@classy/block--search-form-block.html.twig" % #} {# /** * @file - * clf's theme implementation for a search form block. + * Theme override for the search form 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, including: + * - 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. - * - content_attributes: A list of HTML attributes applied to the main content + * - attributes: A list HTML attributes populated by modules, intended to + * be added to the main container tag of this template. Includes: + * - 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() * @see search_preprocess_block() - * - * @ingroup themeable */ #} -{# % block content %} - - {{ parent() }} - - { % endblock % #} - {% set classes = [ - 'content', - 'container-inline', - ] + 'block', + 'block-search', + 'container-inline', +] %} {{ title_prefix }} diff --git a/templates/block/block--system-branding-block.html.twig b/templates/block/block--system-branding-block.html.twig index baa015b..8814363 100644 --- a/templates/block/block--system-branding-block.html.twig +++ b/templates/block/block--system-branding-block.html.twig @@ -16,7 +16,7 @@ {% block content %} {% if site_logo %} {% endif %} {% if site_name %} diff --git a/templates/block/block--system-menu-block--main.html.twig b/templates/block/block--system-menu-block--main.html.twig index 8263ea6..15f1876 100755 --- a/templates/block/block--system-menu-block--main.html.twig +++ b/templates/block/block--system-menu-block--main.html.twig @@ -9,15 +9,9 @@ * - configuration: A list of the block's configuration values. * - label: The configured label for the block. * - label_display: The display settings for the label. - * - module: The module that provided this block plugin. - * - cache: The cache settings. + * - provider: The module or other provider that provided this block plugin. * - Block plugin specific settings will also be stored here. - * - block - The full block entity. - * - label_hidden: The hidden block title value if the block was - * configured to hide the title ('label' is empty in this case). - * - module: The module that generated the block. - * - delta: An ID for the block, unique within each module. - * - region: The block region embedding the current block. + * - 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. @@ -36,8 +30,6 @@ * to or skip the links. * See http://juicystudio.com/article/screen-readers-display-none.php and * http://www.w3.org/TR/WCAG-TECHS/H42.html for more information. - * - * @ingroup themeable */ #} {% @@ -46,17 +38,17 @@ ] %} {% set heading_id = attributes.id ~ '-menu'|clean_id %} - + diff --git a/templates/block/block--system-menu-block.html.twig b/templates/block/block--system-menu-block.html.twig old mode 100755 new mode 100644 index 0f4ec80..db3f9f8 --- a/templates/block/block--system-menu-block.html.twig +++ b/templates/block/block--system-menu-block.html.twig @@ -9,15 +9,9 @@ * - configuration: A list of the block's configuration values. * - label: The configured label for the block. * - label_display: The display settings for the label. - * - module: The module that provided this block plugin. - * - cache: The cache settings. + * - provider: The module or other provider that provided this block plugin. * - Block plugin specific settings will also be stored here. - * - block - The full block entity. - * - label_hidden: The hidden block title value if the block was - * configured to hide the title ('label' is empty in this case). - * - module: The module that generated the block. - * - delta: An ID for the block, unique within each module. - * - region: The block region embedding the current block. + * - 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. diff --git a/templates/block/block.html.twig b/templates/block/block.html.twig old mode 100755 new mode 100644 index a85c82c..114d7c4 --- a/templates/block/block.html.twig +++ b/templates/block/block.html.twig @@ -9,15 +9,9 @@ * - configuration: A list of the block's configuration values. * - label: The configured label for the block. * - label_display: The display settings for the label. - * - module: The module that provided this block plugin. - * - cache: The cache settings. + * - provider: The module or other provider that provided this block plugin. * - Block plugin specific settings will also be stored here. - * - block - The full block entity. - * - label_hidden: The hidden block title value if the block was - * configured to hide the title ('label' is empty in this case). - * - module: The module that generated the block. - * - delta: An ID for the block, unique within each module. - * - region: The block region embedding the current block. + * - 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. @@ -36,6 +30,7 @@ set classes = [ 'block', 'block-' ~ configuration.provider|clean_class, + 'block-' ~ plugin_id|clean_class, ] %} diff --git a/templates/content-edit/node-edit-form.html.twig b/templates/content-edit/node-edit-form.html.twig index 18097f3..9e1ffbb 100644 --- a/templates/content-edit/node-edit-form.html.twig +++ b/templates/content-edit/node-edit-form.html.twig @@ -11,8 +11,6 @@ * * Available variables: * - form: The node add/edit form. - * - * @see seven_form_node_form_alter() */ #}
diff --git a/templates/content/aggregator-item.html.twig b/templates/content/aggregator-item.html.twig deleted file mode 100644 index 16f4428..0000000 --- a/templates/content/aggregator-item.html.twig +++ /dev/null @@ -1,31 +0,0 @@ -{# -/** - * @file - * Theme override to present a feed item in an aggregator page. - * - * Available variables: - * - url: URL to the originating feed item. - * - title: (optional) Title of the feed item. - * - content: All field 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 element. - * - attributes: HTML attributes for the wrapper. - * - 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_aggregator_item() - */ -#} - - {{ title_prefix }} - {% if title %} -

- {{ title }} -

- {% endif %} - {{ title_suffix }} - {{ content }} - diff --git a/templates/content/book-node-export-html.html.twig b/templates/content/book-node-export-html.html.twig deleted file mode 100644 index 94a4c24..0000000 --- a/templates/content/book-node-export-html.html.twig +++ /dev/null @@ -1,20 +0,0 @@ -{# -/** - * @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() - */ -#} -
-

{{ title }}

- {{ content }} - {{ children }} -
diff --git a/templates/content/comment.html.twig b/templates/content/comment.html.twig index c7bf261..fc7e40a 100644 --- a/templates/content/comment.html.twig +++ b/templates/content/comment.html.twig @@ -29,7 +29,7 @@ * - title: (optional) 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; e.g., 'theming hook'. + * - 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. diff --git a/templates/content/links--node.html.twig b/templates/content/links--node.html.twig index e6cda0d..f5ab63d 100644 --- a/templates/content/links--node.html.twig +++ b/templates/content/links--node.html.twig @@ -29,8 +29,6 @@ * http://www.w3.org/TR/WCAG-TECHS/H42.html for more information. * * @see template_preprocess_links() - * - * @ingroup themeable */ #} {% if links %} diff --git a/templates/content/media-embed-error.html.twig b/templates/content/media-embed-error.html.twig deleted file mode 100644 index b9216f1..0000000 --- a/templates/content/media-embed-error.html.twig +++ /dev/null @@ -1,21 +0,0 @@ -{# -/** - * @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 - * - * @ingroup themeable - */ -#} -{{ attach_library('galactus/media_embed_error') }} - - {{ message }} -
diff --git a/templates/content/media.html.twig b/templates/content/media.html.twig index 422030e..a982c54 100644 --- a/templates/content/media.html.twig +++ b/templates/content/media.html.twig @@ -8,8 +8,6 @@ * - content: Media content. * * @see template_preprocess_media() - * - * @ingroup themeable */ #} {% diff --git a/templates/content/node.html.twig b/templates/content/node.html.twig old mode 100755 new mode 100644 index 2b16fb7..589e412 --- a/templates/content/node.html.twig +++ b/templates/content/node.html.twig @@ -4,13 +4,18 @@ * Theme override to display a node. * * Available variables: - * - node: Full node entity. - * - id: The node ID. - * - bundle: The type of the node, for example, "page" or "article". - * - authorid: The user ID of the node author. - * - createdtime: Time the node was published formatted in Unix timestamp. - * - changedtime: Time the node was changed formatted in Unix timestamp. - * - label: The title of the node. + * - 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 @@ -18,8 +23,8 @@ * - author_picture: The node author user entity, rendered using the "compact" * view mode. * - metadata: Metadata for this node. - * - date: Themed creation date field. - * - author_name: Themed author name field. + * - 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. @@ -51,18 +56,9 @@ * - 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() * - * @todo Remove the id attribute (or make it a class), because if that gets - * rendered twice on a page this is invalid CSS for example: two lists - * in different view modes. */ #} {% @@ -75,15 +71,11 @@ view_mode ? 'node--view-mode-' ~ view_mode|clean_class, ] %} -{% - set contentClasses = [ - 'clearfix', - ] -%} +{{ attach_library('galactus/node') }} {{ title_prefix }} - {% if not page %} + {% if label and not page %} {{ label }} @@ -91,26 +83,24 @@ {{ title_suffix }} {% if display_submitted %} -
+
{{ author_picture }} {% trans %}Submitted by {{ author_name }} on {{ date }}{% endtrans %} {{ metadata }}
- + {% endif %} - + {% if not node.isPublished() %}
Unpublished
{% endif %} {{ content|without('links') }} - {% if content.links %} {% endif %} - diff --git a/templates/dataset/aggregator-feed.html.twig b/templates/dataset/aggregator-feed.html.twig deleted file mode 100644 index 9eacccb..0000000 --- a/templates/dataset/aggregator-feed.html.twig +++ /dev/null @@ -1,36 +0,0 @@ -{# -/** - * @file - * Theme override to present an aggregator feed. - * - * The contents are rendered above feed listings when browsing source feeds. - * For example, "example.com/aggregator/sources/1". - * - * Available variables: - * - title: (optional) Title of the feed item. - * - content: All field 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 element. - * - attributes: HTML attributes for the wrapper. - * - 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_aggregator_feed() - */ -#} - - - {{ title_prefix }} - {% if title and not full %} - {{ title }} - {% endif %} - {{ title_suffix }} - - {{ content }} - - diff --git a/templates/dataset/forum-icon.html.twig b/templates/dataset/forum-icon.html.twig deleted file mode 100644 index d6be503..0000000 --- a/templates/dataset/forum-icon.html.twig +++ /dev/null @@ -1,30 +0,0 @@ -{# -/** - * @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() - */ -#} -{% - set classes = [ - 'forum__icon', - 'forum__topic-status--' ~ icon_status, - ] -%} - - {% if first_new -%} - - {%- endif %} - {{ icon_title }} - diff --git a/templates/dataset/forum-list.html.twig b/templates/dataset/forum-list.html.twig deleted file mode 100644 index d8523f1..0000000 --- a/templates/dataset/forum-list.html.twig +++ /dev/null @@ -1,79 +0,0 @@ -{# -/** - * @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() - */ -#} - - - - - - - - - - - {% for child_id, forum in forums %} - - - {% if forum.is_container == false %} - - - - {% endif %} - - {% endfor %} - -
{{ 'Forum'|t }}{{ 'Topics'|t }}{{ 'Posts'|t }}{{ 'Last post'|t }}
- {# - 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 %}
{% endfor %}{% endif %} -
- {{ forum.icon_title }} -
- - {% if forum.description.value %} -
{{ forum.description.value }}
- {% endif %} - {% if forum.depth > 0 %}{% for i in 1..forum.depth %}
{% endfor %}{% endif %} -
- {{ forum.num_topics }} - {% if forum.new_topics == true %} -
- {{ forum.new_text }} - {% endif %} -
{{ forum.num_posts }}{{ forum.last_reply }}
diff --git a/templates/dataset/forums.html.twig b/templates/dataset/forums.html.twig deleted file mode 100644 index b560fdc..0000000 --- a/templates/dataset/forums.html.twig +++ /dev/null @@ -1,24 +0,0 @@ -{# -/** - * @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_pager: The topics pager. - * - forums_defined: A flag to indicate that the forums are configured. - * - * @see template_preprocess_forums() - */ -#} -{{ attach_library('galactus/forum') }} -{% if forums_defined %} -
- {{ forums }} - {{ topics }} - {{ topics_pager }} -
-{% endif %} diff --git a/templates/dataset/table.html.twig b/templates/dataset/table.html.twig old mode 100755 new mode 100644 index fc6aa0c..fb44baa --- a/templates/dataset/table.html.twig +++ b/templates/dataset/table.html.twig @@ -30,6 +30,8 @@ * - 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 () or not (). * - 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. diff --git a/templates/field/field--text.html.twig b/templates/field/field--text.html.twig index 5d1690c..41f6f01 100644 --- a/templates/field/field--text.html.twig +++ b/templates/field/field--text.html.twig @@ -21,8 +21,6 @@ * lists or other dynamic content. * * @see https://www.drupal.org/node/2539860 - * - * @ingroup themeable */ #} {% set attributes = attributes.addClass('clearfix', 'text-formatted') %} diff --git a/templates/field/file-audio.html.twig b/templates/field/file-audio.html.twig index 314bbd6..7a9c705 100644 --- a/templates/field/file-audio.html.twig +++ b/templates/field/file-audio.html.twig @@ -11,8 +11,6 @@ * - file: The full file object. * - source_attributes: An array of HTML attributes for to be added to the * source tag. -* -* @ingroup themeable */ #} {{ attach_library('galactus/file') }} diff --git a/templates/field/file-link.html.twig b/templates/field/file-link.html.twig index 029ef71..5b19703 100644 --- a/templates/field/file-link.html.twig +++ b/templates/field/file-link.html.twig @@ -10,7 +10,6 @@ * - file_size: The size of the file. * * @see template_preprocess_file_link() - * @see stable_preprocess_image_widget() */ #} {{ attach_library('galactus/file') }} diff --git a/templates/field/file-video.html.twig b/templates/field/file-video.html.twig index d33df1f..dad796e 100644 --- a/templates/field/file-video.html.twig +++ b/templates/field/file-video.html.twig @@ -11,8 +11,6 @@ * - file: The full file object. * - source_attributes: An array of HTML attributes for to be added to the * source tag. -* -* @ingroup themeable */ #} {{ attach_library('galactus/file') }} diff --git a/templates/form/container.html.twig b/templates/form/container.html.twig index 0da6c38..0e35d50 100644 --- a/templates/form/container.html.twig +++ b/templates/form/container.html.twig @@ -5,9 +5,9 @@ * * Used for grouped form items. Can also be used as a theme wrapper for any * renderable element, to surround it with a
and HTML attributes. - * See \Drupal\Core\Render\Element\RenderElement for more + * See \Drupal\Core\Render\Element\RenderElementBase for more * information on the #theme_wrappers render array property, and - * \Drupal\Core\Render\Element\container for usage of the container render + * \Drupal\Core\Render\Element\Container for usage of the container render * element. * * Available variables: diff --git a/templates/form/dropbutton-wrapper.html.twig b/templates/form/dropbutton-wrapper.html.twig index a2bdc21..930e6ef 100644 --- a/templates/form/dropbutton-wrapper.html.twig +++ b/templates/form/dropbutton-wrapper.html.twig @@ -11,7 +11,7 @@ #} {% if children %} {% apply spaceless %} -
+
{{ children }}
diff --git a/templates/form/fieldset.html.twig b/templates/form/fieldset.html.twig index 93b5f54..bd5d0e6 100644 --- a/templates/form/fieldset.html.twig +++ b/templates/form/fieldset.html.twig @@ -23,46 +23,81 @@ * - suffix: The content to add after the fieldset children. * * @see template_preprocess_fieldset() + * @see galactus_preprocess_fieldset() */ #} {% - set classes = [ - 'js-form-item', - 'form-item', - 'js-form-wrapper', - 'form-wrapper', - ] +set classes = [ + 'fieldset', + attributes.hasClass('fieldgroup') ? 'fieldset--group', + 'js-form-item', + 'form-item', + 'js-form-wrapper', + 'form-wrapper', +] %} +{% +set wrapper_classes = [ + 'fieldset__wrapper', + attributes.hasClass('fieldgroup') ? 'fieldset__wrapper--group', +] +%} +{% +set legend_span_classes = [ + 'fieldset__label', + attributes.hasClass('fieldgroup') ? 'fieldset__label--group', + required ? 'js-form-required', + required ? 'form-required', +] +%} +{% +set legend_classes = [ + 'fieldset__legend', + attributes.hasClass('fieldgroup') and not attributes.hasClass('form-composite') ? 'fieldset__legend--group', + attributes.hasClass('form-composite') ? 'fieldset__legend--composite', + title_display == 'invisible' ? 'fieldset__legend--invisible' : 'fieldset__legend--visible', +] +%} +{% +set description_classes = [ + 'fieldset__description', +] +%} + - {% - set legend_span_classes = [ - 'fieldset-legend', - required ? 'js-form-required', - required ? 'form-required', - ] - %} - {# Always wrap fieldset legends in a for CSS positioning. #} - - {{ legend.title }} - -
+ {# Always wrap fieldset legends in a for CSS positioning. #} + {% if legend.title %} + + {{ legend.title }} + + {% endif %} + + {% if description_display == 'before' and description.content %} - {{ description.content }}
- {% endif %} - {% if errors %} -
- {{ errors }} -
- {% endif %} - {% if prefix %} - {{ prefix }} - {% endif %} - {{ children }} - {% if suffix %} - {{ suffix }} + {{ description.content }}
{% endif %} - {% if description_display in ['after', 'invisible'] and description.content %} - {{ description.content }}
+ {% if inline_items %} +
+ {% endif %} + + {% if prefix %} + {{ prefix }} + {% endif %} + {{ children }} + {% if suffix %} + {{ suffix }} + {% endif %} + {% if errors %} +
+ {{ errors }} +
+ {% endif %} + {% if description_display in ['after', 'invisible'] and description.content %} + {{ description.content }}
+ {% endif %} + + {% if inline_items %} +
{% endif %} diff --git a/templates/layout/book-export-html.html.twig b/templates/layout/book-export-html.html.twig deleted file mode 100644 index b7525f7..0000000 --- a/templates/layout/book-export-html.html.twig +++ /dev/null @@ -1,45 +0,0 @@ -{# -/** - * @file - * Theme override for printed version of book outline. - * - * Available variables: - * - title: Top level node title. - * - head: Header tags. - * - language: Language object. - * - language_rtl: A flag indicating whether the current display language is a - * right to left language. - * - base_url: URL to the home page. - * - contents: Nodes within the current outline rendered through - * book-node-export-html.html.twig. - * - * @see template_preprocess_book_export_html() - */ -#} - - - - {{ title }} - {{ page.head }} - - - - - {# - The given node is embedded to its absolute depth in a top level section. - For example, a child node with depth 2 in the hierarchy is contained in - (otherwise empty) div elements corresponding to depth 0 and depth 1. This - is intended to support WYSIWYG output - e.g., level 3 sections always look - like level 3 sections, no matter their depth relative to the node selected - to be exported as printer-friendly HTML. - #} - - {% if depth > 1 %}{% for i in 1..depth-1 %} -
- {% endfor %}{% endif %} - {{ contents }} - {% if depth > 1 %}{% for i in 1..depth-1 %} -
- {% endfor %}{% endif %} - - diff --git a/templates/layout/html.html.twig b/templates/layout/html.html.twig old mode 100755 new mode 100644 index 93efce5..67707ab --- a/templates/layout/html.html.twig +++ b/templates/layout/html.html.twig @@ -8,7 +8,7 @@ * - root_path: The root path of the current page (e.g., node, admin, user). * - node_type: The content type for the current node, if the page is a node. * - head_title: List of text elements that make up the head_title variable. - * May contain or more of the following: + * May contain one or more of the following: * - title: The title of the page. * - name: The name of the site. * - slogan: The slogan of the site. diff --git a/templates/layout/page.html.twig b/templates/layout/page.html.twig old mode 100755 new mode 100644 index df0b6f8..7a941ca --- a/templates/layout/page.html.twig +++ b/templates/layout/page.html.twig @@ -19,22 +19,8 @@ * Site identity: * - front_page: The URL of the front page. Use this instead of base_path when * linking to the front page. This includes the language domain or prefix. - * - logo: The url of the logo image, as defined in theme settings. - * - site_name: The name of the site. This is empty when displaying the site - * name has been disabled in the theme settings. - * - site_slogan: The slogan of the site. This is empty when displaying the site - * slogan has been disabled in theme settings. * * Page content (in order of occurrence in the default page.html.twig): - * - 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. - * - tabs: Tabs linking to any sub-pages beneath the current page (e.g., the - * view and edit tabs when displaying a node). - * - action_links: Actions local to the page, such as "Add menu" on the menu - * administration interface. * - node: Fully loaded node, if there is an automatically-loaded node * associated with the page and the node ID is the second argument in the * page's path (e.g. node/12345 and node/12345/revisions, but not diff --git a/templates/layout/region--primary-menu.html.twig b/templates/layout/region--primary-menu.html.twig index af96a1c..90c6d37 100755 --- a/templates/layout/region--primary-menu.html.twig +++ b/templates/layout/region--primary-menu.html.twig @@ -5,21 +5,11 @@ * * Available variables: * - content: The content for this region, typically blocks. - * - attributes: HTML attributes for the region div. + * - attributes: HTML attributes for the region
. * - region: The name of the region variable as defined in the theme's * .info.yml file. * * @see template_preprocess_region() - * - * @ingroup themeable */ #} -{% - set classes = [ - 'region', - 'region-' ~ region|clean_class, - ] -%} -{% if content %} - {{ content }} -{% endif %} +{{ content }} diff --git a/templates/media-library/container--media-library-content.html.twig b/templates/media-library/container--media-library-content.html.twig deleted file mode 100644 index 7c930e2..0000000 --- a/templates/media-library/container--media-library-content.html.twig +++ /dev/null @@ -1,28 +0,0 @@ -{# -/** - * @file - * Theme implementation the content area of the modal media library dialog. - * - * The content area is everything that is not the menu of available media - * types. This includes the form to add new media items, if available, and - * the view of available media to select. - * - * Available variables: - * - attributes: HTML attributes for the containing element. - * - children: The rendered child elements of the container. - * - has_parent: A flag to indicate that the container has one or more parent - containers. - * - * @see template_preprocess_container() - * - * @ingroup themeable - */ -#} -{% - set classes = [ - has_parent ? 'js-form-wrapper', - has_parent ? 'form-wrapper', - 'media-library-content', - ] -%} -{{ children }}
diff --git a/templates/media-library/container--media-library-widget-selection.html.twig b/templates/media-library/container--media-library-widget-selection.html.twig deleted file mode 100644 index 7c0af44..0000000 --- a/templates/media-library/container--media-library-widget-selection.html.twig +++ /dev/null @@ -1,28 +0,0 @@ -{# -/** - * @file - * Theme implementation of a wrapper for selected media items. - * - * This is used to wrap around the set of media items that are currently - * selected in the media library widget (not the modal dialog), which may - * be used for entity reference fields that target media. - * - * Available variables: - * - attributes: HTML attributes for the containing element. - * - children: The rendered child elements of the container. - * - has_parent: A flag to indicate that the container has one or more parent - containers. - * - * @see template_preprocess_container() - * - * @ingroup themeable - */ -#} -{% - set classes = [ - has_parent ? 'js-form-wrapper', - has_parent ? 'form-wrapper', - 'media-library-selection', - ] -%} -{{ children }} diff --git a/templates/media-library/links--media-library-menu.html.twig b/templates/media-library/links--media-library-menu.html.twig deleted file mode 100644 index b236157..0000000 --- a/templates/media-library/links--media-library-menu.html.twig +++ /dev/null @@ -1,36 +0,0 @@ -{% extends "links.html.twig" %} -{# -/** - * @file - * Theme implementation of the media type menu in the media library dialog. - * - * Available variables: - * - attributes: Attributes for the UL containing the list of links. - * - links: Links to be output. - * Each link will have the following elements: - * - link: (optional) A render array that returns a link. See - * template_preprocess_links() for details how it is generated. - * - text: The link text. - * - attributes: HTML attributes for the list item element. - * - text_attributes: (optional) HTML attributes for the span element if no - * 'url' was supplied. - * - heading: (optional) A heading to precede the links. - * - text: The heading text. - * - level: The heading level (e.g. 'h2', 'h3'). - * - attributes: (optional) A keyed list of attributes for the heading. - * If the heading is a string, it will be used as the text of the heading and - * the level will default to 'h2'. - * - * Headings should be used on navigation menus and any list of links that - * consistently appears on multiple pages. To make the heading invisible use - * the 'visually-hidden' CSS class. Do not use 'display:none', which - * removes it from screen readers and assistive technology. Headings allow - * screen reader and keyboard only users to navigate to or skip the links. - * See http://juicystudio.com/article/screen-readers-display-none.php and - * http://www.w3.org/TR/WCAG-TECHS/H42.html for more information. - * - * @see classy_preprocess_links__media_library_menu() - * @see template_preprocess_links() - */ -#} -{% set attributes = attributes.addClass('media-library-menu') %} diff --git a/templates/media-library/media--media-library.html.twig b/templates/media-library/media--media-library.html.twig deleted file mode 100644 index e886354..0000000 --- a/templates/media-library/media--media-library.html.twig +++ /dev/null @@ -1,55 +0,0 @@ -{# -/** - * @file - * Theme override of a media item in the media library. - * - * This is used for media that the user can select from the grid of media - * items. It is not used for items that have already been selected in the - * corresponding field widget, or for items that have been previously selected - * before adding new media to the library. - * - * Available variables: - * - media: The 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: - * - 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. - * - 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. - * - url: Direct URL of the media. - * - preview_attributes: HTML attributes for the preview wrapper. - * - metadata_attributes: HTML attributes for the expandable metadata area. - * - status: Whether or not the Media is published. - * - * @see template_preprocess_media() - * - * @ingroup themeable - */ -#} - - {% if content %} - - {{ content|without('name') }} - - {% if not status %} -
{{ "unpublished" | t }}
- {% endif %} - -
- {{ name }} -
- - {% endif %} - diff --git a/templates/media-library/media-library-item--small.html.twig b/templates/media-library/media-library-item--small.html.twig deleted file mode 100644 index ba03858..0000000 --- a/templates/media-library/media-library-item--small.html.twig +++ /dev/null @@ -1,31 +0,0 @@ -{# -/** - * @file - * Default theme implementation of a media library item. - * - * This is used when displaying selected media items, either in the field - * widget or in the "Additional selected media" area when adding new - * media items in the media library modal dialog. - * - * Available variables: - * - attributes: HTML attributes for the containing element. - * - content: The content of the media library item, plus any additional - * fields or elements surrounding it. - * - * @see seven_preprocess_media_library_item__small() - * @see seven_preprocess_media_library_item__widget() - * @see template_preprocess_media_library_item() - * - * @ingroup themeable - */ -#} -{% - set classes = [ - 'media-library-item', - 'media-library-item--grid', - 'media-library-item--small', - ] -%} - - {{ content }} - diff --git a/templates/media-library/media-library-item.html.twig b/templates/media-library/media-library-item.html.twig deleted file mode 100644 index 297780e..0000000 --- a/templates/media-library/media-library-item.html.twig +++ /dev/null @@ -1,28 +0,0 @@ -{# -/** - * @file - * Default theme implementation of a media library item. - * - * This is used when displaying selected media items, either in the field - * widget or in the "Additional selected media" area when adding new - * media items in the media library modal dialog. - * - * Available variables: - * - attributes: HTML attributes for the containing element. - * - content: The content of the media library item, plus any additional - * fields or elements surrounding it. - * - * @see template_preprocess_media_library_item() - * - * @ingroup themeable - */ -#} -{% - set classes = [ - 'media-library-item', - 'media-library-item--grid', - ] -%} - - {{ content }} - diff --git a/templates/media-library/media-library-wrapper.html.twig b/templates/media-library/media-library-wrapper.html.twig deleted file mode 100644 index 4d5458a..0000000 --- a/templates/media-library/media-library-wrapper.html.twig +++ /dev/null @@ -1,21 +0,0 @@ -{# -/** - * @file - * Theme override of a container used to wrap the media library's modal dialog - * interface. - * - * Available variables: - * - attributes: HTML attributes for the containing element. - * - menu: The menu of available media types to choose from. - * - content: The form to add new media items, followed by the grid or table of - * existing media items to choose from. - * - * @see template_preprocess_media_library_wrapper() - * - * @ingroup themeable - */ -#} - - {{ menu }} - {{ content }} - diff --git a/templates/media-library/views-view-unformatted--media-library.html.twig b/templates/media-library/views-view-unformatted--media-library.html.twig deleted file mode 100644 index a94d4e2..0000000 --- a/templates/media-library/views-view-unformatted--media-library.html.twig +++ /dev/null @@ -1,35 +0,0 @@ -{# -/** - * @file - * Theme override of the media library view. - * - * This is used to display a grid of media items, in both the administrative - * interface and in the modal media library dialog's grid layout. - * - * Available variables: - * - title: The title of this group of rows. May be empty. - * - rows: A list of the view's row items. - * - attributes: The row's HTML attributes. - * - content: The row's content. - * - view: The view object. - * - default_row_class: A flag indicating whether default classes should be - * used on rows. - * - * @see template_preprocess_views_view_unformatted() - */ -#} -{% if title %} -

{{ title }}

-{% endif %} -{% for row in rows %} - {% - set row_classes = [ - default_row_class ? 'views-row', - 'media-library-item', - 'media-library-item--grid', - ] - %} - - {{- row.content -}} - -{% endfor %} diff --git a/templates/misc/help-section.html.twig b/templates/misc/help-section.html.twig deleted file mode 100644 index 6cfaa38..0000000 --- a/templates/misc/help-section.html.twig +++ /dev/null @@ -1,48 +0,0 @@ -{# -/** - * @file - * Theme override for a section of the help page. - * - * This implementation divides the links into 4 columns. - * - * 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. - */ -#} -
-

{{ title }}

-

{{ description }}

- {% if links %} - {# Calculate the column length, to divide links into 4 columns. #} - {% set size = links|length // 4 %} - {% if size * 4 < links|length %} - {% set size = size + 1 %} - {% endif %} - - {# Output the links in 4 columns. #} - {% set count = 0 %} - {% for link in links %} - {% if count == 0 %} - {# Start a new column. #} -
    - {% endif %} -
  • {{ link }}
  • - {% set count = count + 1 %} - {% if count >= size %} - {# End the current column. #} - {% set count = 0 %} -
- {% endif %} - {% endfor %} - - {# End the last column, if one is open. #} - {% if count > 0 %} -
- {% endif %} - {% else %} -

{{ empty }}

- {% endif %} - diff --git a/templates/misc/rdf-metadata.html.twig b/templates/misc/rdf-metadata.html.twig deleted file mode 100644 index acc62df..0000000 --- a/templates/misc/rdf-metadata.html.twig +++ /dev/null @@ -1,20 +0,0 @@ -{# -/** - * @file - * Theme override for empty spans with RDF attributes. - * - * The XHTML+RDFa doctype allows either or syntax to - * be used, but for maximum browser compatibility, W3C recommends the - * former when serving pages using the text/html media type, see - * http://www.w3.org/TR/xhtml1/#C_3. - * - * Available variables: - * - metadata: Each item within corresponds to its own set of attributes, - * and therefore, needs its own 'attributes' element. - * - * @see template_preprocess_rdf_metadata() - */ -#} -{% for attributes in metadata %} - -{% endfor %} diff --git a/templates/misc/status-messages.html.twig b/templates/misc/status-messages.html.twig old mode 100755 new mode 100644 index 19eedd8..5280857 --- a/templates/misc/status-messages.html.twig +++ b/templates/misc/status-messages.html.twig @@ -15,15 +15,11 @@ * Available variables: * - message_list: List of messages to be displayed, grouped by type. * - status_headings: List of all status types. - * - display: (optional) May have a value of 'status' or 'error' when only - * displaying messages of that specific type. * - attributes: HTML attributes for the element, including: * - class: HTML classes. - * - * @see template_preprocess_status_messages() */ #} - +
{% block messages %} {% for type, messages in message_list %} {% @@ -31,9 +27,11 @@ 'alert', 'alert-block', 'alert-' ~ type, + 'messages', + 'messages--' ~ type, ] %} -
+
× {% if status_headings[type] %}

{{ status_headings[type] }}

@@ -48,5 +46,8 @@ {{ messages|first }} {% endif %}
+ {# Remove type specific classes. #} + {% set attributes = attributes.removeClass(classes) %} {% endfor %} {% endblock messages %} +
diff --git a/templates/navigation/book-all-books-block.html.twig b/templates/navigation/book-all-books-block.html.twig deleted file mode 100644 index b4cb64d..0000000 --- a/templates/navigation/book-all-books-block.html.twig +++ /dev/null @@ -1,22 +0,0 @@ -{# -/** - * @file - * Theme override for rendering book outlines within a block. - * - * This template is used only when the block is configured to "show block on all - * pages", which presents multiple independent books on all pages. - * - * Available variables: - * - book_menus: Book outlines. - * - id: The parent book ID. - * - title: The parent book title. - * - menu: The top-level book links. - * - * @see template_preprocess_book_all_books_block() - */ -#} -{% for book in book_menus %} - -{% endfor %} diff --git a/templates/navigation/book-navigation.html.twig b/templates/navigation/book-navigation.html.twig deleted file mode 100644 index b6790ae..0000000 --- a/templates/navigation/book-navigation.html.twig +++ /dev/null @@ -1,56 +0,0 @@ -{# -/** - * @file - * Theme override to navigate books. - * - * Presented under nodes that are a part of book outlines. - * - * Available variables: - * - tree: The immediate children of the current node rendered as an unordered - * list. - * - current_depth: Depth of the current node within the book outline. Provided - * for context. - * - prev_url: URL to the previous node. - * - prev_title: Title of the previous node. - * - parent_url: URL to the parent node. - * - parent_title: Title of the parent node. Not printed by default. Provided - * as an option. - * - next_url: URL to the next node. - * - next_title: Title of the next node. - * - has_links: Flags TRUE whenever the previous, parent or next data has a - * value. - * - book_id: The book ID of the current outline being viewed. Same as the node - * ID containing the entire outline. Provided for context. - * - book_url: The book/node URL of the current outline being viewed. Provided - * as an option. Not used by default. - * - book_title: The book/node title of the current outline being viewed. - * - * @see template_preprocess_book_navigation() - */ -#} -{{ attach_library('galactus/book-navigation') }} -{% if tree or has_links %} - -{% endif %} diff --git a/templates/navigation/book-tree.html.twig b/templates/navigation/book-tree.html.twig deleted file mode 100644 index 94fac55..0000000 --- a/templates/navigation/book-tree.html.twig +++ /dev/null @@ -1,55 +0,0 @@ -{# -/** - * @file - * Theme override to display a book tree. - * - * Returns HTML for a wrapper for a book sub-tree. - * - * Available variables: - * - items: A nested list of book items. Each book item contains: - * - attributes: HTML attributes for the book item. - * - below: The book item child items. - * - title: The book link title. - * - url: The book link URL, instance of \Drupal\Core\Url. - * - is_expanded: TRUE if the link has visible children within the current - * book tree. - * - is_collapsed: TRUE if the link has children within the current book tree - * that are not currently visible. - * - in_active_trail: TRUE if the link is in the active trail. - */ -#} -{% import _self as book_tree %} - -{# - We call a macro which calls itself to render the full tree. - @see https://twig.symfony.com/doc/1.x/tags/macro.html -#} -{{ book_tree.book_links(items, attributes, 0) }} - -{% macro book_links(items, attributes, menu_level) %} - {% import _self as book_tree %} - {% if items %} - {% if menu_level == 0 %} - - {% else %} - - {% endif %} -{% endmacro %} diff --git a/templates/navigation/breadcrumb.html.twig b/templates/navigation/breadcrumb.html.twig old mode 100755 new mode 100644 index 6f513d3..9e84963 --- a/templates/navigation/breadcrumb.html.twig +++ b/templates/navigation/breadcrumb.html.twig @@ -8,17 +8,17 @@ */ #} {% if breadcrumb %} -
-

{{ 'Breadcrumb'|t }}

- -
+ {% endif %} diff --git a/templates/navigation/menu--main.html.twig b/templates/navigation/menu--main.html.twig index a373bcc..43244ea 100755 --- a/templates/navigation/menu--main.html.twig +++ b/templates/navigation/menu--main.html.twig @@ -11,8 +11,6 @@ * - title: The menu link title. * - url: The menu link url, instance of \Drupal\Core\Url * - localized_options: Menu link localized options. - * - * @ingroup themeable */ #} {% import _self as menus %} diff --git a/templates/navigation/menu-local-tasks.html.twig b/templates/navigation/menu-local-tasks.html.twig index 55e291c..e38dd47 100644 --- a/templates/navigation/menu-local-tasks.html.twig +++ b/templates/navigation/menu-local-tasks.html.twig @@ -5,7 +5,7 @@ * * Available variables: * - primary: HTML list items representing primary tasks. - * - secondary: HTML list items representing primary tasks. + * - secondary: HTML list items representing secondary tasks. * * Each item in these variables (primary and secondary) can be individually * themed in menu-local-task.html.twig. diff --git a/templates/navigation/menu.html.twig b/templates/navigation/menu.html.twig index 11d49ff..5d22245 100644 --- a/templates/navigation/menu.html.twig +++ b/templates/navigation/menu.html.twig @@ -9,7 +9,7 @@ * - attributes: HTML attributes for the menu item. * - below: The menu item child items. * - title: The menu link title. - * - url: The menu link url, instance of \Drupal\Core\Url + * - url: The menu link URL, instance of \Drupal\Core\Url * - localized_options: Menu link localized options. * - is_expanded: TRUE if the link has visible children within the current * menu tree. @@ -22,7 +22,7 @@ {# We call a macro which calls itself to render the full tree. - @see http://twig.sensiolabs.org/doc/tags/macro.html + @see https://twig.symfony.com/doc/3.x/tags/macro.html #} {{ menus.menu_links(items, attributes, 0) }} diff --git a/templates/navigation/pager.html.twig b/templates/navigation/pager.html.twig index 6f863fa..cb96612 100644 --- a/templates/navigation/pager.html.twig +++ b/templates/navigation/pager.html.twig @@ -5,6 +5,7 @@ * * Available variables: * - heading_id: Pagination heading ID. + * - pagination_heading_level: The heading level to use for the pager. * - items: List of pager items. * The list is keyed by the following elements: * - first: Item for the first page; not present on the first page of results. @@ -32,7 +33,7 @@ #} {% if items %}
- {% endapply %} - - {% endfor %} - - {{ remainder }} - diff --git a/templates/user/forum-submitted.html.twig b/templates/user/forum-submitted.html.twig deleted file mode 100644 index 57311e9..0000000 --- a/templates/user/forum-submitted.html.twig +++ /dev/null @@ -1,21 +0,0 @@ -{# -/** - * @file - * Theme override for a forum post submission string. - * - * The submission string indicates when and by whom a topic was submitted. - * - * Available variables: - * - author: The author of the post. - * - time: How long ago the post was created. - * - topic: An object with the raw data of the post. Potentially unsafe. Be - * sure to clean this data before printing. - * - * @see template_preprocess_forum_submitted() - */ -#} -{% if time %} - -{% else %} - {{ 'n/a'|t }} -{% endif %} diff --git a/templates/views/views-mini-pager.html.twig b/templates/views/views-mini-pager.html.twig index 4b46f2b..6a76ccd 100644 --- a/templates/views/views-mini-pager.html.twig +++ b/templates/views/views-mini-pager.html.twig @@ -5,6 +5,7 @@ * * Available variables: * - heading_id: Pagination heading ID. + * - pagination_heading_level: The heading level to use for the pager. * - items: List of pager items. * * @see template_preprocess_views_mini_pager() @@ -12,7 +13,7 @@ #} {% if items.previous or items.next %}