@anker-in/headless-ui 1.3.0 → 1.3.2

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 (37) hide show
  1. package/dist/cjs/biz-components/HeroBanner/HeroBanner.d.ts +1 -1
  2. package/dist/cjs/biz-components/HeroBanner/HeroBanner.js +1 -1
  3. package/dist/cjs/biz-components/HeroBanner/HeroBanner.js.map +3 -3
  4. package/dist/cjs/biz-components/HeroBanner/HeroBannerCarousel.d.ts +1 -0
  5. package/dist/cjs/biz-components/HeroBanner/HeroBannerCarousel.js +1 -1
  6. package/dist/cjs/biz-components/HeroBanner/HeroBannerCarousel.js.map +3 -3
  7. package/dist/cjs/biz-components/HeroBanner/types.d.ts +15 -0
  8. package/dist/cjs/biz-components/HeroBanner/types.js +1 -1
  9. package/dist/cjs/biz-components/HeroBanner/types.js.map +1 -1
  10. package/dist/cjs/biz-components/WebPushPopup/index.d.ts +44 -0
  11. package/dist/cjs/biz-components/WebPushPopup/index.js +2 -0
  12. package/dist/cjs/biz-components/WebPushPopup/index.js.map +7 -0
  13. package/dist/cjs/biz-components/index.d.ts +4 -0
  14. package/dist/cjs/biz-components/index.js +1 -1
  15. package/dist/cjs/biz-components/index.js.map +3 -3
  16. package/dist/cjs/hooks/useEmarsysWebPush.d.ts +111 -0
  17. package/dist/cjs/hooks/useEmarsysWebPush.js +2 -0
  18. package/dist/cjs/hooks/useEmarsysWebPush.js.map +7 -0
  19. package/dist/esm/biz-components/HeroBanner/HeroBanner.d.ts +1 -1
  20. package/dist/esm/biz-components/HeroBanner/HeroBanner.js +1 -1
  21. package/dist/esm/biz-components/HeroBanner/HeroBanner.js.map +3 -3
  22. package/dist/esm/biz-components/HeroBanner/HeroBannerCarousel.d.ts +1 -0
  23. package/dist/esm/biz-components/HeroBanner/HeroBannerCarousel.js +1 -1
  24. package/dist/esm/biz-components/HeroBanner/HeroBannerCarousel.js.map +3 -3
  25. package/dist/esm/biz-components/HeroBanner/types.d.ts +15 -0
  26. package/dist/esm/biz-components/WebPushPopup/index.d.ts +44 -0
  27. package/dist/esm/biz-components/WebPushPopup/index.js +2 -0
  28. package/dist/esm/biz-components/WebPushPopup/index.js.map +7 -0
  29. package/dist/esm/biz-components/index.d.ts +4 -0
  30. package/dist/esm/biz-components/index.js +1 -1
  31. package/dist/esm/biz-components/index.js.map +3 -3
  32. package/dist/esm/hooks/useEmarsysWebPush.d.ts +111 -0
  33. package/dist/esm/hooks/useEmarsysWebPush.js +2 -0
  34. package/dist/esm/hooks/useEmarsysWebPush.js.map +7 -0
  35. package/package.json +4 -2
  36. package/static/emarsys-service-worker.js +31 -0
  37. package/style.css +62 -0
