@smg-automotive/components 25.11.0-dgajin-vsst-4352-migrate-carousel.2 → 25.11.0-dgajin-vsst-4352-migrate-carousel.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/carousel/DotsPagination.d.ts +1 -1
- package/dist/cjs/components/carousel/DotsPagination.d.ts.map +1 -1
- package/dist/cjs/components/carousel/DotsPaginationIndicator.d.ts.map +1 -1
- package/dist/cjs/components/carousel/NumbersPaginationButton.d.ts.map +1 -1
- package/dist/cjs/index.js +26 -25
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/themes/shared/index.d.ts +1 -1
- package/dist/cjs/themes/shared/slotRecipes/carousel.d.ts +1 -1
- package/dist/cjs/themes/shared/slotRecipes/carousel.d.ts.map +1 -1
- package/dist/cjs/themes/shared/slotRecipes/index.d.ts +1 -1
- package/dist/esm/components/carousel/DotsPagination.d.ts +1 -1
- package/dist/esm/components/carousel/DotsPagination.d.ts.map +1 -1
- package/dist/esm/components/carousel/DotsPagination.js +2 -2
- package/dist/esm/components/carousel/DotsPagination.js.map +1 -1
- package/dist/esm/components/carousel/DotsPaginationIndicator.d.ts.map +1 -1
- package/dist/esm/components/carousel/DotsPaginationIndicator.js +1 -3
- package/dist/esm/components/carousel/DotsPaginationIndicator.js.map +1 -1
- package/dist/esm/components/carousel/NumbersPaginationButton.d.ts.map +1 -1
- package/dist/esm/components/carousel/NumbersPaginationButton.js +1 -3
- package/dist/esm/components/carousel/NumbersPaginationButton.js.map +1 -1
- package/dist/esm/components/carousel/index.js +2 -2
- package/dist/esm/components/carousel/index.js.map +1 -1
- package/dist/esm/themes/shared/index.d.ts +1 -1
- package/dist/esm/themes/shared/slotRecipes/carousel.d.ts +1 -1
- package/dist/esm/themes/shared/slotRecipes/carousel.d.ts.map +1 -1
- package/dist/esm/themes/shared/slotRecipes/carousel.js +22 -18
- package/dist/esm/themes/shared/slotRecipes/carousel.js.map +1 -1
- package/dist/esm/themes/shared/slotRecipes/index.d.ts +1 -1
- package/dist/index.d.ts +5 -5
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DotsPagination.d.ts","sourceRoot":"","sources":["../../../../src/components/carousel/DotsPagination.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAQlC,UAAU,KAAK;IACb,iBAAiB,EAAE,MAAM,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,eAAO,MAAM,
|
|
1
|
+
{"version":3,"file":"DotsPagination.d.ts","sourceRoot":"","sources":["../../../../src/components/carousel/DotsPagination.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAQlC,UAAU,KAAK;IACb,iBAAiB,EAAE,MAAM,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,eAAO,MAAM,cAAc,EAAE,EAAE,CAAC,KAAK,CAoBpC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DotsPaginationIndicator.d.ts","sourceRoot":"","sources":["../../../../src/components/carousel/DotsPaginationIndicator.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAGlC,UAAU,eAAe;IACvB,SAAS,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,uBAAuB,EAAE,EAAE,CAAC,eAAe,
|
|
1
|
+
{"version":3,"file":"DotsPaginationIndicator.d.ts","sourceRoot":"","sources":["../../../../src/components/carousel/DotsPaginationIndicator.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAGlC,UAAU,eAAe;IACvB,SAAS,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,uBAAuB,EAAE,EAAE,CAAC,eAAe,CAUvD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NumbersPaginationButton.d.ts","sourceRoot":"","sources":["../../../../src/components/carousel/NumbersPaginationButton.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAGlC,UAAU,KAAK;IACb,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,SAAS,EAAE,OAAO,CAAC;IACnB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,eAAO,MAAM,uBAAuB,EAAE,EAAE,CAAC,KAAK,
|
|
1
|
+
{"version":3,"file":"NumbersPaginationButton.d.ts","sourceRoot":"","sources":["../../../../src/components/carousel/NumbersPaginationButton.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAGlC,UAAU,KAAK;IACb,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,SAAS,EAAE,OAAO,CAAC;IACnB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,eAAO,MAAM,uBAAuB,EAAE,EAAE,CAAC,KAAK,CAmB7C,CAAC"}
|
package/dist/cjs/index.js
CHANGED
|
@@ -2535,9 +2535,7 @@ var slots = [
|
|
|
2535
2535
|
'paginationIconContainer',
|
|
2536
2536
|
'dotsPaginationContainer',
|
|
2537
2537
|
'dotsPaginationIndicator',
|
|
2538
|
-
'dotsPaginationIndicatorActive',
|
|
2539
2538
|
'numbersPaginationButton',
|
|
2540
|
-
'numbersPaginationButtonActive',
|
|
2541
2539
|
];
|
|
2542
2540
|
var baseContainer = react$1.defineStyle({
|
|
2543
2541
|
height: 'full',
|
|
@@ -2608,10 +2606,14 @@ var numbersPaginationButton = react$1.defineStyle({
|
|
|
2608
2606
|
_hover: {
|
|
2609
2607
|
backgroundColor: 'gray.100',
|
|
2610
2608
|
},
|
|
2611
|
-
|
|
2612
|
-
|
|
2609
|
+
'&[aria-current="true"]': {
|
|
2610
|
+
color: 'white',
|
|
2613
2611
|
backgroundColor: 'gray.900',
|
|
2614
|
-
|
|
2612
|
+
_hover: {
|
|
2613
|
+
backgroundColor: 'gray.900',
|
|
2614
|
+
},
|
|
2615
|
+
},
|
|
2616
|
+
});
|
|
2615
2617
|
var dotsPaginationIndicator = react$1.defineStyle({
|
|
2616
2618
|
backgroundColor: 'transparent',
|
|
2617
2619
|
touchAction: 'pan-x',
|
|
@@ -2639,23 +2641,28 @@ var dotsPaginationIndicator = react$1.defineStyle({
|
|
|
2639
2641
|
height: 'var(--carousel-dot-size)',
|
|
2640
2642
|
content: '""',
|
|
2641
2643
|
},
|
|
2642
|
-
|
|
2643
|
-
var dotsPaginationIndicatorActive = react$1.defineStyle(__assign(__assign({}, dotsPaginationIndicator), { width: 'var(--carousel-dot-size-active)', height: 'var(--carousel-dot-size-active)', _last: {
|
|
2644
|
+
'&[aria-current="true"]': {
|
|
2644
2645
|
width: 'var(--carousel-dot-size-active)',
|
|
2645
2646
|
height: 'var(--carousel-dot-size-active)',
|
|
2647
|
+
_last: {
|
|
2648
|
+
width: 'var(--carousel-dot-size-active)',
|
|
2649
|
+
height: 'var(--carousel-dot-size-active)',
|
|
2650
|
+
_after: {
|
|
2651
|
+
width: 'full',
|
|
2652
|
+
height: 'var(--carousel-dot-size-active)',
|
|
2653
|
+
content: '""',
|
|
2654
|
+
},
|
|
2655
|
+
},
|
|
2646
2656
|
_after: {
|
|
2657
|
+
backgroundColor: 'white',
|
|
2658
|
+
borderRadius: 'full',
|
|
2659
|
+
opacity: '100',
|
|
2647
2660
|
width: 'full',
|
|
2648
2661
|
height: 'var(--carousel-dot-size-active)',
|
|
2649
2662
|
content: '""',
|
|
2650
2663
|
},
|
|
2651
|
-
},
|
|
2652
|
-
|
|
2653
|
-
borderRadius: 'full',
|
|
2654
|
-
opacity: '100',
|
|
2655
|
-
width: 'full',
|
|
2656
|
-
height: 'var(--carousel-dot-size-active)',
|
|
2657
|
-
content: '""',
|
|
2658
|
-
} }));
|
|
2664
|
+
},
|
|
2665
|
+
});
|
|
2659
2666
|
var fullScreenVariant = {
|
|
2660
2667
|
container: react$1.defineStyle({
|
|
2661
2668
|
backgroundColor: 'black',
|
|
@@ -2727,7 +2734,6 @@ var carouselRecipe = react$1.defineSlotRecipe({
|
|
|
2727
2734
|
button: baseButton,
|
|
2728
2735
|
icon: baseIcon,
|
|
2729
2736
|
numbersPaginationButton: numbersPaginationButton,
|
|
2730
|
-
numbersPaginationButtonActive: numbersPaginationButtonActive,
|
|
2731
2737
|
dotsPaginationContainer: react$1.defineStyle({
|
|
2732
2738
|
position: 'absolute',
|
|
2733
2739
|
width: 'full',
|
|
@@ -2737,7 +2743,6 @@ var carouselRecipe = react$1.defineSlotRecipe({
|
|
|
2737
2743
|
alignItems: 'center',
|
|
2738
2744
|
}),
|
|
2739
2745
|
dotsPaginationIndicator: dotsPaginationIndicator,
|
|
2740
|
-
dotsPaginationIndicatorActive: dotsPaginationIndicatorActive,
|
|
2741
2746
|
},
|
|
2742
2747
|
variants: {
|
|
2743
2748
|
variant: {
|
|
@@ -11279,9 +11284,7 @@ var NumbersPaginationButton = function (_a) {
|
|
|
11279
11284
|
var onClick = _a.onClick, isCurrent = _a.isCurrent, currentPageNumber = _a.currentPageNumber, totalNumbers = _a.totalNumbers;
|
|
11280
11285
|
var recipe = react$1.useSlotRecipe({ key: 'carousel' });
|
|
11281
11286
|
var styles = recipe();
|
|
11282
|
-
return (React.createElement(react$1.chakra.button, { css: isCurrent
|
|
11283
|
-
? styles.numbersPaginationButtonActive
|
|
11284
|
-
: styles.numbersPaginationButton, onClick: onClick, "aria-current": isCurrent, "aria-label": "numbers pagination ".concat(currentPageNumber, " of ").concat(totalNumbers) }, currentPageNumber));
|
|
11287
|
+
return (React.createElement(react$1.chakra.button, { css: styles.numbersPaginationButton, onClick: onClick, "aria-current": isCurrent, "aria-label": "numbers pagination ".concat(currentPageNumber, " of ").concat(totalNumbers) }, currentPageNumber));
|
|
11285
11288
|
};
|
|
11286
11289
|
|
|
11287
11290
|
var NumbersPagination = function (_a) {
|
|
@@ -11313,12 +11316,10 @@ var DotsPaginationIndicator = function (_a) {
|
|
|
11313
11316
|
var isCurrent = _a.isCurrent;
|
|
11314
11317
|
var recipe = react$1.useSlotRecipe({ key: 'carousel' });
|
|
11315
11318
|
var styles = recipe();
|
|
11316
|
-
return (React.createElement(react$1.chakra.span, { css:
|
|
11317
|
-
? styles.dotsPaginationIndicatorActive
|
|
11318
|
-
: styles.dotsPaginationIndicator }));
|
|
11319
|
+
return (React.createElement(react$1.chakra.span, { "aria-current": isCurrent, css: styles.dotsPaginationIndicator }));
|
|
11319
11320
|
};
|
|
11320
11321
|
|
|
11321
|
-
var
|
|
11322
|
+
var DotsPagination = function (_a) {
|
|
11322
11323
|
var currentSlideIndex = _a.currentSlideIndex, numberOfSlides = _a.numberOfSlides;
|
|
11323
11324
|
var pagination = Array.from({ length: numberOfSlides }, function (_, i) { return i; });
|
|
11324
11325
|
var recipe = react$1.useSlotRecipe({ key: 'carousel' });
|
|
@@ -11455,7 +11456,7 @@ var Carousel = function (props) {
|
|
|
11455
11456
|
React.createElement(Flex, { css: styles.slideContainer, marginLeft: slidesPerView === 1 ? '0' : { base: '-md', md: '-2xl' } }, props.children.map(function (slide, index) { return (React.createElement(Slide, { key: "slide-".concat(index), slideIndex: index, onClick: function () { return onClick(index); }, totalSlides: numberOfSlides, isCurrent: index === selectedIndex, fullScreen: !!fullScreen, slidesPerView: slidesPerView }, isFullScreenSlide(slide) ? slide.slide : slide)); })),
|
|
11456
11457
|
canScrollPrevious ? (React.createElement(NavigationButton, { onClick: scrollPrev, direction: "previous", fullScreen: !!fullScreen, isHovered: isHovered || (!!fullScreen && !isSmallLandscapeViewport) })) : null,
|
|
11457
11458
|
canScrollNext ? (React.createElement(NavigationButton, { onClick: scrollNext, direction: "next", fullScreen: !!fullScreen, isHovered: isHovered || (!!fullScreen && !isSmallLandscapeViewport) })) : null,
|
|
11458
|
-
paginationType === exports.PaginationType.Dot ? (React.createElement(
|
|
11459
|
+
paginationType === exports.PaginationType.Dot ? (React.createElement(DotsPagination, { currentSlideIndex: selectedIndex, numberOfSlides: props.children.length })) : null)),
|
|
11459
11460
|
hasThumbnailPagination ? (React.createElement(ThumbnailPagination, { currentSlideIndex: selectedIndex, thumbnails: props.children.map(function (slide) { return slide.thumbnail; }), mainCarousel: mainCarousel, paginationCarousel: paginationCarousel, paginationCarouselRef: paginationCarouselRef })) : null,
|
|
11460
11461
|
paginationType === exports.PaginationType.Number ? (React.createElement(NumbersPagination, { mainCarousel: mainCarousel, currentSlideIndex: selectedIndex, numberOfSlides: props.children.length })) : null));
|
|
11461
11462
|
};
|