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

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 (319) hide show
  1. package/dist/cjs/biz-components/AiuiProvider/index.d.ts +4 -0
  2. package/dist/cjs/biz-components/AiuiProvider/index.js +1 -1
  3. package/dist/cjs/biz-components/AiuiProvider/index.js.map +2 -2
  4. package/dist/cjs/biz-components/HeroBanner/Countdown.d.ts +9 -0
  5. package/dist/cjs/biz-components/HeroBanner/Countdown.js +2 -0
  6. package/dist/cjs/biz-components/HeroBanner/Countdown.js.map +7 -0
  7. package/dist/cjs/biz-components/HeroBanner/HeroBanner.js +1 -1
  8. package/dist/cjs/biz-components/HeroBanner/HeroBanner.js.map +3 -3
  9. package/dist/cjs/biz-components/HeroBanner/types.d.ts +6 -0
  10. package/dist/cjs/biz-components/HeroBanner/types.js.map +1 -1
  11. package/dist/cjs/biz-components/Listing/BizProductProvider.d.ts +118 -0
  12. package/dist/cjs/biz-components/Listing/BizProductProvider.js +2 -0
  13. package/dist/cjs/biz-components/Listing/BizProductProvider.js.map +7 -0
  14. package/dist/cjs/biz-components/Listing/components/PaidShipping/LearnMore.d.ts +2 -0
  15. package/dist/cjs/biz-components/Listing/components/PaidShipping/LearnMore.js +2 -0
  16. package/dist/cjs/biz-components/Listing/components/PaidShipping/LearnMore.js.map +7 -0
  17. package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingMethod.d.ts +10 -0
  18. package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingMethod.js +2 -0
  19. package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingMethod.js.map +7 -0
  20. package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.d.ts +25 -0
  21. package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.js +2 -0
  22. package/dist/cjs/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.js.map +7 -0
  23. package/dist/cjs/biz-components/Listing/components/PaidShipping/index.d.ts +12 -0
  24. package/dist/cjs/biz-components/Listing/components/PaidShipping/index.js +2 -0
  25. package/dist/cjs/biz-components/Listing/components/PaidShipping/index.js.map +7 -0
  26. package/dist/cjs/biz-components/Listing/components/PaidShipping/type.d.ts +30 -0
  27. package/dist/cjs/biz-components/Listing/components/PaidShipping/type.js +2 -0
  28. package/dist/cjs/biz-components/Listing/components/PaidShipping/type.js.map +7 -0
  29. package/dist/cjs/biz-components/Listing/components/PaidShipping/utils.d.ts +2 -0
  30. package/dist/cjs/biz-components/Listing/components/PaidShipping/utils.js +2 -0
  31. package/dist/cjs/biz-components/Listing/components/PaidShipping/utils.js.map +7 -0
  32. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts +37 -0
  33. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.js +40 -0
  34. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.js.map +7 -0
  35. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.d.ts +30 -0
  36. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js +2 -0
  37. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js.map +7 -0
  38. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.d.ts +2 -0
  39. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.js +2 -0
  40. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.js.map +7 -0
  41. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.d.ts +2 -0
  42. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js +2 -0
  43. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js.map +7 -0
  44. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.d.ts +2 -0
  45. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js +2 -0
  46. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js.map +7 -0
  47. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.d.ts +2 -0
  48. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js +2 -0
  49. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js.map +7 -0
  50. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.d.ts +2 -0
  51. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.js +2 -0
  52. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.js.map +7 -0
  53. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/index.d.ts +2 -0
  54. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/index.js +2 -0
  55. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/index.js.map +7 -0
  56. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/types.d.ts +43 -0
  57. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/types.js +2 -0
  58. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/types.js.map +7 -0
  59. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.d.ts +2 -0
  60. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.js +2 -0
  61. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.js.map +7 -0
  62. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.d.ts +21 -0
  63. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.js +2 -0
  64. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.js.map +7 -0
  65. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.d.ts +5 -0
  66. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.js +2 -0
  67. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.js.map +7 -0
  68. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.d.ts +1 -0
  69. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.js +2 -0
  70. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.js.map +7 -0
  71. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/index.d.ts +2 -0
  72. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/index.js +2 -0
  73. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/index.js.map +7 -0
  74. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/types.d.ts +37 -0
  75. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/types.js +2 -0
  76. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/types.js.map +7 -0
  77. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGridBox.d.ts +6 -0
  78. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGridBox.js +2 -0
  79. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGridBox.js.map +7 -0
  80. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.d.ts +3 -0
  81. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.js +2 -0
  82. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.js.map +7 -0
  83. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/types.d.ts +2 -0
  84. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/types.js +2 -0
  85. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/types.js.map +7 -0
  86. package/dist/cjs/biz-components/Listing/components/ProductCard/index.d.ts +2 -0
  87. package/dist/cjs/biz-components/Listing/components/ProductCard/index.js +2 -0
  88. package/dist/cjs/biz-components/Listing/components/ProductCard/index.js.map +7 -0
  89. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ProductActions/index.d.ts +2 -0
  90. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ProductActions/index.js +2 -0
  91. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ProductActions/index.js.map +7 -0
  92. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.d.ts +4 -0
  93. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.js +2 -0
  94. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.js.map +7 -0
  95. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.d.ts +10 -0
  96. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.js +2 -0
  97. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.js.map +7 -0
  98. package/dist/cjs/biz-components/Listing/components/PurchaseBar/index.d.ts +3 -0
  99. package/dist/cjs/biz-components/Listing/components/PurchaseBar/index.js +2 -0
  100. package/dist/cjs/biz-components/Listing/components/PurchaseBar/index.js.map +7 -0
  101. package/dist/cjs/biz-components/Listing/components/PurchaseBar/types.d.ts +12 -0
  102. package/dist/cjs/biz-components/Listing/components/PurchaseBar/types.js +2 -0
  103. package/dist/cjs/biz-components/Listing/components/PurchaseBar/types.js.map +7 -0
  104. package/dist/cjs/biz-components/Listing/components/index.d.ts +3 -0
  105. package/dist/cjs/biz-components/Listing/components/index.js +2 -0
  106. package/dist/cjs/biz-components/Listing/components/index.js.map +7 -0
  107. package/dist/cjs/biz-components/Listing/const.d.ts +29 -0
  108. package/dist/cjs/biz-components/Listing/const.js +2 -0
  109. package/dist/cjs/biz-components/Listing/const.js.map +7 -0
  110. package/dist/cjs/biz-components/Listing/hooks/use-options.d.ts +3 -0
  111. package/dist/cjs/biz-components/Listing/hooks/use-options.js +2 -0
  112. package/dist/cjs/biz-components/Listing/hooks/use-options.js.map +7 -0
  113. package/dist/cjs/biz-components/Listing/hooks/use-variant-media.d.ts +14 -0
  114. package/dist/cjs/biz-components/Listing/hooks/use-variant-media.js +2 -0
  115. package/dist/cjs/biz-components/Listing/hooks/use-variant-media.js.map +7 -0
  116. package/dist/cjs/biz-components/Listing/hooks/use-variant.d.ts +5 -0
  117. package/dist/cjs/biz-components/Listing/hooks/use-variant.js +2 -0
  118. package/dist/cjs/biz-components/Listing/hooks/use-variant.js.map +7 -0
  119. package/dist/cjs/biz-components/Listing/hooks/useBenefits.d.ts +50 -0
  120. package/dist/cjs/biz-components/Listing/hooks/useBenefits.js +2 -0
  121. package/dist/cjs/biz-components/Listing/hooks/useBenefits.js.map +7 -0
  122. package/dist/cjs/biz-components/Listing/hooks/useCopy.d.ts +5 -0
  123. package/dist/cjs/biz-components/Listing/hooks/useCopy.js +2 -0
  124. package/dist/cjs/biz-components/Listing/hooks/useCopy.js.map +7 -0
  125. package/dist/cjs/biz-components/Listing/index.d.ts +3 -0
  126. package/dist/cjs/biz-components/Listing/index.js +2 -0
  127. package/dist/cjs/biz-components/Listing/index.js.map +7 -0
  128. package/dist/cjs/biz-components/Listing/types/graphql.d.ts +7473 -0
  129. package/dist/cjs/biz-components/Listing/types/graphql.js +2 -0
  130. package/dist/cjs/biz-components/Listing/types/graphql.js.map +7 -0
  131. package/dist/cjs/biz-components/Listing/types/product.d.ts +141 -0
  132. package/dist/cjs/biz-components/Listing/types/product.js +2 -0
  133. package/dist/cjs/biz-components/Listing/types/product.js.map +7 -0
  134. package/dist/cjs/biz-components/Listing/types/productMetafields.d.js +2 -0
  135. package/dist/cjs/biz-components/Listing/types/productMetafields.d.js.map +7 -0
  136. package/dist/cjs/biz-components/Listing/types/type-helper.d.ts +5 -0
  137. package/dist/cjs/biz-components/Listing/types/type-helper.js +2 -0
  138. package/dist/cjs/biz-components/Listing/types/type-helper.js.map +7 -0
  139. package/dist/cjs/biz-components/Listing/types.d.ts +28 -0
  140. package/dist/cjs/biz-components/Listing/types.js +2 -0
  141. package/dist/cjs/biz-components/Listing/types.js.map +7 -0
  142. package/dist/cjs/biz-components/Listing/utils/helper.d.ts +36 -0
  143. package/dist/cjs/biz-components/Listing/utils/helper.js +2 -0
  144. package/dist/cjs/biz-components/Listing/utils/helper.js.map +7 -0
  145. package/dist/cjs/biz-components/Listing/utils/index.d.ts +37 -0
  146. package/dist/cjs/biz-components/Listing/utils/index.js +2 -0
  147. package/dist/cjs/biz-components/Listing/utils/index.js.map +7 -0
  148. package/dist/cjs/biz-components/Listing/utils/textFormat.d.ts +73 -0
  149. package/dist/cjs/biz-components/Listing/utils/textFormat.js +2 -0
  150. package/dist/cjs/biz-components/Listing/utils/textFormat.js.map +7 -0
  151. package/dist/cjs/biz-components/TabWithImage/TabWithImage.js +1 -1
  152. package/dist/cjs/biz-components/TabWithImage/TabWithImage.js.map +2 -2
  153. package/dist/cjs/biz-components/TabsWithMedia/TabsWithMedia.js.map +2 -2
  154. package/dist/cjs/biz-components/index.d.ts +17 -0
  155. package/dist/cjs/biz-components/index.js +1 -1
  156. package/dist/cjs/biz-components/index.js.map +3 -3
  157. package/dist/cjs/components/checkbox.d.ts +1 -0
  158. package/dist/cjs/components/checkbox.js +1 -1
  159. package/dist/cjs/components/checkbox.js.map +3 -3
  160. package/dist/esm/biz-components/AiuiProvider/index.d.ts +4 -0
  161. package/dist/esm/biz-components/AiuiProvider/index.js +1 -1
  162. package/dist/esm/biz-components/AiuiProvider/index.js.map +2 -2
  163. package/dist/esm/biz-components/HeroBanner/Countdown.d.ts +9 -0
  164. package/dist/esm/biz-components/HeroBanner/Countdown.js +2 -0
  165. package/dist/esm/biz-components/HeroBanner/Countdown.js.map +7 -0
  166. package/dist/esm/biz-components/HeroBanner/HeroBanner.js +1 -1
  167. package/dist/esm/biz-components/HeroBanner/HeroBanner.js.map +3 -3
  168. package/dist/esm/biz-components/HeroBanner/types.d.ts +6 -0
  169. package/dist/esm/biz-components/Listing/BizProductProvider.d.ts +118 -0
  170. package/dist/esm/biz-components/Listing/BizProductProvider.js +2 -0
  171. package/dist/esm/biz-components/Listing/BizProductProvider.js.map +7 -0
  172. package/dist/esm/biz-components/Listing/components/PaidShipping/LearnMore.d.ts +2 -0
  173. package/dist/esm/biz-components/Listing/components/PaidShipping/LearnMore.js +2 -0
  174. package/dist/esm/biz-components/Listing/components/PaidShipping/LearnMore.js.map +7 -0
  175. package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingMethod.d.ts +10 -0
  176. package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingMethod.js +2 -0
  177. package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingMethod.js.map +7 -0
  178. package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.d.ts +25 -0
  179. package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.js +2 -0
  180. package/dist/esm/biz-components/Listing/components/PaidShipping/ShippingPolicyModal.js.map +7 -0
  181. package/dist/esm/biz-components/Listing/components/PaidShipping/index.d.ts +12 -0
  182. package/dist/esm/biz-components/Listing/components/PaidShipping/index.js +2 -0
  183. package/dist/esm/biz-components/Listing/components/PaidShipping/index.js.map +7 -0
  184. package/dist/esm/biz-components/Listing/components/PaidShipping/type.d.ts +30 -0
  185. package/dist/esm/biz-components/Listing/components/PaidShipping/type.js +2 -0
  186. package/dist/esm/biz-components/Listing/components/PaidShipping/type.js.map +7 -0
  187. package/dist/esm/biz-components/Listing/components/PaidShipping/utils.d.ts +2 -0
  188. package/dist/esm/biz-components/Listing/components/PaidShipping/utils.js +2 -0
  189. package/dist/esm/biz-components/Listing/components/PaidShipping/utils.js.map +7 -0
  190. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts +37 -0
  191. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.js +40 -0
  192. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.js.map +7 -0
  193. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.d.ts +30 -0
  194. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js +2 -0
  195. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js.map +7 -0
  196. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.d.ts +2 -0
  197. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.js +2 -0
  198. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.js.map +7 -0
  199. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.d.ts +2 -0
  200. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js +2 -0
  201. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js.map +7 -0
  202. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.d.ts +2 -0
  203. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js +2 -0
  204. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js.map +7 -0
  205. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.d.ts +2 -0
  206. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js +2 -0
  207. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js.map +7 -0
  208. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.d.ts +2 -0
  209. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.js +2 -0
  210. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.js.map +7 -0
  211. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/index.d.ts +2 -0
  212. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/index.js +2 -0
  213. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/index.js.map +7 -0
  214. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/types.d.ts +43 -0
  215. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/types.js +2 -0
  216. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/types.js.map +7 -0
  217. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.d.ts +2 -0
  218. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.js +2 -0
  219. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.js.map +7 -0
  220. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.d.ts +21 -0
  221. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.js +2 -0
  222. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.js.map +7 -0
  223. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.d.ts +5 -0
  224. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.js +2 -0
  225. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.js.map +7 -0
  226. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.d.ts +1 -0
  227. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.js +2 -0
  228. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.js.map +7 -0
  229. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/index.d.ts +2 -0
  230. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/index.js +2 -0
  231. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/index.js.map +7 -0
  232. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/types.d.ts +37 -0
  233. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/types.js +2 -0
  234. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/types.js.map +7 -0
  235. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGridBox.d.ts +6 -0
  236. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGridBox.js +2 -0
  237. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGridBox.js.map +7 -0
  238. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.d.ts +3 -0
  239. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.js +2 -0
  240. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.js.map +7 -0
  241. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/types.d.ts +2 -0
  242. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/types.js +1 -0
  243. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/types.js.map +7 -0
  244. package/dist/esm/biz-components/Listing/components/ProductCard/index.d.ts +2 -0
  245. package/dist/esm/biz-components/Listing/components/ProductCard/index.js +2 -0
  246. package/dist/esm/biz-components/Listing/components/ProductCard/index.js.map +7 -0
  247. package/dist/esm/biz-components/Listing/components/PurchaseBar/ProductActions/index.d.ts +2 -0
  248. package/dist/esm/biz-components/Listing/components/PurchaseBar/ProductActions/index.js +2 -0
  249. package/dist/esm/biz-components/Listing/components/PurchaseBar/ProductActions/index.js.map +7 -0
  250. package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.d.ts +4 -0
  251. package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.js +2 -0
  252. package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/index.js.map +7 -0
  253. package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.d.ts +10 -0
  254. package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.js +1 -0
  255. package/dist/esm/biz-components/Listing/components/PurchaseBar/ScrollSpyNav/types.js.map +7 -0
  256. package/dist/esm/biz-components/Listing/components/PurchaseBar/index.d.ts +3 -0
  257. package/dist/esm/biz-components/Listing/components/PurchaseBar/index.js +2 -0
  258. package/dist/esm/biz-components/Listing/components/PurchaseBar/index.js.map +7 -0
  259. package/dist/esm/biz-components/Listing/components/PurchaseBar/types.d.ts +12 -0
  260. package/dist/esm/biz-components/Listing/components/PurchaseBar/types.js +1 -0
  261. package/dist/esm/biz-components/Listing/components/PurchaseBar/types.js.map +7 -0
  262. package/dist/esm/biz-components/Listing/components/index.d.ts +3 -0
  263. package/dist/esm/biz-components/Listing/components/index.js +2 -0
  264. package/dist/esm/biz-components/Listing/components/index.js.map +7 -0
  265. package/dist/esm/biz-components/Listing/const.d.ts +29 -0
  266. package/dist/esm/biz-components/Listing/const.js +2 -0
  267. package/dist/esm/biz-components/Listing/const.js.map +7 -0
  268. package/dist/esm/biz-components/Listing/hooks/use-options.d.ts +3 -0
  269. package/dist/esm/biz-components/Listing/hooks/use-options.js +2 -0
  270. package/dist/esm/biz-components/Listing/hooks/use-options.js.map +7 -0
  271. package/dist/esm/biz-components/Listing/hooks/use-variant-media.d.ts +14 -0
  272. package/dist/esm/biz-components/Listing/hooks/use-variant-media.js +2 -0
  273. package/dist/esm/biz-components/Listing/hooks/use-variant-media.js.map +7 -0
  274. package/dist/esm/biz-components/Listing/hooks/use-variant.d.ts +5 -0
  275. package/dist/esm/biz-components/Listing/hooks/use-variant.js +2 -0
  276. package/dist/esm/biz-components/Listing/hooks/use-variant.js.map +7 -0
  277. package/dist/esm/biz-components/Listing/hooks/useBenefits.d.ts +50 -0
  278. package/dist/esm/biz-components/Listing/hooks/useBenefits.js +2 -0
  279. package/dist/esm/biz-components/Listing/hooks/useBenefits.js.map +7 -0
  280. package/dist/esm/biz-components/Listing/hooks/useCopy.d.ts +5 -0
  281. package/dist/esm/biz-components/Listing/hooks/useCopy.js +2 -0
  282. package/dist/esm/biz-components/Listing/hooks/useCopy.js.map +7 -0
  283. package/dist/esm/biz-components/Listing/index.d.ts +3 -0
  284. package/dist/esm/biz-components/Listing/index.js +2 -0
  285. package/dist/esm/biz-components/Listing/index.js.map +7 -0
  286. package/dist/esm/biz-components/Listing/types/graphql.d.ts +7473 -0
  287. package/dist/esm/biz-components/Listing/types/graphql.js +2 -0
  288. package/dist/esm/biz-components/Listing/types/graphql.js.map +7 -0
  289. package/dist/esm/biz-components/Listing/types/product.d.ts +141 -0
  290. package/dist/esm/biz-components/Listing/types/product.js +2 -0
  291. package/dist/esm/biz-components/Listing/types/product.js.map +7 -0
  292. package/dist/esm/biz-components/Listing/types/productMetafields.d.js +2 -0
  293. package/dist/esm/biz-components/Listing/types/productMetafields.d.js.map +7 -0
  294. package/dist/esm/biz-components/Listing/types/type-helper.d.ts +5 -0
  295. package/dist/esm/biz-components/Listing/types/type-helper.js +1 -0
  296. package/dist/esm/biz-components/Listing/types/type-helper.js.map +7 -0
  297. package/dist/esm/biz-components/Listing/types.d.ts +28 -0
  298. package/dist/esm/biz-components/Listing/types.js +1 -0
  299. package/dist/esm/biz-components/Listing/types.js.map +7 -0
  300. package/dist/esm/biz-components/Listing/utils/helper.d.ts +36 -0
  301. package/dist/esm/biz-components/Listing/utils/helper.js +2 -0
  302. package/dist/esm/biz-components/Listing/utils/helper.js.map +7 -0
  303. package/dist/esm/biz-components/Listing/utils/index.d.ts +37 -0
  304. package/dist/esm/biz-components/Listing/utils/index.js +2 -0
  305. package/dist/esm/biz-components/Listing/utils/index.js.map +7 -0
  306. package/dist/esm/biz-components/Listing/utils/textFormat.d.ts +73 -0
  307. package/dist/esm/biz-components/Listing/utils/textFormat.js +2 -0
  308. package/dist/esm/biz-components/Listing/utils/textFormat.js.map +7 -0
  309. package/dist/esm/biz-components/TabWithImage/TabWithImage.js +1 -1
  310. package/dist/esm/biz-components/TabWithImage/TabWithImage.js.map +2 -2
  311. package/dist/esm/biz-components/TabsWithMedia/TabsWithMedia.js.map +2 -2
  312. package/dist/esm/biz-components/index.d.ts +17 -0
  313. package/dist/esm/biz-components/index.js +1 -1
  314. package/dist/esm/biz-components/index.js.map +2 -2
  315. package/dist/esm/components/checkbox.d.ts +1 -0
  316. package/dist/esm/components/checkbox.js +1 -1
  317. package/dist/esm/components/checkbox.js.map +3 -3
  318. package/dist/tokens/base.css +1 -1
  319. package/package.json +1 -1
