@volter/world-ui 1.0.18 → 1.0.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/client/sign-in.tsx
CHANGED
|
@@ -10,8 +10,8 @@ export type SignInProps = {
|
|
|
10
10
|
action: string;
|
|
11
11
|
fields: Record<string, string>;
|
|
12
12
|
/** the account field and the password field: their names, labels and (the account's) prefilled value */
|
|
13
|
-
account: { name: string; label: string; value?: string };
|
|
14
|
-
password: { name: string; label: string };
|
|
13
|
+
account: { name: string; label: string; value?: string; id?: string };
|
|
14
|
+
password: { name: string; label: string; id?: string; autoComplete?: 'current-password' | 'new-password' };
|
|
15
15
|
submit: string;
|
|
16
16
|
/** the vendor's message for a refused attempt ("Incorrect username or password.") */
|
|
17
17
|
error?: string;
|
|
@@ -25,10 +25,12 @@ export function SignIn(props: SignInProps) {
|
|
|
25
25
|
{props.error ? <div className="sign-in-error" role="alert">{props.error}</div> : null}
|
|
26
26
|
<form method="post" action={props.action} className="sign-in-box">
|
|
27
27
|
{Object.entries(props.fields).map(([name, value]) => <input key={name} type="hidden" name={name} value={value} />)}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
<label htmlFor={props.
|
|
31
|
-
<input id={props.
|
|
28
|
+
{/* a field's id is its name unless the page gives another: a page with two sign-in forms (a login and a
|
|
29
|
+
create-account, as Hacker News's) keeps every id one of its own, so each label names its own field */}
|
|
30
|
+
<label htmlFor={props.account.id ?? props.account.name}>{props.account.label}</label>
|
|
31
|
+
<input id={props.account.id ?? props.account.name} name={props.account.name} type="text" autoComplete="username" defaultValue={props.account.value ?? ''} />
|
|
32
|
+
<label htmlFor={props.password.id ?? props.password.name}>{props.password.label}</label>
|
|
33
|
+
<input id={props.password.id ?? props.password.name} name={props.password.name} type="password" autoComplete={props.password.autoComplete ?? 'current-password'} />
|
|
32
34
|
<button type="submit" className="sign-in-submit">{props.submit}</button>
|
|
33
35
|
</form>
|
|
34
36
|
</main>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var mB=Object.create;var{getPrototypeOf:uB,defineProperty:vB,getOwnPropertyNames:sB}=Object;var dB=Object.prototype.hasOwnProperty;function yB(
|
|
1
|
+
var mB=Object.create;var{getPrototypeOf:uB,defineProperty:vB,getOwnPropertyNames:sB}=Object;var dB=Object.prototype.hasOwnProperty;function yB(U){return this[U]}var cB,iB,JB=(U,P,w)=>{var F=U!=null&&typeof U==="object";if(F){var C=P?cB??=new WeakMap:iB??=new WeakMap,I=C.get(U);if(I)return I}w=U!=null?mB(uB(U)):{};let A=P||!U||!U.__esModule?vB(w,"default",{value:U,enumerable:!0}):w;for(let x of sB(U))if(!dB.call(A,x))vB(A,x,{get:yB.bind(U,x),enumerable:!0});if(F)C.set(U,A);return A};var CB=(U,P)=>()=>(P||U((P={exports:{}}).exports,P),P.exports);var gB=CB((pB,XB)=>{(function(){function U(B,G){Object.defineProperty(F.prototype,B,{get:function(){console.warn("%s(...) is deprecated in plain JavaScript React classes. %s",G[0],G[1])}})}function P(B){if(B===null||typeof B!=="object")return null;return B=PB&&B[PB]||B["@@iterator"],typeof B==="function"?B:null}function w(B,G){B=(B=B.constructor)&&(B.displayName||B.name)||"ReactClass";var M=B+"."+G;wB[M]||(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.",G,B),wB[M]=!0)}function F(B,G,M){this.props=B,this.context=G,this.refs=OB,this.updater=M||DB}function C(){}function I(B,G,M){this.props=B,this.context=G,this.refs=OB,this.updater=M||DB}function A(){}function x(B){return""+B}function b(B){try{x(B);var G=!1}catch(W){G=!0}if(G){G=console;var M=G.error,R=typeof Symbol==="function"&&Symbol.toStringTag&&B[Symbol.toStringTag]||B.constructor.name||"Object";return M.call(G,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",R),x(B)}}function h(B){if(B==null)return null;if(typeof B==="function")return B.$$typeof===SB?null:B.displayName||B.name||null;if(typeof B==="string")return B;switch(B){case s:return"Fragment";case Y:return"Profiler";case H:return"StrictMode";case d:return"Suspense";case q:return"SuspenseList";case HB:return"Activity"}if(typeof B==="object")switch(typeof B.tag==="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),B.$$typeof){case GB:return"Portal";case D:return B.displayName||"Context";case O:return(B._context.displayName||"Context")+".Consumer";case T:var G=B.render;return B=B.displayName,B||(B=G.displayName||G.name||"",B=B!==""?"ForwardRef("+B+")":"ForwardRef"),B;case E:return G=B.displayName||null,G!==null?G:h(B.type)||"Memo";case N:G=B._payload,B=B._init;try{return h(B(G))}catch(M){}}return null}function e(B){if(B===s)return"<>";if(typeof B==="object"&&B!==null&&B.$$typeof===N)return"<...>";try{var G=h(B);return G?"<"+G+">":"<...>"}catch(M){return"<...>"}}function c(){var B=Z.A;return B===null?null:B.getOwner()}function i(){return Error("react-stack-top-frame")}function p(B){if(MB.call(B,"key")){var G=Object.getOwnPropertyDescriptor(B,"key").get;if(G&&G.isReactWarning)return!1}return B.key!==void 0}function YB(B,G){function M(){TB||(TB=!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))}M.isReactWarning=!0,Object.defineProperty(B,"key",{get:M,configurable:!0})}function o(){var B=h(this.type);return IB[B]||(IB[B]=!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.")),B=this.props.ref,B!==void 0?B:null}function l(B,G,M,R,W,z){var X=M.ref;return B={$$typeof:a,type:B,key:G,props:M,_owner:R},(X!==void 0?X:null)!==null?Object.defineProperty(B,"ref",{enumerable:!1,get:o}):Object.defineProperty(B,"ref",{enumerable:!1,value:null}),B._store={},Object.defineProperty(B._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(B,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(B,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:W}),Object.defineProperty(B,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:z}),Object.freeze&&(Object.freeze(B.props),Object.freeze(B)),B}function ZB(B,G){return G=l(B.type,G,B.props,B._owner,B._debugStack,B._debugTask),B._store&&(G._store.validated=B._store.validated),G}function BB(B){j(B)?B._store&&(B._store.validated=1):typeof B==="object"&&B!==null&&B.$$typeof===N&&(B._payload.status==="fulfilled"?j(B._payload.value)&&B._payload.value._store&&(B._payload.value._store.validated=1):B._store&&(B._store.validated=1))}function j(B){return typeof B==="object"&&B!==null&&B.$$typeof===a}function zB(B){var G={"=":"=0",":":"=2"};return"$"+B.replace(/[=:]/g,function(M){return G[M]})}function t(B,G){return typeof B==="object"&&B!==null&&B.key!=null?(b(B.key),zB(""+B.key)):G.toString(36)}function QB(B){switch(B.status){case"fulfilled":return B.value;case"rejected":throw B.reason;default:switch(typeof B.status==="string"?B.then(A,A):(B.status="pending",B.then(function(G){B.status==="pending"&&(B.status="fulfilled",B.value=G)},function(G){B.status==="pending"&&(B.status="rejected",B.reason=G)})),B.status){case"fulfilled":return B.value;case"rejected":throw B.reason}}throw B}function _(B,G,M,R,W){var z=typeof B;if(z==="undefined"||z==="boolean")B=null;var X=!1;if(B===null)X=!0;else switch(z){case"bigint":case"string":case"number":X=!0;break;case"object":switch(B.$$typeof){case a:case GB:X=!0;break;case N:return X=B._init,_(X(B._payload),G,M,R,W)}}if(X){X=B,W=W(X);var L=R===""?"."+t(X,0):R;return KB(W)?(M="",L!=null&&(M=L.replace(xB,"$&/")+"/"),_(W,G,M,"",function(v){return v})):W!=null&&(j(W)&&(W.key!=null&&(X&&X.key===W.key||b(W.key)),M=ZB(W,M+(W.key==null||X&&X.key===W.key?"":(""+W.key).replace(xB,"$&/")+"/")+L),R!==""&&X!=null&&j(X)&&X.key==null&&X._store&&!X._store.validated&&(M._store.validated=2),W=M),G.push(W)),1}if(X=0,L=R===""?".":R+":",KB(B))for(var Q=0;Q<B.length;Q++)R=B[Q],z=L+t(R,Q),X+=_(R,G,M,z,W);else if(Q=P(B),typeof Q==="function")for(Q===B.entries&&(NB||console.warn("Using Maps as children is not supported. Use an array of keyed ReactElements instead."),NB=!0),B=Q.call(B),Q=0;!(R=B.next()).done;)R=R.value,z=L+t(R,Q++),X+=_(R,G,M,z,W);else if(z==="object"){if(typeof B.then==="function")return _(QB(B),G,M,R,W);throw G=String(B),Error("Objects are not valid as a React child (found: "+(G==="[object Object]"?"object with keys {"+Object.keys(B).join(", ")+"}":G)+"). If you meant to render a collection of children, use an array instead.")}return X}function V(B,G,M){if(B==null)return B;var R=[],W=0;return _(B,R,"","",function(z){return G.call(M,z,W++)}),R}function LB(B){if(B._status===-1){var G=B._ioInfo;G!=null&&(G.start=G.end=performance.now()),G=B._result;var M=G();if(M.then(function(W){if(B._status===0||B._status===-1){B._status=1,B._result=W;var z=B._ioInfo;z!=null&&(z.end=performance.now()),M.status===void 0&&(M.status="fulfilled",M.value=W)}},function(W){if(B._status===0||B._status===-1){B._status=2,B._result=W;var z=B._ioInfo;z!=null&&(z.end=performance.now()),M.status===void 0&&(M.status="rejected",M.reason=W)}}),G=B._ioInfo,G!=null){G.value=M;var R=M.displayName;typeof R==="string"&&(G.name=R)}B._status===-1&&(B._status=0,B._result=M)}if(B._status===1)return G=B._result,G===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'))
|
|
@@ -10,12 +10,12 @@ Your code should look like:
|
|
|
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.`),B}function n(){Z.asyncTransitions--}function g(B){if(RB===null)try{var G=("require"+Math.random()).slice(0,7);RB=(XB&&XB[G]).call(XB,"timers").setImmediate}catch(M){RB=function(R){_B===!1&&(_B=!0,typeof MessageChannel>"u"&&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 U=new MessageChannel;U.port1.onmessage=R,U.port2.postMessage(void 0)}}return RB(B)}function S(B){return 1<B.length&&typeof AggregateError==="function"?AggregateError(B):B[0]}function k(B,G){G!==UB-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. "),UB=G}function m(B,G,M){var R=Z.actQueue;if(R!==null)if(R.length!==0)try{u(R),g(function(){return m(B,G,M)});return}catch(U){Z.thrownErrors.push(U)}else Z.actQueue=null;0<Z.thrownErrors.length?(R=S(Z.thrownErrors),Z.thrownErrors.length=0,M(R)):G(B)}function u(B){if(!$B){$B=!0;var G=0;try{for(;G<B.length;G++){var M=B[G];do{Z.didUsePromise=!1;var R=M(!1);if(R!==null){if(Z.didUsePromise){B[G]=M,B.splice(0,G);return}M=R}else break}while(1)}B.length=0}catch(U){B.splice(0,G+1),Z.thrownErrors.push(U)}finally{$B=!1}}}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart==="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var a=Symbol.for("react.transitional.element"),GB=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),H=Symbol.for("react.strict_mode"),Y=Symbol.for("react.profiler"),O=Symbol.for("react.consumer"),D=Symbol.for("react.context"),T=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),q=Symbol.for("react.suspense_list"),E=Symbol.for("react.memo"),N=Symbol.for("react.lazy"),HB=Symbol.for("react.activity"),PB=Symbol.iterator,wB={},DB={isMounted:function(){return!1},enqueueForceUpdate:function(B){w(B,"forceUpdate")},enqueueReplaceState:function(B){w(B,"replaceState")},enqueueSetState:function(B){w(B,"setState")}},FB=Object.assign,OB={};Object.freeze(OB),F.prototype.isReactComponent={},F.prototype.setState=function(B,G){if(typeof B!=="object"&&typeof B!=="function"&&B!=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,B,G,"setState")},F.prototype.forceUpdate=function(B){this.updater.enqueueForceUpdate(this,B,"forceUpdate")};var K={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)."]};for(r in K)K.hasOwnProperty(r)&&W(r,K[r]);C.prototype=F.prototype,K=I.prototype=new C,K.constructor=I,FB(K,F.prototype),K.isPureReactComponent=!0;var KB=Array.isArray,SB=Symbol.for("react.client.reference"),Z={H:null,A:null,T:null,S:null,actQueue:null,asyncTransitions:0,isBatchingLegacy:!1,didScheduleLegacyUpdate:!1,didUsePromise:!1,thrownErrors:[],getCurrentStack:null,recentlyCreatedOwnerStacks:0},MB=Object.prototype.hasOwnProperty,AB=console.createTask?console.createTask:function(){return null};K={react_stack_bottom_frame:function(B){return B()}};var TB,EB,IB={},kB=K.react_stack_bottom_frame.bind(K,i)(),fB=AB(e(i)),NB=!1,xB=/\/+/g,jB=typeof reportError==="function"?reportError:function(B){if(typeof window==="object"&&typeof window.ErrorEvent==="function"){var G=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof B==="object"&&B!==null&&typeof B.message==="string"?String(B.message):String(B),error:B});if(!window.dispatchEvent(G))return}else if(typeof process==="object"&&typeof process.emit==="function"){process.emit("uncaughtException",B);return}console.error(B)},_B=!1,RB=null,UB=0,WB=!1,$B=!1,VB=typeof queueMicrotask==="function"?function(B){queueMicrotask(function(){return queueMicrotask(B)})}:g;K=Object.freeze({__proto__:null,c:function(B){return $().useMemoCache(B)}});var r={map:V,forEach:function(B,G,M){V(B,function(){G.apply(this,arguments)},M)},count:function(B){var G=0;return V(B,function(){G++}),G},toArray:function(B){return V(B,function(G){return G})||[]},only:function(B){if(!j(B))throw Error("React.Children.only expected to receive a single React element child.");return B}};pB.Activity=HB,pB.Children=r,pB.Component=F,pB.Fragment=s,pB.Profiler=Y,pB.PureComponent=I,pB.StrictMode=H,pB.Suspense=d,pB.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=Z,pB.__COMPILER_RUNTIME=K,pB.act=function(B){var G=Z.actQueue,M=UB;UB++;var R=Z.actQueue=G!==null?G:[],U=!1;try{var z=B()}catch(Q){Z.thrownErrors.push(Q)}if(0<Z.thrownErrors.length)throw k(G,M),B=S(Z.thrownErrors),Z.thrownErrors.length=0,B;if(z!==null&&typeof z==="object"&&typeof z.then==="function"){var X=z;return VB(function(){U||WB||(WB=!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(Q,v){U=!0,X.then(function(y){if(k(G,M),M===0){try{u(R),g(function(){return m(y,Q,v)})}catch(hB){Z.thrownErrors.push(hB)}if(0<Z.thrownErrors.length){var bB=S(Z.thrownErrors);Z.thrownErrors.length=0,v(bB)}}else Q(y)},function(y){k(G,M),0<Z.thrownErrors.length?(y=S(Z.thrownErrors),Z.thrownErrors.length=0,v(y)):v(y)})}}}var L=z;if(k(G,M),M===0&&(u(R),R.length!==0&&VB(function(){U||WB||(WB=!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(() => ...)"))}),Z.actQueue=null),0<Z.thrownErrors.length)throw B=S(Z.thrownErrors),Z.thrownErrors.length=0,B;return{then:function(Q,v){U=!0,M===0?(Z.actQueue=R,g(function(){return m(L,Q,v)})):Q(L)}}},pB.cache=function(B){return function(){return B.apply(null,arguments)}},pB.cacheSignal=function(){return null},pB.captureOwnerStack=function(){var B=Z.getCurrentStack;return B===null?null:B()},pB.cloneElement=function(B,G,M){if(B===null||B===void 0)throw Error("The argument must be a React element, but you passed "+B+".");var R=FB({},B.props),U=B.key,z=B._owner;if(G!=null){var X;B:{if(MB.call(G,"ref")&&(X=Object.getOwnPropertyDescriptor(G,"ref").get)&&X.isReactWarning){X=!1;break B}X=G.ref!==void 0}X&&(z=c()),p(G)&&(b(G.key),U=""+G.key);for(L in G)!MB.call(G,L)||L==="key"||L==="__self"||L==="__source"||L==="ref"&&G.ref===void 0||(R[L]=G[L])}var L=arguments.length-2;if(L===1)R.children=M;else if(1<L){X=Array(L);for(var Q=0;Q<L;Q++)X[Q]=arguments[Q+2];R.children=X}R=l(B.type,U,R,z,B._debugStack,B._debugTask);for(U=2;U<arguments.length;U++)BB(arguments[U]);return R},pB.createContext=function(B){return B={$$typeof:D,_currentValue:B,_currentValue2:B,_threadCount:0,Provider:null,Consumer:null},B.Provider=B,B.Consumer={$$typeof:O,_context:B},B._currentRenderer=null,B._currentRenderer2=null,B},pB.createElement=function(B,G,M){for(var R=2;R<arguments.length;R++)BB(arguments[R]);R={};var U=null;if(G!=null)for(Q in EB||!("__self"in G)||"key"in G||(EB=!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")),p(G)&&(b(G.key),U=""+G.key),G)MB.call(G,Q)&&Q!=="key"&&Q!=="__self"&&Q!=="__source"&&(R[Q]=G[Q]);var z=arguments.length-2;if(z===1)R.children=M;else if(1<z){for(var X=Array(z),L=0;L<z;L++)X[L]=arguments[L+2];Object.freeze&&Object.freeze(X),R.children=X}if(B&&B.defaultProps)for(Q in z=B.defaultProps,z)R[Q]===void 0&&(R[Q]=z[Q]);U&&YB(R,typeof B==="function"?B.displayName||B.name||"Unknown":B);var Q=1e4>Z.recentlyCreatedOwnerStacks++;return l(B,U,R,c(),Q?Error("react-stack-top-frame"):kB,Q?AB(e(B)):fB)},pB.createRef=function(){var B={current:null};return Object.seal(B),B},pB.forwardRef=function(B){B!=null&&B.$$typeof===E?console.error("forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...))."):typeof B!=="function"?console.error("forwardRef requires a render function but was given %s.",B===null?"null":typeof B):B.length!==0&&B.length!==2&&console.error("forwardRef render functions accept exactly two parameters: props and ref. %s",B.length===1?"Did you forget to use the ref parameter?":"Any additional parameter will be undefined."),B!=null&&B.defaultProps!=null&&console.error("forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?");var G={$$typeof:T,render:B},M;return Object.defineProperty(G,"displayName",{enumerable:!1,configurable:!0,get:function(){return M},set:function(R){M=R,B.name||B.displayName||(Object.defineProperty(B,"name",{value:R}),B.displayName=R)}}),G},pB.isValidElement=j,pB.lazy=function(B){B={_status:-1,_result:B};var G={$$typeof:N,_payload:B,_init:LB},M={name:"lazy",start:-1,end:-1,value:null,owner:null,debugStack:Error("react-stack-top-frame"),debugTask:console.createTask?console.createTask("lazy()"):null};return B._ioInfo=M,G._debugInfo=[{awaited:M}],G},pB.memo=function(B,G){B==null&&console.error("memo: The first argument must be a component. Instead received: %s",B===null?"null":typeof B),G={$$typeof:E,type:B,compare:G===void 0?null:G};var M;return Object.defineProperty(G,"displayName",{enumerable:!1,configurable:!0,get:function(){return M},set:function(R){M=R,B.name||B.displayName||(Object.defineProperty(B,"name",{value:R}),B.displayName=R)}}),G},pB.startTransition=function(B){var G=Z.T,M={};M._updatedFibers=new Set,Z.T=M;try{var R=B(),U=Z.S;U!==null&&U(M,R),typeof R==="object"&&R!==null&&typeof R.then==="function"&&(Z.asyncTransitions++,R.then(n,n),R.then(A,jB))}catch(z){jB(z)}finally{G===null&&M._updatedFibers&&(B=M._updatedFibers.size,M._updatedFibers.clear(),10<B&&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.")),G!==null&&M.types!==null&&(G.types!==null&&G.types!==M.types&&console.error("We expected inner Transitions to have transferred the outer types set and that you cannot add to the outer Transition while inside the inner.This is a bug in React."),G.types=M.types),Z.T=G}},pB.unstable_useCacheRefresh=function(){return $().useCacheRefresh()},pB.use=function(B){return $().use(B)},pB.useActionState=function(B,G,M){return $().useActionState(B,G,M)},pB.useCallback=function(B,G){return $().useCallback(B,G)},pB.useContext=function(B){var G=$();return B.$$typeof===O&&console.error("Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?"),G.useContext(B)},pB.useDebugValue=function(B,G){return $().useDebugValue(B,G)},pB.useDeferredValue=function(B,G){return $().useDeferredValue(B,G)},pB.useEffect=function(B,G){return B==null&&console.warn("React Hook useEffect requires an effect callback. Did you forget to pass a callback to the hook?"),$().useEffect(B,G)},pB.useEffectEvent=function(B){return $().useEffectEvent(B)},pB.useId=function(){return $().useId()},pB.useImperativeHandle=function(B,G,M){return $().useImperativeHandle(B,G,M)},pB.useInsertionEffect=function(B,G){return B==null&&console.warn("React Hook useInsertionEffect requires an effect callback. Did you forget to pass a callback to the hook?"),$().useInsertionEffect(B,G)},pB.useLayoutEffect=function(B,G){return B==null&&console.warn("React Hook useLayoutEffect requires an effect callback. Did you forget to pass a callback to the hook?"),$().useLayoutEffect(B,G)},pB.useMemo=function(B,G){return $().useMemo(B,G)},pB.useOptimistic=function(B,G){return $().useOptimistic(B,G)},pB.useReducer=function(B,G,M){return $().useReducer(B,G,M)},pB.useRef=function(B){return $().useRef(B)},pB.useState=function(B){return $().useState(B)},pB.useSyncExternalStore=function(B,G,M){return $().useSyncExternalStore(B,G,M)},pB.useTransition=function(){return $().useTransition()},pB.version="19.2.7",typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop==="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()});var qB=CB((oB)=>{var f=JB(gB());(function(){function W(H){if(H==null)return null;if(typeof H==="function")return H.$$typeof===$?null:H.displayName||H.name||null;if(typeof H==="string")return H;switch(H){case o:return"Fragment";case ZB:return"Profiler";case l:return"StrictMode";case t:return"Suspense";case QB:return"SuspenseList";case LB:return"Activity"}if(typeof H==="object")switch(typeof H.tag==="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),H.$$typeof){case YB:return"Portal";case j:return H.displayName||"Context";case BB:return(H._context.displayName||"Context")+".Consumer";case zB:var Y=H.render;return H=H.displayName,H||(H=Y.displayName||Y.name||"",H=H!==""?"ForwardRef("+H+")":"ForwardRef"),H;case _:return Y=H.displayName||null,Y!==null?Y:W(H.type)||"Memo";case V:Y=H._payload,H=H._init;try{return W(H(Y))}catch(O){}}return null}function P(H){return""+H}function w(H){try{P(H);var Y=!1}catch(T){Y=!0}if(Y){Y=console;var O=Y.error,D=typeof Symbol==="function"&&Symbol.toStringTag&&H[Symbol.toStringTag]||H.constructor.name||"Object";return O.call(Y,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",D),P(H)}}function F(H){if(H===o)return"<>";if(typeof H==="object"&&H!==null&&H.$$typeof===V)return"<...>";try{var Y=W(H);return Y?"<"+Y+">":"<...>"}catch(O){return"<...>"}}function C(){var H=n.A;return H===null?null:H.getOwner()}function I(){return Error("react-stack-top-frame")}function A(H){if(g.call(H,"key")){var Y=Object.getOwnPropertyDescriptor(H,"key").get;if(Y&&Y.isReactWarning)return!1}return H.key!==void 0}function x(H,Y){function O(){m||(m=!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)",Y))}O.isReactWarning=!0,Object.defineProperty(H,"key",{get:O,configurable:!0})}function b(){var H=W(this.type);return u[H]||(u[H]=!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.")),H=this.props.ref,H!==void 0?H:null}function h(H,Y,O,D,T,d){var q=O.ref;return H={$$typeof:p,type:H,key:Y,props:O,_owner:D},(q!==void 0?q:null)!==null?Object.defineProperty(H,"ref",{enumerable:!1,get:b}):Object.defineProperty(H,"ref",{enumerable:!1,value:null}),H._store={},Object.defineProperty(H._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(H,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(H,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:T}),Object.defineProperty(H,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:d}),Object.freeze&&(Object.freeze(H.props),Object.freeze(H)),H}function e(H,Y,O,D,T,d){var q=Y.children;if(q!==void 0)if(D)if(S(q)){for(D=0;D<q.length;D++)c(q[D]);Object.freeze&&Object.freeze(q)}else console.error("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 c(q);if(g.call(Y,"key")){q=W(H);var E=Object.keys(Y).filter(function(HB){return HB!=="key"});D=0<E.length?"{key: someKey, "+E.join(": ..., ")+": ...}":"{key: someKey}",s[q+D]||(E=0<E.length?"{"+E.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
|
|
13
|
+
See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`),B}function n(){Z.asyncTransitions--}function g(B){if(RB===null)try{var G=("require"+Math.random()).slice(0,7);RB=(XB&&XB[G]).call(XB,"timers").setImmediate}catch(M){RB=function(R){_B===!1&&(_B=!0,typeof MessageChannel>"u"&&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 W=new MessageChannel;W.port1.onmessage=R,W.port2.postMessage(void 0)}}return RB(B)}function S(B){return 1<B.length&&typeof AggregateError==="function"?AggregateError(B):B[0]}function k(B,G){G!==UB-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. "),UB=G}function m(B,G,M){var R=Z.actQueue;if(R!==null)if(R.length!==0)try{u(R),g(function(){return m(B,G,M)});return}catch(W){Z.thrownErrors.push(W)}else Z.actQueue=null;0<Z.thrownErrors.length?(R=S(Z.thrownErrors),Z.thrownErrors.length=0,M(R)):G(B)}function u(B){if(!$B){$B=!0;var G=0;try{for(;G<B.length;G++){var M=B[G];do{Z.didUsePromise=!1;var R=M(!1);if(R!==null){if(Z.didUsePromise){B[G]=M,B.splice(0,G);return}M=R}else break}while(1)}B.length=0}catch(W){B.splice(0,G+1),Z.thrownErrors.push(W)}finally{$B=!1}}}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart==="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var a=Symbol.for("react.transitional.element"),GB=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),H=Symbol.for("react.strict_mode"),Y=Symbol.for("react.profiler"),O=Symbol.for("react.consumer"),D=Symbol.for("react.context"),T=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),q=Symbol.for("react.suspense_list"),E=Symbol.for("react.memo"),N=Symbol.for("react.lazy"),HB=Symbol.for("react.activity"),PB=Symbol.iterator,wB={},DB={isMounted:function(){return!1},enqueueForceUpdate:function(B){w(B,"forceUpdate")},enqueueReplaceState:function(B){w(B,"replaceState")},enqueueSetState:function(B){w(B,"setState")}},FB=Object.assign,OB={};Object.freeze(OB),F.prototype.isReactComponent={},F.prototype.setState=function(B,G){if(typeof B!=="object"&&typeof B!=="function"&&B!=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,B,G,"setState")},F.prototype.forceUpdate=function(B){this.updater.enqueueForceUpdate(this,B,"forceUpdate")};var K={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)."]};for(r in K)K.hasOwnProperty(r)&&U(r,K[r]);C.prototype=F.prototype,K=I.prototype=new C,K.constructor=I,FB(K,F.prototype),K.isPureReactComponent=!0;var KB=Array.isArray,SB=Symbol.for("react.client.reference"),Z={H:null,A:null,T:null,S:null,actQueue:null,asyncTransitions:0,isBatchingLegacy:!1,didScheduleLegacyUpdate:!1,didUsePromise:!1,thrownErrors:[],getCurrentStack:null,recentlyCreatedOwnerStacks:0},MB=Object.prototype.hasOwnProperty,AB=console.createTask?console.createTask:function(){return null};K={react_stack_bottom_frame:function(B){return B()}};var TB,EB,IB={},kB=K.react_stack_bottom_frame.bind(K,i)(),fB=AB(e(i)),NB=!1,xB=/\/+/g,jB=typeof reportError==="function"?reportError:function(B){if(typeof window==="object"&&typeof window.ErrorEvent==="function"){var G=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof B==="object"&&B!==null&&typeof B.message==="string"?String(B.message):String(B),error:B});if(!window.dispatchEvent(G))return}else if(typeof process==="object"&&typeof process.emit==="function"){process.emit("uncaughtException",B);return}console.error(B)},_B=!1,RB=null,UB=0,WB=!1,$B=!1,VB=typeof queueMicrotask==="function"?function(B){queueMicrotask(function(){return queueMicrotask(B)})}:g;K=Object.freeze({__proto__:null,c:function(B){return $().useMemoCache(B)}});var r={map:V,forEach:function(B,G,M){V(B,function(){G.apply(this,arguments)},M)},count:function(B){var G=0;return V(B,function(){G++}),G},toArray:function(B){return V(B,function(G){return G})||[]},only:function(B){if(!j(B))throw Error("React.Children.only expected to receive a single React element child.");return B}};pB.Activity=HB,pB.Children=r,pB.Component=F,pB.Fragment=s,pB.Profiler=Y,pB.PureComponent=I,pB.StrictMode=H,pB.Suspense=d,pB.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=Z,pB.__COMPILER_RUNTIME=K,pB.act=function(B){var G=Z.actQueue,M=UB;UB++;var R=Z.actQueue=G!==null?G:[],W=!1;try{var z=B()}catch(Q){Z.thrownErrors.push(Q)}if(0<Z.thrownErrors.length)throw k(G,M),B=S(Z.thrownErrors),Z.thrownErrors.length=0,B;if(z!==null&&typeof z==="object"&&typeof z.then==="function"){var X=z;return VB(function(){W||WB||(WB=!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(Q,v){W=!0,X.then(function(y){if(k(G,M),M===0){try{u(R),g(function(){return m(y,Q,v)})}catch(hB){Z.thrownErrors.push(hB)}if(0<Z.thrownErrors.length){var bB=S(Z.thrownErrors);Z.thrownErrors.length=0,v(bB)}}else Q(y)},function(y){k(G,M),0<Z.thrownErrors.length?(y=S(Z.thrownErrors),Z.thrownErrors.length=0,v(y)):v(y)})}}}var L=z;if(k(G,M),M===0&&(u(R),R.length!==0&&VB(function(){W||WB||(WB=!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(() => ...)"))}),Z.actQueue=null),0<Z.thrownErrors.length)throw B=S(Z.thrownErrors),Z.thrownErrors.length=0,B;return{then:function(Q,v){W=!0,M===0?(Z.actQueue=R,g(function(){return m(L,Q,v)})):Q(L)}}},pB.cache=function(B){return function(){return B.apply(null,arguments)}},pB.cacheSignal=function(){return null},pB.captureOwnerStack=function(){var B=Z.getCurrentStack;return B===null?null:B()},pB.cloneElement=function(B,G,M){if(B===null||B===void 0)throw Error("The argument must be a React element, but you passed "+B+".");var R=FB({},B.props),W=B.key,z=B._owner;if(G!=null){var X;B:{if(MB.call(G,"ref")&&(X=Object.getOwnPropertyDescriptor(G,"ref").get)&&X.isReactWarning){X=!1;break B}X=G.ref!==void 0}X&&(z=c()),p(G)&&(b(G.key),W=""+G.key);for(L in G)!MB.call(G,L)||L==="key"||L==="__self"||L==="__source"||L==="ref"&&G.ref===void 0||(R[L]=G[L])}var L=arguments.length-2;if(L===1)R.children=M;else if(1<L){X=Array(L);for(var Q=0;Q<L;Q++)X[Q]=arguments[Q+2];R.children=X}R=l(B.type,W,R,z,B._debugStack,B._debugTask);for(W=2;W<arguments.length;W++)BB(arguments[W]);return R},pB.createContext=function(B){return B={$$typeof:D,_currentValue:B,_currentValue2:B,_threadCount:0,Provider:null,Consumer:null},B.Provider=B,B.Consumer={$$typeof:O,_context:B},B._currentRenderer=null,B._currentRenderer2=null,B},pB.createElement=function(B,G,M){for(var R=2;R<arguments.length;R++)BB(arguments[R]);R={};var W=null;if(G!=null)for(Q in EB||!("__self"in G)||"key"in G||(EB=!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")),p(G)&&(b(G.key),W=""+G.key),G)MB.call(G,Q)&&Q!=="key"&&Q!=="__self"&&Q!=="__source"&&(R[Q]=G[Q]);var z=arguments.length-2;if(z===1)R.children=M;else if(1<z){for(var X=Array(z),L=0;L<z;L++)X[L]=arguments[L+2];Object.freeze&&Object.freeze(X),R.children=X}if(B&&B.defaultProps)for(Q in z=B.defaultProps,z)R[Q]===void 0&&(R[Q]=z[Q]);W&&YB(R,typeof B==="function"?B.displayName||B.name||"Unknown":B);var Q=1e4>Z.recentlyCreatedOwnerStacks++;return l(B,W,R,c(),Q?Error("react-stack-top-frame"):kB,Q?AB(e(B)):fB)},pB.createRef=function(){var B={current:null};return Object.seal(B),B},pB.forwardRef=function(B){B!=null&&B.$$typeof===E?console.error("forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...))."):typeof B!=="function"?console.error("forwardRef requires a render function but was given %s.",B===null?"null":typeof B):B.length!==0&&B.length!==2&&console.error("forwardRef render functions accept exactly two parameters: props and ref. %s",B.length===1?"Did you forget to use the ref parameter?":"Any additional parameter will be undefined."),B!=null&&B.defaultProps!=null&&console.error("forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?");var G={$$typeof:T,render:B},M;return Object.defineProperty(G,"displayName",{enumerable:!1,configurable:!0,get:function(){return M},set:function(R){M=R,B.name||B.displayName||(Object.defineProperty(B,"name",{value:R}),B.displayName=R)}}),G},pB.isValidElement=j,pB.lazy=function(B){B={_status:-1,_result:B};var G={$$typeof:N,_payload:B,_init:LB},M={name:"lazy",start:-1,end:-1,value:null,owner:null,debugStack:Error("react-stack-top-frame"),debugTask:console.createTask?console.createTask("lazy()"):null};return B._ioInfo=M,G._debugInfo=[{awaited:M}],G},pB.memo=function(B,G){B==null&&console.error("memo: The first argument must be a component. Instead received: %s",B===null?"null":typeof B),G={$$typeof:E,type:B,compare:G===void 0?null:G};var M;return Object.defineProperty(G,"displayName",{enumerable:!1,configurable:!0,get:function(){return M},set:function(R){M=R,B.name||B.displayName||(Object.defineProperty(B,"name",{value:R}),B.displayName=R)}}),G},pB.startTransition=function(B){var G=Z.T,M={};M._updatedFibers=new Set,Z.T=M;try{var R=B(),W=Z.S;W!==null&&W(M,R),typeof R==="object"&&R!==null&&typeof R.then==="function"&&(Z.asyncTransitions++,R.then(n,n),R.then(A,jB))}catch(z){jB(z)}finally{G===null&&M._updatedFibers&&(B=M._updatedFibers.size,M._updatedFibers.clear(),10<B&&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.")),G!==null&&M.types!==null&&(G.types!==null&&G.types!==M.types&&console.error("We expected inner Transitions to have transferred the outer types set and that you cannot add to the outer Transition while inside the inner.This is a bug in React."),G.types=M.types),Z.T=G}},pB.unstable_useCacheRefresh=function(){return $().useCacheRefresh()},pB.use=function(B){return $().use(B)},pB.useActionState=function(B,G,M){return $().useActionState(B,G,M)},pB.useCallback=function(B,G){return $().useCallback(B,G)},pB.useContext=function(B){var G=$();return B.$$typeof===O&&console.error("Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?"),G.useContext(B)},pB.useDebugValue=function(B,G){return $().useDebugValue(B,G)},pB.useDeferredValue=function(B,G){return $().useDeferredValue(B,G)},pB.useEffect=function(B,G){return B==null&&console.warn("React Hook useEffect requires an effect callback. Did you forget to pass a callback to the hook?"),$().useEffect(B,G)},pB.useEffectEvent=function(B){return $().useEffectEvent(B)},pB.useId=function(){return $().useId()},pB.useImperativeHandle=function(B,G,M){return $().useImperativeHandle(B,G,M)},pB.useInsertionEffect=function(B,G){return B==null&&console.warn("React Hook useInsertionEffect requires an effect callback. Did you forget to pass a callback to the hook?"),$().useInsertionEffect(B,G)},pB.useLayoutEffect=function(B,G){return B==null&&console.warn("React Hook useLayoutEffect requires an effect callback. Did you forget to pass a callback to the hook?"),$().useLayoutEffect(B,G)},pB.useMemo=function(B,G){return $().useMemo(B,G)},pB.useOptimistic=function(B,G){return $().useOptimistic(B,G)},pB.useReducer=function(B,G,M){return $().useReducer(B,G,M)},pB.useRef=function(B){return $().useRef(B)},pB.useState=function(B){return $().useState(B)},pB.useSyncExternalStore=function(B,G,M){return $().useSyncExternalStore(B,G,M)},pB.useTransition=function(){return $().useTransition()},pB.version="19.2.7",typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop==="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()});var qB=CB((oB)=>{var f=JB(gB());(function(){function U(H){if(H==null)return null;if(typeof H==="function")return H.$$typeof===$?null:H.displayName||H.name||null;if(typeof H==="string")return H;switch(H){case o:return"Fragment";case ZB:return"Profiler";case l:return"StrictMode";case t:return"Suspense";case QB:return"SuspenseList";case LB:return"Activity"}if(typeof H==="object")switch(typeof H.tag==="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),H.$$typeof){case YB:return"Portal";case j:return H.displayName||"Context";case BB:return(H._context.displayName||"Context")+".Consumer";case zB:var Y=H.render;return H=H.displayName,H||(H=Y.displayName||Y.name||"",H=H!==""?"ForwardRef("+H+")":"ForwardRef"),H;case _:return Y=H.displayName||null,Y!==null?Y:U(H.type)||"Memo";case V:Y=H._payload,H=H._init;try{return U(H(Y))}catch(O){}}return null}function P(H){return""+H}function w(H){try{P(H);var Y=!1}catch(T){Y=!0}if(Y){Y=console;var O=Y.error,D=typeof Symbol==="function"&&Symbol.toStringTag&&H[Symbol.toStringTag]||H.constructor.name||"Object";return O.call(Y,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",D),P(H)}}function F(H){if(H===o)return"<>";if(typeof H==="object"&&H!==null&&H.$$typeof===V)return"<...>";try{var Y=U(H);return Y?"<"+Y+">":"<...>"}catch(O){return"<...>"}}function C(){var H=n.A;return H===null?null:H.getOwner()}function I(){return Error("react-stack-top-frame")}function A(H){if(g.call(H,"key")){var Y=Object.getOwnPropertyDescriptor(H,"key").get;if(Y&&Y.isReactWarning)return!1}return H.key!==void 0}function x(H,Y){function O(){m||(m=!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)",Y))}O.isReactWarning=!0,Object.defineProperty(H,"key",{get:O,configurable:!0})}function b(){var H=U(this.type);return u[H]||(u[H]=!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.")),H=this.props.ref,H!==void 0?H:null}function h(H,Y,O,D,T,d){var q=O.ref;return H={$$typeof:p,type:H,key:Y,props:O,_owner:D},(q!==void 0?q:null)!==null?Object.defineProperty(H,"ref",{enumerable:!1,get:b}):Object.defineProperty(H,"ref",{enumerable:!1,value:null}),H._store={},Object.defineProperty(H._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(H,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(H,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:T}),Object.defineProperty(H,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:d}),Object.freeze&&(Object.freeze(H.props),Object.freeze(H)),H}function e(H,Y,O,D,T,d){var q=Y.children;if(q!==void 0)if(D)if(S(q)){for(D=0;D<q.length;D++)c(q[D]);Object.freeze&&Object.freeze(q)}else console.error("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 c(q);if(g.call(Y,"key")){q=U(H);var E=Object.keys(Y).filter(function(HB){return HB!=="key"});D=0<E.length?"{key: someKey, "+E.join(": ..., ")+": ...}":"{key: someKey}",s[q+D]||(E=0<E.length?"{"+E.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
|
|
14
14
|
let props = %s;
|
|
15
15
|
<%s {...props} />
|
|
16
16
|
React keys must be passed directly to JSX without using spread:
|
|
17
17
|
let props = %s;
|
|
18
|
-
<%s key={someKey} {...props} />`,D,q,E,q),s[q+D]=!0)}if(q=null,O!==void 0&&(w(O),q=""+O),A(Y)&&(w(Y.key),q=""+Y.key),"key"in Y){O={};for(var N in Y)N!=="key"&&(O[N]=Y[N])}else O=Y;return q&&x(O,typeof H==="function"?H.displayName||H.name||"Unknown":H),h(H,q,O,C(),T,d)}function c(H){i(H)?H._store&&(H._store.validated=1):typeof H==="object"&&H!==null&&H.$$typeof===V&&(H._payload.status==="fulfilled"?i(H._payload.value)&&H._payload.value._store&&(H._payload.value._store.validated=1):H._store&&(H._store.validated=1))}function i(H){return typeof H==="object"&&H!==null&&H.$$typeof===p}var p=Symbol.for("react.transitional.element"),YB=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),l=Symbol.for("react.strict_mode"),ZB=Symbol.for("react.profiler"),BB=Symbol.for("react.consumer"),j=Symbol.for("react.context"),zB=Symbol.for("react.forward_ref"),t=Symbol.for("react.suspense"),QB=Symbol.for("react.suspense_list"),_=Symbol.for("react.memo"),V=Symbol.for("react.lazy"),LB=Symbol.for("react.activity"),$=Symbol.for("react.client.reference"),n=f.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,g=Object.prototype.hasOwnProperty,S=Array.isArray,k=console.createTask?console.createTask:function(){return null};f={react_stack_bottom_frame:function(H){return H()}};var m,u={},a=f.react_stack_bottom_frame.bind(f,I)(),GB=k(F(I)),s={};oB.Fragment=o,oB.jsxDEV=function(H,Y,O,D){var T=1e4>n.recentlyCreatedOwnerStacks++;return e(H,Y,O,D,T?Error("react-stack-top-frame"):a,T?k(F(H)):GB)}})()});var J=JB(qB(),1);function yG(
|
|
18
|
+
<%s key={someKey} {...props} />`,D,q,E,q),s[q+D]=!0)}if(q=null,O!==void 0&&(w(O),q=""+O),A(Y)&&(w(Y.key),q=""+Y.key),"key"in Y){O={};for(var N in Y)N!=="key"&&(O[N]=Y[N])}else O=Y;return q&&x(O,typeof H==="function"?H.displayName||H.name||"Unknown":H),h(H,q,O,C(),T,d)}function c(H){i(H)?H._store&&(H._store.validated=1):typeof H==="object"&&H!==null&&H.$$typeof===V&&(H._payload.status==="fulfilled"?i(H._payload.value)&&H._payload.value._store&&(H._payload.value._store.validated=1):H._store&&(H._store.validated=1))}function i(H){return typeof H==="object"&&H!==null&&H.$$typeof===p}var p=Symbol.for("react.transitional.element"),YB=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),l=Symbol.for("react.strict_mode"),ZB=Symbol.for("react.profiler"),BB=Symbol.for("react.consumer"),j=Symbol.for("react.context"),zB=Symbol.for("react.forward_ref"),t=Symbol.for("react.suspense"),QB=Symbol.for("react.suspense_list"),_=Symbol.for("react.memo"),V=Symbol.for("react.lazy"),LB=Symbol.for("react.activity"),$=Symbol.for("react.client.reference"),n=f.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,g=Object.prototype.hasOwnProperty,S=Array.isArray,k=console.createTask?console.createTask:function(){return null};f={react_stack_bottom_frame:function(H){return H()}};var m,u={},a=f.react_stack_bottom_frame.bind(f,I)(),GB=k(F(I)),s={};oB.Fragment=o,oB.jsxDEV=function(H,Y,O,D){var T=1e4>n.recentlyCreatedOwnerStacks++;return e(H,Y,O,D,T?Error("react-stack-top-frame"):a,T?k(F(H)):GB)}})()});var J=JB(qB(),1);function yG(U){return J.jsxDEV("main",{className:"sign-in",children:[J.jsxDEV("div",{className:"sign-in-mark","aria-hidden":"true"},void 0,!1,void 0,this),J.jsxDEV("h1",{className:"sign-in-heading",children:U.heading},void 0,!1,void 0,this),U.error?J.jsxDEV("div",{className:"sign-in-error",role:"alert",children:U.error},void 0,!1,void 0,this):null,J.jsxDEV("form",{method:"post",action:U.action,className:"sign-in-box",children:[Object.entries(U.fields).map(([P,w])=>J.jsxDEV("input",{type:"hidden",name:P,value:w},P,!1,void 0,this)),J.jsxDEV("label",{htmlFor:U.account.id??U.account.name,children:U.account.label},void 0,!1,void 0,this),J.jsxDEV("input",{id:U.account.id??U.account.name,name:U.account.name,type:"text",autoComplete:"username",defaultValue:U.account.value??""},void 0,!1,void 0,this),J.jsxDEV("label",{htmlFor:U.password.id??U.password.name,children:U.password.label},void 0,!1,void 0,this),J.jsxDEV("input",{id:U.password.id??U.password.name,name:U.password.name,type:"password",autoComplete:U.password.autoComplete??"current-password"},void 0,!1,void 0,this),J.jsxDEV("button",{type:"submit",className:"sign-in-submit",children:U.submit},void 0,!1,void 0,this)]},void 0,!0,void 0,this)]},void 0,!0,void 0,this)}function cG(U){return J.jsxDEV("main",{className:"sign-in",children:[J.jsxDEV("div",{className:"sign-in-mark","aria-hidden":"true"},void 0,!1,void 0,this),J.jsxDEV("h1",{className:"sign-in-heading",children:U.heading},void 0,!1,void 0,this),U.error?J.jsxDEV("div",{className:"sign-in-error",role:"alert",children:U.error},void 0,!1,void 0,this):null,J.jsxDEV("form",{method:"post",action:U.action,className:"sign-in-box",children:[Object.entries(U.fields).map(([P,w])=>J.jsxDEV("input",{type:"hidden",name:P,value:w},P,!1,void 0,this)),J.jsxDEV("label",{htmlFor:U.code.name,children:U.code.label},void 0,!1,void 0,this),J.jsxDEV("input",{id:U.code.name,name:U.code.name,type:"text",inputMode:"numeric",autoComplete:"one-time-code"},void 0,!1,void 0,this),J.jsxDEV("p",{className:"sign-in-hint",children:U.hint},void 0,!1,void 0,this),J.jsxDEV("button",{type:"submit",className:"sign-in-submit",children:U.submit},void 0,!1,void 0,this)]},void 0,!0,void 0,this)]},void 0,!0,void 0,this)}var iG=`
|
|
19
19
|
body { margin: 0; font: 14px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif; }
|
|
20
20
|
.sign-in { max-width: 340px; margin: 0 auto; padding: 32px 16px; }
|
|
21
21
|
.sign-in-mark { width: 48px; height: 48px; border-radius: 50%; margin: 0 auto 16px; }
|
|
@@ -25,4 +25,4 @@ body { margin: 0; font: 14px/1.5 system-ui, -apple-system, "Segoe UI", sans-seri
|
|
|
25
25
|
.sign-in-box input[type=text], .sign-in-box input[type=password] { font: inherit; padding: 5px 12px; border: 1px solid; border-radius: 6px; margin-bottom: 8px; }
|
|
26
26
|
.sign-in-hint { margin: 0 0 8px; font-size: 12px; }
|
|
27
27
|
.sign-in-submit { font: inherit; font-weight: 500; padding: 6px 16px; border-radius: 6px; border: 1px solid; cursor: pointer; }
|
|
28
|
-
`;function pG(
|
|
28
|
+
`;function pG(U,P){for(let w of(U.headers.get("cookie")??"").split(";")){let F=w.indexOf("=");if(F>0&&w.slice(0,F).trim()===P)return decodeURIComponent(w.slice(F+1).trim())}return}export{pG as cookieOf,cG as SignInCode,yG as SignIn,iG as SIGN_IN_CSS};
|
package/dist/client/sign-in.d.ts
CHANGED
|
@@ -9,10 +9,13 @@ export type SignInProps = {
|
|
|
9
9
|
name: string;
|
|
10
10
|
label: string;
|
|
11
11
|
value?: string;
|
|
12
|
+
id?: string;
|
|
12
13
|
};
|
|
13
14
|
password: {
|
|
14
15
|
name: string;
|
|
15
16
|
label: string;
|
|
17
|
+
id?: string;
|
|
18
|
+
autoComplete?: 'current-password' | 'new-password';
|
|
16
19
|
};
|
|
17
20
|
submit: string;
|
|
18
21
|
/** the vendor's message for a refused attempt ("Incorrect username or password.") */
|
package/dist/client/sign-in.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
export function SignIn(props) {
|
|
3
|
-
return (_jsxs("main", { className: "sign-in", children: [_jsx("div", { className: "sign-in-mark", "aria-hidden": "true" }), _jsx("h1", { className: "sign-in-heading", children: props.heading }), props.error ? _jsx("div", { className: "sign-in-error", role: "alert", children: props.error }) : null, _jsxs("form", { method: "post", action: props.action, className: "sign-in-box", children: [Object.entries(props.fields).map(([name, value]) => _jsx("input", { type: "hidden", name: name, value: value }, name)), _jsx("label", { htmlFor: props.account.name, children: props.account.label }), _jsx("input", { id: props.account.name, name: props.account.name, type: "text", autoComplete: "username", defaultValue: props.account.value ?? '' }), _jsx("label", { htmlFor: props.password.name, children: props.password.label }), _jsx("input", { id: props.password.name, name: props.password.name, type: "password", autoComplete:
|
|
3
|
+
return (_jsxs("main", { className: "sign-in", children: [_jsx("div", { className: "sign-in-mark", "aria-hidden": "true" }), _jsx("h1", { className: "sign-in-heading", children: props.heading }), props.error ? _jsx("div", { className: "sign-in-error", role: "alert", children: props.error }) : null, _jsxs("form", { method: "post", action: props.action, className: "sign-in-box", children: [Object.entries(props.fields).map(([name, value]) => _jsx("input", { type: "hidden", name: name, value: value }, name)), _jsx("label", { htmlFor: props.account.id ?? props.account.name, children: props.account.label }), _jsx("input", { id: props.account.id ?? props.account.name, name: props.account.name, type: "text", autoComplete: "username", defaultValue: props.account.value ?? '' }), _jsx("label", { htmlFor: props.password.id ?? props.password.name, children: props.password.label }), _jsx("input", { id: props.password.id ?? props.password.name, name: props.password.name, type: "password", autoComplete: props.password.autoComplete ?? 'current-password' }), _jsx("button", { type: "submit", className: "sign-in-submit", children: props.submit })] })] }));
|
|
4
4
|
}
|
|
5
5
|
export function SignInCode(props) {
|
|
6
6
|
return (_jsxs("main", { className: "sign-in", children: [_jsx("div", { className: "sign-in-mark", "aria-hidden": "true" }), _jsx("h1", { className: "sign-in-heading", children: props.heading }), props.error ? _jsx("div", { className: "sign-in-error", role: "alert", children: props.error }) : null, _jsxs("form", { method: "post", action: props.action, className: "sign-in-box", children: [Object.entries(props.fields).map(([name, value]) => _jsx("input", { type: "hidden", name: name, value: value }, name)), _jsx("label", { htmlFor: props.code.name, children: props.code.label }), _jsx("input", { id: props.code.name, name: props.code.name, type: "text", inputMode: "numeric", autoComplete: "one-time-code" }), _jsx("p", { className: "sign-in-hint", children: props.hint }), _jsx("button", { type: "submit", className: "sign-in-submit", children: props.submit })] })] }));
|
package/dist/client/sign-in.tsx
CHANGED
|
@@ -10,8 +10,8 @@ export type SignInProps = {
|
|
|
10
10
|
action: string;
|
|
11
11
|
fields: Record<string, string>;
|
|
12
12
|
/** the account field and the password field: their names, labels and (the account's) prefilled value */
|
|
13
|
-
account: { name: string; label: string; value?: string };
|
|
14
|
-
password: { name: string; label: string };
|
|
13
|
+
account: { name: string; label: string; value?: string; id?: string };
|
|
14
|
+
password: { name: string; label: string; id?: string; autoComplete?: 'current-password' | 'new-password' };
|
|
15
15
|
submit: string;
|
|
16
16
|
/** the vendor's message for a refused attempt ("Incorrect username or password.") */
|
|
17
17
|
error?: string;
|
|
@@ -25,10 +25,12 @@ export function SignIn(props: SignInProps) {
|
|
|
25
25
|
{props.error ? <div className="sign-in-error" role="alert">{props.error}</div> : null}
|
|
26
26
|
<form method="post" action={props.action} className="sign-in-box">
|
|
27
27
|
{Object.entries(props.fields).map(([name, value]) => <input key={name} type="hidden" name={name} value={value} />)}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
<label htmlFor={props.
|
|
31
|
-
<input id={props.
|
|
28
|
+
{/* a field's id is its name unless the page gives another: a page with two sign-in forms (a login and a
|
|
29
|
+
create-account, as Hacker News's) keeps every id one of its own, so each label names its own field */}
|
|
30
|
+
<label htmlFor={props.account.id ?? props.account.name}>{props.account.label}</label>
|
|
31
|
+
<input id={props.account.id ?? props.account.name} name={props.account.name} type="text" autoComplete="username" defaultValue={props.account.value ?? ''} />
|
|
32
|
+
<label htmlFor={props.password.id ?? props.password.name}>{props.password.label}</label>
|
|
33
|
+
<input id={props.password.id ?? props.password.name} name={props.password.name} type="password" autoComplete={props.password.autoComplete ?? 'current-password'} />
|
|
32
34
|
<button type="submit" className="sign-in-submit">{props.submit}</button>
|
|
33
35
|
</form>
|
|
34
36
|
</main>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@volter/world-ui",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.20",
|
|
4
4
|
"description": "Shared pieces and serving for derived packs' screens (hosted flows and workspaces), through each pack's own API; see docs/contributing/architecture.md, Screens.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "Volter (https://github.com/volter-ai)",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"dist"
|
|
29
29
|
],
|
|
30
30
|
"peerDependencies": {
|
|
31
|
-
"@volter/world-core": "3.0.
|
|
31
|
+
"@volter/world-core": "3.0.20",
|
|
32
32
|
"react": "^19.2.7",
|
|
33
33
|
"react-dom": "^19.2.7"
|
|
34
34
|
},
|