File tree 2 files changed +11
-3
lines changed
clients/search-component/src/TrieveModal
2 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -82,17 +82,17 @@ export const Carousel = ({ children }: { children: React.ReactNode }) => {
82
82
return (
83
83
< div className = "carousel-root" >
84
84
< ul className = "carousel-scroll" ref = { scrollRef } >
85
- { allProductsCarousel . map ( ( child , index ) => child ? (
85
+ { allProductsCarousel . map ( ( child , index ) => (
86
86
< li
87
- className = "carousel-item"
87
+ className = { child ? "carousel-item carousel-item-visibile" : "carousel-item carousel-item-hidden" }
88
88
style = { {
89
89
width : `calc(100% / ${ itemsPerPage } )` ,
90
90
} }
91
91
key = { index }
92
92
>
93
93
{ child }
94
94
</ li >
95
- ) : null ) }
95
+ ) ) }
96
96
</ ul >
97
97
{ numPages > 1 && (
98
98
< div className = "carousel-controls" >
Original file line number Diff line number Diff line change @@ -336,6 +336,14 @@ body {
336
336
box-sizing : border-box;
337
337
}
338
338
339
+ .carousel-item-hidden {
340
+ visibility : hidden;
341
+ }
342
+
343
+ .carousel-item-visibile {
344
+ visibility : visible;
345
+ }
346
+
339
347
.carousel-controls {
340
348
display : flex;
341
349
justify-content : center;
You can’t perform that action at this time.
0 commit comments