@@ -0,0 +1,2 @@
1
+ declare const ProductDetail: (props: any) => import("react/jsx-runtime").JSX.Element;
2
+ export default ProductDetail;
@@ -0,0 +1,2 @@
1
+ "use strict";var n=Object.create;var d=Object.defineProperty;var x=Object.getOwnPropertyDescriptor;var P=Object.getOwnPropertyNames;var b=Object.getPrototypeOf,g=Object.prototype.hasOwnProperty;var B=(o,t)=>{for(var r in t)d(o,r,{get:t[r],enumerable:!0})},m=(o,t,r,f)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of P(t))!g.call(o,i)&&i!==r&&d(o,i,{get:()=>t[i],enumerable:!(f=x(t,i))||f.enumerable});return o};var e=(o,t,r)=>(r=o!=null?n(b(o)):{},m(t||!o||!o.__esModule?d(r,"default",{value:o,enumerable:!0}):r,o)),h=o=>m(d({},"__esModule",{value:!0}),o);var k={};B(k,{default:()=>T});module.exports=h(k);var p=require("react/jsx-runtime"),D=require("./ProductBenefitsTabs/index.js"),l=e(require("./ProductHighlight/index.js")),a=e(require("./ProductFreeGift/index.js")),c=e(require("./ProductOptions/index.js")),u=e(require("./ProductBundle/index.js")),s=e(require("./BenefitsTab"));const v=o=>(0,p.jsxs)("div",{id:"ipc-product-detail",className:"flex flex-col gap-12 tablet:px-8 laptop:px-16 desktop:px-0 px-4",children:[(0,p.jsx)(s.default,{}),(0,p.jsx)(l.default,{}),(0,p.jsx)(c.default,{}),(0,p.jsx)(a.default,{}),(0,p.jsx)(u.default,{})]});var T=v;
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../src/biz-components/Listing/components/ProductCard/ProductDetail/index.tsx"],
4
+ "sourcesContent": ["import ProductBenefitsTabs from './ProductBenefitsTabs/index.js'\nimport ProductHighlight from './ProductHighlight/index.js'\nimport ProductFreeGift from './ProductFreeGift/index.js'\nimport ProductOptions from './ProductOptions/index.js'\nimport ProductBundle from './ProductBundle/index.js'\nimport BenefitsTab from './BenefitsTab'\n\n\nconst ProductDetail = (props: any) => {\n return (\n <div id=\"ipc-product-detail\" className=\"flex flex-col gap-12 tablet:px-8 laptop:px-16 desktop:px-0 px-4\">\n <BenefitsTab />\n <ProductHighlight />\n <ProductOptions />\n <ProductFreeGift />\n <ProductBundle />\n </div>\n )\n}\n\nexport default ProductDetail\n"],
5
+ "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GAUI,IAAAI,EAAA,6BAVJC,EAAgC,0CAChCC,EAA6B,0CAC7BC,EAA4B,yCAC5BC,EAA2B,wCAC3BC,EAA0B,uCAC1BC,EAAwB,4BAGxB,MAAMC,EAAiBC,MAEnB,QAAC,OAAI,GAAG,qBAAqB,UAAU,kEACrC,oBAAC,EAAAC,QAAA,EAAY,KACb,OAAC,EAAAC,QAAA,EAAiB,KAClB,OAAC,EAAAC,QAAA,EAAe,KAChB,OAAC,EAAAC,QAAA,EAAgB,KACjB,OAAC,EAAAC,QAAA,EAAc,GACjB,EAIJ,IAAOf,EAAQS",
6
+ "names": ["ProductDetail_exports", "__export", "ProductDetail_default", "__toCommonJS", "import_jsx_runtime", "import_ProductBenefitsTabs", "import_ProductHighlight", "import_ProductFreeGift", "import_ProductOptions", "import_ProductBundle", "import_BenefitsTab", "ProductDetail", "props", "BenefitsTab", "ProductHighlight", "ProductOptions", "ProductFreeGift", "ProductBundle"]
7
+ }
@@ -0,0 +1,43 @@
1
+ import type { ProductOption } from '../../../../../cpn-components/CpnProductCard/types.js';
2
+ import type { Img } from '../../../../../types/props.js';
3
+ export interface ProductDetailProps {
4
+ }
5
+ export declare enum BenefitsTabsType {
6
+ ALL_BENEFITS = "allBenefits",
7
+ COUPON = "coupon",
8
+ INSTALLMENT = "installment",
9
+ MEMBERSHIP = "membership"
10
+ }
11
+ export interface ProductBenefitsTabsProps {
12
+ data: {
13
+ allBenefits: {
14
+ benefits: {
15
+ type?: BenefitsTabsType;
16
+ tabName: string;
17
+ tabValue: string;
18
+ collectBgImage?: Img;
19
+ coupons?: BenefitsTabCouponProps[];
20
+ }[];
21
+ };
22
+ };
23
+ }
24
+ export interface BenefitsTabCouponProps {
25
+ code: string;
26
+ title: string;
27
+ description: string;
28
+ discount: number;
29
+ bgImage: Img;
30
+ }
31
+ export interface ProductBenefitsTabCouponProps {
32
+ coupons?: BenefitsTabCouponProps[];
33
+ }
34
+ export interface HighlightProps {
35
+ data: any;
36
+ }
37
+ export interface ProductOptionsProps {
38
+ option: ProductOption;
39
+ onOptionChange: (arg0: {
40
+ id: string;
41
+ value: string;
42
+ }) => void;
43
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";var n=Object.defineProperty;var s=Object.getOwnPropertyDescriptor;var a=Object.getOwnPropertyNames;var c=Object.prototype.hasOwnProperty;var u=(e,o)=>{for(var r in o)n(e,r,{get:o[r],enumerable:!0})},P=(e,o,r,p)=>{if(o&&typeof o=="object"||typeof o=="function")for(let t of a(o))!c.call(e,t)&&t!==r&&n(e,t,{get:()=>o[t],enumerable:!(p=s(o,t))||p.enumerable});return e};var d=e=>P(n({},"__esModule",{value:!0}),e);var g={};u(g,{BenefitsTabsType:()=>i});module.exports=d(g);var i=(t=>(t.ALL_BENEFITS="allBenefits",t.COUPON="coupon",t.INSTALLMENT="installment",t.MEMBERSHIP="membership",t))(i||{});
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../src/biz-components/Listing/components/ProductCard/ProductDetail/types.ts"],
4
+ "sourcesContent": ["import type {\n ProductVariant,\n Product,\n ProductOption,\n ProductOptionValues,\n} from '../../../../../cpn-components/CpnProductCard/types.js'\nimport type { Img } from '../../../../../types/props.js'\n\nexport interface ProductDetailProps {}\n\nexport enum BenefitsTabsType {\n ALL_BENEFITS = 'allBenefits',\n COUPON = 'coupon',\n INSTALLMENT = 'installment',\n MEMBERSHIP = 'membership',\n}\n\nexport interface ProductBenefitsTabsProps {\n data: {\n allBenefits: {\n benefits: {\n type?: BenefitsTabsType\n tabName: string\n tabValue: string\n collectBgImage?: Img\n coupons?: BenefitsTabCouponProps[]\n }[]\n }\n }\n}\n\nexport interface BenefitsTabCouponProps {\n code: string\n title: string\n description: string\n discount: number\n bgImage: Img\n}\n\nexport interface ProductBenefitsTabCouponProps {\n coupons?: BenefitsTabCouponProps[]\n}\n\nexport interface HighlightProps {\n data: any\n}\n\nexport interface ProductOptionsProps {\n option: ProductOption\n onOptionChange: (arg0: { id: string; value: string }) => void\n}\n"],
5
+ "mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,sBAAAE,IAAA,eAAAC,EAAAH,GAUO,IAAKE,OACVA,EAAA,aAAe,cACfA,EAAA,OAAS,SACTA,EAAA,YAAc,cACdA,EAAA,WAAa,aAJHA,OAAA",
6
+ "names": ["types_exports", "__export", "BenefitsTabsType", "__toCommonJS"]
7
+ }
@@ -0,0 +1,2 @@
1
+ declare const CompareModal: () => import("react/jsx-runtime").JSX.Element | null;
2
+ export default CompareModal;
@@ -0,0 +1,2 @@
1
+ "use strict";var y=Object.create;var c=Object.defineProperty;var h=Object.getOwnPropertyDescriptor;var D=Object.getOwnPropertyNames;var G=Object.getPrototypeOf,w=Object.prototype.hasOwnProperty;var I=(r,a)=>{for(var i in a)c(r,i,{get:a[i],enumerable:!0})},g=(r,a,i,p)=>{if(a&&typeof a=="object"||typeof a=="function")for(let l of D(a))!w.call(r,l)&&l!==i&&c(r,l,{get:()=>a[l],enumerable:!(p=h(a,l))||p.enumerable});return r};var k=(r,a,i)=>(i=r!=null?y(G(r)):{},g(a||!r||!r.__esModule?c(i,"default",{value:r,enumerable:!0}):i,r)),P=r=>g(c({},"__esModule",{value:!0}),r);var H={};I(H,{default:()=>L});module.exports=P(H);var e=require("react/jsx-runtime"),n=require("react"),t=require("../../../../../../components"),b=require("../../../../BizProductProvider"),v=k(require("./Select")),N=require("../../../../../AiuiProvider/index.js"),C=require("../../../../utils"),E=require("./ShopifyColorOption");const T=()=>{const{locale:r="us"}=(0,N.useAiuiContext)(),{compareData:a,product:i}=(0,b.useBizProductContext)(),[p,l]=(0,n.useState)();(0,n.useEffect)(()=>{l(a?.availableCompareList[0]?.handle)},[a?.availableCompareList]);const x=[a?.currentProductCompareData?.product,a?.availableCompareList.find(o=>o.handle===p)?.product].filter(Boolean);return a?.specificationKeys?(0,e.jsxs)(t.Dialog,{children:[(0,e.jsx)(t.DialogTrigger,{children:(0,e.jsx)("button",{className:"text-base leading-[1.4] font-bold",children:"Compare"})}),(0,e.jsxs)(t.DialogContent,{overlayClassName:"z-[100]",className:"max-h-[calc(100vh-92px)] z-[110] overflow-y-scroll px-[40px] py-[30px] shadow-lg tablet:min-w-[760px] min-w-[90vw]",children:[(0,e.jsx)(t.DialogHeader,{className:"border-b border-[#E8E8E8]",children:(0,e.jsx)(t.DialogTitle,{children:"Compare"})}),(0,e.jsxs)(t.Grid,{className:"gap-[40px] grid-cols-3 items-center gap-[40px] border-b border-[#E8E8E8] py-[24px]",children:[(0,e.jsx)(t.GridItem,{span:1}),x.map((o,d)=>(0,e.jsx)(t.GridItem,{span:1,className:"flex items-center",children:(0,e.jsx)("img",{src:o.images[0].url,alt:o.title,className:"h-[200px] w-[200px]",role:"presentation"})},d))]}),(0,e.jsxs)(t.Grid,{className:"gap-[40px] grid-cols-3 items-center gap-[40px] border-b border-[#E8E8E8] py-[24px]",children:[(0,e.jsx)(t.GridItem,{span:1,children:(0,e.jsx)("div",{className:"text-[16px] font-bold text-[#595959]",children:"Product"})}),(0,e.jsx)(t.GridItem,{span:1,children:(0,e.jsx)(t.Text,{as:"div",className:"flex h-[38px] w-full items-center rounded-[2px] border border-[#E8E8E8] px-[12px] text-[16px] font-bold",html:a.currentProductCompareData?.shortName||i.title})}),p&&(0,e.jsx)(t.GridItem,{span:1,children:(0,e.jsx)(v.default,{value:p,onChange:o=>{l(o)},list:a.options})})]}),(0,e.jsxs)(t.Grid,{className:"gap-[40px] grid-cols-3 items-center gap-[40px] border-b border-[#E8E8E8] py-[24px]",children:[(0,e.jsx)(t.GridItem,{span:1,children:(0,e.jsx)("div",{className:"text-[16px] font-bold text-[#595959]",children:"Basic Information"})}),x.map((o,d)=>{const m=o.variants[0],f=o.options?.find(s=>["color","colour","couleur"].find(u=>s.name.toLowerCase().includes(u)))?.values.map(s=>s.label);return(0,e.jsx)(t.GridItem,{span:1,className:"flex h-full",children:(0,e.jsxs)("div",{className:"flex flex-col gap-[8px]",children:[m.price.amount<9999999&&(0,e.jsxs)("div",{className:"flex items-center gap-[8px]",children:[(0,e.jsx)("div",{className:"text-[16px] font-semibold text-[#595959]",children:"Price:"}),(0,e.jsx)("div",{className:"flex items-center gap-[6px]",children:(0,e.jsx)("span",{className:"text-[16px] font-bold",children:(0,C.formatPrice)({locale:r,amount:m.price.amount,currencyCode:m.price.currencyCode})})})]}),f?.length&&(0,e.jsxs)("div",{className:"flex items-center gap-[8px]",children:[(0,e.jsx)("div",{className:"text-[16px] font-semibold text-[#595959]",children:"Color:"}),(0,e.jsx)("div",{className:"flex items-center gap-[16px]",children:f.map(s=>(0,e.jsx)(E.ShopifyColorOption,{label:s,className:"h-[16px] w-[16px]"},s))})]})]})},d)})]}),(0,e.jsx)(t.Grid,{className:"gap-[40px] grid-cols-12 items-center gap-[40px] border-b border-[#E8E8E8]",children:a.specificationKeys?.map(o=>(0,e.jsxs)(t.GridItem,{span:12,className:"grid grid-cols-3 items-center gap-[40px] border-b border-[#E8E8E8] py-[24px]",children:[(0,e.jsx)("div",{className:"text-[16px] font-bold text-[#595959]",children:o}),x.map((d,m)=>{let s=d.metafields?.global?.specifications?.find(u=>u?.key===o)?.value||"";switch(s.trim().toLowerCase()){case"true":s="\u2714\uFE0F";break;case"false":s="\u274C";break;default:break}return(0,e.jsx)("div",{className:"flex items-center",children:(0,e.jsx)("div",{className:"text-[16px] font-semibold text-[#595959]",children:s})},m)})]},o))})]})]}):null};var L=T;
2
+ //# sourceMappingURL=CompareModal.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../../src/biz-components/Listing/components/ProductCard/ProductGallery/components/CompareModal.tsx"],
4
+ "sourcesContent": ["import { useEffect, useState } from 'react'\nimport {\n Dialog,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogTitle,\n Grid,\n GridItem,\n Text,\n} from '../../../../../../components'\nimport { useBizProductContext } from '../../../../BizProductProvider'\nimport type { CompareItem } from '../../../../types'\nimport Select from './Select'\nimport { useAiuiContext } from '../../../../../AiuiProvider/index.js'\nimport { formatPrice } from '../../../../utils'\nimport { ShopifyColorOption } from './ShopifyColorOption'\n\nconst CompareModal = () => {\n const { locale = 'us' } = useAiuiContext()\n const { compareData, product } = useBizProductContext()\n const [selectedProductHandle, setSelectedProductHandle] = useState<string>()\n\n useEffect(() => {\n setSelectedProductHandle(compareData?.availableCompareList[0]?.handle)\n }, [compareData?.availableCompareList])\n\n const products = [\n compareData?.currentProductCompareData!?.product,\n compareData?.availableCompareList.find(product => product.handle === selectedProductHandle)?.product,\n ].filter(Boolean) as CompareItem['product'][]\n\n if (!compareData?.specificationKeys) return null\n\n return (\n <Dialog>\n <DialogTrigger>\n <button className=\"text-base leading-[1.4] font-bold\">Compare</button>\n </DialogTrigger>\n <DialogContent\n overlayClassName=\"z-[100]\"\n className=\"max-h-[calc(100vh-92px)] z-[110] overflow-y-scroll px-[40px] py-[30px] shadow-lg tablet:min-w-[760px] min-w-[90vw]\"\n >\n <DialogHeader className=\"border-b border-[#E8E8E8]\">\n <DialogTitle>Compare</DialogTitle>\n </DialogHeader>\n <Grid className=\"gap-[40px] grid-cols-3 items-center gap-[40px] border-b border-[#E8E8E8] py-[24px]\">\n <GridItem span={1} />\n {products.map((product, productIndex) => {\n return (\n <GridItem key={productIndex} span={1} className=\"flex items-center\">\n <img\n src={product.images[0].url}\n alt={product.title}\n className=\"h-[200px] w-[200px]\"\n role=\"presentation\"\n />\n </GridItem>\n )\n })}\n </Grid>\n <Grid className=\"gap-[40px] grid-cols-3 items-center gap-[40px] border-b border-[#E8E8E8] py-[24px]\">\n <GridItem span={1}>\n <div className=\"text-[16px] font-bold text-[#595959]\">Product</div>\n </GridItem>\n <GridItem span={1}>\n <Text\n as=\"div\"\n className=\"flex h-[38px] w-full items-center rounded-[2px] border border-[#E8E8E8] px-[12px] text-[16px] font-bold\"\n html={compareData.currentProductCompareData?.shortName || product.title}\n ></Text>\n </GridItem>\n {selectedProductHandle && (\n <GridItem span={1}>\n <Select\n value={selectedProductHandle}\n onChange={value => {\n setSelectedProductHandle(value)\n }}\n list={compareData.options!}\n />\n </GridItem>\n )}\n </Grid>\n <Grid className=\"gap-[40px] grid-cols-3 items-center gap-[40px] border-b border-[#E8E8E8] py-[24px]\">\n <GridItem span={1}>\n <div className=\"text-[16px] font-bold text-[#595959]\">Basic Information</div>\n </GridItem>\n {products.map((product, productIndex) => {\n const variant = product.variants[0]\n const colors = product.options\n ?.find(option =>\n ['color', 'colour', 'couleur'].find(predicate => option.name.toLowerCase().includes(predicate))\n )\n ?.values.map(value => value.label)\n return (\n <GridItem span={1} key={productIndex} className=\"flex h-full\">\n {/* Price with original price */}\n <div className=\"flex flex-col gap-[8px]\">\n {variant.price.amount < 9999999 && (\n <div className=\"flex items-center gap-[8px]\">\n <div className=\"text-[16px] font-semibold text-[#595959]\">Price:</div>\n <div className=\"flex items-center gap-[6px]\">\n <span className=\"text-[16px] font-bold\">\n {formatPrice({\n locale,\n amount: variant.price.amount,\n currencyCode: variant.price.currencyCode,\n })}\n </span>\n\n {/* {Number(coupon?.fixed_value) > 0 && (\n <span className='font-semibold text-[#999999] line-through'>\n {formatPrice({\n locale,\n amount: variant.price.amount,\n currencyCode: variant.price.currencyCode,\n })}\n </span>\n )} */}\n </div>\n </div>\n )}\n {colors?.length && (\n <div className=\"flex items-center gap-[8px]\">\n <div className=\"text-[16px] font-semibold text-[#595959]\">Color:</div>\n <div className=\"flex items-center gap-[16px]\">\n {colors.map(label => (\n <ShopifyColorOption key={label} label={label} className=\"h-[16px] w-[16px]\" />\n ))}\n </div>\n </div>\n )}\n </div>\n </GridItem>\n )\n })}\n </Grid>\n <Grid className=\"gap-[40px] grid-cols-12 items-center gap-[40px] border-b border-[#E8E8E8]\">\n {compareData.specificationKeys?.map((key: string) => {\n return (\n <GridItem\n span={12}\n className=\"grid grid-cols-3 items-center gap-[40px] border-b border-[#E8E8E8] py-[24px]\"\n key={key}\n >\n {/* Detail value */}\n <div className=\"text-[16px] font-bold text-[#595959]\">{key}</div>\n {/* Product Values */}\n {products.map((product, productIndex) => {\n const value =\n product.metafields?.global?.specifications?.find(\n (specification: { key: string }) => specification?.key === key\n )?.value || ''\n let text = value\n switch (text.trim().toLowerCase()) {\n case 'true':\n text = '\u2714\uFE0F'\n break\n case 'false':\n text = '\u274C'\n break\n default:\n break\n }\n return (\n <div key={productIndex} className=\"flex items-center\">\n {/* Other details */}\n <div className=\"text-[16px] font-semibold text-[#595959]\">{text}</div>\n </div>\n )\n })}\n </GridItem>\n )\n })}\n </Grid>\n </DialogContent>\n </Dialog>\n )\n}\n\nexport default CompareModal\n"],
5
+ "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GAqCQ,IAAAI,EAAA,6BArCRC,E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e,MAAQF,CAC7D,GAAG,OAAS,GAEd,OAAQC,EAAK,KAAK,EAAE,YAAY,EAAG,CACjC,IAAK,OACHA,EAAO,eACP,MACF,IAAK,QACHA,EAAO,SACP,MACF,QACE,KACJ,CACA,SACE,OAAC,OAAuB,UAAU,oBAEhC,mBAAC,OAAI,UAAU,2CAA4C,SAAAA,EAAK,GAFxDT,CAGV,CAEJ,CAAC,IA3BIQ,CA4BP,CAEH,EACH,GACF,GACF,EAjJ0C,IAmJ9C,EAEA,IAAOzB,EAAQU",
6
+ "names": ["CompareModal_exports", "__export", "CompareModal_default", "__toCommonJS", "import_jsx_runtime", "import_react", "import_components", "import_BizProductProvider", "import_Select", "import_AiuiProvider", "import_utils", "import_ShopifyColorOption", "CompareModal", "locale", "compareData", "product", "selectedProductHandle", "setSelectedProductHandle", "products", "productIndex", "Select", "value", "variant", "colors", "option", "predicate", "label", "key", "text", "specification"]
7
+ }
@@ -0,0 +1,21 @@
1
+ interface SelectProps {
2
+ label?: string;
3
+ required?: boolean;
4
+ list?: {
5
+ value: string;
6
+ text: string;
7
+ disabled?: boolean;
8
+ }[];
9
+ value?: string;
10
+ disabled?: boolean;
11
+ error?: string;
12
+ errorClassName?: string;
13
+ onChange?: (value: string) => void;
14
+ placeholder?: string;
15
+ className?: string;
16
+ containerClassName?: string;
17
+ selectListClassName?: string;
18
+ truncate?: boolean;
19
+ }
20
+ declare const Select: ({ label, required, list, value, disabled, error, errorClassName, onChange, placeholder, className, containerClassName, selectListClassName, truncate, ...props }: SelectProps) => import("react/jsx-runtime").JSX.Element;
21
+ export default Select;
@@ -0,0 +1,2 @@
1
+ "use strict";var v=Object.defineProperty;var C=Object.getOwnPropertyDescriptor;var D=Object.getOwnPropertyNames;var S=Object.prototype.hasOwnProperty;var L=(a,n)=>{for(var s in n)v(a,s,{get:n[s],enumerable:!0})},R=(a,n,s,l)=>{if(n&&typeof n=="object"||typeof n=="function")for(let r of D(n))!S.call(a,r)&&r!==s&&v(a,r,{get:()=>n[r],enumerable:!(l=C(n,r))||l.enumerable});return a};var _=a=>R(v({},"__esModule",{value:!0}),a);var H={};L(H,{default:()=>M});module.exports=_(H);var t=require("react/jsx-runtime"),g=require("@heroicons/react/24/outline"),o=require("../../../../../../helpers"),i=require("react");const I=({label:a="",required:n=!1,list:s=[],value:l="",disabled:r=!1,error:d="",errorClassName:h="",onChange:m=b=>{},placeholder:p="",className:w="",containerClassName:N="",selectListClassName:E="",truncate:F=!1,...k})=>{const b=(0,i.useRef)(null),[x,u]=(0,i.useState)(!1),f=(0,i.useRef)(null),y=s.find(e=>e?.value===l)?.text;return(0,i.useEffect)(()=>{const e=c=>{f.current&&!f.current?.contains(c.target)&&u(!1)};return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[]),(0,t.jsxs)("div",{className:(0,o.cn)("relative w-full",N),children:[a&&(0,t.jsxs)("div",{className:"mb-[10px] text-[16px] font-bold",children:[a,n&&(0,t.jsx)("span",{className:"text-[#F84D4F]",children:"*"})]}),(0,t.jsxs)("div",{ref:f,className:"relative block",children:[(0,t.jsxs)("div",{className:(0,o.cn)("flex h-[38px] w-full cursor-pointer items-center justify-between rounded-[2px] border px-[12px] text-[16px] font-bold transition-all x:text-[14px]",p&&!l?"placeholder:text-[#999]":"",r?"pointer-events-none bg-[#F7F8F9]":"bg-white",d?"!border-[#F84D4F]":"border-[#E8E8E8]",s.length<=1&&"cursor-default",w),onClick:()=>{s.length>1&&u(!x)},onChange:e=>{m(e.target.value)},role:"button",tabIndex:0,onKeyDown:e=>{(e.key==="Enter"||e.key===" ")&&e.preventDefault()},...k,children:[!l&&p?(0,t.jsx)("div",{className:"text-[#999]",children:p}):(0,t.jsx)("div",{className:(0,o.cn)("line-clamp-1",F?"min-w-0 flex-1 truncate":"flex-1"),children:y}),s.length>1&&(0,t.jsx)(g.ChevronDownIcon,{className:(0,o.cn)("ml-[4px] h-[18px] w-[18px] flex-shrink-0 stroke-[#999999] transition-transform",x&&"rotate-180")})]}),(0,t.jsx)("div",{ref:b,className:(0,o.cn)("absolute left-0 right-0 top-full z-[1] mt-[8px] max-h-[318px] overflow-auto rounded-[4px] bg-white py-[6px] shadow-[0_1px_12px_0px_#0000001F] transition-all duration-300",x?"":"pointer-events-none opacity-0",E),children:s.map(e=>(0,t.jsx)("div",{"data-value":e.value,className:(0,o.cn)("flex h-[47px] w-full flex-shrink-0 cursor-pointer items-center whitespace-nowrap bg-white px-[14px] text-[15px] font-bold text-[#333] transition-colors duration-300 hover:bg-[#F7F8F9]",l===e.value?"!bg-[#E8E8E8]":"",e?.disabled?"pointer-events-none text-[#C8C8C8]":""),onClick:()=>{m(e.value),u(!1)},role:"button",tabIndex:0,onKeyDown:c=>{(c.key==="Enter"||c.key===" ")&&c.preventDefault()},children:e.text},e.value))})]}),d&&(0,t.jsx)("div",{className:(0,o.cn)("mt-[8px] text-[14px] text-[#F84D4F]",h),children:typeof d=="string"?`*${d}`:d})]})};var M=I;
2
+ //# sourceMappingURL=Select.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../../src/biz-components/Listing/components/ProductCard/ProductGallery/components/Select.tsx"],
4
+ "sourcesContent": ["import { ChevronDownIcon } from '@heroicons/react/24/outline'\nimport { cn as classNames, cn } from '../../../../../../helpers'\nimport React, { useEffect, useRef, useState } from 'react'\n\ninterface SelectProps {\n label?: string\n required?: boolean\n list?: { value: string; text: string; disabled?: boolean }[]\n value?: string\n disabled?: boolean\n error?: string\n errorClassName?: string\n onChange?: (value: string) => void\n placeholder?: string\n className?: string\n containerClassName?: string\n selectListClassName?: string\n truncate?: boolean\n}\n\nconst Select = ({\n label = '',\n required = false,\n list = [],\n value = '',\n disabled = false,\n error = '',\n errorClassName = '',\n onChange = (value: string) => {},\n placeholder = '',\n className = '',\n containerClassName = '',\n selectListClassName = '',\n truncate = false,\n ...props\n}: SelectProps) => {\n const dropdownRef = useRef(null)\n const [selecting, setSelecting] = useState(false)\n const buttonRef = useRef<HTMLDivElement>(null)\n\n const displayValue = list.find(item => item?.value === value)?.text\n useEffect(() => {\n const handleClickOutside = (event: MouseEvent) => {\n if (buttonRef.current && !buttonRef.current?.contains(event.target as Node)) {\n setSelecting(false)\n }\n }\n document.addEventListener('mousedown', handleClickOutside)\n return () => {\n document.removeEventListener('mousedown', handleClickOutside)\n }\n }, [])\n\n // useEffect(() => {\n // // scroll to select item when select is open\n // // start_ai_generated\n // if (selecting && value) {\n // const selectedElement = dropdownRef.current.querySelector(`[data-value=\"${value}\"]`)\n // if (selectedElement) {\n // scrollParentToChild(dropdownRef.current, selectedElement)\n // }\n // }\n // // end_ai_generated\n // }, [selecting, value])\n\n return (\n <div className={classNames('relative w-full', containerClassName)}>\n {label && (\n <div className=\"mb-[10px] text-[16px] font-bold\">\n {label}\n {required && <span className=\"text-[#F84D4F]\">*</span>}\n </div>\n )}\n <div ref={buttonRef} className=\"relative block\">\n <div\n className={classNames(\n 'flex h-[38px] w-full cursor-pointer items-center justify-between rounded-[2px] border px-[12px] text-[16px] font-bold transition-all x:text-[14px]',\n placeholder && !value ? 'placeholder:text-[#999]' : '',\n disabled ? 'pointer-events-none bg-[#F7F8F9]' : 'bg-white',\n error ? '!border-[#F84D4F]' : 'border-[#E8E8E8]',\n list.length <= 1 && 'cursor-default',\n className\n )}\n onClick={() => {\n if (list.length > 1) {\n setSelecting(!selecting)\n }\n }}\n onChange={event => {\n onChange((event.target as HTMLSelectElement).value)\n }}\n role=\"button\"\n tabIndex={0}\n onKeyDown={e => {\n if (e.key === 'Enter' || e.key === ' ') {\n e.preventDefault()\n }\n }}\n {...props}\n >\n {!value && placeholder ? (\n <div className=\"text-[#999]\">{placeholder}</div>\n ) : (\n <div className={cn('line-clamp-1', truncate ? 'min-w-0 flex-1 truncate' : 'flex-1')}>{displayValue}</div>\n )}\n {list.length > 1 && (\n <ChevronDownIcon\n className={classNames(\n 'ml-[4px] h-[18px] w-[18px] flex-shrink-0 stroke-[#999999] transition-transform',\n selecting && 'rotate-180'\n )}\n />\n )}\n </div>\n <div\n ref={dropdownRef}\n className={classNames(\n 'absolute left-0 right-0 top-full z-[1] mt-[8px] max-h-[318px] overflow-auto rounded-[4px] bg-white py-[6px] shadow-[0_1px_12px_0px_#0000001F] transition-all duration-300',\n selecting ? '' : 'pointer-events-none opacity-0',\n selectListClassName\n )}\n >\n {list.map(item => (\n <div\n key={item.value}\n data-value={item.value}\n className={classNames(\n 'flex h-[47px] w-full flex-shrink-0 cursor-pointer items-center whitespace-nowrap bg-white px-[14px] text-[15px] font-bold text-[#333] transition-colors duration-300 hover:bg-[#F7F8F9]',\n value === item.value ? '!bg-[#E8E8E8]' : '',\n item?.disabled ? 'pointer-events-none text-[#C8C8C8]' : ''\n )}\n onClick={() => {\n onChange(item.value)\n setSelecting(false)\n }}\n role=\"button\"\n tabIndex={0}\n onKeyDown={e => {\n if (e.key === 'Enter' || e.key === ' ') {\n e.preventDefault()\n }\n }}\n >\n {item.text}\n </div>\n ))}\n </div>\n </div>\n {error && (\n <div className={classNames('mt-[8px] text-[14px] text-[#F84D4F]', errorClassName)}>\n {typeof error === 'string' ? `*${error}` : error}\n </div>\n )}\n </div>\n )\n}\n\nexport default Select"],
5
+ "mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GAoEQ,IAAAI,EAAA,6BApERC,EAAgC,uCAChCC,EAAqC,qCACrCC,EAAmD,iBAkBnD,MAAMC,EAAS,CAAC,CACd,MAAAC,EAAQ,GACR,SAAAC,EAAW,GACX,KAAAC,EAAO,CAAC,EACR,MAAAC,EAAQ,GACR,SAAAC,EAAW,GACX,MAAAC,EAAQ,GACR,eAAAC,EAAiB,GACjB,SAAAC,EAAYJ,GAAkB,CAAC,EAC/B,YAAAK,EAAc,GACd,UAAAC,EAAY,GACZ,mBAAAC,EAAqB,GACrB,oBAAAC,EAAsB,GACtB,SAAAC,EAAW,GACX,GAAGC,CACL,IAAmB,CACjB,MAAMC,KAAc,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D,EACL,aAAW,EAAAQ,IACT,4KACAP,EAAY,GAAK,gCACjBJ,CACF,EAEC,SAAAT,EAAK,IAAIiB,MACR,OAAC,OAEC,aAAYA,EAAK,MACjB,aAAW,EAAAG,IACT,0LACAnB,IAAUgB,EAAK,MAAQ,gBAAkB,GACzCA,GAAM,SAAW,qCAAuC,EAC1D,EACA,QAAS,IAAM,CACbZ,EAASY,EAAK,KAAK,EACnBH,EAAa,EAAK,CACpB,EACA,KAAK,SACL,SAAU,EACV,UAAWO,GAAK,EACVA,EAAE,MAAQ,SAAWA,EAAE,MAAQ,MACjCA,EAAE,eAAe,CAErB,EAEC,SAAAJ,EAAK,MAnBDA,EAAK,KAoBZ,CACD,EACH,GACF,EACCd,MACC,OAAC,OAAI,aAAW,EAAAiB,IAAW,sCAAuChB,CAAc,EAC7E,gBAAOD,GAAU,SAAW,IAAIA,CAAK,GAAKA,EAC7C,GAEJ,CAEJ,EAEA,IAAOZ,EAAQM",
6
+ "names": ["Select_exports", "__export", "Select_default", "__toCommonJS", "import_jsx_runtime", "import_outline", "import_helpers", "import_react", "Select", "label", "required", "list", "value", "disabled", "error", "errorClassName", "onChange", "placeholder", "className", "containerClassName", "selectListClassName", "truncate", "props", "dropdownRef", "selecting", "setSelecting", "buttonRef", "displayValue", "item", "handleClickOutside", "event", "classNames", "e"]
7
+ }
@@ -0,0 +1,5 @@
1
+ export declare const ShopifyColorOption: ({ onClick, label, className, }: {
2
+ onClick?: () => void;
3
+ label: string;
4
+ className?: string;
5
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ "use strict";var a=Object.defineProperty;var h=Object.getOwnPropertyDescriptor;var _=Object.getOwnPropertyNames;var v=Object.prototype.hasOwnProperty;var x=(t,o)=>{for(var s in o)a(t,s,{get:o[s],enumerable:!0})},y=(t,o,s,i)=>{if(o&&typeof o=="object"||typeof o=="function")for(let r of _(o))!v.call(t,r)&&r!==s&&a(t,r,{get:()=>o[r],enumerable:!(i=h(o,r))||i.enumerable});return t};var b=t=>y(a({},"__esModule",{value:!0}),t);var w={};x(w,{ShopifyColorOption:()=>N});module.exports=b(w);var e=require("react/jsx-runtime"),n=require("../../../../../../components"),l=require("../../../../utils/helper.js"),u=require("react"),c=require("../../../../../../helpers"),m=require("../../../../../AiuiProvider/index.js");const N=({onClick:t,label:o,className:s})=>{const[i,r]=(0,u.useState)({}),{locale:E,storeDomain:f}=(0,m.useAiuiContext)(),d=`https://${f}/cdn/shop/files/${(0,l.handle)(o)}.png`;return(0,e.jsxs)("div",{className:"relative",children:[(0,e.jsx)("button",{className:(0,c.cn)("relative flex h-[36px] w-[36px] items-center justify-center rounded-full bg-center bg-no-repeat outline outline-2 outline-offset-4 outline-white",!t&&"cursor-default",s),"aria-label":`switch to ${o}`,onClick:t||(()=>{}),title:o,style:i[o]?{background:o}:{},children:!i[o]&&(0,e.jsx)(e.Fragment,{children:(0,e.jsx)(n.Picture,{className:"w-full",source:d,onError:({currentTarget:p})=>{p.onerror=null,r(g=>({...g,[o]:!0}))}})})}),(0,e.jsx)("div",{className:"absolute inset-0 rounded-full shadow-[inset_0_0_4px_rgba(0,0,0,0.08),inset_0_2px_2px_rgba(0,0,0,0.12)]"})]})};
2
+ //# sourceMappingURL=ShopifyColorOption.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../../src/biz-components/Listing/components/ProductCard/ProductGallery/components/ShopifyColorOption.tsx"],
4
+ "sourcesContent": ["import { Picture } from '../../../../../../components'\nimport { handle } from '../../../../utils/helper.js'\nimport { useState } from 'react'\nimport { cn as classNames } from '../../../../../../helpers'\nimport { useAiuiContext } from '../../../../../AiuiProvider/index.js'\n\nexport const ShopifyColorOption = ({\n onClick,\n label,\n className,\n}: {\n onClick?: () => void\n label: string\n className?: string\n}) => {\n const [imgLoadError, setImgLoadError] = useState({})\n\n const { locale, storeDomain } = useAiuiContext()\n const imagePath = `https://${storeDomain}/cdn/shop/files/${handle(label)}.png`\n return (\n <div className='relative'>\n <button\n className={classNames(\n `relative flex h-[36px] w-[36px] items-center justify-center rounded-full bg-center bg-no-repeat outline outline-2 outline-offset-4 outline-white`,\n !onClick && 'cursor-default',\n className,\n )}\n aria-label={`switch to ${label}`}\n onClick={onClick ? onClick : () => {}}\n title={label}\n // If the image fails to load, set the background color to the color of the label\n style={imgLoadError[label as keyof typeof imgLoadError] ? { background: label } : {}}\n >\n {!imgLoadError[label as keyof typeof imgLoadError] && (\n <>\n <Picture\n className='w-full'\n source={imagePath}\n onError={({ currentTarget }) => {\n currentTarget.onerror = null // prevents looping\n setImgLoadError((prev) => ({ ...prev, [label]: true }))\n }}\n />\n </>\n )}\n </button>\n <div className='absolute inset-0 rounded-full shadow-[inset_0_0_4px_rgba(0,0,0,0.08),inset_0_2px_2px_rgba(0,0,0,0.12)]'></div>\n </div>\n )\n}\n"],
5
+ "mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,wBAAAE,IAAA,eAAAC,EAAAH,GAoBI,IAAAI,EAAA,6BApBJC,EAAwB,wCACxBC,EAAuB,uCACvBC,EAAyB,iBACzBC,EAAiC,qCACjCC,EAA+B,gDAExB,MAAMP,EAAqB,CAAC,CACjC,QAAAQ,EACA,MAAAC,EACA,UAAAC,CACF,IAIM,CACJ,KAAM,CAACC,EAAcC,CAAe,KAAI,YAAS,CAAC,CAAC,EAE7C,CAAE,OAAAC,EAAQ,YAAAC,CAAY,KAAI,kBAAe,EACzCC,EAAY,WAAWD,CAAW,sBAAmB,UAAOL,CAAK,CAAC,OACxE,SACE,QAAC,OAAI,UAAU,WACb,oBAAC,UACC,aAAW,EAAAO,IACT,mJACA,CAACR,GAAW,iBACZE,CACF,EACA,aAAY,aAAaD,CAAK,GAC9B,QAASD,IAAoB,IAAM,CAAC,GACpC,MAAOC,EAEP,MAAOE,EAAaF,CAAkC,EAAI,CAAE,WAAYA,CAAM,EAAI,CAAC,EAElF,UAACE,EAAaF,CAAkC,MAC/C,mBACE,mBAAC,WACC,UAAU,SACV,OAAQM,EACR,QAAS,CAAC,CAAE,cAAAE,CAAc,IAAM,CAC9BA,EAAc,QAAU,KACxBL,EAAiBM,IAAU,CAAE,GAAGA,EAAM,CAACT,CAAK,EAAG,EAAK,EAAE,CACxD,EACF,EACF,EAEJ,KACA,OAAC,OAAI,UAAU,yGAAyG,GAC1H,CAEJ",
6
+ "names": ["ShopifyColorOption_exports", "__export", "ShopifyColorOption", "__toCommonJS", "import_jsx_runtime", "import_components", "import_helper", "import_react", "import_helpers", "import_AiuiProvider", "onClick", "label", "className", "imgLoadError", "setImgLoadError", "locale", "storeDomain", "imagePath", "classNames", "currentTarget", "prev"]
7
+ }
@@ -0,0 +1 @@
1
+ export declare const SpecsModal: () => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ "use strict";var s=Object.defineProperty;var d=Object.getOwnPropertyDescriptor;var n=Object.getOwnPropertyNames;var g=Object.prototype.hasOwnProperty;var c=(a,o)=>{for(var l in o)s(a,l,{get:o[l],enumerable:!0})},x=(a,o,l,i)=>{if(o&&typeof o=="object"||typeof o=="function")for(let r of n(o))!g.call(a,r)&&r!==l&&s(a,r,{get:()=>o[r],enumerable:!(i=d(o,r))||i.enumerable});return a};var p=a=>x(s({},"__esModule",{value:!0}),a);var f={};c(f,{SpecsModal:()=>b});module.exports=p(f);var t=require("react/jsx-runtime"),e=require("../../../../../../components"),m=require("../../../../BizProductProvider");const b=()=>{const{product:a}=(0,m.useBizProductContext)();return(0,t.jsxs)(e.Dialog,{children:[(0,t.jsx)(e.DialogTrigger,{children:(0,t.jsx)("button",{className:"text-base leading-[1.4] font-bold",children:"Specs"})}),(0,t.jsxs)(e.DialogContent,{overlayClassName:"z-[100]",className:"max-h-[80vh] z-[110] overflow-y-scroll tablet:min-w-[600px] min-w-[90vw]",children:[(0,t.jsx)(e.DialogHeader,{className:"border-b border-[#E8E8E8]",children:(0,t.jsx)(e.DialogTitle,{children:"Specs"})}),(0,t.jsx)(e.Grid,{className:"gap-[40px]",children:a.metafields?.global?.specifications?.map(({key:o,value:l})=>(0,t.jsxs)(e.GridItem,{span:12,className:"flex w-full py-[24px] border-b border-[#E8E8E8]",children:[(0,t.jsx)(e.Text,{className:"flex-1 text-[16px] font-bold text-[#595959]",children:o}),(0,t.jsx)("div",{className:"flex-1 flex items-center",children:(0,t.jsx)(e.Text,{className:"text-[16px] font-semibold text-[#595959]",html:l?.trim().toLowerCase()==="true"?"\u2714\uFE0F":l?.trim().toLowerCase()==="false"?"\u274C":l})})]}))})]})]})};
2
+ //# sourceMappingURL=SpecsModal.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../../src/biz-components/Listing/components/ProductCard/ProductGallery/components/SpecsModal.tsx"],
4
+ "sourcesContent": ["import {\n Dialog,\n DialogTrigger,\n DialogContent,\n DialogHeader,\n DialogTitle,\n Grid,\n GridItem,\n Text,\n} from '../../../../../../components'\nimport { useBizProductContext } from '../../../../BizProductProvider'\n\nexport const SpecsModal = () => {\n const { product } = useBizProductContext()\n\n return (\n <Dialog>\n <DialogTrigger>\n <button className=\"text-base leading-[1.4] font-bold\">Specs</button>\n </DialogTrigger>\n <DialogContent\n overlayClassName=\"z-[100]\"\n className=\"max-h-[80vh] z-[110] overflow-y-scroll tablet:min-w-[600px] min-w-[90vw]\"\n >\n <DialogHeader className=\"border-b border-[#E8E8E8]\">\n <DialogTitle>Specs</DialogTitle>\n </DialogHeader>\n <Grid className=\"gap-[40px]\">\n {product.metafields?.global?.specifications?.map(({ key, value }: { key: string; value: string }) => (\n <GridItem span={12} className=\"flex w-full py-[24px] border-b border-[#E8E8E8]\">\n <Text className=\"flex-1 text-[16px] font-bold text-[#595959]\">{key}</Text>\n <div className=\"flex-1 flex items-center\">\n <Text\n className=\"text-[16px] font-semibold text-[#595959]\"\n html={\n value?.trim().toLowerCase() === 'true'\n ? '\u2714\uFE0F'\n : value?.trim().toLowerCase() === 'false'\n ? '\u274C'\n : value\n }\n />\n </div>\n </GridItem>\n ))}\n </Grid>\n </DialogContent>\n </Dialog>\n )\n}\n"],
5
+ "mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,gBAAAE,IAAA,eAAAC,EAAAH,GAkBQ,IAAAI,EAAA,6BAlBRC,EASO,wCACPC,EAAqC,0CAE9B,MAAMJ,EAAa,IAAM,CAC9B,KAAM,CAAE,QAAAK,CAAQ,KAAI,wBAAqB,EAEzC,SACE,QAAC,UACC,oBAAC,iBACC,mBAAC,UAAO,UAAU,oCAAoC,iBAAK,EAC7D,KACA,QAAC,iBACC,iBAAiB,UACjB,UAAU,2EAEV,oBAAC,gBAAa,UAAU,4BACtB,mBAAC,eAAY,iBAAK,EACpB,KACA,OAAC,QAAK,UAAU,aACb,SAAAA,EAAQ,YAAY,QAAQ,gBAAgB,IAAI,CAAC,CAAE,IAAAC,EAAK,MAAAC,CAAM,OAC7D,QAAC,YAAS,KAAM,GAAI,UAAU,kDAC5B,oBAAC,QAAK,UAAU,8CAA+C,SAAAD,EAAI,KACnE,OAAC,OAAI,UAAU,2BACb,mBAAC,QACC,UAAU,2CACV,KACEC,GAAO,KAAK,EAAE,YAAY,IAAM,OAC5B,eACAA,GAAO,KAAK,EAAE,YAAY,IAAM,QAC9B,SACAA,EAEV,EACF,GACF,CACD,EACH,GACF,GACF,CAEJ",
6
+ "names": ["SpecsModal_exports", "__export", "SpecsModal", "__toCommonJS", "import_jsx_runtime", "import_components", "import_BizProductProvider", "product", "key", "value"]
7
+ }
@@ -0,0 +1,2 @@
1
+ declare const ProductGallery: () => import("react/jsx-runtime").JSX.Element;
2
+ export default ProductGallery;
@@ -0,0 +1,2 @@
1
+ "use strict";var $=Object.create;var L=Object.defineProperty;var F=Object.getOwnPropertyDescriptor;var j=Object.getOwnPropertyNames;var Y=Object.getPrototypeOf,W=Object.prototype.hasOwnProperty;var O=(t,l)=>{for(var a in l)L(t,a,{get:l[a],enumerable:!0})},A=(t,l,a,v)=>{if(l&&typeof l=="object"||typeof l=="function")for(let r of j(l))!W.call(t,r)&&r!==a&&L(t,r,{get:()=>l[r],enumerable:!(v=F(l,r))||v.enumerable});return t};var H=(t,l,a)=>(a=t!=null?$(Y(t)):{},A(l||!t||!t.__esModule?L(a,"default",{value:t,enumerable:!0}):a,t)),U=t=>A(L({},"__esModule",{value:!0}),t);var Q={};O(Q,{default:()=>J});module.exports=U(Q);var e=require("react/jsx-runtime"),C=require("../../../../AiuiProvider/index.js"),g=require("../../../../../components"),o=require("react"),y=require("swiper/react"),s=require("swiper/modules"),m=require("../../../../../helpers/index.js"),f=require("./types.js"),w=require("@radix-ui/react-tabs"),G=require("../../../BizProductProvider.js"),V=require("../../../hooks/use-variant-media.js"),R=require("./components/SpecsModal.js"),_=H(require("./components/CompareModal.js")),B=require("../../../utils/index.js");const I=t=>(0,e.jsxs)("svg",{width:"48",height:"48",viewBox:"0 0 48 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",...t,children:[(0,e.jsx)("rect",{x:"48",y:"48",width:"48",height:"48",rx:"24",transform:"rotate(-180 48 48)",fill:"white"}),(0,e.jsx)("path",{d:"M25.1035 16.8545C25.5372 16.3818 26.246 16.3818 26.6797 16.8545C27.1067 17.3201 27.1067 18.0706 26.6797 18.5361L21.668 24L26.6797 29.4639C27.1067 29.9294 27.1067 30.6799 26.6797 31.1455C26.246 31.6182 25.5372 31.6182 25.1035 31.1455L19.3203 24.8408C18.8933 24.3752 18.8933 23.6248 19.3203 23.1592L25.1035 16.8545Z",fill:"currentColor"})]}),z=t=>(0,e.jsxs)("svg",{width:"48",height:"48",viewBox:"0 0 48 48",fill:"none",xmlns:"http://www.w3.org/2000/svg",...t,children:[(0,e.jsx)("rect",{width:"48",height:"48",rx:"24",transform:"matrix(1 -8.74228e-08 -8.74228e-08 -1 0 48)",fill:"white"}),(0,e.jsx)("path",{d:"M22.8965 16.8545C22.4628 16.3818 21.754 16.3818 21.3203 16.8545C20.8933 17.3201 20.8933 18.0706 21.3203 18.5361L26.332 24L21.3203 29.4639C20.8933 29.9294 20.8933 30.6799 21.3203 31.1455C21.754 31.6182 22.4628 31.6182 22.8965 31.1455L28.6797 24.8408C29.1067 24.3752 29.1067 23.6248 28.6797 23.1592L22.8965 16.8545Z",fill:"currentColor"})]}),Z=()=>{const{copyWriting:t}=(0,C.useAiuiContext)(),{product:l,variant:a,selectedOptions:v}=(0,G.useBizProductContext)(),r=(0,V.useVariantMedia)({product:l,variant:a}),[u,S]=(0,o.useState)(null),c=a?.metafields?.component?.custom_media_list;let d,b,T,h;c&&c?.available?(d=c?.product||[],b=c?.scenarios||[],T=c?.keyFeatures||[],h=c?.video||[]):(d=r?.productList,b=r?.sceneList,T=r?.keyFeaturesList,h=r?.videoList);const M=(0,o.useMemo)(()=>[...d,...b,...h],[d,b,h]),N={productList:d,sceneList:b,keyFeaturesList:T,videoList:h},x=(0,o.useMemo)(()=>(l?.payload?.components?.find(n=>n.componentKey==="ProductGallery")?.data||[])?.map(n=>({...n,galleries:N[n?.galleries]||[]})).filter(n=>n.galleries.length>0),[l?.payload,N]),P=(0,o.useRef)({}),[i,k]=(0,o.useState)(x?.[0]),D=(p,n)=>{switch(p?.galleryTabType){case f.GalleryTabType.GALLERY_IMAGE_MAIN:return(0,e.jsx)(E,{...p,index:n});case f.GalleryTabType.GALLERY_IMAGE_FEATURES:return(0,e.jsx)(E,{...p,index:n});case f.GalleryTabType.GALLERY_IMAGE_SCENE:return(0,e.jsx)(E,{...p,index:n});case f.GalleryTabType.GALLERY_VIDEO:return(0,e.jsx)(q,{...p});default:return null}};return(0,e.jsx)("div",{id:"ipc-product-gallery",children:(0,e.jsxs)(w.Root,{className:"relative",defaultValue:x?.[0]?.tabValue,children:[(0,e.jsx)("div",{className:"h-[420px] overflow-hidden tablet:h-[620px] desktop:rounded-2xl desktop:h-[560px] lg-desktop:h-[700px] bg-[#EAEAEC] desktop:relative ",children:x.map((p,n)=>(0,e.jsx)(w.Content,{className:"h-full",value:p.tabValue,children:D(p,n)},p.tabValue))}),(0,e.jsx)(K,{galleryTabs:x,activeGalleryTab:i,setActiveGalleryTab:k})]})})},K=({galleryTabs:t,activeGalleryTab:l,setActiveGalleryTab:a})=>{const{product:v}=(0,G.useBizProductContext)(),r=(0,o.useRef)(null);return(0,e.jsxs)("div",{className:"absolute z-[2] bottom-4 left-4 right-4 laptop:left-16 laptop:right-16 flex justify-between items-center tablet:mt-3 desktop:static",children:[(0,e.jsx)(w.List,{ref:r,className:"rounded-full bg-[#EAEAEC] p-1 laptop:p-0 desktop:p-1 overflow-x-auto",style:{scrollbarWidth:"none",msOverflowStyle:"none"},children:(0,e.jsx)("div",{className:"whitespace-nowrap",children:t?.map(u=>(0,e.jsx)(w.Trigger,{className:(0,m.cn)("lg-desktop:px-7 lg-desktop:pb-[14px] rounded-full font-bold lg-desktop:pt-[15px] lg-desktop:text-[16px] px-5 pb-[10px] pt-[11px] text-[14px] leading-tight",u.tabValue===l?.tabValue&&"bg-white"),onClick:S=>{if(a(u),r.current){const c=r.current,d=S.currentTarget,b=d.offsetLeft-c.offsetWidth/2+d.offsetWidth/2;c.scrollTo({left:b,behavior:"smooth"})}},value:u.tabValue,children:u.tabLabel},u.tabValue))})}),(0,e.jsx)("div",{className:"laptop:gap-2 hidden laptop:flex",children:v.metafields?.global?.specifications&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(R.SpecsModal,{})," | ",(0,e.jsx)(_.default,{})]})})]})},E=(0,o.forwardRef)((t,l)=>{const{locale:a="us",copyWriting:v}=(0,C.useAiuiContext)(),{variant:r,totalSavings:u}=(0,G.useBizProductContext)(),S=(0,o.useRef)(null),[c,d]=(0,o.useState)(null),[b,T]=(0,o.useState)(!0),[h,M]=(0,o.useState)(!1),[N,x]=(0,o.useState)(null),P=(0,o.useMemo)(()=>{if(t?.galleryTabType===f.GalleryTabType.GALLERY_IMAGE_MAIN)return"size-[240px] mx-auto mt-[42px] tablet:mt-16 tablet:size-[420px] lg-desktop:size-[560px]";t?.galleryTabType===f.GalleryTabType.GALLERY_IMAGE_FEATURES||(t?.galleryTabType,f.GalleryTabType.GALLERY_IMAGE_SCENE)},[t?.galleryTabType]);return(0,e.jsxs)("div",{className:"h-full [&_.swiper-button]:hover:opacity-100",children:[(0,e.jsx)(y.Swiper,{ref:l,className:"h-full",navigation:{nextEl:`.ipc-product-gallery-${t?.id}-custom-swiper-button-next`,prevEl:`.ipc-product-gallery-${t?.id}-custom-swiper-button-prev`},onSwiper:x,onProgress:i=>{T(i.isBeginning),M(i.isEnd)},pagination:{clickable:!0,el:S.current},onSlideChange:i=>{i&&(i.isEnd?t?.onCurrentTabLoopEnd?.():i.isBeginning&&t?.onCurrentTabLoopStart?.())},thumbs:{swiper:c},modules:[s.Mousewheel,s.Thumbs,s.Navigation,s.Pagination],mousewheel:{forceToAxis:!0},breakpoints:{0:{slidesPerView:1,freeMode:!1}},children:t?.galleries?.map((i,k)=>(0,e.jsx)(y.SwiperSlide,{className:"h-full",children:(0,e.jsx)(g.Picture,{source:i?.image?.url,alt:i?.image?.altText,className:(0,m.cn)("h-full",P),imgClassName:"object-contain h-full"})},t?.id+"SwiperSlideItem"+k))}),r.availableForSale&&!!u&&!t.index&&(0,e.jsx)(g.Badge,{size:"lg",className:"absolute bg-brand text-white top-3 laptop:left-16 laptop:top-5 left-4 z-[2] desktop:left-6 desktop:top-6",children:`${(0,B.formatPrice)({amount:u,currencyCode:r?.price?.currencyCode,locale:a})} ${v?.off}`}),(0,e.jsx)("div",{className:(0,m.cn)("hidden tablet:opacity-0 tablet:block tablet:absolute tablet:top-1/2 laptop:left-16 tablet:left-6 desktop:left-6 z-10 -translate-y-1/2 cursor-pointer",`ipc-product-gallery-${t?.id}-custom-swiper-button-prev`,"swiper-button"),children:(0,e.jsx)(I,{className:(0,m.cn)("tablet:size-10 lg-desktop:size-12")})}),(0,e.jsx)("div",{className:(0,m.cn)("hidden tablet:block tablet:opacity-0 tablet:absolute tablet:top-1/2 laptop:right-16 tablet:right-6 z-10 desktop:right-6 -translate-y-1/2 cursor-pointer",`ipc-product-gallery-${t?.id}-custom-swiper-button-next`,"swiper-button"),children:(0,e.jsx)(z,{className:(0,m.cn)("tablet:size-10 lg-desktop:size-12")})}),(0,e.jsxs)("div",{className:"absolute bottom-[94px] tablet:bottom-[70px] left-4 right-4 z-10 items-center tablet:flex justify-between laptop:left-16 laptop:right-16 desktop:bottom-[20px] desktop:right-6 desktop:left-6",children:[(0,e.jsx)("div",{className:"hidden tablet:block",children:(0,e.jsx)(y.Swiper,{className:"flex items-center justify-between",onSwiper:d,spaceBetween:12,slidesPerView:6,freeMode:!0,watchSlidesProgress:!0,modules:[s.Navigation,s.Thumbs],children:t?.galleries?.map((i,k)=>(0,e.jsx)(y.SwiperSlide,{className:"!w-auto [&.swiper-slide-thumb-active]:border [&.swiper-slide-thumb-active]:rounded [&.swiper-slide-thumb-active]:border-brand",children:(0,e.jsx)(g.Picture,{source:i.image?.url,alt:i.image?.altText,className:"size-10 lg-desktop:size-12 overflow-hidden bg-white rounded",imgClassName:"object-contain h-full"})},t?.id+"SwiperSlideThumbItem"+k))})}),!t?.index&&(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)(g.Picture,{source:t?.comment?.avatar?.url,className:"size-8 laptop:size-10 rounded-full shrink-0",imgClassName:"object-cover "}),(0,e.jsx)(g.Text,{html:t?.comment?.content,className:"text-sm lg-desktop:text-base max-w-[528px] font-bold text-[#1D1D1F] line-clamp-2"})]})]}),(0,e.jsx)("div",{ref:S,className:"tablet:hidden text-center absolute !bottom-[70px] left-4 right-4 z-10"})]})}),q=t=>(0,e.jsxs)("div",{className:"h-full [&_.swiper-button]:hover:opacity-100",children:[(0,e.jsx)(y.Swiper,{className:"h-full",navigation:{nextEl:`.ipc-product-gallery-${t?.id}-custom-swiper-button-next`,prevEl:`.ipc-product-gallery-${t?.id}-custom-swiper-button-prev`},modules:[s.Mousewheel,s.Thumbs,s.Navigation,s.Pagination],mousewheel:{forceToAxis:!0},breakpoints:{0:{slidesPerView:1,freeMode:!1}},children:t?.galleries?.map((l,a)=>(0,e.jsx)(y.SwiperSlide,{className:"h-full",children:(0,e.jsxs)("video",{controls:!0,className:"size-full",children:[(0,e.jsx)("track",{kind:"captions"}),(0,e.jsx)("source",{src:l?.sources?.[0]?.url,type:"video/mp4"}),(0,e.jsx)("source",{src:l?.sources?.[0]?.url,type:"video/webm"}),(0,e.jsx)("source",{src:l?.sources?.[0]?.url,type:"video/ogg"})]})},t?.id+"SwiperSlideItem"+a))}),(0,e.jsx)("div",{className:(0,m.cn)("hidden swiper-button tablet:block tablet:opacity-0 tablet:absolute tablet:top-1/2 tablet:left-6 z-10 -translate-y-1/2 cursor-pointer",`ipc-product-gallery-${t?.id}-custom-swiper-button-prev`),children:(0,e.jsx)(I,{className:"tablet:size-10 lg-desktop:size-12"})}),(0,e.jsx)("div",{className:(0,m.cn)("hidden tablet:block swiper-button tablet:opacity-0 tablet:absolute tablet:top-1/2 tablet:right-6 z-10 -translate-y-1/2 cursor-pointer",`ipc-product-gallery-${t?.id}-custom-swiper-button-next`),children:(0,e.jsx)(z,{className:"tablet:size-10 lg-desktop:size-12"})})]}),ae=t=>(0,e.jsx)("div",{children:"3D View"});var J=Z;
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../src/biz-components/Listing/components/ProductCard/ProductGallery/index.tsx"],
4
+ "sourcesContent": ["import { useAiuiContext } from '../../../../AiuiProvider/index.js'\nimport { Text, Picture, Button, Badge } from '../../../../../components'\nimport {\n useCallback,\n useMemo,\n useState,\n forwardRef,\n useRef,\n type RefObject,\n useEffect,\n type Dispatch,\n type SetStateAction,\n} from 'react'\nimport { Swiper, SwiperSlide, type SwiperRef } from 'swiper/react'\nimport { Navigation, Mousewheel, Thumbs, Pagination } from 'swiper/modules'\nimport { cn } from '../../../../../helpers/index.js'\nimport { GalleryTabType } from './types.js'\nimport { Content, List, Root, Trigger } from '@radix-ui/react-tabs'\nimport { useBizProductContext } from '../../../BizProductProvider.js'\nimport { useVariantMedia } from '../../../hooks/use-variant-media.js'\nimport { SpecsModal } from './components/SpecsModal.js'\nimport CompareModal from './components/CompareModal.js'\nimport { formatPrice } from '../../../utils/index.js'\n\nimport type { Swiper as SwiperType } from 'swiper'\nimport type { ImageMedia, VideoMedia } from '../../../hooks/use-variant-media.js'\nimport type { ProductGalleryProps, ProductGalleryTabItemProps, GalleryTabItemProps } from './types.js'\n\nconst SwiperLeftButtonIcon = (props: React.SVGProps<SVGSVGElement>) => {\n return (\n <svg width=\"48\" height=\"48\" viewBox=\"0 0 48 48\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <rect x=\"48\" y=\"48\" width=\"48\" height=\"48\" rx=\"24\" transform=\"rotate(-180 48 48)\" fill=\"white\" />\n <path\n d=\"M25.1035 16.8545C25.5372 16.3818 26.246 16.3818 26.6797 16.8545C27.1067 17.3201 27.1067 18.0706 26.6797 18.5361L21.668 24L26.6797 29.4639C27.1067 29.9294 27.1067 30.6799 26.6797 31.1455C26.246 31.6182 25.5372 31.6182 25.1035 31.1455L19.3203 24.8408C18.8933 24.3752 18.8933 23.6248 19.3203 23.1592L25.1035 16.8545Z\"\n fill=\"currentColor\"\n />\n </svg>\n )\n}\n\nconst SwiperRightButtonIcon = (props: React.SVGProps<SVGSVGElement>) => {\n return (\n <svg width=\"48\" height=\"48\" viewBox=\"0 0 48 48\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" {...props}>\n <rect width=\"48\" height=\"48\" rx=\"24\" transform=\"matrix(1 -8.74228e-08 -8.74228e-08 -1 0 48)\" fill=\"white\" />\n <path\n d=\"M22.8965 16.8545C22.4628 16.3818 21.754 16.3818 21.3203 16.8545C20.8933 17.3201 20.8933 18.0706 21.3203 18.5361L26.332 24L21.3203 29.4639C20.8933 29.9294 20.8933 30.6799 21.3203 31.1455C21.754 31.6182 22.4628 31.6182 22.8965 31.1455L28.6797 24.8408C29.1067 24.3752 29.1067 23.6248 28.6797 23.1592L22.8965 16.8545Z\"\n fill=\"currentColor\"\n />\n </svg>\n )\n}\n\nconst ProductGallery = () => {\n const { copyWriting } = useAiuiContext()\n const { product, variant, selectedOptions } = useBizProductContext()\n const defaultMediaData = useVariantMedia({ product, variant })\n const [swiper, setSwiper] = useState<SwiperType | null>(null)\n\n const customMediaList = variant?.metafields?.component?.custom_media_list\n let productList: ImageMedia[], sceneList: ImageMedia[], keyFeaturesList: ImageMedia[], videoList: VideoMedia[]\n\n if (customMediaList && customMediaList?.available) {\n productList = customMediaList?.product || []\n sceneList = customMediaList?.scenarios || []\n keyFeaturesList = customMediaList?.keyFeatures || []\n videoList = customMediaList?.video || []\n } else {\n productList = defaultMediaData?.productList\n sceneList = defaultMediaData?.sceneList\n keyFeaturesList = defaultMediaData?.keyFeaturesList\n videoList = defaultMediaData?.videoList\n }\n\n const allMedia = useMemo(() => [...productList, ...sceneList, ...videoList], [productList, sceneList, videoList])\n\n const galleryMap: Record<string, ImageMedia[] | VideoMedia[]> = {\n productList: productList,\n sceneList: sceneList,\n keyFeaturesList: keyFeaturesList,\n videoList: videoList,\n }\n\n const galleryTabs = useMemo(() => {\n const productTab =\n product?.payload?.components?.find((item: any) => item.componentKey === 'ProductGallery')?.data || []\n\n return productTab\n ?.map((item: any) => ({\n ...item,\n galleries: galleryMap[item?.galleries] || [],\n }))\n .filter((item: any) => item.galleries.length > 0)\n }, [product?.payload, galleryMap])\n\n // \u4E3A\u6BCF\u4E2A galleryTab \u521B\u5EFA\u5BF9\u5E94\u7684 ref\n const gallerySwiperRefs = useRef<{ [key: string]: SwiperRef | null }>({})\n\n const [activeGalleryTab, setActiveGalleryTab] = useState<GalleryTabItemProps>(galleryTabs?.[0])\n\n\n // useEffect(() => {\n // if (selectedOptions?.color) {\n // setActiveGalleryTab(galleryTabs?.find((item: any) => item.galleryTabType === GalleryTabType.GALLERY_IMAGE_MAIN))\n // }\n // }, [selectedOptions, galleryTabs])\n\n // \u4E3A\u6BCF\u4E2A tab \u6E32\u67D3\u5BF9\u5E94\u7684\u7EC4\u4EF6\n const renderGalleryForTab = (tab: any, index: number) => {\n switch (tab?.galleryTabType) {\n // case GalleryTabType.GALLERY_IMAGE_MAIN ||\n // GalleryTabType.GALLERY_IMAGE_FEATURES ||\n // GalleryTabType.GALLERY_IMAGE_SCENE:\n // return (\n // <ProductGalleryTabImage\n // {...tab}\n // // onCurrentTabLoopEnd={() => {\n // // setActiveGalleryTab(galleryTabs?.[index])\n // // }}\n // // onCurrentTabLoopStart={() => {\n // // setActiveGalleryTab(galleryTabs?.[index])\n // // }}\n // index={index}\n // />\n // )\n\n case GalleryTabType.GALLERY_IMAGE_MAIN:\n return <ProductGalleryTabImage {...tab} index={index} />\n case GalleryTabType.GALLERY_IMAGE_FEATURES:\n return <ProductGalleryTabImage {...tab} index={index} />\n case GalleryTabType.GALLERY_IMAGE_SCENE:\n return <ProductGalleryTabImage {...tab} index={index} />\n case GalleryTabType.GALLERY_VIDEO:\n return <ProductGalleryTabVideo {...tab} />\n // case GalleryTabType.GALLERY_3D_VIEW:\n // return <ProductGalleryTab3DView {...item} />\n default:\n return null\n }\n }\n\n return (\n <div id=\"ipc-product-gallery\">\n <Root className=\"relative\" defaultValue={galleryTabs?.[0]?.tabValue}>\n {/* <Swiper\n className=\"h-[420px] laptop:h-[700px] bg-[#EAEAEC] rounded-2xl\"\n onSwiper={setSwiper}\n loop={true}\n // onProgress={swiper => {\n // setStart(swiper.isBeginning)\n // setEnd(swiper.isEnd)\n // }}\n modules={[Mousewheel]}\n mousewheel={{\n forceToAxis: true,\n }}\n >\n {galleryTabs.map((item, index) => {\n return (\n <Content forceMount key={item.tabValue} value={item.tabValue}>\n <SwiperSlide key={index}>{renderGalleryForTab(activeGalleryTab)}</SwiperSlide>\n </Content>\n )\n })}\n </Swiper>\n <div\n className={cn(\n 'absolute top-1/2 left-6 z-10 -translate-y-1/2 cursor-pointer',\n `ipc-product-gallery-custom-swiper-button-prev`\n )}\n >\n <SwiperLeftButtonIcon\n className=\"size-12\"\n onClick={() => {\n if (activeGalleryTab?.tabValue) {\n const currentRef = gallerySwiperRefs.current[activeGalleryTab.tabValue]\n currentRef?.swiper?.slidePrev()\n }\n }}\n />\n </div>\n <div\n className={cn(\n 'absolute top-1/2 right-6 z-10 -translate-y-1/2 cursor-pointer',\n `ipc-product-gallery-custom-swiper-button-next`\n )}\n >\n <SwiperRightButtonIcon\n className=\"size-12\"\n onClick={() => {\n if (activeGalleryTab?.tabValue) {\n const currentRef = gallerySwiperRefs.current[activeGalleryTab.tabValue]\n currentRef?.swiper?.slideNext()\n }\n }}\n />\n </div> */}\n <div className=\"h-[420px] overflow-hidden tablet:h-[620px] desktop:rounded-2xl desktop:h-[560px] lg-desktop:h-[700px] bg-[#EAEAEC] desktop:relative \">\n {galleryTabs.map((item: any, index: number) => {\n return (\n <Content key={item.tabValue} className=\"h-full\" value={item.tabValue}>\n {renderGalleryForTab(item, index)}\n </Content>\n )\n })}\n </div>\n <ProductGalleryTab\n galleryTabs={galleryTabs}\n activeGalleryTab={activeGalleryTab}\n setActiveGalleryTab={setActiveGalleryTab}\n />\n </Root>\n </div>\n )\n}\n\nconst ProductGalleryTab = ({\n galleryTabs,\n activeGalleryTab,\n setActiveGalleryTab,\n}: {\n galleryTabs: GalleryTabItemProps[]\n activeGalleryTab: GalleryTabItemProps\n setActiveGalleryTab: Dispatch<SetStateAction<GalleryTabItemProps>>\n}) => {\n const { product } = useBizProductContext()\n const scrollContainerRef = useRef<HTMLDivElement>(null)\n return (\n <div className=\"absolute z-[2] bottom-4 left-4 right-4 laptop:left-16 laptop:right-16 flex justify-between items-center tablet:mt-3 desktop:static\">\n <List\n ref={scrollContainerRef}\n className=\"rounded-full bg-[#EAEAEC] p-1 laptop:p-0 desktop:p-1 overflow-x-auto\"\n style={{\n scrollbarWidth: 'none',\n msOverflowStyle: 'none',\n }}\n >\n <div className=\"whitespace-nowrap\">\n {galleryTabs?.map(item => {\n return (\n <Trigger\n className={cn(\n 'lg-desktop:px-7 lg-desktop:pb-[14px] rounded-full font-bold lg-desktop:pt-[15px] lg-desktop:text-[16px] px-5 pb-[10px] pt-[11px] text-[14px] leading-tight',\n item.tabValue === activeGalleryTab?.tabValue && 'bg-white'\n )}\n onClick={el => {\n setActiveGalleryTab(item)\n if (scrollContainerRef.current) {\n const container = scrollContainerRef.current\n const button = el.currentTarget\n const scrollLeft = button.offsetLeft - container.offsetWidth / 2 + button.offsetWidth / 2\n container.scrollTo({\n left: scrollLeft,\n behavior: 'smooth',\n })\n }\n }}\n key={item.tabValue}\n value={item.tabValue}\n >\n {item.tabLabel}\n </Trigger>\n )\n })}\n </div>\n </List>\n <div className=\"laptop:gap-2 hidden laptop:flex\">\n {product.metafields?.global?.specifications && (\n <>\n <SpecsModal /> | <CompareModal />\n </>\n )}\n </div>\n </div>\n )\n}\n\nconst ProductGalleryTabImage = forwardRef<SwiperRef, ProductGalleryTabItemProps>((props, ref) => {\n const { locale = 'us', copyWriting } = useAiuiContext()\n const { variant, totalSavings } = useBizProductContext()\n const paginationRef = useRef<HTMLDivElement>(null)\n const [thumbsSwiper, setThumbsSwiper] = useState<SwiperType | null>(null)\n const [isStart, setStart] = useState(true)\n const [isEnd, setEnd] = useState(false)\n const [swiper, setSwiper] = useState<SwiperType | null>(null)\n\n const imageClassName = useMemo(() => {\n if (props?.galleryTabType === GalleryTabType.GALLERY_IMAGE_MAIN) {\n return 'size-[240px] mx-auto mt-[42px] tablet:mt-16 tablet:size-[420px] lg-desktop:size-[560px]'\n } else if (props?.galleryTabType === GalleryTabType.GALLERY_IMAGE_FEATURES) {\n // return '420px'\n } else if (props?.galleryTabType === GalleryTabType.GALLERY_IMAGE_SCENE) {\n // return '560px'\n }\n }, [props?.galleryTabType])\n\n return (\n <div className=\"h-full [&_.swiper-button]:hover:opacity-100\">\n <Swiper\n ref={ref}\n className=\"h-full\"\n navigation={{\n nextEl: `.ipc-product-gallery-${props?.id}-custom-swiper-button-next`,\n prevEl: `.ipc-product-gallery-${props?.id}-custom-swiper-button-prev`,\n }}\n onSwiper={setSwiper}\n onProgress={swiper => {\n setStart(swiper.isBeginning)\n setEnd(swiper.isEnd)\n }}\n pagination={{\n clickable: true,\n el: paginationRef.current,\n }}\n onSlideChange={swiper => {\n if (swiper) {\n if (swiper.isEnd) {\n props?.onCurrentTabLoopEnd?.()\n } else if (swiper.isBeginning) {\n props?.onCurrentTabLoopStart?.()\n }\n }\n }}\n thumbs={{ swiper: thumbsSwiper }}\n modules={[Mousewheel, Thumbs, Navigation, Pagination]}\n mousewheel={{\n forceToAxis: true,\n }}\n breakpoints={{\n 0: {\n slidesPerView: 1,\n freeMode: false,\n },\n }}\n >\n {props?.galleries?.map((item, jIndex) => {\n return (\n <SwiperSlide className=\"h-full\" key={props?.id + 'SwiperSlideItem' + jIndex}>\n <Picture\n source={item?.image?.url}\n alt={item?.image?.altText}\n className={cn(\"h-full\", imageClassName)}\n imgClassName=\"object-contain h-full\"\n />\n </SwiperSlide>\n )\n })}\n </Swiper>\n {variant.availableForSale && !!totalSavings && !props.index && (\n <Badge\n size=\"lg\"\n className=\"absolute bg-brand text-white top-3 laptop:left-16 laptop:top-5 left-4 z-[2] desktop:left-6 desktop:top-6\"\n >\n {`${formatPrice({\n amount: totalSavings,\n currencyCode: variant?.price?.currencyCode,\n locale: locale,\n })} ${copyWriting?.off}`}\n </Badge>\n )}\n <div\n className={cn(\n 'hidden tablet:opacity-0 tablet:block tablet:absolute tablet:top-1/2 laptop:left-16 tablet:left-6 desktop:left-6 z-10 -translate-y-1/2 cursor-pointer',\n `ipc-product-gallery-${props?.id}-custom-swiper-button-prev`,\n `swiper-button`\n )}\n >\n <SwiperLeftButtonIcon className={cn('tablet:size-10 lg-desktop:size-12')} />\n </div>\n <div\n className={cn(\n 'hidden tablet:block tablet:opacity-0 tablet:absolute tablet:top-1/2 laptop:right-16 tablet:right-6 z-10 desktop:right-6 -translate-y-1/2 cursor-pointer',\n `ipc-product-gallery-${props?.id}-custom-swiper-button-next`,\n `swiper-button`\n )}\n >\n <SwiperRightButtonIcon className={cn('tablet:size-10 lg-desktop:size-12')} />\n </div>\n {/* {props?.galleries?.map((item, jIndex) => {\n return (\n <Picture\n key={props?.id + 'SwiperSlideItem' + jIndex}\n source={item?.image?.url}\n alt={item?.image?.altText}\n className=\"h-full\"\n imgClassName=\"object-cover h-full\"\n />\n )\n })} */}\n <div className=\"absolute bottom-[94px] tablet:bottom-[70px] left-4 right-4 z-10 items-center tablet:flex justify-between laptop:left-16 laptop:right-16 desktop:bottom-[20px] desktop:right-6 desktop:left-6\">\n <div className=\"hidden tablet:block\">\n <Swiper\n className=\"flex items-center justify-between\"\n onSwiper={setThumbsSwiper}\n spaceBetween={12}\n slidesPerView={6}\n freeMode={true}\n watchSlidesProgress={true}\n modules={[Navigation, Thumbs]}\n >\n {props?.galleries?.map((item, jIndex) => (\n <SwiperSlide\n key={props?.id + 'SwiperSlideThumbItem' + jIndex}\n className=\"!w-auto [&.swiper-slide-thumb-active]:border [&.swiper-slide-thumb-active]:rounded [&.swiper-slide-thumb-active]:border-brand\"\n >\n <Picture\n source={item.image?.url}\n alt={item.image?.altText}\n className=\"size-10 lg-desktop:size-12 overflow-hidden bg-white rounded\"\n imgClassName=\"object-contain h-full\"\n />\n </SwiperSlide>\n ))}\n </Swiper>\n </div>\n {!props?.index && (\n <div className=\"flex items-center gap-2\">\n <Picture\n source={props?.comment?.avatar?.url}\n className=\"size-8 laptop:size-10 rounded-full shrink-0\"\n imgClassName=\"object-cover \"\n />\n <Text\n html={props?.comment?.content}\n className=\"text-sm lg-desktop:text-base max-w-[528px] font-bold text-[#1D1D1F] line-clamp-2\"\n />\n </div>\n )}\n </div>\n <div ref={paginationRef} className=\"tablet:hidden text-center absolute !bottom-[70px] left-4 right-4 z-10\" />\n </div>\n )\n})\n\nconst ProductGalleryTabVideo = (props: ProductGalleryTabItemProps) => {\n return (\n <div className=\"h-full [&_.swiper-button]:hover:opacity-100\">\n <Swiper\n className=\"h-full\"\n navigation={{\n nextEl: `.ipc-product-gallery-${props?.id}-custom-swiper-button-next`,\n prevEl: `.ipc-product-gallery-${props?.id}-custom-swiper-button-prev`,\n }}\n modules={[Mousewheel, Thumbs, Navigation, Pagination]}\n mousewheel={{\n forceToAxis: true,\n }}\n breakpoints={{\n 0: {\n slidesPerView: 1,\n freeMode: false,\n },\n }}\n >\n {props?.galleries?.map((item, jIndex) => {\n return (\n <SwiperSlide className=\"h-full\" key={props?.id + 'SwiperSlideItem' + jIndex}>\n <video controls className=\"size-full\">\n <track kind=\"captions\" />\n <source src={item?.sources?.[0]?.url} type=\"video/mp4\" />\n <source src={item?.sources?.[0]?.url} type=\"video/webm\" />\n <source src={item?.sources?.[0]?.url} type=\"video/ogg\" />\n </video>\n </SwiperSlide>\n )\n })}\n </Swiper>\n <div\n className={cn(\n 'hidden swiper-button tablet:block tablet:opacity-0 tablet:absolute tablet:top-1/2 tablet:left-6 z-10 -translate-y-1/2 cursor-pointer',\n `ipc-product-gallery-${props?.id}-custom-swiper-button-prev`\n )}\n >\n <SwiperLeftButtonIcon className=\"tablet:size-10 lg-desktop:size-12\" />\n </div>\n <div\n className={cn(\n 'hidden tablet:block swiper-button tablet:opacity-0 tablet:absolute tablet:top-1/2 tablet:right-6 z-10 -translate-y-1/2 cursor-pointer',\n `ipc-product-gallery-${props?.id}-custom-swiper-button-next`\n )}\n >\n <SwiperRightButtonIcon className=\"tablet:size-10 lg-desktop:size-12\" />\n </div>\n </div>\n )\n}\n\nconst ProductGalleryTab3DView = (props: ProductGalleryTabItemProps) => {\n return <div>3D View</div>\n}\n\nexport default ProductGallery\n"],
5
+ "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GA8BI,IAAAI,EAAA,6BA9BJC,EAA+B,6CAC/BC,EAA6C,qCAC7CC,EAUO,iBACPA,EAAoD,wBACpDC,EAA2D,0BAC3DC,EAAmB,2CACnBC,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C,SAAM,KAAK,WAAW,KACvB,OAAC,UAAO,IAAK3B,GAAM,UAAU,CAAC,GAAG,IAAK,KAAK,YAAY,KACvD,OAAC,UAAO,IAAKA,GAAM,UAAU,CAAC,GAAG,IAAK,KAAK,aAAa,KACxD,OAAC,UAAO,IAAKA,GAAM,UAAU,CAAC,GAAG,IAAK,KAAK,YAAY,GACzD,GANmClB,GAAO,GAAK,kBAAoB6C,CAOrE,CAEH,EACH,KACA,OAAC,OACC,aAAW,MACT,uIACA,uBAAuB7C,GAAO,EAAE,4BAClC,EAEA,mBAACD,EAAA,CAAqB,UAAU,oCAAoC,EACtE,KACA,OAAC,OACC,aAAW,MACT,wIACA,uBAAuBC,GAAO,EAAE,4BAClC,EAEA,mBAACC,EAAA,CAAsB,UAAU,oCAAoC,EACvE,GACF,EAIE6C,GAA2B9C,MACxB,OAAC,OAAI,mBAAO,EAGrB,IAAOhB,EAAQkB",
6
+ "names": ["ProductGallery_exports", "__export", "ProductGallery_default", "__toCommonJS", "import_jsx_runtime", "import_AiuiProvider", "import_components", "import_react", "import_modules", "import_helpers", "import_types", "import_react_tabs", "import_BizProductProvider", "import_use_variant_media", "import_SpecsModal", "import_CompareModal", "import_utils", "SwiperLeftButtonIcon", "props", "SwiperRightButtonIcon", "ProductGallery", "copyWriting", "product", "variant", "selectedOptions", "defaultMediaData", "swiper", "setSwiper", "customMediaList", "productList", "sceneList", "keyFeaturesList", "videoList", "allMedia", "galleryMap", "galleryTabs", "item", "gallerySwiperRefs", "activeGalleryTab", "setActiveGalleryTab", "renderGalleryForTab", "tab", "index", "ProductGalleryTabImage", "ProductGalleryTabVideo", "ProductGalleryTab", "scrollContainerRef", "el", "container", "button", "scrollLeft", "CompareModal", "ref", "locale", "totalSavings", "paginationRef", "thumbsSwiper", "setThumbsSwiper", "isStart", "setStart", "isEnd", "setEnd", "imageClassName", "jIndex", "ProductGalleryTab3DView"]
7
+ }
@@ -0,0 +1,37 @@
1
+ import type { Img } from '../../../../../types/props.js';
2
+ import type { ImageMedia, VideoMedia } from '../../../hooks/use-variant-media.js';
3
+ export interface ProductGalleryProps {
4
+ data: {
5
+ gallerySections: {
6
+ title: string;
7
+ }[];
8
+ };
9
+ }
10
+ export interface ProductGalleryTabItemProps {
11
+ index: number;
12
+ galleryTabType: GalleryTabType;
13
+ galleries: ImageMedia[] | VideoMedia[];
14
+ onCurrentTabLoopStart?: () => void;
15
+ onCurrentTabLoopEnd?: () => void;
16
+ id: string;
17
+ comment?: {
18
+ content: string;
19
+ avatar: Img;
20
+ };
21
+ tabLabel: string;
22
+ tabValue: string;
23
+ }
24
+ export interface GalleryTabItemProps {
25
+ tabLabel: string;
26
+ tabValue: string;
27
+ id: string;
28
+ galleryTabType: GalleryTabType;
29
+ galleries: ImageMedia[] | VideoMedia[];
30
+ }
31
+ export declare enum GalleryTabType {
32
+ GALLERY_IMAGE_MAIN = "ipc-gallery-tab-image-main",
33
+ GALLERY_IMAGE_FEATURES = "ipc-gallery-tab-image-features",
34
+ GALLERY_IMAGE_SCENE = "ipc-gallery-tab-image-scene",
35
+ GALLERY_VIDEO = "ipc-gallery-tab-video",
36
+ GALLERY_3D_VIEW = "ipc-gallery-tab-3d-view"
37
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";var o=Object.defineProperty;var l=Object.getOwnPropertyDescriptor;var d=Object.getOwnPropertyNames;var s=Object.prototype.hasOwnProperty;var m=(a,e)=>{for(var r in e)o(a,r,{get:e[r],enumerable:!0})},p=(a,e,r,g)=>{if(e&&typeof e=="object"||typeof e=="function")for(let t of d(e))!s.call(a,t)&&t!==r&&o(a,t,{get:()=>e[t],enumerable:!(g=l(e,t))||g.enumerable});return a};var b=a=>p(o({},"__esModule",{value:!0}),a);var E={};m(E,{GalleryTabType:()=>n});module.exports=b(E);var n=(i=>(i.GALLERY_IMAGE_MAIN="ipc-gallery-tab-image-main",i.GALLERY_IMAGE_FEATURES="ipc-gallery-tab-image-features",i.GALLERY_IMAGE_SCENE="ipc-gallery-tab-image-scene",i.GALLERY_VIDEO="ipc-gallery-tab-video",i.GALLERY_3D_VIEW="ipc-gallery-tab-3d-view",i))(n||{});
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../src/biz-components/Listing/components/ProductCard/ProductGallery/types.ts"],
4
+ "sourcesContent": ["import type { Img, Video } from '../../../../../types/props.js'\nimport type { ImageMedia, VideoMedia } from '../../../hooks/use-variant-media.js'\n\nexport interface ProductGalleryProps {\n data: {\n gallerySections: {\n title: string\n }[]\n }\n}\n\nexport interface ProductGalleryTabItemProps {\n index: number\n galleryTabType: GalleryTabType\n galleries: ImageMedia[] | VideoMedia[]\n onCurrentTabLoopStart?: () => void\n onCurrentTabLoopEnd?: () => void\n id: string\n comment?: {\n content: string\n avatar: Img\n }\n tabLabel: string\n tabValue: string\n // galleryImgs?: Img[]\n // galleryVideo?: Video\n // gallery3DView?: Video\n}\n\nexport interface GalleryTabItemProps {\n tabLabel: string\n tabValue: string\n id: string\n galleryTabType: GalleryTabType\n galleries: ImageMedia[] | VideoMedia[]\n}[]\n\nexport enum GalleryTabType {\n GALLERY_IMAGE_MAIN = 'ipc-gallery-tab-image-main',\n GALLERY_IMAGE_FEATURES = 'ipc-gallery-tab-image-features',\n GALLERY_IMAGE_SCENE = 'ipc-gallery-tab-image-scene',\n GALLERY_VIDEO = 'ipc-gallery-tab-video',\n GALLERY_3D_VIEW = 'ipc-gallery-tab-3d-view',\n}\n"],
5
+ "mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,oBAAAE,IAAA,eAAAC,EAAAH,GAqCO,IAAKE,OACVA,EAAA,mBAAqB,6BACrBA,EAAA,uBAAyB,iCACzBA,EAAA,oBAAsB,8BACtBA,EAAA,cAAgB,wBAChBA,EAAA,gBAAkB,0BALRA,OAAA",
6
+ "names": ["types_exports", "__export", "GalleryTabType", "__toCommonJS"]
7
+ }
@@ -0,0 +1,6 @@
1
+ declare const ProductGridBox: ({ BoxLeftGallery, BoxRightDetail, BoxBottomSummary, }: {
2
+ BoxLeftGallery: React.ReactNode;
3
+ BoxRightDetail: React.ReactNode;
4
+ BoxBottomSummary: React.ReactNode;
5
+ }) => import("react/jsx-runtime").JSX.Element;
6
+ export default ProductGridBox;
@@ -0,0 +1,2 @@
1
+ "use strict";var s=Object.defineProperty;var l=Object.getOwnPropertyDescriptor;var r=Object.getOwnPropertyNames;var i=Object.prototype.hasOwnProperty;var k=(o,t)=>{for(var e in t)s(o,e,{get:t[e],enumerable:!0})},m=(o,t,e,c)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of r(t))!i.call(o,a)&&a!==e&&s(o,a,{get:()=>t[a],enumerable:!(c=l(t,a))||c.enumerable});return o};var x=o=>m(s({},"__esModule",{value:!0}),o);var R={};k(R,{default:()=>N});module.exports=x(R);var p=require("react/jsx-runtime"),d=require("../../../../components");const G=({BoxLeftGallery:o,BoxRightDetail:t,BoxBottomSummary:e})=>(0,p.jsxs)("div",{id:"ipc-product-card",className:"desktop:mt-6 desktop:px-16 lg-desktop:px-[calc(50%-832px)]",children:[(0,p.jsxs)(d.Grid,{className:"desktop:gap-4 lg-desktop:gap-8 gap-8",children:[(0,p.jsx)(d.GridItem,{className:"col-span-12 laptop:px-0 desktop:col-start-1 desktop:col-span-8 desktop:sticky desktop:top-[124px] h-fit",children:o}),(0,p.jsx)(d.GridItem,{className:"col-span-12 desktop:col-start-9 desktop:col-span-4",children:t})]}),e]});var N=G;
2
+ //# sourceMappingURL=ProductGridBox.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../src/biz-components/Listing/components/ProductCard/ProductGridBox.tsx"],
4
+ "sourcesContent": ["import { Grid, GridItem } from '../../../../components'\n\nconst ProductGridBox = ({\n BoxLeftGallery,\n BoxRightDetail,\n BoxBottomSummary,\n}: {\n BoxLeftGallery: React.ReactNode\n BoxRightDetail: React.ReactNode\n BoxBottomSummary: React.ReactNode\n}) => {\n return (\n <div id=\"ipc-product-card\" className=\"desktop:mt-6 desktop:px-16 lg-desktop:px-[calc(50%-832px)]\">\n <Grid className=\"desktop:gap-4 lg-desktop:gap-8 gap-8\">\n <GridItem className=\"col-span-12 laptop:px-0 desktop:col-start-1 desktop:col-span-8 desktop:sticky desktop:top-[124px] h-fit\">\n {BoxLeftGallery}\n </GridItem>\n <GridItem className=\"col-span-12 desktop:col-start-9 desktop:col-span-4\">{BoxRightDetail}</GridItem>\n </Grid>\n {BoxBottomSummary}\n </div>\n )\n}\n\nexport default ProductGridBox\n"],
5
+ "mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GAaM,IAAAI,EAAA,6BAbNC,EAA+B,kCAE/B,MAAMC,EAAiB,CAAC,CACtB,eAAAC,EACA,eAAAC,EACA,iBAAAC,CACF,OAMI,QAAC,OAAI,GAAG,mBAAmB,UAAU,6DACnC,qBAAC,QAAK,UAAU,uCACd,oBAAC,YAAS,UAAU,0GACjB,SAAAF,EACH,KACA,OAAC,YAAS,UAAU,qDAAsD,SAAAC,EAAe,GAC3F,EACCC,GACH,EAIJ,IAAOP,EAAQI",
6
+ "names": ["ProductGridBox_exports", "__export", "ProductGridBox_default", "__toCommonJS", "import_jsx_runtime", "import_components", "ProductGridBox", "BoxLeftGallery", "BoxRightDetail", "BoxBottomSummary"]
7
+ }
@@ -0,0 +1,3 @@
1
+ import type { ProductSummaryProps } from './types';
2
+ declare const ProductSummary: ({}: ProductSummaryProps) => import("react/jsx-runtime").JSX.Element | null;
3
+ export default ProductSummary;
@@ -0,0 +1,2 @@
1
+ "use strict";var I=Object.create;var w=Object.defineProperty;var $=Object.getOwnPropertyDescriptor;var T=Object.getOwnPropertyNames;var H=Object.getPrototypeOf,M=Object.prototype.hasOwnProperty;var W=(o,t)=>{for(var l in t)w(o,l,{get:t[l],enumerable:!0})},V=(o,t,l,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let c of T(t))!M.call(o,c)&&c!==l&&w(o,c,{get:()=>t[c],enumerable:!(n=$(t,c))||n.enumerable});return o};var q=(o,t,l)=>(l=o!=null?I(H(o)):{},V(t||!o||!o.__esModule?w(l,"default",{value:o,enumerable:!0}):l,o)),K=o=>V(w({},"__esModule",{value:!0}),o);var Y={};W(Y,{default:()=>X});module.exports=K(Y);var e=require("react/jsx-runtime"),a=require("../../../../../components"),k=require("../../../BizProductProvider"),g=require("react"),f=require("../../../utils"),B=require("../../../../AiuiProvider"),te=require("../../../../../helpers"),z=q(require("decimal.js"));const Q=({})=>{const{locale:o="us",copyWriting:t}=(0,B.useAiuiContext)(),{product:l,variant:n,finalPrice:c,comparePrice:p,coupon:h,selectedOptions:r,selectedVariants:u,totalSavings:y,onAddToCart:R,onBuyNow:D,savingDetail:P,checkedBundle:C,joinedRecommendBuyProducts:s,setJoinedRecommendBuyProducts:b}=(0,k.useBizProductContext)(),[m,x]=(0,g.useState)({bundle:!1,gift:!1,exchange:!1}),[N]=u,S=(0,g.useMemo)(()=>{const[d]=C?.variants||[],O=new z.default(N?.price?.amount||0).minus(d?.price||N?.price?.amount).toNumber();return new z.default(N?.price?.amount||0).minus(P?.coupon).minus(O).toNumber()},[N,y,C]);if(!n.availableForSale)return null;const{bundleVariant:E,giftVariant:F,exchangeVariant:A}=U()||{},[i,v]=(0,g.useState)();(0,g.useEffect)(()=>{v({bundle:s.bundle?void 0:E,gift:s.gift?void 0:F,exchange:s.exchange?void 0:A})},[E,F,s]);const L=(0,g.useMemo)(()=>new z.default(p).minus(P.freeGift).toNumber(),[p,P]);return(0,e.jsx)("div",{className:"ipc-product-summary laptop:px-16 desktop:px-0 mt-8 desktop:mt-16",children:(0,e.jsx)("div",{className:"bg-[#F5F5F7] laptop:rounded-2xl",children:(0,e.jsxs)(a.Grid,{className:"px-4 py-6 tablet:p-8",children:[(0,e.jsxs)(a.GridItem,{className:"col-span-12 laptop:col-start-1 laptop:col-span-5",children:[(0,e.jsx)(a.Heading,{className:"font-bold text-[24px] lg-desktop:text-[48px] laptop:text-[32px] desktop:text-[40px] leading-[1] mb-4 [&>span]:text-[#D1D1D1]",html:`${l.title} is ready <br/><span>Just the way you want it.</span>`}),(0,e.jsx)("div",{className:"aspect-[644/320]",children:(0,e.jsx)(a.Picture,{source:n.image?.url||l?.images?.[0]?.url,className:"h-full w-full",imgClassName:"object-contain h-full"})})]}),(0,e.jsxs)(a.GridItem,{className:"col-span-12 mt-8 laptop:col-start-7 laptop:mt-0 laptop:col-span-6 flex flex-col gap-6 justify-between",children:[(0,e.jsxs)("div",{children:[(0,e.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,e.jsxs)("div",{className:"flex items-center justify-between",children:[(0,e.jsxs)("div",{className:"shrink-0 flex items-center gap-4",children:[(0,e.jsx)(a.Picture,{source:n.image?.url||l?.images?.[0]?.url,className:"size-10 laptop:size-12 lg-desktop:size-16 object-cover border-1 border-[#E4E5E6] rounded-[5px] rounded-lg"}),(0,e.jsxs)("div",{className:"flex flex-col gap-[6px] max-w-[178px] tablet:max-w-none",children:[(0,e.jsx)(a.Text,{className:"font-bold text-[14px] line-clamp-2 desktop:text-[16px] lg-desktop:text-[18px]",html:l.title}),(0,e.jsx)(a.Text,{className:"text-[12px] laptop:text-[14px] desktop:text-[18px] font-bold text-[#6D6D6F]",html:`x1 | ${r.color||r.colour||r.couleur}`})]})]}),(0,e.jsxs)("div",{className:"flex items-center gap-1",children:[(0,e.jsx)(a.Text,{className:"text-base desktop:text-2xl font-bold",html:(0,f.formatPrice)({amount:S,currencyCode:n.price.currencyCode,locale:o})}),y>0&&(0,e.jsx)(a.Text,{className:"text-base desktop:text-2xl laptop:text-xl font-bold line-through text-[#6D6D6F]",html:(0,f.formatPrice)({amount:n?.price?.amount,currencyCode:n.price.currencyCode,locale:o})})]})]}),s?.gift&&(0,e.jsx)(G,{giftOperation:d=>{b?.({...s,gift:void 0}),v?.({...i,gift:d})},status:!!s?.gift,gift:s?.gift,currentJoinedRecommendBuyProducts:m?.gift}),s?.bundle&&(0,e.jsx)(j,{bundleOperation:d=>{b?.({...s,bundle:void 0}),v?.({...i,bundle:d})},status:!!s?.bundle,bundleListItem:s?.bundle,currentJoinedRecommendBuyProducts:m?.bundle}),s?.exchange&&(0,e.jsx)(J,{exchangeOperation:d=>{b?.({...s,exchange:void 0}),v?.({...i,exchange:d})},status:!!s?.exchange,currentJoinedRecommendBuyProducts:m?.exchange,exchange:s?.exchange})]}),(i?.bundle||i?.gift||i?.exchange)&&(0,e.jsxs)("div",{className:"mt-6",children:[(0,e.jsx)(a.Text,{className:"text-sm desktop:text-[18px] font-bold",html:"Recommend Buy"}),(0,e.jsxs)("div",{className:"flex flex-col gap-6 mt-6",children:[i?.exchange&&(0,e.jsx)(J,{exchangeOperation:d=>{b?.({exchange:d}),x({...m,exchange:!1}),v?.({...i,exchange:void 0})},currentJoinedRecommendBuyProducts:m?.exchange,status:!i?.exchange,exchange:i?.exchange}),i?.bundle&&(0,e.jsx)(j,{bundleOperation:d=>{b?.({bundle:d}),x({...m,bundle:!1}),v?.({...i,bundle:void 0})},currentJoinedRecommendBuyProducts:m?.bundle,status:!i?.bundle,bundleListItem:i?.bundle}),i?.gift&&(0,e.jsx)(G,{giftOperation:d=>{b?.({gift:d}),x({...m,gift:!1}),v?.({...i,gift:void 0})},currentJoinedRecommendBuyProducts:m?.gift,status:!i?.gift,gift:i?.gift})]})]})]}),(0,e.jsxs)("div",{className:"text-right",children:[(0,e.jsx)(a.Text,{className:"laptop:text-xl desktop:text-2xl font-bold text-right",html:`${t?.totalPrice} ${(0,f.formatPrice)({amount:c,currencyCode:n.price.currencyCode,locale:o})}`}),y>0&&(0,e.jsx)(a.Text,{className:"text-base laptop:text-xl desktop:text-2xl ml-1 font-bold line-through text-[#6D6D6F]",html:(0,f.formatPrice)({amount:L,currencyCode:n.price.currencyCode,locale:o})}),(0,e.jsxs)("div",{className:"flex gap-3 mt-2 justify-end",children:[(0,e.jsx)(a.Button,{size:"lg",variant:"secondary",className:"w-1/2 tablet:w-auto laptop:w-1/2 desktop:w-auto",onClick:()=>R?.(),children:t?.addToCart}),(0,e.jsx)(a.Button,{size:"lg",variant:"primary",className:"w-1/2 tablet:w-auto laptop:w-1/2 desktop:w-auto",onClick:()=>D?.(),children:t?.shopNow})]})]})]})]})})})},U=()=>{const{bundle:o,variant:t,checkedBundle:l,freeGift:n,checkedGift:c,exchangePurchase:p,checkedExchangePurchase:h}=(0,k.useBizProductContext)();let r,u,y;const{bundleList:R}=o||{},{giftList:D=[]}=n||{},{giftList:P=[]}=p||{},C=R?.filter(x=>x.variants.slice(1,x.variants.length).every(N=>N.variant.availableForSale))||[],[s]=C;r=l||s;const[b]=D?.filter(x=>x.availableForSale);u=c||b;const[m]=P?.filter(x=>x.availableForSale);return y=h||m,{bundleVariant:r,giftVariant:u,exchangeVariant:y}},j=({bundleOperation:o,bundleListItem:t,currentJoinedRecommendBuyProducts:l,status:n})=>{const{locale:c="us"}=(0,B.useAiuiContext)(),{variant:p,setCheckedBundle:h}=(0,k.useBizProductContext)(),r=t?.variants.filter(u=>u.variant.sku!==p.sku);return(0,e.jsxs)("div",{className:"flex items-center justify-between",children:[r?.map(u=>(0,e.jsxs)("div",{className:"flex items-center gap-4",children:[(0,e.jsx)(a.Picture,{source:u?.variant?.image?.url,className:"size-10 laptop:size-12 lg-desktop:size-16 object-cover border-1 border-[#E4E5E6] rounded-[5px] rounded-lg"}),(0,e.jsx)("div",{className:"flex flex-col gap-[6px] line-clamp-2 max-w-[178px] tablet:max-w-none",children:(0,e.jsx)(a.Text,{className:"font-bold text-[14px] desktop:text-[16px] lg-desktop:text-[18px]",html:u.variant.product.title})})]},u.variant.id)),(0,e.jsxs)("div",{className:"flex flex-col items-end gap-1 justify-center",children:[!!t&&(0,e.jsx)(a.Text,{className:"text-base desktop:text-2xl font-bold",html:(0,f.formatPrice)({amount:r[0]?.price,locale:c,currencyCode:r[0]?.variant?.price?.currencyCode})}),!l&&(0,e.jsx)(a.Button,{size:"icon",variant:"link",onClick:()=>{h?.(n?void 0:t),o(t)},className:"shrink-0 size-auto underline",children:n?"Remove":"Add"})]})]})},G=({giftOperation:o,gift:t,currentJoinedRecommendBuyProducts:l,status:n})=>{const{locale:c="us"}=(0,B.useAiuiContext)(),{freeGift:p,setCheckedGift:h}=(0,k.useBizProductContext)(),{freeLabel:r,count:u}=p||{};return(0,e.jsxs)("div",{className:"flex items-center justify-between",children:[(0,e.jsxs)("div",{className:"flex items-center gap-4",children:[(0,e.jsx)(a.Picture,{source:t?.image?.url,className:"size-10 laptop:size-12 lg-desktop:size-16 object-cover border-1 border-[#E4E5E6] rounded-[5px] rounded-lg"}),(0,e.jsxs)("div",{className:"flex flex-col gap-[6px] max-w-[178px] tablet:max-w-none",children:[(0,e.jsx)(a.Text,{className:"font-bold text-[14px] line-clamp-2 desktop:text-[16px] lg-desktop:text-[18px]",html:t?.product?.title}),(0,e.jsx)(a.Text,{className:"text-[12px] laptop:text-[14px] desktop:text-[18px] font-bold text-[#6D6D6F]",html:`x${u} | ${r}`})]})]}),(0,e.jsxs)("div",{className:"flex flex-col items-end gap-2 justify-center",children:[!!t&&(0,e.jsxs)("div",{className:"flex items-center gap-1",children:[(0,e.jsx)(a.Text,{className:"text-base desktop:text-2xl font-bold",html:r}),(0,e.jsx)(a.Text,{className:"text-base desktop:text-2xl font-bold line-through text-[#6D6D6F]",html:(0,f.formatPrice)({amount:t.price.amount,locale:c,currencyCode:t.price.currencyCode})})]}),l&&(0,e.jsx)(a.Button,{size:"icon",variant:"link",onClick:()=>{h?.(n?void 0:t),o(t)},className:"shrink-0 size-auto underline",children:n?"Remove":"Add"})]})]})},J=({exchangeOperation:o,exchange:t,currentJoinedRecommendBuyProducts:l,status:n})=>{const{locale:c="us"}=(0,B.useAiuiContext)(),{setCheckedExchangePurchase:p}=(0,k.useBizProductContext)();return(0,e.jsxs)("div",{className:"flex items-center justify-between",children:[(0,e.jsxs)("div",{className:"flex items-center gap-4",children:[(0,e.jsx)(a.Picture,{source:t?.image?.url,className:"size-10 laptop:size-12 lg-desktop:size-16 object-cover border-1 border-[#E4E5E6] rounded-[5px] rounded-lg"}),(0,e.jsxs)("div",{className:"flex flex-col gap-[6px] max-w-[178px] tablet:max-w-none",children:[(0,e.jsx)(a.Text,{className:"font-bold text-[14px] line-clamp-2 desktop:text-[16px] lg-desktop:text-[18px]",html:t?.product?.title}),(0,e.jsx)(a.Text,{className:"text-[12px] laptop:text-[14px] desktop:text-[18px] font-bold text-[#6D6D6F]"})]})]}),(0,e.jsxs)("div",{className:"flex flex-col items-end gap-2 justify-center",children:[!!t&&(0,e.jsxs)("div",{className:"flex items-center gap-1",children:[(0,e.jsx)(a.Text,{className:"text-base desktop:text-2xl font-bold",html:(0,f.formatPrice)({amount:t.finalPrice?.amount||0,locale:c,currencyCode:t.price.currencyCode})}),(0,e.jsx)(a.Text,{className:"text-base desktop:text-2xl font-bold line-through text-[#6D6D6F]",html:(0,f.formatPrice)({amount:t.price?.amount||0,locale:c,currencyCode:t.price.currencyCode})})]}),l&&(0,e.jsx)(a.Button,{size:"icon",variant:"link",onClick:()=>{p?.(n?void 0:t),o(t)},className:"shrink-0 size-auto underline",children:n?"Remove":"Add"})]})]})};var X=Q;
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../src/biz-components/Listing/components/ProductCard/ProductSummary/index.tsx"],
4
+ "sourcesContent": ["import { Text, Button, Container, Grid, GridItem, Picture, Heading } from '../../../../../components'\nimport type { ProductSummaryProps } from './types'\nimport { useBizProductContext } from '../../../BizProductProvider'\nimport { useEffect, useMemo, useState } from 'react'\nimport { formatPrice } from '../../../utils'\nimport { useAiuiContext } from '../../../../AiuiProvider'\nimport type { BundleListItem, ProductVariant, ProductPrice } from '../../../types/product'\nimport { cn } from '../../../../../helpers'\nimport Decimal from 'decimal.js'\n\nconst ProductSummary = ({}: ProductSummaryProps) => {\n const { locale = 'us', copyWriting } = useAiuiContext()\n const {\n product,\n variant,\n finalPrice,\n comparePrice,\n coupon,\n selectedOptions,\n selectedVariants,\n totalSavings,\n onAddToCart,\n onBuyNow,\n savingDetail,\n checkedBundle,\n joinedRecommendBuyProducts,\n setJoinedRecommendBuyProducts,\n } = useBizProductContext()\n\n const [currentJoinedRecommendBuyProducts, setCurrentJoinedRecommendBuyProducts] = useState<{\n bundle?: boolean\n gift?: boolean\n exchange?: boolean\n }>({\n bundle: false,\n gift: false,\n exchange: false,\n })\n\n const [currentProductVariant] = selectedVariants\n\n const summaryFinalPrice = useMemo(() => {\n const [currentBundleVariant] = checkedBundle?.variants || []\n const currentBundlePrice = new Decimal(currentProductVariant?.price?.amount || 0)\n .minus(currentBundleVariant?.price || currentProductVariant?.price?.amount)\n .toNumber()\n return new Decimal(currentProductVariant?.price?.amount || 0)\n .minus(savingDetail?.coupon)\n .minus(currentBundlePrice)\n .toNumber()\n }, [currentProductVariant, totalSavings, checkedBundle])\n\n const isAvailable = variant.availableForSale\n if (!isAvailable) return null\n\n const { bundleVariant, giftVariant, exchangeVariant } = useRecommendBuyProducts() || {}\n const [initialRecommendBuyProducts, setInitialRecommendBuyProducts] = useState<{\n bundle?: BundleListItem\n gift?: ProductVariant\n exchange?: ProductVariant\n }>()\n\n useEffect(() => {\n setInitialRecommendBuyProducts({\n bundle: joinedRecommendBuyProducts.bundle ? undefined : bundleVariant,\n gift: joinedRecommendBuyProducts.gift ? undefined : giftVariant,\n exchange: joinedRecommendBuyProducts.exchange ? undefined : exchangeVariant,\n })\n }, [bundleVariant, giftVariant, joinedRecommendBuyProducts])\n\n const comparePriceRemovedFreeGift = useMemo(\n () => new Decimal(comparePrice).minus(savingDetail.freeGift).toNumber(),\n [comparePrice, savingDetail]\n )\n\n return (\n <div className=\"ipc-product-summary laptop:px-16 desktop:px-0 mt-8 desktop:mt-16\">\n <div className=\"bg-[#F5F5F7] laptop:rounded-2xl\">\n <Grid className=\"px-4 py-6 tablet:p-8\">\n <GridItem className=\"col-span-12 laptop:col-start-1 laptop:col-span-5\">\n <Heading\n className=\"font-bold text-[24px] lg-desktop:text-[48px] laptop:text-[32px] desktop:text-[40px] leading-[1] mb-4 [&>span]:text-[#D1D1D1]\"\n html={`${product.title} is ready <br/><span>Just the way you want it.</span>`}\n />\n <div className=\"aspect-[644/320]\">\n <Picture\n source={variant.image?.url || product?.images?.[0]?.url}\n className=\"h-full w-full\"\n imgClassName=\"object-contain h-full\"\n />\n </div>\n </GridItem>\n <GridItem className=\"col-span-12 mt-8 laptop:col-start-7 laptop:mt-0 laptop:col-span-6 flex flex-col gap-6 justify-between\">\n <div>\n <div className=\"flex flex-col gap-4\">\n <div className=\"flex items-center justify-between\">\n <div className=\"shrink-0 flex items-center gap-4\">\n <Picture\n source={variant.image?.url || product?.images?.[0]?.url}\n className=\"size-10 laptop:size-12 lg-desktop:size-16 object-cover border-1 border-[#E4E5E6] rounded-[5px] rounded-lg\"\n />\n <div className=\"flex flex-col gap-[6px] max-w-[178px] tablet:max-w-none\">\n <Text\n className=\"font-bold text-[14px] line-clamp-2 desktop:text-[16px] lg-desktop:text-[18px]\"\n html={product.title}\n />\n <Text\n className=\"text-[12px] laptop:text-[14px] desktop:text-[18px] font-bold text-[#6D6D6F]\"\n html={`x1 | ${selectedOptions.color || selectedOptions.colour || selectedOptions.couleur}`}\n />\n </div>\n </div>\n <div className=\"flex items-center gap-1\">\n <Text\n className=\"text-base desktop:text-2xl font-bold\"\n html={formatPrice({\n amount: summaryFinalPrice,\n currencyCode: variant.price.currencyCode,\n locale,\n })}\n />\n {totalSavings > 0 && (\n <Text\n className=\"text-base desktop:text-2xl laptop:text-xl font-bold line-through text-[#6D6D6F]\"\n html={formatPrice({\n amount: variant?.price?.amount,\n currencyCode: variant.price.currencyCode,\n locale,\n })}\n />\n )}\n </div>\n </div>\n {joinedRecommendBuyProducts?.gift && (\n <ProductGiftSummary\n giftOperation={gift => {\n setJoinedRecommendBuyProducts?.({ ...joinedRecommendBuyProducts, gift: undefined })\n setInitialRecommendBuyProducts?.({ ...initialRecommendBuyProducts, gift })\n }}\n status={!!joinedRecommendBuyProducts?.gift}\n gift={joinedRecommendBuyProducts?.gift}\n currentJoinedRecommendBuyProducts={currentJoinedRecommendBuyProducts?.gift}\n />\n )}\n {joinedRecommendBuyProducts?.bundle && (\n <ProductBundleSummary\n bundleOperation={bundle => {\n setJoinedRecommendBuyProducts?.({ ...joinedRecommendBuyProducts, bundle: undefined })\n setInitialRecommendBuyProducts?.({ ...initialRecommendBuyProducts, bundle })\n }}\n status={!!joinedRecommendBuyProducts?.bundle}\n bundleListItem={joinedRecommendBuyProducts?.bundle}\n currentJoinedRecommendBuyProducts={currentJoinedRecommendBuyProducts?.bundle}\n />\n )}\n {joinedRecommendBuyProducts?.exchange && (\n <ProductExchangeSummary\n exchangeOperation={exchange => {\n setJoinedRecommendBuyProducts?.({ ...joinedRecommendBuyProducts, exchange: undefined })\n setInitialRecommendBuyProducts?.({ ...initialRecommendBuyProducts, exchange })\n }}\n status={!!joinedRecommendBuyProducts?.exchange}\n currentJoinedRecommendBuyProducts={currentJoinedRecommendBuyProducts?.exchange}\n exchange={joinedRecommendBuyProducts?.exchange}\n />\n )}\n </div>\n {(initialRecommendBuyProducts?.bundle ||\n initialRecommendBuyProducts?.gift ||\n initialRecommendBuyProducts?.exchange) && (\n <div className=\"mt-6\">\n <Text className=\"text-sm desktop:text-[18px] font-bold\" html={'Recommend Buy'} />\n <div className=\"flex flex-col gap-6 mt-6\">\n {initialRecommendBuyProducts?.exchange && (\n <ProductExchangeSummary\n exchangeOperation={exchange => {\n setJoinedRecommendBuyProducts?.({ exchange })\n setCurrentJoinedRecommendBuyProducts({ ...currentJoinedRecommendBuyProducts, exchange: false })\n setInitialRecommendBuyProducts?.({ ...initialRecommendBuyProducts, exchange: undefined })\n }}\n currentJoinedRecommendBuyProducts={currentJoinedRecommendBuyProducts?.exchange}\n status={!initialRecommendBuyProducts?.exchange}\n exchange={initialRecommendBuyProducts?.exchange}\n />\n )}\n {initialRecommendBuyProducts?.bundle && (\n <ProductBundleSummary\n bundleOperation={bundle => {\n setJoinedRecommendBuyProducts?.({ bundle })\n setCurrentJoinedRecommendBuyProducts({ ...currentJoinedRecommendBuyProducts, bundle: false })\n setInitialRecommendBuyProducts?.({ ...initialRecommendBuyProducts, bundle: undefined })\n }}\n currentJoinedRecommendBuyProducts={currentJoinedRecommendBuyProducts?.bundle}\n status={!initialRecommendBuyProducts?.bundle}\n bundleListItem={initialRecommendBuyProducts?.bundle}\n />\n )}\n {initialRecommendBuyProducts?.gift && (\n <ProductGiftSummary\n giftOperation={gift => {\n setJoinedRecommendBuyProducts?.({ gift })\n setCurrentJoinedRecommendBuyProducts({ ...currentJoinedRecommendBuyProducts, gift: false })\n setInitialRecommendBuyProducts?.({ ...initialRecommendBuyProducts, gift: undefined })\n }}\n currentJoinedRecommendBuyProducts={currentJoinedRecommendBuyProducts?.gift}\n status={!initialRecommendBuyProducts?.gift}\n gift={initialRecommendBuyProducts?.gift}\n />\n )}\n </div>\n </div>\n )}\n </div>\n <div className=\"text-right\">\n <Text\n className=\"laptop:text-xl desktop:text-2xl font-bold text-right\"\n html={`${copyWriting?.totalPrice} ${formatPrice({ amount: finalPrice, currencyCode: variant.price.currencyCode, locale })}`}\n />\n\n {totalSavings > 0 && (\n <Text\n className=\"text-base laptop:text-xl desktop:text-2xl ml-1 font-bold line-through text-[#6D6D6F]\"\n html={formatPrice({\n amount: comparePriceRemovedFreeGift,\n currencyCode: variant.price.currencyCode,\n locale,\n })}\n />\n )}\n <div className=\"flex gap-3 mt-2 justify-end\">\n <Button\n size=\"lg\"\n variant=\"secondary\"\n className=\"w-1/2 tablet:w-auto laptop:w-1/2 desktop:w-auto\"\n onClick={() => onAddToCart?.()}\n >\n {copyWriting?.addToCart}\n </Button>\n <Button\n size=\"lg\"\n variant=\"primary\"\n className=\"w-1/2 tablet:w-auto laptop:w-1/2 desktop:w-auto\"\n onClick={() => onBuyNow?.()}\n >\n {copyWriting?.shopNow}\n </Button>\n </div>\n </div>\n </GridItem>\n </Grid>\n </div>\n </div>\n )\n}\n\nconst useRecommendBuyProducts = () => {\n const { bundle, variant, checkedBundle, freeGift, checkedGift, exchangePurchase, checkedExchangePurchase } =\n useBizProductContext()\n let bundleVariant = undefined\n let giftVariant = undefined\n let exchangeVariant = undefined\n const { bundleList } = bundle || {}\n\n const { giftList = [] } = freeGift || {}\n const { giftList: exchangeList = [] } = exchangePurchase || {}\n\n const availableBundleList =\n bundleList?.filter(bundle =>\n bundle.variants.slice(1, bundle.variants.length).every(v => v.variant.availableForSale)\n ) || []\n\n const [firstAvailableBundle] = availableBundleList\n bundleVariant = checkedBundle || firstAvailableBundle\n\n const [firstAvailableGift] = giftList?.filter(gift => gift.availableForSale)\n giftVariant = checkedGift || firstAvailableGift\n\n const [firstAvailableExchange] = exchangeList?.filter(exchange => exchange.availableForSale)\n exchangeVariant = checkedExchangePurchase || firstAvailableExchange\n\n return { bundleVariant, giftVariant, exchangeVariant }\n}\n\nconst ProductBundleSummary = ({\n bundleOperation,\n bundleListItem,\n currentJoinedRecommendBuyProducts,\n status,\n}: {\n bundleOperation: (bundle: BundleListItem) => void\n bundleListItem: BundleListItem\n currentJoinedRecommendBuyProducts?: boolean\n status?: boolean\n}) => {\n const { locale = 'us' } = useAiuiContext()\n const { variant, setCheckedBundle } = useBizProductContext()\n const bundleVariants = bundleListItem?.variants.filter(v => v.variant.sku !== variant.sku)\n\n return (\n <div className=\"flex items-center justify-between\">\n {bundleVariants?.map(bundleVariant => {\n return (\n <div className=\"flex items-center gap-4\" key={bundleVariant.variant.id}>\n <Picture\n source={bundleVariant?.variant?.image?.url}\n className=\"size-10 laptop:size-12 lg-desktop:size-16 object-cover border-1 border-[#E4E5E6] rounded-[5px] rounded-lg\"\n />\n <div className=\"flex flex-col gap-[6px] line-clamp-2 max-w-[178px] tablet:max-w-none\">\n <Text\n className=\"font-bold text-[14px] desktop:text-[16px] lg-desktop:text-[18px]\"\n html={bundleVariant.variant.product.title}\n />\n </div>\n </div>\n )\n })}\n <div className=\"flex flex-col items-end gap-1 justify-center\">\n {!!bundleListItem && (\n <Text\n className=\"text-base desktop:text-2xl font-bold\"\n html={formatPrice({\n amount: bundleVariants[0]?.price,\n locale,\n currencyCode: bundleVariants[0]?.variant?.price?.currencyCode,\n })}\n />\n )}\n {!currentJoinedRecommendBuyProducts && (\n <Button\n size=\"icon\"\n variant=\"link\"\n onClick={() => {\n setCheckedBundle?.(status ? undefined : bundleListItem)\n bundleOperation(bundleListItem)\n }}\n className=\"shrink-0 size-auto underline\"\n >\n {!!status ? 'Remove' : 'Add'}\n </Button>\n )}\n </div>\n </div>\n )\n}\n\nconst ProductGiftSummary = ({\n giftOperation,\n gift,\n currentJoinedRecommendBuyProducts,\n status,\n}: {\n giftOperation: (gift: ProductVariant) => void\n gift: ProductVariant\n currentJoinedRecommendBuyProducts?: boolean\n status?: boolean\n}) => {\n const { locale = 'us' } = useAiuiContext()\n const { freeGift, setCheckedGift } = useBizProductContext()\n const { freeLabel, count } = freeGift || {}\n\n return (\n <div className=\"flex items-center justify-between\">\n <div className=\"flex items-center gap-4\">\n <Picture\n source={gift?.image?.url}\n className=\"size-10 laptop:size-12 lg-desktop:size-16 object-cover border-1 border-[#E4E5E6] rounded-[5px] rounded-lg\"\n />\n <div className=\"flex flex-col gap-[6px] max-w-[178px] tablet:max-w-none\">\n <Text\n className=\"font-bold text-[14px] line-clamp-2 desktop:text-[16px] lg-desktop:text-[18px]\"\n html={gift?.product?.title}\n />\n <Text\n className=\"text-[12px] laptop:text-[14px] desktop:text-[18px] font-bold text-[#6D6D6F]\"\n html={`x${count} | ${freeLabel}`}\n />\n </div>\n </div>\n <div className=\"flex flex-col items-end gap-2 justify-center\">\n {!!gift && (\n <div className=\"flex items-center gap-1\">\n <Text className=\"text-base desktop:text-2xl font-bold\" html={freeLabel} />\n <Text\n className=\"text-base desktop:text-2xl font-bold line-through text-[#6D6D6F]\"\n html={formatPrice({\n amount: gift.price.amount,\n locale,\n currencyCode: gift.price.currencyCode,\n })}\n />\n </div>\n )}\n {currentJoinedRecommendBuyProducts && (\n <Button\n size=\"icon\"\n variant=\"link\"\n onClick={() => {\n setCheckedGift?.(status ? undefined : gift)\n giftOperation(gift)\n }}\n className=\"shrink-0 size-auto underline\"\n >\n {status ? 'Remove' : 'Add'}\n </Button>\n )}\n </div>\n </div>\n )\n}\n\nconst ProductExchangeSummary = ({\n exchangeOperation,\n exchange,\n currentJoinedRecommendBuyProducts,\n status,\n}: {\n exchangeOperation: (exchange: ProductVariant) => void\n exchange: ProductVariant & { finalPrice?: ProductPrice }\n currentJoinedRecommendBuyProducts?: boolean\n status?: boolean\n}) => {\n const { locale = 'us' } = useAiuiContext()\n const { setCheckedExchangePurchase } = useBizProductContext()\n\n return (\n <div className=\"flex items-center justify-between\">\n <div className=\"flex items-center gap-4\">\n <Picture\n source={exchange?.image?.url}\n className=\"size-10 laptop:size-12 lg-desktop:size-16 object-cover border-1 border-[#E4E5E6] rounded-[5px] rounded-lg\"\n />\n <div className=\"flex flex-col gap-[6px] max-w-[178px] tablet:max-w-none\">\n <Text\n className=\"font-bold text-[14px] line-clamp-2 desktop:text-[16px] lg-desktop:text-[18px]\"\n html={exchange?.product?.title}\n />\n <Text className=\"text-[12px] laptop:text-[14px] desktop:text-[18px] font-bold text-[#6D6D6F]\" />\n </div>\n </div>\n <div className=\"flex flex-col items-end gap-2 justify-center\">\n {!!exchange && (\n <div className=\"flex items-center gap-1\">\n <Text\n className=\"text-base desktop:text-2xl font-bold\"\n html={formatPrice({\n amount: exchange.finalPrice?.amount || 0,\n locale,\n currencyCode: exchange.price.currencyCode,\n })}\n />\n <Text\n className=\"text-base desktop:text-2xl font-bold line-through text-[#6D6D6F]\"\n html={formatPrice({\n amount: exchange.price?.amount || 0,\n locale,\n currencyCode: exchange.price.currencyCode,\n })}\n />\n </div>\n )}\n {currentJoinedRecommendBuyProducts && (\n <Button\n size=\"icon\"\n variant=\"link\"\n onClick={() => {\n setCheckedExchangePurchase?.(status ? undefined : exchange)\n exchangeOperation(exchange)\n }}\n className=\"shrink-0 size-auto underline\"\n >\n {status ? 'Remove' : 'Add'}\n </Button>\n )}\n </div>\n </div>\n )\n}\n\nexport default ProductSummary\n"],
5
+ "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GA+EU,IAAAI,EAAA,6BA/EVC,EAA0E,qCAE1EC,EAAqC,uCACrCC,EAA6C,iBAC7CC,EAA4B,0BAC5BC,EAA+B,oCAE/BC,GAAmB,kCACnBC,EAAoB,yBAEpB,MAAMC,EAAiB,CAAC,CAAC,IAA2B,CAClD,KAAM,CAAE,OAAAC,EAAS,KAAM,YAAAC,CAAY,KAAI,kBAAe,EAChD,CACJ,QAAAC,EACA,QAAAC,EACA,WAAAC,EACA,aAAAC,EACA,OAAAC,EACA,gBAAAC,EACA,iBAAAC,EACA,aAAAC,EACA,YAAAC,EACA,SAAAC,EACA,aAAAC,EACA,cAAAC,EACA,2BAAAC,EACA,8BAAAC,CACF,KAAI,wBAAqB,EAEnB,CAACC,EAAmCC,CAAoC,KAAI,YAI/E,CACD,OAAQ,GACR,KAAM,GACN,SAAU,EACZ,CAAC,EAEK,CAACC,CAAqB,EAAIV,EAE1BW,KAAoB,WAAQ,IAAM,CACtC,KAAM,CAACC,CAAoB,EAAIP,GAAe,UAAY,CAAC,EACrDQ,EAAqB,IAAI,EAAAC,QAAQJ,GAAuB,OAAO,QAAU,CAAC,EAC7E,MAAME,GAAsB,OAASF,GAAuB,OAAO,MAAM,EACzE,SAAS,EACZ,OAAO,IAAI,EAAAI,QAAQJ,GAAuB,OAAO,QAAU,CAAC,EACzD,MAAMN,GAAc,MAAM,EAC1B,MAAMS,CAAkB,EACxB,SAAS,CACd,EAAG,CAACH,EAAuBT,EAAcI,CAAa,CAAC,EAGvD,GAAI,CADgBV,EAAQ,iBACV,OAAO,KAEzB,KAAM,CAAE,cAAAoB,EAAe,Y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", "__toCommonJS", "import_jsx_runtime", "import_components", "import_BizProductProvider", "import_react", "import_utils", "import_AiuiProvider", "import_helpers", "import_decimal", "ProductSummary", "locale", "copyWriting", "product", "variant", "finalPrice", "comparePrice", "coupon", "selectedOptions", "selectedVariants", "totalSavings", "onAddToCart", "onBuyNow", "savingDetail", "checkedBundle", "joinedRecommendBuyProducts", "setJoinedRecommendBuyProducts", "currentJoinedRecommendBuyProducts", "setCurrentJoinedRecommendBuyProducts", "currentProductVariant", "summaryFinalPrice", "currentBundleVariant", "currentBundlePrice", "Decimal", "bundleVariant", "giftVariant", "exchangeVariant", "useRecommendBuyProducts", "initialRecommendBuyProducts", "setInitialRecommendBuyProducts", "comparePriceRemovedFreeGift", "ProductGiftSummary", "gift", "ProductBundleSummary", "bundle", "ProductExchangeSummary", "exchange", "freeGift", "checkedGift", "exchangePurchase", "checkedExchangePurchase", "bundleList", "giftList", "exchangeList", "availableBundleList", "v", "firstAvailableBundle", "firstAvailableGift", "firstAvailableExchange", "bundleOperation", "bundleListItem", "status", "setCheckedBundle", "bundleVariants", "giftOperation", "setCheckedGift", "freeLabel", "count", "exchangeOperation", "setCheckedExchangePurchase"]
7
+ }
@@ -0,0 +1,2 @@
1
+ export interface ProductSummaryProps {
2
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";var a=Object.defineProperty;var m=Object.getOwnPropertyDescriptor;var p=Object.getOwnPropertyNames;var u=Object.prototype.hasOwnProperty;var P=(e,r,c,t)=>{if(r&&typeof r=="object"||typeof r=="function")for(let o of p(r))!u.call(e,o)&&o!==c&&a(e,o,{get:()=>r[o],enumerable:!(t=m(r,o))||t.enumerable});return e};var d=e=>P(a({},"__esModule",{value:!0}),e);var f={};module.exports=d(f);
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../../../../src/biz-components/Listing/components/ProductCard/ProductSummary/types.ts"],
4
+ "sourcesContent": ["export interface ProductSummaryProps {\n}\n"],
5
+ "mappings": "+WAAA,IAAAA,EAAA,kBAAAC,EAAAD",
6
+ "names": ["types_exports", "__toCommonJS"]
7
+ }