diff --git a/.github/workflows/test.yml b/.github/workflows/tests.yml similarity index 93% rename from .github/workflows/test.yml rename to .github/workflows/tests.yml index b2a699ae0..cb202aa6f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/tests.yml @@ -30,15 +30,15 @@ env: SIMPLETEST_BASE_URL: http://thunder-testing:8888 SKIP_TEST_CLEANUP: true # The following variable set the version that the upgrade test starts with. - DRUPAL_TESTING_UPGRADE_COMPOSER_PROJECT_VERSION: 3.0.12 - DRUPAL_TESTING_UPGRADE_DRUSH_VERSION: 10.3.6 - DRUPAL_TESTING_UPGRADE_VERSION: 6.5.4 + DRUPAL_TESTING_UPGRADE_COMPOSER_PROJECT_VERSION: 4.1.0 + DRUPAL_TESTING_UPGRADE_DRUSH_VERSION: 12.4.3 + DRUPAL_TESTING_UPGRADE_VERSION: 7.3.0 jobs: build: - runs-on: ubuntu-20.04 + runs-on: ubuntu-24.04 services: mysql: @@ -50,7 +50,7 @@ jobs: strategy: matrix: - PHP_VERSION: [ '8.1', '8.3' ] + PHP_VERSION: [ '8.3' ] env: DRUPAL_TESTING_TEST_DEPRECATION: true @@ -106,7 +106,7 @@ jobs: test-max: needs: build - runs-on: ubuntu-20.04 + runs-on: ubuntu-24.04 services: mysql: @@ -170,7 +170,7 @@ jobs: test-upgrade: - runs-on: ubuntu-20.04 + runs-on: ubuntu-24.04 services: mysql: @@ -187,7 +187,7 @@ jobs: strategy: matrix: - PHP_VERSION: [ '8.1' ] + PHP_VERSION: [ '8.3' ] if: ${{ contains(github.event.pull_request.labels.*.name, 'test-upgrade') || github.event_name == 'schedule' }} @@ -229,7 +229,7 @@ jobs: - name: Fix the old install run: | - composer upgrade caxy/php-htmldiff + composer upgrade league/container working-directory: /tmp/test/thunder/install env: COMPOSER_ROOT_VERSION: ${{ env.DRUPAL_TESTING_UPGRADE_COMPOSER_PROJECT_VERSION }} @@ -249,15 +249,13 @@ jobs: composer remove thunder/thunder-distribution --no-update composer config name "drupal-testing-thunder/thunder-distribution" --working-dir="${GITHUB_WORKSPACE}" composer require "drupal-testing-thunder/thunder-distribution:*" --no-update - composer require "drupal/ckeditor" --no-update - composer require "drupal/seven" --no-update - composer require "drupal/entity_browser" --no-update - composer require "drupal/thunder_admin" --no-update - composer require "drupal/shariff" --no-update - composer require "drupal/ctools" --no-update - composer require "drupal/core-dev:~10.0.0" --no-update + composer require "drupal/responsive_preview" --no-update + composer require "drupal/slick:^2.7" --no-update + composer require "drupal/blazy:^2.14" --no-update + composer require "drupal/core-dev:~10.3.0" --no-update composer update + composer install composer exec -- drush updb -y cd docroot @@ -281,7 +279,7 @@ jobs: test-min: - runs-on: ubuntu-20.04 + runs-on: ubuntu-24.04 services: mysql: @@ -298,7 +296,7 @@ jobs: strategy: matrix: - PHP_VERSION: [ '8.1' ] + PHP_VERSION: [ '8.3' ] if: ${{ contains(github.event.pull_request.labels.*.name, 'test-min') || github.event_name == 'schedule' }} diff --git a/CHANGELOG.md b/CHANGELOG.md index 989a9c641..1456541b0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,26 @@ # Changelog +## [7.3.3](https://github.com/thunder/thunder-distribution/tree/7.3.3) 2024-08-22 + +[Full Changelog](https://github.com/thunder/thunder-distribution/compare/7.3.2...7.3.3) + +Add search api GraphQl schema and data producer. + +## [7.3.2](https://github.com/thunder/thunder-distribution/tree/7.3.2) 2024-08-14 + +[Full Changelog](https://github.com/thunder/thunder-distribution/compare/7.3.1...7.3.2) + +* [Issue #3462165: Add focal_point patch](https://www.drupal.org/node/3462165) + +## [7.3.1](https://github.com/thunder/thunder-distribution/tree/7.3.1) 2024-06-024 + +[Full Changelog](https://github.com/thunder/thunder-distribution/compare/7.3.0...7.3.1) + +Add patches for upstream issues. + +* [Issue #3465364: Fatal error when changing password when password_policy_history is enabled](https://www.drupal.org/project/password_policy/issues/3465364) +* [Issue #3455558: There is no visible change to a toggle when pressed (but it does trigger conditional fields, value is saved, etc)](https://www.drupal.org/project/gin/issues/3455558) + ## [7.3.0](https://github.com/thunder/thunder-distribution/tree/7.1.0) 2024-06-024 [Full Changelog](https://github.com/thunder/thunder-distribution/compare/7.2.2...7.3.0) diff --git a/README.md b/README.md index 0569bc307..35e66e0a9 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ For general help using Thunder, please refer to [the official Thunder documentat ### Community support -For additional help, you can use one of this channel to ask question: +For additional help, you can use one of these channels to ask question: * [Slack](https://thunder.org/contact-us) (highly recommended for faster support) * [Twitter](https://twitter.com/ThunderCoreTeam) diff --git a/app.json b/app.json index f71f3f491..fc2b12b2e 100644 --- a/app.json +++ b/app.json @@ -2,7 +2,7 @@ "name": "Thunder CMS heroku app", "buildpacks": [ { - "url": "https://github.com/thunder/heroku-buildpack-thunder" + "url": "https://github.com/thunder/heroku-buildpack-thunder#php83" } ], "stack": "heroku-20" diff --git a/composer.json b/composer.json index f54ca7e7e..4fd83600c 100644 --- a/composer.json +++ b/composer.json @@ -40,36 +40,40 @@ }, "drupal/diff": { "Back button for comparison page": "https://www.drupal.org/files/issues/back_button_for-2853193-4.patch" + }, + "drupal/focal_point": { + "Issue #3462165: Preview results in Error: Call to a member function getDefinitions() on null": "https://www.drupal.org/files/issues/2024-07-18/Preview-results-in-Error-3462165.patch" + }, + "drupal/gin": { + "Issue #3455558: There is no visible change to a toggle when pressed (but it does trigger conditional fields, value is saved, etc)": "https://www.drupal.org/files/issues/2024-08-06/3455558-Refactor-toggle-styles-mr438.patch" } } }, "require": { - "php": ">=8.1", + "php": ">=8.3", "cweagans/composer-patches": "^1.6.5", "drupal/access_unpublished": "^1.5", "drupal/admin_toolbar": "^3.4", "drupal/autofill": "^1.1", "drupal/autosave_form": "^1.6", - "drupal/blazy": "^2.14", - "drupal/checklistapi": "^2.1", + "drupal/checklistapi": "^2.1.3", "drupal/core-recommended": "~10.3.0@stable", "drupal/config_selector": "^2.1", "drupal/config_update": "^1.7 || ^2.0", - "drupal/content_lock": "^2.1", + "drupal/content_lock": "^3.0.0-alpha2", "drupal/crop": "^2.2", - "drupal/default_content": "^1.0-alpha7||^2.0@ALPHA", "drupal/diff": "1.7", "drupal/dropzonejs": "^2.8", "drupal/empty_fields": "^1.0-alpha1", - "drupal/entity_reference_actions": "^1.1", + "drupal/entity_reference_actions": "^1.1.1", "drupal/entity_reference_revisions": "^1.3", "drupal/field_group": "^3.4", - "drupal/focal_point": "^2.1", - "drupal/facets": "^2.0.6", + "drupal/focal_point": "^2.1.1", + "drupal/facets": "^2.0.7", "drupal/gin": "3.0-rc11", "drupal/gin_toolbar": "^1.0-rc6", "drupal/graphql": "^4.7", - "drupal/inline_entity_form": "^1.0-rc14", + "drupal/inline_entity_form": "^3.0.0@rc", "drupal/ivw_integration": "^2.0", "drupal/length_indicator": "^1.2", "drupal/linkit": "^6.0-beta4", @@ -78,29 +82,28 @@ "drupal/media_entity_slideshow": "^2.0-alpha1", "drupal/media_entity_twitter": "^2.5", "drupal/media_expire": "^2.6", - "drupal/media_library_media_modify": "^1.0.0-beta16", + "drupal/media_library_media_modify": "^1.0.0", "drupal/media_file_delete": "^1.2", "drupal/metatag": "^1.26", "drupal/metatag_async_widget": "^1.0-alpha2", "drupal/paragraphs": "^1.12", "drupal/paragraphs_features": "^2.0.0-beta3", "drupal/paragraphs_paste": "^2.0-beta3", - "drupal/password_policy": "^4.0", - "drupal/pathauto": "^1.11", + "drupal/password_policy": "^4.0.3", + "drupal/pathauto": "^1.12", "drupal/responsive_preview": "^2.1", "drupal/redirect": "^1.7", "drupal/scheduler": "^2.0.2", "drupal/scheduler_content_moderation_integration": "^2.0", - "drupal/schema_metatag": "^2.4", + "drupal/schema_metatag": "^2.5", "drupal/select2": "^1.7", "drupal/search_api_mark_outdated": "^1.0", "drupal/simple_sitemap": "^4.1.6", - "drupal/slick": "^2.7", "drupal/token": "^1.7", "drupal/update_helper": "^2.0||^3.0.3||^4.0", "drupal/search_api": "^1.29", "drupal/views_bulk_edit": "^2.5", - "drupal/views_bulk_operations": "^4.0", + "drupal/views_bulk_operations": "^4.2.7", "drupal/vgwort": "^2.0@beta", "drupal/xymatic": "^1.0@beta", "npm-asset/dropzone": "^5.5.1", @@ -109,9 +112,7 @@ "npm-asset/slick-carousel": "^1.8", "npm-asset/select2": "^4.0.7", "caxy/php-htmldiff": "^0.1.14", - "webonyx/graphql-php": "^14.11.8", - "drupal/jquery_ui": "^1.6", - "drupal/jquery_ui_draggable": "^2.1" + "webonyx/graphql-php": "^14.11.8" }, "suggest": { "drupal/search_api_solr": "Provides a Apache Solr backend for the Search API module" diff --git a/config/install/filter.format.basic_html.yml b/config/install/filter.format.basic_html.yml index f19ae33a2..263720045 100644 --- a/config/install/filter.format.basic_html.yml +++ b/config/install/filter.format.basic_html.yml @@ -2,29 +2,12 @@ langcode: en status: true dependencies: module: - - blazy - editor - linkit - - slick name: 'Basic HTML' format: basic_html weight: 0 filters: - blazy_filter: - id: blazy_filter - provider: blazy - status: false - weight: 3 - settings: - media_switch: '' - hybrid_style: '' - box_style: '' - box_media_style: '' - box_caption: '' - filter_tags: - img: img - iframe: iframe - use_data_uri: '0' editor_file_reference: id: editor_file_reference provider: editor @@ -71,47 +54,3 @@ filters: weight: 0 settings: title: true - slick_filter: - id: slick_filter - provider: slick - status: false - weight: 4 - settings: - caption: - alt: '0' - title: '0' - optionset: default - layout: '' - background: false - box_caption: '' - box_caption_custom: '' - box_media_style: '' - loading: '' - responsive_image_style: '' - box_style: '' - image_style: '' - media_switch: '' - ratio: '' - thumbnail_style: '' - grid: '' - grid_medium: '' - grid_small: '' - style: '' - skin: '' - overridables: - arrows: '0' - autoplay: '0' - dots: '0' - draggable: '0' - infinite: '0' - mouseWheel: '0' - randomize: '0' - variableWidth: '0' - optionset_thumbnail: '' - skin_thumbnail: '' - thumbnail_caption: '' - thumbnail_effect: '' - thumbnail_position: '' - override: false - preserve_keys: false - visible_items: null diff --git a/config/install/filter.format.full_html.yml b/config/install/filter.format.full_html.yml index 97add11da..fe166b6d5 100644 --- a/config/install/filter.format.full_html.yml +++ b/config/install/filter.format.full_html.yml @@ -2,29 +2,12 @@ langcode: en status: true dependencies: module: - - blazy - editor - linkit - - slick name: 'Full HTML' format: full_html weight: 2 filters: - blazy_filter: - id: blazy_filter - provider: blazy - status: false - weight: 3 - settings: - media_switch: '' - hybrid_style: '' - box_style: '' - box_media_style: '' - box_caption: '' - filter_tags: - img: img - iframe: iframe - use_data_uri: '0' editor_file_reference: id: editor_file_reference provider: editor @@ -71,47 +54,3 @@ filters: weight: 0 settings: title: true - slick_filter: - id: slick_filter - provider: slick - status: false - weight: 4 - settings: - caption: - alt: '0' - title: '0' - optionset: default - layout: '' - background: false - box_caption: '' - box_caption_custom: '' - box_media_style: '' - loading: '' - responsive_image_style: '' - box_style: '' - image_style: '' - media_switch: '' - ratio: '' - thumbnail_style: '' - grid: '' - grid_medium: '' - grid_small: '' - style: '' - skin: '' - overridables: - arrows: '0' - autoplay: '0' - dots: '0' - draggable: '0' - infinite: '0' - mouseWheel: '0' - randomize: '0' - variableWidth: '0' - optionset_thumbnail: '' - skin_thumbnail: '' - thumbnail_caption: '' - thumbnail_effect: '' - thumbnail_position: '' - override: false - preserve_keys: false - visible_items: null diff --git a/config/install/filter.format.restricted_html.yml b/config/install/filter.format.restricted_html.yml index 8aff2a2ac..2772061b2 100644 --- a/config/install/filter.format.restricted_html.yml +++ b/config/install/filter.format.restricted_html.yml @@ -1,28 +1,10 @@ langcode: en status: true -dependencies: - module: - - blazy - - slick +dependencies: { } name: 'Restricted HTML' format: restricted_html weight: 1 filters: - blazy_filter: - id: blazy_filter - provider: blazy - status: false - weight: 3 - settings: - media_switch: '' - hybrid_style: '' - box_style: '' - box_media_style: '' - box_caption: '' - filter_tags: - img: img - iframe: iframe - use_data_uri: '0' filter_autop: id: filter_autop provider: filter @@ -45,47 +27,3 @@ filters: weight: 0 settings: filter_url_length: 72 - slick_filter: - id: slick_filter - provider: slick - status: false - weight: 4 - settings: - caption: - alt: '0' - title: '0' - optionset: default - layout: '' - background: false - box_caption: '' - box_caption_custom: '' - box_media_style: '' - loading: '' - responsive_image_style: '' - box_style: '' - image_style: '' - media_switch: '' - ratio: '' - thumbnail_style: '' - grid: '' - grid_medium: '' - grid_small: '' - style: '' - skin: '' - overridables: - arrows: '0' - autoplay: '0' - dots: '0' - draggable: '0' - infinite: '0' - mouseWheel: '0' - randomize: '0' - variableWidth: '0' - optionset_thumbnail: '' - skin_thumbnail: '' - thumbnail_caption: '' - thumbnail_effect: '' - thumbnail_position: '' - override: false - preserve_keys: false - visible_items: null diff --git a/config/install/user.role.editor.yml b/config/install/user.role.editor.yml index 7002b33fa..89b5fa4e6 100644 --- a/config/install/user.role.editor.yml +++ b/config/install/user.role.editor.yml @@ -20,7 +20,6 @@ dependencies: - media - node - path - - responsive_preview - scheduler - system - taxonomy @@ -37,7 +36,6 @@ permissions: - 'access contextual links' - 'access files overview' - 'access media overview' - - 'access responsive preview' - 'access tokens overview' - 'access toolbar' - 'administer menu' diff --git a/config/install/user.role.restricted_editor.yml b/config/install/user.role.restricted_editor.yml index 5ba4d7272..8b74a5ad5 100644 --- a/config/install/user.role.restricted_editor.yml +++ b/config/install/user.role.restricted_editor.yml @@ -20,7 +20,6 @@ dependencies: - media - node - path - - responsive_preview - scheduler - system - taxonomy @@ -35,7 +34,6 @@ permissions: - 'access contextual links' - 'access files overview' - 'access media overview' - - 'access responsive preview' - 'access tokens overview' - 'access toolbar' - 'break content lock' diff --git a/config/install/user.role.seo.yml b/config/install/user.role.seo.yml index e4ba12e84..dcffbd6f9 100644 --- a/config/install/user.role.seo.yml +++ b/config/install/user.role.seo.yml @@ -22,7 +22,6 @@ dependencies: - node - path - redirect - - responsive_preview - scheduler - system - taxonomy @@ -40,7 +39,6 @@ permissions: - 'access contextual links' - 'access files overview' - 'access media overview' - - 'access responsive preview' - 'access tokens overview' - 'access toolbar' - 'administer menu' diff --git a/config/install/views.view.media_library.yml b/config/install/views.view.media_library.yml index a329d29c4..c50075a9b 100644 --- a/config/install/views.view.media_library.yml +++ b/config/install/views.view.media_library.yml @@ -136,6 +136,7 @@ display: type: mini options: offset: 0 + pagination_heading_level: h4 items_per_page: 24 total_pages: null id: 0 @@ -150,7 +151,6 @@ display: items_per_page_options_all_label: '- All -' offset: false offset_label: Offset - pagination_heading_level: h4 exposed_form: type: basic options: @@ -466,29 +466,7 @@ display: - url.query_args - user - user.permissions - tags: - - 'config:core.entity_view_display.media.gallery.default' - - 'config:core.entity_view_display.media.gallery.media_library' - - 'config:core.entity_view_display.media.gallery.paragraph_preview' - - 'config:core.entity_view_display.media.image.default' - - 'config:core.entity_view_display.media.image.media_library' - - 'config:core.entity_view_display.media.image.paragraph_preview' - - 'config:core.entity_view_display.media.image.slick' - - 'config:core.entity_view_display.media.image.thumbnail' - - 'config:core.entity_view_display.media.instagram.default' - - 'config:core.entity_view_display.media.instagram.media_library' - - 'config:core.entity_view_display.media.instagram.paragraph_preview' - - 'config:core.entity_view_display.media.instagram.thumbnail' - - 'config:core.entity_view_display.media.pinterest.default' - - 'config:core.entity_view_display.media.pinterest.media_library' - - 'config:core.entity_view_display.media.pinterest.paragraph_preview' - - 'config:core.entity_view_display.media.twitter.default' - - 'config:core.entity_view_display.media.twitter.media_library' - - 'config:core.entity_view_display.media.twitter.paragraph_preview' - - 'config:core.entity_view_display.media.video.default' - - 'config:core.entity_view_display.media.video.media_library' - - 'config:core.entity_view_display.media.video.paragraph_preview' - - 'config:core.entity_view_display.media.video.thumbnail' + tags: { } page: id: page display_title: Page @@ -784,29 +762,7 @@ display: - url.query_args - user - user.permissions - tags: - - 'config:core.entity_view_display.media.gallery.default' - - 'config:core.entity_view_display.media.gallery.media_library' - - 'config:core.entity_view_display.media.gallery.paragraph_preview' - - 'config:core.entity_view_display.media.image.default' - - 'config:core.entity_view_display.media.image.media_library' - - 'config:core.entity_view_display.media.image.paragraph_preview' - - 'config:core.entity_view_display.media.image.slick' - - 'config:core.entity_view_display.media.image.thumbnail' - - 'config:core.entity_view_display.media.instagram.default' - - 'config:core.entity_view_display.media.instagram.media_library' - - 'config:core.entity_view_display.media.instagram.paragraph_preview' - - 'config:core.entity_view_display.media.instagram.thumbnail' - - 'config:core.entity_view_display.media.pinterest.default' - - 'config:core.entity_view_display.media.pinterest.media_library' - - 'config:core.entity_view_display.media.pinterest.paragraph_preview' - - 'config:core.entity_view_display.media.twitter.default' - - 'config:core.entity_view_display.media.twitter.media_library' - - 'config:core.entity_view_display.media.twitter.paragraph_preview' - - 'config:core.entity_view_display.media.video.default' - - 'config:core.entity_view_display.media.video.media_library' - - 'config:core.entity_view_display.media.video.paragraph_preview' - - 'config:core.entity_view_display.media.video.thumbnail' + tags: { } widget: id: widget display_title: Widget @@ -1137,29 +1093,7 @@ display: - url - url.query_args - user.permissions - tags: - - 'config:core.entity_view_display.media.gallery.default' - - 'config:core.entity_view_display.media.gallery.media_library' - - 'config:core.entity_view_display.media.gallery.paragraph_preview' - - 'config:core.entity_view_display.media.image.default' - - 'config:core.entity_view_display.media.image.media_library' - - 'config:core.entity_view_display.media.image.paragraph_preview' - - 'config:core.entity_view_display.media.image.slick' - - 'config:core.entity_view_display.media.image.thumbnail' - - 'config:core.entity_view_display.media.instagram.default' - - 'config:core.entity_view_display.media.instagram.media_library' - - 'config:core.entity_view_display.media.instagram.paragraph_preview' - - 'config:core.entity_view_display.media.instagram.thumbnail' - - 'config:core.entity_view_display.media.pinterest.default' - - 'config:core.entity_view_display.media.pinterest.media_library' - - 'config:core.entity_view_display.media.pinterest.paragraph_preview' - - 'config:core.entity_view_display.media.twitter.default' - - 'config:core.entity_view_display.media.twitter.media_library' - - 'config:core.entity_view_display.media.twitter.paragraph_preview' - - 'config:core.entity_view_display.media.video.default' - - 'config:core.entity_view_display.media.video.media_library' - - 'config:core.entity_view_display.media.video.paragraph_preview' - - 'config:core.entity_view_display.media.video.thumbnail' + tags: { } widget_table: id: widget_table display_title: 'Widget (table)' diff --git a/config/optional/core.entity_view_display.media.gallery.default.yml b/config/optional/core.entity_view_display.media.gallery.default.yml index 475dd765b..cd80797ee 100644 --- a/config/optional/core.entity_view_display.media.gallery.default.yml +++ b/config/optional/core.entity_view_display.media.gallery.default.yml @@ -3,98 +3,24 @@ status: true dependencies: config: - field.field.media.gallery.field_media_images - - image.style.gallery - media.type.gallery module: - empty_fields - - slick id: media.gallery.default targetEntityType: media bundle: gallery mode: default content: field_media_images: - type: slick_media + type: entity_reference_entity_view label: hidden settings: - caption: - field_copyright: field_copyright - field_description: '0' - field_expires: '0' - field_image: '0' - field_tags: '0' - optionset: thunder_gallery - class: '' - id: '' - image: '' - link: '' - overlay: '' - title: field_description - vanilla: true - layout: below - view_mode: slick - cache: 0 - skin: classic - style: '' - background: false - box_caption: '' - box_caption_custom: '' - box_media_style: '' - responsive_image_style: '' - box_style: '' - image_style: gallery - media_switch: '' - ratio: '' - thumbnail_style: '' - grid: '0' - grid_medium: '0' - grid_small: '0' - breakpoints: - xs: - width: '' - image_style: '' - sm: - width: '' - image_style: '' - md: - width: '' - image_style: '' - lg: - width: '' - image_style: '' - xl: - width: '' - image_style: '' - current_view_mode: default - fx: '' - icon: '' - sizes: '' - grid_header: '' - overridables: - arrows: '0' - autoplay: '0' - dots: '0' - draggable: '0' - infinite: '0' - mouseWheel: '0' - randomize: '0' - variableWidth: '0' - thumbnail: '' - optionset_thumbnail: '' - skin_thumbnail: '' - thumbnail_caption: '' - thumbnail_effect: '' - thumbnail_position: '' - override: false - skin_arrows: '' - skin_dots: '' - use_theme_field: false - preserve_keys: false - visible_items: 0 + view_mode: default + link: false third_party_settings: empty_fields: handler: '' - weight: 0 + weight: 1 region: content hidden: created: true diff --git a/config/optional/core.entity_view_display.media.image.default.yml b/config/optional/core.entity_view_display.media.image.default.yml index 6258980ea..ae9349d6d 100644 --- a/config/optional/core.entity_view_display.media.image.default.yml +++ b/config/optional/core.entity_view_display.media.image.default.yml @@ -11,8 +11,8 @@ dependencies: - image.style.media_image - media.type.image module: - - blazy - empty_fields + - image id: media.image.default targetEntityType: media bundle: image @@ -27,33 +27,13 @@ content: weight: 1 region: content field_image: - type: blazy + type: image label: hidden settings: - caption: - title: '0' - alt: '0' - layout: '' - view_mode: '' - cache: 0 - skin: '' - lazy: '' - style: '' - background: false - box_caption: '' - box_caption_custom: '' - box_media_style: '' - loading: '' - preload: false - responsive_image_style: '' - box_style: '' + image_link: '' image_style: media_image - media_switch: '' - ratio: '' - thumbnail_style: '' - grid: '' - grid_medium: '' - grid_small: '' + image_loading: + attribute: lazy third_party_settings: empty_fields: handler: '' diff --git a/config/optional/core.entity_view_display.media.image.slick.yml b/config/optional/core.entity_view_display.media.image.slick.yml deleted file mode 100644 index 17189fdba..000000000 --- a/config/optional/core.entity_view_display.media.image.slick.yml +++ /dev/null @@ -1,94 +0,0 @@ -langcode: en -status: true -dependencies: - config: - - core.entity_view_mode.media.slick - - field.field.media.image.field_copyright - - field.field.media.image.field_description - - field.field.media.image.field_expires - - field.field.media.image.field_image - - field.field.media.image.field_source - - field.field.media.image.field_tags - - image.style.media_image - - media.type.image - module: - - blazy - - empty_fields -id: media.image.slick -targetEntityType: media -bundle: image -mode: slick -content: - field_copyright: - type: string - label: hidden - settings: - link_to_entity: false - third_party_settings: { } - weight: 1 - region: content - field_image: - type: blazy - label: hidden - settings: - caption: - title: '0' - alt: '0' - layout: '' - view_mode: '' - cache: 0 - skin: '' - style: '' - background: false - box_caption: '' - box_caption_custom: '' - box_media_style: '' - responsive_image_style: '' - box_style: '' - image_style: media_image - media_switch: '' - ratio: '' - thumbnail_style: '' - grid: '0' - grid_medium: '0' - grid_small: '0' - breakpoints: - xs: - width: '' - image_style: '' - sm: - width: '' - image_style: '' - md: - width: '' - image_style: '' - lg: - width: '' - image_style: '' - xl: - width: '' - image_style: '' - current_view_mode: slick - fx: '' - icon: '' - sizes: '' - grid_header: '' - third_party_settings: - empty_fields: - handler: '' - weight: 0 - region: content -hidden: - created: true - field_brands: true - field_channel: true - field_description: true - field_events: true - field_expires: true - field_people: true - field_source: true - field_tags: true - langcode: true - name: true - thumbnail: true - uid: true diff --git a/config/optional/image.style.media_image_tablet.yml b/config/optional/image.style.media_image_tablet.yml index c2d4b7d65..62b315850 100644 --- a/config/optional/image.style.media_image_tablet.yml +++ b/config/optional/image.style.media_image_tablet.yml @@ -19,4 +19,4 @@ effects: id: image_convert weight: 2 data: - extension: webp \ No newline at end of file + extension: webp diff --git a/config/optional/slick.optionset.thunder_gallery.yml b/config/optional/slick.optionset.thunder_gallery.yml deleted file mode 100644 index f1ab43240..000000000 --- a/config/optional/slick.optionset.thunder_gallery.yml +++ /dev/null @@ -1,75 +0,0 @@ -langcode: en -status: false -dependencies: - enforced: - module: - - slick -id: thunder_gallery -name: thunder_gallery -weight: -10 -label: 'Thunder Gallery' -group: '' -skin: default -breakpoints: 0 -optimized: false -options: - options__active_tab: edit-options-settings - settings: - mobileFirst: false - asNavFor: '' - accessibility: true - regionLabel: carousel - useGroupRole: true - instructionsText: '' - adaptiveHeight: false - autoplay: false - useAutoplayToggleButton: true - pauseIcon: slick-pause-icon - playIcon: slick-play-icon - pauseOnHover: true - pauseOnDotsHover: false - pauseOnFocus: true - autoplaySpeed: 3000 - arrows: true - prevArrow: Previous - nextArrow: Next - arrowsPlacement: '' - downArrow: false - downArrowTarget: '' - downArrowOffset: 0 - centerMode: true - centerPadding: 0px - dots: false - dotsClass: slick-dots - appendDots: $(element) - draggable: true - fade: false - focusOnSelect: false - infinite: true - initialSlide: 0 - lazyLoad: blazy - mouseWheel: false - randomize: false - respondTo: window - rtl: false - rows: 1 - slidesPerRow: 1 - slide: '' - slidesToShow: 1 - slidesToScroll: 1 - speed: 500 - swipe: true - swipeToSlide: false - edgeFriction: 0.35 - touchMove: true - touchThreshold: 5 - useCSS: true - cssEase: ease - cssEaseBezier: '' - cssEaseOverride: '' - useTransform: true - easing: linear - variableWidth: false - vertical: false - verticalSwiping: false - waitForAnimate: true diff --git a/config/update/thunder_post_update_0004_remove_blazy_and_slick.yml b/config/update/thunder_post_update_0004_remove_blazy_and_slick.yml new file mode 100644 index 000000000..79193f507 --- /dev/null +++ b/config/update/thunder_post_update_0004_remove_blazy_and_slick.yml @@ -0,0 +1,603 @@ +filter.format.basic_html: + expected_config: + filters: + blazy_filter: + id: blazy_filter + provider: blazy + settings: + box_caption: '' + box_media_style: '' + box_style: '' + filter_tags: + iframe: iframe + img: img + hybrid_style: '' + media_switch: '' + use_data_uri: '0' + status: false + weight: 3 + slick_filter: + id: slick_filter + provider: slick + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + caption: + alt: '0' + title: '0' + grid: '' + grid_medium: '' + grid_small: '' + image_style: '' + layout: '' + loading: '' + media_switch: '' + optionset: default + optionset_thumbnail: '' + overridables: + arrows: '0' + autoplay: '0' + dots: '0' + draggable: '0' + infinite: '0' + mouseWheel: '0' + randomize: '0' + variableWidth: '0' + override: false + preserve_keys: false + ratio: '' + responsive_image_style: '' + skin: '' + skin_thumbnail: '' + style: '' + thumbnail_caption: '' + thumbnail_effect: '' + thumbnail_position: '' + thumbnail_style: '' + visible_items: null + status: false + weight: 4 + update_actions: + delete: + filters: + blazy_filter: + id: blazy_filter + provider: blazy + settings: + box_caption: '' + box_media_style: '' + box_style: '' + filter_tags: + iframe: iframe + img: img + hybrid_style: '' + media_switch: '' + use_data_uri: '0' + status: false + weight: 3 + slick_filter: + id: slick_filter + provider: slick + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + caption: + alt: '0' + title: '0' + grid: '' + grid_medium: '' + grid_small: '' + image_style: '' + layout: '' + loading: '' + media_switch: '' + optionset: default + optionset_thumbnail: '' + overridables: + arrows: '0' + autoplay: '0' + dots: '0' + draggable: '0' + infinite: '0' + mouseWheel: '0' + randomize: '0' + variableWidth: '0' + override: false + preserve_keys: false + ratio: '' + responsive_image_style: '' + skin: '' + skin_thumbnail: '' + style: '' + thumbnail_caption: '' + thumbnail_effect: '' + thumbnail_position: '' + thumbnail_style: '' + visible_items: null + status: false + weight: 4 +filter.format.full_html: + expected_config: + filters: + blazy_filter: + id: blazy_filter + provider: blazy + settings: + box_caption: '' + box_media_style: '' + box_style: '' + filter_tags: + iframe: iframe + img: img + hybrid_style: '' + media_switch: '' + use_data_uri: '0' + status: false + weight: 3 + slick_filter: + id: slick_filter + provider: slick + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + caption: + alt: '0' + title: '0' + grid: '' + grid_medium: '' + grid_small: '' + image_style: '' + layout: '' + loading: '' + media_switch: '' + optionset: default + optionset_thumbnail: '' + overridables: + arrows: '0' + autoplay: '0' + dots: '0' + draggable: '0' + infinite: '0' + mouseWheel: '0' + randomize: '0' + variableWidth: '0' + override: false + preserve_keys: false + ratio: '' + responsive_image_style: '' + skin: '' + skin_thumbnail: '' + style: '' + thumbnail_caption: '' + thumbnail_effect: '' + thumbnail_position: '' + thumbnail_style: '' + visible_items: null + status: false + weight: 4 + update_actions: + delete: + filters: + blazy_filter: + id: blazy_filter + provider: blazy + settings: + box_caption: '' + box_media_style: '' + box_style: '' + filter_tags: + iframe: iframe + img: img + hybrid_style: '' + media_switch: '' + use_data_uri: '0' + status: false + weight: 3 + slick_filter: + id: slick_filter + provider: slick + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + caption: + alt: '0' + title: '0' + grid: '' + grid_medium: '' + grid_small: '' + image_style: '' + layout: '' + loading: '' + media_switch: '' + optionset: default + optionset_thumbnail: '' + overridables: + arrows: '0' + autoplay: '0' + dots: '0' + draggable: '0' + infinite: '0' + mouseWheel: '0' + randomize: '0' + variableWidth: '0' + override: false + preserve_keys: false + ratio: '' + responsive_image_style: '' + skin: '' + skin_thumbnail: '' + style: '' + thumbnail_caption: '' + thumbnail_effect: '' + thumbnail_position: '' + thumbnail_style: '' + visible_items: null + status: false + weight: 4 +filter.format.restricted_html: + expected_config: + filters: + blazy_filter: + id: blazy_filter + provider: blazy + settings: + box_caption: '' + box_media_style: '' + box_style: '' + filter_tags: + iframe: iframe + img: img + hybrid_style: '' + media_switch: '' + use_data_uri: '0' + status: false + weight: 3 + slick_filter: + id: slick_filter + provider: slick + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + caption: + alt: '0' + title: '0' + grid: '' + grid_medium: '' + grid_small: '' + image_style: '' + layout: '' + loading: '' + media_switch: '' + optionset: default + optionset_thumbnail: '' + overridables: + arrows: '0' + autoplay: '0' + dots: '0' + draggable: '0' + infinite: '0' + mouseWheel: '0' + randomize: '0' + variableWidth: '0' + override: false + preserve_keys: false + ratio: '' + responsive_image_style: '' + skin: '' + skin_thumbnail: '' + style: '' + thumbnail_caption: '' + thumbnail_effect: '' + thumbnail_position: '' + thumbnail_style: '' + visible_items: null + status: false + weight: 4 + update_actions: + delete: + filters: + blazy_filter: + id: blazy_filter + provider: blazy + settings: + box_caption: '' + box_media_style: '' + box_style: '' + filter_tags: + iframe: iframe + img: img + hybrid_style: '' + media_switch: '' + use_data_uri: '0' + status: false + weight: 3 + slick_filter: + id: slick_filter + provider: slick + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + caption: + alt: '0' + title: '0' + grid: '' + grid_medium: '' + grid_small: '' + image_style: '' + layout: '' + loading: '' + media_switch: '' + optionset: default + optionset_thumbnail: '' + overridables: + arrows: '0' + autoplay: '0' + dots: '0' + draggable: '0' + infinite: '0' + mouseWheel: '0' + randomize: '0' + variableWidth: '0' + override: false + preserve_keys: false + ratio: '' + responsive_image_style: '' + skin: '' + skin_thumbnail: '' + style: '' + thumbnail_caption: '' + thumbnail_effect: '' + thumbnail_position: '' + thumbnail_style: '' + visible_items: null + status: false + weight: 4 +core.entity_view_display.media.gallery.default: + expected_config: + content: + field_media_images: + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + breakpoints: + lg: + image_style: '' + width: '' + md: + image_style: '' + width: '' + sm: + image_style: '' + width: '' + xl: + image_style: '' + width: '' + xs: + image_style: '' + width: '' + cache: 0 + caption: + field_copyright: field_copyright + field_description: '0' + field_expires: '0' + field_image: '0' + field_tags: '0' + class: '' + current_view_mode: default + fx: '' + grid: '0' + grid_header: '' + grid_medium: '0' + grid_small: '0' + icon: '' + id: '' + image: '' + image_style: gallery + layout: below + link: '' + media_switch: '' + optionset: thunder_gallery + optionset_thumbnail: '' + overlay: '' + overridables: + arrows: '0' + autoplay: '0' + dots: '0' + draggable: '0' + infinite: '0' + mouseWheel: '0' + randomize: '0' + variableWidth: '0' + override: false + preserve_keys: false + ratio: '' + responsive_image_style: '' + sizes: '' + skin: classic + skin_arrows: '' + skin_dots: '' + skin_thumbnail: '' + style: '' + thumbnail: '' + thumbnail_caption: '' + thumbnail_effect: '' + thumbnail_position: '' + thumbnail_style: '' + title: field_description + use_theme_field: false + vanilla: true + view_mode: slick + visible_items: 0 + type: slick_media + weight: 0 + update_actions: + delete: + content: + field_media_images: + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + breakpoints: + lg: + image_style: '' + width: '' + md: + image_style: '' + width: '' + sm: + image_style: '' + width: '' + xl: + image_style: '' + width: '' + xs: + image_style: '' + width: '' + cache: 0 + caption: + field_copyright: field_copyright + field_description: '0' + field_expires: '0' + field_image: '0' + field_tags: '0' + class: '' + current_view_mode: default + fx: '' + grid: '0' + grid_header: '' + grid_medium: '0' + grid_small: '0' + icon: '' + id: '' + image: '' + image_style: gallery + layout: below + media_switch: '' + optionset: thunder_gallery + optionset_thumbnail: '' + overlay: '' + overridables: + arrows: '0' + autoplay: '0' + dots: '0' + draggable: '0' + infinite: '0' + mouseWheel: '0' + randomize: '0' + variableWidth: '0' + override: false + preserve_keys: false + ratio: '' + responsive_image_style: '' + sizes: '' + skin: classic + skin_arrows: '' + skin_dots: '' + skin_thumbnail: '' + style: '' + thumbnail: '' + thumbnail_caption: '' + thumbnail_effect: '' + thumbnail_position: '' + thumbnail_style: '' + title: field_description + use_theme_field: false + vanilla: true + visible_items: 0 + change: + content: + field_media_images: + settings: + link: false + view_mode: default + type: entity_reference_entity_view + weight: 1 +core.entity_view_display.media.image.default: + expected_config: + content: + field_image: + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + cache: 0 + caption: + alt: '0' + title: '0' + grid: '' + grid_medium: '' + grid_small: '' + layout: '' + lazy: '' + loading: '' + media_switch: '' + preload: false + ratio: '' + responsive_image_style: '' + skin: '' + style: '' + thumbnail_style: '' + view_mode: '' + type: blazy + update_actions: + delete: + content: + field_image: + settings: + background: false + box_caption: '' + box_caption_custom: '' + box_media_style: '' + box_style: '' + cache: 0 + caption: + alt: '0' + title: '0' + grid: '' + grid_medium: '' + grid_small: '' + layout: '' + lazy: '' + loading: '' + media_switch: '' + preload: false + ratio: '' + responsive_image_style: '' + skin: '' + style: '' + thumbnail_style: '' + view_mode: '' + change: + content: + field_image: + settings: + image_link: '' + image_loading: + attribute: lazy + type: image diff --git a/docs/README.md b/docs/README.md index 2c135cb83..45d2fae69 100644 --- a/docs/README.md +++ b/docs/README.md @@ -50,9 +50,6 @@ Public License to further enhance Thunder. * **Mobile Friendly**: With the Thunder installation, you get a responsive theme for frontend and backend. When writing an article, you can check how your text will look on different smartphones and tablets with the help of the device preview. -* **Demo Content and Guided Tour**: We added demo content and a guided tour to make it easier for newcomers to - understand how Thunder works. Step by step, we explain how to add an article, how to edit an article, or how to add - and sort channels. * **Flexible System**: With Thunder, you get a system with a very high scalability. It's extendable with more than 2500 modules to fit every need. Plus, it's themeable. * **Big Drupal community**: Benefit from an active community with more than 100.000 user actively contributing and more diff --git a/docs/contributing.md b/docs/contributing.md index 8047b2cb2..92a695c82 100644 --- a/docs/contributing.md +++ b/docs/contributing.md @@ -214,49 +214,6 @@ php ./core/scripts/db-tools.php dump-database-d8-mysql | gzip > thunder.sql.gz export thunderDumpFile=/path/to/thunder.sql.gz ``` -### How to run the NightwatchJS performance tests - -1. You need to install [Yarn](https://yarnpkg.com). Please check the installation documentation for it. -2. You have to install `thunder/thunder_performance_measurement` package. To do that, execute the following command in - your project root directory: `composer require thunder/thunder_performance_measurement:dev-master --dev` and enable - the module by executing: `drush en thunder_performance_measurement` in your `docroot` directory. -3. You need to install [Elastic APM Node.js Agent](https://www.npmjs.com/package/elastic-apm-node) in Drupal Core node - packages. To do that go to your `docroot/core` directory and execute the following - command: `yarn add elastic-apm-node --dev` -4. You have to adjust your `.env` file inside `docroot/core` directory. You can copy the `.env.example` to `.env` and - edit it accordingly. Thunder tests require the following environment variables: `DRUPAL_TEST_BASE_URL` - , `THUNDER_BRANCH`, `THUNDER_SITE_HOSTNAME` and `THUNDER_APM_URL`. The `THUNDER_BRANCH` is the branch name where - tests are executing, for example, `8.x-4.x`. The `THUNDER_SITE_HOSTNAME` is the hostname where tests are executing, - for example, `thunder.dev`. The `THUNDER_APM_URL` is URL to Elastic APM Server, for example, `http://localhost:8200`. -5. After that, you can run NightwatchJS tests by executing the following command inside `docroot/core` - directory: `yarn test:nightwatch `. Here is an - example: `yarn test:nightwatch ../profiles/contrib/thunder/tests/src/Nightwatch/Tests/CreateMostUsedContent.js` - -#### If you have a problem with outdated chromedriver - -Drupal core does not update javascript dependencies so fast and chromedriver may be outdated and unable to work with -chrome installed on the system. You can provide chrome that can be used by chromedriver inside a docker container. You -can do it with the following command: - -```bash -docker run --name selenium_chrome -d -P -p 6000:5900 -p 4444:4444 --shm-size 256m --add-host="thunder.dd:172.16.123.1" selenium/standalone-chrome-debug:3.141.59-selenium -``` - -You have to find what is correct docker image tag for the chrome version you need. To do that you have to take a look -at [selenium docker releases](https://github.com/SeleniumHQ/docker-selenium/releases). This workflow is similar to PHP -JavaScript tests and for additional information, you can take a look at **How to run the tests** section. - -After you have running chrome in docker, you have also to change environment variables in `.env` file. The following -environment variable should be set: - -```bash -DRUPAL_TEST_WEBDRIVER_PORT=4444 -DRUPAL_TEST_WEBDRIVER_PATH_PREFIX=/wd/hub -DRUPAL_TEST_CHROMEDRIVER_AUTOSTART=false -``` - -You can copy/paste this section to the bottom of your `.env` file. - ## Documentation To help with the documentation, please run: diff --git a/docs/developer-guide/migration/migrate-7-8.md b/docs/developer-guide/migration/migrate-7-8.md index 53026603b..6e8636cdf 100644 --- a/docs/developer-guide/migration/migrate-7-8.md +++ b/docs/developer-guide/migration/migrate-7-8.md @@ -31,9 +31,19 @@ drush updb You should at least see the Thunder XXXX schema update. If not, double check that the correct version of Thunder is installed, and that `drush updb` did not throw any errors. -Before you start with the code and database update please disable the jQuery UI Draggable module or require it on your own. +Before you start with the code and database update please add the Slick module, the Blazy module and the Responsive +Preview module to your own composer.json. Both are no longer part of Thunder and can be removed after the update +was successfully executed. ```bash -composer require drupal/jquery_ui_draggable +composer require drupal/blazy drupal/slick drupal/responsive_preview ``` +Also, if you have jquery_ui, jquery_ui_draggable or default_content enabled, you have to +require them own your own, since Thunder removed them from the distribution. + +```bash +composer require drupal/jquery_ui +composer require drupal/jquery_ui_draggable +composer require drupal/default_content +``` diff --git a/docs/user-guide/feature-overview.md b/docs/user-guide/feature-overview.md index c3a706408..84f13a2e5 100644 --- a/docs/user-guide/feature-overview.md +++ b/docs/user-guide/feature-overview.md @@ -46,10 +46,6 @@ all administration pages.\ Once your field input was customized the autofill functionality will be detached.\ [https://www.drupal.org/project/autofill](https://www.drupal.org/project/autofill) -**Blazy**: Lazy load and multi-serve images to save bandwidth and server requests. The user will have faster load times -and save data usage if they don't browse the whole page. A friend of mobile devices.\ -[https://www.drupal.org/project/blazy](https://www.drupal.org/project/blazy) - **Content Lock**: When a user is editing a node, any other user that attempts to edit the same node will be blocked from doing so, and notified that the content is already being edited.\ [https://www.drupal.org/project/content_lock](https://www.drupal.org/project/content_lock) @@ -127,10 +123,6 @@ system that uses tokens which the administrator can change.\ **Redirect**: The Redirect module automatically adds redirects if the URL of an article has been changed.\ [https://www.drupal.org/project/redirect](https://www.drupal.org/project/redirect) -**Responsive Preview**: The Responsive Preview module provides editors with a quick way to preview how their site's -pages will appear at narrow and wide width dimensions on different devices.\ -[https://www.drupal.org/project/responsive_preview](https://www.drupal.org/project/responsive_preview) - **Scheduler**: Scheduler gives content editors the ability to schedule nodes to be published and unpublished at specified dates and times in the future. Dates can be entered either as plain text or with calendar popups.\ [https://www.drupal.org/project/scheduler](https://www.drupal.org/project/scheduler) @@ -145,9 +137,6 @@ and usability. Sitemaps generated by this module adhere to the new Google standa creating hreflang sitemaps and image sitemaps.\ [https://www.drupal.org/project/simple_sitemap](https://www.drupal.org/project/simple_sitemap) -**Slick**: Slick is a powerful and performant slideshow/carousel solution.\ -[https://www.drupal.org/project/slick](https://www.drupal.org/project/slick) - **Token**: Provides additional tokens not supported by core (most notably fields), as well as a UI for browsing tokens.\ [https://www.drupal.org/project/token](https://www.drupal.org/project/token) diff --git a/modules/thunder_article/src/Breadcrumb/ThunderArticleBreadcrumbBuilder.php b/modules/thunder_article/src/Breadcrumb/ThunderArticleBreadcrumbBuilder.php index 0aa578d63..1f4ee5d9c 100644 --- a/modules/thunder_article/src/Breadcrumb/ThunderArticleBreadcrumbBuilder.php +++ b/modules/thunder_article/src/Breadcrumb/ThunderArticleBreadcrumbBuilder.php @@ -10,6 +10,7 @@ use Drupal\Core\Link; use Drupal\Core\Routing\RouteMatchInterface; use Drupal\Core\StringTranslation\StringTranslationTrait; +use Drupal\taxonomy\TermStorageInterface; /** * Class to define the menu_link breadcrumb builder. @@ -17,68 +18,12 @@ class ThunderArticleBreadcrumbBuilder implements BreadcrumbBuilderInterface { use StringTranslationTrait; - /** - * The router request context. - * - * @var \Drupal\Core\Routing\RequestContext - */ - protected $context; - - /** - * The menu link access service. - * - * @var \Drupal\Core\Access\AccessManagerInterface - */ - protected $accessManager; - - /** - * The dynamic router service. - * - * @var \Symfony\Component\Routing\Matcher\RequestMatcherInterface - */ - protected $router; - - /** - * The dynamic router service. - * - * @var \Drupal\Core\PathProcessor\InboundPathProcessorInterface - */ - protected $pathProcessor; - - /** - * Site configFactory object. - * - * @var \Drupal\Core\Config\ConfigFactoryInterface - */ - protected $configFactory; - - /** - * The title resolver. - * - * @var \Drupal\Core\Controller\TitleResolverInterface - */ - protected $titleResolver; - - /** - * The current user object. - * - * @var \Drupal\Core\Session\AccountInterface - */ - protected $currentUser; - - /** - * The entity repository service. - * - * @var \Drupal\Core\Entity\EntityRepositoryInterface - */ - protected $entityRepository; - /** * The taxonomy storage. * * @var \Drupal\taxonomy\TermStorageInterface */ - protected $termStorage; + protected TermStorageInterface $termStorage; /** * Constructs the ThunderArticleBreadcrumbBuilder. @@ -93,10 +38,8 @@ class ThunderArticleBreadcrumbBuilder implements BreadcrumbBuilderInterface { * @throws \Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException * @throws \Drupal\Component\Plugin\Exception\PluginNotFoundException */ - public function __construct(EntityTypeManagerInterface $entityTypeManager, EntityRepositoryInterface $entityRepository, ConfigFactoryInterface $configFactory) { - $this->entityRepository = $entityRepository; + public function __construct(EntityTypeManagerInterface $entityTypeManager, protected readonly EntityRepositoryInterface $entityRepository, protected readonly ConfigFactoryInterface $configFactory) { $this->termStorage = $entityTypeManager->getStorage('taxonomy_term'); - $this->configFactory = $configFactory; } /** @@ -106,7 +49,7 @@ public function applies(RouteMatchInterface $route_match): bool { // This breadcrumb apply only for all articles. $parameters = $route_match->getParameters()->all(); if (($route_match->getRouteName() === 'entity.node.canonical') && is_object($parameters['node'])) { - return $parameters['node']->getType() == 'article'; + return $parameters['node']->getType() === 'article'; } return FALSE; } @@ -125,7 +68,7 @@ public function build(RouteMatchInterface $route_match): Breadcrumb { // Add all parent forums to breadcrumbs. /** @var \Drupal\taxonomy\TermInterface|NULL $term */ - $term = !empty($node->field_channel) ? $node->field_channel->entity : NULL; + $term = $node->field_channel->entity ?? NULL; $links = []; if ($term) { @@ -139,7 +82,7 @@ public function build(RouteMatchInterface $route_match): Breadcrumb { $links[] = Link::createFromRoute($term->getName(), 'entity.taxonomy_term.canonical', ['taxonomy_term' => $term->id()]); } } - if (!$links || '/' . $links[0]->getUrl()->getInternalPath() != $this->configFactory->get('system.site')->get('page.front')) { + if (!$links || '/' . $links[0]->getUrl()->getInternalPath() !== $this->configFactory->get('system.site')->get('page.front')) { array_unshift($links, Link::createFromRoute($this->t('Home'), '')); } diff --git a/modules/thunder_article/src/Form/NodeRevisionRevertDefaultForm.php b/modules/thunder_article/src/Form/NodeRevisionRevertDefaultForm.php index 458a72c50..170b95684 100644 --- a/modules/thunder_article/src/Form/NodeRevisionRevertDefaultForm.php +++ b/modules/thunder_article/src/Form/NodeRevisionRevertDefaultForm.php @@ -22,33 +22,17 @@ class NodeRevisionRevertDefaultForm extends ConfirmFormBase { * * @var \Drupal\node\NodeInterface */ - protected $revision; - - /** - * The date formatter service. - * - * @var \Drupal\Core\Datetime\DateFormatterInterface - */ - protected $dateFormatter; - - /** - * The time service. - * - * @var \Drupal\Component\Datetime\TimeInterface - */ - protected $time; + protected NodeInterface $revision; /** * Constructs a new NodeRevisionRevertForm. * - * @param \Drupal\Core\Datetime\DateFormatterInterface $date_formatter + * @param \Drupal\Core\Datetime\DateFormatterInterface $dateFormatter * The date formatter service. * @param \Drupal\Component\Datetime\TimeInterface $time * The time service. */ - public function __construct(DateFormatterInterface $date_formatter, TimeInterface $time) { - $this->dateFormatter = $date_formatter; - $this->time = $time; + public function __construct(protected readonly DateFormatterInterface $dateFormatter, protected readonly TimeInterface $time) { } /** diff --git a/modules/thunder_article/src/Plugin/Derivative/DynamicLocalTasks.php b/modules/thunder_article/src/Plugin/Derivative/DynamicLocalTasks.php index 6397b73a2..760f5d474 100644 --- a/modules/thunder_article/src/Plugin/Derivative/DynamicLocalTasks.php +++ b/modules/thunder_article/src/Plugin/Derivative/DynamicLocalTasks.php @@ -18,44 +18,20 @@ class DynamicLocalTasks extends DeriverBase implements ContainerDeriverInterface use StringTranslationTrait; - /** - * The module handler service. - * - * @var \Drupal\Core\Extension\ModuleHandlerInterface - */ - protected $moduleHandler; - - /** - * The route provider service. - * - * @var \Drupal\Core\Routing\RouteProviderInterface - */ - protected $routeProvider; - - /** - * The config factory service. - * - * @var \Drupal\Core\Config\ConfigFactoryInterface - */ - protected $configFactory; - /** * Creates an DynamicLocalTasks object. * * @param \Drupal\Core\StringTranslation\TranslationInterface $string_translation * The translation manager. - * @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler + * @param \Drupal\Core\Extension\ModuleHandlerInterface $moduleHandler * The module handler service. - * @param \Drupal\Core\Routing\RouteProviderInterface $route_provider + * @param \Drupal\Core\Routing\RouteProviderInterface $routeProvider * The route provider service. - * @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory + * @param \Drupal\Core\Config\ConfigFactoryInterface $configFactory * The config factory service. */ - public function __construct(TranslationInterface $string_translation, ModuleHandlerInterface $module_handler, RouteProviderInterface $route_provider, ConfigFactoryInterface $config_factory) { + public function __construct(TranslationInterface $string_translation, protected readonly ModuleHandlerInterface $moduleHandler, protected readonly RouteProviderInterface $routeProvider, protected readonly ConfigFactoryInterface $configFactory) { $this->stringTranslation = $string_translation; - $this->moduleHandler = $module_handler; - $this->routeProvider = $route_provider; - $this->configFactory = $config_factory; } /** diff --git a/modules/thunder_article/src/ThunderNodeFormHelper.php b/modules/thunder_article/src/ThunderNodeFormHelper.php index 555df2096..8f648f0dd 100644 --- a/modules/thunder_article/src/ThunderNodeFormHelper.php +++ b/modules/thunder_article/src/ThunderNodeFormHelper.php @@ -10,23 +10,15 @@ /** * Base for handler for node add/edit forms. */ -class ThunderNodeFormHelper implements ContainerInjectionInterface { - - /** - * The theme manager. - * - * @var \Drupal\Core\Theme\ThemeManagerInterface - */ - protected ThemeManagerInterface $themeManager; +readonly class ThunderNodeFormHelper implements ContainerInjectionInterface { /** * Constructs a ThunderNodeFormHelper object. * - * @param \Drupal\Core\Theme\ThemeManagerInterface $theme_manager + * @param \Drupal\Core\Theme\ThemeManagerInterface $themeManager * The theme manager. */ - final public function __construct(ThemeManagerInterface $theme_manager) { - $this->themeManager = $theme_manager; + final public function __construct(protected ThemeManagerInterface $themeManager) { } /** diff --git a/modules/thunder_demo/README.md b/modules/thunder_demo/README.md deleted file mode 100644 index 2c5c8586a..000000000 --- a/modules/thunder_demo/README.md +++ /dev/null @@ -1,6 +0,0 @@ -# Thunder demo - -This module is just for demonstration purpose. It provides some demo content and introduces -a [tour](https://www.drupal.org/documentation/modules/tour). - -The tour guides you through Thunder and explains it's features. diff --git a/modules/thunder_demo/config/install/tour.tour.content-add.yml b/modules/thunder_demo/config/install/tour.tour.content-add.yml deleted file mode 100644 index 5dbf58846..000000000 --- a/modules/thunder_demo/config/install/tour.tour.content-add.yml +++ /dev/null @@ -1,84 +0,0 @@ -langcode: en -status: true -dependencies: - module: - - thunder_demo -id: content-add -label: 'Add new content' -module: thunder_demo -routes: - - - route_name: node.add - route_params: - node_type: article -tips: - article: - id: article - plugin: text - label: 'Article creation page' - body: '

