1import{a as e,i as t,n,s as r,t as i}from"./utils-Oy7PmJWG.js";var a=r(e(),1);function o(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function s(...e){return t=>{let n=!1,r=e.map(e=>{let r=o(e,t);return!n&&typeof r==`function`&&(n=!0),r});if(n)return()=>{for(let t=0;t<r.length;t++){let n=r[t];typeof n==`function`?n():o(e[t],null)}}}}function c(...e){return a.useCallback(s(...e),e)}function l(e){let t=a.forwardRef((t,n)=>{let{children:r,...i}=t,o=null,s=!1,l=[];_(r)&&typeof x==`function`&&(r=x(r._payload)),a.Children.forEach(r,e=>{if(h(e)){s=!0;let t=e,n=`child`in t.props?t.props.child:t.props.children;_(n)&&typeof x==`function`&&(n=x(n._payload)),o=f(t,n),l.push(o?.props?.children)}else l.push(e)}),o?o=a.cloneElement(o,void 0,l):!s&&a.Children.count(r)===1&&a.isValidElement(r)&&(o=r);let u=o?m(o):void 0,d=c(n,u);if(!o){if(r||r===0)throw Error(s?b(e):y(e));return r}let g=p(i,o.props??{});return o.type!==a.Fragment&&(g.ref=n?d:u),a.cloneElement(o,g)});return t.displayName=`${e}.Slot`,t}var u=l(`Slot`),d=Symbol.for(`radix.slottable`),f=(e,t)=>{if(`child`in e.props){let t=e.props.child;return a.isValidElement(t)?a.cloneElement(t,void 0,e.props.children(t.props.children)):null}return a.isValidElement(t)?t:null};function p(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}function m(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function h(e){return a.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===d}var g=Symbol.for(`react.lazy`);function _(e){return typeof e==`object`&&!!e&&`$$typeof`in e&&e.$$typeof===g&&`_payload`in e&&v(e._payload)}function v(e){return typeof e==`object`&&!!e&&`then`in e}var y=e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,b=e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,x=a.use,S=e=>typeof e==`boolean`?`${e}`:e===0?`0`:e,C=n,w=(e,t)=>n=>{if(t?.variants==null)return C(e,n?.class,n?.className);let{variants:r,defaultVariants:i}=t,a=Object.keys(r).map(e=>{let t=n?.[e],a=i?.[e];if(t===null)return null;let o=S(t)||S(a);return r[e][o]}),o=n&&Object.entries(n).reduce((e,t)=>{let[n,r]=t;return r===void 0||(e[n]=r),e},{});return C(e,a,t?.compoundVariants?.reduce((e,t)=>{let{class:n,className:r,...a}=t;return Object.entries(a).every(e=>{let[t,n]=e;return Array.isArray(n)?n.includes({...i,...o}[t]):{...i,...o}[t]===n})?[...e,n,r]:e},[]),n?.class,n?.className)},T=t(),E=w(`inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium cursor-pointer transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 disabled:cursor-not-allowed [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0`,{variants:{variant:{default:`bg-primary text-primary-foreground shadow hover:bg-primary/90 text-white`,destructive:`bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90 text-white`,outline:`border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground text-white`,secondary:`bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80`,ghost:`hover:bg-accent hover:text-accent-foreground`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-9 px-4 py-2`,sm:`h-8 rounded-md px-3 text-xs`,lg:`h-10 rounded-md px-8`,icon:`h-9 w-9`}},defaultVariants:{variant:`default`,size:`default`}}),D=a.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...a},o)=>(0,T.jsx)(r?u:`button`,{className:i(E({variant:t,size:n,className:e})),ref:o,...a}));D.displayName=`Button`;export{c as i,w as n,l as r,D as t};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.