@@ -1,2 +1,2 @@
1
- import{default as a}from"./ActivitySchedule/index.js";import{default as i}from"./GiftShelf/index.js";import{default as s}from"./GiftTierShelf/index.js";import{default as d}from"./ActivityMechanism/index.js";import{default as l}from"./BrandEquity/index.js";import{default as m}from"./MemberEquity/index.js";import{default as x}from"./Slogan/index.js";import{default as h}from"./Title/index.js";import{default as P}from"./Spacer/index.js";import{default as g}from"./ShelfDisplay/index.js";import{default as v}from"./Evaluate/index.js";import{default as B}from"./Category/index.js";import{default as j}from"./HeroBanner/index.js";import{default as F}from"./AccordionCards/index.js";import{default as b}from"./Graphic/index.js";import{default as k}from"./MediaPlayerBase/index.js";import{default as L}from"./MediaPlayerSticky/index.js";import{default as V}from"./MediaPlayerMulti/index.js";import{default as N}from"./Marquee/index.js";import{default as W}from"./MarqueeReview/index.js";import{default as H}from"./WhyChoose/index.js";import{default as _}from"./Faq/index.js";import{MarqueeItem as U,MarqueeImageContent as Y,MarqueeTextContent as J}from"./Marquee/index.js";import{default as X}from"./MultiLayoutGraphicBlock/index.js";import{default as $}from"./GraphicAttractionBlock/index.js";import{default as te}from"./HeaderNavigation/index.js";import{default as ae}from"./FooterNavigation/index.js";import{default as ie}from"./SearchPage/index.js";import{IPC_SEARCH_PAGE as se,SearchPageTabType as fe}from"./SearchPage/types.js";import{withLayout as ce}from"../shared/Styles.js";import{default as ue}from"./AiuiProvider/index.js";import{default as ne}from"./Tabs/index.js";import{default as ye}from"./CreativeModule/index.js";import{default as Se}from"./GraphicOverlay/index.js";import{default as Ce}from"./Specs/index.js";import{default as Me}from"./TabsGroup/index.js";import{default as Te}from"./Listing/BizProductProvider.js";import{default as Ie}from"./Listing/components/PurchaseBar/index.js";import{default as De}from"./Listing/components/PurchaseBar/ProductActions/index.js";import{default as Ge}from"./Listing/components/ProductCard/index.js";import{default as Ae}from"./Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js";import{default as we}from"./Listing/components/ProductCard/ProductDetail/ProductBenefits/index.js";import{default as Oe}from"./Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js";import{default as qe}from"./Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js";import{default as Ee}from"./Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js";import{default as Re}from"./Listing/components/ProductCard/ProductDetail/ProductOptions/index.js";import{default as Ke}from"./Listing/components/ProductCard/ProductDetail/ProductBundle/index.js";import{default as ze}from"./Listing/components/ProductCard/ProductDetail/ProductCoupon/index.js";import{default as Ye}from"./Listing/components/ProductCard/ProductDetail/ProductBanner/index.js";import{default as Qe}from"./Listing/components/ProductCard/ProductGridBox.js";import{default as Ze}from"./Listing/components/ProductCard/ProductGallery/index.js";import{default as et}from"./Listing/components/ProductCard/ProductDetail/index.js";import{default as rt}from"./Listing/components/ProductCard/ProductSummary/index.js";import{default as ot}from"./Listing/components/ProductCard/ProductDetail/BenefitsTab.js";import{default as pt}from"./Listing/components/PaidShipping/index.js";import{default as ft}from"./Listing/components/ProductCard/ProductPaidShipping/index.js";import{default as ct}from"./GraphicMore/index.js";import{default as ut}from"./Features/index.js";import{default as nt}from"./AplusDesc/index.js";import{default as yt}from"./GiftBox/index.js";import{default as St}from"./SelectStore/index.js";import{default as Ct}from"./DownLoad/index.js";import{default as Mt}from"./FootCharger/index.js";import{default as Tt}from"./BrandCardLink/index.js";import*as Bt from"./IPRedirect/index.js";import{default as jt}from"./WheelLottery/index.js";import{default as Ft}from"./ProductLottery/index.js";import{default as bt}from"./ProductCompare/index.js";import{default as kt}from"./Ksp/index.js";import{default as Lt}from"./ImageTextFeature/index.js";import{default as Vt}from"./FeatureCards/index.js";import{default as Nt}from"./FeaturedBlogPosts/index.js";import{default as Wt}from"./ImageWithText/index.js";import{default as Ht}from"./VideoFeature/index.js";import{default as _t}from"./TabsWithMedia/index.js";import{default as Ut}from"./TabWithImage/index.js";import{default as Jt}from"./FeatureShowcase/index.js";import{default as Xt}from"./ProductHero/index.js";import{default as $t}from"./SpecsComparison/index.js";import{default as tr}from"./MediaSceneSwitcher/index.js";import{default as ar}from"./MediaSceneSwitcherV2/index.js";import{default as ir}from"./ThreeDCarousel/index.js";import{default as sr}from"./ProductNav/index.js";import{default as dr}from"./AnchorNavigation/index.js";import{default as lr}from"./PromotionalBar/index.js";import{default as mr}from"./EventSchedule/index.js";import{default as xr}from"./SecondaryBanner/index.js";import{default as hr}from"./BuyOneGetOneShelf/index.js";import{default as Pr}from"./ActiveShelf/index.js";import{default as gr}from"./MediaShelf/index.js";import{default as vr,CreditsProductCard as Tr}from"./CreditsShelf/index.js";import{default as Ir,SceneProductCard as jr}from"./SceneShelf/index.js";import{default as Fr,SceneShelfV2ProductCard as Gr}from"./SceneShelfV2/index.js";import{default as Ar}from"./SceneShelfV3/index.js";import{default as wr}from"./MediaEndorsement/index.js";import{default as Or}from"./MediaTextOverlay/index.js";import{default as qr}from"./ImageOverlayShelf/index.js";import{default as Er}from"./ImageTextOverlay/index.js";import{default as Rr}from"./MiniCart/index.js";import{default as Kr}from"./MiniCart/CircleProgress.js";import{default as zr,MiniCartDialog as Ur}from"./MiniCart/MiniCartDialog.js";const e={"ipc-accordioncards":"AccordionCards","ipc-aplusdesc":"AplusDesc","ipc-banner":"HeroBanner","ipc-brand-equity":"BrandEquity","ipc-category":"Category","ipc-collection-banner":"CollectionBanner","ipc-collection-shelves":"CollectionShelves","ipc-creativemodule":"CreativeModule","ipc-download":"DownLoad","ipc-evaluate":"Evaluate","ipc-faq":"Faq","ipc-features":"Features","ipc-footcharger":"FootCharger","ipc-ga-block":"GraphicAttractionBlock","ipc-giftbox":"GiftBox","ipc-giftshelf":"GiftShelf","ipc-graphic":"Graphic","ipc-graphicmore":"GraphicMore","ipc-graphicoverlay":"GraphicOverlay","ipc-marquee":"Marquee","ipc-mediaplayerbase":"MediaPlayerBase","ipc-mediaplayermulti":"MediaPlayerMulti","ipc-mediaplayersticky":"MediaPlayerSticky","ipc-member-equity":"MemberEquity","ipc-mlg-block":"MultiLayoutGraphicBlock","ipc-search-page-tabs":"SearchPageBlock","ipc-selectstore":"SelectStore","ipc-shelfdisplay":"ShelfDisplay","ipc-slogan":"Slogan","ipc-spacer":"Spacer","ipc-specs":"Specs","ipc-tabs":"TabsBlock","ipc-text-marquee":"TextMarquee","ipc-title":"Title","ipc-whychoose":"WhyChoose","ipc-product-nav":"ProductNav","ipc-brand-card-link":"BrandCardLink","ipc-ipredirect":"IPRedirect",ksp:"Ksp","ipc-secondary-banner":"SecondaryBanner","ipc-active-shelf":"ActiveShelf","ipc-media-shelf":"MediaShelf","ipc-bogo-shelf":"BuyOneGetOneShelf","ipc-media-endorsement":"MediaEndorsement","ipc-media-scene-switcher-v2":"MediaSceneSwitcherV2","ipc-featured-blog-posts":"FeaturedBlogPosts"};export{F as AccordionCards,Pr as ActiveShelf,d as ActivityMechanism,a as ActivitySchedule,ue as AiuiProvider,dr as AnchorNavigation,nt as AplusDesc,ot as BenefitsTab,Te as BizProductProvider,Tt as BrandCardLink,l as BrandEquity,hr as BuyOneGetOneShelf,B as Category,ye as CreativeModule,Tr as CreditsProductCard,vr as CreditsShelf,Ct as DownLoad,v as Evaluate,mr as EventSchedule,_ as Faq,Vt as FeatureCards,Jt as FeatureShowcase,Nt as FeaturedBlogPosts,ut as Features,Mt as FootCharger,ae as FooterNavigation,yt as GiftBox,i as GiftShelf,s as GiftTierShelf,b as Graphic,$ as GraphicAttractionBlock,ct as GraphicMore,Se as GraphicOverlay,te as HeaderNavigation,j as HeroBanner,se as IPC_SEARCH_PAGE,Bt as IPRedirect,qr as ImageOverlayShelf,Lt as ImageTextFeature,Er as ImageTextOverlay,Wt as ImageWithText,kt as Ksp,N as Marquee,Y as MarqueeImageContent,U as MarqueeItem,W as MarqueeReview,J as MarqueeTextContent,wr as MediaEndorsement,k as MediaPlayerBase,V as MediaPlayerMulti,L as MediaPlayerSticky,tr as MediaSceneSwitcher,ar as MediaSceneSwitcherV2,gr as MediaShelf,Or as MediaTextOverlay,m as MemberEquity,Rr as MiniCart,Kr as MiniCartCircleProgress,zr as MiniCartDialog,Ur as MiniCartDialogComponent,X as MultiLayoutGraphicBlock,e as PAYLOAD_COMPONENT_MAP,pt as PaidShipping,De as ProductActions,Ye as ProductBanner,we as ProductBenefits,Ae as ProductBenefitsTabs,Ke as ProductBundle,Ge as ProductCard,bt as ProductCompare,ze as ProductCoupon,et as ProductDetail,Ee as ProductExchangePurchase,qe as ProductFreeGift,Ze as ProductGallery,Qe as ProductGridBox,Xt as ProductHero,Oe as ProductHighlight,Ft as ProductLottery,sr as ProductNav,Re as ProductOptions,ft as ProductPaidShipping,rt as ProductSummary,lr as PromotionalBar,Ie as PurchaseBar,jr as SceneProductCard,Ir as SceneShelf,Fr as SceneShelfV2,Gr as SceneShelfV2ProductCard,Ar as SceneShelfV3,ie as SearchPage,fe as SearchPageTabType,xr as SecondaryBanner,St as SelectStore,g as ShelfDisplay,x as Slogan,P as Spacer,Ce as Specs,$t as SpecsComparison,Me as TabGroup,Ut as TabWithImage,ne as Tabs,_t as TabsWithMedia,ir as ThreeDCarousel,h as Title,Ht as VideoFeature,jt as WheelLottery,H as WhyChoose,ce as withLayout};
1
+ import{default as a}from"./ActivitySchedule/index.js";import{default as i}from"./GiftShelf/index.js";import{default as s}from"./GiftTierShelf/index.js";import{default as d}from"./ActivityMechanism/index.js";import{default as l}from"./BrandEquity/index.js";import{default as m}from"./MemberEquity/index.js";import{default as x}from"./Slogan/index.js";import{default as h}from"./Title/index.js";import{default as P}from"./Spacer/index.js";import{default as g}from"./ShelfDisplay/index.js";import{default as v}from"./Evaluate/index.js";import{default as B}from"./Category/index.js";import{default as j}from"./HeroBanner/index.js";import{default as D}from"./AccordionCards/index.js";import{default as G}from"./Graphic/index.js";import{default as k}from"./MediaPlayerBase/index.js";import{default as L}from"./MediaPlayerSticky/index.js";import{default as V}from"./MediaPlayerMulti/index.js";import{default as W}from"./Marquee/index.js";import{default as N}from"./MarqueeReview/index.js";import{default as H}from"./WhyChoose/index.js";import{default as _}from"./Faq/index.js";import{MarqueeItem as z,MarqueeImageContent as Y,MarqueeTextContent as J}from"./Marquee/index.js";import{default as X}from"./MultiLayoutGraphicBlock/index.js";import{default as $}from"./GraphicAttractionBlock/index.js";import{default as te}from"./HeaderNavigation/index.js";import{default as ae}from"./FooterNavigation/index.js";import{default as ie}from"./SearchPage/index.js";import{IPC_SEARCH_PAGE as se,SearchPageTabType as fe}from"./SearchPage/types.js";import{withLayout as ce}from"../shared/Styles.js";import{default as ue}from"./AiuiProvider/index.js";import{default as ne}from"./Tabs/index.js";import{default as ye}from"./CreativeModule/index.js";import{default as Se}from"./GraphicOverlay/index.js";import{default as Ce}from"./Specs/index.js";import{default as Me}from"./TabsGroup/index.js";import{default as Te}from"./Listing/BizProductProvider.js";import{default as Ie}from"./Listing/components/PurchaseBar/index.js";import{default as be}from"./Listing/components/PurchaseBar/ProductActions/index.js";import{default as Fe}from"./Listing/components/ProductCard/index.js";import{default as Ae}from"./Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js";import{default as we}from"./Listing/components/ProductCard/ProductDetail/ProductBenefits/index.js";import{default as Oe}from"./Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js";import{default as Ee}from"./Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js";import{default as qe}from"./Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js";import{default as Re}from"./Listing/components/ProductCard/ProductDetail/ProductOptions/index.js";import{default as Ke}from"./Listing/components/ProductCard/ProductDetail/ProductBundle/index.js";import{default as Ue}from"./Listing/components/ProductCard/ProductDetail/ProductCoupon/index.js";import{default as Ye}from"./Listing/components/ProductCard/ProductDetail/ProductBanner/index.js";import{default as Qe}from"./Listing/components/ProductCard/ProductGridBox.js";import{default as Ze}from"./Listing/components/ProductCard/ProductGallery/index.js";import{default as et}from"./Listing/components/ProductCard/ProductDetail/index.js";import{default as rt}from"./Listing/components/ProductCard/ProductSummary/index.js";import{default as ot}from"./Listing/components/ProductCard/ProductDetail/BenefitsTab.js";import{default as pt}from"./Listing/components/PaidShipping/index.js";import{default as ft}from"./Listing/components/ProductCard/ProductPaidShipping/index.js";import{default as ct}from"./GraphicMore/index.js";import{default as ut}from"./Features/index.js";import{default as nt}from"./AplusDesc/index.js";import{default as yt}from"./GiftBox/index.js";import{default as St}from"./SelectStore/index.js";import{default as Ct}from"./DownLoad/index.js";import{default as Mt}from"./FootCharger/index.js";import{default as Tt}from"./BrandCardLink/index.js";import*as Bt from"./IPRedirect/index.js";import{default as jt}from"./WheelLottery/index.js";import{default as Dt}from"./ProductLottery/index.js";import{default as Gt}from"./ProductCompare/index.js";import{default as kt}from"./Ksp/index.js";import{default as Lt}from"./ImageTextFeature/index.js";import{default as Vt}from"./FeatureCards/index.js";import{default as Wt}from"./FeaturedBlogPosts/index.js";import{default as Nt}from"./ImageWithText/index.js";import{default as Ht}from"./VideoFeature/index.js";import{default as _t}from"./TabsWithMedia/index.js";import{default as zt}from"./TabWithImage/index.js";import{default as Jt}from"./FeatureShowcase/index.js";import{default as Xt}from"./ProductHero/index.js";import{default as $t}from"./SpecsComparison/index.js";import{default as tr}from"./MediaSceneSwitcher/index.js";import{default as ar}from"./MediaSceneSwitcherV2/index.js";import{default as ir}from"./ThreeDCarousel/index.js";import{default as sr}from"./ProductNav/index.js";import{default as dr}from"./AnchorNavigation/index.js";import{default as lr}from"./PromotionalBar/index.js";import{default as mr}from"./EventSchedule/index.js";import{default as xr}from"./SecondaryBanner/index.js";import{default as hr}from"./BuyOneGetOneShelf/index.js";import{default as Pr}from"./ActiveShelf/index.js";import{default as gr}from"./MediaShelf/index.js";import{default as vr,CreditsProductCard as Tr}from"./CreditsShelf/index.js";import{default as Ir,SceneProductCard as jr}from"./SceneShelf/index.js";import{default as Dr,SceneShelfV2ProductCard as Fr}from"./SceneShelfV2/index.js";import{default as Ar}from"./SceneShelfV3/index.js";import{default as wr}from"./MediaEndorsement/index.js";import{default as Or}from"./MediaTextOverlay/index.js";import{default as Er}from"./ImageOverlayShelf/index.js";import{default as qr}from"./ImageTextOverlay/index.js";import{default as Rr}from"./MiniCart/index.js";import{default as Kr}from"./MiniCart/CircleProgress.js";import{default as Ur,MiniCartDialog as zr}from"./MiniCart/MiniCartDialog.js";import{default as Jr}from"./WebPushPopup/index.js";import{useEmarsysWebPush as Xr}from"../hooks/useEmarsysWebPush.js";const e={"ipc-accordioncards":"AccordionCards","ipc-aplusdesc":"AplusDesc","ipc-banner":"HeroBanner","ipc-brand-equity":"BrandEquity","ipc-category":"Category","ipc-collection-banner":"CollectionBanner","ipc-collection-shelves":"CollectionShelves","ipc-creativemodule":"CreativeModule","ipc-download":"DownLoad","ipc-evaluate":"Evaluate","ipc-faq":"Faq","ipc-features":"Features","ipc-footcharger":"FootCharger","ipc-ga-block":"GraphicAttractionBlock","ipc-giftbox":"GiftBox","ipc-giftshelf":"GiftShelf","ipc-graphic":"Graphic","ipc-graphicmore":"GraphicMore","ipc-graphicoverlay":"GraphicOverlay","ipc-marquee":"Marquee","ipc-mediaplayerbase":"MediaPlayerBase","ipc-mediaplayermulti":"MediaPlayerMulti","ipc-mediaplayersticky":"MediaPlayerSticky","ipc-member-equity":"MemberEquity","ipc-mlg-block":"MultiLayoutGraphicBlock","ipc-search-page-tabs":"SearchPageBlock","ipc-selectstore":"SelectStore","ipc-shelfdisplay":"ShelfDisplay","ipc-slogan":"Slogan","ipc-spacer":"Spacer","ipc-specs":"Specs","ipc-tabs":"TabsBlock","ipc-text-marquee":"TextMarquee","ipc-title":"Title","ipc-whychoose":"WhyChoose","ipc-product-nav":"ProductNav","ipc-brand-card-link":"BrandCardLink","ipc-ipredirect":"IPRedirect",ksp:"Ksp","ipc-secondary-banner":"SecondaryBanner","ipc-active-shelf":"ActiveShelf","ipc-media-shelf":"MediaShelf","ipc-bogo-shelf":"BuyOneGetOneShelf","ipc-media-endorsement":"MediaEndorsement","ipc-media-scene-switcher-v2":"MediaSceneSwitcherV2","ipc-featured-blog-posts":"FeaturedBlogPosts"};export{D as AccordionCards,Pr as ActiveShelf,d as ActivityMechanism,a as ActivitySchedule,ue as AiuiProvider,dr as AnchorNavigation,nt as AplusDesc,ot as BenefitsTab,Te as BizProductProvider,Tt as BrandCardLink,l as BrandEquity,hr as BuyOneGetOneShelf,B as Category,ye as CreativeModule,Tr as CreditsProductCard,vr as CreditsShelf,Ct as DownLoad,v as Evaluate,mr as EventSchedule,_ as Faq,Vt as FeatureCards,Jt as FeatureShowcase,Wt as FeaturedBlogPosts,ut as Features,Mt as FootCharger,ae as FooterNavigation,yt as GiftBox,i as GiftShelf,s as GiftTierShelf,G as Graphic,$ as GraphicAttractionBlock,ct as GraphicMore,Se as GraphicOverlay,te as HeaderNavigation,j as HeroBanner,se as IPC_SEARCH_PAGE,Bt as IPRedirect,Er as ImageOverlayShelf,Lt as ImageTextFeature,qr as ImageTextOverlay,Nt as ImageWithText,kt as Ksp,W as Marquee,Y as MarqueeImageContent,z as MarqueeItem,N as MarqueeReview,J as MarqueeTextContent,wr as MediaEndorsement,k as MediaPlayerBase,V as MediaPlayerMulti,L as MediaPlayerSticky,tr as MediaSceneSwitcher,ar as MediaSceneSwitcherV2,gr as MediaShelf,Or as MediaTextOverlay,m as MemberEquity,Rr as MiniCart,Kr as MiniCartCircleProgress,Ur as MiniCartDialog,zr as MiniCartDialogComponent,X as MultiLayoutGraphicBlock,e as PAYLOAD_COMPONENT_MAP,pt as PaidShipping,be as ProductActions,Ye as ProductBanner,we as ProductBenefits,Ae as ProductBenefitsTabs,Ke as ProductBundle,Fe as ProductCard,Gt as ProductCompare,Ue as ProductCoupon,et as ProductDetail,qe as ProductExchangePurchase,Ee as ProductFreeGift,Ze as ProductGallery,Qe as ProductGridBox,Xt as ProductHero,Oe as ProductHighlight,Dt as ProductLottery,sr as ProductNav,Re as ProductOptions,ft as ProductPaidShipping,rt as ProductSummary,lr as PromotionalBar,Ie as PurchaseBar,jr as SceneProductCard,Ir as SceneShelf,Dr as SceneShelfV2,Fr as SceneShelfV2ProductCard,Ar as SceneShelfV3,ie as SearchPage,fe as SearchPageTabType,xr as SecondaryBanner,St as SelectStore,g as ShelfDisplay,x as Slogan,P as Spacer,Ce as Specs,$t as SpecsComparison,Me as TabGroup,zt as TabWithImage,ne as Tabs,_t as TabsWithMedia,ir as ThreeDCarousel,h as Title,Ht as VideoFeature,Jr as WebPushPopup,jt as WheelLottery,H as WhyChoose,Xr as useEmarsysWebPush,ce as withLayout};
2
2
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/biz-components/index.ts"],
4
- "sourcesContent": ["export { default as ActivitySchedule } from './ActivitySchedule/index.js'\nexport type { ActivityScheduleProps, ActivityScheduleData, ActivityScheduleItem } from './ActivitySchedule/types.js'\nexport { default as GiftShelf } from './GiftShelf/index.js'\nexport type {\n GiftShelfProps,\n GiftShelfData,\n GiftShelfItem,\n CountdownConfig,\n ResponsiveBackgroundImage as GiftShelfResponsiveBackgroundImage,\n} from './GiftShelf/types.js'\nexport { default as GiftTierShelf } from './GiftTierShelf/index.js'\nexport type { GiftTierShelfProps, GiftTierShelfData, GiftTierItem, GiftTierProduct } from './GiftTierShelf/types.js'\nexport { default as ActivityMechanism } from './ActivityMechanism/index.js'\nexport type {\n ActivityMechanismProps,\n ActivityMechanismItem,\n ActivityMechanismSemanticName,\n ResponsiveBackgroundImage,\n} from './ActivityMechanism/types.js'\nexport { default as BrandEquity } from './BrandEquity/index.js'\nexport { default as MemberEquity } from './MemberEquity/index.js'\nexport { default as Slogan } from './Slogan/index.js'\nexport { default as Title } from './Title/index.js'\nexport { default as Spacer } from './Spacer/index.js'\nexport { default as ShelfDisplay } from './ShelfDisplay/index.js'\nexport { default as Evaluate } from './Evaluate/index.js'\nexport { default as Category } from './Category/index.js'\nexport { default as HeroBanner } from './HeroBanner/index.js'\nexport { default as AccordionCards } from './AccordionCards/index.js'\nexport { default as Graphic } from './Graphic/index.js'\nexport { default as MediaPlayerBase } from './MediaPlayerBase/index.js'\nexport { default as MediaPlayerSticky } from './MediaPlayerSticky/index.js'\nexport { default as MediaPlayerMulti } from './MediaPlayerMulti/index.js'\nexport { default as Marquee } from './Marquee/index.js'\nexport { default as MarqueeReview } from './MarqueeReview/index.js'\nexport type { MarqueeReviewProps, MarqueeReviewData, ReviewItem } from './MarqueeReview/index.js'\nexport { default as WhyChoose } from './WhyChoose/index.js'\nexport { default as Faq } from './Faq/index.js'\nexport { MarqueeItem, MarqueeImageContent, MarqueeTextContent } from './Marquee/index.js'\nexport { default as MultiLayoutGraphicBlock } from './MultiLayoutGraphicBlock/index.js'\nexport type { MultiLayoutGraphicBlockProps } from './MultiLayoutGraphicBlock/index.js'\nexport { default as GraphicAttractionBlock } from './GraphicAttractionBlock/index.js'\nexport type { GraphicAttractionBlockProps } from './GraphicAttractionBlock/index.js'\nexport { default as HeaderNavigation } from './HeaderNavigation/index.js'\nexport { default as FooterNavigation } from './FooterNavigation/index.js'\nexport { default as SearchPage } from './SearchPage/index.js'\nexport type { SearchPageProps } from './SearchPage/types.js'\nexport { IPC_SEARCH_PAGE, SearchPageTabType } from './SearchPage/types.js'\n\nexport { withLayout } from '../shared/Styles.js'\nexport { default as AiuiProvider } from './AiuiProvider/index.js'\nexport { default as Tabs } from './Tabs/index.js'\nexport { default as CreativeModule } from './CreativeModule/index.js'\nexport { default as GraphicOverlay } from './GraphicOverlay/index.js'\nexport { default as Specs } from './Specs/index.js'\nexport { default as TabGroup } from './TabsGroup/index.js'\n\nexport { default as BizProductProvider } from './Listing/BizProductProvider.js'\nexport { default as PurchaseBar } from './Listing/components/PurchaseBar/index.js'\nexport { default as ProductActions } from './Listing/components/PurchaseBar/ProductActions/index.js'\nexport type { ProductActionsProps } from './Listing/components/PurchaseBar/ProductActions/index.js'\nexport { default as ProductCard } from './Listing/components/ProductCard/index.js'\nexport { default as ProductBenefitsTabs } from './Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js'\nexport { default as ProductBenefits } from './Listing/components/ProductCard/ProductDetail/ProductBenefits/index.js'\nexport { default as ProductHighlight } from './Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js'\nexport { default as ProductFreeGift } from './Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js'\nexport { default as ProductExchangePurchase } from './Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js'\nexport { default as ProductOptions } from './Listing/components/ProductCard/ProductDetail/ProductOptions/index.js'\nexport { default as ProductBundle } from './Listing/components/ProductCard/ProductDetail/ProductBundle/index.js'\nexport { default as ProductCoupon } from './Listing/components/ProductCard/ProductDetail/ProductCoupon/index.js'\nexport { default as ProductBanner } from './Listing/components/ProductCard/ProductDetail/ProductBanner/index.js'\nexport { default as ProductGridBox } from './Listing/components/ProductCard/ProductGridBox.js'\nexport { default as ProductGallery } from './Listing/components/ProductCard/ProductGallery/index.js'\nexport { default as ProductDetail } from './Listing/components/ProductCard/ProductDetail/index.js'\nexport { default as ProductSummary } from './Listing/components/ProductCard/ProductSummary/index.js'\nexport { default as BenefitsTab } from './Listing/components/ProductCard/ProductDetail/BenefitsTab.js'\nexport { default as PaidShipping } from './Listing/components/PaidShipping/index.js'\nexport { default as ProductPaidShipping } from './Listing/components/ProductCard/ProductPaidShipping/index.js'\n\nexport { default as GraphicMore } from './GraphicMore/index.js'\nexport { default as Features } from './Features/index.js'\nexport { default as AplusDesc } from './AplusDesc/index.js'\nexport { default as GiftBox } from './GiftBox/index.js'\nexport { default as SelectStore } from './SelectStore/index.js'\nexport { default as DownLoad } from './DownLoad/index.js'\nexport { default as FootCharger } from './FootCharger/index.js'\nexport { default as BrandCardLink } from './BrandCardLink/index.js'\nexport type { BrandCardLinkProps, BrandCardLinkItemProps } from './BrandCardLink/types.js'\n\nexport * as IPRedirect from './IPRedirect/index.js'\n\nexport { default as WheelLottery } from './WheelLottery/index.js'\nexport type {\n WheelLotteryProps,\n WheelLotteryHandle,\n Prize,\n ChanceMethod,\n WinningInfo,\n UserData,\n} from './WheelLottery/types.js'\nexport { default as ProductLottery } from './ProductLottery/index.js'\nexport type { ProductLotteryProps, ProductLotteryHandle, MediaConfig, CtaButtonConfig } from './ProductLottery/types.js'\nexport { default as ProductCompare } from './ProductCompare/index.js'\nexport type { ProductCompareProps, ProductItemData } from './ProductCompare/index.js'\nexport { default as Ksp } from './Ksp/index.js'\nexport type { KspProps, KspData, KspCardItem } from './Ksp/index.js'\nexport { default as ImageTextFeature } from './ImageTextFeature/index.js'\nexport type { ImageTextFeatureProps, ImageTextFeatureItem } from './ImageTextFeature/index.js'\nexport { default as FeatureCards } from './FeatureCards/index.js'\nexport type { FeatureCardsProps, FeatureCardItem } from './FeatureCards/index.js'\nexport { default as FeaturedBlogPosts } from './FeaturedBlogPosts/index.js'\nexport type {\n FeaturedBlogPostsProps,\n FeaturedBlogPostsData,\n FeaturedBlogPostItem,\n FeaturedBlogPostSpan,\n} from './FeaturedBlogPosts/index.js'\nexport { default as ImageWithText } from './ImageWithText/index.js'\nexport type { ImageWithTextProps } from './ImageWithText/index.js'\nexport { default as VideoFeature } from './VideoFeature/index.js'\nexport type { VideoFeatureProps } from './VideoFeature/index.js'\nexport { default as TabsWithMedia } from './TabsWithMedia/index.js'\nexport type { TabsWithMediaProps, TabItem, TimeIndex } from './TabsWithMedia/index.js'\nexport { default as TabWithImage } from './TabWithImage/index.js'\nexport type { TabWithImageProps, TabWithImageDataItem } from './TabWithImage/index.js'\nexport { default as FeatureShowcase } from './FeatureShowcase/index.js'\nexport type { FeatureShowcaseProps, FeatureShowcaseItem } from './FeatureShowcase/index.js'\nexport { default as ProductHero } from './ProductHero/index.js'\nexport type { ProductHeroProps } from './ProductHero/index.js'\nexport { default as SpecsComparison } from './SpecsComparison/index.js'\nexport type {\n SpecsComparisonProps,\n SpecsComparisonMenuItem,\n SpecsComparisonLeftMenuItem,\n} from './SpecsComparison/index.js'\nexport { default as MediaSceneSwitcher } from './MediaSceneSwitcher/index.js'\nexport type { MediaSceneSwitcherProps } from './MediaSceneSwitcher/types.js'\nexport { default as MediaSceneSwitcherV2 } from './MediaSceneSwitcherV2/index.js'\nexport type {\n MediaSceneSwitcherV2Props,\n MediaSceneSwitcherV2Data,\n MediaSceneSwitcherV2Item,\n MediaSceneSwitcherV2Layout,\n} from './MediaSceneSwitcherV2/index.js'\nexport { default as ThreeDCarousel } from './ThreeDCarousel/index.js'\nexport type { ThreeDCarouselProps } from './ThreeDCarousel/index.js'\nexport { default as ProductNav } from './ProductNav/index.js'\nexport type { ProductNavProps, TabLink, AnchorItem, BuyButton } from './ProductNav/index.js'\nexport { default as AnchorNavigation } from './AnchorNavigation/index.js'\nexport { default as PromotionalBar } from './PromotionalBar/index.js'\nexport { default as EventSchedule } from './EventSchedule/index.js'\nexport { default as SecondaryBanner } from './SecondaryBanner/index.js'\nexport { default as BuyOneGetOneShelf } from './BuyOneGetOneShelf/index.js'\nexport { default as ActiveShelf } from './ActiveShelf/index.js'\nexport { default as MediaShelf } from './MediaShelf/index.js'\nexport { default as CreditsShelf, CreditsProductCard } from './CreditsShelf/index.js'\nexport type {\n CreditsShelfSemanticName,\n CreditsProductCardData,\n CopyConfig as CreditsShelfCopyConfig,\n ButtonFunctionType as CreditsShelfButtonFunctionType,\n} from './CreditsShelf/index.js'\nexport { default as SceneShelf, SceneProductCard } from './SceneShelf/index.js'\nexport type { SceneShelfSemanticName, SceneProductCardData, SceneProductCardSemanticName } from './SceneShelf/index.js'\nexport { default as SceneShelfV2, SceneShelfV2ProductCard } from './SceneShelfV2/index.js'\nexport type {\n SceneShelfV2SemanticName,\n SceneShelfV2Data,\n SceneShelfV2Product,\n SceneShelfV2Props,\n} from './SceneShelfV2/index.js'\nexport { default as SceneShelfV3 } from './SceneShelfV3/index.js'\nexport type { SceneShelfV3Data, SceneShelfV3Props, ProductTab as SceneShelfV3ProductTab } from './SceneShelfV3/index.js'\nexport type {\n SceneShelfV3SemanticName,\n ProductCardData as SceneShelfV3ProductCardData,\n} from './SceneShelfV3/ProductCard.js'\n\nexport { default as MediaEndorsement } from './MediaEndorsement/index.js'\nexport type {\n MediaEndorsementProps,\n MediaEndorsementData,\n MediaEndorsementItem,\n MediaEndorsementSemanticName,\n} from './MediaEndorsement/index.js'\n\nexport { default as MediaTextOverlay } from './MediaTextOverlay/index.js'\nexport type {\n MediaTextOverlayProps,\n MediaTextOverlayData,\n MediaTextOverlayItem,\n MediaTextOverlaySemanticName,\n ResponsiveMedia,\n} from './MediaTextOverlay/index.js'\n\n// Copy configuration types and defaults\nexport type {\n CopyConfig as MediaShelfCopyConfig,\n ButtonFunctionType as MediaShelfButtonFunctionType,\n} from './MediaShelf/types.js'\nexport type { CopyConfig as ActiveShelfCopyConfig, ButtonFunctionType } from './ActiveShelf/types.js'\n\nexport {\n default as ImageOverlayShelf,\n type ButtonFunctionType as ImageOverlayShelfButtonFunctionType,\n} from './ImageOverlayShelf/index.js'\n\nexport { default as ImageTextOverlay } from './ImageTextOverlay/index.js'\nexport type {\n ImageTextOverlayProps,\n ImageTextOverlayData,\n ImageTextOverlayItem,\n ImageTextOverlaySemanticName,\n ImageTextOverlayBackgroundImage,\n} from './ImageTextOverlay/types.js'\n\n// MiniCart \u7EC4\u4EF6\u53CA\u7C7B\u578B\u5BFC\u51FA\nexport { default as MiniCart } from './MiniCart/index.js'\nexport type { Cart, CartLineItem, MiniCartData, MiniCartProps, CircleProgressConfig } from './MiniCart/index.js'\nexport { default as MiniCartCircleProgress } from './MiniCart/CircleProgress.js'\nexport type { CircleProgressProps as MiniCartCircleProgressProps } from './MiniCart/CircleProgress.js'\nexport { default as MiniCartDialog, MiniCartDialog as MiniCartDialogComponent } from './MiniCart/MiniCartDialog.js'\nexport type {\n MiniCartDialogProps,\n MiniCartDialogCopy,\n MiniCartDialogSemanticName,\n CartData,\n} from './MiniCart/MiniCartDialog.js'\n\n/**\n * \u7EC4\u4EF6\u6620\u5C04\u5BF9\u8C61\n */\n\nexport const PAYLOAD_COMPONENT_MAP = {\n 'ipc-accordioncards': 'AccordionCards',\n 'ipc-aplusdesc': 'AplusDesc',\n 'ipc-banner': 'HeroBanner',\n 'ipc-brand-equity': 'BrandEquity',\n 'ipc-category': 'Category',\n 'ipc-collection-banner': 'CollectionBanner',\n 'ipc-collection-shelves': 'CollectionShelves',\n 'ipc-creativemodule': 'CreativeModule',\n 'ipc-download': 'DownLoad',\n 'ipc-evaluate': 'Evaluate',\n 'ipc-faq': 'Faq',\n 'ipc-features': 'Features',\n 'ipc-footcharger': 'FootCharger',\n 'ipc-ga-block': 'GraphicAttractionBlock',\n 'ipc-giftbox': 'GiftBox',\n 'ipc-giftshelf': 'GiftShelf',\n 'ipc-graphic': 'Graphic',\n 'ipc-graphicmore': 'GraphicMore',\n 'ipc-graphicoverlay': 'GraphicOverlay',\n 'ipc-marquee': 'Marquee',\n 'ipc-mediaplayerbase': 'MediaPlayerBase',\n 'ipc-mediaplayermulti': 'MediaPlayerMulti',\n 'ipc-mediaplayersticky': 'MediaPlayerSticky',\n 'ipc-member-equity': 'MemberEquity',\n 'ipc-mlg-block': 'MultiLayoutGraphicBlock',\n 'ipc-search-page-tabs': 'SearchPageBlock',\n 'ipc-selectstore': 'SelectStore',\n 'ipc-shelfdisplay': 'ShelfDisplay',\n 'ipc-slogan': 'Slogan',\n 'ipc-spacer': 'Spacer',\n 'ipc-specs': 'Specs',\n 'ipc-tabs': 'TabsBlock',\n 'ipc-text-marquee': 'TextMarquee',\n 'ipc-title': 'Title',\n 'ipc-whychoose': 'WhyChoose',\n 'ipc-product-nav': 'ProductNav',\n 'ipc-brand-card-link': 'BrandCardLink',\n 'ipc-ipredirect': 'IPRedirect',\n ksp: 'Ksp',\n 'ipc-secondary-banner': 'SecondaryBanner',\n /**\n * \u6D3B\u52A8\u8D27\u67B6\n */\n 'ipc-active-shelf': 'ActiveShelf',\n 'ipc-media-shelf': 'MediaShelf',\n /**\n * \u6D3B\u52A8\u4E70\u8D60\u8D27\u67B6\n */\n 'ipc-bogo-shelf': 'BuyOneGetOneShelf',\n 'ipc-media-endorsement': 'MediaEndorsement',\n 'ipc-media-scene-switcher-v2': 'MediaSceneSwitcherV2',\n 'ipc-featured-blog-posts': 'FeaturedBlogPosts',\n}\n"],
5
- "mappings": "AAAA,OAAoB,WAAXA,MAAmC,8BAE5C,OAAoB,WAAXA,MAA4B,uBAQrC,OAAoB,WAAXA,MAAgC,2BAEzC,OAAoB,WAAXA,MAAoC,+BAO7C,OAAoB,WAAXA,MAA8B,yBACvC,OAAoB,WAAXA,MAA+B,0BACxC,OAAoB,WAAXA,MAAyB,oBAClC,OAAoB,WAAXA,MAAwB,mBACjC,OAAoB,WAAXA,MAAyB,oBAClC,OAAoB,WAAXA,MAA+B,0BACxC,OAAoB,WAAXA,MAA2B,sBACpC,OAAoB,WAAXA,MAA2B,sBACpC,OAAoB,WAAXA,MAA6B,wBACtC,OAAoB,WAAXA,MAAiC,4BAC1C,OAAoB,WAAXA,MAA0B,qBACnC,OAAoB,WAAXA,MAAkC,6BAC3C,OAAoB,WAAXA,MAAoC,+BAC7C,OAAoB,WAAXA,MAAmC,8BAC5C,OAAoB,WAAXA,MAA0B,qBACnC,OAAoB,WAAXA,MAAgC,2BAEzC,OAAoB,WAAXA,MAA4B,uBACrC,OAAoB,WAAXA,MAAsB,iBAC/B,OAAS,eAAAC,EAAa,uBAAAC,EAAqB,sBAAAC,MAA0B,qBACrE,OAAoB,WAAXH,MAA0C,qCAEn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B,oBAC1B,qBAAsB,iBACtB,eAAgB,WAChB,eAAgB,WAChB,UAAW,MACX,eAAgB,WAChB,kBAAmB,cACnB,eAAgB,yBAChB,cAAe,UACf,gBAAiB,YACjB,cAAe,UACf,kBAAmB,cACnB,qBAAsB,iBACtB,cAAe,UACf,sBAAuB,kBACvB,uBAAwB,mBACxB,wBAAyB,oBACzB,oBAAqB,eACrB,gBAAiB,0BACjB,uBAAwB,kBACxB,kBAAmB,cACnB,mBAAoB,eACpB,aAAc,SACd,aAAc,SACd,YAAa,QACb,WAAY,YACZ,mBAAoB,cACpB,YAAa,QACb,gBAAiB,YACjB,kBAAmB,aACnB,sBAAuB,gBACvB,iBAAkB,aAClB,IAAK,MACL,uBAAwB,kBAIxB,mBAAoB,cACpB,kBAAmB,aAInB,iBAAkB,oBAClB,wBAAyB,mBACzB,8BAA+B,uBAC/B,0BAA2B,mBAC7B",
6
- "names": ["default", "MarqueeItem", "MarqueeImageContent", "MarqueeTextContent", "IPC_SEARCH_PAGE", "SearchPageTabType", "withLayout", "IPRedirect", "CreditsProductCard", "SceneProductCard", "SceneShelfV2ProductCard", "MiniCartDialog", "PAYLOAD_COMPONENT_MAP"]
4
+ "sourcesContent": ["export { default as ActivitySchedule } from './ActivitySchedule/index.js'\nexport type { ActivityScheduleProps, ActivityScheduleData, ActivityScheduleItem } from './ActivitySchedule/types.js'\nexport { default as GiftShelf } from './GiftShelf/index.js'\nexport type {\n GiftShelfProps,\n GiftShelfData,\n GiftShelfItem,\n CountdownConfig,\n ResponsiveBackgroundImage as GiftShelfResponsiveBackgroundImage,\n} from './GiftShelf/types.js'\nexport { default as GiftTierShelf } from './GiftTierShelf/index.js'\nexport type { GiftTierShelfProps, GiftTierShelfData, GiftTierItem, GiftTierProduct } from './GiftTierShelf/types.js'\nexport { default as ActivityMechanism } from './ActivityMechanism/index.js'\nexport type {\n ActivityMechanismProps,\n ActivityMechanismItem,\n ActivityMechanismSemanticName,\n ResponsiveBackgroundImage,\n} from './ActivityMechanism/types.js'\nexport { default as BrandEquity } from './BrandEquity/index.js'\nexport { default as MemberEquity } from './MemberEquity/index.js'\nexport { default as Slogan } from './Slogan/index.js'\nexport { default as Title } from './Title/index.js'\nexport { default as Spacer } from './Spacer/index.js'\nexport { default as ShelfDisplay } from './ShelfDisplay/index.js'\nexport { default as Evaluate } from './Evaluate/index.js'\nexport { default as Category } from './Category/index.js'\nexport { default as HeroBanner } from './HeroBanner/index.js'\nexport { default as AccordionCards } from './AccordionCards/index.js'\nexport { default as Graphic } from './Graphic/index.js'\nexport { default as MediaPlayerBase } from './MediaPlayerBase/index.js'\nexport { default as MediaPlayerSticky } from './MediaPlayerSticky/index.js'\nexport { default as MediaPlayerMulti } from './MediaPlayerMulti/index.js'\nexport { default as Marquee } from './Marquee/index.js'\nexport { default as MarqueeReview } from './MarqueeReview/index.js'\nexport type { MarqueeReviewProps, MarqueeReviewData, ReviewItem } from './MarqueeReview/index.js'\nexport { default as WhyChoose } from './WhyChoose/index.js'\nexport { default as Faq } from './Faq/index.js'\nexport { MarqueeItem, MarqueeImageContent, MarqueeTextContent } from './Marquee/index.js'\nexport { default as MultiLayoutGraphicBlock } from './MultiLayoutGraphicBlock/index.js'\nexport type { MultiLayoutGraphicBlockProps } from './MultiLayoutGraphicBlock/index.js'\nexport { default as GraphicAttractionBlock } from './GraphicAttractionBlock/index.js'\nexport type { GraphicAttractionBlockProps } from './GraphicAttractionBlock/index.js'\nexport { default as HeaderNavigation } from './HeaderNavigation/index.js'\nexport { default as FooterNavigation } from './FooterNavigation/index.js'\nexport { default as SearchPage } from './SearchPage/index.js'\nexport type { SearchPageProps } from './SearchPage/types.js'\nexport { IPC_SEARCH_PAGE, SearchPageTabType } from './SearchPage/types.js'\n\nexport { withLayout } from '../shared/Styles.js'\nexport { default as AiuiProvider } from './AiuiProvider/index.js'\nexport { default as Tabs } from './Tabs/index.js'\nexport { default as CreativeModule } from './CreativeModule/index.js'\nexport { default as GraphicOverlay } from './GraphicOverlay/index.js'\nexport { default as Specs } from './Specs/index.js'\nexport { default as TabGroup } from './TabsGroup/index.js'\n\nexport { default as BizProductProvider } from './Listing/BizProductProvider.js'\nexport { default as PurchaseBar } from './Listing/components/PurchaseBar/index.js'\nexport { default as ProductActions } from './Listing/components/PurchaseBar/ProductActions/index.js'\nexport type { ProductActionsProps } from './Listing/components/PurchaseBar/ProductActions/index.js'\nexport { default as ProductCard } from './Listing/components/ProductCard/index.js'\nexport { default as ProductBenefitsTabs } from './Listing/components/ProductCard/ProductDetail/ProductBenefitsTabs/index.js'\nexport { default as ProductBenefits } from './Listing/components/ProductCard/ProductDetail/ProductBenefits/index.js'\nexport { default as ProductHighlight } from './Listing/components/ProductCard/ProductDetail/ProductHighlight/index.js'\nexport { default as ProductFreeGift } from './Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.js'\nexport { default as ProductExchangePurchase } from './Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.js'\nexport { default as ProductOptions } from './Listing/components/ProductCard/ProductDetail/ProductOptions/index.js'\nexport { default as ProductBundle } from './Listing/components/ProductCard/ProductDetail/ProductBundle/index.js'\nexport { default as ProductCoupon } from './Listing/components/ProductCard/ProductDetail/ProductCoupon/index.js'\nexport { default as ProductBanner } from './Listing/components/ProductCard/ProductDetail/ProductBanner/index.js'\nexport { default as ProductGridBox } from './Listing/components/ProductCard/ProductGridBox.js'\nexport { default as ProductGallery } from './Listing/components/ProductCard/ProductGallery/index.js'\nexport { default as ProductDetail } from './Listing/components/ProductCard/ProductDetail/index.js'\nexport { default as ProductSummary } from './Listing/components/ProductCard/ProductSummary/index.js'\nexport { default as BenefitsTab } from './Listing/components/ProductCard/ProductDetail/BenefitsTab.js'\nexport { default as PaidShipping } from './Listing/components/PaidShipping/index.js'\nexport { default as ProductPaidShipping } from './Listing/components/ProductCard/ProductPaidShipping/index.js'\n\nexport { default as GraphicMore } from './GraphicMore/index.js'\nexport { default as Features } from './Features/index.js'\nexport { default as AplusDesc } from './AplusDesc/index.js'\nexport { default as GiftBox } from './GiftBox/index.js'\nexport { default as SelectStore } from './SelectStore/index.js'\nexport { default as DownLoad } from './DownLoad/index.js'\nexport { default as FootCharger } from './FootCharger/index.js'\nexport { default as BrandCardLink } from './BrandCardLink/index.js'\nexport type { BrandCardLinkProps, BrandCardLinkItemProps } from './BrandCardLink/types.js'\n\nexport * as IPRedirect from './IPRedirect/index.js'\n\nexport { default as WheelLottery } from './WheelLottery/index.js'\nexport type {\n WheelLotteryProps,\n WheelLotteryHandle,\n Prize,\n ChanceMethod,\n WinningInfo,\n UserData,\n} from './WheelLottery/types.js'\nexport { default as ProductLottery } from './ProductLottery/index.js'\nexport type { ProductLotteryProps, ProductLotteryHandle, MediaConfig, CtaButtonConfig } from './ProductLottery/types.js'\nexport { default as ProductCompare } from './ProductCompare/index.js'\nexport type { ProductCompareProps, ProductItemData } from './ProductCompare/index.js'\nexport { default as Ksp } from './Ksp/index.js'\nexport type { KspProps, KspData, KspCardItem } from './Ksp/index.js'\nexport { default as ImageTextFeature } from './ImageTextFeature/index.js'\nexport type { ImageTextFeatureProps, ImageTextFeatureItem } from './ImageTextFeature/index.js'\nexport { default as FeatureCards } from './FeatureCards/index.js'\nexport type { FeatureCardsProps, FeatureCardItem } from './FeatureCards/index.js'\nexport { default as FeaturedBlogPosts } from './FeaturedBlogPosts/index.js'\nexport type {\n FeaturedBlogPostsProps,\n FeaturedBlogPostsData,\n FeaturedBlogPostItem,\n FeaturedBlogPostSpan,\n} from './FeaturedBlogPosts/index.js'\nexport { default as ImageWithText } from './ImageWithText/index.js'\nexport type { ImageWithTextProps } from './ImageWithText/index.js'\nexport { default as VideoFeature } from './VideoFeature/index.js'\nexport type { VideoFeatureProps } from './VideoFeature/index.js'\nexport { default as TabsWithMedia } from './TabsWithMedia/index.js'\nexport type { TabsWithMediaProps, TabItem, TimeIndex } from './TabsWithMedia/index.js'\nexport { default as TabWithImage } from './TabWithImage/index.js'\nexport type { TabWithImageProps, TabWithImageDataItem } from './TabWithImage/index.js'\nexport { default as FeatureShowcase } from './FeatureShowcase/index.js'\nexport type { FeatureShowcaseProps, FeatureShowcaseItem } from './FeatureShowcase/index.js'\nexport { default as ProductHero } from './ProductHero/index.js'\nexport type { ProductHeroProps } from './ProductHero/index.js'\nexport { default as SpecsComparison } from './SpecsComparison/index.js'\nexport type {\n SpecsComparisonProps,\n SpecsComparisonMenuItem,\n SpecsComparisonLeftMenuItem,\n} from './SpecsComparison/index.js'\nexport { default as MediaSceneSwitcher } from './MediaSceneSwitcher/index.js'\nexport type { MediaSceneSwitcherProps } from './MediaSceneSwitcher/types.js'\nexport { default as MediaSceneSwitcherV2 } from './MediaSceneSwitcherV2/index.js'\nexport type {\n MediaSceneSwitcherV2Props,\n MediaSceneSwitcherV2Data,\n MediaSceneSwitcherV2Item,\n MediaSceneSwitcherV2Layout,\n} from './MediaSceneSwitcherV2/index.js'\nexport { default as ThreeDCarousel } from './ThreeDCarousel/index.js'\nexport type { ThreeDCarouselProps } from './ThreeDCarousel/index.js'\nexport { default as ProductNav } from './ProductNav/index.js'\nexport type { ProductNavProps, TabLink, AnchorItem, BuyButton } from './ProductNav/index.js'\nexport { default as AnchorNavigation } from './AnchorNavigation/index.js'\nexport { default as PromotionalBar } from './PromotionalBar/index.js'\nexport { default as EventSchedule } from './EventSchedule/index.js'\nexport { default as SecondaryBanner } from './SecondaryBanner/index.js'\nexport { default as BuyOneGetOneShelf } from './BuyOneGetOneShelf/index.js'\nexport { default as ActiveShelf } from './ActiveShelf/index.js'\nexport { default as MediaShelf } from './MediaShelf/index.js'\nexport { default as CreditsShelf, CreditsProductCard } from './CreditsShelf/index.js'\nexport type {\n CreditsShelfSemanticName,\n CreditsProductCardData,\n CopyConfig as CreditsShelfCopyConfig,\n ButtonFunctionType as CreditsShelfButtonFunctionType,\n} from './CreditsShelf/index.js'\nexport { default as SceneShelf, SceneProductCard } from './SceneShelf/index.js'\nexport type { SceneShelfSemanticName, SceneProductCardData, SceneProductCardSemanticName } from './SceneShelf/index.js'\nexport { default as SceneShelfV2, SceneShelfV2ProductCard } from './SceneShelfV2/index.js'\nexport type {\n SceneShelfV2SemanticName,\n SceneShelfV2Data,\n SceneShelfV2Product,\n SceneShelfV2Props,\n} from './SceneShelfV2/index.js'\nexport { default as SceneShelfV3 } from './SceneShelfV3/index.js'\nexport type { SceneShelfV3Data, SceneShelfV3Props, ProductTab as SceneShelfV3ProductTab } from './SceneShelfV3/index.js'\nexport type {\n SceneShelfV3SemanticName,\n ProductCardData as SceneShelfV3ProductCardData,\n} from './SceneShelfV3/ProductCard.js'\n\nexport { default as MediaEndorsement } from './MediaEndorsement/index.js'\nexport type {\n MediaEndorsementProps,\n MediaEndorsementData,\n MediaEndorsementItem,\n MediaEndorsementSemanticName,\n} from './MediaEndorsement/index.js'\n\nexport { default as MediaTextOverlay } from './MediaTextOverlay/index.js'\nexport type {\n MediaTextOverlayProps,\n MediaTextOverlayData,\n MediaTextOverlayItem,\n MediaTextOverlaySemanticName,\n ResponsiveMedia,\n} from './MediaTextOverlay/index.js'\n\n// Copy configuration types and defaults\nexport type {\n CopyConfig as MediaShelfCopyConfig,\n ButtonFunctionType as MediaShelfButtonFunctionType,\n} from './MediaShelf/types.js'\nexport type { CopyConfig as ActiveShelfCopyConfig, ButtonFunctionType } from './ActiveShelf/types.js'\n\nexport {\n default as ImageOverlayShelf,\n type ButtonFunctionType as ImageOverlayShelfButtonFunctionType,\n} from './ImageOverlayShelf/index.js'\n\nexport { default as ImageTextOverlay } from './ImageTextOverlay/index.js'\nexport type {\n ImageTextOverlayProps,\n ImageTextOverlayData,\n ImageTextOverlayItem,\n ImageTextOverlaySemanticName,\n ImageTextOverlayBackgroundImage,\n} from './ImageTextOverlay/types.js'\n\n// MiniCart \u7EC4\u4EF6\u53CA\u7C7B\u578B\u5BFC\u51FA\nexport { default as MiniCart } from './MiniCart/index.js'\nexport type { Cart, CartLineItem, MiniCartData, MiniCartProps, CircleProgressConfig } from './MiniCart/index.js'\nexport { default as MiniCartCircleProgress } from './MiniCart/CircleProgress.js'\nexport type { CircleProgressProps as MiniCartCircleProgressProps } from './MiniCart/CircleProgress.js'\nexport { default as MiniCartDialog, MiniCartDialog as MiniCartDialogComponent } from './MiniCart/MiniCartDialog.js'\nexport type {\n MiniCartDialogProps,\n MiniCartDialogCopy,\n MiniCartDialogSemanticName,\n CartData,\n} from './MiniCart/MiniCartDialog.js'\n\n// \u2500\u2500\u2500 Web Push \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\nexport { default as WebPushPopup } from './WebPushPopup/index.js'\nexport type { WebPushPopupProps } from './WebPushPopup/index.js'\nexport { useEmarsysWebPush } from '../hooks/useEmarsysWebPush.js'\nexport type {\n UseEmarsysWebPushOptions,\n UseEmarsysWebPushReturn,\n EmarsysContactInfo,\n EmarsysInitConfig,\n} from '../hooks/useEmarsysWebPush.js'\n\n/**\n * \u7EC4\u4EF6\u6620\u5C04\u5BF9\u8C61\n */\n\nexport const PAYLOAD_COMPONENT_MAP = {\n 'ipc-accordioncards': 'AccordionCards',\n 'ipc-aplusdesc': 'AplusDesc',\n 'ipc-banner': 'HeroBanner',\n 'ipc-brand-equity': 'BrandEquity',\n 'ipc-category': 'Category',\n 'ipc-collection-banner': 'CollectionBanner',\n 'ipc-collection-shelves': 'CollectionShelves',\n 'ipc-creativemodule': 'CreativeModule',\n 'ipc-download': 'DownLoad',\n 'ipc-evaluate': 'Evaluate',\n 'ipc-faq': 'Faq',\n 'ipc-features': 'Features',\n 'ipc-footcharger': 'FootCharger',\n 'ipc-ga-block': 'GraphicAttractionBlock',\n 'ipc-giftbox': 'GiftBox',\n 'ipc-giftshelf': 'GiftShelf',\n 'ipc-graphic': 'Graphic',\n 'ipc-graphicmore': 'GraphicMore',\n 'ipc-graphicoverlay': 'GraphicOverlay',\n 'ipc-marquee': 'Marquee',\n 'ipc-mediaplayerbase': 'MediaPlayerBase',\n 'ipc-mediaplayermulti': 'MediaPlayerMulti',\n 'ipc-mediaplayersticky': 'MediaPlayerSticky',\n 'ipc-member-equity': 'MemberEquity',\n 'ipc-mlg-block': 'MultiLayoutGraphicBlock',\n 'ipc-search-page-tabs': 'SearchPageBlock',\n 'ipc-selectstore': 'SelectStore',\n 'ipc-shelfdisplay': 'ShelfDisplay',\n 'ipc-slogan': 'Slogan',\n 'ipc-spacer': 'Spacer',\n 'ipc-specs': 'Specs',\n 'ipc-tabs': 'TabsBlock',\n 'ipc-text-marquee': 'TextMarquee',\n 'ipc-title': 'Title',\n 'ipc-whychoose': 'WhyChoose',\n 'ipc-product-nav': 'ProductNav',\n 'ipc-brand-card-link': 'BrandCardLink',\n 'ipc-ipredirect': 'IPRedirect',\n ksp: 'Ksp',\n 'ipc-secondary-banner': 'SecondaryBanner',\n /**\n * \u6D3B\u52A8\u8D27\u67B6\n */\n 'ipc-active-shelf': 'ActiveShelf',\n 'ipc-media-shelf': 'MediaShelf',\n /**\n * \u6D3B\u52A8\u4E70\u8D60\u8D27\u67B6\n */\n 'ipc-bogo-shelf': 'BuyOneGetOneShelf',\n 'ipc-media-endorsement': 'MediaEndorsement',\n 'ipc-media-scene-switcher-v2': 'MediaSceneSwitcherV2',\n 'ipc-featured-blog-posts': 'FeaturedBlogPosts',\n}\n"],
5
+ "mappings": "AAAA,OAAoB,WAAXA,MAAmC,8BAE5C,OAAoB,WAAXA,MAA4B,uBAQrC,OAAoB,WAAXA,MAAgC,2BAEzC,OAAoB,WAAXA,MAAoC,+BAO7C,OAAoB,WAAXA,MAA8B,yBACvC,OAAoB,WAAXA,MAA+B,0BACxC,OAAoB,WAAXA,MAA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BACvC,OAAoB,WAAXA,OAA6B,wBACtC,OAAoB,WAAXA,GAAyB,sBAAAQ,OAA0B,0BAO5D,OAAoB,WAAXR,GAAuB,oBAAAS,OAAwB,wBAExD,OAAoB,WAAXT,GAAyB,2BAAAU,OAA+B,0BAOjE,OAAoB,WAAXV,OAA+B,0BAOxC,OAAoB,WAAXA,OAAmC,8BAQ5C,OAAoB,WAAXA,OAAmC,8BAgB5C,OACa,WAAXA,OAEK,+BAEP,OAAoB,WAAXA,OAAmC,8BAU5C,OAAoB,WAAXA,OAA2B,sBAEpC,OAAoB,WAAXA,OAAyC,+BAElD,OAAoB,WAAXA,GAA6C,kBAAlBW,OAAiD,+BASrF,OAAoB,WAAXX,OAA+B,0BAExC,OAAS,qBAAAY,OAAyB,gCAY3B,MAAMC,EAAwB,CACnC,qBAAsB,iBACtB,gBAAiB,YACjB,aAAc,aACd,mBAAoB,cACpB,eAAgB,WAChB,wBAAyB,mBACzB,yBAA0B,oBAC1B,qBAAsB,iBACtB,eAAgB,WAChB,eAAgB,WAChB,UAAW,MACX,eAAgB,WAChB,kBAAmB,cACnB,eAAgB,yBAChB,cAAe,UACf,gBAAiB,YACjB,cAAe,UACf,kBAAmB,cACnB,qBAAsB,iBACtB,cAAe,UACf,sBAAuB,kBACvB,uBAAwB,mBACxB,wBAAyB,oBACzB,oBAAqB,eACrB,gBAAiB,0BACjB,uBAAwB,kBACxB,kBAAmB,cACnB,mBAAoB,eACpB,aAAc,SACd,aAAc,SACd,YAAa,QACb,WAAY,YACZ,mBAAoB,cACpB,YAAa,QACb,gBAAiB,YACjB,kBAAmB,aACnB,sBAAuB,gBACvB,iBAAkB,aAClB,IAAK,MACL,uBAAwB,kBAIxB,mBAAoB,cACpB,kBAAmB,aAInB,iBAAkB,oBAClB,wBAAyB,mBACzB,8BAA+B,uBAC/B,0BAA2B,mBAC7B",
6
+ "names": ["default", "MarqueeItem", "MarqueeImageContent", "MarqueeTextContent", "IPC_SEARCH_PAGE", "SearchPageTabType", "withLayout", "IPRedirect", "CreditsProductCard", "SceneProductCard", "SceneShelfV2ProductCard", "MiniCartDialog", "useEmarsysWebPush", "PAYLOAD_COMPONENT_MAP"]
7
7
  }
