diff --git a/.github/workflows/update-config.yml b/.github/workflows/update-config.yml index 5f79886fc..b76aa2619 100644 --- a/.github/workflows/update-config.yml +++ b/.github/workflows/update-config.yml @@ -3,6 +3,8 @@ on: repository_dispatch: types: [config_change] name: Update config +env: + GH_TOKEN: ${{ github.token }} jobs: update-config: runs-on: ubuntu-latest @@ -21,10 +23,7 @@ jobs: - 3306:3306 steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 1 - + - uses: actions/checkout@v4 - name: Download latest dump env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -41,16 +40,43 @@ jobs: # Update platform drush helfi:tools:update-platform + - name: Check module versions + id: module-status + run: | + MODE="delete" + drush helfi:tools:check-composer-versions $GITHUB_WORKSPACE/composer.lock --format=markdown_table >> $GITHUB_STEP_SUMMARY && EXIT_CODE=$? || EXIT_CODE=$? + if [ "$EXIT_CODE" -eq 3 ]; then + MODE="upsert" + echo " " >> $GITHUB_STEP_SUMMARY + echo ":warning: Failed to install the latest version of the packages listed above" >> $GITHUB_STEP_SUMMARY + echo " " >> $GITHUB_STEP_SUMMARY + echo "Please run \`composer why-not drupal/package_name package_version\` to see why." >> $GITHUB_STEP_SUMMARY + fi + echo "MODE=$MODE" >> $GITHUB_OUTPUT + cat $GITHUB_STEP_SUMMARY > /tmp/pr-message.txt + - name: Create Pull Request - uses: peter-evans/create-pull-request@v4 + uses: peter-evans/create-pull-request@v6 with: - committer: GitHub - author: actions-bot commit-message: Update configuration title: Automatic update labels: auto-update body: | - Updated active configuration. - Updated platform - branch: update-configuration + + - name: Attempt to find PR + env: + BRANCH_NAME: ${{ github.head_ref || github.ref_name }} + id: find-pr + run: echo "number=$(gh pr list --base ${BRANCH_NAME} --head update-configuration --json number --jq '.[].number')" >> $GITHUB_OUTPUT + + - name: Comment PR + uses: thollander/actions-comment-pull-request@v2 + if: ${{ steps.find-pr.outputs.number != '' }} + with: + comment_tag: status + mode: ${{ steps.module-status.outputs.MODE }} + filePath: /tmp/pr-message.txt + pr_number: ${{ steps.find-pr.outputs.number }} diff --git a/composer.lock b/composer.lock index 8881cf2a3..2f7a86eea 100644 --- a/composer.lock +++ b/composer.lock @@ -125,16 +125,16 @@ }, { "name": "chi-teck/drupal-code-generator", - "version": "3.3.0", + "version": "3.4.0", "source": { "type": "git", "url": "https://github.com/Chi-teck/drupal-code-generator.git", - "reference": "56da9209b24a5a5b5d27bec9e523f02bdd101770" + "reference": "b8136b945dc3446894e6cd2b2f055e147140faed" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Chi-teck/drupal-code-generator/zipball/56da9209b24a5a5b5d27bec9e523f02bdd101770", - "reference": "56da9209b24a5a5b5d27bec9e523f02bdd101770", + "url": "https://api.github.com/repos/Chi-teck/drupal-code-generator/zipball/b8136b945dc3446894e6cd2b2f055e147140faed", + "reference": "b8136b945dc3446894e6cd2b2f055e147140faed", "shasum": "" }, "require": { @@ -152,16 +152,16 @@ "squizlabs/php_codesniffer": "<3.6" }, "require-dev": { - "chi-teck/drupal-coder-extension": "^2.0.0-alpha4", - "drupal/coder": "8.3.22", - "drupal/core": "10.1.x-dev", + "chi-teck/drupal-coder-extension": "^2.0.0-beta2", + "drupal/coder": "8.3.23", + "drupal/core": "10.3.x-dev", "ext-simplexml": "*", - "phpspec/prophecy-phpunit": "^2.0", - "phpunit/phpunit": "^9.5", - "squizlabs/php_codesniffer": "^3.7", - "symfony/var-dumper": "^6.3", + "phpspec/prophecy-phpunit": "^2.2", + "phpunit/phpunit": "^9.6", + "squizlabs/php_codesniffer": "^3.9", + "symfony/var-dumper": "^6.4", "symfony/yaml": "^6.3", - "vimeo/psalm": "^5.14.0" + "vimeo/psalm": "^5.22.2" }, "bin": [ "bin/dcg" @@ -179,9 +179,9 @@ "description": "Drupal code generator", "support": { "issues": "https://github.com/Chi-teck/drupal-code-generator/issues", - "source": "https://github.com/Chi-teck/drupal-code-generator/tree/3.3.0" + "source": "https://github.com/Chi-teck/drupal-code-generator/tree/3.4.0" }, - "time": "2023-10-21T12:57:05+00:00" + "time": "2024-03-10T13:35:00+00:00" }, { "name": "commerceguys/addressing", @@ -1190,16 +1190,16 @@ }, { "name": "doctrine/collections", - "version": "2.2.0", + "version": "2.2.1", "source": { "type": "git", "url": "https://github.com/doctrine/collections.git", - "reference": "07e16cd7b80a2cffed99e36b541876af172f0257" + "reference": "420480fc085bc65f3c956af13abe8e7546f94813" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/07e16cd7b80a2cffed99e36b541876af172f0257", - "reference": "07e16cd7b80a2cffed99e36b541876af172f0257", + "url": "https://api.github.com/repos/doctrine/collections/zipball/420480fc085bc65f3c956af13abe8e7546f94813", + "reference": "420480fc085bc65f3c956af13abe8e7546f94813", "shasum": "" }, "require": { @@ -1256,7 +1256,7 @@ ], "support": { "issues": "https://github.com/doctrine/collections/issues", - "source": "https://github.com/doctrine/collections/tree/2.2.0" + "source": "https://github.com/doctrine/collections/tree/2.2.1" }, "funding": [ { @@ -1272,7 +1272,7 @@ "type": "tidelift" } ], - "time": "2024-02-25T22:55:36+00:00" + "time": "2024-03-05T22:28:45+00:00" }, { "name": "doctrine/deprecations", @@ -1995,16 +1995,16 @@ }, { "name": "drupal/core", - "version": "10.2.3", + "version": "10.2.4", "source": { "type": "git", "url": "https://github.com/drupal/core.git", - "reference": "cc8c7952f7013795b735f5c15290e76937163bb7" + "reference": "d1c5b44adfc79bda03252471491b0fba89d87eff" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/drupal/core/zipball/cc8c7952f7013795b735f5c15290e76937163bb7", - "reference": "cc8c7952f7013795b735f5c15290e76937163bb7", + "url": "https://api.github.com/repos/drupal/core/zipball/d1c5b44adfc79bda03252471491b0fba89d87eff", + "reference": "d1c5b44adfc79bda03252471491b0fba89d87eff", "shasum": "" }, "require": { @@ -2152,9 +2152,9 @@ ], "description": "Drupal is an open source content management platform powering millions of websites and applications.", "support": { - "source": "https://github.com/drupal/core/tree/10.2.3" + "source": "https://github.com/drupal/core/tree/10.2.4" }, - "time": "2024-02-07T22:44:48+00:00" + "time": "2024-03-06T08:23:56+00:00" }, { "name": "drupal/core-composer-scaffold", @@ -2568,6 +2568,14 @@ "homepage": "https://www.drupal.org/u/greg-boggs", "role": "Maintainer" }, + { + "name": "diamondsea", + "homepage": "https://www.drupal.org/user/430714" + }, + { + "name": "Greg Boggs", + "homepage": "https://www.drupal.org/user/153069" + }, { "name": "hmartens", "homepage": "https://www.drupal.org/user/622826" @@ -3724,16 +3732,16 @@ }, { "name": "drupal/hdbt", - "version": "6.4.17", + "version": "6.4.25", "source": { "type": "git", "url": "https://github.com/City-of-Helsinki/drupal-hdbt.git", - "reference": "13dbc7ad6fcf6f943cca47f3002e213052d23111" + "reference": "fda238d677f4b044b239eb4916a5fd4a0a7e0eb5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/City-of-Helsinki/drupal-hdbt/zipball/13dbc7ad6fcf6f943cca47f3002e213052d23111", - "reference": "13dbc7ad6fcf6f943cca47f3002e213052d23111", + "url": "https://api.github.com/repos/City-of-Helsinki/drupal-hdbt/zipball/fda238d677f4b044b239eb4916a5fd4a0a7e0eb5", + "reference": "fda238d677f4b044b239eb4916a5fd4a0a7e0eb5", "shasum": "" }, "require": { @@ -3751,23 +3759,23 @@ "Drupal" ], "support": { - "source": "https://github.com/City-of-Helsinki/drupal-hdbt/tree/6.4.17", + "source": "https://github.com/City-of-Helsinki/drupal-hdbt/tree/6.4.25", "issues": "https://github.com/City-of-Helsinki/drupal-hdbt/issues" }, - "time": "2024-02-28T07:06:09+00:00" + "time": "2024-03-12T12:56:27+00:00" }, { "name": "drupal/hdbt_admin", - "version": "3.1.2", + "version": "3.1.4", "source": { "type": "git", "url": "https://github.com/City-of-Helsinki/drupal-hdbt-admin.git", - "reference": "220819586d9ec9d11d72115be9a271ebc181c513" + "reference": "b39cc0cbf23eeea448a2b10b835b406b19efc3c0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/City-of-Helsinki/drupal-hdbt-admin/zipball/220819586d9ec9d11d72115be9a271ebc181c513", - "reference": "220819586d9ec9d11d72115be9a271ebc181c513", + "url": "https://api.github.com/repos/City-of-Helsinki/drupal-hdbt-admin/zipball/b39cc0cbf23eeea448a2b10b835b406b19efc3c0", + "reference": "b39cc0cbf23eeea448a2b10b835b406b19efc3c0", "shasum": "" }, "require": { @@ -3786,10 +3794,10 @@ "Drupal" ], "support": { - "source": "https://github.com/City-of-Helsinki/drupal-hdbt-admin/tree/3.1.2", + "source": "https://github.com/City-of-Helsinki/drupal-hdbt-admin/tree/3.1.4", "issues": "https://github.com/City-of-Helsinki/drupal-hdbt-admin/issues" }, - "time": "2024-02-09T07:13:18+00:00" + "time": "2024-03-06T12:26:23+00:00" }, { "name": "drupal/health_check", @@ -3843,16 +3851,16 @@ }, { "name": "drupal/helfi_api_base", - "version": "2.6.1", + "version": "2.6.4", "source": { "type": "git", "url": "https://github.com/City-of-Helsinki/drupal-module-helfi-api-base.git", - "reference": "5d713ea9804fe9c9f728da6cd02542f10768f918" + "reference": "778b6431d341db6f280aeb343d1bc673a378b5a0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/City-of-Helsinki/drupal-module-helfi-api-base/zipball/5d713ea9804fe9c9f728da6cd02542f10768f918", - "reference": "5d713ea9804fe9c9f728da6cd02542f10768f918", + "url": "https://api.github.com/repos/City-of-Helsinki/drupal-module-helfi-api-base/zipball/778b6431d341db6f280aeb343d1bc673a378b5a0", + "reference": "778b6431d341db6f280aeb343d1bc673a378b5a0", "shasum": "" }, "require": { @@ -3881,10 +3889,10 @@ ], "description": "Helfi - API Base", "support": { - "source": "https://github.com/City-of-Helsinki/drupal-module-helfi-api-base/tree/2.6.1", + "source": "https://github.com/City-of-Helsinki/drupal-module-helfi-api-base/tree/2.6.4", "issues": "https://github.com/City-of-Helsinki/drupal-module-helfi-api-base/issues" }, - "time": "2024-02-09T07:17:02+00:00" + "time": "2024-03-06T08:32:04+00:00" }, { "name": "drupal/helfi_azure_fs", @@ -3932,12 +3940,12 @@ "source": { "type": "git", "url": "https://github.com/City-of-Helsinki/drupal-tools.git", - "reference": "7a1cc3ed0c3e4f81bb964fa33a55d5987cb673f1" + "reference": "f038bbff89056bc61ca57d2229b4d74127e8017c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/City-of-Helsinki/drupal-tools/zipball/7a1cc3ed0c3e4f81bb964fa33a55d5987cb673f1", - "reference": "7a1cc3ed0c3e4f81bb964fa33a55d5987cb673f1", + "url": "https://api.github.com/repos/City-of-Helsinki/drupal-tools/zipball/f038bbff89056bc61ca57d2229b4d74127e8017c", + "reference": "f038bbff89056bc61ca57d2229b4d74127e8017c", "shasum": "" }, "require": { @@ -4009,7 +4017,7 @@ "source": "https://github.com/City-of-Helsinki/drupal-tools/tree/main", "issues": "https://github.com/City-of-Helsinki/drupal-tools/issues" }, - "time": "2024-02-28T07:58:18+00:00" + "time": "2024-03-07T07:59:22+00:00" }, { "name": "drupal/helfi_navigation", @@ -4047,16 +4055,16 @@ }, { "name": "drupal/helfi_platform_config", - "version": "4.3.16", + "version": "4.3.20", "source": { "type": "git", "url": "https://github.com/City-of-Helsinki/drupal-helfi-platform-config.git", - "reference": "372c946e224d5d7aa3be3aa33a5b21652093013f" + "reference": "9d7def6814bf8a94f662f4fd983cb8fe5114ae03" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/City-of-Helsinki/drupal-helfi-platform-config/zipball/372c946e224d5d7aa3be3aa33a5b21652093013f", - "reference": "372c946e224d5d7aa3be3aa33a5b21652093013f", + "url": "https://api.github.com/repos/City-of-Helsinki/drupal-helfi-platform-config/zipball/9d7def6814bf8a94f662f4fd983cb8fe5114ae03", + "reference": "9d7def6814bf8a94f662f4fd983cb8fe5114ae03", "shasum": "" }, "require": { @@ -4138,7 +4146,8 @@ "[#UHF-7008] Core localization file download URL is wrong (https://www.drupal.org/project/drupal/issues/3022876)": "https://git.drupalcode.org/project/drupal/-/commit/40a96136b2dfe4322338508dffa636f6cb407900.patch", "[#UHF-7008] Add multilingual support for caching basefield definitions (https://www.drupal.org/project/drupal/issues/3114824)": "https://www.drupal.org/files/issues/2020-02-20/3114824_2.patch", "[#UHF-7008] Admin toolbar and contextual links should always be rendered in the admin language (https://www.drupal.org/project/drupal/issues/2313309)": "https://www.drupal.org/files/issues/2023-12-19/2313309-179.patch", - "[#UHF-9388] Process translation config files for custom modules (https://www.drupal.org/i/2845437)": "https://www.drupal.org/files/issues/2023-10-16/2845437-61.patch" + "[#UHF-9388] Process translation config files for custom modules (https://www.drupal.org/i/2845437)": "https://www.drupal.org/files/issues/2023-10-16/2845437-61.patch", + "[#UHF-9690] Allow updating lists when switching from allowed values to allowed values function (https://www.drupal.org/i/2873353)": "https://www.drupal.org/files/issues/2021-05-18/allow-allowed-values-function-update-D9-2873353_1.patch" }, "drupal/default_content": { "https://www.drupal.org/project/default_content/issues/2640734#comment-14638943": "https://raw.githubusercontent.com/City-of-Helsinki/drupal-helfi-platform-config/main/patches/default_content_2.0.0-alpha2-2640734_manual_imports-e164a354.patch" @@ -4165,10 +4174,10 @@ ], "description": "HELfi platform config", "support": { - "source": "https://github.com/City-of-Helsinki/drupal-helfi-platform-config/tree/4.3.16", + "source": "https://github.com/City-of-Helsinki/drupal-helfi-platform-config/tree/4.3.20", "issues": "https://github.com/City-of-Helsinki/drupal-helfi-platform-config/issues" }, - "time": "2024-02-27T09:50:42+00:00" + "time": "2024-03-12T08:04:15+00:00" }, { "name": "drupal/helfi_proxy", @@ -4224,16 +4233,16 @@ }, { "name": "drupal/helfi_tpr", - "version": "2.3.5", + "version": "2.3.6", "source": { "type": "git", "url": "https://github.com/City-of-Helsinki/drupal-module-helfi-tpr.git", - "reference": "c14c8634c913125faf96d217d11bac4a456049a8" + "reference": "44f69ad718b06aea6022fc9e66c4625525e056c4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/City-of-Helsinki/drupal-module-helfi-tpr/zipball/c14c8634c913125faf96d217d11bac4a456049a8", - "reference": "c14c8634c913125faf96d217d11bac4a456049a8", + "url": "https://api.github.com/repos/City-of-Helsinki/drupal-module-helfi-tpr/zipball/44f69ad718b06aea6022fc9e66c4625525e056c4", + "reference": "44f69ad718b06aea6022fc9e66c4625525e056c4", "shasum": "" }, "require": { @@ -4259,10 +4268,10 @@ ], "description": "TPR integration", "support": { - "source": "https://github.com/City-of-Helsinki/drupal-module-helfi-tpr/tree/2.3.5", + "source": "https://github.com/City-of-Helsinki/drupal-module-helfi-tpr/tree/2.3.6", "issues": "https://github.com/City-of-Helsinki/drupal-module-helfi-tpr/issues" }, - "time": "2024-01-26T07:55:57+00:00" + "time": "2024-03-01T14:46:13+00:00" }, { "name": "drupal/helfi_tunnistamo", @@ -4360,17 +4369,17 @@ }, { "name": "drupal/imagecache_external", - "version": "3.0.1", + "version": "3.0.2", "source": { "type": "git", "url": "https://git.drupalcode.org/project/imagecache_external.git", - "reference": "3.0.1" + "reference": "3.0.2" }, "dist": { "type": "zip", - "url": "https://ftp.drupal.org/files/projects/imagecache_external-3.0.1.zip", - "reference": "3.0.1", - "shasum": "f36e080a5059d760f4c47ad21ac9391f1b1ea6b3" + "url": "https://ftp.drupal.org/files/projects/imagecache_external-3.0.2.zip", + "reference": "3.0.2", + "shasum": "0c6254c6de9c4ecd62da6f82f231484f5178e61d" }, "require": { "drupal/core": "^9.3 || ^10" @@ -4378,8 +4387,8 @@ "type": "drupal-module", "extra": { "drupal": { - "version": "3.0.1", - "datestamp": "1665918248", + "version": "3.0.2", + "datestamp": "1709311320", "security-coverage": { "status": "covered", "message": "Covered by Drupal's security advisory policy" @@ -5079,7 +5088,7 @@ "extra": { "drupal": { "version": "8.x-1.17", - "datestamp": "1705234146", + "datestamp": "1709804220", "security-coverage": { "status": "covered", "message": "Covered by Drupal's security advisory policy" @@ -6592,26 +6601,30 @@ }, { "name": "drupal/view_unpublished", - "version": "1.1.0", + "version": "1.2.0", "source": { "type": "git", "url": "https://git.drupalcode.org/project/view_unpublished.git", - "reference": "8.x-1.1" + "reference": "8.x-1.2" }, "dist": { "type": "zip", - "url": "https://ftp.drupal.org/files/projects/view_unpublished-8.x-1.1.zip", - "reference": "8.x-1.1", - "shasum": "f9f5e88cbaf1a1e71952d94cf67ef2f180e292be" + "url": "https://ftp.drupal.org/files/projects/view_unpublished-8.x-1.2.zip", + "reference": "8.x-1.2", + "shasum": "14374dd56d841270207e21974c7b7cf8aa1804f7" }, "require": { "drupal/core": "^9.4 || ^10" }, + "require-dev": { + "drupal/coder": "^8.3.18", + "phpcompatibility/php-compatibility": "10.x-dev@dev" + }, "type": "drupal-module", "extra": { "drupal": { - "version": "8.x-1.1", - "datestamp": "1681757575", + "version": "8.x-1.2", + "datestamp": "1709383642", "security-coverage": { "status": "covered", "message": "Covered by Drupal's security advisory policy" @@ -6838,23 +6851,23 @@ }, { "name": "drush/drush", - "version": "12.4.3", + "version": "12.4.4", "source": { "type": "git", "url": "https://github.com/drush-ops/drush.git", - "reference": "8245acede57ecc62a90aa0f19ff3b29e5f11f971" + "reference": "a6585cddae47144413565f3c1cd29debc69f6b41" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/drush-ops/drush/zipball/8245acede57ecc62a90aa0f19ff3b29e5f11f971", - "reference": "8245acede57ecc62a90aa0f19ff3b29e5f11f971", + "url": "https://api.github.com/repos/drush-ops/drush/zipball/a6585cddae47144413565f3c1cd29debc69f6b41", + "reference": "a6585cddae47144413565f3c1cd29debc69f6b41", "shasum": "" }, "require": { "chi-teck/drupal-code-generator": "^3.0", "composer-runtime-api": "^2.2", "composer/semver": "^1.4 || ^3", - "consolidation/annotated-command": "^4.9.1", + "consolidation/annotated-command": "^4.9.2", "consolidation/config": "^2.1.2", "consolidation/filter-via-dot-access-data": "^2.0.2", "consolidation/output-formatters": "^4.3.2", @@ -6970,7 +6983,7 @@ "issues": "https://github.com/drush-ops/drush/issues", "security": "https://github.com/drush-ops/drush/security/advisories", "slack": "https://drupal.slack.com/messages/C62H9CWQM", - "source": "https://github.com/drush-ops/drush/tree/12.4.3" + "source": "https://github.com/drush-ops/drush/tree/12.4.4" }, "funding": [ { @@ -6978,7 +6991,7 @@ "type": "github" } ], - "time": "2023-11-16T22:57:24+00:00" + "time": "2024-03-02T12:14:56+00:00" }, { "name": "easyrdf/easyrdf", @@ -8660,16 +8673,16 @@ }, { "name": "mck89/peast", - "version": "v1.16.1", + "version": "v1.16.2", "source": { "type": "git", "url": "https://github.com/mck89/peast.git", - "reference": "f6e681062bb25c8dacbd30e079f4ad3fd890d7ad" + "reference": "2791b08ffcc1862fe18eef85675da3aa58c406fe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/mck89/peast/zipball/f6e681062bb25c8dacbd30e079f4ad3fd890d7ad", - "reference": "f6e681062bb25c8dacbd30e079f4ad3fd890d7ad", + "url": "https://api.github.com/repos/mck89/peast/zipball/2791b08ffcc1862fe18eef85675da3aa58c406fe", + "reference": "2791b08ffcc1862fe18eef85675da3aa58c406fe", "shasum": "" }, "require": { @@ -8682,7 +8695,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.16.1-dev" + "dev-master": "1.16.2-dev" } }, "autoload": { @@ -8703,9 +8716,9 @@ "description": "Peast is PHP library that generates AST for JavaScript code", "support": { "issues": "https://github.com/mck89/peast/issues", - "source": "https://github.com/mck89/peast/tree/v1.16.1" + "source": "https://github.com/mck89/peast/tree/v1.16.2" }, - "time": "2024-02-14T08:15:19+00:00" + "time": "2024-03-05T09:16:03+00:00" }, { "name": "microsoft/azure-storage-blob", @@ -8846,16 +8859,16 @@ }, { "name": "nikic/php-parser", - "version": "v5.0.1", + "version": "v5.0.2", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "2218c2252c874a4624ab2f613d86ac32d227bc69" + "reference": "139676794dc1e9231bf7bcd123cfc0c99182cb13" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/2218c2252c874a4624ab2f613d86ac32d227bc69", - "reference": "2218c2252c874a4624ab2f613d86ac32d227bc69", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/139676794dc1e9231bf7bcd123cfc0c99182cb13", + "reference": "139676794dc1e9231bf7bcd123cfc0c99182cb13", "shasum": "" }, "require": { @@ -8898,9 +8911,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v5.0.1" + "source": "https://github.com/nikic/PHP-Parser/tree/v5.0.2" }, - "time": "2024-02-21T19:24:10+00:00" + "time": "2024-03-05T20:51:40+00:00" }, { "name": "nodespark/des-connector", @@ -9152,16 +9165,16 @@ }, { "name": "pear/pear-core-minimal", - "version": "v1.10.14", + "version": "v1.10.15", "source": { "type": "git", "url": "https://github.com/pear/pear-core-minimal.git", - "reference": "a86fc145edb5caedbf96527214ce3cadc9de4a32" + "reference": "d457b5c93e5001fbf4b5726d21038266e029e3be" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/pear/pear-core-minimal/zipball/a86fc145edb5caedbf96527214ce3cadc9de4a32", - "reference": "a86fc145edb5caedbf96527214ce3cadc9de4a32", + "url": "https://api.github.com/repos/pear/pear-core-minimal/zipball/d457b5c93e5001fbf4b5726d21038266e029e3be", + "reference": "d457b5c93e5001fbf4b5726d21038266e029e3be", "shasum": "" }, "require": { @@ -9197,7 +9210,7 @@ "issues": "http://pear.php.net/bugs/search.php?cmd=display&package_name[]=PEAR", "source": "https://github.com/pear/pear-core-minimal" }, - "time": "2023-11-26T16:15:38+00:00" + "time": "2024-03-09T19:38:40+00:00" }, { "name": "pear/pear_exception", @@ -9515,30 +9528,30 @@ }, { "name": "phrity/util-errorhandler", - "version": "1.0.1", + "version": "1.1.0", "source": { "type": "git", "url": "https://github.com/sirn-se/phrity-util-errorhandler.git", - "reference": "dc9ac8fb70d733c48a9d9d1eb50f7022172da6bc" + "reference": "4016d9f9615a4c602f525b0542e4835e316a42e4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sirn-se/phrity-util-errorhandler/zipball/dc9ac8fb70d733c48a9d9d1eb50f7022172da6bc", - "reference": "dc9ac8fb70d733c48a9d9d1eb50f7022172da6bc", + "url": "https://api.github.com/repos/sirn-se/phrity-util-errorhandler/zipball/4016d9f9615a4c602f525b0542e4835e316a42e4", + "reference": "4016d9f9615a4c602f525b0542e4835e316a42e4", "shasum": "" }, "require": { - "php": "^7.2|^8.0" + "php": "^7.4 | ^8.0" }, "require-dev": { "php-coveralls/php-coveralls": "^2.0", - "phpunit/phpunit": "^8.0|^9.0", + "phpunit/phpunit": "^9.0 | ^10.0 | ^11.0", "squizlabs/php_codesniffer": "^3.5" }, "type": "library", "autoload": { "psr-4": { - "": "src/" + "Phrity\\Util\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -9560,9 +9573,9 @@ ], "support": { "issues": "https://github.com/sirn-se/phrity-util-errorhandler/issues", - "source": "https://github.com/sirn-se/phrity-util-errorhandler/tree/1.0.1" + "source": "https://github.com/sirn-se/phrity-util-errorhandler/tree/1.1.0" }, - "time": "2022-10-27T12:14:42+00:00" + "time": "2024-03-05T19:32:14+00:00" }, { "name": "psr/cache", @@ -10123,16 +10136,16 @@ }, { "name": "ruflin/elastica", - "version": "7.3.1", + "version": "7.3.2", "source": { "type": "git", "url": "https://github.com/ruflin/Elastica.git", - "reference": "7c61a630c3d456b00a5610960ae3a9bd29987469" + "reference": "84ba137678707a1aa4242d12bad891dc38fa2608" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ruflin/Elastica/zipball/7c61a630c3d456b00a5610960ae3a9bd29987469", - "reference": "7c61a630c3d456b00a5610960ae3a9bd29987469", + "url": "https://api.github.com/repos/ruflin/Elastica/zipball/84ba137678707a1aa4242d12bad891dc38fa2608", + "reference": "84ba137678707a1aa4242d12bad891dc38fa2608", "shasum": "" }, "require": { @@ -10186,22 +10199,22 @@ ], "support": { "issues": "https://github.com/ruflin/Elastica/issues", - "source": "https://github.com/ruflin/Elastica/tree/7.3.1" + "source": "https://github.com/ruflin/Elastica/tree/7.3.2" }, - "time": "2023-04-21T09:04:46+00:00" + "time": "2024-03-11T14:11:50+00:00" }, { "name": "sebastian/diff", - "version": "4.0.5", + "version": "4.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "74be17022044ebaaecfdf0c5cd504fc9cd5a7131" + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/74be17022044ebaaecfdf0c5cd504fc9cd5a7131", - "reference": "74be17022044ebaaecfdf0c5cd504fc9cd5a7131", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/ba01945089c3a293b01ba9badc29ad55b106b0bc", + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc", "shasum": "" }, "require": { @@ -10246,7 +10259,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/4.0.5" + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.6" }, "funding": [ { @@ -10254,7 +10267,7 @@ "type": "github" } ], - "time": "2023-05-07T05:35:17+00:00" + "time": "2024-03-02T06:30:58+00:00" }, { "name": "sentry/sentry", @@ -11097,16 +11110,16 @@ }, { "name": "symfony/http-kernel", - "version": "v6.4.4", + "version": "v6.4.5", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "7a186f64a7f02787c04e8476538624d6aa888e42" + "reference": "f6947cb939d8efee137797382cb4db1af653ef75" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/7a186f64a7f02787c04e8476538624d6aa888e42", - "reference": "7a186f64a7f02787c04e8476538624d6aa888e42", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/f6947cb939d8efee137797382cb4db1af653ef75", + "reference": "f6947cb939d8efee137797382cb4db1af653ef75", "shasum": "" }, "require": { @@ -11190,7 +11203,7 @@ "description": "Provides a structured process for converting a Request into a Response", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-kernel/tree/v6.4.4" + "source": "https://github.com/symfony/http-kernel/tree/v6.4.5" }, "funding": [ { @@ -11206,7 +11219,7 @@ "type": "tidelift" } ], - "time": "2024-02-27T06:32:13+00:00" + "time": "2024-03-04T21:00:47+00:00" }, { "name": "symfony/mailer", @@ -12449,16 +12462,16 @@ }, { "name": "symfony/routing", - "version": "v6.4.3", + "version": "v6.4.5", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "3b2957ad54902f0f544df83e3d58b38d7e8e5842" + "reference": "7fe30068e207d9c31c0138501ab40358eb2d49a4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/3b2957ad54902f0f544df83e3d58b38d7e8e5842", - "reference": "3b2957ad54902f0f544df83e3d58b38d7e8e5842", + "url": "https://api.github.com/repos/symfony/routing/zipball/7fe30068e207d9c31c0138501ab40358eb2d49a4", + "reference": "7fe30068e207d9c31c0138501ab40358eb2d49a4", "shasum": "" }, "require": { @@ -12512,7 +12525,7 @@ "url" ], "support": { - "source": "https://github.com/symfony/routing/tree/v6.4.3" + "source": "https://github.com/symfony/routing/tree/v6.4.5" }, "funding": [ { @@ -12528,7 +12541,7 @@ "type": "tidelift" } ], - "time": "2024-01-30T13:55:02+00:00" + "time": "2024-02-27T12:33:30+00:00" }, { "name": "symfony/serializer", diff --git a/conf/cmi/block.block.smarttichatbot.yml b/conf/cmi/block.block.smarttichatbot.yml deleted file mode 100644 index 70ea8c8e2..000000000 --- a/conf/cmi/block.block.smarttichatbot.yml +++ /dev/null @@ -1,33 +0,0 @@ -uuid: cbfb1e61-53cd-4939-94c1-d7f14c397c25 -langcode: en -status: true -dependencies: - module: - - helfi_platform_config - - language - - system - theme: - - hdbt -id: smarttichatbot -theme: hdbt -region: attachments -weight: -11 -provider: null -plugin: smartti_chatbot -settings: - id: smartti_chatbot - label: 'Smartti Chatbot' - label_display: '0' - provider: helfi_platform_config -visibility: - language: - id: language - negate: false - context_mapping: - language: '@language.current_language_context:language_content' - langcodes: - fi: fi - request_path: - id: request_path - negate: false - pages: "/pysakointi\r\n/pysakointi/*" diff --git a/conf/cmi/core.base_field_override.paragraphs_library_item.paragraphs_library_item.paragraphs.yml b/conf/cmi/core.base_field_override.paragraphs_library_item.paragraphs_library_item.paragraphs.yml index 2aff2b09b..acc7d009b 100644 --- a/conf/cmi/core.base_field_override.paragraphs_library_item.paragraphs_library_item.paragraphs.yml +++ b/conf/cmi/core.base_field_override.paragraphs_library_item.paragraphs_library_item.paragraphs.yml @@ -10,7 +10,6 @@ dependencies: - paragraphs.paragraphs_type.content_cards - paragraphs.paragraphs_type.content_liftup - paragraphs.paragraphs_type.district_and_project_search - - paragraphs.paragraphs_type.district_listing - paragraphs.paragraphs_type.image - paragraphs.paragraphs_type.liftup_with_image - paragraphs.paragraphs_type.list_of_links @@ -43,7 +42,6 @@ settings: handler_settings: target_bundles: district_and_project_search: district_and_project_search - district_listing: district_listing list_of_plans: list_of_plans accordion: accordion banner: banner @@ -82,9 +80,6 @@ settings: district_and_project_search: weight: 1 enabled: true - district_listing: - weight: 3 - enabled: true image: weight: 0 enabled: true diff --git a/conf/cmi/core.entity_form_display.node.page.default.yml b/conf/cmi/core.entity_form_display.node.page.default.yml index fb202cf63..15d1c46c1 100644 --- a/conf/cmi/core.entity_form_display.node.page.default.yml +++ b/conf/cmi/core.entity_form_display.node.page.default.yml @@ -21,7 +21,7 @@ dependencies: - publication_date - scheduler _core: - default_config_hash: _RX52hwdyz48o4MBqyRPUVkop-Unt1rcPuPanpQ7ksk + default_config_hash: IrTthHmbnCZxuMpndzRlr9-t2RT3szU18RcM_bpnrz0 id: node.page.default targetEntityType: node bundle: page @@ -79,10 +79,12 @@ content: duplicate: '0' third_party_settings: { } field_lead_in: - type: string_textarea + type: textarea_character_counter weight: 13 region: content settings: + counter_step: 160 + counter_total: 200 rows: 3 placeholder: '' third_party_settings: { } @@ -203,10 +205,12 @@ content: display_label: true third_party_settings: { } title: - type: string_textfield + type: textfield_character_counter weight: 1 region: content settings: + counter_step: 0 + counter_total: 55 size: 60 placeholder: '' third_party_settings: { } diff --git a/conf/cmi/core.entity_form_display.paragraph.district_listing.default.yml b/conf/cmi/core.entity_form_display.paragraph.district_listing.default.yml deleted file mode 100644 index d79117040..000000000 --- a/conf/cmi/core.entity_form_display.paragraph.district_listing.default.yml +++ /dev/null @@ -1,34 +0,0 @@ -uuid: 9ae551eb-55a0-4172-ab27-beba0f9e1cfe -langcode: en -status: true -dependencies: - config: - - field.field.paragraph.district_listing.field_district_list_description - - field.field.paragraph.district_listing.field_district_list_title - - paragraphs.paragraphs_type.district_listing - module: - - text -id: paragraph.district_listing.default -targetEntityType: paragraph -bundle: district_listing -mode: default -content: - field_district_list_description: - type: text_textarea - weight: 1 - region: content - settings: - rows: 5 - placeholder: '' - third_party_settings: { } - field_district_list_title: - type: string_textfield - weight: 0 - region: content - settings: - size: 60 - placeholder: '' - third_party_settings: { } -hidden: - created: true - status: true diff --git a/conf/cmi/core.entity_form_display.paragraph.event_list.default.yml b/conf/cmi/core.entity_form_display.paragraph.event_list.default.yml index 83ffb5c25..09afd2898 100644 --- a/conf/cmi/core.entity_form_display.paragraph.event_list.default.yml +++ b/conf/cmi/core.entity_form_display.paragraph.event_list.default.yml @@ -9,6 +9,7 @@ dependencies: - field.field.paragraph.event_list.field_event_list_title - field.field.paragraph.event_list.field_event_location - field.field.paragraph.event_list.field_event_time + - field.field.paragraph.event_list.field_filter_keywords - field.field.paragraph.event_list.field_free_events - field.field.paragraph.event_list.field_remote_events - paragraphs.paragraphs_type.event_list @@ -16,7 +17,7 @@ dependencies: - link - text _core: - default_config_hash: bGb0ZQ38-NxHtZ1rrdqclYHeStlwA5q3ucy5Wpnb0ng + default_config_hash: 26rzwNcMiiF5Bucl9iUliZYoL4vZcdmdNkYBAr9DYOU id: paragraph.event_list.default targetEntityType: paragraph bundle: event_list @@ -66,6 +67,16 @@ content: settings: display_label: true third_party_settings: { } + field_filter_keywords: + type: entity_reference_autocomplete_tags + weight: 8 + region: content + settings: + match_operator: CONTAINS + match_limit: 10 + size: 60 + placeholder: '' + third_party_settings: { } field_free_events: type: boolean_checkbox weight: 7 diff --git a/conf/cmi/core.entity_form_display.paragraph.hero.default.yml b/conf/cmi/core.entity_form_display.paragraph.hero.default.yml index 70cb6d337..ae5fc4dc3 100644 --- a/conf/cmi/core.entity_form_display.paragraph.hero.default.yml +++ b/conf/cmi/core.entity_form_display.paragraph.hero.default.yml @@ -11,24 +11,29 @@ dependencies: - field.field.paragraph.hero.field_hero_title - paragraphs.paragraphs_type.hero module: + - allowed_formats - hdbt_admin_tools - media_library - - text _core: - default_config_hash: CvDiqRtujItZjhiR7KUf0a9dQrlgEcmuDDhJHmzUNOw + default_config_hash: 1GjBs_T3tKYlTF4jxU6lUtwC7YSCChaZ4Tmsrialewk id: paragraph.hero.default targetEntityType: paragraph bundle: hero mode: default content: field_hero_desc: - type: text_textarea + type: formatted_text_character_counter weight: 3 region: content settings: + counter_step: 160 + counter_total: 200 rows: 5 placeholder: '' - third_party_settings: { } + third_party_settings: + allowed_formats: + hide_help: '0' + hide_guidelines: '0' field_hero_design: type: design_field_widget weight: 0 @@ -47,6 +52,8 @@ content: weight: 6 region: content settings: + placeholder_url: '' + placeholder_title: '' linkit_profile: helfi linkit_auto_link_text: false third_party_settings: { } @@ -57,10 +64,12 @@ content: settings: { } third_party_settings: { } field_hero_title: - type: string_textfield + type: textfield_character_counter weight: 2 region: content settings: + counter_step: 0 + counter_total: 55 size: 60 placeholder: '' third_party_settings: { } diff --git a/conf/cmi/core.entity_form_display.taxonomy_term.linked_events_keywords.default.yml b/conf/cmi/core.entity_form_display.taxonomy_term.linked_events_keywords.default.yml new file mode 100644 index 000000000..37b0a8c1f --- /dev/null +++ b/conf/cmi/core.entity_form_display.taxonomy_term.linked_events_keywords.default.yml @@ -0,0 +1,72 @@ +uuid: d3bdb49e-461c-4a0f-a88c-c34eb54f7101 +langcode: en +status: true +dependencies: + config: + - field.field.taxonomy_term.linked_events_keywords.field_keyword_id + - taxonomy.vocabulary.linked_events_keywords + module: + - hdbt_admin_tools + - path + - readonly_field_widget +_core: + default_config_hash: wrJ7qU6IE5H0AiZu6m8w7XCBXT-dqOntJPqFqR0iyU8 +id: taxonomy_term.linked_events_keywords.default +targetEntityType: taxonomy_term +bundle: linked_events_keywords +mode: default +content: + description: + type: formatted_text_character_counter + weight: 0 + region: content + settings: + counter_step: 160 + counter_total: 200 + rows: 5 + placeholder: '' + third_party_settings: { } + field_keyword_id: + type: readonly_field_widget + weight: 101 + region: content + settings: + label: above + formatter_type: null + formatter_settings: { } + show_description: false + third_party_settings: { } + langcode: + type: language_select + weight: 2 + region: content + settings: + include_locked: true + third_party_settings: { } + name: + type: string_textfield + weight: -5 + region: content + settings: + size: 60 + placeholder: '' + third_party_settings: { } + path: + type: path + weight: 30 + region: content + settings: { } + third_party_settings: { } + status: + type: boolean_checkbox + weight: 100 + region: content + settings: + display_label: true + third_party_settings: { } + translation: + weight: 10 + region: content + settings: { } + third_party_settings: { } +hidden: { } diff --git a/conf/cmi/core.entity_view_display.media.image.hero.yml b/conf/cmi/core.entity_view_display.media.image.hero.yml index 50cee82e4..2538f0432 100644 --- a/conf/cmi/core.entity_view_display.media.image.hero.yml +++ b/conf/cmi/core.entity_view_display.media.image.hero.yml @@ -11,7 +11,7 @@ dependencies: module: - responsive_image _core: - default_config_hash: UX2CrJYBdnGTpSaqiYid65d46ihnZEmWEBJbdXJZQ7g + default_config_hash: 1TRAhLvz-37rbjca1TJiVCP65Gy_X5ppn2iiiTRvl-g id: media.image.hero targetEntityType: media bundle: image diff --git a/conf/cmi/core.entity_view_display.paragraph.district_listing.default.yml b/conf/cmi/core.entity_view_display.paragraph.district_listing.default.yml deleted file mode 100644 index 712a3969b..000000000 --- a/conf/cmi/core.entity_view_display.paragraph.district_listing.default.yml +++ /dev/null @@ -1,32 +0,0 @@ -uuid: dbf7e281-d42d-4de4-b115-b77f9f9d5c8e -langcode: en -status: true -dependencies: - config: - - field.field.paragraph.district_listing.field_district_list_description - - field.field.paragraph.district_listing.field_district_list_title - - paragraphs.paragraphs_type.district_listing - module: - - text -id: paragraph.district_listing.default -targetEntityType: paragraph -bundle: district_listing -mode: default -content: - field_district_list_description: - type: text_default - label: hidden - settings: { } - third_party_settings: { } - weight: 1 - region: content - field_district_list_title: - type: string - label: hidden - settings: - link_to_entity: false - third_party_settings: { } - weight: 0 - region: content -hidden: - search_api_excerpt: true diff --git a/conf/cmi/core.entity_view_display.paragraph.event_list.default.yml b/conf/cmi/core.entity_view_display.paragraph.event_list.default.yml index 516fd2c4b..cc7654aaf 100644 --- a/conf/cmi/core.entity_view_display.paragraph.event_list.default.yml +++ b/conf/cmi/core.entity_view_display.paragraph.event_list.default.yml @@ -9,6 +9,7 @@ dependencies: - field.field.paragraph.event_list.field_event_list_title - field.field.paragraph.event_list.field_event_location - field.field.paragraph.event_list.field_event_time + - field.field.paragraph.event_list.field_filter_keywords - field.field.paragraph.event_list.field_free_events - field.field.paragraph.event_list.field_remote_events - paragraphs.paragraphs_type.event_list @@ -16,7 +17,7 @@ dependencies: - options - text _core: - default_config_hash: dMZ_8jKpOaA7CkuxlB2baa1apQcQ_vFlXM04jq4bqQY + default_config_hash: klW1qrhnmScBqsz4kDhFjtI4wmrMjLZynRsx9475Egs id: paragraph.event_list.default targetEntityType: paragraph bundle: event_list @@ -64,6 +65,14 @@ content: third_party_settings: { } weight: 3 region: content + field_filter_keywords: + type: entity_reference_label + label: above + settings: + link: true + third_party_settings: { } + weight: 6 + region: content field_free_events: type: boolean label: above diff --git a/conf/cmi/core.entity_view_display.taxonomy_term.linked_events_keywords.default.yml b/conf/cmi/core.entity_view_display.taxonomy_term.linked_events_keywords.default.yml new file mode 100644 index 000000000..968b3c939 --- /dev/null +++ b/conf/cmi/core.entity_view_display.taxonomy_term.linked_events_keywords.default.yml @@ -0,0 +1,27 @@ +uuid: 19cd3ce0-e5a8-4db8-ab50-ae7bde5fa981 +langcode: en +status: true +dependencies: + config: + - field.field.taxonomy_term.linked_events_keywords.field_keyword_id + - taxonomy.vocabulary.linked_events_keywords + module: + - text +_core: + default_config_hash: fBcG1sEoN3MYNH4WUM9M_e2jo304Kha_sUVu26s05ig +id: taxonomy_term.linked_events_keywords.default +targetEntityType: taxonomy_term +bundle: linked_events_keywords +mode: default +content: + description: + type: text_default + label: hidden + settings: { } + third_party_settings: { } + weight: 0 + region: content +hidden: + field_keyword_id: true + langcode: true + search_api_excerpt: true diff --git a/conf/cmi/core.entity_view_display.tpr_service_channel.tpr_service_channel.default.yml b/conf/cmi/core.entity_view_display.tpr_service_channel.tpr_service_channel.default.yml index abe4ae742..3958ca9f4 100644 --- a/conf/cmi/core.entity_view_display.tpr_service_channel.tpr_service_channel.default.yml +++ b/conf/cmi/core.entity_view_display.tpr_service_channel.tpr_service_channel.default.yml @@ -9,7 +9,7 @@ dependencies: - telephone - text _core: - default_config_hash: i0i5Sy5UJYyKJqoc7NKFbAMaMlXpC53GoO7Z3mahaBE + default_config_hash: NC4qX-7naY7U9PAcLK80wAYby0wkk8T8ZuqKK2_fRd0 id: tpr_service_channel.tpr_service_channel.default targetEntityType: tpr_service_channel bundle: tpr_service_channel @@ -106,6 +106,13 @@ content: third_party_settings: { } weight: 22 region: content + information: + type: text_default + label: hidden + settings: { } + third_party_settings: { } + weight: 4 + region: content langcode: type: language label: hidden diff --git a/conf/cmi/core.entity_view_mode.media.hero.yml b/conf/cmi/core.entity_view_mode.media.hero.yml index f43cccf3f..a8c1a0b5e 100644 --- a/conf/cmi/core.entity_view_mode.media.hero.yml +++ b/conf/cmi/core.entity_view_mode.media.hero.yml @@ -5,7 +5,7 @@ dependencies: module: - media _core: - default_config_hash: XHi0bUTi0UQU5CFI90xrtRS1tLLlwUSrMhNft4fY_XA + default_config_hash: zAj-eiOJoImMZ2MAmC2k7HFfOKvT0JA_aHDz6RaN2uQ id: media.hero label: Hero description: '' diff --git a/conf/cmi/eu_cookie_compliance.settings.yml b/conf/cmi/eu_cookie_compliance.settings.yml index 5a34e5fe4..2f1d21d09 100644 --- a/conf/cmi/eu_cookie_compliance.settings.yml +++ b/conf/cmi/eu_cookie_compliance.settings.yml @@ -59,7 +59,7 @@ better_support_for_screen_readers: false method: categories disabled_javascripts: '' automatic_cookies_removal: true -allowed_cookies: "essential:AWSELBCORS\r\nessential:cookiehub\r\nessential:mtm_cookie_consent\r\nessential:JSESSIONID\r\nessential:COOKIE_SUPPORT\r\nessential:GUEST_LANGUAGE_ID\r\npreference:httpskartta.hel.fi.SWCulture\r\npreference:icareus-device\r\npreference:VISITOR_INFO1_LIVE\r\npreference:CONSENT\r\nstatistics:nmstat\r\nstatistics:_pk_id.*\r\nstatistics:_pk_ses.141.89f6\r\nstatistics:_pk_id.*\r\nstatistics:_pk_ses.*\r\nstatistics:_pk_id.*\r\nstatistics:_pk_ses.*\r\nstatistics:rnsbid\r\nstatistics:rnsbid_ts\r\nstatistics:rns_reaction_*\r\nstatistics:YSC\r\nchat:_genesys.widgets.*\r\nchat:leijuke.*" +allowed_cookies: "helfi_accordions_open\r\nessential:AWSELBCORS\r\nessential:cookiehub\r\nessential:mtm_cookie_consent\r\nessential:JSESSIONID\r\nessential:COOKIE_SUPPORT\r\nessential:GUEST_LANGUAGE_ID\r\npreference:httpskartta.hel.fi.SWCulture\r\npreference:icareus-device\r\npreference:VISITOR_INFO1_LIVE\r\npreference:CONSENT\r\nstatistics:nmstat\r\nstatistics:_pk_id.*\r\nstatistics:_pk_ses.141.89f6\r\nstatistics:_pk_id.*\r\nstatistics:_pk_ses.*\r\nstatistics:_pk_id.*\r\nstatistics:_pk_ses.*\r\nstatistics:rnsbid\r\nstatistics:rnsbid_ts\r\nstatistics:rns_reaction_*\r\nstatistics:YSC\r\nchat:_genesys.widgets.*\r\nchat:leijuke.*" consent_storage_method: do_not_store withdraw_message: value: '

