@gem-sdk/components 23.0.0-staging.12 → 23.0.0-staging.13

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.
Files changed (94) hide show
  1. package/dist/cjs/article/components/ArticleImage.js +1 -1
  2. package/dist/cjs/article/index.js +1 -1
  3. package/dist/cjs/cart/components/CartList.js +1 -1
  4. package/dist/cjs/cart/index.js +1 -1
  5. package/dist/cjs/collection/index.js +1 -1
  6. package/dist/cjs/grid/index.js +1 -1
  7. package/dist/cjs/header/components/kind/basic/index.js +1 -1
  8. package/dist/cjs/header/components/kind/modern/index.js +1 -1
  9. package/dist/cjs/header/index.js +1 -1
  10. package/dist/cjs/hero-banner/components/HeroBannerItem.js +1 -1
  11. package/dist/cjs/hero-banner/index.js +1 -1
  12. package/dist/cjs/image/common/adaptiveSources.js +1 -0
  13. package/dist/cjs/image/common/attrs.js +1 -1
  14. package/dist/cjs/image/common/helpers.js +1 -1
  15. package/dist/cjs/image/common/listContext.js +1 -1
  16. package/dist/cjs/image/common/listImageContext.js +1 -0
  17. package/dist/cjs/image/common/sizes.js +1 -0
  18. package/dist/cjs/image/common/srcset.js +1 -1
  19. package/dist/cjs/image/components/AdaptiveImage.js +1 -1
  20. package/dist/cjs/image/components/AdaptiveImage.liquid.js +10 -10
  21. package/dist/cjs/image/components/Image.js +1 -1
  22. package/dist/cjs/image/components/NextImage.js +1 -1
  23. package/dist/cjs/image/index.js +1 -1
  24. package/dist/cjs/image-comparison/common/attrs.js +1 -1
  25. package/dist/cjs/image-comparison/components/CompareImage.js +1 -1
  26. package/dist/cjs/image-comparison/index.js +1 -1
  27. package/dist/cjs/post-purchase/callout-banner/index.js +1 -1
  28. package/dist/cjs/post-purchase/product/index.js +1 -1
  29. package/dist/cjs/product/components/product-images/ProductImagesLightBox.js +1 -1
  30. package/dist/cjs/product/components/product-images-v2/components/child/ProductFeaturedImageOnly.js +1 -1
  31. package/dist/cjs/product/components/product-images-v2/components/child/ProductGalleryGrid.js +1 -1
  32. package/dist/cjs/product/components/product-images-v2/components/gallery-carousel/GalleryCarousel.js +1 -1
  33. package/dist/cjs/product/components/product-images-v2/components/lightbox/ProductImagesLightBox.js +1 -1
  34. package/dist/cjs/product/components/product-images-v3/components/child/ProductFeaturedImageOnly.js +1 -1
  35. package/dist/cjs/product/components/product-images-v3/components/child/ProductGalleryGrid.js +1 -1
  36. package/dist/cjs/product/components/product-images-v3/components/gallery-carousel/GalleryCarousel.js +1 -1
  37. package/dist/cjs/product/components/product-images-v3/components/lightbox/ProductImagesLightBox.js +1 -1
  38. package/dist/cjs/product/components/product-list/ProductListCarouselLayout.js +1 -1
  39. package/dist/cjs/product/components/product-list/ProductListGridLayout.js +1 -1
  40. package/dist/cjs/product/components/product-list/common/imagePriority.js +11 -11
  41. package/dist/cjs/product/components/product-list/common/imagePriorityHints.js +1 -0
  42. package/dist/cjs/product/components/product-list-v3/ProductListCarouselLayout.js +1 -1
  43. package/dist/cjs/product/components/product-list-v3/ProductListGridLayout.js +1 -1
  44. package/dist/cjs/product/index.js +1 -1
  45. package/dist/cjs/video/components/HTML5Embed.js +1 -1
  46. package/dist/cjs/video/components/LiteYouTubeEmbed.js +1 -1
  47. package/dist/esm/article/components/ArticleImage.js +1 -1
  48. package/dist/esm/article/index.js +1 -1
  49. package/dist/esm/cart/components/CartList.js +1 -1
  50. package/dist/esm/cart/index.js +1 -1
  51. package/dist/esm/collection/index.js +1 -1
  52. package/dist/esm/grid/index.js +1 -1
  53. package/dist/esm/header/components/kind/basic/index.js +1 -1
  54. package/dist/esm/header/components/kind/modern/index.js +1 -1
  55. package/dist/esm/header/index.js +1 -1
  56. package/dist/esm/hero-banner/components/HeroBannerItem.js +1 -1
  57. package/dist/esm/hero-banner/index.js +1 -1
  58. package/dist/esm/image/common/adaptiveSources.js +1 -0
  59. package/dist/esm/image/common/attrs.js +1 -1
  60. package/dist/esm/image/common/helpers.js +2 -2
  61. package/dist/esm/image/common/listContext.js +1 -1
  62. package/dist/esm/image/common/listImageContext.js +1 -0
  63. package/dist/esm/image/common/sizes.js +1 -0
  64. package/dist/esm/image/common/srcset.js +1 -1
  65. package/dist/esm/image/components/AdaptiveImage.js +1 -1
  66. package/dist/esm/image/components/AdaptiveImage.liquid.js +9 -9
  67. package/dist/esm/image/components/Image.js +1 -1
  68. package/dist/esm/image/components/NextImage.js +1 -1
  69. package/dist/esm/image/index.js +1 -1
  70. package/dist/esm/image-comparison/common/attrs.js +1 -1
  71. package/dist/esm/image-comparison/components/CompareImage.js +1 -1
  72. package/dist/esm/image-comparison/index.js +1 -1
  73. package/dist/esm/post-purchase/callout-banner/index.js +1 -1
  74. package/dist/esm/post-purchase/product/index.js +1 -1
  75. package/dist/esm/product/components/product-images/ProductImagesLightBox.js +1 -1
  76. package/dist/esm/product/components/product-images-v2/components/child/ProductFeaturedImageOnly.js +1 -1
  77. package/dist/esm/product/components/product-images-v2/components/child/ProductGalleryGrid.js +1 -1
  78. package/dist/esm/product/components/product-images-v2/components/gallery-carousel/GalleryCarousel.js +1 -1
  79. package/dist/esm/product/components/product-images-v2/components/lightbox/ProductImagesLightBox.js +1 -1
  80. package/dist/esm/product/components/product-images-v3/components/child/ProductFeaturedImageOnly.js +1 -1
  81. package/dist/esm/product/components/product-images-v3/components/child/ProductGalleryGrid.js +1 -1
  82. package/dist/esm/product/components/product-images-v3/components/gallery-carousel/GalleryCarousel.js +1 -1
  83. package/dist/esm/product/components/product-images-v3/components/lightbox/ProductImagesLightBox.js +1 -1
  84. package/dist/esm/product/components/product-list/ProductListCarouselLayout.js +1 -1
  85. package/dist/esm/product/components/product-list/ProductListGridLayout.js +1 -1
  86. package/dist/esm/product/components/product-list/common/imagePriority.js +12 -12
  87. package/dist/esm/product/components/product-list/common/imagePriorityHints.js +1 -0
  88. package/dist/esm/product/components/product-list-v3/ProductListCarouselLayout.js +1 -1
  89. package/dist/esm/product/components/product-list-v3/ProductListGridLayout.js +1 -1
  90. package/dist/esm/product/index.js +1 -1
  91. package/dist/esm/video/components/HTML5Embed.js +1 -1
  92. package/dist/esm/video/components/LiteYouTubeEmbed.js +1 -1
  93. package/dist/types/index.d.ts +1 -1
  94. package/package.json +1 -1
@@ -1,2 +1,2 @@
1
1
  'use client';
