@anker-in/headless-ui 1.0.26-alpha.1762243303200 → 1.0.26-alpha.1762257871632

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 (214) hide show
  1. package/dist/cjs/biz-components/AiuiProvider/index.d.ts +1 -1
  2. package/dist/cjs/biz-components/AiuiProvider/index.js.map +1 -1
  3. package/dist/cjs/biz-components/AplusDesc/index.d.ts +22 -0
  4. package/dist/cjs/biz-components/AplusDesc/index.js +2 -0
  5. package/dist/cjs/biz-components/AplusDesc/index.js.map +7 -0
  6. package/dist/cjs/biz-components/CollectionShelves/CollectionShelvesItem.d.ts +4 -0
  7. package/dist/cjs/biz-components/CollectionShelves/CollectionShelvesItem.js +2 -0
  8. package/dist/cjs/biz-components/CollectionShelves/CollectionShelvesItem.js.map +7 -0
  9. package/dist/cjs/biz-components/CollectionShelves/index.d.ts +6 -0
  10. package/dist/cjs/biz-components/CollectionShelves/index.js +2 -0
  11. package/dist/cjs/biz-components/CollectionShelves/index.js.map +7 -0
  12. package/dist/cjs/biz-components/CollectionsBanner/index.d.ts +7 -0
  13. package/dist/cjs/biz-components/CollectionsBanner/index.js +2 -0
  14. package/dist/cjs/biz-components/CollectionsBanner/index.js.map +7 -0
  15. package/dist/cjs/biz-components/CollectionsBanner/types.d.ts +43 -0
  16. package/dist/cjs/biz-components/CollectionsBanner/types.js +2 -0
  17. package/dist/cjs/biz-components/CollectionsBanner/types.js.map +7 -0
  18. package/dist/cjs/biz-components/CollectionsFilters/FilterCardWrap.d.ts +18 -0
  19. package/dist/cjs/biz-components/CollectionsFilters/FilterCardWrap.js +2 -0
  20. package/dist/cjs/biz-components/CollectionsFilters/FilterCardWrap.js.map +7 -0
  21. package/dist/cjs/biz-components/CollectionsFilters/FilterCardWrapItem.d.ts +10 -0
  22. package/dist/cjs/biz-components/CollectionsFilters/FilterCardWrapItem.js +2 -0
  23. package/dist/cjs/biz-components/CollectionsFilters/FilterCardWrapItem.js.map +7 -0
  24. package/dist/cjs/biz-components/CollectionsFilters/FilterHeader.d.ts +13 -0
  25. package/dist/cjs/biz-components/CollectionsFilters/FilterHeader.js +2 -0
  26. package/dist/cjs/biz-components/CollectionsFilters/FilterHeader.js.map +7 -0
  27. package/dist/cjs/biz-components/CollectionsFilters/FilterList.d.ts +14 -0
  28. package/dist/cjs/biz-components/CollectionsFilters/FilterList.js +2 -0
  29. package/dist/cjs/biz-components/CollectionsFilters/FilterList.js.map +7 -0
  30. package/dist/cjs/biz-components/CollectionsFilters/component/AnimatedUL.d.ts +5 -0
  31. package/dist/cjs/biz-components/CollectionsFilters/component/AnimatedUL.js +2 -0
  32. package/dist/cjs/biz-components/CollectionsFilters/component/AnimatedUL.js.map +7 -0
  33. package/dist/cjs/biz-components/CollectionsFilters/component/TabFilter.d.ts +12 -0
  34. package/dist/cjs/biz-components/CollectionsFilters/component/TabFilter.js +2 -0
  35. package/dist/cjs/biz-components/CollectionsFilters/component/TabFilter.js.map +7 -0
  36. package/dist/cjs/biz-components/CollectionsFilters/component/filtersFun.d.ts +12 -0
  37. package/dist/cjs/biz-components/CollectionsFilters/component/filtersFun.js +2 -0
  38. package/dist/cjs/biz-components/CollectionsFilters/component/filtersFun.js.map +7 -0
  39. package/dist/cjs/biz-components/CollectionsFilters/component/helper.d.ts +81 -0
  40. package/dist/cjs/biz-components/CollectionsFilters/component/helper.js +2 -0
  41. package/dist/cjs/biz-components/CollectionsFilters/component/helper.js.map +7 -0
  42. package/dist/cjs/biz-components/CollectionsFilters/component/price.d.ts +25 -0
  43. package/dist/cjs/biz-components/CollectionsFilters/component/price.js +2 -0
  44. package/dist/cjs/biz-components/CollectionsFilters/component/price.js.map +7 -0
  45. package/dist/cjs/biz-components/CollectionsFilters/component/priceProps.d.ts +215 -0
  46. package/dist/cjs/biz-components/CollectionsFilters/component/priceProps.js +2 -0
  47. package/dist/cjs/biz-components/CollectionsFilters/component/priceProps.js.map +7 -0
  48. package/dist/cjs/biz-components/CollectionsFilters/index.d.ts +23 -0
  49. package/dist/cjs/biz-components/CollectionsFilters/index.js +2 -0
  50. package/dist/cjs/biz-components/CollectionsFilters/index.js.map +7 -0
  51. package/dist/cjs/biz-components/DownLoad/index.d.ts +20 -0
  52. package/dist/cjs/biz-components/DownLoad/index.js +2 -0
  53. package/dist/cjs/biz-components/DownLoad/index.js.map +7 -0
  54. package/dist/cjs/biz-components/Faq/Faq.js +1 -1
  55. package/dist/cjs/biz-components/Faq/Faq.js.map +2 -2
  56. package/dist/cjs/biz-components/Features/index.d.ts +26 -0
  57. package/dist/cjs/biz-components/Features/index.js +2 -0
  58. package/dist/cjs/biz-components/Features/index.js.map +7 -0
  59. package/dist/cjs/biz-components/FootCharger/index.d.ts +12 -0
  60. package/dist/cjs/biz-components/FootCharger/index.js +2 -0
  61. package/dist/cjs/biz-components/FootCharger/index.js.map +7 -0
  62. package/dist/cjs/biz-components/GiftBox/index.d.ts +17 -0
  63. package/dist/cjs/biz-components/GiftBox/index.js +2 -0
  64. package/dist/cjs/biz-components/GiftBox/index.js.map +7 -0
  65. package/dist/cjs/biz-components/Graphic/index.js +1 -1
  66. package/dist/cjs/biz-components/Graphic/index.js.map +2 -2
  67. package/dist/cjs/biz-components/GraphicMore/index.d.ts +22 -0
  68. package/dist/cjs/biz-components/GraphicMore/index.js +2 -0
  69. package/dist/cjs/biz-components/GraphicMore/index.js.map +7 -0
  70. package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js +1 -1
  71. package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js.map +2 -2
  72. package/dist/cjs/biz-components/Paginator/index.d.ts +7 -0
  73. package/dist/cjs/biz-components/Paginator/index.js +7 -0
  74. package/dist/cjs/biz-components/Paginator/index.js.map +7 -0
  75. package/dist/cjs/biz-components/SelectStore/index.d.ts +20 -0
  76. package/dist/cjs/biz-components/SelectStore/index.js +2 -0
  77. package/dist/cjs/biz-components/SelectStore/index.js.map +7 -0
  78. package/dist/cjs/biz-components/ShelfDisplay/index.js +1 -1
  79. package/dist/cjs/biz-components/ShelfDisplay/index.js.map +3 -3
  80. package/dist/cjs/biz-components/ShelfDisplay/shelfDisplay.d.ts +11 -2
  81. package/dist/cjs/biz-components/ShelfDisplay/shelfDisplay.js +1 -1
  82. package/dist/cjs/biz-components/ShelfDisplay/shelfDisplay.js.map +3 -3
  83. package/dist/cjs/biz-components/ShelfDisplay/shelfDisplayItem.js +4 -4
  84. package/dist/cjs/biz-components/ShelfDisplay/shelfDisplayItem.js.map +3 -3
  85. package/dist/cjs/biz-components/TextMarquee/index.d.ts +9 -0
  86. package/dist/cjs/biz-components/TextMarquee/index.js +2 -0
  87. package/dist/cjs/biz-components/TextMarquee/index.js.map +7 -0
  88. package/dist/cjs/biz-components/Title/index.js +1 -1
  89. package/dist/cjs/biz-components/Title/index.js.map +3 -3
  90. package/dist/cjs/biz-components/Title/types.d.ts +1 -0
  91. package/dist/cjs/biz-components/Title/types.js +1 -1
  92. package/dist/cjs/biz-components/Title/types.js.map +1 -1
  93. package/dist/cjs/biz-components/index.d.ts +16 -0
  94. package/dist/cjs/biz-components/index.js +1 -1
  95. package/dist/cjs/biz-components/index.js.map +3 -3
  96. package/dist/cjs/components/breadcrumb.d.ts +12 -0
  97. package/dist/cjs/components/breadcrumb.js +2 -0
  98. package/dist/cjs/components/breadcrumb.js.map +7 -0
  99. package/dist/cjs/components/index.d.ts +1 -0
  100. package/dist/cjs/components/index.js +1 -1
  101. package/dist/cjs/components/index.js.map +3 -3
  102. package/dist/cjs/helpers/utils.d.ts +1 -0
  103. package/dist/cjs/helpers/utils.js +1 -1
  104. package/dist/cjs/helpers/utils.js.map +3 -3
  105. package/dist/cjs/hooks/useRollout.d.ts +1 -0
  106. package/dist/cjs/hooks/useRollout.js +2 -0
  107. package/dist/cjs/hooks/useRollout.js.map +7 -0
  108. package/dist/esm/biz-components/AiuiProvider/index.d.ts +1 -1
  109. package/dist/esm/biz-components/AiuiProvider/index.js.map +1 -1
  110. package/dist/esm/biz-components/AplusDesc/index.d.ts +22 -0
  111. package/dist/esm/biz-components/AplusDesc/index.js +2 -0
  112. package/dist/esm/biz-components/AplusDesc/index.js.map +7 -0
  113. package/dist/esm/biz-components/CollectionShelves/CollectionShelvesItem.d.ts +4 -0
  114. package/dist/esm/biz-components/CollectionShelves/CollectionShelvesItem.js +2 -0
  115. package/dist/esm/biz-components/CollectionShelves/CollectionShelvesItem.js.map +7 -0
  116. package/dist/esm/biz-components/CollectionShelves/index.d.ts +6 -0
  117. package/dist/esm/biz-components/CollectionShelves/index.js +2 -0
  118. package/dist/esm/biz-components/CollectionShelves/index.js.map +7 -0
  119. package/dist/esm/biz-components/CollectionsBanner/index.d.ts +7 -0
  120. package/dist/esm/biz-components/CollectionsBanner/index.js +2 -0
  121. package/dist/esm/biz-components/CollectionsBanner/index.js.map +7 -0
  122. package/dist/esm/biz-components/CollectionsBanner/types.d.ts +43 -0
  123. package/dist/esm/biz-components/CollectionsBanner/types.js +1 -0
  124. package/dist/esm/biz-components/CollectionsBanner/types.js.map +7 -0
  125. package/dist/esm/biz-components/CollectionsFilters/FilterCardWrap.d.ts +18 -0
  126. package/dist/esm/biz-components/CollectionsFilters/FilterCardWrap.js +2 -0
  127. package/dist/esm/biz-components/CollectionsFilters/FilterCardWrap.js.map +7 -0
  128. package/dist/esm/biz-components/CollectionsFilters/FilterCardWrapItem.d.ts +10 -0
  129. package/dist/esm/biz-components/CollectionsFilters/FilterCardWrapItem.js +2 -0
  130. package/dist/esm/biz-components/CollectionsFilters/FilterCardWrapItem.js.map +7 -0
  131. package/dist/esm/biz-components/CollectionsFilters/FilterHeader.d.ts +13 -0
  132. package/dist/esm/biz-components/CollectionsFilters/FilterHeader.js +2 -0
  133. package/dist/esm/biz-components/CollectionsFilters/FilterHeader.js.map +7 -0
  134. package/dist/esm/biz-components/CollectionsFilters/FilterList.d.ts +14 -0
  135. package/dist/esm/biz-components/CollectionsFilters/FilterList.js +2 -0
  136. package/dist/esm/biz-components/CollectionsFilters/FilterList.js.map +7 -0
  137. package/dist/esm/biz-components/CollectionsFilters/component/AnimatedUL.d.ts +5 -0
  138. package/dist/esm/biz-components/CollectionsFilters/component/AnimatedUL.js +2 -0
  139. package/dist/esm/biz-components/CollectionsFilters/component/AnimatedUL.js.map +7 -0
  140. package/dist/esm/biz-components/CollectionsFilters/component/TabFilter.d.ts +12 -0
  141. package/dist/esm/biz-components/CollectionsFilters/component/TabFilter.js +2 -0
  142. package/dist/esm/biz-components/CollectionsFilters/component/TabFilter.js.map +7 -0
  143. package/dist/esm/biz-components/CollectionsFilters/component/filtersFun.d.ts +12 -0
  144. package/dist/esm/biz-components/CollectionsFilters/component/filtersFun.js +2 -0
  145. package/dist/esm/biz-components/CollectionsFilters/component/filtersFun.js.map +7 -0
  146. package/dist/esm/biz-components/CollectionsFilters/component/helper.d.ts +81 -0
  147. package/dist/esm/biz-components/CollectionsFilters/component/helper.js +2 -0
  148. package/dist/esm/biz-components/CollectionsFilters/component/helper.js.map +7 -0
  149. package/dist/esm/biz-components/CollectionsFilters/component/price.d.ts +25 -0
  150. package/dist/esm/biz-components/CollectionsFilters/component/price.js +2 -0
  151. package/dist/esm/biz-components/CollectionsFilters/component/price.js.map +7 -0
  152. package/dist/esm/biz-components/CollectionsFilters/component/priceProps.d.ts +215 -0
  153. package/dist/esm/biz-components/CollectionsFilters/component/priceProps.js +2 -0
  154. package/dist/esm/biz-components/CollectionsFilters/component/priceProps.js.map +7 -0
  155. package/dist/esm/biz-components/CollectionsFilters/index.d.ts +23 -0
  156. package/dist/esm/biz-components/CollectionsFilters/index.js +2 -0
  157. package/dist/esm/biz-components/CollectionsFilters/index.js.map +7 -0
  158. package/dist/esm/biz-components/DownLoad/index.d.ts +20 -0
  159. package/dist/esm/biz-components/DownLoad/index.js +2 -0
  160. package/dist/esm/biz-components/DownLoad/index.js.map +7 -0
  161. package/dist/esm/biz-components/Faq/Faq.js +1 -1
  162. package/dist/esm/biz-components/Faq/Faq.js.map +3 -3
  163. package/dist/esm/biz-components/Features/index.d.ts +26 -0
  164. package/dist/esm/biz-components/Features/index.js +2 -0
  165. package/dist/esm/biz-components/Features/index.js.map +7 -0
  166. package/dist/esm/biz-components/FootCharger/index.d.ts +12 -0
  167. package/dist/esm/biz-components/FootCharger/index.js +2 -0
  168. package/dist/esm/biz-components/FootCharger/index.js.map +7 -0
  169. package/dist/esm/biz-components/GiftBox/index.d.ts +17 -0
  170. package/dist/esm/biz-components/GiftBox/index.js +2 -0
  171. package/dist/esm/biz-components/GiftBox/index.js.map +7 -0
  172. package/dist/esm/biz-components/Graphic/index.js +1 -1
  173. package/dist/esm/biz-components/Graphic/index.js.map +2 -2
  174. package/dist/esm/biz-components/GraphicMore/index.d.ts +22 -0
  175. package/dist/esm/biz-components/GraphicMore/index.js +2 -0
  176. package/dist/esm/biz-components/GraphicMore/index.js.map +7 -0
  177. package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js +1 -1
  178. package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js.map +2 -2
  179. package/dist/esm/biz-components/Paginator/index.d.ts +7 -0
  180. package/dist/esm/biz-components/Paginator/index.js +7 -0
  181. package/dist/esm/biz-components/Paginator/index.js.map +7 -0
  182. package/dist/esm/biz-components/SelectStore/index.d.ts +20 -0
  183. package/dist/esm/biz-components/SelectStore/index.js +2 -0
  184. package/dist/esm/biz-components/SelectStore/index.js.map +7 -0
  185. package/dist/esm/biz-components/ShelfDisplay/index.js +1 -1
  186. package/dist/esm/biz-components/ShelfDisplay/index.js.map +3 -3
  187. package/dist/esm/biz-components/ShelfDisplay/shelfDisplay.d.ts +11 -2
  188. package/dist/esm/biz-components/ShelfDisplay/shelfDisplay.js +1 -1
  189. package/dist/esm/biz-components/ShelfDisplay/shelfDisplay.js.map +3 -3
  190. package/dist/esm/biz-components/ShelfDisplay/shelfDisplayItem.js +9 -9
  191. package/dist/esm/biz-components/ShelfDisplay/shelfDisplayItem.js.map +3 -3
  192. package/dist/esm/biz-components/TextMarquee/index.d.ts +9 -0
  193. package/dist/esm/biz-components/TextMarquee/index.js +2 -0
  194. package/dist/esm/biz-components/TextMarquee/index.js.map +7 -0
  195. package/dist/esm/biz-components/Title/index.js +1 -1
  196. package/dist/esm/biz-components/Title/index.js.map +3 -3
  197. package/dist/esm/biz-components/Title/types.d.ts +1 -0
  198. package/dist/esm/biz-components/index.d.ts +16 -0
  199. package/dist/esm/biz-components/index.js +1 -1
  200. package/dist/esm/biz-components/index.js.map +2 -2
  201. package/dist/esm/components/breadcrumb.d.ts +12 -0
  202. package/dist/esm/components/breadcrumb.js +2 -0
  203. package/dist/esm/components/breadcrumb.js.map +7 -0
  204. package/dist/esm/components/index.d.ts +1 -0
  205. package/dist/esm/components/index.js +1 -1
  206. package/dist/esm/components/index.js.map +2 -2
  207. package/dist/esm/helpers/utils.d.ts +1 -0
  208. package/dist/esm/helpers/utils.js +1 -1
  209. package/dist/esm/helpers/utils.js.map +3 -3
  210. package/dist/esm/hooks/useRollout.d.ts +1 -0
  211. package/dist/esm/hooks/useRollout.js +2 -0
  212. package/dist/esm/hooks/useRollout.js.map +7 -0
  213. package/package.json +1 -1
  214. package/style.css +23 -0
