@anker-in/headless-ui 1.3.21 → 1.3.22-alpha.1781754422536

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 (623) hide show
  1. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoriesProductGrid/index.d.ts +11 -0
  2. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoriesProductGrid/index.js +2 -0
  3. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoriesProductGrid/index.js.map +7 -0
  4. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/ProductCard.d.ts +23 -0
  5. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/ProductCard.js +2 -0
  6. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/ProductCard.js.map +7 -0
  7. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/index.d.ts +40 -0
  8. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/index.js +2 -0
  9. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/index.js.map +7 -0
  10. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/types.d.ts +103 -0
  11. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/types.js +2 -0
  12. package/dist/cjs/biz-components/AccessoriesShelf/components/AccessoryShelf/types.js.map +7 -0
  13. package/dist/cjs/biz-components/AccessoriesShelf/components/MainProductArea/index.d.ts +27 -0
  14. package/dist/cjs/biz-components/AccessoriesShelf/components/MainProductArea/index.js +2 -0
  15. package/dist/cjs/biz-components/AccessoriesShelf/components/MainProductArea/index.js.map +7 -0
  16. package/dist/cjs/biz-components/AccessoriesShelf/components/ProductGrid/index.d.ts +11 -0
  17. package/dist/cjs/biz-components/AccessoriesShelf/components/ProductGrid/index.js +2 -0
  18. package/dist/cjs/biz-components/AccessoriesShelf/components/ProductGrid/index.js.map +7 -0
  19. package/dist/cjs/biz-components/AccessoriesShelf/components/PromoBanner/index.d.ts +10 -0
  20. package/dist/cjs/biz-components/AccessoriesShelf/components/PromoBanner/index.js +2 -0
  21. package/dist/cjs/biz-components/AccessoriesShelf/components/PromoBanner/index.js.map +7 -0
  22. package/dist/cjs/biz-components/AccessoriesShelf/components/SectionHeader/index.d.ts +9 -0
  23. package/dist/cjs/biz-components/AccessoriesShelf/components/SectionHeader/index.js +2 -0
  24. package/dist/cjs/biz-components/AccessoriesShelf/components/SectionHeader/index.js.map +7 -0
  25. package/dist/cjs/biz-components/AccessoriesShelf/index.d.ts +8 -0
  26. package/dist/cjs/biz-components/AccessoriesShelf/index.js +2 -0
  27. package/dist/cjs/biz-components/AccessoriesShelf/index.js.map +7 -0
  28. package/dist/cjs/biz-components/AccessoriesShelf/product.d.ts +280 -0
  29. package/dist/cjs/biz-components/AccessoriesShelf/product.js +2 -0
  30. package/dist/cjs/biz-components/AccessoriesShelf/product.js.map +7 -0
  31. package/dist/cjs/biz-components/AccessoriesShelf/types.d.ts +43 -0
  32. package/dist/cjs/biz-components/AccessoriesShelf/types.js +2 -0
  33. package/dist/cjs/biz-components/AccessoriesShelf/types.js.map +7 -0
  34. package/dist/cjs/biz-components/AccordionCards/index.d.ts +1 -1
  35. package/dist/cjs/biz-components/ActiveShelf/index.d.ts +1 -1
  36. package/dist/cjs/biz-components/ActivityMechanism/index.js +1 -1
  37. package/dist/cjs/biz-components/ActivityMechanism/index.js.map +3 -3
  38. package/dist/cjs/biz-components/ActivitySchedule/index.d.ts +1 -1
  39. package/dist/cjs/biz-components/ActivitySchedule/index.js +1 -1
  40. package/dist/cjs/biz-components/ActivitySchedule/index.js.map +3 -3
  41. package/dist/cjs/biz-components/AiuiProvider/index.d.ts +6 -0
  42. package/dist/cjs/biz-components/AiuiProvider/index.js +1 -1
  43. package/dist/cjs/biz-components/AiuiProvider/index.js.map +3 -3
  44. package/dist/cjs/biz-components/AnchorNavigation/index.d.ts +1 -1
  45. package/dist/cjs/biz-components/AnchorNavigation/index.js +1 -1
  46. package/dist/cjs/biz-components/AnchorNavigation/index.js.map +3 -3
  47. package/dist/cjs/biz-components/AplusDesc/index.d.ts +1 -1
  48. package/dist/cjs/biz-components/BrandCardLink/BrandCardLink.d.ts +1 -1
  49. package/dist/cjs/biz-components/BrandCardLink/BrandCardLink.js +1 -1
  50. package/dist/cjs/biz-components/BrandCardLink/BrandCardLink.js.map +3 -3
  51. package/dist/cjs/biz-components/BrandEquity/BrandEquity.d.ts +1 -1
  52. package/dist/cjs/biz-components/BrandEquity/BrandEquity.js +1 -1
  53. package/dist/cjs/biz-components/BrandEquity/BrandEquity.js.map +3 -3
  54. package/dist/cjs/biz-components/BuyOneGetOneShelf/ProductCard.d.ts +1 -1
  55. package/dist/cjs/biz-components/BuyOneGetOneShelf/ProductCard.js +1 -1
  56. package/dist/cjs/biz-components/BuyOneGetOneShelf/ProductCard.js.map +3 -3
  57. package/dist/cjs/biz-components/BuyOneGetOneShelf/context.d.ts +4 -0
  58. package/dist/cjs/biz-components/BuyOneGetOneShelf/context.js +2 -0
  59. package/dist/cjs/biz-components/BuyOneGetOneShelf/context.js.map +7 -0
  60. package/dist/cjs/biz-components/BuyOneGetOneShelf/types.d.ts +1 -1
  61. package/dist/cjs/biz-components/BuyOneGetOneShelf/types.js.map +1 -1
  62. package/dist/cjs/biz-components/Category/SwiperCategory.js +1 -1
  63. package/dist/cjs/biz-components/Category/SwiperCategory.js.map +3 -3
  64. package/dist/cjs/biz-components/Category/index.d.ts +1 -1
  65. package/dist/cjs/biz-components/Category/index.js +1 -1
  66. package/dist/cjs/biz-components/Category/index.js.map +3 -3
  67. package/dist/cjs/biz-components/CreativeModule/index.d.ts +1 -1
  68. package/dist/cjs/biz-components/DownLoad/index.d.ts +1 -1
  69. package/dist/cjs/biz-components/Evaluate/index.d.ts +1 -1
  70. package/dist/cjs/biz-components/Evaluate/index.js +1 -1
  71. package/dist/cjs/biz-components/Evaluate/index.js.map +3 -3
  72. package/dist/cjs/biz-components/EventSchedule/index.d.ts +1 -1
  73. package/dist/cjs/biz-components/EventSchedule/index.js +1 -1
  74. package/dist/cjs/biz-components/EventSchedule/index.js.map +3 -3
  75. package/dist/cjs/biz-components/Faq/Faq.d.ts +1 -1
  76. package/dist/cjs/biz-components/FeatureCards/FeatureCards.d.ts +1 -1
  77. package/dist/cjs/biz-components/FeatureCards/FeatureCards.js +1 -1
  78. package/dist/cjs/biz-components/FeatureCards/FeatureCards.js.map +3 -3
  79. package/dist/cjs/biz-components/FeatureShowcase/FeatureShowcase.d.ts +1 -1
  80. package/dist/cjs/biz-components/FeaturedBlogPosts/index.d.ts +1 -1
  81. package/dist/cjs/biz-components/FeaturedBlogPosts/index.js +1 -1
  82. package/dist/cjs/biz-components/FeaturedBlogPosts/index.js.map +2 -2
  83. package/dist/cjs/biz-components/Features/index.d.ts +1 -1
  84. package/dist/cjs/biz-components/FootCharger/index.d.ts +1 -1
  85. package/dist/cjs/biz-components/FooterNavigation/index.d.ts +1 -1
  86. package/dist/cjs/biz-components/FooterNavigation/index.js +1 -1
  87. package/dist/cjs/biz-components/FooterNavigation/index.js.map +3 -3
  88. package/dist/cjs/biz-components/GiftBox/index.d.ts +1 -1
  89. package/dist/cjs/biz-components/GiftShelf/index.d.ts +1 -1
  90. package/dist/cjs/biz-components/GiftShelf/index.js +1 -1
  91. package/dist/cjs/biz-components/GiftShelf/index.js.map +2 -2
  92. package/dist/cjs/biz-components/GiftTierShelf/index.d.ts +1 -1
  93. package/dist/cjs/biz-components/Graphic/index.d.ts +1 -1
  94. package/dist/cjs/biz-components/Graphic/index.js +1 -1
  95. package/dist/cjs/biz-components/Graphic/index.js.map +3 -3
  96. package/dist/cjs/biz-components/GraphicAttractionBlock/index.d.ts +1 -1
  97. package/dist/cjs/biz-components/GraphicOverlay/GraphicOverlay.d.ts +2 -2
  98. package/dist/cjs/biz-components/GraphicOverlay/GraphicOverlay.js +1 -1
  99. package/dist/cjs/biz-components/GraphicOverlay/GraphicOverlay.js.map +3 -3
  100. package/dist/cjs/biz-components/HeaderNavigation/MobileTextLinksMenu.d.ts +12 -0
  101. package/dist/cjs/biz-components/HeaderNavigation/MobileTextLinksMenu.js +2 -0
  102. package/dist/cjs/biz-components/HeaderNavigation/MobileTextLinksMenu.js.map +7 -0
  103. package/dist/cjs/biz-components/HeaderNavigation/MulticolDropdown.js +1 -1
  104. package/dist/cjs/biz-components/HeaderNavigation/MulticolDropdown.js.map +2 -2
  105. package/dist/cjs/biz-components/HeaderNavigation/TextLinksDropdown.d.ts +10 -0
  106. package/dist/cjs/biz-components/HeaderNavigation/TextLinksDropdown.js +2 -0
  107. package/dist/cjs/biz-components/HeaderNavigation/TextLinksDropdown.js.map +7 -0
  108. package/dist/cjs/biz-components/HeaderNavigation/index.d.ts +1 -1
  109. package/dist/cjs/biz-components/HeaderNavigation/index.js +1 -1
  110. package/dist/cjs/biz-components/HeaderNavigation/index.js.map +3 -3
  111. package/dist/cjs/biz-components/HeaderNavigation/types.d.ts +11 -1
  112. package/dist/cjs/biz-components/HeaderNavigation/types.js +1 -1
  113. package/dist/cjs/biz-components/HeaderNavigation/types.js.map +2 -2
  114. package/dist/cjs/biz-components/HeaderNavigation/withCategory.d.ts +1 -0
  115. package/dist/cjs/biz-components/HeaderNavigation/withCategory.js +1 -1
  116. package/dist/cjs/biz-components/HeaderNavigation/withCategory.js.map +3 -3
  117. package/dist/cjs/biz-components/HeroBanner/HeroBanner.d.ts +1 -1
  118. package/dist/cjs/biz-components/HeroBanner/HeroBanner.js +1 -1
  119. package/dist/cjs/biz-components/HeroBanner/HeroBanner.js.map +3 -3
  120. package/dist/cjs/biz-components/HeroBanner/HeroBannerCarousel.js +1 -1
  121. package/dist/cjs/biz-components/HeroBanner/HeroBannerCarousel.js.map +3 -3
  122. package/dist/cjs/biz-components/ImageOverlayShelf/index.d.ts +1 -1
  123. package/dist/cjs/biz-components/ImageTextFeature/ImageTextFeature.d.ts +1 -1
  124. package/dist/cjs/biz-components/ImageTextOverlay/index.d.ts +1 -1
  125. package/dist/cjs/biz-components/ImageTextOverlay/index.js +2 -2
  126. package/dist/cjs/biz-components/ImageTextOverlay/index.js.map +3 -3
  127. package/dist/cjs/biz-components/ImageWithText/ImageWithText.d.ts +1 -1
  128. package/dist/cjs/biz-components/ImageWithText/ImageWithText.js +1 -1
  129. package/dist/cjs/biz-components/ImageWithText/ImageWithText.js.map +3 -3
  130. package/dist/cjs/biz-components/Ksp/index.d.ts +1 -1
  131. package/dist/cjs/biz-components/Ksp/index.js +1 -1
  132. package/dist/cjs/biz-components/Ksp/index.js.map +3 -3
  133. package/dist/cjs/biz-components/Listing/BizProductProvider.d.ts +3 -1
  134. package/dist/cjs/biz-components/Listing/BizProductProvider.js +1 -1
  135. package/dist/cjs/biz-components/Listing/BizProductProvider.js.map +3 -3
  136. package/dist/cjs/biz-components/Listing/components/CartActionButtons/index.d.ts +9 -1
  137. package/dist/cjs/biz-components/Listing/components/CartActionButtons/index.js +1 -1
  138. package/dist/cjs/biz-components/Listing/components/CartActionButtons/index.js.map +3 -3
  139. package/dist/cjs/biz-components/Listing/components/PaidShipping/index.d.ts +1 -1
  140. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts +1 -1
  141. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.d.ts +1 -1
  142. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.d.ts +1 -1
  143. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.d.ts +1 -1
  144. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.d.ts +1 -1
  145. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.d.ts +1 -1
  146. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/index.d.ts +1 -1
  147. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductPaidShipping/index.d.ts +1 -1
  148. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.d.ts +1 -1
  149. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.js +1 -1
  150. package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.js.map +3 -3
  151. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ProductActions/index.js +1 -1
  152. package/dist/cjs/biz-components/Listing/components/PurchaseBar/ProductActions/index.js.map +3 -3
  153. package/dist/cjs/biz-components/Listing/components/PurchaseBar/index.d.ts +1 -1
  154. package/dist/cjs/biz-components/LotteryShared/ErrorModal.d.ts +4 -0
  155. package/dist/cjs/biz-components/LotteryShared/ErrorModal.js.map +2 -2
  156. package/dist/cjs/biz-components/LotteryShared/MyRewardsModal.d.ts +13 -13
  157. package/dist/cjs/biz-components/LotteryShared/MyRewardsModal.js +1 -1
  158. package/dist/cjs/biz-components/LotteryShared/MyRewardsModal.js.map +3 -3
  159. package/dist/cjs/biz-components/LotteryShared/types.d.ts +9 -0
  160. package/dist/cjs/biz-components/LotteryShared/types.js.map +2 -2
  161. package/dist/cjs/biz-components/Marquee/Marquee.d.ts +1 -1
  162. package/dist/cjs/biz-components/MarqueeReview/index.d.ts +1 -1
  163. package/dist/cjs/biz-components/Media/index.js +1 -1
  164. package/dist/cjs/biz-components/Media/index.js.map +3 -3
  165. package/dist/cjs/biz-components/MediaEndorsement/index.d.ts +1 -1
  166. package/dist/cjs/biz-components/MediaEndorsement/index.js +2 -2
  167. package/dist/cjs/biz-components/MediaEndorsement/index.js.map +3 -3
  168. package/dist/cjs/biz-components/MediaPlayerBase/index.d.ts +1 -1
  169. package/dist/cjs/biz-components/MediaPlayerBase/index.js +1 -1
  170. package/dist/cjs/biz-components/MediaPlayerBase/index.js.map +3 -3
  171. package/dist/cjs/biz-components/MediaPlayerMulti/index.d.ts +1 -1
  172. package/dist/cjs/biz-components/MediaPlayerMulti/index.js +1 -1
  173. package/dist/cjs/biz-components/MediaPlayerMulti/index.js.map +3 -3
  174. package/dist/cjs/biz-components/MediaPlayerSticky/index.d.ts +1 -1
  175. package/dist/cjs/biz-components/MediaPlayerSticky/index.js +1 -1
  176. package/dist/cjs/biz-components/MediaPlayerSticky/index.js.map +3 -3
  177. package/dist/cjs/biz-components/MediaSceneSwitcher/MediaSceneSwitcher.d.ts +1 -1
  178. package/dist/cjs/biz-components/MediaSceneSwitcher/MediaSceneSwitcher.js +2 -2
  179. package/dist/cjs/biz-components/MediaSceneSwitcher/MediaSceneSwitcher.js.map +3 -3
  180. package/dist/cjs/biz-components/MediaSceneSwitcherV2/index.d.ts +1 -1
  181. package/dist/cjs/biz-components/MediaSceneSwitcherV2/index.js +1 -1
  182. package/dist/cjs/biz-components/MediaSceneSwitcherV2/index.js.map +3 -3
  183. package/dist/cjs/biz-components/MediaShelf/index.d.ts +1 -1
  184. package/dist/cjs/biz-components/MediaTextOverlay/MediaTextOverlay.d.ts +1 -1
  185. package/dist/cjs/biz-components/MediaTextOverlay/MediaTextOverlay.js +1 -1
  186. package/dist/cjs/biz-components/MediaTextOverlay/MediaTextOverlay.js.map +3 -3
  187. package/dist/cjs/biz-components/MemberEquity/index.d.ts +1 -1
  188. package/dist/cjs/biz-components/MemberEquity/index.js +2 -2
  189. package/dist/cjs/biz-components/MemberEquity/index.js.map +3 -3
  190. package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.d.ts +2 -2
  191. package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js +1 -1
  192. package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js.map +3 -3
  193. package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlockCarousel.js +1 -1
  194. package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlockCarousel.js.map +2 -2
  195. package/dist/cjs/biz-components/NavigationSearch/index.d.ts +1 -1
  196. package/dist/cjs/biz-components/NavigationSearch/index.js +2 -2
  197. package/dist/cjs/biz-components/NavigationSearch/index.js.map +2 -2
  198. package/dist/cjs/biz-components/NotifyMeDialog/NotifyMeDialog.d.ts +7 -0
  199. package/dist/cjs/biz-components/NotifyMeDialog/NotifyMeDialog.js +2 -0
  200. package/dist/cjs/biz-components/NotifyMeDialog/NotifyMeDialog.js.map +7 -0
  201. package/dist/cjs/biz-components/NotifyMeDialog/index.d.ts +2 -0
  202. package/dist/cjs/biz-components/NotifyMeDialog/index.js +2 -0
  203. package/dist/cjs/biz-components/NotifyMeDialog/index.js.map +7 -0
  204. package/dist/cjs/biz-components/NotifyMeDialog/types.d.ts +111 -0
  205. package/dist/cjs/biz-components/NotifyMeDialog/types.js +2 -0
  206. package/dist/cjs/biz-components/NotifyMeDialog/types.js.map +7 -0
  207. package/dist/cjs/biz-components/ProductCompare/index.d.ts +1 -1
  208. package/dist/cjs/biz-components/ProductCompare/index.js +1 -1
  209. package/dist/cjs/biz-components/ProductCompare/index.js.map +2 -2
  210. package/dist/cjs/biz-components/ProductHero/ProductHero.d.ts +1 -1
  211. package/dist/cjs/biz-components/ProductHero/ProductHero.js +1 -1
  212. package/dist/cjs/biz-components/ProductHero/ProductHero.js.map +3 -3
  213. package/dist/cjs/biz-components/ProductLottery/types.d.ts +62 -5
  214. package/dist/cjs/biz-components/ProductLottery/types.js +1 -1
  215. package/dist/cjs/biz-components/ProductLottery/types.js.map +2 -2
  216. package/dist/cjs/biz-components/ProductNav/ProductNav.d.ts +1 -1
  217. package/dist/cjs/biz-components/ProductNav/ProductNav.js +1 -1
  218. package/dist/cjs/biz-components/ProductNav/ProductNav.js.map +3 -3
  219. package/dist/cjs/biz-components/PromotionalBar/index.d.ts +1 -1
  220. package/dist/cjs/biz-components/PromotionalBar/index.js +1 -1
  221. package/dist/cjs/biz-components/PromotionalBar/index.js.map +3 -3
  222. package/dist/cjs/biz-components/SceneShelfV2/index.d.ts +1 -1
  223. package/dist/cjs/biz-components/SceneShelfV3/index.d.ts +1 -1
  224. package/dist/cjs/biz-components/SearchPage/index.js +1 -1
  225. package/dist/cjs/biz-components/SearchPage/index.js.map +3 -3
  226. package/dist/cjs/biz-components/SecondaryBanner/index.d.ts +1 -1
  227. package/dist/cjs/biz-components/SecondaryBanner/index.js +1 -1
  228. package/dist/cjs/biz-components/SecondaryBanner/index.js.map +2 -2
  229. package/dist/cjs/biz-components/SelectStore/index.d.ts +1 -1
  230. package/dist/cjs/biz-components/ShelfDisplay/index.d.ts +1 -1
  231. package/dist/cjs/biz-components/ShelfDisplay/shelfDisplayItem.js +1 -1
  232. package/dist/cjs/biz-components/ShelfDisplay/shelfDisplayItem.js.map +3 -3
  233. package/dist/cjs/biz-components/Slogan/index.d.ts +1 -1
  234. package/dist/cjs/biz-components/Spacer/index.d.ts +1 -1
  235. package/dist/cjs/biz-components/Specs/index.d.ts +1 -1
  236. package/dist/cjs/biz-components/Specs/index.js +1 -1
  237. package/dist/cjs/biz-components/Specs/index.js.map +3 -3
  238. package/dist/cjs/biz-components/SpecsComparison/SpecsComparison.d.ts +1 -1
  239. package/dist/cjs/biz-components/Subscribe/index.js +1 -1
  240. package/dist/cjs/biz-components/Subscribe/index.js.map +2 -2
  241. package/dist/cjs/biz-components/SwiperBox/index.js +1 -1
  242. package/dist/cjs/biz-components/SwiperBox/index.js.map +3 -3
  243. package/dist/cjs/biz-components/TabWithImage/TabWithImage.d.ts +1 -1
  244. package/dist/cjs/biz-components/Tabs/Tabs.d.ts +1 -1
  245. package/dist/cjs/biz-components/TabsGroup/index.d.ts +1 -1
  246. package/dist/cjs/biz-components/TabsWithMedia/TabsWithMedia.d.ts +1 -1
  247. package/dist/cjs/biz-components/TabsWithMedia/TabsWithMedia.js +1 -1
  248. package/dist/cjs/biz-components/TabsWithMedia/TabsWithMedia.js.map +3 -3
  249. package/dist/cjs/biz-components/ThreeDCarousel/ThreeDCarousel.d.ts +1 -1
  250. package/dist/cjs/biz-components/ThreeDCarousel/ThreeDCarousel.js +1 -1
  251. package/dist/cjs/biz-components/ThreeDCarousel/ThreeDCarousel.js.map +3 -3
  252. package/dist/cjs/biz-components/Title/index.d.ts +1 -1
  253. package/dist/cjs/biz-components/Title/index.js +1 -1
  254. package/dist/cjs/biz-components/Title/index.js.map +3 -3
  255. package/dist/cjs/biz-components/VideoFeature/VideoFeature.d.ts +1 -1
  256. package/dist/cjs/biz-components/VideoModal/index.d.ts +1 -0
  257. package/dist/cjs/biz-components/VideoModal/index.js +1 -1
  258. package/dist/cjs/biz-components/VideoModal/index.js.map +3 -3
  259. package/dist/cjs/biz-components/WheelLottery/index.js +1 -1
  260. package/dist/cjs/biz-components/WheelLottery/index.js.map +3 -3
  261. package/dist/cjs/biz-components/WhyChoose/WhyChoose.d.ts +1 -1
  262. package/dist/cjs/biz-components/index.d.ts +8 -0
  263. package/dist/cjs/biz-components/index.js +1 -1
  264. package/dist/cjs/biz-components/index.js.map +3 -3
  265. package/dist/cjs/components/Countdown.js +1 -1
  266. package/dist/cjs/components/Countdown.js.map +3 -3
  267. package/dist/cjs/components/alert.d.ts +1 -0
  268. package/dist/cjs/components/alert.js +1 -1
  269. package/dist/cjs/components/alert.js.map +2 -2
  270. package/dist/cjs/components/breadcrumb.d.ts +12 -0
  271. package/dist/cjs/components/breadcrumb.js +2 -0
  272. package/dist/cjs/components/breadcrumb.js.map +7 -0
  273. package/dist/cjs/components/checkbox.js +1 -1
  274. package/dist/cjs/components/checkbox.js.map +2 -2
  275. package/dist/cjs/components/dialog.js +1 -1
  276. package/dist/cjs/components/dialog.js.map +3 -3
  277. package/dist/cjs/components/index.d.ts +5 -0
  278. package/dist/cjs/components/index.js +1 -1
  279. package/dist/cjs/components/index.js.map +3 -3
  280. package/dist/cjs/components/input-number.d.ts +22 -0
  281. package/dist/cjs/components/input-number.js +1 -1
  282. package/dist/cjs/components/input-number.js.map +3 -3
  283. package/dist/cjs/components/link.js +1 -1
  284. package/dist/cjs/components/link.js.map +2 -2
  285. package/dist/cjs/components/otp-input.d.ts +18 -0
  286. package/dist/cjs/components/otp-input.js +2 -0
  287. package/dist/cjs/components/otp-input.js.map +7 -0
  288. package/dist/cjs/components/toast.d.ts +25 -0
  289. package/dist/cjs/components/toast.js +2 -0
  290. package/dist/cjs/components/toast.js.map +7 -0
  291. package/dist/cjs/helpers/index.d.ts +2 -2
  292. package/dist/cjs/helpers/index.js +1 -1
  293. package/dist/cjs/helpers/index.js.map +2 -2
  294. package/dist/cjs/helpers/isLexicalEmpty.d.ts +5 -0
  295. package/dist/cjs/helpers/isLexicalEmpty.js +1 -1
  296. package/dist/cjs/helpers/isLexicalEmpty.js.map +3 -3
  297. package/dist/cjs/helpers/priceFormatting.d.ts +5 -0
  298. package/dist/cjs/helpers/priceFormatting.js +1 -1
  299. package/dist/cjs/helpers/priceFormatting.js.map +3 -3
  300. package/dist/cjs/helpers/utils.d.ts +7 -1
  301. package/dist/cjs/helpers/utils.js +1 -1
  302. package/dist/cjs/helpers/utils.js.map +3 -3
  303. package/dist/cjs/hooks/useIsomorphicMediaQuery.d.ts +14 -0
  304. package/dist/cjs/hooks/useIsomorphicMediaQuery.js +2 -0
  305. package/dist/cjs/hooks/useIsomorphicMediaQuery.js.map +7 -0
  306. package/dist/cjs/hooks/useProductListTrack.d.ts +43 -0
  307. package/dist/cjs/hooks/useProductListTrack.js +2 -0
  308. package/dist/cjs/hooks/useProductListTrack.js.map +7 -0
  309. package/dist/cjs/index.d.ts +10 -0
  310. package/dist/cjs/index.js +1 -1
  311. package/dist/cjs/index.js.map +3 -3
  312. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoriesProductGrid/index.d.ts +11 -0
  313. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoriesProductGrid/index.js +2 -0
  314. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoriesProductGrid/index.js.map +7 -0
  315. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/ProductCard.d.ts +23 -0
  316. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/ProductCard.js +2 -0
  317. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/ProductCard.js.map +7 -0
  318. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/index.d.ts +40 -0
  319. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/index.js +2 -0
  320. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/index.js.map +7 -0
  321. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/types.d.ts +103 -0
  322. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/types.js +1 -0
  323. package/dist/esm/biz-components/AccessoriesShelf/components/AccessoryShelf/types.js.map +7 -0
  324. package/dist/esm/biz-components/AccessoriesShelf/components/MainProductArea/index.d.ts +27 -0
  325. package/dist/esm/biz-components/AccessoriesShelf/components/MainProductArea/index.js +2 -0
  326. package/dist/esm/biz-components/AccessoriesShelf/components/MainProductArea/index.js.map +7 -0
  327. package/dist/esm/biz-components/AccessoriesShelf/components/ProductGrid/index.d.ts +11 -0
  328. package/dist/esm/biz-components/AccessoriesShelf/components/ProductGrid/index.js +2 -0
  329. package/dist/esm/biz-components/AccessoriesShelf/components/ProductGrid/index.js.map +7 -0
  330. package/dist/esm/biz-components/AccessoriesShelf/components/PromoBanner/index.d.ts +10 -0
  331. package/dist/esm/biz-components/AccessoriesShelf/components/PromoBanner/index.js +2 -0
  332. package/dist/esm/biz-components/AccessoriesShelf/components/PromoBanner/index.js.map +7 -0
  333. package/dist/esm/biz-components/AccessoriesShelf/components/SectionHeader/index.d.ts +9 -0
  334. package/dist/esm/biz-components/AccessoriesShelf/components/SectionHeader/index.js +2 -0
  335. package/dist/esm/biz-components/AccessoriesShelf/components/SectionHeader/index.js.map +7 -0
  336. package/dist/esm/biz-components/AccessoriesShelf/index.d.ts +8 -0
  337. package/dist/esm/biz-components/AccessoriesShelf/index.js +2 -0
  338. package/dist/esm/biz-components/AccessoriesShelf/index.js.map +7 -0
  339. package/dist/esm/biz-components/AccessoriesShelf/product.d.ts +280 -0
  340. package/dist/esm/biz-components/AccessoriesShelf/product.js +1 -0
  341. package/dist/esm/biz-components/AccessoriesShelf/product.js.map +7 -0
  342. package/dist/esm/biz-components/AccessoriesShelf/types.d.ts +43 -0
  343. package/dist/esm/biz-components/AccessoriesShelf/types.js +1 -0
  344. package/dist/esm/biz-components/AccessoriesShelf/types.js.map +7 -0
  345. package/dist/esm/biz-components/AccordionCards/index.d.ts +1 -1
  346. package/dist/esm/biz-components/ActiveShelf/index.d.ts +1 -1
  347. package/dist/esm/biz-components/ActivityMechanism/index.js +1 -1
  348. package/dist/esm/biz-components/ActivityMechanism/index.js.map +3 -3
  349. package/dist/esm/biz-components/ActivitySchedule/index.d.ts +1 -1
  350. package/dist/esm/biz-components/ActivitySchedule/index.js +1 -1
  351. package/dist/esm/biz-components/ActivitySchedule/index.js.map +3 -3
  352. package/dist/esm/biz-components/AiuiProvider/index.d.ts +6 -0
  353. package/dist/esm/biz-components/AiuiProvider/index.js +1 -1
  354. package/dist/esm/biz-components/AiuiProvider/index.js.map +3 -3
  355. package/dist/esm/biz-components/AnchorNavigation/index.d.ts +1 -1
  356. package/dist/esm/biz-components/AnchorNavigation/index.js +1 -1
  357. package/dist/esm/biz-components/AnchorNavigation/index.js.map +3 -3
  358. package/dist/esm/biz-components/AplusDesc/index.d.ts +1 -1
  359. package/dist/esm/biz-components/BrandCardLink/BrandCardLink.d.ts +1 -1
  360. package/dist/esm/biz-components/BrandCardLink/BrandCardLink.js +1 -1
  361. package/dist/esm/biz-components/BrandCardLink/BrandCardLink.js.map +3 -3
  362. package/dist/esm/biz-components/BrandEquity/BrandEquity.d.ts +1 -1
  363. package/dist/esm/biz-components/BrandEquity/BrandEquity.js +1 -1
  364. package/dist/esm/biz-components/BrandEquity/BrandEquity.js.map +3 -3
  365. package/dist/esm/biz-components/BuyOneGetOneShelf/ProductCard.d.ts +1 -1
  366. package/dist/esm/biz-components/BuyOneGetOneShelf/ProductCard.js +1 -1
  367. package/dist/esm/biz-components/BuyOneGetOneShelf/ProductCard.js.map +3 -3
  368. package/dist/esm/biz-components/BuyOneGetOneShelf/context.d.ts +4 -0
  369. package/dist/esm/biz-components/BuyOneGetOneShelf/context.js +2 -0
  370. package/dist/esm/biz-components/BuyOneGetOneShelf/context.js.map +7 -0
  371. package/dist/esm/biz-components/BuyOneGetOneShelf/types.d.ts +1 -1
  372. package/dist/esm/biz-components/BuyOneGetOneShelf/types.js.map +1 -1
  373. package/dist/esm/biz-components/Category/SwiperCategory.js +1 -1
  374. package/dist/esm/biz-components/Category/SwiperCategory.js.map +3 -3
  375. package/dist/esm/biz-components/Category/index.d.ts +1 -1
  376. package/dist/esm/biz-components/Category/index.js +1 -1
  377. package/dist/esm/biz-components/Category/index.js.map +3 -3
  378. package/dist/esm/biz-components/CreativeModule/index.d.ts +1 -1
  379. package/dist/esm/biz-components/DownLoad/index.d.ts +1 -1
  380. package/dist/esm/biz-components/Evaluate/index.d.ts +1 -1
  381. package/dist/esm/biz-components/Evaluate/index.js +1 -1
  382. package/dist/esm/biz-components/Evaluate/index.js.map +3 -3
  383. package/dist/esm/biz-components/EventSchedule/index.d.ts +1 -1
  384. package/dist/esm/biz-components/EventSchedule/index.js +1 -1
  385. package/dist/esm/biz-components/EventSchedule/index.js.map +3 -3
  386. package/dist/esm/biz-components/Faq/Faq.d.ts +1 -1
  387. package/dist/esm/biz-components/FeatureCards/FeatureCards.d.ts +1 -1
  388. package/dist/esm/biz-components/FeatureCards/FeatureCards.js +1 -1
  389. package/dist/esm/biz-components/FeatureCards/FeatureCards.js.map +3 -3
  390. package/dist/esm/biz-components/FeatureShowcase/FeatureShowcase.d.ts +1 -1
  391. package/dist/esm/biz-components/FeaturedBlogPosts/index.d.ts +1 -1
  392. package/dist/esm/biz-components/FeaturedBlogPosts/index.js +1 -1
  393. package/dist/esm/biz-components/FeaturedBlogPosts/index.js.map +2 -2
  394. package/dist/esm/biz-components/Features/index.d.ts +1 -1
  395. package/dist/esm/biz-components/FootCharger/index.d.ts +1 -1
  396. package/dist/esm/biz-components/FooterNavigation/index.d.ts +1 -1
  397. package/dist/esm/biz-components/FooterNavigation/index.js +1 -1
  398. package/dist/esm/biz-components/FooterNavigation/index.js.map +3 -3
  399. package/dist/esm/biz-components/GiftBox/index.d.ts +1 -1
  400. package/dist/esm/biz-components/GiftShelf/index.d.ts +1 -1
  401. package/dist/esm/biz-components/GiftShelf/index.js +1 -1
  402. package/dist/esm/biz-components/GiftShelf/index.js.map +2 -2
  403. package/dist/esm/biz-components/GiftTierShelf/index.d.ts +1 -1
  404. package/dist/esm/biz-components/Graphic/index.d.ts +1 -1
  405. package/dist/esm/biz-components/Graphic/index.js +1 -1
  406. package/dist/esm/biz-components/Graphic/index.js.map +3 -3
  407. package/dist/esm/biz-components/GraphicAttractionBlock/index.d.ts +1 -1
  408. package/dist/esm/biz-components/GraphicOverlay/GraphicOverlay.d.ts +2 -2
  409. package/dist/esm/biz-components/GraphicOverlay/GraphicOverlay.js +1 -1
  410. package/dist/esm/biz-components/GraphicOverlay/GraphicOverlay.js.map +3 -3
  411. package/dist/esm/biz-components/HeaderNavigation/MobileTextLinksMenu.d.ts +12 -0
  412. package/dist/esm/biz-components/HeaderNavigation/MobileTextLinksMenu.js +2 -0
  413. package/dist/esm/biz-components/HeaderNavigation/MobileTextLinksMenu.js.map +7 -0
  414. package/dist/esm/biz-components/HeaderNavigation/MulticolDropdown.js +1 -1
  415. package/dist/esm/biz-components/HeaderNavigation/MulticolDropdown.js.map +2 -2
  416. package/dist/esm/biz-components/HeaderNavigation/TextLinksDropdown.d.ts +10 -0
  417. package/dist/esm/biz-components/HeaderNavigation/TextLinksDropdown.js +2 -0
  418. package/dist/esm/biz-components/HeaderNavigation/TextLinksDropdown.js.map +7 -0
  419. package/dist/esm/biz-components/HeaderNavigation/index.d.ts +1 -1
  420. package/dist/esm/biz-components/HeaderNavigation/index.js +1 -1
  421. package/dist/esm/biz-components/HeaderNavigation/index.js.map +3 -3
  422. package/dist/esm/biz-components/HeaderNavigation/types.d.ts +11 -1
  423. package/dist/esm/biz-components/HeaderNavigation/types.js +1 -1
  424. package/dist/esm/biz-components/HeaderNavigation/types.js.map +2 -2
  425. package/dist/esm/biz-components/HeaderNavigation/withCategory.d.ts +1 -0
  426. package/dist/esm/biz-components/HeaderNavigation/withCategory.js +1 -1
  427. package/dist/esm/biz-components/HeaderNavigation/withCategory.js.map +3 -3
  428. package/dist/esm/biz-components/HeroBanner/HeroBanner.d.ts +1 -1
  429. package/dist/esm/biz-components/HeroBanner/HeroBanner.js +1 -1
  430. package/dist/esm/biz-components/HeroBanner/HeroBanner.js.map +3 -3
  431. package/dist/esm/biz-components/HeroBanner/HeroBannerCarousel.js +1 -1
  432. package/dist/esm/biz-components/HeroBanner/HeroBannerCarousel.js.map +3 -3
  433. package/dist/esm/biz-components/ImageOverlayShelf/index.d.ts +1 -1
  434. package/dist/esm/biz-components/ImageTextFeature/ImageTextFeature.d.ts +1 -1
  435. package/dist/esm/biz-components/ImageTextOverlay/index.d.ts +1 -1
  436. package/dist/esm/biz-components/ImageTextOverlay/index.js +2 -2
  437. package/dist/esm/biz-components/ImageTextOverlay/index.js.map +3 -3
  438. package/dist/esm/biz-components/ImageWithText/ImageWithText.d.ts +1 -1
  439. package/dist/esm/biz-components/ImageWithText/ImageWithText.js +1 -1
  440. package/dist/esm/biz-components/ImageWithText/ImageWithText.js.map +3 -3
  441. package/dist/esm/biz-components/Ksp/index.d.ts +1 -1
  442. package/dist/esm/biz-components/Ksp/index.js +1 -1
  443. package/dist/esm/biz-components/Ksp/index.js.map +3 -3
  444. package/dist/esm/biz-components/Listing/BizProductProvider.d.ts +3 -1
  445. package/dist/esm/biz-components/Listing/BizProductProvider.js +1 -1
  446. package/dist/esm/biz-components/Listing/BizProductProvider.js.map +3 -3
  447. package/dist/esm/biz-components/Listing/components/CartActionButtons/index.d.ts +9 -1
  448. package/dist/esm/biz-components/Listing/components/CartActionButtons/index.js +1 -1
  449. package/dist/esm/biz-components/Listing/components/CartActionButtons/index.js.map +3 -3
  450. package/dist/esm/biz-components/Listing/components/PaidShipping/index.d.ts +1 -1
  451. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts +1 -1
  452. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.d.ts +1 -1
  453. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.d.ts +1 -1
  454. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.d.ts +1 -1
  455. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.d.ts +1 -1
  456. package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.d.ts +1 -1
  457. package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/index.d.ts +1 -1
  458. package/dist/esm/biz-components/Listing/components/ProductCard/ProductPaidShipping/index.d.ts +1 -1
  459. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.d.ts +1 -1
  460. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.js +1 -1
  461. package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.js.map +3 -3
  462. package/dist/esm/biz-components/Listing/components/PurchaseBar/ProductActions/index.js +1 -1
  463. package/dist/esm/biz-components/Listing/components/PurchaseBar/ProductActions/index.js.map +3 -3
  464. package/dist/esm/biz-components/Listing/components/PurchaseBar/index.d.ts +1 -1
  465. package/dist/esm/biz-components/LotteryShared/ErrorModal.d.ts +4 -0
  466. package/dist/esm/biz-components/LotteryShared/ErrorModal.js.map +2 -2
  467. package/dist/esm/biz-components/LotteryShared/MyRewardsModal.d.ts +13 -13
  468. package/dist/esm/biz-components/LotteryShared/MyRewardsModal.js +1 -1
  469. package/dist/esm/biz-components/LotteryShared/MyRewardsModal.js.map +3 -3
  470. package/dist/esm/biz-components/LotteryShared/types.d.ts +9 -0
  471. package/dist/esm/biz-components/LotteryShared/types.js.map +2 -2
  472. package/dist/esm/biz-components/Marquee/Marquee.d.ts +1 -1
  473. package/dist/esm/biz-components/MarqueeReview/index.d.ts +1 -1
  474. package/dist/esm/biz-components/Media/index.js +1 -1
  475. package/dist/esm/biz-components/Media/index.js.map +3 -3
  476. package/dist/esm/biz-components/MediaEndorsement/index.d.ts +1 -1
  477. package/dist/esm/biz-components/MediaEndorsement/index.js +2 -2
  478. package/dist/esm/biz-components/MediaEndorsement/index.js.map +3 -3
  479. package/dist/esm/biz-components/MediaPlayerBase/index.d.ts +1 -1
  480. package/dist/esm/biz-components/MediaPlayerBase/index.js +1 -1
  481. package/dist/esm/biz-components/MediaPlayerBase/index.js.map +3 -3
  482. package/dist/esm/biz-components/MediaPlayerMulti/index.d.ts +1 -1
  483. package/dist/esm/biz-components/MediaPlayerMulti/index.js +1 -1
  484. package/dist/esm/biz-components/MediaPlayerMulti/index.js.map +3 -3
  485. package/dist/esm/biz-components/MediaPlayerSticky/index.d.ts +1 -1
  486. package/dist/esm/biz-components/MediaPlayerSticky/index.js +1 -1
  487. package/dist/esm/biz-components/MediaPlayerSticky/index.js.map +3 -3
  488. package/dist/esm/biz-components/MediaSceneSwitcher/MediaSceneSwitcher.d.ts +1 -1
  489. package/dist/esm/biz-components/MediaSceneSwitcher/MediaSceneSwitcher.js +2 -2
  490. package/dist/esm/biz-components/MediaSceneSwitcher/MediaSceneSwitcher.js.map +3 -3
  491. package/dist/esm/biz-components/MediaSceneSwitcherV2/index.d.ts +1 -1
  492. package/dist/esm/biz-components/MediaSceneSwitcherV2/index.js +1 -1
  493. package/dist/esm/biz-components/MediaSceneSwitcherV2/index.js.map +3 -3
  494. package/dist/esm/biz-components/MediaShelf/index.d.ts +1 -1
  495. package/dist/esm/biz-components/MediaTextOverlay/MediaTextOverlay.d.ts +1 -1
  496. package/dist/esm/biz-components/MediaTextOverlay/MediaTextOverlay.js +1 -1
  497. package/dist/esm/biz-components/MediaTextOverlay/MediaTextOverlay.js.map +3 -3
  498. package/dist/esm/biz-components/MemberEquity/index.d.ts +1 -1
  499. package/dist/esm/biz-components/MemberEquity/index.js +2 -2
  500. package/dist/esm/biz-components/MemberEquity/index.js.map +3 -3
  501. package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.d.ts +2 -2
  502. package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js +1 -1
  503. package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.js.map +3 -3
  504. package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlockCarousel.js +1 -1
  505. package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlockCarousel.js.map +2 -2
  506. package/dist/esm/biz-components/NavigationSearch/index.d.ts +1 -1
  507. package/dist/esm/biz-components/NavigationSearch/index.js +2 -2
  508. package/dist/esm/biz-components/NavigationSearch/index.js.map +3 -3
  509. package/dist/esm/biz-components/NotifyMeDialog/NotifyMeDialog.d.ts +7 -0
  510. package/dist/esm/biz-components/NotifyMeDialog/NotifyMeDialog.js +2 -0
  511. package/dist/esm/biz-components/NotifyMeDialog/NotifyMeDialog.js.map +7 -0
  512. package/dist/esm/biz-components/NotifyMeDialog/index.d.ts +2 -0
  513. package/dist/esm/biz-components/NotifyMeDialog/index.js +2 -0
  514. package/dist/esm/biz-components/NotifyMeDialog/index.js.map +7 -0
  515. package/dist/esm/biz-components/NotifyMeDialog/types.d.ts +111 -0
  516. package/dist/esm/biz-components/NotifyMeDialog/types.js +1 -0
  517. package/dist/esm/biz-components/NotifyMeDialog/types.js.map +7 -0
  518. package/dist/esm/biz-components/ProductCompare/index.d.ts +1 -1
  519. package/dist/esm/biz-components/ProductCompare/index.js +1 -1
  520. package/dist/esm/biz-components/ProductCompare/index.js.map +2 -2
  521. package/dist/esm/biz-components/ProductHero/ProductHero.d.ts +1 -1
  522. package/dist/esm/biz-components/ProductHero/ProductHero.js +1 -1
  523. package/dist/esm/biz-components/ProductHero/ProductHero.js.map +3 -3
  524. package/dist/esm/biz-components/ProductLottery/types.d.ts +62 -5
  525. package/dist/esm/biz-components/ProductLottery/types.js.map +2 -2
  526. package/dist/esm/biz-components/ProductNav/ProductNav.d.ts +1 -1
  527. package/dist/esm/biz-components/ProductNav/ProductNav.js +1 -1
  528. package/dist/esm/biz-components/ProductNav/ProductNav.js.map +3 -3
  529. package/dist/esm/biz-components/PromotionalBar/index.d.ts +1 -1
  530. package/dist/esm/biz-components/PromotionalBar/index.js +1 -1
  531. package/dist/esm/biz-components/PromotionalBar/index.js.map +3 -3
  532. package/dist/esm/biz-components/SceneShelfV2/index.d.ts +1 -1
  533. package/dist/esm/biz-components/SceneShelfV3/index.d.ts +1 -1
  534. package/dist/esm/biz-components/SearchPage/index.js +1 -1
  535. package/dist/esm/biz-components/SearchPage/index.js.map +3 -3
  536. package/dist/esm/biz-components/SecondaryBanner/index.d.ts +1 -1
  537. package/dist/esm/biz-components/SecondaryBanner/index.js +1 -1
  538. package/dist/esm/biz-components/SecondaryBanner/index.js.map +2 -2
  539. package/dist/esm/biz-components/SelectStore/index.d.ts +1 -1
  540. package/dist/esm/biz-components/ShelfDisplay/index.d.ts +1 -1
  541. package/dist/esm/biz-components/ShelfDisplay/shelfDisplayItem.js +1 -1
  542. package/dist/esm/biz-components/ShelfDisplay/shelfDisplayItem.js.map +3 -3
  543. package/dist/esm/biz-components/Slogan/index.d.ts +1 -1
  544. package/dist/esm/biz-components/Spacer/index.d.ts +1 -1
  545. package/dist/esm/biz-components/Specs/index.d.ts +1 -1
  546. package/dist/esm/biz-components/Specs/index.js +1 -1
  547. package/dist/esm/biz-components/Specs/index.js.map +3 -3
  548. package/dist/esm/biz-components/SpecsComparison/SpecsComparison.d.ts +1 -1
  549. package/dist/esm/biz-components/Subscribe/index.js +1 -1
  550. package/dist/esm/biz-components/Subscribe/index.js.map +2 -2
  551. package/dist/esm/biz-components/SwiperBox/index.js +1 -1
  552. package/dist/esm/biz-components/SwiperBox/index.js.map +3 -3
  553. package/dist/esm/biz-components/TabWithImage/TabWithImage.d.ts +1 -1
  554. package/dist/esm/biz-components/Tabs/Tabs.d.ts +1 -1
  555. package/dist/esm/biz-components/TabsGroup/index.d.ts +1 -1
  556. package/dist/esm/biz-components/TabsWithMedia/TabsWithMedia.d.ts +1 -1
  557. package/dist/esm/biz-components/TabsWithMedia/TabsWithMedia.js +1 -1
  558. package/dist/esm/biz-components/TabsWithMedia/TabsWithMedia.js.map +3 -3
  559. package/dist/esm/biz-components/ThreeDCarousel/ThreeDCarousel.d.ts +1 -1
  560. package/dist/esm/biz-components/ThreeDCarousel/ThreeDCarousel.js +1 -1
  561. package/dist/esm/biz-components/ThreeDCarousel/ThreeDCarousel.js.map +3 -3
  562. package/dist/esm/biz-components/Title/index.d.ts +1 -1
  563. package/dist/esm/biz-components/Title/index.js +1 -1
  564. package/dist/esm/biz-components/Title/index.js.map +3 -3
  565. package/dist/esm/biz-components/VideoFeature/VideoFeature.d.ts +1 -1
  566. package/dist/esm/biz-components/VideoModal/index.d.ts +1 -0
  567. package/dist/esm/biz-components/VideoModal/index.js +1 -1
  568. package/dist/esm/biz-components/VideoModal/index.js.map +3 -3
  569. package/dist/esm/biz-components/WheelLottery/index.js +1 -1
  570. package/dist/esm/biz-components/WheelLottery/index.js.map +2 -2
  571. package/dist/esm/biz-components/WhyChoose/WhyChoose.d.ts +1 -1
  572. package/dist/esm/biz-components/index.d.ts +8 -0
  573. package/dist/esm/biz-components/index.js +1 -1
  574. package/dist/esm/biz-components/index.js.map +3 -3
  575. package/dist/esm/components/Countdown.js +1 -1
  576. package/dist/esm/components/Countdown.js.map +3 -3
  577. package/dist/esm/components/alert.d.ts +1 -0
  578. package/dist/esm/components/alert.js +1 -1
  579. package/dist/esm/components/alert.js.map +2 -2
  580. package/dist/esm/components/breadcrumb.d.ts +12 -0
  581. package/dist/esm/components/breadcrumb.js +2 -0
  582. package/dist/esm/components/breadcrumb.js.map +7 -0
  583. package/dist/esm/components/checkbox.js +1 -1
  584. package/dist/esm/components/checkbox.js.map +2 -2
  585. package/dist/esm/components/dialog.js +1 -1
  586. package/dist/esm/components/dialog.js.map +3 -3
  587. package/dist/esm/components/index.d.ts +5 -0
  588. package/dist/esm/components/index.js +1 -1
  589. package/dist/esm/components/index.js.map +3 -3
  590. package/dist/esm/components/input-number.d.ts +22 -0
  591. package/dist/esm/components/input-number.js +1 -1
  592. package/dist/esm/components/input-number.js.map +3 -3
  593. package/dist/esm/components/link.js +1 -1
  594. package/dist/esm/components/link.js.map +2 -2
  595. package/dist/esm/components/otp-input.d.ts +18 -0
  596. package/dist/esm/components/otp-input.js +2 -0
  597. package/dist/esm/components/otp-input.js.map +7 -0
  598. package/dist/esm/components/toast.d.ts +25 -0
  599. package/dist/esm/components/toast.js +2 -0
  600. package/dist/esm/components/toast.js.map +7 -0
  601. package/dist/esm/helpers/index.d.ts +2 -2
  602. package/dist/esm/helpers/index.js +1 -1
  603. package/dist/esm/helpers/index.js.map +3 -3
  604. package/dist/esm/helpers/isLexicalEmpty.d.ts +5 -0
  605. package/dist/esm/helpers/isLexicalEmpty.js +1 -1
  606. package/dist/esm/helpers/isLexicalEmpty.js.map +3 -3
  607. package/dist/esm/helpers/priceFormatting.d.ts +5 -0
  608. package/dist/esm/helpers/priceFormatting.js +1 -1
  609. package/dist/esm/helpers/priceFormatting.js.map +3 -3
  610. package/dist/esm/helpers/utils.d.ts +7 -1
  611. package/dist/esm/helpers/utils.js +1 -1
  612. package/dist/esm/helpers/utils.js.map +3 -3
  613. package/dist/esm/hooks/useIsomorphicMediaQuery.d.ts +14 -0
  614. package/dist/esm/hooks/useIsomorphicMediaQuery.js +2 -0
  615. package/dist/esm/hooks/useIsomorphicMediaQuery.js.map +7 -0
  616. package/dist/esm/hooks/useProductListTrack.d.ts +43 -0
  617. package/dist/esm/hooks/useProductListTrack.js +2 -0
  618. package/dist/esm/hooks/useProductListTrack.js.map +7 -0
  619. package/dist/esm/index.d.ts +10 -0
  620. package/dist/esm/index.js +1 -1
  621. package/dist/esm/index.js.map +3 -3
  622. package/package.json +1 -1
  623. package/style.css +208 -10
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/biz-components/MediaPlayerBase/index.tsx"],
4
- "sourcesContent": ["'use client'\nimport { useState, useRef, useMemo, useEffect, forwardRef, useImperativeHandle } from 'react'\nimport { debounce } from 'lodash'\nimport { cn } from '../../helpers/utils.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport Button from '../../components/button.js'\nimport { Heading, Text } from '../../components/index.js'\nimport { VideoModal } from '../VideoModal/index.js'\nimport { convertLexicalToHTML } from '@payloadcms/richtext-lexical/html'\nimport type { MediaPlayerBaseProps } from './types.js'\n// import { Right } from './right.js'\nimport { useInView } from 'react-intersection-observer'\nimport type { HTMLConvertersFunction } from '@payloadcms/richtext-lexical/html'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport ScrollLoadVideo from '../../helpers/ScrollLoadVideo.js'\nimport { gsap } from 'gsap'\nimport { SplitText } from 'gsap/dist/SplitText'\nimport { ScrollTrigger } from 'gsap/dist/ScrollTrigger'\n\nconst componentName = 'media_player_base'\nconst componentType = 'video'\n\n// \u6CE8\u518C gsap \u63D2\u4EF6\ngsap.registerPlugin(ScrollTrigger, SplitText)\n\nconst htmlConverters: HTMLConvertersFunction = ({ defaultConverters }) => ({\n ...defaultConverters,\n text: args => {\n const { node } = args\n // \u68C0\u67E5\u662F\u5426\u6709\u81EA\u5B9A\u4E49 color\n if (node.$ && node.$.color) {\n return `<span class=\"lexical-${node.$.color}\">${node.text}</span>`\n }\n return node.text\n },\n})\n\nconst MediaPlayerBase = forwardRef<HTMLDivElement, MediaPlayerBaseProps>(\n (\n {\n className = '',\n id,\n onBtnClick,\n data: {\n title,\n videoTitle,\n btnText,\n youtubeId,\n video,\n mobileVideo,\n theme,\n img,\n shape,\n titleAnimation = 'fade-in',\n variant,\n headline,\n paragraphs,\n metrics,\n ...dataRest\n },\n ...rest\n },\n ref\n ) => {\n const { sticky } = dataRest\n const [isPlaying, setIsPlaying] = useState(false)\n const [btb, setbtb] = useState(0)\n const [titleHeight, setTitleHeight] = useState(0)\n const [videoHeightProgress, setVideoHeightProgress] = useState(0)\n const [visible, setVisible] = useState<boolean>(false)\n\n const videoRef = useRef<HTMLVideoElement>(null)\n const bgRef = useRef<HTMLImageElement>(null)\n const titleRef = useRef<HTMLDivElement>(null)\n const titleFadeInRef = useRef<HTMLDivElement>(null)\n const trackRef = useRef<HTMLDivElement>(null)\n const splitTextInstance = useRef<SplitText | null>(null)\n const btnFadeInRef = useRef<HTMLButtonElement>(null)\n const scrollTriggerRef = useRef<ScrollTrigger | null>(null)\n const heightTriggerRef = useRef<ScrollTrigger | null>(null)\n const { ref: inViewRef, inView } = useInView()\n\n useImperativeHandle(ref, () => titleRef.current as HTMLDivElement)\n\n const title_html =\n typeof title === 'string' ? title : title && convertLexicalToHTML({ data: title, converters: htmlConverters })\n const videoTitle_html =\n typeof videoTitle === 'string'\n ? videoTitle\n : videoTitle && convertLexicalToHTML({ data: videoTitle, converters: htmlConverters })\n\n useEffect(() => {\n if (inView) {\n videoRef.current?.play()\n setIsPlaying(true)\n } else {\n videoRef.current?.pause()\n setIsPlaying(false)\n }\n }, [inView])\n\n const debouncedHandleResize = debounce(() => {\n if (titleRef.current) {\n const rect = titleRef.current.getBoundingClientRect()\n const screenHeight = window.innerHeight\n const scrollTop = window.scrollY || window.pageYOffset\n const elementBottomToPageTop = rect.bottom + scrollTop\n const pageHeight = document.documentElement.scrollHeight\n const distanceToPageBottom = pageHeight - elementBottomToPageTop\n setbtb(distanceToPageBottom > screenHeight ? screenHeight : distanceToPageBottom)\n }\n if (titleRef.current) {\n const titleHeight = titleRef.current.clientHeight\n const screenHeight = window.innerHeight\n setTitleHeight(titleHeight + screenHeight)\n }\n }, 600)\n\n useEffect(() => {\n debouncedHandleResize()\n window.addEventListener('resize', debouncedHandleResize)\n return () => {\n window.removeEventListener('resize', debouncedHandleResize)\n }\n }, [])\n\n useEffect(() => {\n function gsapResize() {\n if (!titleFadeInRef.current || titleAnimation !== 'fade-in') return\n const height = titleFadeInRef.current?.clientHeight || 80\n splitTextInstance.current = new SplitText(titleFadeInRef.current, {\n type: 'words',\n wordsClass: 'word',\n })\n const words = splitTextInstance.current.words\n gsap.set(words, { opacity: 0 })\n if (btnFadeInRef.current) gsap.set(btnFadeInRef.current, { opacity: 0 })\n scrollTriggerRef.current = ScrollTrigger.create({\n trigger: titleRef.current,\n start: 'top center-=10%',\n end: `top+=${height * 1.5 + 80}px center-=10%`,\n scrub: true,\n onUpdate: (self: any) => {\n const progress = self.progress\n const total = words.length\n const interval = 1 / total\n const overlap = 0.5\n words.forEach((word: any, i: number) => {\n const start = (i / total) * (1 - overlap)\n const width = interval * (1 + overlap)\n let opacity = (progress - start) / width\n opacity = Math.max(0, Math.min(opacity, 1))\n gsap.set(word, { opacity })\n })\n gsap.set(bgRef.current, { opacity: progress })\n if (btnFadeInRef.current) {\n gsap.set(btnFadeInRef.current, { opacity: progress >= 0.6 ? 1 : 0 })\n }\n },\n })\n }\n\n function gsapVideoHeightResize() {\n heightTriggerRef.current = ScrollTrigger.create({\n trigger: titleRef.current,\n start: 'bottom bottom',\n end: `bottom top`,\n // markers: true,\n scrub: true,\n onUpdate: (self: any) => {\n const progress = self.progress\n setVideoHeightProgress(progress)\n },\n })\n }\n\n if (inView) {\n gsapResize()\n gsapVideoHeightResize()\n }\n\n return () => {\n splitTextInstance.current && splitTextInstance.current.revert()\n // ScrollTrigger.getAll().forEach((t: { kill: () => any }) => t.kill())\n scrollTriggerRef.current && scrollTriggerRef.current.kill()\n heightTriggerRef.current && heightTriggerRef.current.kill()\n }\n }, [titleAnimation, inView])\n\n useExposure(trackRef, {\n componentType,\n componentName,\n componentTitle: title_html,\n })\n\n const zIndexVideo = useMemo(() => {\n if (inView && videoHeightProgress > 0 && videoHeightProgress < 0.9) return 3\n if (inView) return 2\n return 1\n }, [videoHeightProgress, inView])\n\n if (variant === 'text-layout') {\n return (\n <div\n {...rest}\n ref={titleRef}\n className={cn(\n 'relative flex w-full items-center overflow-hidden',\n 'aspect-w-[390] aspect-h-[660] tablet:aspect-w-[768] tablet:aspect-h-[660]',\n 'laptop:aspect-w-[1024] laptop:aspect-h-[520] desktop:aspect-w-[1440] desktop:aspect-h-[700]',\n 'lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930]',\n {\n 'aiui-dark': theme === 'dark',\n 'rounded-box': shape === 'rounded',\n },\n className\n )}\n >\n <div ref={inViewRef} className=\"pointer-events-none absolute inset-0\" />\n\n {/* Video Background */}\n <div className=\"absolute inset-0 z-0\">\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={img?.url || ''}\n src={video?.url!}\n className=\"tablet:block hidden size-full\"\n videoClassName=\"size-full object-cover\"\n muted\n loop\n playsInline\n autoplay\n webkit-playsinline\n x5-playsinline\n />\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={img?.url || ''}\n src={mobileVideo?.url || video?.url!}\n className=\"tablet:hidden block size-full\"\n videoClassName=\"size-full object-cover\"\n muted\n loop\n playsInline\n autoplay\n webkit-playsinline\n x5-playsinline\n />\n <div className=\"absolute inset-0 bg-black/30\" />\n </div>\n\n {/* Content */}\n {/* Content \u2014 Fix#1/#9: laptop:flex-row, reduced spacing */}\n <div\n className={cn(\n 'relative z-10 mx-auto flex w-full max-w-[1920px] flex-col',\n 'gap-6 px-4 py-10',\n 'tablet:gap-8 tablet:px-8',\n 'laptop:flex-row laptop:gap-12 laptop:px-16',\n 'desktop:gap-16 desktop:px-20',\n 'lg-desktop:px-24'\n )}\n >\n {/* 1. Headline */}\n {/* 1. Headline \u2014 Fix#1(w-1/2) + Fix#5(Heading size=5) */}\n <div className=\"laptop:w-1/2 w-full shrink-0\">\n {headline && (\n <Heading as=\"h2\" size={5} className=\"text-info-primary\">\n {headline}\n </Heading>\n )}\n </div>\n\n {/* Right column for paragraphs and metrics */}\n {/* Right column \u2014 Fix#1(w-1/2) + Fix#4(justify-start) + Fix#10(gap) */}\n <div\n className={cn(\n 'laptop:w-1/2 flex w-full flex-col justify-start',\n 'tablet:gap-8 laptop:gap-10 desktop:gap-12 gap-6'\n )}\n >\n {/* 2. Paragraphs */}\n {paragraphs && paragraphs.length > 0 && (\n <div className=\"tablet:gap-4 flex flex-col gap-3\">\n {paragraphs.map((p, i) => (\n <Text key={i} as=\"p\" size={3} className=\"text-info-primary lg-desktop:text-[18px] opacity-90\">\n {typeof p === 'string' ? p : p.text}\n </Text>\n ))}\n </div>\n )}\n\n {/* 3. Metrics */}\n {metrics && metrics.length > 0 && (\n <div className={cn('tablet:grid-cols-3 grid grid-cols-2', 'tablet:gap-6 desktop:gap-8 gap-4')}>\n {metrics.map((m, i) => (\n <div key={i} className=\"flex flex-col gap-1\">\n {/* Fix#7: Heading size=4 equivalent classes on span */}\n <span className=\"text-info-primary desktop:text-[40px] lg-desktop:text-[48px] text-balance text-[32px] font-bold leading-[100%] tracking-[-0.04em]\">\n {m.value}\n </span>\n {/* Fix#8: Text size=2 \u2192 14px, removed uppercase/tracking-wider */}\n <Text as=\"span\" size={2} className=\"text-info-primary opacity-80\">\n {m.label}\n </Text>\n </div>\n ))}\n </div>\n )}\n </div>\n </div>\n </div>\n )\n }\n\n const aspect =\n 'lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930] desktop:aspect-w-[1024] desktop:aspect-h-[520] laptop:aspect-w-[1024] laptop:aspect-h-[520] tablet:aspect-w-[768] tablet:aspect-h-[660] aspect-w-[390] aspect-h-[660]'\n return (\n <>\n {sticky && (\n <div\n {...rest}\n ref={titleRef}\n className={cn(\n 'pointer-events-none relative z-10',\n aspect,\n {\n 'aiui-dark': theme === 'dark',\n 'rounded-box': shape === 'rounded',\n },\n className\n )}\n >\n <div ref={inViewRef}>\n {!titleAnimation && (\n <div className=\"media-content absolute left-1/2 top-1/2 z-20 w-full -translate-x-1/2 -translate-y-1/2 px-4 text-center\">\n {title_html && !isPlaying && (\n <div\n className=\"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl\"\n dangerouslySetInnerHTML={{ __html: title_html }}\n />\n )}\n {videoTitle_html && isPlaying && (\n <div\n className=\"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl\"\n dangerouslySetInnerHTML={{ __html: videoTitle_html }}\n />\n )}\n {btnText && (\n <Button\n variant=\"link\"\n className={cn('member-equity-button-secondary text-info-primary')}\n onClick={() => {\n setVisible(true)\n // if (isPlaying) {\n // if (videoRef.current) {\n // videoRef.current.pause()\n // }\n // setIsPlaying(false)\n // } else {\n // if (videoRef.current) {\n // videoRef.current.play()\n // }\n // setIsPlaying(true)\n // }\n onBtnClick && onBtnClick?.()\n }}\n >\n {btnText}\n {/* <Right /> */}\n </Button>\n )}\n </div>\n )}\n </div>\n </div>\n )}\n <div\n {...(!sticky ? rest : {})}\n style={\n sticky\n ? {\n marginBottom: `-${btb}px`,\n marginTop: `-${titleHeight}px`,\n zIndex: zIndexVideo,\n }\n : { zIndex: 5 }\n }\n className={cn('relative', className)}\n >\n <div className=\"sticky top-0 \">\n <div\n id={id}\n className={cn('relative overflow-hidden', sticky ? 'h-screen w-full' : aspect, {\n 'aiui-dark': theme === 'dark',\n 'rounded-box': shape === 'rounded',\n })}\n >\n {titleAnimation === 'fade-in' && (\n <div\n className={cn(\n 'absolute z-30 flex w-full flex-col items-center justify-center gap-4 px-4 text-center',\n sticky ? 'left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2' : 'left-0 top-0'\n )}\n >\n {title_html && (\n <div\n ref={titleFadeInRef}\n className=\"media-player-base-title lg-desktop:text-[64px] text-info-primary text-[40px] font-bold leading-none lg:text-5xl\"\n dangerouslySetInnerHTML={{ __html: title_html }}\n />\n )}\n {btnText && (\n <Button\n ref={btnFadeInRef}\n variant=\"link\"\n className={cn('media-player-base-button member-equity-button-secondary text-info-primary')}\n onClick={() => {\n setVisible(true)\n onBtnClick && onBtnClick?.()\n }}\n >\n {btnText}\n </Button>\n )}\n </div>\n )}\n <div\n className=\"media-cover left-0 top-0 h-screen w-screen overflow-hidden\"\n style={{ height: `${102 - videoHeightProgress * 100}vh` }}\n >\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={img?.url || ''}\n src={video?.url!}\n className=\"tablet:block hidden size-full\"\n videoClassName=\"object-cover\"\n muted\n loop\n playsInline\n autoplay\n webkit-playsinline\n x5-playsinline\n />\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={img?.url || ''}\n src={mobileVideo?.url || video?.url!}\n className=\"tablet:hidden block size-full\"\n videoClassName=\"object-cover\"\n muted\n loop\n playsInline\n autoplay\n webkit-playsinline\n x5-playsinline\n />\n <div\n ref={bgRef}\n className=\"absolute left-0 top-0 z-10 size-full opacity-0\"\n style={{\n background: 'rgba(0, 0, 0, 0.2)',\n }}\n />\n </div>\n </div>\n </div>\n {sticky && (\n <div\n className={cn(sticky && 'pointer-events-none relative box-content block', aspect)}\n style={sticky ? { height: `${btb}px` } : {}}\n ref={trackRef}\n />\n )}\n </div>\n {visible && youtubeId && (\n <VideoModal visible={visible} youTubeId={youtubeId} onCloseModal={() => setVisible(false)} />\n )}\n </>\n )\n }\n)\n\nMediaPlayerBase.displayName = 'MediaPlayerBase'\n\nexport default withLayout(MediaPlayerBase)\n"],
5
- "mappings": "aA0NU,OAoGJ,YAAAA,GApGI,OAAAC,EAGA,QAAAC,MAHA,oBAzNV,OAAS,YAAAC,EAAU,UAAAC,EAAQ,WAAAC,GAAS,aAAAC,EAAW,cAAAC,GAAY,uBAAAC,OAA2B,QACtF,OAAS,YAAAC,OAAgB,SACzB,OAAS,MAAAC,MAAU,yBACnB,OAAS,cAAAC,OAAkB,yBAC3B,OAAOC,OAAY,6BACnB,OAAS,WAAAC,GAAS,QAAAC,OAAY,4BAC9B,OAAS,cAAAC,OAAkB,yBAC3B,OAAS,wBAAAC,OAA4B,oCAGrC,OAAS,aAAAC,OAAiB,8BAE1B,OAAS,eAAAC,OAAmB,6BAC5B,OAAOC,MAA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,IAAKY,EACP,GAEJ,EACCN,GAAWvB,GACVnC,EAACc,GAAA,CAAW,QAAS4C,EAAS,UAAWvB,EAAW,aAAc,IAAMwB,EAAW,EAAK,EAAG,GAE/F,CAEJ,CACF,EAEA/B,GAAgB,YAAc,kBAE9B,IAAOqE,GAAQvF,GAAWkB,EAAe",
6
- "names": ["Fragment", "jsx", "jsxs", "useState", "useRef", "useMemo", "useEffect", "forwardRef", "useImperativeHandle", "debounce", "cn", "withLayout", "Button", "Heading", "Text", "VideoModal", "convertLexicalToHTML", "useInView", "useExposure", "ScrollLoadVideo", "gsap", "SplitText", "ScrollTrigger", "componentName", "componentType", "htmlConverters", "defaultConverters", "args", "node", "MediaPlayerBase", "className", "id", "onBtnClick", "title", "videoTitle", "btnText", "youtubeId", "video", "mobileVideo", "theme", "img", "shape", "titleAnimation", "variant", "headline", "paragraphs", "metrics", "dataRest", "rest", "ref", "sticky", "isPlaying", "setIsPlaying", "btb", "setbtb", "titleHeight", "setTitleHeight", "videoHeightProgress", "setVideoHeightProgress", "visible", "setVisible", "videoRef", "bgRef", "titleRef", "titleFadeInRef", "trackRef", "splitTextInstance", "btnFadeInRef", "scrollTriggerRef", "heightTriggerRef", "inViewRef", "inView", "title_html", "videoTitle_html", "debouncedHandleResize", "rect", "screenHeight", "scrollTop", "elementBottomToPageTop", "distanceToPageBottom", "gsapResize", "height", "words", "self", "progress", "total", "interval", "overlap", "word", "i", "start", "width", "opacity", "gsapVideoHeightResize", "zIndexVideo", "p", "m", "aspect", "MediaPlayerBase_default"]
4
+ "sourcesContent": ["'use client'\nimport { useState, useRef, useMemo, useEffect, forwardRef, useImperativeHandle } from 'react'\nimport { debounce } from 'lodash'\nimport { cn } from '../../helpers/utils.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport Button from '../../components/button.js'\nimport { Heading, Text } from '../../components/index.js'\nimport { VideoModal } from '../VideoModal/index.js'\nimport { convertLexicalToHTML } from '@payloadcms/richtext-lexical/html'\nimport type { MediaPlayerBaseProps } from './types.js'\n// import { Right } from './right.js'\nimport { useInView } from 'react-intersection-observer'\nimport type { HTMLConvertersFunction } from '@payloadcms/richtext-lexical/html'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport ScrollLoadVideo from '../../helpers/ScrollLoadVideo.js'\nimport { gsap } from 'gsap'\nimport { SplitText } from 'gsap/dist/SplitText'\nimport { ScrollTrigger } from 'gsap/dist/ScrollTrigger'\n\nconst componentName = 'media_player_base'\nconst componentType = 'video'\n\n// \u6CE8\u518C gsap \u63D2\u4EF6\ngsap.registerPlugin(ScrollTrigger, SplitText)\n\nconst htmlConverters: HTMLConvertersFunction = ({ defaultConverters }) => ({\n ...defaultConverters,\n text: args => {\n const { node } = args\n // \u68C0\u67E5\u662F\u5426\u6709\u81EA\u5B9A\u4E49 color\n if (node.$ && node.$.color) {\n return `<span class=\"lexical-${node.$.color}\">${node.text}</span>`\n }\n return node.text\n },\n})\n\nconst MediaPlayerBase = forwardRef<HTMLDivElement, MediaPlayerBaseProps>(\n (\n {\n className = '',\n id,\n onBtnClick,\n data: {\n title,\n videoTitle,\n btnText,\n youtubeId,\n video,\n mobileVideo,\n theme,\n img,\n shape,\n variant,\n headline,\n paragraphs,\n metrics,\n ...dataRest\n },\n ...rest\n },\n ref\n ) => {\n const { sticky } = dataRest\n const [isPlaying, setIsPlaying] = useState(false)\n const [btb, setbtb] = useState(0)\n const [titleHeight, setTitleHeight] = useState(0)\n const [videoHeightProgress, setVideoHeightProgress] = useState(0)\n const [visible, setVisible] = useState<boolean>(false)\n\n const videoRef = useRef<HTMLVideoElement>(null)\n const bgRef = useRef<HTMLImageElement>(null)\n const titleRef = useRef<HTMLDivElement>(null)\n const titleFadeInRef = useRef<HTMLDivElement>(null)\n const trackRef = useRef<HTMLDivElement>(null)\n const splitTextInstance = useRef<SplitText | null>(null)\n const btnFadeInRef = useRef<HTMLButtonElement>(null)\n const scrollTriggerRef = useRef<ScrollTrigger | null>(null)\n const heightTriggerRef = useRef<ScrollTrigger | null>(null)\n const { ref: inViewRef, inView } = useInView()\n\n useImperativeHandle(ref, () => titleRef.current as HTMLDivElement)\n\n const title_html =\n typeof title === 'string' ? title : title && convertLexicalToHTML({ data: title, converters: htmlConverters })\n const videoTitle_html =\n typeof videoTitle === 'string'\n ? videoTitle\n : videoTitle && convertLexicalToHTML({ data: videoTitle, converters: htmlConverters })\n\n useEffect(() => {\n if (inView) {\n videoRef.current?.play()\n setIsPlaying(true)\n } else {\n videoRef.current?.pause()\n setIsPlaying(false)\n }\n }, [inView])\n\n const debouncedHandleResize = debounce(() => {\n if (titleRef.current) {\n const rect = titleRef.current.getBoundingClientRect()\n const screenHeight = window.innerHeight\n const scrollTop = window.scrollY || window.pageYOffset\n const elementBottomToPageTop = rect.bottom + scrollTop\n const pageHeight = document.documentElement.scrollHeight\n const distanceToPageBottom = pageHeight - elementBottomToPageTop\n setbtb(distanceToPageBottom > screenHeight ? screenHeight : distanceToPageBottom)\n }\n if (titleRef.current) {\n const titleHeight = titleRef.current.clientHeight\n const screenHeight = window.innerHeight\n setTitleHeight(titleHeight + screenHeight)\n }\n }, 600)\n\n useEffect(() => {\n debouncedHandleResize()\n window.addEventListener('resize', debouncedHandleResize)\n return () => {\n window.removeEventListener('resize', debouncedHandleResize)\n }\n }, [])\n\n useEffect(() => {\n function gsapResize() {\n if (!titleFadeInRef.current) return\n const height = titleFadeInRef.current?.clientHeight || 80\n splitTextInstance.current = new SplitText(titleFadeInRef.current, {\n type: 'words',\n wordsClass: 'word',\n })\n const words = splitTextInstance.current.words\n gsap.set(words, { opacity: 0 })\n if (btnFadeInRef.current) gsap.set(btnFadeInRef.current, { opacity: 0 })\n scrollTriggerRef.current = ScrollTrigger.create({\n trigger: titleRef.current,\n start: 'top center-=10%',\n end: `top+=${height * 1.5 + 80}px center-=10%`,\n scrub: true,\n onUpdate: (self: any) => {\n const progress = self.progress\n const total = words.length\n const interval = 1 / total\n const overlap = 0.5\n words.forEach((word: any, i: number) => {\n const start = (i / total) * (1 - overlap)\n const width = interval * (1 + overlap)\n let opacity = (progress - start) / width\n opacity = Math.max(0, Math.min(opacity, 1))\n gsap.set(word, { opacity })\n })\n gsap.set(bgRef.current, { opacity: progress })\n if (btnFadeInRef.current) {\n gsap.set(btnFadeInRef.current, { opacity: progress >= 0.6 ? 1 : 0 })\n }\n },\n })\n }\n\n function gsapVideoHeightResize() {\n heightTriggerRef.current = ScrollTrigger.create({\n trigger: titleRef.current,\n start: 'bottom bottom',\n end: `bottom top`,\n // markers: true,\n scrub: true,\n onUpdate: (self: any) => {\n const progress = self.progress\n setVideoHeightProgress(progress)\n },\n })\n }\n\n if (inView) {\n gsapResize()\n gsapVideoHeightResize()\n }\n\n return () => {\n splitTextInstance.current && splitTextInstance.current.revert()\n // ScrollTrigger.getAll().forEach((t: { kill: () => any }) => t.kill())\n scrollTriggerRef.current && scrollTriggerRef.current.kill()\n heightTriggerRef.current && heightTriggerRef.current.kill()\n }\n }, [inView])\n\n useExposure(trackRef, {\n componentType,\n componentName,\n componentTitle: title_html,\n })\n\n const zIndexVideo = useMemo(() => {\n if (inView && videoHeightProgress > 0 && videoHeightProgress < 0.9) return 3\n if (inView) return 2\n return 1\n }, [videoHeightProgress, inView])\n\n if (variant === 'text-layout') {\n return (\n <div\n {...rest}\n ref={titleRef}\n className={cn(\n 'relative flex w-full items-center overflow-hidden',\n 'aspect-w-[390] aspect-h-[660] tablet:aspect-w-[768] tablet:aspect-h-[660]',\n 'laptop:aspect-w-[1024] laptop:aspect-h-[520] desktop:aspect-w-[1440] desktop:aspect-h-[700]',\n 'lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930]',\n {\n 'aiui-dark': theme === 'dark',\n 'rounded-box': shape === 'rounded',\n },\n className\n )}\n >\n <div ref={inViewRef} className=\"pointer-events-none absolute inset-0\" />\n\n {/* Video Background */}\n <div className=\"absolute inset-0 z-0\">\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={img?.url || ''}\n src={video?.url!}\n className=\"tablet:block hidden size-full\"\n videoClassName=\"size-full object-cover\"\n muted\n loop\n playsInline\n autoplay\n webkit-playsinline\n x5-playsinline\n />\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={img?.url || ''}\n src={mobileVideo?.url || video?.url!}\n className=\"tablet:hidden block size-full\"\n videoClassName=\"size-full object-cover\"\n muted\n loop\n playsInline\n autoplay\n webkit-playsinline\n x5-playsinline\n />\n <div className=\"absolute inset-0 bg-black/30\" />\n </div>\n\n {/* Content */}\n {/* Content \u2014 Fix#1/#9: laptop:flex-row, reduced spacing */}\n <div\n className={cn(\n 'relative z-10 mx-auto flex w-full max-w-[1920px] flex-col',\n 'gap-6 px-4 py-10',\n 'tablet:gap-8 tablet:px-8',\n 'laptop:flex-row laptop:gap-12 laptop:px-16',\n 'desktop:gap-16 desktop:px-20',\n 'lg-desktop:px-24'\n )}\n >\n {/* 1. Headline */}\n {/* 1. Headline \u2014 Fix#1(w-1/2) + Fix#5(Heading size=5) */}\n <div className=\"laptop:w-1/2 w-full shrink-0\">\n {headline && (\n <Heading as=\"h2\" size={5} className=\"text-info-primary\">\n {headline}\n </Heading>\n )}\n </div>\n\n {/* Right column for paragraphs and metrics */}\n {/* Right column \u2014 Fix#1(w-1/2) + Fix#4(justify-start) + Fix#10(gap) */}\n <div\n className={cn(\n 'laptop:w-1/2 flex w-full flex-col justify-start',\n 'tablet:gap-8 laptop:gap-10 desktop:gap-12 gap-6'\n )}\n >\n {/* 2. Paragraphs */}\n {paragraphs && paragraphs.length > 0 && (\n <div className=\"tablet:gap-4 flex flex-col gap-3\">\n {paragraphs.map((p, i) => (\n <Text key={i} as=\"p\" size={3} className=\"text-info-primary lg-desktop:text-[18px] opacity-90\">\n {typeof p === 'string' ? p : p.text}\n </Text>\n ))}\n </div>\n )}\n\n {/* 3. Metrics */}\n {metrics && metrics.length > 0 && (\n <div className={cn('tablet:grid-cols-3 grid grid-cols-2', 'tablet:gap-6 desktop:gap-8 gap-4')}>\n {metrics.map((m, i) => (\n <div key={i} className=\"flex flex-col gap-1\">\n {/* Fix#7: Heading size=4 equivalent classes on span */}\n <span className=\"text-info-primary desktop:text-[40px] lg-desktop:text-[48px] text-balance text-[32px] font-bold leading-[100%] tracking-[-0.04em]\">\n {m.value}\n </span>\n {/* Fix#8: Text size=2 \u2192 14px, removed uppercase/tracking-wider */}\n <Text as=\"span\" size={2} className=\"text-info-primary opacity-80\">\n {m.label}\n </Text>\n </div>\n ))}\n </div>\n )}\n </div>\n </div>\n </div>\n )\n }\n\n const aspect_box =\n 'lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930] desktop:aspect-w-[1024] desktop:aspect-h-[520] laptop:aspect-w-[1024] laptop:aspect-h-[520] tablet:aspect-w-[768] tablet:aspect-h-[660] aspect-w-[390] aspect-h-[660]'\n const aspect_no_stickybox =\n 'lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930] desktop:aspect-w-[1024] desktop:aspect-h-[520] laptop:aspect-w-[1024] laptop:aspect-h-[520] tablet:aspect-w-[768] tablet:aspect-h-[660]'\n return (\n <>\n {sticky && (\n <div\n {...rest}\n ref={titleRef}\n className={cn(\n 'pointer-events-none relative z-10',\n aspect_box,\n {\n 'aiui-dark': theme === 'dark',\n 'rounded-box': shape === 'rounded',\n },\n className\n )}\n >\n <div ref={inViewRef}>\n <div className=\"media-content absolute left-1/2 top-1/2 z-20 w-full -translate-x-1/2 -translate-y-1/2 px-4 text-center\">\n {title_html && !isPlaying && (\n <div\n className=\"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl\"\n dangerouslySetInnerHTML={{ __html: title_html }}\n />\n )}\n {videoTitle_html && isPlaying && (\n <div\n className=\"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl\"\n dangerouslySetInnerHTML={{ __html: videoTitle_html }}\n />\n )}\n {btnText && (\n <Button\n variant=\"link\"\n className={cn('member-equity-button-secondary text-info-primary')}\n onClick={() => {\n setVisible(true)\n // if (isPlaying) {\n // if (videoRef.current) {\n // videoRef.current.pause()\n // }\n // setIsPlaying(false)\n // } else {\n // if (videoRef.current) {\n // videoRef.current.play()\n // }\n // setIsPlaying(true)\n // }\n onBtnClick && onBtnClick?.()\n }}\n >\n {btnText}\n {/* <Right /> */}\n </Button>\n )}\n </div>\n </div>\n </div>\n )}\n <div\n {...(!sticky ? rest : {})}\n style={\n sticky\n ? {\n marginBottom: `-${btb}px`,\n marginTop: `-${titleHeight}px`,\n zIndex: zIndexVideo,\n }\n : { zIndex: 5 }\n }\n className={cn('relative', className)}\n >\n <div className=\"sticky top-0 \">\n <div\n id={id}\n className={cn('relative overflow-hidden', sticky ? 'h-screen w-full' : aspect_no_stickybox, {\n 'aiui-dark': theme === 'dark',\n 'rounded-box': shape === 'rounded',\n })}\n >\n <div className=\"media-cover relative left-0 top-0 h-screen w-screen overflow-hidden\">\n {!sticky && (\n <div\n className={cn(\n 'absolute z-30 flex w-full flex-col items-center justify-center gap-4 px-4 text-center',\n 'left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2'\n )}\n >\n {title_html && !isPlaying && (\n <div\n className=\"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl\"\n dangerouslySetInnerHTML={{ __html: title_html }}\n />\n )}\n {videoTitle_html && isPlaying && (\n <div\n className=\"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl\"\n dangerouslySetInnerHTML={{ __html: videoTitle_html }}\n />\n )}\n {btnText && (\n <Button\n ref={btnFadeInRef}\n variant=\"link\"\n className={cn('media-player-base-button member-equity-button-secondary text-info-primary')}\n onClick={() => {\n setVisible(true)\n onBtnClick && onBtnClick?.()\n }}\n >\n {btnText}\n </Button>\n )}\n </div>\n )}\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={img?.url || ''}\n src={video?.url!}\n className=\"tablet:block hidden size-full\"\n videoClassName=\"object-cover\"\n muted\n loop\n playsInline\n autoplay\n webkit-playsinline\n x5-playsinline\n />\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={img?.url || ''}\n src={mobileVideo?.url || video?.url!}\n className=\"tablet:hidden block size-full\"\n videoClassName=\"object-cover\"\n muted\n loop\n playsInline\n autoplay\n webkit-playsinline\n x5-playsinline\n />\n <div\n ref={bgRef}\n className=\"absolute left-0 top-0 z-10 size-full opacity-0\"\n style={{\n background: 'rgba(0, 0, 0, 0.2)',\n }}\n />\n </div>\n </div>\n </div>\n {sticky && (\n <div\n className={cn(sticky && 'pointer-events-none relative box-content block', aspect_box)}\n style={sticky ? { height: `${btb}px` } : {}}\n ref={trackRef}\n />\n )}\n </div>\n {visible && youtubeId && (\n <VideoModal visible={visible} youTubeId={youtubeId} onCloseModal={() => setVisible(false)} />\n )}\n </>\n )\n }\n)\n\nMediaPlayerBase.displayName = 'MediaPlayerBase'\n\nexport default withLayout(MediaPlayerBase)\n"],
5
+ "mappings": "aAyNU,OAsGJ,YAAAA,GAtGI,OAAAC,EAGA,QAAAC,MAHA,oBAxNV,OAAS,YAAAC,EAAU,UAAAC,EAAQ,WAAAC,GAAS,aAAAC,EAAW,cAAAC,GAAY,uBAAAC,OAA2B,QACtF,OAAS,YAAAC,OAAgB,SACzB,OAAS,MAAAC,MAAU,yBACnB,OAAS,cAAAC,OAAkB,yBAC3B,OAAOC,OAAY,6BACnB,OAAS,WAAAC,GAAS,QAAAC,OAAY,4BAC9B,OAAS,cAAAC,OAAkB,yBAC3B,OAAS,wBAAAC,OAA4B,oCAGrC,OAAS,aAAAC,OAAiB,8BAE1B,OAAS,eAAAC,OAAmB,6BAC5B,OAAOC,MAAqB,mCAC5B,OAAS,QAAAC,MAAY,OACrB,OAAS,aAAAC,OAAiB,sBAC1B,OAAS,iBAAAC,MAAqB,0BAE9B,MAAMC,GAAgB,oBAChBC,GAAgB,QAGtBJ,EAAK,eAAeE,EAAeD,EAAS,EAE5C,MAAMI,GAAyC,CAAC,CAAE,kBAAAC,CAAkB,KAAO,CACzE,GAAGA,EACH,KAAMC,G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6D,GAAc,CAACrB,GACdjD,EAAC,OACC,UAAU,sGACV,wBAAyB,CAAE,OAAQsE,CAAW,EAChD,EAEDC,GAAmBtB,GAClBjD,EAAC,OACC,UAAU,sGACV,wBAAyB,CAAE,OAAQuE,CAAgB,EACrD,EAEDrC,GACClC,EAACW,GAAA,CACC,IAAKsD,EACL,QAAQ,OACR,UAAWxD,EAAG,2EAA2E,EACzF,QAAS,IAAM,CACbiD,EAAW,EAAI,EACf3B,GAAcA,IAAa,CAC7B,EAEC,SAAAG,EACH,GAEJ,EAEFlC,EAACkB,EAAA,CACC,SAAUyC,EACV,OAAQpB,GAAK,KAAO,GACpB,IAAKH,GAAO,IACZ,UAAU,gCACV,eAAe,eACf,MAAK,GACL,KAAI,GACJ,YAAW,GACX,SAAQ,GACR,qBAAkB,GAClB,iBAAc,GAChB,EACApC,EAACkB,EAAA,CACC,SAAUyC,EACV,OAAQpB,GAAK,KAAO,GACpB,IAAKF,GAAa,KAAOD,GAAO,IAChC,UAAU,gCACV,eAAe,eACf,MAAK,GACL,KAAI,GACJ,YAAW,GACX,SAAQ,GACR,qBAAkB,GAClB,iBAAc,GAChB,EACApC,EAAC,OACC,IAAK4D,EACL,UAAU,iDACV,MAAO,CACL,WAAY,oBACd,EACF,GACF,EACF,EACF,EACCZ,GACChD,EAAC,OACC,UAAWS,EAAGuC,GAAU,iDAAkD+C,CAAU,EACpF,MAAO/C,EAAS,CAAE,OAAQ,GAAGG,CAAG,IAAK,EAAI,CAAC,EAC1C,IAAKY,EACP,GAEJ,EACCN,GAAWtB,GACVnC,EAACc,GAAA,CAAW,QAAS2C,EAAS,UAAWtB,EAAW,aAAc,IAAMuB,EAAW,EAAK,EAAG,GAE/F,CAEJ,CACF,EAEA9B,GAAgB,YAAc,kBAE9B,IAAOoE,GAAQtF,GAAWkB,EAAe",
6
+ "names": ["Fragment", "jsx", "jsxs", "useState", "useRef", "useMemo", "useEffect", "forwardRef", "useImperativeHandle", "debounce", "cn", "withLayout", "Button", "Heading", "Text", "VideoModal", "convertLexicalToHTML", "useInView", "useExposure", "ScrollLoadVideo", "gsap", "SplitText", "ScrollTrigger", "componentName", "componentType", "htmlConverters", "defaultConverters", "args", "node", "MediaPlayerBase", "className", "id", "onBtnClick", "title", "videoTitle", "btnText", "youtubeId", "video", "mobileVideo", "theme", "img", "shape", "variant", "headline", "paragraphs", "metrics", "dataRest", "rest", "ref", "sticky", "isPlaying", "setIsPlaying", "btb", "setbtb", "titleHeight", "setTitleHeight", "videoHeightProgress", "setVideoHeightProgress", "visible", "setVisible", "videoRef", "bgRef", "titleRef", "titleFadeInRef", "trackRef", "splitTextInstance", "btnFadeInRef", "scrollTriggerRef", "heightTriggerRef", "inViewRef", "inView", "title_html", "videoTitle_html", "debouncedHandleResize", "rect", "screenHeight", "scrollTop", "elementBottomToPageTop", "distanceToPageBottom", "gsapResize", "height", "words", "self", "progress", "total", "interval", "overlap", "word", "i", "start", "width", "opacity", "gsapVideoHeightResize", "zIndexVideo", "p", "m", "aspect_box", "MediaPlayerBase_default"]
7
7
  }
