@takumi-rs/helpers 0.19.0 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +3 -3
  2. package/package.json +7 -2
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- var Aw=Object.create;var{getPrototypeOf:zw,defineProperty:_x,getOwnPropertyNames:Ow}=Object;var jw=Object.prototype.hasOwnProperty;var qw=(w,f,T)=>{T=w!=null?Aw(zw(w)):{};let E=f||!w||!w.__esModule?_x(T,"default",{value:w,enumerable:!0}):T;for(let X of Ow(w))if(!jw.call(E,X))_x(E,X,{get:()=>w[X],enumerable:!0});return E};var Nw=(w,f)=>()=>(f||w((f={exports:{}}).exports,f),f.exports);var yx=Nw((Uw,o)=>{(function(){function w(x,$){Object.defineProperty(E.prototype,x,{get:function(){console.warn("%s(...) is deprecated in plain JavaScript React classes. %s",$[0],$[1])}})}function f(x){if(x===null||typeof x!=="object")return null;return x=Mx&&x[Mx]||x["@@iterator"],typeof x==="function"?x:null}function T(x,$){x=(x=x.constructor)&&(x.displayName||x.name)||"ReactClass";var D=x+"."+$;Wx[D]||(console.error("Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.",$,x),Wx[D]=!0)}function E(x,$,D){this.props=x,this.context=$,this.refs=wx,this.updater=D||Ix}function X(){}function B(x,$,D){this.props=x,this.context=$,this.refs=wx,this.updater=D||Ix}function Z(x){return""+x}function Y(x){try{Z(x);var $=!1}catch(H){$=!0}if($){$=console;var D=$.error,G=typeof Symbol==="function"&&Symbol.toStringTag&&x[Symbol.toStringTag]||x.constructor.name||"Object";return D.call($,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",G),Z(x)}}function O(x){if(x==null)return null;if(typeof x==="function")return x.$$typeof===Rw?null:x.displayName||x.name||null;if(typeof x==="string")return x;switch(x){case a:return"Fragment";case Bx:return"Profiler";case Hx:return"StrictMode";case Rx:return"Suspense";case Qw:return"SuspenseList";case Yw:return"Activity"}if(typeof x==="object")switch(typeof x.tag==="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),x.$$typeof){case Zx:return"Portal";case Qx:return(x.displayName||"Context")+".Provider";case e:return(x._context.displayName||"Context")+".Consumer";case Yx:var $=x.render;return x=x.displayName,x||(x=$.displayName||$.name||"",x=x!==""?"ForwardRef("+x+")":"ForwardRef"),x;case xx:return $=x.displayName||null,$!==null?$:O(x.type)||"Memo";case V:$=x._payload,x=x._init;try{return O(x($))}catch(D){}}return null}function N(x){if(x===a)return"<>";if(typeof x==="object"&&x!==null&&x.$$typeof===V)return"<...>";try{var $=O(x);return $?"<"+$+">":"<...>"}catch(D){return"<...>"}}function U(){var x=M.A;return x===null?null:x.getOwner()}function q(){return Error("react-stack-top-frame")}function _(x){if(d.call(x,"key")){var $=Object.getOwnPropertyDescriptor(x,"key").get;if($&&$.isReactWarning)return!1}return x.key!==void 0}function Dw(x,$){function D(){Ox||(Ox=!0,console.error("%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://react.dev/link/special-props)",$))}D.isReactWarning=!0,Object.defineProperty(x,"key",{get:D,configurable:!0})}function Ew(){var x=O(this.type);return qx[x]||(qx[x]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),x=this.props.ref,x!==void 0?x:null}function p(x,$,D,G,H,W,Q,I){return D=W.ref,x={$$typeof:r,type:x,key:$,props:W,_owner:H},(D!==void 0?D:null)!==null?Object.defineProperty(x,"ref",{enumerable:!1,get:Ew}):Object.defineProperty(x,"ref",{enumerable:!1,value:null}),x._store={},Object.defineProperty(x._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(x,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(x,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:Q}),Object.defineProperty(x,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:I}),Object.freeze&&(Object.freeze(x.props),Object.freeze(x)),x}function Gw(x,$){return $=p(x.type,$,void 0,void 0,x._owner,x.props,x._debugStack,x._debugTask),x._store&&($._store.validated=x._store.validated),$}function h(x){return typeof x==="object"&&x!==null&&x.$$typeof===r}function Xw(x){var $={"=":"=0",":":"=2"};return"$"+x.replace(/[=:]/g,function(D){return $[D]})}function t(x,$){return typeof x==="object"&&x!==null&&x.key!=null?(Y(x.key),Xw(""+x.key)):$.toString(36)}function Xx(){}function Zw(x){switch(x.status){case"fulfilled":return x.value;case"rejected":throw x.reason;default:switch(typeof x.status==="string"?x.then(Xx,Xx):(x.status="pending",x.then(function($){x.status==="pending"&&(x.status="fulfilled",x.value=$)},function($){x.status==="pending"&&(x.status="rejected",x.reason=$)})),x.status){case"fulfilled":return x.value;case"rejected":throw x.reason}}throw x}function L(x,$,D,G,H){var W=typeof x;if(W==="undefined"||W==="boolean")x=null;var Q=!1;if(x===null)Q=!0;else switch(W){case"bigint":case"string":case"number":Q=!0;break;case"object":switch(x.$$typeof){case r:case Zx:Q=!0;break;case V:return Q=x._init,L(Q(x._payload),$,D,G,H)}}if(Q){Q=x,H=H(Q);var I=G===""?"."+t(Q,0):G;return Ax(H)?(D="",I!=null&&(D=I.replace(Ux,"$&/")+"/"),L(H,$,D,"",function(C){return C})):H!=null&&(h(H)&&(H.key!=null&&(Q&&Q.key===H.key||Y(H.key)),D=Gw(H,D+(H.key==null||Q&&Q.key===H.key?"":(""+H.key).replace(Ux,"$&/")+"/")+I),G!==""&&Q!=null&&h(Q)&&Q.key==null&&Q._store&&!Q._store.validated&&(D._store.validated=2),H=D),$.push(H)),1}if(Q=0,I=G===""?".":G+":",Ax(x))for(var R=0;R<x.length;R++)G=x[R],W=I+t(G,R),Q+=L(G,$,D,W,H);else if(R=f(x),typeof R==="function")for(R===x.entries&&(Nx||console.warn("Using Maps as children is not supported. Use an array of keyed ReactElements instead."),Nx=!0),x=R.call(x),R=0;!(G=x.next()).done;)G=G.value,W=I+t(G,R++),Q+=L(G,$,D,W,H);else if(W==="object"){if(typeof x.then==="function")return L(Zw(x),$,D,G,H);throw $=String(x),Error("Objects are not valid as a React child (found: "+($==="[object Object]"?"object with keys {"+Object.keys(x).join(", ")+"}":$)+"). If you meant to render a collection of children, use an array instead.")}return Q}function b(x,$,D){if(x==null)return x;var G=[],H=0;return L(x,G,"","",function(W){return $.call(D,W,H++)}),G}function Hw(x){if(x._status===-1){var $=x._result;$=$(),$.then(function(D){if(x._status===0||x._status===-1)x._status=1,x._result=D},function(D){if(x._status===0||x._status===-1)x._status=2,x._result=D}),x._status===-1&&(x._status=0,x._result=$)}if(x._status===1)return $=x._result,$===void 0&&console.error(`lazy: Expected the result of a dynamic import() call. Instead received: %s
1
+ var zw=Object.create;var{getPrototypeOf:Ow,defineProperty:_x,getOwnPropertyNames:qw}=Object;var Iw=Object.prototype.hasOwnProperty;var jw=(w,T,D)=>{D=w!=null?zw(Ow(w)):{};let X=T||!w||!w.__esModule?_x(D,"default",{value:w,enumerable:!0}):D;for(let B of qw(w))if(!Iw.call(X,B))_x(X,B,{get:()=>w[B],enumerable:!0});return X};var Uw=(w,T)=>()=>(T||w((T={exports:{}}).exports,T),T.exports);var bx=Uw((Kw,n)=>{(function(){function w(x,$){Object.defineProperty(X.prototype,x,{get:function(){console.warn("%s(...) is deprecated in plain JavaScript React classes. %s",$[0],$[1])}})}function T(x){if(x===null||typeof x!=="object")return null;return x=Rx&&x[Rx]||x["@@iterator"],typeof x==="function"?x:null}function D(x,$){x=(x=x.constructor)&&(x.displayName||x.name)||"ReactClass";var G=x+"."+$;Jx[G]||(console.error("Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.",$,x),Jx[G]=!0)}function X(x,$,G){this.props=x,this.context=$,this.refs=wx,this.updater=G||Wx}function B(){}function E(x,$,G){this.props=x,this.context=$,this.refs=wx,this.updater=G||Wx}function H(x){return""+x}function Y(x){try{H(x);var $=!1}catch(f){$=!0}if($){$=console;var G=$.error,Z=typeof Symbol==="function"&&Symbol.toStringTag&&x[Symbol.toStringTag]||x.constructor.name||"Object";return G.call($,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",Z),H(x)}}function q(x){if(x==null)return null;if(typeof x==="function")return x.$$typeof===Mw?null:x.displayName||x.name||null;if(typeof x==="string")return x;switch(x){case a:return"Fragment";case Ex:return"Profiler";case fx:return"StrictMode";case Mx:return"Suspense";case Qw:return"SuspenseList";case Yw:return"Activity"}if(typeof x==="object")switch(typeof x.tag==="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),x.$$typeof){case Hx:return"Portal";case Qx:return(x.displayName||"Context")+".Provider";case e:return(x._context.displayName||"Context")+".Consumer";case Yx:var $=x.render;return x=x.displayName,x||(x=$.displayName||$.name||"",x=x!==""?"ForwardRef("+x+")":"ForwardRef"),x;case xx:return $=x.displayName||null,$!==null?$:q(x.type)||"Memo";case g:$=x._payload,x=x._init;try{return q(x($))}catch(G){}}return null}function U(x){if(x===a)return"<>";if(typeof x==="object"&&x!==null&&x.$$typeof===g)return"<...>";try{var $=q(x);return $?"<"+$+">":"<...>"}catch(G){return"<...>"}}function K(){var x=R.A;return x===null?null:x.getOwner()}function j(){return Error("react-stack-top-frame")}function _(x){if(d.call(x,"key")){var $=Object.getOwnPropertyDescriptor(x,"key").get;if($&&$.isReactWarning)return!1}return x.key!==void 0}function Gw(x,$){function G(){qx||(qx=!0,console.error("%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://react.dev/link/special-props)",$))}G.isReactWarning=!0,Object.defineProperty(x,"key",{get:G,configurable:!0})}function Xw(){var x=q(this.type);return jx[x]||(jx[x]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),x=this.props.ref,x!==void 0?x:null}function t(x,$,G,Z,f,J,Q,W){return G=J.ref,x={$$typeof:r,type:x,key:$,props:J,_owner:f},(G!==void 0?G:null)!==null?Object.defineProperty(x,"ref",{enumerable:!1,get:Xw}):Object.defineProperty(x,"ref",{enumerable:!1,value:null}),x._store={},Object.defineProperty(x._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(x,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(x,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:Q}),Object.defineProperty(x,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:W}),Object.freeze&&(Object.freeze(x.props),Object.freeze(x)),x}function Zw(x,$){return $=t(x.type,$,void 0,void 0,x._owner,x.props,x._debugStack,x._debugTask),x._store&&($._store.validated=x._store.validated),$}function L(x){return typeof x==="object"&&x!==null&&x.$$typeof===r}function Bw(x){var $={"=":"=0",":":"=2"};return"$"+x.replace(/[=:]/g,function(G){return $[G]})}function o(x,$){return typeof x==="object"&&x!==null&&x.key!=null?(Y(x.key),Bw(""+x.key)):$.toString(36)}function Bx(){}function Hw(x){switch(x.status){case"fulfilled":return x.value;case"rejected":throw x.reason;default:switch(typeof x.status==="string"?x.then(Bx,Bx):(x.status="pending",x.then(function($){x.status==="pending"&&(x.status="fulfilled",x.value=$)},function($){x.status==="pending"&&(x.status="rejected",x.reason=$)})),x.status){case"fulfilled":return x.value;case"rejected":throw x.reason}}throw x}function h(x,$,G,Z,f){var J=typeof x;if(J==="undefined"||J==="boolean")x=null;var Q=!1;if(x===null)Q=!0;else switch(J){case"bigint":case"string":case"number":Q=!0;break;case"object":switch(x.$$typeof){case r:case Hx:Q=!0;break;case g:return Q=x._init,h(Q(x._payload),$,G,Z,f)}}if(Q){Q=x,f=f(Q);var W=Z===""?"."+o(Q,0):Z;return zx(f)?(G="",W!=null&&(G=W.replace(Kx,"$&/")+"/"),h(f,$,G,"",function(N){return N})):f!=null&&(L(f)&&(f.key!=null&&(Q&&Q.key===f.key||Y(f.key)),G=Zw(f,G+(f.key==null||Q&&Q.key===f.key?"":(""+f.key).replace(Kx,"$&/")+"/")+W),Z!==""&&Q!=null&&L(Q)&&Q.key==null&&Q._store&&!Q._store.validated&&(G._store.validated=2),f=G),$.push(f)),1}if(Q=0,W=Z===""?".":Z+":",zx(x))for(var M=0;M<x.length;M++)Z=x[M],J=W+o(Z,M),Q+=h(Z,$,G,J,f);else if(M=T(x),typeof M==="function")for(M===x.entries&&(Ux||console.warn("Using Maps as children is not supported. Use an array of keyed ReactElements instead."),Ux=!0),x=M.call(x),M=0;!(Z=x.next()).done;)Z=Z.value,J=W+o(Z,M++),Q+=h(Z,$,G,J,f);else if(J==="object"){if(typeof x.then==="function")return h(Hw(x),$,G,Z,f);throw $=String(x),Error("Objects are not valid as a React child (found: "+($==="[object Object]"?"object with keys {"+Object.keys(x).join(", ")+"}":$)+"). If you meant to render a collection of children, use an array instead.")}return Q}function y(x,$,G){if(x==null)return x;var Z=[],f=0;return h(x,Z,"","",function(J){return $.call(G,J,f++)}),Z}function fw(x){if(x._status===-1){var $=x._result;$=$(),$.then(function(G){if(x._status===0||x._status===-1)x._status=1,x._result=G},function(G){if(x._status===0||x._status===-1)x._status=2,x._result=G}),x._status===-1&&(x._status=0,x._result=$)}if(x._status===1)return $=x._result,$===void 0&&console.error(`lazy: Expected the result of a dynamic import() call. Instead received: %s
2
2
 
3
3
  Your code should look like:
4
4
  const MyComponent = lazy(() => import('./MyComponent'))
@@ -6,8 +6,8 @@ Your code should look like:
6
6
  Did you accidentally put curly braces around the import?`,$),"default"in $||console.error(`lazy: Expected the result of a dynamic import() call. Instead received: %s
7
7
 
8
8
  Your code should look like:
9
- const MyComponent = lazy(() => import('./MyComponent'))`,$),$.default;throw x._result}function A(){var x=M.H;return x===null&&console.error(`Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
9
+ const MyComponent = lazy(() => import('./MyComponent'))`,$),$.default;throw x._result}function z(){var x=R.H;return x===null&&console.error(`Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
10
10
  1. You might have mismatching versions of React and the renderer (such as React DOM)
11
11
  2. You might be breaking the Rules of Hooks
12
12
  3. You might have more than one copy of React in the same app
13
- See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`),x}function Bw(){}function S(x){if(s===null)try{var $=("require"+Math.random()).slice(0,7);s=(o&&o[$]).call(o,"timers").setImmediate}catch(D){s=function(G){Kx===!1&&(Kx=!0,typeof MessageChannel==="undefined"&&console.error("This browser does not have a MessageChannel implementation, so enqueuing tasks via await act(async () => ...) will fail. Please file an issue at https://github.com/facebook/react/issues if you encounter this warning."));var H=new MessageChannel;H.port1.onmessage=G,H.port2.postMessage(void 0)}}return s(x)}function m(x){return 1<x.length&&typeof AggregateError==="function"?new AggregateError(x):x[0]}function y(x,$){$!==i-1&&console.error("You seem to have overlapping act() calls, this is not supported. Be sure to await previous act() calls before making a new one. "),i=$}function c(x,$,D){var G=M.actQueue;if(G!==null)if(G.length!==0)try{l(G),S(function(){return c(x,$,D)});return}catch(H){M.thrownErrors.push(H)}else M.actQueue=null;0<M.thrownErrors.length?(G=m(M.thrownErrors),M.thrownErrors.length=0,D(G)):$(x)}function l(x){if(!fx){fx=!0;var $=0;try{for(;$<x.length;$++){var D=x[$];do{M.didUsePromise=!1;var G=D(!1);if(G!==null){if(M.didUsePromise){x[$]=D,x.splice(0,$);return}D=G}else break}while(1)}x.length=0}catch(H){x.splice(0,$+1),M.thrownErrors.push(H)}finally{fx=!1}}}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!=="undefined"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart==="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var r=Symbol.for("react.transitional.element"),Zx=Symbol.for("react.portal"),a=Symbol.for("react.fragment"),Hx=Symbol.for("react.strict_mode"),Bx=Symbol.for("react.profiler"),e=Symbol.for("react.consumer"),Qx=Symbol.for("react.context"),Yx=Symbol.for("react.forward_ref"),Rx=Symbol.for("react.suspense"),Qw=Symbol.for("react.suspense_list"),xx=Symbol.for("react.memo"),V=Symbol.for("react.lazy"),Yw=Symbol.for("react.activity"),Mx=Symbol.iterator,Wx={},Ix={isMounted:function(){return!1},enqueueForceUpdate:function(x){T(x,"forceUpdate")},enqueueReplaceState:function(x){T(x,"replaceState")},enqueueSetState:function(x){T(x,"setState")}},Jx=Object.assign,wx={};Object.freeze(wx),E.prototype.isReactComponent={},E.prototype.setState=function(x,$){if(typeof x!=="object"&&typeof x!=="function"&&x!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,x,$,"setState")},E.prototype.forceUpdate=function(x){this.updater.enqueueForceUpdate(this,x,"forceUpdate")};var j={isMounted:["isMounted","Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks."],replaceState:["replaceState","Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)."]},v;for(v in j)j.hasOwnProperty(v)&&w(v,j[v]);X.prototype=E.prototype,j=B.prototype=new X,j.constructor=B,Jx(j,E.prototype),j.isPureReactComponent=!0;var Ax=Array.isArray,Rw=Symbol.for("react.client.reference"),M={H:null,A:null,T:null,S:null,V:null,actQueue:null,isBatchingLegacy:!1,didScheduleLegacyUpdate:!1,didUsePromise:!1,thrownErrors:[],getCurrentStack:null,recentlyCreatedOwnerStacks:0},d=Object.prototype.hasOwnProperty,zx=console.createTask?console.createTask:function(){return null};j={react_stack_bottom_frame:function(x){return x()}};var Ox,jx,qx={},Mw=j.react_stack_bottom_frame.bind(j,q)(),Ww=zx(N(q)),Nx=!1,Ux=/\/+/g,Cx=typeof reportError==="function"?reportError:function(x){if(typeof window==="object"&&typeof window.ErrorEvent==="function"){var $=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof x==="object"&&x!==null&&typeof x.message==="string"?String(x.message):String(x),error:x});if(!window.dispatchEvent($))return}else if(typeof process==="object"&&typeof process.emit==="function"){process.emit("uncaughtException",x);return}console.error(x)},Kx=!1,s=null,i=0,u=!1,fx=!1,Fx=typeof queueMicrotask==="function"?function(x){queueMicrotask(function(){return queueMicrotask(x)})}:S;j=Object.freeze({__proto__:null,c:function(x){return A().useMemoCache(x)}}),Uw.Children={map:b,forEach:function(x,$,D){b(x,function(){$.apply(this,arguments)},D)},count:function(x){var $=0;return b(x,function(){$++}),$},toArray:function(x){return b(x,function($){return $})||[]},only:function(x){if(!h(x))throw Error("React.Children.only expected to receive a single React element child.");return x}},Uw.Component=E,Uw.Fragment=a,Uw.Profiler=Bx,Uw.PureComponent=B,Uw.StrictMode=Hx,Uw.Suspense=Rx,Uw.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=M,Uw.__COMPILER_RUNTIME=j,Uw.act=function(x){var $=M.actQueue,D=i;i++;var G=M.actQueue=$!==null?$:[],H=!1;try{var W=x()}catch(R){M.thrownErrors.push(R)}if(0<M.thrownErrors.length)throw y($,D),x=m(M.thrownErrors),M.thrownErrors.length=0,x;if(W!==null&&typeof W==="object"&&typeof W.then==="function"){var Q=W;return Fx(function(){H||u||(u=!0,console.error("You called act(async () => ...) without await. This could lead to unexpected testing behaviour, interleaving multiple act calls and mixing their scopes. You should - await act(async () => ...);"))}),{then:function(R,C){H=!0,Q.then(function(P){if(y($,D),D===0){try{l(G),S(function(){return c(P,R,C)})}catch(Jw){M.thrownErrors.push(Jw)}if(0<M.thrownErrors.length){var Iw=m(M.thrownErrors);M.thrownErrors.length=0,C(Iw)}}else R(P)},function(P){y($,D),0<M.thrownErrors.length?(P=m(M.thrownErrors),M.thrownErrors.length=0,C(P)):C(P)})}}}var I=W;if(y($,D),D===0&&(l(G),G.length!==0&&Fx(function(){H||u||(u=!0,console.error("A component suspended inside an `act` scope, but the `act` call was not awaited. When testing React components that depend on asynchronous data, you must await the result:\n\nawait act(() => ...)"))}),M.actQueue=null),0<M.thrownErrors.length)throw x=m(M.thrownErrors),M.thrownErrors.length=0,x;return{then:function(R,C){H=!0,D===0?(M.actQueue=G,S(function(){return c(I,R,C)})):R(I)}}},Uw.cache=function(x){return function(){return x.apply(null,arguments)}},Uw.captureOwnerStack=function(){var x=M.getCurrentStack;return x===null?null:x()},Uw.cloneElement=function(x,$,D){if(x===null||x===void 0)throw Error("The argument must be a React element, but you passed "+x+".");var G=Jx({},x.props),H=x.key,W=x._owner;if($!=null){var Q;x:{if(d.call($,"ref")&&(Q=Object.getOwnPropertyDescriptor($,"ref").get)&&Q.isReactWarning){Q=!1;break x}Q=$.ref!==void 0}Q&&(W=U()),_($)&&(Y($.key),H=""+$.key);for(I in $)!d.call($,I)||I==="key"||I==="__self"||I==="__source"||I==="ref"&&$.ref===void 0||(G[I]=$[I])}var I=arguments.length-2;if(I===1)G.children=D;else if(1<I){Q=Array(I);for(var R=0;R<I;R++)Q[R]=arguments[R+2];G.children=Q}G=p(x.type,H,void 0,void 0,W,G,x._debugStack,x._debugTask);for(H=2;H<arguments.length;H++)W=arguments[H],h(W)&&W._store&&(W._store.validated=1);return G},Uw.createContext=function(x){return x={$$typeof:Qx,_currentValue:x,_currentValue2:x,_threadCount:0,Provider:null,Consumer:null},x.Provider=x,x.Consumer={$$typeof:e,_context:x},x._currentRenderer=null,x._currentRenderer2=null,x},Uw.createElement=function(x,$,D){for(var G=2;G<arguments.length;G++){var H=arguments[G];h(H)&&H._store&&(H._store.validated=1)}if(G={},H=null,$!=null)for(R in jx||!("__self"in $)||"key"in $||(jx=!0,console.warn("Your app (or one of its dependencies) is using an outdated JSX transform. Update to the modern JSX transform for faster performance: https://react.dev/link/new-jsx-transform")),_($)&&(Y($.key),H=""+$.key),$)d.call($,R)&&R!=="key"&&R!=="__self"&&R!=="__source"&&(G[R]=$[R]);var W=arguments.length-2;if(W===1)G.children=D;else if(1<W){for(var Q=Array(W),I=0;I<W;I++)Q[I]=arguments[I+2];Object.freeze&&Object.freeze(Q),G.children=Q}if(x&&x.defaultProps)for(R in W=x.defaultProps,W)G[R]===void 0&&(G[R]=W[R]);H&&Dw(G,typeof x==="function"?x.displayName||x.name||"Unknown":x);var R=1e4>M.recentlyCreatedOwnerStacks++;return p(x,H,void 0,void 0,U(),G,R?Error("react-stack-top-frame"):Mw,R?zx(N(x)):Ww)},Uw.createRef=function(){var x={current:null};return Object.seal(x),x},Uw.forwardRef=function(x){x!=null&&x.$$typeof===xx?console.error("forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...))."):typeof x!=="function"?console.error("forwardRef requires a render function but was given %s.",x===null?"null":typeof x):x.length!==0&&x.length!==2&&console.error("forwardRef render functions accept exactly two parameters: props and ref. %s",x.length===1?"Did you forget to use the ref parameter?":"Any additional parameter will be undefined."),x!=null&&x.defaultProps!=null&&console.error("forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?");var $={$$typeof:Yx,render:x},D;return Object.defineProperty($,"displayName",{enumerable:!1,configurable:!0,get:function(){return D},set:function(G){D=G,x.name||x.displayName||(Object.defineProperty(x,"name",{value:G}),x.displayName=G)}}),$},Uw.isValidElement=h,Uw.lazy=function(x){return{$$typeof:V,_payload:{_status:-1,_result:x},_init:Hw}},Uw.memo=function(x,$){x==null&&console.error("memo: The first argument must be a component. Instead received: %s",x===null?"null":typeof x),$={$$typeof:xx,type:x,compare:$===void 0?null:$};var D;return Object.defineProperty($,"displayName",{enumerable:!1,configurable:!0,get:function(){return D},set:function(G){D=G,x.name||x.displayName||(Object.defineProperty(x,"name",{value:G}),x.displayName=G)}}),$},Uw.startTransition=function(x){var $=M.T,D={};M.T=D,D._updatedFibers=new Set;try{var G=x(),H=M.S;H!==null&&H(D,G),typeof G==="object"&&G!==null&&typeof G.then==="function"&&G.then(Bw,Cx)}catch(W){Cx(W)}finally{$===null&&D._updatedFibers&&(x=D._updatedFibers.size,D._updatedFibers.clear(),10<x&&console.warn("Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table.")),M.T=$}},Uw.unstable_useCacheRefresh=function(){return A().useCacheRefresh()},Uw.use=function(x){return A().use(x)},Uw.useActionState=function(x,$,D){return A().useActionState(x,$,D)},Uw.useCallback=function(x,$){return A().useCallback(x,$)},Uw.useContext=function(x){var $=A();return x.$$typeof===e&&console.error("Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?"),$.useContext(x)},Uw.useDebugValue=function(x,$){return A().useDebugValue(x,$)},Uw.useDeferredValue=function(x,$){return A().useDeferredValue(x,$)},Uw.useEffect=function(x,$,D){x==null&&console.warn("React Hook useEffect requires an effect callback. Did you forget to pass a callback to the hook?");var G=A();if(typeof D==="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return G.useEffect(x,$)},Uw.useId=function(){return A().useId()},Uw.useImperativeHandle=function(x,$,D){return A().useImperativeHandle(x,$,D)},Uw.useInsertionEffect=function(x,$){return x==null&&console.warn("React Hook useInsertionEffect requires an effect callback. Did you forget to pass a callback to the hook?"),A().useInsertionEffect(x,$)},Uw.useLayoutEffect=function(x,$){return x==null&&console.warn("React Hook useLayoutEffect requires an effect callback. Did you forget to pass a callback to the hook?"),A().useLayoutEffect(x,$)},Uw.useMemo=function(x,$){return A().useMemo(x,$)},Uw.useOptimistic=function(x,$){return A().useOptimistic(x,$)},Uw.useReducer=function(x,$,D){return A().useReducer(x,$,D)},Uw.useRef=function(x){return A().useRef(x)},Uw.useState=function(x){return A().useState(x)},Uw.useSyncExternalStore=function(x,$,D){return A().useSyncExternalStore(x,$,D)},Uw.useTransition=function(){return A().useTransition()},Uw.version="19.1.1",typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!=="undefined"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop==="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()});function hx(w){return{type:"container",...w}}function Lx(w,f){return{...f,type:"text",text:w}}function $x(w,f){return{...f,type:"image",src:w}}function X0(w){return w}function Px(w){return{percentage:w}}function mx(w){return{vw:w}}function gx(w){return{vh:w}}function z(w){return{em:w}}function kx(w){return{rem:w}}function bx(w){return{fr:w}}function Z0(w,f,T=0){return{from:w,to:f,angle:T}}function Sx(w,f,T,E=1){return[w,f,T,E]}var Tw=qw(yx(),1);import{renderToString as ew}from"react-dom/server";function Vx(w){return w.replace(/[A-Z]/g,(f)=>`_${f.toLowerCase()}`)}var Cw=["-moz-","-webkit-","-o-","-ms-"];function vx(w){if(typeof w!=="string")return w;if(Fw(w)||Kw(w))return;return w}function Kw(w){return Cw.some((f)=>w.startsWith(f))}function Fw(w){return w==="inherit"||w==="initial"||w==="revert"||w==="unset"}function _w(w){let f=Number.parseInt(w.slice(1),16);if(Number.isNaN(f))throw new Error(`Invalid hex color: ${w}`);if(w.length===4){let T=f>>8&15,E=f>>4&15,X=f&15;return T<<20|T<<16|E<<12|E<<8|X<<4|X}if(w.length===5){let T=f>>12&15,E=f>>8&15,X=f>>4&15,B=f&15;return[T<<4|T,E<<4|E,X<<4|X,B/15]}if(w.length===7)return f;if(w.length===9)return[f>>24&255,f>>16&255,f>>8&255,(f&255)/255];throw new Error(`Invalid hex color: ${w}`)}function hw(w){let f=w.slice(4,-1).split(",").map((T)=>Number.parseInt(T.trim()).toString(16).padStart(2,"0"));if(f.length!==3)throw new Error(`Invalid rgb color: ${w}`);return Number.parseInt(f.join(""),16)}function Lw(w){let f=w.slice(5,-1).split(",").map((E)=>Number.parseFloat(E.trim()));if(f.length!==4)throw new Error(`Invalid rgba color: ${w}`);let T=f;if(T[0]<0||T[0]>255||T[1]<0||T[1]>255||T[2]<0||T[2]>255||T[3]<0||T[3]>1)throw new Error(`Invalid rgba color: ${w}`);return T}function K(w){if(w.startsWith("#"))return _w(w);if(w.startsWith("rgb("))return hw(w);if(w.startsWith("rgba("))return Lw(w);throw new Error(`Invalid color: ${w}`)}function dx(w){if(w==="none")return;let f=w.match(/^linear-gradient\((.*)\)$/i)?.[1];if(!f)throw new Error(`Invalid linear-gradient syntax: ${w}`);let T=f.trim(),E=sx(T,","),X=E[0]?.trim();if(!X)throw new Error(`linear-gradient requires at least one argument: ${w}`);let B=Pw(X),Z=B!==void 0?ix(B):180,Y=B!==void 0?E.slice(1):E;if(Y.length<2)throw new Error(`linear-gradient requires at least two color stops: ${w}`);let O=Y.map(kw);return{angle:Z,stops:Sw(O)}}function sx(w,f){let T=[],E=0,X=0;for(let Z=0;Z<w.length;Z++){let Y=w[Z];if(Y==="(")E++;else if(Y===")")E=Math.max(0,E-1);if(E===0&&w.startsWith(f,Z)){let O=w.slice(X,Z).trim();if(O)T.push(O);X=Z+f.length,Z+=f.length-1}}let B=w.slice(X).trim();if(B)T.push(B);return T}function Pw(w){let f=w.trim();return mw(f)??gw(f)}function mw(w){let f=w.match(/^to\s+(top|bottom|left|right)(?:\s+(top|bottom|left|right))?$/i);if(!f)return;let T=(f[1]??"").toLowerCase(),E=(f[2]??"").toLowerCase(),X={top:0,right:90,bottom:180,left:270},B=X[T]??180;if(!E)return B;let Z=X[E]??180,Y=new Set([B,Z]);if(Y.has(0)&&Y.has(90))return 45;if(Y.has(90)&&Y.has(180))return 135;if(Y.has(180)&&Y.has(270))return 225;if(Y.has(270)&&Y.has(0))return 315;return ix((B+Z)/2)}function gw(w){let f=w.match(/^(-?\d*\.?\d+)\s*(deg|rad|turn)?$/i);if(!f)return;let T=Number.parseFloat(f[1]??"0");switch(f[2]?f[2].toLowerCase():"deg"){case"deg":return T;case"rad":return T*180/Math.PI;case"turn":return T*360;default:return T}}function kw(w){let f=sx(w.trim()," "),T=K(f[0]??w.trim()),E=f[1]?bw(f[1]):void 0;return{color:T,position:E}}function bw(w){let f=w.trim();if(f.endsWith("%"))return Number.parseFloat(f.slice(0,-1))/100;return Number.parseFloat(f)}function Sw(w){if(w.every((Z)=>Z.position===void 0))return yw(w);let f=[],T=w.length,E=w[0];if(!E)throw new Error("First stop must have a position defined");f.push({color:E.color,position:0});for(let Z=1;Z<T-1;Z++){let Y=w[Z];if(typeof Y?.position==="number")f.push({color:Y.color,position:Vw(Y.position)})}let X=w[T-1];if(!X)throw new Error("Last stop must have a position defined");return f.push({color:X.color,position:1}),f.reduce((Z,Y)=>{if(Z.length===0||Z[Z.length-1]?.position!==Y.position)Z.push(Y);return Z},[]).sort((Z,Y)=>Z.position-Y.position)}function yw(w){let f=w.length;return w.map((T,E)=>({color:T.color,position:f===1?0:E/(f-1)}))}function Vw(w){return Math.max(0,Math.min(1,w))}function ix(w){let f=w%360;if(f<0)f+=360;return f}function J(w){if(typeof w==="number")return w;if(w==="auto"||w==="min-content"||w==="max-content")return w;let f=w.match(/^(-?[\d.]+)(.*)$/);if(!f)return 0;let[,T,E]=f;if(!T)return 0;let X=Number.parseFloat(T);switch(E){case"%":return Px(X);case"rem":return kx(X);case"em":return z(X);case"vh":return gx(X);case"vw":return mx(X);case"px":case"":return X;default:return X}}function F(w){if(typeof w==="number")return J(w);let T=w.trim().split(/\s+/).map(J);if(T.length===1)return T[0];if(T.length===2||T.length===4)return T;if(T.length===3&&T[0]!==void 0&&T[1]!==void 0&&T[2]!==void 0)return[T[0],T[1],T[2],T[1]];throw new Error(`Invalid sides value: ${w}. Expected 1 to at most 4 values.`)}function ux(w){if(typeof w==="number")return w;if(typeof w==="string"&&w.includes("/")){let[f,T]=w.split("/").map(Number.parseFloat);if(f===void 0||T===void 0)throw new Error(`Invalid aspect ratio: ${w}. Expected format 'width/height'.`);if(T===0)throw new Error(`Invalid aspect ratio: ${w}. Denominator cannot be zero.`);return f/T}if(typeof w==="string")return Number.parseFloat(w);throw new Error(`Invalid aspect ratio: ${w}`)}function ox(w){switch(w){case"block":case"flex":case"grid":case"none":return w;default:return console.warn(`Invalid display value: ${w}, fallback to 'block'.`),"block"}}function nx(w){switch(w){case"relative":case"absolute":return w;case"static":return"relative";default:return console.warn(`Invalid position value: ${w}, fallback to 'relative'.`),"relative"}}function px(w){let f=w.trim().split(/\s+/);if(f.length<2)throw new Error(`Invalid box-shadow: ${w}`);let T=!1,E="black",X=0;if(f[0]==="inset")T=!0,X=1;let B=/^(#|rgb|rgba|hsl|hsla|[a-zA-Z]+)/,Z=[];for(let q=X;q<f.length;q++){let _=f[q]??"";if(q===f.length-1&&B.test(_))E=_;else Z.push(_)}if(Z.length<2||Z.length>4)throw new Error(`Invalid box-shadow format: ${w}`);let[Y="0px",O="0px",N="0px",U="0px"]=Z;try{return{color:K(E),offset_x:J(Y)??0,offset_y:J(O)??0,blur_radius:J(N)??0,spread_radius:J(U)??0,inset:T}}catch{throw new Error(`Invalid box-shadow color: ${E}`)}}function vw(w){return w.trim().split(/\s+/).map((T)=>{if(T.endsWith("fr")){let E=Number.parseFloat(T.slice(0,-2));if(Number.isNaN(E))return{fr:0};return{fr:E}}return J(T)??0})}function tx(w){switch(w){case"row":case"column":case"row dense":case"column dense":return w.replace(" ","-");default:return console.warn(`Invalid grid-auto-flow value: ${w}, fallback to 'row'.`),"row"}}function dw(w){if(w.startsWith("span ")){let T=Number.parseInt(w.slice(5));if(Number.isNaN(T))throw new Error(`Invalid span value: ${w}`);return{start:T,end:null}}if(w.includes("/")){let T=w.split("/");if(T.length!==2)throw new Error(`Invalid grid line format: ${w}`);let[E="",X=""]=T.map((Y)=>Y.trim()),B=E==="auto"?null:Number.parseInt(E)||E,Z=X==="auto"?null:Number.parseInt(X)||X;return{start:B,end:Z}}if(w==="auto")return{start:null,end:null};let f=Number.parseInt(w);if(Number.isNaN(f))return{start:w,end:null};return{start:f,end:null}}function cx(w){let f=w.match(/repeat\(([^,]+),\s*(.+)\)/);if(f){let T=sw(f);if(!T)throw new Error(`Invalid repeat function: ${w}`);return T}return iw(w)}function sw(w){let[,f,T]=w;if(!f||!T)return;let E;if(f==="auto-fill")E="auto-fill";else if(f==="auto-fit")E="auto-fit";else{let B=Number.parseInt(f);if(Number.isNaN(B))return;E=B}let X=T.trim().split(/\s+/).map((B)=>{if(B.endsWith("fr")){let Z=Number.parseFloat(B.slice(0,-2));return Number.isNaN(Z)?0:{fr:Z}}return J(B)??0});return[{repeat:[E,X]}]}function iw(w){return w.trim().split(/\s+/).map((T)=>{if(T.endsWith("fr")){let E=Number.parseFloat(T.slice(0,-2));return{single:Number.isNaN(E)?0:{fr:E}}}return{single:J(T)??0}})}function lx(w){if(typeof w==="number")return Math.max(1,Math.min(1000,w));if(typeof w==="string")switch(w){case"normal":return 400;case"bold":return 700;case"lighter":return 300;case"bolder":return 600;default:{let f=Number.parseInt(w);if(!Number.isNaN(f))return Math.max(1,Math.min(1000,f))}}return console.warn(`Invalid font-weight value: ${w}, fallback to 400.`),400}function Tx(w){if(typeof w==="string")return vw(w);if(Array.isArray(w))return w;return typeof w==="number"?[w]:[bx(1)]}function Dx(w){if(typeof w==="string")return dw(w);if(typeof w==="number")return{start:w,end:null};return w}function rx(w){if(typeof w==="string")return cx(w);if(Array.isArray(w))return w;return typeof w==="number"?[{single:w}]:[{single:0}]}function ax(w){if(typeof w==="string")return cx(w);if(Array.isArray(w))return w;return typeof w==="number"?[{single:w}]:[{single:0}]}function ex(w){if(w==="none")return 0;return Number(w)}function xw(w){switch(w){case"auto":case"pixelated":return w;case"crisp-edges":return"pixelated";default:return console.warn(`Invalid image-rendering value: ${w}, fallback to 'auto'.`),"auto"}}var g=Symbol("skip-parsing"),uw={display:ox,position:nx,width:J,height:J,maxWidth:J,maxHeight:J,minWidth:J,minHeight:J,aspectRatio:ux,padding:F,margin:F,flexDirection:g,flexWrap:g,justifyContent:(w)=>w,alignContent:(w)=>w,justifySelf:(w)=>w,alignItems:(w)=>w,alignSelf:(w)=>w,justifyItems:(w)=>w,flexBasis:J,gap:J,flexGrow:(w)=>Number(w),flexShrink:(w)=>Number(w),borderWidth:F,backgroundColor:K,backgroundImage:dx,boxShadow:px,objectFit:g,imageRendering:xw,gridAutoColumns:Tx,gridAutoRows:Tx,gridAutoFlow:tx,gridColumn:Dx,gridRow:Dx,gridTemplateColumns:rx,gridTemplateRows:ax,textOverflow:(w)=>w,borderColor:K,color:K,fontSize:J,fontFamily:g,lineHeight:J,fontWeight:lx,lineClamp:ex,borderRadius:(w)=>F(w),textAlign(w){if(w==="match-parent")return void console.warn("Unsupported value for text-align found:",w);return w},letterSpacing:J,inset:(w)=>F(w)},ow=new Set(["top","right","bottom","left","marginTop","marginRight","marginBottom","marginLeft","paddingTop","paddingRight","paddingBottom","paddingLeft"]);function nw(w,f,T){if(ow.has(f))return;let E=vx(T);if(E===void 0||E===null)return;let X=uw[f];if(!X){console.warn(`No parser found for CSS property: ${f}`);return}let B=Vx(f);if(X===g){w[B]=E;return}try{let Z=X(E);if(Z!=null&&Z!==void 0)w[B]=Z}catch(Z){console.warn(`Failed to parse ${f}:`,Z)}}function pw(w){let f=F(w);if(typeof f==="number")return{top:f,right:f,bottom:f,left:f};if(Array.isArray(f)){if(f.length===2)return{top:f[0],right:f[1],bottom:f[0],left:f[1]};if(f.length===4)return{top:f[0],right:f[1],bottom:f[2],left:f[3]}}return{top:0,right:0,bottom:0,left:0}}function tw(w,f,T,E,X,B){let Z=w[T]!==void 0||w[E]!==void 0||w[X]!==void 0||w[B]!==void 0;return w[f]!==void 0&&!Z}function cw(w,f){let T=w[f];if(T!==void 0&&typeof T!=="object")return pw(T);return{top:0,right:0,bottom:0,left:0}}function n(w,f){let T=w[f];if(T!==void 0&&typeof T!=="object")return J(T);return 0}function Ex(w,f,T,E,X,B){if(w[f]===void 0&&w[T]===void 0&&w[E]===void 0&&w[X]===void 0&&w[B]===void 0)return;if(tw(w,f,T,E,X,B)){let q=w[f];if(q!==void 0)return F(q)}let Z=cw(w,f),Y=Z.top,O=Z.right,N=Z.bottom,U=Z.left;if(w[T]!==void 0)Y=n(w,T);if(w[E]!==void 0)O=n(w,E);if(w[X]!==void 0)N=n(w,X);if(w[B]!==void 0)U=n(w,B);if(Y===O&&O===N&&N===U)return Y;return[Y,O,N,U]}function lw(w){return Ex(w,"padding","paddingTop","paddingRight","paddingBottom","paddingLeft")}function rw(w){return Ex(w,"margin","marginTop","marginRight","marginBottom","marginLeft")}function aw(w){return Ex(w,"inset","top","right","bottom","left")}function Gx(w){if(!w)return;let f={};for(let[B,Z]of Object.entries(w))nw(f,B,Z);let T=aw(w);if(T!==void 0)f.inset=T;let E=lw(w);if(E!==void 0)f.padding=E;let X=rw(w);if(X!==void 0)f.margin=X;return Object.keys(f).length>0?f:void 0}var ww={p:{margin:[z(1),0]},blockquote:{margin:[z(1),40]},center:{text_align:"center"},hr:{margin:[z(0.5),"auto"],border_width:1},h1:{font_size:z(2),margin:[z(0.67),0],font_weight:700},h2:{font_size:z(1.5),margin:[z(0.83),0],font_weight:700},h3:{font_size:z(1.17),margin:[z(1),0],font_weight:700},h4:{margin:[z(1.33),0],font_weight:700},h5:{font_size:z(0.83),margin:[z(1.67),0],font_weight:700},h6:{font_size:z(0.67),margin:[z(2.33),0],font_weight:700},strong:{font_weight:700},b:{font_weight:700},code:{font_family:"monospace"},kbd:{font_family:"monospace"},pre:{font_family:"monospace",margin:[z(1),0]},mark:{background_color:Sx(255,255,0),color:0},big:{font_size:19.2},small:{font_size:13.333333333333334}};var x0=Symbol.for("react.transitional.element");function w0(w){return typeof w==="object"&&w!==null&&"$$typeof"in w&&w.$$typeof===x0}async function k(w){if(w===void 0||w===null)return[];if(w instanceof Promise)return k(await w);if(typeof w==="object"&&Symbol.iterator in w)return E0(w);if(w0(w)){let f=await f0(w);return Array.isArray(f)?f:f?[f]:[]}return[Lx(String(w))]}async function f0(w){if(typeof w.type==="function"){let E=w.type;return k(E(w.props))}if(typeof w.type==="symbol"&&w.type===Symbol.for("react.fragment"))return await $w(w)||[];if(fw(w,"img"))return $0(w);if(fw(w,"svg"))return[T0(w)];let f=await $w(w),T=D0(w.props);return[hx({children:f,...ww[w.type],...Gx(T)})]}function $0(w){if(!w.props.src)throw new Error("Image element must have a 'src' prop.");let f=w.props.style?.width??w.props.width,T=w.props.style?.height??w.props.height;return[$x(w.props.src,{...Gx(w.props.style),width:f?J(f):void 0,height:T?J(T):void 0})]}function T0(w){return $x(ew(Tw.cloneElement(w,{xmlns:"http://www.w3.org/2000/svg",...w.props},w.props.children)))}function D0(w){return typeof w==="object"&&w&&"style"in w?w.style:void 0}function fw(w,f){return w.type===f}async function $w(w){if(typeof w.props!=="object"||w.props===null||!("children"in w.props))return[];return await k(w.props.children)}async function E0(w){return(await Promise.all(Array.from(w).map(k))).flat()}export{mx as vw,gx as vh,Lx as text,X0 as style,Sx as rgba,kx as rem,Px as percentage,$x as image,Z0 as gradient,k as fromJsx,bx as fr,z as em,hx as container};
13
+ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`),x}function Ew(){}function V(x){if(s===null)try{var $=("require"+Math.random()).slice(0,7);s=(n&&n[$]).call(n,"timers").setImmediate}catch(G){s=function(Z){Cx===!1&&(Cx=!0,typeof MessageChannel==="undefined"&&console.error("This browser does not have a MessageChannel implementation, so enqueuing tasks via await act(async () => ...) will fail. Please file an issue at https://github.com/facebook/react/issues if you encounter this warning."));var f=new MessageChannel;f.port1.onmessage=Z,f.port2.postMessage(void 0)}}return s(x)}function m(x){return 1<x.length&&typeof AggregateError==="function"?new AggregateError(x):x[0]}function b(x,$){$!==i-1&&console.error("You seem to have overlapping act() calls, this is not supported. Be sure to await previous act() calls before making a new one. "),i=$}function c(x,$,G){var Z=R.actQueue;if(Z!==null)if(Z.length!==0)try{l(Z),V(function(){return c(x,$,G)});return}catch(f){R.thrownErrors.push(f)}else R.actQueue=null;0<R.thrownErrors.length?(Z=m(R.thrownErrors),R.thrownErrors.length=0,G(Z)):$(x)}function l(x){if(!Tx){Tx=!0;var $=0;try{for(;$<x.length;$++){var G=x[$];do{R.didUsePromise=!1;var Z=G(!1);if(Z!==null){if(R.didUsePromise){x[$]=G,x.splice(0,$);return}G=Z}else break}while(1)}x.length=0}catch(f){x.splice(0,$+1),R.thrownErrors.push(f)}finally{Tx=!1}}}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!=="undefined"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart==="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var r=Symbol.for("react.transitional.element"),Hx=Symbol.for("react.portal"),a=Symbol.for("react.fragment"),fx=Symbol.for("react.strict_mode"),Ex=Symbol.for("react.profiler"),e=Symbol.for("react.consumer"),Qx=Symbol.for("react.context"),Yx=Symbol.for("react.forward_ref"),Mx=Symbol.for("react.suspense"),Qw=Symbol.for("react.suspense_list"),xx=Symbol.for("react.memo"),g=Symbol.for("react.lazy"),Yw=Symbol.for("react.activity"),Rx=Symbol.iterator,Jx={},Wx={isMounted:function(){return!1},enqueueForceUpdate:function(x){D(x,"forceUpdate")},enqueueReplaceState:function(x){D(x,"replaceState")},enqueueSetState:function(x){D(x,"setState")}},Ax=Object.assign,wx={};Object.freeze(wx),X.prototype.isReactComponent={},X.prototype.setState=function(x,$){if(typeof x!=="object"&&typeof x!=="function"&&x!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,x,$,"setState")},X.prototype.forceUpdate=function(x){this.updater.enqueueForceUpdate(this,x,"forceUpdate")};var I={isMounted:["isMounted","Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks."],replaceState:["replaceState","Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)."]},v;for(v in I)I.hasOwnProperty(v)&&w(v,I[v]);B.prototype=X.prototype,I=E.prototype=new B,I.constructor=E,Ax(I,X.prototype),I.isPureReactComponent=!0;var zx=Array.isArray,Mw=Symbol.for("react.client.reference"),R={H:null,A:null,T:null,S:null,V:null,actQueue:null,isBatchingLegacy:!1,didScheduleLegacyUpdate:!1,didUsePromise:!1,thrownErrors:[],getCurrentStack:null,recentlyCreatedOwnerStacks:0},d=Object.prototype.hasOwnProperty,Ox=console.createTask?console.createTask:function(){return null};I={react_stack_bottom_frame:function(x){return x()}};var qx,Ix,jx={},Rw=I.react_stack_bottom_frame.bind(I,j)(),Jw=Ox(U(j)),Ux=!1,Kx=/\/+/g,Nx=typeof reportError==="function"?reportError:function(x){if(typeof window==="object"&&typeof window.ErrorEvent==="function"){var $=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof x==="object"&&x!==null&&typeof x.message==="string"?String(x.message):String(x),error:x});if(!window.dispatchEvent($))return}else if(typeof process==="object"&&typeof process.emit==="function"){process.emit("uncaughtException",x);return}console.error(x)},Cx=!1,s=null,i=0,u=!1,Tx=!1,Fx=typeof queueMicrotask==="function"?function(x){queueMicrotask(function(){return queueMicrotask(x)})}:V;I=Object.freeze({__proto__:null,c:function(x){return z().useMemoCache(x)}}),Kw.Children={map:y,forEach:function(x,$,G){y(x,function(){$.apply(this,arguments)},G)},count:function(x){var $=0;return y(x,function(){$++}),$},toArray:function(x){return y(x,function($){return $})||[]},only:function(x){if(!L(x))throw Error("React.Children.only expected to receive a single React element child.");return x}},Kw.Component=X,Kw.Fragment=a,Kw.Profiler=Ex,Kw.PureComponent=E,Kw.StrictMode=fx,Kw.Suspense=Mx,Kw.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=R,Kw.__COMPILER_RUNTIME=I,Kw.act=function(x){var $=R.actQueue,G=i;i++;var Z=R.actQueue=$!==null?$:[],f=!1;try{var J=x()}catch(M){R.thrownErrors.push(M)}if(0<R.thrownErrors.length)throw b($,G),x=m(R.thrownErrors),R.thrownErrors.length=0,x;if(J!==null&&typeof J==="object"&&typeof J.then==="function"){var Q=J;return Fx(function(){f||u||(u=!0,console.error("You called act(async () => ...) without await. This could lead to unexpected testing behaviour, interleaving multiple act calls and mixing their scopes. You should - await act(async () => ...);"))}),{then:function(M,N){f=!0,Q.then(function(P){if(b($,G),G===0){try{l(Z),V(function(){return c(P,M,N)})}catch(Aw){R.thrownErrors.push(Aw)}if(0<R.thrownErrors.length){var Ww=m(R.thrownErrors);R.thrownErrors.length=0,N(Ww)}}else M(P)},function(P){b($,G),0<R.thrownErrors.length?(P=m(R.thrownErrors),R.thrownErrors.length=0,N(P)):N(P)})}}}var W=J;if(b($,G),G===0&&(l(Z),Z.length!==0&&Fx(function(){f||u||(u=!0,console.error("A component suspended inside an `act` scope, but the `act` call was not awaited. When testing React components that depend on asynchronous data, you must await the result:\n\nawait act(() => ...)"))}),R.actQueue=null),0<R.thrownErrors.length)throw x=m(R.thrownErrors),R.thrownErrors.length=0,x;return{then:function(M,N){f=!0,G===0?(R.actQueue=Z,V(function(){return c(W,M,N)})):M(W)}}},Kw.cache=function(x){return function(){return x.apply(null,arguments)}},Kw.captureOwnerStack=function(){var x=R.getCurrentStack;return x===null?null:x()},Kw.cloneElement=function(x,$,G){if(x===null||x===void 0)throw Error("The argument must be a React element, but you passed "+x+".");var Z=Ax({},x.props),f=x.key,J=x._owner;if($!=null){var Q;x:{if(d.call($,"ref")&&(Q=Object.getOwnPropertyDescriptor($,"ref").get)&&Q.isReactWarning){Q=!1;break x}Q=$.ref!==void 0}Q&&(J=K()),_($)&&(Y($.key),f=""+$.key);for(W in $)!d.call($,W)||W==="key"||W==="__self"||W==="__source"||W==="ref"&&$.ref===void 0||(Z[W]=$[W])}var W=arguments.length-2;if(W===1)Z.children=G;else if(1<W){Q=Array(W);for(var M=0;M<W;M++)Q[M]=arguments[M+2];Z.children=Q}Z=t(x.type,f,void 0,void 0,J,Z,x._debugStack,x._debugTask);for(f=2;f<arguments.length;f++)J=arguments[f],L(J)&&J._store&&(J._store.validated=1);return Z},Kw.createContext=function(x){return x={$$typeof:Qx,_currentValue:x,_currentValue2:x,_threadCount:0,Provider:null,Consumer:null},x.Provider=x,x.Consumer={$$typeof:e,_context:x},x._currentRenderer=null,x._currentRenderer2=null,x},Kw.createElement=function(x,$,G){for(var Z=2;Z<arguments.length;Z++){var f=arguments[Z];L(f)&&f._store&&(f._store.validated=1)}if(Z={},f=null,$!=null)for(M in Ix||!("__self"in $)||"key"in $||(Ix=!0,console.warn("Your app (or one of its dependencies) is using an outdated JSX transform. Update to the modern JSX transform for faster performance: https://react.dev/link/new-jsx-transform")),_($)&&(Y($.key),f=""+$.key),$)d.call($,M)&&M!=="key"&&M!=="__self"&&M!=="__source"&&(Z[M]=$[M]);var J=arguments.length-2;if(J===1)Z.children=G;else if(1<J){for(var Q=Array(J),W=0;W<J;W++)Q[W]=arguments[W+2];Object.freeze&&Object.freeze(Q),Z.children=Q}if(x&&x.defaultProps)for(M in J=x.defaultProps,J)Z[M]===void 0&&(Z[M]=J[M]);f&&Gw(Z,typeof x==="function"?x.displayName||x.name||"Unknown":x);var M=1e4>R.recentlyCreatedOwnerStacks++;return t(x,f,void 0,void 0,K(),Z,M?Error("react-stack-top-frame"):Rw,M?Ox(U(x)):Jw)},Kw.createRef=function(){var x={current:null};return Object.seal(x),x},Kw.forwardRef=function(x){x!=null&&x.$$typeof===xx?console.error("forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...))."):typeof x!=="function"?console.error("forwardRef requires a render function but was given %s.",x===null?"null":typeof x):x.length!==0&&x.length!==2&&console.error("forwardRef render functions accept exactly two parameters: props and ref. %s",x.length===1?"Did you forget to use the ref parameter?":"Any additional parameter will be undefined."),x!=null&&x.defaultProps!=null&&console.error("forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?");var $={$$typeof:Yx,render:x},G;return Object.defineProperty($,"displayName",{enumerable:!1,configurable:!0,get:function(){return G},set:function(Z){G=Z,x.name||x.displayName||(Object.defineProperty(x,"name",{value:Z}),x.displayName=Z)}}),$},Kw.isValidElement=L,Kw.lazy=function(x){return{$$typeof:g,_payload:{_status:-1,_result:x},_init:fw}},Kw.memo=function(x,$){x==null&&console.error("memo: The first argument must be a component. Instead received: %s",x===null?"null":typeof x),$={$$typeof:xx,type:x,compare:$===void 0?null:$};var G;return Object.defineProperty($,"displayName",{enumerable:!1,configurable:!0,get:function(){return G},set:function(Z){G=Z,x.name||x.displayName||(Object.defineProperty(x,"name",{value:Z}),x.displayName=Z)}}),$},Kw.startTransition=function(x){var $=R.T,G={};R.T=G,G._updatedFibers=new Set;try{var Z=x(),f=R.S;f!==null&&f(G,Z),typeof Z==="object"&&Z!==null&&typeof Z.then==="function"&&Z.then(Ew,Nx)}catch(J){Nx(J)}finally{$===null&&G._updatedFibers&&(x=G._updatedFibers.size,G._updatedFibers.clear(),10<x&&console.warn("Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table.")),R.T=$}},Kw.unstable_useCacheRefresh=function(){return z().useCacheRefresh()},Kw.use=function(x){return z().use(x)},Kw.useActionState=function(x,$,G){return z().useActionState(x,$,G)},Kw.useCallback=function(x,$){return z().useCallback(x,$)},Kw.useContext=function(x){var $=z();return x.$$typeof===e&&console.error("Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?"),$.useContext(x)},Kw.useDebugValue=function(x,$){return z().useDebugValue(x,$)},Kw.useDeferredValue=function(x,$){return z().useDeferredValue(x,$)},Kw.useEffect=function(x,$,G){x==null&&console.warn("React Hook useEffect requires an effect callback. Did you forget to pass a callback to the hook?");var Z=z();if(typeof G==="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return Z.useEffect(x,$)},Kw.useId=function(){return z().useId()},Kw.useImperativeHandle=function(x,$,G){return z().useImperativeHandle(x,$,G)},Kw.useInsertionEffect=function(x,$){return x==null&&console.warn("React Hook useInsertionEffect requires an effect callback. Did you forget to pass a callback to the hook?"),z().useInsertionEffect(x,$)},Kw.useLayoutEffect=function(x,$){return x==null&&console.warn("React Hook useLayoutEffect requires an effect callback. Did you forget to pass a callback to the hook?"),z().useLayoutEffect(x,$)},Kw.useMemo=function(x,$){return z().useMemo(x,$)},Kw.useOptimistic=function(x,$){return z().useOptimistic(x,$)},Kw.useReducer=function(x,$,G){return z().useReducer(x,$,G)},Kw.useRef=function(x){return z().useRef(x)},Kw.useState=function(x){return z().useState(x)},Kw.useSyncExternalStore=function(x,$,G){return z().useSyncExternalStore(x,$,G)},Kw.useTransition=function(){return z().useTransition()},Kw.version="19.1.1",typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!=="undefined"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop==="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()});function Lx(w){return{type:"container",...w}}function hx(w,T){return{...T,type:"text",text:w}}function $x(w,T){return{...T,type:"image",src:w}}function BT(w){return w}function Px(w){return{percentage:w}}function mx(w){return{vw:w}}function kx(w){return{vh:w}}function O(w){return{em:w}}function Sx(w){return{rem:w}}function yx(w){return{fr:w}}function HT(w,T,D=0){return{from:w,to:T,angle:D}}function Vx(w,T,D,X=1){return[w,T,D,X]}var Dw=jw(bx(),1);import{renderToString as ew}from"react-dom/server";function gx(w){return w.replace(/[A-Z]/g,(T)=>`_${T.toLowerCase()}`)}var Nw=["-moz-","-webkit-","-o-","-ms-"];function vx(w){if(typeof w!=="string")return w;if(Fw(w)||Cw(w))return;return w}function Cw(w){return Nw.some((T)=>w.startsWith(T))}function Fw(w){return w==="inherit"||w==="initial"||w==="revert"||w==="unset"}function _w(w){let T=Number.parseInt(w.slice(1),16);if(Number.isNaN(T))throw new Error(`Invalid hex color: ${w}`);if(w.length===4){let D=T>>8&15,X=T>>4&15,B=T&15;return D<<20|D<<16|X<<12|X<<8|B<<4|B}if(w.length===5){let D=T>>12&15,X=T>>8&15,B=T>>4&15,E=T&15;return[D<<4|D,X<<4|X,B<<4|B,E/15]}if(w.length===7)return T;if(w.length===9)return[T>>24&255,T>>16&255,T>>8&255,(T&255)/255];throw new Error(`Invalid hex color: ${w}`)}function Lw(w){let T=w.slice(4,-1).split(",").map((D)=>Number.parseInt(D.trim()).toString(16).padStart(2,"0"));if(T.length!==3)throw new Error(`Invalid rgb color: ${w}`);return Number.parseInt(T.join(""),16)}function hw(w){let T=w.slice(5,-1).split(",").map((X)=>Number.parseFloat(X.trim()));if(T.length!==4)throw new Error(`Invalid rgba color: ${w}`);let D=T;if(D[0]<0||D[0]>255||D[1]<0||D[1]>255||D[2]<0||D[2]>255||D[3]<0||D[3]>1)throw new Error(`Invalid rgba color: ${w}`);return D}function C(w){if(w.startsWith("#"))return _w(w);if(w.startsWith("rgb("))return Lw(w);if(w.startsWith("rgba("))return hw(w);if(w.toLowerCase()==="transparent")return[0,0,0,0];throw new Error(`Invalid color: ${w}`)}function dx(w){if(w==="none")return;let T=w.match(/^linear-gradient\((.*)\)$/i)?.[1];if(!T)throw new Error(`Invalid linear-gradient syntax: ${w}`);let D=T.trim(),X=sx(D,","),B=X[0]?.trim();if(!B)throw new Error(`linear-gradient requires at least one argument: ${w}`);let E=Pw(B),H=E!==void 0?ix(E):180,Y=E!==void 0?X.slice(1):X;if(Y.length<2)throw new Error(`linear-gradient requires at least two color stops: ${w}`);let q=Y.map(Sw);return{angle:H,stops:Vw(q)}}function sx(w,T){let D=[],X=0,B=0;for(let H=0;H<w.length;H++){let Y=w[H];if(Y==="(")X++;else if(Y===")")X=Math.max(0,X-1);if(X===0&&w.startsWith(T,H)){let q=w.slice(B,H).trim();if(q)D.push(q);B=H+T.length,H+=T.length-1}}let E=w.slice(B).trim();if(E)D.push(E);return D}function Pw(w){let T=w.trim();return mw(T)??kw(T)}function mw(w){let T=w.match(/^to\s+(top|bottom|left|right)(?:\s+(top|bottom|left|right))?$/i);if(!T)return;let D=(T[1]??"").toLowerCase(),X=(T[2]??"").toLowerCase(),B={top:0,right:90,bottom:180,left:270},E=B[D]??180;if(!X)return E;let H=B[X]??180,Y=new Set([E,H]);if(Y.has(0)&&Y.has(90))return 45;if(Y.has(90)&&Y.has(180))return 135;if(Y.has(180)&&Y.has(270))return 225;if(Y.has(270)&&Y.has(0))return 315;return ix((E+H)/2)}function kw(w){let T=w.match(/^(-?\d*\.?\d+)\s*(deg|rad|turn)?$/i);if(!T)return;let D=Number.parseFloat(T[1]??"0");switch(T[2]?T[2].toLowerCase():"deg"){case"deg":return D;case"rad":return D*180/Math.PI;case"turn":return D*360;default:return D}}function Sw(w){let T=sx(w.trim()," "),D=C(T[0]??w.trim()),X=T[1]?yw(T[1]):void 0;return{color:D,position:X}}function yw(w){let T=w.trim();if(T.endsWith("%"))return Number.parseFloat(T.slice(0,-1))/100;return Number.parseFloat(T)}function Vw(w){if(w.every((H)=>H.position===void 0))return bw(w);let T=[],D=w.length,X=w[0];if(!X)throw new Error("First stop must have a position defined");T.push({color:X.color,position:0});for(let H=1;H<D-1;H++){let Y=w[H];if(typeof Y?.position==="number")T.push({color:Y.color,position:gw(Y.position)})}let B=w[D-1];if(!B)throw new Error("Last stop must have a position defined");return T.push({color:B.color,position:1}),T.reduce((H,Y)=>{if(H.length===0||H[H.length-1]?.position!==Y.position)H.push(Y);return H},[]).sort((H,Y)=>H.position-Y.position)}function bw(w){let T=w.length;return w.map((D,X)=>({color:D.color,position:T===1?0:X/(T-1)}))}function gw(w){return Math.max(0,Math.min(1,w))}function ix(w){let T=w%360;if(T<0)T+=360;return T}function A(w){if(typeof w==="number")return w;if(w==="auto"||w==="min-content"||w==="max-content")return w;let T=w.match(/^(-?[\d.]+)(.*)$/);if(!T)return 0;let[,D,X]=T;if(!D)return 0;let B=Number.parseFloat(D);switch(X){case"%":return Px(B);case"rem":return Sx(B);case"em":return O(B);case"vh":return kx(B);case"vw":return mx(B);case"px":case"":return B;default:return B}}function F(w){if(typeof w==="number")return A(w);let D=w.trim().split(/\s+/).map(A);if(D.length===1)return D[0];if(D.length===2||D.length===4)return D;if(D.length===3&&D[0]!==void 0&&D[1]!==void 0&&D[2]!==void 0)return[D[0],D[1],D[2],D[1]];throw new Error(`Invalid sides value: ${w}. Expected 1 to at most 4 values.`)}function ux(w){if(typeof w==="number")return w;if(typeof w==="string"&&w.includes("/")){let[T,D]=w.split("/").map(Number.parseFloat);if(T===void 0||D===void 0)throw new Error(`Invalid aspect ratio: ${w}. Expected format 'width/height'.`);if(D===0)throw new Error(`Invalid aspect ratio: ${w}. Denominator cannot be zero.`);return T/D}if(typeof w==="string")return Number.parseFloat(w);throw new Error(`Invalid aspect ratio: ${w}`)}function nx(w){switch(w){case"block":case"flex":case"grid":case"none":return w;default:return console.warn(`Invalid display value: ${w}, fallback to 'block'.`),"block"}}function px(w){switch(w){case"relative":case"absolute":return w;case"static":return"relative";default:return console.warn(`Invalid position value: ${w}, fallback to 'relative'.`),"relative"}}function tx(w){let T=w.trim().split(/\s+/);if(T.length<2)throw new Error(`Invalid box-shadow: ${w}`);let D=!1,X="black",B=0;if(T[0]==="inset")D=!0,B=1;let E=/^(#|rgb|rgba|hsl|hsla|[a-zA-Z]+)/,H=[];for(let j=B;j<T.length;j++){let _=T[j]??"";if(j===T.length-1&&E.test(_))X=_;else H.push(_)}if(H.length<2||H.length>4)throw new Error(`Invalid box-shadow format: ${w}`);let[Y="0px",q="0px",U="0px",K="0px"]=H;try{return{color:C(X),offset_x:A(Y)??0,offset_y:A(q)??0,blur_radius:A(U)??0,spread_radius:A(K)??0,inset:D}}catch{throw new Error(`Invalid box-shadow color: ${X}`)}}function vw(w){return w.trim().split(/\s+/).map((D)=>{if(D.endsWith("fr")){let X=Number.parseFloat(D.slice(0,-2));if(Number.isNaN(X))return{fr:0};return{fr:X}}return A(D)??0})}function ox(w){switch(w){case"row":case"column":case"row dense":case"column dense":return w.replace(" ","-");default:return console.warn(`Invalid grid-auto-flow value: ${w}, fallback to 'row'.`),"row"}}function dw(w){if(w.startsWith("span ")){let D=Number.parseInt(w.slice(5));if(Number.isNaN(D))throw new Error(`Invalid span value: ${w}`);return{start:D,end:null}}if(w.includes("/")){let D=w.split("/");if(D.length!==2)throw new Error(`Invalid grid line format: ${w}`);let[X="",B=""]=D.map((Y)=>Y.trim()),E=X==="auto"?null:Number.parseInt(X)||X,H=B==="auto"?null:Number.parseInt(B)||B;return{start:E,end:H}}if(w==="auto")return{start:null,end:null};let T=Number.parseInt(w);if(Number.isNaN(T))return{start:w,end:null};return{start:T,end:null}}function cx(w){let T=w.match(/repeat\(([^,]+),\s*(.+)\)/);if(T){let D=sw(T);if(!D)throw new Error(`Invalid repeat function: ${w}`);return D}return iw(w)}function sw(w){let[,T,D]=w;if(!T||!D)return;let X;if(T==="auto-fill")X="auto-fill";else if(T==="auto-fit")X="auto-fit";else{let E=Number.parseInt(T);if(Number.isNaN(E))return;X=E}let B=D.trim().split(/\s+/).map((E)=>{if(E.endsWith("fr")){let H=Number.parseFloat(E.slice(0,-2));return Number.isNaN(H)?0:{fr:H}}return A(E)??0});return[{repeat:[X,B]}]}function iw(w){return w.trim().split(/\s+/).map((D)=>{if(D.endsWith("fr")){let X=Number.parseFloat(D.slice(0,-2));return{single:Number.isNaN(X)?0:{fr:X}}}return{single:A(D)??0}})}function lx(w){if(typeof w==="number")return Math.max(1,Math.min(1000,w));if(typeof w==="string")switch(w){case"normal":return 400;case"bold":return 700;case"lighter":return 300;case"bolder":return 600;default:{let T=Number.parseInt(w);if(!Number.isNaN(T))return Math.max(1,Math.min(1000,T))}}return console.warn(`Invalid font-weight value: ${w}, fallback to 400.`),400}function Dx(w){if(typeof w==="string")return vw(w);if(Array.isArray(w))return w;return typeof w==="number"?[w]:[yx(1)]}function Gx(w){if(typeof w==="string")return dw(w);if(typeof w==="number")return{start:w,end:null};return w}function rx(w){if(typeof w==="string")return cx(w);if(Array.isArray(w))return w;return typeof w==="number"?[{single:w}]:[{single:0}]}function ax(w){if(typeof w==="string")return cx(w);if(Array.isArray(w))return w;return typeof w==="number"?[{single:w}]:[{single:0}]}function ex(w){if(w==="none")return 0;return Number(w)}function xw(w){switch(w){case"auto":case"pixelated":return w;case"crisp-edges":return"pixelated";default:return console.warn(`Invalid image-rendering value: ${w}, fallback to 'auto'.`),"auto"}}var k=Symbol("skip-parsing"),uw={display:nx,position:px,width:A,height:A,maxWidth:A,maxHeight:A,minWidth:A,minHeight:A,aspectRatio:ux,padding:F,margin:F,flexDirection:k,flexWrap:k,justifyContent:(w)=>w,alignContent:(w)=>w,justifySelf:(w)=>w,alignItems:(w)=>w,alignSelf:(w)=>w,justifyItems:(w)=>w,flexBasis:A,gap:A,flexGrow:(w)=>Number(w),flexShrink:(w)=>Number(w),borderWidth:F,backgroundColor:C,backgroundImage:dx,boxShadow:tx,objectFit:k,imageRendering:xw,gridAutoColumns:Dx,gridAutoRows:Dx,gridAutoFlow:ox,gridColumn:Gx,gridRow:Gx,gridTemplateColumns:rx,gridTemplateRows:ax,textOverflow:(w)=>w,borderColor:C,color:C,fontSize:A,fontFamily:k,lineHeight:A,fontWeight:lx,lineClamp:ex,borderRadius:(w)=>F(w),textAlign(w){if(w==="match-parent")return void console.warn("Unsupported value for text-align found:",w);return w},letterSpacing:A,inset:(w)=>F(w)},nw=new Set(["top","right","bottom","left","marginTop","marginRight","marginBottom","marginLeft","paddingTop","paddingRight","paddingBottom","paddingLeft"]);function pw(w,T,D){if(nw.has(T))return;let X=vx(D);if(X===void 0||X===null)return;let B=uw[T];if(!B){console.warn(`No parser found for CSS property: ${T}`);return}let E=gx(T);if(B===k){w[E]=X;return}try{let H=B(X);if(H!=null&&H!==void 0)w[E]=H}catch(H){console.warn(`Failed to parse ${T}:`,H)}}function tw(w){let T=F(w);if(typeof T==="number")return{top:T,right:T,bottom:T,left:T};if(Array.isArray(T)){if(T.length===2)return{top:T[0],right:T[1],bottom:T[0],left:T[1]};if(T.length===4)return{top:T[0],right:T[1],bottom:T[2],left:T[3]}}return{top:0,right:0,bottom:0,left:0}}function ow(w,T,D,X,B,E){let H=w[D]!==void 0||w[X]!==void 0||w[B]!==void 0||w[E]!==void 0;return w[T]!==void 0&&!H}function cw(w,T){let D=w[T];if(D!==void 0&&typeof D!=="object")return tw(D);return{top:0,right:0,bottom:0,left:0}}function p(w,T){let D=w[T];if(D!==void 0&&typeof D!=="object")return A(D);return 0}function Xx(w,T,D,X,B,E){if(w[T]===void 0&&w[D]===void 0&&w[X]===void 0&&w[B]===void 0&&w[E]===void 0)return;if(ow(w,T,D,X,B,E)){let j=w[T];if(j!==void 0)return F(j)}let H=cw(w,T),Y=H.top,q=H.right,U=H.bottom,K=H.left;if(w[D]!==void 0)Y=p(w,D);if(w[X]!==void 0)q=p(w,X);if(w[B]!==void 0)U=p(w,B);if(w[E]!==void 0)K=p(w,E);if(Y===q&&q===U&&U===K)return Y;return[Y,q,U,K]}function lw(w){return Xx(w,"padding","paddingTop","paddingRight","paddingBottom","paddingLeft")}function rw(w){return Xx(w,"margin","marginTop","marginRight","marginBottom","marginLeft")}function aw(w){return Xx(w,"inset","top","right","bottom","left")}function Zx(w){if(!w)return;let T={};for(let[E,H]of Object.entries(w))pw(T,E,H);let D=aw(w);if(D!==void 0)T.inset=D;let X=lw(w);if(X!==void 0)T.padding=X;let B=rw(w);if(B!==void 0)T.margin=B;return Object.keys(T).length>0?T:void 0}var ww={p:{margin:[O(1),0]},blockquote:{margin:[O(1),40]},center:{text_align:"center"},hr:{margin:[O(0.5),"auto"],border_width:1},h1:{font_size:O(2),margin:[O(0.67),0],font_weight:700},h2:{font_size:O(1.5),margin:[O(0.83),0],font_weight:700},h3:{font_size:O(1.17),margin:[O(1),0],font_weight:700},h4:{margin:[O(1.33),0],font_weight:700},h5:{font_size:O(0.83),margin:[O(1.67),0],font_weight:700},h6:{font_size:O(0.67),margin:[O(2.33),0],font_weight:700},strong:{font_weight:700},b:{font_weight:700},code:{font_family:"monospace"},kbd:{font_family:"monospace"},pre:{font_family:"monospace",margin:[O(1),0]},mark:{background_color:Vx(255,255,0),color:0},big:{font_size:19.2},small:{font_size:13.333333333333334}};var xT=Symbol.for("react.transitional.element");function wT(w){return typeof w==="object"&&w!==null&&"$$typeof"in w&&w.$$typeof===xT}async function S(w){if(w===void 0||w===null)return[];if(w instanceof Promise)return S(await w);if(typeof w==="object"&&Symbol.iterator in w)return XT(w);if(wT(w)){let T=await TT(w);return Array.isArray(T)?T:T?[T]:[]}return[hx(String(w))]}async function TT(w){if(typeof w.type==="function"){let X=w.type;return S(X(w.props))}if(typeof w.type==="symbol"&&w.type===Symbol.for("react.fragment"))return await $w(w)||[];if(Tw(w,"img"))return $T(w);if(Tw(w,"svg"))return[DT(w)];let T=await $w(w),D=GT(w.props);return[Lx({children:T,...ww[w.type],...Zx(D)})]}function $T(w){if(!w.props.src)throw new Error("Image element must have a 'src' prop.");let T=w.props.style?.width??w.props.width,D=w.props.style?.height??w.props.height;return[$x(w.props.src,{...Zx(w.props.style),width:T?A(T):void 0,height:D?A(D):void 0})]}function DT(w){return $x(ew(Dw.cloneElement(w,{xmlns:"http://www.w3.org/2000/svg",...w.props},w.props.children)))}function GT(w){return typeof w==="object"&&w&&"style"in w?w.style:void 0}function Tw(w,T){return w.type===T}async function $w(w){if(typeof w.props!=="object"||w.props===null||!("children"in w.props))return[];return await S(w.props.children)}async function XT(w){return(await Promise.all(Array.from(w).map(S))).flat()}export{mx as vw,kx as vh,hx as text,BT as style,Vx as rgba,Sx as rem,Px as percentage,$x as image,HT as gradient,S as fromJsx,yx as fr,O as em,Lx as container};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@takumi-rs/helpers",
3
- "version": "0.19.0",
3
+ "version": "0.20.0",
4
4
  "author": {
5
5
  "email": "me@kane.tw",
6
6
  "name": "Kane Wang",
@@ -19,7 +19,12 @@
19
19
  "typescript": "catalog:"
20
20
  },
21
21
  "peerDependencies": {
22
- "react-dom": "^19.1.1"
22
+ "react-dom": "^19.0.0"
23
+ },
24
+ "peerDependenciesMeta": {
25
+ "react-dom": {
26
+ "optional": true
27
+ }
23
28
  },
24
29
  "exports": {
25
30
  "types": "./dist/index.d.ts",