@anker-in/headless-ui 1.1.81 → 1.1.82
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.
- package/dist/cjs/biz-components/AccordionCards/index.d.ts +1 -36
- package/dist/cjs/biz-components/ActivitySchedule/index.d.ts +1 -3
- package/dist/cjs/biz-components/AiuiProvider/index.d.ts +1 -13
- package/dist/cjs/biz-components/AiuiProvider/index.js +1 -1
- package/dist/cjs/biz-components/AiuiProvider/index.js.map +3 -3
- package/dist/cjs/biz-components/AnchorNavigation/index.d.ts +1 -1
- package/dist/cjs/biz-components/AplusDesc/index.d.ts +1 -17
- package/dist/cjs/biz-components/BrandCardLink/BrandCardLink.d.ts +1 -2
- package/dist/cjs/biz-components/BrandEquity/BrandEquity.d.ts +1 -2
- package/dist/cjs/biz-components/Category/index.d.ts +1 -1
- package/dist/cjs/biz-components/CreativeModule/index.d.ts +1 -7
- package/dist/cjs/biz-components/DownLoad/index.d.ts +1 -6
- package/dist/cjs/biz-components/Evaluate/index.d.ts +1 -1
- package/dist/cjs/biz-components/Faq/Faq.d.ts +2 -3
- package/dist/cjs/biz-components/FeatureCards/FeatureCards.d.ts +1 -3
- package/dist/cjs/biz-components/FeatureShowcase/FeatureShowcase.d.ts +1 -3
- package/dist/cjs/biz-components/Features/index.d.ts +1 -8
- package/dist/cjs/biz-components/FootCharger/index.d.ts +1 -7
- package/dist/cjs/biz-components/FooterNavigation/index.d.ts +1 -2
- package/dist/cjs/biz-components/GiftBox/index.d.ts +1 -3
- package/dist/cjs/biz-components/GiftShelf/index.d.ts +1 -3
- package/dist/cjs/biz-components/GiftTierShelf/index.d.ts +1 -3
- package/dist/cjs/biz-components/Graphic/index.d.ts +1 -1
- package/dist/cjs/biz-components/GraphicAttractionBlock/index.d.ts +1 -1
- package/dist/cjs/biz-components/GraphicMore/index.d.ts +1 -7
- package/dist/cjs/biz-components/GraphicOverlay/GraphicOverlay.d.ts +2 -10
- package/dist/cjs/biz-components/HeaderNavigation/index.d.ts +1 -3
- package/dist/cjs/biz-components/HeroBanner/HeroBanner.d.ts +1 -5
- package/dist/cjs/biz-components/ImageTextFeature/ImageTextFeature.d.ts +1 -3
- package/dist/cjs/biz-components/ImageWithText/ImageWithText.d.ts +1 -3
- package/dist/cjs/biz-components/Ksp/index.d.ts +1 -1
- package/dist/cjs/biz-components/Listing/components/PaidShipping/index.d.ts +1 -11
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts +1 -26
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.d.ts +1 -1
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.d.ts +1 -1
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.d.ts +1 -1
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.d.ts +1 -1
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.d.ts +1 -1
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductGallery/index.d.ts +1 -1
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductPaidShipping/index.d.ts +1 -11
- package/dist/cjs/biz-components/Listing/components/ProductCard/ProductSummary/index.d.ts +1 -1
- package/dist/cjs/biz-components/Listing/components/PurchaseBar/index.d.ts +1 -2
- package/dist/cjs/biz-components/Marquee/Marquee.d.ts +2 -3
- package/dist/cjs/biz-components/MarqueeReview/index.d.ts +1 -1
- package/dist/cjs/biz-components/MediaEndorsement/index.d.ts +1 -2
- package/dist/cjs/biz-components/MediaPlayerBase/index.d.ts +1 -2
- package/dist/cjs/biz-components/MediaPlayerBase/index.js +1 -1
- package/dist/cjs/biz-components/MediaPlayerBase/index.js.map +2 -2
- package/dist/cjs/biz-components/MediaPlayerMulti/index.d.ts +1 -2
- package/dist/cjs/biz-components/MediaPlayerSticky/index.d.ts +1 -5
- package/dist/cjs/biz-components/MediaSceneSwitcher/MediaSceneSwitcher.d.ts +1 -2
- package/dist/cjs/biz-components/MediaSceneSwitcherV2/index.d.ts +1 -1
- package/dist/cjs/biz-components/MemberEquity/index.d.ts +1 -3
- package/dist/cjs/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.d.ts +2 -17
- package/dist/cjs/biz-components/NavigationSearch/index.d.ts +1 -2
- package/dist/cjs/biz-components/ProductCompare/index.d.ts +1 -1
- package/dist/cjs/biz-components/ProductHero/ProductHero.d.ts +1 -3
- package/dist/cjs/biz-components/ProductNav/ProductNav.d.ts +1 -2
- package/dist/cjs/biz-components/PromotionalBar/index.d.ts +1 -1
- package/dist/cjs/biz-components/SecondaryBanner/index.d.ts +1 -1
- package/dist/cjs/biz-components/SelectStore/index.d.ts +1 -7
- package/dist/cjs/biz-components/ShelfDisplay/index.d.ts +1 -3
- package/dist/cjs/biz-components/Slogan/index.d.ts +1 -3
- package/dist/cjs/biz-components/Spacer/index.d.ts +1 -3
- package/dist/cjs/biz-components/Specs/index.d.ts +1 -1
- package/dist/cjs/biz-components/SpecsComparison/SpecsComparison.d.ts +1 -3
- package/dist/cjs/biz-components/TabWithImage/TabWithImage.d.ts +1 -3
- package/dist/cjs/biz-components/Tabs/Tabs.d.ts +1 -3
- package/dist/cjs/biz-components/TabsGroup/index.d.ts +1 -3
- package/dist/cjs/biz-components/TabsWithMedia/TabsWithMedia.d.ts +1 -3
- package/dist/cjs/biz-components/ThreeDCarousel/ThreeDCarousel.d.ts +1 -3
- package/dist/cjs/biz-components/Title/index.d.ts +1 -1
- package/dist/cjs/biz-components/VideoFeature/VideoFeature.d.ts +1 -3
- package/dist/cjs/biz-components/WheelLottery/index.d.ts +1 -1
- package/dist/cjs/biz-components/WhyChoose/WhyChoose.d.ts +2 -3
- package/dist/cjs/helpers/ScrollLoadVideo.js +1 -1
- package/dist/cjs/helpers/ScrollLoadVideo.js.map +2 -2
- package/dist/cjs/shared/Styles.d.ts +1 -2
- package/dist/cjs/shared/Styles.js +1 -1
- package/dist/cjs/shared/Styles.js.map +2 -2
- package/dist/esm/biz-components/AccordionCards/index.d.ts +1 -36
- package/dist/esm/biz-components/ActivitySchedule/index.d.ts +1 -3
- package/dist/esm/biz-components/AiuiProvider/index.d.ts +1 -13
- package/dist/esm/biz-components/AiuiProvider/index.js +1 -1
- package/dist/esm/biz-components/AiuiProvider/index.js.map +3 -3
- package/dist/esm/biz-components/AnchorNavigation/index.d.ts +1 -1
- package/dist/esm/biz-components/AplusDesc/index.d.ts +1 -17
- package/dist/esm/biz-components/BrandCardLink/BrandCardLink.d.ts +1 -2
- package/dist/esm/biz-components/BrandEquity/BrandEquity.d.ts +1 -2
- package/dist/esm/biz-components/Category/index.d.ts +1 -1
- package/dist/esm/biz-components/CreativeModule/index.d.ts +1 -7
- package/dist/esm/biz-components/DownLoad/index.d.ts +1 -6
- package/dist/esm/biz-components/Evaluate/index.d.ts +1 -1
- package/dist/esm/biz-components/Faq/Faq.d.ts +2 -3
- package/dist/esm/biz-components/FeatureCards/FeatureCards.d.ts +1 -3
- package/dist/esm/biz-components/FeatureShowcase/FeatureShowcase.d.ts +1 -3
- package/dist/esm/biz-components/Features/index.d.ts +1 -8
- package/dist/esm/biz-components/FootCharger/index.d.ts +1 -7
- package/dist/esm/biz-components/FooterNavigation/index.d.ts +1 -2
- package/dist/esm/biz-components/GiftBox/index.d.ts +1 -3
- package/dist/esm/biz-components/GiftShelf/index.d.ts +1 -3
- package/dist/esm/biz-components/GiftTierShelf/index.d.ts +1 -3
- package/dist/esm/biz-components/Graphic/index.d.ts +1 -1
- package/dist/esm/biz-components/GraphicAttractionBlock/index.d.ts +1 -1
- package/dist/esm/biz-components/GraphicMore/index.d.ts +1 -7
- package/dist/esm/biz-components/GraphicOverlay/GraphicOverlay.d.ts +2 -10
- package/dist/esm/biz-components/HeaderNavigation/index.d.ts +1 -3
- package/dist/esm/biz-components/HeroBanner/HeroBanner.d.ts +1 -5
- package/dist/esm/biz-components/ImageTextFeature/ImageTextFeature.d.ts +1 -3
- package/dist/esm/biz-components/ImageWithText/ImageWithText.d.ts +1 -3
- package/dist/esm/biz-components/Ksp/index.d.ts +1 -1
- package/dist/esm/biz-components/Listing/components/PaidShipping/index.d.ts +1 -11
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts +1 -26
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductBundle/index.d.ts +1 -1
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductExchangePurchase/index.d.ts +1 -1
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductFreeGift/index.d.ts +1 -1
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductHighlight/index.d.ts +1 -1
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/ProductOptions/index.d.ts +1 -1
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductGallery/index.d.ts +1 -1
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductPaidShipping/index.d.ts +1 -11
- package/dist/esm/biz-components/Listing/components/ProductCard/ProductSummary/index.d.ts +1 -1
- package/dist/esm/biz-components/Listing/components/PurchaseBar/index.d.ts +1 -2
- package/dist/esm/biz-components/Marquee/Marquee.d.ts +2 -3
- package/dist/esm/biz-components/MarqueeReview/index.d.ts +1 -1
- package/dist/esm/biz-components/MediaEndorsement/index.d.ts +1 -2
- package/dist/esm/biz-components/MediaPlayerBase/index.d.ts +1 -2
- package/dist/esm/biz-components/MediaPlayerBase/index.js +1 -1
- package/dist/esm/biz-components/MediaPlayerBase/index.js.map +2 -2
- package/dist/esm/biz-components/MediaPlayerMulti/index.d.ts +1 -2
- package/dist/esm/biz-components/MediaPlayerSticky/index.d.ts +1 -5
- package/dist/esm/biz-components/MediaSceneSwitcher/MediaSceneSwitcher.d.ts +1 -2
- package/dist/esm/biz-components/MediaSceneSwitcherV2/index.d.ts +1 -1
- package/dist/esm/biz-components/MemberEquity/index.d.ts +1 -3
- package/dist/esm/biz-components/MultiLayoutGraphicBlock/MultiLayoutGraphicBlock.d.ts +2 -17
- package/dist/esm/biz-components/NavigationSearch/index.d.ts +1 -2
- package/dist/esm/biz-components/ProductCompare/index.d.ts +1 -1
- package/dist/esm/biz-components/ProductHero/ProductHero.d.ts +1 -3
- package/dist/esm/biz-components/ProductNav/ProductNav.d.ts +1 -2
- package/dist/esm/biz-components/PromotionalBar/index.d.ts +1 -1
- package/dist/esm/biz-components/SecondaryBanner/index.d.ts +1 -1
- package/dist/esm/biz-components/SelectStore/index.d.ts +1 -7
- package/dist/esm/biz-components/ShelfDisplay/index.d.ts +1 -3
- package/dist/esm/biz-components/Slogan/index.d.ts +1 -3
- package/dist/esm/biz-components/Spacer/index.d.ts +1 -3
- package/dist/esm/biz-components/Specs/index.d.ts +1 -1
- package/dist/esm/biz-components/SpecsComparison/SpecsComparison.d.ts +1 -3
- package/dist/esm/biz-components/TabWithImage/TabWithImage.d.ts +1 -3
- package/dist/esm/biz-components/Tabs/Tabs.d.ts +1 -3
- package/dist/esm/biz-components/TabsGroup/index.d.ts +1 -3
- package/dist/esm/biz-components/TabsWithMedia/TabsWithMedia.d.ts +1 -3
- package/dist/esm/biz-components/ThreeDCarousel/ThreeDCarousel.d.ts +1 -3
- package/dist/esm/biz-components/Title/index.d.ts +1 -1
- package/dist/esm/biz-components/VideoFeature/VideoFeature.d.ts +1 -3
- package/dist/esm/biz-components/WheelLottery/index.d.ts +1 -1
- package/dist/esm/biz-components/WhyChoose/WhyChoose.d.ts +2 -3
- package/dist/esm/helpers/ScrollLoadVideo.js +1 -1
- package/dist/esm/helpers/ScrollLoadVideo.js.map +2 -2
- package/dist/esm/shared/Styles.d.ts +1 -2
- package/dist/esm/shared/Styles.js +1 -1
- package/dist/esm/shared/Styles.js.map +2 -2
- package/package.json +1 -1
- package/dist/cjs/biz-components/AiuiProvider/useAutoTracking.d.ts +0 -17
- package/dist/cjs/biz-components/AiuiProvider/useAutoTracking.js +0 -2
- package/dist/cjs/biz-components/AiuiProvider/useAutoTracking.js.map +0 -7
- package/dist/esm/biz-components/AiuiProvider/useAutoTracking.d.ts +0 -17
- package/dist/esm/biz-components/AiuiProvider/useAutoTracking.js +0 -2
- package/dist/esm/biz-components/AiuiProvider/useAutoTracking.js.map +0 -7
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as v}from"react/jsx-runtime";import{gaTrack as y}from"../../shared/track.js";import{createContext as g,useContext as b,useEffect as h}from"react";const d=g({trackingData:{},locale:void 0,copyWriting:{}}),C=()=>{const a=b(d);if(!a)throw new Error("useAiui must be used in <AiuiProvider>");return a},f=({children:a,...i})=>(h(()=>{const s=(t,e)=>{const n={};if(!e||!e.attributes)return n;for(const m of Array.from(e.attributes)){const r=m?.name;r?.startsWith("data-headless-")&&(n[r]=e.getAttribute(r))}const l=n?.["data-headless-sku"],u=n?.["data-headless-type-name"]?.split?.("#"),o=n?.["data-headless-title-desc-button"]?.split?.("#"),p=n?.["data-headless-nav-position"]?.split?.("#");y({event:"ga4Event",event_name:"component_click",event_parameters:{page_group:i?.trackingData?.pageGroup||"Home Page",component_type:u?.[0]||"",component_name:u?.[1]||"",position:p?.[1]||"",navigation:p?.[0]||"",button_name:o?.[2]||"",SKU:l||"",component_title:o?.[0]||"",component_description:o?.[1]||""}})},c=new MutationObserver(()=>{document.querySelectorAll("[data-headless-type-name]").forEach(t=>{t.hasAttribute("data-headless-track-bound")||(t.addEventListener("click",e=>s(e,t)),t.setAttribute("data-headless-track-bound","true"))})});return c.observe(document.body,{childList:!0,subtree:!0}),document.querySelectorAll("[data-headless-type-name]").forEach(t=>{t.hasAttribute("data-headless-track-bound")||(t.addEventListener("click",e=>s(e,t)),t.setAttribute("data-headless-track-bound","true"))}),()=>c.disconnect()},[]),v(d.Provider,{value:i,children:a}));var E=f;export{d as AiuiContext,E as default,C as useAiuiContext};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/biz-components/AiuiProvider/index.tsx"],
|
|
4
|
-
"sourcesContent": ["import React, { createContext, useContext } from 'react'\nimport type { CurrencyDisplayType } from '../../types/props.js'\
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": ["jsx", "createContext", "useContext", "
|
|
4
|
+
"sourcesContent": ["import { gaTrack } from '../../shared/track.js'\nimport React, { createContext, useContext, useEffect } from 'react'\nimport type { CurrencyDisplayType } from '../../types/props.js'\n\n/**\n * Exposure tracking parameters\n */\nexport interface ExposureParams {\n componentType: string\n componentName: string\n componentTitle?: string\n componentDescription?: string\n navigation?: string\n pageGroup?: string\n position?: number\n}\n\n/**\n * Callback function for custom exposure handling\n */\nexport type OnExposureCallback = (params: ExposureParams) => void\n\ninterface AiuiContextType {\n /**\n * \u5168\u5C40\u57CB\u70B9\u6570\u636E\uFF0C\u81F3\u5C11\u5E94\u5305\u542B pageGroup \u5B57\u6BB5\u7528\u4E8E\u533A\u5206\u9875\u9762\uFF0C\u5176\u4ED6\u5B57\u6BB5\u53EF\u6839\u636E\u9700\u8981\u6DFB\u52A0\n */\n trackingData: Record<string, any>\n /**\n * \u5F53\u524D\u8BED\u8A00\u73AF\u5883\uFF0C\u9ED8\u8BA4\u4E3A\u6D4F\u89C8\u5668\u8BED\u8A00\n */\n locale?: string\n /**\n * \u5F53\u524D\u9875\u9762\u8DEF\u5F84\uFF0C\u7528\u4E8E\u57CB\u70B9\u533A\u5206\u4E0D\u540C\u9875\u9762\uFF0C\u9ED8\u8BA4\u4E3A window.location.pathname\n */\n pathname?: string\n /**\n * \u5546\u6237\u81EA\u5B9A\u4E49\u7684\u5E97\u94FA\u57DF\u540D\uFF0C\u7528\u4E8E\u57CB\u70B9\u533A\u5206\u4E0D\u540C\u5546\u6237\uFF0C\u9ED8\u8BA4\u4E3A\u7A7A\u5B57\u7B26\u4E32\n */\n storeDomain?: string\n /**\n * \u7528\u6237\u662F\u5426\u767B\u5F55\n */\n isLogin?: boolean\n\n /**\n * \u7528\u6237\u662F\u5426\u4E3APlus\u4F1A\u5458\n */\n isPlusMember?: boolean\n /**\n * \u8D27\u5E01\u4EE3\u7801\uFF0C\u9ED8\u8BA4\u4E3AUSD\n */\n currencyCode?: string\n /**\n * \u8D27\u5E01\u663E\u793A\u65B9\u5F0F\uFF0C\u9ED8\u8BA4\u4E3Asymbol\uFF08\u7B26\u53F7\uFF09\uFF0C\u53EF\u9009\u503C\u5305\u62EC\uFF1A'symbol'\uFF08\u7B26\u53F7\uFF0C\u5982$\uFF09\u3001'code'\uFF08\u8D27\u5E01\u4EE3\u7801\uFF0C\u5982USD\uFF09\u548C'name'\uFF08\u8D27\u5E01\u540D\u79F0\uFF0C\u5982\u7F8E\u5143\uFF09\u3002\n * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#currencydisplay for more details\n */\n currencyDisplay?: CurrencyDisplayType\n /**\n * \u6587\u6848\u914D\u7F6E\uFF0C\u5546\u6237\u53EF\u901A\u8FC7\u6B64\u5B57\u6BB5\u8986\u76D6\u9ED8\u8BA4\u6587\u6848\n */\n copyWriting?: Record<string, string>\n /**\n * \u81EA\u5B9A\u4E49\u66DD\u5149\u56DE\u8C03\u3002\u4F20\u5165\u540E\u4F1A\u66FF\u4EE3\u9ED8\u8BA4\u7684 GA \u57CB\u70B9\u903B\u8F91\u3002\n *\n * @example\n * <AiuiProvider\n * trackingData={{ pageGroup: 'Home Page' }}\n * onExposure={(params) => {\n * // \u4F7F\u7528\u5546\u6237\u81EA\u5DF1\u7684\u57CB\u70B9\u7CFB\u7EDF\u8BB0\u5F55\u66DD\u5149\u4E8B\u4EF6\n * ga.track('component_impression', params)\n * }}\n * >\n * {children}\n * </AiuiProvider>\n */\n onExposure?: OnExposureCallback\n}\n\nexport const AiuiContext = createContext<AiuiContextType>({\n trackingData: {},\n locale: undefined,\n copyWriting: {},\n})\n\nexport const useAiuiContext = () => {\n const context = useContext(AiuiContext)\n if (!context) {\n throw new Error('useAiui must be used in <AiuiProvider>')\n }\n return context\n}\n\nconst AiuiProvider = ({\n children,\n ...rest\n}: {\n children: React.ReactNode\n} & AiuiContextType) => {\n useEffect(() => {\n const handleTrackClick = (e: any, el: any) => {\n // e?.stopPropagation?.()\n const out: any = {}\n if (!el || !el.attributes) return out\n for (const attr of Array.from(el.attributes)) {\n const name = (attr as any)?.name\n if (name?.startsWith('data-headless-')) {\n out[name] = el.getAttribute(name)\n }\n }\n const sku = out?.['data-headless-sku']\n const nameType = out?.['data-headless-type-name']?.split?.('#')\n const titleDesc = out?.['data-headless-title-desc-button']?.split?.('#')\n const navPosition = out?.['data-headless-nav-position']?.split?.('#')\n gaTrack({\n event: 'ga4Event',\n event_name: 'component_click',\n event_parameters: {\n page_group: rest?.trackingData?.pageGroup || 'Home Page',\n component_type: nameType?.[0] || '',\n component_name: nameType?.[1] || '',\n position: navPosition?.[1] || '',\n navigation: navPosition?.[0] || '',\n button_name: titleDesc?.[2] || '',\n SKU: sku || '',\n component_title: titleDesc?.[0] || '',\n component_description: titleDesc?.[1] || '',\n },\n })\n }\n const observer = new MutationObserver(() => {\n document.querySelectorAll('[data-headless-type-name]').forEach(el => {\n if (!el.hasAttribute('data-headless-track-bound')) {\n el.addEventListener('click', e => handleTrackClick(e, el))\n el.setAttribute('data-headless-track-bound', 'true') // \u907F\u514D\u91CD\u590D\u7ED1\u5B9A\n }\n })\n })\n observer.observe(document.body, { childList: true, subtree: true })\n // \u521D\u59CB\u5316\u4E00\u6B21\u73B0\u6709\u8282\u70B9\n document.querySelectorAll('[data-headless-type-name]').forEach(el => {\n if (!el.hasAttribute('data-headless-track-bound')) {\n el.addEventListener('click', e => handleTrackClick(e, el))\n el.setAttribute('data-headless-track-bound', 'true')\n }\n })\n return () => observer.disconnect()\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [])\n\n return <AiuiContext.Provider value={rest}>{children}</AiuiContext.Provider>\n}\n\nexport default AiuiProvider\n"],
|
|
5
|
+
"mappings": "AAqJS,cAAAA,MAAA,oBArJT,OAAS,WAAAC,MAAe,wBACxB,OAAgB,iBAAAC,EAAe,cAAAC,EAAY,aAAAC,MAAiB,QA6ErD,MAAMC,EAAcH,EAA+B,CACxD,aAAc,CAAC,EACf,OAAQ,OACR,YAAa,CAAC,CAChB,CAAC,EAEYI,EAAiB,IAAM,CAClC,MAAMC,EAAUJ,EAAWE,CAAW,EACtC,GAAI,CAACE,EACH,MAAM,IAAI,MAAM,wCAAwC,EAE1D,OAAOA,CACT,EAEMC,EAAe,CAAC,CACpB,SAAAC,EACA,GAAGC,CACL,KAGEN,EAAU,IAAM,CACd,MAAMO,EAAmB,CAACC,EAAQC,IAAY,CAE5C,MAAMC,EAAW,CAAC,EAClB,GAAI,CAACD,GAAM,CAACA,EAAG,WAAY,OAAOC,EAClC,UAAWC,KAAQ,MAAM,KAAKF,EAAG,UAAU,EAAG,CAC5C,MAAMG,EAAQD,GAAc,KACxBC,GAAM,WAAW,gBAAgB,IACnCF,EAAIE,CAAI,EAAIH,EAAG,aAAaG,CAAI,EAEpC,CACA,MAAMC,EAAMH,IAAM,mBAAmB,EAC/BI,EAAWJ,IAAM,yBAAyB,GAAG,QAAQ,GAAG,EACxDK,EAAYL,IAAM,iCAAiC,GAAG,QAAQ,GAAG,EACjEM,EAAcN,IAAM,4BAA4B,GAAG,QAAQ,GAAG,EACpEb,EAAQ,CACN,MAAO,WACP,WAAY,kBACZ,iBAAkB,CAChB,WAAYS,GAAM,cAAc,WAAa,YAC7C,eAAgBQ,IAAW,CAAC,GAAK,GACjC,eAAgBA,IAAW,CAAC,GAAK,GACjC,SAAUE,IAAc,CAAC,GAAK,GAC9B,WAAYA,IAAc,CAAC,GAAK,GAChC,YAAaD,IAAY,CAAC,GAAK,GAC/B,IAAKF,GAAO,GACZ,gBAAiBE,IAAY,CAAC,GAAK,GACnC,sBAAuBA,IAAY,CAAC,GAAK,EAC3C,CACF,CAAC,CACH,EACME,EAAW,IAAI,iBAAiB,IAAM,CAC1C,SAAS,iBAAiB,2BAA2B,EAAE,QAAQR,GAAM,CAC9DA,EAAG,aAAa,2BAA2B,IAC9CA,EAAG,iBAAiB,QAAS,GAAKF,EAAiB,EAAGE,CAAE,CAAC,EACzDA,EAAG,aAAa,4BAA6B,MAAM,EAEvD,CAAC,CACH,CAAC,EACD,OAAAQ,EAAS,QAAQ,SAAS,KAAM,CAAE,UAAW,GAAM,QAAS,EAAK,CAAC,EAElE,SAAS,iBAAiB,2BAA2B,EAAE,QAAQR,GAAM,CAC9DA,EAAG,aAAa,2BAA2B,IAC9CA,EAAG,iBAAiB,QAAS,GAAKF,EAAiB,EAAGE,CAAE,CAAC,EACzDA,EAAG,aAAa,4BAA6B,MAAM,EAEvD,CAAC,EACM,IAAMQ,EAAS,WAAW,CAEnC,EAAG,CAAC,CAAC,EAEErB,EAACK,EAAY,SAAZ,CAAqB,MAAOK,EAAO,SAAAD,EAAS,GAGtD,IAAOa,EAAQd",
|
|
6
|
+
"names": ["jsx", "gaTrack", "createContext", "useContext", "useEffect", "AiuiContext", "useAiuiContext", "context", "AiuiProvider", "children", "rest", "handleTrackClick", "e", "el", "out", "attr", "name", "sku", "nameType", "titleDesc", "navPosition", "observer", "AiuiProvider_default"]
|
|
7
7
|
}
|
|
@@ -60,5 +60,5 @@ export interface AnchorNavigationProps extends React.HTMLAttributes<HTMLDivEleme
|
|
|
60
60
|
*/
|
|
61
61
|
buttonStyle?: AnchorButtonStyle;
|
|
62
62
|
}
|
|
63
|
-
declare const _default:
|
|
63
|
+
declare const _default: any;
|
|
64
64
|
export default _default;
|
|
@@ -1,18 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
type AplusItem = {
|
|
3
|
-
img: Img;
|
|
4
|
-
mobileImg: Img;
|
|
5
|
-
title: string;
|
|
6
|
-
desc: string;
|
|
7
|
-
theme: 'light' | 'dark';
|
|
8
|
-
};
|
|
9
|
-
interface AplusDescType extends React.HTMLAttributes<HTMLDivElement> {
|
|
10
|
-
data: {
|
|
11
|
-
title: string;
|
|
12
|
-
img: Img;
|
|
13
|
-
mobileImg: Img;
|
|
14
|
-
list: AplusItem[];
|
|
15
|
-
};
|
|
16
|
-
}
|
|
17
|
-
declare const _default: import("react").ForwardRefExoticComponent<AplusDescType & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
1
|
+
declare const _default: any;
|
|
18
2
|
export default _default;
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
declare const _default: import("react").ForwardRefExoticComponent<BrandCardLinkProps & import("react").RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
3
2
|
export default _default;
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
declare const _default: import("react").ForwardRefExoticComponent<BrandEquityProps & import("react").RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
3
2
|
export default _default;
|
|
@@ -27,5 +27,5 @@ export interface CategoryProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
27
27
|
};
|
|
28
28
|
key?: string;
|
|
29
29
|
}
|
|
30
|
-
declare const _default:
|
|
30
|
+
declare const _default: any;
|
|
31
31
|
export default _default;
|
|
@@ -7,11 +7,5 @@ export type CreativeModuleDataType = {
|
|
|
7
7
|
theme: 'light' | 'dark';
|
|
8
8
|
span: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
|
|
9
9
|
};
|
|
10
|
-
|
|
11
|
-
data: {
|
|
12
|
-
shape?: 'rounded' | 'square';
|
|
13
|
-
productsTab: CreativeModuleDataType[];
|
|
14
|
-
};
|
|
15
|
-
}
|
|
16
|
-
declare const _default: import("react").ForwardRefExoticComponent<CreativeModuleType & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
10
|
+
declare const _default: any;
|
|
17
11
|
export default _default;
|
|
@@ -7,10 +7,5 @@ export type DownLoadDataType = {
|
|
|
7
7
|
line: Img;
|
|
8
8
|
icon: Img;
|
|
9
9
|
};
|
|
10
|
-
|
|
11
|
-
data: {
|
|
12
|
-
list: DownLoadDataType[];
|
|
13
|
-
};
|
|
14
|
-
}
|
|
15
|
-
declare const _default: import("react").ForwardRefExoticComponent<DownLoadType & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
10
|
+
declare const _default: any;
|
|
16
11
|
export default _default;
|
|
@@ -29,5 +29,5 @@ export interface EvaluateProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
29
29
|
};
|
|
30
30
|
key?: string;
|
|
31
31
|
}
|
|
32
|
-
declare const _default:
|
|
32
|
+
declare const _default: any;
|
|
33
33
|
export default _default;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import type { FaqProps, FaqItem as ItemType, FaqSemanticName } from './types.js';
|
|
1
|
+
import type { FaqItem as ItemType, FaqSemanticName } from './types.js';
|
|
3
2
|
interface FaqItemProps {
|
|
4
3
|
data: ItemType;
|
|
5
4
|
defaultOpen?: boolean;
|
|
@@ -9,6 +8,6 @@ declare const FaqItem: {
|
|
|
9
8
|
({ data, defaultOpen, classNames }: FaqItemProps): import("react/jsx-runtime").JSX.Element;
|
|
10
9
|
displayName: string;
|
|
11
10
|
};
|
|
12
|
-
declare const _default:
|
|
11
|
+
declare const _default: any;
|
|
13
12
|
export default _default;
|
|
14
13
|
export { FaqItem };
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import type { FeatureCardsProps } from './types.js';
|
|
3
|
-
declare const _default: React.ForwardRefExoticComponent<FeatureCardsProps & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
4
2
|
export default _default;
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import type { FeatureShowcaseProps } from './types.js';
|
|
3
|
-
declare const _default: React.ForwardRefExoticComponent<FeatureShowcaseProps & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
4
2
|
export default _default;
|
|
@@ -10,12 +10,5 @@ export type FeaturesDataType = {
|
|
|
10
10
|
textTwo: string;
|
|
11
11
|
icon: Img;
|
|
12
12
|
};
|
|
13
|
-
declare const _default:
|
|
14
|
-
data: {
|
|
15
|
-
title: string;
|
|
16
|
-
img: Img;
|
|
17
|
-
mobileImg: Img;
|
|
18
|
-
list: FeaturesDataType[];
|
|
19
|
-
};
|
|
20
|
-
} & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
13
|
+
declare const _default: any;
|
|
21
14
|
export default _default;
|
|
@@ -1,8 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
data: {
|
|
3
|
-
title: string;
|
|
4
|
-
text: string;
|
|
5
|
-
};
|
|
6
|
-
}
|
|
7
|
-
declare const _default: import("react").ForwardRefExoticComponent<FootChargerType & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
1
|
+
declare const _default: any;
|
|
8
2
|
export default _default;
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
declare const _default: import("react").ForwardRefExoticComponent<FooterNavigationProps & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
1
|
+
declare const _default: any;
|
|
3
2
|
export default _default;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import 'swiper/css';
|
|
3
2
|
import 'swiper/css/navigation';
|
|
4
3
|
import 'swiper/css/pagination';
|
|
5
|
-
|
|
6
|
-
declare const _default: React.ForwardRefExoticComponent<GiftBoxType & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & React.RefAttributes<any>>;
|
|
4
|
+
declare const _default: any;
|
|
7
5
|
export default _default;
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
import type { GiftShelfProps } from './types.js';
|
|
3
|
-
declare const _default: React.ForwardRefExoticComponent<GiftShelfProps & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
4
2
|
export default _default;
|
|
5
3
|
export type { GiftShelfProps, GiftShelfData, GiftShelfItem, GiftShelfProduct, CountdownConfig, ResponsiveBackgroundImage, } from './types.js';
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
import type { GiftTierShelfProps } from './types.js';
|
|
3
|
-
declare const _default: React.ForwardRefExoticComponent<GiftTierShelfProps & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
4
2
|
export default _default;
|
|
5
3
|
export type { GiftTierShelfProps, GiftTierShelfData, GiftTierItem, GiftTierProduct } from './types.js';
|
|
@@ -37,5 +37,5 @@ export interface GraphicProps extends ComponentCommonProps, React.HTMLAttributes
|
|
|
37
37
|
itemTheme?: Theme;
|
|
38
38
|
};
|
|
39
39
|
}
|
|
40
|
-
declare const _default:
|
|
40
|
+
declare const _default: any;
|
|
41
41
|
export default _default;
|
|
@@ -17,6 +17,6 @@ interface GraphicAttractionBlockProps extends React.HTMLAttributes<HTMLElement>
|
|
|
17
17
|
attractionItems?: AttractionItem[];
|
|
18
18
|
};
|
|
19
19
|
}
|
|
20
|
-
declare const _default:
|
|
20
|
+
declare const _default: any;
|
|
21
21
|
export default _default;
|
|
22
22
|
export type { GraphicAttractionBlockProps };
|
|
@@ -8,11 +8,5 @@ export type GraphicMoreDataType = {
|
|
|
8
8
|
fullWidth: 'true' | 'false';
|
|
9
9
|
span: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
|
|
10
10
|
};
|
|
11
|
-
|
|
12
|
-
data: {
|
|
13
|
-
shape?: 'rounded' | 'square';
|
|
14
|
-
productsTab: GraphicMoreDataType[];
|
|
15
|
-
};
|
|
16
|
-
}
|
|
17
|
-
declare const _default: import("react").ForwardRefExoticComponent<GraphicMoreType & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
11
|
+
declare const _default: any;
|
|
18
12
|
export default _default;
|
|
@@ -1,12 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
declare const _default: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLElement> & {
|
|
4
|
-
data: {
|
|
5
|
-
shape?: import("../../types/props").Shape;
|
|
6
|
-
items: ({
|
|
7
|
-
width?: "full" | "half" | "one-third";
|
|
8
|
-
} & Item)[];
|
|
9
|
-
};
|
|
10
|
-
} & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
import type { GraphicOverlayProps } from './types';
|
|
2
|
+
declare const _default: any;
|
|
11
3
|
export default _default;
|
|
12
4
|
export type { GraphicOverlayProps };
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import type { HeaderNavigationProps } from './types.js';
|
|
3
|
-
declare const _default: React.ForwardRefExoticComponent<HeaderNavigationProps & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
4
2
|
export default _default;
|
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import type { HeroBannerProps } from './types.js';
|
|
3
1
|
export type HeroBannerSemanticName = 'root' | 'title' | 'subtitle' | 'buttonGroup' | 'primaryButton' | 'secondaryButton' | 'captionGroup';
|
|
4
|
-
declare const _default:
|
|
5
|
-
classNames?: Partial<Record<HeroBannerSemanticName, string>>;
|
|
6
|
-
} & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
2
|
+
declare const _default: any;
|
|
7
3
|
export default _default;
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import type { ImageTextFeatureProps } from './types.js';
|
|
3
|
-
declare const _default: React.ForwardRefExoticComponent<ImageTextFeatureProps & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
4
2
|
export default _default;
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import type { ImageWithTextProps } from './types.js';
|
|
3
|
-
declare const _default: React.ForwardRefExoticComponent<ImageWithTextProps & React.RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
4
2
|
export default _default;
|
|
@@ -75,5 +75,5 @@ export interface KspProps extends Omit<React.HTMLAttributes<HTMLElement>, 'class
|
|
|
75
75
|
/** 语义化类名配置 */
|
|
76
76
|
classNames?: KspClassNames;
|
|
77
77
|
}
|
|
78
|
-
declare const _default:
|
|
78
|
+
declare const _default: any;
|
|
79
79
|
export default _default;
|
|
@@ -1,12 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import type { DeliveryCustom } from './type';
|
|
3
|
-
declare const _default: import("react").ForwardRefExoticComponent<{
|
|
4
|
-
metafields: any;
|
|
5
|
-
productList: Array<Product & {
|
|
6
|
-
variant: ProductVariant;
|
|
7
|
-
}>;
|
|
8
|
-
variant: ProductVariant;
|
|
9
|
-
onShippingInfoChange: (deliveryCustom: DeliveryCustom) => void;
|
|
10
|
-
className?: string;
|
|
11
|
-
} & Partial<import("../../../../shared/Styles.js").StylesProps & import("../../../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
1
|
+
declare const _default: any;
|
|
12
2
|
export default _default;
|
package/dist/esm/biz-components/Listing/components/ProductCard/ProductDetail/BenefitsTab.d.ts
CHANGED
|
@@ -1,26 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
interface BenefitsTabTextConfig {
|
|
3
|
-
couponCode?: string;
|
|
4
|
-
copyCode?: string;
|
|
5
|
-
copied?: string;
|
|
6
|
-
expired?: string;
|
|
7
|
-
offCoupon?: string;
|
|
8
|
-
offMemberOnly?: string;
|
|
9
|
-
loginNow?: string;
|
|
10
|
-
selectFreeGift?: string;
|
|
11
|
-
bundleSaveUpTo?: string;
|
|
12
|
-
bundleOffer?: string;
|
|
13
|
-
creditsTitle?: string;
|
|
14
|
-
creditsDesc?: string;
|
|
15
|
-
off?: string;
|
|
16
|
-
memberBenefitsNotLogin?: string;
|
|
17
|
-
memberBenefitsNotLoginText?: string;
|
|
18
|
-
forNewMember?: string;
|
|
19
|
-
expressShipping?: string;
|
|
20
|
-
creditsAfterActivation?: string;
|
|
21
|
-
active?: string;
|
|
22
|
-
flexibleInstallment?: string;
|
|
23
|
-
}
|
|
24
2
|
export type ProductBenefitsTabsValueType = 'coupon' | 'membership' | 'pay' | 'installment';
|
|
25
3
|
export type ModalData = {
|
|
26
4
|
needClickAway?: boolean;
|
|
@@ -29,8 +7,5 @@ export type ModalData = {
|
|
|
29
7
|
content?: string;
|
|
30
8
|
domContent?: React.ReactNode;
|
|
31
9
|
};
|
|
32
|
-
|
|
33
|
-
textConfig?: BenefitsTabTextConfig;
|
|
34
|
-
}
|
|
35
|
-
declare const _default: React.ForwardRefExoticComponent<BenefitsTabProps & Partial<import("../../../../../shared/Styles.js").StylesProps & import("../../../../../shared/Styles.js").ContainerProps> & React.RefAttributes<any>>;
|
|
10
|
+
declare const _default: any;
|
|
36
11
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default:
|
|
1
|
+
declare const _default: any;
|
|
2
2
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default:
|
|
1
|
+
declare const _default: any;
|
|
2
2
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default:
|
|
1
|
+
declare const _default: any;
|
|
2
2
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default:
|
|
1
|
+
declare const _default: any;
|
|
2
2
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default:
|
|
1
|
+
declare const _default: any;
|
|
2
2
|
export default _default;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export interface ProductGalleryTabRef {
|
|
2
2
|
scrollToTab: (index: number) => void;
|
|
3
3
|
}
|
|
4
|
-
declare const _default:
|
|
4
|
+
declare const _default: any;
|
|
5
5
|
export default _default;
|
package/dist/esm/biz-components/Listing/components/ProductCard/ProductPaidShipping/index.d.ts
CHANGED
|
@@ -1,12 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import type { DeliveryCustom } from '../../PaidShipping/type.js';
|
|
3
|
-
declare const _default: import("react").ForwardRefExoticComponent<{
|
|
4
|
-
metafields: any;
|
|
5
|
-
productList: Array<Product & {
|
|
6
|
-
variant: ProductVariant;
|
|
7
|
-
}>;
|
|
8
|
-
variant: ProductVariant;
|
|
9
|
-
onShippingInfoChange: (deliveryCustom: DeliveryCustom) => void;
|
|
10
|
-
className?: string;
|
|
11
|
-
} & Partial<import("../../../../../shared/Styles.js").StylesProps & import("../../../../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
1
|
+
declare const _default: any;
|
|
12
2
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default:
|
|
1
|
+
declare const _default: any;
|
|
2
2
|
export default _default;
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
declare const _default: import("react").ForwardRefExoticComponent<PurchaseBarProps & Partial<import("../../../../shared/Styles.js").StylesProps & import("../../../../shared/Styles.js").ContainerProps> & import("react").RefAttributes<any>>;
|
|
1
|
+
declare const _default: any;
|
|
3
2
|
export default _default;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type {
|
|
3
|
-
import { type SwiperRef } from 'swiper/react';
|
|
2
|
+
import type { MarqueeItemProps, MarqueeImageContentProps, MarqueeTextContentProps } from './type.js';
|
|
4
3
|
declare const MarqueeItem: {
|
|
5
4
|
({ data, configuration }: MarqueeItemProps): import("react/jsx-runtime").JSX.Element;
|
|
6
5
|
displayName: string;
|
|
@@ -10,6 +9,6 @@ declare const MarqueeImageContent: {
|
|
|
10
9
|
displayName: string;
|
|
11
10
|
};
|
|
12
11
|
declare const MarqueeTextContent: React.ForwardRefExoticComponent<MarqueeTextContentProps & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
-
declare const _default:
|
|
12
|
+
declare const _default: any;
|
|
14
13
|
export default _default;
|
|
15
14
|
export { MarqueeItem, MarqueeImageContent, MarqueeTextContent };
|
|
@@ -33,5 +33,5 @@ export interface MarqueeReviewProps extends React.HTMLAttributes<HTMLElement> {
|
|
|
33
33
|
/** 评论数据 */
|
|
34
34
|
data: MarqueeReviewData;
|
|
35
35
|
}
|
|
36
|
-
declare const _default:
|
|
36
|
+
declare const _default: any;
|
|
37
37
|
export default _default;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
1
|
import 'swiper/css/pagination';
|
|
3
2
|
import type { MediaEndorsementProps, MediaEndorsementData, MediaEndorsementItem, MediaEndorsementSemanticName } from './types.js';
|
|
4
|
-
declare const _default:
|
|
3
|
+
declare const _default: any;
|
|
5
4
|
export default _default;
|
|
6
5
|
export type { MediaEndorsementProps, MediaEndorsementData, MediaEndorsementItem, MediaEndorsementSemanticName };
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
declare const _default: import("react").ForwardRefExoticComponent<MediaPlayerBaseProps & import("react").RefAttributes<HTMLDivElement> & Partial<import("../../shared/Styles.js").StylesProps & import("../../shared/Styles.js").ContainerProps>>;
|
|
1
|
+
declare const _default: any;
|
|
3
2
|
export default _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";import{Fragment as Ne,jsx as e,jsxs as p}from"react/jsx-runtime";import{useState as v,useRef as r,useMemo as ye,useEffect as S,forwardRef as xe,useImperativeHandle as he}from"react";import{debounce as be}from"lodash";import{cn as i}from"../../helpers/utils.js";import{withLayout as we}from"../../shared/Styles.js";import X from"../../components/button.js";import{VideoModal as He}from"../VideoModal/index.js";import{convertLexicalToHTML as Z}from"@payloadcms/richtext-lexical/html";import{useInView as Te}from"react-intersection-observer";import{useExposure as ke}from"../../hooks/useExposure.js";import A from"../../helpers/ScrollLoadVideo.js";import{gsap as d}from"gsap";import{SplitText as ee}from"gsap/dist/SplitText";import{ScrollTrigger as V}from"gsap/dist/ScrollTrigger";const Me="media_player_base",Le="video";d.registerPlugin(V,ee);const te=({defaultConverters:y})=>({...y,text:L=>{const{node:t}=L;return t.$&&t.$.color?`<span class="lexical-${t.$.color}">${t.text}</span>`:t.text}}),re=xe(({className:y="",id:L,onBtnClick:t,data:{title:x,videoTitle:h,btnText:b,youtubeId:_,video:$,mobileVideo:ne,theme:B,img:C,shape:D,titleAnimation:w="fade-in",...oe},...F},se)=>{const{sticky:n}=oe,[j,q]=v(!1),[U,le]=v(0),[ie,ae]=v(0),[H,ce]=v(0),[Y,N]=v(!1),T=r(null),O=r(null),o=r(null),k=r(null),G=r(null),M=r(null),u=r(null),R=r(null),I=r(null),{ref:de,inView:s}=Te();he(se,()=>o.current);const m=typeof x=="string"?x:x&&Z({data:x,converters:te}),J=typeof h=="string"?h:h&&Z({data:h,converters:te});S(()=>{s?(T.current?.play(),q(!0)):(T.current?.pause(),q(!1))},[s]);const z=be(()=>{if(o.current){const f=o.current.getBoundingClientRect(),a=window.innerHeight,g=window.scrollY||window.pageYOffset,l=f.bottom+g,c=document.documentElement.scrollHeight-l;le(c>a?a:c)}if(o.current){const f=o.current.clientHeight,a=window.innerHeight;ae(f+a)}},600);S(()=>(z(),window.addEventListener("resize",z),()=>{window.removeEventListener("resize",z)}),[]),S(()=>{function f(){if(!k.current||w!=="fade-in")return;const g=k.current?.clientHeight||80;M.current=new ee(k.current,{type:"words",wordsClass:"word"});const l=M.current.words;d.set(l,{opacity:0}),u.current&&d.set(u.current,{opacity:0}),R.current=V.create({trigger:o.current,start:"top center-=10%",end:`top+=${g*1.5+80}px center-=10%`,scrub:!0,onUpdate:K=>{const c=K.progress,Q=l.length,ue=1/Q,W=.5;l.forEach((me,fe)=>{const ge=fe/Q*(1-W),ve=ue*(1+W);let P=(c-ge)/ve;P=Math.max(0,Math.min(P,1)),d.set(me,{opacity:P})}),d.set(O.current,{opacity:c}),u.current&&d.set(u.current,{opacity:c>=.6?1:0})}})}function a(){I.current=V.create({trigger:o.current,start:"bottom bottom",end:"bottom top",scrub:!0,onUpdate:g=>{const l=g.progress;ce(l)}})}return s&&(f(),a()),()=>{M.current&&M.current.revert(),R.current&&R.current.kill(),I.current&&I.current.kill()}},[w,s]),ke(G,{componentType:Le,componentName:Me,componentTitle:m});const pe=ye(()=>s&&H>0&&H<.9?3:s?2:1,[H,s]),E="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]";return p(Ne,{children:[n&&e("div",{...F,ref:o,className:i("pointer-events-none relative z-10",E,{"aiui-dark":B==="dark","rounded-box":D==="rounded"},y),children:e("div",{ref:de,children:!w&&p("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",children:[m&&!j&&e("div",{className:"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl",dangerouslySetInnerHTML:{__html:m}}),J&&j&&e("div",{className:"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl",dangerouslySetInnerHTML:{__html:J}}),b&&e(X,{variant:"link",className:i("member-equity-button-secondary text-info-primary"),onClick:()=>{N(!0),t&&t?.()},children:b})]})})}),p("div",{...n?{}:F,style:n?{marginBottom:`-${U}px`,marginTop:`-${ie}px`,zIndex:pe}:{zIndex:5},className:i("relative",y),children:[e("div",{className:"sticky top-0 ",children:p("div",{id:L,className:i("relative overflow-hidden",n?"h-screen w-full":E,{"aiui-dark":B==="dark","rounded-box":D==="rounded"}),children:[w==="fade-in"&&p("div",{className:i("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":"left-0 top-0"),children:[m&&e("div",{ref:k,className:"media-player-base-title lg-desktop:text-[64px] text-info-primary text-[40px] font-bold leading-none lg:text-5xl",dangerouslySetInnerHTML:{__html:m}}),b&&e(X,{ref:u,variant:"link",className:i("media-player-base-button member-equity-button-secondary text-info-primary"),onClick:()=>{N(!0),t&&t?.()},children:b})]}),p("div",{className:"media-cover left-0 top-0 h-screen w-screen overflow-hidden",style:{height:`${102-H*100}vh`},children:[e(A,{videoRef:T,poster:C?.url||"",src:$?.url,className:"tablet:block hidden size-full !h-auto",videoClassName:"object-cover",muted:!0,loop:!0,playsInline:!0,autoplay:!0,"webkit-playsinline"
|
|
1
|
+
"use client";import{Fragment as Ne,jsx as e,jsxs as p}from"react/jsx-runtime";import{useState as v,useRef as r,useMemo as ye,useEffect as S,forwardRef as xe,useImperativeHandle as he}from"react";import{debounce as be}from"lodash";import{cn as i}from"../../helpers/utils.js";import{withLayout as we}from"../../shared/Styles.js";import X from"../../components/button.js";import{VideoModal as He}from"../VideoModal/index.js";import{convertLexicalToHTML as Z}from"@payloadcms/richtext-lexical/html";import{useInView as Te}from"react-intersection-observer";import{useExposure as ke}from"../../hooks/useExposure.js";import A from"../../helpers/ScrollLoadVideo.js";import{gsap as d}from"gsap";import{SplitText as ee}from"gsap/dist/SplitText";import{ScrollTrigger as V}from"gsap/dist/ScrollTrigger";const Me="media_player_base",Le="video";d.registerPlugin(V,ee);const te=({defaultConverters:y})=>({...y,text:L=>{const{node:t}=L;return t.$&&t.$.color?`<span class="lexical-${t.$.color}">${t.text}</span>`:t.text}}),re=xe(({className:y="",id:L,onBtnClick:t,data:{title:x,videoTitle:h,btnText:b,youtubeId:_,video:$,mobileVideo:ne,theme:B,img:C,shape:D,titleAnimation:w="fade-in",...oe},...F},se)=>{const{sticky:n}=oe,[j,q]=v(!1),[U,le]=v(0),[ie,ae]=v(0),[H,ce]=v(0),[Y,N]=v(!1),T=r(null),O=r(null),o=r(null),k=r(null),G=r(null),M=r(null),u=r(null),R=r(null),I=r(null),{ref:de,inView:s}=Te();he(se,()=>o.current);const m=typeof x=="string"?x:x&&Z({data:x,converters:te}),J=typeof h=="string"?h:h&&Z({data:h,converters:te});S(()=>{s?(T.current?.play(),q(!0)):(T.current?.pause(),q(!1))},[s]);const z=be(()=>{if(o.current){const f=o.current.getBoundingClientRect(),a=window.innerHeight,g=window.scrollY||window.pageYOffset,l=f.bottom+g,c=document.documentElement.scrollHeight-l;le(c>a?a:c)}if(o.current){const f=o.current.clientHeight,a=window.innerHeight;ae(f+a)}},600);S(()=>(z(),window.addEventListener("resize",z),()=>{window.removeEventListener("resize",z)}),[]),S(()=>{function f(){if(!k.current||w!=="fade-in")return;const g=k.current?.clientHeight||80;M.current=new ee(k.current,{type:"words",wordsClass:"word"});const l=M.current.words;d.set(l,{opacity:0}),u.current&&d.set(u.current,{opacity:0}),R.current=V.create({trigger:o.current,start:"top center-=10%",end:`top+=${g*1.5+80}px center-=10%`,scrub:!0,onUpdate:K=>{const c=K.progress,Q=l.length,ue=1/Q,W=.5;l.forEach((me,fe)=>{const ge=fe/Q*(1-W),ve=ue*(1+W);let P=(c-ge)/ve;P=Math.max(0,Math.min(P,1)),d.set(me,{opacity:P})}),d.set(O.current,{opacity:c}),u.current&&d.set(u.current,{opacity:c>=.6?1:0})}})}function a(){I.current=V.create({trigger:o.current,start:"bottom bottom",end:"bottom top",scrub:!0,onUpdate:g=>{const l=g.progress;ce(l)}})}return s&&(f(),a()),()=>{M.current&&M.current.revert(),R.current&&R.current.kill(),I.current&&I.current.kill()}},[w,s]),ke(G,{componentType:Le,componentName:Me,componentTitle:m});const pe=ye(()=>s&&H>0&&H<.9?3:s?2:1,[H,s]),E="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]";return p(Ne,{children:[n&&e("div",{...F,ref:o,className:i("pointer-events-none relative z-10",E,{"aiui-dark":B==="dark","rounded-box":D==="rounded"},y),children:e("div",{ref:de,children:!w&&p("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",children:[m&&!j&&e("div",{className:"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl",dangerouslySetInnerHTML:{__html:m}}),J&&j&&e("div",{className:"lg-desktop:text-[64px] text-info-primary text-center text-[40px] font-bold leading-none lg:text-5xl",dangerouslySetInnerHTML:{__html:J}}),b&&e(X,{variant:"link",className:i("member-equity-button-secondary text-info-primary"),onClick:()=>{N(!0),t&&t?.()},children:b})]})})}),p("div",{...n?{}:F,style:n?{marginBottom:`-${U}px`,marginTop:`-${ie}px`,zIndex:pe}:{zIndex:5},className:i("relative",y),children:[e("div",{className:"sticky top-0 ",children:p("div",{id:L,className:i("relative overflow-hidden",n?"h-screen w-full":E,{"aiui-dark":B==="dark","rounded-box":D==="rounded"}),children:[w==="fade-in"&&p("div",{className:i("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":"left-0 top-0"),children:[m&&e("div",{ref:k,className:"media-player-base-title lg-desktop:text-[64px] text-info-primary text-[40px] font-bold leading-none lg:text-5xl",dangerouslySetInnerHTML:{__html:m}}),b&&e(X,{ref:u,variant:"link",className:i("media-player-base-button member-equity-button-secondary text-info-primary"),onClick:()=>{N(!0),t&&t?.()},children:b})]}),p("div",{className:"media-cover left-0 top-0 h-screen w-screen overflow-hidden",style:{height:`${102-H*100}vh`},children:[e(A,{videoRef:T,poster:C?.url||"",src:$?.url,className:"tablet:block hidden size-full !h-auto",videoClassName:"object-cover",muted:!0,loop:!0,playsInline:!0,autoplay:!0,"webkit-playsinline":!0,"x5-playsinline":!0}),e(A,{videoRef:T,poster:C?.url||"",src:ne?.url||$?.url,className:"tablet:hidden block min-h-screen w-full",videoClassName:"object-cover w-full h-auto",muted:!0,loop:!0,playsInline:!0,autoplay:!0,"webkit-playsinline":!0,"x5-playsinline":!0}),e("div",{ref:O,className:"absolute left-0 top-0 z-10 size-full opacity-0",style:{background:"rgba(0, 0, 0, 0.2)"}})]})]})}),n&&e("div",{className:i(n&&"pointer-events-none relative box-content block",E),style:n?{height:`${U}px`}:{},ref:G})]}),Y&&_&&e(He,{visible:Y,youTubeId:_,onCloseModal:()=>N(!1)})]})});re.displayName="MediaPlayerBase";var je=we(re);export{je as default};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|