On this step we''ll explain you the different parts of an article.

Let''s start!

' - weight: 1 - article-channel: - id: article-channel - plugin: text - label: 'Channel selection' - body: '

Channels reflect the site structure. Administrators can easily add, remove, modify and organize them using a simple UI.

Choose the one in which your article will be published.

' - weight: 2 - selector: '#edit-field-channel' - article-title: - id: article-title - plugin: text - label: Title - body: '

Enter the title of your article, which is used as main heading of your article.

' - weight: 3 - selector: '#edit-title-wrapper' - article-seo-title: - id: article-seo-title - plugin: text - label: Seo-Title - body: '

Enter the same or a different title, which is optimized for search engines.

It will be used to generate the url and as browser title.

' - weight: 4 - selector: '#edit-field-seo-title-wrapper' - article-teaser-media: - id: article-teaser-media - plugin: text - label: 'Teaser media' - body: '

Enter the information that will be used for teasers (on the front page for example). First upload or select a teaser image by clicking on the "Select entities" button.

Take your time! I am not going anywhere. ;)

' - weight: 5 - selector: '#edit-field-teaser-media' - article-teaser-text: - id: article-teaser-text - plugin: text - label: 'Teaser text' - body: '

Type the text which will appear at the front page and which will be used for Facebook and Google-Snippets, too.

' - weight: 6 - selector: '#edit-field-teaser-text-wrapper' - article-paragraphs: - id: article-paragraphs - plugin: text - label: Paragraphs - body: '

The paragraphs section represents the main article content. Here you can add your text and various types of media. It is easier to explain this part on an existing article, which we''ll do on our next stop.

But let me show you few more neat things first.

' - weight: 7 - selector: '.paragraphs-container .fieldset-legend' - article-advanced: - id: article-advanced - plugin: text - label: Advanced - body: '

They let you configure advanced settings related to the article. You will use this part when dealing with SEO, article promotion, scheduling, etc.

Click on the section titles to expand them and see what they offer.

' - weight: 8 - position: left - selector: '#edit-advanced' - article-actions: - id: article-actions - plugin: text - label: 'Main actions' - body: '

You can preview, save, publish and unpublish the article here.

Try clicking the down arrow in the "Save and continue" button to reveal the hidden options.

' - weight: 9 - position: top-start - selector: '#edit-actions' - article-last: - id: article-last - plugin: text - label: 'What is next?' - body: '

You have just learned how to create an article. What do you want to do next?

Ah, right! I promised you that I''ll teach you more about paragraphs.' - weight: 10 diff --git a/modules/thunder_demo/config/install/tour.tour.content-list.yml b/modules/thunder_demo/config/install/tour.tour.content-list.yml deleted file mode 100644 index 8ab825dff..000000000 --- a/modules/thunder_demo/config/install/tour.tour.content-list.yml +++ /dev/null @@ -1,64 +0,0 @@ -langcode: en -status: true -dependencies: - module: - - thunder_demo -id: content-list -label: 'Content listing' -module: thunder_demo -routes: - - - route_name: view.content.page_1 - - - route_name: system.admin_content -tips: - first: - id: first - plugin: text - label: 'Content listing page' - body: '

We are on the content lising page. It allows you to browse your content, see some details, edit and execute actions on it.

Let''s go step by step.

' - weight: 1 - filters: - id: filters - plugin: text - label: Filters - body: '

Filters can be used to search the content based on author, type, title and other parameters. Hit "Filter" when you entered the desired values.

' - weight: 2 - selector: '#views-exposed-form-content-page-1' - actions: - id: actions - plugin: text - label: Actions - body: '

They let you execute actions on multiple content items at once. Check which actions are offered in the drop-down.

' - weight: 3 - selector: '#edit-node-bulk-form--2' - actions-checkbox: - id: actions-checkbox - plugin: text - label: Actions - body: '

In order to define which items to execute an action on use the checkboxes. The one in the header row will select all items on a page and the ones in the rows below will select corresponding individual items.

' - weight: 4 - position: right - selector: '.views-table .select-all' - sort: - id: sort - plugin: text - label: Sorting - body: '

Click on the links in the header row to sort the list. Arrow next to the active sort link indicates the sort direction (ascending or descending).

' - weight: 5 - position: top - selector: '.views-table #view-changed-table-column' - operations: - id: operations - plugin: text - label: 'Content operations' - body: '

Use content operations dropbutton to edit or delete a given content item.

' - weight: 6 - position: left - selector: '.views-table tr:nth-child(2) .views-field-operations' - last: - id: last - plugin: text - label: 'That is it for now' - body: '

Nice! Let us just mention that it is very easy to modify most of things on this page (as it is the case with any listing in Thunder). A very powerful module called "Views" can be used to do that. Details about it are out of scope for this tour. For now just keep in mind that you will be able to tweak it if you need to.

This is it for now. I hope that you enjoyed our company. Now you can navigate back to the front page and start exploring on your own.' - weight: 7 diff --git a/modules/thunder_demo/config/install/tour.tour.content-paragraphs.yml b/modules/thunder_demo/config/install/tour.tour.content-paragraphs.yml deleted file mode 100644 index 46f3d53a0..000000000 --- a/modules/thunder_demo/config/install/tour.tour.content-paragraphs.yml +++ /dev/null @@ -1,83 +0,0 @@ -langcode: en -status: true -dependencies: - module: - - thunder_demo -id: content-paragraphs -label: 'Introduction to paragraphs' -module: thunder_demo -routes: - - - route_name: entity.node.edit_form - route_params: - node: '3' -tips: - article-paragraphs: - id: article-paragraphs - plugin: text - label: Paragraphs - body: '

The paragraphs section represents the main article content. Here you can add your text and various types of media.

' - weight: 1 - selector: '.paragraphs-container .fieldset-legend' - article-paragraphs-actions: - id: article-paragraphs-actions - plugin: text - label: 'Paragraph actions' - body: '

Each paragraph comes with it''s actions, which let you edit or remove it.

' - weight: 2 - position: left - selector: '#field-paragraphs-0-edit--2' - article-paragraphs-text: - id: article-paragraphs-text - plugin: text - label: Text - body: '

This is a simple text paragraph with a WYSIWYG editor.

' - weight: 3 - position: left - selector: '#edit-field-paragraphs-0-top' - article-paragraphs-video: - id: article-paragraphs-video - plugin: text - label: Video - body: '

This is a video. You can select one from the library or upload a new one.

' - weight: 4 - position: left - selector: '#edit-field-paragraphs-1-top' - article-paragraphs-twitter: - id: article-paragraphs-twitter - plugin: text - label: Twitter - body: '

In order to display an Twitter card just paste in the url of the post and Thunder will do the rest for you. How smart!

' - weight: 5 - position: left - selector: '#edit-field-paragraphs-3-top' - article-paragraphs-gallery: - id: article-paragraphs-gallery - plugin: text - label: Gallery - body: '

This is a gallery. By using the "Edit" button you''re able to add or delete images and change their order.

' - weight: 6 - position: left - selector: '#edit-field-paragraphs-8-top' - article-paragraphs-more: - id: article-paragraphs-more - plugin: text - label: 'Add paragraphs in between' - body: '

Use this kind of button to add another paragraph at the place you like!

' - weight: 7 - position: top - selector: '#field-paragraphs-values .paragraphs-features__add-in-between__button' - article-paragraphs-drag: - id: article-paragraphs-drag - plugin: text - label: 'Reorder paragprahs' - body: '

Activate the sort mode to easily reorder your paragraphs.

' - weight: 8 - position: right - selector: '#field-paragraphs-values .tabledrag-toggle-checkbox' - article-paragraphs-last: - id: article-paragraphs-last - plugin: text - label: 'What a tool!' - body: '

Amazed? You should be! Paragraphs are a great tool that lets you structure your content the way you need it to be. It is specially useful if you''re planning to publish the content to various destinations such as smartphones, TVs and tablets.

Now we''ve learned how to create content. It is time to see where we can manage it.

' - weight: 9 diff --git a/modules/thunder_demo/config/install/tour.tour.homepage.yml b/modules/thunder_demo/config/install/tour.tour.homepage.yml deleted file mode 100644 index fbcfe49ad..000000000 --- a/modules/thunder_demo/config/install/tour.tour.homepage.yml +++ /dev/null @@ -1,54 +0,0 @@ -langcode: en -status: true -dependencies: - module: - - thunder_demo -id: homepage -label: Homepage -module: thunder_demo -routes: - - - route_name: entity.user.canonical - route_params: - user: '1' -tips: - homepage: - id: homepage - plugin: text - label: 'Welcome and thank you for trying Thunder!' - body: 'This tour will lead you through its most interesting features. Let''s explore the basic structure of a site first.' - weight: 1 - main_content: - id: main_content - plugin: text - label: 'Main content region' - body: 'Meat and bones of a Thunder site. Depending on the page you are on you''ll find article content, list of articles in a channel, media assets and many more here.' - weight: 2 - position: left - selector: '#content' - main_menu: - id: main_menu - plugin: text - label: 'Main menu' - body: '

Main site navigation. You can currently see the links to the two channels that we pre-created for you. All menus in Thunder are easy to modify so they can suit your needs.

Hint: try hovering the menu and look for the pencil icon.' - weight: 3 - selector: .menu--main - admin_menu: - id: admin_menu - plugin: text - label: 'Admin menu' - body: '

It lets you do the editorial and administrative tasks. Hover over the "Content" link and see what happens. Don''t worry I''ll wait so you can take your time.

Neat, ha?

' - weight: 4 - selector: .toolbar-icon-system-admin-content - restart_tour: - id: restart_tour - plugin: text - label: 'Need some more time to explore on your own?' - body: 'You can stop the tour at any time and re-start it by pressing the tour button in the top-right corner.' - weight: 5 - next_step: - id: next_step - plugin: text - label: 'Are you ready?' - body: '

We are! Let''s continue with the basic content creation.

