@gem-sdk/components 4.0.0-staging.1203 → 4.0.0-staging.1205
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/builder.js +1 -1
- package/dist/cjs/carousel/components/arrow/common/classes.js +1 -1
- package/dist/cjs/carousel/components/arrow/common/helpers.js +1 -1
- package/dist/cjs/carousel/components/arrow/common/styles.js +11 -11
- package/dist/cjs/carousel/components/dot/common/helpers.js +1 -1
- package/dist/cjs/carousel/components/item/CarouselItem.js +1 -1
- package/dist/cjs/carousel/components/item/common/styles.js +1 -1
- package/dist/cjs/carousel/components/root/Carousel.js +1 -1
- package/dist/cjs/carousel/components/root/Carousel.liquid.js +6 -8
- package/dist/cjs/carousel/components/root/common/attrs.js +1 -1
- package/dist/cjs/carousel/components/root/common/classes.js +1 -1
- package/dist/cjs/carousel/components/root/common/styles.js +1 -1
- package/dist/cjs/carousel/hooks/useCarousel.js +1 -1
- package/dist/cjs/carousel/hooks/useDotsSetting.js +1 -1
- package/dist/cjs/carousel/index.js +1 -1
- package/dist/cjs/carousel/plugins/animation.js +1 -1
- package/dist/cjs/carousel/plugins/auto-play.js +1 -0
- package/dist/cjs/carousel/plugins/fix-slider-move-backward.js +1 -0
- package/dist/cjs/carousel/plugins/mutation.js +1 -0
- package/dist/cjs/carousel/settings/configs/presets.js +4 -4
- package/dist/cjs/carousel/settings/configs/settings-v2.js +1 -1
- package/dist/cjs/carousel-v3/common/helpers.js +1 -0
- package/dist/cjs/carousel-v3/components/arrow/Arrow.js +10 -0
- package/dist/cjs/carousel-v3/components/arrow/Arrow.liquid.js +26 -0
- package/dist/cjs/carousel-v3/components/arrow/common/classes.js +1 -0
- package/dist/cjs/carousel-v3/components/arrow/common/helpers.js +1 -0
- package/dist/cjs/carousel-v3/components/arrow/common/styles.js +33 -0
- package/dist/cjs/carousel-v3/components/dot/Dots.js +2 -0
- package/dist/cjs/carousel-v3/components/dot/Dots.liquid.js +7 -0
- package/dist/cjs/carousel-v3/components/dot/common/classes.js +1 -0
- package/dist/cjs/carousel-v3/components/dot/common/helpers.js +1 -0
- package/dist/cjs/carousel-v3/components/dot/common/styles.js +1 -0
- package/dist/cjs/carousel-v3/components/item/CarouselItem.js +2 -0
- package/dist/cjs/carousel-v3/components/item/CarouselItem.liquid.js +22 -0
- package/dist/cjs/carousel-v3/components/item/common/classes.js +1 -0
- package/dist/cjs/carousel-v3/components/item/common/styles.js +1 -0
- package/dist/cjs/carousel-v3/components/root/Carousel.js +2 -0
- package/dist/cjs/carousel-v3/components/root/Carousel.liquid.js +23 -0
- package/dist/cjs/carousel-v3/components/root/common/attrs.js +1 -0
- package/dist/cjs/carousel-v3/components/root/common/classes.js +1 -0
- package/dist/cjs/carousel-v3/components/root/common/helpers.js +1 -0
- package/dist/cjs/carousel-v3/components/root/common/styles.js +1 -0
- package/dist/cjs/carousel-v3/components/swiper/Swiper.js +1 -0
- package/dist/cjs/carousel-v3/hooks/useCarouseItem.js +1 -0
- package/dist/cjs/carousel-v3/hooks/useCarousel.js +1 -0
- package/dist/cjs/carousel-v3/hooks/useDotsSetting.js +1 -0
- package/dist/cjs/carousel-v3/hooks/useTrackPreviewPause.js +1 -0
- package/dist/cjs/carousel-v3/index.js +1 -0
- package/dist/cjs/{carousel → carousel-v3}/next.js +1 -1
- package/dist/cjs/carousel-v3/plugins/animation.js +1 -0
- package/dist/cjs/carousel-v3/settings/Carousel.js +5 -0
- package/dist/cjs/carousel-v3/settings/CarouselItem.js +1 -0
- package/dist/cjs/carousel-v3/settings/configs/presets.js +114 -0
- package/dist/cjs/carousel-v3/settings/configs/settings-v2.js +3 -0
- package/dist/cjs/carousel-v3/settings/configs/ui-v1.js +1 -0
- package/dist/cjs/carousel-v3/settings/configs/ui-v2.js +1 -0
- package/dist/cjs/grid/components/row/common/helpers.js +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/index.liquid.js +1 -1
- package/dist/cjs/marquee/hooks/useMarqueeScrollToItem.js +1 -1
- package/dist/cjs/marquee/settings/Marquee.js +1 -1
- package/dist/cjs/next.js +1 -1
- package/dist/cjs/product/components/product-images/ProductGalleryCarousel.js +1 -1
- package/dist/cjs/product/components/product-images/ProductGalleryCarousel.liquid.js +1 -1
- package/dist/cjs/product/components/product-images/ProductImagesLightBox.js +1 -1
- package/dist/cjs/product/components/product-images-v2/ProductImagesV2.liquid.js +6 -6
- package/dist/cjs/product/components/product-images-v2/common/attrs.js +1 -1
- package/dist/cjs/product/components/product-images-v2/common/classes.js +1 -1
- package/dist/cjs/product/components/product-images-v2/common/common.js +1 -1
- package/dist/cjs/product/components/product-images-v2/common/getBorderActiveCss.js +1 -5
- package/dist/cjs/product/components/product-images-v2/common/productFeaturedImage.js +1 -1
- package/dist/cjs/product/components/product-images-v2/common/productGallery.js +1 -1
- package/dist/cjs/product/components/product-images-v2/common/styles.js +1 -1
- package/dist/cjs/product/components/product-images-v2/components/child/ProductFeaturedImageCarousel.js +1 -1
- package/dist/cjs/product/components/product-images-v2/components/child/ProductGalleryGrid.js +2 -2
- package/dist/cjs/product/components/product-images-v2/components/feature-gallery/FeatureImageWithGallery.js +1 -1
- package/dist/cjs/product/components/product-images-v2/components/feature-gallery/FeatureImageWithGallery.liquid.js +13 -13
- package/dist/cjs/product/components/product-images-v2/components/gallery-carousel/GalleryCarousel.js +1 -1
- package/dist/cjs/product/components/product-images-v2/components/gallery-carousel/GalleryCarousel.liquid.js +7 -7
- package/dist/cjs/product/components/product-images-v2/components/gallery-grid/GalleryGrid.js +1 -1
- package/dist/cjs/product/components/product-images-v2/components/gallery-grid/GalleryGrid.liquid.js +4 -4
- package/dist/cjs/product/components/product-images-v2/components/lightbox/ProductImagesLightBox.js +1 -1
- package/dist/cjs/product/components/product-images-v2/hooks/useProductGalleryGrid.js +1 -1
- package/dist/cjs/product/components/product-images-v3/ProductImageV2.js +26 -0
- package/dist/cjs/product/components/product-images-v3/ProductImagesV2.liquid.js +44 -0
- package/dist/cjs/product/components/product-images-v3/common/attrs.js +1 -0
- package/dist/cjs/product/components/product-images-v3/common/classes.js +1 -0
- package/dist/cjs/product/components/product-images-v3/common/common.js +1 -0
- package/dist/cjs/product/components/product-images-v3/common/getBorderActiveCss.js +20 -0
- package/dist/cjs/product/components/product-images-v3/common/hoverAction.js +1 -0
- package/dist/cjs/product/components/product-images-v3/common/productFeaturedImage.js +1 -0
- package/dist/cjs/product/components/product-images-v3/common/productGallery.js +1 -0
- package/dist/cjs/product/components/product-images-v3/common/styles.js +1 -0
- package/dist/cjs/product/components/product-images-v3/components/child/MediaIcon.js +2 -0
- package/dist/cjs/product/components/product-images-v3/components/child/ProductFeatureVideo.js +1 -0
- package/dist/cjs/product/components/product-images-v3/components/child/ProductFeaturedImageCarousel.js +1 -0
- package/dist/cjs/product/components/product-images-v3/components/child/ProductFeaturedImageOnly.js +2 -0
- package/dist/cjs/product/components/product-images-v3/components/child/ProductGalleryGrid.js +2 -0
- package/dist/cjs/product/components/product-images-v3/components/feature-gallery/FeatureImageWithGallery.js +1 -0
- package/dist/cjs/product/components/product-images-v3/components/feature-gallery/FeatureImageWithGallery.liquid.js +118 -0
- package/dist/cjs/product/components/product-images-v3/components/feature-only/OnlyFeatureImage.js +2 -0
- package/dist/cjs/product/components/product-images-v3/components/gallery-carousel/GalleryCarousel.js +1 -0
- package/dist/cjs/product/components/product-images-v3/components/gallery-carousel/GalleryCarousel.liquid.js +46 -0
- package/dist/cjs/product/components/product-images-v3/components/gallery-grid/GalleryGrid.js +2 -0
- package/dist/cjs/product/components/product-images-v3/components/gallery-grid/GalleryGrid.liquid.js +93 -0
- package/dist/cjs/product/components/product-images-v3/components/lightbox/ButtonOpenLightBox.js +2 -0
- package/dist/cjs/product/components/product-images-v3/components/lightbox/ProductImagesLightBox.js +2 -0
- package/dist/cjs/product/components/product-images-v3/composables/getProductImagesAttr.js +1 -0
- package/dist/cjs/product/components/product-images-v3/composables/getProductImagesClassName.js +1 -0
- package/dist/cjs/product/components/product-images-v3/composables/getProductImagesStyles.js +1 -0
- package/dist/cjs/product/components/product-images-v3/hooks/useFeatureImageWithGallery.js +1 -0
- package/dist/cjs/product/components/product-images-v3/hooks/useFilterImagesByVariant.js +1 -0
- package/dist/cjs/product/components/product-images-v3/hooks/useGalleryCarousel.js +1 -0
- package/dist/cjs/product/components/product-images-v3/hooks/useProductFeaturedImageCarousel.js +1 -0
- package/dist/cjs/product/components/product-images-v3/hooks/useProductGalleryGrid.js +1 -0
- package/dist/cjs/product/components/product-list/ProductListCarouselLayout.liquid.js +4 -4
- package/dist/cjs/product/components/product-list-v3/ProductList.js +1 -0
- package/dist/cjs/product/components/product-list-v3/ProductList.liquid.js +205 -0
- package/dist/cjs/product/components/product-list-v3/ProductListCarouselItem.liquid.js +15 -0
- package/dist/cjs/product/components/product-list-v3/ProductListCarouselLayout.js +1 -0
- package/dist/cjs/product/components/product-list-v3/ProductListCarouselLayout.liquid.js +22 -0
- package/dist/cjs/product/components/product-list-v3/ProductListGridItem.liquid.js +19 -0
- package/dist/cjs/product/components/product-list-v3/ProductListGridLayout.js +1 -0
- package/dist/cjs/product/components/product-list-v3/ProductListGridLayout.liquid.js +34 -0
- package/dist/cjs/product/components/product-list-v3/common/attrs.js +1 -0
- package/dist/cjs/product/components/product-list-v3/common/classes.js +1 -0
- package/dist/cjs/product/components/product-list-v3/common/helpers.js +1 -0
- package/dist/cjs/product/components/product-list-v3/common/styles.js +1 -0
- package/dist/cjs/product/index.js +1 -1
- package/dist/cjs/product/next.js +1 -1
- package/dist/cjs/product/settings/ProductListV3.js +8 -0
- package/dist/cjs/product/settings/product/configs/product-presets/product-1-col.js +2 -2
- package/dist/cjs/product/settings/product/configs/product-presets/product-2-col.js +2 -2
- package/dist/cjs/product/settings/product/configs/product-presets/product-default.js +2 -2
- package/dist/cjs/product/settings/product-image-v2/ProductImages.js +2 -2
- package/dist/cjs/product/settings/product-image-v2/configs/setting-v2/ProductFeatureImage.js +1 -1
- package/dist/cjs/product/settings/product-image-v2/configs/setting-v2/ProductGalleryImage.js +3 -2
- package/dist/cjs/product/settings/product-image-v2/configs/ui/FeatureNavigation.js +1 -1
- package/dist/cjs/product/settings/product-image-v2/configs/ui/ImageListNavigation.js +1 -1
- package/dist/cjs/product/settings/product-image-v2/configs/ui-v2.js +1 -1
- package/dist/cjs/product/settings/product-image-v3/ProductFeatureImage.js +1 -0
- package/dist/cjs/product/settings/product-image-v3/ProductGalleryImage.js +1 -0
- package/dist/cjs/product/settings/product-image-v3/ProductImages.js +21 -0
- package/dist/cjs/product/settings/product-image-v3/configs/setting-v2/ProductFeatureImage.js +2 -0
- package/dist/cjs/product/settings/product-image-v3/configs/setting-v2/ProductGalleryImage.js +2 -0
- package/dist/cjs/product/settings/product-image-v3/configs/setting-v2/index.js +1 -0
- package/dist/cjs/product/settings/product-image-v3/configs/ui/FeatureDots.js +1 -0
- package/dist/cjs/product/settings/product-image-v3/configs/ui/FeatureNavigation.js +1 -0
- package/dist/cjs/product/settings/product-image-v3/configs/ui/ImageListNavigation.js +1 -0
- package/dist/cjs/product/settings/product-image-v3/configs/ui-v1.js +1 -0
- package/dist/cjs/product/settings/product-image-v3/configs/ui-v2.js +1 -0
- package/dist/cjs/product/settings/product-list/configs/presets.js +2 -2
- package/dist/cjs/product/settings/product-list/configs/settings-v2.js +1 -1
- package/dist/cjs/product/settings/product-list-v3/configs/presets.js +37 -0
- package/dist/cjs/product/settings/product-list-v3/configs/settings-v2.js +1 -0
- package/dist/cjs/product/settings/product-list-v3/configs/ui-v1.js +1 -0
- package/dist/cjs/product/settings/product-list-v3/configs/ui-v2.js +1 -0
- package/dist/cjs/setting.js +1 -1
- package/dist/cjs/third-party/components/BloyRewardsProgramLoyalty.js +2 -0
- package/dist/cjs/third-party/components/BloyRewardsProgramLoyalty.liquid.js +1 -0
- package/dist/cjs/third-party/components/UppromoteAffiliateMarketing.liquid.js +89 -1
- package/dist/cjs/third-party/configs/BloyRewardsProgramLoyalty.js +1 -0
- package/dist/cjs/third-party/index.js +1 -1
- package/dist/cjs/third-party/next.js +1 -1
- package/dist/cjs/third-party/settings/BloyRewardsProgramLoyalty/index.js +4 -0
- package/dist/cjs/third-party/settings/BloyRewardsProgramLoyalty/uiV2.js +1 -0
- package/dist/cjs/third-party/settings/KoalaBundleQuantityDiscount/index.js +1 -1
- package/dist/esm/builder.js +1 -1
- package/dist/esm/carousel/components/arrow/common/classes.js +1 -1
- package/dist/esm/carousel/components/arrow/common/helpers.js +1 -1
- package/dist/esm/carousel/components/arrow/common/styles.js +8 -8
- package/dist/esm/carousel/components/dot/common/helpers.js +1 -1
- package/dist/esm/carousel/components/item/CarouselItem.js +1 -1
- package/dist/esm/carousel/components/item/common/styles.js +1 -1
- package/dist/esm/carousel/components/root/Carousel.js +1 -1
- package/dist/esm/carousel/components/root/Carousel.liquid.js +7 -9
- package/dist/esm/carousel/components/root/common/attrs.js +1 -1
- package/dist/esm/carousel/components/root/common/classes.js +1 -1
- package/dist/esm/carousel/components/root/common/styles.js +1 -1
- package/dist/esm/carousel/hooks/useCarousel.js +1 -1
- package/dist/esm/carousel/hooks/useDotsSetting.js +1 -1
- package/dist/esm/carousel/index.js +1 -1
- package/dist/esm/carousel/plugins/animation.js +1 -1
- package/dist/esm/carousel/plugins/auto-play.js +1 -0
- package/dist/esm/carousel/plugins/fix-slider-move-backward.js +1 -0
- package/dist/esm/carousel/plugins/mutation.js +1 -0
- package/dist/esm/carousel/settings/configs/presets.js +4 -4
- package/dist/esm/carousel/settings/configs/settings-v2.js +1 -1
- package/dist/esm/carousel-v3/common/helpers.js +1 -0
- package/dist/esm/carousel-v3/components/arrow/Arrow.js +10 -0
- package/dist/esm/carousel-v3/components/arrow/Arrow.liquid.js +26 -0
- package/dist/esm/carousel-v3/components/arrow/common/classes.js +1 -0
- package/dist/esm/carousel-v3/components/arrow/common/helpers.js +1 -0
- package/dist/esm/carousel-v3/components/arrow/common/styles.js +33 -0
- package/dist/esm/carousel-v3/components/dot/Dots.js +2 -0
- package/dist/esm/carousel-v3/components/dot/Dots.liquid.js +7 -0
- package/dist/esm/carousel-v3/components/dot/common/classes.js +1 -0
- package/dist/esm/carousel-v3/components/dot/common/helpers.js +1 -0
- package/dist/esm/carousel-v3/components/dot/common/styles.js +1 -0
- package/dist/esm/carousel-v3/components/item/CarouselItem.js +2 -0
- package/dist/esm/carousel-v3/components/item/CarouselItem.liquid.js +22 -0
- package/dist/esm/carousel-v3/components/item/common/classes.js +1 -0
- package/dist/esm/carousel-v3/components/item/common/styles.js +1 -0
- package/dist/esm/carousel-v3/components/root/Carousel.js +2 -0
- package/dist/esm/carousel-v3/components/root/Carousel.liquid.js +23 -0
- package/dist/esm/carousel-v3/components/root/common/attrs.js +1 -0
- package/dist/esm/carousel-v3/components/root/common/classes.js +1 -0
- package/dist/esm/carousel-v3/components/root/common/helpers.js +1 -0
- package/dist/esm/carousel-v3/components/root/common/styles.js +1 -0
- package/dist/esm/carousel-v3/components/swiper/Swiper.js +1 -0
- package/dist/esm/carousel-v3/hooks/useCarouseItem.js +1 -0
- package/dist/esm/carousel-v3/hooks/useCarousel.js +1 -0
- package/dist/esm/carousel-v3/hooks/useDotsSetting.js +1 -0
- package/dist/esm/carousel-v3/hooks/useTrackPreviewPause.js +1 -0
- package/dist/esm/carousel-v3/index.js +1 -0
- package/dist/esm/{carousel → carousel-v3}/next.js +1 -1
- package/dist/esm/carousel-v3/plugins/animation.js +1 -0
- package/dist/esm/carousel-v3/settings/Carousel.js +5 -0
- package/dist/esm/carousel-v3/settings/CarouselItem.js +1 -0
- package/dist/esm/carousel-v3/settings/configs/presets.js +114 -0
- package/dist/esm/carousel-v3/settings/configs/settings-v2.js +3 -0
- package/dist/esm/carousel-v3/settings/configs/ui-v1.js +1 -0
- package/dist/esm/carousel-v3/settings/configs/ui-v2.js +1 -0
- package/dist/esm/grid/components/row/common/helpers.js +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.liquid.js +1 -1
- package/dist/esm/marquee/hooks/useMarqueeScrollToItem.js +1 -1
- package/dist/esm/marquee/settings/Marquee.js +1 -1
- package/dist/esm/next.js +1 -1
- package/dist/esm/product/components/product-images/ProductGalleryCarousel.js +1 -1
- package/dist/esm/product/components/product-images/ProductGalleryCarousel.liquid.js +1 -1
- package/dist/esm/product/components/product-images/ProductImagesLightBox.js +1 -1
- package/dist/esm/product/components/product-images-v2/ProductImagesV2.liquid.js +8 -8
- package/dist/esm/product/components/product-images-v2/common/attrs.js +1 -1
- package/dist/esm/product/components/product-images-v2/common/classes.js +1 -1
- package/dist/esm/product/components/product-images-v2/common/common.js +1 -1
- package/dist/esm/product/components/product-images-v2/common/getBorderActiveCss.js +2 -6
- package/dist/esm/product/components/product-images-v2/common/productFeaturedImage.js +1 -1
- package/dist/esm/product/components/product-images-v2/common/productGallery.js +1 -1
- package/dist/esm/product/components/product-images-v2/common/styles.js +1 -1
- package/dist/esm/product/components/product-images-v2/components/child/ProductFeaturedImageCarousel.js +1 -1
- package/dist/esm/product/components/product-images-v2/components/child/ProductGalleryGrid.js +2 -2
- package/dist/esm/product/components/product-images-v2/components/feature-gallery/FeatureImageWithGallery.js +1 -1
- package/dist/esm/product/components/product-images-v2/components/feature-gallery/FeatureImageWithGallery.liquid.js +48 -48
- package/dist/esm/product/components/product-images-v2/components/gallery-carousel/GalleryCarousel.js +1 -1
- package/dist/esm/product/components/product-images-v2/components/gallery-carousel/GalleryCarousel.liquid.js +14 -14
- package/dist/esm/product/components/product-images-v2/components/gallery-grid/GalleryGrid.js +1 -1
- package/dist/esm/product/components/product-images-v2/components/gallery-grid/GalleryGrid.liquid.js +11 -11
- package/dist/esm/product/components/product-images-v2/components/lightbox/ProductImagesLightBox.js +1 -1
- package/dist/esm/product/components/product-images-v2/hooks/useProductGalleryGrid.js +1 -1
- package/dist/esm/product/components/product-images-v3/ProductImageV2.js +26 -0
- package/dist/esm/product/components/product-images-v3/ProductImagesV2.liquid.js +44 -0
- package/dist/esm/product/components/product-images-v3/common/attrs.js +1 -0
- package/dist/esm/product/components/product-images-v3/common/classes.js +1 -0
- package/dist/esm/product/components/product-images-v3/common/common.js +1 -0
- package/dist/esm/product/components/product-images-v3/common/getBorderActiveCss.js +20 -0
- package/dist/esm/product/components/product-images-v3/common/hoverAction.js +1 -0
- package/dist/esm/product/components/product-images-v3/common/productFeaturedImage.js +1 -0
- package/dist/esm/product/components/product-images-v3/common/productGallery.js +1 -0
- package/dist/esm/product/components/product-images-v3/common/styles.js +1 -0
- package/dist/esm/product/components/product-images-v3/components/child/MediaIcon.js +2 -0
- package/dist/esm/product/components/product-images-v3/components/child/ProductFeatureVideo.js +1 -0
- package/dist/esm/product/components/product-images-v3/components/child/ProductFeaturedImageCarousel.js +1 -0
- package/dist/esm/product/components/product-images-v3/components/child/ProductFeaturedImageOnly.js +2 -0
- package/dist/esm/product/components/product-images-v3/components/child/ProductGalleryGrid.js +2 -0
- package/dist/esm/product/components/product-images-v3/components/feature-gallery/FeatureImageWithGallery.js +1 -0
- package/dist/esm/product/components/product-images-v3/components/feature-gallery/FeatureImageWithGallery.liquid.js +118 -0
- package/dist/esm/product/components/product-images-v3/components/feature-only/OnlyFeatureImage.js +2 -0
- package/dist/esm/product/components/product-images-v3/components/gallery-carousel/GalleryCarousel.js +1 -0
- package/dist/esm/product/components/product-images-v3/components/gallery-carousel/GalleryCarousel.liquid.js +46 -0
- package/dist/esm/product/components/product-images-v3/components/gallery-grid/GalleryGrid.js +2 -0
- package/dist/esm/product/components/product-images-v3/components/gallery-grid/GalleryGrid.liquid.js +93 -0
- package/dist/esm/product/components/product-images-v3/components/lightbox/ButtonOpenLightBox.js +2 -0
- package/dist/esm/product/components/product-images-v3/components/lightbox/ProductImagesLightBox.js +2 -0
- package/dist/esm/product/components/product-images-v3/composables/getProductImagesAttr.js +1 -0
- package/dist/esm/product/components/product-images-v3/composables/getProductImagesClassName.js +1 -0
- package/dist/esm/product/components/product-images-v3/composables/getProductImagesStyles.js +1 -0
- package/dist/esm/product/components/product-images-v3/hooks/useFeatureImageWithGallery.js +1 -0
- package/dist/esm/product/components/product-images-v3/hooks/useFilterImagesByVariant.js +1 -0
- package/dist/esm/product/components/product-images-v3/hooks/useGalleryCarousel.js +1 -0
- package/dist/esm/product/components/product-images-v3/hooks/useProductFeaturedImageCarousel.js +1 -0
- package/dist/esm/product/components/product-images-v3/hooks/useProductGalleryGrid.js +1 -0
- package/dist/esm/product/components/product-list/ProductListCarouselLayout.liquid.js +6 -6
- package/dist/esm/product/components/product-list-v3/ProductList.js +1 -0
- package/dist/esm/product/components/product-list-v3/ProductList.liquid.js +205 -0
- package/dist/esm/product/components/product-list-v3/ProductListCarouselItem.liquid.js +15 -0
- package/dist/esm/product/components/product-list-v3/ProductListCarouselLayout.js +1 -0
- package/dist/esm/product/components/product-list-v3/ProductListCarouselLayout.liquid.js +22 -0
- package/dist/esm/product/components/product-list-v3/ProductListGridItem.liquid.js +19 -0
- package/dist/esm/product/components/product-list-v3/ProductListGridLayout.js +1 -0
- package/dist/esm/product/components/product-list-v3/ProductListGridLayout.liquid.js +34 -0
- package/dist/esm/product/components/product-list-v3/common/attrs.js +1 -0
- package/dist/esm/product/components/product-list-v3/common/classes.js +1 -0
- package/dist/esm/product/components/product-list-v3/common/helpers.js +1 -0
- package/dist/esm/product/components/product-list-v3/common/styles.js +1 -0
- package/dist/esm/product/index.js +1 -1
- package/dist/esm/product/next.js +1 -1
- package/dist/esm/product/settings/ProductListV3.js +8 -0
- package/dist/esm/product/settings/product/configs/product-presets/product-1-col.js +2 -2
- package/dist/esm/product/settings/product/configs/product-presets/product-2-col.js +2 -2
- package/dist/esm/product/settings/product/configs/product-presets/product-default.js +2 -2
- package/dist/esm/product/settings/product-image-v2/ProductImages.js +2 -2
- package/dist/esm/product/settings/product-image-v2/configs/setting-v2/ProductFeatureImage.js +1 -1
- package/dist/esm/product/settings/product-image-v2/configs/setting-v2/ProductGalleryImage.js +3 -2
- package/dist/esm/product/settings/product-image-v2/configs/ui/FeatureNavigation.js +1 -1
- package/dist/esm/product/settings/product-image-v2/configs/ui/ImageListNavigation.js +1 -1
- package/dist/esm/product/settings/product-image-v2/configs/ui-v2.js +1 -1
- package/dist/esm/product/settings/product-image-v3/ProductFeatureImage.js +1 -0
- package/dist/esm/product/settings/product-image-v3/ProductGalleryImage.js +1 -0
- package/dist/esm/product/settings/product-image-v3/ProductImages.js +21 -0
- package/dist/esm/product/settings/product-image-v3/configs/setting-v2/ProductFeatureImage.js +2 -0
- package/dist/esm/product/settings/product-image-v3/configs/setting-v2/ProductGalleryImage.js +2 -0
- package/dist/esm/product/settings/product-image-v3/configs/setting-v2/index.js +1 -0
- package/dist/esm/product/settings/product-image-v3/configs/ui/FeatureDots.js +1 -0
- package/dist/esm/product/settings/product-image-v3/configs/ui/FeatureNavigation.js +1 -0
- package/dist/esm/product/settings/product-image-v3/configs/ui/ImageListNavigation.js +1 -0
- package/dist/esm/product/settings/product-image-v3/configs/ui-v1.js +1 -0
- package/dist/esm/product/settings/product-image-v3/configs/ui-v2.js +1 -0
- package/dist/esm/product/settings/product-list/configs/presets.js +2 -2
- package/dist/esm/product/settings/product-list/configs/settings-v2.js +1 -1
- package/dist/esm/product/settings/product-list-v3/configs/presets.js +37 -0
- package/dist/esm/product/settings/product-list-v3/configs/settings-v2.js +1 -0
- package/dist/esm/product/settings/product-list-v3/configs/ui-v1.js +1 -0
- package/dist/esm/product/settings/product-list-v3/configs/ui-v2.js +1 -0
- package/dist/esm/setting.js +1 -1
- package/dist/esm/third-party/components/BloyRewardsProgramLoyalty.js +2 -0
- package/dist/esm/third-party/components/BloyRewardsProgramLoyalty.liquid.js +1 -0
- package/dist/esm/third-party/components/UppromoteAffiliateMarketing.liquid.js +89 -1
- package/dist/esm/third-party/configs/BloyRewardsProgramLoyalty.js +1 -0
- package/dist/esm/third-party/index.js +1 -1
- package/dist/esm/third-party/next.js +1 -1
- package/dist/esm/third-party/settings/BloyRewardsProgramLoyalty/index.js +4 -0
- package/dist/esm/third-party/settings/BloyRewardsProgramLoyalty/uiV2.js +1 -0
- package/dist/esm/third-party/settings/KoalaBundleQuantityDiscount/index.js +1 -1
- package/dist/types/index.d.ts +492 -74
- package/package.json +3 -3
- package/dist/cjs/carousel/components/swiper/Swiper.js +0 -1
- package/dist/esm/carousel/components/swiper/Swiper.js +0 -1
- /package/dist/cjs/{carousel → carousel-v3}/components/swiper/SwiperSlide.js +0 -0
- /package/dist/cjs/{carousel → carousel-v3}/components/swiper/common/styles.js +0 -0
- /package/dist/esm/{carousel → carousel-v3}/components/swiper/SwiperSlide.js +0 -0
- /package/dist/esm/{carousel → carousel-v3}/components/swiper/common/styles.js +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import{jsx as e}from"react/jsx-runtime";import{useFeaturedImageGlobal as t,cls as o}from"@gem-sdk/core";import i from"../../../carousel/components/root/Carousel.js";import l from"../../../carousel/components/item/CarouselItem.js";import s from"../../../image/components/NextImage.js";import"../../../modal/components/confirm.js";import r from"../../../modal/components/Modal.js";import{useMemo as m}from"react";import{isFeatureMedia as n}from"./common/productFeaturedImage.js";let ProductImagesLightBox=({builderPropUID:d,productImages:p,open:a,imageRatio:c,onHandleClose:g})=>{let h=t(),b=m(()=>{let e=p?.findIndex(e=>e.id===h?.id);return e&&e>0?e:0},[p,h]),u={desktop:p&&p.length>1,mobile:p&&p?.length>1,tablet:p&&p?.length>1},f={desktop:!1,mobile:!1,tablet:!1};return e(r,{setting:{open:a},styles:{width:"80%"},closeOnClickOutside:!0,onClose:()=>g(),disableIframeClickEvent:!0,contentClass:"mobile:!gp-w-[100%] gp-px-2",children:e(i,{setting:{loop:f,slidesToShow:{desktop:1,tablet:1,mobile:1},defaultCurrentSlider:b,dot:{desktop:!0,mobile:!0,tablet:!0},dotStyle:{desktop:"outside",mobile:"outside",tablet:"outside"},dotColor:{desktop:"#E2E2E2",mobile:"#E2E2E2",tablet:"#E2E2E2"},dotActiveColor:{desktop:"#121212",mobile:"#121212",tablet:"#121212"},controlOverContent:{desktop:!0,mobile:!0,tablet:!0},arrow:u},styles:{sizeSetting:{desktop:{height:"80vh"},tablet:{height:"80vh"},mobile:{height:"60vh"}}},moveToIdx:b,hiddenDotWhenOnlyOne:!0,isHiddenArrowWhenDisabled:!0,builderProps:{uid:d},children:p?.map(t=>e(l,{className:`gem-slider-item gem-slider-item-${d} gp-flex gp-items-center gp-justify-center gp-px-4`,children:e(s,{src:n(t?.contentType)?t?.previewImage:t?.src,width:t?.width,height:t?.height,alt:t?.alt,"content-type":t?.contentType,setting:{aspectRatio:c},className:o("gp-h-full gp-w-full gp-object-contain")},t?.id)},t?.id))})})};export{ProductImagesLightBox as default};
|
|
2
|
+
import{jsx as e}from"react/jsx-runtime";import{useFeaturedImageGlobal as t,cls as o}from"@gem-sdk/core";import i from"../../../carousel-v3/components/root/Carousel.js";import l from"../../../carousel-v3/components/item/CarouselItem.js";import s from"../../../image/components/NextImage.js";import"../../../modal/components/confirm.js";import r from"../../../modal/components/Modal.js";import{useMemo as m}from"react";import{isFeatureMedia as n}from"./common/productFeaturedImage.js";let ProductImagesLightBox=({builderPropUID:d,productImages:p,open:a,imageRatio:c,onHandleClose:g})=>{let h=t(),b=m(()=>{let e=p?.findIndex(e=>e.id===h?.id);return e&&e>0?e:0},[p,h]),u={desktop:p&&p.length>1,mobile:p&&p?.length>1,tablet:p&&p?.length>1},f={desktop:!1,mobile:!1,tablet:!1};return e(r,{setting:{open:a},styles:{width:"80%"},closeOnClickOutside:!0,onClose:()=>g(),disableIframeClickEvent:!0,contentClass:"mobile:!gp-w-[100%] gp-px-2",children:e(i,{setting:{loop:f,slidesToShow:{desktop:1,tablet:1,mobile:1},defaultCurrentSlider:b,dot:{desktop:!0,mobile:!0,tablet:!0},dotStyle:{desktop:"outside",mobile:"outside",tablet:"outside"},dotColor:{desktop:"#E2E2E2",mobile:"#E2E2E2",tablet:"#E2E2E2"},dotActiveColor:{desktop:"#121212",mobile:"#121212",tablet:"#121212"},controlOverContent:{desktop:!0,mobile:!0,tablet:!0},arrow:u},styles:{sizeSetting:{desktop:{height:"80vh"},tablet:{height:"80vh"},mobile:{height:"60vh"}}},moveToIdx:b,hiddenDotWhenOnlyOne:!0,isHiddenArrowWhenDisabled:!0,builderProps:{uid:d},children:p?.map(t=>e(l,{className:`gem-slider-item gem-slider-item-${d} gp-flex gp-items-center gp-justify-center gp-px-4`,children:e(s,{src:n(t?.contentType)?t?.previewImage:t?.src,width:t?.width,height:t?.height,alt:t?.alt,"content-type":t?.contentType,setting:{aspectRatio:c},className:o("gp-h-full gp-w-full gp-object-contain")},t?.id)},t?.id))})})};export{ProductImagesLightBox as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{template as e,isLocalEnv as o,baseAssetURL as r,WrapRenderChildren as s,RenderChildren as t}from"@gem-sdk/core";import{getConditionRenderGalleryImages as i,getStyleInsideLayout as a,setDefaultWhenUndefineSetting as p}from"./common/common.js";import l from"./components/feature-gallery/FeatureImageWithGallery.liquid.js";import d from"./components/gallery-carousel/GalleryCarousel.liquid.js";import m from"./components/gallery-grid/GalleryGrid.liquid.js";import{getSettingPreloadData as c}from"../../../helpers.js";import{getShapeByLayout as u,sizeSettingDefaultForNewLayout as n}from"./common/productGallery.js";import{getProductImagesClassName as g}from"./composables/getProductImagesClassName.js";import{getProductImagesStyles as f}from"./composables/getProductImagesStyles.js";import{createAttr as $,LiquidIf as y,createClass as h,If as
|
|
1
|
+
import{template as e,isLocalEnv as o,baseAssetURL as r,WrapRenderChildren as s,RenderChildren as t}from"@gem-sdk/core";import{getConditionRenderGalleryImages as i,getStyleInsideLayout as a,setDefaultWhenUndefineSetting as p}from"./common/common.js";import l from"./components/feature-gallery/FeatureImageWithGallery.liquid.js";import d from"./components/gallery-carousel/GalleryCarousel.liquid.js";import m from"./components/gallery-grid/GalleryGrid.liquid.js";import{getSettingPreloadData as c}from"../../../helpers.js";import{getShapeByLayout as u,sizeSettingDefaultForNewLayout as n}from"./common/productGallery.js";import{getProductImagesClassName as g}from"./composables/getProductImagesClassName.js";import{getProductImagesStyles as f}from"./composables/getProductImagesStyles.js";import{createAttr as $,LiquidIf as y,createClass as h,If as S,Liquid as j}from"@gem-sdk/system";import{getBorderActiveCss as v}from"./common/getBorderActiveCss.js";import{getStyleOfObject as F}from"../../helpers/function.js";let ProductImages=I=>{let P=p(I),{setting:C,styles:G,builderProps:D,style:b}=P,{rawChildren:z,pageContext:O}=I,{enableLazyLoadImage:_}=O??{},N={...C,...G},A=`
|
|
2
2
|
{
|
|
3
3
|
"id":${JSON.stringify(D?.uid)},
|
|
4
4
|
"pageContext": ${JSON.stringify(O)},
|
|
@@ -18,15 +18,15 @@ import{template as e,isLocalEnv as o,baseAssetURL as r,WrapRenderChildren as s,R
|
|
|
18
18
|
${{...q}}
|
|
19
19
|
>
|
|
20
20
|
${y("product.media.size > 1",d({builderPropUID:`gp-gallery-${D?.uid}`,...N,enableLazyLoadImage:_}))}
|
|
21
|
-
${
|
|
21
|
+
${S(k,m({builderPropUID:D?.uid,wrapperStyle:{...V},children:W(),...N,enableLazyLoadImage:_}))}
|
|
22
22
|
</div>
|
|
23
23
|
`,K=()=>C?.borderActive?.border!=="none";return e`
|
|
24
|
-
${
|
|
25
|
-
${
|
|
24
|
+
${S(K(),y("product.media.size > 1",`<style>${v({settings:N,uid:D?.uid,type:"Liquid"})}</style>`),"")}
|
|
25
|
+
${j(`
|
|
26
26
|
{% assign featured_image = product.featured_image %}
|
|
27
27
|
${y("variant != null and variant.featured_image != null","{% assign featured_image = variant.featured_image %}")}
|
|
28
28
|
`)}
|
|
29
|
-
<gp-product-images
|
|
29
|
+
<gp-product-images
|
|
30
30
|
gp-data='${A}'
|
|
31
31
|
${{...B}}
|
|
32
32
|
style="${{...b}}"
|
|
@@ -37,8 +37,8 @@ import{template as e,isLocalEnv as o,baseAssetURL as r,WrapRenderChildren as s,R
|
|
|
37
37
|
style="${y("product.media.size > 1",F(x),F(L))}"
|
|
38
38
|
>
|
|
39
39
|
${l({builderPropUID:`gp-carousel-${D?.uid}`,...N,children:W(),enableLazyLoadImage:_})}
|
|
40
|
-
${
|
|
40
|
+
${S(!U,H())}
|
|
41
41
|
</div>
|
|
42
|
-
</gp-product-images
|
|
43
|
-
${
|
|
42
|
+
</gp-product-images>
|
|
43
|
+
${S(o,`<script ${c('class="gps-link" delay',"src")}="{{ 'gp-product-images-v7-5.js' | asset_url }}" defer="defer"></script>`,`<script ${c('class="gps-link" delay',"src")}="${r}/assets-v2/gp-product-images-v7-5.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}" defer="defer"></script>`)}
|
|
44
44
|
`};export{ProductImages as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{getResponsiveValueByScreen as o}from"@gem-sdk/core";import{
|
|
1
|
+
import{getResponsiveValueByScreen as o}from"@gem-sdk/core";import{getShapeByLayout as t,getSliderPerShowConfig as r,getDotStyleConfig as e,getCarouselVerticalConfigByPosition as a,getAllowDotConfig as i}from"./productGallery.js";import{getDotStyleForOnlyFeaturedImage as n}from"./productFeaturedImage.js";let DEVICES=["desktop","mobile","tablet"],getGalleryCarouselSettingAttr=i=>{let n=t({shape:i.shape,shapeForBottom:i.shapeForBottom,shapeFor1Col:i.shapeFor1Col,shapeFor2Col:i.shapeFor2Col,shapeForFtOnly:i.shapeForFtOnly,shapeForInsideBottom:i.shapeForInsideBottom,shapeForInside:i.shapeForInside},i.position),d=r(n,i.position),l={desktop:"inside"===o(i.navigationPosition,"desktop"),tablet:"inside"===o(i.navigationPosition,"tablet"),mobile:"inside"===o(i.navigationPosition,"mobile")},s=DEVICES.reduce((o,t)=>(i.navigationPosition?.[t]&&(o[t]="none"!==i.navigationPosition[t]),o),{});return{...i?.loop&&{loop:i.loop},itemNumber:d,dot:{desktop:!1,tablet:!1,mobile:!1},dotStyle:e(),controlOverContent:l,...i?.dragToScroll&&{enableDrag:{desktop:i.dragToScroll,tablet:i.dragToScroll,mobile:i.dragToScroll}},vertical:a(i.position),...i?.arrowIcon&&{arrowCustom:i.arrowIcon},arrowIconSize:i.arrowIconSize||{desktop:24},...i?.arrowIconColor&&{arrowCustomColor:i.arrowIconColor},...i?.arrowNavColor&&{arrowBackgroundColor:i.arrowNavColor},...i?.arrowNavBorder&&{arrowBorder:{desktop:i.arrowNavBorder}},...i?.arrowNavRadius&&{roundedArrow:{desktop:i.arrowNavRadius}},...i?.arrowNavShadow&&{arrowShadow:{desktop:i.arrowNavShadow}},sneakPeakType:{desktop:"center"},arrowGapToEachSide:"16",navigationStyle:i.navigationPosition,navigationEnable:s,arrowButtonSize:{desktop:{width:void 0,height:void 0}},animationMode:i?.ftAnimationMode,enableAction:{desktop:!0}}},getFeaturedCarouselSettingAttr=t=>{let r={desktop:"inside"===o(t.ftNavigationPosition,"desktop"),tablet:"inside"===o(t.ftNavigationPosition,"tablet"),mobile:"inside"===o(t.ftNavigationPosition,"mobile")},e=DEVICES.reduce((o,r)=>(t.ftNavigationPosition?.[r]&&(o[r]="none"!==t.ftNavigationPosition[r]),o),{});return{...t?.ftLoop&&{loop:t.ftLoop},itemNumber:{desktop:1},dot:i(),dotStyle:n({position:t.position,dotStyle:t.ftDotStyle}),dotSize:t.ftDotSize??{desktop:12},dotGapToCarousel:t.ftDotGapToCarousel??{desktop:16},dotColor:t.ftDotColor??{desktop:"bg-1"},dotActiveColor:t.ftDotActiveColor??{desktop:"line-3"},controlOverContent:r,...t?.ftDragToScroll&&{enableDrag:{desktop:t.ftDragToScroll,tablet:t.ftDragToScroll,mobile:t.ftDragToScroll}},...t?.ftArrowIcon&&{arrowCustom:t.ftArrowIcon},arrowIconSize:t.ftArrowIconSize||{desktop:24},...t?.ftArrowIconColor&&{arrowCustomColor:t.ftArrowIconColor},...t?.ftArrowNavColor&&{arrowBackgroundColor:t.ftArrowNavColor},...t?.ftArrowNavBorder&&{arrowBorder:{desktop:t.ftArrowNavBorder}},...t?.ftArrowNavRadius&&{roundedArrow:{desktop:t.ftArrowNavRadius}},...t?.ftArrowNavShadow&&{arrowShadow:{desktop:t.ftArrowNavShadow}},sneakPeakType:{desktop:"center"},arrowGapToEachSide:"16",animationMode:t?.ftAnimationMode,...t?.ftNavigationPosition&&{navigationStyle:t.ftNavigationPosition},navigationEnable:e,arrowButtonSize:{desktop:{width:void 0,height:void 0}},enableAction:{desktop:!0}}};export{getFeaturedCarouselSettingAttr,getGalleryCarouselSettingAttr};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{DEVICES as e,getResponsiveValueByScreen as l}from"@gem-sdk/core";function composeClasses(e){return e.split(" ").reduce((e,l)=>(e[l]=!0,e),{})}let getWrapperClasses=({extraClass:e,isAddOverFlowClass:l=!1})=>{let s="gp-relative gp-w-full";return e&&(s+=` ${e}`),l&&(s+=" gp-overflow-hidden"),composeClasses(s)},getGalleryWrapperClasses=({extraClass:e})=>{let l="gallery-wrapper gp-product-images-gallery gp-flex gp-overflow-hidden gp-max-w-full gp-max-h-full data-[only-image=true]:gp-hidden";return e&&(l+=` ${e}`),composeClasses(l)},getGalleryGridWrapperClasses=({extraClass:e})=>{let l="product-feature-image grid-gallery gp-flex !gp-h-fit gp-w-full gp-flex-wrap scrollbar-track:gp-rounded-2xl scrollbar-thumb:gp-rounded-2xl scrollbar-thumb:gp-bg-gray-400
|
|
1
|
+
import{DEVICES as e,getResponsiveValueByScreen as l}from"@gem-sdk/core";function composeClasses(e){return e.split(" ").reduce((e,l)=>(e[l]=!0,e),{})}let getWrapperClasses=({extraClass:e,isAddOverFlowClass:l=!1})=>{let s="gp-relative gp-w-full";return e&&(s+=` ${e}`),l&&(s+=" gp-overflow-hidden"),composeClasses(s)},getGalleryWrapperClasses=({extraClass:e})=>{let l="gallery-wrapper gp-product-images-gallery gp-flex gp-overflow-hidden gp-max-w-full gp-max-h-full data-[only-image=true]:gp-hidden";return e&&(l+=` ${e}`),composeClasses(l)},getGalleryGridWrapperClasses=({extraClass:e})=>{let l="product-feature-image grid-gallery gp-flex !gp-h-fit gp-w-full gp-flex-wrap scrollbar-track:gp-rounded-2xl scrollbar-thumb:gp-rounded-2xl scrollbar-thumb:gp-bg-gray-400";return e&&(l+=` ${e}`),composeClasses(l)},getFtImageWithGalleryClasses=({extraClass:e})=>{let l="gp-flex !gp-h-fit gp-relative gp-overflow-hidden";return e&&(l+=` ${e}`),composeClasses(l)},getImageGalleryWrapperClasses=({extraClass:e})=>{let l="gp-flex gp-h-fit gp-max-w-full gp-overflow-hidden";return e&&(l+=` ${e}`),composeClasses(l)},getFeaturedImageCarouselClasses=({extraClass:e})=>{let l="`gp-flex-1 gp-w-full gp-feature-image-carousel";return e&&(l+=` ${e}`),composeClasses(l)},getFeaturedImageClasses=({setting:s,extraClass:r})=>{let a=r??"";return e.forEach(e=>{let r=l(s?.ftNavigationPosition,e),t="desktop"!==e?`${e}:`:"";"outside"===r?a+=` ${t}gp-px-[16px]`:a+=` ${t}gp-px-0`}),composeClasses(a)},getFeaturedImageGalleryClasses=({settings:s,extraClass:r})=>{let a=r??"gp-flex-1 gp-w-full carousel-gallery";return e.forEach(e=>{let r=l(s?.navigationPosition,e),t=l(s?.type,e),g=l(s?.position,e),p="desktop"!==e?`${e}:`:"";"outside"===r&&"slider"===t&&["bottom-center"].includes(g||"")?a+=` ${p}gp-px-[16px]`:a+=` ${p}gp-px-0`}),composeClasses(a)},getGalleryItemClasses=({extraClass:e})=>{let l="gp-image-item gp-flex gp-items-center gp-justify-center gp-group gp-relative gp-overflow-hidden gp-cursor-pointer data-[outline=deactive]:after:!gp-border-transparent";return e&&(l+=` ${e}`),composeClasses(l)},getFeaturedCarouselItemClasses=({extraClass:e})=>{let l="gp-group gp-z-0 gp-flex !gp-min-w-full !gp-max-w-full gp-w-full gp-relative gp-items-start gp-justify-center gp-overflow-hidden gp-outline-1 -gp-outline-offset-1 gp-image-item gp-ft-image-item data-[outline=active]:gp-outline";return e&&(l+=` ${e}`),composeClasses(l)};export{getFeaturedCarouselItemClasses,getFeaturedImageCarouselClasses,getFeaturedImageClasses,getFeaturedImageGalleryClasses,getFtImageWithGalleryClasses,getGalleryGridWrapperClasses,getGalleryItemClasses,getGalleryWrapperClasses,getImageGalleryWrapperClasses,getWrapperClasses};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{getResponsiveValueByScreen as e,makeAspectRatio as t,makeStyleResponsive as
|
|
1
|
+
import{getResponsiveValueByScreen as e,makeAspectRatio as t,makeStyleResponsive as o,removeNullUndefined as i,DEVICES as r}from"@gem-sdk/core";let getTypeWidthDevice=e=>{let t=e?.desktop,o=e?.tablet===void 0?t:e?.tablet,i=e?.mobile===void 0?o:e?.mobile;return{desktop:t,tablet:o,mobile:i}},convertUnitToNumber=(e,t)=>{if(!e)return t;if("number"==typeof e)return e;let o=e.replaceAll("px","").replaceAll("%","").replaceAll("rem","").replaceAll("em","");return isNaN(Number(o))?t:Number(o)},convertSpacing=e=>e?{desktop:convertUnitToNumber(e.desktop,5),tablet:convertUnitToNumber(e.tablet,5),mobile:convertUnitToNumber(e.mobile,5)}:{desktop:5},getDisplayStyle=(e,t)=>{let o={},i=["desktop","mobile","tablet"];return i.forEach(i=>{o={...o,[`--d${"desktop"===i?"":`-${i}`}`]:`${e(i)?"none":t}`}}),o},checkAddOverFlowClass=e=>{let t=e?.["--radius"],o=e?.["--bblr"]||"0px",i=e?.["--bbrr"]||"0px",r=e?.["--btlr"]||"0px",l=e?.["--btrr"]||"0px";return t&&!t.toString().includes("none")&&"0"!==t.toString()||"0px"!==o||"0px"!==i||"0px"!==r||"0px"!==l},getAspectRatio=o=>{let i={},r=["desktop","mobile","tablet"];return r.forEach(t=>{let r=e(o,t)?.shapeValue;if(r)i={...i,[t]:r};else{let r=e(o,t)?.shape;switch(r){case"square":i={...i,[t]:"1/1"};break;case"vertical":i={...i,[t]:"3/4"};break;case"horizontal":i={...i,[t]:"4/3"};break;case"original":i={...i,[t]:""}}}}),t(i)},getStyleGridLayout=t=>{let o={"--gtc":"minmax(0, 12fr)","--gtc-tablet":"minmax(0, 12fr)","--gtc-mobile":"minmax(0, 12fr)"};if(!t.isHiddenGalleryImages){let i=!1;r.forEach(r=>{let l=e(t.position,r),a=e(t.ratioLayout,r),n=e(t.ratioLayoutRight,r),s="desktop"===r?"--gtc":`--gtc-${r}`,d="desktop"===r?"--gtr":`--gtr-${r}`,u="left"===l?a:n,c=["left","right"].includes(l||"");c&&u?(i=!0,Object.assign(o={...o,[s]:`minmax(0, ${u[0]}fr) minmax(0, ${u[1]}fr)`},{[d]:"fit-content(0)"})):i&&Object.assign(o,{[d]:"unset"})})}return o},getStyleGridOrderForFeature=t=>{let o={"--o":"0","--o-tablet":"0","--o-mobile":"0"},i=["desktop","mobile","tablet"];return i.forEach(i=>{let r=e(t.position,i),l="desktop"===i?"--o":`--o-${i}`;o={...o,[l]:"left"===r?"1":"0"}}),o},getStyleGridOrderForGallery=t=>{let o={"--o":"1","--o-tablet":"1","--o-mobile":"1"},i=["desktop","mobile","tablet"];return i.forEach(i=>{let r=e(t.position,i),l="desktop"===i?"--o":`--o-${i}`;o={...o,[l]:"left"===r?"0":"1"}}),o},getSrcImage=e=>`{{${e} | image_url: width: 480}} 480w, {{${e} | image_url: width: 768}} 768w, {{${e} | image_url: width: 1024}} 1024w, {{${e} | image_url: width: 1440}} 1440w`,convertSpacingForIndisdeLayout=e=>{let t=parseInt(e)?`${2*parseInt(e)}px`:`${e} * 2`;return t},getStyleInsideLayout=(t,r,l)=>{let a=["desktop","mobile","tablet"],n={},s={},d={},u={},c={},g={};return a.forEach(o=>{let i=e(t,o),a=e(r,o)?.width,m=e(l,o);if(n={...n,[o]:["inside-bottom","inside-left","inside-right"].includes(i)?"absolute":"static"},["inside-bottom"].includes(i)){let e=convertSpacingForIndisdeLayout(m);a=`calc(100% - ${e})`}["bottom-center","two-col","one-col"].includes(i)&&(a="100%"),d={...d,[o]:"inside-bottom"===i?`${m}`:"auto"},u={...u,[o]:["inside-left","inside-right"].includes(i)?`${m}`:"auto"},g={...g,[o]:["inside-bottom","inside-left"].includes(i)?`${m}`:"auto"},c={...c,[o]:"inside-right"===i?`${m}`:"auto"},s={...s,[o]:a}}),{...o("pos",n),...o("w",i(s)),...o("bottom",i(d)),...o("top",i(u)),...o("left",i(g)),...o("right",i(c))}},getConditionRenderGalleryImages=(t,o)=>{let i=["desktop","mobile","tablet"],r=!0,l=!1;return i.forEach(i=>{let a=e(t,i),n=e(o,i);a&&"only-feature"!==a&&(r=!1),(["two-col","one-col"].includes(a)||"images"===n)&&(l=!0)}),{isOnlyFeatureAllDevices:r,isRenderGalleryGrid:l}},setDefaultWhenUndefineSetting=e=>({...e,setting:{...e.setting}}),getValueFromValueContainUnit=e=>{let t=e.match(/\d+/g);return t?t[0]:e},getPaddingBottomByShapeSetting=t=>{let o=getAspectRatio(t),i={desktop:"auto",mobile:"auto",tablet:"auto"},r=["desktop","mobile","tablet"];return r.forEach(r=>{let l=e(t,r),a=l?.height,n=l?.width||"",s=getValueFromValueContainUnit(a||""),d=n.toString().match(/px/g)?getValueFromValueContainUnit(n):n;if(a&&n&&!isNaN(Number(s))&&!isNaN(Number(d))){i={...i,[r]:`${Number(s)/Number(d)*100}%`};return}if(a&&!isNaN(Number(s))){i={...i,[r]:a};return}let u=o?.[r]!=="auto"&&o?.[r]?o?.[r]?.split("/").reverse().join("/"):"{%if largestRatio == 0%} 100 / 100 {%else%} {{largestRatio}} {%endif%}";i={...i,[r]:`calc((${u})*100%)`}}),i};export{checkAddOverFlowClass,convertSpacing,convertSpacingForIndisdeLayout,convertUnitToNumber,getAspectRatio,getConditionRenderGalleryImages,getDisplayStyle,getPaddingBottomByShapeSetting,getSrcImage,getStyleGridLayout,getStyleGridOrderForFeature,getStyleGridOrderForGallery,getStyleInsideLayout,getTypeWidthDevice,setDefaultWhenUndefineSetting};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import{composeBorderCss as e,composeCornerCss as t}from"@gem-sdk/core";let getBorderActiveCss=({settings:i,uid:r,type:
|
|
2
|
-
${
|
|
1
|
+
import{composeBorderCss as e,composeCornerCss as t}from"@gem-sdk/core";let getBorderActiveCss=({settings:i,uid:r,type:g})=>{let l="Liquid"===g?`.gem-slider-item-${r}-{{product.id}}.gp-gallery-image-item::after, .gem-slider-item-gp-gallery-${r}-{{product.id}}.gp-gallery-image-item::after`:`.gem-slider-item-active.gem-slider-item-${r}.gp-gallery-image-item::after`;return`
|
|
2
|
+
${l} {
|
|
3
3
|
content: "";
|
|
4
4
|
height: 100%;
|
|
5
5
|
width: 100%;
|
|
@@ -13,8 +13,4 @@ import{composeBorderCss as e,composeCornerCss as t}from"@gem-sdk/core";let getBo
|
|
|
13
13
|
.gem-slider-item-${r}-{{product.id}}.gp-gallery-image-item[data-outline=active]:after, .gem-slider-item-gp-gallery-${r}-{{product.id}}.gp-gallery-image-item[data-outline=active]:after {
|
|
14
14
|
pointer-events: none;
|
|
15
15
|
}
|
|
16
|
-
.gem-slider-item-${r}-{{product.id}}.gp-gallery-image-item[data-outline=none]:after{
|
|
17
|
-
pointer-events: none;
|
|
18
|
-
border-color: transparent !important;
|
|
19
|
-
}
|
|
20
16
|
`};export{getBorderActiveCss};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{getResponsiveValueByScreen as e,DEVICES as
|
|
1
|
+
import{getResponsiveValueByScreen as e,DEVICES as o}from"@gem-sdk/core";let isFeatureMedia=e=>!!e&&["EXTERNAL_VIDEO","MODEL_3D","VIDEO"].includes(e),getZoomLenClass=()=>"!gp-flex gp-absolute gp-opacity-0 gp-h-[150px] gp-w-[150px] gp-cursor-none gp-rounded-full gp-bg-no-repeat gp-shadow-glasses gp-bg-white gp-pointer-events-none",getZoomImageClass=()=>"gp-absolute gp-left-0 gp-top-0 gp-opacity-0 gp-transition-opacity gp-bg-white gp-pointer-events-none",getDotStyleForOnlyFeaturedImage=t=>{let a={};return o.forEach(o=>{let r=e(t.position,o),g=e(t.dotStyle,o);a={...a,[o]:"only-feature"===r?g:"none"}}),a},checkRenderFeaturedCarousel=e=>{let o=["desktop","mobile","tablet"],t=!1;return o.forEach(o=>{let a=checkShowCarousel(e,o);checkShowCarousel(e,o)&&(t=a)}),t},checkShowCarousel=(o,t)=>"only-feature"!==e(o.position,t)||"none"!==e(o.ftNavigationPosition,t)||"none"!==e(o.ftDotStyle,t)||!0===e(o.ftLoop,t)||!0===o.ftDragToScroll;export{checkRenderFeaturedCarousel,getDotStyleForOnlyFeaturedImage,getZoomImageClass,getZoomLenClass,isFeatureMedia};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{getResponsiveValueByScreen as e,cls as t}from"@gem-sdk/core";import{getDisplayStyle as o}from"./common.js";import{convertUnitToNumber as i}from"../../product-images/common/productFeaturedImage.js";let getZoomDisplay=t=>o(o=>!e(t,o),"flex"),HORIZONTAL_LAYOUT=["right","left","inside-left","inside-right"],sizeSettingDefaultForNewLayout={desktop:{shape:"square",shapeValue:"1/1",width:"20%",height:void 0,shapeLinked:!0}},getCarouselVerticalConfigByPosition=t=>{let o=["desktop","mobile","tablet"],i={};return o.forEach(o=>{let a=e(t,o),l=HORIZONTAL_LAYOUT.includes(a);i=l?{...i,[o]:!0}:{...i,[o]:!1}}),i},getMinHeightByPosition=(o,i)=>{let a=["desktop","mobile","tablet"],l=getCarouselVerticalConfigByPosition(o),
|
|
1
|
+
import{getResponsiveValueByScreen as e,cls as t}from"@gem-sdk/core";import{getDisplayStyle as o}from"./common.js";import{convertUnitToNumber as i}from"../../product-images/common/productFeaturedImage.js";let getZoomDisplay=t=>o(o=>!e(t,o),"flex"),HORIZONTAL_LAYOUT=["right","left","inside-left","inside-right"],sizeSettingDefaultForNewLayout={desktop:{shape:"square",shapeValue:"1/1",width:"20%",height:void 0,shapeLinked:!0}},getCarouselVerticalConfigByPosition=t=>{let o=["desktop","mobile","tablet"],i={};return o.forEach(o=>{let a=e(t,o),l=HORIZONTAL_LAYOUT.includes(a);i=l?{...i,[o]:!0}:{...i,[o]:!1}}),i},getMinHeightByPosition=(o,i)=>{let a=["desktop","mobile","tablet"],l=getCarouselVerticalConfigByPosition(o),r={};return a.forEach(t=>{let o=e(i,t),a="desktop"===t?"":`${t}:`;r[`${a}!gp-min-h-0`]=!!l[t]&&"outside"===o,r[`${a}!gp-min-h-full`]=!(l[t]&&"outside"===o)}),t({...r})},getEditorMinHeightClass=(t,o,i)=>{let a=getCarouselVerticalConfigByPosition(o),l=e(i,t);return a[t]&&"outside"===l?"!gp-min-h-0":"!gp-min-h-full"},getAllowDotConfig=()=>({desktop:!0,tablet:!0,mobile:!0}),getDotStyleConfig=()=>({desktop:"none",tablet:"none",mobile:"none"}),getSettingWidthForGridItem=t=>{let o={},i=["desktop","mobile","tablet"];return i.forEach(i=>{let a=e(t.shapeByLayout,i)?.width,l=e(t.itemSpacing,i),r=0;a?.includes("%")&&(r=100/parseInt(a)),o={...o,[i]:r?`calc(${a} - ${l} * ${r-1} / ${r})`:a}}),o},getSettingWidthForCarouselItem=t=>{let o={},i=["desktop","mobile","tablet"];return i.forEach(i=>{let a=e(t.position,i),l="bottom-center"===a,r=e(t.shapeByLayout,i)?.width;o={...o,[i]:l&&r?.includes("px")?r:"100%"}}),o},getSettingMinWidthForCarouselItem=t=>{let o={},a=["desktop","mobile","tablet"];return a.forEach(a=>{let l=e(t.position,a),r=i(e(t.spacing,a),5),s="bottom-center"===l||"inside-bottom"===l,n=e(t.shapeByLayout,a)?.width,g="100%";if(s){let e=100/i(n,20);g=n?.includes("px")?n:n?.includes("%")?`calc(${n} - ${(e-1)*r/e}px)`:"100%"}o={...o,[a]:g}}),o},checkDisplayGalleryByWidth=t=>{let o={desktop:!0,tablet:!0,mobile:!0},i=["desktop","mobile","tablet"];return i.forEach(i=>{let a=e(t.shapeByLayout,i)?.width??"100%",l=0!==parseInt(a);o={...o,[i]:l}}),o},getSliderPerShowConfig=(t,o)=>{let i={desktop:"auto",tablet:"auto",mobile:"auto"},a=["desktop","mobile","tablet"];return a.forEach(a=>{let l=e(o,a),r="bottom-center"===l||"inside-bottom"===l,s=e(t,a)?.width,n="auto";s?.includes("%")&&(n=100>parseInt(s)?100/parseInt(s):"auto"),i={...i,[a]:r?n:"auto"}}),i},getShapeByLayout=(t,o)=>{let i={},a=["desktop","mobile","tablet"];return a.forEach(a=>{let l=e(o,a);switch(l){case"bottom-center":case"bottom-left":i={...i,[a]:e(t.shapeForBottom,a)};break;case"inside-bottom":i={...i,[a]:e(t.shapeForInsideBottom??sizeSettingDefaultForNewLayout,a)};break;case"left":case"right":i={...i,[a]:e(t.shape,a)};break;case"inside-left":case"inside-right":i={...i,[a]:e(t.shapeForInside??sizeSettingDefaultForNewLayout,a)};break;case"only-feature":i={...i,[a]:e(t.shapeForFtOnly,a)};break;case"one-col":i={...i,[a]:e(t.shapeFor1Col,a)};break;case"two-col":i={...i,[a]:e(t.shapeFor2Col,a)}}}),i};export{HORIZONTAL_LAYOUT,checkDisplayGalleryByWidth,getAllowDotConfig,getCarouselVerticalConfigByPosition,getDotStyleConfig,getEditorMinHeightClass,getMinHeightByPosition,getSettingMinWidthForCarouselItem,getSettingWidthForCarouselItem,getSettingWidthForGridItem,getShapeByLayout,getSliderPerShowConfig,getZoomDisplay,sizeSettingDefaultForNewLayout};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{makeStyleResponsive as e,makeHeight as t,getHeightByShapeGlobalSize as o,makeWidth as r,composeRadius as i,getResponsiveValueByScreen as a,makeStyleWithDefault as l,getWidthByShapeGlobalSize as s}from"@gem-sdk/core";import{getStyleGridLayout as n,getStyleGridOrderForFeature as p,getStyleGridOrderForGallery as h,getStyleInsideLayout as m,convertSpacing as g,getDisplayStyle as
|
|
1
|
+
import{makeStyleResponsive as e,makeHeight as t,getHeightByShapeGlobalSize as o,makeWidth as r,composeRadius as i,getResponsiveValueByScreen as a,makeStyleWithDefault as l,getWidthByShapeGlobalSize as s}from"@gem-sdk/core";import{getStyleGridLayout as n,getStyleGridOrderForFeature as p,getStyleGridOrderForGallery as h,getStyleInsideLayout as m,convertSpacing as g,getDisplayStyle as F,convertSpacingForIndisdeLayout as d}from"./common.js";import{getShapeByLayout as y,sizeSettingDefaultForNewLayout as u,getSettingWidthForGridItem as S,getSettingMinWidthForCarouselItem as c,getSettingWidthForCarouselItem as I,checkDisplayGalleryByWidth as b}from"./productGallery.js";let DEVICES=["desktop","mobile","tablet"];function filterTruthyStyles(e){return Object.fromEntries(Object.entries(e||{}).filter(([,e])=>!!e))}let getWrapContainerStyle=(t,o)=>{let r=n({position:t.position,ratioLayout:t.ratioLayout,ratioLayoutRight:t.ratioLayoutRight,isHiddenGalleryImages:!!o}),i={"--gtc":"minmax(0, 12fr)"},a={...o?i:r,...e("gg",t?.spacing)};return filterTruthyStyles(a)},getFeatureImageStyle=(t,{enableOrder:o,enableDisplay:r})=>{let i=()=>F(e=>!["bottom-center","left","right","only-feature","inside-bottom","inside-left","inside-right"].includes(a(t?.position,e)||""),"flex"),l=p({position:t?.position}),s={...e("jc",t?.align),...o&&{...l},...r&&{...i()}};return filterTruthyStyles(s)},getGalleryImageStyle=(o,r)=>{let i=h({position:o.position}),l=()=>{let e={},t=r??0;return DEVICES.forEach(r=>{let i=a(o?.position,r),l=["left","right"].includes(i),s=a(o?.spacing,r),n=["inside-left","inside-right"].includes(i),p=d(s),h=`calc(${t}px - ${p})`;e={...e,[r]:l?t+"px":n?h:"auto"}}),e},s=y({shape:o.shape,shapeForBottom:o.shapeForBottom,shapeFor1Col:o.shapeFor1Col,shapeFor2Col:o.shapeFor2Col,shapeForFtOnly:o.shapeForFtOnly,shapeForInsideBottom:o.shapeForInsideBottom??u,shapeForInside:o.shapeForInside??u},o.position),n=m(o.position,s,o?.spacing),p={...e("h",t(l())),...e("jc",o?.align),...i,...n};return filterTruthyStyles(p)},getGalleryGridStyle=(t,o)=>{let r=y({shape:t.shape,shapeForBottom:t.shapeForBottom,shapeFor1Col:t.shapeFor1Col,shapeFor2Col:t.shapeFor2Col,shapeForFtOnly:t.shapeForFtOnly,shapeForInsideBottom:t.shapeForInsideBottom,shapeForInside:t.shapeForInside},t.position),i=()=>{let e=(e,t,o)=>{let r=a(t,o),i=a(e,o),l="slider"!==i&&("bottom-center"===r||"inside-bottom"===r),s=["one-col","two-col"].includes(r||"");return l||s},o=b({shapeByLayout:r}),i={desktop:o.desktop&&e(t.type,t.position,"desktop"),tablet:o.tablet&&e(t.type,t.position,"tablet"),mobile:o.mobile&&e(t.type,t.position,"mobile")};return F(e=>!i[e],"flex")},l={...i(),...e("cg",t?.itemSpacing),...e("rg",t?.itemSpacing),...e("jc",t?.align),...o};return filterTruthyStyles(l)},getGalleryGridItemStyle=a=>{let l=y({shape:a.shape,shapeForBottom:a.shapeForBottom,shapeFor1Col:a.shapeFor1Col,shapeFor2Col:a.shapeFor2Col,shapeForFtOnly:a.shapeForFtOnly,shapeForInsideBottom:a.shapeForInsideBottom,shapeForInside:a.shapeForInside},a.position),s=o(l),n=S({shapeByLayout:l,itemSpacing:a.itemSpacing}),p={"max-width":"100%","outline-color":"var(--g-c-brand, brand)",...e("h",t(s)),...e("w",r(n)),...i({normal:a.corner})};return filterTruthyStyles(p)},getFeatureImageCarouselItemStyle=r=>{let a=o(r.ftShape),l={"max-width":"100%","outline-color":"var(--g-c-brand, brand)",...i({normal:r?.ftCorner}),...e("h",t(a))};return filterTruthyStyles(l)},getGalleryCarouselStyle=e=>{let t=y({shape:e.shape,shapeForBottom:e.shapeForBottom,shapeFor1Col:e.shapeFor1Col,shapeFor2Col:e.shapeFor2Col,shapeForFtOnly:e.shapeForFtOnly,shapeForInsideBottom:e.shapeForInsideBottom,shapeForInside:e.shapeForInside},e.position),o=o=>{let r=a(e?.position,o),i="bottom-center"===r||"inside-bottom"===r,l="inside-left"===r||"inside-right"===r||"left"===r||"right"===r,s=a(t,o);return i||l||!s?.width?"100%":s.width},r={spacing:g(e?.itemSpacing),sizeSetting:{desktop:{width:o("desktop"),height:"100%"},tablet:{width:o("tablet"),height:"100%"},mobile:{width:o("mobile"),height:"100%"}}};return filterTruthyStyles(r)},getGalleryCarouselItemStyle=a=>{let l=y({shape:a.shape,shapeForBottom:a.shapeForBottom,shapeFor1Col:a.shapeFor1Col,shapeFor2Col:a.shapeFor2Col,shapeForFtOnly:a.shapeForFtOnly,shapeForInsideBottom:a.shapeForInsideBottom,shapeForInside:a.shapeForInside},a.position),s=e("minw",r(c({shapeByLayout:l,position:a.position,spacing:a.itemSpacing}))),n=e("maxw",r(c({shapeByLayout:l,position:a.position,spacing:a.itemSpacing}))),p=e("w",r(I({shapeByLayout:l,position:a.position}))),h=e("h",t(o(l))),m={"outline-color":"var(--g-c-brand, brand)",...s,...n,...p,...h,...i({normal:a.corner})};return filterTruthyStyles(m)},getFeaturedImageCarouselStyle=e=>{let t=t=>{let o=a(e.ftShape,t);return o?.width??"100%"},o={playSpeed:e?.ftAnimationSpeed,sizeSetting:{desktop:{width:t("desktop"),height:"auto"},tablet:{width:t("tablet"),height:"auto"},mobile:{width:t("mobile"),height:"auto"}},align:{desktop:a(e?.align,"desktop"),tablet:a(e?.align,"tablet"),mobile:a(e?.align,"mobile")}};return filterTruthyStyles(o)},getFeaturedImageOnlyOneImageStyle=({setting:r,options:a})=>{let n=o(r?.ftShape),p={...l("w",s(r?.ftShape,!1,!0),{desktop:"--g-ct-w",tablet:"--g-ct-w",mobile:"--g-ct-w"}),...a?.enableRadius&&i({normal:r?.ftCorner}),...a?.enableHeight&&e("h",t(n))};return filterTruthyStyles(p)};export{getFeatureImageCarouselItemStyle,getFeatureImageStyle,getFeaturedImageCarouselStyle,getFeaturedImageOnlyOneImageStyle,getGalleryCarouselItemStyle,getGalleryCarouselStyle,getGalleryGridItemStyle,getGalleryGridStyle,getGalleryImageStyle,getWrapContainerStyle};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as e,jsxs as o}from"react/jsx-runtime";import{memo as
|
|
1
|
+
import{jsx as e,jsxs as o}from"react/jsx-runtime";import{memo as t}from"react";import{useCurrentDevice as r,getResponsiveValueByScreen as a,makeStyleResponsive as s}from"@gem-sdk/core";import{handleMouseMove as m,handleMouseOut as i}from"../../common/hoverAction.js";import{getProductImagesStyles as l}from"../../composables/getProductImagesStyles.js";import{getProductImagesClassName as n}from"../../composables/getProductImagesClassName.js";import{getProductImagesAttr as d}from"../../composables/getProductImagesAttr.js";import{createStyle as u}from"@gem-sdk/system";import{getFeaturedImageOnlyOneImageStyle as c}from"../../common/styles.js";import g from"../../../../../carousel/components/root/Carousel.js";import p from"../../../../../carousel/components/item/CarouselItem.js";import f from"./ProductFeaturedImageOnly.js";import{useProductFeaturedImageCarousel as h}from"../../hooks/useProductFeaturedImageCarousel.js";let ProductFeaturedImageCarousel=t=>{let{productImages:C,imgRef:I,onHandleClick:v,onClickArrow:j,onHandleLoaded:y,onHandleUpdateActiveIndex:P,builderPropUID:b,builderPropsClass:k,children:w,parentUid:M,...x}=t,{ref:A,imageActive:F,imageActiveIndex:H,imageShowWhenHover:N,enableOpenLightBox:O,filteredProductImages:R,isRenderFeatureCarousel:S,genRandomKey:B,getAspectRatioFinal:W,emitUpdateActiveIndex:L}=h(t),T=r(),{galleryItemClasses:$,featureImageOnlyOneImageClasses:D}=n(x),{featuredImageCarouselStyle:q,featureImageCarouselItemStyle:z}=l(x),E=u({...c({setting:x,options:{enableRadius:!0,enableHeight:!0}})}),{featuredImageCarouselSettingAttrs:G}=d(x);return e("div",{ref:A,"data-slot":"children",className:"product-feature-image",children:S?o(g,{parentClass:k,elmRef:I,setting:G,styles:q,builderProps:{uid:b},isHiddenArrowWhenDisabled:!0,onLoaded:e=>y&&y(e),onChangeActive:e=>L(e),onClickArrow:()=>j&&j(B()),moveToIdx:H,disableMarginAuto:!0,onHandleChangeSlideByInteraction:e=>{let o=R?.length??0,t=e>=o?0:e;v(R?.[t]?.id??"",O)},children:[w,R?.map(o=>e(p,{contentType:"productImage",className:$("gp-ft-image-item !gp-min-w-full !gp-max-w-full"),onClickItem:()=>{let e=a(x?.ftClickOpenLightBox,T);"none"!==e&&v(o?.id??"",O)},style:z,onMouseMove:e=>m(e,x),onMouseOut:e=>i(e),children:e(f,{image:o,imageShowWhenHover:N,setting:x,aspectRatio:W()})},o?.id))]}):e("div",{ref:I,className:"gp-flex gp-w-full",style:{...s("jc",x?.align)},"data-id":b,children:e("div",{"aria-hidden":"true",className:D,style:E,onMouseMove:e=>m(e,x),onMouseOut:e=>i(e),onBlur:()=>void 0,onClick:()=>{v(F?.id??"",O)},children:e(f,{image:F,imageShowWhenHover:N,setting:x,aspectRatio:W(F)})})})})};var ProductFeaturedImageCarousel$1=t(ProductFeaturedImageCarousel);export{ProductFeaturedImageCarousel$1 as default};
|
package/dist/esm/product/components/product-images-v2/components/child/ProductGalleryGrid.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as e,Fragment as o,jsxs as t}from"react/jsx-runtime";import{useCurrentDevice as r,cls as i,getResponsiveValueByScreen as a,makeStyle as l}from"@gem-sdk/core";import{memo as m}from"react";import{getAspectRatio as s}from"../../common/common.js";import c from"../../../../../image/components/NextImage.js";import d from"../lightbox/ButtonOpenLightBox.js";import n from"./MediaIcon.js";import{isFeatureMedia as
|
|
2
|
-
${m&&M?"gem-slider-item-active":""}`),onClick:()=>T(o?.id||"",E),style:A,onMouseMove:e=>
|
|
1
|
+
import{jsx as e,Fragment as o,jsxs as t}from"react/jsx-runtime";import{useCurrentDevice as r,cls as i,getResponsiveValueByScreen as a,makeStyle as l}from"@gem-sdk/core";import{memo as m}from"react";import{getAspectRatio as s}from"../../common/common.js";import c from"../../../../../image/components/NextImage.js";import d from"../lightbox/ButtonOpenLightBox.js";import n from"./MediaIcon.js";import{isFeatureMedia as p,getZoomImageClass as g,getZoomLenClass as h}from"../../common/productFeaturedImage.js";import{handleMouseMove as y,handleMouseOut as u}from"../../common/hoverAction.js";import{getProductImagesClassName as f}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as v}from"../../composables/getProductImagesStyles.js";import{useProductGalleryGrid as j}from"../../hooks/useProductGalleryGrid.js";let ProductGalleryGrid=m=>{let{builderPropUID:G,productImages:w,onHandleClick:T,activeIndexFormFeatureImage:x,children:P,isHiddenInteraction:b,...I}=m,{isDisplay:N,shapeByLayout:$,imageActiveIndex:k,enableOpenLightBox:E,isEnableBorderActive:M,filteredProductImages:z}=j(m),B=r(),{galleryGridWrapperClasses:H,galleryItemClasses:O}=f(I),{galleryGridStyles:Z,galleryGridItemStyles:A}=v(I);return e(o,{children:N&&t("div",{"data-slot":"children","data-id":G,className:H,style:Z,"gp-data-hidden":`${b}`,children:[z?.map((o,r)=>{let m=r===k,f=p(o.contentType)?o.previewImage:o.src;return t("div",{"aria-hidden":!0,className:O(`gem-slider-item-${G}
|
|
2
|
+
${m&&M?"gem-slider-item-active":""}`),onClick:()=>T(o?.id||"",E),style:A,onMouseMove:e=>y(e,{hoverEffect:I.galleryHoverEffect,zoom:I.galleryZoom,zoomType:I.galleryZoomType}),onMouseOut:e=>u(e),"data-border":m&&I?.borderActive?"active":"deactive",children:[e(c,{src:f,width:o?.width,height:o?.height,alt:o?.alt,setting:{aspectRatio:s($),layout:I?.layout},style:{width:"100%",height:"100%"}},o?.id),e(n,{contentType:o?.contentType||""}),I?.galleryHoverEffect!=="none"&&!p(o?.contentType)&&e(c,{src:f,width:o?.width,height:o?.height,alt:o?.alt,setting:{layout:I.layout,aspectRatio:s($)},className:i("hover-image !gp-max-w-none",g())}),I?.galleryHoverEffect=="zoom"&&I?.galleryZoomType=="glasses"&&["one-col","two-col"].includes(a(I.position,B)||"")&&!p(o?.contentType)&&e("div",{className:i(h(),"room-len"),style:{...l({bgi:`url("${o?.src}")`})}}),a(I?.clickOpenLightBox,B)&&e(d,{})]},o?.id)}),P]})})};var ProductGalleryGrid$1=m(ProductGalleryGrid);export{ProductGalleryGrid$1 as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as e,Fragment as r,jsxs as
|
|
1
|
+
import{jsx as e,Fragment as r,jsxs as o}from"react/jsx-runtime";import{cls as a}from"@gem-sdk/core";import l from"../gallery-carousel/GalleryCarousel.js";import i from"../child/ProductGalleryGrid.js";import t from"../child/ProductFeaturedImageCarousel.js";import{getProductImagesStyles as d}from"../../composables/getProductImagesStyles.js";import{getProductImagesClassName as s}from"../../composables/getProductImagesClassName.js";import{useFeatureImageWithGallery as m}from"../../hooks/useFeatureImageWithGallery.js";let FeatureImageWithGallery=u=>{let{setting:c,styles:n,builderProps:p,gallery:g,onHandleClickImage:I,priorityFeatureImage:f,children:h,noDataChildren:y}=u,C={...c,...n},{isShowCarousel:F,featureImageHeight:P,featureWrapperImage:b,onClickFeatureArrow:j,activeIndexFromFeatureImage:k,setOnClickFeatureArrow:v,onHandleLoadedFeatureImage:G,setActiveIndexFromFeatureImage:H}=m(u);if(g?.[0]?.id==="noImageError")return e(r,{children:y});let{ftImageGalleryClasses:x,imageGalleryWrapperClasses:N}=s(u),{wrapperFeaturedImageStyle:U,featureImageStyle:w,galleryImageStyle:A}=d(C,{gallery:g,featureImageHeight:P});return o("div",{className:a("gp-grid gp-w-full gp-relative"),style:U,children:[e("div",{className:x,style:w,children:e(t,{imgRef:b,productImages:g,...C,onHandleClick:(e,r)=>I(e||"",r),onHandleLoaded:G,onHandleUpdateActiveIndex:H,onClickArrow:e=>v(e),builderPropUID:p?.uid,builderPropsClass:`gp-product-images-feature-${p?.uid}`,children:h})}),g.length>1&&e("div",{className:N,style:A,children:F?e(l,{productImages:g,position:C?.position,...C,builderPropUID:p?.uid,onHandleClick:(e,r)=>I(e||"",r),activeIndexFormFeatureImage:k,priorityFeatureImage:f,onClickFeatureArrow:j,builderPropsClass:`gp-product-images-gallery-${p?.uid}`}):e(i,{productImages:g,...C,builderPropUID:p?.uid,onHandleClick:(e,r)=>I(e||"",r),activeIndexFormFeatureImage:k,isHiddenInteraction:!0})})]})};export{FeatureImageWithGallery as default};
|
|
@@ -1,79 +1,79 @@
|
|
|
1
|
-
import{makeStyleResponsive as e,template as a,cls as i}from"@gem-sdk/core";import{getAspectRatio as t,getPaddingBottomByShapeSetting as r,getSrcImage as s}from"../../common/common.js";import{checkRenderFeaturedCarousel as d,
|
|
1
|
+
import{makeStyleResponsive as e,template as a,cls as i}from"@gem-sdk/core";import{getAspectRatio as t,getPaddingBottomByShapeSetting as r,getSrcImage as s}from"../../common/common.js";import{checkRenderFeaturedCarousel as d,getZoomImageClass as o,getZoomLenClass as u}from"../../common/productFeaturedImage.js";import m from"../../../../../video/components/HTML5Embed.liquid.js";import l from"../../../../../image/components/Modal3d.liquid.js";import g from"../../../../../image/components/NextImage.liquid.js";import p from"../../../../../image/components/Video.liquid.js";import{getStyleOfObject as n}from"../../../../helpers/function.js";import{getProductImagesStyles as c}from"../../composables/getProductImagesStyles.js";import{getProductImagesClassName as f}from"../../composables/getProductImagesClassName.js";import{getProductImagesAttr as h}from"../../composables/getProductImagesAttr.js";import{LiquidIf as y,LiquidFor as M,Liquid as $,If as _}from"@gem-sdk/system";import b from"../../../../../carousel/components/root/Carousel.liquid.js";import w from"../../../../../carousel/components/item/CarouselItem.liquid.js";let FeatureImageWithGallery=({builderPropUID:v,children:I,enableLazyLoadImage:x,...q})=>{let{featuredImageCarouselClasses:z,galleryItemClasses:j,featuredCarouselItemClasses:S}=f(q),{featuredImageCarouselStyle:R,featureImageStyle:W,featureImageCarouselOnlyOneImageStyle:P,featureImageOnlyOneImageStyle:C,featureImageCarouselItemStyle:T}=c(q),{featuredImageCarouselSettingAttrs:L}=h(q),N=t(q.ftShape),k=()=>`
|
|
2
2
|
{% case featureMedia.media_type %}
|
|
3
3
|
{% when 'image' %}
|
|
4
|
-
${
|
|
4
|
+
${D()}
|
|
5
5
|
{% when 'external_video' %}
|
|
6
6
|
{% assign mediaSourceVideo = featureMedia | external_video_url %}
|
|
7
|
-
${
|
|
7
|
+
${O()}
|
|
8
8
|
{% when 'video' %}
|
|
9
9
|
{% assign mediaSourceVideo = featureMedia.sources.last.url %}
|
|
10
|
-
${V()}
|
|
11
|
-
{% when 'model' %}
|
|
12
10
|
${A()}
|
|
11
|
+
{% when 'model' %}
|
|
12
|
+
${E()}
|
|
13
13
|
{% else %}
|
|
14
|
-
${
|
|
14
|
+
${F()}
|
|
15
15
|
{% endcase %}
|
|
16
|
-
`,
|
|
17
|
-
${
|
|
18
|
-
${
|
|
19
|
-
${
|
|
16
|
+
`,E=()=>l({src:y("featureMedia.sources.first.url contains '.glb'","{{ featureMedia.sources.first.url }}","{{featureMedia.sources.last.url}}"),alt:"{{featureMedia.preview_image.alt}}",poster:"{{featureMedia.preview_image.src | product_img_url: '1024x1024'}}",cameraControls:!0,arStatus:"not-presenting",style:{width:"100%"},aspectRatio:N}),O=()=>p({src:"{{mediaSourceVideo}}",alt:"{{featureMedia.alt | escape}}",autoplay:!1,allowfullscreen:!0,controls:!0,style:{width:"100%",height:"100%"},aspectRatio:N}),A=()=>m({src:"{{mediaSourceVideo}}",title:"{{featureMedia.alt | escape}}",autoplay:!1,controls:!0,thumbnail:"{{featureMedia.preview_image.src | product_img_url: '1024x1024'}}",isCheckLoaded:!0,style:{width:"100%","max-height":"100%"},className:"gp-invisible"}),D=()=>a`
|
|
17
|
+
${V(i("gp-w-full gp-transition-opacity",{"group-hover:gp-opacity-0":"other"==q.hoverEffect},"{{shouldHidden}}"))}
|
|
18
|
+
${_(q?.hoverEffect!=="none",`<div class="${i("zoom-element !gp-max-w-none",o())}">
|
|
19
|
+
${V("image-zoom",!0)}
|
|
20
20
|
</div>`," ")}
|
|
21
|
-
${
|
|
22
|
-
`,
|
|
21
|
+
${_(q?.hoverEffect=="zoom"&&q?.zoomType=="glasses",`<div class="${i("zoom-lens-element",u())}" style="opacity: 0; background-image: url('{{ featureMedia.src | img_url: "1024x1024"}}')"></div>`," ")}
|
|
22
|
+
`,V=(e,i)=>a`
|
|
23
23
|
{% assign src = featureMedia.src %}
|
|
24
|
-
${
|
|
25
|
-
{% assign other_image_index = ${
|
|
24
|
+
${_(i&&"other"==q.hoverEffect,`{% assign media_length = product.media | size %}
|
|
25
|
+
{% assign other_image_index = ${q.otherImage} | plus: 0 %}
|
|
26
26
|
{% if other_image_index >= media_length %}
|
|
27
27
|
{% assign other_image_index = media_length | minus: 1 %}
|
|
28
28
|
{% endif %}
|
|
29
29
|
{% assign otherImage = product.media[other_image_index] %}
|
|
30
|
-
${
|
|
30
|
+
${y("otherImage.media_type != 'image'","{% assign src = otherImage.preview_image.src %}","{% assign src = otherImage.src %}")}
|
|
31
31
|
`)}
|
|
32
|
-
${
|
|
33
|
-
${
|
|
34
|
-
${
|
|
32
|
+
${g({srcIsLiquidCode:!0,src:y("src != null",s("src"),"https://cdn.shopify.com/s/assets/no-image-2048-5e88c1b20e087fb7bbe9a3771824e743c244f437e4f8ba93bbf7b11b53f7824c_large.gif"),id:y("featureMedia != null","{{featureMedia.id}}"),width:"{{featureMedia.width}}",height:"{{featureMedia.height}}",alt:"{{featureMedia.alt | escape}}",srcset:`${s("src")}`,baseSrc:"{{src | image_url}}",sizes:"(max-width: 768px) 50vw, 100vw",setting:{layout:q?.ftLayout,aspectRatio:N,qualityType:q?.qualityType,qualityPercent:q?.qualityPercent},priority:q?.preload,className:`gp-w-full gp-h-full gp-absolute gp-top-0 gp-left-0 featured-image-only gp-cursor-pointer !gp-rounded-none ${e}`,enableLazyLoadImage:x})}`,F=()=>a`
|
|
33
|
+
${g({srcIsLiquidCode:!0,src:"https://cdn.shopify.com/s/assets/no-image-2048-5e88c1b20e087fb7bbe9a3771824e743c244f437e4f8ba93bbf7b11b53f7824c_large.gif",alt:"No Image",sizes:"(max-width: 768px) 50vw, 100vw",setting:{layout:q?.ftLayout,aspectRatio:N,qualityType:q?.qualityType,qualityPercent:q?.qualityPercent},priority:q?.preload,className:"gp-w-full gp-h-full gp-absolute gp-top-0 gp-left-0 featured-image-only gp-cursor-pointer !gp-rounded-none",enableLazyLoadImage:x})}`,H=r(q.ftShape),G=a=>`
|
|
34
|
+
${$(`{% assign productImageWidth = 0 %}
|
|
35
35
|
{% case featureMedia.media_type %}
|
|
36
36
|
{% when 'image' %}
|
|
37
37
|
{% assign productImageWidth = featureMedia.width %}
|
|
38
38
|
{% else %}
|
|
39
39
|
{% assign productImageWidth = featureMedia.preview_image.width %}
|
|
40
40
|
{% endcase %}`)}
|
|
41
|
-
${
|
|
41
|
+
${w({id:"{{section.id}}-{{imageID}}",contentType:"productImage",className:`${j(`gp-ft-image-item !gp-min-w-full !gp-max-w-full' ${a}`)}`,parentId:`${v}-{{section.id}}-{{product.id}}`,style:T,customStyle:{width:"{{productImageWidth}}px"},children:`
|
|
42
42
|
<div
|
|
43
|
-
class="gp-w-full gp-relative ${
|
|
44
|
-
style="${
|
|
43
|
+
class="gp-w-full gp-relative ${y("featureMedia == null or featureMedia.media_type == 'image'","{{ 'gp-h-0' }}","{{ 'gp-h-full !gp-pb-0' }}")}"
|
|
44
|
+
style="${n(e("pb",H))} ${y("featureMedia.media_type == 'video' or featureMedia.media_type == 'external_video'","{{ 'display: flex; align-items: center; justify-content: center' }}")}"
|
|
45
45
|
>
|
|
46
|
-
${
|
|
46
|
+
${k()}
|
|
47
47
|
</div>
|
|
48
|
-
`})}`,
|
|
49
|
-
${
|
|
48
|
+
`})}`,J=d(q),B="gp-featured-image-wrapper",K=y("product.media.size > 0",`${I||""} {% assign largestRatio = 0 %}
|
|
49
|
+
${M("featureMedia in product.media",`
|
|
50
50
|
{% assign height = featureMedia.height | times: 1.0 %}
|
|
51
51
|
{% assign width = featureMedia.width | times: 1.0 %}
|
|
52
52
|
{% assign ratio = height | divided_by: width %}
|
|
53
|
-
${
|
|
53
|
+
${y("ratio > largestRatio","{% assign largestRatio = ratio %}")}
|
|
54
54
|
`)}
|
|
55
|
-
${
|
|
56
|
-
${
|
|
57
|
-
`,
|
|
58
|
-
${
|
|
59
|
-
`,
|
|
55
|
+
${M("featureMedia in product.media",`${y("featureMedia.media_type == 'image'",`${M("image in product.images",y("image.src == featureMedia.src","{% assign imageID = image.id %}{% break %}"))}`,"{% assign imageID = '' %}")}
|
|
56
|
+
${G()}`)}
|
|
57
|
+
`,g({src:"https://cdn.shopify.com/s/assets/no-image-2048-5e88c1b20e087fb7bbe9a3771824e743c244f437e4f8ba93bbf7b11b53f7824c_large.gif",id:"noImageError",width:"480",height:"480",alt:"no image",priority:q?.preload,setting:{layout:q?.ftLayout,aspectRatio:N,qualityType:q?.qualityType,qualityPercent:q?.qualityPercent},style:{height:"100%"},className:"gp-w-full featured-image-only !gp-rounded-none",customLazyload:!0,enableLazyLoadImage:x})),Q=()=>`
|
|
58
|
+
${b({builderProps:{uid:v},rootId:`ft-${v}-{{section.id}}-{{product.id}}`,conditionAppendJs:"product.media.size > 1",wrapperClass:B,rootClass:`${z}`,rootAttrs:{type:"gp-feature-image-carousel","product-id":"{{product.id}}","product-media":"{{product.media.size}}"},isHiddenArrowWhenDisabled:!0,setting:L,rootStyles:W,styles:R,style:{playSpeed:600},disableMarginAuto:!0,children:K})}
|
|
59
|
+
`,U=()=>{switch(q?.preDisplay){case"1st-images":return`
|
|
60
60
|
{% assign featureMedia = product.media.first %}
|
|
61
|
-
`;case"1st-3d-mode":return
|
|
61
|
+
`;case"1st-3d-mode":return M("media in product.media",y("media.media_type == 'model'","{% assign featureMedia = media %}{% break %}"));case"1st-video":return M("media in product.media",y("media.media_type == 'video' or media.media_type == 'external_video'","{% assign featureMedia = media %}{% break %}"));default:return`
|
|
62
62
|
{% assign featureMedia = variant.featured_media %}
|
|
63
63
|
{% unless featureMedia %}
|
|
64
64
|
{% assign featureMedia = product.featured_media %}
|
|
65
65
|
{% endunless %}
|
|
66
|
-
`}},
|
|
66
|
+
`}},X=()=>$(`
|
|
67
67
|
{% assign featureMedia = variant.featured_media %}
|
|
68
68
|
{% unless featureMedia %}
|
|
69
69
|
{% assign featureMedia = product.featured_media %}
|
|
70
70
|
{% endunless %}
|
|
71
|
-
${
|
|
71
|
+
${y("product.media.size > 1",U())}
|
|
72
72
|
{% assign largestRatio = 0 %}
|
|
73
73
|
{% assign height = featureMedia.height | times: 1.0 %}
|
|
74
74
|
{% assign width = featureMedia.width | times: 1.0 %}
|
|
75
75
|
{% assign ratio = height | divided_by: width %}
|
|
76
|
-
${
|
|
76
|
+
${y("ratio > largestRatio","{% assign largestRatio = ratio %}")}
|
|
77
77
|
{% assign productImageWidth = 0 %}
|
|
78
78
|
{% case featureMedia.media_type %}
|
|
79
79
|
{% when 'image' %}
|
|
@@ -81,38 +81,38 @@ import{makeStyleResponsive as e,template as a,cls as i}from"@gem-sdk/core";impor
|
|
|
81
81
|
{% else %}
|
|
82
82
|
{% assign productImageWidth = featureMedia.preview_image.width %}
|
|
83
83
|
{% endcase %}
|
|
84
|
-
${
|
|
84
|
+
${y("featureMedia == null","{% assign productImageWidth = 1600 %}")}
|
|
85
85
|
<div
|
|
86
86
|
class='gp-feature-image-carousel gp-feature-image-only'
|
|
87
|
-
style="${
|
|
87
|
+
style="${n(W)}"
|
|
88
88
|
>
|
|
89
89
|
<div
|
|
90
90
|
class="gp-relative"
|
|
91
|
-
style="${
|
|
91
|
+
style="${n(C)}"
|
|
92
92
|
>
|
|
93
|
-
${
|
|
93
|
+
${I}
|
|
94
94
|
<div
|
|
95
95
|
type="gp-feature-image-only"
|
|
96
96
|
product-id="{{product.id}}"
|
|
97
97
|
product-media="{{product.media.size}}"
|
|
98
|
-
class="${
|
|
99
|
-
style="${
|
|
98
|
+
class="${S(B)}"
|
|
99
|
+
style="${n(P)}"
|
|
100
100
|
>
|
|
101
101
|
<div
|
|
102
|
-
class="gp-w-full gp-relative ${
|
|
103
|
-
style="${
|
|
102
|
+
class="gp-w-full gp-relative ${y("featureMedia == null or featureMedia.media_type == 'image'","{{ 'gp-h-0' }}","{{ 'gp-h-full !gp-pb-0' }}")}"
|
|
103
|
+
style="${n(e("pb",H))} ${y("featureMedia.media_type == 'video' or featureMedia.media_type == 'external_video'","{{ 'display: flex; align-items: center; justify-content: center' }}")}"
|
|
104
104
|
>
|
|
105
|
-
${
|
|
105
|
+
${k()}
|
|
106
106
|
</div>
|
|
107
107
|
</div>
|
|
108
108
|
</div>
|
|
109
109
|
</div>
|
|
110
|
-
`);return
|
|
110
|
+
`);return $(`
|
|
111
111
|
{% capture featureImageOnlyOne %}
|
|
112
|
-
${
|
|
112
|
+
${X()}
|
|
113
113
|
{% endcapture %}
|
|
114
|
-
${
|
|
115
|
-
${
|
|
116
|
-
${
|
|
114
|
+
${y("product.media.size > 1",`
|
|
115
|
+
${_(J,Q()," ")}
|
|
116
|
+
${_(!J,"{{ featureImageOnlyOne }}"," ")}
|
|
117
117
|
`,"{{ featureImageOnlyOne }}")}
|
|
118
118
|
`)};export{FeatureImageWithGallery as default};
|
package/dist/esm/product/components/product-images-v2/components/gallery-carousel/GalleryCarousel.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as e,Fragment as o,jsxs as t}from"react/jsx-runtime";import{useCurrentDevice as r}from"@gem-sdk/core";import{getAspectRatio as s}from"../../common/common.js";import{getEditorMinHeightClass as
|
|
1
|
+
import{jsx as e,Fragment as o,jsxs as t}from"react/jsx-runtime";import{useCurrentDevice as r}from"@gem-sdk/core";import{getAspectRatio as s}from"../../common/common.js";import{getEditorMinHeightClass as i}from"../../common/productGallery.js";import{getProductImagesClassName as m}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as a}from"../../composables/getProductImagesStyles.js";import{getProductImagesAttr as l}from"../../composables/getProductImagesAttr.js";import{isFeatureMedia as c}from"../../common/productFeaturedImage.js";import d from"../child/MediaIcon.js";import n from"../lightbox/ButtonOpenLightBox.js";import p from"../../../../../image/components/NextImage.js";import u from"../../../../../carousel/components/root/Carousel.js";import g from"../../../../../carousel/components/item/CarouselItem.js";import{useGalleryCarousel as y}from"../../hooks/useGalleryCarousel.js";import{If as f}from"@gem-sdk/system";let ProductGalleryCarousel=h=>{let{builderPropUID:j,productImages:I,activeIndexFormFeatureImage:b,onClickFeatureArrow:C,builderPropsClass:P,arrow:v,priorityFeatureImage:T,...x}=h,w=r(),{galleryItemClasses:k}=m(x),{galleryCarouselSettingAttrs:q}=l(x),{galleryCarouselStyle:A,galleryCarouselItemStyle:G}=a(x),{moveToIdx:N,isDisplay:$,shapeByLayout:B,isEnableBorderActive:L,isShowButtonLightbox:M,filteredProductImages:D,handleClickCarouselItem:F,safeMoveToIdx:H,setSliderReady:O}=y(h);return e(o,{children:$&&e(u,{parentClass:P,rootClass:P,setting:q,styles:A,slidesClass:i(w,x.position,x.navigationPosition),builderProps:{uid:`${j}-carousel`},moveToIdx:H,isHiddenArrowWhenDisabled:!0,disableMarginAuto:!0,onLoaded:e=>{e&&O(!0)},children:D?.map((o,r)=>{let i=r===N,m=c(o.contentType)?o.previewImage:o.src;return t(g,{contentType:"productImage",className:k(`gp-gallery-image-item gem-slider-item-${j} ${i&&L?"gem-slider-item-active":""}`),onClickItem:()=>F(o?.id),style:G,"data-id":o?.id,"data-border":i&&x?.borderActive?"active":"deactive",children:[e(p,{draggable:"false",src:m,width:o?.width,height:o?.height,alt:o?.alt,setting:{aspectRatio:s(B),layout:x?.layout,qualityPercent:x?.qualityPercent,qualityType:x?.qualityType},style:{width:"100%",height:"100%",cursor:"pointer"},className:"product-list-image"}),e(d,{contentType:o?.contentType||""}),f(M,e(n,{}))]},o?.id)})})})};export{ProductGalleryCarousel as default};
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import{template as e,getResponsiveValueByScreen as
|
|
2
|
-
${
|
|
3
|
-
${
|
|
4
|
-
${
|
|
5
|
-
${
|
|
6
|
-
<div class="gp-w-full gp-relative
|
|
7
|
-
|
|
1
|
+
import{template as e,makeStyleResponsive as t,getResponsiveValueByScreen as i}from"@gem-sdk/core";import o from"../../../../../image/components/NextImage.liquid.js";import{getPaddingBottomByShapeSetting as r,getDisplayStyle as s,getAspectRatio as a,getSrcImage as p}from"../../common/common.js";import{getShapeByLayout as l,getMinHeightByPosition as d,checkDisplayGalleryByWidth as m,getZoomDisplay as g,getCarouselVerticalConfigByPosition as n}from"../../common/productGallery.js";import{getStyleOfObject as c}from"../../../../helpers/function.js";import{getProductImagesStyles as u}from"../../composables/getProductImagesStyles.js";import{getProductImagesClassName as C}from"../../composables/getProductImagesClassName.js";import{getProductImagesAttr as h}from"../../composables/getProductImagesAttr.js";import{LiquidIf as y,LiquidFor as b}from"@gem-sdk/system";import v from"../../../../../carousel/components/root/Carousel.liquid.js";import f from"../../../../../carousel/components/item/CarouselItem.liquid.js";let ProductGalleryCarousel=({builderPropUID:w,children:L,enableLazyLoadImage:F,...$})=>{let{featuredImageGalleryClasses:x,galleryItemClasses:I}=C($),{galleryCarouselSettingAttrs:_}=h($),{galleryCarouselStyle:k,galleryCarouselItemStyle:j}=u($),V=()=>{let e=(e,t,o)=>{let r=i(t,o),s=i(e,o),a="slider"===s&&("bottom-center"===r||"inside-bottom"===r),p=["left","right","inside-left","inside-right"].includes(r??"");return p||a},t=m({shapeByLayout:M}),o={desktop:t.desktop&&e($.type,$.position,"desktop"),tablet:t.tablet&&e($.type,$.position,"tablet"),mobile:t.mobile&&e($.type,$.position,"mobile")};return s(e=>!o[e],"flex")},M=l({shape:$.shape,shapeForBottom:$.shapeForBottom,shapeFor1Col:$.shapeFor1Col,shapeFor2Col:$.shapeFor2Col,shapeForFtOnly:$.shapeForFtOnly,shapeForInsideBottom:$.shapeForInsideBottom,shapeForInside:$.shapeForInside},$.position),P=(t,i)=>e`${o({srcIsLiquidCode:!0,src:`${p("media.preview_image")}`,width:"{{media.width}}",height:"{{media.height}}",alt:"{{media.alt | escape}}",setting:t,baseSrc:"{{media.preview_image | image_url}}",customLazyload:!0,style:i,className:"!gp-rounded-none gp-w-full gp-h-full gp-absolute gp-top-0 gp-left-0 gp-cursor-pointer",enableLazyLoadImage:F})}`,Z=r(M),q=e=>`
|
|
2
|
+
${y("media.media_type == 'video'","{% assign mediaSourceUrl = media.sources.last.url %}")}
|
|
3
|
+
${y("media.media_type == 'external_video'","{% assign mediaSourceUrl = media | external_video_url %}")}
|
|
4
|
+
${y("media.media_type == 'image'","{% assign mediaSourceUrl = media.src %}")}
|
|
5
|
+
${f({id:"{{imageID}}",contentType:"productImage",className:`${I(`gp-gallery-image-item ${e}`)}`,parentId:`${w}-{{product.id}}`,builderAttrs:{"data-outline":e?"active":"deactive"},style:j,children:`
|
|
6
|
+
<div class="gp-w-full gp-relative"
|
|
7
|
+
style="${c(t("pb",Z))};"
|
|
8
8
|
>
|
|
9
|
-
${
|
|
9
|
+
${P({aspectRatio:a(M),layout:$?.layout,qualityPercent:$?.qualityPercent,qualityType:$?.qualityType},{width:"100%",height:"100%",cursor:"pointer"})}
|
|
10
10
|
|
|
11
|
-
${
|
|
11
|
+
${y("media.media_type == 'video' or media.media_type == 'external_video'",`<div class="gp-absolute gp-pb-1 gp-pr-1 gp-right-0 gp-bottom-0" >
|
|
12
12
|
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
13
13
|
<rect opacity="0.9" width="24" height="24" rx="3" fill="#212121"/>
|
|
14
14
|
<path d="M17.6869 12.2646L17.6868 12.2646L6.78379 18.4464C6.78378 18.4464 6.78376 18.4464 6.78374 18.4464C6.52931 18.5903 6.1665 18.4179 6.1665 18.0416V5.95844C6.1665 5.58218 6.52917 5.40981 6.7836 5.55354C6.78366 5.55357 6.78373 5.55361 6.78379 5.55365L17.6868 11.7354L17.6869 11.7354C17.8819 11.846 17.8819 12.154 17.6869 12.2646Z" stroke="#F9F9F9" stroke-miterlimit="10"/>
|
|
15
15
|
</svg>
|
|
16
16
|
</div>`)}
|
|
17
|
-
${
|
|
17
|
+
${y("media.media_type == 'model'",`<div class="gp-absolute gp-pb-1 gp-pr-1 gp-right-0 gp-bottom-0">
|
|
18
18
|
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
19
19
|
<rect opacity="0.9" width="24" height="24" rx="3" fill="#212121"/>
|
|
20
20
|
<path fill-rule="evenodd" clip-rule="evenodd" d="M11.7441 4.57034C11.9017 4.47655 12.098 4.47655 12.2555 4.57034L18.5889 8.33957C18.7404 8.42971 18.8332 8.59296 18.8332 8.76923V15.2308C18.8332 15.407 18.7404 15.5703 18.5889 15.6604L12.2555 19.4297C12.098 19.5234 11.9017 19.5234 11.7441 19.4297L5.41079 15.6604C5.25932 15.5703 5.1665 15.407 5.1665 15.2308V8.76923C5.1665 8.59296 5.25932 8.42971 5.41079 8.33957L11.7441 4.57034ZM6.1665 9.64865V14.9465L11.4998 18.1206V12.8227L6.1665 9.64865ZM12.4998 12.8227V18.1206L17.8332 14.9465V9.64865L12.4998 12.8227ZM17.3555 8.76923L11.9998 11.9566L6.64417 8.76923L11.9998 5.58185L17.3555 8.76923Z" fill="#F9F9F9"/>
|
|
@@ -22,7 +22,7 @@ import{template as e,getResponsiveValueByScreen as t}from"@gem-sdk/core";import
|
|
|
22
22
|
</div>`)}
|
|
23
23
|
|
|
24
24
|
<div class="gp-absolute gp-inset-0 gp-flex gp-cursor-pointer gp-items-center gp-justify-center gp-bg-black/50 gp-opacity-0 gp-transition-opacity gp-duration-100 group-hover:gp-opacity-100"
|
|
25
|
-
style="${g(
|
|
25
|
+
style="${c(g($?.clickOpenLightBox))}"
|
|
26
26
|
>
|
|
27
27
|
<svg
|
|
28
28
|
height="100%"
|
|
@@ -40,7 +40,7 @@ import{template as e,getResponsiveValueByScreen as t}from"@gem-sdk/core";import
|
|
|
40
40
|
</svg>
|
|
41
41
|
</div>
|
|
42
42
|
</div>
|
|
43
|
-
`})}`,
|
|
44
|
-
${
|
|
45
|
-
${
|
|
43
|
+
`})}`,B=()=>{let e=n($.position),t=[e.desktop?"gp-px-0":"gp-py-0",e.tablet?"tablet:gp-px-0":"tablet:gp-py-0",e.mobile?"mobile:gp-px-0":"mobile:gp-py-0"];return` ${t.join(" ")}`},A=y("product.media.size > 1",b("media in product.media",`${y("media.media_type == 'image'",b("image in product.images",y("image.src == media.src","{% assign imageID = image.id %}{% break %}")),"{% assign imageID = '' %}")}
|
|
44
|
+
${y("media.id == product.featured_media.id ",q($?.borderActive?.border!=="none"?"active":""),q())}`));return e`
|
|
45
|
+
${v({builderProps:{uid:w},rootId:`${w}-{{product.id}}`,rootClass:`${x}`,rootAttrs:{type:"grid-carousel","product-media":"{{product.media.size}}"},wrapperClass:B(),slidesClass:d($.position,$.navigationPosition),isHiddenArrowWhenDisabled:!0,setting:_,rootStyles:{...V()},styles:k,disableMarginAuto:!0,children:A})}
|
|
46
46
|
`};export{ProductGalleryCarousel as default};
|
package/dist/esm/product/components/product-images-v2/components/gallery-grid/GalleryGrid.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import{jsx as r,Fragment as e}from"react/jsx-runtime";import
|
|
2
|
+
import{jsx as r,Fragment as e}from"react/jsx-runtime";import l from"../child/ProductGalleryGrid.js";let GalleryGrid=i=>{let{setting:d,styles:o,gallery:t,builderProps:a,noDataChildren:n,onHandleClickImage:c,children:m}=i,u={...d,...o};return t?.[0]?.id==="noImageError"?r(e,{children:n}):r(l,{productImages:t,enableHoverAction:!0,...u,builderPropUID:a?.uid,onHandleClick:(r,e)=>c(r||"",e),children:m})};export{GalleryGrid as default};
|