@@ -0,0 +1,111 @@
1
+ export interface EmarsysContactInfo {
2
+ /** Emarsys 联系人字段 ID(如 10372) */
3
+ fieldId: number;
4
+ /** 字段值(如用户唯一标识) */
5
+ fieldValue: string;
6
+ }
7
+ export interface EmarsysInitConfig {
8
+ /** Emarsys Domain Code,从后台获取 */
9
+ applicationCode: string;
10
+ /** macOS Safari 16+ 使用 VAPID 替代 APNS */
11
+ enableMacSafariVapid?: boolean;
12
+ /** 默认推送通知标题 */
13
+ defaultNotificationTitle?: string;
14
+ /** 默认推送通知图标 URL */
15
+ defaultNotificationIcon?: string;
16
+ /** 是否自动触发浏览器订阅弹窗,强烈建议设为 false */
17
+ autoSubscribe?: boolean;
18
+ /** 开发阶段开启 SDK 日志 */
19
+ enableLogging?: boolean;
20
+ serviceWorker: {
21
+ /** Service Worker 文件路径(需放在网站根目录) */
22
+ url: string;
23
+ /** VAPID 公钥(Base64 URL-safe 编码) */
24
+ applicationServerPublicKey: string;
25
+ };
26
+ }
27
+ type EmarsysSdkEventName = 'onReady' | 'onSubscribe' | 'onUnsubscribe' | 'onPermissionPrompt' | 'onPermissionGranted' | 'onPermissionDenied' | 'onSWInitError';
28
+ type EmarsysSdkCommand = ['init', EmarsysInitConfig] | [EmarsysSdkEventName, () => void];
29
+ interface EmarsysSdkApi {
30
+ subscribe: () => void;
31
+ unsubscribe: () => void;
32
+ login: (contactInfo: EmarsysContactInfo) => Promise<boolean>;
33
+ logout: () => Promise<boolean>;
34
+ isSubscribed: () => Promise<boolean>;
35
+ isRegistered: () => boolean;
36
+ customEvent: (eventName: string, payload?: Record<string, unknown>) => Promise<boolean>;
37
+ push: (command: EmarsysSdkCommand | ((sdk: EmarsysSdkApi) => void)) => void;
38
+ }
39
+ declare global {
40
+ interface Window {
41
+ WebEmarsysSdk: EmarsysSdkApi | (EmarsysSdkCommand | ((sdk: EmarsysSdkApi) => void))[];
42
+ }
43
+ }
44
+ export interface UseEmarsysWebPushOptions {
45
+ /** Emarsys Domain Code */
46
+ applicationCode: string;
47
+ /** VAPID 公钥 */
48
+ applicationServerPublicKey: string;
49
+ /** Service Worker 路径,默认 'service-worker.js'(不含前导斜杠) */
50
+ serviceWorkerUrl?: string;
51
+ /** 默认通知标题 */
52
+ defaultNotificationTitle?: string;
53
+ /** 默认通知图标 URL */
54
+ defaultNotificationIcon?: string;
55
+ /** 联系人主键字段 ID(由 Emarsys 后台配置) */
56
+ fieldId: number;
57
+ /**
58
+ * 当前用户的联系人标识(如 hashed email / customer ID)。
59
+ * null 表示未登录的匿名访客。
60
+ */
61
+ contactValue: string | null;
62
+ /** 是否开启调试日志,默认 false */
63
+ enableLogging?: boolean;
64
+ /**
65
+ * 点击"稍后"后的弹窗冷却天数,默认 7 天。
66
+ * 冷却期间不再展示自定义弹窗。
67
+ */
68
+ dismissCooldownDays?: number;
69
+ /**
70
+ * SDK 是否已通过外部 <Script> 标签加载完毕。
71
+ * 传入此 flag 以便 hook 在正确时机初始化。
72
+ * 默认 true(假设 SDK 已经加载)。
73
+ */
74
+ sdkLoaded?: boolean;
75
+ }
76
+ export interface UseEmarsysWebPushReturn {
77
+ /** 手动触发浏览器原生订阅弹窗(供"订阅"按钮调用) */
78
+ subscribe: () => void;
79
+ /** 取消推送订阅 */
80
+ unsubscribe: () => void;
81
+ /** 是否应向用户展示自定义引导弹窗 */
82
+ shouldShowPopup: boolean;
83
+ /** 关闭自定义弹窗并写入冷却标记 */
84
+ dismissPopup: () => void;
85
+ /** 当前是否已订阅(异步检测完成后更新) */
86
+ isSubscribed: boolean;
87
+ /** SDK 是否就绪 */
88
+ isReady: boolean;
89
+ }
90
+ /**
91
+ * useEmarsysWebPush
92
+ *
93
+ * 封装 Emarsys Web Push SDK 的订阅生命周期,包括:
94
+ * - SDK 初始化
95
+ * - 自定义弹窗展示逻辑(两步策略,避免直接触发浏览器原生弹窗)
96
+ * - 已登录联系人的 login / logout 自动管理
97
+ * - 已有订阅用户的迁移(从旧推送系统迁移)
98
+ *
99
+ * @example
100
+ * ```tsx
101
+ * const { shouldShowPopup, subscribe, dismissPopup } = useEmarsysWebPush({
102
+ * applicationCode: process.env.NEXT_PUBLIC_EMARSYS_APP_CODE!,
103
+ * applicationServerPublicKey: process.env.NEXT_PUBLIC_EMARSYS_VAPID_PUBLIC_KEY!,
104
+ * fieldId: 10372,
105
+ * contactValue: user?.customerId ?? null,
106
+ * sdkLoaded: scriptLoaded,
107
+ * })
108
+ * ```
109
+ */
110
+ export declare function useEmarsysWebPush({ applicationCode, applicationServerPublicKey, serviceWorkerUrl, defaultNotificationTitle, defaultNotificationIcon, fieldId, contactValue, enableLogging, dismissCooldownDays, sdkLoaded, }: UseEmarsysWebPushOptions): UseEmarsysWebPushReturn;
111
+ export {};
@@ -0,0 +1,2 @@
1
+ import{useCallback as d,useEffect as g,useRef as R,useState as y}from"react";const E="emarsysSubscribe",b="emarsysLogin",C="anker_push_dismissed";function D(){return typeof navigator>"u"?!1:/iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase())}function x(){return typeof window>"u"?!1:window.matchMedia("(display-mode: standalone)").matches||"standalone"in window.navigator&&window.navigator.standalone===!0}function r(n,o,u){try{if(n==="get")return localStorage.getItem(o);n==="set"&&u!==void 0&&localStorage.setItem(o,u),n==="remove"&&localStorage.removeItem(o)}catch{}return null}function a(){if(typeof window>"u")return null;const n=window.WebEmarsysSdk;return!n||Array.isArray(n)?null:n}function K({applicationCode:n,applicationServerPublicKey:o,serviceWorkerUrl:u="service-worker.js",defaultNotificationTitle:w,defaultNotificationIcon:k,fieldId:h,contactValue:t,enableLogging:v=!1,dismissCooldownDays:P=7,sdkLoaded:c=!0}){const[f,L]=y(!1),[G,m]=y(!1),[_,p]=y(!1),S=R(!1),A=R(!1);g(()=>{if(!c||typeof window>"u")return;const e=u.replace(/^\/+/,"").replace(/^https?:\/\/[^/]+\//,"");window.WebEmarsysSdk=window.WebEmarsysSdk||[],window.WebEmarsysSdk.push(["init",{applicationCode:n,enableMacSafariVapid:!0,defaultNotificationTitle:w,defaultNotificationIcon:k,autoSubscribe:!1,enableLogging:v,serviceWorker:{url:e,applicationServerPublicKey:o}}])},[c,n,o,u,w,k,v]);const l=d(e=>{if(S.current)return;const s=a();s&&s.isSubscribed().then(i=>{i&&s.login({fieldId:h,fieldValue:e}).then(W=>{W&&(r("set",b,"login"),S.current=!0)})})},[h]),I=d(()=>{const e=a();e&&e.isSubscribed().then(s=>{s&&e.logout().then(i=>{i&&(r("remove",b),S.current=!1)})})},[]);g(()=>{if(!c||typeof window>"u"||D()&&!x())return;window.WebEmarsysSdk=window.WebEmarsysSdk||[];const e=window.WebEmarsysSdk;e.push(["onReady",()=>{L(!0),a()?.isSubscribed().then(i=>{m(i)}),e.push(["onPermissionGranted",()=>{!r("get",E)&&!A.current&&(a()?.subscribe(),r("set",E,"subscribe"))}]);let s=!1;e.push(["onPermissionGranted",()=>{s=!0}]),e.push(["onPermissionDenied",()=>{s=!0}]),setTimeout(()=>{if(s)return;const i=r("get",C);i&&Date.now()-parseInt(i,10)<P*24*60*60*1e3||p(!0)},2e3)}]),e.push(["onSubscribe",()=>{m(!0),r("set",E,"subscribe"),t&&l(t)}]),e.push(["onUnsubscribe",()=>{m(!1)}])},[c,t,P,l]),g(()=>{f&&(t?r("get",b)||l(t):r("get",b)&&I())},[f,t,l,I]);const N=d(()=>{p(!1),A.current=!0;const e=a();if(!e){window.WebEmarsysSdk.push(i=>{i.subscribe()});return}e.subscribe()},[]),O=d(()=>{a()?.unsubscribe()},[]),U=d(()=>{p(!1),r("set",C,String(Date.now()))},[]);return{subscribe:N,unsubscribe:O,shouldShowPopup:_,dismissPopup:U,isSubscribed:G,isReady:f}}export{K as useEmarsysWebPush};
2
+ //# sourceMappingURL=useEmarsysWebPush.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/hooks/useEmarsysWebPush.ts"],
4
+ "sourcesContent": ["import { useCallback, useEffect, useRef, useState } from 'react'\n\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n// Emarsys Web Push SDK \u5168\u5C40\u7C7B\u578B\u58F0\u660E\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\nexport interface EmarsysContactInfo {\n /** Emarsys \u8054\u7CFB\u4EBA\u5B57\u6BB5 ID\uFF08\u5982 10372\uFF09 */\n fieldId: number\n /** \u5B57\u6BB5\u503C\uFF08\u5982\u7528\u6237\u552F\u4E00\u6807\u8BC6\uFF09 */\n fieldValue: string\n}\n\nexport interface EmarsysInitConfig {\n /** Emarsys Domain Code\uFF0C\u4ECE\u540E\u53F0\u83B7\u53D6 */\n applicationCode: string\n /** macOS Safari 16+ \u4F7F\u7528 VAPID \u66FF\u4EE3 APNS */\n enableMacSafariVapid?: boolean\n /** \u9ED8\u8BA4\u63A8\u9001\u901A\u77E5\u6807\u9898 */\n defaultNotificationTitle?: string\n /** \u9ED8\u8BA4\u63A8\u9001\u901A\u77E5\u56FE\u6807 URL */\n defaultNotificationIcon?: string\n /** \u662F\u5426\u81EA\u52A8\u89E6\u53D1\u6D4F\u89C8\u5668\u8BA2\u9605\u5F39\u7A97\uFF0C\u5F3A\u70C8\u5EFA\u8BAE\u8BBE\u4E3A false */\n autoSubscribe?: boolean\n /** \u5F00\u53D1\u9636\u6BB5\u5F00\u542F SDK \u65E5\u5FD7 */\n enableLogging?: boolean\n serviceWorker: {\n /** Service Worker \u6587\u4EF6\u8DEF\u5F84\uFF08\u9700\u653E\u5728\u7F51\u7AD9\u6839\u76EE\u5F55\uFF09 */\n url: string\n /** VAPID \u516C\u94A5\uFF08Base64 URL-safe \u7F16\u7801\uFF09 */\n applicationServerPublicKey: string\n }\n}\n\ntype EmarsysSdkEventName =\n | 'onReady'\n | 'onSubscribe'\n | 'onUnsubscribe'\n | 'onPermissionPrompt'\n | 'onPermissionGranted'\n | 'onPermissionDenied'\n | 'onSWInitError'\n\ntype EmarsysSdkCommand = ['init', EmarsysInitConfig] | [EmarsysSdkEventName, () => void]\n\ninterface EmarsysSdkApi {\n subscribe: () => void\n unsubscribe: () => void\n login: (contactInfo: EmarsysContactInfo) => Promise<boolean>\n logout: () => Promise<boolean>\n isSubscribed: () => Promise<boolean>\n isRegistered: () => boolean\n customEvent: (eventName: string, payload?: Record<string, unknown>) => Promise<boolean>\n push: (command: EmarsysSdkCommand | ((sdk: EmarsysSdkApi) => void)) => void\n}\n\ndeclare global {\n interface Window {\n WebEmarsysSdk: EmarsysSdkApi | (EmarsysSdkCommand | ((sdk: EmarsysSdkApi) => void))[]\n }\n}\n\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n// Hook \u5165\u53C2\u7C7B\u578B\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\nexport interface UseEmarsysWebPushOptions {\n /** Emarsys Domain Code */\n applicationCode: string\n /** VAPID \u516C\u94A5 */\n applicationServerPublicKey: string\n /** Service Worker \u8DEF\u5F84\uFF0C\u9ED8\u8BA4 'service-worker.js'\uFF08\u4E0D\u542B\u524D\u5BFC\u659C\u6760\uFF09 */\n serviceWorkerUrl?: string\n /** \u9ED8\u8BA4\u901A\u77E5\u6807\u9898 */\n defaultNotificationTitle?: string\n /** \u9ED8\u8BA4\u901A\u77E5\u56FE\u6807 URL */\n defaultNotificationIcon?: string\n /** \u8054\u7CFB\u4EBA\u4E3B\u952E\u5B57\u6BB5 ID\uFF08\u7531 Emarsys \u540E\u53F0\u914D\u7F6E\uFF09 */\n fieldId: number\n /**\n * \u5F53\u524D\u7528\u6237\u7684\u8054\u7CFB\u4EBA\u6807\u8BC6\uFF08\u5982 hashed email / customer ID\uFF09\u3002\n * null \u8868\u793A\u672A\u767B\u5F55\u7684\u533F\u540D\u8BBF\u5BA2\u3002\n */\n contactValue: string | null\n /** \u662F\u5426\u5F00\u542F\u8C03\u8BD5\u65E5\u5FD7\uFF0C\u9ED8\u8BA4 false */\n enableLogging?: boolean\n /**\n * \u70B9\u51FB\"\u7A0D\u540E\"\u540E\u7684\u5F39\u7A97\u51B7\u5374\u5929\u6570\uFF0C\u9ED8\u8BA4 7 \u5929\u3002\n * \u51B7\u5374\u671F\u95F4\u4E0D\u518D\u5C55\u793A\u81EA\u5B9A\u4E49\u5F39\u7A97\u3002\n */\n dismissCooldownDays?: number\n /**\n * SDK \u662F\u5426\u5DF2\u901A\u8FC7\u5916\u90E8 <Script> \u6807\u7B7E\u52A0\u8F7D\u5B8C\u6BD5\u3002\n * \u4F20\u5165\u6B64 flag \u4EE5\u4FBF hook \u5728\u6B63\u786E\u65F6\u673A\u521D\u59CB\u5316\u3002\n * \u9ED8\u8BA4 true\uFF08\u5047\u8BBE SDK \u5DF2\u7ECF\u52A0\u8F7D\uFF09\u3002\n */\n sdkLoaded?: boolean\n}\n\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n// Hook \u8FD4\u56DE\u503C\u7C7B\u578B\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\nexport interface UseEmarsysWebPushReturn {\n /** \u624B\u52A8\u89E6\u53D1\u6D4F\u89C8\u5668\u539F\u751F\u8BA2\u9605\u5F39\u7A97\uFF08\u4F9B\"\u8BA2\u9605\"\u6309\u94AE\u8C03\u7528\uFF09 */\n subscribe: () => void\n /** \u53D6\u6D88\u63A8\u9001\u8BA2\u9605 */\n unsubscribe: () => void\n /** \u662F\u5426\u5E94\u5411\u7528\u6237\u5C55\u793A\u81EA\u5B9A\u4E49\u5F15\u5BFC\u5F39\u7A97 */\n shouldShowPopup: boolean\n /** \u5173\u95ED\u81EA\u5B9A\u4E49\u5F39\u7A97\u5E76\u5199\u5165\u51B7\u5374\u6807\u8BB0 */\n dismissPopup: () => void\n /** \u5F53\u524D\u662F\u5426\u5DF2\u8BA2\u9605\uFF08\u5F02\u6B65\u68C0\u6D4B\u5B8C\u6210\u540E\u66F4\u65B0\uFF09 */\n isSubscribed: boolean\n /** SDK \u662F\u5426\u5C31\u7EEA */\n isReady: boolean\n}\n\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n// \u5DE5\u5177\u51FD\u6570\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\nconst STORAGE_KEY_SUBSCRIBE = 'emarsysSubscribe'\nconst STORAGE_KEY_LOGIN = 'emarsysLogin'\nconst STORAGE_KEY_DISMISSED = 'anker_push_dismissed'\n\nfunction isIOS(): boolean {\n if (typeof navigator === 'undefined') return false\n return /iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase())\n}\n\nfunction isStandaloneWebApp(): boolean {\n if (typeof window === 'undefined') return false\n return (\n window.matchMedia('(display-mode: standalone)').matches ||\n // Safari standalone \u5C5E\u6027\uFF08\u975E\u6807\u51C6\uFF09\n ('standalone' in window.navigator && (window.navigator as Navigator & { standalone?: boolean }).standalone === true)\n )\n}\n\nfunction safeLocalStorage(action: 'get', key: string): string | null\nfunction safeLocalStorage(action: 'set', key: string, value: string): void\nfunction safeLocalStorage(action: 'remove', key: string): void\nfunction safeLocalStorage(action: 'get' | 'set' | 'remove', key: string, value?: string): string | null | void {\n try {\n if (action === 'get') return localStorage.getItem(key)\n if (action === 'set' && value !== undefined) localStorage.setItem(key, value)\n if (action === 'remove') localStorage.removeItem(key)\n } catch {\n // SSR \u6216\u9690\u79C1\u6A21\u5F0F\u4E0B localStorage \u4E0D\u53EF\u7528\n }\n return null\n}\n\nfunction getSdkApi(): EmarsysSdkApi | null {\n if (typeof window === 'undefined') return null\n const sdk = window.WebEmarsysSdk\n if (!sdk || Array.isArray(sdk)) return null\n return sdk as EmarsysSdkApi\n}\n\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n// \u6838\u5FC3 Hook\n// \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\n/**\n * useEmarsysWebPush\n *\n * \u5C01\u88C5 Emarsys Web Push SDK \u7684\u8BA2\u9605\u751F\u547D\u5468\u671F\uFF0C\u5305\u62EC\uFF1A\n * - SDK \u521D\u59CB\u5316\n * - \u81EA\u5B9A\u4E49\u5F39\u7A97\u5C55\u793A\u903B\u8F91\uFF08\u4E24\u6B65\u7B56\u7565\uFF0C\u907F\u514D\u76F4\u63A5\u89E6\u53D1\u6D4F\u89C8\u5668\u539F\u751F\u5F39\u7A97\uFF09\n * - \u5DF2\u767B\u5F55\u8054\u7CFB\u4EBA\u7684 login / logout \u81EA\u52A8\u7BA1\u7406\n * - \u5DF2\u6709\u8BA2\u9605\u7528\u6237\u7684\u8FC1\u79FB\uFF08\u4ECE\u65E7\u63A8\u9001\u7CFB\u7EDF\u8FC1\u79FB\uFF09\n *\n * @example\n * ```tsx\n * const { shouldShowPopup, subscribe, dismissPopup } = useEmarsysWebPush({\n * applicationCode: process.env.NEXT_PUBLIC_EMARSYS_APP_CODE!,\n * applicationServerPublicKey: process.env.NEXT_PUBLIC_EMARSYS_VAPID_PUBLIC_KEY!,\n * fieldId: 10372,\n * contactValue: user?.customerId ?? null,\n * sdkLoaded: scriptLoaded,\n * })\n * ```\n */\nexport function useEmarsysWebPush({\n applicationCode,\n applicationServerPublicKey,\n serviceWorkerUrl = 'service-worker.js',\n defaultNotificationTitle,\n defaultNotificationIcon,\n fieldId,\n contactValue,\n enableLogging = false,\n dismissCooldownDays = 7,\n sdkLoaded = true,\n}: UseEmarsysWebPushOptions): UseEmarsysWebPushReturn {\n const [isReady, setIsReady] = useState(false)\n const [isSubscribed, setIsSubscribed] = useState(false)\n const [shouldShowPopup, setShouldShowPopup] = useState(false)\n\n // \u907F\u514D\u91CD\u590D login/logout\n const hasPerformedLogin = useRef(false)\n // \u8FFD\u8E2A\u5F53\u524D session \u5185\u662F\u5426\u5DF2\u4E3B\u52A8\u89E6\u53D1\u8FC7 subscribe\n const isGeneralSubscribeRef = useRef(false)\n\n // \u2500\u2500 \u521D\u59CB\u5316 SDK \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n useEffect(() => {\n if (!sdkLoaded || typeof window === 'undefined') return\n\n // SDK v4.7.0 \u5185\u90E8 registerServiceWorker() \u6267\u884C `/${url}` \u62FC\u63A5\uFF0C\n // \u56E0\u6B64\u6B64\u5904\u5FC5\u987B\u4F20\u4E0D\u542B\u524D\u5BFC\u659C\u6760\u7684\u7EAF\u8DEF\u5F84\uFF08\u5982 'service-worker.js'\uFF09\uFF0C\n // \u4F20\u5165\u5E26\u659C\u6760\u7684\u8DEF\u5F84\u6216\u7EDD\u5BF9 URL \u5747\u4F1A\u5BFC\u81F4\u53CC\u659C\u6760/\u8DE8\u57DF SecurityError\u3002\n const swPath = serviceWorkerUrl.replace(/^\\/+/, '').replace(/^https?:\\/\\/[^/]+\\//, '')\n\n window.WebEmarsysSdk = window.WebEmarsysSdk || []\n const sdk = window.WebEmarsysSdk as (EmarsysSdkCommand | ((api: EmarsysSdkApi) => void))[]\n\n sdk.push([\n 'init',\n {\n applicationCode,\n enableMacSafariVapid: true,\n defaultNotificationTitle,\n defaultNotificationIcon,\n autoSubscribe: false,\n enableLogging,\n serviceWorker: {\n url: swPath,\n applicationServerPublicKey,\n },\n },\n ])\n }, [\n sdkLoaded,\n applicationCode,\n applicationServerPublicKey,\n serviceWorkerUrl,\n defaultNotificationTitle,\n defaultNotificationIcon,\n enableLogging,\n ])\n\n // \u2500\u2500 \u6267\u884C Emarsys login\uFF08\u5173\u8054\u5DF2\u77E5\u8054\u7CFB\u4EBA\uFF09\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n const performLogin = useCallback(\n (value: string) => {\n if (hasPerformedLogin.current) return\n const api = getSdkApi()\n if (!api) return\n\n api.isSubscribed().then(subscribed => {\n if (!subscribed) return\n api.login({ fieldId, fieldValue: value }).then(result => {\n if (result) {\n safeLocalStorage('set', STORAGE_KEY_LOGIN, 'login')\n hasPerformedLogin.current = true\n }\n })\n })\n },\n [fieldId]\n )\n\n // \u2500\u2500 \u6267\u884C Emarsys logout\uFF08\u89E3\u9664\u8054\u7CFB\u4EBA\u5173\u8054\uFF09\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n const performLogout = useCallback(() => {\n const api = getSdkApi()\n if (!api) return\n\n api.isSubscribed().then(subscribed => {\n if (!subscribed) return\n api.logout().then(result => {\n if (result) {\n safeLocalStorage('remove', STORAGE_KEY_LOGIN)\n hasPerformedLogin.current = false\n }\n })\n })\n }, [])\n\n // \u2500\u2500 \u6CE8\u518C SDK \u56DE\u8C03 & \u4E1A\u52A1\u903B\u8F91 \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n useEffect(() => {\n if (!sdkLoaded || typeof window === 'undefined') return\n\n // iOS \u6D4F\u89C8\u5668\uFF08\u975E PWA \u6A21\u5F0F\uFF09\u4E0D\u505A\u4EFB\u4F55\u64CD\u4F5C\n if (isIOS() && !isStandaloneWebApp()) return\n\n window.WebEmarsysSdk = window.WebEmarsysSdk || []\n const sdk = window.WebEmarsysSdk as (EmarsysSdkCommand | ((api: EmarsysSdkApi) => void))[]\n\n sdk.push([\n 'onReady',\n () => {\n setIsReady(true)\n\n // \u68C0\u67E5\u5F53\u524D\u8BA2\u9605\u72B6\u6001\n getSdkApi()\n ?.isSubscribed()\n .then(subscribed => {\n setIsSubscribed(subscribed)\n })\n\n // \u5DF2\u6709\u8BA2\u9605\u7528\u6237\u8FC1\u79FB\uFF08\u65E7\u63A8\u9001\u7CFB\u7EDF \u2192 Emarsys\uFF09\n sdk.push([\n 'onPermissionGranted',\n () => {\n if (!safeLocalStorage('get', STORAGE_KEY_SUBSCRIBE) && !isGeneralSubscribeRef.current) {\n getSdkApi()?.subscribe()\n safeLocalStorage('set', STORAGE_KEY_SUBSCRIBE, 'subscribe')\n }\n },\n ])\n\n // \u5224\u65AD\u662F\u5426\u9700\u8981\u5C55\u793A\u81EA\u5B9A\u4E49\u5F15\u5BFC\u5F39\u7A97\n // \u5EF6\u8FDF 2 \u79D2\uFF0C\u7B49\u5F85 onPermissionGranted / onPermissionDenied \u5F02\u6B65\u56DE\u8C03\n let permissionAlreadyHandled = false\n sdk.push([\n 'onPermissionGranted',\n () => {\n permissionAlreadyHandled = true\n },\n ])\n sdk.push([\n 'onPermissionDenied',\n () => {\n permissionAlreadyHandled = true\n },\n ])\n\n setTimeout(() => {\n if (permissionAlreadyHandled) return\n\n // \u68C0\u67E5\u51B7\u5374\u671F\n const dismissedAt = safeLocalStorage('get', STORAGE_KEY_DISMISSED)\n if (dismissedAt) {\n const elapsed = Date.now() - parseInt(dismissedAt, 10)\n if (elapsed < dismissCooldownDays * 24 * 60 * 60 * 1000) return\n }\n\n setShouldShowPopup(true)\n }, 2000)\n },\n ])\n\n // \u8BA2\u9605\u6210\u529F\u540E\u66F4\u65B0\u72B6\u6001\u5E76\u6267\u884C login\n sdk.push([\n 'onSubscribe',\n () => {\n setIsSubscribed(true)\n safeLocalStorage('set', STORAGE_KEY_SUBSCRIBE, 'subscribe')\n if (contactValue) {\n performLogin(contactValue)\n }\n },\n ])\n\n sdk.push([\n 'onUnsubscribe',\n () => {\n setIsSubscribed(false)\n },\n ])\n }, [sdkLoaded, contactValue, dismissCooldownDays, performLogin])\n\n // \u2500\u2500 \u76D1\u542C contactValue \u53D8\u5316\uFF0C\u81EA\u52A8 login / logout \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n useEffect(() => {\n if (!isReady) return\n\n if (contactValue) {\n if (!safeLocalStorage('get', STORAGE_KEY_LOGIN)) {\n performLogin(contactValue)\n }\n } else {\n if (safeLocalStorage('get', STORAGE_KEY_LOGIN)) {\n performLogout()\n }\n }\n }, [isReady, contactValue, performLogin, performLogout])\n\n // \u2500\u2500 \u5BF9\u5916\u66B4\u9732\u7684 API \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\n const subscribe = useCallback(() => {\n setShouldShowPopup(false)\n isGeneralSubscribeRef.current = true\n const api = getSdkApi()\n if (!api) {\n const sdk = window.WebEmarsysSdk as ((api: EmarsysSdkApi) => void)[]\n sdk.push(sdkApi => {\n sdkApi.subscribe()\n })\n return\n }\n api.subscribe()\n }, [])\n\n const unsubscribe = useCallback(() => {\n getSdkApi()?.unsubscribe()\n }, [])\n\n const dismissPopup = useCallback(() => {\n setShouldShowPopup(false)\n safeLocalStorage('set', STORAGE_KEY_DISMISSED, String(Date.now()))\n }, [])\n\n return {\n subscribe,\n unsubscribe,\n shouldShowPopup,\n dismissPopup,\n isSubscribed,\n isReady,\n }\n}\n"],
5
+ "mappings": "AAAA,OAAS,eAAAA,EAAa,aAAAC,EAAW,UAAAC,EAAQ,YAAAC,MAAgB,QA0HzD,MAAMC,EAAwB,mBACxBC,EAAoB,eACpBC,EAAwB,uBAE9B,SAASC,GAAiB,CACxB,OAAI,OAAO,UAAc,IAAoB,GACtC,mBAAmB,KAAK,UAAU,UAAU,YAAY,CAAC,CAClE,CAEA,SAASC,GAA8B,CACr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gBAAAd,EACA,aAAAe,EACA,aAAAjB,EACA,QAAAF,CACF,CACF",
6
+ "names": ["useCallback", "useEffect", "useRef", "useState", "STORAGE_KEY_SUBSCRIBE", "STORAGE_KEY_LOGIN", "STORAGE_KEY_DISMISSED", "isIOS", "isStandaloneWebApp", "safeLocalStorage", "action", "key", "value", "getSdkApi", "sdk", "useEmarsysWebPush", "applicationCode", "applicationServerPublicKey", "serviceWorkerUrl", "defaultNotificationTitle", "defaultNotificationIcon", "fieldId", "contactValue", "enableLogging", "dismissCooldownDays", "sdkLoaded", "isReady", "setIsReady", "isSubscribed", "setIsSubscribed", "shouldShowPopup", "setShouldShowPopup", "hasPerformedLogin", "isGeneralSubscribeRef", "swPath", "performLogin", "api", "subscribed", "result", "performLogout", "permissionAlreadyHandled", "dismissedAt", "subscribe", "sdkApi", "unsubscribe", "dismissPopup"]
7
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anker-in/headless-ui",
3
- "version": "1.3.0",
3
+ "version": "1.3.2",
4
4
  "type": "commonjs",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "types": "./dist/cjs/index.d.ts",
@@ -47,11 +47,13 @@
47
47
  "import": "./tailwind.config.js",
48
48
  "types": "./tailwind.config.d.ts"
49
49
  },
50
- "./tokens/*": "./dist/tokens/*"
50
+ "./tokens/*": "./dist/tokens/*",
51
+ "./static/*": "./static/*"
51
52
  },
52
53
  "description": "",
53
54
  "files": [
54
55
  "dist/**",
56
+ "static/**",
55
57
  "*.css",
56
58
  "README.md",
57
59
  "CONTRIBUTING.md",
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Emarsys Web Push Service Worker
3
+ *
4
+ * 使用说明
5
+ * ────────
6
+ * 此文件是独立静态资源,不会被打包进 JS bundle。
7
+ * 使用前需将此文件复制到你的项目 public/ 目录(Next.js Pages Router / App Router 均适用):
8
+ *
9
+ * cp node_modules/@anker-in/headless-ui/static/emarsys-service-worker.js public/service-worker.js
10
+ *
11
+ * 或在项目 package.json 中添加脚本(推荐,随依赖更新自动同步):
12
+ *
13
+ * "scripts": {
14
+ * "copy:emarsys-sw": "cp node_modules/@anker-in/headless-ui/static/emarsys-service-worker.js public/service-worker.js"
15
+ * }
16
+ *
17
+ * 然后在 useEmarsysWebPush 中配置 serviceWorkerUrl: '/service-worker.js'(默认值,无需额外设置)。
18
+ *
19
+ * 注意事项
20
+ * ────────
21
+ * - Service Worker 必须从网站根路径(/service-worker.js)提供服务,才能控制整站页面
22
+ * - 服务器需返回 Content-Type: application/javascript
23
+ * - 建议设置 Cache-Control: no-cache,确保 SDK 版本更新时能及时刷新
24
+ * - 如果项目已有 Service Worker,将下方 importScripts 加入现有文件顶部即可
25
+ *
26
+ * @see https://help.sap.com/docs/SAP_EMARSYS
27
+ */
28
+
29
+ self.importScripts(
30
+ 'https://client-version.cf.emarsys.net/web-emarsys-sdk-v4/latest/web-emarsys-service-worker.js'
31
+ )
package/style.css CHANGED
@@ -1004,6 +1004,9 @@ video {
1004
1004
  .mt-0 {
1005
1005
  margin-top: 0px;
1006
1006
  }
1007
+ .mt-0\.5 {
1008
+ margin-top: 0.125rem;
1009
+ }
1007
1010
  .mt-1 {
1008
1011
  margin-top: 0.25rem;
1009
1012
  }
@@ -2282,6 +2285,9 @@ video {
2282
2285
  .gap-y-1 {
2283
2286
  row-gap: 0.25rem;
2284
2287
  }
2288
+ .gap-y-3 {
2289
+ row-gap: 0.75rem;
2290
+ }
2285
2291
  .gap-y-4 {
2286
2292
  row-gap: 1rem;
2287
2293
  }
@@ -2629,6 +2635,9 @@ video {
2629
2635
  .border-\[var\(--brand-color-0\)\] {
2630
2636
  border-color: var(--brand-color-0);
2631
2637
  }
2638
+ .border-black\/5 {
2639
+ border-color: rgb(0 0 0 / 0.05);
2640
+ }
2632
2641
  .border-brand-0 {
2633
2642
  border-color: var(--brand-color-0);
2634
2643
  }
@@ -2876,6 +2885,10 @@ video {
2876
2885
  .bg-error-1 {
2877
2886
  background-color: var(--error-color-1);
2878
2887
  }
2888
+ .bg-gray-900 {
2889
+ --tw-bg-opacity: 1;
2890
+ background-color: rgb(17 24 39 / var(--tw-bg-opacity, 1));
2891
+ }
2879
2892
  .bg-info-primary {
2880
2893
  background-color: var(--info-primary-color);
2881
2894
  }
@@ -3398,6 +3411,9 @@ video {
3398
3411
  .pt-0 {
3399
3412
  padding-top: 0px;
3400
3413
  }
3414
+ .pt-0\.5 {
3415
+ padding-top: 0.125rem;
3416
+ }
3401
3417
  .pt-1 {
3402
3418
  padding-top: 0.25rem;
3403
3419
  }
@@ -3577,6 +3593,12 @@ video {
3577
3593
  .leading-none {
3578
3594
  line-height: 1;
3579
3595
  }
3596
+ .leading-relaxed {
3597
+ line-height: 1.625;
3598
+ }
3599
+ .leading-snug {
3600
+ line-height: 1.375;
3601
+ }
3580
3602
  .leading-tight {
3581
3603
  line-height: var(--line-height-tight);
3582
3604
  }
@@ -3785,6 +3807,10 @@ video {
3785
3807
  --tw-text-opacity: 1;
3786
3808
  color: rgb(107 114 128 / var(--tw-text-opacity, 1));
3787
3809
  }
3810
+ .text-gray-900 {
3811
+ --tw-text-opacity: 1;
3812
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
3813
+ }
3788
3814
  .text-info-primary {
3789
3815
  color: var(--info-primary-color);
3790
3816
  }
@@ -4001,6 +4027,9 @@ video {
4001
4027
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
4002
4028
  transition-duration: 150ms;
4003
4029
  }
4030
+ .duration-150 {
4031
+ transition-duration: 150ms;
4032
+ }
4004
4033
  .duration-200 {
4005
4034
  transition-duration: 200ms;
4006
4035
  }
@@ -4305,6 +4334,14 @@ video {
4305
4334
  .hover\:bg-container-secondary-0:hover {
4306
4335
  background-color: var(--container-secondary-color-0);
4307
4336
  }
4337
+ .hover\:bg-gray-100:hover {
4338
+ --tw-bg-opacity: 1;
4339
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
4340
+ }
4341
+ .hover\:bg-gray-700:hover {
4342
+ --tw-bg-opacity: 1;
4343
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1));
4344
+ }
4308
4345
  .hover\:bg-info-white:hover {
4309
4346
  background-color: var(--info-white-color);
4310
4347
  }
@@ -4434,6 +4471,21 @@ video {
4434
4471
  outline: 2px solid transparent;
4435
4472
  outline-offset: 2px;
4436
4473
  }
4474
+ .focus-visible\:outline:focus-visible {
4475
+ outline-style: solid;
4476
+ }
4477
+ .focus-visible\:outline-2:focus-visible {
4478
+ outline-width: 2px;
4479
+ }
4480
+ .focus-visible\:outline-offset-2:focus-visible {
4481
+ outline-offset: 2px;
4482
+ }
4483
+ .focus-visible\:outline-gray-400:focus-visible {
4484
+ outline-color: #9ca3af;
4485
+ }
4486
+ .focus-visible\:outline-gray-900:focus-visible {
4487
+ outline-color: #111827;
4488
+ }
4437
4489
  .focus-visible\:ring-0:focus-visible {
4438
4490
  --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);
4439
4491
  --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);
@@ -5154,6 +5206,9 @@ video {
5154
5206
  .tablet\:basis-\[58\%\] {
5155
5207
  flex-basis: 58%;
5156
5208
  }
5209
+ .tablet\:basis-auto {
5210
+ flex-basis: auto;
5211
+ }
5157
5212
  .tablet\:-translate-y-1\/2 {
5158
5213
  --tw-translate-y: -50%;
5159
5214
  transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
@@ -5804,6 +5859,9 @@ video {
5804
5859
  .laptop\:w-2\/3 {
5805
5860
  width: 66.666667%;
5806
5861
  }
5862
+ .laptop\:w-80 {
5863
+ width: 20rem;
5864
+ }
5807
5865
  .laptop\:w-\[--circle-laptop-size\] {
5808
5866
  width: var(--circle-laptop-size);
5809
5867
  }
@@ -7591,6 +7649,10 @@ video {
7591
7649
  .lg-desktop\:gap-\[64px\] {
7592
7650
  gap: 64px;
7593
7651
  }
7652
+ .lg-desktop\:gap-x-3 {
7653
+ -moz-column-gap: 0.75rem;
7654
+ column-gap: 0.75rem;
7655
+ }
7594
7656
  .lg-desktop\:p-4 {
7595
7657
  padding: 1rem;
7596
7658
  }