diff --git a/composer.lock b/composer.lock index 16c21f7d..95652134 100644 --- a/composer.lock +++ b/composer.lock @@ -1701,6 +1701,50 @@ "source": "https://git.drupalcode.org/project/ckeditor" } }, + { + "name": "drupal/ckeditor5_paste_filter", + "version": "1.0.0", + "source": { + "type": "git", + "url": "https://git.drupalcode.org/project/ckeditor5_paste_filter.git", + "reference": "1.0.0" + }, + "dist": { + "type": "zip", + "url": "https://ftp.drupal.org/files/projects/ckeditor5_paste_filter-1.0.0.zip", + "reference": "1.0.0", + "shasum": "f04752267a09489e9637add278d4c661150b46f7" + }, + "require": { + "drupal/core": "^9.3 || ^10" + }, + "type": "drupal-module", + "extra": { + "drupal": { + "version": "1.0.0", + "datestamp": "1700503273", + "security-coverage": { + "status": "covered", + "message": "Covered by Drupal's security advisory policy" + } + } + }, + "notification-url": "https://packages.drupal.org/8/downloads", + "license": [ + "GPL-2.0-or-later" + ], + "authors": [ + { + "name": "star-szr", + "homepage": "https://www.drupal.org/user/1167326" + } + ], + "description": "Filter content pasted into CKEditor 5", + "homepage": "https://www.drupal.org/project/ckeditor5_paste_filter", + "support": { + "source": "https://git.drupalcode.org/project/ckeditor5_paste_filter" + } + }, { "name": "drupal/config_filter", "version": "2.6.0", @@ -2562,17 +2606,17 @@ }, { "name": "drupal/editoria11y", - "version": "2.1.7", + "version": "2.1.8", "source": { "type": "git", "url": "https://git.drupalcode.org/project/editoria11y.git", - "reference": "2.1.7" + "reference": "2.1.8" }, "dist": { "type": "zip", - "url": "https://ftp.drupal.org/files/projects/editoria11y-2.1.7.zip", - "reference": "2.1.7", - "shasum": "4efcf4a9cff26cbd64d9b69be384d9347499e1a5" + "url": "https://ftp.drupal.org/files/projects/editoria11y-2.1.8.zip", + "reference": "2.1.8", + "shasum": "6ec91608cb6cd0db75a9a9bd8681616080cb8e76" }, "require": { "drupal/core": "^9 || ^10" @@ -2580,8 +2624,8 @@ "type": "drupal-module", "extra": { "drupal": { - "version": "2.1.7", - "datestamp": "1703778081", + "version": "2.1.8", + "datestamp": "1707937463", "security-coverage": { "status": "covered", "message": "Covered by Drupal's security advisory policy" @@ -3144,17 +3188,17 @@ }, { "name": "drupal/externalauth", - "version": "2.0.3", + "version": "2.0.5", "source": { "type": "git", "url": "https://git.drupalcode.org/project/externalauth.git", - "reference": "2.0.3" + "reference": "2.0.5" }, "dist": { "type": "zip", - "url": "https://ftp.drupal.org/files/projects/externalauth-2.0.3.zip", - "reference": "2.0.3", - "shasum": "dae49e3df8739538d7b9371ab7fb5005b8d953fd" + "url": "https://ftp.drupal.org/files/projects/externalauth-2.0.5.zip", + "reference": "2.0.5", + "shasum": "7c262c7ca20d26aae45896daee4249e47b637abc" }, "require": { "drupal/core": "^9 || ^10" @@ -3162,8 +3206,8 @@ "type": "drupal-module", "extra": { "drupal": { - "version": "2.0.3", - "datestamp": "1668777505", + "version": "2.0.5", + "datestamp": "1708329378", "security-coverage": { "status": "covered", "message": "Covered by Drupal's security advisory policy" @@ -3680,16 +3724,16 @@ }, { "name": "drupal/hdbt", - "version": "6.4.12", + "version": "6.4.13", "source": { "type": "git", "url": "https://github.com/City-of-Helsinki/drupal-hdbt.git", - "reference": "e6c27176dbc269c233e6e27f01e0b06752e8e3e6" + "reference": "c76de24931e368362b1991f0c4f75c37786234cb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/City-of-Helsinki/drupal-hdbt/zipball/e6c27176dbc269c233e6e27f01e0b06752e8e3e6", - "reference": "e6c27176dbc269c233e6e27f01e0b06752e8e3e6", + "url": "https://api.github.com/repos/City-of-Helsinki/drupal-hdbt/zipball/c76de24931e368362b1991f0c4f75c37786234cb", + "reference": "c76de24931e368362b1991f0c4f75c37786234cb", "shasum": "" }, "require": { @@ -3707,10 +3751,10 @@ "Drupal" ], "support": { - "source": "https://github.com/City-of-Helsinki/drupal-hdbt/tree/6.4.12", + "source": "https://github.com/City-of-Helsinki/drupal-hdbt/tree/6.4.13", "issues": "https://github.com/City-of-Helsinki/drupal-hdbt/issues" }, - "time": "2024-02-12T13:56:31+00:00" + "time": "2024-02-22T08:40:40+00:00" }, { "name": "drupal/hdbt_admin", @@ -3973,22 +4017,23 @@ }, { "name": "drupal/helfi_platform_config", - "version": "4.3.8", + "version": "4.3.13", "source": { "type": "git", "url": "https://github.com/City-of-Helsinki/drupal-helfi-platform-config.git", - "reference": "d7a3a5eb1fe34422ca82d24de0f7d0a52039e87f" + "reference": "4f4c6facbe49620a5aa90d8530bb0f1522b4f2c4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/City-of-Helsinki/drupal-helfi-platform-config/zipball/d7a3a5eb1fe34422ca82d24de0f7d0a52039e87f", - "reference": "d7a3a5eb1fe34422ca82d24de0f7d0a52039e87f", + "url": "https://api.github.com/repos/City-of-Helsinki/drupal-helfi-platform-config/zipball/4f4c6facbe49620a5aa90d8530bb0f1522b4f2c4", + "reference": "4f4c6facbe49620a5aa90d8530bb0f1522b4f2c4", "shasum": "" }, "require": { "drupal/admin_toolbar": "^3.0", "drupal/allowed_formats": "^2.0", "drupal/ckeditor": "^1.0", + "drupal/ckeditor5_paste_filter": "^1.0", "drupal/config_filter": "^2.6", "drupal/config_ignore": "^3.0", "drupal/config_rewrite": "^1.4", @@ -4090,10 +4135,10 @@ ], "description": "HELfi platform config", "support": { - "source": "https://github.com/City-of-Helsinki/drupal-helfi-platform-config/tree/4.3.8", + "source": "https://github.com/City-of-Helsinki/drupal-helfi-platform-config/tree/4.3.13", "issues": "https://github.com/City-of-Helsinki/drupal-helfi-platform-config/issues" }, - "time": "2024-02-12T10:26:29+00:00" + "time": "2024-02-22T10:20:01+00:00" }, { "name": "drupal/helfi_proxy", @@ -8771,16 +8816,16 @@ }, { "name": "nikic/php-parser", - "version": "v5.0.0", + "version": "v5.0.1", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "4a21235f7e56e713259a6f76bf4b5ea08502b9dc" + "reference": "2218c2252c874a4624ab2f613d86ac32d227bc69" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/4a21235f7e56e713259a6f76bf4b5ea08502b9dc", - "reference": "4a21235f7e56e713259a6f76bf4b5ea08502b9dc", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/2218c2252c874a4624ab2f613d86ac32d227bc69", + "reference": "2218c2252c874a4624ab2f613d86ac32d227bc69", "shasum": "" }, "require": { @@ -8823,9 +8868,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v5.0.0" + "source": "https://github.com/nikic/PHP-Parser/tree/v5.0.1" }, - "time": "2024-01-07T17:17:35+00:00" + "time": "2024-02-21T19:24:10+00:00" }, { "name": "nodespark/des-connector", @@ -15947,16 +15992,16 @@ }, { "name": "phpdocumentor/type-resolver", - "version": "1.8.0", + "version": "1.8.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "fad452781b3d774e3337b0c0b245dd8e5a4455fc" + "reference": "bc3dc91a5e9b14aa06d1d9e90647c5c5a2cc5353" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/fad452781b3d774e3337b0c0b245dd8e5a4455fc", - "reference": "fad452781b3d774e3337b0c0b245dd8e5a4455fc", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/bc3dc91a5e9b14aa06d1d9e90647c5c5a2cc5353", + "reference": "bc3dc91a5e9b14aa06d1d9e90647c5c5a2cc5353", "shasum": "" }, "require": { @@ -15999,9 +16044,9 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.8.0" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.8.1" }, - "time": "2024-01-11T11:49:22+00:00" + "time": "2024-01-18T19:15:27+00:00" }, { "name": "phpspec/prophecy", diff --git a/conf/cmi/block.block.hdbt_subtheme_user_inquiry.yml b/conf/cmi/block.block.hdbt_subtheme_user_inquiry.yml new file mode 100644 index 00000000..01c323ed --- /dev/null +++ b/conf/cmi/block.block.hdbt_subtheme_user_inquiry.yml @@ -0,0 +1,40 @@ +uuid: 3f0b9a35-6bbf-462a-97b7-a8c0f8929458 +langcode: en +status: true +dependencies: + module: + - helfi_platform_config + - language + - user + theme: + - hdbt_subtheme +id: hdbt_subtheme_user_inquiry +theme: hdbt_subtheme +region: attachments +weight: -19 +provider: helfi_platform_config +plugin: chat_leijuke +settings: + id: chat_leijuke + label: 'User inquiry' + label_display: '' + provider: helfi_platform_config + chat_title: '' + chat_selection: user_inquiry +visibility: + language: + id: language + negate: false + context_mapping: + language: '@language.current_language_context:language_interface' + langcodes: + fi: fi + en: en + sv: sv + user_role: + id: user_role + negate: false + context_mapping: + user: '@user.current_user_context:current_user' + roles: + anonymous: anonymous diff --git a/conf/cmi/core.extension.yml b/conf/cmi/core.extension.yml index b68af56f..9e18436d 100644 --- a/conf/cmi/core.extension.yml +++ b/conf/cmi/core.extension.yml @@ -10,6 +10,7 @@ module: block: 0 breakpoint: 0 ckeditor5: 0 + ckeditor5_paste_filter: 0 config: 0 config_ignore: 0 config_rewrite: 0 diff --git a/conf/cmi/editor.editor.full_html.yml b/conf/cmi/editor.editor.full_html.yml index ae983b91..54dee2fc 100644 --- a/conf/cmi/editor.editor.full_html.yml +++ b/conf/cmi/editor.editor.full_html.yml @@ -7,7 +7,7 @@ dependencies: module: - ckeditor5 _core: - default_config_hash: rMPZSfUdZCsb509LFsy6EZYI2wjtuonQtf6afD85sQ0 + default_config_hash: yobPkyFHZ_T4qFbTwAFPEgpYYtGpRMfUOE4xTRUVREk format: full_html editor: ckeditor5 settings: @@ -47,28 +47,94 @@ settings: reversed: false startIndex: true multiBlock: true + ckeditor5_paste_filter_pasteFilter: + enabled: true + filters: + - + enabled: true + weight: 0 + search: '<\/o:p>' + replace: '' + - + enabled: true + weight: 1 + search: '(<[^>]*) (style="[^"]*")' + replace: $1 + - + enabled: true + weight: 2 + search: '(<[^>]*) (face="[^"]*")' + replace: $1 + - + enabled: true + weight: 3 + search: '(<[^>]*) (class="[^"]*")' + replace: $1 + - + enabled: true + weight: 4 + search: '(<[^>]*) (valign="[^"]*")' + replace: $1 + - + enabled: true + weight: 5 + search: ']*>' + replace: '' + - + enabled: true + weight: 6 + search: '<\/font>' + replace: '' + - + enabled: true + weight: 7 + search: ']*\b(?:dir|lang)="[^"]*")[^>]*>(.*?)<\/span>' + replace: $1 + - + enabled: true + weight: 8 + search: '

<\/span><\/p>' + replace: '' + - + enabled: true + weight: 9 + search: '<\/span>' + replace: '' + - + enabled: true + weight: 10 + search: '

 <\/p>' + replace: '' + - + enabled: true + weight: 11 + search: '

<\/p>' + replace: '' + - + enabled: true + weight: 12 + search: '<\/b>' + replace: '' + - + enabled: true + weight: 13 + search: '<\/i>' + replace: '' + - + enabled: true + weight: 14 + search: '(.*?)<\/a>' + replace: $1 + - + enabled: true + weight: 15 + search: '(.*?)<\/a>' + replace: $1 ckeditor5_sourceEditing: - allowed_tags: - - '

' - - '
' - - '
' - - '
' - - '
' - - '' - - '' - - '