@@ -1,10 +1,10 @@
1
- "use strict";var M=Object.create;var k=Object.defineProperty;var V=Object.getOwnPropertyDescriptor;var q=Object.getOwnPropertyNames;var G=Object.getPrototypeOf,J=Object.prototype.hasOwnProperty;var K=(e,t)=>{for(var n in t)k(e,n,{get:t[n],enumerable:!0})},W=(e,t,n,c)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of q(t))!J.call(e,o)&&o!==n&&k(e,o,{get:()=>t[o],enumerable:!(c=V(t,o))||c.enumerable});return e};var P=(e,t,n)=>(n=e!=null?M(G(e)):{},W(t||!e||!e.__esModule?k(n,"default",{value:e,enumerable:!0}):n,e)),Q=e=>W(k({},"__esModule",{value:!0}),e);var Z={};K(Z,{ShelfDisplayHorizontalItem:()=>Y,ShelfDisplayWrapItem:()=>X});module.exports=Q(Z);var l=require("react/jsx-runtime"),$=require("../AiuiProvider/index.js"),j=require("./shelfDisplay.js"),S=P(require("../../components/picture.js")),O=P(require("../../components/badge.js")),m=require("../../helpers/utils.js"),H=require("../../components/text.js"),b=P(require("../../components/button.js")),L=require("../../shared/track.js"),z=require("../../shared/trackUrlRef.js"),E=require("../../components/heading.js"),F=require("../../hooks/useExposure.js"),U=require("react");const w="image",g="product_shelf",A=999999999e-2,X=({data:e,configuration:t})=>{const{isDisplayBackImage:n=!1,itemShape:c}=t||{},{locale:o="us",copyWriting:_}=(0,$.useAiuiContext)(),h=(0,U.useRef)(null),N=(i,s,r)=>t?.event?.primaryButton?.(i,s+1,r),B=(i,s,r)=>t?.event?.secondaryButton?.(i,s+1,r),a=e?.variants?.find(i=>i?.sku===e?.sku)||e?.variants?.[0]||{},D=!a?.availableForSale&&a?.price?.amount===A,T=t?.isShowTag,f=t?.isShowOriginalPrice,d=a?.coupons?.[0],{price:C,basePrice:I}=(0,j.formatVariantPrice)({locale:o,amount:f&&d?d.variant_price4wscode:a.price,baseAmount:f&&d?a.price:0,currencyCode:e?.price?.currencyCode||"USD"}),y=()=>{const i=e?.sku,s=e?.variants;return s?.find(v=>v?.sku===i)?.image?.url||s?.[0]?.image?.url||""},p=e?.custom_name||e?.title,x=e?.custom_description||e?.description;(0,F.useExposure)(h,{componentType:w,componentName:g,componentTitle:p,componentDescription:x,position:t?.index+1});const u=()=>(0,l.jsxs)(l.Fragment,{children:[T?(0,l.jsx)("div",{className:"mb-1 box-border flex h-8 flex-wrap gap-1 overflow-hidden",children:e?.tags?.filter?.(i=>i?.startsWith?.("CLtag"))?.map?.(i=>i?.replace?.("CLtag:",""))?.slice?.(0,2)?.map?.((i,s)=>(0,l.jsx)(O.default,{children:i},s))}):null,p?(0,l.jsx)(E.Heading,{as:"h3",title:p||"",size:2,className:"shelf-display-product-title mb-1 line-clamp-2",html:p||""}):null,x?(0,l.jsx)(H.Text,{size:2,className:"lg-desktop:text-lg lg-desktop:h-[26px] desktop:text-base desktop:h-6 shelf-display-product-description line-clamp-1 h-5 text-sm",html:x||""}):null,(0,l.jsx)("div",{className:"mb-2 mt-5 flex items-center",children:D?(0,l.jsx)("div",{className:"tablet:text-2xl text-info-primary text-xl font-bold",children:_?.soldOutText}):(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("div",{className:"final-price tablet:text-2xl text-info-primary text-xl font-bold",children:a?.availableForSale&&C||""}),(0,l.jsx)("div",{className:"origin-price tablet:text-xl text-info-secondary ml-1 text-lg font-bold line-through",children:a?.availableForSale&&I||""})]})}),(0,l.jsxs)("div",{className:(0,m.cn)("shelf-flex-button-group","lg-desktop:gap-3 flex items-center gap-2",t.direction==="vertical"?"flex-col":""),children:[t?.secondaryButton?(0,l.jsx)(b.default,{variant:"secondary",onClick:()=>B(e,t?.index,t),className:`
1
+ "use strict";var K=Object.create;var N=Object.defineProperty;var Q=Object.getOwnPropertyDescriptor;var X=Object.getOwnPropertyNames;var Y=Object.getPrototypeOf,Z=Object.prototype.hasOwnProperty;var ee=(e,t)=>{for(var n in t)N(e,n,{get:t[n],enumerable:!0})},q=(e,t,n,x)=>{if(t&&typeof t=="object"||typeof t=="function")for(let c of X(t))!Z.call(e,c)&&c!==n&&N(e,c,{get:()=>t[c],enumerable:!(x=Q(t,c))||x.enumerable});return e};var z=(e,t,n)=>(n=e!=null?K(Y(e)):{},q(t||!e||!e.__esModule?N(n,"default",{value:e,enumerable:!0}):n,e)),te=e=>q(N({},"__esModule",{value:!0}),e);var oe={};ee(oe,{ShelfDisplayHorizontalItem:()=>le,ShelfDisplayWrapItem:()=>se});module.exports=te(oe);var s=require("react/jsx-runtime"),E=require("../AiuiProvider/index.js"),F=require("./shelfDisplay.js"),D=z(require("../../components/picture.js")),U=z(require("../../components/badge.js")),d=require("../../helpers/utils.js"),W=require("../../components/text.js"),k=z(require("../../components/button.js")),A=require("../../shared/track.js"),R=require("../../shared/trackUrlRef.js"),M=require("../../components/heading.js"),V=require("../../hooks/useExposure.js"),u=require("react");const T="image",B="product_shelf",G=999999999e-2,se=({data:e,configuration:t})=>{const{isDisplayBackImage:n=!1,itemShape:x,metafields:c}=t||{},{locale:f="us",copyWriting:b}=(0,E.useAiuiContext)(),{discounts:C}=c||{},w=(0,u.useRef)(null),[$,S]=(0,u.useState)([]),I=(i,l,a)=>t?.event?.primaryButton?.(i,l+1,a),P=(i,l,a)=>t?.event?.secondaryButton?.(i,l+1,a),o=e?.variants?.find(i=>i?.sku===e?.sku)||e?.variants?.[0]||{},j=!o?.availableForSale&&o?.price?.amount===G,O=t?.isShowTag,g=t?.isShowOriginalPrice,h=o?.coupons?.[0],{price:H,basePrice:L,discount:m}=(0,F.formatVariantPrice)({locale:f,amount:g&&h?h.variant_price4wscode:o.price,baseAmount:g&&h?o.price:0,currencyCode:e?.price?.currencyCode||"USD"}),_=()=>{const i=e?.sku,l=e?.variants;return l?.find(r=>r?.sku===i)?.image?.url||l?.[0]?.image?.url||""},p=e?.custom_name||e?.title,v=e?.custom_description||e?.description;(0,u.useEffect)(()=>{let i=[];if(m){const a=`${m}${C?.off||""}`;i.push(a)}const l=e?.tags?.filter?.(a=>a?.startsWith?.("CLtag"))?.map?.(a=>a?.replace?.("CLtag:",""))?.slice?.(0,m?1:2);S(i.concat(l))},[e?.tags,m]),(0,V.useExposure)(w,{componentType:T,componentName:B,componentTitle:p,componentDescription:v,position:t?.index+1});const y=()=>(0,s.jsxs)(s.Fragment,{children:[O?(0,s.jsx)("div",{className:"mb-1 box-border flex h-8 flex-wrap gap-1 overflow-hidden",children:$?.map?.((i,l)=>(0,s.jsx)(U.default,{children:i},l))}):null,p?(0,s.jsx)(M.Heading,{as:"h3",title:p||"",size:2,className:"shelf-display-product-title mb-1 line-clamp-2",html:p||""}):null,v?(0,s.jsx)(W.Text,{size:2,className:"lg-desktop:text-lg lg-desktop:h-[26px] desktop:text-base desktop:h-6 shelf-display-product-description line-clamp-1 h-5 text-sm",html:v||""}):null,(0,s.jsx)("div",{className:"mb-2 mt-5 flex items-center",children:j?(0,s.jsx)("div",{className:"tablet:text-2xl text-info-primary text-xl font-bold",children:b?.soldOutText}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"final-price tablet:text-2xl text-info-primary text-xl font-bold",children:o?.availableForSale&&H||""}),(0,s.jsx)("div",{className:"origin-price tablet:text-xl text-info-secondary ml-1 text-lg font-bold line-through",children:o?.availableForSale&&L||""})]})}),(0,s.jsxs)("div",{className:(0,d.cn)("shelf-flex-button-group","lg-desktop:gap-3 flex items-center gap-2",t.direction==="vertical"?"flex-col":""),children:[t?.secondaryButton?(0,s.jsx)(k.default,{variant:"secondary",onClick:()=>P(e,t?.index,t),className:`
2
2
  ${t.direction==="vertical"?"w-full":""}
3
- `,children:t?.secondaryButton||""}):null,t?.primaryButton?(0,l.jsx)(b.default,{variant:"primary",onClick:()=>N(e,t?.index,t),className:`
3
+ `,children:t?.secondaryButton||""}):null,t?.primaryButton?(0,s.jsx)(k.default,{variant:"primary",onClick:()=>I(e,t?.index,t),className:`
4
4
  ${t.direction==="vertical"?"w-full":""}
5
- `,children:t?.primaryButton||""}):null]})]});return(0,l.jsx)("div",{ref:h,className:(0,m.cn)("bg-container-secondary-1 tablet:hover:bg-info-white box-border w-full cursor-pointer overflow-hidden duration-300",c==="round"?"rounded-2xl":"rounded-none","lg-desktop:aspect-w-[404] lg-desktop:aspect-h-[480] desktop:aspect-w-[316] desktop:aspect-h-[384]","laptop:aspect-w-[288] laptop:aspect-h-[360] aspect-w-[296] aspect-h-[360] relative","md-tablet:h-[360px]"),children:n?(0,l.jsx)("div",{className:"absolute inset-0 box-border overflow-hidden",children:(0,l.jsxs)("div",{className:"relative inset-0 size-full",children:[(0,l.jsx)(S.default,{source:y(),alt:"",className:"flex h-full justify-center object-cover [&_img]:w-auto"}),(0,l.jsx)("div",{className:"desktop:p-6 absolute inset-x-0 bottom-0 box-border overflow-hidden p-4",children:u()})]})}):(0,l.jsxs)("div",{className:"desktop:p-6 absolute inset-0 box-border flex flex-col justify-between overflow-hidden p-4",children:[(0,l.jsx)("div",{className:(0,m.cn)("lg-desktop:mb-3 lg-desktop:h-[195px] relative mb-2 inline-block h-[140px] w-full flex-1 overflow-hidden"),children:(0,l.jsx)("a",{"aria-label":p,target:t?.target,href:(0,z.trackUrlRef)(`${o==="us"||!o?"":`/${o}`}/products/${e?.handle}`,`${w}_${g}`),onClick:()=>{(0,L.gaTrack)({event:"ga4Event",event_name:"select_item",event_parameters:{page_group:"Home Page",item_list_name:"Home_Page_Bundle",items:[{item_id:e?.sku||a?.sku,item_name:e?.name,item_variant:a?.name,price:a?.price,index:t?.index+1}]}})},children:(0,l.jsx)(S.default,{source:y(),alt:"",className:"flex h-full justify-center object-cover [&_img]:w-auto"})})}),u()]})},e?.id||e?.handle)},Y=({data:e,configuration:t})=>{const{itemShape:n,itemLength:c}=t||{},{locale:o="us",copyWriting:_}=(0,$.useAiuiContext)(),h=(0,U.useRef)(null),N=(s,r,v)=>t?.event?.primaryButton?.(s,r+1,v),B=(s,r,v)=>t?.event?.secondaryButton?.(s,r+1,v),a=e?.variants?.find(s=>s?.sku===e?.sku)||e?.variants?.[0]||{},D=!a?.availableForSale&&a?.price?.amount===A,T=t?.isShowTag,f=t?.isShowOriginalPrice,d=a?.coupons?.[0],{price:C,basePrice:I}=(0,j.formatVariantPrice)({locale:o,amount:f&&d?d.variant_price4wscode:a.price,baseAmount:f&&d?a.price:0,currencyCode:e?.price?.currencyCode||"USD"}),y=()=>{const s=e?.sku,r=e?.variants;return r?.find(R=>R?.sku===s)?.image?.url||r?.[0]?.image?.url||""},p=e?.custom_name||e?.title,x=e?.custom_description||e?.description;(0,F.useExposure)(h,{componentType:w,componentName:g,componentTitle:p,componentDescription:x,position:t?.index+1});const u=()=>c>=2?{boxItem:"lg-desktop:max-w-[401px] desktop:max-w-[292px] max-w-full",imgItem:"m-tablet:m-auto lg-desktop:max-w-[330px] lg-desktop:max-h-[330px] desktop:max-w-[260px] desktop:max-h-[260px] max-w-[138px] max-h-[138px]",wrap:"lg-desktop:aspect-w-[824] lg-desktop:aspect-h-[480] desktop:aspect-w-[648] desktop:aspect-h-[380] laptop:aspect-w-[440] laptop:aspect-h-[356] tablet:aspect-w-[346] tablet:aspect-h-[360] md-tablet:w-full"}:{boxItem:"lg-desktop:max-w-[401px] desktop:max-w-[292px] laptop:max-w-[289px] max-w-[262px]",imgItem:"md-tablet:m-auto lg-desktop:max-w-[450px] lg-desktop:max-h-[450px] desktop:max-w-[332px] desktop:max-h-[332px] max-w-[312px] max-h-[312px]",wrap:"lg-desktop:aspect-w-[1664] lg-desktop:aspect-h-[480] desktop:aspect-w-[1312] desktop:aspect-h-[380] laptop:aspect-w-[896] laptop:aspect-h-[356] tablet:aspect-w-[704] tablet:aspect-h-[360] md-tablet:w-full"},i=()=>c>=2?"flex flex-col justify-between desktop:gap-12 desktop:flex-row desktop:justify-center desktop:items-center":"flex justify-center items-center gap-6 md-tablet:flex-col";return(0,l.jsx)("div",{ref:h,className:(0,m.cn)(u().wrap,n==="round"?"rounded-2xl":"rounded-none","bg-container-secondary-1 tablet:hover:bg-info-white duration-300 gap-6","box-border w-full cursor-pointer overflow-hidden relative md-tablet:h-[360px]"),children:(0,l.jsxs)("div",{className:(0,m.cn)(i(),"desktop:p-6 absolute inset-0 box-border overflow-hidden p-4"),children:[(0,l.jsx)("div",{className:(0,m.cn)(u().imgItem,"relative overflow-hidden desktop:mb-0 mb-1"),children:(0,l.jsx)("a",{"aria-label":p,target:t?.target,href:(0,z.trackUrlRef)(`${o==="us"||!o?"":`/${o}`}/products/${e?.handle}`,`${w}_${g}`),onClick:()=>{(0,L.gaTrack)({event:"ga4Event",event_name:"select_item",event_parameters:{page_group:"Home Page",item_list_name:"Home_Page_Bundle",items:[{item_id:e?.sku||a?.sku,item_name:e?.name,item_variant:a?.name,price:a?.price,index:t?.index+1}]}})},children:(0,l.jsx)(S.default,{source:y(),alt:"",className:"flex h-full justify-center object-cover [&_img]:w-auto"})})}),(0,l.jsxs)("div",{className:(0,m.cn)("flex flex-col justify-center items-start",u().boxItem),children:[T?(0,l.jsx)("div",{className:"mb-1 box-border flex h-8 flex-wrap gap-1 overflow-hidden",children:e?.tags?.filter?.(s=>s?.startsWith?.("CLtag"))?.map?.(s=>s?.replace?.("CLtag:",""))?.slice?.(0,2)?.map?.((s,r)=>(0,l.jsx)(O.default,{children:s},r))}):null,p?(0,l.jsx)(E.Heading,{as:"h3",title:p||"",size:2,className:"shelf-display-product-title mb-1 line-clamp-2",html:p||""}):null,x?(0,l.jsx)(H.Text,{size:2,className:"lg-desktop:text-lg lg-desktop:h-[26px] desktop:text-base desktop:h-6 shelf-display-product-description line-clamp-1 h-5 text-sm",html:x||""}):null,(0,l.jsx)("div",{className:"mb-2 mt-5 flex items-center",children:D?(0,l.jsx)("div",{className:"tablet:text-2xl text-info-primary text-xl font-bold",children:_?.soldOutText}):(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("div",{className:"final-price tablet:text-2xl text-info-primary text-xl font-bold",children:a?.availableForSale&&C||""}),(0,l.jsx)("div",{className:"origin-price tablet:text-xl text-info-secondary ml-1 text-lg font-bold line-through",children:a?.availableForSale&&I||""})]})}),(0,l.jsxs)("div",{className:(0,m.cn)("shelf-flex-button-group","lg-desktop:gap-3 flex items-center gap-2",t.direction==="vertical"?"flex-col":""),children:[t?.secondaryButton?(0,l.jsx)(b.default,{variant:"secondary",onClick:()=>B(e,t?.index,t),className:`
5
+ `,children:t?.primaryButton||""}):null]})]});return(0,s.jsx)("div",{ref:w,className:(0,d.cn)("bg-container-secondary-1 tablet:hover:bg-info-white box-border w-full cursor-pointer overflow-hidden duration-300",x==="round"?"rounded-2xl":"rounded-none","lg-desktop:aspect-w-[404] lg-desktop:aspect-h-[480] desktop:aspect-w-[316] desktop:aspect-h-[384]","laptop:aspect-w-[288] laptop:aspect-h-[360] aspect-w-[296] aspect-h-[360] relative","md-tablet:h-[360px]"),children:n?(0,s.jsx)("div",{className:"absolute inset-0 box-border overflow-hidden",children:(0,s.jsxs)("div",{className:"relative inset-0 size-full",children:[(0,s.jsx)(D.default,{source:_(),alt:"",className:"flex h-full justify-center object-cover [&_img]:w-auto"}),(0,s.jsx)("div",{className:"desktop:p-6 absolute inset-x-0 bottom-0 box-border overflow-hidden p-4",children:y()})]})}):(0,s.jsxs)("div",{className:"desktop:p-6 absolute inset-0 box-border flex flex-col justify-between overflow-hidden p-4",children:[(0,s.jsx)("div",{className:(0,d.cn)("lg-desktop:mb-3 lg-desktop:h-[195px] relative mb-2 inline-block h-[140px] w-full flex-1 overflow-hidden"),children:(0,s.jsx)("a",{"aria-label":p,target:t?.target,href:(0,R.trackUrlRef)(`${f==="us"||!f?"":`/${f}`}/products/${e?.handle}`,`${T}_${B}`),onClick:()=>{(0,A.gaTrack)({event:"ga4Event",event_name:"select_item",event_parameters:{page_group:"Home Page",item_list_name:"Home_Page_Bundle",items:[{item_id:e?.sku||o?.sku,item_name:e?.name,item_variant:o?.name,price:o?.price,index:t?.index+1}]}})},children:(0,s.jsx)(D.default,{source:_(),alt:"",className:"flex h-full justify-center object-cover [&_img]:w-auto"})})}),y()]})},e?.id||e?.handle)},le=({data:e,configuration:t})=>{const{itemShape:n,itemLength:x,metafields:c}=t||{},{discounts:f}=c||{},{locale:b="us",copyWriting:C}=(0,E.useAiuiContext)(),[w,$]=(0,u.useState)([]),S=(0,u.useRef)(null),I=(l,a,r)=>t?.event?.primaryButton?.(l,a+1,r),P=(l,a,r)=>t?.event?.secondaryButton?.(l,a+1,r),o=e?.variants?.find(l=>l?.sku===e?.sku)||e?.variants?.[0]||{},j=!o?.availableForSale&&o?.price?.amount===G,O=t?.isShowTag,g=t?.isShowOriginalPrice,h=o?.coupons?.[0],{price:H,basePrice:L,discount:m}=(0,F.formatVariantPrice)({locale:b,amount:g&&h?h.variant_price4wscode:o.price,baseAmount:g&&h?o.price:0,currencyCode:e?.price?.currencyCode||"USD"}),_=()=>{const l=e?.sku,a=e?.variants;return a?.find(J=>J?.sku===l)?.image?.url||a?.[0]?.image?.url||""},p=e?.custom_name||e?.title,v=e?.custom_description||e?.description;(0,V.useExposure)(S,{componentType:T,componentName:B,componentTitle:p,componentDescription:v,position:t?.index+1});const y=()=>x>=2?{boxItem:"lg-desktop:max-w-[401px] desktop:max-w-[292px] max-w-full",imgItem:"m-tablet:m-auto lg-desktop:max-w-[330px] lg-desktop:max-h-[330px] desktop:max-w-[260px] desktop:max-h-[260px] max-w-[138px] max-h-[138px]",wrap:"lg-desktop:aspect-w-[824] lg-desktop:aspect-h-[480] desktop:aspect-w-[648] desktop:aspect-h-[380] laptop:aspect-w-[440] laptop:aspect-h-[356] tablet:aspect-w-[346] tablet:aspect-h-[360] md-tablet:w-full"}:{boxItem:"lg-desktop:max-w-[401px] desktop:max-w-[292px] laptop:max-w-[289px] max-w-[262px]",imgItem:"md-tablet:m-auto lg-desktop:max-w-[450px] lg-desktop:max-h-[450px] desktop:max-w-[332px] desktop:max-h-[332px] max-w-[312px] max-h-[312px]",wrap:"lg-desktop:aspect-w-[1664] lg-desktop:aspect-h-[480] desktop:aspect-w-[1312] desktop:aspect-h-[380] laptop:aspect-w-[896] laptop:aspect-h-[356] tablet:aspect-w-[704] tablet:aspect-h-[360] md-tablet:w-full"},i=()=>x>=2?"flex flex-col justify-between desktop:gap-12 desktop:flex-row desktop:justify-center desktop:items-center":"flex justify-center items-center gap-6 md-tablet:flex-col";return(0,u.useEffect)(()=>{let l=[];if(m){const r=`${m}${f?.off||""}`;l.push(r)}const a=e?.tags?.filter?.(r=>r?.startsWith?.("CLtag"))?.map?.(r=>r?.replace?.("CLtag:",""))?.slice?.(0,m?1:2);$(l.concat(a))},[e?.tags,m]),(0,s.jsx)("div",{ref:S,className:(0,d.cn)(y().wrap,n==="round"?"rounded-2xl":"rounded-none","bg-container-secondary-1 tablet:hover:bg-info-white duration-300 gap-6","box-border w-full cursor-pointer overflow-hidden relative md-tablet:h-[360px]"),children:(0,s.jsxs)("div",{className:(0,d.cn)(i(),"desktop:p-6 absolute inset-0 box-border overflow-hidden p-4"),children:[(0,s.jsx)("div",{className:(0,d.cn)(y().imgItem,"relative overflow-hidden desktop:mb-0 mb-1"),children:(0,s.jsx)("a",{"aria-label":p,target:t?.target,href:(0,R.trackUrlRef)(`${b==="us"||!b?"":`/${b}`}/products/${e?.handle}`,`${T}_${B}`),onClick:()=>{(0,A.gaTrack)({event:"ga4Event",event_name:"select_item",event_parameters:{page_group:"Home Page",item_list_name:"Home_Page_Bundle",items:[{item_id:e?.sku||o?.sku,item_name:e?.name,item_variant:o?.name,price:o?.price,index:t?.index+1}]}})},children:(0,s.jsx)(D.default,{source:_(),alt:"",className:"flex h-full justify-center object-cover [&_img]:w-auto"})})}),(0,s.jsxs)("div",{className:(0,d.cn)("flex flex-col justify-center items-start",y().boxItem),children:[O?(0,s.jsx)("div",{className:"mb-1 box-border flex h-8 flex-wrap gap-1 overflow-hidden",children:w?.map?.((l,a)=>(0,s.jsx)(U.default,{children:l},a))}):null,p?(0,s.jsx)(M.Heading,{as:"h3",title:p||"",size:2,className:"shelf-display-product-title mb-1 line-clamp-2",html:p||""}):null,v?(0,s.jsx)(W.Text,{size:2,className:"lg-desktop:text-lg lg-desktop:h-[26px] desktop:text-base desktop:h-6 shelf-display-product-description line-clamp-1 h-5 text-sm",html:v||""}):null,(0,s.jsx)("div",{className:"mb-2 mt-5 flex items-center",children:j?(0,s.jsx)("div",{className:"tablet:text-2xl text-info-primary text-xl font-bold",children:C?.soldOutText}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"final-price tablet:text-2xl text-info-primary text-xl font-bold",children:o?.availableForSale&&H||""}),(0,s.jsx)("div",{className:"origin-price tablet:text-xl text-info-secondary ml-1 text-lg font-bold line-through",children:o?.availableForSale&&L||""})]})}),(0,s.jsxs)("div",{className:(0,d.cn)("shelf-flex-button-group","lg-desktop:gap-3 flex items-center gap-2",t.direction==="vertical"?"flex-col":""),children:[t?.secondaryButton?(0,s.jsx)(k.default,{variant:"secondary",onClick:()=>P(e,t?.index,t),className:`
6
6
  ${t.direction==="vertical"?"w-full":""}
7
- `,children:t?.secondaryButton||""}):null,t?.primaryButton?(0,l.jsx)(b.default,{variant:"primary",onClick:()=>N(e,t?.index,t),className:`
7
+ `,children:t?.secondaryButton||""}):null,t?.primaryButton?(0,s.jsx)(k.default,{variant:"primary",onClick:()=>I(e,t?.index,t),className:`
8
8
  ${t.direction==="vertical"?"w-full":""}
9
9
  `,children:t?.primaryButton||""}):null]})]})]})},e?.id||e?.handle)};
10
10
  //# sourceMappingURL=shelfDisplayItem.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/biz-components/ShelfDisplay/shelfDisplayItem.tsx"],
4
- "sourcesContent": ["import { useAiuiContext } from '../AiuiProvider/index.js'\nimport { formatVariantPrice } from './shelfDisplay.js'\nimport Picture from '../../components/picture.js'\nimport Badge from '../../components/badge.js'\nimport { cn } from '../../helpers/utils.js'\nimport { Text } from '../../components/text.js'\nimport Button from '../../components/button.js'\nimport { gaTrack } from '../../shared/track.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\nimport { Heading } from '../../components/heading.js'\nimport type { ShelfDisplayItem, ShelfDisplayType } from './shelfDisplay.js'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { useRef } from 'react'\n\nconst componentType = 'image'\nconst componentName = 'product_shelf'\n\nconst SOLD_OUT_PRICE = 9999999.99\n\nexport const ShelfDisplayWrapItem = ({ data, configuration }: { data: any; configuration?: any }) => {\n const { isDisplayBackImage = false, itemShape } = configuration || {}\n const { locale = 'us', copyWriting } = useAiuiContext()\n const ref = useRef<HTMLDivElement>(null)\n\n const onPrimaryButton = (params: ShelfDisplayItem, index: number, data: ShelfDisplayType) =>\n configuration?.event?.primaryButton?.(params, index + 1, data)\n\n const onSecondaryButton = (params: ShelfDisplayItem, index: number, data: ShelfDisplayType) =>\n configuration?.event?.secondaryButton?.(params, index + 1, data)\n\n const variant = data?.variants?.find((item: any) => item?.sku === data?.sku) || data?.variants?.[0] || {}\n\n const isSoldOut = !variant?.availableForSale && variant?.price?.amount === SOLD_OUT_PRICE\n const isShowTag = configuration?.isShowTag\n const isShowOriginalPrice = configuration?.isShowOriginalPrice\n\n // active \u7684 \u901A\u7528\u6298\u6263\n const coupon = variant?.coupons?.[0]\n\n const { price, basePrice } = formatVariantPrice({\n locale: locale,\n amount: isShowOriginalPrice && coupon ? coupon.variant_price4wscode : variant.price,\n baseAmount: isShowOriginalPrice && coupon ? variant.price : 0,\n currencyCode: data?.price?.currencyCode || 'USD',\n })\n\n const handleUrl = () => {\n const sku = data?.sku\n const skuArray = data?.variants\n const findSku = skuArray?.find((item: any) => item?.sku === sku)\n return findSku?.image?.url || skuArray?.[0]?.image?.url || ''\n }\n\n const displayTitle = data?.custom_name || data?.title\n const displayDescription = data?.custom_description || data?.description\n\n\n useExposure(ref, {\n componentType,\n componentName,\n componentTitle: displayTitle,\n componentDescription: displayDescription,\n position: configuration?.index + 1,\n })\n\n const bottomContent = () => {\n return (\n <>\n {isShowTag ? (\n <div className=\"mb-1 box-border flex h-8 flex-wrap gap-1 overflow-hidden\">\n {data?.tags\n ?.filter?.((item: any) => item?.startsWith?.('CLtag'))\n ?.map?.((item: any) => item?.replace?.('CLtag:', ''))\n ?.slice?.(0, 2)\n ?.map?.((item: any, index: number) => <Badge key={index}>{item}</Badge>)}\n </div>\n ) : null}\n {displayTitle ? (\n <Heading\n as=\"h3\"\n title={displayTitle || ''}\n size={2}\n className=\"shelf-display-product-title mb-1 line-clamp-2\"\n html={displayTitle || ''}\n />\n ) : null}\n {displayDescription ? (\n <Text\n size={2}\n className=\"lg-desktop:text-lg lg-desktop:h-[26px] desktop:text-base desktop:h-6 shelf-display-product-description line-clamp-1 h-5 text-sm\"\n html={displayDescription || ''}\n />\n ) : null}\n <div className=\"mb-2 mt-5 flex items-center\">\n {isSoldOut ? (\n <div className=\"tablet:text-2xl text-info-primary text-xl font-bold\">{copyWriting?.soldOutText}</div>\n ) : (\n <>\n <div className=\"final-price tablet:text-2xl text-info-primary text-xl font-bold\">\n {variant?.availableForSale ? price || '' : ''}\n </div>\n <div className=\"origin-price tablet:text-xl text-info-secondary ml-1 text-lg font-bold line-through\">\n {variant?.availableForSale ? basePrice || '' : ''}\n </div>\n </>\n )}\n </div>\n {/* \u6309\u94AE\u7EC4 */}\n <div\n className={cn(\n 'shelf-flex-button-group',\n 'lg-desktop:gap-3 flex items-center gap-2',\n configuration.direction === 'vertical' ? 'flex-col' : ''\n )}\n >\n {configuration?.secondaryButton ? (\n <Button\n variant=\"secondary\"\n onClick={() => onSecondaryButton(data, configuration?.index, configuration)}\n className={`\n ${configuration.direction === 'vertical' ? 'w-full' : ''}\n `}\n >\n {configuration?.secondaryButton || ''}\n </Button>\n ) : null}\n {configuration?.primaryButton ? (\n <Button\n variant=\"primary\"\n onClick={() => onPrimaryButton(data, configuration?.index, configuration)}\n className={`\n ${configuration.direction === 'vertical' ? 'w-full' : ''}\n `}\n >\n {configuration?.primaryButton || ''}\n </Button>\n ) : null}\n </div>\n </>\n )\n }\n\n return (\n <div\n ref={ref}\n key={data?.id || data?.handle}\n className={cn(\n 'bg-container-secondary-1 tablet:hover:bg-info-white box-border w-full cursor-pointer overflow-hidden duration-300',\n itemShape === 'round' ? 'rounded-2xl' : 'rounded-none',\n 'lg-desktop:aspect-w-[404] lg-desktop:aspect-h-[480] desktop:aspect-w-[316] desktop:aspect-h-[384]',\n 'laptop:aspect-w-[288] laptop:aspect-h-[360] aspect-w-[296] aspect-h-[360] relative',\n 'md-tablet:h-[360px]'\n )}\n >\n {isDisplayBackImage ? (\n <div className=\"absolute inset-0 box-border overflow-hidden\">\n <div className=\"relative inset-0 size-full\">\n <Picture source={handleUrl()} alt=\"\" className=\"flex h-full justify-center object-cover [&_img]:w-auto\" />\n <div className=\"desktop:p-6 absolute inset-x-0 bottom-0 box-border overflow-hidden p-4\">\n {bottomContent()}\n </div>\n </div>\n </div>\n ) : (\n <div className=\"desktop:p-6 absolute inset-0 box-border flex flex-col justify-between overflow-hidden p-4\">\n <div\n className={cn(\n 'lg-desktop:mb-3 lg-desktop:h-[195px] relative mb-2 inline-block h-[140px] w-full flex-1 overflow-hidden'\n )}\n >\n <a\n aria-label={displayTitle}\n target={configuration?.target}\n href={trackUrlRef(\n `${locale === 'us' || !locale ? '' : `/${locale}`}/products/${data?.handle}`,\n `${componentType}_${componentName}`\n )}\n onClick={() => {\n gaTrack({\n event: 'ga4Event',\n event_name: 'select_item',\n event_parameters: {\n page_group: 'Home Page',\n item_list_name: 'Home_Page_Bundle',\n items: [\n {\n item_id: data?.sku || variant?.sku,\n item_name: data?.name,\n item_variant: variant?.name,\n price: variant?.price,\n index: configuration?.index + 1,\n },\n ],\n },\n })\n }}\n >\n <Picture source={handleUrl()} alt=\"\" className=\"flex h-full justify-center object-cover [&_img]:w-auto\" />\n </a>\n </div>\n {bottomContent()}\n </div>\n )}\n </div>\n )\n}\n\nexport const ShelfDisplayHorizontalItem = ({ data, configuration }: { data: any; configuration?: any }) => {\n const { itemShape, itemLength } = configuration || {}\n const { locale = 'us', copyWriting } = useAiuiContext()\n const ref = useRef<HTMLDivElement>(null)\n\n const onPrimaryButton = (params: ShelfDisplayItem, index: number, data: ShelfDisplayType) =>\n configuration?.event?.primaryButton?.(params, index + 1, data)\n\n const onSecondaryButton = (params: ShelfDisplayItem, index: number, data: ShelfDisplayType) =>\n configuration?.event?.secondaryButton?.(params, index + 1, data)\n\n const variant = data?.variants?.find((item: any) => item?.sku === data?.sku) || data?.variants?.[0] || {}\n\n const isSoldOut = !variant?.availableForSale && variant?.price?.amount === SOLD_OUT_PRICE\n const isShowTag = configuration?.isShowTag\n const isShowOriginalPrice = configuration?.isShowOriginalPrice\n\n // active \u7684 \u901A\u7528\u6298\u6263\n const coupon = variant?.coupons?.[0]\n\n const { price, basePrice } = formatVariantPrice({\n locale: locale,\n amount: isShowOriginalPrice && coupon ? coupon.variant_price4wscode : variant.price,\n baseAmount: isShowOriginalPrice && coupon ? variant.price : 0,\n currencyCode: data?.price?.currencyCode || 'USD',\n })\n\n const handleUrl = () => {\n const sku = data?.sku\n const skuArray = data?.variants\n const findSku = skuArray?.find((item: any) => item?.sku === sku)\n return findSku?.image?.url || skuArray?.[0]?.image?.url || ''\n }\n\n const displayTitle = data?.custom_name || data?.title\n const displayDescription = data?.custom_description || data?.description\n\n useExposure(ref, {\n componentType,\n componentName,\n componentTitle: displayTitle,\n componentDescription: displayDescription,\n position: configuration?.index + 1,\n })\n\n const showSizeClass = (): {\n boxItem: string \n imgItem: string\n wrap: string\n } => {\n if (itemLength >= 2) {\n return {\n boxItem: 'lg-desktop:max-w-[401px] desktop:max-w-[292px] max-w-full',\n imgItem:\n 'm-tablet:m-auto lg-desktop:max-w-[330px] lg-desktop:max-h-[330px] desktop:max-w-[260px] desktop:max-h-[260px] max-w-[138px] max-h-[138px]',\n wrap: 'lg-desktop:aspect-w-[824] lg-desktop:aspect-h-[480] desktop:aspect-w-[648] desktop:aspect-h-[380] laptop:aspect-w-[440] laptop:aspect-h-[356] tablet:aspect-w-[346] tablet:aspect-h-[360] md-tablet:w-full',\n }\n }\n return {\n boxItem: 'lg-desktop:max-w-[401px] desktop:max-w-[292px] laptop:max-w-[289px] max-w-[262px]',\n imgItem:\n 'md-tablet:m-auto lg-desktop:max-w-[450px] lg-desktop:max-h-[450px] desktop:max-w-[332px] desktop:max-h-[332px] max-w-[312px] max-h-[312px]',\n wrap: 'lg-desktop:aspect-w-[1664] lg-desktop:aspect-h-[480] desktop:aspect-w-[1312] desktop:aspect-h-[380] laptop:aspect-w-[896] laptop:aspect-h-[356] tablet:aspect-w-[704] tablet:aspect-h-[360] md-tablet:w-full',\n }\n }\n \n const handleWrapClass = () => {\n if (itemLength >= 2) {\n return 'flex flex-col justify-between desktop:gap-12 desktop:flex-row desktop:justify-center desktop:items-center'\n }\n return 'flex justify-center items-center gap-6 md-tablet:flex-col'\n }\n\n return (\n <div\n ref={ref}\n key={data?.id || data?.handle}\n className={cn(\n showSizeClass().wrap,\n itemShape === 'round' ? 'rounded-2xl' : 'rounded-none',\n 'bg-container-secondary-1 tablet:hover:bg-info-white duration-300 gap-6',\n 'box-border w-full cursor-pointer overflow-hidden relative md-tablet:h-[360px]'\n )}\n >\n <div className={cn(handleWrapClass(), 'desktop:p-6 absolute inset-0 box-border overflow-hidden p-4')}>\n <div className={cn(showSizeClass().imgItem, 'relative overflow-hidden desktop:mb-0 mb-1')}>\n <a\n aria-label={displayTitle}\n target={configuration?.target}\n href={trackUrlRef(\n `${locale === 'us' || !locale ? '' : `/${locale}`}/products/${data?.handle}`,\n `${componentType}_${componentName}`\n )}\n onClick={() => {\n gaTrack({\n event: 'ga4Event',\n event_name: 'select_item',\n event_parameters: {\n page_group: 'Home Page',\n item_list_name: 'Home_Page_Bundle',\n items: [\n {\n item_id: data?.sku || variant?.sku,\n item_name: data?.name,\n item_variant: variant?.name,\n price: variant?.price,\n index: configuration?.index + 1,\n },\n ],\n },\n })\n }}\n >\n <Picture source={handleUrl()} alt=\"\" className=\"flex h-full justify-center object-cover [&_img]:w-auto\" />\n </a>\n </div>\n <div className={cn('flex flex-col justify-center items-start', showSizeClass().boxItem)}>\n {isShowTag ? (\n <div className=\"mb-1 box-border flex h-8 flex-wrap gap-1 overflow-hidden\">\n {data?.tags\n ?.filter?.((item: any) => item?.startsWith?.('CLtag'))\n ?.map?.((item: any) => item?.replace?.('CLtag:', ''))\n ?.slice?.(0, 2)\n ?.map?.((item: any, index: number) => <Badge key={index}>{item}</Badge>)}\n </div>\n ) : null}\n {displayTitle ? (\n <Heading\n as=\"h3\"\n title={displayTitle || ''}\n size={2}\n className=\"shelf-display-product-title mb-1 line-clamp-2\"\n html={displayTitle || ''}\n />\n ) : null}\n {displayDescription ? (\n <Text\n size={2}\n className=\"lg-desktop:text-lg lg-desktop:h-[26px] desktop:text-base desktop:h-6 shelf-display-product-description line-clamp-1 h-5 text-sm\"\n html={displayDescription || ''}\n />\n ) : null}\n <div className=\"mb-2 mt-5 flex items-center\">\n {isSoldOut ? (\n <div className=\"tablet:text-2xl text-info-primary text-xl font-bold\">{copyWriting?.soldOutText}</div>\n ) : (\n <>\n <div className=\"final-price tablet:text-2xl text-info-primary text-xl font-bold\">\n {variant?.availableForSale ? price || '' : ''}\n </div>\n <div className=\"origin-price tablet:text-xl text-info-secondary ml-1 text-lg font-bold line-through\">\n {variant?.availableForSale ? basePrice || '' : ''}\n </div>\n </>\n )}\n </div>\n {/* \u6309\u94AE\u7EC4 */}\n <div\n className={cn(\n 'shelf-flex-button-group',\n 'lg-desktop:gap-3 flex items-center gap-2',\n configuration.direction === 'vertical' ? 'flex-col' : ''\n )}\n >\n {configuration?.secondaryButton ? (\n <Button\n variant=\"secondary\"\n onClick={() => onSecondaryButton(data, configuration?.index, configuration)}\n className={`\n ${configuration.direction === 'vertical' ? 'w-full' : ''}\n `}\n >\n {configuration?.secondaryButton || ''}\n </Button>\n ) : null}\n {configuration?.primaryButton ? (\n <Button\n variant=\"primary\"\n onClick={() => onPrimaryButton(data, configuration?.index, configuration)}\n className={`\n ${configuration.direction === 'vertical' ? 'w-full' : ''}\n `}\n >\n {configuration?.primaryButton || ''}\n </Button>\n ) : null}\n </div>\n </div>\n </div>\n </div>\n )\n}\n"],
5
- "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,gCAAAE,EAAA,yBAAAC,IAAA,eAAAC,EAAAJ,GA0EoD,IAAAK,EAAA,6BA1EpDC,EAA+B,oCAC/BC,EAAmC,6BACnCC,EAAoB,0CACpBC,EAAkB,wCAClBC,EAAmB,kCACnBC,EAAqB,oCACrBC,EAAmB,yCACnBC,EAAwB,iCACxBC,EAA4B,uCAC5BC,EAAwB,uCAExBC,EAA4B,sCAC5BC,EAAuB,iBAEvB,MAAMC,EAAgB,QAChBC,EAAgB,gBAEhBC,EAAiB,aAEVjB,EAAuB,CAAC,CAAE,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BM,GAAS,GACxC,KACA,OAAC,OAAI,UAAU,sFACZ,SAAAN,GAAS,kBAAmBO,GAAa,GAC5C,GACF,EAEJ,KAEA,QAAC,OACC,aAAW,MACT,0BACA,2CACAjB,EAAc,YAAc,WAAa,WAAa,EACxD,EAEC,UAAAA,GAAe,mBACd,OAAC,EAAAyB,QAAA,CACC,QAAQ,YACR,QAAS,IAAMhB,EAAkBV,EAAMC,GAAe,MAAOA,CAAa,EAC1E,UAAW;AAAA,kBACTA,EAAc,YAAc,WAAa,SAAW,EAAE;AAAA,gBAGvD,SAAAA,GAAe,iBAAmB,GACrC,EACE,KACHA,GAAe,iBACd,OAAC,EAAAyB,QAAA,CACC,QAAQ,UACR,QAAS,IAAMnB,EAAgBP,EAAMC,GAAe,MAAOA,CAAa,EACxE,UAAW;AAAA,gBACXA,EAAc,YAAc,WAAa,SAAW,EAAE;AAAA,cAGrD,SAAAA,GAAe,eAAiB,GACnC,EACE,MACN,GACF,GACF,GAhHKD,GAAM,IAAMA,GAAM,MAiHzB,CAEJ",
6
- "names": ["shelfDisplayItem_exports", "__export", "ShelfDisplayHorizontalItem", "ShelfDisplayWrapItem", "__toCommonJS", "import_jsx_runtime", "import_AiuiProvider", "import_shelfDisplay", "import_picture", "import_badge", "import_utils", "import_text", "import_button", "import_track", "import_trackUrlRef", "import_heading", "import_useExposure", "import_react", "componentType", "componentName", "SOLD_OUT_PRICE", "data", "configuration", "isDisplayBackImage", "itemShape", "locale", "copyWriting", "ref", "onPrimaryButton", "params", "index", "onSecondaryButton", "variant", "item", "isSoldOut", "isShowTag", "isShowOriginalPrice", "coupon", "price", "basePrice", "handleUrl", "sku", "skuArray", "displayTitle", "displayDescription", "bottomContent", "Badge", "Button", "Picture", "itemLength", "showSizeClass", "handleWrapClass"]
4
+ "sourcesContent": ["import { useAiuiContext } from '../AiuiProvider/index.js'\nimport { formatVariantPrice } from './shelfDisplay.js'\nimport Picture from '../../components/picture.js'\nimport Badge from '../../components/badge.js'\nimport { cn } from '../../helpers/utils.js'\nimport { Text } from '../../components/text.js'\nimport Button from '../../components/button.js'\nimport { gaTrack } from '../../shared/track.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\nimport { Heading } from '../../components/heading.js'\nimport type { ShelfDisplayItem, ShelfDisplayType } from './shelfDisplay.js'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { useRef, useEffect, useState } from 'react'\n\nconst componentType = 'image'\nconst componentName = 'product_shelf'\n\nconst SOLD_OUT_PRICE = 9999999.99\n\nexport const ShelfDisplayWrapItem = ({ data, configuration }: { data: any; configuration?: any }) => {\n const { isDisplayBackImage = false, itemShape, metafields } = configuration || {}\n const { locale = 'us', copyWriting } = useAiuiContext()\n const { discounts } = metafields || {}\n const ref = useRef<HTMLDivElement>(null)\n const [showTags, setShowTags] = useState<string[]>([])\n\n const onPrimaryButton = (params: ShelfDisplayItem, index: number, data: ShelfDisplayType) =>\n configuration?.event?.primaryButton?.(params, index + 1, data)\n\n const onSecondaryButton = (params: ShelfDisplayItem, index: number, data: ShelfDisplayType) =>\n configuration?.event?.secondaryButton?.(params, index + 1, data)\n\n const variant = data?.variants?.find((item: any) => item?.sku === data?.sku) || data?.variants?.[0] || {}\n\n const isSoldOut = !variant?.availableForSale && variant?.price?.amount === SOLD_OUT_PRICE\n const isShowTag = configuration?.isShowTag\n const isShowOriginalPrice = configuration?.isShowOriginalPrice\n\n // active \u7684 \u901A\u7528\u6298\u6263\n const coupon = variant?.coupons?.[0]\n\n const { price, basePrice, discount } = formatVariantPrice({\n locale: locale,\n amount: isShowOriginalPrice && coupon ? coupon.variant_price4wscode : variant.price,\n baseAmount: isShowOriginalPrice && coupon ? variant.price : 0,\n currencyCode: data?.price?.currencyCode || 'USD',\n })\n\n const handleUrl = () => {\n const sku = data?.sku\n const skuArray = data?.variants\n const findSku = skuArray?.find((item: any) => item?.sku === sku)\n return findSku?.image?.url || skuArray?.[0]?.image?.url || ''\n }\n\n const displayTitle = data?.custom_name || data?.title\n const displayDescription = data?.custom_description || data?.description\n\n // \u5904\u7406\u6807\u7B7E\n useEffect(() => {\n let handleTags: string[] = []\n if (discount) {\n const discountTag = `${discount}${discounts?.off || ''}`\n handleTags.push(discountTag)\n }\n const newTags = data?.tags\n ?.filter?.((item: string) => item?.startsWith?.('CLtag'))\n ?.map?.((item: string) => item?.replace?.('CLtag:', ''))\n ?.slice?.(0, discount ? 1 : 2)\n setShowTags(handleTags.concat(newTags))\n }, [data?.tags, discount])\n\n useExposure(ref, {\n componentType,\n componentName,\n componentTitle: displayTitle,\n componentDescription: displayDescription,\n position: configuration?.index + 1,\n })\n\n const bottomContent = () => {\n return (\n <>\n {isShowTag ? (\n <div className=\"mb-1 box-border flex h-8 flex-wrap gap-1 overflow-hidden\">\n {showTags?.map?.((item: any, index: number) => <Badge key={index}>{item}</Badge>)}\n </div>\n ) : null}\n {displayTitle ? (\n <Heading\n as=\"h3\"\n title={displayTitle || ''}\n size={2}\n className=\"shelf-display-product-title mb-1 line-clamp-2\"\n html={displayTitle || ''}\n />\n ) : null}\n {displayDescription ? (\n <Text\n size={2}\n className=\"lg-desktop:text-lg lg-desktop:h-[26px] desktop:text-base desktop:h-6 shelf-display-product-description line-clamp-1 h-5 text-sm\"\n html={displayDescription || ''}\n />\n ) : null}\n <div className=\"mb-2 mt-5 flex items-center\">\n {isSoldOut ? (\n <div className=\"tablet:text-2xl text-info-primary text-xl font-bold\">{copyWriting?.soldOutText}</div>\n ) : (\n <>\n <div className=\"final-price tablet:text-2xl text-info-primary text-xl font-bold\">\n {variant?.availableForSale ? price || '' : ''}\n </div>\n <div className=\"origin-price tablet:text-xl text-info-secondary ml-1 text-lg font-bold line-through\">\n {variant?.availableForSale ? basePrice || '' : ''}\n </div>\n </>\n )}\n </div>\n {/* \u6309\u94AE\u7EC4 */}\n <div\n className={cn(\n 'shelf-flex-button-group',\n 'lg-desktop:gap-3 flex items-center gap-2',\n configuration.direction === 'vertical' ? 'flex-col' : ''\n )}\n >\n {configuration?.secondaryButton ? (\n <Button\n variant=\"secondary\"\n onClick={() => onSecondaryButton(data, configuration?.index, configuration)}\n className={`\n ${configuration.direction === 'vertical' ? 'w-full' : ''}\n `}\n >\n {configuration?.secondaryButton || ''}\n </Button>\n ) : null}\n {configuration?.primaryButton ? (\n <Button\n variant=\"primary\"\n onClick={() => onPrimaryButton(data, configuration?.index, configuration)}\n className={`\n ${configuration.direction === 'vertical' ? 'w-full' : ''}\n `}\n >\n {configuration?.primaryButton || ''}\n </Button>\n ) : null}\n </div>\n </>\n )\n }\n\n return (\n <div\n ref={ref}\n key={data?.id || data?.handle}\n className={cn(\n 'bg-container-secondary-1 tablet:hover:bg-info-white box-border w-full cursor-pointer overflow-hidden duration-300',\n itemShape === 'round' ? 'rounded-2xl' : 'rounded-none',\n 'lg-desktop:aspect-w-[404] lg-desktop:aspect-h-[480] desktop:aspect-w-[316] desktop:aspect-h-[384]',\n 'laptop:aspect-w-[288] laptop:aspect-h-[360] aspect-w-[296] aspect-h-[360] relative',\n 'md-tablet:h-[360px]'\n )}\n >\n {isDisplayBackImage ? (\n <div className=\"absolute inset-0 box-border overflow-hidden\">\n <div className=\"relative inset-0 size-full\">\n <Picture source={handleUrl()} alt=\"\" className=\"flex h-full justify-center object-cover [&_img]:w-auto\" />\n <div className=\"desktop:p-6 absolute inset-x-0 bottom-0 box-border overflow-hidden p-4\">\n {bottomContent()}\n </div>\n </div>\n </div>\n ) : (\n <div className=\"desktop:p-6 absolute inset-0 box-border flex flex-col justify-between overflow-hidden p-4\">\n <div\n className={cn(\n 'lg-desktop:mb-3 lg-desktop:h-[195px] relative mb-2 inline-block h-[140px] w-full flex-1 overflow-hidden'\n )}\n >\n <a\n aria-label={displayTitle}\n target={configuration?.target}\n href={trackUrlRef(\n `${locale === 'us' || !locale ? '' : `/${locale}`}/products/${data?.handle}`,\n `${componentType}_${componentName}`\n )}\n onClick={() => {\n gaTrack({\n event: 'ga4Event',\n event_name: 'select_item',\n event_parameters: {\n page_group: 'Home Page',\n item_list_name: 'Home_Page_Bundle',\n items: [\n {\n item_id: data?.sku || variant?.sku,\n item_name: data?.name,\n item_variant: variant?.name,\n price: variant?.price,\n index: configuration?.index + 1,\n },\n ],\n },\n })\n }}\n >\n <Picture source={handleUrl()} alt=\"\" className=\"flex h-full justify-center object-cover [&_img]:w-auto\" />\n </a>\n </div>\n {bottomContent()}\n </div>\n )}\n </div>\n )\n}\n\nexport const ShelfDisplayHorizontalItem = ({ data, configuration }: { data: any; configuration?: any }) => {\n const { itemShape, itemLength, metafields } = configuration || {}\n const { discounts } = metafields || {}\n const { locale = 'us', copyWriting } = useAiuiContext()\n const [showTags, setShowTags] = useState<string[]>([])\n const ref = useRef<HTMLDivElement>(null)\n\n const onPrimaryButton = (params: ShelfDisplayItem, index: number, data: ShelfDisplayType) =>\n configuration?.event?.primaryButton?.(params, index + 1, data)\n\n const onSecondaryButton = (params: ShelfDisplayItem, index: number, data: ShelfDisplayType) =>\n configuration?.event?.secondaryButton?.(params, index + 1, data)\n\n const variant = data?.variants?.find((item: any) => item?.sku === data?.sku) || data?.variants?.[0] || {}\n\n const isSoldOut = !variant?.availableForSale && variant?.price?.amount === SOLD_OUT_PRICE\n const isShowTag = configuration?.isShowTag\n const isShowOriginalPrice = configuration?.isShowOriginalPrice\n\n // active \u7684 \u901A\u7528\u6298\u6263\n const coupon = variant?.coupons?.[0]\n\n const { price, basePrice, discount } = formatVariantPrice({\n locale: locale,\n amount: isShowOriginalPrice && coupon ? coupon.variant_price4wscode : variant.price,\n baseAmount: isShowOriginalPrice && coupon ? variant.price : 0,\n currencyCode: data?.price?.currencyCode || 'USD',\n })\n\n const handleUrl = () => {\n const sku = data?.sku\n const skuArray = data?.variants\n const findSku = skuArray?.find((item: any) => item?.sku === sku)\n return findSku?.image?.url || skuArray?.[0]?.image?.url || ''\n }\n\n const displayTitle = data?.custom_name || data?.title\n const displayDescription = data?.custom_description || data?.description\n\n useExposure(ref, {\n componentType,\n componentName,\n componentTitle: displayTitle,\n componentDescription: displayDescription,\n position: configuration?.index + 1,\n })\n\n const showSizeClass = (): {\n boxItem: string\n imgItem: string\n wrap: string\n } => {\n if (itemLength >= 2) {\n return {\n boxItem: 'lg-desktop:max-w-[401px] desktop:max-w-[292px] max-w-full',\n imgItem:\n 'm-tablet:m-auto lg-desktop:max-w-[330px] lg-desktop:max-h-[330px] desktop:max-w-[260px] desktop:max-h-[260px] max-w-[138px] max-h-[138px]',\n wrap: 'lg-desktop:aspect-w-[824] lg-desktop:aspect-h-[480] desktop:aspect-w-[648] desktop:aspect-h-[380] laptop:aspect-w-[440] laptop:aspect-h-[356] tablet:aspect-w-[346] tablet:aspect-h-[360] md-tablet:w-full',\n }\n }\n return {\n boxItem: 'lg-desktop:max-w-[401px] desktop:max-w-[292px] laptop:max-w-[289px] max-w-[262px]',\n imgItem:\n 'md-tablet:m-auto lg-desktop:max-w-[450px] lg-desktop:max-h-[450px] desktop:max-w-[332px] desktop:max-h-[332px] max-w-[312px] max-h-[312px]',\n wrap: 'lg-desktop:aspect-w-[1664] lg-desktop:aspect-h-[480] desktop:aspect-w-[1312] desktop:aspect-h-[380] laptop:aspect-w-[896] laptop:aspect-h-[356] tablet:aspect-w-[704] tablet:aspect-h-[360] md-tablet:w-full',\n }\n }\n\n const handleWrapClass = () => {\n if (itemLength >= 2) {\n return 'flex flex-col justify-between desktop:gap-12 desktop:flex-row desktop:justify-center desktop:items-center'\n }\n return 'flex justify-center items-center gap-6 md-tablet:flex-col'\n }\n\n // \u5904\u7406\u6807\u7B7E\n useEffect(() => {\n let handleTags: string[] = []\n if (discount) {\n const discountTag = `${discount}${discounts?.off || ''}`\n handleTags.push(discountTag)\n }\n const newTags = data?.tags\n ?.filter?.((item: string) => item?.startsWith?.('CLtag'))\n ?.map?.((item: string) => item?.replace?.('CLtag:', ''))\n ?.slice?.(0, discount ? 1 : 2)\n setShowTags(handleTags.concat(newTags))\n }, [data?.tags, discount])\n\n return (\n <div\n ref={ref}\n key={data?.id || data?.handle}\n className={cn(\n showSizeClass().wrap,\n itemShape === 'round' ? 'rounded-2xl' : 'rounded-none',\n 'bg-container-secondary-1 tablet:hover:bg-info-white duration-300 gap-6',\n 'box-border w-full cursor-pointer overflow-hidden relative md-tablet:h-[360px]'\n )}\n >\n <div className={cn(handleWrapClass(), 'desktop:p-6 absolute inset-0 box-border overflow-hidden p-4')}>\n <div className={cn(showSizeClass().imgItem, 'relative overflow-hidden desktop:mb-0 mb-1')}>\n <a\n aria-label={displayTitle}\n target={configuration?.target}\n href={trackUrlRef(\n `${locale === 'us' || !locale ? '' : `/${locale}`}/products/${data?.handle}`,\n `${componentType}_${componentName}`\n )}\n onClick={() => {\n gaTrack({\n event: 'ga4Event',\n event_name: 'select_item',\n event_parameters: {\n page_group: 'Home Page',\n item_list_name: 'Home_Page_Bundle',\n items: [\n {\n item_id: data?.sku || variant?.sku,\n item_name: data?.name,\n item_variant: variant?.name,\n price: variant?.price,\n index: configuration?.index + 1,\n },\n ],\n },\n })\n }}\n >\n <Picture source={handleUrl()} alt=\"\" className=\"flex h-full justify-center object-cover [&_img]:w-auto\" />\n </a>\n </div>\n <div className={cn('flex flex-col justify-center items-start', showSizeClass().boxItem)}>\n {isShowTag ? (\n <div className=\"mb-1 box-border flex h-8 flex-wrap gap-1 overflow-hidden\">\n {showTags?.map?.((item: any, index: number) => <Badge key={index}>{item}</Badge>)}\n </div>\n ) : null}\n {displayTitle ? (\n <Heading\n as=\"h3\"\n title={displayTitle || ''}\n size={2}\n className=\"shelf-display-product-title mb-1 line-clamp-2\"\n html={displayTitle || ''}\n />\n ) : null}\n {displayDescription ? (\n <Text\n size={2}\n className=\"lg-desktop:text-lg lg-desktop:h-[26px] desktop:text-base desktop:h-6 shelf-display-product-description line-clamp-1 h-5 text-sm\"\n html={displayDescription || ''}\n />\n ) : null}\n <div className=\"mb-2 mt-5 flex items-center\">\n {isSoldOut ? (\n <div className=\"tablet:text-2xl text-info-primary text-xl font-bold\">{copyWriting?.soldOutText}</div>\n ) : (\n <>\n <div className=\"final-price tablet:text-2xl text-info-primary text-xl font-bold\">\n {variant?.availableForSale ? price || '' : ''}\n </div>\n <div className=\"origin-price tablet:text-xl text-info-secondary ml-1 text-lg font-bold line-through\">\n {variant?.availableForSale ? basePrice || '' : ''}\n </div>\n </>\n )}\n </div>\n {/* \u6309\u94AE\u7EC4 */}\n <div\n className={cn(\n 'shelf-flex-button-group',\n 'lg-desktop:gap-3 flex items-center gap-2',\n configuration.direction === 'vertical' ? 'flex-col' : ''\n )}\n >\n {configuration?.secondaryButton ? (\n <Button\n variant=\"secondary\"\n onClick={() => onSecondaryButton(data, configuration?.index, configuration)}\n className={`\n ${configuration.direction === 'vertical' ? 'w-full' : ''}\n `}\n >\n {configuration?.secondaryButton || ''}\n </Button>\n ) : null}\n {configuration?.primaryButton ? (\n <Button\n variant=\"primary\"\n onClick={() => onPrimaryButton(data, configuration?.index, configuration)}\n className={`\n ${configuration.direction === 'vertical' ? 'w-full' : ''}\n `}\n >\n {configuration?.primaryButton || ''}\n </Button>\n ) : null}\n </div>\n </div>\n </div>\n </div>\n )\n}\n"],
5
+ "mappings": "4jBAAA,IAAAA,GAAA,GAAAC,GAAAD,GAAA,gCAAAE,GAAA,yBAAAC,KAAA,eAAAC,GAAAJ,IAqF2D,IAAAK,EAAA,6BArF3DC,EAA+B,oCAC/BC,EAAmC,6BACnCC,EAAoB,0CACpBC,EAAkB,wCAClBC,EAAmB,kCACnBC,EAAqB,oCACrBC,EAAmB,yCACnBC,EAAwB,iCACxBC,EAA4B,uCAC5BC,EAAwB,uCAExBC,EAA4B,sCAC5BC,EAA4C,iBAE5C,MAAMC,EAAgB,QAChBC,EAAgB,gBAEhBC,EAAiB,aAEVjB,GAAuB,CAAC,CAAE,KAAAkB,EAAM,cAAAC,CAAc,IAA0C,CACnG,KAAM,CAAE,mBAAAC,EAAqB,GAAO,UAAAC,EAAW,WAAAC,CAAW,EAAIH,GAAiB,CAAC,EAC1E,CAAE,OAAAI,EAAS,KAAM,YAAAC,CAAY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,GAAe,eAAiB,GACnC,EACE,MACN,GACF,GACF,GA5GKD,GAAM,IAAMA,GAAM,MA6GzB,CAEJ",
6
+ "names": ["shelfDisplayItem_exports", "__export", "ShelfDisplayHorizontalItem", "ShelfDisplayWrapItem", "__toCommonJS", "import_jsx_runtime", "import_AiuiProvider", "import_shelfDisplay", "import_picture", "import_badge", "import_utils", "import_text", "import_button", "import_track", "import_trackUrlRef", "import_heading", "import_useExposure", "import_react", "componentType", "componentName", "SOLD_OUT_PRICE", "data", "configuration", "isDisplayBackImage", "itemShape", "metafields", "locale", "copyWriting", "discounts", "ref", "showTags", "setShowTags", "onPrimaryButton", "params", "index", "onSecondaryButton", "variant", "item", "isSoldOut", "isShowTag", "isShowOriginalPrice", "coupon", "price", "basePrice", "discount", "handleUrl", "sku", "skuArray", "displayTitle", "displayDescription", "handleTags", "discountTag", "newTags", "bottomContent", "Badge", "Button", "Picture", "itemLength", "showSizeClass", "handleWrapClass"]
7
7
  }
@@ -0,0 +1,9 @@
1
+ import 'swiper/css';
2
+ import 'swiper/css/pagination';
3
+ declare const _default: import("react").ForwardRefExoticComponent<Omit<{
4
+ data: any;
5
+ }, keyof import("../../shared/Styles.js").StylesProps> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & {
6
+ className?: string;
7
+ data?: Record<string, any>;
8
+ } & import("react").RefAttributes<any>>;
9
+ export default _default;
@@ -0,0 +1,2 @@
1
+ "use strict";var w=Object.create;var r=Object.defineProperty;var c=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var f=Object.getPrototypeOf,v=Object.prototype.hasOwnProperty;var x=(s,e)=>{for(var t in e)r(s,t,{get:e[t],enumerable:!0})},d=(s,e,t,l)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of u(e))!v.call(s,i)&&i!==t&&r(s,i,{get:()=>e[i],enumerable:!(l=c(e,i))||l.enumerable});return s};var b=(s,e,t)=>(t=s!=null?w(f(s)):{},d(e||!s||!s.__esModule?r(t,"default",{value:s,enumerable:!0}):t,s)),h=s=>d(r({},"__esModule",{value:!0}),s);var P={};x(P,{default:()=>N});module.exports=h(P);var a=require("react/jsx-runtime"),o=require("swiper/react"),p=b(require("../../components/picture.js")),m=require("../../shared/Styles.js"),n=require("swiper/modules"),V=require("swiper/css"),g=require("swiper/css/pagination");const y=({data:s})=>{const{items:e}=s;return(0,a.jsxs)("div",{className:"overflow-hidden relative w-full",children:[(0,a.jsx)("div",{className:"absolute inset-0 size-full bg-transparent z-10"}),(0,a.jsx)(o.Swiper,{className:"overflow-hidden",slidesPerView:"auto",speed:7e3,loop:!0,autoplay:{delay:0,disableOnInteraction:!0},wrapperClass:"!ease-linear",modules:[n.FreeMode,n.Autoplay],breakpoints:{0:{spaceBetween:24,slidesPerView:1.6},768:{spaceBetween:24,slidesPerView:3.1},1024:{spaceBetween:128,slidesPerView:3},1440:{spaceBetween:128,slidesPerView:4},1920:{spaceBetween:128,slidesPerView:e?.length>=5?5:4}},children:(e?.length>3?[...e||[],...e||[]]:e)?.map?.((t,l)=>(0,a.jsx)(o.SwiperSlide,{className:"!h-[unset]",children:(0,a.jsxs)("div",{className:"flex w-full flex-1 items-center gap-1 overflow-hidden min-md:gap-2",children:[(0,a.jsx)(p.default,{source:t.icon?.url||t.icon,className:"size-6"}),(0,a.jsx)("span",{title:t.text||"",className:"flex-1 truncate text-base md-tablet:text-sm font-semibold text-[#1D1D1F]",children:t.text})]})},l))})]})};var N=(0,m.withLayout)(y);
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../src/biz-components/TextMarquee/index.tsx"],
4
+ "sourcesContent": ["import { Swiper, SwiperSlide } from 'swiper/react'\nimport Picture from '../../components/picture.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport { FreeMode, Autoplay } from 'swiper/modules'\nimport 'swiper/css'\nimport 'swiper/css/pagination'\n\nconst TextMarquee = ({ data }: { data: any }) => {\n const { items } = data\n\n return (\n <div className=\"overflow-hidden relative w-full\">\n <div className=\"absolute inset-0 size-full bg-transparent z-10\" />\n <Swiper\n className=\"overflow-hidden\"\n slidesPerView=\"auto\"\n speed={7000}\n loop={true}\n autoplay={{\n delay: 0,\n disableOnInteraction: true,\n }}\n wrapperClass=\"!ease-linear\"\n modules={[FreeMode, Autoplay]}\n breakpoints={{\n 0: {\n spaceBetween: 24,\n slidesPerView: 1.6,\n },\n 768: {\n spaceBetween: 24,\n slidesPerView: 3.1,\n },\n 1024: {\n spaceBetween: 128,\n slidesPerView: 3,\n },\n 1440: {\n spaceBetween: 128,\n slidesPerView: 4,\n },\n 1920: {\n spaceBetween: 128,\n slidesPerView: items?.length >= 5 ? 5 : 4,\n },\n }}\n >\n {(items?.length > 3 ? [...(items || []), ...(items || [])] : items)?.map?.((item: any, index: number) => (\n <SwiperSlide key={index} className=\"!h-[unset]\">\n <div className=\"flex w-full flex-1 items-center gap-1 overflow-hidden min-md:gap-2\">\n <Picture source={item.icon?.url || item.icon} className=\"size-6\" />\n <span title={item.text || ''} className=\"flex-1 truncate text-base md-tablet:text-sm font-semibold text-[#1D1D1F]\">\n {item.text}\n </span>\n </div>\n </SwiperSlide>\n ))}\n </Swiper>\n </div>\n )\n}\n\nexport default withLayout(TextMarquee)\n"],
5
+ "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GAYM,IAAAI,EAAA,6BAZNC,EAAoC,wBACpCC,EAAoB,0CACpBC,EAA2B,kCAC3BC,EAAmC,0BACnCC,EAAO,sBACPC,EAAO,iCAEP,MAAMC,EAAc,CAAC,CAAE,KAAAC,CAAK,IAAqB,CAC/C,KAAM,CAAE,MAAAC,CAAM,EAAID,EAElB,SACE,QAAC,OAAI,UAAU,kCACb,oBAAC,OAAI,UAAU,iDAAiD,KAChE,OAAC,UACC,UAAU,kBACV,cAAc,OACd,MAAO,IACP,KAAM,GACN,SAAU,CACR,MAAO,EACP,qBAAsB,EACxB,EACA,aAAa,eACb,QAAS,CAAC,WAAU,UAAQ,EAC5B,YAAa,CACX,EAAG,CACD,aAAc,GACd,cAAe,GACjB,EACA,IAAK,CACH,aAAc,GACd,cAAe,GACjB,EACA,KAAM,CACJ,aAAc,IACd,cAAe,CACjB,EACA,KAAM,CACJ,aAAc,IACd,cAAe,CACjB,EACA,KAAM,CACJ,aAAc,IACd,cAAeC,GAAO,QAAU,EAAI,EAAI,CAC1C,CACF,EAEE,UAAAA,GAAO,OAAS,EAAI,CAAC,GAAIA,GAAS,CAAC,EAAI,GAAIA,GAAS,CAAC,CAAE,EAAIA,IAAQ,MAAM,CAACC,EAAWC,OACrF,OAAC,eAAwB,UAAU,aACjC,oBAAC,OAAI,UAAU,qEACb,oBAAC,EAAAC,QAAA,CAAQ,OAAQF,EAAK,MAAM,KAAOA,EAAK,KAAM,UAAU,SAAS,KACjE,OAAC,QAAK,MAAOA,EAAK,MAAQ,GAAI,UAAU,2EACrC,SAAAA,EAAK,KACR,GACF,GANgBC,CAOlB,CACD,EACH,GACF,CAEJ,EAEA,IAAOb,KAAQ,cAAWS,CAAW",
6
+ "names": ["TextMarquee_exports", "__export", "TextMarquee_default", "__toCommonJS", "import_jsx_runtime", "import_react", "import_picture", "import_Styles", "import_modules", "import_css", "import_pagination", "TextMarquee", "data", "items", "item", "index", "Picture"]
7
+ }
@@ -1,2 +1,2 @@
1
- "use strict";"use client";var A=Object.create;var m=Object.defineProperty;var G=Object.getOwnPropertyDescriptor;var J=Object.getOwnPropertyNames;var K=Object.getPrototypeOf,Q=Object.prototype.hasOwnProperty;var W=(t,e)=>{for(var n in e)m(t,n,{get:e[n],enumerable:!0})},E=(t,e,n,c)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of J(e))!Q.call(t,o)&&o!==n&&m(t,o,{get:()=>e[o],enumerable:!(c=G(e,o))||c.enumerable});return t};var X=(t,e,n)=>(n=t!=null?A(K(t)):{},E(e||!t||!t.__esModule?m(n,"default",{value:t,enumerable:!0}):n,t)),Y=t=>E(m({},"__esModule",{value:!0}),t);var tt={};W(tt,{default:()=>Z});module.exports=Y(tt);var i=require("react/jsx-runtime"),r=X(require("react")),u=require("gsap"),w=require("gsap/dist/SplitText"),v=require("gsap/dist/ScrollTrigger"),x=require("../../helpers/utils.js"),$=require("../../components/index.js"),D=require("../../shared/Styles.js"),rt=require("../../hooks/useExposure.js"),P=require("../../shared/trackUrlRef.js"),S=require("react-intersection-observer");const H="link",M="title",N=r.default.forwardRef(({data:t,className:e,as:n="h2"},c)=>{const{title:o,caption:p,theme:T,extensions:f}=t,k=(0,r.useRef)(null),l=(0,r.useRef)(null),s=(0,r.useRef)(null),a=(0,r.useRef)(null),{ref:z,inView:y}=(0,S.useInView)();return(0,r.useImperativeHandle)(c,()=>k.current),(0,r.useEffect)(()=>{u.gsap.registerPlugin(w.SplitText,v.ScrollTrigger);function I(){if(!l.current)return;const V=l.current?.clientHeight||80;s.current&&s.current.revert(),a.current&&a.current.kill(),s.current=new w.SplitText(l.current,{type:"words",wordsClass:"word"});const d=s.current.words;u.gsap.set(d,{opacity:0}),a.current=v.ScrollTrigger.create({trigger:l.current,start:"bottom bottom-=4%",end:`bottom+=${V*1.5+60}px bottom-=4%`,scrub:!0,invalidateOnRefresh:!0,onUpdate:U=>{const j=U.progress,b=d.length||1,B=.5,g=1/b,R=g*(1-B),L=(b-1)*R+g,C=Math.min(1,L>0?j/L:0);d.forEach((F,O)=>{const _=O*R,q=g;let h=(C-_)/q;h=Math.max(0,Math.min(1,h)),u.gsap.set(F,{opacity:h})})}})}return y&&I(),()=>{s.current&&s.current.revert(),a.current&&a.current.kill()}},[y]),(o||p)&&(0,i.jsxs)("div",{className:"mb-6 flex items-end justify-between overflow-hidden title-box",ref:k,children:[(0,i.jsx)("div",{ref:z,className:(0,x.cn)("space-y-4 flex-1",e,{"aiui-dark":T==="dark"}),children:(0,i.jsx)($.Heading,{ref:l,as:n,size:4,html:p||o})}),f?.textLink&&(0,i.jsxs)("a",{className:(0,x.cn)({"aiui-dark":T==="dark"},"flex items-center text-base font-[700] leading-[1.4] text-[#777] transition-all duration-[0.4s] hover:text-[#1D1D1F]"),href:(0,P.trackUrlRef)(f?.link,`${H}_${M}`),"data-headless-type-name":`${H}#${M}`,"data-headless-title-desc-button":`${o}#${p}`,children:[f?.textLink,(0,i.jsx)("svg",{width:"24",height:"24",className:"mb-[3px]",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:(0,i.jsx)("path",{className:"transition-all duration-[0.4s]",d:"M10.5 8L14.5 12L10.5 16",stroke:"#777","stroke-width":"1.5","stroke-linecap":"round"})})]})]})});N.displayName="Title";var Z=(0,D.withLayout)(N);
1
+ "use strict";"use client";var G=Object.create;var m=Object.defineProperty;var J=Object.getOwnPropertyDescriptor;var K=Object.getOwnPropertyNames;var Q=Object.getPrototypeOf,W=Object.prototype.hasOwnProperty;var X=(t,e)=>{for(var n in e)m(t,n,{get:e[n],enumerable:!0})},H=(t,e,n,c)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of K(e))!W.call(t,i)&&i!==n&&m(t,i,{get:()=>e[i],enumerable:!(c=J(e,i))||c.enumerable});return t};var Y=(t,e,n)=>(n=t!=null?G(Q(t)):{},H(e||!t||!t.__esModule?m(n,"default",{value:t,enumerable:!0}):n,t)),Z=t=>H(m({},"__esModule",{value:!0}),t);var et={};X(et,{default:()=>tt});module.exports=Z(et);var o=require("react/jsx-runtime"),r=Y(require("react")),u=require("gsap"),v=require("gsap/dist/SplitText"),x=require("gsap/dist/ScrollTrigger"),T=require("../../helpers/utils.js"),D=require("../../components/index.js"),P=require("../../shared/Styles.js"),nt=require("../../hooks/useExposure.js"),S=require("../../shared/trackUrlRef.js"),z=require("react-intersection-observer");const M="link",N="title",$=r.default.forwardRef(({data:t,className:e,as:n="h2",weight:c="bold"},i)=>{const{title:p,caption:d,theme:k,extensions:f}=t,b=(0,r.useRef)(null),l=(0,r.useRef)(null),s=(0,r.useRef)(null),a=(0,r.useRef)(null),{ref:I,inView:y}=(0,z.useInView)();return(0,r.useImperativeHandle)(i,()=>b.current),(0,r.useEffect)(()=>{u.gsap.registerPlugin(v.SplitText,x.ScrollTrigger);function V(){if(!l.current)return;const U=l.current?.clientHeight||80;s.current&&s.current.revert(),a.current&&a.current.kill(),s.current=new v.SplitText(l.current,{type:"words",wordsClass:"word"});const g=s.current.words;u.gsap.set(g,{opacity:0}),a.current=x.ScrollTrigger.create({trigger:l.current,start:"bottom bottom-=4%",end:`bottom+=${U*1.5+60}px bottom-=4%`,scrub:!0,invalidateOnRefresh:!0,onUpdate:j=>{const B=j.progress,R=g.length||1,C=.5,h=1/R,L=h*(1-C),E=(R-1)*L+h,F=Math.min(1,E>0?B/E:0);g.forEach((O,_)=>{const q=_*L,A=h;let w=(F-q)/A;w=Math.max(0,Math.min(1,w)),u.gsap.set(O,{opacity:w})})}})}return y&&V(),()=>{s.current&&s.current.revert(),a.current&&a.current.kill()}},[y]),(p||d)&&(0,o.jsxs)("div",{className:"mb-6 flex items-end justify-between overflow-hidden title-box",ref:b,children:[(0,o.jsx)("div",{ref:I,className:(0,T.cn)("space-y-4 flex-1",e,{"aiui-dark":k==="dark"}),children:(0,o.jsx)(D.Heading,{ref:l,as:n,size:4,html:d||p,weight:c})}),f?.textLink&&(0,o.jsxs)("a",{className:(0,T.cn)({"aiui-dark":k==="dark"},"flex items-center text-base font-[700] leading-[1.4] text-[#777] transition-all duration-[0.4s] hover:text-[#1D1D1F]"),href:(0,S.trackUrlRef)(f?.link,`${M}_${N}`),"data-headless-type-name":`${M}#${N}`,"data-headless-title-desc-button":`${p}#${d}`,children:[f?.textLink,(0,o.jsx)("svg",{width:"24",height:"24",className:"mb-[3px]",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",children:(0,o.jsx)("path",{className:"transition-all duration-[0.4s]",d:"M10.5 8L14.5 12L10.5 16",stroke:"#777","stroke-width":"1.5","stroke-linecap":"round"})})]})]})});$.displayName="Title";var tt=(0,P.withLayout)($);
2
2
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/biz-components/Title/index.tsx"],
4
- "sourcesContent": ["'use client'\nimport React, { useEffect, useRef, useImperativeHandle } from 'react'\nimport { gsap } from 'gsap'\nimport { SplitText } from 'gsap/dist/SplitText'\nimport { ScrollTrigger } from 'gsap/dist/ScrollTrigger'\nimport { cn } from '../../helpers/utils.js'\nimport { Heading } from '../../components/index.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport type { TitleProps } from './types.js'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\nimport { useInView } from 'react-intersection-observer'\n\nconst componentType = 'link'\nconst componentName = 'title'\n\nconst Title = React.forwardRef<HTMLDivElement, TitleProps>(({ data, className, as = 'h2' }, ref) => {\n const { title, caption, theme, extensions } = data\n const innerRef = useRef<HTMLDivElement>(null)\n const titleRef = useRef<HTMLHeadingElement>(null)\n const splitTextInstance = useRef<SplitText | null>(null)\n const scrollTriggerRef = useRef<ScrollTrigger | null>(null)\n\n const { ref: inViewRef, inView } = useInView()\n\n useImperativeHandle(ref, () => innerRef.current as HTMLDivElement)\n\n\n useEffect(() => {\n gsap.registerPlugin(SplitText, ScrollTrigger)\n function gsapResize() {\n if (!titleRef.current) return\n const height = titleRef.current?.clientHeight || 80\n if (splitTextInstance.current) {\n splitTextInstance.current.revert()\n }\n if (scrollTriggerRef.current) {\n scrollTriggerRef.current.kill()\n }\n splitTextInstance.current = new SplitText(titleRef.current, {\n type: 'words',\n wordsClass: 'word',\n })\n const words = splitTextInstance.current.words\n gsap.set(words, { opacity: 0 })\n scrollTriggerRef.current = ScrollTrigger.create({\n trigger: titleRef.current,\n start: 'bottom bottom-=4%',\n end: `bottom+=${height * 1.5 + 60}px bottom-=4%`,\n scrub: true,\n invalidateOnRefresh: true,\n onUpdate: (self: any) => {\n const progress = self.progress\n const total = words.length || 1\n const overlap = 0.5\n const interval = 1 / total\n const step = interval * (1 - overlap)\n const lastEnd = (total - 1) * step + interval\n const normalizedProgress = Math.min(1, lastEnd > 0 ? progress / lastEnd : 0)\n words.forEach((word: any, i: number) => {\n const start = i * step\n const width = interval\n let opacity = (normalizedProgress - start) / width\n opacity = Math.max(0, Math.min(1, opacity))\n gsap.set(word, { opacity })\n })\n },\n })\n }\n\n if (inView) {\n gsapResize()\n }\n\n return () => {\n splitTextInstance.current && splitTextInstance.current.revert()\n // ScrollTrigger.getAll().forEach((t: { kill: () => any }) => t.kill())\n scrollTriggerRef.current && scrollTriggerRef.current.kill()\n }\n }, [inView])\n\n return (\n (title || caption) && (\n <div className=\"mb-6 flex items-end justify-between overflow-hidden title-box\" ref={innerRef}>\n <div ref={inViewRef} className={cn('space-y-4 flex-1', className, { 'aiui-dark': theme === 'dark' })}>\n <Heading ref={titleRef} as={as} size={4} html={caption || title} />\n </div>\n {extensions?.textLink && (\n <a\n className={cn(\n { 'aiui-dark': theme === 'dark' },\n 'flex items-center text-base font-[700] leading-[1.4] text-[#777] transition-all duration-[0.4s] hover:text-[#1D1D1F]'\n )}\n href={trackUrlRef(extensions?.link, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${title}#${caption}`}\n >\n {extensions?.textLink}\n <svg\n width=\"24\"\n height=\"24\"\n className=\"mb-[3px]\"\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n >\n <path\n className=\"transition-all duration-[0.4s]\"\n d=\"M10.5 8L14.5 12L10.5 16\"\n stroke=\"#777\"\n stroke-width=\"1.5\"\n stroke-linecap=\"round\"\n ></path>\n </svg>\n </a>\n )}\n </div>\n )\n )\n})\n\nTitle.displayName = 'Title'\n\nexport default withLayout(Title)\n"],
5
- "mappings": "ukBAAA,IAAAA,GAAA,GAAAC,EAAAD,GAAA,aAAAE,IAAA,eAAAC,EAA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M,YAAc,QAEpB,IAAOf,KAAQ,cAAWe,CAAK",
6
- "names": ["Title_exports", "__export", "Title_default", "__toCommonJS", "import_jsx_runtime", "import_react", "import_gsap", "import_SplitText", "import_ScrollTrigger", "import_utils", "import_components", "import_Styles", "import_useExposure", "import_trackUrlRef", "import_react_intersection_observer", "componentType", "componentName", "Title", "React", "data", "className", "as", "ref", "title", "caption", "theme", "extensions", "innerRef", "titleRef", "splitTextInstance", "scrollTriggerRef", "inViewRef", "inView", "gsapResize", "height", "words", "self", "progress", "total", "overlap", "interval", "step", "lastEnd", "normalizedProgress", "word", "i", "start", "width", "opacity"]
4
+ "sourcesContent": ["'use client'\nimport React, { useEffect, useRef, useImperativeHandle } from 'react'\nimport { gsap } from 'gsap'\nimport { SplitText } from 'gsap/dist/SplitText'\nimport { ScrollTrigger } from 'gsap/dist/ScrollTrigger'\nimport { cn } from '../../helpers/utils.js'\nimport { Heading } from '../../components/index.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport type { TitleProps } from './types.js'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\nimport { useInView } from 'react-intersection-observer'\n\nconst componentType = 'link'\nconst componentName = 'title'\n\nconst Title = React.forwardRef<HTMLDivElement, TitleProps>(({ data, className, as = 'h2', weight = 'bold' }, ref) => {\n const { title, caption, theme, extensions } = data\n const innerRef = useRef<HTMLDivElement>(null)\n const titleRef = useRef<HTMLHeadingElement>(null)\n const splitTextInstance = useRef<SplitText | null>(null)\n const scrollTriggerRef = useRef<ScrollTrigger | null>(null)\n\n const { ref: inViewRef, inView } = useInView()\n\n useImperativeHandle(ref, () => innerRef.current as HTMLDivElement)\n\n\n useEffect(() => {\n gsap.registerPlugin(SplitText, ScrollTrigger)\n function gsapResize() {\n if (!titleRef.current) return\n const height = titleRef.current?.clientHeight || 80\n if (splitTextInstance.current) {\n splitTextInstance.current.revert()\n }\n if (scrollTriggerRef.current) {\n scrollTriggerRef.current.kill()\n }\n splitTextInstance.current = new SplitText(titleRef.current, {\n type: 'words',\n wordsClass: 'word',\n })\n const words = splitTextInstance.current.words\n gsap.set(words, { opacity: 0 })\n scrollTriggerRef.current = ScrollTrigger.create({\n trigger: titleRef.current,\n start: 'bottom bottom-=4%',\n end: `bottom+=${height * 1.5 + 60}px bottom-=4%`,\n scrub: true,\n invalidateOnRefresh: true,\n onUpdate: (self: any) => {\n const progress = self.progress\n const total = words.length || 1\n const overlap = 0.5\n const interval = 1 / total\n const step = interval * (1 - overlap)\n const lastEnd = (total - 1) * step + interval\n const normalizedProgress = Math.min(1, lastEnd > 0 ? progress / lastEnd : 0)\n words.forEach((word: any, i: number) => {\n const start = i * step\n const width = interval\n let opacity = (normalizedProgress - start) / width\n opacity = Math.max(0, Math.min(1, opacity))\n gsap.set(word, { opacity })\n })\n },\n })\n }\n\n if (inView) {\n gsapResize()\n }\n\n return () => {\n splitTextInstance.current && splitTextInstance.current.revert()\n // ScrollTrigger.getAll().forEach((t: { kill: () => any }) => t.kill())\n scrollTriggerRef.current && scrollTriggerRef.current.kill()\n }\n }, [inView])\n\n return (\n (title || caption) && (\n <div className=\"mb-6 flex items-end justify-between overflow-hidden title-box\" ref={innerRef}>\n <div ref={inViewRef} className={cn('space-y-4 flex-1', className, { 'aiui-dark': theme === 'dark' })}>\n <Heading ref={titleRef} as={as} size={4} html={caption || title} weight={weight} />\n </div>\n {extensions?.textLink && (\n <a\n className={cn(\n { 'aiui-dark': theme === 'dark' },\n 'flex items-center text-base font-[700] leading-[1.4] text-[#777] transition-all duration-[0.4s] hover:text-[#1D1D1F]'\n )}\n href={trackUrlRef(extensions?.link, `${componentType}_${componentName}`)}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${title}#${caption}`}\n >\n {extensions?.textLink}\n <svg\n width=\"24\"\n height=\"24\"\n className=\"mb-[3px]\"\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n >\n <path\n className=\"transition-all duration-[0.4s]\"\n d=\"M10.5 8L14.5 12L10.5 16\"\n stroke=\"#777\"\n stroke-width=\"1.5\"\n stroke-linecap=\"round\"\n ></path>\n </svg>\n </a>\n )}\n </div>\n )\n )\n})\n\nTitle.displayName = 'Title'\n\nexport default withLayout(Title)\n"],
5
+ "mappings": "ukBAAA,IAAAA,GAAA,GAAAC,EAAAD,GAAA,aAAAE,KAAA,eAAAC,EAAAH,IAqFU,IAAAI,EAAA,6BApFVC,EAA8D,oBAC9DC,EAAqB,gBACrBC,EAA0B,+BAC1BC,EAA8B,mCAC9BC,EAAmB,kCACnBC,EAAwB,qCACxBC,EAA2B,kCAE3BC,GAA4B,sCAC5BC,EAA4B,uCAC5BC,EAA0B,uCAE1B,MAAMC,EAAgB,OAChBC,EAAgB,QAEhBC,EAAQ,EAAAC,QAAM,WAAuC,CAAC,CAAE,KAAAC,EAAM,UAAAC,EAAW,GAAAC,EAAK,KAAM,OAAAC,EAAS,MAAO,EAAGC,IAAQ,CACnH,KAAM,CAAE,MAAAC,EAAO,QAAAC,EAAS,MAAAC,EAAO,WAAAC,CAAW,EAAIR,EACxCS,KAAW,UAAuB,IAAI,EACtCC,KAAW,UAA2B,IAAI,EAC1CC,KAAoB,UAAyB,IAAI,EACjDC,KAAmB,UAA6B,IAAI,EAEpD,CAAE,IAAKC,EAAW,OAAAC,CAAO,KAAI,aAAU,EAE7C,gCAAoBV,EAAK,IAAMK,EAAS,OAAyB,KAGjE,aAAU,IAAM,CACd,OAAK,eAAe,YAAW,eAAa,EAC5C,SAASM,GAAa,CACpB,GAAI,CAACL,EAAS,QAAS,OACvB,MAAMM,EAASN,EAAS,SAAS,cAAgB,GAC7CC,EAAkB,SACpBA,EAAkB,QAAQ,OAAO,EAE/BC,EAAiB,SACnBA,EAAiB,QAAQ,KAAK,EAEhCD,EAAkB,QAAU,IAAI,YAAUD,EAAS,QAAS,CAC1D,KAAM,QACN,WAAY,MACd,CAAC,EACD,MAAMO,EAAQN,EAAkB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AE,EACvE,0BAAyB,GAAGD,CAAa,IAAIC,CAAa,GAC1D,kCAAiC,GAAGQ,CAAK,IAAIC,CAAO,GAEnD,UAAAE,GAAY,YACb,OAAC,OACC,MAAM,KACN,OAAO,KACP,UAAU,WACV,MAAM,6BACN,QAAQ,YACR,KAAK,OAEL,mBAAC,QACC,UAAU,iCACV,EAAE,0BACF,OAAO,OACP,eAAa,MACb,iBAAe,QAChB,EACH,GACF,GAEJ,CAGN,CAAC,EAEDV,EAAM,YAAc,QAEpB,IAAOf,MAAQ,cAAWe,CAAK",
6
+ "names": ["Title_exports", "__export", "Title_default", "__toCommonJS", "import_jsx_runtime", "import_react", "import_gsap", "import_SplitText", "import_ScrollTrigger", "import_utils", "import_components", "import_Styles", "import_useExposure", "import_trackUrlRef", "import_react_intersection_observer", "componentType", "componentName", "Title", "React", "data", "className", "as", "weight", "ref", "title", "caption", "theme", "extensions", "innerRef", "titleRef", "splitTextInstance", "scrollTriggerRef", "inViewRef", "inView", "gsapResize", "height", "words", "self", "progress", "total", "overlap", "interval", "step", "lastEnd", "normalizedProgress", "word", "i", "start", "width", "opacity"]
7
7
  }
@@ -30,4 +30,5 @@ export interface TitleProps {
30
30
  */
31
31
  className?: string;
32
32
  as?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
33
+ weight?: 'bold' | 'medium' | 'semibold' | 'extraBold' | 'black';
33
34
  }
@@ -1,2 +1,2 @@
1
- "use strict";var a=Object.defineProperty;var n=Object.getOwnPropertyDescriptor;var h=Object.getOwnPropertyNames;var p=Object.prototype.hasOwnProperty;var o=(t,e,i,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of h(e))!p.call(t,r)&&r!==i&&a(t,r,{get:()=>e[r],enumerable:!(s=n(e,r))||s.enumerable});return t};var m=t=>o(a({},"__esModule",{value:!0}),t);var c={};module.exports=m(c);
1
+ "use strict";var s=Object.defineProperty;var o=Object.getOwnPropertyDescriptor;var h=Object.getOwnPropertyNames;var n=Object.prototype.hasOwnProperty;var m=(t,e,a,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of h(e))!n.call(t,r)&&r!==a&&s(t,r,{get:()=>e[r],enumerable:!(i=o(e,r))||i.enumerable});return t};var p=t=>m(s({},"__esModule",{value:!0}),t);var l={};module.exports=p(l);
2
2
  //# sourceMappingURL=types.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/biz-components/Title/types.ts"],
4
- "sourcesContent": ["import type { Theme } from '../../types/props.js'\n\nexport interface Feature {\n /**\n * \u7279\u6027\u6807\u9898\n */\n title: string\n}\n\nexport interface TitleProps {\n data: {\n /**\n * \u4E3B\u6807\u9898\n */\n title?: string\n caption?: string\n /**\n * \u7279\u6027\u5217\u8868\uFF0C\u6700\u591A\u652F\u63013\u4E2A\n */\n features?: Feature[]\n /**\n * \u4E3B\u9898\u8272\n */\n theme?: Theme\n /**\n * \u6269\u5C55\u6570\u636E\n */\n extensions?: any\n }\n /**\n * \u81EA\u5B9A\u4E49\u7C7B\u540D\n */\n className?: string\n as?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'\n}\n"],
4
+ "sourcesContent": ["import type { Theme } from '../../types/props.js'\n\nexport interface Feature {\n /**\n * \u7279\u6027\u6807\u9898\n */\n title: string\n}\n\nexport interface TitleProps {\n data: {\n /**\n * \u4E3B\u6807\u9898\n */\n title?: string\n caption?: string\n /**\n * \u7279\u6027\u5217\u8868\uFF0C\u6700\u591A\u652F\u63013\u4E2A\n */\n features?: Feature[]\n /**\n * \u4E3B\u9898\u8272\n */\n theme?: Theme\n /**\n * \u6269\u5C55\u6570\u636E\n */\n extensions?: any\n }\n /**\n * \u81EA\u5B9A\u4E49\u7C7B\u540D\n */\n className?: string\n as?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'\n weight?: 'bold' | 'medium' | 'semibold' | 'extraBold' | 'black'\n}\n"],
5
5
  "mappings": "+WAAA,IAAAA,EAAA,kBAAAC,EAAAD",
6
6
  "names": ["types_exports", "__toCommonJS"]
7
7
  }
@@ -52,6 +52,13 @@ export { default as ProductSummary } from './Listing/components/ProductCard/Prod
52
52
  export { default as BenefitsTab } from './Listing/components/ProductCard/ProductDetail/BenefitsTab';
53
53
  export { default as PaidShipping } from './Listing/components/PaidShipping/index.js';
54
54
  export { default as ProductCompare } from './ProductCompare/index.js';
55
+ export { default as GraphicMore } from './GraphicMore/index.js';
56
+ export { default as Features } from './Features/index.js';
57
+ export { default as AplusDesc } from './AplusDesc/index.js';
58
+ export { default as GiftBox } from './GiftBox/index.js';
59
+ export { default as SelectStore } from './SelectStore/index.js';
60
+ export { default as DownLoad } from './DownLoad/index.js';
61
+ export { default as FootCharger } from './FootCharger/index.js';
55
62
  export type { ProductCompareProps, ProductItemData } from './ProductCompare/index.js';
56
63
  export { default as Ksp } from './Ksp/index.js';
57
64
  export type { KspProps, KspData, KspCardItem } from './Ksp/index.js';
@@ -108,3 +115,12 @@ export declare const PAYLOAD_COMPONENT_MAP: {
108
115
  'ipc-title': string;
109
116
  'ipc-whychoose': string;
110
117
  };
118
+ export { default as CollectionsFilters } from './CollectionsFilters/index.js';
119
+ export { default as FilterList } from './CollectionsFilters/FilterList.js';
120
+ export { default as FilterHeader } from './CollectionsFilters/FilterHeader.js';
121
+ export { default as FilterCardWrap } from './CollectionsFilters/FilterCardWrap.js';
122
+ export { default as FilterCardWrapItem } from './CollectionsFilters/FilterCardWrapItem.js';
123
+ export { default as Paginator } from './Paginator/index.js';
124
+ export { default as CollectionsBanner } from './CollectionsBanner/index.js';
125
+ export { default as TextMarquee } from './TextMarquee/index.js';
126
+ export { default as CollectionShelves } from './CollectionShelves/index.js';
@@ -1,2 +1,2 @@
1
- "use strict";var xe=Object.create;var i=Object.defineProperty;var ne=Object.getOwnPropertyDescriptor;var he=Object.getOwnPropertyNames;var Pe=Object.getPrototypeOf,ye=Object.prototype.hasOwnProperty;var ge=(r,a)=>{for(var t in a)i(r,t,{get:a[t],enumerable:!0})},u=(r,a,t,f)=>{if(a&&typeof a=="object"||typeof a=="function")for(let p of he(a))!ye.call(r,p)&&p!==t&&i(r,p,{get:()=>a[p],enumerable:!(f=ne(a,p))||f.enumerable});return r};var e=(r,a,t)=>(t=r!=null?xe(Pe(r)):{},u(a||!r||!r.__esModule?i(t,"default",{value:r,enumerable:!0}):t,r)),Me=r=>u(i({},"__esModule",{value:!0}),r);var Ce={};ge(Ce,{AccordionCards:()=>g.default,AiuiProvider:()=>A.default,BenefitsTab:()=>re.default,BizProductProvider:()=>R.default,BrandEquity:()=>d.default,Category:()=>P.default,CreativeModule:()=>D.default,Evaluate:()=>h.default,Faq:()=>q.default,FeatureCards:()=>ie.default,FeatureShowcase:()=>ce.default,FooterNavigation:()=>j.default,Graphic:()=>M.default,GraphicAttractionBlock:()=>v.default,GraphicOverlay:()=>E.default,HeaderNavigation:()=>G.default,HeroBanner:()=>y.default,IPC_SEARCH_PAGE:()=>s.IPC_SEARCH_PAGE,ImageTextFeature:()=>pe.default,ImageWithText:()=>se.default,Ksp:()=>oe.default,Listing:()=>O.default,Marquee:()=>b.default,MarqueeImageContent:()=>o.MarqueeImageContent,MarqueeItem:()=>o.MarqueeItem,MarqueeReview:()=>I.default,MarqueeTextContent:()=>o.MarqueeTextContent,MediaPlayerBase:()=>S.default,MediaPlayerMulti:()=>T.default,MediaPlayerSticky:()=>C.default,MemberEquity:()=>c.default,MultiLayoutGraphicBlock:()=>F.default,PAYLOAD_COMPONENT_MAP:()=>Se,PaidShipping:()=>ae.default,ProductActions:()=>N.default,ProductBenefitsTabs:()=>V.default,ProductBundle:()=>U.default,ProductCard:()=>_.default,ProductCompare:()=>te.default,ProductDetail:()=>$.default,ProductExchangePurchase:()=>J.default,ProductFreeGift:()=>Y.default,ProductGallery:()=>Z.default,ProductGridBox:()=>X.default,ProductHero:()=>le.default,ProductHighlight:()=>z.default,ProductOptions:()=>Q.default,ProductSummary:()=>ee.default,PurchaseBar:()=>K.default,SearchPage:()=>k.default,SearchPageTabType:()=>s.SearchPageTabType,ShelfDisplay:()=>n.default,Slogan:()=>l.default,Spacer:()=>x.default,Specs:()=>L.default,SpecsComparison:()=>me.default,TabGroup:()=>H.default,TabWithImage:()=>de.default,Tabs:()=>W.default,TabsWithMedia:()=>ue.default,Title:()=>m.default,VideoFeature:()=>fe.default,WhyChoose:()=>B.default,withLayout:()=>w.withLayout});module.exports=Me(Ce);var d=e(require("./BrandEquity/index.js")),c=e(require("./MemberEquity/index.js")),l=e(require("./Slogan/index.js")),m=e(require("./Title/index.js")),x=e(require("./Spacer/index.js")),n=e(require("./ShelfDisplay/index.js")),h=e(require("./Evaluate/index.js")),P=e(require("./Category/index.js")),y=e(require("./HeroBanner/index.js")),g=e(require("./AccordionCards/index.js")),M=e(require("./Graphic/index.js")),S=e(require("./MediaPlayerBase/index.js")),C=e(require("./MediaPlayerSticky/index.js")),T=e(require("./MediaPlayerMulti/index.js")),b=e(require("./Marquee/index.js")),I=e(require("./MarqueeReview/index.js")),B=e(require("./WhyChoose/index.js")),q=e(require("./Faq/index.js")),o=require("./Marquee/index.js"),F=e(require("./MultiLayoutGraphicBlock/index.js")),v=e(require("./GraphicAttractionBlock/index.js")),G=e(require("./HeaderNavigation/index.js")),j=e(require("./FooterNavigation/index.js")),k=e(require("./SearchPage/index.js")),s=require("./SearchPage/types.js"),w=require("../shared/Styles.js"),A=e(require("./AiuiProvider/index.js")),W=e(require("./Tabs/index.js")),D=e(require("./CreativeModule/index.js")),E=e(require("./GraphicOverlay/index.js")),L=e(require("./Specs/index.js")),H=e(require("./TabsGroup/index.js")),O=e(require("./Listing/index.js")),R=e(require("./Listing/BizProductProvider.js")),K=e(require("./Listing/components/PurchaseBar/index.js")),N=e(require("./Listing/components/PurchaseBar/ProductActions/index.js")),_=e(require("./Listing/components/ProductCard/index.js")),V=e(require("./Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js")),z=e(require("./Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js")),Y=e(require("./Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js")),J=e(require("./Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js")),Q=e(require("./Listing/components/ProductCard/ProductDetail/ProductOptions/index.js")),U=e(require("./Listing/components/ProductCard/ProductDetail/ProductBundle/index.js")),X=e(require("./Listing/components/ProductCard/ProductGridBox.js")),Z=e(require("./Listing/components/ProductCard/ProductGallery/index.js")),$=e(require("./Listing/components/ProductCard/ProductDetail/index.js")),ee=e(require("./Listing/components/ProductCard/ProductSummary/index.js")),re=e(require("./Listing/components/ProductCard/ProductDetail/BenefitsTab")),ae=e(require("./Listing/components/PaidShipping/index.js")),te=e(require("./ProductCompare/index.js")),oe=e(require("./Ksp/index.js")),pe=e(require("./ImageTextFeature/index.js")),ie=e(require("./FeatureCards/index.js")),se=e(require("./ImageWithText/index.js")),fe=e(require("./VideoFeature/index.js")),ue=e(require("./TabsWithMedia/index.js")),de=e(require("./TabWithImage/index.js")),ce=e(require("./FeatureShowcase/index.js")),le=e(require("./ProductHero/index.js")),me=e(require("./SpecsComparison/index.js"));const Se={"ipc-aplusdesc":"AplusDesc","ipc-banner":"Banner","ipc-brand-equity":"BrandEquity","ipc-category":"Category","ipc-collection-banner":"CollectionBanner","ipc-collection-shelves":"CollectionShelves","ipc-creativemodule":"CreativeModule","ipc-download":"DownLoad","ipc-evaluate":"Evaluate","ipc-faq":"Faq","ipc-features":"Features","ipc-footcharger":"FootCharger","ipc-ga-block":"GraphicAttractionBlock","ipc-giftbox":"GiftBox","ipc-graphic":"Graphic","ipc-graphicmore":"GraphicMore","ipc-graphicoverlay":"GraphicOverlay","ipc-marquee":"Marquee","ipc-mediaplayerbase":"MediaPlayerBase","ipc-mediaplayermulti":"MediaPlayerMulti","ipc-mediaplayersticky":"MediaPlayerSticky","ipc-member-equity":"MemberEquity","ipc-mlg-block":"MultiLayoutGraphicBlock","ipc-search-page-tabs":"SearchPageBlock","ipc-selectstore":"SelectStore","ipc-shelfdisplay":"ShelfDisplay","ipc-slogan":"Slogan","ipc-spacer":"Spacer","ipc-specs":"Specs","ipc-tabs":"Tabs","ipc-text-marquee":"TextMarquee","ipc-title":"Title","ipc-whychoose":"WhyChoose"};
1
+ "use strict";var Ge=Object.create;var s=Object.defineProperty;var je=Object.getOwnPropertyDescriptor;var ke=Object.getOwnPropertyNames;var we=Object.getPrototypeOf,Ae=Object.prototype.hasOwnProperty;var We=(r,a)=>{for(var t in a)s(r,t,{get:a[t],enumerable:!0})},u=(r,a,t,i)=>{if(a&&typeof a=="object"||typeof a=="function")for(let p of ke(a))!Ae.call(r,p)&&p!==t&&s(r,p,{get:()=>a[p],enumerable:!(i=je(a,p))||i.enumerable});return r};var e=(r,a,t)=>(t=r!=null?Ge(we(r)):{},u(a||!r||!r.__esModule?s(t,"default",{value:r,enumerable:!0}):t,r)),De=r=>u(s({},"__esModule",{value:!0}),r);var Ee={};We(Ee,{AccordionCards:()=>g.default,AiuiProvider:()=>A.default,AplusDesc:()=>se.default,BenefitsTab:()=>re.default,BizProductProvider:()=>R.default,BrandEquity:()=>l.default,Category:()=>P.default,CollectionShelves:()=>ve.default,CollectionsBanner:()=>Be.default,CollectionsFilters:()=>Ce.default,CreativeModule:()=>D.default,DownLoad:()=>ue.default,Evaluate:()=>h.default,Faq:()=>B.default,FeatureCards:()=>ce.default,FeatureShowcase:()=>ye.default,Features:()=>pe.default,FilterCardWrap:()=>Fe.default,FilterCardWrapItem:()=>be.default,FilterHeader:()=>Te.default,FilterList:()=>Se.default,FootCharger:()=>le.default,FooterNavigation:()=>j.default,GiftBox:()=>fe.default,Graphic:()=>M.default,GraphicAttractionBlock:()=>v.default,GraphicMore:()=>oe.default,GraphicOverlay:()=>L.default,HeaderNavigation:()=>G.default,HeroBanner:()=>y.default,IPC_SEARCH_PAGE:()=>f.IPC_SEARCH_PAGE,ImageTextFeature:()=>me.default,ImageWithText:()=>xe.default,Ksp:()=>de.default,Listing:()=>O.default,Marquee:()=>F.default,MarqueeImageContent:()=>o.MarqueeImageContent,MarqueeItem:()=>o.MarqueeItem,MarqueeReview:()=>b.default,MarqueeTextContent:()=>o.MarqueeTextContent,MediaPlayerBase:()=>C.default,MediaPlayerMulti:()=>T.default,MediaPlayerSticky:()=>S.default,MemberEquity:()=>d.default,MultiLayoutGraphicBlock:()=>q.default,PAYLOAD_COMPONENT_MAP:()=>Le,Paginator:()=>Ie.default,PaidShipping:()=>ae.default,ProductActions:()=>N.default,ProductBenefitsTabs:()=>V.default,ProductBundle:()=>U.default,ProductCard:()=>_.default,ProductCompare:()=>te.default,ProductDetail:()=>$.default,ProductExchangePurchase:()=>J.default,ProductFreeGift:()=>Y.default,ProductGallery:()=>Z.default,ProductGridBox:()=>X.default,ProductHero:()=>ge.default,ProductHighlight:()=>z.default,ProductOptions:()=>Q.default,ProductSummary:()=>ee.default,PurchaseBar:()=>K.default,SearchPage:()=>k.default,SearchPageTabType:()=>f.SearchPageTabType,SelectStore:()=>ie.default,ShelfDisplay:()=>n.default,Slogan:()=>m.default,Spacer:()=>x.default,Specs:()=>E.default,SpecsComparison:()=>Me.default,TabGroup:()=>H.default,TabWithImage:()=>Pe.default,Tabs:()=>W.default,TabsWithMedia:()=>he.default,TextMarquee:()=>qe.default,Title:()=>c.default,VideoFeature:()=>ne.default,WhyChoose:()=>I.default,withLayout:()=>w.withLayout});module.exports=De(Ee);var l=e(require("./BrandEquity/index.js")),d=e(require("./MemberEquity/index.js")),m=e(require("./Slogan/index.js")),c=e(require("./Title/index.js")),x=e(require("./Spacer/index.js")),n=e(require("./ShelfDisplay/index.js")),h=e(require("./Evaluate/index.js")),P=e(require("./Category/index.js")),y=e(require("./HeroBanner/index.js")),g=e(require("./AccordionCards/index.js")),M=e(require("./Graphic/index.js")),C=e(require("./MediaPlayerBase/index.js")),S=e(require("./MediaPlayerSticky/index.js")),T=e(require("./MediaPlayerMulti/index.js")),F=e(require("./Marquee/index.js")),b=e(require("./MarqueeReview/index.js")),I=e(require("./WhyChoose/index.js")),B=e(require("./Faq/index.js")),o=require("./Marquee/index.js"),q=e(require("./MultiLayoutGraphicBlock/index.js")),v=e(require("./GraphicAttractionBlock/index.js")),G=e(require("./HeaderNavigation/index.js")),j=e(require("./FooterNavigation/index.js")),k=e(require("./SearchPage/index.js")),f=require("./SearchPage/types.js"),w=require("../shared/Styles.js"),A=e(require("./AiuiProvider/index.js")),W=e(require("./Tabs/index.js")),D=e(require("./CreativeModule/index.js")),L=e(require("./GraphicOverlay/index.js")),E=e(require("./Specs/index.js")),H=e(require("./TabsGroup/index.js")),O=e(require("./Listing/index.js")),R=e(require("./Listing/BizProductProvider.js")),K=e(require("./Listing/components/PurchaseBar/index.js")),N=e(require("./Listing/components/PurchaseBar/ProductActions/index.js")),_=e(require("./Listing/components/ProductCard/index.js")),V=e(require("./Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js")),z=e(require("./Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js")),Y=e(require("./Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js")),J=e(require("./Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js")),Q=e(require("./Listing/components/ProductCard/ProductDetail/ProductOptions/index.js")),U=e(require("./Listing/components/ProductCard/ProductDetail/ProductBundle/index.js")),X=e(require("./Listing/components/ProductCard/ProductGridBox.js")),Z=e(require("./Listing/components/ProductCard/ProductGallery/index.js")),$=e(require("./Listing/components/ProductCard/ProductDetail/index.js")),ee=e(require("./Listing/components/ProductCard/ProductSummary/index.js")),re=e(require("./Listing/components/ProductCard/ProductDetail/BenefitsTab")),ae=e(require("./Listing/components/PaidShipping/index.js")),te=e(require("./ProductCompare/index.js")),oe=e(require("./GraphicMore/index.js")),pe=e(require("./Features/index.js")),se=e(require("./AplusDesc/index.js")),fe=e(require("./GiftBox/index.js")),ie=e(require("./SelectStore/index.js")),ue=e(require("./DownLoad/index.js")),le=e(require("./FootCharger/index.js")),de=e(require("./Ksp/index.js")),me=e(require("./ImageTextFeature/index.js")),ce=e(require("./FeatureCards/index.js")),xe=e(require("./ImageWithText/index.js")),ne=e(require("./VideoFeature/index.js")),he=e(require("./TabsWithMedia/index.js")),Pe=e(require("./TabWithImage/index.js")),ye=e(require("./FeatureShowcase/index.js")),ge=e(require("./ProductHero/index.js")),Me=e(require("./SpecsComparison/index.js")),Ce=e(require("./CollectionsFilters/index.js")),Se=e(require("./CollectionsFilters/FilterList.js")),Te=e(require("./CollectionsFilters/FilterHeader.js")),Fe=e(require("./CollectionsFilters/FilterCardWrap.js")),be=e(require("./CollectionsFilters/FilterCardWrapItem.js")),Ie=e(require("./Paginator/index.js")),Be=e(require("./CollectionsBanner/index.js")),qe=e(require("./TextMarquee/index.js")),ve=e(require("./CollectionShelves/index.js"));const Le={"ipc-aplusdesc":"AplusDesc","ipc-banner":"Banner","ipc-brand-equity":"BrandEquity","ipc-category":"Category","ipc-collection-banner":"CollectionBanner","ipc-collection-shelves":"CollectionShelves","ipc-creativemodule":"CreativeModule","ipc-download":"DownLoad","ipc-evaluate":"Evaluate","ipc-faq":"Faq","ipc-features":"Features","ipc-footcharger":"FootCharger","ipc-ga-block":"GraphicAttractionBlock","ipc-giftbox":"GiftBox","ipc-graphic":"Graphic","ipc-graphicmore":"GraphicMore","ipc-graphicoverlay":"GraphicOverlay","ipc-marquee":"Marquee","ipc-mediaplayerbase":"MediaPlayerBase","ipc-mediaplayermulti":"MediaPlayerMulti","ipc-mediaplayersticky":"MediaPlayerSticky","ipc-member-equity":"MemberEquity","ipc-mlg-block":"MultiLayoutGraphicBlock","ipc-search-page-tabs":"SearchPageBlock","ipc-selectstore":"SelectStore","ipc-shelfdisplay":"ShelfDisplay","ipc-slogan":"Slogan","ipc-spacer":"Spacer","ipc-specs":"Specs","ipc-tabs":"Tabs","ipc-text-marquee":"TextMarquee","ipc-title":"Title","ipc-whychoose":"WhyChoose"};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/biz-components/index.ts"],
4
- "sourcesContent": ["export { default as BrandEquity } from './BrandEquity/index.js'\nexport { default as MemberEquity } from './MemberEquity/index.js'\nexport { default as Slogan } from './Slogan/index.js'\nexport { default as Title } from './Title/index.js'\nexport { default as Spacer } from './Spacer/index.js'\nexport { default as ShelfDisplay } from './ShelfDisplay/index.js'\nexport { default as Evaluate } from './Evaluate/index.js'\nexport { default as Category } from './Category/index.js'\nexport { default as HeroBanner } from './HeroBanner/index.js'\nexport { default as AccordionCards } from './AccordionCards/index.js'\nexport { default as Graphic } from './Graphic/index.js'\nexport { default as MediaPlayerBase } from './MediaPlayerBase/index.js'\nexport { default as MediaPlayerSticky } from './MediaPlayerSticky/index.js'\nexport { default as MediaPlayerMulti } from './MediaPlayerMulti/index.js'\nexport { default as Marquee } from './Marquee/index.js'\nexport { default as MarqueeReview } from './MarqueeReview/index.js'\nexport type { MarqueeReviewProps, MarqueeReviewData, ReviewItem } from './MarqueeReview/index.js'\nexport { default as WhyChoose } from './WhyChoose/index.js'\nexport { default as Faq } from './Faq/index.js'\nexport { MarqueeItem, MarqueeImageContent, MarqueeTextContent } from './Marquee/index.js'\nexport { default as MultiLayoutGraphicBlock } from './MultiLayoutGraphicBlock/index.js'\nexport type { MultiLayoutGraphicBlockProps } from './MultiLayoutGraphicBlock/index.js'\nexport { default as GraphicAttractionBlock } from './GraphicAttractionBlock/index.js'\nexport type { GraphicAttractionBlockProps } from './GraphicAttractionBlock/index.js'\nexport { default as HeaderNavigation } from './HeaderNavigation/index.js'\nexport { default as FooterNavigation } from './FooterNavigation/index.js'\nexport { default as SearchPage } from './SearchPage/index.js'\nexport type { SearchPageProps } from './SearchPage/types.js'\nexport { IPC_SEARCH_PAGE, SearchPageTabType } from './SearchPage/types.js'\n\nexport { withLayout } from '../shared/Styles.js'\nexport { default as AiuiProvider } from './AiuiProvider/index.js'\nexport { default as Tabs } from './Tabs/index.js'\nexport { default as CreativeModule } from './CreativeModule/index.js'\nexport { default as GraphicOverlay } from './GraphicOverlay/index.js'\nexport { default as Specs } from './Specs/index.js'\nexport { default as TabGroup } from './TabsGroup/index.js'\nexport { default as Listing } from './Listing/index.js'\nexport { default as BizProductProvider } from './Listing/BizProductProvider.js'\nexport { default as PurchaseBar } from './Listing/components/PurchaseBar/index.js'\nexport { default as ProductActions } from './Listing/components/PurchaseBar/ProductActions/index.js'\nexport { default as ProductCard } from './Listing/components/ProductCard/index.js'\nexport { default as ProductBenefitsTabs } from './Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js'\nexport { default as ProductHighlight } from './Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js'\nexport { default as ProductFreeGift } from './Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js'\nexport { default as ProductExchangePurchase } from './Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js'\nexport { default as ProductOptions } from './Listing/components/ProductCard/ProductDetail/ProductOptions/index.js'\nexport { default as ProductBundle } from './Listing/components/ProductCard/ProductDetail/ProductBundle/index.js'\nexport { default as ProductGridBox } from './Listing/components/ProductCard/ProductGridBox.js'\nexport { default as ProductGallery } from './Listing/components/ProductCard/ProductGallery/index.js'\nexport { default as ProductDetail } from './Listing/components/ProductCard/ProductDetail/index.js'\nexport { default as ProductSummary } from './Listing/components/ProductCard/ProductSummary/index.js'\nexport { default as BenefitsTab } from './Listing/components/ProductCard/ProductDetail/BenefitsTab'\nexport { default as PaidShipping } from './Listing/components/PaidShipping/index.js'\nexport { default as ProductCompare } from './ProductCompare/index.js'\nexport type { ProductCompareProps, ProductItemData } from './ProductCompare/index.js'\nexport { default as Ksp } from './Ksp/index.js'\nexport type { KspProps, KspData, KspCardItem } from './Ksp/index.js'\nexport { default as ImageTextFeature } from './ImageTextFeature/index.js'\nexport type { ImageTextFeatureProps, ImageTextFeatureItem } from './ImageTextFeature/index.js'\nexport { default as FeatureCards } from './FeatureCards/index.js'\nexport type { FeatureCardsProps, FeatureCardItem } from './FeatureCards/index.js'\nexport { default as ImageWithText } from './ImageWithText/index.js'\nexport type { ImageWithTextProps } from './ImageWithText/index.js'\nexport { default as VideoFeature } from './VideoFeature/index.js'\nexport type { VideoFeatureProps } from './VideoFeature/index.js'\nexport { default as TabsWithMedia } from './TabsWithMedia/index.js'\nexport type { TabsWithMediaProps, TabItem, TimeIndex } from './TabsWithMedia/index.js'\nexport { default as TabWithImage } from './TabWithImage/index.js'\nexport type { TabWithImageProps, TabWithImageDataItem } from './TabWithImage/index.js'\nexport { default as FeatureShowcase } from './FeatureShowcase/index.js'\nexport type { FeatureShowcaseProps, FeatureShowcaseItem } from './FeatureShowcase/index.js'\nexport { default as ProductHero } from './ProductHero/index.js'\nexport type { ProductHeroProps } from './ProductHero/index.js'\nexport { default as SpecsComparison } from './SpecsComparison/index.js'\nexport type {\n SpecsComparisonProps,\n SpecsComparisonMenuItem,\n SpecsComparisonLeftMenuItem,\n} from './SpecsComparison/index.js'\n\nexport const PAYLOAD_COMPONENT_MAP = {\n 'ipc-aplusdesc': 'AplusDesc',\n 'ipc-banner': 'Banner',\n 'ipc-brand-equity': 'BrandEquity',\n 'ipc-category': 'Category',\n 'ipc-collection-banner': 'CollectionBanner',\n 'ipc-collection-shelves': 'CollectionShelves',\n 'ipc-creativemodule': 'CreativeModule',\n 'ipc-download': 'DownLoad',\n 'ipc-evaluate': 'Evaluate',\n 'ipc-faq': 'Faq',\n 'ipc-features': 'Features',\n 'ipc-footcharger': 'FootCharger',\n 'ipc-ga-block': 'GraphicAttractionBlock',\n 'ipc-giftbox': 'GiftBox',\n 'ipc-graphic': 'Graphic',\n 'ipc-graphicmore': 'GraphicMore',\n 'ipc-graphicoverlay': 'GraphicOverlay',\n 'ipc-marquee': 'Marquee',\n 'ipc-mediaplayerbase': 'MediaPlayerBase',\n 'ipc-mediaplayermulti': 'MediaPlayerMulti',\n 'ipc-mediaplayersticky': 'MediaPlayerSticky',\n 'ipc-member-equity': 'MemberEquity',\n 'ipc-mlg-block': 'MultiLayoutGraphicBlock',\n 'ipc-search-page-tabs': 'SearchPageBlock',\n 'ipc-selectstore': 'SelectStore',\n 'ipc-shelfdisplay': 'ShelfDisplay',\n 'ipc-slogan': 'Slogan',\n 'ipc-spacer': 'Spacer',\n 'ipc-specs': 'Specs',\n 'ipc-tabs': 'Tabs',\n 'ipc-text-marquee': 'TextMarquee',\n 'ipc-title': 'Title',\n 'ipc-whychoose': 'WhyChoose',\n}\n"],
5
- "mappings": "skBAAA,IAAAA,GAAA,GAAAC,GAAAD,GAAA,o8BAAAE,GAAA,22BAAAC,GAAAH,IAAA,IAAAI,EAAuC,qCACvCC,EAAwC,sCACxCC,EAAkC,gCAClCC,EAAiC,+BACjCC,EAAkC,gCAClCC,EAAwC,sCACxCC,EAAoC,kCACpCC,EAAoC,kCACpCC,EAAsC,oCACtCC,EAA0C,wCAC1CC,EAAmC,iCACnCC,EAA2C,yCAC3CC,EAA6C,2CAC7CC,EAA4C,0CAC5CC,EAAmC,iCACnCC,EAAyC,uCAEzCC,EAAqC,mCACrCC,EAA+B,6BAC/BH,EAAqE,8BACrEI,EAAmD,iDAEnDC,EAAkD,gDAElDC,EAA4C,0CAC5CC,EAA4C,0CAC5CC,EAAsC,oCAEtCC,EAAmD,iCAEnDC,EAA2B,+BAC3BC,EAAwC,sCACxCC,EAAgC,8BAChCC,EAA0C,wCAC1CC,EAA0C,wCAC1CC,EAAiC,+BACjCC,EAAoC,mCACpCC,EAAmC,iCACnCC,EAA8C,8CAC9CC,EAAuC,wDACvCC,EAA0C,uEAC1CC,EAAuC,wDACvCC,EAA+C,0FAC/CC,EAA4C,uFAC5CC,EAA2C,sFAC3CC,EAAmD,8FACnDC,EAA0C,qFAC1CC,EAAyC,oFACzCC,EAA0C,iEAC1CC,EAA0C,uEAC1CC,EAAyC,sEACzCC,GAA0C,uEAC1CC,GAAuC,yEACvCC,GAAwC,yDACxCC,GAA0C,wCAE1CC,GAA+B,6BAE/BC,GAA4C,0CAE5CC,GAAwC,sCAExCC,GAAyC,uCAEzCC,GAAwC,sCAExCC,GAAyC,uCAEzCC,GAAwC,sCAExCC,GAA2C,yCAE3CC,GAAuC,qCAEvCC,GAA2C,yCAOpC,MAAM5D,GAAwB,CACnC,gBAAiB,YACjB,aAAc,SACd,mBAAoB,cACpB,eAAgB,WAChB,wBAAyB,mBACzB,yBAA0B,oBAC1B,qBAAsB,iBACtB,eAAgB,WAChB,eAAgB,WAChB,UAAW,MACX,eAAgB,WAChB,kBAAmB,cACnB,eAAgB,yBAChB,cAAe,UACf,cAAe,UACf,kBAAmB,cACnB,qBAAsB,iBACtB,cAAe,UACf,sBAAuB,kBACvB,uBAAwB,mBACxB,wBAAyB,oBACzB,oBAAqB,eACrB,gBAAiB,0BACjB,uBAAwB,kBACxB,kBAAmB,cACnB,mBAAoB,eACpB,aAAc,SACd,aAAc,SACd,YAAa,QACb,WAAY,OACZ,mBAAoB,cACpB,YAAa,QACb,gBAAiB,WACnB",
6
- "names": ["biz_components_exports", "__export", "PAYLOAD_COMPONENT_MAP", "__toCommonJS", "import_BrandEquity", "import_MemberEquity", "import_Slogan", "import_Title", "import_Spacer", "import_ShelfDisplay", "import_Evaluate", "import_Category", "import_HeroBanner", "import_AccordionCards", "import_Graphic", "import_MediaPlayerBase", "import_MediaPlayerSticky", "import_MediaPlayerMulti", "import_Marquee", "import_MarqueeReview", "import_WhyChoose", "import_Faq", "import_MultiLayoutGraphicBlock", "import_GraphicAttractionBlock", "import_HeaderNavigation", "import_FooterNavigation", "import_SearchPage", "import_types", "import_Styles", "import_AiuiProvider", "import_Tabs", "import_CreativeModule", "import_GraphicOverlay", "import_Specs", "import_TabsGroup", "import_Listing", "import_BizProductProvider", "import_PurchaseBar", "import_ProductActions", "import_ProductCard", "import_ProductBenefitsTabs", "import_ProductHighlight", "import_ProductFreeGift", "import_ProductExchangePurchase", "import_ProductOptions", "import_ProductBundle", "import_ProductGridBox", "import_ProductGallery", "import_ProductDetail", "import_ProductSummary", "import_BenefitsTab", "import_PaidShipping", "import_ProductCompare", "import_Ksp", "import_ImageTextFeature", "import_FeatureCards", "import_ImageWithText", "import_VideoFeature", "import_TabsWithMedia", "import_TabWithImage", "import_FeatureShowcase", "import_ProductHero", "import_SpecsComparison"]
4
+ "sourcesContent": ["export { default as BrandEquity } from './BrandEquity/index.js'\nexport { default as MemberEquity } from './MemberEquity/index.js'\nexport { default as Slogan } from './Slogan/index.js'\nexport { default as Title } from './Title/index.js'\nexport { default as Spacer } from './Spacer/index.js'\nexport { default as ShelfDisplay } from './ShelfDisplay/index.js'\nexport { default as Evaluate } from './Evaluate/index.js'\nexport { default as Category } from './Category/index.js'\nexport { default as HeroBanner } from './HeroBanner/index.js'\nexport { default as AccordionCards } from './AccordionCards/index.js'\nexport { default as Graphic } from './Graphic/index.js'\nexport { default as MediaPlayerBase } from './MediaPlayerBase/index.js'\nexport { default as MediaPlayerSticky } from './MediaPlayerSticky/index.js'\nexport { default as MediaPlayerMulti } from './MediaPlayerMulti/index.js'\nexport { default as Marquee } from './Marquee/index.js'\nexport { default as MarqueeReview } from './MarqueeReview/index.js'\nexport type { MarqueeReviewProps, MarqueeReviewData, ReviewItem } from './MarqueeReview/index.js'\nexport { default as WhyChoose } from './WhyChoose/index.js'\nexport { default as Faq } from './Faq/index.js'\nexport { MarqueeItem, MarqueeImageContent, MarqueeTextContent } from './Marquee/index.js'\nexport { default as MultiLayoutGraphicBlock } from './MultiLayoutGraphicBlock/index.js'\nexport type { MultiLayoutGraphicBlockProps } from './MultiLayoutGraphicBlock/index.js'\nexport { default as GraphicAttractionBlock } from './GraphicAttractionBlock/index.js'\nexport type { GraphicAttractionBlockProps } from './GraphicAttractionBlock/index.js'\nexport { default as HeaderNavigation } from './HeaderNavigation/index.js'\nexport { default as FooterNavigation } from './FooterNavigation/index.js'\nexport { default as SearchPage } from './SearchPage/index.js'\nexport type { SearchPageProps } from './SearchPage/types.js'\nexport { IPC_SEARCH_PAGE, SearchPageTabType } from './SearchPage/types.js'\n\nexport { withLayout } from '../shared/Styles.js'\nexport { default as AiuiProvider } from './AiuiProvider/index.js'\nexport { default as Tabs } from './Tabs/index.js'\nexport { default as CreativeModule } from './CreativeModule/index.js'\nexport { default as GraphicOverlay } from './GraphicOverlay/index.js'\nexport { default as Specs } from './Specs/index.js'\nexport { default as TabGroup } from './TabsGroup/index.js'\nexport { default as Listing } from './Listing/index.js'\nexport { default as BizProductProvider } from './Listing/BizProductProvider.js'\nexport { default as PurchaseBar } from './Listing/components/PurchaseBar/index.js'\nexport { default as ProductActions } from './Listing/components/PurchaseBar/ProductActions/index.js'\nexport { default as ProductCard } from './Listing/components/ProductCard/index.js'\nexport { default as ProductBenefitsTabs } from './Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js'\nexport { default as ProductHighlight } from './Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js'\nexport { default as ProductFreeGift } from './Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js'\nexport { default as ProductExchangePurchase } from './Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js'\nexport { default as ProductOptions } from './Listing/components/ProductCard/ProductDetail/ProductOptions/index.js'\nexport { default as ProductBundle } from './Listing/components/ProductCard/ProductDetail/ProductBundle/index.js'\nexport { default as ProductGridBox } from './Listing/components/ProductCard/ProductGridBox.js'\nexport { default as ProductGallery } from './Listing/components/ProductCard/ProductGallery/index.js'\nexport { default as ProductDetail } from './Listing/components/ProductCard/ProductDetail/index.js'\nexport { default as ProductSummary } from './Listing/components/ProductCard/ProductSummary/index.js'\nexport { default as BenefitsTab } from './Listing/components/ProductCard/ProductDetail/BenefitsTab'\nexport { default as PaidShipping } from './Listing/components/PaidShipping/index.js'\nexport { default as ProductCompare } from './ProductCompare/index.js'\nexport { default as GraphicMore } from './GraphicMore/index.js'\nexport { default as Features } from './Features/index.js'\nexport { default as AplusDesc } from './AplusDesc/index.js'\nexport { default as GiftBox } from './GiftBox/index.js'\nexport { default as SelectStore } from './SelectStore/index.js'\nexport { default as DownLoad } from './DownLoad/index.js'\nexport { default as FootCharger } from './FootCharger/index.js'\nexport type { ProductCompareProps, ProductItemData } from './ProductCompare/index.js'\nexport { default as Ksp } from './Ksp/index.js'\nexport type { KspProps, KspData, KspCardItem } from './Ksp/index.js'\nexport { default as ImageTextFeature } from './ImageTextFeature/index.js'\nexport type { ImageTextFeatureProps, ImageTextFeatureItem } from './ImageTextFeature/index.js'\nexport { default as FeatureCards } from './FeatureCards/index.js'\nexport type { FeatureCardsProps, FeatureCardItem } from './FeatureCards/index.js'\nexport { default as ImageWithText } from './ImageWithText/index.js'\nexport type { ImageWithTextProps } from './ImageWithText/index.js'\nexport { default as VideoFeature } from './VideoFeature/index.js'\nexport type { VideoFeatureProps } from './VideoFeature/index.js'\nexport { default as TabsWithMedia } from './TabsWithMedia/index.js'\nexport type { TabsWithMediaProps, TabItem, TimeIndex } from './TabsWithMedia/index.js'\nexport { default as TabWithImage } from './TabWithImage/index.js'\nexport type { TabWithImageProps, TabWithImageDataItem } from './TabWithImage/index.js'\nexport { default as FeatureShowcase } from './FeatureShowcase/index.js'\nexport type { FeatureShowcaseProps, FeatureShowcaseItem } from './FeatureShowcase/index.js'\nexport { default as ProductHero } from './ProductHero/index.js'\nexport type { ProductHeroProps } from './ProductHero/index.js'\nexport { default as SpecsComparison } from './SpecsComparison/index.js'\nexport type {\n SpecsComparisonProps,\n SpecsComparisonMenuItem,\n SpecsComparisonLeftMenuItem,\n} from './SpecsComparison/index.js'\n\nexport const PAYLOAD_COMPONENT_MAP = {\n 'ipc-aplusdesc': 'AplusDesc',\n 'ipc-banner': 'Banner',\n 'ipc-brand-equity': 'BrandEquity',\n 'ipc-category': 'Category',\n 'ipc-collection-banner': 'CollectionBanner',\n 'ipc-collection-shelves': 'CollectionShelves',\n 'ipc-creativemodule': 'CreativeModule',\n 'ipc-download': 'DownLoad',\n 'ipc-evaluate': 'Evaluate',\n 'ipc-faq': 'Faq',\n 'ipc-features': 'Features',\n 'ipc-footcharger': 'FootCharger',\n 'ipc-ga-block': 'GraphicAttractionBlock',\n 'ipc-giftbox': 'GiftBox',\n 'ipc-graphic': 'Graphic',\n 'ipc-graphicmore': 'GraphicMore',\n 'ipc-graphicoverlay': 'GraphicOverlay',\n 'ipc-marquee': 'Marquee',\n 'ipc-mediaplayerbase': 'MediaPlayerBase',\n 'ipc-mediaplayermulti': 'MediaPlayerMulti',\n 'ipc-mediaplayersticky': 'MediaPlayerSticky',\n 'ipc-member-equity': 'MemberEquity',\n 'ipc-mlg-block': 'MultiLayoutGraphicBlock',\n 'ipc-search-page-tabs': 'SearchPageBlock',\n 'ipc-selectstore': 'SelectStore',\n 'ipc-shelfdisplay': 'ShelfDisplay',\n 'ipc-slogan': 'Slogan',\n 'ipc-spacer': 'Spacer',\n 'ipc-specs': 'Specs',\n 'ipc-tabs': 'Tabs',\n 'ipc-text-marquee': 'TextMarquee',\n 'ipc-title': 'Title',\n 'ipc-whychoose': 'WhyChoose',\n}\nexport { default as CollectionsFilters } from './CollectionsFilters/index.js'\nexport { default as FilterList } from './CollectionsFilters/FilterList.js'\nexport { default as FilterHeader } from './CollectionsFilters/FilterHeader.js'\nexport { default as FilterCardWrap } from './CollectionsFilters/FilterCardWrap.js'\nexport { default as FilterCardWrapItem } from './CollectionsFilters/FilterCardWrapItem.js'\nexport { default as Paginator } from './Paginator/index.js'\nexport { default as CollectionsBanner } from './CollectionsBanner/index.js'\nexport { default as TextMarquee } from './TextMarquee/index.js'\nexport { default as CollectionShelves } from './CollectionShelves/index.js'\n"],
5
+ "mappings": "skBAAA,IAAAA,GAAA,GAAAC,GAAAD,GAAA,ozCAAAE,GAAA,07BAAAC,GAAAH,IAAA,IAAAI,EAAuC,qCACvCC,EAAwC,sCACxCC,EAAkC,gCAClCC,EAAiC,+BACjCC,EAAkC,gCAClCC,EAAwC,sCACxCC,EAAoC,kCACpCC,EAAoC,kCACpCC,EAAsC,oCACtCC,EAA0C,wCAC1CC,EAAmC,iCACnCC,EAA2C,yCAC3CC,EAA6C,2CAC7CC,EAA4C,0CAC5CC,EAAmC,iCACnCC,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,qBAAsB,iBACtB,cAAe,UACf,sBAAuB,kBACvB,uBAAwB,mBACxB,wBAAyB,oBACzB,oBAAqB,eACrB,gBAAiB,0BACjB,uBAAwB,kBACxB,kBAAmB,cACnB,mBAAoB,eACpB,aAAc,SACd,aAAc,SACd,YAAa,QACb,WAAY,OACZ,mBAAoB,cACpB,YAAa,QACb,gBAAiB,WACnB",
6
+ "names": ["biz_components_exports", "__export", "PAYLOAD_COMPONENT_MAP", "__toCommonJS", "import_BrandEquity", "import_MemberEquity", "import_Slogan", "import_Title", "import_Spacer", "import_ShelfDisplay", "import_Evaluate", "import_Category", "import_HeroBanner", "import_AccordionCards", "import_Graphic", "import_MediaPlayerBase", "import_MediaPlayerSticky", "import_MediaPlayerMulti", "import_Marquee", "import_MarqueeReview", "import_WhyChoose", "import_Faq", "import_MultiLayoutGraphicBlock", "import_GraphicAttractionBlock", "import_HeaderNavigation", "import_FooterNavigation", "import_SearchPage", "import_types", "import_Styles", "import_AiuiProvider", "import_Tabs", "import_CreativeModule", "import_GraphicOverlay", "import_Specs", "import_TabsGroup", "import_Listing", "import_BizProductProvider", "import_PurchaseBar", "import_ProductActions", "import_ProductCard", "import_ProductBenefitsTabs", "import_ProductHighlight", "import_ProductFreeGift", "import_ProductExchangePurchase", "import_ProductOptions", "import_ProductBundle", "import_ProductGridBox", "import_ProductGallery", "import_ProductDetail", "import_ProductSummary", "import_BenefitsTab", "import_PaidShipping", "import_ProductCompare", "import_GraphicMore", "import_Features", "import_AplusDesc", "import_GiftBox", "import_SelectStore", "import_DownLoad", "import_FootCharger", "import_Ksp", "import_ImageTextFeature", "import_FeatureCards", "import_ImageWithText", "import_VideoFeature", "import_TabsWithMedia", "import_TabWithImage", "import_FeatureShowcase", "import_ProductHero", "import_SpecsComparison", "import_CollectionsFilters", "import_FilterList", "import_FilterHeader", "import_FilterCardWrap", "import_FilterCardWrapItem", "import_Paginator", "import_CollectionsBanner", "import_TextMarquee", "import_CollectionShelves"]
7
7
  }
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ export type BreadcrumbItem = {
3
+ label: string;
4
+ href?: string;
5
+ };
6
+ type Props = {
7
+ items: BreadcrumbItem[];
8
+ maxItems?: number;
9
+ className?: string;
10
+ };
11
+ export declare const Breadcrumb: React.FC<Props>;
12
+ export default Breadcrumb;
@@ -0,0 +1,2 @@
1
+ "use strict";var f=Object.create;var o=Object.defineProperty;var d=Object.getOwnPropertyDescriptor;var h=Object.getOwnPropertyNames;var g=Object.getPrototypeOf,x=Object.prototype.hasOwnProperty;var N=(e,l)=>{for(var r in l)o(e,r,{get:l[r],enumerable:!0})},m=(e,l,r,c)=>{if(l&&typeof l=="object"||typeof l=="function")for(let t of h(l))!x.call(e,t)&&t!==r&&o(e,t,{get:()=>l[t],enumerable:!(c=d(l,t))||c.enumerable});return e};var y=(e,l,r)=>(r=e!=null?f(g(e)):{},m(l||!e||!e.__esModule?o(r,"default",{value:e,enumerable:!0}):r,e)),k=e=>m(o({},"__esModule",{value:!0}),e);var I={};N(I,{Breadcrumb:()=>p,default:()=>B});module.exports=k(I);var s=require("react/jsx-runtime"),v=require("react"),b=y(require("./link"));const p=({items:e,maxItems:l=5,className:r=""})=>{if(!e||e.length===0)return null;const c=e.length>l;let t=e;if(c){const a=e[0],n=e.slice(-2);t=[a,{ellipsis:!0},...n]}return(0,s.jsx)("nav",{className:r,"aria-label":"Breadcrumb",children:(0,s.jsx)("ol",{className:"flex items-center",children:t.map((a,n)=>{if("ellipsis"in a&&a.ellipsis)return(0,s.jsx)("li",{className:"select-none text-gray-400",children:(0,s.jsx)("span",{"aria-hidden":!0,children:"\u2026"})},`ellipsis-${n}`);const i=e?.[e?.length-1]?.label===a?.label&&e?.[e?.length-1]?.href===a?.href,u=`${a.label}-${n}`;return(0,s.jsxs)("li",{className:"flex items-center font-bold desktop:text-lg tablet:text-base text-sm",children:[n!==0&&(0,s.jsx)("span",{className:"mx-1 text-[#6D6D6F]",children:"/"}),i?(0,s.jsx)("span",{className:"truncate","aria-current":"page",title:a.label,children:a.label}):(0,s.jsx)(b.default,{href:a.href,asChild:!a.href,title:a.label,className:"text-[#6D6D6F] truncate no-underline",children:a.label})]},u)})})})};p.displayName="Breadcrumb";var B=p;
2
+ //# sourceMappingURL=breadcrumb.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/components/breadcrumb.tsx"],
4
+ "sourcesContent": ["// Breadcrumb.tsx\nimport React from 'react'\nimport Link from './link'\n\nexport type BreadcrumbItem = {\n label: string\n href?: string // \u5982\u679C\u6CA1\u6709 href \u5219\u6E32\u67D3\u4E3A\u4E0D\u53EF\u70B9\u51FB\u7684\u6587\u672C\uFF08\u901A\u5E38\u7528\u4E8E\u6700\u540E\u4E00\u9879\uFF09\n}\n\ntype Props = {\n items: BreadcrumbItem[]\n maxItems?: number // \u8D85\u8FC7\u591A\u5C11\u4E2A\u65F6\u542F\u7528\u622A\u65AD\u903B\u8F91\uFF08\u9ED8\u8BA4 5\uFF09\n className?: string\n}\n\nexport const Breadcrumb: React.FC<Props> = ({ items, maxItems = 5, className = '' }) => {\n if (!items || items.length === 0) return null\n\n // \u5982\u679C\u6570\u91CF\u8D85\u51FA maxItems\uFF0C\u5219\u663E\u793A first, '...', last 2\n const shouldTruncate = items.length > maxItems\n let visibleItems: (BreadcrumbItem | { ellipsis: true })[] = items\n\n if (shouldTruncate) {\n const first = items[0]\n const lastTwo = items.slice(-2)\n visibleItems = [first, { ellipsis: true }, ...lastTwo]\n }\n\n return (\n <nav className={className} aria-label=\"Breadcrumb\">\n <ol className=\"flex items-center\">\n {visibleItems.map((it: any, idx) => {\n // \u5904\u7406\u7701\u7565\u9879\n if ('ellipsis' in it && it.ellipsis) {\n return (\n <li key={`ellipsis-${idx}`} className=\"select-none text-gray-400\">\n <span aria-hidden>\u2026</span>\n </li>\n )\n }\n const isLast =\n items?.[items?.length - 1]?.label === it?.label && items?.[items?.length - 1]?.href === it?.href\n const key = `${it.label}-${idx}`\n\n return (\n <li key={key} className=\"flex items-center font-bold desktop:text-lg tablet:text-base text-sm\">\n {/* \u5206\u9694\u7B26\uFF08\u7B2C\u4E00\u4E2A\u9879\u524D\u9762\u4E0D\u6E32\u67D3\uFF09 */}\n {idx !== 0 && <span className=\"mx-1 text-[#6D6D6F]\">/</span>}\n\n {isLast ? (\n <span className=\"truncate\" aria-current=\"page\" title={it.label}>\n {it.label}\n </span>\n ) : (\n <Link\n href={it.href}\n asChild={!it.href}\n title={it.label}\n className=\"text-[#6D6D6F] truncate no-underline\"\n >\n {it.label}\n </Link>\n )}\n </li>\n )\n })}\n </ol>\n </nav>\n )\n}\n\nBreadcrumb.displayName = 'Breadcrumb'\n\nexport default Breadcrumb\n"],
5
+ "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,gBAAAE,EAAA,YAAAC,IAAA,eAAAC,EAAAJ,GAoCgB,IAAAK,EAAA,6BAnChBC,EAAkB,iBAClBC,EAAiB,qBAaV,MAAML,EAA8B,CAAC,CAAE,MAAAM,EAAO,SAAAC,EAAW,EAAG,UAAAC,EAAY,EAAG,IAAM,CACtF,GAAI,CAACF,GAASA,EAAM,SAAW,EAAG,OAAO,KAGzC,MAAMG,EAAiBH,EAAM,OAASC,EACtC,IAAIG,EAAwDJ,EAE5D,GAAIG,EAAgB,CAClB,MAAME,EAAQL,EAAM,CAAC,EACfM,EAAUN,EAAM,MAAM,EAAE,EAC9BI,EAAe,CAACC,EAAO,CAAE,SAAU,EAAK,EAAG,GAAGC,CAAO,CACvD,CAEA,SACE,OAAC,OAAI,UAAWJ,EAAW,aAAW,aACpC,mBAAC,MAAG,UAAU,oBACX,SAAAE,EAAa,IAAI,CAACG,EAASC,IAAQ,CAElC,GAAI,aAAcD,GAAMA,EAAG,SACzB,SACE,OAAC,MAA2B,UAAU,4BACpC,mBAAC,QAAK,cAAW,GAAC,kBAAC,GADZ,YAAYC,CAAG,EAExB,EAGJ,MAAMC,EACJT,IAAQA,GAAO,OAAS,CAAC,GAAG,QAAUO,GAAI,OAASP,IAAQA,GAAO,OAAS,CAAC,GAAG,OAASO,GAAI,KACxFG,EAAM,GAAGH,EAAG,KAAK,IAAIC,CAAG,GAE9B,SACE,QAAC,MAAa,UAAU,uEAErB,UAAAA,IAAQ,MAAK,OAAC,QAAK,UAAU,sBAAsB,aAAC,EAEpDC,KACC,OAAC,QAAK,UAAU,WAAW,eAAa,OAAO,MAAOF,EAAG,MACtD,SAAAA,EAAG,MACN,KAEA,OAAC,EAAAI,QAAA,CACC,KAAMJ,EAAG,KACT,QAAS,CAACA,EAAG,KACb,MAAOA,EAAG,MACV,UAAU,uCAET,SAAAA,EAAG,MACN,IAhBKG,CAkBT,CAEJ,CAAC,EACH,EACF,CAEJ,EAEAhB,EAAW,YAAc,aAEzB,IAAOC,EAAQD",
6
+ "names": ["breadcrumb_exports", "__export", "Breadcrumb", "breadcrumb_default", "__toCommonJS", "import_jsx_runtime", "import_react", "import_link", "items", "maxItems", "className", "shouldTruncate", "visibleItems", "first", "lastTwo", "it", "idx", "isLast", "key", "Link"]
7
+ }
@@ -24,3 +24,4 @@ export { default as Picture } from './picture.js';
24
24
  export { default as Theme } from './theme.js';
25
25
  export { default as Board } from './board.js';
26
26
  export { default as LoadingDots } from './loadingDots.js';
27
+ export { default as Breadcrumb } from './breadcrumb.js';