Skip to content

Commit 483ab84

Browse files
committed
fix carousel layout
1 parent c2a60ee commit 483ab84

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/styles/block.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@
5454

5555
@include desktop-tablet {
5656
.stk-block:is(.aligncenter, .alignwide, .alignfull) > .stk-content-align:not(.alignwide):not(.alignfull),
57+
// Dev note: add selector for carousel because it has an extra wrapper before the inner blocks.
58+
.stk-block-carousel:is(.aligncenter, .alignwide, .alignfull) > :where(.stk-block-carousel__content-wrapper) > .stk-content-align:not(.alignwide):not(.alignfull),
5759
.stk-block .stk-block.aligncenter {
5860
// --stk-block-default-width is a Stackable setting
5961
// --stk-block-width-default-detected is from the fallback autodetected value.

src/styles/editor-block.scss

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,9 @@
104104

105105
// For wide/full width blocks, but with their contents center aligned.
106106
:where(:is(.stk-preview-device-desktop, .stk-preview-device-tablet) [data-type^="stackable/"]:is([data-align="wide"], [data-align="full"]) > .stk-block > .stk-inner-blocks:not(.alignwide):not(.alignfull)),
107-
:where(:is(.stk-preview-device-desktop, .stk-preview-device-tablet) [data-type^="stackable/"]:is([data-align="wide"], [data-align="full"]) [data-type^="stackable/"][data-align="center"]) {
107+
:where(:is(.stk-preview-device-desktop, .stk-preview-device-tablet) [data-type^="stackable/"]:is([data-align="wide"], [data-align="full"]) [data-type^="stackable/"][data-align="center"]),
108+
// Dev note: add selector for carousel because it has an extra wrapper before the inner blocks.
109+
:where(:is(.stk-preview-device-desktop, .stk-preview-device-tablet) [data-type^="stackable/"]:is([data-align="wide"], [data-align="full"]) > .stk-block-carousel > :where(.stk-block-carousel__content-wrapper) > .stk-inner-blocks:not(.alignwide):not(.alignfull)) {
108110
// --stk-block-default-width is a Stackable setting
109111
// --stk-block-width-default-detected is from the fallback autodetected value.
110112
max-width: var(--stk-block-default-width, var(--stk-block-width-default-detected, 900px)) !important;

0 commit comments

Comments
 (0)