diff --git a/blocks/v2-static-content-carousel/v2-static-content-carousel.css b/blocks/v2-static-content-carousel/v2-static-content-carousel.css index 7dbaac86..e00c4dec 100644 --- a/blocks/v2-static-content-carousel/v2-static-content-carousel.css +++ b/blocks/v2-static-content-carousel/v2-static-content-carousel.css @@ -96,6 +96,7 @@ .v2-static-content-carousel__button:disabled:hover { background: transparent; border: none; + border-radius: 4px; } .v2-static-content-carousel__button .icon-arrow-left svg, @@ -168,7 +169,7 @@ position: absolute; top: 0; pointer-events: none; - background: linear-gradient(90deg, rgb(255 255 255 / 0%) 0%, rgb(255 255 255 / 100%) 100%); + background: linear-gradient(90deg, rgb(255 255 255 / 0%) 0%, var(--background-gradient) 100%); right: 0; } } \ No newline at end of file diff --git a/blocks/v2-static-content-carousel/v2-static-content-carousel.js b/blocks/v2-static-content-carousel/v2-static-content-carousel.js index b8ad7ed0..4b1e307d 100644 --- a/blocks/v2-static-content-carousel/v2-static-content-carousel.js +++ b/blocks/v2-static-content-carousel/v2-static-content-carousel.js @@ -8,7 +8,7 @@ const updateActiveClass = (elements, targetElement, carousel) => { elements.forEach((el, index) => { if (el === targetElement) { el.classList.add('active'); - let arrowControl = document.querySelector(`.${blockName}__button:disabled`); + let arrowControl = carousel.nextElementSibling.querySelector(`.${blockName}__button:disabled`); if (arrowControl) { arrowControl.disabled = false; @@ -16,9 +16,9 @@ const updateActiveClass = (elements, targetElement, carousel) => { } // disable arrow buttons if (index === 0) { - arrowControl = document.querySelector(`.${blockName}__button-prev`); + arrowControl = carousel.nextElementSibling.querySelector(`.${blockName}__button-prev`); } else if (index === el.parentNode.children.length - 1) { - arrowControl = document.querySelector(`.${blockName}__button-next`); + arrowControl = carousel.nextElementSibling.querySelector(`.${blockName}__button-next`); } if (arrowControl) { arrowControl.disabled = true; diff --git a/styles/styles.css b/styles/styles.css index 37e2d0bd..81c33991 100644 --- a/styles/styles.css +++ b/styles/styles.css @@ -997,6 +997,7 @@ main.blue-contract .section.section-with-title p { --card-text: var(--c-main-black); --text-color: var(--c-main-black); --text-subtle: var(--c-grey-4); + --background-gradient: rgb(255 255 255 / 100%); font-size: 16px; } @@ -1050,6 +1051,7 @@ main.blue-contract .section.section-with-title p { --card-text: var(--c-white); --c-cta-blue-default: #44A1FF; --text-subtle: var(--c-grey-2); + --background-gradient: rgb(20 20 20 / 100%); color: var(--text-color); background-color: var(--c-main-black); @@ -1059,6 +1061,7 @@ main.blue-contract .section.section-with-title p { .section--gray-background { --card-background: var(--c-white); --card-text: var(--c-main-black); + --background-gradient: rgb(247 247 247 / 100%); background-color: var(--c-grey-50); }