' - weight: 6 diff --git a/modules/thunder_demo/content/crop/35877b5f-300a-4456-9e8c-760a4c1c37b5.yml b/modules/thunder_demo/content/crop/35877b5f-300a-4456-9e8c-760a4c1c37b5.yml deleted file mode 100644 index d177e3b3a..000000000 --- a/modules/thunder_demo/content/crop/35877b5f-300a-4456-9e8c-760a4c1c37b5.yml +++ /dev/null @@ -1,31 +0,0 @@ -_meta: - version: '1.0' - entity_type: crop - uuid: 35877b5f-300a-4456-9e8c-760a4c1c37b5 - bundle: focal_point - default_langcode: en -default: - entity_id: - - - value: 2 - entity_type: - - - value: file - uri: - - - value: 'public://2020-09/welte_philipp_final_2.jpg' - x: - - - value: 1060 - 'y': - - - value: 1189 - revision_timestamp: - - - value: 1600157271 - revision_uid: - - - target_id: 1 - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/crop/73fa0ae6-47b2-4719-b2fd-09dabca808d0.yml b/modules/thunder_demo/content/crop/73fa0ae6-47b2-4719-b2fd-09dabca808d0.yml deleted file mode 100644 index 1ceccfc72..000000000 --- a/modules/thunder_demo/content/crop/73fa0ae6-47b2-4719-b2fd-09dabca808d0.yml +++ /dev/null @@ -1,31 +0,0 @@ -_meta: - version: '1.0' - entity_type: crop - uuid: 73fa0ae6-47b2-4719-b2fd-09dabca808d0 - bundle: focal_point - default_langcode: en -default: - entity_id: - - - value: 1 - entity_type: - - - value: file - uri: - - - value: 'public://2020-09/welte_ingo_v1.jpg' - x: - - - value: 728 - 'y': - - - value: 294 - revision_timestamp: - - - value: 1600152511 - revision_uid: - - - target_id: 1 - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/file/0044429b-3571-4ccf-b6a1-4e7d2c5c035a.yml b/modules/thunder_demo/content/file/0044429b-3571-4ccf-b6a1-4e7d2c5c035a.yml deleted file mode 100644 index 4bd242fc8..000000000 --- a/modules/thunder_demo/content/file/0044429b-3571-4ccf-b6a1-4e7d2c5c035a.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 0044429b-3571-4ccf-b6a1-4e7d2c5c035a - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderday_burda_2017011490.jpg - uri: - - - value: 'public://2020-09/thunderday_burda_2017011490.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 440839 - status: - - - value: true - created: - - - value: 1600160742 diff --git a/modules/thunder_demo/content/file/038a612e-d318-4959-b23b-ee2978cd1f6c.yml b/modules/thunder_demo/content/file/038a612e-d318-4959-b23b-ee2978cd1f6c.yml deleted file mode 100644 index 477ab7efe..000000000 --- a/modules/thunder_demo/content/file/038a612e-d318-4959-b23b-ee2978cd1f6c.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 038a612e-d318-4959-b23b-ee2978cd1f6c - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: impressionen_kaminzimmer_3.jpg - uri: - - - value: 'public://2020-09/impressionen_kaminzimmer_3.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 10076427 - status: - - - value: true - created: - - - value: 1600162381 diff --git a/modules/thunder_demo/content/file/2387f16f-68c8-4297-a998-954c7ef66dc0.yml b/modules/thunder_demo/content/file/2387f16f-68c8-4297-a998-954c7ef66dc0.yml deleted file mode 100644 index 3c2d4e33f..000000000 --- a/modules/thunder_demo/content/file/2387f16f-68c8-4297-a998-954c7ef66dc0.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 2387f16f-68c8-4297-a998-954c7ef66dc0 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderday_burda_2017011817.jpg - uri: - - - value: 'public://2020-09/thunderday_burda_2017011817.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 965454 - status: - - - value: true - created: - - - value: 1600160861 diff --git a/modules/thunder_demo/content/file/4533f02b-f720-46cb-acbb-84255b302ef1.yml b/modules/thunder_demo/content/file/4533f02b-f720-46cb-acbb-84255b302ef1.yml deleted file mode 100644 index 06fae1897..000000000 --- a/modules/thunder_demo/content/file/4533f02b-f720-46cb-acbb-84255b302ef1.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 4533f02b-f720-46cb-acbb-84255b302ef1 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderday_burda_2017011555.jpg - uri: - - - value: 'public://2020-09/thunderday_burda_2017011555.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 822667 - status: - - - value: true - created: - - - value: 1600160861 diff --git a/modules/thunder_demo/content/file/4fc96a05-40d7-4651-9c87-b06f2fcaf95a.yml b/modules/thunder_demo/content/file/4fc96a05-40d7-4651-9c87-b06f2fcaf95a.yml deleted file mode 100644 index 701f99d05..000000000 --- a/modules/thunder_demo/content/file/4fc96a05-40d7-4651-9c87-b06f2fcaf95a.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 4fc96a05-40d7-4651-9c87-b06f2fcaf95a - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: leeraufbau_festsaal.jpg - uri: - - - value: 'public://2020-09/leeraufbau_festsaal.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 5662638 - status: - - - value: true - created: - - - value: 1600162381 diff --git a/modules/thunder_demo/content/file/50b7f62a-6c43-4ae8-b1fc-2675520fdea7.yml b/modules/thunder_demo/content/file/50b7f62a-6c43-4ae8-b1fc-2675520fdea7.yml deleted file mode 100644 index a00dc7d9c..000000000 --- a/modules/thunder_demo/content/file/50b7f62a-6c43-4ae8-b1fc-2675520fdea7.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 50b7f62a-6c43-4ae8-b1fc-2675520fdea7 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: map_ctis.png - uri: - - - value: 'public://2020-09/map_ctis.png' - filemime: - - - value: image/png - filesize: - - - value: 434830 - status: - - - value: true - created: - - - value: 1600160222 diff --git a/modules/thunder_demo/content/file/587ac846-1c3a-4345-8995-122683d5d2a9.yml b/modules/thunder_demo/content/file/587ac846-1c3a-4345-8995-122683d5d2a9.yml deleted file mode 100644 index ba22da8e9..000000000 --- a/modules/thunder_demo/content/file/587ac846-1c3a-4345-8995-122683d5d2a9.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 587ac846-1c3a-4345-8995-122683d5d2a9 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderday_burda_2017011616.jpg - uri: - - - value: 'public://2020-09/thunderday_burda_2017011616.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 252641 - status: - - - value: true - created: - - - value: 1600160861 diff --git a/modules/thunder_demo/content/file/5abbb82e-76f3-405d-b8e3-e2d890197aba.yml b/modules/thunder_demo/content/file/5abbb82e-76f3-405d-b8e3-e2d890197aba.yml deleted file mode 100644 index 6674aa883..000000000 --- a/modules/thunder_demo/content/file/5abbb82e-76f3-405d-b8e3-e2d890197aba.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 5abbb82e-76f3-405d-b8e3-e2d890197aba - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: impressionen_kaminzimmer_4.jpg - uri: - - - value: 'public://2020-09/impressionen_kaminzimmer_4.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 5449588 - status: - - - value: true - created: - - - value: 1600162381 diff --git a/modules/thunder_demo/content/file/63c664f3-d403-4509-b90c-b945a69431b5.yml b/modules/thunder_demo/content/file/63c664f3-d403-4509-b90c-b945a69431b5.yml deleted file mode 100644 index da734da04..000000000 --- a/modules/thunder_demo/content/file/63c664f3-d403-4509-b90c-b945a69431b5.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 63c664f3-d403-4509-b90c-b945a69431b5 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunder_dg_2237.jpg - uri: - - - value: 'public://2020-09/thunder_dg_2237.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 361958 - status: - - - value: true - created: - - - value: 1600163434 diff --git a/modules/thunder_demo/content/file/7e9e28dd-35a6-48eb-bfdd-5578b250cf8c.yml b/modules/thunder_demo/content/file/7e9e28dd-35a6-48eb-bfdd-5578b250cf8c.yml deleted file mode 100644 index d6d806e5d..000000000 --- a/modules/thunder_demo/content/file/7e9e28dd-35a6-48eb-bfdd-5578b250cf8c.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 7e9e28dd-35a6-48eb-bfdd-5578b250cf8c - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderteam_on_stage.jpg - uri: - - - value: 'public://2020-09/thunderteam_on_stage.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 3136403 - status: - - - value: true - created: - - - value: 1600162381 diff --git a/modules/thunder_demo/content/file/82aa86b9-645c-4310-a7b6-9770240663b3.yml b/modules/thunder_demo/content/file/82aa86b9-645c-4310-a7b6-9770240663b3.yml deleted file mode 100644 index 3751eb7e3..000000000 --- a/modules/thunder_demo/content/file/82aa86b9-645c-4310-a7b6-9770240663b3.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 82aa86b9-645c-4310-a7b6-9770240663b3 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderday_burda_2017011666.jpg - uri: - - - value: 'public://2020-09/thunderday_burda_2017011666.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 375957 - status: - - - value: true - created: - - - value: 1600160861 diff --git a/modules/thunder_demo/content/file/87530ce0-8006-4773-9ec2-98bb85c21d30.yml b/modules/thunder_demo/content/file/87530ce0-8006-4773-9ec2-98bb85c21d30.yml deleted file mode 100644 index 4986b1c8a..000000000 --- a/modules/thunder_demo/content/file/87530ce0-8006-4773-9ec2-98bb85c21d30.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 87530ce0-8006-4773-9ec2-98bb85c21d30 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: cti-badge.jpg - uri: - - - value: 'public://2020-09/cti-badge.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 38551 - status: - - - value: true - created: - - - value: 1600160312 diff --git a/modules/thunder_demo/content/file/911771d1-f8d5-4d62-ba77-e7040682c07e.yml b/modules/thunder_demo/content/file/911771d1-f8d5-4d62-ba77-e7040682c07e.yml deleted file mode 100644 index cea927cc5..000000000 --- a/modules/thunder_demo/content/file/911771d1-f8d5-4d62-ba77-e7040682c07e.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 911771d1-f8d5-4d62-ba77-e7040682c07e - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderday_burda_2017011419.jpg - uri: - - - value: 'public://2020-09/thunderday_burda_2017011419.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 217503 - status: - - - value: true - created: - - - value: 1600160861 diff --git a/modules/thunder_demo/content/file/94a2a059-a253-45a1-83e0-79fcb32133c0.yml b/modules/thunder_demo/content/file/94a2a059-a253-45a1-83e0-79fcb32133c0.yml deleted file mode 100644 index 6c9995a90..000000000 --- a/modules/thunder_demo/content/file/94a2a059-a253-45a1-83e0-79fcb32133c0.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 94a2a059-a253-45a1-83e0-79fcb32133c0 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: welte_philipp_final_2.jpg - uri: - - - value: 'public://2020-09/welte_philipp_final_2.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 961396 - status: - - - value: true - created: - - - value: 1600157248 diff --git a/modules/thunder_demo/content/file/9a9a6603-6dba-4f33-b467-fd81bcc6a3a4.yml b/modules/thunder_demo/content/file/9a9a6603-6dba-4f33-b467-fd81bcc6a3a4.yml deleted file mode 100644 index 2a1565cc7..000000000 --- a/modules/thunder_demo/content/file/9a9a6603-6dba-4f33-b467-fd81bcc6a3a4.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 9a9a6603-6dba-4f33-b467-fd81bcc6a3a4 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: impressionen_kaminzimmer_2.jpg - uri: - - - value: 'public://2020-09/impressionen_kaminzimmer_2.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 4338476 - status: - - - value: true - created: - - - value: 1600162381 diff --git a/modules/thunder_demo/content/file/b08692d3-765c-4422-b001-0aee9b7ea103.yml b/modules/thunder_demo/content/file/b08692d3-765c-4422-b001-0aee9b7ea103.yml deleted file mode 100644 index b5a3ea2f3..000000000 --- a/modules/thunder_demo/content/file/b08692d3-765c-4422-b001-0aee9b7ea103.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: b08692d3-765c-4422-b001-0aee9b7ea103 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderday_burda_2017011438.jpg - uri: - - - value: 'public://2020-09/thunderday_burda_2017011438.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 806695 - status: - - - value: true - created: - - - value: 1600160861 diff --git a/modules/thunder_demo/content/file/c5a9a50a-20bc-48ee-89ff-6465c194f2be.yml b/modules/thunder_demo/content/file/c5a9a50a-20bc-48ee-89ff-6465c194f2be.yml deleted file mode 100644 index bfbd2aef5..000000000 --- a/modules/thunder_demo/content/file/c5a9a50a-20bc-48ee-89ff-6465c194f2be.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: c5a9a50a-20bc-48ee-89ff-6465c194f2be - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: welte_ingo_v1.jpg - uri: - - - value: 'public://2020-09/welte_ingo_v1_0.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 126045 - status: - - - value: true - created: - - - value: 1600152444 diff --git a/modules/thunder_demo/content/file/cti-badge.jpg b/modules/thunder_demo/content/file/cti-badge.jpg deleted file mode 100644 index dd80ad992..000000000 Binary files a/modules/thunder_demo/content/file/cti-badge.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/d2fd4235-9c0d-46bf-a649-e812be18cfbb.yml b/modules/thunder_demo/content/file/d2fd4235-9c0d-46bf-a649-e812be18cfbb.yml deleted file mode 100644 index da5b9adb5..000000000 --- a/modules/thunder_demo/content/file/d2fd4235-9c0d-46bf-a649-e812be18cfbb.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: d2fd4235-9c0d-46bf-a649-e812be18cfbb - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: impressionen_kaminzimmer.jpg - uri: - - - value: 'public://2020-09/impressionen_kaminzimmer.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 6101518 - status: - - - value: true - created: - - - value: 1600162084 diff --git a/modules/thunder_demo/content/file/de73fbb6-9126-4eee-844f-cd4622653f83.yml b/modules/thunder_demo/content/file/de73fbb6-9126-4eee-844f-cd4622653f83.yml deleted file mode 100644 index 18c82170e..000000000 --- a/modules/thunder_demo/content/file/de73fbb6-9126-4eee-844f-cd4622653f83.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: de73fbb6-9126-4eee-844f-cd4622653f83 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: thunderday_burda_2017011407.jpg - uri: - - - value: 'public://2020-09/thunderday_burda_2017011407.jpg' - filemime: - - - value: image/jpeg - filesize: - - - value: 1657167 - status: - - - value: true - created: - - - value: 1600160861 diff --git a/modules/thunder_demo/content/file/impressionen_kaminzimmer.jpg b/modules/thunder_demo/content/file/impressionen_kaminzimmer.jpg deleted file mode 100644 index c456cb2b5..000000000 Binary files a/modules/thunder_demo/content/file/impressionen_kaminzimmer.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/impressionen_kaminzimmer_2.jpg b/modules/thunder_demo/content/file/impressionen_kaminzimmer_2.jpg deleted file mode 100644 index 6507687a8..000000000 Binary files a/modules/thunder_demo/content/file/impressionen_kaminzimmer_2.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/impressionen_kaminzimmer_3.jpg b/modules/thunder_demo/content/file/impressionen_kaminzimmer_3.jpg deleted file mode 100644 index c3dd72b56..000000000 Binary files a/modules/thunder_demo/content/file/impressionen_kaminzimmer_3.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/impressionen_kaminzimmer_4.jpg b/modules/thunder_demo/content/file/impressionen_kaminzimmer_4.jpg deleted file mode 100644 index 23884bf50..000000000 Binary files a/modules/thunder_demo/content/file/impressionen_kaminzimmer_4.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/leeraufbau_festsaal.jpg b/modules/thunder_demo/content/file/leeraufbau_festsaal.jpg deleted file mode 100644 index c7ec07112..000000000 Binary files a/modules/thunder_demo/content/file/leeraufbau_festsaal.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/map_ctis.png b/modules/thunder_demo/content/file/map_ctis.png deleted file mode 100644 index eac332285..000000000 Binary files a/modules/thunder_demo/content/file/map_ctis.png and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunder_dg_2237.jpg b/modules/thunder_demo/content/file/thunder_dg_2237.jpg deleted file mode 100644 index 3293fbd80..000000000 Binary files a/modules/thunder_demo/content/file/thunder_dg_2237.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderday_burda_2017011407.jpg b/modules/thunder_demo/content/file/thunderday_burda_2017011407.jpg deleted file mode 100644 index 6f8fe80f9..000000000 Binary files a/modules/thunder_demo/content/file/thunderday_burda_2017011407.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderday_burda_2017011419.jpg b/modules/thunder_demo/content/file/thunderday_burda_2017011419.jpg deleted file mode 100644 index e25077562..000000000 Binary files a/modules/thunder_demo/content/file/thunderday_burda_2017011419.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderday_burda_2017011438.jpg b/modules/thunder_demo/content/file/thunderday_burda_2017011438.jpg deleted file mode 100644 index 8260c215b..000000000 Binary files a/modules/thunder_demo/content/file/thunderday_burda_2017011438.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderday_burda_2017011490.jpg b/modules/thunder_demo/content/file/thunderday_burda_2017011490.jpg deleted file mode 100644 index f1d8b70e9..000000000 Binary files a/modules/thunder_demo/content/file/thunderday_burda_2017011490.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderday_burda_2017011555.jpg b/modules/thunder_demo/content/file/thunderday_burda_2017011555.jpg deleted file mode 100644 index b4c2d2121..000000000 Binary files a/modules/thunder_demo/content/file/thunderday_burda_2017011555.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderday_burda_2017011616.jpg b/modules/thunder_demo/content/file/thunderday_burda_2017011616.jpg deleted file mode 100644 index f061f63b0..000000000 Binary files a/modules/thunder_demo/content/file/thunderday_burda_2017011616.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderday_burda_2017011666.jpg b/modules/thunder_demo/content/file/thunderday_burda_2017011666.jpg deleted file mode 100644 index 41ef6c6dc..000000000 Binary files a/modules/thunder_demo/content/file/thunderday_burda_2017011666.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderday_burda_2017011817.jpg b/modules/thunder_demo/content/file/thunderday_burda_2017011817.jpg deleted file mode 100644 index 7b67b4b37..000000000 Binary files a/modules/thunder_demo/content/file/thunderday_burda_2017011817.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/thunderteam_on_stage.jpg b/modules/thunder_demo/content/file/thunderteam_on_stage.jpg deleted file mode 100644 index b531c1f41..000000000 Binary files a/modules/thunder_demo/content/file/thunderteam_on_stage.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/welte_ingo_v1.jpg b/modules/thunder_demo/content/file/welte_ingo_v1.jpg deleted file mode 100644 index 602639f7e..000000000 Binary files a/modules/thunder_demo/content/file/welte_ingo_v1.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/file/welte_philipp_final_2.jpg b/modules/thunder_demo/content/file/welte_philipp_final_2.jpg deleted file mode 100644 index 8c3c9c456..000000000 Binary files a/modules/thunder_demo/content/file/welte_philipp_final_2.jpg and /dev/null differ diff --git a/modules/thunder_demo/content/media/1348d981-3575-4c32-81b4-ae758e43d38e.yml b/modules/thunder_demo/content/media/1348d981-3575-4c32-81b4-ae758e43d38e.yml deleted file mode 100644 index 2ec516b2e..000000000 --- a/modules/thunder_demo/content/media/1348d981-3575-4c32-81b4-ae758e43d38e.yml +++ /dev/null @@ -1,30 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 1348d981-3575-4c32-81b4-ae758e43d38e - bundle: twitter - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - created: - - - value: 1600162474 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_author: - - - value: markusvl - field_url: - - - value: 'https://twitter.com/markusvl/status/1067030913299693568' diff --git a/modules/thunder_demo/content/media/13b6536a-f317-4e74-a71f-66e5c61ede65.yml b/modules/thunder_demo/content/media/13b6536a-f317-4e74-a71f-66e5c61ede65.yml deleted file mode 100644 index 48536f04b..000000000 --- a/modules/thunder_demo/content/media/13b6536a-f317-4e74-a71f-66e5c61ede65.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 13b6536a-f317-4e74-a71f-66e5c61ede65 - bundle: image - default_langcode: en - depends: - 4fc96a05-40d7-4651-9c87-b06f2fcaf95a: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: leeraufbau_festsaal.jpg - created: - - - value: 1600162381 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Sophia Vogel' - field_image: - - - entity: 4fc96a05-40d7-4651-9c87-b06f2fcaf95a - alt: '' - title: '' - width: 5190 - height: 3381 diff --git a/modules/thunder_demo/content/media/17e3275e-aed4-4780-be08-89e839a0be5f.yml b/modules/thunder_demo/content/media/17e3275e-aed4-4780-be08-89e839a0be5f.yml deleted file mode 100644 index 55a640555..000000000 --- a/modules/thunder_demo/content/media/17e3275e-aed4-4780-be08-89e839a0be5f.yml +++ /dev/null @@ -1,30 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 17e3275e-aed4-4780-be08-89e839a0be5f - bundle: twitter - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - created: - - - value: 1600162499 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_author: - - - value: lukasfischer - field_url: - - - value: 'https://twitter.com/lukasfischer/status/1067396358775218176' diff --git a/modules/thunder_demo/content/media/1c1b3c83-3f91-4110-871c-d612d7df1bb6.yml b/modules/thunder_demo/content/media/1c1b3c83-3f91-4110-871c-d612d7df1bb6.yml deleted file mode 100644 index a2e5d45dd..000000000 --- a/modules/thunder_demo/content/media/1c1b3c83-3f91-4110-871c-d612d7df1bb6.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 1c1b3c83-3f91-4110-871c-d612d7df1bb6 - bundle: image - default_langcode: en - depends: - b08692d3-765c-4422-b001-0aee9b7ea103: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: thunderday_burda_2017011438.jpg - created: - - - value: 1600160861 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Kerstin Seipt, www.kerstinseipt-photography.de' - field_image: - - - entity: b08692d3-765c-4422-b001-0aee9b7ea103 - alt: '' - title: '' - width: 3543 - height: 2362 diff --git a/modules/thunder_demo/content/media/2584ef49-8f36-424e-9338-c95d5cf933dc.yml b/modules/thunder_demo/content/media/2584ef49-8f36-424e-9338-c95d5cf933dc.yml deleted file mode 100644 index a2dbae595..000000000 --- a/modules/thunder_demo/content/media/2584ef49-8f36-424e-9338-c95d5cf933dc.yml +++ /dev/null @@ -1,30 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 2584ef49-8f36-424e-9338-c95d5cf933dc - bundle: twitter - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - created: - - - value: 1600161155 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_author: - - - value: bofrost007 - field_url: - - - value: 'https://twitter.com/bofrost007/status/932699092278444032' diff --git a/modules/thunder_demo/content/media/31457b1e-0122-46a6-b3ab-edfa0c4b801a.yml b/modules/thunder_demo/content/media/31457b1e-0122-46a6-b3ab-edfa0c4b801a.yml deleted file mode 100644 index 2fbb814b3..000000000 --- a/modules/thunder_demo/content/media/31457b1e-0122-46a6-b3ab-edfa0c4b801a.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 31457b1e-0122-46a6-b3ab-edfa0c4b801a - bundle: image - default_langcode: en - depends: - c5a9a50a-20bc-48ee-89ff-6465c194f2be: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: Thunder - created: - - - value: 1458200844 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_copyright: - - - value: 'Thunder, Hubert Burda Media' - field_image: - - - entity: c5a9a50a-20bc-48ee-89ff-6465c194f2be - alt: '' - title: '' - width: 1456 - height: 818 diff --git a/modules/thunder_demo/content/media/34478597-153e-4b96-b275-4de573e1116c.yml b/modules/thunder_demo/content/media/34478597-153e-4b96-b275-4de573e1116c.yml deleted file mode 100644 index 539383e2c..000000000 --- a/modules/thunder_demo/content/media/34478597-153e-4b96-b275-4de573e1116c.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 34478597-153e-4b96-b275-4de573e1116c - bundle: image - default_langcode: en - depends: - 50b7f62a-6c43-4ae8-b1fc-2675520fdea7: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: 'Map of CTIs' - created: - - - value: 1600160222 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_image: - - - entity: 50b7f62a-6c43-4ae8-b1fc-2675520fdea7 - alt: '' - title: '' - width: 1581 - height: 781 diff --git a/modules/thunder_demo/content/media/3c47da20-33f3-4bf2-bee0-bd7669d8e7aa.yml b/modules/thunder_demo/content/media/3c47da20-33f3-4bf2-bee0-bd7669d8e7aa.yml deleted file mode 100644 index 175750c6a..000000000 --- a/modules/thunder_demo/content/media/3c47da20-33f3-4bf2-bee0-bd7669d8e7aa.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 3c47da20-33f3-4bf2-bee0-bd7669d8e7aa - bundle: image - default_langcode: en - depends: - 5abbb82e-76f3-405d-b8e3-e2d890197aba: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: impressionen_kaminzimmer_4.jpg - created: - - - value: 1600162381 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Sophia Vogel' - field_image: - - - entity: 5abbb82e-76f3-405d-b8e3-e2d890197aba - alt: '' - title: '' - width: 5472 - height: 3648 diff --git a/modules/thunder_demo/content/media/40bbeede-898b-4574-a239-95aae6112a3d.yml b/modules/thunder_demo/content/media/40bbeede-898b-4574-a239-95aae6112a3d.yml deleted file mode 100644 index 56ab4c0f5..000000000 --- a/modules/thunder_demo/content/media/40bbeede-898b-4574-a239-95aae6112a3d.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 40bbeede-898b-4574-a239-95aae6112a3d - bundle: image - default_langcode: en - depends: - 911771d1-f8d5-4d62-ba77-e7040682c07e: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: thunderday_burda_2017011419.jpg - created: - - - value: 1600160861 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Kerstin Seipt, www.kerstinseipt-photography.de' - field_image: - - - entity: 911771d1-f8d5-4d62-ba77-e7040682c07e - alt: '' - title: '' - width: 3543 - height: 2362 diff --git a/modules/thunder_demo/content/media/486e2773-81e6-4685-80c0-9e4f26c214a1.yml b/modules/thunder_demo/content/media/486e2773-81e6-4685-80c0-9e4f26c214a1.yml deleted file mode 100644 index 570c64c16..000000000 --- a/modules/thunder_demo/content/media/486e2773-81e6-4685-80c0-9e4f26c214a1.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 486e2773-81e6-4685-80c0-9e4f26c214a1 - bundle: image - default_langcode: en - depends: - 9a9a6603-6dba-4f33-b467-fd81bcc6a3a4: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: impressionen_kaminzimmer_2.jpg - created: - - - value: 1600162381 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Sophia Vogel' - field_image: - - - entity: 9a9a6603-6dba-4f33-b467-fd81bcc6a3a4 - alt: '' - title: '' - width: 5472 - height: 3648 diff --git a/modules/thunder_demo/content/media/4f4039ab-65a3-4ade-8d2c-6553b21cad58.yml b/modules/thunder_demo/content/media/4f4039ab-65a3-4ade-8d2c-6553b21cad58.yml deleted file mode 100644 index 6d2de20ae..000000000 --- a/modules/thunder_demo/content/media/4f4039ab-65a3-4ade-8d2c-6553b21cad58.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 4f4039ab-65a3-4ade-8d2c-6553b21cad58 - bundle: image - default_langcode: en - depends: - 82aa86b9-645c-4310-a7b6-9770240663b3: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: thunderday_burda_2017011666.jpg - created: - - - value: 1600160861 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Kerstin Seipt, www.kerstinseipt-photography.de' - field_image: - - - entity: 82aa86b9-645c-4310-a7b6-9770240663b3 - alt: '' - title: '' - width: 3543 - height: 2362 diff --git a/modules/thunder_demo/content/media/5734cc42-787a-464e-9836-38ffa34aad7f.yml b/modules/thunder_demo/content/media/5734cc42-787a-464e-9836-38ffa34aad7f.yml deleted file mode 100644 index 078f7318b..000000000 --- a/modules/thunder_demo/content/media/5734cc42-787a-464e-9836-38ffa34aad7f.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 5734cc42-787a-464e-9836-38ffa34aad7f - bundle: image - default_langcode: en - depends: - 587ac846-1c3a-4345-8995-122683d5d2a9: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: thunderday_burda_2017011616.jpg - created: - - - value: 1600160861 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Kerstin Seipt, www.kerstinseipt-photography.de' - field_image: - - - entity: 587ac846-1c3a-4345-8995-122683d5d2a9 - alt: '' - title: '' - width: 3543 - height: 2362 diff --git a/modules/thunder_demo/content/media/5d0b5981-3c35-4160-9ada-f4f7eaf4f607.yml b/modules/thunder_demo/content/media/5d0b5981-3c35-4160-9ada-f4f7eaf4f607.yml deleted file mode 100644 index 2cf89c57d..000000000 --- a/modules/thunder_demo/content/media/5d0b5981-3c35-4160-9ada-f4f7eaf4f607.yml +++ /dev/null @@ -1,30 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 5d0b5981-3c35-4160-9ada-f4f7eaf4f607 - bundle: twitter - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - created: - - - value: 1600161142 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_author: - - - value: thorandreg - field_url: - - - value: 'https://twitter.com/thorandreg/status/932727077526212608' diff --git a/modules/thunder_demo/content/media/6296b850-fea3-458d-8782-3177f48e2cbe.yml b/modules/thunder_demo/content/media/6296b850-fea3-458d-8782-3177f48e2cbe.yml deleted file mode 100644 index dcac653f3..000000000 --- a/modules/thunder_demo/content/media/6296b850-fea3-458d-8782-3177f48e2cbe.yml +++ /dev/null @@ -1,30 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 6296b850-fea3-458d-8782-3177f48e2cbe - bundle: twitter - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - created: - - - value: 1600161182 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_author: - - - value: breidert - field_url: - - - value: 'https://twitter.com/breidert/status/932627844030779392' diff --git a/modules/thunder_demo/content/media/6fcc43bd-c374-4528-b180-ebe94c8fa6a5.yml b/modules/thunder_demo/content/media/6fcc43bd-c374-4528-b180-ebe94c8fa6a5.yml deleted file mode 100644 index 4e946a0e1..000000000 --- a/modules/thunder_demo/content/media/6fcc43bd-c374-4528-b180-ebe94c8fa6a5.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 6fcc43bd-c374-4528-b180-ebe94c8fa6a5 - bundle: image - default_langcode: en - depends: - 0044429b-3571-4ccf-b6a1-4e7d2c5c035a: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: ThunderDay - created: - - - value: 1600160742 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_copyright: - - - value: 'Kerstin Seipt, www.kerstinseipt-photography.de' - field_image: - - - entity: 0044429b-3571-4ccf-b6a1-4e7d2c5c035a - alt: '' - title: '' - width: 3543 - height: 2362 diff --git a/modules/thunder_demo/content/media/765b7c3f-e70c-4cdb-85c6-d0d329919eec.yml b/modules/thunder_demo/content/media/765b7c3f-e70c-4cdb-85c6-d0d329919eec.yml deleted file mode 100644 index 1815a6894..000000000 --- a/modules/thunder_demo/content/media/765b7c3f-e70c-4cdb-85c6-d0d329919eec.yml +++ /dev/null @@ -1,33 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 765b7c3f-e70c-4cdb-85c6-d0d329919eec - bundle: video - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: 'ThunderDay 2018' - created: - - - value: 1600162429 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_author: - - - value: 'Thunder CMS' - field_media_video_embed_field: - - - value: 'https://youtu.be/6imbfpIs6FI' diff --git a/modules/thunder_demo/content/media/81392281-1bf3-4929-b887-c8096ebc01e4.yml b/modules/thunder_demo/content/media/81392281-1bf3-4929-b887-c8096ebc01e4.yml deleted file mode 100644 index 7d3922d72..000000000 --- a/modules/thunder_demo/content/media/81392281-1bf3-4929-b887-c8096ebc01e4.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 81392281-1bf3-4929-b887-c8096ebc01e4 - bundle: image - default_langcode: en - depends: - d2fd4235-9c0d-46bf-a649-e812be18cfbb: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: Impressionen - created: - - - value: 1600162084 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_copyright: - - - value: 'Sophia Vogel' - field_image: - - - entity: d2fd4235-9c0d-46bf-a649-e812be18cfbb - alt: '' - title: '' - width: 5880 - height: 3770 diff --git a/modules/thunder_demo/content/media/83294827-6a30-43ff-b515-b73e86e8205a.yml b/modules/thunder_demo/content/media/83294827-6a30-43ff-b515-b73e86e8205a.yml deleted file mode 100644 index cbff68ea6..000000000 --- a/modules/thunder_demo/content/media/83294827-6a30-43ff-b515-b73e86e8205a.yml +++ /dev/null @@ -1,30 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 83294827-6a30-43ff-b515-b73e86e8205a - bundle: twitter - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - created: - - - value: 1600162464 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_author: - - - value: ramsalt - field_url: - - - value: 'https://twitter.com/ramsalt/status/1066995176093216769' diff --git a/modules/thunder_demo/content/media/8656ff5b-a9a5-49e4-a8e8-0d7c5bc2678b.yml b/modules/thunder_demo/content/media/8656ff5b-a9a5-49e4-a8e8-0d7c5bc2678b.yml deleted file mode 100644 index ebebac98e..000000000 --- a/modules/thunder_demo/content/media/8656ff5b-a9a5-49e4-a8e8-0d7c5bc2678b.yml +++ /dev/null @@ -1,30 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 8656ff5b-a9a5-49e4-a8e8-0d7c5bc2678b - bundle: pinterest - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: '478085316687452268' - created: - - - value: 1600163484 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_url: - - - value: 'https://www.pinterest.de/pin/478085316687452268/' diff --git a/modules/thunder_demo/content/media/916d281a-6097-4e26-8805-e5392ac53a0b.yml b/modules/thunder_demo/content/media/916d281a-6097-4e26-8805-e5392ac53a0b.yml deleted file mode 100644 index e1eba2663..000000000 --- a/modules/thunder_demo/content/media/916d281a-6097-4e26-8805-e5392ac53a0b.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 916d281a-6097-4e26-8805-e5392ac53a0b - bundle: image - default_langcode: en - depends: - 038a612e-d318-4959-b23b-ee2978cd1f6c: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: impressionen_kaminzimmer_3.jpg - created: - - - value: 1600162381 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Sophia Vogel' - field_image: - - - entity: 038a612e-d318-4959-b23b-ee2978cd1f6c - alt: '' - title: '' - width: 6000 - height: 4000 diff --git a/modules/thunder_demo/content/media/9c2cafe0-3345-4cd3-ad3c-2d8ff85b9db5.yml b/modules/thunder_demo/content/media/9c2cafe0-3345-4cd3-ad3c-2d8ff85b9db5.yml deleted file mode 100644 index e90352931..000000000 --- a/modules/thunder_demo/content/media/9c2cafe0-3345-4cd3-ad3c-2d8ff85b9db5.yml +++ /dev/null @@ -1,43 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 9c2cafe0-3345-4cd3-ad3c-2d8ff85b9db5 - bundle: image - default_langcode: en - depends: - 87530ce0-8006-4773-9ec2-98bb85c21d30: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: 'CTI Badge' - created: - - - value: 1600160312 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_copyright: - - - value: Thunder - field_description: - - - value: "

CTIs are allowed to use the label ‘Certified Thunder Integrator’ and the associated badge to promote their services.

\r\n" - format: basic_html - field_image: - - - entity: 87530ce0-8006-4773-9ec2-98bb85c21d30 - alt: 'Certified Thunder Integrator Badge' - title: 'Certified Thunder Integrator Badge' - width: 3543 - height: 1248 diff --git a/modules/thunder_demo/content/media/c8b73bd1-1e4b-477e-96d9-580be6dab017.yml b/modules/thunder_demo/content/media/c8b73bd1-1e4b-477e-96d9-580be6dab017.yml deleted file mode 100644 index 32615be71..000000000 --- a/modules/thunder_demo/content/media/c8b73bd1-1e4b-477e-96d9-580be6dab017.yml +++ /dev/null @@ -1,47 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: c8b73bd1-1e4b-477e-96d9-580be6dab017 - bundle: gallery - default_langcode: en - depends: - d3782161-f7b3-4e8c-a24f-f2545bb2d474: media - 13b6536a-f317-4e74-a71f-66e5c61ede65: media - 486e2773-81e6-4685-80c0-9e4f26c214a1: media - 916d281a-6097-4e26-8805-e5392ac53a0b: media - 3c47da20-33f3-4bf2-bee0-bd7669d8e7aa: media - 81392281-1bf3-4929-b887-c8096ebc01e4: media -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: 'ThunderDay 2018' - created: - - - value: 1600162372 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_media_images: - - - entity: d3782161-f7b3-4e8c-a24f-f2545bb2d474 - - - entity: 13b6536a-f317-4e74-a71f-66e5c61ede65 - - - entity: 486e2773-81e6-4685-80c0-9e4f26c214a1 - - - entity: 916d281a-6097-4e26-8805-e5392ac53a0b - - - entity: 3c47da20-33f3-4bf2-bee0-bd7669d8e7aa - - - entity: 81392281-1bf3-4929-b887-c8096ebc01e4 diff --git a/modules/thunder_demo/content/media/d3782161-f7b3-4e8c-a24f-f2545bb2d474.yml b/modules/thunder_demo/content/media/d3782161-f7b3-4e8c-a24f-f2545bb2d474.yml deleted file mode 100644 index 3ab164f0a..000000000 --- a/modules/thunder_demo/content/media/d3782161-f7b3-4e8c-a24f-f2545bb2d474.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: d3782161-f7b3-4e8c-a24f-f2545bb2d474 - bundle: image - default_langcode: en - depends: - 7e9e28dd-35a6-48eb-bfdd-5578b250cf8c: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: thunderteam_on_stage.jpg - created: - - - value: 1600162381 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Sophia Vogel' - field_image: - - - entity: 7e9e28dd-35a6-48eb-bfdd-5578b250cf8c - alt: '' - title: '' - width: 4618 - height: 2996 diff --git a/modules/thunder_demo/content/media/d43954eb-0edc-4aa8-a842-d99f413020be.yml b/modules/thunder_demo/content/media/d43954eb-0edc-4aa8-a842-d99f413020be.yml deleted file mode 100644 index d70025fe8..000000000 --- a/modules/thunder_demo/content/media/d43954eb-0edc-4aa8-a842-d99f413020be.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: d43954eb-0edc-4aa8-a842-d99f413020be - bundle: image - default_langcode: en - depends: - 4533f02b-f720-46cb-acbb-84255b302ef1: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: thunderday_burda_2017011555.jpg - created: - - - value: 1600160861 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Kerstin Seipt, www.kerstinseipt-photography.de' - field_image: - - - entity: 4533f02b-f720-46cb-acbb-84255b302ef1 - alt: '' - title: '' - width: 3543 - height: 2362 diff --git a/modules/thunder_demo/content/media/d5170777-5d26-423a-8710-e009d47ee979.yml b/modules/thunder_demo/content/media/d5170777-5d26-423a-8710-e009d47ee979.yml deleted file mode 100644 index 394259241..000000000 --- a/modules/thunder_demo/content/media/d5170777-5d26-423a-8710-e009d47ee979.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: d5170777-5d26-423a-8710-e009d47ee979 - bundle: image - default_langcode: en - depends: - 2387f16f-68c8-4297-a998-954c7ef66dc0: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: thunderday_burda_2017011817.jpg - created: - - - value: 1600160861 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Kerstin Seipt, www.kerstinseipt-photography.de' - field_image: - - - entity: 2387f16f-68c8-4297-a998-954c7ef66dc0 - alt: '' - title: '' - width: 3543 - height: 2362 diff --git a/modules/thunder_demo/content/media/dd45a3e7-ce93-41e8-bffe-2020211c2b5b.yml b/modules/thunder_demo/content/media/dd45a3e7-ce93-41e8-bffe-2020211c2b5b.yml deleted file mode 100644 index f4fe2a7ec..000000000 --- a/modules/thunder_demo/content/media/dd45a3e7-ce93-41e8-bffe-2020211c2b5b.yml +++ /dev/null @@ -1,53 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: dd45a3e7-ce93-41e8-bffe-2020211c2b5b - bundle: gallery - default_langcode: en - depends: - 6fcc43bd-c374-4528-b180-ebe94c8fa6a5: media - d5170777-5d26-423a-8710-e009d47ee979: media - 4f4039ab-65a3-4ade-8d2c-6553b21cad58: media - 5734cc42-787a-464e-9836-38ffa34aad7f: media - d43954eb-0edc-4aa8-a842-d99f413020be: media - 40bbeede-898b-4574-a239-95aae6112a3d: media - 1c1b3c83-3f91-4110-871c-d612d7df1bb6: media - f34ecf01-3fce-45f6-b507-77cd9104cf96: media -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: 'Thunder Day 2017' - created: - - - value: 1600160816 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_media_images: - - - entity: 6fcc43bd-c374-4528-b180-ebe94c8fa6a5 - - - entity: d5170777-5d26-423a-8710-e009d47ee979 - - - entity: 4f4039ab-65a3-4ade-8d2c-6553b21cad58 - - - entity: 5734cc42-787a-464e-9836-38ffa34aad7f - - - entity: d43954eb-0edc-4aa8-a842-d99f413020be - - - entity: 40bbeede-898b-4574-a239-95aae6112a3d - - - entity: 1c1b3c83-3f91-4110-871c-d612d7df1bb6 - - - entity: f34ecf01-3fce-45f6-b507-77cd9104cf96 diff --git a/modules/thunder_demo/content/media/df43ad97-ab4f-4f15-84c0-f10009b8fdb0.yml b/modules/thunder_demo/content/media/df43ad97-ab4f-4f15-84c0-f10009b8fdb0.yml deleted file mode 100644 index b025c67ff..000000000 --- a/modules/thunder_demo/content/media/df43ad97-ab4f-4f15-84c0-f10009b8fdb0.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: df43ad97-ab4f-4f15-84c0-f10009b8fdb0 - bundle: image - default_langcode: en - depends: - 63c664f3-d403-4509-b90c-b945a69431b5: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: Thunder - created: - - - value: 1600163434 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_image: - - - entity: 63c664f3-d403-4509-b90c-b945a69431b5 - alt: '' - title: '' - width: 3500 - height: 2333 diff --git a/modules/thunder_demo/content/media/f34ecf01-3fce-45f6-b507-77cd9104cf96.yml b/modules/thunder_demo/content/media/f34ecf01-3fce-45f6-b507-77cd9104cf96.yml deleted file mode 100644 index 2871fa859..000000000 --- a/modules/thunder_demo/content/media/f34ecf01-3fce-45f6-b507-77cd9104cf96.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: f34ecf01-3fce-45f6-b507-77cd9104cf96 - bundle: image - default_langcode: en - depends: - de73fbb6-9126-4eee-844f-cd4622653f83: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: thunderday_burda_2017011407.jpg - created: - - - value: 1600160861 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 1 - field_copyright: - - - value: 'Kerstin Seipt, www.kerstinseipt-photography.de' - field_image: - - - entity: de73fbb6-9126-4eee-844f-cd4622653f83 - alt: '' - title: '' - width: 3543 - height: 2362 diff --git a/modules/thunder_demo/content/media/f8ad6684-b110-4751-98b8-dbf9310f91b0.yml b/modules/thunder_demo/content/media/f8ad6684-b110-4751-98b8-dbf9310f91b0.yml deleted file mode 100644 index 74330c55b..000000000 --- a/modules/thunder_demo/content/media/f8ad6684-b110-4751-98b8-dbf9310f91b0.yml +++ /dev/null @@ -1,39 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: f8ad6684-b110-4751-98b8-dbf9310f91b0 - bundle: image - default_langcode: en - depends: - 94a2a059-a253-45a1-83e0-79fcb32133c0: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: 'Philipp Welte' - created: - - - value: 1600157248 - revision_translation_affected: - - - value: true - path: - - - alias: '' - langcode: en - pathauto: 0 - field_copyright: - - - value: 'Thunder, Hubert Burda Media' - field_image: - - - entity: 94a2a059-a253-45a1-83e0-79fcb32133c0 - alt: 'Philipp Welte' - title: 'Philipp Welte' - width: 2409 - height: 2973 diff --git a/modules/thunder_demo/content/menu_link_content/132c827a-1b30-4f67-a8df-8f41b38797fe.yml b/modules/thunder_demo/content/menu_link_content/132c827a-1b30-4f67-a8df-8f41b38797fe.yml deleted file mode 100644 index c131595cf..000000000 --- a/modules/thunder_demo/content/menu_link_content/132c827a-1b30-4f67-a8df-8f41b38797fe.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: 132c827a-1b30-4f67-a8df-8f41b38797fe - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: 'Certified Thunder Integrators' - menu_name: - - - value: footer - link: - - - uri: 'https://thunder.org/ctis' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: false - weight: - - - value: 0 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/menu_link_content/41f139d4-f1e7-4cc1-8dd6-37f86c682f49.yml b/modules/thunder_demo/content/menu_link_content/41f139d4-f1e7-4cc1-8dd6-37f86c682f49.yml deleted file mode 100644 index e5e523cdc..000000000 --- a/modules/thunder_demo/content/menu_link_content/41f139d4-f1e7-4cc1-8dd6-37f86c682f49.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: 41f139d4-f1e7-4cc1-8dd6-37f86c682f49 - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: News - menu_name: - - - value: main - link: - - - uri: 'internal:/news' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: true - weight: - - - value: -50 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/menu_link_content/5e0b1d08-af33-4a38-b3ba-f4cf85b7315a.yml b/modules/thunder_demo/content/menu_link_content/5e0b1d08-af33-4a38-b3ba-f4cf85b7315a.yml deleted file mode 100644 index 4a9e77ef5..000000000 --- a/modules/thunder_demo/content/menu_link_content/5e0b1d08-af33-4a38-b3ba-f4cf85b7315a.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: 5e0b1d08-af33-4a38-b3ba-f4cf85b7315a - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: Contact - menu_name: - - - value: footer - link: - - - uri: 'https://thunder.org/contact-us' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: false - weight: - - - value: 0 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/menu_link_content/61c592ad-015b-43e3-8cd0-03f2fdb1893d.yml b/modules/thunder_demo/content/menu_link_content/61c592ad-015b-43e3-8cd0-03f2fdb1893d.yml deleted file mode 100644 index df92f5ee9..000000000 --- a/modules/thunder_demo/content/menu_link_content/61c592ad-015b-43e3-8cd0-03f2fdb1893d.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: 61c592ad-015b-43e3-8cd0-03f2fdb1893d - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: Coalition - menu_name: - - - value: footer - link: - - - uri: 'https://thunder.org/thunder-coalition' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: false - weight: - - - value: 0 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/menu_link_content/9c2a1fbf-a72f-4ca3-b27d-e216788aa6cc.yml b/modules/thunder_demo/content/menu_link_content/9c2a1fbf-a72f-4ca3-b27d-e216788aa6cc.yml deleted file mode 100644 index 8917704a0..000000000 --- a/modules/thunder_demo/content/menu_link_content/9c2a1fbf-a72f-4ca3-b27d-e216788aa6cc.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: 9c2a1fbf-a72f-4ca3-b27d-e216788aa6cc - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: 'Case Studies' - menu_name: - - - value: footer - link: - - - uri: 'https://thunder.org/case-studies' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: false - weight: - - - value: 0 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/menu_link_content/ddba293d-6e01-4f47-aa16-6a84fbe592da.yml b/modules/thunder_demo/content/menu_link_content/ddba293d-6e01-4f47-aa16-6a84fbe592da.yml deleted file mode 100644 index 69f563372..000000000 --- a/modules/thunder_demo/content/menu_link_content/ddba293d-6e01-4f47-aa16-6a84fbe592da.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: ddba293d-6e01-4f47-aa16-6a84fbe592da - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: 'About Thunder' - menu_name: - - - value: footer - link: - - - uri: 'https://thunder.org/about-thunder' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: false - weight: - - - value: 0 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/menu_link_content/f3cace00-efd5-421d-8366-d7975754e737.yml b/modules/thunder_demo/content/menu_link_content/f3cace00-efd5-421d-8366-d7975754e737.yml deleted file mode 100644 index b31cfd130..000000000 --- a/modules/thunder_demo/content/menu_link_content/f3cace00-efd5-421d-8366-d7975754e737.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: f3cace00-efd5-421d-8366-d7975754e737 - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: Events - menu_name: - - - value: main - link: - - - uri: 'internal:/events' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: true - weight: - - - value: -49 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/modules/thunder_demo/content/node/17317a9b-c007-4933-99af-57d53e416f5d.yml b/modules/thunder_demo/content/node/17317a9b-c007-4933-99af-57d53e416f5d.yml deleted file mode 100644 index e1293bbd2..000000000 --- a/modules/thunder_demo/content/node/17317a9b-c007-4933-99af-57d53e416f5d.yml +++ /dev/null @@ -1,330 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: 17317a9b-c007-4933-99af-57d53e416f5d - bundle: article - default_langcode: en - depends: - a67c24e2-5974-42b4-9210-f918a0f230fd: taxonomy_term - dd45a3e7-ce93-41e8-bffe-2020211c2b5b: media - 5d0b5981-3c35-4160-9ada-f4f7eaf4f607: media - 2584ef49-8f36-424e-9338-c95d5cf933dc: media - 6296b850-fea3-458d-8782-3177f48e2cbe: media - 4fe40f59-8f90-4fc6-8630-fadea609a619: taxonomy_term - 038587f9-39d8-4441-a848-a62b54b08a84: taxonomy_term - 6fcc43bd-c374-4528-b180-ebe94c8fa6a5: media -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Thunder Day 2017: What you missed (if you weren''t there)' - created: - - - value: 1511258648 - promote: - - - value: true - sticky: - - - value: false - revision_translation_affected: - - - value: true - moderation_state: - - - value: published - path: - - - alias: /thunder-day-2017-community-shared-experiences-hamburg - langcode: en - pathauto: 1 - publish_state: - - - value: _none - unpublish_state: - - - value: _none - field_channel: - - - entity: a67c24e2-5974-42b4-9210-f918a0f230fd - field_paragraphs: - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 7e9a1da5-9369-4243-ba59-b53c12678b72 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160761 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Our very first Thunder Day was a huge success: More than 100 publishers and IT experts working with or interested in Thunder came together in Hamburg to exchange experiences, success stories, and business cards. Conclusion: For professional publishing, there is no way to do without Thunder.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 14cd9f78-37fd-4346-9a43-f2b8bdcbe8c6 - bundle: gallery - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160779 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: dd45a3e7-ce93-41e8-bffe-2020211c2b5b - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 8cfb5c3e-6a7a-405e-98a8-7bf1e68c9e36 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160770 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Around 120 participants from eleven countries joined us for the first Thunder Day in Hamburg. Most came from Germany but we also welcomed guests from Austria, the Czech Republic, the Netherlands, Norway, Portugal, Serbia, Switzerland, Ukraine, United Kingdom, and the United States. We had an outstanding lineup of speakers from different areas of the publishing world who shared their experiences and ideas.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 150d0236-869d-4711-8098-3dc838826713 - bundle: twitter - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600161133 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: 5d0b5981-3c35-4160-9ada-f4f7eaf4f607 - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: e50b8b0f-b498-44e5-b7d7-9da228a7655d - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160923 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

