@anker-in/headless-ui 1.0.9-alpha.1753347288191 → 1.0.9-temp-1

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 (113) hide show
  1. package/dist/cjs/apps/playground/utils/classnames.d.ts +1 -0
  2. package/dist/cjs/biz-components/AccordionCards/useDebounce.d.ts +6 -0
  3. package/dist/cjs/biz-components/Graphic/index.js +1 -1
  4. package/dist/cjs/biz-components/Graphic/index.js.map +3 -3
  5. package/dist/cjs/biz-components/MediaPlayerMulti/YouTubePlayer.d.ts +3 -0
  6. package/dist/cjs/biz-components/SectionHeading/SectionHeading.d.ts +4 -0
  7. package/dist/cjs/biz-components/SectionHeading/index.d.ts +0 -0
  8. package/dist/cjs/biz-components/SectionHeading/types.d.ts +6 -0
  9. package/dist/cjs/biz-components/Shelf/Shelf.d.ts +8 -0
  10. package/dist/cjs/biz-components/Shelf/index.d.ts +1 -0
  11. package/dist/cjs/biz-components/Shelf/types.d.ts +6 -0
  12. package/dist/cjs/biz-components/ShelfDisplay/tab.d.ts +7 -0
  13. package/dist/cjs/components/col.d.ts +29 -0
  14. package/dist/cjs/components/dropdown.d.ts +27 -0
  15. package/dist/cjs/components/inputnumber.d.ts +0 -0
  16. package/dist/cjs/components/row.d.ts +18 -0
  17. package/dist/cjs/helpers/get-subtree.d.ts +12 -0
  18. package/dist/cjs/packages/ui/src/components/avatar.d.ts +26 -0
  19. package/dist/cjs/packages/ui/src/components/index.d.ts +20 -0
  20. package/dist/cjs/packages/ui/src/index.d.ts +1 -0
  21. package/dist/cjs/packages/ui/src/stories/avatar.stories.d.ts +40 -0
  22. package/dist/cjs/packages/ui/src/stories/badge.stories.d.ts +26 -0
  23. package/dist/cjs/packages/ui/src/stories/button.stories.d.ts +48 -0
  24. package/dist/cjs/packages/ui/src/stories/checkbox.stories.d.ts +46 -0
  25. package/dist/cjs/packages/ui/src/stories/container.stories.d.ts +36 -0
  26. package/dist/cjs/packages/ui/src/stories/dialog.stories.d.ts +20 -0
  27. package/dist/cjs/packages/ui/src/stories/grid.stories.d.ts +42 -0
  28. package/dist/cjs/packages/ui/src/stories/heading.stories.d.ts +82 -0
  29. package/dist/cjs/packages/ui/src/stories/input.stories.d.ts +35 -0
  30. package/dist/cjs/packages/ui/src/stories/picture.stories.d.ts +18 -0
  31. package/dist/cjs/packages/ui/src/stories/popover.stories.d.ts +17 -0
  32. package/dist/cjs/packages/ui/src/stories/radio.stories.d.ts +39 -0
  33. package/dist/cjs/packages/ui/src/stories/skeleton.stories.d.ts +20 -0
  34. package/dist/cjs/packages/ui/src/stories/text.stories.d.ts +94 -0
  35. package/dist/cjs/src/components/index.d.ts +21 -0
  36. package/dist/cjs/src/components/input-number.d.ts +47 -0
  37. package/dist/cjs/src/index.d.ts +1 -0
  38. package/dist/cjs/src/stories/avatar.stories.d.ts +40 -0
  39. package/dist/cjs/src/stories/badge.stories.d.ts +26 -0
  40. package/dist/cjs/src/stories/button.stories.d.ts +48 -0
  41. package/dist/cjs/src/stories/checkbox.stories.d.ts +46 -0
  42. package/dist/cjs/src/stories/container.stories.d.ts +36 -0
  43. package/dist/cjs/src/stories/dialog.stories.d.ts +20 -0
  44. package/dist/cjs/src/stories/grid.stories.d.ts +42 -0
  45. package/dist/cjs/src/stories/heading.stories.d.ts +82 -0
  46. package/dist/cjs/src/stories/input-number.stories.d.ts +51 -0
  47. package/dist/cjs/src/stories/input.stories.d.ts +35 -0
  48. package/dist/cjs/src/stories/picture.stories.d.ts +18 -0
  49. package/dist/cjs/src/stories/popover.stories.d.ts +17 -0
  50. package/dist/cjs/src/stories/radio.stories.d.ts +39 -0
  51. package/dist/cjs/src/stories/skeleton.stories.d.ts +20 -0
  52. package/dist/cjs/src/stories/text.stories.d.ts +94 -0
  53. package/dist/cjs/stories/shelf.stories.d.ts +17 -0
  54. package/dist/cjs/tailwind.config.d.ts +253 -0
  55. package/dist/cjs/tsconfig.tsbuildinfo +1 -0
  56. package/dist/esm/apps/playground/utils/classnames.d.ts +1 -0
  57. package/dist/esm/biz-components/AccordionCards/useDebounce.d.ts +6 -0
  58. package/dist/esm/biz-components/Graphic/index.js +1 -1
  59. package/dist/esm/biz-components/Graphic/index.js.map +3 -3
  60. package/dist/esm/biz-components/MediaPlayerMulti/YouTubePlayer.d.ts +3 -0
  61. package/dist/esm/biz-components/SectionHeading/SectionHeading.d.ts +4 -0
  62. package/dist/esm/biz-components/SectionHeading/index.d.ts +0 -0
  63. package/dist/esm/biz-components/SectionHeading/types.d.ts +6 -0
  64. package/dist/esm/biz-components/Shelf/Shelf.d.ts +8 -0
  65. package/dist/esm/biz-components/Shelf/index.d.ts +1 -0
  66. package/dist/esm/biz-components/Shelf/types.d.ts +6 -0
  67. package/dist/esm/biz-components/ShelfDisplay/tab.d.ts +7 -0
  68. package/dist/esm/components/col.d.ts +29 -0
  69. package/dist/esm/components/dropdown.d.ts +27 -0
  70. package/dist/esm/components/inputnumber.d.ts +0 -0
  71. package/dist/esm/components/row.d.ts +18 -0
  72. package/dist/esm/helpers/get-subtree.d.ts +12 -0
  73. package/dist/esm/packages/ui/src/components/avatar.d.ts +26 -0
  74. package/dist/esm/packages/ui/src/components/index.d.ts +20 -0
  75. package/dist/esm/packages/ui/src/index.d.ts +1 -0
  76. package/dist/esm/packages/ui/src/stories/avatar.stories.d.ts +40 -0
  77. package/dist/esm/packages/ui/src/stories/badge.stories.d.ts +26 -0
  78. package/dist/esm/packages/ui/src/stories/button.stories.d.ts +48 -0
  79. package/dist/esm/packages/ui/src/stories/checkbox.stories.d.ts +46 -0
  80. package/dist/esm/packages/ui/src/stories/container.stories.d.ts +36 -0
  81. package/dist/esm/packages/ui/src/stories/dialog.stories.d.ts +20 -0
  82. package/dist/esm/packages/ui/src/stories/grid.stories.d.ts +42 -0
  83. package/dist/esm/packages/ui/src/stories/heading.stories.d.ts +82 -0
  84. package/dist/esm/packages/ui/src/stories/input.stories.d.ts +35 -0
  85. package/dist/esm/packages/ui/src/stories/picture.stories.d.ts +18 -0
  86. package/dist/esm/packages/ui/src/stories/popover.stories.d.ts +17 -0
  87. package/dist/esm/packages/ui/src/stories/radio.stories.d.ts +39 -0
  88. package/dist/esm/packages/ui/src/stories/skeleton.stories.d.ts +20 -0
  89. package/dist/esm/packages/ui/src/stories/text.stories.d.ts +94 -0
  90. package/dist/esm/src/components/index.d.ts +21 -0
  91. package/dist/esm/src/components/input-number.d.ts +47 -0
  92. package/dist/esm/src/index.d.ts +1 -0
  93. package/dist/esm/src/stories/avatar.stories.d.ts +40 -0
  94. package/dist/esm/src/stories/badge.stories.d.ts +26 -0
  95. package/dist/esm/src/stories/button.stories.d.ts +48 -0
  96. package/dist/esm/src/stories/checkbox.stories.d.ts +46 -0
  97. package/dist/esm/src/stories/container.stories.d.ts +36 -0
  98. package/dist/esm/src/stories/dialog.stories.d.ts +20 -0
  99. package/dist/esm/src/stories/grid.stories.d.ts +42 -0
  100. package/dist/esm/src/stories/heading.stories.d.ts +82 -0
  101. package/dist/esm/src/stories/input-number.stories.d.ts +51 -0
  102. package/dist/esm/src/stories/input.stories.d.ts +35 -0
  103. package/dist/esm/src/stories/picture.stories.d.ts +18 -0
  104. package/dist/esm/src/stories/popover.stories.d.ts +17 -0
  105. package/dist/esm/src/stories/radio.stories.d.ts +39 -0
  106. package/dist/esm/src/stories/skeleton.stories.d.ts +20 -0
  107. package/dist/esm/src/stories/text.stories.d.ts +94 -0
  108. package/dist/esm/stories/shelf.stories.d.ts +17 -0
  109. package/dist/esm/tailwind.config.d.ts +253 -0
  110. package/dist/esm/tsconfig.tsbuildinfo +1 -0
  111. package/package.json +1 -1
  112. /package/dist/cjs/hooks/{useExposure.d.ts → useEXposure.d.ts} +0 -0
  113. /package/dist/esm/hooks/{useExposure.d.ts → useEXposure.d.ts} +0 -0
