From 44e53eaefb572e2c85d70e7ba760bcf91150cb0b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Munsch?= Date: Tue, 28 May 2024 09:41:11 +0200 Subject: [PATCH] fix: :bug: Cookie notice windows size variables could not be overriden --- src/scss/themes/standard.scss | 10 +++++++--- src/scss/variables.scss | 4 ++-- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/src/scss/themes/standard.scss b/src/scss/themes/standard.scss index 6b68088..ef9c3a7 100644 --- a/src/scss/themes/standard.scss +++ b/src/scss/themes/standard.scss @@ -57,6 +57,10 @@ $ck-color-list: $ck-secondary-color; $ck-color-title: $ck-secondary-color; $breakpoint-mobile: 535px; +/* Size */ +$cn-w-max-height-desktop: $cn-cookie-modal-max-height-desktop; +$cn-w-modal-width: $cn-cookie-modal-width; + %nav-button { display: flex; height: $cn-button-height; @@ -226,12 +230,12 @@ $breakpoint-mobile: 535px; right: $cn-cookie-animation-right; bottom: calc(#{$cn-cookie-button-position-bottom} + 60px); left: $cn-cookie-animation-left; - width: $cn-cookie-modal-width; - max-height: math.max(26rem, $cn-cookie-modal-max-height-desktop - 12rem); + width: $cn-w-modal-width; + max-height: #{math.max($cn-w-max-height-desktop - 12rem, 26rem)}; border-radius: 0.5rem; &.cn-modal-page { - max-height: $cn-cookie-modal-max-height-desktop; + max-height: $cn-w-max-height-desktop; } } diff --git a/src/scss/variables.scss b/src/scss/variables.scss index 6d79816..34efa01 100644 --- a/src/scss/variables.scss +++ b/src/scss/variables.scss @@ -61,6 +61,6 @@ $cn-switch-checked-color: #346abf !default; $cn-switch-focus-color: $cn-switch-checked-color!default; // Dimensions modal -$cn-cookie-modal-max-height-mobile: 100dvh; -$cn-cookie-modal-max-height-desktop: 38rem; +$cn-cookie-modal-max-height-mobile: 100dvh !default; +$cn-cookie-modal-max-height-desktop: 38rem !default; $cn-cookie-modal-width: 30rem !default;