componentables 0.1.26 → 0.1.27
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/README.md +11 -0
- package/dist/componentables.css +1 -1
- package/dist/components/Table/Table.d.ts.map +1 -1
- package/dist/components/Toggle/Toggle.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +388 -392
- package/dist/index.js.map +1 -1
- package/package.json +4 -3
package/dist/index.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),j=require("react"),_e=require("react-loader-spinner"),$e=require("react-dom"),Q=require("react-toastify");function ye(e){var r,t,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(r=0;r<n;r++)e[r]&&(t=ye(e[r]))&&(o&&(o+=" "),o+=t)}else for(t in e)e[t]&&(o&&(o+=" "),o+=t);return o}function Fe(){for(var e,r,t=0,o="",n=arguments.length;t<n;t++)(e=arguments[t])&&(r=ye(e))&&(o&&(o+=" "),o+=r);return o}const de="-",Re=e=>{const r=Be(e),{conflictingClassGroups:t,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:i=>{const a=i.split(de);return a[0]===""&&a.length!==1&&a.shift(),we(a,r)||Ve(i)},getConflictingClassGroupIds:(i,a)=>{const d=t[i]||[];return a&&o[i]?[...d,...o[i]]:d}}},we=(e,r)=>{if(e.length===0)return r.classGroupId;const t=e[0],o=r.nextPart.get(t),n=o?we(e.slice(1),o):void 0;if(n)return n;if(r.validators.length===0)return;const l=e.join(de);return r.validators.find(({validator:i})=>i(l))?.classGroupId},ue=/^\[(.+)\]$/,Ve=e=>{if(ue.test(e)){const r=ue.exec(e)[1],t=r?.substring(0,r.indexOf(":"));if(t)return"arbitrary.."+t}},Be=e=>{const{theme:r,prefix:t}=e,o={nextPart:new Map,validators:[]};return He(Object.entries(e.classGroups),t).forEach(([l,i])=>{ie(i,o,l,r)}),o},ie=(e,r,t,o)=>{e.forEach(n=>{if(typeof n=="string"){const l=n===""?r:me(r,n);l.classGroupId=t;return}if(typeof n=="function"){if(Ge(n)){ie(n(o),r,t,o);return}r.validators.push({validator:n,classGroupId:t});return}Object.entries(n).forEach(([l,i])=>{ie(i,me(r,l),t,o)})})},me=(e,r)=>{let t=e;return r.split(de).forEach(o=>{t.nextPart.has(o)||t.nextPart.set(o,{nextPart:new Map,validators:[]}),t=t.nextPart.get(o)}),t},Ge=e=>e.isThemeGetter,He=(e,r)=>r?e.map(([t,o])=>{const n=o.map(l=>typeof l=="string"?r+l:typeof l=="object"?Object.fromEntries(Object.entries(l).map(([i,a])=>[r+i,a])):l);return[t,n]}):e,We=e=>{if(e<1)return{get:()=>{},set:()=>{}};let r=0,t=new Map,o=new Map;const n=(l,i)=>{t.set(l,i),r++,r>e&&(r=0,o=t,t=new Map)};return{get(l){let i=t.get(l);if(i!==void 0)return i;if((i=o.get(l))!==void 0)return n(l,i),i},set(l,i){t.has(l)?t.set(l,i):n(l,i)}}},ve="!",Ue=e=>{const{separator:r,experimentalParseClassName:t}=e,o=r.length===1,n=r[0],l=r.length,i=a=>{const d=[];let u=0,p=0,w;for(let m=0;m<a.length;m++){let v=a[m];if(u===0){if(v===n&&(o||a.slice(m,m+l)===r)){d.push(a.slice(p,m)),p=m+l;continue}if(v==="/"){w=m;continue}}v==="["?u++:v==="]"&&u--}const f=d.length===0?a:a.substring(p),y=f.startsWith(ve),b=y?f.substring(1):f,x=w&&w>p?w-p:void 0;return{modifiers:d,hasImportantModifier:y,baseClassName:b,maybePostfixModifierPosition:x}};return t?a=>t({className:a,parseClassName:i}):i},Ye=e=>{if(e.length<=1)return e;const r=[];let t=[];return e.forEach(o=>{o[0]==="["?(r.push(...t.sort(),o),t=[]):t.push(o)}),r.push(...t.sort()),r},Je=e=>({cache:We(e.cacheSize),parseClassName:Ue(e),...Re(e)}),Ke=/\s+/,qe=(e,r)=>{const{parseClassName:t,getClassGroupId:o,getConflictingClassGroupIds:n}=r,l=[],i=e.trim().split(Ke);let a="";for(let d=i.length-1;d>=0;d-=1){const u=i[d],{modifiers:p,hasImportantModifier:w,baseClassName:f,maybePostfixModifierPosition:y}=t(u);let b=!!y,x=o(b?f.substring(0,y):f);if(!x){if(!b){a=u+(a.length>0?" "+a:a);continue}if(x=o(f),!x){a=u+(a.length>0?" "+a:a);continue}b=!1}const m=Ye(p).join(":"),v=w?m+ve:m,h=v+x;if(l.includes(h))continue;l.push(h);const L=n(x,b);for(let E=0;E<L.length;++E){const S=L[E];l.push(v+S)}a=u+(a.length>0?" "+a:a)}return a};function Ze(){let e=0,r,t,o="";for(;e<arguments.length;)(r=arguments[e++])&&(t=je(r))&&(o&&(o+=" "),o+=t);return o}const je=e=>{if(typeof e=="string")return e;let r,t="";for(let o=0;o<e.length;o++)e[o]&&(r=je(e[o]))&&(t&&(t+=" "),t+=r);return t};function Xe(e,...r){let t,o,n,l=i;function i(d){const u=r.reduce((p,w)=>w(p),e());return t=Je(u),o=t.cache.get,n=t.cache.set,l=a,a(d)}function a(d){const u=o(d);if(u)return u;const p=qe(d,t);return n(d,p),p}return function(){return l(Ze.apply(null,arguments))}}const P=e=>{const r=t=>t[e]||[];return r.isThemeGetter=!0,r},ke=/^\[(?:([a-z-]+):)?(.+)\]$/i,Qe=/^\d+\/\d+$/,er=new Set(["px","full","screen"]),rr=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,tr=/\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$/,sr=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,or=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,nr=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,G=e=>Z(e)||er.has(e)||Qe.test(e),H=e=>X(e,"length",pr),Z=e=>!!e&&!Number.isNaN(Number(e)),ae=e=>X(e,"number",Z),ee=e=>!!e&&Number.isInteger(Number(e)),ar=e=>e.endsWith("%")&&Z(e.slice(0,-1)),N=e=>ke.test(e),W=e=>rr.test(e),lr=new Set(["length","size","percentage"]),ir=e=>X(e,lr,Ne),cr=e=>X(e,"position",Ne),dr=new Set(["image","url"]),ur=e=>X(e,dr,gr),mr=e=>X(e,"",br),re=()=>!0,X=(e,r,t)=>{const o=ke.exec(e);return o?o[1]?typeof r=="string"?o[1]===r:r.has(o[1]):t(o[2]):!1},pr=e=>tr.test(e)&&!sr.test(e),Ne=()=>!1,br=e=>or.test(e),gr=e=>nr.test(e),fr=()=>{const e=P("colors"),r=P("spacing"),t=P("blur"),o=P("brightness"),n=P("borderColor"),l=P("borderRadius"),i=P("borderSpacing"),a=P("borderWidth"),d=P("contrast"),u=P("grayscale"),p=P("hueRotate"),w=P("invert"),f=P("gap"),y=P("gradientColorStops"),b=P("gradientColorStopPositions"),x=P("inset"),m=P("margin"),v=P("opacity"),h=P("padding"),L=P("saturate"),E=P("scale"),S=P("sepia"),z=P("skew"),g=P("space"),I=P("translate"),$=()=>["auto","contain","none"],B=()=>["auto","hidden","clip","visible","scroll"],Y=()=>["auto",N,r],D=()=>[N,r],C=()=>["",G,H],A=()=>["auto",Z,N],V=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],_=()=>["solid","dashed","dotted","double","none"],K=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],k=()=>["start","end","center","between","around","evenly","stretch"],M=()=>["","0",N],F=()=>["auto","avoid","all","avoid-page","page","left","right","column"],R=()=>[Z,N];return{cacheSize:500,separator:":",theme:{colors:[re],spacing:[G,H],blur:["none","",W,N],brightness:R(),borderColor:[e],borderRadius:["none","","full",W,N],borderSpacing:D(),borderWidth:C(),contrast:R(),grayscale:M(),hueRotate:R(),invert:M(),gap:D(),gradientColorStops:[e],gradientColorStopPositions:[ar,H],inset:Y(),margin:Y(),opacity:R(),padding:D(),saturate:R(),scale:R(),sepia:M(),skew:R(),space:D(),translate:D()},classGroups:{aspect:[{aspect:["auto","square","video",N]}],container:["container"],columns:[{columns:[W]}],"break-after":[{"break-after":F()}],"break-before":[{"break-before":F()}],"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:[...V(),N]}],overflow:[{overflow:B()}],"overflow-x":[{"overflow-x":B()}],"overflow-y":[{"overflow-y":B()}],overscroll:[{overscroll:$()}],"overscroll-x":[{"overscroll-x":$()}],"overscroll-y":[{"overscroll-y":$()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[x]}],"inset-x":[{"inset-x":[x]}],"inset-y":[{"inset-y":[x]}],start:[{start:[x]}],end:[{end:[x]}],top:[{top:[x]}],right:[{right:[x]}],bottom:[{bottom:[x]}],left:[{left:[x]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",ee,N]}],basis:[{basis:Y()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",N]}],grow:[{grow:M()}],shrink:[{shrink:M()}],order:[{order:["first","last","none",ee,N]}],"grid-cols":[{"grid-cols":[re]}],"col-start-end":[{col:["auto",{span:["full",ee,N]},N]}],"col-start":[{"col-start":A()}],"col-end":[{"col-end":A()}],"grid-rows":[{"grid-rows":[re]}],"row-start-end":[{row:["auto",{span:[ee,N]},N]}],"row-start":[{"row-start":A()}],"row-end":[{"row-end":A()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",N]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",N]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:["normal",...k()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...k(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...k(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[h]}],px:[{px:[h]}],py:[{py:[h]}],ps:[{ps:[h]}],pe:[{pe:[h]}],pt:[{pt:[h]}],pr:[{pr:[h]}],pb:[{pb:[h]}],pl:[{pl:[h]}],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":[g]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[g]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",N,r]}],"min-w":[{"min-w":[N,r,"min","max","fit"]}],"max-w":[{"max-w":[N,r,"none","full","min","max","fit","prose",{screen:[W]},W]}],h:[{h:[N,r,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[N,r,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[N,r,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[N,r,"auto","min","max","fit"]}],"font-size":[{text:["base",W,H]}],"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:[re]}],"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-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",N]}],"line-clamp":[{"line-clamp":["none",Z,ae]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",G,N]}],"list-image":[{"list-image":["none",N]}],"list-style-type":[{list:["none","disc","decimal",N]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[v]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[v]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[..._(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",G,H]}],"underline-offset":[{"underline-offset":["auto",G,N]}],"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:D()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",N]}],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",N]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[v]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...V(),cr]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",ir]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},ur]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[b]}],"gradient-via-pos":[{via:[b]}],"gradient-to-pos":[{to:[b]}],"gradient-from":[{from:[y]}],"gradient-via":[{via:[y]}],"gradient-to":[{to:[y]}],rounded:[{rounded:[l]}],"rounded-s":[{"rounded-s":[l]}],"rounded-e":[{"rounded-e":[l]}],"rounded-t":[{"rounded-t":[l]}],"rounded-r":[{"rounded-r":[l]}],"rounded-b":[{"rounded-b":[l]}],"rounded-l":[{"rounded-l":[l]}],"rounded-ss":[{"rounded-ss":[l]}],"rounded-se":[{"rounded-se":[l]}],"rounded-ee":[{"rounded-ee":[l]}],"rounded-es":[{"rounded-es":[l]}],"rounded-tl":[{"rounded-tl":[l]}],"rounded-tr":[{"rounded-tr":[l]}],"rounded-br":[{"rounded-br":[l]}],"rounded-bl":[{"rounded-bl":[l]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[v]}],"border-style":[{border:[..._(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[v]}],"divide-style":[{divide:_()}],"border-color":[{border:[n]}],"border-color-x":[{"border-x":[n]}],"border-color-y":[{"border-y":[n]}],"border-color-s":[{"border-s":[n]}],"border-color-e":[{"border-e":[n]}],"border-color-t":[{"border-t":[n]}],"border-color-r":[{"border-r":[n]}],"border-color-b":[{"border-b":[n]}],"border-color-l":[{"border-l":[n]}],"divide-color":[{divide:[n]}],"outline-style":[{outline:["",..._()]}],"outline-offset":[{"outline-offset":[G,N]}],"outline-w":[{outline:[G,H]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:C()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[v]}],"ring-offset-w":[{"ring-offset":[G,H]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",W,mr]}],"shadow-color":[{shadow:[re]}],opacity:[{opacity:[v]}],"mix-blend":[{"mix-blend":[...K(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":K()}],filter:[{filter:["","none"]}],blur:[{blur:[t]}],brightness:[{brightness:[o]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",W,N]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[w]}],saturate:[{saturate:[L]}],sepia:[{sepia:[S]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[t]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[w]}],"backdrop-opacity":[{"backdrop-opacity":[v]}],"backdrop-saturate":[{"backdrop-saturate":[L]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",N]}],duration:[{duration:R()}],ease:[{ease:["linear","in","out","in-out",N]}],delay:[{delay:R()}],animate:[{animate:["none","spin","ping","pulse","bounce",N]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[E]}],"scale-x":[{"scale-x":[E]}],"scale-y":[{"scale-y":[E]}],rotate:[{rotate:[ee,N]}],"translate-x":[{"translate-x":[I]}],"translate-y":[{"translate-y":[I]}],"skew-x":[{"skew-x":[z]}],"skew-y":[{"skew-y":[z]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",N]}],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",N]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":D()}],"scroll-mx":[{"scroll-mx":D()}],"scroll-my":[{"scroll-my":D()}],"scroll-ms":[{"scroll-ms":D()}],"scroll-me":[{"scroll-me":D()}],"scroll-mt":[{"scroll-mt":D()}],"scroll-mr":[{"scroll-mr":D()}],"scroll-mb":[{"scroll-mb":D()}],"scroll-ml":[{"scroll-ml":D()}],"scroll-p":[{"scroll-p":D()}],"scroll-px":[{"scroll-px":D()}],"scroll-py":[{"scroll-py":D()}],"scroll-ps":[{"scroll-ps":D()}],"scroll-pe":[{"scroll-pe":D()}],"scroll-pt":[{"scroll-pt":D()}],"scroll-pr":[{"scroll-pr":D()}],"scroll-pb":[{"scroll-pb":D()}],"scroll-pl":[{"scroll-pl":D()}],"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",N]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[G,H,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-s","border-color-e","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"]}}},hr=Xe(fr);function c(...e){return hr(Fe(e))}function Ce(e){const r=parseInt(e.slice(1,3),16)/255,t=parseInt(e.slice(3,5),16)/255,o=parseInt(e.slice(5,7),16)/255,n=Math.max(r,t,o),l=Math.min(r,t,o);let i=0,a=0;const d=(n+l)/2;if(n!==l){const u=n-l;switch(a=d>.5?u/(2-n-l):u/(n+l),n){case r:i=((t-o)/u+(t<o?6:0))/6;break;case t:i=((o-r)/u+2)/6;break;case o:i=((r-t)/u+4)/6;break}}return[i*360,a*100,d*100]}function ce(e,r,t){t/=100;const o=r*Math.min(t,1-t)/100,n=l=>{const i=(l+e/30)%12,a=t-o*Math.max(Math.min(i-3,9-i,1),-1);return Math.round(255*a).toString(16).padStart(2,"0")};return`#${n(0)}${n(8)}${n(4)}`}function se(e){const[r,t,o]=Ce(e);return{base:e,light:ce(r,Math.max(0,t-10),Math.min(100,o+15)),dark:ce(r,Math.min(100,t+10),Math.max(0,o-15))}}const O={colors:{primary:"#6366f1",primaryLight:"#818cf8",primaryDark:"#4f46e5",secondary:"#8b5cf6",secondaryLight:"#a78bfa",secondaryDark:"#7c3aed",danger:"#ef4444",dangerLight:"#f87171",dangerDark:"#dc2626",text:"#1f2937",textMuted:"#6b7280",textLight:"#9ca3af",border:"#e5e7eb",borderDark:"#d1d5db",background:"#ffffff",backgroundDark:"#f9fafb",backgroundLight:"#f3f4f6",disabled:"#e5e7eb",light:"#f9fafb",active:"#4338ca"}},Se=j.createContext(O);function xr(){return j.useContext(Se)}function pe(e){const r=document.documentElement;r.style.setProperty("--componentables-primary",e.colors.primary),r.style.setProperty("--componentables-primary-light",e.colors.primaryLight),r.style.setProperty("--componentables-primary-dark",e.colors.primaryDark),r.style.setProperty("--componentables-secondary",e.colors.secondary),r.style.setProperty("--componentables-secondary-light",e.colors.secondaryLight),r.style.setProperty("--componentables-secondary-dark",e.colors.secondaryDark),r.style.setProperty("--componentables-danger",e.colors.danger),r.style.setProperty("--componentables-danger-light",e.colors.dangerLight),r.style.setProperty("--componentables-danger-dark",e.colors.dangerDark),r.style.setProperty("--componentables-text",e.colors.text),r.style.setProperty("--componentables-text-muted",e.colors.textMuted),r.style.setProperty("--componentables-text-light",e.colors.textLight),r.style.setProperty("--componentables-border",e.colors.border),r.style.setProperty("--componentables-border-dark",e.colors.borderDark),r.style.setProperty("--componentables-background",e.colors.background),r.style.setProperty("--componentables-background-dark",e.colors.backgroundDark),r.style.setProperty("--componentables-background-light",e.colors.backgroundLight),r.style.setProperty("--componentables-disabled",e.colors.disabled),r.style.setProperty("--componentables-light",e.colors.light),r.style.setProperty("--componentables-active",e.colors.active)}function yr({children:e,theme:r}){const t=j.useMemo(()=>{const o=r?.colors||{},n=o.primary?se(o.primary):null,l=o.secondary?se(o.secondary):null,i=o.danger?se(o.danger):null;return{colors:{primary:o.primary||O.colors.primary,primaryLight:n?.light||O.colors.primaryLight,primaryDark:n?.dark||O.colors.primaryDark,secondary:o.secondary||O.colors.secondary,secondaryLight:l?.light||O.colors.secondaryLight,secondaryDark:l?.dark||O.colors.secondaryDark,danger:o.danger||O.colors.danger,dangerLight:i?.light||O.colors.dangerLight,dangerDark:i?.dark||O.colors.dangerDark,text:o.text||O.colors.text,textMuted:o.textMuted||O.colors.textMuted,textLight:o.textLight||O.colors.textLight,border:o.border||O.colors.border,borderDark:o.borderDark||O.colors.borderDark,background:o.background||O.colors.background,backgroundDark:o.backgroundDark||O.colors.backgroundDark,backgroundLight:o.backgroundLight||O.colors.backgroundLight,disabled:o.disabled||O.colors.disabled,light:o.light||O.colors.light,active:o.active||O.colors.active}}},[r]);return typeof window<"u"&&pe(t),j.useEffect(()=>{pe(t)},[t]),j.createElement(Se.Provider,{value:t},e)}const wr={primary:"bg-primary text-white border-primary hover:bg-primary-dark hover:border-primary-dark active:bg-active",secondary:"bg-secondary text-white border-secondary hover:bg-secondary-dark hover:border-secondary-dark","primary-outline":"bg-transparent text-primary border-primary hover:bg-primary hover:text-white","secondary-outline":"bg-transparent text-secondary border-secondary hover:bg-secondary hover:text-white",ghost:"bg-transparent text-primary border-transparent hover:bg-primary hover:text-white hover:border-primary",light:"bg-light text-text border-border hover:bg-background-light",danger:"bg-transparent text-danger border-danger hover:text-white hover:bg-danger hover:border-danger active:bg-danger-dark",link:"bg-transparent text-secondary-light! underline hover:text-primary! border-0",dark:"bg-gray-800 text-white border-gray-800 hover:bg-gray-900 hover:border-gray-900"},vr={sm:"px-3 py-1.5 text-sm",md:"px-4 py-2 text-base",lg:"px-6 py-3 text-lg",xl:"px-8 py-4 text-xl"};function J({children:e,onClick:r,disabled:t=!1,type:o="button",variant:n="primary",size:l="md",fullWidth:i=!1,loading:a=!1,className:d="",...u}){return s.jsxs("button",{type:o,onClick:t||a?void 0:r,disabled:t||a,className:c("inline-flex shadow-md hover:shadow-lg cursor-pointer items-center justify-center font-medium rounded-lg border transition-all duration-300 focus:outline-none focus:ring-2 focus:ring-primary focus:ring-opacity-50",t||a?"bg-disabled text-text-muted border-disabled cursor-not-allowed hover:bg-disabled hover:border-disabled hover:text-text-muted":wr[n],vr[l],i&&"w-full",a&&"cursor-wait opacity-75",d),...u,children:[a&&s.jsxs("svg",{className:"w-4 h-4 mr-2 animate-spin",fill:"none",viewBox:"0 0 24 24",children:[s.jsx("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),s.jsx("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]}),e]})}function jr({id:e,name:r,type:t="text",value:o,onChange:n,placeholder:l,label:i,error:a,disabled:d=!1,required:u=!1,colorScheme:p="secondary",className:w="",...f}){const y=()=>{const x="w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed placeholder:text-text-muted";if(a)return c(x,"border-danger focus:border-danger focus:shadow-danger-light");switch(p){case"primary":return c(x,"text-primary border-primary focus:border-primary");case"secondary":default:return c(x,"text-secondary border-secondary focus:border-secondary")}},b=()=>p==="primary"?"text-primary":"text-secondary";return s.jsxs("div",{className:c("mb-6",w),children:[i&&s.jsxs("label",{htmlFor:e,className:c("block mb-2 text-sm font-medium",b()),children:[i,u&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsx("input",{id:e,name:r,type:t,value:o,onChange:n,placeholder:l,disabled:d,required:u,className:y(),...f}),a&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:a})]})}function kr({id:e,name:r,value:t,onChange:o,placeholder:n,label:l,error:i,disabled:a=!1,required:d=!1,colorScheme:u="secondary",className:p="",rows:w=4,...f}){const y=()=>{const x="w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed placeholder:text-text-muted resize-none";if(i)return c(x,"border-danger focus:border-danger focus:shadow-danger-light");switch(u){case"primary":return c(x,"text-primary border-primary focus:border-primary");case"secondary":default:return c(x,"text-secondary border-secondary focus:border-secondary")}},b=()=>u==="primary"?"text-primary":"text-secondary";return s.jsxs("div",{className:c("mb-6",p),children:[l&&s.jsxs("label",{htmlFor:e,className:c("block mb-2 text-sm font-medium",b()),children:[l,d&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsx("textarea",{id:e,name:r,value:t,onChange:o,placeholder:n,disabled:a,required:d,rows:w,className:y(),...f}),i&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:i})]})}const Me={Input:jr,InputArea:kr};function Nr({id:e,name:r,checked:t=!1,onChange:o,disabled:n=!1,label:l,colorScheme:i="secondary",size:a="md",className:d="",...u}){const[p,w]=j.useState(t);j.useEffect(()=>{w(t)},[t]);const f=()=>{if(n)return;const h=!p;w(h),o?.(h)},y=()=>({primary:{bg:"bg-primary",border:"border-primary",text:"text-primary"},secondary:{bg:"bg-secondary",border:"border-secondary",text:"text-secondary"}})[i],b=()=>{switch(a){case"sm":return"w-10 h-6";case"lg":return"w-16 h-8";case"md":default:return"w-13 h-7"}},x=()=>{switch(a){case"sm":return"w-5 h-5";case"lg":return"w-7 h-7";case"md":default:return"w-6 h-6"}},m=()=>{if(!p)return"translate-x-0";switch(a){case"sm":return"translate-x-5";case"lg":return"translate-x-8";case"md":default:return"translate-x-6"}},v=y();return s.jsxs("div",{className:c("flex items-center gap-3",n?"cursor-not-allowed":"cursor-pointer",d),onClick:f,children:[s.jsxs("div",{className:"relative",children:[s.jsx("input",{type:"checkbox",id:e,name:r,checked:p,onChange:()=>{},disabled:n,className:"sr-only","aria-label":l||r,...u}),s.jsx("div",{className:c("block transition-all duration-300 rounded-full border-2",b(),p?c(v.bg,v.border):"bg-gray-200 border-gray-300",n?"opacity-50":"hover:shadow-md"),children:s.jsx("span",{className:c("absolute top-0.5 left-0.5 inline-block rounded-full bg-white transition-all duration-300 shadow-sm",x(),m())})})]}),l&&s.jsx("span",{className:c("text-sm font-medium select-none",v.text,n&&"opacity-50"),children:l})]})}const Le=({size:e=40,wrapperStyle:r={},wrapperClass:t="",ariaLabel:o="Cargando...",label:n="Cargando...",visible:l=!0,direction:i="column"})=>{const a={display:"flex",flexDirection:i,justifyContent:"center",alignItems:"center",minHeight:"100px",...r};return s.jsxs("div",{style:a,className:t,children:[s.jsx("label",{children:n}),s.jsx(_e.Oval,{visible:l,height:e,width:e,ariaLabel:o,wrapperStyle:{},wrapperClass:"",secondaryColor:"#cdae90",color:"#cdae90"})]})},{Input:le}=Me,Cr=({title:e="Iniciar Sesión",showForgotPassword:r=!0,onlyForgotPassword:t=!1,className:o="",onLogin:n,onForgotPassword:l})=>{const[i,a]=j.useState({email:"",password:""}),[d,u]=j.useState({}),[p,w]=j.useState(!1),[f,y]=j.useState(t?"forgot":"login"),b=(z,g)=>{switch(z){case"email":return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(g)?"":"Por favor ingresa un email válido";case"password":return g.length>=6?"":"La contraseña debe tener al menos 6 caracteres";default:return""}},x=z=>{const{name:g,value:I}=z.target;a($=>({...$,[g]:I})),d[g]&&u($=>({...$,[g]:""}))},m=()=>{const z={},g=b("email",i.email);if(g&&(z.email=g),f==="login"){const I=b("password",i.password);I&&(z.password=I)}return u(z),Object.keys(z).length===0},v=async z=>{if(z.preventDefault(),!!m()){w(!0);try{switch(f){case"login":n&&await n({email:i.email,password:i.password});break;case"forgot":l&&await l(i.email);break}}catch(g){console.error("Login error:",g)}finally{w(!1)}}},h=z=>{y(z),u({}),a({email:i.email,password:""})},L=()=>{switch(f){case"forgot":return s.jsx(le,{id:"email",type:"email",name:"email",placeholder:"Ingresa tu email",label:"Email",value:i.email,onChange:x,error:d.email,disabled:p,colorScheme:"secondary"});default:return s.jsxs(s.Fragment,{children:[s.jsx(le,{id:"email",type:"email",name:"email",placeholder:"Ingresa tu email",label:"Email",value:i.email,onChange:x,error:d.email,disabled:p,colorScheme:"secondary"}),s.jsx(le,{id:"password",type:"password",name:"password",placeholder:"Ingresa tu contraseña",label:"Contraseña",value:i.password,onChange:x,error:d.password,disabled:p,colorScheme:"secondary"})]})}},E=()=>{switch(f){case"forgot":return t?"Cambiar Contraseña":"Recuperar Contraseña";default:return e}},S=()=>{if(p)return s.jsx(Le,{size:20,wrapperStyle:{minHeight:"auto"}});switch(f){case"forgot":return"Enviar Enlace";default:return"Entrar"}};return s.jsx("div",{className:`flex justify-center items-center min-h-[90vh] p-4 bg-background ${o||""}`,children:s.jsxs("div",{className:"w-full max-w-100 p-6 bg-white rounded-2xl shadow-lg animate-[fadeIn_0.3s_ease-out] sm:p-8",children:[s.jsx("h2",{className:"text-center mb-8 text-2xl font-semibold text-primary",children:E()}),s.jsxs("form",{onSubmit:v,children:[s.jsx("div",{className:"space-y-4 mb-6",children:L()}),s.jsx(J,{type:"submit",disabled:p,loading:p,fullWidth:!0,variant:"primary",size:"lg",className:"mb-6",children:!p&&S()})]}),f==="login"&&r&&s.jsx(J,{type:"button",onClick:()=>h("forgot"),variant:"link",size:"sm",fullWidth:!0,className:"shadow-none! !hover:shadow-none",children:"¿Olvidaste tu contraseña?"}),f==="forgot"&&!t&&s.jsx(J,{type:"button",onClick:()=>h("login"),variant:"link",size:"sm",fullWidth:!0,className:"shadow-none! !hover:shadow-none",children:"Volver al inicio de sesión"})]})})};var De={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},be=j.createContext&&j.createContext(De),Sr=["attr","size","title"];function Mr(e,r){if(e==null)return{};var t=Lr(e,r),o,n;if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(n=0;n<l.length;n++)o=l[n],!(r.indexOf(o)>=0)&&Object.prototype.propertyIsEnumerable.call(e,o)&&(t[o]=e[o])}return t}function Lr(e,r){if(e==null)return{};var t={};for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){if(r.indexOf(o)>=0)continue;t[o]=e[o]}return t}function oe(){return oe=Object.assign?Object.assign.bind():function(e){for(var r=1;r<arguments.length;r++){var t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},oe.apply(this,arguments)}function ge(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),t.push.apply(t,o)}return t}function ne(e){for(var r=1;r<arguments.length;r++){var t=arguments[r]!=null?arguments[r]:{};r%2?ge(Object(t),!0).forEach(function(o){Dr(e,o,t[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ge(Object(t)).forEach(function(o){Object.defineProperty(e,o,Object.getOwnPropertyDescriptor(t,o))})}return e}function Dr(e,r,t){return r=Er(r),r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function Er(e){var r=zr(e,"string");return typeof r=="symbol"?r:r+""}function zr(e,r){if(typeof e!="object"||!e)return e;var t=e[Symbol.toPrimitive];if(t!==void 0){var o=t.call(e,r);if(typeof o!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(e)}function Ee(e){return e&&e.map((r,t)=>j.createElement(r.tag,ne({key:t},r.attr),Ee(r.child)))}function U(e){return r=>j.createElement(Ar,oe({attr:ne({},e.attr)},r),Ee(e.child))}function Ar(e){var r=t=>{var{attr:o,size:n,title:l}=e,i=Mr(e,Sr),a=n||t.size||"1em",d;return t.className&&(d=t.className),e.className&&(d=(d?d+" ":"")+e.className),j.createElement("svg",oe({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},t.attr,o,i,{className:d,style:ne(ne({color:e.color||t.color},t.style),e.style),height:a,width:a,xmlns:"http://www.w3.org/2000/svg"}),l&&j.createElement("title",null,l),e.children)};return be!==void 0?j.createElement(be.Consumer,null,t=>r(t)):r(De)}function Pr(e){return U({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"circle",attr:{cx:"11",cy:"11",r:"8"},child:[]},{tag:"line",attr:{x1:"21",y1:"21",x2:"16.65",y2:"16.65"},child:[]}]})(e)}const ze=(e,r=500)=>{const[t,o]=j.useState(e);return j.useEffect(()=>{const n=setTimeout(()=>{o(e)},r);return()=>clearTimeout(n)},[e,r]),t},Tr=()=>({showToast:(r,t)=>{const o={position:"bottom-right",autoClose:2e3,hideProgressBar:!1,closeOnClick:!0,pauseOnHover:!0,draggable:!1,progress:void 0};switch(r){case"success":Q.toast.success(t,o);break;case"error":Q.toast.error(t,o);break;case"warning":Q.toast.warning(t,o);break;case"info":Q.toast.info(t,o);break;default:Q.toast(t,o);break}}});function Ir(e=768){const[r,t]=j.useState(()=>typeof window>"u"?!1:window.innerWidth<e);return j.useEffect(()=>{if(typeof window>"u")return;const o=()=>{t(window.innerWidth<e)};return window.addEventListener("resize",o),()=>{window.removeEventListener("resize",o)}},[e]),r}function Or({value:e,onChange:r,placeholder:t="Search...",disabled:o=!1,colorScheme:n="secondary",label:l,className:i="",debounceDelay:a=500,...d}){const[u,p]=j.useState(e||""),w=ze(u,a),f=j.useCallback(r,[r]);j.useEffect(()=>{f(w)},[w,f]);const y=()=>{const m="w-full px-4 py-2.5 pl-10 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed placeholder:text-text-muted";switch(n){case"primary":return c(m,"text-primary border-primary focus:border-primary");case"secondary":default:return c(m,"text-secondary border-secondary focus:border-secondary")}},b=()=>n==="primary"?"text-primary":"text-secondary",x=()=>n==="primary"?"text-primary":"text-secondary";return s.jsxs("div",{className:c("mb-0",i),children:[l&&s.jsx("label",{className:c("block mb-2 text-sm font-medium",x()),children:l}),s.jsxs("div",{className:"relative w-full",children:[s.jsx(Pr,{className:c("absolute left-3 top-1/2 -translate-y-1/2 text-base pointer-events-none",b())}),s.jsx("input",{type:"text",value:u,onChange:m=>p(m.target.value),placeholder:t,disabled:o,className:y(),...d})]})]})}function _r(e){return U({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M257.5 445.1l-22.2 22.2c-9.4 9.4-24.6 9.4-33.9 0L7 273c-9.4-9.4-9.4-24.6 0-33.9L201.4 44.7c9.4-9.4 24.6-9.4 33.9 0l22.2 22.2c9.5 9.5 9.3 25-.4 34.3L136.6 216H424c13.3 0 24 10.7 24 24v32c0 13.3-10.7 24-24 24H136.6l120.5 114.8c9.8 9.3 10 24.8.4 34.3z"},child:[]}]})(e)}function $r(e){return U({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M190.5 66.9l22.2-22.2c9.4-9.4 24.6-9.4 33.9 0L441 239c9.4 9.4 9.4 24.6 0 33.9L246.6 467.3c-9.4 9.4-24.6 9.4-33.9 0l-22.2-22.2c-9.5-9.5-9.3-25 .4-34.3L311.4 296H24c-13.3 0-24-10.7-24-24v-32c0-13.3 10.7-24 24-24h287.4L190.9 101.2c-9.8-9.3-10-24.8-.4-34.3z"},child:[]}]})(e)}function Fr({labelPage:e="Page",labelOf:r="of",setPagination:t,totalPages:o,currentPage:n,showLabel:l=!0,className:i="",isLoading:a=!1,fetchPage:d}){const u=parseInt(String(n))===1||parseInt(String(o))===0||a,p=parseInt(String(n))===parseInt(String(o))||parseInt(String(o))===0||a,w=()=>{a||(d?d(n-1):t&&t(y=>({...y,page:y.page-1})))},f=()=>{a||(d?d(n+1):t&&t(y=>({...y,page:y.page+1})))};return s.jsxs("div",{className:c("flex justify-center items-center mt-8",i),children:[s.jsx(J,{disabled:u,onClick:w,variant:"secondary",children:s.jsx(_r,{size:14})}),s.jsx("h5",{className:"font-bold mx-2.5 text-text",children:`${l?e:""} ${n}${l?` ${r} `:" / "}${o}`}),s.jsx(J,{disabled:p,onClick:f,variant:"primary",children:s.jsx($r,{size:14})})]})}function Ae(e){return U({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"m112 184 144 144 144-144"},child:[]}]})(e)}function Rr(e){return U({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"m289.94 256 95-95A24 24 0 0 0 351 127l-95 95-95-95a24 24 0 0 0-34 34l95 95-95 95a24 24 0 1 0 34 34l95-95 95 95a24 24 0 0 0 34-34z"},child:[]}]})(e)}function Vr(e){return U({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M456.69 421.39 362.6 327.3a173.81 173.81 0 0 0 34.84-104.58C397.44 126.38 319.06 48 222.72 48S48 126.38 48 222.72s78.38 174.72 174.72 174.72A173.81 173.81 0 0 0 327.3 362.6l94.09 94.09a25 25 0 0 0 35.3-35.3zM97.92 222.72a124.8 124.8 0 1 1 124.8 124.8 124.95 124.95 0 0 1-124.8-124.8z"},child:[]}]})(e)}function Br({title:e,subtitle:r,children:t,defaultExpanded:o=!1,expanded:n,onToggle:l,className:i="",colorScheme:a="primary",icon:d,disabled:u=!1,headerExtra:p}){const[w,f]=j.useState(o),y=n!==void 0?n:w,b=()=>{if(u)return;const h=!y;n===void 0&&f(h),l?.(h)},x=()=>a==="primary"?"border-primary":"border-secondary",m=()=>a==="primary"?"text-primary":"text-secondary",v=()=>a==="primary"?"hover:bg-primary/5":"hover:bg-secondary/5";return s.jsxs("div",{className:c("w-full rounded-lg border-2 bg-background transition-all duration-300",x(),y&&"shadow-lg",i),children:[s.jsxs("button",{type:"button",onClick:b,disabled:u,className:c("w-full flex cursor-pointer items-center justify-between p-4 text-left transition-all duration-300 rounded-lg",!u&&v(),u&&"opacity-50"),"aria-expanded":y,children:[s.jsxs("div",{className:"flex items-center gap-3 flex-1 min-w-0",children:[d&&s.jsx("div",{className:c("shrink-0",m()),children:d}),s.jsxs("div",{className:"flex-1 min-w-0",children:[s.jsx("h3",{className:c("text-base font-medium truncate",m()),children:e}),r&&s.jsx("p",{className:"text-sm text-text-muted truncate mt-0.5",children:r})]})]}),s.jsxs("div",{className:"flex items-center gap-3 shrink-0",children:[p&&s.jsx("div",{onClick:h=>h.stopPropagation(),children:p}),s.jsx("div",{className:c("h-5 w-5 transition-transform duration-300",m(),y&&"rotate-180"),children:s.jsx(Ae,{className:"h-5 w-5"})})]})]}),s.jsx("div",{className:c("overflow-hidden transition-all duration-300 ease-in-out",y?"max-h-500 opacity-100":"max-h-0 opacity-0"),children:s.jsx("div",{className:c("p-4 pt-0 border-t-0",x()),children:s.jsx("div",{className:"border-t border-border pt-4",children:t})})})]})}function Gr({children:e,className:r=""}){return s.jsx("div",{className:c("py-4",r),children:e})}function Hr({options:e,value:r,onChange:t,children:o,className:n="",colorScheme:l="primary",variant:i="underline"}){const[a,d]=j.useState(r??e[0]?.value??""),u=r!==void 0?r:a,p=b=>{r===void 0&&d(b),t?.(b)},w=(b,x)=>{const m=u===b,v="px-4 py-3 cursor-pointer text-sm font-medium transition-all duration-300 focus:outline-none disabled:opacity-50 disabled:cursor-not-allowed";if(x)return c(v,"text-text-muted");switch(i){case"filled":return c(v,"rounded-lg",m?l==="primary"?"bg-primary text-white":"bg-secondary text-white":"text-text-muted hover:bg-background-light");case"pills":return c(v,"rounded-full",m?l==="primary"?"bg-primary/10 text-primary border-2 border-primary":"bg-secondary/10 text-secondary border-2 border-secondary":"text-text-muted hover:bg-background-light border-2 border-transparent");case"underline":default:return c(v,"border-b-2 flex items-center gap-2",m?l==="primary"?"border-primary text-primary":"border-secondary text-secondary":"border-transparent text-gray-500 hover:text-gray-700")}},f=()=>{switch(i){case"filled":return"flex gap-1 p-1 bg-background-light rounded-lg";case"pills":return"flex gap-2 flex-wrap";case"underline":default:return"flex gap-2 border-b border-gray-200"}},y=j.Children.toArray(o).find(b=>j.isValidElement(b)?b.props.value===u:!1);return s.jsxs("div",{className:c("w-full",n),children:[s.jsx("div",{className:f(),role:"tablist",children:e.map(b=>s.jsxs("button",{type:"button",role:"tab","aria-selected":u===b.value,"aria-controls":`tabpanel-${b.value}`,disabled:b.disabled,onClick:()=>!b.disabled&&p(b.value),className:w(b.value,b.disabled),children:[b.icon&&s.jsx("span",{className:"shrink-0",children:b.icon}),b.label]},b.value))}),s.jsx("div",{role:"tabpanel",id:`tabpanel-${u}`,children:y})]})}function fe(e){return U({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M15.41 7.41 14 6l-6 6 6 6 1.41-1.41L10.83 12z"},child:[]}]})(e)}function he(e){return U({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"},child:[]}]})(e)}const Pe=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Te=["Lun","Mar","Mié","Jue","Vie","Sáb","Dom"],Ie=["January","February","March","April","May","June","July","August","September","October","November","December"],Oe=["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"];function Wr(e){return new Date(e.getFullYear(),e.getMonth()+1,0).getDate()}function Ur(e){const r=new Date(e.getFullYear(),e.getMonth(),1).getDay();return r===0?6:r-1}function Yr({value:e,onChange:r,disabled:t=!1,className:o="",colorScheme:n="secondary",lang:l="en",...i}){const[a,d]=j.useState(e||new Date),u={en:"en-US",es:"es-ES"},p={en:Pe,es:Te},w={en:Ie,es:Oe},f=Wr(a),y=Ur(a),b=[];for(let g=0;g<y;g++)b.push(null);for(let g=1;g<=f;g++){const I=new Date(a.getFullYear(),a.getMonth(),g,12,0,0);b.push(I)}const x=()=>{d(new Date(a.getFullYear(),a.getMonth()-1,1,12,0,0))},m=()=>{d(new Date(a.getFullYear(),a.getMonth()+1,1,12,0,0))},v=()=>{d(new Date(a.getFullYear()-1,a.getMonth(),1,12,0,0))},h=()=>{d(new Date(a.getFullYear()+1,a.getMonth(),1,12,0,0))},L=g=>{if(g&&!t){const I=new Date(g.getFullYear(),g.getMonth(),g.getDate(),12,0,0);d(I),r?.(I)}},S=(()=>{switch(n){case"primary":return{header:"text-primary",selected:"bg-primary text-white",hover:"hover:bg-primary/10",button:"text-primary border-primary hover:bg-primary/20"};case"secondary":default:return{header:"text-secondary",selected:"bg-secondary text-white",hover:"hover:bg-secondary/10",button:"text-secondary border-secondary hover:bg-secondary/20"}}})(),z=g=>g&&e?g.toDateString()===e.toDateString():!1;return s.jsxs("div",{className:c("w-full max-w-sm bg-background border-2 border-border rounded-lg p-6 shadow-md",o),...i,children:[s.jsxs("div",{className:"mb-6",children:[s.jsxs("div",{className:c("flex items-center justify-between mb-4",S.header),children:[s.jsx("button",{type:"button",onClick:v,disabled:t,className:c("p-2 rounded-lg border transition-all duration-300",S.button,t&&"opacity-50 cursor-not-allowed"),children:s.jsx(fe,{size:18})}),s.jsx("h2",{className:"font-semibold text-lg",children:a.getFullYear()}),s.jsx("button",{type:"button",onClick:h,disabled:t,className:c("p-2 rounded-lg border transition-all duration-300",S.button,t&&"opacity-50 cursor-not-allowed"),children:s.jsx(he,{size:18})})]}),s.jsxs("div",{className:c("flex items-center justify-between",S.header),children:[s.jsx("button",{type:"button",onClick:x,disabled:t,className:c("p-2 rounded-lg border transition-all duration-300",S.button,t&&"opacity-50 cursor-not-allowed"),children:s.jsx(fe,{size:18})}),s.jsx("h2",{className:"font-semibold text-lg",children:w[l][a.getMonth()]}),s.jsx("button",{type:"button",onClick:m,disabled:t,className:c("p-2 rounded-lg border transition-all duration-300",S.button,t&&"opacity-50 cursor-not-allowed"),children:s.jsx(he,{size:18})})]})]}),s.jsx("div",{className:"grid grid-cols-7 gap-2 mb-4",children:p[l].map(g=>s.jsx("div",{className:c("text-center text-sm font-medium py-2",S.header),children:g},g))}),s.jsx("div",{className:"grid grid-cols-7 gap-2",children:b.map((g,I)=>s.jsx("button",{type:"button",onClick:()=>L(g),disabled:!g||t,className:c("p-2 rounded-lg text-sm font-medium transition-all duration-300",g?c("cursor-pointer",S.hover,z(g)?S.selected:"text-text border border-transparent hover:border-border",t&&"opacity-50 cursor-not-allowed"):"cursor-default"),children:g?g.getDate():""},I))}),e&&s.jsx("div",{className:c("mt-6 p-3 rounded-lg bg-background-dark border border-border text-center text-sm font-medium",S.header),children:e.toLocaleDateString(u[l],{year:"numeric",month:"long",day:"numeric"})})]})}function Jr({headers:e,data:r,loading:t,loadingText:o="Loading...",actions:n,actionsHeader:l="Actions",onRowClick:i,className:a="",rowClassName:d="",cellClassName:u="",headerClassName:p="",emptyText:w="No data available",showCount:f=!0,countText:y=x=>`Showing ${x} record${x!==1?"s":""}`,keyExtractor:b=(x,m)=>x._id||x.id||m}){if(t)return s.jsx("div",{className:"flex justify-center items-center min-h-50",children:s.jsx("div",{className:"text-lg text-text-light",children:o})});if(r.length===0)return s.jsx("div",{className:"flex justify-center items-center min-h-50",children:s.jsx("div",{className:"text-lg text-text-muted",children:w})});const x=(m,v)=>{const h=v.toLowerCase().replace(/\s+/g,"_");let L=m[h];if(L===void 0){const E=[h.replace(/_/g,""),v.toLowerCase().replace(/\s+/g,""),h.replace(/_([a-z])/g,(S,z)=>z.toUpperCase())];for(const S of E)if(m[S]!==void 0){L=m[S];break}}if(L===void 0){const E=v.toLowerCase().split(" "),S=Object.keys(m).find(z=>E.some(g=>z.toLowerCase().includes(g)));S&&(L=m[S])}return L!=null?String(L):"N/A"};return s.jsxs("div",{className:c("overflow-x-auto",a),children:[s.jsxs("table",{className:"w-full border-collapse",children:[s.jsx("thead",{children:s.jsxs("tr",{className:"border-b-2 border-border",children:[e.map((m,v)=>s.jsx("th",{className:c("text-left py-3 px-4 font-semibold text-text",p),children:m},v)),n&&s.jsx("th",{className:c("text-center py-3 px-4 font-semibold text-text",p),children:l})]})}),s.jsx("tbody",{children:r.map((m,v)=>s.jsxs("tr",{className:c("border-b border-border-dark hover:bg-background-light transition-colors",i&&"cursor-pointer",d),onClick:()=>i?.(m),children:[e.map((h,L)=>s.jsx("td",{className:c("py-4 px-4",u),children:s.jsx("div",{className:"text-text-light",children:x(m,h)})},L)),n&&s.jsx("td",{className:c("py-4 px-4",u),children:s.jsx("div",{className:"flex gap-2 justify-center",children:n.map((h,L)=>{const E=S=>{S?.stopPropagation(),h.onClick?.(m)};if(h.component){const S=h.component;return s.jsxs(S,{onClick:E,className:h.className||"",...h.props||{},children:[h.icon&&s.jsx("span",{className:"inline-block",children:j.createElement(h.icon)}),h.label&&h.label]},L)}return s.jsxs(J,{onClick:E,className:h.className||"",...h.props||{},children:[h.icon&&s.jsx("span",{className:"inline-block",children:j.createElement(h.icon)}),h.label&&h.label]},L)})})})]},b(m,v)))})]}),f&&r.length>0&&s.jsx("div",{className:"mt-6 text-center text-text-light text-sm",children:y(r.length)})]})}function Kr({label:e,options:r,value:t="",onChange:o,multiple:n=!1,className:l="",searchable:i=!1,onSearchInputCustom:a,placeholder:d="Select...",disabled:u=!1,error:p,required:w=!1,colorScheme:f="primary",noResultsText:y="No results found",searchPlaceholder:b="Search...",...x}){const[m,v]=j.useState(!1),[h,L]=j.useState(""),[E,S]=j.useState({top:0,left:0,openUpward:!1}),z=Array.isArray(t)?t:t?[t]:[],[g,I]=j.useState(z.map(k=>r.find(M=>M.value===k)).filter(Boolean)),$=j.useRef(null),B=j.useRef(null),Y=()=>{const k="w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed";if(p)return c(k,"border-danger focus:border-danger");switch(f){case"primary":return c(k,"text-primary border-primary focus:border-primary");case"secondary":default:return c(k,"text-secondary border-secondary focus:border-secondary")}},D=()=>f==="primary"?"text-primary":"text-secondary";j.useEffect(()=>{const M=(Array.isArray(t)?t:t!==""&&t!==null&&t!==void 0?[t]:[]).map(F=>r.find(R=>R.value===F)).filter(Boolean);I(M)},[t,r]),j.useEffect(()=>{m&&i&&B.current&&B.current.focus()},[m,i]);const C=j.useCallback(()=>{if(!$.current)return;const k=$.current.getBoundingClientRect(),M=window.innerHeight,F=250,q=M-k.bottom<F&&k.top>F;S({top:q?k.top:k.bottom,left:k.left,width:k.width,openUpward:q})},[]);j.useEffect(()=>{function k(F){$.current&&!$.current.contains(F.target)&&v(!1)}function M(){m&&C()}return document.addEventListener("mousedown",k),window.addEventListener("scroll",M,!0),window.addEventListener("resize",M),()=>{document.removeEventListener("mousedown",k),window.removeEventListener("scroll",M,!0),window.removeEventListener("resize",M)}},[m,C]);const A=k=>{const M=r.find(R=>R.value===k);if(!M)return;let F;n?(F=g.some(q=>q.value===k)?g.filter(q=>q.value!==k):[...g,M],I(F),o(F)):(F=[M],I(F),o(M),v(!1),L(""))},V=k=>{L(k),a?.(k)},_=i?r.filter(k=>k.label.toLowerCase().includes(h.toLowerCase())):r,K=()=>g.length===0?d:n?g.length===1?g[0].label:`${g.length} selected`:g[0]?.label||d;return s.jsxs("div",{className:c("mb-6",l),children:[e&&s.jsxs("label",{className:c("block mb-2 text-sm font-medium",D()),children:[e,w&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsxs("div",{ref:$,className:"relative w-full",children:[s.jsxs("button",{type:"button",onClick:k=>{k.preventDefault(),k.stopPropagation(),m||C(),v(!m)},className:c(Y(),"inline-flex items-center justify-between cursor-pointer h-auto min-h-14",u&&"cursor-not-allowed",m&&"ring-1"),disabled:u,...x,children:[s.jsxs("div",{className:"flex items-center gap-2 flex-1",children:[g.length>0&&g[0].hex&&s.jsx("div",{className:"h-4 w-4 rounded border border-border",style:{backgroundColor:g[0].hex}}),s.jsx("span",{className:g.length>0?"":"text-text-muted",children:K()})]}),s.jsx("div",{className:c("h-5 w-5 transition-transform duration-200",m&&"rotate-180"),children:s.jsx(Ae,{className:"h-5 w-5"})})]}),m&&s.jsxs("div",{className:c("fixed z-9999 rounded-lg border-2 bg-white shadow-xl",p?"border-danger":f==="primary"?"border-primary":"border-secondary"),style:{top:`${E.top+(E.openUpward?0:8)}px`,left:`${E.left}px`,width:`${E.width}px`,transform:E.openUpward?"translateY(-100%)":"none"},children:[i&&s.jsx("div",{className:"border-b border-border p-3",children:s.jsxs("div",{className:"relative",children:[s.jsx(Vr,{className:"absolute top-1/2 left-3 h-4 w-4 -translate-y-1/2 transform text-text-muted"}),s.jsx("input",{ref:B,type:"text",value:h,onChange:k=>V(k.target.value),placeholder:b,className:c("w-full rounded-lg border-2 py-2 pr-10 pl-10 text-sm transition-all duration-300 focus:outline-none focus:ring-1",f==="primary"?"border-primary text-primary":"border-secondary text-secondary")}),h&&s.jsx("button",{type:"button",onClick:()=>L(""),className:"absolute top-1/2 right-3 h-4 w-4 -translate-y-1/2 transform text-text-muted hover:text-text",children:s.jsx(Rr,{className:"h-4 w-4"})})]})}),s.jsxs("div",{className:"max-h-60 overflow-y-auto py-1",children:[_.map(k=>s.jsx("button",{type:"button",onClick:()=>A(k.value??""),className:c("w-full px-4 py-3 text-left text-sm transition-colors",g.some(M=>M.value===k.value)?f==="primary"?"bg-primary/10 text-primary font-medium":"bg-secondary/10 text-secondary font-medium":"text-text hover:bg-background-light"),children:s.jsxs("div",{className:"flex items-center gap-3",children:[n&&s.jsx("div",{className:c("flex h-4 w-4 items-center justify-center rounded border-2 transition-colors",g.some(M=>M.value===k.value)?f==="primary"?"border-primary bg-primary":"border-secondary bg-secondary":"border-border"),children:g.some(M=>M.value===k.value)&&s.jsx("svg",{className:"h-3 w-3 text-white",fill:"currentColor",viewBox:"0 0 20 20",children:s.jsx("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})})}),k.hex&&s.jsx("div",{className:"h-4 w-4 rounded border border-border",style:{backgroundColor:k.hex}}),s.jsx("span",{children:k.label})]})},k.value)),_.length===0&&h&&r.length>0&&s.jsx("div",{className:"px-4 py-3",children:s.jsx("span",{className:"text-sm text-text-muted",children:y})})]})]})]}),p&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:p})]})}const qr=({id:e,name:r,onFilesSelected:t,placeholder:o="Arrastra y suelta archivos aquí o haz clic para seleccionar",labelSelectedFiles:n="archivo:",label:l,error:i,disabled:a=!1,required:d=!1,colorScheme:u="secondary",className:p="",accept:w="*/*",multiple:f=!1,...y})=>{const b=j.useRef(null),[x,m]=j.useState(!1),[v,h]=j.useState([]),L=()=>{const C="w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed cursor-pointer min-h-[120px]";if(i)return c(C,"border-danger focus:border-danger focus:ring-1 focus:ring-danger");switch(u){case"primary":return c(C,"border-primary focus:border-primary focus:ring-1 focus:ring-primary hover:border-primary-dark");case"secondary":default:return c(C,"border-secondary focus:border-secondary focus:ring-1 focus:ring-secondary hover:border-secondary-dark")}},E=()=>{switch(u){case"primary":return"text-primary";case"secondary":default:return"text-secondary"}},S=C=>{C.preventDefault(),C.stopPropagation(),a||(C.type==="dragenter"||C.type==="dragover"?m(!0):C.type==="dragleave"&&m(!1))},z=C=>{if(C.preventDefault(),C.stopPropagation(),m(!1),a)return;const A=C.dataTransfer.files;I(A)},g=C=>{const A=C.target.files;A&&I(A)},I=C=>{const A=Array.from(C);if(w!=="*/*"){const V=A.filter(_=>$(_,w));if(V.length===0){console.warn("No valid files selected");return}h(f?V:[V[0]]),t(f?V:[V[0]])}else h(f?A:[A[0]]),t(f?A:[A[0]])},$=(C,A)=>A.split(",").map(_=>_.trim()).some(_=>{if(_.startsWith("."))return C.name.toLowerCase().endsWith(_.toLowerCase());if(_.includes("/")){const[K,k]=_.split("/"),M=C.type.split("/")[0];return k==="*"?M===K:C.type===_}return!1}),B=()=>{a||b.current?.click()},Y=C=>{const A=v.filter((V,_)=>_!==C);h(A),t(A)},D=C=>{(C.key==="Enter"||C.key===" ")&&(C.preventDefault(),B())};return s.jsxs("div",{className:`mb-6 ${p}`,children:[l&&s.jsxs("label",{className:`block mb-2 text-sm font-medium ${E()}`,children:[l,d&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsxs("div",{className:c(L(),x&&"bg-background-light border-2-dashed"),onDragEnter:S,onDragLeave:S,onDragOver:S,onDrop:z,onClick:B,onKeyDown:D,role:"button",tabIndex:a?-1:0,children:[s.jsx("input",{ref:b,id:e,name:r,type:"file",onChange:g,disabled:a,required:d,accept:w,multiple:f,className:"hidden",...y}),s.jsxs("div",{className:"flex flex-col items-center justify-center py-4",children:[s.jsx("svg",{className:`w-8 h-8 mb-2 ${u==="primary"?"text-primary":"text-secondary"}`,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 4v16m8-8H4"})}),s.jsx("p",{className:`text-sm ${E()}`,children:o})]})]}),s.jsxs("div",{className:"mt-4 space-y-2",children:[s.jsxs("p",{className:`text-sm font-medium ${E()}`,children:[v.length," ",n,"(s) seleccionado(s):"]}),s.jsx("ul",{className:"space-y-1",children:v.map((C,A)=>s.jsxs("li",{className:"flex items-center justify-between p-2 bg-light rounded border border-border",children:[s.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[s.jsxs("svg",{className:"w-4 h-4 text-text-muted shrink-0",fill:"currentColor",viewBox:"0 0 20 20",children:[s.jsx("path",{d:"M8 16.5a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0zM15 16.5a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0z"}),s.jsx("path",{d:"M3 4a1 1 0 00-1 1v10a1 1 0 001 1h1.05a2.5 2.5 0 014.9 0H10a1 1 0 001-1V5a1 1 0 00-1-1H3zM14 7a1 1 0 00-1 1v6.05A2.5 2.5 0 0115.95 10H17a1 1 0 001-1v-3a1 1 0 00-1-1h-3z"})]}),s.jsx("span",{className:"text-sm text-text truncate",children:C.name})]}),s.jsx("button",{onClick:V=>{V.stopPropagation(),Y(A)},className:"ml-2 text-danger hover:text-danger-dark shrink-0",type:"button",children:"✕"})]},A))})]}),i&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:i})]})},Zr=({text:e,className:r="",variant:t="default",visible:o=!0,...n})=>{if(!o)return null;const l={default:"bg-gray-200 text-gray-800",primary:"bg-primary text-white",secondary:"bg-secondary text-white",secondaryDark:"bg-secondary-dark text-white",danger:"bg-danger text-white",warning:"bg-warning text-white"},i="inline-flex items-center px-3 py-1 rounded-full text-xs font-bold uppercase shadow-md",a=l[t]||l.default;return s.jsx("div",{className:`${i} ${a} ${r}`,...n,children:e})};function Xr({isOpen:e,onClose:r,title:t,children:o,size:n="md",className:l="",overlayClassName:i="",showCloseButton:a=!0,closeOnOverlayClick:d=!0,closeOnEscape:u=!0}){if(j.useEffect(()=>(e?document.body.style.overflow="hidden":document.body.style.overflow="unset",()=>{document.body.style.overflow="unset"}),[e]),j.useEffect(()=>{if(!u||!e)return;const y=b=>{b.key==="Escape"&&r()};return document.addEventListener("keydown",y),()=>{document.removeEventListener("keydown",y)}},[e,r,u]),!e)return null;const p={sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",xl:"max-w-xl","2xl":"max-w-2xl"},w=()=>{d&&r()},f=s.jsx("div",{className:c("fixed inset-0 bg-black/40 flex items-center justify-center z-9999 p-4",i),onClick:w,role:"dialog","aria-modal":"true","aria-labelledby":t?"modal-title":void 0,children:s.jsxs("div",{className:c("relative bg-white rounded-xl shadow-2xl max-h-[90vh] flex flex-col w-full transition-all duration-300",p[n],l),onClick:y=>y.stopPropagation(),children:[(t||a)&&s.jsxs("div",{className:"flex justify-between items-center px-6 py-5 border-b border-border rounded-t-xl shrink-0",children:[t&&s.jsx("h2",{id:"modal-title",className:"text-xl sm:text-2xl font-bold text-primary m-0",children:t}),a&&s.jsx("button",{className:"flex items-center justify-center w-8 h-8 text-text-muted hover:text-text hover:bg-background-light transition-colors duration-200 rounded-lg",onClick:r,"aria-label":"Cerrar modal",type:"button",children:s.jsx("span",{className:"text-2xl font-light leading-none",children:"×"})})]}),s.jsx("div",{className:"p-6 overflow-y-auto flex-1",children:o})]})});return $e.createPortal(f,document.body)}function Qr({id:e,name:r,checked:t=!1,onChange:o,disabled:n=!1,required:l=!1,colorScheme:i="secondary",variant:a="solid",label:d,className:u="",...p}){const w=(f,y)=>{const b="checkbox-input size-4 shrink-0 rounded transition-all duration-300 cursor-pointer focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-opacity-50 disabled:cursor-not-allowed disabled:opacity-50";if(f==="outline")switch(y){case"primary":return`${b} checkbox-outline checkbox-primary`;case"secondary":default:return`${b} checkbox-outline checkbox-secondary`}else switch(y){case"primary":return`${b} checkbox-solid checkbox-primary`;case"secondary":default:return`${b} checkbox-solid checkbox-secondary`}};return d?s.jsxs("div",{className:`flex items-center gap-2 ${u}`,children:[s.jsx("input",{id:e,name:r,type:"checkbox",checked:t,onChange:o,disabled:n,required:l,className:w(a,i),...p}),s.jsxs("label",{htmlFor:e,className:"text-sm text-text cursor-pointer font-medium",children:[d,l&&s.jsx("span",{className:"text-red-500 ml-1",children:"*"})]})]}):s.jsx("input",{id:e,name:r,type:"checkbox",checked:t,onChange:o,disabled:n,required:l,className:`${w(a,i)} ${u}`,style:{accentColor:"white"},...p})}const te=e=>String(e).padStart(2,"0"),xe=e=>!e||Number.isNaN(e.getTime())?"":`${e.getFullYear()}-${te(e.getMonth()+1)}-${te(e.getDate())}T${te(e.getHours())}:${te(e.getMinutes())}`,et=e=>{if(!e)return null;const r=new Date(e);return Number.isNaN(r.getTime())?null:r};function rt({id:e,name:r,value:t,onChange:o,min:n,label:l,error:i,disabled:a=!1,required:d=!1,colorScheme:u="secondary",className:p="",...w}){const f=c("w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed",i?"border-danger focus:border-danger focus:shadow-danger-light":u==="primary"?"text-primary border-primary focus:border-primary":"text-secondary border-secondary focus:border-secondary");return s.jsxs("div",{className:c("mb-6",p),children:[l&&s.jsxs("label",{htmlFor:e,className:c("block mb-2 text-sm font-medium",u==="primary"?"text-primary":"text-secondary"),children:[l,d&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsx("input",{id:e,name:r,type:"datetime-local",value:xe(t),onChange:y=>o(et(y.target.value)),min:n?xe(n):void 0,disabled:a,required:d,"aria-invalid":i?!0:void 0,className:f,...w}),i&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:i})]})}const tt={pulse:"cmp-skeleton-pulse",wave:"cmp-skeleton-wave",none:""},T=({className:e="",animation:r="pulse"})=>{const t=/(^|\s)rounded/.test(e);return s.jsx("div",{className:c("bg-gray-200",tt[r],!t&&"rounded-md",e)})},st=({count:e=6,className:r="",animation:t="pulse"})=>s.jsx("div",{className:c("divide-y divide-gray-200",r),children:Array.from({length:e}).map((o,n)=>s.jsxs("div",{className:"flex items-center justify-between py-3",children:[s.jsxs("div",{className:"flex flex-col gap-1.5 min-w-0",children:[s.jsx(T,{className:"h-4 w-40",animation:t}),s.jsx(T,{className:"h-3 w-28",animation:t})]}),s.jsx(T,{className:"h-4 w-12 shrink-0 ml-3",animation:t})]},n))}),ot=({animation:e})=>s.jsxs("div",{className:"bg-white border border-gray-200 rounded-xl shadow-sm flex items-stretch overflow-hidden",children:[s.jsx(T,{className:"shrink-0 w-36 h-[120px] rounded-none",animation:e}),s.jsxs("div",{className:"flex-1 p-4 min-w-0 flex flex-col justify-center gap-2",children:[s.jsx(T,{className:"h-5 w-1/3",animation:e}),s.jsxs("div",{className:"flex items-center gap-1.5",children:[s.jsx(T,{className:"h-4 w-16 rounded-full",animation:e}),s.jsx(T,{className:"h-4 w-20 rounded-full",animation:e}),s.jsx(T,{className:"h-4 w-24 rounded-full",animation:e})]}),s.jsx(T,{className:"h-3 w-2/3",animation:e})]}),s.jsxs("div",{className:"shrink-0 flex items-center gap-2 px-4 border-l border-gray-100",children:[s.jsx(T,{className:"h-8 w-8",animation:e}),s.jsx(T,{className:"h-8 w-8",animation:e}),s.jsx(T,{className:"h-8 w-8",animation:e})]})]}),nt=({count:e=6,className:r="",animation:t="pulse"})=>s.jsx("div",{className:c("flex flex-col gap-3",r),children:Array.from({length:e}).map((o,n)=>s.jsx(ot,{animation:t},n))}),at={2:"grid-cols-1 sm:grid-cols-2",3:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-3",4:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-4"},lt={video:"aspect-video",square:"aspect-square","4/3":"aspect-4/3",auto:""},it=({aspect:e,animation:r})=>s.jsxs("div",{className:"bg-white border border-gray-200 rounded-xl shadow-sm overflow-hidden flex flex-col",children:[s.jsx(T,{className:c("w-full rounded-none",lt[e]||"h-40"),animation:r}),s.jsxs("div",{className:"p-4 flex-1 flex flex-col",children:[s.jsx(T,{className:"h-5 w-4/5 mb-2",animation:r}),s.jsx(T,{className:"h-3 w-full mb-1.5",animation:r}),s.jsx(T,{className:"h-3 w-2/3 mb-3",animation:r}),s.jsxs("div",{className:"mt-auto flex items-center justify-between",children:[s.jsx(T,{className:"h-3 w-16",animation:r}),s.jsx(T,{className:"h-8 w-24 rounded-lg",animation:r})]})]})]}),ct=({count:e=6,columns:r=3,aspect:t="4/3",className:o="",animation:n="pulse"})=>s.jsx("div",{className:c("grid gap-6",at[r],o),children:Array.from({length:e}).map((l,i)=>s.jsx(it,{aspect:t,animation:n},i))}),dt=({rows:e=8,columns:r=6,className:t="",animation:o="pulse"})=>s.jsxs("div",{className:c("w-full",t),children:[s.jsx("div",{className:"flex gap-4 border-b border-gray-200 pb-3 mb-3",children:Array.from({length:r}).map((n,l)=>s.jsx(T,{className:"h-4 flex-1",animation:o},l))}),Array.from({length:e}).map((n,l)=>s.jsx("div",{className:"flex gap-4 py-3 border-b border-gray-100 last:border-0",children:Array.from({length:r}).map((i,a)=>s.jsx(T,{className:"h-4 flex-1",animation:o},a))},l))]}),ut=({count:e=3,className:r="",animation:t="pulse"})=>s.jsx("div",{className:c("space-y-4",r),children:Array.from({length:e}).map((o,n)=>s.jsxs("div",{children:[s.jsxs("div",{className:"flex justify-between mb-1",children:[s.jsx(T,{className:"h-3 w-32",animation:t}),s.jsx(T,{className:"h-3 w-10",animation:t})]}),s.jsx(T,{className:"h-2 w-full rounded-full",animation:t})]},n))}),{Input:mt,InputArea:pt}=Me;exports.Badge=Zr;exports.Button=J;exports.Calendar=Yr;exports.Checkbox=Qr;exports.DateTimePicker=rt;exports.Dropdown=Kr;exports.EN_DEFAULT_DAY_NAMES=Pe;exports.EN_DEFAULT_MONTH_NAMES=Ie;exports.ES_DEFAULT_DAY_NAMES=Te;exports.ES_DEFAULT_MONTH_NAMES=Oe;exports.ExpandableCard=Br;exports.FileDropZone=qr;exports.Input=mt;exports.InputArea=pt;exports.Loader=Le;exports.Login=Cr;exports.Modal=Xr;exports.Pagination=Fr;exports.SearchInput=Or;exports.Skeleton=T;exports.SkeletonBars=ut;exports.SkeletonCardList=nt;exports.SkeletonGrid=ct;exports.SkeletonList=st;exports.SkeletonTable=dt;exports.TabPanel=Gr;exports.Table=Jr;exports.Tabs=Hr;exports.ThemeProvider=yr;exports.Toggle=Nr;exports.cn=c;exports.defaultTheme=O;exports.generateColorVariants=se;exports.hexToHsl=Ce;exports.hslToHex=ce;exports.useDebounce=ze;exports.useIsMobile=Ir;exports.useTheme=xr;exports.useToast=Tr;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),v=require("react"),_e=require("react-loader-spinner"),$e=require("react-dom"),Q=require("react-toastify");function ye(e){var r,t,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(r=0;r<n;r++)e[r]&&(t=ye(e[r]))&&(o&&(o+=" "),o+=t)}else for(t in e)e[t]&&(o&&(o+=" "),o+=t);return o}function Fe(){for(var e,r,t=0,o="",n=arguments.length;t<n;t++)(e=arguments[t])&&(r=ye(e))&&(o&&(o+=" "),o+=r);return o}const de="-",Re=e=>{const r=Be(e),{conflictingClassGroups:t,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:i=>{const a=i.split(de);return a[0]===""&&a.length!==1&&a.shift(),we(a,r)||Ve(i)},getConflictingClassGroupIds:(i,a)=>{const d=t[i]||[];return a&&o[i]?[...d,...o[i]]:d}}},we=(e,r)=>{if(e.length===0)return r.classGroupId;const t=e[0],o=r.nextPart.get(t),n=o?we(e.slice(1),o):void 0;if(n)return n;if(r.validators.length===0)return;const l=e.join(de);return r.validators.find(({validator:i})=>i(l))?.classGroupId},ue=/^\[(.+)\]$/,Ve=e=>{if(ue.test(e)){const r=ue.exec(e)[1],t=r?.substring(0,r.indexOf(":"));if(t)return"arbitrary.."+t}},Be=e=>{const{theme:r,prefix:t}=e,o={nextPart:new Map,validators:[]};return He(Object.entries(e.classGroups),t).forEach(([l,i])=>{ie(i,o,l,r)}),o},ie=(e,r,t,o)=>{e.forEach(n=>{if(typeof n=="string"){const l=n===""?r:me(r,n);l.classGroupId=t;return}if(typeof n=="function"){if(Ge(n)){ie(n(o),r,t,o);return}r.validators.push({validator:n,classGroupId:t});return}Object.entries(n).forEach(([l,i])=>{ie(i,me(r,l),t,o)})})},me=(e,r)=>{let t=e;return r.split(de).forEach(o=>{t.nextPart.has(o)||t.nextPart.set(o,{nextPart:new Map,validators:[]}),t=t.nextPart.get(o)}),t},Ge=e=>e.isThemeGetter,He=(e,r)=>r?e.map(([t,o])=>{const n=o.map(l=>typeof l=="string"?r+l:typeof l=="object"?Object.fromEntries(Object.entries(l).map(([i,a])=>[r+i,a])):l);return[t,n]}):e,We=e=>{if(e<1)return{get:()=>{},set:()=>{}};let r=0,t=new Map,o=new Map;const n=(l,i)=>{t.set(l,i),r++,r>e&&(r=0,o=t,t=new Map)};return{get(l){let i=t.get(l);if(i!==void 0)return i;if((i=o.get(l))!==void 0)return n(l,i),i},set(l,i){t.has(l)?t.set(l,i):n(l,i)}}},ve="!",Ue=e=>{const{separator:r,experimentalParseClassName:t}=e,o=r.length===1,n=r[0],l=r.length,i=a=>{const d=[];let u=0,b=0,w;for(let m=0;m<a.length;m++){let j=a[m];if(u===0){if(j===n&&(o||a.slice(m,m+l)===r)){d.push(a.slice(b,m)),b=m+l;continue}if(j==="/"){w=m;continue}}j==="["?u++:j==="]"&&u--}const g=d.length===0?a:a.substring(b),x=g.startsWith(ve),p=x?g.substring(1):g,y=w&&w>b?w-b:void 0;return{modifiers:d,hasImportantModifier:x,baseClassName:p,maybePostfixModifierPosition:y}};return t?a=>t({className:a,parseClassName:i}):i},Ye=e=>{if(e.length<=1)return e;const r=[];let t=[];return e.forEach(o=>{o[0]==="["?(r.push(...t.sort(),o),t=[]):t.push(o)}),r.push(...t.sort()),r},Je=e=>({cache:We(e.cacheSize),parseClassName:Ue(e),...Re(e)}),Ke=/\s+/,qe=(e,r)=>{const{parseClassName:t,getClassGroupId:o,getConflictingClassGroupIds:n}=r,l=[],i=e.trim().split(Ke);let a="";for(let d=i.length-1;d>=0;d-=1){const u=i[d],{modifiers:b,hasImportantModifier:w,baseClassName:g,maybePostfixModifierPosition:x}=t(u);let p=!!x,y=o(p?g.substring(0,x):g);if(!y){if(!p){a=u+(a.length>0?" "+a:a);continue}if(y=o(g),!y){a=u+(a.length>0?" "+a:a);continue}p=!1}const m=Ye(b).join(":"),j=w?m+ve:m,h=j+y;if(l.includes(h))continue;l.push(h);const S=n(y,p);for(let L=0;L<S.length;++L){const M=S[L];l.push(j+M)}a=u+(a.length>0?" "+a:a)}return a};function Ze(){let e=0,r,t,o="";for(;e<arguments.length;)(r=arguments[e++])&&(t=je(r))&&(o&&(o+=" "),o+=t);return o}const je=e=>{if(typeof e=="string")return e;let r,t="";for(let o=0;o<e.length;o++)e[o]&&(r=je(e[o]))&&(t&&(t+=" "),t+=r);return t};function Xe(e,...r){let t,o,n,l=i;function i(d){const u=r.reduce((b,w)=>w(b),e());return t=Je(u),o=t.cache.get,n=t.cache.set,l=a,a(d)}function a(d){const u=o(d);if(u)return u;const b=qe(d,t);return n(d,b),b}return function(){return l(Ze.apply(null,arguments))}}const P=e=>{const r=t=>t[e]||[];return r.isThemeGetter=!0,r},ke=/^\[(?:([a-z-]+):)?(.+)\]$/i,Qe=/^\d+\/\d+$/,er=new Set(["px","full","screen"]),rr=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,tr=/\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$/,sr=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,or=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,nr=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,G=e=>Z(e)||er.has(e)||Qe.test(e),H=e=>X(e,"length",pr),Z=e=>!!e&&!Number.isNaN(Number(e)),ae=e=>X(e,"number",Z),ee=e=>!!e&&Number.isInteger(Number(e)),ar=e=>e.endsWith("%")&&Z(e.slice(0,-1)),N=e=>ke.test(e),W=e=>rr.test(e),lr=new Set(["length","size","percentage"]),ir=e=>X(e,lr,Ne),cr=e=>X(e,"position",Ne),dr=new Set(["image","url"]),ur=e=>X(e,dr,gr),mr=e=>X(e,"",br),re=()=>!0,X=(e,r,t)=>{const o=ke.exec(e);return o?o[1]?typeof r=="string"?o[1]===r:r.has(o[1]):t(o[2]):!1},pr=e=>tr.test(e)&&!sr.test(e),Ne=()=>!1,br=e=>or.test(e),gr=e=>nr.test(e),fr=()=>{const e=P("colors"),r=P("spacing"),t=P("blur"),o=P("brightness"),n=P("borderColor"),l=P("borderRadius"),i=P("borderSpacing"),a=P("borderWidth"),d=P("contrast"),u=P("grayscale"),b=P("hueRotate"),w=P("invert"),g=P("gap"),x=P("gradientColorStops"),p=P("gradientColorStopPositions"),y=P("inset"),m=P("margin"),j=P("opacity"),h=P("padding"),S=P("saturate"),L=P("scale"),M=P("sepia"),z=P("skew"),f=P("space"),I=P("translate"),$=()=>["auto","contain","none"],B=()=>["auto","hidden","clip","visible","scroll"],Y=()=>["auto",N,r],E=()=>[N,r],C=()=>["",G,H],A=()=>["auto",Z,N],V=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],_=()=>["solid","dashed","dotted","double","none"],K=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],k=()=>["start","end","center","between","around","evenly","stretch"],D=()=>["","0",N],F=()=>["auto","avoid","all","avoid-page","page","left","right","column"],R=()=>[Z,N];return{cacheSize:500,separator:":",theme:{colors:[re],spacing:[G,H],blur:["none","",W,N],brightness:R(),borderColor:[e],borderRadius:["none","","full",W,N],borderSpacing:E(),borderWidth:C(),contrast:R(),grayscale:D(),hueRotate:R(),invert:D(),gap:E(),gradientColorStops:[e],gradientColorStopPositions:[ar,H],inset:Y(),margin:Y(),opacity:R(),padding:E(),saturate:R(),scale:R(),sepia:D(),skew:R(),space:E(),translate:E()},classGroups:{aspect:[{aspect:["auto","square","video",N]}],container:["container"],columns:[{columns:[W]}],"break-after":[{"break-after":F()}],"break-before":[{"break-before":F()}],"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:[...V(),N]}],overflow:[{overflow:B()}],"overflow-x":[{"overflow-x":B()}],"overflow-y":[{"overflow-y":B()}],overscroll:[{overscroll:$()}],"overscroll-x":[{"overscroll-x":$()}],"overscroll-y":[{"overscroll-y":$()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[y]}],"inset-x":[{"inset-x":[y]}],"inset-y":[{"inset-y":[y]}],start:[{start:[y]}],end:[{end:[y]}],top:[{top:[y]}],right:[{right:[y]}],bottom:[{bottom:[y]}],left:[{left:[y]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",ee,N]}],basis:[{basis:Y()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",N]}],grow:[{grow:D()}],shrink:[{shrink:D()}],order:[{order:["first","last","none",ee,N]}],"grid-cols":[{"grid-cols":[re]}],"col-start-end":[{col:["auto",{span:["full",ee,N]},N]}],"col-start":[{"col-start":A()}],"col-end":[{"col-end":A()}],"grid-rows":[{"grid-rows":[re]}],"row-start-end":[{row:["auto",{span:[ee,N]},N]}],"row-start":[{"row-start":A()}],"row-end":[{"row-end":A()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",N]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",N]}],gap:[{gap:[g]}],"gap-x":[{"gap-x":[g]}],"gap-y":[{"gap-y":[g]}],"justify-content":[{justify:["normal",...k()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...k(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...k(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[h]}],px:[{px:[h]}],py:[{py:[h]}],ps:[{ps:[h]}],pe:[{pe:[h]}],pt:[{pt:[h]}],pr:[{pr:[h]}],pb:[{pb:[h]}],pl:[{pl:[h]}],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":[f]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[f]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",N,r]}],"min-w":[{"min-w":[N,r,"min","max","fit"]}],"max-w":[{"max-w":[N,r,"none","full","min","max","fit","prose",{screen:[W]},W]}],h:[{h:[N,r,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[N,r,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[N,r,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[N,r,"auto","min","max","fit"]}],"font-size":[{text:["base",W,H]}],"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:[re]}],"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-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",N]}],"line-clamp":[{"line-clamp":["none",Z,ae]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",G,N]}],"list-image":[{"list-image":["none",N]}],"list-style-type":[{list:["none","disc","decimal",N]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[j]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[j]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[..._(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",G,H]}],"underline-offset":[{"underline-offset":["auto",G,N]}],"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:E()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",N]}],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",N]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[j]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...V(),cr]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",ir]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},ur]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[p]}],"gradient-via-pos":[{via:[p]}],"gradient-to-pos":[{to:[p]}],"gradient-from":[{from:[x]}],"gradient-via":[{via:[x]}],"gradient-to":[{to:[x]}],rounded:[{rounded:[l]}],"rounded-s":[{"rounded-s":[l]}],"rounded-e":[{"rounded-e":[l]}],"rounded-t":[{"rounded-t":[l]}],"rounded-r":[{"rounded-r":[l]}],"rounded-b":[{"rounded-b":[l]}],"rounded-l":[{"rounded-l":[l]}],"rounded-ss":[{"rounded-ss":[l]}],"rounded-se":[{"rounded-se":[l]}],"rounded-ee":[{"rounded-ee":[l]}],"rounded-es":[{"rounded-es":[l]}],"rounded-tl":[{"rounded-tl":[l]}],"rounded-tr":[{"rounded-tr":[l]}],"rounded-br":[{"rounded-br":[l]}],"rounded-bl":[{"rounded-bl":[l]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[j]}],"border-style":[{border:[..._(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[j]}],"divide-style":[{divide:_()}],"border-color":[{border:[n]}],"border-color-x":[{"border-x":[n]}],"border-color-y":[{"border-y":[n]}],"border-color-s":[{"border-s":[n]}],"border-color-e":[{"border-e":[n]}],"border-color-t":[{"border-t":[n]}],"border-color-r":[{"border-r":[n]}],"border-color-b":[{"border-b":[n]}],"border-color-l":[{"border-l":[n]}],"divide-color":[{divide:[n]}],"outline-style":[{outline:["",..._()]}],"outline-offset":[{"outline-offset":[G,N]}],"outline-w":[{outline:[G,H]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:C()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[j]}],"ring-offset-w":[{"ring-offset":[G,H]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",W,mr]}],"shadow-color":[{shadow:[re]}],opacity:[{opacity:[j]}],"mix-blend":[{"mix-blend":[...K(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":K()}],filter:[{filter:["","none"]}],blur:[{blur:[t]}],brightness:[{brightness:[o]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",W,N]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[b]}],invert:[{invert:[w]}],saturate:[{saturate:[S]}],sepia:[{sepia:[M]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[t]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[b]}],"backdrop-invert":[{"backdrop-invert":[w]}],"backdrop-opacity":[{"backdrop-opacity":[j]}],"backdrop-saturate":[{"backdrop-saturate":[S]}],"backdrop-sepia":[{"backdrop-sepia":[M]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",N]}],duration:[{duration:R()}],ease:[{ease:["linear","in","out","in-out",N]}],delay:[{delay:R()}],animate:[{animate:["none","spin","ping","pulse","bounce",N]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[L]}],"scale-x":[{"scale-x":[L]}],"scale-y":[{"scale-y":[L]}],rotate:[{rotate:[ee,N]}],"translate-x":[{"translate-x":[I]}],"translate-y":[{"translate-y":[I]}],"skew-x":[{"skew-x":[z]}],"skew-y":[{"skew-y":[z]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",N]}],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",N]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":E()}],"scroll-mx":[{"scroll-mx":E()}],"scroll-my":[{"scroll-my":E()}],"scroll-ms":[{"scroll-ms":E()}],"scroll-me":[{"scroll-me":E()}],"scroll-mt":[{"scroll-mt":E()}],"scroll-mr":[{"scroll-mr":E()}],"scroll-mb":[{"scroll-mb":E()}],"scroll-ml":[{"scroll-ml":E()}],"scroll-p":[{"scroll-p":E()}],"scroll-px":[{"scroll-px":E()}],"scroll-py":[{"scroll-py":E()}],"scroll-ps":[{"scroll-ps":E()}],"scroll-pe":[{"scroll-pe":E()}],"scroll-pt":[{"scroll-pt":E()}],"scroll-pr":[{"scroll-pr":E()}],"scroll-pb":[{"scroll-pb":E()}],"scroll-pl":[{"scroll-pl":E()}],"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",N]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[G,H,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-s","border-color-e","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"]}}},hr=Xe(fr);function c(...e){return hr(Fe(e))}function Ce(e){const r=parseInt(e.slice(1,3),16)/255,t=parseInt(e.slice(3,5),16)/255,o=parseInt(e.slice(5,7),16)/255,n=Math.max(r,t,o),l=Math.min(r,t,o);let i=0,a=0;const d=(n+l)/2;if(n!==l){const u=n-l;switch(a=d>.5?u/(2-n-l):u/(n+l),n){case r:i=((t-o)/u+(t<o?6:0))/6;break;case t:i=((o-r)/u+2)/6;break;case o:i=((r-t)/u+4)/6;break}}return[i*360,a*100,d*100]}function ce(e,r,t){t/=100;const o=r*Math.min(t,1-t)/100,n=l=>{const i=(l+e/30)%12,a=t-o*Math.max(Math.min(i-3,9-i,1),-1);return Math.round(255*a).toString(16).padStart(2,"0")};return`#${n(0)}${n(8)}${n(4)}`}function se(e){const[r,t,o]=Ce(e);return{base:e,light:ce(r,Math.max(0,t-10),Math.min(100,o+15)),dark:ce(r,Math.min(100,t+10),Math.max(0,o-15))}}const O={colors:{primary:"#6366f1",primaryLight:"#818cf8",primaryDark:"#4f46e5",secondary:"#8b5cf6",secondaryLight:"#a78bfa",secondaryDark:"#7c3aed",danger:"#ef4444",dangerLight:"#f87171",dangerDark:"#dc2626",text:"#1f2937",textMuted:"#6b7280",textLight:"#9ca3af",border:"#e5e7eb",borderDark:"#d1d5db",background:"#ffffff",backgroundDark:"#f9fafb",backgroundLight:"#f3f4f6",disabled:"#e5e7eb",light:"#f9fafb",active:"#4338ca"}},Se=v.createContext(O);function xr(){return v.useContext(Se)}function pe(e){const r=document.documentElement;r.style.setProperty("--componentables-primary",e.colors.primary),r.style.setProperty("--componentables-primary-light",e.colors.primaryLight),r.style.setProperty("--componentables-primary-dark",e.colors.primaryDark),r.style.setProperty("--componentables-secondary",e.colors.secondary),r.style.setProperty("--componentables-secondary-light",e.colors.secondaryLight),r.style.setProperty("--componentables-secondary-dark",e.colors.secondaryDark),r.style.setProperty("--componentables-danger",e.colors.danger),r.style.setProperty("--componentables-danger-light",e.colors.dangerLight),r.style.setProperty("--componentables-danger-dark",e.colors.dangerDark),r.style.setProperty("--componentables-text",e.colors.text),r.style.setProperty("--componentables-text-muted",e.colors.textMuted),r.style.setProperty("--componentables-text-light",e.colors.textLight),r.style.setProperty("--componentables-border",e.colors.border),r.style.setProperty("--componentables-border-dark",e.colors.borderDark),r.style.setProperty("--componentables-background",e.colors.background),r.style.setProperty("--componentables-background-dark",e.colors.backgroundDark),r.style.setProperty("--componentables-background-light",e.colors.backgroundLight),r.style.setProperty("--componentables-disabled",e.colors.disabled),r.style.setProperty("--componentables-light",e.colors.light),r.style.setProperty("--componentables-active",e.colors.active)}function yr({children:e,theme:r}){const t=v.useMemo(()=>{const o=r?.colors||{},n=o.primary?se(o.primary):null,l=o.secondary?se(o.secondary):null,i=o.danger?se(o.danger):null;return{colors:{primary:o.primary||O.colors.primary,primaryLight:n?.light||O.colors.primaryLight,primaryDark:n?.dark||O.colors.primaryDark,secondary:o.secondary||O.colors.secondary,secondaryLight:l?.light||O.colors.secondaryLight,secondaryDark:l?.dark||O.colors.secondaryDark,danger:o.danger||O.colors.danger,dangerLight:i?.light||O.colors.dangerLight,dangerDark:i?.dark||O.colors.dangerDark,text:o.text||O.colors.text,textMuted:o.textMuted||O.colors.textMuted,textLight:o.textLight||O.colors.textLight,border:o.border||O.colors.border,borderDark:o.borderDark||O.colors.borderDark,background:o.background||O.colors.background,backgroundDark:o.backgroundDark||O.colors.backgroundDark,backgroundLight:o.backgroundLight||O.colors.backgroundLight,disabled:o.disabled||O.colors.disabled,light:o.light||O.colors.light,active:o.active||O.colors.active}}},[r]);return typeof window<"u"&&pe(t),v.useEffect(()=>{pe(t)},[t]),v.createElement(Se.Provider,{value:t},e)}const wr={primary:"bg-primary text-white border-primary hover:bg-primary-dark hover:border-primary-dark active:bg-active",secondary:"bg-secondary text-white border-secondary hover:bg-secondary-dark hover:border-secondary-dark","primary-outline":"bg-transparent text-primary border-primary hover:bg-primary hover:text-white","secondary-outline":"bg-transparent text-secondary border-secondary hover:bg-secondary hover:text-white",ghost:"bg-transparent text-primary border-transparent hover:bg-primary hover:text-white hover:border-primary",light:"bg-light text-text border-border hover:bg-background-light",danger:"bg-transparent text-danger border-danger hover:text-white hover:bg-danger hover:border-danger active:bg-danger-dark",link:"bg-transparent text-secondary-light! underline hover:text-primary! border-0",dark:"bg-gray-800 text-white border-gray-800 hover:bg-gray-900 hover:border-gray-900"},vr={sm:"px-3 py-1.5 text-sm",md:"px-4 py-2 text-base",lg:"px-6 py-3 text-lg",xl:"px-8 py-4 text-xl"};function J({children:e,onClick:r,disabled:t=!1,type:o="button",variant:n="primary",size:l="md",fullWidth:i=!1,loading:a=!1,className:d="",...u}){return s.jsxs("button",{type:o,onClick:t||a?void 0:r,disabled:t||a,className:c("inline-flex shadow-md hover:shadow-lg cursor-pointer items-center justify-center font-medium rounded-lg border transition-all duration-300 focus:outline-none focus:ring-2 focus:ring-primary focus:ring-opacity-50",t||a?"bg-disabled text-text-muted border-disabled cursor-not-allowed hover:bg-disabled hover:border-disabled hover:text-text-muted":wr[n],vr[l],i&&"w-full",a&&"cursor-wait opacity-75",d),...u,children:[a&&s.jsxs("svg",{className:"w-4 h-4 mr-2 animate-spin",fill:"none",viewBox:"0 0 24 24",children:[s.jsx("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),s.jsx("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]}),e]})}function jr({id:e,name:r,type:t="text",value:o,onChange:n,placeholder:l,label:i,error:a,disabled:d=!1,required:u=!1,colorScheme:b="secondary",className:w="",...g}){const x=()=>{const y="w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed placeholder:text-text-muted";if(a)return c(y,"border-danger focus:border-danger focus:shadow-danger-light");switch(b){case"primary":return c(y,"text-primary border-primary focus:border-primary");case"secondary":default:return c(y,"text-secondary border-secondary focus:border-secondary")}},p=()=>b==="primary"?"text-primary":"text-secondary";return s.jsxs("div",{className:c("mb-6",w),children:[i&&s.jsxs("label",{htmlFor:e,className:c("block mb-2 text-sm font-medium",p()),children:[i,u&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsx("input",{id:e,name:r,type:t,value:o,onChange:n,placeholder:l,disabled:d,required:u,className:x(),...g}),a&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:a})]})}function kr({id:e,name:r,value:t,onChange:o,placeholder:n,label:l,error:i,disabled:a=!1,required:d=!1,colorScheme:u="secondary",className:b="",rows:w=4,...g}){const x=()=>{const y="w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed placeholder:text-text-muted resize-none";if(i)return c(y,"border-danger focus:border-danger focus:shadow-danger-light");switch(u){case"primary":return c(y,"text-primary border-primary focus:border-primary");case"secondary":default:return c(y,"text-secondary border-secondary focus:border-secondary")}},p=()=>u==="primary"?"text-primary":"text-secondary";return s.jsxs("div",{className:c("mb-6",b),children:[l&&s.jsxs("label",{htmlFor:e,className:c("block mb-2 text-sm font-medium",p()),children:[l,d&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsx("textarea",{id:e,name:r,value:t,onChange:o,placeholder:n,disabled:a,required:d,rows:w,className:x(),...g}),i&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:i})]})}const Me={Input:jr,InputArea:kr};function Nr({id:e,name:r,checked:t,onChange:o,disabled:n=!1,label:l,colorScheme:i="secondary",size:a="md",className:d="",...u}){const[b,w]=v.useState(!1),g=t!==void 0,x=g?t:b,p=()=>{if(n)return;const L=!x;g||w(L),o?.(L)},y=()=>({primary:{bg:"bg-primary",border:"border-primary",text:"text-primary"},secondary:{bg:"bg-secondary",border:"border-secondary",text:"text-secondary"}})[i],m=()=>{switch(a){case"sm":return"w-10 h-6";case"lg":return"w-16 h-8";case"md":default:return"w-13 h-7"}},j=()=>{switch(a){case"sm":return"w-5 h-5";case"lg":return"w-7 h-7";case"md":default:return"w-6 h-6"}},h=()=>{if(!x)return"translate-x-0";switch(a){case"sm":return"translate-x-4";case"lg":return"translate-x-8";case"md":default:return"translate-x-6"}},S=y();return s.jsxs("div",{className:c("flex items-center gap-3",n?"cursor-not-allowed":"cursor-pointer",d),onClick:p,children:[s.jsxs("div",{className:"relative",children:[s.jsx("input",{type:"checkbox",id:e,name:r,checked:x,onChange:p,onClick:L=>L.stopPropagation(),disabled:n,className:"sr-only","aria-label":l||r,...u}),s.jsx("div",{className:c("block transition-all duration-300 rounded-full border-2",m(),x?c(S.bg,S.border):"bg-gray-200 border-gray-300",n?"opacity-50":"hover:shadow-md"),children:s.jsx("span",{className:c("absolute top-0.5 left-0.5 inline-block rounded-full bg-white transition-all duration-300 shadow-sm",j(),h())})})]}),l&&s.jsx("span",{className:c("text-sm font-medium select-none",S.text,n&&"opacity-50"),children:l})]})}const Le=({size:e=40,wrapperStyle:r={},wrapperClass:t="",ariaLabel:o="Cargando...",label:n="Cargando...",visible:l=!0,direction:i="column"})=>{const a={display:"flex",flexDirection:i,justifyContent:"center",alignItems:"center",minHeight:"100px",...r};return s.jsxs("div",{style:a,className:t,children:[s.jsx("label",{children:n}),s.jsx(_e.Oval,{visible:l,height:e,width:e,ariaLabel:o,wrapperStyle:{},wrapperClass:"",secondaryColor:"#cdae90",color:"#cdae90"})]})},{Input:le}=Me,Cr=({title:e="Iniciar Sesión",showForgotPassword:r=!0,onlyForgotPassword:t=!1,className:o="",onLogin:n,onForgotPassword:l})=>{const[i,a]=v.useState({email:"",password:""}),[d,u]=v.useState({}),[b,w]=v.useState(!1),[g,x]=v.useState(t?"forgot":"login"),p=(z,f)=>{switch(z){case"email":return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(f)?"":"Por favor ingresa un email válido";case"password":return f.length>=6?"":"La contraseña debe tener al menos 6 caracteres";default:return""}},y=z=>{const{name:f,value:I}=z.target;a($=>({...$,[f]:I})),d[f]&&u($=>({...$,[f]:""}))},m=()=>{const z={},f=p("email",i.email);if(f&&(z.email=f),g==="login"){const I=p("password",i.password);I&&(z.password=I)}return u(z),Object.keys(z).length===0},j=async z=>{if(z.preventDefault(),!!m()){w(!0);try{switch(g){case"login":n&&await n({email:i.email,password:i.password});break;case"forgot":l&&await l(i.email);break}}catch(f){console.error("Login error:",f)}finally{w(!1)}}},h=z=>{x(z),u({}),a({email:i.email,password:""})},S=()=>{switch(g){case"forgot":return s.jsx(le,{id:"email",type:"email",name:"email",placeholder:"Ingresa tu email",label:"Email",value:i.email,onChange:y,error:d.email,disabled:b,colorScheme:"secondary"});default:return s.jsxs(s.Fragment,{children:[s.jsx(le,{id:"email",type:"email",name:"email",placeholder:"Ingresa tu email",label:"Email",value:i.email,onChange:y,error:d.email,disabled:b,colorScheme:"secondary"}),s.jsx(le,{id:"password",type:"password",name:"password",placeholder:"Ingresa tu contraseña",label:"Contraseña",value:i.password,onChange:y,error:d.password,disabled:b,colorScheme:"secondary"})]})}},L=()=>{switch(g){case"forgot":return t?"Cambiar Contraseña":"Recuperar Contraseña";default:return e}},M=()=>{if(b)return s.jsx(Le,{size:20,wrapperStyle:{minHeight:"auto"}});switch(g){case"forgot":return"Enviar Enlace";default:return"Entrar"}};return s.jsx("div",{className:`flex justify-center items-center min-h-[90vh] p-4 bg-background ${o||""}`,children:s.jsxs("div",{className:"w-full max-w-100 p-6 bg-white rounded-2xl shadow-lg animate-[fadeIn_0.3s_ease-out] sm:p-8",children:[s.jsx("h2",{className:"text-center mb-8 text-2xl font-semibold text-primary",children:L()}),s.jsxs("form",{onSubmit:j,children:[s.jsx("div",{className:"space-y-4 mb-6",children:S()}),s.jsx(J,{type:"submit",disabled:b,loading:b,fullWidth:!0,variant:"primary",size:"lg",className:"mb-6",children:!b&&M()})]}),g==="login"&&r&&s.jsx(J,{type:"button",onClick:()=>h("forgot"),variant:"link",size:"sm",fullWidth:!0,className:"shadow-none! !hover:shadow-none",children:"¿Olvidaste tu contraseña?"}),g==="forgot"&&!t&&s.jsx(J,{type:"button",onClick:()=>h("login"),variant:"link",size:"sm",fullWidth:!0,className:"shadow-none! !hover:shadow-none",children:"Volver al inicio de sesión"})]})})};var De={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},be=v.createContext&&v.createContext(De),Sr=["attr","size","title"];function Mr(e,r){if(e==null)return{};var t=Lr(e,r),o,n;if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(n=0;n<l.length;n++)o=l[n],!(r.indexOf(o)>=0)&&Object.prototype.propertyIsEnumerable.call(e,o)&&(t[o]=e[o])}return t}function Lr(e,r){if(e==null)return{};var t={};for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){if(r.indexOf(o)>=0)continue;t[o]=e[o]}return t}function oe(){return oe=Object.assign?Object.assign.bind():function(e){for(var r=1;r<arguments.length;r++){var t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},oe.apply(this,arguments)}function ge(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),t.push.apply(t,o)}return t}function ne(e){for(var r=1;r<arguments.length;r++){var t=arguments[r]!=null?arguments[r]:{};r%2?ge(Object(t),!0).forEach(function(o){Dr(e,o,t[o])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ge(Object(t)).forEach(function(o){Object.defineProperty(e,o,Object.getOwnPropertyDescriptor(t,o))})}return e}function Dr(e,r,t){return r=Er(r),r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function Er(e){var r=zr(e,"string");return typeof r=="symbol"?r:r+""}function zr(e,r){if(typeof e!="object"||!e)return e;var t=e[Symbol.toPrimitive];if(t!==void 0){var o=t.call(e,r);if(typeof o!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(e)}function Ee(e){return e&&e.map((r,t)=>v.createElement(r.tag,ne({key:t},r.attr),Ee(r.child)))}function U(e){return r=>v.createElement(Ar,oe({attr:ne({},e.attr)},r),Ee(e.child))}function Ar(e){var r=t=>{var{attr:o,size:n,title:l}=e,i=Mr(e,Sr),a=n||t.size||"1em",d;return t.className&&(d=t.className),e.className&&(d=(d?d+" ":"")+e.className),v.createElement("svg",oe({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},t.attr,o,i,{className:d,style:ne(ne({color:e.color||t.color},t.style),e.style),height:a,width:a,xmlns:"http://www.w3.org/2000/svg"}),l&&v.createElement("title",null,l),e.children)};return be!==void 0?v.createElement(be.Consumer,null,t=>r(t)):r(De)}function Pr(e){return U({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"circle",attr:{cx:"11",cy:"11",r:"8"},child:[]},{tag:"line",attr:{x1:"21",y1:"21",x2:"16.65",y2:"16.65"},child:[]}]})(e)}const ze=(e,r=500)=>{const[t,o]=v.useState(e);return v.useEffect(()=>{const n=setTimeout(()=>{o(e)},r);return()=>clearTimeout(n)},[e,r]),t},Tr=()=>({showToast:(r,t)=>{const o={position:"bottom-right",autoClose:2e3,hideProgressBar:!1,closeOnClick:!0,pauseOnHover:!0,draggable:!1,progress:void 0};switch(r){case"success":Q.toast.success(t,o);break;case"error":Q.toast.error(t,o);break;case"warning":Q.toast.warning(t,o);break;case"info":Q.toast.info(t,o);break;default:Q.toast(t,o);break}}});function Ir(e=768){const[r,t]=v.useState(()=>typeof window>"u"?!1:window.innerWidth<e);return v.useEffect(()=>{if(typeof window>"u")return;const o=()=>{t(window.innerWidth<e)};return window.addEventListener("resize",o),()=>{window.removeEventListener("resize",o)}},[e]),r}function Or({value:e,onChange:r,placeholder:t="Search...",disabled:o=!1,colorScheme:n="secondary",label:l,className:i="",debounceDelay:a=500,...d}){const[u,b]=v.useState(e||""),w=ze(u,a),g=v.useCallback(r,[r]);v.useEffect(()=>{g(w)},[w,g]);const x=()=>{const m="w-full px-4 py-2.5 pl-10 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed placeholder:text-text-muted";switch(n){case"primary":return c(m,"text-primary border-primary focus:border-primary");case"secondary":default:return c(m,"text-secondary border-secondary focus:border-secondary")}},p=()=>n==="primary"?"text-primary":"text-secondary",y=()=>n==="primary"?"text-primary":"text-secondary";return s.jsxs("div",{className:c("mb-0",i),children:[l&&s.jsx("label",{className:c("block mb-2 text-sm font-medium",y()),children:l}),s.jsxs("div",{className:"relative w-full",children:[s.jsx(Pr,{className:c("absolute left-3 top-1/2 -translate-y-1/2 text-base pointer-events-none",p())}),s.jsx("input",{type:"text",value:u,onChange:m=>b(m.target.value),placeholder:t,disabled:o,className:x(),...d})]})]})}function _r(e){return U({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M257.5 445.1l-22.2 22.2c-9.4 9.4-24.6 9.4-33.9 0L7 273c-9.4-9.4-9.4-24.6 0-33.9L201.4 44.7c9.4-9.4 24.6-9.4 33.9 0l22.2 22.2c9.5 9.5 9.3 25-.4 34.3L136.6 216H424c13.3 0 24 10.7 24 24v32c0 13.3-10.7 24-24 24H136.6l120.5 114.8c9.8 9.3 10 24.8.4 34.3z"},child:[]}]})(e)}function $r(e){return U({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M190.5 66.9l22.2-22.2c9.4-9.4 24.6-9.4 33.9 0L441 239c9.4 9.4 9.4 24.6 0 33.9L246.6 467.3c-9.4 9.4-24.6 9.4-33.9 0l-22.2-22.2c-9.5-9.5-9.3-25 .4-34.3L311.4 296H24c-13.3 0-24-10.7-24-24v-32c0-13.3 10.7-24 24-24h287.4L190.9 101.2c-9.8-9.3-10-24.8-.4-34.3z"},child:[]}]})(e)}function Fr({labelPage:e="Page",labelOf:r="of",setPagination:t,totalPages:o,currentPage:n,showLabel:l=!0,className:i="",isLoading:a=!1,fetchPage:d}){const u=parseInt(String(n))===1||parseInt(String(o))===0||a,b=parseInt(String(n))===parseInt(String(o))||parseInt(String(o))===0||a,w=()=>{a||(d?d(n-1):t&&t(x=>({...x,page:x.page-1})))},g=()=>{a||(d?d(n+1):t&&t(x=>({...x,page:x.page+1})))};return s.jsxs("div",{className:c("flex justify-center items-center mt-8",i),children:[s.jsx(J,{disabled:u,onClick:w,variant:"secondary",children:s.jsx(_r,{size:14})}),s.jsx("h5",{className:"font-bold mx-2.5 text-text",children:`${l?e:""} ${n}${l?` ${r} `:" / "}${o}`}),s.jsx(J,{disabled:b,onClick:g,variant:"primary",children:s.jsx($r,{size:14})})]})}function Ae(e){return U({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"m112 184 144 144 144-144"},child:[]}]})(e)}function Rr(e){return U({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"m289.94 256 95-95A24 24 0 0 0 351 127l-95 95-95-95a24 24 0 0 0-34 34l95 95-95 95a24 24 0 1 0 34 34l95-95 95 95a24 24 0 0 0 34-34z"},child:[]}]})(e)}function Vr(e){return U({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M456.69 421.39 362.6 327.3a173.81 173.81 0 0 0 34.84-104.58C397.44 126.38 319.06 48 222.72 48S48 126.38 48 222.72s78.38 174.72 174.72 174.72A173.81 173.81 0 0 0 327.3 362.6l94.09 94.09a25 25 0 0 0 35.3-35.3zM97.92 222.72a124.8 124.8 0 1 1 124.8 124.8 124.95 124.95 0 0 1-124.8-124.8z"},child:[]}]})(e)}function Br({title:e,subtitle:r,children:t,defaultExpanded:o=!1,expanded:n,onToggle:l,className:i="",colorScheme:a="primary",icon:d,disabled:u=!1,headerExtra:b}){const[w,g]=v.useState(o),x=n!==void 0?n:w,p=()=>{if(u)return;const h=!x;n===void 0&&g(h),l?.(h)},y=()=>a==="primary"?"border-primary":"border-secondary",m=()=>a==="primary"?"text-primary":"text-secondary",j=()=>a==="primary"?"hover:bg-primary/5":"hover:bg-secondary/5";return s.jsxs("div",{className:c("w-full rounded-lg border-2 bg-background transition-all duration-300",y(),x&&"shadow-lg",i),children:[s.jsxs("button",{type:"button",onClick:p,disabled:u,className:c("w-full flex cursor-pointer items-center justify-between p-4 text-left transition-all duration-300 rounded-lg",!u&&j(),u&&"opacity-50"),"aria-expanded":x,children:[s.jsxs("div",{className:"flex items-center gap-3 flex-1 min-w-0",children:[d&&s.jsx("div",{className:c("shrink-0",m()),children:d}),s.jsxs("div",{className:"flex-1 min-w-0",children:[s.jsx("h3",{className:c("text-base font-medium truncate",m()),children:e}),r&&s.jsx("p",{className:"text-sm text-text-muted truncate mt-0.5",children:r})]})]}),s.jsxs("div",{className:"flex items-center gap-3 shrink-0",children:[b&&s.jsx("div",{onClick:h=>h.stopPropagation(),children:b}),s.jsx("div",{className:c("h-5 w-5 transition-transform duration-300",m(),x&&"rotate-180"),children:s.jsx(Ae,{className:"h-5 w-5"})})]})]}),s.jsx("div",{className:c("overflow-hidden transition-all duration-300 ease-in-out",x?"max-h-500 opacity-100":"max-h-0 opacity-0"),children:s.jsx("div",{className:c("p-4 pt-0 border-t-0",y()),children:s.jsx("div",{className:"border-t border-border pt-4",children:t})})})]})}function Gr({children:e,className:r=""}){return s.jsx("div",{className:c("py-4",r),children:e})}function Hr({options:e,value:r,onChange:t,children:o,className:n="",colorScheme:l="primary",variant:i="underline"}){const[a,d]=v.useState(r??e[0]?.value??""),u=r!==void 0?r:a,b=p=>{r===void 0&&d(p),t?.(p)},w=(p,y)=>{const m=u===p,j="px-4 py-3 cursor-pointer text-sm font-medium transition-all duration-300 focus:outline-none disabled:opacity-50 disabled:cursor-not-allowed";if(y)return c(j,"text-text-muted");switch(i){case"filled":return c(j,"rounded-lg",m?l==="primary"?"bg-primary text-white":"bg-secondary text-white":"text-text-muted hover:bg-background-light");case"pills":return c(j,"rounded-full",m?l==="primary"?"bg-primary/10 text-primary border-2 border-primary":"bg-secondary/10 text-secondary border-2 border-secondary":"text-text-muted hover:bg-background-light border-2 border-transparent");case"underline":default:return c(j,"border-b-2 flex items-center gap-2",m?l==="primary"?"border-primary text-primary":"border-secondary text-secondary":"border-transparent text-gray-500 hover:text-gray-700")}},g=()=>{switch(i){case"filled":return"flex gap-1 p-1 bg-background-light rounded-lg";case"pills":return"flex gap-2 flex-wrap";case"underline":default:return"flex gap-2 border-b border-gray-200"}},x=v.Children.toArray(o).find(p=>v.isValidElement(p)?p.props.value===u:!1);return s.jsxs("div",{className:c("w-full",n),children:[s.jsx("div",{className:g(),role:"tablist",children:e.map(p=>s.jsxs("button",{type:"button",role:"tab","aria-selected":u===p.value,"aria-controls":`tabpanel-${p.value}`,disabled:p.disabled,onClick:()=>!p.disabled&&b(p.value),className:w(p.value,p.disabled),children:[p.icon&&s.jsx("span",{className:"shrink-0",children:p.icon}),p.label]},p.value))}),s.jsx("div",{role:"tabpanel",id:`tabpanel-${u}`,children:x})]})}function fe(e){return U({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M15.41 7.41 14 6l-6 6 6 6 1.41-1.41L10.83 12z"},child:[]}]})(e)}function he(e){return U({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"},child:[]}]})(e)}const Pe=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Te=["Lun","Mar","Mié","Jue","Vie","Sáb","Dom"],Ie=["January","February","March","April","May","June","July","August","September","October","November","December"],Oe=["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"];function Wr(e){return new Date(e.getFullYear(),e.getMonth()+1,0).getDate()}function Ur(e){const r=new Date(e.getFullYear(),e.getMonth(),1).getDay();return r===0?6:r-1}function Yr({value:e,onChange:r,disabled:t=!1,className:o="",colorScheme:n="secondary",lang:l="en",...i}){const[a,d]=v.useState(e||new Date),u={en:"en-US",es:"es-ES"},b={en:Pe,es:Te},w={en:Ie,es:Oe},g=Wr(a),x=Ur(a),p=[];for(let f=0;f<x;f++)p.push(null);for(let f=1;f<=g;f++){const I=new Date(a.getFullYear(),a.getMonth(),f,12,0,0);p.push(I)}const y=()=>{d(new Date(a.getFullYear(),a.getMonth()-1,1,12,0,0))},m=()=>{d(new Date(a.getFullYear(),a.getMonth()+1,1,12,0,0))},j=()=>{d(new Date(a.getFullYear()-1,a.getMonth(),1,12,0,0))},h=()=>{d(new Date(a.getFullYear()+1,a.getMonth(),1,12,0,0))},S=f=>{if(f&&!t){const I=new Date(f.getFullYear(),f.getMonth(),f.getDate(),12,0,0);d(I),r?.(I)}},M=(()=>{switch(n){case"primary":return{header:"text-primary",selected:"bg-primary text-white",hover:"hover:bg-primary/10",button:"text-primary border-primary hover:bg-primary/20"};case"secondary":default:return{header:"text-secondary",selected:"bg-secondary text-white",hover:"hover:bg-secondary/10",button:"text-secondary border-secondary hover:bg-secondary/20"}}})(),z=f=>f&&e?f.toDateString()===e.toDateString():!1;return s.jsxs("div",{className:c("w-full max-w-sm bg-background border-2 border-border rounded-lg p-6 shadow-md",o),...i,children:[s.jsxs("div",{className:"mb-6",children:[s.jsxs("div",{className:c("flex items-center justify-between mb-4",M.header),children:[s.jsx("button",{type:"button",onClick:j,disabled:t,className:c("p-2 rounded-lg border transition-all duration-300",M.button,t&&"opacity-50 cursor-not-allowed"),children:s.jsx(fe,{size:18})}),s.jsx("h2",{className:"font-semibold text-lg",children:a.getFullYear()}),s.jsx("button",{type:"button",onClick:h,disabled:t,className:c("p-2 rounded-lg border transition-all duration-300",M.button,t&&"opacity-50 cursor-not-allowed"),children:s.jsx(he,{size:18})})]}),s.jsxs("div",{className:c("flex items-center justify-between",M.header),children:[s.jsx("button",{type:"button",onClick:y,disabled:t,className:c("p-2 rounded-lg border transition-all duration-300",M.button,t&&"opacity-50 cursor-not-allowed"),children:s.jsx(fe,{size:18})}),s.jsx("h2",{className:"font-semibold text-lg",children:w[l][a.getMonth()]}),s.jsx("button",{type:"button",onClick:m,disabled:t,className:c("p-2 rounded-lg border transition-all duration-300",M.button,t&&"opacity-50 cursor-not-allowed"),children:s.jsx(he,{size:18})})]})]}),s.jsx("div",{className:"grid grid-cols-7 gap-2 mb-4",children:b[l].map(f=>s.jsx("div",{className:c("text-center text-sm font-medium py-2",M.header),children:f},f))}),s.jsx("div",{className:"grid grid-cols-7 gap-2",children:p.map((f,I)=>s.jsx("button",{type:"button",onClick:()=>S(f),disabled:!f||t,className:c("p-2 rounded-lg text-sm font-medium transition-all duration-300",f?c("cursor-pointer",M.hover,z(f)?M.selected:"text-text border border-transparent hover:border-border",t&&"opacity-50 cursor-not-allowed"):"cursor-default"),children:f?f.getDate():""},I))}),e&&s.jsx("div",{className:c("mt-6 p-3 rounded-lg bg-background-dark border border-border text-center text-sm font-medium",M.header),children:e.toLocaleDateString(u[l],{year:"numeric",month:"long",day:"numeric"})})]})}function Jr({headers:e,data:r,loading:t,loadingText:o="Loading...",actions:n,actionsHeader:l="Actions",onRowClick:i,className:a="",rowClassName:d="",cellClassName:u="",headerClassName:b="",emptyText:w="No data available",showCount:g=!0,countText:x=y=>`Showing ${y} record${y!==1?"s":""}`,keyExtractor:p=(y,m)=>y._id||y.id||m}){if(t)return s.jsx("div",{className:"flex justify-center items-center min-h-50",children:s.jsx("div",{className:"text-lg text-text-light",children:o})});if(r.length===0)return s.jsx("div",{className:"flex justify-center items-center min-h-50",children:s.jsx("div",{className:"text-lg text-text-muted",children:w})});const y=(m,j)=>{const h=j.toLowerCase().replace(/\s+/g,"_");let S=m[h];if(S===void 0){const L=[h.replace(/_/g,""),j.toLowerCase().replace(/\s+/g,""),h.replace(/_([a-z])/g,(M,z)=>z.toUpperCase())];for(const M of L)if(m[M]!==void 0){S=m[M];break}}if(S===void 0){const L=j.toLowerCase().split(" "),M=Object.keys(m).find(z=>L.some(f=>z.toLowerCase().includes(f)));M&&(S=m[M])}return v.isValidElement(S)?S:S!=null?String(S):"N/A"};return s.jsxs("div",{className:c("overflow-x-auto",a),children:[s.jsxs("table",{className:"w-full border-collapse",children:[s.jsx("thead",{children:s.jsxs("tr",{className:"border-b-2 border-border",children:[e.map((m,j)=>s.jsx("th",{className:c("text-left py-3 px-4 font-semibold text-text",b),children:m},j)),n&&s.jsx("th",{className:c("text-center py-3 px-4 font-semibold text-text",b),children:l})]})}),s.jsx("tbody",{children:r.map((m,j)=>s.jsxs("tr",{className:c("border-b border-border-dark hover:bg-background-light transition-colors",i&&"cursor-pointer",d),onClick:()=>i?.(m),children:[e.map((h,S)=>s.jsx("td",{className:c("py-4 px-4",u),children:s.jsx("div",{className:"text-text-light",children:y(m,h)})},S)),n&&s.jsx("td",{className:c("py-4 px-4",u),children:s.jsx("div",{className:"flex gap-2 justify-center",children:n.map((h,S)=>{const L=M=>{M?.stopPropagation(),h.onClick?.(m)};if(h.component){const M=h.component;return s.jsxs(M,{onClick:L,className:h.className||"",...h.props||{},children:[h.icon&&s.jsx("span",{className:"inline-block",children:v.createElement(h.icon)}),h.label&&h.label]},S)}return s.jsxs(J,{onClick:L,className:h.className||"",...h.props||{},children:[h.icon&&s.jsx("span",{className:"inline-block",children:v.createElement(h.icon)}),h.label&&h.label]},S)})})})]},p(m,j)))})]}),g&&r.length>0&&s.jsx("div",{className:"mt-6 text-center text-text-light text-sm",children:x(r.length)})]})}function Kr({label:e,options:r,value:t="",onChange:o,multiple:n=!1,className:l="",searchable:i=!1,onSearchInputCustom:a,placeholder:d="Select...",disabled:u=!1,error:b,required:w=!1,colorScheme:g="primary",noResultsText:x="No results found",searchPlaceholder:p="Search...",...y}){const[m,j]=v.useState(!1),[h,S]=v.useState(""),[L,M]=v.useState({top:0,left:0,openUpward:!1}),z=Array.isArray(t)?t:t?[t]:[],[f,I]=v.useState(z.map(k=>r.find(D=>D.value===k)).filter(Boolean)),$=v.useRef(null),B=v.useRef(null),Y=()=>{const k="w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed";if(b)return c(k,"border-danger focus:border-danger");switch(g){case"primary":return c(k,"text-primary border-primary focus:border-primary");case"secondary":default:return c(k,"text-secondary border-secondary focus:border-secondary")}},E=()=>g==="primary"?"text-primary":"text-secondary";v.useEffect(()=>{const D=(Array.isArray(t)?t:t!==""&&t!==null&&t!==void 0?[t]:[]).map(F=>r.find(R=>R.value===F)).filter(Boolean);I(D)},[t,r]),v.useEffect(()=>{m&&i&&B.current&&B.current.focus()},[m,i]);const C=v.useCallback(()=>{if(!$.current)return;const k=$.current.getBoundingClientRect(),D=window.innerHeight,F=250,q=D-k.bottom<F&&k.top>F;M({top:q?k.top:k.bottom,left:k.left,width:k.width,openUpward:q})},[]);v.useEffect(()=>{function k(F){$.current&&!$.current.contains(F.target)&&j(!1)}function D(){m&&C()}return document.addEventListener("mousedown",k),window.addEventListener("scroll",D,!0),window.addEventListener("resize",D),()=>{document.removeEventListener("mousedown",k),window.removeEventListener("scroll",D,!0),window.removeEventListener("resize",D)}},[m,C]);const A=k=>{const D=r.find(R=>R.value===k);if(!D)return;let F;n?(F=f.some(q=>q.value===k)?f.filter(q=>q.value!==k):[...f,D],I(F),o(F)):(F=[D],I(F),o(D),j(!1),S(""))},V=k=>{S(k),a?.(k)},_=i?r.filter(k=>k.label.toLowerCase().includes(h.toLowerCase())):r,K=()=>f.length===0?d:n?f.length===1?f[0].label:`${f.length} selected`:f[0]?.label||d;return s.jsxs("div",{className:c("mb-6",l),children:[e&&s.jsxs("label",{className:c("block mb-2 text-sm font-medium",E()),children:[e,w&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsxs("div",{ref:$,className:"relative w-full",children:[s.jsxs("button",{type:"button",onClick:k=>{k.preventDefault(),k.stopPropagation(),m||C(),j(!m)},className:c(Y(),"inline-flex items-center justify-between cursor-pointer h-auto min-h-14",u&&"cursor-not-allowed",m&&"ring-1"),disabled:u,...y,children:[s.jsxs("div",{className:"flex items-center gap-2 flex-1",children:[f.length>0&&f[0].hex&&s.jsx("div",{className:"h-4 w-4 rounded border border-border",style:{backgroundColor:f[0].hex}}),s.jsx("span",{className:f.length>0?"":"text-text-muted",children:K()})]}),s.jsx("div",{className:c("h-5 w-5 transition-transform duration-200",m&&"rotate-180"),children:s.jsx(Ae,{className:"h-5 w-5"})})]}),m&&s.jsxs("div",{className:c("fixed z-9999 rounded-lg border-2 bg-white shadow-xl",b?"border-danger":g==="primary"?"border-primary":"border-secondary"),style:{top:`${L.top+(L.openUpward?0:8)}px`,left:`${L.left}px`,width:`${L.width}px`,transform:L.openUpward?"translateY(-100%)":"none"},children:[i&&s.jsx("div",{className:"border-b border-border p-3",children:s.jsxs("div",{className:"relative",children:[s.jsx(Vr,{className:"absolute top-1/2 left-3 h-4 w-4 -translate-y-1/2 transform text-text-muted"}),s.jsx("input",{ref:B,type:"text",value:h,onChange:k=>V(k.target.value),placeholder:p,className:c("w-full rounded-lg border-2 py-2 pr-10 pl-10 text-sm transition-all duration-300 focus:outline-none focus:ring-1",g==="primary"?"border-primary text-primary":"border-secondary text-secondary")}),h&&s.jsx("button",{type:"button",onClick:()=>S(""),className:"absolute top-1/2 right-3 h-4 w-4 -translate-y-1/2 transform text-text-muted hover:text-text",children:s.jsx(Rr,{className:"h-4 w-4"})})]})}),s.jsxs("div",{className:"max-h-60 overflow-y-auto py-1",children:[_.map(k=>s.jsx("button",{type:"button",onClick:()=>A(k.value??""),className:c("w-full px-4 py-3 text-left text-sm transition-colors",f.some(D=>D.value===k.value)?g==="primary"?"bg-primary/10 text-primary font-medium":"bg-secondary/10 text-secondary font-medium":"text-text hover:bg-background-light"),children:s.jsxs("div",{className:"flex items-center gap-3",children:[n&&s.jsx("div",{className:c("flex h-4 w-4 items-center justify-center rounded border-2 transition-colors",f.some(D=>D.value===k.value)?g==="primary"?"border-primary bg-primary":"border-secondary bg-secondary":"border-border"),children:f.some(D=>D.value===k.value)&&s.jsx("svg",{className:"h-3 w-3 text-white",fill:"currentColor",viewBox:"0 0 20 20",children:s.jsx("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})})}),k.hex&&s.jsx("div",{className:"h-4 w-4 rounded border border-border",style:{backgroundColor:k.hex}}),s.jsx("span",{children:k.label})]})},k.value)),_.length===0&&h&&r.length>0&&s.jsx("div",{className:"px-4 py-3",children:s.jsx("span",{className:"text-sm text-text-muted",children:x})})]})]})]}),b&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:b})]})}const qr=({id:e,name:r,onFilesSelected:t,placeholder:o="Arrastra y suelta archivos aquí o haz clic para seleccionar",labelSelectedFiles:n="archivo:",label:l,error:i,disabled:a=!1,required:d=!1,colorScheme:u="secondary",className:b="",accept:w="*/*",multiple:g=!1,...x})=>{const p=v.useRef(null),[y,m]=v.useState(!1),[j,h]=v.useState([]),S=()=>{const C="w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed cursor-pointer min-h-[120px]";if(i)return c(C,"border-danger focus:border-danger focus:ring-1 focus:ring-danger");switch(u){case"primary":return c(C,"border-primary focus:border-primary focus:ring-1 focus:ring-primary hover:border-primary-dark");case"secondary":default:return c(C,"border-secondary focus:border-secondary focus:ring-1 focus:ring-secondary hover:border-secondary-dark")}},L=()=>{switch(u){case"primary":return"text-primary";case"secondary":default:return"text-secondary"}},M=C=>{C.preventDefault(),C.stopPropagation(),a||(C.type==="dragenter"||C.type==="dragover"?m(!0):C.type==="dragleave"&&m(!1))},z=C=>{if(C.preventDefault(),C.stopPropagation(),m(!1),a)return;const A=C.dataTransfer.files;I(A)},f=C=>{const A=C.target.files;A&&I(A)},I=C=>{const A=Array.from(C);if(w!=="*/*"){const V=A.filter(_=>$(_,w));if(V.length===0){console.warn("No valid files selected");return}h(g?V:[V[0]]),t(g?V:[V[0]])}else h(g?A:[A[0]]),t(g?A:[A[0]])},$=(C,A)=>A.split(",").map(_=>_.trim()).some(_=>{if(_.startsWith("."))return C.name.toLowerCase().endsWith(_.toLowerCase());if(_.includes("/")){const[K,k]=_.split("/"),D=C.type.split("/")[0];return k==="*"?D===K:C.type===_}return!1}),B=()=>{a||p.current?.click()},Y=C=>{const A=j.filter((V,_)=>_!==C);h(A),t(A)},E=C=>{(C.key==="Enter"||C.key===" ")&&(C.preventDefault(),B())};return s.jsxs("div",{className:`mb-6 ${b}`,children:[l&&s.jsxs("label",{className:`block mb-2 text-sm font-medium ${L()}`,children:[l,d&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsxs("div",{className:c(S(),y&&"bg-background-light border-2-dashed"),onDragEnter:M,onDragLeave:M,onDragOver:M,onDrop:z,onClick:B,onKeyDown:E,role:"button",tabIndex:a?-1:0,children:[s.jsx("input",{ref:p,id:e,name:r,type:"file",onChange:f,disabled:a,required:d,accept:w,multiple:g,className:"hidden",...x}),s.jsxs("div",{className:"flex flex-col items-center justify-center py-4",children:[s.jsx("svg",{className:`w-8 h-8 mb-2 ${u==="primary"?"text-primary":"text-secondary"}`,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 4v16m8-8H4"})}),s.jsx("p",{className:`text-sm ${L()}`,children:o})]})]}),s.jsxs("div",{className:"mt-4 space-y-2",children:[s.jsxs("p",{className:`text-sm font-medium ${L()}`,children:[j.length," ",n,"(s) seleccionado(s):"]}),s.jsx("ul",{className:"space-y-1",children:j.map((C,A)=>s.jsxs("li",{className:"flex items-center justify-between p-2 bg-light rounded border border-border",children:[s.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[s.jsxs("svg",{className:"w-4 h-4 text-text-muted shrink-0",fill:"currentColor",viewBox:"0 0 20 20",children:[s.jsx("path",{d:"M8 16.5a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0zM15 16.5a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0z"}),s.jsx("path",{d:"M3 4a1 1 0 00-1 1v10a1 1 0 001 1h1.05a2.5 2.5 0 014.9 0H10a1 1 0 001-1V5a1 1 0 00-1-1H3zM14 7a1 1 0 00-1 1v6.05A2.5 2.5 0 0115.95 10H17a1 1 0 001-1v-3a1 1 0 00-1-1h-3z"})]}),s.jsx("span",{className:"text-sm text-text truncate",children:C.name})]}),s.jsx("button",{onClick:V=>{V.stopPropagation(),Y(A)},className:"ml-2 text-danger hover:text-danger-dark shrink-0",type:"button",children:"✕"})]},A))})]}),i&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:i})]})},Zr=({text:e,className:r="",variant:t="default",visible:o=!0,...n})=>{if(!o)return null;const l={default:"bg-gray-200 text-gray-800",primary:"bg-primary text-white",secondary:"bg-secondary text-white",secondaryDark:"bg-secondary-dark text-white",danger:"bg-danger text-white",warning:"bg-warning text-white"},i="inline-flex items-center px-3 py-1 rounded-full text-xs font-bold uppercase shadow-md",a=l[t]||l.default;return s.jsx("div",{className:`${i} ${a} ${r}`,...n,children:e})};function Xr({isOpen:e,onClose:r,title:t,children:o,size:n="md",className:l="",overlayClassName:i="",showCloseButton:a=!0,closeOnOverlayClick:d=!0,closeOnEscape:u=!0}){if(v.useEffect(()=>(e?document.body.style.overflow="hidden":document.body.style.overflow="unset",()=>{document.body.style.overflow="unset"}),[e]),v.useEffect(()=>{if(!u||!e)return;const x=p=>{p.key==="Escape"&&r()};return document.addEventListener("keydown",x),()=>{document.removeEventListener("keydown",x)}},[e,r,u]),!e)return null;const b={sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",xl:"max-w-xl","2xl":"max-w-2xl"},w=()=>{d&&r()},g=s.jsx("div",{className:c("fixed inset-0 bg-black/40 flex items-center justify-center z-9999 p-4",i),onClick:w,role:"dialog","aria-modal":"true","aria-labelledby":t?"modal-title":void 0,children:s.jsxs("div",{className:c("relative bg-white rounded-xl shadow-2xl max-h-[90vh] flex flex-col w-full transition-all duration-300",b[n],l),onClick:x=>x.stopPropagation(),children:[(t||a)&&s.jsxs("div",{className:"flex justify-between items-center px-6 py-5 border-b border-border rounded-t-xl shrink-0",children:[t&&s.jsx("h2",{id:"modal-title",className:"text-xl sm:text-2xl font-bold text-primary m-0",children:t}),a&&s.jsx("button",{className:"flex items-center justify-center w-8 h-8 text-text-muted hover:text-text hover:bg-background-light transition-colors duration-200 rounded-lg",onClick:r,"aria-label":"Cerrar modal",type:"button",children:s.jsx("span",{className:"text-2xl font-light leading-none",children:"×"})})]}),s.jsx("div",{className:"p-6 overflow-y-auto flex-1",children:o})]})});return $e.createPortal(g,document.body)}function Qr({id:e,name:r,checked:t=!1,onChange:o,disabled:n=!1,required:l=!1,colorScheme:i="secondary",variant:a="solid",label:d,className:u="",...b}){const w=(g,x)=>{const p="checkbox-input size-4 shrink-0 rounded transition-all duration-300 cursor-pointer focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-opacity-50 disabled:cursor-not-allowed disabled:opacity-50";if(g==="outline")switch(x){case"primary":return`${p} checkbox-outline checkbox-primary`;case"secondary":default:return`${p} checkbox-outline checkbox-secondary`}else switch(x){case"primary":return`${p} checkbox-solid checkbox-primary`;case"secondary":default:return`${p} checkbox-solid checkbox-secondary`}};return d?s.jsxs("div",{className:`flex items-center gap-2 ${u}`,children:[s.jsx("input",{id:e,name:r,type:"checkbox",checked:t,onChange:o,disabled:n,required:l,className:w(a,i),...b}),s.jsxs("label",{htmlFor:e,className:"text-sm text-text cursor-pointer font-medium",children:[d,l&&s.jsx("span",{className:"text-red-500 ml-1",children:"*"})]})]}):s.jsx("input",{id:e,name:r,type:"checkbox",checked:t,onChange:o,disabled:n,required:l,className:`${w(a,i)} ${u}`,style:{accentColor:"white"},...b})}const te=e=>String(e).padStart(2,"0"),xe=e=>!e||Number.isNaN(e.getTime())?"":`${e.getFullYear()}-${te(e.getMonth()+1)}-${te(e.getDate())}T${te(e.getHours())}:${te(e.getMinutes())}`,et=e=>{if(!e)return null;const r=new Date(e);return Number.isNaN(r.getTime())?null:r};function rt({id:e,name:r,value:t,onChange:o,min:n,label:l,error:i,disabled:a=!1,required:d=!1,colorScheme:u="secondary",className:b="",...w}){const g=c("w-full p-4 border-2 rounded-lg text-base bg-white transition-all duration-300 focus:outline-none focus:ring-1 disabled:bg-light disabled:text-text-muted disabled:cursor-not-allowed",i?"border-danger focus:border-danger focus:shadow-danger-light":u==="primary"?"text-primary border-primary focus:border-primary":"text-secondary border-secondary focus:border-secondary");return s.jsxs("div",{className:c("mb-6",b),children:[l&&s.jsxs("label",{htmlFor:e,className:c("block mb-2 text-sm font-medium",u==="primary"?"text-primary":"text-secondary"),children:[l,d&&s.jsx("span",{className:"text-danger ml-1",children:"*"})]}),s.jsx("input",{id:e,name:r,type:"datetime-local",value:xe(t),onChange:x=>o(et(x.target.value)),min:n?xe(n):void 0,disabled:a,required:d,"aria-invalid":i?!0:void 0,className:g,...w}),i&&s.jsx("span",{className:"block mt-1 text-xs text-danger font-medium",children:i})]})}const tt={pulse:"cmp-skeleton-pulse",wave:"cmp-skeleton-wave",none:""},T=({className:e="",animation:r="pulse"})=>{const t=/(^|\s)rounded/.test(e);return s.jsx("div",{className:c("bg-gray-200",tt[r],!t&&"rounded-md",e)})},st=({count:e=6,className:r="",animation:t="pulse"})=>s.jsx("div",{className:c("divide-y divide-gray-200",r),children:Array.from({length:e}).map((o,n)=>s.jsxs("div",{className:"flex items-center justify-between py-3",children:[s.jsxs("div",{className:"flex flex-col gap-1.5 min-w-0",children:[s.jsx(T,{className:"h-4 w-40",animation:t}),s.jsx(T,{className:"h-3 w-28",animation:t})]}),s.jsx(T,{className:"h-4 w-12 shrink-0 ml-3",animation:t})]},n))}),ot=({animation:e})=>s.jsxs("div",{className:"bg-white border border-gray-200 rounded-xl shadow-sm flex items-stretch overflow-hidden",children:[s.jsx(T,{className:"shrink-0 w-36 h-[120px] rounded-none",animation:e}),s.jsxs("div",{className:"flex-1 p-4 min-w-0 flex flex-col justify-center gap-2",children:[s.jsx(T,{className:"h-5 w-1/3",animation:e}),s.jsxs("div",{className:"flex items-center gap-1.5",children:[s.jsx(T,{className:"h-4 w-16 rounded-full",animation:e}),s.jsx(T,{className:"h-4 w-20 rounded-full",animation:e}),s.jsx(T,{className:"h-4 w-24 rounded-full",animation:e})]}),s.jsx(T,{className:"h-3 w-2/3",animation:e})]}),s.jsxs("div",{className:"shrink-0 flex items-center gap-2 px-4 border-l border-gray-100",children:[s.jsx(T,{className:"h-8 w-8",animation:e}),s.jsx(T,{className:"h-8 w-8",animation:e}),s.jsx(T,{className:"h-8 w-8",animation:e})]})]}),nt=({count:e=6,className:r="",animation:t="pulse"})=>s.jsx("div",{className:c("flex flex-col gap-3",r),children:Array.from({length:e}).map((o,n)=>s.jsx(ot,{animation:t},n))}),at={2:"grid-cols-1 sm:grid-cols-2",3:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-3",4:"grid-cols-1 sm:grid-cols-2 lg:grid-cols-4"},lt={video:"aspect-video",square:"aspect-square","4/3":"aspect-4/3",auto:""},it=({aspect:e,animation:r})=>s.jsxs("div",{className:"bg-white border border-gray-200 rounded-xl shadow-sm overflow-hidden flex flex-col",children:[s.jsx(T,{className:c("w-full rounded-none",lt[e]||"h-40"),animation:r}),s.jsxs("div",{className:"p-4 flex-1 flex flex-col",children:[s.jsx(T,{className:"h-5 w-4/5 mb-2",animation:r}),s.jsx(T,{className:"h-3 w-full mb-1.5",animation:r}),s.jsx(T,{className:"h-3 w-2/3 mb-3",animation:r}),s.jsxs("div",{className:"mt-auto flex items-center justify-between",children:[s.jsx(T,{className:"h-3 w-16",animation:r}),s.jsx(T,{className:"h-8 w-24 rounded-lg",animation:r})]})]})]}),ct=({count:e=6,columns:r=3,aspect:t="4/3",className:o="",animation:n="pulse"})=>s.jsx("div",{className:c("grid gap-6",at[r],o),children:Array.from({length:e}).map((l,i)=>s.jsx(it,{aspect:t,animation:n},i))}),dt=({rows:e=8,columns:r=6,className:t="",animation:o="pulse"})=>s.jsxs("div",{className:c("w-full",t),children:[s.jsx("div",{className:"flex gap-4 border-b border-gray-200 pb-3 mb-3",children:Array.from({length:r}).map((n,l)=>s.jsx(T,{className:"h-4 flex-1",animation:o},l))}),Array.from({length:e}).map((n,l)=>s.jsx("div",{className:"flex gap-4 py-3 border-b border-gray-100 last:border-0",children:Array.from({length:r}).map((i,a)=>s.jsx(T,{className:"h-4 flex-1",animation:o},a))},l))]}),ut=({count:e=3,className:r="",animation:t="pulse"})=>s.jsx("div",{className:c("space-y-4",r),children:Array.from({length:e}).map((o,n)=>s.jsxs("div",{children:[s.jsxs("div",{className:"flex justify-between mb-1",children:[s.jsx(T,{className:"h-3 w-32",animation:t}),s.jsx(T,{className:"h-3 w-10",animation:t})]}),s.jsx(T,{className:"h-2 w-full rounded-full",animation:t})]},n))}),{Input:mt,InputArea:pt}=Me;exports.Badge=Zr;exports.Button=J;exports.Calendar=Yr;exports.Checkbox=Qr;exports.DateTimePicker=rt;exports.Dropdown=Kr;exports.EN_DEFAULT_DAY_NAMES=Pe;exports.EN_DEFAULT_MONTH_NAMES=Ie;exports.ES_DEFAULT_DAY_NAMES=Te;exports.ES_DEFAULT_MONTH_NAMES=Oe;exports.ExpandableCard=Br;exports.FileDropZone=qr;exports.Input=mt;exports.InputArea=pt;exports.Loader=Le;exports.Login=Cr;exports.Modal=Xr;exports.Pagination=Fr;exports.SearchInput=Or;exports.Skeleton=T;exports.SkeletonBars=ut;exports.SkeletonCardList=nt;exports.SkeletonGrid=ct;exports.SkeletonList=st;exports.SkeletonTable=dt;exports.TabPanel=Gr;exports.Table=Jr;exports.Tabs=Hr;exports.ThemeProvider=yr;exports.Toggle=Nr;exports.cn=c;exports.defaultTheme=O;exports.generateColorVariants=se;exports.hexToHsl=Ce;exports.hslToHex=ce;exports.useDebounce=ze;exports.useIsMobile=Ir;exports.useTheme=xr;exports.useToast=Tr;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|