2
- import{jsx as e}from"react/jsx-runtime";import t from"../../../carousel-v3/components/item/CarouselItem.js";import o from"../../../carousel-v3/components/root/Carousel.js";import{isFeatureMedia as i}from"./common/productFeaturedImage.js";import l from"../../../image/components/NextImage.js";import{useFeaturedImageGlobal as s,cls as r}from"@gem-sdk/core";import"../../../modal/components/confirm.js";import m from"../../../modal/components/Modal.js";import{useMemo as n}from"react";let d=({builderPropUID:d,productImages:p,open:a,imageRatio:c,onHandleClose:g})=>{let h=s(),b=n(()=>{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};return e(m,{setting:{open:a},styles:{width:"80%"},closeOnClickOutside:!0,onClose:()=>g(),disableIframeClickEvent:!0,contentClass:"mobile:!gp-w-[100%] gp-px-2",children:e(o,{setting:{loop:{desktop:!1,mobile:!1,tablet:!1},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(o=>e(t,{className:`gem-slider-item gem-slider-item-${d} gp-flex gp-items-center gp-justify-center gp-px-4`,children:e(l,{src:i(o?.contentType)?o?.previewImage:o?.src,width:o?.width,height:o?.height,alt:o?.alt,"content-type":o?.contentType,setting:{aspectRatio:c},className:r("gp-h-full gp-w-full gp-object-contain")},o?.id)},o?.id))})})};export{d as default};
2
+ import{jsx as e}from"react/jsx-runtime";import t from"../../../carousel-v3/components/item/CarouselItem.js";import o from"../../../carousel-v3/components/root/Carousel.js";import{isFeatureMedia as i}from"./common/productFeaturedImage.js";import l from"../../../image/components/NextImage.js";import{useFeaturedImageGlobal as s,cls as r}from"@gem-sdk/core";import"../../../modal/components/confirm.js";import m from"../../../modal/components/Modal.js";import{useMemo as n}from"react";let d={desktop:"finest"},p=({builderPropUID:p,productImages:a,open:c,imageRatio:g,onHandleClose:h})=>{let b=s(),u=n(()=>{let e=a?.findIndex(e=>e.id===b?.id);return e&&e>0?e:0},[a,b]),f={desktop:a&&a.length>1,mobile:a&&a?.length>1,tablet:a&&a?.length>1};return e(m,{setting:{open:c},styles:{width:"80%"},closeOnClickOutside:!0,onClose:()=>h(),disableIframeClickEvent:!0,contentClass:"mobile:!gp-w-[100%] gp-px-2",children:e(o,{setting:{loop:{desktop:!1,mobile:!1,tablet:!1},slidesToShow:{desktop:1,tablet:1,mobile:1},defaultCurrentSlider:u,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:f},styles:{sizeSetting:{desktop:{height:"80vh"},tablet:{height:"80vh"},mobile:{height:"60vh"}}},moveToIdx:u,hiddenDotWhenOnlyOne:!0,isHiddenArrowWhenDisabled:!0,builderProps:{uid:p},children:a?.map(o=>e(t,{className:`gem-slider-item gem-slider-item-${p} gp-flex gp-items-center gp-justify-center gp-px-4`,children:e(l,{src:i(o?.contentType)?o?.previewImage:o?.src,width:o?.width,height:o?.height,alt:o?.alt,"content-type":o?.contentType,setting:{aspectRatio:g,qualityType:d},className:r("gp-h-full gp-w-full gp-object-contain")},o?.id)},o?.id))})})};export{p as default};
@@ -1,2 +1,2 @@
1
1
  'use client';
2
- import{jsx as e,Fragment as t,jsxs as r}from"react/jsx-runtime";import{useProduct as o,useCurrentDevice as i,useShopStore as a,useRenderMode as c,getResponsiveValueByScreen as n,cls as l,makeStyle as s}from"@gem-sdk/core";import{isFeatureMedia as h,getZoomImageClass as f,getZoomLenClass as p}from"../../common/productFeaturedImage.js";import m from"../../../../../image/components/NextImage.js";import g from"./ProductFeatureVideo.js";import{memo as d,useMemo as u}from"react";import y from"./MediaIcon.js";let T={src:"https://cdn.shopify.com/s/assets/no-image-2048-5e88c1b20e087fb7bbe9a3771824e743c244f437e4f8ba93bbf7b11b53f7824c_large.gif",id:"noImageError",width:480,height:480,alt:"no image",contentType:"IMAGE"};var b=d(({image:d,imageShowWhenHover:b,setting:v,aspectRatio:E})=>{let w=o(),I=i(),k=a(e=>e.storefrontUrl),{isEditMode:x,isPreviewSharePageMode:L}=c(),N=u(()=>"none"!==n(v.ftClickOpenLightBox,I),[I,v.ftClickOpenLightBox]),O=u(()=>!x&&["VIDEO","EXTERNAL_VIDEO"].includes(d?.contentType||"")&&!N,[x,d?.contentType,N]),j=u(()=>d?{...d,src:O?d.src:h(d?.contentType)?d?.previewImage:d.src}:T,[d,O]),R=u(()=>{if(L)return"javascript:void(0)";if(!k)return"#";let e=new URL(k);return w?`${e.protocol}//${e.host}/products/${w.handle}`:"#"},[k,w,L]),C=u(()=>v?.hoverEffect!=="none"&&!h(j?.contentType),[j?.contentType,v?.hoverEffect]),$=u(()=>v?.hoverEffect=="zoom"&&v?.zoomType=="glasses"&&!h(j?.contentType),[j?.contentType,v?.hoverEffect,v?.zoomType]);return e(t,{children:(t=>{if("product-link"===n(v.ftClickOpenLightBox,I)){let r=v.ftClickOpenNewTab?"_blank":"_self";return e("a",{title:w?.title,href:R,className:"gp-w-full",target:r,children:t})}return t})(e(t,{children:O?e(g,{type:j?.contentType,url:j.src??"",aspectRatio:E}):r(t,{children:[e(m,{draggable:"false",src:j.src,width:j?.width,height:j?.height,alt:j?.alt,setting:{aspectRatio:E,layout:v?.ftLayout},priority:v?.preload,className:"featured-image-only",style:{width:"100%",height:"100%",cursor:"pointer"}}),e(y,{contentType:j?.contentType??""}),C&&e(m,{draggable:"false",src:v?.hoverEffect==="other"?b?.src:j.src,width:v?.hoverEffect==="other"?b?.width:j.width,height:v?.hoverEffect==="other"?b?.height:j.height,alt:v?.hoverEffect==="other"?b?.alt:j.alt,setting:{layout:v.ftLayout,aspectRatio:E},style:{width:"100%",height:"100%"},className:l("hover-image featured-image-only !gp-max-w-none",f()),priority:v?.preload}),$&&e("div",{className:l(p(),"room-len"),style:{...s({bgi:`url("${j?.src}")`})}})]})}))})});export{b as default};
2
+ import{jsx as e,Fragment as t,jsxs as r}from"react/jsx-runtime";import{useProduct as o,useCurrentDevice as i,useShopStore as a,useRenderMode as c,getResponsiveValueByScreen as n,cls as l,makeStyle as s}from"@gem-sdk/core";import{isFeatureMedia as h,getZoomImageClass as p,getZoomLenClass as f}from"../../common/productFeaturedImage.js";import m from"../../../../../image/components/NextImage.js";import u from"./ProductFeatureVideo.js";import{memo as y,useMemo as g}from"react";import d from"./MediaIcon.js";let T={src:"https://cdn.shopify.com/s/assets/no-image-2048-5e88c1b20e087fb7bbe9a3771824e743c244f437e4f8ba93bbf7b11b53f7824c_large.gif",id:"noImageError",width:480,height:480,alt:"no image",contentType:"IMAGE"};var w=y(({image:y,imageShowWhenHover:w,setting:v,aspectRatio:E})=>{let b=o(),I=i(),q=a(e=>e.storefrontUrl),{isEditMode:P,isPreviewSharePageMode:k}=c(),x=g(()=>"none"!==n(v.ftClickOpenLightBox,I),[I,v.ftClickOpenLightBox]),L=g(()=>!P&&["VIDEO","EXTERNAL_VIDEO"].includes(y?.contentType||"")&&!x,[P,y?.contentType,x]),N=g(()=>y?{...y,src:L?y.src:h(y?.contentType)?y?.previewImage:y.src}:T,[y,L]),O=g(()=>{if(k)return"javascript:void(0)";if(!q)return"#";let e=new URL(q);return b?`${e.protocol}//${e.host}/products/${b.handle}`:"#"},[q,b,k]),j=g(()=>v?.hoverEffect!=="none"&&!h(N?.contentType),[N?.contentType,v?.hoverEffect]),z=g(()=>v?.hoverEffect=="zoom"&&v?.zoomType=="glasses"&&!h(N?.contentType),[N?.contentType,v?.hoverEffect,v?.zoomType]);return e(t,{children:(t=>{if("product-link"===n(v.ftClickOpenLightBox,I)){let r=v.ftClickOpenNewTab?"_blank":"_self";return e("a",{title:b?.title,href:O,className:"gp-w-full",target:r,children:t})}return t})(e(t,{children:L?e(u,{type:N?.contentType,url:N.src??"",aspectRatio:E}):r(t,{children:[e(m,{sizeTarget:"ProductFeatureImage",listAware:!0,src:N.src,width:N?.width,height:N?.height,alt:N?.alt,setting:{qualityType:v?.qualityType,qualityPercent:v?.qualityPercent,aspectRatio:E,layout:v?.ftLayout},priority:v?.preload,className:"featured-image-only",style:{width:"100%",height:"100%",cursor:"pointer"}}),e(d,{contentType:N?.contentType??""}),j&&e(m,{sizeTarget:"ProductFeatureImage",listAware:!0,src:v?.hoverEffect==="other"?w?.src:N.src,width:v?.hoverEffect==="other"?w?.width:N.width,height:v?.hoverEffect==="other"?w?.height:N.height,alt:v?.hoverEffect==="other"?w?.alt:N.alt,setting:{qualityType:v?.qualityType,qualityPercent:v?.qualityPercent,layout:v.ftLayout,aspectRatio:E},style:{width:"100%",height:"100%"},className:l("hover-image featured-image-only !gp-max-w-none",p()),priority:v?.preload}),z&&e("div",{className:l(f(),"room-len"),style:{...s({bgi:`url("${N?.src}")`})}})]})}))})});export{w as default};
@@ -1 +1 @@
1
- import{jsx as e,Fragment as o,jsxs as t}from"react/jsx-runtime";import{isFeatureMedia as r,getZoomImageClass as i,getZoomLenClass as a}from"../../common/productFeaturedImage.js";import{getProductImagesClassName as m}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as l}from"../../composables/getProductImagesStyles.js";import{useCurrentDevice as s,cls as c,getResponsiveValueByScreen as n,makeStyle as d}from"@gem-sdk/core";import{handleMouseOut as p,handleMouseMove as g}from"../../common/hoverAction.js";import{useProductGalleryGrid as h}from"../../hooks/useProductGalleryGrid.js";import y from"../../../../../image/components/NextImage.js";import f from"../lightbox/ButtonOpenLightBox.js";import{getAspectRatio as u}from"../../common/common.js";import v from"./MediaIcon.js";import{memo as j}from"react";var w=j(j=>{let{builderPropUID:w,productImages:T,onHandleClick:x,activeIndexFormFeatureImage:b,children:I,isHiddenInteraction:N,...k}=j,{isDisplay:E,shapeByLayout:G,imageActiveIndex:M,enableOpenLightBox:P,isEnableBorderActive:$,filteredProductImages:z}=h(j),B=s(),{galleryGridWrapperClasses:H,galleryItemClasses:O}=m(k),{galleryGridStyles:Z,galleryGridItemStyles:A}=l(k);return e(o,{children:E&&t("div",{"data-slot":"children","data-id":w,className:H,style:Z,"gp-data-hidden":`${N}`,children:[z?.map((o,m)=>{let l=m===M,s=r(o.contentType)?o.previewImage:o.src;return t("div",{"aria-hidden":!0,className:O(`gem-slider-item-${w} ${l&&$?"gem-slider-item-active":""}`),onClick:()=>x(o?.id||"",P),style:A,onMouseMove:e=>g(e,{hoverEffect:k.galleryHoverEffect,zoom:k.galleryZoom,zoomType:k.galleryZoomType}),onMouseOut:e=>p(e),"data-border":l&&k?.borderActive?"active":"deactive",children:[e(y,{src:s,width:o?.width,height:o?.height,alt:o?.alt,setting:{aspectRatio:u(G),layout:k?.layout},style:{width:"100%",height:"100%"}},o?.id),e(v,{contentType:o?.contentType||""}),k?.galleryHoverEffect!=="none"&&!r(o?.contentType)&&e(y,{src:s,width:o?.width,height:o?.height,alt:o?.alt,setting:{layout:k.layout,aspectRatio:u(G)},className:c("hover-image !gp-max-w-none",i())}),k?.galleryHoverEffect=="zoom"&&k?.galleryZoomType=="glasses"&&["one-col","two-col"].includes(n(k.position,B)||"")&&!r(o?.contentType)&&e("div",{className:c(a(),"room-len"),style:{...d({bgi:`url("${o?.src}")`})}}),n(k?.clickOpenLightBox,B)&&e(f,{})]},o?.id)}),I]})})});export{w as default};
1
+ import{jsx as e,Fragment as t,jsxs as o}from"react/jsx-runtime";import{isFeatureMedia as r,getZoomImageClass as a,getZoomLenClass as i}from"../../common/productFeaturedImage.js";import{getProductImagesClassName as l}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as m}from"../../composables/getProductImagesStyles.js";import{useCurrentDevice as s,cls as c,getResponsiveValueByScreen as n,makeStyle as d}from"@gem-sdk/core";import{handleMouseOut as p,handleMouseMove as y}from"../../common/hoverAction.js";import{useProductGalleryGrid as g}from"../../hooks/useProductGalleryGrid.js";import u from"../../../../../image/components/NextImage.js";import h from"../lightbox/ButtonOpenLightBox.js";import{getAspectRatio as f}from"../../common/common.js";import v from"./MediaIcon.js";import{memo as T}from"react";var j=T(T=>{let{builderPropUID:j,productImages:w,onHandleClick:P,activeIndexFormFeatureImage:q,children:I,isHiddenInteraction:x,...b}=T,{isDisplay:N,shapeByLayout:z,imageActiveIndex:k,enableOpenLightBox:A,isEnableBorderActive:E,filteredProductImages:G}=g(T),M=s(),{galleryGridWrapperClasses:$,galleryItemClasses:B}=l(b),{galleryGridStyles:F,galleryGridItemStyles:H}=m(b);return e(t,{children:N&&o("div",{"data-slot":"children","data-id":j,className:$,style:F,"gp-data-hidden":`${x}`,children:[G?.map((t,l)=>{let m=l===k,s=r(t.contentType)?t.previewImage:t.src;return o("div",{"aria-hidden":!0,className:B(`gem-slider-item-${j} ${m&&E?"gem-slider-item-active":""}`),onClick:()=>P(t?.id||"",A),style:H,onMouseMove:e=>y(e,{hoverEffect:b.galleryHoverEffect,zoom:b.galleryZoom,zoomType:b.galleryZoomType}),onMouseOut:e=>p(e),"data-border":m&&b?.borderActive?"active":"deactive",children:[e(u,{sizeTarget:"ProductFeatureImage",listAware:!0,src:s,width:t?.width,height:t?.height,alt:t?.alt,setting:{qualityType:b?.qualityType,qualityPercent:b?.qualityPercent,aspectRatio:f(z),layout:b?.layout},style:{width:"100%",height:"100%"}},t?.id),e(v,{contentType:t?.contentType||""}),b?.galleryHoverEffect!=="none"&&!r(t?.contentType)&&e(u,{sizeTarget:"ProductFeatureImage",listAware:!0,src:s,width:t?.width,height:t?.height,alt:t?.alt,setting:{qualityType:b?.qualityType,qualityPercent:b?.qualityPercent,layout:b.layout,aspectRatio:f(z)},className:c("hover-image !gp-max-w-none",a())}),b?.galleryHoverEffect=="zoom"&&b?.galleryZoomType=="glasses"&&["one-col","two-col"].includes(n(b.position,M)||"")&&!r(t?.contentType)&&e("div",{className:c(i(),"room-len"),style:{...d({bgi:`url("${t?.src}")`})}}),n(b?.clickOpenLightBox,M)&&e(h,{})]},t?.id)}),I]})})});export{j as default};
@@ -1 +1 @@
1
- import{jsx as e,Fragment as t,jsxs as o}from"react/jsx-runtime";import{getProductImagesClassName as r}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as s}from"../../composables/getProductImagesStyles.js";import{getProductImagesAttr as i}from"../../composables/getProductImagesAttr.js";import{getEditorMinHeightClass as m}from"../../common/productGallery.js";import{useGalleryCarousel as a}from"../../hooks/useGalleryCarousel.js";import{isFeatureMedia as l}from"../../common/productFeaturedImage.js";import c from"../../../../../image/components/NextImage.js";import d from"../../../../../carousel/components/item/CarouselItem.js";import n from"../../../../../carousel/components/root/Carousel.js";import p from"../lightbox/ButtonOpenLightBox.js";import{getAspectRatio as u}from"../../common/common.js";import{useCurrentDevice as g}from"@gem-sdk/core";import y from"../child/MediaIcon.js";import{If as f}from"@gem-sdk/system";let h=h=>{let{builderPropUID:j,productImages:I,activeIndexFormFeatureImage:b,onClickFeatureArrow:C,builderPropsClass:P,arrow:v,priorityFeatureImage:T,...x}=h,w=g(),{galleryItemClasses:k}=r(x),{galleryCarouselSettingAttrs:q}=i(x),{galleryCarouselStyle:A,galleryCarouselItemStyle:N}=s(x),{moveToIdx:G,isDisplay:$,shapeByLayout:B,isEnableBorderActive:L,isShowButtonLightbox:M,filteredProductImages:D,handleClickCarouselItem:F,safeMoveToIdx:H,setSliderReady:O}=a(h);return e(t,{children:$&&e(n,{parentClass:P,rootClass:P,setting:q,styles:A,slidesClass:m(w,x.position,x.navigationPosition),builderProps:{uid:`${j}-carousel`},moveToIdx:H,isHiddenArrowWhenDisabled:!0,disableMarginAuto:!0,onLoaded:e=>{e&&O(!0)},children:D?.map((t,r)=>{let s=r===G,i=l(t.contentType)?t.previewImage:t.src;return o(d,{contentType:"productImage",className:k(`gp-gallery-image-item gem-slider-item-${j} ${s&&L?"gem-slider-item-active":""}`),onClickItem:()=>F(t?.id),style:N,"data-id":t?.id,"data-border":s&&x?.borderActive?"active":"deactive",children:[e(c,{draggable:"false",src:i,width:t?.width,height:t?.height,alt:t?.alt,setting:{aspectRatio:u(B),layout:x?.layout,qualityPercent:x?.qualityPercent,qualityType:x?.qualityType},style:{width:"100%",height:"100%",cursor:"pointer"},className:"product-list-image"}),e(y,{contentType:t?.contentType||""}),f(M,e(p,{}))]},t?.id)})})})};export{h as default};
1
+ import{jsx as e,Fragment as t,jsxs as o}from"react/jsx-runtime";import{getProductImagesClassName as r}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as s}from"../../composables/getProductImagesStyles.js";import{getProductImagesAttr as i}from"../../composables/getProductImagesAttr.js";import{getEditorMinHeightClass as m}from"../../common/productGallery.js";import{useGalleryCarousel as a}from"../../hooks/useGalleryCarousel.js";import{isFeatureMedia as l}from"../../common/productFeaturedImage.js";import c from"../../../../../image/components/NextImage.js";import n from"../../../../../carousel/components/item/CarouselItem.js";import d from"../../../../../carousel/components/root/Carousel.js";import p from"../lightbox/ButtonOpenLightBox.js";import{getAspectRatio as u}from"../../common/common.js";import{useCurrentDevice as g}from"@gem-sdk/core";import y from"../child/MediaIcon.js";import{If as h}from"@gem-sdk/system";let f=f=>{let{builderPropUID:j,productImages:I,activeIndexFormFeatureImage:b,onClickFeatureArrow:C,builderPropsClass:P,arrow:T,priorityFeatureImage:v,...w}=f,x=g(),{galleryItemClasses:A}=r(w),{galleryCarouselSettingAttrs:k}=i(w),{galleryCarouselStyle:q,galleryCarouselItemStyle:G}=s(w),{moveToIdx:N,isDisplay:L,shapeByLayout:$,isEnableBorderActive:B,isShowButtonLightbox:M,filteredProductImages:z,handleClickCarouselItem:D,safeMoveToIdx:F,setSliderReady:H}=a(f);return e(t,{children:L&&e(d,{parentClass:P,rootClass:P,setting:k,styles:q,slidesClass:m(x,w.position,w.navigationPosition),builderProps:{uid:`${j}-carousel`},moveToIdx:F,isHiddenArrowWhenDisabled:!0,disableMarginAuto:!0,onLoaded:e=>{e&&H(!0)},children:z?.map((t,r)=>{let s=r===N,i=l(t.contentType)?t.previewImage:t.src;return o(n,{contentType:"productImage",className:A(`gp-gallery-image-item gem-slider-item-${j} ${s&&B?"gem-slider-item-active":""}`),onClickItem:()=>D(t?.id),style:G,"data-id":t?.id,"data-border":s&&w?.borderActive?"active":"deactive",children:[e(c,{sizeTarget:"GalleryList",listAware:!0,src:i,width:t?.width,height:t?.height,alt:t?.alt,setting:{aspectRatio:u($),layout:w?.layout,qualityPercent:w?.qualityPercent,qualityType:w?.qualityType},style:{width:"100%",height:"100%",cursor:"pointer"},className:"product-list-image"}),e(y,{contentType:t?.contentType||""}),h(M,e(p,{}))]},t?.id)})})})};export{f as default};
@@ -1,2 +1,2 @@
1
1
  'use client';