At the get-together in the evening, the participants were able to dive into relevant discussions, ask questions, and meet new people as well as consolidate acquaintances made earlier that day or beforehand.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 0b623b95-2b98-4000-bb53-9f02e7297879 - bundle: twitter - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600161142 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: 2584ef49-8f36-424e-9338-c95d5cf933dc - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 62d11693-bdc8-48ef-888f-509bdb78fae9 - bundle: twitter - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600161155 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: 6296b850-fea3-458d-8782-3177f48e2cbe - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 99874574-80bb-41e7-ad7f-092ed1856ca0 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600333308 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

For those who couldn't attend, we have good news: We recorded the sessions in the main room. The videos can be found here:

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: e8c0bc6f-2da1-41b6-aba9-bec8c07e2f64 - bundle: link - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160936 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_link: - - - uri: 'https://thunder.org/stratos-filalithis-tim-gray-innovation-collaboration-development-university-edinburgh-cms' - title: 'Stratos Filalithis and Tim Gray, University of Edinburgh: Innovation via collaboration in the development of the University of Edinburgh CMS' - options: { } - - - uri: 'https://thunder.org/nathan-maehren-open-y-bringing-digital-transformation-170-year-old-global-ymca-brand' - title: 'Nathan Maehren, YMCA of the Greater Twin Cities: Open Y – Bringing Digital Transformation to a 170-year-old global YMCA Brand' - options: { } - - - uri: 'https://thunder.org/andreas-landle-thunderstruck-agile-values-design-thinking-and-mvps-book-publishing' - title: 'Andreas Ländle, Droemer Knaur: Thunderstruck – Agile Values, Design Thinking and MVPs in Book Publishing' - options: { } - - - uri: 'https://thunder.org/richard-jones-7-dimensions-personalisation' - title: 'Richard Jones, Inviqa: Personalisation in 7 Dimensions' - options: { } - - - uri: 'https://thunder.org/oliver-berndt-contentpool-publishers-our-way-drupal-6-thunder' - title: 'Oliver Berndt, Österreichischer Wirtschaftsverlag: Contentpool for Publishers. Our way from Drupal 6 to Thunder' - options: { } - - - uri: 'https://thunder.org/martin-gaiger-adam-zielinski-digital-transformation-daily-news-publisher' - title: 'Adam Zielinski and Martin Gaiger, Telekurier Online Medien: Digital Transformation of a Daily News Publisher' - options: { } - - - uri: 'https://thunder.org/peter-bilz-wohlgemuth-johannes-haseitl-saskia-rettenbacher-case-study-ispocom-how-thunder-drives' - title: 'Johannes Haseitl, undpaul, Peter Bilz-Wohlgemuth, THE DIGITALE, and Saskia Rettenbacher, Messe München: Case Study ISPO.COM - How Thunder drives Content Marketing' - options: { } - - - uri: 'https://thunder.org/stephan-heck-thunder-and-purple-ds-serve-all-digital-channels' - title: 'Stephan Heck, sprylab technologies: Thunder and Purple DS to serve all digital channels' - options: { } - - - uri: 'https://thunder.org/patrick-lithander-alexander-dobbert-cms-requirements-content-marketing-industry' - title: 'Patrick Lithander, fischerAppelt, and Alexander Dobbert, Fork Unstable Media: CMS requirements for the content marketing industry' - options: { } - - - uri: 'https://thunder.org/thor-andre-gretland-roberto-ornelas-university-drupal-8-distribution-universities-and-colleges' - title: 'Thor Andre Gretland and Roberto Ornelas, frontkom: University – a Drupal 8 distribution for universities and colleges' - options: { } - field_seo_title: - - - value: 'Thunder Day 2017: Community shared experiences in Hamburg' - field_tags: - - - entity: 4fe40f59-8f90-4fc6-8630-fadea609a619 - - - entity: 038587f9-39d8-4441-a848-a62b54b08a84 - field_teaser_media: - - - entity: 6fcc43bd-c374-4528-b180-ebe94c8fa6a5 - field_teaser_text: - - - value: 'Our very first Thunder Day was a huge success: More than 100 publishers and IT experts working with or interested in Thunder came together in Hamburg to exchange experiences, success stories, and business cards. Conclusion: For professional publishing, there is no way to do without Thunder.' diff --git a/modules/thunder_demo/content/node/2f23186e-dcc3-4feb-997b-db72410afe16.yml b/modules/thunder_demo/content/node/2f23186e-dcc3-4feb-997b-db72410afe16.yml deleted file mode 100644 index 26af60384..000000000 --- a/modules/thunder_demo/content/node/2f23186e-dcc3-4feb-997b-db72410afe16.yml +++ /dev/null @@ -1,245 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: 2f23186e-dcc3-4feb-997b-db72410afe16 - bundle: article - default_langcode: en - depends: - 120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3: taxonomy_term - 8656ff5b-a9a5-49e4-a8e8-0d7c5bc2678b: media - d6de25c8-c089-4b62-b69a-d43dfee83492: taxonomy_term - bdaf83bd-2f64-4b35-a458-2e1ac0fbf4f9: taxonomy_term - df43ad97-ab4f-4f15-84c0-f10009b8fdb0: media -default: - revision_uid: - - - target_id: 1 - status: - - - value: false - uid: - - - target_id: 1 - title: - - - value: 'Thunder, the Drupal distribution for professional publishing' - created: - - - value: 1600163163 - promote: - - - value: true - sticky: - - - value: false - revision_translation_affected: - - - value: true - moderation_state: - - - value: unpublished - path: - - - alias: /thunder-drupal-distribution-professional-publishing - langcode: en - pathauto: 1 - publish_state: - - - value: _none - unpublish_state: - - - value: _none - field_channel: - - - entity: 120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3 - field_paragraphs: - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: bc281376-68d4-4311-90c8-2872a810ae53 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600163458 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Thunder is the Drupal 8 distribution for professional publishing. Thunder was designed by Hubert Burda Media and released as open-source software under the GNU General Public License in 2016. As members of the Thunder community, publishers, partners, and developers build custom extensions and share them with the community to further enhance Thunder.

\r\n\r\n

Thunder consists of the current Drupal functionality, lots of handpicked publisher-centric modules with custom enhancements (our own Thunder Admin Theme, the Paragraphs module, the Media Entity module and lots more), and an environment which makes it easy to install, deploy and add new functionality (e.g. the Thunder Updater).

\r\n\r\n

To learn more about Thunder projects, read these case studies: German magazine Mein Schöner Garten (Gardening Magazine for Hubert Burda Media), US magazine American Heritage (American Heritage Magazine Migration – Drupal 8), and Serbian television and radio station PannonRTV (News portal for media house – PannonRTV).

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 20043ff5-c610-47d2-9305-178a0c88d2ec - bundle: pinterest - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600163473 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: 8656ff5b-a9a5-49e4-a8e8-0d7c5bc2678b - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 1d7d8be7-2cd9-451f-8bdf-8b84c64dd221 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600163484 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

About the idea:

\r\n\r\n

We at the Thunder Core Team believe that publishers do not compete with each other through technology, but rather through content and brands. That is why the German publisher Hubert Burda Media established the Thunder community which aims to join forces among media companies by sharing code and innovation power. The goal is to innovate faster and spend less money overall by working together.

\r\n\r\n

The Thunder community’s core product is the open-source content management system Thunder. Community members develop useful modules, use them for their own purposes and share them with the community by publishing them under the GNU General Public License. Neither Hubert Burda Media nor the other publishers in the community charge anyone for their contributions.

\r\n\r\n

Any company publishing content professionally is welcome as a member of the Thunder community - both as user and as contributor. Anyone can join by contributing to the distribution. The usefulness and richness of Thunder’s functionality directly benefit from the number of contributors.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: fdfbc78e-f5be-4e40-a9cf-ba3201a3c3fa - bundle: link - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600163505 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_link: - - - uri: 'https://thunder.org/' - title: 'Visit thunder.org' - options: { } - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 3596a508-42ab-4030-92aa-28f7ae3c1877 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600163529 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Why Drupal was chosen: 

\r\n\r\n

For Burda, Drupal is the content management platform of choice. It is a free and open-source content-management framework written in PHP and distributed under the GNU General Public License.

\r\n\r\n

The standard Drupal core already provides the essential features, e.g. user management, menu management, RSS feeds, taxonomy, page layout customization, and system administration. It is easily adaptable and extensible with thousands of modules provided by a global community of users and developers. In addition, developers at Hubert Burda Media have had previous good experiences with Drupal. Drupal is therefore a tried and tested basis.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: d3bcd37c-c7ac-4d00-a7d2-d85bed1112f2 - bundle: quote - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600163636 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

\"Since we get a lot from the Drupal community, we give our best to contribute back, e.g. by fixing the bugs we find through automated tests and by supporting Drupal events and code sprints with developer time, talks, and sponsoring.\"

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 0b132944-aa92-4649-9602-96354787a8c1 - bundle: link - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600163651 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_link: - - - uri: 'https://www.drupal.org/case-study/thunder-the-drupal-8-distribution-for-professional-publishing' - title: 'Read the case study at drupal.org' - options: { } - field_seo_title: - - - value: 'Thunder, the Drupal distribution for professional publishing' - field_tags: - - - entity: d6de25c8-c089-4b62-b69a-d43dfee83492 - - - entity: bdaf83bd-2f64-4b35-a458-2e1ac0fbf4f9 - field_teaser_media: - - - entity: df43ad97-ab4f-4f15-84c0-f10009b8fdb0 - field_teaser_text: - - - value: 'Thunder is the Drupal distribution for professional publishing. Thunder was designed by Hubert Burda Media and released as open-source software under the GNU General Public License in 2016. As members of the Thunder community, publishers, partners, and developers build custom extensions and share them with the community to further enhance Thunder.' diff --git a/modules/thunder_demo/content/node/383b2b08-01be-464d-8cfb-a265d2fd46b9.yml b/modules/thunder_demo/content/node/383b2b08-01be-464d-8cfb-a265d2fd46b9.yml deleted file mode 100644 index bf52866bd..000000000 --- a/modules/thunder_demo/content/node/383b2b08-01be-464d-8cfb-a265d2fd46b9.yml +++ /dev/null @@ -1,194 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: 383b2b08-01be-464d-8cfb-a265d2fd46b9 - bundle: article - default_langcode: en - depends: - 120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3: taxonomy_term - 9c2cafe0-3345-4cd3-ad3c-2d8ff85b9db5: media - f9eb68a8-9bc1-4209-a7a0-fa72cbffecf6: taxonomy_term - 593c8619-b941-4bcb-93ef-0574cbbb49ad: taxonomy_term - 34478597-153e-4b96-b275-4de573e1116c: media -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Thunder worldwide' - created: - - - value: 1580723753 - promote: - - - value: true - sticky: - - - value: false - revision_translation_affected: - - - value: true - moderation_state: - - - value: published - path: - - - alias: /celebrating-20-certified-thunder-integrators - langcode: en - pathauto: 1 - publish_state: - - - value: _none - unpublish_state: - - - value: _none - field_channel: - - - entity: 120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3 - field_paragraphs: - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 5ba05849-b4b3-4c24-83a4-1556d3b9b8e6 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160244 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

The Thunder community keeps growing and growing! In December we welcomed our 20th Certified Thunder Integrator and we would like to use this occasion to provide you a short update.

\r\n\r\n

Our 20 Certified Thunder Integrators are based in a total of 55 cities in 21 countries. In Germany alone there are 18 cities in which Thunder experts are based. Those located furthest away from Munich (where Thunder originated) are Valuebound in San Jose, California (9,458km) and Netnode in Chiang-Mai, Thailand (8,279km).

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 3cf67f3f-f42d-4e1d-b9a3-2b2d2c53846b - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160252 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

More than 634 employees work at our CTIs. If one were to add up the time spent registered on drupal.org it would amount to more than 3000 years of Drupal experience!

\r\n\r\n

We ourselves do not even know how many Thunder sites there are in total. As an open source product, anyone can download, use and change our distribution without our knowledge. On drupal.org more than 700 sites report using Thunder. Our CTIs have by themselves created more than 85 Thunder websites and share their experiences with the community.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: d363da33-ab13-4188-a9e3-11504db06553 - bundle: image - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160270 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_image: - - - entity: 9c2cafe0-3345-4cd3-ad3c-2d8ff85b9db5 - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 0787147f-3a78-4067-a186-4bec131c9f24 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160338 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

About our CTI program
\r\nCertified Thunder Integrators (CTI) are IT consultancies, developers, agencies, and similar IT professionals with proven knowledge and practical experience in managing and implementing successful Thunder projects. CTIs need to be certified by the Thunder Core Team. They can help you to implement your Thunder site.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: ecea85e2-cc41-48a7-94b0-2924096c2cc6 - bundle: link - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600160348 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_link: - - - uri: 'https://thunder.org/ctis' - title: 'Learn more about our Certified Thunder Integrators' - options: { } - field_seo_title: - - - value: 'Celebrating 20 Certified Thunder Integrators' - field_tags: - - - entity: f9eb68a8-9bc1-4209-a7a0-fa72cbffecf6 - - - entity: 593c8619-b941-4bcb-93ef-0574cbbb49ad - field_teaser_media: - - - entity: 34478597-153e-4b96-b275-4de573e1116c - field_teaser_text: - - - value: 'The Thunder community keeps growing and growing! In December we welcomed our 20th Certified Thunder Integrator and we would like to use this occasion to provide you a short update.' diff --git a/modules/thunder_demo/content/node/bd5c625d-9074-40f8-99e4-91923ffdeb84.yml b/modules/thunder_demo/content/node/bd5c625d-9074-40f8-99e4-91923ffdeb84.yml deleted file mode 100644 index 8b1727c3a..000000000 --- a/modules/thunder_demo/content/node/bd5c625d-9074-40f8-99e4-91923ffdeb84.yml +++ /dev/null @@ -1,243 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: bd5c625d-9074-40f8-99e4-91923ffdeb84 - bundle: article - default_langcode: en - depends: - 120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3: taxonomy_term - f8ad6684-b110-4751-98b8-dbf9310f91b0: media - d6de25c8-c089-4b62-b69a-d43dfee83492: taxonomy_term - 4fe40f59-8f90-4fc6-8630-fadea609a619: taxonomy_term - 31457b1e-0122-46a6-b3ab-edfa0c4b801a: media -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Burda launches worldwide coalition of industry partners and releases open-source online CMS Thunder' - created: - - - value: 1458200750 - promote: - - - value: true - sticky: - - - value: false - revision_translation_affected: - - - value: true - moderation_state: - - - value: published - path: - - - alias: /burda-released-open-source-cms-thunder - langcode: en - pathauto: 1 - publish_state: - - - value: _none - unpublish_state: - - - value: _none - field_channel: - - - entity: 120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3 - field_paragraphs: - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 8ae4ce87-50e0-4d29-9480-fea3124c4b81 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600152523 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

As of today, international media group Hubert Burda Media makes it's Drupal 8 based Thunder Content Management System (CMS) available online as a free open-source platform for use and further development by other publishers. With this move, Burda joins forces with sector and industry partners, aiming to develop the best open-source CMS platform for publishers. Burda believes that in today’s world, successful media offerings result from the right combination of quality journalism and technology expertise. For the media company, this meant future-proofing its Content Management System by developing Thunder, an open-source system based on leading-edge technology, now available online free of charge for use and continuous development.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 98805d6a-92f6-41d9-92cf-519ac5d96ad7 - bundle: image - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600153544 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_image: - - - entity: f8ad6684-b110-4751-98b8-dbf9310f91b0 - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: e5cb5587-0f9e-44f1-9c63-babdfd8a84f7 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600153597 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Board Member Philipp Welte explains, “Success in this new era of publishing can only be achieved by keeping up with the lightning speed of technological progress. No publisher in the world can do this alone, so we have to leave our historical silos behind, share our knowledge, cross traditional boundaries and learn how to work in a much more connected way. Thunder symbolizes this new era of collaboration: We have invested a lot of development effort, but we are not keeping the results for ourselves. We are putting it out there, to the core of our industry, so everyone can contribute to its continued enhancement. Our aim is to work with our partners to develop the best technology foundation for publishing the best journalistic content.”

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: fb9a345b-bb21-4439-80f8-acca2c97cad6 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600153602 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Worldwide collaboration — The Thunder Coalition
\r\nWith the launch of the new CMS, Burda is creating a worldwide coalition for publishers, industry partners, and developers. At the core of the community is a team of publishing experts and developers led by Ingo Rübe, CTO for Burda’s German publishing operations, and initiator of Thunder. This team will also be responsible for coordinating the continuous development and enhancement of Thunder. Ingo Rübe explains,“A CMS is no longer a strategic differentiator, especially in the consumer’s perception. Thunder helps media companies break free from expensive legacy systems, and focus on the development of their content and brands.”

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: fa26621a-16c2-4a33-b2fa-a4ab9c749b93 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600153621 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Innovative CMS technology enriched by custom features for publishers
\r\nThunder is a Drupal distribution based on the new version 8 of the framework, released in November 2015. It features a range of publisher-centric Drupal modules with custom enhancements, including tools for interactive content, IVW counting tools, single sign-on (SSO) and Responsive Web Design (RWD). With RWD, the layout of both the front-end (websites) and the back-end (authoring tool) automatically adjusts to each user’s device. Thunder users also benefit from a whole range of channel- and feature-specific enhancements through collaboration with industry partners.

\r\n\r\n

Burda have already migrated their Playboy and Instyle brands to Thunder. Florian Boitin, Editor-in-Chief of Playboy, remembers: “Over six months ago, we were one of the first brands to integrate Thunder into our editorial workflows, and we are proud to have laid the foundations for something really big. We were able to contribute to the design of Thunder by leveraging our long-standing experience of different CMS platforms. We are now reaping the benefits of further development efforts by the community, both in terms of technology and content.”

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 86b58a17-82ce-4c69-bb2b-e087b6e756a6 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600153630 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Thunder was released under the GNU General Public License, meaning the software can be used and enhanced by all users free of charge.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 086756da-61ba-4447-9727-e6ddca14e0e7 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600153642 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

For more information about Thunder, available extensions, and the Thunder Coalition, visit www.thunder.org.

\r\n" - format: basic_html - field_seo_title: - - - value: 'Burda released open source CMS Thunder' - field_tags: - - - entity: d6de25c8-c089-4b62-b69a-d43dfee83492 - - - entity: 4fe40f59-8f90-4fc6-8630-fadea609a619 - field_teaser_media: - - - entity: 31457b1e-0122-46a6-b3ab-edfa0c4b801a - field_teaser_text: - - - value: 'As of today, international media group Hubert Burda Media makes its Drupal 8 based Thunder Content Management System (CMS) available online as a free open-source platform for use and further development by other publishers. With this move, Burda joins forces with sector and industry partners, aiming to develop the best open-source CMS platform for publishers. Burda believes that in today’s world, successful media offerings result from the right combination of quality journalism and technology expertise. For the media company, this meant future-proofing its Content Management System by developing Thunder, an open-source system based on leading-edge technology, now available online free of charge for use and continuous development.' diff --git a/modules/thunder_demo/content/node/efc68dc1-649e-4ac8-ad95-78cd404f22a7.yml b/modules/thunder_demo/content/node/efc68dc1-649e-4ac8-ad95-78cd404f22a7.yml deleted file mode 100644 index 2f6f6f4cf..000000000 --- a/modules/thunder_demo/content/node/efc68dc1-649e-4ac8-ad95-78cd404f22a7.yml +++ /dev/null @@ -1,293 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: efc68dc1-649e-4ac8-ad95-78cd404f22a7 - bundle: article - default_langcode: en - depends: - a67c24e2-5974-42b4-9210-f918a0f230fd: taxonomy_term - 765b7c3f-e70c-4cdb-85c6-d0d329919eec: media - 83294827-6a30-43ff-b515-b73e86e8205a: media - 1348d981-3575-4c32-81b4-ae758e43d38e: media - 17e3275e-aed4-4780-be08-89e839a0be5f: media - c8b73bd1-1e4b-477e-96d9-580be6dab017: media - 4fe40f59-8f90-4fc6-8630-fadea609a619: taxonomy_term - 038587f9-39d8-4441-a848-a62b54b08a84: taxonomy_term - 81392281-1bf3-4929-b887-c8096ebc01e4: media -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Thunder Day 2018 - cool, global and forward-looking' - created: - - - value: 1543400800 - promote: - - - value: true - sticky: - - - value: false - revision_translation_affected: - - - value: true - moderation_state: - - - value: published - path: - - - alias: /thunder-day-2018-community-meets-berlin - langcode: en - pathauto: 1 - publish_state: - - - value: _none - unpublish_state: - - - value: _none - field_channel: - - - entity: a67c24e2-5974-42b4-9210-f918a0f230fd - field_paragraphs: - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 1a382549-f7f3-4828-af64-37ba9cdf7804 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600162115 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

The future of Online Publishing was the central focus at Thunder Day 2018. Experts from media, IT, and open source not only shared their experiences of the media world with Online Publishing but also provided food for thought regarding future trends, expectations, and challenges. Particular attention was given to the question as to how income can be generated in the future from sources other than classic advertising. Numerous speakers were present, from companies such as Microsoft, Gruner + Jahr, Axel Springer, and BOTlabs who provided insights into their business models and work with Open Source systems such as Drupal or Thunder.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: f3edfd03-ae49-433f-b8d2-827f34b70921 - bundle: video - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600162421 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_video: - - - entity: 765b7c3f-e70c-4cdb-85c6-d0d329919eec - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 4e6d04fa-0fb3-45f7-ad76-d85d46e91625 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600162414 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

With over 150 participants from 10 countries, 23 well selected speakers and a creative presenter, we pulled off a fantastic event for networking, discussions and further learing. There was a bit of everything at the event: content-rich presentations, spontaneous discussions, exciting interactive activitities, entertainment, artistic elements and a very cool location. A really lively atmosphere could be sensed, especially during the breaks and get-togeher in the evening.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 65714a95-fee2-4d5e-9169-1162d112b4fd - bundle: twitter - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600162455 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: 83294827-6a30-43ff-b515-b73e86e8205a - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: daa345c4-0d3d-41c3-9727-0bf785dd79e3 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600333523 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

All participants grouped themselves into intense conversations and discussed presentation topics. Business cards were swapped, plans discussed and there was much head-nodding and laughing as old friends met again. Each of the participants contributed to the success of the event, like individual pieces of a jigsaw puzzle. And that is exactly what Thunder Day is all about, a global platform bringing together experts from IT, Media and Open Source, enabling them to talk about topics as equals, network and discuss new ideas and perspectives.

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: d2b920ca-a456-471e-945f-4fd62ef63a9c - bundle: twitter - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600162464 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: 1348d981-3575-4c32-81b4-ae758e43d38e - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 38808a60-4437-41bb-ad69-63d93e3daa17 - bundle: text - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600333527 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_text: - - - value: "

Thunder Day 2018 ran from 26th to 27th November in Berlin and was a great success for us. We are very pleased with the positive feedback from participants which will enable us to strengthen our plans with Thunder and Thunder Day. We are already looking forward to seeing even more old friends and new faces!