@@ -1,5 +1,5 @@
1
1
  import type { MediaPlayerMultiProps } from './types.js';
2
- declare const _default: import("react").ForwardRefExoticComponent<Omit<MediaPlayerMultiProps & import("react").RefAttributes<HTMLDivElement>, "container" | keyof import("../../shared/Styles.js").StylesProps> & import("../../shared/Styles.js").StylesProps & import("../WheelLottery/index.js").ContainerProps & import("react").RefAttributes<unknown>> & {
2
+ declare const _default: import("react").ForwardRefExoticComponent<Omit<MediaPlayerMultiProps & import("react").RefAttributes<HTMLDivElement>, "container" | keyof import("../../shared/Styles.js").StylesProps> & import("../../shared/Styles.js").StylesProps & import("../index.js").ContainerProps & import("react").RefAttributes<unknown>> & {
3
3
  readonly $$typeof: symbol;
4
4
  };
5
5
  export default _default;
@@ -1,2 +1,2 @@
1
- "use client";import{jsx as l,jsxs as i}from"react/jsx-runtime";import{useState as r,forwardRef as C,useRef as h}from"react";import{cn as V,getLocalizedPath as B}from"../../helpers/utils.js";import{withLayout as $}from"../../shared/Styles.js";import{Picture as v,Link as z,Text as D}from"../../components/index.js";import E from"../Title/index.js";import H from"../SwiperBox/index.js";import{Container as R}from"../../components/container.js";import{VideoModal as S}from"../VideoModal/index.js";import{convertLexicalToHTML as U}from"@payloadcms/richtext-lexical/html";import{useExposure as _}from"../../hooks/useExposure.js";import{useAiuiContext as j}from"../AiuiProvider/index.js";import{trackUrlRef as q}from"../../shared/trackUrlRef.js";const a="video",p="media_player_multi",Y=({data:e,configuration:o})=>{const t=h(null);return _(t,{componentType:a,componentName:p,componentTitle:e?.title,position:o?.index+1,componentDescription:e?.description}),i("div",{ref:t,className:V("laptop:max-w-full w-full overflow-hidden","laptop:flex-row flex shrink-0 flex-col","lg-desktop:h-[480px] desktop:h-[384px] laptop:h-[360px] h-auto",o.shape==="round"?"rounded-2xl":""),children:[i("div",{className:"laptop:w-[49%] laptop:h-full tablet:h-[18.22vw] relative h-[35.9vw] w-full flex-none",children:[l(v,{source:e.img?.url,alt:e.img?.alt||"",className:"tablet:block hidden size-full",imgClassName:"w-full h-full object-cover tablet:hover:scale-110 transition-all duration-300"}),l(v,{source:e.mobileImg?.url||e.img?.url,alt:e.mobileImg?.alt||e.img?.alt||"",className:"tablet:hidden block size-full",imgClassName:"w-full h-full object-cover"}),l("div",{className:"laptop:bottom-6 laptop:right-6 absolute bottom-4 right-4",children:(e?.video?.url||e?.youtubeId)&&l("button",{onClick:()=>{o?.onVideoPlayBtnClick?.(o?.index||0,e)},className:"laptop:size-14 bg-opacity/20 flex size-8 items-center justify-center rounded-full bg-white bg-opacity-20 hover:bg-black/75",children:l("svg",{width:"12",height:"14",viewBox:"0 0 12 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:l("path",{d:"M12 7L0 14L0 0L12 7Z",fill:"white"})})})})]}),i("div",{className:"laptop:gap-[60px] lg-desktop:p-8 tablet:p-6 bg-container-secondary-1 flex min-h-[200px] flex-1 flex-col gap-4 overflow-hidden p-4",children:[i("div",{className:"flex flex-col",children:[l("h3",{className:"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary mb-2 text-[14px] font-bold leading-[1.2] tracking-[-0.02em]",children:e.title}),e.quote&&l(z,{asChild:!e?.href,href:q(B(e?.href||"",o?.locale||"us"),`${a}_${p}`),"data-headless-type-name":`${a}#${p}`,"data-headless-title-desc-button":`${e?.title}#${e?.description}`,children:l(D,{html:e.quote,weight:"bold",className:"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary text-sm"})})]}),l("p",{className:"lg-desktop:text-2xl lg-desktop:leading-[1.2] text-info-primary desktop:max-h-[186px] line-clamp-6 max-h-[144px] min-h-[100px] text-xl font-bold leading-[1.2] tracking-[-0.04em]",children:e.description})]})]})},b=C(({data:{items:e=[],shape:o="square",title:t,containerProps:g},className:n="",key:w,onVideoPlayBtnClick:y,...M},k)=>{const[m,d]=r(!1),[P,c]=r(""),[N,f]=r(""),{locale:L="us"}=j(),u=typeof t=="string"?t:t&&U({data:t}),T=h(null),x=e.length===2;return i("div",{...M,ref:T,className:n,children:[l("div",{className:"mediaplayermulti-box",children:l(R,{...g||{},className:"overflow-hidden",children:i("div",{className:n,ref:k,children:[t&&l(E,{className:"mediaplayermulti-title",data:{title:u||""}}),l(H,{className:"!overflow-visible",id:"MediaPlayerMultiSwiper"+w,data:{list:e,configuration:{shape:o,locale:L,onVideoPlayBtnClick:(I,s)=>{d(!0),s?.isYouTube?(f(s?.youtubeId||""),c("")):(c(s?.video?.url||""),f("")),y?.(I)},title:u}},Slide:Y,breakpoints:{0:{spaceBetween:12,freeMode:!1,slidesPerView:1},374:{spaceBetween:12,freeMode:!1,slidesPerView:1.2},768:{spaceBetween:16,freeMode:!1,slidesPerView:x?2:2.3},1024:{spaceBetween:16,freeMode:!1,slidesPerView:x?2:1.5},1440:{spaceBetween:16,freeMode:!1,slidesPerView:2}}})]})})}),m&&l(S,{visible:m,youTubeId:N,videoUrl:P,onCloseModal:()=>d(!1)})]})});b.displayName="MediaPlayerMulti";var te=$(b);export{te as default};
1
+ "use client";import{jsx as l,jsxs as i}from"react/jsx-runtime";import{useState as r,forwardRef as V,useRef as v}from"react";import{cn as B,getLocalizedPath as $}from"../../helpers/utils.js";import{withLayout as D}from"../../shared/Styles.js";import{Picture as b,Link as z,Text as H}from"../../components/index.js";import _ from"../Title/index.js";import j from"../SwiperBox/index.js";import{Container as E}from"../../components/container.js";import{VideoModal as R}from"../VideoModal/index.js";import{convertLexicalToHTML as S}from"@payloadcms/richtext-lexical/html";import{useExposure as U}from"../../hooks/useExposure.js";import{useAiuiContext as g}from"../AiuiProvider/index.js";import{trackUrlRef as q}from"../../shared/trackUrlRef.js";const n="video",p="media_player_multi",Y=({data:e,configuration:o})=>{const t=v(null),{trackingData:s}=g();return U(t,{componentType:n,componentName:p,componentTitle:e?.title,position:o?.index+1,componentDescription:e?.description}),i("div",{ref:t,className:B("laptop:max-w-full w-full overflow-hidden","laptop:flex-row flex shrink-0 flex-col","lg-desktop:h-[480px] desktop:h-[384px] laptop:h-[360px] h-auto",o.shape==="round"?"rounded-2xl":""),children:[i("div",{className:"laptop:w-[49%] laptop:h-full tablet:h-[18.22vw] relative h-[35.9vw] w-full flex-none",children:[l(b,{source:e.img?.url,alt:e.img?.alt||"",className:"tablet:block hidden size-full",imgClassName:"w-full h-full object-cover tablet:hover:scale-110 transition-all duration-300"}),l(b,{source:e.mobileImg?.url||e.img?.url,alt:e.mobileImg?.alt||e.img?.alt||"",className:"tablet:hidden block size-full",imgClassName:"w-full h-full object-cover"}),l("div",{className:"laptop:bottom-6 laptop:right-6 absolute bottom-4 right-4",children:(e?.video?.url||e?.youtubeId)&&l("button",{onClick:()=>{o?.onVideoPlayBtnClick?.(o?.index||0,e)},className:"laptop:size-14 bg-opacity/20 flex size-8 items-center justify-center rounded-full bg-white bg-opacity-20 hover:bg-black/75",children:l("svg",{width:"12",height:"14",viewBox:"0 0 12 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:l("path",{d:"M12 7L0 14L0 0L12 7Z",fill:"white"})})})})]}),i("div",{className:"laptop:gap-[60px] lg-desktop:p-8 tablet:p-6 bg-container-secondary-1 flex min-h-[200px] flex-1 flex-col gap-4 overflow-hidden p-4",children:[i("div",{className:"flex flex-col",children:[l("h3",{className:"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary mb-2 text-[14px] font-bold leading-[1.2] tracking-[-0.02em]",children:e.title}),e.quote&&l(z,{asChild:!e?.href,href:q($(e?.href||"",o?.locale||"us"),`${s?.contextHandle||""}_${n}_${p}`),"data-headless-type-name":`${n}#${p}`,"data-headless-title-desc-button":`${e?.title}#${e?.description}`,children:l(H,{html:e.quote,weight:"bold",className:"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary text-sm"})})]}),l("p",{className:"lg-desktop:text-2xl lg-desktop:leading-[1.2] text-info-primary desktop:max-h-[186px] line-clamp-6 max-h-[144px] min-h-[100px] text-xl font-bold leading-[1.2] tracking-[-0.04em]",children:e.description})]})]})},w=V(({data:{items:e=[],shape:o="square",title:t,containerProps:s},className:m="",key:y,onVideoPlayBtnClick:M,...k},P)=>{const[d,c]=r(!1),[N,f]=r(""),[L,u]=r(""),{locale:T="us",trackingData:A}=g(),x=typeof t=="string"?t:t&&S({data:t}),C=v(null),h=e.length===2;return i("div",{...k,ref:C,className:m,children:[l("div",{className:"mediaplayermulti-box",children:l(E,{...s||{},className:"overflow-hidden",children:i("div",{className:m,ref:P,children:[t&&l(_,{className:"mediaplayermulti-title",data:{title:x||""}}),l(j,{className:"!overflow-visible",id:"MediaPlayerMultiSwiper"+y,data:{list:e,configuration:{shape:o,locale:T,onVideoPlayBtnClick:(I,a)=>{c(!0),a?.isYouTube?(u(a?.youtubeId||""),f("")):(f(a?.video?.url||""),u("")),M?.(I)},title:x}},Slide:Y,breakpoints:{0:{spaceBetween:12,freeMode:!1,slidesPerView:1},374:{spaceBetween:12,freeMode:!1,slidesPerView:1.2},768:{spaceBetween:16,freeMode:!1,slidesPerView:h?2:2.3},1024:{spaceBetween:16,freeMode:!1,slidesPerView:h?2:1.5},1440:{spaceBetween:16,freeMode:!1,slidesPerView:2}}})]})})}),d&&l(R,{videoClassName:"object-contain",visible:d,youTubeId:L,videoUrl:N,onCloseModal:()=>c(!1)})]})});w.displayName="MediaPlayerMulti";var oe=D(w);export{oe as default};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/biz-components/MediaPlayerMulti/index.tsx"],
4
- "sourcesContent": ["'use client'\nimport { useState, forwardRef, useRef } from 'react'\nimport { cn, getLocalizedPath } from '../../helpers/utils.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport { Picture, Link, Text } from '../../components/index.js'\nimport Title from '../Title/index.js'\nimport SwiperBox from '../SwiperBox/index.js'\nimport { Container } from '../../components/container.js'\nimport { VideoModal } from '../VideoModal/index.js'\nimport { convertLexicalToHTML } from '@payloadcms/richtext-lexical/html'\nimport type { MediaPlayerMultiProps, MediaPlayerItemProps } from './types.js'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { useAiuiContext } from '../AiuiProvider/index.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\n\nconst componentType = 'video'\nconst componentName = 'media_player_multi'\n\nconst MediaPlayerItem = ({ data, configuration }: { data: MediaPlayerItemProps; configuration?: any }) => {\n const ref = useRef<HTMLDivElement>(null)\n\n useExposure(ref, {\n componentType,\n componentName,\n componentTitle: data?.title,\n position: configuration?.index + 1,\n componentDescription: data?.description,\n })\n\n return (\n <div\n ref={ref}\n className={cn(\n 'laptop:max-w-full w-full overflow-hidden',\n 'laptop:flex-row flex shrink-0 flex-col',\n 'lg-desktop:h-[480px] desktop:h-[384px] laptop:h-[360px] h-auto',\n configuration.shape === 'round' ? 'rounded-2xl' : ''\n )}\n >\n <div className=\"laptop:w-[49%] laptop:h-full tablet:h-[18.22vw] relative h-[35.9vw] w-full flex-none\">\n <Picture\n source={data.img?.url}\n alt={data.img?.alt || ''}\n className=\"tablet:block hidden size-full\"\n imgClassName=\"w-full h-full object-cover tablet:hover:scale-110 transition-all duration-300\"\n />\n <Picture\n source={data.mobileImg?.url || data.img?.url}\n alt={data.mobileImg?.alt || data.img?.alt || ''}\n className=\"tablet:hidden block size-full\"\n imgClassName=\"w-full h-full object-cover\"\n />\n <div className=\"laptop:bottom-6 laptop:right-6 absolute bottom-4 right-4\">\n {(data?.video?.url || data?.youtubeId) && (\n <button\n onClick={() => {\n configuration?.onVideoPlayBtnClick?.(configuration?.index || 0, data)\n }}\n className=\"laptop:size-14 bg-opacity/20 flex size-8 items-center justify-center rounded-full bg-white bg-opacity-20 hover:bg-black/75\"\n >\n <svg width=\"12\" height=\"14\" viewBox=\"0 0 12 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M12 7L0 14L0 0L12 7Z\" fill=\"white\" />\n </svg>\n </button>\n )}\n </div>\n </div>\n\n <div className=\"laptop:gap-[60px] lg-desktop:p-8 tablet:p-6 bg-container-secondary-1 flex min-h-[200px] flex-1 flex-col gap-4 overflow-hidden p-4\">\n <div className=\"flex flex-col\">\n <h3 className=\"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary mb-2 text-[14px] font-bold leading-[1.2] tracking-[-0.02em]\">\n {data.title}\n </h3>\n {data.quote && (\n <Link\n asChild={!data?.href}\n href={trackUrlRef(\n getLocalizedPath(data?.href || '', configuration?.locale || 'us'),\n `${componentType}_${componentName}`\n )}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${data?.title}#${data?.description}`}\n >\n <Text\n html={data.quote}\n weight=\"bold\"\n className=\"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary text-sm\"\n />\n </Link>\n )}\n </div>\n\n <p className=\"lg-desktop:text-2xl lg-desktop:leading-[1.2] text-info-primary desktop:max-h-[186px] line-clamp-6 max-h-[144px] min-h-[100px] text-xl font-bold leading-[1.2] tracking-[-0.04em]\">\n {data.description}\n </p>\n </div>\n </div>\n )\n}\n\nconst MediaPlayerMulti = forwardRef<HTMLDivElement, MediaPlayerMultiProps>(\n (\n {\n data: { items = [], shape = 'square', title, containerProps },\n className = '',\n key,\n onVideoPlayBtnClick,\n ...rest\n },\n ref\n ) => {\n const [visible, setVisible] = useState<boolean>(false)\n const [videoUrl, setVideoUrl] = useState<string>('')\n const [youTubeId, setYouTubeId] = useState<string>('')\n const { locale = 'us' } = useAiuiContext()\n const title_html = typeof title === 'string' ? title : title && convertLexicalToHTML({ data: title })\n const wrapperRef = useRef<HTMLDivElement>(null)\n\n // \u5982\u679C\u53EA\u6709\u4E24\u4E2Aitem, \u5219\u5E73\u5747\u5206\u914D\u7A7A\u95F4\n const itemsLength = items.length === 2\n\n return (\n <div {...rest} ref={wrapperRef} className={className}>\n <div className=\"mediaplayermulti-box\">\n <Container {...(containerProps || {})} className=\"overflow-hidden\">\n <div className={className} ref={ref}>\n {title && <Title className=\"mediaplayermulti-title\" data={{ title: title_html || '' }} />}\n <SwiperBox\n className=\"!overflow-visible\"\n id={'MediaPlayerMultiSwiper' + key}\n data={{\n list: items,\n configuration: {\n shape,\n locale,\n onVideoPlayBtnClick: (_: number, data: MediaPlayerItemProps) => {\n setVisible(true)\n if (data?.isYouTube) {\n setYouTubeId(data?.youtubeId || '')\n setVideoUrl('')\n } else {\n setVideoUrl(data?.video?.url || '')\n setYouTubeId('')\n }\n onVideoPlayBtnClick?.(_)\n },\n title: title_html,\n },\n }}\n Slide={MediaPlayerItem}\n breakpoints={{\n 0: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1,\n },\n 374: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1.2,\n },\n 768: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: itemsLength ? 2 : 2.3,\n },\n 1024: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: itemsLength ? 2 : 1.5,\n },\n 1440: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: 2,\n },\n }}\n />\n </div>\n </Container>\n </div>\n {visible && (\n <VideoModal\n visible={visible}\n youTubeId={youTubeId}\n videoUrl={videoUrl}\n onCloseModal={() => setVisible(false)}\n />\n )}\n </div>\n )\n }\n)\n\nMediaPlayerMulti.displayName = 'MediaPlayerMulti'\nexport default withLayout(MediaPlayerMulti)\n"],
5
- "mappings": "aAuCM,OACE,OAAAA,EADF,QAAAC,MAAA,oBAtCN,OAAS,YAAAC,EAAU,cAAAC,EAAY,UAAAC,MAAc,QAC7C,OAAS,MAAAC,EAAI,oBAAAC,MAAwB,yBACrC,OAAS,cAAAC,MAAkB,yBAC3B,OAAS,WAAAC,EAAS,QAAAC,EAAM,QAAAC,MAAY,4BACpC,OAAOC,MAAW,oBAClB,OAAOC,MAAe,wBACtB,OAAS,aAAAC,MAAiB,gCAC1B,OAAS,cAAAC,MAAkB,yBAC3B,OAAS,wBAAAC,MAA4B,oCAErC,OAAS,eAAAC,MAAmB,6BAC5B,OAAS,kBAAAC,MAAsB,2BAC/B,OAAS,eAAAC,MAAmB,8BAE5B,MAAMC,EAAgB,QAChBC,EAAgB,qBAEhBC,EAAkB,CAAC,CAAE,KAAAC,EAAM,cAAAC,CAAc,IAA2D,CACxG,MAAMC,EAAMpB,EAAuB,IAAI,EAEvC,OAAAY,EAAYQ,EAAK,CACf,cAAAL,EACA,cAAAC,EACA,eAAgBE,GAAM,MACtB,SAAUC,GAAe,MAAQ,EACjC,qBAAsBD,GAAM,WAC9B,CAAC,EAGCrB,EAAC,OACC,IAAKuB,EACL,UAAWnB,EACT,2CACA,yCACA,iEACAkB,EAAc,QAAU,QAAU,cAAgB,EACpD,EAEA,UAAAtB,EAAC,OAAI,UAAU,uFACb,UAAAD,EAACQ,EAAA,CACC,OAAQc,EAAK,KAAK,IAClB,IAAKA,EAAK,KAAK,KAAO,GACtB,UAAU,gCACV,aAAa,gFACf,EACAtB,EAACQ,EAAA,CACC,OAAQc,EAAK,WAAW,KAAOA,EAAK,KAAK,IACzC,IAAKA,EAAK,WAAW,KAAOA,E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AAc,IAAMD,EAAW,EAAK,EACtC,GAEJ,CAEJ,CACF,EAEAV,EAAiB,YAAc,mBAC/B,IAAOoB,GAAQtC,EAAWkB,CAAgB",
6
- "names": ["jsx", "jsxs", "useState", "forwardRef", "useRef", "cn", "getLocalizedPath", "withLayout", "Picture", "Link", "Text", "Title", "SwiperBox", "Container", "VideoModal", "convertLexicalToHTML", "useExposure", "useAiuiContext", "trackUrlRef", "componentType", "componentName", "MediaPlayerItem", "data", "configuration", "ref", "MediaPlayerMulti", "items", "shape", "title", "containerProps", "className", "key", "onVideoPlayBtnClick", "rest", "visible", "setVisible", "videoUrl", "setVideoUrl", "youTubeId", "setYouTubeId", "locale", "title_html", "wrapperRef", "itemsLength", "_", "MediaPlayerMulti_default"]
4
+ "sourcesContent": ["'use client'\nimport { useState, forwardRef, useRef } from 'react'\nimport { cn, getLocalizedPath } from '../../helpers/utils.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport { Picture, Link, Text } from '../../components/index.js'\nimport Title from '../Title/index.js'\nimport SwiperBox from '../SwiperBox/index.js'\nimport { Container } from '../../components/container.js'\nimport { VideoModal } from '../VideoModal/index.js'\nimport { convertLexicalToHTML } from '@payloadcms/richtext-lexical/html'\nimport type { MediaPlayerMultiProps, MediaPlayerItemProps } from './types.js'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { useAiuiContext } from '../AiuiProvider/index.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\n\nconst componentType = 'video'\nconst componentName = 'media_player_multi'\n\nconst MediaPlayerItem = ({ data, configuration }: { data: MediaPlayerItemProps; configuration?: any }) => {\n const ref = useRef<HTMLDivElement>(null)\n const { trackingData } = useAiuiContext()\n\n useExposure(ref, {\n componentType,\n componentName,\n componentTitle: data?.title,\n position: configuration?.index + 1,\n componentDescription: data?.description,\n })\n\n return (\n <div\n ref={ref}\n className={cn(\n 'laptop:max-w-full w-full overflow-hidden',\n 'laptop:flex-row flex shrink-0 flex-col',\n 'lg-desktop:h-[480px] desktop:h-[384px] laptop:h-[360px] h-auto',\n configuration.shape === 'round' ? 'rounded-2xl' : ''\n )}\n >\n <div className=\"laptop:w-[49%] laptop:h-full tablet:h-[18.22vw] relative h-[35.9vw] w-full flex-none\">\n <Picture\n source={data.img?.url}\n alt={data.img?.alt || ''}\n className=\"tablet:block hidden size-full\"\n imgClassName=\"w-full h-full object-cover tablet:hover:scale-110 transition-all duration-300\"\n />\n <Picture\n source={data.mobileImg?.url || data.img?.url}\n alt={data.mobileImg?.alt || data.img?.alt || ''}\n className=\"tablet:hidden block size-full\"\n imgClassName=\"w-full h-full object-cover\"\n />\n <div className=\"laptop:bottom-6 laptop:right-6 absolute bottom-4 right-4\">\n {(data?.video?.url || data?.youtubeId) && (\n <button\n onClick={() => {\n configuration?.onVideoPlayBtnClick?.(configuration?.index || 0, data)\n }}\n className=\"laptop:size-14 bg-opacity/20 flex size-8 items-center justify-center rounded-full bg-white bg-opacity-20 hover:bg-black/75\"\n >\n <svg width=\"12\" height=\"14\" viewBox=\"0 0 12 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M12 7L0 14L0 0L12 7Z\" fill=\"white\" />\n </svg>\n </button>\n )}\n </div>\n </div>\n\n <div className=\"laptop:gap-[60px] lg-desktop:p-8 tablet:p-6 bg-container-secondary-1 flex min-h-[200px] flex-1 flex-col gap-4 overflow-hidden p-4\">\n <div className=\"flex flex-col\">\n <h3 className=\"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary mb-2 text-[14px] font-bold leading-[1.2] tracking-[-0.02em]\">\n {data.title}\n </h3>\n {data.quote && (\n <Link\n asChild={!data?.href}\n href={trackUrlRef(\n getLocalizedPath(data?.href || '', configuration?.locale || 'us'),\n `${trackingData?.contextHandle || ''}_${componentType}_${componentName}`\n )}\n data-headless-type-name={`${componentType}#${componentName}`}\n data-headless-title-desc-button={`${data?.title}#${data?.description}`}\n >\n <Text\n html={data.quote}\n weight=\"bold\"\n className=\"lg-desktop:text-[18px] desktop:text-[16px] text-info-primary text-sm\"\n />\n </Link>\n )}\n </div>\n\n <p className=\"lg-desktop:text-2xl lg-desktop:leading-[1.2] text-info-primary desktop:max-h-[186px] line-clamp-6 max-h-[144px] min-h-[100px] text-xl font-bold leading-[1.2] tracking-[-0.04em]\">\n {data.description}\n </p>\n </div>\n </div>\n )\n}\n\nconst MediaPlayerMulti = forwardRef<HTMLDivElement, MediaPlayerMultiProps>(\n (\n {\n data: { items = [], shape = 'square', title, containerProps },\n className = '',\n key,\n onVideoPlayBtnClick,\n ...rest\n },\n ref\n ) => {\n const [visible, setVisible] = useState<boolean>(false)\n const [videoUrl, setVideoUrl] = useState<string>('')\n const [youTubeId, setYouTubeId] = useState<string>('')\n const { locale = 'us', trackingData } = useAiuiContext()\n const title_html = typeof title === 'string' ? title : title && convertLexicalToHTML({ data: title })\n const wrapperRef = useRef<HTMLDivElement>(null)\n\n // \u5982\u679C\u53EA\u6709\u4E24\u4E2Aitem, \u5219\u5E73\u5747\u5206\u914D\u7A7A\u95F4\n const itemsLength = items.length === 2\n\n return (\n <div {...rest} ref={wrapperRef} className={className}>\n <div className=\"mediaplayermulti-box\">\n <Container {...(containerProps || {})} className=\"overflow-hidden\">\n <div className={className} ref={ref}>\n {title && <Title className=\"mediaplayermulti-title\" data={{ title: title_html || '' }} />}\n <SwiperBox\n className=\"!overflow-visible\"\n id={'MediaPlayerMultiSwiper' + key}\n data={{\n list: items,\n configuration: {\n shape,\n locale,\n onVideoPlayBtnClick: (_: number, data: MediaPlayerItemProps) => {\n setVisible(true)\n if (data?.isYouTube) {\n setYouTubeId(data?.youtubeId || '')\n setVideoUrl('')\n } else {\n setVideoUrl(data?.video?.url || '')\n setYouTubeId('')\n }\n onVideoPlayBtnClick?.(_)\n },\n title: title_html,\n },\n }}\n Slide={MediaPlayerItem}\n breakpoints={{\n 0: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1,\n },\n 374: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1.2,\n },\n 768: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: itemsLength ? 2 : 2.3,\n },\n 1024: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: itemsLength ? 2 : 1.5,\n },\n 1440: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: 2,\n },\n }}\n />\n </div>\n </Container>\n </div>\n {visible && (\n <VideoModal\n videoClassName=\"object-contain\"\n visible={visible}\n youTubeId={youTubeId}\n videoUrl={videoUrl}\n onCloseModal={() => setVisible(false)}\n />\n )}\n </div>\n )\n }\n)\n\nMediaPlayerMulti.displayName = 'MediaPlayerMulti'\nexport default withLayout(MediaPlayerMulti)\n"],
5
+ "mappings": "aAwCM,OACE,OAAAA,EADF,QAAAC,MAAA,oBAvCN,OAAS,YAAAC,EAAU,cAAAC,EAAY,UAAAC,MAAc,QAC7C,OAAS,MAAAC,EAAI,oBAAAC,MAAwB,yBACrC,OAAS,cAAAC,MAAkB,yBAC3B,OAAS,WAAAC,EAAS,QAAAC,EAAM,QAAAC,MAAY,4BACpC,OAAOC,MAAW,oBAClB,OAAOC,MAAe,wBACtB,OAAS,aAAAC,MAAiB,gCAC1B,OAAS,cAAAC,MAAkB,yBAC3B,OAAS,wBAAAC,MAA4B,oCAErC,OAAS,eAAAC,MAAmB,6BAC5B,OAAS,kBAAAC,MAAsB,2BAC/B,OAAS,eAAAC,MAAmB,8BAE5B,MAAMC,EAAgB,QAChBC,EAAgB,qBAEhBC,EAAkB,CAAC,CAAE,KAAAC,EAAM,cAAAC,CAAc,IAA2D,CACxG,MAAMC,EAAMpB,EAAuB,IAAI,EACjC,CAAE,aAAAqB,CAAa,EAAIR,EAAe,EAExC,OAAAD,EAAYQ,EAAK,CACf,cAAAL,EACA,cAAAC,EACA,eAAgBE,GAAM,MACtB,SAAUC,GAAe,MAAQ,EACjC,qBAAsBD,GAAM,WAC9B,CAAC,EAGCrB,EAAC,OACC,IAAKuB,EACL,UAAWnB,EACT,2CACA,yCACA,iEACAk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,EACA,IAAK,CACH,aAAc,GACd,SAAU,GACV,cAAe,GACjB,EACA,IAAK,CACH,aAAc,GACd,SAAU,GACV,cAAeuB,EAAc,EAAI,GACnC,EACA,KAAM,CACJ,aAAc,GACd,SAAU,GACV,cAAeA,EAAc,EAAI,GACnC,EACA,KAAM,CACJ,aAAc,GACd,SAAU,GACV,cAAe,CACjB,CACF,EACF,GACF,EACF,EACF,EACCT,GACCnC,EAACc,EAAA,CACC,eAAe,iBACf,QAASqB,EACT,UAAWI,EACX,SAAUF,EACV,aAAc,IAAMD,EAAW,EAAK,EACtC,GAEJ,CAEJ,CACF,EAEAV,EAAiB,YAAc,mBAC/B,IAAOoB,GAAQvC,EAAWmB,CAAgB",
6
+ "names": ["jsx", "jsxs", "useState", "forwardRef", "useRef", "cn", "getLocalizedPath", "withLayout", "Picture", "Link", "Text", "Title", "SwiperBox", "Container", "VideoModal", "convertLexicalToHTML", "useExposure", "useAiuiContext", "trackUrlRef", "componentType", "componentName", "MediaPlayerItem", "data", "configuration", "ref", "trackingData", "MediaPlayerMulti", "items", "shape", "title", "containerProps", "className", "key", "onVideoPlayBtnClick", "rest", "visible", "setVisible", "videoUrl", "setVideoUrl", "youTubeId", "setYouTubeId", "locale", "title_html", "wrapperRef", "itemsLength", "_", "MediaPlayerMulti_default"]
7
7
  }
@@ -2,7 +2,7 @@ import React from 'react';
2
2
  import type { MediaPlayerBaseProps } from './types.js';
3
3
  declare const _default: React.ForwardRefExoticComponent<Omit<MediaPlayerBaseProps & React.RefAttributes<{
4
4
  mediaPlayerStickyRef: HTMLDivElement;
5
- }>, "container" | keyof import("../../shared/Styles.js").StylesProps> & import("../../shared/Styles.js").StylesProps & import("../WheelLottery/index.js").ContainerProps & React.RefAttributes<unknown>> & {
5
+ }>, "container" | keyof import("../../shared/Styles.js").StylesProps> & import("../../shared/Styles.js").StylesProps & import("../index.js").ContainerProps & React.RefAttributes<unknown>> & {
6
6
  readonly $$typeof: symbol;
7
7
  };
8
8
  export default _default;
@@ -1,2 +1,2 @@
1
- "use client";import{Fragment as N,jsx as e,jsxs as u}from"react/jsx-runtime";import Z,{useState as p,useRef as f,useEffect as y,forwardRef as D}from"react";import{debounce as ee}from"es-toolkit";import{useInView as te}from"react-intersection-observer";import{cn as b}from"../../helpers/utils.js";import{withLayout as re}from"../../shared/Styles.js";import ae from"../Slogan/index.js";import{YouTubePlayer as se}from"../VideoModal/YouTubePlayer.js";import{Grid as le,GridItem as k}from"../../components/grid.js";import{Container as oe}from"../../components/container.js";import ie from"../BrandEquity/index.js";import ne from"../MemberEquity/index.js";import ce from"../Spacer/index.js";import de from"gsap";import{convertLexicalToHTML as z}from"@payloadcms/richtext-lexical/html";import{useMediaQuery as C}from"react-responsive";import pe from"../../helpers/ScrollLoadVideo.js";const E=({defaultConverters:l})=>({...l,text:o=>{const{node:t}=o;return t.$&&t.$.color?`<span class="lexical-${t.$.color}">${t.text}</span>`:t.text}}),x=({children:l,spaceY:o,className:t})=>{const a=C({query:"(max-width: 768px)"});return e(oe,{spaceY:o,className:b("!bg-transparent",t),children:u(le,{children:[!a&&e(k,{span:1}),e(k,{span:a?12:10,children:l}),!a&&e(k,{span:1})]})})},P=Z.forwardRef(({children:l,id:o,components:t},a)=>{const i=f(null);return u("div",{ref:i,className:"relative z-10",children:[e(N,{children:l}),e(N,{children:t?.map((r,s)=>{switch(r.blockType){case"ipc-brand-equity":return e("div",{className:"relative z-20 bg-transparent",children:e(x,{spaceY:"none",children:e(ie,{data:r,style:r?.style})})},`${r.blockType}-${s}`);case"ipc-member-equity":return e("div",{className:"relative z-20 w-full bg-transparent",children:e(x,{spaceY:"none",children:e(ne,{data:r,className:"w-full",style:r?.style})})},`${r.blockType}-${s}`);case"ipc-spacer":return e(ce,{data:r,style:r?.style,className:"!bg-transparent"},`${r.blockType}-${s}`);default:return null}})})]})});P.displayName="SubBox";const L=D(({className:l="",wrapperClassName:o="",id:t,data:{title:a,videoTitle:i,mobVideo:r,mobImg:s,img:m,isYouTube:B,youtubePcId:M,youtubeMobileId:Y,video:v,theme:R,shape:q,components:F},...I},ue)=>{const H=f(null),g=f(null),{ref:j,inView:c}=te(),[me,G]=p(0),[T,V]=p(!1),[Q,O]=p(!1),W=f(null),_=typeof a=="string"?a:a&&z({data:a,converters:E});typeof i=="string"||i&&z({data:i,converters:E});const[A,J]=p(0),[n,K]=p(!1),S=C({query:"(max-width: 768px)"});return y(()=>{K(S)},[S]),y(()=>{c&&!T&&(H.current?.play(),V(!0))},[c,T]),y(()=>{const d=ee(()=>{if(g.current){const w=g.current.getBoundingClientRect(),h=n?window.screen.height:window.innerHeight,U=window.scrollY||window.pageYOffset,X=w.bottom+U,$=document.documentElement.scrollHeight-X;J($>h?h:$),G(h)}},2e3);return d(),window.addEventListener("resize",d),()=>{window.removeEventListener("resize",d)}},[]),y(()=>{function d(){const w=n?window.screen.height:window.innerHeight;de.timeline({scrollTrigger:{trigger:`#${t}`,start:"top top",end:`top+=${w*1.8}px bottom`,scrub:.5}}).from(`#${t} .media-content`,{top:"50%",transform:"translate(-50%, -50%)"}).to(`.${t} .sticky-cover`,{backdropFilter:"blur(8px)",duration:.4}).to(`#${t} .media-content`,{top:"100%",transform:"translate(-50%, -100%)",duration:1},"<")}c&&d()},[c]),u(N,{children:[e("div",{id:t,...I,className:b("relative z-20 h-screen w-full",l,{"aiui-dark":R==="dark","rounded-box":q==="rounded"}),ref:W,children:e("div",{ref:j,className:"media-content translate-z-0 absolute left-1/2 top-1/2 z-10 w-full -translate-x-1/2 -translate-y-1/2 antialiased",style:{willChange:"transform",contain:"paint"},children:e(x,{spaceY:"tablet:my-[32px] my-[24px] space-y-4",children:e(ae,{className:"sticky-title antialiased",data:{title:_||"",theme:R,tag:"h2"}})})})}),u("div",{ref:g,style:{marginBottom:`-${A}px`,zIndex:c?2:1},className:b(t,"relative mt-[-200vh]",o),children:[e("div",{className:"sticky top-0 ",children:u("div",{className:b("media-cover","relative h-screen w-full"),children:[B?e(se,{youTubeId:n&&Y||M}):v?.url&&e(pe,{videoRef:H,poster:n&&s?.url?s?.url:m?.url,src:n&&r?.url?r?.url:v?.url,className:"lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930] lg:aspect-w-[1440] lg:aspect-h-[700] desktop:aspect-w-[1024] desktop:aspect-h-[520] tablet:aspect-w-[768] tablet:aspect-h-[660] aspect-w-[390] aspect-h-[660]",videoClassName:" object-cover object-[82%]",muted:!0,loop:!1,playsInline:!0,autoplay:!1,onEnded:()=>{O(!0)}}),m?.url&&(!v?.url||Q)&&e("img",{src:n&&s?.url?s?.url:m?.url,alt:m?.alt,className:"z-1 absolute left-0 top-0 size-full object-cover object-[82%]",loading:"lazy"}),e("div",{className:"sticky-cover absolute left-0 top-0 z-10 size-full",style:{backdropFilter:"blur(0px)",WebkitBackdropFilter:"blur(0px)",willChange:"backdrop-filter"}})]})}),e("div",{className:"relative h-screen w-full"}),e(P,{components:F}),e("div",{className:"relative h-screen w-full"})]})]})});L.displayName="MediaPlayerSticky";var Ce=re(L);export{Ce as default};
1
+ "use client";import{Fragment as x,jsx as e,jsxs as p}from"react/jsx-runtime";import X,{useState as u,useRef as f,useEffect as y,forwardRef as Z}from"react";import{debounce as D}from"es-toolkit";import{useInView as ee}from"react-intersection-observer";import{cn as b}from"../../helpers/utils.js";import{withLayout as te}from"../../shared/Styles.js";import re from"../Slogan/index.js";import{YouTubePlayer as ae}from"../VideoModal/YouTubePlayer.js";import{Grid as se,GridItem as h}from"../../components/grid.js";import{Container as oe}from"../../components/container.js";import le from"../BrandEquity/index.js";import ie from"../MemberEquity/index.js";import ne from"../Spacer/index.js";import ce from"gsap";import{convertLexicalToHTML as S}from"@payloadcms/richtext-lexical/html";import{useIsomorphicMediaQuery as C}from"../../hooks/useIsomorphicMediaQuery.js";import de from"../../helpers/ScrollLoadVideo.js";const E=({defaultConverters:o})=>({...o,text:l=>{const{node:t}=l;return t.$&&t.$.color?`<span class="lexical-${t.$.color}">${t.text}</span>`:t.text}}),k=({children:o,spaceY:l,className:t})=>{const a=C({query:"(max-width: 768px)"});return e(oe,{spaceY:l,className:b("!bg-transparent",t),children:p(se,{children:[!a&&e(h,{span:1}),e(h,{span:a?12:10,children:o}),!a&&e(h,{span:1})]})})},P=X.forwardRef(({children:o,id:l,components:t},a)=>{const i=f(null);return p("div",{ref:i,className:"relative z-10",children:[e(x,{children:o}),e(x,{children:t?.map((r,s)=>{switch(r.blockType){case"ipc-brand-equity":return e("div",{className:"relative z-20 bg-transparent",children:e(k,{spaceY:"none",children:e(le,{data:r,style:r?.style})})},`${r.blockType}-${s}`);case"ipc-member-equity":return e("div",{className:"relative z-20 w-full bg-transparent",children:e(k,{spaceY:"none",children:e(ie,{data:r,className:"w-full",style:r?.style})})},`${r.blockType}-${s}`);case"ipc-spacer":return e(ne,{data:r,style:r?.style,className:"!bg-transparent"},`${r.blockType}-${s}`);default:return null}})})]})});P.displayName="SubBox";const L=Z(({className:o="",wrapperClassName:l="",id:t,data:{title:a,videoTitle:i,mobVideo:r,mobImg:s,img:m,isYouTube:B,youtubePcId:N,youtubeMobileId:Y,video:v,theme:M,shape:q,components:I},...F},pe)=>{const R=f(null),w=f(null),{ref:j,inView:c}=ee(),[T,G]=u(!1),[V,Q]=u(!1),O=f(null),W=typeof a=="string"?a:a&&S({data:a,converters:E});typeof i=="string"||i&&S({data:i,converters:E});const[_,A]=u(0),[n,J]=u(!1),$=C({query:"(max-width: 768px)"});return y(()=>{J($)},[$]),y(()=>{c&&!T&&(R.current?.play(),G(!0))},[c,T]),y(()=>{const d=D(()=>{if(w.current){const g=w.current.getBoundingClientRect(),z=n?window.screen.height:window.innerHeight,K=window.scrollY||window.pageYOffset,U=g.bottom+K,H=document.documentElement.scrollHeight-U;A(H>z?z:H)}},2e3);return d(),window.addEventListener("resize",d),()=>{window.removeEventListener("resize",d)}},[]),y(()=>{function d(){const g=n?window.screen.height:window.innerHeight;ce.timeline({scrollTrigger:{trigger:`#${t}`,start:"top top",end:`top+=${g*1.8}px bottom`,scrub:.5}}).from(`#${t} .media-content`,{top:"50%",transform:"translate(-50%, -50%)"}).to(`.${t} .sticky-cover`,{backdropFilter:"blur(8px)",duration:.4}).to(`#${t} .media-content`,{top:"100%",transform:"translate(-50%, -100%)",duration:1},"<")}c&&d()},[c]),p(x,{children:[e("div",{id:t,...F,className:b("relative z-20 h-screen w-full",o,{"aiui-dark":M==="dark","rounded-box":q==="rounded"}),ref:O,children:e("div",{ref:j,className:"media-content translate-z-0 absolute left-1/2 top-1/2 z-10 w-full -translate-x-1/2 -translate-y-1/2 antialiased",style:{willChange:"transform",contain:"paint"},children:e(k,{spaceY:"tablet:my-[32px] my-[24px] space-y-4",children:e(re,{className:"sticky-title antialiased",data:{title:W||"",theme:M,tag:"h2"}})})})}),p("div",{ref:w,style:{marginBottom:`-${_}px`,zIndex:c?2:1},className:b(t,"relative mt-[-200vh]",l),children:[e("div",{className:"sticky top-0 ",children:p("div",{className:b("media-cover","relative h-screen w-full"),children:[B?e(ae,{youTubeId:n&&Y||N}):v?.url&&e(de,{videoRef:R,poster:n&&s?.url?s?.url:m?.url,src:n&&r?.url?r?.url:v?.url,className:"lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930] lg:aspect-w-[1440] lg:aspect-h-[700] desktop:aspect-w-[1024] desktop:aspect-h-[520] tablet:aspect-w-[768] tablet:aspect-h-[660] aspect-w-[390] aspect-h-[660]",videoClassName:" object-cover object-[82%]",muted:!0,loop:!1,playsInline:!0,autoplay:!1,onEnded:()=>{Q(!0)}}),m?.url&&(!v?.url||V)&&e("img",{src:n&&s?.url?s?.url:m?.url,alt:m?.alt,className:"z-1 absolute left-0 top-0 size-full object-cover object-[82%]",loading:"lazy"}),e("div",{className:"sticky-cover absolute left-0 top-0 z-10 size-full",style:{backdropFilter:"blur(0px)",WebkitBackdropFilter:"blur(0px)",willChange:"backdrop-filter"}})]})}),e("div",{className:"relative h-screen w-full"}),e(P,{components:I}),e("div",{className:"relative h-screen w-full"})]})]})});L.displayName="MediaPlayerSticky";var He=te(L);export{He as default};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/biz-components/MediaPlayerSticky/index.tsx"],
4
- "sourcesContent": ["'use client'\nimport React, { useState, useRef, useEffect, forwardRef } from 'react'\nimport { debounce } from 'es-toolkit'\nimport { useInView } from 'react-intersection-observer'\nimport { cn } from '../../helpers/utils.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport Slogan from '../Slogan/index.js'\nimport { YouTubePlayer } from '../VideoModal/YouTubePlayer.js'\nimport { Grid, GridItem } from '../../components/grid.js'\nimport { Container } from '../../components/container.js'\nimport BrandEquity from '../BrandEquity/index.js'\nimport MemberEquity from '../MemberEquity/index.js'\nimport Spacer from '../Spacer/index.js'\nimport gsap from 'gsap'\nimport { convertLexicalToHTML } from '@payloadcms/richtext-lexical/html'\n\nimport type { HTMLConvertersFunction } from '@payloadcms/richtext-lexical/html'\n\nimport { useMediaQuery } from 'react-responsive'\nimport type { MediaPlayerBaseProps, MediaPlayerComponent } from './types.js'\nimport ScrollLoadVideo from '../../helpers/ScrollLoadVideo.js'\n\nconst htmlConverters: HTMLConvertersFunction = ({ defaultConverters }) =>\n ({\n ...defaultConverters,\n text: (args: any) => {\n const { node } = args\n\n // \u68C0\u67E5\u662F\u5426\u6709\u81EA\u5B9A\u4E49 color\n if (node.$ && node.$.color) {\n return `<span class=\"lexical-${node.$.color}\">${node.text}</span>`\n }\n return node.text\n },\n }) as any\n\nconst SubContainer = ({\n children,\n spaceY,\n className,\n}: {\n children: React.ReactNode\n spaceY?: string\n className?: string\n}) => {\n const isMobile = useMediaQuery({ query: '(max-width: 768px)' })\n return (\n <Container spaceY={spaceY} className={cn('!bg-transparent', className)}>\n <Grid>\n {!isMobile && <GridItem span={1} />}\n <GridItem span={isMobile ? 12 : 10}>{children}</GridItem>\n {!isMobile && <GridItem span={1} />}\n </Grid>\n </Container>\n )\n}\n\nconst SubBox = React.forwardRef<\n {\n mediaPlayerStickyRef: HTMLDivElement\n },\n {\n children?: React.ReactNode\n id?: string\n components?: MediaPlayerComponent[]\n }\n>(({ children, id, components }, ref) => {\n const mediaPlayerStickyRef = useRef<HTMLDivElement>(null)\n\n return (\n <div ref={mediaPlayerStickyRef} className=\"relative z-10\">\n <>{children}</>\n <>\n {components?.map((componentData: any, index: number) => {\n switch (componentData.blockType) {\n case 'ipc-brand-equity': {\n return (\n <div key={`${componentData.blockType}-${index}`} className=\"relative z-20 bg-transparent\">\n <SubContainer spaceY=\"none\">\n <BrandEquity data={componentData} style={componentData?.style} />\n </SubContainer>\n </div>\n )\n }\n case 'ipc-member-equity': {\n return (\n <div key={`${componentData.blockType}-${index}`} className=\"relative z-20 w-full bg-transparent\">\n <SubContainer spaceY=\"none\">\n <MemberEquity data={componentData} className=\"w-full\" style={componentData?.style} />\n </SubContainer>\n </div>\n )\n }\n case 'ipc-spacer': {\n return (\n <Spacer\n key={`${componentData.blockType}-${index}`}\n data={componentData}\n style={componentData?.style}\n className=\"!bg-transparent\"\n />\n )\n }\n default:\n return null\n }\n })}\n </>\n </div>\n )\n})\n\nSubBox.displayName = 'SubBox'\n\nconst MediaPlayerSticky = forwardRef<\n {\n mediaPlayerStickyRef: HTMLDivElement\n },\n MediaPlayerBaseProps\n>(\n (\n {\n className = '',\n wrapperClassName = '',\n id,\n data: {\n title,\n videoTitle,\n mobVideo,\n mobImg,\n img,\n isYouTube,\n youtubePcId,\n youtubeMobileId,\n video,\n theme,\n shape,\n components,\n },\n ...rest\n },\n ref\n ) => {\n const videoRef = useRef<HTMLVideoElement>(null)\n const boxRef = useRef<HTMLDivElement>(null)\n const { ref: inViewRef, inView } = useInView()\n const [screenHeight, setScreenHeight] = useState(0)\n const [isPlaying, setIsPlaying] = useState(false)\n const [isEntered, setIsEntered] = useState(false)\n const wrapperRef = useRef<HTMLDivElement>(null)\n\n const title_html =\n typeof title === 'string' ? title : title && convertLexicalToHTML({ data: title, converters: htmlConverters })\n typeof videoTitle === 'string'\n ? videoTitle\n : videoTitle && convertLexicalToHTML({ data: videoTitle, converters: htmlConverters })\n\n const [btb, setbtb] = useState(0)\n const [isMobile, setIsMobile] = useState(false)\n const mediaQuery = useMediaQuery({ query: '(max-width: 768px)' })\n\n useEffect(() => {\n setIsMobile(mediaQuery)\n }, [mediaQuery])\n\n useEffect(() => {\n if (inView && !isPlaying) {\n videoRef.current?.play()\n setIsPlaying(true)\n }\n }, [inView, isPlaying])\n\n useEffect(() => {\n const debouncedHandleResize = debounce(() => {\n if (boxRef.current) {\n const rect = boxRef.current.getBoundingClientRect()\n const screenHeight = isMobile ? window.screen.height : window.innerHeight\n const scrollTop = window.scrollY || window.pageYOffset\n const elementBottomToPageTop = rect.bottom + scrollTop\n const pageHeight = document.documentElement.scrollHeight\n const distanceToPageBottom = pageHeight - elementBottomToPageTop\n setbtb(distanceToPageBottom > screenHeight ? screenHeight : distanceToPageBottom)\n setScreenHeight(screenHeight)\n }\n }, 2000)\n debouncedHandleResize()\n window.addEventListener('resize', debouncedHandleResize)\n return () => {\n window.removeEventListener('resize', debouncedHandleResize)\n }\n }, [])\n\n useEffect(() => {\n function gsapResize() {\n const height = isMobile ? window.screen.height : window.innerHeight\n gsap\n .timeline({\n scrollTrigger: {\n trigger: `#${id}`,\n start: 'top top',\n end: `top+=${height * 1.8}px bottom`,\n scrub: 0.5,\n },\n })\n .from(`#${id} .media-content`, { top: '50%', transform: 'translate(-50%, -50%)' })\n .to(`.${id} .sticky-cover`, {\n backdropFilter: 'blur(8px)',\n duration: 0.4,\n })\n .to(\n `#${id} .media-content`,\n {\n top: '100%',\n transform: 'translate(-50%, -100%)',\n duration: 1,\n },\n '<'\n )\n }\n if (inView) {\n gsapResize()\n }\n }, [inView])\n\n return (\n <>\n <div\n id={id}\n {...rest}\n className={cn('relative z-20 h-screen w-full', className, {\n 'aiui-dark': theme === 'dark',\n 'rounded-box': shape === 'rounded',\n })}\n ref={wrapperRef}\n >\n <div\n ref={inViewRef}\n className=\"media-content translate-z-0 absolute left-1/2 top-1/2 z-10 w-full -translate-x-1/2 -translate-y-1/2 antialiased\"\n style={{ willChange: 'transform', contain: 'paint' }}\n >\n <SubContainer spaceY=\"tablet:my-[32px] my-[24px] space-y-4\">\n <Slogan className=\"sticky-title antialiased\" data={{ title: title_html || '', theme, tag: 'h2' }} />\n </SubContainer>\n </div>\n </div>\n\n <div\n ref={boxRef}\n style={{ marginBottom: `-${btb}px`, zIndex: inView ? 2 : 1 }}\n className={cn(id, 'relative mt-[-200vh]', wrapperClassName)}\n >\n <div className=\"sticky top-0 \">\n <div className={cn('media-cover', 'relative h-screen w-full')}>\n {isYouTube ? (\n <YouTubePlayer youTubeId={isMobile ? youtubeMobileId || youtubePcId : youtubePcId} />\n ) : (\n video?.url && (\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={isMobile && mobImg?.url ? mobImg?.url : img?.url}\n src={isMobile && mobVideo?.url ? mobVideo?.url : video?.url}\n className=\"lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930] lg:aspect-w-[1440] lg:aspect-h-[700] desktop:aspect-w-[1024] desktop:aspect-h-[520] tablet:aspect-w-[768] tablet:aspect-h-[660] aspect-w-[390] aspect-h-[660]\"\n videoClassName=\" object-cover object-[82%]\"\n muted\n loop={false}\n playsInline\n autoplay={false}\n onEnded={() => {\n setIsEntered(true)\n }}\n />\n )\n )}\n {img?.url && (!video?.url || isEntered) && (\n <img\n src={isMobile && mobImg?.url ? mobImg?.url : img?.url}\n alt={img?.alt}\n className=\"z-1 absolute left-0 top-0 size-full object-cover object-[82%]\"\n loading=\"lazy\"\n />\n )}\n <div\n className=\"sticky-cover absolute left-0 top-0 z-10 size-full\"\n style={{\n backdropFilter: 'blur(0px)',\n WebkitBackdropFilter: 'blur(0px)',\n willChange: 'backdrop-filter',\n }}\n />\n </div>\n </div>\n\n <div className=\"relative h-screen w-full\" />\n <SubBox components={components}></SubBox>\n <div className=\"relative h-screen w-full\" />\n </div>\n </>\n )\n }\n)\n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C,OAAI,UAAWQ,EAAG,cAAe,0BAA0B,EACzD,UAAAqC,EACC9C,EAACY,GAAA,CAAc,UAAWmB,GAAWiB,GAAmBD,EAA2B,EAEnFE,GAAO,KACLjD,EAACsB,GAAA,CACC,SAAU+B,EACV,OAAQtB,GAAYa,GAAQ,IAAMA,GAAQ,IAAMC,GAAK,IACrD,IAAKd,GAAYY,GAAU,IAAMA,GAAU,IAAMM,GAAO,IACxD,UAAU,qNACV,eAAe,6BACf,MAAK,GACL,KAAM,GACN,YAAW,GACX,SAAU,GACV,QAAS,IAAM,CACba,EAAa,EAAI,CACnB,EACF,EAGHjB,GAAK,MAAQ,CAACI,GAAO,KAAOY,IAC3B7D,EAAC,OACC,IAAK+B,GAAYa,GAAQ,IAAMA,GAAQ,IAAMC,GAAK,IAClD,IAAKA,GAAK,IACV,UAAU,iEACV,QAAQ,OACV,EAEF7C,EAAC,OACC,UAAU,oDACV,MAAO,CACL,eAAgB,YAChB,qBAAsB,YACtB,WAAY,iBACd,EACF,GACF,EACF,EAEAA,EAAC,OAAI,UAAU,2BAA2B,EAC1CA,EAACgC,EAAA,CAAO,WAAYE,EAAY,EAChClC,EAAC,OAAI,UAAU,2BAA2B,GAC5C,GACF,CAEJ,CACF,EACAuC,EAAkB,YAAc,oBAEhC,IAAOqC,GAAQlE,GAAW6B,CAAiB",
6
- "names": ["Fragment", "jsx", "jsxs", "React", "useState", "useRef", "useEffect", "forwardRef", "debounce", "useInView", "cn", "withLayout", "Slogan", "YouTubePlayer", "Grid", "GridItem", "Container", "BrandEquity", "MemberEquity", "Spacer", "gsap", "convertLexicalToHTML", "useMediaQuery", "ScrollLoadVideo", "htmlConverters", "defaultConverters", "args", "node", "SubContainer", "children", "spaceY", "className", "isMobile", "SubBox", "id", "components", "ref", "mediaPlayerStickyRef", "componentData", "index", "MediaPlayerSticky", "wrapperClassName", "title", "videoTitle", "mobVideo", "mobImg", "img", "isYouTube", "youtubePcId", "youtubeMobileId", "video", "theme", "shape", "rest", "videoRef", "boxRef", "inViewRef", "inView", "screenHeight", "setScreenHeight", "isPlaying", "setIsPlaying", "isEntered", "setIsEntered", "wrapperRef", "title_html", "btb", "setbtb", "setIsMobile", "mediaQuery", "debouncedHandleResize", "rect", "scrollTop", "elementBottomToPageTop", "distanceToPageBottom", "gsapResize", "height", "MediaPlayerSticky_default"]
4
+ "sourcesContent": ["'use client'\nimport React, { useState, useRef, useEffect, forwardRef } from 'react'\nimport { debounce } from 'es-toolkit'\nimport { useInView } from 'react-intersection-observer'\nimport { cn } from '../../helpers/utils.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport Slogan from '../Slogan/index.js'\nimport { YouTubePlayer } from '../VideoModal/YouTubePlayer.js'\nimport { Grid, GridItem } from '../../components/grid.js'\nimport { Container } from '../../components/container.js'\nimport BrandEquity from '../BrandEquity/index.js'\nimport MemberEquity from '../MemberEquity/index.js'\nimport Spacer from '../Spacer/index.js'\nimport gsap from 'gsap'\nimport { convertLexicalToHTML } from '@payloadcms/richtext-lexical/html'\n\nimport type { HTMLConvertersFunction } from '@payloadcms/richtext-lexical/html'\n\nimport { useIsomorphicMediaQuery } from '../../hooks/useIsomorphicMediaQuery.js'\nimport type { MediaPlayerBaseProps, MediaPlayerComponent } from './types.js'\nimport ScrollLoadVideo from '../../helpers/ScrollLoadVideo.js'\n\nconst htmlConverters: HTMLConvertersFunction = ({ defaultConverters }) =>\n ({\n ...defaultConverters,\n text: (args: any) => {\n const { node } = args\n\n // \u68C0\u67E5\u662F\u5426\u6709\u81EA\u5B9A\u4E49 color\n if (node.$ && node.$.color) {\n return `<span class=\"lexical-${node.$.color}\">${node.text}</span>`\n }\n return node.text\n },\n }) as any\n\nconst SubContainer = ({\n children,\n spaceY,\n className,\n}: {\n children: React.ReactNode\n spaceY?: string\n className?: string\n}) => {\n const isMobile = useIsomorphicMediaQuery({ query: '(max-width: 768px)' })\n return (\n <Container spaceY={spaceY} className={cn('!bg-transparent', className)}>\n <Grid>\n {!isMobile && <GridItem span={1} />}\n <GridItem span={isMobile ? 12 : 10}>{children}</GridItem>\n {!isMobile && <GridItem span={1} />}\n </Grid>\n </Container>\n )\n}\n\nconst SubBox = React.forwardRef<\n {\n mediaPlayerStickyRef: HTMLDivElement\n },\n {\n children?: React.ReactNode\n id?: string\n components?: MediaPlayerComponent[]\n }\n>(({ children, id, components }, ref) => {\n const mediaPlayerStickyRef = useRef<HTMLDivElement>(null)\n\n return (\n <div ref={mediaPlayerStickyRef} className=\"relative z-10\">\n <>{children}</>\n <>\n {components?.map((componentData: any, index: number) => {\n switch (componentData.blockType) {\n case 'ipc-brand-equity': {\n return (\n <div key={`${componentData.blockType}-${index}`} className=\"relative z-20 bg-transparent\">\n <SubContainer spaceY=\"none\">\n <BrandEquity data={componentData} style={componentData?.style} />\n </SubContainer>\n </div>\n )\n }\n case 'ipc-member-equity': {\n return (\n <div key={`${componentData.blockType}-${index}`} className=\"relative z-20 w-full bg-transparent\">\n <SubContainer spaceY=\"none\">\n <MemberEquity data={componentData} className=\"w-full\" style={componentData?.style} />\n </SubContainer>\n </div>\n )\n }\n case 'ipc-spacer': {\n return (\n <Spacer\n key={`${componentData.blockType}-${index}`}\n data={componentData}\n style={componentData?.style}\n className=\"!bg-transparent\"\n />\n )\n }\n default:\n return null\n }\n })}\n </>\n </div>\n )\n})\n\nSubBox.displayName = 'SubBox'\n\nconst MediaPlayerSticky = forwardRef<\n {\n mediaPlayerStickyRef: HTMLDivElement\n },\n MediaPlayerBaseProps\n>(\n (\n {\n className = '',\n wrapperClassName = '',\n id,\n data: {\n title,\n videoTitle,\n mobVideo,\n mobImg,\n img,\n isYouTube,\n youtubePcId,\n youtubeMobileId,\n video,\n theme,\n shape,\n components,\n },\n ...rest\n },\n ref\n ) => {\n const videoRef = useRef<HTMLVideoElement>(null)\n const boxRef = useRef<HTMLDivElement>(null)\n const { ref: inViewRef, inView } = useInView()\n const [isPlaying, setIsPlaying] = useState(false)\n const [isEntered, setIsEntered] = useState(false)\n const wrapperRef = useRef<HTMLDivElement>(null)\n\n const title_html =\n typeof title === 'string' ? title : title && convertLexicalToHTML({ data: title, converters: htmlConverters })\n typeof videoTitle === 'string'\n ? videoTitle\n : videoTitle && convertLexicalToHTML({ data: videoTitle, converters: htmlConverters })\n\n const [btb, setbtb] = useState(0)\n const [isMobile, setIsMobile] = useState(false)\n const mediaQuery = useIsomorphicMediaQuery({ query: '(max-width: 768px)' })\n\n useEffect(() => {\n setIsMobile(mediaQuery)\n }, [mediaQuery])\n\n useEffect(() => {\n if (inView && !isPlaying) {\n videoRef.current?.play()\n setIsPlaying(true)\n }\n }, [inView, isPlaying])\n\n useEffect(() => {\n const debouncedHandleResize = debounce(() => {\n if (boxRef.current) {\n const rect = boxRef.current.getBoundingClientRect()\n const screenHeight = isMobile ? window.screen.height : window.innerHeight\n const scrollTop = window.scrollY || window.pageYOffset\n const elementBottomToPageTop = rect.bottom + scrollTop\n const pageHeight = document.documentElement.scrollHeight\n const distanceToPageBottom = pageHeight - elementBottomToPageTop\n setbtb(distanceToPageBottom > screenHeight ? screenHeight : distanceToPageBottom)\n }\n }, 2000)\n debouncedHandleResize()\n window.addEventListener('resize', debouncedHandleResize)\n return () => {\n window.removeEventListener('resize', debouncedHandleResize)\n }\n }, [])\n\n useEffect(() => {\n function gsapResize() {\n const height = isMobile ? window.screen.height : window.innerHeight\n gsap\n .timeline({\n scrollTrigger: {\n trigger: `#${id}`,\n start: 'top top',\n end: `top+=${height * 1.8}px bottom`,\n scrub: 0.5,\n },\n })\n .from(`#${id} .media-content`, { top: '50%', transform: 'translate(-50%, -50%)' })\n .to(`.${id} .sticky-cover`, {\n backdropFilter: 'blur(8px)',\n duration: 0.4,\n })\n .to(\n `#${id} .media-content`,\n {\n top: '100%',\n transform: 'translate(-50%, -100%)',\n duration: 1,\n },\n '<'\n )\n }\n if (inView) {\n gsapResize()\n }\n }, [inView])\n\n return (\n <>\n <div\n id={id}\n {...rest}\n className={cn('relative z-20 h-screen w-full', className, {\n 'aiui-dark': theme === 'dark',\n 'rounded-box': shape === 'rounded',\n })}\n ref={wrapperRef}\n >\n <div\n ref={inViewRef}\n className=\"media-content translate-z-0 absolute left-1/2 top-1/2 z-10 w-full -translate-x-1/2 -translate-y-1/2 antialiased\"\n style={{ willChange: 'transform', contain: 'paint' }}\n >\n <SubContainer spaceY=\"tablet:my-[32px] my-[24px] space-y-4\">\n <Slogan className=\"sticky-title antialiased\" data={{ title: title_html || '', theme, tag: 'h2' }} />\n </SubContainer>\n </div>\n </div>\n\n <div\n ref={boxRef}\n style={{ marginBottom: `-${btb}px`, zIndex: inView ? 2 : 1 }}\n className={cn(id, 'relative mt-[-200vh]', wrapperClassName)}\n >\n <div className=\"sticky top-0 \">\n <div className={cn('media-cover', 'relative h-screen w-full')}>\n {isYouTube ? (\n <YouTubePlayer youTubeId={isMobile ? youtubeMobileId || youtubePcId : youtubePcId} />\n ) : (\n video?.url && (\n <ScrollLoadVideo\n videoRef={videoRef}\n poster={isMobile && mobImg?.url ? mobImg?.url : img?.url}\n src={isMobile && mobVideo?.url ? mobVideo?.url : video?.url}\n className=\"lg-desktop:aspect-w-[1920] lg-desktop:aspect-h-[930] lg:aspect-w-[1440] lg:aspect-h-[700] desktop:aspect-w-[1024] desktop:aspect-h-[520] tablet:aspect-w-[768] tablet:aspect-h-[660] aspect-w-[390] aspect-h-[660]\"\n videoClassName=\" object-cover object-[82%]\"\n muted\n loop={false}\n playsInline\n autoplay={false}\n onEnded={() => {\n setIsEntered(true)\n }}\n />\n )\n )}\n {img?.url && (!video?.url || isEntered) && (\n <img\n src={isMobile && mobImg?.url ? mobImg?.url : img?.url}\n alt={img?.alt}\n className=\"z-1 absolute left-0 top-0 size-full object-cover object-[82%]\"\n loading=\"lazy\"\n />\n )}\n <div\n className=\"sticky-cover absolute left-0 top-0 z-10 size-full\"\n style={{\n backdropFilter: 'blur(0px)',\n WebkitBackdropFilter: 'blur(0px)',\n willChange: 'backdrop-filter',\n }}\n />\n </div>\n </div>\n\n <div className=\"relative h-screen w-full\" />\n <SubBox components={components}></SubBox>\n <div className=\"relative h-screen w-full\" />\n </div>\n </>\n )\n }\n)\nMediaPlayerSticky.displayName = 'MediaPlayerSticky'\n\nexport default withLayout(MediaPlayerSticky)\n"],
5
+ "mappings": "aAgDM,OAuBA,YAAAA,EAtBgB,OAAAC,EADhB,QAAAC,MAAA,oBA/CN,OAAOC,GAAS,YAAAC,EAAU,UAAAC,EAAQ,aAAAC,EAAW,cAAAC,MAAkB,QAC/D,OAAS,YAAAC,MAAgB,aACzB,OAAS,aAAAC,OAAiB,8BAC1B,OAAS,MAAAC,MAAU,yBACnB,OAAS,cAAAC,OAAkB,yBAC3B,OAAOC,OAAY,qBACnB,OAAS,iBAAAC,OAAqB,iCAC9B,OAAS,QAAAC,GAAM,YAAAC,MAAgB,2BAC/B,OAAS,aAAAC,OAAiB,gCAC1B,OAAOC,OAAiB,0BACxB,OAAOC,OAAkB,2BACzB,OAAOC,OAAY,qBACnB,OAAOC,OAAU,OACjB,OAAS,wBAAAC,MAA4B,oCAIrC,OAAS,2BAAAC,MAA+B,yCAExC,OAAOC,OAAqB,mCAE5B,MAAMC,EAAyC,CAAC,CAAE,kBAAAC,CAAkB,KACjE,CACC,GAAGA,EACH,KAAOC,GAAc,CACnB,KAAM,CAAE,KAAAC,CAAK,EAAID,EAGjB,OAAIC,EAAK,GAAKA,EAAK,EAAE,MACZ,wBAAwBA,EAAK,EAAE,KAAK,KAAKA,EAAK,IAAI,UAEpDA,EAAK,IACd,CACF,GAEIC,EAAe,CAAC,CACpB,SAAAC,EACA,OAAAC,EACA,UAAAC,CACF,IAIM,CACJ,MAAMC,EAAWV,EAAwB,CAAE,MAAO,oBAAqB,CAAC,EACxE,OACErB,EAACe,GAAA,CAAU,OAAQc,EAAQ,UAAWpB,EAAG,kBAAmBqB,CAAS,EACnE,SAAA7B,EAACY,GAAA,CACE,WAACkB,GAAY/B,EAACc,EAAA,CAAS,KAAM,EAAG,EACjCd,EAACc,EAAA,CAAS,KAAMi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AAC,OAAI,UAAWQ,EAAG,cAAe,0BAA0B,EACzD,UAAAqC,EACC9C,EAACY,GAAA,CAAc,UAAWmB,GAAWiB,GAAmBD,EAA2B,EAEnFE,GAAO,KACLjD,EAACsB,GAAA,CACC,SAAU+B,EACV,OAAQtB,GAAYa,GAAQ,IAAMA,GAAQ,IAAMC,GAAK,IACrD,IAAKd,GAAYY,GAAU,IAAMA,GAAU,IAAMM,GAAO,IACxD,UAAU,qNACV,eAAe,6BACf,MAAK,GACL,KAAM,GACN,YAAW,GACX,SAAU,GACV,QAAS,IAAM,CACbW,EAAa,EAAI,CACnB,EACF,EAGHf,GAAK,MAAQ,CAACI,GAAO,KAAOU,IAC3B3D,EAAC,OACC,IAAK+B,GAAYa,GAAQ,IAAMA,GAAQ,IAAMC,GAAK,IAClD,IAAKA,GAAK,IACV,UAAU,iEACV,QAAQ,OACV,EAEF7C,EAAC,OACC,UAAU,oDACV,MAAO,CACL,eAAgB,YAChB,qBAAsB,YACtB,WAAY,iBACd,EACF,GACF,EACF,EAEAA,EAAC,OAAI,UAAU,2BAA2B,EAC1CA,EAACgC,EAAA,CAAO,WAAYE,EAAY,EAChClC,EAAC,OAAI,UAAU,2BAA2B,GAC5C,GACF,CAEJ,CACF,EACAuC,EAAkB,YAAc,oBAEhC,IAAOoC,GAAQjE,GAAW6B,CAAiB",
6
+ "names": ["Fragment", "jsx", "jsxs", "React", "useState", "useRef", "useEffect", "forwardRef", "debounce", "useInView", "cn", "withLayout", "Slogan", "YouTubePlayer", "Grid", "GridItem", "Container", "BrandEquity", "MemberEquity", "Spacer", "gsap", "convertLexicalToHTML", "useIsomorphicMediaQuery", "ScrollLoadVideo", "htmlConverters", "defaultConverters", "args", "node", "SubContainer", "children", "spaceY", "className", "isMobile", "SubBox", "id", "components", "ref", "mediaPlayerStickyRef", "componentData", "index", "MediaPlayerSticky", "wrapperClassName", "title", "videoTitle", "mobVideo", "mobImg", "img", "isYouTube", "youtubePcId", "youtubeMobileId", "video", "theme", "shape", "rest", "videoRef", "boxRef", "inViewRef", "inView", "isPlaying", "setIsPlaying", "isEntered", "setIsEntered", "wrapperRef", "title_html", "btb", "setbtb", "setIsMobile", "mediaQuery", "debouncedHandleResize", "rect", "screenHeight", "scrollTop", "elementBottomToPageTop", "distanceToPageBottom", "gsapResize", "height", "MediaPlayerSticky_default"]
7
7
  }
@@ -1,6 +1,6 @@
1
1
  import type { MediaSceneSwitcherProps } from './types.js';
2
2
  import 'swiper/css';
3
- declare const _default: import("react").ForwardRefExoticComponent<Omit<MediaSceneSwitcherProps & import("react").RefAttributes<HTMLDivElement>, "container" | keyof import("../../shared/Styles.js").StylesProps> & import("../../shared/Styles.js").StylesProps & import("../WheelLottery/index.js").ContainerProps & import("react").RefAttributes<unknown>> & {
3
+ declare const _default: import("react").ForwardRefExoticComponent<Omit<MediaSceneSwitcherProps & import("react").RefAttributes<HTMLDivElement>, "container" | keyof import("../../shared/Styles.js").StylesProps> & import("../../shared/Styles.js").StylesProps & import("../index.js").ContainerProps & import("react").RefAttributes<unknown>> & {
4
4
  readonly $$typeof: symbol;
5
5
  };
6
6
  export default _default;
@@ -1,4 +1,4 @@
1
- "use client";import{Fragment as G,jsx as e,jsxs as l}from"react/jsx-runtime";import{useState as M,useRef as f,useEffect as j,forwardRef as R,useImperativeHandle as H}from"react";import{useMediaQuery as C}from"react-responsive";import{cn as n}from"../../helpers/utils.js";import{withLayout as V}from"../../shared/Styles.js";import{Heading as h,Text as w,Picture as b}from"../../components/index.js";import{useExposure as S}from"../../hooks/useExposure.js";import{Swiper as _,SwiperSlide as q}from"swiper/react";import{Autoplay as $}from"swiper/modules";import"swiper/css";const A="media",D="media_scene_switcher",v=3e3,O=({data:t,configuration:c,theme:o})=>{const d=f(null),i=c?.isActive||!1;return S(d,{componentType:A,componentName:D,componentTitle:t?.title,position:(c?.index??0)+1}),l("div",{ref:d,className:n("media-scene-switcher-item rounded-box cursor-pointer overflow-hidden transition-colors","relative text-[#6D6D6F]",i?"opacity-100":"opacity-60",{"bg-[#1D1D1F] text-white":i,"bg-[#EAEAEC] text-[1D1D1F]":i&&o==="light"}),onClick:()=>c?.onItemClick?.(c?.index??0),children:[l("div",{className:"media-scene-switcher-item-content laptop:gap-[32px] laptop:p-[12px] desktop:gap-[48px] desktop:p-[24px] flex items-center justify-between gap-[24px]",children:[l("div",{children:[e("div",{className:"media-scene-switcher-item-title flex-1",children:e(h,{as:"h6",size:2,html:t?.title})}),t?.description&&i&&e(w,{size:2,className:"media-scene-switcher-item-description tablet:text-base desktop:text-lg mt-1 text-sm font-bold",html:t.description})]}),e("div",{className:n("media-scene-switcher-item-badge rounded-btn border-[1.6px] px-[18px] py-[7px]",o==="dark"?"border-[#B5B7BB]":"border-[#4A4C56]",{"!border-[#F5F6F7]":o==="dark"&&i}),children:e(h,{as:"h6",size:2,html:t?.tag})})]}),e("div",{className:n("media-scene-switcher-progress absolute bottom-0 left-0 h-[2px] w-full",{"media-scene-switcher-progress-active":i}),style:{transform:"translate3d(-100%, 0, 0)",background:"linear-gradient(90deg, #3ad1ff 0%, #008cd6 100%)",animation:i?`progress-bar ${v}ms ease-out`:"none"}})]})},Q=({data:t,configuration:c,theme:o})=>{const d=f(null),i=c?.isActive||!1,m=C({query:"(max-width: 768px)"});S(d,{componentType:A,componentName:D,componentTitle:t?.title,position:(c?.index??0)+1});const r=m&&t?.mobVideoUrl?.url?t.mobVideoUrl.url:t?.videoUrl?.url,p=m&&t?.mobImageUrl?.url?t.mobImageUrl.url:t?.imageUrl?.url,g=p||t?.videoUrl?.thumbnailURL||"";return l("div",{ref:d,className:n("media-scene-switcher-mobile-item rounded-box flex h-[360px] w-[296px] max-w-full flex-col overflow-hidden",{"aiui-dark":o==="dark"}),children:[e("div",{className:"media-scene-switcher-mobile-media relative aspect-[554/480] w-full overflow-hidden",children:r?e("video",{src:r,playsInline:!0,autoPlay:!0,loop:!0,muted:!0,poster:g,className:"size-full object-cover"}):p?e(b,{className:"size-full",imgClassName:"size-full object-cover",source:p,alt:t?.title||""}):null}),l("div",{className:n("media-scene-switcher-mobile-bottom flex items-start justify-between gap-[8px] p-[16px]","text-[#6D6D6F]",{"bg-[#1D1D1F] text-white":i,"bg-[#EAEAEC] text-[1D1D1F]":i&&o==="light"}),children:[l("div",{children:[e("div",{className:"media-scene-switcher-mobile-title line-clamp-3 h-[72px] flex-1",children:e(h,{as:"h6",size:2,html:t?.title})}),t?.description&&i&&e(w,{size:2,className:"media-scene-switcher-item-description tablet:text-base desktop:text-lg mt-1 line-clamp-3 text-sm font-bold",html:t.description})]}),e("div",{className:n("media-scene-switcher-mobile-badge rounded-btn shrink-0 border-[1.6px] px-[12px] py-[5px]",o==="dark"?"border-[#B5B7BB]":"border-[#4A4C56]",{"!border-[#F5F6F7]":o==="dark"&&i}),children:e(h,{as:"h6",size:1,html:t?.tag})})]}),e("div",{className:n("media-scene-switcher-progress h-[2px] w-full",{"media-scene-switcher-progress-active":i}),style:{transform:"translate3d(-100%, 0, 0)",background:"linear-gradient(90deg, #3ad1ff 0%, #008cd6 100%)",animation:i?`progress-bar ${v}ms ease-out`:"none"}})]})},F=R(({className:t="",data:c,id:o},d)=>{const{title:i,subtitle:m,items:r=[],theme:p="light",layout:g,titleIcon:x}=c||{},[N,k]=M(0),[T,B]=M(0),y=f(null),u=f(0),z=C({query:"(max-width: 1023px)"});H(d,()=>y.current),S(y,{componentType:A,componentName:D,componentTitle:i}),j(()=>{if(!(z||r.length===0))return u.current=window.setInterval(()=>{k(s=>(s+1)%r.length)},v),()=>{u.current&&window.clearInterval(u.current)}},[z,r.length]);const P=s=>{k(s),u.current&&window.clearInterval(u.current),u.current=window.setInterval(()=>{k(a=>(a+1)%r.length)},v)},I=r[N],J=I?.videoUrl?.url,W=I?.imageUrl?.url||I?.videoUrl?.thumbnailURL||"";return l(G,{children:[e("style",{children:`
1
+ "use client";import{Fragment as G,jsx as e,jsxs as l}from"react/jsx-runtime";import{useState as M,useRef as f,useEffect as j,forwardRef as R,useImperativeHandle as H}from"react";import{useIsomorphicMediaQuery as C}from"../../hooks/useIsomorphicMediaQuery.js";import{cn as n}from"../../helpers/utils.js";import{withLayout as V}from"../../shared/Styles.js";import{Heading as h,Text as w,Picture as b}from"../../components/index.js";import{useExposure as S}from"../../hooks/useExposure.js";import{Swiper as _,SwiperSlide as q}from"swiper/react";import{Autoplay as $}from"swiper/modules";import"swiper/css";const A="media",D="media_scene_switcher",v=3e3,O=({data:t,configuration:c,theme:a})=>{const d=f(null),i=c?.isActive||!1;return S(d,{componentType:A,componentName:D,componentTitle:t?.title,position:(c?.index??0)+1}),l("div",{ref:d,className:n("media-scene-switcher-item rounded-box cursor-pointer overflow-hidden transition-colors","relative text-[#6D6D6F]",i?"opacity-100":"opacity-60",{"bg-[#1D1D1F] text-white":i,"bg-[#EAEAEC] text-[1D1D1F]":i&&a==="light"}),onClick:()=>c?.onItemClick?.(c?.index??0),children:[l("div",{className:"media-scene-switcher-item-content laptop:gap-[32px] laptop:p-[12px] desktop:gap-[48px] desktop:p-[24px] flex items-center justify-between gap-[24px]",children:[l("div",{children:[e("div",{className:"media-scene-switcher-item-title flex-1",children:e(h,{as:"h6",size:2,html:t?.title})}),t?.description&&i&&e(w,{size:2,className:"media-scene-switcher-item-description tablet:text-base desktop:text-lg mt-1 text-sm font-bold",html:t.description})]}),e("div",{className:n("media-scene-switcher-item-badge rounded-btn border-[1.6px] px-[18px] py-[7px]",a==="dark"?"border-[#B5B7BB]":"border-[#4A4C56]",{"!border-[#F5F6F7]":a==="dark"&&i}),children:e(h,{as:"h6",size:2,html:t?.tag})})]}),e("div",{className:n("media-scene-switcher-progress absolute bottom-0 left-0 h-[2px] w-full",{"media-scene-switcher-progress-active":i}),style:{transform:"translate3d(-100%, 0, 0)",background:"linear-gradient(90deg, #3ad1ff 0%, #008cd6 100%)",animation:i?`progress-bar ${v}ms ease-out`:"none"}})]})},Q=({data:t,configuration:c,theme:a})=>{const d=f(null),i=c?.isActive||!1,m=C({query:"(max-width: 768px)"});S(d,{componentType:A,componentName:D,componentTitle:t?.title,position:(c?.index??0)+1});const r=m&&t?.mobVideoUrl?.url?t.mobVideoUrl.url:t?.videoUrl?.url,p=m&&t?.mobImageUrl?.url?t.mobImageUrl.url:t?.imageUrl?.url,g=p||t?.videoUrl?.thumbnailURL||"";return l("div",{ref:d,className:n("media-scene-switcher-mobile-item rounded-box flex h-[360px] w-[296px] max-w-full flex-col overflow-hidden",{"aiui-dark":a==="dark"}),children:[e("div",{className:"media-scene-switcher-mobile-media relative aspect-[554/480] w-full overflow-hidden",children:r?e("video",{src:r,playsInline:!0,autoPlay:!0,loop:!0,muted:!0,poster:g,className:"size-full object-cover"}):p?e(b,{className:"size-full",imgClassName:"size-full object-cover",source:p,alt:t?.title||""}):null}),l("div",{className:n("media-scene-switcher-mobile-bottom flex items-start justify-between gap-[8px] p-[16px]","text-[#6D6D6F]",{"bg-[#1D1D1F] text-white":i,"bg-[#EAEAEC] text-[1D1D1F]":i&&a==="light"}),children:[l("div",{children:[e("div",{className:"media-scene-switcher-mobile-title line-clamp-3 h-[72px] flex-1",children:e(h,{as:"h6",size:2,html:t?.title})}),t?.description&&i&&e(w,{size:2,className:"media-scene-switcher-item-description tablet:text-base desktop:text-lg mt-1 line-clamp-3 text-sm font-bold",html:t.description})]}),e("div",{className:n("media-scene-switcher-mobile-badge rounded-btn shrink-0 border-[1.6px] px-[12px] py-[5px]",a==="dark"?"border-[#B5B7BB]":"border-[#4A4C56]",{"!border-[#F5F6F7]":a==="dark"&&i}),children:e(h,{as:"h6",size:1,html:t?.tag})})]}),e("div",{className:n("media-scene-switcher-progress h-[2px] w-full",{"media-scene-switcher-progress-active":i}),style:{transform:"translate3d(-100%, 0, 0)",background:"linear-gradient(90deg, #3ad1ff 0%, #008cd6 100%)",animation:i?`progress-bar ${v}ms ease-out`:"none"}})]})},F=R(({className:t="",data:c,id:a},d)=>{const{title:i,subtitle:m,items:r=[],theme:p="light",layout:g,titleIcon:x}=c||{},[N,k]=M(0),[T,B]=M(0),y=f(null),u=f(0),z=C({query:"(max-width: 1023px)"});H(d,()=>y.current),S(y,{componentType:A,componentName:D,componentTitle:i}),j(()=>{if(!(z||r.length===0))return u.current=window.setInterval(()=>{k(s=>(s+1)%r.length)},v),()=>{u.current&&window.clearInterval(u.current)}},[z,r.length]);const P=s=>{k(s),u.current&&window.clearInterval(u.current),u.current=window.setInterval(()=>{k(o=>(o+1)%r.length)},v)},I=r[N],J=I?.videoUrl?.url,W=I?.imageUrl?.url||I?.videoUrl?.thumbnailURL||"";return l(G,{children:[e("style",{children:`
2
2
  @keyframes progress-bar {
3
3
  from {
4
4
  transform: translate3d(-100%, 0, 0);
@@ -7,5 +7,5 @@
7
7
  transform: translate3d(0, 0, 0);
8
8
  }
9
9
  }
10
- `}),l("section",{id:o,ref:y,className:n("media-scene-switcher text-info-primary w-full",{"aiui-dark":p==="dark"},t),children:[l("div",{className:"media-scene-switcher-desktop laptop:gap-[24px] lg-desktop:gap-[40px] laptop:flex hidden w-full items-stretch gap-[20px] overflow-hidden",children:[e("div",{className:n("media-scene-switcher-preview rounded-box laptop:flex-1 relative aspect-[824/640] max-w-[824px] shrink-0 overflow-hidden",{"order-1":g==="right"}),children:r.map((s,a)=>{const E=s?.videoUrl?.url,U=s?.imageUrl?.url,L=U||s?.videoUrl?.thumbnailURL||"";return e("div",{className:n("media-scene-switcher-media rounded-box absolute inset-0 hidden size-full overflow-hidden",{"inline-block":a===N}),children:E?e("video",{src:E,playsInline:!0,autoPlay:!0,loop:!0,muted:!0,poster:L,className:"size-full object-cover"}):U?e(b,{className:"size-full",imgClassName:"size-full object-cover",source:U,alt:s?.title||""}):null},s.id||a)})}),l("div",{className:"media-scene-switcher-sidebar laptop:flex-1 flex shrink-0 flex-col justify-between",children:[l("div",{className:"media-scene-switcher-header flex flex-col",children:[l("div",{className:"desktop:gap-2 flex items-center gap-1",children:[i&&e(h,{as:"h3",html:i,size:4,className:"media-scene-switcher-title text-info-primary tablet:!text-[40px] desktop:!text-[56px] lg-desktop:!text-[64px] text-[40px] leading-none text-[#00BEFA]"}),x&&e(b,{source:x.url,alt:x.alt||"title icon",className:"desktop:h-8 lg-desktop:h-10 h-6",imgClassName:"!w-auto h-full"})]}),m&&e(w,{as:"span",size:4,html:m,className:"media-scene-switcher-subtitle tablet:text-[14px] laptop:text-[14px] desktop:text-[16px] lg-desktop:text-[18px] relative -top-2 mt-3 text-[14px]"})]}),e("div",{className:"media-scene-switcher-list flex flex-col gap-[16px]",children:r.map((s,a)=>e(O,{data:s,configuration:{index:a,isActive:a===N,onItemClick:P},theme:p},s.id||a))})]})]}),l("div",{className:"media-scene-switcher-mobile laptop:hidden flex flex-col overflow-visible",children:[l("div",{className:"media-scene-switcher-mobile-header",children:[l("div",{className:"desktop:gap-2 flex items-center gap-1",children:[i&&e(h,{as:"h2",html:i,size:2,className:"media-scene-switcher-title tablet:!text-[40px] desktop:!text-[56px] lg-desktop:!text-[64px] text-[40px] leading-tight text-[#00BEFA]"}),x&&e(b,{source:x.url,alt:x.alt||"title icon",className:"desktop:h-8 lg-desktop:h-10 h-6",imgClassName:"!w-auto h-full"})]}),m&&e(w,{as:"span",size:4,html:m,className:"media-scene-switcher-subtitle text-[14px]"})]}),e("div",{className:"media-scene-switcher-mobile-swiper mt-[24px] overflow-visible",children:e(_,{onSlideChange:s=>B(s.realIndex),initialSlide:0,modules:[$],loop:r.length>1,autoplay:r.length>1?{delay:v,disableOnInteraction:!1}:!1,spaceBetween:12,slidesPerView:"auto",watchSlidesProgress:!0,className:"w-full !overflow-visible",children:r.map((s,a)=>e(q,{className:"!h-auto !w-[296px] max-w-full",children:e(Q,{data:s,configuration:{index:a,isActive:a===T},theme:p})},s.id||a))})})]})]})]})});F.displayName="MediaSceneSwitcher";var ae=V(F,{style:"overflow: hidden;"});export{ae as default};
10
+ `}),l("section",{id:a,ref:y,className:n("media-scene-switcher text-info-primary w-full",{"aiui-dark":p==="dark"},t),children:[l("div",{className:"media-scene-switcher-desktop laptop:gap-[24px] lg-desktop:gap-[40px] laptop:flex hidden w-full items-stretch gap-[20px] overflow-hidden",children:[e("div",{className:n("media-scene-switcher-preview rounded-box laptop:flex-1 relative aspect-[824/640] max-w-[824px] shrink-0 overflow-hidden",{"order-1":g==="right"}),children:r.map((s,o)=>{const E=s?.videoUrl?.url,U=s?.imageUrl?.url,L=U||s?.videoUrl?.thumbnailURL||"";return e("div",{className:n("media-scene-switcher-media rounded-box absolute inset-0 hidden size-full overflow-hidden",{"inline-block":o===N}),children:E?e("video",{src:E,playsInline:!0,autoPlay:!0,loop:!0,muted:!0,poster:L,className:"size-full object-cover"}):U?e(b,{className:"size-full",imgClassName:"size-full object-cover",source:U,alt:s?.title||""}):null},s.id||o)})}),l("div",{className:"media-scene-switcher-sidebar laptop:flex-1 flex shrink-0 flex-col justify-between",children:[l("div",{className:"media-scene-switcher-header flex flex-col",children:[l("div",{className:"desktop:gap-2 flex items-center gap-1",children:[i&&e(h,{as:"h3",html:i,size:4,className:"media-scene-switcher-title text-info-primary tablet:!text-[40px] desktop:!text-[56px] lg-desktop:!text-[64px] text-[40px] leading-none text-[#00BEFA]"}),x&&e(b,{source:x.url,alt:x.alt||"title icon",className:"desktop:h-8 lg-desktop:h-10 h-6",imgClassName:"!w-auto h-full"})]}),m&&e(w,{as:"span",size:4,html:m,className:"media-scene-switcher-subtitle tablet:text-[14px] laptop:text-[14px] desktop:text-[16px] lg-desktop:text-[18px] relative -top-2 mt-3 text-[14px]"})]}),e("div",{className:"media-scene-switcher-list flex flex-col gap-[16px]",children:r.map((s,o)=>e(O,{data:s,configuration:{index:o,isActive:o===N,onItemClick:P},theme:p},s.id||o))})]})]}),l("div",{className:"media-scene-switcher-mobile laptop:hidden flex flex-col overflow-visible",children:[l("div",{className:"media-scene-switcher-mobile-header",children:[l("div",{className:"desktop:gap-2 flex items-center gap-1",children:[i&&e(h,{as:"h2",html:i,size:2,className:"media-scene-switcher-title tablet:!text-[40px] desktop:!text-[56px] lg-desktop:!text-[64px] text-[40px] leading-tight text-[#00BEFA]"}),x&&e(b,{source:x.url,alt:x.alt||"title icon",className:"desktop:h-8 lg-desktop:h-10 h-6",imgClassName:"!w-auto h-full"})]}),m&&e(w,{as:"span",size:4,html:m,className:"media-scene-switcher-subtitle text-[14px]"})]}),e("div",{className:"media-scene-switcher-mobile-swiper mt-[24px] overflow-visible",children:e(_,{onSlideChange:s=>B(s.realIndex),initialSlide:0,modules:[$],loop:r.length>1,autoplay:r.length>1?{delay:v,disableOnInteraction:!1}:!1,spaceBetween:12,slidesPerView:"auto",watchSlidesProgress:!0,className:"w-full !overflow-visible",children:r.map((s,o)=>e(q,{className:"!h-auto !w-[296px] max-w-full",children:e(Q,{data:s,configuration:{index:o,isActive:o===T},theme:p})},s.id||o))})})]})]})]})});F.displayName="MediaSceneSwitcher";var oe=V(F,{style:"overflow: hidden;"});export{oe as default};
11
11
  //# sourceMappingURL=MediaSceneSwitcher.js.map