@usevyre/react 1.1.0 → 1.2.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.
- package/dist/components/Calendar/Calendar.d.ts +12 -11
- package/dist/components/Calendar/DatePicker.d.ts +32 -0
- package/dist/components/Conversation/Conversation.d.ts +115 -0
- package/dist/components/DateRangePicker/DateRangePicker.d.ts +58 -0
- package/dist/components/Input/Input.d.ts +22 -1
- package/dist/components/Item/Item.d.ts +74 -0
- package/dist/components/Kanban/Kanban.d.ts +76 -0
- package/dist/components/Radio/Radio.d.ts +77 -0
- package/dist/components/RichTextEditor/RichTextEditor.d.ts +44 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +25 -4
- package/dist/index.js +2653 -1597
- package/dist/styles/components.css +848 -0
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),n=require("react"),F=require("react-dom");function f(...e){const a=[];for(const r of e)if(r){if(typeof r=="string")a.push(r);else if(Array.isArray(r)){const s=f(...r);s&&a.push(s)}else if(typeof r=="object")for(const[s,o]of Object.entries(r))o&&a.push(s)}return a.join(" ")}const rr={primary:"vyre-btn--primary",secondary:"vyre-btn--secondary",ghost:"vyre-btn--ghost",accent:"vyre-btn--accent",teal:"vyre-btn--teal",danger:"vyre-btn--danger"},ar={sm:"vyre-btn--sm",md:"vyre-btn--md",lg:"vyre-btn--lg",icon:"vyre-btn--icon"},ve=n.forwardRef(({variant:e="secondary",size:a="md",loading:r=!1,disabled:s,leftIcon:o,rightIcon:i,className:c,children:d,as:u="button",...h},m)=>{const y=s||r;return t.jsxs(u,{ref:m,className:f("vyre-btn",rr[e],ar[a],r&&"vyre-btn--loading",c),disabled:u==="button"?y:void 0,"aria-disabled":y,"data-variant":e,"data-size":a,...h,children:[r&&t.jsx("span",{className:"vyre-btn__spinner","aria-hidden":"true",children:t.jsx(nr,{})}),!r&&o&&t.jsx("span",{className:"vyre-btn__icon vyre-btn__icon--left","aria-hidden":"true",children:o}),d&&t.jsx("span",{className:"vyre-btn__label",children:d}),i&&t.jsx("span",{className:"vyre-btn__icon vyre-btn__icon--right","aria-hidden":"true",children:i})]})});ve.displayName="VyreButton";function nr(){return t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"vyre-spinner","aria-hidden":"true",children:t.jsx("circle",{cx:"7",cy:"7",r:"5.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeDasharray:"28",strokeDashoffset:"10"})})}const ye=n.forwardRef(({variant:e="default",dot:a=!1,className:r,children:s,...o},i)=>t.jsxs("span",{ref:i,className:f("vyre-badge",`vyre-badge--${e}`,r),"data-variant":e,...o,children:[a&&t.jsx("span",{className:"vyre-badge__dot","aria-hidden":"true"}),s]}));ye.displayName="VyreBadge";const fe=n.forwardRef(({variant:e="default",hoverable:a=!1,clickable:r=!1,className:s,children:o,...i},c)=>t.jsx("div",{ref:c,className:f("vyre-card",`vyre-card--${e}`,a&&"vyre-card--hoverable",r&&"vyre-card--clickable",s),"data-variant":e,role:r?"button":void 0,tabIndex:r?0:void 0,...i,children:o}));fe.displayName="VyreCard";const he=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-card__header",e),...r,children:a}));he.displayName="VyreCardHeader";const be=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-card__body",e),...r,children:a}));be.displayName="VyreCardBody";const xe=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-card__footer",e),...r,children:a}));xe.displayName="VyreCardFooter";const pe=n.forwardRef(({label:e,hint:a,state:r="idle",required:s=!1,htmlFor:o,className:i,children:c,...d},u)=>t.jsxs("div",{ref:u,className:f("vyre-field",r!=="idle"&&`vyre-field--${r}`,i),"data-state":r,...d,children:[e&&t.jsxs("label",{className:"vyre-field__label",htmlFor:o,children:[e,s&&t.jsx("span",{className:"vyre-field__required","aria-label":"required",children:"*"})]}),c,a&&t.jsx("span",{className:"vyre-field__hint",role:r==="error"?"alert":void 0,children:a})]}));pe.displayName="VyreField";const _e=n.forwardRef(({size:e="md",leftElement:a,rightElement:r,className:s,...o},i)=>a||r?t.jsxs("div",{className:f("vyre-input-wrapper",`vyre-input-wrapper--${e}`),children:[a&&t.jsx("span",{className:"vyre-input__element vyre-input__element--left","aria-hidden":"true",children:a}),t.jsx("input",{ref:i,className:f("vyre-input",`vyre-input--${e}`,!!a&&"vyre-input--has-left",!!r&&"vyre-input--has-right",s),...o}),r&&t.jsx("span",{className:"vyre-input__element vyre-input__element--right","aria-hidden":"true",children:r})]}):t.jsx("input",{ref:i,className:f("vyre-input",`vyre-input--${e}`,s),...o}));_e.displayName="VyreInput";const ge=n.forwardRef(({size:e="md",resize:a="vertical",className:r,style:s,...o},i)=>t.jsx("textarea",{ref:i,className:f("vyre-textarea",`vyre-textarea--${e}`,r),style:{resize:a,...s},...o}));ge.displayName="VyreTextarea";const sr=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(","),we=n.forwardRef(({open:e,onClose:a,size:r="md",closeOnBackdrop:s=!0,closeOnEsc:o=!0,initialFocus:i,className:c,children:d,"aria-label":u,"aria-labelledby":h,...m},y)=>{const b=n.useRef(null),_=n.useRef(null),l=n.useCallback(x=>{b.current=x,typeof y=="function"?y(x):y&&(y.current=x)},[y]),v=n.useCallback(x=>{if(x.key!=="Tab")return;const N=b.current;if(!N)return;const j=Array.from(N.querySelectorAll(sr));if(!j.length)return;const S=j[0],E=j[j.length-1];x.shiftKey&&document.activeElement===S?(x.preventDefault(),E.focus()):!x.shiftKey&&document.activeElement===E&&(x.preventDefault(),S.focus())},[]),p=n.useCallback(x=>{x.key==="Escape"&&o&&a()},[o,a]);return n.useEffect(()=>{if(!e)return;document.addEventListener("keydown",p),document.addEventListener("keydown",v);const x=document.body.style.overflow;document.body.style.overflow="hidden";const N=setTimeout(()=>{var j;i!=null&&i.current?i.current.focus():(j=b.current)==null||j.focus()},0);return()=>{document.removeEventListener("keydown",p),document.removeEventListener("keydown",v),document.body.style.overflow=x,clearTimeout(N)}},[e,p,v,i]),e?F.createPortal(t.jsx("div",{ref:_,className:"vyre-modal-backdrop",onClick:x=>{s&&x.target===_.current&&a()},role:"presentation",children:t.jsx("div",{ref:l,className:f("vyre-modal",`vyre-modal--${r}`,c),role:"dialog","aria-modal":"true","aria-label":u,"aria-labelledby":h,tabIndex:-1,...m,children:d})}),document.body):null});we.displayName="VyreModal";const je=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-modal__header",e),...r,children:a}));je.displayName="VyreModalHeader";const ke=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-modal__body",e),...r,children:a}));ke.displayName="VyreModalBody";const Ne=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-modal__footer",e),...r,children:a}));Ne.displayName="VyreModalFooter";const Ce=n.createContext(null);function or(e,a){switch(a.type){case"ADD":return[...e,a.payload];case"REMOVE":return e.filter(r=>r.id!==a.id);default:return e}}let ir=0;const lr=()=>`vyre-t-${++ir}`;function dr({children:e}){const[a,r]=n.useReducer(or,[]),s=n.useCallback(i=>{const c=lr();return r({type:"ADD",payload:{...i,id:c}}),c},[]),o=n.useCallback(i=>{r({type:"REMOVE",id:i})},[]);return t.jsxs(Ce.Provider,{value:{toast:s,dismiss:o},children:[e,typeof document<"u"&&F.createPortal(t.jsx("div",{className:"vyre-toast-viewport","aria-live":"polite","aria-atomic":"false","aria-label":"Notifications",children:a.map(i=>t.jsx(ur,{...i,onDismiss:()=>o(i.id)},i.id))}),document.body)]})}function cr(){const e=n.useContext(Ce);if(!e)throw new Error("useToast must be used inside <ToastProvider>");return e}function ur({title:e,description:a,variant:r="default",duration:s=4e3,onDismiss:o}){return n.useEffect(()=>{if(s===1/0)return;const i=setTimeout(o,s);return()=>clearTimeout(i)},[s,o]),t.jsxs("div",{className:f("vyre-toast",`vyre-toast--${r}`),role:"alert","data-variant":r,children:[t.jsxs("div",{className:"vyre-toast__content",children:[e&&t.jsx("p",{className:"vyre-toast__title",children:e}),a&&t.jsx("p",{className:"vyre-toast__description",children:a})]}),t.jsx("button",{className:"vyre-toast__close",onClick:o,"aria-label":"Dismiss notification",type:"button",children:t.jsx(mr,{})})]})}function mr(){return t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M10.5 3.5L3.5 10.5M3.5 3.5L10.5 10.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}const Le=n.forwardRef(({options:e,value:a,defaultValue:r,onChange:s,placeholder:o="Select an option",disabled:i=!1,size:c="md",className:d,...u},h)=>{const m=a!==void 0,[y,b]=n.useState(r??""),_=m?a:y,[l,v]=n.useState(!1),[p,x]=n.useState(-1),N=n.useRef(null),j=n.useRef(null),E=`${n.useId()}-listbox`,I=e.find(k=>k.value===_),D=e.filter(k=>!k.disabled),V=n.useCallback(()=>{v(!1),x(-1)},[]),T=n.useCallback(k=>{var w;k.disabled||(m||b(k.value),s==null||s(k.value),V(),(w=N.current)==null||w.focus())},[m,s,V]);n.useEffect(()=>{if(!l)return;const k=w=>{const L=h==null?void 0:h.current;L&&!L.contains(w.target)&&V()};return document.addEventListener("mousedown",k),()=>document.removeEventListener("mousedown",k)},[l,h,V]),n.useEffect(()=>{var w;if(!l||p<0)return;const k=(w=j.current)==null?void 0:w.children[p];k==null||k.scrollIntoView({block:"nearest"})},[p,l]);const B=k=>{switch(k.key){case"Enter":case" ":case"ArrowDown":{if(k.preventDefault(),!l){v(!0);const w=e.findIndex(L=>L.value===_);x(w>=0?w:0)}break}case"ArrowUp":{k.preventDefault(),l||(v(!0),x(e.length-1));break}case"Escape":{V();break}}},M=k=>{var w;switch(k.key){case"ArrowDown":{k.preventDefault(),x(L=>{let R=L+1;for(;R<e.length&&e[R].disabled;)R++;return R<e.length?R:L});break}case"ArrowUp":{k.preventDefault(),x(L=>{let R=L-1;for(;R>=0&&e[R].disabled;)R--;return R>=0?R:L});break}case"Enter":case" ":{k.preventDefault(),p>=0&&T(e[p]);break}case"Escape":case"Tab":{V(),(w=N.current)==null||w.focus();break}case"Home":{k.preventDefault();const L=e.findIndex(R=>!R.disabled);L>=0&&x(L);break}case"End":{k.preventDefault();const L=[...e].reverse().findIndex(R=>!R.disabled);L>=0&&x(e.length-1-L);break}}};return t.jsxs("div",{ref:h,className:f("vyre-select",`vyre-select--${c}`,d),"data-open":l,...u,children:[t.jsxs("button",{ref:N,type:"button",className:"vyre-select__trigger","aria-haspopup":"listbox","aria-expanded":l,"aria-controls":E,"aria-disabled":i,disabled:i,onClick:()=>{i||v(k=>{if(!k){const w=e.findIndex(L=>L.value===_);x(w>=0?w:0)}return!k})},onKeyDown:B,children:[I?t.jsx("span",{className:"vyre-select__value",children:I.label}):t.jsx("span",{className:"vyre-select__placeholder",children:o}),t.jsx(vr,{})]}),l&&t.jsxs("ul",{ref:j,id:E,role:"listbox",className:"vyre-select__dropdown","aria-label":"Options",tabIndex:-1,onKeyDown:M,children:[e.map((k,w)=>t.jsxs("li",{role:"option","aria-selected":k.value===_,"aria-disabled":k.disabled,"data-highlighted":w===p,className:"vyre-select__option",onMouseEnter:()=>!k.disabled&&x(w),onMouseDown:L=>{L.preventDefault(),T(k)},children:[k.label,k.value===_&&t.jsx(yr,{})]},k.value)),D.length===0&&t.jsx("li",{className:"vyre-select__empty",role:"presentation",children:"No options available"})]})]})});Le.displayName="VyreSelect";function vr(){return t.jsx("svg",{className:"vyre-select__chevron",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M3 5L7 9L11 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}function yr(){return t.jsx("svg",{className:"vyre-select__check",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2.5 7L5.5 10L11.5 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}const Re=n.createContext(null);function Se(){const e=n.useContext(Re);if(!e)throw new Error("Tab components must be used inside <Tabs>");return e}const Me=n.forwardRef(({defaultValue:e="",value:a,onChange:r,className:s,children:o,...i},c)=>{const d=a!==void 0,[u,h]=n.useState(e),m=d?a:u,y=n.useId(),b=n.useCallback(_=>{d||h(_),r==null||r(_)},[d,r]);return t.jsx(Re.Provider,{value:{value:m,onChange:b,baseId:y},children:t.jsx("div",{ref:c,className:f("vyre-tabs",s),...i,children:o})})});Me.displayName="VyreTabs";const Te=n.forwardRef(({className:e,children:a,"aria-label":r,...s},o)=>{const i=n.useRef(null),c=d=>{var y;const u=Array.from(((y=i.current)==null?void 0:y.querySelectorAll('[role="tab"]:not([disabled])'))??[]),h=u.findIndex(b=>b===document.activeElement);if(h<0)return;let m=h;if(d.key==="ArrowRight")m=(h+1)%u.length;else if(d.key==="ArrowLeft")m=(h-1+u.length)%u.length;else if(d.key==="Home")m=0;else if(d.key==="End")m=u.length-1;else return;d.preventDefault(),u[m].focus(),u[m].click()};return t.jsx("div",{ref:d=>{i.current=d,typeof o=="function"?o(d):o&&(o.current=d)},role:"tablist",className:f("vyre-tabs__list",e),"aria-label":r,onKeyDown:c,...s,children:a})});Te.displayName="VyreTabList";const Ee=n.forwardRef(({value:e,disabled:a=!1,className:r,children:s,...o},i)=>{const{value:c,onChange:d,baseId:u}=Se(),h=e===c;return t.jsx("button",{ref:i,role:"tab",type:"button",id:`${u}-tab-${e}`,"aria-controls":`${u}-panel-${e}`,"aria-selected":h,disabled:a,tabIndex:h?0:-1,className:f("vyre-tabs__tab",h&&"vyre-tabs__tab--active",r),"data-selected":h,onClick:()=>!a&&d(e),...o,children:s})});Ee.displayName="VyreTab";const Ie=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-tabs__panels",e),...r,children:a}));Ie.displayName="VyreTabPanels";const De=n.forwardRef(({value:e,className:a,children:r,...s},o)=>{const{value:i,baseId:c}=Se();return e===i?t.jsx("div",{ref:o,role:"tabpanel",id:`${c}-panel-${e}`,"aria-labelledby":`${c}-tab-${e}`,tabIndex:0,className:f("vyre-tabs__panel",a),...s,children:r}):null});De.displayName="VyreTabPanel";const fr=120,Ae=({content:e,placement:a="top",delay:r=300,children:s,className:o})=>{const[i,c]=n.useState("hidden"),d=n.useRef(null),u=n.useRef(null),h=n.useId(),m=n.useCallback(()=>{u.current&&(clearTimeout(u.current),u.current=null),d.current=setTimeout(()=>c("visible"),r)},[r]),y=n.useCallback(()=>{d.current&&(clearTimeout(d.current),d.current=null),c("leaving"),u.current=setTimeout(()=>c("hidden"),fr)},[]),b=n.Children.only(s),_=n.cloneElement(b,{onMouseEnter:l=>{var v,p;m(),(p=(v=b.props).onMouseEnter)==null||p.call(v,l)},onMouseLeave:l=>{var v,p;y(),(p=(v=b.props).onMouseLeave)==null||p.call(v,l)},onFocus:l=>{var v,p;c("visible"),(p=(v=b.props).onFocus)==null||p.call(v,l)},onBlur:l=>{var v,p;y(),(p=(v=b.props).onBlur)==null||p.call(v,l)},"aria-describedby":i!=="hidden"?h:void 0});return t.jsxs("span",{className:f("vyre-tooltip-wrapper",o),children:[_,i!=="hidden"&&t.jsxs("span",{id:h,role:"tooltip",className:f("vyre-tooltip",`vyre-tooltip--${a}`,i==="leaving"&&"vyre-tooltip--leaving"),"data-placement":a,children:[e,t.jsx("span",{className:"vyre-tooltip__arrow","aria-hidden":"true"})]})]})};Ae.displayName="VyreTooltip";const Be=n.createContext(null);function Ve(){const e=n.useContext(Be);if(!e)throw new Error("AccordionItem must be used within Accordion");return e}const $e=n.forwardRef(({type:e="single",defaultValue:a,value:r,onValueChange:s,className:o,children:i,...c},d)=>{const u=_=>_===void 0?[]:Array.isArray(_)?_:[_],[h,m]=n.useState(u(a)),y=r!==void 0?u(r):h,b=n.useCallback(_=>{let l;e==="single"?l=y.includes(_)?[]:[_]:l=y.includes(_)?y.filter(v=>v!==_):[...y,_],r===void 0&&m(l),s==null||s(e==="single"?l[0]??"":l)},[e,y,r,s]);return t.jsx(Be.Provider,{value:{type:e,value:y,toggle:b},children:t.jsx("div",{ref:d,className:["vyre-accordion",o].filter(Boolean).join(" "),...c,children:i})})});$e.displayName="Accordion";const ne=n.createContext(null),We=n.forwardRef(({value:e,className:a,children:r,...s},o)=>{const{value:i}=Ve(),c=i.includes(e);return t.jsx(ne.Provider,{value:{itemValue:e,isOpen:c},children:t.jsx("div",{ref:o,"data-state":c?"open":"closed",className:["vyre-accordion__item",a].filter(Boolean).join(" "),...s,children:r})})});We.displayName="AccordionItem";const He=n.forwardRef(({className:e,children:a,...r},s)=>{const{toggle:o}=Ve(),i=n.useContext(ne);if(!i)throw new Error("AccordionTrigger must be used within AccordionItem");const{itemValue:c,isOpen:d}=i;return t.jsxs("button",{ref:s,type:"button","aria-expanded":d,"data-state":d?"open":"closed",className:["vyre-accordion__trigger",e].filter(Boolean).join(" "),onClick:()=>o(c),...r,children:[t.jsx("span",{className:"vyre-accordion__trigger-text",children:a}),t.jsx("svg",{className:"vyre-accordion__chevron",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M4 6l4 4 4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})]})});He.displayName="AccordionTrigger";const Fe=n.forwardRef(({className:e,children:a,...r},s)=>{const o=n.useContext(ne);if(!o)throw new Error("AccordionContent must be used within AccordionItem");const{isOpen:i}=o;return t.jsx("div",{ref:s,hidden:!i,"data-state":i?"open":"closed",className:["vyre-accordion__content",e].filter(Boolean).join(" "),...r,children:t.jsx("div",{className:"vyre-accordion__content-inner",children:a})})});Fe.displayName="AccordionContent";const Pe=n.forwardRef(({src:e,alt:a="",fallback:r,size:s="md",status:o,className:i,...c},d)=>{var y;const[u,h]=n.useState(!1),m=e&&!u;return t.jsxs("span",{ref:d,"data-size":s,className:["vyre-avatar",i].filter(Boolean).join(" "),...c,children:[m?t.jsx("img",{src:e,alt:a,className:"vyre-avatar__img",onError:()=>h(!0)}):t.jsx("span",{className:"vyre-avatar__fallback","aria-label":a||r,children:r??((y=a==null?void 0:a.charAt(0))==null?void 0:y.toUpperCase())??"?"}),o&&t.jsx("span",{className:`vyre-avatar__status vyre-avatar__status--${o}`,"aria-label":o})]})});Pe.displayName="Avatar";const Oe=n.forwardRef(({checked:e,defaultChecked:a,indeterminate:r=!1,onCheckedChange:s,disabled:o,size:i="md",className:c,id:d,...u},h)=>{const m=n.useRef(null),y=h??m;return n.useEffect(()=>{y.current&&(y.current.indeterminate=r)},[r,y]),t.jsxs("span",{className:["vyre-checkbox",`vyre-checkbox--${i}`,c].filter(Boolean).join(" "),"data-disabled":o||void 0,"data-checked":e||void 0,"data-indeterminate":r||void 0,children:[t.jsx("input",{ref:y,type:"checkbox",id:d,checked:e,defaultChecked:a,disabled:o,className:"vyre-checkbox__input",onChange:b=>s==null?void 0:s(b.target.checked),...u}),t.jsx("span",{className:"vyre-checkbox__box","aria-hidden":"true",children:r?t.jsx("svg",{width:"10",height:"2",viewBox:"0 0 10 2",fill:"none",children:t.jsx("path",{d:"M1 1h8",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})}):t.jsx("svg",{width:"10",height:"8",viewBox:"0 0 10 8",fill:"none",children:t.jsx("path",{d:"M1 4l3 3 5-6",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"})})})]})});Oe.displayName="Checkbox";const Ke=n.forwardRef(({checked:e,defaultChecked:a=!1,onCheckedChange:r,disabled:s,size:o="md",className:i,...c},d)=>{const[u,h]=n.useState(a),m=e!==void 0?e:u,y=()=>{if(s)return;const b=!m;e===void 0&&h(b),r==null||r(b)};return t.jsx("button",{ref:d,type:"button",role:"switch","aria-checked":m,disabled:s,"data-checked":m||void 0,"data-size":o,className:["vyre-switch",i].filter(Boolean).join(" "),onClick:y,...c,children:t.jsx("span",{className:"vyre-switch__thumb"})})});Ke.displayName="Switch";const qe=n.forwardRef(({value:e,defaultValue:a=0,min:r=0,max:s=100,step:o=1,onValueChange:i,disabled:c,size:d="md",className:u,style:h,...m},y)=>{const[b,_]=n.useState(a),l=e!==void 0?e:b,v=(l-r)/(s-r)*100;return t.jsxs("div",{className:["vyre-slider",`vyre-slider--${d}`,u].filter(Boolean).join(" "),"data-disabled":c||void 0,style:{"--vyre-slider-pct":`${v}%`,...h},children:[t.jsx("input",{ref:y,type:"range",min:r,max:s,step:o,value:l,disabled:c,className:"vyre-slider__input",onChange:p=>{const x=Number(p.target.value);e===void 0&&_(x),i==null||i(x)},...m}),t.jsxs("div",{className:"vyre-slider__track",children:[t.jsx("div",{className:"vyre-slider__fill",style:{width:`${v}%`}}),t.jsx("div",{className:"vyre-slider__thumb",style:{left:`${v}%`}})]})]})});qe.displayName="Slider";const Ge=n.forwardRef(({value:e,max:a=100,indeterminate:r=!1,size:s="md",variant:o="default",className:i,...c},d)=>{const u=r?void 0:Math.min(100,Math.max(0,(e??0)/a*100));return t.jsx("div",{ref:d,role:"progressbar","aria-valuemin":0,"aria-valuemax":a,"aria-valuenow":r?void 0:e??0,"data-size":s,"data-variant":o,"data-indeterminate":r||void 0,className:["vyre-progress",i].filter(Boolean).join(" "),...c,children:t.jsx("div",{className:"vyre-progress__bar",style:u!==void 0?{width:`${u}%`}:void 0})})});Ge.displayName="Progress";const Ye=n.forwardRef(({orientation:e="horizontal",decorative:a=!0,className:r,...s},o)=>t.jsx("div",{ref:o,role:a?"none":"separator","aria-orientation":a?void 0:e,"data-orientation":e,className:["vyre-separator",r].filter(Boolean).join(" "),...s}));Ye.displayName="Separator";const Ue=n.forwardRef(({required:e,disabled:a,className:r,children:s,...o},i)=>t.jsxs("label",{ref:i,"data-required":e||void 0,"data-disabled":a||void 0,className:["vyre-label",r].filter(Boolean).join(" "),...o,children:[s,e&&t.jsx("span",{className:"vyre-label__required","aria-hidden":"true",children:"*"})]}));Ue.displayName="Label";const se=n.forwardRef(({variant:e="rect",width:a,height:r,className:s,style:o,...i},c)=>t.jsx("div",{ref:c,"aria-hidden":"true","data-variant":e,className:["vyre-skeleton",s].filter(Boolean).join(" "),style:{width:typeof a=="number"?`${a}px`:a,height:typeof r=="number"?`${r}px`:r,...o},...i}));se.displayName="Skeleton";const Q=8,hr=120;function br(e){const[a,r]=e.split("-");return{side:a,align:r??"center"}}function xr(e,a,r,s,o,i){const c=e.width,d=e.height,u=a.width,h=a.height,m=e.left+o,y=e.top+i;let b=0,_=0;switch(r){case"top":b=y-h-Q;break;case"bottom":b=y+d+Q;break;case"left":_=m-u-Q;break;case"right":_=m+c+Q;break}if(r==="top"||r==="bottom")switch(s){case"start":_=m;break;case"center":_=m+c/2-u/2;break;case"end":_=m+c-u;break}else switch(s){case"start":b=y;break;case"center":b=y+d/2-h/2;break;case"end":b=y+d-h;break}return{top:b,left:_}}const Xe=({trigger:e,children:a,open:r,onOpenChange:s,placement:o="bottom",closeOnOutside:i=!0,className:c})=>{const d=r!==void 0,[u,h]=n.useState(!1),[m,y]=n.useState(!1),[b,_]=n.useState(!1),[l,v]=n.useState({top:0,left:0}),p=d?r:u,x=n.useRef(null),N=n.useRef(null),j=n.useRef(null),S=n.useId(),{side:E,align:I}=br(o),D=n.useCallback(M=>{d||h(M),s==null||s(M)},[d,s]),V=n.useCallback(()=>D(!p),[p,D]),T=n.useCallback(()=>{y(!0),j.current=setTimeout(()=>{y(!1),_(!1),D(!1)},hr)},[D]);n.useEffect(()=>{p?(j.current&&(clearTimeout(j.current),j.current=null),y(!1),_(!0)):b&&!m&&T()},[p]),n.useEffect(()=>{if(!b||!x.current||!N.current)return;const M=x.current.getBoundingClientRect(),k=N.current.getBoundingClientRect(),w=xr(M,k,E,I,window.scrollX,window.scrollY);v(w)},[b,E,I]),n.useEffect(()=>{if(!b||!i)return;const M=k=>{N.current&&!N.current.contains(k.target)&&x.current&&!x.current.contains(k.target)&&T()};return document.addEventListener("mousedown",M),()=>document.removeEventListener("mousedown",M)},[b,i,T]),n.useEffect(()=>{if(!b)return;const M=k=>{k.key==="Escape"&&T()};return document.addEventListener("keydown",M),()=>document.removeEventListener("keydown",M)},[b,T]);const B=n.cloneElement(e,{ref:x,onClick:M=>{var k,w;V(),(w=(k=e.props).onClick)==null||w.call(k,M)},"aria-expanded":p,"aria-controls":S,"aria-haspopup":"dialog"});return t.jsxs(t.Fragment,{children:[B,b&&F.createPortal(t.jsx("div",{ref:N,id:S,role:"dialog","aria-modal":"false",className:f("vyre-popover",`vyre-popover--${E}`,m&&"vyre-popover--leaving",c),style:{top:l.top,left:l.left},children:a}),document.body)]})};Xe.displayName="VyrePopover";const ee=n.createContext(null),ze=n.createContext(null),pr=120,Ze=({trigger:e,children:a,placement:r="bottom-start",className:s})=>{const[o,i]=n.useState(!1),[c,d]=n.useState(!1),[u,h]=n.useState(!1),[m,y]=n.useState({top:0,left:0}),[b,_]=n.useState(-1),l=n.useRef(null),v=n.useRef(null),p=n.useRef(null),x=n.useId(),N=n.useCallback(()=>{var T;return Array.from(((T=v.current)==null?void 0:T.querySelectorAll("[role=menuitem]:not([aria-disabled=true]):not([disabled]),[role=menuitemcheckbox]:not([aria-disabled=true]):not([disabled]),[role=menuitemradio]:not([aria-disabled=true]):not([disabled])"))??[])},[]),j=n.useCallback(()=>{d(!0),p.current=setTimeout(()=>{var T;d(!1),h(!1),i(!1),_(-1),(T=l.current)==null||T.focus({preventScroll:!0})},pr)},[]),S=n.useCallback(()=>{p.current&&(clearTimeout(p.current),p.current=null),d(!1),i(!0),h(!0)},[]),E=n.useCallback(()=>{o?j():S()},[o,S,j]);n.useEffect(()=>{if(!u||!l.current)return;const T=l.current.getBoundingClientRect(),B=4,M=window.scrollX,k=window.scrollY;let w=0,L=0;r.startsWith("bottom")?(w=T.bottom+k+B,L=r==="bottom-start"?T.left+M:T.right+M):(w=T.top+k-B,L=r==="top-start"?T.left+M:T.right+M),y({top:w,left:L}),requestAnimationFrame(()=>{var A;(A=N()[0])==null||A.focus({preventScroll:!0}),_(0)})},[u,r,N]),n.useEffect(()=>{if(!u)return;const T=M=>{v.current&&!v.current.contains(M.target)&&l.current&&!l.current.contains(M.target)&&j()},B=M=>{var k,w,L;if(M.key==="Escape"){j();return}if(M.key==="ArrowDown"||M.key==="ArrowUp"){M.preventDefault();const R=N();if(!R.length)return;const A=M.key==="ArrowDown"?1:-1,Z=(b+A+R.length)%R.length;(k=R[Z])==null||k.focus({preventScroll:!0}),_(Z)}if(M.key==="Home"&&((w=N()[0])==null||w.focus({preventScroll:!0}),_(0)),M.key==="End"){const R=N();(L=R[R.length-1])==null||L.focus({preventScroll:!0}),_(R.length-1)}};return document.addEventListener("mousedown",T),document.addEventListener("keydown",B),()=>{document.removeEventListener("mousedown",T),document.removeEventListener("keydown",B)}},[u,b,j,N]);const I=n.cloneElement(e,{ref:l,onClick:T=>{var B,M;E(),(M=(B=e.props).onClick)==null||M.call(B,T)},"aria-expanded":o,"aria-haspopup":"menu","aria-controls":x}),D=r.endsWith("-end"),V=r.startsWith("top");return t.jsxs(ee.Provider,{value:{close:j},children:[I,u&&F.createPortal(t.jsx("div",{ref:v,id:x,role:"menu","aria-orientation":"vertical",className:f("vyre-dropdown",D&&"vyre-dropdown--end",V&&"vyre-dropdown--top",c&&"vyre-dropdown--leaving",s),style:{top:m.top,left:m.left,transform:D?"translateX(-100%)":void 0},children:a}),document.body)]})};Ze.displayName="VyreDropdownMenu";const Je=({children:e,className:a})=>t.jsx("div",{className:f("vyre-dropdown__label",a),children:e});Je.displayName="VyreDropdownLabel";const Qe=({children:e,onSelect:a,disabled:r=!1,variant:s="default",icon:o,shortcut:i,className:c})=>{const d=n.useContext(ee);return t.jsxs("button",{role:"menuitem",className:f("vyre-dropdown__item",s==="danger"&&"vyre-dropdown__item--danger",c),"aria-disabled":r||void 0,disabled:r,tabIndex:-1,onClick:()=>{r||(a==null||a(),d==null||d.close())},children:[o&&t.jsx("span",{className:"vyre-dropdown__item-icon","aria-hidden":"true",children:o}),t.jsx("span",{className:"vyre-dropdown__item-label",children:e}),i&&t.jsx("kbd",{className:"vyre-dropdown__item-shortcut",children:i})]})};Qe.displayName="VyreDropdownItem";const et=({children:e,checked:a,onCheckedChange:r,disabled:s=!1,shortcut:o,className:i})=>{const c=n.useContext(ee);return t.jsxs("button",{role:"menuitemcheckbox","aria-checked":a,"aria-disabled":s||void 0,disabled:s,tabIndex:-1,className:f("vyre-dropdown__item vyre-dropdown__item--checkbox",i),onClick:()=>{s||(r(!a),c==null||c.close())},children:[t.jsx("span",{className:"vyre-dropdown__item-indicator","aria-hidden":"true",children:a&&t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",children:t.jsx("path",{d:"M2 6l3 3 5-5",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",strokeLinejoin:"round"})})}),t.jsx("span",{className:"vyre-dropdown__item-label",children:e}),o&&t.jsx("kbd",{className:"vyre-dropdown__item-shortcut",children:o})]})};et.displayName="VyreDropdownCheckboxItem";const tt=({value:e,onValueChange:a,children:r})=>t.jsx(ze.Provider,{value:{value:e,onValueChange:a},children:t.jsx("div",{role:"group",children:r})});tt.displayName="VyreDropdownRadioGroup";const rt=({children:e,value:a,disabled:r=!1,className:s})=>{const o=n.useContext(ee),i=n.useContext(ze),c=(i==null?void 0:i.value)===a;return t.jsxs("button",{role:"menuitemradio","aria-checked":c,"aria-disabled":r||void 0,disabled:r,tabIndex:-1,className:f("vyre-dropdown__item vyre-dropdown__item--radio",s),onClick:()=>{r||(i==null||i.onValueChange(a),o==null||o.close())},children:[t.jsx("span",{className:"vyre-dropdown__item-indicator","aria-hidden":"true",children:c&&t.jsx("svg",{width:"8",height:"8",viewBox:"0 0 8 8",children:t.jsx("circle",{cx:"4",cy:"4",r:"3",fill:"currentColor"})})}),t.jsx("span",{className:"vyre-dropdown__item-label",children:e})]})};rt.displayName="VyreDropdownRadioItem";const at=({trigger:e,children:a,icon:r,placement:s="right",disabled:o=!1,className:i})=>{const[c,d]=n.useState(!1),[u,h]=n.useState({top:0,left:0}),m=n.useRef(null),y=n.useRef(null),b=n.useCallback(()=>{if(!m.current)return;const v=m.current.getBoundingClientRect(),p=window.scrollX,x=window.scrollY,N=2;h({top:v.top+x,left:s==="right"?v.right+p+N:v.left+p-N}),d(!0)},[s]),_=n.useCallback(()=>d(!1),[]),l=v=>{var x;const p=v.relatedTarget;(x=y.current)!=null&&x.contains(p)||_()};return t.jsxs(t.Fragment,{children:[t.jsxs("button",{ref:m,role:"menuitem","aria-haspopup":"menu","aria-expanded":c,"aria-disabled":o||void 0,disabled:o,tabIndex:-1,className:f("vyre-dropdown__item vyre-dropdown__item--sub",i),onMouseEnter:b,onMouseLeave:l,onFocus:b,children:[r&&t.jsx("span",{className:"vyre-dropdown__item-icon","aria-hidden":"true",children:r}),t.jsx("span",{className:"vyre-dropdown__item-label",children:e}),t.jsx("span",{className:"vyre-dropdown__item-chevron","aria-hidden":"true",children:t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",children:t.jsx("path",{d:s==="right"?"M4 2l4 4-4 4":"M8 2L4 6l4 4",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),c&&F.createPortal(t.jsx("div",{ref:y,role:"menu",className:f("vyre-dropdown vyre-dropdown--sub",s==="left"&&"vyre-dropdown--sub-left"),style:{position:"absolute",top:u.top,left:s==="right"?u.left:void 0,right:s==="left"?`calc(100vw - ${u.left}px)`:void 0,transform:s==="left"?"translateX(-100%)":void 0},onMouseLeave:v=>{var x;const p=v.relatedTarget;(x=m.current)!=null&&x.contains(p)||_()},children:a}),document.body)]})};at.displayName="VyreDropdownSub";const nt=({className:e})=>t.jsx("div",{role:"separator",className:f("vyre-dropdown__separator",e)});nt.displayName="VyreDropdownSeparator";const _r=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"1.4"}),t.jsx("path",{d:"M8 7v4M8 5v.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]}),gr=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"1.4"}),t.jsx("path",{d:"M5 8l2 2 4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}),wr=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("path",{d:"M8 2L14.5 13H1.5L8 2Z",stroke:"currentColor",strokeWidth:"1.4",strokeLinejoin:"round"}),t.jsx("path",{d:"M8 6v3M8 11v.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]}),jr=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"1.4"}),t.jsx("path",{d:"M6 6l4 4M10 6l-4 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]}),st={info:_r,success:gr,warning:wr,danger:jr},ot=({variant:e="info",title:a,icon:r,onClose:s,children:o,className:i})=>{const c=st[e];return t.jsxs("div",{role:"alert",className:f("vyre-alert",`vyre-alert--${e}`,i),children:[t.jsx("span",{className:"vyre-alert__icon","aria-hidden":"true",children:r??t.jsx(c,{})}),t.jsxs("div",{className:"vyre-alert__body",children:[a&&t.jsx("p",{className:"vyre-alert__title",children:a}),o&&t.jsx("div",{className:"vyre-alert__description",children:o})]}),s&&t.jsx("button",{type:"button",className:"vyre-alert__close","aria-label":"Dismiss",onClick:s,children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M3 3l8 8M11 3l-8 8",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})})]})};ot.displayName="VyreAlert";const kr=["button:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(","),it=({open:e,onOpenChange:a,title:r,description:s,variant:o="danger",confirmLabel:i="Confirm",cancelLabel:c="Cancel",onConfirm:d,onCancel:u,className:h})=>{const m=n.useRef(null),y=n.useRef(null),b=n.useRef(null),_=n.useCallback(()=>{u==null||u(),a(!1)},[u,a]),l=n.useCallback(()=>{d==null||d(),a(!1)},[d,a]),v=n.useCallback(x=>{if(x.key!=="Tab")return;const N=m.current;if(!N)return;const j=Array.from(N.querySelectorAll(kr));if(!j.length)return;const S=j[0],E=j[j.length-1];x.shiftKey&&document.activeElement===S?(x.preventDefault(),E.focus()):!x.shiftKey&&document.activeElement===E&&(x.preventDefault(),S.focus())},[]);if(n.useEffect(()=>{if(!e)return;document.addEventListener("keydown",v);const x=document.body.style.overflow;document.body.style.overflow="hidden";const N=j=>{j.key==="Escape"&&_()};return document.addEventListener("keydown",N),setTimeout(()=>{var j;return(j=b.current)==null?void 0:j.focus()},0),()=>{document.removeEventListener("keydown",v),document.removeEventListener("keydown",N),document.body.style.overflow=x}},[e,v,_]),!e)return null;const p=st[o];return F.createPortal(t.jsx("div",{ref:y,className:"vyre-alert-dialog-backdrop",onClick:x=>{x.target===y.current&&_()},role:"presentation",children:t.jsxs("div",{ref:m,role:"alertdialog","aria-modal":"true","aria-labelledby":"vyre-ad-title","aria-describedby":s?"vyre-ad-desc":void 0,className:f("vyre-alert-dialog",`vyre-alert-dialog--${o}`,h),tabIndex:-1,children:[t.jsx("div",{className:"vyre-alert-dialog__icon-wrap",children:t.jsx("span",{className:f("vyre-alert-dialog__icon",`vyre-alert-dialog__icon--${o}`),children:t.jsx(p,{})})}),t.jsxs("div",{className:"vyre-alert-dialog__body",children:[t.jsx("h2",{id:"vyre-ad-title",className:"vyre-alert-dialog__title",children:r}),s&&t.jsx("p",{id:"vyre-ad-desc",className:"vyre-alert-dialog__description",children:s})]}),t.jsxs("div",{className:"vyre-alert-dialog__footer",children:[t.jsx("button",{ref:b,type:"button",className:"vyre-btn vyre-btn--ghost vyre-btn--sm",onClick:_,children:c}),t.jsx("button",{type:"button",className:f("vyre-btn vyre-btn--sm",o==="danger"&&"vyre-btn--danger",o==="warning"&&"vyre-btn--primary",o==="info"&&"vyre-btn--accent"),onClick:l,children:i})]})]})}),document.body)};it.displayName="VyreAlertDialog";const Nr=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(","),lt=n.forwardRef(({open:e,onClose:a,side:r="right",size:s="md",closeOnBackdrop:o=!0,closeOnEsc:i=!0,className:c,children:d,"aria-label":u,"aria-labelledby":h,...m},y)=>{const b=n.useRef(null),_=n.useRef(null),l=n.useCallback(v=>{if(v.key!=="Tab")return;const p=b.current;if(!p)return;const x=Array.from(p.querySelectorAll(Nr));if(!x.length)return;const N=x[0],j=x[x.length-1];v.shiftKey&&document.activeElement===N?(v.preventDefault(),j.focus()):!v.shiftKey&&document.activeElement===j&&(v.preventDefault(),N.focus())},[]);return n.useEffect(()=>{if(!e)return;if(document.addEventListener("keydown",l),i){const p=N=>{N.key==="Escape"&&a()};document.addEventListener("keydown",p);const x=document.body.style.overflow;return document.body.style.overflow="hidden",setTimeout(()=>{var N;return(N=b.current)==null?void 0:N.focus()},0),()=>{document.removeEventListener("keydown",l),document.removeEventListener("keydown",p),document.body.style.overflow=x}}const v=document.body.style.overflow;return document.body.style.overflow="hidden",setTimeout(()=>{var p;return(p=b.current)==null?void 0:p.focus()},0),()=>{document.removeEventListener("keydown",l),document.body.style.overflow=v}},[e,l,i,a]),e?F.createPortal(t.jsx("div",{ref:_,className:"vyre-sheet-backdrop",onClick:v=>{o&&v.target===_.current&&a()},role:"presentation",children:t.jsx("div",{ref:v=>{b.current=v,typeof y=="function"?y(v):y&&(y.current=v)},role:"dialog","aria-modal":"true","aria-label":u,"aria-labelledby":h,tabIndex:-1,className:f("vyre-sheet",`vyre-sheet--${r}`,`vyre-sheet--${s}`,c),...m,children:d})}),document.body):null});lt.displayName="VyreSheet";const dt=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-sheet__header",e),...r,children:a}));dt.displayName="VyreSheetHeader";const ct=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-sheet__body",e),...r,children:a}));ct.displayName="VyreSheetBody";const ut=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("div",{ref:s,className:f("vyre-sheet__footer",e),...r,children:a}));ut.displayName="VyreSheetFooter";const mt=({children:e,separator:a="/",className:r})=>{const s=n.Children.toArray(e).filter(Boolean);return t.jsx("nav",{"aria-label":"Breadcrumb",className:f("vyre-breadcrumb",r),children:t.jsx("ol",{className:"vyre-breadcrumb__list",children:s.map((o,i)=>t.jsxs("li",{className:"vyre-breadcrumb__item",children:[o,i<s.length-1&&t.jsx("span",{className:"vyre-breadcrumb__separator","aria-hidden":"true",children:a})]},i))})})};mt.displayName="VyreBreadcrumb";const vt=({children:e,href:a,current:r=!1,className:s})=>r||!a?t.jsx("span",{className:f("vyre-breadcrumb__link vyre-breadcrumb__link--current",s),"aria-current":r?"page":void 0,children:e}):t.jsx("a",{href:a,className:f("vyre-breadcrumb__link",s),children:e});vt.displayName="VyreBreadcrumbItem";const yt=({children:e,href:a,className:r})=>t.jsx("a",{href:a,className:f("vyre-breadcrumb__link",r),children:e});yt.displayName="VyreBreadcrumbLink";const ft=({children:e="/",className:a})=>t.jsx("span",{className:f("vyre-breadcrumb__separator",a),"aria-hidden":"true",children:e});ft.displayName="VyreBreadcrumbSeparator";function ce(e,a){return Array.from({length:a-e+1},(r,s)=>e+s)}function Cr(e,a,r){const s=r*2+5;if(a<=s)return ce(1,a);const o=Math.max(e-r,2),i=Math.min(e+r,a-1),c=o>2,d=i<a-1,u=[1];return c&&u.push("..."),u.push(...ce(o,i)),d&&u.push("..."),u.push(a),u}const Lr=()=>t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M9 2L4 7l5 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Rr=()=>t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M5 2l5 5-5 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Sr=()=>t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M7 2L2 7l5 5M12 2L7 7l5 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Mr=()=>t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 2l5 5-5 5M7 2l5 5-5 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),ht=({page:e,totalPages:a,onPageChange:r,siblings:s=1,showEdges:o=!0,showInfo:i=!1,totalItems:c,pageSize:d,className:u})=>{const h=Cr(e,a,s),m=e>1,y=e<a,b=n.useMemo(()=>{if(!i)return null;if(c!=null&&d!=null){const l=(e-1)*d+1,v=Math.min(e*d,c);return`Showing ${l}–${v} of ${c}`}return`Page ${e} of ${a}`},[i,e,a,c,d]),_=t.jsxs(t.Fragment,{children:[o&&t.jsx("button",{className:"vyre-pagination__nav",onClick:()=>r(1),disabled:!m,"aria-label":"First page",children:t.jsx(Sr,{})}),t.jsx("button",{className:"vyre-pagination__nav",onClick:()=>r(e-1),disabled:!m,"aria-label":"Previous page",children:t.jsx(Lr,{})}),t.jsx("ol",{className:"vyre-pagination__list",children:h.map((l,v)=>l==="..."?t.jsx("li",{children:t.jsx("span",{className:"vyre-pagination__dots","aria-hidden":"true",children:"···"})},`dots-${v}`):t.jsx("li",{children:t.jsx("button",{className:f("vyre-pagination__btn",l===e&&"vyre-pagination__btn--active"),onClick:()=>r(l),"aria-label":`Page ${l}`,"aria-current":l===e?"page":void 0,children:l})},l))}),t.jsx("button",{className:"vyre-pagination__nav",onClick:()=>r(e+1),disabled:!y,"aria-label":"Next page",children:t.jsx(Rr,{})}),o&&t.jsx("button",{className:"vyre-pagination__nav",onClick:()=>r(a),disabled:!y,"aria-label":"Last page",children:t.jsx(Mr,{})})]});return i?t.jsxs("div",{className:f("vyre-pagination-row",u),children:[t.jsx("span",{className:"vyre-pagination__info",children:b}),t.jsx("nav",{"aria-label":"Pagination",className:"vyre-pagination",children:_})]}):t.jsx("nav",{"aria-label":"Pagination",className:f("vyre-pagination",u),children:_})};ht.displayName="VyrePagination";const bt=({children:e,striped:a=!1,bordered:r=!1,compact:s=!1,hoverable:o=!0,className:i})=>t.jsx("div",{className:"vyre-table-wrapper",children:t.jsx("table",{className:f("vyre-table",a&&"vyre-table--striped",r&&"vyre-table--bordered",s&&"vyre-table--compact",o&&"vyre-table--hoverable",i),children:e})});bt.displayName="VyreTable";const xt=n.forwardRef(({className:e,...a},r)=>t.jsx("thead",{ref:r,className:f("vyre-table__head",e),...a}));xt.displayName="VyreTableHead";const pt=n.forwardRef(({className:e,...a},r)=>t.jsx("tbody",{ref:r,className:f("vyre-table__body",e),...a}));pt.displayName="VyreTableBody";const _t=n.forwardRef(({className:e,selected:a,...r},s)=>t.jsx("tr",{ref:s,className:f("vyre-table__row",a&&"vyre-table__row--selected",e),"aria-selected":a,...r}));_t.displayName="VyreTableRow";const Tr=({dir:e})=>t.jsx("span",{className:"vyre-table__sort-icon","aria-hidden":"true",children:t.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",children:[t.jsx("path",{d:"M6 2v8M3 5l3-3 3 3",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",opacity:e==="desc"?.3:1}),t.jsx("path",{d:"M3 7l3 3 3-3",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",opacity:e==="asc"?.3:1})]})}),gt=n.forwardRef(({className:e,sortable:a,sortDir:r=null,onSort:s,align:o="left",children:i,...c},d)=>a?t.jsx("th",{ref:d,className:f("vyre-table__th vyre-table__th--sortable",`vyre-table__th--${o}`,r&&`vyre-table__th--sort-${r}`,e),"aria-sort":r==="asc"?"ascending":r==="desc"?"descending":"none",...c,children:t.jsxs("button",{className:"vyre-table__sort-btn",onClick:s,type:"button",children:[i,t.jsx(Tr,{dir:r})]})}):t.jsx("th",{ref:d,className:f("vyre-table__th",`vyre-table__th--${o}`,e),...c,children:i}));gt.displayName="VyreTableHeader";const wt=n.forwardRef(({className:e,align:a="left",...r},s)=>t.jsx("td",{ref:s,className:f("vyre-table__td",`vyre-table__td--${a}`,e),...r}));wt.displayName="VyreTableCell";const jt=n.forwardRef(({className:e,...a},r)=>t.jsx("caption",{ref:r,className:f("vyre-table__caption",e),...a}));jt.displayName="VyreTableCaption";const kt=n.createContext(null),te=()=>{const e=n.useContext(kt);if(!e)throw new Error("Command components must be used inside <Command>");return e};function ae(e){return e.toLowerCase().replace(/\s+/g," ").trim()}function Er(e,a,r=[]){if(!e)return!0;const s=ae(e);return ae(a).includes(s)||r.some(o=>ae(o).includes(s))}let Ir=0;function Dr(){return`cmd-${++Ir}`}const oe=n.forwardRef(({value:e,onValueChange:a,className:r,children:s},o)=>{const[i,c]=n.useState(""),[d,u]=n.useState(0),[h,m]=n.useState(0),y=e!==void 0?e:i,b=n.useCallback(j=>{c(j),a==null||a(j),u(0)},[a]),_=n.useRef(new Map),l=n.useRef(new Map),v=n.useCallback((j,S,E)=>{_.current.set(j,{el:S,disabled:E})},[]),p=n.useCallback(j=>{_.current.delete(j),l.current.delete(j)},[]),x=n.useCallback(j=>{var S;(S=l.current.get(j))==null||S()},[]),N=n.useMemo(()=>({search:y,setSearch:b,activeIndex:d,setActiveIndex:u,items:_,registerItem:v,unregisterItem:p,selectItem:x,onSelectRef:l,visibleCount:h,setVisibleCount:m}),[y,b,d,v,p,x,h]);return t.jsx(kt.Provider,{value:N,children:t.jsx("div",{ref:o,className:f("vyre-command",r),role:"combobox","aria-expanded":"true","aria-haspopup":"listbox",children:s})})});oe.displayName="VyreCommand";const Nt=n.forwardRef(({placeholder:e="Search...",className:a},r)=>{const{search:s,setSearch:o}=te();return t.jsxs("div",{className:"vyre-command__input-wrapper",children:[t.jsx("svg",{className:"vyre-command__search-icon",width:"15",height:"15",viewBox:"0 0 15 15",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M10 6.5a3.5 3.5 0 1 1-7 0 3.5 3.5 0 0 1 7 0ZM9.5 10.207l3.146 3.147",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})}),t.jsx("input",{ref:r,className:f("vyre-command__input",a),type:"text",placeholder:e,value:s,onChange:i=>o(i.target.value),autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list","aria-controls":"vyre-command-list"}),s&&t.jsx("button",{className:"vyre-command__clear",type:"button","aria-label":"Clear search",onClick:()=>o(""),children:t.jsx("svg",{width:"13",height:"13",viewBox:"0 0 13 13",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 2l9 9M11 2l-9 9",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round"})})})]})});Nt.displayName="VyreCommandInput";const Ct=n.forwardRef(({className:e,children:a},r)=>{const{activeIndex:s,setActiveIndex:o,items:i,selectItem:c}=te(),d=n.useCallback(u=>{var m,y;const h=Array.from((i.current??new Map).entries()).filter(([,b])=>!b.disabled&&b.el.closest("[data-cmd-item]")!==null&&!b.el.hasAttribute("data-cmd-hidden"));if(u.key==="ArrowDown")u.preventDefault(),o(Math.min(s+1,h.length-1)),(m=h[Math.min(s+1,h.length-1)])==null||m[1].el.scrollIntoView({block:"nearest"});else if(u.key==="ArrowUp")u.preventDefault(),o(Math.max(s-1,0)),(y=h[Math.max(s-1,0)])==null||y[1].el.scrollIntoView({block:"nearest"});else if(u.key==="Enter"){u.preventDefault();const[b]=h[s]??[];b&&c(b)}},[s,o,i,c]);return t.jsx("div",{ref:r,id:"vyre-command-list",role:"listbox",className:f("vyre-command__list",e),onKeyDown:d,children:a})});Ct.displayName="VyreCommandList";const Lt=({className:e,children:a})=>{const{search:r,visibleCount:s}=te();return!r||s>0?null:t.jsx("div",{className:f("vyre-command__empty",e),role:"presentation",children:a??"No results found."})};Lt.displayName="VyreCommandEmpty";const Rt=({heading:e,className:a,children:r})=>t.jsxs("div",{className:f("vyre-command__group",a),role:"presentation",children:[e&&t.jsx("div",{className:"vyre-command__group-heading","aria-hidden":"true",children:e}),t.jsx("div",{role:"group","aria-label":e,children:r})]});Rt.displayName="VyreCommandGroup";const St=({onSelect:e,disabled:a=!1,keywords:r,className:s,children:o,icon:i,shortcut:c})=>{const{search:d,setActiveIndex:u,registerItem:h,unregisterItem:m,onSelectRef:y,setVisibleCount:b}=te(),_=n.useMemo(()=>Dr(),[]),l=n.useRef(null),p=Er(d,typeof o=="string"?o:"",r);return n.useEffect(()=>(b(x=>x+(p?1:0)),()=>{b(x=>x-(p?1:0))}),[p,b]),n.useEffect(()=>{const x=l.current;if(!(!x||!p))return h(_,x,a),()=>m(_)},[_,a,p,h,m]),n.useEffect(()=>{var x;return e&&((x=y.current)==null||x.set(_,e)),()=>{var N;(N=y.current)==null||N.delete(_)}},[_,e,y]),p?t.jsxs("div",{ref:l,"data-cmd-item":!0,role:"option","aria-disabled":a||void 0,className:f("vyre-command__item",a&&"vyre-command__item--disabled",s),onClick:()=>{a||e==null||e()},onMouseEnter:()=>{!a&&l.current&&u(-1)},children:[i&&t.jsx("span",{className:"vyre-command__item-icon","aria-hidden":"true",children:i}),t.jsx("span",{className:"vyre-command__item-label",children:o}),c&&t.jsx("kbd",{className:"vyre-command__item-shortcut",children:c})]}):null};St.displayName="VyreCommandItem";const Mt=({className:e})=>t.jsx("div",{className:f("vyre-command__separator",e),role:"separator","aria-hidden":"true"});Mt.displayName="VyreCommandSeparator";const Tt=({open:e,onOpenChange:a,value:r,onValueChange:s,className:o,children:i})=>{const c=n.useRef(null);return n.useEffect(()=>{var h;if(!e)return;const d=document.activeElement,u=(h=c.current)==null?void 0:h.querySelector(".vyre-command__input");return u==null||u.focus(),()=>{d==null||d.focus({preventScroll:!0})}},[e]),n.useEffect(()=>{if(!e)return;const d=u=>{u.key==="Escape"&&a(!1)};return window.addEventListener("keydown",d),()=>window.removeEventListener("keydown",d)},[e,a]),e?F.createPortal(t.jsx("div",{className:"vyre-command-backdrop",ref:c,onClick:d=>{d.target===d.currentTarget&&a(!1)},role:"dialog","aria-modal":"true","aria-label":"Command palette",children:t.jsx(oe,{value:r,onValueChange:s,className:f("vyre-command--dialog",o),children:i})}),document.body):null};Tt.displayName="VyreCommandDialog";const Et=n.forwardRef(({orientation:e="horizontal",attached:a=!1,size:r,className:s,children:o,...i},c)=>t.jsx("div",{ref:c,role:"group",className:f("vyre-btn-group",e==="vertical"&&"vyre-btn-group--vertical",a&&"vyre-btn-group--attached",s),"data-orientation":e,"data-size":r,...i,children:o}));Et.displayName="VyreButtonGroup";const ie=n.forwardRef(({variant:e="default",size:a="md",onRemove:r,onClick:s,disabled:o=!1,className:i,children:c,...d},u)=>{const h=!!s&&!o;return t.jsxs("span",{ref:u,className:f("vyre-tag",`vyre-tag--${e}`,`vyre-tag--${a}`,h&&"vyre-tag--clickable",o&&"vyre-tag--disabled",i),"data-variant":e,"data-size":a,role:h?"button":void 0,tabIndex:h?0:void 0,"aria-disabled":o||void 0,onClick:h?s:void 0,onKeyDown:h?m=>{(m.key==="Enter"||m.key===" ")&&(m.preventDefault(),s==null||s())}:void 0,...d,children:[t.jsx("span",{className:"vyre-tag__label",children:c}),r&&t.jsx("button",{type:"button",className:"vyre-tag__remove","aria-label":"Remove",disabled:o,onClick:m=>{m.stopPropagation(),r()},children:t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M9 3L3 9M3 3L9 9",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})})]})});ie.displayName="VyreTag";const It=n.forwardRef(({value:e,onChange:a,placeholder:r="Add tag…",disabled:s=!1,max:o,size:i="md",className:c,style:d,"data-testid":u},h)=>{const[m,y]=n.useState(""),b=n.useRef(null),_=o!==void 0&&e.length>=o,l=s||_;function v(j){const S=j.trim();if(!S||e.includes(S)||_){y("");return}a([...e,S]),y("")}function p(j){s||a(e.filter((S,E)=>E!==j))}function x(j){if(j.key==="Enter"||j.key===","){j.preventDefault(),v(m);return}j.key==="Backspace"&&m===""&&e.length>0&&p(e.length-1)}function N(j){const S=j.target.value;if(S.includes(",")){const E=S.split(",");E.slice(0,-1).forEach(D=>v(D)),y(E[E.length-1])}else y(S)}return t.jsxs("div",{ref:h,className:f("vyre-tags-input",`vyre-tags-input--${i}`,s&&"vyre-tags-input--disabled",c),"data-testid":u,style:d,onClick:()=>{var j;return(j=b.current)==null?void 0:j.focus()},children:[e.map((j,S)=>t.jsx(ie,{size:i,disabled:s,onRemove:s?void 0:()=>p(S),children:j},`${j}-${S}`)),t.jsx("input",{ref:b,type:"text",className:"vyre-tags-input__field",value:m,onChange:N,onKeyDown:x,placeholder:_?"":r,disabled:l,"aria-label":"Add tag"})]})});It.displayName="VyreTagsInput";const Dt=n.forwardRef(({options:e,value:a,onChange:r,placeholder:s="Search…",disabled:o=!1,size:i="md",emptyText:c="No results",className:d,...u},h)=>{const[m,y]=n.useState(!1),[b,_]=n.useState(""),[l,v]=n.useState(-1),p=n.useRef(null),x=n.useRef(null),N=n.useRef(null),S=`${n.useId()}-listbox`,E=e.find(w=>w.value===a)??null,I=e.filter(w=>w.label.toLowerCase().includes(b.toLowerCase())),D=n.useCallback(()=>{y(!1),v(-1),_("")},[]),V=n.useCallback(w=>{var L;w.disabled||(r(w.value),D(),(L=p.current)==null||L.blur())},[r,D]);n.useEffect(()=>{if(!m)return;const w=L=>{const R=N.current;R&&!R.contains(L.target)&&D()};return document.addEventListener("mousedown",w),()=>document.removeEventListener("mousedown",w)},[m,D]),n.useEffect(()=>{var L;if(!m||l<0)return;const w=(L=x.current)==null?void 0:L.children[l];w==null||w.scrollIntoView({block:"nearest"})},[l,m]),n.useEffect(()=>{v(I.length>0?0:-1)},[b]);function T(){o||(y(!0),_(""))}function B(w){_(w.target.value),m||y(!0)}function M(w){var L;switch(w.key){case"ArrowDown":{if(w.preventDefault(),!m){y(!0);return}v(R=>{let A=R+1;for(;A<I.length&&I[A].disabled;)A++;return A<I.length?A:R});break}case"ArrowUp":{if(w.preventDefault(),!m){y(!0);return}v(R=>{let A=R-1;for(;A>=0&&I[A].disabled;)A--;return A>=0?A:R});break}case"Enter":{w.preventDefault(),m&&l>=0&&I[l]&&V(I[l]);break}case"Escape":{D(),(L=p.current)==null||L.blur();break}}}const k=m?b:(E==null?void 0:E.label)??"";return t.jsxs("div",{ref:w=>{N.current=w,typeof h=="function"?h(w):h&&(h.current=w)},className:f("vyre-combobox",`vyre-combobox--${i}`,o&&"vyre-combobox--disabled",d),"data-open":m,...u,children:[t.jsx("input",{ref:p,type:"text",role:"combobox","aria-expanded":m,"aria-haspopup":"listbox","aria-controls":S,"aria-autocomplete":"list","aria-disabled":o,disabled:o,className:"vyre-combobox__input",placeholder:s,value:k,onFocus:T,onChange:B,onKeyDown:M}),t.jsx("span",{className:"vyre-combobox__chevron","aria-hidden":"true",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M3 5L7 9L11 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}),m&&t.jsx("ul",{ref:x,id:S,role:"listbox",className:"vyre-combobox__dropdown","aria-label":"Options",children:I.length>0?I.map((w,L)=>t.jsx("li",{role:"option","aria-selected":w.value===a,"aria-disabled":w.disabled,"data-highlighted":L===l,className:f("vyre-combobox__option",L===l&&"vyre-combobox__option--highlighted",w.value===a&&"vyre-combobox__option--selected"),onMouseEnter:()=>!w.disabled&&v(L),onMouseDown:R=>{R.preventDefault(),V(w)},children:w.label},w.value)):t.jsx("li",{className:"vyre-combobox__empty",role:"presentation",children:c})})]})});Dt.displayName="VyreCombobox";function Ar({col:e,sortKey:a,sortDir:r}){const o=a===e.key?r:void 0;return t.jsx("span",{className:"vyre-data-grid__sort-icon","aria-hidden":"true",children:t.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",children:[t.jsx("path",{d:"M6 2v4M3.5 4.5L6 2l2.5 2.5",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",opacity:o==="desc"?.3:1}),t.jsx("path",{d:"M6 10V6M3.5 7.5L6 10l2.5-2.5",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",opacity:o==="asc"?.3:1})]})})}const Br=5,At=n.forwardRef(({columns:e,rows:a,sortKey:r,sortDir:s,onSort:o,loading:i=!1,emptyText:c="No data",stickyHeader:d=!1,className:u,style:h,"data-testid":m},y)=>{function b(l){if(!l.sortable||!o)return;const v=r===l.key&&s==="asc"?"desc":"asc";o(l.key,v)}function _(l){return r!==l.key?"none":s==="asc"?"ascending":"descending"}return t.jsx("div",{ref:y,className:f("vyre-data-grid",d&&"vyre-data-grid--sticky-header",u),style:h,"data-testid":m,children:t.jsxs("table",{className:"vyre-data-grid__table",children:[t.jsx("thead",{className:"vyre-data-grid__thead",children:t.jsx("tr",{children:e.map(l=>t.jsx("th",{className:f("vyre-data-grid__th",l.sortable&&"vyre-data-grid__th--sortable",r===l.key&&`vyre-data-grid__th--sort-${s}`),style:l.width?{width:l.width}:void 0,"aria-sort":l.sortable?_(l):void 0,children:l.sortable?t.jsxs("button",{type:"button",className:"vyre-data-grid__sort-btn",onClick:()=>b(l),children:[l.label,t.jsx(Ar,{col:l,sortKey:r,sortDir:s})]}):l.label},l.key))})}),t.jsx("tbody",{className:"vyre-data-grid__tbody",children:i?Array.from({length:Br}).map((l,v)=>t.jsx("tr",{className:"vyre-data-grid__row vyre-data-grid__row--skeleton",children:e.map(p=>t.jsx("td",{className:"vyre-data-grid__td",children:t.jsx(se,{height:16})},p.key))},`skel-${v}`)):a.length===0?t.jsx("tr",{className:"vyre-data-grid__row vyre-data-grid__row--empty",children:t.jsx("td",{className:"vyre-data-grid__td vyre-data-grid__empty",colSpan:e.length,children:c})}):a.map((l,v)=>t.jsx("tr",{className:"vyre-data-grid__row",children:e.map(p=>t.jsx("td",{className:"vyre-data-grid__td",children:l[p.key]!=null?String(l[p.key]):""},p.key))},v))})]})})});At.displayName="VyreDataGrid";const Bt=n.forwardRef(({gap:e="md",wrap:a=!0,className:r,children:s,...o},i)=>t.jsx("div",{ref:i,className:f("vyre-tag-group",`vyre-tag-group--gap-${e}`,!a&&"vyre-tag-group--nowrap",r),role:"list",...o,children:s}));Bt.displayName="VyreTagGroup";function Y(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate())}function P(e,a){return e.getFullYear()===a.getFullYear()&&e.getMonth()===a.getMonth()&&e.getDate()===a.getDate()}function X(e,a){return Y(e)<Y(a)}function ue(e,a){return Y(e)>Y(a)}function Vr(e,a){return new Date(e,a+1,0).getDate()}function $r(e,a,r){return(new Date(e,a,1).getDay()-r+7)%7}function O(e,a){return e?new Intl.DateTimeFormat("default",{year:"numeric",month:"short",day:"numeric"}).format(e):""}function Wr(e){return`${String(e.getHours()).padStart(2,"0")}:${String(e.getMinutes()).padStart(2,"0")}`}const me=Array.from({length:12},(e,a)=>new Intl.DateTimeFormat("default",{month:"long"}).format(new Date(2e3,a,1))),z=12,le=n.forwardRef((e,a)=>{const{showTime:r=!1,minDate:s,maxDate:o,disabled:i,className:c,weekStartsOn:d=1}=e,u=Y(new Date),h=()=>{var g,C;return e.mode==="range"?((g=e.value)==null?void 0:g[0])??u:e.mode==="multiple"?((C=e.value)==null?void 0:C[0])??u:e.value??u},[m,y]=n.useState(()=>(h()??u).getFullYear()),[b,_]=n.useState(()=>(h()??u).getMonth()),[l,v]=n.useState("days"),[p,x]=n.useState(null),[N,j]=n.useState(()=>{const g=e.mode==="single"?e.value:null;return g?g.getHours():0}),[S,E]=n.useState(()=>{const g=e.mode==="single"?e.value:null;return g?g.getMinutes():0}),I=n.useMemo(()=>{const g=Vr(m,b),C=$r(m,b,d);return{count:g,offset:C}},[m,b,d]),D=n.useMemo(()=>d===1?["Mo","Tu","We","Th","Fr","Sa","Su"]:["Su","Mo","Tu","We","Th","Fr","Sa"],[d]),V=n.useCallback(g=>{if(e.mode==="single")return!!e.value&&P(g,e.value);if(e.mode==="range"){const[C,$]=e.value??[null,null];return!!C&&P(g,C)||!!$&&P(g,$)}return e.mode==="multiple"?(e.value??[]).some(C=>P(g,C)):!1},[e]),T=n.useCallback(g=>{if(e.mode!=="range")return!1;const[C,$]=e.value??[null,null],W=$??p;if(!C||!W)return!1;const K=X(C,W)?C:W,q=X(C,W)?W:C;return ue(g,K)&&X(g,q)},[e,p]),B=n.useCallback(g=>{if(e.mode!=="range")return!1;const[C]=e.value??[null,null];return!!C&&P(g,C)},[e]),M=n.useCallback(g=>{if(e.mode!=="range")return!1;const[,C]=e.value??[null,null];return!!C&&P(g,C)},[e]),k=n.useCallback(g=>!!(s&&X(g,s)||o&&ue(g,o)||i!=null&&i(g)),[s,o,i]),w=n.useCallback(g=>{var $,W,K,q,U,J;const C=new Date(m,b,g,N,S);if(!k(Y(C))){if(e.mode==="single"||!e.mode)($=e.onChange)==null||$.call(e,C);else if(e.mode==="range"){const[H,G]=e.value??[null,null];!H||H&&G?(W=e.onChange)==null||W.call(e,[C,null]):X(C,H)?(K=e.onChange)==null||K.call(e,[C,H]):(q=e.onChange)==null||q.call(e,[H,C])}else if(e.mode==="multiple"){const H=e.value??[],G=H.findIndex(de=>P(de,C));G>=0?(U=e.onChange)==null||U.call(e,H.filter((de,tr)=>tr!==G)):(J=e.onChange)==null||J.call(e,[...H,C])}}},[m,b,N,S,e,k]),L=()=>{b===0?(_(11),y(g=>g-1)):_(g=>g-1)},R=()=>{b===11?(_(0),y(g=>g+1)):_(g=>g+1)},A=(g,C)=>{var $;if(j(g),E(C),e.mode==="single"&&e.value){const W=new Date(e.value);W.setHours(g,C),($=e.onChange)==null||$.call(e,W)}},Z=Math.floor(m/z)*z;return t.jsxs("div",{ref:a,className:f("vyre-calendar",c),children:[t.jsxs("div",{className:"vyre-calendar__header",children:[l==="days"&&t.jsx("button",{className:"vyre-calendar__nav",onClick:L,"aria-label":"Previous month",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M9 11L5 7l4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}),l==="years"&&t.jsx("button",{className:"vyre-calendar__nav",onClick:()=>y(g=>g-z),"aria-label":"Previous years",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M9 11L5 7l4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}),t.jsxs("div",{className:"vyre-calendar__header-center",children:[t.jsx("button",{className:"vyre-calendar__header-btn",onClick:()=>v(l==="months"?"days":"months"),children:me[b]}),t.jsx("button",{className:"vyre-calendar__header-btn",onClick:()=>v(l==="years"?"days":"years"),children:m})]}),l==="days"&&t.jsx("button",{className:"vyre-calendar__nav",onClick:R,"aria-label":"Next month",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M5 3l4 4-4 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}),l==="years"&&t.jsx("button",{className:"vyre-calendar__nav",onClick:()=>y(g=>g+z),"aria-label":"Next years",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M5 3l4 4-4 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),l==="months"&&t.jsx("div",{className:"vyre-calendar__month-grid",children:me.map((g,C)=>t.jsx("button",{className:f("vyre-calendar__month-cell",C===b&&"vyre-calendar__month-cell--active"),onClick:()=>{_(C),v("days")},children:g.slice(0,3)},g))}),l==="years"&&t.jsx("div",{className:"vyre-calendar__year-grid",children:Array.from({length:z},(g,C)=>Z+C).map(g=>t.jsx("button",{className:f("vyre-calendar__year-cell",g===m&&"vyre-calendar__year-cell--active"),onClick:()=>{y(g),v("days")},children:g},g))}),l==="days"&&t.jsxs("div",{className:"vyre-calendar__grid",children:[D.map(g=>t.jsx("div",{className:"vyre-calendar__weekday",children:g},g)),Array.from({length:I.offset}).map((g,C)=>t.jsx("div",{},`empty-${C}`)),Array.from({length:I.count},(g,C)=>C+1).map(g=>{const C=new Date(m,b,g),$=V(C),W=T(C),K=B(C),q=M(C),U=k(C),J=P(C,u);return t.jsx("button",{className:f("vyre-calendar__day",J&&"vyre-calendar__day--today",$&&"vyre-calendar__day--selected",W&&"vyre-calendar__day--in-range",K&&"vyre-calendar__day--range-start",q&&"vyre-calendar__day--range-end",U&&"vyre-calendar__day--disabled"),onClick:()=>w(g),onMouseEnter:()=>{if(e.mode==="range"){const[H,G]=e.value??[null,null];H&&!G&&x(C)}},onMouseLeave:()=>x(null),disabled:U,"aria-selected":$,"aria-label":O(C),children:g},g)})]}),r&&l==="days"&&t.jsxs("div",{className:"vyre-calendar__time",children:[t.jsxs("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[t.jsx("circle",{cx:"7",cy:"7",r:"5.5",stroke:"currentColor",strokeWidth:"1.3"}),t.jsx("path",{d:"M7 4v3.5l2 1.5",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]}),t.jsx("input",{type:"number",className:"vyre-calendar__time-input",min:0,max:23,value:N,onChange:g=>A(Number(g.target.value),S),"aria-label":"Hours"}),t.jsx("span",{className:"vyre-calendar__time-sep",children:":"}),t.jsx("input",{type:"number",className:"vyre-calendar__time-input",min:0,max:59,value:S,onChange:g=>A(N,Number(g.target.value)),"aria-label":"Minutes"})]})]})});le.displayName="VyreCalendar";function Hr(e){if(e.mode==="range"){const[s,o]=e.value??[null,null];return s?o?`${O(s)} – ${O(o)}`:O(s):""}if(e.mode==="multiple"){const s=e.value??[];return s.length===0?"":s.length===1?O(s[0]):`${s.length} dates selected`}const a=e.value,r=e.showTime;return a?r?`${O(a)} ${Wr(a)}`:O(a):""}const Vt=n.forwardRef(({placeholder:e="Pick a date",inputClassName:a,...r},s)=>{const[o,i]=n.useState(!1),c=n.useRef(null),d=n.useRef(null),[u,h]=n.useState({top:0,left:0,width:0}),m=Hr(r),y=n.useCallback(()=>{if(!c.current)return;const l=c.current.getBoundingClientRect();h({top:l.bottom+window.scrollY+6,left:l.left+window.scrollX,width:l.width})},[]);n.useEffect(()=>{if(!o)return;y();const l=()=>y(),v=()=>y();return window.addEventListener("scroll",l,!0),window.addEventListener("resize",v),()=>{window.removeEventListener("scroll",l,!0),window.removeEventListener("resize",v)}},[o,y]),n.useEffect(()=>{if(!o)return;const l=p=>{var x,N;!((x=d.current)!=null&&x.contains(p.target))&&!((N=c.current)!=null&&N.contains(p.target))&&i(!1)},v=p=>{p.key==="Escape"&&i(!1)};return document.addEventListener("pointerdown",l),document.addEventListener("keydown",v),()=>{document.removeEventListener("pointerdown",l),document.removeEventListener("keydown",v)}},[o]);const b=r.mode!=="range"&&r.mode!=="multiple"&&!r.showTime,_=n.useMemo(()=>r.mode==="range"?{...r,onChange:l=>{var v;(v=r.onChange)==null||v.call(r,l),l[0]&&l[1]&&i(!1)}}:r.mode==="multiple"?r:{...r,onChange:l=>{var v;(v=r.onChange)==null||v.call(r,l),b&&i(!1)}},[r,b]);return t.jsxs("div",{ref:s,className:"vyre-datepicker",children:[t.jsxs("button",{ref:c,type:"button",className:f("vyre-datepicker__trigger",!m&&"vyre-datepicker__trigger--placeholder",a),onClick:()=>{y(),i(l=>!l)},"aria-expanded":o,"aria-haspopup":"dialog",children:[t.jsxs("svg",{className:"vyre-datepicker__icon",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[t.jsx("rect",{x:"1.5",y:"2.5",width:"11",height:"10",rx:"1.5",stroke:"currentColor",strokeWidth:"1.3"}),t.jsx("path",{d:"M1.5 6h11M4.5 1v3M9.5 1v3",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]}),t.jsx("span",{children:m||e}),m&&t.jsx("button",{className:"vyre-datepicker__clear",type:"button","aria-label":"Clear",onClick:l=>{var v,p,x;l.stopPropagation(),r.mode==="range"?(v=r.onChange)==null||v.call(r,[null,null]):r.mode==="multiple"?(p=r.onChange)==null||p.call(r,[]):(x=r.onChange)==null||x.call(r,null)},children:t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 2l8 8M10 2l-8 8",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round"})})})]}),o&&F.createPortal(t.jsx("div",{ref:d,className:"vyre-datepicker__popover",role:"dialog","aria-label":"Date picker",style:{top:u.top,left:u.left,minWidth:u.width},children:t.jsx(le,{..._})}),document.body)]})});Vt.displayName="VyreDatePicker";const $t=n.forwardRef(({as:e="p",size:a="md",weight:r,color:s="default",truncate:o,mono:i,className:c,children:d,...u},h)=>t.jsx(e,{ref:h,className:f("vyre-text",a!=="md"&&`vyre-text--${a}`,r&&`vyre-text--${r}`,s!=="default"&&`vyre-text--${s}`,o&&"vyre-text--truncate",i&&"vyre-text--mono",c),...u,children:d}));$t.displayName="VyreText";const Wt=n.forwardRef(({as:e="h2",size:a="md",weight:r="bold",color:s="default",truncate:o,className:i,children:c,...d},u)=>t.jsx(e,{ref:u,className:f("vyre-heading",`vyre-heading--${a}`,r!=="bold"&&`vyre-heading--${r}`,s!=="default"&&`vyre-text--${s}`,o&&"vyre-text--truncate",i),...d,children:c}));Wt.displayName="VyreHeading";const Ht=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("p",{ref:s,className:f("vyre-lead",e),...r,children:a}));Ht.displayName="VyreLead";const Ft=n.forwardRef(({block:e,className:a,children:r,...s},o)=>e?t.jsx("pre",{className:f("vyre-code-block",a),...s,children:t.jsx("code",{ref:o,children:r})}):t.jsx("code",{ref:o,className:f("vyre-code",a),...s,children:r}));Ft.displayName="VyreCode";const Pt=n.forwardRef(({className:e,children:a,...r},s)=>t.jsx("blockquote",{ref:s,className:f("vyre-blockquote",e),...r,children:a}));Pt.displayName="VyreBlockquote";const Ot=n.createContext({collapsed:!1,toggleCollapsed:()=>{}}),re=()=>n.useContext(Ot),Kt=n.forwardRef(({defaultCollapsed:e=!1,collapsed:a,onCollapsedChange:r,className:s,children:o},i)=>{const[c,d]=n.useState(e),u=a!==void 0?a:c,h=n.useCallback(()=>{const m=!u;d(m),r==null||r(m)},[u,r]);return t.jsx(Ot.Provider,{value:{collapsed:u,toggleCollapsed:h},children:t.jsx("div",{ref:i,className:f("vyre-app-layout",s),children:o})})});Kt.displayName="VyreAppLayout";const qt=n.forwardRef(({variant:e="default",className:a,children:r},s)=>{const{collapsed:o}=re();return t.jsx("aside",{ref:s,className:f("vyre-sidebar",o&&"vyre-sidebar--collapsed",e==="floating"&&"vyre-sidebar--floating",a),"data-collapsed":o||void 0,children:r})});qt.displayName="VyreSidebar";const Gt=n.forwardRef(({logo:e,title:a,className:r,children:s},o)=>t.jsxs("div",{ref:o,className:f("vyre-sidebar__header",r),children:[e&&t.jsx("span",{className:"vyre-sidebar__logo",children:e}),a&&t.jsx("span",{className:"vyre-sidebar__title",children:a}),s]}));Gt.displayName="VyreSidebarHeader";const Yt=n.forwardRef(({className:e,children:a},r)=>t.jsx("div",{ref:r,className:f("vyre-sidebar__content",e),children:a}));Yt.displayName="VyreSidebarContent";const Ut=n.forwardRef(({label:e,className:a,children:r},s)=>t.jsxs("div",{ref:s,className:f("vyre-sidebar__section",a),children:[e&&t.jsx("div",{className:"vyre-sidebar__section-label",children:e}),r]}));Ut.displayName="VyreSidebarSection";const Xt=({active:e,icon:a,badge:r,href:s,onClick:o,className:i,children:c})=>{const{collapsed:d}=re(),u=f("vyre-sidebar__item",e&&"vyre-sidebar__item--active",i),h=t.jsxs(t.Fragment,{children:[a&&t.jsx("span",{className:"vyre-sidebar__item-icon",children:a}),t.jsx("span",{className:"vyre-sidebar__item-label",children:c}),r!==void 0&&t.jsx("span",{className:"vyre-sidebar__item-badge",children:r})]});return s?t.jsx("a",{href:s,className:u,"aria-current":e?"page":void 0,title:d?String(c):void 0,children:h}):t.jsx("button",{type:"button",className:u,onClick:o,"aria-pressed":e,title:d?String(c):void 0,children:h})};Xt.displayName="VyreSidebarItem";const zt=n.forwardRef(({className:e,children:a},r)=>t.jsx("div",{ref:r,className:f("vyre-sidebar__footer",e),children:a}));zt.displayName="VyreSidebarFooter";const Zt=n.forwardRef(({className:e,children:a},r)=>t.jsx("div",{ref:r,className:f("vyre-app-shell",e),children:a}));Zt.displayName="VyreAppShell";const Jt=n.forwardRef(({className:e,children:a},r)=>t.jsx("header",{ref:r,className:f("vyre-app-bar",e),children:a}));Jt.displayName="VyreAppBar";const Qt=({className:e})=>{const{collapsed:a,toggleCollapsed:r}=re();return t.jsx("button",{type:"button",className:f("vyre-sidebar-trigger",e),onClick:r,"aria-label":a?"Expand sidebar":"Collapse sidebar","aria-expanded":!a,children:t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("rect",{x:"2",y:"4",width:"12",height:"1.5",rx:"0.75",fill:"currentColor"}),t.jsx("rect",{x:"2",y:"7.25",width:"8",height:"1.5",rx:"0.75",fill:"currentColor"}),t.jsx("rect",{x:"2",y:"10.5",width:"12",height:"1.5",rx:"0.75",fill:"currentColor"})]})})};Qt.displayName="VyreSidebarTrigger";const er=n.forwardRef(({className:e,children:a},r)=>t.jsx("div",{ref:r,className:f("vyre-page-content",e),children:a}));er.displayName="VyrePageContent";exports.Accordion=$e;exports.AccordionContent=Fe;exports.AccordionItem=We;exports.AccordionTrigger=He;exports.Alert=ot;exports.AlertDialog=it;exports.AppBar=Jt;exports.AppLayout=Kt;exports.AppShell=Zt;exports.Avatar=Pe;exports.Badge=ye;exports.Blockquote=Pt;exports.Breadcrumb=mt;exports.BreadcrumbItem=vt;exports.BreadcrumbLink=yt;exports.BreadcrumbSeparator=ft;exports.Button=ve;exports.ButtonGroup=Et;exports.Calendar=le;exports.Card=fe;exports.CardBody=be;exports.CardFooter=xe;exports.CardHeader=he;exports.Checkbox=Oe;exports.Code=Ft;exports.Combobox=Dt;exports.Command=oe;exports.CommandDialog=Tt;exports.CommandEmpty=Lt;exports.CommandGroup=Rt;exports.CommandInput=Nt;exports.CommandItem=St;exports.CommandList=Ct;exports.CommandSeparator=Mt;exports.DataGrid=At;exports.DatePicker=Vt;exports.DropdownCheckboxItem=et;exports.DropdownItem=Qe;exports.DropdownLabel=Je;exports.DropdownMenu=Ze;exports.DropdownRadioGroup=tt;exports.DropdownRadioItem=rt;exports.DropdownSeparator=nt;exports.DropdownSub=at;exports.Field=pe;exports.Heading=Wt;exports.Input=_e;exports.Label=Ue;exports.Lead=Ht;exports.Modal=we;exports.ModalBody=ke;exports.ModalFooter=Ne;exports.ModalHeader=je;exports.PageContent=er;exports.Pagination=ht;exports.Popover=Xe;exports.Progress=Ge;exports.Select=Le;exports.Separator=Ye;exports.Sheet=lt;exports.SheetBody=ct;exports.SheetFooter=ut;exports.SheetHeader=dt;exports.Sidebar=qt;exports.SidebarContent=Yt;exports.SidebarFooter=zt;exports.SidebarHeader=Gt;exports.SidebarItem=Xt;exports.SidebarSection=Ut;exports.SidebarTrigger=Qt;exports.Skeleton=se;exports.Slider=qe;exports.Switch=Ke;exports.Tab=Ee;exports.TabList=Te;exports.TabPanel=De;exports.TabPanels=Ie;exports.Table=bt;exports.TableBody=pt;exports.TableCaption=jt;exports.TableCell=wt;exports.TableHead=xt;exports.TableHeader=gt;exports.TableRow=_t;exports.Tabs=Me;exports.Tag=ie;exports.TagGroup=Bt;exports.TagsInput=It;exports.Text=$t;exports.Textarea=ge;exports.ToastProvider=dr;exports.Tooltip=Ae;exports.cn=f;exports.useAppLayout=re;exports.useToast=cr;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),s=require("react"),P=require("react-dom");function v(...e){const r=[];for(const a of e)if(a){if(typeof a=="string")r.push(a);else if(Array.isArray(a)){const n=v(...a);n&&r.push(n)}else if(typeof a=="object")for(const[n,o]of Object.entries(a))o&&r.push(n)}return r.join(" ")}const Lr={primary:"vyre-btn--primary",secondary:"vyre-btn--secondary",ghost:"vyre-btn--ghost",accent:"vyre-btn--accent",teal:"vyre-btn--teal",danger:"vyre-btn--danger"},Dr={sm:"vyre-btn--sm",md:"vyre-btn--md",lg:"vyre-btn--lg",icon:"vyre-btn--icon"},we=s.forwardRef(({variant:e="secondary",size:r="md",loading:a=!1,disabled:n,leftIcon:o,rightIcon:i,className:l,children:c,as:d="button",...h},f)=>{const y=n||a;return t.jsxs(d,{ref:f,className:v("vyre-btn",Lr[e],Dr[r],a&&"vyre-btn--loading",l),disabled:d==="button"?y:void 0,"aria-disabled":y,"data-variant":e,"data-size":r,...h,children:[a&&t.jsx("span",{className:"vyre-btn__spinner","aria-hidden":"true",children:t.jsx(Sr,{})}),!a&&o&&t.jsx("span",{className:"vyre-btn__icon vyre-btn__icon--left","aria-hidden":"true",children:o}),c&&t.jsx("span",{className:"vyre-btn__label",children:c}),i&&t.jsx("span",{className:"vyre-btn__icon vyre-btn__icon--right","aria-hidden":"true",children:i})]})});we.displayName="VyreButton";function Sr(){return t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"vyre-spinner","aria-hidden":"true",children:t.jsx("circle",{cx:"7",cy:"7",r:"5.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeDasharray:"28",strokeDashoffset:"10"})})}const ke=s.forwardRef(({variant:e="default",dot:r=!1,className:a,children:n,...o},i)=>t.jsxs("span",{ref:i,className:v("vyre-badge",`vyre-badge--${e}`,a),"data-variant":e,...o,children:[r&&t.jsx("span",{className:"vyre-badge__dot","aria-hidden":"true"}),n]}));ke.displayName="VyreBadge";const de=s.forwardRef(({variant:e="default",hoverable:r=!1,clickable:a=!1,className:n,children:o,...i},l)=>t.jsx("div",{ref:l,className:v("vyre-card",`vyre-card--${e}`,r&&"vyre-card--hoverable",a&&"vyre-card--clickable",n),"data-variant":e,role:a?"button":void 0,tabIndex:a?0:void 0,...i,children:o}));de.displayName="VyreCard";const Ne=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-card__header",e),...a,children:r}));Ne.displayName="VyreCardHeader";const ue=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-card__body",e),...a,children:r}));ue.displayName="VyreCardBody";const Ce=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-card__footer",e),...a,children:r}));Ce.displayName="VyreCardFooter";const Re=s.forwardRef(({label:e,hint:r,state:a="idle",required:n=!1,htmlFor:o,className:i,children:l,...c},d)=>t.jsxs("div",{ref:d,className:v("vyre-field",a!=="idle"&&`vyre-field--${a}`,i),"data-state":a,...c,children:[e&&t.jsxs("label",{className:"vyre-field__label",htmlFor:o,children:[e,n&&t.jsx("span",{className:"vyre-field__required","aria-label":"required",children:"*"})]}),l,r&&t.jsx("span",{className:"vyre-field__hint",role:a==="error"?"alert":void 0,children:r})]}));Re.displayName="VyreField";const Le=s.forwardRef(({required:e=!1,className:r,children:a,...n},o)=>t.jsxs("label",{ref:o,className:v("vyre-field__label",r),...n,children:[a,e&&t.jsx("span",{className:"vyre-field__required","aria-label":"required",children:"*"})]}));Le.displayName="VyreFieldLabel";const De=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("p",{ref:n,className:v("vyre-field__description",e),...a,children:r}));De.displayName="VyreFieldDescription";const Se=s.forwardRef(({className:e,children:r,...a},n)=>r?t.jsx("p",{ref:n,role:"alert",className:v("vyre-field__error",e),...a,children:r}):null);Se.displayName="VyreFieldError";const Me=s.forwardRef(({orientation:e="vertical",className:r,children:a,...n},o)=>t.jsx("div",{ref:o,className:v("vyre-field-group",`vyre-field-group--${e}`,r),...n,children:a}));Me.displayName="VyreFieldGroup";const Ie=s.forwardRef(({legend:e,className:r,children:a,...n},o)=>t.jsxs("fieldset",{ref:o,className:v("vyre-field-set",r),...n,children:[e&&t.jsx("legend",{className:"vyre-field-set__legend",children:e}),a]}));Ie.displayName="VyreFieldSet";const Te=s.forwardRef(({size:e="md",leftElement:r,rightElement:a,className:n,...o},i)=>r||a?t.jsxs("div",{className:v("vyre-input-wrapper",`vyre-input-wrapper--${e}`),children:[r&&t.jsx("span",{className:"vyre-input__element vyre-input__element--left","aria-hidden":"true",children:r}),t.jsx("input",{ref:i,className:v("vyre-input",`vyre-input--${e}`,!!r&&"vyre-input--has-left",!!a&&"vyre-input--has-right",n),...o}),a&&t.jsx("span",{className:"vyre-input__element vyre-input__element--right","aria-hidden":"true",children:a})]}):t.jsx("input",{ref:i,className:v("vyre-input",`vyre-input--${e}`,n),...o}));Te.displayName="VyreInput";const Ee=s.forwardRef(({size:e="md",resize:r="vertical",className:a,style:n,...o},i)=>t.jsx("textarea",{ref:i,className:v("vyre-textarea",`vyre-textarea--${e}`,a),style:{resize:r,...n},...o}));Ee.displayName="VyreTextarea";const Mr=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(","),Ae=s.forwardRef(({open:e,onClose:r,size:a="md",closeOnBackdrop:n=!0,closeOnEsc:o=!0,initialFocus:i,className:l,children:c,"aria-label":d,"aria-labelledby":h,...f},y)=>{const p=s.useRef(null),x=s.useRef(null),u=s.useCallback(g=>{p.current=g,typeof y=="function"?y(g):y&&(y.current=g)},[y]),m=s.useCallback(g=>{if(g.key!=="Tab")return;const N=p.current;if(!N)return;const b=Array.from(N.querySelectorAll(Mr));if(!b.length)return;const L=b[0],w=b[b.length-1];g.shiftKey&&document.activeElement===L?(g.preventDefault(),w.focus()):!g.shiftKey&&document.activeElement===w&&(g.preventDefault(),L.focus())},[]),_=s.useCallback(g=>{g.key==="Escape"&&o&&r()},[o,r]);return s.useEffect(()=>{if(!e)return;document.addEventListener("keydown",_),document.addEventListener("keydown",m);const g=document.body.style.overflow;document.body.style.overflow="hidden";const N=setTimeout(()=>{var b;i!=null&&i.current?i.current.focus():(b=p.current)==null||b.focus()},0);return()=>{document.removeEventListener("keydown",_),document.removeEventListener("keydown",m),document.body.style.overflow=g,clearTimeout(N)}},[e,_,m,i]),e?P.createPortal(t.jsx("div",{ref:x,className:"vyre-modal-backdrop",onClick:g=>{n&&g.target===x.current&&r()},role:"presentation",children:t.jsx("div",{ref:u,className:v("vyre-modal",`vyre-modal--${a}`,l),role:"dialog","aria-modal":"true","aria-label":d,"aria-labelledby":h,tabIndex:-1,...f,children:c})}),document.body):null});Ae.displayName="VyreModal";const Be=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-modal__header",e),...a,children:r}));Be.displayName="VyreModalHeader";const Ve=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-modal__body",e),...a,children:r}));Ve.displayName="VyreModalBody";const $e=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-modal__footer",e),...a,children:r}));$e.displayName="VyreModalFooter";const Fe=s.createContext(null);function Ir(e,r){switch(r.type){case"ADD":return[...e,r.payload];case"REMOVE":return e.filter(a=>a.id!==r.id);default:return e}}let Tr=0;const Er=()=>`vyre-t-${++Tr}`;function Ar({children:e}){const[r,a]=s.useReducer(Ir,[]),n=s.useCallback(i=>{const l=Er();return a({type:"ADD",payload:{...i,id:l}}),l},[]),o=s.useCallback(i=>{a({type:"REMOVE",id:i})},[]);return t.jsxs(Fe.Provider,{value:{toast:n,dismiss:o},children:[e,typeof document<"u"&&P.createPortal(t.jsx("div",{className:"vyre-toast-viewport","aria-live":"polite","aria-atomic":"false","aria-label":"Notifications",children:r.map(i=>t.jsx(Vr,{...i,onDismiss:()=>o(i.id)},i.id))}),document.body)]})}function Br(){const e=s.useContext(Fe);if(!e)throw new Error("useToast must be used inside <ToastProvider>");return e}function Vr({title:e,description:r,variant:a="default",duration:n=4e3,onDismiss:o}){return s.useEffect(()=>{if(n===1/0)return;const i=setTimeout(o,n);return()=>clearTimeout(i)},[n,o]),t.jsxs("div",{className:v("vyre-toast",`vyre-toast--${a}`),role:"alert","data-variant":a,children:[t.jsxs("div",{className:"vyre-toast__content",children:[e&&t.jsx("p",{className:"vyre-toast__title",children:e}),r&&t.jsx("p",{className:"vyre-toast__description",children:r})]}),t.jsx("button",{className:"vyre-toast__close",onClick:o,"aria-label":"Dismiss notification",type:"button",children:t.jsx($r,{})})]})}function $r(){return t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M10.5 3.5L3.5 10.5M3.5 3.5L10.5 10.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}const We=s.forwardRef(({options:e,value:r,defaultValue:a,onChange:n,placeholder:o="Select an option",disabled:i=!1,size:l="md",className:c,...d},h)=>{const f=r!==void 0,[y,p]=s.useState(a??""),x=f?r:y,[u,m]=s.useState(!1),[_,g]=s.useState(-1),N=s.useRef(null),b=s.useRef(null),w=`${s.useId()}-listbox`,I=e.find(j=>j.value===x),A=e.filter(j=>!j.disabled),T=s.useCallback(()=>{m(!1),g(-1)},[]),M=s.useCallback(j=>{var k;j.disabled||(f||p(j.value),n==null||n(j.value),T(),(k=N.current)==null||k.focus())},[f,n,T]);s.useEffect(()=>{if(!u)return;const j=k=>{const D=h==null?void 0:h.current;D&&!D.contains(k.target)&&T()};return document.addEventListener("mousedown",j),()=>document.removeEventListener("mousedown",j)},[u,h,T]),s.useEffect(()=>{var k;if(!u||_<0)return;const j=(k=b.current)==null?void 0:k.children[_];j==null||j.scrollIntoView({block:"nearest"})},[_,u]);const B=j=>{switch(j.key){case"Enter":case" ":case"ArrowDown":{if(j.preventDefault(),!u){m(!0);const k=e.findIndex(D=>D.value===x);g(k>=0?k:0)}break}case"ArrowUp":{j.preventDefault(),u||(m(!0),g(e.length-1));break}case"Escape":{T();break}}},R=j=>{var k;switch(j.key){case"ArrowDown":{j.preventDefault(),g(D=>{let E=D+1;for(;E<e.length&&e[E].disabled;)E++;return E<e.length?E:D});break}case"ArrowUp":{j.preventDefault(),g(D=>{let E=D-1;for(;E>=0&&e[E].disabled;)E--;return E>=0?E:D});break}case"Enter":case" ":{j.preventDefault(),_>=0&&M(e[_]);break}case"Escape":case"Tab":{T(),(k=N.current)==null||k.focus();break}case"Home":{j.preventDefault();const D=e.findIndex(E=>!E.disabled);D>=0&&g(D);break}case"End":{j.preventDefault();const D=[...e].reverse().findIndex(E=>!E.disabled);D>=0&&g(e.length-1-D);break}}};return t.jsxs("div",{ref:h,className:v("vyre-select",`vyre-select--${l}`,c),"data-open":u,...d,children:[t.jsxs("button",{ref:N,type:"button",className:"vyre-select__trigger","aria-haspopup":"listbox","aria-expanded":u,"aria-controls":w,"aria-disabled":i,disabled:i,onClick:()=>{i||m(j=>{if(!j){const k=e.findIndex(D=>D.value===x);g(k>=0?k:0)}return!j})},onKeyDown:B,children:[I?t.jsx("span",{className:"vyre-select__value",children:I.label}):t.jsx("span",{className:"vyre-select__placeholder",children:o}),t.jsx(Fr,{})]}),u&&t.jsxs("ul",{ref:b,id:w,role:"listbox",className:"vyre-select__dropdown","aria-label":"Options",tabIndex:-1,onKeyDown:R,children:[e.map((j,k)=>t.jsxs("li",{role:"option","aria-selected":j.value===x,"aria-disabled":j.disabled,"data-highlighted":k===_,className:"vyre-select__option",onMouseEnter:()=>!j.disabled&&g(k),onMouseDown:D=>{D.preventDefault(),M(j)},children:[j.label,j.value===x&&t.jsx(Wr,{})]},j.value)),A.length===0&&t.jsx("li",{className:"vyre-select__empty",role:"presentation",children:"No options available"})]})]})});We.displayName="VyreSelect";function Fr(){return t.jsx("svg",{className:"vyre-select__chevron",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M3 5L7 9L11 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}function Wr(){return t.jsx("svg",{className:"vyre-select__check",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2.5 7L5.5 10L11.5 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}const He=s.createContext(null);function Pe(){const e=s.useContext(He);if(!e)throw new Error("Tab components must be used inside <Tabs>");return e}const Oe=s.forwardRef(({defaultValue:e="",value:r,onChange:a,className:n,children:o,...i},l)=>{const c=r!==void 0,[d,h]=s.useState(e),f=c?r:d,y=s.useId(),p=s.useCallback(x=>{c||h(x),a==null||a(x)},[c,a]);return t.jsx(He.Provider,{value:{value:f,onChange:p,baseId:y},children:t.jsx("div",{ref:l,className:v("vyre-tabs",n),...i,children:o})})});Oe.displayName="VyreTabs";const Ge=s.forwardRef(({className:e,children:r,"aria-label":a,...n},o)=>{const i=s.useRef(null),l=c=>{var y;const d=Array.from(((y=i.current)==null?void 0:y.querySelectorAll('[role="tab"]:not([disabled])'))??[]),h=d.findIndex(p=>p===document.activeElement);if(h<0)return;let f=h;if(c.key==="ArrowRight")f=(h+1)%d.length;else if(c.key==="ArrowLeft")f=(h-1+d.length)%d.length;else if(c.key==="Home")f=0;else if(c.key==="End")f=d.length-1;else return;c.preventDefault(),d[f].focus(),d[f].click()};return t.jsx("div",{ref:c=>{i.current=c,typeof o=="function"?o(c):o&&(o.current=c)},role:"tablist",className:v("vyre-tabs__list",e),"aria-label":a,onKeyDown:l,...n,children:r})});Ge.displayName="VyreTabList";const Ye=s.forwardRef(({value:e,disabled:r=!1,className:a,children:n,...o},i)=>{const{value:l,onChange:c,baseId:d}=Pe(),h=e===l;return t.jsx("button",{ref:i,role:"tab",type:"button",id:`${d}-tab-${e}`,"aria-controls":`${d}-panel-${e}`,"aria-selected":h,disabled:r,tabIndex:h?0:-1,className:v("vyre-tabs__tab",h&&"vyre-tabs__tab--active",a),"data-selected":h,onClick:()=>!r&&c(e),...o,children:n})});Ye.displayName="VyreTab";const Ke=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-tabs__panels",e),...a,children:r}));Ke.displayName="VyreTabPanels";const qe=s.forwardRef(({value:e,className:r,children:a,...n},o)=>{const{value:i,baseId:l}=Pe();return e===i?t.jsx("div",{ref:o,role:"tabpanel",id:`${l}-panel-${e}`,"aria-labelledby":`${l}-tab-${e}`,tabIndex:0,className:v("vyre-tabs__panel",r),...n,children:a}):null});qe.displayName="VyreTabPanel";const Hr=120,Ue=({content:e,placement:r="top",delay:a=300,children:n,className:o})=>{const[i,l]=s.useState("hidden"),c=s.useRef(null),d=s.useRef(null),h=s.useId(),f=s.useCallback(()=>{d.current&&(clearTimeout(d.current),d.current=null),c.current=setTimeout(()=>l("visible"),a)},[a]),y=s.useCallback(()=>{c.current&&(clearTimeout(c.current),c.current=null),l("leaving"),d.current=setTimeout(()=>l("hidden"),Hr)},[]),p=s.Children.only(n),x=s.cloneElement(p,{onMouseEnter:u=>{var m,_;f(),(_=(m=p.props).onMouseEnter)==null||_.call(m,u)},onMouseLeave:u=>{var m,_;y(),(_=(m=p.props).onMouseLeave)==null||_.call(m,u)},onFocus:u=>{var m,_;l("visible"),(_=(m=p.props).onFocus)==null||_.call(m,u)},onBlur:u=>{var m,_;y(),(_=(m=p.props).onBlur)==null||_.call(m,u)},"aria-describedby":i!=="hidden"?h:void 0});return t.jsxs("span",{className:v("vyre-tooltip-wrapper",o),children:[x,i!=="hidden"&&t.jsxs("span",{id:h,role:"tooltip",className:v("vyre-tooltip",`vyre-tooltip--${r}`,i==="leaving"&&"vyre-tooltip--leaving"),"data-placement":r,children:[e,t.jsx("span",{className:"vyre-tooltip__arrow","aria-hidden":"true"})]})]})};Ue.displayName="VyreTooltip";const ze=s.createContext(null);function Xe(){const e=s.useContext(ze);if(!e)throw new Error("AccordionItem must be used within Accordion");return e}const Ze=s.forwardRef(({type:e="single",defaultValue:r,value:a,onValueChange:n,className:o,children:i,...l},c)=>{const d=x=>x===void 0?[]:Array.isArray(x)?x:[x],[h,f]=s.useState(d(r)),y=a!==void 0?d(a):h,p=s.useCallback(x=>{let u;e==="single"?u=y.includes(x)?[]:[x]:u=y.includes(x)?y.filter(m=>m!==x):[...y,x],a===void 0&&f(u),n==null||n(e==="single"?u[0]??"":u)},[e,y,a,n]);return t.jsx(ze.Provider,{value:{type:e,value:y,toggle:p},children:t.jsx("div",{ref:c,className:["vyre-accordion",o].filter(Boolean).join(" "),...l,children:i})})});Ze.displayName="Accordion";const me=s.createContext(null),Qe=s.forwardRef(({value:e,className:r,children:a,...n},o)=>{const{value:i}=Xe(),l=i.includes(e);return t.jsx(me.Provider,{value:{itemValue:e,isOpen:l},children:t.jsx("div",{ref:o,"data-state":l?"open":"closed",className:["vyre-accordion__item",r].filter(Boolean).join(" "),...n,children:a})})});Qe.displayName="AccordionItem";const Je=s.forwardRef(({className:e,children:r,...a},n)=>{const{toggle:o}=Xe(),i=s.useContext(me);if(!i)throw new Error("AccordionTrigger must be used within AccordionItem");const{itemValue:l,isOpen:c}=i;return t.jsxs("button",{ref:n,type:"button","aria-expanded":c,"data-state":c?"open":"closed",className:["vyre-accordion__trigger",e].filter(Boolean).join(" "),onClick:()=>o(l),...a,children:[t.jsx("span",{className:"vyre-accordion__trigger-text",children:r}),t.jsx("svg",{className:"vyre-accordion__chevron",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M4 6l4 4 4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})]})});Je.displayName="AccordionTrigger";const et=s.forwardRef(({className:e,children:r,...a},n)=>{const o=s.useContext(me);if(!o)throw new Error("AccordionContent must be used within AccordionItem");const{isOpen:i}=o;return t.jsx("div",{ref:n,hidden:!i,"data-state":i?"open":"closed",className:["vyre-accordion__content",e].filter(Boolean).join(" "),...a,children:t.jsx("div",{className:"vyre-accordion__content-inner",children:r})})});et.displayName="AccordionContent";const ve=s.forwardRef(({src:e,alt:r="",fallback:a,size:n="md",status:o,className:i,...l},c)=>{var y;const[d,h]=s.useState(!1),f=e&&!d;return t.jsxs("span",{ref:c,"data-size":n,className:["vyre-avatar",i].filter(Boolean).join(" "),...l,children:[f?t.jsx("img",{src:e,alt:r,className:"vyre-avatar__img",onError:()=>h(!0)}):t.jsx("span",{className:"vyre-avatar__fallback","aria-label":r||a,children:a??((y=r==null?void 0:r.charAt(0))==null?void 0:y.toUpperCase())??"?"}),o&&t.jsx("span",{className:`vyre-avatar__status vyre-avatar__status--${o}`,"aria-label":o})]})});ve.displayName="Avatar";const tt=s.forwardRef(({checked:e,defaultChecked:r,indeterminate:a=!1,onCheckedChange:n,disabled:o,size:i="md",className:l,id:c,...d},h)=>{const f=s.useRef(null),y=h??f;return s.useEffect(()=>{y.current&&(y.current.indeterminate=a)},[a,y]),t.jsxs("span",{className:["vyre-checkbox",`vyre-checkbox--${i}`,l].filter(Boolean).join(" "),"data-disabled":o||void 0,"data-checked":e||void 0,"data-indeterminate":a||void 0,children:[t.jsx("input",{ref:y,type:"checkbox",id:c,checked:e,defaultChecked:r,disabled:o,className:"vyre-checkbox__input",onChange:p=>n==null?void 0:n(p.target.checked),...d}),t.jsx("span",{className:"vyre-checkbox__box","aria-hidden":"true",children:a?t.jsx("svg",{width:"10",height:"2",viewBox:"0 0 10 2",fill:"none",children:t.jsx("path",{d:"M1 1h8",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})}):t.jsx("svg",{width:"10",height:"8",viewBox:"0 0 10 8",fill:"none",children:t.jsx("path",{d:"M1 4l3 3 5-6",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"})})})]})});tt.displayName="Checkbox";const rt=s.createContext(null);let Pr=0;const at=s.forwardRef(({value:e,defaultValue:r,onChange:a,name:n,disabled:o=!1,size:i="md",orientation:l="vertical",options:c,className:d,children:h,...f},y)=>{const[p,x]=s.useState(r),u=e!==void 0,m=u?e:p,_=s.useMemo(()=>n??`vyre-radio-${++Pr}`,[n]),g=s.useCallback(b=>{u||x(b),a==null||a(b)},[u,a]),N={name:_,value:m,onChange:g,groupDisabled:o,size:i};return t.jsx(rt.Provider,{value:N,children:t.jsx("div",{ref:y,role:"radiogroup","aria-orientation":l,className:v("vyre-radio-group",`vyre-radio-group--${l}`,d),"data-disabled":o||void 0,...f,children:c?c.map(b=>t.jsx(fe,{value:b.value,label:b.label,description:b.description,disabled:b.disabled},b.value)):h})})});at.displayName="VyreRadioGroup";const fe=s.forwardRef(({value:e,label:r,description:a,disabled:n,className:o,id:i,...l},c)=>{const d=s.useContext(rt);if(!d)throw new Error("Radio must be used inside a <RadioGroup>.");const h=d.value===e,f=n||d.groupDisabled,y=i??`${d.name}-${e}`.replace(/\s+/g,"-");return t.jsxs("label",{className:v("vyre-radio",`vyre-radio--${d.size}`,f&&"vyre-radio--disabled",o),"data-checked":h||void 0,"data-disabled":f||void 0,htmlFor:y,children:[t.jsx("input",{ref:c,type:"radio",id:y,name:d.name,value:e,checked:h,disabled:f,className:"vyre-radio__input",onChange:()=>{var p;return(p=d.onChange)==null?void 0:p.call(d,e)},...l}),t.jsx("span",{className:"vyre-radio__control","aria-hidden":"true",children:t.jsx("span",{className:"vyre-radio__dot"})}),(r||a)&&t.jsxs("span",{className:"vyre-radio__content",children:[r&&t.jsx("span",{className:"vyre-radio__label",children:r}),a&&t.jsx("span",{className:"vyre-radio__description",children:a})]})]})});fe.displayName="VyreRadio";const Or=["bold","italic","underline","strike","h1","h2","h3","ul","ol","quote","code","link","clear"];function W(e,r){document.execCommand(e,!1,r)}const nt=s.forwardRef(({value:e,onChange:r,placeholder:a="Write something…",disabled:n=!1,readOnly:o=!1,toolbar:i=Or,minHeight:l="10rem",className:c,...d},h)=>{const f=s.useRef(null),y=!n&&!o;s.useEffect(()=>{const m=f.current;m&&m.innerHTML!==e&&(m.innerHTML=e)},[e]);const p=s.useCallback(()=>{f.current&&r(f.current.innerHTML)},[r]),x=s.useCallback(m=>{var _;y&&((_=f.current)==null||_.focus(),m(),p())},[y,p]),u={bold:{label:"Bold",icon:t.jsx("b",{children:"B"}),run:()=>W("bold")},italic:{label:"Italic",icon:t.jsx("i",{children:"I"}),run:()=>W("italic")},underline:{label:"Underline",icon:t.jsx("u",{children:"U"}),run:()=>W("underline")},strike:{label:"Strikethrough",icon:t.jsx("s",{children:"S"}),run:()=>W("strikeThrough")},h1:{label:"Heading 1",icon:t.jsx(t.Fragment,{children:"H1"}),run:()=>W("formatBlock","<h1>")},h2:{label:"Heading 2",icon:t.jsx(t.Fragment,{children:"H2"}),run:()=>W("formatBlock","<h2>")},h3:{label:"Heading 3",icon:t.jsx(t.Fragment,{children:"H3"}),run:()=>W("formatBlock","<h3>")},ul:{label:"Bullet list",icon:t.jsx(t.Fragment,{children:"•≡"}),run:()=>W("insertUnorderedList")},ol:{label:"Numbered list",icon:t.jsx(t.Fragment,{children:"1.≡"}),run:()=>W("insertOrderedList")},quote:{label:"Quote",icon:t.jsx(t.Fragment,{children:"“”"}),run:()=>W("formatBlock","<blockquote>")},code:{label:"Code block",icon:t.jsx(t.Fragment,{children:"</>"}),run:()=>W("formatBlock","<pre>")},link:{label:"Link",icon:t.jsx(t.Fragment,{children:"🔗"}),run:()=>{const m=window.prompt("Link URL");m&&W("createLink",m)}},clear:{label:"Clear formatting",icon:t.jsx(t.Fragment,{children:"⌫"}),run:()=>W("removeFormat")}};return t.jsxs("div",{ref:h,className:v("vyre-rte",n&&"vyre-rte--disabled",o&&"vyre-rte--readonly",c),...d,children:[!o&&t.jsx("div",{className:"vyre-rte__toolbar",role:"toolbar","aria-label":"Formatting",children:i.map(m=>{const _=u[m];return _?t.jsx("button",{type:"button",className:"vyre-rte__tool",title:_.label,"aria-label":_.label,disabled:!y,onMouseDown:g=>g.preventDefault(),onClick:()=>x(_.run),children:_.icon},m):null})}),t.jsx("div",{ref:f,className:"vyre-rte__content",contentEditable:y,suppressContentEditableWarning:!0,role:"textbox","aria-multiline":"true","aria-label":a,"data-placeholder":a,style:{minHeight:l},onInput:p,onBlur:p})]})});nt.displayName="VyreRichTextEditor";const st=s.forwardRef(({checked:e,defaultChecked:r=!1,onCheckedChange:a,disabled:n,size:o="md",className:i,...l},c)=>{const[d,h]=s.useState(r),f=e!==void 0?e:d,y=()=>{if(n)return;const p=!f;e===void 0&&h(p),a==null||a(p)};return t.jsx("button",{ref:c,type:"button",role:"switch","aria-checked":f,disabled:n,"data-checked":f||void 0,"data-size":o,className:["vyre-switch",i].filter(Boolean).join(" "),onClick:y,...l,children:t.jsx("span",{className:"vyre-switch__thumb"})})});st.displayName="Switch";const ot=s.forwardRef(({value:e,defaultValue:r=0,min:a=0,max:n=100,step:o=1,onValueChange:i,disabled:l,size:c="md",className:d,style:h,...f},y)=>{const[p,x]=s.useState(r),u=e!==void 0?e:p,m=(u-a)/(n-a)*100;return t.jsxs("div",{className:["vyre-slider",`vyre-slider--${c}`,d].filter(Boolean).join(" "),"data-disabled":l||void 0,style:{"--vyre-slider-pct":`${m}%`,...h},children:[t.jsx("input",{ref:y,type:"range",min:a,max:n,step:o,value:u,disabled:l,className:"vyre-slider__input",onChange:_=>{const g=Number(_.target.value);e===void 0&&x(g),i==null||i(g)},...f}),t.jsxs("div",{className:"vyre-slider__track",children:[t.jsx("div",{className:"vyre-slider__fill",style:{width:`${m}%`}}),t.jsx("div",{className:"vyre-slider__thumb",style:{left:`${m}%`}})]})]})});ot.displayName="Slider";const it=s.forwardRef(({value:e,max:r=100,indeterminate:a=!1,size:n="md",variant:o="default",className:i,...l},c)=>{const d=a?void 0:Math.min(100,Math.max(0,(e??0)/r*100));return t.jsx("div",{ref:c,role:"progressbar","aria-valuemin":0,"aria-valuemax":r,"aria-valuenow":a?void 0:e??0,"data-size":n,"data-variant":o,"data-indeterminate":a||void 0,className:["vyre-progress",i].filter(Boolean).join(" "),...l,children:t.jsx("div",{className:"vyre-progress__bar",style:d!==void 0?{width:`${d}%`}:void 0})})});it.displayName="Progress";const lt=s.forwardRef(({orientation:e="horizontal",decorative:r=!0,className:a,...n},o)=>t.jsx("div",{ref:o,role:r?"none":"separator","aria-orientation":r?void 0:e,"data-orientation":e,className:["vyre-separator",a].filter(Boolean).join(" "),...n}));lt.displayName="Separator";const ct=s.forwardRef(({required:e,disabled:r,className:a,children:n,...o},i)=>t.jsxs("label",{ref:i,"data-required":e||void 0,"data-disabled":r||void 0,className:["vyre-label",a].filter(Boolean).join(" "),...o,children:[n,e&&t.jsx("span",{className:"vyre-label__required","aria-hidden":"true",children:"*"})]}));ct.displayName="Label";const ye=s.forwardRef(({variant:e="rect",width:r,height:a,className:n,style:o,...i},l)=>t.jsx("div",{ref:l,"aria-hidden":"true","data-variant":e,className:["vyre-skeleton",n].filter(Boolean).join(" "),style:{width:typeof r=="number"?`${r}px`:r,height:typeof a=="number"?`${a}px`:a,...o},...i}));ye.displayName="Skeleton";const re=8,Gr=120;function Yr(e){const[r,a]=e.split("-");return{side:r,align:a??"center"}}function Kr(e,r,a,n,o,i){const l=e.width,c=e.height,d=r.width,h=r.height,f=e.left+o,y=e.top+i;let p=0,x=0;switch(a){case"top":p=y-h-re;break;case"bottom":p=y+c+re;break;case"left":x=f-d-re;break;case"right":x=f+l+re;break}if(a==="top"||a==="bottom")switch(n){case"start":x=f;break;case"center":x=f+l/2-d/2;break;case"end":x=f+l-d;break}else switch(n){case"start":p=y;break;case"center":p=y+c/2-h/2;break;case"end":p=y+c-h;break}return{top:p,left:x}}const dt=({trigger:e,children:r,open:a,onOpenChange:n,placement:o="bottom",closeOnOutside:i=!0,className:l})=>{const c=a!==void 0,[d,h]=s.useState(!1),[f,y]=s.useState(!1),[p,x]=s.useState(!1),[u,m]=s.useState({top:0,left:0}),_=c?a:d,g=s.useRef(null),N=s.useRef(null),b=s.useRef(null),L=s.useId(),{side:w,align:I}=Yr(o),A=s.useCallback(R=>{c||h(R),n==null||n(R)},[c,n]),T=s.useCallback(()=>A(!_),[_,A]),M=s.useCallback(()=>{y(!0),b.current=setTimeout(()=>{y(!1),x(!1),A(!1)},Gr)},[A]);s.useEffect(()=>{_?(b.current&&(clearTimeout(b.current),b.current=null),y(!1),x(!0)):p&&!f&&M()},[_]),s.useEffect(()=>{if(!p||!g.current||!N.current)return;const R=g.current.getBoundingClientRect(),j=N.current.getBoundingClientRect(),k=Kr(R,j,w,I,window.scrollX,window.scrollY);m(k)},[p,w,I]),s.useEffect(()=>{if(!p||!i)return;const R=j=>{N.current&&!N.current.contains(j.target)&&g.current&&!g.current.contains(j.target)&&M()};return document.addEventListener("mousedown",R),()=>document.removeEventListener("mousedown",R)},[p,i,M]),s.useEffect(()=>{if(!p)return;const R=j=>{j.key==="Escape"&&M()};return document.addEventListener("keydown",R),()=>document.removeEventListener("keydown",R)},[p,M]);const B=s.cloneElement(e,{ref:g,onClick:R=>{var j,k;T(),(k=(j=e.props).onClick)==null||k.call(j,R)},"aria-expanded":_,"aria-controls":L,"aria-haspopup":"dialog"});return t.jsxs(t.Fragment,{children:[B,p&&P.createPortal(t.jsx("div",{ref:N,id:L,role:"dialog","aria-modal":"false",className:v("vyre-popover",`vyre-popover--${w}`,f&&"vyre-popover--leaving",l),style:{top:u.top,left:u.left},children:r}),document.body)]})};dt.displayName="VyrePopover";const ae=s.createContext(null),ut=s.createContext(null),qr=120,mt=({trigger:e,children:r,placement:a="bottom-start",className:n})=>{const[o,i]=s.useState(!1),[l,c]=s.useState(!1),[d,h]=s.useState(!1),[f,y]=s.useState({top:0,left:0}),[p,x]=s.useState(-1),u=s.useRef(null),m=s.useRef(null),_=s.useRef(null),g=s.useId(),N=s.useCallback(()=>{var M;return Array.from(((M=m.current)==null?void 0:M.querySelectorAll("[role=menuitem]:not([aria-disabled=true]):not([disabled]),[role=menuitemcheckbox]:not([aria-disabled=true]):not([disabled]),[role=menuitemradio]:not([aria-disabled=true]):not([disabled])"))??[])},[]),b=s.useCallback(()=>{c(!0),_.current=setTimeout(()=>{var M;c(!1),h(!1),i(!1),x(-1),(M=u.current)==null||M.focus({preventScroll:!0})},qr)},[]),L=s.useCallback(()=>{_.current&&(clearTimeout(_.current),_.current=null),c(!1),i(!0),h(!0)},[]),w=s.useCallback(()=>{o?b():L()},[o,L,b]);s.useEffect(()=>{if(!d||!u.current)return;const M=u.current.getBoundingClientRect(),B=4,R=window.scrollX,j=window.scrollY;let k=0,D=0;a.startsWith("bottom")?(k=M.bottom+j+B,D=a==="bottom-start"?M.left+R:M.right+R):(k=M.top+j-B,D=a==="top-start"?M.left+R:M.right+R),y({top:k,left:D}),requestAnimationFrame(()=>{var V;(V=N()[0])==null||V.focus({preventScroll:!0}),x(0)})},[d,a,N]),s.useEffect(()=>{if(!d)return;const M=R=>{m.current&&!m.current.contains(R.target)&&u.current&&!u.current.contains(R.target)&&b()},B=R=>{var j,k,D;if(R.key==="Escape"){b();return}if(R.key==="ArrowDown"||R.key==="ArrowUp"){R.preventDefault();const E=N();if(!E.length)return;const V=R.key==="ArrowDown"?1:-1,X=(p+V+E.length)%E.length;(j=E[X])==null||j.focus({preventScroll:!0}),x(X)}if(R.key==="Home"&&((k=N()[0])==null||k.focus({preventScroll:!0}),x(0)),R.key==="End"){const E=N();(D=E[E.length-1])==null||D.focus({preventScroll:!0}),x(E.length-1)}};return document.addEventListener("mousedown",M),document.addEventListener("keydown",B),()=>{document.removeEventListener("mousedown",M),document.removeEventListener("keydown",B)}},[d,p,b,N]);const I=s.cloneElement(e,{ref:u,onClick:M=>{var B,R;w(),(R=(B=e.props).onClick)==null||R.call(B,M)},"aria-expanded":o,"aria-haspopup":"menu","aria-controls":g}),A=a.endsWith("-end"),T=a.startsWith("top");return t.jsxs(ae.Provider,{value:{close:b},children:[I,d&&P.createPortal(t.jsx("div",{ref:m,id:g,role:"menu","aria-orientation":"vertical",className:v("vyre-dropdown",A&&"vyre-dropdown--end",T&&"vyre-dropdown--top",l&&"vyre-dropdown--leaving",n),style:{top:f.top,left:f.left,transform:A?"translateX(-100%)":void 0},children:r}),document.body)]})};mt.displayName="VyreDropdownMenu";const vt=({children:e,className:r})=>t.jsx("div",{className:v("vyre-dropdown__label",r),children:e});vt.displayName="VyreDropdownLabel";const ft=({children:e,onSelect:r,disabled:a=!1,variant:n="default",icon:o,shortcut:i,className:l})=>{const c=s.useContext(ae);return t.jsxs("button",{role:"menuitem",className:v("vyre-dropdown__item",n==="danger"&&"vyre-dropdown__item--danger",l),"aria-disabled":a||void 0,disabled:a,tabIndex:-1,onClick:()=>{a||(r==null||r(),c==null||c.close())},children:[o&&t.jsx("span",{className:"vyre-dropdown__item-icon","aria-hidden":"true",children:o}),t.jsx("span",{className:"vyre-dropdown__item-label",children:e}),i&&t.jsx("kbd",{className:"vyre-dropdown__item-shortcut",children:i})]})};ft.displayName="VyreDropdownItem";const yt=({children:e,checked:r,onCheckedChange:a,disabled:n=!1,shortcut:o,className:i})=>{const l=s.useContext(ae);return t.jsxs("button",{role:"menuitemcheckbox","aria-checked":r,"aria-disabled":n||void 0,disabled:n,tabIndex:-1,className:v("vyre-dropdown__item vyre-dropdown__item--checkbox",i),onClick:()=>{n||(a(!r),l==null||l.close())},children:[t.jsx("span",{className:"vyre-dropdown__item-indicator","aria-hidden":"true",children:r&&t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",children:t.jsx("path",{d:"M2 6l3 3 5-5",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",strokeLinejoin:"round"})})}),t.jsx("span",{className:"vyre-dropdown__item-label",children:e}),o&&t.jsx("kbd",{className:"vyre-dropdown__item-shortcut",children:o})]})};yt.displayName="VyreDropdownCheckboxItem";const ht=({value:e,onValueChange:r,children:a})=>t.jsx(ut.Provider,{value:{value:e,onValueChange:r},children:t.jsx("div",{role:"group",children:a})});ht.displayName="VyreDropdownRadioGroup";const bt=({children:e,value:r,disabled:a=!1,className:n})=>{const o=s.useContext(ae),i=s.useContext(ut),l=(i==null?void 0:i.value)===r;return t.jsxs("button",{role:"menuitemradio","aria-checked":l,"aria-disabled":a||void 0,disabled:a,tabIndex:-1,className:v("vyre-dropdown__item vyre-dropdown__item--radio",n),onClick:()=>{a||(i==null||i.onValueChange(r),o==null||o.close())},children:[t.jsx("span",{className:"vyre-dropdown__item-indicator","aria-hidden":"true",children:l&&t.jsx("svg",{width:"8",height:"8",viewBox:"0 0 8 8",children:t.jsx("circle",{cx:"4",cy:"4",r:"3",fill:"currentColor"})})}),t.jsx("span",{className:"vyre-dropdown__item-label",children:e})]})};bt.displayName="VyreDropdownRadioItem";const pt=({trigger:e,children:r,icon:a,placement:n="right",disabled:o=!1,className:i})=>{const[l,c]=s.useState(!1),[d,h]=s.useState({top:0,left:0}),f=s.useRef(null),y=s.useRef(null),p=s.useCallback(()=>{if(!f.current)return;const m=f.current.getBoundingClientRect(),_=window.scrollX,g=window.scrollY,N=2;h({top:m.top+g,left:n==="right"?m.right+_+N:m.left+_-N}),c(!0)},[n]),x=s.useCallback(()=>c(!1),[]),u=m=>{var g;const _=m.relatedTarget;(g=y.current)!=null&&g.contains(_)||x()};return t.jsxs(t.Fragment,{children:[t.jsxs("button",{ref:f,role:"menuitem","aria-haspopup":"menu","aria-expanded":l,"aria-disabled":o||void 0,disabled:o,tabIndex:-1,className:v("vyre-dropdown__item vyre-dropdown__item--sub",i),onMouseEnter:p,onMouseLeave:u,onFocus:p,children:[a&&t.jsx("span",{className:"vyre-dropdown__item-icon","aria-hidden":"true",children:a}),t.jsx("span",{className:"vyre-dropdown__item-label",children:e}),t.jsx("span",{className:"vyre-dropdown__item-chevron","aria-hidden":"true",children:t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",children:t.jsx("path",{d:n==="right"?"M4 2l4 4-4 4":"M8 2L4 6l4 4",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),l&&P.createPortal(t.jsx("div",{ref:y,role:"menu",className:v("vyre-dropdown vyre-dropdown--sub",n==="left"&&"vyre-dropdown--sub-left"),style:{position:"absolute",top:d.top,left:n==="right"?d.left:void 0,right:n==="left"?`calc(100vw - ${d.left}px)`:void 0,transform:n==="left"?"translateX(-100%)":void 0},onMouseLeave:m=>{var g;const _=m.relatedTarget;(g=f.current)!=null&&g.contains(_)||x()},children:r}),document.body)]})};pt.displayName="VyreDropdownSub";const xt=({className:e})=>t.jsx("div",{role:"separator",className:v("vyre-dropdown__separator",e)});xt.displayName="VyreDropdownSeparator";const Ur=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"1.4"}),t.jsx("path",{d:"M8 7v4M8 5v.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]}),zr=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"1.4"}),t.jsx("path",{d:"M5 8l2 2 4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}),Xr=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("path",{d:"M8 2L14.5 13H1.5L8 2Z",stroke:"currentColor",strokeWidth:"1.4",strokeLinejoin:"round"}),t.jsx("path",{d:"M8 6v3M8 11v.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]}),Zr=()=>t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"1.4"}),t.jsx("path",{d:"M6 6l4 4M10 6l-4 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]}),_t={info:Ur,success:zr,warning:Xr,danger:Zr},gt=({variant:e="info",title:r,icon:a,onClose:n,children:o,className:i})=>{const l=_t[e];return t.jsxs("div",{role:"alert",className:v("vyre-alert",`vyre-alert--${e}`,i),children:[t.jsx("span",{className:"vyre-alert__icon","aria-hidden":"true",children:a??t.jsx(l,{})}),t.jsxs("div",{className:"vyre-alert__body",children:[r&&t.jsx("p",{className:"vyre-alert__title",children:r}),o&&t.jsx("div",{className:"vyre-alert__description",children:o})]}),n&&t.jsx("button",{type:"button",className:"vyre-alert__close","aria-label":"Dismiss",onClick:n,children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M3 3l8 8M11 3l-8 8",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})})]})};gt.displayName="VyreAlert";const Qr=["button:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(","),jt=({open:e,onOpenChange:r,title:a,description:n,variant:o="danger",confirmLabel:i="Confirm",cancelLabel:l="Cancel",onConfirm:c,onCancel:d,className:h})=>{const f=s.useRef(null),y=s.useRef(null),p=s.useRef(null),x=s.useCallback(()=>{d==null||d(),r(!1)},[d,r]),u=s.useCallback(()=>{c==null||c(),r(!1)},[c,r]),m=s.useCallback(g=>{if(g.key!=="Tab")return;const N=f.current;if(!N)return;const b=Array.from(N.querySelectorAll(Qr));if(!b.length)return;const L=b[0],w=b[b.length-1];g.shiftKey&&document.activeElement===L?(g.preventDefault(),w.focus()):!g.shiftKey&&document.activeElement===w&&(g.preventDefault(),L.focus())},[]);if(s.useEffect(()=>{if(!e)return;document.addEventListener("keydown",m);const g=document.body.style.overflow;document.body.style.overflow="hidden";const N=b=>{b.key==="Escape"&&x()};return document.addEventListener("keydown",N),setTimeout(()=>{var b;return(b=p.current)==null?void 0:b.focus()},0),()=>{document.removeEventListener("keydown",m),document.removeEventListener("keydown",N),document.body.style.overflow=g}},[e,m,x]),!e)return null;const _=_t[o];return P.createPortal(t.jsx("div",{ref:y,className:"vyre-alert-dialog-backdrop",onClick:g=>{g.target===y.current&&x()},role:"presentation",children:t.jsxs("div",{ref:f,role:"alertdialog","aria-modal":"true","aria-labelledby":"vyre-ad-title","aria-describedby":n?"vyre-ad-desc":void 0,className:v("vyre-alert-dialog",`vyre-alert-dialog--${o}`,h),tabIndex:-1,children:[t.jsx("div",{className:"vyre-alert-dialog__icon-wrap",children:t.jsx("span",{className:v("vyre-alert-dialog__icon",`vyre-alert-dialog__icon--${o}`),children:t.jsx(_,{})})}),t.jsxs("div",{className:"vyre-alert-dialog__body",children:[t.jsx("h2",{id:"vyre-ad-title",className:"vyre-alert-dialog__title",children:a}),n&&t.jsx("p",{id:"vyre-ad-desc",className:"vyre-alert-dialog__description",children:n})]}),t.jsxs("div",{className:"vyre-alert-dialog__footer",children:[t.jsx("button",{ref:p,type:"button",className:"vyre-btn vyre-btn--ghost vyre-btn--sm",onClick:x,children:l}),t.jsx("button",{type:"button",className:v("vyre-btn vyre-btn--sm",o==="danger"&&"vyre-btn--danger",o==="warning"&&"vyre-btn--primary",o==="info"&&"vyre-btn--accent"),onClick:u,children:i})]})]})}),document.body)};jt.displayName="VyreAlertDialog";const Jr=["a[href]","button:not([disabled])","textarea:not([disabled])","input:not([disabled])","select:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(","),wt=s.forwardRef(({open:e,onClose:r,side:a="right",size:n="md",closeOnBackdrop:o=!0,closeOnEsc:i=!0,className:l,children:c,"aria-label":d,"aria-labelledby":h,...f},y)=>{const p=s.useRef(null),x=s.useRef(null),u=s.useCallback(m=>{if(m.key!=="Tab")return;const _=p.current;if(!_)return;const g=Array.from(_.querySelectorAll(Jr));if(!g.length)return;const N=g[0],b=g[g.length-1];m.shiftKey&&document.activeElement===N?(m.preventDefault(),b.focus()):!m.shiftKey&&document.activeElement===b&&(m.preventDefault(),N.focus())},[]);return s.useEffect(()=>{if(!e)return;if(document.addEventListener("keydown",u),i){const _=N=>{N.key==="Escape"&&r()};document.addEventListener("keydown",_);const g=document.body.style.overflow;return document.body.style.overflow="hidden",setTimeout(()=>{var N;return(N=p.current)==null?void 0:N.focus()},0),()=>{document.removeEventListener("keydown",u),document.removeEventListener("keydown",_),document.body.style.overflow=g}}const m=document.body.style.overflow;return document.body.style.overflow="hidden",setTimeout(()=>{var _;return(_=p.current)==null?void 0:_.focus()},0),()=>{document.removeEventListener("keydown",u),document.body.style.overflow=m}},[e,u,i,r]),e?P.createPortal(t.jsx("div",{ref:x,className:"vyre-sheet-backdrop",onClick:m=>{o&&m.target===x.current&&r()},role:"presentation",children:t.jsx("div",{ref:m=>{p.current=m,typeof y=="function"?y(m):y&&(y.current=m)},role:"dialog","aria-modal":"true","aria-label":d,"aria-labelledby":h,tabIndex:-1,className:v("vyre-sheet",`vyre-sheet--${a}`,`vyre-sheet--${n}`,l),...f,children:c})}),document.body):null});wt.displayName="VyreSheet";const kt=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-sheet__header",e),...a,children:r}));kt.displayName="VyreSheetHeader";const Nt=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-sheet__body",e),...a,children:r}));Nt.displayName="VyreSheetBody";const Ct=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-sheet__footer",e),...a,children:r}));Ct.displayName="VyreSheetFooter";const Rt=({children:e,separator:r="/",className:a})=>{const n=s.Children.toArray(e).filter(Boolean);return t.jsx("nav",{"aria-label":"Breadcrumb",className:v("vyre-breadcrumb",a),children:t.jsx("ol",{className:"vyre-breadcrumb__list",children:n.map((o,i)=>t.jsxs("li",{className:"vyre-breadcrumb__item",children:[o,i<n.length-1&&t.jsx("span",{className:"vyre-breadcrumb__separator","aria-hidden":"true",children:r})]},i))})})};Rt.displayName="VyreBreadcrumb";const Lt=({children:e,href:r,current:a=!1,className:n})=>a||!r?t.jsx("span",{className:v("vyre-breadcrumb__link vyre-breadcrumb__link--current",n),"aria-current":a?"page":void 0,children:e}):t.jsx("a",{href:r,className:v("vyre-breadcrumb__link",n),children:e});Lt.displayName="VyreBreadcrumbItem";const Dt=({children:e,href:r,className:a})=>t.jsx("a",{href:r,className:v("vyre-breadcrumb__link",a),children:e});Dt.displayName="VyreBreadcrumbLink";const St=({children:e="/",className:r})=>t.jsx("span",{className:v("vyre-breadcrumb__separator",r),"aria-hidden":"true",children:e});St.displayName="VyreBreadcrumbSeparator";function xe(e,r){return Array.from({length:r-e+1},(a,n)=>e+n)}function ea(e,r,a){const n=a*2+5;if(r<=n)return xe(1,r);const o=Math.max(e-a,2),i=Math.min(e+a,r-1),l=o>2,c=i<r-1,d=[1];return l&&d.push("..."),d.push(...xe(o,i)),c&&d.push("..."),d.push(r),d}const ta=()=>t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M9 2L4 7l5 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),ra=()=>t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M5 2l5 5-5 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),aa=()=>t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M7 2L2 7l5 5M12 2L7 7l5 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),na=()=>t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 2l5 5-5 5M7 2l5 5-5 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Mt=({page:e,totalPages:r,onPageChange:a,siblings:n=1,showEdges:o=!0,showInfo:i=!1,totalItems:l,pageSize:c,className:d})=>{const h=ea(e,r,n),f=e>1,y=e<r,p=s.useMemo(()=>{if(!i)return null;if(l!=null&&c!=null){const u=(e-1)*c+1,m=Math.min(e*c,l);return`Showing ${u}–${m} of ${l}`}return`Page ${e} of ${r}`},[i,e,r,l,c]),x=t.jsxs(t.Fragment,{children:[o&&t.jsx("button",{className:"vyre-pagination__nav",onClick:()=>a(1),disabled:!f,"aria-label":"First page",children:t.jsx(aa,{})}),t.jsx("button",{className:"vyre-pagination__nav",onClick:()=>a(e-1),disabled:!f,"aria-label":"Previous page",children:t.jsx(ta,{})}),t.jsx("ol",{className:"vyre-pagination__list",children:h.map((u,m)=>u==="..."?t.jsx("li",{children:t.jsx("span",{className:"vyre-pagination__dots","aria-hidden":"true",children:"···"})},`dots-${m}`):t.jsx("li",{children:t.jsx("button",{className:v("vyre-pagination__btn",u===e&&"vyre-pagination__btn--active"),onClick:()=>a(u),"aria-label":`Page ${u}`,"aria-current":u===e?"page":void 0,children:u})},u))}),t.jsx("button",{className:"vyre-pagination__nav",onClick:()=>a(e+1),disabled:!y,"aria-label":"Next page",children:t.jsx(ra,{})}),o&&t.jsx("button",{className:"vyre-pagination__nav",onClick:()=>a(r),disabled:!y,"aria-label":"Last page",children:t.jsx(na,{})})]});return i?t.jsxs("div",{className:v("vyre-pagination-row",d),children:[t.jsx("span",{className:"vyre-pagination__info",children:p}),t.jsx("nav",{"aria-label":"Pagination",className:"vyre-pagination",children:x})]}):t.jsx("nav",{"aria-label":"Pagination",className:v("vyre-pagination",d),children:x})};Mt.displayName="VyrePagination";const It=({children:e,striped:r=!1,bordered:a=!1,compact:n=!1,hoverable:o=!0,className:i})=>t.jsx("div",{className:"vyre-table-wrapper",children:t.jsx("table",{className:v("vyre-table",r&&"vyre-table--striped",a&&"vyre-table--bordered",n&&"vyre-table--compact",o&&"vyre-table--hoverable",i),children:e})});It.displayName="VyreTable";const Tt=s.forwardRef(({className:e,...r},a)=>t.jsx("thead",{ref:a,className:v("vyre-table__head",e),...r}));Tt.displayName="VyreTableHead";const Et=s.forwardRef(({className:e,...r},a)=>t.jsx("tbody",{ref:a,className:v("vyre-table__body",e),...r}));Et.displayName="VyreTableBody";const At=s.forwardRef(({className:e,selected:r,...a},n)=>t.jsx("tr",{ref:n,className:v("vyre-table__row",r&&"vyre-table__row--selected",e),"aria-selected":r,...a}));At.displayName="VyreTableRow";const sa=({dir:e})=>t.jsx("span",{className:"vyre-table__sort-icon","aria-hidden":"true",children:t.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",children:[t.jsx("path",{d:"M6 2v8M3 5l3-3 3 3",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",opacity:e==="desc"?.3:1}),t.jsx("path",{d:"M3 7l3 3 3-3",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",opacity:e==="asc"?.3:1})]})}),Bt=s.forwardRef(({className:e,sortable:r,sortDir:a=null,onSort:n,align:o="left",children:i,...l},c)=>r?t.jsx("th",{ref:c,className:v("vyre-table__th vyre-table__th--sortable",`vyre-table__th--${o}`,a&&`vyre-table__th--sort-${a}`,e),"aria-sort":a==="asc"?"ascending":a==="desc"?"descending":"none",...l,children:t.jsxs("button",{className:"vyre-table__sort-btn",onClick:n,type:"button",children:[i,t.jsx(sa,{dir:a})]})}):t.jsx("th",{ref:c,className:v("vyre-table__th",`vyre-table__th--${o}`,e),...l,children:i}));Bt.displayName="VyreTableHeader";const Vt=s.forwardRef(({className:e,align:r="left",...a},n)=>t.jsx("td",{ref:n,className:v("vyre-table__td",`vyre-table__td--${r}`,e),...a}));Vt.displayName="VyreTableCell";const $t=s.forwardRef(({className:e,...r},a)=>t.jsx("caption",{ref:a,className:v("vyre-table__caption",e),...r}));$t.displayName="VyreTableCaption";const Ft=s.createContext(null),ne=()=>{const e=s.useContext(Ft);if(!e)throw new Error("Command components must be used inside <Command>");return e};function oe(e){return e.toLowerCase().replace(/\s+/g," ").trim()}function oa(e,r,a=[]){if(!e)return!0;const n=oe(e);return oe(r).includes(n)||a.some(o=>oe(o).includes(n))}let ia=0;function la(){return`cmd-${++ia}`}const he=s.forwardRef(({value:e,onValueChange:r,className:a,children:n},o)=>{const[i,l]=s.useState(""),[c,d]=s.useState(0),[h,f]=s.useState(0),y=e!==void 0?e:i,p=s.useCallback(b=>{l(b),r==null||r(b),d(0)},[r]),x=s.useRef(new Map),u=s.useRef(new Map),m=s.useCallback((b,L,w)=>{x.current.set(b,{el:L,disabled:w})},[]),_=s.useCallback(b=>{x.current.delete(b),u.current.delete(b)},[]),g=s.useCallback(b=>{var L;(L=u.current.get(b))==null||L()},[]),N=s.useMemo(()=>({search:y,setSearch:p,activeIndex:c,setActiveIndex:d,items:x,registerItem:m,unregisterItem:_,selectItem:g,onSelectRef:u,visibleCount:h,setVisibleCount:f}),[y,p,c,m,_,g,h]);return t.jsx(Ft.Provider,{value:N,children:t.jsx("div",{ref:o,className:v("vyre-command",a),role:"combobox","aria-expanded":"true","aria-haspopup":"listbox",children:n})})});he.displayName="VyreCommand";const Wt=s.forwardRef(({placeholder:e="Search...",className:r},a)=>{const{search:n,setSearch:o}=ne();return t.jsxs("div",{className:"vyre-command__input-wrapper",children:[t.jsx("svg",{className:"vyre-command__search-icon",width:"15",height:"15",viewBox:"0 0 15 15",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M10 6.5a3.5 3.5 0 1 1-7 0 3.5 3.5 0 0 1 7 0ZM9.5 10.207l3.146 3.147",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})}),t.jsx("input",{ref:a,className:v("vyre-command__input",r),type:"text",placeholder:e,value:n,onChange:i=>o(i.target.value),autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list","aria-controls":"vyre-command-list"}),n&&t.jsx("button",{className:"vyre-command__clear",type:"button","aria-label":"Clear search",onClick:()=>o(""),children:t.jsx("svg",{width:"13",height:"13",viewBox:"0 0 13 13",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 2l9 9M11 2l-9 9",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round"})})})]})});Wt.displayName="VyreCommandInput";const Ht=s.forwardRef(({className:e,children:r},a)=>{const{activeIndex:n,setActiveIndex:o,items:i,selectItem:l}=ne(),c=s.useCallback(d=>{var f,y;const h=Array.from((i.current??new Map).entries()).filter(([,p])=>!p.disabled&&p.el.closest("[data-cmd-item]")!==null&&!p.el.hasAttribute("data-cmd-hidden"));if(d.key==="ArrowDown")d.preventDefault(),o(Math.min(n+1,h.length-1)),(f=h[Math.min(n+1,h.length-1)])==null||f[1].el.scrollIntoView({block:"nearest"});else if(d.key==="ArrowUp")d.preventDefault(),o(Math.max(n-1,0)),(y=h[Math.max(n-1,0)])==null||y[1].el.scrollIntoView({block:"nearest"});else if(d.key==="Enter"){d.preventDefault();const[p]=h[n]??[];p&&l(p)}},[n,o,i,l]);return t.jsx("div",{ref:a,id:"vyre-command-list",role:"listbox",className:v("vyre-command__list",e),onKeyDown:c,children:r})});Ht.displayName="VyreCommandList";const Pt=({className:e,children:r})=>{const{search:a,visibleCount:n}=ne();return!a||n>0?null:t.jsx("div",{className:v("vyre-command__empty",e),role:"presentation",children:r??"No results found."})};Pt.displayName="VyreCommandEmpty";const Ot=({heading:e,className:r,children:a})=>t.jsxs("div",{className:v("vyre-command__group",r),role:"presentation",children:[e&&t.jsx("div",{className:"vyre-command__group-heading","aria-hidden":"true",children:e}),t.jsx("div",{role:"group","aria-label":e,children:a})]});Ot.displayName="VyreCommandGroup";const Gt=({onSelect:e,disabled:r=!1,keywords:a,className:n,children:o,icon:i,shortcut:l})=>{const{search:c,setActiveIndex:d,registerItem:h,unregisterItem:f,onSelectRef:y,setVisibleCount:p}=ne(),x=s.useMemo(()=>la(),[]),u=s.useRef(null),_=oa(c,typeof o=="string"?o:"",a);return s.useEffect(()=>(p(g=>g+(_?1:0)),()=>{p(g=>g-(_?1:0))}),[_,p]),s.useEffect(()=>{const g=u.current;if(!(!g||!_))return h(x,g,r),()=>f(x)},[x,r,_,h,f]),s.useEffect(()=>{var g;return e&&((g=y.current)==null||g.set(x,e)),()=>{var N;(N=y.current)==null||N.delete(x)}},[x,e,y]),_?t.jsxs("div",{ref:u,"data-cmd-item":!0,role:"option","aria-disabled":r||void 0,className:v("vyre-command__item",r&&"vyre-command__item--disabled",n),onClick:()=>{r||e==null||e()},onMouseEnter:()=>{!r&&u.current&&d(-1)},children:[i&&t.jsx("span",{className:"vyre-command__item-icon","aria-hidden":"true",children:i}),t.jsx("span",{className:"vyre-command__item-label",children:o}),l&&t.jsx("kbd",{className:"vyre-command__item-shortcut",children:l})]}):null};Gt.displayName="VyreCommandItem";const Yt=({className:e})=>t.jsx("div",{className:v("vyre-command__separator",e),role:"separator","aria-hidden":"true"});Yt.displayName="VyreCommandSeparator";const Kt=({open:e,onOpenChange:r,value:a,onValueChange:n,className:o,children:i})=>{const l=s.useRef(null);return s.useEffect(()=>{var h;if(!e)return;const c=document.activeElement,d=(h=l.current)==null?void 0:h.querySelector(".vyre-command__input");return d==null||d.focus(),()=>{c==null||c.focus({preventScroll:!0})}},[e]),s.useEffect(()=>{if(!e)return;const c=d=>{d.key==="Escape"&&r(!1)};return window.addEventListener("keydown",c),()=>window.removeEventListener("keydown",c)},[e,r]),e?P.createPortal(t.jsx("div",{className:"vyre-command-backdrop",ref:l,onClick:c=>{c.target===c.currentTarget&&r(!1)},role:"dialog","aria-modal":"true","aria-label":"Command palette",children:t.jsx(he,{value:a,onValueChange:n,className:v("vyre-command--dialog",o),children:i})}),document.body):null};Kt.displayName="VyreCommandDialog";const qt=s.forwardRef(({orientation:e="horizontal",attached:r=!1,size:a,className:n,children:o,...i},l)=>t.jsx("div",{ref:l,role:"group",className:v("vyre-btn-group",e==="vertical"&&"vyre-btn-group--vertical",r&&"vyre-btn-group--attached",n),"data-orientation":e,"data-size":a,...i,children:o}));qt.displayName="VyreButtonGroup";const be=s.forwardRef(({variant:e="default",size:r="md",onRemove:a,onClick:n,disabled:o=!1,className:i,children:l,...c},d)=>{const h=!!n&&!o;return t.jsxs("span",{ref:d,className:v("vyre-tag",`vyre-tag--${e}`,`vyre-tag--${r}`,h&&"vyre-tag--clickable",o&&"vyre-tag--disabled",i),"data-variant":e,"data-size":r,role:h?"button":void 0,tabIndex:h?0:void 0,"aria-disabled":o||void 0,onClick:h?n:void 0,onKeyDown:h?f=>{(f.key==="Enter"||f.key===" ")&&(f.preventDefault(),n==null||n())}:void 0,...c,children:[t.jsx("span",{className:"vyre-tag__label",children:l}),a&&t.jsx("button",{type:"button",className:"vyre-tag__remove","aria-label":"Remove",disabled:o,onClick:f=>{f.stopPropagation(),a()},children:t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M9 3L3 9M3 3L9 9",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})})]})});be.displayName="VyreTag";const Ut=s.forwardRef(({value:e,onChange:r,placeholder:a="Add tag…",disabled:n=!1,max:o,size:i="md",className:l,style:c,"data-testid":d},h)=>{const[f,y]=s.useState(""),p=s.useRef(null),x=o!==void 0&&e.length>=o,u=n||x;function m(b){const L=b.trim();if(!L||e.includes(L)||x){y("");return}r([...e,L]),y("")}function _(b){n||r(e.filter((L,w)=>w!==b))}function g(b){if(b.key==="Enter"||b.key===","){b.preventDefault(),m(f);return}b.key==="Backspace"&&f===""&&e.length>0&&_(e.length-1)}function N(b){const L=b.target.value;if(L.includes(",")){const w=L.split(",");w.slice(0,-1).forEach(A=>m(A)),y(w[w.length-1])}else y(L)}return t.jsxs("div",{ref:h,className:v("vyre-tags-input",`vyre-tags-input--${i}`,n&&"vyre-tags-input--disabled",l),"data-testid":d,style:c,onClick:()=>{var b;return(b=p.current)==null?void 0:b.focus()},children:[e.map((b,L)=>t.jsx(be,{size:i,disabled:n,onRemove:n?void 0:()=>_(L),children:b},`${b}-${L}`)),t.jsx("input",{ref:p,type:"text",className:"vyre-tags-input__field",value:f,onChange:N,onKeyDown:g,placeholder:x?"":a,disabled:u,"aria-label":"Add tag"})]})});Ut.displayName="VyreTagsInput";const zt=s.forwardRef(({options:e,value:r,onChange:a,placeholder:n="Search…",disabled:o=!1,size:i="md",emptyText:l="No results",className:c,...d},h)=>{const[f,y]=s.useState(!1),[p,x]=s.useState(""),[u,m]=s.useState(-1),_=s.useRef(null),g=s.useRef(null),N=s.useRef(null),L=`${s.useId()}-listbox`,w=e.find(k=>k.value===r)??null,I=e.filter(k=>k.label.toLowerCase().includes(p.toLowerCase())),A=s.useCallback(()=>{y(!1),m(-1),x("")},[]),T=s.useCallback(k=>{var D;k.disabled||(a(k.value),A(),(D=_.current)==null||D.blur())},[a,A]);s.useEffect(()=>{if(!f)return;const k=D=>{const E=N.current;E&&!E.contains(D.target)&&A()};return document.addEventListener("mousedown",k),()=>document.removeEventListener("mousedown",k)},[f,A]),s.useEffect(()=>{var D;if(!f||u<0)return;const k=(D=g.current)==null?void 0:D.children[u];k==null||k.scrollIntoView({block:"nearest"})},[u,f]),s.useEffect(()=>{m(I.length>0?0:-1)},[p]);function M(){o||(y(!0),x(""))}function B(k){x(k.target.value),f||y(!0)}function R(k){var D;switch(k.key){case"ArrowDown":{if(k.preventDefault(),!f){y(!0);return}m(E=>{let V=E+1;for(;V<I.length&&I[V].disabled;)V++;return V<I.length?V:E});break}case"ArrowUp":{if(k.preventDefault(),!f){y(!0);return}m(E=>{let V=E-1;for(;V>=0&&I[V].disabled;)V--;return V>=0?V:E});break}case"Enter":{k.preventDefault(),f&&u>=0&&I[u]&&T(I[u]);break}case"Escape":{A(),(D=_.current)==null||D.blur();break}}}const j=f?p:(w==null?void 0:w.label)??"";return t.jsxs("div",{ref:k=>{N.current=k,typeof h=="function"?h(k):h&&(h.current=k)},className:v("vyre-combobox",`vyre-combobox--${i}`,o&&"vyre-combobox--disabled",c),"data-open":f,...d,children:[t.jsx("input",{ref:_,type:"text",role:"combobox","aria-expanded":f,"aria-haspopup":"listbox","aria-controls":L,"aria-autocomplete":"list","aria-disabled":o,disabled:o,className:"vyre-combobox__input",placeholder:n,value:j,onFocus:M,onChange:B,onKeyDown:R}),t.jsx("span",{className:"vyre-combobox__chevron","aria-hidden":"true",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M3 5L7 9L11 5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}),f&&t.jsx("ul",{ref:g,id:L,role:"listbox",className:"vyre-combobox__dropdown","aria-label":"Options",children:I.length>0?I.map((k,D)=>t.jsx("li",{role:"option","aria-selected":k.value===r,"aria-disabled":k.disabled,"data-highlighted":D===u,className:v("vyre-combobox__option",D===u&&"vyre-combobox__option--highlighted",k.value===r&&"vyre-combobox__option--selected"),onMouseEnter:()=>!k.disabled&&m(D),onMouseDown:E=>{E.preventDefault(),T(k)},children:k.label},k.value)):t.jsx("li",{className:"vyre-combobox__empty",role:"presentation",children:l})})]})});zt.displayName="VyreCombobox";function ca({col:e,sortKey:r,sortDir:a}){const o=r===e.key?a:void 0;return t.jsx("span",{className:"vyre-data-grid__sort-icon","aria-hidden":"true",children:t.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",children:[t.jsx("path",{d:"M6 2v4M3.5 4.5L6 2l2.5 2.5",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",opacity:o==="desc"?.3:1}),t.jsx("path",{d:"M6 10V6M3.5 7.5L6 10l2.5-2.5",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round",opacity:o==="asc"?.3:1})]})})}const da=5,Xt=s.forwardRef(({columns:e,rows:r,sortKey:a,sortDir:n,onSort:o,loading:i=!1,emptyText:l="No data",stickyHeader:c=!1,className:d,style:h,"data-testid":f},y)=>{function p(u){if(!u.sortable||!o)return;const m=a===u.key&&n==="asc"?"desc":"asc";o(u.key,m)}function x(u){return a!==u.key?"none":n==="asc"?"ascending":"descending"}return t.jsx("div",{ref:y,className:v("vyre-data-grid",c&&"vyre-data-grid--sticky-header",d),style:h,"data-testid":f,children:t.jsxs("table",{className:"vyre-data-grid__table",children:[t.jsx("thead",{className:"vyre-data-grid__thead",children:t.jsx("tr",{children:e.map(u=>t.jsx("th",{className:v("vyre-data-grid__th",u.sortable&&"vyre-data-grid__th--sortable",a===u.key&&`vyre-data-grid__th--sort-${n}`),style:u.width?{width:u.width}:void 0,"aria-sort":u.sortable?x(u):void 0,children:u.sortable?t.jsxs("button",{type:"button",className:"vyre-data-grid__sort-btn",onClick:()=>p(u),children:[u.label,t.jsx(ca,{col:u,sortKey:a,sortDir:n})]}):u.label},u.key))})}),t.jsx("tbody",{className:"vyre-data-grid__tbody",children:i?Array.from({length:da}).map((u,m)=>t.jsx("tr",{className:"vyre-data-grid__row vyre-data-grid__row--skeleton",children:e.map(_=>t.jsx("td",{className:"vyre-data-grid__td",children:t.jsx(ye,{height:16})},_.key))},`skel-${m}`)):r.length===0?t.jsx("tr",{className:"vyre-data-grid__row vyre-data-grid__row--empty",children:t.jsx("td",{className:"vyre-data-grid__td vyre-data-grid__empty",colSpan:e.length,children:l})}):r.map((u,m)=>t.jsx("tr",{className:"vyre-data-grid__row",children:e.map(_=>t.jsx("td",{className:"vyre-data-grid__td",children:u[_.key]!=null?String(u[_.key]):""},_.key))},m))})]})})});Xt.displayName="VyreDataGrid";const Zt=s.forwardRef(({gap:e="md",wrap:r=!0,className:a,children:n,...o},i)=>t.jsx("div",{ref:i,className:v("vyre-tag-group",`vyre-tag-group--gap-${e}`,!r&&"vyre-tag-group--nowrap",a),role:"list",...o,children:n}));Zt.displayName="VyreTagGroup";function z(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate())}function G(e,r){return e.getFullYear()===r.getFullYear()&&e.getMonth()===r.getMonth()&&e.getDate()===r.getDate()}function Q(e,r){return z(e)<z(r)}function _e(e,r){return z(e)>z(r)}function ua(e,r){return new Date(e,r+1,0).getDate()}function ma(e,r,a){return(new Date(e,r,1).getDay()-a+7)%7}function Y(e,r){return e?new Intl.DateTimeFormat("default",{year:"numeric",month:"short",day:"numeric"}).format(e):""}function va(e){return`${String(e.getHours()).padStart(2,"0")}:${String(e.getMinutes()).padStart(2,"0")}`}const ge=Array.from({length:12},(e,r)=>new Intl.DateTimeFormat("default",{month:"long"}).format(new Date(2e3,r,1))),J=12,ee=s.forwardRef((e,r)=>{const{showTime:a=!1,minDate:n,maxDate:o,disabled:i,className:l,weekStartsOn:c=1,defaultMonth:d}=e,h=z(new Date),f=()=>{var C,S;return e.mode==="range"?((C=e.value)==null?void 0:C[0])??d??h:e.mode==="multiple"?((S=e.value)==null?void 0:S[0])??d??h:e.value??d??h},[y,p]=s.useState(()=>(f()??h).getFullYear()),[x,u]=s.useState(()=>(f()??h).getMonth()),[m,_]=s.useState("days"),[g,N]=s.useState(null),[b,L]=s.useState(()=>{const C=e.mode==="single"?e.value:null;return C?C.getHours():0}),[w,I]=s.useState(()=>{const C=e.mode==="single"?e.value:null;return C?C.getMinutes():0}),A=s.useMemo(()=>{const C=ua(y,x),S=ma(y,x,c);return{count:C,offset:S}},[y,x,c]),T=s.useMemo(()=>c===1?["Mo","Tu","We","Th","Fr","Sa","Su"]:["Su","Mo","Tu","We","Th","Fr","Sa"],[c]),M=s.useCallback(C=>{if(e.mode==="single")return!!e.value&&G(C,e.value);if(e.mode==="range"){const[S,$]=e.value??[null,null];return!!S&&G(C,S)||!!$&&G(C,$)}return e.mode==="multiple"?(e.value??[]).some(S=>G(C,S)):!1},[e]),B=s.useCallback(C=>{if(e.mode!=="range")return!1;const[S,$]=e.value??[null,null],F=$??g;if(!S||!F)return!1;const K=Q(S,F)?S:F,q=Q(S,F)?F:S;return _e(C,K)&&Q(C,q)},[e,g]),R=s.useCallback(C=>{if(e.mode!=="range")return!1;const[S]=e.value??[null,null];return!!S&&G(C,S)},[e]),j=s.useCallback(C=>{if(e.mode!=="range")return!1;const[,S]=e.value??[null,null];return!!S&&G(C,S)},[e]),k=s.useCallback(C=>!!(n&&Q(C,n)||o&&_e(C,o)||i!=null&&i(C)),[n,o,i]),D=s.useCallback(C=>{var $,F,K,q,Z,te;const S=new Date(y,x,C,b,w);if(!k(z(S))){if(e.mode==="single"||!e.mode)($=e.onChange)==null||$.call(e,S);else if(e.mode==="range"){const[H,U]=e.value??[null,null];!H||H&&U?(F=e.onChange)==null||F.call(e,[S,null]):Q(S,H)?(K=e.onChange)==null||K.call(e,[S,H]):(q=e.onChange)==null||q.call(e,[H,S])}else if(e.mode==="multiple"){const H=e.value??[],U=H.findIndex(pe=>G(pe,S));U>=0?(Z=e.onChange)==null||Z.call(e,H.filter((pe,Rr)=>Rr!==U)):(te=e.onChange)==null||te.call(e,[...H,S])}}},[y,x,b,w,e,k]),E=()=>{x===0?(u(11),p(C=>C-1)):u(C=>C-1)},V=()=>{x===11?(u(0),p(C=>C+1)):u(C=>C+1)},X=(C,S)=>{var $;if(L(C),I(S),e.mode==="single"&&e.value){const F=new Date(e.value);F.setHours(C,S),($=e.onChange)==null||$.call(e,F)}},Cr=Math.floor(y/J)*J;return t.jsxs("div",{ref:r,className:v("vyre-calendar",l),children:[t.jsxs("div",{className:"vyre-calendar__header",children:[m==="days"&&t.jsx("button",{className:"vyre-calendar__nav",onClick:E,"aria-label":"Previous month",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M9 11L5 7l4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}),m==="years"&&t.jsx("button",{className:"vyre-calendar__nav",onClick:()=>p(C=>C-J),"aria-label":"Previous years",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M9 11L5 7l4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}),t.jsxs("div",{className:"vyre-calendar__header-center",children:[t.jsx("button",{className:"vyre-calendar__header-btn",onClick:()=>_(m==="months"?"days":"months"),children:ge[x]}),t.jsx("button",{className:"vyre-calendar__header-btn",onClick:()=>_(m==="years"?"days":"years"),children:y})]}),m==="days"&&t.jsx("button",{className:"vyre-calendar__nav",onClick:V,"aria-label":"Next month",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M5 3l4 4-4 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}),m==="years"&&t.jsx("button",{className:"vyre-calendar__nav",onClick:()=>p(C=>C+J),"aria-label":"Next years",children:t.jsx("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",children:t.jsx("path",{d:"M5 3l4 4-4 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),m==="months"&&t.jsx("div",{className:"vyre-calendar__month-grid",children:ge.map((C,S)=>t.jsx("button",{className:v("vyre-calendar__month-cell",S===x&&"vyre-calendar__month-cell--active"),onClick:()=>{u(S),_("days")},children:C.slice(0,3)},C))}),m==="years"&&t.jsx("div",{className:"vyre-calendar__year-grid",children:Array.from({length:J},(C,S)=>Cr+S).map(C=>t.jsx("button",{className:v("vyre-calendar__year-cell",C===y&&"vyre-calendar__year-cell--active"),onClick:()=>{p(C),_("days")},children:C},C))}),m==="days"&&t.jsxs("div",{className:"vyre-calendar__grid",children:[T.map(C=>t.jsx("div",{className:"vyre-calendar__weekday",children:C},C)),Array.from({length:A.offset}).map((C,S)=>t.jsx("div",{},`empty-${S}`)),Array.from({length:A.count},(C,S)=>S+1).map(C=>{const S=new Date(y,x,C),$=M(S),F=B(S),K=R(S),q=j(S),Z=k(S),te=G(S,h);return t.jsx("button",{className:v("vyre-calendar__day",te&&"vyre-calendar__day--today",$&&"vyre-calendar__day--selected",F&&"vyre-calendar__day--in-range",K&&"vyre-calendar__day--range-start",q&&"vyre-calendar__day--range-end",Z&&"vyre-calendar__day--disabled"),onClick:()=>D(C),onMouseEnter:()=>{if(e.mode==="range"){const[H,U]=e.value??[null,null];H&&!U&&N(S)}},onMouseLeave:()=>N(null),disabled:Z,"aria-selected":$,"aria-label":Y(S),children:C},C)})]}),a&&m==="days"&&t.jsxs("div",{className:"vyre-calendar__time",children:[t.jsxs("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[t.jsx("circle",{cx:"7",cy:"7",r:"5.5",stroke:"currentColor",strokeWidth:"1.3"}),t.jsx("path",{d:"M7 4v3.5l2 1.5",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]}),t.jsx("input",{type:"number",className:"vyre-calendar__time-input",min:0,max:23,value:b,onChange:C=>X(Number(C.target.value),w),"aria-label":"Hours"}),t.jsx("span",{className:"vyre-calendar__time-sep",children:":"}),t.jsx("input",{type:"number",className:"vyre-calendar__time-input",min:0,max:59,value:w,onChange:C=>X(b,Number(C.target.value)),"aria-label":"Minutes"})]})]})});ee.displayName="VyreCalendar";function fa(e){if(e.mode==="range"){const[n,o]=e.value??[null,null];return n?o?`${Y(n)} – ${Y(o)}`:Y(n):""}if(e.mode==="multiple"){const n=e.value??[];return n.length===0?"":n.length===1?Y(n[0]):`${n.length} dates selected`}const r=e.value,a=e.showTime;return r?a?`${Y(r)} ${va(r)}`:Y(r):""}const Qt=s.forwardRef(({placeholder:e="Pick a date",inputClassName:r,...a},n)=>{const[o,i]=s.useState(!1),l=s.useRef(null),c=s.useRef(null),[d,h]=s.useState({top:0,left:0,width:0}),f=fa(a),y=s.useCallback(()=>{if(!l.current)return;const u=l.current.getBoundingClientRect();h({top:u.bottom+window.scrollY+6,left:u.left+window.scrollX,width:u.width})},[]);s.useEffect(()=>{if(!o)return;y();const u=()=>y(),m=()=>y();return window.addEventListener("scroll",u,!0),window.addEventListener("resize",m),()=>{window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",m)}},[o,y]),s.useEffect(()=>{if(!o)return;const u=_=>{var g,N;!((g=c.current)!=null&&g.contains(_.target))&&!((N=l.current)!=null&&N.contains(_.target))&&i(!1)},m=_=>{_.key==="Escape"&&i(!1)};return document.addEventListener("pointerdown",u),document.addEventListener("keydown",m),()=>{document.removeEventListener("pointerdown",u),document.removeEventListener("keydown",m)}},[o]);const p=a.mode!=="range"&&a.mode!=="multiple"&&!a.showTime,x=s.useMemo(()=>a.mode==="range"?{...a,onChange:u=>{var m;(m=a.onChange)==null||m.call(a,u),u[0]&&u[1]&&i(!1)}}:a.mode==="multiple"?a:{...a,onChange:u=>{var m;(m=a.onChange)==null||m.call(a,u),p&&i(!1)}},[a,p]);return t.jsxs("div",{ref:n,className:"vyre-datepicker",children:[t.jsxs("button",{ref:l,type:"button",className:v("vyre-datepicker__trigger",!f&&"vyre-datepicker__trigger--placeholder",r),onClick:()=>{y(),i(u=>!u)},"aria-expanded":o,"aria-haspopup":"dialog",children:[t.jsxs("svg",{className:"vyre-datepicker__icon",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[t.jsx("rect",{x:"1.5",y:"2.5",width:"11",height:"10",rx:"1.5",stroke:"currentColor",strokeWidth:"1.3"}),t.jsx("path",{d:"M1.5 6h11M4.5 1v3M9.5 1v3",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]}),t.jsx("span",{children:f||e}),f&&t.jsx("button",{className:"vyre-datepicker__clear",type:"button","aria-label":"Clear",onClick:u=>{var m,_,g;u.stopPropagation(),a.mode==="range"?(m=a.onChange)==null||m.call(a,[null,null]):a.mode==="multiple"?(_=a.onChange)==null||_.call(a,[]):(g=a.onChange)==null||g.call(a,null)},children:t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 2l8 8M10 2l-8 8",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round"})})})]}),o&&P.createPortal(t.jsx("div",{ref:c,className:"vyre-datepicker__popover",role:"dialog","aria-label":"Date picker",style:{top:d.top,left:d.left,minWidth:d.width},children:t.jsx(ee,{...x})}),document.body)]})});Qt.displayName="VyreDatePicker";function O(e){return new Date(e.getFullYear(),e.getMonth(),e.getDate())}function ie(e,r){const a=new Date(e);return a.setDate(a.getDate()+r),O(a)}function le(e){return e?new Intl.DateTimeFormat("default",{year:"numeric",month:"short",day:"numeric"}).format(e):""}const ya=[{label:"Today",range:()=>{const e=O(new Date);return{from:e,to:e}}},{label:"Yesterday",range:()=>{const e=ie(new Date,-1);return{from:e,to:e}}},{label:"Last 7 days",range:()=>({from:ie(new Date,-6),to:O(new Date)})},{label:"Last 30 days",range:()=>({from:ie(new Date,-29),to:O(new Date)})},{label:"This month",range:()=>{const e=new Date;return{from:O(new Date(e.getFullYear(),e.getMonth(),1)),to:O(new Date(e.getFullYear(),e.getMonth()+1,0))}}},{label:"Last month",range:()=>{const e=new Date;return{from:O(new Date(e.getFullYear(),e.getMonth()-1,1)),to:O(new Date(e.getFullYear(),e.getMonth(),0))}}}],Jt=s.forwardRef(({value:e,onChange:r,placeholder:a="Pick a date range",numberOfMonths:n=2,presets:o=!1,minDate:i,maxDate:l,disabled:c,weekStartsOn:d=1,className:h,inputClassName:f},y)=>{const[p,x]=s.useState(!1),u=s.useRef(null),m=s.useRef(null),[_,g]=s.useState({top:0,left:0,width:0}),N=(e==null?void 0:e.from)??null,b=(e==null?void 0:e.to)??null,L=s.useMemo(()=>o===!0?ya:Array.isArray(o)?o:[],[o]),w=s.useMemo(()=>N?b?`${le(N)} – ${le(b)}`:le(N):"",[N,b]),I=s.useCallback(()=>{if(!u.current)return;const j=u.current.getBoundingClientRect();g({top:j.bottom+window.scrollY+6,left:j.left+window.scrollX,width:j.width})},[]);s.useEffect(()=>{if(!p)return;I();const j=()=>I(),k=()=>I();return window.addEventListener("scroll",j,!0),window.addEventListener("resize",k),()=>{window.removeEventListener("scroll",j,!0),window.removeEventListener("resize",k)}},[p,I]),s.useEffect(()=>{if(!p)return;const j=D=>{var E,V;!((E=m.current)!=null&&E.contains(D.target))&&!((V=u.current)!=null&&V.contains(D.target))&&x(!1)},k=D=>{D.key==="Escape"&&x(!1)};return document.addEventListener("pointerdown",j),document.addEventListener("keydown",k),()=>{document.removeEventListener("pointerdown",j),document.removeEventListener("keydown",k)}},[p]);const A=s.useCallback(j=>{const k={from:j[0],to:j[1]};r==null||r(k),k.from&&k.to&&x(!1)},[r]),T=s.useCallback(j=>{r==null||r(j.range()),x(!1)},[r]),M=s.useCallback(()=>{r==null||r({from:null,to:null})},[r]),B=s.useMemo(()=>{const j=N??O(new Date);return new Date(j.getFullYear(),j.getMonth()+1,1)},[N]),R=[N,b];return t.jsxs("div",{ref:y,className:v("vyre-date-range-picker",h),children:[t.jsxs("button",{ref:u,type:"button",className:v("vyre-datepicker__trigger",!w&&"vyre-datepicker__trigger--placeholder",f),onClick:()=>{I(),x(j=>!j)},"aria-expanded":p,"aria-haspopup":"dialog",children:[t.jsxs("svg",{className:"vyre-datepicker__icon",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[t.jsx("rect",{x:"1.5",y:"2.5",width:"11",height:"10",rx:"1.5",stroke:"currentColor",strokeWidth:"1.3"}),t.jsx("path",{d:"M1.5 6h11M4.5 1v3M9.5 1v3",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]}),t.jsx("span",{children:w||a}),w&&t.jsx("button",{className:"vyre-datepicker__clear",type:"button","aria-label":"Clear",onClick:j=>{j.stopPropagation(),M()},children:t.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 2l8 8M10 2l-8 8",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round"})})})]}),p&&P.createPortal(t.jsxs("div",{ref:m,className:"vyre-date-range-picker__popover",role:"dialog","aria-label":"Date range picker",style:{top:_.top,left:_.left},children:[L.length>0&&t.jsx("div",{className:"vyre-date-range-picker__presets",children:L.map(j=>t.jsx("button",{type:"button",className:"vyre-date-range-picker__preset",onClick:()=>T(j),children:j.label},j.label))}),t.jsxs("div",{className:"vyre-date-range-picker__calendars",children:[t.jsx(ee,{mode:"range",value:R,onChange:A,minDate:i,maxDate:l,disabled:c,weekStartsOn:d}),n===2&&t.jsx(ee,{mode:"range",value:R,defaultMonth:B,onChange:A,minDate:i,maxDate:l,disabled:c,weekStartsOn:d},B.toISOString())]})]}),document.body)]})});Jt.displayName="VyreDateRangePicker";const er=s.forwardRef(({variant:e="default",size:r="md",clickable:a=!1,className:n,children:o,...i},l)=>t.jsx("div",{ref:l,className:v("vyre-item",`vyre-item--${e}`,`vyre-item--${r}`,a&&"vyre-item--clickable",n),"data-variant":e,"data-size":r,role:a?"button":void 0,tabIndex:a?0:void 0,...i,children:o}));er.displayName="VyreItem";const tr=s.forwardRef(({separated:e=!1,className:r,children:a,...n},o)=>t.jsx("div",{ref:o,role:"list",className:v("vyre-item-group",e&&"vyre-item-group--separated",r),...n,children:a}));tr.displayName="VyreItemGroup";const rr=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-item__media",e),"aria-hidden":"true",...a,children:r}));rr.displayName="VyreItemMedia";const ar=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-item__content",e),...a,children:r}));ar.displayName="VyreItemContent";const nr=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-item__title",e),...a,children:r}));nr.displayName="VyreItemTitle";const sr=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("p",{ref:n,className:v("vyre-item__description",e),...a,children:r}));sr.displayName="VyreItemDescription";const or=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("div",{ref:n,className:v("vyre-item__actions",e),...a,children:r}));or.displayName="VyreItemActions";function ha(e,r,a,n){const o=e.find(l=>l.id===r.fromColumnId);if(!o)return e;const i=o.cards.find(l=>l.id===r.cardId);return i?e.map(l=>{if(l.id===r.fromColumnId&&l.id===a){const c=l.cards.filter(f=>f.id!==r.cardId),d=Math.max(0,Math.min(n,c.length)),h=[...c];return h.splice(d,0,i),{...l,cards:h}}if(l.id===r.fromColumnId)return{...l,cards:l.cards.filter(c=>c.id!==r.cardId)};if(l.id===a){const c=Math.max(0,Math.min(n,l.cards.length)),d=[...l.cards];return d.splice(c,0,i),{...l,cards:d}}return l}):e}const ir=s.forwardRef(({value:e,onChange:r,renderCard:a,onCardClick:n,className:o,...i},l)=>{const c=s.useRef(null),d=s.useRef(!1),[h,f]=s.useState(null),[y,p]=s.useState(null),[x,u]=s.useState(null),m=(b,L)=>{p(w=>w===b?w:b),u(w=>w===L?w:L)},_=(b,L)=>w=>{c.current={cardId:L,fromColumnId:b},d.current=!1,f(L),w.dataTransfer.effectAllowed="move",w.dataTransfer.setData("text/plain",L)},g=()=>{c.current=null,f(null),p(null),u(null)},N=(b,L)=>{const w=c.current;if(!w)return;const I=ha(e,w,b,L);I!==e&&(d.current=!0,r(I))};return t.jsx("div",{ref:l,className:v("vyre-kanban",o),role:"list","aria-label":"Kanban board",...i,children:e.map(b=>{const L=y===b.id,w=b.color&&b.color!=="default"?b.color:void 0,I=L&&c.current&&x!==null?x:null,A=t.jsx("div",{className:"vyre-kanban__placeholder","aria-hidden":"true"});return t.jsxs("div",{role:"listitem","data-color":w,className:v("vyre-kanban__column",L&&"vyre-kanban__column--over"),onDragOver:T=>{c.current&&(T.preventDefault(),T.dataTransfer.dropEffect="move",m(b.id,b.cards.length))},onDragLeave:T=>{T.currentTarget.contains(T.relatedTarget)||(p(M=>M===b.id?null:M),u(null))},onDrop:T=>{T.preventDefault(),N(b.id,x??b.cards.length),g()},children:[t.jsxs("div",{className:"vyre-kanban__column-header",children:[t.jsx("span",{className:"vyre-kanban__column-title",children:b.title}),t.jsx("span",{className:"vyre-kanban__column-count",children:b.cards.length})]}),t.jsxs("div",{className:"vyre-kanban__cards",children:[b.cards.map((T,M)=>{const B=T.color&&T.color!=="default"?T.color:void 0;return t.jsxs(s.Fragment,{children:[I===M&&A,t.jsx(de,{variant:"outlined","data-color":B,className:v("vyre-kanban__card",h===T.id&&"vyre-kanban__card--dragging",n&&"vyre-kanban__card--clickable"),draggable:!0,role:n?"button":void 0,tabIndex:n?0:void 0,onDragStart:_(b.id,T.id),onDragEnd:g,onDragOver:R=>{if(!c.current)return;R.preventDefault(),R.stopPropagation();const j=R.currentTarget.getBoundingClientRect(),k=R.clientY-j.top>j.height/2;m(b.id,k?M+1:M)},onDrop:R=>{R.preventDefault(),R.stopPropagation(),N(b.id,x??M),g()},onClick:()=>{d.current||n==null||n(T,b)},onKeyDown:R=>{n&&(R.key==="Enter"||R.key===" ")&&(R.preventDefault(),n(T,b))},children:t.jsx(ue,{children:a?a(T,b):t.jsxs(t.Fragment,{children:[t.jsx("div",{className:"vyre-kanban__card-title",children:T.title}),T.description&&t.jsx("div",{className:"vyre-kanban__card-desc",children:T.description})]})})})]},T.id)}),I===b.cards.length&&A,b.cards.length===0&&I===null&&t.jsx("div",{className:"vyre-kanban__empty",children:"Drop cards here"})]})]},b.id)})})});ir.displayName="VyreKanban";function je(e){if(e==null)return null;const r=e instanceof Date?e:new Date(e);return Number.isNaN(r.getTime())?null:r}function ce(e,r){return e.getFullYear()===r.getFullYear()&&e.getMonth()===r.getMonth()&&e.getDate()===r.getDate()}function ba(e){const r=new Date,a=new Date;return a.setDate(r.getDate()-1),ce(e,r)?"Today":ce(e,a)?"Yesterday":new Intl.DateTimeFormat("default",{month:"short",day:"numeric",year:e.getFullYear()===r.getFullYear()?void 0:"numeric"}).format(e)}function pa(e){return new Intl.DateTimeFormat("default",{hour:"numeric",minute:"2-digit"}).format(e)}const xa={sending:"Sending…",sent:"Sent",delivered:"Delivered",read:"Read"};function _a(){return t.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none","aria-hidden":"true",children:[t.jsx("path",{d:"M10 2H5a1.5 1.5 0 0 0-1.5 1.5v11A1.5 1.5 0 0 0 5 16h8a1.5 1.5 0 0 0 1.5-1.5V6.5L10 2z",stroke:"currentColor",strokeWidth:"1.3",strokeLinejoin:"round"}),t.jsx("path",{d:"M10 2v4.5h4.5",stroke:"currentColor",strokeWidth:"1.3",strokeLinejoin:"round"})]})}function ga({attachment:e}){const{kind:r,url:a,name:n,size:o}=e;return r==="image"?t.jsx("a",{className:"vyre-conversation__att vyre-conversation__att--image",href:a,target:"_blank",rel:"noopener noreferrer",children:t.jsx("img",{src:a,alt:n??"image attachment",loading:"lazy"})}):r==="audio"?t.jsx("audio",{className:"vyre-conversation__att vyre-conversation__att--audio",src:a,controls:!0,preload:"none"}):r==="video"?t.jsx("video",{className:"vyre-conversation__att vyre-conversation__att--video",src:a,controls:!0,preload:"none"}):t.jsxs("a",{className:"vyre-conversation__att vyre-conversation__att--file",href:a,target:"_blank",rel:"noopener noreferrer",download:n,children:[t.jsx("span",{className:"vyre-conversation__att-icon",children:t.jsx(_a,{})}),t.jsxs("span",{className:"vyre-conversation__att-info",children:[t.jsx("span",{className:"vyre-conversation__att-name",children:n??"Attachment"}),o&&t.jsx("span",{className:"vyre-conversation__att-size",children:o})]})]})}const lr=s.forwardRef(({value:e,currentUserId:r,composer:a=!1,onSend:n,placeholder:o="Write a message…",typing:i=!1,allowAttachments:l=!1,accept:c,renderMessage:d,renderComposer:h,className:f,...y},p)=>{const[x,u]=s.useState(""),[m,_]=s.useState([]),g=s.useRef(null),N=()=>{const w=x.trim();!w&&m.length===0||(n==null||n(w,m),u(""),_([]))},b=s.useMemo(()=>e.map((w,I)=>{const A=e[I-1],T=e[I+1],M=je(w.timestamp),B=A?je(A.timestamp):null,R=!!M&&(!B||!ce(M,B)),j=!A||A.authorId!==w.authorId||R,k=!T||T.authorId!==w.authorId,D=w.authorId===r;return{msg:w,date:M,showDaySeparator:R,isGroupStart:j,isGroupEnd:k,outgoing:D}}),[e,r]),L={value:x,setValue:u,files:m,setFiles:_,send:N};return t.jsxs("div",{ref:p,className:v("vyre-conversation",f),...y,children:[t.jsxs("div",{className:"vyre-conversation__thread",role:"log","aria-label":"Conversation","aria-live":"polite",children:[b.map(({msg:w,date:I,showDaySeparator:A,isGroupStart:T,isGroupEnd:M,outgoing:B})=>t.jsxs(s.Fragment,{children:[A&&I&&t.jsx("div",{className:"vyre-conversation__day",role:"separator",children:t.jsx("span",{children:ba(I)})}),t.jsxs("div",{className:v("vyre-conversation__row",B?"vyre-conversation__row--out":"vyre-conversation__row--in",M&&"vyre-conversation__row--group-end"),children:[t.jsx("div",{className:"vyre-conversation__avatar",children:!B&&M&&t.jsx(ve,{size:"sm",src:w.authorAvatar,fallback:(w.authorName??w.authorId).slice(0,1).toUpperCase(),alt:w.authorName??w.authorId})}),t.jsxs("div",{className:"vyre-conversation__stack",children:[!B&&T&&w.authorName&&t.jsx("span",{className:"vyre-conversation__author",children:w.authorName}),t.jsx("div",{className:"vyre-conversation__bubble",children:d?d(w,{outgoing:B,isGroupStart:T,isGroupEnd:M}):t.jsxs(t.Fragment,{children:[w.attachments&&w.attachments.length>0&&t.jsx("div",{className:"vyre-conversation__attachments",children:w.attachments.map((R,j)=>t.jsx(ga,{attachment:R},j))}),w.text]})}),M&&t.jsxs("span",{className:"vyre-conversation__meta",children:[I&&pa(I),B&&w.status&&t.jsxs("span",{className:v("vyre-conversation__status",`vyre-conversation__status--${w.status}`),children:[I?" · ":"",xa[w.status]]})]})]})]})]},w.id)),i&&t.jsxs("div",{className:"vyre-conversation__row vyre-conversation__row--in",children:[t.jsx("div",{className:"vyre-conversation__avatar"}),t.jsx("div",{className:"vyre-conversation__stack",children:t.jsxs("div",{className:"vyre-conversation__bubble vyre-conversation__bubble--typing",children:[t.jsx("span",{className:"vyre-conversation__dot"}),t.jsx("span",{className:"vyre-conversation__dot"}),t.jsx("span",{className:"vyre-conversation__dot"}),typeof i=="string"&&t.jsx("span",{className:"vyre-conversation__typing-label",children:i})]})})]})]}),h?h(L):a&&t.jsxs("form",{className:"vyre-conversation__composer",onSubmit:w=>{w.preventDefault(),N()},children:[l&&m.length>0&&t.jsx("div",{className:"vyre-conversation__staged",children:m.map((w,I)=>t.jsxs("span",{className:"vyre-conversation__chip",children:[t.jsx("span",{className:"vyre-conversation__chip-name",children:w.name}),t.jsx("button",{type:"button",className:"vyre-conversation__chip-remove","aria-label":`Remove ${w.name}`,onClick:()=>_(m.filter((A,T)=>T!==I)),children:t.jsx("svg",{width:"10",height:"10",viewBox:"0 0 10 10",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 2l6 6M8 2l-6 6",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round"})})})]},I))}),t.jsxs("div",{className:"vyre-conversation__composer-row",children:[l&&t.jsxs(t.Fragment,{children:[t.jsx("input",{ref:g,type:"file",multiple:!0,accept:c,className:"vyre-conversation__file-input",onChange:w=>{const I=Array.from(w.target.files??[]);I.length&&_([...m,...I]),w.target.value=""}}),t.jsx("button",{type:"button",className:"vyre-conversation__attach","aria-label":"Attach files",onClick:()=>{var w;return(w=g.current)==null?void 0:w.click()},children:t.jsx("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M13.5 6.5l-5.6 5.6a2.5 2.5 0 0 1-3.5-3.5l6-6a3.5 3.5 0 0 1 5 5l-6 6",stroke:"currentColor",strokeWidth:"1.4",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),t.jsx("input",{className:"vyre-conversation__input",value:x,onChange:w=>u(w.target.value),placeholder:o,"aria-label":"Message"}),t.jsx("button",{type:"submit",className:"vyre-conversation__send",disabled:!x.trim()&&m.length===0,"aria-label":"Send message",children:t.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:t.jsx("path",{d:"M2 8l12-5-4.5 12L7 9.5 2 8z",stroke:"currentColor",strokeWidth:"1.4",strokeLinejoin:"round"})})})]})]})]})});lr.displayName="VyreConversation";const cr=s.forwardRef(({as:e="p",size:r="md",weight:a,color:n="default",truncate:o,mono:i,className:l,children:c,...d},h)=>t.jsx(e,{ref:h,className:v("vyre-text",r!=="md"&&`vyre-text--${r}`,a&&`vyre-text--${a}`,n!=="default"&&`vyre-text--${n}`,o&&"vyre-text--truncate",i&&"vyre-text--mono",l),...d,children:c}));cr.displayName="VyreText";const dr=s.forwardRef(({as:e="h2",size:r="md",weight:a="bold",color:n="default",truncate:o,className:i,children:l,...c},d)=>t.jsx(e,{ref:d,className:v("vyre-heading",`vyre-heading--${r}`,a!=="bold"&&`vyre-heading--${a}`,n!=="default"&&`vyre-text--${n}`,o&&"vyre-text--truncate",i),...c,children:l}));dr.displayName="VyreHeading";const ur=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("p",{ref:n,className:v("vyre-lead",e),...a,children:r}));ur.displayName="VyreLead";const mr=s.forwardRef(({block:e,className:r,children:a,...n},o)=>e?t.jsx("pre",{className:v("vyre-code-block",r),...n,children:t.jsx("code",{ref:o,children:a})}):t.jsx("code",{ref:o,className:v("vyre-code",r),...n,children:a}));mr.displayName="VyreCode";const vr=s.forwardRef(({className:e,children:r,...a},n)=>t.jsx("blockquote",{ref:n,className:v("vyre-blockquote",e),...a,children:r}));vr.displayName="VyreBlockquote";const fr=s.createContext({collapsed:!1,toggleCollapsed:()=>{}}),se=()=>s.useContext(fr),yr=s.forwardRef(({defaultCollapsed:e=!1,collapsed:r,onCollapsedChange:a,className:n,children:o},i)=>{const[l,c]=s.useState(e),d=r!==void 0?r:l,h=s.useCallback(()=>{const f=!d;c(f),a==null||a(f)},[d,a]);return t.jsx(fr.Provider,{value:{collapsed:d,toggleCollapsed:h},children:t.jsx("div",{ref:i,className:v("vyre-app-layout",n),children:o})})});yr.displayName="VyreAppLayout";const hr=s.forwardRef(({variant:e="default",className:r,children:a},n)=>{const{collapsed:o}=se();return t.jsx("aside",{ref:n,className:v("vyre-sidebar",o&&"vyre-sidebar--collapsed",e==="floating"&&"vyre-sidebar--floating",r),"data-collapsed":o||void 0,children:a})});hr.displayName="VyreSidebar";const br=s.forwardRef(({logo:e,title:r,className:a,children:n},o)=>t.jsxs("div",{ref:o,className:v("vyre-sidebar__header",a),children:[e&&t.jsx("span",{className:"vyre-sidebar__logo",children:e}),r&&t.jsx("span",{className:"vyre-sidebar__title",children:r}),n]}));br.displayName="VyreSidebarHeader";const pr=s.forwardRef(({className:e,children:r},a)=>t.jsx("div",{ref:a,className:v("vyre-sidebar__content",e),children:r}));pr.displayName="VyreSidebarContent";const xr=s.forwardRef(({label:e,className:r,children:a},n)=>t.jsxs("div",{ref:n,className:v("vyre-sidebar__section",r),children:[e&&t.jsx("div",{className:"vyre-sidebar__section-label",children:e}),a]}));xr.displayName="VyreSidebarSection";const _r=({active:e,icon:r,badge:a,href:n,onClick:o,className:i,children:l})=>{const{collapsed:c}=se(),d=v("vyre-sidebar__item",e&&"vyre-sidebar__item--active",i),h=t.jsxs(t.Fragment,{children:[r&&t.jsx("span",{className:"vyre-sidebar__item-icon",children:r}),t.jsx("span",{className:"vyre-sidebar__item-label",children:l}),a!==void 0&&t.jsx("span",{className:"vyre-sidebar__item-badge",children:a})]});return n?t.jsx("a",{href:n,className:d,"aria-current":e?"page":void 0,title:c?String(l):void 0,children:h}):t.jsx("button",{type:"button",className:d,onClick:o,"aria-pressed":e,title:c?String(l):void 0,children:h})};_r.displayName="VyreSidebarItem";const gr=s.forwardRef(({className:e,children:r},a)=>t.jsx("div",{ref:a,className:v("vyre-sidebar__footer",e),children:r}));gr.displayName="VyreSidebarFooter";const jr=s.forwardRef(({className:e,children:r},a)=>t.jsx("div",{ref:a,className:v("vyre-app-shell",e),children:r}));jr.displayName="VyreAppShell";const wr=s.forwardRef(({className:e,children:r},a)=>t.jsx("header",{ref:a,className:v("vyre-app-bar",e),children:r}));wr.displayName="VyreAppBar";const kr=({className:e})=>{const{collapsed:r,toggleCollapsed:a}=se();return t.jsx("button",{type:"button",className:v("vyre-sidebar-trigger",e),onClick:a,"aria-label":r?"Expand sidebar":"Collapse sidebar","aria-expanded":!r,children:t.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[t.jsx("rect",{x:"2",y:"4",width:"12",height:"1.5",rx:"0.75",fill:"currentColor"}),t.jsx("rect",{x:"2",y:"7.25",width:"8",height:"1.5",rx:"0.75",fill:"currentColor"}),t.jsx("rect",{x:"2",y:"10.5",width:"12",height:"1.5",rx:"0.75",fill:"currentColor"})]})})};kr.displayName="VyreSidebarTrigger";const Nr=s.forwardRef(({className:e,children:r},a)=>t.jsx("div",{ref:a,className:v("vyre-page-content",e),children:r}));Nr.displayName="VyrePageContent";exports.Accordion=Ze;exports.AccordionContent=et;exports.AccordionItem=Qe;exports.AccordionTrigger=Je;exports.Alert=gt;exports.AlertDialog=jt;exports.AppBar=wr;exports.AppLayout=yr;exports.AppShell=jr;exports.Avatar=ve;exports.Badge=ke;exports.Blockquote=vr;exports.Breadcrumb=Rt;exports.BreadcrumbItem=Lt;exports.BreadcrumbLink=Dt;exports.BreadcrumbSeparator=St;exports.Button=we;exports.ButtonGroup=qt;exports.Calendar=ee;exports.Card=de;exports.CardBody=ue;exports.CardFooter=Ce;exports.CardHeader=Ne;exports.Checkbox=tt;exports.Code=mr;exports.Combobox=zt;exports.Command=he;exports.CommandDialog=Kt;exports.CommandEmpty=Pt;exports.CommandGroup=Ot;exports.CommandInput=Wt;exports.CommandItem=Gt;exports.CommandList=Ht;exports.CommandSeparator=Yt;exports.Conversation=lr;exports.DataGrid=Xt;exports.DatePicker=Qt;exports.DateRangePicker=Jt;exports.DropdownCheckboxItem=yt;exports.DropdownItem=ft;exports.DropdownLabel=vt;exports.DropdownMenu=mt;exports.DropdownRadioGroup=ht;exports.DropdownRadioItem=bt;exports.DropdownSeparator=xt;exports.DropdownSub=pt;exports.Field=Re;exports.FieldDescription=De;exports.FieldError=Se;exports.FieldGroup=Me;exports.FieldLabel=Le;exports.FieldSet=Ie;exports.Heading=dr;exports.Input=Te;exports.Item=er;exports.ItemActions=or;exports.ItemContent=ar;exports.ItemDescription=sr;exports.ItemGroup=tr;exports.ItemMedia=rr;exports.ItemTitle=nr;exports.Kanban=ir;exports.Label=ct;exports.Lead=ur;exports.Modal=Ae;exports.ModalBody=Ve;exports.ModalFooter=$e;exports.ModalHeader=Be;exports.PageContent=Nr;exports.Pagination=Mt;exports.Popover=dt;exports.Progress=it;exports.Radio=fe;exports.RadioGroup=at;exports.RichTextEditor=nt;exports.Select=We;exports.Separator=lt;exports.Sheet=wt;exports.SheetBody=Nt;exports.SheetFooter=Ct;exports.SheetHeader=kt;exports.Sidebar=hr;exports.SidebarContent=pr;exports.SidebarFooter=gr;exports.SidebarHeader=br;exports.SidebarItem=_r;exports.SidebarSection=xr;exports.SidebarTrigger=kr;exports.Skeleton=ye;exports.Slider=ot;exports.Switch=st;exports.Tab=Ye;exports.TabList=Ge;exports.TabPanel=qe;exports.TabPanels=Ke;exports.Table=It;exports.TableBody=Et;exports.TableCaption=$t;exports.TableCell=Vt;exports.TableHead=Tt;exports.TableHeader=Bt;exports.TableRow=At;exports.Tabs=Oe;exports.Tag=be;exports.TagGroup=Zt;exports.TagsInput=Ut;exports.Text=cr;exports.Textarea=Ee;exports.ToastProvider=Ar;exports.Tooltip=Ue;exports.cn=v;exports.useAppLayout=se;exports.useToast=Br;
|
package/dist/index.d.ts
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* - Button — Interactive actions and CTAs
|
|
10
10
|
* - Badge — Status labels and indicators
|
|
11
11
|
* - Card — Content containers (+ CardHeader, CardBody, CardFooter)
|
|
12
|
-
* - Field — Form field wrapper
|
|
12
|
+
* - Field — Form field wrapper (props-based) + composable parts (FieldLabel, FieldDescription, FieldError, FieldGroup, FieldSet)
|
|
13
13
|
* - Input — Text input with optional icons
|
|
14
14
|
* - Textarea — Multi-line text input
|
|
15
15
|
* - Modal — Dialog overlay with focus trap (+ ModalHeader, ModalBody, ModalFooter)
|
|
@@ -21,6 +21,8 @@
|
|
|
21
21
|
* - Accordion — Collapsible sections (+ AccordionItem, AccordionTrigger, AccordionContent)
|
|
22
22
|
* - Avatar — User avatar with image fallback and status dot
|
|
23
23
|
* - Checkbox — Checkbox input with indeterminate state
|
|
24
|
+
* - RadioGroup — Controlled single-choice group (+ Radio); options array or composable children
|
|
25
|
+
* - RichTextEditor — Controlled WYSIWYG editor (HTML value); toolbar bold/italic/heading/list/link; zero deps
|
|
24
26
|
* - Switch — Toggle switch (on/off)
|
|
25
27
|
* - Slider — Range input with custom track
|
|
26
28
|
* - Progress — Linear progress bar with indeterminate mode
|
|
@@ -41,6 +43,12 @@
|
|
|
41
43
|
* - DataGrid — Table with built-in column sorting (asc/desc), loading skeletons, empty state
|
|
42
44
|
* - Tag — Standalone display tag/chip: variant, size, onRemove (× button), onClick (interactive)
|
|
43
45
|
* - TagGroup — Read-only container that lays out multiple Tag elements with wrapping + gap
|
|
46
|
+
* - Item — Layout primitive for list/settings rows (+ ItemGroup, ItemMedia, ItemContent, ItemTitle, ItemDescription, ItemActions)
|
|
47
|
+
* - Calendar — Inline date grid; mode single/range/multiple, optional time
|
|
48
|
+
* - DatePicker — Input trigger + popover Calendar (single/range/multiple)
|
|
49
|
+
* - DateRangePicker — Start/end date range picker with dual-month view and preset shortcuts; built on Calendar
|
|
50
|
+
* - Kanban — Controlled board with drag-and-drop cards between columns; native HTML5 DnD, zero deps
|
|
51
|
+
* - Conversation — Controlled chat/inbox thread: grouped bubbles, avatars, day separators, status, optional composer
|
|
44
52
|
*
|
|
45
53
|
* CSS must be imported separately:
|
|
46
54
|
* import "@usevyre/tokens/css"; ← design tokens (required)
|
|
@@ -49,7 +57,7 @@
|
|
|
49
57
|
export { Button } from "./components/Button/Button";
|
|
50
58
|
export { Badge } from "./components/Badge/Badge";
|
|
51
59
|
export { Card, CardHeader, CardBody, CardFooter } from "./components/Card/Card";
|
|
52
|
-
export { Field, Input, Textarea } from "./components/Input/Input";
|
|
60
|
+
export { Field, FieldLabel, FieldDescription, FieldError, FieldGroup, FieldSet, Input, Textarea, } from "./components/Input/Input";
|
|
53
61
|
export { Modal, ModalHeader, ModalBody, ModalFooter } from "./components/Modal/Modal";
|
|
54
62
|
export { ToastProvider, useToast } from "./components/Toast/Toast";
|
|
55
63
|
export { Select } from "./components/Select/Select";
|
|
@@ -58,6 +66,8 @@ export { Tooltip } from "./components/Tooltip/Tooltip";
|
|
|
58
66
|
export { Accordion, AccordionItem, AccordionTrigger, AccordionContent } from "./components/Accordion/Accordion";
|
|
59
67
|
export { Avatar } from "./components/Avatar/Avatar";
|
|
60
68
|
export { Checkbox } from "./components/Checkbox/Checkbox";
|
|
69
|
+
export { RadioGroup, Radio } from "./components/Radio/Radio";
|
|
70
|
+
export { RichTextEditor } from "./components/RichTextEditor/RichTextEditor";
|
|
61
71
|
export { Switch } from "./components/Switch/Switch";
|
|
62
72
|
export { Slider } from "./components/Slider/Slider";
|
|
63
73
|
export { Progress } from "./components/Progress/Progress";
|
|
@@ -78,7 +88,12 @@ export { Combobox } from "./components/Combobox/Combobox";
|
|
|
78
88
|
export { DataGrid } from "./components/DataGrid/DataGrid";
|
|
79
89
|
export { Tag } from "./components/Tag/Tag";
|
|
80
90
|
export { TagGroup } from "./components/Tag/TagGroup";
|
|
81
|
-
export { Calendar
|
|
91
|
+
export { Calendar } from "./components/Calendar/Calendar";
|
|
92
|
+
export { DatePicker } from "./components/Calendar/DatePicker";
|
|
93
|
+
export { DateRangePicker } from "./components/DateRangePicker/DateRangePicker";
|
|
94
|
+
export { Item, ItemGroup, ItemMedia, ItemContent, ItemTitle, ItemDescription, ItemActions, } from "./components/Item/Item";
|
|
95
|
+
export { Kanban } from "./components/Kanban/Kanban";
|
|
96
|
+
export { Conversation } from "./components/Conversation/Conversation";
|
|
82
97
|
export type { CalendarProps, CalendarSingleProps, CalendarRangeProps, CalendarMultipleProps, CalendarBaseProps, DatePickerProps, CalendarMode, } from "./components/Calendar/Calendar";
|
|
83
98
|
export { Text, Heading, Lead, Code, Blockquote } from "./components/Typography/Typography";
|
|
84
99
|
export type { TextProps, HeadingProps, LeadProps, CodeProps, BlockquoteProps, } from "./components/Typography/Typography";
|
|
@@ -87,7 +102,7 @@ export type { AppLayoutProps, AppShellProps, AppBarProps, PageContentProps, Side
|
|
|
87
102
|
export type { ButtonProps } from "./components/Button/Button";
|
|
88
103
|
export type { BadgeProps } from "./components/Badge/Badge";
|
|
89
104
|
export type { CardProps, CardSectionProps } from "./components/Card/Card";
|
|
90
|
-
export type { FieldProps, InputProps, TextareaProps } from "./components/Input/Input";
|
|
105
|
+
export type { FieldProps, FieldLabelProps, FieldDescriptionProps, FieldErrorProps, FieldGroupProps, FieldSetProps, InputProps, TextareaProps, } from "./components/Input/Input";
|
|
91
106
|
export type { ModalProps, ModalSectionProps, ModalSize } from "./components/Modal/Modal";
|
|
92
107
|
export type { ToastInput, ToastVariant } from "./components/Toast/Toast";
|
|
93
108
|
export type { SelectProps, SelectOption, SelectSize } from "./components/Select/Select";
|
|
@@ -96,6 +111,8 @@ export type { TooltipProps, TooltipPlacement } from "./components/Tooltip/Toolti
|
|
|
96
111
|
export type { AccordionProps, AccordionItemProps, AccordionTriggerProps, AccordionContentProps } from "./components/Accordion/Accordion";
|
|
97
112
|
export type { AvatarProps } from "./components/Avatar/Avatar";
|
|
98
113
|
export type { CheckboxProps } from "./components/Checkbox/Checkbox";
|
|
114
|
+
export type { RadioGroupProps, RadioProps, RadioOption, } from "./components/Radio/Radio";
|
|
115
|
+
export type { RichTextEditorProps, RichTextTool, } from "./components/RichTextEditor/RichTextEditor";
|
|
99
116
|
export type { SwitchProps } from "./components/Switch/Switch";
|
|
100
117
|
export type { SliderProps } from "./components/Slider/Slider";
|
|
101
118
|
export type { ProgressProps } from "./components/Progress/Progress";
|
|
@@ -115,5 +132,9 @@ export type { ComboboxProps, ComboboxOption } from "./components/Combobox/Combob
|
|
|
115
132
|
export type { DataGridProps, DataGridColumn } from "./components/DataGrid/DataGrid";
|
|
116
133
|
export type { TagProps, TagVariant, TagSize } from "./components/Tag/Tag";
|
|
117
134
|
export type { TagGroupProps, TagGroupGap } from "./components/Tag/TagGroup";
|
|
135
|
+
export type { ItemProps, ItemGroupProps, ItemSectionProps, } from "./components/Item/Item";
|
|
136
|
+
export type { KanbanProps, KanbanColumn, KanbanCard, } from "./components/Kanban/Kanban";
|
|
137
|
+
export type { ConversationProps, ConversationMessage, ConversationStatus, ConversationMessageMeta, ConversationComposerApi, ConversationAttachment, ConversationAttachmentKind, } from "./components/Conversation/Conversation";
|
|
138
|
+
export type { DateRangePickerProps, DateRange, DateRangePreset, } from "./components/DateRangePicker/DateRangePicker";
|
|
118
139
|
export type { Variant, Size, FieldState, BadgeVariant, BaseProps } from "./types";
|
|
119
140
|
export { cn } from "./utils/cn";
|