From 1ca354439aac5bf68d6d7cf3f27a8b7e00d96e52 Mon Sep 17 00:00:00 2001 From: Santeri Hurnanen Date: Thu, 14 Mar 2024 08:23:50 +0200 Subject: [PATCH 1/2] UHF-9576: Switch field widget to select2_entity_reference --- ...e.entity_form_display.paragraph.event_list.default.yml | 7 ++++--- modules/helfi_react_search/helfi_react_search.info.yml | 1 + modules/helfi_react_search/helfi_react_search.install | 8 ++++++++ 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/modules/helfi_react_search/config/install/core.entity_form_display.paragraph.event_list.default.yml b/modules/helfi_react_search/config/install/core.entity_form_display.paragraph.event_list.default.yml index 751e4cf2a..806a0a470 100644 --- a/modules/helfi_react_search/config/install/core.entity_form_display.paragraph.event_list.default.yml +++ b/modules/helfi_react_search/config/install/core.entity_form_display.paragraph.event_list.default.yml @@ -14,6 +14,7 @@ dependencies: - paragraphs.paragraphs_type.event_list module: - link + - select2 - text id: paragraph.event_list.default targetEntityType: paragraph @@ -65,14 +66,14 @@ content: display_label: true third_party_settings: { } field_filter_keywords: - type: entity_reference_autocomplete_tags + type: select2_entity_reference weight: 8 region: content settings: + width: 100% + autocomplete: true match_operator: CONTAINS match_limit: 10 - size: 60 - placeholder: '' third_party_settings: { } field_free_events: type: boolean_checkbox diff --git a/modules/helfi_react_search/helfi_react_search.info.yml b/modules/helfi_react_search/helfi_react_search.info.yml index 04e04eb91..eeb7cccf3 100644 --- a/modules/helfi_react_search/helfi_react_search.info.yml +++ b/modules/helfi_react_search/helfi_react_search.info.yml @@ -11,6 +11,7 @@ dependencies: - 'drupal:text' - 'drupal:taxonomy' - 'drupal:migrate' + - 'select2:select2' - 'helfi_platform_config:helfi_platform_config' - 'readonly_field_widget:readonly_field_widget' - 'paragraphs:paragraphs' diff --git a/modules/helfi_react_search/helfi_react_search.install b/modules/helfi_react_search/helfi_react_search.install index b86c1540e..a99a1710c 100644 --- a/modules/helfi_react_search/helfi_react_search.install +++ b/modules/helfi_react_search/helfi_react_search.install @@ -111,3 +111,11 @@ function helfi_react_search_update_9007() : void { \Drupal::service('helfi_platform_config.config_update_helper') ->update('helfi_react_search'); } + +/** + * UHF-9576: Linked events: change paragraph widget. + */ +function helfi_react_search_update_9008() : void { + \Drupal::service('helfi_platform_config.config_update_helper') + ->update('helfi_react_search'); +} From 7105be6d73518877fe22804d1cb718c9b830a7ad Mon Sep 17 00:00:00 2001 From: Santeri Hurnanen Date: Thu, 14 Mar 2024 08:19:57 +0200 Subject: [PATCH 2/2] UHF-9576: Update topic filter translations --- modules/helfi_react_search/translations/fi.po | 12 ++++++------ modules/helfi_react_search/translations/sv.po | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/modules/helfi_react_search/translations/fi.po b/modules/helfi_react_search/translations/fi.po index b1a7c20f8..e8145b6ae 100644 --- a/modules/helfi_react_search/translations/fi.po +++ b/modules/helfi_react_search/translations/fi.po @@ -38,13 +38,13 @@ msgstr "Jos haluat etsiä etätapahtumia, valitse vaihtoehto 'Internet (etätapa msgid "Select a venue" msgstr "Valitse tapahtumapaikka" -msgctxt "React search topics filter" -msgid "Select topics" -msgstr "Valitse asiasanat" +msgctxt "React search: topics filter" +msgid "Event topic" +msgstr "Tapahtuman aihe" -msgctxt "React search topics filter" -msgid "Filter events by topics" -msgstr "Suodata asiasanoilla" +msgctxt "React search: topics filter" +msgid "All topics" +msgstr "Kaikki aiheet" msgctxt "React search: remove item aria label" msgid "Remove item" diff --git a/modules/helfi_react_search/translations/sv.po b/modules/helfi_react_search/translations/sv.po index a14ee307e..e9d709d42 100644 --- a/modules/helfi_react_search/translations/sv.po +++ b/modules/helfi_react_search/translations/sv.po @@ -44,13 +44,13 @@ msgstr "Om du vill söka evenemang på distans, välj endast alternativet 'Inter msgid "Select a venue" msgstr "Välj tidpunkt" -msgctxt "React search topics filter" -msgid "Select topics" -msgstr "XXXX" +msgctxt "React search: topics filter" +msgid "Event topic" +msgstr "Evenemangets ämne" -msgctxt "React search topics filter" -msgid "Filter events by topics" -msgstr "XXXX" +msgctxt "React search: topics filter" +msgid "All topics" +msgstr "Alla ämnen" msgctxt "React search: remove item aria label" msgid "Remove item"