From 2421e202274b0376b1e12ca16f586502a3d2830a Mon Sep 17 00:00:00 2001 From: sabrina-bongiovanni <116291154+sabrina-bongiovanni@users.noreply.github.com> Date: Tue, 30 Jan 2024 10:28:27 +0100 Subject: [PATCH 1/2] fix(subsites): changed select pill text color when theme is light (#494) * fix: subsite mixin styles * chore: added release.md info * Apply suggestions from code review Co-authored-by: Martina Bustacchini <41484878+deodorhunter@users.noreply.github.com> * fix: typo * fix: changed select pill text color when theme is light --------- Co-authored-by: Martina Bustacchini <41484878+deodorhunter@users.noreply.github.com> Co-authored-by: Piero Nicolli --- RELEASE.md | 1 + .../Subsites/ItaliaTheme/Blocks/_cta.scss | 9 ++++++++- .../ItaliaTheme/Blocks/_searchSections.scss | 9 +++++++-- .../ItaliaTheme/Subsites/ItaliaTheme/_common.scss | 15 +++++---------- src/theme/ItaliaTheme/Subsites/_mixin.scss | 8 +++++--- 5 files changed, 26 insertions(+), 16 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index 2434a01f7..fe98fb44d 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -45,6 +45,7 @@ ### Fix +- Sistemati problemi negli stili per i sottositi - Risolto un problema di visualizzazione degli argomenti indicati come altri argomenti nel blocco Argomenti quando il loro numero è esiguo - Sistemato il layout e la visualizzazione della vista del CT Cartella Modulistica per gestire al meglio gli elementi titolo, titolo del modulo e link al download in caso di testi lunghi, specialmente su mobile diff --git a/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_cta.scss b/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_cta.scss index 765ff5f3a..f8d760f35 100644 --- a/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_cta.scss +++ b/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_cta.scss @@ -1,6 +1,6 @@ @use '../../all_variables' as *; -@mixin block($subsite-secondary) { +@mixin block($subsite-secondary, $subsite-secondary-text) { .cta-block { .cta-block-wrapper { background-color: $subsite-secondary; @@ -8,6 +8,13 @@ &.has-image { background: none; } + + a { + color: $subsite-secondary-text; + } } } + .cms-ui .cta-block a { + color: $subsite-secondary-text; + } } diff --git a/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_searchSections.scss b/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_searchSections.scss index ae2759ca4..4e7a77fec 100644 --- a/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_searchSections.scss +++ b/src/theme/ItaliaTheme/Subsites/ItaliaTheme/Blocks/_searchSections.scss @@ -5,7 +5,8 @@ $subsite-primary-text, $subsite-secondary, $subsite-secondary-text, - $subsite-primary-a0 + $subsite-primary-a0, + $subsite-light-theme ) { .container .block { .searchSections { @@ -41,7 +42,11 @@ &.search { .search-wrapper .autocomplete-icon .icon { - fill: $subsite-primary; + @if $subsite-light-theme { + fill: $subsite-secondary; + } @else { + fill: $subsite-primary; + } } } } diff --git a/src/theme/ItaliaTheme/Subsites/ItaliaTheme/_common.scss b/src/theme/ItaliaTheme/Subsites/ItaliaTheme/_common.scss index 1a59abfe3..f2f4f46ff 100644 --- a/src/theme/ItaliaTheme/Subsites/ItaliaTheme/_common.scss +++ b/src/theme/ItaliaTheme/Subsites/ItaliaTheme/_common.scss @@ -57,7 +57,11 @@ color: $subsite-primary-text !important; } .select-pill.text-primary { - color: $subsite-primary !important; + @if ($subsite-light-theme) { + color: $subsite-link-color !important; + } @else { + color: $subsite-primary !important; + } div { color: inherit; @@ -83,15 +87,6 @@ } } - // icon external link - .external-link { - @if $subsite-light-theme { - fill: $subsite-link-color !important; - } @else { - fill: $subsite-primary !important; - } - } - .flag-icon { background: $subsite-secondary; } diff --git a/src/theme/ItaliaTheme/Subsites/_mixin.scss b/src/theme/ItaliaTheme/Subsites/_mixin.scss index 0eeb0bd93..4c6a8559c 100644 --- a/src/theme/ItaliaTheme/Subsites/_mixin.scss +++ b/src/theme/ItaliaTheme/Subsites/_mixin.scss @@ -129,7 +129,7 @@ $subsite-secondary-text ); @include it-contacts.block($subsite-primary, $subsite-primary-text); - @include it-cta.block($subsite-secondary); + @include it-cta.block($subsite-secondary, $subsite-secondary-text); @include it-form.block( $subsite-primary, $subsite-primary-text, @@ -169,7 +169,8 @@ $subsite-primary-text, $subsite-secondary, $subsite-secondary-text, - $subsite-primary-a0 + $subsite-primary-a0, + $subsite-light-theme ); @include it-table-contents.block($subsite-primary); @include it-views.common( @@ -206,7 +207,8 @@ #categoryCollapse .btn-icon.btn.btn-outline-secondary { border-color: $subsite-primary; - box-shadow: inset 0 0 0 1px $subsite-primary, + box-shadow: + inset 0 0 0 1px $subsite-primary, 0 0 0 0.2rem rgba(var($subsite-primary), 0.2); color: $subsite-primary; } From bb25a584c3be6020b8bbc70e0753fcc46b7e093d Mon Sep 17 00:00:00 2001 From: Martina Bustacchini <41484878+deodorhunter@users.noreply.github.com> Date: Tue, 30 Jan 2024 11:04:38 +0100 Subject: [PATCH 2/2] Bug 51182 visualizzazione card piccole grid gallery template (#495) * fix: grid gallery template layout and visual fixes, image is now contained and title does not overflow anymore --------- Co-authored-by: Piero Nicolli --- RELEASE.md | 1 + .../Blocks/Listing/GridGalleryTemplate.jsx | 30 +++++++++---------- 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index fe98fb44d..1146e2315 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -45,6 +45,7 @@ ### Fix +- Sistemato il layout del template Galliery a griglia per il blocco elenco, le immagini più piccole ora sono correttamente contenute dentro il loro riquadro e il titolo non fuoriesce più - Sistemati problemi negli stili per i sottositi - Risolto un problema di visualizzazione degli argomenti indicati come altri argomenti nel blocco Argomenti quando il loro numero è esiguo - Sistemato il layout e la visualizzazione della vista del CT Cartella Modulistica per gestire al meglio gli elementi diff --git a/src/components/ItaliaTheme/Blocks/Listing/GridGalleryTemplate.jsx b/src/components/ItaliaTheme/Blocks/Listing/GridGalleryTemplate.jsx index 0082980f5..1e21911ad 100644 --- a/src/components/ItaliaTheme/Blocks/Listing/GridGalleryTemplate.jsx +++ b/src/components/ItaliaTheme/Blocks/Listing/GridGalleryTemplate.jsx @@ -35,7 +35,6 @@ const GridGalleryTemplate = ({ linkmore_id_lighthouse, }) => { const intl = useIntl(); - return (
@@ -60,7 +59,6 @@ const GridGalleryTemplate = ({ item, className: '', }); - let scale = null; if (index % 7 === 0 || index % 7 === 6 || index % 7 === 3) { scale = 'great'; @@ -73,18 +71,16 @@ const GridGalleryTemplate = ({ } if (scale && item?.image?.scales?.[scale]) { image = ( - - - + ); } @@ -97,7 +93,11 @@ const GridGalleryTemplate = ({ item={!isEditMode ? item : null} href={isEditMode ? '#' : null} > - {image && image} + {image && ( + + {image} + + )}

{item.title}