Hel.fi uses cookies

You have given your consent for us to set cookies.

' diff --git a/conf/cmi/field.field.node.district.field_hero.yml b/conf/cmi/field.field.node.district.field_hero.yml index e3cf058b1..f8a9b3040 100644 --- a/conf/cmi/field.field.node.district.field_hero.yml +++ b/conf/cmi/field.field.node.district.field_hero.yml @@ -55,9 +55,6 @@ settings: district_and_project_search: weight: 46 enabled: false - district_listing: - weight: 47 - enabled: false event_list: weight: 39 enabled: false diff --git a/conf/cmi/field.field.node.district.field_lower_content.yml b/conf/cmi/field.field.node.district.field_lower_content.yml index 0f0e9cce6..e08d97e90 100644 --- a/conf/cmi/field.field.node.district.field_lower_content.yml +++ b/conf/cmi/field.field.node.district.field_lower_content.yml @@ -55,9 +55,6 @@ settings: district_and_project_search: weight: -48 enabled: false - district_listing: - weight: -45 - enabled: false event_list: weight: -55 enabled: false diff --git a/conf/cmi/field.field.node.landing_page.field_content.yml b/conf/cmi/field.field.node.landing_page.field_content.yml index cf5f5fece..0e85f53e9 100644 --- a/conf/cmi/field.field.node.landing_page.field_content.yml +++ b/conf/cmi/field.field.node.landing_page.field_content.yml @@ -11,7 +11,6 @@ dependencies: - paragraphs.paragraphs_type.content_cards - paragraphs.paragraphs_type.content_liftup - paragraphs.paragraphs_type.district_and_project_search - - paragraphs.paragraphs_type.district_listing - paragraphs.paragraphs_type.event_list - paragraphs.paragraphs_type.from_library - paragraphs.paragraphs_type.hearings @@ -46,7 +45,6 @@ settings: handler_settings: target_bundles: district_and_project_search: district_and_project_search - district_listing: district_listing list_of_plans: list_of_plans columns: columns list_of_links: list_of_links @@ -87,9 +85,6 @@ settings: district_and_project_search: weight: 18 enabled: true - district_listing: - weight: 20 - enabled: true event_list: weight: 13 enabled: true diff --git a/conf/cmi/field.field.node.page.field_content.yml b/conf/cmi/field.field.node.page.field_content.yml index cb0c54762..4ec7edd1e 100644 --- a/conf/cmi/field.field.node.page.field_content.yml +++ b/conf/cmi/field.field.node.page.field_content.yml @@ -14,6 +14,7 @@ dependencies: - paragraphs.paragraphs_type.content_liftup - paragraphs.paragraphs_type.event_list - paragraphs.paragraphs_type.from_library + - paragraphs.paragraphs_type.hearings - paragraphs.paragraphs_type.image - paragraphs.paragraphs_type.journey_planner - paragraphs.paragraphs_type.list_of_links @@ -44,27 +45,28 @@ settings: handler: 'default:paragraph' handler_settings: target_bundles: - list_of_plans: list_of_plans + hearings: hearings journey_planner: journey_planner + list_of_plans: list_of_plans + ploughing_schedule: ploughing_schedule text: text - columns: columns - image: image accordion: accordion + banner: banner + image: image list_of_links: list_of_links - contact_card_listing: contact_card_listing content_cards: content_cards - content_liftup: content_liftup - banner: banner - event_list: event_list - news_list: news_list - from_library: from_library + columns: columns phasing: phasing - chart: chart - remote_video: remote_video + from_library: from_library map: map - unit_search: unit_search + remote_video: remote_video + chart: chart + event_list: event_list + contact_card_listing: contact_card_listing + news_list: news_list + content_liftup: content_liftup service_list_search: service_list_search - ploughing_schedule: ploughing_schedule + unit_search: unit_search negate: 0 target_bundles_drag_drop: accordion: @@ -94,17 +96,20 @@ settings: from_library: weight: 8 enabled: true + hearings: + weight: 18 + enabled: true image: weight: 3 enabled: true journey_planner: - weight: 18 + weight: 19 enabled: true list_of_links: weight: 4 enabled: true list_of_plans: - weight: 19 + weight: 20 enabled: true map: weight: 9 @@ -116,7 +121,7 @@ settings: weight: 7 enabled: true ploughing_schedule: - weight: 20 + weight: 21 enabled: true remote_video: weight: 10 diff --git a/conf/cmi/field.field.node.page.field_lower_content.yml b/conf/cmi/field.field.node.page.field_lower_content.yml index 17f559233..fd3da508f 100644 --- a/conf/cmi/field.field.node.page.field_lower_content.yml +++ b/conf/cmi/field.field.node.page.field_lower_content.yml @@ -43,24 +43,24 @@ settings: handler_settings: target_bundles: list_of_plans: list_of_plans - text: text - columns: columns - image: image - accordion: accordion list_of_links: list_of_links - contact_card_listing: contact_card_listing content_cards: content_cards - content_liftup: content_liftup + text: text + accordion: accordion banner: banner - event_list: event_list - news_list: news_list - from_library: from_library - chart: chart + image: image + columns: columns phasing: phasing - remote_video: remote_video + from_library: from_library map: map - unit_search: unit_search + remote_video: remote_video + chart: chart + event_list: event_list + contact_card_listing: contact_card_listing + news_list: news_list + content_liftup: content_liftup service_list_search: service_list_search + unit_search: unit_search negate: 0 target_bundles_drag_drop: accordion: diff --git a/conf/cmi/field.field.node.page.field_sidebar_content.yml b/conf/cmi/field.field.node.page.field_sidebar_content.yml index 1f52ad208..bf8b71f35 100644 --- a/conf/cmi/field.field.node.page.field_sidebar_content.yml +++ b/conf/cmi/field.field.node.page.field_sidebar_content.yml @@ -25,8 +25,8 @@ settings: handler: 'default:paragraph' handler_settings: target_bundles: - sidebar_text: sidebar_text from_library: from_library + sidebar_text: sidebar_text negate: 0 target_bundles_drag_drop: from_library: diff --git a/conf/cmi/field.field.node.project.field_lower_content.yml b/conf/cmi/field.field.node.project.field_lower_content.yml index c688b1e92..3c60a4513 100644 --- a/conf/cmi/field.field.node.project.field_lower_content.yml +++ b/conf/cmi/field.field.node.project.field_lower_content.yml @@ -55,9 +55,6 @@ settings: district_and_project_search: weight: -48 enabled: false - district_listing: - weight: -45 - enabled: false event_list: weight: -55 enabled: false diff --git a/conf/cmi/field.field.paragraph.district_listing.field_district_list_description.yml b/conf/cmi/field.field.paragraph.district_listing.field_district_list_description.yml deleted file mode 100644 index 92ccea09d..000000000 --- a/conf/cmi/field.field.paragraph.district_listing.field_district_list_description.yml +++ /dev/null @@ -1,27 +0,0 @@ -uuid: 49503511-881e-49f8-acef-d0d131fff3f7 -langcode: en -status: true -dependencies: - config: - - field.storage.paragraph.field_district_list_description - - paragraphs.paragraphs_type.district_listing - module: - - allowed_formats - - text -third_party_settings: - allowed_formats: - allowed_formats: - - minimal -id: paragraph.district_listing.field_district_list_description -field_name: field_district_list_description -entity_type: paragraph -bundle: district_listing -label: Description -description: '' -required: false -translatable: false -default_value: { } -default_value_callback: '' -settings: - allowed_formats: { } -field_type: text_long diff --git a/conf/cmi/field.field.paragraph.district_listing.field_district_list_title.yml b/conf/cmi/field.field.paragraph.district_listing.field_district_list_title.yml deleted file mode 100644 index ea7f50677..000000000 --- a/conf/cmi/field.field.paragraph.district_listing.field_district_list_title.yml +++ /dev/null @@ -1,19 +0,0 @@ -uuid: 0025133a-56f0-49b0-8b87-fb4011d1d452 -langcode: en -status: true -dependencies: - config: - - field.storage.paragraph.field_district_list_title - - paragraphs.paragraphs_type.district_listing -id: paragraph.district_listing.field_district_list_title -field_name: field_district_list_title -entity_type: paragraph -bundle: district_listing -label: Title -description: '' -required: true -translatable: false -default_value: { } -default_value_callback: '' -settings: { } -field_type: string diff --git a/conf/cmi/field.field.paragraph.event_list.field_api_url.yml b/conf/cmi/field.field.paragraph.event_list.field_api_url.yml index ad6231c70..45b017ea5 100644 --- a/conf/cmi/field.field.paragraph.event_list.field_api_url.yml +++ b/conf/cmi/field.field.paragraph.event_list.field_api_url.yml @@ -8,13 +8,13 @@ dependencies: module: - link _core: - default_config_hash: Y-6hGxIpid7_ScRXE2GozslolF7R3tkTNiJFFaLEw4Y + default_config_hash: qFl3v-buWHh5wpZVM1bBbrLFD8prLGRuI8-zz1PX_sA id: paragraph.event_list.field_api_url field_name: field_api_url entity_type: paragraph bundle: event_list label: 'Api URL' -description: 'Add URL from tapahtumat.hel.fi to form a list of events. Example URL: https://tapahtumat.hel.fi/fi/events?categories=museum' +description: 'Add URL from tapahtumat.hel.fi to form a list of events. Example URL: https://tapahtumat.hel.fi/fi/events?categories=museum. If you want to use the location filter, the URL should contain the IDs of all relevant locations. For example: &places=tprek:123,tprek:456' required: false translatable: false default_value: { } diff --git a/conf/cmi/field.field.paragraph.event_list.field_event_location.yml b/conf/cmi/field.field.paragraph.event_list.field_event_location.yml index 3673a6bcc..ba30703c6 100644 --- a/conf/cmi/field.field.paragraph.event_list.field_event_location.yml +++ b/conf/cmi/field.field.paragraph.event_list.field_event_location.yml @@ -6,13 +6,13 @@ dependencies: - field.storage.paragraph.field_event_location - paragraphs.paragraphs_type.event_list _core: - default_config_hash: qn_ofDevCfu_ZKP8n6kRAQFTmy0cRAXNJUvxS6mU-6Q + default_config_hash: DSXkHRCUYDva2angAe8mEVxY95-9mh8B_oOd_9i-1I0 id: paragraph.event_list.field_event_location field_name: field_event_location entity_type: paragraph bundle: event_list label: 'Event location' -description: 'Show "event location" filter. Do not use at the same time with the "Remote events" filter.' +description: 'Show "event location" filter. Do not use at the same time with the "Remote events" filter. The API URL field should include all location IDs, otherwise this list will display all active locations.' required: false translatable: false default_value: diff --git a/conf/cmi/field.field.paragraph.event_list.field_filter_keywords.yml b/conf/cmi/field.field.paragraph.event_list.field_filter_keywords.yml new file mode 100644 index 000000000..65279cf38 --- /dev/null +++ b/conf/cmi/field.field.paragraph.event_list.field_filter_keywords.yml @@ -0,0 +1,31 @@ +uuid: 05609557-0317-49a6-b2dd-1e7a2e69c10b +langcode: en +status: true +dependencies: + config: + - field.storage.paragraph.field_filter_keywords + - paragraphs.paragraphs_type.event_list + - taxonomy.vocabulary.linked_events_keywords +_core: + default_config_hash: zOO1RpDPCcNOWimUEMWLWWTZGDfOxr1BadD0vxMwZl8 +id: paragraph.event_list.field_filter_keywords +field_name: field_filter_keywords +entity_type: paragraph +bundle: event_list +label: Topics +description: 'Select options for "filter by topic" filter. The filter is hidden if no keywords are selected.' +required: false +translatable: false +default_value: { } +default_value_callback: '' +settings: + handler: 'default:taxonomy_term' + handler_settings: + target_bundles: + linked_events_keywords: linked_events_keywords + sort: + field: name + direction: asc + auto_create: false + auto_create_bundle: '' +field_type: entity_reference diff --git a/conf/cmi/field.field.paragraph.hero.field_hero_desc.yml b/conf/cmi/field.field.paragraph.hero.field_hero_desc.yml index aa6b82cc3..8a3269c3c 100644 --- a/conf/cmi/field.field.paragraph.hero.field_hero_desc.yml +++ b/conf/cmi/field.field.paragraph.hero.field_hero_desc.yml @@ -12,7 +12,7 @@ third_party_settings: allowed_formats: allowed_formats: { } _core: - default_config_hash: 8R816KbWZKNUvPgCHKY1nRR0RRNTUOhsmU9s2eQCy-c + default_config_hash: cwwrLHDaOq3Y_x5EhOnPYng3P2Qpk-AZNL5Zo6DZn20 id: paragraph.hero.field_hero_desc field_name: field_hero_desc entity_type: paragraph diff --git a/conf/cmi/field.field.taxonomy_term.linked_events_keywords.field_keyword_id.yml b/conf/cmi/field.field.taxonomy_term.linked_events_keywords.field_keyword_id.yml new file mode 100644 index 000000000..3c5d8bda2 --- /dev/null +++ b/conf/cmi/field.field.taxonomy_term.linked_events_keywords.field_keyword_id.yml @@ -0,0 +1,21 @@ +uuid: f04d1d15-8a22-440d-aa3f-1af424df9124 +langcode: en +status: true +dependencies: + config: + - field.storage.taxonomy_term.field_keyword_id + - taxonomy.vocabulary.linked_events_keywords +_core: + default_config_hash: VHWaAjAYzxCy2U7_c3Vc3MAfurLC2QCPAimZVamsAuU +id: taxonomy_term.linked_events_keywords.field_keyword_id +field_name: field_keyword_id +entity_type: taxonomy_term +bundle: linked_events_keywords +label: 'Keyword ID' +description: 'Linked events keyword id.' +required: true +translatable: false +default_value: { } +default_value_callback: '' +settings: { } +field_type: string diff --git a/conf/cmi/field.storage.paragraph.field_district_list_description.yml b/conf/cmi/field.storage.paragraph.field_district_list_description.yml deleted file mode 100644 index d3fe9c432..000000000 --- a/conf/cmi/field.storage.paragraph.field_district_list_description.yml +++ /dev/null @@ -1,19 +0,0 @@ -uuid: 9848dbaf-184b-4c12-a771-009db7896b35 -langcode: en -status: true -dependencies: - module: - - paragraphs - - text -id: paragraph.field_district_list_description -field_name: field_district_list_description -entity_type: paragraph -type: text_long -settings: { } -module: text -locked: false -cardinality: 1 -translatable: true -indexes: { } -persist_with_no_fields: false -custom_storage: false diff --git a/conf/cmi/field.storage.paragraph.field_filter_keywords.yml b/conf/cmi/field.storage.paragraph.field_filter_keywords.yml new file mode 100644 index 000000000..05ad130e6 --- /dev/null +++ b/conf/cmi/field.storage.paragraph.field_filter_keywords.yml @@ -0,0 +1,22 @@ +uuid: 2950aba3-734a-4bd3-9791-775aceae8e5e +langcode: en +status: true +dependencies: + module: + - paragraphs + - taxonomy +_core: + default_config_hash: p5gLAIXKUuxZdeUFP1juUwV9fUPwzJ7uRLik5wOAK6Y +id: paragraph.field_filter_keywords +field_name: field_filter_keywords +entity_type: paragraph +type: entity_reference +settings: + target_type: taxonomy_term +module: core +locked: false +cardinality: -1 +translatable: true +indexes: { } +persist_with_no_fields: false +custom_storage: false diff --git a/conf/cmi/field.storage.paragraph.field_hero_design.yml b/conf/cmi/field.storage.paragraph.field_hero_design.yml index 9c28c89cc..3f76c7d64 100644 --- a/conf/cmi/field.storage.paragraph.field_hero_design.yml +++ b/conf/cmi/field.storage.paragraph.field_hero_design.yml @@ -6,28 +6,13 @@ dependencies: - options - paragraphs _core: - default_config_hash: zZ661kERU722BOWyFdnw3UIzhMePsDzfGXd2TsHAJYc + default_config_hash: KXFi1Afbypvb78pxWyzXeA3ha5otHESFK39t-DuF16Q id: paragraph.field_hero_design field_name: field_hero_design entity_type: paragraph type: list_string settings: - allowed_values: - - - value: without-image-left - label: 'Without image, align left' - - - value: with-image-right - label: 'Image on the right' - - - value: with-image-left - label: 'Image on the left' - - - value: with-image-bottom - label: 'Image on the bottom' - - - value: diagonal - label: Diagonal + allowed_values: { } allowed_values_function: helfi_paragraphs_hero_design_allowed_values module: options locked: false diff --git a/conf/cmi/field.storage.paragraph.field_district_list_title.yml b/conf/cmi/field.storage.taxonomy_term.field_keyword_id.yml similarity index 53% rename from conf/cmi/field.storage.paragraph.field_district_list_title.yml rename to conf/cmi/field.storage.taxonomy_term.field_keyword_id.yml index 7fb1d7540..c4f0a47ed 100644 --- a/conf/cmi/field.storage.paragraph.field_district_list_title.yml +++ b/conf/cmi/field.storage.taxonomy_term.field_keyword_id.yml @@ -1,12 +1,14 @@ -uuid: 260205c1-0911-4916-8492-812a5d5af385 +uuid: 8c76f060-07d3-4c16-b305-cc4ade3105a9 langcode: en status: true dependencies: module: - - paragraphs -id: paragraph.field_district_list_title -field_name: field_district_list_title -entity_type: paragraph + - taxonomy +_core: + default_config_hash: 7xItqwaMwhMih7aOv7ihiQx1wvkRGKrWiRJLJnM3RYA +id: taxonomy_term.field_keyword_id +field_name: field_keyword_id +entity_type: taxonomy_term type: string settings: max_length: 255 diff --git a/conf/cmi/language/fi/field.field.paragraph.event_list.field_api_url.yml b/conf/cmi/language/fi/field.field.paragraph.event_list.field_api_url.yml index 84bd65316..1eab9886f 100644 --- a/conf/cmi/language/fi/field.field.paragraph.event_list.field_api_url.yml +++ b/conf/cmi/language/fi/field.field.paragraph.event_list.field_api_url.yml @@ -1 +1 @@ -description: 'Tapahtumat.hel.fi-osoite, jonka perusteella listaus muodostetaan.' +description: 'Tapahtumat.hel.fi-osoite, jonka perusteella listaus muodostetaan. Esimerkki: https://tapahtumat.hel.fi/fi/events?categories=museum. Jos haluat käyttää tapahtumapaikka-suodatinta, URLissa tulee olla mukana tapahtumapaikkojen ID:t. Esim: &places=tprek:123,tprek:456' diff --git a/conf/cmi/language/fi/field.field.paragraph.event_list.field_event_location.yml b/conf/cmi/language/fi/field.field.paragraph.event_list.field_event_location.yml index 5808b45f8..aa1604470 100644 --- a/conf/cmi/language/fi/field.field.paragraph.event_list.field_event_location.yml +++ b/conf/cmi/language/fi/field.field.paragraph.event_list.field_event_location.yml @@ -1,5 +1,5 @@ label: Tapahtumapaikka -description: 'Näytä "tapahtumapaikka" -suodatin. Älä käytä yhtä aikaa "Etätapahtumat" -suodattimen kanssa.' +description: 'Näytä "tapahtumapaikka" -suodatin. Älä käytä yhtä aikaa "Etätapahtumat" -suodattimen kanssa. API URL kentässä tulee olla tapahtumapaikkojen ID:t mukana, muuten listassa näytetään kaikki aktiiviset tapahtumapaikat.' settings: on_label: Kyllä off_label: Ei diff --git a/conf/cmi/language/fi/field.field.paragraph.event_list.field_filter_keywords.yml b/conf/cmi/language/fi/field.field.paragraph.event_list.field_filter_keywords.yml new file mode 100644 index 000000000..048db90cf --- /dev/null +++ b/conf/cmi/language/fi/field.field.paragraph.event_list.field_filter_keywords.yml @@ -0,0 +1,2 @@ +label: Asiasanat +description: 'Valitse "suodata asiasanoilla" -suodattimen vaihtoehdot. Suodatinta ei näytetä jos ainuttakaan asiasanaa ei ole valittu.' diff --git a/conf/cmi/language/fi/field.storage.paragraph.field_hero_design.yml b/conf/cmi/language/fi/field.storage.paragraph.field_hero_design.yml deleted file mode 100644 index 7e625c9ce..000000000 --- a/conf/cmi/language/fi/field.storage.paragraph.field_hero_design.yml +++ /dev/null @@ -1,12 +0,0 @@ -settings: - allowed_values: - - - label: 'Ilman kuvaa, tasattu vasemmalle' - - - label: 'Kuva oikealla' - - - label: 'Kuva vasemmalla' - - - label: 'Kuva alhaalla' - - - label: Diagonaalinen diff --git a/conf/cmi/language/fi/paragraphs.paragraphs_type.district_listing.yml b/conf/cmi/language/fi/paragraphs.paragraphs_type.district_listing.yml deleted file mode 100644 index a5d781316..000000000 --- a/conf/cmi/language/fi/paragraphs.paragraphs_type.district_listing.yml +++ /dev/null @@ -1,2 +0,0 @@ -label: Aluelistaus -description: 'Listaa kaikki sivustolle lisätyt, julkaistut alueet.' diff --git a/conf/cmi/language/fi/social_media.settings.yml b/conf/cmi/language/fi/social_media.settings.yml index d2707e46e..370101b82 100644 --- a/conf/cmi/language/fi/social_media.settings.yml +++ b/conf/cmi/language/fi/social_media.settings.yml @@ -3,6 +3,7 @@ social_media: text: 'Jaa Facebook-palvelussa' linkedin: text: 'Jaa LinkedIn-palvelussa' + api_url: 'https://www.linkedin.com/sharing/share-offsite/?url=[current-page:url]' twitter: text: 'Jaa Twitter-palvelussa' email: diff --git a/conf/cmi/language/fi/views.view.district_listing.yml b/conf/cmi/language/fi/views.view.district_listing.yml deleted file mode 100644 index d59ab594d..000000000 --- a/conf/cmi/language/fi/views.view.district_listing.yml +++ /dev/null @@ -1,28 +0,0 @@ -label: Aluelistaus -display: - default: - display_title: Oletus - display_options: - title: Aluelistaus - pager: - options: - tags: - next: Seuraava - previous: Edellinen - first: Ensimmäinen - last: Viimeinen - expose: - items_per_page_label: 'Kohteita per sivu' - items_per_page_options_all_label: '- Kaikki -' - exposed_form: - options: - submit_button: Hae - reset_button_label: Palauta - exposed_sorts_label: Järjestä - sort_asc_label: Nouseva - sort_desc_label: Laskeva - header: - result: - content: '
@total aluetta
' - district_listing: - display_title: Lohko diff --git a/conf/cmi/language/sv/field.storage.paragraph.field_hero_design.yml b/conf/cmi/language/sv/field.storage.paragraph.field_hero_design.yml deleted file mode 100644 index 5c5f4ec15..000000000 --- a/conf/cmi/language/sv/field.storage.paragraph.field_hero_design.yml +++ /dev/null @@ -1,12 +0,0 @@ -settings: - allowed_values: - - - label: 'Utan bild, justerad vänster' - - - label: 'Bild justerad till höger' - - - label: 'Bild justerad till vänster' - - - label: 'Bild justerad ner' - - - label: Diagonal diff --git a/conf/cmi/language/sv/paragraphs.paragraphs_type.district_listing.yml b/conf/cmi/language/sv/paragraphs.paragraphs_type.district_listing.yml deleted file mode 100644 index 63372d42b..000000000 --- a/conf/cmi/language/sv/paragraphs.paragraphs_type.district_listing.yml +++ /dev/null @@ -1,2 +0,0 @@ -label: Områdelistning -description: 'Listar alla publicerade områden som har lagts till på webbplatsen.' diff --git a/conf/cmi/language/sv/views.view.district_listing.yml b/conf/cmi/language/sv/views.view.district_listing.yml deleted file mode 100644 index 8dd7d3710..000000000 --- a/conf/cmi/language/sv/views.view.district_listing.yml +++ /dev/null @@ -1,26 +0,0 @@ -label: Områdelistning -display: - default: - display_title: Standard - display_options: - title: Områdelistning - pager: - options: - tags: - next: Nästa - previous: Föregående - first: Första - last: Sista - expose: - items_per_page_label: 'Objekt per sida' - items_per_page_options_all_label: '- Alla -' - exposed_form: - options: - submit_button: Använda - reset_button_label: Återställa - exposed_sorts_label: 'Sortera på' - sort_asc_label: Stigande - sort_desc_label: Fallande - header: - result: - content: '
@total områden
' diff --git a/conf/cmi/paragraphs.paragraphs_type.district_listing.yml b/conf/cmi/paragraphs.paragraphs_type.district_listing.yml deleted file mode 100644 index dc08bee26..000000000 --- a/conf/cmi/paragraphs.paragraphs_type.district_listing.yml +++ /dev/null @@ -1,10 +0,0 @@ -uuid: 282598b4-187d-405b-8c6f-26944bd2f246 -langcode: en -status: true -dependencies: { } -id: district_listing -label: 'District listing' -icon_uuid: null -icon_default: null -description: 'Lists all published districts that have been added to the site.' -behavior_plugins: { } diff --git a/conf/cmi/social_media.settings.yml b/conf/cmi/social_media.settings.yml index b2e1fcd8d..358c7a768 100644 --- a/conf/cmi/social_media.settings.yml +++ b/conf/cmi/social_media.settings.yml @@ -27,7 +27,7 @@ social_media: linkedin: enable: 1 text: 'Share in Linkedin' - api_url: 'http://www.linkedin.com/shareArticle?mini=true&url=[current-page:url]&title=[current-page:title]&source=[current-page:url]' + api_url: 'https://www.linkedin.com/sharing/share-offsite/?url=[current-page:url]' api_event: href default_img: 0 weight: 3 diff --git a/conf/cmi/taxonomy.vocabulary.linked_events_keywords.yml b/conf/cmi/taxonomy.vocabulary.linked_events_keywords.yml new file mode 100644 index 000000000..6b0b8609f --- /dev/null +++ b/conf/cmi/taxonomy.vocabulary.linked_events_keywords.yml @@ -0,0 +1,10 @@ +uuid: 757cd796-00f7-445a-907d-0977ffe099be +langcode: en +status: true +dependencies: { } +_core: + default_config_hash: e0eqaMehV63Hmtfc20QLyE7IGXuwqhSMNZg9hLgizfM +name: 'Linked Events Keywords' +vid: linked_events_keywords +description: 'Keywords from yso dataset.' +weight: 0 diff --git a/conf/cmi/views.view.district_listing.yml b/conf/cmi/views.view.district_listing.yml deleted file mode 100644 index c0d61a23a..000000000 --- a/conf/cmi/views.view.district_listing.yml +++ /dev/null @@ -1,212 +0,0 @@ -uuid: 2eec0d1a-18ea-45d5-8797-ed06c89e2103 -langcode: en -status: true -dependencies: - config: - - core.entity_view_mode.node.teaser - - node.type.district - module: - - node - - user -id: district_listing -label: 'District listing' -module: views -description: '' -tag: '' -base_table: node_field_data -base_field: nid -display: - default: - id: default - display_title: Default - display_plugin: default - position: 0 - display_options: - title: 'District listing' - fields: - title: - id: title - table: node_field_data - field: title - relationship: none - group_type: group - admin_label: '' - entity_type: node - entity_field: title - plugin_id: field - label: '' - exclude: false - alter: - alter_text: false - make_link: false - absolute: false - word_boundary: false - ellipsis: false - strip_tags: false - trim: false - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - click_sort_column: value - type: string - settings: - link_to_entity: true - group_column: value - group_columns: { } - group_rows: true - delta_limit: 0 - delta_offset: 0 - delta_reversed: false - delta_first_last: false - multi_type: separator - separator: ', ' - field_api_classes: false - pager: - type: full - options: - offset: 0 - items_per_page: 10 - total_pages: null - id: 0 - tags: - next: Next - previous: Previous - first: First - last: Last - expose: - items_per_page: false - items_per_page_label: 'Items per page' - items_per_page_options: '5, 10, 25, 50' - items_per_page_options_all: false - items_per_page_options_all_label: '- All -' - offset: false - offset_label: Offset - quantity: 9 - exposed_form: - type: basic - options: - submit_button: Apply - reset_button: false - reset_button_label: Reset - exposed_sorts_label: 'Sort by' - expose_sort_order: true - sort_asc_label: Asc - sort_desc_label: Desc - access: - type: perm - options: - perm: 'access content' - cache: - type: tag - options: { } - empty: { } - sorts: - title: - id: title - table: node_field_data - field: title - relationship: none - group_type: group - admin_label: '' - entity_type: node - entity_field: title - plugin_id: standard - order: ASC - expose: - label: '' - field_identifier: '' - exposed: false - arguments: { } - filters: - status: - id: status - table: node_field_data - field: status - entity_type: node - entity_field: status - plugin_id: boolean - value: '1' - group: 1 - expose: - operator: '' - operator_limit_selection: false - operator_list: { } - type: - id: type - table: node_field_data - field: type - entity_type: node - entity_field: type - plugin_id: bundle - value: - district: district - expose: - operator_limit_selection: false - operator_list: { } - style: - type: default - row: - type: 'entity:node' - options: - view_mode: teaser - query: - type: views_query - options: - query_comment: '' - disable_sql_rewrite: false - distinct: false - replica: false - query_tags: { } - relationships: { } - use_ajax: true - header: - result: - id: result - table: views - field: result - relationship: none - group_type: group - admin_label: '' - plugin_id: result - empty: false - content: '
@total districts
' - footer: { } - display_extenders: { } - cache_metadata: - max-age: -1 - contexts: - - 'languages:language_content' - - 'languages:language_interface' - - url.query_args - - 'user.node_grants:view' - - user.permissions - tags: { } - district_listing: - id: district_listing - display_title: Block - display_plugin: block - position: 1 - display_options: - display_extenders: - metatag_display_extender: - metatags: { } - tokenize: false - cache_metadata: - max-age: -1 - contexts: - - 'languages:language_content' - - 'languages:language_interface' - - url.query_args - - 'user.node_grants:view' - - user.permissions - tags: { } diff --git a/public/modules/custom/helfi_custom_test_content/content/menu_link_content/33ee5b0d-bd4d-4023-9285-915ee1980913.yml b/public/modules/custom/helfi_custom_test_content/content/menu_link_content/33ee5b0d-bd4d-4023-9285-915ee1980913.yml deleted file mode 100644 index 9f65e1291..000000000 --- a/public/modules/custom/helfi_custom_test_content/content/menu_link_content/33ee5b0d-bd4d-4023-9285-915ee1980913.yml +++ /dev/null @@ -1,57 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: 33ee5b0d-bd4d-4023-9285-915ee1980913 - bundle: menu_link_content - default_langcode: en - depends: - 0f1e306e-7940-42f1-a924-ff14e1af3983: menu_link_content - 2abbdcf2-dbc8-4ea4-8317-83936b204630: node -default: - enabled: - - - value: true - title: - - - value: 'DC: component district listing' - menu_name: - - - value: main - link: - - - target_uuid: 2abbdcf2-dbc8-4ea4-8317-83936b204630 - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: false - weight: - - - value: 0 - expanded: - - - value: false - parent: - - - value: 'menu_link_content:0f1e306e-7940-42f1-a924-ff14e1af3983' - revision_translation_affected: - - - value: true - content_translation_source: - - - value: und - content_translation_outdated: - - - value: false - content_translation_uid: - - - target_id: 1 - content_translation_status: - - - value: true - content_translation_created: - - - value: 1678456175 diff --git a/public/modules/custom/helfi_custom_test_content/content/node/2abbdcf2-dbc8-4ea4-8317-83936b204630.yml b/public/modules/custom/helfi_custom_test_content/content/node/2abbdcf2-dbc8-4ea4-8317-83936b204630.yml deleted file mode 100644 index fdfe77a5e..000000000 --- a/public/modules/custom/helfi_custom_test_content/content/node/2abbdcf2-dbc8-4ea4-8317-83936b204630.yml +++ /dev/null @@ -1,107 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: 2abbdcf2-dbc8-4ea4-8317-83936b204630 - bundle: landing_page - default_langcode: en -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'DC: component district listing' - created: - - - value: 1678456060 - promote: - - - value: false - sticky: - - - value: false - revision_translation_affected: - - - value: true - hide_sidebar_navigation: - - - value: false - toc_enabled: - - - value: false - toc_title: - - - value: 'Table of contents' - path: - - - alias: /dc-helfi-platform-test-content/dc-helfi-custom-test-content/dc-components-custom/dc-component-district-listing - langcode: en - pathauto: 0 - content_translation_source: - - - value: und - content_translation_outdated: - - - value: false - field_content: - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: be7ddb6e-8e9a-4c94-b01f-210393e043e5 - bundle: district_listing - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1678456071 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_district_list_title: - - - value: 'District listing - No Description' - - - entity: - _meta: - version: '1.0' - entity_type: paragraph - uuid: 2fdb7364-2159-42bc-9daf-971d91729267 - bundle: district_listing - default_langcode: en - default: - status: - - - value: true - created: - - - value: 1678456125 - behavior_settings: - - - value: { } - revision_translation_affected: - - - value: true - field_district_list_description: - - - value: "

Proin eget tortor risus. Curabitur aliquet quam id dui posuere blandit. Vivamus magna justo, lacinia eget consectetur sed, convallis at tellus. Praesent sapien massa, convallis a pellentesque nec, egestas non nisi. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae.

\r\n" - format: minimal - field_district_list_title: - - - value: 'District listing - Description' - field_has_hero: - - - value: false diff --git a/public/modules/custom/helfi_custom_test_content/content/node/a1a7c479-cb1b-4661-98c1-a9d59a11bc0f.yml b/public/modules/custom/helfi_custom_test_content/content/node/a1a7c479-cb1b-4661-98c1-a9d59a11bc0f.yml index 308b24d33..8f161934b 100644 --- a/public/modules/custom/helfi_custom_test_content/content/node/a1a7c479-cb1b-4661-98c1-a9d59a11bc0f.yml +++ b/public/modules/custom/helfi_custom_test_content/content/node/a1a7c479-cb1b-4661-98c1-a9d59a11bc0f.yml @@ -73,7 +73,7 @@ default: value: true field_text: - - value: "\r\n" + value: "\r\n" format: full_html field_has_hero: - diff --git a/public/modules/custom/helfi_custom_test_content/helfi_custom_test_content.info.yml b/public/modules/custom/helfi_custom_test_content/helfi_custom_test_content.info.yml index f146294b2..543c332e5 100644 --- a/public/modules/custom/helfi_custom_test_content/helfi_custom_test_content.info.yml +++ b/public/modules/custom/helfi_custom_test_content/helfi_custom_test_content.info.yml @@ -13,7 +13,6 @@ default_content: - 3d27b114-4e22-4d5d-acc9-70c9f8f8a821 - 5fed4852-ed1e-4ece-b83a-d4b7bc4f611b - 16be7c3d-dfbf-4ea1-8775-c4db5b6d3666 - - 33ee5b0d-bd4d-4023-9285-915ee1980913 - 762e6c3c-06ed-40a0-8cad-7f03954289c7 - 18757e5e-23a5-4205-9ccf-41becc245f7d - 08591473-4036-4137-9e8e-d0a3ea6c9bad @@ -26,7 +25,6 @@ default_content: - d5f34390-b02a-4609-8849-27809595df19 - efa4ebeb-7b3a-442b-b1c4-370cae548442 node: - - 2abbdcf2-dbc8-4ea4-8317-83936b204630 - 5c3777f5-7486-43cb-ada3-8c863440ee84 - 19b7130b-8dce-4daa-a604-d490e79d839c - 29e01875-1d07-4c06-8010-134efb989de3 diff --git a/public/modules/custom/helfi_kymp_content/helfi_kymp_content.module b/public/modules/custom/helfi_kymp_content/helfi_kymp_content.module index 058d9b0fe..738395315 100644 --- a/public/modules/custom/helfi_kymp_content/helfi_kymp_content.module +++ b/public/modules/custom/helfi_kymp_content/helfi_kymp_content.module @@ -65,10 +65,9 @@ function helfi_kymp_content_preprocess_block(&$variables) { $first_paragraph_gray = &$variables['content']['hero_block']['#first_paragraph_grey']; // Check if the content field first paragraph is District and project - // search or District listing and add classes accordingly. + // search and add classes accordingly. switch ($paragraph->getType()) { case 'district_and_project_search': - case 'district_listing': $first_paragraph_gray = 'has-first-gray-bg-block'; break; } @@ -301,9 +300,10 @@ function helfi_kymp_content_helfi_paragraph_types() : array { 'node' => [ 'page' => [ 'field_content' => [ - 'journey_planner' => 18, - 'list_of_plans' => 19, - 'ploughing_schedule' => 20, + 'hearings' => 18, + 'journey_planner' => 19, + 'list_of_plans' => 20, + 'ploughing_schedule' => 21, ], 'field_lower_content' => [ 'list_of_plans' => 18, @@ -313,7 +313,6 @@ function helfi_kymp_content_helfi_paragraph_types() : array { 'field_content' => [ 'district_and_project_search' => 18, 'list_of_plans' => 19, - 'district_listing' => 20, ], ], ], @@ -322,7 +321,6 @@ function helfi_kymp_content_helfi_paragraph_types() : array { 'paragraphs' => [ 'district_and_project_search' => 1, 'list_of_plans' => 2, - 'district_listing' => 3, ], ], ], diff --git a/public/sites/default/staging.settings.php b/public/sites/default/staging.settings.php index 09b16ca54..61e04801c 100644 --- a/public/sites/default/staging.settings.php +++ b/public/sites/default/staging.settings.php @@ -1,11 +1,3 @@ 'staging-urban-environment-and-traffic', - 'fi' => 'staging-kaupunkiymparisto-ja-liikenne', - 'sv' => 'staging-stadsmiljo-och-trafik', - 'ru' => 'staging-urban-environment-and-traffic', - 'zxx' => 'staging-urban-environment-and-traffic', -]; +$config['helfi_proxy.settings']['tunnistamo_return_url'] = '/fi/kaupunkiymparisto-ja-liikenne/openid-connect/tunnistamo'; diff --git a/public/sites/default/testing.settings.php b/public/sites/default/testing.settings.php index f7b71385c..61e04801c 100644 --- a/public/sites/default/testing.settings.php +++ b/public/sites/default/testing.settings.php @@ -1,14 +1,3 @@ 'test-urban-environment-and-traffic', - 'fi' => 'test-kaupunkiymparisto-ja-liikenne', - 'sv' => 'test-stadsmiljo-och-trafik', - 'ru' => 'test-urban-environment-and-traffic', - 'zxx' => 'test-urban-environment-and-traffic', -]; - -$config['helfi_news_feed.settings']['source_environment'] = 'test'; -$config['helfi_global_announcement.settings']['source_environment'] = 'test'; +$config['helfi_proxy.settings']['tunnistamo_return_url'] = '/fi/kaupunkiymparisto-ja-liikenne/openid-connect/tunnistamo'; diff --git a/public/themes/custom/hdbt_subtheme/README.md b/public/themes/custom/hdbt_subtheme/README.md index 1b81adab8..2f1eda600 100644 --- a/public/themes/custom/hdbt_subtheme/README.md +++ b/public/themes/custom/hdbt_subtheme/README.md @@ -70,35 +70,15 @@ hdbt_subtheme │ │ └───... │ └───js │ │ │ common.js -│ └───icons -│ | some-icon.svg └───dist └───css | styles.min.css └───js | bundle.min.js - └───icons - | sprite.svg ``` ## How tos -### How can I add a new SVG icon and then use it on my site. - -You can add your custom icons to `./src/icons/`. F.e. `my-awesome-icon.svg`. -Running `nvm use && npm i && npm run build` will collect the icon to the sprite.svg and it should then be available for use on your site by calling `my-awesome-icon`. Just remember to clear caches. -The icons can be used in twig like so: - - {# HDBT Subtheme specific icons #} - {% include "@hdbt_subtheme/misc/icon.twig" with {icon: 'my-awesome-icon'} %} - - {# HDBT specific icons #} - {% include "@hdbt/misc/icon.twig" with {icon: 'google-view'} %} - -To use the icon in SCSS, you can call it like so: - - background-image: url('../icons/my-awesome-icon.svg'); - ### My javascript has unexpected errors when loading a page in Drupal. If you have compiled the code with dev-flag (`nmp run dev`), then the sourcemaps expects the JS files to be found in correct places. diff --git a/public/themes/custom/hdbt_subtheme/src/scss/06_components/paragraphs/__index.scss b/public/themes/custom/hdbt_subtheme/src/scss/06_components/paragraphs/__index.scss index 3016e5d83..6a9a117fc 100644 --- a/public/themes/custom/hdbt_subtheme/src/scss/06_components/paragraphs/__index.scss +++ b/public/themes/custom/hdbt_subtheme/src/scss/06_components/paragraphs/__index.scss @@ -1,4 +1,3 @@ -@import 'district-listing'; @import 'journey-planner'; @import 'list-of-plans'; -@import 'project-list'; \ No newline at end of file +@import 'project-list'; diff --git a/public/themes/custom/hdbt_subtheme/src/scss/06_components/paragraphs/_district-listing.scss b/public/themes/custom/hdbt_subtheme/src/scss/06_components/paragraphs/_district-listing.scss deleted file mode 100644 index aa1729978..000000000 --- a/public/themes/custom/hdbt_subtheme/src/scss/06_components/paragraphs/_district-listing.scss +++ /dev/null @@ -1,29 +0,0 @@ -.component--district-listing { - background-color: $color-silver-light; -} - -// If the distirct and project search is just before footer it needs to function the same way as unit search. -.layout-main-wrapper > *:last-child .component--district-listing:last-child { - margin-bottom: -115px; // Enough to get the block under the footer. - padding-bottom: 55px; // Leave enough room between the last card and footer. -} - -.district-listing .views-infinite-scroll-content-wrapper { - margin-top: $spacing; - - @include breakpoint($breakpoint-m) { - margin-top: $spacing-double; - } -} - -.district-listing__count-container { - @include font('lead'); - - .district-listing__count { - font-weight: $font-weight-bold; - } -} - -.district-listing .district-teaser .content-tags { - display: none; // Hide content type tags since only one type is listed. -} diff --git a/public/themes/custom/hdbt_subtheme/templates/misc/icon.twig b/public/themes/custom/hdbt_subtheme/templates/misc/icon.twig deleted file mode 100644 index 8e2c5124a..000000000 --- a/public/themes/custom/hdbt_subtheme/templates/misc/icon.twig +++ /dev/null @@ -1 +0,0 @@ - diff --git a/public/themes/custom/hdbt_subtheme/templates/paragraph/paragraph--district-listing.html.twig b/public/themes/custom/hdbt_subtheme/templates/paragraph/paragraph--district-listing.html.twig deleted file mode 100644 index 1f9645022..000000000 --- a/public/themes/custom/hdbt_subtheme/templates/paragraph/paragraph--district-listing.html.twig +++ /dev/null @@ -1,19 +0,0 @@ -{% block paragraph %} - {% embed "@hdbt/misc/component.twig" with - { - component_classes: [ - 'component--full-width', - 'component--district-listing' - ], - component_title: content.field_district_list_title, - component_description: content.field_district_list_description, - component_content_class: 'district-listing', - } - %} - {% block component_content %} -
- {{ drupal_view('district_listing', 'district_listing') }} -
- {% endblock component_content %} - {% endembed %} -{% endblock paragraph %} diff --git a/public/themes/custom/hdbt_subtheme/webpack.config.js b/public/themes/custom/hdbt_subtheme/webpack.config.js index ab9055da2..75b8e8030 100644 --- a/public/themes/custom/hdbt_subtheme/webpack.config.js +++ b/public/themes/custom/hdbt_subtheme/webpack.config.js @@ -4,7 +4,6 @@ const glob = require('glob'); const FriendlyErrorsWebpackPlugin = require('@nuxt/friendly-errors-webpack-plugin'); const MiniCssExtractPlugin = require('mini-css-extract-plugin'); const RemoveEmptyScriptsPlugin = require('webpack-remove-empty-scripts'); -const SvgToSprite = require('./webpack.svgToSprite'); const { merge } = require('webpack-merge'); // Handle entry points. @@ -105,12 +104,6 @@ module.exports = (env, argv) => { extensions: ['.js', '.json'], }, plugins: [ - // Uncomment following lines to create svg icon sprite. - // new SvgToSprite( - // path.resolve(__dirname, 'src/icons/**/*.svg'), - // 'icons/hdbt-subtheme-sprite.svg', - // 'icons.json' - // ), new FriendlyErrorsWebpackPlugin(), new RemoveEmptyScriptsPlugin(), new MiniCssExtractPlugin({ diff --git a/public/themes/custom/hdbt_subtheme/webpack.svgToSprite.js b/public/themes/custom/hdbt_subtheme/webpack.svgToSprite.js deleted file mode 100644 index cfb478edd..000000000 --- a/public/themes/custom/hdbt_subtheme/webpack.svgToSprite.js +++ /dev/null @@ -1,181 +0,0 @@ -const fs = require('fs'); -const md5 = require('md5'); -const path = require('path'); -const glob = require('glob'); -const SVGSpriter = require('svg-sprite'); - -// Generates styles for each icon. -class svgToSprite { - constructor(inputPattern, outputSvgSpriteFilename, outputIconJsonFilename) { - // Current theme name. - this.themeName = path.basename(path.resolve(process.cwd())).replace(/_/g, '-'); - - // Input and output patterns. - this.inputPattern = inputPattern; - this.svgSpriteFilename = outputSvgSpriteFilename; - this.svgToCssOutputFilename = `css/${this.themeName}-icons.css`; - this.svgToJsonOutputFilename = outputIconJsonFilename; - - // Mapped SVG files. - this.files = []; - this.cssVariables = []; - this.classes = []; - - // Sprite configurations. - this.spriteHashFilename = ''; - } - - apply(compiler) { - const pluginName = svgToSprite.name; - const { webpack } = compiler; - const { Compilation } = webpack; - const { RawSource } = webpack.sources; - - // Tapping to the "thisCompilation" hook in order to further tap - // to the compilation process on an earlier stage. - compiler.hooks.thisCompilation.tap(pluginName, (compilation) => { - - // Tapping to the assets processing pipeline on a specific stage. - compilation.hooks.processAssets.tap( - { - name: pluginName, - stage: Compilation.PROCESS_ASSETS_STAGE_SUMMARIZE, - }, - () => { - if (this.files) { - // Create Spriter instance with custom configuration. - let spriter = new SVGSpriter({ - mode: { - stack: { - dest: "dist", - sprite: this.svgSpriteFilename, - rootviewbox: false, - } - } - }); - - // Add SVG files to Spriter instance. - this.files.forEach(function(pathname) { - spriter.add(pathname, null, fs.readFileSync(pathname, 'utf-8')); - }); - - // Compile the sprite. - spriter.compile((error, result) => { - for (let mode in result) { - for (let resource in result[mode]) { - let hash = md5(result[mode][resource].contents).slice(-5); - let outputFilename = this.svgSpriteFilename.replace(/.svg/g, `-${hash}.svg`); - - if (result[mode][resource].contents) { - this.spriteHashFilename = outputFilename; - - // Adding new asset to the compilation, so it will be - // automatically generated by the webpack - // in the output directory. - compilation.emitAsset( - outputFilename, - new RawSource(result[mode][resource].contents) - ); - } - } - } - }); - } - } - ); - }); - - // SVG to CSS. - // Create styles for the icons. - compiler.hooks.emit.tapAsync('svgToCss', (compilation, callback) => { - - // Create --hel-icon--{icon name} and [data-hds-icon-start:'{icon name}'] CSS variables. - let cssVariables = []; - - while(this.cssVariables.length) { - let fullFilename = this.cssVariables.shift(); - let filename = fullFilename.replace(/^.*[\\\/]/, '') - let name = filename.split('.'); - cssVariables.push(`--${this.themeName}-icon--${name[0]}:url(../${this.spriteHashFilename}#${name[0]})`); - } - cssVariables = `:root{${ cssVariables.join(';') }}`; - - // Create .hel-icon--{icon name} & [data-hds-icon-start:'{icon name}'] or {theme-name}--{icon name} css classes. - let cssClasses = ''; - while(this.classes.length) { - let fullFilename = this.classes.shift(); - let filename = fullFilename.replace(/^.*[\\\/]/, '') - let name = filename.split('.'); - cssClasses += `.${this.themeName}-icon--${name[0]},[data-hds-icon-start='${name[0]}']{--url:var(--${this.themeName}-icon--${name[0]})}`; - } - - // Add a URL as a CSS variable to the hel-icon mask-image. - // If icons are used elsewhere (f.e. in a separate theme or module) this - // variable will provide the correct URL for the icon. - let hdbtIconUrl = `.${this.themeName}-icon,[data-hds-icon-start]::before{` + - `-webkit-mask-image:var(--url);` + - `mask-image:var(--url)` + - `}`; - - // Combine CSS variables and classes. - let filelist = cssVariables + cssClasses + hdbtIconUrl; - - // Compile the assets. - compilation.assets[this.svgToCssOutputFilename] = { - source: function() { - return filelist; - }, - size: function() { - return filelist.length; - } - }; - callback(); - }); - compiler.hooks.environment.tap('svgToCss', this.checkForFiles.bind(this)); - compiler.hooks.watchRun.tap('svgToCss', this.checkForFiles.bind(this)); - - // SVG to JSON - // Create a list of icons in JSON format. - compiler.hooks.emit.tapAsync('svgToJson', (compilation, callback) => { - let filelist = '['; - const last = this.files[this.files.length - 1]; - - while(this.files.length) { - let fullfilename = this.files.shift(); - let filename = fullfilename.replace(/^.*[\\\/]/, '') - let name = filename.split('.'); - let divider = (fullfilename === last) ? '"' : '",'; - filelist += '"' + name[0] + divider; - } - filelist += ']'; - - compilation.assets[this.svgToJsonOutputFilename] = { - source: function() { - return filelist; - }, - size: function() { - return filelist.length; - } - }; - callback(); - }); - compiler.hooks.environment.tap('svgToJson', this.checkForFiles.bind(this)); - compiler.hooks.watchRun.tap('svgToJson', this.checkForFiles.bind(this)); - } - - // Map files to suitable variables. - checkForFiles() { - glob.globSync(this.inputPattern).map((match) => { - const pathname = path.resolve(match); - const stats = fs.lstatSync(pathname); - - if (stats.isFile()) { - this.classes = [...new Set([...this.classes, pathname])]; - this.cssVariables = [...new Set([...this.cssVariables, pathname])]; - this.files = [...new Set([...this.files, pathname])]; - } - }); - } -} - -module.exports = svgToSprite;