\r\n" - format: basic_html - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: d60bec6f-7f08-4645-a5f5-6d558f4c4094 - bundle: twitter - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600162474 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: 17e3275e-aed4-4780-be08-89e839a0be5f - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 61167910-2695-45ec-b942-0292d7a3d272 - bundle: gallery - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1600162291 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_media: - - - entity: c8b73bd1-1e4b-477e-96d9-580be6dab017 - field_seo_title: - - - value: 'Thunder Day 2018 Community meets in Berlin' - field_tags: - - - entity: 4fe40f59-8f90-4fc6-8630-fadea609a619 - - - entity: 038587f9-39d8-4441-a848-a62b54b08a84 - field_teaser_media: - - - entity: 81392281-1bf3-4929-b887-c8096ebc01e4 - field_teaser_text: - - - value: 'The future of Online Publishing was the central focus at Thunder Day 2018. Experts from media, IT, and open source not only shared their experiences of the media world with Online Publishing but also provided food for thought regarding future trends, expectations, and challenges. Particular attention was given to the question as to how income can be generated in the future from sources other than classic advertising.' diff --git a/modules/thunder_demo/content/taxonomy_term/038587f9-39d8-4441-a848-a62b54b08a84.yml b/modules/thunder_demo/content/taxonomy_term/038587f9-39d8-4441-a848-a62b54b08a84.yml deleted file mode 100644 index 2e3d83f68..000000000 --- a/modules/thunder_demo/content/taxonomy_term/038587f9-39d8-4441-a848-a62b54b08a84.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: 038587f9-39d8-4441-a848-a62b54b08a84 - bundle: tags - default_langcode: en -default: - status: - - - value: true - name: - - - value: ThunderDay - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - path: - - - alias: /thunderday - langcode: en - pathauto: 1 diff --git a/modules/thunder_demo/content/taxonomy_term/120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3.yml b/modules/thunder_demo/content/taxonomy_term/120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3.yml deleted file mode 100644 index 4ca77467a..000000000 --- a/modules/thunder_demo/content/taxonomy_term/120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: 120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3 - bundle: channel - default_langcode: en -default: - status: - - - value: true - name: - - - value: News - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - path: - - - alias: /news - langcode: en - pathauto: 1 diff --git a/modules/thunder_demo/content/taxonomy_term/4fe40f59-8f90-4fc6-8630-fadea609a619.yml b/modules/thunder_demo/content/taxonomy_term/4fe40f59-8f90-4fc6-8630-fadea609a619.yml deleted file mode 100644 index 5a0334f62..000000000 --- a/modules/thunder_demo/content/taxonomy_term/4fe40f59-8f90-4fc6-8630-fadea609a619.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: 4fe40f59-8f90-4fc6-8630-fadea609a619 - bundle: tags - default_langcode: en -default: - status: - - - value: true - name: - - - value: Open-Source - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - path: - - - alias: /open-source - langcode: en - pathauto: 1 diff --git a/modules/thunder_demo/content/taxonomy_term/593c8619-b941-4bcb-93ef-0574cbbb49ad.yml b/modules/thunder_demo/content/taxonomy_term/593c8619-b941-4bcb-93ef-0574cbbb49ad.yml deleted file mode 100644 index 70667eeca..000000000 --- a/modules/thunder_demo/content/taxonomy_term/593c8619-b941-4bcb-93ef-0574cbbb49ad.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: 593c8619-b941-4bcb-93ef-0574cbbb49ad - bundle: tags - default_langcode: en -default: - status: - - - value: true - name: - - - value: Business - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - path: - - - alias: /business - langcode: en - pathauto: 1 diff --git a/modules/thunder_demo/content/taxonomy_term/a67c24e2-5974-42b4-9210-f918a0f230fd.yml b/modules/thunder_demo/content/taxonomy_term/a67c24e2-5974-42b4-9210-f918a0f230fd.yml deleted file mode 100644 index 0392abd0e..000000000 --- a/modules/thunder_demo/content/taxonomy_term/a67c24e2-5974-42b4-9210-f918a0f230fd.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: a67c24e2-5974-42b4-9210-f918a0f230fd - bundle: channel - default_langcode: en -default: - status: - - - value: true - name: - - - value: Events - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - path: - - - alias: /events - langcode: en - pathauto: 1 diff --git a/modules/thunder_demo/content/taxonomy_term/bdaf83bd-2f64-4b35-a458-2e1ac0fbf4f9.yml b/modules/thunder_demo/content/taxonomy_term/bdaf83bd-2f64-4b35-a458-2e1ac0fbf4f9.yml deleted file mode 100644 index 1aa848025..000000000 --- a/modules/thunder_demo/content/taxonomy_term/bdaf83bd-2f64-4b35-a458-2e1ac0fbf4f9.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: bdaf83bd-2f64-4b35-a458-2e1ac0fbf4f9 - bundle: tags - default_langcode: en -default: - status: - - - value: true - name: - - - value: 'Case Study' - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - path: - - - alias: /case-study - langcode: en - pathauto: 1 diff --git a/modules/thunder_demo/content/taxonomy_term/d6de25c8-c089-4b62-b69a-d43dfee83492.yml b/modules/thunder_demo/content/taxonomy_term/d6de25c8-c089-4b62-b69a-d43dfee83492.yml deleted file mode 100644 index 41499dcb6..000000000 --- a/modules/thunder_demo/content/taxonomy_term/d6de25c8-c089-4b62-b69a-d43dfee83492.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: d6de25c8-c089-4b62-b69a-d43dfee83492 - bundle: tags - default_langcode: en -default: - status: - - - value: true - name: - - - value: CMS - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - path: - - - alias: /cms - langcode: en - pathauto: 1 diff --git a/modules/thunder_demo/content/taxonomy_term/f9eb68a8-9bc1-4209-a7a0-fa72cbffecf6.yml b/modules/thunder_demo/content/taxonomy_term/f9eb68a8-9bc1-4209-a7a0-fa72cbffecf6.yml deleted file mode 100644 index 264fad357..000000000 --- a/modules/thunder_demo/content/taxonomy_term/f9eb68a8-9bc1-4209-a7a0-fa72cbffecf6.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: f9eb68a8-9bc1-4209-a7a0-fa72cbffecf6 - bundle: tags - default_langcode: en -default: - status: - - - value: true - name: - - - value: Agency - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - path: - - - alias: /agency - langcode: en - pathauto: 1 diff --git a/modules/thunder_demo/thunder_demo.info.yml b/modules/thunder_demo/thunder_demo.info.yml deleted file mode 100644 index 16bf7d8f6..000000000 --- a/modules/thunder_demo/thunder_demo.info.yml +++ /dev/null @@ -1,88 +0,0 @@ -name: Thunder Demo -type: module -description: Provide demo content. -package: Thunder Optional -core_version_requirement: ^10 -dependencies: - - default_content:default_content - - drupal:tour - - drupal:help -default_content: - taxonomy_term: - - 120b4c9c-82e5-4fe9-97b0-da6fefb9b5f3 - - a67c24e2-5974-42b4-9210-f918a0f230fd - - d6de25c8-c089-4b62-b69a-d43dfee83492 - - 4fe40f59-8f90-4fc6-8630-fadea609a619 - - f9eb68a8-9bc1-4209-a7a0-fa72cbffecf6 - - 593c8619-b941-4bcb-93ef-0574cbbb49ad - - 038587f9-39d8-4441-a848-a62b54b08a84 - - bdaf83bd-2f64-4b35-a458-2e1ac0fbf4f9 - node: - - bd5c625d-9074-40f8-99e4-91923ffdeb84 - - 383b2b08-01be-464d-8cfb-a265d2fd46b9 - - 17317a9b-c007-4933-99af-57d53e416f5d - - efc68dc1-649e-4ac8-ad95-78cd404f22a7 - - 2f23186e-dcc3-4feb-997b-db72410afe16 - media: - - 31457b1e-0122-46a6-b3ab-edfa0c4b801a - - f8ad6684-b110-4751-98b8-dbf9310f91b0 - - 9c2cafe0-3345-4cd3-ad3c-2d8ff85b9db5 - - 34478597-153e-4b96-b275-4de573e1116c - - dd45a3e7-ce93-41e8-bffe-2020211c2b5b - - 5d0b5981-3c35-4160-9ada-f4f7eaf4f607 - - 2584ef49-8f36-424e-9338-c95d5cf933dc - - 6296b850-fea3-458d-8782-3177f48e2cbe - - 6fcc43bd-c374-4528-b180-ebe94c8fa6a5 - - d5170777-5d26-423a-8710-e009d47ee979 - - 4f4039ab-65a3-4ade-8d2c-6553b21cad58 - - 5734cc42-787a-464e-9836-38ffa34aad7f - - d43954eb-0edc-4aa8-a842-d99f413020be - - 40bbeede-898b-4574-a239-95aae6112a3d - - 40bbeede-898b-4574-a239-95aae6112a3d - - 1c1b3c83-3f91-4110-871c-d612d7df1bb6 - - f34ecf01-3fce-45f6-b507-77cd9104cf96 - - c8b73bd1-1e4b-477e-96d9-580be6dab017 - - 765b7c3f-e70c-4cdb-85c6-d0d329919eec - - 83294827-6a30-43ff-b515-b73e86e8205a - - 1348d981-3575-4c32-81b4-ae758e43d38e - - 17e3275e-aed4-4780-be08-89e839a0be5f - - 81392281-1bf3-4929-b887-c8096ebc01e4 - - d3782161-f7b3-4e8c-a24f-f2545bb2d474 - - 13b6536a-f317-4e74-a71f-66e5c61ede65 - - 486e2773-81e6-4685-80c0-9e4f26c214a1 - - 916d281a-6097-4e26-8805-e5392ac53a0b - - 3c47da20-33f3-4bf2-bee0-bd7669d8e7aa - - 8656ff5b-a9a5-49e4-a8e8-0d7c5bc2678b - - df43ad97-ab4f-4f15-84c0-f10009b8fdb0 - file: - - c5a9a50a-20bc-48ee-89ff-6465c194f2be - - 94a2a059-a253-45a1-83e0-79fcb32133c0 - - 87530ce0-8006-4773-9ec2-98bb85c21d30 - - 50b7f62a-6c43-4ae8-b1fc-2675520fdea7 - - 0044429b-3571-4ccf-b6a1-4e7d2c5c035a - - b08692d3-765c-4422-b001-0aee9b7ea103 - - 82aa86b9-645c-4310-a7b6-9770240663b3 - - 911771d1-f8d5-4d62-ba77-e7040682c07e - - 587ac846-1c3a-4345-8995-122683d5d2a9 - - 4533f02b-f720-46cb-acbb-84255b302ef1 - - 2387f16f-68c8-4297-a998-954c7ef66dc0 - - de73fbb6-9126-4eee-844f-cd4622653f83 - - d2fd4235-9c0d-46bf-a649-e812be18cfbb - - 5abbb82e-76f3-405d-b8e3-e2d890197aba - - 4fc96a05-40d7-4651-9c87-b06f2fcaf95a - - 9a9a6603-6dba-4f33-b467-fd81bcc6a3a4 - - 038a612e-d318-4959-b23b-ee2978cd1f6c - - 7e9e28dd-35a6-48eb-bfdd-5578b250cf8c - - 63c664f3-d403-4509-b90c-b945a69431b5 - crop: - - 73fa0ae6-47b2-4719-b2fd-09dabca808d0 - - 35877b5f-300a-4456-9e8c-760a4c1c37b5 - menu_link_content: - - 41f139d4-f1e7-4cc1-8dd6-37f86c682f49 - - f3cace00-efd5-421d-8366-d7975754e737 - - 5e0b1d08-af33-4a38-b3ba-f4cf85b7315a - - 132c827a-1b30-4f67-a8df-8f41b38797fe - - 9c2a1fbf-a72f-4ca3-b27d-e216788aa6cc - - 61c592ad-015b-43e3-8cd0-03f2fdb1893d - - ddba293d-6e01-4f47-aa16-6a84fbe592da - diff --git a/modules/thunder_demo/thunder_demo.install b/modules/thunder_demo/thunder_demo.install deleted file mode 100644 index 46550e186..000000000 --- a/modules/thunder_demo/thunder_demo.install +++ /dev/null @@ -1,64 +0,0 @@ -loadEntityByUuid('node', 'efc68dc1-649e-4ac8-ad95-78cd404f22a7'); - - \Drupal::configFactory()->getEditable('tour.tour.content-paragraphs') - ->set('routes.0.route_params.node', $node->id()) - ->save(); - - $tour = \Drupal::configFactory()->getEditable('tour.tour.content-add'); - $article_last = $tour->get('tips.article-last.body'); - $article_last = str_replace('/node/7/edit', $node->toUrl('edit-form')->toString(), $article_last); - $tour->set('tips.article-last.body', $article_last)->save(); - - foreach (['editor', 'restricted_editor', 'seo'] as $role) { - if ($role = Role::load($role)) { - $role->grantPermission('access tour') - ->save(); - } - } - } -} - -/** - * Implements hook_uninstall(). - * - * Handling following steps: - * - Remove all tours from configuration. - */ -function thunder_demo_uninstall(): void { - /** @var \Drupal\Core\Config\ConfigFactoryInterface $configFactory */ - $configFactory = \Drupal::configFactory(); - $logger = \Drupal::logger('thunder_demo'); - - $tours = [ - 'tour.tour.content-add', - 'tour.tour.content-list', - 'tour.tour.content-paragraphs', - 'tour.tour.homepage', - ]; - - foreach ($tours as $tour) { - try { - $configFactory->getEditable($tour)->delete(); - } - catch (\Exception $e) { - $logger->warning(sprintf('Unable to uninstall tour: %s.', $tour)); - } - } -} diff --git a/modules/thunder_demo/thunder_demo.module b/modules/thunder_demo/thunder_demo.module deleted file mode 100644 index 895efbaf3..000000000 --- a/modules/thunder_demo/thunder_demo.module +++ /dev/null @@ -1,43 +0,0 @@ - ['olivero'], - 'content-add' => ['gin'], - 'content-list' => ['gin'], - 'content-paragraphs' => ['gin'], - ]; - - // Remove tours that are not whitelisted for provided themes. - $activeTheme = \Drupal::theme()->getActiveTheme()->getName(); - $tourId = $entity->id(); - if (isset($tourThemeMapping[$tourId]) && !in_array($activeTheme, $tourThemeMapping[$tourId])) { - $tour_tips = []; - } -} - -/** - * Implements hook_js_alter(). - */ -function thunder_demo_js_alter(array &$javascript, AttachedAssetsInterface $assets): void { - // Put the tour at the very end, because it depends on elements that are - // generated by JS. - if (isset($javascript['core/modules/tour/js/tour.js'])) { - $javascript['core/modules/tour/js/tour.js']['weight'] = 1; - } -} diff --git a/modules/thunder_gqls/graphql/thunder_menu.base.graphqls b/modules/thunder_gqls/graphql/thunder_menu.base.graphqls index a61951f9a..eadd9339d 100644 --- a/modules/thunder_gqls/graphql/thunder_menu.base.graphqls +++ b/modules/thunder_gqls/graphql/thunder_menu.base.graphqls @@ -1,7 +1,6 @@ type Menu { id: String! name: String! - items: [MenuItem] } diff --git a/modules/thunder_gqls/graphql/thunder_search_api.base.graphqls b/modules/thunder_gqls/graphql/thunder_search_api.base.graphqls new file mode 100644 index 000000000..29db90559 --- /dev/null +++ b/modules/thunder_gqls/graphql/thunder_search_api.base.graphqls @@ -0,0 +1,4 @@ +type SearchApiResult { + items: [Page!] + total: Int! +} diff --git a/modules/thunder_gqls/graphql/thunder_search_api.extension.graphqls b/modules/thunder_gqls/graphql/thunder_search_api.extension.graphqls new file mode 100644 index 000000000..e69de29bb diff --git a/modules/thunder_gqls/src/GraphQL/Buffers/SearchApiResultBuffer.php b/modules/thunder_gqls/src/GraphQL/Buffers/SearchApiResultBuffer.php new file mode 100644 index 000000000..354dfa53f --- /dev/null +++ b/modules/thunder_gqls/src/GraphQL/Buffers/SearchApiResultBuffer.php @@ -0,0 +1,101 @@ +entityTypeManager = $entityTypeManager; + } + + /** + * Add an item to the buffer. + * + * @param string|int|null $index + * The entity type of the given entity ids. + * @param array|int $id + * The entity id(s) to load. + * + * @return \Closure + * The callback to invoke to load the result for this buffer item. + */ + public function add($index, $id) { + $item = new \ArrayObject([ + 'index' => $index, + 'id' => $id, + ]); + + return $this->createBufferResolver($item); + } + + /** + * {@inheritdoc} + */ + protected function getBufferId($item) { + return $item['index']; + } + + /** + * {@inheritdoc} + */ + public function resolveBufferArray(array $buffer) { + $index = reset($buffer)['index']; + $ids = array_map(function (\ArrayObject $item) { + return (array) $item['id']; + }, $buffer); + + $ids = call_user_func_array('array_merge', $ids); + $ids = array_values(array_unique($ids)); + + // Load the buffered entities. + /** @var \Drupal\search_api\IndexInterface $index */ + $index = $this->entityTypeManager + ->getStorage('search_api_index') + ->load($index); + + $resultSet = $index->loadItemsMultiple($ids); + $entities = []; + + foreach ($resultSet as $key => $resultItem) { + if ($resultItem instanceof EntityAdapter) { + $entities[$key] = $resultItem->getEntity(); + } + } + + return array_map(function ($item) use ($entities) { + if (is_array($item['id'])) { + return array_reduce($item['id'], static function ($carry, $current) use ($entities) { + if (!empty($entities[$current])) { + $carry[] = $entities[$current]; + return $carry; + } + + return $carry; + }, []); + } + + return $entities[$item['id']] ?? NULL; + }, $buffer); + } + +} diff --git a/modules/thunder_gqls/src/GraphQL/DecoratableTypeResolver.php b/modules/thunder_gqls/src/GraphQL/DecoratableTypeResolver.php index c14e852f4..8b6720938 100644 --- a/modules/thunder_gqls/src/GraphQL/DecoratableTypeResolver.php +++ b/modules/thunder_gqls/src/GraphQL/DecoratableTypeResolver.php @@ -58,7 +58,7 @@ public function __construct(?self $resolver) { * @return string|null * The GraphQL type name or NULL if this resolver could not determine it. */ - abstract protected function resolve($object) : ?string; + abstract protected function resolve(mixed $object) : ?string; /** * Allows this type resolver to be called by the GraphQL library. @@ -75,7 +75,7 @@ abstract protected function resolve($object) : ?string; * @throws \RuntimeException * When a type was passed for which no type resolver exists in the chain. */ - public function __invoke($object) : string { + public function __invoke(mixed $object) : string { $type = $this->resolve($object); if ($type !== NULL) { return $type; diff --git a/modules/thunder_gqls/src/GraphQL/MediaTypeResolver.php b/modules/thunder_gqls/src/GraphQL/MediaTypeResolver.php index b5efeacc1..c0bc10beb 100644 --- a/modules/thunder_gqls/src/GraphQL/MediaTypeResolver.php +++ b/modules/thunder_gqls/src/GraphQL/MediaTypeResolver.php @@ -15,7 +15,7 @@ class MediaTypeResolver extends DecoratableTypeResolver { /** * {@inheritdoc} */ - protected function resolve($object) : ?string { + protected function resolve(mixed $object) : ?string { if ($object instanceof MediaInterface) { return 'Media' . $this->mapBundleToSchemaName($object->bundle()); } diff --git a/modules/thunder_gqls/src/GraphQL/PagesTypeResolver.php b/modules/thunder_gqls/src/GraphQL/PagesTypeResolver.php index 010d9b565..a2c20da32 100644 --- a/modules/thunder_gqls/src/GraphQL/PagesTypeResolver.php +++ b/modules/thunder_gqls/src/GraphQL/PagesTypeResolver.php @@ -17,7 +17,7 @@ class PagesTypeResolver extends DecoratableTypeResolver { /** * {@inheritdoc} */ - protected function resolve($object) : ?string { + protected function resolve(mixed $object) : ?string { if ($object instanceof NodeInterface || $object instanceof TermInterface || $object instanceof UserInterface) { if ($object->bundle() === 'page') { return 'BasicPage'; diff --git a/modules/thunder_gqls/src/GraphQL/ParagraphsTypeResolver.php b/modules/thunder_gqls/src/GraphQL/ParagraphsTypeResolver.php index 0b9b4f2c6..0fa823841 100644 --- a/modules/thunder_gqls/src/GraphQL/ParagraphsTypeResolver.php +++ b/modules/thunder_gqls/src/GraphQL/ParagraphsTypeResolver.php @@ -15,7 +15,7 @@ class ParagraphsTypeResolver extends DecoratableTypeResolver { /** * {@inheritdoc} */ - protected function resolve($object) : ?string { + protected function resolve(mixed $object) : ?string { if ($object instanceof ParagraphInterface) { return 'Paragraph' . $this->mapBundleToSchemaName($object->bundle()); } diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntitiesWithTerm.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntitiesWithTerm.php index 8788b2539..9ac9953ae 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntitiesWithTerm.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntitiesWithTerm.php @@ -4,7 +4,6 @@ use Drupal\graphql\GraphQL\Execution\FieldContext; use Drupal\taxonomy\TermInterface; -use Drupal\thunder_gqls\Wrappers\EntityListResponse; use Drupal\thunder_gqls\Wrappers\EntityListResponseInterface; /** @@ -119,7 +118,7 @@ public function resolve(TermInterface $term, string $type, array $bundles, strin $cacheContext ); - return new EntityListResponse($query); + return $this->entityListResponse($query); } /** diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntityLinks.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntityLinks.php index 3a3d50ab6..3c0c042c3 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntityLinks.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntityLinks.php @@ -28,23 +28,16 @@ */ class EntityLinks extends DataProducerPluginBase implements ContainerFactoryPluginInterface { - /** - * The rendering service. - * - * @var \Drupal\Core\Render\RendererInterface - */ - protected $renderer; - /** * {@inheritdoc} * * @codeCoverageIgnore */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition): self { + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition): self { return new static( $configuration, - $pluginId, - $pluginDefinition, + $plugin_id, + $plugin_definition, $container->get('renderer') ); } @@ -54,21 +47,20 @@ public static function create(ContainerInterface $container, array $configuratio * * @param array $configuration * The plugin configuration array. - * @param string $pluginId + * @param string $plugin_id * The plugin id. - * @param mixed $pluginDefinition + * @param mixed $plugin_definition * The plugin definition. * @param \Drupal\Core\Render\RendererInterface $renderer * The renderer service. */ public function __construct( array $configuration, - string $pluginId, - $pluginDefinition, - RendererInterface $renderer, + string $plugin_id, + $plugin_definition, + protected readonly RendererInterface $renderer, ) { - parent::__construct($configuration, $pluginId, $pluginDefinition); - $this->renderer = $renderer; + parent::__construct($configuration, $plugin_id, $plugin_definition); } /** diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/FocalPoint.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/FocalPoint.php index a26ab0fd0..34e7040e8 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/FocalPoint.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/FocalPoint.php @@ -3,6 +3,7 @@ namespace Drupal\thunder_gqls\Plugin\GraphQL\DataProducer; use Drupal\Core\Config\ConfigFactoryInterface; +use Drupal\Core\Config\ImmutableConfig; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\file\FileInterface; @@ -34,32 +35,18 @@ class FocalPoint extends DataProducerPluginBase implements ContainerFactoryPlugi * * @var \Drupal\Core\Config\ImmutableConfig */ - protected $config; - - /** - * The focal point manager service. - * - * @var \Drupal\focal_point\FocalPointManagerInterface - */ - protected $focalPointManager; - - /** - * The module handler. - * - * @var \Drupal\Core\Extension\ModuleHandlerInterface - */ - protected $moduleHandler; + protected ImmutableConfig $config; /** * {@inheritdoc} * * @codeCoverageIgnore */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition): self { + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition): self { return new static( $configuration, - $pluginId, - $pluginDefinition, + $plugin_id, + $plugin_definition, $container->get('config.factory'), $container->get('focal_point.manager'), $container->get('module_handler') @@ -71,9 +58,9 @@ public static function create(ContainerInterface $container, array $configuratio * * @param array $configuration * The plugin configuration array. - * @param string $pluginId + * @param string $plugin_id * The plugin id. - * @param mixed $pluginDefinition + * @param mixed $plugin_definition * The plugin definition. * @param \Drupal\Core\Config\ConfigFactoryInterface $configFactory * The config factory service. @@ -84,16 +71,14 @@ public static function create(ContainerInterface $container, array $configuratio */ public function __construct( array $configuration, - string $pluginId, - $pluginDefinition, + string $plugin_id, + $plugin_definition, ConfigFactoryInterface $configFactory, - FocalPointManagerInterface $focalPointManager, - ModuleHandlerInterface $moduleHandler, + protected readonly FocalPointManagerInterface $focalPointManager, + protected readonly ModuleHandlerInterface $moduleHandler, ) { - parent::__construct($configuration, $pluginId, $pluginDefinition); + parent::__construct($configuration, $plugin_id, $plugin_definition); $this->config = $configFactory->get('focal_point.settings'); - $this->focalPointManager = $focalPointManager; - $this->moduleHandler = $moduleHandler; } /** diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MenuLinksActiveTrail.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MenuLinksActiveTrail.php index 1faf60209..c127ca5cc 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MenuLinksActiveTrail.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MenuLinksActiveTrail.php @@ -39,30 +39,16 @@ class MenuLinksActiveTrail extends DataProducerPluginBase implements ContainerFactoryPluginInterface { use DependencySerializationTrait; - /** - * The menu link tree. - * - * @var \Drupal\Core\Menu\MenuLinkTreeInterface - */ - protected $menuLinkTree; - - /** - * The menu link tree. - * - * @var \Drupal\Core\Menu\MenuLinkManagerInterface - */ - protected $menuLinkManager; - /** * {@inheritdoc} * * @codeCoverageIgnore */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition): self { + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition): self { return new static( $configuration, - $pluginId, - $pluginDefinition, + $plugin_id, + $plugin_definition, $container->get('menu.link_tree'), $container->get('plugin.manager.menu.link') ); @@ -73,9 +59,9 @@ public static function create(ContainerInterface $container, array $configuratio * * @param array $configuration * The plugin configuration array. - * @param string $pluginId + * @param string $plugin_id * The plugin id. - * @param mixed $pluginDefinition + * @param mixed $plugin_definition * The plugin definition. * @param \Drupal\Core\Menu\MenuLinkTreeInterface $menuLinkTree * The menu link tree service. @@ -84,10 +70,8 @@ public static function create(ContainerInterface $container, array $configuratio * * @codeCoverageIgnore */ - public function __construct(array $configuration, $pluginId, $pluginDefinition, MenuLinkTreeInterface $menuLinkTree, MenuLinkManagerInterface $menuLinkManager) { - parent::__construct($configuration, $pluginId, $pluginDefinition); - $this->menuLinkTree = $menuLinkTree; - $this->menuLinkManager = $menuLinkManager; + public function __construct(array $configuration, $plugin_id, $plugin_definition, protected readonly MenuLinkTreeInterface $menuLinkTree, protected readonly MenuLinkManagerInterface $menuLinkManager) { + parent::__construct($configuration, $plugin_id, $plugin_definition); } /** diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MetaTags.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MetaTags.php index 9eacc739f..10e896ee5 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MetaTags.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MetaTags.php @@ -39,37 +39,16 @@ class MetaTags extends DataProducerPluginBase implements ContainerFactoryPluginInterface { use DataFetcherTrait; - /** - * The rendering service. - * - * @var \Drupal\Core\Render\RendererInterface - */ - protected $renderer; - - /** - * The metatag manager service. - * - * @var \Drupal\metatag\MetatagManager - */ - protected $metatagManager; - - /** - * The module handler. - * - * @var \Drupal\Core\Extension\ModuleHandlerInterface - */ - protected $moduleHandler; - /** * {@inheritdoc} * * @codeCoverageIgnore */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition): self { + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition): self { return new static( $configuration, - $pluginId, - $pluginDefinition, + $plugin_id, + $plugin_definition, $container->get('renderer'), $container->get('metatag.manager'), $container->get('module_handler') @@ -81,9 +60,9 @@ public static function create(ContainerInterface $container, array $configuratio * * @param array $configuration * The plugin configuration array. - * @param string $pluginId + * @param string $plugin_id * The plugin id. - * @param mixed $pluginDefinition + * @param mixed $plugin_definition * The plugin definition. * @param \Drupal\Core\Render\RendererInterface $renderer * The renderer service. @@ -94,16 +73,13 @@ public static function create(ContainerInterface $container, array $configuratio */ public function __construct( array $configuration, - string $pluginId, - $pluginDefinition, - RendererInterface $renderer, - MetatagManager $metatagManager, - ModuleHandlerInterface $moduleHandler, + string $plugin_id, + $plugin_definition, + protected readonly RendererInterface $renderer, + protected readonly MetatagManager $metatagManager, + protected readonly ModuleHandlerInterface $moduleHandler, ) { - parent::__construct($configuration, $pluginId, $pluginDefinition); - $this->renderer = $renderer; - $this->metatagManager = $metatagManager; - $this->moduleHandler = $moduleHandler; + parent::__construct($configuration, $plugin_id, $plugin_definition); } /** @@ -119,7 +95,7 @@ public function __construct( * @return array * Normalized metatags. */ - public function resolve($value, ?string $type, RefinableCacheableDependencyInterface $metadata): array { + public function resolve(mixed $value, ?string $type, RefinableCacheableDependencyInterface $metadata): array { if ($value instanceof ContentEntityInterface) { $context = new RenderContext(); $result = $this->renderer->executeInRenderContext($context, function () use ($value): array { diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderBreadcrumb.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderBreadcrumb.php index 08aad9e5b..348a7d95f 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderBreadcrumb.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderBreadcrumb.php @@ -32,22 +32,22 @@ class ThunderBreadcrumb extends ThunderEntitySubRequestBase { /** * The breadcrumb manager. * - * @var \Drupal\Core\Breadcrumb\BreadcrumbBuilderInterface + * @var \Drupal\Core\Breadcrumb\BreadcrumbManager */ - protected $breadcrumbManager; + protected BreadcrumbManager $breadcrumbManager; /** * The route match service. * * @var \Drupal\Core\Routing\CurrentRouteMatch */ - protected $currentRouteMatch; + protected CurrentRouteMatch $currentRouteMatch; /** * {@inheritdoc} */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition) { - $producer = parent::create($container, $configuration, $pluginId, $pluginDefinition); + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) { + $producer = parent::create($container, $configuration, $plugin_id, $plugin_definition); $producer->setCurrentRouteMatch($container->get('current_route_match')); $producer->setBreadcrumbManager($container->get('breadcrumb')); return $producer; diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityList.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityList.php index 3afcc2965..43ea0aa03 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityList.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityList.php @@ -3,7 +3,6 @@ namespace Drupal\thunder_gqls\Plugin\GraphQL\DataProducer; use Drupal\graphql\GraphQL\Execution\FieldContext; -use Drupal\thunder_gqls\Wrappers\EntityListResponse; use Drupal\thunder_gqls\Wrappers\EntityListResponseInterface; /** @@ -97,7 +96,7 @@ protected function resolve(string $type, array $bundles, int $offset, int $limit $cacheContext ); - return new EntityListResponse($query); + return $this->entityListResponse($query); } } diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityListProducerBase.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityListProducerBase.php index 610700ab2..ff4ec5723 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityListProducerBase.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityListProducerBase.php @@ -2,12 +2,13 @@ namespace Drupal\thunder_gqls\Plugin\GraphQL\DataProducer; -use Drupal\Core\Entity\EntityTypeManager; +use Drupal\Core\Entity\EntityTypeManagerInterface; use Drupal\Core\Entity\Query\QueryInterface; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\Core\Session\AccountInterface; use Drupal\graphql\GraphQL\Execution\FieldContext; use Drupal\graphql\Plugin\GraphQL\DataProducer\DataProducerPluginBase; +use Drupal\thunder_gqls\Wrappers\EntityListResponse; use GraphQL\Error\UserError; use Symfony\Component\DependencyInjection\ContainerInterface; @@ -21,54 +22,69 @@ abstract class ThunderEntityListProducerBase extends DataProducerPluginBase impl /** * The entity type manager service. * - * @var \Drupal\Core\Entity\EntityTypeManager + * @var \Drupal\Core\Entity\EntityTypeManagerInterface */ - protected $entityTypeManager; + protected EntityTypeManagerInterface $entityTypeManager; /** * The current user. * * @var \Drupal\Core\Session\AccountInterface */ - protected $currentUser; + protected AccountInterface $currentUser; + + /** + * The response wrapper service. + * + * @var \Drupal\thunder_gqls\Wrappers\EntityListResponse + */ + protected EntityListResponse $responseWrapper; /** * {@inheritdoc} */ public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition): self { - return new static( + $instance = new static( $configuration, $plugin_id, - $plugin_definition, - $container->get('entity_type.manager'), - $container->get('current_user') + $plugin_definition ); + + $instance->setResponseWrapper($container->get('thunder_gqls.entity_list_response_wrapper')); + $instance->setEntityTypeManager($container->get('entity_type.manager')); + $instance->setCurrentUser($container->get('current_user')); + + return $instance; } /** - * EntityLoad constructor. + * Set the entity type manager service. * - * @param array $configuration - * The plugin configuration array. - * @param string $pluginId - * The plugin id. - * @param array $pluginDefinition - * The plugin definition array. - * @param \Drupal\Core\Entity\EntityTypeManager $entityTypeManager + * @param \Drupal\Core\Entity\EntityTypeManagerInterface $entityTypeManager * The entity type manager service. - * @param \Drupal\Core\Session\AccountInterface $current_user - * The current user. */ - public function __construct( - array $configuration, - string $pluginId, - array $pluginDefinition, - EntityTypeManager $entityTypeManager, - AccountInterface $current_user, - ) { - parent::__construct($configuration, $pluginId, $pluginDefinition); + public function setEntityTypeManager(EntityTypeManagerInterface $entityTypeManager): void { $this->entityTypeManager = $entityTypeManager; - $this->currentUser = $current_user; + } + + /** + * Set the current user. + * + * @param \Drupal\Core\Session\AccountInterface $currentUser + * The current user. + */ + public function setCurrentUser(AccountInterface $currentUser): void { + $this->currentUser = $currentUser; + } + + /** + * Set the response wrapper service. + * + * @param \Drupal\thunder_gqls\Wrappers\EntityListResponse $responseWrapper + * The response wrapper service. + */ + public function setResponseWrapper(EntityListResponse $responseWrapper): void { + $this->responseWrapper = $responseWrapper; } /** @@ -149,7 +165,7 @@ protected function query( if (!empty($sort['field'])) { if (!empty($sort['direction']) && strtolower( $sort['direction'] - ) == 'desc') { + ) === 'desc') { $direction = 'DESC'; } else { @@ -163,10 +179,7 @@ protected function query( $query->range($offset, $limit); $storage = $this->entityTypeManager->getStorage($type); - $entityType = $storage->getEntityType(); - - $cacheContext->addCacheTags($entityType->getListCacheTags()); - $cacheContext->addCacheContexts($entityType->getListCacheContexts()); + $cacheContext->addCacheableDependency($storage->getEntityType()); return $query; } @@ -202,4 +215,17 @@ protected function createPublishedCondition(string $type, array $conditions) { ]; } + /** + * The entity list response. + * + * @param \Drupal\Core\Entity\Query\QueryInterface $query + * The entity query. + * + * @return \Drupal\thunder_gqls\Wrappers\EntityListResponse + * The entity list response. + */ + protected function entityListResponse(QueryInterface $query): EntityListResponse { + return $this->responseWrapper->setQuery($query); + } + } diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntitySubRequestBase.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntitySubRequestBase.php index 950bf5f06..709fab4c4 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntitySubRequestBase.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntitySubRequestBase.php @@ -18,37 +18,16 @@ */ abstract class ThunderEntitySubRequestBase extends DataProducerPluginBase implements ContainerFactoryPluginInterface { - /** - * The HTTP kernel service. - * - * @var \Symfony\Component\HttpKernel\HttpKernelInterface - */ - protected $httpKernel; - - /** - * The current request. - * - * @var \Symfony\Component\HttpFoundation\Request - */ - protected $currentRequest; - - /** - * The rendering service. - * - * @var \Drupal\Core\Render\RendererInterface - */ - protected $renderer; - /** * {@inheritdoc} * * @codeCoverageIgnore */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition) { + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) { return new static( $configuration, - $pluginId, - $pluginDefinition, + $plugin_id, + $plugin_definition, $container->get('http_kernel'), $container->get('request_stack')->getCurrentRequest(), $container->get('renderer') @@ -60,9 +39,9 @@ public static function create(ContainerInterface $container, array $configuratio * * @param array $configuration * The plugin configuration array. - * @param string $pluginId + * @param string $plugin_id * The plugin id. - * @param mixed $pluginDefinition + * @param mixed $plugin_definition * The plugin definition. * @param \Symfony\Component\HttpKernel\HttpKernelInterface $httpKernel * The HTTP kernel service. @@ -73,22 +52,19 @@ public static function create(ContainerInterface $container, array $configuratio */ public function __construct( array $configuration, - string $pluginId, - $pluginDefinition, - HttpKernelInterface $httpKernel, - Request $currentRequest, - RendererInterface $renderer, + string $plugin_id, + $plugin_definition, + protected readonly HttpKernelInterface $httpKernel, + protected readonly Request $currentRequest, + protected readonly RendererInterface $renderer, ) { - parent::__construct($configuration, $pluginId, $pluginDefinition); - $this->httpKernel = $httpKernel; - $this->currentRequest = $currentRequest; - $this->renderer = $renderer; + parent::__construct($configuration, $plugin_id, $plugin_definition); } /** * {@inheritdoc} */ - public function resolveField(FieldContext $fieldContext) { + public function resolveField(FieldContext $field) { $contextValues = $this->getContextValues(); if (!isset($contextValues['path'])) { @@ -96,7 +72,7 @@ public function resolveField(FieldContext $fieldContext) { } $url = $this->currentRequest->getSchemeAndHttpHost() . $contextValues['path']; - $request = $this->createRequest($this->currentRequest, $url, $fieldContext); + $request = $this->createRequest($this->currentRequest, $url, $field); $response = $this->httpKernel->handle($request, HttpKernelInterface::SUB_REQUEST); if ($response instanceof SubRequestResponse) { @@ -116,13 +92,13 @@ public function resolveField(FieldContext $fieldContext) { * The current main request. * @param string $url * The url to run the subrequest on. - * @param \Drupal\graphql\GraphQL\Execution\FieldContext $fieldContext + * @param \Drupal\graphql\GraphQL\Execution\FieldContext $field * The field context. * * @return \Symfony\Component\HttpFoundation\Request * The request object. */ - protected function createRequest(Request $current, string $url, FieldContext $fieldContext) { + protected function createRequest(Request $current, string $url, FieldContext $field): Request { $request = Request::create( $url, 'GET', @@ -132,7 +108,7 @@ protected function createRequest(Request $current, string $url, FieldContext $fi $current->server->all() ); - $request->attributes->set('_graphql_subrequest', function (CacheableMetadata $cacheableMetadata) use ($fieldContext) { + $request->attributes->set('_graphql_subrequest', function (CacheableMetadata $cacheableMetadata) use ($field) { if (!method_exists($this, 'resolve')) { throw new \LogicException('Missing data producer resolve method.'); } @@ -143,12 +119,12 @@ protected function createRequest(Request $current, string $url, FieldContext $fi [$this, 'resolve'], array_values(array_merge($contextValues, [ $cacheableMetadata, - $fieldContext, + $field, ])) )); if (!$context->isEmpty()) { - $fieldContext->addCacheableDependency($context->pop()); + $field->addCacheableDependency($context->pop()); } return $result ?? ''; diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderImage.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderImage.php index 8c839f525..f3ff086db 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderImage.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderImage.php @@ -34,37 +34,16 @@ */ class ThunderImage extends DataProducerPluginBase implements ContainerFactoryPluginInterface { - /** - * The rendering service. - * - * @var \Drupal\Core\Render\RendererInterface - */ - protected $renderer; - - /** - * The image factory. - * - * @var \Drupal\Core\Image\ImageFactory - */ - protected $imageFactory; - - /** - * The file URL generator service. - * - * @var \Drupal\Core\File\FileUrlGeneratorInterface - */ - protected $fileUrlGenerator; - /** * {@inheritdoc} * * @codeCoverageIgnore */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition): self { + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition): self { return new static( $configuration, - $pluginId, - $pluginDefinition, + $plugin_id, + $plugin_definition, $container->get('renderer'), $container->get('image.factory'), $container->get('file_url_generator') @@ -76,9 +55,9 @@ public static function create(ContainerInterface $container, array $configuratio * * @param array $configuration * The plugin configuration array. - * @param string $pluginId + * @param string $plugin_id * The plugin id. - * @param mixed $pluginDefinition + * @param mixed $plugin_definition * The plugin definition. * @param \Drupal\Core\Render\RendererInterface $renderer * The renderer service. @@ -91,16 +70,13 @@ public static function create(ContainerInterface $container, array $configuratio */ public function __construct( array $configuration, - $pluginId, - $pluginDefinition, - RendererInterface $renderer, - ImageFactory $imageFactory, - FileUrlGeneratorInterface $fileUrlGenerator, + $plugin_id, + $plugin_definition, + protected readonly RendererInterface $renderer, + protected readonly ImageFactory $imageFactory, + protected readonly FileUrlGeneratorInterface $fileUrlGenerator, ) { - parent::__construct($configuration, $pluginId, $pluginDefinition); - $this->renderer = $renderer; - $this->imageFactory = $imageFactory; - $this->fileUrlGenerator = $fileUrlGenerator; + parent::__construct($configuration, $plugin_id, $plugin_definition); } /** diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderJsonLd.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderJsonLd.php index 9bb67b68d..4e777cf1a 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderJsonLd.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderJsonLd.php @@ -35,22 +35,22 @@ class ThunderJsonLd extends ThunderEntitySubRequestBase { * * @var \Drupal\metatag\MetatagManager|null */ - protected $metatagManager; + protected ?MetatagManager $metatagManager; /** * The module handler. * * @var \Drupal\Core\Extension\ModuleHandlerInterface */ - protected $moduleHandler; + protected ModuleHandlerInterface $moduleHandler; /** * {@inheritdoc} * * @codeCoverageIgnore */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition) { - $producer = parent::create($container, $configuration, $pluginId, $pluginDefinition); + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) { + $producer = parent::create($container, $configuration, $plugin_id, $plugin_definition); $producer->setMetatagManager($container->get('metatag.manager', ContainerInterface::NULL_ON_INVALID_REFERENCE)); $producer->setModuleHandler($container->get('module_handler')); return $producer; diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderLanguage.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderLanguage.php index 5adf5cd85..520bc0fb2 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderLanguage.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderLanguage.php @@ -38,13 +38,13 @@ class ThunderLanguage extends ThunderEntitySubRequestBase { * * @var \Drupal\Core\Language\LanguageManagerInterface */ - protected $languageManager; + protected LanguageManagerInterface $languageManager; /** * {@inheritdoc} */ - public static function create(ContainerInterface $container, array $configuration, $pluginId, $pluginDefinition) { - $producer = parent::create($container, $configuration, $pluginId, $pluginDefinition); + public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) { + $producer = parent::create($container, $configuration, $plugin_id, $plugin_definition); $producer->setLanguageManager($container->get('language_manager')); return $producer; } diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderRedirect.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderRedirect.php index cad408b5e..b0582d6ba 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderRedirect.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderRedirect.php @@ -32,27 +32,6 @@ */ class ThunderRedirect extends DataProducerPluginBase implements ContainerFactoryPluginInterface { - /** - * Optional redirect module repository. - * - * @var \Drupal\redirect\RedirectRepository|null - */ - protected $redirectRepository; - - /** - * The language manager. - * - * @var \Drupal\Core\Language\LanguageManagerInterface - */ - protected $languageManager; - - /** - * The path validator. - * - * @var \Drupal\Core\Path\PathValidatorInterface - */ - protected $pathValidator; - /** * {@inheritdoc} * @@ -74,9 +53,9 @@ public static function create(ContainerInterface $container, array $configuratio * * @param array $configuration * The plugin configuration. - * @param string $pluginId + * @param string $plugin_id * The plugin id. - * @param mixed $pluginDefinition + * @param mixed $plugin_definition * The plugin definition. * @param \Drupal\Core\Language\LanguageManagerInterface $languageManager * The language manager. @@ -89,16 +68,13 @@ public static function create(ContainerInterface $container, array $configuratio */ public function __construct( array $configuration, - $pluginId, - $pluginDefinition, - LanguageManagerInterface $languageManager, - PathValidatorInterface $pathValidator, - ?RedirectRepository $redirectRepository = NULL, + $plugin_id, + $plugin_definition, + protected readonly LanguageManagerInterface $languageManager, + protected readonly PathValidatorInterface $pathValidator, + protected readonly ?RedirectRepository $redirectRepository = NULL, ) { - parent::__construct($configuration, $pluginId, $pluginDefinition); - $this->languageManager = $languageManager; - $this->pathValidator = $pathValidator; - $this->redirectRepository = $redirectRepository; + parent::__construct($configuration, $plugin_id, $plugin_definition); } /** diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderSearchApi.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderSearchApi.php new file mode 100644 index 000000000..d26ecc9c6 --- /dev/null +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderSearchApi.php @@ -0,0 +1,122 @@ + 'status', + 'value' => TRUE, + 'operator' => '=', + ], + [ + 'field' => 'search_api_language', + 'value' => $this->languageManager->getCurrentLanguage(LanguageInterface::TYPE_CONTENT)->getId(), + 'operator' => '=', + ], + ]; + + // Add default sorts. + $sortBy = $sortBy ?: [ + [ + 'field' => 'search_api_relevance', + 'direction' => QueryInterface::SORT_DESC, + ], + ]; + + $query = $this->buildBaseQuery( + $limit, + $offset, + $index, + $sortBy, + $conditions, + $search, + $cacheContext + ); + + return $this->searchApiResponse($query); + } + +} diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderSearchApiProducerBase.php b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderSearchApiProducerBase.php new file mode 100644 index 000000000..e568b6971 --- /dev/null +++ b/modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderSearchApiProducerBase.php @@ -0,0 +1,181 @@ +setEntityTypeManager($container->get('entity_type.manager')); + $instance->setLanguageManager($container->get('language_manager')); + $instance->setResponseWrapper($container->get('thunder_gqls.search_api_response_wrapper')); + + return $instance; + } + + /** + * Set the entity type manager service. + * + * @param \Drupal\Core\Entity\EntityTypeManagerInterface $entityTypeManager + * The entity type manager service. + */ + public function setEntityTypeManager(EntityTypeManagerInterface $entityTypeManager): void { + $this->entityTypeManager = $entityTypeManager; + } + + /** + * Set the language manager service. + * + * @param \Drupal\Core\Language\LanguageManagerInterface $languageManager + * The language manager service. + */ + public function setLanguageManager(LanguageManagerInterface $languageManager): void { + $this->languageManager = $languageManager; + } + + /** + * Set the response wrapper service. + * + * @param \Drupal\thunder_gqls\Wrappers\SearchApiResponse $responseWrapper + * The response wrapper service. + */ + public function setResponseWrapper(SearchApiResponse $responseWrapper): void { + $this->responseWrapper = $responseWrapper; + } + + /** + * Build base search api query. + * + * @param int $limit + * Limit of the query. + * @param int $offset + * Offset of the query. + * @param string $index + * Id of the search api index. + * @param array|null $sortBy + * List of sorts. + * @param array|null $conditions + * List of conditions to filter the result. + * @param string|null $search + * Query Search. + * @param \Drupal\graphql\GraphQL\Execution\FieldContext $cacheContext + * The caching context related to the current field. + * + * @return \Drupal\search_api\Query\QueryInterface|null + * The query interface. + * + * @throws \Drupal\search_api\SearchApiException + */ + protected function buildBaseQuery( + int $limit, + int $offset, + string $index, + ?array $sortBy, + ?array $conditions, + ?string $search, + FieldContext $cacheContext, + ): ?QueryInterface { + + // Make sure offset is zero or positive. + $offset = max($offset, 0); + + // Make sure limit is positive and cap the max items. + if ($limit <= 0) { + $limit = 10; + } + if ($limit > static::MAX_ITEMS) { + throw new UserError( + sprintf('Exceeded maximum query limit: %s.', static::MAX_ITEMS) + ); + } + + $searchIndex = Index::load($index); + if (!$searchIndex) { + return NULL; + } + + $query = $searchIndex->query(); + + foreach ($conditions as $condition) { + $query->addCondition($condition['field'], $condition['value'], $condition['operator']); + } + + foreach ($sortBy as $sort) { + $direction = $sort['direction'] ?? QueryInterface::SORT_ASC; + $query->sort($sort['field'], $direction); + } + + if (!empty($search)) { + $query->keys($search); + } + + $query->range($offset, $limit); + $cacheContext->addCacheableDependency($searchIndex); + + return $query; + } + + /** + * The search api response. + * + * @param \Drupal\search_api\Query\QueryInterface $query + * The search api query. + * + * @return \Drupal\thunder_gqls\Wrappers\SearchApiResponse + * The search api response. + */ + protected function searchApiResponse(QueryInterface $query): SearchApiResponse { + return $this->responseWrapper->setQuery($query); + } + +} diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/Schema/ThunderSchema.php b/modules/thunder_gqls/src/Plugin/GraphQL/Schema/ThunderSchema.php index 1afaa4f5a..aaa2f1340 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/Schema/ThunderSchema.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/Schema/ThunderSchema.php @@ -25,7 +25,7 @@ class ThunderSchema extends ComposableSchema { use ResolverHelperTrait; - public const REQUIRED_EXTENSIONS = [ + public const array REQUIRED_EXTENSIONS = [ 'thunder_pages', 'thunder_media', 'thunder_paragraphs', @@ -36,7 +36,7 @@ class ThunderSchema extends ComposableSchema { * * @var \Drupal\graphql\Plugin\DataProducerPluginManager */ - protected $dataProducerManager; + protected DataProducerPluginManager $dataProducerManager; /** * {@inheritdoc} @@ -113,7 +113,7 @@ protected function getExtensions(): array { public function buildConfigurationForm(array $form, FormStateInterface $form_state): array { $form = parent::buildConfigurationForm($form, $form_state); foreach (Element::children($form['extensions']) as $extension) { - if (in_array($extension, static::REQUIRED_EXTENSIONS)) { + if (in_array($extension, static::REQUIRED_EXTENSIONS, TRUE)) { $form['extensions'][$extension]['#disabled'] = TRUE; $form['extensions'][$extension]['#value'] = TRUE; } diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/SchemaExtension/ThunderSchemaExtensionPluginBase.php b/modules/thunder_gqls/src/Plugin/GraphQL/SchemaExtension/ThunderSchemaExtensionPluginBase.php index d5fe25b9e..075603ba5 100644 --- a/modules/thunder_gqls/src/Plugin/GraphQL/SchemaExtension/ThunderSchemaExtensionPluginBase.php +++ b/modules/thunder_gqls/src/Plugin/GraphQL/SchemaExtension/ThunderSchemaExtensionPluginBase.php @@ -24,14 +24,14 @@ abstract class ThunderSchemaExtensionPluginBase extends SdlSchemaExtensionPlugin * * @var \Drupal\graphql\Plugin\DataProducerPluginManager */ - protected $dataProducerManager; + protected DataProducerPluginManager $dataProducerManager; /** * The entity type manager service. * * @var \Drupal\Core\Entity\EntityTypeManagerInterface */ - protected $entityTypeManager; + protected EntityTypeManagerInterface $entityTypeManager; /** * {@inheritdoc} diff --git a/modules/thunder_gqls/src/Plugin/GraphQL/SchemaExtension/ThunderSearchApiSchemaExtension.php b/modules/thunder_gqls/src/Plugin/GraphQL/SchemaExtension/ThunderSearchApiSchemaExtension.php new file mode 100644 index 000000000..dc9c2fbeb --- /dev/null +++ b/modules/thunder_gqls/src/Plugin/GraphQL/SchemaExtension/ThunderSearchApiSchemaExtension.php @@ -0,0 +1,39 @@ +addFieldResolverIfNotExists('SearchApiResult', 'total', + $this->builder->callback(function (SearchApiResponse $result) { + return $result->total(); + }) + ); + + $this->addFieldResolverIfNotExists('SearchApiResult', 'items', + $this->builder->callback(function (SearchApiResponse $result) { + return $result->items(); + }) + ); + } + +} diff --git a/modules/thunder_gqls/src/Traits/ResolverHelperTrait.php b/modules/thunder_gqls/src/Traits/ResolverHelperTrait.php index d09fbca9e..8a8b94ce7 100644 --- a/modules/thunder_gqls/src/Traits/ResolverHelperTrait.php +++ b/modules/thunder_gqls/src/Traits/ResolverHelperTrait.php @@ -2,8 +2,11 @@ namespace Drupal\thunder_gqls\Traits; +use Drupal\graphql\GraphQL\Resolver\Composite; use Drupal\graphql\GraphQL\Resolver\ResolverInterface; use Drupal\graphql\GraphQL\ResolverBuilder; +use Drupal\graphql\GraphQL\ResolverRegistryInterface; +use Drupal\graphql\Plugin\GraphQL\DataProducer\DataProducerProxy; /** * Helper functions for field resolvers. @@ -15,14 +18,14 @@ trait ResolverHelperTrait { * * @var \Drupal\graphql\GraphQL\ResolverBuilder */ - protected $builder; + protected ResolverBuilder $builder; /** * ResolverRegistryInterface. * * @var \Drupal\graphql\GraphQL\ResolverRegistryInterface */ - protected $registry; + protected ResolverRegistryInterface $registry; /** * Add field resolver to registry, if it does not already exist. @@ -60,7 +63,7 @@ protected function createResolverBuilder(): void { * @return \Drupal\graphql\GraphQL\Resolver\Composite * The field data producer. */ - public function fromEntityReference(string $field, ResolverInterface $entity = NULL, bool $multiValue = TRUE) { + public function fromEntityReference(string $field, ResolverInterface $entity = NULL, bool $multiValue = TRUE): Composite { return $this->builder->compose( $this->builder->produce('entity_reference') ->map('field', $this->builder->fromValue($field)) @@ -85,7 +88,7 @@ public function fromEntityReference(string $field, ResolverInterface $entity = N * @return \Drupal\graphql\Plugin\GraphQL\DataProducer\DataProducerProxy * The field data producer. */ - public function fromEntityReferenceRevisions(string $field, $entity = NULL) { + public function fromEntityReferenceRevisions(string $field, ?ResolverInterface $entity = NULL): DataProducerProxy { return $this->builder->produce('entity_reference_revisions') ->map('field', $this->builder->fromValue($field)) ->map('entity', $entity ?: $this->builder->fromParent()) @@ -117,7 +120,7 @@ public function addSimpleCallbackFields(string $type, array $fields): void { * @return \Drupal\graphql\GraphQL\Resolver\ResolverInterface * The resolved entity. */ - public function fromRoute(ResolverInterface $path) { + public function fromRoute(ResolverInterface $path): ResolverInterface { return $this->builder->compose( $this->builder->produce('route_load') ->map('path', $path), @@ -138,7 +141,7 @@ public function fromRoute(ResolverInterface $path) { * @return string * Returns the mapped bundle name. */ - protected function mapBundleToSchemaName(string $bundleName) { + protected function mapBundleToSchemaName(string $bundleName): string { return str_replace('_', '', ucwords($bundleName, '_')); } diff --git a/modules/thunder_gqls/src/Wrappers/EntityListResponse.php b/modules/thunder_gqls/src/Wrappers/EntityListResponse.php index d2502ac23..96c7b8f65 100644 --- a/modules/thunder_gqls/src/Wrappers/EntityListResponse.php +++ b/modules/thunder_gqls/src/Wrappers/EntityListResponse.php @@ -2,29 +2,51 @@ namespace Drupal\thunder_gqls\Wrappers; +use Drupal\Core\DependencyInjection\ContainerInjectionInterface; use Drupal\Core\Entity\Query\QueryInterface; +use Drupal\graphql\GraphQL\Buffers\EntityBuffer; use GraphQL\Deferred; +use Symfony\Component\DependencyInjection\ContainerInterface; /** * The thunder entity list response class. */ -class EntityListResponse implements EntityListResponseInterface { +class EntityListResponse implements EntityListResponseInterface, ContainerInjectionInterface { /** * The query interface. * * @var \Drupal\Core\Entity\Query\QueryInterface */ - protected $query; + protected QueryInterface $query; /** * EntityListResponse constructor. * + * @param \Drupal\graphql\GraphQL\Buffers\EntityBuffer $buffer + * The buffer parameter. + */ + public function __construct(protected readonly EntityBuffer $buffer) { + } + + /** + * {@inheritDoc} + */ + public static function create(ContainerInterface $container): self { + return new static( + $container->get('graphql.buffer.entity'), + ); + } + + /** + * Set query. + * * @param \Drupal\Core\Entity\Query\QueryInterface $query - * The query interface. + * The query. */ - public function __construct(QueryInterface $query) { + public function setQuery(QueryInterface $query): EntityListResponse { $this->query = $query; + return $this; } /** @@ -36,7 +58,7 @@ public function __construct(QueryInterface $query) { public function total(): int { $query = clone $this->query; $query->range(NULL, NULL)->count(); - return intval($query->execute()); + return (int) $query->execute(); } /** @@ -45,14 +67,13 @@ public function total(): int { * @return array|\GraphQL\Deferred * The entity list. */ - public function items() { + public function items(): array|Deferred { $result = $this->query->execute(); if (empty($result)) { return []; } - $buffer = \Drupal::service('graphql.buffer.entity'); - $callback = $buffer->add($this->query->getEntityTypeId(), array_values($result)); + $callback = $this->buffer->add($this->query->getEntityTypeId(), array_values($result)); return new Deferred(fn() => $callback()); } diff --git a/modules/thunder_gqls/src/Wrappers/EntityListResponseInterface.php b/modules/thunder_gqls/src/Wrappers/EntityListResponseInterface.php index a40b1c3a2..08d72be59 100644 --- a/modules/thunder_gqls/src/Wrappers/EntityListResponseInterface.php +++ b/modules/thunder_gqls/src/Wrappers/EntityListResponseInterface.php @@ -2,6 +2,8 @@ namespace Drupal\thunder_gqls\Wrappers; +use GraphQL\Deferred; + /** * The thunder entity list response class. */ @@ -21,6 +23,6 @@ public function total(): int; * @return array|\GraphQL\Deferred * The entity list. */ - public function items(); + public function items(): array|Deferred; } diff --git a/modules/thunder_gqls/src/Wrappers/SearchApiResponse.php b/modules/thunder_gqls/src/Wrappers/SearchApiResponse.php new file mode 100644 index 000000000..612c56d03 --- /dev/null +++ b/modules/thunder_gqls/src/Wrappers/SearchApiResponse.php @@ -0,0 +1,273 @@ +get('thunder_gqls.buffer.search_api_result'), + $container->get('entity_field.manager'), + ); + } + + /** + * Set query. + * + * @param \Drupal\search_api\Query\QueryInterface $query + * The query. + */ + public function setQuery(QueryInterface $query): SearchApiResponse { + $this->query = $query; + return $this; + } + + /** + * Set Facet mapping. + * + * @param array $facetMapping + * The facet mapping. + */ + public function setFacetMapping(array $facetMapping): SearchApiResponse { + $this->facetMapping = $facetMapping; + return $this; + } + + /** + * Set bundle. + * + * @param string $bundle + * The bundle. + */ + public function setBundle(string $bundle): SearchApiResponse { + $this->bundle = $bundle; + return $this; + } + + /** + * Set facets. + * + * @param array $facets + * The facets. + */ + public function setFacets(array $facets): SearchApiResponse { + $this->facets = $facets; + return $this; + } + + /** + * {@inheritdoc} + * + * @throws \Drupal\search_api\SearchApiException + */ + public function facets(): array { + if (!$this->facets || !$this->facetMapping) { + return []; + } + + if (!$this->result) { + $this->result = $this->query->execute(); + } + + $facets = []; + + $facetData = $this->result->getExtraData('search_api_facets'); + foreach ($facetData as $facetFieldId => $facetResults) { + $facets[] = [ + 'key' => $this->facetMapping[$facetFieldId], + 'values' => $this->processFacetResults($this->facets[$facetFieldId], $facetResults), + ]; + } + + return $facets; + } + + /** + * Get search result items. + * + * @return array|\GraphQL\Deferred + * The search result items. + * + * @throws \Drupal\search_api\SearchApiException + */ + public function items(): array|Deferred { + if (!$this->result) { + $this->result = $this->query->execute(); + } + + $ids = array_map(static function ($item) { + return $item->getId(); + }, $this->result->getResultItems()); + + $ids = array_unique($ids); + + if (empty($ids)) { + return []; + } + + $callback = $this->buffer->add( + $this->query->getIndex()->id(), + array_values($ids) + ); + + return new Deferred(function () use ($callback) { + return $callback(); + }); + } + + /** + * Returns the total results. + * + * @return int + * The total results. + * + * @throws \Drupal\search_api\SearchApiException + */ + public function total(): int { + $query = clone $this->query; + $query->range(0, NULL); + $result = $query->execute(); + + return (int) $result->getResultCount(); + } + + /** + * Handles processing of facet values. + * + * @param \Drupal\facets\Entity\Facet $facet + * The facet to process. + * @param array $facetResults + * The facet results. + * + * @return array + * The processed facet results. + */ + private function processFacetResults( + Facet $facet, + array $facetResults, + ): array { + // First process facet results which contain filter like filter=""9"". + // @see Drupal\facets\Plugin\facets\query_type\SearchApiString#build(). + foreach ($facetResults as $i => $facetResult) { + $facetResult['filter'] = $facetResult['filter'] ?? ''; + + if ($facetResult['filter'][0] === '"') { + $facetResult['filter'] = substr($facetResult['filter'], 1); + } + if ($facetResult['filter'][strlen($facetResult['filter']) - 1] === '"') { + $facetResult['filter'] = substr($facetResult['filter'], 0, -1); + } + + $facetResults[$i] = $facetResult; + } + + return $this->processFacetResultsFromFieldConfig($facet, $facetResults); + } + + /** + * Populates label for facet values from allowed options field config. + * + * @param \Drupal\facets\Entity\Facet $facet + * The facet. + * @param array $facetResults + * The facet results. + * + * @return array + * The processed facet results. + */ + private function processFacetResultsFromFieldConfig( + Facet $facet, + array $facetResults, + ): array { + if (!$this->bundle) { + return $facetResults; + } + + $fieldName = $facet->getFieldIdentifier(); + $fieldConfig = $this->entityFieldManager->getFieldDefinitions('node', $this->bundle); + + if (isset($fieldConfig[$fieldName])) { + $allowedValues = options_allowed_values($fieldConfig[$fieldName]->getFieldStorageDefinition()); + + // Use order of allowedValues. + foreach ($facetResults as $key => $facetResult) { + $facetResults[$key]['label'] = $allowedValues[$facetResult['filter']] ?? $facetResult['filter']; + $facetResults[$key]['value'] = $facetResult['filter']; + } + + $allowedValueKeys = array_keys($allowedValues); + usort($facetResults, function ($a, $b) use ($allowedValueKeys) { + $indexA = array_search($a['filter'], $allowedValueKeys, TRUE); + $indexB = array_search($b['filter'], $allowedValueKeys, TRUE); + + return $indexA < $indexB ? -1 : 1; + }); + } + + return $facetResults; + } + +} diff --git a/modules/thunder_gqls/src/Wrappers/SearchApiResponseInterface.php b/modules/thunder_gqls/src/Wrappers/SearchApiResponseInterface.php new file mode 100644 index 000000000..82d2158aa --- /dev/null +++ b/modules/thunder_gqls/src/Wrappers/SearchApiResponseInterface.php @@ -0,0 +1,18 @@ +logWithRole('administrator'); + + $this->drupalGet('admin/config/search/search-api/index/content'); + $this->submitForm([], 'Index now'); + $this->assertSession()->statusCodeEquals(200); + $this->checkForMetaRefresh(); + + $options = [ + 'index' => 'content', + 'search' => 'the', + 'limit' => 10, + 'offset' => 0, + ]; + + $result = $this->executeDataProducer('thunder_search_api', $options); + $this->assertEquals(3, $result->total()); + + $items = $result->items(); + $items->runQueue(); + $this->assertEquals('Burda Launches Open-Source CMS Thunder', $items->result[0]->getTitle()); + + // Change sort order. + $options['sortBy'] = [ + [ + 'field' => 'search_api_relevance', + 'direction' => QueryInterface::SORT_ASC, + ], + ]; + + $this->container->get('kernel')->rebuildContainer(); + $result = $this->executeDataProducer('thunder_search_api', $options); + + $items = $result->items(); + $items->runQueue(); + $this->assertEquals('Legal notice', $items->result[0]->getTitle()); + + // Get articles only. + $options['conditions'] = [ + [ + 'field' => 'type', + 'value' => 'article', + 'operator' => '=', + ], + ]; + + $this->container->get('kernel')->rebuildContainer(); + $result = $this->executeDataProducer('thunder_search_api', $options); + + $items = $result->items(); + $items->runQueue(); + $this->assertEquals('Come to DrupalCon New Orleans', $items->result[0]->getTitle()); + + } + +} diff --git a/modules/thunder_gqls/tests/src/Functional/RedirectSchemaTest.php b/modules/thunder_gqls/tests/src/Functional/RedirectSchemaTest.php index d26c16a5a..d7d9e1d1a 100644 --- a/modules/thunder_gqls/tests/src/Functional/RedirectSchemaTest.php +++ b/modules/thunder_gqls/tests/src/Functional/RedirectSchemaTest.php @@ -3,6 +3,7 @@ namespace Drupal\Tests\thunder_gqls\Functional; use Drupal\Component\Serialization\Json; +use Drupal\node\NodeInterface; /** * Test the redirect endpoint. @@ -16,7 +17,7 @@ class RedirectSchemaTest extends ThunderGqlsTestBase { * * @var \Drupal\node\NodeInterface */ - protected $unpublishedEntity; + protected NodeInterface $unpublishedEntity; /** * {@inheritdoc} diff --git a/modules/thunder_gqls/tests/src/Kernel/DataProducer/EntitiesWithTermTest.php b/modules/thunder_gqls/tests/src/Kernel/DataProducer/EntitiesWithTermTest.php index a065cf9b4..d1ddd8161 100644 --- a/modules/thunder_gqls/tests/src/Kernel/DataProducer/EntitiesWithTermTest.php +++ b/modules/thunder_gqls/tests/src/Kernel/DataProducer/EntitiesWithTermTest.php @@ -8,6 +8,7 @@ use Drupal\node\Entity\NodeType; use Drupal\taxonomy\Entity\Term; use Drupal\taxonomy\Entity\Vocabulary; +use Drupal\taxonomy\TermInterface; use Drupal\Tests\graphql\Kernel\GraphQLTestBase; /** @@ -22,12 +23,12 @@ class EntitiesWithTermTest extends GraphQLTestBase { * * @var \Drupal\taxonomy\TermInterface */ - protected $parent; + protected TermInterface $parent; /** * The taxonomy term reference field name. */ - protected const TAXONOMY_FIELD_NAME = 'taxonomy_field'; + protected const string TAXONOMY_FIELD_NAME = 'taxonomy_field'; /** * {@inheritdoc} diff --git a/modules/thunder_gqls/tests/src/Kernel/DataProducer/ThunderMetatagsTest.php b/modules/thunder_gqls/tests/src/Kernel/DataProducer/ThunderMetatagsTest.php index a261ac857..4885639bc 100644 --- a/modules/thunder_gqls/tests/src/Kernel/DataProducer/ThunderMetatagsTest.php +++ b/modules/thunder_gqls/tests/src/Kernel/DataProducer/ThunderMetatagsTest.php @@ -3,6 +3,7 @@ namespace Drupal\Tests\thunder_gqls\Kernel\DataProducer; use Drupal\node\Entity\Node; +use Drupal\node\NodeInterface; use Drupal\Tests\graphql\Kernel\GraphQLTestBase; use Drupal\Tests\TestFileCreationTrait; @@ -20,7 +21,7 @@ class ThunderMetatagsTest extends GraphQLTestBase { * * @var \Drupal\node\NodeInterface */ - protected $node; + protected NodeInterface $node; /** * {@inheritdoc} diff --git a/modules/thunder_gqls/thunder_gqls.services.yml b/modules/thunder_gqls/thunder_gqls.services.yml new file mode 100644 index 000000000..863299712 --- /dev/null +++ b/modules/thunder_gqls/thunder_gqls.services.yml @@ -0,0 +1,12 @@ +services: + _defaults: + autowire: true + thunder_gqls.buffer.search_api_result: + class: Drupal\thunder_gqls\GraphQL\Buffers\SearchApiResultBuffer + Drupal\thunder_gqls\GraphQL\Buffers\SearchApiResultBuffer: '@thunder_gqls.buffer.search_api_result' + thunder_gqls.search_api_response_wrapper: + class: Drupal\thunder_gqls\Wrappers\SearchApiResponse + thunder_gqls.entity_list_response_wrapper: + autowire: false + class: Drupal\thunder_gqls\Wrappers\EntityListResponse + arguments: [ '@graphql.buffer.entity' ] diff --git a/modules/thunder_media/src/Form/ConfigurationForm.php b/modules/thunder_media/src/Form/ConfigurationForm.php index 00c9ccd95..563d1fcc1 100644 --- a/modules/thunder_media/src/Form/ConfigurationForm.php +++ b/modules/thunder_media/src/Form/ConfigurationForm.php @@ -4,20 +4,13 @@ use Drupal\Core\Form\ConfigFormBase; use Drupal\Core\Form\FormStateInterface; +use Drupal\Core\Form\RedundantEditableConfigNamesTrait; /** * Configuration form for Thunder media settings. */ class ConfigurationForm extends ConfigFormBase { - - /** - * {@inheritdoc} - */ - protected function getEditableConfigNames(): array { - return [ - 'thunder_media.settings', - ]; - } + use RedundantEditableConfigNamesTrait; /** * {@inheritdoc} @@ -30,27 +23,14 @@ public function getFormId(): string { * {@inheritdoc} */ public function buildForm(array $form, FormStateInterface $form_state): array { - $config = $this->config('thunder_media.settings'); - $form['enable_filefield_remove_button'] = [ '#type' => 'checkbox', '#title' => $this->t('Enable file field remove button'), '#description' => $this->t('Enable this checkbox to enable remove buttons for file fields on inline entity forms.'), - '#default_value' => $config->get('enable_filefield_remove_button'), + '#config_target' => 'thunder_media.settings:enable_filefield_remove_button', ]; return parent::buildForm($form, $form_state); } - /** - * {@inheritdoc} - */ - public function submitForm(array &$form, FormStateInterface $form_state): void { - parent::submitForm($form, $form_state); - - $this->config('thunder_media.settings') - ->set('enable_filefield_remove_button', $form_state->getValue('enable_filefield_remove_button')) - ->save(); - } - } diff --git a/modules/thunder_media/src/Plugin/ImageEffect/AutoAspectEffect.php b/modules/thunder_media/src/Plugin/ImageEffect/AutoAspectEffect.php index 359537a65..cf84560f4 100644 --- a/modules/thunder_media/src/Plugin/ImageEffect/AutoAspectEffect.php +++ b/modules/thunder_media/src/Plugin/ImageEffect/AutoAspectEffect.php @@ -5,18 +5,19 @@ use Drupal\Core\Entity\EntityTypeManagerInterface; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Image\ImageInterface; +use Drupal\Core\StringTranslation\TranslatableMarkup; +use Drupal\image\Attribute\ImageEffect; use Drupal\image\ConfigurableImageEffectBase; use Symfony\Component\DependencyInjection\ContainerInterface; /** * Resizes an image resource. - * - * @ImageEffect( - * id = "thunder_media_auto_aspect", - * label = @Translation("Auto Aspect"), - * description = @Translation("Use different effects depending on whether the image is landscape of portrait shaped. This re-uses other preset definitions, and just chooses between them based on the rule.") - * ) */ +#[ImageEffect( + id: "thunder_media_auto_aspect", + label: new TranslatableMarkup("Auto Aspect"), + description: new TranslatableMarkup("Use different effects depending on whether the image is landscape of portrait shaped. This re-uses other preset definitions, and just chooses between them based on the rule."), +)] class AutoAspectEffect extends ConfigurableImageEffectBase { /** @@ -24,7 +25,7 @@ class AutoAspectEffect extends ConfigurableImageEffectBase { * * @var \Drupal\Core\Entity\EntityTypeManagerInterface */ - protected $entityTypeManager; + protected EntityTypeManagerInterface $entityTypeManager; /** * {@inheritdoc} diff --git a/modules/thunder_taxonomy/src/ThunderTaxonomyPermissions.php b/modules/thunder_taxonomy/src/ThunderTaxonomyPermissions.php index 818644a71..2b640c000 100644 --- a/modules/thunder_taxonomy/src/ThunderTaxonomyPermissions.php +++ b/modules/thunder_taxonomy/src/ThunderTaxonomyPermissions.php @@ -16,21 +16,13 @@ class ThunderTaxonomyPermissions implements ContainerInjectionInterface { use StringTranslationTrait; - /** - * The entity manager. - * - * @var \Drupal\Core\Entity\EntityTypeManagerInterface - */ - protected $entityTypeManager; - /** * Constructs a TaxonomyPermissions instance. * * @param \Drupal\Core\Entity\EntityTypeManagerInterface $entityTypeManager * The entity type manager. */ - public function __construct(EntityTypeManagerInterface $entityTypeManager) { - $this->entityTypeManager = $entityTypeManager; + public function __construct(protected readonly EntityTypeManagerInterface $entityTypeManager) { } /** diff --git a/modules/thunder_workflow/src/Plugin/Field/FieldWidget/ModerationStateWidget.php b/modules/thunder_workflow/src/Plugin/Field/FieldWidget/ModerationStateWidget.php index 24d0ad65d..247cd2f34 100644 --- a/modules/thunder_workflow/src/Plugin/Field/FieldWidget/ModerationStateWidget.php +++ b/modules/thunder_workflow/src/Plugin/Field/FieldWidget/ModerationStateWidget.php @@ -3,8 +3,10 @@ namespace Drupal\thunder_workflow\Plugin\Field\FieldWidget; use Drupal\content_moderation\Plugin\Field\FieldWidget\ModerationStateWidget as CoreModerationStateWidget; +use Drupal\Core\Field\Attribute\FieldWidget; use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Form\FormStateInterface; +use Drupal\Core\StringTranslation\TranslatableMarkup; /** * Plugin implementation of the 'thunder_moderation_state_default' widget. @@ -12,15 +14,12 @@ * Thunder provides its own moderation_state widget that only shows a list of * possible states to switch in. To display the current state is not part of * this widget. Thunder shows that in ThunderNodeFormHelper. - * - * @FieldWidget( - * id = "thunder_moderation_state_default", - * label = @Translation("Moderation state (Thunder)"), - * field_types = { - * "string" - * } - * ) */ +#[FieldWidget( + id: 'thunder_moderation_state_default', + label: new TranslatableMarkup('Moderation state (Thunder)'), + field_types: ['string'], +)] class ModerationStateWidget extends CoreModerationStateWidget { /** diff --git a/modules/thunder_workflow/src/ThunderWorkflowFormHelper.php b/modules/thunder_workflow/src/ThunderWorkflowFormHelper.php index 091662a10..dbf3fe8f2 100644 --- a/modules/thunder_workflow/src/ThunderWorkflowFormHelper.php +++ b/modules/thunder_workflow/src/ThunderWorkflowFormHelper.php @@ -24,20 +24,6 @@ class ThunderWorkflowFormHelper implements ContainerInjectionInterface { use StringTranslationTrait; - /** - * The current user. - * - * @var \Drupal\Core\Session\AccountInterface - */ - protected AccountInterface $currentUser; - - /** - * The messenger service. - * - * @var \Drupal\Core\Messenger\MessengerInterface - */ - protected MessengerInterface $messenger; - /** * The request object. * @@ -45,46 +31,18 @@ class ThunderWorkflowFormHelper implements ContainerInjectionInterface { */ protected Request $request; - /** - * The moderation information service. - * - * @var \Drupal\content_moderation\ModerationInformationInterface - */ - protected ModerationInformationInterface $moderationInfo; - - /** - * The entity type manager. - * - * @var \Drupal\Core\Entity\EntityTypeManagerInterface - */ - protected EntityTypeManagerInterface $entityTypeManager; - - /** - * The theme manager. - * - * @var \Drupal\Core\Theme\ThemeManagerInterface - */ - protected ThemeManagerInterface $themeManager; - - /** - * The state transition validation service. - * - * @var \Drupal\content_moderation\StateTransitionValidationInterface - */ - protected StateTransitionValidationInterface $stateTransitionValidation; - /** * Constructs a NodeForm object. * - * @param \Drupal\Core\Session\AccountInterface $current_user + * @param \Drupal\Core\Session\AccountInterface $currentUser * The current user. * @param \Drupal\Core\Messenger\MessengerInterface $messenger * The messenger service. * @param \Symfony\Component\HttpFoundation\RequestStack $requestStack * The request stack service. - * @param \Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager + * @param \Drupal\Core\Entity\EntityTypeManagerInterface $entityTypeManager * The entity type manager. - * @param \Drupal\Core\Theme\ThemeManagerInterface $theme_manager + * @param \Drupal\Core\Theme\ThemeManagerInterface $themeManager * The theme manager. * @param \Drupal\content_moderation\ModerationInformationInterface $moderationInfo * The moderation info service. The optionality is important @@ -92,14 +50,8 @@ class ThunderWorkflowFormHelper implements ContainerInjectionInterface { * @param \Drupal\content_moderation\StateTransitionValidationInterface $stateTransitionValidation * The state transition validation service. */ - final public function __construct(AccountInterface $current_user, MessengerInterface $messenger, RequestStack $requestStack, EntityTypeManagerInterface $entity_type_manager, ThemeManagerInterface $theme_manager, ModerationInformationInterface $moderationInfo, StateTransitionValidationInterface $stateTransitionValidation) { - $this->currentUser = $current_user; - $this->messenger = $messenger; + final public function __construct(protected readonly AccountInterface $currentUser, protected readonly MessengerInterface $messenger, RequestStack $requestStack, protected readonly EntityTypeManagerInterface $entityTypeManager, protected readonly ThemeManagerInterface $themeManager, protected readonly ModerationInformationInterface $moderationInfo, protected readonly StateTransitionValidationInterface $stateTransitionValidation) { $this->request = $requestStack->getCurrentRequest(); - $this->entityTypeManager = $entity_type_manager; - $this->themeManager = $theme_manager; - $this->moderationInfo = $moderationInfo; - $this->stateTransitionValidation = $stateTransitionValidation; } /** diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index 3fcf0a4db..652178514 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -1,55 +1,5 @@ parameters: ignoreErrors: - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_article/src/Form/NodeRevisionRevertDefaultForm.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_article/src/Plugin/Derivative/DynamicLocalTasks.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/EntityLinks.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/FocalPoint.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MenuLinksActiveTrail.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/MetaTags.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntityListProducerBase.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderEntitySubRequestBase.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderImage.php - - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_gqls/src/Plugin/GraphQL/DataProducer/ThunderRedirect.php - - message: "#^Access to an undefined property Drupal\\\\Core\\\\Entity\\\\ContentEntityInterface\\:\\:\\$field_teaser_media\\.$#" count: 1 @@ -60,21 +10,11 @@ parameters: count: 1 path: modules/thunder_gqls/src/Plugin/GraphQL/SchemaExtension/ThunderPagesSchemaExtension.php - - - message: "#^\\\\Drupal calls should be avoided in classes, use dependency injection instead$#" - count: 1 - path: modules/thunder_gqls/src/Wrappers/EntityListResponse.php - - message: "#^Access to an undefined property Drupal\\\\Tests\\\\thunder_gqls\\\\Kernel\\\\DataProducer\\\\EntityLinksTest\\:\\:\\$node\\.$#" count: 4 path: modules/thunder_gqls/tests/src/Kernel/DataProducer/EntityLinksTest.php - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: modules/thunder_taxonomy/src/ThunderTaxonomyPermissions.php - - message: "#^Access to an undefined property Drupal\\\\Core\\\\Entity\\\\EntityInterface\\:\\:\\$status\\.$#" count: 1 @@ -175,11 +115,6 @@ parameters: count: 6 path: tests/src/FunctionalJavascript/Integration/ParagraphsPasteTest.php - - - message: "#^Call to an undefined method Drupal\\\\Tests\\\\WebAssert\\:\\:waitForElement\\(\\)\\.$#" - count: 1 - path: tests/src/FunctionalJavascript/Integration/ResponsivePreviewTest.php - - message: "#^Call to an undefined method Drupal\\\\Tests\\\\WebAssert\\:\\:waitForElementVisible\\(\\)\\.$#" count: 5 @@ -225,11 +160,6 @@ parameters: count: 1 path: tests/src/TestSuites/ThunderTestSuite.php - - - message: "#^Unsafe usage of new static\\(\\)\\.$#" - count: 1 - path: tests/src/TestSuites/ThunderTestSuite.php - - message: "#^Call to method id\\(\\) on an unknown class Drupal\\\\entity_browser\\\\Entity\\\\EntityBrowser\\.$#" count: 1 diff --git a/phpstan.neon b/phpstan.neon index 654ea7304..a604bc45c 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -1,8 +1,11 @@ parameters: customRulesetUsed: true - checkGenericClassInNonGenericObjectType: false - checkMissingIterableValueType: false reportUnmatchedIgnoredErrors: true level: 6 + ignoreErrors: + # new static() is a best practice in Drupal, so we cannot fix that. + - "#^Unsafe usage of new static#" + - identifier: missingType.generics + - identifier: missingType.iterableValue includes: - ./phpstan-baseline.neon diff --git a/src/Breadcrumb/ThunderNodeEditBreadcrumbBuilder.php b/src/Breadcrumb/ThunderNodeEditBreadcrumbBuilder.php index 330f11c0e..cbd5d38b2 100644 --- a/src/Breadcrumb/ThunderNodeEditBreadcrumbBuilder.php +++ b/src/Breadcrumb/ThunderNodeEditBreadcrumbBuilder.php @@ -36,7 +36,7 @@ public function build(RouteMatchInterface $route_match): Breadcrumb { $links[] = Link::createFromRoute($this->t('Home'), ''); $links[] = Link::createFromRoute($this->t('Overview'), 'system.admin_content'); - if ($route_match->getRouteName() == 'node.add') { + if ($route_match->getRouteName() === 'node.add') { $links[] = Link::createFromRoute($this->t('Add content'), 'node.add_page'); } diff --git a/src/Installer/Form/ModuleConfigureForm.php b/src/Installer/Form/ModuleConfigureForm.php index 9de6125ac..623e6d58b 100644 --- a/src/Installer/Form/ModuleConfigureForm.php +++ b/src/Installer/Form/ModuleConfigureForm.php @@ -30,42 +30,42 @@ class ModuleConfigureForm extends FormBase { * * @var \Drupal\Core\Extension\ModuleExtensionList */ - protected $moduleExtensionList; + protected ModuleExtensionList $moduleExtensionList; /** * The module installer. * * @var \Drupal\Core\Extension\ModuleInstallerInterface */ - protected $moduleInstaller; + protected ModuleInstallerInterface $moduleInstaller; /** * The access manager service. * * @var \Drupal\Core\Access\AccessManagerInterface */ - protected $accessManager; + protected AccessManagerInterface $accessManager; /** * The module handler service. * * @var \Drupal\Core\Extension\ModuleHandlerInterface */ - protected $moduleHandler; + protected ModuleHandlerInterface $moduleHandler; /** * The current user. * * @var \Drupal\Core\Session\AccountProxyInterface */ - protected $currentUser; + protected AccountProxyInterface $currentUser; /** * The permission handler service. * * @var \Drupal\user\PermissionHandlerInterface */ - protected $permissionHandler; + protected PermissionHandlerInterface $permissionHandler; /** * {@inheritdoc} diff --git a/src/Plugin/Block/ThunderPoweredByBlock.php b/src/Plugin/Block/ThunderPoweredByBlock.php index 34fefdd3d..da26247d3 100644 --- a/src/Plugin/Block/ThunderPoweredByBlock.php +++ b/src/Plugin/Block/ThunderPoweredByBlock.php @@ -2,16 +2,18 @@ namespace Drupal\thunder\Plugin\Block; +use Drupal\Core\Block\Attribute\Block; use Drupal\Core\Block\BlockBase; +use Drupal\Core\StringTranslation\TranslatableMarkup; /** * Provides a 'Powered by Thunder' block. - * - * @Block( - * id = "thunder_powered_by_block", - * admin_label = @Translation("Powered by Thunder") - * ) */ +#[Block( + id: "thunder_powered_by_block", + admin_label: new TranslatableMarkup("Powered by Thunder"), + category: new TranslatableMarkup("Footer") +)] class ThunderPoweredByBlock extends BlockBase { /** diff --git a/tests/modules/thunder_test_mock_request/src/MockHttpClientMiddleware.php b/tests/modules/thunder_test_mock_request/src/MockHttpClientMiddleware.php index 64707a0e0..babed8040 100644 --- a/tests/modules/thunder_test_mock_request/src/MockHttpClientMiddleware.php +++ b/tests/modules/thunder_test_mock_request/src/MockHttpClientMiddleware.php @@ -6,6 +6,7 @@ use GuzzleHttp\Promise\Create; use GuzzleHttp\Psr7\Response; use Psr\Http\Message\RequestInterface; +use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\RequestStack; /** @@ -18,14 +19,7 @@ class MockHttpClientMiddleware { * * @var \Symfony\Component\HttpFoundation\Request */ - protected $request; - - /** - * The state service. - * - * @var \Drupal\Core\State\StateInterface - */ - protected $state; + protected Request $request; /** * MockHttpClientMiddleware constructor. @@ -35,9 +29,8 @@ class MockHttpClientMiddleware { * @param \Drupal\Core\State\StateInterface $state * The state service. */ - public function __construct(RequestStack $requestStack, StateInterface $state) { + public function __construct(RequestStack $requestStack, protected readonly StateInterface $state) { $this->request = $requestStack->getCurrentRequest(); - $this->state = $state; } /** diff --git a/tests/src/Functional/BreadcrumbTest.php b/tests/src/Functional/BreadcrumbTest.php index 77c981a3f..728ef0d8d 100644 --- a/tests/src/Functional/BreadcrumbTest.php +++ b/tests/src/Functional/BreadcrumbTest.php @@ -11,8 +11,6 @@ * @group Thunder */ class BreadcrumbTest extends ThunderTestBase { - - use AssertBreadcrumbTrait; /** diff --git a/tests/src/Functional/InstalledConfigurationTest.php b/tests/src/Functional/InstalledConfigurationTest.php index 1fbeb35e8..bf03562b9 100644 --- a/tests/src/Functional/InstalledConfigurationTest.php +++ b/tests/src/Functional/InstalledConfigurationTest.php @@ -46,7 +46,7 @@ class InstalledConfigurationTest extends ThunderTestBase { * * @var array */ - protected static $ignoreCoreConfigs = [ + protected static array $ignoreCoreConfigs = [ 'checklistapi.progress.update_helper_checklist', 'system.site', 'core.extension', @@ -81,7 +81,6 @@ class InstalledConfigurationTest extends ThunderTestBase { 'core.entity_view_mode.search_api_task.token', // Configs are missing the 'description' key. - 'core.entity_view_mode.media.slick', 'core.entity_view_mode.node.diff', 'core.entity_view_mode.paragraph.preview', @@ -105,7 +104,7 @@ class InstalledConfigurationTest extends ThunderTestBase { * * @var array */ - protected static $ignoreConfigKeys = [ + protected static array $ignoreConfigKeys = [ // It's not exported in Yaml, so that new key is generated. 'scheduler.settings' => [ 'lightweight_cron_access_key' => TRUE, @@ -298,7 +297,7 @@ class InstalledConfigurationTest extends ThunderTestBase { * * @var string */ - public const CONFIG_PATH_SEPARATOR = '::'; + public const string CONFIG_PATH_SEPARATOR = '::'; /** * Ignore configuration list values. Path to key is separated by '::'. @@ -315,7 +314,7 @@ class InstalledConfigurationTest extends ThunderTestBase { * * @todo use this functionality for more strict "dependencies" checking. */ - protected static $ignoreConfigListValues = [ + protected static array $ignoreConfigListValues = [ 'user.role.editor' => [ 'permissions' => [ 'access tour', @@ -350,7 +349,7 @@ class InstalledConfigurationTest extends ThunderTestBase { * * @var array */ - protected static $ignoreConfigs = []; + protected static array $ignoreConfigs = []; /** * Set default theme for test. diff --git a/tests/src/Functional/Installer/ThunderInstallerGermanTest.php b/tests/src/Functional/Installer/ThunderInstallerGermanTest.php index 2699443f3..e18adb7c8 100644 --- a/tests/src/Functional/Installer/ThunderInstallerGermanTest.php +++ b/tests/src/Functional/Installer/ThunderInstallerGermanTest.php @@ -12,7 +12,7 @@ class ThunderInstallerGermanTest extends ThunderInstallerTest { /** * {@inheritdoc} */ - protected $knownWarnings = 0; + protected int $knownWarnings = 0; /** * {@inheritdoc} diff --git a/tests/src/Functional/Installer/ThunderInstallerTest.php b/tests/src/Functional/Installer/ThunderInstallerTest.php index ac86df95e..cbb34bf1d 100644 --- a/tests/src/Functional/Installer/ThunderInstallerTest.php +++ b/tests/src/Functional/Installer/ThunderInstallerTest.php @@ -17,7 +17,7 @@ class ThunderInstallerTest extends InstallerTestBase { * * @var int */ - protected $knownWarnings = 0; + protected int $knownWarnings = 0; /** * {@inheritdoc} diff --git a/tests/src/Functional/Integration/ContentTranslationTest.php b/tests/src/Functional/Integration/ContentTranslationTest.php index 27bb3982c..ac81f6688 100644 --- a/tests/src/Functional/Integration/ContentTranslationTest.php +++ b/tests/src/Functional/Integration/ContentTranslationTest.php @@ -27,7 +27,7 @@ class ContentTranslationTest extends ThunderTestBase { * * @var \Drupal\language\ConfigurableLanguageInterface[] */ - protected $languages = []; + protected array|ConfigurableLanguage $languages = []; /** * {@inheritdoc} diff --git a/tests/src/Functional/ModuleUninstallTest.php b/tests/src/Functional/ModuleUninstallTest.php index 0f47cc9b4..a8bb02b29 100644 --- a/tests/src/Functional/ModuleUninstallTest.php +++ b/tests/src/Functional/ModuleUninstallTest.php @@ -16,11 +16,10 @@ class ModuleUninstallTest extends ThunderTestBase { * * @var string[][] */ - protected static $moduleLists = [ + protected static array $moduleLists = [ ['diff'], ['content_lock'], ['access_unpublished'], - ['responsive_preview'], ['length_indicator'], ['redirect'], ['simple_sitemap'], diff --git a/tests/src/FunctionalJavascript/ChannelsTagsTest.php b/tests/src/FunctionalJavascript/ChannelsTagsTest.php index fa1ed22f4..218a89966 100644 --- a/tests/src/FunctionalJavascript/ChannelsTagsTest.php +++ b/tests/src/FunctionalJavascript/ChannelsTagsTest.php @@ -19,7 +19,7 @@ class ChannelsTagsTest extends ThunderJavascriptTestBase { * * @var string */ - protected static $defaultUserRole = 'administrator'; + protected static string $defaultUserRole = 'administrator'; /** * Test channel creation, tagging of articles and channel page with articles. diff --git a/tests/src/FunctionalJavascript/Integration/DiffTest.php b/tests/src/FunctionalJavascript/Integration/DiffTest.php index 224ca1301..5fb1d8b9c 100644 --- a/tests/src/FunctionalJavascript/Integration/DiffTest.php +++ b/tests/src/FunctionalJavascript/Integration/DiffTest.php @@ -19,14 +19,14 @@ class DiffTest extends ThunderJavascriptTestBase { * * @var int */ - protected static $previousTextColumn = 3; + protected static int $previousTextColumn = 3; /** * Column in diff table used for new text. * * @var int */ - protected static $newTextColumn = 6; + protected static int $newTextColumn = 6; /** * Validate diff entry for one field. diff --git a/tests/src/FunctionalJavascript/Integration/FocalPointTest.php b/tests/src/FunctionalJavascript/Integration/FocalPointTest.php new file mode 100644 index 000000000..cfa49561d --- /dev/null +++ b/tests/src/FunctionalJavascript/Integration/FocalPointTest.php @@ -0,0 +1,25 @@ +loadNodeByUuid('0bd5c257-2231-450f-b4c2-ab156af7b78d'); + $this->drupalGet($node->toUrl('edit-form')); + $this->clickDrupalSelector('edit-field-teaser-media-selection-0-edit'); + $this->clickDrupalSelector('edit-field-image-0-preview-preview-link'); + + $this->assertSession()->elementExists('css', '#focal-point-derivatives .focal-point-derivative-preview-image'); + $this->assertSession()->elementExists('css', '.focal-point-original-image > #focal-point-preview-image'); + } + +} diff --git a/tests/src/FunctionalJavascript/Integration/ParagraphSplitTest.php b/tests/src/FunctionalJavascript/Integration/ParagraphSplitTest.php index d69efb405..0eb7c0ec9 100644 --- a/tests/src/FunctionalJavascript/Integration/ParagraphSplitTest.php +++ b/tests/src/FunctionalJavascript/Integration/ParagraphSplitTest.php @@ -21,7 +21,7 @@ class ParagraphSplitTest extends ThunderJavascriptTestBase { * * @var string */ - protected static $paragraphsField = 'field_paragraphs'; + protected static string $paragraphsField = 'field_paragraphs'; /** * Selector template for CKEditor instances. @@ -31,7 +31,7 @@ class ParagraphSplitTest extends ThunderJavascriptTestBase { * * @var string */ - protected static $selectorTemplate = "textarea[name='%s[%d][subform][field_text][0][value]']"; + protected static string $selectorTemplate = "textarea[name='%s[%d][subform][field_text][0][value]']"; /** * Test split of paragraph before a selection. diff --git a/tests/src/FunctionalJavascript/Integration/ParagraphsPasteTest.php b/tests/src/FunctionalJavascript/Integration/ParagraphsPasteTest.php index ad5350eeb..4c782f3d8 100644 --- a/tests/src/FunctionalJavascript/Integration/ParagraphsPasteTest.php +++ b/tests/src/FunctionalJavascript/Integration/ParagraphsPasteTest.php @@ -40,7 +40,7 @@ class ParagraphsPasteTest extends ThunderJavascriptTestBase { * * @var string */ - protected static $paragraphsField = 'field_paragraphs'; + protected static string $paragraphsField = 'field_paragraphs'; /** * Test paste functionality. diff --git a/tests/src/FunctionalJavascript/Integration/ResponsivePreviewTest.php b/tests/src/FunctionalJavascript/Integration/ResponsivePreviewTest.php deleted file mode 100644 index dfc7e22b9..000000000 --- a/tests/src/FunctionalJavascript/Integration/ResponsivePreviewTest.php +++ /dev/null @@ -1,104 +0,0 @@ -assertSession(); - - /** @var \Behat\Mink\Session $session */ - $session = $this->getSession(); - - // Check channel page. - $this->drupalGet('news'); - - // The selection of device should create overlay with iframe to news page. - $this->selectDevice('(//*[@id="responsive-preview-toolbar-tab"]//button[@data-responsive-preview-name])[1]'); - $assert_session->elementNotExists('xpath', '//*[@id="responsive-preview-orientation" and contains(@class, "rotated")]'); - $assert_session->elementExists('xpath', '//*[@id="responsive-preview-frame"]'); - $this->waitForIframeContent(); - $this->assertTrue($session->evaluateScript("document.getElementById('responsive-preview-frame').contentWindow.location.href.endsWith('news')")); - - // Clicking of rotate should rotate iframe sizes. - $current_width = $session->evaluateScript("document.getElementById('responsive-preview-frame').clientWidth"); - $current_height = $session->evaluateScript("document.getElementById('responsive-preview-frame').clientHeight"); - $this->changeDeviceRotation(); - $this->waitForIframeContent(); - $assert_session->elementExists('xpath', '//*[@id="responsive-preview-orientation" and contains(@class, "rotated")]'); - $this->assertEquals($current_height, $session->evaluateScript("document.getElementById('responsive-preview-frame').clientWidth")); - $this->assertEquals($current_width, $session->evaluateScript("document.getElementById('responsive-preview-frame').clientHeight")); - - // @todo Device switcher is not accessible from overlay when using gin secondary toolbar. - // Switching of device should keep rotation. - // Clicking on preview close, should remove overlay. - $this->getSession() - ->getPage() - ->find('xpath', '//*[@id="responsive-preview-close"]') - ->click(); - $this->getSession() - ->wait(5000, "document.getElementById('responsive-preview-frame') === null"); - $assert_session->elementNotExists('xpath', '//*[@id="responsive-preview"]'); - - $node = $this->loadNodeByUuid('bbb1ee17-15f8-46bd-9df5-21c58040d741'); - $this->drupalGet($node->toUrl('edit-form')); - - // Using preview on entity edit should use preview page. - $this->selectDevice('(//*[@id="responsive-preview-toolbar-tab"]//button[@data-responsive-preview-name])[1]'); - $this->waitForIframeContent(); - $this->assertNotEquals(-1, $session->evaluateScript("document.getElementById('responsive-preview-frame').contentWindow.location.href.indexOf('/node/preview/')")); - $this->changeDeviceRotation(); - } - - /** - * Change device rotation for device preview. - */ - protected function changeDeviceRotation(): void { - $this->getSession() - ->getPage() - ->find('xpath', '//*[@id="responsive-preview-orientation"]') - ->click(); - $this->assertWaitOnAjaxRequest(); - } - - /** - * Wait for iframe content loaded. - */ - protected function waitForIframeContent(): void { - $this->getSession()->evaluateScript("document.getElementById('responsive-preview-frame').setAttribute('name', 'responsive-preview-frame-testing')"); - $this->getSession()->switchToIFrame('responsive-preview-frame-testing'); - $this->assertSession()->waitForElement('css', 'h1.page-title'); - $this->getSession()->switchToIFrame(); - } - - /** - * Select device for device preview. - * - * NOTE: Index starts from 1. - * - * @param string $xpath_device_button - * The xpath of the device in drop-down list. - */ - protected function selectDevice(string $xpath_device_button): void { - $page = $this->getSession()->getPage(); - - $page->find('xpath', '//*[@id="responsive-preview-toolbar-tab"]/button') - ->click(); - $this->assertWaitOnAjaxRequest(); - - $page->find('xpath', $xpath_device_button)->click(); - $this->assertWaitOnAjaxRequest(); - } - -} diff --git a/tests/src/FunctionalJavascript/MediaGalleryModifyTest.php b/tests/src/FunctionalJavascript/MediaGalleryModifyTest.php index 35b2bd615..7e5a4c269 100644 --- a/tests/src/FunctionalJavascript/MediaGalleryModifyTest.php +++ b/tests/src/FunctionalJavascript/MediaGalleryModifyTest.php @@ -67,12 +67,21 @@ public function testOrderChange(): void { $this->clickSave(); - $this->clickCssSelector('div.slick--initialized.slick--field-media-images button.slick-next'); + // Check that there are 5 images in gallery. + $this->assertEquals( + 5, + $this->getSession()->evaluateScript('document.querySelectorAll("div.field--name-field-media-images div.field__item img").length'), + 'There should be five images shown in frontend.' + ); // Check that, 2nd image is file: 26357237683_0891e46ba5_k.jpg. $fileNamePosition = $this->getSession() - ->evaluateScript('jQuery(\'div.slick--initialized.slick--field-media-images div.slick-slide:not(.slick-cloned):nth(1) img\').attr(\'src\').indexOf("26357237683_0891e46ba5_k.jpg")'); - $this->assertNotEquals(-1, $fileNamePosition, 'For 2nd image in gallery, used file should be "26357237683_0891e46ba5_k.jpg".'); + ->evaluateScript('document.querySelector("div.field--name-field-media-images div.field__item:nth-child(2) div.field--name-field-image img").getAttribute("src").indexOf("26357237683_0891e46ba5_k.jpg")'); + $this->assertNotEquals( + -1, + $fileNamePosition, + 'For 2nd image in gallery, used file should be "26357237683_0891e46ba5_k.jpg".' + ); } /** @@ -98,17 +107,21 @@ public function testAddRemove(): void { $this->clickSave(); - $this->clickCssSelector('div.slick--initialized.slick--field-media-images button.slick-next'); - - // Check that, there are 4 images in gallery. - $numberOfImages = $this->getSession() - ->evaluateScript('jQuery(\'div.slick--initialized.slick--field-media-images div.slick-slide:not(.slick-cloned)\').length;'); - $this->assertEquals(4, $numberOfImages, 'There should be 4 images in Gallery.'); + // Check that there are 4 images in gallery. + $this->assertEquals( + 4, + $this->getSession()->evaluateScript('document.querySelectorAll("div.field--name-field-media-images div.field__item img").length'), + 'There should be four images shown in frontend.' + ); // Check that, 2nd image is file: 26315068204_24ffa6cfc4_o.jpg. $fileNamePosition = $this->getSession() - ->evaluateScript('jQuery(\'div.slick--initialized.slick--field-media-images div.slick-slide:not(.slick-cloned):nth(1) img\').attr(\'src\').indexOf("26315068204_24ffa6cfc4_o.jpg")'); - $this->assertNotEquals(-1, $fileNamePosition, 'For 2nd image in gallery, used file should be "26315068204_24ffa6cfc4_o.jpg".'); + ->evaluateScript('document.querySelector("div.field--name-field-media-images div.field__item:nth-child(2) div.field--name-field-image img").getAttribute("src").indexOf("26315068204_24ffa6cfc4_o.jpg")'); + $this->assertNotEquals( + -1, + $fileNamePosition, + 'For 2nd image in gallery, used file should be "26315068204_24ffa6cfc4_o.jpg".' + ); // Test add + reorder inside media library. $this->drupalGet($node->toUrl('edit-form')); @@ -128,17 +141,20 @@ public function testAddRemove(): void { $this->clickSave(); // Check that, there are 5 images in gallery. - $numberOfImages = $this->getSession() - ->evaluateScript('jQuery(\'div.slick--initialized.slick--field-media-images div.slick-slide:not(.slick-cloned)\').length;'); - $this->assertEquals(5, $numberOfImages, 'There should be 5 images in Gallery.'); - - $this->clickCssSelector('div.slick--initialized.slick--field-media-images button.slick-next'); - $this->clickCssSelector('div.slick--initialized.slick--field-media-images button.slick-next'); + $this->assertEquals( + 5, + $this->getSession()->evaluateScript('document.querySelectorAll("div.field--name-field-media-images div.field__item img").length'), + 'There should be five images shown in frontend.' + ); // Check that, 3rd image is file: reference.jpg. $fileNamePosition = $this->getSession() - ->evaluateScript('jQuery(\'div.slick--initialized.slick--field-media-images div.slick-slide:not(.slick-cloned):nth(2) img\').attr(\'src\').indexOf("reference.jpg")'); - $this->assertNotEquals(-1, $fileNamePosition, 'For 3rd image in gallery, used file should be "reference.jpg".'); + ->evaluateScript('document.querySelector("div.field--name-field-media-images div.field__item:nth-child(3) div.field--name-field-image img").getAttribute("src").indexOf("reference.jpg")'); + $this->assertNotEquals( + -1, + $fileNamePosition, + 'For 3rd image in gallery, used file should be "reference.jpg".' + ); // Test remove inside media library. $this->drupalGet($node->toUrl('edit-form')); @@ -156,17 +172,21 @@ public function testAddRemove(): void { $this->clickSave(); // Check that, there are 4 images in gallery. - $numberOfImages = $this->getSession() - ->evaluateScript('jQuery(\'div.slick--initialized.slick--field-media-images div.slick-slide:not(.slick-cloned)\').length;'); - $this->assertEquals(4, $numberOfImages, 'There should be 4 images in Gallery.'); - - $this->clickCssSelector('div.slick--initialized.slick--field-media-images button.slick-next'); - $this->clickCssSelector('div.slick--initialized.slick--field-media-images button.slick-next'); + $this->assertEquals( + 4, + $this->getSession()->evaluateScript('document.querySelectorAll("div.field--name-field-media-images div.field__item img").length'), + 'There should be four images shown in frontend.' + ); // Check that, 3rd image is not file: reference.jpg. $fileNamePosition = $this->getSession() - ->evaluateScript('jQuery(\'div.slick--initialized.slick--field-media-images div.slick-slide:not(.slick-cloned):nth(2) img\').attr(\'src\').indexOf("reference.jpg")'); - $this->assertEquals(-1, $fileNamePosition, 'For 2nd image in gallery, used file should not be "reference.jpg".'); + ->evaluateScript('document.querySelector("div.field--name-field-media-images div.field__item:nth-child(3) div.field--name-field-image img").getAttribute("src").indexOf("reference.jpg")'); + $this->assertEquals( + -1, + $fileNamePosition, + 'For 3rd image in gallery, used file should not be "reference.jpg".' + ); + } } diff --git a/tests/src/FunctionalJavascript/MetaInformationTest.php b/tests/src/FunctionalJavascript/MetaInformationTest.php index 43bb678ee..2009e19ac 100644 --- a/tests/src/FunctionalJavascript/MetaInformationTest.php +++ b/tests/src/FunctionalJavascript/MetaInformationTest.php @@ -2,6 +2,7 @@ namespace Drupal\Tests\thunder\FunctionalJavascript; +use Drupal\simple_sitemap\Manager\Generator; use Drupal\simple_sitemap\Queue\QueueWorker; use Drupal\Tests\Traits\Core\CronRunTrait; @@ -25,14 +26,14 @@ class MetaInformationTest extends ThunderJavascriptTestBase { * * @var string */ - protected static $defaultUserRole = 'administrator'; + protected static string $defaultUserRole = 'administrator'; /** * Meta tag configuration that will be set for Global meta tags. * * @var array */ - protected static $globalMetaTags = [ + protected static array $globalMetaTags = [ 'basic title' => 'Global Title', 'basic keywords' => 'Thunder,CMS,Burda', 'basic abstract' => '[random]', @@ -44,7 +45,7 @@ class MetaInformationTest extends ThunderJavascriptTestBase { * * @var array */ - protected static $contentMetaTags = [ + protected static array $contentMetaTags = [ 'basic title' => '[node:title]', 'basic abstract' => '[random]', ]; @@ -54,7 +55,7 @@ class MetaInformationTest extends ThunderJavascriptTestBase { * * @var array */ - protected static $articleMetaTags = [ + protected static array $articleMetaTags = [ 'basic title' => 'Test [node:field_teaser_text]', 'basic description' => '[random]', 'advanced robots' => 'index, follow', @@ -85,7 +86,7 @@ class MetaInformationTest extends ThunderJavascriptTestBase { * * @var array */ - protected static $customMetaTags = [ + protected static array $customMetaTags = [ 'basic title' => 'Custom [node:field_teaser_text]', 'basic description' => '[random]', 'advanced robots' => 'follow', @@ -98,7 +99,7 @@ class MetaInformationTest extends ThunderJavascriptTestBase { * * @var array */ - protected static $tokens = [ + protected static array $tokens = [ '[node:field_seo_title]' => 'Test SEO Title', '[node:field_teaser_text]' => 'Test Teaser Text', '[node:title]' => 'Test Note Title', @@ -115,7 +116,7 @@ class MetaInformationTest extends ThunderJavascriptTestBase { * * @var \Drupal\simple_sitemap\Manager\Generator */ - protected $sitemapGenerator; + protected Generator $sitemapGenerator; /** * {@inheritdoc} diff --git a/tests/src/FunctionalJavascript/NodeCreationTest.php b/tests/src/FunctionalJavascript/NodeCreationTest.php index fe88923c6..8c6a91718 100644 --- a/tests/src/FunctionalJavascript/NodeCreationTest.php +++ b/tests/src/FunctionalJavascript/NodeCreationTest.php @@ -90,8 +90,11 @@ public function testCreateNode(string $contentType, string $contentTypeDisplayNa $this->assertSession()->pageTextContains('Awesome text'); // Check Gallery paragraph. Ensure that there are 2 images in gallery. - $this->assertSession() - ->elementsCount('xpath', '//div[contains(@class, "field--name-field-paragraphs")]/div[contains(@class, "field__item")][3]//div[contains(@class, "slick-track")]/div[not(contains(@class, "slick-cloned"))]//img', 2); + $this->assertEquals( + 2, + $this->getSession()->evaluateScript('document.querySelectorAll("div.field--name-field-media-images div.field__item img").length'), + 'There should be two images shown in frontend.' + ); // Check Quote paragraph. $this->assertSession()->pageTextContains('Awesome quote'); diff --git a/tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php b/tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php index 4bf1e5dd1..0f11d48c0 100644 --- a/tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php +++ b/tests/src/FunctionalJavascript/ThunderJavascriptTestBase.php @@ -54,14 +54,14 @@ abstract class ThunderJavascriptTestBase extends WebDriverTestBase { * * @var string */ - protected $screenshotDirectory = '/tmp/thunder-screenshots'; + protected string $screenshotDirectory = '/tmp/thunder-screenshots'; /** * Default user login role used for testing. * * @var string */ - protected static $defaultUserRole = 'editor'; + protected static string $defaultUserRole = 'editor'; /** * {@inheritdoc} diff --git a/tests/src/Kernel/MetatagTest.php b/tests/src/Kernel/MetatagTest.php index 23b76d3bb..b2251a2fb 100644 --- a/tests/src/Kernel/MetatagTest.php +++ b/tests/src/Kernel/MetatagTest.php @@ -4,6 +4,7 @@ use Drupal\KernelTests\KernelTestBase; use Drupal\node\Entity\Node; +use Drupal\node\NodeInterface; use Drupal\Tests\thunder\Traits\ThunderKernelTestTrait; /** @@ -20,7 +21,7 @@ class MetatagTest extends KernelTestBase { * * @var \Drupal\node\NodeInterface */ - protected $node; + protected NodeInterface $node; /** * {@inheritdoc} diff --git a/tests/src/Nightwatch/.eslintrc.json b/tests/src/Nightwatch/.eslintrc.json deleted file mode 100644 index e3d505cad..000000000 --- a/tests/src/Nightwatch/.eslintrc.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "extends": [ - "airbnb", - "plugin:prettier/recommended" - ], - "root": true, - "env": { - "browser": true, - "es6": true, - "node": true - }, - "globals": { - "Drupal": true, - "drupalSettings": true, - "drupalTranslations": true, - "domready": true, - "jQuery": true, - "_": true, - "matchMedia": true, - "Backbone": true, - "Modernizr": true, - "CKEDITOR": true - }, - "rules": { - "prettier/prettier": "error", - "consistent-return": ["off"], - "no-underscore-dangle": ["off"], - "max-nested-callbacks": ["warn", 3], - "import/no-mutable-exports": ["warn"], - "no-plusplus": ["warn", { - "allowForLoopAfterthoughts": true - }], - "no-param-reassign": ["off"], - "no-prototype-builtins": ["off"], - "valid-jsdoc": ["warn", { - "prefer": { - "returns": "return", - "property": "prop" - }, - "requireReturn": false - }], - "no-unused-vars": ["warn"], - "operator-linebreak": ["error", "after", { "overrides": { "?": "ignore", ":": "ignore" } }] - } -} diff --git a/tests/src/Nightwatch/Commands/autoFillField.js b/tests/src/Nightwatch/Commands/autoFillField.js deleted file mode 100644 index 9f4ed5759..000000000 --- a/tests/src/Nightwatch/Commands/autoFillField.js +++ /dev/null @@ -1,134 +0,0 @@ -/** - * @file - * Automatically fill field with some random data. - * - * TODO: We should fill fields with some meaningful data! - * - * This provides a custom command, .autoFillField() - * - * @param {string} fieldName - * The filed name. - * @param {{type: string}} fieldInfo - * The filed information object. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function autoFillField(fieldName, fieldInfo) { - const browser = this; - - // eslint-disable-next-line no-console - console.log(`Auto fill field: ${fieldName}`); - - const fieldIdPart = fieldName.replace(/[_[]/g, '-').replace(/]/g, ''); - - switch (fieldInfo.type) { - // Text field. - case 'string_textfield': - case 'string_textarea': { - const stringFieldXPath = `//*[starts-with(@id, "edit-${fieldIdPart}-0-value")]`; - - browser.clearValue(stringFieldXPath); - browser.setValue( - stringFieldXPath, - `Some text ${Math.random().toString(36)}`, - ); - - return browser; - } - - case 'text_textarea': { - browser - .waitForElementVisible( - `//*[starts-with(@id, "cke_edit-${fieldIdPart}-0-value")]//iframe`, - 10000, - ) - .fillCKEditor( - `//*[starts-with(@id, "edit-${fieldIdPart}-0-value")]`, - 'Lorem ipsum dolor sit amet, cu choro iudico expetenda qui, sale assum instructior per an. His ne regione oporteat detraxit, integre intellegat definiebas mel id. Mutat persequeris definitiones nec at. Eu est legere facilis partiendo, ad sed sensibus posidonium. Insolens argumentum an pri. Mea at tritani nostrum recteque, et viris interpretaris vis.', - ); - - return browser; - } - - // Number field. - case 'number': { - const numberFieldXPath = `//*[starts-with(@id, "edit-${fieldIdPart}-0-value")]`; - - browser.clearValue(numberFieldXPath); - browser.setValue(numberFieldXPath, '1'); - - return browser; - } - - // Select options. - case 'options_select': - browser.click(`//*[starts-with(@id, "edit-${fieldIdPart}")]/option[2]`); - - return browser; - - // Default Auto-Complete widget. - case 'entity_reference_autocomplete': - browser - .clearValue(`//*[@id="edit-${fieldIdPart}-0-target-id"]`) - .setValue(`//*[@id="edit-${fieldIdPart}-0-target-id"]`, 'b') - .waitForElementVisible('//*[@id="ui-id-1"]', 10000) - .click('//*[@id="ui-id-1"]/*[1]/a'); - - return browser; - - // Select2 Auto-Complete widget. - case 'select2_entity_reference': - browser.select2.selectValue(fieldName, 'b', 1, 10000); - - return browser; - - // Entity browser widget. - case 'entity_browser_entity_reference': - browser.fillEntityBrowser( - fieldName, - fieldInfo.settings.entity_browser, - fieldInfo.settings.selection_mode, - ); - - return browser; - - // Paragraphs widget. - case 'paragraphs': - browser.paragraphs.autoCreate(fieldName, fieldInfo); - - return browser; - - // Inline entity form. - case 'inline_entity_form_simple': - if (typeof fieldInfo.inline_entity_form !== 'object') { - browser.perform(() => { - // eslint-disable-next-line no-console - console.log( - '\x1b[31m\x1b[1m%s\x1b[0m', - `Inline entity form information is not provided for field: ${fieldName}.`, - ); - }); - - return browser; - } - - browser.autoFillFields( - fieldInfo.inline_entity_form, - `${fieldName}[0][inline_entity_form]`, - ); - - return browser; - - default: - browser.perform(() => { - // eslint-disable-next-line no-console - console.log( - '\x1b[31m\x1b[1m%s\x1b[0m', - `Unsupported widget type: ${fieldInfo.type}`, - ); - }); - } - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/autoFillFields.js b/tests/src/Nightwatch/Commands/autoFillFields.js deleted file mode 100644 index 7c678f0b1..000000000 --- a/tests/src/Nightwatch/Commands/autoFillFields.js +++ /dev/null @@ -1,27 +0,0 @@ -/** - * @file - * Automatically fill multiple fields with some random data. - * - * This provides a custom command, .autoFillFields() - * - * @param {{type: string}[]} fields - * The field information objects. - * @param {string} parent - * The parent path. Fe. "field_paragraphs[0][subform]" - * - * @return {object} - * The 'browser' object. - */ -exports.command = function autoFillFields(fields, parent = '') { - const browser = this; - const fieldNames = Object.keys(fields); - - fieldNames.forEach((fieldName) => { - browser.autoFillField( - parent.length === 0 ? fieldName : `${parent}[${fieldName}]`, - fields[fieldName], - ); - }); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/fillCKEditor.js b/tests/src/Nightwatch/Commands/fillCKEditor.js deleted file mode 100644 index 0e9b51048..000000000 --- a/tests/src/Nightwatch/Commands/fillCKEditor.js +++ /dev/null @@ -1,32 +0,0 @@ -/** - * @file - * Sets tag for element. It can be existing tag or new one. - * - * This provides a custom command, .fillCKEditor() - * - * @param {string} selector - * The element selector. - * @param {string} value - * The HTML value that will be filled to CKEditor. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function fillCKEditor(selector, value) { - const browser = this; - - browser.executeAsync( - // eslint-disable-next-line prefer-arrow-callback - function inBrowser(selectorInBrowser, valueInBrowser, done) { - const elem = document.evaluate(selectorInBrowser, document).iterateNext(); - - CKEDITOR.instances[jQuery(elem)[0].id].insertHtml(valueInBrowser); - - done(); - }, - [selector, value], - () => {}, - ); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/fillEntityBrowser.js b/tests/src/Nightwatch/Commands/fillEntityBrowser.js deleted file mode 100644 index fbd153a36..000000000 --- a/tests/src/Nightwatch/Commands/fillEntityBrowser.js +++ /dev/null @@ -1,66 +0,0 @@ -/** - * @file - * Automatically fill entity browser field widget in modal dialog. - * - * This provides a custom command, .fillEntityBrowser() - * - * TODO: Extend to accept list of entities to select. - * - * @param {string} fieldName - * The filed name. - * @param {string} entityBrowserName - * The entity browser name. - * @param {string} selectionMode - * The entity browser selection mode. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function fillEntityBrowser( - fieldName, - entityBrowserName, - selectionMode, -) { - const browser = this; - - const fieldIdPart = fieldName.replace(/[_[]/g, '-').replace(/]/g, ''); - const entityBrowserNameIdPart = entityBrowserName - .replace(/[_[]/g, '-') - .replace(/]/g, ''); - - // Handle multi and single select entity browser. - const submitSelector = - selectionMode === 'selection_edit' - ? '//*[starts-with(@id, "edit-use-selected")]' - : '//*[@id = "edit-submit"]'; - - browser - .scrollInViewAndClick( - `//*[starts-with(@id, "edit-${fieldIdPart}-entity-browser-entity-browser-open-modal")]`, - ) - .waitForElementVisible( - `//*[@id="entity_browser_iframe_${entityBrowserName}"]`, - 10000, - ) - .frame(`entity_browser_iframe_${entityBrowserName}`) - .waitForElementVisible( - `//*[@id="entity-browser-${entityBrowserNameIdPart}-form"]/div[1]/div[2]`, - 10000, - ) - .waitForElementVisible( - `//*[@id="entity-browser-${entityBrowserNameIdPart}-form"]/div[1]/div[2]/div[1]`, - 10000, - ) - .click( - `//*[@id="entity-browser-${entityBrowserNameIdPart}-form"]/div[1]/div[2]/div[1]`, - ) - .waitForElementVisible(submitSelector, 10000) - .click(submitSelector) - .frame() - .waitForElementVisible( - `//*[starts-with(@id, "edit-${fieldIdPart}-current-items-0")]`, - 10000, - ); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/paragraphs/add.js b/tests/src/Nightwatch/Commands/paragraphs/add.js deleted file mode 100644 index bc8c970c4..000000000 --- a/tests/src/Nightwatch/Commands/paragraphs/add.js +++ /dev/null @@ -1,53 +0,0 @@ -/** - * @file - * Create empty paragraph for defined paragraph type. - * - * This provides a custom command, .paragraphs.add() - * - * @param {string} fieldName - * The paragraphs field name. - * @param {string} type - * The paragraphs type. - * @param {int} position - * The position where paragraph should be added. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function add(fieldName, type, position) { - const browser = this; - - if (position < 1) { - browser.perform(() => { - // eslint-disable-next-line no-console - console.log( - '\x1b[31m\x1b[1m%s\x1b[0m', - `Paragraph position has to be 1 or bigger. Following value is provided: ${position}.`, - ); - }); - - return browser; - } - - const fieldNameId = fieldName.replace(/_/g, '-'); - const addButtonPosition = position * 2 - 1; - - browser - .scrollIntoMiddleOfView( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${addButtonPosition}]//input`, - ) - .click( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${addButtonPosition}]//input`, - ) - .click( - `//div[contains(@class, "ui-dialog-content")]/*[contains(@class, "paragraphs-add-dialog-list")]//*[@name="${fieldName}_${type}_add_more"]`, - ) - .waitForElementVisible( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${ - addButtonPosition + 1 - }]//div[contains(@class, "ajax-new-content")]`, - 10000, - ); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/paragraphs/addImage.js b/tests/src/Nightwatch/Commands/paragraphs/addImage.js deleted file mode 100644 index 803a3218c..000000000 --- a/tests/src/Nightwatch/Commands/paragraphs/addImage.js +++ /dev/null @@ -1,101 +0,0 @@ -/** - * @file - * Create image paragraph. - * - * This provides a custom command, .paragraphs.addImage() - * - * Config can be following: - * { - * selectIndex: , - * uploadImage: '' - * } - * - * @param {string} fieldName - * The paragraphs field name. - * @param {int} position - * The position where paragraph should be added. - * @param {object} config - * The config for image paragraph. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function addImage(fieldName, position, config) { - const browser = this; - - const fieldNameId = fieldName.replace(/_/g, '-'); - const paragraphPosition = position * 2; - - browser.paragraphs.add(fieldName, 'image', position); - - browser - .waitForElementVisible( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${paragraphPosition}]//*[contains(@id, "subform-field-image-entity-browser-entity-browser-open-modal")]`, - 10000, - ) - .click( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${paragraphPosition}]//*[contains(@id, "subform-field-image-entity-browser-entity-browser-open-modal")]`, - ) - .waitForElementVisible( - '//*[@id="entity_browser_iframe_image_browser"]', - 10000, - ) - .frame('entity_browser_iframe_image_browser'); - - // Make selection of provided image index. - if (config.selectIndex) { - const { selectIndex } = config; - - browser - .waitForElementVisible( - `//*[@id="entity-browser-image-browser-form"]/div[1]/div[2]/div[${selectIndex}]/div[1]/span/img`, - 10000, - ) - .click( - `//*[@id="entity-browser-image-browser-form"]/div[1]/div[2]/div[${selectIndex}]`, - ); - } - - // Upload image and use it. - if (config.uploadImage) { - browser - .click('//a[text()="Import image"]') - .waitForElementVisible('//*[@id="edit-upload"]/div/a', 10000) - .executeAsync( - // eslint-disable-next-line prefer-arrow-callback - function inBrowser(done) { - const elem = document - .evaluate('//input[@type="file"]', document) - .iterateNext(); - - // Make upload field visible!!! This is workaround, so that we can - // use browser.setValue() later, to upload file. - jQuery(elem) - .show(0) - .css('visibility', 'visible') - .width(200) - .height(30) - .removeAttr('multiple'); - - done(); - }, - [], - () => {}, - ) - .setValue('//input[@type="file"]', config.uploadImage) - .waitForElementVisible( - '//*[contains(@id, "ajax-wrapper--")]/div/div/div[1]/div[1]/div/img', - 10000, - ); - } - - browser - .click('//*[@id="edit-submit"]') - .frame() - .waitForElementVisible( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${paragraphPosition}]//img`, - 10000, - ); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/paragraphs/addInstagram.js b/tests/src/Nightwatch/Commands/paragraphs/addInstagram.js deleted file mode 100644 index 59e49c846..000000000 --- a/tests/src/Nightwatch/Commands/paragraphs/addInstagram.js +++ /dev/null @@ -1,36 +0,0 @@ -/** - * @file - * Create Instagram paragraph with provided URL. - * - * This provides a custom command, .paragraphs.addInstagram() - * - * @param {string} fieldName - * The paragraphs field name. - * @param {int} position - * The position where paragraph should be added. - * @param {string} url - * The URL for Instagram paragraph. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function addInstagram(fieldName, position, url) { - const browser = this; - - const fieldNameId = fieldName.replace(/_/g, '-'); - const paragraphPosition = position * 2; - - browser.paragraphs.add(fieldName, 'instagram', position); - - browser - .waitForElementVisible( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${paragraphPosition}]//input[contains(@id, "subform-field-media-0-inline-entity-form-field-url-0-uri")]`, - 10000, - ) - .setValue( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${paragraphPosition}]//input[contains(@id, "subform-field-media-0-inline-entity-form-field-url-0-uri")]`, - url, - ); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/paragraphs/addText.js b/tests/src/Nightwatch/Commands/paragraphs/addText.js deleted file mode 100644 index 818b07379..000000000 --- a/tests/src/Nightwatch/Commands/paragraphs/addText.js +++ /dev/null @@ -1,36 +0,0 @@ -/** - * @file - * Create text paragraph with provided HTML code. - * - * This provides a custom command, .paragraphs.addText() - * - * @param {string} fieldName - * The paragraphs field name. - * @param {int} position - * The position where paragraph should be added. - * @param {string} html - * The html for text paragraph. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function addText(fieldName, position, html) { - const browser = this; - - const fieldNameId = fieldName.replace(/_/g, '-'); - const paragraphPosition = position * 2; - - browser.paragraphs.add(fieldName, 'text', position); - - browser - .waitForElementVisible( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${paragraphPosition}]//*[contains(@id, "subform-field-text-0-value")]//iframe`, - 10000, - ) - .fillCKEditor( - `//table[contains(@id, "${fieldNameId}-values")]/tbody/tr[${paragraphPosition}]//*[contains(@name, "[subform][field_text][0][value]")]`, - html, - ); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/paragraphs/autoCreate.js b/tests/src/Nightwatch/Commands/paragraphs/autoCreate.js deleted file mode 100644 index a7406761a..000000000 --- a/tests/src/Nightwatch/Commands/paragraphs/autoCreate.js +++ /dev/null @@ -1,33 +0,0 @@ -/** - * @file - * Create paragraphs for list of bundles and related fields. - * - * This provides a custom command, .paragraphs.autoCreate() - * - * @param {string} fieldName - * The paragraphs field name. - * @param {string} paragraphs - * The list of paragraph types and their fields. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function autoCreate(fieldName, paragraphs) { - const browser = this; - - const { target_type_distribution: paragraphBundles } = paragraphs; - let position = 1; - - Object.keys(paragraphBundles).forEach((bundleName) => { - const { instances, fields } = paragraphBundles[bundleName]; - - for (let i = 0; i < instances; i++) { - browser.paragraphs.add(fieldName, bundleName, position); - browser.autoFillFields(fields, `${fieldName}[${position - 1}][subform]`); - - position += 1; - } - }); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/performance/endMark.js b/tests/src/Nightwatch/Commands/performance/endMark.js deleted file mode 100644 index 7ef8d12f7..000000000 --- a/tests/src/Nightwatch/Commands/performance/endMark.js +++ /dev/null @@ -1,40 +0,0 @@ -/** - * @file - * Ends last performance measurement mark. - * - * This provides a custom command, .performance.endMark() - * - * @return {object} - * The 'browser' object. - */ -exports.command = function endMark() { - const browser = this; - - browser.performance.waitBrowser().perform(() => { - let span = browser.globals.apmSpans.pop(); - - if (!span) { - return; - } - - span.end(); - - // Set spanId to current active span, if there is any. - span = browser.globals.apmSpans.pop(); - - if (!span) { - return; - } - - browser.setCookie({ - domain: browser.globals.apmDomain, - httpOnly: false, - name: 'spanId', - path: '/', - value: span.id, - }); - browser.globals.apmSpans.push(span); - }); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/performance/endMeasurement.js b/tests/src/Nightwatch/Commands/performance/endMeasurement.js deleted file mode 100644 index 85727e3f4..000000000 --- a/tests/src/Nightwatch/Commands/performance/endMeasurement.js +++ /dev/null @@ -1,30 +0,0 @@ -/** - * @file - * Ends performance measurement for a test. - * - * This provides a custom command, .performance.endMeasurement() - * - * @return {object} - * The 'browser' object. - */ -exports.command = function endMeasurement() { - const browser = this; - - browser.performance.waitBrowser(); - - browser - .perform(() => { - let span = browser.globals.apmSpans.pop(); - - while (span) { - span.end(); - - span = browser.globals.apmSpans.pop(); - } - }) - .perform(() => { - browser.globals.apmTrans.end(); - }); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/performance/setLabel.js b/tests/src/Nightwatch/Commands/performance/setLabel.js deleted file mode 100644 index eaed0d203..000000000 --- a/tests/src/Nightwatch/Commands/performance/setLabel.js +++ /dev/null @@ -1,24 +0,0 @@ -/** - * @file - * Sets labels for performance test execution. - * - * This provides a custom command, .performance.setLabel() - * - * @param {string} name - * The label name. - * @param {string} value - * The label value. - * - * @return {object} - * The 'browser' object. - */ - -exports.command = function setLabel(name, value) { - const browser = this; - - browser.perform(() => { - browser.globals.apmTrans.setLabel(name, value); - }); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/performance/startMark.js b/tests/src/Nightwatch/Commands/performance/startMark.js deleted file mode 100644 index dda405f06..000000000 --- a/tests/src/Nightwatch/Commands/performance/startMark.js +++ /dev/null @@ -1,35 +0,0 @@ -/** - * @file - * Sets performance measurement mark. - * - * This provides a custom command, .performance.startMark() - * - * @param {string} markName - * The mark name used for naming of time spans. - * - * @return {object} - * The 'browser' object. - */ - -exports.command = function startMark(markName) { - const browser = this; - - browser.perform(() => { - const span = browser.globals.apmTrans.startSpan(markName); - - span.setLabel('branch', process.env.THUNDER_BRANCH); - span.setLabel('test', browser.currentTest.name); - - browser.globals.apmSpans.push(span); - - browser.setCookie({ - domain: browser.globals.apmDomain, - httpOnly: false, - name: 'spanId', - path: '/', - value: span.id, - }); - }); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/performance/startMeasurement.js b/tests/src/Nightwatch/Commands/performance/startMeasurement.js deleted file mode 100644 index 073e0e93e..000000000 --- a/tests/src/Nightwatch/Commands/performance/startMeasurement.js +++ /dev/null @@ -1,78 +0,0 @@ -/** - * @file - * Start performance measurement for test. - * - * This provides a custom command, .performance.startMeasurement() - * - * @param {string} serverUrl - * The Elastic APM server URL. - * @param {string} serviceName - * The service name used to display time spans inside Kibana APM. - * @param {string} transactionName - * The transaction name used for tagging logged data. - * @param {string} domain - * The testing host domain name. - * - * @return {object} - * The 'browser' object. - */ - -exports.command = function startMeasurement( - serverUrl, - transactionName, - domain, -) { - const browser = this; - - browser.perform(() => { - if (!browser.apm.isStarted()) { - browser.apm.start({ serverUrl, serviceName: 'NightwatchJS - Test' }); - } - - browser.globals.apmDomain = domain; - browser.globals.apmTrans = browser.apm.startTransaction( - transactionName, - 'test', - ); - browser.globals.apmSpans = []; - - browser - // We need to open some URL before set cookie. - .drupalRelativeURL('/') - .setCookie({ - domain, - httpOnly: false, - path: '/', - name: 'traceId', - value: browser.globals.apmTrans.traceId, - }) - .setCookie({ - domain, - httpOnly: false, - path: '/', - name: 'serverUrl', - value: serverUrl, - }); - - // Label set on Node.JS APM agent should be also set for Browser APM agent. - browser.performance - .setLabel('branch', process.env.THUNDER_BRANCH) - .setCookie({ - domain, - httpOnly: false, - path: '/', - name: 'branchTag', - value: process.env.THUNDER_BRANCH, - }) - .performance.setLabel('test', browser.currentTest.name) - .setCookie({ - domain, - httpOnly: false, - path: '/', - name: 'testTag', - value: browser.currentTest.name, - }); - }); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/performance/waitBrowser.js b/tests/src/Nightwatch/Commands/performance/waitBrowser.js deleted file mode 100644 index 09c4a6c7d..000000000 --- a/tests/src/Nightwatch/Commands/performance/waitBrowser.js +++ /dev/null @@ -1,53 +0,0 @@ -/** - * @file - * Waits for browser performance metrics to be sent. - * - * This provides a custom command, .performance.waitBrowser() - * - * @param {int} maxWait - * The maximum time for waiting for browser to send data to APM Server. - * Default to 10000 ms. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function waitBrowser(maxWait) { - const browser = this; - - maxWait = maxWait || 10000; - - browser.timeoutsAsyncScript(maxWait).executeAsync( - // eslint-disable-next-line prefer-arrow-callback - function inBrowser(done) { - const checkBrowserTransaction = () => { - if (typeof elasticApm === 'undefined') { - setTimeout(checkBrowserTransaction, 100); - - return; - } - - const transaction = window.elasticApm.getCurrentTransaction(); - if (!transaction) { - setTimeout(checkBrowserTransaction, 100); - - return; - } - - if (transaction.type === 'page-load' && !transaction.ended) { - setTimeout(checkBrowserTransaction, 100); - - return; - } - - // TODO: Ensure that not page-load transactions are also sent before navigating to new page! - setTimeout(done, 0); - }; - - setTimeout(checkBrowserTransaction, 200); - }, - [], - () => {}, - ); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/scrollInViewAndClick.js b/tests/src/Nightwatch/Commands/scrollInViewAndClick.js deleted file mode 100644 index 9db8e3940..000000000 --- a/tests/src/Nightwatch/Commands/scrollInViewAndClick.js +++ /dev/null @@ -1,19 +0,0 @@ -/** - * @file - * Helper function to scroll element in center of page and click it. - * - * This provides a custom command, .scrollInViewAndClick() - * - * @param {string} selector - * The XPATH selector for the element. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function scrollInViewAndClick(selector) { - const browser = this; - - browser.scrollIntoMiddleOfView(selector).click(selector); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/scrollIntoMiddleOfView.js b/tests/src/Nightwatch/Commands/scrollIntoMiddleOfView.js deleted file mode 100644 index 11f32e071..000000000 --- a/tests/src/Nightwatch/Commands/scrollIntoMiddleOfView.js +++ /dev/null @@ -1,48 +0,0 @@ -/** - * @file - * Scroll element into center of the screen, so that it's visible and clickable. - * - * NOTE: This function works only with XPATH!!! - * - * This provides a custom command, .scrollIntoMiddleOfView() - * - * @param {string} selector - * The XPATH selector for element. - * - * @return {object} - * The 'browser' object. - */ -exports.command = function scrollIntoMiddleOfView(selector) { - const browser = this; - - browser.executeAsync( - // eslint-disable-next-line prefer-arrow-callback - function inBrowser(selectorInBrowser, done) { - const elem = document.evaluate(selectorInBrowser, document).iterateNext(); - const viewPortHeight = Math.max( - document.documentElement.clientHeight, - window.innerHeight || 0, - ); - const element = jQuery(elem); - const scrollTop = element.offset().top - viewPortHeight / 2; - const scrollableParent = jQuery.isFunction(element.scrollParent) - ? element.scrollParent() - : []; - if ( - scrollableParent.length > 0 && - scrollableParent[0] !== document && - scrollableParent[0] !== document.body - ) { - scrollableParent[0].scrollTop = scrollTop; - } else { - window.scroll(0, scrollTop); - } - - done(); - }, - [selector], - () => {}, - ); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/select2/selectValue.js b/tests/src/Nightwatch/Commands/select2/selectValue.js deleted file mode 100644 index bd1e86c35..000000000 --- a/tests/src/Nightwatch/Commands/select2/selectValue.js +++ /dev/null @@ -1,37 +0,0 @@ -/** - * @file - * Select an element after search. - * - * This provides a custom command, .select2.selectValue() - * - * @param {string} field - * The field name. - * @param {string} search - * The element to search for. - * @param {int} index - * The index to select from list after search. - * @param {int} searchWait - * The wait time for search result in milliseconds. Default: 5000 - * - * @return {object} - * The 'browser' object. - */ -exports.command = function selectValue( - field, - search, - index, - searchWait = 5000, -) { - const browser = this; - const fieldIdPart = field.replace(/_/g, '-'); - - browser - .setValue(`//*[@id="edit-${fieldIdPart}-wrapper"]//input`, search) - .waitForElementVisible( - `//*[@id="select2-edit-${fieldIdPart}-results"]/li[${index}]`, - searchWait, - ) - .click(`//*[@id="select2-edit-${fieldIdPart}-results"]/li[${index}]`); - - return browser; -}; diff --git a/tests/src/Nightwatch/Commands/select2/setValue.js b/tests/src/Nightwatch/Commands/select2/setValue.js deleted file mode 100644 index af03871a5..000000000 --- a/tests/src/Nightwatch/Commands/select2/setValue.js +++ /dev/null @@ -1,28 +0,0 @@ -/** - * @file - * Sets tag for element. It can be existing tag or new one. - * - * This provides a custom command, .select2.setValue() - * - * @param {string} field - * The element selector. - * @param {string} name - * The tag name. - * @param {string} waitFor - * The element selector that should be waited for. - * @param {int} wait - * The wait time in milliseconds. Default: 5000 - * - * @return {object} - * The 'browser' object. - */ -exports.command = function setValue(field, name, waitFor, wait = 5000) { - const browser = this; - - browser - .setValue(field, name) - .waitForElementVisible(waitFor, wait) - .keys([browser.Keys.ENTER]); - - return browser; -}; diff --git a/tests/src/Nightwatch/Tests/ArticleCreate.js b/tests/src/Nightwatch/Tests/ArticleCreate.js deleted file mode 100644 index 13b13c800..000000000 --- a/tests/src/Nightwatch/Tests/ArticleCreate.js +++ /dev/null @@ -1,196 +0,0 @@ -/** - * @file - * Testing of an article creation with 15 paragraphs. - */ - -/** - * Module "elastic-apm-node" has to be installed for core. - * - * You can use Yarn command for that: yarn add elastic-apm-node --dev - * and it will install that module with it's requirements. - * - * We are using "process.cwd()" to get core directory. - */ -// eslint-disable-next-line import/no-dynamic-require -const apm = require(`${process.cwd()}/node_modules/elastic-apm-node`); - -module.exports = { - '@tags': ['Thunder'], - before(browser, done) { - browser.apm = apm; - - done(); - }, - createAnArticleWithParagraphs(browser) { - browser - .resizeWindow(1024, 1024) - .performance.startMeasurement( - process.env.THUNDER_APM_URL, - 'Create an article with paragraphs', - `.${process.env.THUNDER_SITE_HOSTNAME}`, - ) - .performance.startMark('full task') - .performance.startMark('login') - .drupalLogin({ name: 'test-editor', password: 'test-editor' }) - .performance.endMark() - - .performance.startMark('create article') - .drupalRelativeURL('/node/add/article') - // Start using XPATH!!! - .useXpath() - .waitForElementVisible('//*[@id="field-paragraphs-values"]', 1000) - // Set base vaues for an Article. - .performance.startMark('create article basic fields') - .click('//*[@id="edit-field-channel"]/option[3]') - .setValue( - '//*[@id="edit-title-0-value"]', - 'Lorem Cat Sum 10. Reasons why cats ipsum', - ) - .setValue( - '//*[@id="edit-field-seo-title-0-value"]', - `10 Reasons why cats ${Math.random().toString(36)}`, - ) - .select2.setValue( - '//*[@id="edit-field-tags-wrapper"]//input', - 'Performance', - '//*[@id="select2-edit-field-tags-results"]/li[contains(@class, "highlighted")]', - ) - .select2.setValue( - '//*[@id="edit-field-tags-wrapper"]//input', - 'Testing', - '//*[@id="select2-edit-field-tags-results"]/li[contains(@class, "highlighted")]', - ) - .select2.setValue( - '//*[@id="edit-field-tags-wrapper"]//input', - 'Cats', - '//*[@id="select2-edit-field-tags-results"]/li[contains(@class, "highlighted")]', - ) - .performance.endMark() - - // Set teaser information for an Article. - .performance.startMark('create article teaser information') - .setValue( - '//*[@id="edit-field-teaser-text-0-value"]', - 'The cat (Felis catus) is a small carnivorous mammal. It is the only domesticated species in the family Felidae and often referred to as the domestic cat to distinguish it from wild members of the family. The cat is either a house cat, kept as a pet, or a feral cat, freely ranging and avoiding human contact.[5] A house cat is valued by humans for companionship and for its ability to hunt rodents. About 60 cat breeds are recognized by various cat registries.', - ) - .click( - '//*[@id="edit-field-teaser-media-entity-browser-entity-browser-open-modal"]', - ) - .waitForElementVisible( - '//*[@id="entity_browser_iframe_image_browser"]', - 10000, - ) - .frame('entity_browser_iframe_image_browser') - .waitForElementVisible( - '//*[@id="entity-browser-image-browser-form"]/div[1]/div[2]/div[13]/div[1]/span/img', - 10000, - ) - .click( - '//*[@id="entity-browser-image-browser-form"]/div[1]/div[2]/div[13]', - ) - .click('//*[@id="edit-submit"]') - .frame() - .waitForElementVisible( - '//*[contains(@id, "edit-field-teaser-media-current-items-0")]/article/div/img', - 10000, - ) - .performance.endMark() - - // Create paragraphs for an Article. - .performance.startMark('create paragraphs') - .performance.startMark('create paragraphs - set 1') - .paragraphs.addText( - 'field_paragraphs', - 1, - '