@@ -0,0 +1 @@
1
+ export declare function classNames(...arr: unknown[]): string;
@@ -0,0 +1,6 @@
1
+ type DebounceOptions = {
2
+ leading?: boolean;
3
+ trailing?: boolean;
4
+ };
5
+ export declare function useDebounce<T extends any[]>(func: (...args: T) => void, delay?: number, options?: DebounceOptions): (...args: T) => void;
6
+ export {};
@@ -1,2 +1,2 @@
1
- "use strict";"use client";var H=Object.create;var m=Object.defineProperty;var I=Object.getOwnPropertyDescriptor;var L=Object.getOwnPropertyNames;var D=Object.getPrototypeOf,U=Object.prototype.hasOwnProperty;var R=(e,s)=>{for(var l in s)m(e,l,{get:s[l],enumerable:!0})},v=(e,s,l,a)=>{if(s&&typeof s=="object"||typeof s=="function")for(let o of L(s))!U.call(e,o)&&o!==l&&m(e,o,{get:()=>s[o],enumerable:!(a=I(s,o))||a.enumerable});return e};var f=(e,s,l)=>(l=e!=null?H(D(e)):{},v(s||!e||!e.__esModule?m(l,"default",{value:e,enumerable:!0}):l,e)),$=e=>v(m({},"__esModule",{value:!0}),e);var q={};R(q,{default:()=>j});module.exports=$(q);var t=require("react/jsx-runtime"),i=f(require("react")),d=require("../../helpers/utils.js"),k=require("../../shared/Styles.js"),T=f(require("../SwiperBox/index.js")),h=require("../../components/index.js"),u=require("../../components/index.js"),M=f(require("../Title/index.js")),N=require("react-responsive"),P=require("../VideoModal/index.js"),V=require("../../hooks/useExposure.js"),w=require("../../shared/trackUrlRef.js");const g="image",b="graphic",z=({data:e,configuration:s})=>{const l=(0,N.useMediaQuery)({query:"(max-width: 768px)"});return(0,t.jsx)("div",{className:(0,d.cn)((()=>{switch(s.num){case 1:return"tablet:aspect-w-[704] tablet:aspect-h-[400] laptop:aspect-w-[896] laptop:aspect-h-[384] desktop:aspect-w-[1312] desktop:aspect-h-[512] lg-desktop:aspect-w-[1664] lg-desktop:aspect-h-[640]";case 2:return"tablet:aspect-w-[346] tablet:aspect-h-[360] laptop:aspect-w-[440] laptop:aspect-h-[360] desktop:aspect-w-[648] desktop:aspect-h-[384] lg-desktop:aspect-w-[824] lg-desktop:aspect-h-[480]";case 3:return"tablet:aspect-w-[296] laptop:aspect-w-[288] laptop:aspect-h-[360] desktop:aspect-w-[427] desktop:aspect-h-[384] lg-desktop:aspect-w-[544] lg-desktop:aspect-h-[480]";default:return"tablet:aspect-w-[296] laptop:aspect-w-[288] laptop:aspect-h-[360] desktop:aspect-w-[316] desktop:aspect-h-[384] lg-desktop:aspect-w-[404] lg-desktop:aspect-h-[480]"}})(),"laptop:h-auto text-info-primary flex-1 shrink-0 md:basis-[296px]",{"aiui-dark":e.theme==="dark","h-[360px]":l}),children:(0,t.jsx)("div",{className:(0,d.cn)("absolute inset-0",{"rounded-xl overflow-hidden laptop:rounded-2xl":s?.itemShape==="round"}),children:(0,t.jsxs)("a",{"aria-label":e?.title??e?.description,href:(0,w.trackUrlRef)(e?.href,`${g}_${b}`),className:"relative block size-full cursor-pointer overflow-hidden",children:[(0,t.jsx)(u.Picture,{className:"h-full",imgClassName:"h-full object-cover tablet:hover:scale-110 transition-all duration-300",source:e?.imgUrl?.url,alt:e?.imgUrl?.alt||""}),(0,t.jsxs)("div",{className:"laptop:p-6 absolute bottom-0 z-[1] box-border flex w-full flex-col p-4",children:[(0,t.jsx)(u.Text,{style:{color:e?.textColor},html:e?.title,className:"graphic-title line-clamp-3 lg-desktop:text-[18px] desktop:text-[16px] text-[14px] font-bold leading-[1.2]"}),(0,t.jsxs)("div",{className:"flex items-end justify-between",children:[(0,t.jsx)("div",{className:"flex-1",children:e?.description&&(0,t.jsx)(h.Heading,{html:e?.description,style:{color:e?.textColor},as:"h3",className:"graphic-description lg-desktop:text-[32px] desktop:mt-2 desktop:text-[24px] text-lines-2 mt-1 line-clamp-3 flex-1 text-[24px] font-bold leading-[1.2]"})}),(e?.video?.url||e?.youtubeId)&&(0,t.jsx)("button",{"aria-label":"Play Video",onClick:o=>{o.preventDefault(),o.stopPropagation(),s?.onVideoPlayBtnClick?.(s?.index||0,e)},className:"laptop:size-12 flex size-10 items-center justify-center rounded-full bg-white bg-opacity-20 hover:bg-black/75",children:(0,t.jsx)("svg",{width:"12",height:"14",viewBox:"0 0 12 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,t.jsx)("path",{d:"M12 7L0 14L0 0L12 7Z",fill:"white"})})})]}),e.buttonText&&(0,t.jsx)(h.Button,{"aria-label":e?.title??e?.description,variant:"secondary",className:"desktop:mt-[24px] mt-[12px] self-start",as:"a",href:(0,w.trackUrlRef)(e?.href,`${g}_${b}`),children:e.buttonText})]})]})})})},y=i.default.forwardRef(({data:e,className:s,...l},a)=>{const o=(0,i.useRef)(null),[C,x]=(0,i.useState)(!1),[B,G]=(0,i.useState)(""),[S,E]=(0,i.useState)(""),c=r=>{const p=e?.items?.length>3,n=e?.items?.length>2;switch(r){case 1440:return p?4:e?.items?.length;case 1024:return p?3:e?.items?.length;case 768:return p||n?2.3:2;default:return 1.2}};return(0,i.useImperativeHandle)(a,()=>o.current),(0,V.useExposure)(o,{componentType:g,componentName:b,componentTitle:e?.title}),(0,i.useEffect)(()=>{const r=o.current?.querySelectorAll(".graphic-description");if(r&&r.length>0){let p=0;r.forEach(n=>{p=Math.max(p,n.offsetHeight)}),r.forEach(n=>{n.style.height=`${p}px`})}},[]),(0,t.jsxs)("div",{className:s,ref:o,children:[(0,t.jsxs)("div",{className:"graphic-box",children:[e?.title&&(0,t.jsx)(M.default,{data:{title:e?.title}}),(0,t.jsx)(T.default,{id:"Graphic",className:(0,d.cn)("!overflow-visible"),data:{list:e?.items||[],configuration:{itemShape:e.itemShape,num:e?.items?.length||0,onVideoPlayBtnClick:(r,p)=>{x(!0),p?.isYouTube?E?.(p?.youtubeId||""):G?.(p?.video?.url||"")}}},Slide:z,breakpoints:{0:{spaceBetween:12,freeMode:!1,slidesPerView:1},374:{spaceBetween:12,freeMode:!1,slidesPerView:c()},768:{spaceBetween:16,freeMode:!1,slidesPerView:c(768)},1024:{spaceBetween:16,freeMode:!1,slidesPerView:c(1024)},1440:{spaceBetween:16,freeMode:!1,slidesPerView:c(1440)}}})]}),(0,t.jsx)(P.VideoModal,{visible:C,youTubeId:S,videoUrl:B,onCloseModal:()=>x(!1)})]})});y.displayName="Graphic";var j=(0,k.withLayout)(y);
1
+ "use strict";"use client";var I=Object.create;var d=Object.defineProperty;var L=Object.getOwnPropertyDescriptor;var D=Object.getOwnPropertyNames;var U=Object.getPrototypeOf,z=Object.prototype.hasOwnProperty;var R=(e,s)=>{for(var l in s)d(e,l,{get:s[l],enumerable:!0})},y=(e,s,l,p)=>{if(s&&typeof s=="object"||typeof s=="function")for(let r of D(s))!z.call(e,r)&&r!==l&&d(e,r,{get:()=>s[r],enumerable:!(p=L(s,r))||p.enumerable});return e};var b=(e,s,l)=>(l=e!=null?I(U(e)):{},y(s||!e||!e.__esModule?d(l,"default",{value:e,enumerable:!0}):l,e)),$=e=>y(d({},"__esModule",{value:!0}),e);var A={};R(A,{default:()=>q});module.exports=$(A);var t=require("react/jsx-runtime"),i=b(require("react")),h=require("../../helpers/utils.js"),T=require("../../shared/Styles.js"),M=b(require("../SwiperBox/index.js")),u=require("../../components/index.js"),f=require("../../components/index.js"),N=b(require("../Title/index.js")),P=require("react-responsive"),V=require("../VideoModal/index.js"),C=require("../../hooks/useExposure.js"),x=require("../../shared/trackUrlRef.js");const g="image",w="graphic",j=({data:e,configuration:s})=>(0,t.jsx)("div",{className:(0,h.cn)((()=>{switch(s.num){case 1:return"tablet:aspect-w-[704] tablet:aspect-h-[400] laptop:aspect-w-[896] laptop:aspect-h-[384] desktop:aspect-w-[1312] desktop:aspect-h-[512] lg-desktop:aspect-w-[1664] lg-desktop:aspect-h-[640]";case 2:return"tablet:aspect-w-[346] tablet:aspect-h-[360] laptop:aspect-w-[440] laptop:aspect-h-[360] desktop:aspect-w-[648] desktop:aspect-h-[384] lg-desktop:aspect-w-[824] lg-desktop:aspect-h-[480]";case 3:return"tablet:aspect-w-[296] tablet:aspect-h-[360] laptop:aspect-w-[288] laptop:aspect-h-[360] desktop:aspect-w-[427] desktop:aspect-h-[384] lg-desktop:aspect-w-[544] lg-desktop:aspect-h-[480]";default:return"tablet:aspect-w-[296] tablet:aspect-h-[360] laptop:aspect-w-[288] laptop:aspect-h-[360] desktop:aspect-w-[316] desktop:aspect-h-[384] lg-desktop:aspect-w-[404] lg-desktop:aspect-h-[480]"}})(),"laptop:h-auto text-info-primary flex-1 shrink-0 md:basis-[296px]",{"aiui-dark":e.theme==="dark","h-[360px]":s?.isMobile}),children:(0,t.jsx)("div",{className:(0,h.cn)("absolute inset-0",{"rounded-xl overflow-hidden laptop:rounded-2xl":s?.itemShape==="round"}),children:(0,t.jsxs)("a",{"aria-label":e?.title??e?.description,href:(0,x.trackUrlRef)(e?.href,`${g}_${w}`),className:"relative block size-full cursor-pointer overflow-hidden",children:[(0,t.jsx)(f.Picture,{className:"h-full",imgClassName:"h-full object-cover tablet:hover:scale-110 transition-all duration-300",source:e?.imgUrl?.url,alt:e?.imgUrl?.alt||""}),(0,t.jsxs)("div",{className:"laptop:p-6 absolute bottom-0 z-[1] box-border flex w-full flex-col p-4",children:[(0,t.jsx)(f.Text,{style:{color:e?.textColor},html:e?.title,className:"graphic-title line-clamp-3 lg-desktop:text-[18px] desktop:text-[16px] text-[14px] font-bold leading-[1.2]"}),(0,t.jsxs)("div",{className:"flex items-end justify-between",children:[(0,t.jsx)("div",{className:"flex-1",children:e?.description&&(0,t.jsx)(u.Heading,{html:e?.description,style:{color:e?.textColor},as:"h3",className:"graphic-description lg-desktop:text-[32px] desktop:mt-2 desktop:text-[24px] text-lines-2 mt-1 line-clamp-3 flex-1 text-[24px] font-bold leading-[1.2]"})}),(e?.video?.url||e?.youtubeId)&&(0,t.jsx)("button",{"aria-label":"Play Video",onClick:p=>{p.preventDefault(),p.stopPropagation(),s?.onVideoPlayBtnClick?.(s?.index||0,e)},className:"laptop:size-12 flex size-10 items-center justify-center rounded-full bg-white bg-opacity-20 hover:bg-black/75",children:(0,t.jsx)("svg",{width:"12",height:"14",viewBox:"0 0 12 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,t.jsx)("path",{d:"M12 7L0 14L0 0L12 7Z",fill:"white"})})})]}),e.buttonText&&(0,t.jsx)(u.Button,{"aria-label":e?.title??e?.description,variant:"secondary",className:"desktop:mt-[24px] mt-[12px] self-start",as:"a",href:(0,x.trackUrlRef)(e?.href,`${g}_${w}`),children:e.buttonText})]})]})})}),k=i.default.forwardRef(({data:e,className:s,...l},p)=>{const r=(0,P.useMediaQuery)({query:"(max-width: 768px)"}),c=(0,i.useRef)(null),[S,v]=(0,i.useState)(!1),[B,G]=(0,i.useState)(""),[E,H]=(0,i.useState)(""),m=a=>{const o=e?.items?.length>3,n=e?.items?.length>2;switch(a){case 1440:return o?4:e?.items?.length;case 1024:return o?3:e?.items?.length;case 768:return o||n?2.3:2;default:return 1.2}};return(0,i.useImperativeHandle)(p,()=>c.current),(0,C.useExposure)(c,{componentType:g,componentName:w,componentTitle:e?.title}),(0,i.useEffect)(()=>{const a=c.current?.querySelectorAll(".graphic-description");if(a&&a.length>0){let o=0;a.forEach(n=>{o=Math.max(o,n.offsetHeight)}),a.forEach(n=>{n.style.height=`${o}px`})}},[]),(0,t.jsxs)("div",{className:s,ref:c,children:[(0,t.jsxs)("div",{className:"graphic-box",children:[e?.title&&(0,t.jsx)(N.default,{data:{title:e?.title}}),(0,t.jsx)(M.default,{id:"Graphic",className:(0,h.cn)("!overflow-visible"),data:{list:e?.items||[],configuration:{itemShape:e.itemShape,num:e?.items?.length||0,isMobile:r,onVideoPlayBtnClick:(a,o)=>{v(!0),o?.isYouTube?H?.(o?.youtubeId||""):G?.(o?.video?.url||"")}}},Slide:j,breakpoints:{0:{spaceBetween:12,freeMode:!1,slidesPerView:1},374:{spaceBetween:12,freeMode:!1,slidesPerView:m()},768:{spaceBetween:16,freeMode:!1,slidesPerView:m(768)},1024:{spaceBetween:16,freeMode:!1,slidesPerView:m(1024)},1440:{spaceBetween:16,freeMode:!1,slidesPerView:m(1440)}}})]}),(0,t.jsx)(V.VideoModal,{visible:S,youTubeId:E,videoUrl:B,onCloseModal:()=>v(!1)})]})});k.displayName="Graphic";var q=(0,T.withLayout)(k);
2
2
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/biz-components/Graphic/index.tsx"],
4
- "sourcesContent": ["'use client'\nimport React, { useEffect, useImperativeHandle, useRef, useState } from 'react'\nimport { cn } from '../../helpers/utils.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport SwiperBox from '../SwiperBox/index.js'\nimport { Button, Heading } from '../../components/index.js'\nimport { Picture, Text } from '../../components/index.js'\nimport Title from '../Title/index.js'\nimport { useMediaQuery } from 'react-responsive'\nimport { VideoModal } from '../VideoModal/index.js'\nimport type { ComponentCommonProps, Video, Img, Theme } from '../../types/props.js'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\n\nconst componentType = 'image'\nconst componentName = 'graphic'\n\ntype GraphicType = {\n imgUrl: Img\n title: string\n description?: string\n textColor?: string\n href?: string\n video?: Video\n youtubeId?: string\n isYouTube?: boolean\n buttonText?: string\n theme?: Theme\n}\nexport interface GraphicProps extends ComponentCommonProps {\n className?: string\n data: {\n title?: string\n items?: GraphicType[]\n itemShape?: 'round' | 'square'\n itemTheme?: Theme\n }\n}\n\nconst Item = ({ data, configuration }: { data: GraphicType; configuration?: any }) => {\n const isMobile = useMediaQuery({ query: '(max-width: 768px)' })\n const handleAspect = () => {\n switch (configuration.num) {\n case 1:\n return 'tablet:aspect-w-[704] tablet:aspect-h-[400] laptop:aspect-w-[896] laptop:aspect-h-[384] desktop:aspect-w-[1312] desktop:aspect-h-[512] lg-desktop:aspect-w-[1664] lg-desktop:aspect-h-[640]'\n case 2:\n return 'tablet:aspect-w-[346] tablet:aspect-h-[360] laptop:aspect-w-[440] laptop:aspect-h-[360] desktop:aspect-w-[648] desktop:aspect-h-[384] lg-desktop:aspect-w-[824] lg-desktop:aspect-h-[480]'\n case 3:\n return 'tablet:aspect-w-[296] laptop:aspect-w-[288] laptop:aspect-h-[360] desktop:aspect-w-[427] desktop:aspect-h-[384] lg-desktop:aspect-w-[544] lg-desktop:aspect-h-[480]'\n default:\n return 'tablet:aspect-w-[296] laptop:aspect-w-[288] laptop:aspect-h-[360] desktop:aspect-w-[316] desktop:aspect-h-[384] lg-desktop:aspect-w-[404] lg-desktop:aspect-h-[480]'\n }\n }\n\n return (\n <div\n className={cn(handleAspect(), 'laptop:h-auto text-info-primary flex-1 shrink-0 md:basis-[296px]', {\n 'aiui-dark': data.theme === 'dark',\n 'h-[360px]': isMobile,\n })}\n >\n <div\n className={cn('absolute inset-0', {\n ['rounded-xl overflow-hidden laptop:rounded-2xl']: configuration?.itemShape === 'round',\n })}\n >\n <a\n aria-label={data?.title ?? data?.description}\n href={trackUrlRef(data?.href, `${componentType}_${componentName}`)}\n className=\"relative block size-full cursor-pointer overflow-hidden\"\n >\n <Picture\n className=\"h-full\"\n imgClassName=\"h-full object-cover tablet:hover:scale-110 transition-all duration-300\"\n source={data?.imgUrl?.url}\n alt={data?.imgUrl?.alt || ''}\n />\n <div className=\"laptop:p-6 absolute bottom-0 z-[1] box-border flex w-full flex-col p-4\">\n <Text\n style={{\n color: data?.textColor,\n }}\n html={data?.title}\n // eslint-disable-next-line tailwindcss/classnames-order\n className=\"graphic-title line-clamp-3 lg-desktop:text-[18px] desktop:text-[16px] text-[14px] font-bold leading-[1.2]\"\n />\n <div className=\"flex items-end justify-between\">\n <div className=\"flex-1\">\n {data?.description && (\n <Heading\n html={data?.description}\n style={{\n color: data?.textColor,\n }}\n as=\"h3\"\n className=\"graphic-description lg-desktop:text-[32px] desktop:mt-2 desktop:text-[24px] text-lines-2 mt-1 line-clamp-3 flex-1 text-[24px] font-bold leading-[1.2]\"\n />\n )}\n </div>\n {(data?.video?.url || data?.youtubeId) && (\n <button\n aria-label=\"Play Video\"\n onClick={(e: any) => {\n e.preventDefault()\n e.stopPropagation()\n configuration?.onVideoPlayBtnClick?.(configuration?.index || 0, data)\n }}\n className=\"laptop:size-12 flex size-10 items-center justify-center rounded-full bg-white bg-opacity-20 hover:bg-black/75\"\n >\n <svg width=\"12\" height=\"14\" viewBox=\"0 0 12 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M12 7L0 14L0 0L12 7Z\" fill=\"white\" />\n </svg>\n </button>\n )}\n </div>\n {data.buttonText && (\n <Button\n aria-label={data?.title ?? data?.description}\n variant=\"secondary\"\n className=\"desktop:mt-[24px] mt-[12px] self-start\"\n as=\"a\"\n href={trackUrlRef(data?.href, `${componentType}_${componentName}`)}\n >\n {data.buttonText}\n </Button>\n )}\n </div>\n </a>\n </div>\n </div>\n )\n}\n\nconst Graphic = React.forwardRef<HTMLDivElement, GraphicProps>(({ data, className, ...props }, ref) => {\n const innerRef = useRef<HTMLDivElement>(null)\n const [visible, setVisible] = useState<boolean>(false)\n const [videoUrl, setVideoUrl] = useState<string>('')\n const [youTubeId, setYouTubeId] = useState<string>('')\n\n const handleSwiperShow = (width?: number) => {\n const isShow = (data?.items as GraphicType[])?.length > 3\n const isMobile = (data?.items as GraphicType[])?.length > 2\n switch (width) {\n case 1440:\n return isShow ? 4 : data?.items?.length\n case 1024:\n return isShow ? 3 : data?.items?.length\n case 768:\n return isShow ? 2.3 : isMobile ? 2.3 : 2\n default:\n return 1.2\n }\n }\n\n useImperativeHandle(ref, () => innerRef.current as HTMLDivElement)\n\n useExposure(innerRef, {\n componentType,\n componentName,\n componentTitle: data?.title,\n })\n\n useEffect(() => {\n const descriptions = innerRef.current?.querySelectorAll<HTMLDivElement>('.graphic-description')\n if (descriptions && descriptions.length > 0) {\n let maxHeight = 0\n descriptions.forEach((el: HTMLDivElement) => {\n maxHeight = Math.max(maxHeight, el.offsetHeight)\n })\n descriptions.forEach((el: HTMLDivElement) => {\n el.style.height = `${maxHeight}px`\n })\n }\n }, [])\n\n return (\n <div className={className} ref={innerRef}>\n <div className=\"graphic-box\">\n {data?.title && <Title data={{ title: data?.title }} />}\n <SwiperBox\n id=\"Graphic\"\n className={cn('!overflow-visible')}\n data={{\n list: data?.items || [],\n configuration: {\n itemShape: data.itemShape,\n num: data?.items?.length || 0,\n onVideoPlayBtnClick: (_: number, data: GraphicType) => {\n setVisible(true)\n if (data?.isYouTube) {\n setYouTubeId?.(data?.youtubeId || '')\n } else {\n setVideoUrl?.(data?.video?.url || '')\n }\n },\n },\n }}\n Slide={Item}\n breakpoints={{\n 0: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1,\n },\n 374: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: handleSwiperShow(),\n },\n 768: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: handleSwiperShow(768),\n },\n 1024: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: handleSwiperShow(1024),\n },\n 1440: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: handleSwiperShow(1440),\n },\n }}\n />\n </div>\n <VideoModal visible={visible} youTubeId={youTubeId} videoUrl={videoUrl} onCloseModal={() => setVisible(false)} />\n </div>\n )\n})\n\nGraphic.displayName = 'Graphic'\n\nexport default withLayout(Graphic)\n"],
5
- "mappings": "ukBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GAuEU,IAAAI,EAAA,6BAtEVC,EAAwE,oBACxEC,EAAmB,kCACnBC,EAA2B,kCAC3BC,EAAsB,oCACtBC,EAAgC,qCAChCA,EAA8B,qCAC9BC,EAAkB,gCAClBC,EAA8B,4BAC9BC,EAA2B,kCAE3BC,EAA4B,sCAC5BC,EAA4B,uCAE5B,MAAMC,EAAgB,QAChBC,EAAgB,UAwBhBC,EAAO,CAAC,CAAE,KAAAC,EAAM,cAAAC,CAAc,IAAkD,CACpF,MAAMC,KAAW,iBAAc,CAAE,MAAO,oBAAqB,CAAC,EAc9D,SACE,OAAC,OACC,aAAW,OAfM,IAAM,CACzB,OAAQD,EAAc,IAAK,CACzB,IAAK,GACH,MAAO,8LACT,IAAK,GACH,MAAO,4LACT,IAAK,GACH,MAAO,sKACT,QACE,MAAO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ACb,UAAWA,EAAK,UAChB,IAAKA,GAAM,OAAO,QAAU,EAC5B,oBAAqB,CAACwB,EAAWxB,IAAsB,CACrDW,EAAW,EAAI,EACXX,GAAM,UACRe,IAAef,GAAM,WAAa,EAAE,EAEpCa,IAAcb,GAAM,OAAO,KAAO,EAAE,CAExC,CACF,CACF,EACA,MAAOD,EACP,YAAa,CACX,EAAG,CACD,aAAc,GACd,SAAU,GACV,cAAe,CACjB,EACA,IAAK,CACH,aAAc,GACd,SAAU,GACV,cAAeiB,EAAiB,CAClC,EACA,IAAK,CACH,aAAc,GACd,SAAU,GACV,cAAeA,EAAiB,GAAG,CACrC,EACA,KAAM,CACJ,aAAc,GACd,SAAU,GACV,cAAeA,EAAiB,IAAI,CACtC,EACA,KAAM,CACJ,aAAc,GACd,SAAU,GACV,cAAeA,EAAiB,IAAI,CACtC,CACF,EACF,GACF,KACA,OAAC,cAAW,QAASN,EAAS,UAAWI,EAAW,SAAUF,EAAU,aAAc,IAAMD,EAAW,EAAK,EAAG,GACjH,CAEJ,CAAC,EAEDP,EAAQ,YAAc,UAEtB,IAAOpB,KAAQ,cAAWoB,CAAO",
6
- "names": ["Graphic_exports", "__export", "Graphic_default", "__toCommonJS", "import_jsx_runtime", "import_react", "import_utils", "import_Styles", "import_SwiperBox", "import_components", "import_Title", "import_react_responsive", "import_VideoModal", "import_useExposure", "import_trackUrlRef", "componentType", "componentName", "Item", "data", "configuration", "isMobile", "e", "Graphic", "React", "className", "props", "ref", "innerRef", "visible", "setVisible", "videoUrl", "setVideoUrl", "youTubeId", "setYouTubeId", "handleSwiperShow", "width", "isShow", "descriptions", "maxHeight", "el", "Title", "SwiperBox", "_"]
4
+ "sourcesContent": ["'use client'\nimport React, { useEffect, useImperativeHandle, useRef, useState } from 'react'\nimport { cn } from '../../helpers/utils.js'\nimport { withLayout } from '../../shared/Styles.js'\nimport SwiperBox from '../SwiperBox/index.js'\nimport { Button, Heading } from '../../components/index.js'\nimport { Picture, Text } from '../../components/index.js'\nimport Title from '../Title/index.js'\nimport { useMediaQuery } from 'react-responsive'\nimport { VideoModal } from '../VideoModal/index.js'\nimport type { ComponentCommonProps, Video, Img, Theme } from '../../types/props.js'\nimport { useExposure } from '../../hooks/useExposure.js'\nimport { trackUrlRef } from '../../shared/trackUrlRef.js'\n\nconst componentType = 'image'\nconst componentName = 'graphic'\n\ntype GraphicType = {\n imgUrl: Img\n title: string\n description?: string\n textColor?: string\n href?: string\n video?: Video\n youtubeId?: string\n isYouTube?: boolean\n buttonText?: string\n theme?: Theme\n}\nexport interface GraphicProps extends ComponentCommonProps {\n className?: string\n data: {\n title?: string\n items?: GraphicType[]\n itemShape?: 'round' | 'square'\n itemTheme?: Theme\n }\n}\n\nconst Item = ({ data, configuration }: { data: GraphicType; configuration?: any }) => {\n const handleAspect = () => {\n switch (configuration.num) {\n case 1:\n return 'tablet:aspect-w-[704] tablet:aspect-h-[400] laptop:aspect-w-[896] laptop:aspect-h-[384] desktop:aspect-w-[1312] desktop:aspect-h-[512] lg-desktop:aspect-w-[1664] lg-desktop:aspect-h-[640]'\n case 2:\n return 'tablet:aspect-w-[346] tablet:aspect-h-[360] laptop:aspect-w-[440] laptop:aspect-h-[360] desktop:aspect-w-[648] desktop:aspect-h-[384] lg-desktop:aspect-w-[824] lg-desktop:aspect-h-[480]'\n case 3:\n return 'tablet:aspect-w-[296] tablet:aspect-h-[360] laptop:aspect-w-[288] laptop:aspect-h-[360] desktop:aspect-w-[427] desktop:aspect-h-[384] lg-desktop:aspect-w-[544] lg-desktop:aspect-h-[480]'\n default:\n return 'tablet:aspect-w-[296] tablet:aspect-h-[360] laptop:aspect-w-[288] laptop:aspect-h-[360] desktop:aspect-w-[316] desktop:aspect-h-[384] lg-desktop:aspect-w-[404] lg-desktop:aspect-h-[480]'\n }\n }\n\n return (\n <div\n className={cn(handleAspect(), 'laptop:h-auto text-info-primary flex-1 shrink-0 md:basis-[296px]', {\n 'aiui-dark': data.theme === 'dark',\n 'h-[360px]': configuration?.isMobile,\n })}\n >\n <div\n className={cn('absolute inset-0', {\n ['rounded-xl overflow-hidden laptop:rounded-2xl']: configuration?.itemShape === 'round',\n })}\n >\n <a\n aria-label={data?.title ?? data?.description}\n href={trackUrlRef(data?.href, `${componentType}_${componentName}`)}\n className=\"relative block size-full cursor-pointer overflow-hidden\"\n >\n <Picture\n className=\"h-full\"\n imgClassName=\"h-full object-cover tablet:hover:scale-110 transition-all duration-300\"\n source={data?.imgUrl?.url}\n alt={data?.imgUrl?.alt || ''}\n />\n <div className=\"laptop:p-6 absolute bottom-0 z-[1] box-border flex w-full flex-col p-4\">\n <Text\n style={{\n color: data?.textColor,\n }}\n html={data?.title}\n // eslint-disable-next-line tailwindcss/classnames-order\n className=\"graphic-title line-clamp-3 lg-desktop:text-[18px] desktop:text-[16px] text-[14px] font-bold leading-[1.2]\"\n />\n <div className=\"flex items-end justify-between\">\n <div className=\"flex-1\">\n {data?.description && (\n <Heading\n html={data?.description}\n style={{\n color: data?.textColor,\n }}\n as=\"h3\"\n className=\"graphic-description lg-desktop:text-[32px] desktop:mt-2 desktop:text-[24px] text-lines-2 mt-1 line-clamp-3 flex-1 text-[24px] font-bold leading-[1.2]\"\n />\n )}\n </div>\n {(data?.video?.url || data?.youtubeId) && (\n <button\n aria-label=\"Play Video\"\n onClick={(e: any) => {\n e.preventDefault()\n e.stopPropagation()\n configuration?.onVideoPlayBtnClick?.(configuration?.index || 0, data)\n }}\n className=\"laptop:size-12 flex size-10 items-center justify-center rounded-full bg-white bg-opacity-20 hover:bg-black/75\"\n >\n <svg width=\"12\" height=\"14\" viewBox=\"0 0 12 14\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M12 7L0 14L0 0L12 7Z\" fill=\"white\" />\n </svg>\n </button>\n )}\n </div>\n {data.buttonText && (\n <Button\n aria-label={data?.title ?? data?.description}\n variant=\"secondary\"\n className=\"desktop:mt-[24px] mt-[12px] self-start\"\n as=\"a\"\n href={trackUrlRef(data?.href, `${componentType}_${componentName}`)}\n >\n {data.buttonText}\n </Button>\n )}\n </div>\n </a>\n </div>\n </div>\n )\n}\n\nconst Graphic = React.forwardRef<HTMLDivElement, GraphicProps>(({ data, className, ...props }, ref) => {\n const isMobileSize = useMediaQuery({ query: '(max-width: 768px)' })\n const innerRef = useRef<HTMLDivElement>(null)\n const [visible, setVisible] = useState<boolean>(false)\n const [videoUrl, setVideoUrl] = useState<string>('')\n const [youTubeId, setYouTubeId] = useState<string>('')\n\n const handleSwiperShow = (width?: number) => {\n const isShow = (data?.items as GraphicType[])?.length > 3\n const isMobile = (data?.items as GraphicType[])?.length > 2\n switch (width) {\n case 1440:\n return isShow ? 4 : data?.items?.length\n case 1024:\n return isShow ? 3 : data?.items?.length\n case 768:\n return isShow ? 2.3 : isMobile ? 2.3 : 2\n default:\n return 1.2\n }\n }\n\n useImperativeHandle(ref, () => innerRef.current as HTMLDivElement)\n\n useExposure(innerRef, {\n componentType,\n componentName,\n componentTitle: data?.title,\n })\n\n useEffect(() => {\n const descriptions = innerRef.current?.querySelectorAll<HTMLDivElement>('.graphic-description')\n if (descriptions && descriptions.length > 0) {\n let maxHeight = 0\n descriptions.forEach((el: HTMLDivElement) => {\n maxHeight = Math.max(maxHeight, el.offsetHeight)\n })\n descriptions.forEach((el: HTMLDivElement) => {\n el.style.height = `${maxHeight}px`\n })\n }\n }, [])\n\n return (\n <div className={className} ref={innerRef}>\n <div className=\"graphic-box\">\n {data?.title && <Title data={{ title: data?.title }} />}\n <SwiperBox\n id=\"Graphic\"\n className={cn('!overflow-visible')}\n data={{\n list: data?.items || [],\n configuration: {\n itemShape: data.itemShape,\n num: data?.items?.length || 0,\n isMobile: isMobileSize,\n onVideoPlayBtnClick: (_: number, data: GraphicType) => {\n setVisible(true)\n if (data?.isYouTube) {\n setYouTubeId?.(data?.youtubeId || '')\n } else {\n setVideoUrl?.(data?.video?.url || '')\n }\n },\n },\n }}\n Slide={Item}\n breakpoints={{\n 0: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: 1,\n },\n 374: {\n spaceBetween: 12,\n freeMode: false,\n slidesPerView: handleSwiperShow(),\n },\n 768: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: handleSwiperShow(768),\n },\n 1024: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: handleSwiperShow(1024),\n },\n 1440: {\n spaceBetween: 16,\n freeMode: false,\n slidesPerView: handleSwiperShow(1440),\n },\n }}\n />\n </div>\n <VideoModal visible={visible} youTubeId={youTubeId} videoUrl={videoUrl} onCloseModal={() => setVisible(false)} />\n </div>\n )\n})\n\nGraphic.displayName = 'Graphic'\n\nexport default withLayout(Graphic)\n"],
5
+ "mappings": "ukBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,IAAA,eAAAC,EAAAH,GAsEU,IAAAI,EAAA,6BArEVC,EAAwE,oBACxEC,EAAmB,kCACnBC,EAA2B,kCAC3BC,EAAsB,oCACtBC,EAAgC,qCAChCA,EAA8B,qCAC9BC,EAAkB,gCAClBC,EAA8B,4BAC9BC,EAA2B,kCAE3BC,EAA4B,sCAC5BC,EAA4B,uCAE5B,MAAMC,EAAgB,QAChBC,EAAgB,UAwBhBC,EAAO,CAAC,CAAE,KAAAC,EAAM,cAAAC,CAAc,OAehC,OAAC,OACC,aAAW,OAfM,IAAM,CACzB,OAAQA,EAAc,IAAK,CACzB,IAAK,GACH,MAAO,8LACT,IAAK,GACH,MAAO,4LACT,IAAK,GACH,MAAO,4LACT,QACE,MAAO,2LACX,CACF,GAI+B,EAAG,mEAAoE,CAChG,YAAaD,EAAK,QAAU,OAC5B,YAAaC,GAAe,QAC9B,CAAC,EAED,mBAAC,OACC,aAAW,MAAG,mBAAoB,CAC/B,gDAAkDA,GAAe,YAAc,OAClF,CAAC,EAED,oBAAC,KACC,aAAYD,GAAM,OAASA,GAAM,YACjC,QAAM,eAAYA,GAAM,KAAM,GAAGH,CAAa,IAAIC,CAAa,EAAE,EACjE,UAAU,0DAEV,oBAAC,WAC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ACD,aAAc,GACd,SAAU,GACV,cAAe,CACjB,EACA,IAAK,CACH,aAAc,GACd,SAAU,GACV,cAAeiB,EAAiB,CAClC,EACA,IAAK,CACH,aAAc,GACd,SAAU,GACV,cAAeA,EAAiB,GAAG,CACrC,EACA,KAAM,CACJ,aAAc,GACd,SAAU,GACV,cAAeA,EAAiB,IAAI,CACtC,EACA,KAAM,CACJ,aAAc,GACd,SAAU,GACV,cAAeA,EAAiB,IAAI,CACtC,CACF,EACF,GACF,KACA,OAAC,cAAW,QAASN,EAAS,UAAWI,EAAW,SAAUF,EAAU,aAAc,IAAMD,EAAW,EAAK,EAAG,GACjH,CAEJ,CAAC,EAEDR,EAAQ,YAAc,UAEtB,IAAOnB,KAAQ,cAAWmB,CAAO",
6
+ "names": ["Graphic_exports", "__export", "Graphic_default", "__toCommonJS", "import_jsx_runtime", "import_react", "import_utils", "import_Styles", "import_SwiperBox", "import_components", "import_Title", "import_react_responsive", "import_VideoModal", "import_useExposure", "import_trackUrlRef", "componentType", "componentName", "Item", "data", "configuration", "e", "Graphic", "React", "className", "props", "ref", "isMobileSize", "innerRef", "visible", "setVisible", "videoUrl", "setVideoUrl", "youTubeId", "setYouTubeId", "handleSwiperShow", "width", "isShow", "isMobile", "descriptions", "maxHeight", "el", "Title", "SwiperBox", "_"]
7
7
  }
@@ -0,0 +1,3 @@
1
+ export declare function YouTubePlayer({ youTubeId }: {
2
+ youTubeId: string;
3
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import type { SectionHeadingProps } from './types.js';
3
+ declare const SectionHeading: React.ForwardRefExoticComponent<SectionHeadingProps & React.RefAttributes<HTMLDivElement>>;
4
+ export default SectionHeading;
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ export interface SectionHeadingProps {
3
+ title: string;
4
+ className?: string;
5
+ children: React.ReactNode;
6
+ }
@@ -0,0 +1,8 @@
1
+ import type { ShelfProps } from './types.js';
2
+ declare const _default: {
3
+ (props: Omit<ShelfProps, keyof import("../../shared/Styles.js").StylesProps> & Partial<import("../../shared/Styles.js").StylesProps> & {
4
+ className?: string;
5
+ }): import("react/jsx-runtime").JSX.Element;
6
+ displayName: string;
7
+ };
8
+ export default _default;
@@ -0,0 +1 @@
1
+ export { default } from './Shelf.js';
@@ -0,0 +1,6 @@
1
+ export type ShelfProps = {
2
+ id: string;
3
+ title: string;
4
+ subtitle: string;
5
+ products: any[];
6
+ };
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ interface TabsProps {
3
+ tabs: any[];
4
+ onTabClick?: (value: any) => void;
5
+ }
6
+ declare const Tab: React.FC<TabsProps>;
7
+ export default Tab;
@@ -0,0 +1,29 @@
1
+ import React from 'react';
2
+ import type { ReactNode } from 'react';
3
+ interface mediaProps {
4
+ span?: number;
5
+ pull?: number;
6
+ push?: number;
7
+ offset?: number;
8
+ order?: number;
9
+ }
10
+ interface ColProps {
11
+ children?: ReactNode;
12
+ span?: number;
13
+ className?: string;
14
+ asChild?: boolean;
15
+ offset?: number;
16
+ order?: number;
17
+ push?: number;
18
+ pull?: number;
19
+ flex?: number;
20
+ allFlex?: number;
21
+ md?: number | mediaProps;
22
+ lxl?: number | mediaProps;
23
+ mdl?: number | mediaProps;
24
+ xlxxl?: number | mediaProps;
25
+ minxxl?: number | mediaProps;
26
+ }
27
+ declare const Col: React.ForwardRefExoticComponent<ColProps & React.RefAttributes<HTMLDivElement>>;
28
+ export { Col };
29
+ export type { ColProps };
@@ -0,0 +1,27 @@
1
+ import * as React from 'react';
2
+ import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
3
+ declare const DropdownMenu: React.FC<DropdownMenuPrimitive.DropdownMenuProps>;
4
+ declare const DropdownMenuTrigger: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuTriggerProps & React.RefAttributes<HTMLButtonElement>>;
5
+ declare const DropdownMenuGroup: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuGroupProps & React.RefAttributes<HTMLDivElement>>;
6
+ declare const DropdownMenuPortal: React.FC<DropdownMenuPrimitive.DropdownMenuPortalProps>;
7
+ declare const DropdownMenuSub: React.FC<DropdownMenuPrimitive.DropdownMenuSubProps>;
8
+ declare const DropdownMenuRadioGroup: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuRadioGroupProps & React.RefAttributes<HTMLDivElement>>;
9
+ declare const DropdownMenuSubTrigger: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
10
+ inset?: boolean;
11
+ } & React.RefAttributes<HTMLDivElement>>;
12
+ declare const DropdownMenuSubContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
13
+ declare const DropdownMenuContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
14
+ declare const DropdownMenuItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
15
+ inset?: boolean;
16
+ } & React.RefAttributes<HTMLDivElement>>;
17
+ declare const DropdownMenuCheckboxItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
18
+ declare const DropdownMenuRadioItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
19
+ declare const DropdownMenuLabel: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
20
+ inset?: boolean;
21
+ } & React.RefAttributes<HTMLDivElement>>;
22
+ declare const DropdownMenuSeparator: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
23
+ declare const DropdownMenuShortcut: {
24
+ ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>): import("react/jsx-runtime").JSX.Element;
25
+ displayName: string;
26
+ };
27
+ export { DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuItem, DropdownMenuCheckboxItem, DropdownMenuRadioItem, DropdownMenuLabel, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuGroup, DropdownMenuPortal, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuRadioGroup, };
File without changes
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ import type { ReactNode } from 'react';
3
+ interface RowProps {
4
+ children?: ReactNode;
5
+ className?: string;
6
+ align?: 'start' | 'center' | 'end' | 'stretch' | {
7
+ [key in 'md' | 'mdl' | 'xlxxl' | 'minxxl']: 'start' | 'center' | 'end' | 'stretch';
8
+ };
9
+ asChild?: boolean;
10
+ gutter?: number | object | Array<object | number>;
11
+ wrap?: boolean;
12
+ justify?: 'start' | 'end' | 'center' | 'space-around' | 'space-between' | 'space-evenly' | {
13
+ [key in 'md' | 'mdl' | 'xlxxl' | 'minxxl']: 'start' | 'end' | 'center' | 'space-around' | 'space-between' | 'space-evenly';
14
+ };
15
+ }
16
+ declare const Row: React.ForwardRefExoticComponent<RowProps & React.RefAttributes<HTMLDivElement>>;
17
+ export { Row };
18
+ export type { RowProps };
@@ -0,0 +1,12 @@
1
+ import * as React from 'react';
2
+ /**
3
+ * This is a helper function that is used when a component supports `asChild`
4
+ * using the `Slot` component but its implementation contains nested DOM elements.
5
+ *
6
+ * Using it ensures if a consumer uses the `asChild` prop, the elements are in
7
+ * correct order in the DOM, adopting the intended consumer `children`.
8
+ */
9
+ export declare function getSubtree(options: {
10
+ asChild: boolean | undefined;
11
+ children: React.ReactNode;
12
+ }, content: React.ReactNode | ((children: React.ReactNode) => React.ReactNode)): React.ReactNode;
@@ -0,0 +1,26 @@
1
+ import React from 'react';
2
+ import * as AvatarPrimitive from '@radix-ui/react-avatar';
3
+ import { type VariantProps } from 'class-variance-authority';
4
+ declare const Avatar: React.ForwardRefExoticComponent<{
5
+ /** 定义子组件作为父组件的类型,详细使用方式请参考radix-ui */
6
+ asChild?: boolean;
7
+ /** 类名*/
8
+ className?: string;
9
+ /** 样式*/
10
+ style?: React.CSSProperties;
11
+ /** 点击事件*/
12
+ onClick?: Function;
13
+ /** 文本自适应*/
14
+ isAdaptation?: boolean;
15
+ /** 文本自适应最小字体, 开启时生效*/
16
+ minSize?: number;
17
+ /** 文本自适应最大字体, 开启时生效*/
18
+ maxSize?: number;
19
+ /** 文本自适应类*/
20
+ textClassName?: string;
21
+ } & VariantProps<(props?: ({
22
+ size?: "small" | "medium" | "large" | null | undefined;
23
+ } & import("class-variance-authority/dist/types.js").ClassProp) | undefined) => string> & Omit<AvatarPrimitive.AvatarProps & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
24
+ declare const AvatarImage: React.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarImageProps & React.RefAttributes<HTMLImageElement>, "ref"> & React.RefAttributes<HTMLImageElement>>;
25
+ declare const AvatarFallback: React.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarFallbackProps & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
26
+ export { Avatar, AvatarImage, AvatarFallback };
@@ -0,0 +1,20 @@
1
+ export { default as Button } from './button.js';
2
+ export { default as Badge } from './badge.js';
3
+ export * from './input.js';
4
+ export { default as Checkbox } from './checkbox.js';
5
+ export { default as Skeleton } from './skeleton.js';
6
+ export * from './dialog.js';
7
+ export * from './popover.js';
8
+ export * from './radio.js';
9
+ export * from './dialog.js';
10
+ export * from './text.js';
11
+ export * from './gird.js';
12
+ export * from './col.js';
13
+ export * from './row.js';
14
+ export * from './heading.js';
15
+ export * from './container.js';
16
+ export * from './color.js';
17
+ export * from './link.js';
18
+ export * from './avatar.js';
19
+ export { default as Picture } from './picture.js';
20
+ export { default as Theme } from './theme.js';
@@ -0,0 +1 @@
1
+ export * from './components/index.js';
@@ -0,0 +1,40 @@
1
+ declare const meta: {
2
+ title: string;
3
+ component: import("react").ForwardRefExoticComponent<{
4
+ asChild?: boolean;
5
+ className?: string;
6
+ style?: React.CSSProperties;
7
+ onClick?: Function;
8
+ isAdaptation?: boolean;
9
+ minSize?: number;
10
+ maxSize?: number;
11
+ textClassName?: string;
12
+ } & import("class-variance-authority").VariantProps<(props?: ({
13
+ size?: "small" | "medium" | "large" | null | undefined;
14
+ } & import("class-variance-authority/dist/types.js").ClassProp) | undefined) => string> & Omit<import("@radix-ui/react-avatar").AvatarProps & import("react").RefAttributes<HTMLSpanElement>, "ref"> & import("react").RefAttributes<HTMLSpanElement>>;
15
+ tags: string[];
16
+ subcomponents: any;
17
+ parameters: {
18
+ layout: string;
19
+ docs: {
20
+ description: {
21
+ component: string;
22
+ };
23
+ };
24
+ };
25
+ argTypes: {
26
+ size: {
27
+ description: string;
28
+ table: {
29
+ defaultValue: {
30
+ summary: string;
31
+ };
32
+ };
33
+ };
34
+ };
35
+ };
36
+ export default meta;
37
+ export declare const Default: () => import("react/jsx-runtime").JSX.Element;
38
+ export declare const AvatarType: () => import("react/jsx-runtime").JSX.Element;
39
+ export declare const AvatarTextAdaptation: () => import("react/jsx-runtime").JSX.Element;
40
+ export declare const AvatarSize: () => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,26 @@
1
+ import type { StoryObj } from '@storybook/react';
2
+ import { Badge } from '../components/index.js';
3
+ declare const meta: {
4
+ title: string;
5
+ component: typeof Badge;
6
+ parameters: {
7
+ layout: string;
8
+ };
9
+ tags: string[];
10
+ argTypes: {
11
+ variant: {
12
+ control: {
13
+ type: "select";
14
+ };
15
+ options: string[];
16
+ };
17
+ };
18
+ args: {
19
+ variant: "default";
20
+ children: string;
21
+ };
22
+ };
23
+ export default meta;
24
+ type Story = StoryObj<typeof meta>;
25
+ export declare const Default: Story;
26
+ export declare const Examples: Story;
@@ -0,0 +1,48 @@
1
+ import type { StoryObj } from '@storybook/react';
2
+ import React from 'react';
3
+ declare const meta: {
4
+ title: string;
5
+ component: React.ForwardRefExoticComponent<import("../components/button.js").ButtonProps & React.RefAttributes<HTMLButtonElement>>;
6
+ parameters: {
7
+ layout: string;
8
+ };
9
+ tags: string[];
10
+ argTypes: {
11
+ variant: {
12
+ control: {
13
+ type: "select";
14
+ };
15
+ options: string[];
16
+ };
17
+ size: {
18
+ control: {
19
+ type: "select";
20
+ };
21
+ options: string[];
22
+ };
23
+ hoverEffect: {
24
+ description: string;
25
+ control: {
26
+ type: "select";
27
+ };
28
+ options: string[];
29
+ };
30
+ };
31
+ args: {
32
+ variant: "primary";
33
+ size: "base";
34
+ children: string;
35
+ asChild: false;
36
+ disabled: false;
37
+ loading: false;
38
+ hoverEffect: "none";
39
+ };
40
+ };
41
+ export default meta;
42
+ type Story = StoryObj<typeof meta>;
43
+ export declare const Primary: Story;
44
+ export declare const Secondary: Story;
45
+ export declare const Link: Story;
46
+ export declare const WithIcon: Story;
47
+ export declare const Aschild: Story;
48
+ export declare const Spinner: Story;
@@ -0,0 +1,46 @@
1
+ import type { StoryObj } from '@storybook/react/*';
2
+ import React from 'react';
3
+ declare const meta: {
4
+ title: string;
5
+ component: React.ForwardRefExoticComponent<import("../components/checkbox.js").CheckboxProps & React.RefAttributes<HTMLButtonElement>>;
6
+ parameters: {
7
+ layout: string;
8
+ docs: {
9
+ description: {
10
+ component: string;
11
+ };
12
+ };
13
+ };
14
+ tags: string[];
15
+ argTypes: {
16
+ size: {
17
+ control: {
18
+ type: "select";
19
+ };
20
+ options: string[];
21
+ description: string;
22
+ table: {
23
+ defaultValue: {
24
+ summary: string;
25
+ };
26
+ };
27
+ };
28
+ };
29
+ args: {
30
+ size: "base";
31
+ };
32
+ };
33
+ export default meta;
34
+ type Story = StoryObj<typeof meta>;
35
+ export declare const Default: Story;
36
+ export declare const Sizes: {
37
+ (): import("react/jsx-runtime").JSX.Element;
38
+ parameters: {
39
+ docs: {
40
+ description: {
41
+ story: string;
42
+ };
43
+ };
44
+ };
45
+ };
46
+ export declare const Disabled: () => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,36 @@
1
+ import React from 'react';
2
+ import { Container } from '../components/index.js';
3
+ import type { StoryObj } from '@storybook/react';
4
+ declare const meta: {
5
+ title: string;
6
+ component: React.ForwardRefExoticComponent<{
7
+ asChild?: boolean;
8
+ children?: React.ReactNode;
9
+ className?: string;
10
+ type?: "default" | "home" | "none";
11
+ } & Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ parameters: {
13
+ layout: string;
14
+ docs: {
15
+ description: {
16
+ component: string;
17
+ };
18
+ };
19
+ };
20
+ tags: string[];
21
+ argTypes: {
22
+ type: {
23
+ description: string;
24
+ control: {
25
+ type: "select";
26
+ };
27
+ options: string[];
28
+ };
29
+ };
30
+ args: {
31
+ type: "default";
32
+ };
33
+ };
34
+ export default meta;
35
+ type Story = StoryObj<typeof Container>;
36
+ export declare const Default: Story;
@@ -0,0 +1,20 @@
1
+ import React from 'react';
2
+ import { Dialog } from '../components/index.js';
3
+ import type { StoryObj } from '@storybook/react/*';
4
+ declare const meta: {
5
+ title: string;
6
+ component: React.FC<import("@radix-ui/react-dialog").DialogProps>;
7
+ subcomponents: any;
8
+ parameters: {
9
+ layout: string;
10
+ docs: {
11
+ description: {
12
+ component: string;
13
+ };
14
+ };
15
+ };
16
+ tags: string[];
17
+ };
18
+ export default meta;
19
+ type Story = StoryObj<typeof Dialog>;
20
+ export declare const Default: Story;
@@ -0,0 +1,42 @@
1
+ import React from 'react';
2
+ import { Container } from '../components/index.js';
3
+ import type { StoryObj } from '@storybook/react';
4
+ declare const meta: {
5
+ title: string;
6
+ component: React.ForwardRefExoticComponent<{
7
+ asChild?: boolean;
8
+ children?: React.ReactNode;
9
+ className?: string;
10
+ type?: "default" | "home" | "none";
11
+ } & Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ subcomponents: any;
13
+ parameters: {
14
+ layout: string;
15
+ docs: {
16
+ description: {
17
+ component: string;
18
+ };
19
+ };
20
+ };
21
+ tags: string[];
22
+ argTypes: {
23
+ type: {
24
+ control: {
25
+ type: "select";
26
+ };
27
+ options: string[];
28
+ description: string;
29
+ table: {
30
+ defaultValue: {
31
+ summary: string;
32
+ };
33
+ };
34
+ };
35
+ };
36
+ args: {
37
+ type: "default";
38
+ };
39
+ };
40
+ export default meta;
41
+ type Story = StoryObj<typeof Container>;
42
+ export declare const Default: Story;