2
- import{jsx as e,jsxs as t,Fragment as o}from"react/jsx-runtime";import{useFeaturedImageGlobal as i,useEditorMode as l,cls as s}from"@gem-sdk/core";import{isFeatureMedia as n}from"../../common/productFeaturedImage.js";import r from"../../../../../image/components/NextImage.js";import d from"../../../../../carousel/components/item/CarouselItem.js";import m from"../../../../../carousel/components/root/Carousel.js";import p from"../child/ProductFeatureVideo.js";import"../../../../../modal/components/confirm.js";import a from"../../../../../modal/components/Modal.js";import c from"../child/MediaIcon.js";import{useMemo as g}from"react";let h=({builderPropUID:h,productImages:u,open:b,imageRatio:f,onHandleClose:k})=>{let y=i(),E=g(()=>{let e=u?.findIndex(e=>e.id===y?.id);return e&&e>0?e:0},[u,y]),I={desktop:u&&u.length>1,mobile:u&&u?.length>1,tablet:u&&u?.length>1},j=l(),C=e=>"edit"!==j&&["VIDEO","EXTERNAL_VIDEO"].includes(e?.contentType||"");return e(a,{setting:{open:b},styles:{width:"80%"},closeOnClickOutside:!0,onClose:()=>{k(),console.log("onHandleClose")},disableIframeClickEvent:!0,contentClass:"mobile:!gp-w-[100%] gp-px-2 gp-pb-10",children:e(m,{setting:{loop:{desktop:!1,mobile:!1,tablet:!1},slidesToShow:{desktop:1,tablet:1,mobile:1},defaultCurrentSlider:E,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"},dotSize:{desktop:12},dotGapToCarousel:{desktop:12},navigationEnable:I,navigationStyle:{desktop:"outside"},arrowIconSize:{desktop:24}},styles:{sizeSetting:{desktop:{height:"80vh"},tablet:{height:"80vh"},mobile:{height:"60vh"}}},moveToIdx:E,hiddenDotWhenOnlyOne:!0,isHiddenArrowWhenDisabled:!0,builderProps:{uid:h},fullHeight:!0,children:u?.map(i=>e(d,{className:`gem-slider-item gem-slider-item-${h} gp-flex gp-items-center gp-justify-center gp-px-4`,children:C(i)?e(p,{type:i?.contentType,url:i.src??"",aspectRatio:f}):t(o,{children:[e(r,{src:n(i?.contentType)?i?.previewImage:i?.src,width:i?.width,height:i?.height,alt:i?.alt,"content-type":i?.contentType,setting:{aspectRatio:f},className:s("gp-h-full gp-w-full gp-object-contain")},i?.id),e(c,{contentType:i?.contentType??""})]})},i?.id))})})};export{h as default};
2
+ import{jsx as e,jsxs as t,Fragment as o}from"react/jsx-runtime";import{useFeaturedImageGlobal as i,useEditorMode as l,cls as s}from"@gem-sdk/core";import{isFeatureMedia as n}from"../../common/productFeaturedImage.js";import d from"../../../../../image/components/NextImage.js";import r from"../../../../../carousel/components/item/CarouselItem.js";import p from"../../../../../carousel/components/root/Carousel.js";import m from"../child/ProductFeatureVideo.js";import"../../../../../modal/components/confirm.js";import a from"../../../../../modal/components/Modal.js";import c from"../child/MediaIcon.js";import{useMemo as g}from"react";let h={desktop:"finest"},u=({builderPropUID:u,productImages:b,open:f,imageRatio:k,onHandleClose:y})=>{let E=i(),I=g(()=>{let e=b?.findIndex(e=>e.id===E?.id);return e&&e>0?e:0},[b,E]),j={desktop:b&&b.length>1,mobile:b&&b?.length>1,tablet:b&&b?.length>1},C=l(),T=e=>"edit"!==C&&["VIDEO","EXTERNAL_VIDEO"].includes(e?.contentType||"");return e(a,{setting:{open:f},styles:{width:"80%"},closeOnClickOutside:!0,onClose:()=>{y(),console.log("onHandleClose")},disableIframeClickEvent:!0,contentClass:"mobile:!gp-w-[100%] gp-px-2 gp-pb-10",children:e(p,{setting:{loop:{desktop:!1,mobile:!1,tablet:!1},slidesToShow:{desktop:1,tablet:1,mobile:1},defaultCurrentSlider:I,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"},dotSize:{desktop:12},dotGapToCarousel:{desktop:12},navigationEnable:j,navigationStyle:{desktop:"outside"},arrowIconSize:{desktop:24}},styles:{sizeSetting:{desktop:{height:"80vh"},tablet:{height:"80vh"},mobile:{height:"60vh"}}},moveToIdx:I,hiddenDotWhenOnlyOne:!0,isHiddenArrowWhenDisabled:!0,builderProps:{uid:u},fullHeight:!0,children:b?.map(i=>e(r,{className:`gem-slider-item gem-slider-item-${u} gp-flex gp-items-center gp-justify-center gp-px-4`,children:T(i)?e(m,{type:i?.contentType,url:i.src??"",aspectRatio:k}):t(o,{children:[e(d,{src:n(i?.contentType)?i?.previewImage:i?.src,width:i?.width,height:i?.height,alt:i?.alt,"content-type":i?.contentType,setting:{aspectRatio:k,qualityType:h},className:s("gp-h-full gp-w-full gp-object-contain")},i?.id),e(c,{contentType:i?.contentType??""})]})},i?.id))})})};export{u as default};
@@ -1,2 +1,2 @@
1
1
  'use client';
2
- import{jsx as e,Fragment as t,jsxs as r}from"react/jsx-runtime";import{useProduct as o,useCurrentDevice as i,useShopStore as a,useRenderMode as c,getResponsiveValueByScreen as n,cls as l,makeStyle as s}from"@gem-sdk/core";import{isFeatureMedia as h,getZoomImageClass as f,getZoomLenClass as p}from"../../common/productFeaturedImage.js";import m from"../../../../../image/components/NextImage.js";import g from"./ProductFeatureVideo.js";import{memo as d,useMemo as u,useCallback as y}from"react";import v from"./MediaIcon.js";let E={src:"https://cdn.shopify.com/s/assets/no-image-2048-5e88c1b20e087fb7bbe9a3771824e743c244f437e4f8ba93bbf7b11b53f7824c_large.gif",id:"noImageError",width:480,height:480,alt:"no image",contentType:"IMAGE"};var T=d(({image:d,imageShowWhenHover:T,setting:b,aspectRatio:w})=>{let I=o(),k=i(),x=a(e=>e.storefrontUrl),{isEditMode:L,isPreviewSharePageMode:N}=c(),O=u(()=>"none"!==n(b.ftClickOpenLightBox,k),[k,b.ftClickOpenLightBox]),j=u(()=>!L&&["VIDEO","EXTERNAL_VIDEO"].includes(d?.contentType||"")&&!O,[L,d?.contentType,O]),R=u(()=>d?{...d,src:j?d.src:h(d?.contentType)?d?.previewImage:d.src}:E,[d,j]),C=u(()=>{if(N)return"javascript:void(0)";if(!x)return"#";let e=new URL(x);return I?`${e.protocol}//${e.host}/products/${I.handle}`:"#"},[x,I,N]),$=u(()=>b?.hoverEffect!=="none"&&!h(R?.contentType),[R?.contentType,b?.hoverEffect]),_=u(()=>b?.hoverEffect=="zoom"&&b?.zoomType=="glasses"&&!h(R?.contentType),[R?.contentType,b?.hoverEffect,b?.zoomType]),z=y(e=>"IMAGE"!==e.contentType?e.previewImage:e.src,[]),A=u(()=>T?"other"!==b.hoverEffect?z(R):z(T):E.src,[T,R,b.hoverEffect,z]);return e(t,{children:(t=>{if("product-link"===n(b.ftClickOpenLightBox,k)){let r=b.ftClickOpenNewTab?"_blank":"_self";return e("a",{title:I?.title,href:C,className:"gp-w-full",target:r,children:t})}return t})(e(t,{children:j?e(g,{type:R?.contentType,url:R.src??"",thumbnail:R?.previewImage,aspectRatio:w}):r(t,{children:[e(m,{draggable:"false",src:R.src,width:R?.width,height:R?.height,alt:R?.alt,setting:{aspectRatio:w,layout:b?.ftLayout},priority:b?.preload,className:"featured-image-only",style:{width:"100%",height:"100%",cursor:"pointer"}}),e(v,{contentType:R?.contentType??""}),$&&e(m,{draggable:"false",src:A,width:b?.hoverEffect==="other"?T?.width:R.width,height:b?.hoverEffect==="other"?T?.height:R.height,alt:b?.hoverEffect==="other"?T?.alt:R.alt,setting:{layout:b.ftLayout,aspectRatio:w},style:{width:"100%",height:"100%"},className:l("hover-image featured-image-only !gp-max-w-none",f()),priority:b?.preload}),_&&e("div",{className:l(p(),"room-len"),style:{...s({bgi:`url("${R?.src}")`})}})]})}))})});export{T as default};
2
+ import{jsx as e,Fragment as t,jsxs as r}from"react/jsx-runtime";import{useProduct as o,useCurrentDevice as i,useShopStore as a,useRenderMode as c,getResponsiveValueByScreen as n,cls as l,makeStyle as s}from"@gem-sdk/core";import{isFeatureMedia as p,getZoomImageClass as h,getZoomLenClass as f}from"../../common/productFeaturedImage.js";import m from"../../../../../image/components/NextImage.js";import u from"./ProductFeatureVideo.js";import{memo as y,useMemo as g,useCallback as d}from"react";import T from"./MediaIcon.js";let v={src:"https://cdn.shopify.com/s/assets/no-image-2048-5e88c1b20e087fb7bbe9a3771824e743c244f437e4f8ba93bbf7b11b53f7824c_large.gif",id:"noImageError",width:480,height:480,alt:"no image",contentType:"IMAGE"};var w=y(({image:y,imageShowWhenHover:w,setting:E,aspectRatio:I})=>{let b=o(),q=i(),P=a(e=>e.storefrontUrl),{isEditMode:k,isPreviewSharePageMode:x}=c(),L=g(()=>"none"!==n(E.ftClickOpenLightBox,q),[q,E.ftClickOpenLightBox]),N=g(()=>!k&&["VIDEO","EXTERNAL_VIDEO"].includes(y?.contentType||"")&&!L,[k,y?.contentType,L]),O=g(()=>y?{...y,src:N?y.src:p(y?.contentType)?y?.previewImage:y.src}:v,[y,N]),j=g(()=>{if(x)return"javascript:void(0)";if(!P)return"#";let e=new URL(P);return b?`${e.protocol}//${e.host}/products/${b.handle}`:"#"},[P,b,x]),z=g(()=>E?.hoverEffect!=="none"&&!p(O?.contentType),[O?.contentType,E?.hoverEffect]),A=g(()=>E?.hoverEffect=="zoom"&&E?.zoomType=="glasses"&&!p(O?.contentType),[O?.contentType,E?.hoverEffect,E?.zoomType]),F=d(e=>"IMAGE"!==e.contentType?e.previewImage:e.src,[]),R=g(()=>w?"other"!==E.hoverEffect?F(O):F(w):v.src,[w,O,E.hoverEffect,F]);return e(t,{children:(t=>{if("product-link"===n(E.ftClickOpenLightBox,q)){let r=E.ftClickOpenNewTab?"_blank":"_self";return e("a",{title:b?.title,href:j,className:"gp-w-full",target:r,children:t})}return t})(e(t,{children:N?e(u,{type:O?.contentType,url:O.src??"",thumbnail:O?.previewImage,aspectRatio:I}):r(t,{children:[e(m,{sizeTarget:"ProductFeatureImage",listAware:!0,src:O.src,width:O?.width,height:O?.height,alt:O?.alt,setting:{qualityType:E?.qualityType,qualityPercent:E?.qualityPercent,aspectRatio:I,layout:E?.ftLayout},priority:E?.preload,className:"featured-image-only",style:{width:"100%",height:"100%",cursor:"pointer"}}),e(T,{contentType:O?.contentType??""}),z&&e(m,{sizeTarget:"ProductFeatureImage",listAware:!0,src:R,width:E?.hoverEffect==="other"?w?.width:O.width,height:E?.hoverEffect==="other"?w?.height:O.height,alt:E?.hoverEffect==="other"?w?.alt:O.alt,setting:{qualityType:E?.qualityType,qualityPercent:E?.qualityPercent,layout:E.ftLayout,aspectRatio:I},style:{width:"100%",height:"100%"},className:l("hover-image featured-image-only !gp-max-w-none",h()),priority:E?.preload}),A&&e("div",{className:l(f(),"room-len"),style:{...s({bgi:`url("${O?.src}")`})}})]})}))})});export{w as default};
@@ -1 +1 @@
1
- import{jsx as e,Fragment as o,jsxs as t}from"react/jsx-runtime";import{isFeatureMedia as r,getZoomImageClass as i,getZoomLenClass as a}from"../../common/productFeaturedImage.js";import{getProductImagesClassName as m}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as l}from"../../composables/getProductImagesStyles.js";import{useCurrentDevice as c,useRenderMode as s,getResponsiveValueByScreen as n,cls as d,makeStyle as p}from"@gem-sdk/core";import{handleMouseOut as g,handleMouseMove as h}from"../../common/hoverAction.js";import{useProductGalleryGrid as y}from"../../hooks/useProductGalleryGrid.js";import u from"../../../../../image/components/NextImage.js";import f from"../lightbox/ButtonOpenLightBox.js";import v from"./ProductFeatureVideo.js";import{getAspectRatio as j}from"../../common/common.js";import T from"./MediaIcon.js";import{memo as w}from"react";var I=w(w=>{let{builderPropUID:I,productImages:b,onHandleClick:E,activeIndexFromFeatureImage:x,children:N,isHiddenInteraction:O,...P}=w,{isDisplay:k,shapeByLayout:G,imageActiveIndex:M,enableOpenLightBox:R,isEnableBorderActive:$,filteredProductImages:z}=y(w),A=c(),{isEditMode:B}=s(),H=n(P.position,A)||"",L=["one-col","two-col"].includes(H),V="bottom-center"===H,{galleryGridWrapperClasses:Z,galleryItemClasses:C}=m(P),{galleryGridStyles:D,galleryGridItemStyles:F}=l(P),S=V?"none":P.galleryHoverEffect;return e(o,{children:k&&t("div",{"data-slot":"children","data-id":I,className:Z,style:D,"gp-data-hidden":`${O}`,children:[z?.map((m,l)=>{let c=l===M,s=r(m.contentType)?m.previewImage:m.src,y=!B&&L&&!R&&["VIDEO","EXTERNAL_VIDEO"].includes(m?.contentType||"");return t("div",{"aria-hidden":!0,className:C(`gp-gallery-image-item gem-slider-item-${I} ${c&&$?"gem-slider-item-active":""}`),onClick:()=>E(m?.id||"",R),style:F,onMouseMove:e=>h(e,{hoverEffect:S,zoom:P.galleryZoom,zoomType:P.galleryZoomType}),onMouseOut:e=>g(e),"data-border":c&&P?.borderActive?"active":"deactive",children:[y?e(v,{type:m?.contentType,url:m?.src??"",thumbnail:m?.previewImage,aspectRatio:j(G)}):t(o,{children:[e(u,{src:s,width:m?.width,height:m?.height,alt:m?.alt,setting:{aspectRatio:j(G),layout:P?.layout},style:{width:"100%",height:"100%"}},m?.id),e(T,{contentType:m?.contentType||""})]}),P?.galleryHoverEffect!=="none"&&!r(m?.contentType)&&e(u,{src:s,width:m?.width,height:m?.height,alt:m?.alt,setting:{layout:P.layout,aspectRatio:j(G)},className:d("hover-image !gp-max-w-none",i())}),P?.galleryHoverEffect=="zoom"&&P?.galleryZoomType=="glasses"&&["one-col","two-col"].includes(n(P.position,A)||"")&&!r(m?.contentType)&&e("div",{className:d(a(),"room-len"),style:{...p({bgi:`url("${m?.src}")`})}}),n(P?.clickOpenLightBox,A)&&e(f,{})]},m?.id)}),N]})})});export{I as default};
1
+ import{jsx as e,Fragment as t,jsxs as o}from"react/jsx-runtime";import{isFeatureMedia as r,getZoomImageClass as i,getZoomLenClass as a}from"../../common/productFeaturedImage.js";import{getProductImagesClassName as l}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as m}from"../../composables/getProductImagesStyles.js";import{useCurrentDevice as c,useRenderMode as s,getResponsiveValueByScreen as n,cls as d,makeStyle as p}from"@gem-sdk/core";import{handleMouseOut as y,handleMouseMove as g}from"../../common/hoverAction.js";import{useProductGalleryGrid as u}from"../../hooks/useProductGalleryGrid.js";import h from"../../../../../image/components/NextImage.js";import f from"../lightbox/ButtonOpenLightBox.js";import v from"./ProductFeatureVideo.js";import{getAspectRatio as T}from"../../common/common.js";import w from"./MediaIcon.js";import{memo as j}from"react";var I=j(j=>{let{builderPropUID:I,productImages:P,onHandleClick:b,activeIndexFromFeatureImage:q,children:E,isHiddenInteraction:x,...N}=j,{isDisplay:z,shapeByLayout:A,imageActiveIndex:O,enableOpenLightBox:k,isEnableBorderActive:F,filteredProductImages:G}=u(j),M=c(),{isEditMode:R}=s(),$=n(N.position,M)||"",B=["one-col","two-col"].includes($),H="bottom-center"===$,{galleryGridWrapperClasses:L,galleryItemClasses:V}=l(N),{galleryGridStyles:Z,galleryGridItemStyles:C}=m(N),D=H?"none":N.galleryHoverEffect;return e(t,{children:z&&o("div",{"data-slot":"children","data-id":I,className:L,style:Z,"gp-data-hidden":`${x}`,children:[G?.map((l,m)=>{let c=m===O,s=r(l.contentType)?l.previewImage:l.src,u=!R&&B&&!k&&["VIDEO","EXTERNAL_VIDEO"].includes(l?.contentType||"");return o("div",{"aria-hidden":!0,className:V(`gp-gallery-image-item gem-slider-item-${I} ${c&&F?"gem-slider-item-active":""}`),onClick:()=>b(l?.id||"",k),style:C,onMouseMove:e=>g(e,{hoverEffect:D,zoom:N.galleryZoom,zoomType:N.galleryZoomType}),onMouseOut:e=>y(e),"data-border":c&&N?.borderActive?"active":"deactive",children:[u?e(v,{type:l?.contentType,url:l?.src??"",thumbnail:l?.previewImage,aspectRatio:T(A)}):o(t,{children:[e(h,{sizeTarget:"ProductFeatureImage",listAware:!0,src:s,width:l?.width,height:l?.height,alt:l?.alt,setting:{qualityType:N?.qualityType,qualityPercent:N?.qualityPercent,aspectRatio:T(A),layout:N?.layout},style:{width:"100%",height:"100%"}},l?.id),e(w,{contentType:l?.contentType||""})]}),N?.galleryHoverEffect!=="none"&&!r(l?.contentType)&&e(h,{sizeTarget:"ProductFeatureImage",listAware:!0,src:s,width:l?.width,height:l?.height,alt:l?.alt,setting:{qualityType:N?.qualityType,qualityPercent:N?.qualityPercent,layout:N.layout,aspectRatio:T(A)},className:d("hover-image !gp-max-w-none",i())}),N?.galleryHoverEffect=="zoom"&&N?.galleryZoomType=="glasses"&&["one-col","two-col"].includes(n(N.position,M)||"")&&!r(l?.contentType)&&e("div",{className:d(a(),"room-len"),style:{...p({bgi:`url("${l?.src}")`})}}),n(N?.clickOpenLightBox,M)&&e(f,{})]},l?.id)}),E]})})});export{I as default};
@@ -1 +1 @@
1
- import{jsx as e,Fragment as o,jsxs as t}from"react/jsx-runtime";import r from"../../../../../carousel-v3/components/item/CarouselItem.js";import s from"../../../../../carousel-v3/components/root/Carousel.js";import{getProductImagesClassName as m}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as i}from"../../composables/getProductImagesStyles.js";import{getProductImagesAttr as a}from"../../composables/getProductImagesAttr.js";import{getEditorMinHeightClass as l}from"../../common/productGallery.js";import{useGalleryCarousel as n}from"../../hooks/useGalleryCarousel.js";import{isFeatureMedia as c}from"../../common/productFeaturedImage.js";import p from"../../../../../image/components/NextImage.js";import d from"../lightbox/ButtonOpenLightBox.js";import{getAspectRatio as u,getGalleryCarouselRootId as g}from"../../common/common.js";import{useCurrentDevice as y}from"@gem-sdk/core";import h from"../child/MediaIcon.js";import{If as f}from"@gem-sdk/system";let j=j=>{let{builderPropUID:I,productImages:C,onSwiperReady:b,activeIndexFormFeatureImage:P,onClickFeatureArrow:T,builderPropsClass:v,carouselInstanceUID:w,arrow:x,priorityFeatureImage:k,...q}=j,N=y(),{galleryItemClasses:A}=m(q),{galleryCarouselSettingAttrs:G}=a(q),{galleryCarouselStyle:S,galleryCarouselItemStyle:$}=i(q),{moveToIdx:B,isDisplay:H,shapeByLayout:L,isEnableBorderActive:M,isShowButtonLightbox:R,filteredProductImages:D,handleClickCarouselItem:E,safeMoveToIdx:F,setSliderReady:O}=n(j);return e(o,{children:H&&e(s,{parentClass:v,rootClass:v,setting:G,styles:S,slidesClass:l(N,q.position,q.navigationPosition),builderProps:{uid:`${I}-carousel`},rootId:g({carouselInstanceUID:w,builderPropUID:I}),moveToIdx:F,isHiddenArrowWhenDisabled:!0,disableMarginAuto:!0,isEnableCheckHasScrollableContent:!0,onLoaded:e=>{e&&O(!0)},onSwiperReady:b,children:D?.map((o,s)=>{let m=c(o.contentType)?o.previewImage:o.src;return t(r,{contentType:"productImage",className:A(`gp-gallery-image-item gem-slider-item-${I} ${s===B&&M?"gem-slider-item-active":""}`),onClickItem:()=>E(o?.id),style:$,"data-id":o?.id,children:[e(p,{draggable:"false",src:m,width:o?.width,height:o?.height,alt:o?.alt,setting:{aspectRatio:u(L),layout:q?.layout,qualityPercent:q?.qualityPercent,qualityType:q?.qualityType},style:{width:"100%",height:"100%",cursor:"pointer"},className:"product-list-image"}),e(h,{contentType:o?.contentType||""}),f(R,e(d,{}))]},o?.id)})})})};export{j as default};
1
+ import{jsx as e,Fragment as o,jsxs as t}from"react/jsx-runtime";import r from"../../../../../carousel-v3/components/item/CarouselItem.js";import s from"../../../../../carousel-v3/components/root/Carousel.js";import{getProductImagesClassName as i}from"../../composables/getProductImagesClassName.js";import{getProductImagesStyles as m}from"../../composables/getProductImagesStyles.js";import{getProductImagesAttr as a}from"../../composables/getProductImagesAttr.js";import{getEditorMinHeightClass as l}from"../../common/productGallery.js";import{useGalleryCarousel as n}from"../../hooks/useGalleryCarousel.js";import{isFeatureMedia as c}from"../../common/productFeaturedImage.js";import p from"../../../../../image/components/NextImage.js";import d from"../lightbox/ButtonOpenLightBox.js";import{getAspectRatio as u,getGalleryCarouselRootId as g}from"../../common/common.js";import{useCurrentDevice as y}from"@gem-sdk/core";import h from"../child/MediaIcon.js";import{If as f}from"@gem-sdk/system";let j=j=>{let{builderPropUID:I,productImages:C,onSwiperReady:b,activeIndexFormFeatureImage:P,onClickFeatureArrow:T,builderPropsClass:w,carouselInstanceUID:v,arrow:x,priorityFeatureImage:k,...q}=j,A=y(),{galleryItemClasses:G}=i(q),{galleryCarouselSettingAttrs:N}=a(q),{galleryCarouselStyle:L,galleryCarouselItemStyle:S}=m(q),{moveToIdx:$,isDisplay:B,shapeByLayout:H,isEnableBorderActive:M,isShowButtonLightbox:R,filteredProductImages:z,handleClickCarouselItem:D,safeMoveToIdx:E,setSliderReady:F}=n(j);return e(o,{children:B&&e(s,{parentClass:w,rootClass:w,setting:N,styles:L,slidesClass:l(A,q.position,q.navigationPosition),builderProps:{uid:`${I}-carousel`},rootId:g({carouselInstanceUID:v,builderPropUID:I}),moveToIdx:E,isHiddenArrowWhenDisabled:!0,disableMarginAuto:!0,isEnableCheckHasScrollableContent:!0,onLoaded:e=>{e&&F(!0)},onSwiperReady:b,children:z?.map((o,s)=>{let i=c(o.contentType)?o.previewImage:o.src;return t(r,{contentType:"productImage",className:G(`gp-gallery-image-item gem-slider-item-${I} ${s===$&&M?"gem-slider-item-active":""}`),onClickItem:()=>D(o?.id),style:S,"data-id":o?.id,children:[e(p,{sizeTarget:"GalleryList",listAware:!0,src:i,width:o?.width,height:o?.height,alt:o?.alt,setting:{aspectRatio:u(H),layout:q?.layout,qualityPercent:q?.qualityPercent,qualityType:q?.qualityType},style:{width:"100%",height:"100%",cursor:"pointer"},className:"product-list-image"}),e(h,{contentType:o?.contentType||""}),f(R,e(d,{}))]},o?.id)})})})};export{j as default};
@@ -1,2 +1,2 @@
1
1
  'use client';
2
- import{jsx as e,jsxs as t,Fragment as o}from"react/jsx-runtime";import i from"../../../../../carousel-v3/components/item/CarouselItem.js";import l from"../../../../../carousel-v3/components/root/Carousel.js";import{useFeaturedImageGlobal as s,useEditorMode as d,cls as n}from"@gem-sdk/core";import{isFeatureMedia as r}from"../../common/productFeaturedImage.js";import p from"../../../../../image/components/NextImage.js";import m from"../child/ProductFeatureVideo.js";import"../../../../../modal/components/confirm.js";import a from"../../../../../modal/components/Modal.js";import c from"../child/MediaIcon.js";import{useMemo as g}from"react";let h=({builderPropUID:h,productImages:u,open:b,imageRatio:f,onHandleClose:k})=>{let y=s(),E=g(()=>{let e=u?.findIndex(e=>e.id===y?.id);return e&&e>0?e:0},[u,y]),I={desktop:u&&u.length>1,mobile:u&&u?.length>1,tablet:u&&u?.length>1},j=d(),v=e=>"edit"!==j&&["VIDEO","EXTERNAL_VIDEO"].includes(e?.contentType||"");return e(a,{setting:{open:b},styles:{width:"80%"},closeOnClickOutside:!0,onClose:()=>{k(),console.log("onHandleClose")},disableIframeClickEvent:!0,contentClass:"mobile:!gp-w-[100%] gp-px-2 gp-pb-10",children:e(l,{setting:{loop:{desktop:!1,mobile:!1,tablet:!1},slidesToShow:{desktop:1,tablet:1,mobile:1},defaultCurrentSlider:E,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"},dotSize:{desktop:12},dotGapToCarousel:{desktop:12},navigationEnable:I,navigationStyle:{desktop:"outside"},arrowIconSize:{desktop:24},initialSlide:E},styles:{sizeSetting:{desktop:{height:"80vh"},tablet:{height:"80vh"},mobile:{height:"60vh"}},playSpeed:0},moveToIdx:E,hiddenDotWhenOnlyOne:!0,isHiddenArrowWhenDisabled:!0,isDisableResetSlide:!0,builderProps:{uid:h},fullHeight:!0,children:u?.map(l=>e(i,{className:`gem-slider-item gem-slider-item-${h} gp-flex gp-items-center gp-justify-center gp-px-4`,children:v(l)?e(m,{type:l?.contentType,url:l.src??"",thumbnail:l?.previewImage,aspectRatio:f}):t(o,{children:[e(p,{src:r(l?.contentType)?l?.previewImage:l?.src,width:l?.width,height:l?.height,alt:l?.alt,"content-type":l?.contentType,setting:{aspectRatio:f},className:n("gp-h-full gp-w-full gp-object-contain")},l?.id),e(c,{contentType:l?.contentType??""})]})},l?.id))})})};export{h as default};
2
+ import{jsx as e,jsxs as t,Fragment as o}from"react/jsx-runtime";import i from"../../../../../carousel-v3/components/item/CarouselItem.js";import l from"../../../../../carousel-v3/components/root/Carousel.js";import{useFeaturedImageGlobal as s,useEditorMode as d,cls as n}from"@gem-sdk/core";import{isFeatureMedia as r}from"../../common/productFeaturedImage.js";import p from"../../../../../image/components/NextImage.js";import m from"../child/ProductFeatureVideo.js";import"../../../../../modal/components/confirm.js";import a from"../../../../../modal/components/Modal.js";import c from"../child/MediaIcon.js";import{useMemo as g}from"react";let h={desktop:"finest"},u=({builderPropUID:u,productImages:b,open:f,imageRatio:y,onHandleClose:k})=>{let E=s(),I=g(()=>{let e=b?.findIndex(e=>e.id===E?.id);return e&&e>0?e:0},[b,E]),j={desktop:b&&b.length>1,mobile:b&&b?.length>1,tablet:b&&b?.length>1},v=d(),C=e=>"edit"!==v&&["VIDEO","EXTERNAL_VIDEO"].includes(e?.contentType||"");return e(a,{setting:{open:f},styles:{width:"80%"},closeOnClickOutside:!0,onClose:()=>{k(),console.log("onHandleClose")},disableIframeClickEvent:!0,contentClass:"mobile:!gp-w-[100%] gp-px-2 gp-pb-10",children:e(l,{setting:{loop:{desktop:!1,mobile:!1,tablet:!1},slidesToShow:{desktop:1,tablet:1,mobile:1},defaultCurrentSlider:I,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"},dotSize:{desktop:12},dotGapToCarousel:{desktop:12},navigationEnable:j,navigationStyle:{desktop:"outside"},arrowIconSize:{desktop:24},initialSlide:I},styles:{sizeSetting:{desktop:{height:"80vh"},tablet:{height:"80vh"},mobile:{height:"60vh"}},playSpeed:0},moveToIdx:I,hiddenDotWhenOnlyOne:!0,isHiddenArrowWhenDisabled:!0,isDisableResetSlide:!0,builderProps:{uid:u},fullHeight:!0,children:b?.map(l=>e(i,{className:`gem-slider-item gem-slider-item-${u} gp-flex gp-items-center gp-justify-center gp-px-4`,children:C(l)?e(m,{type:l?.contentType,url:l.src??"",thumbnail:l?.previewImage,aspectRatio:y}):t(o,{children:[e(p,{src:r(l?.contentType)?l?.previewImage:l?.src,width:l?.width,height:l?.height,alt:l?.alt,"content-type":l?.contentType,setting:{aspectRatio:y,qualityType:h},className:n("gp-h-full gp-w-full gp-object-contain")},l?.id),e(c,{contentType:l?.contentType??""})]})},l?.id))})})};export{u as default};
@@ -1 +1 @@
1
- import{jsx as o}from"react/jsx-runtime";import{useEditorMode as r,ProductProvider as e,isEmptyChildren as s}from"@gem-sdk/core";import t from"../../../grid/components/ChildrenDroppable.js";import m from"../../../carousel/components/item/CarouselItem.js";import i from"../../../carousel/components/root/Carousel.js";import{getClass as l}from"./common/classes.js";import{getData as a}from"./common/helpers.js";import{getStyle as c}from"./common/styles.js";import{getAttr as n}from"./common/attrs.js";let p=p=>{let{children:d,builderProps:u,productSortedById:f,advanced:j}=p,h=r(),{carouselConfigSetting:y,carouselConfigStyle:C}=a(p),{productListAttr:b,getAttrProductItemEditor:g}=n(p),{carouselItemStyle:D}=c(p),{carouselClass:I,productItemClass:v}=l(p);return o(i,{advanced:j,builderProps:{uid:u?.uid},rootAttrs:{...b},rootClass:I,setting:y,styles:C,children:f?.map(r=>o(m,{style:D,children:o(e,{product:r,readOnly:!0,children:o("div",{..."edit"===h?g(r?.baseID):{},className:v,children:s(d)?o(t,{}):d})})},r?.baseID))})};export{p as default};
1
+ import{jsx as o}from"react/jsx-runtime";import{useEditorMode as r,ProductProvider as m,isEmptyChildren as e}from"@gem-sdk/core";import s from"../../../grid/components/ChildrenDroppable.js";import{ListImageContext as t}from"../../../image/common/listImageContext.js";import{getListImageHints as i}from"./common/imagePriorityHints.js";import{LIST_PRELOAD_ROWS as l}from"./common/imagePriority.js";import n from"../../../carousel/components/item/CarouselItem.js";import a from"../../../carousel/components/root/Carousel.js";import{getClass as c}from"./common/classes.js";import{getData as d}from"./common/helpers.js";import{getStyle as p}from"./common/styles.js";import{getAttr as u}from"./common/attrs.js";let f=f=>{let{children:j,builderProps:h,productSortedById:g,advanced:y,setting:C}=f,P=r(),{carouselConfigSetting:b,carouselConfigStyle:v}=d(f),{productListAttr:x,getAttrProductItemEditor:I}=u(f),{carouselItemStyle:w}=p(f),{carouselClass:D,productItemClass:L}=c(f);return o(a,{advanced:y,builderProps:{uid:h?.uid},rootAttrs:{...x},rootClass:D,setting:b,styles:v,children:g?.map((r,a)=>o(n,{style:w,children:o(m,{product:r,readOnly:!0,children:o(t.Provider,{value:i({slidesToShow:C?.slidesToShow,rows:l.CAROUSEL,index:a+1}),children:o("div",{..."edit"===P?I(r?.baseID):{},className:L,children:e(j)?o(s,{}):j})})})},r?.baseID))})};export{f as default};
@@ -1 +1 @@
1
- import{jsx as r}from"react/jsx-runtime";import{Children as o,isValidElement as e,createElement as m}from"react";import{useEditorMode as t,ProductProvider as s,isEmptyChildren as i}from"@gem-sdk/core";import l from"../../../grid/components/ChildrenDroppable.js";import{getClass as a}from"./common/classes.js";import{getStyle as d}from"./common/styles.js";import{getAttr as c}from"./common/attrs.js";let p=p=>{let{children:n,productSortedById:f,generateGridRowArray:h,setting:u}=p,y=t(),{gridLayoutStyle:g}=d(p),{gridLayoutClass:j,productItemClass:b}=a(p),{productListAttr:k,getAttrProductItemEditor:v}=c(p);return r("div",{...k,style:g,className:j,children:f?.length?f?.map((t,a)=>r(s,{product:t,readOnly:!0,children:r("div",{..."edit"===y?v(t?.baseID):{},className:b,style:{"--grchild":u?.sameHeight?h?.[a]?.gridRow:void 0,"--mbchild":h?.[a]?.marginBottom},children:i(n)?r(l,{}):o.map(n,r=>e(r)?m(r.type,{...r.props,key:r.key}):null)})},t?.baseID)):null})};export{p as default};
1
+ import{jsx as o}from"react/jsx-runtime";import{Children as r,isValidElement as m,createElement as e}from"react";import{useEditorMode as i,ProductProvider as t,isEmptyChildren as s}from"@gem-sdk/core";import l from"../../../grid/components/ChildrenDroppable.js";import{ListImageContext as a}from"../../../image/common/listImageContext.js";import{getListImageHints as d}from"./common/imagePriorityHints.js";import{LIST_PRELOAD_ROWS as n}from"./common/imagePriority.js";import{getClass as c}from"./common/classes.js";import{getStyle as p}from"./common/styles.js";import{getAttr as f}from"./common/attrs.js";let g=g=>{let{children:h,productSortedById:y,generateGridRowArray:u,setting:j}=g,v=i(),{gridLayoutStyle:b}=p(g),{gridLayoutClass:w,productItemClass:x}=c(g),{productListAttr:D,getAttrProductItemEditor:I}=f(g);return o("div",{...D,style:b,className:w,children:y?.length?y?.map((i,c)=>o(t,{product:i,readOnly:!0,children:o(a.Provider,{value:d({slidesToShow:j?.slidesToShow,rows:n.GRID,index:c+1}),children:o("div",{..."edit"===v?I(i?.baseID):{},className:x,style:{"--grchild":j?.sameHeight?u?.[c]?.gridRow:void 0,"--mbchild":u?.[c]?.marginBottom},children:s(h)?o(l,{}):r.map(h,o=>m(o)?e(o.type,{...o.props,key:o.key}):null)})})},i?.baseID)):null})};export{g as default};
@@ -1,17 +1,17 @@
1
- import{LIST_IMAGE_LIQUID_VARS as i,DEVICES as e,getResponsiveValueByScreen as t}from"@gem-sdk/core";let s={desktop:4,tablet:2,mobile:2},a={GRID:2,CAROUSEL:1},r=i=>e.map(e=>{let a=Number(t(i,e));return Math.max(1,Math.floor(a||s[e]))}),n=({slidesToShow:i,rows:e})=>{let t=r(i);return{eagerLimit:Math.max(...t)*e,highLimit:Math.min(...t),sizes:`${Number((100/Math.min(...t)).toFixed(2))}vw`}},g=({slidesToShow:e,rows:t,indexVar:s="count"})=>{let{eagerLimit:a,highLimit:r,sizes:g}=n({slidesToShow:e,rows:t});return{item:`{%- liquid
2
- if ${s} <= ${a}
3
- assign ${i.LOADING} = 'eager'
1
+ import{DEVICES as i,getResponsiveValueByScreen as e,LIST_IMAGE_LIQUID_VARS as t}from"@gem-sdk/core";import{getImageSizes as s}from"../../../../image/common/sizes.js";let a={desktop:4,tablet:2,mobile:2},r={GRID:2,CAROUSEL:1},m=t=>i.map(i=>{let s=Number(e(t,i));return Math.max(1,Math.floor(s||a[i]))}),n=i=>100/Math.min(...m(i)),g=({slidesToShow:i,rows:e})=>{let t=m(i);return{eagerLimit:Math.max(...t)*e,highLimit:Math.min(...t),sizes:`${Number(n(i).toFixed(2))}vw`}},o=({slidesToShow:i,rows:e,indexVar:a="count"})=>{let{eagerLimit:r,highLimit:m}=g({slidesToShow:i,rows:e}),o=s({slotVw:n(i)});return{item:`{%- liquid
2
+ if ${a} <= ${r}
3
+ assign ${t.LOADING} = 'eager'
4
4
  else
5
- assign ${i.LOADING} = 'lazy'
5
+ assign ${t.LOADING} = 'lazy'
6
6
  endif
7
- if ${s} <= ${r}
8
- assign ${i.FETCH_PRIORITY} = 'high'
7
+ if ${a} <= ${m}
8
+ assign ${t.FETCH_PRIORITY} = 'high'
9
9
  else
10
- assign ${i.FETCH_PRIORITY} = 'auto'
10
+ assign ${t.FETCH_PRIORITY} = 'auto'
11
11
  endif
12
- assign ${i.SIZES} = '${g}'
12
+ assign ${t.SIZES} = '${o}'
13
13
  -%}`,reset:`{%- liquid
14
- assign ${i.LOADING} = nil
15
- assign ${i.FETCH_PRIORITY} = nil
16
- assign ${i.SIZES} = nil
17
- -%}`}};export{a as LIST_PRELOAD_ROWS,n as getListImagePriority,g as getListImagePriorityLiquid};
14
+ assign ${t.LOADING} = nil
15
+ assign ${t.FETCH_PRIORITY} = nil
16
+ assign ${t.SIZES} = nil
17
+ -%}`}};export{r as LIST_PRELOAD_ROWS,g as getListImagePriority,o as getListImagePriorityLiquid};
@@ -0,0 +1 @@
1
+ import{getListImagePriority as t}from"./imagePriority.js";let e=({slidesToShow:e,rows:i,index:r})=>{let{eagerLimit:o,highLimit:a,sizes:g}=t({slidesToShow:e,rows:i});return{loading:r<=o?"eager":"lazy",fetchpriority:r<=a?"high":"auto",sizes:g}};export{e as getListImageHints};
@@ -1 +1 @@
1
- import{jsx as o}from"react/jsx-runtime";import r from"../../../carousel-v3/components/item/CarouselItem.js";import s from"../../../carousel-v3/components/root/Carousel.js";import{useEditorMode as t,ProductProvider as e,isEmptyChildren as m}from"@gem-sdk/core";import i from"../../../grid/components/ChildrenDroppable.js";import{getClass as l}from"./common/classes.js";import{getData as a}from"./common/helpers.js";import{getStyle as c}from"./common/styles.js";import{getAttr as n}from"./common/attrs.js";let d=d=>{let{children:p,builderProps:u,productSortedById:f,advanced:j}=d,h=t(),{carouselConfigSetting:y,carouselConfigStyle:C}=a(d),{productListAttr:b,getAttrProductItemEditor:v}=n(d),{carouselItemStyle:g}=c(d),{carouselClass:D,productItemClass:I}=l(d);return o(s,{advanced:j,builderProps:{uid:u?.uid},rootAttrs:{...b},rootClass:D,setting:y,styles:C,isProductList:!0,children:f?.map(s=>o(r,{style:g,children:o(e,{product:s,readOnly:!0,children:o("div",{..."edit"===h?v(s?.baseID):{},className:I,children:m(p)?o(i,{}):p})})},s?.baseID))})};export{d as default};
1
+ import{jsx as o}from"react/jsx-runtime";import r from"../../../carousel-v3/components/item/CarouselItem.js";import t from"../../../carousel-v3/components/root/Carousel.js";import{useEditorMode as s,ProductProvider as m,isEmptyChildren as e}from"@gem-sdk/core";import{getListImageHints as i}from"../product-list/common/imagePriorityHints.js";import l from"../../../grid/components/ChildrenDroppable.js";import{ListImageContext as c}from"../../../image/common/listImageContext.js";import{LIST_PRELOAD_ROWS as n}from"../product-list/common/imagePriority.js";import{getClass as a}from"./common/classes.js";import{getData as d}from"./common/helpers.js";import{getStyle as p}from"./common/styles.js";import{getAttr as u}from"./common/attrs.js";let f=f=>{let{children:j,builderProps:h,productSortedById:g,advanced:y,setting:C}=f,v=s(),{carouselConfigSetting:P,carouselConfigStyle:b}=d(f),{productListAttr:x,getAttrProductItemEditor:I}=u(f),{carouselItemStyle:L}=p(f),{carouselClass:w,productItemClass:D}=a(f);return o(t,{advanced:y,builderProps:{uid:h?.uid},rootAttrs:{...x},rootClass:w,setting:P,styles:b,isProductList:!0,children:g?.map((t,s)=>o(r,{style:L,children:o(m,{product:t,readOnly:!0,children:o(c.Provider,{value:i({slidesToShow:C?.slidesToShow,rows:n.CAROUSEL,index:s+1}),children:o("div",{..."edit"===v?I(t?.baseID):{},className:D,children:e(j)?o(l,{}):j})})})},t?.baseID))})};export{f as default};
@@ -1 +1 @@
1
- import{jsx as r}from"react/jsx-runtime";import{Children as o,isValidElement as e,createElement as m}from"react";import{useEditorMode as t,ProductProvider as s,isEmptyChildren as i}from"@gem-sdk/core";import l from"../../../grid/components/ChildrenDroppable.js";import{getClass as a}from"./common/classes.js";import{getStyle as d}from"./common/styles.js";import{getAttr as c}from"./common/attrs.js";let p=p=>{let{children:n,productSortedById:f,generateGridRowArray:h,setting:u}=p,y=t(),{gridLayoutStyle:g}=d(p),{gridLayoutClass:j,productItemClass:b}=a(p),{productListAttr:k,getAttrProductItemEditor:v}=c(p);return r("div",{...k,style:g,className:j,children:f?.length?f?.map((t,a)=>r(s,{product:t,readOnly:!0,children:r("div",{..."edit"===y?v(t?.baseID):{},className:b,style:{"--grchild":u?.sameHeight?h?.[a]?.gridRow:void 0,"--mbchild":h?.[a]?.marginBottom},children:i(n)?r(l,{}):o.map(n,r=>e(r)?m(r.type,{...r.props,key:r.key}):null)})},t?.baseID)):null})};export{p as default};
1
+ import{jsx as o}from"react/jsx-runtime";import{Children as r,isValidElement as m,createElement as t}from"react";import{useEditorMode as e,ProductProvider as i,isEmptyChildren as s}from"@gem-sdk/core";import{getListImageHints as l}from"../product-list/common/imagePriorityHints.js";import d from"../../../grid/components/ChildrenDroppable.js";import{ListImageContext as a}from"../../../image/common/listImageContext.js";import{LIST_PRELOAD_ROWS as c}from"../product-list/common/imagePriority.js";import{getClass as n}from"./common/classes.js";import{getStyle as p}from"./common/styles.js";import{getAttr as f}from"./common/attrs.js";let g=g=>{let{children:h,productSortedById:u,generateGridRowArray:y,setting:j}=g,v=e(),{gridLayoutStyle:b}=p(g),{gridLayoutClass:w,productItemClass:x}=n(g),{productListAttr:D,getAttrProductItemEditor:I}=f(g);return o("div",{...D,style:b,className:w,children:u?.length?u?.map((e,n)=>o(i,{product:e,readOnly:!0,children:o(a.Provider,{value:l({slidesToShow:j?.slidesToShow,rows:c.GRID,index:n+1}),children:o("div",{..."edit"===v?I(e?.baseID):{},className:x,style:{"--grchild":j?.sameHeight?y?.[n]?.gridRow:void 0,"--mbchild":y?.[n]?.marginBottom},children:s(h)?o(d,{}):r.map(h,o=>m(o)?t(o.type,{...o.props,key:o.key}):null)})})},e?.baseID)):null})};export{g as default};
@@ -1 +1 @@
1
- import"react/jsx-runtime";import"react";import"@gem-sdk/core";import"./components/product-bundle/common/styles.js";import"./components/product-bundle/common/classes.js";import"@gem-sdk/system";import"next/link";import"./components/constants/product-bundle.js";import"../common/const.js";import"./components/product-variants/components/variants/index.js";import"../carousel-v3/components/swiper/Swiper.js";import"next/image";import"../video/components/Video.js";import"../modal/components/confirm.js";import"react-dom";import"@gem-sdk/keen-slider/react";export{default as ProductQuickView}from"./components/product-quick-view/QuickView.js";import"../notification/components/Notifications.js";import"../notification/components/Notice.js";import"./components/product-button/types.js";export{default as ProductListV3}from"./components/product-list-v3/ProductList.js";import"./components/product-badge/types.js";import"./components/product-badge/constants.js";import"./components/product-badge/utils/shape.js";export{default as ProductList}from"./components/product-list/ProductList.js";export{default as Product}from"./components/product-wrap/Product.js";import t from"./components/product-bundle/setting/ProductBundleDiscountItem.js";import o from"./components/product-bundle/setting/ProductBundleDiscount.js";import r from"./settings/product-image-v3/ProductImages.js";import s from"./settings/product-image-v2/ProductImages.js";import i from"./settings/ProductDescription.js";import e from"./settings/ProductProperties.js";import m from"./components/file-upload/settings/index.js";import c from"./settings/ProductViewMore.js";import n from"./settings/ProductVariants.js";import p from"./settings/ProductQuantity.js";import u from"./settings/DynamicCheckout.js";import d from"./settings/ProductListV3.js";import a from"./settings/ProductImages.js";import P from"./settings/ProductButton.js";import g from"./settings/ProductTitle.js";import j from"./settings/ProductPrice.js";import f from"./settings/ProductBadge.js";import l from"./settings/ProductList.js";import V from"./settings/ProductTag.js";import k from"./settings/Vendor.js";import x from"./settings/Product.js";import b from"./settings/Sku.js";let v={Product:x,ProductQuantity:p,ProductTitle:g,ProductButton:P,ProductPrice:j,ProductVariants:n,ProductImages:a,ProductImagesV2:s,ProductImagesV3:r,ProductDescription:i,ProductProperties:e,ProductTag:V,ProductListV3:d,ProductList:l,DynamicCheckout:u,ProductVendor:k,ProductSku:b,ProductBundleDiscount:o,ProductBundleDiscountItem:t,ProductViewMore:c,ProductBadge:f,FileUpload:m};export{v as productSetting};
1
+ import"react/jsx-runtime";import"react";import"@gem-sdk/core";import"./components/product-bundle/common/styles.js";import"./components/product-bundle/common/classes.js";import"@gem-sdk/system";import"next/link";import"./components/constants/product-bundle.js";import"../common/const.js";import"./components/product-variants/components/variants/index.js";import"../carousel-v3/components/swiper/Swiper.js";import"../image/common/listImageContext.js";import"../image/common/listContext.js";import"../video/components/Video.js";import"../modal/components/confirm.js";import"react-dom";import"@gem-sdk/keen-slider/react";export{default as ProductQuickView}from"./components/product-quick-view/QuickView.js";import"../notification/components/Notifications.js";import"../notification/components/Notice.js";import"./components/product-button/types.js";export{default as ProductListV3}from"./components/product-list-v3/ProductList.js";import"./components/product-badge/types.js";import"./components/product-badge/constants.js";import"./components/product-badge/utils/shape.js";export{default as ProductList}from"./components/product-list/ProductList.js";export{default as Product}from"./components/product-wrap/Product.js";import t from"./components/product-bundle/setting/ProductBundleDiscountItem.js";import o from"./components/product-bundle/setting/ProductBundleDiscount.js";import r from"./settings/product-image-v3/ProductImages.js";import s from"./settings/product-image-v2/ProductImages.js";import i from"./settings/ProductDescription.js";import e from"./settings/ProductProperties.js";import m from"./components/file-upload/settings/index.js";import c from"./settings/ProductViewMore.js";import n from"./settings/ProductVariants.js";import p from"./settings/ProductQuantity.js";import u from"./settings/DynamicCheckout.js";import d from"./settings/ProductListV3.js";import a from"./settings/ProductImages.js";import P from"./settings/ProductButton.js";import g from"./settings/ProductTitle.js";import j from"./settings/ProductPrice.js";import f from"./settings/ProductBadge.js";import l from"./settings/ProductList.js";import V from"./settings/ProductTag.js";import k from"./settings/Vendor.js";import x from"./settings/Product.js";import b from"./settings/Sku.js";let I={Product:x,ProductQuantity:p,ProductTitle:g,ProductButton:P,ProductPrice:j,ProductVariants:n,ProductImages:a,ProductImagesV2:s,ProductImagesV3:r,ProductDescription:i,ProductProperties:e,ProductTag:V,ProductListV3:d,ProductList:l,DynamicCheckout:u,ProductVendor:k,ProductSku:b,ProductBundleDiscount:o,ProductBundleDiscountItem:t,ProductViewMore:c,ProductBadge:f,FileUpload:m};export{I as productSetting};
@@ -1,2 +1,2 @@
1
1
  'use client';
2
- import{jsxs as e,Fragment as t,jsx as o}from"react/jsx-runtime";import{getWrapThumbnailClasses as s,getButtonThumbnailClasses as r,getImageThumbnailClasses as l,getVideoYoutubeClasses as m}from"../common/classes.js";import{createAttr as i,createClass as a,createStyle as c}from"@gem-sdk/system";import n from"../hooks/useLiteHtml5Embed.js";import p from"../../image/components/NextImage.js";import{getPreloadImageStyle as d}from"../common/styles.js";import{getHtml5Attr as y}from"../common/attrs.js";import{useEditorMode as f}from"@gem-sdk/core";let u=u=>{let g=f(),h="edit"!==g,{thumbnail:b,muted:x,autoplay:j,loop:v,controls:N,src:C,style:k,title:w,className:L,lazy:T,poster:E,pageContext:H}=u,{playVideoAndTurnOffThumbnail:I,videoRef:M,showThumbnail:P}=n(j,x,C),V=!h&&j&&x&&!!b,A=!T&&u.isVideoComponent&&h,B=!b||!P,D=C||void 0,S=i({...y({title:w,autoplay:j,preloadThumbnail:V,offLazyLoad:A,src:C,thumbnail:b})}),Z=a({...s(B)}),q=c({...d()}),z=a({...r()}),F=a({...l()}),G=a({...m(L,A)});return e(t,{children:[V?o(p,{src:b,alt:w,priority:!0,style:q}):"",o("video",{ref:M,...S,style:k,className:G,controls:N,loop:v,muted:x,autoPlay:j,playsInline:!0,src:D}),!B&&e("div",{role:"presentation",style:k,className:Z,onClick:I,children:[o(p,{id:"video-thumbnail",src:b??"",alt:E?.altText,title:E?.imageTitle,priority:E?.preload&&h,className:F,isDisableAspectStyle:!0,pageContext:H}),o("button",{type:"button",className:z,"aria-label":"Play",children:o("svg",{className:"gp-w-5 gp-text-white",viewBox:"0 0 24 24",children:o("path",{fill:"currentColor",d:"M5 5.274c0-1.707 1.826-2.792 3.325-1.977l12.362 6.726c1.566.853 1.566 3.101 0 3.953L8.325 20.702C6.826 21.518 5 20.432 5 18.726V5.274Z"})})})]})]})};export{u as default};
2
+ import{jsxs as e,Fragment as t,jsx as o}from"react/jsx-runtime";import{getWrapThumbnailClasses as s,getButtonThumbnailClasses as r,getImageThumbnailClasses as l,getVideoYoutubeClasses as m}from"../common/classes.js";import{createAttr as i,createClass as a,createStyle as c}from"@gem-sdk/system";import n from"../hooks/useLiteHtml5Embed.js";import p from"../../image/components/NextImage.js";import{getPreloadImageStyle as d}from"../common/styles.js";import{getHtml5Attr as y}from"../common/attrs.js";import{useEditorMode as f}from"@gem-sdk/core";let u=u=>{let g=f(),h="edit"!==g,{thumbnail:b,muted:j,autoplay:v,loop:x,controls:N,src:k,style:C,title:w,className:L,lazy:T,poster:E}=u,{playVideoAndTurnOffThumbnail:H,videoRef:I,showThumbnail:M}=n(v,j,k),P=!h&&v&&j&&!!b,V=!T&&u.isVideoComponent&&h,A=!b||!M,B=k||void 0,D=i({...y({title:w,autoplay:v,preloadThumbnail:P,offLazyLoad:V,src:k,thumbnail:b})}),S=a({...s(A)}),Z=c({...d()}),q=a({...r()}),z=a({...l()}),F=a({...m(L,V)});return e(t,{children:[P?o(p,{src:b,alt:w,priority:!0,style:Z}):"",o("video",{ref:I,...D,style:C,className:F,controls:N,loop:x,muted:j,autoPlay:v,playsInline:!0,src:B}),!A&&e("div",{role:"presentation",style:C,className:S,onClick:H,children:[o(p,{id:"video-thumbnail",src:b??"",alt:E?.altText,title:E?.imageTitle,priority:E?.preload&&h,className:z,isDisableAspectStyle:!0}),o("button",{type:"button",className:q,"aria-label":"Play",children:o("svg",{className:"gp-w-5 gp-text-white",viewBox:"0 0 24 24",children:o("path",{fill:"currentColor",d:"M5 5.274c0-1.707 1.826-2.792 3.325-1.977l12.362 6.726c1.566.853 1.566 3.101 0 3.953L8.325 20.702C6.826 21.518 5 20.432 5 18.726V5.274Z"})})})]})]})};export{u as default};
@@ -1,2 +1,2 @@
1
1
  'use client';
2
- import{jsxs as e,jsx as t}from"react/jsx-runtime";import{useEditorMode as r}from"@gem-sdk/core";import a from"react-youtube";import{getButtonYoutubeClasses as o,getImageYoutubeClasses as i,getArticleYoutubeClasses as l,getIframeYoutubeClasses as s,getYoutubeContentClasses as m}from"../common/classes.js";import{getYoutubeParams as n,isSettingLoop as c,covertStrParamsToObj as u}from"../common/helpers.js";import{getIframeYoutubeStyle as d,getArticleYoutubeStyle as p}from"../common/styles.js";import f from"../hooks/useLiteYoutubeEmbed.js";import{createClass as y,createStyle as h}from"@gem-sdk/system";import g from"../../image/components/NextImage.js";let b=b=>{let C=r(),v="edit"!==C,{style:w,poster:N,iframeClass:j,wrapperClass:x,title:k,pageContext:B}=b,{preload:S}=N||{},{videoId:E,paramsImp:T,posterUrl:V,iframeSrc:H}=n(b),{iframe:I,intervalPlay:M,warmConnections:D,isVideoStarted:L,videoDuration:P,addIframe:Y}=f(b,T,E),z=y({...o(I)}),A=y({...i()}),F=y({...l(S&&v||!1,x)}),O=y({...s(j)}),R=h({...d(w)}),q=h({...p(w,V)}),G=y({...m()});return e("article",{"aria-hidden":!0,className:F,"data-title":k,style:q,onPointerOver:D,onClick:Y,children:[t(g,{src:V,alt:N?.altText,title:N?.imageTitle,priority:v&&S,pageContext:B,className:A,isDisableAspectStyle:!0}),t("button",{type:"button","aria-label":"Play",className:z,children:e("svg",{height:"100%",version:"1.1",viewBox:"0 0 68 48",width:"100%",children:[t("path",{d:"M66.52,7.74c-0.78-2.93-2.49-5.41-5.42-6.19C55.79,.13,34,0,34,0S12.21,.13,6.9,1.55 C3.97,2.33,2.27,4.81,1.48,7.74C0.06,13.05,0,24,0,24s0.06,10.95,1.48,16.26c0.78,2.93,2.49,5.41,5.42,6.19 C12.21,47.87,34,48,34,48s21.79-0.13,27.1-1.55c2.93-0.78,4.64-3.26,5.42-6.19C67.94,34.95,68,24,68,24S67.94,13.05,66.52,7.74z",fill:"#f00"}),t("path",{d:"M 45,24 27,14 27,34",fill:"#fff"})]})}),I&&(()=>{if(b.isHeroBanner&&c(T))return t(a,{videoId:E,title:k,iframeClassName:O,style:R,className:G,opts:{host:"https://www.youtube-nocookie.com",playerVars:{autoplay:1,state:1,controls:0,mute:1,...u(T)}},onReady:e=>{if(e.target.playVideo(),P.current=Math.floor(e.target.getDuration()),b.isHeroBanner){let t=e.target.getIframe();if(t){let e=t.closest("div.hero-banner-container");if(e){let r=new CustomEvent("youtube-iframe-ready",{detail:{iframe:t},bubbles:!0,cancelable:!0});e.dispatchEvent(r)}}}},onStateChange:e=>{let t=e.target;L.current||(t.playVideo(),L.current=!0,M(e)),0===e.data&&(P.current=t.getCurrentTime(),t.playVideo(),M(e))}});let e=t("iframe",{className:O,style:R,title:k,frameBorder:"0",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0,src:H});return b.isHeroBanner?t("div",{className:G,children:e}):e})()]})};export{b as default};
2
+ import{jsxs as e,jsx as t}from"react/jsx-runtime";import{useEditorMode as r}from"@gem-sdk/core";import a from"react-youtube";import{getButtonYoutubeClasses as o,getImageYoutubeClasses as i,getArticleYoutubeClasses as l,getIframeYoutubeClasses as s,getYoutubeContentClasses as m}from"../common/classes.js";import{getYoutubeParams as n,isSettingLoop as c,covertStrParamsToObj as u}from"../common/helpers.js";import{getIframeYoutubeStyle as d,getArticleYoutubeStyle as p}from"../common/styles.js";import f from"../hooks/useLiteYoutubeEmbed.js";import{createClass as y,createStyle as h}from"@gem-sdk/system";import b from"../../image/components/NextImage.js";let g=g=>{let C=r(),v="edit"!==C,{style:w,poster:N,iframeClass:j,wrapperClass:k,title:x}=g,{preload:B}=N||{},{videoId:S,paramsImp:E,posterUrl:T,iframeSrc:V}=n(g),{iframe:H,intervalPlay:I,warmConnections:M,isVideoStarted:D,videoDuration:L,addIframe:P}=f(g,E,S),Y=y({...o(H)}),z=y({...i()}),A=y({...l(B&&v||!1,k)}),F=y({...s(j)}),O=h({...d(w)}),R=h({...p(w,T)}),q=y({...m()});return e("article",{"aria-hidden":!0,className:A,"data-title":x,style:R,onPointerOver:M,onClick:P,children:[t(b,{src:T,alt:N?.altText,title:N?.imageTitle,priority:v&&B,className:z,isDisableAspectStyle:!0}),t("button",{type:"button","aria-label":"Play",className:Y,children:e("svg",{height:"100%",version:"1.1",viewBox:"0 0 68 48",width:"100%",children:[t("path",{d:"M66.52,7.74c-0.78-2.93-2.49-5.41-5.42-6.19C55.79,.13,34,0,34,0S12.21,.13,6.9,1.55 C3.97,2.33,2.27,4.81,1.48,7.74C0.06,13.05,0,24,0,24s0.06,10.95,1.48,16.26c0.78,2.93,2.49,5.41,5.42,6.19 C12.21,47.87,34,48,34,48s21.79-0.13,27.1-1.55c2.93-0.78,4.64-3.26,5.42-6.19C67.94,34.95,68,24,68,24S67.94,13.05,66.52,7.74z",fill:"#f00"}),t("path",{d:"M 45,24 27,14 27,34",fill:"#fff"})]})}),H&&(()=>{if(g.isHeroBanner&&c(E))return t(a,{videoId:S,title:x,iframeClassName:F,style:O,className:q,opts:{host:"https://www.youtube-nocookie.com",playerVars:{autoplay:1,state:1,controls:0,mute:1,...u(E)}},onReady:e=>{if(e.target.playVideo(),L.current=Math.floor(e.target.getDuration()),g.isHeroBanner){let t=e.target.getIframe();if(t){let e=t.closest("div.hero-banner-container");if(e){let r=new CustomEvent("youtube-iframe-ready",{detail:{iframe:t},bubbles:!0,cancelable:!0});e.dispatchEvent(r)}}}},onStateChange:e=>{let t=e.target;D.current||(t.playVideo(),D.current=!0,I(e)),0===e.data&&(L.current=t.getCurrentTime(),t.playVideo(),I(e))}});let e=t("iframe",{className:F,style:O,title:x,frameBorder:"0",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0,src:V});return g.isHeroBanner?t("div",{className:q,children:e}):e})()]})};export{g as default};
@@ -176,7 +176,7 @@ type ImageProps = BasePropsWrap<ImageSettingProps$1, ImageStyleProps$1> & {
176
176
  onLoad?: React.ReactEventHandler<any>;
177
177
  } & {
178
178
  advanced?: any;
179
- };
179
+ } & Pick<ImageSizeProps, 'sizeTarget'>;
180
180
  type ImageLiquidProps = ImageProps & Pick<ImageSizeProps, 'sizeTarget'> & {
181
181
  pageContext?: PageContext;
182
182
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gem-sdk/components",
3
- "version": "23.0.0-staging.12",
3
+ "version": "23.0.0-staging.13",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "main": "dist/cjs/index.js",