1: Lorem ipsum dolor sit amet

an est tacimates molestiae, vel eu animal suscipit. Populo accusam ad has, cu libris disputando voluptatibus ius, feugiat nusquam instructior id pro?

Vel possim invidunt ex, est facer erant phaedrum ea? Ei ancillae detraxit mei, antiopam euripidis vim in? Vel ea amet movet fastidii. Magna oratio molestie eum ea, ius cu odio cibo?

', - ) - .paragraphs.addImage('field_paragraphs', 2, { - selectIndex: 14, - }) - .paragraphs.addInstagram( - 'field_paragraphs', - 3, - 'https://www.instagram.com/p/BtlH0ysgGLs/?utm_source=ig_web_copy_link', - ) - .performance.endMark() - - .performance.startMark('create paragraphs - set 2') - .paragraphs.addText( - 'field_paragraphs', - 4, - '

2: Ex cotidieque intellegebat nec

quo cu quis ridens, ei cibo omnes complectitur duo. Cu sed deleniti indoctum assueverit. Elit eligendi senserit eu nam. Velit delectus ut cum, no vim habeo veniam mentitum, eos id eros senserit.

', - ) - .paragraphs.addImage('field_paragraphs', 5, { - selectIndex: 13, - }) - .paragraphs.addInstagram( - 'field_paragraphs', - 6, - 'https://www.instagram.com/p/BtSRBAgAYod/?utm_source=ig_web_copy_link', - ) - .performance.endMark() - - .performance.startMark('create paragraphs - set 3') - .paragraphs.addText( - 'field_paragraphs', - 7, - '

