From 1d02986a73298aac1a078e68bdd2fa2f8d0557fb Mon Sep 17 00:00:00 2001 From: Joe Tower Date: Mon, 11 Sep 2023 16:37:18 -0500 Subject: [PATCH 1/9] fix(YALB-mega-footer-2): update image styles to use 1:1 --- .../responsive_image.styles.image_logos.yml | 30 +++++++------------ 1 file changed, 11 insertions(+), 19 deletions(-) diff --git a/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml b/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml index af2021a991..294c10697d 100644 --- a/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml +++ b/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml @@ -3,15 +3,11 @@ langcode: en status: true dependencies: config: - - image.style.max_width_180 - - image.style.max_width_220 - - image.style.max_width_250 - - image.style.max_width_320 - - image.style.max_width_444 - - image.style.max_width_480 - - image.style.max_width_540 - - image.style.max_width_640 - - image.style.max_width_800 + - image.style.1_1_150 + - image.style.1_1_200 + - image.style.1_1_300_ + - image.style.1_1_500 + - image.style.1_1_600 id: image_logos label: 'Image - Logos' image_style_mappings: @@ -20,16 +16,12 @@ image_style_mappings: image_mapping: sizes: '(min-width: 1344px) 212px, (min-width: 992px) 180px, (min-width: 576px) 25vw, 50vw' sizes_image_styles: - - max_width_250 - - max_width_180 - - max_width_220 - - max_width_320 - - max_width_444 - - max_width_480 - - max_width_540 - - max_width_640 - - max_width_800 + - '1_1_150' + - '1_1_200' + - '1_1_300_' + - '1_1_500' + - '1_1_600' breakpoint_id: responsive_image.viewport_sizing multiplier: 1x breakpoint_group: responsive_image -fallback_image_style: max_width_320 +fallback_image_style: '1_1_300_' From d20fac3c52b7da16dc98058a3b1d73fba9d34d6f Mon Sep 17 00:00:00 2001 From: Joe Tower Date: Tue, 12 Sep 2023 14:04:10 -0500 Subject: [PATCH 2/9] fix(YALB-mega-footer-2): update responsive image style for image_logos --- .../config/sync/image.style.1_1_250.yml | 26 +++++++++++++++++++ .../responsive_image.styles.image_logos.yml | 10 +++---- 2 files changed, 30 insertions(+), 6 deletions(-) create mode 100644 web/profiles/custom/yalesites_profile/config/sync/image.style.1_1_250.yml diff --git a/web/profiles/custom/yalesites_profile/config/sync/image.style.1_1_250.yml b/web/profiles/custom/yalesites_profile/config/sync/image.style.1_1_250.yml new file mode 100644 index 0000000000..0ec16aff6d --- /dev/null +++ b/web/profiles/custom/yalesites_profile/config/sync/image.style.1_1_250.yml @@ -0,0 +1,26 @@ +uuid: de51c589-87e5-438e-905d-fa29247da0cb +langcode: en +status: true +dependencies: + config: + - crop.type.profile_1_1_ + module: + - crop +name: '1_1_250' +label: '1:1 (250)' +effects: + 91edf6fe-7cd0-4d0c-8156-714352c244f6: + uuid: 91edf6fe-7cd0-4d0c-8156-714352c244f6 + id: crop_crop + weight: 1 + data: + crop_type: profile_1_1_ + automatic_crop_provider: null + f6a70a4b-f538-465d-9d38-839e13b2f45a: + uuid: f6a70a4b-f538-465d-9d38-839e13b2f45a + id: image_scale_and_crop + weight: 2 + data: + width: 250 + height: 250 + anchor: center-center diff --git a/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml b/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml index 294c10697d..3a9058c545 100644 --- a/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml +++ b/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml @@ -5,23 +5,21 @@ dependencies: config: - image.style.1_1_150 - image.style.1_1_200 + - image.style.1_1_250 - image.style.1_1_300_ - - image.style.1_1_500 - - image.style.1_1_600 id: image_logos label: 'Image - Logos' image_style_mappings: - image_mapping_type: sizes image_mapping: - sizes: '(min-width: 1344px) 212px, (min-width: 992px) 180px, (min-width: 576px) 25vw, 50vw' + sizes: '(min-width:556px) 200px, 50vw' sizes_image_styles: - '1_1_150' - '1_1_200' + - '1_1_250' - '1_1_300_' - - '1_1_500' - - '1_1_600' breakpoint_id: responsive_image.viewport_sizing multiplier: 1x breakpoint_group: responsive_image -fallback_image_style: '1_1_300_' +fallback_image_style: '1_1_200' From b10924061440b4d4aa2cfd99b0a7dceb772a7029 Mon Sep 17 00:00:00 2001 From: Joe Tower Date: Tue, 12 Sep 2023 16:27:46 -0500 Subject: [PATCH 3/9] fix(YALB-mega-footer-2): update responsive image style for image_logos --- .../config/sync/responsive_image.styles.image_logos.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml b/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml index 3a9058c545..aa838ea2a8 100644 --- a/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml +++ b/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_logos.yml @@ -7,6 +7,8 @@ dependencies: - image.style.1_1_200 - image.style.1_1_250 - image.style.1_1_300_ + - image.style.1_1_500 + - image.style.1_1_600 id: image_logos label: 'Image - Logos' image_style_mappings: @@ -19,6 +21,8 @@ image_style_mappings: - '1_1_200' - '1_1_250' - '1_1_300_' + - '1_1_500' + - '1_1_600' breakpoint_id: responsive_image.viewport_sizing multiplier: 1x breakpoint_group: responsive_image From 84918e9997a4df62181f4b8e981d61360e006015 Mon Sep 17 00:00:00 2001 From: Marc Berger Date: Tue, 12 Sep 2023 15:52:11 -0700 Subject: [PATCH 4/9] feat: Change footer logo form from allowing 4 to allowing 2 --- .../modules/custom/ys_core/src/Form/FooterSettingsForm.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/profiles/custom/yalesites_profile/modules/custom/ys_core/src/Form/FooterSettingsForm.php b/web/profiles/custom/yalesites_profile/modules/custom/ys_core/src/Form/FooterSettingsForm.php index 0ccbad82c9..45f66a0c85 100644 --- a/web/profiles/custom/yalesites_profile/modules/custom/ys_core/src/Form/FooterSettingsForm.php +++ b/web/profiles/custom/yalesites_profile/modules/custom/ys_core/src/Form/FooterSettingsForm.php @@ -154,7 +154,7 @@ public function buildForm(array $form, FormStateInterface $form_state) { $form['footer_logos']['logos'] = [ '#type' => 'multivalue', '#title' => $this->t('Footer Logos'), - '#cardinality' => 4, + '#cardinality' => 2, '#default_value' => ($footerConfig->get('content.logos')) ? $footerConfig->get('content.logos') : [], 'logo' => [ From fc77676f764d5fb56e08883ef6b65bc624a75133 Mon Sep 17 00:00:00 2001 From: Joe Tower Date: Wed, 13 Sep 2023 11:49:49 -0500 Subject: [PATCH 5/9] fix(YALB-mega-footer-2): wrap social-links in block --- .../modules/custom/ys_core/templates/ys-footer-block.html.twig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/web/profiles/custom/yalesites_profile/modules/custom/ys_core/templates/ys-footer-block.html.twig b/web/profiles/custom/yalesites_profile/modules/custom/ys_core/templates/ys-footer-block.html.twig index 99ee8d8e2f..a6775db66e 100644 --- a/web/profiles/custom/yalesites_profile/modules/custom/ys_core/templates/ys-footer-block.html.twig +++ b/web/profiles/custom/yalesites_profile/modules/custom/ys_core/templates/ys-footer-block.html.twig @@ -62,6 +62,8 @@ {% endif %} {% endblock %} {% endembed %} + {% endblock %} + {% block site_footer__social_links %} {{ drupal_block('social_links_block') }} {% endblock %} {% endembed %} From c66bd514a8c8135f6d80a5d7115bb98166f6ca1b Mon Sep 17 00:00:00 2001 From: Joe Tower Date: Wed, 13 Sep 2023 13:11:34 -0500 Subject: [PATCH 6/9] fix(YALB-mega-footer-2): update responsive image style to new 3:1 ratio --- .../custom/ys_core/src/Plugin/Block/YaleSitesFooterBlock.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/profiles/custom/yalesites_profile/modules/custom/ys_core/src/Plugin/Block/YaleSitesFooterBlock.php b/web/profiles/custom/yalesites_profile/modules/custom/ys_core/src/Plugin/Block/YaleSitesFooterBlock.php index 042616079d..361e53abf0 100644 --- a/web/profiles/custom/yalesites_profile/modules/custom/ys_core/src/Plugin/Block/YaleSitesFooterBlock.php +++ b/web/profiles/custom/yalesites_profile/modules/custom/ys_core/src/Plugin/Block/YaleSitesFooterBlock.php @@ -104,7 +104,7 @@ public function build() { $schoolLogoFileUri = $fileEntity->load($schoolLogoMedia->field_media_image->target_id)->getFileUri(); $schoolLogoRender = [ '#type' => 'responsive_image', - '#responsive_image_style_id' => 'image_content_width', + '#responsive_image_style_id' => 'image_horizontal_logos', '#uri' => $schoolLogoFileUri, '#attributes' => [ 'alt' => $schoolLogoMedia->get('field_media_image')->first()->get('alt')->getValue(), From 19c9ed565ac1da9d13ecea844841302464beb982 Mon Sep 17 00:00:00 2001 From: Joe Tower Date: Wed, 13 Sep 2023 13:19:01 -0500 Subject: [PATCH 7/9] fix(YALB-mega-footer-2): add new 3:1 horizontal logo crop type, add new 3:1 image styles and responsive image style --- ...ntity_form_display.media.image.default.yml | 1 + .../sync/crop.type.logo_horizontal_3_1.yml | 37 +++++++++++++++++++ .../config/sync/image.style.3_1_300.yml | 26 +++++++++++++ .../config/sync/image.style.3_1_400.yml | 26 +++++++++++++ .../config/sync/image.style.3_1_500.yml | 26 +++++++++++++ .../config/sync/image.style.3_1_600.yml | 26 +++++++++++++ .../config/sync/image.style.3_1_700.yml | 26 +++++++++++++ ...ve_image.styles.image_horizontal_logos.yml | 27 ++++++++++++++ 8 files changed, 195 insertions(+) create mode 100644 web/profiles/custom/yalesites_profile/config/sync/crop.type.logo_horizontal_3_1.yml create mode 100644 web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_300.yml create mode 100644 web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_400.yml create mode 100644 web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_500.yml create mode 100644 web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_600.yml create mode 100644 web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_700.yml create mode 100644 web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_horizontal_logos.yml diff --git a/web/profiles/custom/yalesites_profile/config/sync/core.entity_form_display.media.image.default.yml b/web/profiles/custom/yalesites_profile/config/sync/core.entity_form_display.media.image.default.yml index d94c88c228..962fd87f99 100644 --- a/web/profiles/custom/yalesites_profile/config/sync/core.entity_form_display.media.image.default.yml +++ b/web/profiles/custom/yalesites_profile/config/sync/core.entity_form_display.media.image.default.yml @@ -24,6 +24,7 @@ content: crop_list: - banner_16_5 - card_3_2 + - logo_horizontal_3_1 - profile_1_1_ crop_types_required: { } warn_multiple_usages: true diff --git a/web/profiles/custom/yalesites_profile/config/sync/crop.type.logo_horizontal_3_1.yml b/web/profiles/custom/yalesites_profile/config/sync/crop.type.logo_horizontal_3_1.yml new file mode 100644 index 0000000000..49bf6cfe1e --- /dev/null +++ b/web/profiles/custom/yalesites_profile/config/sync/crop.type.logo_horizontal_3_1.yml @@ -0,0 +1,37 @@ +uuid: 6b052cd9-2d1c-4b86-9349-7f3b7f7ba104 +langcode: en +status: true +dependencies: + module: + - entity_redirect +third_party_settings: + entity_redirect: + redirect: + add: + active: 0 + destination: default + url: '' + external: '' + edit: + active: 0 + destination: default + url: '' + external: '' + delete: + active: 0 + destination: default + url: '' + external: '' + anonymous: + active: 0 + destination: default + url: '' + external: '' +label: 'Logo Horizontal (3:1)' +id: logo_horizontal_3_1 +description: 'Crop type for landscape/horizontal logos in 3:1 aspect ratio.' +aspect_ratio: '3:1' +soft_limit_width: null +soft_limit_height: null +hard_limit_width: null +hard_limit_height: null diff --git a/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_300.yml b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_300.yml new file mode 100644 index 0000000000..984487ee7b --- /dev/null +++ b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_300.yml @@ -0,0 +1,26 @@ +uuid: 5a51324b-359a-43fd-bcb4-2be349b5084f +langcode: en +status: true +dependencies: + config: + - crop.type.logo_horizontal_3_1 + module: + - crop +name: '3_1_300' +label: '3:1 (300)' +effects: + aa428c6a-4f01-463a-a2a8-60826c4d4a66: + uuid: aa428c6a-4f01-463a-a2a8-60826c4d4a66 + id: crop_crop + weight: 1 + data: + crop_type: logo_horizontal_3_1 + automatic_crop_provider: null + 8a3873d2-9ad7-46cb-bdf9-5df37ba25a51: + uuid: 8a3873d2-9ad7-46cb-bdf9-5df37ba25a51 + id: image_scale_and_crop + weight: 2 + data: + width: 300 + height: 100 + anchor: center-center diff --git a/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_400.yml b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_400.yml new file mode 100644 index 0000000000..1f13ba4be2 --- /dev/null +++ b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_400.yml @@ -0,0 +1,26 @@ +uuid: 36d76d1d-fd7a-4deb-94e8-87b4f059b78b +langcode: en +status: true +dependencies: + config: + - crop.type.logo_horizontal_3_1 + module: + - crop +name: '3_1_400' +label: '3:1 (400)' +effects: + 06a2fdc7-3eb2-437b-b96e-2b06edb78127: + uuid: 06a2fdc7-3eb2-437b-b96e-2b06edb78127 + id: crop_crop + weight: 1 + data: + crop_type: logo_horizontal_3_1 + automatic_crop_provider: null + 1779826d-ec52-4a15-b9e1-3ad08b1549a3: + uuid: 1779826d-ec52-4a15-b9e1-3ad08b1549a3 + id: image_scale_and_crop + weight: 2 + data: + width: 400 + height: 133 + anchor: center-center diff --git a/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_500.yml b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_500.yml new file mode 100644 index 0000000000..e0a54e565f --- /dev/null +++ b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_500.yml @@ -0,0 +1,26 @@ +uuid: d9ccb021-af76-427d-9704-d622356eb0ee +langcode: en +status: true +dependencies: + config: + - crop.type.logo_horizontal_3_1 + module: + - crop +name: '3_1_500' +label: '3:1 (500)' +effects: + 53979460-2d06-41ed-8c19-0606690aca30: + uuid: 53979460-2d06-41ed-8c19-0606690aca30 + id: crop_crop + weight: 1 + data: + crop_type: logo_horizontal_3_1 + automatic_crop_provider: null + 5fd3c76d-3e51-4a42-a62c-002a6134504a: + uuid: 5fd3c76d-3e51-4a42-a62c-002a6134504a + id: image_scale_and_crop + weight: 2 + data: + width: 500 + height: 166 + anchor: center-center diff --git a/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_600.yml b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_600.yml new file mode 100644 index 0000000000..54a86ed336 --- /dev/null +++ b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_600.yml @@ -0,0 +1,26 @@ +uuid: 5efd596b-b64b-462a-8464-1d708d55bf08 +langcode: en +status: true +dependencies: + config: + - crop.type.logo_horizontal_3_1 + module: + - crop +name: '3_1_600' +label: '3:1 (600)' +effects: + 31133b06-51c3-40a2-b493-a5015514cf48: + uuid: 31133b06-51c3-40a2-b493-a5015514cf48 + id: crop_crop + weight: 1 + data: + crop_type: logo_horizontal_3_1 + automatic_crop_provider: null + 283af2b5-646f-4ac0-8651-fc56402b161c: + uuid: 283af2b5-646f-4ac0-8651-fc56402b161c + id: image_scale_and_crop + weight: 2 + data: + width: 600 + height: 200 + anchor: center-center diff --git a/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_700.yml b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_700.yml new file mode 100644 index 0000000000..fd273108fb --- /dev/null +++ b/web/profiles/custom/yalesites_profile/config/sync/image.style.3_1_700.yml @@ -0,0 +1,26 @@ +uuid: 1fc31537-285c-4d51-a818-e679ab7b4277 +langcode: en +status: true +dependencies: + config: + - crop.type.logo_horizontal_3_1 + module: + - crop +name: '3_1_700' +label: '3:1 (700)' +effects: + 40a36e6d-3a30-4c7c-9adb-eb2a89ecda22: + uuid: 40a36e6d-3a30-4c7c-9adb-eb2a89ecda22 + id: crop_crop + weight: 1 + data: + crop_type: logo_horizontal_3_1 + automatic_crop_provider: null + 09e9582c-0f44-431a-a684-1c35cea092e7: + uuid: 09e9582c-0f44-431a-a684-1c35cea092e7 + id: image_scale_and_crop + weight: 2 + data: + width: 700 + height: 233 + anchor: center-center diff --git a/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_horizontal_logos.yml b/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_horizontal_logos.yml new file mode 100644 index 0000000000..4658b31703 --- /dev/null +++ b/web/profiles/custom/yalesites_profile/config/sync/responsive_image.styles.image_horizontal_logos.yml @@ -0,0 +1,27 @@ +uuid: 5a91f1a5-323d-4607-b493-7bcbed8e18db +langcode: en +status: true +dependencies: + config: + - image.style.3_1_300 + - image.style.3_1_400 + - image.style.3_1_500 + - image.style.3_1_600 + - image.style.3_1_700 +id: image_horizontal_logos +label: 'Image - Horizontal Logos' +image_style_mappings: + - + image_mapping_type: sizes + image_mapping: + sizes: '(min-width:556px) 500px, 100vw' + sizes_image_styles: + - '3_1_300' + - '3_1_400' + - '3_1_500' + - '3_1_600' + - '3_1_700' + breakpoint_id: responsive_image.viewport_sizing + multiplier: 1x +breakpoint_group: responsive_image +fallback_image_style: '3_1_300' From d8714f25b0a4d28487fb8c7fb71f6535d8c1c94d Mon Sep 17 00:00:00 2001 From: Joe Tower Date: Thu, 14 Sep 2023 10:01:33 -0500 Subject: [PATCH 8/9] fix(YALB-mega-footer-2): update footer settings div id top margin --- .../modules/custom/ys_core/css/footer-settings-form.css | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/web/profiles/custom/yalesites_profile/modules/custom/ys_core/css/footer-settings-form.css b/web/profiles/custom/yalesites_profile/modules/custom/ys_core/css/footer-settings-form.css index b8d0b1506b..bc1f5e7330 100644 --- a/web/profiles/custom/yalesites_profile/modules/custom/ys_core/css/footer-settings-form.css +++ b/web/profiles/custom/yalesites_profile/modules/custom/ys_core/css/footer-settings-form.css @@ -78,3 +78,7 @@ .form-item--footer-variation.form-type--radio input:focus + label { outline: 2px solid var(--wool); } + +#edit-footer-variation { + margin-top: 1rem; +} From 7d59a2a15569f46cf842722d340bc3f690391353 Mon Sep 17 00:00:00 2001 From: Marc Berger Date: Fri, 15 Sep 2023 10:50:58 -0700 Subject: [PATCH 9/9] feat: Allow restricted HTML to use paragraph tags --- .../config/sync/filter.format.restricted_html.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/profiles/custom/yalesites_profile/config/sync/filter.format.restricted_html.yml b/web/profiles/custom/yalesites_profile/config/sync/filter.format.restricted_html.yml index 0e6f6ffc65..788d23e1eb 100644 --- a/web/profiles/custom/yalesites_profile/config/sync/filter.format.restricted_html.yml +++ b/web/profiles/custom/yalesites_profile/config/sync/filter.format.restricted_html.yml @@ -14,7 +14,7 @@ filters: status: true weight: -10 settings: - allowed_html: ' ' + allowed_html: '

' filter_html_help: true filter_html_nofollow: false filter_autop: