@machinerd/js-module 0.7.0 → 0.8.0

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 (41) hide show
  1. package/dist/common-Bn0Ko6B7.cjs +1 -0
  2. package/dist/common-Df03Ovdm.mjs +1 -0
  3. package/dist/hooks/index.cjs +1 -1
  4. package/dist/hooks/index.d.cts +1 -1
  5. package/dist/hooks/index.d.mts +1 -1
  6. package/dist/hooks/index.mjs +1 -1
  7. package/dist/{index-4pIelCz_.d.cts → index-B11XDBo5.d.cts} +3 -3
  8. package/dist/{index-BFHrNSKP.d.mts → index-dbBlRf5k.d.mts} +3 -3
  9. package/dist/providers/index.d.cts +2 -2
  10. package/dist/{skeleton-6QtpIO7l.mjs → skeleton-B6_oBhkl.mjs} +1 -1
  11. package/dist/{skeleton-DBha34Cx.cjs → skeleton-DtV9S1QK.cjs} +1 -1
  12. package/dist/styles/index.css +175 -347
  13. package/dist/ui/carousel/index.cjs +1 -1
  14. package/dist/ui/carousel/index.mjs +1 -1
  15. package/dist/ui/dialog/index.cjs +1 -1
  16. package/dist/ui/dialog/index.d.cts +3 -3
  17. package/dist/ui/dialog/index.d.mts +1 -1
  18. package/dist/ui/dialog/index.mjs +1 -1
  19. package/dist/ui/image/index.cjs +1 -1
  20. package/dist/ui/image/index.d.cts +3 -3
  21. package/dist/ui/image/index.d.mts +10 -10
  22. package/dist/ui/image/index.mjs +1 -1
  23. package/dist/ui/index.cjs +1 -1
  24. package/dist/ui/index.d.cts +17 -17
  25. package/dist/ui/index.d.mts +17 -17
  26. package/dist/ui/index.mjs +1 -1
  27. package/dist/ui/sheet/index.cjs +1 -1
  28. package/dist/ui/sheet/index.d.cts +2 -2
  29. package/dist/ui/sheet/index.mjs +1 -1
  30. package/dist/ui/tooltip/index.cjs +1 -1
  31. package/dist/ui/tooltip/index.d.cts +2 -2
  32. package/dist/ui/tooltip/index.mjs +1 -1
  33. package/dist/{use-subset-image-DvV5Mlkc.mjs → use-subset-image-D8ssrZhj.mjs} +1 -1
  34. package/dist/{use-subset-image-DhX5WmYG.cjs → use-subset-image-DC86cg6O.cjs} +1 -1
  35. package/dist/util/common.cjs +1 -1
  36. package/dist/util/common.d.cts +1 -1
  37. package/dist/util/common.d.mts +1 -1
  38. package/dist/util/common.mjs +1 -1
  39. package/package.json +50 -6
  40. package/dist/common-CQWUs1nE.cjs +0 -1
  41. package/dist/common-DbEp6YNc.mjs +0 -1
@@ -1 +1 @@
1
- "use client";import{n as e}from"../../common-DbEp6YNc.mjs";import t from"clsx";import n,{useCallback as r,useEffect as i,useState as a}from"react";import{Fragment as o,jsx as s}from"react/jsx-runtime";import c from"embla-carousel-react";const l=n.createContext(null);function u(){let e=n.useContext(l);if(!e)throw Error(`useCarousel must be used within a <Carousel />`);return e}function d({orientation:t=`horizontal`,options:n,setApi:o,plugins:u,className:d,children:f,...p}){let[m,h]=c({...n,axis:t===`horizontal`?`x`:`y`},u),[g,_]=a(!1),[v,y]=a(!1),[b,x]=a(0),[S,C]=a(0),w=r(e=>{e&&(_(e.canScrollPrev()),y(e.canScrollNext()),C(e.selectedScrollSnap()))},[]),T=r(()=>{h?.scrollPrev()},[h]),E=r(()=>{h?.scrollNext()},[h]),D=r(e=>{h?.scrollTo(e)},[h]),O=r(()=>{x(h?.scrollSnapList().length||0)},[h]),k=r(e=>{t===`horizontal`?e.key===`ArrowLeft`?(e.preventDefault(),T()):e.key===`ArrowRight`&&(e.preventDefault(),E()):e.key===`ArrowUp`?(e.preventDefault(),T()):e.key===`ArrowDown`&&(e.preventDefault(),E())},[T,E,t]);return i(()=>{!h||!o||o(h)},[h,o]),i(()=>{if(h)return w(h),O(),h.on(`reInit`,O),h.on(`reInit`,w),h.on(`select`,w),()=>{h?.off(`select`,w)}},[h,w]),s(l.Provider,{value:{carouselRef:m,api:h,options:n,orientation:t||(n?.axis===`y`?`vertical`:`horizontal`),scrollPrev:T,scrollNext:E,canScrollPrev:g,canScrollNext:v,scrollTo:D,dots:b,selectedScrollSnap:S},children:s(`div`,{"data-komc":!0,role:`region`,"aria-label":`carousel`,"aria-roledescription":`carousel`,tabIndex:0,onKeyDownCapture:k,className:e(`komc:relative`,d),...p,children:f})})}function f({children:t,className:n,...r}){let{carouselRef:i}=u();return s(`div`,{ref:i,"data-komc":!0,className:e(`komc:h-full komc:overflow-hidden`,n),...r,children:t})}function p({className:t,...n}){let{orientation:r}=u();return s(`div`,{className:e(`komc:flex komc:h-full`,r===`horizontal`?`komc:-ml-4`:`komc:-mt-4 komc:flex-col`,t),...n})}function m({className:t,...n}){let{orientation:r}=u();return s(`div`,{"data-komc":!0,className:e(`komc:min-w-0 komc:shrink-0 komc:grow-0 komc:basis-full`,r===`horizontal`?`komc:pl-4`:`komc:pt-4`,t),...n})}function h({children:e,className:n,...r}){let{scrollPrev:i,canScrollPrev:a}=u();return s(`button`,{type:`button`,"data-komc":!0,disabled:!a,"aria-label":`previous slide`,className:t(`komc:w-full`,n),onClick:i,...r,children:e})}function g({children:e,className:n,...r}){let{scrollNext:i,canScrollNext:a}=u();return s(`button`,{type:`button`,"data-komc":!0,disabled:!a,"aria-label":`next slide`,className:t(`komc:w-full`,n),onClick:i,...r,children:e})}function _({children:e,...t}){let{dots:n,selectedScrollSnap:r,scrollTo:i}=u();return s(o,{children:Array.from({length:n}).map((n,a)=>s(`button`,{type:`button`,"data-komc":!0,"data-selected":r===a,"aria-label":`go to slide ${a+1}`,onClick:()=>i(a),...t,children:e?.(a)},a))})}function v({index:e,children:t,...n}){let{selectedScrollSnap:r,scrollTo:i}=u();return s(`button`,{type:`button`,"data-komc":!0,"data-selected":r===e,"aria-label":`go to slide ${e+1}`,onClick:()=>i(e),...n,children:t})}export{d as Carousel,v as CarouselDot,_ as CarouselDots,m as CarouselItem,g as CarouselNext,h as CarouselPrevious,f as CarouselViewport,p as CarouselWrapper,u as useCarousel};
1
+ "use client";import{n as e}from"../../common-Df03Ovdm.mjs";import t from"clsx";import n,{useCallback as r,useEffect as i,useState as a}from"react";import{Fragment as o,jsx as s}from"react/jsx-runtime";import c from"embla-carousel-react";const l=n.createContext(null);function u(){let e=n.useContext(l);if(!e)throw Error(`useCarousel must be used within a <Carousel />`);return e}function d({orientation:t=`horizontal`,options:n,setApi:o,plugins:u,className:d,children:f,...p}){let[m,h]=c({...n,axis:t===`horizontal`?`x`:`y`},u),[g,_]=a(!1),[v,y]=a(!1),[b,x]=a(0),[S,C]=a(0),w=r(e=>{e&&(_(e.canScrollPrev()),y(e.canScrollNext()),C(e.selectedScrollSnap()))},[]),T=r(()=>{h?.scrollPrev()},[h]),E=r(()=>{h?.scrollNext()},[h]),D=r(e=>{h?.scrollTo(e)},[h]),O=r(()=>{x(h?.scrollSnapList().length||0)},[h]),k=r(e=>{t===`horizontal`?e.key===`ArrowLeft`?(e.preventDefault(),T()):e.key===`ArrowRight`&&(e.preventDefault(),E()):e.key===`ArrowUp`?(e.preventDefault(),T()):e.key===`ArrowDown`&&(e.preventDefault(),E())},[T,E,t]);return i(()=>{!h||!o||o(h)},[h,o]),i(()=>{if(h)return w(h),O(),h.on(`reInit`,O),h.on(`reInit`,w),h.on(`select`,w),()=>{h?.off(`select`,w)}},[h,O,w]),s(l.Provider,{value:{carouselRef:m,api:h,options:n,orientation:t||(n?.axis===`y`?`vertical`:`horizontal`),scrollPrev:T,scrollNext:E,canScrollPrev:g,canScrollNext:v,scrollTo:D,dots:b,selectedScrollSnap:S},children:s(`div`,{"data-komc":!0,role:`region`,"aria-label":`carousel`,"aria-roledescription":`carousel`,tabIndex:0,onKeyDownCapture:k,className:e(`komc:relative`,d),...p,children:f})})}function f({children:t,className:n,...r}){let{carouselRef:i}=u();return s(`div`,{ref:i,"data-komc":!0,className:e(`komc:h-full komc:overflow-hidden`,n),...r,children:t})}function p({className:t,...n}){let{orientation:r}=u();return s(`div`,{className:e(`komc:flex komc:h-full`,r===`horizontal`?`komc:-ml-4`:`komc:-mt-4 komc:flex-col`,t),...n})}function m({className:t,...n}){let{orientation:r}=u();return s(`div`,{"data-komc":!0,className:e(`komc:min-w-0 komc:shrink-0 komc:grow-0 komc:basis-full`,r===`horizontal`?`komc:pl-4`:`komc:pt-4`,t),...n})}function h({children:e,className:n,...r}){let{scrollPrev:i,canScrollPrev:a}=u();return s(`button`,{type:`button`,"data-komc":!0,disabled:!a,"aria-label":`previous slide`,className:t(`komc:w-full`,n),onClick:i,...r,children:e})}function g({children:e,className:n,...r}){let{scrollNext:i,canScrollNext:a}=u();return s(`button`,{type:`button`,"data-komc":!0,disabled:!a,"aria-label":`next slide`,className:t(`komc:w-full`,n),onClick:i,...r,children:e})}function _({children:e,...t}){let{dots:n,selectedScrollSnap:r,scrollTo:i}=u();return s(o,{children:Array.from({length:n}).map((n,a)=>s(`button`,{type:`button`,"data-komc":!0,"data-selected":r===a,"aria-label":`go to slide ${a+1}`,onClick:()=>i(a),...t,children:e?.(a)},a))})}function v({index:e,children:t,...n}){let{selectedScrollSnap:r,scrollTo:i}=u();return s(`button`,{type:`button`,"data-komc":!0,"data-selected":r===e,"aria-label":`go to slide ${e+1}`,onClick:()=>i(e),...n,children:t})}export{d as Carousel,v as CarouselDot,_ as CarouselDots,m as CarouselItem,g as CarouselNext,h as CarouselPrevious,f as CarouselViewport,p as CarouselWrapper,u as useCarousel};
@@ -1 +1 @@
1
- "use client";const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../src-CjpmdVyv.cjs`),require(`../../file-5mweNdAM.cjs`);const t=require(`../../hooks--O5RcEJq.cjs`);require(`../../providers-CkXkdYcB.cjs`),require(`../../use-subset-image-DhX5WmYG.cjs`);let n=require(`react`),r=require(`react/jsx-runtime`),i=require(`class-variance-authority`);const a=(0,i.cva)(`komc:relative komc:z-10 komc:flex komc:min-h-0 komc:flex-col komc:overflow-hidden komc:w-full komc:max-h-full komc:min-w-0 komc:transition-all komc:duration-300 komc:ease-in-out`,{variants:{padding:{sm:`komc:p-2`,md:`komc:p-4`,lg:`komc:p-6`,none:`komc:p-0`},maxWidth:{sm:`komc:max-w-sm`,md:`komc:max-w-md`,lg:`komc:max-w-lg`,xl:`komc:max-w-xl`,"2xl":`komc:max-w-2xl`,full:`komc:max-w-full`}},defaultVariants:{padding:`sm`,maxWidth:`md`}});function o({closeOnBackdropClick:e=!0,isOpen:i,zIndex:o=1e4,padding:s,maxWidth:c,className:l,onClose:u,children:d,...f}){let p=t.o(i,300),[m,h]=(0,n.useState)(!1);(0,n.useEffect)(()=>{if(i&&p){let e=setTimeout(()=>h(!0),10);return()=>clearTimeout(e)}else i||h(!1)},[i,p]);let g=(0,n.useCallback)(e=>{e.key===`Escape`&&u()},[u]),_=(0,n.useCallback)(()=>{e&&u()},[e,u]);return(0,n.useEffect)(()=>(i?(document.addEventListener(`keydown`,g),document.body.style.overflow=`hidden`):document.body.style.overflow=`unset`,()=>{document.removeEventListener(`keydown`,g),document.body.style.overflow=`unset`}),[i,g]),p?(0,r.jsx)(`div`,{"data-komc":!0,className:`komc:fixed komc:inset-0 komc:flex komc:min-h-0 komc:flex-col komc:overflow-hidden`,style:{zIndex:o},children:(0,r.jsxs)(`div`,{className:`komc:relative komc:flex komc:min-h-0 komc:flex-1 komc:w-full komc:items-center komc:justify-center`,children:[(0,r.jsx)(`button`,{type:`button`,"data-state":m?`open`:`closed`,className:`komc:fixed komc:inset-0 komc:z-0 komc:cursor-default komc:bg-black/50 komc:transition-opacity komc:duration-300 komc:ease-in-out komc:data-[state=closed]:opacity-0 komc:data-[state=open]:opacity-100`,onClick:_,"aria-label":`close dialog`}),(0,r.jsx)(`div`,{"data-state":m?`open`:`closed`,className:`${a({padding:s,maxWidth:c,className:l})} komc:data-[state=closed]:opacity-0 komc:data-[state=open]:opacity-100 komc:data-[state=closed]:scale-95 komc:data-[state=open]:scale-100`,role:`dialog`,"aria-modal":`true`,...f,children:d})]})}):null}exports.Dialog=o;
1
+ "use client";const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../src-CjpmdVyv.cjs`),require(`../../file-5mweNdAM.cjs`);const t=require(`../../hooks--O5RcEJq.cjs`);require(`../../providers-CkXkdYcB.cjs`),require(`../../use-subset-image-DC86cg6O.cjs`);let n=require(`react`),r=require(`react/jsx-runtime`),i=require(`class-variance-authority`);const a=(0,i.cva)(`komc:relative komc:z-10 komc:flex komc:min-h-0 komc:flex-col komc:overflow-hidden komc:w-full komc:max-h-full komc:min-w-0 komc:transition-all komc:duration-300 komc:ease-in-out`,{variants:{padding:{sm:`komc:p-2`,md:`komc:p-4`,lg:`komc:p-6`,none:`komc:p-0`},maxWidth:{sm:`komc:max-w-sm`,md:`komc:max-w-md`,lg:`komc:max-w-lg`,xl:`komc:max-w-xl`,"2xl":`komc:max-w-2xl`,full:`komc:max-w-full`}},defaultVariants:{padding:`sm`,maxWidth:`md`}});function o({closeOnBackdropClick:e=!0,isOpen:i,zIndex:o=1e4,padding:s,maxWidth:c,className:l,onClose:u,children:d,...f}){let p=t.o(i,300),[m,h]=(0,n.useState)(!1);(0,n.useEffect)(()=>{if(i&&p){let e=setTimeout(()=>h(!0),10);return()=>clearTimeout(e)}else i||h(!1)},[i,p]);let g=(0,n.useCallback)(e=>{e.key===`Escape`&&u()},[u]),_=(0,n.useCallback)(()=>{e&&u()},[e,u]);return(0,n.useEffect)(()=>(i?(document.addEventListener(`keydown`,g),document.body.style.overflow=`hidden`):document.body.style.overflow=`unset`,()=>{document.removeEventListener(`keydown`,g),document.body.style.overflow=`unset`}),[i,g]),p?(0,r.jsx)(`div`,{"data-komc":!0,className:`komc:fixed komc:inset-0 komc:flex komc:min-h-0 komc:flex-col komc:overflow-hidden`,style:{zIndex:o},children:(0,r.jsxs)(`div`,{className:`komc:relative komc:flex komc:min-h-0 komc:flex-1 komc:w-full komc:items-center komc:justify-center`,children:[(0,r.jsx)(`button`,{type:`button`,"data-state":m?`open`:`closed`,className:`komc:fixed komc:inset-0 komc:z-0 komc:cursor-default komc:bg-black/50 komc:transition-opacity komc:duration-300 komc:ease-in-out komc:data-[state=closed]:opacity-0 komc:data-[state=open]:opacity-100`,onClick:_,"aria-label":`close dialog`}),(0,r.jsx)(`div`,{"data-state":m?`open`:`closed`,className:`${a({padding:s,maxWidth:c,className:l})} komc:data-[state=closed]:opacity-0 komc:data-[state=open]:opacity-100 komc:data-[state=closed]:scale-95 komc:data-[state=open]:scale-100`,role:`dialog`,"aria-modal":`true`,...f,children:d})]})}):null}exports.Dialog=o;
@@ -1,11 +1,11 @@
1
1
  import { HTMLAttributes, ReactNode } from "react";
2
- import * as react_jsx_runtime0 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime1 from "react/jsx-runtime";
3
3
  import * as class_variance_authority_types0 from "class-variance-authority/types";
4
4
  import { VariantProps } from "class-variance-authority";
5
5
 
6
6
  //#region src/ui/dialog/dialog.d.ts
7
7
  declare const classes: (props?: ({
8
- padding?: "none" | "sm" | "md" | "lg" | null | undefined;
8
+ padding?: "sm" | "md" | "lg" | "none" | null | undefined;
9
9
  maxWidth?: "sm" | "md" | "lg" | "xl" | "2xl" | "full" | null | undefined;
10
10
  } & class_variance_authority_types0.ClassProp) | undefined) => string;
11
11
  interface DialogProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof classes> {
@@ -25,6 +25,6 @@ declare function Dialog({
25
25
  onClose,
26
26
  children,
27
27
  ...rest
28
- }: DialogProps): react_jsx_runtime0.JSX.Element | null;
28
+ }: DialogProps): react_jsx_runtime1.JSX.Element | null;
29
29
  //#endregion
30
30
  export { Dialog, type DialogProps };
@@ -5,7 +5,7 @@ import * as class_variance_authority_types0 from "class-variance-authority/types
5
5
 
6
6
  //#region src/ui/dialog/dialog.d.ts
7
7
  declare const classes: (props?: ({
8
- padding?: "none" | "sm" | "md" | "lg" | null | undefined;
8
+ padding?: "sm" | "md" | "lg" | "none" | null | undefined;
9
9
  maxWidth?: "sm" | "md" | "lg" | "xl" | "2xl" | "full" | null | undefined;
10
10
  } & class_variance_authority_types0.ClassProp) | undefined) => string;
11
11
  interface DialogProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof classes> {
@@ -1 +1 @@
1
- "use client";import"../../src-CukOR3K2.mjs";import"../../file-DShNxIW4.mjs";import{o as e}from"../../hooks-C9rXWkfW.mjs";import"../../providers-zftmvT1z.mjs";import"../../use-subset-image-DvV5Mlkc.mjs";import{useCallback as t,useEffect as n,useState as r}from"react";import{jsx as i,jsxs as a}from"react/jsx-runtime";import{cva as o}from"class-variance-authority";const s=o(`komc:relative komc:z-10 komc:flex komc:min-h-0 komc:flex-col komc:overflow-hidden komc:w-full komc:max-h-full komc:min-w-0 komc:transition-all komc:duration-300 komc:ease-in-out`,{variants:{padding:{sm:`komc:p-2`,md:`komc:p-4`,lg:`komc:p-6`,none:`komc:p-0`},maxWidth:{sm:`komc:max-w-sm`,md:`komc:max-w-md`,lg:`komc:max-w-lg`,xl:`komc:max-w-xl`,"2xl":`komc:max-w-2xl`,full:`komc:max-w-full`}},defaultVariants:{padding:`sm`,maxWidth:`md`}});function c({closeOnBackdropClick:o=!0,isOpen:c,zIndex:l=1e4,padding:u,maxWidth:d,className:f,onClose:p,children:m,...h}){let g=e(c,300),[_,v]=r(!1);n(()=>{if(c&&g){let e=setTimeout(()=>v(!0),10);return()=>clearTimeout(e)}else c||v(!1)},[c,g]);let y=t(e=>{e.key===`Escape`&&p()},[p]),b=t(()=>{o&&p()},[o,p]);return n(()=>(c?(document.addEventListener(`keydown`,y),document.body.style.overflow=`hidden`):document.body.style.overflow=`unset`,()=>{document.removeEventListener(`keydown`,y),document.body.style.overflow=`unset`}),[c,y]),g?i(`div`,{"data-komc":!0,className:`komc:fixed komc:inset-0 komc:flex komc:min-h-0 komc:flex-col komc:overflow-hidden`,style:{zIndex:l},children:a(`div`,{className:`komc:relative komc:flex komc:min-h-0 komc:flex-1 komc:w-full komc:items-center komc:justify-center`,children:[i(`button`,{type:`button`,"data-state":_?`open`:`closed`,className:`komc:fixed komc:inset-0 komc:z-0 komc:cursor-default komc:bg-black/50 komc:transition-opacity komc:duration-300 komc:ease-in-out komc:data-[state=closed]:opacity-0 komc:data-[state=open]:opacity-100`,onClick:b,"aria-label":`close dialog`}),i(`div`,{"data-state":_?`open`:`closed`,className:`${s({padding:u,maxWidth:d,className:f})} komc:data-[state=closed]:opacity-0 komc:data-[state=open]:opacity-100 komc:data-[state=closed]:scale-95 komc:data-[state=open]:scale-100`,role:`dialog`,"aria-modal":`true`,...h,children:m})]})}):null}export{c as Dialog};
1
+ "use client";import"../../src-CukOR3K2.mjs";import"../../file-DShNxIW4.mjs";import{o as e}from"../../hooks-C9rXWkfW.mjs";import"../../providers-zftmvT1z.mjs";import"../../use-subset-image-D8ssrZhj.mjs";import{useCallback as t,useEffect as n,useState as r}from"react";import{jsx as i,jsxs as a}from"react/jsx-runtime";import{cva as o}from"class-variance-authority";const s=o(`komc:relative komc:z-10 komc:flex komc:min-h-0 komc:flex-col komc:overflow-hidden komc:w-full komc:max-h-full komc:min-w-0 komc:transition-all komc:duration-300 komc:ease-in-out`,{variants:{padding:{sm:`komc:p-2`,md:`komc:p-4`,lg:`komc:p-6`,none:`komc:p-0`},maxWidth:{sm:`komc:max-w-sm`,md:`komc:max-w-md`,lg:`komc:max-w-lg`,xl:`komc:max-w-xl`,"2xl":`komc:max-w-2xl`,full:`komc:max-w-full`}},defaultVariants:{padding:`sm`,maxWidth:`md`}});function c({closeOnBackdropClick:o=!0,isOpen:c,zIndex:l=1e4,padding:u,maxWidth:d,className:f,onClose:p,children:m,...h}){let g=e(c,300),[_,v]=r(!1);n(()=>{if(c&&g){let e=setTimeout(()=>v(!0),10);return()=>clearTimeout(e)}else c||v(!1)},[c,g]);let y=t(e=>{e.key===`Escape`&&p()},[p]),b=t(()=>{o&&p()},[o,p]);return n(()=>(c?(document.addEventListener(`keydown`,y),document.body.style.overflow=`hidden`):document.body.style.overflow=`unset`,()=>{document.removeEventListener(`keydown`,y),document.body.style.overflow=`unset`}),[c,y]),g?i(`div`,{"data-komc":!0,className:`komc:fixed komc:inset-0 komc:flex komc:min-h-0 komc:flex-col komc:overflow-hidden`,style:{zIndex:l},children:a(`div`,{className:`komc:relative komc:flex komc:min-h-0 komc:flex-1 komc:w-full komc:items-center komc:justify-center`,children:[i(`button`,{type:`button`,"data-state":_?`open`:`closed`,className:`komc:fixed komc:inset-0 komc:z-0 komc:cursor-default komc:bg-black/50 komc:transition-opacity komc:duration-300 komc:ease-in-out komc:data-[state=closed]:opacity-0 komc:data-[state=open]:opacity-100`,onClick:b,"aria-label":`close dialog`}),i(`div`,{"data-state":_?`open`:`closed`,className:`${s({padding:u,maxWidth:d,className:f})} komc:data-[state=closed]:opacity-0 komc:data-[state=open]:opacity-100 komc:data-[state=closed]:scale-95 komc:data-[state=open]:scale-100`,role:`dialog`,"aria-modal":`true`,...h,children:m})]})}):null}export{c as Dialog};
@@ -1 +1 @@
1
- "use client";const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../src-CjpmdVyv.cjs`),require(`../../common-CQWUs1nE.cjs`),require(`../../file-5mweNdAM.cjs`);const t=require(`../../skeleton-DBha34Cx.cjs`);require(`../../providers-CkXkdYcB.cjs`);const n=require(`../../use-subset-image-DhX5WmYG.cjs`);let r=require(`clsx`);r=e.t(r);let i=require(`react`),a=require(`react/jsx-runtime`),o=require(`class-variance-authority`);const s=(0,o.cva)(``,{variants:{fill:{true:`komc:w-full komc:h-full komc:absolute komc:inset-0`,false:``}},defaultVariants:{fill:!1}}),c=(0,i.forwardRef)(({...e},t)=>{let{ref:r,imageProps:i}=n.n({ref:t,...e});return(0,a.jsx)(`img`,{ref:r,...i})}),l=(0,i.forwardRef)(({skeleton:e=!0,layout:i=`stretch`,fallbackSrc:o,className:c,emptyNode:l,emptyNodeClassName:d,skeletonClassName:f,...p},m)=>{let{ref:h,isLoad:g,isError:_,imageProps:v}=n.n({ref:m,fallbackSrc:o,forceLoad:!e,...p}),y=!p.fill&&i===`intrinsic`?{width:`${p.width}px`,height:`${p.height}px`}:void 0,b=(0,r.default)(`komc:flex komc:justify-center komc:items-center komc:relative komc:min-h-0`,!p.fill&&i===`stretch`&&`komc:w-full komc:h-full`);return!o&&_&&l?p.fill?(0,a.jsx)(u,{className:d,children:l}):(0,a.jsx)(`div`,{"data-komc":!0,style:y,className:b,children:(0,a.jsx)(u,{className:d,children:l})}):p.fill?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(`img`,{ref:h,...v,className:(0,r.default)(`komc:w-full komc:h-full komc:absolute komc:inset-0`,e&&!g?`komc:invisible`:`komc:visible`,c)}),(0,a.jsx)(`div`,{"data-komc":!0,className:(0,r.default)(`komc:w-full komc:h-full komc:absolute komc:inset-0`,e&&!g?`komc:block`:`komc:hidden`),children:(0,a.jsx)(t.t,{size:`full`,className:f})})]}):(0,a.jsxs)(`div`,{"data-komc":!0,style:y,className:b,children:[(0,a.jsx)(`img`,{ref:h,...v,className:(0,r.default)(s({fill:p.fill,className:c}),e&&!g?`komc:invisible`:`komc:visible`)}),(0,a.jsx)(`div`,{className:(0,r.default)(`komc:w-full komc:h-full komc:absolute komc:inset-0`,e&&!g?`komc:block`:`komc:hidden`),children:(0,a.jsx)(t.t,{size:`full`,className:f})})]})}),u=({children:e,className:t})=>(0,a.jsx)(`div`,{"data-komc":!0,role:`alert`,className:(0,r.default)(`komc:flex komc:justify-center komc:items-center komc:w-full komc:h-full komc:bg-gray-100 komc:absolute komc:inset-0 komc:p-1`,t),children:e});var d=l;exports.BaseImage=c,exports.EmptyNode=u,exports.Image=d;
1
+ "use client";const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../src-CjpmdVyv.cjs`),require(`../../common-Bn0Ko6B7.cjs`),require(`../../file-5mweNdAM.cjs`);const t=require(`../../skeleton-DtV9S1QK.cjs`);require(`../../providers-CkXkdYcB.cjs`);const n=require(`../../use-subset-image-DC86cg6O.cjs`);let r=require(`clsx`);r=e.t(r);let i=require(`react`),a=require(`react/jsx-runtime`),o=require(`class-variance-authority`);const s=(0,o.cva)(``,{variants:{fill:{true:`komc:w-full komc:h-full komc:absolute komc:inset-0`,false:``}},defaultVariants:{fill:!1}}),c=(0,i.forwardRef)(({...e},t)=>{let{ref:r,imageProps:i}=n.n({ref:t,...e});return(0,a.jsx)(`img`,{ref:r,...i})}),l=(0,i.forwardRef)(({skeleton:e=!0,layout:i=`stretch`,fallbackSrc:o,className:c,emptyNode:l,emptyNodeClassName:d,skeletonClassName:f,...p},m)=>{let{ref:h,isLoad:g,isError:_,imageProps:v}=n.n({ref:m,fallbackSrc:o,forceLoad:!e,...p}),y=!p.fill&&i===`intrinsic`?{width:`${p.width}px`,height:`${p.height}px`}:void 0,b=(0,r.default)(`komc:flex komc:justify-center komc:items-center komc:relative komc:min-h-0`,!p.fill&&i===`stretch`&&`komc:w-full komc:h-full`);return!o&&_&&l?p.fill?(0,a.jsx)(u,{className:d,children:l}):(0,a.jsx)(`div`,{"data-komc":!0,style:y,className:b,children:(0,a.jsx)(u,{className:d,children:l})}):p.fill?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(`img`,{ref:h,...v,className:(0,r.default)(`komc:w-full komc:h-full komc:absolute komc:inset-0`,e&&!g?`komc:invisible`:`komc:visible`,c)}),(0,a.jsx)(`div`,{"data-komc":!0,className:(0,r.default)(`komc:w-full komc:h-full komc:absolute komc:inset-0`,e&&!g?`komc:block`:`komc:hidden`),children:(0,a.jsx)(t.t,{size:`full`,className:f})})]}):(0,a.jsxs)(`div`,{"data-komc":!0,style:y,className:b,children:[(0,a.jsx)(`img`,{ref:h,...v,className:(0,r.default)(s({fill:p.fill,className:c}),e&&!g?`komc:invisible`:`komc:visible`)}),(0,a.jsx)(`div`,{className:(0,r.default)(`komc:w-full komc:h-full komc:absolute komc:inset-0`,e&&!g?`komc:block`:`komc:hidden`),children:(0,a.jsx)(t.t,{size:`full`,className:f})})]})}),u=({children:e,className:t})=>(0,a.jsx)(`div`,{"data-komc":!0,role:`alert`,className:(0,r.default)(`komc:flex komc:justify-center komc:items-center komc:w-full komc:h-full komc:bg-gray-100 komc:absolute komc:inset-0 komc:p-1`,t),children:e});var d=l;exports.BaseImage=c,exports.EmptyNode=u,exports.Image=d;
@@ -1,15 +1,15 @@
1
- import { a as UseSubsetImageProps, n as BaseProps } from "../../index-4pIelCz_.cjs";
1
+ import { a as UseSubsetImageProps, n as BaseProps } from "../../index-B11XDBo5.cjs";
2
2
  import * as react0 from "react";
3
3
  import * as react_jsx_runtime0 from "react/jsx-runtime";
4
4
 
5
5
  //#region src/ui/image/image.d.ts
6
- type ImageSubsetProps = {
6
+ interface ImageSubsetProps {
7
7
  layout?: 'intrinsic' | 'stretch';
8
8
  skeleton?: boolean;
9
9
  emptyNode?: React.ReactNode;
10
10
  emptyNodeClassName?: string;
11
11
  skeletonClassName?: string;
12
- };
12
+ }
13
13
  type ImageProps = UseSubsetImageProps & ImageSubsetProps;
14
14
  declare const BaseImage: react0.ForwardRefExoticComponent<(Omit<BaseProps & {
15
15
  fill: true;
@@ -1,17 +1,17 @@
1
- import { a as UseSubsetImageProps, n as BaseProps } from "../../index-BFHrNSKP.mjs";
2
- import * as react3 from "react";
3
- import * as react_jsx_runtime9 from "react/jsx-runtime";
1
+ import { a as UseSubsetImageProps, n as BaseProps } from "../../index-dbBlRf5k.mjs";
2
+ import * as react2 from "react";
3
+ import * as react_jsx_runtime8 from "react/jsx-runtime";
4
4
 
5
5
  //#region src/ui/image/image.d.ts
6
- type ImageSubsetProps = {
6
+ interface ImageSubsetProps {
7
7
  layout?: 'intrinsic' | 'stretch';
8
8
  skeleton?: boolean;
9
9
  emptyNode?: React.ReactNode;
10
10
  emptyNodeClassName?: string;
11
11
  skeletonClassName?: string;
12
- };
12
+ }
13
13
  type ImageProps = UseSubsetImageProps & ImageSubsetProps;
14
- declare const BaseImage: react3.ForwardRefExoticComponent<(Omit<BaseProps & {
14
+ declare const BaseImage: react2.ForwardRefExoticComponent<(Omit<BaseProps & {
15
15
  fill: true;
16
16
  sizes: string;
17
17
  width?: never;
@@ -21,8 +21,8 @@ declare const BaseImage: react3.ForwardRefExoticComponent<(Omit<BaseProps & {
21
21
  sizes?: never;
22
22
  width: number;
23
23
  height: number;
24
- }, "ref">) & react3.RefAttributes<HTMLImageElement>>;
25
- declare const Image: react3.ForwardRefExoticComponent<(Omit<BaseProps & {
24
+ }, "ref">) & react2.RefAttributes<HTMLImageElement>>;
25
+ declare const Image: react2.ForwardRefExoticComponent<(Omit<BaseProps & {
26
26
  fill: true;
27
27
  sizes: string;
28
28
  width?: never;
@@ -32,7 +32,7 @@ declare const Image: react3.ForwardRefExoticComponent<(Omit<BaseProps & {
32
32
  sizes?: never;
33
33
  width: number;
34
34
  height: number;
35
- } & ImageSubsetProps, "ref">) & react3.RefAttributes<HTMLImageElement>>;
35
+ } & ImageSubsetProps, "ref">) & react2.RefAttributes<HTMLImageElement>>;
36
36
  interface EmptyNodeProps {
37
37
  children: React.ReactNode;
38
38
  className?: string;
@@ -40,6 +40,6 @@ interface EmptyNodeProps {
40
40
  declare const EmptyNode: ({
41
41
  children,
42
42
  className
43
- }: EmptyNodeProps) => react_jsx_runtime9.JSX.Element;
43
+ }: EmptyNodeProps) => react_jsx_runtime8.JSX.Element;
44
44
  //#endregion
45
45
  export { BaseImage, EmptyNode, type EmptyNodeProps, Image, type ImageProps, type ImageSubsetProps };
@@ -1 +1 @@
1
- "use client";import"../../src-CukOR3K2.mjs";import"../../common-DbEp6YNc.mjs";import"../../file-DShNxIW4.mjs";import{t as e}from"../../skeleton-6QtpIO7l.mjs";import"../../providers-zftmvT1z.mjs";import{n as t}from"../../use-subset-image-DvV5Mlkc.mjs";import n from"clsx";import{forwardRef as r}from"react";import{Fragment as i,jsx as a,jsxs as o}from"react/jsx-runtime";import{cva as s}from"class-variance-authority";const c=s(``,{variants:{fill:{true:`komc:w-full komc:h-full komc:absolute komc:inset-0`,false:``}},defaultVariants:{fill:!1}}),l=r(({...e},n)=>{let{ref:r,imageProps:i}=t({ref:n,...e});return a(`img`,{ref:r,...i})}),u=r(({skeleton:r=!0,layout:s=`stretch`,fallbackSrc:l,className:u,emptyNode:f,emptyNodeClassName:p,skeletonClassName:m,...h},g)=>{let{ref:_,isLoad:v,isError:y,imageProps:b}=t({ref:g,fallbackSrc:l,forceLoad:!r,...h}),x=!h.fill&&s===`intrinsic`?{width:`${h.width}px`,height:`${h.height}px`}:void 0,S=n(`komc:flex komc:justify-center komc:items-center komc:relative komc:min-h-0`,!h.fill&&s===`stretch`&&`komc:w-full komc:h-full`);return!l&&y&&f?h.fill?a(d,{className:p,children:f}):a(`div`,{"data-komc":!0,style:x,className:S,children:a(d,{className:p,children:f})}):h.fill?o(i,{children:[a(`img`,{ref:_,...b,className:n(`komc:w-full komc:h-full komc:absolute komc:inset-0`,r&&!v?`komc:invisible`:`komc:visible`,u)}),a(`div`,{"data-komc":!0,className:n(`komc:w-full komc:h-full komc:absolute komc:inset-0`,r&&!v?`komc:block`:`komc:hidden`),children:a(e,{size:`full`,className:m})})]}):o(`div`,{"data-komc":!0,style:x,className:S,children:[a(`img`,{ref:_,...b,className:n(c({fill:h.fill,className:u}),r&&!v?`komc:invisible`:`komc:visible`)}),a(`div`,{className:n(`komc:w-full komc:h-full komc:absolute komc:inset-0`,r&&!v?`komc:block`:`komc:hidden`),children:a(e,{size:`full`,className:m})})]})}),d=({children:e,className:t})=>a(`div`,{"data-komc":!0,role:`alert`,className:n(`komc:flex komc:justify-center komc:items-center komc:w-full komc:h-full komc:bg-gray-100 komc:absolute komc:inset-0 komc:p-1`,t),children:e});var f=u;export{l as BaseImage,d as EmptyNode,f as Image};
1
+ "use client";import"../../src-CukOR3K2.mjs";import"../../common-Df03Ovdm.mjs";import"../../file-DShNxIW4.mjs";import{t as e}from"../../skeleton-B6_oBhkl.mjs";import"../../providers-zftmvT1z.mjs";import{n as t}from"../../use-subset-image-D8ssrZhj.mjs";import n from"clsx";import{forwardRef as r}from"react";import{Fragment as i,jsx as a,jsxs as o}from"react/jsx-runtime";import{cva as s}from"class-variance-authority";const c=s(``,{variants:{fill:{true:`komc:w-full komc:h-full komc:absolute komc:inset-0`,false:``}},defaultVariants:{fill:!1}}),l=r(({...e},n)=>{let{ref:r,imageProps:i}=t({ref:n,...e});return a(`img`,{ref:r,...i})}),u=r(({skeleton:r=!0,layout:s=`stretch`,fallbackSrc:l,className:u,emptyNode:f,emptyNodeClassName:p,skeletonClassName:m,...h},g)=>{let{ref:_,isLoad:v,isError:y,imageProps:b}=t({ref:g,fallbackSrc:l,forceLoad:!r,...h}),x=!h.fill&&s===`intrinsic`?{width:`${h.width}px`,height:`${h.height}px`}:void 0,S=n(`komc:flex komc:justify-center komc:items-center komc:relative komc:min-h-0`,!h.fill&&s===`stretch`&&`komc:w-full komc:h-full`);return!l&&y&&f?h.fill?a(d,{className:p,children:f}):a(`div`,{"data-komc":!0,style:x,className:S,children:a(d,{className:p,children:f})}):h.fill?o(i,{children:[a(`img`,{ref:_,...b,className:n(`komc:w-full komc:h-full komc:absolute komc:inset-0`,r&&!v?`komc:invisible`:`komc:visible`,u)}),a(`div`,{"data-komc":!0,className:n(`komc:w-full komc:h-full komc:absolute komc:inset-0`,r&&!v?`komc:block`:`komc:hidden`),children:a(e,{size:`full`,className:m})})]}):o(`div`,{"data-komc":!0,style:x,className:S,children:[a(`img`,{ref:_,...b,className:n(c({fill:h.fill,className:u}),r&&!v?`komc:invisible`:`komc:visible`)}),a(`div`,{className:n(`komc:w-full komc:h-full komc:absolute komc:inset-0`,r&&!v?`komc:block`:`komc:hidden`),children:a(e,{size:`full`,className:m})})]})}),d=({children:e,className:t})=>a(`div`,{"data-komc":!0,role:`alert`,className:n(`komc:flex komc:justify-center komc:items-center komc:w-full komc:h-full komc:bg-gray-100 komc:absolute komc:inset-0 komc:p-1`,t),children:e});var f=u;export{l as BaseImage,d as EmptyNode,f as Image};
package/dist/ui/index.cjs CHANGED
@@ -1 +1 @@
1
- const e=require(`../chunk-Bmb41Sf3.cjs`),t=require(`../common-CQWUs1nE.cjs`),n=require(`../skeleton-DBha34Cx.cjs`);let r=require(`clsx`);r=e.t(r);let i=require(`react`);i=e.t(i);let a=require(`react/jsx-runtime`),o=require(`class-variance-authority`),s=require(`@radix-ui/react-slot`);function c({className:e,items:t,render:n,...o}){return(0,a.jsx)(`nav`,{"data-komc":!0,"aria-label":`bottom app bar`,className:(0,r.default)(`komc:fixed komc:bottom-0 komc:left-0 komc:right-0`,`komc:border-t komc:border-neutral-200 komc:bg-white komc:z-10`,e),...o,children:(0,a.jsx)(`div`,{className:`komc:grid komc:min-h-15`,style:{gridTemplateColumns:`repeat(${t.length}, 1fr)`},children:t.map((e,t)=>(0,a.jsx)(i.default.Fragment,{children:n(e)},t))})})}const l=(0,o.cva)(t.n(`komc:flex komc:justify-center komc:items-center komc:gap-x-2 komc:w-full`,`komc:transition-colors komc:duration-200 komc:relative`,`komc:[&_svg]:transition-colors komc:[&_svg]:duration-200`,`komc:cursor-pointer komc:disabled:cursor-default`),{variants:{size:{xxs:`komc:h-7.5`,xs:`komc:h-8`,sm:`komc:h-9`,md:`komc:h-10`,lg:`komc:h-11`,xl:`komc:h-12`,"2xl":`komc:h-13`,"3xl":`komc:h-14`,"4xl":`komc:h-15`},shadow:{none:``,sm:`komc:drop-shadow-sm`,md:`komc:drop-shadow-md`,lg:`komc:drop-shadow-lg`,xl:`komc:drop-shadow-xl`,"2xl":`komc:drop-shadow-2xl`,"3xl":`komc:drop-shadow-3xl`},outline:{line:`komc:border`,solid:`komc:border komc:border-transparent`,clear:`komc:border-none`},variant:{blue:``,duo:``,white:``,gray:``,neutral:``,night:``,black:``,sky:``,"sky-blue":``,indigo:``},px:{none:`komc:px-0`,xs:`komc:px-0.5`,sm:`komc:px-1`,md:`komc:px-1.5`,lg:`komc:px-2`,xl:`komc:px-3`,"2xl":`komc:px-4`,"3xl":`komc:px-5`,"4xl":`komc:px-6`},rounded:{none:`komc:rounded-none`,sm:`komc:rounded-sm`,md:`komc:rounded-md`,lg:`komc:rounded-lg`,xl:`komc:rounded-xl`,"2xl":`komc:rounded-2xl`,"3xl":`komc:rounded-3xl`,full:`komc:rounded-full`}},compoundVariants:[{outline:`line`,variant:`blue`,className:t.n(`komc:border-blue-500 komc:bg-white komc:text-blue-500`,`komc:hover:border-transparent komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:border-transparent komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`duo`,className:t.n(`komc:border-blue-500 komc:bg-white komc:text-brand-blck`,`komc:hover:border-transparent komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:border-transparent komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`white`,className:t.n(`komc:border-gray-600 komc:bg-white komc:text-brand-blck`,`komc:hover:bg-gray-200 komc:hover:text-brand-blck`,`komc:active:bg-gray-200 komc:active:text-brand-blck`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`gray`,className:t.n(`komc:border-white komc:bg-transparent komc:text-white`,`komc:hover:bg-[rgb(199,199,199)] komc:hover:text-white`,`komc:active:bg-[rgb(199,199,199)] komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`neutral`,className:t.n(`komc:border-gray-800 komc:bg-transparent komc:text-black`,`komc:hover:bg-gray-200 komc:hover:text-black`,`komc:active:bg-gray-200 komc:active:text-black`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`line`,variant:`sky`,className:t.n(`komc:border-sky-750 komc:bg-transparent komc:text-black`,`komc:hover:bg-sky-750 komc:hover:text-white`,`komc:active:bg-sky-750 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`line`,variant:`sky-blue`,className:t.n(`komc:border-sky-450 komc:bg-transparent komc:text-black`,`komc:hover:bg-sky-450 komc:hover:text-white`,`komc:active:bg-sky-450 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`solid`,variant:`white`,className:t.n(`komc:bg-white komc:text-brand-blck`,`komc:hover:bg-gray-200`,`komc:active:bg-gray-200`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`gray`,className:t.n(`komc:bg-gray-100 komc:text-blue-500`,`komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`blue`,className:t.n(`komc:bg-blue-500 komc:text-white`,`komc:hover:bg-night-700 komc:hover:text-white`,`komc:active:bg-night-700 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`night`,className:t.n(`komc:bg-night-700 komc:text-white`,`komc:hover:bg-night-800 komc:hover:text-white`,`komc:active:bg-night-800 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`black`,className:t.n(`komc:bg-[rgb(95,95,96)] komc:text-white`,`komc:hover:bg-[rgb(76,76,77)] komc:hover:text-white`,`komc:active:bg-[rgb(76,76,77)] komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`sky`,className:t.n(`komc:bg-sky-750 komc:text-white`,`komc:hover:bg-sky-950 komc:hover:text-white`,`komc:active:bg-sky-950 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`solid`,variant:`sky-blue`,className:t.n(`komc:bg-sky-450 komc:text-white`,`komc:hover:bg-sky-650 komc:hover:text-white`,`komc:active:bg-sky-650 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`solid`,variant:`indigo`,className:t.n(`komc:bg-indigo-600 komc:text-white`,`komc:hover:bg-indigo-700 komc:hover:text-white`,`komc:active:bg-indigo-700 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`clear`,variant:`sky`,className:t.n(`komc:bg-transparent komc:text-[#1890FF]`,`komc:hover:bg-transparent komc:hover:text-[#1890FF] komc:hover:underline`,`komc:active:bg-transparent komc:active:text-[#1890FF] komc:active:underline`,`komc:disabled:border-transparent komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`clear`,variant:`gray`,className:t.n(`komc:bg-transparent komc:text-gray-800`,`komc:hover:bg-transparent komc:hover:text-gray-800 komc:hover:underline`,`komc:active:bg-transparent komc:active:text-gray-800 komc:active:underline`,`komc:disabled:border-transparent komc:disabled:bg-transparent komc:disabled:text-gray-500`)}],defaultVariants:{size:`md`,shadow:`none`,outline:`line`,variant:`blue`,px:`2xl`,rounded:`sm`}}),u=(0,i.forwardRef)(({type:e=`button`,className:t,id:n,size:r,shadow:i,outline:o,variant:c,px:u,rounded:d,asChild:f,...p},m)=>(0,a.jsx)(f?s.Slot:`button`,{ref:m,...p,type:e,id:n,className:l({size:r,shadow:i,outline:o,variant:c,px:u,rounded:d,className:t})}));var d=u;function f({condition:e,wrapper:t,children:n}){return e?t(n):n}function p({condition:e,trueWrapper:t,falseWrapper:n,children:r}){return e?t(r):n(r)}const m=(0,o.cva)(t.n(`komc:flex komc:items-center komc:w-full komc:px-2`,`komc:[&>input]:outline-none komc:[&>input]:w-full`,`komc:[&>input]:focus:ring-0 komc:[&>input]:focus:ring-offset-0`,`komc:[&>input]:h-full`),{variants:{size:{xs:`komc:h-7.5`,sm:`komc:h-8`,base:`komc:h-9`,md:`komc:h-10`,lg:`komc:h-11`,xl:`komc:h-12`,"2xl":`komc:h-13`,"3xl":`komc:h-14`},gap:{none:`komc:gap-0`,xs:`komc:gap-1`,sm:`komc:gap-2`,md:`komc:gap-3`,lg:`komc:gap-4`,xl:`komc:gap-5`},outline:{line:`komc:border`,solid:`komc:border-transparent`,clear:`komc:border-none`,dashed:`komc:border-dashed`,dotted:`komc:border-dotted`},rounded:{none:`komc:rounded-none`,sm:`komc:rounded-sm`,md:`komc:rounded-md`,lg:`komc:rounded-lg`,xl:`komc:rounded-xl`,"2xl":`komc:rounded-2xl`}}}),h=(0,i.forwardRef)(({prefix:e=null,surffix:t=null,size:n=`lg`,gap:r=`xl`,outline:i=`line`,rounded:o=`lg`,className:s,...c},l)=>(0,a.jsxs)(`div`,{"data-komc":!0,className:m({size:n,gap:r,outline:i,rounded:o,className:s}),children:[e,(0,a.jsx)(`input`,{ref:l,type:`text`,...c}),t]}));var g=h;function _({children:e,className:t,...n}){return(0,a.jsx)(`span`,{...n,"data-komc":!0,"data-text":`${e}`,className:(0,r.default)(`komc:inline-flex komc:flex-col komc:justify-center komc:items-center`,`komc:after:content-[attr(data-text)] komc:after:font-bold`,`komc:after:h-0 komc:after:invisible komc:after:overflow-hidden`,`komc:after:select-none komc:after:pointer-events-none`,t),children:e})}exports.BottomAppBar=c,exports.Button=d,exports.ConditionalEitherWrapper=p,exports.ConditionalWrapper=f,exports.Input=g,exports.Skeleton=n.t,exports.StableText=_;
1
+ const e=require(`../chunk-Bmb41Sf3.cjs`),t=require(`../common-Bn0Ko6B7.cjs`),n=require(`../skeleton-DtV9S1QK.cjs`);let r=require(`clsx`);r=e.t(r);let i=require(`react`);i=e.t(i);let a=require(`react/jsx-runtime`),o=require(`class-variance-authority`),s=require(`@radix-ui/react-slot`);function c({className:e,items:t,render:n,...o}){return(0,a.jsx)(`nav`,{"data-komc":!0,"aria-label":`bottom app bar`,className:(0,r.default)(`komc:fixed komc:bottom-0 komc:left-0 komc:right-0`,`komc:border-t komc:border-neutral-200 komc:bg-white komc:z-10`,e),...o,children:(0,a.jsx)(`div`,{className:`komc:grid komc:min-h-15`,style:{gridTemplateColumns:`repeat(${t.length}, 1fr)`},children:t.map((e,t)=>(0,a.jsx)(i.default.Fragment,{children:n(e)},t))})})}const l=(0,o.cva)(t.n(`komc:flex komc:justify-center komc:items-center komc:gap-x-2 komc:w-full`,`komc:transition-colors komc:duration-200 komc:relative`,`komc:[&_svg]:transition-colors komc:[&_svg]:duration-200`,`komc:cursor-pointer komc:disabled:cursor-default`),{variants:{size:{xxs:`komc:h-7.5`,xs:`komc:h-8`,sm:`komc:h-9`,md:`komc:h-10`,lg:`komc:h-11`,xl:`komc:h-12`,"2xl":`komc:h-13`,"3xl":`komc:h-14`,"4xl":`komc:h-15`},shadow:{none:``,sm:`komc:drop-shadow-sm`,md:`komc:drop-shadow-md`,lg:`komc:drop-shadow-lg`,xl:`komc:drop-shadow-xl`,"2xl":`komc:drop-shadow-2xl`,"3xl":`komc:drop-shadow-3xl`},outline:{line:`komc:border`,solid:`komc:border komc:border-transparent`,clear:`komc:border-none`},variant:{blue:``,duo:``,white:``,gray:``,neutral:``,night:``,black:``,sky:``,"sky-blue":``,indigo:``},px:{none:`komc:px-0`,xs:`komc:px-0.5`,sm:`komc:px-1`,md:`komc:px-1.5`,lg:`komc:px-2`,xl:`komc:px-3`,"2xl":`komc:px-4`,"3xl":`komc:px-5`,"4xl":`komc:px-6`},rounded:{none:`komc:rounded-none`,sm:`komc:rounded-sm`,md:`komc:rounded-md`,lg:`komc:rounded-lg`,xl:`komc:rounded-xl`,"2xl":`komc:rounded-2xl`,"3xl":`komc:rounded-3xl`,full:`komc:rounded-full`}},compoundVariants:[{outline:`line`,variant:`blue`,className:t.n(`komc:border-blue-500 komc:bg-white komc:text-blue-500`,`komc:hover:border-transparent komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:border-transparent komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`duo`,className:t.n(`komc:border-blue-500 komc:bg-white komc:text-brand-blck`,`komc:hover:border-transparent komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:border-transparent komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`white`,className:t.n(`komc:border-gray-600 komc:bg-white komc:text-brand-blck`,`komc:hover:bg-gray-200 komc:hover:text-brand-blck`,`komc:active:bg-gray-200 komc:active:text-brand-blck`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`gray`,className:t.n(`komc:border-white komc:bg-transparent komc:text-white`,`komc:hover:bg-[rgb(199,199,199)] komc:hover:text-white`,`komc:active:bg-[rgb(199,199,199)] komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`neutral`,className:t.n(`komc:border-gray-800 komc:bg-transparent komc:text-black`,`komc:hover:bg-gray-200 komc:hover:text-black`,`komc:active:bg-gray-200 komc:active:text-black`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`line`,variant:`sky`,className:t.n(`komc:border-sky-750 komc:bg-transparent komc:text-black`,`komc:hover:bg-sky-750 komc:hover:text-white`,`komc:active:bg-sky-750 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`line`,variant:`sky-blue`,className:t.n(`komc:border-sky-450 komc:bg-transparent komc:text-black`,`komc:hover:bg-sky-450 komc:hover:text-white`,`komc:active:bg-sky-450 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`solid`,variant:`white`,className:t.n(`komc:bg-white komc:text-brand-blck`,`komc:hover:bg-gray-200`,`komc:active:bg-gray-200`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`gray`,className:t.n(`komc:bg-gray-100 komc:text-blue-500`,`komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`blue`,className:t.n(`komc:bg-blue-500 komc:text-white`,`komc:hover:bg-night-700 komc:hover:text-white`,`komc:active:bg-night-700 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`night`,className:t.n(`komc:bg-night-700 komc:text-white`,`komc:hover:bg-night-800 komc:hover:text-white`,`komc:active:bg-night-800 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`black`,className:t.n(`komc:bg-[rgb(95,95,96)] komc:text-white`,`komc:hover:bg-[rgb(76,76,77)] komc:hover:text-white`,`komc:active:bg-[rgb(76,76,77)] komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`sky`,className:t.n(`komc:bg-sky-750 komc:text-white`,`komc:hover:bg-sky-950 komc:hover:text-white`,`komc:active:bg-sky-950 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`solid`,variant:`sky-blue`,className:t.n(`komc:bg-sky-450 komc:text-white`,`komc:hover:bg-sky-650 komc:hover:text-white`,`komc:active:bg-sky-650 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`solid`,variant:`indigo`,className:t.n(`komc:bg-indigo-600 komc:text-white`,`komc:hover:bg-indigo-700 komc:hover:text-white`,`komc:active:bg-indigo-700 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`clear`,variant:`sky`,className:t.n(`komc:bg-transparent komc:text-[#1890FF]`,`komc:hover:bg-transparent komc:hover:text-[#1890FF] komc:hover:underline`,`komc:active:bg-transparent komc:active:text-[#1890FF] komc:active:underline`,`komc:disabled:border-transparent komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`clear`,variant:`gray`,className:t.n(`komc:bg-transparent komc:text-gray-800`,`komc:hover:bg-transparent komc:hover:text-gray-800 komc:hover:underline`,`komc:active:bg-transparent komc:active:text-gray-800 komc:active:underline`,`komc:disabled:border-transparent komc:disabled:bg-transparent komc:disabled:text-gray-500`)}],defaultVariants:{size:`md`,shadow:`none`,outline:`line`,variant:`blue`,px:`2xl`,rounded:`sm`}}),u=(0,i.forwardRef)(({type:e=`button`,className:t,id:n,size:r,shadow:i,outline:o,variant:c,px:u,rounded:d,asChild:f,...p},m)=>(0,a.jsx)(f?s.Slot:`button`,{ref:m,...p,type:e,id:n,className:l({size:r,shadow:i,outline:o,variant:c,px:u,rounded:d,className:t})}));var d=u;function f({condition:e,wrapper:t,children:n}){return e?t(n):n}function p({condition:e,trueWrapper:t,falseWrapper:n,children:r}){return e?t(r):n(r)}const m=(0,o.cva)(t.n(`komc:flex komc:items-center komc:w-full komc:px-2`,`komc:[&>input]:outline-none komc:[&>input]:w-full`,`komc:[&>input]:focus:ring-0 komc:[&>input]:focus:ring-offset-0`,`komc:[&>input]:h-full`),{variants:{size:{xs:`komc:h-7.5`,sm:`komc:h-8`,base:`komc:h-9`,md:`komc:h-10`,lg:`komc:h-11`,xl:`komc:h-12`,"2xl":`komc:h-13`,"3xl":`komc:h-14`},gap:{none:`komc:gap-0`,xs:`komc:gap-1`,sm:`komc:gap-2`,md:`komc:gap-3`,lg:`komc:gap-4`,xl:`komc:gap-5`},outline:{line:`komc:border`,solid:`komc:border-transparent`,clear:`komc:border-none`,dashed:`komc:border-dashed`,dotted:`komc:border-dotted`},rounded:{none:`komc:rounded-none`,sm:`komc:rounded-sm`,md:`komc:rounded-md`,lg:`komc:rounded-lg`,xl:`komc:rounded-xl`,"2xl":`komc:rounded-2xl`}}}),h=(0,i.forwardRef)(({prefix:e=null,surffix:t=null,size:n=`lg`,gap:r=`xl`,outline:i=`line`,rounded:o=`lg`,className:s,...c},l)=>(0,a.jsxs)(`div`,{"data-komc":!0,className:m({size:n,gap:r,outline:i,rounded:o,className:s}),children:[e,(0,a.jsx)(`input`,{ref:l,type:`text`,...c}),t]}));var g=h;function _({children:e,className:t,...n}){return(0,a.jsx)(`span`,{...n,"data-komc":!0,"data-text":`${e}`,className:(0,r.default)(`komc:inline-flex komc:flex-col komc:justify-center komc:items-center`,`komc:after:content-[attr(data-text)] komc:after:font-bold`,`komc:after:h-0 komc:after:invisible komc:after:overflow-hidden`,`komc:after:select-none komc:after:pointer-events-none`,t),children:e})}exports.BottomAppBar=c,exports.Button=d,exports.ConditionalEitherWrapper=p,exports.ConditionalWrapper=f,exports.Input=g,exports.Skeleton=n.t,exports.StableText=_;
@@ -1,6 +1,6 @@
1
- import * as react11 from "react";
1
+ import * as react9 from "react";
2
2
  import React$1, { ComponentProps, HTMLAttributes } from "react";
3
- import * as react_jsx_runtime11 from "react/jsx-runtime";
3
+ import * as react_jsx_runtime12 from "react/jsx-runtime";
4
4
  import * as class_variance_authority_types1 from "class-variance-authority/types";
5
5
  import { VariantProps } from "class-variance-authority";
6
6
 
@@ -19,11 +19,11 @@ declare function BottomAppBar<T>({
19
19
  //#region src/ui/button/button.d.ts
20
20
  declare const classes$2: (props?: ({
21
21
  size?: "sm" | "md" | "lg" | "xl" | "2xl" | "xxs" | "xs" | "3xl" | "4xl" | null | undefined;
22
- shadow?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | null | undefined;
22
+ shadow?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | "3xl" | null | undefined;
23
23
  outline?: "line" | "solid" | "clear" | null | undefined;
24
24
  variant?: "blue" | "duo" | "white" | "gray" | "neutral" | "night" | "black" | "sky" | "sky-blue" | "indigo" | null | undefined;
25
- px?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | "xs" | "3xl" | "4xl" | null | undefined;
26
- rounded?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | "full" | "3xl" | null | undefined;
25
+ px?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | "xs" | "3xl" | "4xl" | null | undefined;
26
+ rounded?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | "full" | "3xl" | null | undefined;
27
27
  } & class_variance_authority_types1.ClassProp) | undefined) => string;
28
28
  interface VariantMap {
29
29
  line: 'blue' | 'duo' | 'white' | 'gray' | 'neutral' | 'sky' | 'sky-blue';
@@ -43,22 +43,22 @@ type ButtonProps = ComponentProps<'button'> & BaseProps & ({
43
43
  }) & {
44
44
  asChild?: boolean;
45
45
  };
46
- declare const Button: react11.ForwardRefExoticComponent<(Omit<react11.ClassAttributes<HTMLButtonElement> & react11.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
46
+ declare const Button: react9.ForwardRefExoticComponent<(Omit<react9.ClassAttributes<HTMLButtonElement> & react9.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
47
47
  outline?: "line";
48
48
  variant?: VariantMap["line"];
49
49
  } & {
50
50
  asChild?: boolean;
51
- }, "ref"> | Omit<react11.ClassAttributes<HTMLButtonElement> & react11.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
51
+ }, "ref"> | Omit<react9.ClassAttributes<HTMLButtonElement> & react9.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
52
52
  outline: "solid";
53
53
  variant?: VariantMap["solid"];
54
54
  } & {
55
55
  asChild?: boolean;
56
- }, "ref"> | Omit<react11.ClassAttributes<HTMLButtonElement> & react11.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
56
+ }, "ref"> | Omit<react9.ClassAttributes<HTMLButtonElement> & react9.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
57
57
  outline: "clear";
58
58
  variant?: VariantMap["clear"];
59
59
  } & {
60
60
  asChild?: boolean;
61
- }, "ref">) & react11.RefAttributes<HTMLButtonElement>>;
61
+ }, "ref">) & react9.RefAttributes<HTMLButtonElement>>;
62
62
  //#endregion
63
63
  //#region src/ui/conditional-wrapper/conditional-wrapper.d.ts
64
64
  interface ConditionalWrapperProps {
@@ -70,7 +70,7 @@ declare function ConditionalWrapper({
70
70
  condition,
71
71
  wrapper,
72
72
  children
73
- }: ConditionalWrapperProps): react11.ReactNode;
73
+ }: ConditionalWrapperProps): react9.ReactNode;
74
74
  //#endregion
75
75
  //#region src/ui/conditional-wrapper/conditional-either-wrapper.d.ts
76
76
  interface ConditionalEitherWrapperProps {
@@ -84,14 +84,14 @@ declare function ConditionalEitherWrapper({
84
84
  trueWrapper,
85
85
  falseWrapper,
86
86
  children
87
- }: ConditionalEitherWrapperProps): react11.ReactNode;
87
+ }: ConditionalEitherWrapperProps): react9.ReactNode;
88
88
  //#endregion
89
89
  //#region src/ui/input/input.d.ts
90
90
  declare const classes$1: (props?: ({
91
91
  size?: "sm" | "md" | "lg" | "xl" | "2xl" | "base" | "xs" | "3xl" | null | undefined;
92
- gap?: "none" | "sm" | "md" | "lg" | "xl" | "xs" | null | undefined;
92
+ gap?: "sm" | "md" | "lg" | "none" | "xl" | "xs" | null | undefined;
93
93
  outline?: "line" | "solid" | "clear" | "dashed" | "dotted" | null | undefined;
94
- rounded?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | null | undefined;
94
+ rounded?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | null | undefined;
95
95
  } & class_variance_authority_types1.ClassProp) | undefined) => string;
96
96
  interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'prefix' | 'surffix' | 'size'>, VariantProps<typeof classes$1> {
97
97
  size?: VariantProps<typeof classes$1>['size'];
@@ -101,12 +101,12 @@ interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, '
101
101
  prefix?: React.ReactNode;
102
102
  surffix?: React.ReactNode;
103
103
  }
104
- declare const Input: react11.ForwardRefExoticComponent<InputProps & react11.RefAttributes<HTMLInputElement>>;
104
+ declare const Input: react9.ForwardRefExoticComponent<InputProps & react9.RefAttributes<HTMLInputElement>>;
105
105
  //#endregion
106
106
  //#region src/ui/skeleton/skeleton.d.ts
107
107
  declare const classes: (props?: ({
108
108
  size?: "sm" | "md" | "lg" | "xl" | "2xl" | "full" | "xs" | "3xl" | "square" | null | undefined;
109
- rounded?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | "full" | "3xl" | null | undefined;
109
+ rounded?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | "full" | "3xl" | null | undefined;
110
110
  } & class_variance_authority_types1.ClassProp) | undefined) => string;
111
111
  interface SkeletonProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof classes> {
112
112
  width?: string | number;
@@ -121,7 +121,7 @@ declare function Skeleton({
121
121
  height,
122
122
  className,
123
123
  ...props
124
- }: SkeletonProps): react_jsx_runtime11.JSX.Element;
124
+ }: SkeletonProps): react_jsx_runtime12.JSX.Element;
125
125
  //#endregion
126
126
  //#region src/ui/stable-text/stable-text.d.ts
127
127
  declare function StableText({
@@ -130,6 +130,6 @@ declare function StableText({
130
130
  ...props
131
131
  }: Omit<HTMLAttributes<HTMLSpanElement>, 'children'> & {
132
132
  children: string | number;
133
- }): react_jsx_runtime11.JSX.Element;
133
+ }): react_jsx_runtime12.JSX.Element;
134
134
  //#endregion
135
135
  export { BottomAppBar, type BottomAppBarProps, Button, type ButtonProps, ConditionalEitherWrapper, type ConditionalEitherWrapperProps, ConditionalWrapper, type ConditionalWrapperProps, Input, type InputProps, Skeleton, type SkeletonProps, StableText };
@@ -1,6 +1,6 @@
1
- import * as react7 from "react";
1
+ import * as react9 from "react";
2
2
  import React$1, { ComponentProps, HTMLAttributes } from "react";
3
- import * as react_jsx_runtime12 from "react/jsx-runtime";
3
+ import * as react_jsx_runtime11 from "react/jsx-runtime";
4
4
  import { VariantProps } from "class-variance-authority";
5
5
  import * as class_variance_authority_types0 from "class-variance-authority/types";
6
6
 
@@ -19,11 +19,11 @@ declare function BottomAppBar<T>({
19
19
  //#region src/ui/button/button.d.ts
20
20
  declare const classes$2: (props?: ({
21
21
  size?: "sm" | "md" | "lg" | "xl" | "2xl" | "xxs" | "xs" | "3xl" | "4xl" | null | undefined;
22
- shadow?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | null | undefined;
22
+ shadow?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | "3xl" | null | undefined;
23
23
  outline?: "line" | "solid" | "clear" | null | undefined;
24
24
  variant?: "blue" | "duo" | "white" | "gray" | "neutral" | "night" | "black" | "sky" | "sky-blue" | "indigo" | null | undefined;
25
- px?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | "xs" | "3xl" | "4xl" | null | undefined;
26
- rounded?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | "full" | "3xl" | null | undefined;
25
+ px?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | "xs" | "3xl" | "4xl" | null | undefined;
26
+ rounded?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | "full" | "3xl" | null | undefined;
27
27
  } & class_variance_authority_types0.ClassProp) | undefined) => string;
28
28
  interface VariantMap {
29
29
  line: 'blue' | 'duo' | 'white' | 'gray' | 'neutral' | 'sky' | 'sky-blue';
@@ -43,22 +43,22 @@ type ButtonProps = ComponentProps<'button'> & BaseProps & ({
43
43
  }) & {
44
44
  asChild?: boolean;
45
45
  };
46
- declare const Button: react7.ForwardRefExoticComponent<(Omit<react7.ClassAttributes<HTMLButtonElement> & react7.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
46
+ declare const Button: react9.ForwardRefExoticComponent<(Omit<react9.ClassAttributes<HTMLButtonElement> & react9.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
47
47
  outline?: "line";
48
48
  variant?: VariantMap["line"];
49
49
  } & {
50
50
  asChild?: boolean;
51
- }, "ref"> | Omit<react7.ClassAttributes<HTMLButtonElement> & react7.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
51
+ }, "ref"> | Omit<react9.ClassAttributes<HTMLButtonElement> & react9.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
52
52
  outline: "solid";
53
53
  variant?: VariantMap["solid"];
54
54
  } & {
55
55
  asChild?: boolean;
56
- }, "ref"> | Omit<react7.ClassAttributes<HTMLButtonElement> & react7.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
56
+ }, "ref"> | Omit<react9.ClassAttributes<HTMLButtonElement> & react9.ButtonHTMLAttributes<HTMLButtonElement> & BaseProps & {
57
57
  outline: "clear";
58
58
  variant?: VariantMap["clear"];
59
59
  } & {
60
60
  asChild?: boolean;
61
- }, "ref">) & react7.RefAttributes<HTMLButtonElement>>;
61
+ }, "ref">) & react9.RefAttributes<HTMLButtonElement>>;
62
62
  //#endregion
63
63
  //#region src/ui/conditional-wrapper/conditional-wrapper.d.ts
64
64
  interface ConditionalWrapperProps {
@@ -70,7 +70,7 @@ declare function ConditionalWrapper({
70
70
  condition,
71
71
  wrapper,
72
72
  children
73
- }: ConditionalWrapperProps): react7.ReactNode;
73
+ }: ConditionalWrapperProps): react9.ReactNode;
74
74
  //#endregion
75
75
  //#region src/ui/conditional-wrapper/conditional-either-wrapper.d.ts
76
76
  interface ConditionalEitherWrapperProps {
@@ -84,14 +84,14 @@ declare function ConditionalEitherWrapper({
84
84
  trueWrapper,
85
85
  falseWrapper,
86
86
  children
87
- }: ConditionalEitherWrapperProps): react7.ReactNode;
87
+ }: ConditionalEitherWrapperProps): react9.ReactNode;
88
88
  //#endregion
89
89
  //#region src/ui/input/input.d.ts
90
90
  declare const classes$1: (props?: ({
91
91
  size?: "sm" | "md" | "lg" | "xl" | "2xl" | "base" | "xs" | "3xl" | null | undefined;
92
- gap?: "none" | "sm" | "md" | "lg" | "xl" | "xs" | null | undefined;
92
+ gap?: "sm" | "md" | "lg" | "none" | "xl" | "xs" | null | undefined;
93
93
  outline?: "line" | "solid" | "clear" | "dashed" | "dotted" | null | undefined;
94
- rounded?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | null | undefined;
94
+ rounded?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | null | undefined;
95
95
  } & class_variance_authority_types0.ClassProp) | undefined) => string;
96
96
  interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'prefix' | 'surffix' | 'size'>, VariantProps<typeof classes$1> {
97
97
  size?: VariantProps<typeof classes$1>['size'];
@@ -101,12 +101,12 @@ interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, '
101
101
  prefix?: React.ReactNode;
102
102
  surffix?: React.ReactNode;
103
103
  }
104
- declare const Input: react7.ForwardRefExoticComponent<InputProps & react7.RefAttributes<HTMLInputElement>>;
104
+ declare const Input: react9.ForwardRefExoticComponent<InputProps & react9.RefAttributes<HTMLInputElement>>;
105
105
  //#endregion
106
106
  //#region src/ui/skeleton/skeleton.d.ts
107
107
  declare const classes: (props?: ({
108
108
  size?: "sm" | "md" | "lg" | "xl" | "2xl" | "full" | "xs" | "3xl" | "square" | null | undefined;
109
- rounded?: "none" | "sm" | "md" | "lg" | "xl" | "2xl" | "full" | "3xl" | null | undefined;
109
+ rounded?: "sm" | "md" | "lg" | "none" | "xl" | "2xl" | "full" | "3xl" | null | undefined;
110
110
  } & class_variance_authority_types0.ClassProp) | undefined) => string;
111
111
  interface SkeletonProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof classes> {
112
112
  width?: string | number;
@@ -121,7 +121,7 @@ declare function Skeleton({
121
121
  height,
122
122
  className,
123
123
  ...props
124
- }: SkeletonProps): react_jsx_runtime12.JSX.Element;
124
+ }: SkeletonProps): react_jsx_runtime11.JSX.Element;
125
125
  //#endregion
126
126
  //#region src/ui/stable-text/stable-text.d.ts
127
127
  declare function StableText({
@@ -130,6 +130,6 @@ declare function StableText({
130
130
  ...props
131
131
  }: Omit<HTMLAttributes<HTMLSpanElement>, 'children'> & {
132
132
  children: string | number;
133
- }): react_jsx_runtime12.JSX.Element;
133
+ }): react_jsx_runtime11.JSX.Element;
134
134
  //#endregion
135
135
  export { BottomAppBar, type BottomAppBarProps, Button, type ButtonProps, ConditionalEitherWrapper, type ConditionalEitherWrapperProps, ConditionalWrapper, type ConditionalWrapperProps, Input, type InputProps, Skeleton, type SkeletonProps, StableText };
package/dist/ui/index.mjs CHANGED
@@ -1 +1 @@
1
- import{n as e}from"../common-DbEp6YNc.mjs";import{t}from"../skeleton-6QtpIO7l.mjs";import n from"clsx";import r,{forwardRef as i}from"react";import{jsx as a,jsxs as o}from"react/jsx-runtime";import{cva as s}from"class-variance-authority";import{Slot as c}from"@radix-ui/react-slot";function l({className:e,items:t,render:i,...o}){return a(`nav`,{"data-komc":!0,"aria-label":`bottom app bar`,className:n(`komc:fixed komc:bottom-0 komc:left-0 komc:right-0`,`komc:border-t komc:border-neutral-200 komc:bg-white komc:z-10`,e),...o,children:a(`div`,{className:`komc:grid komc:min-h-15`,style:{gridTemplateColumns:`repeat(${t.length}, 1fr)`},children:t.map((e,t)=>a(r.Fragment,{children:i(e)},t))})})}const u=s(e(`komc:flex komc:justify-center komc:items-center komc:gap-x-2 komc:w-full`,`komc:transition-colors komc:duration-200 komc:relative`,`komc:[&_svg]:transition-colors komc:[&_svg]:duration-200`,`komc:cursor-pointer komc:disabled:cursor-default`),{variants:{size:{xxs:`komc:h-7.5`,xs:`komc:h-8`,sm:`komc:h-9`,md:`komc:h-10`,lg:`komc:h-11`,xl:`komc:h-12`,"2xl":`komc:h-13`,"3xl":`komc:h-14`,"4xl":`komc:h-15`},shadow:{none:``,sm:`komc:drop-shadow-sm`,md:`komc:drop-shadow-md`,lg:`komc:drop-shadow-lg`,xl:`komc:drop-shadow-xl`,"2xl":`komc:drop-shadow-2xl`,"3xl":`komc:drop-shadow-3xl`},outline:{line:`komc:border`,solid:`komc:border komc:border-transparent`,clear:`komc:border-none`},variant:{blue:``,duo:``,white:``,gray:``,neutral:``,night:``,black:``,sky:``,"sky-blue":``,indigo:``},px:{none:`komc:px-0`,xs:`komc:px-0.5`,sm:`komc:px-1`,md:`komc:px-1.5`,lg:`komc:px-2`,xl:`komc:px-3`,"2xl":`komc:px-4`,"3xl":`komc:px-5`,"4xl":`komc:px-6`},rounded:{none:`komc:rounded-none`,sm:`komc:rounded-sm`,md:`komc:rounded-md`,lg:`komc:rounded-lg`,xl:`komc:rounded-xl`,"2xl":`komc:rounded-2xl`,"3xl":`komc:rounded-3xl`,full:`komc:rounded-full`}},compoundVariants:[{outline:`line`,variant:`blue`,className:e(`komc:border-blue-500 komc:bg-white komc:text-blue-500`,`komc:hover:border-transparent komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:border-transparent komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`duo`,className:e(`komc:border-blue-500 komc:bg-white komc:text-brand-blck`,`komc:hover:border-transparent komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:border-transparent komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`white`,className:e(`komc:border-gray-600 komc:bg-white komc:text-brand-blck`,`komc:hover:bg-gray-200 komc:hover:text-brand-blck`,`komc:active:bg-gray-200 komc:active:text-brand-blck`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`gray`,className:e(`komc:border-white komc:bg-transparent komc:text-white`,`komc:hover:bg-[rgb(199,199,199)] komc:hover:text-white`,`komc:active:bg-[rgb(199,199,199)] komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`neutral`,className:e(`komc:border-gray-800 komc:bg-transparent komc:text-black`,`komc:hover:bg-gray-200 komc:hover:text-black`,`komc:active:bg-gray-200 komc:active:text-black`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`line`,variant:`sky`,className:e(`komc:border-sky-750 komc:bg-transparent komc:text-black`,`komc:hover:bg-sky-750 komc:hover:text-white`,`komc:active:bg-sky-750 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`line`,variant:`sky-blue`,className:e(`komc:border-sky-450 komc:bg-transparent komc:text-black`,`komc:hover:bg-sky-450 komc:hover:text-white`,`komc:active:bg-sky-450 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`solid`,variant:`white`,className:e(`komc:bg-white komc:text-brand-blck`,`komc:hover:bg-gray-200`,`komc:active:bg-gray-200`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`gray`,className:e(`komc:bg-gray-100 komc:text-blue-500`,`komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`blue`,className:e(`komc:bg-blue-500 komc:text-white`,`komc:hover:bg-night-700 komc:hover:text-white`,`komc:active:bg-night-700 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`night`,className:e(`komc:bg-night-700 komc:text-white`,`komc:hover:bg-night-800 komc:hover:text-white`,`komc:active:bg-night-800 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`black`,className:e(`komc:bg-[rgb(95,95,96)] komc:text-white`,`komc:hover:bg-[rgb(76,76,77)] komc:hover:text-white`,`komc:active:bg-[rgb(76,76,77)] komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`sky`,className:e(`komc:bg-sky-750 komc:text-white`,`komc:hover:bg-sky-950 komc:hover:text-white`,`komc:active:bg-sky-950 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`solid`,variant:`sky-blue`,className:e(`komc:bg-sky-450 komc:text-white`,`komc:hover:bg-sky-650 komc:hover:text-white`,`komc:active:bg-sky-650 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`solid`,variant:`indigo`,className:e(`komc:bg-indigo-600 komc:text-white`,`komc:hover:bg-indigo-700 komc:hover:text-white`,`komc:active:bg-indigo-700 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`clear`,variant:`sky`,className:e(`komc:bg-transparent komc:text-[#1890FF]`,`komc:hover:bg-transparent komc:hover:text-[#1890FF] komc:hover:underline`,`komc:active:bg-transparent komc:active:text-[#1890FF] komc:active:underline`,`komc:disabled:border-transparent komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`clear`,variant:`gray`,className:e(`komc:bg-transparent komc:text-gray-800`,`komc:hover:bg-transparent komc:hover:text-gray-800 komc:hover:underline`,`komc:active:bg-transparent komc:active:text-gray-800 komc:active:underline`,`komc:disabled:border-transparent komc:disabled:bg-transparent komc:disabled:text-gray-500`)}],defaultVariants:{size:`md`,shadow:`none`,outline:`line`,variant:`blue`,px:`2xl`,rounded:`sm`}});var d=i(({type:e=`button`,className:t,id:n,size:r,shadow:i,outline:o,variant:s,px:l,rounded:d,asChild:f,...p},m)=>a(f?c:`button`,{ref:m,...p,type:e,id:n,className:u({size:r,shadow:i,outline:o,variant:s,px:l,rounded:d,className:t})}));function f({condition:e,wrapper:t,children:n}){return e?t(n):n}function p({condition:e,trueWrapper:t,falseWrapper:n,children:r}){return e?t(r):n(r)}const m=s(e(`komc:flex komc:items-center komc:w-full komc:px-2`,`komc:[&>input]:outline-none komc:[&>input]:w-full`,`komc:[&>input]:focus:ring-0 komc:[&>input]:focus:ring-offset-0`,`komc:[&>input]:h-full`),{variants:{size:{xs:`komc:h-7.5`,sm:`komc:h-8`,base:`komc:h-9`,md:`komc:h-10`,lg:`komc:h-11`,xl:`komc:h-12`,"2xl":`komc:h-13`,"3xl":`komc:h-14`},gap:{none:`komc:gap-0`,xs:`komc:gap-1`,sm:`komc:gap-2`,md:`komc:gap-3`,lg:`komc:gap-4`,xl:`komc:gap-5`},outline:{line:`komc:border`,solid:`komc:border-transparent`,clear:`komc:border-none`,dashed:`komc:border-dashed`,dotted:`komc:border-dotted`},rounded:{none:`komc:rounded-none`,sm:`komc:rounded-sm`,md:`komc:rounded-md`,lg:`komc:rounded-lg`,xl:`komc:rounded-xl`,"2xl":`komc:rounded-2xl`}}});var h=i(({prefix:e=null,surffix:t=null,size:n=`lg`,gap:r=`xl`,outline:i=`line`,rounded:s=`lg`,className:c,...l},u)=>o(`div`,{"data-komc":!0,className:m({size:n,gap:r,outline:i,rounded:s,className:c}),children:[e,a(`input`,{ref:u,type:`text`,...l}),t]}));function g({children:e,className:t,...r}){return a(`span`,{...r,"data-komc":!0,"data-text":`${e}`,className:n(`komc:inline-flex komc:flex-col komc:justify-center komc:items-center`,`komc:after:content-[attr(data-text)] komc:after:font-bold`,`komc:after:h-0 komc:after:invisible komc:after:overflow-hidden`,`komc:after:select-none komc:after:pointer-events-none`,t),children:e})}export{l as BottomAppBar,d as Button,p as ConditionalEitherWrapper,f as ConditionalWrapper,h as Input,t as Skeleton,g as StableText};
1
+ import{n as e}from"../common-Df03Ovdm.mjs";import{t}from"../skeleton-B6_oBhkl.mjs";import n from"clsx";import r,{forwardRef as i}from"react";import{jsx as a,jsxs as o}from"react/jsx-runtime";import{cva as s}from"class-variance-authority";import{Slot as c}from"@radix-ui/react-slot";function l({className:e,items:t,render:i,...o}){return a(`nav`,{"data-komc":!0,"aria-label":`bottom app bar`,className:n(`komc:fixed komc:bottom-0 komc:left-0 komc:right-0`,`komc:border-t komc:border-neutral-200 komc:bg-white komc:z-10`,e),...o,children:a(`div`,{className:`komc:grid komc:min-h-15`,style:{gridTemplateColumns:`repeat(${t.length}, 1fr)`},children:t.map((e,t)=>a(r.Fragment,{children:i(e)},t))})})}const u=s(e(`komc:flex komc:justify-center komc:items-center komc:gap-x-2 komc:w-full`,`komc:transition-colors komc:duration-200 komc:relative`,`komc:[&_svg]:transition-colors komc:[&_svg]:duration-200`,`komc:cursor-pointer komc:disabled:cursor-default`),{variants:{size:{xxs:`komc:h-7.5`,xs:`komc:h-8`,sm:`komc:h-9`,md:`komc:h-10`,lg:`komc:h-11`,xl:`komc:h-12`,"2xl":`komc:h-13`,"3xl":`komc:h-14`,"4xl":`komc:h-15`},shadow:{none:``,sm:`komc:drop-shadow-sm`,md:`komc:drop-shadow-md`,lg:`komc:drop-shadow-lg`,xl:`komc:drop-shadow-xl`,"2xl":`komc:drop-shadow-2xl`,"3xl":`komc:drop-shadow-3xl`},outline:{line:`komc:border`,solid:`komc:border komc:border-transparent`,clear:`komc:border-none`},variant:{blue:``,duo:``,white:``,gray:``,neutral:``,night:``,black:``,sky:``,"sky-blue":``,indigo:``},px:{none:`komc:px-0`,xs:`komc:px-0.5`,sm:`komc:px-1`,md:`komc:px-1.5`,lg:`komc:px-2`,xl:`komc:px-3`,"2xl":`komc:px-4`,"3xl":`komc:px-5`,"4xl":`komc:px-6`},rounded:{none:`komc:rounded-none`,sm:`komc:rounded-sm`,md:`komc:rounded-md`,lg:`komc:rounded-lg`,xl:`komc:rounded-xl`,"2xl":`komc:rounded-2xl`,"3xl":`komc:rounded-3xl`,full:`komc:rounded-full`}},compoundVariants:[{outline:`line`,variant:`blue`,className:e(`komc:border-blue-500 komc:bg-white komc:text-blue-500`,`komc:hover:border-transparent komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:border-transparent komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`duo`,className:e(`komc:border-blue-500 komc:bg-white komc:text-brand-blck`,`komc:hover:border-transparent komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:border-transparent komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`white`,className:e(`komc:border-gray-600 komc:bg-white komc:text-brand-blck`,`komc:hover:bg-gray-200 komc:hover:text-brand-blck`,`komc:active:bg-gray-200 komc:active:text-brand-blck`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`gray`,className:e(`komc:border-white komc:bg-transparent komc:text-white`,`komc:hover:bg-[rgb(199,199,199)] komc:hover:text-white`,`komc:active:bg-[rgb(199,199,199)] komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-white komc:disabled:text-gray-500`)},{outline:`line`,variant:`neutral`,className:e(`komc:border-gray-800 komc:bg-transparent komc:text-black`,`komc:hover:bg-gray-200 komc:hover:text-black`,`komc:active:bg-gray-200 komc:active:text-black`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`line`,variant:`sky`,className:e(`komc:border-sky-750 komc:bg-transparent komc:text-black`,`komc:hover:bg-sky-750 komc:hover:text-white`,`komc:active:bg-sky-750 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`line`,variant:`sky-blue`,className:e(`komc:border-sky-450 komc:bg-transparent komc:text-black`,`komc:hover:bg-sky-450 komc:hover:text-white`,`komc:active:bg-sky-450 komc:active:text-white`,`komc:disabled:border-gray-500 komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`solid`,variant:`white`,className:e(`komc:bg-white komc:text-brand-blck`,`komc:hover:bg-gray-200`,`komc:active:bg-gray-200`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`gray`,className:e(`komc:bg-gray-100 komc:text-blue-500`,`komc:hover:bg-blue-500 komc:hover:text-white`,`komc:active:bg-blue-500 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`blue`,className:e(`komc:bg-blue-500 komc:text-white`,`komc:hover:bg-night-700 komc:hover:text-white`,`komc:active:bg-night-700 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`night`,className:e(`komc:bg-night-700 komc:text-white`,`komc:hover:bg-night-800 komc:hover:text-white`,`komc:active:bg-night-800 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`black`,className:e(`komc:bg-[rgb(95,95,96)] komc:text-white`,`komc:hover:bg-[rgb(76,76,77)] komc:hover:text-white`,`komc:active:bg-[rgb(76,76,77)] komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-50 komc:disabled:text-gray-800`)},{outline:`solid`,variant:`sky`,className:e(`komc:bg-sky-750 komc:text-white`,`komc:hover:bg-sky-950 komc:hover:text-white`,`komc:active:bg-sky-950 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`solid`,variant:`sky-blue`,className:e(`komc:bg-sky-450 komc:text-white`,`komc:hover:bg-sky-650 komc:hover:text-white`,`komc:active:bg-sky-650 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`solid`,variant:`indigo`,className:e(`komc:bg-indigo-600 komc:text-white`,`komc:hover:bg-indigo-700 komc:hover:text-white`,`komc:active:bg-indigo-700 komc:active:text-white`,`komc:disabled:border-white komc:disabled:bg-gray-700`)},{outline:`clear`,variant:`sky`,className:e(`komc:bg-transparent komc:text-[#1890FF]`,`komc:hover:bg-transparent komc:hover:text-[#1890FF] komc:hover:underline`,`komc:active:bg-transparent komc:active:text-[#1890FF] komc:active:underline`,`komc:disabled:border-transparent komc:disabled:bg-transparent komc:disabled:text-gray-500`)},{outline:`clear`,variant:`gray`,className:e(`komc:bg-transparent komc:text-gray-800`,`komc:hover:bg-transparent komc:hover:text-gray-800 komc:hover:underline`,`komc:active:bg-transparent komc:active:text-gray-800 komc:active:underline`,`komc:disabled:border-transparent komc:disabled:bg-transparent komc:disabled:text-gray-500`)}],defaultVariants:{size:`md`,shadow:`none`,outline:`line`,variant:`blue`,px:`2xl`,rounded:`sm`}});var d=i(({type:e=`button`,className:t,id:n,size:r,shadow:i,outline:o,variant:s,px:l,rounded:d,asChild:f,...p},m)=>a(f?c:`button`,{ref:m,...p,type:e,id:n,className:u({size:r,shadow:i,outline:o,variant:s,px:l,rounded:d,className:t})}));function f({condition:e,wrapper:t,children:n}){return e?t(n):n}function p({condition:e,trueWrapper:t,falseWrapper:n,children:r}){return e?t(r):n(r)}const m=s(e(`komc:flex komc:items-center komc:w-full komc:px-2`,`komc:[&>input]:outline-none komc:[&>input]:w-full`,`komc:[&>input]:focus:ring-0 komc:[&>input]:focus:ring-offset-0`,`komc:[&>input]:h-full`),{variants:{size:{xs:`komc:h-7.5`,sm:`komc:h-8`,base:`komc:h-9`,md:`komc:h-10`,lg:`komc:h-11`,xl:`komc:h-12`,"2xl":`komc:h-13`,"3xl":`komc:h-14`},gap:{none:`komc:gap-0`,xs:`komc:gap-1`,sm:`komc:gap-2`,md:`komc:gap-3`,lg:`komc:gap-4`,xl:`komc:gap-5`},outline:{line:`komc:border`,solid:`komc:border-transparent`,clear:`komc:border-none`,dashed:`komc:border-dashed`,dotted:`komc:border-dotted`},rounded:{none:`komc:rounded-none`,sm:`komc:rounded-sm`,md:`komc:rounded-md`,lg:`komc:rounded-lg`,xl:`komc:rounded-xl`,"2xl":`komc:rounded-2xl`}}});var h=i(({prefix:e=null,surffix:t=null,size:n=`lg`,gap:r=`xl`,outline:i=`line`,rounded:s=`lg`,className:c,...l},u)=>o(`div`,{"data-komc":!0,className:m({size:n,gap:r,outline:i,rounded:s,className:c}),children:[e,a(`input`,{ref:u,type:`text`,...l}),t]}));function g({children:e,className:t,...r}){return a(`span`,{...r,"data-komc":!0,"data-text":`${e}`,className:n(`komc:inline-flex komc:flex-col komc:justify-center komc:items-center`,`komc:after:content-[attr(data-text)] komc:after:font-bold`,`komc:after:h-0 komc:after:invisible komc:after:overflow-hidden`,`komc:after:select-none komc:after:pointer-events-none`,t),children:e})}export{l as BottomAppBar,d as Button,p as ConditionalEitherWrapper,f as ConditionalWrapper,h as Input,t as Skeleton,g as StableText};
@@ -1 +1 @@
1
- "use client";const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../src-CjpmdVyv.cjs`),require(`../../file-5mweNdAM.cjs`);const t=require(`../../hooks--O5RcEJq.cjs`);require(`../../providers-CkXkdYcB.cjs`),require(`../../use-subset-image-DhX5WmYG.cjs`);let n=require(`clsx`);n=e.t(n);let r=require(`react`);r=e.t(r);let i=require(`react/jsx-runtime`),a=require(`class-variance-authority`);const o=(0,a.cva)((0,n.default)(`komc:absolute komc:bg-white komc:flex komc:flex-col komc:shadow-2xl`,`komc:transition-transform komc:duration-300 komc:ease-in-out`),{variants:{direction:{top:`komc:top-0 komc:left-0 komc:right-0 komc:-translate-y-full komc:data-[state=open]:translate-y-0`,bottom:`komc:bottom-0 komc:left-0 komc:right-0 komc:translate-y-full komc:data-[state=open]:translate-y-0`,left:`komc:top-0 komc:bottom-0 komc:left-0 komc:-translate-x-full komc:data-[state=open]:translate-x-0`,right:`komc:top-0 komc:bottom-0 komc:right-0 komc:translate-x-full komc:data-[state=open]:translate-x-0`}}}),s=(0,a.cva)(``,{variants:{size:{full:``,half:``,auto:``},direction:{top:``,bottom:``,left:``,right:``}},compoundVariants:[{size:`full`,direction:`top`,className:`komc:h-full`},{size:`full`,direction:`bottom`,className:`komc:h-full`},{size:`full`,direction:`left`,className:`komc:w-full`},{size:`full`,direction:`right`,className:`komc:w-full`},{size:`half`,direction:`top`,className:`komc:h-[50dvh]`},{size:`half`,direction:`bottom`,className:`komc:h-[50dvh]`},{size:`half`,direction:`left`,className:`komc:w-[50dvw]`},{size:`half`,direction:`right`,className:`komc:w-[50dvw]`},{size:`auto`,direction:`top`,className:`komc:h-auto komc:max-h-[90dvh]`},{size:`auto`,direction:`bottom`,className:`komc:h-auto komc:max-h-[90dvh]`},{size:`auto`,direction:`left`,className:`komc:w-auto komc:max-w-[90dvw]`},{size:`auto`,direction:`right`,className:`komc:w-auto komc:max-w-[90dvw]`}]});function c({isOpen:e,onClose:a,direction:c=`bottom`,size:l=`full`,children:u,className:d,closeOnBackdropClick:f=!0,zIndex:p=1001}){let m=t.o(e,300),[h,g]=(0,r.useState)(!1);(0,r.useEffect)(()=>{if(e&&m){let e=setTimeout(()=>g(!0),10);return()=>clearTimeout(e)}else e||g(!1)},[e,m]);let _=(0,r.useCallback)(e=>{e.key===`Escape`&&a()},[a]),v=(0,r.useCallback)(()=>{f&&a()},[f,a]);return(0,r.useEffect)(()=>(e?(document.addEventListener(`keydown`,_),document.body.style.overflow=`hidden`):document.body.style.overflow=`unset`,()=>{document.removeEventListener(`keydown`,_),document.body.style.overflow=`unset`}),[e,_]),m?(0,i.jsxs)(`div`,{className:`komc:fixed komc:inset-0 komc:flex komc:justify-center komc:items-center`,style:{zIndex:p},children:[(0,i.jsx)(`button`,{type:`button`,"data-state":h?`open`:`closed`,className:(0,n.default)(`komc:absolute komc:inset-0 komc:w-full komc:h-full komc:bg-black/40 komc:cursor-default`,`komc:transition-opacity komc:duration-300 komc:ease-in-out`,`komc:opacity-0 komc:data-[state=open]:opacity-100`),onClick:v,"aria-label":`close sheet`}),(0,i.jsx)(`div`,{"data-state":h?`open`:`closed`,className:(0,n.default)(o({direction:c,className:d}),s({direction:c,size:l})),role:`dialog`,"aria-modal":`true`,children:u})]}):null}exports.Sheet=c;
1
+ "use client";const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../src-CjpmdVyv.cjs`),require(`../../file-5mweNdAM.cjs`);const t=require(`../../hooks--O5RcEJq.cjs`);require(`../../providers-CkXkdYcB.cjs`),require(`../../use-subset-image-DC86cg6O.cjs`);let n=require(`clsx`);n=e.t(n);let r=require(`react`);r=e.t(r);let i=require(`react/jsx-runtime`),a=require(`class-variance-authority`);const o=(0,a.cva)((0,n.default)(`komc:absolute komc:bg-white komc:flex komc:flex-col komc:shadow-2xl`,`komc:transition-transform komc:duration-300 komc:ease-in-out`),{variants:{direction:{top:`komc:top-0 komc:left-0 komc:right-0 komc:-translate-y-full komc:data-[state=open]:translate-y-0`,bottom:`komc:bottom-0 komc:left-0 komc:right-0 komc:translate-y-full komc:data-[state=open]:translate-y-0`,left:`komc:top-0 komc:bottom-0 komc:left-0 komc:-translate-x-full komc:data-[state=open]:translate-x-0`,right:`komc:top-0 komc:bottom-0 komc:right-0 komc:translate-x-full komc:data-[state=open]:translate-x-0`}}}),s=(0,a.cva)(``,{variants:{size:{full:``,half:``,auto:``},direction:{top:``,bottom:``,left:``,right:``}},compoundVariants:[{size:`full`,direction:`top`,className:`komc:h-full`},{size:`full`,direction:`bottom`,className:`komc:h-full`},{size:`full`,direction:`left`,className:`komc:w-full`},{size:`full`,direction:`right`,className:`komc:w-full`},{size:`half`,direction:`top`,className:`komc:h-[50dvh]`},{size:`half`,direction:`bottom`,className:`komc:h-[50dvh]`},{size:`half`,direction:`left`,className:`komc:w-[50dvw]`},{size:`half`,direction:`right`,className:`komc:w-[50dvw]`},{size:`auto`,direction:`top`,className:`komc:h-auto komc:max-h-[90dvh]`},{size:`auto`,direction:`bottom`,className:`komc:h-auto komc:max-h-[90dvh]`},{size:`auto`,direction:`left`,className:`komc:w-auto komc:max-w-[90dvw]`},{size:`auto`,direction:`right`,className:`komc:w-auto komc:max-w-[90dvw]`}]});function c({isOpen:e,onClose:a,direction:c=`bottom`,size:l=`full`,children:u,className:d,closeOnBackdropClick:f=!0,zIndex:p=1001}){let m=t.o(e,300),[h,g]=(0,r.useState)(!1);(0,r.useEffect)(()=>{if(e&&m){let e=setTimeout(()=>g(!0),10);return()=>clearTimeout(e)}else e||g(!1)},[e,m]);let _=(0,r.useCallback)(e=>{e.key===`Escape`&&a()},[a]),v=(0,r.useCallback)(()=>{f&&a()},[f,a]);return(0,r.useEffect)(()=>(e?(document.addEventListener(`keydown`,_),document.body.style.overflow=`hidden`):document.body.style.overflow=`unset`,()=>{document.removeEventListener(`keydown`,_),document.body.style.overflow=`unset`}),[e,_]),m?(0,i.jsxs)(`div`,{className:`komc:fixed komc:inset-0 komc:flex komc:justify-center komc:items-center`,style:{zIndex:p},children:[(0,i.jsx)(`button`,{type:`button`,"data-state":h?`open`:`closed`,className:(0,n.default)(`komc:absolute komc:inset-0 komc:w-full komc:h-full komc:bg-black/40 komc:cursor-default`,`komc:transition-opacity komc:duration-300 komc:ease-in-out`,`komc:opacity-0 komc:data-[state=open]:opacity-100`),onClick:v,"aria-label":`close sheet`}),(0,i.jsx)(`div`,{"data-state":h?`open`:`closed`,className:(0,n.default)(o({direction:c,className:d}),s({direction:c,size:l})),role:`dialog`,"aria-modal":`true`,children:u})]}):null}exports.Sheet=c;
@@ -1,5 +1,5 @@
1
1
  import React from "react";
2
- import * as react_jsx_runtime1 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime0 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/ui/sheet/sheet.d.ts
5
5
  type Direction = 'top' | 'bottom' | 'left' | 'right';
@@ -23,6 +23,6 @@ declare function Sheet({
23
23
  className,
24
24
  closeOnBackdropClick,
25
25
  zIndex
26
- }: SheetProps): react_jsx_runtime1.JSX.Element | null;
26
+ }: SheetProps): react_jsx_runtime0.JSX.Element | null;
27
27
  //#endregion
28
28
  export { Sheet, type SheetProps };
@@ -1 +1 @@
1
- "use client";import"../../src-CukOR3K2.mjs";import"../../file-DShNxIW4.mjs";import{o as e}from"../../hooks-C9rXWkfW.mjs";import"../../providers-zftmvT1z.mjs";import"../../use-subset-image-DvV5Mlkc.mjs";import t from"clsx";import n,{useCallback as r,useEffect as i,useState as a}from"react";import{jsx as o,jsxs as s}from"react/jsx-runtime";import{cva as c}from"class-variance-authority";const l=c(t(`komc:absolute komc:bg-white komc:flex komc:flex-col komc:shadow-2xl`,`komc:transition-transform komc:duration-300 komc:ease-in-out`),{variants:{direction:{top:`komc:top-0 komc:left-0 komc:right-0 komc:-translate-y-full komc:data-[state=open]:translate-y-0`,bottom:`komc:bottom-0 komc:left-0 komc:right-0 komc:translate-y-full komc:data-[state=open]:translate-y-0`,left:`komc:top-0 komc:bottom-0 komc:left-0 komc:-translate-x-full komc:data-[state=open]:translate-x-0`,right:`komc:top-0 komc:bottom-0 komc:right-0 komc:translate-x-full komc:data-[state=open]:translate-x-0`}}}),u=c(``,{variants:{size:{full:``,half:``,auto:``},direction:{top:``,bottom:``,left:``,right:``}},compoundVariants:[{size:`full`,direction:`top`,className:`komc:h-full`},{size:`full`,direction:`bottom`,className:`komc:h-full`},{size:`full`,direction:`left`,className:`komc:w-full`},{size:`full`,direction:`right`,className:`komc:w-full`},{size:`half`,direction:`top`,className:`komc:h-[50dvh]`},{size:`half`,direction:`bottom`,className:`komc:h-[50dvh]`},{size:`half`,direction:`left`,className:`komc:w-[50dvw]`},{size:`half`,direction:`right`,className:`komc:w-[50dvw]`},{size:`auto`,direction:`top`,className:`komc:h-auto komc:max-h-[90dvh]`},{size:`auto`,direction:`bottom`,className:`komc:h-auto komc:max-h-[90dvh]`},{size:`auto`,direction:`left`,className:`komc:w-auto komc:max-w-[90dvw]`},{size:`auto`,direction:`right`,className:`komc:w-auto komc:max-w-[90dvw]`}]});function d({isOpen:n,onClose:c,direction:d=`bottom`,size:f=`full`,children:p,className:m,closeOnBackdropClick:h=!0,zIndex:g=1001}){let _=e(n,300),[v,y]=a(!1);i(()=>{if(n&&_){let e=setTimeout(()=>y(!0),10);return()=>clearTimeout(e)}else n||y(!1)},[n,_]);let b=r(e=>{e.key===`Escape`&&c()},[c]),x=r(()=>{h&&c()},[h,c]);return i(()=>(n?(document.addEventListener(`keydown`,b),document.body.style.overflow=`hidden`):document.body.style.overflow=`unset`,()=>{document.removeEventListener(`keydown`,b),document.body.style.overflow=`unset`}),[n,b]),_?s(`div`,{className:`komc:fixed komc:inset-0 komc:flex komc:justify-center komc:items-center`,style:{zIndex:g},children:[o(`button`,{type:`button`,"data-state":v?`open`:`closed`,className:t(`komc:absolute komc:inset-0 komc:w-full komc:h-full komc:bg-black/40 komc:cursor-default`,`komc:transition-opacity komc:duration-300 komc:ease-in-out`,`komc:opacity-0 komc:data-[state=open]:opacity-100`),onClick:x,"aria-label":`close sheet`}),o(`div`,{"data-state":v?`open`:`closed`,className:t(l({direction:d,className:m}),u({direction:d,size:f})),role:`dialog`,"aria-modal":`true`,children:p})]}):null}export{d as Sheet};
1
+ "use client";import"../../src-CukOR3K2.mjs";import"../../file-DShNxIW4.mjs";import{o as e}from"../../hooks-C9rXWkfW.mjs";import"../../providers-zftmvT1z.mjs";import"../../use-subset-image-D8ssrZhj.mjs";import t from"clsx";import n,{useCallback as r,useEffect as i,useState as a}from"react";import{jsx as o,jsxs as s}from"react/jsx-runtime";import{cva as c}from"class-variance-authority";const l=c(t(`komc:absolute komc:bg-white komc:flex komc:flex-col komc:shadow-2xl`,`komc:transition-transform komc:duration-300 komc:ease-in-out`),{variants:{direction:{top:`komc:top-0 komc:left-0 komc:right-0 komc:-translate-y-full komc:data-[state=open]:translate-y-0`,bottom:`komc:bottom-0 komc:left-0 komc:right-0 komc:translate-y-full komc:data-[state=open]:translate-y-0`,left:`komc:top-0 komc:bottom-0 komc:left-0 komc:-translate-x-full komc:data-[state=open]:translate-x-0`,right:`komc:top-0 komc:bottom-0 komc:right-0 komc:translate-x-full komc:data-[state=open]:translate-x-0`}}}),u=c(``,{variants:{size:{full:``,half:``,auto:``},direction:{top:``,bottom:``,left:``,right:``}},compoundVariants:[{size:`full`,direction:`top`,className:`komc:h-full`},{size:`full`,direction:`bottom`,className:`komc:h-full`},{size:`full`,direction:`left`,className:`komc:w-full`},{size:`full`,direction:`right`,className:`komc:w-full`},{size:`half`,direction:`top`,className:`komc:h-[50dvh]`},{size:`half`,direction:`bottom`,className:`komc:h-[50dvh]`},{size:`half`,direction:`left`,className:`komc:w-[50dvw]`},{size:`half`,direction:`right`,className:`komc:w-[50dvw]`},{size:`auto`,direction:`top`,className:`komc:h-auto komc:max-h-[90dvh]`},{size:`auto`,direction:`bottom`,className:`komc:h-auto komc:max-h-[90dvh]`},{size:`auto`,direction:`left`,className:`komc:w-auto komc:max-w-[90dvw]`},{size:`auto`,direction:`right`,className:`komc:w-auto komc:max-w-[90dvw]`}]});function d({isOpen:n,onClose:c,direction:d=`bottom`,size:f=`full`,children:p,className:m,closeOnBackdropClick:h=!0,zIndex:g=1001}){let _=e(n,300),[v,y]=a(!1);i(()=>{if(n&&_){let e=setTimeout(()=>y(!0),10);return()=>clearTimeout(e)}else n||y(!1)},[n,_]);let b=r(e=>{e.key===`Escape`&&c()},[c]),x=r(()=>{h&&c()},[h,c]);return i(()=>(n?(document.addEventListener(`keydown`,b),document.body.style.overflow=`hidden`):document.body.style.overflow=`unset`,()=>{document.removeEventListener(`keydown`,b),document.body.style.overflow=`unset`}),[n,b]),_?s(`div`,{className:`komc:fixed komc:inset-0 komc:flex komc:justify-center komc:items-center`,style:{zIndex:g},children:[o(`button`,{type:`button`,"data-state":v?`open`:`closed`,className:t(`komc:absolute komc:inset-0 komc:w-full komc:h-full komc:bg-black/40 komc:cursor-default`,`komc:transition-opacity komc:duration-300 komc:ease-in-out`,`komc:opacity-0 komc:data-[state=open]:opacity-100`),onClick:x,"aria-label":`close sheet`}),o(`div`,{"data-state":v?`open`:`closed`,className:t(l({direction:d,className:m}),u({direction:d,size:f})),role:`dialog`,"aria-modal":`true`,children:p})]}):null}export{d as Sheet};
@@ -1 +1 @@
1
- "use client";const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../src-CjpmdVyv.cjs`);const t=require(`../../common-CQWUs1nE.cjs`);require(`../../file-5mweNdAM.cjs`);const n=require(`../../hooks--O5RcEJq.cjs`);require(`../../providers-CkXkdYcB.cjs`),require(`../../use-subset-image-DhX5WmYG.cjs`);let r=require(`clsx`);r=e.t(r);let i=require(`react`),a=require(`react/jsx-runtime`),o=require(`class-variance-authority`),s=require(`react-dom`);function c({children:e,setOpen:t}){return(0,a.jsx)(`div`,{"data-komc":!0,className:(0,r.default)(`komc:inline-flex komc:shrink-0 komc:justify-center`,`komc:items-center komc:outline-none`),onMouseLeave:()=>t(!1),onMouseOver:()=>t(!0),onFocus:()=>t(!0),onBlur:()=>t(!1),onClick:()=>t(!0),children:e})}const l=(0,o.cva)(t.n(`komc:z-99 komc:w-max komc:max-w-70 komc:p-2 komc:rounded-md`,`komc:break-all komc:transition-opacity komc:duration-300 komc:bg-white`,`komc:drop-shadow-[0px_0.5px_3px_rgba(0,0,0,0.2)] komc:text-xs`),{variants:{portal:{true:`komc:fixed`,false:`komc:absolute`},placement:{top:``,bottom:``,"top-start":``,"top-end":``,"bottom-start":``,"bottom-end":``}},compoundVariants:[{portal:!0,placement:`top`,className:`komc:-translate-y-2`},{portal:!0,placement:`bottom`,className:`komc:translate-y-2`},{portal:!0,placement:`top-start`,className:`komc:-translate-y-2`},{portal:!0,placement:`top-end`,className:`komc:-translate-y-2`},{portal:!0,placement:`bottom-start`,className:`komc:translate-y-2`},{portal:!0,placement:`bottom-end`,className:`komc:translate-y-2`},{portal:!1,placement:`top`,className:`komc:bottom-full komc:left-1/2 komc:-translate-x-1/2`},{portal:!1,placement:`bottom`,className:`komc:top-full komc:left-1/2 komc:-translate-x-1/2`},{portal:!1,placement:`top-start`,className:`komc:bottom-full komc:left-0`},{portal:!1,placement:`top-end`,className:`komc:bottom-full komc:right-0`},{portal:!1,placement:`bottom-start`,className:`komc:top-full komc:left-0`},{portal:!1,placement:`bottom-end`,className:`komc:top-full komc:right-0`}],defaultVariants:{placement:`top`,portal:!1}}),u=(0,i.forwardRef)(({portal:e,children:t,className:n,placement:r,...i},o)=>(0,a.jsx)(`div`,{ref:o,"data-komc":!0,role:`tooltip`,className:l({portal:e,placement:r,className:n}),...i,children:t}));var d=u;const f=(0,o.cva)(t.n(`komc:absolute komc:w-2 komc:h-2 komc:bg-inherit`,`komc:transition-opacity komc:duration-300`),{variants:{placement:{top:t.n(`komc:top-full komc:-mt-1 komc:left-1/2`),bottom:t.n(`komc:bottom-full komc:-mb-1 komc:left-1/2`),"top-start":t.n(`komc:top-full komc:-mt-1 komc:left-5`),"top-end":t.n(`komc:top-full komc:-mt-1 komc:right-5`),"bottom-start":t.n(`komc:bottom-full komc:-mb-1 komc:left-5`),"bottom-end":t.n(`komc:bottom-full komc:-mb-1 komc:right-5`)}},defaultVariants:{placement:`top`}}),p=({placement:e,className:t,offset:n,style:r,...o})=>{let s=(0,i.useMemo)(()=>{switch(e){case`top`:case`top-start`:case`top-end`:return`rotate(45deg)`;case`bottom`:case`bottom-start`:case`bottom-end`:return`rotate(225deg)`;default:return`rotate(45deg)`}},[e]);return(0,a.jsx)(`div`,{className:f({placement:e,className:t}),style:{transform:`translate(${n?.x}px, ${n?.y}px) ${s}`},...o})};var m=p;const h=24,g=2,_=180,v=(e,t)=>{let[,n]=e.split(`-`);return n?`${t}-${n}`:t};function y({placement:e,className:t,content:n,open:o,hiddenRef:c,containerRef:l}){let[u,f]=(0,i.useState)(!1),[p,h]=(0,i.useState)(e),[g,_]=(0,i.useState)({top:0,left:0}),[y,b]=(0,i.useState)({x:0,y:0});(0,i.useEffect)(()=>{f(!0)},[]);let x=(0,i.useCallback)(()=>{let t=l.current,n=c.current;if(!t||!n)return;let r=t.getBoundingClientRect(),i=n.getBoundingClientRect(),a=e,[o]=a.split(`-`),s=r.top,u=window.innerHeight-r.bottom;o===`bottom`&&u<i.height&&s>=i.height?a=v(a,`top`):o===`top`&&s<i.height&&u>=i.height&&(a=v(a,`bottom`)),h(a);let[d,f]=a.split(`-`),p=r.top,m=r.left+r.width/2-i.width/2;switch(d){case`top`:p-=i.height;break;case`bottom`:p+=r.height;break}switch(f){case`start`:m+=i.width/2-24;break;case`end`:m-=i.width/2-24;break}let g=m,y=window.innerWidth;g+i.width>y-4&&(g=y-i.width-4),g<4&&(g=4),_({top:p,left:g}),b({x:m-g,y:0})},[e,l,c]);return(0,i.useEffect)(()=>{if(!u||!o)return;console.log(`updateLayout`);let e=!1,t=0,n=0,r=!1;x();let i=()=>{r||=(t=requestAnimationFrame(()=>{e||x(),r=!1}),!0)};window.addEventListener(`scroll`,i,{passive:!0}),window.addEventListener(`resize`,i);let a=0,s=0,c=``,d=()=>{if(e||a>=180)return;let t=l.current;if(t){let e=t.getBoundingClientRect(),n=`${e.top.toFixed(4)},${e.left.toFixed(4)},${e.width.toFixed(4)},${e.height.toFixed(4)}`;n===c?s+=1:(s=0,c=n,x())}s<2&&(a+=1,n=requestAnimationFrame(d))};return n=requestAnimationFrame(d),()=>{e=!0,cancelAnimationFrame(t),cancelAnimationFrame(n),window.removeEventListener(`scroll`,i),window.removeEventListener(`resize`,i)}},[u,o,x,l]),u?(0,s.createPortal)((0,a.jsxs)(d,{portal:!0,"data-komc":!0,placement:p,className:(0,r.default)(t,o?`komc:visible komc:opacity-100`:`komc:opacity-0 komc:invisible`),style:{...g},children:[(0,a.jsx)(`span`,{children:n}),(0,a.jsx)(m,{placement:p,offset:y})]}),document.body):null}const b=(0,i.forwardRef)(({children:e,content:t,defaultOpen:o=!1,className:s,placement:l=`top`},u)=>{let[f,p]=(0,i.useState)(o),m=(0,i.useRef)(null),h=(0,i.useRef)(null);return n.i({ref:m,setOpen:p}),(0,a.jsxs)(`div`,{ref:m,"data-komc":!0,className:`komc:flex komc:shrink-0 komc:relative komc:overflow-hidden komc:w-fit komc:h-fit`,children:[(0,a.jsx)(c,{setOpen:p,children:e}),(0,a.jsx)(y,{placement:l,className:s,open:f,content:t,hiddenRef:h,containerRef:m}),(0,a.jsx)(d,{ref:h,role:`presentation`,"aria-hidden":`true`,placement:l,className:(0,r.default)(`komc:opacity-0 komc:invisible`,s),children:(0,a.jsx)(`span`,{children:t})})]})});var x=b;exports.Tooltip=x;
1
+ "use client";const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../src-CjpmdVyv.cjs`);const t=require(`../../common-Bn0Ko6B7.cjs`);require(`../../file-5mweNdAM.cjs`);const n=require(`../../hooks--O5RcEJq.cjs`);require(`../../providers-CkXkdYcB.cjs`),require(`../../use-subset-image-DC86cg6O.cjs`);let r=require(`clsx`);r=e.t(r);let i=require(`react`),a=require(`react/jsx-runtime`),o=require(`class-variance-authority`),s=require(`react-dom`);function c({children:e,setOpen:t}){return(0,a.jsx)(`div`,{"data-komc":!0,className:(0,r.default)(`komc:inline-flex komc:shrink-0 komc:justify-center`,`komc:items-center komc:outline-none`),onMouseLeave:()=>t(!1),onMouseOver:()=>t(!0),onFocus:()=>t(!0),onBlur:()=>t(!1),onClick:()=>t(!0),children:e})}const l=(0,o.cva)(t.n(`komc:z-99 komc:w-max komc:max-w-70 komc:p-2 komc:rounded-md`,`komc:break-all komc:transition-opacity komc:duration-300 komc:bg-white`,`komc:drop-shadow-[0px_0.5px_3px_rgba(0,0,0,0.2)] komc:text-xs`),{variants:{portal:{true:`komc:fixed`,false:`komc:absolute`},placement:{top:``,bottom:``,"top-start":``,"top-end":``,"bottom-start":``,"bottom-end":``}},compoundVariants:[{portal:!0,placement:`top`,className:`komc:-translate-y-2`},{portal:!0,placement:`bottom`,className:`komc:translate-y-2`},{portal:!0,placement:`top-start`,className:`komc:-translate-y-2`},{portal:!0,placement:`top-end`,className:`komc:-translate-y-2`},{portal:!0,placement:`bottom-start`,className:`komc:translate-y-2`},{portal:!0,placement:`bottom-end`,className:`komc:translate-y-2`},{portal:!1,placement:`top`,className:`komc:bottom-full komc:left-1/2 komc:-translate-x-1/2`},{portal:!1,placement:`bottom`,className:`komc:top-full komc:left-1/2 komc:-translate-x-1/2`},{portal:!1,placement:`top-start`,className:`komc:bottom-full komc:left-0`},{portal:!1,placement:`top-end`,className:`komc:bottom-full komc:right-0`},{portal:!1,placement:`bottom-start`,className:`komc:top-full komc:left-0`},{portal:!1,placement:`bottom-end`,className:`komc:top-full komc:right-0`}],defaultVariants:{placement:`top`,portal:!1}}),u=(0,i.forwardRef)(({portal:e,children:t,className:n,placement:r,...i},o)=>(0,a.jsx)(`div`,{ref:o,"data-komc":!0,role:`tooltip`,className:l({portal:e,placement:r,className:n}),...i,children:t}));var d=u;const f=(0,o.cva)(t.n(`komc:absolute komc:w-2 komc:h-2 komc:bg-inherit`,`komc:transition-opacity komc:duration-300`),{variants:{placement:{top:t.n(`komc:top-full komc:-mt-1 komc:left-1/2`),bottom:t.n(`komc:bottom-full komc:-mb-1 komc:left-1/2`),"top-start":t.n(`komc:top-full komc:-mt-1 komc:left-5`),"top-end":t.n(`komc:top-full komc:-mt-1 komc:right-5`),"bottom-start":t.n(`komc:bottom-full komc:-mb-1 komc:left-5`),"bottom-end":t.n(`komc:bottom-full komc:-mb-1 komc:right-5`)}},defaultVariants:{placement:`top`}}),p=({placement:e,className:t,offset:n,...r})=>{let o=(0,i.useMemo)(()=>{switch(e){case`top`:case`top-start`:case`top-end`:return`rotate(45deg)`;case`bottom`:case`bottom-start`:case`bottom-end`:return`rotate(225deg)`;default:return`rotate(45deg)`}},[e]);return(0,a.jsx)(`div`,{className:f({placement:e,className:t}),style:{transform:`translate(${n?.x}px, ${n?.y}px) ${o}`},...r})};var m=p;const h=24,g=2,_=180,v=(e,t)=>{let[,n]=e.split(`-`);return n?`${t}-${n}`:t};function y({placement:e,className:t,content:n,open:o,hiddenRef:c,containerRef:l}){let[u,f]=(0,i.useState)(!1),[p,h]=(0,i.useState)(e),[g,_]=(0,i.useState)({top:0,left:0}),[y,b]=(0,i.useState)({x:0,y:0});(0,i.useEffect)(()=>{f(!0)},[]);let x=(0,i.useCallback)(()=>{let t=l.current,n=c.current;if(!t||!n)return;let r=t.getBoundingClientRect(),i=n.getBoundingClientRect(),a=e,[o]=a.split(`-`),s=r.top,u=window.innerHeight-r.bottom;o===`bottom`&&u<i.height&&s>=i.height?a=v(a,`top`):o===`top`&&s<i.height&&u>=i.height&&(a=v(a,`bottom`)),h(a);let[d,f]=a.split(`-`),p=r.top,m=r.left+r.width/2-i.width/2;switch(d){case`top`:p-=i.height;break;case`bottom`:p+=r.height;break}switch(f){case`start`:m+=i.width/2-24;break;case`end`:m-=i.width/2-24;break}let g=m,y=window.innerWidth;g+i.width>y-4&&(g=y-i.width-4),g<4&&(g=4),_({top:p,left:g}),b({x:m-g,y:0})},[e,l,c]);return(0,i.useEffect)(()=>{if(!u||!o)return;console.log(`updateLayout`);let e=!1,t=0,n=0,r=!1;x();let i=()=>{r||=(t=requestAnimationFrame(()=>{e||x(),r=!1}),!0)};window.addEventListener(`scroll`,i,{passive:!0}),window.addEventListener(`resize`,i);let a=0,s=0,c=``,d=()=>{if(e||a>=180)return;let t=l.current;if(t){let e=t.getBoundingClientRect(),n=`${e.top.toFixed(4)},${e.left.toFixed(4)},${e.width.toFixed(4)},${e.height.toFixed(4)}`;n===c?s+=1:(s=0,c=n,x())}s<2&&(a+=1,n=requestAnimationFrame(d))};return n=requestAnimationFrame(d),()=>{e=!0,cancelAnimationFrame(t),cancelAnimationFrame(n),window.removeEventListener(`scroll`,i),window.removeEventListener(`resize`,i)}},[u,o,x,l]),u?(0,s.createPortal)((0,a.jsxs)(d,{portal:!0,"data-komc":!0,placement:p,className:(0,r.default)(t,o?`komc:visible komc:opacity-100`:`komc:opacity-0 komc:invisible`),style:{...g},children:[(0,a.jsx)(`span`,{children:n}),(0,a.jsx)(m,{placement:p,offset:y})]}),document.body):null}const b=(0,i.forwardRef)(({children:e,content:t,defaultOpen:o=!1,className:s,placement:l=`top`})=>{let[u,f]=(0,i.useState)(o),p=(0,i.useRef)(null),m=(0,i.useRef)(null);return n.i({ref:p,setOpen:f}),(0,a.jsxs)(`div`,{ref:p,"data-komc":!0,className:`komc:flex komc:shrink-0 komc:relative komc:overflow-hidden komc:w-fit komc:h-fit`,children:[(0,a.jsx)(c,{setOpen:f,children:e}),(0,a.jsx)(y,{placement:l,className:s,open:u,content:t,hiddenRef:m,containerRef:p}),(0,a.jsx)(d,{ref:m,role:`presentation`,"aria-hidden":`true`,placement:l,className:(0,r.default)(`komc:opacity-0 komc:invisible`,s),children:(0,a.jsx)(`span`,{children:t})})]})});var x=b;exports.Tooltip=x;
@@ -1,4 +1,4 @@
1
- import * as react3 from "react";
1
+ import * as react5 from "react";
2
2
  import { HTMLAttributes } from "react";
3
3
 
4
4
  //#region src/ui/tooltip/tooltip-container.d.ts
@@ -11,6 +11,6 @@ interface TooltipContainerProps extends HTMLAttributes<HTMLDivElement> {
11
11
  placement?: TooltipPlacement;
12
12
  defaultOpen?: boolean;
13
13
  }
14
- declare const TooltipContainer: react3.ForwardRefExoticComponent<TooltipContainerProps & react3.RefAttributes<HTMLDivElement>>;
14
+ declare const TooltipContainer: react5.ForwardRefExoticComponent<TooltipContainerProps & react5.RefAttributes<HTMLDivElement>>;
15
15
  //#endregion
16
16
  export { TooltipContainer as Tooltip, type TooltipContainerProps as TooltipProps };