3: Ne cum copiosae praesent, feugait quaestio inciderint eos ad.

Odio salutatus constituto eam ea. Mel zril cotidieque dissentiunt ea, erant inimicus convenire sit cu, ea nam oratio vituperatoribus. Noster invenire instructior ex pro. Duo ad mutat fierent.

', - ) - .paragraphs.addImage('field_paragraphs', 8, { - selectIndex: 12, - }) - .paragraphs.addInstagram( - 'field_paragraphs', - 9, - 'https://www.instagram.com/p/BtH8DB3g3GL/?utm_source=ig_web_copy_link', - ) - .performance.endMark() - - .performance.startMark('create paragraphs - set 4') - .paragraphs.addText( - 'field_paragraphs', - 10, - '

4: Commune accumsan deleniti ad duo, cum cibo lorem delicatissimi ex!

Cum mundi nostro forensibus id. At eos elitr fabulas intellegebat! Eleifend praesent mea no, id stet deseruisse pro!

', - ) - .paragraphs.addImage('field_paragraphs', 11, { - selectIndex: 13, - }) - .paragraphs.addInstagram( - 'field_paragraphs', - 12, - 'https://www.instagram.com/p/Btv_rtKF8mU/?utm_source=ig_web_copy_link', - ) - .performance.endMark() - - .performance.startMark('create paragraphs - set 5') - .paragraphs.addText( - 'field_paragraphs', - 13, - '

