@arkyn/components 1.3.58 → 1.3.60

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,4 +1,4 @@
1
- (function(k,l){typeof exports=="object"&&typeof module<"u"?l(exports,require("react"),require("lucide-react"),require("@remix-run/react"),require("@react-input/mask"),require("framer-motion"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","lucide-react","@remix-run/react","@react-input/mask","framer-motion","react-dom"],l):(k=typeof globalThis<"u"?globalThis:k||self,l(k["@arkyn/components"]={},k.e,k.lucideReact,k.react,k.mask,k.framerMotion,k.Gt))})(this,function(k,l,G,Se,Rt,_e,$t){"use strict";var qe={exports:{}},Ie={};/**
1
+ (function(C,l){typeof exports=="object"&&typeof module<"u"?l(exports,require("react"),require("lucide-react"),require("@remix-run/react"),require("@react-input/mask"),require("framer-motion"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","lucide-react","@remix-run/react","@react-input/mask","framer-motion","react-dom"],l):(C=typeof globalThis<"u"?globalThis:C||self,l(C["@arkyn/components"]={},C.e,C.lucideReact,C.react,C.mask,C.framerMotion,C.Gt))})(this,function(C,l,G,Ee,$t,_e,Rt){"use strict";var qe={exports:{}},Ie={};/**
2
2
  * @license React
3
3
  * react-jsx-runtime.production.min.js
4
4
  *
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
- */var it;function Pt(){if(it)return Ie;it=1;var e=l,n=Symbol.for("react.element"),r=Symbol.for("react.fragment"),o=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,u={key:!0,ref:!0,__self:!0,__source:!0};function h(c,d,p){var m,y={},s=null,v=null;p!==void 0&&(s=""+p),d.key!==void 0&&(s=""+d.key),d.ref!==void 0&&(v=d.ref);for(m in d)o.call(d,m)&&!u.hasOwnProperty(m)&&(y[m]=d[m]);if(c&&c.defaultProps)for(m in d=c.defaultProps,d)y[m]===void 0&&(y[m]=d[m]);return{$$typeof:n,type:c,key:s,ref:v,props:y,_owner:i.current}}return Ie.Fragment=r,Ie.jsx=h,Ie.jsxs=h,Ie}var Oe={};/**
9
+ */var it;function Pt(){if(it)return Ie;it=1;var e=l,n=Symbol.for("react.element"),r=Symbol.for("react.fragment"),o=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,c={key:!0,ref:!0,__self:!0,__source:!0};function h(u,d,p){var m,b={},a=null,v=null;p!==void 0&&(a=""+p),d.key!==void 0&&(a=""+d.key),d.ref!==void 0&&(v=d.ref);for(m in d)o.call(d,m)&&!c.hasOwnProperty(m)&&(b[m]=d[m]);if(u&&u.defaultProps)for(m in d=u.defaultProps,d)b[m]===void 0&&(b[m]=d[m]);return{$$typeof:n,type:u,key:a,ref:v,props:b,_owner:i.current}}return Ie.Fragment=r,Ie.jsx=h,Ie.jsxs=h,Ie}var Oe={};/**
10
10
  * @license React
11
11
  * react-jsx-runtime.development.js
12
12
  *
@@ -14,20 +14,20 @@
14
14
  *
15
15
  * This source code is licensed under the MIT license found in the
16
16
  * LICENSE file in the root directory of this source tree.
17
- */var lt;function Tt(){return lt||(lt=1,process.env.NODE_ENV!=="production"&&function(){var e=l,n=Symbol.for("react.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),u=Symbol.for("react.profiler"),h=Symbol.for("react.provider"),c=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),p=Symbol.for("react.suspense"),m=Symbol.for("react.suspense_list"),y=Symbol.for("react.memo"),s=Symbol.for("react.lazy"),v=Symbol.for("react.offscreen"),R=Symbol.iterator,w="@@iterator";function N(t){if(t===null||typeof t!="object")return null;var f=R&&t[R]||t[w];return typeof f=="function"?f:null}var b=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function x(t){{for(var f=arguments.length,g=new Array(f>1?f-1:0),C=1;C<f;C++)g[C-1]=arguments[C];Y("error",t,g)}}function Y(t,f,g){{var C=b.ReactDebugCurrentFrame,L=C.getStackAddendum();L!==""&&(f+="%s",g=g.concat([L]));var V=g.map(function(O){return String(O)});V.unshift("Warning: "+f),Function.prototype.apply.call(console[t],console,V)}}var D=!1,$=!1,W=!1,B=!1,q=!1,K;K=Symbol.for("react.module.reference");function X(t){return!!(typeof t=="string"||typeof t=="function"||t===o||t===u||q||t===i||t===p||t===m||B||t===v||D||$||W||typeof t=="object"&&t!==null&&(t.$$typeof===s||t.$$typeof===y||t.$$typeof===h||t.$$typeof===c||t.$$typeof===d||t.$$typeof===K||t.getModuleId!==void 0))}function z(t,f,g){var C=t.displayName;if(C)return C;var L=f.displayName||f.name||"";return L!==""?g+"("+L+")":g}function Q(t){return t.displayName||"Context"}function E(t){if(t==null)return null;if(typeof t.tag=="number"&&x("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case o:return"Fragment";case r:return"Portal";case u:return"Profiler";case i:return"StrictMode";case p:return"Suspense";case m:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case c:var f=t;return Q(f)+".Consumer";case h:var g=t;return Q(g._context)+".Provider";case d:return z(t,t.render,"ForwardRef");case y:var C=t.displayName||null;return C!==null?C:E(t.type)||"Memo";case s:{var L=t,V=L._payload,O=L._init;try{return E(O(V))}catch{return null}}}return null}var J=Object.assign,F=0,H,re,P,ee,me,I,j;function S(){}S.__reactDisabledLog=!0;function ae(){{if(F===0){H=console.log,re=console.info,P=console.warn,ee=console.error,me=console.group,I=console.groupCollapsed,j=console.groupEnd;var t={configurable:!0,enumerable:!0,value:S,writable:!0};Object.defineProperties(console,{info:t,log:t,warn:t,error:t,group:t,groupCollapsed:t,groupEnd:t})}F++}}function te(){{if(F--,F===0){var t={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:J({},t,{value:H}),info:J({},t,{value:re}),warn:J({},t,{value:P}),error:J({},t,{value:ee}),group:J({},t,{value:me}),groupCollapsed:J({},t,{value:I}),groupEnd:J({},t,{value:j})})}F<0&&x("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var U=b.ReactCurrentDispatcher,se;function le(t,f,g){{if(se===void 0)try{throw Error()}catch(L){var C=L.stack.trim().match(/\n( *(at )?)/);se=C&&C[1]||""}return`
18
- `+se+t}}var he=!1,be;{var et=typeof WeakMap=="function"?WeakMap:Map;be=new et}function Re(t,f){if(!t||he)return"";{var g=be.get(t);if(g!==void 0)return g}var C;he=!0;var L=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var V;V=U.current,U.current=null,ae();try{if(f){var O=function(){throw Error()};if(Object.defineProperty(O.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(O,[])}catch(de){C=de}Reflect.construct(t,[],O)}else{try{O.call()}catch(de){C=de}t.call(O.prototype)}}else{try{throw Error()}catch(de){C=de}t()}}catch(de){if(de&&C&&typeof de.stack=="string"){for(var T=de.stack.split(`
19
- `),ce=C.stack.split(`
17
+ */var lt;function Tt(){return lt||(lt=1,process.env.NODE_ENV!=="production"&&function(){var e=l,n=Symbol.for("react.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),c=Symbol.for("react.profiler"),h=Symbol.for("react.provider"),u=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),p=Symbol.for("react.suspense"),m=Symbol.for("react.suspense_list"),b=Symbol.for("react.memo"),a=Symbol.for("react.lazy"),v=Symbol.for("react.offscreen"),S=Symbol.iterator,x="@@iterator";function N(t){if(t===null||typeof t!="object")return null;var f=S&&t[S]||t[x];return typeof f=="function"?f:null}var y=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function w(t){{for(var f=arguments.length,g=new Array(f>1?f-1:0),k=1;k<f;k++)g[k-1]=arguments[k];Y("error",t,g)}}function Y(t,f,g){{var k=y.ReactDebugCurrentFrame,L=k.getStackAddendum();L!==""&&(f+="%s",g=g.concat([L]));var V=g.map(function(O){return String(O)});V.unshift("Warning: "+f),Function.prototype.apply.call(console[t],console,V)}}var D=!1,R=!1,W=!1,B=!1,q=!1,K;K=Symbol.for("react.module.reference");function X(t){return!!(typeof t=="string"||typeof t=="function"||t===o||t===c||q||t===i||t===p||t===m||B||t===v||D||R||W||typeof t=="object"&&t!==null&&(t.$$typeof===a||t.$$typeof===b||t.$$typeof===h||t.$$typeof===u||t.$$typeof===d||t.$$typeof===K||t.getModuleId!==void 0))}function z(t,f,g){var k=t.displayName;if(k)return k;var L=f.displayName||f.name||"";return L!==""?g+"("+L+")":g}function Q(t){return t.displayName||"Context"}function E(t){if(t==null)return null;if(typeof t.tag=="number"&&w("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case o:return"Fragment";case r:return"Portal";case c:return"Profiler";case i:return"StrictMode";case p:return"Suspense";case m:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case u:var f=t;return Q(f)+".Consumer";case h:var g=t;return Q(g._context)+".Provider";case d:return z(t,t.render,"ForwardRef");case b:var k=t.displayName||null;return k!==null?k:E(t.type)||"Memo";case a:{var L=t,V=L._payload,O=L._init;try{return E(O(V))}catch{return null}}}return null}var J=Object.assign,F=0,H,re,P,ee,me,I,j;function $(){}$.__reactDisabledLog=!0;function ae(){{if(F===0){H=console.log,re=console.info,P=console.warn,ee=console.error,me=console.group,I=console.groupCollapsed,j=console.groupEnd;var t={configurable:!0,enumerable:!0,value:$,writable:!0};Object.defineProperties(console,{info:t,log:t,warn:t,error:t,group:t,groupCollapsed:t,groupEnd:t})}F++}}function te(){{if(F--,F===0){var t={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:J({},t,{value:H}),info:J({},t,{value:re}),warn:J({},t,{value:P}),error:J({},t,{value:ee}),group:J({},t,{value:me}),groupCollapsed:J({},t,{value:I}),groupEnd:J({},t,{value:j})})}F<0&&w("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var U=y.ReactCurrentDispatcher,se;function le(t,f,g){{if(se===void 0)try{throw Error()}catch(L){var k=L.stack.trim().match(/\n( *(at )?)/);se=k&&k[1]||""}return`
18
+ `+se+t}}var he=!1,be;{var et=typeof WeakMap=="function"?WeakMap:Map;be=new et}function $e(t,f){if(!t||he)return"";{var g=be.get(t);if(g!==void 0)return g}var k;he=!0;var L=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var V;V=U.current,U.current=null,ae();try{if(f){var O=function(){throw Error()};if(Object.defineProperty(O.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(O,[])}catch(de){k=de}Reflect.construct(t,[],O)}else{try{O.call()}catch(de){k=de}t.call(O.prototype)}}else{try{throw Error()}catch(de){k=de}t()}}catch(de){if(de&&k&&typeof de.stack=="string"){for(var T=de.stack.split(`
19
+ `),ce=k.stack.split(`
20
20
  `),Z=T.length-1,ne=ce.length-1;Z>=1&&ne>=0&&T[Z]!==ce[ne];)ne--;for(;Z>=1&&ne>=0;Z--,ne--)if(T[Z]!==ce[ne]){if(Z!==1||ne!==1)do if(Z--,ne--,ne<0||T[Z]!==ce[ne]){var ve=`
21
- `+T[Z].replace(" at new "," at ");return t.displayName&&ve.includes("<anonymous>")&&(ve=ve.replace("<anonymous>",t.displayName)),typeof t=="function"&&be.set(t,ve),ve}while(Z>=1&&ne>=0);break}}}finally{he=!1,U.current=V,te(),Error.prepareStackTrace=L}var Te=t?t.displayName||t.name:"",Ee=Te?le(Te):"";return typeof t=="function"&&be.set(t,Ee),Ee}function tt(t,f,g){return Re(t,!1)}function We(t){var f=t.prototype;return!!(f&&f.isReactComponent)}function je(t,f,g){if(t==null)return"";if(typeof t=="function")return Re(t,We(t));if(typeof t=="string")return le(t);switch(t){case p:return le("Suspense");case m:return le("SuspenseList")}if(typeof t=="object")switch(t.$$typeof){case d:return tt(t.render);case y:return je(t.type,f,g);case s:{var C=t,L=C._payload,V=C._init;try{return je(V(L),f,g)}catch{}}}return""}var pe=Object.prototype.hasOwnProperty,Ve={},Ye=b.ReactDebugCurrentFrame;function oe(t){if(t){var f=t._owner,g=je(t.type,t._source,f?f.type:null);Ye.setExtraStackFrame(g)}else Ye.setExtraStackFrame(null)}function Ce(t,f,g,C,L){{var V=Function.call.bind(pe);for(var O in t)if(V(t,O)){var T=void 0;try{if(typeof t[O]!="function"){var ce=Error((C||"React class")+": "+g+" type `"+O+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof t[O]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw ce.name="Invariant Violation",ce}T=t[O](f,O,C,g,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(Z){T=Z}T&&!(T instanceof Error)&&(oe(L),x("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",C||"React class",g,O,typeof T),oe(null)),T instanceof Error&&!(T.message in Ve)&&(Ve[T.message]=!0,oe(L),x("Failed %s type: %s",g,T.message),oe(null))}}}var nt=Array.isArray;function ze(t){return nt(t)}function $e(t){{var f=typeof Symbol=="function"&&Symbol.toStringTag,g=f&&t[Symbol.toStringTag]||t.constructor.name||"Object";return g}}function rt(t){try{return De(t),!1}catch{return!0}}function De(t){return""+t}function Pe(t){if(rt(t))return x("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",$e(t)),De(t)}var ge=b.ReactCurrentOwner,He={key:!0,ref:!0,__self:!0,__source:!0},we,Fe,Le;Le={};function Ue(t){if(pe.call(t,"ref")){var f=Object.getOwnPropertyDescriptor(t,"ref").get;if(f&&f.isReactWarning)return!1}return t.ref!==void 0}function Ke(t){if(pe.call(t,"key")){var f=Object.getOwnPropertyDescriptor(t,"key").get;if(f&&f.isReactWarning)return!1}return t.key!==void 0}function at(t,f){if(typeof t.ref=="string"&&ge.current&&f&&ge.current.stateNode!==f){var g=E(ge.current.type);Le[g]||(x('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',E(ge.current.type),t.ref),Le[g]=!0)}}function Be(t,f){{var g=function(){we||(we=!0,x("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",f))};g.isReactWarning=!0,Object.defineProperty(t,"key",{get:g,configurable:!0})}}function ye(t,f){{var g=function(){Fe||(Fe=!0,x("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",f))};g.isReactWarning=!0,Object.defineProperty(t,"ref",{get:g,configurable:!0})}}var st=function(t,f,g,C,L,V,O){var T={$$typeof:n,type:t,key:f,ref:g,props:O,_owner:V};return T._store={},Object.defineProperty(T._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(T,"_self",{configurable:!1,enumerable:!1,writable:!1,value:C}),Object.defineProperty(T,"_source",{configurable:!1,enumerable:!1,writable:!1,value:L}),Object.freeze&&(Object.freeze(T.props),Object.freeze(T)),T};function _(t,f,g,C,L){{var V,O={},T=null,ce=null;g!==void 0&&(Pe(g),T=""+g),Ke(f)&&(Pe(f.key),T=""+f.key),Ue(f)&&(ce=f.ref,at(f,L));for(V in f)pe.call(f,V)&&!He.hasOwnProperty(V)&&(O[V]=f[V]);if(t&&t.defaultProps){var Z=t.defaultProps;for(V in Z)O[V]===void 0&&(O[V]=Z[V])}if(T||ce){var ne=typeof t=="function"?t.displayName||t.name||"Unknown":t;T&&Be(O,ne),ce&&ye(O,ne)}return st(t,T,ce,L,C,ge.current,O)}}var M=b.ReactCurrentOwner,A=b.ReactDebugCurrentFrame;function ie(t){if(t){var f=t._owner,g=je(t.type,t._source,f?f.type:null);A.setExtraStackFrame(g)}else A.setExtraStackFrame(null)}var ue;ue=!1;function Ne(t){return typeof t=="object"&&t!==null&&t.$$typeof===n}function Xe(){{if(M.current){var t=E(M.current.type);if(t)return`
21
+ `+T[Z].replace(" at new "," at ");return t.displayName&&ve.includes("<anonymous>")&&(ve=ve.replace("<anonymous>",t.displayName)),typeof t=="function"&&be.set(t,ve),ve}while(Z>=1&&ne>=0);break}}}finally{he=!1,U.current=V,te(),Error.prepareStackTrace=L}var Te=t?t.displayName||t.name:"",Se=Te?le(Te):"";return typeof t=="function"&&be.set(t,Se),Se}function tt(t,f,g){return $e(t,!1)}function We(t){var f=t.prototype;return!!(f&&f.isReactComponent)}function je(t,f,g){if(t==null)return"";if(typeof t=="function")return $e(t,We(t));if(typeof t=="string")return le(t);switch(t){case p:return le("Suspense");case m:return le("SuspenseList")}if(typeof t=="object")switch(t.$$typeof){case d:return tt(t.render);case b:return je(t.type,f,g);case a:{var k=t,L=k._payload,V=k._init;try{return je(V(L),f,g)}catch{}}}return""}var pe=Object.prototype.hasOwnProperty,Ve={},Ye=y.ReactDebugCurrentFrame;function oe(t){if(t){var f=t._owner,g=je(t.type,t._source,f?f.type:null);Ye.setExtraStackFrame(g)}else Ye.setExtraStackFrame(null)}function ke(t,f,g,k,L){{var V=Function.call.bind(pe);for(var O in t)if(V(t,O)){var T=void 0;try{if(typeof t[O]!="function"){var ce=Error((k||"React class")+": "+g+" type `"+O+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof t[O]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw ce.name="Invariant Violation",ce}T=t[O](f,O,k,g,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(Z){T=Z}T&&!(T instanceof Error)&&(oe(L),w("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",k||"React class",g,O,typeof T),oe(null)),T instanceof Error&&!(T.message in Ve)&&(Ve[T.message]=!0,oe(L),w("Failed %s type: %s",g,T.message),oe(null))}}}var nt=Array.isArray;function ze(t){return nt(t)}function Re(t){{var f=typeof Symbol=="function"&&Symbol.toStringTag,g=f&&t[Symbol.toStringTag]||t.constructor.name||"Object";return g}}function rt(t){try{return De(t),!1}catch{return!0}}function De(t){return""+t}function Pe(t){if(rt(t))return w("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Re(t)),De(t)}var ge=y.ReactCurrentOwner,He={key:!0,ref:!0,__self:!0,__source:!0},we,Fe,Le;Le={};function Ue(t){if(pe.call(t,"ref")){var f=Object.getOwnPropertyDescriptor(t,"ref").get;if(f&&f.isReactWarning)return!1}return t.ref!==void 0}function Ke(t){if(pe.call(t,"key")){var f=Object.getOwnPropertyDescriptor(t,"key").get;if(f&&f.isReactWarning)return!1}return t.key!==void 0}function at(t,f){if(typeof t.ref=="string"&&ge.current&&f&&ge.current.stateNode!==f){var g=E(ge.current.type);Le[g]||(w('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',E(ge.current.type),t.ref),Le[g]=!0)}}function Be(t,f){{var g=function(){we||(we=!0,w("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",f))};g.isReactWarning=!0,Object.defineProperty(t,"key",{get:g,configurable:!0})}}function ye(t,f){{var g=function(){Fe||(Fe=!0,w("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",f))};g.isReactWarning=!0,Object.defineProperty(t,"ref",{get:g,configurable:!0})}}var st=function(t,f,g,k,L,V,O){var T={$$typeof:n,type:t,key:f,ref:g,props:O,_owner:V};return T._store={},Object.defineProperty(T._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(T,"_self",{configurable:!1,enumerable:!1,writable:!1,value:k}),Object.defineProperty(T,"_source",{configurable:!1,enumerable:!1,writable:!1,value:L}),Object.freeze&&(Object.freeze(T.props),Object.freeze(T)),T};function _(t,f,g,k,L){{var V,O={},T=null,ce=null;g!==void 0&&(Pe(g),T=""+g),Ke(f)&&(Pe(f.key),T=""+f.key),Ue(f)&&(ce=f.ref,at(f,L));for(V in f)pe.call(f,V)&&!He.hasOwnProperty(V)&&(O[V]=f[V]);if(t&&t.defaultProps){var Z=t.defaultProps;for(V in Z)O[V]===void 0&&(O[V]=Z[V])}if(T||ce){var ne=typeof t=="function"?t.displayName||t.name||"Unknown":t;T&&Be(O,ne),ce&&ye(O,ne)}return st(t,T,ce,L,k,ge.current,O)}}var M=y.ReactCurrentOwner,A=y.ReactDebugCurrentFrame;function ie(t){if(t){var f=t._owner,g=je(t.type,t._source,f?f.type:null);A.setExtraStackFrame(g)}else A.setExtraStackFrame(null)}var ue;ue=!1;function Ne(t){return typeof t=="object"&&t!==null&&t.$$typeof===n}function Xe(){{if(M.current){var t=E(M.current.type);if(t)return`
22
22
 
23
- Check the render method of \``+t+"`."}return""}}function tr(t){{if(t!==void 0){var f=t.fileName.replace(/^.*[\\\/]/,""),g=t.lineNumber;return`
23
+ Check the render method of \``+t+"`."}return""}}function rr(t){{if(t!==void 0){var f=t.fileName.replace(/^.*[\\\/]/,""),g=t.lineNumber;return`
24
24
 
25
- Check your code at `+f+":"+g+"."}return""}}var Nt={};function nr(t){{var f=Xe();if(!f){var g=typeof t=="string"?t:t.displayName||t.name;g&&(f=`
25
+ Check your code at `+f+":"+g+"."}return""}}var Nt={};function ar(t){{var f=Xe();if(!f){var g=typeof t=="string"?t:t.displayName||t.name;g&&(f=`
26
26
 
27
- Check the top-level render call using <`+g+">.")}return f}}function _t(t,f){{if(!t._store||t._store.validated||t.key!=null)return;t._store.validated=!0;var g=nr(f);if(Nt[g])return;Nt[g]=!0;var C="";t&&t._owner&&t._owner!==M.current&&(C=" It was passed a child from "+E(t._owner.type)+"."),ie(t),x('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',g,C),ie(null)}}function jt(t,f){{if(typeof t!="object")return;if(ze(t))for(var g=0;g<t.length;g++){var C=t[g];Ne(C)&&_t(C,f)}else if(Ne(t))t._store&&(t._store.validated=!0);else if(t){var L=N(t);if(typeof L=="function"&&L!==t.entries)for(var V=L.call(t),O;!(O=V.next()).done;)Ne(O.value)&&_t(O.value,f)}}}function rr(t){{var f=t.type;if(f==null||typeof f=="string")return;var g;if(typeof f=="function")g=f.propTypes;else if(typeof f=="object"&&(f.$$typeof===d||f.$$typeof===y))g=f.propTypes;else return;if(g){var C=E(f);Ce(g,t.props,"prop",C,t)}else if(f.PropTypes!==void 0&&!ue){ue=!0;var L=E(f);x("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",L||"Unknown")}typeof f.getDefaultProps=="function"&&!f.getDefaultProps.isReactClassApproved&&x("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function ar(t){{for(var f=Object.keys(t.props),g=0;g<f.length;g++){var C=f[g];if(C!=="children"&&C!=="key"){ie(t),x("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",C),ie(null);break}}t.ref!==null&&(ie(t),x("Invalid attribute `ref` supplied to `React.Fragment`."),ie(null))}}var Et={};function St(t,f,g,C,L,V){{var O=X(t);if(!O){var T="";(t===void 0||typeof t=="object"&&t!==null&&Object.keys(t).length===0)&&(T+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var ce=tr(L);ce?T+=ce:T+=Xe();var Z;t===null?Z="null":ze(t)?Z="array":t!==void 0&&t.$$typeof===n?(Z="<"+(E(t.type)||"Unknown")+" />",T=" Did you accidentally export a JSX literal instead of a component?"):Z=typeof t,x("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",Z,T)}var ne=_(t,f,g,L,V);if(ne==null)return ne;if(O){var ve=f.children;if(ve!==void 0)if(C)if(ze(ve)){for(var Te=0;Te<ve.length;Te++)jt(ve[Te],t);Object.freeze&&Object.freeze(ve)}else x("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else jt(ve,t)}if(pe.call(f,"key")){var Ee=E(t),de=Object.keys(f).filter(function(ur){return ur!=="key"}),ot=de.length>0?"{key: someKey, "+de.join(": ..., ")+": ...}":"{key: someKey}";if(!Et[Ee+ot]){var cr=de.length>0?"{"+de.join(": ..., ")+": ...}":"{}";x(`A props object containing a "key" prop is being spread into JSX:
27
+ Check the top-level render call using <`+g+">.")}return f}}function _t(t,f){{if(!t._store||t._store.validated||t.key!=null)return;t._store.validated=!0;var g=ar(f);if(Nt[g])return;Nt[g]=!0;var k="";t&&t._owner&&t._owner!==M.current&&(k=" It was passed a child from "+E(t._owner.type)+"."),ie(t),w('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',g,k),ie(null)}}function jt(t,f){{if(typeof t!="object")return;if(ze(t))for(var g=0;g<t.length;g++){var k=t[g];Ne(k)&&_t(k,f)}else if(Ne(t))t._store&&(t._store.validated=!0);else if(t){var L=N(t);if(typeof L=="function"&&L!==t.entries)for(var V=L.call(t),O;!(O=V.next()).done;)Ne(O.value)&&_t(O.value,f)}}}function sr(t){{var f=t.type;if(f==null||typeof f=="string")return;var g;if(typeof f=="function")g=f.propTypes;else if(typeof f=="object"&&(f.$$typeof===d||f.$$typeof===b))g=f.propTypes;else return;if(g){var k=E(f);ke(g,t.props,"prop",k,t)}else if(f.PropTypes!==void 0&&!ue){ue=!0;var L=E(f);w("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",L||"Unknown")}typeof f.getDefaultProps=="function"&&!f.getDefaultProps.isReactClassApproved&&w("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function or(t){{for(var f=Object.keys(t.props),g=0;g<f.length;g++){var k=f[g];if(k!=="children"&&k!=="key"){ie(t),w("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",k),ie(null);break}}t.ref!==null&&(ie(t),w("Invalid attribute `ref` supplied to `React.Fragment`."),ie(null))}}var St={};function Et(t,f,g,k,L,V){{var O=X(t);if(!O){var T="";(t===void 0||typeof t=="object"&&t!==null&&Object.keys(t).length===0)&&(T+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var ce=rr(L);ce?T+=ce:T+=Xe();var Z;t===null?Z="null":ze(t)?Z="array":t!==void 0&&t.$$typeof===n?(Z="<"+(E(t.type)||"Unknown")+" />",T=" Did you accidentally export a JSX literal instead of a component?"):Z=typeof t,w("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",Z,T)}var ne=_(t,f,g,L,V);if(ne==null)return ne;if(O){var ve=f.children;if(ve!==void 0)if(k)if(ze(ve)){for(var Te=0;Te<ve.length;Te++)jt(ve[Te],t);Object.freeze&&Object.freeze(ve)}else w("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else jt(ve,t)}if(pe.call(f,"key")){var Se=E(t),de=Object.keys(f).filter(function(fr){return fr!=="key"}),ot=de.length>0?"{key: someKey, "+de.join(": ..., ")+": ...}":"{key: someKey}";if(!St[Se+ot]){var dr=de.length>0?"{"+de.join(": ..., ")+": ...}":"{}";w(`A props object containing a "key" prop is being spread into JSX:
28
28
  let props = %s;
29
29
  <%s {...props} />
30
30
  React keys must be passed directly to JSX without using spread:
31
31
  let props = %s;
32
- <%s key={someKey} {...props} />`,ot,Ee,cr,Ee),Et[Ee+ot]=!0}}return t===o?ar(ne):rr(ne),ne}}function sr(t,f,g){return St(t,f,g,!0)}function or(t,f,g){return St(t,f,g,!1)}var ir=or,lr=sr;Oe.Fragment=o,Oe.jsx=ir,Oe.jsxs=lr}()),Oe}process.env.NODE_ENV==="production"?qe.exports=Pt():qe.exports=Tt();var a=qe.exports;function Me(e,n){return n?a.jsx(n,{size:e,strokeWidth:2.5}):a.jsx(a.Fragment,{})}function ct(e,n){return[...new Array(n-e)].map((r,o)=>e+o+1).filter(r=>r>0)}function It(e,n,r){return e>=r?[]:ct(e+1,e+n)}function Ot(e,n){return e<=1?[]:ct(e-1-n,e-1)}function zt(e,n,r){if(!e)return a.jsx(a.Fragment,{});if(typeof e=="string")return a.jsx("p",{className:r,children:e});const o=e;return a.jsx("p",{className:r,children:a.jsx(o,{color:"var(--secondary-600)",size:n,strokeWidth:2.5})})}function Dt(e){const{variant:n="ghost",scheme:r="primary",size:o="md",leftIcon:i,rightIcon:u,className:h="",children:c,...d}=e,m={md:12,lg:14}[o],y=`arkyn_badge ${n} ${r} ${o} ${h}`;return a.jsxs("div",{className:y.trim(),...d,children:[Me(m,i),c,Me(m,i)]})}function Ft(e){const{className:n,orientation:r="horizontal",...o}=e,i=`arkyn_divider ${r} ${n}`;return a.jsx("div",{className:i,...o})}function Lt(e){const{className:n,...r}=e,o=`arkyn_skeleton ${n}`;return a.jsx("aside",{className:o.trim(),...r})}function Bt(e){const{className:n,...r}=e,o=`arkyn_table_body ${n}`;return a.jsx("tbody",{className:o.trim(),...r})}function Mt(e){const{className:n,children:r,...o}=e,i=`arkyn_table_caption ${n}`;return a.jsx("caption",{className:i.trim(),...o,children:a.jsx("div",{className:"arkyn_table_caption-content",children:r})})}function At(e){const{children:n,className:r,...o}=e,i=`arkyn_table_container ${r}`;return a.jsx("div",{className:i.trim(),...o,children:a.jsx("table",{children:n})})}function Wt(e){const{className:n,children:r,...o}=e,i=`arkyn_table_footer ${n}`;return a.jsxs("tfoot",{className:i.trim(),...o,children:[a.jsx("tr",{className:"spacing-row"}),a.jsx("tr",{children:a.jsx("th",{colSpan:100,children:a.jsx("div",{className:"arkyn_table_footer-content",children:r})})})]})}function Vt(e){const{className:n,children:r,...o}=e,i=`arkyn_table_header ${n}`;return a.jsxs("thead",{className:i.trim(),...o,children:[a.jsx("tr",{children:r}),a.jsx("tr",{className:"spacing-row"})]})}function Yt(e){const{isLoading:n=!1,scheme:r="primary",variant:o="solid",loadingText:i,size:u="md",leftIcon:h,rightIcon:c,disabled:d,className:p="",children:m,...y}=e,v={xs:12,sm:16,md:20,lg:24}[u],R=`arkyn_button loading_text_${!!i} ${o} ${r} ${u} loading_${n} ${p}`;return a.jsxs("button",{className:R,disabled:d||n,...y,children:[a.jsxs("div",{className:"arkyn_button-spinner",children:[a.jsx(G.Loader2,{size:v,strokeWidth:2.5}),i&&i]}),a.jsxs("div",{className:"arkyn_button-content",children:[Me(v,h),m,Me(v,c)]})]})}const ut=l.createContext({});function Ht(e){var m,y;const n=Se.useActionData(),{children:r,className:o,...i}=e,u=l.useRef(null),h=((m=u.current)==null?void 0:m.name)||"",c=((y=n==null?void 0:n.fieldErrors)==null?void 0:y[h])||null,d=l.useId(),p=`arkyn_form_controller ${o}`;return a.jsx(ut.Provider,{value:{error:c,id:d,inputRef:u},children:a.jsx("section",{className:p.trim(),...i,children:r})})}function xe(){return l.useContext(ut)}function Ut(e){const{name:n,className:r="",size:o="md",isError:i,defaultChecked:u=!1,checked:h=null,onCheck:c,value:d,...p}=e,{id:m,inputRef:y,error:s}=xe(),v=i||!!s,[R,w]=l.useState(u||!1),N=typeof h=="boolean"?h:R,b=`arkyn_checkbox ${o} ${v?"error":""} ${N?"checked":""} ${r}`;function x(){const Y=R;w(!Y),c&&c(Y?"":d||"checked")}return a.jsxs("button",{type:"button",id:m,className:b,onClick:x,...p,children:[a.jsx("input",{type:"hidden",name:n,ref:y,value:N?d||"checked":""}),a.jsx(G.Check,{})]})}function Kt(e){const{children:n,className:r,...o}=e,i=`arkyn_form_error ${r}`,{error:u}=xe();return n?a.jsx("strong",{className:i.trim(),...o,children:n}):u?a.jsx("strong",{className:i.trim(),...o,children:u}):a.jsx(a.Fragment,{})}function Xt(e){const{showAsterisk:n=!1,className:r="",...o}=e,{id:i}=xe(),h=`arkyn_form_label ${n?"show-asterisk":""} ${r}`;return a.jsx("label",{...o,className:h.trim(),htmlFor:i})}function qt(e){const{isLoading:n=!1,scheme:r="primary",variant:o="solid",size:i="md",icon:u,disabled:h,className:c="",...d}=e,p={xs:12,sm:16,md:20,lg:24},m=`arkyn_icon_button ${o} ${r} ${i} loading_${n} ${c}`;return a.jsxs("button",{disabled:h||n,className:m.trim(),...d,children:[a.jsx("div",{className:"arkyn_icon_button-spinner",children:a.jsx(G.Loader2,{size:p[i],strokeWidth:2.5})}),a.jsx("div",{className:"arkyn_icon_button-content",children:a.jsx(u,{size:p[i],strokeWidth:2.5})})]})}function ke(e,n,r){if(!e)return a.jsx(a.Fragment,{});if(typeof e=="string")return a.jsx("p",{className:r,children:e});const o=e;return a.jsx("p",{className:r,children:a.jsx(o,{color:"var(--secondary-600)",size:n,strokeWidth:2.5})})}function Je(e){return e&&e.replace(/[^0-9]/g,"")}function dt(e,n){let r="",o=0;return Array.from(e).forEach((i,u)=>{n[u+o].match(/[0-9]/)||(r+=n[u+o],o++),r+=i}),r}function ft(e){return e.length>11?"CNPJ":"CPF"}const Ge={CPF:"999.999.999-999",CNPJ:"99.999.999/9999-99"},ht=Je(Ge.CNPJ).length;function Jt(e,n){const{isLoading:r,isError:o,size:i="md",className:u="",variant:h="solid",prefix:c,sufix:d,leftIcon:p,rightIcon:m,disabled:y,defaultValue:s,readOnly:v,onFocus:R,onBlur:w,title:N,style:b,onChange:x,...Y}=e;function D(J){let F=Je(J);const H=ft(F);if(!(F.length>ht))return F=dt(F,Ge[H]),F}const $=m?"right":"left",z=`arkyn_input ${c?"hasPrefix":""} ${d?"hasSufix":""} ${h} ${i} ${y||v||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${u}`,E={md:20,lg:20}[i];return{isLoading:r,className:z,prefix:ke(c,E,"prefix"),sufix:ke(d,E,"sufix"),LeftIcon:p,RightIcon:m,defaultValue:D(s||""),disabled:y,readOnly:v,onFocus:R,onBlur:w,title:N,style:b,onChange:x,loadingPosition:$,iconSize:E,Spinner:a.jsx(G.Loader2,{className:"spinner",size:E,strokeWidth:2.5}),...Y}}function Gt(e){const[n,r]=l.useState(!1),o=l.useRef(null),{inputRef:i,id:u,error:h}=xe(),c=i||o,d=e.isError||!!h,{disabled:p,title:m,style:y,className:s,prefix:v,sufix:R,iconSize:w,loadingPosition:N,isLoading:b,LeftIcon:x,readOnly:Y,onFocus:D,onBlur:$,RightIcon:W,Spinner:B,onChange:q,value:K,defaultValue:X,...z}=Jt({...e,id:u,isError:d},n),[Q,E]=l.useState(X),J=x&&!b,F=W&&!b,H=N==="left"&&b,re=N==="right"&&b;function P(){p||!(c!=null&&c.current)||(r(!0),c.current.focus())}function ee(j){let S=Je(j.target.value);const ae=ft(S);S.length>ht||(S=dt(S,Ge[ae]),j.target.value=S,E(S),q&&q(j))}function me(j){r(!0),D&&D(j)}function I(j){r(!1),$&&$(j)}return a.jsxs("section",{title:m,style:y,onClick:P,className:s,children:[v,H&&B,J&&a.jsx(x,{size:w,strokeWidth:2.5}),a.jsx("input",{disabled:p||b,readOnly:Y,ref:c,value:K||Q,onFocus:me,onChange:ee,onBlur:I,...z}),F&&a.jsx(W,{size:w,strokeWidth:2.5}),re&&B,R]})}function Zt(e,n){const{isLoading:r,isError:o,size:i="md",className:u="",variant:h="solid",prefix:c,sufix:d,leftIcon:p,rightIcon:m,disabled:y,readOnly:s,onFocus:v,onBlur:R,title:w,style:N,showCents:b=!1,max:x=1e9,onChange:Y,...D}=e,$=m?"right":"left",z=`arkyn_input ${c?"hasPrefix":""} ${d?"hasSufix":""} ${h} ${i} ${y||s||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${u}`,E={md:20,lg:20}[i];return{isLoading:r,className:z,prefix:ke(c,E,"prefix"),sufix:ke(d,E,"sufix"),LeftIcon:p,RightIcon:m,disabled:y,readOnly:s,onFocus:v,onBlur:R,title:w,style:N,max:x,onChange:Y,showCents:b,loadingPosition:$,iconSize:E,Spinner:a.jsx(G.Loader2,{className:"spinner",size:E,strokeWidth:2.5}),...D}}const Qt=/^[1-9]{1}$/,en=/^[0-9]{1}$/,mt=8;function tn(e,n){if(e===0)return"";const r=(e/100).toLocaleString("pt-BR",{style:"currency",currency:"BRL"});return n?r:r.replace("R$","").trim()}function nn(e){const{currencyValue:n,event:r,max:o,setCurrencyValue:i}=e,{key:u,keyCode:h}=r;if(n===0&&!Qt.test(u)||n!==0&&!en.test(u)&&h!==mt)return;const c=n.toString();let d;if(h!==mt){const p=n===0?u:`${c}${u}`;d=Number.parseInt(p,10)}else{const p=c.slice(0,-1);d=p===""?0:Number.parseInt(p,10)}d>Number(o)||i(d)}function rn(e){const[n,r]=l.useState(!1),o=l.useRef(null),{inputRef:i,id:u,error:h}=xe(),c=i||o,d=e.isError||!!h,{disabled:p,title:m,style:y,className:s,prefix:v,sufix:R,iconSize:w,loadingPosition:N,isLoading:b,LeftIcon:x,readOnly:Y,onFocus:D,onBlur:$,RightIcon:W,Spinner:B,value:q,max:K,onKeyDown:X,onChange:z,showCents:Q,defaultValue:E,...J}=Zt({...e,id:u,isError:d},n),[F,H]=l.useState(E*100||0),re=x&&!b,P=W&&!b,ee=N==="left"&&b,me=N==="right"&&b;function I(){p||!(c!=null&&c.current)||(r(!0),c.current.focus())}function j(te){nn({currencyValue:F,event:te,max:K,setCurrencyValue:H}),z&&z(F/100),X&&X(te)}function S(te){r(!0),D&&D(te)}function ae(te){r(!1),$&&$(te)}return a.jsxs("section",{title:m,style:y,onClick:I,className:s,children:[v,ee&&B,re&&a.jsx(x,{size:w,strokeWidth:2.5}),a.jsx("input",{value:tn(q||F,Q),onKeyDown:j,disabled:p||b,readOnly:Y,ref:c,onFocus:S,onBlur:ae,onChange:()=>{},...J}),me&&B,P&&a.jsx(W,{size:w,strokeWidth:2.5}),R]})}function an(e,n){const{isLoading:r,isError:o,size:i="md",className:u="",variant:h="solid",prefix:c,sufix:d,leftIcon:p,rightIcon:m,disabled:y,readOnly:s,onFocus:v,onBlur:R,title:w,style:N,onChange:b,showMask:x=!1,type:Y,...D}=e,$=m?"right":"left",z=`arkyn_input ${c?"hasPrefix":""} ${d?"hasSufix":""} ${h} ${i} ${y||s||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${u}`,E={md:20,lg:20}[i];return{isLoading:r,className:z,prefix:ke(c,E,"prefix"),sufix:ke(d,E,"sufix"),LeftIcon:p,RightIcon:m,disabled:y,readOnly:s,onFocus:v,onBlur:R,title:w,style:N,onChange:b,loadingPosition:$,iconSize:E,showMask:x,Spinner:a.jsx(G.Loader2,{className:"spinner",size:E,strokeWidth:2.5}),...D}}const sn=l.forwardRef((e,n)=>a.jsx("input",{ref:n,...e}));function on(e){const[n,r]=l.useState(!1),o=l.useRef(null),{inputRef:i,id:u,error:h}=xe(),c=i||o,d=e.isError||!!h,{disabled:p,title:m,style:y,className:s,prefix:v,sufix:R,iconSize:w,loadingPosition:N,isLoading:b,LeftIcon:x,readOnly:Y,onFocus:D,onBlur:$,RightIcon:W,Spinner:B,...q}=an({...e,id:u,isError:d},n),K=x&&!b,X=W&&!b,z=N==="left"&&b,Q=N==="right"&&b;function E(){p||!(c!=null&&c.current)||(r(!0),c.current.focus())}function J(H){r(!0),D&&D(H)}function F(H){r(!1),$&&$(H)}return a.jsxs("section",{title:m,style:y,onClick:E,className:s,children:[v,z&&B,K&&a.jsx(x,{size:w,strokeWidth:2.5}),a.jsx(Rt.InputMask,{component:sn,ref:c,onFocus:J,onBlur:F,...q}),X&&a.jsx(W,{size:w,strokeWidth:2.5}),Q&&B,R]})}function ln(e,n){const{isLoading:r,isError:o,size:i="md",className:u="",variant:h="solid",prefix:c,sufix:d,leftIcon:p,rightIcon:m,disabled:y,readOnly:s,onFocus:v,onBlur:R,title:w,style:N,onChange:b,...x}=e,Y=m?"right":"left",K=`arkyn_input ${c?"hasPrefix":""} ${d?"hasSufix":""} ${h} ${i} ${y||s||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${u}`,z={md:20,lg:20}[i];return{isLoading:r,className:K,prefix:ke(c,z,"prefix"),sufix:ke(d,z,"sufix"),LeftIcon:p,RightIcon:m,disabled:y,readOnly:s,onFocus:v,onBlur:R,title:w,style:N,onChange:b,loadingPosition:Y,iconSize:z,Spinner:a.jsx(G.Loader2,{className:"spinner",size:z,strokeWidth:2.5}),...x}}function cn(e){const[n,r]=l.useState(!1),o=l.useRef(null),{inputRef:i,id:u,error:h}=xe(),c=i||o,d=e.isError||!!h,{disabled:p,title:m,style:y,className:s,prefix:v,sufix:R,iconSize:w,loadingPosition:N,isLoading:b,LeftIcon:x,readOnly:Y,onFocus:D,onBlur:$,RightIcon:W,type:B,Spinner:q,...K}=ln({...e,id:u,isError:d},n),X=x&&!b,z=W&&!b,Q=N==="left"&&b,E=N==="right"&&b;function J(){p||!(c!=null&&c.current)||(r(!0),c.current.focus())}function F(re){r(!0),D&&D(re)}function H(re){r(!1),$&&$(re)}return B==="hidden"?a.jsx("input",{type:"hidden",ref:c,...K}):a.jsxs("section",{title:m,style:y,onClick:J,className:s,children:[v,Q&&q,X&&a.jsx(x,{size:w,strokeWidth:2.5}),a.jsx("input",{disabled:p||b,readOnly:Y,ref:c,onFocus:F,onBlur:H,type:B,...K}),z&&a.jsx(W,{size:w,strokeWidth:2.5}),E&&q,R]})}function un(e){return e.type==="currency"?a.jsx(rn,{...e}):e.type==="masked"?a.jsx(on,{...e}):e.type==="cpf-cnpj"?a.jsx(Gt,{...e}):a.jsx(cn,{...e})}function dn(e,n){const{isLoading:r,isError:o,size:i="md",className:u="",variant:h="solid",prefix:c,leftIcon:d,disabled:p,readOnly:m,onFocus:y,onBlur:s,title:v,style:R,closeOnSelect:w=!0,...N}=e,$=`arkyn_select ${c?"hasPrefix":""} ${h} ${i} ${p||m||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${u}`,B={md:20,lg:20}[i];return{isLoading:r,className:$,prefix:zt(c,B,"prefix"),LeftIcon:d,disabled:p,readOnly:m,onFocus:y,onBlur:s,title:v,closeOnSelect:w,style:R,iconSize:B,Spinner:a.jsx(G.Loader2,{className:"spinner",size:B,strokeWidth:2.5}),...N}}function fn(e){var U;const[n,r]=l.useState(!1),{inputRef:o,id:i,error:u}=xe(),h=l.useRef(null),c=o||h,d=e.isError||!!u,{disabled:p,title:m,style:y,className:s,prefix:v,iconSize:R,isLoading:w,LeftIcon:N,value:b=null,defaultValue:x="",readOnly:Y,onFocus:D,onBlur:$,Spinner:W,name:B,placeholder:q,onSelect:K,options:X,optionMaxHeight:z,closeOnSelect:Q,...E}=dn({...e,id:i,isError:d},n),[J,F]=l.useState(x),[H,re]=l.useState("");function P(){p||!(c!=null&&c.current)||(r(!0),c.current.focus())}function ee(se){r(!0),D&&D(se)}function me(){r(!1),$&&c.current&&c.current.blur()}function I(se){const{label:le,value:he}=se;F(J!==he?he:""),K&&K({label:le,value:he}),Q&&(c.current.blur(),r(!1),console.log("fecha"))}const j=typeof b=="string"?b:J,S=((U=X.find(se=>se.value===j))==null?void 0:U.label)||"",ae=()=>{if(!n&&S)return!0;if(!n&&!S)return!1;if(n&&S)return!0;if(n&&!S)return!1},te=X.filter(se=>!0);return a.jsxs(a.Fragment,{children:[a.jsxs("section",{title:m,style:y,onClick:P,className:`${s} placeholder_dark_${ae()}`,children:[v,N&&a.jsx(N,{size:R,strokeWidth:2.5}),a.jsx("input",{disabled:p||w,readOnly:!0,value:H||"",placeholder:S||q,onFocus:ee,onBlur:()=>re(""),...E}),a.jsx("input",{type:"hidden",ref:c,name:B,value:j||"",readOnly:!0}),n&&a.jsxs("div",{className:"arkyn_select_content",style:{overflow:"auto",maxHeight:z},children:[te.map(({label:se,value:le})=>a.jsxs("div",{onClick:()=>I({label:se,value:le}),className:j===le?"arkyn_select_option active":"arkyn_select_option",children:[se," ",a.jsx(G.Check,{})]},le)),te.length<=0&&a.jsx("p",{children:"Sem opções disponíveis"})]}),!w&&a.jsx(G.ChevronDown,{className:"arkyn_select_arrow",size:R,strokeWidth:2.5}),w&&W]}),n&&a.jsx("aside",{className:"arkyn_select_overlay",onClick:me})]})}function hn(e){const{variant:n="solid",size:r="md",className:o,disabled:i=!1,readOnly:u=!1,onFocus:h,onBlur:c,title:d,style:p,...m}=e,[y,s]=l.useState(!1),{inputRef:v,id:R,error:w}=xe(),N=l.useRef(null),b=v||N,Y=e.isError||!!w?"errored":"",W=`arkyn_textarea ${n} ${r} ${i||u?"opacity":""} ${Y} ${y?"focused":""} ${o}`;function B(){i||!(b!=null&&b.current)||(s(!0),b.current.focus())}function q(X){s(!0),h&&h(X)}function K(X){s(!1),c&&c(X)}return a.jsx("section",{title:d,style:p,onClick:B,className:W,children:a.jsx("textarea",{id:R,disabled:i,readOnly:u,ref:b,onFocus:q,onBlur:K,...m})})}function mn(e){const{className:n="",...r}=e,o=`arkyn_breadcrumb_container ${n}`;return a.jsx("nav",{className:o,...r})}function pn(e){const{pathname:n}=Se.useLocation(),{className:r="",disabled:o=!1,children:i,to:u,...h}=e,d=`arkyn_breadcrumb_link ${n===u?"active":"inactive"} ${r}`;return o?a.jsxs("p",{className:d,children:[a.jsx(G.ChevronRight,{size:14,strokeWidth:2.5}),i]}):a.jsxs(Se.Link,{to:u,className:d,...h,children:[a.jsx(G.ChevronRight,{size:14,strokeWidth:2.5}),i]})}function pt(e=""){const n=Se.useLocation(),r=new URLSearchParams(n.search),o=e?`${e}:`:"",i=u=>{Object.entries(u).forEach(([h,c])=>{c===void 0?r.delete(`${o}${h}`):r.set(`${o}${h}`,String(c))})};return{getParam:u=>r.get(`${o}${u}`),getScopedSearch:u=>{i(u);let h=r.toString();return h&&(h="?"+h),h}}}function gn(e){const{scope:n,totalCountRegisters:r,perPageKey:o="per_page",pageKey:i="page",siblingsCount:u=2,...h}=e,c=Se.useNavigate(),{getParam:d,getScopedSearch:p}=pt(n),m=Number(d(i))||1,y=Number(d(o))||20,s=Math.ceil(r/y),v=Ot(m,u),R=It(m,u,s);function w(N){c(p({page:N}))}return a.jsxs("div",{className:"arkyn_pagination",...h,children:[a.jsx("button",{className:"arkyn_pagination-icon_button",disabled:m<=1,onClick:()=>w(m-1),children:a.jsx(G.ChevronLeft,{})}),m>1+u&&a.jsxs(a.Fragment,{children:[a.jsx("button",{className:"arkyn_pagination-page_button",onClick:()=>w(1),children:"1"}),m>2+u&&a.jsx("button",{disabled:!0,className:"arkyn_pagination-spread",children:a.jsx(G.Ellipsis,{})})]}),v.map((N,b)=>a.jsx("button",{onClick:()=>w(N),className:"arkyn_pagination-page_button",children:N},b)),a.jsx("button",{className:"arkyn_pagination-current",disabled:!0,children:m}),R.map((N,b)=>a.jsx("button",{onClick:()=>w(N),className:"arkyn_pagination-page_button",children:N},b)),m+u<s&&a.jsxs(a.Fragment,{children:[m+1+u<s&&a.jsx("button",{disabled:!0,className:"arkyn_pagination-spread",children:a.jsx(G.Ellipsis,{})}),a.jsx("button",{className:"arkyn_pagination-page_button",onClick:()=>w(s),children:s})]}),a.jsx("button",{className:"arkyn_pagination-icon_button",disabled:m>=s,onClick:()=>w(m+1),children:a.jsx(G.ChevronRight,{})})]})}const gt=l.createContext({});function vn(e){const{isVisibled:n,makeInvisible:r,orientation:o="left",children:i,className:u,...h}=e,c=o==="left"?"-100%":"100%",p=`arkyn_drawer_container ${o} ${n?"visible":""} ${u}`;return a.jsx(gt.Provider,{value:{makeInvisible:r},children:a.jsx(_e.AnimatePresence,{children:n&&a.jsxs("aside",{className:p.trim(),...h,children:[a.jsx(_e.motion.div,{className:"arkyn_drawer_container-overlay",transition:{duration:.15,ease:"easeOut"},initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},onClick:r}),a.jsx(_e.motion.div,{className:"arkyn_drawer_container-content",transition:{ease:"easeOut",duration:.15},initial:{transform:`translateX(${c})`},animate:{transform:"translateX(0px)"},exit:{transform:`translateX(${c})`},children:i})]})})})}function bn(e){const{showCloseButton:n=!0,className:r,children:o,...i}=e,{makeInvisible:u}=l.useContext(gt),h=`arkyn_drawer_header ${r}`;return a.jsxs("header",{className:h.trim(),...i,children:[o,n&&a.jsx("button",{className:"arkyn_drawer_header-close_button",type:"button",onClick:u,"aria-label":"Close drawer",children:a.jsx(G.X,{size:24})})]})}const vt=l.createContext({});function yn(e){const{isVisibled:n,makeInvisible:r,children:o,className:i="",...u}=e,c=`arkyn_modal_container ${n?"visible":""} ${i}`;return a.jsx(vt.Provider,{value:{makeInvisible:r},children:a.jsx(_e.AnimatePresence,{children:n&&a.jsxs("aside",{className:c.trim(),...u,children:[a.jsx(_e.motion.div,{className:"arkyn_modal_container-overlay",transition:{duration:.15,ease:"easeOut"},initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},onClick:r}),a.jsx(_e.motion.div,{className:"arkyn_modal_container-content",transition:{duration:.15,ease:"easeOut"},initial:{opacity:0,scale:.75},animate:{opacity:1,scale:1},exit:{opacity:0,scale:0},children:o})]})})})}function xn(e){const{alignment:n="right",className:r,...o}=e,i=`arkyn_modal_footer ${n} ${r}`;return a.jsx("footer",{className:i.trim(),...o})}function wn(e){const{showCloseButton:n=!0,className:r,children:o,...i}=e,{makeInvisible:u}=l.useContext(vt),h=`arkyn_modal_header ${r}`;return a.jsxs("header",{className:h.trim(),...i,children:[o,n&&a.jsx("button",{type:"button",onClick:u,"aria-label":"Close modal button",className:"arkyn_modal_header-close_button",children:a.jsx(G.X,{size:24})})]})}function kn(e){const{children:n,button:r,closeOnClick:o,orientation:i="bottom-left"}=e,[u,h]=l.useState(!1),c=`arkyn_popover ${i} ${u?"show":""}`;function d(){u||h(!0)}return a.jsxs("div",{className:c,onClick:d,children:[r,a.jsx(_e.motion.div,{style:{visibility:u?"visible":"hidden"},transition:{ease:"easeOut",duration:0},initial:{opacity:0},animate:{opacity:u?1:0},exit:{opacity:0},onClick:()=>o&&h(!1),className:"arkyn_popover-content",children:n}),u&&a.jsx("div",{onClick:()=>h(!1),className:"arkyn_popover-overlay"})]})}function bt(e){const{message:n,title:r,type:o,size:i="lg"}=e,u=`arkyn_toast ${o} ${i}`;function h(){switch(o){case"info":return a.jsx(G.Info,{});case"success":return a.jsx(G.CheckCircle2,{});case"danger":return a.jsx(G.XCircle,{});case"warning":return a.jsx(G.AlertCircle,{});default:return a.jsx(G.Info,{})}}return a.jsxs("aside",{className:u,children:[a.jsxs("div",{children:[a.jsx("div",{className:"bg"}),a.jsx(h,{})]}),a.jsxs("p",{children:[a.jsx("strong",{title:r,children:r}),a.jsx("span",{children:n})]})]})}function Cn(e){const{text:n,size:r="lg",children:o,orientation:i="top",className:u,...h}=e,c=`arkyn_tooltip ${r} ${i} ${u}`;return a.jsxs("div",{className:c.trim(),...h,children:[o,a.jsx("div",{className:"arkyn_tooltip-text",children:n})]})}const Ze=l.createContext({}),yt=l.createContext({});function xt(){const e=l.useContext(yt);if(Object.entries(e).length===0)throw new Error("useToast must be used within a Provider");return e}function wt(e){return e&&typeof e.title=="string"&&typeof e.message=="string"&&(e.size===void 0||e.size==="md"||e.size==="lg")&&(e.type==="info"||e.type==="success"||e.type==="danger"||e.type==="warning")}function Nn(){const e=Se.useActionData(),{closeModal:n}=l.useContext(Ze),{showToast:r}=xt();l.useEffect(()=>{const o=e==null?void 0:e.closeModalKey;o&&n(o)},[e]),l.useEffect(()=>{const o=e==null?void 0:e.toast,i=e==null?void 0:e.message;wt(o)&&r(o),!wt(o)&&i&&r({message:i,title:"Atenção!",type:"warning"})},[e])}const kt=l.createContext({});function _n(e){const n=l.useContext(kt);if(Object.entries(n).length===0)throw new Error("useDrawer must be used within a Provider");if(e){const{drawerData:r,drawerIsOpen:o,openDrawer:i,closeDrawer:u}=n,h=o(e),c=r(e);return{drawerIsOpen:h,drawerData:c,openDrawer:m=>i(e,m),closeDrawer:()=>u(e)}}else return n}function jn(e){const n=l.useContext(Ze);if(Object.entries(n).length===0)throw new Error("useModal must be used within a Provider");if(e){const{modalData:r,modalIsOpen:o,openModal:i,closeModal:u}=n,h=o(e),c=r(e);return{modalIsOpen:h,modalData:c,openModal:m=>i(e,m),closeModal:()=>u(e)}}else return n}function En(e){const{children:n=!1}=e,[r,o]=l.useState([]);function i(d){return!!r.some(p=>p.key===d)}function u(d){var p;return(p=r.find(m=>m.key===d))==null?void 0:p.data}function h(d,p){const m=i(d);o(m?y=>[...y.filter(v=>v.key!==d),{key:d,data:p}]:[...r,{key:d,data:p}])}function c(d){o(r.filter(p=>p.key!==d))}return a.jsx(kt.Provider,{value:{drawerIsOpen:i,drawerData:u,openDrawer:h,closeDrawer:c},children:n})}function Sn(e){const{children:n=!1}=e,[r,o]=l.useState([]);function i(d){return!!r.some(p=>p.key===d)}function u(d){var p;return(p=r.find(m=>m.key===d))==null?void 0:p.data}function h(d,p){const m=i(d);o(m?y=>[...y.filter(v=>v.key!==d),{key:d,data:p}]:[...r,{key:d,data:p}])}function c(d){o(r.filter(p=>p.key!==d))}return a.jsx(Ze.Provider,{value:{modalIsOpen:i,modalData:u,openModal:h,closeModal:c},children:n})}var Rn=e=>{switch(e){case"success":return Tn;case"info":return On;case"warning":return In;case"error":return zn;default:return null}},$n=Array(12).fill(0),Pn=({visible:e})=>l.createElement("div",{className:"sonner-loading-wrapper","data-visible":e},l.createElement("div",{className:"sonner-spinner"},$n.map((n,r)=>l.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),Tn=l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},l.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),In=l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},l.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),On=l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},l.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),zn=l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},l.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),Dn=()=>{let[e,n]=l.useState(document.hidden);return l.useEffect(()=>{let r=()=>{n(document.hidden)};return document.addEventListener("visibilitychange",r),()=>window.removeEventListener("visibilitychange",r)},[]),e},Qe=1,Fn=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let n=this.subscribers.indexOf(e);this.subscribers.splice(n,1)}),this.publish=e=>{this.subscribers.forEach(n=>n(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var n;let{message:r,...o}=e,i=typeof(e==null?void 0:e.id)=="number"||((n=e.id)==null?void 0:n.length)>0?e.id:Qe++,u=this.toasts.find(c=>c.id===i),h=e.dismissible===void 0?!0:e.dismissible;return u?this.toasts=this.toasts.map(c=>c.id===i?(this.publish({...c,...e,id:i,title:r}),{...c,...e,id:i,dismissible:h,title:r}):c):this.addToast({title:r,...o,dismissible:h,id:i}),i},this.dismiss=e=>(e||this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),this.subscribers.forEach(n=>n({id:e,dismiss:!0})),e),this.message=(e,n)=>this.create({...n,message:e}),this.error=(e,n)=>this.create({...n,message:e,type:"error"}),this.success=(e,n)=>this.create({...n,type:"success",message:e}),this.info=(e,n)=>this.create({...n,type:"info",message:e}),this.warning=(e,n)=>this.create({...n,type:"warning",message:e}),this.loading=(e,n)=>this.create({...n,type:"loading",message:e}),this.promise=(e,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:e,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));let o=e instanceof Promise?e:e(),i=r!==void 0;return o.then(async u=>{if(Bn(u)&&!u.ok){i=!1;let h=typeof n.error=="function"?await n.error(`HTTP error! status: ${u.status}`):n.error,c=typeof n.description=="function"?await n.description(`HTTP error! status: ${u.status}`):n.description;this.create({id:r,type:"error",message:h,description:c})}else if(n.success!==void 0){i=!1;let h=typeof n.success=="function"?await n.success(u):n.success,c=typeof n.description=="function"?await n.description(u):n.description;this.create({id:r,type:"success",message:h,description:c})}}).catch(async u=>{if(n.error!==void 0){i=!1;let h=typeof n.error=="function"?await n.error(u):n.error,c=typeof n.description=="function"?await n.description(u):n.description;this.create({id:r,type:"error",message:h,description:c})}}).finally(()=>{var u;i&&(this.dismiss(r),r=void 0),(u=n.finally)==null||u.call(n)}),r},this.custom=(e,n)=>{let r=(n==null?void 0:n.id)||Qe++;return this.create({jsx:e(r),id:r,...n}),r},this.subscribers=[],this.toasts=[]}},fe=new Fn,Ln=(e,n)=>{let r=(n==null?void 0:n.id)||Qe++;return fe.addToast({title:e,...n,id:r}),r},Bn=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",Mn=Ln,An=()=>fe.toasts,Wn=Object.assign(Mn,{success:fe.success,info:fe.info,warning:fe.warning,error:fe.error,custom:fe.custom,message:fe.message,promise:fe.promise,dismiss:fe.dismiss,loading:fe.loading},{getHistory:An});function Vn(e,{insertAt:n}={}){if(!e||typeof document>"u")return;let r=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",n==="top"&&r.firstChild?r.insertBefore(o,r.firstChild):r.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}Vn(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999}:where([data-sonner-toaster][data-x-position="right"]){right:max(var(--offset),env(safe-area-inset-right))}:where([data-sonner-toaster][data-x-position="left"]){left:max(var(--offset),env(safe-area-inset-left))}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:max(var(--offset),env(safe-area-inset-top))}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:max(var(--offset),env(safe-area-inset-bottom))}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;background:var(--gray1);color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:0;right:0;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount, 0px));transition:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation:swipe-out .2s ease-out forwards}@keyframes swipe-out{0%{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount)));opacity:1}to{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount) + var(--lift) * -100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;--mobile-offset: 16px;right:var(--mobile-offset);left:var(--mobile-offset);width:100%}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset)}[data-sonner-toaster][data-y-position=bottom]{bottom:20px}[data-sonner-toaster][data-y-position=top]{top:20px}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset);right:var(--mobile-offset);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);--error-text: hsl(358, 100%, 81%)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}
33
- `);function Ae(e){return e.label!==void 0}var Yn=3,Hn="32px",Un=4e3,Kn=356,Xn=14,qn=20,Jn=200;function Gn(...e){return e.filter(Boolean).join(" ")}var Zn=e=>{var n,r,o,i,u,h,c,d,p,m;let{invert:y,toast:s,unstyled:v,interacting:R,setHeights:w,visibleToasts:N,heights:b,index:x,toasts:Y,expanded:D,removeToast:$,defaultRichColors:W,closeButton:B,style:q,cancelButtonStyle:K,actionButtonStyle:X,className:z="",descriptionClassName:Q="",duration:E,position:J,gap:F,loadingIcon:H,expandByDefault:re,classNames:P,icons:ee,closeButtonAriaLabel:me="Close toast",pauseWhenPageIsHidden:I,cn:j}=e,[S,ae]=l.useState(!1),[te,U]=l.useState(!1),[se,le]=l.useState(!1),[he,be]=l.useState(!1),[et,Re]=l.useState(0),[tt,We]=l.useState(0),je=l.useRef(null),pe=l.useRef(null),Ve=x===0,Ye=x+1<=N,oe=s.type,Ce=s.dismissible!==!1,nt=s.className||"",ze=s.descriptionClassName||"",$e=l.useMemo(()=>b.findIndex(_=>_.toastId===s.id)||0,[b,s.id]),rt=l.useMemo(()=>{var _;return(_=s.closeButton)!=null?_:B},[s.closeButton,B]),De=l.useMemo(()=>s.duration||E||Un,[s.duration,E]),Pe=l.useRef(0),ge=l.useRef(0),He=l.useRef(0),we=l.useRef(null),[Fe,Le]=J.split("-"),Ue=l.useMemo(()=>b.reduce((_,M,A)=>A>=$e?_:_+M.height,0),[b,$e]),Ke=Dn(),at=s.invert||y,Be=oe==="loading";ge.current=l.useMemo(()=>$e*F+Ue,[$e,Ue]),l.useEffect(()=>{ae(!0)},[]),l.useLayoutEffect(()=>{if(!S)return;let _=pe.current,M=_.style.height;_.style.height="auto";let A=_.getBoundingClientRect().height;_.style.height=M,We(A),w(ie=>ie.find(ue=>ue.toastId===s.id)?ie.map(ue=>ue.toastId===s.id?{...ue,height:A}:ue):[{toastId:s.id,height:A,position:s.position},...ie])},[S,s.title,s.description,w,s.id]);let ye=l.useCallback(()=>{U(!0),Re(ge.current),w(_=>_.filter(M=>M.toastId!==s.id)),setTimeout(()=>{$(s)},Jn)},[s,$,w,ge]);l.useEffect(()=>{if(s.promise&&oe==="loading"||s.duration===1/0||s.type==="loading")return;let _,M=De;return D||R||I&&Ke?(()=>{if(He.current<Pe.current){let A=new Date().getTime()-Pe.current;M=M-A}He.current=new Date().getTime()})():M!==1/0&&(Pe.current=new Date().getTime(),_=setTimeout(()=>{var A;(A=s.onAutoClose)==null||A.call(s,s),ye()},M)),()=>clearTimeout(_)},[D,R,re,s,De,ye,s.promise,oe,I,Ke]),l.useEffect(()=>{let _=pe.current;if(_){let M=_.getBoundingClientRect().height;return We(M),w(A=>[{toastId:s.id,height:M,position:s.position},...A]),()=>w(A=>A.filter(ie=>ie.toastId!==s.id))}},[w,s.id]),l.useEffect(()=>{s.delete&&ye()},[ye,s.delete]);function st(){return ee!=null&&ee.loading?l.createElement("div",{className:"sonner-loader","data-visible":oe==="loading"},ee.loading):H?l.createElement("div",{className:"sonner-loader","data-visible":oe==="loading"},H):l.createElement(Pn,{visible:oe==="loading"})}return l.createElement("li",{"aria-live":s.important?"assertive":"polite","aria-atomic":"true",role:"status",tabIndex:0,ref:pe,className:j(z,nt,P==null?void 0:P.toast,(n=s==null?void 0:s.classNames)==null?void 0:n.toast,P==null?void 0:P.default,P==null?void 0:P[oe],(r=s==null?void 0:s.classNames)==null?void 0:r[oe]),"data-sonner-toast":"","data-rich-colors":(o=s.richColors)!=null?o:W,"data-styled":!(s.jsx||s.unstyled||v),"data-mounted":S,"data-promise":!!s.promise,"data-removed":te,"data-visible":Ye,"data-y-position":Fe,"data-x-position":Le,"data-index":x,"data-front":Ve,"data-swiping":se,"data-dismissible":Ce,"data-type":oe,"data-invert":at,"data-swipe-out":he,"data-expanded":!!(D||re&&S),style:{"--index":x,"--toasts-before":x,"--z-index":Y.length-x,"--offset":`${te?et:ge.current}px`,"--initial-height":re?"auto":`${tt}px`,...q,...s.style},onPointerDown:_=>{Be||!Ce||(je.current=new Date,Re(ge.current),_.target.setPointerCapture(_.pointerId),_.target.tagName!=="BUTTON"&&(le(!0),we.current={x:_.clientX,y:_.clientY}))},onPointerUp:()=>{var _,M,A,ie;if(he||!Ce)return;we.current=null;let ue=Number(((_=pe.current)==null?void 0:_.style.getPropertyValue("--swipe-amount").replace("px",""))||0),Ne=new Date().getTime()-((M=je.current)==null?void 0:M.getTime()),Xe=Math.abs(ue)/Ne;if(Math.abs(ue)>=qn||Xe>.11){Re(ge.current),(A=s.onDismiss)==null||A.call(s,s),ye(),be(!0);return}(ie=pe.current)==null||ie.style.setProperty("--swipe-amount","0px"),le(!1)},onPointerMove:_=>{var M;if(!we.current||!Ce)return;let A=_.clientY-we.current.y,ie=_.clientX-we.current.x,ue=(Fe==="top"?Math.min:Math.max)(0,A),Ne=_.pointerType==="touch"?10:2;Math.abs(ue)>Ne?(M=pe.current)==null||M.style.setProperty("--swipe-amount",`${A}px`):Math.abs(ie)>Ne&&(we.current=null)}},rt&&!s.jsx?l.createElement("button",{"aria-label":me,"data-disabled":Be,"data-close-button":!0,onClick:Be||!Ce?()=>{}:()=>{var _;ye(),(_=s.onDismiss)==null||_.call(s,s)},className:j(P==null?void 0:P.closeButton,(i=s==null?void 0:s.classNames)==null?void 0:i.closeButton)},l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},l.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),l.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"}))):null,s.jsx||l.isValidElement(s.title)?s.jsx||s.title:l.createElement(l.Fragment,null,oe||s.icon||s.promise?l.createElement("div",{"data-icon":"",className:j(P==null?void 0:P.icon,(u=s==null?void 0:s.classNames)==null?void 0:u.icon)},s.promise||s.type==="loading"&&!s.icon?s.icon||st():null,s.type!=="loading"?s.icon||(ee==null?void 0:ee[oe])||Rn(oe):null):null,l.createElement("div",{"data-content":"",className:j(P==null?void 0:P.content,(h=s==null?void 0:s.classNames)==null?void 0:h.content)},l.createElement("div",{"data-title":"",className:j(P==null?void 0:P.title,(c=s==null?void 0:s.classNames)==null?void 0:c.title)},s.title),s.description?l.createElement("div",{"data-description":"",className:j(Q,ze,P==null?void 0:P.description,(d=s==null?void 0:s.classNames)==null?void 0:d.description)},s.description):null),l.isValidElement(s.cancel)?s.cancel:s.cancel&&Ae(s.cancel)?l.createElement("button",{"data-button":!0,"data-cancel":!0,style:s.cancelButtonStyle||K,onClick:_=>{var M,A;Ae(s.cancel)&&Ce&&((A=(M=s.cancel).onClick)==null||A.call(M,_),ye())},className:j(P==null?void 0:P.cancelButton,(p=s==null?void 0:s.classNames)==null?void 0:p.cancelButton)},s.cancel.label):null,l.isValidElement(s.action)?s.action:s.action&&Ae(s.action)?l.createElement("button",{"data-button":!0,"data-action":!0,style:s.actionButtonStyle||X,onClick:_=>{var M,A;Ae(s.action)&&(_.defaultPrevented||((A=(M=s.action).onClick)==null||A.call(M,_),ye()))},className:j(P==null?void 0:P.actionButton,(m=s==null?void 0:s.classNames)==null?void 0:m.actionButton)},s.action.label):null))};function Ct(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}var Qn=e=>{let{invert:n,position:r="bottom-right",hotkey:o=["altKey","KeyT"],expand:i,closeButton:u,className:h,offset:c,theme:d="light",richColors:p,duration:m,style:y,visibleToasts:s=Yn,toastOptions:v,dir:R=Ct(),gap:w=Xn,loadingIcon:N,icons:b,containerAriaLabel:x="Notifications",pauseWhenPageIsHidden:Y,cn:D=Gn}=e,[$,W]=l.useState([]),B=l.useMemo(()=>Array.from(new Set([r].concat($.filter(I=>I.position).map(I=>I.position)))),[$,r]),[q,K]=l.useState([]),[X,z]=l.useState(!1),[Q,E]=l.useState(!1),[J,F]=l.useState(d!=="system"?d:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),H=l.useRef(null),re=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),P=l.useRef(null),ee=l.useRef(!1),me=l.useCallback(I=>{var j;(j=$.find(S=>S.id===I.id))!=null&&j.delete||fe.dismiss(I.id),W(S=>S.filter(({id:ae})=>ae!==I.id))},[$]);return l.useEffect(()=>fe.subscribe(I=>{if(I.dismiss){W(j=>j.map(S=>S.id===I.id?{...S,delete:!0}:S));return}setTimeout(()=>{$t.flushSync(()=>{W(j=>{let S=j.findIndex(ae=>ae.id===I.id);return S!==-1?[...j.slice(0,S),{...j[S],...I},...j.slice(S+1)]:[I,...j]})})})}),[]),l.useEffect(()=>{if(d!=="system"){F(d);return}d==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?F("dark"):F("light")),typeof window<"u"&&window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",({matches:I})=>{F(I?"dark":"light")})},[d]),l.useEffect(()=>{$.length<=1&&z(!1)},[$]),l.useEffect(()=>{let I=j=>{var S,ae;o.every(te=>j[te]||j.code===te)&&(z(!0),(S=H.current)==null||S.focus()),j.code==="Escape"&&(document.activeElement===H.current||(ae=H.current)!=null&&ae.contains(document.activeElement))&&z(!1)};return document.addEventListener("keydown",I),()=>document.removeEventListener("keydown",I)},[o]),l.useEffect(()=>{if(H.current)return()=>{P.current&&(P.current.focus({preventScroll:!0}),P.current=null,ee.current=!1)}},[H.current]),$.length?l.createElement("section",{"aria-label":`${x} ${re}`,tabIndex:-1},B.map((I,j)=>{var S;let[ae,te]=I.split("-");return l.createElement("ol",{key:I,dir:R==="auto"?Ct():R,tabIndex:-1,ref:H,className:h,"data-sonner-toaster":!0,"data-theme":J,"data-y-position":ae,"data-x-position":te,style:{"--front-toast-height":`${((S=q[0])==null?void 0:S.height)||0}px`,"--offset":typeof c=="number"?`${c}px`:c||Hn,"--width":`${Kn}px`,"--gap":`${w}px`,...y},onBlur:U=>{ee.current&&!U.currentTarget.contains(U.relatedTarget)&&(ee.current=!1,P.current&&(P.current.focus({preventScroll:!0}),P.current=null))},onFocus:U=>{U.target instanceof HTMLElement&&U.target.dataset.dismissible==="false"||ee.current||(ee.current=!0,P.current=U.relatedTarget)},onMouseEnter:()=>z(!0),onMouseMove:()=>z(!0),onMouseLeave:()=>{Q||z(!1)},onPointerDown:U=>{U.target instanceof HTMLElement&&U.target.dataset.dismissible==="false"||E(!0)},onPointerUp:()=>E(!1)},$.filter(U=>!U.position&&j===0||U.position===I).map((U,se)=>{var le,he;return l.createElement(Zn,{key:U.id,icons:b,index:se,toast:U,defaultRichColors:p,duration:(le=v==null?void 0:v.duration)!=null?le:m,className:v==null?void 0:v.className,descriptionClassName:v==null?void 0:v.descriptionClassName,invert:n,visibleToasts:s,closeButton:(he=v==null?void 0:v.closeButton)!=null?he:u,interacting:Q,position:I,style:v==null?void 0:v.style,unstyled:v==null?void 0:v.unstyled,classNames:v==null?void 0:v.classNames,cancelButtonStyle:v==null?void 0:v.cancelButtonStyle,actionButtonStyle:v==null?void 0:v.actionButtonStyle,removeToast:me,toasts:$.filter(be=>be.position==U.position),heights:q.filter(be=>be.position==U.position),setHeights:K,expandByDefault:i,gap:w,loadingIcon:N,expanded:X,pauseWhenPageIsHidden:Y,cn:D})}))})):null};function er({children:e}){function n(r){Wn.custom(o=>a.jsx(bt,{...r}))}return a.jsxs(yt.Provider,{value:{showToast:n},children:[a.jsx(Qn,{}),e]})}k.Badge=Dt,k.BreadcrumbContainer=mn,k.BreadcrumbLink=pn,k.Button=Yt,k.Checkbox=Ut,k.Divider=Ft,k.DrawerContainer=vn,k.DrawerHeader=bn,k.DrawerProvider=En,k.FormController=Ht,k.FormError=Kt,k.FormLabel=Xt,k.IconButton=qt,k.Input=un,k.ModalContainer=yn,k.ModalFooter=xn,k.ModalHeader=wn,k.ModalProvider=Sn,k.Pagination=gn,k.Popover=kn,k.Select=fn,k.Skeleton=Lt,k.TableBody=Bt,k.TableCaption=Mt,k.TableContainer=At,k.TableFooter=Wt,k.TableHeader=Vt,k.Textarea=hn,k.Toast=bt,k.ToastProvider=er,k.Tooltip=Cn,k.useAutomation=Nn,k.useDrawer=_n,k.useModal=jn,k.useScopedParams=pt,k.useToast=xt,Object.defineProperty(k,Symbol.toStringTag,{value:"Module"})});
32
+ <%s key={someKey} {...props} />`,ot,Se,dr,Se),St[Se+ot]=!0}}return t===o?or(ne):sr(ne),ne}}function ir(t,f,g){return Et(t,f,g,!0)}function lr(t,f,g){return Et(t,f,g,!1)}var cr=lr,ur=ir;Oe.Fragment=o,Oe.jsx=cr,Oe.jsxs=ur}()),Oe}process.env.NODE_ENV==="production"?qe.exports=Pt():qe.exports=Tt();var s=qe.exports;function Me(e,n){return n?s.jsx(n,{size:e,strokeWidth:2.5}):s.jsx(s.Fragment,{})}function ct(e,n){return[...new Array(n-e)].map((r,o)=>e+o+1).filter(r=>r>0)}function It(e,n,r){return e>=r?[]:ct(e+1,e+n)}function Ot(e,n){return e<=1?[]:ct(e-1-n,e-1)}function zt(e,n,r){if(!e)return s.jsx(s.Fragment,{});if(typeof e=="string")return s.jsx("p",{className:r,children:e});const o=e;return s.jsx("p",{className:r,children:s.jsx(o,{color:"var(--secondary-600)",size:n,strokeWidth:2.5})})}function Dt(e){const{variant:n="ghost",scheme:r="primary",size:o="md",leftIcon:i,rightIcon:c,className:h="",children:u,...d}=e,m={md:12,lg:14}[o],b=`arkyn_badge ${n} ${r} ${o} ${h}`;return s.jsxs("div",{className:b.trim(),...d,children:[Me(m,i),u,Me(m,i)]})}function Ft(e){const{className:n,orientation:r="horizontal",...o}=e,i=`arkyn_divider ${r} ${n}`;return s.jsx("div",{className:i,...o})}function Lt(e){const{className:n,...r}=e,o=`arkyn_skeleton ${n}`;return s.jsx("aside",{className:o.trim(),...r})}function Bt(e){const{className:n,...r}=e,o=`arkyn_table_body ${n}`;return s.jsx("tbody",{className:o.trim(),...r})}function Mt(e){const{className:n,children:r,...o}=e,i=`arkyn_table_caption ${n}`;return s.jsx("caption",{className:i.trim(),...o,children:s.jsx("div",{className:"arkyn_table_caption-content",children:r})})}function At(e){const{children:n,className:r,...o}=e,i=`arkyn_table_container ${r}`;return s.jsx("div",{className:i.trim(),...o,children:s.jsx("table",{children:n})})}function Wt(e){const{className:n,children:r,...o}=e,i=`arkyn_table_footer ${n}`;return s.jsxs("tfoot",{className:i.trim(),...o,children:[s.jsx("tr",{className:"spacing-row"}),s.jsx("tr",{children:s.jsx("th",{colSpan:100,children:s.jsx("div",{className:"arkyn_table_footer-content",children:r})})})]})}function Vt(e){const{className:n,children:r,...o}=e,i=`arkyn_table_header ${n}`;return s.jsxs("thead",{className:i.trim(),...o,children:[s.jsx("tr",{children:r}),s.jsx("tr",{className:"spacing-row"})]})}function Yt(e){const{isLoading:n=!1,scheme:r="primary",variant:o="solid",loadingText:i,size:c="md",leftIcon:h,rightIcon:u,disabled:d,className:p="",children:m,...b}=e,v={xs:12,sm:16,md:20,lg:24}[c],S=`arkyn_button loading_text_${!!i} ${o} ${r} ${c} loading_${n} ${p}`;return s.jsxs("button",{className:S,disabled:d||n,...b,children:[s.jsxs("div",{className:"arkyn_button-spinner",children:[s.jsx(G.Loader2,{size:v,strokeWidth:2.5}),i&&i]}),s.jsxs("div",{className:"arkyn_button-content",children:[Me(v,h),m,Me(v,u)]})]})}const ut=l.createContext({});function Ht(e){var m,b;const n=Ee.useActionData(),{children:r,className:o,...i}=e,c=l.useRef(null),h=((m=c.current)==null?void 0:m.name)||"",u=((b=n==null?void 0:n.fieldErrors)==null?void 0:b[h])||null,d=l.useId(),p=`arkyn_form_controller ${o}`;return s.jsx(ut.Provider,{value:{error:u,id:d,inputRef:c},children:s.jsx("section",{className:p.trim(),...i,children:r})})}function xe(){return l.useContext(ut)}function Ut(e){const{name:n,className:r="",size:o="md",isError:i,defaultChecked:c=!1,checked:h=null,onCheck:u,value:d,...p}=e,{id:m,inputRef:b,error:a}=xe(),v=i||!!a,[S,x]=l.useState(c||!1),N=typeof h=="boolean"?h:S,y=`arkyn_checkbox ${o} ${v?"error":""} ${N?"checked":""} ${r}`;function w(){const Y=S;x(!Y),u&&u(Y?"":d||"checked")}return s.jsxs("button",{type:"button",id:m,className:y,onClick:w,...p,children:[s.jsx("input",{type:"hidden",name:n,ref:b,value:N?d||"checked":""}),s.jsx(G.Check,{})]})}function Kt(e){const{children:n,className:r,...o}=e,i=`arkyn_form_error ${r}`,{error:c}=xe();return n?s.jsx("strong",{className:i.trim(),...o,children:n}):c?s.jsx("strong",{className:i.trim(),...o,children:c}):s.jsx(s.Fragment,{})}function Xt(e){const{showAsterisk:n=!1,className:r="",...o}=e,{id:i}=xe(),h=`arkyn_form_label ${n?"show-asterisk":""} ${r}`;return s.jsx("label",{...o,className:h.trim(),htmlFor:i})}function qt(e){const{isLoading:n=!1,scheme:r="primary",variant:o="solid",size:i="md",icon:c,disabled:h,className:u="",...d}=e,p={xs:12,sm:16,md:20,lg:24},m=`arkyn_icon_button ${o} ${r} ${i} loading_${n} ${u}`;return s.jsxs("button",{disabled:h||n,className:m.trim(),...d,children:[s.jsx("div",{className:"arkyn_icon_button-spinner",children:s.jsx(G.Loader2,{size:p[i],strokeWidth:2.5})}),s.jsx("div",{className:"arkyn_icon_button-content",children:s.jsx(c,{size:p[i],strokeWidth:2.5})})]})}function Ce(e,n,r){if(!e)return s.jsx(s.Fragment,{});if(typeof e=="string")return s.jsx("p",{className:r,children:e});const o=e;return s.jsx("p",{className:r,children:s.jsx(o,{color:"var(--secondary-600)",size:n,strokeWidth:2.5})})}function Je(e){return e&&e.replace(/[^0-9]/g,"")}function dt(e,n){let r="",o=0;return Array.from(e).forEach((i,c)=>{n[c+o].match(/[0-9]/)||(r+=n[c+o],o++),r+=i}),r}function ft(e){return e.length>11?"CNPJ":"CPF"}const Ge={CPF:"999.999.999-999",CNPJ:"99.999.999/9999-99"},ht=Je(Ge.CNPJ).length;function Jt(e,n){const{isLoading:r,isError:o,size:i="md",className:c="",variant:h="solid",prefix:u,sufix:d,leftIcon:p,rightIcon:m,disabled:b,defaultValue:a,readOnly:v,onFocus:S,onBlur:x,title:N,style:y,onChange:w,...Y}=e;function D(J){let F=Je(J);const H=ft(F);if(!(F.length>ht))return F=dt(F,Ge[H]),F}const R=m?"right":"left",z=`arkyn_input ${u?"hasPrefix":""} ${d?"hasSufix":""} ${h} ${i} ${b||v||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${c}`,E={md:20,lg:20}[i];return{isLoading:r,className:z,prefix:Ce(u,E,"prefix"),sufix:Ce(d,E,"sufix"),LeftIcon:p,RightIcon:m,defaultValue:D(a||""),disabled:b,readOnly:v,onFocus:S,onBlur:x,title:N,style:y,onChange:w,loadingPosition:R,iconSize:E,Spinner:s.jsx(G.Loader2,{className:"spinner",size:E,strokeWidth:2.5}),...Y}}function Gt(e){const[n,r]=l.useState(!1),o=l.useRef(null),{inputRef:i,id:c,error:h}=xe(),u=i||o,d=e.isError||!!h,{disabled:p,title:m,style:b,className:a,prefix:v,sufix:S,iconSize:x,loadingPosition:N,isLoading:y,LeftIcon:w,readOnly:Y,onFocus:D,onBlur:R,RightIcon:W,Spinner:B,onChange:q,value:K,defaultValue:X,...z}=Jt({...e,id:c,isError:d},n),[Q,E]=l.useState(X),J=w&&!y,F=W&&!y,H=N==="left"&&y,re=N==="right"&&y;function P(){p||!(u!=null&&u.current)||(r(!0),u.current.focus())}function ee(j){let $=Je(j.target.value);const ae=ft($);$.length>ht||($=dt($,Ge[ae]),j.target.value=$,E($),q&&q(j))}function me(j){r(!0),D&&D(j)}function I(j){r(!1),R&&R(j)}return s.jsxs("section",{title:m,style:b,onClick:P,className:a,children:[v,H&&B,J&&s.jsx(w,{size:x,strokeWidth:2.5}),s.jsx("input",{disabled:p||y,readOnly:Y,ref:u,value:K||Q,onFocus:me,onChange:ee,onBlur:I,...z}),F&&s.jsx(W,{size:x,strokeWidth:2.5}),re&&B,S]})}function Zt(e,n){const{isLoading:r,isError:o,size:i="md",className:c="",variant:h="solid",prefix:u,sufix:d,leftIcon:p,rightIcon:m,disabled:b,readOnly:a,onFocus:v,onBlur:S,title:x,style:N,showCents:y=!1,max:w=1e9,onChange:Y,...D}=e,R=m?"right":"left",z=`arkyn_input ${u?"hasPrefix":""} ${d?"hasSufix":""} ${h} ${i} ${b||a||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${c}`,E={md:20,lg:20}[i];return{isLoading:r,className:z,prefix:Ce(u,E,"prefix"),sufix:Ce(d,E,"sufix"),LeftIcon:p,RightIcon:m,disabled:b,readOnly:a,onFocus:v,onBlur:S,title:x,style:N,max:w,onChange:Y,showCents:y,loadingPosition:R,iconSize:E,Spinner:s.jsx(G.Loader2,{className:"spinner",size:E,strokeWidth:2.5}),...D}}const Qt=/^[1-9]{1}$/,en=/^[0-9]{1}$/,mt=8;function tn(e,n){if(e===0)return"";const r=(e/100).toLocaleString("pt-BR",{style:"currency",currency:"BRL"});return n?r:r.replace("R$","").trim()}function nn(e){const{currencyValue:n,event:r,max:o,setCurrencyValue:i}=e,{key:c,keyCode:h}=r;if(n===0&&!Qt.test(c)||n!==0&&!en.test(c)&&h!==mt)return;const u=n.toString();let d;if(h!==mt){const p=n===0?c:`${u}${c}`;d=Number.parseInt(p,10)}else{const p=u.slice(0,-1);d=p===""?0:Number.parseInt(p,10)}d>Number(o)||i(d)}function rn(e){const[n,r]=l.useState(!1),o=l.useRef(null),{inputRef:i,id:c,error:h}=xe(),u=i||o,d=e.isError||!!h,{disabled:p,title:m,style:b,className:a,prefix:v,sufix:S,iconSize:x,loadingPosition:N,isLoading:y,LeftIcon:w,readOnly:Y,onFocus:D,onBlur:R,RightIcon:W,Spinner:B,value:q,max:K,onKeyDown:X,onChange:z,showCents:Q,defaultValue:E,...J}=Zt({...e,id:c,isError:d},n),[F,H]=l.useState(E*100||0),re=w&&!y,P=W&&!y,ee=N==="left"&&y,me=N==="right"&&y;function I(){p||!(u!=null&&u.current)||(r(!0),u.current.focus())}function j(te){nn({currencyValue:F,event:te,max:K,setCurrencyValue:H}),z&&z(F/100),X&&X(te)}function $(te){r(!0),D&&D(te)}function ae(te){r(!1),R&&R(te)}return s.jsxs("section",{title:m,style:b,onClick:I,className:a,children:[v,ee&&B,re&&s.jsx(w,{size:x,strokeWidth:2.5}),s.jsx("input",{value:tn(q||F,Q),onKeyDown:j,disabled:p||y,readOnly:Y,ref:u,onFocus:$,onBlur:ae,onChange:()=>{},...J}),me&&B,P&&s.jsx(W,{size:x,strokeWidth:2.5}),S]})}function an(e,n){const{isLoading:r,isError:o,size:i="md",className:c="",variant:h="solid",prefix:u,sufix:d,leftIcon:p,rightIcon:m,disabled:b,readOnly:a,onFocus:v,onBlur:S,title:x,style:N,onChange:y,showMask:w=!1,type:Y,...D}=e,R=m?"right":"left",z=`arkyn_input ${u?"hasPrefix":""} ${d?"hasSufix":""} ${h} ${i} ${b||a||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${c}`,E={md:20,lg:20}[i];return{isLoading:r,className:z,prefix:Ce(u,E,"prefix"),sufix:Ce(d,E,"sufix"),LeftIcon:p,RightIcon:m,disabled:b,readOnly:a,onFocus:v,onBlur:S,title:x,style:N,onChange:y,loadingPosition:R,iconSize:E,showMask:w,Spinner:s.jsx(G.Loader2,{className:"spinner",size:E,strokeWidth:2.5}),...D}}const sn=l.forwardRef((e,n)=>s.jsx("input",{ref:n,...e}));function on(e){const[n,r]=l.useState(!1),o=l.useRef(null),{inputRef:i,id:c,error:h}=xe(),u=i||o,d=e.isError||!!h,{disabled:p,title:m,style:b,className:a,prefix:v,sufix:S,iconSize:x,loadingPosition:N,isLoading:y,LeftIcon:w,readOnly:Y,onFocus:D,onBlur:R,RightIcon:W,Spinner:B,...q}=an({...e,id:c,isError:d},n),K=w&&!y,X=W&&!y,z=N==="left"&&y,Q=N==="right"&&y;function E(){p||!(u!=null&&u.current)||(r(!0),u.current.focus())}function J(H){r(!0),D&&D(H)}function F(H){r(!1),R&&R(H)}return s.jsxs("section",{title:m,style:b,onClick:E,className:a,children:[v,z&&B,K&&s.jsx(w,{size:x,strokeWidth:2.5}),s.jsx($t.InputMask,{component:sn,ref:u,onFocus:J,onBlur:F,...q}),X&&s.jsx(W,{size:x,strokeWidth:2.5}),Q&&B,S]})}function ln(e,n){const{isLoading:r,isError:o,size:i="md",className:c="",variant:h="solid",prefix:u,sufix:d,leftIcon:p,rightIcon:m,disabled:b,readOnly:a,onFocus:v,onBlur:S,title:x,style:N,onChange:y,...w}=e,Y=m?"right":"left",K=`arkyn_input ${u?"hasPrefix":""} ${d?"hasSufix":""} ${h} ${i} ${b||a||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${c}`,z={md:20,lg:20}[i];return{isLoading:r,className:K,prefix:Ce(u,z,"prefix"),sufix:Ce(d,z,"sufix"),LeftIcon:p,RightIcon:m,disabled:b,readOnly:a,onFocus:v,onBlur:S,title:x,style:N,onChange:y,loadingPosition:Y,iconSize:z,Spinner:s.jsx(G.Loader2,{className:"spinner",size:z,strokeWidth:2.5}),...w}}function cn(e){const[n,r]=l.useState(!1),o=l.useRef(null),{inputRef:i,id:c,error:h}=xe(),u=i||o,d=e.isError||!!h,{disabled:p,title:m,style:b,className:a,prefix:v,sufix:S,iconSize:x,loadingPosition:N,isLoading:y,LeftIcon:w,readOnly:Y,onFocus:D,onBlur:R,RightIcon:W,type:B,Spinner:q,...K}=ln({...e,id:c,isError:d},n),X=w&&!y,z=W&&!y,Q=N==="left"&&y,E=N==="right"&&y;function J(){p||!(u!=null&&u.current)||(r(!0),u.current.focus())}function F(re){r(!0),D&&D(re)}function H(re){r(!1),R&&R(re)}return B==="hidden"?s.jsx("input",{type:"hidden",ref:u,...K}):s.jsxs("section",{title:m,style:b,onClick:J,className:a,children:[v,Q&&q,X&&s.jsx(w,{size:x,strokeWidth:2.5}),s.jsx("input",{disabled:p||y,readOnly:Y,ref:u,onFocus:F,onBlur:H,type:B,...K}),z&&s.jsx(W,{size:x,strokeWidth:2.5}),E&&q,S]})}function un(e){return e.type==="currency"?s.jsx(rn,{...e}):e.type==="masked"?s.jsx(on,{...e}):e.type==="cpf-cnpj"?s.jsx(Gt,{...e}):s.jsx(cn,{...e})}function dn(e,n){const{isLoading:r,isError:o,size:i="md",className:c="",variant:h="solid",prefix:u,leftIcon:d,disabled:p,readOnly:m,onFocus:b,onBlur:a,title:v,style:S,closeOnSelect:x=!0,...N}=e,R=`arkyn_select ${u?"hasPrefix":""} ${h} ${i} ${p||m||r?"opacity":""} ${o?"errored":""} ${n?"focused":""} ${c}`,B={md:20,lg:20}[i];return{isLoading:r,className:R,prefix:zt(u,B,"prefix"),LeftIcon:d,disabled:p,readOnly:m,onFocus:b,onBlur:a,title:v,closeOnSelect:x,style:S,iconSize:B,Spinner:s.jsx(G.Loader2,{className:"spinner",size:B,strokeWidth:2.5}),...N}}function fn(e){var U;const[n,r]=l.useState(!1),{inputRef:o,id:i,error:c}=xe(),h=l.useRef(null),u=o||h,d=e.isError||!!c,{disabled:p,title:m,style:b,className:a,prefix:v,iconSize:S,isLoading:x,LeftIcon:N,value:y=null,defaultValue:w="",readOnly:Y,onFocus:D,onBlur:R,Spinner:W,name:B,placeholder:q,onSelect:K,options:X,optionMaxHeight:z,closeOnSelect:Q,...E}=dn({...e,id:i,isError:d},n),[J,F]=l.useState(w),[H,re]=l.useState("");function P(){p||!(u!=null&&u.current)||(r(!0),u.current.focus())}function ee(se){r(!0),D&&D(se)}function me(){r(!1),R&&u.current&&u.current.blur()}function I(se){const{label:le,value:he}=se;F(J!==he?he:""),K&&K({label:le,value:he}),Q&&(u.current.blur(),r(!1),console.log("fecha"))}const j=typeof y=="string"?y:J,$=((U=X.find(se=>se.value===j))==null?void 0:U.label)||"",ae=()=>{if(!n&&$)return!0;if(!n&&!$)return!1;if(n&&$)return!0;if(n&&!$)return!1},te=X.filter(se=>!0);return s.jsxs(s.Fragment,{children:[s.jsxs("section",{title:m,style:b,onClick:P,className:`${a} placeholder_dark_${ae()}`,children:[v,N&&s.jsx(N,{size:S,strokeWidth:2.5}),s.jsx("input",{disabled:p||x,readOnly:!0,value:H||"",placeholder:$||q,onFocus:ee,onBlur:()=>re(""),...E}),s.jsx("input",{type:"hidden",ref:u,name:B,value:j||"",readOnly:!0}),n&&s.jsxs("div",{className:"arkyn_select_content",style:{overflow:"auto",maxHeight:z},children:[te.map(({label:se,value:le})=>s.jsxs("div",{onClick:()=>I({label:se,value:le}),className:j===le?"arkyn_select_option active":"arkyn_select_option",children:[se," ",s.jsx(G.Check,{})]},le)),te.length<=0&&s.jsx("p",{children:"Sem opções disponíveis"})]}),!x&&s.jsx(G.ChevronDown,{className:"arkyn_select_arrow",size:S,strokeWidth:2.5}),x&&W]}),n&&s.jsx("aside",{className:"arkyn_select_overlay",onClick:me})]})}function hn(e){const{variant:n="solid",size:r="md",className:o,disabled:i=!1,readOnly:c=!1,onFocus:h,onBlur:u,title:d,style:p,...m}=e,[b,a]=l.useState(!1),{inputRef:v,id:S,error:x}=xe(),N=l.useRef(null),y=v||N,Y=e.isError||!!x?"errored":"",W=`arkyn_textarea ${n} ${r} ${i||c?"opacity":""} ${Y} ${b?"focused":""} ${o}`;function B(){i||!(y!=null&&y.current)||(a(!0),y.current.focus())}function q(X){a(!0),h&&h(X)}function K(X){a(!1),u&&u(X)}return s.jsx("section",{title:d,style:p,onClick:B,className:W,children:s.jsx("textarea",{id:S,disabled:i,readOnly:c,ref:y,onFocus:q,onBlur:K,...m})})}function mn(e){const{className:n="",...r}=e,o=`arkyn_breadcrumb_container ${n}`;return s.jsx("nav",{className:o,...r})}function pn(e){const{pathname:n}=Ee.useLocation(),{className:r="",disabled:o=!1,children:i,to:c,...h}=e,d=`arkyn_breadcrumb_link ${n===c?"active":"inactive"} ${r}`;return o?s.jsxs("p",{className:d,children:[s.jsx(G.ChevronRight,{size:14,strokeWidth:2.5}),i]}):s.jsxs(Ee.Link,{to:c,className:d,...h,children:[s.jsx(G.ChevronRight,{size:14,strokeWidth:2.5}),i]})}function pt(e=""){const n=Ee.useLocation(),r=new URLSearchParams(n.search),o=e?`${e}:`:"",i=c=>{Object.entries(c).forEach(([h,u])=>{u===void 0?r.delete(`${o}${h}`):r.set(`${o}${h}`,String(u))})};return{getParam:c=>r.get(`${o}${c}`),getScopedSearch:c=>{i(c);let h=r.toString();return h&&(h="?"+h),h}}}function gn(e){const{scope:n,totalCountRegisters:r,perPageKey:o="per_page",pageKey:i="page",siblingsCount:c=2,...h}=e,u=Ee.useNavigate(),{getParam:d,getScopedSearch:p}=pt(n),m=Number(d(i))||1,b=Number(d(o))||20,a=Math.ceil(r/b),v=Ot(m,c),S=It(m,c,a);function x(N){u(p({page:N}))}return s.jsxs("div",{className:"arkyn_pagination",...h,children:[s.jsx("button",{className:"arkyn_pagination-icon_button",disabled:m<=1,onClick:()=>x(m-1),children:s.jsx(G.ChevronLeft,{})}),m>1+c&&s.jsxs(s.Fragment,{children:[s.jsx("button",{className:"arkyn_pagination-page_button",onClick:()=>x(1),children:"1"}),m>2+c&&s.jsx("button",{disabled:!0,className:"arkyn_pagination-spread",children:s.jsx(G.Ellipsis,{})})]}),v.map((N,y)=>s.jsx("button",{onClick:()=>x(N),className:"arkyn_pagination-page_button",children:N},y)),s.jsx("button",{className:"arkyn_pagination-current",disabled:!0,children:m}),S.map((N,y)=>s.jsx("button",{onClick:()=>x(N),className:"arkyn_pagination-page_button",children:N},y)),m+c<a&&s.jsxs(s.Fragment,{children:[m+1+c<a&&s.jsx("button",{disabled:!0,className:"arkyn_pagination-spread",children:s.jsx(G.Ellipsis,{})}),s.jsx("button",{className:"arkyn_pagination-page_button",onClick:()=>x(a),children:a})]}),s.jsx("button",{className:"arkyn_pagination-icon_button",disabled:m>=a,onClick:()=>x(m+1),children:s.jsx(G.ChevronRight,{})})]})}function vn(e){const{children:n,value:r,className:o,...i}=e,c=`arkyn_tab_button ${e.defaultActive?"active":""} ${o||""}`;return s.jsx("button",{className:c.trim(),...i,children:n})}function bn(e){const{children:n,onClick:r,className:o,...i}=e,c=l.useRef(null),h=`arkyn_tab_container ${o||""}`,[u,d]=l.useState({width:"0px",left:"0px",transition:"none"}),p=(b,a)=>{const v=b.getBoundingClientRect(),S=c.current.getBoundingClientRect();d({transition:a?void 0:"none",width:`${v.width}px`,left:`${v.left-S.left}px`})};l.useLayoutEffect(()=>{const b=c.current;if(!b)return;let a=null;a=b.querySelector("button.active"),a&&p(a)},[]);const m=b=>{const a=b.target,v=c.current;a&&v&&v.contains(a)&&(v.querySelectorAll("button").forEach(x=>x.classList.remove("active")),a.classList.add("active"),p(a,!0),r&&r(a.value))};return s.jsxs("nav",{ref:c,onClick:m,className:h.trim(),...i,children:[n,s.jsx("div",{className:"active-line",style:u})]})}const gt=l.createContext({});function yn(e){const{isVisibled:n,makeInvisible:r,orientation:o="left",children:i,className:c,...h}=e,u=o==="left"?"-100%":"100%",p=`arkyn_drawer_container ${o} ${n?"visible":""} ${c}`;return s.jsx(gt.Provider,{value:{makeInvisible:r},children:s.jsx(_e.AnimatePresence,{children:n&&s.jsxs("aside",{className:p.trim(),...h,children:[s.jsx(_e.motion.div,{className:"arkyn_drawer_container-overlay",transition:{duration:.15,ease:"easeOut"},initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},onClick:r}),s.jsx(_e.motion.div,{className:"arkyn_drawer_container-content",transition:{ease:"easeOut",duration:.15},initial:{transform:`translateX(${u})`},animate:{transform:"translateX(0px)"},exit:{transform:`translateX(${u})`},children:i})]})})})}function xn(e){const{showCloseButton:n=!0,className:r,children:o,...i}=e,{makeInvisible:c}=l.useContext(gt),h=`arkyn_drawer_header ${r}`;return s.jsxs("header",{className:h.trim(),...i,children:[o,n&&s.jsx("button",{className:"arkyn_drawer_header-close_button",type:"button",onClick:c,"aria-label":"Close drawer",children:s.jsx(G.X,{size:24})})]})}const vt=l.createContext({});function wn(e){const{isVisibled:n,makeInvisible:r,children:o,className:i="",...c}=e,u=`arkyn_modal_container ${n?"visible":""} ${i}`;return s.jsx(vt.Provider,{value:{makeInvisible:r},children:s.jsx(_e.AnimatePresence,{children:n&&s.jsxs("aside",{className:u.trim(),...c,children:[s.jsx(_e.motion.div,{className:"arkyn_modal_container-overlay",transition:{duration:.15,ease:"easeOut"},initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},onClick:r}),s.jsx(_e.motion.div,{className:"arkyn_modal_container-content",transition:{duration:.15,ease:"easeOut"},initial:{opacity:0,scale:.75},animate:{opacity:1,scale:1},exit:{opacity:0,scale:0},children:o})]})})})}function Cn(e){const{alignment:n="right",className:r,...o}=e,i=`arkyn_modal_footer ${n} ${r}`;return s.jsx("footer",{className:i.trim(),...o})}function kn(e){const{showCloseButton:n=!0,className:r,children:o,...i}=e,{makeInvisible:c}=l.useContext(vt),h=`arkyn_modal_header ${r}`;return s.jsxs("header",{className:h.trim(),...i,children:[o,n&&s.jsx("button",{type:"button",onClick:c,"aria-label":"Close modal button",className:"arkyn_modal_header-close_button",children:s.jsx(G.X,{size:24})})]})}function Nn(e){const{children:n,button:r,closeOnClick:o,orientation:i="bottom-left"}=e,[c,h]=l.useState(!1),u=`arkyn_popover ${i} ${c?"show":""}`;function d(){c||h(!0)}return s.jsxs("div",{className:u,onClick:d,children:[r,s.jsx(_e.motion.div,{style:{visibility:c?"visible":"hidden"},transition:{ease:"easeOut",duration:0},initial:{opacity:0},animate:{opacity:c?1:0},exit:{opacity:0},onClick:()=>o&&h(!1),className:"arkyn_popover-content",children:n}),c&&s.jsx("div",{onClick:()=>h(!1),className:"arkyn_popover-overlay"})]})}function bt(e){const{message:n,title:r,type:o,size:i="lg"}=e,c=`arkyn_toast ${o} ${i}`;function h(){switch(o){case"info":return s.jsx(G.Info,{});case"success":return s.jsx(G.CheckCircle2,{});case"danger":return s.jsx(G.XCircle,{});case"warning":return s.jsx(G.AlertCircle,{});default:return s.jsx(G.Info,{})}}return s.jsxs("aside",{className:c,children:[s.jsxs("div",{children:[s.jsx("div",{className:"bg"}),s.jsx(h,{})]}),s.jsxs("p",{children:[s.jsx("strong",{title:r,children:r}),s.jsx("span",{children:n})]})]})}function _n(e){const{text:n,size:r="lg",children:o,orientation:i="top",className:c,...h}=e,u=`arkyn_tooltip ${r} ${i} ${c}`;return s.jsxs("div",{className:u.trim(),...h,children:[o,s.jsx("div",{className:"arkyn_tooltip-text",children:n})]})}const Ze=l.createContext({}),yt=l.createContext({});function xt(){const e=l.useContext(yt);if(Object.entries(e).length===0)throw new Error("useToast must be used within a Provider");return e}function wt(e){return e&&typeof e.title=="string"&&typeof e.message=="string"&&(e.size===void 0||e.size==="md"||e.size==="lg")&&(e.type==="info"||e.type==="success"||e.type==="danger"||e.type==="warning")}function jn(){const e=Ee.useActionData(),{closeModal:n}=l.useContext(Ze),{showToast:r}=xt();l.useEffect(()=>{const o=e==null?void 0:e.closeModalKey;o&&n(o)},[e]),l.useEffect(()=>{const o=e==null?void 0:e.toast,i=e==null?void 0:e.message;wt(o)&&r(o),!wt(o)&&i&&r({message:i,title:"Atenção!",type:"warning"})},[e])}const Ct=l.createContext({});function Sn(e){const n=l.useContext(Ct);if(Object.entries(n).length===0)throw new Error("useDrawer must be used within a Provider");if(e){const{drawerData:r,drawerIsOpen:o,openDrawer:i,closeDrawer:c}=n,h=o(e),u=r(e);return{drawerIsOpen:h,drawerData:u,openDrawer:m=>i(e,m),closeDrawer:()=>c(e)}}else return n}function En(e){const n=l.useContext(Ze);if(Object.entries(n).length===0)throw new Error("useModal must be used within a Provider");if(e){const{modalData:r,modalIsOpen:o,openModal:i,closeModal:c}=n,h=o(e),u=r(e);return{modalIsOpen:h,modalData:u,openModal:m=>i(e,m),closeModal:()=>c(e)}}else return n}function $n(e){const{children:n=!1}=e,[r,o]=l.useState([]);function i(d){return!!r.some(p=>p.key===d)}function c(d){var p;return(p=r.find(m=>m.key===d))==null?void 0:p.data}function h(d,p){const m=i(d);o(m?b=>[...b.filter(v=>v.key!==d),{key:d,data:p}]:[...r,{key:d,data:p}])}function u(d){o(r.filter(p=>p.key!==d))}return s.jsx(Ct.Provider,{value:{drawerIsOpen:i,drawerData:c,openDrawer:h,closeDrawer:u},children:n})}function Rn(e){const{children:n=!1}=e,[r,o]=l.useState([]);function i(d){return!!r.some(p=>p.key===d)}function c(d){var p;return(p=r.find(m=>m.key===d))==null?void 0:p.data}function h(d,p){const m=i(d);o(m?b=>[...b.filter(v=>v.key!==d),{key:d,data:p}]:[...r,{key:d,data:p}])}function u(d){o(r.filter(p=>p.key!==d))}return s.jsx(Ze.Provider,{value:{modalIsOpen:i,modalData:c,openModal:h,closeModal:u},children:n})}var Pn=e=>{switch(e){case"success":return On;case"info":return Dn;case"warning":return zn;case"error":return Fn;default:return null}},Tn=Array(12).fill(0),In=({visible:e})=>l.createElement("div",{className:"sonner-loading-wrapper","data-visible":e},l.createElement("div",{className:"sonner-spinner"},Tn.map((n,r)=>l.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),On=l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},l.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),zn=l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},l.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),Dn=l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},l.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),Fn=l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},l.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),Ln=()=>{let[e,n]=l.useState(document.hidden);return l.useEffect(()=>{let r=()=>{n(document.hidden)};return document.addEventListener("visibilitychange",r),()=>window.removeEventListener("visibilitychange",r)},[]),e},Qe=1,Bn=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let n=this.subscribers.indexOf(e);this.subscribers.splice(n,1)}),this.publish=e=>{this.subscribers.forEach(n=>n(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var n;let{message:r,...o}=e,i=typeof(e==null?void 0:e.id)=="number"||((n=e.id)==null?void 0:n.length)>0?e.id:Qe++,c=this.toasts.find(u=>u.id===i),h=e.dismissible===void 0?!0:e.dismissible;return c?this.toasts=this.toasts.map(u=>u.id===i?(this.publish({...u,...e,id:i,title:r}),{...u,...e,id:i,dismissible:h,title:r}):u):this.addToast({title:r,...o,dismissible:h,id:i}),i},this.dismiss=e=>(e||this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),this.subscribers.forEach(n=>n({id:e,dismiss:!0})),e),this.message=(e,n)=>this.create({...n,message:e}),this.error=(e,n)=>this.create({...n,message:e,type:"error"}),this.success=(e,n)=>this.create({...n,type:"success",message:e}),this.info=(e,n)=>this.create({...n,type:"info",message:e}),this.warning=(e,n)=>this.create({...n,type:"warning",message:e}),this.loading=(e,n)=>this.create({...n,type:"loading",message:e}),this.promise=(e,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:e,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));let o=e instanceof Promise?e:e(),i=r!==void 0;return o.then(async c=>{if(An(c)&&!c.ok){i=!1;let h=typeof n.error=="function"?await n.error(`HTTP error! status: ${c.status}`):n.error,u=typeof n.description=="function"?await n.description(`HTTP error! status: ${c.status}`):n.description;this.create({id:r,type:"error",message:h,description:u})}else if(n.success!==void 0){i=!1;let h=typeof n.success=="function"?await n.success(c):n.success,u=typeof n.description=="function"?await n.description(c):n.description;this.create({id:r,type:"success",message:h,description:u})}}).catch(async c=>{if(n.error!==void 0){i=!1;let h=typeof n.error=="function"?await n.error(c):n.error,u=typeof n.description=="function"?await n.description(c):n.description;this.create({id:r,type:"error",message:h,description:u})}}).finally(()=>{var c;i&&(this.dismiss(r),r=void 0),(c=n.finally)==null||c.call(n)}),r},this.custom=(e,n)=>{let r=(n==null?void 0:n.id)||Qe++;return this.create({jsx:e(r),id:r,...n}),r},this.subscribers=[],this.toasts=[]}},fe=new Bn,Mn=(e,n)=>{let r=(n==null?void 0:n.id)||Qe++;return fe.addToast({title:e,...n,id:r}),r},An=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",Wn=Mn,Vn=()=>fe.toasts,Yn=Object.assign(Wn,{success:fe.success,info:fe.info,warning:fe.warning,error:fe.error,custom:fe.custom,message:fe.message,promise:fe.promise,dismiss:fe.dismiss,loading:fe.loading},{getHistory:Vn});function Hn(e,{insertAt:n}={}){if(!e||typeof document>"u")return;let r=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",n==="top"&&r.firstChild?r.insertBefore(o,r.firstChild):r.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}Hn(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999}:where([data-sonner-toaster][data-x-position="right"]){right:max(var(--offset),env(safe-area-inset-right))}:where([data-sonner-toaster][data-x-position="left"]){left:max(var(--offset),env(safe-area-inset-left))}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:max(var(--offset),env(safe-area-inset-top))}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:max(var(--offset),env(safe-area-inset-bottom))}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;background:var(--gray1);color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:0;right:0;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount, 0px));transition:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation:swipe-out .2s ease-out forwards}@keyframes swipe-out{0%{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount)));opacity:1}to{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount) + var(--lift) * -100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;--mobile-offset: 16px;right:var(--mobile-offset);left:var(--mobile-offset);width:100%}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset)}[data-sonner-toaster][data-y-position=bottom]{bottom:20px}[data-sonner-toaster][data-y-position=top]{top:20px}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset);right:var(--mobile-offset);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);--error-text: hsl(358, 100%, 81%)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}
33
+ `);function Ae(e){return e.label!==void 0}var Un=3,Kn="32px",Xn=4e3,qn=356,Jn=14,Gn=20,Zn=200;function Qn(...e){return e.filter(Boolean).join(" ")}var er=e=>{var n,r,o,i,c,h,u,d,p,m;let{invert:b,toast:a,unstyled:v,interacting:S,setHeights:x,visibleToasts:N,heights:y,index:w,toasts:Y,expanded:D,removeToast:R,defaultRichColors:W,closeButton:B,style:q,cancelButtonStyle:K,actionButtonStyle:X,className:z="",descriptionClassName:Q="",duration:E,position:J,gap:F,loadingIcon:H,expandByDefault:re,classNames:P,icons:ee,closeButtonAriaLabel:me="Close toast",pauseWhenPageIsHidden:I,cn:j}=e,[$,ae]=l.useState(!1),[te,U]=l.useState(!1),[se,le]=l.useState(!1),[he,be]=l.useState(!1),[et,$e]=l.useState(0),[tt,We]=l.useState(0),je=l.useRef(null),pe=l.useRef(null),Ve=w===0,Ye=w+1<=N,oe=a.type,ke=a.dismissible!==!1,nt=a.className||"",ze=a.descriptionClassName||"",Re=l.useMemo(()=>y.findIndex(_=>_.toastId===a.id)||0,[y,a.id]),rt=l.useMemo(()=>{var _;return(_=a.closeButton)!=null?_:B},[a.closeButton,B]),De=l.useMemo(()=>a.duration||E||Xn,[a.duration,E]),Pe=l.useRef(0),ge=l.useRef(0),He=l.useRef(0),we=l.useRef(null),[Fe,Le]=J.split("-"),Ue=l.useMemo(()=>y.reduce((_,M,A)=>A>=Re?_:_+M.height,0),[y,Re]),Ke=Ln(),at=a.invert||b,Be=oe==="loading";ge.current=l.useMemo(()=>Re*F+Ue,[Re,Ue]),l.useEffect(()=>{ae(!0)},[]),l.useLayoutEffect(()=>{if(!$)return;let _=pe.current,M=_.style.height;_.style.height="auto";let A=_.getBoundingClientRect().height;_.style.height=M,We(A),x(ie=>ie.find(ue=>ue.toastId===a.id)?ie.map(ue=>ue.toastId===a.id?{...ue,height:A}:ue):[{toastId:a.id,height:A,position:a.position},...ie])},[$,a.title,a.description,x,a.id]);let ye=l.useCallback(()=>{U(!0),$e(ge.current),x(_=>_.filter(M=>M.toastId!==a.id)),setTimeout(()=>{R(a)},Zn)},[a,R,x,ge]);l.useEffect(()=>{if(a.promise&&oe==="loading"||a.duration===1/0||a.type==="loading")return;let _,M=De;return D||S||I&&Ke?(()=>{if(He.current<Pe.current){let A=new Date().getTime()-Pe.current;M=M-A}He.current=new Date().getTime()})():M!==1/0&&(Pe.current=new Date().getTime(),_=setTimeout(()=>{var A;(A=a.onAutoClose)==null||A.call(a,a),ye()},M)),()=>clearTimeout(_)},[D,S,re,a,De,ye,a.promise,oe,I,Ke]),l.useEffect(()=>{let _=pe.current;if(_){let M=_.getBoundingClientRect().height;return We(M),x(A=>[{toastId:a.id,height:M,position:a.position},...A]),()=>x(A=>A.filter(ie=>ie.toastId!==a.id))}},[x,a.id]),l.useEffect(()=>{a.delete&&ye()},[ye,a.delete]);function st(){return ee!=null&&ee.loading?l.createElement("div",{className:"sonner-loader","data-visible":oe==="loading"},ee.loading):H?l.createElement("div",{className:"sonner-loader","data-visible":oe==="loading"},H):l.createElement(In,{visible:oe==="loading"})}return l.createElement("li",{"aria-live":a.important?"assertive":"polite","aria-atomic":"true",role:"status",tabIndex:0,ref:pe,className:j(z,nt,P==null?void 0:P.toast,(n=a==null?void 0:a.classNames)==null?void 0:n.toast,P==null?void 0:P.default,P==null?void 0:P[oe],(r=a==null?void 0:a.classNames)==null?void 0:r[oe]),"data-sonner-toast":"","data-rich-colors":(o=a.richColors)!=null?o:W,"data-styled":!(a.jsx||a.unstyled||v),"data-mounted":$,"data-promise":!!a.promise,"data-removed":te,"data-visible":Ye,"data-y-position":Fe,"data-x-position":Le,"data-index":w,"data-front":Ve,"data-swiping":se,"data-dismissible":ke,"data-type":oe,"data-invert":at,"data-swipe-out":he,"data-expanded":!!(D||re&&$),style:{"--index":w,"--toasts-before":w,"--z-index":Y.length-w,"--offset":`${te?et:ge.current}px`,"--initial-height":re?"auto":`${tt}px`,...q,...a.style},onPointerDown:_=>{Be||!ke||(je.current=new Date,$e(ge.current),_.target.setPointerCapture(_.pointerId),_.target.tagName!=="BUTTON"&&(le(!0),we.current={x:_.clientX,y:_.clientY}))},onPointerUp:()=>{var _,M,A,ie;if(he||!ke)return;we.current=null;let ue=Number(((_=pe.current)==null?void 0:_.style.getPropertyValue("--swipe-amount").replace("px",""))||0),Ne=new Date().getTime()-((M=je.current)==null?void 0:M.getTime()),Xe=Math.abs(ue)/Ne;if(Math.abs(ue)>=Gn||Xe>.11){$e(ge.current),(A=a.onDismiss)==null||A.call(a,a),ye(),be(!0);return}(ie=pe.current)==null||ie.style.setProperty("--swipe-amount","0px"),le(!1)},onPointerMove:_=>{var M;if(!we.current||!ke)return;let A=_.clientY-we.current.y,ie=_.clientX-we.current.x,ue=(Fe==="top"?Math.min:Math.max)(0,A),Ne=_.pointerType==="touch"?10:2;Math.abs(ue)>Ne?(M=pe.current)==null||M.style.setProperty("--swipe-amount",`${A}px`):Math.abs(ie)>Ne&&(we.current=null)}},rt&&!a.jsx?l.createElement("button",{"aria-label":me,"data-disabled":Be,"data-close-button":!0,onClick:Be||!ke?()=>{}:()=>{var _;ye(),(_=a.onDismiss)==null||_.call(a,a)},className:j(P==null?void 0:P.closeButton,(i=a==null?void 0:a.classNames)==null?void 0:i.closeButton)},l.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},l.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),l.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"}))):null,a.jsx||l.isValidElement(a.title)?a.jsx||a.title:l.createElement(l.Fragment,null,oe||a.icon||a.promise?l.createElement("div",{"data-icon":"",className:j(P==null?void 0:P.icon,(c=a==null?void 0:a.classNames)==null?void 0:c.icon)},a.promise||a.type==="loading"&&!a.icon?a.icon||st():null,a.type!=="loading"?a.icon||(ee==null?void 0:ee[oe])||Pn(oe):null):null,l.createElement("div",{"data-content":"",className:j(P==null?void 0:P.content,(h=a==null?void 0:a.classNames)==null?void 0:h.content)},l.createElement("div",{"data-title":"",className:j(P==null?void 0:P.title,(u=a==null?void 0:a.classNames)==null?void 0:u.title)},a.title),a.description?l.createElement("div",{"data-description":"",className:j(Q,ze,P==null?void 0:P.description,(d=a==null?void 0:a.classNames)==null?void 0:d.description)},a.description):null),l.isValidElement(a.cancel)?a.cancel:a.cancel&&Ae(a.cancel)?l.createElement("button",{"data-button":!0,"data-cancel":!0,style:a.cancelButtonStyle||K,onClick:_=>{var M,A;Ae(a.cancel)&&ke&&((A=(M=a.cancel).onClick)==null||A.call(M,_),ye())},className:j(P==null?void 0:P.cancelButton,(p=a==null?void 0:a.classNames)==null?void 0:p.cancelButton)},a.cancel.label):null,l.isValidElement(a.action)?a.action:a.action&&Ae(a.action)?l.createElement("button",{"data-button":!0,"data-action":!0,style:a.actionButtonStyle||X,onClick:_=>{var M,A;Ae(a.action)&&(_.defaultPrevented||((A=(M=a.action).onClick)==null||A.call(M,_),ye()))},className:j(P==null?void 0:P.actionButton,(m=a==null?void 0:a.classNames)==null?void 0:m.actionButton)},a.action.label):null))};function kt(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}var tr=e=>{let{invert:n,position:r="bottom-right",hotkey:o=["altKey","KeyT"],expand:i,closeButton:c,className:h,offset:u,theme:d="light",richColors:p,duration:m,style:b,visibleToasts:a=Un,toastOptions:v,dir:S=kt(),gap:x=Jn,loadingIcon:N,icons:y,containerAriaLabel:w="Notifications",pauseWhenPageIsHidden:Y,cn:D=Qn}=e,[R,W]=l.useState([]),B=l.useMemo(()=>Array.from(new Set([r].concat(R.filter(I=>I.position).map(I=>I.position)))),[R,r]),[q,K]=l.useState([]),[X,z]=l.useState(!1),[Q,E]=l.useState(!1),[J,F]=l.useState(d!=="system"?d:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),H=l.useRef(null),re=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),P=l.useRef(null),ee=l.useRef(!1),me=l.useCallback(I=>{var j;(j=R.find($=>$.id===I.id))!=null&&j.delete||fe.dismiss(I.id),W($=>$.filter(({id:ae})=>ae!==I.id))},[R]);return l.useEffect(()=>fe.subscribe(I=>{if(I.dismiss){W(j=>j.map($=>$.id===I.id?{...$,delete:!0}:$));return}setTimeout(()=>{Rt.flushSync(()=>{W(j=>{let $=j.findIndex(ae=>ae.id===I.id);return $!==-1?[...j.slice(0,$),{...j[$],...I},...j.slice($+1)]:[I,...j]})})})}),[]),l.useEffect(()=>{if(d!=="system"){F(d);return}d==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?F("dark"):F("light")),typeof window<"u"&&window.matchMedia("(prefers-color-scheme: dark)").addEventListener("change",({matches:I})=>{F(I?"dark":"light")})},[d]),l.useEffect(()=>{R.length<=1&&z(!1)},[R]),l.useEffect(()=>{let I=j=>{var $,ae;o.every(te=>j[te]||j.code===te)&&(z(!0),($=H.current)==null||$.focus()),j.code==="Escape"&&(document.activeElement===H.current||(ae=H.current)!=null&&ae.contains(document.activeElement))&&z(!1)};return document.addEventListener("keydown",I),()=>document.removeEventListener("keydown",I)},[o]),l.useEffect(()=>{if(H.current)return()=>{P.current&&(P.current.focus({preventScroll:!0}),P.current=null,ee.current=!1)}},[H.current]),R.length?l.createElement("section",{"aria-label":`${w} ${re}`,tabIndex:-1},B.map((I,j)=>{var $;let[ae,te]=I.split("-");return l.createElement("ol",{key:I,dir:S==="auto"?kt():S,tabIndex:-1,ref:H,className:h,"data-sonner-toaster":!0,"data-theme":J,"data-y-position":ae,"data-x-position":te,style:{"--front-toast-height":`${(($=q[0])==null?void 0:$.height)||0}px`,"--offset":typeof u=="number"?`${u}px`:u||Kn,"--width":`${qn}px`,"--gap":`${x}px`,...b},onBlur:U=>{ee.current&&!U.currentTarget.contains(U.relatedTarget)&&(ee.current=!1,P.current&&(P.current.focus({preventScroll:!0}),P.current=null))},onFocus:U=>{U.target instanceof HTMLElement&&U.target.dataset.dismissible==="false"||ee.current||(ee.current=!0,P.current=U.relatedTarget)},onMouseEnter:()=>z(!0),onMouseMove:()=>z(!0),onMouseLeave:()=>{Q||z(!1)},onPointerDown:U=>{U.target instanceof HTMLElement&&U.target.dataset.dismissible==="false"||E(!0)},onPointerUp:()=>E(!1)},R.filter(U=>!U.position&&j===0||U.position===I).map((U,se)=>{var le,he;return l.createElement(er,{key:U.id,icons:y,index:se,toast:U,defaultRichColors:p,duration:(le=v==null?void 0:v.duration)!=null?le:m,className:v==null?void 0:v.className,descriptionClassName:v==null?void 0:v.descriptionClassName,invert:n,visibleToasts:a,closeButton:(he=v==null?void 0:v.closeButton)!=null?he:c,interacting:Q,position:I,style:v==null?void 0:v.style,unstyled:v==null?void 0:v.unstyled,classNames:v==null?void 0:v.classNames,cancelButtonStyle:v==null?void 0:v.cancelButtonStyle,actionButtonStyle:v==null?void 0:v.actionButtonStyle,removeToast:me,toasts:R.filter(be=>be.position==U.position),heights:q.filter(be=>be.position==U.position),setHeights:K,expandByDefault:i,gap:x,loadingIcon:N,expanded:X,pauseWhenPageIsHidden:Y,cn:D})}))})):null};function nr({children:e}){function n(r){Yn.custom(o=>s.jsx(bt,{...r}))}return s.jsxs(yt.Provider,{value:{showToast:n},children:[s.jsx(tr,{}),e]})}C.Badge=Dt,C.BreadcrumbContainer=mn,C.BreadcrumbLink=pn,C.Button=Yt,C.Checkbox=Ut,C.Divider=Ft,C.DrawerContainer=yn,C.DrawerHeader=xn,C.DrawerProvider=$n,C.FormController=Ht,C.FormError=Kt,C.FormLabel=Xt,C.IconButton=qt,C.Input=un,C.ModalContainer=wn,C.ModalFooter=Cn,C.ModalHeader=kn,C.ModalProvider=Rn,C.Pagination=gn,C.Popover=Nn,C.Select=fn,C.Skeleton=Lt,C.TabButton=vn,C.TabContainer=bn,C.TableBody=Bt,C.TableCaption=Mt,C.TableContainer=At,C.TableFooter=Wt,C.TableHeader=Vt,C.Textarea=hn,C.Toast=bt,C.ToastProvider=nr,C.Tooltip=_n,C.useAutomation=jn,C.useDrawer=Sn,C.useModal=En,C.useScopedParams=pt,C.useToast=xt,Object.defineProperty(C,Symbol.toStringTag,{value:"Module"})});
@@ -0,0 +1,5 @@
1
+ import { TabButtonProps } from "@arkyn/types";
2
+ import "./styles.css";
3
+ declare function TabButton(props: TabButtonProps): import("react/jsx-runtime").JSX.Element;
4
+ export { TabButton };
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Tabs/TabButton/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,cAAc,CAAC;AAEtB,iBAAS,SAAS,CAAC,KAAK,EAAE,cAAc,2CAYvC;AAED,OAAO,EAAE,SAAS,EAAE,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import "./styles.css";
3
+ function TabButton(props) {
4
+ const { children, value, className: baseClassName, ...rest } = props;
5
+ const className = `arkyn_tab_button ${props.defaultActive ? "active" : ""} ${baseClassName || ""}`;
6
+ return (_jsx("button", { className: className.trim(), ...rest, children: children }));
7
+ }
8
+ export { TabButton };
@@ -0,0 +1,5 @@
1
+ import { TabContainerProps } from "@arkyn/types";
2
+ import "./styles.css";
3
+ declare function TabContainer(props: TabContainerProps): import("react/jsx-runtime").JSX.Element;
4
+ export { TabContainer };
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Tabs/TabContainer/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAGjD,OAAO,cAAc,CAAC;AAEtB,iBAAS,YAAY,CAAC,KAAK,EAAE,iBAAiB,2CA+D7C;AAED,OAAO,EAAE,YAAY,EAAE,CAAC"}
@@ -0,0 +1,45 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useLayoutEffect, useRef, useState } from "react";
3
+ import "./styles.css";
4
+ function TabContainer(props) {
5
+ const { children, onClick, className: baseClassName, ...rest } = props;
6
+ const reference = useRef(null);
7
+ const className = `arkyn_tab_container ${baseClassName || ""}`;
8
+ const [activeLineStyle, setActiveLineStyle] = useState({
9
+ width: "0px",
10
+ left: "0px",
11
+ transition: "none",
12
+ });
13
+ const updateActiveLine = (button, applyTransition) => {
14
+ const rect = button.getBoundingClientRect();
15
+ const containerRect = reference.current.getBoundingClientRect();
16
+ const transition = applyTransition ? undefined : "none";
17
+ setActiveLineStyle({
18
+ transition,
19
+ width: `${rect.width}px`,
20
+ left: `${rect.left - containerRect.left}px`,
21
+ });
22
+ };
23
+ useLayoutEffect(() => {
24
+ const tabContainer = reference.current;
25
+ if (!tabContainer)
26
+ return;
27
+ let activeButton = null;
28
+ activeButton = tabContainer.querySelector("button.active");
29
+ if (activeButton)
30
+ updateActiveLine(activeButton);
31
+ }, []);
32
+ const handleTabClick = (event) => {
33
+ const target = event.target;
34
+ const tabContainer = reference.current;
35
+ if (target && tabContainer && tabContainer.contains(target)) {
36
+ const buttons = tabContainer.querySelectorAll("button");
37
+ buttons.forEach((button) => button.classList.remove("active"));
38
+ target.classList.add("active");
39
+ updateActiveLine(target, true);
40
+ onClick && onClick(target.value);
41
+ }
42
+ };
43
+ return (_jsxs("nav", { ref: reference, onClick: handleTabClick, className: className.trim(), ...rest, children: [children, _jsx("div", { className: "active-line", style: activeLineStyle })] }));
44
+ }
45
+ export { TabContainer };
@@ -0,0 +1,4 @@
1
+ import { TabButton } from "./TabButton";
2
+ import { TabContainer } from "./TabContainer";
3
+ export { TabContainer, TabButton };
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Tabs/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { TabButton } from "./TabButton";
2
+ import { TabContainer } from "./TabContainer";
3
+ export { TabContainer, TabButton };
package/dist/index.d.ts CHANGED
@@ -11,6 +11,7 @@ export { Select } from "./components/Select";
11
11
  export { Textarea } from "./components/Textarea";
12
12
  export { BreadcrumbContainer, BreadcrumbLink } from "./components/Breadcrumb";
13
13
  export { Pagination } from "./components/Pagination";
14
+ export { TabButton, TabContainer } from "./components/Tabs";
14
15
  export { DrawerContainer, DrawerHeader } from "./components/Drawer";
15
16
  export { ModalContainer, ModalFooter, ModalHeader } from "./components/Modal";
16
17
  export { Popover } from "./components/Popover";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AACjD,OAAO,EACL,SAAS,EACT,YAAY,EACZ,cAAc,EACd,WAAW,EACX,WAAW,GACZ,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AACjD,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACzE,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGjD,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAC9E,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAGrD,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAC9E,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAG/C,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAG5C,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AACjD,OAAO,EACL,SAAS,EACT,YAAY,EACZ,cAAc,EACd,WAAW,EACX,WAAW,GACZ,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AACjD,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACzE,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGjD,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAC9E,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAE5D,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAC9E,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAG/C,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAG5C,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC"}
package/dist/index.js CHANGED
@@ -14,6 +14,7 @@ export { Textarea } from "./components/Textarea";
14
14
  // Navigation
15
15
  export { BreadcrumbContainer, BreadcrumbLink } from "./components/Breadcrumb";
16
16
  export { Pagination } from "./components/Pagination";
17
+ export { TabButton, TabContainer } from "./components/Tabs";
17
18
  // Overlay
18
19
  export { DrawerContainer, DrawerHeader } from "./components/Drawer";
19
20
  export { ModalContainer, ModalFooter, ModalHeader } from "./components/Modal";