Skip to content

Commit

Permalink
add single-slide classname to View
Browse files Browse the repository at this point in the history
  • Loading branch information
danalvrz committed Dec 19, 2023
1 parent e51a2fd commit 7fb6617
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/View.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,9 @@ const SliderView = (props) => {
return (
<>
<div
className={cx('block slider', className)}
className={cx('block slider', className, {
'single-slide': data.slides?.length === 1,
})}
style={{ '--slider-container-width': `${sliderContainerWidth}px` }}
>
{(data.slides?.length === 0 || !data.slides) && isEditMode && (
Expand Down

0 comments on commit 7fb6617

Please sign in to comment.