Skip to content

The Open Standard for Generative UI

Update Carousel component styles for improved layout and responsiveness (#189)

subham39f230e8752a
diff --git a/js/packages/react-ui/package.json b/js/packages/react-ui/package.json
index 62fed9edd..2040bb579 100644
--- a/js/packages/react-ui/package.json
+++ b/js/packages/react-ui/package.json
@@ -2,7 +2,7 @@
"type": "module",
"name": "@crayonai/react-ui",
"license": "MIT",
- "version": "0.8.25",
+ "version": "0.8.26",
"description": "Component library for Generative UI SDK",
"main": "dist/index.js",
"types": "dist/index.d.ts",
diff --git a/js/packages/react-ui/src/components/Carousel/carousel.scss b/js/packages/react-ui/src/components/Carousel/carousel.scss
index 57c83549b..01646d2c0 100644
--- a/js/packages/react-ui/src/components/Carousel/carousel.scss
+++ b/js/packages/react-ui/src/components/Carousel/carousel.scss
@@ -33,9 +33,9 @@
@include cssUtils.typography(body, default);
display: flex;
flex-direction: column;
- gap: cssUtils.$spacing-s;
- min-width: 200px;
- max-width: 200px;
+ gap: cssUtils.$spacing-m;
+ min-width: 280px;
+ max-width: 280px;
border-radius: cssUtils.$rounded-2xl;
background-color: cssUtils.$bg-container;
padding: cssUtils.$spacing-m;
@@ -61,4 +61,10 @@
right: -12px;
}
}
+ @media (max-width: 400px) {
+ .crayon-carousel-item {
+ min-width: 248px;
+ max-width: 248px;
+ }
+ }
}