5: Ex persecuti argumentum pri, phaedrum cotidieque mel te?

Vix choro nusquam molestiae eu. Pro ei prodesset honestatis, an duo omnes dictas meliore. Fastidii reformidans sea ne. Modus mucius per et, audiam partiendo eu sea! Eam ea augue signiferumque.

', - ) - .paragraphs.addImage('field_paragraphs', 14, { - selectIndex: 14, - }) - .paragraphs.addInstagram( - 'field_paragraphs', - 15, - 'https://www.instagram.com/p/BtSRBAgAYod/?utm_source=ig_web_copy_link', - ) - - // End creation of paragraphs - // Close: create paragraphs - set 5. - .performance.endMark() - // Close: create paragraphs. - .performance.endMark() - - // Submit form. - .click('//*[@id="edit-submit"]') - .waitForElementVisible( - '//*[@id="block-thunder-base-content"]/div/article/div/div[1]/div[13]/div/div/p[1]/strong/span', - 60000, - ) - .performance.endMeasurement(); - - browser.end(); - }, -}; diff --git a/tests/src/Nightwatch/Tests/AutoCompleteField.js b/tests/src/Nightwatch/Tests/AutoCompleteField.js deleted file mode 100644 index 0d9220c70..000000000 --- a/tests/src/Nightwatch/Tests/AutoCompleteField.js +++ /dev/null @@ -1,57 +0,0 @@ -/** - * @file - * Testing of auto-complete field. - */ - -// eslint-disable-next-line import/no-dynamic-require -const apm = require(`${process.cwd()}/node_modules/elastic-apm-node`); -const thunderUtils = require('../utils'); - -module.exports = { - '@tags': ['Thunder', 'Thunder_Base_Set'], - before(browser, done) { - browser.apm = apm; - - // Get site information for field with autocomplete field. - thunderUtils.setSiteInfo( - 'test-admin', - 'test-admin', - { - rule: 'number_of_fields', - index: 3, - }, - browser, - done, - ); - }, - autoCompleteField(browser) { - const { bundle } = browser._site_info; - - browser - .resizeWindow(1024, 1024) - .performance.startMeasurement( - process.env.THUNDER_APM_URL, - 'Auto complete field', - `.${process.env.THUNDER_SITE_HOSTNAME}`, - ) - .drupalLogin({ name: 'test-admin', password: 'test-admin' }) - .useXpath(); - - browser - .drupalRelativeURL(`/node/add/${bundle}`) - .waitForElementVisible('//*[@id="edit-submit"]', 1000); - - browser.performance - .startMark('Select a first value') - .select2.selectValue('field_22', 'bund', 2, 10000) - .performance.endMark(); - - browser.performance - .startMark('Select a second value') - .select2.selectValue('field_22', 'bund', 4, 10000) - .performance.endMark(); - - browser.performance.endMeasurement(); - browser.end(); - }, -}; diff --git a/tests/src/Nightwatch/Tests/ContentOverviewFiltering.js b/tests/src/Nightwatch/Tests/ContentOverviewFiltering.js deleted file mode 100644 index 629f5aeaa..000000000 --- a/tests/src/Nightwatch/Tests/ContentOverviewFiltering.js +++ /dev/null @@ -1,53 +0,0 @@ -/** - * @file - * Testing of content overview filtering. - */ - -// eslint-disable-next-line import/no-dynamic-require -const apm = require(`${process.cwd()}/node_modules/elastic-apm-node`); - -module.exports = { - '@tags': ['Thunder', 'Thunder_Base_Set'], - before(browser, done) { - browser.apm = apm; - - done(); - }, - contentOverviewFiltering(browser) { - browser - .resizeWindow(1024, 1024) - .performance.startMeasurement( - process.env.THUNDER_APM_URL, - 'Filtering of content overview', - `.${process.env.THUNDER_SITE_HOSTNAME}`, - ) - .performance.startMark('full task') - .performance.startMark('login') - .drupalLogin({ name: 'test-admin', password: 'test-admin' }) - // End "login". - .performance.endMark() - .performance.startMark('Open content overview page') - .drupalRelativeURL('/admin/t0_node_bundle_0') - .useXpath() - .waitForElementPresent( - '//*[@id="block-thunder-admin-content"]/div/div/nav/ul/li[1]/a', - ) - // End "Open content overview page". - .performance.endMark() - .performance.startMark('Filter by type') - .setValue('//*[@id="edit-type"]', 'bundle_6') - .click('//*[@id="edit-submit-t0-node-bundle-0"]') - .waitForElementPresent( - '//*[@id="block-thunder-admin-content"]/div/div/nav[@class="pager"]/ul/li[1]/a[contains(@href, "bundle_6")]', - ) - // End "Filter by type". - .performance.endMark() - // End full task. - .performance.endMark(); - - // End measurement transaction for whole test. - browser.performance.endMeasurement(); - - browser.end(); - }, -}; diff --git a/tests/src/Nightwatch/Tests/CreateMostUsedContent.js b/tests/src/Nightwatch/Tests/CreateMostUsedContent.js deleted file mode 100644 index 45f46f39d..000000000 --- a/tests/src/Nightwatch/Tests/CreateMostUsedContent.js +++ /dev/null @@ -1,90 +0,0 @@ -/** - * @file - * Testing of content creation for most used bundle type. - */ - -/** - * Module "elastic-apm-node" has to be installed for core. - * - * You can use Yarn command for that: yarn add elastic-apm-node --dev - * and it will install that module with it's requirements. - * - * We are using "process.cwd()" to get core directory. - */ - -// eslint-disable-next-line import/no-dynamic-require -const apm = require(`${process.cwd()}/node_modules/elastic-apm-node`); -const thunderUtils = require('../utils'); -const thunderConfig = require('../config'); - -module.exports = { - '@tags': ['Thunder', 'Thunder_Base_Set'], - before(browser, done) { - browser.apm = apm; - - // Get site information. - thunderUtils.setSiteInfo( - 'test-admin', - 'test-admin', - { - rule: 'count', - index: 0, - percent_of_instances_threshold: 50, - }, - browser, - done, - ); - }, - createMostUsedContent(browser) { - const { bundle, fields } = browser._site_info; - - // Discover test set name for current test. - const testSetName = thunderUtils.getTestSetName( - browser._site_info, - browser.currentTest.name, - ); - - // We have to filter returned fields, because we always have 100% threshold. - const filteredFields = thunderUtils.filterObject( - fields, - thunderConfig.createMostUsedContent[testSetName].fieldsToFill, - ); - - browser - .resizeWindow(1024, 1024) - .performance.startMeasurement( - process.env.THUNDER_APM_URL, - 'Create new most used content (min)', - `.${process.env.THUNDER_SITE_HOSTNAME}`, - ) - .performance.startMark('full task') - .performance.startMark('login') - .drupalLogin({ name: 'test-admin', password: 'test-admin' }) - .performance.endMark() - - .performance.startMark('create new most used content') - .drupalRelativeURL(`/node/add/${bundle}`) - // Start using XPATH!!! - .useXpath() - .waitForElementVisible('//*[@id="edit-submit"]', 10000) - - // Fill fields for content bundle. - .performance.startMark('fill fields') - .autoFillFields(filteredFields) - .performance.endMark(); - - // Close mark and save newly created content entity. - browser.performance - .endMark() - - // Submit form. - .click('//*[@id="edit-submit"]') - .waitForElementVisible( - '//*[@id="block-thunder-base-page-title"]/div[2]/h1/span', - 60000, - ) - .performance.endMeasurement(); - - browser.end(); - }, -}; diff --git a/tests/src/Nightwatch/Tests/EditMostUsedContent.js b/tests/src/Nightwatch/Tests/EditMostUsedContent.js deleted file mode 100644 index 328ba8a3a..000000000 --- a/tests/src/Nightwatch/Tests/EditMostUsedContent.js +++ /dev/null @@ -1,62 +0,0 @@ -/** - * @file - * Testing of editing for most used bundle type. - */ - -// eslint-disable-next-line import/no-dynamic-require -const apm = require(`${process.cwd()}/node_modules/elastic-apm-node`); -const thunderUtils = require('../utils'); - -module.exports = { - '@tags': ['Thunder', 'Thunder_Base_Set'], - before(browser, done) { - browser.apm = apm; - - // Get site information. - thunderUtils.setSiteInfo( - 'test-admin', - 'test-admin', - { - rule: 'count', - index: 0, - }, - browser, - done, - ); - }, - editMostUsedContent(browser) { - const { bundle, fields } = browser._site_info; - - browser - .resizeWindow(1024, 1024) - .performance.startMeasurement( - process.env.THUNDER_APM_URL, - 'Edit most used content (min)', - `.${process.env.THUNDER_SITE_HOSTNAME}`, - ) - .drupalLogin({ name: 'test-admin', password: 'test-admin' }) - .useXpath() - .drupalRelativeURL(`/admin/content?type=${bundle}`) - - .performance.startMark('full task') - .performance.startMark('load form') - .click( - '(//li[contains(@class,"dropbutton-action")])[1]//a[contains(@href, "edit")]', - ) - .waitForElementVisible('//*[@id="edit-submit"]', 1000) - .performance.endMark() // "load form" task. - - .autoFillFields(fields) - - .performance.startMark('submit save form') - .click('//*[@id="edit-submit"]') - .waitForElementVisible('//*[@id="block-thunder-admin-content"]', 10000) - .performance.endMark() // "submit save form" task. - - .performance.endMark() // "full task" task. - - .performance.endMeasurement(); - - browser.end(); - }, -}; diff --git a/tests/src/Nightwatch/Tests/SearchApiContentOverviewFiltering.js b/tests/src/Nightwatch/Tests/SearchApiContentOverviewFiltering.js deleted file mode 100644 index 65b2d33bc..000000000 --- a/tests/src/Nightwatch/Tests/SearchApiContentOverviewFiltering.js +++ /dev/null @@ -1,58 +0,0 @@ -/** - * @file - * Testing of content overview filtering with a search api based view. - */ - -// eslint-disable-next-line import/no-dynamic-require -const apm = require(`${process.cwd()}/node_modules/elastic-apm-node`); - -module.exports = { - '@tags': ['Thunder', 'Thunder_Base_Set'], - before(browser, done) { - browser.apm = apm; - - done(); - }, - searchApiContentOverviewFiltering(browser) { - browser - .resizeWindow(1024, 1024) - .performance.startMeasurement( - process.env.THUNDER_APM_URL, - 'Filtering of content overview', - `.${process.env.THUNDER_SITE_HOSTNAME}`, - ) - .performance.startMark('full task') - .performance.startMark('login') - .drupalLogin({ name: 'test-admin', password: 'test-admin' }) - // End "login". - .performance.endMark() - .performance.startMark('Open content overview page') - .drupalRelativeURL('/admin/t1_node_bundle_0/node') - .useXpath() - .waitForElementPresent( - '//*[@id="block-thunder-admin-content"]/div/div/nav/ul/li[1]/a', - ) - // End "Open content overview page". - .performance.endMark() - .performance.startMark('Filter by type') - .moveToElement('//*[@id="block-t1-node-bundle-0-type"]', 10, 10) - .click( - '//*[@id="block-t1-node-bundle-0-type"]/div/span/span[1]/span/span[2]/b', - ) - .click( - '//*[@class="select2-results__options"]/li[contains(@data-select2-id, "bundle_6")]', - ) - .waitForElementPresent( - '//*[@id="block-thunder-admin-content"]/div/div[contains(@class, "view-t1-node-bundle-0")]/nav[@class="pager"]/ul/li[1]/a[contains(@href, "bundle_6")]', - ) - // End "Filter by type". - .performance.endMark() - // End full task. - .performance.endMark(); - - // End measurement transaction for whole test. - browser.performance.endMeasurement(); - - browser.end(); - }, -}; diff --git a/tests/src/Nightwatch/config.js b/tests/src/Nightwatch/config.js deleted file mode 100644 index 279692339..000000000 --- a/tests/src/Nightwatch/config.js +++ /dev/null @@ -1,52 +0,0 @@ -/** - * Configuration for Thunder Nightwatch tests. - */ - -module.exports = { - createMostUsedContent: { - testSetFootprint: { - // Order of test sets is important, because first matched will be used. - Thunder_Base_Set: [ - ['fields', 'field_13', 'third_party_settings', 'paragraphs_features'], - ], - Thunder: [['bundle']], - }, - Thunder_Base_Set: { - fieldsToFill: { - title: true, // required - field_2: true, // required - field_13: { - bundle_0: { - field_4: true, - field_6: true, - }, - bundle_2: { - field_4: true, - field_7: true, - field_12: true, - }, - bundle_4: { - field_4: true, - field_12: { - name: true, - field_1: true, - field_2: true, - }, - }, - bundle_8: { - field_4: true, - field_7: true, - }, - }, // optional - paragraphs - field_18: true, // required - field_23: true, // required - }, - }, - Thunder: { - fieldsToFill: { - title: true, - body: true, - }, - }, - }, -}; diff --git a/tests/src/Nightwatch/utils.js b/tests/src/Nightwatch/utils.js deleted file mode 100644 index 64131c68e..000000000 --- a/tests/src/Nightwatch/utils.js +++ /dev/null @@ -1,89 +0,0 @@ -// eslint-disable-next-line import/no-dynamic-require -const request = require(`${process.cwd()}/node_modules/request`); -const thunderConfig = require('./config'); - -module.exports = { - setSiteInfo(adminUser, adminPass, queryParams, browser, browserDoneCallback) { - const baseUrl = process.env.DRUPAL_TEST_BASE_URL; - - request( - { - url: `${baseUrl}/user/login?_format=json`, - method: 'POST', - body: JSON.stringify({ name: adminUser, pass: adminPass }), - headers: { - 'Content-type': 'application/json', - }, - jar: true, - }, - () => { - request( - { - url: `${baseUrl}/thunder-performance-measurement/site-info`, - qs: queryParams, - jar: true, - }, - (error, response, body) => { - const { data } = JSON.parse(body); - - browser._site_info = data; - - browserDoneCallback(); - }, - ); - }, - ); - }, - - /** - * Find test set name based on defined footprint in config. - * - * @param {object} data - * The site info object. - * @param {string} testName - * The test name. - * - * @return {string|undefined} - * Returns found test set name. - */ - getTestSetName(data, testName) { - const { testSetFootprint } = thunderConfig[testName]; - - return Object.keys(testSetFootprint).find((testSetName) => - testSetFootprint[testSetName].find( - (objectPath) => - objectPath.reduce( - (obj, key) => (obj && obj[key] ? obj[key] : null), - data, - ) !== null, - ), - ); - }, - - filterObject(data, filterBy) { - return Object.keys(data).reduce((result, key) => { - if (Object.keys(filterBy).includes(key)) { - result[key] = data[key]; - } - - // Filter nested objects only if we have nested filter definition. - if (typeof filterBy[key] !== 'object') { - return result; - } - - // Filter custom sub-from fields. - ['target_type_distribution', 'fields', 'inline_entity_form'].forEach( - (filterKey) => { - if (typeof data[key][filterKey] === 'object') { - result[key][filterKey] = this.filterObject( - data[key][filterKey], - filterBy[key], - ); - } - }, - ); - - return result; - }, {}); - }, -}; diff --git a/tests/src/Traits/ThunderTestTrait.php b/tests/src/Traits/ThunderTestTrait.php index b244072ee..c42b21048 100644 --- a/tests/src/Traits/ThunderTestTrait.php +++ b/tests/src/Traits/ThunderTestTrait.php @@ -20,15 +20,6 @@ */ trait ThunderTestTrait { - /** - * {@inheritdoc} - */ - protected function installParameters(): array { - $parameters = parent::installParameters(); - $parameters['forms']['thunder_module_configure_form'] = ['install_modules_thunder_demo' => NULL]; - return $parameters; - } - /** * {@inheritdoc} */ diff --git a/thunder.info.yml b/thunder.info.yml index 8e024d289..c82aa16f4 100644 --- a/thunder.info.yml +++ b/thunder.info.yml @@ -3,7 +3,7 @@ type: profile description: 'The Drupal based CMS for professional publishing.' project: thunder core_version_requirement: ~10.3.0 -version: '7.3.0' +version: '7.3.3' distribution: name: Thunder @@ -49,7 +49,6 @@ install: - admin_toolbar:admin_toolbar_links_access_filter - autosave_form:autosave_form - autofill:autofill - - blazy:blazy - content_lock:content_lock - diff:diff - dropzonejs:dropzonejs @@ -82,8 +81,6 @@ install: - schema_metatag:schema_article - select2:select2 - simple_sitemap:simple_sitemap - - slick:slick - - responsive_preview:responsive_preview - update_helper_checklist:update_helper_checklist - views_bulk_edit:views_bulk_edit # thunder diff --git a/thunder.post_update.php b/thunder.post_update.php index e34b956ee..42852fab7 100644 --- a/thunder.post_update.php +++ b/thunder.post_update.php @@ -20,7 +20,6 @@ function thunder_post_update_0001_upgrade_to_thunder7(array &$sandbox): string { $moduleInstaller->install([ 'media_library_media_modify', 'gin_toolbar', - 'jquery_ui', 'ckeditor5', ]); @@ -125,3 +124,17 @@ function thunder_post_update_0003_enable_sticky_action_buttons(array &$sandbox): return t('Sticky action buttons enabled.'); } + +/** + * This update removes blazy and slick integration. + */ +function thunder_post_update_0004_remove_blazy_and_slick(): string { + /** @var \Drupal\update_helper\Updater $updater */ + $updater = \Drupal::service('update_helper.updater'); + + // Execute configuration update definitions with logging of success. + $updater->executeUpdate('thunder', 'thunder_post_update_0004_remove_blazy_and_slick'); + + // Output logged messages to related channel of update execution. + return $updater->logger()->output(); +} diff --git a/updates_checklist.yml b/updates_checklist.yml index 42d98b5db..bfdf38558 100644 --- a/updates_checklist.yml +++ b/updates_checklist.yml @@ -10,3 +10,9 @@ v7.2.2: thunder_post_update_0002_enable_paragraphs_split: '#title': 'Enable paragraphs split functionality.' '#description': '

This configuration update will update input formats and editors settings

' +v7.X.X: + '#title': 'Update to version v7.X.X' + '#description': '

Remove blazy and slick integration

' + thunder_post_update_0002_enable_paragraphs_split: + '#title': 'Remove blazy and slick integration.' + '#description': '

Remove configuration for blazy and slick modules

'