UNPKG

@starter-ui/core

Version:

This is a UI Components built with the utility classes from Tailwind CSS.

105 lines (103 loc) 105 kB
(function($,g){typeof exports=="object"&&typeof module<"u"?g(exports,require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","react-dom"],g):($=typeof globalThis<"u"?globalThis:$||self,g($["@starter-ui/core"]={},$.react,$.ReactDOM))})(this,function($,g,He){"use strict";var ze={exports:{}},xe={};/** * @license React * react-jsx-runtime.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Qe;function zr(){if(Qe)return xe;Qe=1;var e=g,r=Symbol.for("react.element"),n=Symbol.for("react.fragment"),s=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function c(l,d,h){var p,x={},j=null,C=null;h!==void 0&&(j=""+h),d.key!==void 0&&(j=""+d.key),d.ref!==void 0&&(C=d.ref);for(p in d)s.call(d,p)&&!a.hasOwnProperty(p)&&(x[p]=d[p]);if(l&&l.defaultProps)for(p in d=l.defaultProps,d)x[p]===void 0&&(x[p]=d[p]);return{$$typeof:r,type:l,key:j,ref:C,props:x,_owner:i.current}}return xe.Fragment=n,xe.jsx=c,xe.jsxs=c,xe}var ve={};/** * @license React * react-jsx-runtime.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var er;function Rr(){return er||(er=1,process.env.NODE_ENV!=="production"&&function(){var e=g,r=Symbol.for("react.element"),n=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),c=Symbol.for("react.provider"),l=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),x=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),C=Symbol.for("react.offscreen"),k=Symbol.iterator,b="@@iterator";function m(o){if(o===null||typeof o!="object")return null;var f=k&&o[k]||o[b];return typeof f=="function"?f:null}var w=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function y(o){{for(var f=arguments.length,v=new Array(f>1?f-1:0),_=1;_<f;_++)v[_-1]=arguments[_];T("error",o,v)}}function T(o,f,v){{var _=w.ReactDebugCurrentFrame,A=_.getStackAddendum();A!==""&&(f+="%s",v=v.concat([A]));var L=v.map(function(z){return String(z)});L.unshift("Warning: "+f),Function.prototype.apply.call(console[o],console,L)}}var E=!1,O=!1,V=!1,U=!1,re=!1,B;B=Symbol.for("react.module.reference");function Z(o){return!!(typeof o=="string"||typeof o=="function"||o===s||o===a||re||o===i||o===h||o===p||U||o===C||E||O||V||typeof o=="object"&&o!==null&&(o.$$typeof===j||o.$$typeof===x||o.$$typeof===c||o.$$typeof===l||o.$$typeof===d||o.$$typeof===B||o.getModuleId!==void 0))}function W(o,f,v){var _=o.displayName;if(_)return _;var A=f.displayName||f.name||"";return A!==""?v+"("+A+")":v}function N(o){return o.displayName||"Context"}function G(o){if(o==null)return null;if(typeof o.tag=="number"&&y("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof o=="function")return o.displayName||o.name||null;if(typeof o=="string")return o;switch(o){case s:return"Fragment";case n:return"Portal";case a:return"Profiler";case i:return"StrictMode";case h:return"Suspense";case p:return"SuspenseList"}if(typeof o=="object")switch(o.$$typeof){case l:var f=o;return N(f)+".Consumer";case c:var v=o;return N(v._context)+".Provider";case d:return W(o,o.render,"ForwardRef");case x:var _=o.displayName||null;return _!==null?_:G(o.type)||"Memo";case j:{var A=o,L=A._payload,z=A._init;try{return G(z(L))}catch{return null}}}return null}var F=Object.assign,Q=0,oe,le,R,X,P,M,ee;function he(){}he.__reactDisabledLog=!0;function dn(){{if(Q===0){oe=console.log,le=console.info,R=console.warn,X=console.error,P=console.group,M=console.groupCollapsed,ee=console.groupEnd;var o={configurable:!0,enumerable:!0,value:he,writable:!0};Object.defineProperties(console,{info:o,log:o,warn:o,error:o,group:o,groupCollapsed:o,groupEnd:o})}Q++}}function fn(){{if(Q--,Q===0){var o={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:F({},o,{value:oe}),info:F({},o,{value:le}),warn:F({},o,{value:R}),error:F({},o,{value:X}),group:F({},o,{value:P}),groupCollapsed:F({},o,{value:M}),groupEnd:F({},o,{value:ee})})}Q<0&&y("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var Ve=w.ReactCurrentDispatcher,Ge;function Pe(o,f,v){{if(Ge===void 0)try{throw Error()}catch(A){var _=A.stack.trim().match(/\n( *(at )?)/);Ge=_&&_[1]||""}return` `+Ge+o}}var Ke=!1,Ie;{var pn=typeof WeakMap=="function"?WeakMap:Map;Ie=new pn}function vr(o,f){if(!o||Ke)return"";{var v=Ie.get(o);if(v!==void 0)return v}var _;Ke=!0;var A=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var L;L=Ve.current,Ve.current=null,dn();try{if(f){var z=function(){throw Error()};if(Object.defineProperty(z.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(z,[])}catch(H){_=H}Reflect.construct(o,[],z)}else{try{z.call()}catch(H){_=H}o.call(z.prototype)}}else{try{throw Error()}catch(H){_=H}o()}}catch(H){if(H&&_&&typeof H.stack=="string"){for(var I=H.stack.split(` `),J=_.stack.split(` `),K=I.length-1,Y=J.length-1;K>=1&&Y>=0&&I[K]!==J[Y];)Y--;for(;K>=1&&Y>=0;K--,Y--)if(I[K]!==J[Y]){if(K!==1||Y!==1)do if(K--,Y--,Y<0||I[K]!==J[Y]){var te=` `+I[K].replace(" at new "," at ");return o.displayName&&te.includes("<anonymous>")&&(te=te.replace("<anonymous>",o.displayName)),typeof o=="function"&&Ie.set(o,te),te}while(K>=1&&Y>=0);break}}}finally{Ke=!1,Ve.current=L,fn(),Error.prepareStackTrace=A}var me=o?o.displayName||o.name:"",de=me?Pe(me):"";return typeof o=="function"&&Ie.set(o,de),de}function gn(o,f,v){return vr(o,!1)}function hn(o){var f=o.prototype;return!!(f&&f.isReactComponent)}function $e(o,f,v){if(o==null)return"";if(typeof o=="function")return vr(o,hn(o));if(typeof o=="string")return Pe(o);switch(o){case h:return Pe("Suspense");case p:return Pe("SuspenseList")}if(typeof o=="object")switch(o.$$typeof){case d:return gn(o.render);case x:return $e(o.type,f,v);case j:{var _=o,A=_._payload,L=_._init;try{return $e(L(A),f,v)}catch{}}}return""}var _e=Object.prototype.hasOwnProperty,yr={},wr=w.ReactDebugCurrentFrame;function Te(o){if(o){var f=o._owner,v=$e(o.type,o._source,f?f.type:null);wr.setExtraStackFrame(v)}else wr.setExtraStackFrame(null)}function bn(o,f,v,_,A){{var L=Function.call.bind(_e);for(var z in o)if(L(o,z)){var I=void 0;try{if(typeof o[z]!="function"){var J=Error((_||"React class")+": "+v+" type `"+z+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[z]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw J.name="Invariant Violation",J}I=o[z](f,z,_,v,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(K){I=K}I&&!(I instanceof Error)&&(Te(A),y("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",_||"React class",v,z,typeof I),Te(null)),I instanceof Error&&!(I.message in yr)&&(yr[I.message]=!0,Te(A),y("Failed %s type: %s",v,I.message),Te(null))}}}var mn=Array.isArray;function Ue(o){return mn(o)}function xn(o){{var f=typeof Symbol=="function"&&Symbol.toStringTag,v=f&&o[Symbol.toStringTag]||o.constructor.name||"Object";return v}}function vn(o){try{return jr(o),!1}catch{return!0}}function jr(o){return""+o}function kr(o){if(vn(o))return y("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",xn(o)),jr(o)}var Ne=w.ReactCurrentOwner,yn={key:!0,ref:!0,__self:!0,__source:!0},_r,Nr,Ye;Ye={};function wn(o){if(_e.call(o,"ref")){var f=Object.getOwnPropertyDescriptor(o,"ref").get;if(f&&f.isReactWarning)return!1}return o.ref!==void 0}function jn(o){if(_e.call(o,"key")){var f=Object.getOwnPropertyDescriptor(o,"key").get;if(f&&f.isReactWarning)return!1}return o.key!==void 0}function kn(o,f){if(typeof o.ref=="string"&&Ne.current&&f&&Ne.current.stateNode!==f){var v=G(Ne.current.type);Ye[v]||(y('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',G(Ne.current.type),o.ref),Ye[v]=!0)}}function _n(o,f){{var v=function(){_r||(_r=!0,y("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",f))};v.isReactWarning=!0,Object.defineProperty(o,"key",{get:v,configurable:!0})}}function Nn(o,f){{var v=function(){Nr||(Nr=!0,y("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",f))};v.isReactWarning=!0,Object.defineProperty(o,"ref",{get:v,configurable:!0})}}var Cn=function(o,f,v,_,A,L,z){var I={$$typeof:r,type:o,key:f,ref:v,props:z,_owner:L};return I._store={},Object.defineProperty(I._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(I,"_self",{configurable:!1,enumerable:!1,writable:!1,value:_}),Object.defineProperty(I,"_source",{configurable:!1,enumerable:!1,writable:!1,value:A}),Object.freeze&&(Object.freeze(I.props),Object.freeze(I)),I};function Sn(o,f,v,_,A){{var L,z={},I=null,J=null;v!==void 0&&(kr(v),I=""+v),jn(f)&&(kr(f.key),I=""+f.key),wn(f)&&(J=f.ref,kn(f,A));for(L in f)_e.call(f,L)&&!yn.hasOwnProperty(L)&&(z[L]=f[L]);if(o&&o.defaultProps){var K=o.defaultProps;for(L in K)z[L]===void 0&&(z[L]=K[L])}if(I||J){var Y=typeof o=="function"?o.displayName||o.name||"Unknown":o;I&&_n(z,Y),J&&Nn(z,Y)}return Cn(o,I,J,A,_,Ne.current,z)}}var qe=w.ReactCurrentOwner,Cr=w.ReactDebugCurrentFrame;function be(o){if(o){var f=o._owner,v=$e(o.type,o._source,f?f.type:null);Cr.setExtraStackFrame(v)}else Cr.setExtraStackFrame(null)}var Xe;Xe=!1;function Je(o){return typeof o=="object"&&o!==null&&o.$$typeof===r}function Sr(){{if(qe.current){var o=G(qe.current.type);if(o)return` Check the render method of \``+o+"`."}return""}}function En(o){return""}var Er={};function Pn(o){{var f=Sr();if(!f){var v=typeof o=="string"?o:o.displayName||o.name;v&&(f=` Check the top-level render call using <`+v+">.")}return f}}function Pr(o,f){{if(!o._store||o._store.validated||o.key!=null)return;o._store.validated=!0;var v=Pn(f);if(Er[v])return;Er[v]=!0;var _="";o&&o._owner&&o._owner!==qe.current&&(_=" It was passed a child from "+G(o._owner.type)+"."),be(o),y('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',v,_),be(null)}}function Ir(o,f){{if(typeof o!="object")return;if(Ue(o))for(var v=0;v<o.length;v++){var _=o[v];Je(_)&&Pr(_,f)}else if(Je(o))o._store&&(o._store.validated=!0);else if(o){var A=m(o);if(typeof A=="function"&&A!==o.entries)for(var L=A.call(o),z;!(z=L.next()).done;)Je(z.value)&&Pr(z.value,f)}}}function In(o){{var f=o.type;if(f==null||typeof f=="string")return;var v;if(typeof f=="function")v=f.propTypes;else if(typeof f=="object"&&(f.$$typeof===d||f.$$typeof===x))v=f.propTypes;else return;if(v){var _=G(f);bn(v,o.props,"prop",_,o)}else if(f.PropTypes!==void 0&&!Xe){Xe=!0;var A=G(f);y("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",A||"Unknown")}typeof f.getDefaultProps=="function"&&!f.getDefaultProps.isReactClassApproved&&y("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function $n(o){{for(var f=Object.keys(o.props),v=0;v<f.length;v++){var _=f[v];if(_!=="children"&&_!=="key"){be(o),y("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",_),be(null);break}}o.ref!==null&&(be(o),y("Invalid attribute `ref` supplied to `React.Fragment`."),be(null))}}var $r={};function Tr(o,f,v,_,A,L){{var z=Z(o);if(!z){var I="";(o===void 0||typeof o=="object"&&o!==null&&Object.keys(o).length===0)&&(I+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var J=En();J?I+=J:I+=Sr();var K;o===null?K="null":Ue(o)?K="array":o!==void 0&&o.$$typeof===r?(K="<"+(G(o.type)||"Unknown")+" />",I=" Did you accidentally export a JSX literal instead of a component?"):K=typeof o,y("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",K,I)}var Y=Sn(o,f,v,A,L);if(Y==null)return Y;if(z){var te=f.children;if(te!==void 0)if(_)if(Ue(te)){for(var me=0;me<te.length;me++)Ir(te[me],o);Object.freeze&&Object.freeze(te)}else y("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Ir(te,o)}if(_e.call(f,"key")){var de=G(o),H=Object.keys(f).filter(function(On){return On!=="key"}),Ze=H.length>0?"{key: someKey, "+H.join(": ..., ")+": ...}":"{key: someKey}";if(!$r[de+Ze]){var An=H.length>0?"{"+H.join(": ..., ")+": ...}":"{}";y(`A props object containing a "key" prop is being spread into JSX: let props = %s; <%s {...props} /> React keys must be passed directly to JSX without using spread: let props = %s; <%s key={someKey} {...props} />`,Ze,de,An,de),$r[de+Ze]=!0}}return o===s?$n(Y):In(Y),Y}}function Tn(o,f,v){return Tr(o,f,v,!0)}function zn(o,f,v){return Tr(o,f,v,!1)}var Rn=zn,Mn=Tn;ve.Fragment=s,ve.jsx=Rn,ve.jsxs=Mn}()),ve}process.env.NODE_ENV==="production"?ze.exports=zr():ze.exports=Rr();var t=ze.exports;function rr(e){var r,n,s="";if(typeof e=="string"||typeof e=="number")s+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(r=0;r<i;r++)e[r]&&(n=rr(e[r]))&&(s&&(s+=" "),s+=n)}else for(n in e)e[n]&&(s&&(s+=" "),s+=n);return s}function Mr(){for(var e,r,n=0,s="",i=arguments.length;n<i;n++)(e=arguments[n])&&(r=rr(e))&&(s&&(s+=" "),s+=r);return s}const Re="-",Ar=e=>{const r=Lr(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:s}=e;return{getClassGroupId:c=>{const l=c.split(Re);return l[0]===""&&l.length!==1&&l.shift(),tr(l,r)||Or(c)},getConflictingClassGroupIds:(c,l)=>{const d=n[c]||[];return l&&s[c]?[...d,...s[c]]:d}}},tr=(e,r)=>{var c;if(e.length===0)return r.classGroupId;const n=e[0],s=r.nextPart.get(n),i=s?tr(e.slice(1),s):void 0;if(i)return i;if(r.validators.length===0)return;const a=e.join(Re);return(c=r.validators.find(({validator:l})=>l(a)))==null?void 0:c.classGroupId},sr=/^\[(.+)\]$/,Or=e=>{if(sr.test(e)){const r=sr.exec(e)[1],n=r==null?void 0:r.substring(0,r.indexOf(":"));if(n)return"arbitrary.."+n}},Lr=e=>{const{theme:r,prefix:n}=e,s={nextPart:new Map,validators:[]};return Dr(Object.entries(e.classGroups),n).forEach(([a,c])=>{Me(c,s,a,r)}),s},Me=(e,r,n,s)=>{e.forEach(i=>{if(typeof i=="string"){const a=i===""?r:nr(r,i);a.classGroupId=n;return}if(typeof i=="function"){if(Fr(i)){Me(i(s),r,n,s);return}r.validators.push({validator:i,classGroupId:n});return}Object.entries(i).forEach(([a,c])=>{Me(c,nr(r,a),n,s)})})},nr=(e,r)=>{let n=e;return r.split(Re).forEach(s=>{n.nextPart.has(s)||n.nextPart.set(s,{nextPart:new Map,validators:[]}),n=n.nextPart.get(s)}),n},Fr=e=>e.isThemeGetter,Dr=(e,r)=>r?e.map(([n,s])=>{const i=s.map(a=>typeof a=="string"?r+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([c,l])=>[r+c,l])):a);return[n,i]}):e,Br=e=>{if(e<1)return{get:()=>{},set:()=>{}};let r=0,n=new Map,s=new Map;const i=(a,c)=>{n.set(a,c),r++,r>e&&(r=0,s=n,n=new Map)};return{get(a){let c=n.get(a);if(c!==void 0)return c;if((c=s.get(a))!==void 0)return i(a,c),c},set(a,c){n.has(a)?n.set(a,c):i(a,c)}}},or="!",Wr=e=>{const{separator:r,experimentalParseClassName:n}=e,s=r.length===1,i=r[0],a=r.length,c=l=>{const d=[];let h=0,p=0,x;for(let m=0;m<l.length;m++){let w=l[m];if(h===0){if(w===i&&(s||l.slice(m,m+a)===r)){d.push(l.slice(p,m)),p=m+a;continue}if(w==="/"){x=m;continue}}w==="["?h++:w==="]"&&h--}const j=d.length===0?l:l.substring(p),C=j.startsWith(or),k=C?j.substring(1):j,b=x&&x>p?x-p:void 0;return{modifiers:d,hasImportantModifier:C,baseClassName:k,maybePostfixModifierPosition:b}};return n?l=>n({className:l,parseClassName:c}):c},Vr=e=>{if(e.length<=1)return e;const r=[];let n=[];return e.forEach(s=>{s[0]==="["?(r.push(...n.sort(),s),n=[]):n.push(s)}),r.push(...n.sort()),r},Gr=e=>({cache:Br(e.cacheSize),parseClassName:Wr(e),...Ar(e)}),Kr=/\s+/,Ur=(e,r)=>{const{parseClassName:n,getClassGroupId:s,getConflictingClassGroupIds:i}=r,a=[],c=e.trim().split(Kr);let l="";for(let d=c.length-1;d>=0;d-=1){const h=c[d],{modifiers:p,hasImportantModifier:x,baseClassName:j,maybePostfixModifierPosition:C}=n(h);let k=!!C,b=s(k?j.substring(0,C):j);if(!b){if(!k){l=h+(l.length>0?" "+l:l);continue}if(b=s(j),!b){l=h+(l.length>0?" "+l:l);continue}k=!1}const m=Vr(p).join(":"),w=x?m+or:m,y=w+b;if(a.includes(y))continue;a.push(y);const T=i(b,k);for(let E=0;E<T.length;++E){const O=T[E];a.push(w+O)}l=h+(l.length>0?" "+l:l)}return l};function Yr(){let e=0,r,n,s="";for(;e<arguments.length;)(r=arguments[e++])&&(n=ar(r))&&(s&&(s+=" "),s+=n);return s}const ar=e=>{if(typeof e=="string")return e;let r,n="";for(let s=0;s<e.length;s++)e[s]&&(r=ar(e[s]))&&(n&&(n+=" "),n+=r);return n};function qr(e,...r){let n,s,i,a=c;function c(d){const h=r.reduce((p,x)=>x(p),e());return n=Gr(h),s=n.cache.get,i=n.cache.set,a=l,l(d)}function l(d){const h=s(d);if(h)return h;const p=Ur(d,n);return i(d,p),p}return function(){return a(Yr.apply(null,arguments))}}const D=e=>{const r=n=>n[e]||[];return r.isThemeGetter=!0,r},lr=/^\[(?:([a-z-]+):)?(.+)\]$/i,Xr=/^\d+\/\d+$/,Jr=new Set(["px","full","screen"]),Zr=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Hr=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Qr=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,et=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,rt=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,ae=e=>fe(e)||Jr.has(e)||Xr.test(e),ce=e=>pe(e,"length",it),fe=e=>!!e&&!Number.isNaN(Number(e)),Ae=e=>pe(e,"number",fe),ye=e=>!!e&&Number.isInteger(Number(e)),tt=e=>e.endsWith("%")&&fe(e.slice(0,-1)),S=e=>lr.test(e),ie=e=>Zr.test(e),st=new Set(["length","size","percentage"]),nt=e=>pe(e,st,cr),ot=e=>pe(e,"position",cr),at=new Set(["image","url"]),lt=e=>pe(e,at,dt),ct=e=>pe(e,"",ut),we=()=>!0,pe=(e,r,n)=>{const s=lr.exec(e);return s?s[1]?typeof r=="string"?s[1]===r:r.has(s[1]):n(s[2]):!1},it=e=>Hr.test(e)&&!Qr.test(e),cr=()=>!1,ut=e=>et.test(e),dt=e=>rt.test(e),ft=qr(()=>{const e=D("colors"),r=D("spacing"),n=D("blur"),s=D("brightness"),i=D("borderColor"),a=D("borderRadius"),c=D("borderSpacing"),l=D("borderWidth"),d=D("contrast"),h=D("grayscale"),p=D("hueRotate"),x=D("invert"),j=D("gap"),C=D("gradientColorStops"),k=D("gradientColorStopPositions"),b=D("inset"),m=D("margin"),w=D("opacity"),y=D("padding"),T=D("saturate"),E=D("scale"),O=D("sepia"),V=D("skew"),U=D("space"),re=D("translate"),B=()=>["auto","contain","none"],Z=()=>["auto","hidden","clip","visible","scroll"],W=()=>["auto",S,r],N=()=>[S,r],G=()=>["",ae,ce],F=()=>["auto",fe,S],Q=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],oe=()=>["solid","dashed","dotted","double","none"],le=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],R=()=>["start","end","center","between","around","evenly","stretch"],X=()=>["","0",S],P=()=>["auto","avoid","all","avoid-page","page","left","right","column"],M=()=>[fe,S];return{cacheSize:500,separator:":",theme:{colors:[we],spacing:[ae,ce],blur:["none","",ie,S],brightness:M(),borderColor:[e],borderRadius:["none","","full",ie,S],borderSpacing:N(),borderWidth:G(),contrast:M(),grayscale:X(),hueRotate:M(),invert:X(),gap:N(),gradientColorStops:[e],gradientColorStopPositions:[tt,ce],inset:W(),margin:W(),opacity:M(),padding:N(),saturate:M(),scale:M(),sepia:X(),skew:M(),space:N(),translate:N()},classGroups:{aspect:[{aspect:["auto","square","video",S]}],container:["container"],columns:[{columns:[ie]}],"break-after":[{"break-after":P()}],"break-before":[{"break-before":P()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...Q(),S]}],overflow:[{overflow:Z()}],"overflow-x":[{"overflow-x":Z()}],"overflow-y":[{"overflow-y":Z()}],overscroll:[{overscroll:B()}],"overscroll-x":[{"overscroll-x":B()}],"overscroll-y":[{"overscroll-y":B()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[b]}],"inset-x":[{"inset-x":[b]}],"inset-y":[{"inset-y":[b]}],start:[{start:[b]}],end:[{end:[b]}],top:[{top:[b]}],right:[{right:[b]}],bottom:[{bottom:[b]}],left:[{left:[b]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",ye,S]}],basis:[{basis:W()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",S]}],grow:[{grow:X()}],shrink:[{shrink:X()}],order:[{order:["first","last","none",ye,S]}],"grid-cols":[{"grid-cols":[we]}],"col-start-end":[{col:["auto",{span:["full",ye,S]},S]}],"col-start":[{"col-start":F()}],"col-end":[{"col-end":F()}],"grid-rows":[{"grid-rows":[we]}],"row-start-end":[{row:["auto",{span:[ye,S]},S]}],"row-start":[{"row-start":F()}],"row-end":[{"row-end":F()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",S]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",S]}],gap:[{gap:[j]}],"gap-x":[{"gap-x":[j]}],"gap-y":[{"gap-y":[j]}],"justify-content":[{justify:["normal",...R()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...R(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...R(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[y]}],px:[{px:[y]}],py:[{py:[y]}],ps:[{ps:[y]}],pe:[{pe:[y]}],pt:[{pt:[y]}],pr:[{pr:[y]}],pb:[{pb:[y]}],pl:[{pl:[y]}],m:[{m:[m]}],mx:[{mx:[m]}],my:[{my:[m]}],ms:[{ms:[m]}],me:[{me:[m]}],mt:[{mt:[m]}],mr:[{mr:[m]}],mb:[{mb:[m]}],ml:[{ml:[m]}],"space-x":[{"space-x":[U]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[U]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",S,r]}],"min-w":[{"min-w":[S,r,"min","max","fit"]}],"max-w":[{"max-w":[S,r,"none","full","min","max","fit","prose",{screen:[ie]},ie]}],h:[{h:[S,r,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[S,r,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[S,r,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[S,r,"auto","min","max","fit"]}],"font-size":[{text:["base",ie,ce]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Ae]}],"font-family":[{font:[we]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",S]}],"line-clamp":[{"line-clamp":["none",fe,Ae]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",ae,S]}],"list-image":[{"list-image":["none",S]}],"list-style-type":[{list:["none","disc","decimal",S]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[w]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[w]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...oe(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",ae,ce]}],"underline-offset":[{"underline-offset":["auto",ae,S]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:N()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",S]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",S]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[w]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...Q(),ot]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",nt]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},lt]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[k]}],"gradient-via-pos":[{via:[k]}],"gradient-to-pos":[{to:[k]}],"gradient-from":[{from:[C]}],"gradient-via":[{via:[C]}],"gradient-to":[{to:[C]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[l]}],"border-w-x":[{"border-x":[l]}],"border-w-y":[{"border-y":[l]}],"border-w-s":[{"border-s":[l]}],"border-w-e":[{"border-e":[l]}],"border-w-t":[{"border-t":[l]}],"border-w-r":[{"border-r":[l]}],"border-w-b":[{"border-b":[l]}],"border-w-l":[{"border-l":[l]}],"border-opacity":[{"border-opacity":[w]}],"border-style":[{border:[...oe(),"hidden"]}],"divide-x":[{"divide-x":[l]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[l]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[w]}],"divide-style":[{divide:oe()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...oe()]}],"outline-offset":[{"outline-offset":[ae,S]}],"outline-w":[{outline:[ae,ce]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:G()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[w]}],"ring-offset-w":[{"ring-offset":[ae,ce]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",ie,ct]}],"shadow-color":[{shadow:[we]}],opacity:[{opacity:[w]}],"mix-blend":[{"mix-blend":[...le(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":le()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[s]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",ie,S]}],grayscale:[{grayscale:[h]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[x]}],saturate:[{saturate:[T]}],sepia:[{sepia:[O]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[s]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[h]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[x]}],"backdrop-opacity":[{"backdrop-opacity":[w]}],"backdrop-saturate":[{"backdrop-saturate":[T]}],"backdrop-sepia":[{"backdrop-sepia":[O]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[c]}],"border-spacing-x":[{"border-spacing-x":[c]}],"border-spacing-y":[{"border-spacing-y":[c]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",S]}],duration:[{duration:M()}],ease:[{ease:["linear","in","out","in-out",S]}],delay:[{delay:M()}],animate:[{animate:["none","spin","ping","pulse","bounce",S]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[E]}],"scale-x":[{"scale-x":[E]}],"scale-y":[{"scale-y":[E]}],rotate:[{rotate:[ye,S]}],"translate-x":[{"translate-x":[re]}],"translate-y":[{"translate-y":[re]}],"skew-x":[{"skew-x":[V]}],"skew-y":[{"skew-y":[V]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",S]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",S]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":N()}],"scroll-mx":[{"scroll-mx":N()}],"scroll-my":[{"scroll-my":N()}],"scroll-ms":[{"scroll-ms":N()}],"scroll-me":[{"scroll-me":N()}],"scroll-mt":[{"scroll-mt":N()}],"scroll-mr":[{"scroll-mr":N()}],"scroll-mb":[{"scroll-mb":N()}],"scroll-ml":[{"scroll-ml":N()}],"scroll-p":[{"scroll-p":N()}],"scroll-px":[{"scroll-px":N()}],"scroll-py":[{"scroll-py":N()}],"scroll-ps":[{"scroll-ps":N()}],"scroll-pe":[{"scroll-pe":N()}],"scroll-pt":[{"scroll-pt":N()}],"scroll-pr":[{"scroll-pr":N()}],"scroll-pb":[{"scroll-pb":N()}],"scroll-pl":[{"scroll-pl":N()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",S]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[ae,ce,Ae]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}});function u(...e){return ft(Mr(e))}const je=g.createContext({mode:"single",selectedKeys:[],disabledKeys:[],activatedKeys:[],setActivatedKeys:()=>[]}),pt=({onChange:e,children:r})=>{const{activatedKeys:n}=g.useContext(je);return g.useEffect(()=>{e(n)},[n]),r},Oe=g.createContext({loading:!1,isDisabled:!1,itemId:"",setItemId:()=>""}),gt=({id:e="",loading:r=!1,className:n="",children:s})=>{const{disabledKeys:i=[]}=g.useContext(je),[a,c]=g.useState(""),l=g.useMemo(()=>i.includes(a),[i,a]);return g.useEffect(()=>{c(e)},[e]),t.jsx(Oe.Provider,{value:{loading:r,isDisabled:l,itemId:a,setItemId:c},children:t.jsx("div",{className:u(["starterui-accordion pt-3 last:pb-0"],n),children:s})})},ht=({className:e,subTitle:r,children:n,onClick:s})=>{const{mode:i,activatedKeys:a,setActivatedKeys:c}=g.useContext(je),{itemId:l,loading:d,isDisabled:h}=g.useContext(Oe),p=()=>{d||h||(s==null||s(),c(i==="single"?x=>x.includes(l)?[]:[l]:x=>x.includes(l)?x.filter(j=>j!==l):[...x,l]))};return t.jsxs("div",{id:`accordion-header-${l}`,onClick:p,className:u(["flex items-center justify-between w-full cursor-pointer",d?"opacity-70 cursor-wait":"",h?"cursor-default opacity-50":"",e]),children:[t.jsxs("div",{children:[t.jsx("div",{className:"text-lg font-semibold",children:n}),t.jsx("div",{className:"text-sm font-light opacity-85",children:r})]}),d?t.jsx("div",{className:"h-3 w-3 animate-spin rounded-full border-2 border-solid block border-t-transparent border-black/50 mr-0.5"}):t.jsx("div",{className:u(["transition-all duration-200",a.includes(l)?"rotate-180":"rotate-0"]),children:t.jsxs("svg",{width:"14px",height:"14px",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[t.jsx("g",{id:"SVGRepo_bgCarrier","stroke-width":"0"}),t.jsx("g",{id:"SVGRepo_tracerCarrier","stroke-linecap":"round","stroke-linejoin":"round"}),t.jsx("g",{id:"SVGRepo_iconCarrier",children:t.jsx("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M12 7C12.2652 7 12.5196 7.10536 12.7071 7.29289L19.7071 14.2929C20.0976 14.6834 20.0976 15.3166 19.7071 15.7071C19.3166 16.0976 18.6834 16.0976 18.2929 15.7071L12 9.41421L5.70711 15.7071C5.31658 16.0976 4.68342 16.0976 4.29289 15.7071C3.90237 15.3166 3.90237 14.6834 4.29289 14.2929L11.2929 7.29289C11.4804 7.10536 11.7348 7 12 7Z",fill:"#000000"})})]})})]})},bt=({className:e,children:r})=>{const{activatedKeys:n}=g.useContext(je),{itemId:s,loading:i,isDisabled:a}=g.useContext(Oe),c=!i&&n.includes(s);return t.jsx("div",{id:`accordion-body-${s}`,className:u(["starterui-accordion-body overflow-hidden pt-3",c?"starterui-accordion-body-open pb-3":"starterui-accordion-body-close",a?"cursor-default opacity-50":"",e]),children:t.jsx("div",{children:r})})},Ce=({id:e="starterui-collapse-accordion",mode:r="single",selectedKeys:n=[],disabledKeys:s=[],showDivider:i=!0,className:a,children:c,onChange:l})=>{const[d,h]=g.useState(n);return t.jsx("div",{id:e,className:u(["w-full",i?"divide-y":""],a),children:t.jsx(je.Provider,{value:{mode:r,selectedKeys:n,disabledKeys:s,activatedKeys:d,setActivatedKeys:h},children:t.jsx(pt,{onChange:p=>l==null?void 0:l(p),children:c})})})};Ce.Item=gt,Ce.Header=ht,Ce.Content=bt;/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const mt=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),ir=(...e)=>e.filter((r,n,s)=>!!r&&s.indexOf(r)===n).join(" ");/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */var xt={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const vt=g.forwardRef(({color:e="currentColor",size:r=24,strokeWidth:n=2,absoluteStrokeWidth:s,className:i="",children:a,iconNode:c,...l},d)=>g.createElement("svg",{ref:d,...xt,width:r,height:r,stroke:e,strokeWidth:s?Number(n)*24/Number(r):n,className:ir("lucide",i),...l},[...c.map(([h,p])=>g.createElement(h,p)),...Array.isArray(a)?a:[a]]));/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const se=(e,r)=>{const n=g.forwardRef(({className:s,...i},a)=>g.createElement(vt,{ref:a,iconNode:r,className:ir(`lucide-${mt(e)}`,s),...i}));return n.displayName=`${e}`,n};/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const yt=se("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const wt=se("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const ur=se("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const jt=se("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const kt=se("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const dr=se("FileSearch",[["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M4.268 21a2 2 0 0 0 1.727 1H18a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v3",key:"ms7g94"}],["path",{d:"m9 18-1.5-1.5",key:"1j6qii"}],["circle",{cx:"5",cy:"14",r:"3",key:"ufru5t"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const fr=se("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const _t=se("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Nt=se("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const Ct=se("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/** * @license lucide-react v0.451.0 - ISC * * This source code is licensed under the ISC license. * See the LICENSE file in the root directory of this source tree. */const ne=se("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),St=e=>{switch(e){case"info":return"bg-primary-light/30 text-primary-dark";case"success":return"bg-success-light/20 text-success-dark";case"warning":return"bg-warning-light/20 text-warning-dark";case"error":return"bg-error-light/20 text-error-dark";default:return"bg-muted/10 text-default"}},Et=e=>{switch(e){case"info":return"border border-primary-light";case"success":return"border border-success-light";case"warning":return"border border-warning-light";case"error":return"border border-error-light";default:return"border border-muted/70"}},Pt=e=>{switch(e){case"info":return t.jsx(fr,{size:18});case"success":return t.jsx(jt,{size:18});case"warning":return t.jsx(Nt,{size:18});case"error":return t.jsx(kt,{size:18});default:return t.jsx(fr,{size:18})}},It=(e,r)=>{switch(e){case"info":return t.jsx("div",{className:"ms-2 -mr-1.5 flex-shrink-0 p-1 cursor-pointer rounded-lg hover:bg-primary-light/20",onClick:r,children:t.jsx(ne,{size:18})});case"success":return t.jsx("div",{className:"ms-2 -mr-1.5 flex-shrink-0 p-1 cursor-pointer rounded-lg hover:bg-success-light/20",onClick:r,children:t.jsx(ne,{size:18})});case"warning":return t.jsx("div",{className:"ms-2 -mr-1.5 flex-shrink-0 p-1 cursor-pointer rounded-lg hover:bg-warning-light/30",onClick:r,children:t.jsx(ne,{size:18})});case"error":return t.jsx("div",{className:"ms-2 -mr-1.5 flex-shrink-0 p-1 cursor-pointer rounded-lg hover:bg-error-light/20",onClick:r,children:t.jsx(ne,{size:18})});default:return null}},$t=({id:e="starterui-default-alert",type:r="default",outline:n=!1,closeable:s=!0,className:i,children:a,onClose:c})=>t.jsxs("div",{id:e,className:u(["starterui-alert p-4 rounded-lg flex items-start font-medium text-base",St(r),Et(r),i]),role:"alert",children:[t.jsx("div",{className:"mt-[3px] flex-shrink-0 inline me-2",children:Pt(r)}),t.jsx("div",{className:"grow",children:a}),s&&It(r,c)]}),Le=e=>{switch(e){case"sm":return"rounded-md";case"md":return"rounded-lg";case"lg":return"rounded-xl";case"full":return"rounded-full";case"none":return"rounded-none";default:return""}},Fe=e=>{switch(e){case"default":return"border-default ring-default";case"primary":return"border-primary ring-primary";case"secondary":return"border-secondary ring-secondary";case"success":return"border-success ring-success";case"warning":return"border-warning ring-warning";case"error":return"border-error ring-error";default:return"border-default ring-default"}},Tt=({color:e,size:r,radius:n,bordered:s,disabled:i,className:a,onClick:c})=>t.jsx("div",{className:u(["starterui-avatar bg-gray-100 rounded-full flex items-center justify-center",s?"border-[1.5px]":"",Fe(e),Le(n),i?"opacity-50 cursor-not-allowed":"",a]),onClick:()=>{i||c==null||c()},style:{width:r,height:r},children:t.jsx(Ct,{size:r-12,className:"flex-1"})}),zt=({name:e,color:r,size:n,radius:s,bordered:i,disabled:a,className:c,onClick:l})=>t.jsx("div",{className:u(["bg-gray-100 rounded-full inline-flex items-center justify-center p-2 w-fit h-fit",i?"border":"",Fe(r),Le(s),a?"opacity-50 cursor-not-allowed":"",c]),onClick:()=>{a||l==null||l()},style:{width:n,height:n},children:t.jsx("span",{className:"flex-1 text-center leading-none",children:e.toUpperCase().slice(0,1)})}),Rt=({id:e="starterui-default-avatar",src:r,name:n,alt:s="alt-avatar",color:i="default",size:a=32,radius:c="full",bordered:l=!1,disabled:d=!1,className:h="",onClick:p})=>!r&&!n?t.jsx(Tt,{color:i,size:a,radius:c,bordered:l,disabled:d,className:h}):!r&&n?t.jsx(zt,{name:n,color:i,size:a,radius:c,bordered:l,disabled:d,className:h}):t.jsx("img",{id:e,style:{width:a,height:a},src:r,alt:s,className:u(["rounded-full object-cover object-center",l&&"ring-1 p-0.5",Fe(i),Le(c),d?"opacity-50 cursor-not-allowed":"",h]),onClick:()=>{d||p==null||p()}}),De=({className:e,onClick:r})=>t.jsx("div",{onClick:r,className:u(["fixed z-50 top-0 left-0 h-screen w-screen bg-[#00000080] opacity-50",e])}),Mt=(e,r)=>{switch(e){case"primary":return`text-white bg-primary ${r?"border-primary text-primary":""}`;case"secondary":return`text-white bg-secondary ${r?"border-secondary text-primary":""}`;case"success":return`text-default bg-success ${r?"border-success text-success":""}`;case"warning":return`text-default bg-warning ${r?"border-warning text-warning":""}`;case"error":return`text-white bg-error ${r?"border-error text-error":""}`;default:return`text-default bg-grey ${r?"border-default":""}`}},At=(e,r)=>{switch(e){case"sm":return"text-sm px-2 py-1.5 rounded-md";case"md":return`text-base px-3 py-2 rounded-lg ${r?"border-[1.5px]":""}`;case"lg":return`text-lg px-4 py-3 rounded-xl ${r?"border-[2px]":""}`;default:return"text-sm px-2 py-1.5 rounded-md"}},Ot=({id:e="starterui-default-badge",color:r="default",size:n="sm",className:s,disabled:i=!1,outline:a=!1,children:c})=>t.jsx("div",{id:e,className:u(["starterui-badge inline-flex items-center justify-start w-fit h-fit whitespace-nowrap",Mt(r,a),At(n,a),a?"border bg-transparent":"",i?"cursor-not-allowed opacity-60":"",s]),children:c}),pr=e=>{switch(e){case"sm":return"text-sm";case"md":return"text-base";case"lg":return"text-lg";default:return"text-base"}},Lt=e=>{switch(e){case"hover":return"hover:underline";case"all":return"underline";default:return""}},Ft=({id:e="starterui-default-breadcrumbs",data:r,size:n="md",underline:s="hover",className:i,onClick:a})=>r&&r.length===0?null:t.jsx("nav",{id:e,className:"starterui-breadcrumb","aria-label":"Breadcrumb",children:t.jsx("ol",{className:u(["inline-flex items-center space-x-1 leading-none",i]),children:r.map((c,l)=>t.jsx(g.Fragment,{children:t.jsxs("li",{className:"flex items-center space-x-1","aria-current":l===r.length-1,children:[l!=0&&t.jsx(ur,{size:16}),c.title&&t.jsx(t.Fragment,{children:l===r.length-1||!c.url||c!=null&&c.isDisabled?t.jsx("span",{className:u(["w-fit text-default",l===r.length-1?"font-bold":"",pr(n),c!=null&&c.isDisabled?"text-default/50":"",c==null?void 0:c.className]),children:c.title}):t.jsx("a",{href:c.url,className:u(["w-fit font-normal text-default hover:text-default/60 transition-all duration-200 underline-offset-1 decoration-1",pr(n),Lt(s),c==null?void 0:c.className]),onClick:a==null?void 0:a(c.url),children:c.title})})]},l)},l))})}),Dt=e=>{switch(e){case"sm":return"w-3 h-3 border";case"md":return"w-4 h-4";case"lg":return"w-6 h-6";default:return"w-4 h-4"}},Bt=e=>{switch(e){case"default":return"border-default";case"primary":return"border-primary";case"secondary":return"border-secondary";case"success":return"border-success";case"warning":return"border-warning";case"error":return"border-error";default:return"border-white"}},ue=({id:e="starterui-default-spinner",isLoading:r=!0,size:n="md",color:s="default",className:i})=>t.jsx("div",{id:e,className:u(["starterui-spinner animate-spin rounded-full border-2 border-solid",Dt(n),Bt(s),r?"block":"hidden",i,"border-t-transparent"])}),Wt=(e,r,n)=>{switch(e){case"primary":return`[&_div]:text-white bg-primary focus:ring-primary/40 ${r?"hover:bg-primary-dark":""} ${n?"border-primary [&_div]:text-primary":""}`;case"secondary":return`[&_div]:text-white bg-secondary focus:ring-secondary/40 ${r?"hover:bg-secondary-dark":""} ${n?"border-secondary [&_div]:text-primary":""}`;case"success":return`[&_div]:text-default bg-success focus:ring-success/40 ${r?"hover:bg-success-dark":""} ${n?"border-success [&_div]:text-success":""}`;case"warning":return`[&_div]:text-default bg-warning focus:ring-warning/40 ${r?"hover:bg-warning-dark":""} ${n?"border-warning [&_div]:text-warning":""}`;case"error":return`[&_div]