@agilys-system/design-system 1.0.13 → 1.0.14
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.
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),y=require("react"),Ge=require("react-dom");function xe(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(r=xe(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function he(){for(var e,t,r=0,n="",a=arguments.length;r<a;r++)(e=arguments[r])&&(t=xe(e))&&(n&&(n+=" "),n+=t);return n}const de=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,ue=he,T=(e,t)=>r=>{var n;if((t==null?void 0:t.variants)==null)return ue(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:a,defaultVariants:s}=t,l=Object.keys(a).map(c=>{const p=r==null?void 0:r[c],b=s==null?void 0:s[c];if(p===null)return null;const f=de(p)||de(b);return a[c][f]}),i=r&&Object.entries(r).reduce((c,p)=>{let[b,f]=p;return f===void 0||(c[b]=f),c},{}),d=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((c,p)=>{let{class:b,className:f,...z}=p;return Object.entries(z).every(N=>{let[x,m]=N;return Array.isArray(m)?m.includes({...s,...i}[x]):{...s,...i}[x]===m})?[...c,b,f]:c},[]);return ue(e,l,d,r==null?void 0:r.class,r==null?void 0:r.className)},ne="-",Be=e=>{const t=He(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:l=>{const i=l.split(ne);return i[0]===""&&i.length!==1&&i.shift(),ye(i,t)||$e(l)},getConflictingClassGroupIds:(l,i)=>{const d=r[l]||[];return i&&n[l]?[...d,...n[l]]:d}}},ye=(e,t)=>{var l;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),a=n?ye(e.slice(1),n):void 0;if(a)return a;if(t.validators.length===0)return;const s=e.join(ne);return(l=t.validators.find(({validator:i})=>i(s)))==null?void 0:l.classGroupId},pe=/^\[(.+)\]$/,$e=e=>{if(pe.test(e)){const t=pe.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},He=e=>{const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return Ue(Object.entries(e.classGroups),r).forEach(([s,l])=>{te(l,n,s,t)}),n},te=(e,t,r,n)=>{e.forEach(a=>{if(typeof a=="string"){const s=a===""?t:fe(t,a);s.classGroupId=r;return}if(typeof a=="function"){if(Fe(a)){te(a(n),t,r,n);return}t.validators.push({validator:a,classGroupId:r});return}Object.entries(a).forEach(([s,l])=>{te(l,fe(t,s),r,n)})})},fe=(e,t)=>{let r=e;return t.split(ne).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},Fe=e=>e.isThemeGetter,Ue=(e,t)=>t?e.map(([r,n])=>{const a=n.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([l,i])=>[t+l,i])):s);return[r,a]}):e,qe=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const a=(s,l)=>{r.set(s,l),t++,t>e&&(t=0,n=r,r=new Map)};return{get(s){let l=r.get(s);if(l!==void 0)return l;if((l=n.get(s))!==void 0)return a(s,l),l},set(s,l){r.has(s)?r.set(s,l):a(s,l)}}},ve="!",Ke=e=>{const{separator:t,experimentalParseClassName:r}=e,n=t.length===1,a=t[0],s=t.length,l=i=>{const d=[];let c=0,p=0,b;for(let m=0;m<i.length;m++){let w=i[m];if(c===0){if(w===a&&(n||i.slice(m,m+s)===t)){d.push(i.slice(p,m)),p=m+s;continue}if(w==="/"){b=m;continue}}w==="["?c++:w==="]"&&c--}const f=d.length===0?i:i.substring(p),z=f.startsWith(ve),N=z?f.substring(1):f,x=b&&b>p?b-p:void 0;return{modifiers:d,hasImportantModifier:z,baseClassName:N,maybePostfixModifierPosition:x}};return r?i=>r({className:i,parseClassName:l}):l},Je=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t},Xe=e=>({cache:qe(e.cacheSize),parseClassName:Ke(e),...Be(e)}),Ze=/\s+/,De=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:a}=t,s=[],l=e.trim().split(Ze);let i="";for(let d=l.length-1;d>=0;d-=1){const c=l[d],{modifiers:p,hasImportantModifier:b,baseClassName:f,maybePostfixModifierPosition:z}=r(c);let N=!!z,x=n(N?f.substring(0,z):f);if(!x){if(!N){i=c+(i.length>0?" "+i:i);continue}if(x=n(f),!x){i=c+(i.length>0?" "+i:i);continue}N=!1}const m=Je(p).join(":"),w=b?m+ve:m,C=w+x;if(s.includes(C))continue;s.push(C);const S=a(x,N);for(let M=0;M<S.length;++M){const L=S[M];s.push(w+L)}i=c+(i.length>0?" "+i:i)}return i};function Qe(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=we(t))&&(n&&(n+=" "),n+=r);return n}const we=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=we(e[n]))&&(r&&(r+=" "),r+=t);return r};function Ye(e,...t){let r,n,a,s=l;function l(d){const c=t.reduce((p,b)=>b(p),e());return r=Xe(c),n=r.cache.get,a=r.cache.set,s=i,i(d)}function i(d){const c=n(d);if(c)return c;const p=De(d,r);return a(d,p),p}return function(){return s(Qe.apply(null,arguments))}}const h=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},je=/^\[(?:([a-z-]+):)?(.+)\]$/i,et=/^\d+\/\d+$/,tt=new Set(["px","full","screen"]),rt=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,nt=/\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$/,ot=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,st=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,at=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,O=e=>P(e)||tt.has(e)||et.test(e),V=e=>W(e,"length",bt),P=e=>!!e&&!Number.isNaN(Number(e)),ee=e=>W(e,"number",P),$=e=>!!e&&Number.isInteger(Number(e)),it=e=>e.endsWith("%")&&P(e.slice(0,-1)),u=e=>je.test(e),E=e=>rt.test(e),lt=new Set(["length","size","percentage"]),ct=e=>W(e,lt,ke),dt=e=>W(e,"position",ke),ut=new Set(["image","url"]),pt=e=>W(e,ut,gt),ft=e=>W(e,"",mt),H=()=>!0,W=(e,t,r)=>{const n=je.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1},bt=e=>nt.test(e)&&!ot.test(e),ke=()=>!1,mt=e=>st.test(e),gt=e=>at.test(e),xt=()=>{const e=h("colors"),t=h("spacing"),r=h("blur"),n=h("brightness"),a=h("borderColor"),s=h("borderRadius"),l=h("borderSpacing"),i=h("borderWidth"),d=h("contrast"),c=h("grayscale"),p=h("hueRotate"),b=h("invert"),f=h("gap"),z=h("gradientColorStops"),N=h("gradientColorStopPositions"),x=h("inset"),m=h("margin"),w=h("opacity"),C=h("padding"),S=h("saturate"),M=h("scale"),L=h("sepia"),U=h("skew"),j=h("space"),_=h("translate"),R=()=>["auto","contain","none"],I=()=>["auto","hidden","clip","visible","scroll"],G=()=>["auto",u,t],v=()=>[u,t],ae=()=>["",O,V],q=()=>["auto",P,u],ie=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],K=()=>["solid","dashed","dotted","double","none"],le=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Y=()=>["start","end","center","between","around","evenly","stretch"],B=()=>["","0",u],ce=()=>["auto","avoid","all","avoid-page","page","left","right","column"],A=()=>[P,u];return{cacheSize:500,separator:":",theme:{colors:[H],spacing:[O,V],blur:["none","",E,u],brightness:A(),borderColor:[e],borderRadius:["none","","full",E,u],borderSpacing:v(),borderWidth:ae(),contrast:A(),grayscale:B(),hueRotate:A(),invert:B(),gap:v(),gradientColorStops:[e],gradientColorStopPositions:[it,V],inset:G(),margin:G(),opacity:A(),padding:v(),saturate:A(),scale:A(),sepia:B(),skew:A(),space:v(),translate:v()},classGroups:{aspect:[{aspect:["auto","square","video",u]}],container:["container"],columns:[{columns:[E]}],"break-after":[{"break-after":ce()}],"break-before":[{"break-before":ce()}],"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:[...ie(),u]}],overflow:[{overflow:I()}],"overflow-x":[{"overflow-x":I()}],"overflow-y":[{"overflow-y":I()}],overscroll:[{overscroll:R()}],"overscroll-x":[{"overscroll-x":R()}],"overscroll-y":[{"overscroll-y":R()}],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",$,u]}],basis:[{basis:G()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",u]}],grow:[{grow:B()}],shrink:[{shrink:B()}],order:[{order:["first","last","none",$,u]}],"grid-cols":[{"grid-cols":[H]}],"col-start-end":[{col:["auto",{span:["full",$,u]},u]}],"col-start":[{"col-start":q()}],"col-end":[{"col-end":q()}],"grid-rows":[{"grid-rows":[H]}],"row-start-end":[{row:["auto",{span:[$,u]},u]}],"row-start":[{"row-start":q()}],"row-end":[{"row-end":q()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",u]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",u]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:["normal",...Y()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Y(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Y(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[C]}],px:[{px:[C]}],py:[{py:[C]}],ps:[{ps:[C]}],pe:[{pe:[C]}],pt:[{pt:[C]}],pr:[{pr:[C]}],pb:[{pb:[C]}],pl:[{pl:[C]}],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":[j]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[j]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",u,t]}],"min-w":[{"min-w":[u,t,"min","max","fit"]}],"max-w":[{"max-w":[u,t,"none","full","min","max","fit","prose",{screen:[E]},E]}],h:[{h:[u,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[u,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[u,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[u,t,"auto","min","max","fit"]}],"font-size":[{text:["base",E,V]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",ee]}],"font-family":[{font:[H]}],"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",u]}],"line-clamp":[{"line-clamp":["none",P,ee]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",O,u]}],"list-image":[{"list-image":["none",u]}],"list-style-type":[{list:["none","disc","decimal",u]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[w]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[w]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...K(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",O,V]}],"underline-offset":[{"underline-offset":["auto",O,u]}],"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:v()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",u]}],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",u]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[w]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ie(),dt]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",ct]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},pt]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[N]}],"gradient-via-pos":[{via:[N]}],"gradient-to-pos":[{to:[N]}],"gradient-from":[{from:[z]}],"gradient-via":[{via:[z]}],"gradient-to":[{to:[z]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[i]}],"border-w-x":[{"border-x":[i]}],"border-w-y":[{"border-y":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[w]}],"border-style":[{border:[...K(),"hidden"]}],"divide-x":[{"divide-x":[i]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[i]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[w]}],"divide-style":[{divide:K()}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-s":[{"border-s":[a]}],"border-color-e":[{"border-e":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["",...K()]}],"outline-offset":[{"outline-offset":[O,u]}],"outline-w":[{outline:[O,V]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:ae()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[w]}],"ring-offset-w":[{"ring-offset":[O,V]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",E,ft]}],"shadow-color":[{shadow:[H]}],opacity:[{opacity:[w]}],"mix-blend":[{"mix-blend":[...le(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":le()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",E,u]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[b]}],saturate:[{saturate:[S]}],sepia:[{sepia:[L]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[b]}],"backdrop-opacity":[{"backdrop-opacity":[w]}],"backdrop-saturate":[{"backdrop-saturate":[S]}],"backdrop-sepia":[{"backdrop-sepia":[L]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[l]}],"border-spacing-x":[{"border-spacing-x":[l]}],"border-spacing-y":[{"border-spacing-y":[l]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",u]}],duration:[{duration:A()}],ease:[{ease:["linear","in","out","in-out",u]}],delay:[{delay:A()}],animate:[{animate:["none","spin","ping","pulse","bounce",u]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[M]}],"scale-x":[{"scale-x":[M]}],"scale-y":[{"scale-y":[M]}],rotate:[{rotate:[$,u]}],"translate-x":[{"translate-x":[_]}],"translate-y":[{"translate-y":[_]}],"skew-x":[{"skew-x":[U]}],"skew-y":[{"skew-y":[U]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",u]}],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",u]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":v()}],"scroll-mx":[{"scroll-mx":v()}],"scroll-my":[{"scroll-my":v()}],"scroll-ms":[{"scroll-ms":v()}],"scroll-me":[{"scroll-me":v()}],"scroll-mt":[{"scroll-mt":v()}],"scroll-mr":[{"scroll-mr":v()}],"scroll-mb":[{"scroll-mb":v()}],"scroll-ml":[{"scroll-ml":v()}],"scroll-p":[{"scroll-p":v()}],"scroll-px":[{"scroll-px":v()}],"scroll-py":[{"scroll-py":v()}],"scroll-ps":[{"scroll-ps":v()}],"scroll-pe":[{"scroll-pe":v()}],"scroll-pt":[{"scroll-pt":v()}],"scroll-pr":[{"scroll-pr":v()}],"scroll-pb":[{"scroll-pb":v()}],"scroll-pl":[{"scroll-pl":v()}],"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",u]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[O,V,ee]}],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"]}}},ht=Ye(xt);function g(...e){return ht(he(e))}const Ne=T("font-sans text-gray-900",{variants:{variant:{h1:"text-3xl leading-tight font-bold",h2:"text-2xl leading-tight font-bold",h3:"text-xl leading-snug font-semibold",h4:"text-lg leading-snug font-semibold",h5:"text-base leading-snug font-medium",h6:"text-sm leading-snug font-medium",body:"text-sm leading-relaxed font-normal",bodySm:"text-xs leading-relaxed font-normal",caption:"text-[11px] leading-normal font-normal"},weight:{regular:"font-normal",medium:"font-medium",semibold:"font-semibold",bold:"font-bold"}},defaultVariants:{variant:"body"}}),yt={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",body:"p",bodySm:"p",caption:"span"},k=y.forwardRef(({className:e,variant:t="body",weight:r,as:n,children:a,...s},l)=>{const i=n??yt[t??"body"];return y.createElement(i,{ref:l,className:g(Ne({variant:t,weight:r}),e),...s},a)});k.displayName="Text";const Ce=T("inline-flex items-center justify-center gap-2 rounded-lg transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-agilys-primary disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{primary:"bg-agilys-primary text-white shadow-[0px_2px_6px_0px_rgba(71,71,245,0.16),inset_0px_0px_10px_0px_rgba(255,255,255,0.3)] hover:bg-agilys-primary/90",secondary:"bg-white text-neutral-secondary shadow-[0px_0px_2px_0px_rgba(66,74,98,0.04),0px_3px_8px_0px_rgba(66,74,98,0.09)] hover:bg-gray-50",destructive:"bg-danger-light text-danger-dark shadow-[0px_2px_6px_0px_rgba(243,22,22,0.16)] hover:bg-danger-light/80"},size:{sm:"h-9 px-3",md:"h-10 px-4",lg:"h-11 px-6",icon:"size-10 p-0 shrink-0"},fullWidth:{true:"w-full"}},defaultVariants:{variant:"primary",size:"md"}}),vt={sm:"bodySm",md:"body",lg:"body",icon:"body"},ze=y.forwardRef(({className:e,variant:t,size:r,fullWidth:n,isLoading:a=!1,leftIcon:s,disabled:l,children:i,...d},c)=>{const p=r==="icon",b=vt[r??"md"];return o.jsxs("button",{ref:c,className:g(Ce({variant:t,size:r,fullWidth:n}),e),disabled:l||a,"aria-busy":a,...d,children:[a&&o.jsxs("svg",{className:"size-[18px] animate-spin",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),o.jsx("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8v4a4 4 0 00-4 4H4z"})]}),!a&&s&&o.jsx("span",{className:"inline-flex shrink-0","aria-hidden":"true",children:s}),p?o.jsx("span",{className:"inline-flex shrink-0",children:i}):o.jsx(k,{as:"span",variant:b,className:"text-inherit",children:i})]})});ze.displayName="Button";const _e=T("inline-flex items-center justify-center h-6 whitespace-nowrap",{variants:{variant:{filled:"rounded-lg px-3",dot:"rounded bg-white gap-1.5 px-2"},status:{default:"",success:"",alert:"",error:""}},compoundVariants:[{variant:"filled",status:"default",class:"bg-agilys-primary text-white"},{variant:"filled",status:"success",class:"bg-success-10 text-success-60"},{variant:"filled",status:"alert",class:"bg-warning-light text-warning-accent"},{variant:"filled",status:"error",class:"bg-danger-10 text-danger-60"},{variant:"dot",status:"default",class:"text-agilys-primary"},{variant:"dot",status:"success",class:"text-success-60"},{variant:"dot",status:"alert",class:"text-warning-dark"},{variant:"dot",status:"error",class:"text-danger-60"}],defaultVariants:{variant:"filled",status:"default"}}),wt={default:"bg-agilys-primary",success:"bg-success-60",alert:"bg-warning-accent",error:"bg-danger-60"},Se=y.forwardRef(({className:e,variant:t="filled",status:r="default",children:n,...a},s)=>o.jsxs("span",{ref:s,className:g(_e({variant:t,status:r}),e),...a,children:[t==="dot"&&o.jsx("span",{className:g("size-2 shrink-0 rounded-full",wt[r??"default"]),"aria-hidden":"true"}),o.jsx(k,{as:"span",variant:"body",className:"text-inherit",children:n})]}));Se.displayName="Badge";const Me=T("flex items-start gap-2 rounded-lg p-5 font-sans",{variants:{variant:{default:"border border-neutral-divider-secondary bg-white shadow-[0px_0px_1px_0px_rgba(66,74,98,0.09),0px_2px_2px_0px_rgba(66,74,98,0.04)]",success:"border border-transparent bg-success-10",warning:"border border-transparent bg-warning-light",error:"border border-transparent bg-danger-10",info:"border border-transparent bg-primary-50"}},defaultVariants:{variant:"default"}}),jt={default:"text-neutral-text-primary",success:"text-success-60",warning:"text-warning-dark",error:"text-danger-dark",info:"text-primary-700"};function kt(){return o.jsxs("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("circle",{cx:"12",cy:"12",r:"9",stroke:"currentColor",strokeWidth:"2"}),o.jsx("path",{d:"M12 11v5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"}),o.jsx("circle",{cx:"12",cy:"8",r:"1",fill:"currentColor"})]})}function Nt(){return o.jsxs("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("circle",{cx:"12",cy:"12",r:"9",stroke:"currentColor",strokeWidth:"2"}),o.jsx("path",{d:"M8.5 12.5l2.5 2.5 4.5-5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})}function Ct(){return o.jsxs("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("path",{d:"M12 3.5L21 20H3L12 3.5z",stroke:"currentColor",strokeWidth:"2",strokeLinejoin:"round"}),o.jsx("path",{d:"M12 10v4",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"}),o.jsx("circle",{cx:"12",cy:"17",r:"1",fill:"currentColor"})]})}function zt(){return o.jsxs("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("circle",{cx:"12",cy:"12",r:"9",stroke:"currentColor",strokeWidth:"2"}),o.jsx("path",{d:"M9.5 9.5l5 5m0-5l-5 5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})]})}function _t(){return o.jsx("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:"M18 6L6 18M6 6l12 12",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})})}const St={success:o.jsx(Nt,{}),warning:o.jsx(Ct,{}),error:o.jsx(zt,{}),info:o.jsx(kt,{})},oe=y.forwardRef(({className:e,variant:t="default",icon:r,title:n,description:a,action:s,onClose:l,children:i,...d},c)=>{const p=t??"default",b=r===void 0?St[p]:r,f=jt[p];return o.jsxs("div",{ref:c,className:g(Me({variant:t}),e),...d,children:[b&&o.jsx("span",{className:g("size-6 shrink-0",f),"aria-hidden":"true",children:b}),o.jsxs("div",{className:"flex min-w-0 flex-1 flex-col gap-1",children:[n&&o.jsx(k,{as:"div",variant:"body",weight:"semibold",className:f,children:n}),a&&o.jsx(k,{as:"div",variant:"bodySm",className:"text-neutral-text-secondary",children:a}),i]}),s&&o.jsx("div",{className:"flex shrink-0 items-center",children:s}),l&&o.jsx("button",{type:"button",onClick:l,"aria-label":"Fechar",className:g("flex size-5 shrink-0 items-center justify-center rounded-md transition-colors hover:opacity-70 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",f),children:o.jsx(_t,{})})]})});oe.displayName="Card";var Ie={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},be=y.createContext&&y.createContext(Ie),Mt=["attr","size","title"];function It(e,t){if(e==null)return{};var r,n,a=At(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(n=0;n<s.length;n++)r=s[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function At(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function X(){return X=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},X.apply(null,arguments)}function me(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Z(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?me(Object(r),!0).forEach(function(n){Ot(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):me(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Ot(e,t,r){return(t=Vt(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Vt(e){var t=Et(e,"string");return typeof t=="symbol"?t:t+""}function Et(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ae(e){return e&&e.map((t,r)=>y.createElement(t.tag,Z({key:r},t.attr),Ae(t.child)))}function Oe(e){return t=>y.createElement(Rt,X({attr:Z({},e.attr)},t),Ae(e.child))}function Rt(e){var t=r=>{var n=e.attr,a=e.size,s=e.title,l=It(e,Mt),i=a||r.size||"1em",d;return r.className&&(d=r.className),e.className&&(d=(d?d+" ":"")+e.className),y.createElement("svg",X({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},r.attr,n,l,{className:d,style:Z(Z({color:e.color||r.color},r.style),e.style),height:i,width:i,xmlns:"http://www.w3.org/2000/svg"}),s&&y.createElement("title",null,s),e.children)};return be!==void 0?y.createElement(be.Consumer,null,r=>t(r)):t(Ie)}function Lt(e){return Oe({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M80 152v256a40.12 40.12 0 0 0 40 40h272a40.12 40.12 0 0 0 40-40V152"},child:[]},{tag:"rect",attr:{width:"416",height:"80",x:"48",y:"64",fill:"none",strokeLinejoin:"round",strokeWidth:"32",rx:"28",ry:"28"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"m320 304-64 64-64-64m64 41.89V224"},child:[]}]})(e)}function Pt(e){return Oe({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M16 9v10H8V9zm-1.5-6h-5l-1 1H5v2h14V4h-3.5zM18 7H6v12c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2z"},child:[]}]})(e)}const Ve=y.forwardRef(({className:e,title:t,body:r,timestamp:n,read:a=!1,onArchive:s,onDelete:l,...i},d)=>o.jsxs(oe,{ref:d,icon:null,className:g(!a&&"border-transparent bg-lightGray",e),...i,children:[o.jsxs("div",{className:"flex items-start justify-between gap-3",children:[o.jsxs("div",{className:"flex min-w-0 items-center gap-2",children:[!a&&o.jsx("span",{className:"size-2 shrink-0 rounded-full bg-danger-60","aria-label":"Não visualizada"}),o.jsx(k,{as:"div",variant:"body",weight:"semibold",className:"truncate text-neutral-text-primary",children:t})]}),o.jsx(k,{as:"span",variant:"caption",className:"shrink-0 text-neutral-text-secondary",children:n})]}),o.jsx(k,{as:"div",variant:"bodySm",className:"text-neutral-text-secondary",children:r}),o.jsxs("div",{className:"flex items-center justify-end gap-1 pt-1",children:[o.jsx("button",{type:"button",onClick:s,"aria-label":"Arquivar",className:"flex size-7 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:bg-neutral-surface-selected hover:text-neutral-text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",children:o.jsx(Lt,{className:"size-4","aria-hidden":"true"})}),o.jsx("button",{type:"button",onClick:l,"aria-label":"Excluir",className:"flex size-7 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:bg-danger-10 hover:text-danger-60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",children:o.jsx(Pt,{className:"size-4","aria-hidden":"true"})})]})]}));Ve.displayName="NotificationCard";function Tt(e,t){return t.split(".").reduce((r,n)=>r==null?void 0:r[n],e)}function Wt(e,t){if(t.callback)return t.callback(e);if(!t.key)return null;const r=Tt(e,t.key);return r==null||r===""?null:o.jsx(k,{as:"span",variant:"body",className:"truncate text-neutral-text-primary",children:r})}const Ee={left:"text-left justify-start",center:"text-center justify-center",right:"text-right justify-end"},D=y.forwardRef(({className:e,...t},r)=>o.jsxs("span",{className:"relative inline-flex size-5 shrink-0 items-center justify-center",children:[o.jsx("input",{ref:r,type:"checkbox",className:g("peer size-5 shrink-0 cursor-pointer appearance-none rounded border-2 border-neutral-divider-primary bg-white shadow-[0px_0px_2px_0px_rgba(66,74,98,0.09)] checked:border-agilys-primary checked:bg-agilys-primary disabled:cursor-not-allowed disabled:opacity-50",e),...t}),o.jsx("svg",{className:"pointer-events-none absolute size-3 text-white opacity-0 peer-checked:opacity-100",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:"M5 13l4 4L19 7",stroke:"currentColor",strokeWidth:"3",strokeLinecap:"round",strokeLinejoin:"round"})})]}));D.displayName="TableCheckbox";function Gt({className:e}){return o.jsx("svg",{className:g("size-5 shrink-0",e),viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:"M8 9l4-4 4 4M8 15l4 4 4-4",stroke:"currentColor",strokeWidth:"1.7",strokeLinecap:"round",strokeLinejoin:"round"})})}const Q=y.forwardRef(({className:e,align:t="left",sortable:r,sorted:n,onSort:a,children:s,...l},i)=>o.jsx("th",{ref:i,className:g("border-b border-neutral-divider-secondary px-5 py-2",e),...l,children:o.jsxs("span",{className:g("flex items-center gap-1.5",Ee[t??"left"],r&&"cursor-pointer select-none"),onClick:r?a:void 0,children:[o.jsx(k,{as:"span",variant:"bodySm",weight:"medium",className:"flex-1 truncate text-neutral-text-secondary",children:s}),r&&o.jsx(Gt,{className:g(n&&"text-agilys-primary")})]})}));Q.displayName="TableHeadCell";function re({align:e="left",className:t,children:r,onClick:n}){return o.jsx("td",{onClick:n,className:g("border-b border-neutral-divider-secondary px-5 py-3",t),children:o.jsx(k,{className:g("flex items-center gap-2",Ee[e??"left"]),children:r})})}function Bt(e,t,r){if(typeof r=="function")return r(e);const n=e;return r?n[r]??t:n.id??t}function $t({keys:e,data:t,rowKey:r,loading:n,loadingMessage:a="Carregando dados...",emptyMessage:s="Nenhum dado para ser exibido!",selectable:l,selectedRowKeys:i,onSelectionChange:d,sortKey:c,sortDirection:p,onSortChange:b,onRowClick:f,shadow:z=!1,border:N=!0,className:x,...m}){const w=e.length+(l?1:0),C=i??[],S=t.map((j,_)=>Bt(j,_,r)),M=S.length>0&&S.every(j=>C.includes(j)),L=()=>{d&&d(M?[]:S)},U=j=>{d&&d(C.includes(j)?C.filter(_=>_!==j):[...C,j])};return o.jsx("div",{className:g("w-full overflow-x-auto rounded-lg",N&&"border border-neutral-divider-secondary",z&&"shadow-[0px_0px_2px_0px_rgba(66,74,98,0.04),0px_3px_8px_0px_rgba(66,74,98,0.09)]"),children:o.jsxs("table",{className:g("w-full border-collapse font-sans",x),...m,children:[o.jsx("thead",{children:o.jsxs("tr",{children:[l&&o.jsx(Q,{align:"center",className:"w-11",children:o.jsx(D,{checked:M,onChange:L,"aria-label":"Selecionar todas as linhas"})}),e.map((j,_)=>o.jsx(Q,{align:j.align,sortable:!!j.key&&!!b,sorted:j.key&&c===j.key?p:!1,onSort:()=>j.key&&(b==null?void 0:b(j.key)),children:j.label},j.key??`column-${_}`))]})}),o.jsx("tbody",{children:n?o.jsx("tr",{children:o.jsx("td",{colSpan:w,className:"border-b border-neutral-divider-secondary bg-neutral-surface-lightest px-5 py-6",children:o.jsx(k,{as:"p",variant:"body",className:"w-full text-center text-neutral-text-secondary",children:a})})}):t.length===0?o.jsx("tr",{children:o.jsx("td",{colSpan:w,className:"border-b border-neutral-divider-secondary bg-neutral-surface-lightest px-5 py-6",children:o.jsx(k,{as:"p",variant:"body",className:"w-full text-center text-neutral-text-secondary",children:s})})}):t.map((j,_)=>{const R=S[_];return o.jsxs("tr",{onClick:f?()=>f(j):void 0,className:g(_%2===0?"bg-neutral-surface-lightest":"bg-white",f&&"cursor-pointer"),children:[l&&o.jsx(re,{align:"center",onClick:I=>I.stopPropagation(),children:o.jsx(D,{checked:C.includes(R),onChange:()=>U(R),"aria-label":"Selecionar linha"})}),e.map((I,G)=>o.jsx(re,{align:I.align,className:I.className,children:Wt(j,I)},I.key??`column-${G}`))]},R)})})]})})}const Re=T("relative inline-flex shrink-0 items-center justify-center overflow-hidden rounded-full bg-neutral-surface-lightest font-sans font-medium text-neutral-text-secondary",{variants:{size:{sm:"size-6 text-xs",md:"size-7 text-sm",lg:"size-10 text-base"}},defaultVariants:{size:"md"}});function Ht(e){var n;const t=e.trim().split(/\s+/),r=t.length>1?`${t[0][0]}${t[t.length-1][0]}`:(n=t[0])==null?void 0:n.slice(0,2);return r==null?void 0:r.toUpperCase()}const Ft={sm:"caption",md:"bodySm",lg:"body"},se=y.forwardRef(({className:e,size:t,src:r,alt:n="",name:a,...s},l)=>{const i=t??"md";return o.jsx("span",{ref:l,className:g(Re({size:t}),e),...s,children:r?o.jsx("img",{src:r,alt:n,className:"size-full object-cover"}):a&&o.jsx(k,{as:"span",variant:Ft[i],weight:"medium",className:"text-inherit leading-none",children:Ht(a)})})});se.displayName="Avatar";function Ut({src:e,name:t,description:r,size:n="md",className:a}){return o.jsxs("div",{className:g("flex min-w-0 items-center gap-2",a),children:[o.jsx(se,{src:e,name:t,size:n}),o.jsxs("div",{className:"flex min-w-0 flex-col",children:[o.jsx(k,{as:"span",variant:"body",className:"truncate",children:t}),r&&o.jsx(k,{as:"span",variant:"bodySm",className:"truncate text-neutral-text-secondary",children:r})]})]})}const F="ellipsis";function J(e,t){return Array.from({length:t-e+1},(r,n)=>e+n)}function qt(e,t,r){if(r*2+5>=t)return J(1,t);const a=Math.max(e-r,1),s=Math.min(e+r,t),l=a>2,i=s<t-1;return!l&&i?[...J(1,3+r*2),F,t]:l&&!i?[1,F,...J(t-(2+r*2),t)]:[1,F,...J(a,s),F,t]}function ge({direction:e,className:t}){return o.jsx("svg",{className:g("size-4",t),viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:e==="left"?"M15 6l-6 6 6 6":"M9 6l6 6-6 6",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})})}const Le=y.forwardRef(({currentPage:e,totalPages:t,onPageChange:r,siblingCount:n=1,className:a,...s},l)=>{if(t<=1)return null;const i=qt(e,t,n),d=c=>{c<1||c>t||c===e||r(c)};return o.jsxs("nav",{ref:l,"aria-label":"Paginação",className:g("flex items-center gap-1 font-sans",a),...s,children:[o.jsx("button",{type:"button","aria-label":"Página anterior",disabled:e===1,onClick:()=>d(e-1),className:"inline-flex size-9 shrink-0 items-center justify-center rounded-lg text-neutral-text-secondary transition-colors hover:bg-neutral-surface-lightest disabled:pointer-events-none disabled:opacity-40",children:o.jsx(ge,{direction:"left"})}),i.map((c,p)=>c===F?o.jsx("span",{className:"inline-flex size-9 shrink-0 items-center justify-center text-neutral-text-secondary",children:o.jsx(k,{as:"span",variant:"bodySm",className:"text-inherit",children:"…"})},`ellipsis-${p}`):o.jsx("button",{type:"button","aria-current":c===e?"page":void 0,onClick:()=>d(c),className:g("inline-flex size-9 shrink-0 items-center justify-center rounded-lg transition-colors",c===e?"bg-neutral-surface-selected text-agilys-primary":"text-neutral-text-secondary hover:bg-neutral-surface-lightest"),children:o.jsx(k,{as:"span",variant:"bodySm",weight:"medium",className:"text-inherit",children:c})},c)),o.jsx("button",{type:"button","aria-label":"Próxima página",disabled:e===t,onClick:()=>d(e+1),className:"inline-flex size-9 shrink-0 items-center justify-center rounded-lg text-neutral-text-secondary transition-colors hover:bg-neutral-surface-lightest disabled:pointer-events-none disabled:opacity-40",children:o.jsx(ge,{direction:"right"})})]})});Le.displayName="Pagination";const Pe=T("flex h-11 w-full min-w-0 items-center gap-2 rounded-lg bg-white px-3 shadow-[0px_1px_2px_0px_rgba(0,0,0,0.25)] transition-shadow focus-within:ring-2 focus-within:ring-agilys-primary",{variants:{hasError:{true:"ring-2 ring-danger-60 focus-within:ring-danger-60",false:""}},defaultVariants:{hasError:!1}}),Te=y.forwardRef(({className:e,containerClassName:t,label:r,leftIcon:n,rightIcon:a,bgIcon:s=!1,error:l,disabled:i,id:d,...c},p)=>{const b=y.useId(),f=d??b,z=typeof l=="string"?l:l==null?void 0:l.message,N=!!z,x=`${f}-error`;return o.jsxs("div",{className:g("flex w-full min-w-0 flex-col gap-1.5",t),children:[r&&o.jsx(k,{as:"label",htmlFor:f,variant:"body",className:"text-neutral-text-primary",children:r}),o.jsxs("div",{className:g(Pe({hasError:N}),i&&"pointer-events-none opacity-50"),children:[n&&o.jsx("span",{className:"flex size-6 shrink-0 items-center justify-center text-neutral-secondary [&>svg]:size-full","aria-hidden":"true",children:n}),o.jsx("input",{ref:p,id:f,disabled:i,"aria-invalid":N||void 0,"aria-describedby":N?x:void 0,className:g("w-full min-w-0 flex-1 bg-transparent font-sans text-xs leading-relaxed font-normal text-black placeholder:font-sans placeholder:text-xs placeholder:leading-relaxed placeholder:font-normal placeholder:text-neutral-secondary/60 focus:outline-none disabled:cursor-not-allowed",e),...c}),a&&o.jsx("span",{className:g("flex size-6 shrink-0 items-center justify-center text-neutral-secondary [&>svg]:size-full",s&&"rounded-md bg-lightGray p-1"),"aria-hidden":"true",children:a})]}),N&&o.jsx(k,{as:"span",id:x,role:"alert",variant:"caption",className:"text-danger-60",children:z})]})});Te.displayName="Input";function Kt(){return o.jsx("svg",{className:"size-5",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:"M18 6L6 18M6 6l12 12",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})})}const We=y.forwardRef(({open:e,onClose:t,title:r,children:n,footer:a,closeOnBackdropClick:s=!0,showCloseButton:l=!0,className:i,contentClassName:d,...c},p)=>{const b=y.useId(),f=y.useRef(null),[z,N]=y.useState(!1);return y.useEffect(()=>N(!0),[]),y.useEffect(()=>{var w;if(!e)return;const x=document.body.style.overflow;document.body.style.overflow="hidden",(w=f.current)==null||w.focus();const m=C=>{C.key==="Escape"&&t()};return document.addEventListener("keydown",m),()=>{document.body.style.overflow=x,document.removeEventListener("keydown",m)}},[e,t]),!e||!z?null:Ge.createPortal(o.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center overflow-y-auto bg-black/40 p-4",onClick:s?t:void 0,children:o.jsxs("div",{ref:p,role:"dialog","aria-modal":"true","aria-labelledby":r?b:void 0,onClick:x=>x.stopPropagation(),className:g("relative flex w-full min-w-0 max-w-lg flex-col gap-6 rounded-xl bg-[#fcfcfc] p-6 shadow-[0px_0px_2px_0px_rgba(34,34,34,0.08)] sm:p-8",i),...c,children:[l&&o.jsx("button",{ref:f,type:"button",onClick:t,"aria-label":"Fechar",className:"absolute right-4 top-4 flex size-6 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:text-neutral-text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary sm:right-5 sm:top-5",children:o.jsx(Kt,{})}),r&&o.jsx("div",{className:"pr-8",children:o.jsx(k,{as:"h2",id:b,variant:"h4",weight:"medium",className:"text-neutral-text-primary",children:r})}),o.jsx("div",{className:g("max-h-[70vh] min-w-0 overflow-y-auto overflow-x-hidden font-sans text-sm leading-relaxed text-neutral-text-secondary sm:text-base",d),children:n}),a&&o.jsx("div",{className:"flex flex-wrap items-center gap-2.5 pt-1",children:a})]})}),document.body)});We.displayName="Modal";exports.Avatar=se;exports.AvatarColumn=Ut;exports.Badge=Se;exports.Button=ze;exports.Card=oe;exports.Input=Te;exports.Modal=We;exports.NotificationCard=Ve;exports.Pagination=Le;exports.Table=$t;exports.TableCell=re;exports.TableCheckbox=D;exports.TableHeadCell=Q;exports.Text=k;exports.avatarVariants=Re;exports.badgeVariants=_e;exports.buttonVariants=Ce;exports.cardVariants=Me;exports.cn=g;exports.inputVariants=Pe;exports.textVariants=Ne;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),y=require("react"),Ge=require("react-dom");function xe(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(r=xe(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function he(){for(var e,t,r=0,n="",a=arguments.length;r<a;r++)(e=arguments[r])&&(t=xe(e))&&(n&&(n+=" "),n+=t);return n}const de=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,ue=he,T=(e,t)=>r=>{var n;if((t==null?void 0:t.variants)==null)return ue(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:a,defaultVariants:s}=t,l=Object.keys(a).map(c=>{const p=r==null?void 0:r[c],b=s==null?void 0:s[c];if(p===null)return null;const f=de(p)||de(b);return a[c][f]}),i=r&&Object.entries(r).reduce((c,p)=>{let[b,f]=p;return f===void 0||(c[b]=f),c},{}),d=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((c,p)=>{let{class:b,className:f,...z}=p;return Object.entries(z).every(N=>{let[x,m]=N;return Array.isArray(m)?m.includes({...s,...i}[x]):{...s,...i}[x]===m})?[...c,b,f]:c},[]);return ue(e,l,d,r==null?void 0:r.class,r==null?void 0:r.className)},ne="-",Be=e=>{const t=He(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:l=>{const i=l.split(ne);return i[0]===""&&i.length!==1&&i.shift(),ye(i,t)||$e(l)},getConflictingClassGroupIds:(l,i)=>{const d=r[l]||[];return i&&n[l]?[...d,...n[l]]:d}}},ye=(e,t)=>{var l;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),a=n?ye(e.slice(1),n):void 0;if(a)return a;if(t.validators.length===0)return;const s=e.join(ne);return(l=t.validators.find(({validator:i})=>i(s)))==null?void 0:l.classGroupId},pe=/^\[(.+)\]$/,$e=e=>{if(pe.test(e)){const t=pe.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},He=e=>{const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return Ue(Object.entries(e.classGroups),r).forEach(([s,l])=>{te(l,n,s,t)}),n},te=(e,t,r,n)=>{e.forEach(a=>{if(typeof a=="string"){const s=a===""?t:fe(t,a);s.classGroupId=r;return}if(typeof a=="function"){if(Fe(a)){te(a(n),t,r,n);return}t.validators.push({validator:a,classGroupId:r});return}Object.entries(a).forEach(([s,l])=>{te(l,fe(t,s),r,n)})})},fe=(e,t)=>{let r=e;return t.split(ne).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},Fe=e=>e.isThemeGetter,Ue=(e,t)=>t?e.map(([r,n])=>{const a=n.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([l,i])=>[t+l,i])):s);return[r,a]}):e,qe=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const a=(s,l)=>{r.set(s,l),t++,t>e&&(t=0,n=r,r=new Map)};return{get(s){let l=r.get(s);if(l!==void 0)return l;if((l=n.get(s))!==void 0)return a(s,l),l},set(s,l){r.has(s)?r.set(s,l):a(s,l)}}},ve="!",Ke=e=>{const{separator:t,experimentalParseClassName:r}=e,n=t.length===1,a=t[0],s=t.length,l=i=>{const d=[];let c=0,p=0,b;for(let m=0;m<i.length;m++){let w=i[m];if(c===0){if(w===a&&(n||i.slice(m,m+s)===t)){d.push(i.slice(p,m)),p=m+s;continue}if(w==="/"){b=m;continue}}w==="["?c++:w==="]"&&c--}const f=d.length===0?i:i.substring(p),z=f.startsWith(ve),N=z?f.substring(1):f,x=b&&b>p?b-p:void 0;return{modifiers:d,hasImportantModifier:z,baseClassName:N,maybePostfixModifierPosition:x}};return r?i=>r({className:i,parseClassName:l}):l},Je=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t},Xe=e=>({cache:qe(e.cacheSize),parseClassName:Ke(e),...Be(e)}),Ze=/\s+/,De=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:a}=t,s=[],l=e.trim().split(Ze);let i="";for(let d=l.length-1;d>=0;d-=1){const c=l[d],{modifiers:p,hasImportantModifier:b,baseClassName:f,maybePostfixModifierPosition:z}=r(c);let N=!!z,x=n(N?f.substring(0,z):f);if(!x){if(!N){i=c+(i.length>0?" "+i:i);continue}if(x=n(f),!x){i=c+(i.length>0?" "+i:i);continue}N=!1}const m=Je(p).join(":"),w=b?m+ve:m,C=w+x;if(s.includes(C))continue;s.push(C);const S=a(x,N);for(let M=0;M<S.length;++M){const L=S[M];s.push(w+L)}i=c+(i.length>0?" "+i:i)}return i};function Qe(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=we(t))&&(n&&(n+=" "),n+=r);return n}const we=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=we(e[n]))&&(r&&(r+=" "),r+=t);return r};function Ye(e,...t){let r,n,a,s=l;function l(d){const c=t.reduce((p,b)=>b(p),e());return r=Xe(c),n=r.cache.get,a=r.cache.set,s=i,i(d)}function i(d){const c=n(d);if(c)return c;const p=De(d,r);return a(d,p),p}return function(){return s(Qe.apply(null,arguments))}}const h=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},je=/^\[(?:([a-z-]+):)?(.+)\]$/i,et=/^\d+\/\d+$/,tt=new Set(["px","full","screen"]),rt=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,nt=/\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$/,ot=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,st=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,at=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,O=e=>P(e)||tt.has(e)||et.test(e),V=e=>W(e,"length",bt),P=e=>!!e&&!Number.isNaN(Number(e)),ee=e=>W(e,"number",P),$=e=>!!e&&Number.isInteger(Number(e)),it=e=>e.endsWith("%")&&P(e.slice(0,-1)),u=e=>je.test(e),E=e=>rt.test(e),lt=new Set(["length","size","percentage"]),ct=e=>W(e,lt,ke),dt=e=>W(e,"position",ke),ut=new Set(["image","url"]),pt=e=>W(e,ut,gt),ft=e=>W(e,"",mt),H=()=>!0,W=(e,t,r)=>{const n=je.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1},bt=e=>nt.test(e)&&!ot.test(e),ke=()=>!1,mt=e=>st.test(e),gt=e=>at.test(e),xt=()=>{const e=h("colors"),t=h("spacing"),r=h("blur"),n=h("brightness"),a=h("borderColor"),s=h("borderRadius"),l=h("borderSpacing"),i=h("borderWidth"),d=h("contrast"),c=h("grayscale"),p=h("hueRotate"),b=h("invert"),f=h("gap"),z=h("gradientColorStops"),N=h("gradientColorStopPositions"),x=h("inset"),m=h("margin"),w=h("opacity"),C=h("padding"),S=h("saturate"),M=h("scale"),L=h("sepia"),U=h("skew"),j=h("space"),_=h("translate"),R=()=>["auto","contain","none"],I=()=>["auto","hidden","clip","visible","scroll"],G=()=>["auto",u,t],v=()=>[u,t],ae=()=>["",O,V],q=()=>["auto",P,u],ie=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],K=()=>["solid","dashed","dotted","double","none"],le=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Y=()=>["start","end","center","between","around","evenly","stretch"],B=()=>["","0",u],ce=()=>["auto","avoid","all","avoid-page","page","left","right","column"],A=()=>[P,u];return{cacheSize:500,separator:":",theme:{colors:[H],spacing:[O,V],blur:["none","",E,u],brightness:A(),borderColor:[e],borderRadius:["none","","full",E,u],borderSpacing:v(),borderWidth:ae(),contrast:A(),grayscale:B(),hueRotate:A(),invert:B(),gap:v(),gradientColorStops:[e],gradientColorStopPositions:[it,V],inset:G(),margin:G(),opacity:A(),padding:v(),saturate:A(),scale:A(),sepia:B(),skew:A(),space:v(),translate:v()},classGroups:{aspect:[{aspect:["auto","square","video",u]}],container:["container"],columns:[{columns:[E]}],"break-after":[{"break-after":ce()}],"break-before":[{"break-before":ce()}],"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:[...ie(),u]}],overflow:[{overflow:I()}],"overflow-x":[{"overflow-x":I()}],"overflow-y":[{"overflow-y":I()}],overscroll:[{overscroll:R()}],"overscroll-x":[{"overscroll-x":R()}],"overscroll-y":[{"overscroll-y":R()}],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",$,u]}],basis:[{basis:G()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",u]}],grow:[{grow:B()}],shrink:[{shrink:B()}],order:[{order:["first","last","none",$,u]}],"grid-cols":[{"grid-cols":[H]}],"col-start-end":[{col:["auto",{span:["full",$,u]},u]}],"col-start":[{"col-start":q()}],"col-end":[{"col-end":q()}],"grid-rows":[{"grid-rows":[H]}],"row-start-end":[{row:["auto",{span:[$,u]},u]}],"row-start":[{"row-start":q()}],"row-end":[{"row-end":q()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",u]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",u]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:["normal",...Y()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Y(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Y(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[C]}],px:[{px:[C]}],py:[{py:[C]}],ps:[{ps:[C]}],pe:[{pe:[C]}],pt:[{pt:[C]}],pr:[{pr:[C]}],pb:[{pb:[C]}],pl:[{pl:[C]}],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":[j]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[j]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",u,t]}],"min-w":[{"min-w":[u,t,"min","max","fit"]}],"max-w":[{"max-w":[u,t,"none","full","min","max","fit","prose",{screen:[E]},E]}],h:[{h:[u,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[u,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[u,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[u,t,"auto","min","max","fit"]}],"font-size":[{text:["base",E,V]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",ee]}],"font-family":[{font:[H]}],"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",u]}],"line-clamp":[{"line-clamp":["none",P,ee]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",O,u]}],"list-image":[{"list-image":["none",u]}],"list-style-type":[{list:["none","disc","decimal",u]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[w]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[w]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...K(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",O,V]}],"underline-offset":[{"underline-offset":["auto",O,u]}],"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:v()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",u]}],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",u]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[w]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ie(),dt]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",ct]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},pt]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[N]}],"gradient-via-pos":[{via:[N]}],"gradient-to-pos":[{to:[N]}],"gradient-from":[{from:[z]}],"gradient-via":[{via:[z]}],"gradient-to":[{to:[z]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[i]}],"border-w-x":[{"border-x":[i]}],"border-w-y":[{"border-y":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[w]}],"border-style":[{border:[...K(),"hidden"]}],"divide-x":[{"divide-x":[i]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[i]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[w]}],"divide-style":[{divide:K()}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-s":[{"border-s":[a]}],"border-color-e":[{"border-e":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["",...K()]}],"outline-offset":[{"outline-offset":[O,u]}],"outline-w":[{outline:[O,V]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:ae()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[w]}],"ring-offset-w":[{"ring-offset":[O,V]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",E,ft]}],"shadow-color":[{shadow:[H]}],opacity:[{opacity:[w]}],"mix-blend":[{"mix-blend":[...le(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":le()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",E,u]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[b]}],saturate:[{saturate:[S]}],sepia:[{sepia:[L]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[b]}],"backdrop-opacity":[{"backdrop-opacity":[w]}],"backdrop-saturate":[{"backdrop-saturate":[S]}],"backdrop-sepia":[{"backdrop-sepia":[L]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[l]}],"border-spacing-x":[{"border-spacing-x":[l]}],"border-spacing-y":[{"border-spacing-y":[l]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",u]}],duration:[{duration:A()}],ease:[{ease:["linear","in","out","in-out",u]}],delay:[{delay:A()}],animate:[{animate:["none","spin","ping","pulse","bounce",u]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[M]}],"scale-x":[{"scale-x":[M]}],"scale-y":[{"scale-y":[M]}],rotate:[{rotate:[$,u]}],"translate-x":[{"translate-x":[_]}],"translate-y":[{"translate-y":[_]}],"skew-x":[{"skew-x":[U]}],"skew-y":[{"skew-y":[U]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",u]}],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",u]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":v()}],"scroll-mx":[{"scroll-mx":v()}],"scroll-my":[{"scroll-my":v()}],"scroll-ms":[{"scroll-ms":v()}],"scroll-me":[{"scroll-me":v()}],"scroll-mt":[{"scroll-mt":v()}],"scroll-mr":[{"scroll-mr":v()}],"scroll-mb":[{"scroll-mb":v()}],"scroll-ml":[{"scroll-ml":v()}],"scroll-p":[{"scroll-p":v()}],"scroll-px":[{"scroll-px":v()}],"scroll-py":[{"scroll-py":v()}],"scroll-ps":[{"scroll-ps":v()}],"scroll-pe":[{"scroll-pe":v()}],"scroll-pt":[{"scroll-pt":v()}],"scroll-pr":[{"scroll-pr":v()}],"scroll-pb":[{"scroll-pb":v()}],"scroll-pl":[{"scroll-pl":v()}],"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",u]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[O,V,ee]}],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"]}}},ht=Ye(xt);function g(...e){return ht(he(e))}const Ne=T("font-sans text-gray-900",{variants:{variant:{h1:"text-3xl leading-tight font-bold",h2:"text-2xl leading-tight font-bold",h3:"text-xl leading-snug font-semibold",h4:"text-lg leading-snug font-semibold",h5:"text-base leading-snug font-medium",h6:"text-sm leading-snug font-medium",body:"text-sm leading-relaxed font-normal",bodySm:"text-xs leading-relaxed font-normal",caption:"text-[11px] leading-normal font-normal"},weight:{regular:"font-normal",medium:"font-medium",semibold:"font-semibold",bold:"font-bold"}},defaultVariants:{variant:"body"}}),yt={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",body:"p",bodySm:"p",caption:"span"},k=y.forwardRef(({className:e,variant:t="body",weight:r,as:n,children:a,...s},l)=>{const i=n??yt[t??"body"];return y.createElement(i,{ref:l,className:g(Ne({variant:t,weight:r}),e),...s},a)});k.displayName="Text";const Ce=T("inline-flex items-center justify-center gap-2 rounded-lg transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-agilys-primary disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{primary:"bg-agilys-primary text-white shadow-[0px_2px_6px_0px_rgba(71,71,245,0.16),inset_0px_0px_10px_0px_rgba(255,255,255,0.3)] hover:bg-agilys-primary/90",secondary:"bg-white text-neutral-secondary shadow-[0px_0px_2px_0px_rgba(66,74,98,0.04),0px_3px_8px_0px_rgba(66,74,98,0.09)] hover:bg-gray-50",destructive:"bg-danger-light text-danger-dark shadow-[0px_2px_6px_0px_rgba(243,22,22,0.16)] hover:bg-danger-light/80"},size:{sm:"h-9 px-3",md:"h-10 px-4",lg:"h-11 px-6",icon:"size-10 p-0 shrink-0"},fullWidth:{true:"w-full"}},defaultVariants:{variant:"primary",size:"md"}}),vt={sm:"bodySm",md:"body",lg:"body",icon:"body"},ze=y.forwardRef(({className:e,variant:t,size:r,fullWidth:n,isLoading:a=!1,leftIcon:s,disabled:l,children:i,...d},c)=>{const p=r==="icon",b=vt[r??"md"];return o.jsxs("button",{ref:c,className:g(Ce({variant:t,size:r,fullWidth:n}),e),disabled:l||a,"aria-busy":a,...d,children:[a&&o.jsxs("svg",{className:"size-[18px] animate-spin",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),o.jsx("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8v4a4 4 0 00-4 4H4z"})]}),!a&&s&&o.jsx("span",{className:"inline-flex shrink-0","aria-hidden":"true",children:s}),p?o.jsx("span",{className:"inline-flex shrink-0",children:i}):o.jsx(k,{as:"span",variant:b,className:"text-inherit",children:i})]})});ze.displayName="Button";const _e=T("inline-flex items-center justify-center h-6 whitespace-nowrap",{variants:{variant:{filled:"rounded-lg px-3",dot:"rounded bg-white gap-1.5 px-2"},status:{default:"",success:"",alert:"",error:""}},compoundVariants:[{variant:"filled",status:"default",class:"bg-agilys-primary text-white"},{variant:"filled",status:"success",class:"bg-success-10 text-success-60"},{variant:"filled",status:"alert",class:"bg-warning-light text-warning-accent"},{variant:"filled",status:"error",class:"bg-danger-10 text-danger-60"},{variant:"dot",status:"default",class:"text-agilys-primary"},{variant:"dot",status:"success",class:"text-success-60"},{variant:"dot",status:"alert",class:"text-warning-dark"},{variant:"dot",status:"error",class:"text-danger-60"}],defaultVariants:{variant:"filled",status:"default"}}),wt={default:"bg-agilys-primary",success:"bg-success-60",alert:"bg-warning-accent",error:"bg-danger-60"},Se=y.forwardRef(({className:e,variant:t="filled",status:r="default",children:n,...a},s)=>o.jsxs("span",{ref:s,className:g(_e({variant:t,status:r}),e),...a,children:[t==="dot"&&o.jsx("span",{className:g("size-2 shrink-0 rounded-full",wt[r??"default"]),"aria-hidden":"true"}),o.jsx(k,{as:"span",variant:"body",className:"text-inherit",children:n})]}));Se.displayName="Badge";const Me=T("flex items-start gap-2 rounded-lg p-5 font-sans",{variants:{variant:{default:"border border-neutral-divider-secondary bg-white shadow-[0px_0px_1px_0px_rgba(66,74,98,0.09),0px_2px_2px_0px_rgba(66,74,98,0.04)]",success:"border border-transparent bg-success-10",warning:"border border-transparent bg-warning-light",error:"border border-transparent bg-danger-10",info:"border border-transparent bg-primary-50"}},defaultVariants:{variant:"default"}}),jt={default:"text-neutral-text-primary",success:"text-success-60",warning:"text-warning-dark",error:"text-danger-dark",info:"text-primary-700"};function kt(){return o.jsxs("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("circle",{cx:"12",cy:"12",r:"9",stroke:"currentColor",strokeWidth:"2"}),o.jsx("path",{d:"M12 11v5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"}),o.jsx("circle",{cx:"12",cy:"8",r:"1",fill:"currentColor"})]})}function Nt(){return o.jsxs("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("circle",{cx:"12",cy:"12",r:"9",stroke:"currentColor",strokeWidth:"2"}),o.jsx("path",{d:"M8.5 12.5l2.5 2.5 4.5-5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})}function Ct(){return o.jsxs("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("path",{d:"M12 3.5L21 20H3L12 3.5z",stroke:"currentColor",strokeWidth:"2",strokeLinejoin:"round"}),o.jsx("path",{d:"M12 10v4",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"}),o.jsx("circle",{cx:"12",cy:"17",r:"1",fill:"currentColor"})]})}function zt(){return o.jsxs("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[o.jsx("circle",{cx:"12",cy:"12",r:"9",stroke:"currentColor",strokeWidth:"2"}),o.jsx("path",{d:"M9.5 9.5l5 5m0-5l-5 5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})]})}function _t(){return o.jsx("svg",{className:"size-full",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:"M18 6L6 18M6 6l12 12",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})})}const St={success:o.jsx(Nt,{}),warning:o.jsx(Ct,{}),error:o.jsx(zt,{}),info:o.jsx(kt,{})},oe=y.forwardRef(({className:e,variant:t="default",icon:r,title:n,description:a,action:s,onClose:l,children:i,...d},c)=>{const p=t??"default",b=r===void 0?St[p]:r,f=jt[p];return o.jsxs("div",{ref:c,className:g(Me({variant:t}),e),...d,children:[b&&o.jsx("span",{className:g("size-6 shrink-0",f),"aria-hidden":"true",children:b}),o.jsxs("div",{className:"flex min-w-0 flex-1 flex-col gap-1",children:[n&&o.jsx(k,{as:"div",variant:"body",weight:"semibold",className:f,children:n}),a&&o.jsx(k,{as:"div",variant:"bodySm",className:"text-neutral-text-secondary",children:a}),i]}),s&&o.jsx("div",{className:"flex shrink-0 items-center",children:s}),l&&o.jsx("button",{type:"button",onClick:l,"aria-label":"Fechar",className:g("flex size-5 shrink-0 items-center justify-center rounded-md transition-colors hover:opacity-70 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",f),children:o.jsx(_t,{})})]})});oe.displayName="Card";var Ie={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},be=y.createContext&&y.createContext(Ie),Mt=["attr","size","title"];function It(e,t){if(e==null)return{};var r,n,a=At(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(n=0;n<s.length;n++)r=s[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(a[r]=e[r])}return a}function At(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function X(){return X=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},X.apply(null,arguments)}function me(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function Z(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?me(Object(r),!0).forEach(function(n){Ot(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):me(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Ot(e,t,r){return(t=Vt(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Vt(e){var t=Et(e,"string");return typeof t=="symbol"?t:t+""}function Et(e,t){if(typeof e!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ae(e){return e&&e.map((t,r)=>y.createElement(t.tag,Z({key:r},t.attr),Ae(t.child)))}function Oe(e){return t=>y.createElement(Rt,X({attr:Z({},e.attr)},t),Ae(e.child))}function Rt(e){var t=r=>{var n=e.attr,a=e.size,s=e.title,l=It(e,Mt),i=a||r.size||"1em",d;return r.className&&(d=r.className),e.className&&(d=(d?d+" ":"")+e.className),y.createElement("svg",X({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},r.attr,n,l,{className:d,style:Z(Z({color:e.color||r.color},r.style),e.style),height:i,width:i,xmlns:"http://www.w3.org/2000/svg"}),s&&y.createElement("title",null,s),e.children)};return be!==void 0?y.createElement(be.Consumer,null,r=>t(r)):t(Ie)}function Lt(e){return Oe({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M80 152v256a40.12 40.12 0 0 0 40 40h272a40.12 40.12 0 0 0 40-40V152"},child:[]},{tag:"rect",attr:{width:"416",height:"80",x:"48",y:"64",fill:"none",strokeLinejoin:"round",strokeWidth:"32",rx:"28",ry:"28"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"m320 304-64 64-64-64m64 41.89V224"},child:[]}]})(e)}function Pt(e){return Oe({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"},child:[]},{tag:"path",attr:{d:"M16 9v10H8V9zm-1.5-6h-5l-1 1H5v2h14V4h-3.5zM18 7H6v12c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2z"},child:[]}]})(e)}const Ve=y.forwardRef(({className:e,title:t,body:r,timestamp:n,read:a=!1,onArchive:s,onDelete:l,...i},d)=>o.jsxs(oe,{ref:d,icon:null,className:g(!a&&"border-transparent bg-lightGray",e),...i,children:[o.jsxs("div",{className:"flex items-start justify-between gap-3",children:[o.jsxs("div",{className:"flex min-w-0 items-center gap-2",children:[!a&&o.jsx("span",{className:"size-2 shrink-0 rounded-full bg-danger-60","aria-label":"Não visualizada"}),o.jsx(k,{as:"div",variant:"body",weight:"semibold",className:"truncate text-neutral-text-primary",children:t})]}),o.jsx(k,{as:"span",variant:"caption",className:"shrink-0 text-neutral-text-secondary",children:n})]}),o.jsx(k,{as:"div",variant:"bodySm",className:"text-neutral-text-secondary",children:r}),o.jsxs("div",{className:"flex items-center justify-end gap-1 pt-1",children:[o.jsx("button",{type:"button",onClick:s,"aria-label":"Arquivar",className:"flex size-7 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:bg-neutral-surface-selected hover:text-neutral-text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",children:o.jsx(Lt,{className:"size-4","aria-hidden":"true"})}),o.jsx("button",{type:"button",onClick:l,"aria-label":"Excluir",className:"flex size-7 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:bg-danger-10 hover:text-danger-60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary",children:o.jsx(Pt,{className:"size-4","aria-hidden":"true"})})]})]}));Ve.displayName="NotificationCard";function Tt(e,t){return t.split(".").reduce((r,n)=>r==null?void 0:r[n],e)}function Wt(e,t){if(t.callback)return t.callback(e);if(!t.key)return null;const r=Tt(e,t.key);return r==null||r===""?null:o.jsx(k,{as:"span",variant:"body",className:"truncate text-neutral-text-primary",children:r})}const Ee={left:"text-left justify-start",center:"text-center justify-center",right:"text-right justify-end"},D=y.forwardRef(({className:e,...t},r)=>o.jsxs("span",{className:"relative inline-flex size-5 shrink-0 items-center justify-center",children:[o.jsx("input",{ref:r,type:"checkbox",className:g("peer size-5 shrink-0 cursor-pointer appearance-none rounded border-2 border-neutral-divider-primary bg-white shadow-[0px_0px_2px_0px_rgba(66,74,98,0.09)] checked:border-agilys-primary checked:bg-agilys-primary disabled:cursor-not-allowed disabled:opacity-50",e),...t}),o.jsx("svg",{className:"pointer-events-none absolute size-3 text-white opacity-0 peer-checked:opacity-100",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:"M5 13l4 4L19 7",stroke:"currentColor",strokeWidth:"3",strokeLinecap:"round",strokeLinejoin:"round"})})]}));D.displayName="TableCheckbox";function Gt({className:e}){return o.jsx("svg",{className:g("size-5 shrink-0",e),viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:"M8 9l4-4 4 4M8 15l4 4 4-4",stroke:"currentColor",strokeWidth:"1.7",strokeLinecap:"round",strokeLinejoin:"round"})})}const Q=y.forwardRef(({className:e,align:t="left",sortable:r,sorted:n,onSort:a,children:s,...l},i)=>o.jsx("th",{ref:i,className:g("border-b border-neutral-divider-secondary px-5 py-2",e),...l,children:o.jsxs("span",{className:g("flex items-center gap-1.5",Ee[t??"left"],r&&"cursor-pointer select-none"),onClick:r?a:void 0,children:[o.jsx(k,{as:"span",variant:"bodySm",weight:"medium",className:"flex-1 truncate text-neutral-text-secondary",children:s}),r&&o.jsx(Gt,{className:g(n&&"text-agilys-primary")})]})}));Q.displayName="TableHeadCell";function re({align:e="left",className:t,children:r,onClick:n}){return o.jsx("td",{onClick:n,className:g("border-b border-neutral-divider-secondary px-5 py-3",t),children:o.jsx(k,{className:g("flex items-center gap-2",Ee[e??"left"]),children:r})})}function Bt(e,t,r){if(typeof r=="function")return r(e);const n=e;return r?n[r]??t:n.id??t}function $t({keys:e,data:t,rowKey:r,loading:n,loadingMessage:a="Carregando dados...",emptyMessage:s="Nenhum dado para ser exibido!",selectable:l,selectedRowKeys:i,onSelectionChange:d,sortKey:c,sortDirection:p,onSortChange:b,onRowClick:f,shadow:z=!1,border:N=!0,className:x,...m}){const w=e.length+(l?1:0),C=i??[],S=t.map((j,_)=>Bt(j,_,r)),M=S.length>0&&S.every(j=>C.includes(j)),L=()=>{d&&d(M?[]:S)},U=j=>{d&&d(C.includes(j)?C.filter(_=>_!==j):[...C,j])};return o.jsx("div",{className:g("w-full overflow-x-auto rounded-lg",N&&"border border-neutral-divider-secondary",z&&"shadow-[0px_0px_2px_0px_rgba(66,74,98,0.04),0px_3px_8px_0px_rgba(66,74,98,0.09)]"),children:o.jsxs("table",{className:g("w-full border-collapse font-sans",x),...m,children:[o.jsx("thead",{children:o.jsxs("tr",{children:[l&&o.jsx(Q,{align:"center",className:"w-11",children:o.jsx(D,{checked:M,onChange:L,"aria-label":"Selecionar todas as linhas"})}),e.map((j,_)=>o.jsx(Q,{align:j.align,sortable:!!j.key&&!!b,sorted:j.key&&c===j.key?p:!1,onSort:()=>j.key&&(b==null?void 0:b(j.key)),children:j.label},j.key??`column-${_}`))]})}),o.jsx("tbody",{children:n?o.jsx("tr",{children:o.jsx("td",{colSpan:w,className:"border-b border-neutral-divider-secondary bg-neutral-surface-lightest px-5 py-6",children:o.jsx(k,{as:"p",variant:"body",className:"w-full text-center text-neutral-text-secondary",children:a})})}):t.length===0?o.jsx("tr",{children:o.jsx("td",{colSpan:w,className:"border-b border-neutral-divider-secondary bg-neutral-surface-lightest px-5 py-6",children:o.jsx(k,{as:"p",variant:"body",className:"w-full text-center text-neutral-text-secondary",children:s})})}):t.map((j,_)=>{const R=S[_];return o.jsxs("tr",{onClick:f?()=>f(j):void 0,className:g(_%2===0?"bg-neutral-surface-lightest":"bg-white",f&&"cursor-pointer"),children:[l&&o.jsx(re,{align:"center",onClick:I=>I.stopPropagation(),children:o.jsx(D,{checked:C.includes(R),onChange:()=>U(R),"aria-label":"Selecionar linha"})}),e.map((I,G)=>o.jsx(re,{align:I.align,className:I.className,children:Wt(j,I)},I.key??`column-${G}`))]},R)})})]})})}const Re=T("relative inline-flex shrink-0 items-center justify-center overflow-hidden rounded-full bg-neutral-surface-lightest font-sans font-medium text-neutral-text-secondary",{variants:{size:{sm:"size-6 text-xs",md:"size-7 text-sm",lg:"size-10 text-base"}},defaultVariants:{size:"md"}});function Ht(e){var n;const t=e.trim().split(/\s+/),r=t.length>1?`${t[0][0]}${t[t.length-1][0]}`:(n=t[0])==null?void 0:n.slice(0,2);return r==null?void 0:r.toUpperCase()}const Ft={sm:"caption",md:"bodySm",lg:"body"},se=y.forwardRef(({className:e,size:t,src:r,alt:n="",name:a,...s},l)=>{const i=t??"md";return o.jsx("span",{ref:l,className:g(Re({size:t}),e),...s,children:r?o.jsx("img",{src:r,alt:n,className:"size-full object-cover"}):a&&o.jsx(k,{as:"span",variant:Ft[i],weight:"medium",className:"text-inherit leading-none",children:Ht(a)})})});se.displayName="Avatar";function Ut({src:e,name:t,description:r,size:n="md",className:a}){return o.jsxs("div",{className:g("flex min-w-0 items-center gap-2",a),children:[o.jsx(se,{src:e,name:t,size:n}),o.jsxs("div",{className:"flex min-w-0 flex-col",children:[o.jsx(k,{as:"span",variant:"body",className:"truncate",children:t}),r&&o.jsx(k,{as:"span",variant:"bodySm",className:"truncate text-neutral-text-secondary",children:r})]})]})}const F="ellipsis";function J(e,t){return Array.from({length:t-e+1},(r,n)=>e+n)}function qt(e,t,r){if(r*2+5>=t)return J(1,t);const a=Math.max(e-r,1),s=Math.min(e+r,t),l=a>2,i=s<t-1;return!l&&i?[...J(1,3+r*2),F,t]:l&&!i?[1,F,...J(t-(2+r*2),t)]:[1,F,...J(a,s),F,t]}function ge({direction:e,className:t}){return o.jsx("svg",{className:g("size-4",t),viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:e==="left"?"M15 6l-6 6 6 6":"M9 6l6 6-6 6",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})})}const Le=y.forwardRef(({currentPage:e,totalPages:t,onPageChange:r,siblingCount:n=1,className:a,...s},l)=>{if(t<=1)return null;const i=qt(e,t,n),d=c=>{c<1||c>t||c===e||r(c)};return o.jsxs("nav",{ref:l,"aria-label":"Paginação",className:g("flex items-center gap-1 font-sans",a),...s,children:[o.jsx("button",{type:"button","aria-label":"Página anterior",disabled:e===1,onClick:()=>d(e-1),className:"inline-flex size-9 shrink-0 items-center justify-center rounded-lg text-neutral-text-secondary transition-colors hover:bg-neutral-surface-lightest disabled:pointer-events-none disabled:opacity-40",children:o.jsx(ge,{direction:"left"})}),i.map((c,p)=>c===F?o.jsx("span",{className:"inline-flex size-9 shrink-0 items-center justify-center text-neutral-text-secondary",children:o.jsx(k,{as:"span",variant:"bodySm",className:"text-inherit",children:"…"})},`ellipsis-${p}`):o.jsx("button",{type:"button","aria-current":c===e?"page":void 0,onClick:()=>d(c),className:g("inline-flex size-9 shrink-0 items-center justify-center rounded-lg transition-colors",c===e?"bg-neutral-surface-selected text-agilys-primary":"text-neutral-text-secondary hover:bg-neutral-surface-lightest"),children:o.jsx(k,{as:"span",variant:"bodySm",weight:"medium",className:"text-inherit",children:c})},c)),o.jsx("button",{type:"button","aria-label":"Próxima página",disabled:e===t,onClick:()=>d(e+1),className:"inline-flex size-9 shrink-0 items-center justify-center rounded-lg text-neutral-text-secondary transition-colors hover:bg-neutral-surface-lightest disabled:pointer-events-none disabled:opacity-40",children:o.jsx(ge,{direction:"right"})})]})});Le.displayName="Pagination";const Pe=T("flex h-11 w-full min-w-0 items-center gap-2 rounded-lg bg-white px-3 shadow-[0px_1px_2px_0px_rgba(0,0,0,0.25)] transition-shadow focus-within:ring-2 focus-within:ring-agilys-primary",{variants:{hasError:{true:"ring-2 ring-danger-60 focus-within:ring-danger-60",false:""}},defaultVariants:{hasError:!1}}),Te=y.forwardRef(({className:e,containerClassName:t,label:r,leftIcon:n,rightIcon:a,bgIcon:s=!1,error:l,disabled:i,id:d,...c},p)=>{const b=y.useId(),f=d??b,z=typeof l=="string"?l:l==null?void 0:l.message,N=!!z,x=`${f}-error`;return o.jsxs("div",{className:g("flex w-full min-w-0 flex-col gap-1.5",t),children:[r&&o.jsx(k,{as:"label",htmlFor:f,variant:"body",className:"text-neutral-text-primary",children:r}),o.jsxs("div",{className:g(Pe({hasError:N}),i&&"pointer-events-none opacity-50"),children:[n&&o.jsx("span",{className:"inline-flex shrink-0","aria-hidden":"true",children:n}),o.jsx("input",{ref:p,id:f,disabled:i,"aria-invalid":N||void 0,"aria-describedby":N?x:void 0,className:g("w-full min-w-0 flex-1 bg-transparent font-sans text-xs leading-relaxed font-normal text-black placeholder:font-sans placeholder:text-xs placeholder:leading-relaxed placeholder:font-normal placeholder:text-neutral-secondary/60 focus:outline-none disabled:cursor-not-allowed",e),...c}),a&&o.jsx("span",{className:g("flex size-6 shrink-0 items-center justify-center text-neutral-secondary",s&&"rounded-md bg-lightGray p-1"),"aria-hidden":"true",children:a})]}),N&&o.jsx(k,{as:"span",id:x,role:"alert",variant:"caption",className:"text-danger-60",children:z})]})});Te.displayName="Input";function Kt(){return o.jsx("svg",{className:"size-5",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:o.jsx("path",{d:"M18 6L6 18M6 6l12 12",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})})}const We=y.forwardRef(({open:e,onClose:t,title:r,children:n,footer:a,closeOnBackdropClick:s=!0,showCloseButton:l=!0,className:i,contentClassName:d,...c},p)=>{const b=y.useId(),f=y.useRef(null),[z,N]=y.useState(!1);return y.useEffect(()=>N(!0),[]),y.useEffect(()=>{var w;if(!e)return;const x=document.body.style.overflow;document.body.style.overflow="hidden",(w=f.current)==null||w.focus();const m=C=>{C.key==="Escape"&&t()};return document.addEventListener("keydown",m),()=>{document.body.style.overflow=x,document.removeEventListener("keydown",m)}},[e,t]),!e||!z?null:Ge.createPortal(o.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center overflow-y-auto bg-black/40 p-4",onClick:s?t:void 0,children:o.jsxs("div",{ref:p,role:"dialog","aria-modal":"true","aria-labelledby":r?b:void 0,onClick:x=>x.stopPropagation(),className:g("relative flex w-full min-w-0 max-w-lg flex-col gap-6 rounded-xl bg-[#fcfcfc] p-6 shadow-[0px_0px_2px_0px_rgba(34,34,34,0.08)] sm:p-8",i),...c,children:[l&&o.jsx("button",{ref:f,type:"button",onClick:t,"aria-label":"Fechar",className:"absolute right-4 top-4 flex size-6 shrink-0 items-center justify-center rounded-md text-neutral-text-secondary transition-colors hover:text-neutral-text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-agilys-primary sm:right-5 sm:top-5",children:o.jsx(Kt,{})}),r&&o.jsx("div",{className:"pr-8",children:o.jsx(k,{as:"h2",id:b,variant:"h4",weight:"medium",className:"text-neutral-text-primary",children:r})}),o.jsx("div",{className:g("max-h-[70vh] min-w-0 overflow-y-auto overflow-x-hidden font-sans text-sm leading-relaxed text-neutral-text-secondary sm:text-base",d),children:n}),a&&o.jsx("div",{className:"flex flex-wrap items-center gap-2.5 pt-1",children:a})]})}),document.body)});We.displayName="Modal";exports.Avatar=se;exports.AvatarColumn=Ut;exports.Badge=Se;exports.Button=ze;exports.Card=oe;exports.Input=Te;exports.Modal=We;exports.NotificationCard=Ve;exports.Pagination=Le;exports.Table=$t;exports.TableCell=re;exports.TableCheckbox=D;exports.TableHeadCell=Q;exports.Text=k;exports.avatarVariants=Re;exports.badgeVariants=_e;exports.buttonVariants=Ce;exports.cardVariants=Me;exports.cn=g;exports.inputVariants=Pe;exports.textVariants=Ne;
|
|
2
2
|
//# sourceMappingURL=agilys-design-system.cjs.map
|