playwright-core 1.57.0-alpha-2025-10-21 → 1.57.0-alpha-2025-10-23
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/ThirdPartyNotices.txt +28 -1
- package/lib/generated/injectedScriptSource.js +1 -1
- package/lib/server/frameSelectors.js +2 -4
- package/lib/server/frames.js +5 -0
- package/lib/server/page.js +4 -8
- package/lib/utilsBundle.js +6 -3
- package/lib/utilsBundleImpl/index.js +168 -168
- package/lib/vite/htmlReport/index.html +16 -16
- package/lib/vite/recorder/assets/codeMirrorModule-DX585GyR.js +25 -0
- package/lib/vite/recorder/assets/{index-BuEOMwzr.js → index-DjadjNw5.js} +2 -2
- package/lib/vite/recorder/index.html +1 -1
- package/lib/vite/traceViewer/assets/codeMirrorModule-Cw-6jrKz.js +25 -0
- package/lib/vite/traceViewer/assets/{defaultSettingsView-Bx2ouWUu.js → defaultSettingsView-BZIhX7gh.js} +76 -76
- package/lib/vite/traceViewer/{index.VwpdcXcy.js → index.Dk_obRs3.js} +1 -1
- package/lib/vite/traceViewer/index.html +2 -2
- package/lib/vite/traceViewer/{uiMode.D7xpyanj.js → uiMode.Bai-qGIw.js} +1 -1
- package/lib/vite/traceViewer/uiMode.html +2 -2
- package/package.json +1 -1
- package/lib/vite/recorder/assets/codeMirrorModule-C3YIS0Zg.js +0 -24
- package/lib/vite/traceViewer/assets/codeMirrorModule-CeWbQMSr.js +0 -24
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./codeMirrorModule-
|
|
2
|
-
var
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./codeMirrorModule-Cw-6jrKz.js","../codeMirrorModule.C3UTv-Ge.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
var Tw=Object.defineProperty;var Ew=(n,e,i)=>e in n?Tw(n,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):n[e]=i;var Ne=(n,e,i)=>Ew(n,typeof e!="symbol"?e+"":e,i);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const a of document.querySelectorAll('link[rel="modulepreload"]'))s(a);new MutationObserver(a=>{for(const o of a)if(o.type==="childList")for(const u of o.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&s(u)}).observe(document,{childList:!0,subtree:!0});function i(a){const o={};return a.integrity&&(o.integrity=a.integrity),a.referrerPolicy&&(o.referrerPolicy=a.referrerPolicy),a.crossOrigin==="use-credentials"?o.credentials="include":a.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function s(a){if(a.ep)return;a.ep=!0;const o=i(a);fetch(a.href,o)}})();function Aw(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var qf={exports:{}},Ta={};/**
|
|
3
3
|
* @license React
|
|
4
4
|
* react-jsx-runtime.production.js
|
|
5
5
|
*
|
|
@@ -7,7 +7,7 @@ var _w=Object.defineProperty;var Tw=(n,e,i)=>e in n?_w(n,e,{enumerable:!0,config
|
|
|
7
7
|
*
|
|
8
8
|
* This source code is licensed under the MIT license found in the
|
|
9
9
|
* LICENSE file in the root directory of this source tree.
|
|
10
|
-
*/var fy;function
|
|
10
|
+
*/var fy;function Nw(){if(fy)return Ta;fy=1;var n=Symbol.for("react.transitional.element"),e=Symbol.for("react.fragment");function i(s,a,o){var u=null;if(o!==void 0&&(u=""+o),a.key!==void 0&&(u=""+a.key),"key"in a){o={};for(var f in a)f!=="key"&&(o[f]=a[f])}else o=a;return a=o.ref,{$$typeof:n,type:s,key:u,ref:a!==void 0?a:null,props:o}}return Ta.Fragment=e,Ta.jsx=i,Ta.jsxs=i,Ta}var hy;function Cw(){return hy||(hy=1,qf.exports=Nw()),qf.exports}var v=Cw(),$f={exports:{}},he={};/**
|
|
11
11
|
* @license React
|
|
12
12
|
* react.production.js
|
|
13
13
|
*
|
|
@@ -15,7 +15,7 @@ var _w=Object.defineProperty;var Tw=(n,e,i)=>e in n?_w(n,e,{enumerable:!0,config
|
|
|
15
15
|
*
|
|
16
16
|
* This source code is licensed under the MIT license found in the
|
|
17
17
|
* LICENSE file in the root directory of this source tree.
|
|
18
|
-
*/var dy;function Cw(){if(dy)return he;dy=1;var n=Symbol.for("react.transitional.element"),e=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),s=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),u=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),y=Symbol.iterator;function b(N){return N===null||typeof N!="object"?null:(N=y&&N[y]||N["@@iterator"],typeof N=="function"?N:null)}var w={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},E=Object.assign,x={};function _(N,X,Q){this.props=N,this.context=X,this.refs=x,this.updater=Q||w}_.prototype.isReactComponent={},_.prototype.setState=function(N,X){if(typeof N!="object"&&typeof N!="function"&&N!=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,N,X,"setState")},_.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function k(){}k.prototype=_.prototype;function C(N,X,Q){this.props=N,this.context=X,this.refs=x,this.updater=Q||w}var V=C.prototype=new k;V.constructor=C,E(V,_.prototype),V.isPureReactComponent=!0;var I=Array.isArray,B={H:null,A:null,T:null,S:null,V:null},G=Object.prototype.hasOwnProperty;function J(N,X,Q,W,se,ve){return Q=ve.ref,{$$typeof:n,type:N,key:X,ref:Q!==void 0?Q:null,props:ve}}function $(N,X){return J(N.type,X,void 0,void 0,void 0,N.props)}function R(N){return typeof N=="object"&&N!==null&&N.$$typeof===n}function ee(N){var X={"=":"=0",":":"=2"};return"$"+N.replace(/[=:]/g,function(Q){return X[Q]})}var re=/\/+/g;function j(N,X){return typeof N=="object"&&N!==null&&N.key!=null?ee(""+N.key):X.toString(36)}function F(){}function ge(N){switch(N.status){case"fulfilled":return N.value;case"rejected":throw N.reason;default:switch(typeof N.status=="string"?N.then(F,F):(N.status="pending",N.then(function(X){N.status==="pending"&&(N.status="fulfilled",N.value=X)},function(X){N.status==="pending"&&(N.status="rejected",N.reason=X)})),N.status){case"fulfilled":return N.value;case"rejected":throw N.reason}}throw N}function me(N,X,Q,W,se){var ve=typeof N;(ve==="undefined"||ve==="boolean")&&(N=null);var ue=!1;if(N===null)ue=!0;else switch(ve){case"bigint":case"string":case"number":ue=!0;break;case"object":switch(N.$$typeof){case n:case e:ue=!0;break;case m:return ue=N._init,me(ue(N._payload),X,Q,W,se)}}if(ue)return se=se(N),ue=W===""?"."+j(N,0):W,I(se)?(Q="",ue!=null&&(Q=ue.replace(re,"$&/")+"/"),me(se,X,Q,"",function(gn){return gn})):se!=null&&(R(se)&&(se=$(se,Q+(se.key==null||N&&N.key===se.key?"":(""+se.key).replace(re,"$&/")+"/")+ue)),X.push(se)),1;ue=0;var We=W===""?".":W+":";if(I(N))for(var xe=0;xe<N.length;xe++)W=N[xe],ve=We+j(W,xe),ue+=me(W,X,Q,ve,se);else if(xe=b(N),typeof xe=="function")for(N=xe.call(N),xe=0;!(W=N.next()).done;)W=W.value,ve=We+j(W,xe++),ue+=me(W,X,Q,ve,se);else if(ve==="object"){if(typeof N.then=="function")return me(ge(N),X,Q,W,se);throw X=String(N),Error("Objects are not valid as a React child (found: "+(X==="[object Object]"?"object with keys {"+Object.keys(N).join(", ")+"}":X)+"). If you meant to render a collection of children, use an array instead.")}return ue}function q(N,X,Q){if(N==null)return N;var W=[],se=0;return me(N,W,"","",function(ve){return X.call(Q,ve,se++)}),W}function Z(N){if(N._status===-1){var X=N._result;X=X(),X.then(function(Q){(N._status===0||N._status===-1)&&(N._status=1,N._result=Q)},function(Q){(N._status===0||N._status===-1)&&(N._status=2,N._result=Q)}),N._status===-1&&(N._status=0,N._result=X)}if(N._status===1)return N._result.default;throw N._result}var ne=typeof reportError=="function"?reportError:function(N){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var X=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof N=="object"&&N!==null&&typeof N.message=="string"?String(N.message):String(N),error:N});if(!window.dispatchEvent(X))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",N);return}console.error(N)};function Se(){}return he.Children={map:q,forEach:function(N,X,Q){q(N,function(){X.apply(this,arguments)},Q)},count:function(N){var X=0;return q(N,function(){X++}),X},toArray:function(N){return q(N,function(X){return X})||[]},only:function(N){if(!R(N))throw Error("React.Children.only expected to receive a single React element child.");return N}},he.Component=_,he.Fragment=i,he.Profiler=a,he.PureComponent=C,he.StrictMode=s,he.Suspense=d,he.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=B,he.__COMPILER_RUNTIME={__proto__:null,c:function(N){return B.H.useMemoCache(N)}},he.cache=function(N){return function(){return N.apply(null,arguments)}},he.cloneElement=function(N,X,Q){if(N==null)throw Error("The argument must be a React element, but you passed "+N+".");var W=E({},N.props),se=N.key,ve=void 0;if(X!=null)for(ue in X.ref!==void 0&&(ve=void 0),X.key!==void 0&&(se=""+X.key),X)!G.call(X,ue)||ue==="key"||ue==="__self"||ue==="__source"||ue==="ref"&&X.ref===void 0||(W[ue]=X[ue]);var ue=arguments.length-2;if(ue===1)W.children=Q;else if(1<ue){for(var We=Array(ue),xe=0;xe<ue;xe++)We[xe]=arguments[xe+2];W.children=We}return J(N.type,se,void 0,void 0,ve,W)},he.createContext=function(N){return N={$$typeof:u,_currentValue:N,_currentValue2:N,_threadCount:0,Provider:null,Consumer:null},N.Provider=N,N.Consumer={$$typeof:o,_context:N},N},he.createElement=function(N,X,Q){var W,se={},ve=null;if(X!=null)for(W in X.key!==void 0&&(ve=""+X.key),X)G.call(X,W)&&W!=="key"&&W!=="__self"&&W!=="__source"&&(se[W]=X[W]);var ue=arguments.length-2;if(ue===1)se.children=Q;else if(1<ue){for(var We=Array(ue),xe=0;xe<ue;xe++)We[xe]=arguments[xe+2];se.children=We}if(N&&N.defaultProps)for(W in ue=N.defaultProps,ue)se[W]===void 0&&(se[W]=ue[W]);return J(N,ve,void 0,void 0,null,se)},he.createRef=function(){return{current:null}},he.forwardRef=function(N){return{$$typeof:f,render:N}},he.isValidElement=R,he.lazy=function(N){return{$$typeof:m,_payload:{_status:-1,_result:N},_init:Z}},he.memo=function(N,X){return{$$typeof:p,type:N,compare:X===void 0?null:X}},he.startTransition=function(N){var X=B.T,Q={};B.T=Q;try{var W=N(),se=B.S;se!==null&&se(Q,W),typeof W=="object"&&W!==null&&typeof W.then=="function"&&W.then(Se,ne)}catch(ve){ne(ve)}finally{B.T=X}},he.unstable_useCacheRefresh=function(){return B.H.useCacheRefresh()},he.use=function(N){return B.H.use(N)},he.useActionState=function(N,X,Q){return B.H.useActionState(N,X,Q)},he.useCallback=function(N,X){return B.H.useCallback(N,X)},he.useContext=function(N){return B.H.useContext(N)},he.useDebugValue=function(){},he.useDeferredValue=function(N,X){return B.H.useDeferredValue(N,X)},he.useEffect=function(N,X,Q){var W=B.H;if(typeof Q=="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return W.useEffect(N,X)},he.useId=function(){return B.H.useId()},he.useImperativeHandle=function(N,X,Q){return B.H.useImperativeHandle(N,X,Q)},he.useInsertionEffect=function(N,X){return B.H.useInsertionEffect(N,X)},he.useLayoutEffect=function(N,X){return B.H.useLayoutEffect(N,X)},he.useMemo=function(N,X){return B.H.useMemo(N,X)},he.useOptimistic=function(N,X){return B.H.useOptimistic(N,X)},he.useReducer=function(N,X,Q){return B.H.useReducer(N,X,Q)},he.useRef=function(N){return B.H.useRef(N)},he.useState=function(N){return B.H.useState(N)},he.useSyncExternalStore=function(N,X,Q){return B.H.useSyncExternalStore(N,X,Q)},he.useTransition=function(){return B.H.useTransition()},he.version="19.1.1",he}var py;function kh(){return py||(py=1,$f.exports=Cw()),$f.exports}var U=kh();const Ut=Ew(U);function Io(n,e,i,s){const[a,o]=Ut.useState(i);return Ut.useEffect(()=>{let u=!1;return n().then(f=>{u||o(f)}),()=>{u=!0}},e),a}function ts(){const n=Ut.useRef(null),[e]=uh(n);return[e,n]}function uh(n){const[e,i]=Ut.useState(new DOMRect(0,0,10,10)),s=Ut.useCallback(()=>{const a=n==null?void 0:n.current;a&&i(a.getBoundingClientRect())},[n]);return Ut.useLayoutEffect(()=>{const a=n==null?void 0:n.current;if(!a)return;s();const o=new ResizeObserver(s);return o.observe(a),window.addEventListener("resize",s),()=>{o.disconnect(),window.removeEventListener("resize",s)}},[s,n]),[e,s]}function _t(n){if(n<0||!isFinite(n))return"-";if(n===0)return"0";if(n<1e3)return n.toFixed(0)+"ms";const e=n/1e3;if(e<60)return e.toFixed(1)+"s";const i=e/60;if(i<60)return i.toFixed(1)+"m";const s=i/60;return s<24?s.toFixed(1)+"h":(s/24).toFixed(1)+"d"}function kw(n){if(n<0||!isFinite(n))return"-";if(n===0)return"0";if(n<1e3)return n.toFixed(0);const e=n/1024;if(e<1e3)return e.toFixed(1)+"K";const i=e/1024;return i<1e3?i.toFixed(1)+"M":(i/1024).toFixed(1)+"G"}function v0(n,e,i,s,a){let o=0,u=n.length;for(;o<u;){const f=o+u>>1;i(e,n[f])>=0?o=f+1:u=f}return u}function gy(n){const e=document.createElement("textarea");e.style.position="absolute",e.style.zIndex="-1000",e.value=n,document.body.appendChild(e),e.select(),document.execCommand("copy"),e.remove()}function xn(n,e){n&&(e=Yi.getObject(n,e));const[i,s]=Ut.useState(e),a=Ut.useCallback(o=>{n?Yi.setObject(n,o):s(o)},[n,s]);return Ut.useEffect(()=>{if(n){const o=()=>s(Yi.getObject(n,e));return Yi.onChangeEmitter.addEventListener(n,o),()=>Yi.onChangeEmitter.removeEventListener(n,o)}},[e,n]),[i,a]}class Mw{constructor(){this.onChangeEmitter=new EventTarget}getString(e,i){return localStorage[e]||i}setString(e,i){var s;localStorage[e]=i,this.onChangeEmitter.dispatchEvent(new Event(e)),(s=window.saveSettings)==null||s.call(window)}getObject(e,i){if(!localStorage[e])return i;try{return JSON.parse(localStorage[e])}catch{return i}}setObject(e,i){var s;localStorage[e]=JSON.stringify(i),this.onChangeEmitter.dispatchEvent(new Event(e)),(s=window.saveSettings)==null||s.call(window)}}const Yi=new Mw;function Ke(...n){return n.filter(Boolean).join(" ")}function S0(n){n&&(n!=null&&n.scrollIntoViewIfNeeded?n.scrollIntoViewIfNeeded(!1):n==null||n.scrollIntoView())}const my="\\u0000-\\u0020\\u007f-\\u009f",w0=new RegExp("(?:[a-zA-Z][a-zA-Z0-9+.-]{2,}:\\/\\/|www\\.)[^\\s"+my+'"]{2,}[^\\s'+my+`"')}\\],:;.!?]`,"ug");function Ow(){const[n,e]=Ut.useState(!1),i=Ut.useCallback(()=>{const s=[];return e(a=>(s.push(setTimeout(()=>e(!1),1e3)),a?(s.push(setTimeout(()=>e(!0),50)),!1):!0)),()=>s.forEach(clearTimeout)},[e]);return[n,i]}function IN(){if(document.playwrightThemeInitialized)return;document.playwrightThemeInitialized=!0,document.defaultView.addEventListener("focus",s=>{s.target.document.nodeType===Node.DOCUMENT_NODE&&document.body.classList.remove("inactive")},!1),document.defaultView.addEventListener("blur",s=>{document.body.classList.add("inactive")},!1);const e=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark-mode":"light-mode";Yi.getString("theme",e)==="dark-mode"?document.documentElement.classList.add("dark-mode"):document.documentElement.classList.add("light-mode")}const Mh=new Set;function Rw(){const n=fh(),e=n==="dark-mode"?"light-mode":"dark-mode";document.documentElement.classList.remove(n),document.documentElement.classList.add(e),Yi.setString("theme",e);for(const i of Mh)i(e)}function VN(n){Mh.add(n)}function GN(n){Mh.delete(n)}function fh(){return document.documentElement.classList.contains("dark-mode")?"dark-mode":"light-mode"}function jw(){const[n,e]=Ut.useState(fh()==="dark-mode");return[n,i=>{fh()==="dark-mode"!==i&&Rw(),e(i)}]}var If={exports:{}},Ea={},Vf={exports:{}},Gf={};/**
|
|
18
|
+
*/var dy;function kw(){if(dy)return he;dy=1;var n=Symbol.for("react.transitional.element"),e=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),s=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),u=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),y=Symbol.iterator;function b(N){return N===null||typeof N!="object"?null:(N=y&&N[y]||N["@@iterator"],typeof N=="function"?N:null)}var w={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},E=Object.assign,x={};function _(N,X,Q){this.props=N,this.context=X,this.refs=x,this.updater=Q||w}_.prototype.isReactComponent={},_.prototype.setState=function(N,X){if(typeof N!="object"&&typeof N!="function"&&N!=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,N,X,"setState")},_.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function k(){}k.prototype=_.prototype;function C(N,X,Q){this.props=N,this.context=X,this.refs=x,this.updater=Q||w}var V=C.prototype=new k;V.constructor=C,E(V,_.prototype),V.isPureReactComponent=!0;var I=Array.isArray,B={H:null,A:null,T:null,S:null,V:null},G=Object.prototype.hasOwnProperty;function J(N,X,Q,W,se,ve){return Q=ve.ref,{$$typeof:n,type:N,key:X,ref:Q!==void 0?Q:null,props:ve}}function $(N,X){return J(N.type,X,void 0,void 0,void 0,N.props)}function R(N){return typeof N=="object"&&N!==null&&N.$$typeof===n}function ee(N){var X={"=":"=0",":":"=2"};return"$"+N.replace(/[=:]/g,function(Q){return X[Q]})}var re=/\/+/g;function j(N,X){return typeof N=="object"&&N!==null&&N.key!=null?ee(""+N.key):X.toString(36)}function F(){}function ge(N){switch(N.status){case"fulfilled":return N.value;case"rejected":throw N.reason;default:switch(typeof N.status=="string"?N.then(F,F):(N.status="pending",N.then(function(X){N.status==="pending"&&(N.status="fulfilled",N.value=X)},function(X){N.status==="pending"&&(N.status="rejected",N.reason=X)})),N.status){case"fulfilled":return N.value;case"rejected":throw N.reason}}throw N}function me(N,X,Q,W,se){var ve=typeof N;(ve==="undefined"||ve==="boolean")&&(N=null);var ue=!1;if(N===null)ue=!0;else switch(ve){case"bigint":case"string":case"number":ue=!0;break;case"object":switch(N.$$typeof){case n:case e:ue=!0;break;case m:return ue=N._init,me(ue(N._payload),X,Q,W,se)}}if(ue)return se=se(N),ue=W===""?"."+j(N,0):W,I(se)?(Q="",ue!=null&&(Q=ue.replace(re,"$&/")+"/"),me(se,X,Q,"",function(gn){return gn})):se!=null&&(R(se)&&(se=$(se,Q+(se.key==null||N&&N.key===se.key?"":(""+se.key).replace(re,"$&/")+"/")+ue)),X.push(se)),1;ue=0;var We=W===""?".":W+":";if(I(N))for(var xe=0;xe<N.length;xe++)W=N[xe],ve=We+j(W,xe),ue+=me(W,X,Q,ve,se);else if(xe=b(N),typeof xe=="function")for(N=xe.call(N),xe=0;!(W=N.next()).done;)W=W.value,ve=We+j(W,xe++),ue+=me(W,X,Q,ve,se);else if(ve==="object"){if(typeof N.then=="function")return me(ge(N),X,Q,W,se);throw X=String(N),Error("Objects are not valid as a React child (found: "+(X==="[object Object]"?"object with keys {"+Object.keys(N).join(", ")+"}":X)+"). If you meant to render a collection of children, use an array instead.")}return ue}function q(N,X,Q){if(N==null)return N;var W=[],se=0;return me(N,W,"","",function(ve){return X.call(Q,ve,se++)}),W}function Z(N){if(N._status===-1){var X=N._result;X=X(),X.then(function(Q){(N._status===0||N._status===-1)&&(N._status=1,N._result=Q)},function(Q){(N._status===0||N._status===-1)&&(N._status=2,N._result=Q)}),N._status===-1&&(N._status=0,N._result=X)}if(N._status===1)return N._result.default;throw N._result}var ne=typeof reportError=="function"?reportError:function(N){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var X=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof N=="object"&&N!==null&&typeof N.message=="string"?String(N.message):String(N),error:N});if(!window.dispatchEvent(X))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",N);return}console.error(N)};function Se(){}return he.Children={map:q,forEach:function(N,X,Q){q(N,function(){X.apply(this,arguments)},Q)},count:function(N){var X=0;return q(N,function(){X++}),X},toArray:function(N){return q(N,function(X){return X})||[]},only:function(N){if(!R(N))throw Error("React.Children.only expected to receive a single React element child.");return N}},he.Component=_,he.Fragment=i,he.Profiler=a,he.PureComponent=C,he.StrictMode=s,he.Suspense=d,he.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=B,he.__COMPILER_RUNTIME={__proto__:null,c:function(N){return B.H.useMemoCache(N)}},he.cache=function(N){return function(){return N.apply(null,arguments)}},he.cloneElement=function(N,X,Q){if(N==null)throw Error("The argument must be a React element, but you passed "+N+".");var W=E({},N.props),se=N.key,ve=void 0;if(X!=null)for(ue in X.ref!==void 0&&(ve=void 0),X.key!==void 0&&(se=""+X.key),X)!G.call(X,ue)||ue==="key"||ue==="__self"||ue==="__source"||ue==="ref"&&X.ref===void 0||(W[ue]=X[ue]);var ue=arguments.length-2;if(ue===1)W.children=Q;else if(1<ue){for(var We=Array(ue),xe=0;xe<ue;xe++)We[xe]=arguments[xe+2];W.children=We}return J(N.type,se,void 0,void 0,ve,W)},he.createContext=function(N){return N={$$typeof:u,_currentValue:N,_currentValue2:N,_threadCount:0,Provider:null,Consumer:null},N.Provider=N,N.Consumer={$$typeof:o,_context:N},N},he.createElement=function(N,X,Q){var W,se={},ve=null;if(X!=null)for(W in X.key!==void 0&&(ve=""+X.key),X)G.call(X,W)&&W!=="key"&&W!=="__self"&&W!=="__source"&&(se[W]=X[W]);var ue=arguments.length-2;if(ue===1)se.children=Q;else if(1<ue){for(var We=Array(ue),xe=0;xe<ue;xe++)We[xe]=arguments[xe+2];se.children=We}if(N&&N.defaultProps)for(W in ue=N.defaultProps,ue)se[W]===void 0&&(se[W]=ue[W]);return J(N,ve,void 0,void 0,null,se)},he.createRef=function(){return{current:null}},he.forwardRef=function(N){return{$$typeof:f,render:N}},he.isValidElement=R,he.lazy=function(N){return{$$typeof:m,_payload:{_status:-1,_result:N},_init:Z}},he.memo=function(N,X){return{$$typeof:p,type:N,compare:X===void 0?null:X}},he.startTransition=function(N){var X=B.T,Q={};B.T=Q;try{var W=N(),se=B.S;se!==null&&se(Q,W),typeof W=="object"&&W!==null&&typeof W.then=="function"&&W.then(Se,ne)}catch(ve){ne(ve)}finally{B.T=X}},he.unstable_useCacheRefresh=function(){return B.H.useCacheRefresh()},he.use=function(N){return B.H.use(N)},he.useActionState=function(N,X,Q){return B.H.useActionState(N,X,Q)},he.useCallback=function(N,X){return B.H.useCallback(N,X)},he.useContext=function(N){return B.H.useContext(N)},he.useDebugValue=function(){},he.useDeferredValue=function(N,X){return B.H.useDeferredValue(N,X)},he.useEffect=function(N,X,Q){var W=B.H;if(typeof Q=="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return W.useEffect(N,X)},he.useId=function(){return B.H.useId()},he.useImperativeHandle=function(N,X,Q){return B.H.useImperativeHandle(N,X,Q)},he.useInsertionEffect=function(N,X){return B.H.useInsertionEffect(N,X)},he.useLayoutEffect=function(N,X){return B.H.useLayoutEffect(N,X)},he.useMemo=function(N,X){return B.H.useMemo(N,X)},he.useOptimistic=function(N,X){return B.H.useOptimistic(N,X)},he.useReducer=function(N,X,Q){return B.H.useReducer(N,X,Q)},he.useRef=function(N){return B.H.useRef(N)},he.useState=function(N){return B.H.useState(N)},he.useSyncExternalStore=function(N,X,Q){return B.H.useSyncExternalStore(N,X,Q)},he.useTransition=function(){return B.H.useTransition()},he.version="19.1.1",he}var py;function kh(){return py||(py=1,$f.exports=kw()),$f.exports}var U=kh();const Ut=Aw(U);function Io(n,e,i,s){const[a,o]=Ut.useState(i);return Ut.useEffect(()=>{let u=!1;return n().then(f=>{u||o(f)}),()=>{u=!0}},e),a}function ts(){const n=Ut.useRef(null),[e]=uh(n);return[e,n]}function uh(n){const[e,i]=Ut.useState(new DOMRect(0,0,10,10)),s=Ut.useCallback(()=>{const a=n==null?void 0:n.current;a&&i(a.getBoundingClientRect())},[n]);return Ut.useLayoutEffect(()=>{const a=n==null?void 0:n.current;if(!a)return;s();const o=new ResizeObserver(s);return o.observe(a),window.addEventListener("resize",s),()=>{o.disconnect(),window.removeEventListener("resize",s)}},[s,n]),[e,s]}function _t(n){if(n<0||!isFinite(n))return"-";if(n===0)return"0";if(n<1e3)return n.toFixed(0)+"ms";const e=n/1e3;if(e<60)return e.toFixed(1)+"s";const i=e/60;if(i<60)return i.toFixed(1)+"m";const s=i/60;return s<24?s.toFixed(1)+"h":(s/24).toFixed(1)+"d"}function Mw(n){if(n<0||!isFinite(n))return"-";if(n===0)return"0";if(n<1e3)return n.toFixed(0);const e=n/1024;if(e<1e3)return e.toFixed(1)+"K";const i=e/1024;return i<1e3?i.toFixed(1)+"M":(i/1024).toFixed(1)+"G"}function v0(n,e,i,s,a){let o=0,u=n.length;for(;o<u;){const f=o+u>>1;i(e,n[f])>=0?o=f+1:u=f}return u}function gy(n){const e=document.createElement("textarea");e.style.position="absolute",e.style.zIndex="-1000",e.value=n,document.body.appendChild(e),e.select(),document.execCommand("copy"),e.remove()}function xn(n,e){n&&(e=Yi.getObject(n,e));const[i,s]=Ut.useState(e),a=Ut.useCallback(o=>{n?Yi.setObject(n,o):s(o)},[n,s]);return Ut.useEffect(()=>{if(n){const o=()=>s(Yi.getObject(n,e));return Yi.onChangeEmitter.addEventListener(n,o),()=>Yi.onChangeEmitter.removeEventListener(n,o)}},[e,n]),[i,a]}class Ow{constructor(){this.onChangeEmitter=new EventTarget}getString(e,i){return localStorage[e]||i}setString(e,i){var s;localStorage[e]=i,this.onChangeEmitter.dispatchEvent(new Event(e)),(s=window.saveSettings)==null||s.call(window)}getObject(e,i){if(!localStorage[e])return i;try{return JSON.parse(localStorage[e])}catch{return i}}setObject(e,i){var s;localStorage[e]=JSON.stringify(i),this.onChangeEmitter.dispatchEvent(new Event(e)),(s=window.saveSettings)==null||s.call(window)}}const Yi=new Ow;function Ke(...n){return n.filter(Boolean).join(" ")}function S0(n){n&&(n!=null&&n.scrollIntoViewIfNeeded?n.scrollIntoViewIfNeeded(!1):n==null||n.scrollIntoView())}const my="\\u0000-\\u0020\\u007f-\\u009f",w0=new RegExp("(?:[a-zA-Z][a-zA-Z0-9+.-]{2,}:\\/\\/|www\\.)[^\\s"+my+'"]{2,}[^\\s'+my+`"')}\\],:;.!?]`,"ug");function Rw(){const[n,e]=Ut.useState(!1),i=Ut.useCallback(()=>{const s=[];return e(a=>(s.push(setTimeout(()=>e(!1),1e3)),a?(s.push(setTimeout(()=>e(!0),50)),!1):!0)),()=>s.forEach(clearTimeout)},[e]);return[n,i]}function VN(){if(document.playwrightThemeInitialized)return;document.playwrightThemeInitialized=!0,document.defaultView.addEventListener("focus",s=>{s.target.document.nodeType===Node.DOCUMENT_NODE&&document.body.classList.remove("inactive")},!1),document.defaultView.addEventListener("blur",s=>{document.body.classList.add("inactive")},!1);const e=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark-mode":"light-mode";Yi.getString("theme",e)==="dark-mode"?document.documentElement.classList.add("dark-mode"):document.documentElement.classList.add("light-mode")}const Mh=new Set;function jw(){const n=fh(),e=n==="dark-mode"?"light-mode":"dark-mode";document.documentElement.classList.remove(n),document.documentElement.classList.add(e),Yi.setString("theme",e);for(const i of Mh)i(e)}function GN(n){Mh.add(n)}function KN(n){Mh.delete(n)}function fh(){return document.documentElement.classList.contains("dark-mode")?"dark-mode":"light-mode"}function Lw(){const[n,e]=Ut.useState(fh()==="dark-mode");return[n,i=>{fh()==="dark-mode"!==i&&jw(),e(i)}]}var If={exports:{}},Ea={},Vf={exports:{}},Gf={};/**
|
|
19
19
|
* @license React
|
|
20
20
|
* scheduler.production.js
|
|
21
21
|
*
|
|
@@ -23,7 +23,7 @@ var _w=Object.defineProperty;var Tw=(n,e,i)=>e in n?_w(n,e,{enumerable:!0,config
|
|
|
23
23
|
*
|
|
24
24
|
* This source code is licensed under the MIT license found in the
|
|
25
25
|
* LICENSE file in the root directory of this source tree.
|
|
26
|
-
*/var yy;function
|
|
26
|
+
*/var yy;function Dw(){return yy||(yy=1,(function(n){function e(q,Z){var ne=q.length;q.push(Z);e:for(;0<ne;){var Se=ne-1>>>1,N=q[Se];if(0<a(N,Z))q[Se]=Z,q[ne]=N,ne=Se;else break e}}function i(q){return q.length===0?null:q[0]}function s(q){if(q.length===0)return null;var Z=q[0],ne=q.pop();if(ne!==Z){q[0]=ne;e:for(var Se=0,N=q.length,X=N>>>1;Se<X;){var Q=2*(Se+1)-1,W=q[Q],se=Q+1,ve=q[se];if(0>a(W,ne))se<N&&0>a(ve,W)?(q[Se]=ve,q[se]=ne,Se=se):(q[Se]=W,q[Q]=ne,Se=Q);else if(se<N&&0>a(ve,ne))q[Se]=ve,q[se]=ne,Se=se;else break e}}return Z}function a(q,Z){var ne=q.sortIndex-Z.sortIndex;return ne!==0?ne:q.id-Z.id}if(n.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var o=performance;n.unstable_now=function(){return o.now()}}else{var u=Date,f=u.now();n.unstable_now=function(){return u.now()-f}}var d=[],p=[],m=1,y=null,b=3,w=!1,E=!1,x=!1,_=!1,k=typeof setTimeout=="function"?setTimeout:null,C=typeof clearTimeout=="function"?clearTimeout:null,V=typeof setImmediate<"u"?setImmediate:null;function I(q){for(var Z=i(p);Z!==null;){if(Z.callback===null)s(p);else if(Z.startTime<=q)s(p),Z.sortIndex=Z.expirationTime,e(d,Z);else break;Z=i(p)}}function B(q){if(x=!1,I(q),!E)if(i(d)!==null)E=!0,G||(G=!0,j());else{var Z=i(p);Z!==null&&me(B,Z.startTime-q)}}var G=!1,J=-1,$=5,R=-1;function ee(){return _?!0:!(n.unstable_now()-R<$)}function re(){if(_=!1,G){var q=n.unstable_now();R=q;var Z=!0;try{e:{E=!1,x&&(x=!1,C(J),J=-1),w=!0;var ne=b;try{t:{for(I(q),y=i(d);y!==null&&!(y.expirationTime>q&&ee());){var Se=y.callback;if(typeof Se=="function"){y.callback=null,b=y.priorityLevel;var N=Se(y.expirationTime<=q);if(q=n.unstable_now(),typeof N=="function"){y.callback=N,I(q),Z=!0;break t}y===i(d)&&s(d),I(q)}else s(d);y=i(d)}if(y!==null)Z=!0;else{var X=i(p);X!==null&&me(B,X.startTime-q),Z=!1}}break e}finally{y=null,b=ne,w=!1}Z=void 0}}finally{Z?j():G=!1}}}var j;if(typeof V=="function")j=function(){V(re)};else if(typeof MessageChannel<"u"){var F=new MessageChannel,ge=F.port2;F.port1.onmessage=re,j=function(){ge.postMessage(null)}}else j=function(){k(re,0)};function me(q,Z){J=k(function(){q(n.unstable_now())},Z)}n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(q){q.callback=null},n.unstable_forceFrameRate=function(q){0>q||125<q?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):$=0<q?Math.floor(1e3/q):5},n.unstable_getCurrentPriorityLevel=function(){return b},n.unstable_next=function(q){switch(b){case 1:case 2:case 3:var Z=3;break;default:Z=b}var ne=b;b=Z;try{return q()}finally{b=ne}},n.unstable_requestPaint=function(){_=!0},n.unstable_runWithPriority=function(q,Z){switch(q){case 1:case 2:case 3:case 4:case 5:break;default:q=3}var ne=b;b=q;try{return Z()}finally{b=ne}},n.unstable_scheduleCallback=function(q,Z,ne){var Se=n.unstable_now();switch(typeof ne=="object"&&ne!==null?(ne=ne.delay,ne=typeof ne=="number"&&0<ne?Se+ne:Se):ne=Se,q){case 1:var N=-1;break;case 2:N=250;break;case 5:N=1073741823;break;case 4:N=1e4;break;default:N=5e3}return N=ne+N,q={id:m++,callback:Z,priorityLevel:q,startTime:ne,expirationTime:N,sortIndex:-1},ne>Se?(q.sortIndex=ne,e(p,q),i(d)===null&&q===i(p)&&(x?(C(J),J=-1):x=!0,me(B,ne-Se))):(q.sortIndex=N,e(d,q),E||w||(E=!0,G||(G=!0,j()))),q},n.unstable_shouldYield=ee,n.unstable_wrapCallback=function(q){var Z=b;return function(){var ne=b;b=Z;try{return q.apply(this,arguments)}finally{b=ne}}}})(Gf)),Gf}var by;function Bw(){return by||(by=1,Vf.exports=Dw()),Vf.exports}var Kf={exports:{}},mt={};/**
|
|
27
27
|
* @license React
|
|
28
28
|
* react-dom.production.js
|
|
29
29
|
*
|
|
@@ -31,7 +31,7 @@ var _w=Object.defineProperty;var Tw=(n,e,i)=>e in n?_w(n,e,{enumerable:!0,config
|
|
|
31
31
|
*
|
|
32
32
|
* This source code is licensed under the MIT license found in the
|
|
33
33
|
* LICENSE file in the root directory of this source tree.
|
|
34
|
-
*/var vy;function
|
|
34
|
+
*/var vy;function Uw(){if(vy)return mt;vy=1;var n=kh();function e(d){var p="https://react.dev/errors/"+d;if(1<arguments.length){p+="?args[]="+encodeURIComponent(arguments[1]);for(var m=2;m<arguments.length;m++)p+="&args[]="+encodeURIComponent(arguments[m])}return"Minified React error #"+d+"; visit "+p+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(){}var s={d:{f:i,r:function(){throw Error(e(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},a=Symbol.for("react.portal");function o(d,p,m){var y=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:y==null?null:""+y,children:d,containerInfo:p,implementation:m}}var u=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function f(d,p){if(d==="font")return"";if(typeof p=="string")return p==="use-credentials"?p:""}return mt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=s,mt.createPortal=function(d,p){var m=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!p||p.nodeType!==1&&p.nodeType!==9&&p.nodeType!==11)throw Error(e(299));return o(d,p,null,m)},mt.flushSync=function(d){var p=u.T,m=s.p;try{if(u.T=null,s.p=2,d)return d()}finally{u.T=p,s.p=m,s.d.f()}},mt.preconnect=function(d,p){typeof d=="string"&&(p?(p=p.crossOrigin,p=typeof p=="string"?p==="use-credentials"?p:"":void 0):p=null,s.d.C(d,p))},mt.prefetchDNS=function(d){typeof d=="string"&&s.d.D(d)},mt.preinit=function(d,p){if(typeof d=="string"&&p&&typeof p.as=="string"){var m=p.as,y=f(m,p.crossOrigin),b=typeof p.integrity=="string"?p.integrity:void 0,w=typeof p.fetchPriority=="string"?p.fetchPriority:void 0;m==="style"?s.d.S(d,typeof p.precedence=="string"?p.precedence:void 0,{crossOrigin:y,integrity:b,fetchPriority:w}):m==="script"&&s.d.X(d,{crossOrigin:y,integrity:b,fetchPriority:w,nonce:typeof p.nonce=="string"?p.nonce:void 0})}},mt.preinitModule=function(d,p){if(typeof d=="string")if(typeof p=="object"&&p!==null){if(p.as==null||p.as==="script"){var m=f(p.as,p.crossOrigin);s.d.M(d,{crossOrigin:m,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0})}}else p==null&&s.d.M(d)},mt.preload=function(d,p){if(typeof d=="string"&&typeof p=="object"&&p!==null&&typeof p.as=="string"){var m=p.as,y=f(m,p.crossOrigin);s.d.L(d,m,{crossOrigin:y,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0,type:typeof p.type=="string"?p.type:void 0,fetchPriority:typeof p.fetchPriority=="string"?p.fetchPriority:void 0,referrerPolicy:typeof p.referrerPolicy=="string"?p.referrerPolicy:void 0,imageSrcSet:typeof p.imageSrcSet=="string"?p.imageSrcSet:void 0,imageSizes:typeof p.imageSizes=="string"?p.imageSizes:void 0,media:typeof p.media=="string"?p.media:void 0})}},mt.preloadModule=function(d,p){if(typeof d=="string")if(p){var m=f(p.as,p.crossOrigin);s.d.m(d,{as:typeof p.as=="string"&&p.as!=="script"?p.as:void 0,crossOrigin:m,integrity:typeof p.integrity=="string"?p.integrity:void 0})}else s.d.m(d)},mt.requestFormReset=function(d){s.d.r(d)},mt.unstable_batchedUpdates=function(d,p){return d(p)},mt.useFormState=function(d,p,m){return u.H.useFormState(d,p,m)},mt.useFormStatus=function(){return u.H.useHostTransitionStatus()},mt.version="19.1.1",mt}var Sy;function zw(){if(Sy)return Kf.exports;Sy=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}return n(),Kf.exports=Uw(),Kf.exports}/**
|
|
35
35
|
* @license React
|
|
36
36
|
* react-dom-client.production.js
|
|
37
37
|
*
|
|
@@ -39,48 +39,48 @@ var _w=Object.defineProperty;var Tw=(n,e,i)=>e in n?_w(n,e,{enumerable:!0,config
|
|
|
39
39
|
*
|
|
40
40
|
* This source code is licensed under the MIT license found in the
|
|
41
41
|
* LICENSE file in the root directory of this source tree.
|
|
42
|
-
*/var wy;function zw(){if(wy)return Ea;wy=1;var n=Dw(),e=kh(),i=Uw();function s(t){var r="https://react.dev/errors/"+t;if(1<arguments.length){r+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)r+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+t+"; visit "+r+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function a(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function o(t){var r=t,l=t;if(t.alternate)for(;r.return;)r=r.return;else{t=r;do r=t,(r.flags&4098)!==0&&(l=r.return),t=r.return;while(t)}return r.tag===3?l:null}function u(t){if(t.tag===13){var r=t.memoizedState;if(r===null&&(t=t.alternate,t!==null&&(r=t.memoizedState)),r!==null)return r.dehydrated}return null}function f(t){if(o(t)!==t)throw Error(s(188))}function d(t){var r=t.alternate;if(!r){if(r=o(t),r===null)throw Error(s(188));return r!==t?null:t}for(var l=t,c=r;;){var h=l.return;if(h===null)break;var g=h.alternate;if(g===null){if(c=h.return,c!==null){l=c;continue}break}if(h.child===g.child){for(g=h.child;g;){if(g===l)return f(h),t;if(g===c)return f(h),r;g=g.sibling}throw Error(s(188))}if(l.return!==c.return)l=h,c=g;else{for(var S=!1,T=h.child;T;){if(T===l){S=!0,l=h,c=g;break}if(T===c){S=!0,c=h,l=g;break}T=T.sibling}if(!S){for(T=g.child;T;){if(T===l){S=!0,l=g,c=h;break}if(T===c){S=!0,c=g,l=h;break}T=T.sibling}if(!S)throw Error(s(189))}}if(l.alternate!==c)throw Error(s(190))}if(l.tag!==3)throw Error(s(188));return l.stateNode.current===l?t:r}function p(t){var r=t.tag;if(r===5||r===26||r===27||r===6)return t;for(t=t.child;t!==null;){if(r=p(t),r!==null)return r;t=t.sibling}return null}var m=Object.assign,y=Symbol.for("react.element"),b=Symbol.for("react.transitional.element"),w=Symbol.for("react.portal"),E=Symbol.for("react.fragment"),x=Symbol.for("react.strict_mode"),_=Symbol.for("react.profiler"),k=Symbol.for("react.provider"),C=Symbol.for("react.consumer"),V=Symbol.for("react.context"),I=Symbol.for("react.forward_ref"),B=Symbol.for("react.suspense"),G=Symbol.for("react.suspense_list"),J=Symbol.for("react.memo"),$=Symbol.for("react.lazy"),R=Symbol.for("react.activity"),ee=Symbol.for("react.memo_cache_sentinel"),re=Symbol.iterator;function j(t){return t===null||typeof t!="object"?null:(t=re&&t[re]||t["@@iterator"],typeof t=="function"?t:null)}var F=Symbol.for("react.client.reference");function ge(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===F?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case E:return"Fragment";case _:return"Profiler";case x:return"StrictMode";case B:return"Suspense";case G:return"SuspenseList";case R:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case w:return"Portal";case V:return(t.displayName||"Context")+".Provider";case C:return(t._context.displayName||"Context")+".Consumer";case I:var r=t.render;return t=t.displayName,t||(t=r.displayName||r.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case J:return r=t.displayName||null,r!==null?r:ge(t.type)||"Memo";case $:r=t._payload,t=t._init;try{return ge(t(r))}catch{}}return null}var me=Array.isArray,q=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Z=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ne={pending:!1,data:null,method:null,action:null},Se=[],N=-1;function X(t){return{current:t}}function Q(t){0>N||(t.current=Se[N],Se[N]=null,N--)}function W(t,r){N++,Se[N]=t.current,t.current=r}var se=X(null),ve=X(null),ue=X(null),We=X(null);function xe(t,r){switch(W(ue,r),W(ve,t),W(se,null),r.nodeType){case 9:case 11:t=(t=r.documentElement)&&(t=t.namespaceURI)?Hm(t):0;break;default:if(t=r.tagName,r=r.namespaceURI)r=Hm(r),t=qm(r,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}Q(se),W(se,t)}function gn(){Q(se),Q(ve),Q(ue)}function rs(t){t.memoizedState!==null&&W(We,t);var r=se.current,l=qm(r,t.type);r!==l&&(W(ve,t),W(se,l))}function ht(t){ve.current===t&&(Q(se),Q(ve)),We.current===t&&(Q(We),va._currentValue=ne)}var as=Object.prototype.hasOwnProperty,_r=n.unstable_scheduleCallback,Tr=n.unstable_cancelCallback,Er=n.unstable_shouldYield,rl=n.unstable_requestPaint,Ht=n.unstable_now,Pn=n.unstable_getCurrentPriorityLevel,al=n.unstable_ImmediatePriority,ll=n.unstable_UserBlockingPriority,ls=n.unstable_NormalPriority,Tc=n.unstable_LowPriority,Ar=n.unstable_IdlePriority,Nr=n.log,Ec=n.unstable_setDisableYieldValue,Ti=null,vt=null;function Et(t){if(typeof Nr=="function"&&Ec(t),vt&&typeof vt.setStrictMode=="function")try{vt.setStrictMode(Ti,t)}catch{}}var rt=Math.clz32?Math.clz32:Nc,os=Math.log,Ac=Math.LN2;function Nc(t){return t>>>=0,t===0?32:31-(os(t)/Ac|0)|0}var Ei=256,le=4194304;function dt(t){var r=t&42;if(r!==0)return r;switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function At(t,r,l){var c=t.pendingLanes;if(c===0)return 0;var h=0,g=t.suspendedLanes,S=t.pingedLanes;t=t.warmLanes;var T=c&134217727;return T!==0?(c=T&~g,c!==0?h=dt(c):(S&=T,S!==0?h=dt(S):l||(l=T&~t,l!==0&&(h=dt(l))))):(T=c&~g,T!==0?h=dt(T):S!==0?h=dt(S):l||(l=c&~t,l!==0&&(h=dt(l)))),h===0?0:r!==0&&r!==h&&(r&g)===0&&(g=h&-h,l=r&-r,g>=l||g===32&&(l&4194048)!==0)?r:h}function Cr(t,r){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&r)===0}function uS(t,r){switch(t){case 1:case 2:case 4:case 8:case 64:return r+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return r+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function xd(){var t=Ei;return Ei<<=1,(Ei&4194048)===0&&(Ei=256),t}function _d(){var t=le;return le<<=1,(le&62914560)===0&&(le=4194304),t}function Cc(t){for(var r=[],l=0;31>l;l++)r.push(t);return r}function kr(t,r){t.pendingLanes|=r,r!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function fS(t,r,l,c,h,g){var S=t.pendingLanes;t.pendingLanes=l,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=l,t.entangledLanes&=l,t.errorRecoveryDisabledLanes&=l,t.shellSuspendCounter=0;var T=t.entanglements,A=t.expirationTimes,D=t.hiddenUpdates;for(l=S&~l;0<l;){var K=31-rt(l),P=1<<K;T[K]=0,A[K]=-1;var z=D[K];if(z!==null)for(D[K]=null,K=0;K<z.length;K++){var H=z[K];H!==null&&(H.lane&=-536870913)}l&=~P}c!==0&&Td(t,c,0),g!==0&&h===0&&t.tag!==0&&(t.suspendedLanes|=g&~(S&~r))}function Td(t,r,l){t.pendingLanes|=r,t.suspendedLanes&=~r;var c=31-rt(r);t.entangledLanes|=r,t.entanglements[c]=t.entanglements[c]|1073741824|l&4194090}function Ed(t,r){var l=t.entangledLanes|=r;for(t=t.entanglements;l;){var c=31-rt(l),h=1<<c;h&r|t[c]&r&&(t[c]|=r),l&=~h}}function kc(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function Mc(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function Ad(){var t=Z.p;return t!==0?t:(t=window.event,t===void 0?32:ry(t.type))}function hS(t,r){var l=Z.p;try{return Z.p=t,r()}finally{Z.p=l}}var Fn=Math.random().toString(36).slice(2),pt="__reactFiber$"+Fn,Nt="__reactProps$"+Fn,cs="__reactContainer$"+Fn,Oc="__reactEvents$"+Fn,dS="__reactListeners$"+Fn,pS="__reactHandles$"+Fn,Nd="__reactResources$"+Fn,Mr="__reactMarker$"+Fn;function Rc(t){delete t[pt],delete t[Nt],delete t[Oc],delete t[dS],delete t[pS]}function us(t){var r=t[pt];if(r)return r;for(var l=t.parentNode;l;){if(r=l[cs]||l[pt]){if(l=r.alternate,r.child!==null||l!==null&&l.child!==null)for(t=Gm(t);t!==null;){if(l=t[pt])return l;t=Gm(t)}return r}t=l,l=t.parentNode}return null}function fs(t){if(t=t[pt]||t[cs]){var r=t.tag;if(r===5||r===6||r===13||r===26||r===27||r===3)return t}return null}function Or(t){var r=t.tag;if(r===5||r===26||r===27||r===6)return t.stateNode;throw Error(s(33))}function hs(t){var r=t[Nd];return r||(r=t[Nd]={hoistableStyles:new Map,hoistableScripts:new Map}),r}function et(t){t[Mr]=!0}var Cd=new Set,kd={};function Ai(t,r){ds(t,r),ds(t+"Capture",r)}function ds(t,r){for(kd[t]=r,t=0;t<r.length;t++)Cd.add(r[t])}var gS=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Md={},Od={};function mS(t){return as.call(Od,t)?!0:as.call(Md,t)?!1:gS.test(t)?Od[t]=!0:(Md[t]=!0,!1)}function ol(t,r,l){if(mS(r))if(l===null)t.removeAttribute(r);else{switch(typeof l){case"undefined":case"function":case"symbol":t.removeAttribute(r);return;case"boolean":var c=r.toLowerCase().slice(0,5);if(c!=="data-"&&c!=="aria-"){t.removeAttribute(r);return}}t.setAttribute(r,""+l)}}function cl(t,r,l){if(l===null)t.removeAttribute(r);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(r);return}t.setAttribute(r,""+l)}}function En(t,r,l,c){if(c===null)t.removeAttribute(l);else{switch(typeof c){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(l);return}t.setAttributeNS(r,l,""+c)}}var jc,Rd;function ps(t){if(jc===void 0)try{throw Error()}catch(l){var r=l.stack.trim().match(/\n( *(at )?)/);jc=r&&r[1]||"",Rd=-1<l.stack.indexOf(`
|
|
42
|
+
*/var wy;function Hw(){if(wy)return Ea;wy=1;var n=Bw(),e=kh(),i=zw();function s(t){var r="https://react.dev/errors/"+t;if(1<arguments.length){r+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)r+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+t+"; visit "+r+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function a(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function o(t){var r=t,l=t;if(t.alternate)for(;r.return;)r=r.return;else{t=r;do r=t,(r.flags&4098)!==0&&(l=r.return),t=r.return;while(t)}return r.tag===3?l:null}function u(t){if(t.tag===13){var r=t.memoizedState;if(r===null&&(t=t.alternate,t!==null&&(r=t.memoizedState)),r!==null)return r.dehydrated}return null}function f(t){if(o(t)!==t)throw Error(s(188))}function d(t){var r=t.alternate;if(!r){if(r=o(t),r===null)throw Error(s(188));return r!==t?null:t}for(var l=t,c=r;;){var h=l.return;if(h===null)break;var g=h.alternate;if(g===null){if(c=h.return,c!==null){l=c;continue}break}if(h.child===g.child){for(g=h.child;g;){if(g===l)return f(h),t;if(g===c)return f(h),r;g=g.sibling}throw Error(s(188))}if(l.return!==c.return)l=h,c=g;else{for(var S=!1,T=h.child;T;){if(T===l){S=!0,l=h,c=g;break}if(T===c){S=!0,c=h,l=g;break}T=T.sibling}if(!S){for(T=g.child;T;){if(T===l){S=!0,l=g,c=h;break}if(T===c){S=!0,c=g,l=h;break}T=T.sibling}if(!S)throw Error(s(189))}}if(l.alternate!==c)throw Error(s(190))}if(l.tag!==3)throw Error(s(188));return l.stateNode.current===l?t:r}function p(t){var r=t.tag;if(r===5||r===26||r===27||r===6)return t;for(t=t.child;t!==null;){if(r=p(t),r!==null)return r;t=t.sibling}return null}var m=Object.assign,y=Symbol.for("react.element"),b=Symbol.for("react.transitional.element"),w=Symbol.for("react.portal"),E=Symbol.for("react.fragment"),x=Symbol.for("react.strict_mode"),_=Symbol.for("react.profiler"),k=Symbol.for("react.provider"),C=Symbol.for("react.consumer"),V=Symbol.for("react.context"),I=Symbol.for("react.forward_ref"),B=Symbol.for("react.suspense"),G=Symbol.for("react.suspense_list"),J=Symbol.for("react.memo"),$=Symbol.for("react.lazy"),R=Symbol.for("react.activity"),ee=Symbol.for("react.memo_cache_sentinel"),re=Symbol.iterator;function j(t){return t===null||typeof t!="object"?null:(t=re&&t[re]||t["@@iterator"],typeof t=="function"?t:null)}var F=Symbol.for("react.client.reference");function ge(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===F?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case E:return"Fragment";case _:return"Profiler";case x:return"StrictMode";case B:return"Suspense";case G:return"SuspenseList";case R:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case w:return"Portal";case V:return(t.displayName||"Context")+".Provider";case C:return(t._context.displayName||"Context")+".Consumer";case I:var r=t.render;return t=t.displayName,t||(t=r.displayName||r.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case J:return r=t.displayName||null,r!==null?r:ge(t.type)||"Memo";case $:r=t._payload,t=t._init;try{return ge(t(r))}catch{}}return null}var me=Array.isArray,q=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Z=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ne={pending:!1,data:null,method:null,action:null},Se=[],N=-1;function X(t){return{current:t}}function Q(t){0>N||(t.current=Se[N],Se[N]=null,N--)}function W(t,r){N++,Se[N]=t.current,t.current=r}var se=X(null),ve=X(null),ue=X(null),We=X(null);function xe(t,r){switch(W(ue,r),W(ve,t),W(se,null),r.nodeType){case 9:case 11:t=(t=r.documentElement)&&(t=t.namespaceURI)?Hm(t):0;break;default:if(t=r.tagName,r=r.namespaceURI)r=Hm(r),t=qm(r,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}Q(se),W(se,t)}function gn(){Q(se),Q(ve),Q(ue)}function rs(t){t.memoizedState!==null&&W(We,t);var r=se.current,l=qm(r,t.type);r!==l&&(W(ve,t),W(se,l))}function ht(t){ve.current===t&&(Q(se),Q(ve)),We.current===t&&(Q(We),va._currentValue=ne)}var as=Object.prototype.hasOwnProperty,_r=n.unstable_scheduleCallback,Tr=n.unstable_cancelCallback,Er=n.unstable_shouldYield,rl=n.unstable_requestPaint,Ht=n.unstable_now,Pn=n.unstable_getCurrentPriorityLevel,al=n.unstable_ImmediatePriority,ll=n.unstable_UserBlockingPriority,ls=n.unstable_NormalPriority,Tc=n.unstable_LowPriority,Ar=n.unstable_IdlePriority,Nr=n.log,Ec=n.unstable_setDisableYieldValue,Ti=null,vt=null;function Et(t){if(typeof Nr=="function"&&Ec(t),vt&&typeof vt.setStrictMode=="function")try{vt.setStrictMode(Ti,t)}catch{}}var rt=Math.clz32?Math.clz32:Nc,os=Math.log,Ac=Math.LN2;function Nc(t){return t>>>=0,t===0?32:31-(os(t)/Ac|0)|0}var Ei=256,le=4194304;function dt(t){var r=t&42;if(r!==0)return r;switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function At(t,r,l){var c=t.pendingLanes;if(c===0)return 0;var h=0,g=t.suspendedLanes,S=t.pingedLanes;t=t.warmLanes;var T=c&134217727;return T!==0?(c=T&~g,c!==0?h=dt(c):(S&=T,S!==0?h=dt(S):l||(l=T&~t,l!==0&&(h=dt(l))))):(T=c&~g,T!==0?h=dt(T):S!==0?h=dt(S):l||(l=c&~t,l!==0&&(h=dt(l)))),h===0?0:r!==0&&r!==h&&(r&g)===0&&(g=h&-h,l=r&-r,g>=l||g===32&&(l&4194048)!==0)?r:h}function Cr(t,r){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&r)===0}function fS(t,r){switch(t){case 1:case 2:case 4:case 8:case 64:return r+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return r+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function xd(){var t=Ei;return Ei<<=1,(Ei&4194048)===0&&(Ei=256),t}function _d(){var t=le;return le<<=1,(le&62914560)===0&&(le=4194304),t}function Cc(t){for(var r=[],l=0;31>l;l++)r.push(t);return r}function kr(t,r){t.pendingLanes|=r,r!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function hS(t,r,l,c,h,g){var S=t.pendingLanes;t.pendingLanes=l,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=l,t.entangledLanes&=l,t.errorRecoveryDisabledLanes&=l,t.shellSuspendCounter=0;var T=t.entanglements,A=t.expirationTimes,D=t.hiddenUpdates;for(l=S&~l;0<l;){var K=31-rt(l),P=1<<K;T[K]=0,A[K]=-1;var z=D[K];if(z!==null)for(D[K]=null,K=0;K<z.length;K++){var H=z[K];H!==null&&(H.lane&=-536870913)}l&=~P}c!==0&&Td(t,c,0),g!==0&&h===0&&t.tag!==0&&(t.suspendedLanes|=g&~(S&~r))}function Td(t,r,l){t.pendingLanes|=r,t.suspendedLanes&=~r;var c=31-rt(r);t.entangledLanes|=r,t.entanglements[c]=t.entanglements[c]|1073741824|l&4194090}function Ed(t,r){var l=t.entangledLanes|=r;for(t=t.entanglements;l;){var c=31-rt(l),h=1<<c;h&r|t[c]&r&&(t[c]|=r),l&=~h}}function kc(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function Mc(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function Ad(){var t=Z.p;return t!==0?t:(t=window.event,t===void 0?32:ry(t.type))}function dS(t,r){var l=Z.p;try{return Z.p=t,r()}finally{Z.p=l}}var Fn=Math.random().toString(36).slice(2),pt="__reactFiber$"+Fn,Nt="__reactProps$"+Fn,cs="__reactContainer$"+Fn,Oc="__reactEvents$"+Fn,pS="__reactListeners$"+Fn,gS="__reactHandles$"+Fn,Nd="__reactResources$"+Fn,Mr="__reactMarker$"+Fn;function Rc(t){delete t[pt],delete t[Nt],delete t[Oc],delete t[pS],delete t[gS]}function us(t){var r=t[pt];if(r)return r;for(var l=t.parentNode;l;){if(r=l[cs]||l[pt]){if(l=r.alternate,r.child!==null||l!==null&&l.child!==null)for(t=Gm(t);t!==null;){if(l=t[pt])return l;t=Gm(t)}return r}t=l,l=t.parentNode}return null}function fs(t){if(t=t[pt]||t[cs]){var r=t.tag;if(r===5||r===6||r===13||r===26||r===27||r===3)return t}return null}function Or(t){var r=t.tag;if(r===5||r===26||r===27||r===6)return t.stateNode;throw Error(s(33))}function hs(t){var r=t[Nd];return r||(r=t[Nd]={hoistableStyles:new Map,hoistableScripts:new Map}),r}function et(t){t[Mr]=!0}var Cd=new Set,kd={};function Ai(t,r){ds(t,r),ds(t+"Capture",r)}function ds(t,r){for(kd[t]=r,t=0;t<r.length;t++)Cd.add(r[t])}var mS=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Md={},Od={};function yS(t){return as.call(Od,t)?!0:as.call(Md,t)?!1:mS.test(t)?Od[t]=!0:(Md[t]=!0,!1)}function ol(t,r,l){if(yS(r))if(l===null)t.removeAttribute(r);else{switch(typeof l){case"undefined":case"function":case"symbol":t.removeAttribute(r);return;case"boolean":var c=r.toLowerCase().slice(0,5);if(c!=="data-"&&c!=="aria-"){t.removeAttribute(r);return}}t.setAttribute(r,""+l)}}function cl(t,r,l){if(l===null)t.removeAttribute(r);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(r);return}t.setAttribute(r,""+l)}}function En(t,r,l,c){if(c===null)t.removeAttribute(l);else{switch(typeof c){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(l);return}t.setAttributeNS(r,l,""+c)}}var jc,Rd;function ps(t){if(jc===void 0)try{throw Error()}catch(l){var r=l.stack.trim().match(/\n( *(at )?)/);jc=r&&r[1]||"",Rd=-1<l.stack.indexOf(`
|
|
43
43
|
at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
44
44
|
`+jc+t+Rd}var Lc=!1;function Dc(t,r){if(!t||Lc)return"";Lc=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var c={DetermineComponentFrameRoot:function(){try{if(r){var P=function(){throw Error()};if(Object.defineProperty(P.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(P,[])}catch(H){var z=H}Reflect.construct(t,[],P)}else{try{P.call()}catch(H){z=H}t.call(P.prototype)}}else{try{throw Error()}catch(H){z=H}(P=t())&&typeof P.catch=="function"&&P.catch(function(){})}}catch(H){if(H&&z&&typeof H.stack=="string")return[H.stack,z.stack]}return[null,null]}};c.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var h=Object.getOwnPropertyDescriptor(c.DetermineComponentFrameRoot,"name");h&&h.configurable&&Object.defineProperty(c.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var g=c.DetermineComponentFrameRoot(),S=g[0],T=g[1];if(S&&T){var A=S.split(`
|
|
45
45
|
`),D=T.split(`
|
|
46
46
|
`);for(h=c=0;c<A.length&&!A[c].includes("DetermineComponentFrameRoot");)c++;for(;h<D.length&&!D[h].includes("DetermineComponentFrameRoot");)h++;if(c===A.length||h===D.length)for(c=A.length-1,h=D.length-1;1<=c&&0<=h&&A[c]!==D[h];)h--;for(;1<=c&&0<=h;c--,h--)if(A[c]!==D[h]){if(c!==1||h!==1)do if(c--,h--,0>h||A[c]!==D[h]){var K=`
|
|
47
|
-
`+A[c].replace(" at new "," at ");return t.displayName&&K.includes("<anonymous>")&&(K=K.replace("<anonymous>",t.displayName)),K}while(1<=c&&0<=h);break}}}finally{Lc=!1,Error.prepareStackTrace=l}return(l=t?t.displayName||t.name:"")?ps(l):""}function
|
|
47
|
+
`+A[c].replace(" at new "," at ");return t.displayName&&K.includes("<anonymous>")&&(K=K.replace("<anonymous>",t.displayName)),K}while(1<=c&&0<=h);break}}}finally{Lc=!1,Error.prepareStackTrace=l}return(l=t?t.displayName||t.name:"")?ps(l):""}function bS(t){switch(t.tag){case 26:case 27:case 5:return ps(t.type);case 16:return ps("Lazy");case 13:return ps("Suspense");case 19:return ps("SuspenseList");case 0:case 15:return Dc(t.type,!1);case 11:return Dc(t.type.render,!1);case 1:return Dc(t.type,!0);case 31:return ps("Activity");default:return""}}function jd(t){try{var r="";do r+=bS(t),t=t.return;while(t);return r}catch(l){return`
|
|
48
48
|
Error generating stack: `+l.message+`
|
|
49
|
-
`+l.stack}}function Pt(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function Ld(t){var r=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(r==="checkbox"||r==="radio")}function bS(t){var r=Ld(t)?"checked":"value",l=Object.getOwnPropertyDescriptor(t.constructor.prototype,r),c=""+t[r];if(!t.hasOwnProperty(r)&&typeof l<"u"&&typeof l.get=="function"&&typeof l.set=="function"){var h=l.get,g=l.set;return Object.defineProperty(t,r,{configurable:!0,get:function(){return h.call(this)},set:function(S){c=""+S,g.call(this,S)}}),Object.defineProperty(t,r,{enumerable:l.enumerable}),{getValue:function(){return c},setValue:function(S){c=""+S},stopTracking:function(){t._valueTracker=null,delete t[r]}}}}function ul(t){t._valueTracker||(t._valueTracker=bS(t))}function Dd(t){if(!t)return!1;var r=t._valueTracker;if(!r)return!0;var l=r.getValue(),c="";return t&&(c=Ld(t)?t.checked?"true":"false":t.value),t=c,t!==l?(r.setValue(t),!0):!1}function fl(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var vS=/[\n"\\]/g;function Ft(t){return t.replace(vS,function(r){return"\\"+r.charCodeAt(0).toString(16)+" "})}function Bc(t,r,l,c,h,g,S,T){t.name="",S!=null&&typeof S!="function"&&typeof S!="symbol"&&typeof S!="boolean"?t.type=S:t.removeAttribute("type"),r!=null?S==="number"?(r===0&&t.value===""||t.value!=r)&&(t.value=""+Pt(r)):t.value!==""+Pt(r)&&(t.value=""+Pt(r)):S!=="submit"&&S!=="reset"||t.removeAttribute("value"),r!=null?Uc(t,S,Pt(r)):l!=null?Uc(t,S,Pt(l)):c!=null&&t.removeAttribute("value"),h==null&&g!=null&&(t.defaultChecked=!!g),h!=null&&(t.checked=h&&typeof h!="function"&&typeof h!="symbol"),T!=null&&typeof T!="function"&&typeof T!="symbol"&&typeof T!="boolean"?t.name=""+Pt(T):t.removeAttribute("name")}function Bd(t,r,l,c,h,g,S,T){if(g!=null&&typeof g!="function"&&typeof g!="symbol"&&typeof g!="boolean"&&(t.type=g),r!=null||l!=null){if(!(g!=="submit"&&g!=="reset"||r!=null))return;l=l!=null?""+Pt(l):"",r=r!=null?""+Pt(r):l,T||r===t.value||(t.value=r),t.defaultValue=r}c=c??h,c=typeof c!="function"&&typeof c!="symbol"&&!!c,t.checked=T?t.checked:!!c,t.defaultChecked=!!c,S!=null&&typeof S!="function"&&typeof S!="symbol"&&typeof S!="boolean"&&(t.name=S)}function Uc(t,r,l){r==="number"&&fl(t.ownerDocument)===t||t.defaultValue===""+l||(t.defaultValue=""+l)}function gs(t,r,l,c){if(t=t.options,r){r={};for(var h=0;h<l.length;h++)r["$"+l[h]]=!0;for(l=0;l<t.length;l++)h=r.hasOwnProperty("$"+t[l].value),t[l].selected!==h&&(t[l].selected=h),h&&c&&(t[l].defaultSelected=!0)}else{for(l=""+Pt(l),r=null,h=0;h<t.length;h++){if(t[h].value===l){t[h].selected=!0,c&&(t[h].defaultSelected=!0);return}r!==null||t[h].disabled||(r=t[h])}r!==null&&(r.selected=!0)}}function Ud(t,r,l){if(r!=null&&(r=""+Pt(r),r!==t.value&&(t.value=r),l==null)){t.defaultValue!==r&&(t.defaultValue=r);return}t.defaultValue=l!=null?""+Pt(l):""}function zd(t,r,l,c){if(r==null){if(c!=null){if(l!=null)throw Error(s(92));if(me(c)){if(1<c.length)throw Error(s(93));c=c[0]}l=c}l==null&&(l=""),r=l}l=Pt(r),t.defaultValue=l,c=t.textContent,c===l&&c!==""&&c!==null&&(t.value=c)}function ms(t,r){if(r){var l=t.firstChild;if(l&&l===t.lastChild&&l.nodeType===3){l.nodeValue=r;return}}t.textContent=r}var SS=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Hd(t,r,l){var c=r.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?c?t.setProperty(r,""):r==="float"?t.cssFloat="":t[r]="":c?t.setProperty(r,l):typeof l!="number"||l===0||SS.has(r)?r==="float"?t.cssFloat=l:t[r]=(""+l).trim():t[r]=l+"px"}function qd(t,r,l){if(r!=null&&typeof r!="object")throw Error(s(62));if(t=t.style,l!=null){for(var c in l)!l.hasOwnProperty(c)||r!=null&&r.hasOwnProperty(c)||(c.indexOf("--")===0?t.setProperty(c,""):c==="float"?t.cssFloat="":t[c]="");for(var h in r)c=r[h],r.hasOwnProperty(h)&&l[h]!==c&&Hd(t,h,c)}else for(var g in r)r.hasOwnProperty(g)&&Hd(t,g,r[g])}function zc(t){if(t.indexOf("-")===-1)return!1;switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var wS=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),xS=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function hl(t){return xS.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}var Hc=null;function qc(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var ys=null,bs=null;function $d(t){var r=fs(t);if(r&&(t=r.stateNode)){var l=t[Nt]||null;e:switch(t=r.stateNode,r.type){case"input":if(Bc(t,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),r=l.name,l.type==="radio"&&r!=null){for(l=t;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Ft(""+r)+'"][type="radio"]'),r=0;r<l.length;r++){var c=l[r];if(c!==t&&c.form===t.form){var h=c[Nt]||null;if(!h)throw Error(s(90));Bc(c,h.value,h.defaultValue,h.defaultValue,h.checked,h.defaultChecked,h.type,h.name)}}for(r=0;r<l.length;r++)c=l[r],c.form===t.form&&Dd(c)}break e;case"textarea":Ud(t,l.value,l.defaultValue);break e;case"select":r=l.value,r!=null&&gs(t,!!l.multiple,r,!1)}}}var $c=!1;function Id(t,r,l){if($c)return t(r,l);$c=!0;try{var c=t(r);return c}finally{if($c=!1,(ys!==null||bs!==null)&&(Zl(),ys&&(r=ys,t=bs,bs=ys=null,$d(r),t)))for(r=0;r<t.length;r++)$d(t[r])}}function Rr(t,r){var l=t.stateNode;if(l===null)return null;var c=l[Nt]||null;if(c===null)return null;l=c[r];e:switch(r){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(c=!c.disabled)||(t=t.type,c=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!c;break e;default:t=!1}if(t)return null;if(l&&typeof l!="function")throw Error(s(231,r,typeof l));return l}var An=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ic=!1;if(An)try{var jr={};Object.defineProperty(jr,"passive",{get:function(){Ic=!0}}),window.addEventListener("test",jr,jr),window.removeEventListener("test",jr,jr)}catch{Ic=!1}var Qn=null,Vc=null,dl=null;function Vd(){if(dl)return dl;var t,r=Vc,l=r.length,c,h="value"in Qn?Qn.value:Qn.textContent,g=h.length;for(t=0;t<l&&r[t]===h[t];t++);var S=l-t;for(c=1;c<=S&&r[l-c]===h[g-c];c++);return dl=h.slice(t,1<c?1-c:void 0)}function pl(t){var r=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&r===13&&(t=13)):t=r,t===10&&(t=13),32<=t||t===13?t:0}function gl(){return!0}function Gd(){return!1}function Ct(t){function r(l,c,h,g,S){this._reactName=l,this._targetInst=h,this.type=c,this.nativeEvent=g,this.target=S,this.currentTarget=null;for(var T in t)t.hasOwnProperty(T)&&(l=t[T],this[T]=l?l(g):g[T]);return this.isDefaultPrevented=(g.defaultPrevented!=null?g.defaultPrevented:g.returnValue===!1)?gl:Gd,this.isPropagationStopped=Gd,this}return m(r.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=gl)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=gl)},persist:function(){},isPersistent:gl}),r}var Ni={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ml=Ct(Ni),Lr=m({},Ni,{view:0,detail:0}),_S=Ct(Lr),Gc,Kc,Dr,yl=m({},Lr,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Xc,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Dr&&(Dr&&t.type==="mousemove"?(Gc=t.screenX-Dr.screenX,Kc=t.screenY-Dr.screenY):Kc=Gc=0,Dr=t),Gc)},movementY:function(t){return"movementY"in t?t.movementY:Kc}}),Kd=Ct(yl),TS=m({},yl,{dataTransfer:0}),ES=Ct(TS),AS=m({},Lr,{relatedTarget:0}),Yc=Ct(AS),NS=m({},Ni,{animationName:0,elapsedTime:0,pseudoElement:0}),CS=Ct(NS),kS=m({},Ni,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),MS=Ct(kS),OS=m({},Ni,{data:0}),Yd=Ct(OS),RS={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},jS={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},LS={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function DS(t){var r=this.nativeEvent;return r.getModifierState?r.getModifierState(t):(t=LS[t])?!!r[t]:!1}function Xc(){return DS}var BS=m({},Lr,{key:function(t){if(t.key){var r=RS[t.key]||t.key;if(r!=="Unidentified")return r}return t.type==="keypress"?(t=pl(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?jS[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Xc,charCode:function(t){return t.type==="keypress"?pl(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?pl(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),US=Ct(BS),zS=m({},yl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Xd=Ct(zS),HS=m({},Lr,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Xc}),qS=Ct(HS),$S=m({},Ni,{propertyName:0,elapsedTime:0,pseudoElement:0}),IS=Ct($S),VS=m({},yl,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),GS=Ct(VS),KS=m({},Ni,{newState:0,oldState:0}),YS=Ct(KS),XS=[9,13,27,32],Pc=An&&"CompositionEvent"in window,Br=null;An&&"documentMode"in document&&(Br=document.documentMode);var PS=An&&"TextEvent"in window&&!Br,Pd=An&&(!Pc||Br&&8<Br&&11>=Br),Fd=" ",Qd=!1;function Zd(t,r){switch(t){case"keyup":return XS.indexOf(r.keyCode)!==-1;case"keydown":return r.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Jd(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var vs=!1;function FS(t,r){switch(t){case"compositionend":return Jd(r);case"keypress":return r.which!==32?null:(Qd=!0,Fd);case"textInput":return t=r.data,t===Fd&&Qd?null:t;default:return null}}function QS(t,r){if(vs)return t==="compositionend"||!Pc&&Zd(t,r)?(t=Vd(),dl=Vc=Qn=null,vs=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(r.ctrlKey||r.altKey||r.metaKey)||r.ctrlKey&&r.altKey){if(r.char&&1<r.char.length)return r.char;if(r.which)return String.fromCharCode(r.which)}return null;case"compositionend":return Pd&&r.locale!=="ko"?null:r.data;default:return null}}var ZS={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Wd(t){var r=t&&t.nodeName&&t.nodeName.toLowerCase();return r==="input"?!!ZS[t.type]:r==="textarea"}function ep(t,r,l,c){ys?bs?bs.push(c):bs=[c]:ys=c,r=io(r,"onChange"),0<r.length&&(l=new ml("onChange","change",null,l,c),t.push({event:l,listeners:r}))}var Ur=null,zr=null;function JS(t){Lm(t,0)}function bl(t){var r=Or(t);if(Dd(r))return t}function tp(t,r){if(t==="change")return r}var np=!1;if(An){var Fc;if(An){var Qc="oninput"in document;if(!Qc){var ip=document.createElement("div");ip.setAttribute("oninput","return;"),Qc=typeof ip.oninput=="function"}Fc=Qc}else Fc=!1;np=Fc&&(!document.documentMode||9<document.documentMode)}function sp(){Ur&&(Ur.detachEvent("onpropertychange",rp),zr=Ur=null)}function rp(t){if(t.propertyName==="value"&&bl(zr)){var r=[];ep(r,zr,t,qc(t)),Id(JS,r)}}function WS(t,r,l){t==="focusin"?(sp(),Ur=r,zr=l,Ur.attachEvent("onpropertychange",rp)):t==="focusout"&&sp()}function e1(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return bl(zr)}function t1(t,r){if(t==="click")return bl(r)}function n1(t,r){if(t==="input"||t==="change")return bl(r)}function i1(t,r){return t===r&&(t!==0||1/t===1/r)||t!==t&&r!==r}var qt=typeof Object.is=="function"?Object.is:i1;function Hr(t,r){if(qt(t,r))return!0;if(typeof t!="object"||t===null||typeof r!="object"||r===null)return!1;var l=Object.keys(t),c=Object.keys(r);if(l.length!==c.length)return!1;for(c=0;c<l.length;c++){var h=l[c];if(!as.call(r,h)||!qt(t[h],r[h]))return!1}return!0}function ap(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function lp(t,r){var l=ap(t);t=0;for(var c;l;){if(l.nodeType===3){if(c=t+l.textContent.length,t<=r&&c>=r)return{node:l,offset:r-t};t=c}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=ap(l)}}function op(t,r){return t&&r?t===r?!0:t&&t.nodeType===3?!1:r&&r.nodeType===3?op(t,r.parentNode):"contains"in t?t.contains(r):t.compareDocumentPosition?!!(t.compareDocumentPosition(r)&16):!1:!1}function cp(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var r=fl(t.document);r instanceof t.HTMLIFrameElement;){try{var l=typeof r.contentWindow.location.href=="string"}catch{l=!1}if(l)t=r.contentWindow;else break;r=fl(t.document)}return r}function Zc(t){var r=t&&t.nodeName&&t.nodeName.toLowerCase();return r&&(r==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||r==="textarea"||t.contentEditable==="true")}var s1=An&&"documentMode"in document&&11>=document.documentMode,Ss=null,Jc=null,qr=null,Wc=!1;function up(t,r,l){var c=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Wc||Ss==null||Ss!==fl(c)||(c=Ss,"selectionStart"in c&&Zc(c)?c={start:c.selectionStart,end:c.selectionEnd}:(c=(c.ownerDocument&&c.ownerDocument.defaultView||window).getSelection(),c={anchorNode:c.anchorNode,anchorOffset:c.anchorOffset,focusNode:c.focusNode,focusOffset:c.focusOffset}),qr&&Hr(qr,c)||(qr=c,c=io(Jc,"onSelect"),0<c.length&&(r=new ml("onSelect","select",null,r,l),t.push({event:r,listeners:c}),r.target=Ss)))}function Ci(t,r){var l={};return l[t.toLowerCase()]=r.toLowerCase(),l["Webkit"+t]="webkit"+r,l["Moz"+t]="moz"+r,l}var ws={animationend:Ci("Animation","AnimationEnd"),animationiteration:Ci("Animation","AnimationIteration"),animationstart:Ci("Animation","AnimationStart"),transitionrun:Ci("Transition","TransitionRun"),transitionstart:Ci("Transition","TransitionStart"),transitioncancel:Ci("Transition","TransitionCancel"),transitionend:Ci("Transition","TransitionEnd")},eu={},fp={};An&&(fp=document.createElement("div").style,"AnimationEvent"in window||(delete ws.animationend.animation,delete ws.animationiteration.animation,delete ws.animationstart.animation),"TransitionEvent"in window||delete ws.transitionend.transition);function ki(t){if(eu[t])return eu[t];if(!ws[t])return t;var r=ws[t],l;for(l in r)if(r.hasOwnProperty(l)&&l in fp)return eu[t]=r[l];return t}var hp=ki("animationend"),dp=ki("animationiteration"),pp=ki("animationstart"),r1=ki("transitionrun"),a1=ki("transitionstart"),l1=ki("transitioncancel"),gp=ki("transitionend"),mp=new Map,tu="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");tu.push("scrollEnd");function cn(t,r){mp.set(t,r),Ai(r,[t])}var yp=new WeakMap;function Qt(t,r){if(typeof t=="object"&&t!==null){var l=yp.get(t);return l!==void 0?l:(r={value:t,source:r,stack:jd(r)},yp.set(t,r),r)}return{value:t,source:r,stack:jd(r)}}var Zt=[],xs=0,nu=0;function vl(){for(var t=xs,r=nu=xs=0;r<t;){var l=Zt[r];Zt[r++]=null;var c=Zt[r];Zt[r++]=null;var h=Zt[r];Zt[r++]=null;var g=Zt[r];if(Zt[r++]=null,c!==null&&h!==null){var S=c.pending;S===null?h.next=h:(h.next=S.next,S.next=h),c.pending=h}g!==0&&bp(l,h,g)}}function Sl(t,r,l,c){Zt[xs++]=t,Zt[xs++]=r,Zt[xs++]=l,Zt[xs++]=c,nu|=c,t.lanes|=c,t=t.alternate,t!==null&&(t.lanes|=c)}function iu(t,r,l,c){return Sl(t,r,l,c),wl(t)}function _s(t,r){return Sl(t,null,null,r),wl(t)}function bp(t,r,l){t.lanes|=l;var c=t.alternate;c!==null&&(c.lanes|=l);for(var h=!1,g=t.return;g!==null;)g.childLanes|=l,c=g.alternate,c!==null&&(c.childLanes|=l),g.tag===22&&(t=g.stateNode,t===null||t._visibility&1||(h=!0)),t=g,g=g.return;return t.tag===3?(g=t.stateNode,h&&r!==null&&(h=31-rt(l),t=g.hiddenUpdates,c=t[h],c===null?t[h]=[r]:c.push(r),r.lane=l|536870912),g):null}function wl(t){if(50<fa)throw fa=0,uf=null,Error(s(185));for(var r=t.return;r!==null;)t=r,r=t.return;return t.tag===3?t.stateNode:null}var Ts={};function o1(t,r,l,c){this.tag=t,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=r,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=c,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function $t(t,r,l,c){return new o1(t,r,l,c)}function su(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Nn(t,r){var l=t.alternate;return l===null?(l=$t(t.tag,r,t.key,t.mode),l.elementType=t.elementType,l.type=t.type,l.stateNode=t.stateNode,l.alternate=t,t.alternate=l):(l.pendingProps=r,l.type=t.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=t.flags&65011712,l.childLanes=t.childLanes,l.lanes=t.lanes,l.child=t.child,l.memoizedProps=t.memoizedProps,l.memoizedState=t.memoizedState,l.updateQueue=t.updateQueue,r=t.dependencies,l.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext},l.sibling=t.sibling,l.index=t.index,l.ref=t.ref,l.refCleanup=t.refCleanup,l}function vp(t,r){t.flags&=65011714;var l=t.alternate;return l===null?(t.childLanes=0,t.lanes=r,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=l.childLanes,t.lanes=l.lanes,t.child=l.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=l.memoizedProps,t.memoizedState=l.memoizedState,t.updateQueue=l.updateQueue,t.type=l.type,r=l.dependencies,t.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext}),t}function xl(t,r,l,c,h,g){var S=0;if(c=t,typeof t=="function")su(t)&&(S=1);else if(typeof t=="string")S=uw(t,l,se.current)?26:t==="html"||t==="head"||t==="body"?27:5;else e:switch(t){case R:return t=$t(31,l,r,h),t.elementType=R,t.lanes=g,t;case E:return Mi(l.children,h,g,r);case x:S=8,h|=24;break;case _:return t=$t(12,l,r,h|2),t.elementType=_,t.lanes=g,t;case B:return t=$t(13,l,r,h),t.elementType=B,t.lanes=g,t;case G:return t=$t(19,l,r,h),t.elementType=G,t.lanes=g,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case k:case V:S=10;break e;case C:S=9;break e;case I:S=11;break e;case J:S=14;break e;case $:S=16,c=null;break e}S=29,l=Error(s(130,t===null?"null":typeof t,"")),c=null}return r=$t(S,l,r,h),r.elementType=t,r.type=c,r.lanes=g,r}function Mi(t,r,l,c){return t=$t(7,t,c,r),t.lanes=l,t}function ru(t,r,l){return t=$t(6,t,null,r),t.lanes=l,t}function au(t,r,l){return r=$t(4,t.children!==null?t.children:[],t.key,r),r.lanes=l,r.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},r}var Es=[],As=0,_l=null,Tl=0,Jt=[],Wt=0,Oi=null,Cn=1,kn="";function Ri(t,r){Es[As++]=Tl,Es[As++]=_l,_l=t,Tl=r}function Sp(t,r,l){Jt[Wt++]=Cn,Jt[Wt++]=kn,Jt[Wt++]=Oi,Oi=t;var c=Cn;t=kn;var h=32-rt(c)-1;c&=~(1<<h),l+=1;var g=32-rt(r)+h;if(30<g){var S=h-h%5;g=(c&(1<<S)-1).toString(32),c>>=S,h-=S,Cn=1<<32-rt(r)+h|l<<h|c,kn=g+t}else Cn=1<<g|l<<h|c,kn=t}function lu(t){t.return!==null&&(Ri(t,1),Sp(t,1,0))}function ou(t){for(;t===_l;)_l=Es[--As],Es[As]=null,Tl=Es[--As],Es[As]=null;for(;t===Oi;)Oi=Jt[--Wt],Jt[Wt]=null,kn=Jt[--Wt],Jt[Wt]=null,Cn=Jt[--Wt],Jt[Wt]=null}var St=null,$e=null,Te=!1,ji=null,mn=!1,cu=Error(s(519));function Li(t){var r=Error(s(418,""));throw Vr(Qt(r,t)),cu}function wp(t){var r=t.stateNode,l=t.type,c=t.memoizedProps;switch(r[pt]=t,r[Nt]=c,l){case"dialog":be("cancel",r),be("close",r);break;case"iframe":case"object":case"embed":be("load",r);break;case"video":case"audio":for(l=0;l<da.length;l++)be(da[l],r);break;case"source":be("error",r);break;case"img":case"image":case"link":be("error",r),be("load",r);break;case"details":be("toggle",r);break;case"input":be("invalid",r),Bd(r,c.value,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name,!0),ul(r);break;case"select":be("invalid",r);break;case"textarea":be("invalid",r),zd(r,c.value,c.defaultValue,c.children),ul(r)}l=c.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||r.textContent===""+l||c.suppressHydrationWarning===!0||zm(r.textContent,l)?(c.popover!=null&&(be("beforetoggle",r),be("toggle",r)),c.onScroll!=null&&be("scroll",r),c.onScrollEnd!=null&&be("scrollend",r),c.onClick!=null&&(r.onclick=so),r=!0):r=!1,r||Li(t)}function xp(t){for(St=t.return;St;)switch(St.tag){case 5:case 13:mn=!1;return;case 27:case 3:mn=!0;return;default:St=St.return}}function $r(t){if(t!==St)return!1;if(!Te)return xp(t),Te=!0,!1;var r=t.tag,l;if((l=r!==3&&r!==27)&&((l=r===5)&&(l=t.type,l=!(l!=="form"&&l!=="button")||Af(t.type,t.memoizedProps)),l=!l),l&&$e&&Li(t),xp(t),r===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(s(317));e:{for(t=t.nextSibling,r=0;t;){if(t.nodeType===8)if(l=t.data,l==="/$"){if(r===0){$e=fn(t.nextSibling);break e}r--}else l!=="$"&&l!=="$!"&&l!=="$?"||r++;t=t.nextSibling}$e=null}}else r===27?(r=$e,hi(t.type)?(t=Mf,Mf=null,$e=t):$e=r):$e=St?fn(t.stateNode.nextSibling):null;return!0}function Ir(){$e=St=null,Te=!1}function _p(){var t=ji;return t!==null&&(Ot===null?Ot=t:Ot.push.apply(Ot,t),ji=null),t}function Vr(t){ji===null?ji=[t]:ji.push(t)}var uu=X(null),Di=null,Mn=null;function Zn(t,r,l){W(uu,r._currentValue),r._currentValue=l}function On(t){t._currentValue=uu.current,Q(uu)}function fu(t,r,l){for(;t!==null;){var c=t.alternate;if((t.childLanes&r)!==r?(t.childLanes|=r,c!==null&&(c.childLanes|=r)):c!==null&&(c.childLanes&r)!==r&&(c.childLanes|=r),t===l)break;t=t.return}}function hu(t,r,l,c){var h=t.child;for(h!==null&&(h.return=t);h!==null;){var g=h.dependencies;if(g!==null){var S=h.child;g=g.firstContext;e:for(;g!==null;){var T=g;g=h;for(var A=0;A<r.length;A++)if(T.context===r[A]){g.lanes|=l,T=g.alternate,T!==null&&(T.lanes|=l),fu(g.return,l,t),c||(S=null);break e}g=T.next}}else if(h.tag===18){if(S=h.return,S===null)throw Error(s(341));S.lanes|=l,g=S.alternate,g!==null&&(g.lanes|=l),fu(S,l,t),S=null}else S=h.child;if(S!==null)S.return=h;else for(S=h;S!==null;){if(S===t){S=null;break}if(h=S.sibling,h!==null){h.return=S.return,S=h;break}S=S.return}h=S}}function Gr(t,r,l,c){t=null;for(var h=r,g=!1;h!==null;){if(!g){if((h.flags&524288)!==0)g=!0;else if((h.flags&262144)!==0)break}if(h.tag===10){var S=h.alternate;if(S===null)throw Error(s(387));if(S=S.memoizedProps,S!==null){var T=h.type;qt(h.pendingProps.value,S.value)||(t!==null?t.push(T):t=[T])}}else if(h===We.current){if(S=h.alternate,S===null)throw Error(s(387));S.memoizedState.memoizedState!==h.memoizedState.memoizedState&&(t!==null?t.push(va):t=[va])}h=h.return}t!==null&&hu(r,t,l,c),r.flags|=262144}function El(t){for(t=t.firstContext;t!==null;){if(!qt(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function Bi(t){Di=t,Mn=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function gt(t){return Tp(Di,t)}function Al(t,r){return Di===null&&Bi(t),Tp(t,r)}function Tp(t,r){var l=r._currentValue;if(r={context:r,memoizedValue:l,next:null},Mn===null){if(t===null)throw Error(s(308));Mn=r,t.dependencies={lanes:0,firstContext:r},t.flags|=524288}else Mn=Mn.next=r;return l}var c1=typeof AbortController<"u"?AbortController:function(){var t=[],r=this.signal={aborted:!1,addEventListener:function(l,c){t.push(c)}};this.abort=function(){r.aborted=!0,t.forEach(function(l){return l()})}},u1=n.unstable_scheduleCallback,f1=n.unstable_NormalPriority,Qe={$$typeof:V,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function du(){return{controller:new c1,data:new Map,refCount:0}}function Kr(t){t.refCount--,t.refCount===0&&u1(f1,function(){t.controller.abort()})}var Yr=null,pu=0,Ns=0,Cs=null;function h1(t,r){if(Yr===null){var l=Yr=[];pu=0,Ns=yf(),Cs={status:"pending",value:void 0,then:function(c){l.push(c)}}}return pu++,r.then(Ep,Ep),r}function Ep(){if(--pu===0&&Yr!==null){Cs!==null&&(Cs.status="fulfilled");var t=Yr;Yr=null,Ns=0,Cs=null;for(var r=0;r<t.length;r++)(0,t[r])()}}function d1(t,r){var l=[],c={status:"pending",value:null,reason:null,then:function(h){l.push(h)}};return t.then(function(){c.status="fulfilled",c.value=r;for(var h=0;h<l.length;h++)(0,l[h])(r)},function(h){for(c.status="rejected",c.reason=h,h=0;h<l.length;h++)(0,l[h])(void 0)}),c}var Ap=q.S;q.S=function(t,r){typeof r=="object"&&r!==null&&typeof r.then=="function"&&h1(t,r),Ap!==null&&Ap(t,r)};var Ui=X(null);function gu(){var t=Ui.current;return t!==null?t:je.pooledCache}function Nl(t,r){r===null?W(Ui,Ui.current):W(Ui,r.pool)}function Np(){var t=gu();return t===null?null:{parent:Qe._currentValue,pool:t}}var Xr=Error(s(460)),Cp=Error(s(474)),Cl=Error(s(542)),mu={then:function(){}};function kp(t){return t=t.status,t==="fulfilled"||t==="rejected"}function kl(){}function Mp(t,r,l){switch(l=t[l],l===void 0?t.push(r):l!==r&&(r.then(kl,kl),r=l),r.status){case"fulfilled":return r.value;case"rejected":throw t=r.reason,Rp(t),t;default:if(typeof r.status=="string")r.then(kl,kl);else{if(t=je,t!==null&&100<t.shellSuspendCounter)throw Error(s(482));t=r,t.status="pending",t.then(function(c){if(r.status==="pending"){var h=r;h.status="fulfilled",h.value=c}},function(c){if(r.status==="pending"){var h=r;h.status="rejected",h.reason=c}})}switch(r.status){case"fulfilled":return r.value;case"rejected":throw t=r.reason,Rp(t),t}throw Pr=r,Xr}}var Pr=null;function Op(){if(Pr===null)throw Error(s(459));var t=Pr;return Pr=null,t}function Rp(t){if(t===Xr||t===Cl)throw Error(s(483))}var Jn=!1;function yu(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function bu(t,r){t=t.updateQueue,r.updateQueue===t&&(r.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function Wn(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function ei(t,r,l){var c=t.updateQueue;if(c===null)return null;if(c=c.shared,(Ee&2)!==0){var h=c.pending;return h===null?r.next=r:(r.next=h.next,h.next=r),c.pending=r,r=wl(t),bp(t,null,l),r}return Sl(t,c,r,l),wl(t)}function Fr(t,r,l){if(r=r.updateQueue,r!==null&&(r=r.shared,(l&4194048)!==0)){var c=r.lanes;c&=t.pendingLanes,l|=c,r.lanes=l,Ed(t,l)}}function vu(t,r){var l=t.updateQueue,c=t.alternate;if(c!==null&&(c=c.updateQueue,l===c)){var h=null,g=null;if(l=l.firstBaseUpdate,l!==null){do{var S={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};g===null?h=g=S:g=g.next=S,l=l.next}while(l!==null);g===null?h=g=r:g=g.next=r}else h=g=r;l={baseState:c.baseState,firstBaseUpdate:h,lastBaseUpdate:g,shared:c.shared,callbacks:c.callbacks},t.updateQueue=l;return}t=l.lastBaseUpdate,t===null?l.firstBaseUpdate=r:t.next=r,l.lastBaseUpdate=r}var Su=!1;function Qr(){if(Su){var t=Cs;if(t!==null)throw t}}function Zr(t,r,l,c){Su=!1;var h=t.updateQueue;Jn=!1;var g=h.firstBaseUpdate,S=h.lastBaseUpdate,T=h.shared.pending;if(T!==null){h.shared.pending=null;var A=T,D=A.next;A.next=null,S===null?g=D:S.next=D,S=A;var K=t.alternate;K!==null&&(K=K.updateQueue,T=K.lastBaseUpdate,T!==S&&(T===null?K.firstBaseUpdate=D:T.next=D,K.lastBaseUpdate=A))}if(g!==null){var P=h.baseState;S=0,K=D=A=null,T=g;do{var z=T.lane&-536870913,H=z!==T.lane;if(H?(we&z)===z:(c&z)===z){z!==0&&z===Ns&&(Su=!0),K!==null&&(K=K.next={lane:0,tag:T.tag,payload:T.payload,callback:null,next:null});e:{var ce=t,ae=T;z=r;var Me=l;switch(ae.tag){case 1:if(ce=ae.payload,typeof ce=="function"){P=ce.call(Me,P,z);break e}P=ce;break e;case 3:ce.flags=ce.flags&-65537|128;case 0:if(ce=ae.payload,z=typeof ce=="function"?ce.call(Me,P,z):ce,z==null)break e;P=m({},P,z);break e;case 2:Jn=!0}}z=T.callback,z!==null&&(t.flags|=64,H&&(t.flags|=8192),H=h.callbacks,H===null?h.callbacks=[z]:H.push(z))}else H={lane:z,tag:T.tag,payload:T.payload,callback:T.callback,next:null},K===null?(D=K=H,A=P):K=K.next=H,S|=z;if(T=T.next,T===null){if(T=h.shared.pending,T===null)break;H=T,T=H.next,H.next=null,h.lastBaseUpdate=H,h.shared.pending=null}}while(!0);K===null&&(A=P),h.baseState=A,h.firstBaseUpdate=D,h.lastBaseUpdate=K,g===null&&(h.shared.lanes=0),oi|=S,t.lanes=S,t.memoizedState=P}}function jp(t,r){if(typeof t!="function")throw Error(s(191,t));t.call(r)}function Lp(t,r){var l=t.callbacks;if(l!==null)for(t.callbacks=null,t=0;t<l.length;t++)jp(l[t],r)}var ks=X(null),Ml=X(0);function Dp(t,r){t=zn,W(Ml,t),W(ks,r),zn=t|r.baseLanes}function wu(){W(Ml,zn),W(ks,ks.current)}function xu(){zn=Ml.current,Q(ks),Q(Ml)}var ti=0,de=null,Ce=null,Xe=null,Ol=!1,Ms=!1,zi=!1,Rl=0,Jr=0,Os=null,p1=0;function Ve(){throw Error(s(321))}function _u(t,r){if(r===null)return!1;for(var l=0;l<r.length&&l<t.length;l++)if(!qt(t[l],r[l]))return!1;return!0}function Tu(t,r,l,c,h,g){return ti=g,de=r,r.memoizedState=null,r.updateQueue=null,r.lanes=0,q.H=t===null||t.memoizedState===null?bg:vg,zi=!1,g=l(c,h),zi=!1,Ms&&(g=Up(r,l,c,h)),Bp(t),g}function Bp(t){q.H=zl;var r=Ce!==null&&Ce.next!==null;if(ti=0,Xe=Ce=de=null,Ol=!1,Jr=0,Os=null,r)throw Error(s(300));t===null||tt||(t=t.dependencies,t!==null&&El(t)&&(tt=!0))}function Up(t,r,l,c){de=t;var h=0;do{if(Ms&&(Os=null),Jr=0,Ms=!1,25<=h)throw Error(s(301));if(h+=1,Xe=Ce=null,t.updateQueue!=null){var g=t.updateQueue;g.lastEffect=null,g.events=null,g.stores=null,g.memoCache!=null&&(g.memoCache.index=0)}q.H=w1,g=r(l,c)}while(Ms);return g}function g1(){var t=q.H,r=t.useState()[0];return r=typeof r.then=="function"?Wr(r):r,t=t.useState()[0],(Ce!==null?Ce.memoizedState:null)!==t&&(de.flags|=1024),r}function Eu(){var t=Rl!==0;return Rl=0,t}function Au(t,r,l){r.updateQueue=t.updateQueue,r.flags&=-2053,t.lanes&=~l}function Nu(t){if(Ol){for(t=t.memoizedState;t!==null;){var r=t.queue;r!==null&&(r.pending=null),t=t.next}Ol=!1}ti=0,Xe=Ce=de=null,Ms=!1,Jr=Rl=0,Os=null}function kt(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Xe===null?de.memoizedState=Xe=t:Xe=Xe.next=t,Xe}function Pe(){if(Ce===null){var t=de.alternate;t=t!==null?t.memoizedState:null}else t=Ce.next;var r=Xe===null?de.memoizedState:Xe.next;if(r!==null)Xe=r,Ce=t;else{if(t===null)throw de.alternate===null?Error(s(467)):Error(s(310));Ce=t,t={memoizedState:Ce.memoizedState,baseState:Ce.baseState,baseQueue:Ce.baseQueue,queue:Ce.queue,next:null},Xe===null?de.memoizedState=Xe=t:Xe=Xe.next=t}return Xe}function Cu(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Wr(t){var r=Jr;return Jr+=1,Os===null&&(Os=[]),t=Mp(Os,t,r),r=de,(Xe===null?r.memoizedState:Xe.next)===null&&(r=r.alternate,q.H=r===null||r.memoizedState===null?bg:vg),t}function jl(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return Wr(t);if(t.$$typeof===V)return gt(t)}throw Error(s(438,String(t)))}function ku(t){var r=null,l=de.updateQueue;if(l!==null&&(r=l.memoCache),r==null){var c=de.alternate;c!==null&&(c=c.updateQueue,c!==null&&(c=c.memoCache,c!=null&&(r={data:c.data.map(function(h){return h.slice()}),index:0})))}if(r==null&&(r={data:[],index:0}),l===null&&(l=Cu(),de.updateQueue=l),l.memoCache=r,l=r.data[r.index],l===void 0)for(l=r.data[r.index]=Array(t),c=0;c<t;c++)l[c]=ee;return r.index++,l}function Rn(t,r){return typeof r=="function"?r(t):r}function Ll(t){var r=Pe();return Mu(r,Ce,t)}function Mu(t,r,l){var c=t.queue;if(c===null)throw Error(s(311));c.lastRenderedReducer=l;var h=t.baseQueue,g=c.pending;if(g!==null){if(h!==null){var S=h.next;h.next=g.next,g.next=S}r.baseQueue=h=g,c.pending=null}if(g=t.baseState,h===null)t.memoizedState=g;else{r=h.next;var T=S=null,A=null,D=r,K=!1;do{var P=D.lane&-536870913;if(P!==D.lane?(we&P)===P:(ti&P)===P){var z=D.revertLane;if(z===0)A!==null&&(A=A.next={lane:0,revertLane:0,action:D.action,hasEagerState:D.hasEagerState,eagerState:D.eagerState,next:null}),P===Ns&&(K=!0);else if((ti&z)===z){D=D.next,z===Ns&&(K=!0);continue}else P={lane:0,revertLane:D.revertLane,action:D.action,hasEagerState:D.hasEagerState,eagerState:D.eagerState,next:null},A===null?(T=A=P,S=g):A=A.next=P,de.lanes|=z,oi|=z;P=D.action,zi&&l(g,P),g=D.hasEagerState?D.eagerState:l(g,P)}else z={lane:P,revertLane:D.revertLane,action:D.action,hasEagerState:D.hasEagerState,eagerState:D.eagerState,next:null},A===null?(T=A=z,S=g):A=A.next=z,de.lanes|=P,oi|=P;D=D.next}while(D!==null&&D!==r);if(A===null?S=g:A.next=T,!qt(g,t.memoizedState)&&(tt=!0,K&&(l=Cs,l!==null)))throw l;t.memoizedState=g,t.baseState=S,t.baseQueue=A,c.lastRenderedState=g}return h===null&&(c.lanes=0),[t.memoizedState,c.dispatch]}function Ou(t){var r=Pe(),l=r.queue;if(l===null)throw Error(s(311));l.lastRenderedReducer=t;var c=l.dispatch,h=l.pending,g=r.memoizedState;if(h!==null){l.pending=null;var S=h=h.next;do g=t(g,S.action),S=S.next;while(S!==h);qt(g,r.memoizedState)||(tt=!0),r.memoizedState=g,r.baseQueue===null&&(r.baseState=g),l.lastRenderedState=g}return[g,c]}function zp(t,r,l){var c=de,h=Pe(),g=Te;if(g){if(l===void 0)throw Error(s(407));l=l()}else l=r();var S=!qt((Ce||h).memoizedState,l);S&&(h.memoizedState=l,tt=!0),h=h.queue;var T=$p.bind(null,c,h,t);if(ea(2048,8,T,[t]),h.getSnapshot!==r||S||Xe!==null&&Xe.memoizedState.tag&1){if(c.flags|=2048,Rs(9,Dl(),qp.bind(null,c,h,l,r),null),je===null)throw Error(s(349));g||(ti&124)!==0||Hp(c,r,l)}return l}function Hp(t,r,l){t.flags|=16384,t={getSnapshot:r,value:l},r=de.updateQueue,r===null?(r=Cu(),de.updateQueue=r,r.stores=[t]):(l=r.stores,l===null?r.stores=[t]:l.push(t))}function qp(t,r,l,c){r.value=l,r.getSnapshot=c,Ip(r)&&Vp(t)}function $p(t,r,l){return l(function(){Ip(r)&&Vp(t)})}function Ip(t){var r=t.getSnapshot;t=t.value;try{var l=r();return!qt(t,l)}catch{return!0}}function Vp(t){var r=_s(t,2);r!==null&&Yt(r,t,2)}function Ru(t){var r=kt();if(typeof t=="function"){var l=t;if(t=l(),zi){Et(!0);try{l()}finally{Et(!1)}}}return r.memoizedState=r.baseState=t,r.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Rn,lastRenderedState:t},r}function Gp(t,r,l,c){return t.baseState=l,Mu(t,Ce,typeof c=="function"?c:Rn)}function m1(t,r,l,c,h){if(Ul(t))throw Error(s(485));if(t=r.action,t!==null){var g={payload:h,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(S){g.listeners.push(S)}};q.T!==null?l(!0):g.isTransition=!1,c(g),l=r.pending,l===null?(g.next=r.pending=g,Kp(r,g)):(g.next=l.next,r.pending=l.next=g)}}function Kp(t,r){var l=r.action,c=r.payload,h=t.state;if(r.isTransition){var g=q.T,S={};q.T=S;try{var T=l(h,c),A=q.S;A!==null&&A(S,T),Yp(t,r,T)}catch(D){ju(t,r,D)}finally{q.T=g}}else try{g=l(h,c),Yp(t,r,g)}catch(D){ju(t,r,D)}}function Yp(t,r,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(c){Xp(t,r,c)},function(c){return ju(t,r,c)}):Xp(t,r,l)}function Xp(t,r,l){r.status="fulfilled",r.value=l,Pp(r),t.state=l,r=t.pending,r!==null&&(l=r.next,l===r?t.pending=null:(l=l.next,r.next=l,Kp(t,l)))}function ju(t,r,l){var c=t.pending;if(t.pending=null,c!==null){c=c.next;do r.status="rejected",r.reason=l,Pp(r),r=r.next;while(r!==c)}t.action=null}function Pp(t){t=t.listeners;for(var r=0;r<t.length;r++)(0,t[r])()}function Fp(t,r){return r}function Qp(t,r){if(Te){var l=je.formState;if(l!==null){e:{var c=de;if(Te){if($e){t:{for(var h=$e,g=mn;h.nodeType!==8;){if(!g){h=null;break t}if(h=fn(h.nextSibling),h===null){h=null;break t}}g=h.data,h=g==="F!"||g==="F"?h:null}if(h){$e=fn(h.nextSibling),c=h.data==="F!";break e}}Li(c)}c=!1}c&&(r=l[0])}}return l=kt(),l.memoizedState=l.baseState=r,c={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Fp,lastRenderedState:r},l.queue=c,l=gg.bind(null,de,c),c.dispatch=l,c=Ru(!1),g=zu.bind(null,de,!1,c.queue),c=kt(),h={state:r,dispatch:null,action:t,pending:null},c.queue=h,l=m1.bind(null,de,h,g,l),h.dispatch=l,c.memoizedState=t,[r,l,!1]}function Zp(t){var r=Pe();return Jp(r,Ce,t)}function Jp(t,r,l){if(r=Mu(t,r,Fp)[0],t=Ll(Rn)[0],typeof r=="object"&&r!==null&&typeof r.then=="function")try{var c=Wr(r)}catch(S){throw S===Xr?Cl:S}else c=r;r=Pe();var h=r.queue,g=h.dispatch;return l!==r.memoizedState&&(de.flags|=2048,Rs(9,Dl(),y1.bind(null,h,l),null)),[c,g,t]}function y1(t,r){t.action=r}function Wp(t){var r=Pe(),l=Ce;if(l!==null)return Jp(r,l,t);Pe(),r=r.memoizedState,l=Pe();var c=l.queue.dispatch;return l.memoizedState=t,[r,c,!1]}function Rs(t,r,l,c){return t={tag:t,create:l,deps:c,inst:r,next:null},r=de.updateQueue,r===null&&(r=Cu(),de.updateQueue=r),l=r.lastEffect,l===null?r.lastEffect=t.next=t:(c=l.next,l.next=t,t.next=c,r.lastEffect=t),t}function Dl(){return{destroy:void 0,resource:void 0}}function eg(){return Pe().memoizedState}function Bl(t,r,l,c){var h=kt();c=c===void 0?null:c,de.flags|=t,h.memoizedState=Rs(1|r,Dl(),l,c)}function ea(t,r,l,c){var h=Pe();c=c===void 0?null:c;var g=h.memoizedState.inst;Ce!==null&&c!==null&&_u(c,Ce.memoizedState.deps)?h.memoizedState=Rs(r,g,l,c):(de.flags|=t,h.memoizedState=Rs(1|r,g,l,c))}function tg(t,r){Bl(8390656,8,t,r)}function ng(t,r){ea(2048,8,t,r)}function ig(t,r){return ea(4,2,t,r)}function sg(t,r){return ea(4,4,t,r)}function rg(t,r){if(typeof r=="function"){t=t();var l=r(t);return function(){typeof l=="function"?l():r(null)}}if(r!=null)return t=t(),r.current=t,function(){r.current=null}}function ag(t,r,l){l=l!=null?l.concat([t]):null,ea(4,4,rg.bind(null,r,t),l)}function Lu(){}function lg(t,r){var l=Pe();r=r===void 0?null:r;var c=l.memoizedState;return r!==null&&_u(r,c[1])?c[0]:(l.memoizedState=[t,r],t)}function og(t,r){var l=Pe();r=r===void 0?null:r;var c=l.memoizedState;if(r!==null&&_u(r,c[1]))return c[0];if(c=t(),zi){Et(!0);try{t()}finally{Et(!1)}}return l.memoizedState=[c,r],c}function Du(t,r,l){return l===void 0||(ti&1073741824)!==0?t.memoizedState=r:(t.memoizedState=l,t=fm(),de.lanes|=t,oi|=t,l)}function cg(t,r,l,c){return qt(l,r)?l:ks.current!==null?(t=Du(t,l,c),qt(t,r)||(tt=!0),t):(ti&42)===0?(tt=!0,t.memoizedState=l):(t=fm(),de.lanes|=t,oi|=t,r)}function ug(t,r,l,c,h){var g=Z.p;Z.p=g!==0&&8>g?g:8;var S=q.T,T={};q.T=T,zu(t,!1,r,l);try{var A=h(),D=q.S;if(D!==null&&D(T,A),A!==null&&typeof A=="object"&&typeof A.then=="function"){var K=d1(A,c);ta(t,r,K,Kt(t))}else ta(t,r,c,Kt(t))}catch(P){ta(t,r,{then:function(){},status:"rejected",reason:P},Kt())}finally{Z.p=g,q.T=S}}function b1(){}function Bu(t,r,l,c){if(t.tag!==5)throw Error(s(476));var h=fg(t).queue;ug(t,h,r,ne,l===null?b1:function(){return hg(t),l(c)})}function fg(t){var r=t.memoizedState;if(r!==null)return r;r={memoizedState:ne,baseState:ne,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Rn,lastRenderedState:ne},next:null};var l={};return r.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Rn,lastRenderedState:l},next:null},t.memoizedState=r,t=t.alternate,t!==null&&(t.memoizedState=r),r}function hg(t){var r=fg(t).next.queue;ta(t,r,{},Kt())}function Uu(){return gt(va)}function dg(){return Pe().memoizedState}function pg(){return Pe().memoizedState}function v1(t){for(var r=t.return;r!==null;){switch(r.tag){case 24:case 3:var l=Kt();t=Wn(l);var c=ei(r,t,l);c!==null&&(Yt(c,r,l),Fr(c,r,l)),r={cache:du()},t.payload=r;return}r=r.return}}function S1(t,r,l){var c=Kt();l={lane:c,revertLane:0,action:l,hasEagerState:!1,eagerState:null,next:null},Ul(t)?mg(r,l):(l=iu(t,r,l,c),l!==null&&(Yt(l,t,c),yg(l,r,c)))}function gg(t,r,l){var c=Kt();ta(t,r,l,c)}function ta(t,r,l,c){var h={lane:c,revertLane:0,action:l,hasEagerState:!1,eagerState:null,next:null};if(Ul(t))mg(r,h);else{var g=t.alternate;if(t.lanes===0&&(g===null||g.lanes===0)&&(g=r.lastRenderedReducer,g!==null))try{var S=r.lastRenderedState,T=g(S,l);if(h.hasEagerState=!0,h.eagerState=T,qt(T,S))return Sl(t,r,h,0),je===null&&vl(),!1}catch{}finally{}if(l=iu(t,r,h,c),l!==null)return Yt(l,t,c),yg(l,r,c),!0}return!1}function zu(t,r,l,c){if(c={lane:2,revertLane:yf(),action:c,hasEagerState:!1,eagerState:null,next:null},Ul(t)){if(r)throw Error(s(479))}else r=iu(t,l,c,2),r!==null&&Yt(r,t,2)}function Ul(t){var r=t.alternate;return t===de||r!==null&&r===de}function mg(t,r){Ms=Ol=!0;var l=t.pending;l===null?r.next=r:(r.next=l.next,l.next=r),t.pending=r}function yg(t,r,l){if((l&4194048)!==0){var c=r.lanes;c&=t.pendingLanes,l|=c,r.lanes=l,Ed(t,l)}}var zl={readContext:gt,use:jl,useCallback:Ve,useContext:Ve,useEffect:Ve,useImperativeHandle:Ve,useLayoutEffect:Ve,useInsertionEffect:Ve,useMemo:Ve,useReducer:Ve,useRef:Ve,useState:Ve,useDebugValue:Ve,useDeferredValue:Ve,useTransition:Ve,useSyncExternalStore:Ve,useId:Ve,useHostTransitionStatus:Ve,useFormState:Ve,useActionState:Ve,useOptimistic:Ve,useMemoCache:Ve,useCacheRefresh:Ve},bg={readContext:gt,use:jl,useCallback:function(t,r){return kt().memoizedState=[t,r===void 0?null:r],t},useContext:gt,useEffect:tg,useImperativeHandle:function(t,r,l){l=l!=null?l.concat([t]):null,Bl(4194308,4,rg.bind(null,r,t),l)},useLayoutEffect:function(t,r){return Bl(4194308,4,t,r)},useInsertionEffect:function(t,r){Bl(4,2,t,r)},useMemo:function(t,r){var l=kt();r=r===void 0?null:r;var c=t();if(zi){Et(!0);try{t()}finally{Et(!1)}}return l.memoizedState=[c,r],c},useReducer:function(t,r,l){var c=kt();if(l!==void 0){var h=l(r);if(zi){Et(!0);try{l(r)}finally{Et(!1)}}}else h=r;return c.memoizedState=c.baseState=h,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:h},c.queue=t,t=t.dispatch=S1.bind(null,de,t),[c.memoizedState,t]},useRef:function(t){var r=kt();return t={current:t},r.memoizedState=t},useState:function(t){t=Ru(t);var r=t.queue,l=gg.bind(null,de,r);return r.dispatch=l,[t.memoizedState,l]},useDebugValue:Lu,useDeferredValue:function(t,r){var l=kt();return Du(l,t,r)},useTransition:function(){var t=Ru(!1);return t=ug.bind(null,de,t.queue,!0,!1),kt().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,r,l){var c=de,h=kt();if(Te){if(l===void 0)throw Error(s(407));l=l()}else{if(l=r(),je===null)throw Error(s(349));(we&124)!==0||Hp(c,r,l)}h.memoizedState=l;var g={value:l,getSnapshot:r};return h.queue=g,tg($p.bind(null,c,g,t),[t]),c.flags|=2048,Rs(9,Dl(),qp.bind(null,c,g,l,r),null),l},useId:function(){var t=kt(),r=je.identifierPrefix;if(Te){var l=kn,c=Cn;l=(c&~(1<<32-rt(c)-1)).toString(32)+l,r="«"+r+"R"+l,l=Rl++,0<l&&(r+="H"+l.toString(32)),r+="»"}else l=p1++,r="«"+r+"r"+l.toString(32)+"»";return t.memoizedState=r},useHostTransitionStatus:Uu,useFormState:Qp,useActionState:Qp,useOptimistic:function(t){var r=kt();r.memoizedState=r.baseState=t;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return r.queue=l,r=zu.bind(null,de,!0,l),l.dispatch=r,[t,r]},useMemoCache:ku,useCacheRefresh:function(){return kt().memoizedState=v1.bind(null,de)}},vg={readContext:gt,use:jl,useCallback:lg,useContext:gt,useEffect:ng,useImperativeHandle:ag,useInsertionEffect:ig,useLayoutEffect:sg,useMemo:og,useReducer:Ll,useRef:eg,useState:function(){return Ll(Rn)},useDebugValue:Lu,useDeferredValue:function(t,r){var l=Pe();return cg(l,Ce.memoizedState,t,r)},useTransition:function(){var t=Ll(Rn)[0],r=Pe().memoizedState;return[typeof t=="boolean"?t:Wr(t),r]},useSyncExternalStore:zp,useId:dg,useHostTransitionStatus:Uu,useFormState:Zp,useActionState:Zp,useOptimistic:function(t,r){var l=Pe();return Gp(l,Ce,t,r)},useMemoCache:ku,useCacheRefresh:pg},w1={readContext:gt,use:jl,useCallback:lg,useContext:gt,useEffect:ng,useImperativeHandle:ag,useInsertionEffect:ig,useLayoutEffect:sg,useMemo:og,useReducer:Ou,useRef:eg,useState:function(){return Ou(Rn)},useDebugValue:Lu,useDeferredValue:function(t,r){var l=Pe();return Ce===null?Du(l,t,r):cg(l,Ce.memoizedState,t,r)},useTransition:function(){var t=Ou(Rn)[0],r=Pe().memoizedState;return[typeof t=="boolean"?t:Wr(t),r]},useSyncExternalStore:zp,useId:dg,useHostTransitionStatus:Uu,useFormState:Wp,useActionState:Wp,useOptimistic:function(t,r){var l=Pe();return Ce!==null?Gp(l,Ce,t,r):(l.baseState=t,[t,l.queue.dispatch])},useMemoCache:ku,useCacheRefresh:pg},js=null,na=0;function Hl(t){var r=na;return na+=1,js===null&&(js=[]),Mp(js,t,r)}function ia(t,r){r=r.props.ref,t.ref=r!==void 0?r:null}function ql(t,r){throw r.$$typeof===y?Error(s(525)):(t=Object.prototype.toString.call(r),Error(s(31,t==="[object Object]"?"object with keys {"+Object.keys(r).join(", ")+"}":t)))}function Sg(t){var r=t._init;return r(t._payload)}function wg(t){function r(O,M){if(t){var L=O.deletions;L===null?(O.deletions=[M],O.flags|=16):L.push(M)}}function l(O,M){if(!t)return null;for(;M!==null;)r(O,M),M=M.sibling;return null}function c(O){for(var M=new Map;O!==null;)O.key!==null?M.set(O.key,O):M.set(O.index,O),O=O.sibling;return M}function h(O,M){return O=Nn(O,M),O.index=0,O.sibling=null,O}function g(O,M,L){return O.index=L,t?(L=O.alternate,L!==null?(L=L.index,L<M?(O.flags|=67108866,M):L):(O.flags|=67108866,M)):(O.flags|=1048576,M)}function S(O){return t&&O.alternate===null&&(O.flags|=67108866),O}function T(O,M,L,Y){return M===null||M.tag!==6?(M=ru(L,O.mode,Y),M.return=O,M):(M=h(M,L),M.return=O,M)}function A(O,M,L,Y){var te=L.type;return te===E?K(O,M,L.props.children,Y,L.key):M!==null&&(M.elementType===te||typeof te=="object"&&te!==null&&te.$$typeof===$&&Sg(te)===M.type)?(M=h(M,L.props),ia(M,L),M.return=O,M):(M=xl(L.type,L.key,L.props,null,O.mode,Y),ia(M,L),M.return=O,M)}function D(O,M,L,Y){return M===null||M.tag!==4||M.stateNode.containerInfo!==L.containerInfo||M.stateNode.implementation!==L.implementation?(M=au(L,O.mode,Y),M.return=O,M):(M=h(M,L.children||[]),M.return=O,M)}function K(O,M,L,Y,te){return M===null||M.tag!==7?(M=Mi(L,O.mode,Y,te),M.return=O,M):(M=h(M,L),M.return=O,M)}function P(O,M,L){if(typeof M=="string"&&M!==""||typeof M=="number"||typeof M=="bigint")return M=ru(""+M,O.mode,L),M.return=O,M;if(typeof M=="object"&&M!==null){switch(M.$$typeof){case b:return L=xl(M.type,M.key,M.props,null,O.mode,L),ia(L,M),L.return=O,L;case w:return M=au(M,O.mode,L),M.return=O,M;case $:var Y=M._init;return M=Y(M._payload),P(O,M,L)}if(me(M)||j(M))return M=Mi(M,O.mode,L,null),M.return=O,M;if(typeof M.then=="function")return P(O,Hl(M),L);if(M.$$typeof===V)return P(O,Al(O,M),L);ql(O,M)}return null}function z(O,M,L,Y){var te=M!==null?M.key:null;if(typeof L=="string"&&L!==""||typeof L=="number"||typeof L=="bigint")return te!==null?null:T(O,M,""+L,Y);if(typeof L=="object"&&L!==null){switch(L.$$typeof){case b:return L.key===te?A(O,M,L,Y):null;case w:return L.key===te?D(O,M,L,Y):null;case $:return te=L._init,L=te(L._payload),z(O,M,L,Y)}if(me(L)||j(L))return te!==null?null:K(O,M,L,Y,null);if(typeof L.then=="function")return z(O,M,Hl(L),Y);if(L.$$typeof===V)return z(O,M,Al(O,L),Y);ql(O,L)}return null}function H(O,M,L,Y,te){if(typeof Y=="string"&&Y!==""||typeof Y=="number"||typeof Y=="bigint")return O=O.get(L)||null,T(M,O,""+Y,te);if(typeof Y=="object"&&Y!==null){switch(Y.$$typeof){case b:return O=O.get(Y.key===null?L:Y.key)||null,A(M,O,Y,te);case w:return O=O.get(Y.key===null?L:Y.key)||null,D(M,O,Y,te);case $:var pe=Y._init;return Y=pe(Y._payload),H(O,M,L,Y,te)}if(me(Y)||j(Y))return O=O.get(L)||null,K(M,O,Y,te,null);if(typeof Y.then=="function")return H(O,M,L,Hl(Y),te);if(Y.$$typeof===V)return H(O,M,L,Al(M,Y),te);ql(M,Y)}return null}function ce(O,M,L,Y){for(var te=null,pe=null,ie=M,oe=M=0,it=null;ie!==null&&oe<L.length;oe++){ie.index>oe?(it=ie,ie=null):it=ie.sibling;var _e=z(O,ie,L[oe],Y);if(_e===null){ie===null&&(ie=it);break}t&&ie&&_e.alternate===null&&r(O,ie),M=g(_e,M,oe),pe===null?te=_e:pe.sibling=_e,pe=_e,ie=it}if(oe===L.length)return l(O,ie),Te&&Ri(O,oe),te;if(ie===null){for(;oe<L.length;oe++)ie=P(O,L[oe],Y),ie!==null&&(M=g(ie,M,oe),pe===null?te=ie:pe.sibling=ie,pe=ie);return Te&&Ri(O,oe),te}for(ie=c(ie);oe<L.length;oe++)it=H(ie,O,oe,L[oe],Y),it!==null&&(t&&it.alternate!==null&&ie.delete(it.key===null?oe:it.key),M=g(it,M,oe),pe===null?te=it:pe.sibling=it,pe=it);return t&&ie.forEach(function(yi){return r(O,yi)}),Te&&Ri(O,oe),te}function ae(O,M,L,Y){if(L==null)throw Error(s(151));for(var te=null,pe=null,ie=M,oe=M=0,it=null,_e=L.next();ie!==null&&!_e.done;oe++,_e=L.next()){ie.index>oe?(it=ie,ie=null):it=ie.sibling;var yi=z(O,ie,_e.value,Y);if(yi===null){ie===null&&(ie=it);break}t&&ie&&yi.alternate===null&&r(O,ie),M=g(yi,M,oe),pe===null?te=yi:pe.sibling=yi,pe=yi,ie=it}if(_e.done)return l(O,ie),Te&&Ri(O,oe),te;if(ie===null){for(;!_e.done;oe++,_e=L.next())_e=P(O,_e.value,Y),_e!==null&&(M=g(_e,M,oe),pe===null?te=_e:pe.sibling=_e,pe=_e);return Te&&Ri(O,oe),te}for(ie=c(ie);!_e.done;oe++,_e=L.next())_e=H(ie,O,oe,_e.value,Y),_e!==null&&(t&&_e.alternate!==null&&ie.delete(_e.key===null?oe:_e.key),M=g(_e,M,oe),pe===null?te=_e:pe.sibling=_e,pe=_e);return t&&ie.forEach(function(xw){return r(O,xw)}),Te&&Ri(O,oe),te}function Me(O,M,L,Y){if(typeof L=="object"&&L!==null&&L.type===E&&L.key===null&&(L=L.props.children),typeof L=="object"&&L!==null){switch(L.$$typeof){case b:e:{for(var te=L.key;M!==null;){if(M.key===te){if(te=L.type,te===E){if(M.tag===7){l(O,M.sibling),Y=h(M,L.props.children),Y.return=O,O=Y;break e}}else if(M.elementType===te||typeof te=="object"&&te!==null&&te.$$typeof===$&&Sg(te)===M.type){l(O,M.sibling),Y=h(M,L.props),ia(Y,L),Y.return=O,O=Y;break e}l(O,M);break}else r(O,M);M=M.sibling}L.type===E?(Y=Mi(L.props.children,O.mode,Y,L.key),Y.return=O,O=Y):(Y=xl(L.type,L.key,L.props,null,O.mode,Y),ia(Y,L),Y.return=O,O=Y)}return S(O);case w:e:{for(te=L.key;M!==null;){if(M.key===te)if(M.tag===4&&M.stateNode.containerInfo===L.containerInfo&&M.stateNode.implementation===L.implementation){l(O,M.sibling),Y=h(M,L.children||[]),Y.return=O,O=Y;break e}else{l(O,M);break}else r(O,M);M=M.sibling}Y=au(L,O.mode,Y),Y.return=O,O=Y}return S(O);case $:return te=L._init,L=te(L._payload),Me(O,M,L,Y)}if(me(L))return ce(O,M,L,Y);if(j(L)){if(te=j(L),typeof te!="function")throw Error(s(150));return L=te.call(L),ae(O,M,L,Y)}if(typeof L.then=="function")return Me(O,M,Hl(L),Y);if(L.$$typeof===V)return Me(O,M,Al(O,L),Y);ql(O,L)}return typeof L=="string"&&L!==""||typeof L=="number"||typeof L=="bigint"?(L=""+L,M!==null&&M.tag===6?(l(O,M.sibling),Y=h(M,L),Y.return=O,O=Y):(l(O,M),Y=ru(L,O.mode,Y),Y.return=O,O=Y),S(O)):l(O,M)}return function(O,M,L,Y){try{na=0;var te=Me(O,M,L,Y);return js=null,te}catch(ie){if(ie===Xr||ie===Cl)throw ie;var pe=$t(29,ie,null,O.mode);return pe.lanes=Y,pe.return=O,pe}finally{}}}var Ls=wg(!0),xg=wg(!1),en=X(null),yn=null;function ni(t){var r=t.alternate;W(Ze,Ze.current&1),W(en,t),yn===null&&(r===null||ks.current!==null||r.memoizedState!==null)&&(yn=t)}function _g(t){if(t.tag===22){if(W(Ze,Ze.current),W(en,t),yn===null){var r=t.alternate;r!==null&&r.memoizedState!==null&&(yn=t)}}else ii()}function ii(){W(Ze,Ze.current),W(en,en.current)}function jn(t){Q(en),yn===t&&(yn=null),Q(Ze)}var Ze=X(0);function $l(t){for(var r=t;r!==null;){if(r.tag===13){var l=r.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||kf(l)))return r}else if(r.tag===19&&r.memoizedProps.revealOrder!==void 0){if((r.flags&128)!==0)return r}else if(r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return null;r=r.return}r.sibling.return=r.return,r=r.sibling}return null}function Hu(t,r,l,c){r=t.memoizedState,l=l(c,r),l=l==null?r:m({},r,l),t.memoizedState=l,t.lanes===0&&(t.updateQueue.baseState=l)}var qu={enqueueSetState:function(t,r,l){t=t._reactInternals;var c=Kt(),h=Wn(c);h.payload=r,l!=null&&(h.callback=l),r=ei(t,h,c),r!==null&&(Yt(r,t,c),Fr(r,t,c))},enqueueReplaceState:function(t,r,l){t=t._reactInternals;var c=Kt(),h=Wn(c);h.tag=1,h.payload=r,l!=null&&(h.callback=l),r=ei(t,h,c),r!==null&&(Yt(r,t,c),Fr(r,t,c))},enqueueForceUpdate:function(t,r){t=t._reactInternals;var l=Kt(),c=Wn(l);c.tag=2,r!=null&&(c.callback=r),r=ei(t,c,l),r!==null&&(Yt(r,t,l),Fr(r,t,l))}};function Tg(t,r,l,c,h,g,S){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(c,g,S):r.prototype&&r.prototype.isPureReactComponent?!Hr(l,c)||!Hr(h,g):!0}function Eg(t,r,l,c){t=r.state,typeof r.componentWillReceiveProps=="function"&&r.componentWillReceiveProps(l,c),typeof r.UNSAFE_componentWillReceiveProps=="function"&&r.UNSAFE_componentWillReceiveProps(l,c),r.state!==t&&qu.enqueueReplaceState(r,r.state,null)}function Hi(t,r){var l=r;if("ref"in r){l={};for(var c in r)c!=="ref"&&(l[c]=r[c])}if(t=t.defaultProps){l===r&&(l=m({},l));for(var h in t)l[h]===void 0&&(l[h]=t[h])}return l}var Il=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var r=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(r))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)};function Ag(t){Il(t)}function Ng(t){console.error(t)}function Cg(t){Il(t)}function Vl(t,r){try{var l=t.onUncaughtError;l(r.value,{componentStack:r.stack})}catch(c){setTimeout(function(){throw c})}}function kg(t,r,l){try{var c=t.onCaughtError;c(l.value,{componentStack:l.stack,errorBoundary:r.tag===1?r.stateNode:null})}catch(h){setTimeout(function(){throw h})}}function $u(t,r,l){return l=Wn(l),l.tag=3,l.payload={element:null},l.callback=function(){Vl(t,r)},l}function Mg(t){return t=Wn(t),t.tag=3,t}function Og(t,r,l,c){var h=l.type.getDerivedStateFromError;if(typeof h=="function"){var g=c.value;t.payload=function(){return h(g)},t.callback=function(){kg(r,l,c)}}var S=l.stateNode;S!==null&&typeof S.componentDidCatch=="function"&&(t.callback=function(){kg(r,l,c),typeof h!="function"&&(ci===null?ci=new Set([this]):ci.add(this));var T=c.stack;this.componentDidCatch(c.value,{componentStack:T!==null?T:""})})}function x1(t,r,l,c,h){if(l.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){if(r=l.alternate,r!==null&&Gr(r,l,h,!0),l=en.current,l!==null){switch(l.tag){case 13:return yn===null?hf():l.alternate===null&&Ie===0&&(Ie=3),l.flags&=-257,l.flags|=65536,l.lanes=h,c===mu?l.flags|=16384:(r=l.updateQueue,r===null?l.updateQueue=new Set([c]):r.add(c),pf(t,c,h)),!1;case 22:return l.flags|=65536,c===mu?l.flags|=16384:(r=l.updateQueue,r===null?(r={transitions:null,markerInstances:null,retryQueue:new Set([c])},l.updateQueue=r):(l=r.retryQueue,l===null?r.retryQueue=new Set([c]):l.add(c)),pf(t,c,h)),!1}throw Error(s(435,l.tag))}return pf(t,c,h),hf(),!1}if(Te)return r=en.current,r!==null?((r.flags&65536)===0&&(r.flags|=256),r.flags|=65536,r.lanes=h,c!==cu&&(t=Error(s(422),{cause:c}),Vr(Qt(t,l)))):(c!==cu&&(r=Error(s(423),{cause:c}),Vr(Qt(r,l))),t=t.current.alternate,t.flags|=65536,h&=-h,t.lanes|=h,c=Qt(c,l),h=$u(t.stateNode,c,h),vu(t,h),Ie!==4&&(Ie=2)),!1;var g=Error(s(520),{cause:c});if(g=Qt(g,l),ua===null?ua=[g]:ua.push(g),Ie!==4&&(Ie=2),r===null)return!0;c=Qt(c,l),l=r;do{switch(l.tag){case 3:return l.flags|=65536,t=h&-h,l.lanes|=t,t=$u(l.stateNode,c,t),vu(l,t),!1;case 1:if(r=l.type,g=l.stateNode,(l.flags&128)===0&&(typeof r.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(ci===null||!ci.has(g))))return l.flags|=65536,h&=-h,l.lanes|=h,h=Mg(h),Og(h,t,l,c),vu(l,h),!1}l=l.return}while(l!==null);return!1}var Rg=Error(s(461)),tt=!1;function at(t,r,l,c){r.child=t===null?xg(r,null,l,c):Ls(r,t.child,l,c)}function jg(t,r,l,c,h){l=l.render;var g=r.ref;if("ref"in c){var S={};for(var T in c)T!=="ref"&&(S[T]=c[T])}else S=c;return Bi(r),c=Tu(t,r,l,S,g,h),T=Eu(),t!==null&&!tt?(Au(t,r,h),Ln(t,r,h)):(Te&&T&&lu(r),r.flags|=1,at(t,r,c,h),r.child)}function Lg(t,r,l,c,h){if(t===null){var g=l.type;return typeof g=="function"&&!su(g)&&g.defaultProps===void 0&&l.compare===null?(r.tag=15,r.type=g,Dg(t,r,g,c,h)):(t=xl(l.type,null,c,r,r.mode,h),t.ref=r.ref,t.return=r,r.child=t)}if(g=t.child,!Fu(t,h)){var S=g.memoizedProps;if(l=l.compare,l=l!==null?l:Hr,l(S,c)&&t.ref===r.ref)return Ln(t,r,h)}return r.flags|=1,t=Nn(g,c),t.ref=r.ref,t.return=r,r.child=t}function Dg(t,r,l,c,h){if(t!==null){var g=t.memoizedProps;if(Hr(g,c)&&t.ref===r.ref)if(tt=!1,r.pendingProps=c=g,Fu(t,h))(t.flags&131072)!==0&&(tt=!0);else return r.lanes=t.lanes,Ln(t,r,h)}return Iu(t,r,l,c,h)}function Bg(t,r,l){var c=r.pendingProps,h=c.children,g=t!==null?t.memoizedState:null;if(c.mode==="hidden"){if((r.flags&128)!==0){if(c=g!==null?g.baseLanes|l:l,t!==null){for(h=r.child=t.child,g=0;h!==null;)g=g|h.lanes|h.childLanes,h=h.sibling;r.childLanes=g&~c}else r.childLanes=0,r.child=null;return Ug(t,r,c,l)}if((l&536870912)!==0)r.memoizedState={baseLanes:0,cachePool:null},t!==null&&Nl(r,g!==null?g.cachePool:null),g!==null?Dp(r,g):wu(),_g(r);else return r.lanes=r.childLanes=536870912,Ug(t,r,g!==null?g.baseLanes|l:l,l)}else g!==null?(Nl(r,g.cachePool),Dp(r,g),ii(),r.memoizedState=null):(t!==null&&Nl(r,null),wu(),ii());return at(t,r,h,l),r.child}function Ug(t,r,l,c){var h=gu();return h=h===null?null:{parent:Qe._currentValue,pool:h},r.memoizedState={baseLanes:l,cachePool:h},t!==null&&Nl(r,null),wu(),_g(r),t!==null&&Gr(t,r,c,!0),null}function Gl(t,r){var l=r.ref;if(l===null)t!==null&&t.ref!==null&&(r.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(s(284));(t===null||t.ref!==l)&&(r.flags|=4194816)}}function Iu(t,r,l,c,h){return Bi(r),l=Tu(t,r,l,c,void 0,h),c=Eu(),t!==null&&!tt?(Au(t,r,h),Ln(t,r,h)):(Te&&c&&lu(r),r.flags|=1,at(t,r,l,h),r.child)}function zg(t,r,l,c,h,g){return Bi(r),r.updateQueue=null,l=Up(r,c,l,h),Bp(t),c=Eu(),t!==null&&!tt?(Au(t,r,g),Ln(t,r,g)):(Te&&c&&lu(r),r.flags|=1,at(t,r,l,g),r.child)}function Hg(t,r,l,c,h){if(Bi(r),r.stateNode===null){var g=Ts,S=l.contextType;typeof S=="object"&&S!==null&&(g=gt(S)),g=new l(c,g),r.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,g.updater=qu,r.stateNode=g,g._reactInternals=r,g=r.stateNode,g.props=c,g.state=r.memoizedState,g.refs={},yu(r),S=l.contextType,g.context=typeof S=="object"&&S!==null?gt(S):Ts,g.state=r.memoizedState,S=l.getDerivedStateFromProps,typeof S=="function"&&(Hu(r,l,S,c),g.state=r.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(S=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),S!==g.state&&qu.enqueueReplaceState(g,g.state,null),Zr(r,c,g,h),Qr(),g.state=r.memoizedState),typeof g.componentDidMount=="function"&&(r.flags|=4194308),c=!0}else if(t===null){g=r.stateNode;var T=r.memoizedProps,A=Hi(l,T);g.props=A;var D=g.context,K=l.contextType;S=Ts,typeof K=="object"&&K!==null&&(S=gt(K));var P=l.getDerivedStateFromProps;K=typeof P=="function"||typeof g.getSnapshotBeforeUpdate=="function",T=r.pendingProps!==T,K||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(T||D!==S)&&Eg(r,g,c,S),Jn=!1;var z=r.memoizedState;g.state=z,Zr(r,c,g,h),Qr(),D=r.memoizedState,T||z!==D||Jn?(typeof P=="function"&&(Hu(r,l,P,c),D=r.memoizedState),(A=Jn||Tg(r,l,A,c,z,D,S))?(K||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount()),typeof g.componentDidMount=="function"&&(r.flags|=4194308)):(typeof g.componentDidMount=="function"&&(r.flags|=4194308),r.memoizedProps=c,r.memoizedState=D),g.props=c,g.state=D,g.context=S,c=A):(typeof g.componentDidMount=="function"&&(r.flags|=4194308),c=!1)}else{g=r.stateNode,bu(t,r),S=r.memoizedProps,K=Hi(l,S),g.props=K,P=r.pendingProps,z=g.context,D=l.contextType,A=Ts,typeof D=="object"&&D!==null&&(A=gt(D)),T=l.getDerivedStateFromProps,(D=typeof T=="function"||typeof g.getSnapshotBeforeUpdate=="function")||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(S!==P||z!==A)&&Eg(r,g,c,A),Jn=!1,z=r.memoizedState,g.state=z,Zr(r,c,g,h),Qr();var H=r.memoizedState;S!==P||z!==H||Jn||t!==null&&t.dependencies!==null&&El(t.dependencies)?(typeof T=="function"&&(Hu(r,l,T,c),H=r.memoizedState),(K=Jn||Tg(r,l,K,c,z,H,A)||t!==null&&t.dependencies!==null&&El(t.dependencies))?(D||typeof g.UNSAFE_componentWillUpdate!="function"&&typeof g.componentWillUpdate!="function"||(typeof g.componentWillUpdate=="function"&&g.componentWillUpdate(c,H,A),typeof g.UNSAFE_componentWillUpdate=="function"&&g.UNSAFE_componentWillUpdate(c,H,A)),typeof g.componentDidUpdate=="function"&&(r.flags|=4),typeof g.getSnapshotBeforeUpdate=="function"&&(r.flags|=1024)):(typeof g.componentDidUpdate!="function"||S===t.memoizedProps&&z===t.memoizedState||(r.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||S===t.memoizedProps&&z===t.memoizedState||(r.flags|=1024),r.memoizedProps=c,r.memoizedState=H),g.props=c,g.state=H,g.context=A,c=K):(typeof g.componentDidUpdate!="function"||S===t.memoizedProps&&z===t.memoizedState||(r.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||S===t.memoizedProps&&z===t.memoizedState||(r.flags|=1024),c=!1)}return g=c,Gl(t,r),c=(r.flags&128)!==0,g||c?(g=r.stateNode,l=c&&typeof l.getDerivedStateFromError!="function"?null:g.render(),r.flags|=1,t!==null&&c?(r.child=Ls(r,t.child,null,h),r.child=Ls(r,null,l,h)):at(t,r,l,h),r.memoizedState=g.state,t=r.child):t=Ln(t,r,h),t}function qg(t,r,l,c){return Ir(),r.flags|=256,at(t,r,l,c),r.child}var Vu={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Gu(t){return{baseLanes:t,cachePool:Np()}}function Ku(t,r,l){return t=t!==null?t.childLanes&~l:0,r&&(t|=tn),t}function $g(t,r,l){var c=r.pendingProps,h=!1,g=(r.flags&128)!==0,S;if((S=g)||(S=t!==null&&t.memoizedState===null?!1:(Ze.current&2)!==0),S&&(h=!0,r.flags&=-129),S=(r.flags&32)!==0,r.flags&=-33,t===null){if(Te){if(h?ni(r):ii(),Te){var T=$e,A;if(A=T){e:{for(A=T,T=mn;A.nodeType!==8;){if(!T){T=null;break e}if(A=fn(A.nextSibling),A===null){T=null;break e}}T=A}T!==null?(r.memoizedState={dehydrated:T,treeContext:Oi!==null?{id:Cn,overflow:kn}:null,retryLane:536870912,hydrationErrors:null},A=$t(18,null,null,0),A.stateNode=T,A.return=r,r.child=A,St=r,$e=null,A=!0):A=!1}A||Li(r)}if(T=r.memoizedState,T!==null&&(T=T.dehydrated,T!==null))return kf(T)?r.lanes=32:r.lanes=536870912,null;jn(r)}return T=c.children,c=c.fallback,h?(ii(),h=r.mode,T=Kl({mode:"hidden",children:T},h),c=Mi(c,h,l,null),T.return=r,c.return=r,T.sibling=c,r.child=T,h=r.child,h.memoizedState=Gu(l),h.childLanes=Ku(t,S,l),r.memoizedState=Vu,c):(ni(r),Yu(r,T))}if(A=t.memoizedState,A!==null&&(T=A.dehydrated,T!==null)){if(g)r.flags&256?(ni(r),r.flags&=-257,r=Xu(t,r,l)):r.memoizedState!==null?(ii(),r.child=t.child,r.flags|=128,r=null):(ii(),h=c.fallback,T=r.mode,c=Kl({mode:"visible",children:c.children},T),h=Mi(h,T,l,null),h.flags|=2,c.return=r,h.return=r,c.sibling=h,r.child=c,Ls(r,t.child,null,l),c=r.child,c.memoizedState=Gu(l),c.childLanes=Ku(t,S,l),r.memoizedState=Vu,r=h);else if(ni(r),kf(T)){if(S=T.nextSibling&&T.nextSibling.dataset,S)var D=S.dgst;S=D,c=Error(s(419)),c.stack="",c.digest=S,Vr({value:c,source:null,stack:null}),r=Xu(t,r,l)}else if(tt||Gr(t,r,l,!1),S=(l&t.childLanes)!==0,tt||S){if(S=je,S!==null&&(c=l&-l,c=(c&42)!==0?1:kc(c),c=(c&(S.suspendedLanes|l))!==0?0:c,c!==0&&c!==A.retryLane))throw A.retryLane=c,_s(t,c),Yt(S,t,c),Rg;T.data==="$?"||hf(),r=Xu(t,r,l)}else T.data==="$?"?(r.flags|=192,r.child=t.child,r=null):(t=A.treeContext,$e=fn(T.nextSibling),St=r,Te=!0,ji=null,mn=!1,t!==null&&(Jt[Wt++]=Cn,Jt[Wt++]=kn,Jt[Wt++]=Oi,Cn=t.id,kn=t.overflow,Oi=r),r=Yu(r,c.children),r.flags|=4096);return r}return h?(ii(),h=c.fallback,T=r.mode,A=t.child,D=A.sibling,c=Nn(A,{mode:"hidden",children:c.children}),c.subtreeFlags=A.subtreeFlags&65011712,D!==null?h=Nn(D,h):(h=Mi(h,T,l,null),h.flags|=2),h.return=r,c.return=r,c.sibling=h,r.child=c,c=h,h=r.child,T=t.child.memoizedState,T===null?T=Gu(l):(A=T.cachePool,A!==null?(D=Qe._currentValue,A=A.parent!==D?{parent:D,pool:D}:A):A=Np(),T={baseLanes:T.baseLanes|l,cachePool:A}),h.memoizedState=T,h.childLanes=Ku(t,S,l),r.memoizedState=Vu,c):(ni(r),l=t.child,t=l.sibling,l=Nn(l,{mode:"visible",children:c.children}),l.return=r,l.sibling=null,t!==null&&(S=r.deletions,S===null?(r.deletions=[t],r.flags|=16):S.push(t)),r.child=l,r.memoizedState=null,l)}function Yu(t,r){return r=Kl({mode:"visible",children:r},t.mode),r.return=t,t.child=r}function Kl(t,r){return t=$t(22,t,null,r),t.lanes=0,t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},t}function Xu(t,r,l){return Ls(r,t.child,null,l),t=Yu(r,r.pendingProps.children),t.flags|=2,r.memoizedState=null,t}function Ig(t,r,l){t.lanes|=r;var c=t.alternate;c!==null&&(c.lanes|=r),fu(t.return,r,l)}function Pu(t,r,l,c,h){var g=t.memoizedState;g===null?t.memoizedState={isBackwards:r,rendering:null,renderingStartTime:0,last:c,tail:l,tailMode:h}:(g.isBackwards=r,g.rendering=null,g.renderingStartTime=0,g.last=c,g.tail=l,g.tailMode=h)}function Vg(t,r,l){var c=r.pendingProps,h=c.revealOrder,g=c.tail;if(at(t,r,c.children,l),c=Ze.current,(c&2)!==0)c=c&1|2,r.flags|=128;else{if(t!==null&&(t.flags&128)!==0)e:for(t=r.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&Ig(t,l,r);else if(t.tag===19)Ig(t,l,r);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===r)break e;for(;t.sibling===null;){if(t.return===null||t.return===r)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}c&=1}switch(W(Ze,c),h){case"forwards":for(l=r.child,h=null;l!==null;)t=l.alternate,t!==null&&$l(t)===null&&(h=l),l=l.sibling;l=h,l===null?(h=r.child,r.child=null):(h=l.sibling,l.sibling=null),Pu(r,!1,h,l,g);break;case"backwards":for(l=null,h=r.child,r.child=null;h!==null;){if(t=h.alternate,t!==null&&$l(t)===null){r.child=h;break}t=h.sibling,h.sibling=l,l=h,h=t}Pu(r,!0,l,null,g);break;case"together":Pu(r,!1,null,null,void 0);break;default:r.memoizedState=null}return r.child}function Ln(t,r,l){if(t!==null&&(r.dependencies=t.dependencies),oi|=r.lanes,(l&r.childLanes)===0)if(t!==null){if(Gr(t,r,l,!1),(l&r.childLanes)===0)return null}else return null;if(t!==null&&r.child!==t.child)throw Error(s(153));if(r.child!==null){for(t=r.child,l=Nn(t,t.pendingProps),r.child=l,l.return=r;t.sibling!==null;)t=t.sibling,l=l.sibling=Nn(t,t.pendingProps),l.return=r;l.sibling=null}return r.child}function Fu(t,r){return(t.lanes&r)!==0?!0:(t=t.dependencies,!!(t!==null&&El(t)))}function _1(t,r,l){switch(r.tag){case 3:xe(r,r.stateNode.containerInfo),Zn(r,Qe,t.memoizedState.cache),Ir();break;case 27:case 5:rs(r);break;case 4:xe(r,r.stateNode.containerInfo);break;case 10:Zn(r,r.type,r.memoizedProps.value);break;case 13:var c=r.memoizedState;if(c!==null)return c.dehydrated!==null?(ni(r),r.flags|=128,null):(l&r.child.childLanes)!==0?$g(t,r,l):(ni(r),t=Ln(t,r,l),t!==null?t.sibling:null);ni(r);break;case 19:var h=(t.flags&128)!==0;if(c=(l&r.childLanes)!==0,c||(Gr(t,r,l,!1),c=(l&r.childLanes)!==0),h){if(c)return Vg(t,r,l);r.flags|=128}if(h=r.memoizedState,h!==null&&(h.rendering=null,h.tail=null,h.lastEffect=null),W(Ze,Ze.current),c)break;return null;case 22:case 23:return r.lanes=0,Bg(t,r,l);case 24:Zn(r,Qe,t.memoizedState.cache)}return Ln(t,r,l)}function Gg(t,r,l){if(t!==null)if(t.memoizedProps!==r.pendingProps)tt=!0;else{if(!Fu(t,l)&&(r.flags&128)===0)return tt=!1,_1(t,r,l);tt=(t.flags&131072)!==0}else tt=!1,Te&&(r.flags&1048576)!==0&&Sp(r,Tl,r.index);switch(r.lanes=0,r.tag){case 16:e:{t=r.pendingProps;var c=r.elementType,h=c._init;if(c=h(c._payload),r.type=c,typeof c=="function")su(c)?(t=Hi(c,t),r.tag=1,r=Hg(null,r,c,t,l)):(r.tag=0,r=Iu(null,r,c,t,l));else{if(c!=null){if(h=c.$$typeof,h===I){r.tag=11,r=jg(null,r,c,t,l);break e}else if(h===J){r.tag=14,r=Lg(null,r,c,t,l);break e}}throw r=ge(c)||c,Error(s(306,r,""))}}return r;case 0:return Iu(t,r,r.type,r.pendingProps,l);case 1:return c=r.type,h=Hi(c,r.pendingProps),Hg(t,r,c,h,l);case 3:e:{if(xe(r,r.stateNode.containerInfo),t===null)throw Error(s(387));c=r.pendingProps;var g=r.memoizedState;h=g.element,bu(t,r),Zr(r,c,null,l);var S=r.memoizedState;if(c=S.cache,Zn(r,Qe,c),c!==g.cache&&hu(r,[Qe],l,!0),Qr(),c=S.element,g.isDehydrated)if(g={element:c,isDehydrated:!1,cache:S.cache},r.updateQueue.baseState=g,r.memoizedState=g,r.flags&256){r=qg(t,r,c,l);break e}else if(c!==h){h=Qt(Error(s(424)),r),Vr(h),r=qg(t,r,c,l);break e}else{switch(t=r.stateNode.containerInfo,t.nodeType){case 9:t=t.body;break;default:t=t.nodeName==="HTML"?t.ownerDocument.body:t}for($e=fn(t.firstChild),St=r,Te=!0,ji=null,mn=!0,l=xg(r,null,c,l),r.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(Ir(),c===h){r=Ln(t,r,l);break e}at(t,r,c,l)}r=r.child}return r;case 26:return Gl(t,r),t===null?(l=Pm(r.type,null,r.pendingProps,null))?r.memoizedState=l:Te||(l=r.type,t=r.pendingProps,c=ro(ue.current).createElement(l),c[pt]=r,c[Nt]=t,ot(c,l,t),et(c),r.stateNode=c):r.memoizedState=Pm(r.type,t.memoizedProps,r.pendingProps,t.memoizedState),null;case 27:return rs(r),t===null&&Te&&(c=r.stateNode=Km(r.type,r.pendingProps,ue.current),St=r,mn=!0,h=$e,hi(r.type)?(Mf=h,$e=fn(c.firstChild)):$e=h),at(t,r,r.pendingProps.children,l),Gl(t,r),t===null&&(r.flags|=4194304),r.child;case 5:return t===null&&Te&&((h=c=$e)&&(c=Z1(c,r.type,r.pendingProps,mn),c!==null?(r.stateNode=c,St=r,$e=fn(c.firstChild),mn=!1,h=!0):h=!1),h||Li(r)),rs(r),h=r.type,g=r.pendingProps,S=t!==null?t.memoizedProps:null,c=g.children,Af(h,g)?c=null:S!==null&&Af(h,S)&&(r.flags|=32),r.memoizedState!==null&&(h=Tu(t,r,g1,null,null,l),va._currentValue=h),Gl(t,r),at(t,r,c,l),r.child;case 6:return t===null&&Te&&((t=l=$e)&&(l=J1(l,r.pendingProps,mn),l!==null?(r.stateNode=l,St=r,$e=null,t=!0):t=!1),t||Li(r)),null;case 13:return $g(t,r,l);case 4:return xe(r,r.stateNode.containerInfo),c=r.pendingProps,t===null?r.child=Ls(r,null,c,l):at(t,r,c,l),r.child;case 11:return jg(t,r,r.type,r.pendingProps,l);case 7:return at(t,r,r.pendingProps,l),r.child;case 8:return at(t,r,r.pendingProps.children,l),r.child;case 12:return at(t,r,r.pendingProps.children,l),r.child;case 10:return c=r.pendingProps,Zn(r,r.type,c.value),at(t,r,c.children,l),r.child;case 9:return h=r.type._context,c=r.pendingProps.children,Bi(r),h=gt(h),c=c(h),r.flags|=1,at(t,r,c,l),r.child;case 14:return Lg(t,r,r.type,r.pendingProps,l);case 15:return Dg(t,r,r.type,r.pendingProps,l);case 19:return Vg(t,r,l);case 31:return c=r.pendingProps,l=r.mode,c={mode:c.mode,children:c.children},t===null?(l=Kl(c,l),l.ref=r.ref,r.child=l,l.return=r,r=l):(l=Nn(t.child,c),l.ref=r.ref,r.child=l,l.return=r,r=l),r;case 22:return Bg(t,r,l);case 24:return Bi(r),c=gt(Qe),t===null?(h=gu(),h===null&&(h=je,g=du(),h.pooledCache=g,g.refCount++,g!==null&&(h.pooledCacheLanes|=l),h=g),r.memoizedState={parent:c,cache:h},yu(r),Zn(r,Qe,h)):((t.lanes&l)!==0&&(bu(t,r),Zr(r,null,null,l),Qr()),h=t.memoizedState,g=r.memoizedState,h.parent!==c?(h={parent:c,cache:c},r.memoizedState=h,r.lanes===0&&(r.memoizedState=r.updateQueue.baseState=h),Zn(r,Qe,c)):(c=g.cache,Zn(r,Qe,c),c!==h.cache&&hu(r,[Qe],l,!0))),at(t,r,r.pendingProps.children,l),r.child;case 29:throw r.pendingProps}throw Error(s(156,r.tag))}function Dn(t){t.flags|=4}function Kg(t,r){if(r.type!=="stylesheet"||(r.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!Wm(r)){if(r=en.current,r!==null&&((we&4194048)===we?yn!==null:(we&62914560)!==we&&(we&536870912)===0||r!==yn))throw Pr=mu,Cp;t.flags|=8192}}function Yl(t,r){r!==null&&(t.flags|=4),t.flags&16384&&(r=t.tag!==22?_d():536870912,t.lanes|=r,zs|=r)}function sa(t,r){if(!Te)switch(t.tailMode){case"hidden":r=t.tail;for(var l=null;r!==null;)r.alternate!==null&&(l=r),r=r.sibling;l===null?t.tail=null:l.sibling=null;break;case"collapsed":l=t.tail;for(var c=null;l!==null;)l.alternate!==null&&(c=l),l=l.sibling;c===null?r||t.tail===null?t.tail=null:t.tail.sibling=null:c.sibling=null}}function Ue(t){var r=t.alternate!==null&&t.alternate.child===t.child,l=0,c=0;if(r)for(var h=t.child;h!==null;)l|=h.lanes|h.childLanes,c|=h.subtreeFlags&65011712,c|=h.flags&65011712,h.return=t,h=h.sibling;else for(h=t.child;h!==null;)l|=h.lanes|h.childLanes,c|=h.subtreeFlags,c|=h.flags,h.return=t,h=h.sibling;return t.subtreeFlags|=c,t.childLanes=l,r}function T1(t,r,l){var c=r.pendingProps;switch(ou(r),r.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ue(r),null;case 1:return Ue(r),null;case 3:return l=r.stateNode,c=null,t!==null&&(c=t.memoizedState.cache),r.memoizedState.cache!==c&&(r.flags|=2048),On(Qe),gn(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(t===null||t.child===null)&&($r(r)?Dn(r):t===null||t.memoizedState.isDehydrated&&(r.flags&256)===0||(r.flags|=1024,_p())),Ue(r),null;case 26:return l=r.memoizedState,t===null?(Dn(r),l!==null?(Ue(r),Kg(r,l)):(Ue(r),r.flags&=-16777217)):l?l!==t.memoizedState?(Dn(r),Ue(r),Kg(r,l)):(Ue(r),r.flags&=-16777217):(t.memoizedProps!==c&&Dn(r),Ue(r),r.flags&=-16777217),null;case 27:ht(r),l=ue.current;var h=r.type;if(t!==null&&r.stateNode!=null)t.memoizedProps!==c&&Dn(r);else{if(!c){if(r.stateNode===null)throw Error(s(166));return Ue(r),null}t=se.current,$r(r)?wp(r):(t=Km(h,c,l),r.stateNode=t,Dn(r))}return Ue(r),null;case 5:if(ht(r),l=r.type,t!==null&&r.stateNode!=null)t.memoizedProps!==c&&Dn(r);else{if(!c){if(r.stateNode===null)throw Error(s(166));return Ue(r),null}if(t=se.current,$r(r))wp(r);else{switch(h=ro(ue.current),t){case 1:t=h.createElementNS("http://www.w3.org/2000/svg",l);break;case 2:t=h.createElementNS("http://www.w3.org/1998/Math/MathML",l);break;default:switch(l){case"svg":t=h.createElementNS("http://www.w3.org/2000/svg",l);break;case"math":t=h.createElementNS("http://www.w3.org/1998/Math/MathML",l);break;case"script":t=h.createElement("div"),t.innerHTML="<script><\/script>",t=t.removeChild(t.firstChild);break;case"select":t=typeof c.is=="string"?h.createElement("select",{is:c.is}):h.createElement("select"),c.multiple?t.multiple=!0:c.size&&(t.size=c.size);break;default:t=typeof c.is=="string"?h.createElement(l,{is:c.is}):h.createElement(l)}}t[pt]=r,t[Nt]=c;e:for(h=r.child;h!==null;){if(h.tag===5||h.tag===6)t.appendChild(h.stateNode);else if(h.tag!==4&&h.tag!==27&&h.child!==null){h.child.return=h,h=h.child;continue}if(h===r)break e;for(;h.sibling===null;){if(h.return===null||h.return===r)break e;h=h.return}h.sibling.return=h.return,h=h.sibling}r.stateNode=t;e:switch(ot(t,l,c),l){case"button":case"input":case"select":case"textarea":t=!!c.autoFocus;break e;case"img":t=!0;break e;default:t=!1}t&&Dn(r)}}return Ue(r),r.flags&=-16777217,null;case 6:if(t&&r.stateNode!=null)t.memoizedProps!==c&&Dn(r);else{if(typeof c!="string"&&r.stateNode===null)throw Error(s(166));if(t=ue.current,$r(r)){if(t=r.stateNode,l=r.memoizedProps,c=null,h=St,h!==null)switch(h.tag){case 27:case 5:c=h.memoizedProps}t[pt]=r,t=!!(t.nodeValue===l||c!==null&&c.suppressHydrationWarning===!0||zm(t.nodeValue,l)),t||Li(r)}else t=ro(t).createTextNode(c),t[pt]=r,r.stateNode=t}return Ue(r),null;case 13:if(c=r.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(h=$r(r),c!==null&&c.dehydrated!==null){if(t===null){if(!h)throw Error(s(318));if(h=r.memoizedState,h=h!==null?h.dehydrated:null,!h)throw Error(s(317));h[pt]=r}else Ir(),(r.flags&128)===0&&(r.memoizedState=null),r.flags|=4;Ue(r),h=!1}else h=_p(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=h),h=!0;if(!h)return r.flags&256?(jn(r),r):(jn(r),null)}if(jn(r),(r.flags&128)!==0)return r.lanes=l,r;if(l=c!==null,t=t!==null&&t.memoizedState!==null,l){c=r.child,h=null,c.alternate!==null&&c.alternate.memoizedState!==null&&c.alternate.memoizedState.cachePool!==null&&(h=c.alternate.memoizedState.cachePool.pool);var g=null;c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(g=c.memoizedState.cachePool.pool),g!==h&&(c.flags|=2048)}return l!==t&&l&&(r.child.flags|=8192),Yl(r,r.updateQueue),Ue(r),null;case 4:return gn(),t===null&&wf(r.stateNode.containerInfo),Ue(r),null;case 10:return On(r.type),Ue(r),null;case 19:if(Q(Ze),h=r.memoizedState,h===null)return Ue(r),null;if(c=(r.flags&128)!==0,g=h.rendering,g===null)if(c)sa(h,!1);else{if(Ie!==0||t!==null&&(t.flags&128)!==0)for(t=r.child;t!==null;){if(g=$l(t),g!==null){for(r.flags|=128,sa(h,!1),t=g.updateQueue,r.updateQueue=t,Yl(r,t),r.subtreeFlags=0,t=l,l=r.child;l!==null;)vp(l,t),l=l.sibling;return W(Ze,Ze.current&1|2),r.child}t=t.sibling}h.tail!==null&&Ht()>Fl&&(r.flags|=128,c=!0,sa(h,!1),r.lanes=4194304)}else{if(!c)if(t=$l(g),t!==null){if(r.flags|=128,c=!0,t=t.updateQueue,r.updateQueue=t,Yl(r,t),sa(h,!0),h.tail===null&&h.tailMode==="hidden"&&!g.alternate&&!Te)return Ue(r),null}else 2*Ht()-h.renderingStartTime>Fl&&l!==536870912&&(r.flags|=128,c=!0,sa(h,!1),r.lanes=4194304);h.isBackwards?(g.sibling=r.child,r.child=g):(t=h.last,t!==null?t.sibling=g:r.child=g,h.last=g)}return h.tail!==null?(r=h.tail,h.rendering=r,h.tail=r.sibling,h.renderingStartTime=Ht(),r.sibling=null,t=Ze.current,W(Ze,c?t&1|2:t&1),r):(Ue(r),null);case 22:case 23:return jn(r),xu(),c=r.memoizedState!==null,t!==null?t.memoizedState!==null!==c&&(r.flags|=8192):c&&(r.flags|=8192),c?(l&536870912)!==0&&(r.flags&128)===0&&(Ue(r),r.subtreeFlags&6&&(r.flags|=8192)):Ue(r),l=r.updateQueue,l!==null&&Yl(r,l.retryQueue),l=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),c=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(c=r.memoizedState.cachePool.pool),c!==l&&(r.flags|=2048),t!==null&&Q(Ui),null;case 24:return l=null,t!==null&&(l=t.memoizedState.cache),r.memoizedState.cache!==l&&(r.flags|=2048),On(Qe),Ue(r),null;case 25:return null;case 30:return null}throw Error(s(156,r.tag))}function E1(t,r){switch(ou(r),r.tag){case 1:return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 3:return On(Qe),gn(),t=r.flags,(t&65536)!==0&&(t&128)===0?(r.flags=t&-65537|128,r):null;case 26:case 27:case 5:return ht(r),null;case 13:if(jn(r),t=r.memoizedState,t!==null&&t.dehydrated!==null){if(r.alternate===null)throw Error(s(340));Ir()}return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 19:return Q(Ze),null;case 4:return gn(),null;case 10:return On(r.type),null;case 22:case 23:return jn(r),xu(),t!==null&&Q(Ui),t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 24:return On(Qe),null;case 25:return null;default:return null}}function Yg(t,r){switch(ou(r),r.tag){case 3:On(Qe),gn();break;case 26:case 27:case 5:ht(r);break;case 4:gn();break;case 13:jn(r);break;case 19:Q(Ze);break;case 10:On(r.type);break;case 22:case 23:jn(r),xu(),t!==null&&Q(Ui);break;case 24:On(Qe)}}function ra(t,r){try{var l=r.updateQueue,c=l!==null?l.lastEffect:null;if(c!==null){var h=c.next;l=h;do{if((l.tag&t)===t){c=void 0;var g=l.create,S=l.inst;c=g(),S.destroy=c}l=l.next}while(l!==h)}}catch(T){Oe(r,r.return,T)}}function si(t,r,l){try{var c=r.updateQueue,h=c!==null?c.lastEffect:null;if(h!==null){var g=h.next;c=g;do{if((c.tag&t)===t){var S=c.inst,T=S.destroy;if(T!==void 0){S.destroy=void 0,h=r;var A=l,D=T;try{D()}catch(K){Oe(h,A,K)}}}c=c.next}while(c!==g)}}catch(K){Oe(r,r.return,K)}}function Xg(t){var r=t.updateQueue;if(r!==null){var l=t.stateNode;try{Lp(r,l)}catch(c){Oe(t,t.return,c)}}}function Pg(t,r,l){l.props=Hi(t.type,t.memoizedProps),l.state=t.memoizedState;try{l.componentWillUnmount()}catch(c){Oe(t,r,c)}}function aa(t,r){try{var l=t.ref;if(l!==null){switch(t.tag){case 26:case 27:case 5:var c=t.stateNode;break;case 30:c=t.stateNode;break;default:c=t.stateNode}typeof l=="function"?t.refCleanup=l(c):l.current=c}}catch(h){Oe(t,r,h)}}function bn(t,r){var l=t.ref,c=t.refCleanup;if(l!==null)if(typeof c=="function")try{c()}catch(h){Oe(t,r,h)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(h){Oe(t,r,h)}else l.current=null}function Fg(t){var r=t.type,l=t.memoizedProps,c=t.stateNode;try{e:switch(r){case"button":case"input":case"select":case"textarea":l.autoFocus&&c.focus();break e;case"img":l.src?c.src=l.src:l.srcSet&&(c.srcset=l.srcSet)}}catch(h){Oe(t,t.return,h)}}function Qu(t,r,l){try{var c=t.stateNode;Y1(c,t.type,l,r),c[Nt]=r}catch(h){Oe(t,t.return,h)}}function Qg(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&hi(t.type)||t.tag===4}function Zu(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||Qg(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&hi(t.type)||t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Ju(t,r,l){var c=t.tag;if(c===5||c===6)t=t.stateNode,r?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(t,r):(r=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,r.appendChild(t),l=l._reactRootContainer,l!=null||r.onclick!==null||(r.onclick=so));else if(c!==4&&(c===27&&hi(t.type)&&(l=t.stateNode,r=null),t=t.child,t!==null))for(Ju(t,r,l),t=t.sibling;t!==null;)Ju(t,r,l),t=t.sibling}function Xl(t,r,l){var c=t.tag;if(c===5||c===6)t=t.stateNode,r?l.insertBefore(t,r):l.appendChild(t);else if(c!==4&&(c===27&&hi(t.type)&&(l=t.stateNode),t=t.child,t!==null))for(Xl(t,r,l),t=t.sibling;t!==null;)Xl(t,r,l),t=t.sibling}function Zg(t){var r=t.stateNode,l=t.memoizedProps;try{for(var c=t.type,h=r.attributes;h.length;)r.removeAttributeNode(h[0]);ot(r,c,l),r[pt]=t,r[Nt]=l}catch(g){Oe(t,t.return,g)}}var Bn=!1,Ge=!1,Wu=!1,Jg=typeof WeakSet=="function"?WeakSet:Set,nt=null;function A1(t,r){if(t=t.containerInfo,Tf=fo,t=cp(t),Zc(t)){if("selectionStart"in t)var l={start:t.selectionStart,end:t.selectionEnd};else e:{l=(l=t.ownerDocument)&&l.defaultView||window;var c=l.getSelection&&l.getSelection();if(c&&c.rangeCount!==0){l=c.anchorNode;var h=c.anchorOffset,g=c.focusNode;c=c.focusOffset;try{l.nodeType,g.nodeType}catch{l=null;break e}var S=0,T=-1,A=-1,D=0,K=0,P=t,z=null;t:for(;;){for(var H;P!==l||h!==0&&P.nodeType!==3||(T=S+h),P!==g||c!==0&&P.nodeType!==3||(A=S+c),P.nodeType===3&&(S+=P.nodeValue.length),(H=P.firstChild)!==null;)z=P,P=H;for(;;){if(P===t)break t;if(z===l&&++D===h&&(T=S),z===g&&++K===c&&(A=S),(H=P.nextSibling)!==null)break;P=z,z=P.parentNode}P=H}l=T===-1||A===-1?null:{start:T,end:A}}else l=null}l=l||{start:0,end:0}}else l=null;for(Ef={focusedElem:t,selectionRange:l},fo=!1,nt=r;nt!==null;)if(r=nt,t=r.child,(r.subtreeFlags&1024)!==0&&t!==null)t.return=r,nt=t;else for(;nt!==null;){switch(r=nt,g=r.alternate,t=r.flags,r.tag){case 0:break;case 11:case 15:break;case 1:if((t&1024)!==0&&g!==null){t=void 0,l=r,h=g.memoizedProps,g=g.memoizedState,c=l.stateNode;try{var ce=Hi(l.type,h,l.elementType===l.type);t=c.getSnapshotBeforeUpdate(ce,g),c.__reactInternalSnapshotBeforeUpdate=t}catch(ae){Oe(l,l.return,ae)}}break;case 3:if((t&1024)!==0){if(t=r.stateNode.containerInfo,l=t.nodeType,l===9)Cf(t);else if(l===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":Cf(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(s(163))}if(t=r.sibling,t!==null){t.return=r.return,nt=t;break}nt=r.return}}function Wg(t,r,l){var c=l.flags;switch(l.tag){case 0:case 11:case 15:ri(t,l),c&4&&ra(5,l);break;case 1:if(ri(t,l),c&4)if(t=l.stateNode,r===null)try{t.componentDidMount()}catch(S){Oe(l,l.return,S)}else{var h=Hi(l.type,r.memoizedProps);r=r.memoizedState;try{t.componentDidUpdate(h,r,t.__reactInternalSnapshotBeforeUpdate)}catch(S){Oe(l,l.return,S)}}c&64&&Xg(l),c&512&&aa(l,l.return);break;case 3:if(ri(t,l),c&64&&(t=l.updateQueue,t!==null)){if(r=null,l.child!==null)switch(l.child.tag){case 27:case 5:r=l.child.stateNode;break;case 1:r=l.child.stateNode}try{Lp(t,r)}catch(S){Oe(l,l.return,S)}}break;case 27:r===null&&c&4&&Zg(l);case 26:case 5:ri(t,l),r===null&&c&4&&Fg(l),c&512&&aa(l,l.return);break;case 12:ri(t,l);break;case 13:ri(t,l),c&4&&nm(t,l),c&64&&(t=l.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(l=D1.bind(null,l),W1(t,l))));break;case 22:if(c=l.memoizedState!==null||Bn,!c){r=r!==null&&r.memoizedState!==null||Ge,h=Bn;var g=Ge;Bn=c,(Ge=r)&&!g?ai(t,l,(l.subtreeFlags&8772)!==0):ri(t,l),Bn=h,Ge=g}break;case 30:break;default:ri(t,l)}}function em(t){var r=t.alternate;r!==null&&(t.alternate=null,em(r)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(r=t.stateNode,r!==null&&Rc(r)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var Le=null,Mt=!1;function Un(t,r,l){for(l=l.child;l!==null;)tm(t,r,l),l=l.sibling}function tm(t,r,l){if(vt&&typeof vt.onCommitFiberUnmount=="function")try{vt.onCommitFiberUnmount(Ti,l)}catch{}switch(l.tag){case 26:Ge||bn(l,r),Un(t,r,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:Ge||bn(l,r);var c=Le,h=Mt;hi(l.type)&&(Le=l.stateNode,Mt=!1),Un(t,r,l),ga(l.stateNode),Le=c,Mt=h;break;case 5:Ge||bn(l,r);case 6:if(c=Le,h=Mt,Le=null,Un(t,r,l),Le=c,Mt=h,Le!==null)if(Mt)try{(Le.nodeType===9?Le.body:Le.nodeName==="HTML"?Le.ownerDocument.body:Le).removeChild(l.stateNode)}catch(g){Oe(l,r,g)}else try{Le.removeChild(l.stateNode)}catch(g){Oe(l,r,g)}break;case 18:Le!==null&&(Mt?(t=Le,Vm(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,l.stateNode),_a(t)):Vm(Le,l.stateNode));break;case 4:c=Le,h=Mt,Le=l.stateNode.containerInfo,Mt=!0,Un(t,r,l),Le=c,Mt=h;break;case 0:case 11:case 14:case 15:Ge||si(2,l,r),Ge||si(4,l,r),Un(t,r,l);break;case 1:Ge||(bn(l,r),c=l.stateNode,typeof c.componentWillUnmount=="function"&&Pg(l,r,c)),Un(t,r,l);break;case 21:Un(t,r,l);break;case 22:Ge=(c=Ge)||l.memoizedState!==null,Un(t,r,l),Ge=c;break;default:Un(t,r,l)}}function nm(t,r){if(r.memoizedState===null&&(t=r.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{_a(t)}catch(l){Oe(r,r.return,l)}}function N1(t){switch(t.tag){case 13:case 19:var r=t.stateNode;return r===null&&(r=t.stateNode=new Jg),r;case 22:return t=t.stateNode,r=t._retryCache,r===null&&(r=t._retryCache=new Jg),r;default:throw Error(s(435,t.tag))}}function ef(t,r){var l=N1(t);r.forEach(function(c){var h=B1.bind(null,t,c);l.has(c)||(l.add(c),c.then(h,h))})}function It(t,r){var l=r.deletions;if(l!==null)for(var c=0;c<l.length;c++){var h=l[c],g=t,S=r,T=S;e:for(;T!==null;){switch(T.tag){case 27:if(hi(T.type)){Le=T.stateNode,Mt=!1;break e}break;case 5:Le=T.stateNode,Mt=!1;break e;case 3:case 4:Le=T.stateNode.containerInfo,Mt=!0;break e}T=T.return}if(Le===null)throw Error(s(160));tm(g,S,h),Le=null,Mt=!1,g=h.alternate,g!==null&&(g.return=null),h.return=null}if(r.subtreeFlags&13878)for(r=r.child;r!==null;)im(r,t),r=r.sibling}var un=null;function im(t,r){var l=t.alternate,c=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:It(r,t),Vt(t),c&4&&(si(3,t,t.return),ra(3,t),si(5,t,t.return));break;case 1:It(r,t),Vt(t),c&512&&(Ge||l===null||bn(l,l.return)),c&64&&Bn&&(t=t.updateQueue,t!==null&&(c=t.callbacks,c!==null&&(l=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=l===null?c:l.concat(c))));break;case 26:var h=un;if(It(r,t),Vt(t),c&512&&(Ge||l===null||bn(l,l.return)),c&4){var g=l!==null?l.memoizedState:null;if(c=t.memoizedState,l===null)if(c===null)if(t.stateNode===null){e:{c=t.type,l=t.memoizedProps,h=h.ownerDocument||h;t:switch(c){case"title":g=h.getElementsByTagName("title")[0],(!g||g[Mr]||g[pt]||g.namespaceURI==="http://www.w3.org/2000/svg"||g.hasAttribute("itemprop"))&&(g=h.createElement(c),h.head.insertBefore(g,h.querySelector("head > title"))),ot(g,c,l),g[pt]=t,et(g),c=g;break e;case"link":var S=Zm("link","href",h).get(c+(l.href||""));if(S){for(var T=0;T<S.length;T++)if(g=S[T],g.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&g.getAttribute("rel")===(l.rel==null?null:l.rel)&&g.getAttribute("title")===(l.title==null?null:l.title)&&g.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){S.splice(T,1);break t}}g=h.createElement(c),ot(g,c,l),h.head.appendChild(g);break;case"meta":if(S=Zm("meta","content",h).get(c+(l.content||""))){for(T=0;T<S.length;T++)if(g=S[T],g.getAttribute("content")===(l.content==null?null:""+l.content)&&g.getAttribute("name")===(l.name==null?null:l.name)&&g.getAttribute("property")===(l.property==null?null:l.property)&&g.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&g.getAttribute("charset")===(l.charSet==null?null:l.charSet)){S.splice(T,1);break t}}g=h.createElement(c),ot(g,c,l),h.head.appendChild(g);break;default:throw Error(s(468,c))}g[pt]=t,et(g),c=g}t.stateNode=c}else Jm(h,t.type,t.stateNode);else t.stateNode=Qm(h,c,t.memoizedProps);else g!==c?(g===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):g.count--,c===null?Jm(h,t.type,t.stateNode):Qm(h,c,t.memoizedProps)):c===null&&t.stateNode!==null&&Qu(t,t.memoizedProps,l.memoizedProps)}break;case 27:It(r,t),Vt(t),c&512&&(Ge||l===null||bn(l,l.return)),l!==null&&c&4&&Qu(t,t.memoizedProps,l.memoizedProps);break;case 5:if(It(r,t),Vt(t),c&512&&(Ge||l===null||bn(l,l.return)),t.flags&32){h=t.stateNode;try{ms(h,"")}catch(H){Oe(t,t.return,H)}}c&4&&t.stateNode!=null&&(h=t.memoizedProps,Qu(t,h,l!==null?l.memoizedProps:h)),c&1024&&(Wu=!0);break;case 6:if(It(r,t),Vt(t),c&4){if(t.stateNode===null)throw Error(s(162));c=t.memoizedProps,l=t.stateNode;try{l.nodeValue=c}catch(H){Oe(t,t.return,H)}}break;case 3:if(oo=null,h=un,un=ao(r.containerInfo),It(r,t),un=h,Vt(t),c&4&&l!==null&&l.memoizedState.isDehydrated)try{_a(r.containerInfo)}catch(H){Oe(t,t.return,H)}Wu&&(Wu=!1,sm(t));break;case 4:c=un,un=ao(t.stateNode.containerInfo),It(r,t),Vt(t),un=c;break;case 12:It(r,t),Vt(t);break;case 13:It(r,t),Vt(t),t.child.flags&8192&&t.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(lf=Ht()),c&4&&(c=t.updateQueue,c!==null&&(t.updateQueue=null,ef(t,c)));break;case 22:h=t.memoizedState!==null;var A=l!==null&&l.memoizedState!==null,D=Bn,K=Ge;if(Bn=D||h,Ge=K||A,It(r,t),Ge=K,Bn=D,Vt(t),c&8192)e:for(r=t.stateNode,r._visibility=h?r._visibility&-2:r._visibility|1,h&&(l===null||A||Bn||Ge||qi(t)),l=null,r=t;;){if(r.tag===5||r.tag===26){if(l===null){A=l=r;try{if(g=A.stateNode,h)S=g.style,typeof S.setProperty=="function"?S.setProperty("display","none","important"):S.display="none";else{T=A.stateNode;var P=A.memoizedProps.style,z=P!=null&&P.hasOwnProperty("display")?P.display:null;T.style.display=z==null||typeof z=="boolean"?"":(""+z).trim()}}catch(H){Oe(A,A.return,H)}}}else if(r.tag===6){if(l===null){A=r;try{A.stateNode.nodeValue=h?"":A.memoizedProps}catch(H){Oe(A,A.return,H)}}}else if((r.tag!==22&&r.tag!==23||r.memoizedState===null||r===t)&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break e;for(;r.sibling===null;){if(r.return===null||r.return===t)break e;l===r&&(l=null),r=r.return}l===r&&(l=null),r.sibling.return=r.return,r=r.sibling}c&4&&(c=t.updateQueue,c!==null&&(l=c.retryQueue,l!==null&&(c.retryQueue=null,ef(t,l))));break;case 19:It(r,t),Vt(t),c&4&&(c=t.updateQueue,c!==null&&(t.updateQueue=null,ef(t,c)));break;case 30:break;case 21:break;default:It(r,t),Vt(t)}}function Vt(t){var r=t.flags;if(r&2){try{for(var l,c=t.return;c!==null;){if(Qg(c)){l=c;break}c=c.return}if(l==null)throw Error(s(160));switch(l.tag){case 27:var h=l.stateNode,g=Zu(t);Xl(t,g,h);break;case 5:var S=l.stateNode;l.flags&32&&(ms(S,""),l.flags&=-33);var T=Zu(t);Xl(t,T,S);break;case 3:case 4:var A=l.stateNode.containerInfo,D=Zu(t);Ju(t,D,A);break;default:throw Error(s(161))}}catch(K){Oe(t,t.return,K)}t.flags&=-3}r&4096&&(t.flags&=-4097)}function sm(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var r=t;sm(r),r.tag===5&&r.flags&1024&&r.stateNode.reset(),t=t.sibling}}function ri(t,r){if(r.subtreeFlags&8772)for(r=r.child;r!==null;)Wg(t,r.alternate,r),r=r.sibling}function qi(t){for(t=t.child;t!==null;){var r=t;switch(r.tag){case 0:case 11:case 14:case 15:si(4,r,r.return),qi(r);break;case 1:bn(r,r.return);var l=r.stateNode;typeof l.componentWillUnmount=="function"&&Pg(r,r.return,l),qi(r);break;case 27:ga(r.stateNode);case 26:case 5:bn(r,r.return),qi(r);break;case 22:r.memoizedState===null&&qi(r);break;case 30:qi(r);break;default:qi(r)}t=t.sibling}}function ai(t,r,l){for(l=l&&(r.subtreeFlags&8772)!==0,r=r.child;r!==null;){var c=r.alternate,h=t,g=r,S=g.flags;switch(g.tag){case 0:case 11:case 15:ai(h,g,l),ra(4,g);break;case 1:if(ai(h,g,l),c=g,h=c.stateNode,typeof h.componentDidMount=="function")try{h.componentDidMount()}catch(D){Oe(c,c.return,D)}if(c=g,h=c.updateQueue,h!==null){var T=c.stateNode;try{var A=h.shared.hiddenCallbacks;if(A!==null)for(h.shared.hiddenCallbacks=null,h=0;h<A.length;h++)jp(A[h],T)}catch(D){Oe(c,c.return,D)}}l&&S&64&&Xg(g),aa(g,g.return);break;case 27:Zg(g);case 26:case 5:ai(h,g,l),l&&c===null&&S&4&&Fg(g),aa(g,g.return);break;case 12:ai(h,g,l);break;case 13:ai(h,g,l),l&&S&4&&nm(h,g);break;case 22:g.memoizedState===null&&ai(h,g,l),aa(g,g.return);break;case 30:break;default:ai(h,g,l)}r=r.sibling}}function tf(t,r){var l=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),t=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(t=r.memoizedState.cachePool.pool),t!==l&&(t!=null&&t.refCount++,l!=null&&Kr(l))}function nf(t,r){t=null,r.alternate!==null&&(t=r.alternate.memoizedState.cache),r=r.memoizedState.cache,r!==t&&(r.refCount++,t!=null&&Kr(t))}function vn(t,r,l,c){if(r.subtreeFlags&10256)for(r=r.child;r!==null;)rm(t,r,l,c),r=r.sibling}function rm(t,r,l,c){var h=r.flags;switch(r.tag){case 0:case 11:case 15:vn(t,r,l,c),h&2048&&ra(9,r);break;case 1:vn(t,r,l,c);break;case 3:vn(t,r,l,c),h&2048&&(t=null,r.alternate!==null&&(t=r.alternate.memoizedState.cache),r=r.memoizedState.cache,r!==t&&(r.refCount++,t!=null&&Kr(t)));break;case 12:if(h&2048){vn(t,r,l,c),t=r.stateNode;try{var g=r.memoizedProps,S=g.id,T=g.onPostCommit;typeof T=="function"&&T(S,r.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(A){Oe(r,r.return,A)}}else vn(t,r,l,c);break;case 13:vn(t,r,l,c);break;case 23:break;case 22:g=r.stateNode,S=r.alternate,r.memoizedState!==null?g._visibility&2?vn(t,r,l,c):la(t,r):g._visibility&2?vn(t,r,l,c):(g._visibility|=2,Ds(t,r,l,c,(r.subtreeFlags&10256)!==0)),h&2048&&tf(S,r);break;case 24:vn(t,r,l,c),h&2048&&nf(r.alternate,r);break;default:vn(t,r,l,c)}}function Ds(t,r,l,c,h){for(h=h&&(r.subtreeFlags&10256)!==0,r=r.child;r!==null;){var g=t,S=r,T=l,A=c,D=S.flags;switch(S.tag){case 0:case 11:case 15:Ds(g,S,T,A,h),ra(8,S);break;case 23:break;case 22:var K=S.stateNode;S.memoizedState!==null?K._visibility&2?Ds(g,S,T,A,h):la(g,S):(K._visibility|=2,Ds(g,S,T,A,h)),h&&D&2048&&tf(S.alternate,S);break;case 24:Ds(g,S,T,A,h),h&&D&2048&&nf(S.alternate,S);break;default:Ds(g,S,T,A,h)}r=r.sibling}}function la(t,r){if(r.subtreeFlags&10256)for(r=r.child;r!==null;){var l=t,c=r,h=c.flags;switch(c.tag){case 22:la(l,c),h&2048&&tf(c.alternate,c);break;case 24:la(l,c),h&2048&&nf(c.alternate,c);break;default:la(l,c)}r=r.sibling}}var oa=8192;function Bs(t){if(t.subtreeFlags&oa)for(t=t.child;t!==null;)am(t),t=t.sibling}function am(t){switch(t.tag){case 26:Bs(t),t.flags&oa&&t.memoizedState!==null&&hw(un,t.memoizedState,t.memoizedProps);break;case 5:Bs(t);break;case 3:case 4:var r=un;un=ao(t.stateNode.containerInfo),Bs(t),un=r;break;case 22:t.memoizedState===null&&(r=t.alternate,r!==null&&r.memoizedState!==null?(r=oa,oa=16777216,Bs(t),oa=r):Bs(t));break;default:Bs(t)}}function lm(t){var r=t.alternate;if(r!==null&&(t=r.child,t!==null)){r.child=null;do r=t.sibling,t.sibling=null,t=r;while(t!==null)}}function ca(t){var r=t.deletions;if((t.flags&16)!==0){if(r!==null)for(var l=0;l<r.length;l++){var c=r[l];nt=c,cm(c,t)}lm(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)om(t),t=t.sibling}function om(t){switch(t.tag){case 0:case 11:case 15:ca(t),t.flags&2048&&si(9,t,t.return);break;case 3:ca(t);break;case 12:ca(t);break;case 22:var r=t.stateNode;t.memoizedState!==null&&r._visibility&2&&(t.return===null||t.return.tag!==13)?(r._visibility&=-3,Pl(t)):ca(t);break;default:ca(t)}}function Pl(t){var r=t.deletions;if((t.flags&16)!==0){if(r!==null)for(var l=0;l<r.length;l++){var c=r[l];nt=c,cm(c,t)}lm(t)}for(t=t.child;t!==null;){switch(r=t,r.tag){case 0:case 11:case 15:si(8,r,r.return),Pl(r);break;case 22:l=r.stateNode,l._visibility&2&&(l._visibility&=-3,Pl(r));break;default:Pl(r)}t=t.sibling}}function cm(t,r){for(;nt!==null;){var l=nt;switch(l.tag){case 0:case 11:case 15:si(8,l,r);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var c=l.memoizedState.cachePool.pool;c!=null&&c.refCount++}break;case 24:Kr(l.memoizedState.cache)}if(c=l.child,c!==null)c.return=l,nt=c;else e:for(l=t;nt!==null;){c=nt;var h=c.sibling,g=c.return;if(em(c),c===l){nt=null;break e}if(h!==null){h.return=g,nt=h;break e}nt=g}}}var C1={getCacheForType:function(t){var r=gt(Qe),l=r.data.get(t);return l===void 0&&(l=t(),r.data.set(t,l)),l}},k1=typeof WeakMap=="function"?WeakMap:Map,Ee=0,je=null,ye=null,we=0,Ae=0,Gt=null,li=!1,Us=!1,sf=!1,zn=0,Ie=0,oi=0,$i=0,rf=0,tn=0,zs=0,ua=null,Ot=null,af=!1,lf=0,Fl=1/0,Ql=null,ci=null,lt=0,ui=null,Hs=null,qs=0,of=0,cf=null,um=null,fa=0,uf=null;function Kt(){if((Ee&2)!==0&&we!==0)return we&-we;if(q.T!==null){var t=Ns;return t!==0?t:yf()}return Ad()}function fm(){tn===0&&(tn=(we&536870912)===0||Te?xd():536870912);var t=en.current;return t!==null&&(t.flags|=32),tn}function Yt(t,r,l){(t===je&&(Ae===2||Ae===9)||t.cancelPendingCommit!==null)&&($s(t,0),fi(t,we,tn,!1)),kr(t,l),((Ee&2)===0||t!==je)&&(t===je&&((Ee&2)===0&&($i|=l),Ie===4&&fi(t,we,tn,!1)),Sn(t))}function hm(t,r,l){if((Ee&6)!==0)throw Error(s(327));var c=!l&&(r&124)===0&&(r&t.expiredLanes)===0||Cr(t,r),h=c?R1(t,r):df(t,r,!0),g=c;do{if(h===0){Us&&!c&&fi(t,r,0,!1);break}else{if(l=t.current.alternate,g&&!M1(l)){h=df(t,r,!1),g=!1;continue}if(h===2){if(g=r,t.errorRecoveryDisabledLanes&g)var S=0;else S=t.pendingLanes&-536870913,S=S!==0?S:S&536870912?536870912:0;if(S!==0){r=S;e:{var T=t;h=ua;var A=T.current.memoizedState.isDehydrated;if(A&&($s(T,S).flags|=256),S=df(T,S,!1),S!==2){if(sf&&!A){T.errorRecoveryDisabledLanes|=g,$i|=g,h=4;break e}g=Ot,Ot=h,g!==null&&(Ot===null?Ot=g:Ot.push.apply(Ot,g))}h=S}if(g=!1,h!==2)continue}}if(h===1){$s(t,0),fi(t,r,0,!0);break}e:{switch(c=t,g=h,g){case 0:case 1:throw Error(s(345));case 4:if((r&4194048)!==r)break;case 6:fi(c,r,tn,!li);break e;case 2:Ot=null;break;case 3:case 5:break;default:throw Error(s(329))}if((r&62914560)===r&&(h=lf+300-Ht(),10<h)){if(fi(c,r,tn,!li),At(c,0,!0)!==0)break e;c.timeoutHandle=$m(dm.bind(null,c,l,Ot,Ql,af,r,tn,$i,zs,li,g,2,-0,0),h);break e}dm(c,l,Ot,Ql,af,r,tn,$i,zs,li,g,0,-0,0)}}break}while(!0);Sn(t)}function dm(t,r,l,c,h,g,S,T,A,D,K,P,z,H){if(t.timeoutHandle=-1,P=r.subtreeFlags,(P&8192||(P&16785408)===16785408)&&(ba={stylesheets:null,count:0,unsuspend:fw},am(r),P=dw(),P!==null)){t.cancelPendingCommit=P(Sm.bind(null,t,r,g,l,c,h,S,T,A,K,1,z,H)),fi(t,g,S,!D);return}Sm(t,r,g,l,c,h,S,T,A)}function M1(t){for(var r=t;;){var l=r.tag;if((l===0||l===11||l===15)&&r.flags&16384&&(l=r.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var c=0;c<l.length;c++){var h=l[c],g=h.getSnapshot;h=h.value;try{if(!qt(g(),h))return!1}catch{return!1}}if(l=r.child,r.subtreeFlags&16384&&l!==null)l.return=r,r=l;else{if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return!0;r=r.return}r.sibling.return=r.return,r=r.sibling}}return!0}function fi(t,r,l,c){r&=~rf,r&=~$i,t.suspendedLanes|=r,t.pingedLanes&=~r,c&&(t.warmLanes|=r),c=t.expirationTimes;for(var h=r;0<h;){var g=31-rt(h),S=1<<g;c[g]=-1,h&=~S}l!==0&&Td(t,l,r)}function Zl(){return(Ee&6)===0?(ha(0),!1):!0}function ff(){if(ye!==null){if(Ae===0)var t=ye.return;else t=ye,Mn=Di=null,Nu(t),js=null,na=0,t=ye;for(;t!==null;)Yg(t.alternate,t),t=t.return;ye=null}}function $s(t,r){var l=t.timeoutHandle;l!==-1&&(t.timeoutHandle=-1,P1(l)),l=t.cancelPendingCommit,l!==null&&(t.cancelPendingCommit=null,l()),ff(),je=t,ye=l=Nn(t.current,null),we=r,Ae=0,Gt=null,li=!1,Us=Cr(t,r),sf=!1,zs=tn=rf=$i=oi=Ie=0,Ot=ua=null,af=!1,(r&8)!==0&&(r|=r&32);var c=t.entangledLanes;if(c!==0)for(t=t.entanglements,c&=r;0<c;){var h=31-rt(c),g=1<<h;r|=t[h],c&=~g}return zn=r,vl(),l}function pm(t,r){de=null,q.H=zl,r===Xr||r===Cl?(r=Op(),Ae=3):r===Cp?(r=Op(),Ae=4):Ae=r===Rg?8:r!==null&&typeof r=="object"&&typeof r.then=="function"?6:1,Gt=r,ye===null&&(Ie=1,Vl(t,Qt(r,t.current)))}function gm(){var t=q.H;return q.H=zl,t===null?zl:t}function mm(){var t=q.A;return q.A=C1,t}function hf(){Ie=4,li||(we&4194048)!==we&&en.current!==null||(Us=!0),(oi&134217727)===0&&($i&134217727)===0||je===null||fi(je,we,tn,!1)}function df(t,r,l){var c=Ee;Ee|=2;var h=gm(),g=mm();(je!==t||we!==r)&&(Ql=null,$s(t,r)),r=!1;var S=Ie;e:do try{if(Ae!==0&&ye!==null){var T=ye,A=Gt;switch(Ae){case 8:ff(),S=6;break e;case 3:case 2:case 9:case 6:en.current===null&&(r=!0);var D=Ae;if(Ae=0,Gt=null,Is(t,T,A,D),l&&Us){S=0;break e}break;default:D=Ae,Ae=0,Gt=null,Is(t,T,A,D)}}O1(),S=Ie;break}catch(K){pm(t,K)}while(!0);return r&&t.shellSuspendCounter++,Mn=Di=null,Ee=c,q.H=h,q.A=g,ye===null&&(je=null,we=0,vl()),S}function O1(){for(;ye!==null;)ym(ye)}function R1(t,r){var l=Ee;Ee|=2;var c=gm(),h=mm();je!==t||we!==r?(Ql=null,Fl=Ht()+500,$s(t,r)):Us=Cr(t,r);e:do try{if(Ae!==0&&ye!==null){r=ye;var g=Gt;t:switch(Ae){case 1:Ae=0,Gt=null,Is(t,r,g,1);break;case 2:case 9:if(kp(g)){Ae=0,Gt=null,bm(r);break}r=function(){Ae!==2&&Ae!==9||je!==t||(Ae=7),Sn(t)},g.then(r,r);break e;case 3:Ae=7;break e;case 4:Ae=5;break e;case 7:kp(g)?(Ae=0,Gt=null,bm(r)):(Ae=0,Gt=null,Is(t,r,g,7));break;case 5:var S=null;switch(ye.tag){case 26:S=ye.memoizedState;case 5:case 27:var T=ye;if(!S||Wm(S)){Ae=0,Gt=null;var A=T.sibling;if(A!==null)ye=A;else{var D=T.return;D!==null?(ye=D,Jl(D)):ye=null}break t}}Ae=0,Gt=null,Is(t,r,g,5);break;case 6:Ae=0,Gt=null,Is(t,r,g,6);break;case 8:ff(),Ie=6;break e;default:throw Error(s(462))}}j1();break}catch(K){pm(t,K)}while(!0);return Mn=Di=null,q.H=c,q.A=h,Ee=l,ye!==null?0:(je=null,we=0,vl(),Ie)}function j1(){for(;ye!==null&&!Er();)ym(ye)}function ym(t){var r=Gg(t.alternate,t,zn);t.memoizedProps=t.pendingProps,r===null?Jl(t):ye=r}function bm(t){var r=t,l=r.alternate;switch(r.tag){case 15:case 0:r=zg(l,r,r.pendingProps,r.type,void 0,we);break;case 11:r=zg(l,r,r.pendingProps,r.type.render,r.ref,we);break;case 5:Nu(r);default:Yg(l,r),r=ye=vp(r,zn),r=Gg(l,r,zn)}t.memoizedProps=t.pendingProps,r===null?Jl(t):ye=r}function Is(t,r,l,c){Mn=Di=null,Nu(r),js=null,na=0;var h=r.return;try{if(x1(t,h,r,l,we)){Ie=1,Vl(t,Qt(l,t.current)),ye=null;return}}catch(g){if(h!==null)throw ye=h,g;Ie=1,Vl(t,Qt(l,t.current)),ye=null;return}r.flags&32768?(Te||c===1?t=!0:Us||(we&536870912)!==0?t=!1:(li=t=!0,(c===2||c===9||c===3||c===6)&&(c=en.current,c!==null&&c.tag===13&&(c.flags|=16384))),vm(r,t)):Jl(r)}function Jl(t){var r=t;do{if((r.flags&32768)!==0){vm(r,li);return}t=r.return;var l=T1(r.alternate,r,zn);if(l!==null){ye=l;return}if(r=r.sibling,r!==null){ye=r;return}ye=r=t}while(r!==null);Ie===0&&(Ie=5)}function vm(t,r){do{var l=E1(t.alternate,t);if(l!==null){l.flags&=32767,ye=l;return}if(l=t.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!r&&(t=t.sibling,t!==null)){ye=t;return}ye=t=l}while(t!==null);Ie=6,ye=null}function Sm(t,r,l,c,h,g,S,T,A){t.cancelPendingCommit=null;do Wl();while(lt!==0);if((Ee&6)!==0)throw Error(s(327));if(r!==null){if(r===t.current)throw Error(s(177));if(g=r.lanes|r.childLanes,g|=nu,fS(t,l,g,S,T,A),t===je&&(ye=je=null,we=0),Hs=r,ui=t,qs=l,of=g,cf=h,um=c,(r.subtreeFlags&10256)!==0||(r.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,U1(ls,function(){return Em(),null})):(t.callbackNode=null,t.callbackPriority=0),c=(r.flags&13878)!==0,(r.subtreeFlags&13878)!==0||c){c=q.T,q.T=null,h=Z.p,Z.p=2,S=Ee,Ee|=4;try{A1(t,r,l)}finally{Ee=S,Z.p=h,q.T=c}}lt=1,wm(),xm(),_m()}}function wm(){if(lt===1){lt=0;var t=ui,r=Hs,l=(r.flags&13878)!==0;if((r.subtreeFlags&13878)!==0||l){l=q.T,q.T=null;var c=Z.p;Z.p=2;var h=Ee;Ee|=4;try{im(r,t);var g=Ef,S=cp(t.containerInfo),T=g.focusedElem,A=g.selectionRange;if(S!==T&&T&&T.ownerDocument&&op(T.ownerDocument.documentElement,T)){if(A!==null&&Zc(T)){var D=A.start,K=A.end;if(K===void 0&&(K=D),"selectionStart"in T)T.selectionStart=D,T.selectionEnd=Math.min(K,T.value.length);else{var P=T.ownerDocument||document,z=P&&P.defaultView||window;if(z.getSelection){var H=z.getSelection(),ce=T.textContent.length,ae=Math.min(A.start,ce),Me=A.end===void 0?ae:Math.min(A.end,ce);!H.extend&&ae>Me&&(S=Me,Me=ae,ae=S);var O=lp(T,ae),M=lp(T,Me);if(O&&M&&(H.rangeCount!==1||H.anchorNode!==O.node||H.anchorOffset!==O.offset||H.focusNode!==M.node||H.focusOffset!==M.offset)){var L=P.createRange();L.setStart(O.node,O.offset),H.removeAllRanges(),ae>Me?(H.addRange(L),H.extend(M.node,M.offset)):(L.setEnd(M.node,M.offset),H.addRange(L))}}}}for(P=[],H=T;H=H.parentNode;)H.nodeType===1&&P.push({element:H,left:H.scrollLeft,top:H.scrollTop});for(typeof T.focus=="function"&&T.focus(),T=0;T<P.length;T++){var Y=P[T];Y.element.scrollLeft=Y.left,Y.element.scrollTop=Y.top}}fo=!!Tf,Ef=Tf=null}finally{Ee=h,Z.p=c,q.T=l}}t.current=r,lt=2}}function xm(){if(lt===2){lt=0;var t=ui,r=Hs,l=(r.flags&8772)!==0;if((r.subtreeFlags&8772)!==0||l){l=q.T,q.T=null;var c=Z.p;Z.p=2;var h=Ee;Ee|=4;try{Wg(t,r.alternate,r)}finally{Ee=h,Z.p=c,q.T=l}}lt=3}}function _m(){if(lt===4||lt===3){lt=0,rl();var t=ui,r=Hs,l=qs,c=um;(r.subtreeFlags&10256)!==0||(r.flags&10256)!==0?lt=5:(lt=0,Hs=ui=null,Tm(t,t.pendingLanes));var h=t.pendingLanes;if(h===0&&(ci=null),Mc(l),r=r.stateNode,vt&&typeof vt.onCommitFiberRoot=="function")try{vt.onCommitFiberRoot(Ti,r,void 0,(r.current.flags&128)===128)}catch{}if(c!==null){r=q.T,h=Z.p,Z.p=2,q.T=null;try{for(var g=t.onRecoverableError,S=0;S<c.length;S++){var T=c[S];g(T.value,{componentStack:T.stack})}}finally{q.T=r,Z.p=h}}(qs&3)!==0&&Wl(),Sn(t),h=t.pendingLanes,(l&4194090)!==0&&(h&42)!==0?t===uf?fa++:(fa=0,uf=t):fa=0,ha(0)}}function Tm(t,r){(t.pooledCacheLanes&=r)===0&&(r=t.pooledCache,r!=null&&(t.pooledCache=null,Kr(r)))}function Wl(t){return wm(),xm(),_m(),Em()}function Em(){if(lt!==5)return!1;var t=ui,r=of;of=0;var l=Mc(qs),c=q.T,h=Z.p;try{Z.p=32>l?32:l,q.T=null,l=cf,cf=null;var g=ui,S=qs;if(lt=0,Hs=ui=null,qs=0,(Ee&6)!==0)throw Error(s(331));var T=Ee;if(Ee|=4,om(g.current),rm(g,g.current,S,l),Ee=T,ha(0,!1),vt&&typeof vt.onPostCommitFiberRoot=="function")try{vt.onPostCommitFiberRoot(Ti,g)}catch{}return!0}finally{Z.p=h,q.T=c,Tm(t,r)}}function Am(t,r,l){r=Qt(l,r),r=$u(t.stateNode,r,2),t=ei(t,r,2),t!==null&&(kr(t,2),Sn(t))}function Oe(t,r,l){if(t.tag===3)Am(t,t,l);else for(;r!==null;){if(r.tag===3){Am(r,t,l);break}else if(r.tag===1){var c=r.stateNode;if(typeof r.type.getDerivedStateFromError=="function"||typeof c.componentDidCatch=="function"&&(ci===null||!ci.has(c))){t=Qt(l,t),l=Mg(2),c=ei(r,l,2),c!==null&&(Og(l,c,r,t),kr(c,2),Sn(c));break}}r=r.return}}function pf(t,r,l){var c=t.pingCache;if(c===null){c=t.pingCache=new k1;var h=new Set;c.set(r,h)}else h=c.get(r),h===void 0&&(h=new Set,c.set(r,h));h.has(l)||(sf=!0,h.add(l),t=L1.bind(null,t,r,l),r.then(t,t))}function L1(t,r,l){var c=t.pingCache;c!==null&&c.delete(r),t.pingedLanes|=t.suspendedLanes&l,t.warmLanes&=~l,je===t&&(we&l)===l&&(Ie===4||Ie===3&&(we&62914560)===we&&300>Ht()-lf?(Ee&2)===0&&$s(t,0):rf|=l,zs===we&&(zs=0)),Sn(t)}function Nm(t,r){r===0&&(r=_d()),t=_s(t,r),t!==null&&(kr(t,r),Sn(t))}function D1(t){var r=t.memoizedState,l=0;r!==null&&(l=r.retryLane),Nm(t,l)}function B1(t,r){var l=0;switch(t.tag){case 13:var c=t.stateNode,h=t.memoizedState;h!==null&&(l=h.retryLane);break;case 19:c=t.stateNode;break;case 22:c=t.stateNode._retryCache;break;default:throw Error(s(314))}c!==null&&c.delete(r),Nm(t,l)}function U1(t,r){return _r(t,r)}var eo=null,Vs=null,gf=!1,to=!1,mf=!1,Ii=0;function Sn(t){t!==Vs&&t.next===null&&(Vs===null?eo=Vs=t:Vs=Vs.next=t),to=!0,gf||(gf=!0,H1())}function ha(t,r){if(!mf&&to){mf=!0;do for(var l=!1,c=eo;c!==null;){if(t!==0){var h=c.pendingLanes;if(h===0)var g=0;else{var S=c.suspendedLanes,T=c.pingedLanes;g=(1<<31-rt(42|t)+1)-1,g&=h&~(S&~T),g=g&201326741?g&201326741|1:g?g|2:0}g!==0&&(l=!0,Om(c,g))}else g=we,g=At(c,c===je?g:0,c.cancelPendingCommit!==null||c.timeoutHandle!==-1),(g&3)===0||Cr(c,g)||(l=!0,Om(c,g));c=c.next}while(l);mf=!1}}function z1(){Cm()}function Cm(){to=gf=!1;var t=0;Ii!==0&&(X1()&&(t=Ii),Ii=0);for(var r=Ht(),l=null,c=eo;c!==null;){var h=c.next,g=km(c,r);g===0?(c.next=null,l===null?eo=h:l.next=h,h===null&&(Vs=l)):(l=c,(t!==0||(g&3)!==0)&&(to=!0)),c=h}ha(t)}function km(t,r){for(var l=t.suspendedLanes,c=t.pingedLanes,h=t.expirationTimes,g=t.pendingLanes&-62914561;0<g;){var S=31-rt(g),T=1<<S,A=h[S];A===-1?((T&l)===0||(T&c)!==0)&&(h[S]=uS(T,r)):A<=r&&(t.expiredLanes|=T),g&=~T}if(r=je,l=we,l=At(t,t===r?l:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),c=t.callbackNode,l===0||t===r&&(Ae===2||Ae===9)||t.cancelPendingCommit!==null)return c!==null&&c!==null&&Tr(c),t.callbackNode=null,t.callbackPriority=0;if((l&3)===0||Cr(t,l)){if(r=l&-l,r===t.callbackPriority)return r;switch(c!==null&&Tr(c),Mc(l)){case 2:case 8:l=ll;break;case 32:l=ls;break;case 268435456:l=Ar;break;default:l=ls}return c=Mm.bind(null,t),l=_r(l,c),t.callbackPriority=r,t.callbackNode=l,r}return c!==null&&c!==null&&Tr(c),t.callbackPriority=2,t.callbackNode=null,2}function Mm(t,r){if(lt!==0&<!==5)return t.callbackNode=null,t.callbackPriority=0,null;var l=t.callbackNode;if(Wl()&&t.callbackNode!==l)return null;var c=we;return c=At(t,t===je?c:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),c===0?null:(hm(t,c,r),km(t,Ht()),t.callbackNode!=null&&t.callbackNode===l?Mm.bind(null,t):null)}function Om(t,r){if(Wl())return null;hm(t,r,!0)}function H1(){F1(function(){(Ee&6)!==0?_r(al,z1):Cm()})}function yf(){return Ii===0&&(Ii=xd()),Ii}function Rm(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:hl(""+t)}function jm(t,r){var l=r.ownerDocument.createElement("input");return l.name=r.name,l.value=r.value,t.id&&l.setAttribute("form",t.id),r.parentNode.insertBefore(l,r),t=new FormData(t),l.parentNode.removeChild(l),t}function q1(t,r,l,c,h){if(r==="submit"&&l&&l.stateNode===h){var g=Rm((h[Nt]||null).action),S=c.submitter;S&&(r=(r=S[Nt]||null)?Rm(r.formAction):S.getAttribute("formAction"),r!==null&&(g=r,S=null));var T=new ml("action","action",null,c,h);t.push({event:T,listeners:[{instance:null,listener:function(){if(c.defaultPrevented){if(Ii!==0){var A=S?jm(h,S):new FormData(h);Bu(l,{pending:!0,data:A,method:h.method,action:g},null,A)}}else typeof g=="function"&&(T.preventDefault(),A=S?jm(h,S):new FormData(h),Bu(l,{pending:!0,data:A,method:h.method,action:g},g,A))},currentTarget:h}]})}}for(var bf=0;bf<tu.length;bf++){var vf=tu[bf],$1=vf.toLowerCase(),I1=vf[0].toUpperCase()+vf.slice(1);cn($1,"on"+I1)}cn(hp,"onAnimationEnd"),cn(dp,"onAnimationIteration"),cn(pp,"onAnimationStart"),cn("dblclick","onDoubleClick"),cn("focusin","onFocus"),cn("focusout","onBlur"),cn(r1,"onTransitionRun"),cn(a1,"onTransitionStart"),cn(l1,"onTransitionCancel"),cn(gp,"onTransitionEnd"),ds("onMouseEnter",["mouseout","mouseover"]),ds("onMouseLeave",["mouseout","mouseover"]),ds("onPointerEnter",["pointerout","pointerover"]),ds("onPointerLeave",["pointerout","pointerover"]),Ai("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ai("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ai("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ai("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ai("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ai("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var da="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),V1=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(da));function Lm(t,r){r=(r&4)!==0;for(var l=0;l<t.length;l++){var c=t[l],h=c.event;c=c.listeners;e:{var g=void 0;if(r)for(var S=c.length-1;0<=S;S--){var T=c[S],A=T.instance,D=T.currentTarget;if(T=T.listener,A!==g&&h.isPropagationStopped())break e;g=T,h.currentTarget=D;try{g(h)}catch(K){Il(K)}h.currentTarget=null,g=A}else for(S=0;S<c.length;S++){if(T=c[S],A=T.instance,D=T.currentTarget,T=T.listener,A!==g&&h.isPropagationStopped())break e;g=T,h.currentTarget=D;try{g(h)}catch(K){Il(K)}h.currentTarget=null,g=A}}}}function be(t,r){var l=r[Oc];l===void 0&&(l=r[Oc]=new Set);var c=t+"__bubble";l.has(c)||(Dm(r,t,2,!1),l.add(c))}function Sf(t,r,l){var c=0;r&&(c|=4),Dm(l,t,c,r)}var no="_reactListening"+Math.random().toString(36).slice(2);function wf(t){if(!t[no]){t[no]=!0,Cd.forEach(function(l){l!=="selectionchange"&&(V1.has(l)||Sf(l,!1,t),Sf(l,!0,t))});var r=t.nodeType===9?t:t.ownerDocument;r===null||r[no]||(r[no]=!0,Sf("selectionchange",!1,r))}}function Dm(t,r,l,c){switch(ry(r)){case 2:var h=mw;break;case 8:h=yw;break;default:h=Df}l=h.bind(null,r,l,t),h=void 0,!Ic||r!=="touchstart"&&r!=="touchmove"&&r!=="wheel"||(h=!0),c?h!==void 0?t.addEventListener(r,l,{capture:!0,passive:h}):t.addEventListener(r,l,!0):h!==void 0?t.addEventListener(r,l,{passive:h}):t.addEventListener(r,l,!1)}function xf(t,r,l,c,h){var g=c;if((r&1)===0&&(r&2)===0&&c!==null)e:for(;;){if(c===null)return;var S=c.tag;if(S===3||S===4){var T=c.stateNode.containerInfo;if(T===h)break;if(S===4)for(S=c.return;S!==null;){var A=S.tag;if((A===3||A===4)&&S.stateNode.containerInfo===h)return;S=S.return}for(;T!==null;){if(S=us(T),S===null)return;if(A=S.tag,A===5||A===6||A===26||A===27){c=g=S;continue e}T=T.parentNode}}c=c.return}Id(function(){var D=g,K=qc(l),P=[];e:{var z=mp.get(t);if(z!==void 0){var H=ml,ce=t;switch(t){case"keypress":if(pl(l)===0)break e;case"keydown":case"keyup":H=US;break;case"focusin":ce="focus",H=Yc;break;case"focusout":ce="blur",H=Yc;break;case"beforeblur":case"afterblur":H=Yc;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":H=Kd;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":H=ES;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":H=qS;break;case hp:case dp:case pp:H=CS;break;case gp:H=IS;break;case"scroll":case"scrollend":H=_S;break;case"wheel":H=GS;break;case"copy":case"cut":case"paste":H=MS;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":H=Xd;break;case"toggle":case"beforetoggle":H=YS}var ae=(r&4)!==0,Me=!ae&&(t==="scroll"||t==="scrollend"),O=ae?z!==null?z+"Capture":null:z;ae=[];for(var M=D,L;M!==null;){var Y=M;if(L=Y.stateNode,Y=Y.tag,Y!==5&&Y!==26&&Y!==27||L===null||O===null||(Y=Rr(M,O),Y!=null&&ae.push(pa(M,Y,L))),Me)break;M=M.return}0<ae.length&&(z=new H(z,ce,null,l,K),P.push({event:z,listeners:ae}))}}if((r&7)===0){e:{if(z=t==="mouseover"||t==="pointerover",H=t==="mouseout"||t==="pointerout",z&&l!==Hc&&(ce=l.relatedTarget||l.fromElement)&&(us(ce)||ce[cs]))break e;if((H||z)&&(z=K.window===K?K:(z=K.ownerDocument)?z.defaultView||z.parentWindow:window,H?(ce=l.relatedTarget||l.toElement,H=D,ce=ce?us(ce):null,ce!==null&&(Me=o(ce),ae=ce.tag,ce!==Me||ae!==5&&ae!==27&&ae!==6)&&(ce=null)):(H=null,ce=D),H!==ce)){if(ae=Kd,Y="onMouseLeave",O="onMouseEnter",M="mouse",(t==="pointerout"||t==="pointerover")&&(ae=Xd,Y="onPointerLeave",O="onPointerEnter",M="pointer"),Me=H==null?z:Or(H),L=ce==null?z:Or(ce),z=new ae(Y,M+"leave",H,l,K),z.target=Me,z.relatedTarget=L,Y=null,us(K)===D&&(ae=new ae(O,M+"enter",ce,l,K),ae.target=L,ae.relatedTarget=Me,Y=ae),Me=Y,H&&ce)t:{for(ae=H,O=ce,M=0,L=ae;L;L=Gs(L))M++;for(L=0,Y=O;Y;Y=Gs(Y))L++;for(;0<M-L;)ae=Gs(ae),M--;for(;0<L-M;)O=Gs(O),L--;for(;M--;){if(ae===O||O!==null&&ae===O.alternate)break t;ae=Gs(ae),O=Gs(O)}ae=null}else ae=null;H!==null&&Bm(P,z,H,ae,!1),ce!==null&&Me!==null&&Bm(P,Me,ce,ae,!0)}}e:{if(z=D?Or(D):window,H=z.nodeName&&z.nodeName.toLowerCase(),H==="select"||H==="input"&&z.type==="file")var te=tp;else if(Wd(z))if(np)te=n1;else{te=e1;var pe=WS}else H=z.nodeName,!H||H.toLowerCase()!=="input"||z.type!=="checkbox"&&z.type!=="radio"?D&&zc(D.elementType)&&(te=tp):te=t1;if(te&&(te=te(t,D))){ep(P,te,l,K);break e}pe&&pe(t,z,D),t==="focusout"&&D&&z.type==="number"&&D.memoizedProps.value!=null&&Uc(z,"number",z.value)}switch(pe=D?Or(D):window,t){case"focusin":(Wd(pe)||pe.contentEditable==="true")&&(Ss=pe,Jc=D,qr=null);break;case"focusout":qr=Jc=Ss=null;break;case"mousedown":Wc=!0;break;case"contextmenu":case"mouseup":case"dragend":Wc=!1,up(P,l,K);break;case"selectionchange":if(s1)break;case"keydown":case"keyup":up(P,l,K)}var ie;if(Pc)e:{switch(t){case"compositionstart":var oe="onCompositionStart";break e;case"compositionend":oe="onCompositionEnd";break e;case"compositionupdate":oe="onCompositionUpdate";break e}oe=void 0}else vs?Zd(t,l)&&(oe="onCompositionEnd"):t==="keydown"&&l.keyCode===229&&(oe="onCompositionStart");oe&&(Pd&&l.locale!=="ko"&&(vs||oe!=="onCompositionStart"?oe==="onCompositionEnd"&&vs&&(ie=Vd()):(Qn=K,Vc="value"in Qn?Qn.value:Qn.textContent,vs=!0)),pe=io(D,oe),0<pe.length&&(oe=new Yd(oe,t,null,l,K),P.push({event:oe,listeners:pe}),ie?oe.data=ie:(ie=Jd(l),ie!==null&&(oe.data=ie)))),(ie=PS?FS(t,l):QS(t,l))&&(oe=io(D,"onBeforeInput"),0<oe.length&&(pe=new Yd("onBeforeInput","beforeinput",null,l,K),P.push({event:pe,listeners:oe}),pe.data=ie)),q1(P,t,D,l,K)}Lm(P,r)})}function pa(t,r,l){return{instance:t,listener:r,currentTarget:l}}function io(t,r){for(var l=r+"Capture",c=[];t!==null;){var h=t,g=h.stateNode;if(h=h.tag,h!==5&&h!==26&&h!==27||g===null||(h=Rr(t,l),h!=null&&c.unshift(pa(t,h,g)),h=Rr(t,r),h!=null&&c.push(pa(t,h,g))),t.tag===3)return c;t=t.return}return[]}function Gs(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function Bm(t,r,l,c,h){for(var g=r._reactName,S=[];l!==null&&l!==c;){var T=l,A=T.alternate,D=T.stateNode;if(T=T.tag,A!==null&&A===c)break;T!==5&&T!==26&&T!==27||D===null||(A=D,h?(D=Rr(l,g),D!=null&&S.unshift(pa(l,D,A))):h||(D=Rr(l,g),D!=null&&S.push(pa(l,D,A)))),l=l.return}S.length!==0&&t.push({event:r,listeners:S})}var G1=/\r\n?/g,K1=/\u0000|\uFFFD/g;function Um(t){return(typeof t=="string"?t:""+t).replace(G1,`
|
|
50
|
-
`).replace(K1,"")}function zm(t,r){return r=Um(r),Um(t)===r}function so(){}function ke(t,r,l,c,h,g){switch(l){case"children":typeof c=="string"?r==="body"||r==="textarea"&&c===""||ms(t,c):(typeof c=="number"||typeof c=="bigint")&&r!=="body"&&ms(t,""+c);break;case"className":cl(t,"class",c);break;case"tabIndex":cl(t,"tabindex",c);break;case"dir":case"role":case"viewBox":case"width":case"height":cl(t,l,c);break;case"style":qd(t,c,g);break;case"data":if(r!=="object"){cl(t,"data",c);break}case"src":case"href":if(c===""&&(r!=="a"||l!=="href")){t.removeAttribute(l);break}if(c==null||typeof c=="function"||typeof c=="symbol"||typeof c=="boolean"){t.removeAttribute(l);break}c=hl(""+c),t.setAttribute(l,c);break;case"action":case"formAction":if(typeof c=="function"){t.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof g=="function"&&(l==="formAction"?(r!=="input"&&ke(t,r,"name",h.name,h,null),ke(t,r,"formEncType",h.formEncType,h,null),ke(t,r,"formMethod",h.formMethod,h,null),ke(t,r,"formTarget",h.formTarget,h,null)):(ke(t,r,"encType",h.encType,h,null),ke(t,r,"method",h.method,h,null),ke(t,r,"target",h.target,h,null)));if(c==null||typeof c=="symbol"||typeof c=="boolean"){t.removeAttribute(l);break}c=hl(""+c),t.setAttribute(l,c);break;case"onClick":c!=null&&(t.onclick=so);break;case"onScroll":c!=null&&be("scroll",t);break;case"onScrollEnd":c!=null&&be("scrollend",t);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(s(61));if(l=c.__html,l!=null){if(h.children!=null)throw Error(s(60));t.innerHTML=l}}break;case"multiple":t.multiple=c&&typeof c!="function"&&typeof c!="symbol";break;case"muted":t.muted=c&&typeof c!="function"&&typeof c!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(c==null||typeof c=="function"||typeof c=="boolean"||typeof c=="symbol"){t.removeAttribute("xlink:href");break}l=hl(""+c),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":c!=null&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(l,""+c):t.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":c&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(l,""):t.removeAttribute(l);break;case"capture":case"download":c===!0?t.setAttribute(l,""):c!==!1&&c!=null&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(l,c):t.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":c!=null&&typeof c!="function"&&typeof c!="symbol"&&!isNaN(c)&&1<=c?t.setAttribute(l,c):t.removeAttribute(l);break;case"rowSpan":case"start":c==null||typeof c=="function"||typeof c=="symbol"||isNaN(c)?t.removeAttribute(l):t.setAttribute(l,c);break;case"popover":be("beforetoggle",t),be("toggle",t),ol(t,"popover",c);break;case"xlinkActuate":En(t,"http://www.w3.org/1999/xlink","xlink:actuate",c);break;case"xlinkArcrole":En(t,"http://www.w3.org/1999/xlink","xlink:arcrole",c);break;case"xlinkRole":En(t,"http://www.w3.org/1999/xlink","xlink:role",c);break;case"xlinkShow":En(t,"http://www.w3.org/1999/xlink","xlink:show",c);break;case"xlinkTitle":En(t,"http://www.w3.org/1999/xlink","xlink:title",c);break;case"xlinkType":En(t,"http://www.w3.org/1999/xlink","xlink:type",c);break;case"xmlBase":En(t,"http://www.w3.org/XML/1998/namespace","xml:base",c);break;case"xmlLang":En(t,"http://www.w3.org/XML/1998/namespace","xml:lang",c);break;case"xmlSpace":En(t,"http://www.w3.org/XML/1998/namespace","xml:space",c);break;case"is":ol(t,"is",c);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=wS.get(l)||l,ol(t,l,c))}}function _f(t,r,l,c,h,g){switch(l){case"style":qd(t,c,g);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(s(61));if(l=c.__html,l!=null){if(h.children!=null)throw Error(s(60));t.innerHTML=l}}break;case"children":typeof c=="string"?ms(t,c):(typeof c=="number"||typeof c=="bigint")&&ms(t,""+c);break;case"onScroll":c!=null&&be("scroll",t);break;case"onScrollEnd":c!=null&&be("scrollend",t);break;case"onClick":c!=null&&(t.onclick=so);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!kd.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(h=l.endsWith("Capture"),r=l.slice(2,h?l.length-7:void 0),g=t[Nt]||null,g=g!=null?g[l]:null,typeof g=="function"&&t.removeEventListener(r,g,h),typeof c=="function")){typeof g!="function"&&g!==null&&(l in t?t[l]=null:t.hasAttribute(l)&&t.removeAttribute(l)),t.addEventListener(r,c,h);break e}l in t?t[l]=c:c===!0?t.setAttribute(l,""):ol(t,l,c)}}}function ot(t,r,l){switch(r){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":be("error",t),be("load",t);var c=!1,h=!1,g;for(g in l)if(l.hasOwnProperty(g)){var S=l[g];if(S!=null)switch(g){case"src":c=!0;break;case"srcSet":h=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(s(137,r));default:ke(t,r,g,S,l,null)}}h&&ke(t,r,"srcSet",l.srcSet,l,null),c&&ke(t,r,"src",l.src,l,null);return;case"input":be("invalid",t);var T=g=S=h=null,A=null,D=null;for(c in l)if(l.hasOwnProperty(c)){var K=l[c];if(K!=null)switch(c){case"name":h=K;break;case"type":S=K;break;case"checked":A=K;break;case"defaultChecked":D=K;break;case"value":g=K;break;case"defaultValue":T=K;break;case"children":case"dangerouslySetInnerHTML":if(K!=null)throw Error(s(137,r));break;default:ke(t,r,c,K,l,null)}}Bd(t,g,T,A,D,S,h,!1),ul(t);return;case"select":be("invalid",t),c=S=g=null;for(h in l)if(l.hasOwnProperty(h)&&(T=l[h],T!=null))switch(h){case"value":g=T;break;case"defaultValue":S=T;break;case"multiple":c=T;default:ke(t,r,h,T,l,null)}r=g,l=S,t.multiple=!!c,r!=null?gs(t,!!c,r,!1):l!=null&&gs(t,!!c,l,!0);return;case"textarea":be("invalid",t),g=h=c=null;for(S in l)if(l.hasOwnProperty(S)&&(T=l[S],T!=null))switch(S){case"value":c=T;break;case"defaultValue":h=T;break;case"children":g=T;break;case"dangerouslySetInnerHTML":if(T!=null)throw Error(s(91));break;default:ke(t,r,S,T,l,null)}zd(t,c,h,g),ul(t);return;case"option":for(A in l)if(l.hasOwnProperty(A)&&(c=l[A],c!=null))switch(A){case"selected":t.selected=c&&typeof c!="function"&&typeof c!="symbol";break;default:ke(t,r,A,c,l,null)}return;case"dialog":be("beforetoggle",t),be("toggle",t),be("cancel",t),be("close",t);break;case"iframe":case"object":be("load",t);break;case"video":case"audio":for(c=0;c<da.length;c++)be(da[c],t);break;case"image":be("error",t),be("load",t);break;case"details":be("toggle",t);break;case"embed":case"source":case"link":be("error",t),be("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(D in l)if(l.hasOwnProperty(D)&&(c=l[D],c!=null))switch(D){case"children":case"dangerouslySetInnerHTML":throw Error(s(137,r));default:ke(t,r,D,c,l,null)}return;default:if(zc(r)){for(K in l)l.hasOwnProperty(K)&&(c=l[K],c!==void 0&&_f(t,r,K,c,l,void 0));return}}for(T in l)l.hasOwnProperty(T)&&(c=l[T],c!=null&&ke(t,r,T,c,l,null))}function Y1(t,r,l,c){switch(r){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var h=null,g=null,S=null,T=null,A=null,D=null,K=null;for(H in l){var P=l[H];if(l.hasOwnProperty(H)&&P!=null)switch(H){case"checked":break;case"value":break;case"defaultValue":A=P;default:c.hasOwnProperty(H)||ke(t,r,H,null,c,P)}}for(var z in c){var H=c[z];if(P=l[z],c.hasOwnProperty(z)&&(H!=null||P!=null))switch(z){case"type":g=H;break;case"name":h=H;break;case"checked":D=H;break;case"defaultChecked":K=H;break;case"value":S=H;break;case"defaultValue":T=H;break;case"children":case"dangerouslySetInnerHTML":if(H!=null)throw Error(s(137,r));break;default:H!==P&&ke(t,r,z,H,c,P)}}Bc(t,S,T,A,D,K,g,h);return;case"select":H=S=T=z=null;for(g in l)if(A=l[g],l.hasOwnProperty(g)&&A!=null)switch(g){case"value":break;case"multiple":H=A;default:c.hasOwnProperty(g)||ke(t,r,g,null,c,A)}for(h in c)if(g=c[h],A=l[h],c.hasOwnProperty(h)&&(g!=null||A!=null))switch(h){case"value":z=g;break;case"defaultValue":T=g;break;case"multiple":S=g;default:g!==A&&ke(t,r,h,g,c,A)}r=T,l=S,c=H,z!=null?gs(t,!!l,z,!1):!!c!=!!l&&(r!=null?gs(t,!!l,r,!0):gs(t,!!l,l?[]:"",!1));return;case"textarea":H=z=null;for(T in l)if(h=l[T],l.hasOwnProperty(T)&&h!=null&&!c.hasOwnProperty(T))switch(T){case"value":break;case"children":break;default:ke(t,r,T,null,c,h)}for(S in c)if(h=c[S],g=l[S],c.hasOwnProperty(S)&&(h!=null||g!=null))switch(S){case"value":z=h;break;case"defaultValue":H=h;break;case"children":break;case"dangerouslySetInnerHTML":if(h!=null)throw Error(s(91));break;default:h!==g&&ke(t,r,S,h,c,g)}Ud(t,z,H);return;case"option":for(var ce in l)if(z=l[ce],l.hasOwnProperty(ce)&&z!=null&&!c.hasOwnProperty(ce))switch(ce){case"selected":t.selected=!1;break;default:ke(t,r,ce,null,c,z)}for(A in c)if(z=c[A],H=l[A],c.hasOwnProperty(A)&&z!==H&&(z!=null||H!=null))switch(A){case"selected":t.selected=z&&typeof z!="function"&&typeof z!="symbol";break;default:ke(t,r,A,z,c,H)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var ae in l)z=l[ae],l.hasOwnProperty(ae)&&z!=null&&!c.hasOwnProperty(ae)&&ke(t,r,ae,null,c,z);for(D in c)if(z=c[D],H=l[D],c.hasOwnProperty(D)&&z!==H&&(z!=null||H!=null))switch(D){case"children":case"dangerouslySetInnerHTML":if(z!=null)throw Error(s(137,r));break;default:ke(t,r,D,z,c,H)}return;default:if(zc(r)){for(var Me in l)z=l[Me],l.hasOwnProperty(Me)&&z!==void 0&&!c.hasOwnProperty(Me)&&_f(t,r,Me,void 0,c,z);for(K in c)z=c[K],H=l[K],!c.hasOwnProperty(K)||z===H||z===void 0&&H===void 0||_f(t,r,K,z,c,H);return}}for(var O in l)z=l[O],l.hasOwnProperty(O)&&z!=null&&!c.hasOwnProperty(O)&&ke(t,r,O,null,c,z);for(P in c)z=c[P],H=l[P],!c.hasOwnProperty(P)||z===H||z==null&&H==null||ke(t,r,P,z,c,H)}var Tf=null,Ef=null;function ro(t){return t.nodeType===9?t:t.ownerDocument}function Hm(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function qm(t,r){if(t===0)switch(r){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&r==="foreignObject"?0:t}function Af(t,r){return t==="textarea"||t==="noscript"||typeof r.children=="string"||typeof r.children=="number"||typeof r.children=="bigint"||typeof r.dangerouslySetInnerHTML=="object"&&r.dangerouslySetInnerHTML!==null&&r.dangerouslySetInnerHTML.__html!=null}var Nf=null;function X1(){var t=window.event;return t&&t.type==="popstate"?t===Nf?!1:(Nf=t,!0):(Nf=null,!1)}var $m=typeof setTimeout=="function"?setTimeout:void 0,P1=typeof clearTimeout=="function"?clearTimeout:void 0,Im=typeof Promise=="function"?Promise:void 0,F1=typeof queueMicrotask=="function"?queueMicrotask:typeof Im<"u"?function(t){return Im.resolve(null).then(t).catch(Q1)}:$m;function Q1(t){setTimeout(function(){throw t})}function hi(t){return t==="head"}function Vm(t,r){var l=r,c=0,h=0;do{var g=l.nextSibling;if(t.removeChild(l),g&&g.nodeType===8)if(l=g.data,l==="/$"){if(0<c&&8>c){l=c;var S=t.ownerDocument;if(l&1&&ga(S.documentElement),l&2&&ga(S.body),l&4)for(l=S.head,ga(l),S=l.firstChild;S;){var T=S.nextSibling,A=S.nodeName;S[Mr]||A==="SCRIPT"||A==="STYLE"||A==="LINK"&&S.rel.toLowerCase()==="stylesheet"||l.removeChild(S),S=T}}if(h===0){t.removeChild(g),_a(r);return}h--}else l==="$"||l==="$?"||l==="$!"?h++:c=l.charCodeAt(0)-48;else c=0;l=g}while(l);_a(r)}function Cf(t){var r=t.firstChild;for(r&&r.nodeType===10&&(r=r.nextSibling);r;){var l=r;switch(r=r.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Cf(l),Rc(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}t.removeChild(l)}}function Z1(t,r,l,c){for(;t.nodeType===1;){var h=l;if(t.nodeName.toLowerCase()!==r.toLowerCase()){if(!c&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(c){if(!t[Mr])switch(r){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(g=t.getAttribute("rel"),g==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(g!==h.rel||t.getAttribute("href")!==(h.href==null||h.href===""?null:h.href)||t.getAttribute("crossorigin")!==(h.crossOrigin==null?null:h.crossOrigin)||t.getAttribute("title")!==(h.title==null?null:h.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(g=t.getAttribute("src"),(g!==(h.src==null?null:h.src)||t.getAttribute("type")!==(h.type==null?null:h.type)||t.getAttribute("crossorigin")!==(h.crossOrigin==null?null:h.crossOrigin))&&g&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(r==="input"&&t.type==="hidden"){var g=h.name==null?null:""+h.name;if(h.type==="hidden"&&t.getAttribute("name")===g)return t}else return t;if(t=fn(t.nextSibling),t===null)break}return null}function J1(t,r,l){if(r==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!l||(t=fn(t.nextSibling),t===null))return null;return t}function kf(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState==="complete"}function W1(t,r){var l=t.ownerDocument;if(t.data!=="$?"||l.readyState==="complete")r();else{var c=function(){r(),l.removeEventListener("DOMContentLoaded",c)};l.addEventListener("DOMContentLoaded",c),t._reactRetry=c}}function fn(t){for(;t!=null;t=t.nextSibling){var r=t.nodeType;if(r===1||r===3)break;if(r===8){if(r=t.data,r==="$"||r==="$!"||r==="$?"||r==="F!"||r==="F")break;if(r==="/$")return null}}return t}var Mf=null;function Gm(t){t=t.previousSibling;for(var r=0;t;){if(t.nodeType===8){var l=t.data;if(l==="$"||l==="$!"||l==="$?"){if(r===0)return t;r--}else l==="/$"&&r++}t=t.previousSibling}return null}function Km(t,r,l){switch(r=ro(l),t){case"html":if(t=r.documentElement,!t)throw Error(s(452));return t;case"head":if(t=r.head,!t)throw Error(s(453));return t;case"body":if(t=r.body,!t)throw Error(s(454));return t;default:throw Error(s(451))}}function ga(t){for(var r=t.attributes;r.length;)t.removeAttributeNode(r[0]);Rc(t)}var nn=new Map,Ym=new Set;function ao(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var Hn=Z.d;Z.d={f:ew,r:tw,D:nw,C:iw,L:sw,m:rw,X:lw,S:aw,M:ow};function ew(){var t=Hn.f(),r=Zl();return t||r}function tw(t){var r=fs(t);r!==null&&r.tag===5&&r.type==="form"?hg(r):Hn.r(t)}var Ks=typeof document>"u"?null:document;function Xm(t,r,l){var c=Ks;if(c&&typeof r=="string"&&r){var h=Ft(r);h='link[rel="'+t+'"][href="'+h+'"]',typeof l=="string"&&(h+='[crossorigin="'+l+'"]'),Ym.has(h)||(Ym.add(h),t={rel:t,crossOrigin:l,href:r},c.querySelector(h)===null&&(r=c.createElement("link"),ot(r,"link",t),et(r),c.head.appendChild(r)))}}function nw(t){Hn.D(t),Xm("dns-prefetch",t,null)}function iw(t,r){Hn.C(t,r),Xm("preconnect",t,r)}function sw(t,r,l){Hn.L(t,r,l);var c=Ks;if(c&&t&&r){var h='link[rel="preload"][as="'+Ft(r)+'"]';r==="image"&&l&&l.imageSrcSet?(h+='[imagesrcset="'+Ft(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(h+='[imagesizes="'+Ft(l.imageSizes)+'"]')):h+='[href="'+Ft(t)+'"]';var g=h;switch(r){case"style":g=Ys(t);break;case"script":g=Xs(t)}nn.has(g)||(t=m({rel:"preload",href:r==="image"&&l&&l.imageSrcSet?void 0:t,as:r},l),nn.set(g,t),c.querySelector(h)!==null||r==="style"&&c.querySelector(ma(g))||r==="script"&&c.querySelector(ya(g))||(r=c.createElement("link"),ot(r,"link",t),et(r),c.head.appendChild(r)))}}function rw(t,r){Hn.m(t,r);var l=Ks;if(l&&t){var c=r&&typeof r.as=="string"?r.as:"script",h='link[rel="modulepreload"][as="'+Ft(c)+'"][href="'+Ft(t)+'"]',g=h;switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":g=Xs(t)}if(!nn.has(g)&&(t=m({rel:"modulepreload",href:t},r),nn.set(g,t),l.querySelector(h)===null)){switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(ya(g)))return}c=l.createElement("link"),ot(c,"link",t),et(c),l.head.appendChild(c)}}}function aw(t,r,l){Hn.S(t,r,l);var c=Ks;if(c&&t){var h=hs(c).hoistableStyles,g=Ys(t);r=r||"default";var S=h.get(g);if(!S){var T={loading:0,preload:null};if(S=c.querySelector(ma(g)))T.loading=5;else{t=m({rel:"stylesheet",href:t,"data-precedence":r},l),(l=nn.get(g))&&Of(t,l);var A=S=c.createElement("link");et(A),ot(A,"link",t),A._p=new Promise(function(D,K){A.onload=D,A.onerror=K}),A.addEventListener("load",function(){T.loading|=1}),A.addEventListener("error",function(){T.loading|=2}),T.loading|=4,lo(S,r,c)}S={type:"stylesheet",instance:S,count:1,state:T},h.set(g,S)}}}function lw(t,r){Hn.X(t,r);var l=Ks;if(l&&t){var c=hs(l).hoistableScripts,h=Xs(t),g=c.get(h);g||(g=l.querySelector(ya(h)),g||(t=m({src:t,async:!0},r),(r=nn.get(h))&&Rf(t,r),g=l.createElement("script"),et(g),ot(g,"link",t),l.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},c.set(h,g))}}function ow(t,r){Hn.M(t,r);var l=Ks;if(l&&t){var c=hs(l).hoistableScripts,h=Xs(t),g=c.get(h);g||(g=l.querySelector(ya(h)),g||(t=m({src:t,async:!0,type:"module"},r),(r=nn.get(h))&&Rf(t,r),g=l.createElement("script"),et(g),ot(g,"link",t),l.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},c.set(h,g))}}function Pm(t,r,l,c){var h=(h=ue.current)?ao(h):null;if(!h)throw Error(s(446));switch(t){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(r=Ys(l.href),l=hs(h).hoistableStyles,c=l.get(r),c||(c={type:"style",instance:null,count:0,state:null},l.set(r,c)),c):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){t=Ys(l.href);var g=hs(h).hoistableStyles,S=g.get(t);if(S||(h=h.ownerDocument||h,S={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},g.set(t,S),(g=h.querySelector(ma(t)))&&!g._p&&(S.instance=g,S.state.loading=5),nn.has(t)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},nn.set(t,l),g||cw(h,t,l,S.state))),r&&c===null)throw Error(s(528,""));return S}if(r&&c!==null)throw Error(s(529,""));return null;case"script":return r=l.async,l=l.src,typeof l=="string"&&r&&typeof r!="function"&&typeof r!="symbol"?(r=Xs(l),l=hs(h).hoistableScripts,c=l.get(r),c||(c={type:"script",instance:null,count:0,state:null},l.set(r,c)),c):{type:"void",instance:null,count:0,state:null};default:throw Error(s(444,t))}}function Ys(t){return'href="'+Ft(t)+'"'}function ma(t){return'link[rel="stylesheet"]['+t+"]"}function Fm(t){return m({},t,{"data-precedence":t.precedence,precedence:null})}function cw(t,r,l,c){t.querySelector('link[rel="preload"][as="style"]['+r+"]")?c.loading=1:(r=t.createElement("link"),c.preload=r,r.addEventListener("load",function(){return c.loading|=1}),r.addEventListener("error",function(){return c.loading|=2}),ot(r,"link",l),et(r),t.head.appendChild(r))}function Xs(t){return'[src="'+Ft(t)+'"]'}function ya(t){return"script[async]"+t}function Qm(t,r,l){if(r.count++,r.instance===null)switch(r.type){case"style":var c=t.querySelector('style[data-href~="'+Ft(l.href)+'"]');if(c)return r.instance=c,et(c),c;var h=m({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return c=(t.ownerDocument||t).createElement("style"),et(c),ot(c,"style",h),lo(c,l.precedence,t),r.instance=c;case"stylesheet":h=Ys(l.href);var g=t.querySelector(ma(h));if(g)return r.state.loading|=4,r.instance=g,et(g),g;c=Fm(l),(h=nn.get(h))&&Of(c,h),g=(t.ownerDocument||t).createElement("link"),et(g);var S=g;return S._p=new Promise(function(T,A){S.onload=T,S.onerror=A}),ot(g,"link",c),r.state.loading|=4,lo(g,l.precedence,t),r.instance=g;case"script":return g=Xs(l.src),(h=t.querySelector(ya(g)))?(r.instance=h,et(h),h):(c=l,(h=nn.get(g))&&(c=m({},l),Rf(c,h)),t=t.ownerDocument||t,h=t.createElement("script"),et(h),ot(h,"link",c),t.head.appendChild(h),r.instance=h);case"void":return null;default:throw Error(s(443,r.type))}else r.type==="stylesheet"&&(r.state.loading&4)===0&&(c=r.instance,r.state.loading|=4,lo(c,l.precedence,t));return r.instance}function lo(t,r,l){for(var c=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),h=c.length?c[c.length-1]:null,g=h,S=0;S<c.length;S++){var T=c[S];if(T.dataset.precedence===r)g=T;else if(g!==h)break}g?g.parentNode.insertBefore(t,g.nextSibling):(r=l.nodeType===9?l.head:l,r.insertBefore(t,r.firstChild))}function Of(t,r){t.crossOrigin==null&&(t.crossOrigin=r.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=r.referrerPolicy),t.title==null&&(t.title=r.title)}function Rf(t,r){t.crossOrigin==null&&(t.crossOrigin=r.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=r.referrerPolicy),t.integrity==null&&(t.integrity=r.integrity)}var oo=null;function Zm(t,r,l){if(oo===null){var c=new Map,h=oo=new Map;h.set(l,c)}else h=oo,c=h.get(l),c||(c=new Map,h.set(l,c));if(c.has(t))return c;for(c.set(t,null),l=l.getElementsByTagName(t),h=0;h<l.length;h++){var g=l[h];if(!(g[Mr]||g[pt]||t==="link"&&g.getAttribute("rel")==="stylesheet")&&g.namespaceURI!=="http://www.w3.org/2000/svg"){var S=g.getAttribute(r)||"";S=t+S;var T=c.get(S);T?T.push(g):c.set(S,[g])}}return c}function Jm(t,r,l){t=t.ownerDocument||t,t.head.insertBefore(l,r==="title"?t.querySelector("head > title"):null)}function uw(t,r,l){if(l===1||r.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof r.precedence!="string"||typeof r.href!="string"||r.href==="")break;return!0;case"link":if(typeof r.rel!="string"||typeof r.href!="string"||r.href===""||r.onLoad||r.onError)break;switch(r.rel){case"stylesheet":return t=r.disabled,typeof r.precedence=="string"&&t==null;default:return!0}case"script":if(r.async&&typeof r.async!="function"&&typeof r.async!="symbol"&&!r.onLoad&&!r.onError&&r.src&&typeof r.src=="string")return!0}return!1}function Wm(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}var ba=null;function fw(){}function hw(t,r,l){if(ba===null)throw Error(s(475));var c=ba;if(r.type==="stylesheet"&&(typeof l.media!="string"||matchMedia(l.media).matches!==!1)&&(r.state.loading&4)===0){if(r.instance===null){var h=Ys(l.href),g=t.querySelector(ma(h));if(g){t=g._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(c.count++,c=co.bind(c),t.then(c,c)),r.state.loading|=4,r.instance=g,et(g);return}g=t.ownerDocument||t,l=Fm(l),(h=nn.get(h))&&Of(l,h),g=g.createElement("link"),et(g);var S=g;S._p=new Promise(function(T,A){S.onload=T,S.onerror=A}),ot(g,"link",l),r.instance=g}c.stylesheets===null&&(c.stylesheets=new Map),c.stylesheets.set(r,t),(t=r.state.preload)&&(r.state.loading&3)===0&&(c.count++,r=co.bind(c),t.addEventListener("load",r),t.addEventListener("error",r))}}function dw(){if(ba===null)throw Error(s(475));var t=ba;return t.stylesheets&&t.count===0&&jf(t,t.stylesheets),0<t.count?function(r){var l=setTimeout(function(){if(t.stylesheets&&jf(t,t.stylesheets),t.unsuspend){var c=t.unsuspend;t.unsuspend=null,c()}},6e4);return t.unsuspend=r,function(){t.unsuspend=null,clearTimeout(l)}}:null}function co(){if(this.count--,this.count===0){if(this.stylesheets)jf(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var uo=null;function jf(t,r){t.stylesheets=null,t.unsuspend!==null&&(t.count++,uo=new Map,r.forEach(pw,t),uo=null,co.call(t))}function pw(t,r){if(!(r.state.loading&4)){var l=uo.get(t);if(l)var c=l.get(null);else{l=new Map,uo.set(t,l);for(var h=t.querySelectorAll("link[data-precedence],style[data-precedence]"),g=0;g<h.length;g++){var S=h[g];(S.nodeName==="LINK"||S.getAttribute("media")!=="not all")&&(l.set(S.dataset.precedence,S),c=S)}c&&l.set(null,c)}h=r.instance,S=h.getAttribute("data-precedence"),g=l.get(S)||c,g===c&&l.set(null,h),l.set(S,h),this.count++,c=co.bind(this),h.addEventListener("load",c),h.addEventListener("error",c),g?g.parentNode.insertBefore(h,g.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(h,t.firstChild)),r.state.loading|=4}}var va={$$typeof:V,Provider:null,Consumer:null,_currentValue:ne,_currentValue2:ne,_threadCount:0};function gw(t,r,l,c,h,g,S,T){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Cc(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Cc(0),this.hiddenUpdates=Cc(null),this.identifierPrefix=c,this.onUncaughtError=h,this.onCaughtError=g,this.onRecoverableError=S,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=T,this.incompleteTransitions=new Map}function ey(t,r,l,c,h,g,S,T,A,D,K,P){return t=new gw(t,r,l,S,T,A,D,P),r=1,g===!0&&(r|=24),g=$t(3,null,null,r),t.current=g,g.stateNode=t,r=du(),r.refCount++,t.pooledCache=r,r.refCount++,g.memoizedState={element:c,isDehydrated:l,cache:r},yu(g),t}function ty(t){return t?(t=Ts,t):Ts}function ny(t,r,l,c,h,g){h=ty(h),c.context===null?c.context=h:c.pendingContext=h,c=Wn(r),c.payload={element:l},g=g===void 0?null:g,g!==null&&(c.callback=g),l=ei(t,c,r),l!==null&&(Yt(l,t,r),Fr(l,t,r))}function iy(t,r){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var l=t.retryLane;t.retryLane=l!==0&&l<r?l:r}}function Lf(t,r){iy(t,r),(t=t.alternate)&&iy(t,r)}function sy(t){if(t.tag===13){var r=_s(t,67108864);r!==null&&Yt(r,t,67108864),Lf(t,67108864)}}var fo=!0;function mw(t,r,l,c){var h=q.T;q.T=null;var g=Z.p;try{Z.p=2,Df(t,r,l,c)}finally{Z.p=g,q.T=h}}function yw(t,r,l,c){var h=q.T;q.T=null;var g=Z.p;try{Z.p=8,Df(t,r,l,c)}finally{Z.p=g,q.T=h}}function Df(t,r,l,c){if(fo){var h=Bf(c);if(h===null)xf(t,r,c,ho,l),ay(t,c);else if(vw(h,t,r,l,c))c.stopPropagation();else if(ay(t,c),r&4&&-1<bw.indexOf(t)){for(;h!==null;){var g=fs(h);if(g!==null)switch(g.tag){case 3:if(g=g.stateNode,g.current.memoizedState.isDehydrated){var S=dt(g.pendingLanes);if(S!==0){var T=g;for(T.pendingLanes|=2,T.entangledLanes|=2;S;){var A=1<<31-rt(S);T.entanglements[1]|=A,S&=~A}Sn(g),(Ee&6)===0&&(Fl=Ht()+500,ha(0))}}break;case 13:T=_s(g,2),T!==null&&Yt(T,g,2),Zl(),Lf(g,2)}if(g=Bf(c),g===null&&xf(t,r,c,ho,l),g===h)break;h=g}h!==null&&c.stopPropagation()}else xf(t,r,c,null,l)}}function Bf(t){return t=qc(t),Uf(t)}var ho=null;function Uf(t){if(ho=null,t=us(t),t!==null){var r=o(t);if(r===null)t=null;else{var l=r.tag;if(l===13){if(t=u(r),t!==null)return t;t=null}else if(l===3){if(r.stateNode.current.memoizedState.isDehydrated)return r.tag===3?r.stateNode.containerInfo:null;t=null}else r!==t&&(t=null)}}return ho=t,null}function ry(t){switch(t){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Pn()){case al:return 2;case ll:return 8;case ls:case Tc:return 32;case Ar:return 268435456;default:return 32}default:return 32}}var zf=!1,di=null,pi=null,gi=null,Sa=new Map,wa=new Map,mi=[],bw="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function ay(t,r){switch(t){case"focusin":case"focusout":di=null;break;case"dragenter":case"dragleave":pi=null;break;case"mouseover":case"mouseout":gi=null;break;case"pointerover":case"pointerout":Sa.delete(r.pointerId);break;case"gotpointercapture":case"lostpointercapture":wa.delete(r.pointerId)}}function xa(t,r,l,c,h,g){return t===null||t.nativeEvent!==g?(t={blockedOn:r,domEventName:l,eventSystemFlags:c,nativeEvent:g,targetContainers:[h]},r!==null&&(r=fs(r),r!==null&&sy(r)),t):(t.eventSystemFlags|=c,r=t.targetContainers,h!==null&&r.indexOf(h)===-1&&r.push(h),t)}function vw(t,r,l,c,h){switch(r){case"focusin":return di=xa(di,t,r,l,c,h),!0;case"dragenter":return pi=xa(pi,t,r,l,c,h),!0;case"mouseover":return gi=xa(gi,t,r,l,c,h),!0;case"pointerover":var g=h.pointerId;return Sa.set(g,xa(Sa.get(g)||null,t,r,l,c,h)),!0;case"gotpointercapture":return g=h.pointerId,wa.set(g,xa(wa.get(g)||null,t,r,l,c,h)),!0}return!1}function ly(t){var r=us(t.target);if(r!==null){var l=o(r);if(l!==null){if(r=l.tag,r===13){if(r=u(l),r!==null){t.blockedOn=r,hS(t.priority,function(){if(l.tag===13){var c=Kt();c=kc(c);var h=_s(l,c);h!==null&&Yt(h,l,c),Lf(l,c)}});return}}else if(r===3&&l.stateNode.current.memoizedState.isDehydrated){t.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}t.blockedOn=null}function po(t){if(t.blockedOn!==null)return!1;for(var r=t.targetContainers;0<r.length;){var l=Bf(t.nativeEvent);if(l===null){l=t.nativeEvent;var c=new l.constructor(l.type,l);Hc=c,l.target.dispatchEvent(c),Hc=null}else return r=fs(l),r!==null&&sy(r),t.blockedOn=l,!1;r.shift()}return!0}function oy(t,r,l){po(t)&&l.delete(r)}function Sw(){zf=!1,di!==null&&po(di)&&(di=null),pi!==null&&po(pi)&&(pi=null),gi!==null&&po(gi)&&(gi=null),Sa.forEach(oy),wa.forEach(oy)}function go(t,r){t.blockedOn===r&&(t.blockedOn=null,zf||(zf=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,Sw)))}var mo=null;function cy(t){mo!==t&&(mo=t,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){mo===t&&(mo=null);for(var r=0;r<t.length;r+=3){var l=t[r],c=t[r+1],h=t[r+2];if(typeof c!="function"){if(Uf(c||l)===null)continue;break}var g=fs(l);g!==null&&(t.splice(r,3),r-=3,Bu(g,{pending:!0,data:h,method:l.method,action:c},c,h))}}))}function _a(t){function r(A){return go(A,t)}di!==null&&go(di,t),pi!==null&&go(pi,t),gi!==null&&go(gi,t),Sa.forEach(r),wa.forEach(r);for(var l=0;l<mi.length;l++){var c=mi[l];c.blockedOn===t&&(c.blockedOn=null)}for(;0<mi.length&&(l=mi[0],l.blockedOn===null);)ly(l),l.blockedOn===null&&mi.shift();if(l=(t.ownerDocument||t).$$reactFormReplay,l!=null)for(c=0;c<l.length;c+=3){var h=l[c],g=l[c+1],S=h[Nt]||null;if(typeof g=="function")S||cy(l);else if(S){var T=null;if(g&&g.hasAttribute("formAction")){if(h=g,S=g[Nt]||null)T=S.formAction;else if(Uf(h)!==null)continue}else T=S.action;typeof T=="function"?l[c+1]=T:(l.splice(c,3),c-=3),cy(l)}}}function Hf(t){this._internalRoot=t}yo.prototype.render=Hf.prototype.render=function(t){var r=this._internalRoot;if(r===null)throw Error(s(409));var l=r.current,c=Kt();ny(l,c,t,r,null,null)},yo.prototype.unmount=Hf.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var r=t.containerInfo;ny(t.current,2,null,t,null,null),Zl(),r[cs]=null}};function yo(t){this._internalRoot=t}yo.prototype.unstable_scheduleHydration=function(t){if(t){var r=Ad();t={blockedOn:null,target:t,priority:r};for(var l=0;l<mi.length&&r!==0&&r<mi[l].priority;l++);mi.splice(l,0,t),l===0&&ly(t)}};var uy=e.version;if(uy!=="19.1.1")throw Error(s(527,uy,"19.1.1"));Z.findDOMNode=function(t){var r=t._reactInternals;if(r===void 0)throw typeof t.render=="function"?Error(s(188)):(t=Object.keys(t).join(","),Error(s(268,t)));return t=d(r),t=t!==null?p(t):null,t=t===null?null:t.stateNode,t};var ww={bundleType:0,version:"19.1.1",rendererPackageName:"react-dom",currentDispatcherRef:q,reconcilerVersion:"19.1.1"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var bo=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!bo.isDisabled&&bo.supportsFiber)try{Ti=bo.inject(ww),vt=bo}catch{}}return Ea.createRoot=function(t,r){if(!a(t))throw Error(s(299));var l=!1,c="",h=Ag,g=Ng,S=Cg,T=null;return r!=null&&(r.unstable_strictMode===!0&&(l=!0),r.identifierPrefix!==void 0&&(c=r.identifierPrefix),r.onUncaughtError!==void 0&&(h=r.onUncaughtError),r.onCaughtError!==void 0&&(g=r.onCaughtError),r.onRecoverableError!==void 0&&(S=r.onRecoverableError),r.unstable_transitionCallbacks!==void 0&&(T=r.unstable_transitionCallbacks)),r=ey(t,1,!1,null,null,l,c,h,g,S,T,null),t[cs]=r.current,wf(t),new Hf(r)},Ea.hydrateRoot=function(t,r,l){if(!a(t))throw Error(s(299));var c=!1,h="",g=Ag,S=Ng,T=Cg,A=null,D=null;return l!=null&&(l.unstable_strictMode===!0&&(c=!0),l.identifierPrefix!==void 0&&(h=l.identifierPrefix),l.onUncaughtError!==void 0&&(g=l.onUncaughtError),l.onCaughtError!==void 0&&(S=l.onCaughtError),l.onRecoverableError!==void 0&&(T=l.onRecoverableError),l.unstable_transitionCallbacks!==void 0&&(A=l.unstable_transitionCallbacks),l.formState!==void 0&&(D=l.formState)),r=ey(t,1,!0,r,l??null,c,h,g,S,T,A,D),r.context=ty(null),l=r.current,c=Kt(),c=kc(c),h=Wn(c),h.callback=null,ei(l,h,c),l=c,r.current.lanes=l,kr(r,l),Sn(r),t[cs]=r.current,wf(t),new yo(r)},Ea.version="19.1.1",Ea}var xy;function Hw(){if(xy)return If.exports;xy=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}return n(),If.exports=zw(),If.exports}var KN=Hw();const x0=new Map([["APIRequestContext.fetch",{title:'{method} "{url}"'}],["APIRequestContext.fetchResponseBody",{title:"Get response body",group:"getter"}],["APIRequestContext.fetchLog",{internal:!0}],["APIRequestContext.storageState",{title:"Get storage state"}],["APIRequestContext.disposeAPIResponse",{internal:!0}],["APIRequestContext.dispose",{internal:!0}],["LocalUtils.zip",{internal:!0}],["LocalUtils.harOpen",{internal:!0}],["LocalUtils.harLookup",{internal:!0}],["LocalUtils.harClose",{internal:!0}],["LocalUtils.harUnzip",{internal:!0}],["LocalUtils.connect",{internal:!0}],["LocalUtils.tracingStarted",{internal:!0}],["LocalUtils.addStackToTracingNoReply",{internal:!0}],["LocalUtils.traceDiscarded",{internal:!0}],["LocalUtils.globToRegex",{internal:!0}],["Root.initialize",{internal:!0}],["Playwright.newRequest",{title:"Create request context"}],["DebugController.initialize",{internal:!0}],["DebugController.setReportStateChanged",{internal:!0}],["DebugController.setRecorderMode",{internal:!0}],["DebugController.highlight",{internal:!0}],["DebugController.hideHighlight",{internal:!0}],["DebugController.resume",{internal:!0}],["DebugController.kill",{internal:!0}],["SocksSupport.socksConnected",{internal:!0}],["SocksSupport.socksFailed",{internal:!0}],["SocksSupport.socksData",{internal:!0}],["SocksSupport.socksError",{internal:!0}],["SocksSupport.socksEnd",{internal:!0}],["BrowserType.launch",{title:"Launch browser"}],["BrowserType.launchPersistentContext",{title:"Launch persistent context"}],["BrowserType.connectOverCDP",{title:"Connect over CDP"}],["Browser.close",{title:"Close browser",pausesBeforeAction:!0}],["Browser.killForTests",{internal:!0}],["Browser.defaultUserAgentForTest",{internal:!0}],["Browser.newContext",{title:"Create context"}],["Browser.newContextForReuse",{internal:!0}],["Browser.disconnectFromReusedContext",{internal:!0}],["Browser.newBrowserCDPSession",{title:"Create CDP session",group:"configuration"}],["Browser.startTracing",{title:"Start browser tracing",group:"configuration"}],["Browser.stopTracing",{title:"Stop browser tracing",group:"configuration"}],["EventTarget.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["BrowserContext.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["Page.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["WebSocket.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["ElectronApplication.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["AndroidDevice.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["BrowserContext.addCookies",{title:"Add cookies",group:"configuration"}],["BrowserContext.addInitScript",{title:"Add init script",group:"configuration"}],["BrowserContext.clearCookies",{title:"Clear cookies",group:"configuration"}],["BrowserContext.clearPermissions",{title:"Clear permissions",group:"configuration"}],["BrowserContext.close",{title:"Close context",pausesBeforeAction:!0}],["BrowserContext.cookies",{title:"Get cookies",group:"getter"}],["BrowserContext.exposeBinding",{title:"Expose binding",group:"configuration"}],["BrowserContext.grantPermissions",{title:"Grant permissions",group:"configuration"}],["BrowserContext.newPage",{title:"Create page"}],["BrowserContext.registerSelectorEngine",{internal:!0}],["BrowserContext.setTestIdAttributeName",{internal:!0}],["BrowserContext.setExtraHTTPHeaders",{title:"Set extra HTTP headers",group:"configuration"}],["BrowserContext.setGeolocation",{title:"Set geolocation",group:"configuration"}],["BrowserContext.setHTTPCredentials",{title:"Set HTTP credentials",group:"configuration"}],["BrowserContext.setNetworkInterceptionPatterns",{title:"Route requests",group:"route"}],["BrowserContext.setWebSocketInterceptionPatterns",{title:"Route WebSockets",group:"route"}],["BrowserContext.setOffline",{title:"Set offline mode"}],["BrowserContext.storageState",{title:"Get storage state"}],["BrowserContext.pause",{title:"Pause"}],["BrowserContext.enableRecorder",{internal:!0}],["BrowserContext.disableRecorder",{internal:!0}],["BrowserContext.newCDPSession",{title:"Create CDP session",group:"configuration"}],["BrowserContext.harStart",{internal:!0}],["BrowserContext.harExport",{internal:!0}],["BrowserContext.createTempFiles",{internal:!0}],["BrowserContext.updateSubscription",{internal:!0}],["BrowserContext.clockFastForward",{title:'Fast forward clock "{ticksNumber|ticksString}"'}],["BrowserContext.clockInstall",{title:'Install clock "{timeNumber|timeString}"'}],["BrowserContext.clockPauseAt",{title:'Pause clock "{timeNumber|timeString}"'}],["BrowserContext.clockResume",{title:"Resume clock"}],["BrowserContext.clockRunFor",{title:'Run clock "{ticksNumber|ticksString}"'}],["BrowserContext.clockSetFixedTime",{title:'Set fixed time "{timeNumber|timeString}"'}],["BrowserContext.clockSetSystemTime",{title:'Set system time "{timeNumber|timeString}"'}],["Page.addInitScript",{title:"Add init script",group:"configuration"}],["Page.close",{title:"Close page",pausesBeforeAction:!0}],["Page.consoleMessages",{title:"Get console messages",group:"getter"}],["Page.emulateMedia",{title:"Emulate media",snapshot:!0,pausesBeforeAction:!0}],["Page.exposeBinding",{title:"Expose binding",group:"configuration"}],["Page.goBack",{title:"Go back",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.goForward",{title:"Go forward",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.requestGC",{title:"Request garbage collection",group:"configuration"}],["Page.registerLocatorHandler",{title:"Register locator handler"}],["Page.resolveLocatorHandlerNoReply",{internal:!0}],["Page.unregisterLocatorHandler",{title:"Unregister locator handler"}],["Page.reload",{title:"Reload",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.expectScreenshot",{title:"Expect screenshot",snapshot:!0,pausesBeforeAction:!0}],["Page.screenshot",{title:"Screenshot",snapshot:!0,pausesBeforeAction:!0}],["Page.setExtraHTTPHeaders",{title:"Set extra HTTP headers",group:"configuration"}],["Page.setNetworkInterceptionPatterns",{title:"Route requests",group:"route"}],["Page.setWebSocketInterceptionPatterns",{title:"Route WebSockets",group:"route"}],["Page.setViewportSize",{title:"Set viewport size",snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardDown",{title:'Key down "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardUp",{title:'Key up "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardInsertText",{title:'Insert "{text}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardType",{title:'Type "{text}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardPress",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseMove",{title:"Mouse move",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseDown",{title:"Mouse down",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseUp",{title:"Mouse up",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseClick",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseWheel",{title:"Mouse wheel",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.touchscreenTap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.accessibilitySnapshot",{title:"Accessibility snapshot",group:"getter"}],["Page.pageErrors",{title:"Get page errors",group:"getter"}],["Page.pdf",{title:"PDF"}],["Page.requests",{title:"Get network requests",group:"getter"}],["Page.snapshotForAI",{internal:!0}],["Page.startJSCoverage",{title:"Start JS coverage",group:"configuration"}],["Page.stopJSCoverage",{title:"Stop JS coverage",group:"configuration"}],["Page.startCSSCoverage",{title:"Start CSS coverage",group:"configuration"}],["Page.stopCSSCoverage",{title:"Stop CSS coverage",group:"configuration"}],["Page.bringToFront",{title:"Bring to front"}],["Page.updateSubscription",{internal:!0}],["Frame.evalOnSelector",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.evalOnSelectorAll",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.addScriptTag",{title:"Add script tag",snapshot:!0,pausesBeforeAction:!0}],["Frame.addStyleTag",{title:"Add style tag",snapshot:!0,pausesBeforeAction:!0}],["Frame.ariaSnapshot",{title:"Aria snapshot",snapshot:!0,pausesBeforeAction:!0}],["Frame.blur",{title:"Blur",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.check",{title:"Check",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.click",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.content",{title:"Get content",snapshot:!0,pausesBeforeAction:!0}],["Frame.dragAndDrop",{title:"Drag and drop",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.dblclick",{title:"Double click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.dispatchEvent",{title:'Dispatch "{type}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.fill",{title:'Fill "{value}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.focus",{title:"Focus",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.frameElement",{title:"Get frame element",group:"getter"}],["Frame.resolveSelector",{internal:!0}],["Frame.highlight",{title:"Highlight element",group:"configuration"}],["Frame.getAttribute",{title:'Get attribute "{name}"',snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.goto",{title:'Navigate to "{url}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.hover",{title:"Hover",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.innerHTML",{title:"Get HTML",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.innerText",{title:"Get inner text",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.inputValue",{title:"Get input value",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isChecked",{title:"Is checked",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isDisabled",{title:"Is disabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isEnabled",{title:"Is enabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isHidden",{title:"Is hidden",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isVisible",{title:"Is visible",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isEditable",{title:"Is editable",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.press",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.querySelector",{title:"Query selector",snapshot:!0}],["Frame.querySelectorAll",{title:"Query selector all",snapshot:!0}],["Frame.queryCount",{title:"Query count",snapshot:!0,pausesBeforeAction:!0}],["Frame.selectOption",{title:"Select option",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.setContent",{title:"Set content",snapshot:!0,pausesBeforeAction:!0}],["Frame.setInputFiles",{title:"Set input files",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.tap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.textContent",{title:"Get text content",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.title",{title:"Get page title",group:"getter"}],["Frame.type",{title:'Type "{text}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.uncheck",{title:"Uncheck",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.waitForTimeout",{title:"Wait for timeout",snapshot:!0}],["Frame.waitForFunction",{title:"Wait for function",snapshot:!0,pausesBeforeAction:!0}],["Frame.waitForSelector",{title:"Wait for selector",snapshot:!0}],["Frame.expect",{title:'Expect "{expression}"',snapshot:!0,pausesBeforeAction:!0}],["Worker.evaluateExpression",{title:"Evaluate"}],["Worker.evaluateExpressionHandle",{title:"Evaluate"}],["JSHandle.dispose",{internal:!0}],["ElementHandle.dispose",{internal:!0}],["JSHandle.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["JSHandle.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["JSHandle.getPropertyList",{title:"Get property list",group:"getter"}],["ElementHandle.getPropertyList",{title:"Get property list",group:"getter"}],["JSHandle.getProperty",{title:"Get JS property",group:"getter"}],["ElementHandle.getProperty",{title:"Get JS property",group:"getter"}],["JSHandle.jsonValue",{title:"Get JSON value",group:"getter"}],["ElementHandle.jsonValue",{title:"Get JSON value",group:"getter"}],["ElementHandle.evalOnSelector",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evalOnSelectorAll",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.boundingBox",{title:"Get bounding box",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.check",{title:"Check",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.click",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.contentFrame",{title:"Get content frame",group:"getter"}],["ElementHandle.dblclick",{title:"Double click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.dispatchEvent",{title:"Dispatch event",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.fill",{title:'Fill "{value}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.focus",{title:"Focus",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.getAttribute",{title:"Get attribute",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.hover",{title:"Hover",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.innerHTML",{title:"Get HTML",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.innerText",{title:"Get inner text",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.inputValue",{title:"Get input value",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isChecked",{title:"Is checked",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isDisabled",{title:"Is disabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isEditable",{title:"Is editable",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isEnabled",{title:"Is enabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isHidden",{title:"Is hidden",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isVisible",{title:"Is visible",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.ownerFrame",{title:"Get owner frame",group:"getter"}],["ElementHandle.press",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.querySelector",{title:"Query selector",snapshot:!0}],["ElementHandle.querySelectorAll",{title:"Query selector all",snapshot:!0}],["ElementHandle.screenshot",{title:"Screenshot",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.scrollIntoViewIfNeeded",{title:"Scroll into view",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.selectOption",{title:"Select option",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.selectText",{title:"Select text",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.setInputFiles",{title:"Set input files",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.tap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.textContent",{title:"Get text content",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.type",{title:"Type",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.uncheck",{title:"Uncheck",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.waitForElementState",{title:"Wait for state",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.waitForSelector",{title:"Wait for selector",snapshot:!0}],["Request.response",{internal:!0}],["Request.rawRequestHeaders",{internal:!0}],["Route.redirectNavigationRequest",{internal:!0}],["Route.abort",{title:"Abort request",group:"route"}],["Route.continue",{title:"Continue request",group:"route"}],["Route.fulfill",{title:"Fulfill request",group:"route"}],["WebSocketRoute.connect",{title:"Connect WebSocket to server",group:"route"}],["WebSocketRoute.ensureOpened",{internal:!0}],["WebSocketRoute.sendToPage",{title:"Send WebSocket message",group:"route"}],["WebSocketRoute.sendToServer",{title:"Send WebSocket message",group:"route"}],["WebSocketRoute.closePage",{internal:!0}],["WebSocketRoute.closeServer",{internal:!0}],["Response.body",{title:"Get response body",group:"getter"}],["Response.securityDetails",{internal:!0}],["Response.serverAddr",{internal:!0}],["Response.rawResponseHeaders",{internal:!0}],["Response.sizes",{internal:!0}],["BindingCall.reject",{internal:!0}],["BindingCall.resolve",{internal:!0}],["Dialog.accept",{title:"Accept dialog"}],["Dialog.dismiss",{title:"Dismiss dialog"}],["Tracing.tracingStart",{title:"Start tracing",group:"configuration"}],["Tracing.tracingStartChunk",{title:"Start tracing",group:"configuration"}],["Tracing.tracingGroup",{title:'Trace "{name}"'}],["Tracing.tracingGroupEnd",{title:"Group end"}],["Tracing.tracingStopChunk",{title:"Stop tracing",group:"configuration"}],["Tracing.tracingStop",{title:"Stop tracing",group:"configuration"}],["Artifact.pathAfterFinished",{internal:!0}],["Artifact.saveAs",{internal:!0}],["Artifact.saveAsStream",{internal:!0}],["Artifact.failure",{internal:!0}],["Artifact.stream",{internal:!0}],["Artifact.cancel",{internal:!0}],["Artifact.delete",{internal:!0}],["Stream.read",{internal:!0}],["Stream.close",{internal:!0}],["WritableStream.write",{internal:!0}],["WritableStream.close",{internal:!0}],["CDPSession.send",{title:"Send CDP command",group:"configuration"}],["CDPSession.detach",{title:"Detach CDP session",group:"configuration"}],["Electron.launch",{title:"Launch electron"}],["ElectronApplication.browserWindow",{internal:!0}],["ElectronApplication.evaluateExpression",{title:"Evaluate"}],["ElectronApplication.evaluateExpressionHandle",{title:"Evaluate"}],["ElectronApplication.updateSubscription",{internal:!0}],["Android.devices",{internal:!0}],["AndroidSocket.write",{internal:!0}],["AndroidSocket.close",{internal:!0}],["AndroidDevice.wait",{title:"Wait"}],["AndroidDevice.fill",{title:'Fill "{text}"'}],["AndroidDevice.tap",{title:"Tap"}],["AndroidDevice.drag",{title:"Drag"}],["AndroidDevice.fling",{title:"Fling"}],["AndroidDevice.longTap",{title:"Long tap"}],["AndroidDevice.pinchClose",{title:"Pinch close"}],["AndroidDevice.pinchOpen",{title:"Pinch open"}],["AndroidDevice.scroll",{title:"Scroll"}],["AndroidDevice.swipe",{title:"Swipe"}],["AndroidDevice.info",{internal:!0}],["AndroidDevice.screenshot",{title:"Screenshot"}],["AndroidDevice.inputType",{title:"Type"}],["AndroidDevice.inputPress",{title:"Press"}],["AndroidDevice.inputTap",{title:"Tap"}],["AndroidDevice.inputSwipe",{title:"Swipe"}],["AndroidDevice.inputDrag",{title:"Drag"}],["AndroidDevice.launchBrowser",{title:"Launch browser"}],["AndroidDevice.open",{title:"Open app"}],["AndroidDevice.shell",{title:"Execute shell command",group:"configuration"}],["AndroidDevice.installApk",{title:"Install apk"}],["AndroidDevice.push",{title:"Push"}],["AndroidDevice.connectToWebView",{title:"Connect to Web View"}],["AndroidDevice.close",{internal:!0}],["JsonPipe.send",{internal:!0}],["JsonPipe.close",{internal:!0}]]);function qw(n,e){var i;return(i=$w(n,e))==null?void 0:i.replaceAll(`
|
|
51
|
-
`,"\\n")}function $w(n,e){if(n)for(const i of e.split("|")){if(i==="url")try{const a=new URL(n[i]);return a.protocol==="data:"?a.protocol:a.protocol==="about:"?n[i]:a.pathname+a.search}catch{if(n[i]!==void 0)return n[i]}if(i==="timeNumber"&&n[i]!==void 0)return new Date(n[i]).toString();const s=Iw(n,i);if(s!==void 0)return s}}function Iw(n,e){const i=e.split(".");let s=n;for(const a of i){if(typeof s!="object"||s===null)return;s=s[a]}if(s!==void 0)return String(s)}function Vw(n){var e;return(e=x0.get(n.type+"."+n.method))==null?void 0:e.group}const La=Symbol("context"),_0=Symbol("nextInContext"),T0=Symbol("prevByEndTime"),E0=Symbol("nextByStartTime"),_y=Symbol("events");class YN{constructor(e,i){Ne(this,"startTime");Ne(this,"endTime");Ne(this,"browserName");Ne(this,"channel");Ne(this,"platform");Ne(this,"wallTime");Ne(this,"title");Ne(this,"options");Ne(this,"pages");Ne(this,"actions");Ne(this,"attachments");Ne(this,"visibleAttachments");Ne(this,"events");Ne(this,"stdio");Ne(this,"errors");Ne(this,"errorDescriptors");Ne(this,"hasSource");Ne(this,"hasStepData");Ne(this,"sdkLanguage");Ne(this,"testIdAttributeName");Ne(this,"sources");Ne(this,"resources");Ne(this,"actionCounters");Ne(this,"traceUrl");i.forEach(a=>Gw(a));const s=i.find(a=>a.origin==="library");this.traceUrl=e,this.browserName=(s==null?void 0:s.browserName)||"",this.sdkLanguage=s==null?void 0:s.sdkLanguage,this.channel=s==null?void 0:s.channel,this.testIdAttributeName=s==null?void 0:s.testIdAttributeName,this.platform=(s==null?void 0:s.platform)||"",this.title=(s==null?void 0:s.title)||"",this.options=(s==null?void 0:s.options)||{},this.actions=Kw(i),this.pages=[].concat(...i.map(a=>a.pages)),this.wallTime=i.map(a=>a.wallTime).reduce((a,o)=>Math.min(a||Number.MAX_VALUE,o),Number.MAX_VALUE),this.startTime=i.map(a=>a.startTime).reduce((a,o)=>Math.min(a,o),Number.MAX_VALUE),this.endTime=i.map(a=>a.endTime).reduce((a,o)=>Math.max(a,o),Number.MIN_VALUE),this.events=[].concat(...i.map(a=>a.events)),this.stdio=[].concat(...i.map(a=>a.stdio)),this.errors=[].concat(...i.map(a=>a.errors)),this.hasSource=i.some(a=>a.hasSource),this.hasStepData=i.some(a=>a.origin==="testRunner"),this.resources=[...i.map(a=>a.resources)].flat(),this.attachments=this.actions.flatMap(a=>{var o;return((o=a.attachments)==null?void 0:o.map(u=>({...u,traceUrl:e})))??[]}),this.visibleAttachments=this.attachments.filter(a=>!a.name.startsWith("_")),this.events.sort((a,o)=>a.time-o.time),this.resources.sort((a,o)=>a._monotonicTime-o._monotonicTime),this.errorDescriptors=this.hasStepData?this._errorDescriptorsFromTestRunner():this._errorDescriptorsFromActions(),this.sources=Ww(this.actions,this.errorDescriptors),this.actionCounters=new Map;for(const a of this.actions)a.group=a.group??Vw({type:a.class,method:a.method}),a.group&&this.actionCounters.set(a.group,1+(this.actionCounters.get(a.group)||0))}createRelativeUrl(e){const i=new URL("http://localhost/"+e);return i.searchParams.set("trace",this.traceUrl),i.toString().substring(17)}failedAction(){return this.actions.findLast(e=>e.error)}filteredActions(e){const i=new Set(e);return this.actions.filter(s=>!s.group||i.has(s.group))}_errorDescriptorsFromActions(){var i;const e=[];for(const s of this.actions||[])(i=s.error)!=null&&i.message&&e.push({action:s,stack:s.stack,message:s.error.message});return e}_errorDescriptorsFromTestRunner(){return this.errors.filter(e=>!!e.message).map((e,i)=>({stack:e.stack,message:e.message}))}}function Gw(n){for(const i of n.pages)i[La]=n;for(let i=0;i<n.actions.length;++i){const s=n.actions[i];s[La]=n}let e;for(let i=n.actions.length-1;i>=0;i--){const s=n.actions[i];s[_0]=e,s.class!=="Route"&&(e=s)}for(const i of n.events)i[La]=n;for(const i of n.resources)i[La]=n}function Kw(n){const e=[],i=Yw(n);e.push(...i),e.sort((s,a)=>a.parentId===s.callId?1:s.parentId===a.callId?-1:s.endTime-a.endTime);for(let s=1;s<e.length;++s)e[s][T0]=e[s-1];e.sort((s,a)=>a.parentId===s.callId?-1:s.parentId===a.callId?1:s.startTime-a.startTime);for(let s=0;s+1<e.length;++s)e[s][E0]=e[s+1];return e}let Ty=0;function Yw(n){const e=new Map,i=n.filter(u=>u.origin==="library"),s=n.filter(u=>u.origin==="testRunner");if(!s.length||!i.length)return n.map(u=>u.actions.map(f=>({...f,context:u}))).flat();for(const u of i)for(const f of u.actions)e.set(f.stepId||`tmp-step@${++Ty}`,{...f,context:u});const a=Pw(s,e);a&&Xw(i,a);const o=new Map;for(const u of s)for(const f of u.actions){const d=f.stepId&&e.get(f.stepId);if(d){o.set(f.callId,d.callId),f.error&&(d.error=f.error),f.attachments&&(d.attachments=f.attachments),f.annotations&&(d.annotations=f.annotations),f.parentId&&(d.parentId=o.get(f.parentId)??f.parentId),f.group&&(d.group=f.group),d.startTime=f.startTime,d.endTime=f.endTime;continue}f.parentId&&(f.parentId=o.get(f.parentId)??f.parentId),e.set(f.stepId||`tmp-step@${++Ty}`,{...f,context:u})}return[...e.values()]}function Xw(n,e){for(const i of n){i.startTime+=e,i.endTime+=e;for(const s of i.actions)s.startTime&&(s.startTime+=e),s.endTime&&(s.endTime+=e);for(const s of i.events)s.time+=e;for(const s of i.stdio)s.timestamp+=e;for(const s of i.pages)for(const a of s.screencastFrames)a.timestamp+=e;for(const s of i.resources)s._monotonicTime&&(s._monotonicTime+=e)}}function Pw(n,e){for(const i of n)for(const s of i.actions){if(!s.startTime)continue;const a=s.stepId?e.get(s.stepId):void 0;if(a)return s.startTime-a.startTime}return 0}function Fw(n){const e=new Map;for(const s of n)e.set(s.callId,{id:s.callId,parent:void 0,children:[],action:s});const i={id:"",parent:void 0,children:[]};for(const s of e.values()){const a=s.action.parentId&&e.get(s.action.parentId)||i;a.children.push(s),s.parent=a}return{rootItem:i,itemMap:e}}function A0(n){return n[La]}function Qw(n){return n[_0]}function Ey(n){return n[T0]}function Ay(n){return n[E0]}function Zw(n){let e=0,i=0;for(const s of Jw(n)){if(s.type==="console"){const a=s.messageType;a==="warning"?++i:a==="error"&&++e}s.type==="event"&&s.method==="pageError"&&++e}return{errors:e,warnings:i}}function Jw(n){let e=n[_y];if(e)return e;const i=Qw(n);return e=A0(n).events.filter(s=>s.time>=n.startTime&&(!i||s.time<i.startTime)),n[_y]=e,e}function Ww(n,e){var s;const i=new Map;for(const a of n)for(const o of a.stack||[]){let u=i.get(o.file);u||(u={errors:[],content:void 0},i.set(o.file,u))}for(const a of e){const{action:o,stack:u,message:f}=a;!o||!u||(s=i.get(u[0].file))==null||s.errors.push({line:u[0].line||0,message:f})}return i}const ex=50,Vo=({sidebarSize:n,sidebarHidden:e=!1,sidebarIsFirst:i=!1,orientation:s="vertical",minSidebarSize:a=ex,settingName:o,sidebar:u,main:f})=>{const d=Math.max(a,n)*window.devicePixelRatio,[p,m]=xn(o?o+"."+s+":size":void 0,d),[y,b]=xn(o?o+"."+s+":size":void 0,d),[w,E]=U.useState(null),[x,_]=ts();let k;s==="vertical"?(k=y/window.devicePixelRatio,x&&x.height<k&&(k=x.height-10)):(k=p/window.devicePixelRatio,x&&x.width<k&&(k=x.width-10)),document.body.style.userSelect=w?"none":"inherit";let C={};return s==="vertical"?i?C={top:w?0:k-4,bottom:w?0:void 0,height:w?"initial":8}:C={bottom:w?0:k-4,top:w?0:void 0,height:w?"initial":8}:i?C={left:w?0:k-4,right:w?0:void 0,width:w?"initial":8}:C={right:w?0:k-4,left:w?0:void 0,width:w?"initial":8},v.jsxs("div",{className:Ke("split-view",s,i&&"sidebar-first"),ref:_,children:[v.jsx("div",{className:"split-view-main",children:f}),!e&&v.jsx("div",{style:{flexBasis:k},className:"split-view-sidebar",children:u}),!e&&v.jsx("div",{style:C,className:"split-view-resizer",onMouseDown:V=>E({offset:s==="vertical"?V.clientY:V.clientX,size:k}),onMouseUp:()=>E(null),onMouseMove:V=>{if(!V.buttons)E(null);else if(w){const B=(s==="vertical"?V.clientY:V.clientX)-w.offset,G=i?w.size+B:w.size-B,$=V.target.parentElement.getBoundingClientRect(),R=Math.min(Math.max(a,G),(s==="vertical"?$.height:$.width)-a);s==="vertical"?b(R*window.devicePixelRatio):m(R*window.devicePixelRatio)}}})]})},Fe=function(n,e,i){return n>=e&&n<=i};function Rt(n){return Fe(n,48,57)}function Ny(n){return Rt(n)||Fe(n,65,70)||Fe(n,97,102)}function tx(n){return Fe(n,65,90)}function nx(n){return Fe(n,97,122)}function ix(n){return tx(n)||nx(n)}function sx(n){return n>=128}function ko(n){return ix(n)||sx(n)||n===95}function Cy(n){return ko(n)||Rt(n)||n===45}function rx(n){return Fe(n,0,8)||n===11||Fe(n,14,31)||n===127}function Mo(n){return n===10}function qn(n){return Mo(n)||n===9||n===32}const ax=1114111;class Oh extends Error{constructor(e){super(e),this.name="InvalidCharacterError"}}function lx(n){const e=[];for(let i=0;i<n.length;i++){let s=n.charCodeAt(i);if(s===13&&n.charCodeAt(i+1)===10&&(s=10,i++),(s===13||s===12)&&(s=10),s===0&&(s=65533),Fe(s,55296,56319)&&Fe(n.charCodeAt(i+1),56320,57343)){const a=s-55296,o=n.charCodeAt(i+1)-56320;s=Math.pow(2,16)+a*Math.pow(2,10)+o,i++}e.push(s)}return e}function Je(n){if(n<=65535)return String.fromCharCode(n);n-=Math.pow(2,16);const e=Math.floor(n/Math.pow(2,10))+55296,i=n%Math.pow(2,10)+56320;return String.fromCharCode(e)+String.fromCharCode(i)}function N0(n){const e=lx(n);let i=-1;const s=[];let a;const o=function(j){return j>=e.length?-1:e[j]},u=function(j){if(j===void 0&&(j=1),j>3)throw"Spec Error: no more than three codepoints of lookahead.";return o(i+j)},f=function(j){return j===void 0&&(j=1),i+=j,a=o(i),!0},d=function(){return i-=1,!0},p=function(j){return j===void 0&&(j=a),j===-1},m=function(){if(y(),f(),qn(a)){for(;qn(u());)f();return new Go}else{if(a===34)return E();if(a===35)if(Cy(u())||k(u(1),u(2))){const j=new q0("");return V(u(1),u(2),u(3))&&(j.type="id"),j.value=J(),j}else return new ct(a);else return a===36?u()===61?(f(),new fx):new ct(a):a===39?E():a===40?new U0:a===41?new Rh:a===42?u()===61?(f(),new hx):new ct(a):a===43?G()?(d(),b()):new ct(a):a===44?new j0:a===45?G()?(d(),b()):u(1)===45&&u(2)===62?(f(2),new M0):I()?(d(),w()):new ct(a):a===46?G()?(d(),b()):new ct(a):a===58?new O0:a===59?new R0:a===60?u(1)===33&&u(2)===45&&u(3)===45?(f(3),new k0):new ct(a):a===64?V(u(1),u(2),u(3))?new H0(J()):new ct(a):a===91?new B0:a===92?C()?(d(),w()):new ct(a):a===93?new hh:a===94?u()===61?(f(),new ux):new ct(a):a===123?new L0:a===124?u()===61?(f(),new cx):u()===124?(f(),new z0):new ct(a):a===125?new D0:a===126?u()===61?(f(),new ox):new ct(a):Rt(a)?(d(),b()):ko(a)?(d(),w()):p()?new Ro:new ct(a)}},y=function(){for(;u(1)===47&&u(2)===42;)for(f(2);;)if(f(),a===42&&u()===47){f();break}else if(p())return},b=function(){const j=$();if(V(u(1),u(2),u(3))){const F=new dx;return F.value=j.value,F.repr=j.repr,F.type=j.type,F.unit=J(),F}else if(u()===37){f();const F=new V0;return F.value=j.value,F.repr=j.repr,F}else{const F=new I0;return F.value=j.value,F.repr=j.repr,F.type=j.type,F}},w=function(){const j=J();if(j.toLowerCase()==="url"&&u()===40){for(f();qn(u(1))&&qn(u(2));)f();return u()===34||u()===39?new qa(j):qn(u())&&(u(2)===34||u(2)===39)?new qa(j):x()}else return u()===40?(f(),new qa(j)):new jh(j)},E=function(j){j===void 0&&(j=a);let F="";for(;f();){if(a===j||p())return new Lh(F);if(Mo(a))return d(),new C0;a===92?p(u())||(Mo(u())?f():F+=Je(_())):F+=Je(a)}throw new Error("Internal error")},x=function(){const j=new $0("");for(;qn(u());)f();if(p(u()))return j;for(;f();){if(a===41||p())return j;if(qn(a)){for(;qn(u());)f();return u()===41||p(u())?(f(),j):(ee(),new Oo)}else{if(a===34||a===39||a===40||rx(a))return ee(),new Oo;if(a===92)if(C())j.value+=Je(_());else return ee(),new Oo;else j.value+=Je(a)}}throw new Error("Internal error")},_=function(){if(f(),Ny(a)){const j=[a];for(let ge=0;ge<5&&Ny(u());ge++)f(),j.push(a);qn(u())&&f();let F=parseInt(j.map(function(ge){return String.fromCharCode(ge)}).join(""),16);return F>ax&&(F=65533),F}else return p()?65533:a},k=function(j,F){return!(j!==92||Mo(F))},C=function(){return k(a,u())},V=function(j,F,ge){return j===45?ko(F)||F===45||k(F,ge):ko(j)?!0:j===92?k(j,F):!1},I=function(){return V(a,u(1),u(2))},B=function(j,F,ge){return j===43||j===45?!!(Rt(F)||F===46&&Rt(ge)):j===46?!!Rt(F):!!Rt(j)},G=function(){return B(a,u(1),u(2))},J=function(){let j="";for(;f();)if(Cy(a))j+=Je(a);else if(C())j+=Je(_());else return d(),j;throw new Error("Internal parse error")},$=function(){let j="",F="integer";for((u()===43||u()===45)&&(f(),j+=Je(a));Rt(u());)f(),j+=Je(a);if(u(1)===46&&Rt(u(2)))for(f(),j+=Je(a),f(),j+=Je(a),F="number";Rt(u());)f(),j+=Je(a);const ge=u(1),me=u(2),q=u(3);if((ge===69||ge===101)&&Rt(me))for(f(),j+=Je(a),f(),j+=Je(a),F="number";Rt(u());)f(),j+=Je(a);else if((ge===69||ge===101)&&(me===43||me===45)&&Rt(q))for(f(),j+=Je(a),f(),j+=Je(a),f(),j+=Je(a),F="number";Rt(u());)f(),j+=Je(a);const Z=R(j);return{type:F,value:Z,repr:j}},R=function(j){return+j},ee=function(){for(;f();){if(a===41||p())return;C()&&_()}};let re=0;for(;!p(u());)if(s.push(m()),re++,re>e.length*2)throw new Error("I'm infinite-looping!");return s}class Ye{constructor(){this.tokenType=""}toJSON(){return{token:this.tokenType}}toString(){return this.tokenType}toSource(){return""+this}}class C0 extends Ye{constructor(){super(...arguments),this.tokenType="BADSTRING"}}class Oo extends Ye{constructor(){super(...arguments),this.tokenType="BADURL"}}class Go extends Ye{constructor(){super(...arguments),this.tokenType="WHITESPACE"}toString(){return"WS"}toSource(){return" "}}class k0 extends Ye{constructor(){super(...arguments),this.tokenType="CDO"}toSource(){return"<!--"}}class M0 extends Ye{constructor(){super(...arguments),this.tokenType="CDC"}toSource(){return"-->"}}class O0 extends Ye{constructor(){super(...arguments),this.tokenType=":"}}class R0 extends Ye{constructor(){super(...arguments),this.tokenType=";"}}class j0 extends Ye{constructor(){super(...arguments),this.tokenType=","}}class dr extends Ye{constructor(){super(...arguments),this.value="",this.mirror=""}}class L0 extends dr{constructor(){super(),this.tokenType="{",this.value="{",this.mirror="}"}}class D0 extends dr{constructor(){super(),this.tokenType="}",this.value="}",this.mirror="{"}}class B0 extends dr{constructor(){super(),this.tokenType="[",this.value="[",this.mirror="]"}}class hh extends dr{constructor(){super(),this.tokenType="]",this.value="]",this.mirror="["}}class U0 extends dr{constructor(){super(),this.tokenType="(",this.value="(",this.mirror=")"}}class Rh extends dr{constructor(){super(),this.tokenType=")",this.value=")",this.mirror="("}}class ox extends Ye{constructor(){super(...arguments),this.tokenType="~="}}class cx extends Ye{constructor(){super(...arguments),this.tokenType="|="}}class ux extends Ye{constructor(){super(...arguments),this.tokenType="^="}}class fx extends Ye{constructor(){super(...arguments),this.tokenType="$="}}class hx extends Ye{constructor(){super(...arguments),this.tokenType="*="}}class z0 extends Ye{constructor(){super(...arguments),this.tokenType="||"}}class Ro extends Ye{constructor(){super(...arguments),this.tokenType="EOF"}toSource(){return""}}class ct extends Ye{constructor(e){super(),this.tokenType="DELIM",this.value="",this.value=Je(e)}toString(){return"DELIM("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e}toSource(){return this.value==="\\"?`\\
|
|
52
|
-
`:this.value}}class pr extends Ye{constructor(){super(...arguments),this.value=""}ASCIIMatch(e){return this.value.toLowerCase()===e.toLowerCase()}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e}}class jh extends pr{constructor(e){super(),this.tokenType="IDENT",this.value=e}toString(){return"IDENT("+this.value+")"}toSource(){return el(this.value)}}class qa extends pr{constructor(e){super(),this.tokenType="FUNCTION",this.value=e,this.mirror=")"}toString(){return"FUNCTION("+this.value+")"}toSource(){return el(this.value)+"("}}class H0 extends pr{constructor(e){super(),this.tokenType="AT-KEYWORD",this.value=e}toString(){return"AT("+this.value+")"}toSource(){return"@"+el(this.value)}}class q0 extends pr{constructor(e){super(),this.tokenType="HASH",this.value=e,this.type="unrestricted"}toString(){return"HASH("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.type=this.type,e}toSource(){return this.type==="id"?"#"+el(this.value):"#"+px(this.value)}}class Lh extends pr{constructor(e){super(),this.tokenType="STRING",this.value=e}toString(){return'"'+G0(this.value)+'"'}}class $0 extends pr{constructor(e){super(),this.tokenType="URL",this.value=e}toString(){return"URL("+this.value+")"}toSource(){return'url("'+G0(this.value)+'")'}}class I0 extends Ye{constructor(){super(),this.tokenType="NUMBER",this.type="integer",this.repr=""}toString(){return this.type==="integer"?"INT("+this.value+")":"NUMBER("+this.value+")"}toJSON(){const e=super.toJSON();return e.value=this.value,e.type=this.type,e.repr=this.repr,e}toSource(){return this.repr}}class V0 extends Ye{constructor(){super(),this.tokenType="PERCENTAGE",this.repr=""}toString(){return"PERCENTAGE("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.repr=this.repr,e}toSource(){return this.repr+"%"}}class dx extends Ye{constructor(){super(),this.tokenType="DIMENSION",this.type="integer",this.repr="",this.unit=""}toString(){return"DIM("+this.value+","+this.unit+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.type=this.type,e.repr=this.repr,e.unit=this.unit,e}toSource(){const e=this.repr;let i=el(this.unit);return i[0].toLowerCase()==="e"&&(i[1]==="-"||Fe(i.charCodeAt(1),48,57))&&(i="\\65 "+i.slice(1,i.length)),e+i}}function el(n){n=""+n;let e="";const i=n.charCodeAt(0);for(let s=0;s<n.length;s++){const a=n.charCodeAt(s);if(a===0)throw new Oh("Invalid character: the input contains U+0000.");Fe(a,1,31)||a===127||s===0&&Fe(a,48,57)||s===1&&Fe(a,48,57)&&i===45?e+="\\"+a.toString(16)+" ":a>=128||a===45||a===95||Fe(a,48,57)||Fe(a,65,90)||Fe(a,97,122)?e+=n[s]:e+="\\"+n[s]}return e}function px(n){n=""+n;let e="";for(let i=0;i<n.length;i++){const s=n.charCodeAt(i);if(s===0)throw new Oh("Invalid character: the input contains U+0000.");s>=128||s===45||s===95||Fe(s,48,57)||Fe(s,65,90)||Fe(s,97,122)?e+=n[i]:e+="\\"+s.toString(16)+" "}return e}function G0(n){n=""+n;let e="";for(let i=0;i<n.length;i++){const s=n.charCodeAt(i);if(s===0)throw new Oh("Invalid character: the input contains U+0000.");Fe(s,1,31)||s===127?e+="\\"+s.toString(16)+" ":s===34||s===92?e+="\\"+n[i]:e+=n[i]}return e}class jt extends Error{}function gx(n,e){let i;try{i=N0(n),i[i.length-1]instanceof Ro||i.push(new Ro)}catch(R){const ee=R.message+` while parsing css selector "${n}". Did you mean to CSS.escape it?`,re=(R.stack||"").indexOf(R.message);throw re!==-1&&(R.stack=R.stack.substring(0,re)+ee+R.stack.substring(re+R.message.length)),R.message=ee,R}const s=i.find(R=>R instanceof H0||R instanceof C0||R instanceof Oo||R instanceof z0||R instanceof k0||R instanceof M0||R instanceof R0||R instanceof L0||R instanceof D0||R instanceof $0||R instanceof V0);if(s)throw new jt(`Unsupported token "${s.toSource()}" while parsing css selector "${n}". Did you mean to CSS.escape it?`);let a=0;const o=new Set;function u(){return new jt(`Unexpected token "${i[a].toSource()}" while parsing css selector "${n}". Did you mean to CSS.escape it?`)}function f(){for(;i[a]instanceof Go;)a++}function d(R=a){return i[R]instanceof jh}function p(R=a){return i[R]instanceof Lh}function m(R=a){return i[R]instanceof I0}function y(R=a){return i[R]instanceof j0}function b(R=a){return i[R]instanceof U0}function w(R=a){return i[R]instanceof Rh}function E(R=a){return i[R]instanceof qa}function x(R=a){return i[R]instanceof ct&&i[R].value==="*"}function _(R=a){return i[R]instanceof Ro}function k(R=a){return i[R]instanceof ct&&[">","+","~"].includes(i[R].value)}function C(R=a){return y(R)||w(R)||_(R)||k(R)||i[R]instanceof Go}function V(){const R=[I()];for(;f(),!!y();)a++,R.push(I());return R}function I(){return f(),m()||p()?i[a++].value:B()}function B(){const R={simples:[]};for(f(),k()?R.simples.push({selector:{functions:[{name:"scope",args:[]}]},combinator:""}):R.simples.push({selector:G(),combinator:""});;){if(f(),k())R.simples[R.simples.length-1].combinator=i[a++].value,f();else if(C())break;R.simples.push({combinator:"",selector:G()})}return R}function G(){let R="";const ee=[];for(;!C();)if(d()||x())R+=i[a++].toSource();else if(i[a]instanceof q0)R+=i[a++].toSource();else if(i[a]instanceof ct&&i[a].value===".")if(a++,d())R+="."+i[a++].toSource();else throw u();else if(i[a]instanceof O0)if(a++,d())if(!e.has(i[a].value.toLowerCase()))R+=":"+i[a++].toSource();else{const re=i[a++].value.toLowerCase();ee.push({name:re,args:[]}),o.add(re)}else if(E()){const re=i[a++].value.toLowerCase();if(e.has(re)?(ee.push({name:re,args:V()}),o.add(re)):R+=`:${re}(${J()})`,f(),!w())throw u();a++}else throw u();else if(i[a]instanceof B0){for(R+="[",a++;!(i[a]instanceof hh)&&!_();)R+=i[a++].toSource();if(!(i[a]instanceof hh))throw u();R+="]",a++}else throw u();if(!R&&!ee.length)throw u();return{css:R||void 0,functions:ee}}function J(){let R="",ee=1;for(;!_()&&((b()||E())&&ee++,w()&&ee--,!!ee);)R+=i[a++].toSource();return R}const $=V();if(!_())throw u();if($.some(R=>typeof R!="object"||!("simples"in R)))throw new jt(`Error while parsing css selector "${n}". Did you mean to CSS.escape it?`);return{selector:$,names:Array.from(o)}}const dh=new Set(["internal:has","internal:has-not","internal:and","internal:or","internal:chain","left-of","right-of","above","below","near"]),mx=new Set(["left-of","right-of","above","below","near"]),K0=new Set(["not","is","where","has","scope","light","visible","text","text-matches","text-is","has-text","above","below","right-of","left-of","near","nth-match"]);function tl(n){const e=vx(n),i=[];for(const s of e.parts){if(s.name==="css"||s.name==="css:light"){s.name==="css:light"&&(s.body=":light("+s.body+")");const a=gx(s.body,K0);i.push({name:"css",body:a.selector,source:s.body});continue}if(dh.has(s.name)){let a,o;try{const p=JSON.parse("["+s.body+"]");if(!Array.isArray(p)||p.length<1||p.length>2||typeof p[0]!="string")throw new jt(`Malformed selector: ${s.name}=`+s.body);if(a=p[0],p.length===2){if(typeof p[1]!="number"||!mx.has(s.name))throw new jt(`Malformed selector: ${s.name}=`+s.body);o=p[1]}}catch{throw new jt(`Malformed selector: ${s.name}=`+s.body)}const u={name:s.name,source:s.body,body:{parsed:tl(a),distance:o}},f=[...u.body.parsed.parts].reverse().find(p=>p.name==="internal:control"&&p.body==="enter-frame"),d=f?u.body.parsed.parts.indexOf(f):-1;d!==-1&&yx(u.body.parsed.parts.slice(0,d+1),i.slice(0,d+1))&&u.body.parsed.parts.splice(0,d+1),i.push(u);continue}i.push({...s,source:s.body})}if(dh.has(i[0].name))throw new jt(`"${i[0].name}" selector cannot be first`);return{capture:e.capture,parts:i}}function yx(n,e){return Gn({parts:n})===Gn({parts:e})}function Gn(n,e){return typeof n=="string"?n:n.parts.map((i,s)=>{let a=!0;!e&&s!==n.capture&&(i.name==="css"||i.name==="xpath"&&i.source.startsWith("//")||i.source.startsWith(".."))&&(a=!1);const o=a?i.name+"=":"";return`${s===n.capture?"*":""}${o}${i.source}`}).join(" >> ")}function bx(n,e){const i=(s,a)=>{for(const o of s.parts)e(o,a),dh.has(o.name)&&i(o.body.parsed,!0)};i(n,!1)}function vx(n){let e=0,i,s=0;const a={parts:[]},o=()=>{const f=n.substring(s,e).trim(),d=f.indexOf("=");let p,m;d!==-1&&f.substring(0,d).trim().match(/^[a-zA-Z_0-9-+:*]+$/)?(p=f.substring(0,d).trim(),m=f.substring(d+1)):f.length>1&&f[0]==='"'&&f[f.length-1]==='"'||f.length>1&&f[0]==="'"&&f[f.length-1]==="'"?(p="text",m=f):/^\(*\/\//.test(f)||f.startsWith("..")?(p="xpath",m=f):(p="css",m=f);let y=!1;if(p[0]==="*"&&(y=!0,p=p.substring(1)),a.parts.push({name:p,body:m}),y){if(a.capture!==void 0)throw new jt("Only one of the selectors can capture using * modifier");a.capture=a.parts.length-1}};if(!n.includes(">>"))return e=n.length,o(),a;const u=()=>{const d=n.substring(s,e).match(/^\s*text\s*=(.*)$/);return!!d&&!!d[1]};for(;e<n.length;){const f=n[e];f==="\\"&&e+1<n.length?e+=2:f===i?(i=void 0,e++):!i&&(f==='"'||f==="'"||f==="`")&&!u()?(i=f,e++):!i&&f===">"&&n[e+1]===">"?(o(),e+=2,s=e):e++}return o(),a}function Ji(n,e){let i=0,s=n.length===0;const a=()=>n[i]||"",o=()=>{const _=a();return++i,s=i>=n.length,_},u=_=>{throw s?new jt(`Unexpected end of selector while parsing selector \`${n}\``):new jt(`Error while parsing selector \`${n}\` - unexpected symbol "${a()}" at position ${i}`+(_?" during "+_:""))};function f(){for(;!s&&/\s/.test(a());)o()}function d(_){return _>=""||_>="0"&&_<="9"||_>="A"&&_<="Z"||_>="a"&&_<="z"||_>="0"&&_<="9"||_==="_"||_==="-"}function p(){let _="";for(f();!s&&d(a());)_+=o();return _}function m(_){let k=o();for(k!==_&&u("parsing quoted string");!s&&a()!==_;)a()==="\\"&&o(),k+=o();return a()!==_&&u("parsing quoted string"),k+=o(),k}function y(){o()!=="/"&&u("parsing regular expression");let _="",k=!1;for(;!s;){if(a()==="\\")_+=o(),s&&u("parsing regular expression");else if(k&&a()==="]")k=!1;else if(!k&&a()==="[")k=!0;else if(!k&&a()==="/")break;_+=o()}o()!=="/"&&u("parsing regular expression");let C="";for(;!s&&a().match(/[dgimsuy]/);)C+=o();try{return new RegExp(_,C)}catch(V){throw new jt(`Error while parsing selector \`${n}\`: ${V.message}`)}}function b(){let _="";return f(),a()==="'"||a()==='"'?_=m(a()).slice(1,-1):_=p(),_||u("parsing property path"),_}function w(){f();let _="";return s||(_+=o()),!s&&_!=="="&&(_+=o()),["=","*=","^=","$=","|=","~="].includes(_)||u("parsing operator"),_}function E(){o();const _=[];for(_.push(b()),f();a()===".";)o(),_.push(b()),f();if(a()==="]")return o(),{name:_.join("."),jsonPath:_,op:"<truthy>",value:null,caseSensitive:!1};const k=w();let C,V=!0;if(f(),a()==="/"){if(k!=="=")throw new jt(`Error while parsing selector \`${n}\` - cannot use ${k} in attribute with regular expression`);C=y()}else if(a()==="'"||a()==='"')C=m(a()).slice(1,-1),f(),a()==="i"||a()==="I"?(V=!1,o()):(a()==="s"||a()==="S")&&(V=!0,o());else{for(C="";!s&&(d(a())||a()==="+"||a()===".");)C+=o();C==="true"?C=!0:C==="false"?C=!1:e||(C=+C,Number.isNaN(C)&&u("parsing attribute value"))}if(f(),a()!=="]"&&u("parsing attribute value"),o(),k!=="="&&typeof C!="string")throw new jt(`Error while parsing selector \`${n}\` - cannot use ${k} in attribute with non-string matching value - ${C}`);return{name:_.join("."),jsonPath:_,op:k,value:C,caseSensitive:V}}const x={name:"",attributes:[]};for(x.name=p(),f();a()==="[";)x.attributes.push(E()),f();if(s||u(void 0),!x.name&&!x.attributes.length)throw new jt(`Error while parsing selector \`${n}\` - selector cannot be empty`);return x}function ic(n,e="'"){const i=JSON.stringify(n),s=i.substring(1,i.length-1).replace(/\\"/g,'"');if(e==="'")return e+s.replace(/[']/g,"\\'")+e;if(e==='"')return e+s.replace(/["]/g,'\\"')+e;if(e==="`")return e+s.replace(/[`]/g,"\\`")+e;throw new Error("Invalid escape char")}function Ko(n){return n.charAt(0).toUpperCase()+n.substring(1)}function Y0(n){return n.replace(/([a-z0-9])([A-Z])/g,"$1_$2").replace(/([A-Z])([A-Z][a-z])/g,"$1_$2").toLowerCase()}function Ws(n){return`"${n.replace(/["\\]/g,e=>"\\"+e)}"`}let Vi;function Sx(){Vi=new Map}function Tt(n){let e=Vi==null?void 0:Vi.get(n);return e===void 0&&(e=n.replace(/[\u200b\u00ad]/g,"").trim().replace(/\s+/g," "),Vi==null||Vi.set(n,e)),e}function sc(n){return n.replace(/(^|[^\\])(\\\\)*\\(['"`])/g,"$1$2$3")}function X0(n){return n.unicode||n.unicodeSets?String(n):String(n).replace(/(^|[^\\])(\\\\)*(["'`])/g,"$1$2\\$3").replace(/>>/g,"\\>\\>")}function Lt(n,e){return typeof n!="string"?X0(n):`${JSON.stringify(n)}${e?"s":"i"}`}function xt(n,e){return typeof n!="string"?X0(n):`"${n.replace(/\\/g,"\\\\").replace(/["]/g,'\\"')}"${e?"s":"i"}`}function wx(n,e,i=""){if(n.length<=e)return n;const s=[...n];return s.length>e?s.slice(0,e-i.length).join("")+i:s.join("")}function ky(n,e){return wx(n,e,"…")}function Yo(n){return n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function xx(n,e){const i=n.length,s=e.length;let a=0,o=0;const u=Array(i+1).fill(null).map(()=>Array(s+1).fill(0));for(let f=1;f<=i;f++)for(let d=1;d<=s;d++)n[f-1]===e[d-1]&&(u[f][d]=u[f-1][d-1]+1,u[f][d]>a&&(a=u[f][d],o=f));return n.slice(o-a,o)}function _x(n,e){try{const i=tl(e),s=Tx(i);return s||Xi(new F0[n],i,!1,1)[0]}catch{return e}}function Tx(n){const e=n.parts[n.parts.length-1];if((e==null?void 0:e.name)==="internal:describe"){const i=JSON.parse(e.body);if(typeof i=="string")return i}}function Wi(n,e,i=!1){return P0(n,e,i,1)[0]}function P0(n,e,i=!1,s=20,a){try{return Xi(new F0[n](a),tl(e),i,s)}catch{return[e]}}function Xi(n,e,i=!1,s=20){const a=[...e.parts],o=[];let u=i?"frame-locator":"page";for(let f=0;f<a.length;f++){const d=a[f],p=u;if(u="locator",d.name==="internal:describe")continue;if(d.name==="nth"){d.body==="0"?o.push([n.generateLocator(p,"first",""),n.generateLocator(p,"nth","0")]):d.body==="-1"?o.push([n.generateLocator(p,"last",""),n.generateLocator(p,"nth","-1")]):o.push([n.generateLocator(p,"nth",d.body)]);continue}if(d.name==="visible"){o.push([n.generateLocator(p,"visible",d.body),n.generateLocator(p,"default",`visible=${d.body}`)]);continue}if(d.name==="internal:text"){const{exact:E,text:x}=Aa(d.body);o.push([n.generateLocator(p,"text",x,{exact:E})]);continue}if(d.name==="internal:has-text"){const{exact:E,text:x}=Aa(d.body);if(!E){o.push([n.generateLocator(p,"has-text",x,{exact:E})]);continue}}if(d.name==="internal:has-not-text"){const{exact:E,text:x}=Aa(d.body);if(!E){o.push([n.generateLocator(p,"has-not-text",x,{exact:E})]);continue}}if(d.name==="internal:has"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"has",x)));continue}if(d.name==="internal:has-not"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"hasNot",x)));continue}if(d.name==="internal:and"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"and",x)));continue}if(d.name==="internal:or"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"or",x)));continue}if(d.name==="internal:chain"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"chain",x)));continue}if(d.name==="internal:label"){const{exact:E,text:x}=Aa(d.body);o.push([n.generateLocator(p,"label",x,{exact:E})]);continue}if(d.name==="internal:role"){const E=Ji(d.body,!0),x={attrs:[]};for(const _ of E.attributes)_.name==="name"?(x.exact=_.caseSensitive,x.name=_.value):(_.name==="level"&&typeof _.value=="string"&&(_.value=+_.value),x.attrs.push({name:_.name==="include-hidden"?"includeHidden":_.name,value:_.value}));o.push([n.generateLocator(p,"role",E.name,x)]);continue}if(d.name==="internal:testid"){const E=Ji(d.body,!0),{value:x}=E.attributes[0];o.push([n.generateLocator(p,"test-id",x)]);continue}if(d.name==="internal:attr"){const E=Ji(d.body,!0),{name:x,value:_,caseSensitive:k}=E.attributes[0],C=_,V=!!k;if(x==="placeholder"){o.push([n.generateLocator(p,"placeholder",C,{exact:V})]);continue}if(x==="alt"){o.push([n.generateLocator(p,"alt",C,{exact:V})]);continue}if(x==="title"){o.push([n.generateLocator(p,"title",C,{exact:V})]);continue}}if(d.name==="internal:control"&&d.body==="enter-frame"){const E=o[o.length-1],x=a[f-1],_=E.map(k=>n.chainLocators([k,n.generateLocator(p,"frame","")]));["xpath","css"].includes(x.name)&&_.push(n.generateLocator(p,"frame-locator",Gn({parts:[x]})),n.generateLocator(p,"frame-locator",Gn({parts:[x]},!0))),E.splice(0,E.length,..._),u="frame-locator";continue}const m=a[f+1],y=Gn({parts:[d]}),b=n.generateLocator(p,"default",y);if(m&&["internal:has-text","internal:has-not-text"].includes(m.name)){const{exact:E,text:x}=Aa(m.body);if(!E){const _=n.generateLocator("locator",m.name==="internal:has-text"?"has-text":"has-not-text",x,{exact:E}),k={};m.name==="internal:has-text"?k.hasText=x:k.hasNotText=x;const C=n.generateLocator(p,"default",y,k);o.push([n.chainLocators([b,_]),C]),f++;continue}}let w;if(["xpath","css"].includes(d.name)){const E=Gn({parts:[d]},!0);w=n.generateLocator(p,"default",E)}o.push([b,w].filter(Boolean))}return Ex(n,o,s)}function Ex(n,e,i){const s=e.map(()=>""),a=[],o=u=>{if(u===e.length)return a.push(n.chainLocators(s)),a.length<i;for(const f of e[u])if(s[u]=f,!o(u+1))return!1;return!0};return o(0),a}function Aa(n){let e=!1;const i=n.match(/^\/(.*)\/([igm]*)$/);return i?{text:new RegExp(i[1],i[2])}:(n.endsWith('"')?(n=JSON.parse(n),e=!0):n.endsWith('"s')?(n=JSON.parse(n.substring(0,n.length-1)),e=!0):n.endsWith('"i')&&(n=JSON.parse(n.substring(0,n.length-1)),e=!1),{exact:e,text:n})}class Ax{constructor(e){this.preferredQuote=e}generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, { hasText: ${this.toHasText(a.hasText)} })`:a.hasNotText!==void 0?`locator(${this.quote(s)}, { hasNotText: ${this.toHasText(a.hasNotText)} })`:`locator(${this.quote(s)})`;case"frame-locator":return`frameLocator(${this.quote(s)})`;case"frame":return"contentFrame()";case"nth":return`nth(${s})`;case"first":return"first()";case"last":return"last()";case"visible":return`filter({ visible: ${s==="true"?"true":"false"} })`;case"role":const o=[];ut(a.name)?o.push(`name: ${this.regexToSourceString(a.name)}`):typeof a.name=="string"&&(o.push(`name: ${this.quote(a.name)}`),a.exact&&o.push("exact: true"));for(const{name:f,value:d}of a.attrs)o.push(`${f}: ${typeof d=="string"?this.quote(d):d}`);const u=o.length?`, { ${o.join(", ")} }`:"";return`getByRole(${this.quote(s)}${u})`;case"has-text":return`filter({ hasText: ${this.toHasText(s)} })`;case"has-not-text":return`filter({ hasNotText: ${this.toHasText(s)} })`;case"has":return`filter({ has: ${s} })`;case"hasNot":return`filter({ hasNot: ${s} })`;case"and":return`and(${s})`;case"or":return`or(${s})`;case"chain":return`locator(${s})`;case"test-id":return`getByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("getByText",s,!!a.exact);case"alt":return this.toCallWithExact("getByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact("getByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact("getByLabel",s,!!a.exact);case"title":return this.toCallWithExact("getByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToSourceString(e){return sc(String(e))}toCallWithExact(e,i,s){return ut(i)?`${e}(${this.regexToSourceString(i)})`:s?`${e}(${this.quote(i)}, { exact: true })`:`${e}(${this.quote(i)})`}toHasText(e){return ut(e)?this.regexToSourceString(e):this.quote(e)}toTestIdValue(e){return ut(e)?this.regexToSourceString(e):this.quote(e)}quote(e){return ic(e,this.preferredQuote??"'")}}class Nx{generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, has_text=${this.toHasText(a.hasText)})`:a.hasNotText!==void 0?`locator(${this.quote(s)}, has_not_text=${this.toHasText(a.hasNotText)})`:`locator(${this.quote(s)})`;case"frame-locator":return`frame_locator(${this.quote(s)})`;case"frame":return"content_frame";case"nth":return`nth(${s})`;case"first":return"first";case"last":return"last";case"visible":return`filter(visible=${s==="true"?"True":"False"})`;case"role":const o=[];ut(a.name)?o.push(`name=${this.regexToString(a.name)}`):typeof a.name=="string"&&(o.push(`name=${this.quote(a.name)}`),a.exact&&o.push("exact=True"));for(const{name:f,value:d}of a.attrs){let p=typeof d=="string"?this.quote(d):d;typeof d=="boolean"&&(p=d?"True":"False"),o.push(`${Y0(f)}=${p}`)}const u=o.length?`, ${o.join(", ")}`:"";return`get_by_role(${this.quote(s)}${u})`;case"has-text":return`filter(has_text=${this.toHasText(s)})`;case"has-not-text":return`filter(has_not_text=${this.toHasText(s)})`;case"has":return`filter(has=${s})`;case"hasNot":return`filter(has_not=${s})`;case"and":return`and_(${s})`;case"or":return`or_(${s})`;case"chain":return`locator(${s})`;case"test-id":return`get_by_test_id(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("get_by_text",s,!!a.exact);case"alt":return this.toCallWithExact("get_by_alt_text",s,!!a.exact);case"placeholder":return this.toCallWithExact("get_by_placeholder",s,!!a.exact);case"label":return this.toCallWithExact("get_by_label",s,!!a.exact);case"title":return this.toCallWithExact("get_by_title",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", re.IGNORECASE":"";return`re.compile(r"${sc(e.source).replace(/\\\//,"/").replace(/"/g,'\\"')}"${i})`}toCallWithExact(e,i,s){return ut(i)?`${e}(${this.regexToString(i)})`:s?`${e}(${this.quote(i)}, exact=True)`:`${e}(${this.quote(i)})`}toHasText(e){return ut(e)?this.regexToString(e):`${this.quote(e)}`}toTestIdValue(e){return ut(e)?this.regexToString(e):this.quote(e)}quote(e){return ic(e,'"')}}class Cx{generateLocator(e,i,s,a={}){let o;switch(e){case"page":o="Page";break;case"frame-locator":o="FrameLocator";break;case"locator":o="Locator";break}switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, new ${o}.LocatorOptions().setHasText(${this.toHasText(a.hasText)}))`:a.hasNotText!==void 0?`locator(${this.quote(s)}, new ${o}.LocatorOptions().setHasNotText(${this.toHasText(a.hasNotText)}))`:`locator(${this.quote(s)})`;case"frame-locator":return`frameLocator(${this.quote(s)})`;case"frame":return"contentFrame()";case"nth":return`nth(${s})`;case"first":return"first()";case"last":return"last()";case"visible":return`filter(new ${o}.FilterOptions().setVisible(${s==="true"?"true":"false"}))`;case"role":const u=[];ut(a.name)?u.push(`.setName(${this.regexToString(a.name)})`):typeof a.name=="string"&&(u.push(`.setName(${this.quote(a.name)})`),a.exact&&u.push(".setExact(true)"));for(const{name:d,value:p}of a.attrs)u.push(`.set${Ko(d)}(${typeof p=="string"?this.quote(p):p})`);const f=u.length?`, new ${o}.GetByRoleOptions()${u.join("")}`:"";return`getByRole(AriaRole.${Y0(s).toUpperCase()}${f})`;case"has-text":return`filter(new ${o}.FilterOptions().setHasText(${this.toHasText(s)}))`;case"has-not-text":return`filter(new ${o}.FilterOptions().setHasNotText(${this.toHasText(s)}))`;case"has":return`filter(new ${o}.FilterOptions().setHas(${s}))`;case"hasNot":return`filter(new ${o}.FilterOptions().setHasNot(${s}))`;case"and":return`and(${s})`;case"or":return`or(${s})`;case"chain":return`locator(${s})`;case"test-id":return`getByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact(o,"getByText",s,!!a.exact);case"alt":return this.toCallWithExact(o,"getByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact(o,"getByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact(o,"getByLabel",s,!!a.exact);case"title":return this.toCallWithExact(o,"getByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", Pattern.CASE_INSENSITIVE":"";return`Pattern.compile(${this.quote(sc(e.source))}${i})`}toCallWithExact(e,i,s,a){return ut(s)?`${i}(${this.regexToString(s)})`:a?`${i}(${this.quote(s)}, new ${e}.${Ko(i)}Options().setExact(true))`:`${i}(${this.quote(s)})`}toHasText(e){return ut(e)?this.regexToString(e):this.quote(e)}toTestIdValue(e){return ut(e)?this.regexToString(e):this.quote(e)}quote(e){return ic(e,'"')}}class kx{generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`Locator(${this.quote(s)}, new() { ${this.toHasText(a.hasText)} })`:a.hasNotText!==void 0?`Locator(${this.quote(s)}, new() { ${this.toHasNotText(a.hasNotText)} })`:`Locator(${this.quote(s)})`;case"frame-locator":return`FrameLocator(${this.quote(s)})`;case"frame":return"ContentFrame";case"nth":return`Nth(${s})`;case"first":return"First";case"last":return"Last";case"visible":return`Filter(new() { Visible = ${s==="true"?"true":"false"} })`;case"role":const o=[];ut(a.name)?o.push(`NameRegex = ${this.regexToString(a.name)}`):typeof a.name=="string"&&(o.push(`Name = ${this.quote(a.name)}`),a.exact&&o.push("Exact = true"));for(const{name:f,value:d}of a.attrs)o.push(`${Ko(f)} = ${typeof d=="string"?this.quote(d):d}`);const u=o.length?`, new() { ${o.join(", ")} }`:"";return`GetByRole(AriaRole.${Ko(s)}${u})`;case"has-text":return`Filter(new() { ${this.toHasText(s)} })`;case"has-not-text":return`Filter(new() { ${this.toHasNotText(s)} })`;case"has":return`Filter(new() { Has = ${s} })`;case"hasNot":return`Filter(new() { HasNot = ${s} })`;case"and":return`And(${s})`;case"or":return`Or(${s})`;case"chain":return`Locator(${s})`;case"test-id":return`GetByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("GetByText",s,!!a.exact);case"alt":return this.toCallWithExact("GetByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact("GetByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact("GetByLabel",s,!!a.exact);case"title":return this.toCallWithExact("GetByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", RegexOptions.IgnoreCase":"";return`new Regex(${this.quote(sc(e.source))}${i})`}toCallWithExact(e,i,s){return ut(i)?`${e}(${this.regexToString(i)})`:s?`${e}(${this.quote(i)}, new() { Exact = true })`:`${e}(${this.quote(i)})`}toHasText(e){return ut(e)?`HasTextRegex = ${this.regexToString(e)}`:`HasText = ${this.quote(e)}`}toTestIdValue(e){return ut(e)?this.regexToString(e):this.quote(e)}toHasNotText(e){return ut(e)?`HasNotTextRegex = ${this.regexToString(e)}`:`HasNotText = ${this.quote(e)}`}quote(e){return ic(e,'"')}}class Mx{generateLocator(e,i,s,a={}){return JSON.stringify({kind:i,body:s,options:a})}chainLocators(e){const i=e.map(s=>JSON.parse(s));for(let s=0;s<i.length-1;++s)i[s].next=i[s+1];return JSON.stringify(i[0])}}const F0={javascript:Ax,python:Nx,java:Cx,csharp:kx,jsonl:Mx};function ut(n){return n instanceof RegExp}const My=new Map;function Ox({name:n,rootItem:e,render:i,title:s,icon:a,isError:o,isVisible:u,selectedItem:f,onAccepted:d,onSelected:p,onHighlighted:m,treeState:y,setTreeState:b,noItemsMessage:w,dataTestId:E,autoExpandDepth:x}){const _=U.useMemo(()=>Rx(e,f,y.expandedItems,x||0,u),[e,f,y,x,u]),k=U.useRef(null),[C,V]=U.useState(),[I,B]=U.useState(!1);U.useEffect(()=>{m==null||m(C)},[m,C]),U.useEffect(()=>{const $=k.current;if(!$)return;const R=()=>{My.set(n,$.scrollTop)};return $.addEventListener("scroll",R,{passive:!0}),()=>$.removeEventListener("scroll",R)},[n]),U.useEffect(()=>{k.current&&(k.current.scrollTop=My.get(n)||0)},[n]);const G=U.useCallback($=>{const{expanded:R}=_.get($);if(R){for(let ee=f;ee;ee=ee.parent)if(ee===$){p==null||p($);break}y.expandedItems.set($.id,!1)}else y.expandedItems.set($.id,!0);b({...y})},[_,f,p,y,b]),J=U.useCallback($=>{const{expanded:R}=_.get($),ee=[$];for(;ee.length;){const re=ee.pop();ee.push(...re.children),y.expandedItems.set(re.id,!R)}b({...y})},[_,y,b]);return v.jsx("div",{className:Ke("tree-view vbox",n+"-tree-view"),"data-testid":E||n+"-tree",children:v.jsxs("div",{className:Ke("tree-view-content"),role:_.size>0?"tree":void 0,tabIndex:0,onKeyDown:$=>{if(f&&$.key==="Enter"){d==null||d(f);return}if($.key!=="ArrowDown"&&$.key!=="ArrowUp"&&$.key!=="ArrowLeft"&&$.key!=="ArrowRight")return;if($.stopPropagation(),$.preventDefault(),f&&$.key==="ArrowLeft"){const{expanded:ee,parent:re}=_.get(f);ee?(y.expandedItems.set(f.id,!1),b({...y})):re&&(p==null||p(re));return}if(f&&$.key==="ArrowRight"){f.children.length&&(y.expandedItems.set(f.id,!0),b({...y}));return}let R=f;if($.key==="ArrowDown"&&(f?R=_.get(f).next:_.size&&(R=[..._.keys()][0])),$.key==="ArrowUp"){if(f)R=_.get(f).prev;else if(_.size){const ee=[..._.keys()];R=ee[ee.length-1]}}m==null||m(void 0),R&&(B(!0),p==null||p(R)),V(void 0)},ref:k,children:[w&&_.size===0&&v.jsx("div",{className:"tree-view-empty",children:w}),e.children.map($=>_.get($)&&v.jsx(Q0,{item:$,treeItems:_,selectedItem:f,onSelected:p,onAccepted:d,isError:o,toggleExpanded:G,toggleSubtree:J,highlightedItem:C,setHighlightedItem:V,render:i,icon:a,title:s,isKeyboardNavigation:I,setIsKeyboardNavigation:B},$.id))]})})}function Q0({item:n,treeItems:e,selectedItem:i,onSelected:s,highlightedItem:a,setHighlightedItem:o,isError:u,onAccepted:f,toggleExpanded:d,toggleSubtree:p,render:m,title:y,icon:b,isKeyboardNavigation:w,setIsKeyboardNavigation:E}){const x=U.useId(),_=U.useRef(null);U.useEffect(()=>{i===n&&w&&_.current&&(S0(_.current),E(!1))},[n,i,w,E]);const k=e.get(n),C=k.depth,V=k.expanded;let I="codicon-blank";typeof V=="boolean"&&(I=V?"codicon-chevron-down":"codicon-chevron-right");const B=m(n),G=V&&n.children.length?n.children:[],J=y==null?void 0:y(n),$=(b==null?void 0:b(n))||"codicon-blank";return v.jsxs("div",{ref:_,role:"treeitem","aria-selected":n===i,"aria-expanded":V,"aria-controls":x,title:J,className:"vbox",style:{flex:"none"},children:[v.jsxs("div",{onDoubleClick:()=>f==null?void 0:f(n),className:Ke("tree-view-entry",i===n&&"selected",a===n&&"highlighted",(u==null?void 0:u(n))&&"error"),onClick:()=>s==null?void 0:s(n),onMouseEnter:()=>o(n),onMouseLeave:()=>o(void 0),children:[C?new Array(C).fill(0).map((R,ee)=>v.jsx("div",{className:"tree-view-indent"},"indent-"+ee)):void 0,v.jsx("div",{"aria-hidden":"true",className:"codicon "+I,style:{minWidth:16,marginRight:4},onDoubleClick:R=>{R.preventDefault(),R.stopPropagation()},onClick:R=>{R.stopPropagation(),R.preventDefault(),R.altKey?p(n):d(n)}}),b&&v.jsx("div",{className:"codicon "+$,style:{minWidth:16,marginRight:4},"aria-label":"["+$.replace("codicon","icon")+"]"}),typeof B=="string"?v.jsx("div",{style:{textOverflow:"ellipsis",overflow:"hidden"},children:B}):B]}),!!G.length&&v.jsx("div",{id:x,role:"group",children:G.map(R=>e.get(R)&&v.jsx(Q0,{item:R,treeItems:e,selectedItem:i,onSelected:s,onAccepted:f,isError:u,toggleExpanded:d,toggleSubtree:p,highlightedItem:a,setHighlightedItem:o,render:m,title:y,icon:b,isKeyboardNavigation:w,setIsKeyboardNavigation:E},R.id))})]})}function Rx(n,e,i,s,a=()=>!0){if(!a(n))return new Map;const o=new Map,u=new Set;for(let p=e==null?void 0:e.parent;p;p=p.parent)u.add(p.id);let f=null;const d=(p,m)=>{for(const y of p.children){if(!a(y))continue;const b=u.has(y.id)||i.get(y.id),w=s>m&&o.size<25&&b!==!1,E=y.children.length?b??w:void 0,x={depth:m,expanded:E,parent:n===p?null:p,next:null,prev:f};f&&(o.get(f).next=y),f=y,o.set(y,x),E&&d(y,m+1)}};return d(n,0),o}const zt=U.forwardRef(function({children:e,title:i="",icon:s,disabled:a=!1,toggled:o=!1,onClick:u=()=>{},style:f,testId:d,className:p,ariaLabel:m},y){return v.jsxs("button",{ref:y,className:Ke(p,"toolbar-button",s,o&&"toggled"),onMouseDown:Oy,onClick:u,onDoubleClick:Oy,title:i,disabled:!!a,style:f,"data-testid":d,"aria-label":m||i,children:[s&&v.jsx("span",{className:`codicon codicon-${s}`,style:e?{marginRight:5}:{}}),e]})}),Oy=n=>{n.stopPropagation(),n.preventDefault()};function Z0(n){return n==="scheduled"?"codicon-clock":n==="running"?"codicon-loading":n==="failed"?"codicon-error":n==="passed"?"codicon-check":n==="skipped"?"codicon-circle-slash":"codicon-circle-outline"}function jx(n){return n==="scheduled"?"Pending":n==="running"?"Running":n==="failed"?"Failed":n==="passed"?"Passed":n==="skipped"?"Skipped":"Did not run"}const Lx=Ox,Dx=({actions:n,selectedAction:e,selectedTime:i,setSelectedTime:s,sdkLanguage:a,onSelected:o,onHighlighted:u,revealConsole:f,revealAttachment:d,isLive:p})=>{const[m,y]=U.useState({expandedItems:new Map}),{rootItem:b,itemMap:w}=U.useMemo(()=>Fw(n),[n]),{selectedItem:E}=U.useMemo(()=>({selectedItem:e?w.get(e.callId):void 0}),[w,e]),x=U.useCallback(B=>{var G,J;return!!((J=(G=B.action)==null?void 0:G.error)!=null&&J.message)},[]),_=U.useCallback(B=>s({minimum:B.action.startTime,maximum:B.action.endTime}),[s]),k=U.useCallback(B=>Dh(B.action,{sdkLanguage:a,revealConsole:f,revealAttachment:d,isLive:p,showDuration:!0,showBadges:!0}),[p,f,d,a]),C=U.useCallback(B=>!i||!B.action||B.action.startTime<=i.maximum&&B.action.endTime>=i.minimum,[i]),V=U.useCallback(B=>{o==null||o(B.action)},[o]),I=U.useCallback(B=>{u==null||u(B==null?void 0:B.action)},[u]);return v.jsxs("div",{className:"vbox",children:[i&&v.jsxs("div",{className:"action-list-show-all",onClick:()=>s(void 0),children:[v.jsx("span",{className:"codicon codicon-triangle-left"}),"Show all"]}),v.jsx(Lx,{name:"actions",rootItem:b,treeState:m,setTreeState:y,selectedItem:E,onSelected:V,onHighlighted:I,onAccepted:_,isError:x,isVisible:C,render:k})]})},Dh=(n,e)=>{var _,k;const{sdkLanguage:i,revealConsole:s,revealAttachment:a,isLive:o,showDuration:u,showBadges:f}=e,{errors:d,warnings:p}=Zw(n),m=!!((_=n.attachments)!=null&&_.length)&&!!a,y=n.params.selector?_x(i||"javascript",n.params.selector):void 0,b=n.class==="Test"&&n.method==="test.step"&&((k=n.annotations)==null?void 0:k.some(C=>C.type==="skip"));let w="";n.endTime?w=_t(n.endTime-n.startTime):n.error?w="Timed out":o||(w="-");const{elements:E,title:x}=J0(n);return v.jsxs("div",{className:"action-title vbox",children:[v.jsxs("div",{className:"hbox",children:[v.jsx("span",{className:"action-title-method",title:x,children:E}),(u||f||m||b)&&v.jsx("div",{className:"spacer"}),m&&v.jsx(zt,{icon:"attach",title:"Open Attachment",onClick:()=>a(n.attachments[0])}),u&&!b&&v.jsx("div",{className:"action-duration",children:w||v.jsx("span",{className:"codicon codicon-loading"})}),b&&v.jsx("span",{className:Ke("action-skipped","codicon",Z0("skipped")),title:"skipped"}),f&&v.jsxs("div",{className:"action-icons",onClick:()=>s==null?void 0:s(),children:[!!d&&v.jsxs("div",{className:"action-icon",children:[v.jsx("span",{className:"codicon codicon-error"}),v.jsx("span",{className:"action-icon-value",children:d})]}),!!p&&v.jsxs("div",{className:"action-icon",children:[v.jsx("span",{className:"codicon codicon-warning"}),v.jsx("span",{className:"action-icon-value",children:p})]})]})]}),y&&v.jsx("div",{className:"action-title-selector",title:y,children:y})]})};function J0(n){var f;const e=n.title??((f=x0.get(n.class+"."+n.method))==null?void 0:f.title)??n.method,i=[],s=[];let a=0;const o=/\{([^}]+)\}/g;let u;for(;(u=o.exec(e))!==null;){const[d,p]=u,m=e.slice(a,u.index);i.push(m),s.push(m);const y=qw(n.params,p);y===void 0?(i.push(d),s.push(d)):u.index===0?(i.push(y),s.push(y)):(i.push(v.jsx("span",{className:"action-title-param",children:y},i.length)),s.push(y)),a=u.index+d.length}if(a<e.length){const d=e.slice(a);i.push(d),s.push(d)}return{elements:i,title:s.join("")}}const Bh=({value:n,description:e})=>{const[i,s]=U.useState("copy"),a=U.useCallback(()=>{(typeof n=="function"?n():Promise.resolve(n)).then(u=>{navigator.clipboard.writeText(u).then(()=>{s("check"),setTimeout(()=>{s("copy")},3e3)},()=>{s("close")})},()=>{s("close")})},[n]);return v.jsx(zt,{title:e||"Copy",icon:i,onClick:a})},jo=({value:n,description:e,copiedDescription:i=e,style:s})=>{const[a,o]=U.useState(!1),u=U.useCallback(async()=>{const f=typeof n=="function"?await n():n;await navigator.clipboard.writeText(f),o(!0),setTimeout(()=>o(!1),3e3)},[n]);return v.jsx(zt,{style:s,title:e,onClick:u,className:"copy-to-clipboard-text-button",children:a?i:e})},ns=({text:n})=>v.jsx("div",{className:"fill",style:{display:"flex",alignItems:"center",justifyContent:"center",fontSize:24,fontWeight:"bold",opacity:.5},children:n}),Bx=({action:n,startTimeOffset:e,sdkLanguage:i})=>{const s=U.useMemo(()=>Object.keys((n==null?void 0:n.params)??{}).filter(f=>f!=="info"),[n]);if(!n)return v.jsx(ns,{text:"No action selected"});const a=n.startTime-e,o=_t(a),{title:u}=J0(n);return v.jsxs("div",{className:"call-tab",children:[v.jsx("div",{className:"call-line",children:u}),v.jsx("div",{className:"call-section",children:"Time"}),vo({name:"start",type:"literal",text:o}),vo({name:"duration",type:"literal",text:Ux(n)}),!!s.length&&v.jsxs(v.Fragment,{children:[v.jsx("div",{className:"call-section",children:"Parameters"}),s.map(f=>vo(Ry(n,f,n.params[f],i)))]}),!!n.result&&v.jsxs(v.Fragment,{children:[v.jsx("div",{className:"call-section",children:"Return value"}),Object.keys(n.result).map(f=>vo(Ry(n,f,n.result[f],i)))]})]})};function Ux(n){return n.endTime?_t(n.endTime-n.startTime):n.error?"Timed Out":"Running"}function vo(n){let e=n.text.replace(/\n/g,"↵");return n.type==="string"&&(e=`"${e}"`),v.jsxs("div",{className:"call-line",children:[n.name,":",v.jsx("span",{className:Ke("call-value",n.type),title:n.text,children:e}),["literal","string","number","object","locator"].includes(n.type)&&v.jsx(Bh,{value:n.text})]},n.name)}function Ry(n,e,i,s){const a=n.method.includes("eval")||n.method==="waitForFunction";if(e==="files")return{text:"<files>",type:"string",name:e};if((e==="eventInit"||e==="expectedValue"||e==="arg"&&a)&&(i=Xo(i.value,new Array(10).fill({handle:"<handle>"}))),(e==="value"&&a||e==="received"&&n.method==="expect")&&(i=Xo(i,new Array(10).fill({handle:"<handle>"}))),e==="selector")return{text:Wi(s||"javascript",n.params.selector),type:"locator",name:"locator"};const o=typeof i;return o!=="object"||i===null?{text:String(i),type:o,name:e}:i.guid?{text:"<handle>",type:"handle",name:e}:{text:JSON.stringify(i).slice(0,1e3),type:"object",name:e}}function Xo(n,e){if(n.n!==void 0)return n.n;if(n.s!==void 0)return n.s;if(n.b!==void 0)return n.b;if(n.v!==void 0){if(n.v==="undefined")return;if(n.v==="null")return null;if(n.v==="NaN")return NaN;if(n.v==="Infinity")return 1/0;if(n.v==="-Infinity")return-1/0;if(n.v==="-0")return-0}if(n.d!==void 0)return new Date(n.d);if(n.r!==void 0)return new RegExp(n.r.p,n.r.f);if(n.a!==void 0)return n.a.map(i=>Xo(i,e));if(n.o!==void 0){const i={};for(const{k:s,v:a}of n.o)i[s]=Xo(a,e);return i}return n.h!==void 0?e===void 0?"<object>":e[n.h]:"<object>"}const jy=new Map;function rc({name:n,items:e=[],id:i,render:s,icon:a,isError:o,isWarning:u,isInfo:f,selectedItem:d,onAccepted:p,onSelected:m,onHighlighted:y,onIconClicked:b,noItemsMessage:w,dataTestId:E,notSelectable:x,ariaLabel:_}){const k=U.useRef(null),[C,V]=U.useState();return U.useEffect(()=>{y==null||y(C)},[y,C]),U.useEffect(()=>{const I=k.current;if(!I)return;const B=()=>{jy.set(n,I.scrollTop)};return I.addEventListener("scroll",B,{passive:!0}),()=>I.removeEventListener("scroll",B)},[n]),U.useEffect(()=>{k.current&&(k.current.scrollTop=jy.get(n)||0)},[n]),v.jsx("div",{className:Ke("list-view vbox",n+"-list-view"),role:e.length>0?"list":void 0,"aria-label":_,children:v.jsxs("div",{className:Ke("list-view-content",x&&"not-selectable"),tabIndex:0,onKeyDown:I=>{var $;if(d&&I.key==="Enter"){p==null||p(d,e.indexOf(d));return}if(I.key!=="ArrowDown"&&I.key!=="ArrowUp")return;I.stopPropagation(),I.preventDefault();const B=d?e.indexOf(d):-1;let G=B;I.key==="ArrowDown"&&(B===-1?G=0:G=Math.min(B+1,e.length-1)),I.key==="ArrowUp"&&(B===-1?G=e.length-1:G=Math.max(B-1,0));const J=($=k.current)==null?void 0:$.children.item(G);S0(J||void 0),y==null||y(void 0),m==null||m(e[G],G),V(void 0)},ref:k,children:[w&&e.length===0&&v.jsx("div",{className:"list-view-empty",children:w}),e.map((I,B)=>{const G=s(I,B);return v.jsxs("div",{onDoubleClick:()=>p==null?void 0:p(I,B),role:"listitem",className:Ke("list-view-entry",d===I&&"selected",!x&&C===I&&"highlighted",(o==null?void 0:o(I,B))&&"error",(u==null?void 0:u(I,B))&&"warning",(f==null?void 0:f(I,B))&&"info"),"aria-selected":d===I,onClick:()=>m==null?void 0:m(I,B),onMouseEnter:()=>V(I),onMouseLeave:()=>V(void 0),children:[a&&v.jsx("div",{className:"codicon "+(a(I,B)||"codicon-blank"),style:{minWidth:16,marginRight:4},onDoubleClick:J=>{J.preventDefault(),J.stopPropagation()},onClick:J=>{J.stopPropagation(),J.preventDefault(),b==null||b(I,B)}}),typeof G=="string"?v.jsx("div",{style:{textOverflow:"ellipsis",overflow:"hidden"},children:G}):G]},(i==null?void 0:i(I,B))||B)})]})})}const zx=rc,Hx=({action:n,isLive:e})=>{const i=U.useMemo(()=>{var u;if(!n||!n.log.length)return[];const s=n.log,a=n.context.wallTime-n.context.startTime,o=[];for(let f=0;f<s.length;++f){let d="";if(s[f].time!==-1){const p=(u=s[f])==null?void 0:u.time;f+1<s.length?d=_t(s[f+1].time-p):n.endTime>0?d=_t(n.endTime-p):e?d=_t(Date.now()-a-p):d="-"}o.push({message:s[f].message,time:d})}return o},[n,e]);return i.length?v.jsx(zx,{name:"log",ariaLabel:"Log entries",items:i,render:s=>v.jsxs("div",{className:"log-list-item",children:[v.jsx("span",{className:"log-list-duration",children:s.time}),s.message]}),notSelectable:!0}):v.jsx(ns,{text:"No log entries"})};function Pa(n,e){const i=/(\x1b\[(\d+(;\d+)*)m)|([^\x1b]+)/g,s=[];let a,o={},u=!1,f=e==null?void 0:e.fg,d=e==null?void 0:e.bg;for(;(a=i.exec(n))!==null;){const[,,p,,m]=a;if(p){const y=+p;switch(y){case 0:o={};break;case 1:o["font-weight"]="bold";break;case 2:o.opacity="0.8";break;case 3:o["font-style"]="italic";break;case 4:o["text-decoration"]="underline";break;case 7:u=!0;break;case 8:o.display="none";break;case 9:o["text-decoration"]="line-through";break;case 22:delete o["font-weight"],delete o["font-style"],delete o.opacity,delete o["text-decoration"];break;case 23:delete o["font-weight"],delete o["font-style"],delete o.opacity;break;case 24:delete o["text-decoration"];break;case 27:u=!1;break;case 30:case 31:case 32:case 33:case 34:case 35:case 36:case 37:f=Ly[y-30];break;case 39:f=e==null?void 0:e.fg;break;case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:d=Ly[y-40];break;case 49:d=e==null?void 0:e.bg;break;case 53:o["text-decoration"]="overline";break;case 90:case 91:case 92:case 93:case 94:case 95:case 96:case 97:f=Dy[y-90];break;case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:d=Dy[y-100];break}}else if(m){const y={...o},b=u?d:f;b!==void 0&&(y.color=b);const w=u?f:d;w!==void 0&&(y["background-color"]=w),s.push(`<span style="${$x(y)}">${qx(m)}</span>`)}}return s.join("")}const Ly={0:"var(--vscode-terminal-ansiBlack)",1:"var(--vscode-terminal-ansiRed)",2:"var(--vscode-terminal-ansiGreen)",3:"var(--vscode-terminal-ansiYellow)",4:"var(--vscode-terminal-ansiBlue)",5:"var(--vscode-terminal-ansiMagenta)",6:"var(--vscode-terminal-ansiCyan)",7:"var(--vscode-terminal-ansiWhite)"},Dy={0:"var(--vscode-terminal-ansiBrightBlack)",1:"var(--vscode-terminal-ansiBrightRed)",2:"var(--vscode-terminal-ansiBrightGreen)",3:"var(--vscode-terminal-ansiBrightYellow)",4:"var(--vscode-terminal-ansiBrightBlue)",5:"var(--vscode-terminal-ansiBrightMagenta)",6:"var(--vscode-terminal-ansiBrightCyan)",7:"var(--vscode-terminal-ansiBrightWhite)"};function qx(n){return n.replace(/[&"<>]/g,e=>({"&":"&",'"':""","<":"<",">":">"})[e])}function $x(n){return Object.entries(n).map(([e,i])=>`${e}: ${i}`).join("; ")}const Ix=({error:n})=>{const e=U.useMemo(()=>Pa(n),[n]);return v.jsx("div",{className:"error-message",dangerouslySetInnerHTML:{__html:e||""}})},W0=({cursor:n,onPaneMouseMove:e,onPaneMouseUp:i,onPaneDoubleClick:s})=>(Ut.useEffect(()=>{const a=document.createElement("div");return a.style.position="fixed",a.style.top="0",a.style.right="0",a.style.bottom="0",a.style.left="0",a.style.zIndex="9999",a.style.cursor=n,document.body.appendChild(a),e&&a.addEventListener("mousemove",e),i&&a.addEventListener("mouseup",i),s&&document.body.addEventListener("dblclick",s),()=>{e&&a.removeEventListener("mousemove",e),i&&a.removeEventListener("mouseup",i),s&&document.body.removeEventListener("dblclick",s),document.body.removeChild(a)}},[n,e,i,s]),v.jsx(v.Fragment,{})),Vx={position:"absolute",top:0,right:0,bottom:0,left:0},eb=({orientation:n,offsets:e,setOffsets:i,resizerColor:s,resizerWidth:a,minColumnWidth:o})=>{const u=o||0,[f,d]=Ut.useState(null),[p,m]=ts(),y={position:"absolute",right:n==="horizontal"?void 0:0,bottom:n==="horizontal"?0:void 0,width:n==="horizontal"?7:void 0,height:n==="horizontal"?void 0:7,borderTopWidth:n==="horizontal"?void 0:(7-a)/2,borderRightWidth:n==="horizontal"?(7-a)/2:void 0,borderBottomWidth:n==="horizontal"?void 0:(7-a)/2,borderLeftWidth:n==="horizontal"?(7-a)/2:void 0,borderColor:"transparent",borderStyle:"solid",cursor:n==="horizontal"?"ew-resize":"ns-resize"};return v.jsxs("div",{style:{position:"absolute",top:0,right:0,bottom:0,left:-(7-a)/2,zIndex:100,pointerEvents:"none"},ref:m,children:[!!f&&v.jsx(W0,{cursor:n==="horizontal"?"ew-resize":"ns-resize",onPaneMouseUp:()=>d(null),onPaneMouseMove:b=>{if(!b.buttons)d(null);else if(f){const w=n==="horizontal"?b.clientX-f.clientX:b.clientY-f.clientY,E=f.offset+w,x=f.index>0?e[f.index-1]:0,_=n==="horizontal"?p.width:p.height,k=Math.min(Math.max(x+u,E),_-u)-e[f.index];for(let C=f.index;C<e.length;++C)e[C]=e[C]+k;i([...e])}}}),e.map((b,w)=>v.jsx("div",{style:{...y,top:n==="horizontal"?0:b,left:n==="horizontal"?b:0,pointerEvents:"initial"},onMouseDown:E=>d({clientX:E.clientX,clientY:E.clientY,offset:b,index:w}),children:v.jsx("div",{style:{...Vx,background:s}})},w))]})};async function Yf(n){const e=new Image;return n&&(e.src=n,await new Promise((i,s)=>{e.onload=i,e.onerror=i})),e}const ph={backgroundImage:`linear-gradient(45deg, #80808020 25%, transparent 25%),
|
|
49
|
+
`+l.stack}}function Pt(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function Ld(t){var r=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(r==="checkbox"||r==="radio")}function vS(t){var r=Ld(t)?"checked":"value",l=Object.getOwnPropertyDescriptor(t.constructor.prototype,r),c=""+t[r];if(!t.hasOwnProperty(r)&&typeof l<"u"&&typeof l.get=="function"&&typeof l.set=="function"){var h=l.get,g=l.set;return Object.defineProperty(t,r,{configurable:!0,get:function(){return h.call(this)},set:function(S){c=""+S,g.call(this,S)}}),Object.defineProperty(t,r,{enumerable:l.enumerable}),{getValue:function(){return c},setValue:function(S){c=""+S},stopTracking:function(){t._valueTracker=null,delete t[r]}}}}function ul(t){t._valueTracker||(t._valueTracker=vS(t))}function Dd(t){if(!t)return!1;var r=t._valueTracker;if(!r)return!0;var l=r.getValue(),c="";return t&&(c=Ld(t)?t.checked?"true":"false":t.value),t=c,t!==l?(r.setValue(t),!0):!1}function fl(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var SS=/[\n"\\]/g;function Ft(t){return t.replace(SS,function(r){return"\\"+r.charCodeAt(0).toString(16)+" "})}function Bc(t,r,l,c,h,g,S,T){t.name="",S!=null&&typeof S!="function"&&typeof S!="symbol"&&typeof S!="boolean"?t.type=S:t.removeAttribute("type"),r!=null?S==="number"?(r===0&&t.value===""||t.value!=r)&&(t.value=""+Pt(r)):t.value!==""+Pt(r)&&(t.value=""+Pt(r)):S!=="submit"&&S!=="reset"||t.removeAttribute("value"),r!=null?Uc(t,S,Pt(r)):l!=null?Uc(t,S,Pt(l)):c!=null&&t.removeAttribute("value"),h==null&&g!=null&&(t.defaultChecked=!!g),h!=null&&(t.checked=h&&typeof h!="function"&&typeof h!="symbol"),T!=null&&typeof T!="function"&&typeof T!="symbol"&&typeof T!="boolean"?t.name=""+Pt(T):t.removeAttribute("name")}function Bd(t,r,l,c,h,g,S,T){if(g!=null&&typeof g!="function"&&typeof g!="symbol"&&typeof g!="boolean"&&(t.type=g),r!=null||l!=null){if(!(g!=="submit"&&g!=="reset"||r!=null))return;l=l!=null?""+Pt(l):"",r=r!=null?""+Pt(r):l,T||r===t.value||(t.value=r),t.defaultValue=r}c=c??h,c=typeof c!="function"&&typeof c!="symbol"&&!!c,t.checked=T?t.checked:!!c,t.defaultChecked=!!c,S!=null&&typeof S!="function"&&typeof S!="symbol"&&typeof S!="boolean"&&(t.name=S)}function Uc(t,r,l){r==="number"&&fl(t.ownerDocument)===t||t.defaultValue===""+l||(t.defaultValue=""+l)}function gs(t,r,l,c){if(t=t.options,r){r={};for(var h=0;h<l.length;h++)r["$"+l[h]]=!0;for(l=0;l<t.length;l++)h=r.hasOwnProperty("$"+t[l].value),t[l].selected!==h&&(t[l].selected=h),h&&c&&(t[l].defaultSelected=!0)}else{for(l=""+Pt(l),r=null,h=0;h<t.length;h++){if(t[h].value===l){t[h].selected=!0,c&&(t[h].defaultSelected=!0);return}r!==null||t[h].disabled||(r=t[h])}r!==null&&(r.selected=!0)}}function Ud(t,r,l){if(r!=null&&(r=""+Pt(r),r!==t.value&&(t.value=r),l==null)){t.defaultValue!==r&&(t.defaultValue=r);return}t.defaultValue=l!=null?""+Pt(l):""}function zd(t,r,l,c){if(r==null){if(c!=null){if(l!=null)throw Error(s(92));if(me(c)){if(1<c.length)throw Error(s(93));c=c[0]}l=c}l==null&&(l=""),r=l}l=Pt(r),t.defaultValue=l,c=t.textContent,c===l&&c!==""&&c!==null&&(t.value=c)}function ms(t,r){if(r){var l=t.firstChild;if(l&&l===t.lastChild&&l.nodeType===3){l.nodeValue=r;return}}t.textContent=r}var wS=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Hd(t,r,l){var c=r.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?c?t.setProperty(r,""):r==="float"?t.cssFloat="":t[r]="":c?t.setProperty(r,l):typeof l!="number"||l===0||wS.has(r)?r==="float"?t.cssFloat=l:t[r]=(""+l).trim():t[r]=l+"px"}function qd(t,r,l){if(r!=null&&typeof r!="object")throw Error(s(62));if(t=t.style,l!=null){for(var c in l)!l.hasOwnProperty(c)||r!=null&&r.hasOwnProperty(c)||(c.indexOf("--")===0?t.setProperty(c,""):c==="float"?t.cssFloat="":t[c]="");for(var h in r)c=r[h],r.hasOwnProperty(h)&&l[h]!==c&&Hd(t,h,c)}else for(var g in r)r.hasOwnProperty(g)&&Hd(t,g,r[g])}function zc(t){if(t.indexOf("-")===-1)return!1;switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var xS=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),_S=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function hl(t){return _S.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}var Hc=null;function qc(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var ys=null,bs=null;function $d(t){var r=fs(t);if(r&&(t=r.stateNode)){var l=t[Nt]||null;e:switch(t=r.stateNode,r.type){case"input":if(Bc(t,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),r=l.name,l.type==="radio"&&r!=null){for(l=t;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Ft(""+r)+'"][type="radio"]'),r=0;r<l.length;r++){var c=l[r];if(c!==t&&c.form===t.form){var h=c[Nt]||null;if(!h)throw Error(s(90));Bc(c,h.value,h.defaultValue,h.defaultValue,h.checked,h.defaultChecked,h.type,h.name)}}for(r=0;r<l.length;r++)c=l[r],c.form===t.form&&Dd(c)}break e;case"textarea":Ud(t,l.value,l.defaultValue);break e;case"select":r=l.value,r!=null&&gs(t,!!l.multiple,r,!1)}}}var $c=!1;function Id(t,r,l){if($c)return t(r,l);$c=!0;try{var c=t(r);return c}finally{if($c=!1,(ys!==null||bs!==null)&&(Zl(),ys&&(r=ys,t=bs,bs=ys=null,$d(r),t)))for(r=0;r<t.length;r++)$d(t[r])}}function Rr(t,r){var l=t.stateNode;if(l===null)return null;var c=l[Nt]||null;if(c===null)return null;l=c[r];e:switch(r){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(c=!c.disabled)||(t=t.type,c=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!c;break e;default:t=!1}if(t)return null;if(l&&typeof l!="function")throw Error(s(231,r,typeof l));return l}var An=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ic=!1;if(An)try{var jr={};Object.defineProperty(jr,"passive",{get:function(){Ic=!0}}),window.addEventListener("test",jr,jr),window.removeEventListener("test",jr,jr)}catch{Ic=!1}var Qn=null,Vc=null,dl=null;function Vd(){if(dl)return dl;var t,r=Vc,l=r.length,c,h="value"in Qn?Qn.value:Qn.textContent,g=h.length;for(t=0;t<l&&r[t]===h[t];t++);var S=l-t;for(c=1;c<=S&&r[l-c]===h[g-c];c++);return dl=h.slice(t,1<c?1-c:void 0)}function pl(t){var r=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&r===13&&(t=13)):t=r,t===10&&(t=13),32<=t||t===13?t:0}function gl(){return!0}function Gd(){return!1}function Ct(t){function r(l,c,h,g,S){this._reactName=l,this._targetInst=h,this.type=c,this.nativeEvent=g,this.target=S,this.currentTarget=null;for(var T in t)t.hasOwnProperty(T)&&(l=t[T],this[T]=l?l(g):g[T]);return this.isDefaultPrevented=(g.defaultPrevented!=null?g.defaultPrevented:g.returnValue===!1)?gl:Gd,this.isPropagationStopped=Gd,this}return m(r.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=gl)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=gl)},persist:function(){},isPersistent:gl}),r}var Ni={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ml=Ct(Ni),Lr=m({},Ni,{view:0,detail:0}),TS=Ct(Lr),Gc,Kc,Dr,yl=m({},Lr,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Xc,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Dr&&(Dr&&t.type==="mousemove"?(Gc=t.screenX-Dr.screenX,Kc=t.screenY-Dr.screenY):Kc=Gc=0,Dr=t),Gc)},movementY:function(t){return"movementY"in t?t.movementY:Kc}}),Kd=Ct(yl),ES=m({},yl,{dataTransfer:0}),AS=Ct(ES),NS=m({},Lr,{relatedTarget:0}),Yc=Ct(NS),CS=m({},Ni,{animationName:0,elapsedTime:0,pseudoElement:0}),kS=Ct(CS),MS=m({},Ni,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),OS=Ct(MS),RS=m({},Ni,{data:0}),Yd=Ct(RS),jS={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},LS={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},DS={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function BS(t){var r=this.nativeEvent;return r.getModifierState?r.getModifierState(t):(t=DS[t])?!!r[t]:!1}function Xc(){return BS}var US=m({},Lr,{key:function(t){if(t.key){var r=jS[t.key]||t.key;if(r!=="Unidentified")return r}return t.type==="keypress"?(t=pl(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?LS[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Xc,charCode:function(t){return t.type==="keypress"?pl(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?pl(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),zS=Ct(US),HS=m({},yl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Xd=Ct(HS),qS=m({},Lr,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Xc}),$S=Ct(qS),IS=m({},Ni,{propertyName:0,elapsedTime:0,pseudoElement:0}),VS=Ct(IS),GS=m({},yl,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),KS=Ct(GS),YS=m({},Ni,{newState:0,oldState:0}),XS=Ct(YS),PS=[9,13,27,32],Pc=An&&"CompositionEvent"in window,Br=null;An&&"documentMode"in document&&(Br=document.documentMode);var FS=An&&"TextEvent"in window&&!Br,Pd=An&&(!Pc||Br&&8<Br&&11>=Br),Fd=" ",Qd=!1;function Zd(t,r){switch(t){case"keyup":return PS.indexOf(r.keyCode)!==-1;case"keydown":return r.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Jd(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var vs=!1;function QS(t,r){switch(t){case"compositionend":return Jd(r);case"keypress":return r.which!==32?null:(Qd=!0,Fd);case"textInput":return t=r.data,t===Fd&&Qd?null:t;default:return null}}function ZS(t,r){if(vs)return t==="compositionend"||!Pc&&Zd(t,r)?(t=Vd(),dl=Vc=Qn=null,vs=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(r.ctrlKey||r.altKey||r.metaKey)||r.ctrlKey&&r.altKey){if(r.char&&1<r.char.length)return r.char;if(r.which)return String.fromCharCode(r.which)}return null;case"compositionend":return Pd&&r.locale!=="ko"?null:r.data;default:return null}}var JS={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Wd(t){var r=t&&t.nodeName&&t.nodeName.toLowerCase();return r==="input"?!!JS[t.type]:r==="textarea"}function ep(t,r,l,c){ys?bs?bs.push(c):bs=[c]:ys=c,r=io(r,"onChange"),0<r.length&&(l=new ml("onChange","change",null,l,c),t.push({event:l,listeners:r}))}var Ur=null,zr=null;function WS(t){Lm(t,0)}function bl(t){var r=Or(t);if(Dd(r))return t}function tp(t,r){if(t==="change")return r}var np=!1;if(An){var Fc;if(An){var Qc="oninput"in document;if(!Qc){var ip=document.createElement("div");ip.setAttribute("oninput","return;"),Qc=typeof ip.oninput=="function"}Fc=Qc}else Fc=!1;np=Fc&&(!document.documentMode||9<document.documentMode)}function sp(){Ur&&(Ur.detachEvent("onpropertychange",rp),zr=Ur=null)}function rp(t){if(t.propertyName==="value"&&bl(zr)){var r=[];ep(r,zr,t,qc(t)),Id(WS,r)}}function e1(t,r,l){t==="focusin"?(sp(),Ur=r,zr=l,Ur.attachEvent("onpropertychange",rp)):t==="focusout"&&sp()}function t1(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return bl(zr)}function n1(t,r){if(t==="click")return bl(r)}function i1(t,r){if(t==="input"||t==="change")return bl(r)}function s1(t,r){return t===r&&(t!==0||1/t===1/r)||t!==t&&r!==r}var qt=typeof Object.is=="function"?Object.is:s1;function Hr(t,r){if(qt(t,r))return!0;if(typeof t!="object"||t===null||typeof r!="object"||r===null)return!1;var l=Object.keys(t),c=Object.keys(r);if(l.length!==c.length)return!1;for(c=0;c<l.length;c++){var h=l[c];if(!as.call(r,h)||!qt(t[h],r[h]))return!1}return!0}function ap(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function lp(t,r){var l=ap(t);t=0;for(var c;l;){if(l.nodeType===3){if(c=t+l.textContent.length,t<=r&&c>=r)return{node:l,offset:r-t};t=c}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=ap(l)}}function op(t,r){return t&&r?t===r?!0:t&&t.nodeType===3?!1:r&&r.nodeType===3?op(t,r.parentNode):"contains"in t?t.contains(r):t.compareDocumentPosition?!!(t.compareDocumentPosition(r)&16):!1:!1}function cp(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var r=fl(t.document);r instanceof t.HTMLIFrameElement;){try{var l=typeof r.contentWindow.location.href=="string"}catch{l=!1}if(l)t=r.contentWindow;else break;r=fl(t.document)}return r}function Zc(t){var r=t&&t.nodeName&&t.nodeName.toLowerCase();return r&&(r==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||r==="textarea"||t.contentEditable==="true")}var r1=An&&"documentMode"in document&&11>=document.documentMode,Ss=null,Jc=null,qr=null,Wc=!1;function up(t,r,l){var c=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Wc||Ss==null||Ss!==fl(c)||(c=Ss,"selectionStart"in c&&Zc(c)?c={start:c.selectionStart,end:c.selectionEnd}:(c=(c.ownerDocument&&c.ownerDocument.defaultView||window).getSelection(),c={anchorNode:c.anchorNode,anchorOffset:c.anchorOffset,focusNode:c.focusNode,focusOffset:c.focusOffset}),qr&&Hr(qr,c)||(qr=c,c=io(Jc,"onSelect"),0<c.length&&(r=new ml("onSelect","select",null,r,l),t.push({event:r,listeners:c}),r.target=Ss)))}function Ci(t,r){var l={};return l[t.toLowerCase()]=r.toLowerCase(),l["Webkit"+t]="webkit"+r,l["Moz"+t]="moz"+r,l}var ws={animationend:Ci("Animation","AnimationEnd"),animationiteration:Ci("Animation","AnimationIteration"),animationstart:Ci("Animation","AnimationStart"),transitionrun:Ci("Transition","TransitionRun"),transitionstart:Ci("Transition","TransitionStart"),transitioncancel:Ci("Transition","TransitionCancel"),transitionend:Ci("Transition","TransitionEnd")},eu={},fp={};An&&(fp=document.createElement("div").style,"AnimationEvent"in window||(delete ws.animationend.animation,delete ws.animationiteration.animation,delete ws.animationstart.animation),"TransitionEvent"in window||delete ws.transitionend.transition);function ki(t){if(eu[t])return eu[t];if(!ws[t])return t;var r=ws[t],l;for(l in r)if(r.hasOwnProperty(l)&&l in fp)return eu[t]=r[l];return t}var hp=ki("animationend"),dp=ki("animationiteration"),pp=ki("animationstart"),a1=ki("transitionrun"),l1=ki("transitionstart"),o1=ki("transitioncancel"),gp=ki("transitionend"),mp=new Map,tu="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");tu.push("scrollEnd");function cn(t,r){mp.set(t,r),Ai(r,[t])}var yp=new WeakMap;function Qt(t,r){if(typeof t=="object"&&t!==null){var l=yp.get(t);return l!==void 0?l:(r={value:t,source:r,stack:jd(r)},yp.set(t,r),r)}return{value:t,source:r,stack:jd(r)}}var Zt=[],xs=0,nu=0;function vl(){for(var t=xs,r=nu=xs=0;r<t;){var l=Zt[r];Zt[r++]=null;var c=Zt[r];Zt[r++]=null;var h=Zt[r];Zt[r++]=null;var g=Zt[r];if(Zt[r++]=null,c!==null&&h!==null){var S=c.pending;S===null?h.next=h:(h.next=S.next,S.next=h),c.pending=h}g!==0&&bp(l,h,g)}}function Sl(t,r,l,c){Zt[xs++]=t,Zt[xs++]=r,Zt[xs++]=l,Zt[xs++]=c,nu|=c,t.lanes|=c,t=t.alternate,t!==null&&(t.lanes|=c)}function iu(t,r,l,c){return Sl(t,r,l,c),wl(t)}function _s(t,r){return Sl(t,null,null,r),wl(t)}function bp(t,r,l){t.lanes|=l;var c=t.alternate;c!==null&&(c.lanes|=l);for(var h=!1,g=t.return;g!==null;)g.childLanes|=l,c=g.alternate,c!==null&&(c.childLanes|=l),g.tag===22&&(t=g.stateNode,t===null||t._visibility&1||(h=!0)),t=g,g=g.return;return t.tag===3?(g=t.stateNode,h&&r!==null&&(h=31-rt(l),t=g.hiddenUpdates,c=t[h],c===null?t[h]=[r]:c.push(r),r.lane=l|536870912),g):null}function wl(t){if(50<fa)throw fa=0,uf=null,Error(s(185));for(var r=t.return;r!==null;)t=r,r=t.return;return t.tag===3?t.stateNode:null}var Ts={};function c1(t,r,l,c){this.tag=t,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=r,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=c,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function $t(t,r,l,c){return new c1(t,r,l,c)}function su(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Nn(t,r){var l=t.alternate;return l===null?(l=$t(t.tag,r,t.key,t.mode),l.elementType=t.elementType,l.type=t.type,l.stateNode=t.stateNode,l.alternate=t,t.alternate=l):(l.pendingProps=r,l.type=t.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=t.flags&65011712,l.childLanes=t.childLanes,l.lanes=t.lanes,l.child=t.child,l.memoizedProps=t.memoizedProps,l.memoizedState=t.memoizedState,l.updateQueue=t.updateQueue,r=t.dependencies,l.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext},l.sibling=t.sibling,l.index=t.index,l.ref=t.ref,l.refCleanup=t.refCleanup,l}function vp(t,r){t.flags&=65011714;var l=t.alternate;return l===null?(t.childLanes=0,t.lanes=r,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=l.childLanes,t.lanes=l.lanes,t.child=l.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=l.memoizedProps,t.memoizedState=l.memoizedState,t.updateQueue=l.updateQueue,t.type=l.type,r=l.dependencies,t.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext}),t}function xl(t,r,l,c,h,g){var S=0;if(c=t,typeof t=="function")su(t)&&(S=1);else if(typeof t=="string")S=fw(t,l,se.current)?26:t==="html"||t==="head"||t==="body"?27:5;else e:switch(t){case R:return t=$t(31,l,r,h),t.elementType=R,t.lanes=g,t;case E:return Mi(l.children,h,g,r);case x:S=8,h|=24;break;case _:return t=$t(12,l,r,h|2),t.elementType=_,t.lanes=g,t;case B:return t=$t(13,l,r,h),t.elementType=B,t.lanes=g,t;case G:return t=$t(19,l,r,h),t.elementType=G,t.lanes=g,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case k:case V:S=10;break e;case C:S=9;break e;case I:S=11;break e;case J:S=14;break e;case $:S=16,c=null;break e}S=29,l=Error(s(130,t===null?"null":typeof t,"")),c=null}return r=$t(S,l,r,h),r.elementType=t,r.type=c,r.lanes=g,r}function Mi(t,r,l,c){return t=$t(7,t,c,r),t.lanes=l,t}function ru(t,r,l){return t=$t(6,t,null,r),t.lanes=l,t}function au(t,r,l){return r=$t(4,t.children!==null?t.children:[],t.key,r),r.lanes=l,r.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},r}var Es=[],As=0,_l=null,Tl=0,Jt=[],Wt=0,Oi=null,Cn=1,kn="";function Ri(t,r){Es[As++]=Tl,Es[As++]=_l,_l=t,Tl=r}function Sp(t,r,l){Jt[Wt++]=Cn,Jt[Wt++]=kn,Jt[Wt++]=Oi,Oi=t;var c=Cn;t=kn;var h=32-rt(c)-1;c&=~(1<<h),l+=1;var g=32-rt(r)+h;if(30<g){var S=h-h%5;g=(c&(1<<S)-1).toString(32),c>>=S,h-=S,Cn=1<<32-rt(r)+h|l<<h|c,kn=g+t}else Cn=1<<g|l<<h|c,kn=t}function lu(t){t.return!==null&&(Ri(t,1),Sp(t,1,0))}function ou(t){for(;t===_l;)_l=Es[--As],Es[As]=null,Tl=Es[--As],Es[As]=null;for(;t===Oi;)Oi=Jt[--Wt],Jt[Wt]=null,kn=Jt[--Wt],Jt[Wt]=null,Cn=Jt[--Wt],Jt[Wt]=null}var St=null,$e=null,Te=!1,ji=null,mn=!1,cu=Error(s(519));function Li(t){var r=Error(s(418,""));throw Vr(Qt(r,t)),cu}function wp(t){var r=t.stateNode,l=t.type,c=t.memoizedProps;switch(r[pt]=t,r[Nt]=c,l){case"dialog":be("cancel",r),be("close",r);break;case"iframe":case"object":case"embed":be("load",r);break;case"video":case"audio":for(l=0;l<da.length;l++)be(da[l],r);break;case"source":be("error",r);break;case"img":case"image":case"link":be("error",r),be("load",r);break;case"details":be("toggle",r);break;case"input":be("invalid",r),Bd(r,c.value,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name,!0),ul(r);break;case"select":be("invalid",r);break;case"textarea":be("invalid",r),zd(r,c.value,c.defaultValue,c.children),ul(r)}l=c.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||r.textContent===""+l||c.suppressHydrationWarning===!0||zm(r.textContent,l)?(c.popover!=null&&(be("beforetoggle",r),be("toggle",r)),c.onScroll!=null&&be("scroll",r),c.onScrollEnd!=null&&be("scrollend",r),c.onClick!=null&&(r.onclick=so),r=!0):r=!1,r||Li(t)}function xp(t){for(St=t.return;St;)switch(St.tag){case 5:case 13:mn=!1;return;case 27:case 3:mn=!0;return;default:St=St.return}}function $r(t){if(t!==St)return!1;if(!Te)return xp(t),Te=!0,!1;var r=t.tag,l;if((l=r!==3&&r!==27)&&((l=r===5)&&(l=t.type,l=!(l!=="form"&&l!=="button")||Af(t.type,t.memoizedProps)),l=!l),l&&$e&&Li(t),xp(t),r===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(s(317));e:{for(t=t.nextSibling,r=0;t;){if(t.nodeType===8)if(l=t.data,l==="/$"){if(r===0){$e=fn(t.nextSibling);break e}r--}else l!=="$"&&l!=="$!"&&l!=="$?"||r++;t=t.nextSibling}$e=null}}else r===27?(r=$e,hi(t.type)?(t=Mf,Mf=null,$e=t):$e=r):$e=St?fn(t.stateNode.nextSibling):null;return!0}function Ir(){$e=St=null,Te=!1}function _p(){var t=ji;return t!==null&&(Ot===null?Ot=t:Ot.push.apply(Ot,t),ji=null),t}function Vr(t){ji===null?ji=[t]:ji.push(t)}var uu=X(null),Di=null,Mn=null;function Zn(t,r,l){W(uu,r._currentValue),r._currentValue=l}function On(t){t._currentValue=uu.current,Q(uu)}function fu(t,r,l){for(;t!==null;){var c=t.alternate;if((t.childLanes&r)!==r?(t.childLanes|=r,c!==null&&(c.childLanes|=r)):c!==null&&(c.childLanes&r)!==r&&(c.childLanes|=r),t===l)break;t=t.return}}function hu(t,r,l,c){var h=t.child;for(h!==null&&(h.return=t);h!==null;){var g=h.dependencies;if(g!==null){var S=h.child;g=g.firstContext;e:for(;g!==null;){var T=g;g=h;for(var A=0;A<r.length;A++)if(T.context===r[A]){g.lanes|=l,T=g.alternate,T!==null&&(T.lanes|=l),fu(g.return,l,t),c||(S=null);break e}g=T.next}}else if(h.tag===18){if(S=h.return,S===null)throw Error(s(341));S.lanes|=l,g=S.alternate,g!==null&&(g.lanes|=l),fu(S,l,t),S=null}else S=h.child;if(S!==null)S.return=h;else for(S=h;S!==null;){if(S===t){S=null;break}if(h=S.sibling,h!==null){h.return=S.return,S=h;break}S=S.return}h=S}}function Gr(t,r,l,c){t=null;for(var h=r,g=!1;h!==null;){if(!g){if((h.flags&524288)!==0)g=!0;else if((h.flags&262144)!==0)break}if(h.tag===10){var S=h.alternate;if(S===null)throw Error(s(387));if(S=S.memoizedProps,S!==null){var T=h.type;qt(h.pendingProps.value,S.value)||(t!==null?t.push(T):t=[T])}}else if(h===We.current){if(S=h.alternate,S===null)throw Error(s(387));S.memoizedState.memoizedState!==h.memoizedState.memoizedState&&(t!==null?t.push(va):t=[va])}h=h.return}t!==null&&hu(r,t,l,c),r.flags|=262144}function El(t){for(t=t.firstContext;t!==null;){if(!qt(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function Bi(t){Di=t,Mn=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function gt(t){return Tp(Di,t)}function Al(t,r){return Di===null&&Bi(t),Tp(t,r)}function Tp(t,r){var l=r._currentValue;if(r={context:r,memoizedValue:l,next:null},Mn===null){if(t===null)throw Error(s(308));Mn=r,t.dependencies={lanes:0,firstContext:r},t.flags|=524288}else Mn=Mn.next=r;return l}var u1=typeof AbortController<"u"?AbortController:function(){var t=[],r=this.signal={aborted:!1,addEventListener:function(l,c){t.push(c)}};this.abort=function(){r.aborted=!0,t.forEach(function(l){return l()})}},f1=n.unstable_scheduleCallback,h1=n.unstable_NormalPriority,Qe={$$typeof:V,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function du(){return{controller:new u1,data:new Map,refCount:0}}function Kr(t){t.refCount--,t.refCount===0&&f1(h1,function(){t.controller.abort()})}var Yr=null,pu=0,Ns=0,Cs=null;function d1(t,r){if(Yr===null){var l=Yr=[];pu=0,Ns=yf(),Cs={status:"pending",value:void 0,then:function(c){l.push(c)}}}return pu++,r.then(Ep,Ep),r}function Ep(){if(--pu===0&&Yr!==null){Cs!==null&&(Cs.status="fulfilled");var t=Yr;Yr=null,Ns=0,Cs=null;for(var r=0;r<t.length;r++)(0,t[r])()}}function p1(t,r){var l=[],c={status:"pending",value:null,reason:null,then:function(h){l.push(h)}};return t.then(function(){c.status="fulfilled",c.value=r;for(var h=0;h<l.length;h++)(0,l[h])(r)},function(h){for(c.status="rejected",c.reason=h,h=0;h<l.length;h++)(0,l[h])(void 0)}),c}var Ap=q.S;q.S=function(t,r){typeof r=="object"&&r!==null&&typeof r.then=="function"&&d1(t,r),Ap!==null&&Ap(t,r)};var Ui=X(null);function gu(){var t=Ui.current;return t!==null?t:je.pooledCache}function Nl(t,r){r===null?W(Ui,Ui.current):W(Ui,r.pool)}function Np(){var t=gu();return t===null?null:{parent:Qe._currentValue,pool:t}}var Xr=Error(s(460)),Cp=Error(s(474)),Cl=Error(s(542)),mu={then:function(){}};function kp(t){return t=t.status,t==="fulfilled"||t==="rejected"}function kl(){}function Mp(t,r,l){switch(l=t[l],l===void 0?t.push(r):l!==r&&(r.then(kl,kl),r=l),r.status){case"fulfilled":return r.value;case"rejected":throw t=r.reason,Rp(t),t;default:if(typeof r.status=="string")r.then(kl,kl);else{if(t=je,t!==null&&100<t.shellSuspendCounter)throw Error(s(482));t=r,t.status="pending",t.then(function(c){if(r.status==="pending"){var h=r;h.status="fulfilled",h.value=c}},function(c){if(r.status==="pending"){var h=r;h.status="rejected",h.reason=c}})}switch(r.status){case"fulfilled":return r.value;case"rejected":throw t=r.reason,Rp(t),t}throw Pr=r,Xr}}var Pr=null;function Op(){if(Pr===null)throw Error(s(459));var t=Pr;return Pr=null,t}function Rp(t){if(t===Xr||t===Cl)throw Error(s(483))}var Jn=!1;function yu(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function bu(t,r){t=t.updateQueue,r.updateQueue===t&&(r.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function Wn(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function ei(t,r,l){var c=t.updateQueue;if(c===null)return null;if(c=c.shared,(Ee&2)!==0){var h=c.pending;return h===null?r.next=r:(r.next=h.next,h.next=r),c.pending=r,r=wl(t),bp(t,null,l),r}return Sl(t,c,r,l),wl(t)}function Fr(t,r,l){if(r=r.updateQueue,r!==null&&(r=r.shared,(l&4194048)!==0)){var c=r.lanes;c&=t.pendingLanes,l|=c,r.lanes=l,Ed(t,l)}}function vu(t,r){var l=t.updateQueue,c=t.alternate;if(c!==null&&(c=c.updateQueue,l===c)){var h=null,g=null;if(l=l.firstBaseUpdate,l!==null){do{var S={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};g===null?h=g=S:g=g.next=S,l=l.next}while(l!==null);g===null?h=g=r:g=g.next=r}else h=g=r;l={baseState:c.baseState,firstBaseUpdate:h,lastBaseUpdate:g,shared:c.shared,callbacks:c.callbacks},t.updateQueue=l;return}t=l.lastBaseUpdate,t===null?l.firstBaseUpdate=r:t.next=r,l.lastBaseUpdate=r}var Su=!1;function Qr(){if(Su){var t=Cs;if(t!==null)throw t}}function Zr(t,r,l,c){Su=!1;var h=t.updateQueue;Jn=!1;var g=h.firstBaseUpdate,S=h.lastBaseUpdate,T=h.shared.pending;if(T!==null){h.shared.pending=null;var A=T,D=A.next;A.next=null,S===null?g=D:S.next=D,S=A;var K=t.alternate;K!==null&&(K=K.updateQueue,T=K.lastBaseUpdate,T!==S&&(T===null?K.firstBaseUpdate=D:T.next=D,K.lastBaseUpdate=A))}if(g!==null){var P=h.baseState;S=0,K=D=A=null,T=g;do{var z=T.lane&-536870913,H=z!==T.lane;if(H?(we&z)===z:(c&z)===z){z!==0&&z===Ns&&(Su=!0),K!==null&&(K=K.next={lane:0,tag:T.tag,payload:T.payload,callback:null,next:null});e:{var ce=t,ae=T;z=r;var Me=l;switch(ae.tag){case 1:if(ce=ae.payload,typeof ce=="function"){P=ce.call(Me,P,z);break e}P=ce;break e;case 3:ce.flags=ce.flags&-65537|128;case 0:if(ce=ae.payload,z=typeof ce=="function"?ce.call(Me,P,z):ce,z==null)break e;P=m({},P,z);break e;case 2:Jn=!0}}z=T.callback,z!==null&&(t.flags|=64,H&&(t.flags|=8192),H=h.callbacks,H===null?h.callbacks=[z]:H.push(z))}else H={lane:z,tag:T.tag,payload:T.payload,callback:T.callback,next:null},K===null?(D=K=H,A=P):K=K.next=H,S|=z;if(T=T.next,T===null){if(T=h.shared.pending,T===null)break;H=T,T=H.next,H.next=null,h.lastBaseUpdate=H,h.shared.pending=null}}while(!0);K===null&&(A=P),h.baseState=A,h.firstBaseUpdate=D,h.lastBaseUpdate=K,g===null&&(h.shared.lanes=0),oi|=S,t.lanes=S,t.memoizedState=P}}function jp(t,r){if(typeof t!="function")throw Error(s(191,t));t.call(r)}function Lp(t,r){var l=t.callbacks;if(l!==null)for(t.callbacks=null,t=0;t<l.length;t++)jp(l[t],r)}var ks=X(null),Ml=X(0);function Dp(t,r){t=zn,W(Ml,t),W(ks,r),zn=t|r.baseLanes}function wu(){W(Ml,zn),W(ks,ks.current)}function xu(){zn=Ml.current,Q(ks),Q(Ml)}var ti=0,de=null,Ce=null,Xe=null,Ol=!1,Ms=!1,zi=!1,Rl=0,Jr=0,Os=null,g1=0;function Ve(){throw Error(s(321))}function _u(t,r){if(r===null)return!1;for(var l=0;l<r.length&&l<t.length;l++)if(!qt(t[l],r[l]))return!1;return!0}function Tu(t,r,l,c,h,g){return ti=g,de=r,r.memoizedState=null,r.updateQueue=null,r.lanes=0,q.H=t===null||t.memoizedState===null?bg:vg,zi=!1,g=l(c,h),zi=!1,Ms&&(g=Up(r,l,c,h)),Bp(t),g}function Bp(t){q.H=zl;var r=Ce!==null&&Ce.next!==null;if(ti=0,Xe=Ce=de=null,Ol=!1,Jr=0,Os=null,r)throw Error(s(300));t===null||tt||(t=t.dependencies,t!==null&&El(t)&&(tt=!0))}function Up(t,r,l,c){de=t;var h=0;do{if(Ms&&(Os=null),Jr=0,Ms=!1,25<=h)throw Error(s(301));if(h+=1,Xe=Ce=null,t.updateQueue!=null){var g=t.updateQueue;g.lastEffect=null,g.events=null,g.stores=null,g.memoCache!=null&&(g.memoCache.index=0)}q.H=x1,g=r(l,c)}while(Ms);return g}function m1(){var t=q.H,r=t.useState()[0];return r=typeof r.then=="function"?Wr(r):r,t=t.useState()[0],(Ce!==null?Ce.memoizedState:null)!==t&&(de.flags|=1024),r}function Eu(){var t=Rl!==0;return Rl=0,t}function Au(t,r,l){r.updateQueue=t.updateQueue,r.flags&=-2053,t.lanes&=~l}function Nu(t){if(Ol){for(t=t.memoizedState;t!==null;){var r=t.queue;r!==null&&(r.pending=null),t=t.next}Ol=!1}ti=0,Xe=Ce=de=null,Ms=!1,Jr=Rl=0,Os=null}function kt(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Xe===null?de.memoizedState=Xe=t:Xe=Xe.next=t,Xe}function Pe(){if(Ce===null){var t=de.alternate;t=t!==null?t.memoizedState:null}else t=Ce.next;var r=Xe===null?de.memoizedState:Xe.next;if(r!==null)Xe=r,Ce=t;else{if(t===null)throw de.alternate===null?Error(s(467)):Error(s(310));Ce=t,t={memoizedState:Ce.memoizedState,baseState:Ce.baseState,baseQueue:Ce.baseQueue,queue:Ce.queue,next:null},Xe===null?de.memoizedState=Xe=t:Xe=Xe.next=t}return Xe}function Cu(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Wr(t){var r=Jr;return Jr+=1,Os===null&&(Os=[]),t=Mp(Os,t,r),r=de,(Xe===null?r.memoizedState:Xe.next)===null&&(r=r.alternate,q.H=r===null||r.memoizedState===null?bg:vg),t}function jl(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return Wr(t);if(t.$$typeof===V)return gt(t)}throw Error(s(438,String(t)))}function ku(t){var r=null,l=de.updateQueue;if(l!==null&&(r=l.memoCache),r==null){var c=de.alternate;c!==null&&(c=c.updateQueue,c!==null&&(c=c.memoCache,c!=null&&(r={data:c.data.map(function(h){return h.slice()}),index:0})))}if(r==null&&(r={data:[],index:0}),l===null&&(l=Cu(),de.updateQueue=l),l.memoCache=r,l=r.data[r.index],l===void 0)for(l=r.data[r.index]=Array(t),c=0;c<t;c++)l[c]=ee;return r.index++,l}function Rn(t,r){return typeof r=="function"?r(t):r}function Ll(t){var r=Pe();return Mu(r,Ce,t)}function Mu(t,r,l){var c=t.queue;if(c===null)throw Error(s(311));c.lastRenderedReducer=l;var h=t.baseQueue,g=c.pending;if(g!==null){if(h!==null){var S=h.next;h.next=g.next,g.next=S}r.baseQueue=h=g,c.pending=null}if(g=t.baseState,h===null)t.memoizedState=g;else{r=h.next;var T=S=null,A=null,D=r,K=!1;do{var P=D.lane&-536870913;if(P!==D.lane?(we&P)===P:(ti&P)===P){var z=D.revertLane;if(z===0)A!==null&&(A=A.next={lane:0,revertLane:0,action:D.action,hasEagerState:D.hasEagerState,eagerState:D.eagerState,next:null}),P===Ns&&(K=!0);else if((ti&z)===z){D=D.next,z===Ns&&(K=!0);continue}else P={lane:0,revertLane:D.revertLane,action:D.action,hasEagerState:D.hasEagerState,eagerState:D.eagerState,next:null},A===null?(T=A=P,S=g):A=A.next=P,de.lanes|=z,oi|=z;P=D.action,zi&&l(g,P),g=D.hasEagerState?D.eagerState:l(g,P)}else z={lane:P,revertLane:D.revertLane,action:D.action,hasEagerState:D.hasEagerState,eagerState:D.eagerState,next:null},A===null?(T=A=z,S=g):A=A.next=z,de.lanes|=P,oi|=P;D=D.next}while(D!==null&&D!==r);if(A===null?S=g:A.next=T,!qt(g,t.memoizedState)&&(tt=!0,K&&(l=Cs,l!==null)))throw l;t.memoizedState=g,t.baseState=S,t.baseQueue=A,c.lastRenderedState=g}return h===null&&(c.lanes=0),[t.memoizedState,c.dispatch]}function Ou(t){var r=Pe(),l=r.queue;if(l===null)throw Error(s(311));l.lastRenderedReducer=t;var c=l.dispatch,h=l.pending,g=r.memoizedState;if(h!==null){l.pending=null;var S=h=h.next;do g=t(g,S.action),S=S.next;while(S!==h);qt(g,r.memoizedState)||(tt=!0),r.memoizedState=g,r.baseQueue===null&&(r.baseState=g),l.lastRenderedState=g}return[g,c]}function zp(t,r,l){var c=de,h=Pe(),g=Te;if(g){if(l===void 0)throw Error(s(407));l=l()}else l=r();var S=!qt((Ce||h).memoizedState,l);S&&(h.memoizedState=l,tt=!0),h=h.queue;var T=$p.bind(null,c,h,t);if(ea(2048,8,T,[t]),h.getSnapshot!==r||S||Xe!==null&&Xe.memoizedState.tag&1){if(c.flags|=2048,Rs(9,Dl(),qp.bind(null,c,h,l,r),null),je===null)throw Error(s(349));g||(ti&124)!==0||Hp(c,r,l)}return l}function Hp(t,r,l){t.flags|=16384,t={getSnapshot:r,value:l},r=de.updateQueue,r===null?(r=Cu(),de.updateQueue=r,r.stores=[t]):(l=r.stores,l===null?r.stores=[t]:l.push(t))}function qp(t,r,l,c){r.value=l,r.getSnapshot=c,Ip(r)&&Vp(t)}function $p(t,r,l){return l(function(){Ip(r)&&Vp(t)})}function Ip(t){var r=t.getSnapshot;t=t.value;try{var l=r();return!qt(t,l)}catch{return!0}}function Vp(t){var r=_s(t,2);r!==null&&Yt(r,t,2)}function Ru(t){var r=kt();if(typeof t=="function"){var l=t;if(t=l(),zi){Et(!0);try{l()}finally{Et(!1)}}}return r.memoizedState=r.baseState=t,r.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Rn,lastRenderedState:t},r}function Gp(t,r,l,c){return t.baseState=l,Mu(t,Ce,typeof c=="function"?c:Rn)}function y1(t,r,l,c,h){if(Ul(t))throw Error(s(485));if(t=r.action,t!==null){var g={payload:h,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(S){g.listeners.push(S)}};q.T!==null?l(!0):g.isTransition=!1,c(g),l=r.pending,l===null?(g.next=r.pending=g,Kp(r,g)):(g.next=l.next,r.pending=l.next=g)}}function Kp(t,r){var l=r.action,c=r.payload,h=t.state;if(r.isTransition){var g=q.T,S={};q.T=S;try{var T=l(h,c),A=q.S;A!==null&&A(S,T),Yp(t,r,T)}catch(D){ju(t,r,D)}finally{q.T=g}}else try{g=l(h,c),Yp(t,r,g)}catch(D){ju(t,r,D)}}function Yp(t,r,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(c){Xp(t,r,c)},function(c){return ju(t,r,c)}):Xp(t,r,l)}function Xp(t,r,l){r.status="fulfilled",r.value=l,Pp(r),t.state=l,r=t.pending,r!==null&&(l=r.next,l===r?t.pending=null:(l=l.next,r.next=l,Kp(t,l)))}function ju(t,r,l){var c=t.pending;if(t.pending=null,c!==null){c=c.next;do r.status="rejected",r.reason=l,Pp(r),r=r.next;while(r!==c)}t.action=null}function Pp(t){t=t.listeners;for(var r=0;r<t.length;r++)(0,t[r])()}function Fp(t,r){return r}function Qp(t,r){if(Te){var l=je.formState;if(l!==null){e:{var c=de;if(Te){if($e){t:{for(var h=$e,g=mn;h.nodeType!==8;){if(!g){h=null;break t}if(h=fn(h.nextSibling),h===null){h=null;break t}}g=h.data,h=g==="F!"||g==="F"?h:null}if(h){$e=fn(h.nextSibling),c=h.data==="F!";break e}}Li(c)}c=!1}c&&(r=l[0])}}return l=kt(),l.memoizedState=l.baseState=r,c={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Fp,lastRenderedState:r},l.queue=c,l=gg.bind(null,de,c),c.dispatch=l,c=Ru(!1),g=zu.bind(null,de,!1,c.queue),c=kt(),h={state:r,dispatch:null,action:t,pending:null},c.queue=h,l=y1.bind(null,de,h,g,l),h.dispatch=l,c.memoizedState=t,[r,l,!1]}function Zp(t){var r=Pe();return Jp(r,Ce,t)}function Jp(t,r,l){if(r=Mu(t,r,Fp)[0],t=Ll(Rn)[0],typeof r=="object"&&r!==null&&typeof r.then=="function")try{var c=Wr(r)}catch(S){throw S===Xr?Cl:S}else c=r;r=Pe();var h=r.queue,g=h.dispatch;return l!==r.memoizedState&&(de.flags|=2048,Rs(9,Dl(),b1.bind(null,h,l),null)),[c,g,t]}function b1(t,r){t.action=r}function Wp(t){var r=Pe(),l=Ce;if(l!==null)return Jp(r,l,t);Pe(),r=r.memoizedState,l=Pe();var c=l.queue.dispatch;return l.memoizedState=t,[r,c,!1]}function Rs(t,r,l,c){return t={tag:t,create:l,deps:c,inst:r,next:null},r=de.updateQueue,r===null&&(r=Cu(),de.updateQueue=r),l=r.lastEffect,l===null?r.lastEffect=t.next=t:(c=l.next,l.next=t,t.next=c,r.lastEffect=t),t}function Dl(){return{destroy:void 0,resource:void 0}}function eg(){return Pe().memoizedState}function Bl(t,r,l,c){var h=kt();c=c===void 0?null:c,de.flags|=t,h.memoizedState=Rs(1|r,Dl(),l,c)}function ea(t,r,l,c){var h=Pe();c=c===void 0?null:c;var g=h.memoizedState.inst;Ce!==null&&c!==null&&_u(c,Ce.memoizedState.deps)?h.memoizedState=Rs(r,g,l,c):(de.flags|=t,h.memoizedState=Rs(1|r,g,l,c))}function tg(t,r){Bl(8390656,8,t,r)}function ng(t,r){ea(2048,8,t,r)}function ig(t,r){return ea(4,2,t,r)}function sg(t,r){return ea(4,4,t,r)}function rg(t,r){if(typeof r=="function"){t=t();var l=r(t);return function(){typeof l=="function"?l():r(null)}}if(r!=null)return t=t(),r.current=t,function(){r.current=null}}function ag(t,r,l){l=l!=null?l.concat([t]):null,ea(4,4,rg.bind(null,r,t),l)}function Lu(){}function lg(t,r){var l=Pe();r=r===void 0?null:r;var c=l.memoizedState;return r!==null&&_u(r,c[1])?c[0]:(l.memoizedState=[t,r],t)}function og(t,r){var l=Pe();r=r===void 0?null:r;var c=l.memoizedState;if(r!==null&&_u(r,c[1]))return c[0];if(c=t(),zi){Et(!0);try{t()}finally{Et(!1)}}return l.memoizedState=[c,r],c}function Du(t,r,l){return l===void 0||(ti&1073741824)!==0?t.memoizedState=r:(t.memoizedState=l,t=fm(),de.lanes|=t,oi|=t,l)}function cg(t,r,l,c){return qt(l,r)?l:ks.current!==null?(t=Du(t,l,c),qt(t,r)||(tt=!0),t):(ti&42)===0?(tt=!0,t.memoizedState=l):(t=fm(),de.lanes|=t,oi|=t,r)}function ug(t,r,l,c,h){var g=Z.p;Z.p=g!==0&&8>g?g:8;var S=q.T,T={};q.T=T,zu(t,!1,r,l);try{var A=h(),D=q.S;if(D!==null&&D(T,A),A!==null&&typeof A=="object"&&typeof A.then=="function"){var K=p1(A,c);ta(t,r,K,Kt(t))}else ta(t,r,c,Kt(t))}catch(P){ta(t,r,{then:function(){},status:"rejected",reason:P},Kt())}finally{Z.p=g,q.T=S}}function v1(){}function Bu(t,r,l,c){if(t.tag!==5)throw Error(s(476));var h=fg(t).queue;ug(t,h,r,ne,l===null?v1:function(){return hg(t),l(c)})}function fg(t){var r=t.memoizedState;if(r!==null)return r;r={memoizedState:ne,baseState:ne,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Rn,lastRenderedState:ne},next:null};var l={};return r.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Rn,lastRenderedState:l},next:null},t.memoizedState=r,t=t.alternate,t!==null&&(t.memoizedState=r),r}function hg(t){var r=fg(t).next.queue;ta(t,r,{},Kt())}function Uu(){return gt(va)}function dg(){return Pe().memoizedState}function pg(){return Pe().memoizedState}function S1(t){for(var r=t.return;r!==null;){switch(r.tag){case 24:case 3:var l=Kt();t=Wn(l);var c=ei(r,t,l);c!==null&&(Yt(c,r,l),Fr(c,r,l)),r={cache:du()},t.payload=r;return}r=r.return}}function w1(t,r,l){var c=Kt();l={lane:c,revertLane:0,action:l,hasEagerState:!1,eagerState:null,next:null},Ul(t)?mg(r,l):(l=iu(t,r,l,c),l!==null&&(Yt(l,t,c),yg(l,r,c)))}function gg(t,r,l){var c=Kt();ta(t,r,l,c)}function ta(t,r,l,c){var h={lane:c,revertLane:0,action:l,hasEagerState:!1,eagerState:null,next:null};if(Ul(t))mg(r,h);else{var g=t.alternate;if(t.lanes===0&&(g===null||g.lanes===0)&&(g=r.lastRenderedReducer,g!==null))try{var S=r.lastRenderedState,T=g(S,l);if(h.hasEagerState=!0,h.eagerState=T,qt(T,S))return Sl(t,r,h,0),je===null&&vl(),!1}catch{}finally{}if(l=iu(t,r,h,c),l!==null)return Yt(l,t,c),yg(l,r,c),!0}return!1}function zu(t,r,l,c){if(c={lane:2,revertLane:yf(),action:c,hasEagerState:!1,eagerState:null,next:null},Ul(t)){if(r)throw Error(s(479))}else r=iu(t,l,c,2),r!==null&&Yt(r,t,2)}function Ul(t){var r=t.alternate;return t===de||r!==null&&r===de}function mg(t,r){Ms=Ol=!0;var l=t.pending;l===null?r.next=r:(r.next=l.next,l.next=r),t.pending=r}function yg(t,r,l){if((l&4194048)!==0){var c=r.lanes;c&=t.pendingLanes,l|=c,r.lanes=l,Ed(t,l)}}var zl={readContext:gt,use:jl,useCallback:Ve,useContext:Ve,useEffect:Ve,useImperativeHandle:Ve,useLayoutEffect:Ve,useInsertionEffect:Ve,useMemo:Ve,useReducer:Ve,useRef:Ve,useState:Ve,useDebugValue:Ve,useDeferredValue:Ve,useTransition:Ve,useSyncExternalStore:Ve,useId:Ve,useHostTransitionStatus:Ve,useFormState:Ve,useActionState:Ve,useOptimistic:Ve,useMemoCache:Ve,useCacheRefresh:Ve},bg={readContext:gt,use:jl,useCallback:function(t,r){return kt().memoizedState=[t,r===void 0?null:r],t},useContext:gt,useEffect:tg,useImperativeHandle:function(t,r,l){l=l!=null?l.concat([t]):null,Bl(4194308,4,rg.bind(null,r,t),l)},useLayoutEffect:function(t,r){return Bl(4194308,4,t,r)},useInsertionEffect:function(t,r){Bl(4,2,t,r)},useMemo:function(t,r){var l=kt();r=r===void 0?null:r;var c=t();if(zi){Et(!0);try{t()}finally{Et(!1)}}return l.memoizedState=[c,r],c},useReducer:function(t,r,l){var c=kt();if(l!==void 0){var h=l(r);if(zi){Et(!0);try{l(r)}finally{Et(!1)}}}else h=r;return c.memoizedState=c.baseState=h,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:h},c.queue=t,t=t.dispatch=w1.bind(null,de,t),[c.memoizedState,t]},useRef:function(t){var r=kt();return t={current:t},r.memoizedState=t},useState:function(t){t=Ru(t);var r=t.queue,l=gg.bind(null,de,r);return r.dispatch=l,[t.memoizedState,l]},useDebugValue:Lu,useDeferredValue:function(t,r){var l=kt();return Du(l,t,r)},useTransition:function(){var t=Ru(!1);return t=ug.bind(null,de,t.queue,!0,!1),kt().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,r,l){var c=de,h=kt();if(Te){if(l===void 0)throw Error(s(407));l=l()}else{if(l=r(),je===null)throw Error(s(349));(we&124)!==0||Hp(c,r,l)}h.memoizedState=l;var g={value:l,getSnapshot:r};return h.queue=g,tg($p.bind(null,c,g,t),[t]),c.flags|=2048,Rs(9,Dl(),qp.bind(null,c,g,l,r),null),l},useId:function(){var t=kt(),r=je.identifierPrefix;if(Te){var l=kn,c=Cn;l=(c&~(1<<32-rt(c)-1)).toString(32)+l,r="«"+r+"R"+l,l=Rl++,0<l&&(r+="H"+l.toString(32)),r+="»"}else l=g1++,r="«"+r+"r"+l.toString(32)+"»";return t.memoizedState=r},useHostTransitionStatus:Uu,useFormState:Qp,useActionState:Qp,useOptimistic:function(t){var r=kt();r.memoizedState=r.baseState=t;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return r.queue=l,r=zu.bind(null,de,!0,l),l.dispatch=r,[t,r]},useMemoCache:ku,useCacheRefresh:function(){return kt().memoizedState=S1.bind(null,de)}},vg={readContext:gt,use:jl,useCallback:lg,useContext:gt,useEffect:ng,useImperativeHandle:ag,useInsertionEffect:ig,useLayoutEffect:sg,useMemo:og,useReducer:Ll,useRef:eg,useState:function(){return Ll(Rn)},useDebugValue:Lu,useDeferredValue:function(t,r){var l=Pe();return cg(l,Ce.memoizedState,t,r)},useTransition:function(){var t=Ll(Rn)[0],r=Pe().memoizedState;return[typeof t=="boolean"?t:Wr(t),r]},useSyncExternalStore:zp,useId:dg,useHostTransitionStatus:Uu,useFormState:Zp,useActionState:Zp,useOptimistic:function(t,r){var l=Pe();return Gp(l,Ce,t,r)},useMemoCache:ku,useCacheRefresh:pg},x1={readContext:gt,use:jl,useCallback:lg,useContext:gt,useEffect:ng,useImperativeHandle:ag,useInsertionEffect:ig,useLayoutEffect:sg,useMemo:og,useReducer:Ou,useRef:eg,useState:function(){return Ou(Rn)},useDebugValue:Lu,useDeferredValue:function(t,r){var l=Pe();return Ce===null?Du(l,t,r):cg(l,Ce.memoizedState,t,r)},useTransition:function(){var t=Ou(Rn)[0],r=Pe().memoizedState;return[typeof t=="boolean"?t:Wr(t),r]},useSyncExternalStore:zp,useId:dg,useHostTransitionStatus:Uu,useFormState:Wp,useActionState:Wp,useOptimistic:function(t,r){var l=Pe();return Ce!==null?Gp(l,Ce,t,r):(l.baseState=t,[t,l.queue.dispatch])},useMemoCache:ku,useCacheRefresh:pg},js=null,na=0;function Hl(t){var r=na;return na+=1,js===null&&(js=[]),Mp(js,t,r)}function ia(t,r){r=r.props.ref,t.ref=r!==void 0?r:null}function ql(t,r){throw r.$$typeof===y?Error(s(525)):(t=Object.prototype.toString.call(r),Error(s(31,t==="[object Object]"?"object with keys {"+Object.keys(r).join(", ")+"}":t)))}function Sg(t){var r=t._init;return r(t._payload)}function wg(t){function r(O,M){if(t){var L=O.deletions;L===null?(O.deletions=[M],O.flags|=16):L.push(M)}}function l(O,M){if(!t)return null;for(;M!==null;)r(O,M),M=M.sibling;return null}function c(O){for(var M=new Map;O!==null;)O.key!==null?M.set(O.key,O):M.set(O.index,O),O=O.sibling;return M}function h(O,M){return O=Nn(O,M),O.index=0,O.sibling=null,O}function g(O,M,L){return O.index=L,t?(L=O.alternate,L!==null?(L=L.index,L<M?(O.flags|=67108866,M):L):(O.flags|=67108866,M)):(O.flags|=1048576,M)}function S(O){return t&&O.alternate===null&&(O.flags|=67108866),O}function T(O,M,L,Y){return M===null||M.tag!==6?(M=ru(L,O.mode,Y),M.return=O,M):(M=h(M,L),M.return=O,M)}function A(O,M,L,Y){var te=L.type;return te===E?K(O,M,L.props.children,Y,L.key):M!==null&&(M.elementType===te||typeof te=="object"&&te!==null&&te.$$typeof===$&&Sg(te)===M.type)?(M=h(M,L.props),ia(M,L),M.return=O,M):(M=xl(L.type,L.key,L.props,null,O.mode,Y),ia(M,L),M.return=O,M)}function D(O,M,L,Y){return M===null||M.tag!==4||M.stateNode.containerInfo!==L.containerInfo||M.stateNode.implementation!==L.implementation?(M=au(L,O.mode,Y),M.return=O,M):(M=h(M,L.children||[]),M.return=O,M)}function K(O,M,L,Y,te){return M===null||M.tag!==7?(M=Mi(L,O.mode,Y,te),M.return=O,M):(M=h(M,L),M.return=O,M)}function P(O,M,L){if(typeof M=="string"&&M!==""||typeof M=="number"||typeof M=="bigint")return M=ru(""+M,O.mode,L),M.return=O,M;if(typeof M=="object"&&M!==null){switch(M.$$typeof){case b:return L=xl(M.type,M.key,M.props,null,O.mode,L),ia(L,M),L.return=O,L;case w:return M=au(M,O.mode,L),M.return=O,M;case $:var Y=M._init;return M=Y(M._payload),P(O,M,L)}if(me(M)||j(M))return M=Mi(M,O.mode,L,null),M.return=O,M;if(typeof M.then=="function")return P(O,Hl(M),L);if(M.$$typeof===V)return P(O,Al(O,M),L);ql(O,M)}return null}function z(O,M,L,Y){var te=M!==null?M.key:null;if(typeof L=="string"&&L!==""||typeof L=="number"||typeof L=="bigint")return te!==null?null:T(O,M,""+L,Y);if(typeof L=="object"&&L!==null){switch(L.$$typeof){case b:return L.key===te?A(O,M,L,Y):null;case w:return L.key===te?D(O,M,L,Y):null;case $:return te=L._init,L=te(L._payload),z(O,M,L,Y)}if(me(L)||j(L))return te!==null?null:K(O,M,L,Y,null);if(typeof L.then=="function")return z(O,M,Hl(L),Y);if(L.$$typeof===V)return z(O,M,Al(O,L),Y);ql(O,L)}return null}function H(O,M,L,Y,te){if(typeof Y=="string"&&Y!==""||typeof Y=="number"||typeof Y=="bigint")return O=O.get(L)||null,T(M,O,""+Y,te);if(typeof Y=="object"&&Y!==null){switch(Y.$$typeof){case b:return O=O.get(Y.key===null?L:Y.key)||null,A(M,O,Y,te);case w:return O=O.get(Y.key===null?L:Y.key)||null,D(M,O,Y,te);case $:var pe=Y._init;return Y=pe(Y._payload),H(O,M,L,Y,te)}if(me(Y)||j(Y))return O=O.get(L)||null,K(M,O,Y,te,null);if(typeof Y.then=="function")return H(O,M,L,Hl(Y),te);if(Y.$$typeof===V)return H(O,M,L,Al(M,Y),te);ql(M,Y)}return null}function ce(O,M,L,Y){for(var te=null,pe=null,ie=M,oe=M=0,it=null;ie!==null&&oe<L.length;oe++){ie.index>oe?(it=ie,ie=null):it=ie.sibling;var _e=z(O,ie,L[oe],Y);if(_e===null){ie===null&&(ie=it);break}t&&ie&&_e.alternate===null&&r(O,ie),M=g(_e,M,oe),pe===null?te=_e:pe.sibling=_e,pe=_e,ie=it}if(oe===L.length)return l(O,ie),Te&&Ri(O,oe),te;if(ie===null){for(;oe<L.length;oe++)ie=P(O,L[oe],Y),ie!==null&&(M=g(ie,M,oe),pe===null?te=ie:pe.sibling=ie,pe=ie);return Te&&Ri(O,oe),te}for(ie=c(ie);oe<L.length;oe++)it=H(ie,O,oe,L[oe],Y),it!==null&&(t&&it.alternate!==null&&ie.delete(it.key===null?oe:it.key),M=g(it,M,oe),pe===null?te=it:pe.sibling=it,pe=it);return t&&ie.forEach(function(yi){return r(O,yi)}),Te&&Ri(O,oe),te}function ae(O,M,L,Y){if(L==null)throw Error(s(151));for(var te=null,pe=null,ie=M,oe=M=0,it=null,_e=L.next();ie!==null&&!_e.done;oe++,_e=L.next()){ie.index>oe?(it=ie,ie=null):it=ie.sibling;var yi=z(O,ie,_e.value,Y);if(yi===null){ie===null&&(ie=it);break}t&&ie&&yi.alternate===null&&r(O,ie),M=g(yi,M,oe),pe===null?te=yi:pe.sibling=yi,pe=yi,ie=it}if(_e.done)return l(O,ie),Te&&Ri(O,oe),te;if(ie===null){for(;!_e.done;oe++,_e=L.next())_e=P(O,_e.value,Y),_e!==null&&(M=g(_e,M,oe),pe===null?te=_e:pe.sibling=_e,pe=_e);return Te&&Ri(O,oe),te}for(ie=c(ie);!_e.done;oe++,_e=L.next())_e=H(ie,O,oe,_e.value,Y),_e!==null&&(t&&_e.alternate!==null&&ie.delete(_e.key===null?oe:_e.key),M=g(_e,M,oe),pe===null?te=_e:pe.sibling=_e,pe=_e);return t&&ie.forEach(function(_w){return r(O,_w)}),Te&&Ri(O,oe),te}function Me(O,M,L,Y){if(typeof L=="object"&&L!==null&&L.type===E&&L.key===null&&(L=L.props.children),typeof L=="object"&&L!==null){switch(L.$$typeof){case b:e:{for(var te=L.key;M!==null;){if(M.key===te){if(te=L.type,te===E){if(M.tag===7){l(O,M.sibling),Y=h(M,L.props.children),Y.return=O,O=Y;break e}}else if(M.elementType===te||typeof te=="object"&&te!==null&&te.$$typeof===$&&Sg(te)===M.type){l(O,M.sibling),Y=h(M,L.props),ia(Y,L),Y.return=O,O=Y;break e}l(O,M);break}else r(O,M);M=M.sibling}L.type===E?(Y=Mi(L.props.children,O.mode,Y,L.key),Y.return=O,O=Y):(Y=xl(L.type,L.key,L.props,null,O.mode,Y),ia(Y,L),Y.return=O,O=Y)}return S(O);case w:e:{for(te=L.key;M!==null;){if(M.key===te)if(M.tag===4&&M.stateNode.containerInfo===L.containerInfo&&M.stateNode.implementation===L.implementation){l(O,M.sibling),Y=h(M,L.children||[]),Y.return=O,O=Y;break e}else{l(O,M);break}else r(O,M);M=M.sibling}Y=au(L,O.mode,Y),Y.return=O,O=Y}return S(O);case $:return te=L._init,L=te(L._payload),Me(O,M,L,Y)}if(me(L))return ce(O,M,L,Y);if(j(L)){if(te=j(L),typeof te!="function")throw Error(s(150));return L=te.call(L),ae(O,M,L,Y)}if(typeof L.then=="function")return Me(O,M,Hl(L),Y);if(L.$$typeof===V)return Me(O,M,Al(O,L),Y);ql(O,L)}return typeof L=="string"&&L!==""||typeof L=="number"||typeof L=="bigint"?(L=""+L,M!==null&&M.tag===6?(l(O,M.sibling),Y=h(M,L),Y.return=O,O=Y):(l(O,M),Y=ru(L,O.mode,Y),Y.return=O,O=Y),S(O)):l(O,M)}return function(O,M,L,Y){try{na=0;var te=Me(O,M,L,Y);return js=null,te}catch(ie){if(ie===Xr||ie===Cl)throw ie;var pe=$t(29,ie,null,O.mode);return pe.lanes=Y,pe.return=O,pe}finally{}}}var Ls=wg(!0),xg=wg(!1),en=X(null),yn=null;function ni(t){var r=t.alternate;W(Ze,Ze.current&1),W(en,t),yn===null&&(r===null||ks.current!==null||r.memoizedState!==null)&&(yn=t)}function _g(t){if(t.tag===22){if(W(Ze,Ze.current),W(en,t),yn===null){var r=t.alternate;r!==null&&r.memoizedState!==null&&(yn=t)}}else ii()}function ii(){W(Ze,Ze.current),W(en,en.current)}function jn(t){Q(en),yn===t&&(yn=null),Q(Ze)}var Ze=X(0);function $l(t){for(var r=t;r!==null;){if(r.tag===13){var l=r.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||kf(l)))return r}else if(r.tag===19&&r.memoizedProps.revealOrder!==void 0){if((r.flags&128)!==0)return r}else if(r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return null;r=r.return}r.sibling.return=r.return,r=r.sibling}return null}function Hu(t,r,l,c){r=t.memoizedState,l=l(c,r),l=l==null?r:m({},r,l),t.memoizedState=l,t.lanes===0&&(t.updateQueue.baseState=l)}var qu={enqueueSetState:function(t,r,l){t=t._reactInternals;var c=Kt(),h=Wn(c);h.payload=r,l!=null&&(h.callback=l),r=ei(t,h,c),r!==null&&(Yt(r,t,c),Fr(r,t,c))},enqueueReplaceState:function(t,r,l){t=t._reactInternals;var c=Kt(),h=Wn(c);h.tag=1,h.payload=r,l!=null&&(h.callback=l),r=ei(t,h,c),r!==null&&(Yt(r,t,c),Fr(r,t,c))},enqueueForceUpdate:function(t,r){t=t._reactInternals;var l=Kt(),c=Wn(l);c.tag=2,r!=null&&(c.callback=r),r=ei(t,c,l),r!==null&&(Yt(r,t,l),Fr(r,t,l))}};function Tg(t,r,l,c,h,g,S){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(c,g,S):r.prototype&&r.prototype.isPureReactComponent?!Hr(l,c)||!Hr(h,g):!0}function Eg(t,r,l,c){t=r.state,typeof r.componentWillReceiveProps=="function"&&r.componentWillReceiveProps(l,c),typeof r.UNSAFE_componentWillReceiveProps=="function"&&r.UNSAFE_componentWillReceiveProps(l,c),r.state!==t&&qu.enqueueReplaceState(r,r.state,null)}function Hi(t,r){var l=r;if("ref"in r){l={};for(var c in r)c!=="ref"&&(l[c]=r[c])}if(t=t.defaultProps){l===r&&(l=m({},l));for(var h in t)l[h]===void 0&&(l[h]=t[h])}return l}var Il=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var r=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(r))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)};function Ag(t){Il(t)}function Ng(t){console.error(t)}function Cg(t){Il(t)}function Vl(t,r){try{var l=t.onUncaughtError;l(r.value,{componentStack:r.stack})}catch(c){setTimeout(function(){throw c})}}function kg(t,r,l){try{var c=t.onCaughtError;c(l.value,{componentStack:l.stack,errorBoundary:r.tag===1?r.stateNode:null})}catch(h){setTimeout(function(){throw h})}}function $u(t,r,l){return l=Wn(l),l.tag=3,l.payload={element:null},l.callback=function(){Vl(t,r)},l}function Mg(t){return t=Wn(t),t.tag=3,t}function Og(t,r,l,c){var h=l.type.getDerivedStateFromError;if(typeof h=="function"){var g=c.value;t.payload=function(){return h(g)},t.callback=function(){kg(r,l,c)}}var S=l.stateNode;S!==null&&typeof S.componentDidCatch=="function"&&(t.callback=function(){kg(r,l,c),typeof h!="function"&&(ci===null?ci=new Set([this]):ci.add(this));var T=c.stack;this.componentDidCatch(c.value,{componentStack:T!==null?T:""})})}function _1(t,r,l,c,h){if(l.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){if(r=l.alternate,r!==null&&Gr(r,l,h,!0),l=en.current,l!==null){switch(l.tag){case 13:return yn===null?hf():l.alternate===null&&Ie===0&&(Ie=3),l.flags&=-257,l.flags|=65536,l.lanes=h,c===mu?l.flags|=16384:(r=l.updateQueue,r===null?l.updateQueue=new Set([c]):r.add(c),pf(t,c,h)),!1;case 22:return l.flags|=65536,c===mu?l.flags|=16384:(r=l.updateQueue,r===null?(r={transitions:null,markerInstances:null,retryQueue:new Set([c])},l.updateQueue=r):(l=r.retryQueue,l===null?r.retryQueue=new Set([c]):l.add(c)),pf(t,c,h)),!1}throw Error(s(435,l.tag))}return pf(t,c,h),hf(),!1}if(Te)return r=en.current,r!==null?((r.flags&65536)===0&&(r.flags|=256),r.flags|=65536,r.lanes=h,c!==cu&&(t=Error(s(422),{cause:c}),Vr(Qt(t,l)))):(c!==cu&&(r=Error(s(423),{cause:c}),Vr(Qt(r,l))),t=t.current.alternate,t.flags|=65536,h&=-h,t.lanes|=h,c=Qt(c,l),h=$u(t.stateNode,c,h),vu(t,h),Ie!==4&&(Ie=2)),!1;var g=Error(s(520),{cause:c});if(g=Qt(g,l),ua===null?ua=[g]:ua.push(g),Ie!==4&&(Ie=2),r===null)return!0;c=Qt(c,l),l=r;do{switch(l.tag){case 3:return l.flags|=65536,t=h&-h,l.lanes|=t,t=$u(l.stateNode,c,t),vu(l,t),!1;case 1:if(r=l.type,g=l.stateNode,(l.flags&128)===0&&(typeof r.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(ci===null||!ci.has(g))))return l.flags|=65536,h&=-h,l.lanes|=h,h=Mg(h),Og(h,t,l,c),vu(l,h),!1}l=l.return}while(l!==null);return!1}var Rg=Error(s(461)),tt=!1;function at(t,r,l,c){r.child=t===null?xg(r,null,l,c):Ls(r,t.child,l,c)}function jg(t,r,l,c,h){l=l.render;var g=r.ref;if("ref"in c){var S={};for(var T in c)T!=="ref"&&(S[T]=c[T])}else S=c;return Bi(r),c=Tu(t,r,l,S,g,h),T=Eu(),t!==null&&!tt?(Au(t,r,h),Ln(t,r,h)):(Te&&T&&lu(r),r.flags|=1,at(t,r,c,h),r.child)}function Lg(t,r,l,c,h){if(t===null){var g=l.type;return typeof g=="function"&&!su(g)&&g.defaultProps===void 0&&l.compare===null?(r.tag=15,r.type=g,Dg(t,r,g,c,h)):(t=xl(l.type,null,c,r,r.mode,h),t.ref=r.ref,t.return=r,r.child=t)}if(g=t.child,!Fu(t,h)){var S=g.memoizedProps;if(l=l.compare,l=l!==null?l:Hr,l(S,c)&&t.ref===r.ref)return Ln(t,r,h)}return r.flags|=1,t=Nn(g,c),t.ref=r.ref,t.return=r,r.child=t}function Dg(t,r,l,c,h){if(t!==null){var g=t.memoizedProps;if(Hr(g,c)&&t.ref===r.ref)if(tt=!1,r.pendingProps=c=g,Fu(t,h))(t.flags&131072)!==0&&(tt=!0);else return r.lanes=t.lanes,Ln(t,r,h)}return Iu(t,r,l,c,h)}function Bg(t,r,l){var c=r.pendingProps,h=c.children,g=t!==null?t.memoizedState:null;if(c.mode==="hidden"){if((r.flags&128)!==0){if(c=g!==null?g.baseLanes|l:l,t!==null){for(h=r.child=t.child,g=0;h!==null;)g=g|h.lanes|h.childLanes,h=h.sibling;r.childLanes=g&~c}else r.childLanes=0,r.child=null;return Ug(t,r,c,l)}if((l&536870912)!==0)r.memoizedState={baseLanes:0,cachePool:null},t!==null&&Nl(r,g!==null?g.cachePool:null),g!==null?Dp(r,g):wu(),_g(r);else return r.lanes=r.childLanes=536870912,Ug(t,r,g!==null?g.baseLanes|l:l,l)}else g!==null?(Nl(r,g.cachePool),Dp(r,g),ii(),r.memoizedState=null):(t!==null&&Nl(r,null),wu(),ii());return at(t,r,h,l),r.child}function Ug(t,r,l,c){var h=gu();return h=h===null?null:{parent:Qe._currentValue,pool:h},r.memoizedState={baseLanes:l,cachePool:h},t!==null&&Nl(r,null),wu(),_g(r),t!==null&&Gr(t,r,c,!0),null}function Gl(t,r){var l=r.ref;if(l===null)t!==null&&t.ref!==null&&(r.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(s(284));(t===null||t.ref!==l)&&(r.flags|=4194816)}}function Iu(t,r,l,c,h){return Bi(r),l=Tu(t,r,l,c,void 0,h),c=Eu(),t!==null&&!tt?(Au(t,r,h),Ln(t,r,h)):(Te&&c&&lu(r),r.flags|=1,at(t,r,l,h),r.child)}function zg(t,r,l,c,h,g){return Bi(r),r.updateQueue=null,l=Up(r,c,l,h),Bp(t),c=Eu(),t!==null&&!tt?(Au(t,r,g),Ln(t,r,g)):(Te&&c&&lu(r),r.flags|=1,at(t,r,l,g),r.child)}function Hg(t,r,l,c,h){if(Bi(r),r.stateNode===null){var g=Ts,S=l.contextType;typeof S=="object"&&S!==null&&(g=gt(S)),g=new l(c,g),r.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,g.updater=qu,r.stateNode=g,g._reactInternals=r,g=r.stateNode,g.props=c,g.state=r.memoizedState,g.refs={},yu(r),S=l.contextType,g.context=typeof S=="object"&&S!==null?gt(S):Ts,g.state=r.memoizedState,S=l.getDerivedStateFromProps,typeof S=="function"&&(Hu(r,l,S,c),g.state=r.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(S=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),S!==g.state&&qu.enqueueReplaceState(g,g.state,null),Zr(r,c,g,h),Qr(),g.state=r.memoizedState),typeof g.componentDidMount=="function"&&(r.flags|=4194308),c=!0}else if(t===null){g=r.stateNode;var T=r.memoizedProps,A=Hi(l,T);g.props=A;var D=g.context,K=l.contextType;S=Ts,typeof K=="object"&&K!==null&&(S=gt(K));var P=l.getDerivedStateFromProps;K=typeof P=="function"||typeof g.getSnapshotBeforeUpdate=="function",T=r.pendingProps!==T,K||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(T||D!==S)&&Eg(r,g,c,S),Jn=!1;var z=r.memoizedState;g.state=z,Zr(r,c,g,h),Qr(),D=r.memoizedState,T||z!==D||Jn?(typeof P=="function"&&(Hu(r,l,P,c),D=r.memoizedState),(A=Jn||Tg(r,l,A,c,z,D,S))?(K||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount()),typeof g.componentDidMount=="function"&&(r.flags|=4194308)):(typeof g.componentDidMount=="function"&&(r.flags|=4194308),r.memoizedProps=c,r.memoizedState=D),g.props=c,g.state=D,g.context=S,c=A):(typeof g.componentDidMount=="function"&&(r.flags|=4194308),c=!1)}else{g=r.stateNode,bu(t,r),S=r.memoizedProps,K=Hi(l,S),g.props=K,P=r.pendingProps,z=g.context,D=l.contextType,A=Ts,typeof D=="object"&&D!==null&&(A=gt(D)),T=l.getDerivedStateFromProps,(D=typeof T=="function"||typeof g.getSnapshotBeforeUpdate=="function")||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(S!==P||z!==A)&&Eg(r,g,c,A),Jn=!1,z=r.memoizedState,g.state=z,Zr(r,c,g,h),Qr();var H=r.memoizedState;S!==P||z!==H||Jn||t!==null&&t.dependencies!==null&&El(t.dependencies)?(typeof T=="function"&&(Hu(r,l,T,c),H=r.memoizedState),(K=Jn||Tg(r,l,K,c,z,H,A)||t!==null&&t.dependencies!==null&&El(t.dependencies))?(D||typeof g.UNSAFE_componentWillUpdate!="function"&&typeof g.componentWillUpdate!="function"||(typeof g.componentWillUpdate=="function"&&g.componentWillUpdate(c,H,A),typeof g.UNSAFE_componentWillUpdate=="function"&&g.UNSAFE_componentWillUpdate(c,H,A)),typeof g.componentDidUpdate=="function"&&(r.flags|=4),typeof g.getSnapshotBeforeUpdate=="function"&&(r.flags|=1024)):(typeof g.componentDidUpdate!="function"||S===t.memoizedProps&&z===t.memoizedState||(r.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||S===t.memoizedProps&&z===t.memoizedState||(r.flags|=1024),r.memoizedProps=c,r.memoizedState=H),g.props=c,g.state=H,g.context=A,c=K):(typeof g.componentDidUpdate!="function"||S===t.memoizedProps&&z===t.memoizedState||(r.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||S===t.memoizedProps&&z===t.memoizedState||(r.flags|=1024),c=!1)}return g=c,Gl(t,r),c=(r.flags&128)!==0,g||c?(g=r.stateNode,l=c&&typeof l.getDerivedStateFromError!="function"?null:g.render(),r.flags|=1,t!==null&&c?(r.child=Ls(r,t.child,null,h),r.child=Ls(r,null,l,h)):at(t,r,l,h),r.memoizedState=g.state,t=r.child):t=Ln(t,r,h),t}function qg(t,r,l,c){return Ir(),r.flags|=256,at(t,r,l,c),r.child}var Vu={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Gu(t){return{baseLanes:t,cachePool:Np()}}function Ku(t,r,l){return t=t!==null?t.childLanes&~l:0,r&&(t|=tn),t}function $g(t,r,l){var c=r.pendingProps,h=!1,g=(r.flags&128)!==0,S;if((S=g)||(S=t!==null&&t.memoizedState===null?!1:(Ze.current&2)!==0),S&&(h=!0,r.flags&=-129),S=(r.flags&32)!==0,r.flags&=-33,t===null){if(Te){if(h?ni(r):ii(),Te){var T=$e,A;if(A=T){e:{for(A=T,T=mn;A.nodeType!==8;){if(!T){T=null;break e}if(A=fn(A.nextSibling),A===null){T=null;break e}}T=A}T!==null?(r.memoizedState={dehydrated:T,treeContext:Oi!==null?{id:Cn,overflow:kn}:null,retryLane:536870912,hydrationErrors:null},A=$t(18,null,null,0),A.stateNode=T,A.return=r,r.child=A,St=r,$e=null,A=!0):A=!1}A||Li(r)}if(T=r.memoizedState,T!==null&&(T=T.dehydrated,T!==null))return kf(T)?r.lanes=32:r.lanes=536870912,null;jn(r)}return T=c.children,c=c.fallback,h?(ii(),h=r.mode,T=Kl({mode:"hidden",children:T},h),c=Mi(c,h,l,null),T.return=r,c.return=r,T.sibling=c,r.child=T,h=r.child,h.memoizedState=Gu(l),h.childLanes=Ku(t,S,l),r.memoizedState=Vu,c):(ni(r),Yu(r,T))}if(A=t.memoizedState,A!==null&&(T=A.dehydrated,T!==null)){if(g)r.flags&256?(ni(r),r.flags&=-257,r=Xu(t,r,l)):r.memoizedState!==null?(ii(),r.child=t.child,r.flags|=128,r=null):(ii(),h=c.fallback,T=r.mode,c=Kl({mode:"visible",children:c.children},T),h=Mi(h,T,l,null),h.flags|=2,c.return=r,h.return=r,c.sibling=h,r.child=c,Ls(r,t.child,null,l),c=r.child,c.memoizedState=Gu(l),c.childLanes=Ku(t,S,l),r.memoizedState=Vu,r=h);else if(ni(r),kf(T)){if(S=T.nextSibling&&T.nextSibling.dataset,S)var D=S.dgst;S=D,c=Error(s(419)),c.stack="",c.digest=S,Vr({value:c,source:null,stack:null}),r=Xu(t,r,l)}else if(tt||Gr(t,r,l,!1),S=(l&t.childLanes)!==0,tt||S){if(S=je,S!==null&&(c=l&-l,c=(c&42)!==0?1:kc(c),c=(c&(S.suspendedLanes|l))!==0?0:c,c!==0&&c!==A.retryLane))throw A.retryLane=c,_s(t,c),Yt(S,t,c),Rg;T.data==="$?"||hf(),r=Xu(t,r,l)}else T.data==="$?"?(r.flags|=192,r.child=t.child,r=null):(t=A.treeContext,$e=fn(T.nextSibling),St=r,Te=!0,ji=null,mn=!1,t!==null&&(Jt[Wt++]=Cn,Jt[Wt++]=kn,Jt[Wt++]=Oi,Cn=t.id,kn=t.overflow,Oi=r),r=Yu(r,c.children),r.flags|=4096);return r}return h?(ii(),h=c.fallback,T=r.mode,A=t.child,D=A.sibling,c=Nn(A,{mode:"hidden",children:c.children}),c.subtreeFlags=A.subtreeFlags&65011712,D!==null?h=Nn(D,h):(h=Mi(h,T,l,null),h.flags|=2),h.return=r,c.return=r,c.sibling=h,r.child=c,c=h,h=r.child,T=t.child.memoizedState,T===null?T=Gu(l):(A=T.cachePool,A!==null?(D=Qe._currentValue,A=A.parent!==D?{parent:D,pool:D}:A):A=Np(),T={baseLanes:T.baseLanes|l,cachePool:A}),h.memoizedState=T,h.childLanes=Ku(t,S,l),r.memoizedState=Vu,c):(ni(r),l=t.child,t=l.sibling,l=Nn(l,{mode:"visible",children:c.children}),l.return=r,l.sibling=null,t!==null&&(S=r.deletions,S===null?(r.deletions=[t],r.flags|=16):S.push(t)),r.child=l,r.memoizedState=null,l)}function Yu(t,r){return r=Kl({mode:"visible",children:r},t.mode),r.return=t,t.child=r}function Kl(t,r){return t=$t(22,t,null,r),t.lanes=0,t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},t}function Xu(t,r,l){return Ls(r,t.child,null,l),t=Yu(r,r.pendingProps.children),t.flags|=2,r.memoizedState=null,t}function Ig(t,r,l){t.lanes|=r;var c=t.alternate;c!==null&&(c.lanes|=r),fu(t.return,r,l)}function Pu(t,r,l,c,h){var g=t.memoizedState;g===null?t.memoizedState={isBackwards:r,rendering:null,renderingStartTime:0,last:c,tail:l,tailMode:h}:(g.isBackwards=r,g.rendering=null,g.renderingStartTime=0,g.last=c,g.tail=l,g.tailMode=h)}function Vg(t,r,l){var c=r.pendingProps,h=c.revealOrder,g=c.tail;if(at(t,r,c.children,l),c=Ze.current,(c&2)!==0)c=c&1|2,r.flags|=128;else{if(t!==null&&(t.flags&128)!==0)e:for(t=r.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&Ig(t,l,r);else if(t.tag===19)Ig(t,l,r);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===r)break e;for(;t.sibling===null;){if(t.return===null||t.return===r)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}c&=1}switch(W(Ze,c),h){case"forwards":for(l=r.child,h=null;l!==null;)t=l.alternate,t!==null&&$l(t)===null&&(h=l),l=l.sibling;l=h,l===null?(h=r.child,r.child=null):(h=l.sibling,l.sibling=null),Pu(r,!1,h,l,g);break;case"backwards":for(l=null,h=r.child,r.child=null;h!==null;){if(t=h.alternate,t!==null&&$l(t)===null){r.child=h;break}t=h.sibling,h.sibling=l,l=h,h=t}Pu(r,!0,l,null,g);break;case"together":Pu(r,!1,null,null,void 0);break;default:r.memoizedState=null}return r.child}function Ln(t,r,l){if(t!==null&&(r.dependencies=t.dependencies),oi|=r.lanes,(l&r.childLanes)===0)if(t!==null){if(Gr(t,r,l,!1),(l&r.childLanes)===0)return null}else return null;if(t!==null&&r.child!==t.child)throw Error(s(153));if(r.child!==null){for(t=r.child,l=Nn(t,t.pendingProps),r.child=l,l.return=r;t.sibling!==null;)t=t.sibling,l=l.sibling=Nn(t,t.pendingProps),l.return=r;l.sibling=null}return r.child}function Fu(t,r){return(t.lanes&r)!==0?!0:(t=t.dependencies,!!(t!==null&&El(t)))}function T1(t,r,l){switch(r.tag){case 3:xe(r,r.stateNode.containerInfo),Zn(r,Qe,t.memoizedState.cache),Ir();break;case 27:case 5:rs(r);break;case 4:xe(r,r.stateNode.containerInfo);break;case 10:Zn(r,r.type,r.memoizedProps.value);break;case 13:var c=r.memoizedState;if(c!==null)return c.dehydrated!==null?(ni(r),r.flags|=128,null):(l&r.child.childLanes)!==0?$g(t,r,l):(ni(r),t=Ln(t,r,l),t!==null?t.sibling:null);ni(r);break;case 19:var h=(t.flags&128)!==0;if(c=(l&r.childLanes)!==0,c||(Gr(t,r,l,!1),c=(l&r.childLanes)!==0),h){if(c)return Vg(t,r,l);r.flags|=128}if(h=r.memoizedState,h!==null&&(h.rendering=null,h.tail=null,h.lastEffect=null),W(Ze,Ze.current),c)break;return null;case 22:case 23:return r.lanes=0,Bg(t,r,l);case 24:Zn(r,Qe,t.memoizedState.cache)}return Ln(t,r,l)}function Gg(t,r,l){if(t!==null)if(t.memoizedProps!==r.pendingProps)tt=!0;else{if(!Fu(t,l)&&(r.flags&128)===0)return tt=!1,T1(t,r,l);tt=(t.flags&131072)!==0}else tt=!1,Te&&(r.flags&1048576)!==0&&Sp(r,Tl,r.index);switch(r.lanes=0,r.tag){case 16:e:{t=r.pendingProps;var c=r.elementType,h=c._init;if(c=h(c._payload),r.type=c,typeof c=="function")su(c)?(t=Hi(c,t),r.tag=1,r=Hg(null,r,c,t,l)):(r.tag=0,r=Iu(null,r,c,t,l));else{if(c!=null){if(h=c.$$typeof,h===I){r.tag=11,r=jg(null,r,c,t,l);break e}else if(h===J){r.tag=14,r=Lg(null,r,c,t,l);break e}}throw r=ge(c)||c,Error(s(306,r,""))}}return r;case 0:return Iu(t,r,r.type,r.pendingProps,l);case 1:return c=r.type,h=Hi(c,r.pendingProps),Hg(t,r,c,h,l);case 3:e:{if(xe(r,r.stateNode.containerInfo),t===null)throw Error(s(387));c=r.pendingProps;var g=r.memoizedState;h=g.element,bu(t,r),Zr(r,c,null,l);var S=r.memoizedState;if(c=S.cache,Zn(r,Qe,c),c!==g.cache&&hu(r,[Qe],l,!0),Qr(),c=S.element,g.isDehydrated)if(g={element:c,isDehydrated:!1,cache:S.cache},r.updateQueue.baseState=g,r.memoizedState=g,r.flags&256){r=qg(t,r,c,l);break e}else if(c!==h){h=Qt(Error(s(424)),r),Vr(h),r=qg(t,r,c,l);break e}else{switch(t=r.stateNode.containerInfo,t.nodeType){case 9:t=t.body;break;default:t=t.nodeName==="HTML"?t.ownerDocument.body:t}for($e=fn(t.firstChild),St=r,Te=!0,ji=null,mn=!0,l=xg(r,null,c,l),r.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(Ir(),c===h){r=Ln(t,r,l);break e}at(t,r,c,l)}r=r.child}return r;case 26:return Gl(t,r),t===null?(l=Pm(r.type,null,r.pendingProps,null))?r.memoizedState=l:Te||(l=r.type,t=r.pendingProps,c=ro(ue.current).createElement(l),c[pt]=r,c[Nt]=t,ot(c,l,t),et(c),r.stateNode=c):r.memoizedState=Pm(r.type,t.memoizedProps,r.pendingProps,t.memoizedState),null;case 27:return rs(r),t===null&&Te&&(c=r.stateNode=Km(r.type,r.pendingProps,ue.current),St=r,mn=!0,h=$e,hi(r.type)?(Mf=h,$e=fn(c.firstChild)):$e=h),at(t,r,r.pendingProps.children,l),Gl(t,r),t===null&&(r.flags|=4194304),r.child;case 5:return t===null&&Te&&((h=c=$e)&&(c=J1(c,r.type,r.pendingProps,mn),c!==null?(r.stateNode=c,St=r,$e=fn(c.firstChild),mn=!1,h=!0):h=!1),h||Li(r)),rs(r),h=r.type,g=r.pendingProps,S=t!==null?t.memoizedProps:null,c=g.children,Af(h,g)?c=null:S!==null&&Af(h,S)&&(r.flags|=32),r.memoizedState!==null&&(h=Tu(t,r,m1,null,null,l),va._currentValue=h),Gl(t,r),at(t,r,c,l),r.child;case 6:return t===null&&Te&&((t=l=$e)&&(l=W1(l,r.pendingProps,mn),l!==null?(r.stateNode=l,St=r,$e=null,t=!0):t=!1),t||Li(r)),null;case 13:return $g(t,r,l);case 4:return xe(r,r.stateNode.containerInfo),c=r.pendingProps,t===null?r.child=Ls(r,null,c,l):at(t,r,c,l),r.child;case 11:return jg(t,r,r.type,r.pendingProps,l);case 7:return at(t,r,r.pendingProps,l),r.child;case 8:return at(t,r,r.pendingProps.children,l),r.child;case 12:return at(t,r,r.pendingProps.children,l),r.child;case 10:return c=r.pendingProps,Zn(r,r.type,c.value),at(t,r,c.children,l),r.child;case 9:return h=r.type._context,c=r.pendingProps.children,Bi(r),h=gt(h),c=c(h),r.flags|=1,at(t,r,c,l),r.child;case 14:return Lg(t,r,r.type,r.pendingProps,l);case 15:return Dg(t,r,r.type,r.pendingProps,l);case 19:return Vg(t,r,l);case 31:return c=r.pendingProps,l=r.mode,c={mode:c.mode,children:c.children},t===null?(l=Kl(c,l),l.ref=r.ref,r.child=l,l.return=r,r=l):(l=Nn(t.child,c),l.ref=r.ref,r.child=l,l.return=r,r=l),r;case 22:return Bg(t,r,l);case 24:return Bi(r),c=gt(Qe),t===null?(h=gu(),h===null&&(h=je,g=du(),h.pooledCache=g,g.refCount++,g!==null&&(h.pooledCacheLanes|=l),h=g),r.memoizedState={parent:c,cache:h},yu(r),Zn(r,Qe,h)):((t.lanes&l)!==0&&(bu(t,r),Zr(r,null,null,l),Qr()),h=t.memoizedState,g=r.memoizedState,h.parent!==c?(h={parent:c,cache:c},r.memoizedState=h,r.lanes===0&&(r.memoizedState=r.updateQueue.baseState=h),Zn(r,Qe,c)):(c=g.cache,Zn(r,Qe,c),c!==h.cache&&hu(r,[Qe],l,!0))),at(t,r,r.pendingProps.children,l),r.child;case 29:throw r.pendingProps}throw Error(s(156,r.tag))}function Dn(t){t.flags|=4}function Kg(t,r){if(r.type!=="stylesheet"||(r.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!Wm(r)){if(r=en.current,r!==null&&((we&4194048)===we?yn!==null:(we&62914560)!==we&&(we&536870912)===0||r!==yn))throw Pr=mu,Cp;t.flags|=8192}}function Yl(t,r){r!==null&&(t.flags|=4),t.flags&16384&&(r=t.tag!==22?_d():536870912,t.lanes|=r,zs|=r)}function sa(t,r){if(!Te)switch(t.tailMode){case"hidden":r=t.tail;for(var l=null;r!==null;)r.alternate!==null&&(l=r),r=r.sibling;l===null?t.tail=null:l.sibling=null;break;case"collapsed":l=t.tail;for(var c=null;l!==null;)l.alternate!==null&&(c=l),l=l.sibling;c===null?r||t.tail===null?t.tail=null:t.tail.sibling=null:c.sibling=null}}function Ue(t){var r=t.alternate!==null&&t.alternate.child===t.child,l=0,c=0;if(r)for(var h=t.child;h!==null;)l|=h.lanes|h.childLanes,c|=h.subtreeFlags&65011712,c|=h.flags&65011712,h.return=t,h=h.sibling;else for(h=t.child;h!==null;)l|=h.lanes|h.childLanes,c|=h.subtreeFlags,c|=h.flags,h.return=t,h=h.sibling;return t.subtreeFlags|=c,t.childLanes=l,r}function E1(t,r,l){var c=r.pendingProps;switch(ou(r),r.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ue(r),null;case 1:return Ue(r),null;case 3:return l=r.stateNode,c=null,t!==null&&(c=t.memoizedState.cache),r.memoizedState.cache!==c&&(r.flags|=2048),On(Qe),gn(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(t===null||t.child===null)&&($r(r)?Dn(r):t===null||t.memoizedState.isDehydrated&&(r.flags&256)===0||(r.flags|=1024,_p())),Ue(r),null;case 26:return l=r.memoizedState,t===null?(Dn(r),l!==null?(Ue(r),Kg(r,l)):(Ue(r),r.flags&=-16777217)):l?l!==t.memoizedState?(Dn(r),Ue(r),Kg(r,l)):(Ue(r),r.flags&=-16777217):(t.memoizedProps!==c&&Dn(r),Ue(r),r.flags&=-16777217),null;case 27:ht(r),l=ue.current;var h=r.type;if(t!==null&&r.stateNode!=null)t.memoizedProps!==c&&Dn(r);else{if(!c){if(r.stateNode===null)throw Error(s(166));return Ue(r),null}t=se.current,$r(r)?wp(r):(t=Km(h,c,l),r.stateNode=t,Dn(r))}return Ue(r),null;case 5:if(ht(r),l=r.type,t!==null&&r.stateNode!=null)t.memoizedProps!==c&&Dn(r);else{if(!c){if(r.stateNode===null)throw Error(s(166));return Ue(r),null}if(t=se.current,$r(r))wp(r);else{switch(h=ro(ue.current),t){case 1:t=h.createElementNS("http://www.w3.org/2000/svg",l);break;case 2:t=h.createElementNS("http://www.w3.org/1998/Math/MathML",l);break;default:switch(l){case"svg":t=h.createElementNS("http://www.w3.org/2000/svg",l);break;case"math":t=h.createElementNS("http://www.w3.org/1998/Math/MathML",l);break;case"script":t=h.createElement("div"),t.innerHTML="<script><\/script>",t=t.removeChild(t.firstChild);break;case"select":t=typeof c.is=="string"?h.createElement("select",{is:c.is}):h.createElement("select"),c.multiple?t.multiple=!0:c.size&&(t.size=c.size);break;default:t=typeof c.is=="string"?h.createElement(l,{is:c.is}):h.createElement(l)}}t[pt]=r,t[Nt]=c;e:for(h=r.child;h!==null;){if(h.tag===5||h.tag===6)t.appendChild(h.stateNode);else if(h.tag!==4&&h.tag!==27&&h.child!==null){h.child.return=h,h=h.child;continue}if(h===r)break e;for(;h.sibling===null;){if(h.return===null||h.return===r)break e;h=h.return}h.sibling.return=h.return,h=h.sibling}r.stateNode=t;e:switch(ot(t,l,c),l){case"button":case"input":case"select":case"textarea":t=!!c.autoFocus;break e;case"img":t=!0;break e;default:t=!1}t&&Dn(r)}}return Ue(r),r.flags&=-16777217,null;case 6:if(t&&r.stateNode!=null)t.memoizedProps!==c&&Dn(r);else{if(typeof c!="string"&&r.stateNode===null)throw Error(s(166));if(t=ue.current,$r(r)){if(t=r.stateNode,l=r.memoizedProps,c=null,h=St,h!==null)switch(h.tag){case 27:case 5:c=h.memoizedProps}t[pt]=r,t=!!(t.nodeValue===l||c!==null&&c.suppressHydrationWarning===!0||zm(t.nodeValue,l)),t||Li(r)}else t=ro(t).createTextNode(c),t[pt]=r,r.stateNode=t}return Ue(r),null;case 13:if(c=r.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(h=$r(r),c!==null&&c.dehydrated!==null){if(t===null){if(!h)throw Error(s(318));if(h=r.memoizedState,h=h!==null?h.dehydrated:null,!h)throw Error(s(317));h[pt]=r}else Ir(),(r.flags&128)===0&&(r.memoizedState=null),r.flags|=4;Ue(r),h=!1}else h=_p(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=h),h=!0;if(!h)return r.flags&256?(jn(r),r):(jn(r),null)}if(jn(r),(r.flags&128)!==0)return r.lanes=l,r;if(l=c!==null,t=t!==null&&t.memoizedState!==null,l){c=r.child,h=null,c.alternate!==null&&c.alternate.memoizedState!==null&&c.alternate.memoizedState.cachePool!==null&&(h=c.alternate.memoizedState.cachePool.pool);var g=null;c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(g=c.memoizedState.cachePool.pool),g!==h&&(c.flags|=2048)}return l!==t&&l&&(r.child.flags|=8192),Yl(r,r.updateQueue),Ue(r),null;case 4:return gn(),t===null&&wf(r.stateNode.containerInfo),Ue(r),null;case 10:return On(r.type),Ue(r),null;case 19:if(Q(Ze),h=r.memoizedState,h===null)return Ue(r),null;if(c=(r.flags&128)!==0,g=h.rendering,g===null)if(c)sa(h,!1);else{if(Ie!==0||t!==null&&(t.flags&128)!==0)for(t=r.child;t!==null;){if(g=$l(t),g!==null){for(r.flags|=128,sa(h,!1),t=g.updateQueue,r.updateQueue=t,Yl(r,t),r.subtreeFlags=0,t=l,l=r.child;l!==null;)vp(l,t),l=l.sibling;return W(Ze,Ze.current&1|2),r.child}t=t.sibling}h.tail!==null&&Ht()>Fl&&(r.flags|=128,c=!0,sa(h,!1),r.lanes=4194304)}else{if(!c)if(t=$l(g),t!==null){if(r.flags|=128,c=!0,t=t.updateQueue,r.updateQueue=t,Yl(r,t),sa(h,!0),h.tail===null&&h.tailMode==="hidden"&&!g.alternate&&!Te)return Ue(r),null}else 2*Ht()-h.renderingStartTime>Fl&&l!==536870912&&(r.flags|=128,c=!0,sa(h,!1),r.lanes=4194304);h.isBackwards?(g.sibling=r.child,r.child=g):(t=h.last,t!==null?t.sibling=g:r.child=g,h.last=g)}return h.tail!==null?(r=h.tail,h.rendering=r,h.tail=r.sibling,h.renderingStartTime=Ht(),r.sibling=null,t=Ze.current,W(Ze,c?t&1|2:t&1),r):(Ue(r),null);case 22:case 23:return jn(r),xu(),c=r.memoizedState!==null,t!==null?t.memoizedState!==null!==c&&(r.flags|=8192):c&&(r.flags|=8192),c?(l&536870912)!==0&&(r.flags&128)===0&&(Ue(r),r.subtreeFlags&6&&(r.flags|=8192)):Ue(r),l=r.updateQueue,l!==null&&Yl(r,l.retryQueue),l=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),c=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(c=r.memoizedState.cachePool.pool),c!==l&&(r.flags|=2048),t!==null&&Q(Ui),null;case 24:return l=null,t!==null&&(l=t.memoizedState.cache),r.memoizedState.cache!==l&&(r.flags|=2048),On(Qe),Ue(r),null;case 25:return null;case 30:return null}throw Error(s(156,r.tag))}function A1(t,r){switch(ou(r),r.tag){case 1:return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 3:return On(Qe),gn(),t=r.flags,(t&65536)!==0&&(t&128)===0?(r.flags=t&-65537|128,r):null;case 26:case 27:case 5:return ht(r),null;case 13:if(jn(r),t=r.memoizedState,t!==null&&t.dehydrated!==null){if(r.alternate===null)throw Error(s(340));Ir()}return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 19:return Q(Ze),null;case 4:return gn(),null;case 10:return On(r.type),null;case 22:case 23:return jn(r),xu(),t!==null&&Q(Ui),t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 24:return On(Qe),null;case 25:return null;default:return null}}function Yg(t,r){switch(ou(r),r.tag){case 3:On(Qe),gn();break;case 26:case 27:case 5:ht(r);break;case 4:gn();break;case 13:jn(r);break;case 19:Q(Ze);break;case 10:On(r.type);break;case 22:case 23:jn(r),xu(),t!==null&&Q(Ui);break;case 24:On(Qe)}}function ra(t,r){try{var l=r.updateQueue,c=l!==null?l.lastEffect:null;if(c!==null){var h=c.next;l=h;do{if((l.tag&t)===t){c=void 0;var g=l.create,S=l.inst;c=g(),S.destroy=c}l=l.next}while(l!==h)}}catch(T){Oe(r,r.return,T)}}function si(t,r,l){try{var c=r.updateQueue,h=c!==null?c.lastEffect:null;if(h!==null){var g=h.next;c=g;do{if((c.tag&t)===t){var S=c.inst,T=S.destroy;if(T!==void 0){S.destroy=void 0,h=r;var A=l,D=T;try{D()}catch(K){Oe(h,A,K)}}}c=c.next}while(c!==g)}}catch(K){Oe(r,r.return,K)}}function Xg(t){var r=t.updateQueue;if(r!==null){var l=t.stateNode;try{Lp(r,l)}catch(c){Oe(t,t.return,c)}}}function Pg(t,r,l){l.props=Hi(t.type,t.memoizedProps),l.state=t.memoizedState;try{l.componentWillUnmount()}catch(c){Oe(t,r,c)}}function aa(t,r){try{var l=t.ref;if(l!==null){switch(t.tag){case 26:case 27:case 5:var c=t.stateNode;break;case 30:c=t.stateNode;break;default:c=t.stateNode}typeof l=="function"?t.refCleanup=l(c):l.current=c}}catch(h){Oe(t,r,h)}}function bn(t,r){var l=t.ref,c=t.refCleanup;if(l!==null)if(typeof c=="function")try{c()}catch(h){Oe(t,r,h)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(h){Oe(t,r,h)}else l.current=null}function Fg(t){var r=t.type,l=t.memoizedProps,c=t.stateNode;try{e:switch(r){case"button":case"input":case"select":case"textarea":l.autoFocus&&c.focus();break e;case"img":l.src?c.src=l.src:l.srcSet&&(c.srcset=l.srcSet)}}catch(h){Oe(t,t.return,h)}}function Qu(t,r,l){try{var c=t.stateNode;X1(c,t.type,l,r),c[Nt]=r}catch(h){Oe(t,t.return,h)}}function Qg(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&hi(t.type)||t.tag===4}function Zu(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||Qg(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&hi(t.type)||t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Ju(t,r,l){var c=t.tag;if(c===5||c===6)t=t.stateNode,r?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(t,r):(r=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,r.appendChild(t),l=l._reactRootContainer,l!=null||r.onclick!==null||(r.onclick=so));else if(c!==4&&(c===27&&hi(t.type)&&(l=t.stateNode,r=null),t=t.child,t!==null))for(Ju(t,r,l),t=t.sibling;t!==null;)Ju(t,r,l),t=t.sibling}function Xl(t,r,l){var c=t.tag;if(c===5||c===6)t=t.stateNode,r?l.insertBefore(t,r):l.appendChild(t);else if(c!==4&&(c===27&&hi(t.type)&&(l=t.stateNode),t=t.child,t!==null))for(Xl(t,r,l),t=t.sibling;t!==null;)Xl(t,r,l),t=t.sibling}function Zg(t){var r=t.stateNode,l=t.memoizedProps;try{for(var c=t.type,h=r.attributes;h.length;)r.removeAttributeNode(h[0]);ot(r,c,l),r[pt]=t,r[Nt]=l}catch(g){Oe(t,t.return,g)}}var Bn=!1,Ge=!1,Wu=!1,Jg=typeof WeakSet=="function"?WeakSet:Set,nt=null;function N1(t,r){if(t=t.containerInfo,Tf=fo,t=cp(t),Zc(t)){if("selectionStart"in t)var l={start:t.selectionStart,end:t.selectionEnd};else e:{l=(l=t.ownerDocument)&&l.defaultView||window;var c=l.getSelection&&l.getSelection();if(c&&c.rangeCount!==0){l=c.anchorNode;var h=c.anchorOffset,g=c.focusNode;c=c.focusOffset;try{l.nodeType,g.nodeType}catch{l=null;break e}var S=0,T=-1,A=-1,D=0,K=0,P=t,z=null;t:for(;;){for(var H;P!==l||h!==0&&P.nodeType!==3||(T=S+h),P!==g||c!==0&&P.nodeType!==3||(A=S+c),P.nodeType===3&&(S+=P.nodeValue.length),(H=P.firstChild)!==null;)z=P,P=H;for(;;){if(P===t)break t;if(z===l&&++D===h&&(T=S),z===g&&++K===c&&(A=S),(H=P.nextSibling)!==null)break;P=z,z=P.parentNode}P=H}l=T===-1||A===-1?null:{start:T,end:A}}else l=null}l=l||{start:0,end:0}}else l=null;for(Ef={focusedElem:t,selectionRange:l},fo=!1,nt=r;nt!==null;)if(r=nt,t=r.child,(r.subtreeFlags&1024)!==0&&t!==null)t.return=r,nt=t;else for(;nt!==null;){switch(r=nt,g=r.alternate,t=r.flags,r.tag){case 0:break;case 11:case 15:break;case 1:if((t&1024)!==0&&g!==null){t=void 0,l=r,h=g.memoizedProps,g=g.memoizedState,c=l.stateNode;try{var ce=Hi(l.type,h,l.elementType===l.type);t=c.getSnapshotBeforeUpdate(ce,g),c.__reactInternalSnapshotBeforeUpdate=t}catch(ae){Oe(l,l.return,ae)}}break;case 3:if((t&1024)!==0){if(t=r.stateNode.containerInfo,l=t.nodeType,l===9)Cf(t);else if(l===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":Cf(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(s(163))}if(t=r.sibling,t!==null){t.return=r.return,nt=t;break}nt=r.return}}function Wg(t,r,l){var c=l.flags;switch(l.tag){case 0:case 11:case 15:ri(t,l),c&4&&ra(5,l);break;case 1:if(ri(t,l),c&4)if(t=l.stateNode,r===null)try{t.componentDidMount()}catch(S){Oe(l,l.return,S)}else{var h=Hi(l.type,r.memoizedProps);r=r.memoizedState;try{t.componentDidUpdate(h,r,t.__reactInternalSnapshotBeforeUpdate)}catch(S){Oe(l,l.return,S)}}c&64&&Xg(l),c&512&&aa(l,l.return);break;case 3:if(ri(t,l),c&64&&(t=l.updateQueue,t!==null)){if(r=null,l.child!==null)switch(l.child.tag){case 27:case 5:r=l.child.stateNode;break;case 1:r=l.child.stateNode}try{Lp(t,r)}catch(S){Oe(l,l.return,S)}}break;case 27:r===null&&c&4&&Zg(l);case 26:case 5:ri(t,l),r===null&&c&4&&Fg(l),c&512&&aa(l,l.return);break;case 12:ri(t,l);break;case 13:ri(t,l),c&4&&nm(t,l),c&64&&(t=l.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(l=B1.bind(null,l),ew(t,l))));break;case 22:if(c=l.memoizedState!==null||Bn,!c){r=r!==null&&r.memoizedState!==null||Ge,h=Bn;var g=Ge;Bn=c,(Ge=r)&&!g?ai(t,l,(l.subtreeFlags&8772)!==0):ri(t,l),Bn=h,Ge=g}break;case 30:break;default:ri(t,l)}}function em(t){var r=t.alternate;r!==null&&(t.alternate=null,em(r)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(r=t.stateNode,r!==null&&Rc(r)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var Le=null,Mt=!1;function Un(t,r,l){for(l=l.child;l!==null;)tm(t,r,l),l=l.sibling}function tm(t,r,l){if(vt&&typeof vt.onCommitFiberUnmount=="function")try{vt.onCommitFiberUnmount(Ti,l)}catch{}switch(l.tag){case 26:Ge||bn(l,r),Un(t,r,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:Ge||bn(l,r);var c=Le,h=Mt;hi(l.type)&&(Le=l.stateNode,Mt=!1),Un(t,r,l),ga(l.stateNode),Le=c,Mt=h;break;case 5:Ge||bn(l,r);case 6:if(c=Le,h=Mt,Le=null,Un(t,r,l),Le=c,Mt=h,Le!==null)if(Mt)try{(Le.nodeType===9?Le.body:Le.nodeName==="HTML"?Le.ownerDocument.body:Le).removeChild(l.stateNode)}catch(g){Oe(l,r,g)}else try{Le.removeChild(l.stateNode)}catch(g){Oe(l,r,g)}break;case 18:Le!==null&&(Mt?(t=Le,Vm(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,l.stateNode),_a(t)):Vm(Le,l.stateNode));break;case 4:c=Le,h=Mt,Le=l.stateNode.containerInfo,Mt=!0,Un(t,r,l),Le=c,Mt=h;break;case 0:case 11:case 14:case 15:Ge||si(2,l,r),Ge||si(4,l,r),Un(t,r,l);break;case 1:Ge||(bn(l,r),c=l.stateNode,typeof c.componentWillUnmount=="function"&&Pg(l,r,c)),Un(t,r,l);break;case 21:Un(t,r,l);break;case 22:Ge=(c=Ge)||l.memoizedState!==null,Un(t,r,l),Ge=c;break;default:Un(t,r,l)}}function nm(t,r){if(r.memoizedState===null&&(t=r.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{_a(t)}catch(l){Oe(r,r.return,l)}}function C1(t){switch(t.tag){case 13:case 19:var r=t.stateNode;return r===null&&(r=t.stateNode=new Jg),r;case 22:return t=t.stateNode,r=t._retryCache,r===null&&(r=t._retryCache=new Jg),r;default:throw Error(s(435,t.tag))}}function ef(t,r){var l=C1(t);r.forEach(function(c){var h=U1.bind(null,t,c);l.has(c)||(l.add(c),c.then(h,h))})}function It(t,r){var l=r.deletions;if(l!==null)for(var c=0;c<l.length;c++){var h=l[c],g=t,S=r,T=S;e:for(;T!==null;){switch(T.tag){case 27:if(hi(T.type)){Le=T.stateNode,Mt=!1;break e}break;case 5:Le=T.stateNode,Mt=!1;break e;case 3:case 4:Le=T.stateNode.containerInfo,Mt=!0;break e}T=T.return}if(Le===null)throw Error(s(160));tm(g,S,h),Le=null,Mt=!1,g=h.alternate,g!==null&&(g.return=null),h.return=null}if(r.subtreeFlags&13878)for(r=r.child;r!==null;)im(r,t),r=r.sibling}var un=null;function im(t,r){var l=t.alternate,c=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:It(r,t),Vt(t),c&4&&(si(3,t,t.return),ra(3,t),si(5,t,t.return));break;case 1:It(r,t),Vt(t),c&512&&(Ge||l===null||bn(l,l.return)),c&64&&Bn&&(t=t.updateQueue,t!==null&&(c=t.callbacks,c!==null&&(l=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=l===null?c:l.concat(c))));break;case 26:var h=un;if(It(r,t),Vt(t),c&512&&(Ge||l===null||bn(l,l.return)),c&4){var g=l!==null?l.memoizedState:null;if(c=t.memoizedState,l===null)if(c===null)if(t.stateNode===null){e:{c=t.type,l=t.memoizedProps,h=h.ownerDocument||h;t:switch(c){case"title":g=h.getElementsByTagName("title")[0],(!g||g[Mr]||g[pt]||g.namespaceURI==="http://www.w3.org/2000/svg"||g.hasAttribute("itemprop"))&&(g=h.createElement(c),h.head.insertBefore(g,h.querySelector("head > title"))),ot(g,c,l),g[pt]=t,et(g),c=g;break e;case"link":var S=Zm("link","href",h).get(c+(l.href||""));if(S){for(var T=0;T<S.length;T++)if(g=S[T],g.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&g.getAttribute("rel")===(l.rel==null?null:l.rel)&&g.getAttribute("title")===(l.title==null?null:l.title)&&g.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){S.splice(T,1);break t}}g=h.createElement(c),ot(g,c,l),h.head.appendChild(g);break;case"meta":if(S=Zm("meta","content",h).get(c+(l.content||""))){for(T=0;T<S.length;T++)if(g=S[T],g.getAttribute("content")===(l.content==null?null:""+l.content)&&g.getAttribute("name")===(l.name==null?null:l.name)&&g.getAttribute("property")===(l.property==null?null:l.property)&&g.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&g.getAttribute("charset")===(l.charSet==null?null:l.charSet)){S.splice(T,1);break t}}g=h.createElement(c),ot(g,c,l),h.head.appendChild(g);break;default:throw Error(s(468,c))}g[pt]=t,et(g),c=g}t.stateNode=c}else Jm(h,t.type,t.stateNode);else t.stateNode=Qm(h,c,t.memoizedProps);else g!==c?(g===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):g.count--,c===null?Jm(h,t.type,t.stateNode):Qm(h,c,t.memoizedProps)):c===null&&t.stateNode!==null&&Qu(t,t.memoizedProps,l.memoizedProps)}break;case 27:It(r,t),Vt(t),c&512&&(Ge||l===null||bn(l,l.return)),l!==null&&c&4&&Qu(t,t.memoizedProps,l.memoizedProps);break;case 5:if(It(r,t),Vt(t),c&512&&(Ge||l===null||bn(l,l.return)),t.flags&32){h=t.stateNode;try{ms(h,"")}catch(H){Oe(t,t.return,H)}}c&4&&t.stateNode!=null&&(h=t.memoizedProps,Qu(t,h,l!==null?l.memoizedProps:h)),c&1024&&(Wu=!0);break;case 6:if(It(r,t),Vt(t),c&4){if(t.stateNode===null)throw Error(s(162));c=t.memoizedProps,l=t.stateNode;try{l.nodeValue=c}catch(H){Oe(t,t.return,H)}}break;case 3:if(oo=null,h=un,un=ao(r.containerInfo),It(r,t),un=h,Vt(t),c&4&&l!==null&&l.memoizedState.isDehydrated)try{_a(r.containerInfo)}catch(H){Oe(t,t.return,H)}Wu&&(Wu=!1,sm(t));break;case 4:c=un,un=ao(t.stateNode.containerInfo),It(r,t),Vt(t),un=c;break;case 12:It(r,t),Vt(t);break;case 13:It(r,t),Vt(t),t.child.flags&8192&&t.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(lf=Ht()),c&4&&(c=t.updateQueue,c!==null&&(t.updateQueue=null,ef(t,c)));break;case 22:h=t.memoizedState!==null;var A=l!==null&&l.memoizedState!==null,D=Bn,K=Ge;if(Bn=D||h,Ge=K||A,It(r,t),Ge=K,Bn=D,Vt(t),c&8192)e:for(r=t.stateNode,r._visibility=h?r._visibility&-2:r._visibility|1,h&&(l===null||A||Bn||Ge||qi(t)),l=null,r=t;;){if(r.tag===5||r.tag===26){if(l===null){A=l=r;try{if(g=A.stateNode,h)S=g.style,typeof S.setProperty=="function"?S.setProperty("display","none","important"):S.display="none";else{T=A.stateNode;var P=A.memoizedProps.style,z=P!=null&&P.hasOwnProperty("display")?P.display:null;T.style.display=z==null||typeof z=="boolean"?"":(""+z).trim()}}catch(H){Oe(A,A.return,H)}}}else if(r.tag===6){if(l===null){A=r;try{A.stateNode.nodeValue=h?"":A.memoizedProps}catch(H){Oe(A,A.return,H)}}}else if((r.tag!==22&&r.tag!==23||r.memoizedState===null||r===t)&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break e;for(;r.sibling===null;){if(r.return===null||r.return===t)break e;l===r&&(l=null),r=r.return}l===r&&(l=null),r.sibling.return=r.return,r=r.sibling}c&4&&(c=t.updateQueue,c!==null&&(l=c.retryQueue,l!==null&&(c.retryQueue=null,ef(t,l))));break;case 19:It(r,t),Vt(t),c&4&&(c=t.updateQueue,c!==null&&(t.updateQueue=null,ef(t,c)));break;case 30:break;case 21:break;default:It(r,t),Vt(t)}}function Vt(t){var r=t.flags;if(r&2){try{for(var l,c=t.return;c!==null;){if(Qg(c)){l=c;break}c=c.return}if(l==null)throw Error(s(160));switch(l.tag){case 27:var h=l.stateNode,g=Zu(t);Xl(t,g,h);break;case 5:var S=l.stateNode;l.flags&32&&(ms(S,""),l.flags&=-33);var T=Zu(t);Xl(t,T,S);break;case 3:case 4:var A=l.stateNode.containerInfo,D=Zu(t);Ju(t,D,A);break;default:throw Error(s(161))}}catch(K){Oe(t,t.return,K)}t.flags&=-3}r&4096&&(t.flags&=-4097)}function sm(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var r=t;sm(r),r.tag===5&&r.flags&1024&&r.stateNode.reset(),t=t.sibling}}function ri(t,r){if(r.subtreeFlags&8772)for(r=r.child;r!==null;)Wg(t,r.alternate,r),r=r.sibling}function qi(t){for(t=t.child;t!==null;){var r=t;switch(r.tag){case 0:case 11:case 14:case 15:si(4,r,r.return),qi(r);break;case 1:bn(r,r.return);var l=r.stateNode;typeof l.componentWillUnmount=="function"&&Pg(r,r.return,l),qi(r);break;case 27:ga(r.stateNode);case 26:case 5:bn(r,r.return),qi(r);break;case 22:r.memoizedState===null&&qi(r);break;case 30:qi(r);break;default:qi(r)}t=t.sibling}}function ai(t,r,l){for(l=l&&(r.subtreeFlags&8772)!==0,r=r.child;r!==null;){var c=r.alternate,h=t,g=r,S=g.flags;switch(g.tag){case 0:case 11:case 15:ai(h,g,l),ra(4,g);break;case 1:if(ai(h,g,l),c=g,h=c.stateNode,typeof h.componentDidMount=="function")try{h.componentDidMount()}catch(D){Oe(c,c.return,D)}if(c=g,h=c.updateQueue,h!==null){var T=c.stateNode;try{var A=h.shared.hiddenCallbacks;if(A!==null)for(h.shared.hiddenCallbacks=null,h=0;h<A.length;h++)jp(A[h],T)}catch(D){Oe(c,c.return,D)}}l&&S&64&&Xg(g),aa(g,g.return);break;case 27:Zg(g);case 26:case 5:ai(h,g,l),l&&c===null&&S&4&&Fg(g),aa(g,g.return);break;case 12:ai(h,g,l);break;case 13:ai(h,g,l),l&&S&4&&nm(h,g);break;case 22:g.memoizedState===null&&ai(h,g,l),aa(g,g.return);break;case 30:break;default:ai(h,g,l)}r=r.sibling}}function tf(t,r){var l=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),t=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(t=r.memoizedState.cachePool.pool),t!==l&&(t!=null&&t.refCount++,l!=null&&Kr(l))}function nf(t,r){t=null,r.alternate!==null&&(t=r.alternate.memoizedState.cache),r=r.memoizedState.cache,r!==t&&(r.refCount++,t!=null&&Kr(t))}function vn(t,r,l,c){if(r.subtreeFlags&10256)for(r=r.child;r!==null;)rm(t,r,l,c),r=r.sibling}function rm(t,r,l,c){var h=r.flags;switch(r.tag){case 0:case 11:case 15:vn(t,r,l,c),h&2048&&ra(9,r);break;case 1:vn(t,r,l,c);break;case 3:vn(t,r,l,c),h&2048&&(t=null,r.alternate!==null&&(t=r.alternate.memoizedState.cache),r=r.memoizedState.cache,r!==t&&(r.refCount++,t!=null&&Kr(t)));break;case 12:if(h&2048){vn(t,r,l,c),t=r.stateNode;try{var g=r.memoizedProps,S=g.id,T=g.onPostCommit;typeof T=="function"&&T(S,r.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(A){Oe(r,r.return,A)}}else vn(t,r,l,c);break;case 13:vn(t,r,l,c);break;case 23:break;case 22:g=r.stateNode,S=r.alternate,r.memoizedState!==null?g._visibility&2?vn(t,r,l,c):la(t,r):g._visibility&2?vn(t,r,l,c):(g._visibility|=2,Ds(t,r,l,c,(r.subtreeFlags&10256)!==0)),h&2048&&tf(S,r);break;case 24:vn(t,r,l,c),h&2048&&nf(r.alternate,r);break;default:vn(t,r,l,c)}}function Ds(t,r,l,c,h){for(h=h&&(r.subtreeFlags&10256)!==0,r=r.child;r!==null;){var g=t,S=r,T=l,A=c,D=S.flags;switch(S.tag){case 0:case 11:case 15:Ds(g,S,T,A,h),ra(8,S);break;case 23:break;case 22:var K=S.stateNode;S.memoizedState!==null?K._visibility&2?Ds(g,S,T,A,h):la(g,S):(K._visibility|=2,Ds(g,S,T,A,h)),h&&D&2048&&tf(S.alternate,S);break;case 24:Ds(g,S,T,A,h),h&&D&2048&&nf(S.alternate,S);break;default:Ds(g,S,T,A,h)}r=r.sibling}}function la(t,r){if(r.subtreeFlags&10256)for(r=r.child;r!==null;){var l=t,c=r,h=c.flags;switch(c.tag){case 22:la(l,c),h&2048&&tf(c.alternate,c);break;case 24:la(l,c),h&2048&&nf(c.alternate,c);break;default:la(l,c)}r=r.sibling}}var oa=8192;function Bs(t){if(t.subtreeFlags&oa)for(t=t.child;t!==null;)am(t),t=t.sibling}function am(t){switch(t.tag){case 26:Bs(t),t.flags&oa&&t.memoizedState!==null&&dw(un,t.memoizedState,t.memoizedProps);break;case 5:Bs(t);break;case 3:case 4:var r=un;un=ao(t.stateNode.containerInfo),Bs(t),un=r;break;case 22:t.memoizedState===null&&(r=t.alternate,r!==null&&r.memoizedState!==null?(r=oa,oa=16777216,Bs(t),oa=r):Bs(t));break;default:Bs(t)}}function lm(t){var r=t.alternate;if(r!==null&&(t=r.child,t!==null)){r.child=null;do r=t.sibling,t.sibling=null,t=r;while(t!==null)}}function ca(t){var r=t.deletions;if((t.flags&16)!==0){if(r!==null)for(var l=0;l<r.length;l++){var c=r[l];nt=c,cm(c,t)}lm(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)om(t),t=t.sibling}function om(t){switch(t.tag){case 0:case 11:case 15:ca(t),t.flags&2048&&si(9,t,t.return);break;case 3:ca(t);break;case 12:ca(t);break;case 22:var r=t.stateNode;t.memoizedState!==null&&r._visibility&2&&(t.return===null||t.return.tag!==13)?(r._visibility&=-3,Pl(t)):ca(t);break;default:ca(t)}}function Pl(t){var r=t.deletions;if((t.flags&16)!==0){if(r!==null)for(var l=0;l<r.length;l++){var c=r[l];nt=c,cm(c,t)}lm(t)}for(t=t.child;t!==null;){switch(r=t,r.tag){case 0:case 11:case 15:si(8,r,r.return),Pl(r);break;case 22:l=r.stateNode,l._visibility&2&&(l._visibility&=-3,Pl(r));break;default:Pl(r)}t=t.sibling}}function cm(t,r){for(;nt!==null;){var l=nt;switch(l.tag){case 0:case 11:case 15:si(8,l,r);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var c=l.memoizedState.cachePool.pool;c!=null&&c.refCount++}break;case 24:Kr(l.memoizedState.cache)}if(c=l.child,c!==null)c.return=l,nt=c;else e:for(l=t;nt!==null;){c=nt;var h=c.sibling,g=c.return;if(em(c),c===l){nt=null;break e}if(h!==null){h.return=g,nt=h;break e}nt=g}}}var k1={getCacheForType:function(t){var r=gt(Qe),l=r.data.get(t);return l===void 0&&(l=t(),r.data.set(t,l)),l}},M1=typeof WeakMap=="function"?WeakMap:Map,Ee=0,je=null,ye=null,we=0,Ae=0,Gt=null,li=!1,Us=!1,sf=!1,zn=0,Ie=0,oi=0,$i=0,rf=0,tn=0,zs=0,ua=null,Ot=null,af=!1,lf=0,Fl=1/0,Ql=null,ci=null,lt=0,ui=null,Hs=null,qs=0,of=0,cf=null,um=null,fa=0,uf=null;function Kt(){if((Ee&2)!==0&&we!==0)return we&-we;if(q.T!==null){var t=Ns;return t!==0?t:yf()}return Ad()}function fm(){tn===0&&(tn=(we&536870912)===0||Te?xd():536870912);var t=en.current;return t!==null&&(t.flags|=32),tn}function Yt(t,r,l){(t===je&&(Ae===2||Ae===9)||t.cancelPendingCommit!==null)&&($s(t,0),fi(t,we,tn,!1)),kr(t,l),((Ee&2)===0||t!==je)&&(t===je&&((Ee&2)===0&&($i|=l),Ie===4&&fi(t,we,tn,!1)),Sn(t))}function hm(t,r,l){if((Ee&6)!==0)throw Error(s(327));var c=!l&&(r&124)===0&&(r&t.expiredLanes)===0||Cr(t,r),h=c?j1(t,r):df(t,r,!0),g=c;do{if(h===0){Us&&!c&&fi(t,r,0,!1);break}else{if(l=t.current.alternate,g&&!O1(l)){h=df(t,r,!1),g=!1;continue}if(h===2){if(g=r,t.errorRecoveryDisabledLanes&g)var S=0;else S=t.pendingLanes&-536870913,S=S!==0?S:S&536870912?536870912:0;if(S!==0){r=S;e:{var T=t;h=ua;var A=T.current.memoizedState.isDehydrated;if(A&&($s(T,S).flags|=256),S=df(T,S,!1),S!==2){if(sf&&!A){T.errorRecoveryDisabledLanes|=g,$i|=g,h=4;break e}g=Ot,Ot=h,g!==null&&(Ot===null?Ot=g:Ot.push.apply(Ot,g))}h=S}if(g=!1,h!==2)continue}}if(h===1){$s(t,0),fi(t,r,0,!0);break}e:{switch(c=t,g=h,g){case 0:case 1:throw Error(s(345));case 4:if((r&4194048)!==r)break;case 6:fi(c,r,tn,!li);break e;case 2:Ot=null;break;case 3:case 5:break;default:throw Error(s(329))}if((r&62914560)===r&&(h=lf+300-Ht(),10<h)){if(fi(c,r,tn,!li),At(c,0,!0)!==0)break e;c.timeoutHandle=$m(dm.bind(null,c,l,Ot,Ql,af,r,tn,$i,zs,li,g,2,-0,0),h);break e}dm(c,l,Ot,Ql,af,r,tn,$i,zs,li,g,0,-0,0)}}break}while(!0);Sn(t)}function dm(t,r,l,c,h,g,S,T,A,D,K,P,z,H){if(t.timeoutHandle=-1,P=r.subtreeFlags,(P&8192||(P&16785408)===16785408)&&(ba={stylesheets:null,count:0,unsuspend:hw},am(r),P=pw(),P!==null)){t.cancelPendingCommit=P(Sm.bind(null,t,r,g,l,c,h,S,T,A,K,1,z,H)),fi(t,g,S,!D);return}Sm(t,r,g,l,c,h,S,T,A)}function O1(t){for(var r=t;;){var l=r.tag;if((l===0||l===11||l===15)&&r.flags&16384&&(l=r.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var c=0;c<l.length;c++){var h=l[c],g=h.getSnapshot;h=h.value;try{if(!qt(g(),h))return!1}catch{return!1}}if(l=r.child,r.subtreeFlags&16384&&l!==null)l.return=r,r=l;else{if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return!0;r=r.return}r.sibling.return=r.return,r=r.sibling}}return!0}function fi(t,r,l,c){r&=~rf,r&=~$i,t.suspendedLanes|=r,t.pingedLanes&=~r,c&&(t.warmLanes|=r),c=t.expirationTimes;for(var h=r;0<h;){var g=31-rt(h),S=1<<g;c[g]=-1,h&=~S}l!==0&&Td(t,l,r)}function Zl(){return(Ee&6)===0?(ha(0),!1):!0}function ff(){if(ye!==null){if(Ae===0)var t=ye.return;else t=ye,Mn=Di=null,Nu(t),js=null,na=0,t=ye;for(;t!==null;)Yg(t.alternate,t),t=t.return;ye=null}}function $s(t,r){var l=t.timeoutHandle;l!==-1&&(t.timeoutHandle=-1,F1(l)),l=t.cancelPendingCommit,l!==null&&(t.cancelPendingCommit=null,l()),ff(),je=t,ye=l=Nn(t.current,null),we=r,Ae=0,Gt=null,li=!1,Us=Cr(t,r),sf=!1,zs=tn=rf=$i=oi=Ie=0,Ot=ua=null,af=!1,(r&8)!==0&&(r|=r&32);var c=t.entangledLanes;if(c!==0)for(t=t.entanglements,c&=r;0<c;){var h=31-rt(c),g=1<<h;r|=t[h],c&=~g}return zn=r,vl(),l}function pm(t,r){de=null,q.H=zl,r===Xr||r===Cl?(r=Op(),Ae=3):r===Cp?(r=Op(),Ae=4):Ae=r===Rg?8:r!==null&&typeof r=="object"&&typeof r.then=="function"?6:1,Gt=r,ye===null&&(Ie=1,Vl(t,Qt(r,t.current)))}function gm(){var t=q.H;return q.H=zl,t===null?zl:t}function mm(){var t=q.A;return q.A=k1,t}function hf(){Ie=4,li||(we&4194048)!==we&&en.current!==null||(Us=!0),(oi&134217727)===0&&($i&134217727)===0||je===null||fi(je,we,tn,!1)}function df(t,r,l){var c=Ee;Ee|=2;var h=gm(),g=mm();(je!==t||we!==r)&&(Ql=null,$s(t,r)),r=!1;var S=Ie;e:do try{if(Ae!==0&&ye!==null){var T=ye,A=Gt;switch(Ae){case 8:ff(),S=6;break e;case 3:case 2:case 9:case 6:en.current===null&&(r=!0);var D=Ae;if(Ae=0,Gt=null,Is(t,T,A,D),l&&Us){S=0;break e}break;default:D=Ae,Ae=0,Gt=null,Is(t,T,A,D)}}R1(),S=Ie;break}catch(K){pm(t,K)}while(!0);return r&&t.shellSuspendCounter++,Mn=Di=null,Ee=c,q.H=h,q.A=g,ye===null&&(je=null,we=0,vl()),S}function R1(){for(;ye!==null;)ym(ye)}function j1(t,r){var l=Ee;Ee|=2;var c=gm(),h=mm();je!==t||we!==r?(Ql=null,Fl=Ht()+500,$s(t,r)):Us=Cr(t,r);e:do try{if(Ae!==0&&ye!==null){r=ye;var g=Gt;t:switch(Ae){case 1:Ae=0,Gt=null,Is(t,r,g,1);break;case 2:case 9:if(kp(g)){Ae=0,Gt=null,bm(r);break}r=function(){Ae!==2&&Ae!==9||je!==t||(Ae=7),Sn(t)},g.then(r,r);break e;case 3:Ae=7;break e;case 4:Ae=5;break e;case 7:kp(g)?(Ae=0,Gt=null,bm(r)):(Ae=0,Gt=null,Is(t,r,g,7));break;case 5:var S=null;switch(ye.tag){case 26:S=ye.memoizedState;case 5:case 27:var T=ye;if(!S||Wm(S)){Ae=0,Gt=null;var A=T.sibling;if(A!==null)ye=A;else{var D=T.return;D!==null?(ye=D,Jl(D)):ye=null}break t}}Ae=0,Gt=null,Is(t,r,g,5);break;case 6:Ae=0,Gt=null,Is(t,r,g,6);break;case 8:ff(),Ie=6;break e;default:throw Error(s(462))}}L1();break}catch(K){pm(t,K)}while(!0);return Mn=Di=null,q.H=c,q.A=h,Ee=l,ye!==null?0:(je=null,we=0,vl(),Ie)}function L1(){for(;ye!==null&&!Er();)ym(ye)}function ym(t){var r=Gg(t.alternate,t,zn);t.memoizedProps=t.pendingProps,r===null?Jl(t):ye=r}function bm(t){var r=t,l=r.alternate;switch(r.tag){case 15:case 0:r=zg(l,r,r.pendingProps,r.type,void 0,we);break;case 11:r=zg(l,r,r.pendingProps,r.type.render,r.ref,we);break;case 5:Nu(r);default:Yg(l,r),r=ye=vp(r,zn),r=Gg(l,r,zn)}t.memoizedProps=t.pendingProps,r===null?Jl(t):ye=r}function Is(t,r,l,c){Mn=Di=null,Nu(r),js=null,na=0;var h=r.return;try{if(_1(t,h,r,l,we)){Ie=1,Vl(t,Qt(l,t.current)),ye=null;return}}catch(g){if(h!==null)throw ye=h,g;Ie=1,Vl(t,Qt(l,t.current)),ye=null;return}r.flags&32768?(Te||c===1?t=!0:Us||(we&536870912)!==0?t=!1:(li=t=!0,(c===2||c===9||c===3||c===6)&&(c=en.current,c!==null&&c.tag===13&&(c.flags|=16384))),vm(r,t)):Jl(r)}function Jl(t){var r=t;do{if((r.flags&32768)!==0){vm(r,li);return}t=r.return;var l=E1(r.alternate,r,zn);if(l!==null){ye=l;return}if(r=r.sibling,r!==null){ye=r;return}ye=r=t}while(r!==null);Ie===0&&(Ie=5)}function vm(t,r){do{var l=A1(t.alternate,t);if(l!==null){l.flags&=32767,ye=l;return}if(l=t.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!r&&(t=t.sibling,t!==null)){ye=t;return}ye=t=l}while(t!==null);Ie=6,ye=null}function Sm(t,r,l,c,h,g,S,T,A){t.cancelPendingCommit=null;do Wl();while(lt!==0);if((Ee&6)!==0)throw Error(s(327));if(r!==null){if(r===t.current)throw Error(s(177));if(g=r.lanes|r.childLanes,g|=nu,hS(t,l,g,S,T,A),t===je&&(ye=je=null,we=0),Hs=r,ui=t,qs=l,of=g,cf=h,um=c,(r.subtreeFlags&10256)!==0||(r.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,z1(ls,function(){return Em(),null})):(t.callbackNode=null,t.callbackPriority=0),c=(r.flags&13878)!==0,(r.subtreeFlags&13878)!==0||c){c=q.T,q.T=null,h=Z.p,Z.p=2,S=Ee,Ee|=4;try{N1(t,r,l)}finally{Ee=S,Z.p=h,q.T=c}}lt=1,wm(),xm(),_m()}}function wm(){if(lt===1){lt=0;var t=ui,r=Hs,l=(r.flags&13878)!==0;if((r.subtreeFlags&13878)!==0||l){l=q.T,q.T=null;var c=Z.p;Z.p=2;var h=Ee;Ee|=4;try{im(r,t);var g=Ef,S=cp(t.containerInfo),T=g.focusedElem,A=g.selectionRange;if(S!==T&&T&&T.ownerDocument&&op(T.ownerDocument.documentElement,T)){if(A!==null&&Zc(T)){var D=A.start,K=A.end;if(K===void 0&&(K=D),"selectionStart"in T)T.selectionStart=D,T.selectionEnd=Math.min(K,T.value.length);else{var P=T.ownerDocument||document,z=P&&P.defaultView||window;if(z.getSelection){var H=z.getSelection(),ce=T.textContent.length,ae=Math.min(A.start,ce),Me=A.end===void 0?ae:Math.min(A.end,ce);!H.extend&&ae>Me&&(S=Me,Me=ae,ae=S);var O=lp(T,ae),M=lp(T,Me);if(O&&M&&(H.rangeCount!==1||H.anchorNode!==O.node||H.anchorOffset!==O.offset||H.focusNode!==M.node||H.focusOffset!==M.offset)){var L=P.createRange();L.setStart(O.node,O.offset),H.removeAllRanges(),ae>Me?(H.addRange(L),H.extend(M.node,M.offset)):(L.setEnd(M.node,M.offset),H.addRange(L))}}}}for(P=[],H=T;H=H.parentNode;)H.nodeType===1&&P.push({element:H,left:H.scrollLeft,top:H.scrollTop});for(typeof T.focus=="function"&&T.focus(),T=0;T<P.length;T++){var Y=P[T];Y.element.scrollLeft=Y.left,Y.element.scrollTop=Y.top}}fo=!!Tf,Ef=Tf=null}finally{Ee=h,Z.p=c,q.T=l}}t.current=r,lt=2}}function xm(){if(lt===2){lt=0;var t=ui,r=Hs,l=(r.flags&8772)!==0;if((r.subtreeFlags&8772)!==0||l){l=q.T,q.T=null;var c=Z.p;Z.p=2;var h=Ee;Ee|=4;try{Wg(t,r.alternate,r)}finally{Ee=h,Z.p=c,q.T=l}}lt=3}}function _m(){if(lt===4||lt===3){lt=0,rl();var t=ui,r=Hs,l=qs,c=um;(r.subtreeFlags&10256)!==0||(r.flags&10256)!==0?lt=5:(lt=0,Hs=ui=null,Tm(t,t.pendingLanes));var h=t.pendingLanes;if(h===0&&(ci=null),Mc(l),r=r.stateNode,vt&&typeof vt.onCommitFiberRoot=="function")try{vt.onCommitFiberRoot(Ti,r,void 0,(r.current.flags&128)===128)}catch{}if(c!==null){r=q.T,h=Z.p,Z.p=2,q.T=null;try{for(var g=t.onRecoverableError,S=0;S<c.length;S++){var T=c[S];g(T.value,{componentStack:T.stack})}}finally{q.T=r,Z.p=h}}(qs&3)!==0&&Wl(),Sn(t),h=t.pendingLanes,(l&4194090)!==0&&(h&42)!==0?t===uf?fa++:(fa=0,uf=t):fa=0,ha(0)}}function Tm(t,r){(t.pooledCacheLanes&=r)===0&&(r=t.pooledCache,r!=null&&(t.pooledCache=null,Kr(r)))}function Wl(t){return wm(),xm(),_m(),Em()}function Em(){if(lt!==5)return!1;var t=ui,r=of;of=0;var l=Mc(qs),c=q.T,h=Z.p;try{Z.p=32>l?32:l,q.T=null,l=cf,cf=null;var g=ui,S=qs;if(lt=0,Hs=ui=null,qs=0,(Ee&6)!==0)throw Error(s(331));var T=Ee;if(Ee|=4,om(g.current),rm(g,g.current,S,l),Ee=T,ha(0,!1),vt&&typeof vt.onPostCommitFiberRoot=="function")try{vt.onPostCommitFiberRoot(Ti,g)}catch{}return!0}finally{Z.p=h,q.T=c,Tm(t,r)}}function Am(t,r,l){r=Qt(l,r),r=$u(t.stateNode,r,2),t=ei(t,r,2),t!==null&&(kr(t,2),Sn(t))}function Oe(t,r,l){if(t.tag===3)Am(t,t,l);else for(;r!==null;){if(r.tag===3){Am(r,t,l);break}else if(r.tag===1){var c=r.stateNode;if(typeof r.type.getDerivedStateFromError=="function"||typeof c.componentDidCatch=="function"&&(ci===null||!ci.has(c))){t=Qt(l,t),l=Mg(2),c=ei(r,l,2),c!==null&&(Og(l,c,r,t),kr(c,2),Sn(c));break}}r=r.return}}function pf(t,r,l){var c=t.pingCache;if(c===null){c=t.pingCache=new M1;var h=new Set;c.set(r,h)}else h=c.get(r),h===void 0&&(h=new Set,c.set(r,h));h.has(l)||(sf=!0,h.add(l),t=D1.bind(null,t,r,l),r.then(t,t))}function D1(t,r,l){var c=t.pingCache;c!==null&&c.delete(r),t.pingedLanes|=t.suspendedLanes&l,t.warmLanes&=~l,je===t&&(we&l)===l&&(Ie===4||Ie===3&&(we&62914560)===we&&300>Ht()-lf?(Ee&2)===0&&$s(t,0):rf|=l,zs===we&&(zs=0)),Sn(t)}function Nm(t,r){r===0&&(r=_d()),t=_s(t,r),t!==null&&(kr(t,r),Sn(t))}function B1(t){var r=t.memoizedState,l=0;r!==null&&(l=r.retryLane),Nm(t,l)}function U1(t,r){var l=0;switch(t.tag){case 13:var c=t.stateNode,h=t.memoizedState;h!==null&&(l=h.retryLane);break;case 19:c=t.stateNode;break;case 22:c=t.stateNode._retryCache;break;default:throw Error(s(314))}c!==null&&c.delete(r),Nm(t,l)}function z1(t,r){return _r(t,r)}var eo=null,Vs=null,gf=!1,to=!1,mf=!1,Ii=0;function Sn(t){t!==Vs&&t.next===null&&(Vs===null?eo=Vs=t:Vs=Vs.next=t),to=!0,gf||(gf=!0,q1())}function ha(t,r){if(!mf&&to){mf=!0;do for(var l=!1,c=eo;c!==null;){if(t!==0){var h=c.pendingLanes;if(h===0)var g=0;else{var S=c.suspendedLanes,T=c.pingedLanes;g=(1<<31-rt(42|t)+1)-1,g&=h&~(S&~T),g=g&201326741?g&201326741|1:g?g|2:0}g!==0&&(l=!0,Om(c,g))}else g=we,g=At(c,c===je?g:0,c.cancelPendingCommit!==null||c.timeoutHandle!==-1),(g&3)===0||Cr(c,g)||(l=!0,Om(c,g));c=c.next}while(l);mf=!1}}function H1(){Cm()}function Cm(){to=gf=!1;var t=0;Ii!==0&&(P1()&&(t=Ii),Ii=0);for(var r=Ht(),l=null,c=eo;c!==null;){var h=c.next,g=km(c,r);g===0?(c.next=null,l===null?eo=h:l.next=h,h===null&&(Vs=l)):(l=c,(t!==0||(g&3)!==0)&&(to=!0)),c=h}ha(t)}function km(t,r){for(var l=t.suspendedLanes,c=t.pingedLanes,h=t.expirationTimes,g=t.pendingLanes&-62914561;0<g;){var S=31-rt(g),T=1<<S,A=h[S];A===-1?((T&l)===0||(T&c)!==0)&&(h[S]=fS(T,r)):A<=r&&(t.expiredLanes|=T),g&=~T}if(r=je,l=we,l=At(t,t===r?l:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),c=t.callbackNode,l===0||t===r&&(Ae===2||Ae===9)||t.cancelPendingCommit!==null)return c!==null&&c!==null&&Tr(c),t.callbackNode=null,t.callbackPriority=0;if((l&3)===0||Cr(t,l)){if(r=l&-l,r===t.callbackPriority)return r;switch(c!==null&&Tr(c),Mc(l)){case 2:case 8:l=ll;break;case 32:l=ls;break;case 268435456:l=Ar;break;default:l=ls}return c=Mm.bind(null,t),l=_r(l,c),t.callbackPriority=r,t.callbackNode=l,r}return c!==null&&c!==null&&Tr(c),t.callbackPriority=2,t.callbackNode=null,2}function Mm(t,r){if(lt!==0&<!==5)return t.callbackNode=null,t.callbackPriority=0,null;var l=t.callbackNode;if(Wl()&&t.callbackNode!==l)return null;var c=we;return c=At(t,t===je?c:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),c===0?null:(hm(t,c,r),km(t,Ht()),t.callbackNode!=null&&t.callbackNode===l?Mm.bind(null,t):null)}function Om(t,r){if(Wl())return null;hm(t,r,!0)}function q1(){Q1(function(){(Ee&6)!==0?_r(al,H1):Cm()})}function yf(){return Ii===0&&(Ii=xd()),Ii}function Rm(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:hl(""+t)}function jm(t,r){var l=r.ownerDocument.createElement("input");return l.name=r.name,l.value=r.value,t.id&&l.setAttribute("form",t.id),r.parentNode.insertBefore(l,r),t=new FormData(t),l.parentNode.removeChild(l),t}function $1(t,r,l,c,h){if(r==="submit"&&l&&l.stateNode===h){var g=Rm((h[Nt]||null).action),S=c.submitter;S&&(r=(r=S[Nt]||null)?Rm(r.formAction):S.getAttribute("formAction"),r!==null&&(g=r,S=null));var T=new ml("action","action",null,c,h);t.push({event:T,listeners:[{instance:null,listener:function(){if(c.defaultPrevented){if(Ii!==0){var A=S?jm(h,S):new FormData(h);Bu(l,{pending:!0,data:A,method:h.method,action:g},null,A)}}else typeof g=="function"&&(T.preventDefault(),A=S?jm(h,S):new FormData(h),Bu(l,{pending:!0,data:A,method:h.method,action:g},g,A))},currentTarget:h}]})}}for(var bf=0;bf<tu.length;bf++){var vf=tu[bf],I1=vf.toLowerCase(),V1=vf[0].toUpperCase()+vf.slice(1);cn(I1,"on"+V1)}cn(hp,"onAnimationEnd"),cn(dp,"onAnimationIteration"),cn(pp,"onAnimationStart"),cn("dblclick","onDoubleClick"),cn("focusin","onFocus"),cn("focusout","onBlur"),cn(a1,"onTransitionRun"),cn(l1,"onTransitionStart"),cn(o1,"onTransitionCancel"),cn(gp,"onTransitionEnd"),ds("onMouseEnter",["mouseout","mouseover"]),ds("onMouseLeave",["mouseout","mouseover"]),ds("onPointerEnter",["pointerout","pointerover"]),ds("onPointerLeave",["pointerout","pointerover"]),Ai("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ai("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ai("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ai("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ai("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ai("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var da="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),G1=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(da));function Lm(t,r){r=(r&4)!==0;for(var l=0;l<t.length;l++){var c=t[l],h=c.event;c=c.listeners;e:{var g=void 0;if(r)for(var S=c.length-1;0<=S;S--){var T=c[S],A=T.instance,D=T.currentTarget;if(T=T.listener,A!==g&&h.isPropagationStopped())break e;g=T,h.currentTarget=D;try{g(h)}catch(K){Il(K)}h.currentTarget=null,g=A}else for(S=0;S<c.length;S++){if(T=c[S],A=T.instance,D=T.currentTarget,T=T.listener,A!==g&&h.isPropagationStopped())break e;g=T,h.currentTarget=D;try{g(h)}catch(K){Il(K)}h.currentTarget=null,g=A}}}}function be(t,r){var l=r[Oc];l===void 0&&(l=r[Oc]=new Set);var c=t+"__bubble";l.has(c)||(Dm(r,t,2,!1),l.add(c))}function Sf(t,r,l){var c=0;r&&(c|=4),Dm(l,t,c,r)}var no="_reactListening"+Math.random().toString(36).slice(2);function wf(t){if(!t[no]){t[no]=!0,Cd.forEach(function(l){l!=="selectionchange"&&(G1.has(l)||Sf(l,!1,t),Sf(l,!0,t))});var r=t.nodeType===9?t:t.ownerDocument;r===null||r[no]||(r[no]=!0,Sf("selectionchange",!1,r))}}function Dm(t,r,l,c){switch(ry(r)){case 2:var h=yw;break;case 8:h=bw;break;default:h=Df}l=h.bind(null,r,l,t),h=void 0,!Ic||r!=="touchstart"&&r!=="touchmove"&&r!=="wheel"||(h=!0),c?h!==void 0?t.addEventListener(r,l,{capture:!0,passive:h}):t.addEventListener(r,l,!0):h!==void 0?t.addEventListener(r,l,{passive:h}):t.addEventListener(r,l,!1)}function xf(t,r,l,c,h){var g=c;if((r&1)===0&&(r&2)===0&&c!==null)e:for(;;){if(c===null)return;var S=c.tag;if(S===3||S===4){var T=c.stateNode.containerInfo;if(T===h)break;if(S===4)for(S=c.return;S!==null;){var A=S.tag;if((A===3||A===4)&&S.stateNode.containerInfo===h)return;S=S.return}for(;T!==null;){if(S=us(T),S===null)return;if(A=S.tag,A===5||A===6||A===26||A===27){c=g=S;continue e}T=T.parentNode}}c=c.return}Id(function(){var D=g,K=qc(l),P=[];e:{var z=mp.get(t);if(z!==void 0){var H=ml,ce=t;switch(t){case"keypress":if(pl(l)===0)break e;case"keydown":case"keyup":H=zS;break;case"focusin":ce="focus",H=Yc;break;case"focusout":ce="blur",H=Yc;break;case"beforeblur":case"afterblur":H=Yc;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":H=Kd;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":H=AS;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":H=$S;break;case hp:case dp:case pp:H=kS;break;case gp:H=VS;break;case"scroll":case"scrollend":H=TS;break;case"wheel":H=KS;break;case"copy":case"cut":case"paste":H=OS;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":H=Xd;break;case"toggle":case"beforetoggle":H=XS}var ae=(r&4)!==0,Me=!ae&&(t==="scroll"||t==="scrollend"),O=ae?z!==null?z+"Capture":null:z;ae=[];for(var M=D,L;M!==null;){var Y=M;if(L=Y.stateNode,Y=Y.tag,Y!==5&&Y!==26&&Y!==27||L===null||O===null||(Y=Rr(M,O),Y!=null&&ae.push(pa(M,Y,L))),Me)break;M=M.return}0<ae.length&&(z=new H(z,ce,null,l,K),P.push({event:z,listeners:ae}))}}if((r&7)===0){e:{if(z=t==="mouseover"||t==="pointerover",H=t==="mouseout"||t==="pointerout",z&&l!==Hc&&(ce=l.relatedTarget||l.fromElement)&&(us(ce)||ce[cs]))break e;if((H||z)&&(z=K.window===K?K:(z=K.ownerDocument)?z.defaultView||z.parentWindow:window,H?(ce=l.relatedTarget||l.toElement,H=D,ce=ce?us(ce):null,ce!==null&&(Me=o(ce),ae=ce.tag,ce!==Me||ae!==5&&ae!==27&&ae!==6)&&(ce=null)):(H=null,ce=D),H!==ce)){if(ae=Kd,Y="onMouseLeave",O="onMouseEnter",M="mouse",(t==="pointerout"||t==="pointerover")&&(ae=Xd,Y="onPointerLeave",O="onPointerEnter",M="pointer"),Me=H==null?z:Or(H),L=ce==null?z:Or(ce),z=new ae(Y,M+"leave",H,l,K),z.target=Me,z.relatedTarget=L,Y=null,us(K)===D&&(ae=new ae(O,M+"enter",ce,l,K),ae.target=L,ae.relatedTarget=Me,Y=ae),Me=Y,H&&ce)t:{for(ae=H,O=ce,M=0,L=ae;L;L=Gs(L))M++;for(L=0,Y=O;Y;Y=Gs(Y))L++;for(;0<M-L;)ae=Gs(ae),M--;for(;0<L-M;)O=Gs(O),L--;for(;M--;){if(ae===O||O!==null&&ae===O.alternate)break t;ae=Gs(ae),O=Gs(O)}ae=null}else ae=null;H!==null&&Bm(P,z,H,ae,!1),ce!==null&&Me!==null&&Bm(P,Me,ce,ae,!0)}}e:{if(z=D?Or(D):window,H=z.nodeName&&z.nodeName.toLowerCase(),H==="select"||H==="input"&&z.type==="file")var te=tp;else if(Wd(z))if(np)te=i1;else{te=t1;var pe=e1}else H=z.nodeName,!H||H.toLowerCase()!=="input"||z.type!=="checkbox"&&z.type!=="radio"?D&&zc(D.elementType)&&(te=tp):te=n1;if(te&&(te=te(t,D))){ep(P,te,l,K);break e}pe&&pe(t,z,D),t==="focusout"&&D&&z.type==="number"&&D.memoizedProps.value!=null&&Uc(z,"number",z.value)}switch(pe=D?Or(D):window,t){case"focusin":(Wd(pe)||pe.contentEditable==="true")&&(Ss=pe,Jc=D,qr=null);break;case"focusout":qr=Jc=Ss=null;break;case"mousedown":Wc=!0;break;case"contextmenu":case"mouseup":case"dragend":Wc=!1,up(P,l,K);break;case"selectionchange":if(r1)break;case"keydown":case"keyup":up(P,l,K)}var ie;if(Pc)e:{switch(t){case"compositionstart":var oe="onCompositionStart";break e;case"compositionend":oe="onCompositionEnd";break e;case"compositionupdate":oe="onCompositionUpdate";break e}oe=void 0}else vs?Zd(t,l)&&(oe="onCompositionEnd"):t==="keydown"&&l.keyCode===229&&(oe="onCompositionStart");oe&&(Pd&&l.locale!=="ko"&&(vs||oe!=="onCompositionStart"?oe==="onCompositionEnd"&&vs&&(ie=Vd()):(Qn=K,Vc="value"in Qn?Qn.value:Qn.textContent,vs=!0)),pe=io(D,oe),0<pe.length&&(oe=new Yd(oe,t,null,l,K),P.push({event:oe,listeners:pe}),ie?oe.data=ie:(ie=Jd(l),ie!==null&&(oe.data=ie)))),(ie=FS?QS(t,l):ZS(t,l))&&(oe=io(D,"onBeforeInput"),0<oe.length&&(pe=new Yd("onBeforeInput","beforeinput",null,l,K),P.push({event:pe,listeners:oe}),pe.data=ie)),$1(P,t,D,l,K)}Lm(P,r)})}function pa(t,r,l){return{instance:t,listener:r,currentTarget:l}}function io(t,r){for(var l=r+"Capture",c=[];t!==null;){var h=t,g=h.stateNode;if(h=h.tag,h!==5&&h!==26&&h!==27||g===null||(h=Rr(t,l),h!=null&&c.unshift(pa(t,h,g)),h=Rr(t,r),h!=null&&c.push(pa(t,h,g))),t.tag===3)return c;t=t.return}return[]}function Gs(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function Bm(t,r,l,c,h){for(var g=r._reactName,S=[];l!==null&&l!==c;){var T=l,A=T.alternate,D=T.stateNode;if(T=T.tag,A!==null&&A===c)break;T!==5&&T!==26&&T!==27||D===null||(A=D,h?(D=Rr(l,g),D!=null&&S.unshift(pa(l,D,A))):h||(D=Rr(l,g),D!=null&&S.push(pa(l,D,A)))),l=l.return}S.length!==0&&t.push({event:r,listeners:S})}var K1=/\r\n?/g,Y1=/\u0000|\uFFFD/g;function Um(t){return(typeof t=="string"?t:""+t).replace(K1,`
|
|
50
|
+
`).replace(Y1,"")}function zm(t,r){return r=Um(r),Um(t)===r}function so(){}function ke(t,r,l,c,h,g){switch(l){case"children":typeof c=="string"?r==="body"||r==="textarea"&&c===""||ms(t,c):(typeof c=="number"||typeof c=="bigint")&&r!=="body"&&ms(t,""+c);break;case"className":cl(t,"class",c);break;case"tabIndex":cl(t,"tabindex",c);break;case"dir":case"role":case"viewBox":case"width":case"height":cl(t,l,c);break;case"style":qd(t,c,g);break;case"data":if(r!=="object"){cl(t,"data",c);break}case"src":case"href":if(c===""&&(r!=="a"||l!=="href")){t.removeAttribute(l);break}if(c==null||typeof c=="function"||typeof c=="symbol"||typeof c=="boolean"){t.removeAttribute(l);break}c=hl(""+c),t.setAttribute(l,c);break;case"action":case"formAction":if(typeof c=="function"){t.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof g=="function"&&(l==="formAction"?(r!=="input"&&ke(t,r,"name",h.name,h,null),ke(t,r,"formEncType",h.formEncType,h,null),ke(t,r,"formMethod",h.formMethod,h,null),ke(t,r,"formTarget",h.formTarget,h,null)):(ke(t,r,"encType",h.encType,h,null),ke(t,r,"method",h.method,h,null),ke(t,r,"target",h.target,h,null)));if(c==null||typeof c=="symbol"||typeof c=="boolean"){t.removeAttribute(l);break}c=hl(""+c),t.setAttribute(l,c);break;case"onClick":c!=null&&(t.onclick=so);break;case"onScroll":c!=null&&be("scroll",t);break;case"onScrollEnd":c!=null&&be("scrollend",t);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(s(61));if(l=c.__html,l!=null){if(h.children!=null)throw Error(s(60));t.innerHTML=l}}break;case"multiple":t.multiple=c&&typeof c!="function"&&typeof c!="symbol";break;case"muted":t.muted=c&&typeof c!="function"&&typeof c!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(c==null||typeof c=="function"||typeof c=="boolean"||typeof c=="symbol"){t.removeAttribute("xlink:href");break}l=hl(""+c),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":c!=null&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(l,""+c):t.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":c&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(l,""):t.removeAttribute(l);break;case"capture":case"download":c===!0?t.setAttribute(l,""):c!==!1&&c!=null&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(l,c):t.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":c!=null&&typeof c!="function"&&typeof c!="symbol"&&!isNaN(c)&&1<=c?t.setAttribute(l,c):t.removeAttribute(l);break;case"rowSpan":case"start":c==null||typeof c=="function"||typeof c=="symbol"||isNaN(c)?t.removeAttribute(l):t.setAttribute(l,c);break;case"popover":be("beforetoggle",t),be("toggle",t),ol(t,"popover",c);break;case"xlinkActuate":En(t,"http://www.w3.org/1999/xlink","xlink:actuate",c);break;case"xlinkArcrole":En(t,"http://www.w3.org/1999/xlink","xlink:arcrole",c);break;case"xlinkRole":En(t,"http://www.w3.org/1999/xlink","xlink:role",c);break;case"xlinkShow":En(t,"http://www.w3.org/1999/xlink","xlink:show",c);break;case"xlinkTitle":En(t,"http://www.w3.org/1999/xlink","xlink:title",c);break;case"xlinkType":En(t,"http://www.w3.org/1999/xlink","xlink:type",c);break;case"xmlBase":En(t,"http://www.w3.org/XML/1998/namespace","xml:base",c);break;case"xmlLang":En(t,"http://www.w3.org/XML/1998/namespace","xml:lang",c);break;case"xmlSpace":En(t,"http://www.w3.org/XML/1998/namespace","xml:space",c);break;case"is":ol(t,"is",c);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=xS.get(l)||l,ol(t,l,c))}}function _f(t,r,l,c,h,g){switch(l){case"style":qd(t,c,g);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(s(61));if(l=c.__html,l!=null){if(h.children!=null)throw Error(s(60));t.innerHTML=l}}break;case"children":typeof c=="string"?ms(t,c):(typeof c=="number"||typeof c=="bigint")&&ms(t,""+c);break;case"onScroll":c!=null&&be("scroll",t);break;case"onScrollEnd":c!=null&&be("scrollend",t);break;case"onClick":c!=null&&(t.onclick=so);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!kd.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(h=l.endsWith("Capture"),r=l.slice(2,h?l.length-7:void 0),g=t[Nt]||null,g=g!=null?g[l]:null,typeof g=="function"&&t.removeEventListener(r,g,h),typeof c=="function")){typeof g!="function"&&g!==null&&(l in t?t[l]=null:t.hasAttribute(l)&&t.removeAttribute(l)),t.addEventListener(r,c,h);break e}l in t?t[l]=c:c===!0?t.setAttribute(l,""):ol(t,l,c)}}}function ot(t,r,l){switch(r){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":be("error",t),be("load",t);var c=!1,h=!1,g;for(g in l)if(l.hasOwnProperty(g)){var S=l[g];if(S!=null)switch(g){case"src":c=!0;break;case"srcSet":h=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(s(137,r));default:ke(t,r,g,S,l,null)}}h&&ke(t,r,"srcSet",l.srcSet,l,null),c&&ke(t,r,"src",l.src,l,null);return;case"input":be("invalid",t);var T=g=S=h=null,A=null,D=null;for(c in l)if(l.hasOwnProperty(c)){var K=l[c];if(K!=null)switch(c){case"name":h=K;break;case"type":S=K;break;case"checked":A=K;break;case"defaultChecked":D=K;break;case"value":g=K;break;case"defaultValue":T=K;break;case"children":case"dangerouslySetInnerHTML":if(K!=null)throw Error(s(137,r));break;default:ke(t,r,c,K,l,null)}}Bd(t,g,T,A,D,S,h,!1),ul(t);return;case"select":be("invalid",t),c=S=g=null;for(h in l)if(l.hasOwnProperty(h)&&(T=l[h],T!=null))switch(h){case"value":g=T;break;case"defaultValue":S=T;break;case"multiple":c=T;default:ke(t,r,h,T,l,null)}r=g,l=S,t.multiple=!!c,r!=null?gs(t,!!c,r,!1):l!=null&&gs(t,!!c,l,!0);return;case"textarea":be("invalid",t),g=h=c=null;for(S in l)if(l.hasOwnProperty(S)&&(T=l[S],T!=null))switch(S){case"value":c=T;break;case"defaultValue":h=T;break;case"children":g=T;break;case"dangerouslySetInnerHTML":if(T!=null)throw Error(s(91));break;default:ke(t,r,S,T,l,null)}zd(t,c,h,g),ul(t);return;case"option":for(A in l)if(l.hasOwnProperty(A)&&(c=l[A],c!=null))switch(A){case"selected":t.selected=c&&typeof c!="function"&&typeof c!="symbol";break;default:ke(t,r,A,c,l,null)}return;case"dialog":be("beforetoggle",t),be("toggle",t),be("cancel",t),be("close",t);break;case"iframe":case"object":be("load",t);break;case"video":case"audio":for(c=0;c<da.length;c++)be(da[c],t);break;case"image":be("error",t),be("load",t);break;case"details":be("toggle",t);break;case"embed":case"source":case"link":be("error",t),be("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(D in l)if(l.hasOwnProperty(D)&&(c=l[D],c!=null))switch(D){case"children":case"dangerouslySetInnerHTML":throw Error(s(137,r));default:ke(t,r,D,c,l,null)}return;default:if(zc(r)){for(K in l)l.hasOwnProperty(K)&&(c=l[K],c!==void 0&&_f(t,r,K,c,l,void 0));return}}for(T in l)l.hasOwnProperty(T)&&(c=l[T],c!=null&&ke(t,r,T,c,l,null))}function X1(t,r,l,c){switch(r){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var h=null,g=null,S=null,T=null,A=null,D=null,K=null;for(H in l){var P=l[H];if(l.hasOwnProperty(H)&&P!=null)switch(H){case"checked":break;case"value":break;case"defaultValue":A=P;default:c.hasOwnProperty(H)||ke(t,r,H,null,c,P)}}for(var z in c){var H=c[z];if(P=l[z],c.hasOwnProperty(z)&&(H!=null||P!=null))switch(z){case"type":g=H;break;case"name":h=H;break;case"checked":D=H;break;case"defaultChecked":K=H;break;case"value":S=H;break;case"defaultValue":T=H;break;case"children":case"dangerouslySetInnerHTML":if(H!=null)throw Error(s(137,r));break;default:H!==P&&ke(t,r,z,H,c,P)}}Bc(t,S,T,A,D,K,g,h);return;case"select":H=S=T=z=null;for(g in l)if(A=l[g],l.hasOwnProperty(g)&&A!=null)switch(g){case"value":break;case"multiple":H=A;default:c.hasOwnProperty(g)||ke(t,r,g,null,c,A)}for(h in c)if(g=c[h],A=l[h],c.hasOwnProperty(h)&&(g!=null||A!=null))switch(h){case"value":z=g;break;case"defaultValue":T=g;break;case"multiple":S=g;default:g!==A&&ke(t,r,h,g,c,A)}r=T,l=S,c=H,z!=null?gs(t,!!l,z,!1):!!c!=!!l&&(r!=null?gs(t,!!l,r,!0):gs(t,!!l,l?[]:"",!1));return;case"textarea":H=z=null;for(T in l)if(h=l[T],l.hasOwnProperty(T)&&h!=null&&!c.hasOwnProperty(T))switch(T){case"value":break;case"children":break;default:ke(t,r,T,null,c,h)}for(S in c)if(h=c[S],g=l[S],c.hasOwnProperty(S)&&(h!=null||g!=null))switch(S){case"value":z=h;break;case"defaultValue":H=h;break;case"children":break;case"dangerouslySetInnerHTML":if(h!=null)throw Error(s(91));break;default:h!==g&&ke(t,r,S,h,c,g)}Ud(t,z,H);return;case"option":for(var ce in l)if(z=l[ce],l.hasOwnProperty(ce)&&z!=null&&!c.hasOwnProperty(ce))switch(ce){case"selected":t.selected=!1;break;default:ke(t,r,ce,null,c,z)}for(A in c)if(z=c[A],H=l[A],c.hasOwnProperty(A)&&z!==H&&(z!=null||H!=null))switch(A){case"selected":t.selected=z&&typeof z!="function"&&typeof z!="symbol";break;default:ke(t,r,A,z,c,H)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var ae in l)z=l[ae],l.hasOwnProperty(ae)&&z!=null&&!c.hasOwnProperty(ae)&&ke(t,r,ae,null,c,z);for(D in c)if(z=c[D],H=l[D],c.hasOwnProperty(D)&&z!==H&&(z!=null||H!=null))switch(D){case"children":case"dangerouslySetInnerHTML":if(z!=null)throw Error(s(137,r));break;default:ke(t,r,D,z,c,H)}return;default:if(zc(r)){for(var Me in l)z=l[Me],l.hasOwnProperty(Me)&&z!==void 0&&!c.hasOwnProperty(Me)&&_f(t,r,Me,void 0,c,z);for(K in c)z=c[K],H=l[K],!c.hasOwnProperty(K)||z===H||z===void 0&&H===void 0||_f(t,r,K,z,c,H);return}}for(var O in l)z=l[O],l.hasOwnProperty(O)&&z!=null&&!c.hasOwnProperty(O)&&ke(t,r,O,null,c,z);for(P in c)z=c[P],H=l[P],!c.hasOwnProperty(P)||z===H||z==null&&H==null||ke(t,r,P,z,c,H)}var Tf=null,Ef=null;function ro(t){return t.nodeType===9?t:t.ownerDocument}function Hm(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function qm(t,r){if(t===0)switch(r){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&r==="foreignObject"?0:t}function Af(t,r){return t==="textarea"||t==="noscript"||typeof r.children=="string"||typeof r.children=="number"||typeof r.children=="bigint"||typeof r.dangerouslySetInnerHTML=="object"&&r.dangerouslySetInnerHTML!==null&&r.dangerouslySetInnerHTML.__html!=null}var Nf=null;function P1(){var t=window.event;return t&&t.type==="popstate"?t===Nf?!1:(Nf=t,!0):(Nf=null,!1)}var $m=typeof setTimeout=="function"?setTimeout:void 0,F1=typeof clearTimeout=="function"?clearTimeout:void 0,Im=typeof Promise=="function"?Promise:void 0,Q1=typeof queueMicrotask=="function"?queueMicrotask:typeof Im<"u"?function(t){return Im.resolve(null).then(t).catch(Z1)}:$m;function Z1(t){setTimeout(function(){throw t})}function hi(t){return t==="head"}function Vm(t,r){var l=r,c=0,h=0;do{var g=l.nextSibling;if(t.removeChild(l),g&&g.nodeType===8)if(l=g.data,l==="/$"){if(0<c&&8>c){l=c;var S=t.ownerDocument;if(l&1&&ga(S.documentElement),l&2&&ga(S.body),l&4)for(l=S.head,ga(l),S=l.firstChild;S;){var T=S.nextSibling,A=S.nodeName;S[Mr]||A==="SCRIPT"||A==="STYLE"||A==="LINK"&&S.rel.toLowerCase()==="stylesheet"||l.removeChild(S),S=T}}if(h===0){t.removeChild(g),_a(r);return}h--}else l==="$"||l==="$?"||l==="$!"?h++:c=l.charCodeAt(0)-48;else c=0;l=g}while(l);_a(r)}function Cf(t){var r=t.firstChild;for(r&&r.nodeType===10&&(r=r.nextSibling);r;){var l=r;switch(r=r.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Cf(l),Rc(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}t.removeChild(l)}}function J1(t,r,l,c){for(;t.nodeType===1;){var h=l;if(t.nodeName.toLowerCase()!==r.toLowerCase()){if(!c&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(c){if(!t[Mr])switch(r){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(g=t.getAttribute("rel"),g==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(g!==h.rel||t.getAttribute("href")!==(h.href==null||h.href===""?null:h.href)||t.getAttribute("crossorigin")!==(h.crossOrigin==null?null:h.crossOrigin)||t.getAttribute("title")!==(h.title==null?null:h.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(g=t.getAttribute("src"),(g!==(h.src==null?null:h.src)||t.getAttribute("type")!==(h.type==null?null:h.type)||t.getAttribute("crossorigin")!==(h.crossOrigin==null?null:h.crossOrigin))&&g&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(r==="input"&&t.type==="hidden"){var g=h.name==null?null:""+h.name;if(h.type==="hidden"&&t.getAttribute("name")===g)return t}else return t;if(t=fn(t.nextSibling),t===null)break}return null}function W1(t,r,l){if(r==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!l||(t=fn(t.nextSibling),t===null))return null;return t}function kf(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState==="complete"}function ew(t,r){var l=t.ownerDocument;if(t.data!=="$?"||l.readyState==="complete")r();else{var c=function(){r(),l.removeEventListener("DOMContentLoaded",c)};l.addEventListener("DOMContentLoaded",c),t._reactRetry=c}}function fn(t){for(;t!=null;t=t.nextSibling){var r=t.nodeType;if(r===1||r===3)break;if(r===8){if(r=t.data,r==="$"||r==="$!"||r==="$?"||r==="F!"||r==="F")break;if(r==="/$")return null}}return t}var Mf=null;function Gm(t){t=t.previousSibling;for(var r=0;t;){if(t.nodeType===8){var l=t.data;if(l==="$"||l==="$!"||l==="$?"){if(r===0)return t;r--}else l==="/$"&&r++}t=t.previousSibling}return null}function Km(t,r,l){switch(r=ro(l),t){case"html":if(t=r.documentElement,!t)throw Error(s(452));return t;case"head":if(t=r.head,!t)throw Error(s(453));return t;case"body":if(t=r.body,!t)throw Error(s(454));return t;default:throw Error(s(451))}}function ga(t){for(var r=t.attributes;r.length;)t.removeAttributeNode(r[0]);Rc(t)}var nn=new Map,Ym=new Set;function ao(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var Hn=Z.d;Z.d={f:tw,r:nw,D:iw,C:sw,L:rw,m:aw,X:ow,S:lw,M:cw};function tw(){var t=Hn.f(),r=Zl();return t||r}function nw(t){var r=fs(t);r!==null&&r.tag===5&&r.type==="form"?hg(r):Hn.r(t)}var Ks=typeof document>"u"?null:document;function Xm(t,r,l){var c=Ks;if(c&&typeof r=="string"&&r){var h=Ft(r);h='link[rel="'+t+'"][href="'+h+'"]',typeof l=="string"&&(h+='[crossorigin="'+l+'"]'),Ym.has(h)||(Ym.add(h),t={rel:t,crossOrigin:l,href:r},c.querySelector(h)===null&&(r=c.createElement("link"),ot(r,"link",t),et(r),c.head.appendChild(r)))}}function iw(t){Hn.D(t),Xm("dns-prefetch",t,null)}function sw(t,r){Hn.C(t,r),Xm("preconnect",t,r)}function rw(t,r,l){Hn.L(t,r,l);var c=Ks;if(c&&t&&r){var h='link[rel="preload"][as="'+Ft(r)+'"]';r==="image"&&l&&l.imageSrcSet?(h+='[imagesrcset="'+Ft(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(h+='[imagesizes="'+Ft(l.imageSizes)+'"]')):h+='[href="'+Ft(t)+'"]';var g=h;switch(r){case"style":g=Ys(t);break;case"script":g=Xs(t)}nn.has(g)||(t=m({rel:"preload",href:r==="image"&&l&&l.imageSrcSet?void 0:t,as:r},l),nn.set(g,t),c.querySelector(h)!==null||r==="style"&&c.querySelector(ma(g))||r==="script"&&c.querySelector(ya(g))||(r=c.createElement("link"),ot(r,"link",t),et(r),c.head.appendChild(r)))}}function aw(t,r){Hn.m(t,r);var l=Ks;if(l&&t){var c=r&&typeof r.as=="string"?r.as:"script",h='link[rel="modulepreload"][as="'+Ft(c)+'"][href="'+Ft(t)+'"]',g=h;switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":g=Xs(t)}if(!nn.has(g)&&(t=m({rel:"modulepreload",href:t},r),nn.set(g,t),l.querySelector(h)===null)){switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(ya(g)))return}c=l.createElement("link"),ot(c,"link",t),et(c),l.head.appendChild(c)}}}function lw(t,r,l){Hn.S(t,r,l);var c=Ks;if(c&&t){var h=hs(c).hoistableStyles,g=Ys(t);r=r||"default";var S=h.get(g);if(!S){var T={loading:0,preload:null};if(S=c.querySelector(ma(g)))T.loading=5;else{t=m({rel:"stylesheet",href:t,"data-precedence":r},l),(l=nn.get(g))&&Of(t,l);var A=S=c.createElement("link");et(A),ot(A,"link",t),A._p=new Promise(function(D,K){A.onload=D,A.onerror=K}),A.addEventListener("load",function(){T.loading|=1}),A.addEventListener("error",function(){T.loading|=2}),T.loading|=4,lo(S,r,c)}S={type:"stylesheet",instance:S,count:1,state:T},h.set(g,S)}}}function ow(t,r){Hn.X(t,r);var l=Ks;if(l&&t){var c=hs(l).hoistableScripts,h=Xs(t),g=c.get(h);g||(g=l.querySelector(ya(h)),g||(t=m({src:t,async:!0},r),(r=nn.get(h))&&Rf(t,r),g=l.createElement("script"),et(g),ot(g,"link",t),l.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},c.set(h,g))}}function cw(t,r){Hn.M(t,r);var l=Ks;if(l&&t){var c=hs(l).hoistableScripts,h=Xs(t),g=c.get(h);g||(g=l.querySelector(ya(h)),g||(t=m({src:t,async:!0,type:"module"},r),(r=nn.get(h))&&Rf(t,r),g=l.createElement("script"),et(g),ot(g,"link",t),l.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},c.set(h,g))}}function Pm(t,r,l,c){var h=(h=ue.current)?ao(h):null;if(!h)throw Error(s(446));switch(t){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(r=Ys(l.href),l=hs(h).hoistableStyles,c=l.get(r),c||(c={type:"style",instance:null,count:0,state:null},l.set(r,c)),c):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){t=Ys(l.href);var g=hs(h).hoistableStyles,S=g.get(t);if(S||(h=h.ownerDocument||h,S={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},g.set(t,S),(g=h.querySelector(ma(t)))&&!g._p&&(S.instance=g,S.state.loading=5),nn.has(t)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},nn.set(t,l),g||uw(h,t,l,S.state))),r&&c===null)throw Error(s(528,""));return S}if(r&&c!==null)throw Error(s(529,""));return null;case"script":return r=l.async,l=l.src,typeof l=="string"&&r&&typeof r!="function"&&typeof r!="symbol"?(r=Xs(l),l=hs(h).hoistableScripts,c=l.get(r),c||(c={type:"script",instance:null,count:0,state:null},l.set(r,c)),c):{type:"void",instance:null,count:0,state:null};default:throw Error(s(444,t))}}function Ys(t){return'href="'+Ft(t)+'"'}function ma(t){return'link[rel="stylesheet"]['+t+"]"}function Fm(t){return m({},t,{"data-precedence":t.precedence,precedence:null})}function uw(t,r,l,c){t.querySelector('link[rel="preload"][as="style"]['+r+"]")?c.loading=1:(r=t.createElement("link"),c.preload=r,r.addEventListener("load",function(){return c.loading|=1}),r.addEventListener("error",function(){return c.loading|=2}),ot(r,"link",l),et(r),t.head.appendChild(r))}function Xs(t){return'[src="'+Ft(t)+'"]'}function ya(t){return"script[async]"+t}function Qm(t,r,l){if(r.count++,r.instance===null)switch(r.type){case"style":var c=t.querySelector('style[data-href~="'+Ft(l.href)+'"]');if(c)return r.instance=c,et(c),c;var h=m({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return c=(t.ownerDocument||t).createElement("style"),et(c),ot(c,"style",h),lo(c,l.precedence,t),r.instance=c;case"stylesheet":h=Ys(l.href);var g=t.querySelector(ma(h));if(g)return r.state.loading|=4,r.instance=g,et(g),g;c=Fm(l),(h=nn.get(h))&&Of(c,h),g=(t.ownerDocument||t).createElement("link"),et(g);var S=g;return S._p=new Promise(function(T,A){S.onload=T,S.onerror=A}),ot(g,"link",c),r.state.loading|=4,lo(g,l.precedence,t),r.instance=g;case"script":return g=Xs(l.src),(h=t.querySelector(ya(g)))?(r.instance=h,et(h),h):(c=l,(h=nn.get(g))&&(c=m({},l),Rf(c,h)),t=t.ownerDocument||t,h=t.createElement("script"),et(h),ot(h,"link",c),t.head.appendChild(h),r.instance=h);case"void":return null;default:throw Error(s(443,r.type))}else r.type==="stylesheet"&&(r.state.loading&4)===0&&(c=r.instance,r.state.loading|=4,lo(c,l.precedence,t));return r.instance}function lo(t,r,l){for(var c=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),h=c.length?c[c.length-1]:null,g=h,S=0;S<c.length;S++){var T=c[S];if(T.dataset.precedence===r)g=T;else if(g!==h)break}g?g.parentNode.insertBefore(t,g.nextSibling):(r=l.nodeType===9?l.head:l,r.insertBefore(t,r.firstChild))}function Of(t,r){t.crossOrigin==null&&(t.crossOrigin=r.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=r.referrerPolicy),t.title==null&&(t.title=r.title)}function Rf(t,r){t.crossOrigin==null&&(t.crossOrigin=r.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=r.referrerPolicy),t.integrity==null&&(t.integrity=r.integrity)}var oo=null;function Zm(t,r,l){if(oo===null){var c=new Map,h=oo=new Map;h.set(l,c)}else h=oo,c=h.get(l),c||(c=new Map,h.set(l,c));if(c.has(t))return c;for(c.set(t,null),l=l.getElementsByTagName(t),h=0;h<l.length;h++){var g=l[h];if(!(g[Mr]||g[pt]||t==="link"&&g.getAttribute("rel")==="stylesheet")&&g.namespaceURI!=="http://www.w3.org/2000/svg"){var S=g.getAttribute(r)||"";S=t+S;var T=c.get(S);T?T.push(g):c.set(S,[g])}}return c}function Jm(t,r,l){t=t.ownerDocument||t,t.head.insertBefore(l,r==="title"?t.querySelector("head > title"):null)}function fw(t,r,l){if(l===1||r.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof r.precedence!="string"||typeof r.href!="string"||r.href==="")break;return!0;case"link":if(typeof r.rel!="string"||typeof r.href!="string"||r.href===""||r.onLoad||r.onError)break;switch(r.rel){case"stylesheet":return t=r.disabled,typeof r.precedence=="string"&&t==null;default:return!0}case"script":if(r.async&&typeof r.async!="function"&&typeof r.async!="symbol"&&!r.onLoad&&!r.onError&&r.src&&typeof r.src=="string")return!0}return!1}function Wm(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}var ba=null;function hw(){}function dw(t,r,l){if(ba===null)throw Error(s(475));var c=ba;if(r.type==="stylesheet"&&(typeof l.media!="string"||matchMedia(l.media).matches!==!1)&&(r.state.loading&4)===0){if(r.instance===null){var h=Ys(l.href),g=t.querySelector(ma(h));if(g){t=g._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(c.count++,c=co.bind(c),t.then(c,c)),r.state.loading|=4,r.instance=g,et(g);return}g=t.ownerDocument||t,l=Fm(l),(h=nn.get(h))&&Of(l,h),g=g.createElement("link"),et(g);var S=g;S._p=new Promise(function(T,A){S.onload=T,S.onerror=A}),ot(g,"link",l),r.instance=g}c.stylesheets===null&&(c.stylesheets=new Map),c.stylesheets.set(r,t),(t=r.state.preload)&&(r.state.loading&3)===0&&(c.count++,r=co.bind(c),t.addEventListener("load",r),t.addEventListener("error",r))}}function pw(){if(ba===null)throw Error(s(475));var t=ba;return t.stylesheets&&t.count===0&&jf(t,t.stylesheets),0<t.count?function(r){var l=setTimeout(function(){if(t.stylesheets&&jf(t,t.stylesheets),t.unsuspend){var c=t.unsuspend;t.unsuspend=null,c()}},6e4);return t.unsuspend=r,function(){t.unsuspend=null,clearTimeout(l)}}:null}function co(){if(this.count--,this.count===0){if(this.stylesheets)jf(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var uo=null;function jf(t,r){t.stylesheets=null,t.unsuspend!==null&&(t.count++,uo=new Map,r.forEach(gw,t),uo=null,co.call(t))}function gw(t,r){if(!(r.state.loading&4)){var l=uo.get(t);if(l)var c=l.get(null);else{l=new Map,uo.set(t,l);for(var h=t.querySelectorAll("link[data-precedence],style[data-precedence]"),g=0;g<h.length;g++){var S=h[g];(S.nodeName==="LINK"||S.getAttribute("media")!=="not all")&&(l.set(S.dataset.precedence,S),c=S)}c&&l.set(null,c)}h=r.instance,S=h.getAttribute("data-precedence"),g=l.get(S)||c,g===c&&l.set(null,h),l.set(S,h),this.count++,c=co.bind(this),h.addEventListener("load",c),h.addEventListener("error",c),g?g.parentNode.insertBefore(h,g.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(h,t.firstChild)),r.state.loading|=4}}var va={$$typeof:V,Provider:null,Consumer:null,_currentValue:ne,_currentValue2:ne,_threadCount:0};function mw(t,r,l,c,h,g,S,T){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Cc(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Cc(0),this.hiddenUpdates=Cc(null),this.identifierPrefix=c,this.onUncaughtError=h,this.onCaughtError=g,this.onRecoverableError=S,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=T,this.incompleteTransitions=new Map}function ey(t,r,l,c,h,g,S,T,A,D,K,P){return t=new mw(t,r,l,S,T,A,D,P),r=1,g===!0&&(r|=24),g=$t(3,null,null,r),t.current=g,g.stateNode=t,r=du(),r.refCount++,t.pooledCache=r,r.refCount++,g.memoizedState={element:c,isDehydrated:l,cache:r},yu(g),t}function ty(t){return t?(t=Ts,t):Ts}function ny(t,r,l,c,h,g){h=ty(h),c.context===null?c.context=h:c.pendingContext=h,c=Wn(r),c.payload={element:l},g=g===void 0?null:g,g!==null&&(c.callback=g),l=ei(t,c,r),l!==null&&(Yt(l,t,r),Fr(l,t,r))}function iy(t,r){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var l=t.retryLane;t.retryLane=l!==0&&l<r?l:r}}function Lf(t,r){iy(t,r),(t=t.alternate)&&iy(t,r)}function sy(t){if(t.tag===13){var r=_s(t,67108864);r!==null&&Yt(r,t,67108864),Lf(t,67108864)}}var fo=!0;function yw(t,r,l,c){var h=q.T;q.T=null;var g=Z.p;try{Z.p=2,Df(t,r,l,c)}finally{Z.p=g,q.T=h}}function bw(t,r,l,c){var h=q.T;q.T=null;var g=Z.p;try{Z.p=8,Df(t,r,l,c)}finally{Z.p=g,q.T=h}}function Df(t,r,l,c){if(fo){var h=Bf(c);if(h===null)xf(t,r,c,ho,l),ay(t,c);else if(Sw(h,t,r,l,c))c.stopPropagation();else if(ay(t,c),r&4&&-1<vw.indexOf(t)){for(;h!==null;){var g=fs(h);if(g!==null)switch(g.tag){case 3:if(g=g.stateNode,g.current.memoizedState.isDehydrated){var S=dt(g.pendingLanes);if(S!==0){var T=g;for(T.pendingLanes|=2,T.entangledLanes|=2;S;){var A=1<<31-rt(S);T.entanglements[1]|=A,S&=~A}Sn(g),(Ee&6)===0&&(Fl=Ht()+500,ha(0))}}break;case 13:T=_s(g,2),T!==null&&Yt(T,g,2),Zl(),Lf(g,2)}if(g=Bf(c),g===null&&xf(t,r,c,ho,l),g===h)break;h=g}h!==null&&c.stopPropagation()}else xf(t,r,c,null,l)}}function Bf(t){return t=qc(t),Uf(t)}var ho=null;function Uf(t){if(ho=null,t=us(t),t!==null){var r=o(t);if(r===null)t=null;else{var l=r.tag;if(l===13){if(t=u(r),t!==null)return t;t=null}else if(l===3){if(r.stateNode.current.memoizedState.isDehydrated)return r.tag===3?r.stateNode.containerInfo:null;t=null}else r!==t&&(t=null)}}return ho=t,null}function ry(t){switch(t){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Pn()){case al:return 2;case ll:return 8;case ls:case Tc:return 32;case Ar:return 268435456;default:return 32}default:return 32}}var zf=!1,di=null,pi=null,gi=null,Sa=new Map,wa=new Map,mi=[],vw="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function ay(t,r){switch(t){case"focusin":case"focusout":di=null;break;case"dragenter":case"dragleave":pi=null;break;case"mouseover":case"mouseout":gi=null;break;case"pointerover":case"pointerout":Sa.delete(r.pointerId);break;case"gotpointercapture":case"lostpointercapture":wa.delete(r.pointerId)}}function xa(t,r,l,c,h,g){return t===null||t.nativeEvent!==g?(t={blockedOn:r,domEventName:l,eventSystemFlags:c,nativeEvent:g,targetContainers:[h]},r!==null&&(r=fs(r),r!==null&&sy(r)),t):(t.eventSystemFlags|=c,r=t.targetContainers,h!==null&&r.indexOf(h)===-1&&r.push(h),t)}function Sw(t,r,l,c,h){switch(r){case"focusin":return di=xa(di,t,r,l,c,h),!0;case"dragenter":return pi=xa(pi,t,r,l,c,h),!0;case"mouseover":return gi=xa(gi,t,r,l,c,h),!0;case"pointerover":var g=h.pointerId;return Sa.set(g,xa(Sa.get(g)||null,t,r,l,c,h)),!0;case"gotpointercapture":return g=h.pointerId,wa.set(g,xa(wa.get(g)||null,t,r,l,c,h)),!0}return!1}function ly(t){var r=us(t.target);if(r!==null){var l=o(r);if(l!==null){if(r=l.tag,r===13){if(r=u(l),r!==null){t.blockedOn=r,dS(t.priority,function(){if(l.tag===13){var c=Kt();c=kc(c);var h=_s(l,c);h!==null&&Yt(h,l,c),Lf(l,c)}});return}}else if(r===3&&l.stateNode.current.memoizedState.isDehydrated){t.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}t.blockedOn=null}function po(t){if(t.blockedOn!==null)return!1;for(var r=t.targetContainers;0<r.length;){var l=Bf(t.nativeEvent);if(l===null){l=t.nativeEvent;var c=new l.constructor(l.type,l);Hc=c,l.target.dispatchEvent(c),Hc=null}else return r=fs(l),r!==null&&sy(r),t.blockedOn=l,!1;r.shift()}return!0}function oy(t,r,l){po(t)&&l.delete(r)}function ww(){zf=!1,di!==null&&po(di)&&(di=null),pi!==null&&po(pi)&&(pi=null),gi!==null&&po(gi)&&(gi=null),Sa.forEach(oy),wa.forEach(oy)}function go(t,r){t.blockedOn===r&&(t.blockedOn=null,zf||(zf=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,ww)))}var mo=null;function cy(t){mo!==t&&(mo=t,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){mo===t&&(mo=null);for(var r=0;r<t.length;r+=3){var l=t[r],c=t[r+1],h=t[r+2];if(typeof c!="function"){if(Uf(c||l)===null)continue;break}var g=fs(l);g!==null&&(t.splice(r,3),r-=3,Bu(g,{pending:!0,data:h,method:l.method,action:c},c,h))}}))}function _a(t){function r(A){return go(A,t)}di!==null&&go(di,t),pi!==null&&go(pi,t),gi!==null&&go(gi,t),Sa.forEach(r),wa.forEach(r);for(var l=0;l<mi.length;l++){var c=mi[l];c.blockedOn===t&&(c.blockedOn=null)}for(;0<mi.length&&(l=mi[0],l.blockedOn===null);)ly(l),l.blockedOn===null&&mi.shift();if(l=(t.ownerDocument||t).$$reactFormReplay,l!=null)for(c=0;c<l.length;c+=3){var h=l[c],g=l[c+1],S=h[Nt]||null;if(typeof g=="function")S||cy(l);else if(S){var T=null;if(g&&g.hasAttribute("formAction")){if(h=g,S=g[Nt]||null)T=S.formAction;else if(Uf(h)!==null)continue}else T=S.action;typeof T=="function"?l[c+1]=T:(l.splice(c,3),c-=3),cy(l)}}}function Hf(t){this._internalRoot=t}yo.prototype.render=Hf.prototype.render=function(t){var r=this._internalRoot;if(r===null)throw Error(s(409));var l=r.current,c=Kt();ny(l,c,t,r,null,null)},yo.prototype.unmount=Hf.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var r=t.containerInfo;ny(t.current,2,null,t,null,null),Zl(),r[cs]=null}};function yo(t){this._internalRoot=t}yo.prototype.unstable_scheduleHydration=function(t){if(t){var r=Ad();t={blockedOn:null,target:t,priority:r};for(var l=0;l<mi.length&&r!==0&&r<mi[l].priority;l++);mi.splice(l,0,t),l===0&&ly(t)}};var uy=e.version;if(uy!=="19.1.1")throw Error(s(527,uy,"19.1.1"));Z.findDOMNode=function(t){var r=t._reactInternals;if(r===void 0)throw typeof t.render=="function"?Error(s(188)):(t=Object.keys(t).join(","),Error(s(268,t)));return t=d(r),t=t!==null?p(t):null,t=t===null?null:t.stateNode,t};var xw={bundleType:0,version:"19.1.1",rendererPackageName:"react-dom",currentDispatcherRef:q,reconcilerVersion:"19.1.1"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var bo=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!bo.isDisabled&&bo.supportsFiber)try{Ti=bo.inject(xw),vt=bo}catch{}}return Ea.createRoot=function(t,r){if(!a(t))throw Error(s(299));var l=!1,c="",h=Ag,g=Ng,S=Cg,T=null;return r!=null&&(r.unstable_strictMode===!0&&(l=!0),r.identifierPrefix!==void 0&&(c=r.identifierPrefix),r.onUncaughtError!==void 0&&(h=r.onUncaughtError),r.onCaughtError!==void 0&&(g=r.onCaughtError),r.onRecoverableError!==void 0&&(S=r.onRecoverableError),r.unstable_transitionCallbacks!==void 0&&(T=r.unstable_transitionCallbacks)),r=ey(t,1,!1,null,null,l,c,h,g,S,T,null),t[cs]=r.current,wf(t),new Hf(r)},Ea.hydrateRoot=function(t,r,l){if(!a(t))throw Error(s(299));var c=!1,h="",g=Ag,S=Ng,T=Cg,A=null,D=null;return l!=null&&(l.unstable_strictMode===!0&&(c=!0),l.identifierPrefix!==void 0&&(h=l.identifierPrefix),l.onUncaughtError!==void 0&&(g=l.onUncaughtError),l.onCaughtError!==void 0&&(S=l.onCaughtError),l.onRecoverableError!==void 0&&(T=l.onRecoverableError),l.unstable_transitionCallbacks!==void 0&&(A=l.unstable_transitionCallbacks),l.formState!==void 0&&(D=l.formState)),r=ey(t,1,!0,r,l??null,c,h,g,S,T,A,D),r.context=ty(null),l=r.current,c=Kt(),c=kc(c),h=Wn(c),h.callback=null,ei(l,h,c),l=c,r.current.lanes=l,kr(r,l),Sn(r),t[cs]=r.current,wf(t),new yo(r)},Ea.version="19.1.1",Ea}var xy;function qw(){if(xy)return If.exports;xy=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}return n(),If.exports=Hw(),If.exports}var YN=qw();const x0=new Map([["APIRequestContext.fetch",{title:'{method} "{url}"'}],["APIRequestContext.fetchResponseBody",{title:"Get response body",group:"getter"}],["APIRequestContext.fetchLog",{internal:!0}],["APIRequestContext.storageState",{title:"Get storage state"}],["APIRequestContext.disposeAPIResponse",{internal:!0}],["APIRequestContext.dispose",{internal:!0}],["LocalUtils.zip",{internal:!0}],["LocalUtils.harOpen",{internal:!0}],["LocalUtils.harLookup",{internal:!0}],["LocalUtils.harClose",{internal:!0}],["LocalUtils.harUnzip",{internal:!0}],["LocalUtils.connect",{internal:!0}],["LocalUtils.tracingStarted",{internal:!0}],["LocalUtils.addStackToTracingNoReply",{internal:!0}],["LocalUtils.traceDiscarded",{internal:!0}],["LocalUtils.globToRegex",{internal:!0}],["Root.initialize",{internal:!0}],["Playwright.newRequest",{title:"Create request context"}],["DebugController.initialize",{internal:!0}],["DebugController.setReportStateChanged",{internal:!0}],["DebugController.setRecorderMode",{internal:!0}],["DebugController.highlight",{internal:!0}],["DebugController.hideHighlight",{internal:!0}],["DebugController.resume",{internal:!0}],["DebugController.kill",{internal:!0}],["SocksSupport.socksConnected",{internal:!0}],["SocksSupport.socksFailed",{internal:!0}],["SocksSupport.socksData",{internal:!0}],["SocksSupport.socksError",{internal:!0}],["SocksSupport.socksEnd",{internal:!0}],["BrowserType.launch",{title:"Launch browser"}],["BrowserType.launchPersistentContext",{title:"Launch persistent context"}],["BrowserType.connectOverCDP",{title:"Connect over CDP"}],["Browser.close",{title:"Close browser",pausesBeforeAction:!0}],["Browser.killForTests",{internal:!0}],["Browser.defaultUserAgentForTest",{internal:!0}],["Browser.newContext",{title:"Create context"}],["Browser.newContextForReuse",{internal:!0}],["Browser.disconnectFromReusedContext",{internal:!0}],["Browser.newBrowserCDPSession",{title:"Create CDP session",group:"configuration"}],["Browser.startTracing",{title:"Start browser tracing",group:"configuration"}],["Browser.stopTracing",{title:"Stop browser tracing",group:"configuration"}],["EventTarget.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["BrowserContext.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["Page.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["WebSocket.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["ElectronApplication.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["AndroidDevice.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["BrowserContext.addCookies",{title:"Add cookies",group:"configuration"}],["BrowserContext.addInitScript",{title:"Add init script",group:"configuration"}],["BrowserContext.clearCookies",{title:"Clear cookies",group:"configuration"}],["BrowserContext.clearPermissions",{title:"Clear permissions",group:"configuration"}],["BrowserContext.close",{title:"Close context",pausesBeforeAction:!0}],["BrowserContext.cookies",{title:"Get cookies",group:"getter"}],["BrowserContext.exposeBinding",{title:"Expose binding",group:"configuration"}],["BrowserContext.grantPermissions",{title:"Grant permissions",group:"configuration"}],["BrowserContext.newPage",{title:"Create page"}],["BrowserContext.registerSelectorEngine",{internal:!0}],["BrowserContext.setTestIdAttributeName",{internal:!0}],["BrowserContext.setExtraHTTPHeaders",{title:"Set extra HTTP headers",group:"configuration"}],["BrowserContext.setGeolocation",{title:"Set geolocation",group:"configuration"}],["BrowserContext.setHTTPCredentials",{title:"Set HTTP credentials",group:"configuration"}],["BrowserContext.setNetworkInterceptionPatterns",{title:"Route requests",group:"route"}],["BrowserContext.setWebSocketInterceptionPatterns",{title:"Route WebSockets",group:"route"}],["BrowserContext.setOffline",{title:"Set offline mode"}],["BrowserContext.storageState",{title:"Get storage state"}],["BrowserContext.pause",{title:"Pause"}],["BrowserContext.enableRecorder",{internal:!0}],["BrowserContext.disableRecorder",{internal:!0}],["BrowserContext.newCDPSession",{title:"Create CDP session",group:"configuration"}],["BrowserContext.harStart",{internal:!0}],["BrowserContext.harExport",{internal:!0}],["BrowserContext.createTempFiles",{internal:!0}],["BrowserContext.updateSubscription",{internal:!0}],["BrowserContext.clockFastForward",{title:'Fast forward clock "{ticksNumber|ticksString}"'}],["BrowserContext.clockInstall",{title:'Install clock "{timeNumber|timeString}"'}],["BrowserContext.clockPauseAt",{title:'Pause clock "{timeNumber|timeString}"'}],["BrowserContext.clockResume",{title:"Resume clock"}],["BrowserContext.clockRunFor",{title:'Run clock "{ticksNumber|ticksString}"'}],["BrowserContext.clockSetFixedTime",{title:'Set fixed time "{timeNumber|timeString}"'}],["BrowserContext.clockSetSystemTime",{title:'Set system time "{timeNumber|timeString}"'}],["Page.addInitScript",{title:"Add init script",group:"configuration"}],["Page.close",{title:"Close page",pausesBeforeAction:!0}],["Page.consoleMessages",{title:"Get console messages",group:"getter"}],["Page.emulateMedia",{title:"Emulate media",snapshot:!0,pausesBeforeAction:!0}],["Page.exposeBinding",{title:"Expose binding",group:"configuration"}],["Page.goBack",{title:"Go back",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.goForward",{title:"Go forward",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.requestGC",{title:"Request garbage collection",group:"configuration"}],["Page.registerLocatorHandler",{title:"Register locator handler"}],["Page.resolveLocatorHandlerNoReply",{internal:!0}],["Page.unregisterLocatorHandler",{title:"Unregister locator handler"}],["Page.reload",{title:"Reload",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.expectScreenshot",{title:"Expect screenshot",snapshot:!0,pausesBeforeAction:!0}],["Page.screenshot",{title:"Screenshot",snapshot:!0,pausesBeforeAction:!0}],["Page.setExtraHTTPHeaders",{title:"Set extra HTTP headers",group:"configuration"}],["Page.setNetworkInterceptionPatterns",{title:"Route requests",group:"route"}],["Page.setWebSocketInterceptionPatterns",{title:"Route WebSockets",group:"route"}],["Page.setViewportSize",{title:"Set viewport size",snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardDown",{title:'Key down "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardUp",{title:'Key up "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardInsertText",{title:'Insert "{text}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardType",{title:'Type "{text}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardPress",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseMove",{title:"Mouse move",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseDown",{title:"Mouse down",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseUp",{title:"Mouse up",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseClick",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseWheel",{title:"Mouse wheel",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.touchscreenTap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.accessibilitySnapshot",{title:"Accessibility snapshot",group:"getter"}],["Page.pageErrors",{title:"Get page errors",group:"getter"}],["Page.pdf",{title:"PDF"}],["Page.requests",{title:"Get network requests",group:"getter"}],["Page.snapshotForAI",{internal:!0}],["Page.startJSCoverage",{title:"Start JS coverage",group:"configuration"}],["Page.stopJSCoverage",{title:"Stop JS coverage",group:"configuration"}],["Page.startCSSCoverage",{title:"Start CSS coverage",group:"configuration"}],["Page.stopCSSCoverage",{title:"Stop CSS coverage",group:"configuration"}],["Page.bringToFront",{title:"Bring to front"}],["Page.updateSubscription",{internal:!0}],["Frame.evalOnSelector",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.evalOnSelectorAll",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.addScriptTag",{title:"Add script tag",snapshot:!0,pausesBeforeAction:!0}],["Frame.addStyleTag",{title:"Add style tag",snapshot:!0,pausesBeforeAction:!0}],["Frame.ariaSnapshot",{title:"Aria snapshot",snapshot:!0,pausesBeforeAction:!0}],["Frame.blur",{title:"Blur",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.check",{title:"Check",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.click",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.content",{title:"Get content",snapshot:!0,pausesBeforeAction:!0}],["Frame.dragAndDrop",{title:"Drag and drop",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.dblclick",{title:"Double click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.dispatchEvent",{title:'Dispatch "{type}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.fill",{title:'Fill "{value}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.focus",{title:"Focus",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.frameElement",{title:"Get frame element",group:"getter"}],["Frame.resolveSelector",{internal:!0}],["Frame.highlight",{title:"Highlight element",group:"configuration"}],["Frame.getAttribute",{title:'Get attribute "{name}"',snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.goto",{title:'Navigate to "{url}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.hover",{title:"Hover",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.innerHTML",{title:"Get HTML",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.innerText",{title:"Get inner text",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.inputValue",{title:"Get input value",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isChecked",{title:"Is checked",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isDisabled",{title:"Is disabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isEnabled",{title:"Is enabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isHidden",{title:"Is hidden",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isVisible",{title:"Is visible",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isEditable",{title:"Is editable",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.press",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.querySelector",{title:"Query selector",snapshot:!0}],["Frame.querySelectorAll",{title:"Query selector all",snapshot:!0}],["Frame.queryCount",{title:"Query count",snapshot:!0,pausesBeforeAction:!0}],["Frame.selectOption",{title:"Select option",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.setContent",{title:"Set content",snapshot:!0,pausesBeforeAction:!0}],["Frame.setInputFiles",{title:"Set input files",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.tap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.textContent",{title:"Get text content",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.title",{title:"Get page title",group:"getter"}],["Frame.type",{title:'Type "{text}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.uncheck",{title:"Uncheck",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.waitForTimeout",{title:"Wait for timeout",snapshot:!0}],["Frame.waitForFunction",{title:"Wait for function",snapshot:!0,pausesBeforeAction:!0}],["Frame.waitForSelector",{title:"Wait for selector",snapshot:!0}],["Frame.expect",{title:'Expect "{expression}"',snapshot:!0,pausesBeforeAction:!0}],["Worker.evaluateExpression",{title:"Evaluate"}],["Worker.evaluateExpressionHandle",{title:"Evaluate"}],["JSHandle.dispose",{internal:!0}],["ElementHandle.dispose",{internal:!0}],["JSHandle.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["JSHandle.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["JSHandle.getPropertyList",{title:"Get property list",group:"getter"}],["ElementHandle.getPropertyList",{title:"Get property list",group:"getter"}],["JSHandle.getProperty",{title:"Get JS property",group:"getter"}],["ElementHandle.getProperty",{title:"Get JS property",group:"getter"}],["JSHandle.jsonValue",{title:"Get JSON value",group:"getter"}],["ElementHandle.jsonValue",{title:"Get JSON value",group:"getter"}],["ElementHandle.evalOnSelector",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evalOnSelectorAll",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.boundingBox",{title:"Get bounding box",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.check",{title:"Check",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.click",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.contentFrame",{title:"Get content frame",group:"getter"}],["ElementHandle.dblclick",{title:"Double click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.dispatchEvent",{title:"Dispatch event",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.fill",{title:'Fill "{value}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.focus",{title:"Focus",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.getAttribute",{title:"Get attribute",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.hover",{title:"Hover",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.innerHTML",{title:"Get HTML",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.innerText",{title:"Get inner text",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.inputValue",{title:"Get input value",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isChecked",{title:"Is checked",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isDisabled",{title:"Is disabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isEditable",{title:"Is editable",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isEnabled",{title:"Is enabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isHidden",{title:"Is hidden",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isVisible",{title:"Is visible",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.ownerFrame",{title:"Get owner frame",group:"getter"}],["ElementHandle.press",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.querySelector",{title:"Query selector",snapshot:!0}],["ElementHandle.querySelectorAll",{title:"Query selector all",snapshot:!0}],["ElementHandle.screenshot",{title:"Screenshot",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.scrollIntoViewIfNeeded",{title:"Scroll into view",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.selectOption",{title:"Select option",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.selectText",{title:"Select text",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.setInputFiles",{title:"Set input files",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.tap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.textContent",{title:"Get text content",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.type",{title:"Type",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.uncheck",{title:"Uncheck",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.waitForElementState",{title:"Wait for state",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.waitForSelector",{title:"Wait for selector",snapshot:!0}],["Request.response",{internal:!0}],["Request.rawRequestHeaders",{internal:!0}],["Route.redirectNavigationRequest",{internal:!0}],["Route.abort",{title:"Abort request",group:"route"}],["Route.continue",{title:"Continue request",group:"route"}],["Route.fulfill",{title:"Fulfill request",group:"route"}],["WebSocketRoute.connect",{title:"Connect WebSocket to server",group:"route"}],["WebSocketRoute.ensureOpened",{internal:!0}],["WebSocketRoute.sendToPage",{title:"Send WebSocket message",group:"route"}],["WebSocketRoute.sendToServer",{title:"Send WebSocket message",group:"route"}],["WebSocketRoute.closePage",{internal:!0}],["WebSocketRoute.closeServer",{internal:!0}],["Response.body",{title:"Get response body",group:"getter"}],["Response.securityDetails",{internal:!0}],["Response.serverAddr",{internal:!0}],["Response.rawResponseHeaders",{internal:!0}],["Response.sizes",{internal:!0}],["BindingCall.reject",{internal:!0}],["BindingCall.resolve",{internal:!0}],["Dialog.accept",{title:"Accept dialog"}],["Dialog.dismiss",{title:"Dismiss dialog"}],["Tracing.tracingStart",{title:"Start tracing",group:"configuration"}],["Tracing.tracingStartChunk",{title:"Start tracing",group:"configuration"}],["Tracing.tracingGroup",{title:'Trace "{name}"'}],["Tracing.tracingGroupEnd",{title:"Group end"}],["Tracing.tracingStopChunk",{title:"Stop tracing",group:"configuration"}],["Tracing.tracingStop",{title:"Stop tracing",group:"configuration"}],["Artifact.pathAfterFinished",{internal:!0}],["Artifact.saveAs",{internal:!0}],["Artifact.saveAsStream",{internal:!0}],["Artifact.failure",{internal:!0}],["Artifact.stream",{internal:!0}],["Artifact.cancel",{internal:!0}],["Artifact.delete",{internal:!0}],["Stream.read",{internal:!0}],["Stream.close",{internal:!0}],["WritableStream.write",{internal:!0}],["WritableStream.close",{internal:!0}],["CDPSession.send",{title:"Send CDP command",group:"configuration"}],["CDPSession.detach",{title:"Detach CDP session",group:"configuration"}],["Electron.launch",{title:"Launch electron"}],["ElectronApplication.browserWindow",{internal:!0}],["ElectronApplication.evaluateExpression",{title:"Evaluate"}],["ElectronApplication.evaluateExpressionHandle",{title:"Evaluate"}],["ElectronApplication.updateSubscription",{internal:!0}],["Android.devices",{internal:!0}],["AndroidSocket.write",{internal:!0}],["AndroidSocket.close",{internal:!0}],["AndroidDevice.wait",{title:"Wait"}],["AndroidDevice.fill",{title:'Fill "{text}"'}],["AndroidDevice.tap",{title:"Tap"}],["AndroidDevice.drag",{title:"Drag"}],["AndroidDevice.fling",{title:"Fling"}],["AndroidDevice.longTap",{title:"Long tap"}],["AndroidDevice.pinchClose",{title:"Pinch close"}],["AndroidDevice.pinchOpen",{title:"Pinch open"}],["AndroidDevice.scroll",{title:"Scroll"}],["AndroidDevice.swipe",{title:"Swipe"}],["AndroidDevice.info",{internal:!0}],["AndroidDevice.screenshot",{title:"Screenshot"}],["AndroidDevice.inputType",{title:"Type"}],["AndroidDevice.inputPress",{title:"Press"}],["AndroidDevice.inputTap",{title:"Tap"}],["AndroidDevice.inputSwipe",{title:"Swipe"}],["AndroidDevice.inputDrag",{title:"Drag"}],["AndroidDevice.launchBrowser",{title:"Launch browser"}],["AndroidDevice.open",{title:"Open app"}],["AndroidDevice.shell",{title:"Execute shell command",group:"configuration"}],["AndroidDevice.installApk",{title:"Install apk"}],["AndroidDevice.push",{title:"Push"}],["AndroidDevice.connectToWebView",{title:"Connect to Web View"}],["AndroidDevice.close",{internal:!0}],["JsonPipe.send",{internal:!0}],["JsonPipe.close",{internal:!0}]]);function $w(n,e){var i;return(i=Iw(n,e))==null?void 0:i.replaceAll(`
|
|
51
|
+
`,"\\n")}function Iw(n,e){if(n)for(const i of e.split("|")){if(i==="url")try{const a=new URL(n[i]);return a.protocol==="data:"?a.protocol:a.protocol==="about:"?n[i]:a.pathname+a.search}catch{if(n[i]!==void 0)return n[i]}if(i==="timeNumber"&&n[i]!==void 0)return new Date(n[i]).toString();const s=Vw(n,i);if(s!==void 0)return s}}function Vw(n,e){const i=e.split(".");let s=n;for(const a of i){if(typeof s!="object"||s===null)return;s=s[a]}if(s!==void 0)return String(s)}function Gw(n){var e;return(e=x0.get(n.type+"."+n.method))==null?void 0:e.group}const La=Symbol("context"),_0=Symbol("nextInContext"),T0=Symbol("prevByEndTime"),E0=Symbol("nextByStartTime"),_y=Symbol("events");class XN{constructor(e,i){Ne(this,"startTime");Ne(this,"endTime");Ne(this,"browserName");Ne(this,"channel");Ne(this,"platform");Ne(this,"wallTime");Ne(this,"title");Ne(this,"options");Ne(this,"pages");Ne(this,"actions");Ne(this,"attachments");Ne(this,"visibleAttachments");Ne(this,"events");Ne(this,"stdio");Ne(this,"errors");Ne(this,"errorDescriptors");Ne(this,"hasSource");Ne(this,"hasStepData");Ne(this,"sdkLanguage");Ne(this,"testIdAttributeName");Ne(this,"sources");Ne(this,"resources");Ne(this,"actionCounters");Ne(this,"traceUrl");i.forEach(a=>Kw(a));const s=i.find(a=>a.origin==="library");this.traceUrl=e,this.browserName=(s==null?void 0:s.browserName)||"",this.sdkLanguage=s==null?void 0:s.sdkLanguage,this.channel=s==null?void 0:s.channel,this.testIdAttributeName=s==null?void 0:s.testIdAttributeName,this.platform=(s==null?void 0:s.platform)||"",this.title=(s==null?void 0:s.title)||"",this.options=(s==null?void 0:s.options)||{},this.actions=Yw(i),this.pages=[].concat(...i.map(a=>a.pages)),this.wallTime=i.map(a=>a.wallTime).reduce((a,o)=>Math.min(a||Number.MAX_VALUE,o),Number.MAX_VALUE),this.startTime=i.map(a=>a.startTime).reduce((a,o)=>Math.min(a,o),Number.MAX_VALUE),this.endTime=i.map(a=>a.endTime).reduce((a,o)=>Math.max(a,o),Number.MIN_VALUE),this.events=[].concat(...i.map(a=>a.events)),this.stdio=[].concat(...i.map(a=>a.stdio)),this.errors=[].concat(...i.map(a=>a.errors)),this.hasSource=i.some(a=>a.hasSource),this.hasStepData=i.some(a=>a.origin==="testRunner"),this.resources=[...i.map(a=>a.resources)].flat(),this.attachments=this.actions.flatMap(a=>{var o;return((o=a.attachments)==null?void 0:o.map(u=>({...u,traceUrl:e})))??[]}),this.visibleAttachments=this.attachments.filter(a=>!a.name.startsWith("_")),this.events.sort((a,o)=>a.time-o.time),this.resources.sort((a,o)=>a._monotonicTime-o._monotonicTime),this.errorDescriptors=this.hasStepData?this._errorDescriptorsFromTestRunner():this._errorDescriptorsFromActions(),this.sources=ex(this.actions,this.errorDescriptors),this.actionCounters=new Map;for(const a of this.actions)a.group=a.group??Gw({type:a.class,method:a.method}),a.group&&this.actionCounters.set(a.group,1+(this.actionCounters.get(a.group)||0))}createRelativeUrl(e){const i=new URL("http://localhost/"+e);return i.searchParams.set("trace",this.traceUrl),i.toString().substring(17)}failedAction(){return this.actions.findLast(e=>e.error)}filteredActions(e){const i=new Set(e);return this.actions.filter(s=>!s.group||i.has(s.group))}_errorDescriptorsFromActions(){var i;const e=[];for(const s of this.actions||[])(i=s.error)!=null&&i.message&&e.push({action:s,stack:s.stack,message:s.error.message});return e}_errorDescriptorsFromTestRunner(){return this.errors.filter(e=>!!e.message).map((e,i)=>({stack:e.stack,message:e.message}))}}function Kw(n){for(const i of n.pages)i[La]=n;for(let i=0;i<n.actions.length;++i){const s=n.actions[i];s[La]=n}let e;for(let i=n.actions.length-1;i>=0;i--){const s=n.actions[i];s[_0]=e,s.class!=="Route"&&(e=s)}for(const i of n.events)i[La]=n;for(const i of n.resources)i[La]=n}function Yw(n){const e=[],i=Xw(n);e.push(...i),e.sort((s,a)=>a.parentId===s.callId?1:s.parentId===a.callId?-1:s.endTime-a.endTime);for(let s=1;s<e.length;++s)e[s][T0]=e[s-1];e.sort((s,a)=>a.parentId===s.callId?-1:s.parentId===a.callId?1:s.startTime-a.startTime);for(let s=0;s+1<e.length;++s)e[s][E0]=e[s+1];return e}let Ty=0;function Xw(n){const e=new Map,i=n.filter(u=>u.origin==="library"),s=n.filter(u=>u.origin==="testRunner");if(!s.length||!i.length)return n.map(u=>u.actions.map(f=>({...f,context:u}))).flat();for(const u of i)for(const f of u.actions)e.set(f.stepId||`tmp-step@${++Ty}`,{...f,context:u});const a=Fw(s,e);a&&Pw(i,a);const o=new Map;for(const u of s)for(const f of u.actions){const d=f.stepId&&e.get(f.stepId);if(d){o.set(f.callId,d.callId),f.error&&(d.error=f.error),f.attachments&&(d.attachments=f.attachments),f.annotations&&(d.annotations=f.annotations),f.parentId&&(d.parentId=o.get(f.parentId)??f.parentId),f.group&&(d.group=f.group),d.startTime=f.startTime,d.endTime=f.endTime;continue}f.parentId&&(f.parentId=o.get(f.parentId)??f.parentId),e.set(f.stepId||`tmp-step@${++Ty}`,{...f,context:u})}return[...e.values()]}function Pw(n,e){for(const i of n){i.startTime+=e,i.endTime+=e;for(const s of i.actions)s.startTime&&(s.startTime+=e),s.endTime&&(s.endTime+=e);for(const s of i.events)s.time+=e;for(const s of i.stdio)s.timestamp+=e;for(const s of i.pages)for(const a of s.screencastFrames)a.timestamp+=e;for(const s of i.resources)s._monotonicTime&&(s._monotonicTime+=e)}}function Fw(n,e){for(const i of n)for(const s of i.actions){if(!s.startTime)continue;const a=s.stepId?e.get(s.stepId):void 0;if(a)return s.startTime-a.startTime}return 0}function Qw(n){const e=new Map;for(const s of n)e.set(s.callId,{id:s.callId,parent:void 0,children:[],action:s});const i={id:"",parent:void 0,children:[]};for(const s of e.values()){const a=s.action.parentId&&e.get(s.action.parentId)||i;a.children.push(s),s.parent=a}return{rootItem:i,itemMap:e}}function A0(n){return n[La]}function Zw(n){return n[_0]}function Ey(n){return n[T0]}function Ay(n){return n[E0]}function Jw(n){let e=0,i=0;for(const s of Ww(n)){if(s.type==="console"){const a=s.messageType;a==="warning"?++i:a==="error"&&++e}s.type==="event"&&s.method==="pageError"&&++e}return{errors:e,warnings:i}}function Ww(n){let e=n[_y];if(e)return e;const i=Zw(n);return e=A0(n).events.filter(s=>s.time>=n.startTime&&(!i||s.time<i.startTime)),n[_y]=e,e}function ex(n,e){var s;const i=new Map;for(const a of n)for(const o of a.stack||[]){let u=i.get(o.file);u||(u={errors:[],content:void 0},i.set(o.file,u))}for(const a of e){const{action:o,stack:u,message:f}=a;!o||!u||(s=i.get(u[0].file))==null||s.errors.push({line:u[0].line||0,message:f})}return i}const tx=50,Vo=({sidebarSize:n,sidebarHidden:e=!1,sidebarIsFirst:i=!1,orientation:s="vertical",minSidebarSize:a=tx,settingName:o,sidebar:u,main:f})=>{const d=Math.max(a,n)*window.devicePixelRatio,[p,m]=xn(o?o+"."+s+":size":void 0,d),[y,b]=xn(o?o+"."+s+":size":void 0,d),[w,E]=U.useState(null),[x,_]=ts();let k;s==="vertical"?(k=y/window.devicePixelRatio,x&&x.height<k&&(k=x.height-10)):(k=p/window.devicePixelRatio,x&&x.width<k&&(k=x.width-10)),document.body.style.userSelect=w?"none":"inherit";let C={};return s==="vertical"?i?C={top:w?0:k-4,bottom:w?0:void 0,height:w?"initial":8}:C={bottom:w?0:k-4,top:w?0:void 0,height:w?"initial":8}:i?C={left:w?0:k-4,right:w?0:void 0,width:w?"initial":8}:C={right:w?0:k-4,left:w?0:void 0,width:w?"initial":8},v.jsxs("div",{className:Ke("split-view",s,i&&"sidebar-first"),ref:_,children:[v.jsx("div",{className:"split-view-main",children:f}),!e&&v.jsx("div",{style:{flexBasis:k},className:"split-view-sidebar",children:u}),!e&&v.jsx("div",{style:C,className:"split-view-resizer",onMouseDown:V=>E({offset:s==="vertical"?V.clientY:V.clientX,size:k}),onMouseUp:()=>E(null),onMouseMove:V=>{if(!V.buttons)E(null);else if(w){const B=(s==="vertical"?V.clientY:V.clientX)-w.offset,G=i?w.size+B:w.size-B,$=V.target.parentElement.getBoundingClientRect(),R=Math.min(Math.max(a,G),(s==="vertical"?$.height:$.width)-a);s==="vertical"?b(R*window.devicePixelRatio):m(R*window.devicePixelRatio)}}})]})},Fe=function(n,e,i){return n>=e&&n<=i};function Rt(n){return Fe(n,48,57)}function Ny(n){return Rt(n)||Fe(n,65,70)||Fe(n,97,102)}function nx(n){return Fe(n,65,90)}function ix(n){return Fe(n,97,122)}function sx(n){return nx(n)||ix(n)}function rx(n){return n>=128}function ko(n){return sx(n)||rx(n)||n===95}function Cy(n){return ko(n)||Rt(n)||n===45}function ax(n){return Fe(n,0,8)||n===11||Fe(n,14,31)||n===127}function Mo(n){return n===10}function qn(n){return Mo(n)||n===9||n===32}const lx=1114111;class Oh extends Error{constructor(e){super(e),this.name="InvalidCharacterError"}}function ox(n){const e=[];for(let i=0;i<n.length;i++){let s=n.charCodeAt(i);if(s===13&&n.charCodeAt(i+1)===10&&(s=10,i++),(s===13||s===12)&&(s=10),s===0&&(s=65533),Fe(s,55296,56319)&&Fe(n.charCodeAt(i+1),56320,57343)){const a=s-55296,o=n.charCodeAt(i+1)-56320;s=Math.pow(2,16)+a*Math.pow(2,10)+o,i++}e.push(s)}return e}function Je(n){if(n<=65535)return String.fromCharCode(n);n-=Math.pow(2,16);const e=Math.floor(n/Math.pow(2,10))+55296,i=n%Math.pow(2,10)+56320;return String.fromCharCode(e)+String.fromCharCode(i)}function N0(n){const e=ox(n);let i=-1;const s=[];let a;const o=function(j){return j>=e.length?-1:e[j]},u=function(j){if(j===void 0&&(j=1),j>3)throw"Spec Error: no more than three codepoints of lookahead.";return o(i+j)},f=function(j){return j===void 0&&(j=1),i+=j,a=o(i),!0},d=function(){return i-=1,!0},p=function(j){return j===void 0&&(j=a),j===-1},m=function(){if(y(),f(),qn(a)){for(;qn(u());)f();return new Go}else{if(a===34)return E();if(a===35)if(Cy(u())||k(u(1),u(2))){const j=new q0("");return V(u(1),u(2),u(3))&&(j.type="id"),j.value=J(),j}else return new ct(a);else return a===36?u()===61?(f(),new hx):new ct(a):a===39?E():a===40?new U0:a===41?new Rh:a===42?u()===61?(f(),new dx):new ct(a):a===43?G()?(d(),b()):new ct(a):a===44?new j0:a===45?G()?(d(),b()):u(1)===45&&u(2)===62?(f(2),new M0):I()?(d(),w()):new ct(a):a===46?G()?(d(),b()):new ct(a):a===58?new O0:a===59?new R0:a===60?u(1)===33&&u(2)===45&&u(3)===45?(f(3),new k0):new ct(a):a===64?V(u(1),u(2),u(3))?new H0(J()):new ct(a):a===91?new B0:a===92?C()?(d(),w()):new ct(a):a===93?new hh:a===94?u()===61?(f(),new fx):new ct(a):a===123?new L0:a===124?u()===61?(f(),new ux):u()===124?(f(),new z0):new ct(a):a===125?new D0:a===126?u()===61?(f(),new cx):new ct(a):Rt(a)?(d(),b()):ko(a)?(d(),w()):p()?new Ro:new ct(a)}},y=function(){for(;u(1)===47&&u(2)===42;)for(f(2);;)if(f(),a===42&&u()===47){f();break}else if(p())return},b=function(){const j=$();if(V(u(1),u(2),u(3))){const F=new px;return F.value=j.value,F.repr=j.repr,F.type=j.type,F.unit=J(),F}else if(u()===37){f();const F=new V0;return F.value=j.value,F.repr=j.repr,F}else{const F=new I0;return F.value=j.value,F.repr=j.repr,F.type=j.type,F}},w=function(){const j=J();if(j.toLowerCase()==="url"&&u()===40){for(f();qn(u(1))&&qn(u(2));)f();return u()===34||u()===39?new qa(j):qn(u())&&(u(2)===34||u(2)===39)?new qa(j):x()}else return u()===40?(f(),new qa(j)):new jh(j)},E=function(j){j===void 0&&(j=a);let F="";for(;f();){if(a===j||p())return new Lh(F);if(Mo(a))return d(),new C0;a===92?p(u())||(Mo(u())?f():F+=Je(_())):F+=Je(a)}throw new Error("Internal error")},x=function(){const j=new $0("");for(;qn(u());)f();if(p(u()))return j;for(;f();){if(a===41||p())return j;if(qn(a)){for(;qn(u());)f();return u()===41||p(u())?(f(),j):(ee(),new Oo)}else{if(a===34||a===39||a===40||ax(a))return ee(),new Oo;if(a===92)if(C())j.value+=Je(_());else return ee(),new Oo;else j.value+=Je(a)}}throw new Error("Internal error")},_=function(){if(f(),Ny(a)){const j=[a];for(let ge=0;ge<5&&Ny(u());ge++)f(),j.push(a);qn(u())&&f();let F=parseInt(j.map(function(ge){return String.fromCharCode(ge)}).join(""),16);return F>lx&&(F=65533),F}else return p()?65533:a},k=function(j,F){return!(j!==92||Mo(F))},C=function(){return k(a,u())},V=function(j,F,ge){return j===45?ko(F)||F===45||k(F,ge):ko(j)?!0:j===92?k(j,F):!1},I=function(){return V(a,u(1),u(2))},B=function(j,F,ge){return j===43||j===45?!!(Rt(F)||F===46&&Rt(ge)):j===46?!!Rt(F):!!Rt(j)},G=function(){return B(a,u(1),u(2))},J=function(){let j="";for(;f();)if(Cy(a))j+=Je(a);else if(C())j+=Je(_());else return d(),j;throw new Error("Internal parse error")},$=function(){let j="",F="integer";for((u()===43||u()===45)&&(f(),j+=Je(a));Rt(u());)f(),j+=Je(a);if(u(1)===46&&Rt(u(2)))for(f(),j+=Je(a),f(),j+=Je(a),F="number";Rt(u());)f(),j+=Je(a);const ge=u(1),me=u(2),q=u(3);if((ge===69||ge===101)&&Rt(me))for(f(),j+=Je(a),f(),j+=Je(a),F="number";Rt(u());)f(),j+=Je(a);else if((ge===69||ge===101)&&(me===43||me===45)&&Rt(q))for(f(),j+=Je(a),f(),j+=Je(a),f(),j+=Je(a),F="number";Rt(u());)f(),j+=Je(a);const Z=R(j);return{type:F,value:Z,repr:j}},R=function(j){return+j},ee=function(){for(;f();){if(a===41||p())return;C()&&_()}};let re=0;for(;!p(u());)if(s.push(m()),re++,re>e.length*2)throw new Error("I'm infinite-looping!");return s}class Ye{constructor(){this.tokenType=""}toJSON(){return{token:this.tokenType}}toString(){return this.tokenType}toSource(){return""+this}}class C0 extends Ye{constructor(){super(...arguments),this.tokenType="BADSTRING"}}class Oo extends Ye{constructor(){super(...arguments),this.tokenType="BADURL"}}class Go extends Ye{constructor(){super(...arguments),this.tokenType="WHITESPACE"}toString(){return"WS"}toSource(){return" "}}class k0 extends Ye{constructor(){super(...arguments),this.tokenType="CDO"}toSource(){return"<!--"}}class M0 extends Ye{constructor(){super(...arguments),this.tokenType="CDC"}toSource(){return"-->"}}class O0 extends Ye{constructor(){super(...arguments),this.tokenType=":"}}class R0 extends Ye{constructor(){super(...arguments),this.tokenType=";"}}class j0 extends Ye{constructor(){super(...arguments),this.tokenType=","}}class dr extends Ye{constructor(){super(...arguments),this.value="",this.mirror=""}}class L0 extends dr{constructor(){super(),this.tokenType="{",this.value="{",this.mirror="}"}}class D0 extends dr{constructor(){super(),this.tokenType="}",this.value="}",this.mirror="{"}}class B0 extends dr{constructor(){super(),this.tokenType="[",this.value="[",this.mirror="]"}}class hh extends dr{constructor(){super(),this.tokenType="]",this.value="]",this.mirror="["}}class U0 extends dr{constructor(){super(),this.tokenType="(",this.value="(",this.mirror=")"}}class Rh extends dr{constructor(){super(),this.tokenType=")",this.value=")",this.mirror="("}}class cx extends Ye{constructor(){super(...arguments),this.tokenType="~="}}class ux extends Ye{constructor(){super(...arguments),this.tokenType="|="}}class fx extends Ye{constructor(){super(...arguments),this.tokenType="^="}}class hx extends Ye{constructor(){super(...arguments),this.tokenType="$="}}class dx extends Ye{constructor(){super(...arguments),this.tokenType="*="}}class z0 extends Ye{constructor(){super(...arguments),this.tokenType="||"}}class Ro extends Ye{constructor(){super(...arguments),this.tokenType="EOF"}toSource(){return""}}class ct extends Ye{constructor(e){super(),this.tokenType="DELIM",this.value="",this.value=Je(e)}toString(){return"DELIM("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e}toSource(){return this.value==="\\"?`\\
|
|
52
|
+
`:this.value}}class pr extends Ye{constructor(){super(...arguments),this.value=""}ASCIIMatch(e){return this.value.toLowerCase()===e.toLowerCase()}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e}}class jh extends pr{constructor(e){super(),this.tokenType="IDENT",this.value=e}toString(){return"IDENT("+this.value+")"}toSource(){return el(this.value)}}class qa extends pr{constructor(e){super(),this.tokenType="FUNCTION",this.value=e,this.mirror=")"}toString(){return"FUNCTION("+this.value+")"}toSource(){return el(this.value)+"("}}class H0 extends pr{constructor(e){super(),this.tokenType="AT-KEYWORD",this.value=e}toString(){return"AT("+this.value+")"}toSource(){return"@"+el(this.value)}}class q0 extends pr{constructor(e){super(),this.tokenType="HASH",this.value=e,this.type="unrestricted"}toString(){return"HASH("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.type=this.type,e}toSource(){return this.type==="id"?"#"+el(this.value):"#"+gx(this.value)}}class Lh extends pr{constructor(e){super(),this.tokenType="STRING",this.value=e}toString(){return'"'+G0(this.value)+'"'}}class $0 extends pr{constructor(e){super(),this.tokenType="URL",this.value=e}toString(){return"URL("+this.value+")"}toSource(){return'url("'+G0(this.value)+'")'}}class I0 extends Ye{constructor(){super(),this.tokenType="NUMBER",this.type="integer",this.repr=""}toString(){return this.type==="integer"?"INT("+this.value+")":"NUMBER("+this.value+")"}toJSON(){const e=super.toJSON();return e.value=this.value,e.type=this.type,e.repr=this.repr,e}toSource(){return this.repr}}class V0 extends Ye{constructor(){super(),this.tokenType="PERCENTAGE",this.repr=""}toString(){return"PERCENTAGE("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.repr=this.repr,e}toSource(){return this.repr+"%"}}class px extends Ye{constructor(){super(),this.tokenType="DIMENSION",this.type="integer",this.repr="",this.unit=""}toString(){return"DIM("+this.value+","+this.unit+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.type=this.type,e.repr=this.repr,e.unit=this.unit,e}toSource(){const e=this.repr;let i=el(this.unit);return i[0].toLowerCase()==="e"&&(i[1]==="-"||Fe(i.charCodeAt(1),48,57))&&(i="\\65 "+i.slice(1,i.length)),e+i}}function el(n){n=""+n;let e="";const i=n.charCodeAt(0);for(let s=0;s<n.length;s++){const a=n.charCodeAt(s);if(a===0)throw new Oh("Invalid character: the input contains U+0000.");Fe(a,1,31)||a===127||s===0&&Fe(a,48,57)||s===1&&Fe(a,48,57)&&i===45?e+="\\"+a.toString(16)+" ":a>=128||a===45||a===95||Fe(a,48,57)||Fe(a,65,90)||Fe(a,97,122)?e+=n[s]:e+="\\"+n[s]}return e}function gx(n){n=""+n;let e="";for(let i=0;i<n.length;i++){const s=n.charCodeAt(i);if(s===0)throw new Oh("Invalid character: the input contains U+0000.");s>=128||s===45||s===95||Fe(s,48,57)||Fe(s,65,90)||Fe(s,97,122)?e+=n[i]:e+="\\"+s.toString(16)+" "}return e}function G0(n){n=""+n;let e="";for(let i=0;i<n.length;i++){const s=n.charCodeAt(i);if(s===0)throw new Oh("Invalid character: the input contains U+0000.");Fe(s,1,31)||s===127?e+="\\"+s.toString(16)+" ":s===34||s===92?e+="\\"+n[i]:e+=n[i]}return e}class jt extends Error{}function mx(n,e){let i;try{i=N0(n),i[i.length-1]instanceof Ro||i.push(new Ro)}catch(R){const ee=R.message+` while parsing css selector "${n}". Did you mean to CSS.escape it?`,re=(R.stack||"").indexOf(R.message);throw re!==-1&&(R.stack=R.stack.substring(0,re)+ee+R.stack.substring(re+R.message.length)),R.message=ee,R}const s=i.find(R=>R instanceof H0||R instanceof C0||R instanceof Oo||R instanceof z0||R instanceof k0||R instanceof M0||R instanceof R0||R instanceof L0||R instanceof D0||R instanceof $0||R instanceof V0);if(s)throw new jt(`Unsupported token "${s.toSource()}" while parsing css selector "${n}". Did you mean to CSS.escape it?`);let a=0;const o=new Set;function u(){return new jt(`Unexpected token "${i[a].toSource()}" while parsing css selector "${n}". Did you mean to CSS.escape it?`)}function f(){for(;i[a]instanceof Go;)a++}function d(R=a){return i[R]instanceof jh}function p(R=a){return i[R]instanceof Lh}function m(R=a){return i[R]instanceof I0}function y(R=a){return i[R]instanceof j0}function b(R=a){return i[R]instanceof U0}function w(R=a){return i[R]instanceof Rh}function E(R=a){return i[R]instanceof qa}function x(R=a){return i[R]instanceof ct&&i[R].value==="*"}function _(R=a){return i[R]instanceof Ro}function k(R=a){return i[R]instanceof ct&&[">","+","~"].includes(i[R].value)}function C(R=a){return y(R)||w(R)||_(R)||k(R)||i[R]instanceof Go}function V(){const R=[I()];for(;f(),!!y();)a++,R.push(I());return R}function I(){return f(),m()||p()?i[a++].value:B()}function B(){const R={simples:[]};for(f(),k()?R.simples.push({selector:{functions:[{name:"scope",args:[]}]},combinator:""}):R.simples.push({selector:G(),combinator:""});;){if(f(),k())R.simples[R.simples.length-1].combinator=i[a++].value,f();else if(C())break;R.simples.push({combinator:"",selector:G()})}return R}function G(){let R="";const ee=[];for(;!C();)if(d()||x())R+=i[a++].toSource();else if(i[a]instanceof q0)R+=i[a++].toSource();else if(i[a]instanceof ct&&i[a].value===".")if(a++,d())R+="."+i[a++].toSource();else throw u();else if(i[a]instanceof O0)if(a++,d())if(!e.has(i[a].value.toLowerCase()))R+=":"+i[a++].toSource();else{const re=i[a++].value.toLowerCase();ee.push({name:re,args:[]}),o.add(re)}else if(E()){const re=i[a++].value.toLowerCase();if(e.has(re)?(ee.push({name:re,args:V()}),o.add(re)):R+=`:${re}(${J()})`,f(),!w())throw u();a++}else throw u();else if(i[a]instanceof B0){for(R+="[",a++;!(i[a]instanceof hh)&&!_();)R+=i[a++].toSource();if(!(i[a]instanceof hh))throw u();R+="]",a++}else throw u();if(!R&&!ee.length)throw u();return{css:R||void 0,functions:ee}}function J(){let R="",ee=1;for(;!_()&&((b()||E())&&ee++,w()&&ee--,!!ee);)R+=i[a++].toSource();return R}const $=V();if(!_())throw u();if($.some(R=>typeof R!="object"||!("simples"in R)))throw new jt(`Error while parsing css selector "${n}". Did you mean to CSS.escape it?`);return{selector:$,names:Array.from(o)}}const dh=new Set(["internal:has","internal:has-not","internal:and","internal:or","internal:chain","left-of","right-of","above","below","near"]),yx=new Set(["left-of","right-of","above","below","near"]),K0=new Set(["not","is","where","has","scope","light","visible","text","text-matches","text-is","has-text","above","below","right-of","left-of","near","nth-match"]);function tl(n){const e=Sx(n),i=[];for(const s of e.parts){if(s.name==="css"||s.name==="css:light"){s.name==="css:light"&&(s.body=":light("+s.body+")");const a=mx(s.body,K0);i.push({name:"css",body:a.selector,source:s.body});continue}if(dh.has(s.name)){let a,o;try{const p=JSON.parse("["+s.body+"]");if(!Array.isArray(p)||p.length<1||p.length>2||typeof p[0]!="string")throw new jt(`Malformed selector: ${s.name}=`+s.body);if(a=p[0],p.length===2){if(typeof p[1]!="number"||!yx.has(s.name))throw new jt(`Malformed selector: ${s.name}=`+s.body);o=p[1]}}catch{throw new jt(`Malformed selector: ${s.name}=`+s.body)}const u={name:s.name,source:s.body,body:{parsed:tl(a),distance:o}},f=[...u.body.parsed.parts].reverse().find(p=>p.name==="internal:control"&&p.body==="enter-frame"),d=f?u.body.parsed.parts.indexOf(f):-1;d!==-1&&bx(u.body.parsed.parts.slice(0,d+1),i.slice(0,d+1))&&u.body.parsed.parts.splice(0,d+1),i.push(u);continue}i.push({...s,source:s.body})}if(dh.has(i[0].name))throw new jt(`"${i[0].name}" selector cannot be first`);return{capture:e.capture,parts:i}}function bx(n,e){return Gn({parts:n})===Gn({parts:e})}function Gn(n,e){return typeof n=="string"?n:n.parts.map((i,s)=>{let a=!0;!e&&s!==n.capture&&(i.name==="css"||i.name==="xpath"&&i.source.startsWith("//")||i.source.startsWith(".."))&&(a=!1);const o=a?i.name+"=":"";return`${s===n.capture?"*":""}${o}${i.source}`}).join(" >> ")}function vx(n,e){const i=(s,a)=>{for(const o of s.parts)e(o,a),dh.has(o.name)&&i(o.body.parsed,!0)};i(n,!1)}function Sx(n){let e=0,i,s=0;const a={parts:[]},o=()=>{const f=n.substring(s,e).trim(),d=f.indexOf("=");let p,m;d!==-1&&f.substring(0,d).trim().match(/^[a-zA-Z_0-9-+:*]+$/)?(p=f.substring(0,d).trim(),m=f.substring(d+1)):f.length>1&&f[0]==='"'&&f[f.length-1]==='"'||f.length>1&&f[0]==="'"&&f[f.length-1]==="'"?(p="text",m=f):/^\(*\/\//.test(f)||f.startsWith("..")?(p="xpath",m=f):(p="css",m=f);let y=!1;if(p[0]==="*"&&(y=!0,p=p.substring(1)),a.parts.push({name:p,body:m}),y){if(a.capture!==void 0)throw new jt("Only one of the selectors can capture using * modifier");a.capture=a.parts.length-1}};if(!n.includes(">>"))return e=n.length,o(),a;const u=()=>{const d=n.substring(s,e).match(/^\s*text\s*=(.*)$/);return!!d&&!!d[1]};for(;e<n.length;){const f=n[e];f==="\\"&&e+1<n.length?e+=2:f===i?(i=void 0,e++):!i&&(f==='"'||f==="'"||f==="`")&&!u()?(i=f,e++):!i&&f===">"&&n[e+1]===">"?(o(),e+=2,s=e):e++}return o(),a}function Ji(n,e){let i=0,s=n.length===0;const a=()=>n[i]||"",o=()=>{const _=a();return++i,s=i>=n.length,_},u=_=>{throw s?new jt(`Unexpected end of selector while parsing selector \`${n}\``):new jt(`Error while parsing selector \`${n}\` - unexpected symbol "${a()}" at position ${i}`+(_?" during "+_:""))};function f(){for(;!s&&/\s/.test(a());)o()}function d(_){return _>=""||_>="0"&&_<="9"||_>="A"&&_<="Z"||_>="a"&&_<="z"||_>="0"&&_<="9"||_==="_"||_==="-"}function p(){let _="";for(f();!s&&d(a());)_+=o();return _}function m(_){let k=o();for(k!==_&&u("parsing quoted string");!s&&a()!==_;)a()==="\\"&&o(),k+=o();return a()!==_&&u("parsing quoted string"),k+=o(),k}function y(){o()!=="/"&&u("parsing regular expression");let _="",k=!1;for(;!s;){if(a()==="\\")_+=o(),s&&u("parsing regular expression");else if(k&&a()==="]")k=!1;else if(!k&&a()==="[")k=!0;else if(!k&&a()==="/")break;_+=o()}o()!=="/"&&u("parsing regular expression");let C="";for(;!s&&a().match(/[dgimsuy]/);)C+=o();try{return new RegExp(_,C)}catch(V){throw new jt(`Error while parsing selector \`${n}\`: ${V.message}`)}}function b(){let _="";return f(),a()==="'"||a()==='"'?_=m(a()).slice(1,-1):_=p(),_||u("parsing property path"),_}function w(){f();let _="";return s||(_+=o()),!s&&_!=="="&&(_+=o()),["=","*=","^=","$=","|=","~="].includes(_)||u("parsing operator"),_}function E(){o();const _=[];for(_.push(b()),f();a()===".";)o(),_.push(b()),f();if(a()==="]")return o(),{name:_.join("."),jsonPath:_,op:"<truthy>",value:null,caseSensitive:!1};const k=w();let C,V=!0;if(f(),a()==="/"){if(k!=="=")throw new jt(`Error while parsing selector \`${n}\` - cannot use ${k} in attribute with regular expression`);C=y()}else if(a()==="'"||a()==='"')C=m(a()).slice(1,-1),f(),a()==="i"||a()==="I"?(V=!1,o()):(a()==="s"||a()==="S")&&(V=!0,o());else{for(C="";!s&&(d(a())||a()==="+"||a()===".");)C+=o();C==="true"?C=!0:C==="false"?C=!1:e||(C=+C,Number.isNaN(C)&&u("parsing attribute value"))}if(f(),a()!=="]"&&u("parsing attribute value"),o(),k!=="="&&typeof C!="string")throw new jt(`Error while parsing selector \`${n}\` - cannot use ${k} in attribute with non-string matching value - ${C}`);return{name:_.join("."),jsonPath:_,op:k,value:C,caseSensitive:V}}const x={name:"",attributes:[]};for(x.name=p(),f();a()==="[";)x.attributes.push(E()),f();if(s||u(void 0),!x.name&&!x.attributes.length)throw new jt(`Error while parsing selector \`${n}\` - selector cannot be empty`);return x}function ic(n,e="'"){const i=JSON.stringify(n),s=i.substring(1,i.length-1).replace(/\\"/g,'"');if(e==="'")return e+s.replace(/[']/g,"\\'")+e;if(e==='"')return e+s.replace(/["]/g,'\\"')+e;if(e==="`")return e+s.replace(/[`]/g,"\\`")+e;throw new Error("Invalid escape char")}function Ko(n){return n.charAt(0).toUpperCase()+n.substring(1)}function Y0(n){return n.replace(/([a-z0-9])([A-Z])/g,"$1_$2").replace(/([A-Z])([A-Z][a-z])/g,"$1_$2").toLowerCase()}function Ws(n){return`"${n.replace(/["\\]/g,e=>"\\"+e)}"`}let Vi;function wx(){Vi=new Map}function Tt(n){let e=Vi==null?void 0:Vi.get(n);return e===void 0&&(e=n.replace(/[\u200b\u00ad]/g,"").trim().replace(/\s+/g," "),Vi==null||Vi.set(n,e)),e}function sc(n){return n.replace(/(^|[^\\])(\\\\)*\\(['"`])/g,"$1$2$3")}function X0(n){return n.unicode||n.unicodeSets?String(n):String(n).replace(/(^|[^\\])(\\\\)*(["'`])/g,"$1$2\\$3").replace(/>>/g,"\\>\\>")}function Lt(n,e){return typeof n!="string"?X0(n):`${JSON.stringify(n)}${e?"s":"i"}`}function xt(n,e){return typeof n!="string"?X0(n):`"${n.replace(/\\/g,"\\\\").replace(/["]/g,'\\"')}"${e?"s":"i"}`}function xx(n,e,i=""){if(n.length<=e)return n;const s=[...n];return s.length>e?s.slice(0,e-i.length).join("")+i:s.join("")}function ky(n,e){return xx(n,e,"…")}function Yo(n){return n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function _x(n,e){const i=n.length,s=e.length;let a=0,o=0;const u=Array(i+1).fill(null).map(()=>Array(s+1).fill(0));for(let f=1;f<=i;f++)for(let d=1;d<=s;d++)n[f-1]===e[d-1]&&(u[f][d]=u[f-1][d-1]+1,u[f][d]>a&&(a=u[f][d],o=f));return n.slice(o-a,o)}function Tx(n,e){try{const i=tl(e),s=Ex(i);return s||Xi(new F0[n],i,!1,1)[0]}catch{return e}}function Ex(n){const e=n.parts[n.parts.length-1];if((e==null?void 0:e.name)==="internal:describe"){const i=JSON.parse(e.body);if(typeof i=="string")return i}}function Wi(n,e,i=!1){return P0(n,e,i,1)[0]}function P0(n,e,i=!1,s=20,a){try{return Xi(new F0[n](a),tl(e),i,s)}catch{return[e]}}function Xi(n,e,i=!1,s=20){const a=[...e.parts],o=[];let u=i?"frame-locator":"page";for(let f=0;f<a.length;f++){const d=a[f],p=u;if(u="locator",d.name==="internal:describe")continue;if(d.name==="nth"){d.body==="0"?o.push([n.generateLocator(p,"first",""),n.generateLocator(p,"nth","0")]):d.body==="-1"?o.push([n.generateLocator(p,"last",""),n.generateLocator(p,"nth","-1")]):o.push([n.generateLocator(p,"nth",d.body)]);continue}if(d.name==="visible"){o.push([n.generateLocator(p,"visible",d.body),n.generateLocator(p,"default",`visible=${d.body}`)]);continue}if(d.name==="internal:text"){const{exact:E,text:x}=Aa(d.body);o.push([n.generateLocator(p,"text",x,{exact:E})]);continue}if(d.name==="internal:has-text"){const{exact:E,text:x}=Aa(d.body);if(!E){o.push([n.generateLocator(p,"has-text",x,{exact:E})]);continue}}if(d.name==="internal:has-not-text"){const{exact:E,text:x}=Aa(d.body);if(!E){o.push([n.generateLocator(p,"has-not-text",x,{exact:E})]);continue}}if(d.name==="internal:has"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"has",x)));continue}if(d.name==="internal:has-not"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"hasNot",x)));continue}if(d.name==="internal:and"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"and",x)));continue}if(d.name==="internal:or"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"or",x)));continue}if(d.name==="internal:chain"){const E=Xi(n,d.body.parsed,!1,s);o.push(E.map(x=>n.generateLocator(p,"chain",x)));continue}if(d.name==="internal:label"){const{exact:E,text:x}=Aa(d.body);o.push([n.generateLocator(p,"label",x,{exact:E})]);continue}if(d.name==="internal:role"){const E=Ji(d.body,!0),x={attrs:[]};for(const _ of E.attributes)_.name==="name"?(x.exact=_.caseSensitive,x.name=_.value):(_.name==="level"&&typeof _.value=="string"&&(_.value=+_.value),x.attrs.push({name:_.name==="include-hidden"?"includeHidden":_.name,value:_.value}));o.push([n.generateLocator(p,"role",E.name,x)]);continue}if(d.name==="internal:testid"){const E=Ji(d.body,!0),{value:x}=E.attributes[0];o.push([n.generateLocator(p,"test-id",x)]);continue}if(d.name==="internal:attr"){const E=Ji(d.body,!0),{name:x,value:_,caseSensitive:k}=E.attributes[0],C=_,V=!!k;if(x==="placeholder"){o.push([n.generateLocator(p,"placeholder",C,{exact:V})]);continue}if(x==="alt"){o.push([n.generateLocator(p,"alt",C,{exact:V})]);continue}if(x==="title"){o.push([n.generateLocator(p,"title",C,{exact:V})]);continue}}if(d.name==="internal:control"&&d.body==="enter-frame"){const E=o[o.length-1],x=a[f-1],_=E.map(k=>n.chainLocators([k,n.generateLocator(p,"frame","")]));["xpath","css"].includes(x.name)&&_.push(n.generateLocator(p,"frame-locator",Gn({parts:[x]})),n.generateLocator(p,"frame-locator",Gn({parts:[x]},!0))),E.splice(0,E.length,..._),u="frame-locator";continue}const m=a[f+1],y=Gn({parts:[d]}),b=n.generateLocator(p,"default",y);if(m&&["internal:has-text","internal:has-not-text"].includes(m.name)){const{exact:E,text:x}=Aa(m.body);if(!E){const _=n.generateLocator("locator",m.name==="internal:has-text"?"has-text":"has-not-text",x,{exact:E}),k={};m.name==="internal:has-text"?k.hasText=x:k.hasNotText=x;const C=n.generateLocator(p,"default",y,k);o.push([n.chainLocators([b,_]),C]),f++;continue}}let w;if(["xpath","css"].includes(d.name)){const E=Gn({parts:[d]},!0);w=n.generateLocator(p,"default",E)}o.push([b,w].filter(Boolean))}return Ax(n,o,s)}function Ax(n,e,i){const s=e.map(()=>""),a=[],o=u=>{if(u===e.length)return a.push(n.chainLocators(s)),a.length<i;for(const f of e[u])if(s[u]=f,!o(u+1))return!1;return!0};return o(0),a}function Aa(n){let e=!1;const i=n.match(/^\/(.*)\/([igm]*)$/);return i?{text:new RegExp(i[1],i[2])}:(n.endsWith('"')?(n=JSON.parse(n),e=!0):n.endsWith('"s')?(n=JSON.parse(n.substring(0,n.length-1)),e=!0):n.endsWith('"i')&&(n=JSON.parse(n.substring(0,n.length-1)),e=!1),{exact:e,text:n})}class Nx{constructor(e){this.preferredQuote=e}generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, { hasText: ${this.toHasText(a.hasText)} })`:a.hasNotText!==void 0?`locator(${this.quote(s)}, { hasNotText: ${this.toHasText(a.hasNotText)} })`:`locator(${this.quote(s)})`;case"frame-locator":return`frameLocator(${this.quote(s)})`;case"frame":return"contentFrame()";case"nth":return`nth(${s})`;case"first":return"first()";case"last":return"last()";case"visible":return`filter({ visible: ${s==="true"?"true":"false"} })`;case"role":const o=[];ut(a.name)?o.push(`name: ${this.regexToSourceString(a.name)}`):typeof a.name=="string"&&(o.push(`name: ${this.quote(a.name)}`),a.exact&&o.push("exact: true"));for(const{name:f,value:d}of a.attrs)o.push(`${f}: ${typeof d=="string"?this.quote(d):d}`);const u=o.length?`, { ${o.join(", ")} }`:"";return`getByRole(${this.quote(s)}${u})`;case"has-text":return`filter({ hasText: ${this.toHasText(s)} })`;case"has-not-text":return`filter({ hasNotText: ${this.toHasText(s)} })`;case"has":return`filter({ has: ${s} })`;case"hasNot":return`filter({ hasNot: ${s} })`;case"and":return`and(${s})`;case"or":return`or(${s})`;case"chain":return`locator(${s})`;case"test-id":return`getByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("getByText",s,!!a.exact);case"alt":return this.toCallWithExact("getByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact("getByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact("getByLabel",s,!!a.exact);case"title":return this.toCallWithExact("getByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToSourceString(e){return sc(String(e))}toCallWithExact(e,i,s){return ut(i)?`${e}(${this.regexToSourceString(i)})`:s?`${e}(${this.quote(i)}, { exact: true })`:`${e}(${this.quote(i)})`}toHasText(e){return ut(e)?this.regexToSourceString(e):this.quote(e)}toTestIdValue(e){return ut(e)?this.regexToSourceString(e):this.quote(e)}quote(e){return ic(e,this.preferredQuote??"'")}}class Cx{generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, has_text=${this.toHasText(a.hasText)})`:a.hasNotText!==void 0?`locator(${this.quote(s)}, has_not_text=${this.toHasText(a.hasNotText)})`:`locator(${this.quote(s)})`;case"frame-locator":return`frame_locator(${this.quote(s)})`;case"frame":return"content_frame";case"nth":return`nth(${s})`;case"first":return"first";case"last":return"last";case"visible":return`filter(visible=${s==="true"?"True":"False"})`;case"role":const o=[];ut(a.name)?o.push(`name=${this.regexToString(a.name)}`):typeof a.name=="string"&&(o.push(`name=${this.quote(a.name)}`),a.exact&&o.push("exact=True"));for(const{name:f,value:d}of a.attrs){let p=typeof d=="string"?this.quote(d):d;typeof d=="boolean"&&(p=d?"True":"False"),o.push(`${Y0(f)}=${p}`)}const u=o.length?`, ${o.join(", ")}`:"";return`get_by_role(${this.quote(s)}${u})`;case"has-text":return`filter(has_text=${this.toHasText(s)})`;case"has-not-text":return`filter(has_not_text=${this.toHasText(s)})`;case"has":return`filter(has=${s})`;case"hasNot":return`filter(has_not=${s})`;case"and":return`and_(${s})`;case"or":return`or_(${s})`;case"chain":return`locator(${s})`;case"test-id":return`get_by_test_id(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("get_by_text",s,!!a.exact);case"alt":return this.toCallWithExact("get_by_alt_text",s,!!a.exact);case"placeholder":return this.toCallWithExact("get_by_placeholder",s,!!a.exact);case"label":return this.toCallWithExact("get_by_label",s,!!a.exact);case"title":return this.toCallWithExact("get_by_title",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", re.IGNORECASE":"";return`re.compile(r"${sc(e.source).replace(/\\\//,"/").replace(/"/g,'\\"')}"${i})`}toCallWithExact(e,i,s){return ut(i)?`${e}(${this.regexToString(i)})`:s?`${e}(${this.quote(i)}, exact=True)`:`${e}(${this.quote(i)})`}toHasText(e){return ut(e)?this.regexToString(e):`${this.quote(e)}`}toTestIdValue(e){return ut(e)?this.regexToString(e):this.quote(e)}quote(e){return ic(e,'"')}}class kx{generateLocator(e,i,s,a={}){let o;switch(e){case"page":o="Page";break;case"frame-locator":o="FrameLocator";break;case"locator":o="Locator";break}switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, new ${o}.LocatorOptions().setHasText(${this.toHasText(a.hasText)}))`:a.hasNotText!==void 0?`locator(${this.quote(s)}, new ${o}.LocatorOptions().setHasNotText(${this.toHasText(a.hasNotText)}))`:`locator(${this.quote(s)})`;case"frame-locator":return`frameLocator(${this.quote(s)})`;case"frame":return"contentFrame()";case"nth":return`nth(${s})`;case"first":return"first()";case"last":return"last()";case"visible":return`filter(new ${o}.FilterOptions().setVisible(${s==="true"?"true":"false"}))`;case"role":const u=[];ut(a.name)?u.push(`.setName(${this.regexToString(a.name)})`):typeof a.name=="string"&&(u.push(`.setName(${this.quote(a.name)})`),a.exact&&u.push(".setExact(true)"));for(const{name:d,value:p}of a.attrs)u.push(`.set${Ko(d)}(${typeof p=="string"?this.quote(p):p})`);const f=u.length?`, new ${o}.GetByRoleOptions()${u.join("")}`:"";return`getByRole(AriaRole.${Y0(s).toUpperCase()}${f})`;case"has-text":return`filter(new ${o}.FilterOptions().setHasText(${this.toHasText(s)}))`;case"has-not-text":return`filter(new ${o}.FilterOptions().setHasNotText(${this.toHasText(s)}))`;case"has":return`filter(new ${o}.FilterOptions().setHas(${s}))`;case"hasNot":return`filter(new ${o}.FilterOptions().setHasNot(${s}))`;case"and":return`and(${s})`;case"or":return`or(${s})`;case"chain":return`locator(${s})`;case"test-id":return`getByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact(o,"getByText",s,!!a.exact);case"alt":return this.toCallWithExact(o,"getByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact(o,"getByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact(o,"getByLabel",s,!!a.exact);case"title":return this.toCallWithExact(o,"getByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", Pattern.CASE_INSENSITIVE":"";return`Pattern.compile(${this.quote(sc(e.source))}${i})`}toCallWithExact(e,i,s,a){return ut(s)?`${i}(${this.regexToString(s)})`:a?`${i}(${this.quote(s)}, new ${e}.${Ko(i)}Options().setExact(true))`:`${i}(${this.quote(s)})`}toHasText(e){return ut(e)?this.regexToString(e):this.quote(e)}toTestIdValue(e){return ut(e)?this.regexToString(e):this.quote(e)}quote(e){return ic(e,'"')}}class Mx{generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`Locator(${this.quote(s)}, new() { ${this.toHasText(a.hasText)} })`:a.hasNotText!==void 0?`Locator(${this.quote(s)}, new() { ${this.toHasNotText(a.hasNotText)} })`:`Locator(${this.quote(s)})`;case"frame-locator":return`FrameLocator(${this.quote(s)})`;case"frame":return"ContentFrame";case"nth":return`Nth(${s})`;case"first":return"First";case"last":return"Last";case"visible":return`Filter(new() { Visible = ${s==="true"?"true":"false"} })`;case"role":const o=[];ut(a.name)?o.push(`NameRegex = ${this.regexToString(a.name)}`):typeof a.name=="string"&&(o.push(`Name = ${this.quote(a.name)}`),a.exact&&o.push("Exact = true"));for(const{name:f,value:d}of a.attrs)o.push(`${Ko(f)} = ${typeof d=="string"?this.quote(d):d}`);const u=o.length?`, new() { ${o.join(", ")} }`:"";return`GetByRole(AriaRole.${Ko(s)}${u})`;case"has-text":return`Filter(new() { ${this.toHasText(s)} })`;case"has-not-text":return`Filter(new() { ${this.toHasNotText(s)} })`;case"has":return`Filter(new() { Has = ${s} })`;case"hasNot":return`Filter(new() { HasNot = ${s} })`;case"and":return`And(${s})`;case"or":return`Or(${s})`;case"chain":return`Locator(${s})`;case"test-id":return`GetByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("GetByText",s,!!a.exact);case"alt":return this.toCallWithExact("GetByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact("GetByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact("GetByLabel",s,!!a.exact);case"title":return this.toCallWithExact("GetByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", RegexOptions.IgnoreCase":"";return`new Regex(${this.quote(sc(e.source))}${i})`}toCallWithExact(e,i,s){return ut(i)?`${e}(${this.regexToString(i)})`:s?`${e}(${this.quote(i)}, new() { Exact = true })`:`${e}(${this.quote(i)})`}toHasText(e){return ut(e)?`HasTextRegex = ${this.regexToString(e)}`:`HasText = ${this.quote(e)}`}toTestIdValue(e){return ut(e)?this.regexToString(e):this.quote(e)}toHasNotText(e){return ut(e)?`HasNotTextRegex = ${this.regexToString(e)}`:`HasNotText = ${this.quote(e)}`}quote(e){return ic(e,'"')}}class Ox{generateLocator(e,i,s,a={}){return JSON.stringify({kind:i,body:s,options:a})}chainLocators(e){const i=e.map(s=>JSON.parse(s));for(let s=0;s<i.length-1;++s)i[s].next=i[s+1];return JSON.stringify(i[0])}}const F0={javascript:Nx,python:Cx,java:kx,csharp:Mx,jsonl:Ox};function ut(n){return n instanceof RegExp}const My=new Map;function Rx({name:n,rootItem:e,render:i,title:s,icon:a,isError:o,isVisible:u,selectedItem:f,onAccepted:d,onSelected:p,onHighlighted:m,treeState:y,setTreeState:b,noItemsMessage:w,dataTestId:E,autoExpandDepth:x}){const _=U.useMemo(()=>jx(e,f,y.expandedItems,x||0,u),[e,f,y,x,u]),k=U.useRef(null),[C,V]=U.useState(),[I,B]=U.useState(!1);U.useEffect(()=>{m==null||m(C)},[m,C]),U.useEffect(()=>{const $=k.current;if(!$)return;const R=()=>{My.set(n,$.scrollTop)};return $.addEventListener("scroll",R,{passive:!0}),()=>$.removeEventListener("scroll",R)},[n]),U.useEffect(()=>{k.current&&(k.current.scrollTop=My.get(n)||0)},[n]);const G=U.useCallback($=>{const{expanded:R}=_.get($);if(R){for(let ee=f;ee;ee=ee.parent)if(ee===$){p==null||p($);break}y.expandedItems.set($.id,!1)}else y.expandedItems.set($.id,!0);b({...y})},[_,f,p,y,b]),J=U.useCallback($=>{const{expanded:R}=_.get($),ee=[$];for(;ee.length;){const re=ee.pop();ee.push(...re.children),y.expandedItems.set(re.id,!R)}b({...y})},[_,y,b]);return v.jsx("div",{className:Ke("tree-view vbox",n+"-tree-view"),"data-testid":E||n+"-tree",children:v.jsxs("div",{className:Ke("tree-view-content"),role:_.size>0?"tree":void 0,tabIndex:0,onKeyDown:$=>{if(f&&$.key==="Enter"){d==null||d(f);return}if($.key!=="ArrowDown"&&$.key!=="ArrowUp"&&$.key!=="ArrowLeft"&&$.key!=="ArrowRight")return;if($.stopPropagation(),$.preventDefault(),f&&$.key==="ArrowLeft"){const{expanded:ee,parent:re}=_.get(f);ee?(y.expandedItems.set(f.id,!1),b({...y})):re&&(p==null||p(re));return}if(f&&$.key==="ArrowRight"){f.children.length&&(y.expandedItems.set(f.id,!0),b({...y}));return}let R=f;if($.key==="ArrowDown"&&(f?R=_.get(f).next:_.size&&(R=[..._.keys()][0])),$.key==="ArrowUp"){if(f)R=_.get(f).prev;else if(_.size){const ee=[..._.keys()];R=ee[ee.length-1]}}m==null||m(void 0),R&&(B(!0),p==null||p(R)),V(void 0)},ref:k,children:[w&&_.size===0&&v.jsx("div",{className:"tree-view-empty",children:w}),e.children.map($=>_.get($)&&v.jsx(Q0,{item:$,treeItems:_,selectedItem:f,onSelected:p,onAccepted:d,isError:o,toggleExpanded:G,toggleSubtree:J,highlightedItem:C,setHighlightedItem:V,render:i,icon:a,title:s,isKeyboardNavigation:I,setIsKeyboardNavigation:B},$.id))]})})}function Q0({item:n,treeItems:e,selectedItem:i,onSelected:s,highlightedItem:a,setHighlightedItem:o,isError:u,onAccepted:f,toggleExpanded:d,toggleSubtree:p,render:m,title:y,icon:b,isKeyboardNavigation:w,setIsKeyboardNavigation:E}){const x=U.useId(),_=U.useRef(null);U.useEffect(()=>{i===n&&w&&_.current&&(S0(_.current),E(!1))},[n,i,w,E]);const k=e.get(n),C=k.depth,V=k.expanded;let I="codicon-blank";typeof V=="boolean"&&(I=V?"codicon-chevron-down":"codicon-chevron-right");const B=m(n),G=V&&n.children.length?n.children:[],J=y==null?void 0:y(n),$=(b==null?void 0:b(n))||"codicon-blank";return v.jsxs("div",{ref:_,role:"treeitem","aria-selected":n===i,"aria-expanded":V,"aria-controls":x,title:J,className:"vbox",style:{flex:"none"},children:[v.jsxs("div",{onDoubleClick:()=>f==null?void 0:f(n),className:Ke("tree-view-entry",i===n&&"selected",a===n&&"highlighted",(u==null?void 0:u(n))&&"error"),onClick:()=>s==null?void 0:s(n),onMouseEnter:()=>o(n),onMouseLeave:()=>o(void 0),children:[C?new Array(C).fill(0).map((R,ee)=>v.jsx("div",{className:"tree-view-indent"},"indent-"+ee)):void 0,v.jsx("div",{"aria-hidden":"true",className:"codicon "+I,style:{minWidth:16,marginRight:4},onDoubleClick:R=>{R.preventDefault(),R.stopPropagation()},onClick:R=>{R.stopPropagation(),R.preventDefault(),R.altKey?p(n):d(n)}}),b&&v.jsx("div",{className:"codicon "+$,style:{minWidth:16,marginRight:4},"aria-label":"["+$.replace("codicon","icon")+"]"}),typeof B=="string"?v.jsx("div",{style:{textOverflow:"ellipsis",overflow:"hidden"},children:B}):B]}),!!G.length&&v.jsx("div",{id:x,role:"group",children:G.map(R=>e.get(R)&&v.jsx(Q0,{item:R,treeItems:e,selectedItem:i,onSelected:s,onAccepted:f,isError:u,toggleExpanded:d,toggleSubtree:p,highlightedItem:a,setHighlightedItem:o,render:m,title:y,icon:b,isKeyboardNavigation:w,setIsKeyboardNavigation:E},R.id))})]})}function jx(n,e,i,s,a=()=>!0){if(!a(n))return new Map;const o=new Map,u=new Set;for(let p=e==null?void 0:e.parent;p;p=p.parent)u.add(p.id);let f=null;const d=(p,m)=>{for(const y of p.children){if(!a(y))continue;const b=u.has(y.id)||i.get(y.id),w=s>m&&o.size<25&&b!==!1,E=y.children.length?b??w:void 0,x={depth:m,expanded:E,parent:n===p?null:p,next:null,prev:f};f&&(o.get(f).next=y),f=y,o.set(y,x),E&&d(y,m+1)}};return d(n,0),o}const zt=U.forwardRef(function({children:e,title:i="",icon:s,disabled:a=!1,toggled:o=!1,onClick:u=()=>{},style:f,testId:d,className:p,ariaLabel:m},y){return v.jsxs("button",{ref:y,className:Ke(p,"toolbar-button",s,o&&"toggled"),onMouseDown:Oy,onClick:u,onDoubleClick:Oy,title:i,disabled:!!a,style:f,"data-testid":d,"aria-label":m||i,children:[s&&v.jsx("span",{className:`codicon codicon-${s}`,style:e?{marginRight:5}:{}}),e]})}),Oy=n=>{n.stopPropagation(),n.preventDefault()};function Z0(n){return n==="scheduled"?"codicon-clock":n==="running"?"codicon-loading":n==="failed"?"codicon-error":n==="passed"?"codicon-check":n==="skipped"?"codicon-circle-slash":"codicon-circle-outline"}function Lx(n){return n==="scheduled"?"Pending":n==="running"?"Running":n==="failed"?"Failed":n==="passed"?"Passed":n==="skipped"?"Skipped":"Did not run"}const Dx=Rx,Bx=({actions:n,selectedAction:e,selectedTime:i,setSelectedTime:s,sdkLanguage:a,onSelected:o,onHighlighted:u,revealConsole:f,revealAttachment:d,isLive:p})=>{const[m,y]=U.useState({expandedItems:new Map}),{rootItem:b,itemMap:w}=U.useMemo(()=>Qw(n),[n]),{selectedItem:E}=U.useMemo(()=>({selectedItem:e?w.get(e.callId):void 0}),[w,e]),x=U.useCallback(B=>{var G,J;return!!((J=(G=B.action)==null?void 0:G.error)!=null&&J.message)},[]),_=U.useCallback(B=>s({minimum:B.action.startTime,maximum:B.action.endTime}),[s]),k=U.useCallback(B=>Dh(B.action,{sdkLanguage:a,revealConsole:f,revealAttachment:d,isLive:p,showDuration:!0,showBadges:!0}),[p,f,d,a]),C=U.useCallback(B=>!i||!B.action||B.action.startTime<=i.maximum&&B.action.endTime>=i.minimum,[i]),V=U.useCallback(B=>{o==null||o(B.action)},[o]),I=U.useCallback(B=>{u==null||u(B==null?void 0:B.action)},[u]);return v.jsxs("div",{className:"vbox",children:[i&&v.jsxs("div",{className:"action-list-show-all",onClick:()=>s(void 0),children:[v.jsx("span",{className:"codicon codicon-triangle-left"}),"Show all"]}),v.jsx(Dx,{name:"actions",rootItem:b,treeState:m,setTreeState:y,selectedItem:E,onSelected:V,onHighlighted:I,onAccepted:_,isError:x,isVisible:C,render:k})]})},Dh=(n,e)=>{var _,k;const{sdkLanguage:i,revealConsole:s,revealAttachment:a,isLive:o,showDuration:u,showBadges:f}=e,{errors:d,warnings:p}=Jw(n),m=!!((_=n.attachments)!=null&&_.length)&&!!a,y=n.params.selector?Tx(i||"javascript",n.params.selector):void 0,b=n.class==="Test"&&n.method==="test.step"&&((k=n.annotations)==null?void 0:k.some(C=>C.type==="skip"));let w="";n.endTime?w=_t(n.endTime-n.startTime):n.error?w="Timed out":o||(w="-");const{elements:E,title:x}=J0(n);return v.jsxs("div",{className:"action-title vbox",children:[v.jsxs("div",{className:"hbox",children:[v.jsx("span",{className:"action-title-method",title:x,children:E}),(u||f||m||b)&&v.jsx("div",{className:"spacer"}),m&&v.jsx(zt,{icon:"attach",title:"Open Attachment",onClick:()=>a(n.attachments[0])}),u&&!b&&v.jsx("div",{className:"action-duration",children:w||v.jsx("span",{className:"codicon codicon-loading"})}),b&&v.jsx("span",{className:Ke("action-skipped","codicon",Z0("skipped")),title:"skipped"}),f&&v.jsxs("div",{className:"action-icons",onClick:()=>s==null?void 0:s(),children:[!!d&&v.jsxs("div",{className:"action-icon",children:[v.jsx("span",{className:"codicon codicon-error"}),v.jsx("span",{className:"action-icon-value",children:d})]}),!!p&&v.jsxs("div",{className:"action-icon",children:[v.jsx("span",{className:"codicon codicon-warning"}),v.jsx("span",{className:"action-icon-value",children:p})]})]})]}),y&&v.jsx("div",{className:"action-title-selector",title:y,children:y})]})};function J0(n){var f;const e=n.title??((f=x0.get(n.class+"."+n.method))==null?void 0:f.title)??n.method,i=[],s=[];let a=0;const o=/\{([^}]+)\}/g;let u;for(;(u=o.exec(e))!==null;){const[d,p]=u,m=e.slice(a,u.index);i.push(m),s.push(m);const y=$w(n.params,p);y===void 0?(i.push(d),s.push(d)):u.index===0?(i.push(y),s.push(y)):(i.push(v.jsx("span",{className:"action-title-param",children:y},i.length)),s.push(y)),a=u.index+d.length}if(a<e.length){const d=e.slice(a);i.push(d),s.push(d)}return{elements:i,title:s.join("")}}const Bh=({value:n,description:e})=>{const[i,s]=U.useState("copy"),a=U.useCallback(()=>{(typeof n=="function"?n():Promise.resolve(n)).then(u=>{navigator.clipboard.writeText(u).then(()=>{s("check"),setTimeout(()=>{s("copy")},3e3)},()=>{s("close")})},()=>{s("close")})},[n]);return v.jsx(zt,{title:e||"Copy",icon:i,onClick:a})},jo=({value:n,description:e,copiedDescription:i=e,style:s})=>{const[a,o]=U.useState(!1),u=U.useCallback(async()=>{const f=typeof n=="function"?await n():n;await navigator.clipboard.writeText(f),o(!0),setTimeout(()=>o(!1),3e3)},[n]);return v.jsx(zt,{style:s,title:e,onClick:u,className:"copy-to-clipboard-text-button",children:a?i:e})},ns=({text:n})=>v.jsx("div",{className:"fill",style:{display:"flex",alignItems:"center",justifyContent:"center",fontSize:24,fontWeight:"bold",opacity:.5},children:n}),Ux=({action:n,startTimeOffset:e,sdkLanguage:i})=>{const s=U.useMemo(()=>Object.keys((n==null?void 0:n.params)??{}).filter(f=>f!=="info"),[n]);if(!n)return v.jsx(ns,{text:"No action selected"});const a=n.startTime-e,o=_t(a),{title:u}=J0(n);return v.jsxs("div",{className:"call-tab",children:[v.jsx("div",{className:"call-line",children:u}),v.jsx("div",{className:"call-section",children:"Time"}),vo({name:"start",type:"literal",text:o}),vo({name:"duration",type:"literal",text:zx(n)}),!!s.length&&v.jsxs(v.Fragment,{children:[v.jsx("div",{className:"call-section",children:"Parameters"}),s.map(f=>vo(Ry(n,f,n.params[f],i)))]}),!!n.result&&v.jsxs(v.Fragment,{children:[v.jsx("div",{className:"call-section",children:"Return value"}),Object.keys(n.result).map(f=>vo(Ry(n,f,n.result[f],i)))]})]})};function zx(n){return n.endTime?_t(n.endTime-n.startTime):n.error?"Timed Out":"Running"}function vo(n){let e=n.text.replace(/\n/g,"↵");return n.type==="string"&&(e=`"${e}"`),v.jsxs("div",{className:"call-line",children:[n.name,":",v.jsx("span",{className:Ke("call-value",n.type),title:n.text,children:e}),["literal","string","number","object","locator"].includes(n.type)&&v.jsx(Bh,{value:n.text})]},n.name)}function Ry(n,e,i,s){const a=n.method.includes("eval")||n.method==="waitForFunction";if(e==="files")return{text:"<files>",type:"string",name:e};if((e==="eventInit"||e==="expectedValue"||e==="arg"&&a)&&(i=Xo(i.value,new Array(10).fill({handle:"<handle>"}))),(e==="value"&&a||e==="received"&&n.method==="expect")&&(i=Xo(i,new Array(10).fill({handle:"<handle>"}))),e==="selector")return{text:Wi(s||"javascript",n.params.selector),type:"locator",name:"locator"};const o=typeof i;return o!=="object"||i===null?{text:String(i),type:o,name:e}:i.guid?{text:"<handle>",type:"handle",name:e}:{text:JSON.stringify(i).slice(0,1e3),type:"object",name:e}}function Xo(n,e){if(n.n!==void 0)return n.n;if(n.s!==void 0)return n.s;if(n.b!==void 0)return n.b;if(n.v!==void 0){if(n.v==="undefined")return;if(n.v==="null")return null;if(n.v==="NaN")return NaN;if(n.v==="Infinity")return 1/0;if(n.v==="-Infinity")return-1/0;if(n.v==="-0")return-0}if(n.d!==void 0)return new Date(n.d);if(n.r!==void 0)return new RegExp(n.r.p,n.r.f);if(n.a!==void 0)return n.a.map(i=>Xo(i,e));if(n.o!==void 0){const i={};for(const{k:s,v:a}of n.o)i[s]=Xo(a,e);return i}return n.h!==void 0?e===void 0?"<object>":e[n.h]:"<object>"}const jy=new Map;function rc({name:n,items:e=[],id:i,render:s,icon:a,isError:o,isWarning:u,isInfo:f,selectedItem:d,onAccepted:p,onSelected:m,onHighlighted:y,onIconClicked:b,noItemsMessage:w,dataTestId:E,notSelectable:x,ariaLabel:_}){const k=U.useRef(null),[C,V]=U.useState();return U.useEffect(()=>{y==null||y(C)},[y,C]),U.useEffect(()=>{const I=k.current;if(!I)return;const B=()=>{jy.set(n,I.scrollTop)};return I.addEventListener("scroll",B,{passive:!0}),()=>I.removeEventListener("scroll",B)},[n]),U.useEffect(()=>{k.current&&(k.current.scrollTop=jy.get(n)||0)},[n]),v.jsx("div",{className:Ke("list-view vbox",n+"-list-view"),role:e.length>0?"list":void 0,"aria-label":_,children:v.jsxs("div",{className:Ke("list-view-content",x&&"not-selectable"),tabIndex:0,onKeyDown:I=>{var $;if(d&&I.key==="Enter"){p==null||p(d,e.indexOf(d));return}if(I.key!=="ArrowDown"&&I.key!=="ArrowUp")return;I.stopPropagation(),I.preventDefault();const B=d?e.indexOf(d):-1;let G=B;I.key==="ArrowDown"&&(B===-1?G=0:G=Math.min(B+1,e.length-1)),I.key==="ArrowUp"&&(B===-1?G=e.length-1:G=Math.max(B-1,0));const J=($=k.current)==null?void 0:$.children.item(G);S0(J||void 0),y==null||y(void 0),m==null||m(e[G],G),V(void 0)},ref:k,children:[w&&e.length===0&&v.jsx("div",{className:"list-view-empty",children:w}),e.map((I,B)=>{const G=s(I,B);return v.jsxs("div",{onDoubleClick:()=>p==null?void 0:p(I,B),role:"listitem",className:Ke("list-view-entry",d===I&&"selected",!x&&C===I&&"highlighted",(o==null?void 0:o(I,B))&&"error",(u==null?void 0:u(I,B))&&"warning",(f==null?void 0:f(I,B))&&"info"),"aria-selected":d===I,onClick:()=>m==null?void 0:m(I,B),onMouseEnter:()=>V(I),onMouseLeave:()=>V(void 0),children:[a&&v.jsx("div",{className:"codicon "+(a(I,B)||"codicon-blank"),style:{minWidth:16,marginRight:4},onDoubleClick:J=>{J.preventDefault(),J.stopPropagation()},onClick:J=>{J.stopPropagation(),J.preventDefault(),b==null||b(I,B)}}),typeof G=="string"?v.jsx("div",{style:{textOverflow:"ellipsis",overflow:"hidden"},children:G}):G]},(i==null?void 0:i(I,B))||B)})]})})}const Hx=rc,qx=({action:n,isLive:e})=>{const i=U.useMemo(()=>{var u;if(!n||!n.log.length)return[];const s=n.log,a=n.context.wallTime-n.context.startTime,o=[];for(let f=0;f<s.length;++f){let d="";if(s[f].time!==-1){const p=(u=s[f])==null?void 0:u.time;f+1<s.length?d=_t(s[f+1].time-p):n.endTime>0?d=_t(n.endTime-p):e?d=_t(Date.now()-a-p):d="-"}o.push({message:s[f].message,time:d})}return o},[n,e]);return i.length?v.jsx(Hx,{name:"log",ariaLabel:"Log entries",items:i,render:s=>v.jsxs("div",{className:"log-list-item",children:[v.jsx("span",{className:"log-list-duration",children:s.time}),s.message]}),notSelectable:!0}):v.jsx(ns,{text:"No log entries"})};function Pa(n,e){const i=/(\x1b\[(\d+(;\d+)*)m)|([^\x1b]+)/g,s=[];let a,o={},u=!1,f=e==null?void 0:e.fg,d=e==null?void 0:e.bg;for(;(a=i.exec(n))!==null;){const[,,p,,m]=a;if(p){const y=+p;switch(y){case 0:o={};break;case 1:o["font-weight"]="bold";break;case 2:o.opacity="0.8";break;case 3:o["font-style"]="italic";break;case 4:o["text-decoration"]="underline";break;case 7:u=!0;break;case 8:o.display="none";break;case 9:o["text-decoration"]="line-through";break;case 22:delete o["font-weight"],delete o["font-style"],delete o.opacity,delete o["text-decoration"];break;case 23:delete o["font-weight"],delete o["font-style"],delete o.opacity;break;case 24:delete o["text-decoration"];break;case 27:u=!1;break;case 30:case 31:case 32:case 33:case 34:case 35:case 36:case 37:f=Ly[y-30];break;case 39:f=e==null?void 0:e.fg;break;case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:d=Ly[y-40];break;case 49:d=e==null?void 0:e.bg;break;case 53:o["text-decoration"]="overline";break;case 90:case 91:case 92:case 93:case 94:case 95:case 96:case 97:f=Dy[y-90];break;case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:d=Dy[y-100];break}}else if(m){const y={...o},b=u?d:f;b!==void 0&&(y.color=b);const w=u?f:d;w!==void 0&&(y["background-color"]=w),s.push(`<span style="${Ix(y)}">${$x(m)}</span>`)}}return s.join("")}const Ly={0:"var(--vscode-terminal-ansiBlack)",1:"var(--vscode-terminal-ansiRed)",2:"var(--vscode-terminal-ansiGreen)",3:"var(--vscode-terminal-ansiYellow)",4:"var(--vscode-terminal-ansiBlue)",5:"var(--vscode-terminal-ansiMagenta)",6:"var(--vscode-terminal-ansiCyan)",7:"var(--vscode-terminal-ansiWhite)"},Dy={0:"var(--vscode-terminal-ansiBrightBlack)",1:"var(--vscode-terminal-ansiBrightRed)",2:"var(--vscode-terminal-ansiBrightGreen)",3:"var(--vscode-terminal-ansiBrightYellow)",4:"var(--vscode-terminal-ansiBrightBlue)",5:"var(--vscode-terminal-ansiBrightMagenta)",6:"var(--vscode-terminal-ansiBrightCyan)",7:"var(--vscode-terminal-ansiBrightWhite)"};function $x(n){return n.replace(/[&"<>]/g,e=>({"&":"&",'"':""","<":"<",">":">"})[e])}function Ix(n){return Object.entries(n).map(([e,i])=>`${e}: ${i}`).join("; ")}const Vx=({error:n})=>{const e=U.useMemo(()=>Pa(n),[n]);return v.jsx("div",{className:"error-message",dangerouslySetInnerHTML:{__html:e||""}})},W0=({cursor:n,onPaneMouseMove:e,onPaneMouseUp:i,onPaneDoubleClick:s})=>(Ut.useEffect(()=>{const a=document.createElement("div");return a.style.position="fixed",a.style.top="0",a.style.right="0",a.style.bottom="0",a.style.left="0",a.style.zIndex="9999",a.style.cursor=n,document.body.appendChild(a),e&&a.addEventListener("mousemove",e),i&&a.addEventListener("mouseup",i),s&&document.body.addEventListener("dblclick",s),()=>{e&&a.removeEventListener("mousemove",e),i&&a.removeEventListener("mouseup",i),s&&document.body.removeEventListener("dblclick",s),document.body.removeChild(a)}},[n,e,i,s]),v.jsx(v.Fragment,{})),Gx={position:"absolute",top:0,right:0,bottom:0,left:0},eb=({orientation:n,offsets:e,setOffsets:i,resizerColor:s,resizerWidth:a,minColumnWidth:o})=>{const u=o||0,[f,d]=Ut.useState(null),[p,m]=ts(),y={position:"absolute",right:n==="horizontal"?void 0:0,bottom:n==="horizontal"?0:void 0,width:n==="horizontal"?7:void 0,height:n==="horizontal"?void 0:7,borderTopWidth:n==="horizontal"?void 0:(7-a)/2,borderRightWidth:n==="horizontal"?(7-a)/2:void 0,borderBottomWidth:n==="horizontal"?void 0:(7-a)/2,borderLeftWidth:n==="horizontal"?(7-a)/2:void 0,borderColor:"transparent",borderStyle:"solid",cursor:n==="horizontal"?"ew-resize":"ns-resize"};return v.jsxs("div",{style:{position:"absolute",top:0,right:0,bottom:0,left:-(7-a)/2,zIndex:100,pointerEvents:"none"},ref:m,children:[!!f&&v.jsx(W0,{cursor:n==="horizontal"?"ew-resize":"ns-resize",onPaneMouseUp:()=>d(null),onPaneMouseMove:b=>{if(!b.buttons)d(null);else if(f){const w=n==="horizontal"?b.clientX-f.clientX:b.clientY-f.clientY,E=f.offset+w,x=f.index>0?e[f.index-1]:0,_=n==="horizontal"?p.width:p.height,k=Math.min(Math.max(x+u,E),_-u)-e[f.index];for(let C=f.index;C<e.length;++C)e[C]=e[C]+k;i([...e])}}}),e.map((b,w)=>v.jsx("div",{style:{...y,top:n==="horizontal"?0:b,left:n==="horizontal"?b:0,pointerEvents:"initial"},onMouseDown:E=>d({clientX:E.clientX,clientY:E.clientY,offset:b,index:w}),children:v.jsx("div",{style:{...Gx,background:s}})},w))]})};async function Yf(n){const e=new Image;return n&&(e.src=n,await new Promise((i,s)=>{e.onload=i,e.onerror=i})),e}const ph={backgroundImage:`linear-gradient(45deg, #80808020 25%, transparent 25%),
|
|
53
53
|
linear-gradient(-45deg, #80808020 25%, transparent 25%),
|
|
54
54
|
linear-gradient(45deg, transparent 75%, #80808020 75%),
|
|
55
55
|
linear-gradient(-45deg, transparent 75%, #80808020 75%)`,backgroundSize:"20px 20px",backgroundPosition:"0 0, 0 10px, 10px -10px, -10px 0px",boxShadow:`rgb(0 0 0 / 10%) 0px 1.8px 1.9px,
|
|
56
56
|
rgb(0 0 0 / 15%) 0px 6.1px 6.3px,
|
|
57
57
|
rgb(0 0 0 / 10%) 0px -2px 4px,
|
|
58
58
|
rgb(0 0 0 / 15%) 0px -6.1px 12px,
|
|
59
|
-
rgb(0 0 0 / 25%) 0px 6px 12px`},Gx=({diff:n,noTargetBlank:e,hideDetails:i})=>{const[s,a]=U.useState(n.diff?"diff":"actual"),[o,u]=U.useState(!1),[f,d]=U.useState(null),[p,m]=U.useState("Expected"),[y,b]=U.useState(null),[w,E]=U.useState(null),[x,_]=ts();U.useEffect(()=>{(async()=>{var R,ee,re,j;d(await Yf((R=n.expected)==null?void 0:R.attachment.path)),m(((ee=n.expected)==null?void 0:ee.title)||"Expected"),b(await Yf((re=n.actual)==null?void 0:re.attachment.path)),E(await Yf((j=n.diff)==null?void 0:j.attachment.path))})()},[n]);const k=f&&y&&w,C=k?Math.max(f.naturalWidth,y.naturalWidth,200):500,V=k?Math.max(f.naturalHeight,y.naturalHeight,200):500,I=Math.min(1,(x.width-30)/C),B=Math.min(1,(x.width-50)/C/2),G=C*I,J=V*I,$={flex:"none",margin:"0 10px",cursor:"pointer",userSelect:"none"};return v.jsx("div",{"data-testid":"test-result-image-mismatch",style:{display:"flex",flexDirection:"column",alignItems:"center",flex:"auto"},ref:_,children:k&&v.jsxs(v.Fragment,{children:[v.jsxs("div",{"data-testid":"test-result-image-mismatch-tabs",style:{display:"flex",margin:"10px 0 20px"},children:[n.diff&&v.jsx("div",{style:{...$,fontWeight:s==="diff"?600:"initial"},onClick:()=>a("diff"),children:"Diff"}),v.jsx("div",{style:{...$,fontWeight:s==="actual"?600:"initial"},onClick:()=>a("actual"),children:"Actual"}),v.jsx("div",{style:{...$,fontWeight:s==="expected"?600:"initial"},onClick:()=>a("expected"),children:p}),v.jsx("div",{style:{...$,fontWeight:s==="sxs"?600:"initial"},onClick:()=>a("sxs"),children:"Side by side"}),v.jsx("div",{style:{...$,fontWeight:s==="slider"?600:"initial"},onClick:()=>a("slider"),children:"Slider"})]}),v.jsxs("div",{style:{display:"flex",justifyContent:"center",flex:"auto",minHeight:J+60},children:[n.diff&&s==="diff"&&v.jsx($n,{image:w,alt:"Diff",hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),n.diff&&s==="actual"&&v.jsx($n,{image:y,alt:"Actual",hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),n.diff&&s==="expected"&&v.jsx($n,{image:f,alt:p,hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),n.diff&&s==="slider"&&v.jsx(Kx,{expectedImage:f,actualImage:y,hideSize:i,canvasWidth:G,canvasHeight:J,scale:I,expectedTitle:p}),n.diff&&s==="sxs"&&v.jsxs("div",{style:{display:"flex"},children:[v.jsx($n,{image:f,title:p,hideSize:i,canvasWidth:B*C,canvasHeight:B*V,scale:B}),v.jsx($n,{image:o?w:y,title:o?"Diff":"Actual",onClick:()=>u(!o),hideSize:i,canvasWidth:B*C,canvasHeight:B*V,scale:B})]}),!n.diff&&s==="actual"&&v.jsx($n,{image:y,title:"Actual",hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),!n.diff&&s==="expected"&&v.jsx($n,{image:f,title:p,hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),!n.diff&&s==="sxs"&&v.jsxs("div",{style:{display:"flex"},children:[v.jsx($n,{image:f,title:p,canvasWidth:B*C,canvasHeight:B*V,scale:B}),v.jsx($n,{image:y,title:"Actual",canvasWidth:B*C,canvasHeight:B*V,scale:B})]})]}),!i&&v.jsxs("div",{style:{alignSelf:"start",lineHeight:"18px",marginLeft:"15px"},children:[v.jsx("div",{children:n.diff&&v.jsx("a",{target:"_blank",href:n.diff.attachment.path,rel:"noreferrer",children:n.diff.attachment.name})}),v.jsx("div",{children:v.jsx("a",{target:e?"":"_blank",href:n.actual.attachment.path,rel:"noreferrer",children:n.actual.attachment.name})}),v.jsx("div",{children:v.jsx("a",{target:e?"":"_blank",href:n.expected.attachment.path,rel:"noreferrer",children:n.expected.attachment.name})})]})]})})},Kx=({expectedImage:n,actualImage:e,canvasWidth:i,canvasHeight:s,scale:a,expectedTitle:o,hideSize:u})=>{const f={position:"absolute",top:0,left:0},[d,p]=U.useState(i/2),m=n.naturalWidth===e.naturalWidth&&n.naturalHeight===e.naturalHeight;return v.jsxs("div",{style:{flex:"none",display:"flex",alignItems:"center",flexDirection:"column",userSelect:"none"},children:[!u&&v.jsxs("div",{style:{margin:5},children:[!m&&v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"Expected "}),v.jsx("span",{children:n.naturalWidth}),v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),v.jsx("span",{children:n.naturalHeight}),!m&&v.jsx("span",{style:{flex:"none",margin:"0 5px 0 15px"},children:"Actual "}),!m&&v.jsx("span",{children:e.naturalWidth}),!m&&v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),!m&&v.jsx("span",{children:e.naturalHeight})]}),v.jsxs("div",{style:{position:"relative",width:i,height:s,margin:15,...ph},children:[v.jsx(eb,{orientation:"horizontal",offsets:[d],setOffsets:y=>p(y[0]),resizerColor:"#57606a80",resizerWidth:6}),v.jsx("img",{alt:o,style:{width:n.naturalWidth*a,height:n.naturalHeight*a},draggable:"false",src:n.src}),v.jsx("div",{style:{...f,bottom:0,overflow:"hidden",width:d,...ph},children:v.jsx("img",{alt:"Actual",style:{width:e.naturalWidth*a,height:e.naturalHeight*a},draggable:"false",src:e.src})})]})]})},$n=({image:n,title:e,alt:i,hideSize:s,canvasWidth:a,canvasHeight:o,scale:u,onClick:f})=>v.jsxs("div",{style:{flex:"none",display:"flex",alignItems:"center",flexDirection:"column"},children:[!s&&v.jsxs("div",{style:{margin:5},children:[e&&v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:e}),v.jsx("span",{children:n.naturalWidth}),v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),v.jsx("span",{children:n.naturalHeight})]}),v.jsx("div",{style:{display:"flex",flex:"none",width:a,height:o,margin:15,...ph},children:v.jsx("img",{width:n.naturalWidth*u,height:n.naturalHeight*u,alt:e||i,style:{cursor:f?"pointer":"initial"},draggable:"false",src:n.src,onClick:f})})]}),Yx="modulepreload",Xx=function(n,e){return new URL(n,e).href},By={},Px=function(e,i,s){let a=Promise.resolve();if(i&&i.length>0){let u=function(m){return Promise.all(m.map(y=>Promise.resolve(y).then(b=>({status:"fulfilled",value:b}),b=>({status:"rejected",reason:b}))))};const f=document.getElementsByTagName("link"),d=document.querySelector("meta[property=csp-nonce]"),p=(d==null?void 0:d.nonce)||(d==null?void 0:d.getAttribute("nonce"));a=u(i.map(m=>{if(m=Xx(m,s),m in By)return;By[m]=!0;const y=m.endsWith(".css"),b=y?'[rel="stylesheet"]':"";if(!!s)for(let x=f.length-1;x>=0;x--){const _=f[x];if(_.href===m&&(!y||_.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${m}"]${b}`))return;const E=document.createElement("link");if(E.rel=y?"stylesheet":Yx,y||(E.as="script"),E.crossOrigin="",E.href=m,p&&E.setAttribute("nonce",p),document.head.appendChild(E),y)return new Promise((x,_)=>{E.addEventListener("load",x),E.addEventListener("error",()=>_(new Error(`Unable to preload CSS for ${m}`)))})}))}function o(u){const f=new Event("vite:preloadError",{cancelable:!0});if(f.payload=u,window.dispatchEvent(f),!f.defaultPrevented)throw u}return a.then(u=>{for(const f of u||[])f.status==="rejected"&&o(f.reason);return e().catch(o)})},Fx=20,ur=({text:n,highlighter:e,mimeType:i,linkify:s,readOnly:a,highlight:o,revealLine:u,lineNumbers:f,isFocused:d,focusOnChange:p,wrapLines:m,onChange:y,dataTestId:b,placeholder:w})=>{const[E,x]=ts(),[_]=U.useState(Px(()=>import("./codeMirrorModule-CeWbQMSr.js"),__vite__mapDeps([0,1]),import.meta.url).then(I=>I.default)),k=U.useRef(null),[C,V]=U.useState();return U.useEffect(()=>{(async()=>{var $,R;const I=await _;Zx(I);const B=x.current;if(!B)return;const G=Wx(e)||Jx(i)||(s?"text/linkified":"");if(k.current&&G===k.current.cm.getOption("mode")&&!!a===k.current.cm.getOption("readOnly")&&f===k.current.cm.getOption("lineNumbers")&&m===k.current.cm.getOption("lineWrapping")&&w===k.current.cm.getOption("placeholder"))return;(R=($=k.current)==null?void 0:$.cm)==null||R.getWrapperElement().remove();const J=I(B,{value:"",mode:G,readOnly:!!a,lineNumbers:f,lineWrapping:m,placeholder:w});return k.current={cm:J},d&&J.focus(),V(J),J})()},[_,C,x,e,i,s,f,m,a,d,w]),U.useEffect(()=>{k.current&&k.current.cm.setSize(E.width,E.height)},[E]),U.useLayoutEffect(()=>{var G;if(!C)return;let I=!1;if(C.getValue()!==n&&(C.setValue(n),I=!0,p&&(C.execCommand("selectAll"),C.focus())),I||JSON.stringify(o)!==JSON.stringify(k.current.highlight)){for(const R of k.current.highlight||[])C.removeLineClass(R.line-1,"wrap");for(const R of o||[])C.addLineClass(R.line-1,"wrap",`source-line-${R.type}`);for(const R of k.current.widgets||[])C.removeLineWidget(R);for(const R of k.current.markers||[])R.clear();const J=[],$=[];for(const R of o||[]){if(R.type!=="subtle-error"&&R.type!=="error")continue;const ee=(G=k.current)==null?void 0:G.cm.getLine(R.line-1);if(ee){const re={};re.title=R.message||"",$.push(C.markText({line:R.line-1,ch:0},{line:R.line-1,ch:R.column||ee.length},{className:"source-line-error-underline",attributes:re}))}if(R.type==="error"){const re=document.createElement("div");re.innerHTML=Pa(R.message||""),re.className="source-line-error-widget",J.push(C.addLineWidget(R.line,re,{above:!0,coverGutter:!1}))}}k.current.highlight=o,k.current.widgets=J,k.current.markers=$}typeof u=="number"&&k.current.cm.lineCount()>=u&&C.scrollIntoView({line:Math.max(0,u-1),ch:0},50);let B;return y&&(B=()=>y(C.getValue()),C.on("change",B)),()=>{B&&C.off("change",B)}},[C,n,o,u,p,y]),v.jsx("div",{"data-testid":b,className:"cm-wrapper",ref:x,onClick:Qx})};function Qx(n){var i;if(!(n.target instanceof HTMLElement))return;let e;n.target.classList.contains("cm-linkified")?e=n.target.textContent:n.target.classList.contains("cm-link")&&((i=n.target.nextElementSibling)!=null&&i.classList.contains("cm-url"))&&(e=n.target.nextElementSibling.textContent.slice(1,-1)),e&&(n.preventDefault(),n.stopPropagation(),window.open(e,"_blank"))}let Uy=!1;function Zx(n){Uy||(Uy=!0,n.defineSimpleMode("text/linkified",{start:[{regex:w0,token:"linkified"}]}))}function Jx(n){if(n){if(n.includes("javascript")||n.includes("json"))return"javascript";if(n.includes("python"))return"python";if(n.includes("csharp"))return"text/x-csharp";if(n.includes("java"))return"text/x-java";if(n.includes("markdown"))return"markdown";if(n.includes("html")||n.includes("svg"))return"htmlmixed";if(n.includes("css"))return"css"}}function Wx(n){if(n)return{javascript:"javascript",jsonl:"javascript",python:"python",csharp:"text/x-csharp",java:"text/x-java",markdown:"markdown",html:"htmlmixed",css:"css",yaml:"yaml"}[n]}function e_(n){return!!n.match(/^(text\/.*?|application\/(json|(x-)?javascript|xml.*?|ecmascript|graphql|x-www-form-urlencoded)|image\/svg(\+xml)?|application\/.*?(\+json|\+xml))(;\s*charset=.*)?$/)}const t_=({title:n,children:e,setExpanded:i,expanded:s,expandOnTitleClick:a})=>{const o=U.useId(),u=U.useCallback(()=>i(!s),[s,i]),f=v.jsx("div",{className:Ke("codicon",s?"codicon-chevron-down":"codicon-chevron-right"),style:{cursor:"pointer",color:"var(--vscode-foreground)",marginLeft:"5px"},onClick:a?void 0:u});return v.jsxs("div",{className:Ke("expandable",s&&"expanded"),children:[a?v.jsxs("div",{role:"button","aria-expanded":s,"aria-controls":o,className:"expandable-title",onClick:u,children:[f,n]}):v.jsxs("div",{className:"expandable-title",children:[f,n]}),s&&v.jsx("div",{id:o,role:"region",style:{marginLeft:25},children:e})]})};function tb(n){const e=[];let i=0,s;for(;(s=w0.exec(n))!==null;){const o=n.substring(i,s.index);o&&e.push(o);const u=s[0];e.push(n_(u)),i=s.index+u.length}const a=n.substring(i);return a&&e.push(a),e}function n_(n){let e=n;return e.startsWith("www.")&&(e="https://"+e),v.jsx("a",{href:e,target:"_blank",rel:"noopener noreferrer",children:n})}const Xn=U.createContext(void 0),i_=({attachment:n,reveal:e})=>{const i=U.useContext(Xn),[s,a]=U.useState(!1),[o,u]=U.useState(null),[f,d]=U.useState(null),[p,m]=Ow(),y=U.useRef(null),b=e_(n.contentType),w=!!n.sha1||!!n.path;U.useEffect(()=>{var _;if(e)return(_=y.current)==null||_.scrollIntoView({behavior:"smooth"}),m()},[e,m]),U.useEffect(()=>{s&&o===null&&f===null&&(d("Loading ..."),fetch(ac(i,n)).then(_=>_.text()).then(_=>{u(_),d(null)}).catch(_=>{d("Failed to load: "+_.message)}))},[i,s,o,f,n]);const E=U.useMemo(()=>{const _=o?o.split(`
|
|
60
|
-
`).length:0;return Math.min(Math.max(5,_),20)*
|
|
59
|
+
rgb(0 0 0 / 25%) 0px 6px 12px`},Kx=({diff:n,noTargetBlank:e,hideDetails:i})=>{const[s,a]=U.useState(n.diff?"diff":"actual"),[o,u]=U.useState(!1),[f,d]=U.useState(null),[p,m]=U.useState("Expected"),[y,b]=U.useState(null),[w,E]=U.useState(null),[x,_]=ts();U.useEffect(()=>{(async()=>{var R,ee,re,j;d(await Yf((R=n.expected)==null?void 0:R.attachment.path)),m(((ee=n.expected)==null?void 0:ee.title)||"Expected"),b(await Yf((re=n.actual)==null?void 0:re.attachment.path)),E(await Yf((j=n.diff)==null?void 0:j.attachment.path))})()},[n]);const k=f&&y&&w,C=k?Math.max(f.naturalWidth,y.naturalWidth,200):500,V=k?Math.max(f.naturalHeight,y.naturalHeight,200):500,I=Math.min(1,(x.width-30)/C),B=Math.min(1,(x.width-50)/C/2),G=C*I,J=V*I,$={flex:"none",margin:"0 10px",cursor:"pointer",userSelect:"none"};return v.jsx("div",{"data-testid":"test-result-image-mismatch",style:{display:"flex",flexDirection:"column",alignItems:"center",flex:"auto"},ref:_,children:k&&v.jsxs(v.Fragment,{children:[v.jsxs("div",{"data-testid":"test-result-image-mismatch-tabs",style:{display:"flex",margin:"10px 0 20px"},children:[n.diff&&v.jsx("div",{style:{...$,fontWeight:s==="diff"?600:"initial"},onClick:()=>a("diff"),children:"Diff"}),v.jsx("div",{style:{...$,fontWeight:s==="actual"?600:"initial"},onClick:()=>a("actual"),children:"Actual"}),v.jsx("div",{style:{...$,fontWeight:s==="expected"?600:"initial"},onClick:()=>a("expected"),children:p}),v.jsx("div",{style:{...$,fontWeight:s==="sxs"?600:"initial"},onClick:()=>a("sxs"),children:"Side by side"}),v.jsx("div",{style:{...$,fontWeight:s==="slider"?600:"initial"},onClick:()=>a("slider"),children:"Slider"})]}),v.jsxs("div",{style:{display:"flex",justifyContent:"center",flex:"auto",minHeight:J+60},children:[n.diff&&s==="diff"&&v.jsx($n,{image:w,alt:"Diff",hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),n.diff&&s==="actual"&&v.jsx($n,{image:y,alt:"Actual",hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),n.diff&&s==="expected"&&v.jsx($n,{image:f,alt:p,hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),n.diff&&s==="slider"&&v.jsx(Yx,{expectedImage:f,actualImage:y,hideSize:i,canvasWidth:G,canvasHeight:J,scale:I,expectedTitle:p}),n.diff&&s==="sxs"&&v.jsxs("div",{style:{display:"flex"},children:[v.jsx($n,{image:f,title:p,hideSize:i,canvasWidth:B*C,canvasHeight:B*V,scale:B}),v.jsx($n,{image:o?w:y,title:o?"Diff":"Actual",onClick:()=>u(!o),hideSize:i,canvasWidth:B*C,canvasHeight:B*V,scale:B})]}),!n.diff&&s==="actual"&&v.jsx($n,{image:y,title:"Actual",hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),!n.diff&&s==="expected"&&v.jsx($n,{image:f,title:p,hideSize:i,canvasWidth:G,canvasHeight:J,scale:I}),!n.diff&&s==="sxs"&&v.jsxs("div",{style:{display:"flex"},children:[v.jsx($n,{image:f,title:p,canvasWidth:B*C,canvasHeight:B*V,scale:B}),v.jsx($n,{image:y,title:"Actual",canvasWidth:B*C,canvasHeight:B*V,scale:B})]})]}),!i&&v.jsxs("div",{style:{alignSelf:"start",lineHeight:"18px",marginLeft:"15px"},children:[v.jsx("div",{children:n.diff&&v.jsx("a",{target:"_blank",href:n.diff.attachment.path,rel:"noreferrer",children:n.diff.attachment.name})}),v.jsx("div",{children:v.jsx("a",{target:e?"":"_blank",href:n.actual.attachment.path,rel:"noreferrer",children:n.actual.attachment.name})}),v.jsx("div",{children:v.jsx("a",{target:e?"":"_blank",href:n.expected.attachment.path,rel:"noreferrer",children:n.expected.attachment.name})})]})]})})},Yx=({expectedImage:n,actualImage:e,canvasWidth:i,canvasHeight:s,scale:a,expectedTitle:o,hideSize:u})=>{const f={position:"absolute",top:0,left:0},[d,p]=U.useState(i/2),m=n.naturalWidth===e.naturalWidth&&n.naturalHeight===e.naturalHeight;return v.jsxs("div",{style:{flex:"none",display:"flex",alignItems:"center",flexDirection:"column",userSelect:"none"},children:[!u&&v.jsxs("div",{style:{margin:5},children:[!m&&v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"Expected "}),v.jsx("span",{children:n.naturalWidth}),v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),v.jsx("span",{children:n.naturalHeight}),!m&&v.jsx("span",{style:{flex:"none",margin:"0 5px 0 15px"},children:"Actual "}),!m&&v.jsx("span",{children:e.naturalWidth}),!m&&v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),!m&&v.jsx("span",{children:e.naturalHeight})]}),v.jsxs("div",{style:{position:"relative",width:i,height:s,margin:15,...ph},children:[v.jsx(eb,{orientation:"horizontal",offsets:[d],setOffsets:y=>p(y[0]),resizerColor:"#57606a80",resizerWidth:6}),v.jsx("img",{alt:o,style:{width:n.naturalWidth*a,height:n.naturalHeight*a},draggable:"false",src:n.src}),v.jsx("div",{style:{...f,bottom:0,overflow:"hidden",width:d,...ph},children:v.jsx("img",{alt:"Actual",style:{width:e.naturalWidth*a,height:e.naturalHeight*a},draggable:"false",src:e.src})})]})]})},$n=({image:n,title:e,alt:i,hideSize:s,canvasWidth:a,canvasHeight:o,scale:u,onClick:f})=>v.jsxs("div",{style:{flex:"none",display:"flex",alignItems:"center",flexDirection:"column"},children:[!s&&v.jsxs("div",{style:{margin:5},children:[e&&v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:e}),v.jsx("span",{children:n.naturalWidth}),v.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),v.jsx("span",{children:n.naturalHeight})]}),v.jsx("div",{style:{display:"flex",flex:"none",width:a,height:o,margin:15,...ph},children:v.jsx("img",{width:n.naturalWidth*u,height:n.naturalHeight*u,alt:e||i,style:{cursor:f?"pointer":"initial"},draggable:"false",src:n.src,onClick:f})})]}),Xx="modulepreload",Px=function(n,e){return new URL(n,e).href},By={},Fx=function(e,i,s){let a=Promise.resolve();if(i&&i.length>0){let u=function(m){return Promise.all(m.map(y=>Promise.resolve(y).then(b=>({status:"fulfilled",value:b}),b=>({status:"rejected",reason:b}))))};const f=document.getElementsByTagName("link"),d=document.querySelector("meta[property=csp-nonce]"),p=(d==null?void 0:d.nonce)||(d==null?void 0:d.getAttribute("nonce"));a=u(i.map(m=>{if(m=Px(m,s),m in By)return;By[m]=!0;const y=m.endsWith(".css"),b=y?'[rel="stylesheet"]':"";if(!!s)for(let x=f.length-1;x>=0;x--){const _=f[x];if(_.href===m&&(!y||_.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${m}"]${b}`))return;const E=document.createElement("link");if(E.rel=y?"stylesheet":Xx,y||(E.as="script"),E.crossOrigin="",E.href=m,p&&E.setAttribute("nonce",p),document.head.appendChild(E),y)return new Promise((x,_)=>{E.addEventListener("load",x),E.addEventListener("error",()=>_(new Error(`Unable to preload CSS for ${m}`)))})}))}function o(u){const f=new Event("vite:preloadError",{cancelable:!0});if(f.payload=u,window.dispatchEvent(f),!f.defaultPrevented)throw u}return a.then(u=>{for(const f of u||[])f.status==="rejected"&&o(f.reason);return e().catch(o)})},Qx=20,ur=({text:n,highlighter:e,mimeType:i,linkify:s,readOnly:a,highlight:o,revealLine:u,lineNumbers:f,isFocused:d,focusOnChange:p,wrapLines:m,onChange:y,dataTestId:b,placeholder:w})=>{const[E,x]=ts(),[_]=U.useState(Fx(()=>import("./codeMirrorModule-Cw-6jrKz.js"),__vite__mapDeps([0,1]),import.meta.url).then(I=>I.default)),k=U.useRef(null),[C,V]=U.useState();return U.useEffect(()=>{(async()=>{var $,R;const I=await _;Jx(I);const B=x.current;if(!B)return;const G=e_(e)||Wx(i)||(s?"text/linkified":"");if(k.current&&G===k.current.cm.getOption("mode")&&!!a===k.current.cm.getOption("readOnly")&&f===k.current.cm.getOption("lineNumbers")&&m===k.current.cm.getOption("lineWrapping")&&w===k.current.cm.getOption("placeholder"))return;(R=($=k.current)==null?void 0:$.cm)==null||R.getWrapperElement().remove();const J=I(B,{value:"",mode:G,readOnly:!!a,lineNumbers:f,lineWrapping:m,placeholder:w,matchBrackets:!0,autoCloseBrackets:!0});return k.current={cm:J},d&&J.focus(),V(J),J})()},[_,C,x,e,i,s,f,m,a,d,w]),U.useEffect(()=>{k.current&&k.current.cm.setSize(E.width,E.height)},[E]),U.useLayoutEffect(()=>{var G;if(!C)return;let I=!1;if(C.getValue()!==n&&(C.setValue(n),I=!0,p&&(C.execCommand("selectAll"),C.focus())),I||JSON.stringify(o)!==JSON.stringify(k.current.highlight)){for(const R of k.current.highlight||[])C.removeLineClass(R.line-1,"wrap");for(const R of o||[])C.addLineClass(R.line-1,"wrap",`source-line-${R.type}`);for(const R of k.current.widgets||[])C.removeLineWidget(R);for(const R of k.current.markers||[])R.clear();const J=[],$=[];for(const R of o||[]){if(R.type!=="subtle-error"&&R.type!=="error")continue;const ee=(G=k.current)==null?void 0:G.cm.getLine(R.line-1);if(ee){const re={};re.title=R.message||"",$.push(C.markText({line:R.line-1,ch:0},{line:R.line-1,ch:R.column||ee.length},{className:"source-line-error-underline",attributes:re}))}if(R.type==="error"){const re=document.createElement("div");re.innerHTML=Pa(R.message||""),re.className="source-line-error-widget",J.push(C.addLineWidget(R.line,re,{above:!0,coverGutter:!1}))}}k.current.highlight=o,k.current.widgets=J,k.current.markers=$}typeof u=="number"&&k.current.cm.lineCount()>=u&&C.scrollIntoView({line:Math.max(0,u-1),ch:0},50);let B;return y&&(B=()=>y(C.getValue()),C.on("change",B)),()=>{B&&C.off("change",B)}},[C,n,o,u,p,y]),v.jsx("div",{"data-testid":b,className:"cm-wrapper",ref:x,onClick:Zx})};function Zx(n){var i;if(!(n.target instanceof HTMLElement))return;let e;n.target.classList.contains("cm-linkified")?e=n.target.textContent:n.target.classList.contains("cm-link")&&((i=n.target.nextElementSibling)!=null&&i.classList.contains("cm-url"))&&(e=n.target.nextElementSibling.textContent.slice(1,-1)),e&&(n.preventDefault(),n.stopPropagation(),window.open(e,"_blank"))}let Uy=!1;function Jx(n){Uy||(Uy=!0,n.defineSimpleMode("text/linkified",{start:[{regex:w0,token:"linkified"}]}))}function Wx(n){if(n){if(n.includes("javascript")||n.includes("json"))return"javascript";if(n.includes("python"))return"python";if(n.includes("csharp"))return"text/x-csharp";if(n.includes("java"))return"text/x-java";if(n.includes("markdown"))return"markdown";if(n.includes("html")||n.includes("svg"))return"htmlmixed";if(n.includes("css"))return"css"}}function e_(n){if(n)return{javascript:"javascript",jsonl:"javascript",python:"python",csharp:"text/x-csharp",java:"text/x-java",markdown:"markdown",html:"htmlmixed",css:"css",yaml:"yaml"}[n]}function t_(n){return!!n.match(/^(text\/.*?|application\/(json|(x-)?javascript|xml.*?|ecmascript|graphql|x-www-form-urlencoded)|image\/svg(\+xml)?|application\/.*?(\+json|\+xml))(;\s*charset=.*)?$/)}const n_=({title:n,children:e,setExpanded:i,expanded:s,expandOnTitleClick:a})=>{const o=U.useId(),u=U.useCallback(()=>i(!s),[s,i]),f=v.jsx("div",{className:Ke("codicon",s?"codicon-chevron-down":"codicon-chevron-right"),style:{cursor:"pointer",color:"var(--vscode-foreground)",marginLeft:"5px"},onClick:a?void 0:u});return v.jsxs("div",{className:Ke("expandable",s&&"expanded"),children:[a?v.jsxs("div",{role:"button","aria-expanded":s,"aria-controls":o,className:"expandable-title",onClick:u,children:[f,n]}):v.jsxs("div",{className:"expandable-title",children:[f,n]}),s&&v.jsx("div",{id:o,role:"region",style:{marginLeft:25},children:e})]})};function tb(n){const e=[];let i=0,s;for(;(s=w0.exec(n))!==null;){const o=n.substring(i,s.index);o&&e.push(o);const u=s[0];e.push(i_(u)),i=s.index+u.length}const a=n.substring(i);return a&&e.push(a),e}function i_(n){let e=n;return e.startsWith("www.")&&(e="https://"+e),v.jsx("a",{href:e,target:"_blank",rel:"noopener noreferrer",children:n})}const Xn=U.createContext(void 0),s_=({attachment:n,reveal:e})=>{const i=U.useContext(Xn),[s,a]=U.useState(!1),[o,u]=U.useState(null),[f,d]=U.useState(null),[p,m]=Rw(),y=U.useRef(null),b=t_(n.contentType),w=!!n.sha1||!!n.path;U.useEffect(()=>{var _;if(e)return(_=y.current)==null||_.scrollIntoView({behavior:"smooth"}),m()},[e,m]),U.useEffect(()=>{s&&o===null&&f===null&&(d("Loading ..."),fetch(ac(i,n)).then(_=>_.text()).then(_=>{u(_),d(null)}).catch(_=>{d("Failed to load: "+_.message)}))},[i,s,o,f,n]);const E=U.useMemo(()=>{const _=o?o.split(`
|
|
60
|
+
`).length:0;return Math.min(Math.max(5,_),20)*Qx},[o]),x=v.jsxs("span",{style:{marginLeft:5},ref:y,"aria-label":n.name,children:[v.jsx("span",{children:tb(n.name)}),w&&v.jsx("a",{style:{marginLeft:5},href:Lo(i,n),children:"download"})]});return!b||!w?v.jsx("div",{style:{marginLeft:20},children:x}):v.jsxs("div",{className:Ke(p&&"yellow-flash"),children:[v.jsx(n_,{title:x,expanded:s,setExpanded:a,expandOnTitleClick:!0,children:f&&v.jsx("i",{children:f})}),s&&o!==null&&v.jsx("div",{className:"vbox",style:{height:E},children:v.jsx(ur,{text:o,readOnly:!0,mimeType:n.contentType,linkify:!0,lineNumbers:!0,wrapLines:!1})})]})},r_=({revealedAttachment:n})=>{const e=U.useContext(Xn),{diffMap:i,screenshots:s,attachments:a}=U.useMemo(()=>{const o=new Set((e==null?void 0:e.visibleAttachments)??[]),u=new Set,f=new Map;for(const d of o){if(!d.path&&!d.sha1)continue;const p=d.name.match(/^(.*)-(expected|actual|diff)\.png$/);if(p){const m=p[1],y=p[2],b=f.get(m)||{expected:void 0,actual:void 0,diff:void 0};b[y]=d,f.set(m,b),o.delete(d)}else d.contentType.startsWith("image/")&&(u.add(d),o.delete(d))}return{diffMap:f,attachments:o,screenshots:u}},[e]);return!i.size&&!s.size&&!a.size?v.jsx(ns,{text:"No attachments"}):v.jsxs("div",{className:"attachments-tab",children:[[...i.values()].map(({expected:o,actual:u,diff:f})=>v.jsxs(v.Fragment,{children:[o&&u&&v.jsx("div",{className:"attachments-section",children:"Image diff"}),o&&u&&v.jsx(Kx,{noTargetBlank:!0,diff:{name:"Image diff",expected:{attachment:{...o,path:Lo(e,o)},title:"Expected"},actual:{attachment:{...u,path:Lo(e,u)}},diff:f?{attachment:{...f,path:Lo(e,f)}}:void 0}})]})),s.size?v.jsx("div",{className:"attachments-section",children:"Screenshots"}):void 0,[...s.values()].map((o,u)=>{const f=ac(e,o);return v.jsxs("div",{className:"attachment-item",children:[v.jsx("div",{children:v.jsx("img",{draggable:"false",src:f})}),v.jsx("div",{children:v.jsx("a",{target:"_blank",href:f,rel:"noreferrer",children:o.name})})]},`screenshot-${u}`)}),a.size?v.jsx("div",{className:"attachments-section",children:"Attachments"}):void 0,[...a.values()].map((o,u)=>v.jsx("div",{className:"attachment-item",children:v.jsx(s_,{attachment:o,reveal:n&&a_(o,n[0])?n:void 0})},l_(o,u)))]})};function a_(n,e){return n.name===e.name&&n.path===e.path&&n.sha1===e.sha1}function ac(n,e){return n&&e.sha1?n.createRelativeUrl(`sha1/${e.sha1}`):`file?path=${encodeURIComponent(e.path)}`}function Lo(n,e){let i=e.contentType?`&dn=${encodeURIComponent(e.name)}`:"";return e.contentType&&(i+=`&dct=${encodeURIComponent(e.contentType)}`),ac(n,e)+i}function l_(n,e){return e+"-"+(n.sha1?"sha1-"+n.sha1:"path-"+n.path)}const o_=`
|
|
61
61
|
# Instructions
|
|
62
62
|
|
|
63
63
|
- Following Playwright test failed.
|
|
64
64
|
- Explain why, be concise, respect Playwright best practices.
|
|
65
65
|
- Provide a snippet of code with the fix, if possible.
|
|
66
|
-
`.trimStart();async function
|
|
66
|
+
`.trimStart();async function c_({testInfo:n,metadata:e,errorContext:i,errors:s,buildCodeFrame:a,stdout:o,stderr:u}){var y;const f=new Set(s.filter(b=>b.message&&!b.message.includes(`
|
|
67
67
|
`)).map(b=>b.message));for(const b of s)for(const w of f.keys())(y=b.message)!=null&&y.includes(w)&&f.delete(w);const d=s.filter(b=>!(!b.message||!b.message.includes(`
|
|
68
|
-
`)&&!f.has(b.message)));if(!d.length)return;const p=[
|
|
69
|
-
`)}const
|
|
70
|
-
`)[0]||void 0,location:m,linesAbove:100,linesBelow:100})},[o]),d=Io(()=>
|
|
68
|
+
`)&&!f.has(b.message)));if(!d.length)return;const p=[o_,"# Test info","",n];o&&p.push("","# Stdout","","```",Do(o),"```"),u&&p.push("","# Stderr","","```",Do(u),"```"),p.push("","# Error details");for(const b of d)p.push("","```",Do(b.message||""),"```");i&&p.push(i);const m=await a(d[d.length-1]);return m&&p.push("","# Test source","","```ts",m,"```"),e!=null&&e.gitDiff&&p.push("","# Local changes","","```diff",e.gitDiff,"```"),p.join(`
|
|
69
|
+
`)}const u_=new RegExp("([\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)|(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~])))","g");function Do(n){return n.replace(u_,"")}const f_=rc,h_=({stack:n,setSelectedFrame:e,selectedFrame:i})=>{const s=n||[];return v.jsx(f_,{name:"stack-trace",ariaLabel:"Stack trace",items:s,selectedItem:s[i],render:a=>{const o=a.file[1]===":"?"\\":"/";return v.jsxs(v.Fragment,{children:[v.jsx("span",{className:"stack-trace-frame-function",children:a.function||"(anonymous)"}),v.jsx("span",{className:"stack-trace-frame-location",children:a.file.split(o).pop()}),v.jsx("span",{className:"stack-trace-frame-line",children:":"+a.line})]})},onSelected:a=>e(s.indexOf(a))})},Uh=({noShadow:n,children:e,noMinHeight:i,className:s,sidebarBackground:a,onClick:o})=>v.jsx("div",{className:Ke("toolbar",n&&"no-shadow",i&&"no-min-height",s,a&&"toolbar-sidebar-background"),onClick:o,children:e});function d_(n,e,i,s,a){const o=U.useContext(Xn);return Io(async()=>{var w,E,x,_;const u=n==null?void 0:n[e],f=u!=null&&u.file?u:a;if(!f)return{source:{file:"",errors:[],content:void 0},targetLine:0,highlight:[]};const d=f.file;let p=i.get(d);p||(p={errors:((w=a==null?void 0:a.source)==null?void 0:w.errors)||[],content:(E=a==null?void 0:a.source)==null?void 0:E.content},i.set(d,p));const m=(f==null?void 0:f.line)||((x=p.errors[0])==null?void 0:x.line)||0,y=s&&d.startsWith(s)?d.substring(s.length+1):d,b=p.errors.map(k=>({type:"error",line:k.line,message:k.message}));if(b.push({line:m,type:"running"}),((_=a==null?void 0:a.source)==null?void 0:_.content)!==void 0)p.content=a.source.content;else if(p.content===void 0||f===a){const k=await nb(d);try{let C=o?await fetch(o.createRelativeUrl(`sha1/src@${k}.txt`)):void 0;(!C||C.status===404)&&(C=await fetch(`file?path=${encodeURIComponent(d)}`)),C.status>=400?p.content=`<Unable to read "${d}">`:p.content=await C.text()}catch{p.content=`<Unable to read "${d}">`}}return{model:o,source:p,highlight:b,targetLine:m,fileName:y,location:f}},[n,e,s,a],{source:{errors:[],content:"Loading…"},highlight:[]})}const p_=({stack:n,sources:e,rootDir:i,fallbackLocation:s,stackFrameLocation:a,onOpenExternally:o})=>{const[u,f]=U.useState(),[d,p]=U.useState(0);U.useEffect(()=>{u!==n&&(f(n),p(0))},[n,u,f,p]);const{source:m,highlight:y,targetLine:b,fileName:w,location:E}=d_(n,d,e,i,s),x=U.useCallback(()=>{E&&(o?o(E):window.location.href=`vscode://file//${E.file}:${E.line}`)},[o,E]),_=((n==null?void 0:n.length)??0)>1,k=g_(w);return v.jsx(Vo,{sidebarSize:200,orientation:a==="bottom"?"vertical":"horizontal",sidebarHidden:!_,main:v.jsxs("div",{className:"vbox","data-testid":"source-code",children:[w&&v.jsxs(Uh,{children:[v.jsx("div",{className:"source-tab-file-name",title:w,children:v.jsx("div",{children:k})}),v.jsx(Bh,{description:"Copy filename",value:k}),E&&v.jsx(zt,{icon:"link-external",title:"Open in VS Code",onClick:x})]}),v.jsx(ur,{text:m.content||"",highlighter:"javascript",highlight:y,revealLine:b,readOnly:!0,lineNumbers:!0,dataTestId:"source-code-mirror"})]}),sidebar:v.jsx(h_,{stack:n,selectedFrame:d,setSelectedFrame:p})})};async function nb(n){const e=new TextEncoder().encode(n),i=await crypto.subtle.digest("SHA-1",e),s=[],a=new DataView(i);for(let o=0;o<a.byteLength;o+=1){const u=a.getUint8(o).toString(16).padStart(2,"0");s.push(u)}return s.join("")}function g_(n){if(!n)return"";const e=n!=null&&n.includes("/")?"/":"\\";return(n==null?void 0:n.split(e).pop())??""}const m_=({prompt:n})=>v.jsx(jo,{value:n,description:"Copy prompt",copiedDescription:v.jsxs(v.Fragment,{children:["Copied ",v.jsx("span",{className:"codicon codicon-copy",style:{marginLeft:"5px"}})]}),style:{width:"120px",justifyContent:"center"}});function y_(n){return U.useMemo(()=>{if(!n)return{errors:new Map};const e=new Map;for(const i of n.errorDescriptors)e.set(i.message,i);return{errors:e}},[n])}function b_({message:n,error:e,sdkLanguage:i,revealInSource:s}){var f;let a,o;const u=(f=e.stack)==null?void 0:f[0];return u&&(a=u.file.replace(/.*[/\\](.*)/,"$1")+":"+u.line,o=u.file+":"+u.line),v.jsxs("div",{style:{display:"flex",flexDirection:"column",overflowX:"clip"},children:[v.jsxs("div",{className:"hbox",style:{alignItems:"center",padding:"5px 10px",minHeight:36,fontWeight:"bold",color:"var(--vscode-errorForeground)",flex:0},children:[e.action&&Dh(e.action,{sdkLanguage:i}),a&&v.jsxs("div",{className:"action-location",children:["@ ",v.jsx("span",{title:o,onClick:()=>s(e),children:a})]})]}),v.jsx(Vx,{error:n})]})}const v_=({errorsModel:n,sdkLanguage:e,revealInSource:i,wallTime:s,testRunMetadata:a})=>{const o=U.useContext(Xn),u=Io(async()=>{const p=o==null?void 0:o.attachments.find(m=>m.name==="error-context");if(p)return await fetch(ac(o,p)).then(m=>m.text())},[o],void 0),f=U.useCallback(async p=>{var w;const m=(w=p.stack)==null?void 0:w[0];if(!m)return;let y=o?await fetch(o.createRelativeUrl(`sha1/src@${await nb(m.file)}.txt`)):void 0;if((!y||y.status===404)&&(y=await fetch(`file?path=${encodeURIComponent(m.file)}`)),y.status>=400)return;const b=await y.text();return S_({source:b,message:Do(p.message).split(`
|
|
70
|
+
`)[0]||void 0,location:m,linesAbove:100,linesBelow:100})},[o]),d=Io(()=>c_({testInfo:(o==null?void 0:o.title)??"",metadata:a,errorContext:u,errors:(o==null?void 0:o.errorDescriptors)??[],buildCodeFrame:f}),[u,a,o,f],void 0);return n.errors.size?v.jsxs("div",{className:"fill",style:{overflow:"auto"},children:[v.jsx("span",{style:{position:"absolute",right:"5px",top:"5px",zIndex:1},children:d&&v.jsx(m_,{prompt:d})}),[...n.errors.entries()].map(([p,m])=>{const y=`error-${s}-${p}`;return v.jsx(b_,{message:p,error:m,revealInSource:i,sdkLanguage:e},y)})]}):v.jsx(ns,{text:"No errors"})};function S_({source:n,message:e,location:i,linesAbove:s,linesBelow:a}){const o=n.split(`
|
|
71
71
|
`).slice(),u=Math.max(0,i.line-s-1),f=Math.min(o.length,i.line+a),d=o.slice(u,f),p=String(f).length,m=d.map((y,b)=>`${u+b+1===i.line?"> ":" "}${(u+b+1).toString().padEnd(p," ")} | ${y}`);return e&&m.splice(i.line-u,0,`${" ".repeat(p+2)} | ${" ".repeat(i.column-2)} ^ ${e}`),m.join(`
|
|
72
|
-
`)}const
|
|
72
|
+
`)}const w_=rc;function x_(n,e){const{entries:i}=U.useMemo(()=>{if(!n)return{entries:[]};const a=[];function o(f){var m,y,b,w,E,x;const d=a[a.length-1];d&&((m=f.browserMessage)==null?void 0:m.bodyString)===((y=d.browserMessage)==null?void 0:y.bodyString)&&((b=f.browserMessage)==null?void 0:b.location)===((w=d.browserMessage)==null?void 0:w.location)&&f.browserError===d.browserError&&((E=f.nodeMessage)==null?void 0:E.html)===((x=d.nodeMessage)==null?void 0:x.html)&&f.isError===d.isError&&f.isWarning===d.isWarning&&f.timestamp-d.timestamp<1e3?d.repeat++:a.push({...f,repeat:1})}const u=[...n.events,...n.stdio].sort((f,d)=>{const p="time"in f?f.time:f.timestamp,m="time"in d?d.time:d.timestamp;return p-m});for(const f of u){if(f.type==="console"){const d=f.args&&f.args.length?T_(f.args):ib(f.text),p=f.location.url,y=`${p?p.substring(p.lastIndexOf("/")+1):"<anonymous>"}:${f.location.lineNumber}`;o({browserMessage:{body:d,bodyString:f.text,location:y},isError:f.messageType==="error",isWarning:f.messageType==="warning",timestamp:f.time})}if(f.type==="event"&&f.method==="pageError"&&o({browserError:f.params.error,isError:!0,isWarning:!1,timestamp:f.time}),f.type==="stderr"||f.type==="stdout"){let d="";f.text&&(d=Pa(f.text.trim())||""),f.base64&&(d=Pa(atob(f.base64).trim())||""),o({nodeMessage:{html:d},isError:f.type==="stderr",isWarning:!1,timestamp:f.timestamp})}}return{entries:a}},[n]);return{entries:U.useMemo(()=>e?i.filter(a=>a.timestamp>=e.minimum&&a.timestamp<=e.maximum):i,[i,e])}}const __=({consoleModel:n,boundaries:e,onEntryHovered:i,onAccepted:s})=>n.entries.length?v.jsx("div",{className:"console-tab",children:v.jsx(w_,{name:"console",onAccepted:s,onHighlighted:i,items:n.entries,isError:a=>a.isError,isWarning:a=>a.isWarning,render:a=>{const o=_t(a.timestamp-e.minimum),u=v.jsx("span",{className:"console-time",children:o}),f=a.isError?"status-error":a.isWarning?"status-warning":"status-none",d=a.browserMessage||a.browserError?v.jsx("span",{className:Ke("codicon","codicon-browser",f),title:"Browser message"}):v.jsx("span",{className:Ke("codicon","codicon-file",f),title:"Runner message"});let p,m,y,b;const{browserMessage:w,browserError:E,nodeMessage:x}=a;if(w&&(p=w.location,m=w.body),E){const{error:_,value:k}=E;_?(m=_.message,b=_.stack):m=String(k)}return x&&(y=x.html),v.jsxs("div",{className:"console-line",children:[u,d,p&&v.jsx("span",{className:"console-location",children:p}),a.repeat>1&&v.jsx("span",{className:"console-repeat",children:a.repeat}),m&&v.jsx("span",{className:"console-line-message",children:m}),y&&v.jsx("span",{className:"console-line-message",dangerouslySetInnerHTML:{__html:y}}),b&&v.jsx("div",{className:"console-stack",children:b})]})}})}):v.jsx(ns,{text:"No console entries"});function T_(n){if(n.length===1)return ib(n[0].preview);const e=typeof n[0].value=="string"&&n[0].value.includes("%"),i=e?n[0].value:"",s=e?n.slice(1):n;let a=0;const o=/%([%sdifoOc])/g;let u;const f=[];let d=[];f.push(v.jsx("span",{children:d},f.length+1));let p=0;for(;(u=o.exec(i))!==null;){const m=i.substring(p,u.index);d.push(v.jsx("span",{children:m},d.length+1)),p=u.index+2;const y=u[0][1];if(y==="%")d.push(v.jsx("span",{children:"%"},d.length+1));else if(y==="s"||y==="o"||y==="O"||y==="d"||y==="i"||y==="f"){const b=s[a++],w={};typeof(b==null?void 0:b.value)!="string"&&(w.color="var(--vscode-debugTokenExpression-number)"),d.push(v.jsx("span",{style:w,children:(b==null?void 0:b.preview)||""},d.length+1))}else if(y==="c"){d=[];const b=s[a++],w=b?E_(b.preview):{};f.push(v.jsx("span",{style:w,children:d},f.length+1))}}for(p<i.length&&d.push(v.jsx("span",{children:i.substring(p)},d.length+1));a<s.length;a++){const m=s[a],y={};d.length&&d.push(v.jsx("span",{children:" "},d.length+1)),typeof(m==null?void 0:m.value)!="string"&&(y.color="var(--vscode-debugTokenExpression-number)"),d.push(v.jsx("span",{style:y,children:(m==null?void 0:m.preview)||""},d.length+1))}return f}function ib(n){return[v.jsx("span",{dangerouslySetInnerHTML:{__html:Pa(n.trim())}})]}function E_(n){try{const e={},i=n.split(";");for(const s of i){const a=s.trim();if(!a)continue;let[o,u]=a.split(":");if(o=o.trim(),u=u.trim(),!A_(o))continue;const f=o.replace(/-([a-z])/g,d=>d[1].toUpperCase());e[f]=u}return e}catch{return{}}}function A_(n){return["background","border","color","font","line","margin","padding","text"].some(i=>n.startsWith(i))}const gh=({tabs:n,selectedTab:e,setSelectedTab:i,leftToolbar:s,rightToolbar:a,dataTestId:o,mode:u})=>{const f=U.useId();return e||(e=n[0].id),u||(u="default"),v.jsx("div",{className:"tabbed-pane","data-testid":o,children:v.jsxs("div",{className:"vbox",children:[v.jsxs(Uh,{children:[s&&v.jsxs("div",{style:{flex:"none",display:"flex",margin:"0 4px",alignItems:"center"},children:[...s]}),u==="default"&&v.jsx("div",{style:{flex:"auto",display:"flex",height:"100%",overflow:"hidden"},role:"tablist",children:[...n.map(d=>v.jsx(sb,{id:d.id,ariaControls:`${f}-${d.id}`,title:d.title,count:d.count,errorCount:d.errorCount,selected:e===d.id,onSelect:i},d.id))]}),u==="select"&&v.jsx("div",{style:{flex:"auto",display:"flex",height:"100%",overflow:"hidden"},role:"tablist",children:v.jsx("select",{style:{width:"100%",background:"none",cursor:"pointer"},value:e,onChange:d=>{i==null||i(n[d.currentTarget.selectedIndex].id)},children:n.map(d=>{let p="";return d.count&&(p=` (${d.count})`),d.errorCount&&(p=` (${d.errorCount})`),v.jsxs("option",{value:d.id,role:"tab","aria-controls":`${f}-${d.id}`,children:[d.title,p]},d.id)})})}),a&&v.jsxs("div",{style:{flex:"none",display:"flex",alignItems:"center"},children:[...a]})]}),n.map(d=>{const p="tab-content tab-"+d.id;if(d.component)return v.jsx("div",{id:`${f}-${d.id}`,role:"tabpanel","aria-label":d.title,className:p,style:{display:e===d.id?"inherit":"none"},children:d.component},d.id);if(e===d.id)return v.jsx("div",{id:`${f}-${d.id}`,role:"tabpanel","aria-label":d.title,className:p,children:d.render()},d.id)})]})})},sb=({id:n,title:e,count:i,errorCount:s,selected:a,onSelect:o,ariaControls:u})=>v.jsxs("div",{className:Ke("tabbed-pane-tab",a&&"selected"),onClick:()=>o==null?void 0:o(n),role:"tab",title:e,"aria-controls":u,children:[v.jsx("div",{className:"tabbed-pane-tab-label",children:e}),!!i&&v.jsx("div",{className:"tabbed-pane-tab-counter",children:i}),!!s&&v.jsx("div",{className:"tabbed-pane-tab-counter error",children:s})]});async function N_(n){const e=navigator.platform.includes("Win")?"win":"unix";let i=[];const s=new Set(["accept-encoding","host","method","path","scheme","version","authority","protocol"]);function a(y){return'^"'+y.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/[^a-zA-Z0-9\s_\-:=+~'\/.',?;()*`]/g,"^$&").replace(/%(?=[a-zA-Z0-9_])/g,"%^").replace(/\r?\n/g,`^
|
|
73
73
|
|
|
74
74
|
`)+'^"'}function o(y){function b(w){let x=w.charCodeAt(0).toString(16);for(;x.length<4;)x="0"+x;return"\\u"+x}return/[\0-\x1F\x7F-\x9F!]|\'/.test(y)?"$'"+y.replace(/\\/g,"\\\\").replace(/\'/g,"\\'").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\0-\x1F\x7F-\x9F!]/g,b)+"'":"'"+y+"'"}const u=e==="win"?a:o;i.push(u(n.request.url).replace(/[[{}\]]/g,"\\$&"));let f="GET";const d=[],p=await rb(n);p&&(d.push("--data-raw "+u(p)),s.add("content-length"),f="POST"),n.request.method!==f&&i.push("-X "+u(n.request.method));const m=n.request.headers;for(let y=0;y<m.length;y++){const b=m[y],w=b.name.replace(/^:/,"");s.has(w.toLowerCase())||(b.value.trim()?i.push("-H "+u(w+": "+b.value)):i.push("-H "+u(w+";")))}return i=i.concat(d),"curl "+i.join(i.length>=3?e==="win"?` ^
|
|
75
75
|
`:` \\
|
|
76
|
-
`:" ")}async function
|
|
76
|
+
`:" ")}async function C_(n,e=0){const i=new Set(["method","path","scheme","version","accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via","user-agent"]),s=new Set(["cookie","authorization"]),a=JSON.stringify(n.request.url),o=n.request.headers,u=o.reduce((E,x)=>{const _=x.name;return!i.has(_.toLowerCase())&&!_.includes(":")&&E.append(_,x.value),E},new Headers),f={};for(const E of u)f[E[0]]=E[1];const d=n.request.cookies.length||o.some(({name:E})=>s.has(E.toLowerCase()))?"include":"omit",p=o.find(({name:E})=>E.toLowerCase()==="referer"),m=p?p.value:void 0,y=await rb(n),b={headers:Object.keys(f).length?f:void 0,referrer:m,body:y,method:n.request.method,mode:"cors"};if(e===1){const E=o.find(_=>_.name.toLowerCase()==="cookie"),x={};delete b.mode,E&&(x.cookie=E.value),m&&(delete b.referrer,x.Referer=m),Object.keys(x).length&&(b.headers={...f,...x})}else b.credentials=d;const w=JSON.stringify(b,null,2);return`fetch(${a}, ${w});`}async function rb(n){var e,i;return(e=n.request.postData)!=null&&e._sha1?await fetch(`sha1/${n.request.postData._sha1}`).then(s=>s.text()):(i=n.request.postData)==null?void 0:i.text}class k_{generatePlaywrightRequestCall(e,i){let s=e.method.toLowerCase();const a=new URL(e.url),o=`${a.origin}${a.pathname}`,u={};["delete","get","head","post","put","patch"].includes(s)||(u.method=s,s="fetch"),a.searchParams.size&&(u.params=Object.fromEntries(a.searchParams.entries())),i&&(u.data=i),e.headers.length&&(u.headers=Object.fromEntries(e.headers.map(p=>[p.name,p.value])));const f=[`'${o}'`];return Object.keys(u).length>0&&f.push(this.prettyPrintObject(u)),`await page.request.${s}(${f.join(", ")});`}prettyPrintObject(e,i=2,s=0){if(e===null)return"null";if(e===void 0)return"undefined";if(typeof e!="object")return typeof e=="string"?this.stringLiteral(e):String(e);if(Array.isArray(e)){if(e.length===0)return"[]";const f=" ".repeat(s*i),d=" ".repeat((s+1)*i);return`[
|
|
77
77
|
${e.map(m=>`${d}${this.prettyPrintObject(m,i,s+1)}`).join(`,
|
|
78
78
|
`)}
|
|
79
79
|
${f}]`}if(Object.keys(e).length===0)return"{}";const a=" ".repeat(s*i),o=" ".repeat((s+1)*i);return`{
|
|
80
80
|
${Object.entries(e).map(([f,d])=>{const p=this.prettyPrintObject(d,i,s+1),m=/^[a-zA-Z_$][a-zA-Z0-9_$]*$/.test(f)?f:this.stringLiteral(f);return`${o}${m}: ${p}`}).join(`,
|
|
81
81
|
`)}
|
|
82
82
|
${a}}`}stringLiteral(e){return e=e.replace(/\\/g,"\\\\").replace(/'/g,"\\'"),e.includes(`
|
|
83
|
-
`)||e.includes("\r")||e.includes(" ")?"`"+e+"`":`'${e}'`}}class
|
|
83
|
+
`)||e.includes("\r")||e.includes(" ")?"`"+e+"`":`'${e}'`}}class M_{generatePlaywrightRequestCall(e,i){const s=new URL(e.url),o=[`"${`${s.origin}${s.pathname}`}"`];let u=e.method.toLowerCase();["delete","get","head","post","put","patch"].includes(u)||(o.push(`method="${u}"`),u="fetch"),s.searchParams.size&&o.push(`params=${this.prettyPrintObject(Object.fromEntries(s.searchParams.entries()))}`),i&&o.push(`data=${this.prettyPrintObject(i)}`),e.headers.length&&o.push(`headers=${this.prettyPrintObject(Object.fromEntries(e.headers.map(d=>[d.name,d.value])))}`);const f=o.length===1?o[0]:`
|
|
84
84
|
${o.map(d=>this.indent(d,2)).join(`,
|
|
85
85
|
`)}
|
|
86
86
|
`;return`await page.request.${u}(${f})`}indent(e,i){return e.split(`
|
|
@@ -91,7 +91,7 @@ ${e.map(m=>`${d}${this.prettyPrintObject(m,i,s+1)}`).join(`,
|
|
|
91
91
|
${f}]`}if(Object.keys(e).length===0)return"{}";const a=" ".repeat(s*i),o=" ".repeat((s+1)*i);return`{
|
|
92
92
|
${Object.entries(e).map(([f,d])=>{const p=this.prettyPrintObject(d,i,s+1);return`${o}${this.stringLiteral(f)}: ${p}`}).join(`,
|
|
93
93
|
`)}
|
|
94
|
-
${a}}`}stringLiteral(e){return JSON.stringify(e)}}class
|
|
94
|
+
${a}}`}stringLiteral(e){return JSON.stringify(e)}}class O_{generatePlaywrightRequestCall(e,i){const s=new URL(e.url),a=`${s.origin}${s.pathname}`,o={},u=[];let f=e.method.toLowerCase();["delete","get","head","post","put","patch"].includes(f)||(o.Method=f,f="fetch"),s.searchParams.size&&(o.Params=Object.fromEntries(s.searchParams.entries())),i&&(o.Data=i),e.headers.length&&(o.Headers=Object.fromEntries(e.headers.map(m=>[m.name,m.value])));const d=[`"${a}"`];return Object.keys(o).length>0&&d.push(this.prettyPrintObject(o)),`${u.join(`
|
|
95
95
|
`)}${u.length?`
|
|
96
96
|
`:""}await request.${this.toFunctionName(f)}(${d.join(", ")});`}toFunctionName(e){return e[0].toUpperCase()+e.slice(1)+"Async"}prettyPrintObject(e,i=2,s=0){if(e===null||e===void 0)return"null";if(typeof e!="object")return typeof e=="string"?this.stringLiteral(e):typeof e=="boolean"?e?"true":"false":String(e);if(Array.isArray(e)){if(e.length===0)return"new object[] {}";const f=" ".repeat(s*i),d=" ".repeat((s+1)*i);return`new object[] {
|
|
97
97
|
${e.map(m=>`${d}${this.prettyPrintObject(m,i,s+1)}`).join(`,
|
|
@@ -99,52 +99,52 @@ ${e.map(m=>`${d}${this.prettyPrintObject(m,i,s+1)}`).join(`,
|
|
|
99
99
|
${f}}`}if(Object.keys(e).length===0)return"new {}";const a=" ".repeat(s*i),o=" ".repeat((s+1)*i);return`new() {
|
|
100
100
|
${Object.entries(e).map(([f,d])=>{const p=this.prettyPrintObject(d,i,s+1),m=s===0?f:`[${this.stringLiteral(f)}]`;return`${o}${m} = ${p}`}).join(`,
|
|
101
101
|
`)}
|
|
102
|
-
${a}}`}stringLiteral(e){return JSON.stringify(e)}}class
|
|
102
|
+
${a}}`}stringLiteral(e){return JSON.stringify(e)}}class R_{generatePlaywrightRequestCall(e,i){const s=new URL(e.url),a=[`"${s.origin}${s.pathname}"`],o=[];let u=e.method.toLowerCase();["delete","get","head","post","put","patch"].includes(u)||(o.push(`setMethod("${u}")`),u="fetch");for(const[f,d]of s.searchParams)o.push(`setQueryParam(${this.stringLiteral(f)}, ${this.stringLiteral(d)})`);i&&o.push(`setData(${this.stringLiteral(i)})`);for(const f of e.headers)o.push(`setHeader(${this.stringLiteral(f.name)}, ${this.stringLiteral(f.value)})`);return o.length>0&&a.push(`RequestOptions.create()
|
|
103
103
|
.${o.join(`
|
|
104
104
|
.`)}
|
|
105
|
-
`),`request.${u}(${a.join(", ")});`}stringLiteral(e){return JSON.stringify(e)}}function
|
|
105
|
+
`),`request.${u}(${a.join(", ")});`}stringLiteral(e){return JSON.stringify(e)}}function j_(n){if(n==="javascript")return new k_;if(n==="python")return new M_;if(n==="csharp")return new O_;if(n==="java")return new R_;throw new Error("Unsupported language: "+n)}const L_=({resource:n,sdkLanguage:e,startTimeOffset:i,onClose:s})=>{const[a,o]=U.useState("request"),u=U.useContext(Xn),f=Io(async()=>{if(u&&n.request.postData){const d=n.request.headers.find(m=>m.name.toLowerCase()==="content-type"),p=d?d.value:"";if(n.request.postData._sha1){const m=await fetch(u.createRelativeUrl(`sha1/${n.request.postData._sha1}`));return{text:mh(await m.text(),p),mimeType:p}}else return{text:mh(n.request.postData.text,p),mimeType:p}}else return null},[n],null);return v.jsx(gh,{dataTestId:"network-request-details",leftToolbar:[v.jsx(zt,{icon:"close",title:"Close",onClick:s},"close")],rightToolbar:[v.jsx(D_,{requestBody:f,resource:n,sdkLanguage:e},"dropdown")],tabs:[{id:"request",title:"Request",render:()=>v.jsx(B_,{resource:n,startTimeOffset:i,requestBody:f})},{id:"response",title:"Response",render:()=>v.jsx(U_,{resource:n})},{id:"body",title:"Body",render:()=>v.jsx(z_,{resource:n})}],selectedTab:a,setSelectedTab:o})},D_=({resource:n,sdkLanguage:e,requestBody:i})=>{const s=v.jsxs(v.Fragment,{children:[v.jsx("span",{className:"codicon codicon-check",style:{marginRight:"5px"}})," Copied "]}),a=async()=>j_(e).generatePlaywrightRequestCall(n.request,i==null?void 0:i.text);return v.jsxs("div",{className:"copy-request-dropdown",children:[v.jsxs(zt,{className:"copy-request-dropdown-toggle",children:[v.jsx("span",{className:"codicon codicon-copy",style:{marginRight:"5px"}}),"Copy request",v.jsx("span",{className:"codicon codicon-chevron-down",style:{marginLeft:"5px"}})]}),v.jsxs("div",{className:"copy-request-dropdown-menu",children:[v.jsx(jo,{description:"Copy as cURL",copiedDescription:s,value:()=>N_(n)}),v.jsx(jo,{description:"Copy as Fetch",copiedDescription:s,value:()=>C_(n)}),v.jsx(jo,{description:"Copy as Playwright",copiedDescription:s,value:a})]})]})},B_=({resource:n,startTimeOffset:e,requestBody:i})=>v.jsxs("div",{className:"vbox network-request-details-tab",children:[v.jsx("div",{className:"network-request-details-header",children:"General"}),v.jsx("div",{className:"network-request-details-url",children:`URL: ${n.request.url}`}),v.jsx("div",{className:"network-request-details-general",children:`Method: ${n.request.method}`}),n.response.status!==-1&&v.jsxs("div",{className:"network-request-details-general",style:{display:"flex"},children:["Status Code: ",v.jsx("span",{className:q_(n.response.status),style:{display:"inline-flex"},children:`${n.response.status} ${n.response.statusText}`})]}),n.request.queryString.length?v.jsxs(v.Fragment,{children:[v.jsx("div",{className:"network-request-details-header",children:"Query String Parameters"}),v.jsx("div",{className:"network-request-details-headers",children:n.request.queryString.map(s=>`${s.name}: ${s.value}`).join(`
|
|
106
106
|
`)})]}):null,v.jsx("div",{className:"network-request-details-header",children:"Request Headers"}),v.jsx("div",{className:"network-request-details-headers",children:n.request.headers.map(s=>`${s.name}: ${s.value}`).join(`
|
|
107
|
-
`)}),v.jsx("div",{className:"network-request-details-header",children:"Time"}),v.jsx("div",{className:"network-request-details-general",children:`Start: ${_t(e)}`}),v.jsx("div",{className:"network-request-details-general",children:`Duration: ${_t(n.time)}`}),i&&v.jsx("div",{className:"network-request-details-header",children:"Request Body"}),i&&v.jsx(ur,{text:i.text,mimeType:i.mimeType,readOnly:!0,lineNumbers:!0})]}),
|
|
108
|
-
`)})]}),U_=({resource:n})=>{const e=U.useContext(Xn),[i,s]=U.useState(null);return U.useEffect(()=>{(async()=>{if(e&&n.response.content._sha1){const o=n.response.content.mimeType.includes("image"),u=n.response.content.mimeType.includes("font"),f=await fetch(e.createRelativeUrl(`sha1/${n.response.content._sha1}`));if(o){const d=await f.blob(),p=new FileReader,m=new Promise(y=>p.onload=y);p.readAsDataURL(d),s({dataUrl:(await m).target.result})}else if(u){const d=await f.arrayBuffer();s({font:d})}else{const d=mh(await f.text(),n.response.content.mimeType);s({text:d,mimeType:n.response.content.mimeType})}}else s(null)})()},[n,e]),v.jsxs("div",{className:"vbox network-request-details-tab",children:[!n.response.content._sha1&&v.jsx("div",{children:"Response body is not available for this request."}),i&&i.font&&v.jsx(z_,{font:i.font}),i&&i.dataUrl&&v.jsx("div",{children:v.jsx("img",{draggable:"false",src:i.dataUrl})}),i&&i.text&&v.jsx(ur,{text:i.text,mimeType:i.mimeType,readOnly:!0,lineNumbers:!0})]})},z_=({font:n})=>{const[e,i]=U.useState(!1);return U.useEffect(()=>{let s;try{s=new FontFace("font-preview",n),s.status==="loaded"&&document.fonts.add(s),s.status==="error"&&i(!0)}catch{i(!0)}return()=>{document.fonts.delete(s)}},[n]),e?v.jsx("div",{className:"network-font-preview-error",children:"Could not load font preview"}):v.jsxs("div",{className:"network-font-preview",children:["ABCDEFGHIJKLM",v.jsx("br",{}),"NOPQRSTUVWXYZ",v.jsx("br",{}),"abcdefghijklm",v.jsx("br",{}),"nopqrstuvwxyz",v.jsx("br",{}),"1234567890"]})};function H_(n){return n<300||n===304?"green-circle":n<400?"yellow-circle":"red-circle"}function mh(n,e){if(n===null)return"Loading...";const i=n;if(i==="")return"<Empty>";if(e.includes("application/json"))try{return JSON.stringify(JSON.parse(i),null,2)}catch{return i}return e.includes("application/x-www-form-urlencoded")?decodeURIComponent(i):i}function q_(n){const[e,i]=U.useState([]);U.useEffect(()=>{const o=[];for(let u=0;u<n.columns.length-1;++u){const f=n.columns[u];o[u]=(o[u-1]||0)+n.columnWidths.get(f)}i(o)},[n.columns,n.columnWidths]);function s(o){const u=new Map(n.columnWidths.entries());for(let f=0;f<o.length;++f){const d=o[f]-(o[f-1]||0),p=n.columns[f];u.set(p,d)}n.setColumnWidths(u)}const a=U.useCallback(o=>{var u,f;(f=n.setSorting)==null||f.call(n,{by:o,negate:((u=n.sorting)==null?void 0:u.by)===o?!n.sorting.negate:!1})},[n]);return v.jsxs("div",{className:`grid-view ${n.name}-grid-view`,children:[v.jsx(eb,{orientation:"horizontal",offsets:e,setOffsets:s,resizerColor:"var(--vscode-panel-border)",resizerWidth:1,minColumnWidth:25}),v.jsxs("div",{className:"vbox",children:[v.jsx("div",{className:"grid-view-header",children:n.columns.map((o,u)=>v.jsxs("div",{className:"grid-view-header-cell "+$_(o,n.sorting),style:{width:u<n.columns.length-1?n.columnWidths.get(o):void 0},onClick:()=>n.setSorting&&a(o),children:[v.jsx("span",{className:"grid-view-header-cell-title",children:n.columnTitle(o)}),v.jsx("span",{className:"codicon codicon-triangle-up"}),v.jsx("span",{className:"codicon codicon-triangle-down"})]},n.columnTitle(o)))}),v.jsx(rc,{name:n.name,items:n.items,ariaLabel:n.ariaLabel,id:n.id,render:(o,u)=>v.jsx(v.Fragment,{children:n.columns.map((f,d)=>{const{body:p,title:m}=n.render(o,f,u);return v.jsx("div",{className:`grid-view-cell grid-view-column-${String(f)}`,title:m,style:{width:d<n.columns.length-1?n.columnWidths.get(f):void 0},children:p},n.columnTitle(f))})}),icon:n.icon,isError:n.isError,isWarning:n.isWarning,isInfo:n.isInfo,selectedItem:n.selectedItem,onAccepted:n.onAccepted,onSelected:n.onSelected,onHighlighted:n.onHighlighted,onIconClicked:n.onIconClicked,noItemsMessage:n.noItemsMessage,dataTestId:n.dataTestId,notSelectable:n.notSelectable})]})]})}function $_(n,e){return n===(e==null?void 0:e.by)?" filter-"+(e.negate?"negative":"positive"):""}const I_=["Fetch","HTML","JS","CSS","Font","Image"],V_={searchValue:"",resourceTypes:new Set},G_=({filterState:n,onFilterStateChange:e})=>v.jsxs("div",{className:"network-filters",children:[v.jsx("input",{type:"search",placeholder:"Filter network",spellCheck:!1,value:n.searchValue,onChange:i=>e({...n,searchValue:i.target.value})}),v.jsxs("div",{className:"network-filters-resource-types",children:[v.jsx("div",{title:"All",onClick:()=>e({...n,resourceTypes:new Set}),className:`network-filters-resource-type ${n.resourceTypes.size===0?"selected":""}`,children:"All"}),I_.map(i=>v.jsx("div",{title:i,onClick:s=>{let a;s.ctrlKey||s.metaKey?a=n.resourceTypes.symmetricDifference(new Set([i])):a=new Set([i]),e({...n,resourceTypes:a})},className:`network-filters-resource-type ${n.resourceTypes.has(i)?"selected":""}`,children:i},i))]})]}),K_=q_;function Y_(n,e){const i=U.useMemo(()=>((n==null?void 0:n.resources)||[]).filter(u=>e?!!u._monotonicTime&&u._monotonicTime>=e.minimum&&u._monotonicTime<=e.maximum:!0),[n,e]),s=U.useMemo(()=>new J_(n),[n]);return{resources:i,contextIdMap:s}}const X_=({boundaries:n,networkModel:e,onEntryHovered:i,sdkLanguage:s})=>{const[a,o]=U.useState(void 0),[u,f]=U.useState(void 0),[d,p]=U.useState(V_),{renderedEntries:m}=U.useMemo(()=>{const x=e.resources.map(_=>W_(_,n,e.contextIdMap)).filter(sT(d));return a&&tT(x,a),{renderedEntries:x}},[e.resources,e.contextIdMap,d,a,n]),[y,b]=U.useState(()=>new Map(ab().map(x=>[x,F_(x)]))),w=U.useCallback(x=>{p(x),f(void 0)},[]);if(!e.resources.length)return v.jsx(ns,{text:"No network calls"});const E=v.jsx(K_,{name:"network",ariaLabel:"Network requests",items:m,selectedItem:u,onSelected:x=>f(x),onHighlighted:x=>i==null?void 0:i(x==null?void 0:x.resource),columns:Q_(!!u,m),columnTitle:P_,columnWidths:y,setColumnWidths:b,isError:x=>x.status.code>=400||x.status.code===-1,isInfo:x=>!!x.route,render:(x,_)=>Z_(x,_),sorting:a,setSorting:o});return v.jsxs(v.Fragment,{children:[v.jsx(G_,{filterState:d,onFilterStateChange:w}),!u&&E,u&&v.jsx(Vo,{sidebarSize:y.get("name"),sidebarIsFirst:!0,orientation:"horizontal",settingName:"networkResourceDetails",main:v.jsx(j_,{resource:u.resource,sdkLanguage:s,startTimeOffset:u.start,onClose:()=>f(void 0)}),sidebar:E})]})},P_=n=>n==="contextId"?"Source":n==="name"?"Name":n==="method"?"Method":n==="status"?"Status":n==="contentType"?"Content Type":n==="duration"?"Duration":n==="size"?"Size":n==="start"?"Start":n==="route"?"Route":"",F_=n=>n==="name"?200:n==="method"||n==="status"?60:n==="contentType"?200:n==="contextId"?60:100;function Q_(n,e){if(n){const s=["name"];return zy(e)&&s.unshift("contextId"),s}let i=ab();return zy(e)||(i=i.filter(s=>s!=="contextId")),i}function ab(){return["contextId","name","method","status","contentType","duration","size","start","route"]}const Z_=(n,e)=>e==="contextId"?{body:n.contextId,title:n.name.url}:e==="name"?{body:n.name.name,title:n.name.url}:e==="method"?{body:n.method}:e==="status"?{body:n.status.code>0?n.status.code:"",title:n.status.text}:e==="contentType"?{body:n.contentType}:e==="duration"?{body:_t(n.duration)}:e==="size"?{body:kw(n.size)}:e==="start"?{body:_t(n.start)}:e==="route"?{body:n.route}:{body:""};class J_{constructor(e){Ne(this,"_pagerefToShortId",new Map);Ne(this,"_contextToId",new Map);Ne(this,"_lastPageId",0);Ne(this,"_lastApiRequestContextId",0)}contextId(e){return e.pageref?this._pageId(e.pageref):e._apiRequest?this._apiRequestContextId(e):""}_pageId(e){let i=this._pagerefToShortId.get(e);return i||(++this._lastPageId,i="page#"+this._lastPageId,this._pagerefToShortId.set(e,i)),i}_apiRequestContextId(e){const i=A0(e);if(!i)return"";let s=this._contextToId.get(i);return s||(++this._lastApiRequestContextId,s="api#"+this._lastApiRequestContextId,this._contextToId.set(i,s)),s}}function zy(n){const e=new Set;for(const i of n)if(e.add(i.contextId),e.size>1)return!0;return!1}const W_=(n,e,i)=>{const s=eT(n);let a;try{const f=new URL(n.request.url);a=f.pathname.substring(f.pathname.lastIndexOf("/")+1),a||(a=f.host),f.search&&(a+=f.search)}catch{a=n.request.url}let o=n.response.content.mimeType;const u=o.match(/^(.*);\s*charset=.*$/);return u&&(o=u[1]),{name:{name:a,url:n.request.url},method:n.request.method,status:{code:n.response.status,text:n.response.statusText},contentType:o,duration:n.time,size:n.response._transferSize>0?n.response._transferSize:n.response.bodySize,start:n._monotonicTime-e.minimum,route:s,resource:n,contextId:i.contextId(n)}};function eT(n){return n._wasAborted?"aborted":n._wasContinued?"continued":n._wasFulfilled?"fulfilled":n._apiRequest?"api":""}function tT(n,e){const i=nT(e==null?void 0:e.by);i&&n.sort(i),e.negate&&n.reverse()}function nT(n){if(n==="start")return(e,i)=>e.start-i.start;if(n==="duration")return(e,i)=>e.duration-i.duration;if(n==="status")return(e,i)=>e.status.code-i.status.code;if(n==="method")return(e,i)=>{const s=e.method,a=i.method;return s.localeCompare(a)};if(n==="size")return(e,i)=>e.size-i.size;if(n==="contentType")return(e,i)=>e.contentType.localeCompare(i.contentType);if(n==="name")return(e,i)=>e.name.name.localeCompare(i.name.name);if(n==="route")return(e,i)=>e.route.localeCompare(i.route);if(n==="contextId")return(e,i)=>e.contextId.localeCompare(i.contextId)}const iT={Fetch:n=>n==="application/json",HTML:n=>n==="text/html",CSS:n=>n==="text/css",JS:n=>n.includes("javascript"),Font:n=>n.includes("font"),Image:n=>n.includes("image")};function sT({searchValue:n,resourceTypes:e}){return i=>(e.size===0||Array.from(e).some(a=>iT[a](i.contentType)))&&i.name.url.toLowerCase().includes(n.toLowerCase())}function zh(n,e,i={}){var b;const s=new n.LineCounter,a={keepSourceTokens:!0,lineCounter:s,...i},o=n.parseDocument(e,a),u=[],f=w=>[s.linePos(w[0]),s.linePos(w[1])],d=w=>{u.push({message:w.message,range:[s.linePos(w.pos[0]),s.linePos(w.pos[1])]})},p=(w,E)=>{for(const x of E.items){if(x instanceof n.Scalar&&typeof x.value=="string"){const C=Po.parse(x,a,u);C&&(w.children=w.children||[],w.children.push(C));continue}if(x instanceof n.YAMLMap){m(w,x);continue}u.push({message:"Sequence items should be strings or maps",range:f(x.range||E.range)})}},m=(w,E)=>{for(const x of E.items){if(w.children=w.children||[],!(x.key instanceof n.Scalar&&typeof x.key.value=="string")){u.push({message:"Only string keys are supported",range:f(x.key.range||E.range)});continue}const k=x.key,C=x.value;if(k.value==="text"){if(!(C instanceof n.Scalar&&typeof C.value=="string")){u.push({message:"Text value should be a string",range:f(x.value.range||E.range)});continue}w.children.push({kind:"text",text:Xf(C.value)});continue}if(k.value==="/children"){if(!(C instanceof n.Scalar&&typeof C.value=="string")||C.value!=="contain"&&C.value!=="equal"&&C.value!=="deep-equal"){u.push({message:'Strict value should be "contain", "equal" or "deep-equal"',range:f(x.value.range||E.range)});continue}w.containerMode=C.value;continue}if(k.value.startsWith("/")){if(!(C instanceof n.Scalar&&typeof C.value=="string")){u.push({message:"Property value should be a string",range:f(x.value.range||E.range)});continue}w.props=w.props??{},w.props[k.value.slice(1)]=Xf(C.value);continue}const V=Po.parse(k,a,u);if(!V)continue;if(C instanceof n.Scalar){const G=typeof C.value;if(G!=="string"&&G!=="number"&&G!=="boolean"){u.push({message:"Node value should be a string or a sequence",range:f(x.value.range||E.range)});continue}w.children.push({...V,children:[{kind:"text",text:Xf(String(C.value))}]});continue}if(C instanceof n.YAMLSeq){w.children.push(V),p(V,C);continue}u.push({message:"Map values should be strings or sequences",range:f(x.value.range||E.range)})}},y={kind:"role",role:"fragment"};return o.errors.forEach(d),u.length?{errors:u,fragment:y}:(o.contents instanceof n.YAMLSeq||u.push({message:'Aria snapshot must be a YAML sequence, elements starting with " -"',range:o.contents?f(o.contents.range):[{line:0,col:0},{line:0,col:0}]}),u.length?{errors:u,fragment:y}:(p(y,o.contents),u.length?{errors:u,fragment:rT}:((b=y.children)==null?void 0:b.length)===1&&(!y.containerMode||y.containerMode==="contain")?{fragment:y.children[0],errors:[]}:{fragment:y,errors:[]}))}const rT={kind:"role",role:"fragment"};function lb(n){return n.replace(/[\u200b\u00ad]/g,"").replace(/[\r\n\s\t]+/g," ").trim()}function Xf(n){return{raw:n,normalized:lb(n)}}class Po{static parse(e,i,s){try{return new Po(e.value)._parse()}catch(a){if(a instanceof Hy){const o=i.prettyErrors===!1?a.message:a.message+`:
|
|
107
|
+
`)}),v.jsx("div",{className:"network-request-details-header",children:"Time"}),v.jsx("div",{className:"network-request-details-general",children:`Start: ${_t(e)}`}),v.jsx("div",{className:"network-request-details-general",children:`Duration: ${_t(n.time)}`}),i&&v.jsx("div",{className:"network-request-details-header",children:"Request Body"}),i&&v.jsx(ur,{text:i.text,mimeType:i.mimeType,readOnly:!0,lineNumbers:!0})]}),U_=({resource:n})=>v.jsxs("div",{className:"vbox network-request-details-tab",children:[v.jsx("div",{className:"network-request-details-header",children:"Response Headers"}),v.jsx("div",{className:"network-request-details-headers",children:n.response.headers.map(e=>`${e.name}: ${e.value}`).join(`
|
|
108
|
+
`)})]}),z_=({resource:n})=>{const e=U.useContext(Xn),[i,s]=U.useState(null);return U.useEffect(()=>{(async()=>{if(e&&n.response.content._sha1){const o=n.response.content.mimeType.includes("image"),u=n.response.content.mimeType.includes("font"),f=await fetch(e.createRelativeUrl(`sha1/${n.response.content._sha1}`));if(o){const d=await f.blob(),p=new FileReader,m=new Promise(y=>p.onload=y);p.readAsDataURL(d),s({dataUrl:(await m).target.result})}else if(u){const d=await f.arrayBuffer();s({font:d})}else{const d=mh(await f.text(),n.response.content.mimeType);s({text:d,mimeType:n.response.content.mimeType})}}else s(null)})()},[n,e]),v.jsxs("div",{className:"vbox network-request-details-tab",children:[!n.response.content._sha1&&v.jsx("div",{children:"Response body is not available for this request."}),i&&i.font&&v.jsx(H_,{font:i.font}),i&&i.dataUrl&&v.jsx("div",{children:v.jsx("img",{draggable:"false",src:i.dataUrl})}),i&&i.text&&v.jsx(ur,{text:i.text,mimeType:i.mimeType,readOnly:!0,lineNumbers:!0})]})},H_=({font:n})=>{const[e,i]=U.useState(!1);return U.useEffect(()=>{let s;try{s=new FontFace("font-preview",n),s.status==="loaded"&&document.fonts.add(s),s.status==="error"&&i(!0)}catch{i(!0)}return()=>{document.fonts.delete(s)}},[n]),e?v.jsx("div",{className:"network-font-preview-error",children:"Could not load font preview"}):v.jsxs("div",{className:"network-font-preview",children:["ABCDEFGHIJKLM",v.jsx("br",{}),"NOPQRSTUVWXYZ",v.jsx("br",{}),"abcdefghijklm",v.jsx("br",{}),"nopqrstuvwxyz",v.jsx("br",{}),"1234567890"]})};function q_(n){return n<300||n===304?"green-circle":n<400?"yellow-circle":"red-circle"}function mh(n,e){if(n===null)return"Loading...";const i=n;if(i==="")return"<Empty>";if(e.includes("application/json"))try{return JSON.stringify(JSON.parse(i),null,2)}catch{return i}return e.includes("application/x-www-form-urlencoded")?decodeURIComponent(i):i}function $_(n){const[e,i]=U.useState([]);U.useEffect(()=>{const o=[];for(let u=0;u<n.columns.length-1;++u){const f=n.columns[u];o[u]=(o[u-1]||0)+n.columnWidths.get(f)}i(o)},[n.columns,n.columnWidths]);function s(o){const u=new Map(n.columnWidths.entries());for(let f=0;f<o.length;++f){const d=o[f]-(o[f-1]||0),p=n.columns[f];u.set(p,d)}n.setColumnWidths(u)}const a=U.useCallback(o=>{var u,f;(f=n.setSorting)==null||f.call(n,{by:o,negate:((u=n.sorting)==null?void 0:u.by)===o?!n.sorting.negate:!1})},[n]);return v.jsxs("div",{className:`grid-view ${n.name}-grid-view`,children:[v.jsx(eb,{orientation:"horizontal",offsets:e,setOffsets:s,resizerColor:"var(--vscode-panel-border)",resizerWidth:1,minColumnWidth:25}),v.jsxs("div",{className:"vbox",children:[v.jsx("div",{className:"grid-view-header",children:n.columns.map((o,u)=>v.jsxs("div",{className:"grid-view-header-cell "+I_(o,n.sorting),style:{width:u<n.columns.length-1?n.columnWidths.get(o):void 0},onClick:()=>n.setSorting&&a(o),children:[v.jsx("span",{className:"grid-view-header-cell-title",children:n.columnTitle(o)}),v.jsx("span",{className:"codicon codicon-triangle-up"}),v.jsx("span",{className:"codicon codicon-triangle-down"})]},n.columnTitle(o)))}),v.jsx(rc,{name:n.name,items:n.items,ariaLabel:n.ariaLabel,id:n.id,render:(o,u)=>v.jsx(v.Fragment,{children:n.columns.map((f,d)=>{const{body:p,title:m}=n.render(o,f,u);return v.jsx("div",{className:`grid-view-cell grid-view-column-${String(f)}`,title:m,style:{width:d<n.columns.length-1?n.columnWidths.get(f):void 0},children:p},n.columnTitle(f))})}),icon:n.icon,isError:n.isError,isWarning:n.isWarning,isInfo:n.isInfo,selectedItem:n.selectedItem,onAccepted:n.onAccepted,onSelected:n.onSelected,onHighlighted:n.onHighlighted,onIconClicked:n.onIconClicked,noItemsMessage:n.noItemsMessage,dataTestId:n.dataTestId,notSelectable:n.notSelectable})]})]})}function I_(n,e){return n===(e==null?void 0:e.by)?" filter-"+(e.negate?"negative":"positive"):""}const V_=["Fetch","HTML","JS","CSS","Font","Image"],G_={searchValue:"",resourceTypes:new Set},K_=({filterState:n,onFilterStateChange:e})=>v.jsxs("div",{className:"network-filters",children:[v.jsx("input",{type:"search",placeholder:"Filter network",spellCheck:!1,value:n.searchValue,onChange:i=>e({...n,searchValue:i.target.value})}),v.jsxs("div",{className:"network-filters-resource-types",children:[v.jsx("div",{title:"All",onClick:()=>e({...n,resourceTypes:new Set}),className:`network-filters-resource-type ${n.resourceTypes.size===0?"selected":""}`,children:"All"}),V_.map(i=>v.jsx("div",{title:i,onClick:s=>{let a;s.ctrlKey||s.metaKey?a=n.resourceTypes.symmetricDifference(new Set([i])):a=new Set([i]),e({...n,resourceTypes:a})},className:`network-filters-resource-type ${n.resourceTypes.has(i)?"selected":""}`,children:i},i))]})]}),Y_=$_;function X_(n,e){const i=U.useMemo(()=>((n==null?void 0:n.resources)||[]).filter(u=>e?!!u._monotonicTime&&u._monotonicTime>=e.minimum&&u._monotonicTime<=e.maximum:!0),[n,e]),s=U.useMemo(()=>new W_(n),[n]);return{resources:i,contextIdMap:s}}const P_=({boundaries:n,networkModel:e,onEntryHovered:i,sdkLanguage:s})=>{const[a,o]=U.useState(void 0),[u,f]=U.useState(void 0),[d,p]=U.useState(G_),{renderedEntries:m}=U.useMemo(()=>{const x=e.resources.map(_=>eT(_,n,e.contextIdMap)).filter(rT(d));return a&&nT(x,a),{renderedEntries:x}},[e.resources,e.contextIdMap,d,a,n]),[y,b]=U.useState(()=>new Map(ab().map(x=>[x,Q_(x)]))),w=U.useCallback(x=>{p(x),f(void 0)},[]);if(!e.resources.length)return v.jsx(ns,{text:"No network calls"});const E=v.jsx(Y_,{name:"network",ariaLabel:"Network requests",items:m,selectedItem:u,onSelected:x=>f(x),onHighlighted:x=>i==null?void 0:i(x==null?void 0:x.resource),columns:Z_(!!u,m),columnTitle:F_,columnWidths:y,setColumnWidths:b,isError:x=>x.status.code>=400||x.status.code===-1,isInfo:x=>!!x.route,render:(x,_)=>J_(x,_),sorting:a,setSorting:o});return v.jsxs(v.Fragment,{children:[v.jsx(K_,{filterState:d,onFilterStateChange:w}),!u&&E,u&&v.jsx(Vo,{sidebarSize:y.get("name"),sidebarIsFirst:!0,orientation:"horizontal",settingName:"networkResourceDetails",main:v.jsx(L_,{resource:u.resource,sdkLanguage:s,startTimeOffset:u.start,onClose:()=>f(void 0)}),sidebar:E})]})},F_=n=>n==="contextId"?"Source":n==="name"?"Name":n==="method"?"Method":n==="status"?"Status":n==="contentType"?"Content Type":n==="duration"?"Duration":n==="size"?"Size":n==="start"?"Start":n==="route"?"Route":"",Q_=n=>n==="name"?200:n==="method"||n==="status"?60:n==="contentType"?200:n==="contextId"?60:100;function Z_(n,e){if(n){const s=["name"];return zy(e)&&s.unshift("contextId"),s}let i=ab();return zy(e)||(i=i.filter(s=>s!=="contextId")),i}function ab(){return["contextId","name","method","status","contentType","duration","size","start","route"]}const J_=(n,e)=>e==="contextId"?{body:n.contextId,title:n.name.url}:e==="name"?{body:n.name.name,title:n.name.url}:e==="method"?{body:n.method}:e==="status"?{body:n.status.code>0?n.status.code:"",title:n.status.text}:e==="contentType"?{body:n.contentType}:e==="duration"?{body:_t(n.duration)}:e==="size"?{body:Mw(n.size)}:e==="start"?{body:_t(n.start)}:e==="route"?{body:n.route}:{body:""};class W_{constructor(e){Ne(this,"_pagerefToShortId",new Map);Ne(this,"_contextToId",new Map);Ne(this,"_lastPageId",0);Ne(this,"_lastApiRequestContextId",0)}contextId(e){return e.pageref?this._pageId(e.pageref):e._apiRequest?this._apiRequestContextId(e):""}_pageId(e){let i=this._pagerefToShortId.get(e);return i||(++this._lastPageId,i="page#"+this._lastPageId,this._pagerefToShortId.set(e,i)),i}_apiRequestContextId(e){const i=A0(e);if(!i)return"";let s=this._contextToId.get(i);return s||(++this._lastApiRequestContextId,s="api#"+this._lastApiRequestContextId,this._contextToId.set(i,s)),s}}function zy(n){const e=new Set;for(const i of n)if(e.add(i.contextId),e.size>1)return!0;return!1}const eT=(n,e,i)=>{const s=tT(n);let a;try{const f=new URL(n.request.url);a=f.pathname.substring(f.pathname.lastIndexOf("/")+1),a||(a=f.host),f.search&&(a+=f.search)}catch{a=n.request.url}let o=n.response.content.mimeType;const u=o.match(/^(.*);\s*charset=.*$/);return u&&(o=u[1]),{name:{name:a,url:n.request.url},method:n.request.method,status:{code:n.response.status,text:n.response.statusText},contentType:o,duration:n.time,size:n.response._transferSize>0?n.response._transferSize:n.response.bodySize,start:n._monotonicTime-e.minimum,route:s,resource:n,contextId:i.contextId(n)}};function tT(n){return n._wasAborted?"aborted":n._wasContinued?"continued":n._wasFulfilled?"fulfilled":n._apiRequest?"api":""}function nT(n,e){const i=iT(e==null?void 0:e.by);i&&n.sort(i),e.negate&&n.reverse()}function iT(n){if(n==="start")return(e,i)=>e.start-i.start;if(n==="duration")return(e,i)=>e.duration-i.duration;if(n==="status")return(e,i)=>e.status.code-i.status.code;if(n==="method")return(e,i)=>{const s=e.method,a=i.method;return s.localeCompare(a)};if(n==="size")return(e,i)=>e.size-i.size;if(n==="contentType")return(e,i)=>e.contentType.localeCompare(i.contentType);if(n==="name")return(e,i)=>e.name.name.localeCompare(i.name.name);if(n==="route")return(e,i)=>e.route.localeCompare(i.route);if(n==="contextId")return(e,i)=>e.contextId.localeCompare(i.contextId)}const sT={Fetch:n=>n==="application/json",HTML:n=>n==="text/html",CSS:n=>n==="text/css",JS:n=>n.includes("javascript"),Font:n=>n.includes("font"),Image:n=>n.includes("image")};function rT({searchValue:n,resourceTypes:e}){return i=>(e.size===0||Array.from(e).some(a=>sT[a](i.contentType)))&&i.name.url.toLowerCase().includes(n.toLowerCase())}function zh(n,e,i={}){var b;const s=new n.LineCounter,a={keepSourceTokens:!0,lineCounter:s,...i},o=n.parseDocument(e,a),u=[],f=w=>[s.linePos(w[0]),s.linePos(w[1])],d=w=>{u.push({message:w.message,range:[s.linePos(w.pos[0]),s.linePos(w.pos[1])]})},p=(w,E)=>{for(const x of E.items){if(x instanceof n.Scalar&&typeof x.value=="string"){const C=Po.parse(x,a,u);C&&(w.children=w.children||[],w.children.push(C));continue}if(x instanceof n.YAMLMap){m(w,x);continue}u.push({message:"Sequence items should be strings or maps",range:f(x.range||E.range)})}},m=(w,E)=>{for(const x of E.items){if(w.children=w.children||[],!(x.key instanceof n.Scalar&&typeof x.key.value=="string")){u.push({message:"Only string keys are supported",range:f(x.key.range||E.range)});continue}const k=x.key,C=x.value;if(k.value==="text"){if(!(C instanceof n.Scalar&&typeof C.value=="string")){u.push({message:"Text value should be a string",range:f(x.value.range||E.range)});continue}w.children.push({kind:"text",text:Xf(C.value)});continue}if(k.value==="/children"){if(!(C instanceof n.Scalar&&typeof C.value=="string")||C.value!=="contain"&&C.value!=="equal"&&C.value!=="deep-equal"){u.push({message:'Strict value should be "contain", "equal" or "deep-equal"',range:f(x.value.range||E.range)});continue}w.containerMode=C.value;continue}if(k.value.startsWith("/")){if(!(C instanceof n.Scalar&&typeof C.value=="string")){u.push({message:"Property value should be a string",range:f(x.value.range||E.range)});continue}w.props=w.props??{},w.props[k.value.slice(1)]=Xf(C.value);continue}const V=Po.parse(k,a,u);if(!V)continue;if(C instanceof n.Scalar){const G=typeof C.value;if(G!=="string"&&G!=="number"&&G!=="boolean"){u.push({message:"Node value should be a string or a sequence",range:f(x.value.range||E.range)});continue}w.children.push({...V,children:[{kind:"text",text:Xf(String(C.value))}]});continue}if(C instanceof n.YAMLSeq){w.children.push(V),p(V,C);continue}u.push({message:"Map values should be strings or sequences",range:f(x.value.range||E.range)})}},y={kind:"role",role:"fragment"};return o.errors.forEach(d),u.length?{errors:u,fragment:y}:(o.contents instanceof n.YAMLSeq||u.push({message:'Aria snapshot must be a YAML sequence, elements starting with " -"',range:o.contents?f(o.contents.range):[{line:0,col:0},{line:0,col:0}]}),u.length?{errors:u,fragment:y}:(p(y,o.contents),u.length?{errors:u,fragment:aT}:((b=y.children)==null?void 0:b.length)===1&&(!y.containerMode||y.containerMode==="contain")?{fragment:y.children[0],errors:[]}:{fragment:y,errors:[]}))}const aT={kind:"role",role:"fragment"};function lb(n){return n.replace(/[\u200b\u00ad]/g,"").replace(/[\r\n\s\t]+/g," ").trim()}function Xf(n){return{raw:n,normalized:lb(n)}}class Po{static parse(e,i,s){try{return new Po(e.value)._parse()}catch(a){if(a instanceof Hy){const o=i.prettyErrors===!1?a.message:a.message+`:
|
|
109
109
|
|
|
110
110
|
`+e.value+`
|
|
111
111
|
`+" ".repeat(a.pos)+`^
|
|
112
|
-
`;return s.push({message:o,range:[i.lineCounter.linePos(e.range[0]),i.lineCounter.linePos(e.range[0]+a.pos)]}),null}throw a}}constructor(e){this._input=e,this._pos=0,this._length=e.length}_peek(){return this._input[this._pos]||""}_next(){return this._pos<this._length?this._input[this._pos++]:null}_eof(){return this._pos>=this._length}_isWhitespace(){return!this._eof()&&/\s/.test(this._peek())}_skipWhitespace(){for(;this._isWhitespace();)this._pos++}_readIdentifier(e){this._eof()&&this._throwError(`Unexpected end of input when expecting ${e}`);const i=this._pos;for(;!this._eof()&&/[a-zA-Z]/.test(this._peek());)this._pos++;return this._input.slice(i,this._pos)}_readString(){let e="",i=!1;for(;!this._eof();){const s=this._next();if(i)e+=s,i=!1;else if(s==="\\")i=!0;else{if(s==='"')return e;e+=s}}this._throwError("Unterminated string")}_throwError(e,i=0){throw new Hy(e,i||this._pos)}_readRegex(){let e="",i=!1,s=!1;for(;!this._eof();){const a=this._next();if(i)e+=a,i=!1;else if(a==="\\")i=!0,e+=a;else{if(a==="/"&&!s)return{pattern:e};a==="["?(s=!0,e+=a):a==="]"&&s?(e+=a,s=!1):e+=a}}this._throwError("Unterminated regex")}_readStringOrRegex(){const e=this._peek();return e==='"'?(this._next(),lb(this._readString())):e==="/"?(this._next(),this._readRegex()):null}_readAttributes(e){let i=this._pos;for(;this._skipWhitespace(),this._peek()==="[";){this._next(),this._skipWhitespace(),i=this._pos;const s=this._readIdentifier("attribute");this._skipWhitespace();let a="";if(this._peek()==="=")for(this._next(),this._skipWhitespace(),i=this._pos;this._peek()!=="]"&&!this._isWhitespace()&&!this._eof();)a+=this._next();this._skipWhitespace(),this._peek()!=="]"&&this._throwError("Expected ]"),this._next(),this._applyAttribute(e,s,a||"true",i)}}_parse(){this._skipWhitespace();const e=this._readIdentifier("role");this._skipWhitespace();const i=this._readStringOrRegex()||"",s={kind:"role",role:e,name:i};return this._readAttributes(s),this._skipWhitespace(),this._eof()||this._throwError("Unexpected input"),s}_applyAttribute(e,i,s,a){if(i==="checked"){this._assert(s==="true"||s==="false"||s==="mixed",'Value of "checked" attribute must be a boolean or "mixed"',a),e.checked=s==="true"?!0:s==="false"?!1:"mixed";return}if(i==="disabled"){this._assert(s==="true"||s==="false",'Value of "disabled" attribute must be a boolean',a),e.disabled=s==="true";return}if(i==="expanded"){this._assert(s==="true"||s==="false",'Value of "expanded" attribute must be a boolean',a),e.expanded=s==="true";return}if(i==="active"){this._assert(s==="true"||s==="false",'Value of "active" attribute must be a boolean',a),e.active=s==="true";return}if(i==="level"){this._assert(!isNaN(Number(s)),'Value of "level" attribute must be a number',a),e.level=Number(s);return}if(i==="pressed"){this._assert(s==="true"||s==="false"||s==="mixed",'Value of "pressed" attribute must be a boolean or "mixed"',a),e.pressed=s==="true"?!0:s==="false"?!1:"mixed";return}if(i==="selected"){this._assert(s==="true"||s==="false",'Value of "selected" attribute must be a boolean',a),e.selected=s==="true";return}this._assert(!1,`Unsupported attribute [${i}]`,a)}_assert(e,i,s){e||this._throwError(i||"Assertion error",s)}}class Hy extends Error{constructor(e,i){super(e),this.pos=i}}let ob={};function aT(n){ob=n}function Fa(n,e){for(;e;){if(n.contains(e))return!0;e=ub(e)}return!1}function yt(n){if(n.parentElement)return n.parentElement;if(n.parentNode&&n.parentNode.nodeType===11&&n.parentNode.host)return n.parentNode.host}function cb(n){let e=n;for(;e.parentNode;)e=e.parentNode;if(e.nodeType===11||e.nodeType===9)return e}function ub(n){for(;n.parentElement;)n=n.parentElement;return yt(n)}function Da(n,e,i){for(;n;){const s=n.closest(e);if(i&&s!==i&&(s!=null&&s.contains(i)))return;if(s)return s;n=ub(n)}}function _i(n,e){const i=e==="::before"?qh:e==="::after"?$h:Hh;if(i&&i.has(n))return i.get(n);const s=n.ownerDocument&&n.ownerDocument.defaultView?n.ownerDocument.defaultView.getComputedStyle(n,e):void 0;return i==null||i.set(n,s),s}function fb(n,e){if(e=e??_i(n),!e)return!0;if(Element.prototype.checkVisibility&&ob.browserNameForWorkarounds!=="webkit"){if(!n.checkVisibility())return!1}else{const i=n.closest("details,summary");if(i!==n&&(i==null?void 0:i.nodeName)==="DETAILS"&&!i.open)return!1}return e.visibility==="visible"}function Fo(n){const e=_i(n);if(!e)return{visible:!0,inline:!1};const i=e.cursor;if(e.display==="contents"){for(let a=n.firstChild;a;a=a.nextSibling){if(a.nodeType===1&&vi(a))return{visible:!0,inline:!1,cursor:i};if(a.nodeType===3&&hb(a))return{visible:!0,inline:!0,cursor:i}}return{visible:!1,inline:!1,cursor:i}}if(!fb(n,e))return{cursor:i,visible:!1,inline:!1};const s=n.getBoundingClientRect();return{rect:s,cursor:i,visible:s.width>0&&s.height>0,inline:e.display==="inline"}}function vi(n){return Fo(n).visible}function hb(n){const e=n.ownerDocument.createRange();e.selectNode(n);const i=e.getBoundingClientRect();return i.width>0&&i.height>0}function st(n){const e=n.tagName;return typeof e=="string"?e.toUpperCase():n instanceof HTMLFormElement?"FORM":n.tagName.toUpperCase()}let Hh,qh,$h,db=0;function Ih(){++db,Hh??(Hh=new Map),qh??(qh=new Map),$h??($h=new Map)}function Vh(){--db||(Hh=void 0,qh=void 0,$h=void 0)}function qy(n){return n.hasAttribute("aria-label")||n.hasAttribute("aria-labelledby")}const $y="article:not([role]), aside:not([role]), main:not([role]), nav:not([role]), section:not([role]), [role=article], [role=complementary], [role=main], [role=navigation], [role=region]",lT=[["aria-atomic",void 0],["aria-busy",void 0],["aria-controls",void 0],["aria-current",void 0],["aria-describedby",void 0],["aria-details",void 0],["aria-dropeffect",void 0],["aria-flowto",void 0],["aria-grabbed",void 0],["aria-hidden",void 0],["aria-keyshortcuts",void 0],["aria-label",["caption","code","deletion","emphasis","generic","insertion","paragraph","presentation","strong","subscript","superscript"]],["aria-labelledby",["caption","code","deletion","emphasis","generic","insertion","paragraph","presentation","strong","subscript","superscript"]],["aria-live",void 0],["aria-owns",void 0],["aria-relevant",void 0],["aria-roledescription",["generic"]]];function pb(n,e){return lT.some(([i,s])=>!(s!=null&&s.includes(e||""))&&n.hasAttribute(i))}function gb(n){return!Number.isNaN(Number(String(n.getAttribute("tabindex"))))}function oT(n){return!Nb(n)&&(cT(n)||gb(n))}function cT(n){const e=st(n);return["BUTTON","DETAILS","SELECT","TEXTAREA"].includes(e)?!0:e==="A"||e==="AREA"?n.hasAttribute("href"):e==="INPUT"?!n.hidden:!1}const Pf={A:n=>n.hasAttribute("href")?"link":null,AREA:n=>n.hasAttribute("href")?"link":null,ARTICLE:()=>"article",ASIDE:()=>"complementary",BLOCKQUOTE:()=>"blockquote",BUTTON:()=>"button",CAPTION:()=>"caption",CODE:()=>"code",DATALIST:()=>"listbox",DD:()=>"definition",DEL:()=>"deletion",DETAILS:()=>"group",DFN:()=>"term",DIALOG:()=>"dialog",DT:()=>"term",EM:()=>"emphasis",FIELDSET:()=>"group",FIGURE:()=>"figure",FOOTER:n=>Da(n,$y)?null:"contentinfo",FORM:n=>qy(n)?"form":null,H1:()=>"heading",H2:()=>"heading",H3:()=>"heading",H4:()=>"heading",H5:()=>"heading",H6:()=>"heading",HEADER:n=>Da(n,$y)?null:"banner",HR:()=>"separator",HTML:()=>"document",IMG:n=>n.getAttribute("alt")===""&&!n.getAttribute("title")&&!pb(n)&&!gb(n)?"presentation":"img",INPUT:n=>{const e=n.type.toLowerCase();if(e==="search")return n.hasAttribute("list")?"combobox":"searchbox";if(["email","tel","text","url",""].includes(e)){const i=gr(n,n.getAttribute("list"))[0];return i&&st(i)==="DATALIST"?"combobox":"textbox"}return e==="hidden"?null:e==="file"?"button":ET[e]||"textbox"},INS:()=>"insertion",LI:()=>"listitem",MAIN:()=>"main",MARK:()=>"mark",MATH:()=>"math",MENU:()=>"list",METER:()=>"meter",NAV:()=>"navigation",OL:()=>"list",OPTGROUP:()=>"group",OPTION:()=>"option",OUTPUT:()=>"status",P:()=>"paragraph",PROGRESS:()=>"progressbar",SEARCH:()=>"search",SECTION:n=>qy(n)?"region":null,SELECT:n=>n.hasAttribute("multiple")||n.size>1?"listbox":"combobox",STRONG:()=>"strong",SUB:()=>"subscript",SUP:()=>"superscript",SVG:()=>"img",TABLE:()=>"table",TBODY:()=>"rowgroup",TD:n=>{const e=Da(n,"table"),i=e?Qo(e):"";return i==="grid"||i==="treegrid"?"gridcell":"cell"},TEXTAREA:()=>"textbox",TFOOT:()=>"rowgroup",TH:n=>{if(n.getAttribute("scope")==="col")return"columnheader";if(n.getAttribute("scope")==="row")return"rowheader";const e=Da(n,"table"),i=e?Qo(e):"";return i==="grid"||i==="treegrid"?"gridcell":"cell"},THEAD:()=>"rowgroup",TIME:()=>"time",TR:()=>"row",UL:()=>"list"},uT={DD:["DL","DIV"],DIV:["DL"],DT:["DL","DIV"],LI:["OL","UL"],TBODY:["TABLE"],TD:["TR"],TFOOT:["TABLE"],TH:["TR"],THEAD:["TABLE"],TR:["THEAD","TBODY","TFOOT","TABLE"]};function Iy(n){var s;const e=((s=Pf[st(n)])==null?void 0:s.call(Pf,n))||"";if(!e)return null;let i=n;for(;i;){const a=yt(i),o=uT[st(i)];if(!o||!a||!o.includes(st(a)))break;const u=Qo(a);if((u==="none"||u==="presentation")&&!mb(a,u))return u;i=a}return e}const fT=["alert","alertdialog","application","article","banner","blockquote","button","caption","cell","checkbox","code","columnheader","combobox","complementary","contentinfo","definition","deletion","dialog","directory","document","emphasis","feed","figure","form","generic","grid","gridcell","group","heading","img","insertion","link","list","listbox","listitem","log","main","mark","marquee","math","meter","menu","menubar","menuitem","menuitemcheckbox","menuitemradio","navigation","none","note","option","paragraph","presentation","progressbar","radio","radiogroup","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","strong","subscript","superscript","switch","tab","table","tablist","tabpanel","term","textbox","time","timer","toolbar","tooltip","tree","treegrid","treeitem"];function Qo(n){return(n.getAttribute("role")||"").split(" ").map(i=>i.trim()).find(i=>fT.includes(i))||null}function mb(n,e){return pb(n,e)||oT(n)}function ft(n){const e=Qo(n);if(!e)return Iy(n);if(e==="none"||e==="presentation"){const i=Iy(n);if(mb(n,i))return i}return e}function yb(n){return n===null?void 0:n.toLowerCase()==="true"}function bb(n){return["STYLE","SCRIPT","NOSCRIPT","TEMPLATE"].includes(st(n))}function rn(n){if(bb(n))return!0;const e=_i(n),i=n.nodeName==="SLOT";if((e==null?void 0:e.display)==="contents"&&!i){for(let a=n.firstChild;a;a=a.nextSibling)if(a.nodeType===1&&!rn(a)||a.nodeType===3&&hb(a))return!1;return!0}return!(n.nodeName==="OPTION"&&!!n.closest("select"))&&!i&&!fb(n,e)?!0:vb(n)}function vb(n){let e=bi==null?void 0:bi.get(n);if(e===void 0){if(e=!1,n.parentElement&&n.parentElement.shadowRoot&&!n.assignedSlot&&(e=!0),!e){const i=_i(n);e=!i||i.display==="none"||yb(n.getAttribute("aria-hidden"))===!0}if(!e){const i=yt(n);i&&(e=vb(i))}bi==null||bi.set(n,e)}return e}function gr(n,e){if(!e)return[];const i=cb(n);if(!i)return[];try{const s=e.split(" ").filter(o=>!!o),a=[];for(const o of s){const u=i.querySelector("#"+CSS.escape(o));u&&!a.includes(u)&&a.push(u)}return a}catch{return[]}}function In(n){return n.trim()}function $a(n){return n.split(" ").map(e=>e.replace(/\r\n/g,`
|
|
113
|
-
`).replace(/[\u200b\u00ad]/g,"").replace(/\s\s*/g," ")).join(" ").trim()}function Vy(n,e){const i=[...n.querySelectorAll(e)];for(const s of gr(n,n.getAttribute("aria-owns")))s.matches(e)&&i.push(s),i.push(...s.querySelectorAll(e));return i}function Ia(n,e){const i=e==="::before"?td:e==="::after"?nd:ed;if(i!=null&&i.has(n))return i==null?void 0:i.get(n);const s=_i(n,e);let a;if(s){const o=s.content;o&&o!=="none"&&o!=="normal"&&s.display!=="none"&&s.visibility!=="hidden"&&(a=hT(n,o,!!e))}return e&&a!==void 0&&((s==null?void 0:s.display)||"inline")!=="inline"&&(a=" "+a+" "),i&&i.set(n,a),a}function hT(n,e,i){if(!(!e||e==="none"||e==="normal"))try{let s=N0(e).filter(f=>!(f instanceof Go));const a=s.findIndex(f=>f instanceof ct&&f.value==="/");if(a!==-1)s=s.slice(a+1);else if(!i)return;const o=[];let u=0;for(;u<s.length;)if(s[u]instanceof Lh)o.push(s[u].value),u++;else if(u+2<s.length&&s[u]instanceof qa&&s[u].value==="attr"&&s[u+1]instanceof jh&&s[u+2]instanceof Rh){const f=s[u+1].value;o.push(n.getAttribute(f)||""),u+=3}else return;return o.join("")}catch{}}function Sb(n){const e=n.getAttribute("aria-labelledby");if(e===null)return null;const i=gr(n,e);return i.length?i:null}function dT(n,e){const i=["button","cell","checkbox","columnheader","gridcell","heading","link","menuitem","menuitemcheckbox","menuitemradio","option","radio","row","rowheader","switch","tab","tooltip","treeitem"].includes(n),s=e&&["","caption","code","contentinfo","definition","deletion","emphasis","insertion","list","listitem","mark","none","paragraph","presentation","region","row","rowgroup","section","strong","subscript","superscript","table","term","time"].includes(n);return i||s}function Qa(n,e){const i=e?Zh:Qh;let s=i==null?void 0:i.get(n);return s===void 0&&(s="",["caption","code","definition","deletion","emphasis","generic","insertion","mark","paragraph","presentation","strong","subscript","suggestion","superscript","term","time"].includes(ft(n)||"")||(s=$a(dn(n,{includeHidden:e,visitedElements:new Set,embeddedInTargetElement:"self"}))),i==null||i.set(n,s)),s}function Gy(n,e){const i=e?Wh:Jh;let s=i==null?void 0:i.get(n);if(s===void 0){if(s="",n.hasAttribute("aria-describedby")){const a=gr(n,n.getAttribute("aria-describedby"));s=$a(a.map(o=>dn(o,{includeHidden:e,visitedElements:new Set,embeddedInDescribedBy:{element:o,hidden:rn(o)}})).join(" "))}else n.hasAttribute("aria-description")?s=$a(n.getAttribute("aria-description")||""):s=$a(n.getAttribute("title")||"");i==null||i.set(n,s)}return s}function pT(n){const e=n.getAttribute("aria-invalid");return!e||e.trim()===""||e.toLocaleLowerCase()==="false"?"false":e==="true"||e==="grammar"||e==="spelling"?e:"true"}function gT(n){if("validity"in n){const e=n.validity;return(e==null?void 0:e.valid)===!1}return!1}function mT(n){const e=tr;let i=tr==null?void 0:tr.get(n);if(i===void 0){i="";const s=pT(n)!=="false",a=gT(n);if(s||a){const o=n.getAttribute("aria-errormessage");i=gr(n,o).map(d=>$a(dn(d,{visitedElements:new Set,embeddedInDescribedBy:{element:d,hidden:rn(d)}}))).join(" ").trim()}e==null||e.set(n,i)}return i}function dn(n,e){var d,p,m,y;if(e.visitedElements.has(n))return"";const i={...e,embeddedInTargetElement:e.embeddedInTargetElement==="self"?"descendant":e.embeddedInTargetElement};if(!e.includeHidden){const b=!!((d=e.embeddedInLabelledBy)!=null&&d.hidden)||!!((p=e.embeddedInDescribedBy)!=null&&p.hidden)||!!((m=e.embeddedInNativeTextAlternative)!=null&&m.hidden)||!!((y=e.embeddedInLabel)!=null&&y.hidden);if(bb(n)||!b&&rn(n))return e.visitedElements.add(n),""}const s=Sb(n);if(!e.embeddedInLabelledBy){const b=(s||[]).map(w=>dn(w,{...e,embeddedInLabelledBy:{element:w,hidden:rn(w)},embeddedInDescribedBy:void 0,embeddedInTargetElement:void 0,embeddedInLabel:void 0,embeddedInNativeTextAlternative:void 0})).join(" ");if(b)return b}const a=ft(n)||"",o=st(n);if(e.embeddedInLabel||e.embeddedInLabelledBy||e.embeddedInTargetElement==="descendant"){const b=[...n.labels||[]].includes(n),w=(s||[]).includes(n);if(!b&&!w){if(a==="textbox")return e.visitedElements.add(n),o==="INPUT"||o==="TEXTAREA"?n.value:n.textContent||"";if(["combobox","listbox"].includes(a)){e.visitedElements.add(n);let E;if(o==="SELECT")E=[...n.selectedOptions],!E.length&&n.options.length&&E.push(n.options[0]);else{const x=a==="combobox"?Vy(n,"*").find(_=>ft(_)==="listbox"):n;E=x?Vy(x,'[aria-selected="true"]').filter(_=>ft(_)==="option"):[]}return!E.length&&o==="INPUT"?n.value:E.map(x=>dn(x,i)).join(" ")}if(["progressbar","scrollbar","slider","spinbutton","meter"].includes(a))return e.visitedElements.add(n),n.hasAttribute("aria-valuetext")?n.getAttribute("aria-valuetext")||"":n.hasAttribute("aria-valuenow")?n.getAttribute("aria-valuenow")||"":n.getAttribute("value")||"";if(["menu"].includes(a))return e.visitedElements.add(n),""}}const u=n.getAttribute("aria-label")||"";if(In(u))return e.visitedElements.add(n),u;if(!["presentation","none"].includes(a)){if(o==="INPUT"&&["button","submit","reset"].includes(n.type)){e.visitedElements.add(n);const b=n.value||"";return In(b)?b:n.type==="submit"?"Submit":n.type==="reset"?"Reset":n.getAttribute("title")||""}if(o==="INPUT"&&n.type==="file"){e.visitedElements.add(n);const b=n.labels||[];return b.length&&!e.embeddedInLabelledBy?Na(b,e):"Choose File"}if(o==="INPUT"&&n.type==="image"){e.visitedElements.add(n);const b=n.labels||[];if(b.length&&!e.embeddedInLabelledBy)return Na(b,e);const w=n.getAttribute("alt")||"";if(In(w))return w;const E=n.getAttribute("title")||"";return In(E)?E:"Submit"}if(!s&&o==="BUTTON"){e.visitedElements.add(n);const b=n.labels||[];if(b.length)return Na(b,e)}if(!s&&o==="OUTPUT"){e.visitedElements.add(n);const b=n.labels||[];return b.length?Na(b,e):n.getAttribute("title")||""}if(!s&&(o==="TEXTAREA"||o==="SELECT"||o==="INPUT")){e.visitedElements.add(n);const b=n.labels||[];if(b.length)return Na(b,e);const w=o==="INPUT"&&["text","password","search","tel","email","url"].includes(n.type)||o==="TEXTAREA",E=n.getAttribute("placeholder")||"",x=n.getAttribute("title")||"";return!w||x?x:E}if(!s&&o==="FIELDSET"){e.visitedElements.add(n);for(let w=n.firstElementChild;w;w=w.nextElementSibling)if(st(w)==="LEGEND")return dn(w,{...i,embeddedInNativeTextAlternative:{element:w,hidden:rn(w)}});return n.getAttribute("title")||""}if(!s&&o==="FIGURE"){e.visitedElements.add(n);for(let w=n.firstElementChild;w;w=w.nextElementSibling)if(st(w)==="FIGCAPTION")return dn(w,{...i,embeddedInNativeTextAlternative:{element:w,hidden:rn(w)}});return n.getAttribute("title")||""}if(o==="IMG"){e.visitedElements.add(n);const b=n.getAttribute("alt")||"";return In(b)?b:n.getAttribute("title")||""}if(o==="TABLE"){e.visitedElements.add(n);for(let w=n.firstElementChild;w;w=w.nextElementSibling)if(st(w)==="CAPTION")return dn(w,{...i,embeddedInNativeTextAlternative:{element:w,hidden:rn(w)}});const b=n.getAttribute("summary")||"";if(b)return b}if(o==="AREA"){e.visitedElements.add(n);const b=n.getAttribute("alt")||"";return In(b)?b:n.getAttribute("title")||""}if(o==="SVG"||n.ownerSVGElement){e.visitedElements.add(n);for(let b=n.firstElementChild;b;b=b.nextElementSibling)if(st(b)==="TITLE"&&b.ownerSVGElement)return dn(b,{...i,embeddedInLabelledBy:{element:b,hidden:rn(b)}})}if(n.ownerSVGElement&&o==="A"){const b=n.getAttribute("xlink:title")||"";if(In(b))return e.visitedElements.add(n),b}}const f=o==="SUMMARY"&&!["presentation","none"].includes(a);if(dT(a,e.embeddedInTargetElement==="descendant")||f||e.embeddedInLabelledBy||e.embeddedInDescribedBy||e.embeddedInLabel||e.embeddedInNativeTextAlternative){e.visitedElements.add(n);const b=yT(n,i);if(e.embeddedInTargetElement==="self"?In(b):b)return b}if(!["presentation","none"].includes(a)||o==="IFRAME"){e.visitedElements.add(n);const b=n.getAttribute("title")||"";if(In(b))return b}return e.visitedElements.add(n),""}function yT(n,e){const i=[],s=(o,u)=>{var f;if(!(u&&o.assignedSlot))if(o.nodeType===1){const d=((f=_i(o))==null?void 0:f.display)||"inline";let p=dn(o,e);(d!=="inline"||o.nodeName==="BR")&&(p=" "+p+" "),i.push(p)}else o.nodeType===3&&i.push(o.textContent||"")};i.push(Ia(n,"::before")||"");const a=Ia(n);if(a!==void 0)i.push(a);else{const o=n.nodeName==="SLOT"?n.assignedNodes():[];if(o.length)for(const u of o)s(u,!1);else{for(let u=n.firstChild;u;u=u.nextSibling)s(u,!0);if(n.shadowRoot)for(let u=n.shadowRoot.firstChild;u;u=u.nextSibling)s(u,!0);for(const u of gr(n,n.getAttribute("aria-owns")))s(u,!0)}}return i.push(Ia(n,"::after")||""),i.join("")}const Gh=["gridcell","option","row","tab","rowheader","columnheader","treeitem"];function wb(n){return st(n)==="OPTION"?n.selected:Gh.includes(ft(n)||"")?yb(n.getAttribute("aria-selected"))===!0:!1}const Kh=["checkbox","menuitemcheckbox","option","radio","switch","menuitemradio","treeitem"];function xb(n){const e=Yh(n,!0);return e==="error"?!1:e}function bT(n){return Yh(n,!0)}function vT(n){return Yh(n,!1)}function Yh(n,e){const i=st(n);if(e&&i==="INPUT"&&n.indeterminate)return"mixed";if(i==="INPUT"&&["checkbox","radio"].includes(n.type))return n.checked;if(Kh.includes(ft(n)||"")){const s=n.getAttribute("aria-checked");return s==="true"?!0:e&&s==="mixed"?"mixed":!1}return"error"}const ST=["checkbox","combobox","grid","gridcell","listbox","radiogroup","slider","spinbutton","textbox","columnheader","rowheader","searchbox","switch","treegrid"];function wT(n){const e=st(n);return["INPUT","TEXTAREA","SELECT"].includes(e)?n.hasAttribute("readonly"):ST.includes(ft(n)||"")?n.getAttribute("aria-readonly")==="true":n.isContentEditable?!1:"error"}const Xh=["button"];function _b(n){if(Xh.includes(ft(n)||"")){const e=n.getAttribute("aria-pressed");if(e==="true")return!0;if(e==="mixed")return"mixed"}return!1}const Ph=["application","button","checkbox","combobox","gridcell","link","listbox","menuitem","row","rowheader","tab","treeitem","columnheader","menuitemcheckbox","menuitemradio","rowheader","switch"];function Tb(n){if(st(n)==="DETAILS")return n.open;if(Ph.includes(ft(n)||"")){const e=n.getAttribute("aria-expanded");return e===null?void 0:e==="true"}}const Fh=["heading","listitem","row","treeitem"];function Eb(n){const e={H1:1,H2:2,H3:3,H4:4,H5:5,H6:6}[st(n)];if(e)return e;if(Fh.includes(ft(n)||"")){const i=n.getAttribute("aria-level"),s=i===null?Number.NaN:Number(i);if(Number.isInteger(s)&&s>=1)return s}return 0}const Ab=["application","button","composite","gridcell","group","input","link","menuitem","scrollbar","separator","tab","checkbox","columnheader","combobox","grid","listbox","menu","menubar","menuitemcheckbox","menuitemradio","option","radio","radiogroup","row","rowheader","searchbox","select","slider","spinbutton","switch","tablist","textbox","toolbar","tree","treegrid","treeitem"];function Zo(n){return Nb(n)||Cb(n)}function Nb(n){return["BUTTON","INPUT","SELECT","TEXTAREA","OPTION","OPTGROUP"].includes(st(n))&&(n.hasAttribute("disabled")||xT(n)||_T(n))}function xT(n){return st(n)==="OPTION"&&!!n.closest("OPTGROUP[DISABLED]")}function _T(n){const e=n==null?void 0:n.closest("FIELDSET[DISABLED]");if(!e)return!1;const i=e.querySelector(":scope > LEGEND");return!i||!i.contains(n)}function Cb(n,e=!1){if(!n)return!1;if(e||Ab.includes(ft(n)||"")){const i=(n.getAttribute("aria-disabled")||"").toLowerCase();return i==="true"?!0:i==="false"?!1:Cb(yt(n),!0)}return!1}function Na(n,e){return[...n].map(i=>dn(i,{...e,embeddedInLabel:{element:i,hidden:rn(i)},embeddedInNativeTextAlternative:void 0,embeddedInLabelledBy:void 0,embeddedInDescribedBy:void 0,embeddedInTargetElement:void 0})).filter(i=>!!i).join(" ")}function TT(n){const e=id;let i=n,s;const a=[];for(;i;i=yt(i)){const o=e.get(i);if(o!==void 0){s=o;break}a.push(i);const u=_i(i);if(!u){s=!0;break}const f=u.pointerEvents;if(f){s=f!=="none";break}}s===void 0&&(s=!0);for(const o of a)e.set(o,s);return s}let Qh,Zh,Jh,Wh,tr,bi,ed,td,nd,id,kb=0;function lc(){Ih(),++kb,Qh??(Qh=new Map),Zh??(Zh=new Map),Jh??(Jh=new Map),Wh??(Wh=new Map),tr??(tr=new Map),bi??(bi=new Map),ed??(ed=new Map),td??(td=new Map),nd??(nd=new Map),id??(id=new Map)}function oc(){--kb||(Qh=void 0,Zh=void 0,Jh=void 0,Wh=void 0,tr=void 0,bi=void 0,ed=void 0,td=void 0,nd=void 0,id=void 0),Vh()}const ET={button:"button",checkbox:"checkbox",image:"button",number:"spinbutton",radio:"radio",range:"slider",reset:"button",submit:"button"};function AT(n){return Mb(n)?"'"+n.replace(/'/g,"''")+"'":n}function Ff(n){return Mb(n)?'"'+n.replace(/[\\"\x00-\x1f\x7f-\x9f]/g,e=>{switch(e){case"\\":return"\\\\";case'"':return'\\"';case"\b":return"\\b";case"\f":return"\\f";case`
|
|
114
|
-
`:return"\\n";case"\r":return"\\r";case" ":return"\\t";default:return"\\x"+e.charCodeAt(0).toString(16).padStart(2,"0")}})+'"':n}function Mb(n){return!!(n.length===0||/^\s|\s$/.test(n)||/[\x00-\x08\x0b\x0c\x0e-\x1f\x7f-\x9f]/.test(n)||/^-/.test(n)||/[\n:](\s|$)/.test(n)||/\s#/.test(n)||/[\n\r]/.test(n)||/^[&*\],?!>|@"'#%]/.test(n)||/[{}`]/.test(n)||/^\[/.test(n)||!isNaN(Number(n))||["y","n","yes","no","true","false","on","off","null"].includes(n.toLowerCase()))}let
|
|
115
|
-
`)}function BT(n){const e=[{regex:/\b[\d,.]+[bkmBKM]+\b/,replacement:"[\\d,.]+[bkmBKM]+"},{regex:/\b\d+[hmsp]+\b/,replacement:"\\d+[hmsp]+"},{regex:/\b[\d,.]+[hmsp]+\b/,replacement:"[\\d,.]+[hmsp]+"},{regex:/\b\d+,\d+\b/,replacement:"\\d+,\\d+"},{regex:/\b\d+\.\d{2,}\b/,replacement:"\\d+\\.\\d+"},{regex:/\b\d{2,}\.\d+\b/,replacement:"\\d+\\.\\d+"},{regex:/\b\d{2,}\b/,replacement:"\\d+"}];let i="",s=0;const a=new RegExp(e.map(o=>"("+o.regex.source+")").join("|"),"g");return n.replace(a,(o,...u)=>{const f=u[u.length-2],d=u.slice(0,-2);i+=Yo(n.slice(s,f));for(let p=0;p<d.length;p++)if(d[p]){const{replacement:m}=e[p];i+=m;break}return s=f+o.length,o}),i?(i+=Yo(n.slice(s)),String(new RegExp(i))):n}function UT(n,e){if(!e.length)return!1;if(!n.name)return!0;if(n.name.length>e.length)return!1;const i=e.length<=200&&n.name.length<=200?xx(e,n.name):"";let s=e;for(;i&&s.includes(i);)s=s.replace(i,"");return s.trim().length/e.length>.1}function Fy(n){return n.box.cursor==="pointer"}const Qy=":host{font-size:13px;font-family:system-ui,Ubuntu,Droid Sans,sans-serif;color:#333}svg{position:absolute;height:0}x-pw-tooltip{-webkit-backdrop-filter:blur(5px);backdrop-filter:blur(5px);background-color:#fff;border-radius:6px;box-shadow:0 .5rem 1.2rem #0000004d;display:none;font-size:12.8px;font-weight:400;left:0;line-height:1.5;max-width:600px;position:absolute;top:0;padding:0;flex-direction:column;overflow:hidden}x-pw-tooltip-line{display:flex;max-width:600px;padding:6px;-webkit-user-select:none;user-select:none;cursor:pointer}x-pw-tooltip-footer{display:flex;max-width:600px;padding:6px;-webkit-user-select:none;user-select:none;color:#777}x-pw-dialog{background-color:#fff;pointer-events:auto;border-radius:6px;box-shadow:0 .5rem 1.2rem #0000004d;display:flex;flex-direction:column;position:absolute;z-index:10;font-size:13px}x-pw-dialog:not(.autosize){width:400px;height:150px}x-pw-dialog-body{display:flex;flex-direction:column;flex:auto}x-pw-dialog-body label{margin:5px 8px;display:flex;flex-direction:row;align-items:center}x-pw-highlight{position:absolute;top:0;left:0;width:0;height:0}x-pw-action-point{position:absolute;width:20px;height:20px;background:red;border-radius:10px;margin:-10px 0 0 -10px;z-index:2}x-pw-separator{height:1px;margin:6px 9px;background:#949494e5}x-pw-tool-gripper{height:28px;width:24px;margin:2px 0;cursor:grab}x-pw-tool-gripper:active{cursor:grabbing}x-pw-tool-gripper>x-div{width:16px;height:16px;margin:6px 4px;clip-path:url(#icon-gripper);background-color:#555}x-pw-tools-list>label{display:flex;align-items:center;margin:0 10px;-webkit-user-select:none;user-select:none}x-pw-tools-list{display:flex;width:100%;border-bottom:1px solid #dddddd}x-pw-tool-item{pointer-events:auto;height:28px;width:28px;border-radius:3px}x-pw-tool-item:not(.disabled){cursor:pointer}x-pw-tool-item:not(.disabled):hover{background-color:#dbdbdb}x-pw-tool-item.toggled{background-color:#8acae480}x-pw-tool-item.toggled:not(.disabled):hover{background-color:#8acae4c4}x-pw-tool-item>x-div{width:16px;height:16px;margin:6px;background-color:#3a3a3a}x-pw-tool-item.disabled>x-div{background-color:#61616180;cursor:default}x-pw-tool-item.record.toggled{background-color:transparent}x-pw-tool-item.record.toggled:not(.disabled):hover{background-color:#dbdbdb}x-pw-tool-item.record.toggled>x-div{background-color:#a1260d}x-pw-tool-item.record.disabled.toggled>x-div{opacity:.8}x-pw-tool-item.accept>x-div{background-color:#388a34}x-pw-tool-item.record>x-div{clip-path:url(#icon-circle-large-filled)}x-pw-tool-item.record.toggled>x-div{clip-path:url(#icon-stop-circle)}x-pw-tool-item.pick-locator>x-div{clip-path:url(#icon-inspect)}x-pw-tool-item.text>x-div{clip-path:url(#icon-whole-word)}x-pw-tool-item.visibility>x-div{clip-path:url(#icon-eye)}x-pw-tool-item.value>x-div{clip-path:url(#icon-symbol-constant)}x-pw-tool-item.snapshot>x-div{clip-path:url(#icon-gist)}x-pw-tool-item.accept>x-div{clip-path:url(#icon-check)}x-pw-tool-item.cancel>x-div{clip-path:url(#icon-close)}x-pw-tool-item.succeeded>x-div{clip-path:url(#icon-pass);background-color:#388a34!important}x-pw-overlay{position:absolute;top:0;max-width:min-content;z-index:2147483647;background:transparent;pointer-events:auto}x-pw-overlay x-pw-tools-list{background-color:#fffd;box-shadow:#0000001a 0 5px 5px;border-radius:3px;border-bottom:none}x-pw-overlay x-pw-tool-item{margin:2px}textarea.text-editor{font-family:system-ui,Ubuntu,Droid Sans,sans-serif;flex:auto;border:none;margin:6px 10px;color:#333;outline:1px solid transparent!important;resize:none;padding:0;font-size:13px}textarea.text-editor.does-not-match{outline:1px solid red!important}x-div{display:block}x-spacer{flex:auto}*{box-sizing:border-box}*[hidden]{display:none!important}x-locator-editor{flex:none;width:100%;height:60px;padding:4px;border-bottom:1px solid #dddddd;outline:1px solid transparent}x-locator-editor.does-not-match{outline:1px solid red}.CodeMirror{width:100%!important;height:100%!important}x-pw-action-list{flex:auto;display:flex;flex-direction:column;-webkit-user-select:none;user-select:none}x-pw-action-item{padding:6px 10px;cursor:pointer;overflow:hidden}x-pw-action-item:hover{background-color:#f2f2f2}x-pw-action-item:last-child{border-bottom-left-radius:6px;border-bottom-right-radius:6px}";class Zf{constructor(e){this._renderedEntries=[],this._language="javascript",this._injectedScript=e;const i=e.document;if(this._isUnderTest=e.isUnderTest,this._glassPaneElement=i.createElement("x-pw-glass"),this._glassPaneElement.style.position="fixed",this._glassPaneElement.style.top="0",this._glassPaneElement.style.right="0",this._glassPaneElement.style.bottom="0",this._glassPaneElement.style.left="0",this._glassPaneElement.style.zIndex="2147483647",this._glassPaneElement.style.pointerEvents="none",this._glassPaneElement.style.display="flex",this._glassPaneElement.style.backgroundColor="transparent",this._actionPointElement=i.createElement("x-pw-action-point"),this._actionPointElement.setAttribute("hidden","true"),this._glassPaneShadow=this._glassPaneElement.attachShadow({mode:this._isUnderTest?"open":"closed"}),typeof this._glassPaneShadow.adoptedStyleSheets.push=="function"){const s=new this._injectedScript.window.CSSStyleSheet;s.replaceSync(Qy),this._glassPaneShadow.adoptedStyleSheets.push(s)}else{const s=this._injectedScript.document.createElement("style");s.textContent=Qy,this._glassPaneShadow.appendChild(s)}this._glassPaneShadow.appendChild(this._actionPointElement)}install(){this._injectedScript.document.documentElement&&(!this._injectedScript.document.documentElement.contains(this._glassPaneElement)||this._glassPaneElement.nextElementSibling)&&this._injectedScript.document.documentElement.appendChild(this._glassPaneElement)}setLanguage(e){this._language=e}runHighlightOnRaf(e){this._rafRequest&&this._injectedScript.utils.builtins.cancelAnimationFrame(this._rafRequest);const i=this._injectedScript.querySelectorAll(e,this._injectedScript.document.documentElement),s=Wi(this._language,Gn(e)),a=i.length>1?"#f6b26b7f":"#6fa8dc7f";this.updateHighlight(i.map((o,u)=>{const f=i.length>1?` [${u+1} of ${i.length}]`:"";return{element:o,color:a,tooltipText:s+f}})),this._rafRequest=this._injectedScript.utils.builtins.requestAnimationFrame(()=>this.runHighlightOnRaf(e))}uninstall(){this._rafRequest&&this._injectedScript.utils.builtins.cancelAnimationFrame(this._rafRequest),this._glassPaneElement.remove()}showActionPoint(e,i){this._actionPointElement.style.top=i+"px",this._actionPointElement.style.left=e+"px",this._actionPointElement.hidden=!1}hideActionPoint(){this._actionPointElement.hidden=!0}clearHighlight(){var e,i;for(const s of this._renderedEntries)(e=s.highlightElement)==null||e.remove(),(i=s.tooltipElement)==null||i.remove();this._renderedEntries=[]}maskElements(e,i){this.updateHighlight(e.map(s=>({element:s,color:i})))}updateHighlight(e){if(!this._highlightIsUpToDate(e)){this.clearHighlight();for(const i of e){const s=this._createHighlightElement();this._glassPaneShadow.appendChild(s);let a;if(i.tooltipText){a=this._injectedScript.document.createElement("x-pw-tooltip"),this._glassPaneShadow.appendChild(a),a.style.top="0",a.style.left="0",a.style.display="flex";const o=this._injectedScript.document.createElement("x-pw-tooltip-line");o.textContent=i.tooltipText,a.appendChild(o)}this._renderedEntries.push({targetElement:i.element,color:i.color,tooltipElement:a,highlightElement:s})}for(const i of this._renderedEntries){if(i.box=i.targetElement.getBoundingClientRect(),!i.tooltipElement)continue;const{anchorLeft:s,anchorTop:a}=this.tooltipPosition(i.box,i.tooltipElement);i.tooltipTop=a,i.tooltipLeft=s}for(const i of this._renderedEntries){i.tooltipElement&&(i.tooltipElement.style.top=i.tooltipTop+"px",i.tooltipElement.style.left=i.tooltipLeft+"px");const s=i.box;i.highlightElement.style.backgroundColor=i.color,i.highlightElement.style.left=s.x+"px",i.highlightElement.style.top=s.y+"px",i.highlightElement.style.width=s.width+"px",i.highlightElement.style.height=s.height+"px",i.highlightElement.style.display="block",this._isUnderTest&&console.error("Highlight box for test: "+JSON.stringify({x:s.x,y:s.y,width:s.width,height:s.height}))}}}firstBox(){var e;return(e=this._renderedEntries[0])==null?void 0:e.box}firstTooltipBox(){const e=this._renderedEntries[0];if(!(!e||!e.tooltipElement||e.tooltipLeft===void 0||e.tooltipTop===void 0))return{x:e.tooltipLeft,y:e.tooltipTop,left:e.tooltipLeft,top:e.tooltipTop,width:e.tooltipElement.offsetWidth,height:e.tooltipElement.offsetHeight,bottom:e.tooltipTop+e.tooltipElement.offsetHeight,right:e.tooltipLeft+e.tooltipElement.offsetWidth,toJSON:()=>{}}}tooltipPosition(e,i){const s=i.offsetWidth,a=i.offsetHeight,o=this._glassPaneElement.offsetWidth,u=this._glassPaneElement.offsetHeight;let f=Math.max(5,e.left);f+s>o-5&&(f=o-s-5);let d=Math.max(0,e.bottom)+5;return d+a>u-5&&(Math.max(0,e.top)>a+5?d=Math.max(0,e.top)-a-5:d=u-5-a),{anchorLeft:f,anchorTop:d}}_highlightIsUpToDate(e){if(e.length!==this._renderedEntries.length)return!1;for(let i=0;i<this._renderedEntries.length;++i){if(e[i].element!==this._renderedEntries[i].targetElement||e[i].color!==this._renderedEntries[i].color)return!1;const s=this._renderedEntries[i].box;if(!s)return!1;const a=e[i].element.getBoundingClientRect();if(a.top!==s.top||a.right!==s.right||a.bottom!==s.bottom||a.left!==s.left)return!1}return!0}_createHighlightElement(){return this._injectedScript.document.createElement("x-pw-highlight")}appendChild(e){this._glassPaneShadow.appendChild(e)}onGlassPaneClick(e){this._glassPaneElement.style.pointerEvents="auto",this._glassPaneElement.style.backgroundColor="rgba(0, 0, 0, 0.3)",this._glassPaneElement.addEventListener("click",e)}offGlassPaneClick(e){this._glassPaneElement.style.pointerEvents="none",this._glassPaneElement.style.backgroundColor="transparent",this._glassPaneElement.removeEventListener("click",e)}}function zT(n,e,i){const s=n.left-e.right;if(!(s<0||i!==void 0&&s>i))return s+Math.max(e.bottom-n.bottom,0)+Math.max(n.top-e.top,0)}function HT(n,e,i){const s=e.left-n.right;if(!(s<0||i!==void 0&&s>i))return s+Math.max(e.bottom-n.bottom,0)+Math.max(n.top-e.top,0)}function qT(n,e,i){const s=e.top-n.bottom;if(!(s<0||i!==void 0&&s>i))return s+Math.max(n.left-e.left,0)+Math.max(e.right-n.right,0)}function $T(n,e,i){const s=n.top-e.bottom;if(!(s<0||i!==void 0&&s>i))return s+Math.max(n.left-e.left,0)+Math.max(e.right-n.right,0)}function IT(n,e,i){const s=i===void 0?50:i;let a=0;return n.left-e.right>=0&&(a+=n.left-e.right),e.left-n.right>=0&&(a+=e.left-n.right),e.top-n.bottom>=0&&(a+=e.top-n.bottom),n.top-e.bottom>=0&&(a+=n.top-e.bottom),a>s?void 0:a}const VT=["left-of","right-of","above","below","near"];function Lb(n,e,i,s){const a=e.getBoundingClientRect(),o={"left-of":HT,"right-of":zT,above:qT,below:$T,near:IT}[n];let u;for(const f of i){if(f===e)continue;const d=o(a,f.getBoundingClientRect(),s);d!==void 0&&(u===void 0||d<u)&&(u=d)}return u}function Db(n,e){for(const i of e.jsonPath)n!=null&&(n=n[i]);return Bb(n,e)}function Bb(n,e){const i=typeof n=="string"&&!e.caseSensitive?n.toUpperCase():n,s=typeof e.value=="string"&&!e.caseSensitive?e.value.toUpperCase():e.value;return e.op==="<truthy>"?!!i:e.op==="="?s instanceof RegExp?typeof i=="string"&&!!i.match(s):i===s:typeof i!="string"||typeof s!="string"?!1:e.op==="*="?i.includes(s):e.op==="^="?i.startsWith(s):e.op==="$="?i.endsWith(s):e.op==="|="?i===s||i.startsWith(s+"-"):e.op==="~="?i.split(" ").includes(s):!1}function rd(n){const e=n.ownerDocument;return n.nodeName==="SCRIPT"||n.nodeName==="NOSCRIPT"||n.nodeName==="STYLE"||e.head&&e.head.contains(n)}function Bt(n,e){let i=n.get(e);if(i===void 0){if(i={full:"",normalized:"",immediate:[]},!rd(e)){let s="";if(e instanceof HTMLInputElement&&(e.type==="submit"||e.type==="button"))i={full:e.value,normalized:Tt(e.value),immediate:[e.value]};else{for(let a=e.firstChild;a;a=a.nextSibling)if(a.nodeType===Node.TEXT_NODE)i.full+=a.nodeValue||"",s+=a.nodeValue||"";else{if(a.nodeType===Node.COMMENT_NODE)continue;s&&i.immediate.push(s),s="",a.nodeType===Node.ELEMENT_NODE&&(i.full+=Bt(n,a).full)}s&&i.immediate.push(s),e.shadowRoot&&(i.full+=Bt(n,e.shadowRoot).full),i.full&&(i.normalized=Tt(i.full))}}n.set(e,i)}return i}function cc(n,e,i){if(rd(e)||!i(Bt(n,e)))return"none";for(let s=e.firstChild;s;s=s.nextSibling)if(s.nodeType===Node.ELEMENT_NODE&&i(Bt(n,s)))return"selfAndChildren";return e.shadowRoot&&i(Bt(n,e.shadowRoot))?"selfAndChildren":"self"}function Ub(n,e){const i=Sb(e);if(i)return i.map(o=>Bt(n,o));const s=e.getAttribute("aria-label");if(s!==null&&s.trim())return[{full:s,normalized:Tt(s),immediate:[s]}];const a=e.nodeName==="INPUT"&&e.type!=="hidden";if(["BUTTON","METER","OUTPUT","PROGRESS","SELECT","TEXTAREA"].includes(e.nodeName)||a){const o=e.labels;if(o)return[...o].map(u=>Bt(n,u))}return[]}function Zy(n){return n.displayName||n.name||"Anonymous"}function GT(n){if(n.type)switch(typeof n.type){case"function":return Zy(n.type);case"string":return n.type;case"object":return n.type.displayName||(n.type.render?Zy(n.type.render):"")}if(n._currentElement){const e=n._currentElement.type;if(typeof e=="string")return e;if(typeof e=="function")return e.displayName||e.name||"Anonymous"}return""}function KT(n){var e;return n.key??((e=n._currentElement)==null?void 0:e.key)}function YT(n){if(n.child){const i=[];for(let s=n.child;s;s=s.sibling)i.push(s);return i}if(!n._currentElement)return[];const e=i=>{var a;const s=(a=i._currentElement)==null?void 0:a.type;return typeof s=="function"||typeof s=="string"};if(n._renderedComponent){const i=n._renderedComponent;return e(i)?[i]:[]}return n._renderedChildren?[...Object.values(n._renderedChildren)].filter(e):[]}function XT(n){var s;const e=n.memoizedProps||((s=n._currentElement)==null?void 0:s.props);if(!e||typeof e=="string")return e;const i={...e};return delete i.children,i}function zb(n){var s;const e={key:KT(n),name:GT(n),children:YT(n).map(zb),rootElements:[],props:XT(n)},i=n.stateNode||n._hostNode||((s=n._renderedComponent)==null?void 0:s._hostNode);if(i instanceof Element)e.rootElements.push(i);else for(const a of e.children)e.rootElements.push(...a.rootElements);return e}function Hb(n,e,i=[]){e(n)&&i.push(n);for(const s of n.children)Hb(s,e,i);return i}function qb(n,e=[]){const s=(n.ownerDocument||n).createTreeWalker(n,NodeFilter.SHOW_ELEMENT);do{const a=s.currentNode,o=a,u=Object.keys(o).find(d=>d.startsWith("__reactContainer")&&o[d]!==null);if(u)e.push(o[u].stateNode.current);else{const d="_reactRootContainer";o.hasOwnProperty(d)&&o[d]!==null&&e.push(o[d]._internalRoot.current)}if(a instanceof Element&&a.hasAttribute("data-reactroot"))for(const d of Object.keys(a))(d.startsWith("__reactInternalInstance")||d.startsWith("__reactFiber"))&&e.push(a[d]);const f=a instanceof Element?a.shadowRoot:null;f&&qb(f,e)}while(s.nextNode());return e}const PT=()=>({queryAll(n,e){const{name:i,attributes:s}=Ji(e,!1),u=qb(n.ownerDocument||n).map(d=>zb(d)).map(d=>Hb(d,p=>{const m=p.props??{};if(p.key!==void 0&&(m.key=p.key),i&&p.name!==i||p.rootElements.some(y=>!Fa(n,y)))return!1;for(const y of s)if(!Db(m,y))return!1;return!0})).flat(),f=new Set;for(const d of u)for(const p of d.rootElements)f.add(p);return[...f]}}),$b=["selected","checked","pressed","expanded","level","disabled","name","include-hidden"];$b.sort();function Ca(n,e,i){if(!e.includes(i))throw new Error(`"${n}" attribute is only supported for roles: ${e.slice().sort().map(s=>`"${s}"`).join(", ")}`)}function Ps(n,e){if(n.op!=="<truthy>"&&!e.includes(n.value))throw new Error(`"${n.name}" must be one of ${e.map(i=>JSON.stringify(i)).join(", ")}`)}function Fs(n,e){if(!e.includes(n.op))throw new Error(`"${n.name}" does not support "${n.op}" matcher`)}function FT(n,e){const i={role:e};for(const s of n)switch(s.name){case"checked":{Ca(s.name,Kh,e),Ps(s,[!0,!1,"mixed"]),Fs(s,["<truthy>","="]),i.checked=s.op==="<truthy>"?!0:s.value;break}case"pressed":{Ca(s.name,Xh,e),Ps(s,[!0,!1,"mixed"]),Fs(s,["<truthy>","="]),i.pressed=s.op==="<truthy>"?!0:s.value;break}case"selected":{Ca(s.name,Gh,e),Ps(s,[!0,!1]),Fs(s,["<truthy>","="]),i.selected=s.op==="<truthy>"?!0:s.value;break}case"expanded":{Ca(s.name,Ph,e),Ps(s,[!0,!1]),Fs(s,["<truthy>","="]),i.expanded=s.op==="<truthy>"?!0:s.value;break}case"level":{if(Ca(s.name,Fh,e),typeof s.value=="string"&&(s.value=+s.value),s.op!=="="||typeof s.value!="number"||Number.isNaN(s.value))throw new Error('"level" attribute must be compared to a number');i.level=s.value;break}case"disabled":{Ps(s,[!0,!1]),Fs(s,["<truthy>","="]),i.disabled=s.op==="<truthy>"?!0:s.value;break}case"name":{if(s.op==="<truthy>")throw new Error('"name" attribute must have a value');if(typeof s.value!="string"&&!(s.value instanceof RegExp))throw new Error('"name" attribute must be a string or a regular expression');i.name=s.value,i.nameOp=s.op,i.exact=s.caseSensitive;break}case"include-hidden":{Ps(s,[!0,!1]),Fs(s,["<truthy>","="]),i.includeHidden=s.op==="<truthy>"?!0:s.value;break}default:throw new Error(`Unknown attribute "${s.name}", must be one of ${$b.map(a=>`"${a}"`).join(", ")}.`)}return i}function QT(n,e,i){const s=[],a=u=>{if(ft(u)===e.role&&!(e.selected!==void 0&&wb(u)!==e.selected)&&!(e.checked!==void 0&&xb(u)!==e.checked)&&!(e.pressed!==void 0&&_b(u)!==e.pressed)&&!(e.expanded!==void 0&&Tb(u)!==e.expanded)&&!(e.level!==void 0&&Eb(u)!==e.level)&&!(e.disabled!==void 0&&Zo(u)!==e.disabled)&&!(!e.includeHidden&&rn(u))){if(e.name!==void 0){const f=Tt(Qa(u,!!e.includeHidden));if(typeof e.name=="string"&&(e.name=Tt(e.name)),i&&!e.exact&&e.nameOp==="="&&(e.nameOp="*="),!Bb(f,{op:e.nameOp||"=",value:e.name,caseSensitive:!!e.exact}))return}s.push(u)}},o=u=>{const f=[];u.shadowRoot&&f.push(u.shadowRoot);for(const d of u.querySelectorAll("*"))a(d),d.shadowRoot&&f.push(d.shadowRoot);f.forEach(o)};return o(n),s}function Jy(n){return{queryAll:(e,i)=>{const s=Ji(i,!0),a=s.name.toLowerCase();if(!a)throw new Error("Role must not be empty");const o=FT(s.attributes,a);lc();try{return QT(e,o,n)}finally{oc()}}}}class ZT{constructor(){this._retainCacheCounter=0,this._cacheText=new Map,this._cacheQueryCSS=new Map,this._cacheMatches=new Map,this._cacheQuery=new Map,this._cacheMatchesSimple=new Map,this._cacheMatchesParents=new Map,this._cacheCallMatches=new Map,this._cacheCallQuery=new Map,this._cacheQuerySimple=new Map,this._engines=new Map,this._engines.set("not",eE),this._engines.set("is",Ba),this._engines.set("where",Ba),this._engines.set("has",JT),this._engines.set("scope",WT),this._engines.set("light",tE),this._engines.set("visible",nE),this._engines.set("text",iE),this._engines.set("text-is",sE),this._engines.set("text-matches",rE),this._engines.set("has-text",aE),this._engines.set("right-of",ka("right-of")),this._engines.set("left-of",ka("left-of")),this._engines.set("above",ka("above")),this._engines.set("below",ka("below")),this._engines.set("near",ka("near")),this._engines.set("nth-match",lE);const e=[...this._engines.keys()];e.sort();const i=[...K0];if(i.sort(),e.join("|")!==i.join("|"))throw new Error(`Please keep customCSSNames in sync with evaluator engines: ${e.join("|")} vs ${i.join("|")}`)}begin(){++this._retainCacheCounter}end(){--this._retainCacheCounter,this._retainCacheCounter||(this._cacheQueryCSS.clear(),this._cacheMatches.clear(),this._cacheQuery.clear(),this._cacheMatchesSimple.clear(),this._cacheMatchesParents.clear(),this._cacheCallMatches.clear(),this._cacheCallQuery.clear(),this._cacheQuerySimple.clear(),this._cacheText.clear())}_cached(e,i,s,a){e.has(i)||e.set(i,[]);const o=e.get(i),u=o.find(d=>s.every((p,m)=>d.rest[m]===p));if(u)return u.result;const f=a();return o.push({rest:s,result:f}),f}_checkSelector(e){if(!(typeof e=="object"&&e&&(Array.isArray(e)||"simples"in e&&e.simples.length)))throw new Error(`Malformed selector "${e}"`);return e}matches(e,i,s){const a=this._checkSelector(i);this.begin();try{return this._cached(this._cacheMatches,e,[a,s.scope,s.pierceShadow,s.originalScope],()=>Array.isArray(a)?this._matchesEngine(Ba,e,a,s):(this._hasScopeClause(a)&&(s=this._expandContextForScopeMatching(s)),this._matchesSimple(e,a.simples[a.simples.length-1].selector,s)?this._matchesParents(e,a,a.simples.length-2,s):!1))}finally{this.end()}}query(e,i){const s=this._checkSelector(i);this.begin();try{return this._cached(this._cacheQuery,s,[e.scope,e.pierceShadow,e.originalScope],()=>{if(Array.isArray(s))return this._queryEngine(Ba,e,s);this._hasScopeClause(s)&&(e=this._expandContextForScopeMatching(e));const a=this._scoreMap;this._scoreMap=new Map;let o=this._querySimple(e,s.simples[s.simples.length-1].selector);return o=o.filter(u=>this._matchesParents(u,s,s.simples.length-2,e)),this._scoreMap.size&&o.sort((u,f)=>{const d=this._scoreMap.get(u),p=this._scoreMap.get(f);return d===p?0:d===void 0?1:p===void 0?-1:d-p}),this._scoreMap=a,o})}finally{this.end()}}_markScore(e,i){this._scoreMap&&this._scoreMap.set(e,i)}_hasScopeClause(e){return e.simples.some(i=>i.selector.functions.some(s=>s.name==="scope"))}_expandContextForScopeMatching(e){if(e.scope.nodeType!==1)return e;const i=yt(e.scope);return i?{...e,scope:i,originalScope:e.originalScope||e.scope}:e}_matchesSimple(e,i,s){return this._cached(this._cacheMatchesSimple,e,[i,s.scope,s.pierceShadow,s.originalScope],()=>{if(e===s.scope||i.css&&!this._matchesCSS(e,i.css))return!1;for(const a of i.functions)if(!this._matchesEngine(this._getEngine(a.name),e,a.args,s))return!1;return!0})}_querySimple(e,i){return i.functions.length?this._cached(this._cacheQuerySimple,i,[e.scope,e.pierceShadow,e.originalScope],()=>{let s=i.css;const a=i.functions;s==="*"&&a.length&&(s=void 0);let o,u=-1;s!==void 0?o=this._queryCSS(e,s):(u=a.findIndex(f=>this._getEngine(f.name).query!==void 0),u===-1&&(u=0),o=this._queryEngine(this._getEngine(a[u].name),e,a[u].args));for(let f=0;f<a.length;f++){if(f===u)continue;const d=this._getEngine(a[f].name);d.matches!==void 0&&(o=o.filter(p=>this._matchesEngine(d,p,a[f].args,e)))}for(let f=0;f<a.length;f++){if(f===u)continue;const d=this._getEngine(a[f].name);d.matches===void 0&&(o=o.filter(p=>this._matchesEngine(d,p,a[f].args,e)))}return o}):this._queryCSS(e,i.css||"*")}_matchesParents(e,i,s,a){return s<0?!0:this._cached(this._cacheMatchesParents,e,[i,s,a.scope,a.pierceShadow,a.originalScope],()=>{const{selector:o,combinator:u}=i.simples[s];if(u===">"){const f=So(e,a);return!f||!this._matchesSimple(f,o,a)?!1:this._matchesParents(f,i,s-1,a)}if(u==="+"){const f=Jf(e,a);return!f||!this._matchesSimple(f,o,a)?!1:this._matchesParents(f,i,s-1,a)}if(u===""){let f=So(e,a);for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="")break}f=So(f,a)}return!1}if(u==="~"){let f=Jf(e,a);for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="~")break}f=Jf(f,a)}return!1}if(u===">="){let f=e;for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="")break}f=So(f,a)}return!1}throw new Error(`Unsupported combinator "${u}"`)})}_matchesEngine(e,i,s,a){if(e.matches)return this._callMatches(e,i,s,a);if(e.query)return this._callQuery(e,s,a).includes(i);throw new Error('Selector engine should implement "matches" or "query"')}_queryEngine(e,i,s){if(e.query)return this._callQuery(e,s,i);if(e.matches)return this._queryCSS(i,"*").filter(a=>this._callMatches(e,a,s,i));throw new Error('Selector engine should implement "matches" or "query"')}_callMatches(e,i,s,a){return this._cached(this._cacheCallMatches,i,[e,a.scope,a.pierceShadow,a.originalScope,...s],()=>e.matches(i,s,a,this))}_callQuery(e,i,s){return this._cached(this._cacheCallQuery,e,[s.scope,s.pierceShadow,s.originalScope,...i],()=>e.query(s,i,this))}_matchesCSS(e,i){return e.matches(i)}_queryCSS(e,i){return this._cached(this._cacheQueryCSS,i,[e.scope,e.pierceShadow,e.originalScope],()=>{let s=[];function a(o){if(s=s.concat([...o.querySelectorAll(i)]),!!e.pierceShadow){o.shadowRoot&&a(o.shadowRoot);for(const u of o.querySelectorAll("*"))u.shadowRoot&&a(u.shadowRoot)}}return a(e.scope),s})}_getEngine(e){const i=this._engines.get(e);if(!i)throw new Error(`Unknown selector engine "${e}"`);return i}}const Ba={matches(n,e,i,s){if(e.length===0)throw new Error('"is" engine expects non-empty selector list');return e.some(a=>s.matches(n,a,i))},query(n,e,i){if(e.length===0)throw new Error('"is" engine expects non-empty selector list');let s=[];for(const a of e)s=s.concat(i.query(n,a));return e.length===1?s:Ib(s)}},JT={matches(n,e,i,s){if(e.length===0)throw new Error('"has" engine expects non-empty selector list');return s.query({...i,scope:n},e).length>0}},WT={matches(n,e,i,s){if(e.length!==0)throw new Error('"scope" engine expects no arguments');const a=i.originalScope||i.scope;return a.nodeType===9?n===a.documentElement:n===a},query(n,e,i){if(e.length!==0)throw new Error('"scope" engine expects no arguments');const s=n.originalScope||n.scope;if(s.nodeType===9){const a=s.documentElement;return a?[a]:[]}return s.nodeType===1?[s]:[]}},eE={matches(n,e,i,s){if(e.length===0)throw new Error('"not" engine expects non-empty selector list');return!s.matches(n,e,i)}},tE={query(n,e,i){return i.query({...n,pierceShadow:!1},e)},matches(n,e,i,s){return s.matches(n,e,{...i,pierceShadow:!1})}},nE={matches(n,e,i,s){if(e.length)throw new Error('"visible" engine expects no arguments');return vi(n)}},iE={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"text" engine expects a single string');const a=Tt(e[0]).toLowerCase(),o=u=>u.normalized.toLowerCase().includes(a);return cc(s._cacheText,n,o)==="self"}},sE={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"text-is" engine expects a single string');const a=Tt(e[0]),o=u=>!a&&!u.immediate.length?!0:u.immediate.some(f=>Tt(f)===a);return cc(s._cacheText,n,o)!=="none"}},rE={matches(n,e,i,s){if(e.length===0||typeof e[0]!="string"||e.length>2||e.length===2&&typeof e[1]!="string")throw new Error('"text-matches" engine expects a regexp body and optional regexp flags');const a=new RegExp(e[0],e.length===2?e[1]:void 0),o=u=>a.test(u.full);return cc(s._cacheText,n,o)==="self"}},aE={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"has-text" engine expects a single string');if(rd(n))return!1;const a=Tt(e[0]).toLowerCase();return(u=>u.normalized.toLowerCase().includes(a))(Bt(s._cacheText,n))}};function ka(n){return{matches(e,i,s,a){const o=i.length&&typeof i[i.length-1]=="number"?i[i.length-1]:void 0,u=o===void 0?i:i.slice(0,i.length-1);if(i.length<1+(o===void 0?0:1))throw new Error(`"${n}" engine expects a selector list and optional maximum distance in pixels`);const f=a.query(s,u),d=Lb(n,e,f,o);return d===void 0?!1:(a._markScore(e,d),!0)}}}const lE={query(n,e,i){let s=e[e.length-1];if(e.length<2)throw new Error('"nth-match" engine expects non-empty selector list and an index argument');if(typeof s!="number"||s<1)throw new Error('"nth-match" engine expects a one-based index as the last argument');const a=Ba.query(n,e.slice(0,e.length-1),i);return s--,s<a.length?[a[s]]:[]}};function So(n,e){if(n!==e.scope)return e.pierceShadow?yt(n):n.parentElement||void 0}function Jf(n,e){if(n!==e.scope)return n.previousElementSibling||void 0}function Ib(n){const e=new Map,i=[],s=[];function a(u){let f=e.get(u);if(f)return f;const d=yt(u);return d?a(d).children.push(u):i.push(u),f={children:[],taken:!1},e.set(u,f),f}for(const u of n)a(u).taken=!0;function o(u){const f=e.get(u);if(f.taken&&s.push(u),f.children.length>1){const d=new Set(f.children);f.children=[];let p=u.firstElementChild;for(;p&&f.children.length<d.size;)d.has(p)&&f.children.push(p),p=p.nextElementSibling;for(p=u.shadowRoot?u.shadowRoot.firstElementChild:null;p&&f.children.length<d.size;)d.has(p)&&f.children.push(p),p=p.nextElementSibling}f.children.forEach(o)}return i.forEach(o),s}const Vb=10,mr=Vb/2,Wy=1,oE=2,cE=10,uE=50,Gb=100,Kb=120,Yb=140,Xb=160,Bo=180,Pb=200,e0=250,fE=Kb+mr,hE=Yb+mr,dE=Gb+mr,pE=Xb+mr,gE=Bo+mr,mE=Pb+mr,yE=300,bE=500,Fb=510,Wf=520,Qb=530,yh=1e4,vE=1e7,SE=1e3;function t0(n,e,i){n._evaluator.begin();const s={allowText:new Map,disallowText:new Map};lc(),Ih();try{let a=[];if(i.forTextExpect){let f=Ua(n,e.ownerDocument.documentElement,i);for(let d=e;d;d=yt(d)){const p=Gi(s,n,d,{...i,noText:!0});if(!p)continue;if(Ki(p)<=SE){f=p;break}}a=[Uo(f)]}else{if(!e.matches("input,textarea,select")&&!e.isContentEditable){const f=Da(e,"button,select,input,[role=button],[role=checkbox],[role=radio],a,[role=link]",i.root);f&&vi(f)&&(e=f)}if(i.multiple){const f=Gi(s,n,e,i),d=Gi(s,n,e,{...i,noText:!0});let p=[f,d];if(s.allowText.clear(),s.disallowText.clear(),f&&eh(f)&&p.push(Gi(s,n,e,{...i,noCSSId:!0})),d&&eh(d)&&p.push(Gi(s,n,e,{...i,noText:!0,noCSSId:!0})),p=p.filter(Boolean),!p.length){const m=Ua(n,e,i);p.push(m),eh(m)&&p.push(Ua(n,e,{...i,noCSSId:!0}))}a=[...new Set(p.map(m=>Uo(m)))]}else{const f=Gi(s,n,e,i)||Ua(n,e,i);a=[Uo(f)]}}const o=a[0],u=n.parseSelector(o);return{selector:o,selectors:a,elements:n.querySelectorAll(u,i.root??e.ownerDocument)}}finally{Vh(),oc(),n._evaluator.end()}}function Gi(n,e,i,s){if(s.root&&!Fa(s.root,i))throw new Error("Target element must belong to the root's subtree");if(i===s.root)return[{engine:"css",selector:":scope",score:1}];if(i.ownerDocument.documentElement===i)return[{engine:"css",selector:"html",score:1}];let a=null;const o=f=>{(!a||Ki(f)<Ki(a))&&(a=f)},u=[];if(!s.noText)for(const f of xE(e,i,!s.isRecursive))u.push({candidate:f,isTextCandidate:!0});for(const f of wE(e,i,s))s.omitInternalEngines&&f.engine.startsWith("internal:")||u.push({candidate:[f],isTextCandidate:!1});u.sort((f,d)=>Ki(f.candidate)-Ki(d.candidate));for(const{candidate:f,isTextCandidate:d}of u){const p=e.querySelectorAll(e.parseSelector(Uo(f)),s.root??i.ownerDocument);if(!p.includes(i))continue;if(p.length===1){o(f);break}const m=p.indexOf(i);if(!(m>5)&&(o([...f,{engine:"nth",selector:String(m),score:yh}]),!s.isRecursive))for(let y=yt(i);y&&y!==s.root;y=yt(y)){const b=p.filter(V=>Fa(y,V)&&V!==y),w=b.indexOf(i);if(b.length>5||w===-1||w===m&&b.length>1)continue;const E=b.length===1?f:[...f,{engine:"nth",selector:String(w),score:yh}];if(a&&Ki([{engine:"",selector:"",score:1},...E])>=Ki(a))continue;const _=!!s.noText||d,k=_?n.disallowText:n.allowText;let C=k.get(y);C===void 0&&(C=Gi(n,e,y,{...s,isRecursive:!0,noText:_})||Ua(e,y,s),k.set(y,C)),C&&o([...C,...E])}}return a}function wE(n,e,i){const s=[];{for(const u of["data-testid","data-test-id","data-test"])u!==i.testIdAttributeName&&e.getAttribute(u)&&s.push({engine:"css",selector:`[${u}=${Ws(e.getAttribute(u))}]`,score:oE});if(!i.noCSSId){const u=e.getAttribute("id");u&&!_E(u)&&s.push({engine:"css",selector:Zb(u),score:bE})}s.push({engine:"css",selector:Vn(e),score:Qb})}if(e.nodeName==="IFRAME"){for(const u of["name","title"])e.getAttribute(u)&&s.push({engine:"css",selector:`${Vn(e)}[${u}=${Ws(e.getAttribute(u))}]`,score:cE});return e.getAttribute(i.testIdAttributeName)&&s.push({engine:"css",selector:`[${i.testIdAttributeName}=${Ws(e.getAttribute(i.testIdAttributeName))}]`,score:Wy}),bh([s]),s}if(e.getAttribute(i.testIdAttributeName)&&s.push({engine:"internal:testid",selector:`[${i.testIdAttributeName}=${xt(e.getAttribute(i.testIdAttributeName),!0)}]`,score:Wy}),e.nodeName==="INPUT"||e.nodeName==="TEXTAREA"){const u=e;if(u.placeholder){s.push({engine:"internal:attr",selector:`[placeholder=${xt(u.placeholder,!0)}]`,score:fE});for(const f of nr(u.placeholder))s.push({engine:"internal:attr",selector:`[placeholder=${xt(f.text,!1)}]`,score:Kb-f.scoreBonus})}}const a=Ub(n._evaluator._cacheText,e);for(const u of a){const f=u.normalized;s.push({engine:"internal:label",selector:Lt(f,!0),score:hE});for(const d of nr(f))s.push({engine:"internal:label",selector:Lt(d.text,!1),score:Yb-d.scoreBonus})}const o=ft(e);return o&&!["none","presentation"].includes(o)&&s.push({engine:"internal:role",selector:o,score:Fb}),e.getAttribute("name")&&["BUTTON","FORM","FIELDSET","FRAME","IFRAME","INPUT","KEYGEN","OBJECT","OUTPUT","SELECT","TEXTAREA","MAP","META","PARAM"].includes(e.nodeName)&&s.push({engine:"css",selector:`${Vn(e)}[name=${Ws(e.getAttribute("name"))}]`,score:Wf}),["INPUT","TEXTAREA"].includes(e.nodeName)&&e.getAttribute("type")!=="hidden"&&e.getAttribute("type")&&s.push({engine:"css",selector:`${Vn(e)}[type=${Ws(e.getAttribute("type"))}]`,score:Wf}),["INPUT","TEXTAREA","SELECT"].includes(e.nodeName)&&e.getAttribute("type")!=="hidden"&&s.push({engine:"css",selector:Vn(e),score:Wf+1}),bh([s]),s}function xE(n,e,i){if(e.nodeName==="SELECT")return[];const s=[],a=e.getAttribute("title");if(a){s.push([{engine:"internal:attr",selector:`[title=${xt(a,!0)}]`,score:mE}]);for(const p of nr(a))s.push([{engine:"internal:attr",selector:`[title=${xt(p.text,!1)}]`,score:Pb-p.scoreBonus}])}const o=e.getAttribute("alt");if(o&&["APPLET","AREA","IMG","INPUT"].includes(e.nodeName)){s.push([{engine:"internal:attr",selector:`[alt=${xt(o,!0)}]`,score:pE}]);for(const p of nr(o))s.push([{engine:"internal:attr",selector:`[alt=${xt(p.text,!1)}]`,score:Xb-p.scoreBonus}])}const u=Bt(n._evaluator._cacheText,e).normalized,f=u?nr(u):[];if(u){if(i){u.length<=80&&s.push([{engine:"internal:text",selector:Lt(u,!0),score:gE}]);for(const m of f)s.push([{engine:"internal:text",selector:Lt(m.text,!1),score:Bo-m.scoreBonus}])}const p={engine:"css",selector:Vn(e),score:Qb};for(const m of f)s.push([p,{engine:"internal:has-text",selector:Lt(m.text,!1),score:Bo-m.scoreBonus}]);if(i&&u.length<=80){const m=new RegExp("^"+Yo(u)+"$");s.push([p,{engine:"internal:has-text",selector:Lt(m,!1),score:e0}])}}const d=ft(e);if(d&&!["none","presentation"].includes(d)){const p=Qa(e,!1);if(p){const m={engine:"internal:role",selector:`${d}[name=${xt(p,!0)}]`,score:dE};s.push([m]);for(const y of nr(p))s.push([{engine:"internal:role",selector:`${d}[name=${xt(y.text,!1)}]`,score:Gb-y.scoreBonus}])}else{const m={engine:"internal:role",selector:`${d}`,score:Fb};for(const y of f)s.push([m,{engine:"internal:has-text",selector:Lt(y.text,!1),score:Bo-y.scoreBonus}]);if(i&&u.length<=80){const y=new RegExp("^"+Yo(u)+"$");s.push([m,{engine:"internal:has-text",selector:Lt(y,!1),score:e0}])}}}return bh(s),s}function Zb(n){return/^[a-zA-Z][a-zA-Z0-9\-\_]+$/.test(n)?"#"+n:`[id=${Ws(n)}]`}function eh(n){return n.some(e=>e.engine==="css"&&(e.selector.startsWith("#")||e.selector.startsWith('[id="')))}function Ua(n,e,i){const s=i.root??e.ownerDocument,a=[];function o(f){const d=a.slice();f&&d.unshift(f);const p=d.join(" > "),m=n.parseSelector(p);return n.querySelector(m,s,!1)===e?p:void 0}function u(f){const d={engine:"css",selector:f,score:vE},p=n.parseSelector(f),m=n.querySelectorAll(p,s);if(m.length===1)return[d];const y={engine:"nth",selector:String(m.indexOf(e)),score:yh};return[d,y]}for(let f=e;f&&f!==s;f=yt(f)){let d="";if(f.id&&!i.noCSSId){const y=Zb(f.id),b=o(y);if(b)return u(b);d=y}const p=f.parentNode,m=[...f.classList].map(TE);for(let y=0;y<m.length;++y){const b="."+m.slice(0,y+1).join("."),w=o(b);if(w)return u(w);!d&&p&&p.querySelectorAll(b).length===1&&(d=b)}if(p){const y=[...p.children],b=f.nodeName,E=y.filter(_=>_.nodeName===b).indexOf(f)===0?Vn(f):`${Vn(f)}:nth-child(${1+y.indexOf(f)})`,x=o(E);if(x)return u(x);d||(d=E)}else d||(d=Vn(f));a.unshift(d)}return u(o())}function bh(n){for(const e of n)for(const i of e)i.score>uE&&i.score<yE&&(i.score+=Math.min(Vb,i.selector.length/10|0))}function Uo(n){const e=[];let i="";for(const{engine:s,selector:a}of n)e.length&&(i!=="css"||s!=="css"||a.startsWith(":nth-match("))&&e.push(">>"),i=s,s==="css"?e.push(a):e.push(`${s}=${a}`);return e.join(" ")}function Ki(n){let e=0;for(let i=0;i<n.length;i++)e+=n[i].score*(n.length-i);return e}function _E(n){let e,i=0;for(let s=0;s<n.length;++s){const a=n[s];let o;if(!(a==="-"||a==="_")){if(a>="a"&&a<="z"?o="lower":a>="A"&&a<="Z"?o="upper":a>="0"&&a<="9"?o="digit":o="other",o==="lower"&&e==="upper"){e=o;continue}e&&e!==o&&++i,e=o}}return i>=n.length/4}function wo(n,e){if(n.length<=e)return n;n=n.substring(0,e);const i=n.match(/^(.*)\b(.+?)$/);return i?i[1].trimEnd():""}function nr(n){let e=[];{const i=n.match(/^([\d.,]+)[^.,\w]/),s=i?i[1].length:0;if(s){const a=wo(n.substring(s).trimStart(),80);e.push({text:a,scoreBonus:a.length<=30?2:1})}}{const i=n.match(/[^.,\w]([\d.,]+)$/),s=i?i[1].length:0;if(s){const a=wo(n.substring(0,n.length-s).trimEnd(),80);e.push({text:a,scoreBonus:a.length<=30?2:1})}}return n.length<=30?e.push({text:n,scoreBonus:0}):(e.push({text:wo(n,80),scoreBonus:0}),e.push({text:wo(n,30),scoreBonus:1})),e=e.filter(i=>i.text),e.length||e.push({text:n.substring(0,80),scoreBonus:0}),e}function Vn(n){return n.nodeName.toLocaleLowerCase().replace(/[:\.]/g,e=>"\\"+e)}function TE(n){let e="";for(let i=0;i<n.length;i++)e+=EE(n,i);return e}function EE(n,e){const i=n.charCodeAt(e);return i===0?"�":i>=1&&i<=31||i>=48&&i<=57&&(e===0||e===1&&n.charCodeAt(0)===45)?"\\"+i.toString(16)+" ":e===0&&i===45&&n.length===1?"\\"+n.charAt(e):i>=128||i===45||i===95||i>=48&&i<=57||i>=65&&i<=90||i>=97&&i<=122?n.charAt(e):"\\"+n.charAt(e)}function Jb(n,e){const i=n.replace(/^[a-zA-Z]:/,"").replace(/\\/g,"/");let s=i.substring(i.lastIndexOf("/")+1);return s.endsWith(e)&&(s=s.substring(0,s.length-e.length)),s}function AE(n,e){return e?e.toUpperCase():""}const NE=/(?:^|[-_/])(\w)/g,Wb=n=>n&&n.replace(NE,AE);function CE(n){function e(m){const y=m.name||m._componentTag||m.__playwright_guessedName;if(y)return y;const b=m.__file;if(b)return Wb(Jb(b,".vue"))}function i(m,y){return m.type.__playwright_guessedName=y,y}function s(m){var b,w,E,x;const y=e(m.type||{});if(y)return y;if(m.root===m)return"Root";for(const _ in(w=(b=m.parent)==null?void 0:b.type)==null?void 0:w.components)if(((E=m.parent)==null?void 0:E.type.components[_])===m.type)return i(m,_);for(const _ in(x=m.appContext)==null?void 0:x.components)if(m.appContext.components[_]===m.type)return i(m,_);return"Anonymous Component"}function a(m){return m._isBeingDestroyed||m.isUnmounted}function o(m){return m.subTree.type.toString()==="Symbol(Fragment)"}function u(m){const y=[];return m.component&&y.push(m.component),m.suspense&&y.push(...u(m.suspense.activeBranch)),Array.isArray(m.children)&&m.children.forEach(b=>{b.component?y.push(b.component):y.push(...u(b))}),y.filter(b=>{var w;return!a(b)&&!((w=b.type.devtools)!=null&&w.hide)})}function f(m){return o(m)?d(m.subTree):[m.subTree.el]}function d(m){if(!m.children)return[];const y=[];for(let b=0,w=m.children.length;b<w;b++){const E=m.children[b];E.component?y.push(...f(E.component)):E.el&&y.push(E.el)}return y}function p(m){return{name:s(m),children:u(m.subTree).map(p),rootElements:f(m),props:m.props}}return p(n)}function kE(n){function e(o){const u=o.displayName||o.name||o._componentTag;if(u)return u;const f=o.__file;if(f)return Wb(Jb(f,".vue"))}function i(o){const u=e(o.$options||o.fnOptions||{});return u||(o.$root===o?"Root":"Anonymous Component")}function s(o){return o.$children?o.$children:Array.isArray(o.subTree.children)?o.subTree.children.filter(u=>!!u.component).map(u=>u.component):[]}function a(o){return{name:i(o),children:s(o).map(a),rootElements:[o.$el],props:o._props}}return a(n)}function ev(n,e,i=[]){e(n)&&i.push(n);for(const s of n.children)ev(s,e,i);return i}function tv(n,e=[]){const s=(n.ownerDocument||n).createTreeWalker(n,NodeFilter.SHOW_ELEMENT),a=new Set;do{const o=s.currentNode;o.__vue__&&a.add(o.__vue__.$root),o.__vue_app__&&o._vnode&&o._vnode.component&&e.push({root:o._vnode.component,version:3});const u=o instanceof Element?o.shadowRoot:null;u&&tv(u,e)}while(s.nextNode());for(const o of a)e.push({version:2,root:o});return e}const ME=()=>({queryAll(n,e){const i=n.ownerDocument||n,{name:s,attributes:a}=Ji(e,!1),f=tv(i).map(p=>p.version===3?CE(p.root):kE(p.root)).map(p=>ev(p,m=>{if(s&&m.name!==s||m.rootElements.some(y=>!Fa(n,y)))return!1;for(const y of a)if(!Db(m.props,y))return!1;return!0})).flat(),d=new Set;for(const p of f)for(const m of p.rootElements)d.add(m);return[...d]}}),n0={queryAll(n,e){e.startsWith("/")&&n.nodeType!==Node.DOCUMENT_NODE&&(e="."+e);const i=[],s=n.ownerDocument||n;if(!s)return i;const a=s.evaluate(e,n,null,XPathResult.ORDERED_NODE_ITERATOR_TYPE);for(let o=a.iterateNext();o;o=a.iterateNext())o.nodeType===Node.ELEMENT_NODE&&i.push(o);return i}};function ad(n,e,i){return`internal:attr=[${n}=${xt(e,(i==null?void 0:i.exact)||!1)}]`}function OE(n,e){return`internal:testid=[${n}=${xt(e,!0)}]`}function RE(n,e){return"internal:label="+Lt(n,!!(e!=null&&e.exact))}function jE(n,e){return ad("alt",n,e)}function LE(n,e){return ad("title",n,e)}function DE(n,e){return ad("placeholder",n,e)}function BE(n,e){return"internal:text="+Lt(n,!!(e!=null&&e.exact))}function UE(n,e={}){const i=[];return e.checked!==void 0&&i.push(["checked",String(e.checked)]),e.disabled!==void 0&&i.push(["disabled",String(e.disabled)]),e.selected!==void 0&&i.push(["selected",String(e.selected)]),e.expanded!==void 0&&i.push(["expanded",String(e.expanded)]),e.includeHidden!==void 0&&i.push(["include-hidden",String(e.includeHidden)]),e.level!==void 0&&i.push(["level",String(e.level)]),e.name!==void 0&&i.push(["name",xt(e.name,!!e.exact)]),e.pressed!==void 0&&i.push(["pressed",String(e.pressed)]),`internal:role=${n}${i.map(([s,a])=>`[${s}=${a}]`).join("")}`}const Ma=Symbol("selector"),zE=class za{constructor(e,i,s){if(s!=null&&s.hasText&&(i+=` >> internal:has-text=${Lt(s.hasText,!1)}`),s!=null&&s.hasNotText&&(i+=` >> internal:has-not-text=${Lt(s.hasNotText,!1)}`),s!=null&&s.has&&(i+=" >> internal:has="+JSON.stringify(s.has[Ma])),s!=null&&s.hasNot&&(i+=" >> internal:has-not="+JSON.stringify(s.hasNot[Ma])),(s==null?void 0:s.visible)!==void 0&&(i+=` >> visible=${s.visible?"true":"false"}`),this[Ma]=i,i){const u=e.parseSelector(i);this.element=e.querySelector(u,e.document,!1),this.elements=e.querySelectorAll(u,e.document)}const a=i,o=this;o.locator=(u,f)=>new za(e,a?a+" >> "+u:u,f),o.getByTestId=u=>o.locator(OE(e.testIdAttributeNameForStrictErrorAndConsoleCodegen(),u)),o.getByAltText=(u,f)=>o.locator(jE(u,f)),o.getByLabel=(u,f)=>o.locator(RE(u,f)),o.getByPlaceholder=(u,f)=>o.locator(DE(u,f)),o.getByText=(u,f)=>o.locator(BE(u,f)),o.getByTitle=(u,f)=>o.locator(LE(u,f)),o.getByRole=(u,f={})=>o.locator(UE(u,f)),o.filter=u=>new za(e,i,u),o.first=()=>o.locator("nth=0"),o.last=()=>o.locator("nth=-1"),o.nth=u=>o.locator(`nth=${u}`),o.and=u=>new za(e,a+" >> internal:and="+JSON.stringify(u[Ma])),o.or=u=>new za(e,a+" >> internal:or="+JSON.stringify(u[Ma]))}};let HE=zE;class qE{constructor(e){this._injectedScript=e}install(){this._injectedScript.window.playwright||(this._injectedScript.window.playwright={$:(e,i)=>this._querySelector(e,!!i),$$:e=>this._querySelectorAll(e),inspect:e=>this._inspect(e),selector:e=>this._selector(e),generateLocator:(e,i)=>this._generateLocator(e,i),ariaSnapshot:(e,i)=>this._injectedScript.ariaSnapshot(e||this._injectedScript.document.body,i||{mode:"expect"}),resume:()=>this._resume(),...new HE(this._injectedScript,"")},delete this._injectedScript.window.playwright.filter,delete this._injectedScript.window.playwright.first,delete this._injectedScript.window.playwright.last,delete this._injectedScript.window.playwright.nth,delete this._injectedScript.window.playwright.and,delete this._injectedScript.window.playwright.or)}_querySelector(e,i){if(typeof e!="string")throw new Error("Usage: playwright.query('Playwright >> selector').");const s=this._injectedScript.parseSelector(e);return this._injectedScript.querySelector(s,this._injectedScript.document,i)}_querySelectorAll(e){if(typeof e!="string")throw new Error("Usage: playwright.$$('Playwright >> selector').");const i=this._injectedScript.parseSelector(e);return this._injectedScript.querySelectorAll(i,this._injectedScript.document)}_inspect(e){if(typeof e!="string")throw new Error("Usage: playwright.inspect('Playwright >> selector').");this._injectedScript.window.inspect(this._querySelector(e,!1))}_selector(e){if(!(e instanceof Element))throw new Error("Usage: playwright.selector(element).");return this._injectedScript.generateSelectorSimple(e)}_generateLocator(e,i){if(!(e instanceof Element))throw new Error("Usage: playwright.locator(element).");const s=this._injectedScript.generateSelectorSimple(e);return Wi(i||"javascript",s)}_resume(){if(!this._injectedScript.window.__pw_resume)return!1;this._injectedScript.window.__pw_resume().catch(()=>{})}}function $E(n){try{return n instanceof RegExp||Object.prototype.toString.call(n)==="[object RegExp]"}catch{return!1}}function IE(n){try{return n instanceof Date||Object.prototype.toString.call(n)==="[object Date]"}catch{return!1}}function VE(n){try{return n instanceof URL||Object.prototype.toString.call(n)==="[object URL]"}catch{return!1}}function GE(n){var e;try{return n instanceof Error||n&&((e=Object.getPrototypeOf(n))==null?void 0:e.name)==="Error"}catch{return!1}}function KE(n,e){try{return n instanceof e||Object.prototype.toString.call(n)===`[object ${e.name}]`}catch{return!1}}const nv={i8:Int8Array,ui8:Uint8Array,ui8c:Uint8ClampedArray,i16:Int16Array,ui16:Uint16Array,i32:Int32Array,ui32:Uint32Array,f32:Float32Array,f64:Float64Array,bi64:BigInt64Array,bui64:BigUint64Array};function YE(n){if("toBase64"in n)return n.toBase64();const e=Array.from(new Uint8Array(n.buffer,n.byteOffset,n.byteLength)).map(i=>String.fromCharCode(i)).join("");return btoa(e)}function XE(n,e){const i=atob(n),s=new Uint8Array(i.length);for(let a=0;a<i.length;a++)s[a]=i.charCodeAt(a);return new e(s.buffer)}function vh(n,e=[],i=new Map){if(!Object.is(n,void 0)){if(typeof n=="object"&&n){if("ref"in n)return i.get(n.ref);if("v"in n)return n.v==="undefined"?void 0:n.v==="null"?null:n.v==="NaN"?NaN:n.v==="Infinity"?1/0:n.v==="-Infinity"?-1/0:n.v==="-0"?-0:void 0;if("d"in n)return new Date(n.d);if("u"in n)return new URL(n.u);if("bi"in n)return BigInt(n.bi);if("e"in n){const s=new Error(n.e.m);return s.name=n.e.n,s.stack=n.e.s,s}if("r"in n)return new RegExp(n.r.p,n.r.f);if("a"in n){const s=[];i.set(n.id,s);for(const a of n.a)s.push(vh(a,e,i));return s}if("o"in n){const s={};i.set(n.id,s);for(const{k:a,v:o}of n.o)a!=="__proto__"&&(s[a]=vh(o,e,i));return s}if("h"in n)return e[n.h];if("ta"in n)return XE(n.ta.b,nv[n.ta.k])}return n}}function PE(n,e){return Sh(n,e,{visited:new Map,lastId:0})}function Sh(n,e,i){if(n&&typeof n=="object"){if(typeof globalThis.Window=="function"&&n instanceof globalThis.Window)return"ref: <Window>";if(typeof globalThis.Document=="function"&&n instanceof globalThis.Document)return"ref: <Document>";if(typeof globalThis.Node=="function"&&n instanceof globalThis.Node)return"ref: <Node>"}return iv(n,e,i)}function iv(n,e,i){var o;const s=e(n);if("fallThrough"in s)n=s.fallThrough;else return s;if(typeof n=="symbol")return{v:"undefined"};if(Object.is(n,void 0))return{v:"undefined"};if(Object.is(n,null))return{v:"null"};if(Object.is(n,NaN))return{v:"NaN"};if(Object.is(n,1/0))return{v:"Infinity"};if(Object.is(n,-1/0))return{v:"-Infinity"};if(Object.is(n,-0))return{v:"-0"};if(typeof n=="boolean"||typeof n=="number"||typeof n=="string")return n;if(typeof n=="bigint")return{bi:n.toString()};if(GE(n)){let u;return(o=n.stack)!=null&&o.startsWith(n.name+": "+n.message)?u=n.stack:u=`${n.name}: ${n.message}
|
|
116
|
-
${n.stack}`,{e:{n:n.name,m:n.message,s:u}}}if(IE(n))return{d:n.toJSON()};if(VE(n))return{u:n.toJSON()};if($E(n))return{r:{p:n.source,f:n.flags}};for(const[u,f]of Object.entries(nv))if(KE(n,f))return{ta:{b:YE(n),k:u}};const a=i.visited.get(n);if(a)return{ref:a};if(Array.isArray(n)){const u=[],f=++i.lastId;i.visited.set(n,f);for(let d=0;d<n.length;++d)u.push(Sh(n[d],e,i));return{a:u,id:f}}if(typeof n=="object"){const u=[],f=++i.lastId;i.visited.set(n,f);for(const p of Object.keys(n)){let m;try{m=n[p]}catch{continue}p==="toJSON"&&typeof m=="function"?u.push({k:p,v:{o:[],id:0}}):u.push({k:p,v:Sh(m,e,i)})}let d;try{u.length===0&&n.toJSON&&typeof n.toJSON=="function"&&(d={value:n.toJSON()})}catch{}return d?iv(d.value,e,i):{o:u,id:f}}}class FE{constructor(e,i){var s,a,o,u,f,d,p,m;this.global=e,this.isUnderTest=i,e.__pwClock?this.builtins=e.__pwClock.builtins:this.builtins={setTimeout:(s=e.setTimeout)==null?void 0:s.bind(e),clearTimeout:(a=e.clearTimeout)==null?void 0:a.bind(e),setInterval:(o=e.setInterval)==null?void 0:o.bind(e),clearInterval:(u=e.clearInterval)==null?void 0:u.bind(e),requestAnimationFrame:(f=e.requestAnimationFrame)==null?void 0:f.bind(e),cancelAnimationFrame:(d=e.cancelAnimationFrame)==null?void 0:d.bind(e),requestIdleCallback:(p=e.requestIdleCallback)==null?void 0:p.bind(e),cancelIdleCallback:(m=e.cancelIdleCallback)==null?void 0:m.bind(e),performance:e.performance,Intl:e.Intl,Date:e.Date},this.isUnderTest&&(e.builtins=this.builtins)}evaluate(e,i,s,a,...o){const u=o.slice(0,a),f=o.slice(a),d=[];for(let m=0;m<u.length;m++)d[m]=vh(u[m],f);let p=this.global.eval(s);return e===!0?p=p(...d):e===!1?p=p:typeof p=="function"&&(p=p(...d)),i?this._promiseAwareJsonValueNoThrow(p):p}jsonValue(e,i){if(i!==void 0)return PE(i,s=>({fallThrough:s}))}_promiseAwareJsonValueNoThrow(e){const i=s=>{try{return this.jsonValue(!0,s)}catch{return}};return e&&typeof e=="object"&&typeof e.then=="function"?(async()=>{const s=await e;return i(s)})():i(e)}}class sv{constructor(e,i){this._testIdAttributeNameForStrictErrorAndConsoleCodegen="data-testid",this._lastAriaSnapshotForTrack=new Map,this.utils={asLocator:Wi,cacheNormalizedWhitespaces:Sx,elementText:Bt,getAriaRole:ft,getElementAccessibleDescription:Gy,getElementAccessibleName:Qa,isElementVisible:vi,isInsideScope:Fa,normalizeWhiteSpace:Tt,parseAriaSnapshot:zh,generateAriaTree:Va,builtins:null},this.window=e,this.document=e.document,this.isUnderTest=i.isUnderTest,this.utils.builtins=new FE(e,i.isUnderTest).builtins,this._sdkLanguage=i.sdkLanguage,this._testIdAttributeNameForStrictErrorAndConsoleCodegen=i.testIdAttributeName,this._evaluator=new ZT,this.consoleApi=new qE(this),this.onGlobalListenersRemoved=new Set,this._autoClosingTags=new Set(["AREA","BASE","BR","COL","COMMAND","EMBED","HR","IMG","INPUT","KEYGEN","LINK","MENUITEM","META","PARAM","SOURCE","TRACK","WBR"]),this._booleanAttributes=new Set(["checked","selected","disabled","readonly","multiple"]),this._eventTypes=new Map([["auxclick","mouse"],["click","mouse"],["dblclick","mouse"],["mousedown","mouse"],["mouseeenter","mouse"],["mouseleave","mouse"],["mousemove","mouse"],["mouseout","mouse"],["mouseover","mouse"],["mouseup","mouse"],["mouseleave","mouse"],["mousewheel","mouse"],["keydown","keyboard"],["keyup","keyboard"],["keypress","keyboard"],["textInput","keyboard"],["touchstart","touch"],["touchmove","touch"],["touchend","touch"],["touchcancel","touch"],["pointerover","pointer"],["pointerout","pointer"],["pointerenter","pointer"],["pointerleave","pointer"],["pointerdown","pointer"],["pointerup","pointer"],["pointermove","pointer"],["pointercancel","pointer"],["gotpointercapture","pointer"],["lostpointercapture","pointer"],["focus","focus"],["blur","focus"],["drag","drag"],["dragstart","drag"],["dragend","drag"],["dragover","drag"],["dragenter","drag"],["dragleave","drag"],["dragexit","drag"],["drop","drag"],["wheel","wheel"],["deviceorientation","deviceorientation"],["deviceorientationabsolute","deviceorientation"],["devicemotion","devicemotion"]]),this._hoverHitTargetInterceptorEvents=new Set(["mousemove"]),this._tapHitTargetInterceptorEvents=new Set(["pointerdown","pointerup","touchstart","touchend","touchcancel"]),this._mouseHitTargetInterceptorEvents=new Set(["mousedown","mouseup","pointerdown","pointerup","click","auxclick","dblclick","contextmenu"]),this._allHitTargetInterceptorEvents=new Set([...this._hoverHitTargetInterceptorEvents,...this._tapHitTargetInterceptorEvents,...this._mouseHitTargetInterceptorEvents]),this._engines=new Map,this._engines.set("xpath",n0),this._engines.set("xpath:light",n0),this._engines.set("_react",PT()),this._engines.set("_vue",ME()),this._engines.set("role",Jy(!1)),this._engines.set("text",this._createTextEngine(!0,!1)),this._engines.set("text:light",this._createTextEngine(!1,!1)),this._engines.set("id",this._createAttributeEngine("id",!0)),this._engines.set("id:light",this._createAttributeEngine("id",!1)),this._engines.set("data-testid",this._createAttributeEngine("data-testid",!0)),this._engines.set("data-testid:light",this._createAttributeEngine("data-testid",!1)),this._engines.set("data-test-id",this._createAttributeEngine("data-test-id",!0)),this._engines.set("data-test-id:light",this._createAttributeEngine("data-test-id",!1)),this._engines.set("data-test",this._createAttributeEngine("data-test",!0)),this._engines.set("data-test:light",this._createAttributeEngine("data-test",!1)),this._engines.set("css",this._createCSSEngine()),this._engines.set("nth",{queryAll:()=>[]}),this._engines.set("visible",this._createVisibleEngine()),this._engines.set("internal:control",this._createControlEngine()),this._engines.set("internal:has",this._createHasEngine()),this._engines.set("internal:has-not",this._createHasNotEngine()),this._engines.set("internal:and",{queryAll:()=>[]}),this._engines.set("internal:or",{queryAll:()=>[]}),this._engines.set("internal:chain",this._createInternalChainEngine()),this._engines.set("internal:label",this._createInternalLabelEngine()),this._engines.set("internal:text",this._createTextEngine(!0,!0)),this._engines.set("internal:has-text",this._createInternalHasTextEngine()),this._engines.set("internal:has-not-text",this._createInternalHasNotTextEngine()),this._engines.set("internal:attr",this._createNamedAttributeEngine()),this._engines.set("internal:testid",this._createNamedAttributeEngine()),this._engines.set("internal:role",Jy(!0)),this._engines.set("internal:describe",this._createDescribeEngine()),this._engines.set("aria-ref",this._createAriaRefEngine());for(const{name:s,source:a}of i.customEngines)this._engines.set(s,this.eval(a));this._stableRafCount=i.stableRafCount,this._browserName=i.browserName,this._isUtilityWorld=!!i.isUtilityWorld,aT({browserNameForWorkarounds:i.browserName}),this._setupGlobalListenersRemovalDetection(),this._setupHitTargetInterceptors(),this.isUnderTest&&(this.window.__injectedScript=this)}eval(e){return this.window.eval(e)}testIdAttributeNameForStrictErrorAndConsoleCodegen(){return this._testIdAttributeNameForStrictErrorAndConsoleCodegen}parseSelector(e){const i=tl(e);return bx(i,s=>{if(!this._engines.has(s.name))throw this.createStacklessError(`Unknown engine "${s.name}" while parsing selector ${e}`)}),i}generateSelector(e,i){return t0(this,e,i)}generateSelectorSimple(e,i){return t0(this,e,{...i,testIdAttributeName:this._testIdAttributeNameForStrictErrorAndConsoleCodegen}).selector}querySelector(e,i,s){const a=this.querySelectorAll(e,i);if(s&&a.length>1)throw this.strictModeViolationError(e,a);return a[0]}_queryNth(e,i){const s=[...e];let a=+i.body;return a===-1&&(a=s.length-1),new Set(s.slice(a,a+1))}_queryLayoutSelector(e,i,s){const a=i.name,o=i.body,u=[],f=this.querySelectorAll(o.parsed,s);for(const d of e){const p=Lb(a,d,f,o.distance);p!==void 0&&u.push({element:d,score:p})}return u.sort((d,p)=>d.score-p.score),new Set(u.map(d=>d.element))}ariaSnapshot(e,i){if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Can only capture aria snapshot of Element nodes.");const s=Va(e,i);let a;i.incremental&&(a=i.track?this._lastAriaSnapshotForTrack.get(i.track):this._lastAriaSnapshotForQuery);const o=Jo(s,i,a);return i.track&&this._lastAriaSnapshotForTrack.set(i.track,s),this._lastAriaSnapshotForQuery=s,o}ariaSnapshotForRecorder(){const e=Va(this.document.body,{mode:"ai"});return{ariaSnapshot:Jo(e,{mode:"ai"}),refs:e.refs}}getAllElementsMatchingExpectAriaTemplate(e,i){return LT(e.documentElement,i)}querySelectorAll(e,i){if(e.capture!==void 0){if(e.parts.some(a=>a.name==="nth"))throw this.createStacklessError("Can't query n-th element in a request with the capture.");const s={parts:e.parts.slice(0,e.capture+1)};if(e.capture<e.parts.length-1){const a={parts:e.parts.slice(e.capture+1)},o={name:"internal:has",body:{parsed:a},source:Gn(a)};s.parts.push(o)}return this.querySelectorAll(s,i)}if(!i.querySelectorAll)throw this.createStacklessError("Node is not queryable.");if(e.capture!==void 0)throw this.createStacklessError("Internal error: there should not be a capture in the selector.");if(i.nodeType===11&&e.parts.length===1&&e.parts[0].name==="css"&&e.parts[0].source===":scope")return[i];this._evaluator.begin();try{let s=new Set([i]);for(const a of e.parts)if(a.name==="nth")s=this._queryNth(s,a);else if(a.name==="internal:and"){const o=this.querySelectorAll(a.body.parsed,i);s=new Set(o.filter(u=>s.has(u)))}else if(a.name==="internal:or"){const o=this.querySelectorAll(a.body.parsed,i);s=new Set(Ib(new Set([...s,...o])))}else if(VT.includes(a.name))s=this._queryLayoutSelector(s,a,i);else{const o=new Set;for(const u of s){const f=this._queryEngineAll(a,u);for(const d of f)o.add(d)}s=o}return[...s]}finally{this._evaluator.end()}}_queryEngineAll(e,i){const s=this._engines.get(e.name).queryAll(i,e.body);for(const a of s)if(!("nodeName"in a))throw this.createStacklessError(`Expected a Node but got ${Object.prototype.toString.call(a)}`);return s}_createAttributeEngine(e,i){const s=a=>[{simples:[{selector:{css:`[${e}=${JSON.stringify(a)}]`,functions:[]},combinator:""}]}];return{queryAll:(a,o)=>this._evaluator.query({scope:a,pierceShadow:i},s(o))}}_createCSSEngine(){return{queryAll:(e,i)=>this._evaluator.query({scope:e,pierceShadow:!0},i)}}_createTextEngine(e,i){return{queryAll:(a,o)=>{const{matcher:u,kind:f}=_o(o,i),d=[];let p=null;const m=b=>{if(f==="lax"&&p&&p.contains(b))return!1;const w=cc(this._evaluator._cacheText,b,u);w==="none"&&(p=b),(w==="self"||w==="selfAndChildren"&&f==="strict"&&!i)&&d.push(b)};a.nodeType===Node.ELEMENT_NODE&&m(a);const y=this._evaluator._queryCSS({scope:a,pierceShadow:e},"*");for(const b of y)m(b);return d}}}_createInternalHasTextEngine(){return{queryAll:(e,i)=>{if(e.nodeType!==1)return[];const s=e,a=Bt(this._evaluator._cacheText,s),{matcher:o}=_o(i,!0);return o(a)?[s]:[]}}}_createInternalHasNotTextEngine(){return{queryAll:(e,i)=>{if(e.nodeType!==1)return[];const s=e,a=Bt(this._evaluator._cacheText,s),{matcher:o}=_o(i,!0);return o(a)?[]:[s]}}}_createInternalLabelEngine(){return{queryAll:(e,i)=>{const{matcher:s}=_o(i,!0);return this._evaluator._queryCSS({scope:e,pierceShadow:!0},"*").filter(o=>Ub(this._evaluator._cacheText,o).some(u=>s(u)))}}}_createNamedAttributeEngine(){return{queryAll:(i,s)=>{const a=Ji(s,!0);if(a.name||a.attributes.length!==1)throw new Error("Malformed attribute selector: "+s);const{name:o,value:u,caseSensitive:f}=a.attributes[0],d=f?null:u.toLowerCase();let p;return u instanceof RegExp?p=y=>!!y.match(u):f?p=y=>y===u:p=y=>y.toLowerCase().includes(d),this._evaluator._queryCSS({scope:i,pierceShadow:!0},`[${o}]`).filter(y=>p(y.getAttribute(o)))}}}_createDescribeEngine(){return{queryAll:i=>i.nodeType!==1?[]:[i]}}_createControlEngine(){return{queryAll(e,i){if(i==="enter-frame")return[];if(i==="return-empty")return[];if(i==="component")return e.nodeType!==1?[]:[e.childElementCount===1?e.firstElementChild:e];throw new Error(`Internal error, unknown internal:control selector ${i}`)}}}_createHasEngine(){return{queryAll:(i,s)=>i.nodeType!==1?[]:!!this.querySelector(s.parsed,i,!1)?[i]:[]}}_createHasNotEngine(){return{queryAll:(i,s)=>i.nodeType!==1?[]:!!this.querySelector(s.parsed,i,!1)?[]:[i]}}_createVisibleEngine(){return{queryAll:(i,s)=>{if(i.nodeType!==1)return[];const a=s==="true";return vi(i)===a?[i]:[]}}}_createInternalChainEngine(){return{queryAll:(i,s)=>this.querySelectorAll(s.parsed,i)}}extend(e,i){const s=this.window.eval(`
|
|
112
|
+
`;return s.push({message:o,range:[i.lineCounter.linePos(e.range[0]),i.lineCounter.linePos(e.range[0]+a.pos)]}),null}throw a}}constructor(e){this._input=e,this._pos=0,this._length=e.length}_peek(){return this._input[this._pos]||""}_next(){return this._pos<this._length?this._input[this._pos++]:null}_eof(){return this._pos>=this._length}_isWhitespace(){return!this._eof()&&/\s/.test(this._peek())}_skipWhitespace(){for(;this._isWhitespace();)this._pos++}_readIdentifier(e){this._eof()&&this._throwError(`Unexpected end of input when expecting ${e}`);const i=this._pos;for(;!this._eof()&&/[a-zA-Z]/.test(this._peek());)this._pos++;return this._input.slice(i,this._pos)}_readString(){let e="",i=!1;for(;!this._eof();){const s=this._next();if(i)e+=s,i=!1;else if(s==="\\")i=!0;else{if(s==='"')return e;e+=s}}this._throwError("Unterminated string")}_throwError(e,i=0){throw new Hy(e,i||this._pos)}_readRegex(){let e="",i=!1,s=!1;for(;!this._eof();){const a=this._next();if(i)e+=a,i=!1;else if(a==="\\")i=!0,e+=a;else{if(a==="/"&&!s)return{pattern:e};a==="["?(s=!0,e+=a):a==="]"&&s?(e+=a,s=!1):e+=a}}this._throwError("Unterminated regex")}_readStringOrRegex(){const e=this._peek();return e==='"'?(this._next(),lb(this._readString())):e==="/"?(this._next(),this._readRegex()):null}_readAttributes(e){let i=this._pos;for(;this._skipWhitespace(),this._peek()==="[";){this._next(),this._skipWhitespace(),i=this._pos;const s=this._readIdentifier("attribute");this._skipWhitespace();let a="";if(this._peek()==="=")for(this._next(),this._skipWhitespace(),i=this._pos;this._peek()!=="]"&&!this._isWhitespace()&&!this._eof();)a+=this._next();this._skipWhitespace(),this._peek()!=="]"&&this._throwError("Expected ]"),this._next(),this._applyAttribute(e,s,a||"true",i)}}_parse(){this._skipWhitespace();const e=this._readIdentifier("role");this._skipWhitespace();const i=this._readStringOrRegex()||"",s={kind:"role",role:e,name:i};return this._readAttributes(s),this._skipWhitespace(),this._eof()||this._throwError("Unexpected input"),s}_applyAttribute(e,i,s,a){if(i==="checked"){this._assert(s==="true"||s==="false"||s==="mixed",'Value of "checked" attribute must be a boolean or "mixed"',a),e.checked=s==="true"?!0:s==="false"?!1:"mixed";return}if(i==="disabled"){this._assert(s==="true"||s==="false",'Value of "disabled" attribute must be a boolean',a),e.disabled=s==="true";return}if(i==="expanded"){this._assert(s==="true"||s==="false",'Value of "expanded" attribute must be a boolean',a),e.expanded=s==="true";return}if(i==="active"){this._assert(s==="true"||s==="false",'Value of "active" attribute must be a boolean',a),e.active=s==="true";return}if(i==="level"){this._assert(!isNaN(Number(s)),'Value of "level" attribute must be a number',a),e.level=Number(s);return}if(i==="pressed"){this._assert(s==="true"||s==="false"||s==="mixed",'Value of "pressed" attribute must be a boolean or "mixed"',a),e.pressed=s==="true"?!0:s==="false"?!1:"mixed";return}if(i==="selected"){this._assert(s==="true"||s==="false",'Value of "selected" attribute must be a boolean',a),e.selected=s==="true";return}this._assert(!1,`Unsupported attribute [${i}]`,a)}_assert(e,i,s){e||this._throwError(i||"Assertion error",s)}}class Hy extends Error{constructor(e,i){super(e),this.pos=i}}let ob={};function lT(n){ob=n}function Fa(n,e){for(;e;){if(n.contains(e))return!0;e=ub(e)}return!1}function yt(n){if(n.parentElement)return n.parentElement;if(n.parentNode&&n.parentNode.nodeType===11&&n.parentNode.host)return n.parentNode.host}function cb(n){let e=n;for(;e.parentNode;)e=e.parentNode;if(e.nodeType===11||e.nodeType===9)return e}function ub(n){for(;n.parentElement;)n=n.parentElement;return yt(n)}function Da(n,e,i){for(;n;){const s=n.closest(e);if(i&&s!==i&&(s!=null&&s.contains(i)))return;if(s)return s;n=ub(n)}}function _i(n,e){const i=e==="::before"?qh:e==="::after"?$h:Hh;if(i&&i.has(n))return i.get(n);const s=n.ownerDocument&&n.ownerDocument.defaultView?n.ownerDocument.defaultView.getComputedStyle(n,e):void 0;return i==null||i.set(n,s),s}function fb(n,e){if(e=e??_i(n),!e)return!0;if(Element.prototype.checkVisibility&&ob.browserNameForWorkarounds!=="webkit"){if(!n.checkVisibility())return!1}else{const i=n.closest("details,summary");if(i!==n&&(i==null?void 0:i.nodeName)==="DETAILS"&&!i.open)return!1}return e.visibility==="visible"}function Fo(n){const e=_i(n);if(!e)return{visible:!0,inline:!1};const i=e.cursor;if(e.display==="contents"){for(let a=n.firstChild;a;a=a.nextSibling){if(a.nodeType===1&&vi(a))return{visible:!0,inline:!1,cursor:i};if(a.nodeType===3&&hb(a))return{visible:!0,inline:!0,cursor:i}}return{visible:!1,inline:!1,cursor:i}}if(!fb(n,e))return{cursor:i,visible:!1,inline:!1};const s=n.getBoundingClientRect();return{rect:s,cursor:i,visible:s.width>0&&s.height>0,inline:e.display==="inline"}}function vi(n){return Fo(n).visible}function hb(n){const e=n.ownerDocument.createRange();e.selectNode(n);const i=e.getBoundingClientRect();return i.width>0&&i.height>0}function st(n){const e=n.tagName;return typeof e=="string"?e.toUpperCase():n instanceof HTMLFormElement?"FORM":n.tagName.toUpperCase()}let Hh,qh,$h,db=0;function Ih(){++db,Hh??(Hh=new Map),qh??(qh=new Map),$h??($h=new Map)}function Vh(){--db||(Hh=void 0,qh=void 0,$h=void 0)}function qy(n){return n.hasAttribute("aria-label")||n.hasAttribute("aria-labelledby")}const $y="article:not([role]), aside:not([role]), main:not([role]), nav:not([role]), section:not([role]), [role=article], [role=complementary], [role=main], [role=navigation], [role=region]",oT=[["aria-atomic",void 0],["aria-busy",void 0],["aria-controls",void 0],["aria-current",void 0],["aria-describedby",void 0],["aria-details",void 0],["aria-dropeffect",void 0],["aria-flowto",void 0],["aria-grabbed",void 0],["aria-hidden",void 0],["aria-keyshortcuts",void 0],["aria-label",["caption","code","deletion","emphasis","generic","insertion","paragraph","presentation","strong","subscript","superscript"]],["aria-labelledby",["caption","code","deletion","emphasis","generic","insertion","paragraph","presentation","strong","subscript","superscript"]],["aria-live",void 0],["aria-owns",void 0],["aria-relevant",void 0],["aria-roledescription",["generic"]]];function pb(n,e){return oT.some(([i,s])=>!(s!=null&&s.includes(e||""))&&n.hasAttribute(i))}function gb(n){return!Number.isNaN(Number(String(n.getAttribute("tabindex"))))}function cT(n){return!Nb(n)&&(uT(n)||gb(n))}function uT(n){const e=st(n);return["BUTTON","DETAILS","SELECT","TEXTAREA"].includes(e)?!0:e==="A"||e==="AREA"?n.hasAttribute("href"):e==="INPUT"?!n.hidden:!1}const Pf={A:n=>n.hasAttribute("href")?"link":null,AREA:n=>n.hasAttribute("href")?"link":null,ARTICLE:()=>"article",ASIDE:()=>"complementary",BLOCKQUOTE:()=>"blockquote",BUTTON:()=>"button",CAPTION:()=>"caption",CODE:()=>"code",DATALIST:()=>"listbox",DD:()=>"definition",DEL:()=>"deletion",DETAILS:()=>"group",DFN:()=>"term",DIALOG:()=>"dialog",DT:()=>"term",EM:()=>"emphasis",FIELDSET:()=>"group",FIGURE:()=>"figure",FOOTER:n=>Da(n,$y)?null:"contentinfo",FORM:n=>qy(n)?"form":null,H1:()=>"heading",H2:()=>"heading",H3:()=>"heading",H4:()=>"heading",H5:()=>"heading",H6:()=>"heading",HEADER:n=>Da(n,$y)?null:"banner",HR:()=>"separator",HTML:()=>"document",IMG:n=>n.getAttribute("alt")===""&&!n.getAttribute("title")&&!pb(n)&&!gb(n)?"presentation":"img",INPUT:n=>{const e=n.type.toLowerCase();if(e==="search")return n.hasAttribute("list")?"combobox":"searchbox";if(["email","tel","text","url",""].includes(e)){const i=gr(n,n.getAttribute("list"))[0];return i&&st(i)==="DATALIST"?"combobox":"textbox"}return e==="hidden"?null:e==="file"?"button":AT[e]||"textbox"},INS:()=>"insertion",LI:()=>"listitem",MAIN:()=>"main",MARK:()=>"mark",MATH:()=>"math",MENU:()=>"list",METER:()=>"meter",NAV:()=>"navigation",OL:()=>"list",OPTGROUP:()=>"group",OPTION:()=>"option",OUTPUT:()=>"status",P:()=>"paragraph",PROGRESS:()=>"progressbar",SEARCH:()=>"search",SECTION:n=>qy(n)?"region":null,SELECT:n=>n.hasAttribute("multiple")||n.size>1?"listbox":"combobox",STRONG:()=>"strong",SUB:()=>"subscript",SUP:()=>"superscript",SVG:()=>"img",TABLE:()=>"table",TBODY:()=>"rowgroup",TD:n=>{const e=Da(n,"table"),i=e?Qo(e):"";return i==="grid"||i==="treegrid"?"gridcell":"cell"},TEXTAREA:()=>"textbox",TFOOT:()=>"rowgroup",TH:n=>{if(n.getAttribute("scope")==="col")return"columnheader";if(n.getAttribute("scope")==="row")return"rowheader";const e=Da(n,"table"),i=e?Qo(e):"";return i==="grid"||i==="treegrid"?"gridcell":"cell"},THEAD:()=>"rowgroup",TIME:()=>"time",TR:()=>"row",UL:()=>"list"},fT={DD:["DL","DIV"],DIV:["DL"],DT:["DL","DIV"],LI:["OL","UL"],TBODY:["TABLE"],TD:["TR"],TFOOT:["TABLE"],TH:["TR"],THEAD:["TABLE"],TR:["THEAD","TBODY","TFOOT","TABLE"]};function Iy(n){var s;const e=((s=Pf[st(n)])==null?void 0:s.call(Pf,n))||"";if(!e)return null;let i=n;for(;i;){const a=yt(i),o=fT[st(i)];if(!o||!a||!o.includes(st(a)))break;const u=Qo(a);if((u==="none"||u==="presentation")&&!mb(a,u))return u;i=a}return e}const hT=["alert","alertdialog","application","article","banner","blockquote","button","caption","cell","checkbox","code","columnheader","combobox","complementary","contentinfo","definition","deletion","dialog","directory","document","emphasis","feed","figure","form","generic","grid","gridcell","group","heading","img","insertion","link","list","listbox","listitem","log","main","mark","marquee","math","meter","menu","menubar","menuitem","menuitemcheckbox","menuitemradio","navigation","none","note","option","paragraph","presentation","progressbar","radio","radiogroup","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","strong","subscript","superscript","switch","tab","table","tablist","tabpanel","term","textbox","time","timer","toolbar","tooltip","tree","treegrid","treeitem"];function Qo(n){return(n.getAttribute("role")||"").split(" ").map(i=>i.trim()).find(i=>hT.includes(i))||null}function mb(n,e){return pb(n,e)||cT(n)}function ft(n){const e=Qo(n);if(!e)return Iy(n);if(e==="none"||e==="presentation"){const i=Iy(n);if(mb(n,i))return i}return e}function yb(n){return n===null?void 0:n.toLowerCase()==="true"}function bb(n){return["STYLE","SCRIPT","NOSCRIPT","TEMPLATE"].includes(st(n))}function rn(n){if(bb(n))return!0;const e=_i(n),i=n.nodeName==="SLOT";if((e==null?void 0:e.display)==="contents"&&!i){for(let a=n.firstChild;a;a=a.nextSibling)if(a.nodeType===1&&!rn(a)||a.nodeType===3&&hb(a))return!1;return!0}return!(n.nodeName==="OPTION"&&!!n.closest("select"))&&!i&&!fb(n,e)?!0:vb(n)}function vb(n){let e=bi==null?void 0:bi.get(n);if(e===void 0){if(e=!1,n.parentElement&&n.parentElement.shadowRoot&&!n.assignedSlot&&(e=!0),!e){const i=_i(n);e=!i||i.display==="none"||yb(n.getAttribute("aria-hidden"))===!0}if(!e){const i=yt(n);i&&(e=vb(i))}bi==null||bi.set(n,e)}return e}function gr(n,e){if(!e)return[];const i=cb(n);if(!i)return[];try{const s=e.split(" ").filter(o=>!!o),a=[];for(const o of s){const u=i.querySelector("#"+CSS.escape(o));u&&!a.includes(u)&&a.push(u)}return a}catch{return[]}}function In(n){return n.trim()}function $a(n){return n.split(" ").map(e=>e.replace(/\r\n/g,`
|
|
113
|
+
`).replace(/[\u200b\u00ad]/g,"").replace(/\s\s*/g," ")).join(" ").trim()}function Vy(n,e){const i=[...n.querySelectorAll(e)];for(const s of gr(n,n.getAttribute("aria-owns")))s.matches(e)&&i.push(s),i.push(...s.querySelectorAll(e));return i}function Ia(n,e){const i=e==="::before"?td:e==="::after"?nd:ed;if(i!=null&&i.has(n))return i==null?void 0:i.get(n);const s=_i(n,e);let a;if(s){const o=s.content;o&&o!=="none"&&o!=="normal"&&s.display!=="none"&&s.visibility!=="hidden"&&(a=dT(n,o,!!e))}return e&&a!==void 0&&((s==null?void 0:s.display)||"inline")!=="inline"&&(a=" "+a+" "),i&&i.set(n,a),a}function dT(n,e,i){if(!(!e||e==="none"||e==="normal"))try{let s=N0(e).filter(f=>!(f instanceof Go));const a=s.findIndex(f=>f instanceof ct&&f.value==="/");if(a!==-1)s=s.slice(a+1);else if(!i)return;const o=[];let u=0;for(;u<s.length;)if(s[u]instanceof Lh)o.push(s[u].value),u++;else if(u+2<s.length&&s[u]instanceof qa&&s[u].value==="attr"&&s[u+1]instanceof jh&&s[u+2]instanceof Rh){const f=s[u+1].value;o.push(n.getAttribute(f)||""),u+=3}else return;return o.join("")}catch{}}function Sb(n){const e=n.getAttribute("aria-labelledby");if(e===null)return null;const i=gr(n,e);return i.length?i:null}function pT(n,e){const i=["button","cell","checkbox","columnheader","gridcell","heading","link","menuitem","menuitemcheckbox","menuitemradio","option","radio","row","rowheader","switch","tab","tooltip","treeitem"].includes(n),s=e&&["","caption","code","contentinfo","definition","deletion","emphasis","insertion","list","listitem","mark","none","paragraph","presentation","region","row","rowgroup","section","strong","subscript","superscript","table","term","time"].includes(n);return i||s}function Qa(n,e){const i=e?Zh:Qh;let s=i==null?void 0:i.get(n);return s===void 0&&(s="",["caption","code","definition","deletion","emphasis","generic","insertion","mark","paragraph","presentation","strong","subscript","suggestion","superscript","term","time"].includes(ft(n)||"")||(s=$a(dn(n,{includeHidden:e,visitedElements:new Set,embeddedInTargetElement:"self"}))),i==null||i.set(n,s)),s}function Gy(n,e){const i=e?Wh:Jh;let s=i==null?void 0:i.get(n);if(s===void 0){if(s="",n.hasAttribute("aria-describedby")){const a=gr(n,n.getAttribute("aria-describedby"));s=$a(a.map(o=>dn(o,{includeHidden:e,visitedElements:new Set,embeddedInDescribedBy:{element:o,hidden:rn(o)}})).join(" "))}else n.hasAttribute("aria-description")?s=$a(n.getAttribute("aria-description")||""):s=$a(n.getAttribute("title")||"");i==null||i.set(n,s)}return s}function gT(n){const e=n.getAttribute("aria-invalid");return!e||e.trim()===""||e.toLocaleLowerCase()==="false"?"false":e==="true"||e==="grammar"||e==="spelling"?e:"true"}function mT(n){if("validity"in n){const e=n.validity;return(e==null?void 0:e.valid)===!1}return!1}function yT(n){const e=tr;let i=tr==null?void 0:tr.get(n);if(i===void 0){i="";const s=gT(n)!=="false",a=mT(n);if(s||a){const o=n.getAttribute("aria-errormessage");i=gr(n,o).map(d=>$a(dn(d,{visitedElements:new Set,embeddedInDescribedBy:{element:d,hidden:rn(d)}}))).join(" ").trim()}e==null||e.set(n,i)}return i}function dn(n,e){var d,p,m,y;if(e.visitedElements.has(n))return"";const i={...e,embeddedInTargetElement:e.embeddedInTargetElement==="self"?"descendant":e.embeddedInTargetElement};if(!e.includeHidden){const b=!!((d=e.embeddedInLabelledBy)!=null&&d.hidden)||!!((p=e.embeddedInDescribedBy)!=null&&p.hidden)||!!((m=e.embeddedInNativeTextAlternative)!=null&&m.hidden)||!!((y=e.embeddedInLabel)!=null&&y.hidden);if(bb(n)||!b&&rn(n))return e.visitedElements.add(n),""}const s=Sb(n);if(!e.embeddedInLabelledBy){const b=(s||[]).map(w=>dn(w,{...e,embeddedInLabelledBy:{element:w,hidden:rn(w)},embeddedInDescribedBy:void 0,embeddedInTargetElement:void 0,embeddedInLabel:void 0,embeddedInNativeTextAlternative:void 0})).join(" ");if(b)return b}const a=ft(n)||"",o=st(n);if(e.embeddedInLabel||e.embeddedInLabelledBy||e.embeddedInTargetElement==="descendant"){const b=[...n.labels||[]].includes(n),w=(s||[]).includes(n);if(!b&&!w){if(a==="textbox")return e.visitedElements.add(n),o==="INPUT"||o==="TEXTAREA"?n.value:n.textContent||"";if(["combobox","listbox"].includes(a)){e.visitedElements.add(n);let E;if(o==="SELECT")E=[...n.selectedOptions],!E.length&&n.options.length&&E.push(n.options[0]);else{const x=a==="combobox"?Vy(n,"*").find(_=>ft(_)==="listbox"):n;E=x?Vy(x,'[aria-selected="true"]').filter(_=>ft(_)==="option"):[]}return!E.length&&o==="INPUT"?n.value:E.map(x=>dn(x,i)).join(" ")}if(["progressbar","scrollbar","slider","spinbutton","meter"].includes(a))return e.visitedElements.add(n),n.hasAttribute("aria-valuetext")?n.getAttribute("aria-valuetext")||"":n.hasAttribute("aria-valuenow")?n.getAttribute("aria-valuenow")||"":n.getAttribute("value")||"";if(["menu"].includes(a))return e.visitedElements.add(n),""}}const u=n.getAttribute("aria-label")||"";if(In(u))return e.visitedElements.add(n),u;if(!["presentation","none"].includes(a)){if(o==="INPUT"&&["button","submit","reset"].includes(n.type)){e.visitedElements.add(n);const b=n.value||"";return In(b)?b:n.type==="submit"?"Submit":n.type==="reset"?"Reset":n.getAttribute("title")||""}if(o==="INPUT"&&n.type==="file"){e.visitedElements.add(n);const b=n.labels||[];return b.length&&!e.embeddedInLabelledBy?Na(b,e):"Choose File"}if(o==="INPUT"&&n.type==="image"){e.visitedElements.add(n);const b=n.labels||[];if(b.length&&!e.embeddedInLabelledBy)return Na(b,e);const w=n.getAttribute("alt")||"";if(In(w))return w;const E=n.getAttribute("title")||"";return In(E)?E:"Submit"}if(!s&&o==="BUTTON"){e.visitedElements.add(n);const b=n.labels||[];if(b.length)return Na(b,e)}if(!s&&o==="OUTPUT"){e.visitedElements.add(n);const b=n.labels||[];return b.length?Na(b,e):n.getAttribute("title")||""}if(!s&&(o==="TEXTAREA"||o==="SELECT"||o==="INPUT")){e.visitedElements.add(n);const b=n.labels||[];if(b.length)return Na(b,e);const w=o==="INPUT"&&["text","password","search","tel","email","url"].includes(n.type)||o==="TEXTAREA",E=n.getAttribute("placeholder")||"",x=n.getAttribute("title")||"";return!w||x?x:E}if(!s&&o==="FIELDSET"){e.visitedElements.add(n);for(let w=n.firstElementChild;w;w=w.nextElementSibling)if(st(w)==="LEGEND")return dn(w,{...i,embeddedInNativeTextAlternative:{element:w,hidden:rn(w)}});return n.getAttribute("title")||""}if(!s&&o==="FIGURE"){e.visitedElements.add(n);for(let w=n.firstElementChild;w;w=w.nextElementSibling)if(st(w)==="FIGCAPTION")return dn(w,{...i,embeddedInNativeTextAlternative:{element:w,hidden:rn(w)}});return n.getAttribute("title")||""}if(o==="IMG"){e.visitedElements.add(n);const b=n.getAttribute("alt")||"";return In(b)?b:n.getAttribute("title")||""}if(o==="TABLE"){e.visitedElements.add(n);for(let w=n.firstElementChild;w;w=w.nextElementSibling)if(st(w)==="CAPTION")return dn(w,{...i,embeddedInNativeTextAlternative:{element:w,hidden:rn(w)}});const b=n.getAttribute("summary")||"";if(b)return b}if(o==="AREA"){e.visitedElements.add(n);const b=n.getAttribute("alt")||"";return In(b)?b:n.getAttribute("title")||""}if(o==="SVG"||n.ownerSVGElement){e.visitedElements.add(n);for(let b=n.firstElementChild;b;b=b.nextElementSibling)if(st(b)==="TITLE"&&b.ownerSVGElement)return dn(b,{...i,embeddedInLabelledBy:{element:b,hidden:rn(b)}})}if(n.ownerSVGElement&&o==="A"){const b=n.getAttribute("xlink:title")||"";if(In(b))return e.visitedElements.add(n),b}}const f=o==="SUMMARY"&&!["presentation","none"].includes(a);if(pT(a,e.embeddedInTargetElement==="descendant")||f||e.embeddedInLabelledBy||e.embeddedInDescribedBy||e.embeddedInLabel||e.embeddedInNativeTextAlternative){e.visitedElements.add(n);const b=bT(n,i);if(e.embeddedInTargetElement==="self"?In(b):b)return b}if(!["presentation","none"].includes(a)||o==="IFRAME"){e.visitedElements.add(n);const b=n.getAttribute("title")||"";if(In(b))return b}return e.visitedElements.add(n),""}function bT(n,e){const i=[],s=(o,u)=>{var f;if(!(u&&o.assignedSlot))if(o.nodeType===1){const d=((f=_i(o))==null?void 0:f.display)||"inline";let p=dn(o,e);(d!=="inline"||o.nodeName==="BR")&&(p=" "+p+" "),i.push(p)}else o.nodeType===3&&i.push(o.textContent||"")};i.push(Ia(n,"::before")||"");const a=Ia(n);if(a!==void 0)i.push(a);else{const o=n.nodeName==="SLOT"?n.assignedNodes():[];if(o.length)for(const u of o)s(u,!1);else{for(let u=n.firstChild;u;u=u.nextSibling)s(u,!0);if(n.shadowRoot)for(let u=n.shadowRoot.firstChild;u;u=u.nextSibling)s(u,!0);for(const u of gr(n,n.getAttribute("aria-owns")))s(u,!0)}}return i.push(Ia(n,"::after")||""),i.join("")}const Gh=["gridcell","option","row","tab","rowheader","columnheader","treeitem"];function wb(n){return st(n)==="OPTION"?n.selected:Gh.includes(ft(n)||"")?yb(n.getAttribute("aria-selected"))===!0:!1}const Kh=["checkbox","menuitemcheckbox","option","radio","switch","menuitemradio","treeitem"];function xb(n){const e=Yh(n,!0);return e==="error"?!1:e}function vT(n){return Yh(n,!0)}function ST(n){return Yh(n,!1)}function Yh(n,e){const i=st(n);if(e&&i==="INPUT"&&n.indeterminate)return"mixed";if(i==="INPUT"&&["checkbox","radio"].includes(n.type))return n.checked;if(Kh.includes(ft(n)||"")){const s=n.getAttribute("aria-checked");return s==="true"?!0:e&&s==="mixed"?"mixed":!1}return"error"}const wT=["checkbox","combobox","grid","gridcell","listbox","radiogroup","slider","spinbutton","textbox","columnheader","rowheader","searchbox","switch","treegrid"];function xT(n){const e=st(n);return["INPUT","TEXTAREA","SELECT"].includes(e)?n.hasAttribute("readonly"):wT.includes(ft(n)||"")?n.getAttribute("aria-readonly")==="true":n.isContentEditable?!1:"error"}const Xh=["button"];function _b(n){if(Xh.includes(ft(n)||"")){const e=n.getAttribute("aria-pressed");if(e==="true")return!0;if(e==="mixed")return"mixed"}return!1}const Ph=["application","button","checkbox","combobox","gridcell","link","listbox","menuitem","row","rowheader","tab","treeitem","columnheader","menuitemcheckbox","menuitemradio","rowheader","switch"];function Tb(n){if(st(n)==="DETAILS")return n.open;if(Ph.includes(ft(n)||"")){const e=n.getAttribute("aria-expanded");return e===null?void 0:e==="true"}}const Fh=["heading","listitem","row","treeitem"];function Eb(n){const e={H1:1,H2:2,H3:3,H4:4,H5:5,H6:6}[st(n)];if(e)return e;if(Fh.includes(ft(n)||"")){const i=n.getAttribute("aria-level"),s=i===null?Number.NaN:Number(i);if(Number.isInteger(s)&&s>=1)return s}return 0}const Ab=["application","button","composite","gridcell","group","input","link","menuitem","scrollbar","separator","tab","checkbox","columnheader","combobox","grid","listbox","menu","menubar","menuitemcheckbox","menuitemradio","option","radio","radiogroup","row","rowheader","searchbox","select","slider","spinbutton","switch","tablist","textbox","toolbar","tree","treegrid","treeitem"];function Zo(n){return Nb(n)||Cb(n)}function Nb(n){return["BUTTON","INPUT","SELECT","TEXTAREA","OPTION","OPTGROUP"].includes(st(n))&&(n.hasAttribute("disabled")||_T(n)||TT(n))}function _T(n){return st(n)==="OPTION"&&!!n.closest("OPTGROUP[DISABLED]")}function TT(n){const e=n==null?void 0:n.closest("FIELDSET[DISABLED]");if(!e)return!1;const i=e.querySelector(":scope > LEGEND");return!i||!i.contains(n)}function Cb(n,e=!1){if(!n)return!1;if(e||Ab.includes(ft(n)||"")){const i=(n.getAttribute("aria-disabled")||"").toLowerCase();return i==="true"?!0:i==="false"?!1:Cb(yt(n),!0)}return!1}function Na(n,e){return[...n].map(i=>dn(i,{...e,embeddedInLabel:{element:i,hidden:rn(i)},embeddedInNativeTextAlternative:void 0,embeddedInLabelledBy:void 0,embeddedInDescribedBy:void 0,embeddedInTargetElement:void 0})).filter(i=>!!i).join(" ")}function ET(n){const e=id;let i=n,s;const a=[];for(;i;i=yt(i)){const o=e.get(i);if(o!==void 0){s=o;break}a.push(i);const u=_i(i);if(!u){s=!0;break}const f=u.pointerEvents;if(f){s=f!=="none";break}}s===void 0&&(s=!0);for(const o of a)e.set(o,s);return s}let Qh,Zh,Jh,Wh,tr,bi,ed,td,nd,id,kb=0;function lc(){Ih(),++kb,Qh??(Qh=new Map),Zh??(Zh=new Map),Jh??(Jh=new Map),Wh??(Wh=new Map),tr??(tr=new Map),bi??(bi=new Map),ed??(ed=new Map),td??(td=new Map),nd??(nd=new Map),id??(id=new Map)}function oc(){--kb||(Qh=void 0,Zh=void 0,Jh=void 0,Wh=void 0,tr=void 0,bi=void 0,ed=void 0,td=void 0,nd=void 0,id=void 0),Vh()}const AT={button:"button",checkbox:"checkbox",image:"button",number:"spinbutton",radio:"radio",range:"slider",reset:"button",submit:"button"};function NT(n){return Mb(n)?"'"+n.replace(/'/g,"''")+"'":n}function Ff(n){return Mb(n)?'"'+n.replace(/[\\"\x00-\x1f\x7f-\x9f]/g,e=>{switch(e){case"\\":return"\\\\";case'"':return'\\"';case"\b":return"\\b";case"\f":return"\\f";case`
|
|
114
|
+
`:return"\\n";case"\r":return"\\r";case" ":return"\\t";default:return"\\x"+e.charCodeAt(0).toString(16).padStart(2,"0")}})+'"':n}function Mb(n){return!!(n.length===0||/^\s|\s$/.test(n)||/[\x00-\x08\x0b\x0c\x0e-\x1f\x7f-\x9f]/.test(n)||/^-/.test(n)||/[\n:](\s|$)/.test(n)||/\s#/.test(n)||/[\n\r]/.test(n)||/^[&*\],?!>|@"'#%]/.test(n)||/[{}`]/.test(n)||/^\[/.test(n)||!isNaN(Number(n))||["y","n","yes","no","true","false","on","off","null"].includes(n.toLowerCase()))}let CT=0;function Ob(n){return n.mode==="ai"?{visibility:"ariaOrVisible",refs:"interactable",refPrefix:n.refPrefix,includeGenericRole:!0,renderActive:!0,renderCursorPointer:!0}:n.mode==="autoexpect"?{visibility:"ariaAndVisible",refs:"none"}:n.mode==="codegen"?{visibility:"aria",refs:"none",renderStringsAsRegex:!0}:{visibility:"aria",refs:"none"}}function Va(n,e){const i=Ob(e),s=new Set,a={root:{role:"fragment",name:"",children:[],element:n,props:{},box:Fo(n),receivesPointerEvents:!0},elements:new Map,refs:new Map},o=(f,d,p)=>{if(s.has(d))return;if(s.add(d),d.nodeType===Node.TEXT_NODE&&d.nodeValue){if(!p)return;const x=d.nodeValue;f.role!=="textbox"&&x&&f.children.push(d.nodeValue||"");return}if(d.nodeType!==Node.ELEMENT_NODE)return;const m=d,y=!rn(m);let b=y;if(i.visibility==="ariaOrVisible"&&(b=y||vi(m)),i.visibility==="ariaAndVisible"&&(b=y&&vi(m)),i.visibility==="aria"&&!b)return;const w=[];if(m.hasAttribute("aria-owns")){const x=m.getAttribute("aria-owns").split(/\s+/);for(const _ of x){const k=n.ownerDocument.getElementById(_);k&&w.push(k)}}const E=b?kT(m,i):null;E&&(E.ref&&(a.elements.set(E.ref,m),a.refs.set(m,E.ref)),f.children.push(E)),u(E||f,m,w,b)};function u(f,d,p,m){var E;const b=(((E=_i(d))==null?void 0:E.display)||"inline")!=="inline"||d.nodeName==="BR"?" ":"";b&&f.children.push(b),f.children.push(Ia(d,"::before")||"");const w=d.nodeName==="SLOT"?d.assignedNodes():[];if(w.length)for(const x of w)o(f,x,m);else{for(let x=d.firstChild;x;x=x.nextSibling)x.assignedSlot||o(f,x,m);if(d.shadowRoot)for(let x=d.shadowRoot.firstChild;x;x=x.nextSibling)o(f,x,m)}for(const x of p)o(f,x,m);if(f.children.push(Ia(d,"::after")||""),b&&f.children.push(b),f.children.length===1&&f.name===f.children[0]&&(f.children=[]),f.role==="link"&&d.hasAttribute("href")){const x=d.getAttribute("href");f.props.url=x}if(f.role==="textbox"&&d.hasAttribute("placeholder")&&d.getAttribute("placeholder")!==f.name){const x=d.getAttribute("placeholder");f.props.placeholder=x}}lc();try{o(a.root,n,!0)}finally{oc()}return OT(a.root),MT(a.root),a}function Ky(n,e){if(e.refs==="none"||e.refs==="interactable"&&(!n.box.visible||!n.receivesPointerEvents))return;let i;i=n.element._ariaRef,(!i||i.role!==n.role||i.name!==n.name)&&(i={role:n.role,name:n.name,ref:(e.refPrefix??"")+"e"+ ++CT},n.element._ariaRef=i),n.ref=i.ref}function kT(n,e){const i=n.ownerDocument.activeElement===n;if(n.nodeName==="IFRAME"){const p={role:"iframe",name:"",children:[],props:{},element:n,box:Fo(n),receivesPointerEvents:!0,active:i};return Ky(p,e),p}const s=e.includeGenericRole?"generic":null,a=ft(n)??s;if(!a||a==="presentation"||a==="none")return null;const o=Tt(Qa(n,!1)||""),u=ET(n),f=Fo(n);if(a==="generic"&&f.inline&&n.childNodes.length===1&&n.childNodes[0].nodeType===Node.TEXT_NODE)return null;const d={role:a,name:o,children:[],props:{},element:n,box:f,receivesPointerEvents:u,active:i};return Ky(d,e),Kh.includes(a)&&(d.checked=xb(n)),Ab.includes(a)&&(d.disabled=Zo(n)),Ph.includes(a)&&(d.expanded=Tb(n)),Fh.includes(a)&&(d.level=Eb(n)),Xh.includes(a)&&(d.pressed=_b(n)),Gh.includes(a)&&(d.selected=wb(n)),(n instanceof HTMLInputElement||n instanceof HTMLTextAreaElement)&&n.type!=="checkbox"&&n.type!=="radio"&&n.type!=="file"&&(d.children=[n.value]),d}function MT(n){const e=i=>{const s=[];for(const o of i.children||[]){if(typeof o=="string"){s.push(o);continue}const u=e(o);s.push(...u)}return i.role==="generic"&&!i.name&&s.length<=1&&s.every(o=>typeof o!="string"&&!!o.ref)?s:(i.children=s,[i])};e(n)}function OT(n){const e=(s,a)=>{if(!s.length)return;const o=Tt(s.join(""));o&&a.push(o),s.length=0},i=s=>{const a=[],o=[];for(const u of s.children||[])typeof u=="string"?o.push(u):(e(o,a),i(u),a.push(u));e(o,a),s.children=a.length?a:[],s.children.length===1&&s.children[0]===s.name&&(s.children=[])};i(n)}function RT(n,e){return e?n?typeof e=="string"?n===e:!!n.match(new RegExp(e.pattern)):!1:!0}function Yy(n,e){if(!(e!=null&&e.normalized))return!0;if(!n)return!1;if(n===e.normalized||n===e.raw)return!0;const i=jT(e);return i?!!n.match(i):!1}const Qf=Symbol("cachedRegex");function jT(n){if(n[Qf]!==void 0)return n[Qf];const{raw:e}=n,i=e.startsWith("/")&&e.endsWith("/")&&e.length>1;let s;try{s=i?new RegExp(e.slice(1,-1)):null}catch{s=null}return n[Qf]=s,s}function LT(n,e){const i=Va(n,{mode:"expect"});return{matches:Rb(i.root,e,!1,!1),received:{raw:Jo(i,{mode:"expect"}),regex:Jo(i,{mode:"codegen"})}}}function DT(n,e){const i=Va(n,{mode:"expect"}).root;return Rb(i,e,!0,!1).map(a=>a.element)}function sd(n,e,i){var s;return typeof n=="string"&&e.kind==="text"?Yy(n,e.text):n===null||typeof n!="object"||e.kind!=="role"||e.role!=="fragment"&&e.role!==n.role||e.checked!==void 0&&e.checked!==n.checked||e.disabled!==void 0&&e.disabled!==n.disabled||e.expanded!==void 0&&e.expanded!==n.expanded||e.level!==void 0&&e.level!==n.level||e.pressed!==void 0&&e.pressed!==n.pressed||e.selected!==void 0&&e.selected!==n.selected||!RT(n.name,e.name)||!Yy(n.props.url,(s=e.props)==null?void 0:s.url)?!1:e.containerMode==="contain"?Py(n.children||[],e.children||[]):e.containerMode==="equal"?Xy(n.children||[],e.children||[],!1):e.containerMode==="deep-equal"||i?Xy(n.children||[],e.children||[],!0):Py(n.children||[],e.children||[])}function Xy(n,e,i){if(e.length!==n.length)return!1;for(let s=0;s<e.length;++s)if(!sd(n[s],e[s],i))return!1;return!0}function Py(n,e){if(e.length>n.length)return!1;const i=n.slice(),s=e.slice();for(const a of s){let o=i.shift();for(;o&&!sd(o,a,!1);)o=i.shift();if(!o)return!1}return!0}function Rb(n,e,i,s){const a=[],o=(u,f)=>{if(sd(u,e,s)){const d=typeof u=="string"?f:u;return d&&a.push(d),!i}if(typeof u=="string")return!1;for(const d of u.children||[])if(o(d,u))return!0;return!1};return o(n,null),a}function jb(n,e=new Map){n!=null&&n.ref&&e.set(n.ref,n);for(const i of(n==null?void 0:n.children)||[])typeof i!="string"&&jb(i,e);return e}function Lb(n){return n.role==="iframe"?!0:(n.children||[]).some(e=>typeof e!="string"&&Lb(e))}function BT(n,e){const i=Object.keys(n.props),s=Object.keys(e.props);return i.length===s.length&&i.every(a=>n.props[a]===e.props[a])}function Jo(n,e,i){Lb(n.root)&&(i=void 0);const s=Ob(e),a=[],o=s.renderStringsAsRegex?zT:()=>!0,u=s.renderStringsAsRegex?UT:w=>w,f=jb(i==null?void 0:i.root),d=(w,E)=>{const x=Ff(u(w));x&&a.push(E+"- text: "+x)},p=(w,E)=>{let x=w.role;if(w.name&&w.name.length<=900){const _=u(w.name);if(_){const k=_.startsWith("/")&&_.endsWith("/")?_:JSON.stringify(_);x+=" "+k}}return w.checked==="mixed"&&(x+=" [checked=mixed]"),w.checked===!0&&(x+=" [checked]"),w.disabled&&(x+=" [disabled]"),w.expanded&&(x+=" [expanded]"),w.active&&s.renderActive&&(x+=" [active]"),w.level&&(x+=` [level=${w.level}]`),w.pressed==="mixed"&&(x+=" [pressed=mixed]"),w.pressed===!0&&(x+=" [pressed]"),w.selected===!0&&(x+=" [selected]"),w.ref&&(x+=` [ref=${w.ref}]`,E&&Fy(w)&&(x+=" [cursor=pointer]")),x},m=w=>(w==null?void 0:w.children.length)===1&&typeof w.children[0]=="string"&&!Object.keys(w.props).length?w.children[0]:void 0,y=(w,E,x,_)=>{w.ref&&(_=f.get(w.ref));const k=a.length,C=p(w,x),V=E+"- "+NT(C),I=x&&!!w.ref&&Fy(w),B=m(w);let G=!!_&&C===p(_,x)&&BT(w,_);if(!w.children.length&&!Object.keys(w.props).length)a.push(V);else if(B!==void 0)G=G&&m(_)===B,o(w,B)?a.push(V+": "+Ff(u(B))):a.push(V);else{a.push(V+":");for(const[$,R]of Object.entries(w.props))a.push(E+" - /"+$+": "+Ff(R));G=G&&(_==null?void 0:_.children.length)===w.children.length;const J=E+" ";for(let $=0;$<w.children.length;$++){const R=w.children[$];if(typeof R=="string")G=G&&(_==null?void 0:_.children[$])===R,o(w,R)&&d(R,J);else{const ee=_==null?void 0:_.children[$],re=y(R,J,x&&!I,typeof ee!="string"?ee:void 0);G=G&&re.unchanged}}}return G&&w.ref&&(a.splice(k),a.push(E+`- ref=${w.ref} [unchanged]`)),{unchanged:G}},b=n.root.role==="fragment"?n.root.children:[n.root];for(const w of b)typeof w=="string"?d(w,""):y(w,"",!!s.renderCursorPointer,void 0);return a.join(`
|
|
115
|
+
`)}function UT(n){const e=[{regex:/\b[\d,.]+[bkmBKM]+\b/,replacement:"[\\d,.]+[bkmBKM]+"},{regex:/\b\d+[hmsp]+\b/,replacement:"\\d+[hmsp]+"},{regex:/\b[\d,.]+[hmsp]+\b/,replacement:"[\\d,.]+[hmsp]+"},{regex:/\b\d+,\d+\b/,replacement:"\\d+,\\d+"},{regex:/\b\d+\.\d{2,}\b/,replacement:"\\d+\\.\\d+"},{regex:/\b\d{2,}\.\d+\b/,replacement:"\\d+\\.\\d+"},{regex:/\b\d{2,}\b/,replacement:"\\d+"}];let i="",s=0;const a=new RegExp(e.map(o=>"("+o.regex.source+")").join("|"),"g");return n.replace(a,(o,...u)=>{const f=u[u.length-2],d=u.slice(0,-2);i+=Yo(n.slice(s,f));for(let p=0;p<d.length;p++)if(d[p]){const{replacement:m}=e[p];i+=m;break}return s=f+o.length,o}),i?(i+=Yo(n.slice(s)),String(new RegExp(i))):n}function zT(n,e){if(!e.length)return!1;if(!n.name)return!0;if(n.name.length>e.length)return!1;const i=e.length<=200&&n.name.length<=200?_x(e,n.name):"";let s=e;for(;i&&s.includes(i);)s=s.replace(i,"");return s.trim().length/e.length>.1}function Fy(n){return n.box.cursor==="pointer"}const Qy=":host{font-size:13px;font-family:system-ui,Ubuntu,Droid Sans,sans-serif;color:#333}svg{position:absolute;height:0}x-pw-tooltip{-webkit-backdrop-filter:blur(5px);backdrop-filter:blur(5px);background-color:#fff;border-radius:6px;box-shadow:0 .5rem 1.2rem #0000004d;display:none;font-size:12.8px;font-weight:400;left:0;line-height:1.5;max-width:600px;position:absolute;top:0;padding:0;flex-direction:column;overflow:hidden}x-pw-tooltip-line{display:flex;max-width:600px;padding:6px;-webkit-user-select:none;user-select:none;cursor:pointer}x-pw-tooltip-footer{display:flex;max-width:600px;padding:6px;-webkit-user-select:none;user-select:none;color:#777}x-pw-dialog{background-color:#fff;pointer-events:auto;border-radius:6px;box-shadow:0 .5rem 1.2rem #0000004d;display:flex;flex-direction:column;position:absolute;z-index:10;font-size:13px}x-pw-dialog:not(.autosize){width:400px;height:150px}x-pw-dialog-body{display:flex;flex-direction:column;flex:auto}x-pw-dialog-body label{margin:5px 8px;display:flex;flex-direction:row;align-items:center}x-pw-highlight{position:absolute;top:0;left:0;width:0;height:0}x-pw-action-point{position:absolute;width:20px;height:20px;background:red;border-radius:10px;margin:-10px 0 0 -10px;z-index:2}x-pw-separator{height:1px;margin:6px 9px;background:#949494e5}x-pw-tool-gripper{height:28px;width:24px;margin:2px 0;cursor:grab}x-pw-tool-gripper:active{cursor:grabbing}x-pw-tool-gripper>x-div{width:16px;height:16px;margin:6px 4px;clip-path:url(#icon-gripper);background-color:#555}x-pw-tools-list>label{display:flex;align-items:center;margin:0 10px;-webkit-user-select:none;user-select:none}x-pw-tools-list{display:flex;width:100%;border-bottom:1px solid #dddddd}x-pw-tool-item{pointer-events:auto;height:28px;width:28px;border-radius:3px}x-pw-tool-item:not(.disabled){cursor:pointer}x-pw-tool-item:not(.disabled):hover{background-color:#dbdbdb}x-pw-tool-item.toggled{background-color:#8acae480}x-pw-tool-item.toggled:not(.disabled):hover{background-color:#8acae4c4}x-pw-tool-item>x-div{width:16px;height:16px;margin:6px;background-color:#3a3a3a}x-pw-tool-item.disabled>x-div{background-color:#61616180;cursor:default}x-pw-tool-item.record.toggled{background-color:transparent}x-pw-tool-item.record.toggled:not(.disabled):hover{background-color:#dbdbdb}x-pw-tool-item.record.toggled>x-div{background-color:#a1260d}x-pw-tool-item.record.disabled.toggled>x-div{opacity:.8}x-pw-tool-item.accept>x-div{background-color:#388a34}x-pw-tool-item.record>x-div{clip-path:url(#icon-circle-large-filled)}x-pw-tool-item.record.toggled>x-div{clip-path:url(#icon-stop-circle)}x-pw-tool-item.pick-locator>x-div{clip-path:url(#icon-inspect)}x-pw-tool-item.text>x-div{clip-path:url(#icon-whole-word)}x-pw-tool-item.visibility>x-div{clip-path:url(#icon-eye)}x-pw-tool-item.value>x-div{clip-path:url(#icon-symbol-constant)}x-pw-tool-item.snapshot>x-div{clip-path:url(#icon-gist)}x-pw-tool-item.accept>x-div{clip-path:url(#icon-check)}x-pw-tool-item.cancel>x-div{clip-path:url(#icon-close)}x-pw-tool-item.succeeded>x-div{clip-path:url(#icon-pass);background-color:#388a34!important}x-pw-overlay{position:absolute;top:0;max-width:min-content;z-index:2147483647;background:transparent;pointer-events:auto}x-pw-overlay x-pw-tools-list{background-color:#fffd;box-shadow:#0000001a 0 5px 5px;border-radius:3px;border-bottom:none}x-pw-overlay x-pw-tool-item{margin:2px}textarea.text-editor{font-family:system-ui,Ubuntu,Droid Sans,sans-serif;flex:auto;border:none;margin:6px 10px;color:#333;outline:1px solid transparent!important;resize:none;padding:0;font-size:13px}textarea.text-editor.does-not-match{outline:1px solid red!important}x-div{display:block}x-spacer{flex:auto}*{box-sizing:border-box}*[hidden]{display:none!important}x-locator-editor{flex:none;width:100%;height:60px;padding:4px;border-bottom:1px solid #dddddd;outline:1px solid transparent}x-locator-editor.does-not-match{outline:1px solid red}.CodeMirror{width:100%!important;height:100%!important}x-pw-action-list{flex:auto;display:flex;flex-direction:column;-webkit-user-select:none;user-select:none}x-pw-action-item{padding:6px 10px;cursor:pointer;overflow:hidden}x-pw-action-item:hover{background-color:#f2f2f2}x-pw-action-item:last-child{border-bottom-left-radius:6px;border-bottom-right-radius:6px}";class Zf{constructor(e){this._renderedEntries=[],this._language="javascript",this._injectedScript=e;const i=e.document;if(this._isUnderTest=e.isUnderTest,this._glassPaneElement=i.createElement("x-pw-glass"),this._glassPaneElement.style.position="fixed",this._glassPaneElement.style.top="0",this._glassPaneElement.style.right="0",this._glassPaneElement.style.bottom="0",this._glassPaneElement.style.left="0",this._glassPaneElement.style.zIndex="2147483647",this._glassPaneElement.style.pointerEvents="none",this._glassPaneElement.style.display="flex",this._glassPaneElement.style.backgroundColor="transparent",this._actionPointElement=i.createElement("x-pw-action-point"),this._actionPointElement.setAttribute("hidden","true"),this._glassPaneShadow=this._glassPaneElement.attachShadow({mode:this._isUnderTest?"open":"closed"}),typeof this._glassPaneShadow.adoptedStyleSheets.push=="function"){const s=new this._injectedScript.window.CSSStyleSheet;s.replaceSync(Qy),this._glassPaneShadow.adoptedStyleSheets.push(s)}else{const s=this._injectedScript.document.createElement("style");s.textContent=Qy,this._glassPaneShadow.appendChild(s)}this._glassPaneShadow.appendChild(this._actionPointElement)}install(){this._injectedScript.document.documentElement&&(!this._injectedScript.document.documentElement.contains(this._glassPaneElement)||this._glassPaneElement.nextElementSibling)&&this._injectedScript.document.documentElement.appendChild(this._glassPaneElement)}setLanguage(e){this._language=e}runHighlightOnRaf(e){this._rafRequest&&this._injectedScript.utils.builtins.cancelAnimationFrame(this._rafRequest);const i=this._injectedScript.querySelectorAll(e,this._injectedScript.document.documentElement),s=Wi(this._language,Gn(e)),a=i.length>1?"#f6b26b7f":"#6fa8dc7f";this.updateHighlight(i.map((o,u)=>{const f=i.length>1?` [${u+1} of ${i.length}]`:"";return{element:o,color:a,tooltipText:s+f}})),this._rafRequest=this._injectedScript.utils.builtins.requestAnimationFrame(()=>this.runHighlightOnRaf(e))}uninstall(){this._rafRequest&&this._injectedScript.utils.builtins.cancelAnimationFrame(this._rafRequest),this._glassPaneElement.remove()}showActionPoint(e,i){this._actionPointElement.style.top=i+"px",this._actionPointElement.style.left=e+"px",this._actionPointElement.hidden=!1}hideActionPoint(){this._actionPointElement.hidden=!0}clearHighlight(){var e,i;for(const s of this._renderedEntries)(e=s.highlightElement)==null||e.remove(),(i=s.tooltipElement)==null||i.remove();this._renderedEntries=[]}maskElements(e,i){this.updateHighlight(e.map(s=>({element:s,color:i})))}updateHighlight(e){if(!this._highlightIsUpToDate(e)){this.clearHighlight();for(const i of e){const s=this._createHighlightElement();this._glassPaneShadow.appendChild(s);let a;if(i.tooltipText){a=this._injectedScript.document.createElement("x-pw-tooltip"),this._glassPaneShadow.appendChild(a),a.style.top="0",a.style.left="0",a.style.display="flex";const o=this._injectedScript.document.createElement("x-pw-tooltip-line");o.textContent=i.tooltipText,a.appendChild(o)}this._renderedEntries.push({targetElement:i.element,color:i.color,tooltipElement:a,highlightElement:s})}for(const i of this._renderedEntries){if(i.box=i.targetElement.getBoundingClientRect(),!i.tooltipElement)continue;const{anchorLeft:s,anchorTop:a}=this.tooltipPosition(i.box,i.tooltipElement);i.tooltipTop=a,i.tooltipLeft=s}for(const i of this._renderedEntries){i.tooltipElement&&(i.tooltipElement.style.top=i.tooltipTop+"px",i.tooltipElement.style.left=i.tooltipLeft+"px");const s=i.box;i.highlightElement.style.backgroundColor=i.color,i.highlightElement.style.left=s.x+"px",i.highlightElement.style.top=s.y+"px",i.highlightElement.style.width=s.width+"px",i.highlightElement.style.height=s.height+"px",i.highlightElement.style.display="block",this._isUnderTest&&console.error("Highlight box for test: "+JSON.stringify({x:s.x,y:s.y,width:s.width,height:s.height}))}}}firstBox(){var e;return(e=this._renderedEntries[0])==null?void 0:e.box}firstTooltipBox(){const e=this._renderedEntries[0];if(!(!e||!e.tooltipElement||e.tooltipLeft===void 0||e.tooltipTop===void 0))return{x:e.tooltipLeft,y:e.tooltipTop,left:e.tooltipLeft,top:e.tooltipTop,width:e.tooltipElement.offsetWidth,height:e.tooltipElement.offsetHeight,bottom:e.tooltipTop+e.tooltipElement.offsetHeight,right:e.tooltipLeft+e.tooltipElement.offsetWidth,toJSON:()=>{}}}tooltipPosition(e,i){const s=i.offsetWidth,a=i.offsetHeight,o=this._glassPaneElement.offsetWidth,u=this._glassPaneElement.offsetHeight;let f=Math.max(5,e.left);f+s>o-5&&(f=o-s-5);let d=Math.max(0,e.bottom)+5;return d+a>u-5&&(Math.max(0,e.top)>a+5?d=Math.max(0,e.top)-a-5:d=u-5-a),{anchorLeft:f,anchorTop:d}}_highlightIsUpToDate(e){if(e.length!==this._renderedEntries.length)return!1;for(let i=0;i<this._renderedEntries.length;++i){if(e[i].element!==this._renderedEntries[i].targetElement||e[i].color!==this._renderedEntries[i].color)return!1;const s=this._renderedEntries[i].box;if(!s)return!1;const a=e[i].element.getBoundingClientRect();if(a.top!==s.top||a.right!==s.right||a.bottom!==s.bottom||a.left!==s.left)return!1}return!0}_createHighlightElement(){return this._injectedScript.document.createElement("x-pw-highlight")}appendChild(e){this._glassPaneShadow.appendChild(e)}onGlassPaneClick(e){this._glassPaneElement.style.pointerEvents="auto",this._glassPaneElement.style.backgroundColor="rgba(0, 0, 0, 0.3)",this._glassPaneElement.addEventListener("click",e)}offGlassPaneClick(e){this._glassPaneElement.style.pointerEvents="none",this._glassPaneElement.style.backgroundColor="transparent",this._glassPaneElement.removeEventListener("click",e)}}function HT(n,e,i){const s=n.left-e.right;if(!(s<0||i!==void 0&&s>i))return s+Math.max(e.bottom-n.bottom,0)+Math.max(n.top-e.top,0)}function qT(n,e,i){const s=e.left-n.right;if(!(s<0||i!==void 0&&s>i))return s+Math.max(e.bottom-n.bottom,0)+Math.max(n.top-e.top,0)}function $T(n,e,i){const s=e.top-n.bottom;if(!(s<0||i!==void 0&&s>i))return s+Math.max(n.left-e.left,0)+Math.max(e.right-n.right,0)}function IT(n,e,i){const s=n.top-e.bottom;if(!(s<0||i!==void 0&&s>i))return s+Math.max(n.left-e.left,0)+Math.max(e.right-n.right,0)}function VT(n,e,i){const s=i===void 0?50:i;let a=0;return n.left-e.right>=0&&(a+=n.left-e.right),e.left-n.right>=0&&(a+=e.left-n.right),e.top-n.bottom>=0&&(a+=e.top-n.bottom),n.top-e.bottom>=0&&(a+=n.top-e.bottom),a>s?void 0:a}const GT=["left-of","right-of","above","below","near"];function Db(n,e,i,s){const a=e.getBoundingClientRect(),o={"left-of":qT,"right-of":HT,above:$T,below:IT,near:VT}[n];let u;for(const f of i){if(f===e)continue;const d=o(a,f.getBoundingClientRect(),s);d!==void 0&&(u===void 0||d<u)&&(u=d)}return u}function Bb(n,e){for(const i of e.jsonPath)n!=null&&(n=n[i]);return Ub(n,e)}function Ub(n,e){const i=typeof n=="string"&&!e.caseSensitive?n.toUpperCase():n,s=typeof e.value=="string"&&!e.caseSensitive?e.value.toUpperCase():e.value;return e.op==="<truthy>"?!!i:e.op==="="?s instanceof RegExp?typeof i=="string"&&!!i.match(s):i===s:typeof i!="string"||typeof s!="string"?!1:e.op==="*="?i.includes(s):e.op==="^="?i.startsWith(s):e.op==="$="?i.endsWith(s):e.op==="|="?i===s||i.startsWith(s+"-"):e.op==="~="?i.split(" ").includes(s):!1}function rd(n){const e=n.ownerDocument;return n.nodeName==="SCRIPT"||n.nodeName==="NOSCRIPT"||n.nodeName==="STYLE"||e.head&&e.head.contains(n)}function Bt(n,e){let i=n.get(e);if(i===void 0){if(i={full:"",normalized:"",immediate:[]},!rd(e)){let s="";if(e instanceof HTMLInputElement&&(e.type==="submit"||e.type==="button"))i={full:e.value,normalized:Tt(e.value),immediate:[e.value]};else{for(let a=e.firstChild;a;a=a.nextSibling)if(a.nodeType===Node.TEXT_NODE)i.full+=a.nodeValue||"",s+=a.nodeValue||"";else{if(a.nodeType===Node.COMMENT_NODE)continue;s&&i.immediate.push(s),s="",a.nodeType===Node.ELEMENT_NODE&&(i.full+=Bt(n,a).full)}s&&i.immediate.push(s),e.shadowRoot&&(i.full+=Bt(n,e.shadowRoot).full),i.full&&(i.normalized=Tt(i.full))}}n.set(e,i)}return i}function cc(n,e,i){if(rd(e)||!i(Bt(n,e)))return"none";for(let s=e.firstChild;s;s=s.nextSibling)if(s.nodeType===Node.ELEMENT_NODE&&i(Bt(n,s)))return"selfAndChildren";return e.shadowRoot&&i(Bt(n,e.shadowRoot))?"selfAndChildren":"self"}function zb(n,e){const i=Sb(e);if(i)return i.map(o=>Bt(n,o));const s=e.getAttribute("aria-label");if(s!==null&&s.trim())return[{full:s,normalized:Tt(s),immediate:[s]}];const a=e.nodeName==="INPUT"&&e.type!=="hidden";if(["BUTTON","METER","OUTPUT","PROGRESS","SELECT","TEXTAREA"].includes(e.nodeName)||a){const o=e.labels;if(o)return[...o].map(u=>Bt(n,u))}return[]}function Zy(n){return n.displayName||n.name||"Anonymous"}function KT(n){if(n.type)switch(typeof n.type){case"function":return Zy(n.type);case"string":return n.type;case"object":return n.type.displayName||(n.type.render?Zy(n.type.render):"")}if(n._currentElement){const e=n._currentElement.type;if(typeof e=="string")return e;if(typeof e=="function")return e.displayName||e.name||"Anonymous"}return""}function YT(n){var e;return n.key??((e=n._currentElement)==null?void 0:e.key)}function XT(n){if(n.child){const i=[];for(let s=n.child;s;s=s.sibling)i.push(s);return i}if(!n._currentElement)return[];const e=i=>{var a;const s=(a=i._currentElement)==null?void 0:a.type;return typeof s=="function"||typeof s=="string"};if(n._renderedComponent){const i=n._renderedComponent;return e(i)?[i]:[]}return n._renderedChildren?[...Object.values(n._renderedChildren)].filter(e):[]}function PT(n){var s;const e=n.memoizedProps||((s=n._currentElement)==null?void 0:s.props);if(!e||typeof e=="string")return e;const i={...e};return delete i.children,i}function Hb(n){var s;const e={key:YT(n),name:KT(n),children:XT(n).map(Hb),rootElements:[],props:PT(n)},i=n.stateNode||n._hostNode||((s=n._renderedComponent)==null?void 0:s._hostNode);if(i instanceof Element)e.rootElements.push(i);else for(const a of e.children)e.rootElements.push(...a.rootElements);return e}function qb(n,e,i=[]){e(n)&&i.push(n);for(const s of n.children)qb(s,e,i);return i}function $b(n,e=[]){const s=(n.ownerDocument||n).createTreeWalker(n,NodeFilter.SHOW_ELEMENT);do{const a=s.currentNode,o=a,u=Object.keys(o).find(d=>d.startsWith("__reactContainer")&&o[d]!==null);if(u)e.push(o[u].stateNode.current);else{const d="_reactRootContainer";o.hasOwnProperty(d)&&o[d]!==null&&e.push(o[d]._internalRoot.current)}if(a instanceof Element&&a.hasAttribute("data-reactroot"))for(const d of Object.keys(a))(d.startsWith("__reactInternalInstance")||d.startsWith("__reactFiber"))&&e.push(a[d]);const f=a instanceof Element?a.shadowRoot:null;f&&$b(f,e)}while(s.nextNode());return e}const FT=()=>({queryAll(n,e){const{name:i,attributes:s}=Ji(e,!1),u=$b(n.ownerDocument||n).map(d=>Hb(d)).map(d=>qb(d,p=>{const m=p.props??{};if(p.key!==void 0&&(m.key=p.key),i&&p.name!==i||p.rootElements.some(y=>!Fa(n,y)))return!1;for(const y of s)if(!Bb(m,y))return!1;return!0})).flat(),f=new Set;for(const d of u)for(const p of d.rootElements)f.add(p);return[...f]}}),Ib=["selected","checked","pressed","expanded","level","disabled","name","include-hidden"];Ib.sort();function Ca(n,e,i){if(!e.includes(i))throw new Error(`"${n}" attribute is only supported for roles: ${e.slice().sort().map(s=>`"${s}"`).join(", ")}`)}function Ps(n,e){if(n.op!=="<truthy>"&&!e.includes(n.value))throw new Error(`"${n.name}" must be one of ${e.map(i=>JSON.stringify(i)).join(", ")}`)}function Fs(n,e){if(!e.includes(n.op))throw new Error(`"${n.name}" does not support "${n.op}" matcher`)}function QT(n,e){const i={role:e};for(const s of n)switch(s.name){case"checked":{Ca(s.name,Kh,e),Ps(s,[!0,!1,"mixed"]),Fs(s,["<truthy>","="]),i.checked=s.op==="<truthy>"?!0:s.value;break}case"pressed":{Ca(s.name,Xh,e),Ps(s,[!0,!1,"mixed"]),Fs(s,["<truthy>","="]),i.pressed=s.op==="<truthy>"?!0:s.value;break}case"selected":{Ca(s.name,Gh,e),Ps(s,[!0,!1]),Fs(s,["<truthy>","="]),i.selected=s.op==="<truthy>"?!0:s.value;break}case"expanded":{Ca(s.name,Ph,e),Ps(s,[!0,!1]),Fs(s,["<truthy>","="]),i.expanded=s.op==="<truthy>"?!0:s.value;break}case"level":{if(Ca(s.name,Fh,e),typeof s.value=="string"&&(s.value=+s.value),s.op!=="="||typeof s.value!="number"||Number.isNaN(s.value))throw new Error('"level" attribute must be compared to a number');i.level=s.value;break}case"disabled":{Ps(s,[!0,!1]),Fs(s,["<truthy>","="]),i.disabled=s.op==="<truthy>"?!0:s.value;break}case"name":{if(s.op==="<truthy>")throw new Error('"name" attribute must have a value');if(typeof s.value!="string"&&!(s.value instanceof RegExp))throw new Error('"name" attribute must be a string or a regular expression');i.name=s.value,i.nameOp=s.op,i.exact=s.caseSensitive;break}case"include-hidden":{Ps(s,[!0,!1]),Fs(s,["<truthy>","="]),i.includeHidden=s.op==="<truthy>"?!0:s.value;break}default:throw new Error(`Unknown attribute "${s.name}", must be one of ${Ib.map(a=>`"${a}"`).join(", ")}.`)}return i}function ZT(n,e,i){const s=[],a=u=>{if(ft(u)===e.role&&!(e.selected!==void 0&&wb(u)!==e.selected)&&!(e.checked!==void 0&&xb(u)!==e.checked)&&!(e.pressed!==void 0&&_b(u)!==e.pressed)&&!(e.expanded!==void 0&&Tb(u)!==e.expanded)&&!(e.level!==void 0&&Eb(u)!==e.level)&&!(e.disabled!==void 0&&Zo(u)!==e.disabled)&&!(!e.includeHidden&&rn(u))){if(e.name!==void 0){const f=Tt(Qa(u,!!e.includeHidden));if(typeof e.name=="string"&&(e.name=Tt(e.name)),i&&!e.exact&&e.nameOp==="="&&(e.nameOp="*="),!Ub(f,{op:e.nameOp||"=",value:e.name,caseSensitive:!!e.exact}))return}s.push(u)}},o=u=>{const f=[];u.shadowRoot&&f.push(u.shadowRoot);for(const d of u.querySelectorAll("*"))a(d),d.shadowRoot&&f.push(d.shadowRoot);f.forEach(o)};return o(n),s}function Jy(n){return{queryAll:(e,i)=>{const s=Ji(i,!0),a=s.name.toLowerCase();if(!a)throw new Error("Role must not be empty");const o=QT(s.attributes,a);lc();try{return ZT(e,o,n)}finally{oc()}}}}class JT{constructor(){this._retainCacheCounter=0,this._cacheText=new Map,this._cacheQueryCSS=new Map,this._cacheMatches=new Map,this._cacheQuery=new Map,this._cacheMatchesSimple=new Map,this._cacheMatchesParents=new Map,this._cacheCallMatches=new Map,this._cacheCallQuery=new Map,this._cacheQuerySimple=new Map,this._engines=new Map,this._engines.set("not",tE),this._engines.set("is",Ba),this._engines.set("where",Ba),this._engines.set("has",WT),this._engines.set("scope",eE),this._engines.set("light",nE),this._engines.set("visible",iE),this._engines.set("text",sE),this._engines.set("text-is",rE),this._engines.set("text-matches",aE),this._engines.set("has-text",lE),this._engines.set("right-of",ka("right-of")),this._engines.set("left-of",ka("left-of")),this._engines.set("above",ka("above")),this._engines.set("below",ka("below")),this._engines.set("near",ka("near")),this._engines.set("nth-match",oE);const e=[...this._engines.keys()];e.sort();const i=[...K0];if(i.sort(),e.join("|")!==i.join("|"))throw new Error(`Please keep customCSSNames in sync with evaluator engines: ${e.join("|")} vs ${i.join("|")}`)}begin(){++this._retainCacheCounter}end(){--this._retainCacheCounter,this._retainCacheCounter||(this._cacheQueryCSS.clear(),this._cacheMatches.clear(),this._cacheQuery.clear(),this._cacheMatchesSimple.clear(),this._cacheMatchesParents.clear(),this._cacheCallMatches.clear(),this._cacheCallQuery.clear(),this._cacheQuerySimple.clear(),this._cacheText.clear())}_cached(e,i,s,a){e.has(i)||e.set(i,[]);const o=e.get(i),u=o.find(d=>s.every((p,m)=>d.rest[m]===p));if(u)return u.result;const f=a();return o.push({rest:s,result:f}),f}_checkSelector(e){if(!(typeof e=="object"&&e&&(Array.isArray(e)||"simples"in e&&e.simples.length)))throw new Error(`Malformed selector "${e}"`);return e}matches(e,i,s){const a=this._checkSelector(i);this.begin();try{return this._cached(this._cacheMatches,e,[a,s.scope,s.pierceShadow,s.originalScope],()=>Array.isArray(a)?this._matchesEngine(Ba,e,a,s):(this._hasScopeClause(a)&&(s=this._expandContextForScopeMatching(s)),this._matchesSimple(e,a.simples[a.simples.length-1].selector,s)?this._matchesParents(e,a,a.simples.length-2,s):!1))}finally{this.end()}}query(e,i){const s=this._checkSelector(i);this.begin();try{return this._cached(this._cacheQuery,s,[e.scope,e.pierceShadow,e.originalScope],()=>{if(Array.isArray(s))return this._queryEngine(Ba,e,s);this._hasScopeClause(s)&&(e=this._expandContextForScopeMatching(e));const a=this._scoreMap;this._scoreMap=new Map;let o=this._querySimple(e,s.simples[s.simples.length-1].selector);return o=o.filter(u=>this._matchesParents(u,s,s.simples.length-2,e)),this._scoreMap.size&&o.sort((u,f)=>{const d=this._scoreMap.get(u),p=this._scoreMap.get(f);return d===p?0:d===void 0?1:p===void 0?-1:d-p}),this._scoreMap=a,o})}finally{this.end()}}_markScore(e,i){this._scoreMap&&this._scoreMap.set(e,i)}_hasScopeClause(e){return e.simples.some(i=>i.selector.functions.some(s=>s.name==="scope"))}_expandContextForScopeMatching(e){if(e.scope.nodeType!==1)return e;const i=yt(e.scope);return i?{...e,scope:i,originalScope:e.originalScope||e.scope}:e}_matchesSimple(e,i,s){return this._cached(this._cacheMatchesSimple,e,[i,s.scope,s.pierceShadow,s.originalScope],()=>{if(e===s.scope||i.css&&!this._matchesCSS(e,i.css))return!1;for(const a of i.functions)if(!this._matchesEngine(this._getEngine(a.name),e,a.args,s))return!1;return!0})}_querySimple(e,i){return i.functions.length?this._cached(this._cacheQuerySimple,i,[e.scope,e.pierceShadow,e.originalScope],()=>{let s=i.css;const a=i.functions;s==="*"&&a.length&&(s=void 0);let o,u=-1;s!==void 0?o=this._queryCSS(e,s):(u=a.findIndex(f=>this._getEngine(f.name).query!==void 0),u===-1&&(u=0),o=this._queryEngine(this._getEngine(a[u].name),e,a[u].args));for(let f=0;f<a.length;f++){if(f===u)continue;const d=this._getEngine(a[f].name);d.matches!==void 0&&(o=o.filter(p=>this._matchesEngine(d,p,a[f].args,e)))}for(let f=0;f<a.length;f++){if(f===u)continue;const d=this._getEngine(a[f].name);d.matches===void 0&&(o=o.filter(p=>this._matchesEngine(d,p,a[f].args,e)))}return o}):this._queryCSS(e,i.css||"*")}_matchesParents(e,i,s,a){return s<0?!0:this._cached(this._cacheMatchesParents,e,[i,s,a.scope,a.pierceShadow,a.originalScope],()=>{const{selector:o,combinator:u}=i.simples[s];if(u===">"){const f=So(e,a);return!f||!this._matchesSimple(f,o,a)?!1:this._matchesParents(f,i,s-1,a)}if(u==="+"){const f=Jf(e,a);return!f||!this._matchesSimple(f,o,a)?!1:this._matchesParents(f,i,s-1,a)}if(u===""){let f=So(e,a);for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="")break}f=So(f,a)}return!1}if(u==="~"){let f=Jf(e,a);for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="~")break}f=Jf(f,a)}return!1}if(u===">="){let f=e;for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="")break}f=So(f,a)}return!1}throw new Error(`Unsupported combinator "${u}"`)})}_matchesEngine(e,i,s,a){if(e.matches)return this._callMatches(e,i,s,a);if(e.query)return this._callQuery(e,s,a).includes(i);throw new Error('Selector engine should implement "matches" or "query"')}_queryEngine(e,i,s){if(e.query)return this._callQuery(e,s,i);if(e.matches)return this._queryCSS(i,"*").filter(a=>this._callMatches(e,a,s,i));throw new Error('Selector engine should implement "matches" or "query"')}_callMatches(e,i,s,a){return this._cached(this._cacheCallMatches,i,[e,a.scope,a.pierceShadow,a.originalScope,...s],()=>e.matches(i,s,a,this))}_callQuery(e,i,s){return this._cached(this._cacheCallQuery,e,[s.scope,s.pierceShadow,s.originalScope,...i],()=>e.query(s,i,this))}_matchesCSS(e,i){return e.matches(i)}_queryCSS(e,i){return this._cached(this._cacheQueryCSS,i,[e.scope,e.pierceShadow,e.originalScope],()=>{let s=[];function a(o){if(s=s.concat([...o.querySelectorAll(i)]),!!e.pierceShadow){o.shadowRoot&&a(o.shadowRoot);for(const u of o.querySelectorAll("*"))u.shadowRoot&&a(u.shadowRoot)}}return a(e.scope),s})}_getEngine(e){const i=this._engines.get(e);if(!i)throw new Error(`Unknown selector engine "${e}"`);return i}}const Ba={matches(n,e,i,s){if(e.length===0)throw new Error('"is" engine expects non-empty selector list');return e.some(a=>s.matches(n,a,i))},query(n,e,i){if(e.length===0)throw new Error('"is" engine expects non-empty selector list');let s=[];for(const a of e)s=s.concat(i.query(n,a));return e.length===1?s:Vb(s)}},WT={matches(n,e,i,s){if(e.length===0)throw new Error('"has" engine expects non-empty selector list');return s.query({...i,scope:n},e).length>0}},eE={matches(n,e,i,s){if(e.length!==0)throw new Error('"scope" engine expects no arguments');const a=i.originalScope||i.scope;return a.nodeType===9?n===a.documentElement:n===a},query(n,e,i){if(e.length!==0)throw new Error('"scope" engine expects no arguments');const s=n.originalScope||n.scope;if(s.nodeType===9){const a=s.documentElement;return a?[a]:[]}return s.nodeType===1?[s]:[]}},tE={matches(n,e,i,s){if(e.length===0)throw new Error('"not" engine expects non-empty selector list');return!s.matches(n,e,i)}},nE={query(n,e,i){return i.query({...n,pierceShadow:!1},e)},matches(n,e,i,s){return s.matches(n,e,{...i,pierceShadow:!1})}},iE={matches(n,e,i,s){if(e.length)throw new Error('"visible" engine expects no arguments');return vi(n)}},sE={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"text" engine expects a single string');const a=Tt(e[0]).toLowerCase(),o=u=>u.normalized.toLowerCase().includes(a);return cc(s._cacheText,n,o)==="self"}},rE={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"text-is" engine expects a single string');const a=Tt(e[0]),o=u=>!a&&!u.immediate.length?!0:u.immediate.some(f=>Tt(f)===a);return cc(s._cacheText,n,o)!=="none"}},aE={matches(n,e,i,s){if(e.length===0||typeof e[0]!="string"||e.length>2||e.length===2&&typeof e[1]!="string")throw new Error('"text-matches" engine expects a regexp body and optional regexp flags');const a=new RegExp(e[0],e.length===2?e[1]:void 0),o=u=>a.test(u.full);return cc(s._cacheText,n,o)==="self"}},lE={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"has-text" engine expects a single string');if(rd(n))return!1;const a=Tt(e[0]).toLowerCase();return(u=>u.normalized.toLowerCase().includes(a))(Bt(s._cacheText,n))}};function ka(n){return{matches(e,i,s,a){const o=i.length&&typeof i[i.length-1]=="number"?i[i.length-1]:void 0,u=o===void 0?i:i.slice(0,i.length-1);if(i.length<1+(o===void 0?0:1))throw new Error(`"${n}" engine expects a selector list and optional maximum distance in pixels`);const f=a.query(s,u),d=Db(n,e,f,o);return d===void 0?!1:(a._markScore(e,d),!0)}}}const oE={query(n,e,i){let s=e[e.length-1];if(e.length<2)throw new Error('"nth-match" engine expects non-empty selector list and an index argument');if(typeof s!="number"||s<1)throw new Error('"nth-match" engine expects a one-based index as the last argument');const a=Ba.query(n,e.slice(0,e.length-1),i);return s--,s<a.length?[a[s]]:[]}};function So(n,e){if(n!==e.scope)return e.pierceShadow?yt(n):n.parentElement||void 0}function Jf(n,e){if(n!==e.scope)return n.previousElementSibling||void 0}function Vb(n){const e=new Map,i=[],s=[];function a(u){let f=e.get(u);if(f)return f;const d=yt(u);return d?a(d).children.push(u):i.push(u),f={children:[],taken:!1},e.set(u,f),f}for(const u of n)a(u).taken=!0;function o(u){const f=e.get(u);if(f.taken&&s.push(u),f.children.length>1){const d=new Set(f.children);f.children=[];let p=u.firstElementChild;for(;p&&f.children.length<d.size;)d.has(p)&&f.children.push(p),p=p.nextElementSibling;for(p=u.shadowRoot?u.shadowRoot.firstElementChild:null;p&&f.children.length<d.size;)d.has(p)&&f.children.push(p),p=p.nextElementSibling}f.children.forEach(o)}return i.forEach(o),s}const Gb=10,mr=Gb/2,Wy=1,cE=2,uE=10,fE=50,Kb=100,Yb=120,Xb=140,Pb=160,Bo=180,Fb=200,e0=250,hE=Yb+mr,dE=Xb+mr,pE=Kb+mr,gE=Pb+mr,mE=Bo+mr,yE=Fb+mr,bE=300,vE=500,Qb=510,Wf=520,Zb=530,yh=1e4,SE=1e7,wE=1e3;function t0(n,e,i){n._evaluator.begin();const s={allowText:new Map,disallowText:new Map};lc(),Ih();try{let a=[];if(i.forTextExpect){let f=Ua(n,e.ownerDocument.documentElement,i);for(let d=e;d;d=yt(d)){const p=Gi(s,n,d,{...i,noText:!0});if(!p)continue;if(Ki(p)<=wE){f=p;break}}a=[Uo(f)]}else{if(!e.matches("input,textarea,select")&&!e.isContentEditable){const f=Da(e,"button,select,input,[role=button],[role=checkbox],[role=radio],a,[role=link]",i.root);f&&vi(f)&&(e=f)}if(i.multiple){const f=Gi(s,n,e,i),d=Gi(s,n,e,{...i,noText:!0});let p=[f,d];if(s.allowText.clear(),s.disallowText.clear(),f&&eh(f)&&p.push(Gi(s,n,e,{...i,noCSSId:!0})),d&&eh(d)&&p.push(Gi(s,n,e,{...i,noText:!0,noCSSId:!0})),p=p.filter(Boolean),!p.length){const m=Ua(n,e,i);p.push(m),eh(m)&&p.push(Ua(n,e,{...i,noCSSId:!0}))}a=[...new Set(p.map(m=>Uo(m)))]}else{const f=Gi(s,n,e,i)||Ua(n,e,i);a=[Uo(f)]}}const o=a[0],u=n.parseSelector(o);return{selector:o,selectors:a,elements:n.querySelectorAll(u,i.root??e.ownerDocument)}}finally{Vh(),oc(),n._evaluator.end()}}function Gi(n,e,i,s){if(s.root&&!Fa(s.root,i))throw new Error("Target element must belong to the root's subtree");if(i===s.root)return[{engine:"css",selector:":scope",score:1}];if(i.ownerDocument.documentElement===i)return[{engine:"css",selector:"html",score:1}];let a=null;const o=f=>{(!a||Ki(f)<Ki(a))&&(a=f)},u=[];if(!s.noText)for(const f of _E(e,i,!s.isRecursive))u.push({candidate:f,isTextCandidate:!0});for(const f of xE(e,i,s))s.omitInternalEngines&&f.engine.startsWith("internal:")||u.push({candidate:[f],isTextCandidate:!1});u.sort((f,d)=>Ki(f.candidate)-Ki(d.candidate));for(const{candidate:f,isTextCandidate:d}of u){const p=e.querySelectorAll(e.parseSelector(Uo(f)),s.root??i.ownerDocument);if(!p.includes(i))continue;if(p.length===1){o(f);break}const m=p.indexOf(i);if(!(m>5)&&(o([...f,{engine:"nth",selector:String(m),score:yh}]),!s.isRecursive))for(let y=yt(i);y&&y!==s.root;y=yt(y)){const b=p.filter(V=>Fa(y,V)&&V!==y),w=b.indexOf(i);if(b.length>5||w===-1||w===m&&b.length>1)continue;const E=b.length===1?f:[...f,{engine:"nth",selector:String(w),score:yh}];if(a&&Ki([{engine:"",selector:"",score:1},...E])>=Ki(a))continue;const _=!!s.noText||d,k=_?n.disallowText:n.allowText;let C=k.get(y);C===void 0&&(C=Gi(n,e,y,{...s,isRecursive:!0,noText:_})||Ua(e,y,s),k.set(y,C)),C&&o([...C,...E])}}return a}function xE(n,e,i){const s=[];{for(const u of["data-testid","data-test-id","data-test"])u!==i.testIdAttributeName&&e.getAttribute(u)&&s.push({engine:"css",selector:`[${u}=${Ws(e.getAttribute(u))}]`,score:cE});if(!i.noCSSId){const u=e.getAttribute("id");u&&!TE(u)&&s.push({engine:"css",selector:Jb(u),score:vE})}s.push({engine:"css",selector:Vn(e),score:Zb})}if(e.nodeName==="IFRAME"){for(const u of["name","title"])e.getAttribute(u)&&s.push({engine:"css",selector:`${Vn(e)}[${u}=${Ws(e.getAttribute(u))}]`,score:uE});return e.getAttribute(i.testIdAttributeName)&&s.push({engine:"css",selector:`[${i.testIdAttributeName}=${Ws(e.getAttribute(i.testIdAttributeName))}]`,score:Wy}),bh([s]),s}if(e.getAttribute(i.testIdAttributeName)&&s.push({engine:"internal:testid",selector:`[${i.testIdAttributeName}=${xt(e.getAttribute(i.testIdAttributeName),!0)}]`,score:Wy}),e.nodeName==="INPUT"||e.nodeName==="TEXTAREA"){const u=e;if(u.placeholder){s.push({engine:"internal:attr",selector:`[placeholder=${xt(u.placeholder,!0)}]`,score:hE});for(const f of nr(u.placeholder))s.push({engine:"internal:attr",selector:`[placeholder=${xt(f.text,!1)}]`,score:Yb-f.scoreBonus})}}const a=zb(n._evaluator._cacheText,e);for(const u of a){const f=u.normalized;s.push({engine:"internal:label",selector:Lt(f,!0),score:dE});for(const d of nr(f))s.push({engine:"internal:label",selector:Lt(d.text,!1),score:Xb-d.scoreBonus})}const o=ft(e);return o&&!["none","presentation"].includes(o)&&s.push({engine:"internal:role",selector:o,score:Qb}),e.getAttribute("name")&&["BUTTON","FORM","FIELDSET","FRAME","IFRAME","INPUT","KEYGEN","OBJECT","OUTPUT","SELECT","TEXTAREA","MAP","META","PARAM"].includes(e.nodeName)&&s.push({engine:"css",selector:`${Vn(e)}[name=${Ws(e.getAttribute("name"))}]`,score:Wf}),["INPUT","TEXTAREA"].includes(e.nodeName)&&e.getAttribute("type")!=="hidden"&&e.getAttribute("type")&&s.push({engine:"css",selector:`${Vn(e)}[type=${Ws(e.getAttribute("type"))}]`,score:Wf}),["INPUT","TEXTAREA","SELECT"].includes(e.nodeName)&&e.getAttribute("type")!=="hidden"&&s.push({engine:"css",selector:Vn(e),score:Wf+1}),bh([s]),s}function _E(n,e,i){if(e.nodeName==="SELECT")return[];const s=[],a=e.getAttribute("title");if(a){s.push([{engine:"internal:attr",selector:`[title=${xt(a,!0)}]`,score:yE}]);for(const p of nr(a))s.push([{engine:"internal:attr",selector:`[title=${xt(p.text,!1)}]`,score:Fb-p.scoreBonus}])}const o=e.getAttribute("alt");if(o&&["APPLET","AREA","IMG","INPUT"].includes(e.nodeName)){s.push([{engine:"internal:attr",selector:`[alt=${xt(o,!0)}]`,score:gE}]);for(const p of nr(o))s.push([{engine:"internal:attr",selector:`[alt=${xt(p.text,!1)}]`,score:Pb-p.scoreBonus}])}const u=Bt(n._evaluator._cacheText,e).normalized,f=u?nr(u):[];if(u){if(i){u.length<=80&&s.push([{engine:"internal:text",selector:Lt(u,!0),score:mE}]);for(const m of f)s.push([{engine:"internal:text",selector:Lt(m.text,!1),score:Bo-m.scoreBonus}])}const p={engine:"css",selector:Vn(e),score:Zb};for(const m of f)s.push([p,{engine:"internal:has-text",selector:Lt(m.text,!1),score:Bo-m.scoreBonus}]);if(i&&u.length<=80){const m=new RegExp("^"+Yo(u)+"$");s.push([p,{engine:"internal:has-text",selector:Lt(m,!1),score:e0}])}}const d=ft(e);if(d&&!["none","presentation"].includes(d)){const p=Qa(e,!1);if(p){const m={engine:"internal:role",selector:`${d}[name=${xt(p,!0)}]`,score:pE};s.push([m]);for(const y of nr(p))s.push([{engine:"internal:role",selector:`${d}[name=${xt(y.text,!1)}]`,score:Kb-y.scoreBonus}])}else{const m={engine:"internal:role",selector:`${d}`,score:Qb};for(const y of f)s.push([m,{engine:"internal:has-text",selector:Lt(y.text,!1),score:Bo-y.scoreBonus}]);if(i&&u.length<=80){const y=new RegExp("^"+Yo(u)+"$");s.push([m,{engine:"internal:has-text",selector:Lt(y,!1),score:e0}])}}}return bh(s),s}function Jb(n){return/^[a-zA-Z][a-zA-Z0-9\-\_]+$/.test(n)?"#"+n:`[id=${Ws(n)}]`}function eh(n){return n.some(e=>e.engine==="css"&&(e.selector.startsWith("#")||e.selector.startsWith('[id="')))}function Ua(n,e,i){const s=i.root??e.ownerDocument,a=[];function o(f){const d=a.slice();f&&d.unshift(f);const p=d.join(" > "),m=n.parseSelector(p);return n.querySelector(m,s,!1)===e?p:void 0}function u(f){const d={engine:"css",selector:f,score:SE},p=n.parseSelector(f),m=n.querySelectorAll(p,s);if(m.length===1)return[d];const y={engine:"nth",selector:String(m.indexOf(e)),score:yh};return[d,y]}for(let f=e;f&&f!==s;f=yt(f)){let d="";if(f.id&&!i.noCSSId){const y=Jb(f.id),b=o(y);if(b)return u(b);d=y}const p=f.parentNode,m=[...f.classList].map(EE);for(let y=0;y<m.length;++y){const b="."+m.slice(0,y+1).join("."),w=o(b);if(w)return u(w);!d&&p&&p.querySelectorAll(b).length===1&&(d=b)}if(p){const y=[...p.children],b=f.nodeName,E=y.filter(_=>_.nodeName===b).indexOf(f)===0?Vn(f):`${Vn(f)}:nth-child(${1+y.indexOf(f)})`,x=o(E);if(x)return u(x);d||(d=E)}else d||(d=Vn(f));a.unshift(d)}return u(o())}function bh(n){for(const e of n)for(const i of e)i.score>fE&&i.score<bE&&(i.score+=Math.min(Gb,i.selector.length/10|0))}function Uo(n){const e=[];let i="";for(const{engine:s,selector:a}of n)e.length&&(i!=="css"||s!=="css"||a.startsWith(":nth-match("))&&e.push(">>"),i=s,s==="css"?e.push(a):e.push(`${s}=${a}`);return e.join(" ")}function Ki(n){let e=0;for(let i=0;i<n.length;i++)e+=n[i].score*(n.length-i);return e}function TE(n){let e,i=0;for(let s=0;s<n.length;++s){const a=n[s];let o;if(!(a==="-"||a==="_")){if(a>="a"&&a<="z"?o="lower":a>="A"&&a<="Z"?o="upper":a>="0"&&a<="9"?o="digit":o="other",o==="lower"&&e==="upper"){e=o;continue}e&&e!==o&&++i,e=o}}return i>=n.length/4}function wo(n,e){if(n.length<=e)return n;n=n.substring(0,e);const i=n.match(/^(.*)\b(.+?)$/);return i?i[1].trimEnd():""}function nr(n){let e=[];{const i=n.match(/^([\d.,]+)[^.,\w]/),s=i?i[1].length:0;if(s){const a=wo(n.substring(s).trimStart(),80);e.push({text:a,scoreBonus:a.length<=30?2:1})}}{const i=n.match(/[^.,\w]([\d.,]+)$/),s=i?i[1].length:0;if(s){const a=wo(n.substring(0,n.length-s).trimEnd(),80);e.push({text:a,scoreBonus:a.length<=30?2:1})}}return n.length<=30?e.push({text:n,scoreBonus:0}):(e.push({text:wo(n,80),scoreBonus:0}),e.push({text:wo(n,30),scoreBonus:1})),e=e.filter(i=>i.text),e.length||e.push({text:n.substring(0,80),scoreBonus:0}),e}function Vn(n){return n.nodeName.toLocaleLowerCase().replace(/[:\.]/g,e=>"\\"+e)}function EE(n){let e="";for(let i=0;i<n.length;i++)e+=AE(n,i);return e}function AE(n,e){const i=n.charCodeAt(e);return i===0?"�":i>=1&&i<=31||i>=48&&i<=57&&(e===0||e===1&&n.charCodeAt(0)===45)?"\\"+i.toString(16)+" ":e===0&&i===45&&n.length===1?"\\"+n.charAt(e):i>=128||i===45||i===95||i>=48&&i<=57||i>=65&&i<=90||i>=97&&i<=122?n.charAt(e):"\\"+n.charAt(e)}function Wb(n,e){const i=n.replace(/^[a-zA-Z]:/,"").replace(/\\/g,"/");let s=i.substring(i.lastIndexOf("/")+1);return s.endsWith(e)&&(s=s.substring(0,s.length-e.length)),s}function NE(n,e){return e?e.toUpperCase():""}const CE=/(?:^|[-_/])(\w)/g,ev=n=>n&&n.replace(CE,NE);function kE(n){function e(m){const y=m.name||m._componentTag||m.__playwright_guessedName;if(y)return y;const b=m.__file;if(b)return ev(Wb(b,".vue"))}function i(m,y){return m.type.__playwright_guessedName=y,y}function s(m){var b,w,E,x;const y=e(m.type||{});if(y)return y;if(m.root===m)return"Root";for(const _ in(w=(b=m.parent)==null?void 0:b.type)==null?void 0:w.components)if(((E=m.parent)==null?void 0:E.type.components[_])===m.type)return i(m,_);for(const _ in(x=m.appContext)==null?void 0:x.components)if(m.appContext.components[_]===m.type)return i(m,_);return"Anonymous Component"}function a(m){return m._isBeingDestroyed||m.isUnmounted}function o(m){return m.subTree.type.toString()==="Symbol(Fragment)"}function u(m){const y=[];return m.component&&y.push(m.component),m.suspense&&y.push(...u(m.suspense.activeBranch)),Array.isArray(m.children)&&m.children.forEach(b=>{b.component?y.push(b.component):y.push(...u(b))}),y.filter(b=>{var w;return!a(b)&&!((w=b.type.devtools)!=null&&w.hide)})}function f(m){return o(m)?d(m.subTree):[m.subTree.el]}function d(m){if(!m.children)return[];const y=[];for(let b=0,w=m.children.length;b<w;b++){const E=m.children[b];E.component?y.push(...f(E.component)):E.el&&y.push(E.el)}return y}function p(m){return{name:s(m),children:u(m.subTree).map(p),rootElements:f(m),props:m.props}}return p(n)}function ME(n){function e(o){const u=o.displayName||o.name||o._componentTag;if(u)return u;const f=o.__file;if(f)return ev(Wb(f,".vue"))}function i(o){const u=e(o.$options||o.fnOptions||{});return u||(o.$root===o?"Root":"Anonymous Component")}function s(o){return o.$children?o.$children:Array.isArray(o.subTree.children)?o.subTree.children.filter(u=>!!u.component).map(u=>u.component):[]}function a(o){return{name:i(o),children:s(o).map(a),rootElements:[o.$el],props:o._props}}return a(n)}function tv(n,e,i=[]){e(n)&&i.push(n);for(const s of n.children)tv(s,e,i);return i}function nv(n,e=[]){const s=(n.ownerDocument||n).createTreeWalker(n,NodeFilter.SHOW_ELEMENT),a=new Set;do{const o=s.currentNode;o.__vue__&&a.add(o.__vue__.$root),o.__vue_app__&&o._vnode&&o._vnode.component&&e.push({root:o._vnode.component,version:3});const u=o instanceof Element?o.shadowRoot:null;u&&nv(u,e)}while(s.nextNode());for(const o of a)e.push({version:2,root:o});return e}const OE=()=>({queryAll(n,e){const i=n.ownerDocument||n,{name:s,attributes:a}=Ji(e,!1),f=nv(i).map(p=>p.version===3?kE(p.root):ME(p.root)).map(p=>tv(p,m=>{if(s&&m.name!==s||m.rootElements.some(y=>!Fa(n,y)))return!1;for(const y of a)if(!Bb(m.props,y))return!1;return!0})).flat(),d=new Set;for(const p of f)for(const m of p.rootElements)d.add(m);return[...d]}}),n0={queryAll(n,e){e.startsWith("/")&&n.nodeType!==Node.DOCUMENT_NODE&&(e="."+e);const i=[],s=n.ownerDocument||n;if(!s)return i;const a=s.evaluate(e,n,null,XPathResult.ORDERED_NODE_ITERATOR_TYPE);for(let o=a.iterateNext();o;o=a.iterateNext())o.nodeType===Node.ELEMENT_NODE&&i.push(o);return i}};function ad(n,e,i){return`internal:attr=[${n}=${xt(e,(i==null?void 0:i.exact)||!1)}]`}function RE(n,e){return`internal:testid=[${n}=${xt(e,!0)}]`}function jE(n,e){return"internal:label="+Lt(n,!!(e!=null&&e.exact))}function LE(n,e){return ad("alt",n,e)}function DE(n,e){return ad("title",n,e)}function BE(n,e){return ad("placeholder",n,e)}function UE(n,e){return"internal:text="+Lt(n,!!(e!=null&&e.exact))}function zE(n,e={}){const i=[];return e.checked!==void 0&&i.push(["checked",String(e.checked)]),e.disabled!==void 0&&i.push(["disabled",String(e.disabled)]),e.selected!==void 0&&i.push(["selected",String(e.selected)]),e.expanded!==void 0&&i.push(["expanded",String(e.expanded)]),e.includeHidden!==void 0&&i.push(["include-hidden",String(e.includeHidden)]),e.level!==void 0&&i.push(["level",String(e.level)]),e.name!==void 0&&i.push(["name",xt(e.name,!!e.exact)]),e.pressed!==void 0&&i.push(["pressed",String(e.pressed)]),`internal:role=${n}${i.map(([s,a])=>`[${s}=${a}]`).join("")}`}const Ma=Symbol("selector"),HE=class za{constructor(e,i,s){if(s!=null&&s.hasText&&(i+=` >> internal:has-text=${Lt(s.hasText,!1)}`),s!=null&&s.hasNotText&&(i+=` >> internal:has-not-text=${Lt(s.hasNotText,!1)}`),s!=null&&s.has&&(i+=" >> internal:has="+JSON.stringify(s.has[Ma])),s!=null&&s.hasNot&&(i+=" >> internal:has-not="+JSON.stringify(s.hasNot[Ma])),(s==null?void 0:s.visible)!==void 0&&(i+=` >> visible=${s.visible?"true":"false"}`),this[Ma]=i,i){const u=e.parseSelector(i);this.element=e.querySelector(u,e.document,!1),this.elements=e.querySelectorAll(u,e.document)}const a=i,o=this;o.locator=(u,f)=>new za(e,a?a+" >> "+u:u,f),o.getByTestId=u=>o.locator(RE(e.testIdAttributeNameForStrictErrorAndConsoleCodegen(),u)),o.getByAltText=(u,f)=>o.locator(LE(u,f)),o.getByLabel=(u,f)=>o.locator(jE(u,f)),o.getByPlaceholder=(u,f)=>o.locator(BE(u,f)),o.getByText=(u,f)=>o.locator(UE(u,f)),o.getByTitle=(u,f)=>o.locator(DE(u,f)),o.getByRole=(u,f={})=>o.locator(zE(u,f)),o.filter=u=>new za(e,i,u),o.first=()=>o.locator("nth=0"),o.last=()=>o.locator("nth=-1"),o.nth=u=>o.locator(`nth=${u}`),o.and=u=>new za(e,a+" >> internal:and="+JSON.stringify(u[Ma])),o.or=u=>new za(e,a+" >> internal:or="+JSON.stringify(u[Ma]))}};let qE=HE;class $E{constructor(e){this._injectedScript=e}install(){this._injectedScript.window.playwright||(this._injectedScript.window.playwright={$:(e,i)=>this._querySelector(e,!!i),$$:e=>this._querySelectorAll(e),inspect:e=>this._inspect(e),selector:e=>this._selector(e),generateLocator:(e,i)=>this._generateLocator(e,i),ariaSnapshot:(e,i)=>this._injectedScript.ariaSnapshot(e||this._injectedScript.document.body,i||{mode:"expect"}),resume:()=>this._resume(),...new qE(this._injectedScript,"")},delete this._injectedScript.window.playwright.filter,delete this._injectedScript.window.playwright.first,delete this._injectedScript.window.playwright.last,delete this._injectedScript.window.playwright.nth,delete this._injectedScript.window.playwright.and,delete this._injectedScript.window.playwright.or)}_querySelector(e,i){if(typeof e!="string")throw new Error("Usage: playwright.query('Playwright >> selector').");const s=this._injectedScript.parseSelector(e);return this._injectedScript.querySelector(s,this._injectedScript.document,i)}_querySelectorAll(e){if(typeof e!="string")throw new Error("Usage: playwright.$$('Playwright >> selector').");const i=this._injectedScript.parseSelector(e);return this._injectedScript.querySelectorAll(i,this._injectedScript.document)}_inspect(e){if(typeof e!="string")throw new Error("Usage: playwright.inspect('Playwright >> selector').");this._injectedScript.window.inspect(this._querySelector(e,!1))}_selector(e){if(!(e instanceof Element))throw new Error("Usage: playwright.selector(element).");return this._injectedScript.generateSelectorSimple(e)}_generateLocator(e,i){if(!(e instanceof Element))throw new Error("Usage: playwright.locator(element).");const s=this._injectedScript.generateSelectorSimple(e);return Wi(i||"javascript",s)}_resume(){if(!this._injectedScript.window.__pw_resume)return!1;this._injectedScript.window.__pw_resume().catch(()=>{})}}function IE(n){try{return n instanceof RegExp||Object.prototype.toString.call(n)==="[object RegExp]"}catch{return!1}}function VE(n){try{return n instanceof Date||Object.prototype.toString.call(n)==="[object Date]"}catch{return!1}}function GE(n){try{return n instanceof URL||Object.prototype.toString.call(n)==="[object URL]"}catch{return!1}}function KE(n){var e;try{return n instanceof Error||n&&((e=Object.getPrototypeOf(n))==null?void 0:e.name)==="Error"}catch{return!1}}function YE(n,e){try{return n instanceof e||Object.prototype.toString.call(n)===`[object ${e.name}]`}catch{return!1}}const iv={i8:Int8Array,ui8:Uint8Array,ui8c:Uint8ClampedArray,i16:Int16Array,ui16:Uint16Array,i32:Int32Array,ui32:Uint32Array,f32:Float32Array,f64:Float64Array,bi64:BigInt64Array,bui64:BigUint64Array};function XE(n){if("toBase64"in n)return n.toBase64();const e=Array.from(new Uint8Array(n.buffer,n.byteOffset,n.byteLength)).map(i=>String.fromCharCode(i)).join("");return btoa(e)}function PE(n,e){const i=atob(n),s=new Uint8Array(i.length);for(let a=0;a<i.length;a++)s[a]=i.charCodeAt(a);return new e(s.buffer)}function vh(n,e=[],i=new Map){if(!Object.is(n,void 0)){if(typeof n=="object"&&n){if("ref"in n)return i.get(n.ref);if("v"in n)return n.v==="undefined"?void 0:n.v==="null"?null:n.v==="NaN"?NaN:n.v==="Infinity"?1/0:n.v==="-Infinity"?-1/0:n.v==="-0"?-0:void 0;if("d"in n)return new Date(n.d);if("u"in n)return new URL(n.u);if("bi"in n)return BigInt(n.bi);if("e"in n){const s=new Error(n.e.m);return s.name=n.e.n,s.stack=n.e.s,s}if("r"in n)return new RegExp(n.r.p,n.r.f);if("a"in n){const s=[];i.set(n.id,s);for(const a of n.a)s.push(vh(a,e,i));return s}if("o"in n){const s={};i.set(n.id,s);for(const{k:a,v:o}of n.o)a!=="__proto__"&&(s[a]=vh(o,e,i));return s}if("h"in n)return e[n.h];if("ta"in n)return PE(n.ta.b,iv[n.ta.k])}return n}}function FE(n,e){return Sh(n,e,{visited:new Map,lastId:0})}function Sh(n,e,i){if(n&&typeof n=="object"){if(typeof globalThis.Window=="function"&&n instanceof globalThis.Window)return"ref: <Window>";if(typeof globalThis.Document=="function"&&n instanceof globalThis.Document)return"ref: <Document>";if(typeof globalThis.Node=="function"&&n instanceof globalThis.Node)return"ref: <Node>"}return sv(n,e,i)}function sv(n,e,i){var o;const s=e(n);if("fallThrough"in s)n=s.fallThrough;else return s;if(typeof n=="symbol")return{v:"undefined"};if(Object.is(n,void 0))return{v:"undefined"};if(Object.is(n,null))return{v:"null"};if(Object.is(n,NaN))return{v:"NaN"};if(Object.is(n,1/0))return{v:"Infinity"};if(Object.is(n,-1/0))return{v:"-Infinity"};if(Object.is(n,-0))return{v:"-0"};if(typeof n=="boolean"||typeof n=="number"||typeof n=="string")return n;if(typeof n=="bigint")return{bi:n.toString()};if(KE(n)){let u;return(o=n.stack)!=null&&o.startsWith(n.name+": "+n.message)?u=n.stack:u=`${n.name}: ${n.message}
|
|
116
|
+
${n.stack}`,{e:{n:n.name,m:n.message,s:u}}}if(VE(n))return{d:n.toJSON()};if(GE(n))return{u:n.toJSON()};if(IE(n))return{r:{p:n.source,f:n.flags}};for(const[u,f]of Object.entries(iv))if(YE(n,f))return{ta:{b:XE(n),k:u}};const a=i.visited.get(n);if(a)return{ref:a};if(Array.isArray(n)){const u=[],f=++i.lastId;i.visited.set(n,f);for(let d=0;d<n.length;++d)u.push(Sh(n[d],e,i));return{a:u,id:f}}if(typeof n=="object"){const u=[],f=++i.lastId;i.visited.set(n,f);for(const p of Object.keys(n)){let m;try{m=n[p]}catch{continue}p==="toJSON"&&typeof m=="function"?u.push({k:p,v:{o:[],id:0}}):u.push({k:p,v:Sh(m,e,i)})}let d;try{u.length===0&&n.toJSON&&typeof n.toJSON=="function"&&(d={value:n.toJSON()})}catch{}return d?sv(d.value,e,i):{o:u,id:f}}}class QE{constructor(e,i){var s,a,o,u,f,d,p,m;this.global=e,this.isUnderTest=i,e.__pwClock?this.builtins=e.__pwClock.builtins:this.builtins={setTimeout:(s=e.setTimeout)==null?void 0:s.bind(e),clearTimeout:(a=e.clearTimeout)==null?void 0:a.bind(e),setInterval:(o=e.setInterval)==null?void 0:o.bind(e),clearInterval:(u=e.clearInterval)==null?void 0:u.bind(e),requestAnimationFrame:(f=e.requestAnimationFrame)==null?void 0:f.bind(e),cancelAnimationFrame:(d=e.cancelAnimationFrame)==null?void 0:d.bind(e),requestIdleCallback:(p=e.requestIdleCallback)==null?void 0:p.bind(e),cancelIdleCallback:(m=e.cancelIdleCallback)==null?void 0:m.bind(e),performance:e.performance,Intl:e.Intl,Date:e.Date},this.isUnderTest&&(e.builtins=this.builtins)}evaluate(e,i,s,a,...o){const u=o.slice(0,a),f=o.slice(a),d=[];for(let m=0;m<u.length;m++)d[m]=vh(u[m],f);let p=this.global.eval(s);return e===!0?p=p(...d):e===!1?p=p:typeof p=="function"&&(p=p(...d)),i?this._promiseAwareJsonValueNoThrow(p):p}jsonValue(e,i){if(i!==void 0)return FE(i,s=>({fallThrough:s}))}_promiseAwareJsonValueNoThrow(e){const i=s=>{try{return this.jsonValue(!0,s)}catch{return}};return e&&typeof e=="object"&&typeof e.then=="function"?(async()=>{const s=await e;return i(s)})():i(e)}}class rv{constructor(e,i){this._testIdAttributeNameForStrictErrorAndConsoleCodegen="data-testid",this._lastAriaSnapshotForTrack=new Map,this.utils={asLocator:Wi,cacheNormalizedWhitespaces:wx,elementText:Bt,getAriaRole:ft,getElementAccessibleDescription:Gy,getElementAccessibleName:Qa,isElementVisible:vi,isInsideScope:Fa,normalizeWhiteSpace:Tt,parseAriaSnapshot:zh,generateAriaTree:Va,builtins:null},this.window=e,this.document=e.document,this.isUnderTest=i.isUnderTest,this.utils.builtins=new QE(e,i.isUnderTest).builtins,this._sdkLanguage=i.sdkLanguage,this._testIdAttributeNameForStrictErrorAndConsoleCodegen=i.testIdAttributeName,this._evaluator=new JT,this.consoleApi=new $E(this),this.onGlobalListenersRemoved=new Set,this._autoClosingTags=new Set(["AREA","BASE","BR","COL","COMMAND","EMBED","HR","IMG","INPUT","KEYGEN","LINK","MENUITEM","META","PARAM","SOURCE","TRACK","WBR"]),this._booleanAttributes=new Set(["checked","selected","disabled","readonly","multiple"]),this._eventTypes=new Map([["auxclick","mouse"],["click","mouse"],["dblclick","mouse"],["mousedown","mouse"],["mouseeenter","mouse"],["mouseleave","mouse"],["mousemove","mouse"],["mouseout","mouse"],["mouseover","mouse"],["mouseup","mouse"],["mouseleave","mouse"],["mousewheel","mouse"],["keydown","keyboard"],["keyup","keyboard"],["keypress","keyboard"],["textInput","keyboard"],["touchstart","touch"],["touchmove","touch"],["touchend","touch"],["touchcancel","touch"],["pointerover","pointer"],["pointerout","pointer"],["pointerenter","pointer"],["pointerleave","pointer"],["pointerdown","pointer"],["pointerup","pointer"],["pointermove","pointer"],["pointercancel","pointer"],["gotpointercapture","pointer"],["lostpointercapture","pointer"],["focus","focus"],["blur","focus"],["drag","drag"],["dragstart","drag"],["dragend","drag"],["dragover","drag"],["dragenter","drag"],["dragleave","drag"],["dragexit","drag"],["drop","drag"],["wheel","wheel"],["deviceorientation","deviceorientation"],["deviceorientationabsolute","deviceorientation"],["devicemotion","devicemotion"]]),this._hoverHitTargetInterceptorEvents=new Set(["mousemove"]),this._tapHitTargetInterceptorEvents=new Set(["pointerdown","pointerup","touchstart","touchend","touchcancel"]),this._mouseHitTargetInterceptorEvents=new Set(["mousedown","mouseup","pointerdown","pointerup","click","auxclick","dblclick","contextmenu"]),this._allHitTargetInterceptorEvents=new Set([...this._hoverHitTargetInterceptorEvents,...this._tapHitTargetInterceptorEvents,...this._mouseHitTargetInterceptorEvents]),this._engines=new Map,this._engines.set("xpath",n0),this._engines.set("xpath:light",n0),this._engines.set("_react",FT()),this._engines.set("_vue",OE()),this._engines.set("role",Jy(!1)),this._engines.set("text",this._createTextEngine(!0,!1)),this._engines.set("text:light",this._createTextEngine(!1,!1)),this._engines.set("id",this._createAttributeEngine("id",!0)),this._engines.set("id:light",this._createAttributeEngine("id",!1)),this._engines.set("data-testid",this._createAttributeEngine("data-testid",!0)),this._engines.set("data-testid:light",this._createAttributeEngine("data-testid",!1)),this._engines.set("data-test-id",this._createAttributeEngine("data-test-id",!0)),this._engines.set("data-test-id:light",this._createAttributeEngine("data-test-id",!1)),this._engines.set("data-test",this._createAttributeEngine("data-test",!0)),this._engines.set("data-test:light",this._createAttributeEngine("data-test",!1)),this._engines.set("css",this._createCSSEngine()),this._engines.set("nth",{queryAll:()=>[]}),this._engines.set("visible",this._createVisibleEngine()),this._engines.set("internal:control",this._createControlEngine()),this._engines.set("internal:has",this._createHasEngine()),this._engines.set("internal:has-not",this._createHasNotEngine()),this._engines.set("internal:and",{queryAll:()=>[]}),this._engines.set("internal:or",{queryAll:()=>[]}),this._engines.set("internal:chain",this._createInternalChainEngine()),this._engines.set("internal:label",this._createInternalLabelEngine()),this._engines.set("internal:text",this._createTextEngine(!0,!0)),this._engines.set("internal:has-text",this._createInternalHasTextEngine()),this._engines.set("internal:has-not-text",this._createInternalHasNotTextEngine()),this._engines.set("internal:attr",this._createNamedAttributeEngine()),this._engines.set("internal:testid",this._createNamedAttributeEngine()),this._engines.set("internal:role",Jy(!0)),this._engines.set("internal:describe",this._createDescribeEngine()),this._engines.set("aria-ref",this._createAriaRefEngine());for(const{name:s,source:a}of i.customEngines)this._engines.set(s,this.eval(a));this._stableRafCount=i.stableRafCount,this._browserName=i.browserName,this._isUtilityWorld=!!i.isUtilityWorld,lT({browserNameForWorkarounds:i.browserName}),this._setupGlobalListenersRemovalDetection(),this._setupHitTargetInterceptors(),this.isUnderTest&&(this.window.__injectedScript=this)}eval(e){return this.window.eval(e)}testIdAttributeNameForStrictErrorAndConsoleCodegen(){return this._testIdAttributeNameForStrictErrorAndConsoleCodegen}parseSelector(e){const i=tl(e);return vx(i,s=>{if(!this._engines.has(s.name))throw this.createStacklessError(`Unknown engine "${s.name}" while parsing selector ${e}`)}),i}generateSelector(e,i){return t0(this,e,i)}generateSelectorSimple(e,i){return t0(this,e,{...i,testIdAttributeName:this._testIdAttributeNameForStrictErrorAndConsoleCodegen}).selector}querySelector(e,i,s){const a=this.querySelectorAll(e,i);if(s&&a.length>1)throw this.strictModeViolationError(e,a);return a[0]}_queryNth(e,i){const s=[...e];let a=+i.body;return a===-1&&(a=s.length-1),new Set(s.slice(a,a+1))}_queryLayoutSelector(e,i,s){const a=i.name,o=i.body,u=[],f=this.querySelectorAll(o.parsed,s);for(const d of e){const p=Db(a,d,f,o.distance);p!==void 0&&u.push({element:d,score:p})}return u.sort((d,p)=>d.score-p.score),new Set(u.map(d=>d.element))}ariaSnapshot(e,i){if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Can only capture aria snapshot of Element nodes.");const s=Va(e,i);let a;i.incremental&&(a=i.track?this._lastAriaSnapshotForTrack.get(i.track):void 0);const o=Jo(s,i,a);return i.track&&this._lastAriaSnapshotForTrack.set(i.track,s),this._lastAriaSnapshotForQuery=s,o}ariaSnapshotForRecorder(){const e=Va(this.document.body,{mode:"ai"});return{ariaSnapshot:Jo(e,{mode:"ai"}),refs:e.refs}}getAllElementsMatchingExpectAriaTemplate(e,i){return DT(e.documentElement,i)}querySelectorAll(e,i){if(e.capture!==void 0){if(e.parts.some(a=>a.name==="nth"))throw this.createStacklessError("Can't query n-th element in a request with the capture.");const s={parts:e.parts.slice(0,e.capture+1)};if(e.capture<e.parts.length-1){const a={parts:e.parts.slice(e.capture+1)},o={name:"internal:has",body:{parsed:a},source:Gn(a)};s.parts.push(o)}return this.querySelectorAll(s,i)}if(!i.querySelectorAll)throw this.createStacklessError("Node is not queryable.");if(e.capture!==void 0)throw this.createStacklessError("Internal error: there should not be a capture in the selector.");if(i.nodeType===11&&e.parts.length===1&&e.parts[0].name==="css"&&e.parts[0].source===":scope")return[i];this._evaluator.begin();try{let s=new Set([i]);for(const a of e.parts)if(a.name==="nth")s=this._queryNth(s,a);else if(a.name==="internal:and"){const o=this.querySelectorAll(a.body.parsed,i);s=new Set(o.filter(u=>s.has(u)))}else if(a.name==="internal:or"){const o=this.querySelectorAll(a.body.parsed,i);s=new Set(Vb(new Set([...s,...o])))}else if(GT.includes(a.name))s=this._queryLayoutSelector(s,a,i);else{const o=new Set;for(const u of s){const f=this._queryEngineAll(a,u);for(const d of f)o.add(d)}s=o}return[...s]}finally{this._evaluator.end()}}_queryEngineAll(e,i){const s=this._engines.get(e.name).queryAll(i,e.body);for(const a of s)if(!("nodeName"in a))throw this.createStacklessError(`Expected a Node but got ${Object.prototype.toString.call(a)}`);return s}_createAttributeEngine(e,i){const s=a=>[{simples:[{selector:{css:`[${e}=${JSON.stringify(a)}]`,functions:[]},combinator:""}]}];return{queryAll:(a,o)=>this._evaluator.query({scope:a,pierceShadow:i},s(o))}}_createCSSEngine(){return{queryAll:(e,i)=>this._evaluator.query({scope:e,pierceShadow:!0},i)}}_createTextEngine(e,i){return{queryAll:(a,o)=>{const{matcher:u,kind:f}=_o(o,i),d=[];let p=null;const m=b=>{if(f==="lax"&&p&&p.contains(b))return!1;const w=cc(this._evaluator._cacheText,b,u);w==="none"&&(p=b),(w==="self"||w==="selfAndChildren"&&f==="strict"&&!i)&&d.push(b)};a.nodeType===Node.ELEMENT_NODE&&m(a);const y=this._evaluator._queryCSS({scope:a,pierceShadow:e},"*");for(const b of y)m(b);return d}}}_createInternalHasTextEngine(){return{queryAll:(e,i)=>{if(e.nodeType!==1)return[];const s=e,a=Bt(this._evaluator._cacheText,s),{matcher:o}=_o(i,!0);return o(a)?[s]:[]}}}_createInternalHasNotTextEngine(){return{queryAll:(e,i)=>{if(e.nodeType!==1)return[];const s=e,a=Bt(this._evaluator._cacheText,s),{matcher:o}=_o(i,!0);return o(a)?[]:[s]}}}_createInternalLabelEngine(){return{queryAll:(e,i)=>{const{matcher:s}=_o(i,!0);return this._evaluator._queryCSS({scope:e,pierceShadow:!0},"*").filter(o=>zb(this._evaluator._cacheText,o).some(u=>s(u)))}}}_createNamedAttributeEngine(){return{queryAll:(i,s)=>{const a=Ji(s,!0);if(a.name||a.attributes.length!==1)throw new Error("Malformed attribute selector: "+s);const{name:o,value:u,caseSensitive:f}=a.attributes[0],d=f?null:u.toLowerCase();let p;return u instanceof RegExp?p=y=>!!y.match(u):f?p=y=>y===u:p=y=>y.toLowerCase().includes(d),this._evaluator._queryCSS({scope:i,pierceShadow:!0},`[${o}]`).filter(y=>p(y.getAttribute(o)))}}}_createDescribeEngine(){return{queryAll:i=>i.nodeType!==1?[]:[i]}}_createControlEngine(){return{queryAll(e,i){if(i==="enter-frame")return[];if(i==="return-empty")return[];if(i==="component")return e.nodeType!==1?[]:[e.childElementCount===1?e.firstElementChild:e];throw new Error(`Internal error, unknown internal:control selector ${i}`)}}}_createHasEngine(){return{queryAll:(i,s)=>i.nodeType!==1?[]:!!this.querySelector(s.parsed,i,!1)?[i]:[]}}_createHasNotEngine(){return{queryAll:(i,s)=>i.nodeType!==1?[]:!!this.querySelector(s.parsed,i,!1)?[]:[i]}}_createVisibleEngine(){return{queryAll:(i,s)=>{if(i.nodeType!==1)return[];const a=s==="true";return vi(i)===a?[i]:[]}}}_createInternalChainEngine(){return{queryAll:(i,s)=>this.querySelectorAll(s.parsed,i)}}extend(e,i){const s=this.window.eval(`
|
|
117
117
|
(() => {
|
|
118
118
|
const module = {};
|
|
119
119
|
${e}
|
|
120
120
|
return module.exports.default();
|
|
121
|
-
})()`);return new s(this,i)}async viewportRatio(e){return await new Promise(i=>{const s=new IntersectionObserver(a=>{i(a[0].intersectionRatio),s.disconnect()});s.observe(e),this.utils.builtins.requestAnimationFrame(()=>{})})}getElementBorderWidth(e){if(e.nodeType!==Node.ELEMENT_NODE||!e.ownerDocument||!e.ownerDocument.defaultView)return{left:0,top:0};const i=e.ownerDocument.defaultView.getComputedStyle(e);return{left:parseInt(i.borderLeftWidth||"",10),top:parseInt(i.borderTopWidth||"",10)}}describeIFrameStyle(e){if(!e.ownerDocument||!e.ownerDocument.defaultView)return"error:notconnected";const i=e.ownerDocument.defaultView;for(let a=e;a;a=yt(a))if(i.getComputedStyle(a).transform!=="none")return"transformed";const s=i.getComputedStyle(e);return{left:parseInt(s.borderLeftWidth||"",10)+parseInt(s.paddingLeft||"",10),top:parseInt(s.borderTopWidth||"",10)+parseInt(s.paddingTop||"",10)}}retarget(e,i){let s=e.nodeType===Node.ELEMENT_NODE?e:e.parentElement;if(!s)return null;if(i==="none")return s;if(!s.matches("input, textarea, select")&&!s.isContentEditable&&(i==="button-link"?s=s.closest("button, [role=button], a, [role=link]")||s:s=s.closest("button, [role=button], [role=checkbox], [role=radio]")||s),i==="follow-label"&&!s.matches("a, input, textarea, button, select, [role=link], [role=button], [role=checkbox], [role=radio]")&&!s.isContentEditable){const a=s.closest("label");a&&a.control&&(s=a.control)}return s}async checkElementStates(e,i){if(i.includes("stable")){const s=await this._checkElementIsStable(e);if(s===!1)return{missingState:"stable"};if(s==="error:notconnected")return"error:notconnected"}for(const s of i)if(s!=="stable"){const a=this.elementState(e,s);if(a.received==="error:notconnected")return"error:notconnected";if(!a.matches)return{missingState:s}}}async _checkElementIsStable(e){const i=Symbol("continuePolling");let s,a=0,o=0;const u=()=>{const y=this.retarget(e,"no-follow-label");if(!y)return"error:notconnected";const b=this.utils.builtins.performance.now();if(this._stableRafCount>1&&b-o<15)return i;o=b;const w=y.getBoundingClientRect(),E={x:w.top,y:w.left,width:w.width,height:w.height};if(s){if(!(E.x===s.x&&E.y===s.y&&E.width===s.width&&E.height===s.height))return!1;if(++a>=this._stableRafCount)return!0}return s=E,i};let f,d;const p=new Promise((y,b)=>{f=y,d=b}),m=()=>{try{const y=u();y!==i?f(y):this.utils.builtins.requestAnimationFrame(m)}catch(y){d(y)}};return this.utils.builtins.requestAnimationFrame(m),p}_createAriaRefEngine(){return{queryAll:(i,s)=>{var o,u;const a=(u=(o=this._lastAriaSnapshotForQuery)==null?void 0:o.elements)==null?void 0:u.get(s);return a&&a.isConnected?[a]:[]}}}elementState(e,i){const s=this.retarget(e,["visible","hidden"].includes(i)?"none":"follow-label");if(!s||!s.isConnected)return i==="hidden"?{matches:!0,received:"hidden"}:{matches:!1,received:"error:notconnected"};if(i==="visible"||i==="hidden"){const a=vi(s);return{matches:i==="visible"?a:!a,received:a?"visible":"hidden"}}if(i==="disabled"||i==="enabled"){const a=Zo(s);return{matches:i==="disabled"?a:!a,received:a?"disabled":"enabled"}}if(i==="editable"){const a=Zo(s),o=wT(s);if(o==="error")throw this.createStacklessError("Element is not an <input>, <textarea>, <select> or [contenteditable] and does not have a role allowing [aria-readonly]");return{matches:!a&&!o,received:a?"disabled":o?"readOnly":"editable"}}if(i==="checked"||i==="unchecked"){const a=i==="checked",o=vT(s);if(o==="error")throw this.createStacklessError("Not a checkbox or radio button");const u=s.nodeName==="INPUT"&&s.type==="radio";return{matches:a===o,received:o?"checked":"unchecked",isRadio:u}}if(i==="indeterminate"){const a=bT(s);if(a==="error")throw this.createStacklessError("Not a checkbox or radio button");return{matches:a==="mixed",received:a===!0?"checked":a===!1?"unchecked":"mixed"}}throw this.createStacklessError(`Unexpected element state "${i}"`)}selectOptions(e,i){const s=this.retarget(e,"follow-label");if(!s)return"error:notconnected";if(s.nodeName.toLowerCase()!=="select")throw this.createStacklessError("Element is not a <select> element");const a=s,o=[...a.options],u=[];let f=i.slice();for(let d=0;d<o.length;d++){const p=o[d],m=y=>{if(y instanceof Node)return p===y;let b=!0;return y.valueOrLabel!==void 0&&(b=b&&(y.valueOrLabel===p.value||y.valueOrLabel===p.label)),y.value!==void 0&&(b=b&&y.value===p.value),y.label!==void 0&&(b=b&&y.label===p.label),y.index!==void 0&&(b=b&&y.index===d),b};if(f.some(m)){if(!this.elementState(p,"enabled").matches)return"error:optionnotenabled";if(u.push(p),a.multiple)f=f.filter(y=>!m(y));else{f=[];break}}}return f.length?"error:optionsnotfound":(a.value=void 0,u.forEach(d=>d.selected=!0),a.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),a.dispatchEvent(new Event("change",{bubbles:!0})),u.map(d=>d.value))}fill(e,i){const s=this.retarget(e,"follow-label");if(!s)return"error:notconnected";if(s.nodeName.toLowerCase()==="input"){const a=s,o=a.type.toLowerCase(),u=new Set(["color","date","time","datetime-local","month","range","week"]);if(!new Set(["","email","number","password","search","tel","text","url"]).has(o)&&!u.has(o))throw this.createStacklessError(`Input of type "${o}" cannot be filled`);if(o==="number"&&(i=i.trim(),isNaN(Number(i))))throw this.createStacklessError("Cannot type text into input[type=number]");if(u.has(o)){if(i=i.trim(),a.focus(),a.value=i,a.value!==i)throw this.createStacklessError("Malformed value");return s.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),s.dispatchEvent(new Event("change",{bubbles:!0})),"done"}}else if(s.nodeName.toLowerCase()!=="textarea"){if(!s.isContentEditable)throw this.createStacklessError("Element is not an <input>, <textarea> or [contenteditable] element")}return this.selectText(s),"needsinput"}selectText(e){const i=this.retarget(e,"follow-label");if(!i)return"error:notconnected";if(i.nodeName.toLowerCase()==="input"){const o=i;return o.select(),o.focus(),"done"}if(i.nodeName.toLowerCase()==="textarea"){const o=i;return o.selectionStart=0,o.selectionEnd=o.value.length,o.focus(),"done"}const s=i.ownerDocument.createRange();s.selectNodeContents(i);const a=i.ownerDocument.defaultView.getSelection();return a&&(a.removeAllRanges(),a.addRange(s)),i.focus(),"done"}_activelyFocused(e){const i=e.getRootNode().activeElement,s=i===e&&!!e.ownerDocument&&e.ownerDocument.hasFocus();return{activeElement:i,isFocused:s}}focusNode(e,i){if(!e.isConnected)return"error:notconnected";if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Node is not an element");const{activeElement:s,isFocused:a}=this._activelyFocused(e);if(e.isContentEditable&&!a&&s&&s.blur&&s.blur(),e.focus(),e.focus(),i&&!a&&e.nodeName.toLowerCase()==="input")try{e.setSelectionRange(0,0)}catch{}return"done"}blurNode(e){if(!e.isConnected)return"error:notconnected";if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Node is not an element");return e.blur(),"done"}setInputFiles(e,i){if(e.nodeType!==Node.ELEMENT_NODE)return"Node is not of type HTMLElement";const s=e;if(s.nodeName!=="INPUT")return"Not an <input> element";const a=s;if((a.getAttribute("type")||"").toLowerCase()!=="file")return"Not an input[type=file] element";const u=i.map(d=>{const p=Uint8Array.from(atob(d.buffer),m=>m.charCodeAt(0));return new File([p],d.name,{type:d.mimeType,lastModified:d.lastModifiedMs})}),f=new DataTransfer;for(const d of u)f.items.add(d);a.files=f.files,a.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),a.dispatchEvent(new Event("change",{bubbles:!0}))}expectHitTarget(e,i){const s=[];let a=i;for(;a;){const m=cb(a);if(!m||(s.push(m),m.nodeType===9))break;a=m.host}let o;for(let m=s.length-1;m>=0;m--){const y=s[m],b=y.elementsFromPoint(e.x,e.y),w=y.elementFromPoint(e.x,e.y);if(w&&b[0]&&yt(w)===b[0]){const x=this.window.getComputedStyle(w);(x==null?void 0:x.display)==="contents"&&b.unshift(w)}b[0]&&b[0].shadowRoot===y&&b[1]===w&&b.shift();const E=b[0];if(!E||(o=E,m&&E!==s[m-1].host))break}const u=[];for(;o&&o!==i;)u.push(o),o=o.assignedSlot??yt(o);if(o===i)return"done";const f=this.previewNode(u[0]||this.document.documentElement);let d,p=i;for(;p;){const m=u.indexOf(p);if(m!==-1){m>1&&(d=this.previewNode(u[m-1]));break}p=yt(p)}return d?{hitTargetDescription:`${f} from ${d} subtree`}:{hitTargetDescription:f}}setupHitTargetInterceptor(e,i,s,a){const o=this.retarget(e,"button-link");if(!o||!o.isConnected)return"error:notconnected";if(s){const m=this.expectHitTarget(s,o);if(m!=="done")return m.hitTargetDescription}if(i==="drag")return{stop:()=>"done"};const u={hover:this._hoverHitTargetInterceptorEvents,tap:this._tapHitTargetInterceptorEvents,mouse:this._mouseHitTargetInterceptorEvents}[i];let f;const d=m=>{if(!u.has(m.type)||!m.isTrusted)return;const y=this.window.TouchEvent&&m instanceof this.window.TouchEvent?m.touches[0]:m;f===void 0&&y&&(f=this.expectHitTarget({x:y.clientX,y:y.clientY},o)),(a||f!=="done"&&f!==void 0)&&(m.preventDefault(),m.stopPropagation(),m.stopImmediatePropagation())},p=()=>(this._hitTargetInterceptor===d&&(this._hitTargetInterceptor=void 0),f||"done");return this._hitTargetInterceptor=d,{stop:p}}dispatchEvent(e,i,s){var u,f,d;let a;const o={bubbles:!0,cancelable:!0,composed:!0,...s};switch(this._eventTypes.get(i)){case"mouse":a=new MouseEvent(i,o);break;case"keyboard":a=new KeyboardEvent(i,o);break;case"touch":{if(this._browserName==="webkit"){const p=y=>{var E,x;if(y instanceof Touch)return y;let b=y.pageX;b===void 0&&y.clientX!==void 0&&(b=y.clientX+(((E=this.document.scrollingElement)==null?void 0:E.scrollLeft)||0));let w=y.pageY;return w===void 0&&y.clientY!==void 0&&(w=y.clientY+(((x=this.document.scrollingElement)==null?void 0:x.scrollTop)||0)),this.document.createTouch(this.window,y.target??e,y.identifier,b,w,y.screenX,y.screenY,y.radiusX,y.radiusY,y.rotationAngle,y.force)},m=y=>y instanceof TouchList||!y?y:this.document.createTouchList(...y.map(p));o.target??(o.target=e),o.touches=m(o.touches),o.targetTouches=m(o.targetTouches),o.changedTouches=m(o.changedTouches),a=new TouchEvent(i,o)}else o.target??(o.target=e),o.touches=(u=o.touches)==null?void 0:u.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),o.targetTouches=(f=o.targetTouches)==null?void 0:f.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),o.changedTouches=(d=o.changedTouches)==null?void 0:d.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),a=new TouchEvent(i,o);break}case"pointer":a=new PointerEvent(i,o);break;case"focus":a=new FocusEvent(i,o);break;case"drag":a=new DragEvent(i,o);break;case"wheel":a=new WheelEvent(i,o);break;case"deviceorientation":try{a=new DeviceOrientationEvent(i,o)}catch{const{bubbles:p,cancelable:m,alpha:y,beta:b,gamma:w,absolute:E}=o;a=this.document.createEvent("DeviceOrientationEvent"),a.initDeviceOrientationEvent(i,p,m,y,b,w,E)}break;case"devicemotion":try{a=new DeviceMotionEvent(i,o)}catch{const{bubbles:p,cancelable:m,acceleration:y,accelerationIncludingGravity:b,rotationRate:w,interval:E}=o;a=this.document.createEvent("DeviceMotionEvent"),a.initDeviceMotionEvent(i,p,m,y,b,w,E)}break;default:a=new Event(i,o);break}e.dispatchEvent(a)}previewNode(e){if(e.nodeType===Node.TEXT_NODE)return xo(`#text=${e.nodeValue||""}`);if(e.nodeType!==Node.ELEMENT_NODE)return xo(`<${e.nodeName.toLowerCase()} />`);const i=e,s=[];for(let d=0;d<i.attributes.length;d++){const{name:p,value:m}=i.attributes[d];p!=="style"&&(!m&&this._booleanAttributes.has(p)?s.push(` ${p}`):s.push(` ${p}="${m}"`))}s.sort((d,p)=>d.length-p.length);const a=ky(s.join(""),500);if(this._autoClosingTags.has(i.nodeName))return xo(`<${i.nodeName.toLowerCase()}${a}/>`);const o=i.childNodes;let u=!1;if(o.length<=5){u=!0;for(let d=0;d<o.length;d++)u=u&&o[d].nodeType===Node.TEXT_NODE}const f=u?i.textContent||"":o.length?"…":"";return xo(`<${i.nodeName.toLowerCase()}${a}>${ky(f,50)}</${i.nodeName.toLowerCase()}>`)}strictModeViolationError(e,i){this._evaluator.begin(),lc(),Ih();try{const s=this._isUtilityWorld&&this._browserName==="firefox"?2:10,a=i.slice(0,s).map(u=>({preview:this.previewNode(u),selector:this.generateSelectorSimple(u)})),o=a.map((u,f)=>`
|
|
121
|
+
})()`);return new s(this,i)}async viewportRatio(e){return await new Promise(i=>{const s=new IntersectionObserver(a=>{i(a[0].intersectionRatio),s.disconnect()});s.observe(e),this.utils.builtins.requestAnimationFrame(()=>{})})}getElementBorderWidth(e){if(e.nodeType!==Node.ELEMENT_NODE||!e.ownerDocument||!e.ownerDocument.defaultView)return{left:0,top:0};const i=e.ownerDocument.defaultView.getComputedStyle(e);return{left:parseInt(i.borderLeftWidth||"",10),top:parseInt(i.borderTopWidth||"",10)}}describeIFrameStyle(e){if(!e.ownerDocument||!e.ownerDocument.defaultView)return"error:notconnected";const i=e.ownerDocument.defaultView;for(let a=e;a;a=yt(a))if(i.getComputedStyle(a).transform!=="none")return"transformed";const s=i.getComputedStyle(e);return{left:parseInt(s.borderLeftWidth||"",10)+parseInt(s.paddingLeft||"",10),top:parseInt(s.borderTopWidth||"",10)+parseInt(s.paddingTop||"",10)}}retarget(e,i){let s=e.nodeType===Node.ELEMENT_NODE?e:e.parentElement;if(!s)return null;if(i==="none")return s;if(!s.matches("input, textarea, select")&&!s.isContentEditable&&(i==="button-link"?s=s.closest("button, [role=button], a, [role=link]")||s:s=s.closest("button, [role=button], [role=checkbox], [role=radio]")||s),i==="follow-label"&&!s.matches("a, input, textarea, button, select, [role=link], [role=button], [role=checkbox], [role=radio]")&&!s.isContentEditable){const a=s.closest("label");a&&a.control&&(s=a.control)}return s}async checkElementStates(e,i){if(i.includes("stable")){const s=await this._checkElementIsStable(e);if(s===!1)return{missingState:"stable"};if(s==="error:notconnected")return"error:notconnected"}for(const s of i)if(s!=="stable"){const a=this.elementState(e,s);if(a.received==="error:notconnected")return"error:notconnected";if(!a.matches)return{missingState:s}}}async _checkElementIsStable(e){const i=Symbol("continuePolling");let s,a=0,o=0;const u=()=>{const y=this.retarget(e,"no-follow-label");if(!y)return"error:notconnected";const b=this.utils.builtins.performance.now();if(this._stableRafCount>1&&b-o<15)return i;o=b;const w=y.getBoundingClientRect(),E={x:w.top,y:w.left,width:w.width,height:w.height};if(s){if(!(E.x===s.x&&E.y===s.y&&E.width===s.width&&E.height===s.height))return!1;if(++a>=this._stableRafCount)return!0}return s=E,i};let f,d;const p=new Promise((y,b)=>{f=y,d=b}),m=()=>{try{const y=u();y!==i?f(y):this.utils.builtins.requestAnimationFrame(m)}catch(y){d(y)}};return this.utils.builtins.requestAnimationFrame(m),p}_createAriaRefEngine(){return{queryAll:(i,s)=>{var o,u;const a=(u=(o=this._lastAriaSnapshotForQuery)==null?void 0:o.elements)==null?void 0:u.get(s);return a&&a.isConnected?[a]:[]}}}elementState(e,i){const s=this.retarget(e,["visible","hidden"].includes(i)?"none":"follow-label");if(!s||!s.isConnected)return i==="hidden"?{matches:!0,received:"hidden"}:{matches:!1,received:"error:notconnected"};if(i==="visible"||i==="hidden"){const a=vi(s);return{matches:i==="visible"?a:!a,received:a?"visible":"hidden"}}if(i==="disabled"||i==="enabled"){const a=Zo(s);return{matches:i==="disabled"?a:!a,received:a?"disabled":"enabled"}}if(i==="editable"){const a=Zo(s),o=xT(s);if(o==="error")throw this.createStacklessError("Element is not an <input>, <textarea>, <select> or [contenteditable] and does not have a role allowing [aria-readonly]");return{matches:!a&&!o,received:a?"disabled":o?"readOnly":"editable"}}if(i==="checked"||i==="unchecked"){const a=i==="checked",o=ST(s);if(o==="error")throw this.createStacklessError("Not a checkbox or radio button");const u=s.nodeName==="INPUT"&&s.type==="radio";return{matches:a===o,received:o?"checked":"unchecked",isRadio:u}}if(i==="indeterminate"){const a=vT(s);if(a==="error")throw this.createStacklessError("Not a checkbox or radio button");return{matches:a==="mixed",received:a===!0?"checked":a===!1?"unchecked":"mixed"}}throw this.createStacklessError(`Unexpected element state "${i}"`)}selectOptions(e,i){const s=this.retarget(e,"follow-label");if(!s)return"error:notconnected";if(s.nodeName.toLowerCase()!=="select")throw this.createStacklessError("Element is not a <select> element");const a=s,o=[...a.options],u=[];let f=i.slice();for(let d=0;d<o.length;d++){const p=o[d],m=y=>{if(y instanceof Node)return p===y;let b=!0;return y.valueOrLabel!==void 0&&(b=b&&(y.valueOrLabel===p.value||y.valueOrLabel===p.label)),y.value!==void 0&&(b=b&&y.value===p.value),y.label!==void 0&&(b=b&&y.label===p.label),y.index!==void 0&&(b=b&&y.index===d),b};if(f.some(m)){if(!this.elementState(p,"enabled").matches)return"error:optionnotenabled";if(u.push(p),a.multiple)f=f.filter(y=>!m(y));else{f=[];break}}}return f.length?"error:optionsnotfound":(a.value=void 0,u.forEach(d=>d.selected=!0),a.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),a.dispatchEvent(new Event("change",{bubbles:!0})),u.map(d=>d.value))}fill(e,i){const s=this.retarget(e,"follow-label");if(!s)return"error:notconnected";if(s.nodeName.toLowerCase()==="input"){const a=s,o=a.type.toLowerCase(),u=new Set(["color","date","time","datetime-local","month","range","week"]);if(!new Set(["","email","number","password","search","tel","text","url"]).has(o)&&!u.has(o))throw this.createStacklessError(`Input of type "${o}" cannot be filled`);if(o==="number"&&(i=i.trim(),isNaN(Number(i))))throw this.createStacklessError("Cannot type text into input[type=number]");if(u.has(o)){if(i=i.trim(),a.focus(),a.value=i,a.value!==i)throw this.createStacklessError("Malformed value");return s.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),s.dispatchEvent(new Event("change",{bubbles:!0})),"done"}}else if(s.nodeName.toLowerCase()!=="textarea"){if(!s.isContentEditable)throw this.createStacklessError("Element is not an <input>, <textarea> or [contenteditable] element")}return this.selectText(s),"needsinput"}selectText(e){const i=this.retarget(e,"follow-label");if(!i)return"error:notconnected";if(i.nodeName.toLowerCase()==="input"){const o=i;return o.select(),o.focus(),"done"}if(i.nodeName.toLowerCase()==="textarea"){const o=i;return o.selectionStart=0,o.selectionEnd=o.value.length,o.focus(),"done"}const s=i.ownerDocument.createRange();s.selectNodeContents(i);const a=i.ownerDocument.defaultView.getSelection();return a&&(a.removeAllRanges(),a.addRange(s)),i.focus(),"done"}_activelyFocused(e){const i=e.getRootNode().activeElement,s=i===e&&!!e.ownerDocument&&e.ownerDocument.hasFocus();return{activeElement:i,isFocused:s}}focusNode(e,i){if(!e.isConnected)return"error:notconnected";if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Node is not an element");const{activeElement:s,isFocused:a}=this._activelyFocused(e);if(e.isContentEditable&&!a&&s&&s.blur&&s.blur(),e.focus(),e.focus(),i&&!a&&e.nodeName.toLowerCase()==="input")try{e.setSelectionRange(0,0)}catch{}return"done"}blurNode(e){if(!e.isConnected)return"error:notconnected";if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Node is not an element");return e.blur(),"done"}setInputFiles(e,i){if(e.nodeType!==Node.ELEMENT_NODE)return"Node is not of type HTMLElement";const s=e;if(s.nodeName!=="INPUT")return"Not an <input> element";const a=s;if((a.getAttribute("type")||"").toLowerCase()!=="file")return"Not an input[type=file] element";const u=i.map(d=>{const p=Uint8Array.from(atob(d.buffer),m=>m.charCodeAt(0));return new File([p],d.name,{type:d.mimeType,lastModified:d.lastModifiedMs})}),f=new DataTransfer;for(const d of u)f.items.add(d);a.files=f.files,a.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),a.dispatchEvent(new Event("change",{bubbles:!0}))}expectHitTarget(e,i){const s=[];let a=i;for(;a;){const m=cb(a);if(!m||(s.push(m),m.nodeType===9))break;a=m.host}let o;for(let m=s.length-1;m>=0;m--){const y=s[m],b=y.elementsFromPoint(e.x,e.y),w=y.elementFromPoint(e.x,e.y);if(w&&b[0]&&yt(w)===b[0]){const x=this.window.getComputedStyle(w);(x==null?void 0:x.display)==="contents"&&b.unshift(w)}b[0]&&b[0].shadowRoot===y&&b[1]===w&&b.shift();const E=b[0];if(!E||(o=E,m&&E!==s[m-1].host))break}const u=[];for(;o&&o!==i;)u.push(o),o=o.assignedSlot??yt(o);if(o===i)return"done";const f=this.previewNode(u[0]||this.document.documentElement);let d,p=i;for(;p;){const m=u.indexOf(p);if(m!==-1){m>1&&(d=this.previewNode(u[m-1]));break}p=yt(p)}return d?{hitTargetDescription:`${f} from ${d} subtree`}:{hitTargetDescription:f}}setupHitTargetInterceptor(e,i,s,a){const o=this.retarget(e,"button-link");if(!o||!o.isConnected)return"error:notconnected";if(s){const m=this.expectHitTarget(s,o);if(m!=="done")return m.hitTargetDescription}if(i==="drag")return{stop:()=>"done"};const u={hover:this._hoverHitTargetInterceptorEvents,tap:this._tapHitTargetInterceptorEvents,mouse:this._mouseHitTargetInterceptorEvents}[i];let f;const d=m=>{if(!u.has(m.type)||!m.isTrusted)return;const y=this.window.TouchEvent&&m instanceof this.window.TouchEvent?m.touches[0]:m;f===void 0&&y&&(f=this.expectHitTarget({x:y.clientX,y:y.clientY},o)),(a||f!=="done"&&f!==void 0)&&(m.preventDefault(),m.stopPropagation(),m.stopImmediatePropagation())},p=()=>(this._hitTargetInterceptor===d&&(this._hitTargetInterceptor=void 0),f||"done");return this._hitTargetInterceptor=d,{stop:p}}dispatchEvent(e,i,s){var u,f,d;let a;const o={bubbles:!0,cancelable:!0,composed:!0,...s};switch(this._eventTypes.get(i)){case"mouse":a=new MouseEvent(i,o);break;case"keyboard":a=new KeyboardEvent(i,o);break;case"touch":{if(this._browserName==="webkit"){const p=y=>{var E,x;if(y instanceof Touch)return y;let b=y.pageX;b===void 0&&y.clientX!==void 0&&(b=y.clientX+(((E=this.document.scrollingElement)==null?void 0:E.scrollLeft)||0));let w=y.pageY;return w===void 0&&y.clientY!==void 0&&(w=y.clientY+(((x=this.document.scrollingElement)==null?void 0:x.scrollTop)||0)),this.document.createTouch(this.window,y.target??e,y.identifier,b,w,y.screenX,y.screenY,y.radiusX,y.radiusY,y.rotationAngle,y.force)},m=y=>y instanceof TouchList||!y?y:this.document.createTouchList(...y.map(p));o.target??(o.target=e),o.touches=m(o.touches),o.targetTouches=m(o.targetTouches),o.changedTouches=m(o.changedTouches),a=new TouchEvent(i,o)}else o.target??(o.target=e),o.touches=(u=o.touches)==null?void 0:u.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),o.targetTouches=(f=o.targetTouches)==null?void 0:f.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),o.changedTouches=(d=o.changedTouches)==null?void 0:d.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),a=new TouchEvent(i,o);break}case"pointer":a=new PointerEvent(i,o);break;case"focus":a=new FocusEvent(i,o);break;case"drag":a=new DragEvent(i,o);break;case"wheel":a=new WheelEvent(i,o);break;case"deviceorientation":try{a=new DeviceOrientationEvent(i,o)}catch{const{bubbles:p,cancelable:m,alpha:y,beta:b,gamma:w,absolute:E}=o;a=this.document.createEvent("DeviceOrientationEvent"),a.initDeviceOrientationEvent(i,p,m,y,b,w,E)}break;case"devicemotion":try{a=new DeviceMotionEvent(i,o)}catch{const{bubbles:p,cancelable:m,acceleration:y,accelerationIncludingGravity:b,rotationRate:w,interval:E}=o;a=this.document.createEvent("DeviceMotionEvent"),a.initDeviceMotionEvent(i,p,m,y,b,w,E)}break;default:a=new Event(i,o);break}e.dispatchEvent(a)}previewNode(e){if(e.nodeType===Node.TEXT_NODE)return xo(`#text=${e.nodeValue||""}`);if(e.nodeType!==Node.ELEMENT_NODE)return xo(`<${e.nodeName.toLowerCase()} />`);const i=e,s=[];for(let d=0;d<i.attributes.length;d++){const{name:p,value:m}=i.attributes[d];p!=="style"&&(!m&&this._booleanAttributes.has(p)?s.push(` ${p}`):s.push(` ${p}="${m}"`))}s.sort((d,p)=>d.length-p.length);const a=ky(s.join(""),500);if(this._autoClosingTags.has(i.nodeName))return xo(`<${i.nodeName.toLowerCase()}${a}/>`);const o=i.childNodes;let u=!1;if(o.length<=5){u=!0;for(let d=0;d<o.length;d++)u=u&&o[d].nodeType===Node.TEXT_NODE}const f=u?i.textContent||"":o.length?"…":"";return xo(`<${i.nodeName.toLowerCase()}${a}>${ky(f,50)}</${i.nodeName.toLowerCase()}>`)}strictModeViolationError(e,i){this._evaluator.begin(),lc(),Ih();try{const s=this._isUtilityWorld&&this._browserName==="firefox"?2:10,a=i.slice(0,s).map(u=>({preview:this.previewNode(u),selector:this.generateSelectorSimple(u)})),o=a.map((u,f)=>`
|
|
122
122
|
${f+1}) ${u.preview} aka ${Wi(this._sdkLanguage,u.selector)}`);return a.length<i.length&&o.push(`
|
|
123
123
|
...`),this.createStacklessError(`strict mode violation: ${Wi(this._sdkLanguage,Gn(e))} resolved to ${i.length} elements:${o.join("")}
|
|
124
|
-
`)}finally{Vh(),oc(),this._evaluator.end()}}createStacklessError(e){if(this._browserName==="firefox"){const s=new Error("Error: "+e);return s.stack="",s}const i=new Error(e);return delete i.stack,i}createHighlight(){return new Zf(this)}maskSelectors(e,i){this._highlight&&this.hideHighlight(),this._highlight=new Zf(this),this._highlight.install();const s=[];for(const a of e)s.push(this.querySelectorAll(a,this.document.documentElement));this._highlight.maskElements(s.flat(),i)}highlight(e){this._highlight||(this._highlight=new Zf(this),this._highlight.install()),this._highlight.runHighlightOnRaf(e)}hideHighlight(){this._highlight&&(this._highlight.uninstall(),delete this._highlight)}markTargetElements(e,i){var u,f;((u=this._markedElements)==null?void 0:u.callId)!==i&&(this._markedElements=void 0);const s=((f=this._markedElements)==null?void 0:f.elements)||new Set,a=new CustomEvent("__playwright_unmark_target__",{bubbles:!0,cancelable:!0,detail:i,composed:!0});for(const d of s)e.has(d)||d.dispatchEvent(a);const o=new CustomEvent("__playwright_mark_target__",{bubbles:!0,cancelable:!0,detail:i,composed:!0});for(const d of e)s.has(d)||d.dispatchEvent(o);this._markedElements={callId:i,elements:e}}_setupGlobalListenersRemovalDetection(){const e="__playwright_global_listeners_check__";let i=!1;const s=()=>i=!0;this.window.addEventListener(e,s),new MutationObserver(a=>{if(a.some(u=>Array.from(u.addedNodes).includes(this.document.documentElement))&&(i=!1,this.window.dispatchEvent(new CustomEvent(e)),!i)){this.window.addEventListener(e,s);for(const u of this.onGlobalListenersRemoved)u()}}).observe(this.document,{childList:!0})}_setupHitTargetInterceptors(){const e=s=>{var a;return(a=this._hitTargetInterceptor)==null?void 0:a.call(this,s)},i=()=>{for(const s of this._allHitTargetInterceptorEvents)this.window.addEventListener(s,e,{capture:!0,passive:!1})};i(),this.onGlobalListenersRemoved.add(i)}async expect(e,i,s){var o,u;if(i.expression==="to.have.count"||i.expression.endsWith(".array"))return this.expectArray(s,i);if(!e){if(!i.isNot&&i.expression==="to.be.hidden")return{matches:!0};if(i.isNot&&i.expression==="to.be.visible")return{matches:!1};if(!i.isNot&&i.expression==="to.be.detached")return{matches:!0};if(i.isNot&&i.expression==="to.be.attached")return{matches:!1};if(i.isNot&&i.expression==="to.be.in.viewport")return{matches:!1};if(i.expression==="to.have.title"&&((o=i==null?void 0:i.expectedText)!=null&&o[0])){const f=new Qs(i.expectedText[0]),d=this.document.title;return{received:d,matches:f.matches(d)}}if(i.expression==="to.have.url"&&((u=i==null?void 0:i.expectedText)!=null&&u[0])){const f=new Qs(i.expectedText[0]),d=this.document.location.href;return{received:d,matches:f.matches(d)}}return{matches:i.isNot,missingReceived:!0}}return await this.expectSingleElement(e,i)}async expectSingleElement(e,i){var a;const s=i.expression;{let o;if(s==="to.have.attribute"){const u=e.hasAttribute(i.expressionArg);o={matches:u,received:u?"attribute present":"attribute not present"}}else if(s==="to.be.checked"){const{checked:u,indeterminate:f}=i.expectedValue;if(f){if(u!==void 0)throw this.createStacklessError("Can't assert indeterminate and checked at the same time");o=this.elementState(e,"indeterminate")}else o=this.elementState(e,u===!1?"unchecked":"checked")}else if(s==="to.be.disabled")o=this.elementState(e,"disabled");else if(s==="to.be.editable")o=this.elementState(e,"editable");else if(s==="to.be.readonly")o=this.elementState(e,"editable"),o.matches=!o.matches;else if(s==="to.be.empty")if(e.nodeName==="INPUT"||e.nodeName==="TEXTAREA"){const u=e.value;o={matches:!u,received:u?"notEmpty":"empty"}}else{const u=(a=e.textContent)==null?void 0:a.trim();o={matches:!u,received:u?"notEmpty":"empty"}}else if(s==="to.be.enabled")o=this.elementState(e,"enabled");else if(s==="to.be.focused"){const u=this._activelyFocused(e).isFocused;o={matches:u,received:u?"focused":"inactive"}}else s==="to.be.hidden"?o=this.elementState(e,"hidden"):s==="to.be.visible"?o=this.elementState(e,"visible"):s==="to.be.attached"?o={matches:!0,received:"attached"}:s==="to.be.detached"&&(o={matches:!1,received:"attached"});if(o){if(o.received==="error:notconnected")throw this.createStacklessError("Element is not connected");return o}}if(s==="to.have.property"){let o=e;const u=i.expressionArg.split(".");for(let p=0;p<u.length-1;p++){if(typeof o!="object"||!(u[p]in o))return{received:void 0,matches:!1};o=o[u[p]]}const f=o[u[u.length-1]],d=wh(f,i.expectedValue);return{received:f,matches:d}}if(s==="to.be.in.viewport"){const o=await this.viewportRatio(e);return{received:`viewport ratio ${o}`,matches:o>0&&o>(i.expectedNumber??0)-1e-9}}if(s==="to.have.values"){if(e=this.retarget(e,"follow-label"),e.nodeName!=="SELECT"||!e.multiple)throw this.createStacklessError("Not a select element with a multiple attribute");const o=[...e.selectedOptions].map(u=>u.value);return o.length!==i.expectedText.length?{received:o,matches:!1}:{received:o,matches:o.map((u,f)=>new Qs(i.expectedText[f]).matches(u)).every(Boolean)}}if(s==="to.match.aria"){const o=jT(e,i.expectedValue);return{received:o.received,matches:!!o.matches.length}}{let o;if(s==="to.have.attribute.value"){const u=e.getAttribute(i.expressionArg);if(u===null)return{received:null,matches:!1};o=u}else if(["to.have.class","to.contain.class"].includes(s)){if(!i.expectedText)throw this.createStacklessError("Expected text is not provided for "+s);return{received:e.classList.toString(),matches:new Qs(i.expectedText[0]).matchesClassList(this,e.classList,s==="to.contain.class")}}else if(s==="to.have.css")o=this.window.getComputedStyle(e).getPropertyValue(i.expressionArg);else if(s==="to.have.id")o=e.id;else if(s==="to.have.text")o=i.useInnerText?e.innerText:Bt(new Map,e).full;else if(s==="to.have.accessible.name")o=Qa(e,!1);else if(s==="to.have.accessible.description")o=Gy(e,!1);else if(s==="to.have.accessible.error.message")o=mT(e);else if(s==="to.have.role")o=ft(e)||"";else if(s==="to.have.value"){if(e=this.retarget(e,"follow-label"),e.nodeName!=="INPUT"&&e.nodeName!=="TEXTAREA"&&e.nodeName!=="SELECT")throw this.createStacklessError("Not an input element");o=e.value}if(o!==void 0&&i.expectedText){const u=new Qs(i.expectedText[0]);return{received:o,matches:u.matches(o)}}}throw this.createStacklessError("Unknown expect matcher: "+s)}expectArray(e,i){const s=i.expression;if(s==="to.have.count"){const d=e.length,p=d===i.expectedNumber;return{received:d,matches:p}}if(!i.expectedText)throw this.createStacklessError("Expected text is not provided for "+s);if(["to.have.class.array","to.contain.class.array"].includes(s)){const d=e.map(y=>y.classList),p=d.map(String);if(d.length!==i.expectedText.length)return{received:p,matches:!1};const m=this._matchSequentially(i.expectedText,d,(y,b)=>y.matchesClassList(this,b,s==="to.contain.class.array"));return{received:p,matches:m}}if(!["to.contain.text.array","to.have.text.array"].includes(s))throw this.createStacklessError("Unknown expect matcher: "+s);const a=e.map(d=>i.useInnerText?d.innerText:Bt(new Map,d).full),o=s!=="to.contain.text.array";if(!(a.length===i.expectedText.length||!o))return{received:a,matches:!1};const f=this._matchSequentially(i.expectedText,a,(d,p)=>d.matches(p));return{received:a,matches:f}}_matchSequentially(e,i,s){const a=e.map(f=>new Qs(f));let o=0,u=0;for(;o<a.length&&u<i.length;)s(a[o],i[u])&&++o,++u;return o===a.length}}function xo(n){return n.replace(/\n/g,"↵").replace(/\t/g,"⇆")}function QE(n){if(n=n.substring(1,n.length-1),!n.includes("\\"))return n;const e=[];let i=0;for(;i<n.length;)n[i]==="\\"&&i+1<n.length&&i++,e.push(n[i++]);return e.join("")}function _o(n,e){if(n[0]==="/"&&n.lastIndexOf("/")>0){const a=n.lastIndexOf("/"),o=new RegExp(n.substring(1,a),n.substring(a+1));return{matcher:u=>o.test(u.full),kind:"regex"}}const i=e?JSON.parse.bind(JSON):QE;let s=!1;return n.length>1&&n[0]==='"'&&n[n.length-1]==='"'?(n=i(n),s=!0):e&&n.length>1&&n[0]==='"'&&n[n.length-2]==='"'&&n[n.length-1]==="i"?(n=i(n.substring(0,n.length-1)),s=!1):e&&n.length>1&&n[0]==='"'&&n[n.length-2]==='"'&&n[n.length-1]==="s"?(n=i(n.substring(0,n.length-1)),s=!0):n.length>1&&n[0]==="'"&&n[n.length-1]==="'"&&(n=i(n),s=!0),n=Tt(n),s?e?{kind:"strict",matcher:o=>o.normalized===n}:{matcher:o=>!n&&!o.immediate.length?!0:o.immediate.some(u=>Tt(u)===n),kind:"strict"}:(n=n.toLowerCase(),{kind:"lax",matcher:a=>a.normalized.toLowerCase().includes(n)})}class Qs{constructor(e){if(this._normalizeWhiteSpace=e.normalizeWhiteSpace,this._ignoreCase=e.ignoreCase,this._string=e.matchSubstring?void 0:this.normalize(e.string),this._substring=e.matchSubstring?this.normalize(e.string):void 0,e.regexSource){const i=new Set((e.regexFlags||"").split(""));e.ignoreCase===!1&&i.delete("i"),e.ignoreCase===!0&&i.add("i"),this._regex=new RegExp(e.regexSource,[...i].join(""))}}matches(e){return this._regex||(e=this.normalize(e)),this._string!==void 0?e===this._string:this._substring!==void 0?e.includes(this._substring):this._regex?!!this._regex.test(e):!1}matchesClassList(e,i,s){if(s){if(this._regex)throw e.createStacklessError("Partial matching does not support regular expressions. Please provide a string value.");return this._string.split(/\s+/g).filter(Boolean).every(a=>i.contains(a))}return this.matches(i.toString())}normalize(e){return e&&(this._normalizeWhiteSpace&&(e=Tt(e)),this._ignoreCase&&(e=e.toLocaleLowerCase()),e)}}function wh(n,e){if(n===e)return!0;if(n&&e&&typeof n=="object"&&typeof e=="object"){if(n.constructor!==e.constructor)return!1;if(Array.isArray(n)){if(n.length!==e.length)return!1;for(let s=0;s<n.length;++s)if(!wh(n[s],e[s]))return!1;return!0}if(n instanceof RegExp)return n.source===e.source&&n.flags===e.flags;if(n.valueOf!==Object.prototype.valueOf)return n.valueOf()===e.valueOf();if(n.toString!==Object.prototype.toString)return n.toString()===e.toString();const i=Object.keys(n);if(i.length!==Object.keys(e).length)return!1;for(let s=0;s<i.length;++s)if(!e.hasOwnProperty(i[s]))return!1;for(const s of i)if(!wh(n[s],e[s]))return!1;return!0}return typeof n=="number"&&typeof e=="number"?isNaN(n)&&isNaN(e):!1}const ZE={tagName:"svg",children:[{tagName:"defs",children:[{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-gripper"},children:[{tagName:"path",attrs:{d:"M5 3h2v2H5zm0 4h2v2H5zm0 4h2v2H5zm4-8h2v2H9zm0 4h2v2H9zm0 4h2v2H9z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-circle-large-filled"},children:[{tagName:"path",attrs:{d:"M8 1a6.8 6.8 0 0 1 1.86.253 6.899 6.899 0 0 1 3.083 1.805 6.903 6.903 0 0 1 1.804 3.083C14.916 6.738 15 7.357 15 8s-.084 1.262-.253 1.86a6.9 6.9 0 0 1-.704 1.674 7.157 7.157 0 0 1-2.516 2.509 6.966 6.966 0 0 1-1.668.71A6.984 6.984 0 0 1 8 15a6.984 6.984 0 0 1-1.86-.246 7.098 7.098 0 0 1-1.674-.711 7.3 7.3 0 0 1-1.415-1.094 7.295 7.295 0 0 1-1.094-1.415 7.098 7.098 0 0 1-.71-1.675A6.985 6.985 0 0 1 1 8c0-.643.082-1.262.246-1.86a6.968 6.968 0 0 1 .711-1.667 7.156 7.156 0 0 1 2.509-2.516 6.895 6.895 0 0 1 1.675-.704A6.808 6.808 0 0 1 8 1z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-stop-circle"},children:[{tagName:"path",attrs:{d:"M6 6h4v4H6z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-inspect"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M1 3l1-1h12l1 1v6h-1V3H2v8h5v1H2l-1-1V3zm14.707 9.707L9 6v9.414l2.707-2.707h4zM10 13V8.414l3.293 3.293h-2L10 13z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-whole-word"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M0 11H1V13H15V11H16V14H15H1H0V11Z"}},{tagName:"path",attrs:{d:"M6.84048 11H5.95963V10.1406H5.93814C5.555 10.7995 4.99104 11.1289 4.24625 11.1289C3.69839 11.1289 3.26871 10.9839 2.95718 10.6938C2.64924 10.4038 2.49527 10.0189 2.49527 9.53906C2.49527 8.51139 3.10041 7.91341 4.3107 7.74512L5.95963 7.51416C5.95963 6.57959 5.58186 6.1123 4.82632 6.1123C4.16389 6.1123 3.56591 6.33789 3.03238 6.78906V5.88672C3.57307 5.54297 4.19612 5.37109 4.90152 5.37109C6.19416 5.37109 6.84048 6.05501 6.84048 7.42285V11ZM5.95963 8.21777L4.63297 8.40039C4.22476 8.45768 3.91682 8.55973 3.70914 8.70654C3.50145 8.84977 3.39761 9.10579 3.39761 9.47461C3.39761 9.74316 3.4925 9.96338 3.68228 10.1353C3.87564 10.3035 4.13166 10.3877 4.45035 10.3877C4.8872 10.3877 5.24706 10.2355 5.52994 9.93115C5.8164 9.62321 5.95963 9.2347 5.95963 8.76562V8.21777Z"}},{tagName:"path",attrs:{d:"M9.3475 10.2051H9.32601V11H8.44515V2.85742H9.32601V6.4668H9.3475C9.78076 5.73633 10.4146 5.37109 11.2489 5.37109C11.9543 5.37109 12.5057 5.61816 12.9032 6.1123C13.3042 6.60286 13.5047 7.26172 13.5047 8.08887C13.5047 9.00911 13.2809 9.74674 12.8333 10.3018C12.3857 10.8532 11.7734 11.1289 10.9964 11.1289C10.2695 11.1289 9.71989 10.821 9.3475 10.2051ZM9.32601 7.98682V8.75488C9.32601 9.20964 9.47282 9.59635 9.76644 9.91504C10.0636 10.2301 10.4396 10.3877 10.8944 10.3877C11.4279 10.3877 11.8451 10.1836 12.1458 9.77539C12.4502 9.36719 12.6024 8.79964 12.6024 8.07275C12.6024 7.46045 12.4609 6.98063 12.1781 6.6333C11.8952 6.28597 11.512 6.1123 11.0286 6.1123C10.5166 6.1123 10.1048 6.29134 9.7933 6.64941C9.48177 7.00391 9.32601 7.44971 9.32601 7.98682Z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-eye"},children:[{tagName:"path",attrs:{d:"M7.99993 6.00316C9.47266 6.00316 10.6666 7.19708 10.6666 8.66981C10.6666 10.1426 9.47266 11.3365 7.99993 11.3365C6.52715 11.3365 5.33324 10.1426 5.33324 8.66981C5.33324 7.19708 6.52715 6.00316 7.99993 6.00316ZM7.99993 7.00315C7.07946 7.00315 6.33324 7.74935 6.33324 8.66981C6.33324 9.59028 7.07946 10.3365 7.99993 10.3365C8.9204 10.3365 9.6666 9.59028 9.6666 8.66981C9.6666 7.74935 8.9204 7.00315 7.99993 7.00315ZM7.99993 3.66675C11.0756 3.66675 13.7307 5.76675 14.4673 8.70968C14.5344 8.97755 14.3716 9.24908 14.1037 9.31615C13.8358 9.38315 13.5643 9.22041 13.4973 8.95248C12.8713 6.45205 10.6141 4.66675 7.99993 4.66675C5.38454 4.66675 3.12664 6.45359 2.50182 8.95555C2.43491 9.22341 2.16348 9.38635 1.89557 9.31948C1.62766 9.25255 1.46471 8.98115 1.53162 8.71321C2.26701 5.76856 4.9229 3.66675 7.99993 3.66675Z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-symbol-constant"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M4 6h8v1H4V6zm8 3H4v1h8V9z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M1 4l1-1h12l1 1v8l-1 1H2l-1-1V4zm1 0v8h12V4H2z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-check"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M14.431 3.323l-8.47 10-.79-.036-3.35-4.77.818-.574 2.978 4.24 8.051-9.506.764.646z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-close"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8 8.707l3.646 3.647.708-.707L8.707 8l3.647-3.646-.707-.708L8 7.293 4.354 3.646l-.707.708L7.293 8l-3.646 3.646.707.708L8 8.707z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-pass"},children:[{tagName:"path",attrs:{d:"M6.27 10.87h.71l4.56-4.56-.71-.71-4.2 4.21-1.92-1.92L4 8.6l2.27 2.27z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-gist"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M10.57 1.14l3.28 3.3.15.36v9.7l-.5.5h-11l-.5-.5v-13l.5-.5h7.72l.35.14zM10 5h3l-3-3v3zM3 2v12h10V6H9.5L9 5.5V2H3zm2.062 7.533l1.817-1.828L6.17 7 4 9.179v.707l2.171 2.174.707-.707-1.816-1.82zM8.8 7.714l.7-.709 2.189 2.175v.709L9.5 12.062l-.705-.709 1.831-1.82L8.8 7.714z"}}]}]}]},an={multiple:"#f6b26b7f",single:"#6fa8dc7f",assert:"#8acae480",action:"#dc6f6f7f"};class i0{}class th{constructor(e,i){this._hoveredModel=null,this._hoveredElement=null,this._recorder=e,this._assertVisibility=i}cursor(){return"pointer"}uninstall(){this._hoveredModel=null,this._hoveredElement=null}onClick(e){var i;ze(e),e.button===0&&(i=this._hoveredModel)!=null&&i.selector&&this._commit(this._hoveredModel.selector,this._hoveredModel)}onPointerDown(e){ze(e)}onPointerUp(e){ze(e)}onMouseDown(e){ze(e)}onMouseUp(e){ze(e)}onMouseMove(e){var a;ze(e);let i=this._recorder.deepEventTarget(e);if(i.isConnected||(i=null),this._hoveredElement===i)return;this._hoveredElement=i;let s=null;if(this._hoveredElement){const o=this._recorder.injectedScript.generateSelector(this._hoveredElement,{testIdAttributeName:this._recorder.state.testIdAttributeName,multiple:!1});s={selector:o.selector,elements:o.elements,tooltipText:this._recorder.injectedScript.utils.asLocator(this._recorder.state.language,o.selector),color:this._assertVisibility?an.assert:an.single}}((a=this._hoveredModel)==null?void 0:a.selector)!==(s==null?void 0:s.selector)&&(this._hoveredModel=s,this._recorder.updateHighlight(s,!0))}onMouseEnter(e){ze(e)}onMouseLeave(e){ze(e);const i=this._recorder.injectedScript.window;i.top!==i&&this._recorder.deepEventTarget(e).nodeType===Node.DOCUMENT_NODE&&this._reset(!0)}onKeyDown(e){ze(e),e.key==="Escape"&&this._assertVisibility&&this._recorder.setMode("recording")}onKeyUp(e){ze(e)}onScroll(e){this._reset(!1)}_commit(e,i){var s;this._assertVisibility?(this._recorder.recordAction({name:"assertVisible",selector:e,signals:[]}),this._recorder.setMode("recording"),(s=this._recorder.overlay)==null||s.flashToolSucceeded("assertingVisibility")):this._recorder.elementPicked(e,i)}_reset(e){this._hoveredElement=null,this._hoveredModel=null,this._recorder.updateHighlight(null,e)}}class JE{constructor(e){this._hoveredModel=null,this._hoveredElement=null,this._activeModel=null,this._expectProgrammaticKeyUp=!1,this._observer=null,this._recorder=e,this._performingActions=new Set,this._dialog=new rv(e)}cursor(){return"pointer"}_installObserverIfNeeded(){var e;this._observer||(e=this._recorder.injectedScript.document)!=null&&e.body&&(this._observer=new MutationObserver(i=>{if(this._hoveredElement)for(const s of i)for(const a of s.removedNodes)(a===this._hoveredElement||a.contains(this._hoveredElement))&&this._resetHoveredModel()}),this._observer.observe(this._recorder.injectedScript.document.body,{childList:!0,subtree:!0}))}uninstall(){var e;(e=this._observer)==null||e.disconnect(),this._observer=null,this._hoveredModel=null,this._hoveredElement=null,this._activeModel=null,this._expectProgrammaticKeyUp=!1,this._dialog.close()}onClick(e){if(this._dialog.isShowing()){e.button===2&&e.type==="auxclick"&&ze(e);return}if(Ya(this._hoveredElement)||this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel))return;if(e.button===2&&e.type==="auxclick"){this._showActionListDialog(this._hoveredModel,e);return}const i=Ka(this._recorder.deepEventTarget(e));if(i&&e.detail===1){this._performAction({name:i.checked?"check":"uncheck",selector:this._hoveredModel.selector,signals:[]});return}this._cancelPendingClickAction(),e.detail===1&&(this._pendingClickAction={action:{name:"click",selector:this._hoveredModel.selector,position:Ga(e),signals:[],button:xh(e),modifiers:lr(e),clickCount:e.detail},timeout:this._recorder.injectedScript.utils.builtins.setTimeout(()=>this._commitPendingClickAction(),200)})}onDblClick(e){this._dialog.isShowing()||Ya(this._hoveredElement)||this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel)||(this._cancelPendingClickAction(),this._performAction({name:"click",selector:this._hoveredModel.selector,position:Ga(e),signals:[],button:xh(e),modifiers:lr(e),clickCount:e.detail}))}_commitPendingClickAction(){this._pendingClickAction&&this._performAction(this._pendingClickAction.action),this._cancelPendingClickAction()}_cancelPendingClickAction(){this._pendingClickAction&&this._recorder.injectedScript.utils.builtins.clearTimeout(this._pendingClickAction.timeout),this._pendingClickAction=void 0}onContextMenu(e){if(this._dialog.isShowing()){ze(e);return}this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel)||this._showActionListDialog(this._hoveredModel,e)}onPointerDown(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onPointerUp(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onMouseDown(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||(this._consumeWhenAboutToPerform(e),this._activeModel=this._hoveredModel)}onMouseUp(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onMouseMove(e){if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);this._hoveredElement!==i&&(this._hoveredElement=i,this._updateModelForHoveredElement())}onMouseLeave(e){if(this._dialog.isShowing())return;const i=this._recorder.injectedScript.window;i.top!==i&&this._recorder.deepEventTarget(e).nodeType===Node.DOCUMENT_NODE&&(this._hoveredElement=null,this._updateModelForHoveredElement())}onFocus(e){this._dialog.isShowing()||this._onFocus(!0)}onInput(e){if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);if(i.nodeName==="INPUT"&&i.type.toLowerCase()==="file"){this._recordAction({name:"setInputFiles",selector:this._activeModel.selector,signals:[],files:[...i.files||[]].map(s=>s.name)});return}if(Ya(i)){this._recordAction({name:"fill",selector:this._hoveredModel.selector,signals:[],text:i.value});return}if(["INPUT","TEXTAREA"].includes(i.nodeName)||i.isContentEditable){if(i.nodeName==="INPUT"&&["checkbox","radio"].includes(i.type.toLowerCase())||this._consumedDueWrongTarget(e))return;this._recordAction({name:"fill",selector:this._activeModel.selector,signals:[],text:i.isContentEditable?i.innerText:i.value})}if(i.nodeName==="SELECT"){const s=i;this._recordAction({name:"select",selector:this._activeModel.selector,options:[...s.selectedOptions].map(a=>a.value),signals:[]})}}onKeyDown(e){if(!this._dialog.isShowing()&&this._shouldGenerateKeyPressFor(e)){if(this._actionInProgress(e)){this._expectProgrammaticKeyUp=!0;return}if(!this._consumedDueWrongTarget(e)){if(e.key===" "){const i=Ka(this._recorder.deepEventTarget(e));if(i&&e.detail===0){this._performAction({name:i.checked?"uncheck":"check",selector:this._activeModel.selector,signals:[]});return}}this._performAction({name:"press",selector:this._activeModel.selector,signals:[],key:e.key,modifiers:lr(e)})}}}onKeyUp(e){if(!this._dialog.isShowing()&&this._shouldGenerateKeyPressFor(e)){if(!this._expectProgrammaticKeyUp){ze(e);return}this._expectProgrammaticKeyUp=!1}}onScroll(e){this._dialog.isShowing()||this._resetHoveredModel()}_showActionListDialog(e,i){ze(i);const s=Ga(i),a=[{title:"Click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"left",modifiers:0,clickCount:0})},{title:"Right click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"right",modifiers:0,clickCount:0})},{title:"Double click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"left",modifiers:0,clickCount:2})},{title:"Hover",cb:()=>this._performAction({name:"hover",selector:e.selector,position:s,signals:[]})},{title:"Pick locator",cb:()=>this._recorder.elementPicked(e.selector,e)}],o=this._recorder.document.createElement("x-pw-action-list");o.setAttribute("role","list"),o.setAttribute("aria-label","Choose action");for(const p of a){const m=this._recorder.document.createElement("x-pw-action-item");m.setAttribute("role","listitem"),m.textContent=p.title,m.setAttribute("aria-label",p.title),m.addEventListener("click",()=>{this._dialog.close(),p.cb()}),o.appendChild(m)}const u=this._dialog.show({label:"Choose action",body:o,autosize:!0}),f=this._recorder.highlight.firstTooltipBox()||e.elements[0].getBoundingClientRect(),d=this._recorder.highlight.tooltipPosition(f,u);this._dialog.moveTo(d.anchorTop,d.anchorLeft)}_resetHoveredModel(){this._hoveredModel=null,this._hoveredElement=null,this._updateHighlight(!1)}_onFocus(e){const i=nA(this._recorder.document);if(e&&i===this._recorder.document.body)return;const s=i?this._recorder.injectedScript.generateSelector(i,{testIdAttributeName:this._recorder.state.testIdAttributeName}):null;this._activeModel=s&&s.selector?{...s,color:an.action}:null,e&&(this._hoveredElement=i,this._updateModelForHoveredElement())}_shouldIgnoreMouseEvent(e){const i=this._recorder.deepEventTarget(e),s=i.nodeName;return!!(s==="SELECT"||s==="OPTION"||s==="INPUT"&&["date","range"].includes(i.type))}_actionInProgress(e){const i=e instanceof KeyboardEvent,s=e instanceof MouseEvent||e instanceof PointerEvent;for(const a of this._performingActions)if(i&&a.name==="press"&&e.key===a.key||s&&(a.name==="click"||a.name==="hover"||a.name==="check"||a.name==="uncheck"))return!0;return ze(e),!1}_consumedDueToNoModel(e,i){return i?!1:(ze(e),!0)}_consumedDueWrongTarget(e){return this._activeModel&&this._activeModel.elements[0]===this._recorder.deepEventTarget(e)?!1:(ze(e),!0)}_consumeWhenAboutToPerform(e){this._performingActions.size||ze(e)}_recordAction(e){this._recorder.recordAction(e)}_performAction(e){this._recorder.updateHighlight(null,!1),this._performingActions.add(e);const i=this._recorder.performAction(e).then(()=>{this._performingActions.delete(e),this._onFocus(!1)});this._recorder.injectedScript.isUnderTest&&i.then(()=>{console.error("Action performed for test: "+JSON.stringify({hovered:this._hoveredModel?this._hoveredModel.selector:null,active:this._activeModel?this._activeModel.selector:null}))})}_shouldGenerateKeyPressFor(e){if(typeof e.key!="string"||e.key==="Enter"&&(this._recorder.deepEventTarget(e).nodeName==="TEXTAREA"||this._recorder.deepEventTarget(e).isContentEditable)||["Backspace","Delete","AltGraph"].includes(e.key)||e.key==="@"&&e.code==="KeyL")return!1;if(navigator.platform.includes("Mac")){if(e.key==="v"&&e.metaKey)return!1}else if(e.key==="v"&&e.ctrlKey||e.key==="Insert"&&e.shiftKey)return!1;if(["Shift","Control","Meta","Alt","Process"].includes(e.key))return!1;const i=e.ctrlKey||e.altKey||e.metaKey;return e.key.length===1&&!i?!!Ka(this._recorder.deepEventTarget(e)):!0}_updateModelForHoveredElement(){if(this._installObserverIfNeeded(),this._performingActions.size)return;if(!this._hoveredElement||!this._hoveredElement.isConnected){this._hoveredModel=null,this._hoveredElement=null,this._updateHighlight(!0);return}const{selector:e,elements:i}=this._recorder.injectedScript.generateSelector(this._hoveredElement,{testIdAttributeName:this._recorder.state.testIdAttributeName});this._hoveredModel&&this._hoveredModel.selector===e||(this._hoveredModel=e?{selector:e,elements:i,color:an.action}:null,this._updateHighlight(!0))}_updateHighlight(e){this._recorder.updateHighlight(this._hoveredModel,e)}}class WE{constructor(e){this._recorder=e}install(){this._recorder.highlight.uninstall()}uninstall(){this._recorder.highlight.install()}onClick(e){const i=this._recorder.deepEventTarget(e);if(Ya(i)||e.button===2&&e.type==="auxclick"||this._shouldIgnoreMouseEvent(e))return;const s=Ka(i),{ariaSnapshot:a,selector:o,ref:u}=this._ariaSnapshot(i);if(s&&e.detail===1){this._recorder.recordAction({name:s.checked?"check":"uncheck",selector:o,ref:u,signals:[],ariaSnapshot:a});return}this._recorder.recordAction({name:"click",selector:o,ref:u,ariaSnapshot:a,position:Ga(e),signals:[],button:xh(e),modifiers:lr(e),clickCount:e.detail})}onContextMenu(e){const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);this._recorder.recordAction({name:"click",selector:a,ref:o,ariaSnapshot:s,position:Ga(e),signals:[],button:"right",modifiers:lr(e),clickCount:1})}onInput(e){const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);if(Ya(i)){this._recorder.recordAction({name:"fill",selector:a,ref:o,ariaSnapshot:s,signals:[],text:i.value});return}if(["INPUT","TEXTAREA"].includes(i.nodeName)||i.isContentEditable){if(i.nodeName==="INPUT"&&["checkbox","radio"].includes(i.type.toLowerCase()))return;this._recorder.recordAction({name:"fill",ref:o,selector:a,ariaSnapshot:s,signals:[],text:i.isContentEditable?i.innerText:i.value});return}if(i.nodeName==="SELECT"){const u=i;this._recorder.recordAction({name:"select",selector:a,ref:o,ariaSnapshot:s,options:[...u.selectedOptions].map(f=>f.value),signals:[]});return}}onKeyDown(e){if(!this._shouldGenerateKeyPressFor(e))return;const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);if(e.key===" "){const u=Ka(i);if(u&&e.detail===0){this._recorder.recordAction({name:u.checked?"uncheck":"check",selector:a,ref:o,ariaSnapshot:s,signals:[]});return}}this._recorder.recordAction({name:"press",selector:a,ref:o,ariaSnapshot:s,signals:[],key:e.key,modifiers:lr(e)})}_shouldIgnoreMouseEvent(e){const i=this._recorder.deepEventTarget(e),s=i.nodeName;return!!(s==="SELECT"||s==="OPTION"||s==="INPUT"&&["date","range"].includes(i.type))}_shouldGenerateKeyPressFor(e){if(typeof e.key!="string"||e.key==="Enter"&&(this._recorder.deepEventTarget(e).nodeName==="TEXTAREA"||this._recorder.deepEventTarget(e).isContentEditable)||["Backspace","Delete","AltGraph"].includes(e.key)||e.key==="@"&&e.code==="KeyL")return!1;if(navigator.platform.includes("Mac")){if(e.key==="v"&&e.metaKey)return!1}else if(e.key==="v"&&e.ctrlKey||e.key==="Insert"&&e.shiftKey)return!1;if(["Shift","Control","Meta","Alt","Process"].includes(e.key))return!1;const i=e.ctrlKey||e.altKey||e.metaKey;return e.key.length===1&&!i?!this._isEditable(this._recorder.deepEventTarget(e)):!0}_isEditable(e){return!!(e.nodeName==="TEXTAREA"||e.nodeName==="INPUT"||e.isContentEditable)}_ariaSnapshot(e){const{ariaSnapshot:i,refs:s}=this._recorder.injectedScript.ariaSnapshotForRecorder(),a=e?s.get(e):void 0,o=e?this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName}):void 0;return{ariaSnapshot:i,selector:o==null?void 0:o.selector,ref:a}}}class nh{constructor(e,i){this._hoverHighlight=null,this._action=null,this._recorder=e,this._textCache=new Map,this._kind=i,this._dialog=new rv(e)}cursor(){return"pointer"}uninstall(){this._dialog.close(),this._hoverHighlight=null}onClick(e){ze(e),this._kind==="value"?this._commitAssertValue():this._dialog.isShowing()||this._showDialog()}onMouseDown(e){const i=this._recorder.deepEventTarget(e);this._elementHasValue(i)&&e.preventDefault()}onPointerUp(e){var s;const i=(s=this._hoverHighlight)==null?void 0:s.elements[0];this._kind==="value"&&i&&(i.nodeName==="INPUT"||i.nodeName==="SELECT")&&i.disabled&&this._commitAssertValue()}onMouseMove(e){var s;if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);if(((s=this._hoverHighlight)==null?void 0:s.elements[0])!==i){if(this._kind==="text"||this._kind==="snapshot")this._hoverHighlight=this._recorder.injectedScript.utils.elementText(this._textCache,i).full?{elements:[i],selector:"",color:an.assert}:null;else if(this._elementHasValue(i)){const a=this._recorder.injectedScript.generateSelector(i,{testIdAttributeName:this._recorder.state.testIdAttributeName});this._hoverHighlight={selector:a.selector,elements:a.elements,color:an.assert}}else this._hoverHighlight=null;this._recorder.updateHighlight(this._hoverHighlight,!0)}}onKeyDown(e){e.key==="Escape"&&this._recorder.setMode("recording"),ze(e)}onScroll(e){this._recorder.updateHighlight(this._hoverHighlight,!1)}_elementHasValue(e){return e.nodeName==="TEXTAREA"||e.nodeName==="SELECT"||e.nodeName==="INPUT"&&!["button","image","reset","submit"].includes(e.type)}_generateAction(){var i;this._textCache.clear();const e=(i=this._hoverHighlight)==null?void 0:i.elements[0];if(!e)return null;if(this._kind==="value"){if(!this._elementHasValue(e))return null;const{selector:s}=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName});return e.nodeName==="INPUT"&&["checkbox","radio"].includes(e.type.toLowerCase())?{name:"assertChecked",selector:s,signals:[],checked:!e.checked}:{name:"assertValue",selector:s,signals:[],value:e.value}}else if(this._kind==="snapshot"){const s=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName,forTextExpect:!0});return this._hoverHighlight={selector:s.selector,elements:s.elements,color:an.assert},this._recorder.updateHighlight(this._hoverHighlight,!0),{name:"assertSnapshot",selector:this._hoverHighlight.selector,signals:[],ariaSnapshot:this._recorder.injectedScript.ariaSnapshot(e,{mode:"codegen"})}}else{const s=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName,forTextExpect:!0});return this._hoverHighlight={selector:s.selector,elements:s.elements,color:an.assert},this._recorder.updateHighlight(this._hoverHighlight,!0),{name:"assertText",selector:this._hoverHighlight.selector,signals:[],text:this._recorder.injectedScript.utils.elementText(this._textCache,e).normalized,substring:!0}}}_renderValue(e){return(e==null?void 0:e.name)==="assertText"?this._recorder.injectedScript.utils.normalizeWhiteSpace(e.text):(e==null?void 0:e.name)==="assertChecked"?String(e.checked):(e==null?void 0:e.name)==="assertValue"?e.value:(e==null?void 0:e.name)==="assertSnapshot"?e.ariaSnapshot:""}_commit(){!this._action||!this._dialog.isShowing()||(this._dialog.close(),this._recorder.recordAction(this._action),this._recorder.setMode("recording"))}_showDialog(){var e,i,s,a;(e=this._hoverHighlight)!=null&&e.elements[0]&&(this._action=this._generateAction(),((i=this._action)==null?void 0:i.name)==="assertText"?this._showTextDialog(this._action):((s=this._action)==null?void 0:s.name)==="assertSnapshot"&&(this._recorder.recordAction(this._action),this._recorder.setMode("recording"),(a=this._recorder.overlay)==null||a.flashToolSucceeded("assertingSnapshot")))}_showTextDialog(e){const i=this._recorder.document.createElement("textarea");i.setAttribute("spellcheck","false"),i.value=this._renderValue(e),i.classList.add("text-editor");const s=()=>{var y;const f=this._recorder.injectedScript.utils.normalizeWhiteSpace(i.value),d=(y=this._hoverHighlight)==null?void 0:y.elements[0];if(!d)return;e.text=f;const p=this._recorder.injectedScript.utils.elementText(this._textCache,d).normalized,m=f&&p.includes(f);i.classList.toggle("does-not-match",!m)};i.addEventListener("input",s);const o=this._dialog.show({label:"Assert that element contains text",body:i,onCommit:()=>this._commit()}),u=this._recorder.highlight.tooltipPosition(this._recorder.highlight.firstBox(),o);this._dialog.moveTo(u.anchorTop,u.anchorLeft),i.focus()}_commitAssertValue(){var i;if(this._kind!=="value")return;const e=this._generateAction();e&&(this._recorder.recordAction(e),this._recorder.setMode("recording"),(i=this._recorder.overlay)==null||i.flashToolSucceeded("assertingValue"))}}class eA{constructor(e){this._listeners=[],this._offsetX=0,this._measure={width:0,height:0},this._recorder=e;const i=this._recorder.document;this._overlayElement=i.createElement("x-pw-overlay");const s=i.createElement("x-pw-tools-list");this._overlayElement.appendChild(s),this._dragHandle=i.createElement("x-pw-tool-gripper"),this._dragHandle.appendChild(i.createElement("x-div")),s.appendChild(this._dragHandle),this._recordToggle=this._recorder.document.createElement("x-pw-tool-item"),this._recordToggle.title="Record",this._recordToggle.classList.add("record"),this._recordToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._recordToggle),this._pickLocatorToggle=this._recorder.document.createElement("x-pw-tool-item"),this._pickLocatorToggle.title="Pick locator",this._pickLocatorToggle.classList.add("pick-locator"),this._pickLocatorToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._pickLocatorToggle),this._assertVisibilityToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertVisibilityToggle.title="Assert visibility",this._assertVisibilityToggle.classList.add("visibility"),this._assertVisibilityToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertVisibilityToggle),this._assertTextToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertTextToggle.title="Assert text",this._assertTextToggle.classList.add("text"),this._assertTextToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertTextToggle),this._assertValuesToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertValuesToggle.title="Assert value",this._assertValuesToggle.classList.add("value"),this._assertValuesToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertValuesToggle),this._assertSnapshotToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertSnapshotToggle.title="Assert snapshot",this._assertSnapshotToggle.classList.add("snapshot"),this._assertSnapshotToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertSnapshotToggle),this._updateVisualPosition(),this._refreshListeners()}_refreshListeners(){av(this._listeners),this._listeners=[De(this._dragHandle,"mousedown",e=>{this._dragState={offsetX:this._offsetX,dragStart:{x:e.clientX,y:0}}}),De(this._recordToggle,"click",()=>{this._recordToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="none"||this._recorder.state.mode==="standby"||this._recorder.state.mode==="inspecting"?"recording":"standby")}),De(this._pickLocatorToggle,"click",()=>{if(this._pickLocatorToggle.classList.contains("disabled"))return;const e={inspecting:"standby",none:"inspecting",standby:"inspecting",recording:"recording-inspecting","recording-inspecting":"recording",assertingText:"recording-inspecting",assertingVisibility:"recording-inspecting",assertingValue:"recording-inspecting",assertingSnapshot:"recording-inspecting"};this._recorder.setMode(e[this._recorder.state.mode])}),De(this._assertVisibilityToggle,"click",()=>{this._assertVisibilityToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingVisibility"?"recording":"assertingVisibility")}),De(this._assertTextToggle,"click",()=>{this._assertTextToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingText"?"recording":"assertingText")}),De(this._assertValuesToggle,"click",()=>{this._assertValuesToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingValue"?"recording":"assertingValue")}),De(this._assertSnapshotToggle,"click",()=>{this._assertSnapshotToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingSnapshot"?"recording":"assertingSnapshot")})]}install(){this._recorder.highlight.appendChild(this._overlayElement),this._refreshListeners(),this._updateVisualPosition()}contains(e){return this._recorder.injectedScript.utils.isInsideScope(this._overlayElement,e)}setUIState(e){const i=e.mode==="recording"||e.mode==="assertingText"||e.mode==="assertingVisibility"||e.mode==="assertingValue"||e.mode==="assertingSnapshot"||e.mode==="recording-inspecting";this._recordToggle.classList.toggle("toggled",i),this._recordToggle.title=i?"Stop Recording":"Start Recording",this._pickLocatorToggle.classList.toggle("toggled",e.mode==="inspecting"||e.mode==="recording-inspecting"),this._assertVisibilityToggle.classList.toggle("toggled",e.mode==="assertingVisibility"),this._assertVisibilityToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertTextToggle.classList.toggle("toggled",e.mode==="assertingText"),this._assertTextToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertValuesToggle.classList.toggle("toggled",e.mode==="assertingValue"),this._assertValuesToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertSnapshotToggle.classList.toggle("toggled",e.mode==="assertingSnapshot"),this._assertSnapshotToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._offsetX!==e.overlay.offsetX&&(this._offsetX=e.overlay.offsetX,this._updateVisualPosition()),e.mode==="none"?this._hideOverlay():this._showOverlay()}flashToolSucceeded(e){let i;e==="assertingVisibility"?i=this._assertVisibilityToggle:e==="assertingSnapshot"?i=this._assertSnapshotToggle:i=this._assertValuesToggle,i.classList.add("succeeded"),this._recorder.injectedScript.utils.builtins.setTimeout(()=>i.classList.remove("succeeded"),2e3)}_hideOverlay(){this._overlayElement.setAttribute("hidden","true")}_showOverlay(){this._overlayElement.hasAttribute("hidden")&&(this._overlayElement.removeAttribute("hidden"),this._updateVisualPosition())}_updateVisualPosition(){this._measure=this._overlayElement.getBoundingClientRect(),this._overlayElement.style.left=(this._recorder.injectedScript.window.innerWidth-this._measure.width)/2+this._offsetX+"px"}onMouseMove(e){if(!e.buttons)return this._dragState=void 0,!1;if(this._dragState){this._offsetX=this._dragState.offsetX+e.clientX-this._dragState.dragStart.x;const i=(this._recorder.injectedScript.window.innerWidth-this._measure.width)/2-10;return this._offsetX=Math.max(-i,Math.min(i,this._offsetX)),this._updateVisualPosition(),this._recorder.setOverlayState({offsetX:this._offsetX}),ze(e),!0}return!1}onMouseUp(e){return this._dragState?(ze(e),!0):!1}onClick(e){return this._dragState?(this._dragState=void 0,ze(e),!0):!1}onDblClick(e){return!1}}class tA{constructor(e,i){var s,a;this._listeners=[],this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this.state={mode:"none",testIdAttributeName:"data-testid",language:"javascript",overlay:{offsetX:0}},this._delegate={},this.document=e.document,this.injectedScript=e,this.highlight=e.createHighlight(),this._tools={none:new i0,standby:new i0,inspecting:new th(this,!1),recording:(i==null?void 0:i.recorderMode)==="api"?new WE(this):new JE(this),"recording-inspecting":new th(this,!1),assertingText:new nh(this,"text"),assertingVisibility:new th(this,!0),assertingValue:new nh(this,"value"),assertingSnapshot:new nh(this,"snapshot")},this._currentTool=this._tools.none,(a=(s=this._currentTool).install)==null||a.call(s),e.window.top===e.window&&(this.overlay=new eA(this),this.overlay.setUIState(this.state)),this._stylesheet=new e.window.CSSStyleSheet,this._stylesheet.replaceSync(`
|
|
124
|
+
`)}finally{Vh(),oc(),this._evaluator.end()}}createStacklessError(e){if(this._browserName==="firefox"){const s=new Error("Error: "+e);return s.stack="",s}const i=new Error(e);return delete i.stack,i}createHighlight(){return new Zf(this)}maskSelectors(e,i){this._highlight&&this.hideHighlight(),this._highlight=new Zf(this),this._highlight.install();const s=[];for(const a of e)s.push(this.querySelectorAll(a,this.document.documentElement));this._highlight.maskElements(s.flat(),i)}highlight(e){this._highlight||(this._highlight=new Zf(this),this._highlight.install()),this._highlight.runHighlightOnRaf(e)}hideHighlight(){this._highlight&&(this._highlight.uninstall(),delete this._highlight)}markTargetElements(e,i){var u,f;((u=this._markedElements)==null?void 0:u.callId)!==i&&(this._markedElements=void 0);const s=((f=this._markedElements)==null?void 0:f.elements)||new Set,a=new CustomEvent("__playwright_unmark_target__",{bubbles:!0,cancelable:!0,detail:i,composed:!0});for(const d of s)e.has(d)||d.dispatchEvent(a);const o=new CustomEvent("__playwright_mark_target__",{bubbles:!0,cancelable:!0,detail:i,composed:!0});for(const d of e)s.has(d)||d.dispatchEvent(o);this._markedElements={callId:i,elements:e}}_setupGlobalListenersRemovalDetection(){const e="__playwright_global_listeners_check__";let i=!1;const s=()=>i=!0;this.window.addEventListener(e,s),new MutationObserver(a=>{if(a.some(u=>Array.from(u.addedNodes).includes(this.document.documentElement))&&(i=!1,this.window.dispatchEvent(new CustomEvent(e)),!i)){this.window.addEventListener(e,s);for(const u of this.onGlobalListenersRemoved)u()}}).observe(this.document,{childList:!0})}_setupHitTargetInterceptors(){const e=s=>{var a;return(a=this._hitTargetInterceptor)==null?void 0:a.call(this,s)},i=()=>{for(const s of this._allHitTargetInterceptorEvents)this.window.addEventListener(s,e,{capture:!0,passive:!1})};i(),this.onGlobalListenersRemoved.add(i)}async expect(e,i,s){var o,u;if(i.expression==="to.have.count"||i.expression.endsWith(".array"))return this.expectArray(s,i);if(!e){if(!i.isNot&&i.expression==="to.be.hidden")return{matches:!0};if(i.isNot&&i.expression==="to.be.visible")return{matches:!1};if(!i.isNot&&i.expression==="to.be.detached")return{matches:!0};if(i.isNot&&i.expression==="to.be.attached")return{matches:!1};if(i.isNot&&i.expression==="to.be.in.viewport")return{matches:!1};if(i.expression==="to.have.title"&&((o=i==null?void 0:i.expectedText)!=null&&o[0])){const f=new Qs(i.expectedText[0]),d=this.document.title;return{received:d,matches:f.matches(d)}}if(i.expression==="to.have.url"&&((u=i==null?void 0:i.expectedText)!=null&&u[0])){const f=new Qs(i.expectedText[0]),d=this.document.location.href;return{received:d,matches:f.matches(d)}}return{matches:i.isNot,missingReceived:!0}}return await this.expectSingleElement(e,i)}async expectSingleElement(e,i){var a;const s=i.expression;{let o;if(s==="to.have.attribute"){const u=e.hasAttribute(i.expressionArg);o={matches:u,received:u?"attribute present":"attribute not present"}}else if(s==="to.be.checked"){const{checked:u,indeterminate:f}=i.expectedValue;if(f){if(u!==void 0)throw this.createStacklessError("Can't assert indeterminate and checked at the same time");o=this.elementState(e,"indeterminate")}else o=this.elementState(e,u===!1?"unchecked":"checked")}else if(s==="to.be.disabled")o=this.elementState(e,"disabled");else if(s==="to.be.editable")o=this.elementState(e,"editable");else if(s==="to.be.readonly")o=this.elementState(e,"editable"),o.matches=!o.matches;else if(s==="to.be.empty")if(e.nodeName==="INPUT"||e.nodeName==="TEXTAREA"){const u=e.value;o={matches:!u,received:u?"notEmpty":"empty"}}else{const u=(a=e.textContent)==null?void 0:a.trim();o={matches:!u,received:u?"notEmpty":"empty"}}else if(s==="to.be.enabled")o=this.elementState(e,"enabled");else if(s==="to.be.focused"){const u=this._activelyFocused(e).isFocused;o={matches:u,received:u?"focused":"inactive"}}else s==="to.be.hidden"?o=this.elementState(e,"hidden"):s==="to.be.visible"?o=this.elementState(e,"visible"):s==="to.be.attached"?o={matches:!0,received:"attached"}:s==="to.be.detached"&&(o={matches:!1,received:"attached"});if(o){if(o.received==="error:notconnected")throw this.createStacklessError("Element is not connected");return o}}if(s==="to.have.property"){let o=e;const u=i.expressionArg.split(".");for(let p=0;p<u.length-1;p++){if(typeof o!="object"||!(u[p]in o))return{received:void 0,matches:!1};o=o[u[p]]}const f=o[u[u.length-1]],d=wh(f,i.expectedValue);return{received:f,matches:d}}if(s==="to.be.in.viewport"){const o=await this.viewportRatio(e);return{received:`viewport ratio ${o}`,matches:o>0&&o>(i.expectedNumber??0)-1e-9}}if(s==="to.have.values"){if(e=this.retarget(e,"follow-label"),e.nodeName!=="SELECT"||!e.multiple)throw this.createStacklessError("Not a select element with a multiple attribute");const o=[...e.selectedOptions].map(u=>u.value);return o.length!==i.expectedText.length?{received:o,matches:!1}:{received:o,matches:o.map((u,f)=>new Qs(i.expectedText[f]).matches(u)).every(Boolean)}}if(s==="to.match.aria"){const o=LT(e,i.expectedValue);return{received:o.received,matches:!!o.matches.length}}{let o;if(s==="to.have.attribute.value"){const u=e.getAttribute(i.expressionArg);if(u===null)return{received:null,matches:!1};o=u}else if(["to.have.class","to.contain.class"].includes(s)){if(!i.expectedText)throw this.createStacklessError("Expected text is not provided for "+s);return{received:e.classList.toString(),matches:new Qs(i.expectedText[0]).matchesClassList(this,e.classList,s==="to.contain.class")}}else if(s==="to.have.css")o=this.window.getComputedStyle(e).getPropertyValue(i.expressionArg);else if(s==="to.have.id")o=e.id;else if(s==="to.have.text")o=i.useInnerText?e.innerText:Bt(new Map,e).full;else if(s==="to.have.accessible.name")o=Qa(e,!1);else if(s==="to.have.accessible.description")o=Gy(e,!1);else if(s==="to.have.accessible.error.message")o=yT(e);else if(s==="to.have.role")o=ft(e)||"";else if(s==="to.have.value"){if(e=this.retarget(e,"follow-label"),e.nodeName!=="INPUT"&&e.nodeName!=="TEXTAREA"&&e.nodeName!=="SELECT")throw this.createStacklessError("Not an input element");o=e.value}if(o!==void 0&&i.expectedText){const u=new Qs(i.expectedText[0]);return{received:o,matches:u.matches(o)}}}throw this.createStacklessError("Unknown expect matcher: "+s)}expectArray(e,i){const s=i.expression;if(s==="to.have.count"){const d=e.length,p=d===i.expectedNumber;return{received:d,matches:p}}if(!i.expectedText)throw this.createStacklessError("Expected text is not provided for "+s);if(["to.have.class.array","to.contain.class.array"].includes(s)){const d=e.map(y=>y.classList),p=d.map(String);if(d.length!==i.expectedText.length)return{received:p,matches:!1};const m=this._matchSequentially(i.expectedText,d,(y,b)=>y.matchesClassList(this,b,s==="to.contain.class.array"));return{received:p,matches:m}}if(!["to.contain.text.array","to.have.text.array"].includes(s))throw this.createStacklessError("Unknown expect matcher: "+s);const a=e.map(d=>i.useInnerText?d.innerText:Bt(new Map,d).full),o=s!=="to.contain.text.array";if(!(a.length===i.expectedText.length||!o))return{received:a,matches:!1};const f=this._matchSequentially(i.expectedText,a,(d,p)=>d.matches(p));return{received:a,matches:f}}_matchSequentially(e,i,s){const a=e.map(f=>new Qs(f));let o=0,u=0;for(;o<a.length&&u<i.length;)s(a[o],i[u])&&++o,++u;return o===a.length}}function xo(n){return n.replace(/\n/g,"↵").replace(/\t/g,"⇆")}function ZE(n){if(n=n.substring(1,n.length-1),!n.includes("\\"))return n;const e=[];let i=0;for(;i<n.length;)n[i]==="\\"&&i+1<n.length&&i++,e.push(n[i++]);return e.join("")}function _o(n,e){if(n[0]==="/"&&n.lastIndexOf("/")>0){const a=n.lastIndexOf("/"),o=new RegExp(n.substring(1,a),n.substring(a+1));return{matcher:u=>o.test(u.full),kind:"regex"}}const i=e?JSON.parse.bind(JSON):ZE;let s=!1;return n.length>1&&n[0]==='"'&&n[n.length-1]==='"'?(n=i(n),s=!0):e&&n.length>1&&n[0]==='"'&&n[n.length-2]==='"'&&n[n.length-1]==="i"?(n=i(n.substring(0,n.length-1)),s=!1):e&&n.length>1&&n[0]==='"'&&n[n.length-2]==='"'&&n[n.length-1]==="s"?(n=i(n.substring(0,n.length-1)),s=!0):n.length>1&&n[0]==="'"&&n[n.length-1]==="'"&&(n=i(n),s=!0),n=Tt(n),s?e?{kind:"strict",matcher:o=>o.normalized===n}:{matcher:o=>!n&&!o.immediate.length?!0:o.immediate.some(u=>Tt(u)===n),kind:"strict"}:(n=n.toLowerCase(),{kind:"lax",matcher:a=>a.normalized.toLowerCase().includes(n)})}class Qs{constructor(e){if(this._normalizeWhiteSpace=e.normalizeWhiteSpace,this._ignoreCase=e.ignoreCase,this._string=e.matchSubstring?void 0:this.normalize(e.string),this._substring=e.matchSubstring?this.normalize(e.string):void 0,e.regexSource){const i=new Set((e.regexFlags||"").split(""));e.ignoreCase===!1&&i.delete("i"),e.ignoreCase===!0&&i.add("i"),this._regex=new RegExp(e.regexSource,[...i].join(""))}}matches(e){return this._regex||(e=this.normalize(e)),this._string!==void 0?e===this._string:this._substring!==void 0?e.includes(this._substring):this._regex?!!this._regex.test(e):!1}matchesClassList(e,i,s){if(s){if(this._regex)throw e.createStacklessError("Partial matching does not support regular expressions. Please provide a string value.");return this._string.split(/\s+/g).filter(Boolean).every(a=>i.contains(a))}return this.matches(i.toString())}normalize(e){return e&&(this._normalizeWhiteSpace&&(e=Tt(e)),this._ignoreCase&&(e=e.toLocaleLowerCase()),e)}}function wh(n,e){if(n===e)return!0;if(n&&e&&typeof n=="object"&&typeof e=="object"){if(n.constructor!==e.constructor)return!1;if(Array.isArray(n)){if(n.length!==e.length)return!1;for(let s=0;s<n.length;++s)if(!wh(n[s],e[s]))return!1;return!0}if(n instanceof RegExp)return n.source===e.source&&n.flags===e.flags;if(n.valueOf!==Object.prototype.valueOf)return n.valueOf()===e.valueOf();if(n.toString!==Object.prototype.toString)return n.toString()===e.toString();const i=Object.keys(n);if(i.length!==Object.keys(e).length)return!1;for(let s=0;s<i.length;++s)if(!e.hasOwnProperty(i[s]))return!1;for(const s of i)if(!wh(n[s],e[s]))return!1;return!0}return typeof n=="number"&&typeof e=="number"?isNaN(n)&&isNaN(e):!1}const JE={tagName:"svg",children:[{tagName:"defs",children:[{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-gripper"},children:[{tagName:"path",attrs:{d:"M5 3h2v2H5zm0 4h2v2H5zm0 4h2v2H5zm4-8h2v2H9zm0 4h2v2H9zm0 4h2v2H9z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-circle-large-filled"},children:[{tagName:"path",attrs:{d:"M8 1a6.8 6.8 0 0 1 1.86.253 6.899 6.899 0 0 1 3.083 1.805 6.903 6.903 0 0 1 1.804 3.083C14.916 6.738 15 7.357 15 8s-.084 1.262-.253 1.86a6.9 6.9 0 0 1-.704 1.674 7.157 7.157 0 0 1-2.516 2.509 6.966 6.966 0 0 1-1.668.71A6.984 6.984 0 0 1 8 15a6.984 6.984 0 0 1-1.86-.246 7.098 7.098 0 0 1-1.674-.711 7.3 7.3 0 0 1-1.415-1.094 7.295 7.295 0 0 1-1.094-1.415 7.098 7.098 0 0 1-.71-1.675A6.985 6.985 0 0 1 1 8c0-.643.082-1.262.246-1.86a6.968 6.968 0 0 1 .711-1.667 7.156 7.156 0 0 1 2.509-2.516 6.895 6.895 0 0 1 1.675-.704A6.808 6.808 0 0 1 8 1z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-stop-circle"},children:[{tagName:"path",attrs:{d:"M6 6h4v4H6z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-inspect"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M1 3l1-1h12l1 1v6h-1V3H2v8h5v1H2l-1-1V3zm14.707 9.707L9 6v9.414l2.707-2.707h4zM10 13V8.414l3.293 3.293h-2L10 13z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-whole-word"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M0 11H1V13H15V11H16V14H15H1H0V11Z"}},{tagName:"path",attrs:{d:"M6.84048 11H5.95963V10.1406H5.93814C5.555 10.7995 4.99104 11.1289 4.24625 11.1289C3.69839 11.1289 3.26871 10.9839 2.95718 10.6938C2.64924 10.4038 2.49527 10.0189 2.49527 9.53906C2.49527 8.51139 3.10041 7.91341 4.3107 7.74512L5.95963 7.51416C5.95963 6.57959 5.58186 6.1123 4.82632 6.1123C4.16389 6.1123 3.56591 6.33789 3.03238 6.78906V5.88672C3.57307 5.54297 4.19612 5.37109 4.90152 5.37109C6.19416 5.37109 6.84048 6.05501 6.84048 7.42285V11ZM5.95963 8.21777L4.63297 8.40039C4.22476 8.45768 3.91682 8.55973 3.70914 8.70654C3.50145 8.84977 3.39761 9.10579 3.39761 9.47461C3.39761 9.74316 3.4925 9.96338 3.68228 10.1353C3.87564 10.3035 4.13166 10.3877 4.45035 10.3877C4.8872 10.3877 5.24706 10.2355 5.52994 9.93115C5.8164 9.62321 5.95963 9.2347 5.95963 8.76562V8.21777Z"}},{tagName:"path",attrs:{d:"M9.3475 10.2051H9.32601V11H8.44515V2.85742H9.32601V6.4668H9.3475C9.78076 5.73633 10.4146 5.37109 11.2489 5.37109C11.9543 5.37109 12.5057 5.61816 12.9032 6.1123C13.3042 6.60286 13.5047 7.26172 13.5047 8.08887C13.5047 9.00911 13.2809 9.74674 12.8333 10.3018C12.3857 10.8532 11.7734 11.1289 10.9964 11.1289C10.2695 11.1289 9.71989 10.821 9.3475 10.2051ZM9.32601 7.98682V8.75488C9.32601 9.20964 9.47282 9.59635 9.76644 9.91504C10.0636 10.2301 10.4396 10.3877 10.8944 10.3877C11.4279 10.3877 11.8451 10.1836 12.1458 9.77539C12.4502 9.36719 12.6024 8.79964 12.6024 8.07275C12.6024 7.46045 12.4609 6.98063 12.1781 6.6333C11.8952 6.28597 11.512 6.1123 11.0286 6.1123C10.5166 6.1123 10.1048 6.29134 9.7933 6.64941C9.48177 7.00391 9.32601 7.44971 9.32601 7.98682Z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-eye"},children:[{tagName:"path",attrs:{d:"M7.99993 6.00316C9.47266 6.00316 10.6666 7.19708 10.6666 8.66981C10.6666 10.1426 9.47266 11.3365 7.99993 11.3365C6.52715 11.3365 5.33324 10.1426 5.33324 8.66981C5.33324 7.19708 6.52715 6.00316 7.99993 6.00316ZM7.99993 7.00315C7.07946 7.00315 6.33324 7.74935 6.33324 8.66981C6.33324 9.59028 7.07946 10.3365 7.99993 10.3365C8.9204 10.3365 9.6666 9.59028 9.6666 8.66981C9.6666 7.74935 8.9204 7.00315 7.99993 7.00315ZM7.99993 3.66675C11.0756 3.66675 13.7307 5.76675 14.4673 8.70968C14.5344 8.97755 14.3716 9.24908 14.1037 9.31615C13.8358 9.38315 13.5643 9.22041 13.4973 8.95248C12.8713 6.45205 10.6141 4.66675 7.99993 4.66675C5.38454 4.66675 3.12664 6.45359 2.50182 8.95555C2.43491 9.22341 2.16348 9.38635 1.89557 9.31948C1.62766 9.25255 1.46471 8.98115 1.53162 8.71321C2.26701 5.76856 4.9229 3.66675 7.99993 3.66675Z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-symbol-constant"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M4 6h8v1H4V6zm8 3H4v1h8V9z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M1 4l1-1h12l1 1v8l-1 1H2l-1-1V4zm1 0v8h12V4H2z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-check"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M14.431 3.323l-8.47 10-.79-.036-3.35-4.77.818-.574 2.978 4.24 8.051-9.506.764.646z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-close"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8 8.707l3.646 3.647.708-.707L8.707 8l3.647-3.646-.707-.708L8 7.293 4.354 3.646l-.707.708L7.293 8l-3.646 3.646.707.708L8 8.707z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-pass"},children:[{tagName:"path",attrs:{d:"M6.27 10.87h.71l4.56-4.56-.71-.71-4.2 4.21-1.92-1.92L4 8.6l2.27 2.27z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-gist"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M10.57 1.14l3.28 3.3.15.36v9.7l-.5.5h-11l-.5-.5v-13l.5-.5h7.72l.35.14zM10 5h3l-3-3v3zM3 2v12h10V6H9.5L9 5.5V2H3zm2.062 7.533l1.817-1.828L6.17 7 4 9.179v.707l2.171 2.174.707-.707-1.816-1.82zM8.8 7.714l.7-.709 2.189 2.175v.709L9.5 12.062l-.705-.709 1.831-1.82L8.8 7.714z"}}]}]}]},an={multiple:"#f6b26b7f",single:"#6fa8dc7f",assert:"#8acae480",action:"#dc6f6f7f"};class i0{}class th{constructor(e,i){this._hoveredModel=null,this._hoveredElement=null,this._recorder=e,this._assertVisibility=i}cursor(){return"pointer"}uninstall(){this._hoveredModel=null,this._hoveredElement=null}onClick(e){var i;ze(e),e.button===0&&(i=this._hoveredModel)!=null&&i.selector&&this._commit(this._hoveredModel.selector,this._hoveredModel)}onPointerDown(e){ze(e)}onPointerUp(e){ze(e)}onMouseDown(e){ze(e)}onMouseUp(e){ze(e)}onMouseMove(e){var a;ze(e);let i=this._recorder.deepEventTarget(e);if(i.isConnected||(i=null),this._hoveredElement===i)return;this._hoveredElement=i;let s=null;if(this._hoveredElement){const o=this._recorder.injectedScript.generateSelector(this._hoveredElement,{testIdAttributeName:this._recorder.state.testIdAttributeName,multiple:!1});s={selector:o.selector,elements:o.elements,tooltipText:this._recorder.injectedScript.utils.asLocator(this._recorder.state.language,o.selector),color:this._assertVisibility?an.assert:an.single}}((a=this._hoveredModel)==null?void 0:a.selector)!==(s==null?void 0:s.selector)&&(this._hoveredModel=s,this._recorder.updateHighlight(s,!0))}onMouseEnter(e){ze(e)}onMouseLeave(e){ze(e);const i=this._recorder.injectedScript.window;i.top!==i&&this._recorder.deepEventTarget(e).nodeType===Node.DOCUMENT_NODE&&this._reset(!0)}onKeyDown(e){ze(e),e.key==="Escape"&&this._assertVisibility&&this._recorder.setMode("recording")}onKeyUp(e){ze(e)}onScroll(e){this._reset(!1)}_commit(e,i){var s;this._assertVisibility?(this._recorder.recordAction({name:"assertVisible",selector:e,signals:[]}),this._recorder.setMode("recording"),(s=this._recorder.overlay)==null||s.flashToolSucceeded("assertingVisibility")):this._recorder.elementPicked(e,i)}_reset(e){this._hoveredElement=null,this._hoveredModel=null,this._recorder.updateHighlight(null,e)}}class WE{constructor(e){this._hoveredModel=null,this._hoveredElement=null,this._activeModel=null,this._expectProgrammaticKeyUp=!1,this._observer=null,this._recorder=e,this._performingActions=new Set,this._dialog=new av(e)}cursor(){return"pointer"}_installObserverIfNeeded(){var e;this._observer||(e=this._recorder.injectedScript.document)!=null&&e.body&&(this._observer=new MutationObserver(i=>{if(this._hoveredElement)for(const s of i)for(const a of s.removedNodes)(a===this._hoveredElement||a.contains(this._hoveredElement))&&this._resetHoveredModel()}),this._observer.observe(this._recorder.injectedScript.document.body,{childList:!0,subtree:!0}))}uninstall(){var e;(e=this._observer)==null||e.disconnect(),this._observer=null,this._hoveredModel=null,this._hoveredElement=null,this._activeModel=null,this._expectProgrammaticKeyUp=!1,this._dialog.close()}onClick(e){if(this._dialog.isShowing()){e.button===2&&e.type==="auxclick"&&ze(e);return}if(Ya(this._hoveredElement)||this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel))return;if(e.button===2&&e.type==="auxclick"){this._showActionListDialog(this._hoveredModel,e);return}const i=Ka(this._recorder.deepEventTarget(e));if(i&&e.detail===1){this._performAction({name:i.checked?"check":"uncheck",selector:this._hoveredModel.selector,signals:[]});return}this._cancelPendingClickAction(),e.detail===1&&(this._pendingClickAction={action:{name:"click",selector:this._hoveredModel.selector,position:Ga(e),signals:[],button:xh(e),modifiers:lr(e),clickCount:e.detail},timeout:this._recorder.injectedScript.utils.builtins.setTimeout(()=>this._commitPendingClickAction(),200)})}onDblClick(e){this._dialog.isShowing()||Ya(this._hoveredElement)||this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel)||(this._cancelPendingClickAction(),this._performAction({name:"click",selector:this._hoveredModel.selector,position:Ga(e),signals:[],button:xh(e),modifiers:lr(e),clickCount:e.detail}))}_commitPendingClickAction(){this._pendingClickAction&&this._performAction(this._pendingClickAction.action),this._cancelPendingClickAction()}_cancelPendingClickAction(){this._pendingClickAction&&this._recorder.injectedScript.utils.builtins.clearTimeout(this._pendingClickAction.timeout),this._pendingClickAction=void 0}onContextMenu(e){if(this._dialog.isShowing()){ze(e);return}this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel)||this._showActionListDialog(this._hoveredModel,e)}onPointerDown(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onPointerUp(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onMouseDown(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||(this._consumeWhenAboutToPerform(e),this._activeModel=this._hoveredModel)}onMouseUp(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onMouseMove(e){if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);this._hoveredElement!==i&&(this._hoveredElement=i,this._updateModelForHoveredElement())}onMouseLeave(e){if(this._dialog.isShowing())return;const i=this._recorder.injectedScript.window;i.top!==i&&this._recorder.deepEventTarget(e).nodeType===Node.DOCUMENT_NODE&&(this._hoveredElement=null,this._updateModelForHoveredElement())}onFocus(e){this._dialog.isShowing()||this._onFocus(!0)}onInput(e){if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);if(i.nodeName==="INPUT"&&i.type.toLowerCase()==="file"){this._recordAction({name:"setInputFiles",selector:this._activeModel.selector,signals:[],files:[...i.files||[]].map(s=>s.name)});return}if(Ya(i)){this._recordAction({name:"fill",selector:this._hoveredModel.selector,signals:[],text:i.value});return}if(["INPUT","TEXTAREA"].includes(i.nodeName)||i.isContentEditable){if(i.nodeName==="INPUT"&&["checkbox","radio"].includes(i.type.toLowerCase())||this._consumedDueWrongTarget(e))return;this._recordAction({name:"fill",selector:this._activeModel.selector,signals:[],text:i.isContentEditable?i.innerText:i.value})}if(i.nodeName==="SELECT"){const s=i;this._recordAction({name:"select",selector:this._activeModel.selector,options:[...s.selectedOptions].map(a=>a.value),signals:[]})}}onKeyDown(e){if(!this._dialog.isShowing()&&this._shouldGenerateKeyPressFor(e)){if(this._actionInProgress(e)){this._expectProgrammaticKeyUp=!0;return}if(!this._consumedDueWrongTarget(e)){if(e.key===" "){const i=Ka(this._recorder.deepEventTarget(e));if(i&&e.detail===0){this._performAction({name:i.checked?"uncheck":"check",selector:this._activeModel.selector,signals:[]});return}}this._performAction({name:"press",selector:this._activeModel.selector,signals:[],key:e.key,modifiers:lr(e)})}}}onKeyUp(e){if(!this._dialog.isShowing()&&this._shouldGenerateKeyPressFor(e)){if(!this._expectProgrammaticKeyUp){ze(e);return}this._expectProgrammaticKeyUp=!1}}onScroll(e){this._dialog.isShowing()||this._resetHoveredModel()}_showActionListDialog(e,i){ze(i);const s=Ga(i),a=[{title:"Click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"left",modifiers:0,clickCount:0})},{title:"Right click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"right",modifiers:0,clickCount:0})},{title:"Double click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"left",modifiers:0,clickCount:2})},{title:"Hover",cb:()=>this._performAction({name:"hover",selector:e.selector,position:s,signals:[]})},{title:"Pick locator",cb:()=>this._recorder.elementPicked(e.selector,e)}],o=this._recorder.document.createElement("x-pw-action-list");o.setAttribute("role","list"),o.setAttribute("aria-label","Choose action");for(const p of a){const m=this._recorder.document.createElement("x-pw-action-item");m.setAttribute("role","listitem"),m.textContent=p.title,m.setAttribute("aria-label",p.title),m.addEventListener("click",()=>{this._dialog.close(),p.cb()}),o.appendChild(m)}const u=this._dialog.show({label:"Choose action",body:o,autosize:!0}),f=this._recorder.highlight.firstTooltipBox()||e.elements[0].getBoundingClientRect(),d=this._recorder.highlight.tooltipPosition(f,u);this._dialog.moveTo(d.anchorTop,d.anchorLeft)}_resetHoveredModel(){this._hoveredModel=null,this._hoveredElement=null,this._updateHighlight(!1)}_onFocus(e){const i=iA(this._recorder.document);if(e&&i===this._recorder.document.body)return;const s=i?this._recorder.injectedScript.generateSelector(i,{testIdAttributeName:this._recorder.state.testIdAttributeName}):null;this._activeModel=s&&s.selector?{...s,color:an.action}:null,e&&(this._hoveredElement=i,this._updateModelForHoveredElement())}_shouldIgnoreMouseEvent(e){const i=this._recorder.deepEventTarget(e),s=i.nodeName;return!!(s==="SELECT"||s==="OPTION"||s==="INPUT"&&["date","range"].includes(i.type))}_actionInProgress(e){const i=e instanceof KeyboardEvent,s=e instanceof MouseEvent||e instanceof PointerEvent;for(const a of this._performingActions)if(i&&a.name==="press"&&e.key===a.key||s&&(a.name==="click"||a.name==="hover"||a.name==="check"||a.name==="uncheck"))return!0;return ze(e),!1}_consumedDueToNoModel(e,i){return i?!1:(ze(e),!0)}_consumedDueWrongTarget(e){return this._activeModel&&this._activeModel.elements[0]===this._recorder.deepEventTarget(e)?!1:(ze(e),!0)}_consumeWhenAboutToPerform(e){this._performingActions.size||ze(e)}_recordAction(e){this._recorder.recordAction(e)}_performAction(e){this._recorder.updateHighlight(null,!1),this._performingActions.add(e);const i=this._recorder.performAction(e).then(()=>{this._performingActions.delete(e),this._onFocus(!1)});this._recorder.injectedScript.isUnderTest&&i.then(()=>{console.error("Action performed for test: "+JSON.stringify({hovered:this._hoveredModel?this._hoveredModel.selector:null,active:this._activeModel?this._activeModel.selector:null}))})}_shouldGenerateKeyPressFor(e){if(typeof e.key!="string"||e.key==="Enter"&&(this._recorder.deepEventTarget(e).nodeName==="TEXTAREA"||this._recorder.deepEventTarget(e).isContentEditable)||["Backspace","Delete","AltGraph"].includes(e.key)||e.key==="@"&&e.code==="KeyL")return!1;if(navigator.platform.includes("Mac")){if(e.key==="v"&&e.metaKey)return!1}else if(e.key==="v"&&e.ctrlKey||e.key==="Insert"&&e.shiftKey)return!1;if(["Shift","Control","Meta","Alt","Process"].includes(e.key))return!1;const i=e.ctrlKey||e.altKey||e.metaKey;return e.key.length===1&&!i?!!Ka(this._recorder.deepEventTarget(e)):!0}_updateModelForHoveredElement(){if(this._installObserverIfNeeded(),this._performingActions.size)return;if(!this._hoveredElement||!this._hoveredElement.isConnected){this._hoveredModel=null,this._hoveredElement=null,this._updateHighlight(!0);return}const{selector:e,elements:i}=this._recorder.injectedScript.generateSelector(this._hoveredElement,{testIdAttributeName:this._recorder.state.testIdAttributeName});this._hoveredModel&&this._hoveredModel.selector===e||(this._hoveredModel=e?{selector:e,elements:i,color:an.action}:null,this._updateHighlight(!0))}_updateHighlight(e){this._recorder.updateHighlight(this._hoveredModel,e)}}class eA{constructor(e){this._recorder=e}install(){this._recorder.highlight.uninstall()}uninstall(){this._recorder.highlight.install()}onClick(e){const i=this._recorder.deepEventTarget(e);if(Ya(i)||e.button===2&&e.type==="auxclick"||this._shouldIgnoreMouseEvent(e))return;const s=Ka(i),{ariaSnapshot:a,selector:o,ref:u}=this._ariaSnapshot(i);if(s&&e.detail===1){this._recorder.recordAction({name:s.checked?"check":"uncheck",selector:o,ref:u,signals:[],ariaSnapshot:a});return}this._recorder.recordAction({name:"click",selector:o,ref:u,ariaSnapshot:a,position:Ga(e),signals:[],button:xh(e),modifiers:lr(e),clickCount:e.detail})}onContextMenu(e){const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);this._recorder.recordAction({name:"click",selector:a,ref:o,ariaSnapshot:s,position:Ga(e),signals:[],button:"right",modifiers:lr(e),clickCount:1})}onInput(e){const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);if(Ya(i)){this._recorder.recordAction({name:"fill",selector:a,ref:o,ariaSnapshot:s,signals:[],text:i.value});return}if(["INPUT","TEXTAREA"].includes(i.nodeName)||i.isContentEditable){if(i.nodeName==="INPUT"&&["checkbox","radio"].includes(i.type.toLowerCase()))return;this._recorder.recordAction({name:"fill",ref:o,selector:a,ariaSnapshot:s,signals:[],text:i.isContentEditable?i.innerText:i.value});return}if(i.nodeName==="SELECT"){const u=i;this._recorder.recordAction({name:"select",selector:a,ref:o,ariaSnapshot:s,options:[...u.selectedOptions].map(f=>f.value),signals:[]});return}}onKeyDown(e){if(!this._shouldGenerateKeyPressFor(e))return;const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);if(e.key===" "){const u=Ka(i);if(u&&e.detail===0){this._recorder.recordAction({name:u.checked?"uncheck":"check",selector:a,ref:o,ariaSnapshot:s,signals:[]});return}}this._recorder.recordAction({name:"press",selector:a,ref:o,ariaSnapshot:s,signals:[],key:e.key,modifiers:lr(e)})}_shouldIgnoreMouseEvent(e){const i=this._recorder.deepEventTarget(e),s=i.nodeName;return!!(s==="SELECT"||s==="OPTION"||s==="INPUT"&&["date","range"].includes(i.type))}_shouldGenerateKeyPressFor(e){if(typeof e.key!="string"||e.key==="Enter"&&(this._recorder.deepEventTarget(e).nodeName==="TEXTAREA"||this._recorder.deepEventTarget(e).isContentEditable)||["Backspace","Delete","AltGraph"].includes(e.key)||e.key==="@"&&e.code==="KeyL")return!1;if(navigator.platform.includes("Mac")){if(e.key==="v"&&e.metaKey)return!1}else if(e.key==="v"&&e.ctrlKey||e.key==="Insert"&&e.shiftKey)return!1;if(["Shift","Control","Meta","Alt","Process"].includes(e.key))return!1;const i=e.ctrlKey||e.altKey||e.metaKey;return e.key.length===1&&!i?!this._isEditable(this._recorder.deepEventTarget(e)):!0}_isEditable(e){return!!(e.nodeName==="TEXTAREA"||e.nodeName==="INPUT"||e.isContentEditable)}_ariaSnapshot(e){const{ariaSnapshot:i,refs:s}=this._recorder.injectedScript.ariaSnapshotForRecorder(),a=e?s.get(e):void 0,o=e?this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName}):void 0;return{ariaSnapshot:i,selector:o==null?void 0:o.selector,ref:a}}}class nh{constructor(e,i){this._hoverHighlight=null,this._action=null,this._recorder=e,this._textCache=new Map,this._kind=i,this._dialog=new av(e)}cursor(){return"pointer"}uninstall(){this._dialog.close(),this._hoverHighlight=null}onClick(e){ze(e),this._kind==="value"?this._commitAssertValue():this._dialog.isShowing()||this._showDialog()}onMouseDown(e){const i=this._recorder.deepEventTarget(e);this._elementHasValue(i)&&e.preventDefault()}onPointerUp(e){var s;const i=(s=this._hoverHighlight)==null?void 0:s.elements[0];this._kind==="value"&&i&&(i.nodeName==="INPUT"||i.nodeName==="SELECT")&&i.disabled&&this._commitAssertValue()}onMouseMove(e){var s;if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);if(((s=this._hoverHighlight)==null?void 0:s.elements[0])!==i){if(this._kind==="text"||this._kind==="snapshot")this._hoverHighlight=this._recorder.injectedScript.utils.elementText(this._textCache,i).full?{elements:[i],selector:"",color:an.assert}:null;else if(this._elementHasValue(i)){const a=this._recorder.injectedScript.generateSelector(i,{testIdAttributeName:this._recorder.state.testIdAttributeName});this._hoverHighlight={selector:a.selector,elements:a.elements,color:an.assert}}else this._hoverHighlight=null;this._recorder.updateHighlight(this._hoverHighlight,!0)}}onKeyDown(e){e.key==="Escape"&&this._recorder.setMode("recording"),ze(e)}onScroll(e){this._recorder.updateHighlight(this._hoverHighlight,!1)}_elementHasValue(e){return e.nodeName==="TEXTAREA"||e.nodeName==="SELECT"||e.nodeName==="INPUT"&&!["button","image","reset","submit"].includes(e.type)}_generateAction(){var i;this._textCache.clear();const e=(i=this._hoverHighlight)==null?void 0:i.elements[0];if(!e)return null;if(this._kind==="value"){if(!this._elementHasValue(e))return null;const{selector:s}=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName});return e.nodeName==="INPUT"&&["checkbox","radio"].includes(e.type.toLowerCase())?{name:"assertChecked",selector:s,signals:[],checked:!e.checked}:{name:"assertValue",selector:s,signals:[],value:e.value}}else if(this._kind==="snapshot"){const s=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName,forTextExpect:!0});return this._hoverHighlight={selector:s.selector,elements:s.elements,color:an.assert},this._recorder.updateHighlight(this._hoverHighlight,!0),{name:"assertSnapshot",selector:this._hoverHighlight.selector,signals:[],ariaSnapshot:this._recorder.injectedScript.ariaSnapshot(e,{mode:"codegen"})}}else{const s=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName,forTextExpect:!0});return this._hoverHighlight={selector:s.selector,elements:s.elements,color:an.assert},this._recorder.updateHighlight(this._hoverHighlight,!0),{name:"assertText",selector:this._hoverHighlight.selector,signals:[],text:this._recorder.injectedScript.utils.elementText(this._textCache,e).normalized,substring:!0}}}_renderValue(e){return(e==null?void 0:e.name)==="assertText"?this._recorder.injectedScript.utils.normalizeWhiteSpace(e.text):(e==null?void 0:e.name)==="assertChecked"?String(e.checked):(e==null?void 0:e.name)==="assertValue"?e.value:(e==null?void 0:e.name)==="assertSnapshot"?e.ariaSnapshot:""}_commit(){!this._action||!this._dialog.isShowing()||(this._dialog.close(),this._recorder.recordAction(this._action),this._recorder.setMode("recording"))}_showDialog(){var e,i,s,a;(e=this._hoverHighlight)!=null&&e.elements[0]&&(this._action=this._generateAction(),((i=this._action)==null?void 0:i.name)==="assertText"?this._showTextDialog(this._action):((s=this._action)==null?void 0:s.name)==="assertSnapshot"&&(this._recorder.recordAction(this._action),this._recorder.setMode("recording"),(a=this._recorder.overlay)==null||a.flashToolSucceeded("assertingSnapshot")))}_showTextDialog(e){const i=this._recorder.document.createElement("textarea");i.setAttribute("spellcheck","false"),i.value=this._renderValue(e),i.classList.add("text-editor");const s=()=>{var y;const f=this._recorder.injectedScript.utils.normalizeWhiteSpace(i.value),d=(y=this._hoverHighlight)==null?void 0:y.elements[0];if(!d)return;e.text=f;const p=this._recorder.injectedScript.utils.elementText(this._textCache,d).normalized,m=f&&p.includes(f);i.classList.toggle("does-not-match",!m)};i.addEventListener("input",s);const o=this._dialog.show({label:"Assert that element contains text",body:i,onCommit:()=>this._commit()}),u=this._recorder.highlight.tooltipPosition(this._recorder.highlight.firstBox(),o);this._dialog.moveTo(u.anchorTop,u.anchorLeft),i.focus()}_commitAssertValue(){var i;if(this._kind!=="value")return;const e=this._generateAction();e&&(this._recorder.recordAction(e),this._recorder.setMode("recording"),(i=this._recorder.overlay)==null||i.flashToolSucceeded("assertingValue"))}}class tA{constructor(e){this._listeners=[],this._offsetX=0,this._measure={width:0,height:0},this._recorder=e;const i=this._recorder.document;this._overlayElement=i.createElement("x-pw-overlay");const s=i.createElement("x-pw-tools-list");this._overlayElement.appendChild(s),this._dragHandle=i.createElement("x-pw-tool-gripper"),this._dragHandle.appendChild(i.createElement("x-div")),s.appendChild(this._dragHandle),this._recordToggle=this._recorder.document.createElement("x-pw-tool-item"),this._recordToggle.title="Record",this._recordToggle.classList.add("record"),this._recordToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._recordToggle),this._pickLocatorToggle=this._recorder.document.createElement("x-pw-tool-item"),this._pickLocatorToggle.title="Pick locator",this._pickLocatorToggle.classList.add("pick-locator"),this._pickLocatorToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._pickLocatorToggle),this._assertVisibilityToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertVisibilityToggle.title="Assert visibility",this._assertVisibilityToggle.classList.add("visibility"),this._assertVisibilityToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertVisibilityToggle),this._assertTextToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertTextToggle.title="Assert text",this._assertTextToggle.classList.add("text"),this._assertTextToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertTextToggle),this._assertValuesToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertValuesToggle.title="Assert value",this._assertValuesToggle.classList.add("value"),this._assertValuesToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertValuesToggle),this._assertSnapshotToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertSnapshotToggle.title="Assert snapshot",this._assertSnapshotToggle.classList.add("snapshot"),this._assertSnapshotToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertSnapshotToggle),this._updateVisualPosition(),this._refreshListeners()}_refreshListeners(){lv(this._listeners),this._listeners=[De(this._dragHandle,"mousedown",e=>{this._dragState={offsetX:this._offsetX,dragStart:{x:e.clientX,y:0}}}),De(this._recordToggle,"click",()=>{this._recordToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="none"||this._recorder.state.mode==="standby"||this._recorder.state.mode==="inspecting"?"recording":"standby")}),De(this._pickLocatorToggle,"click",()=>{if(this._pickLocatorToggle.classList.contains("disabled"))return;const e={inspecting:"standby",none:"inspecting",standby:"inspecting",recording:"recording-inspecting","recording-inspecting":"recording",assertingText:"recording-inspecting",assertingVisibility:"recording-inspecting",assertingValue:"recording-inspecting",assertingSnapshot:"recording-inspecting"};this._recorder.setMode(e[this._recorder.state.mode])}),De(this._assertVisibilityToggle,"click",()=>{this._assertVisibilityToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingVisibility"?"recording":"assertingVisibility")}),De(this._assertTextToggle,"click",()=>{this._assertTextToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingText"?"recording":"assertingText")}),De(this._assertValuesToggle,"click",()=>{this._assertValuesToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingValue"?"recording":"assertingValue")}),De(this._assertSnapshotToggle,"click",()=>{this._assertSnapshotToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingSnapshot"?"recording":"assertingSnapshot")})]}install(){this._recorder.highlight.appendChild(this._overlayElement),this._refreshListeners(),this._updateVisualPosition()}contains(e){return this._recorder.injectedScript.utils.isInsideScope(this._overlayElement,e)}setUIState(e){const i=e.mode==="recording"||e.mode==="assertingText"||e.mode==="assertingVisibility"||e.mode==="assertingValue"||e.mode==="assertingSnapshot"||e.mode==="recording-inspecting";this._recordToggle.classList.toggle("toggled",i),this._recordToggle.title=i?"Stop Recording":"Start Recording",this._pickLocatorToggle.classList.toggle("toggled",e.mode==="inspecting"||e.mode==="recording-inspecting"),this._assertVisibilityToggle.classList.toggle("toggled",e.mode==="assertingVisibility"),this._assertVisibilityToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertTextToggle.classList.toggle("toggled",e.mode==="assertingText"),this._assertTextToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertValuesToggle.classList.toggle("toggled",e.mode==="assertingValue"),this._assertValuesToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertSnapshotToggle.classList.toggle("toggled",e.mode==="assertingSnapshot"),this._assertSnapshotToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._offsetX!==e.overlay.offsetX&&(this._offsetX=e.overlay.offsetX,this._updateVisualPosition()),e.mode==="none"?this._hideOverlay():this._showOverlay()}flashToolSucceeded(e){let i;e==="assertingVisibility"?i=this._assertVisibilityToggle:e==="assertingSnapshot"?i=this._assertSnapshotToggle:i=this._assertValuesToggle,i.classList.add("succeeded"),this._recorder.injectedScript.utils.builtins.setTimeout(()=>i.classList.remove("succeeded"),2e3)}_hideOverlay(){this._overlayElement.setAttribute("hidden","true")}_showOverlay(){this._overlayElement.hasAttribute("hidden")&&(this._overlayElement.removeAttribute("hidden"),this._updateVisualPosition())}_updateVisualPosition(){this._measure=this._overlayElement.getBoundingClientRect(),this._overlayElement.style.left=(this._recorder.injectedScript.window.innerWidth-this._measure.width)/2+this._offsetX+"px"}onMouseMove(e){if(!e.buttons)return this._dragState=void 0,!1;if(this._dragState){this._offsetX=this._dragState.offsetX+e.clientX-this._dragState.dragStart.x;const i=(this._recorder.injectedScript.window.innerWidth-this._measure.width)/2-10;return this._offsetX=Math.max(-i,Math.min(i,this._offsetX)),this._updateVisualPosition(),this._recorder.setOverlayState({offsetX:this._offsetX}),ze(e),!0}return!1}onMouseUp(e){return this._dragState?(ze(e),!0):!1}onClick(e){return this._dragState?(this._dragState=void 0,ze(e),!0):!1}onDblClick(e){return!1}}class nA{constructor(e,i){var s,a;this._listeners=[],this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this.state={mode:"none",testIdAttributeName:"data-testid",language:"javascript",overlay:{offsetX:0}},this._delegate={},this.document=e.document,this.injectedScript=e,this.highlight=e.createHighlight(),this._tools={none:new i0,standby:new i0,inspecting:new th(this,!1),recording:(i==null?void 0:i.recorderMode)==="api"?new eA(this):new WE(this),"recording-inspecting":new th(this,!1),assertingText:new nh(this,"text"),assertingVisibility:new th(this,!0),assertingValue:new nh(this,"value"),assertingSnapshot:new nh(this,"snapshot")},this._currentTool=this._tools.none,(a=(s=this._currentTool).install)==null||a.call(s),e.window.top===e.window&&(this.overlay=new tA(this),this.overlay.setUIState(this.state)),this._stylesheet=new e.window.CSSStyleSheet,this._stylesheet.replaceSync(`
|
|
125
125
|
body[data-pw-cursor=pointer] *, body[data-pw-cursor=pointer] *::after { cursor: pointer !important; }
|
|
126
126
|
body[data-pw-cursor=text] *, body[data-pw-cursor=text] *::after { cursor: text !important; }
|
|
127
|
-
`),this.installListeners(),e.utils.cacheNormalizedWhitespaces(),e.isUnderTest&&console.error("Recorder script ready for test"),e.consoleApi.install()}installListeners(){var s,a,o;av(this._listeners),this._listeners=[De(this.document,"click",u=>this._onClick(u),!0),De(this.document,"auxclick",u=>this._onClick(u),!0),De(this.document,"dblclick",u=>this._onDblClick(u),!0),De(this.document,"contextmenu",u=>this._onContextMenu(u),!0),De(this.document,"dragstart",u=>this._onDragStart(u),!0),De(this.document,"input",u=>this._onInput(u),!0),De(this.document,"keydown",u=>this._onKeyDown(u),!0),De(this.document,"keyup",u=>this._onKeyUp(u),!0),De(this.document,"pointerdown",u=>this._onPointerDown(u),!0),De(this.document,"pointerup",u=>this._onPointerUp(u),!0),De(this.document,"mousedown",u=>this._onMouseDown(u),!0),De(this.document,"mouseup",u=>this._onMouseUp(u),!0),De(this.document,"mousemove",u=>this._onMouseMove(u),!0),De(this.document,"mouseleave",u=>this._onMouseLeave(u),!0),De(this.document,"mouseenter",u=>this._onMouseEnter(u),!0),De(this.document,"focus",u=>this._onFocus(u),!0),De(this.document,"scroll",u=>this._onScroll(u),!0)],this.highlight.install();let e;const i=()=>{this.highlight.install(),e=this.injectedScript.utils.builtins.setTimeout(i,500)};e=this.injectedScript.utils.builtins.setTimeout(i,500),this._listeners.push(()=>this.injectedScript.utils.builtins.clearTimeout(e)),this.highlight.appendChild(lv(this.document,ZE)),(s=this.overlay)==null||s.install(),(o=(a=this._currentTool)==null?void 0:a.install)==null||o.call(a),this.document.adoptedStyleSheets.push(this._stylesheet)}_switchCurrentTool(){var s,a,o,u,f,d;const e=this._tools[this.state.mode];if(e===this._currentTool)return;(a=(s=this._currentTool).uninstall)==null||a.call(s),this.clearHighlight(),this._currentTool=e,(u=(o=this._currentTool).install)==null||u.call(o);const i=(f=e.cursor)==null?void 0:f.call(e);i&&((d=this.injectedScript.document.body)==null||d.setAttribute("data-pw-cursor",i))}setUIState(e,i){var o;this._delegate=i,e.actionPoint&&this.state.actionPoint&&e.actionPoint.x===this.state.actionPoint.x&&e.actionPoint.y===this.state.actionPoint.y||!e.actionPoint&&!this.state.actionPoint||(e.actionPoint?this.highlight.showActionPoint(e.actionPoint.x,e.actionPoint.y):this.highlight.hideActionPoint()),this.state=e,this.highlight.setLanguage(e.language),this._switchCurrentTool(),(o=this.overlay)==null||o.setUIState(e);let s="noop";if(e.actionSelector!==this._lastHighlightedSelector){const u=e.actionSelector?iA(this.injectedScript,e.language,e.actionSelector,this.document):null;s=u!=null&&u.length?u:"clear",this._lastHighlightedSelector=u!=null&&u.length?e.actionSelector:void 0}const a=JSON.stringify(e.ariaTemplate);if(this._lastHighlightedAriaTemplateJSON!==a){const u=e.ariaTemplate?this.injectedScript.getAllElementsMatchingExpectAriaTemplate(this.document,e.ariaTemplate):[];if(u.length){const f=u.length>1?an.multiple:an.single;s=u.map(d=>({element:d,color:f})),this._lastHighlightedAriaTemplateJSON=a}else this._lastHighlightedSelector||(s="clear"),this._lastHighlightedAriaTemplateJSON="undefined"}s==="clear"?this.highlight.clearHighlight():s!=="noop"&&this.highlight.updateHighlight(s)}clearHighlight(){this.updateHighlight(null,!1)}_onClick(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onClick(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onClick)==null||a.call(s,e))}_onDblClick(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onDblClick(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onDblClick)==null||a.call(s,e))}_onContextMenu(e){var i,s;e.isTrusted&&((s=(i=this._currentTool).onContextMenu)==null||s.call(i,e))}_onDragStart(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onDragStart)==null||s.call(i,e))}_onPointerDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onPointerDown)==null||s.call(i,e))}_onPointerUp(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onPointerUp)==null||s.call(i,e))}_onMouseDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseDown)==null||s.call(i,e))}_onMouseUp(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onMouseUp(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onMouseUp)==null||a.call(s,e))}_onMouseMove(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onMouseMove(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onMouseMove)==null||a.call(s,e))}_onMouseEnter(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseEnter)==null||s.call(i,e))}_onMouseLeave(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseLeave)==null||s.call(i,e))}_onFocus(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onFocus)==null||s.call(i,e))}_onScroll(e){var i,s;e.isTrusted&&(this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this.highlight.hideActionPoint(),(s=(i=this._currentTool).onScroll)==null||s.call(i,e))}_onInput(e){var i,s;this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onInput)==null||s.call(i,e)}_onKeyDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onKeyDown)==null||s.call(i,e))}_onKeyUp(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onKeyUp)==null||s.call(i,e))}updateHighlight(e,i){this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this._updateHighlight(e,i)}_updateHighlight(e,i){var a,o;let s=e==null?void 0:e.tooltipText;s===void 0&&(e!=null&&e.selector)&&(s=this.injectedScript.utils.asLocator(this.state.language,e.selector)),e?this.highlight.updateHighlight(e.elements.map(u=>({element:u,color:e.color,tooltipText:s}))):this.highlight.clearHighlight(),i&&((o=(a=this._delegate).highlightUpdated)==null||o.call(a))}_ignoreOverlayEvent(e){return e.composedPath().some(i=>(i.nodeName||"").toLowerCase()==="x-pw-glass")}deepEventTarget(e){var i;for(const s of e.composedPath())if(!((i=this.overlay)!=null&&i.contains(s)))return s;return e.composedPath()[0]}setMode(e){var i,s;(s=(i=this._delegate).setMode)==null||s.call(i,e)}_captureAutoExpectSnapshot(){const e=this.injectedScript.document.documentElement;return e?this.injectedScript.utils.generateAriaTree(e,{mode:"autoexpect"}):void 0}async performAction(e){var s,a;const i=this._lastActionAutoexpectSnapshot;if(this._lastActionAutoexpectSnapshot=this._captureAutoExpectSnapshot(),!sA(e)&&this._lastActionAutoexpectSnapshot){const o=rA(i,this._lastActionAutoexpectSnapshot);e.preconditionSelector=o?this.injectedScript.generateSelector(o,{testIdAttributeName:this.state.testIdAttributeName}).selector:void 0,e.preconditionSelector===e.selector&&(e.preconditionSelector=void 0)}await((a=(s=this._delegate).performAction)==null?void 0:a.call(s,e).catch(()=>{}))}recordAction(e){var i,s;this._lastActionAutoexpectSnapshot=this._captureAutoExpectSnapshot(),(s=(i=this._delegate).recordAction)==null||s.call(i,e)}setOverlayState(e){var i,s;(s=(i=this._delegate).setOverlayState)==null||s.call(i,e)}elementPicked(e,i){var a,o;const s=this.injectedScript.ariaSnapshot(i.elements[0],{mode:"expect"});(o=(a=this._delegate).elementPicked)==null||o.call(a,{selector:e,ariaSnapshot:s})}}let rv=class{constructor(e){this._dialogElement=null,this._recorder=e}isShowing(){return!!this._dialogElement}show(e){const i=this._recorder.document.createElement("x-pw-tool-item");i.title="Accept",i.classList.add("accept"),i.appendChild(this._recorder.document.createElement("x-div")),i.addEventListener("click",()=>{var f;return(f=e.onCommit)==null?void 0:f.call(e)});const s=this._recorder.document.createElement("x-pw-tool-item");s.title="Close",s.classList.add("cancel"),s.appendChild(this._recorder.document.createElement("x-div")),s.addEventListener("click",()=>{var f;this.close(),(f=e.onCancel)==null||f.call(e)}),this._dialogElement=this._recorder.document.createElement("x-pw-dialog"),e.autosize&&this._dialogElement.classList.add("autosize"),this._keyboardListener=f=>{var d;if(f.key==="Escape"){this.close(),(d=e.onCancel)==null||d.call(e);return}if(e.onCommit&&f.key==="Enter"&&(f.ctrlKey||f.metaKey)){this._dialogElement&&e.onCommit();return}},this._onGlassPaneClickHandler=f=>{var d;this.close(),(d=e.onCancel)==null||d.call(e)};const a=this._recorder.document.createElement("x-pw-tools-list"),o=this._recorder.document.createElement("label");o.textContent=e.label,a.appendChild(o),a.appendChild(this._recorder.document.createElement("x-spacer")),e.onCommit&&a.appendChild(i),a.appendChild(s),this._dialogElement.appendChild(a);const u=this._recorder.document.createElement("x-pw-dialog-body");return u.appendChild(e.body),this._dialogElement.appendChild(u),this._recorder.highlight.appendChild(this._dialogElement),this._recorder.highlight.onGlassPaneClick(this._onGlassPaneClickHandler),this._recorder.document.addEventListener("keydown",this._keyboardListener,!0),this._dialogElement}moveTo(e,i){this._dialogElement&&(this._dialogElement.style.top=e+"px",this._dialogElement.style.left=i+"px")}close(){this._dialogElement&&(this._dialogElement.remove(),this._recorder.highlight.offGlassPaneClick(this._onGlassPaneClickHandler),this._recorder.document.removeEventListener("keydown",this._keyboardListener),this._dialogElement=null)}};function nA(n){let e=n.activeElement;for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function lr(n){return(n.altKey?1:0)|(n.ctrlKey?2:0)|(n.metaKey?4:0)|(n.shiftKey?8:0)}function xh(n){switch(n.which){case 1:return"left";case 2:return"middle";case 3:return"right"}return"left"}function Ga(n){if(n.target.nodeName==="CANVAS")return{x:n.offsetX,y:n.offsetY}}function ze(n){n.preventDefault(),n.stopPropagation(),n.stopImmediatePropagation()}function Ka(n){if(!n||n.nodeName!=="INPUT")return null;const e=n;return["checkbox","radio"].includes(e.type)?e:null}function Ya(n){return!n||n.nodeName!=="INPUT"?!1:n.type.toLowerCase()==="range"}function De(n,e,i,s){return n.addEventListener(e,i,s),()=>{n.removeEventListener(e,i,s)}}function av(n){for(const e of n)e();n.splice(0,n.length)}function iA(n,e,i,s){try{const a=n.parseSelector(i),o=n.querySelectorAll(a,s),u=o.length>1?an.multiple:an.single,f=n.utils.asLocator(e,i);return o.map((d,p)=>{const m=o.length>1?` [${p+1} of ${o.length}]`:"";return{element:d,color:u,tooltipText:f+m}})}catch{return[]}}function lv(n,{tagName:e,attrs:i,children:s}){const a=n.createElementNS("http://www.w3.org/2000/svg",e);if(i)for(const[o,u]of Object.entries(i))a.setAttribute(o,u);if(s)for(const o of s)a.appendChild(lv(n,o));return a}function sA(n){return n.name.startsWith("assert")}function rA(n,e){var u,f;function i(d,p,m){let y=1,b=m+y;for(const w of d.children||[])typeof w=="string"?(y++,b++):(y+=i(w,p,b),b+=y);if(!["none","presentation","fragment","iframe","generic"].includes(d.role)&&d.name){let w=p.get(d.role);w||(w=new Map,p.set(d.role,w));const E=w.get(d.name),x=y*100-m;(!E||E.sizeAndPosition<x)&&w.set(d.name,{node:d,sizeAndPosition:x})}return y}const s=new Map;n&&i(n.root,s,0);const a=new Map;i(e.root,a,0);const o=[];for(const[d,p]of a)for(const[m,y]of p)((u=s.get(d))==null?void 0:u.get(m))||o.push(y);return o.sort((d,p)=>p.sizeAndPosition-d.sizeAndPosition),(f=o[0])==null?void 0:f.node.element}function aA(n,e){n=n.replace(/AriaRole\s*\.\s*([\w]+)/g,(o,u)=>u.toLowerCase()).replace(/(get_by_role|getByRole)\s*\(\s*(?:["'`])([^'"`]+)['"`]/g,(o,u,f)=>`${u}(${f.toLowerCase()}`);const i=[];let s="";for(let o=0;o<n.length;++o){const u=n[o];if(u!=='"'&&u!=="'"&&u!=="`"&&u!=="/"){s+=u;continue}const f=n[o-1]==="r"||n[o]==="/";++o;let d="";for(;o<n.length;){if(n[o]==="\\"){f?(n[o+1]!==u&&(d+=n[o]),++o,d+=n[o]):(++o,n[o]==="n"?d+=`
|
|
128
|
-
`:n[o]==="r"?d+="\r":n[o]==="t"?d+=" ":d+=n[o]),++o;continue}if(n[o]!==u){d+=n[o++];continue}break}i.push({quote:u,text:d}),s+=(u==="/"?"r":"")+"$"+i.length}s=s.toLowerCase().replace(/get_by_alt_text/g,"getbyalttext").replace(/get_by_test_id/g,"getbytestid").replace(/get_by_([\w]+)/g,"getby$1").replace(/has_not_text/g,"hasnottext").replace(/has_text/g,"hastext").replace(/has_not/g,"hasnot").replace(/frame_locator/g,"framelocator").replace(/content_frame/g,"contentframe").replace(/[{}\s]/g,"").replace(/new\(\)/g,"").replace(/new[\w]+\.[\w]+options\(\)/g,"").replace(/\.set/g,",set").replace(/\.or_\(/g,"or(").replace(/\.and_\(/g,"and(").replace(/:/g,"=").replace(/,re\.ignorecase/g,"i").replace(/,pattern.case_insensitive/g,"i").replace(/,regexoptions.ignorecase/g,"i").replace(/re.compile\(([^)]+)\)/g,"$1").replace(/pattern.compile\(([^)]+)\)/g,"r$1").replace(/newregex\(([^)]+)\)/g,"r$1").replace(/string=/g,"=").replace(/regex=/g,"=").replace(/,,/g,",").replace(/,\)/g,")");const a=i.map(o=>o.quote).filter(o=>"'\"`".includes(o))[0];return{selector:ov(s,i,e),preferredQuote:a}}function s0(n){return[...n.matchAll(/\$\d+/g)].length}function r0(n,e){return n.replace(/\$(\d+)/g,(i,s)=>`$${s-e}`)}function ov(n,e,i){for(;;){const a=n.match(/filter\(,?(has=|hasnot=|sethas\(|sethasnot\()/);if(!a)break;const o=a.index+a[0].length;let u=0,f=o;for(;f<n.length&&(n[f]==="("?u++:n[f]===")"&&u--,!(u<0));f++);let d=n.substring(0,o),p=0;["sethas(","sethasnot("].includes(a[1])&&(p=1,d=d.replace(/sethas\($/,"has=").replace(/sethasnot\($/,"hasnot="));const m=s0(n.substring(0,o)),y=r0(n.substring(o,f),m),b=s0(y),w=e.slice(m,m+b),E=JSON.stringify(ov(y,w,i));n=d.replace(/=$/,"2=")+`$${m+1}`+r0(n.substring(f+p),b-1);const x=e.slice(0,m),_=e.slice(m+b);e=x.concat([{quote:'"',text:E}]).concat(_)}n=n.replace(/\,set([\w]+)\(([^)]+)\)/g,(a,o,u)=>","+o.toLowerCase()+"="+u.toLowerCase()).replace(/framelocator\(([^)]+)\)/g,"$1.internal:control=enter-frame").replace(/contentframe(\(\))?/g,"internal:control=enter-frame").replace(/locator\(([^)]+),hastext=([^),]+)\)/g,"locator($1).internal:has-text=$2").replace(/locator\(([^)]+),hasnottext=([^),]+)\)/g,"locator($1).internal:has-not-text=$2").replace(/locator\(([^)]+),hastext=([^),]+)\)/g,"locator($1).internal:has-text=$2").replace(/locator\(([^)]+)\)/g,"$1").replace(/getbyrole\(([^)]+)\)/g,"internal:role=$1").replace(/getbytext\(([^)]+)\)/g,"internal:text=$1").replace(/getbylabel\(([^)]+)\)/g,"internal:label=$1").replace(/getbytestid\(([^)]+)\)/g,`internal:testid=[${i}=$1]`).replace(/getby(placeholder|alt|title)(?:text)?\(([^)]+)\)/g,"internal:attr=[$1=$2]").replace(/first(\(\))?/g,"nth=0").replace(/last(\(\))?/g,"nth=-1").replace(/nth\(([^)]+)\)/g,"nth=$1").replace(/filter\(,?visible=true\)/g,"visible=true").replace(/filter\(,?visible=false\)/g,"visible=false").replace(/filter\(,?hastext=([^)]+)\)/g,"internal:has-text=$1").replace(/filter\(,?hasnottext=([^)]+)\)/g,"internal:has-not-text=$1").replace(/filter\(,?has2=([^)]+)\)/g,"internal:has=$1").replace(/filter\(,?hasnot2=([^)]+)\)/g,"internal:has-not=$1").replace(/,exact=false/g,"").replace(/,exact=true/g,"s").replace(/,includehidden=/g,",include-hidden=").replace(/\,/g,"][");const s=n.split(".");for(let a=0;a<s.length-1;a++)if(s[a]==="internal:control=enter-frame"&&s[a+1].startsWith("nth=")){const[o]=s.splice(a,1);s.splice(a+1,0,o)}return s.map(a=>!a.startsWith("internal:")||a==="internal:control"?a.replace(/\$(\d+)/g,(o,u)=>e[+u-1].text):(a=a.includes("[")?a.replace(/\]/,"")+"]":a,a=a.replace(/(?:r)\$(\d+)(i)?/g,(o,u,f)=>{const d=e[+u-1];return a.startsWith("internal:attr")||a.startsWith("internal:testid")||a.startsWith("internal:role")?xt(new RegExp(d.text),!1)+(f||""):Lt(new RegExp(d.text,f),!1)}).replace(/\$(\d+)(i|s)?/g,(o,u,f)=>{const d=e[+u-1];return a.startsWith("internal:has=")||a.startsWith("internal:has-not=")?d.text:a.startsWith("internal:testid")?xt(d.text,!0):a.startsWith("internal:attr")||a.startsWith("internal:role")?xt(d.text,f==="s"):Lt(d.text,f==="s")}),a)).join(" >> ")}function lA(n,e,i){try{return oA(n,e,i)}catch{return""}}function oA(n,e,i){try{return tl(e),e}catch{}const{selector:s,preferredQuote:a}=aA(e,i),o=P0(n,s,void 0,void 0,a),u=a0(n,e);return o.some(f=>a0(n,f)===u)?s:""}function a0(n,e){return e=e.replace(/\s/g,""),n==="javascript"&&(e=e.replace(/\\?["`]/g,"'").replace(/,{}/g,"")),e}const cA=({url:n})=>v.jsxs("div",{className:"browser-frame-header",children:[v.jsxs("div",{className:"browser-traffic-lights",children:[v.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(242, 95, 88)"}}),v.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(251, 190, 60)"}}),v.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(88, 203, 66)"}})]}),v.jsxs("div",{className:"browser-frame-address-bar",title:n||"about:blank",children:[v.jsx("span",{className:"browser-frame-address",children:n||"about:blank"}),n&&v.jsx(Bh,{value:n})]}),v.jsx("div",{style:{marginLeft:"auto"},children:v.jsxs("div",{children:[v.jsx("span",{className:"browser-frame-menu-bar"}),v.jsx("span",{className:"browser-frame-menu-bar"}),v.jsx("span",{className:"browser-frame-menu-bar"})]})})]}),ld=Symbol.for("yaml.alias"),_h=Symbol.for("yaml.document"),Si=Symbol.for("yaml.map"),cv=Symbol.for("yaml.pair"),Tn=Symbol.for("yaml.scalar"),yr=Symbol.for("yaml.seq"),on=Symbol.for("yaml.node.type"),is=n=>!!n&&typeof n=="object"&&n[on]===ld,ss=n=>!!n&&typeof n=="object"&&n[on]===_h,br=n=>!!n&&typeof n=="object"&&n[on]===Si,Be=n=>!!n&&typeof n=="object"&&n[on]===cv,Re=n=>!!n&&typeof n=="object"&&n[on]===Tn,vr=n=>!!n&&typeof n=="object"&&n[on]===yr;function He(n){if(n&&typeof n=="object")switch(n[on]){case Si:case yr:return!0}return!1}function qe(n){if(n&&typeof n=="object")switch(n[on]){case ld:case Si:case Tn:case yr:return!0}return!1}const uA=n=>(Re(n)||He(n))&&!!n.anchor,Dt=Symbol("break visit"),uv=Symbol("skip children"),_n=Symbol("remove node");function wi(n,e){const i=fv(e);ss(n)?ir(null,n.contents,i,Object.freeze([n]))===_n&&(n.contents=null):ir(null,n,i,Object.freeze([]))}wi.BREAK=Dt;wi.SKIP=uv;wi.REMOVE=_n;function ir(n,e,i,s){const a=hv(n,e,i,s);if(qe(a)||Be(a))return dv(n,s,a),ir(n,a,i,s);if(typeof a!="symbol"){if(He(e)){s=Object.freeze(s.concat(e));for(let o=0;o<e.items.length;++o){const u=ir(o,e.items[o],i,s);if(typeof u=="number")o=u-1;else{if(u===Dt)return Dt;u===_n&&(e.items.splice(o,1),o-=1)}}}else if(Be(e)){s=Object.freeze(s.concat(e));const o=ir("key",e.key,i,s);if(o===Dt)return Dt;o===_n&&(e.key=null);const u=ir("value",e.value,i,s);if(u===Dt)return Dt;u===_n&&(e.value=null)}}return a}async function uc(n,e){const i=fv(e);ss(n)?await sr(null,n.contents,i,Object.freeze([n]))===_n&&(n.contents=null):await sr(null,n,i,Object.freeze([]))}uc.BREAK=Dt;uc.SKIP=uv;uc.REMOVE=_n;async function sr(n,e,i,s){const a=await hv(n,e,i,s);if(qe(a)||Be(a))return dv(n,s,a),sr(n,a,i,s);if(typeof a!="symbol"){if(He(e)){s=Object.freeze(s.concat(e));for(let o=0;o<e.items.length;++o){const u=await sr(o,e.items[o],i,s);if(typeof u=="number")o=u-1;else{if(u===Dt)return Dt;u===_n&&(e.items.splice(o,1),o-=1)}}}else if(Be(e)){s=Object.freeze(s.concat(e));const o=await sr("key",e.key,i,s);if(o===Dt)return Dt;o===_n&&(e.key=null);const u=await sr("value",e.value,i,s);if(u===Dt)return Dt;u===_n&&(e.value=null)}}return a}function fv(n){return typeof n=="object"&&(n.Collection||n.Node||n.Value)?Object.assign({Alias:n.Node,Map:n.Node,Scalar:n.Node,Seq:n.Node},n.Value&&{Map:n.Value,Scalar:n.Value,Seq:n.Value},n.Collection&&{Map:n.Collection,Seq:n.Collection},n):n}function hv(n,e,i,s){var a,o,u,f,d;if(typeof i=="function")return i(n,e,s);if(br(e))return(a=i.Map)==null?void 0:a.call(i,n,e,s);if(vr(e))return(o=i.Seq)==null?void 0:o.call(i,n,e,s);if(Be(e))return(u=i.Pair)==null?void 0:u.call(i,n,e,s);if(Re(e))return(f=i.Scalar)==null?void 0:f.call(i,n,e,s);if(is(e))return(d=i.Alias)==null?void 0:d.call(i,n,e,s)}function dv(n,e,i){const s=e[e.length-1];if(He(s))s.items[n]=i;else if(Be(s))n==="key"?s.key=i:s.value=i;else if(ss(s))s.contents=i;else{const a=is(s)?"alias":"scalar";throw new Error(`Cannot replace node with ${a} parent`)}}const fA={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},hA=n=>n.replace(/[!,[\]{}]/g,e=>fA[e]);class wt{constructor(e,i){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},wt.defaultYaml,e),this.tags=Object.assign({},wt.defaultTags,i)}clone(){const e=new wt(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){const e=new wt(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:wt.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},wt.defaultTags);break}return e}add(e,i){this.atNextDocument&&(this.yaml={explicit:wt.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},wt.defaultTags),this.atNextDocument=!1);const s=e.trim().split(/[ \t]+/),a=s.shift();switch(a){case"%TAG":{if(s.length!==2&&(i(0,"%TAG directive should contain exactly two parts"),s.length<2))return!1;const[o,u]=s;return this.tags[o]=u,!0}case"%YAML":{if(this.yaml.explicit=!0,s.length!==1)return i(0,"%YAML directive should contain exactly one part"),!1;const[o]=s;if(o==="1.1"||o==="1.2")return this.yaml.version=o,!0;{const u=/^\d+\.\d+$/.test(o);return i(6,`Unsupported YAML version ${o}`,u),!1}}default:return i(0,`Unknown directive ${a}`,!0),!1}}tagName(e,i){if(e==="!")return"!";if(e[0]!=="!")return i(`Not a valid tag: ${e}`),null;if(e[1]==="<"){const u=e.slice(2,-1);return u==="!"||u==="!!"?(i(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(e[e.length-1]!==">"&&i("Verbatim tags must end with a >"),u)}const[,s,a]=e.match(/^(.*!)([^!]*)$/s);a||i(`The ${e} tag has no suffix`);const o=this.tags[s];if(o)try{return o+decodeURIComponent(a)}catch(u){return i(String(u)),null}return s==="!"?e:(i(`Could not resolve tag: ${e}`),null)}tagString(e){for(const[i,s]of Object.entries(this.tags))if(e.startsWith(s))return i+hA(e.substring(s.length));return e[0]==="!"?e:`!<${e}>`}toString(e){const i=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],s=Object.entries(this.tags);let a;if(e&&s.length>0&&qe(e.contents)){const o={};wi(e.contents,(u,f)=>{qe(f)&&f.tag&&(o[f.tag]=!0)}),a=Object.keys(o)}else a=[];for(const[o,u]of s)o==="!!"&&u==="tag:yaml.org,2002:"||(!e||a.some(f=>f.startsWith(u)))&&i.push(`%TAG ${o} ${u}`);return i.join(`
|
|
129
|
-
`)}}wt.defaultYaml={explicit:!1,version:"1.2"};wt.defaultTags={"!!":"tag:yaml.org,2002:"};function
|
|
127
|
+
`),this.installListeners(),e.utils.cacheNormalizedWhitespaces(),e.isUnderTest&&console.error("Recorder script ready for test"),e.consoleApi.install()}installListeners(){var s,a,o;lv(this._listeners),this._listeners=[De(this.document,"click",u=>this._onClick(u),!0),De(this.document,"auxclick",u=>this._onClick(u),!0),De(this.document,"dblclick",u=>this._onDblClick(u),!0),De(this.document,"contextmenu",u=>this._onContextMenu(u),!0),De(this.document,"dragstart",u=>this._onDragStart(u),!0),De(this.document,"input",u=>this._onInput(u),!0),De(this.document,"keydown",u=>this._onKeyDown(u),!0),De(this.document,"keyup",u=>this._onKeyUp(u),!0),De(this.document,"pointerdown",u=>this._onPointerDown(u),!0),De(this.document,"pointerup",u=>this._onPointerUp(u),!0),De(this.document,"mousedown",u=>this._onMouseDown(u),!0),De(this.document,"mouseup",u=>this._onMouseUp(u),!0),De(this.document,"mousemove",u=>this._onMouseMove(u),!0),De(this.document,"mouseleave",u=>this._onMouseLeave(u),!0),De(this.document,"mouseenter",u=>this._onMouseEnter(u),!0),De(this.document,"focus",u=>this._onFocus(u),!0),De(this.document,"scroll",u=>this._onScroll(u),!0)],this.highlight.install();let e;const i=()=>{this.highlight.install(),e=this.injectedScript.utils.builtins.setTimeout(i,500)};e=this.injectedScript.utils.builtins.setTimeout(i,500),this._listeners.push(()=>this.injectedScript.utils.builtins.clearTimeout(e)),this.highlight.appendChild(ov(this.document,JE)),(s=this.overlay)==null||s.install(),(o=(a=this._currentTool)==null?void 0:a.install)==null||o.call(a),this.document.adoptedStyleSheets.push(this._stylesheet)}_switchCurrentTool(){var s,a,o,u,f,d;const e=this._tools[this.state.mode];if(e===this._currentTool)return;(a=(s=this._currentTool).uninstall)==null||a.call(s),this.clearHighlight(),this._currentTool=e,(u=(o=this._currentTool).install)==null||u.call(o);const i=(f=e.cursor)==null?void 0:f.call(e);i&&((d=this.injectedScript.document.body)==null||d.setAttribute("data-pw-cursor",i))}setUIState(e,i){var o;this._delegate=i,e.actionPoint&&this.state.actionPoint&&e.actionPoint.x===this.state.actionPoint.x&&e.actionPoint.y===this.state.actionPoint.y||!e.actionPoint&&!this.state.actionPoint||(e.actionPoint?this.highlight.showActionPoint(e.actionPoint.x,e.actionPoint.y):this.highlight.hideActionPoint()),this.state=e,this.highlight.setLanguage(e.language),this._switchCurrentTool(),(o=this.overlay)==null||o.setUIState(e);let s="noop";if(e.actionSelector!==this._lastHighlightedSelector){const u=e.actionSelector?sA(this.injectedScript,e.language,e.actionSelector,this.document):null;s=u!=null&&u.length?u:"clear",this._lastHighlightedSelector=u!=null&&u.length?e.actionSelector:void 0}const a=JSON.stringify(e.ariaTemplate);if(this._lastHighlightedAriaTemplateJSON!==a){const u=e.ariaTemplate?this.injectedScript.getAllElementsMatchingExpectAriaTemplate(this.document,e.ariaTemplate):[];if(u.length){const f=u.length>1?an.multiple:an.single;s=u.map(d=>({element:d,color:f})),this._lastHighlightedAriaTemplateJSON=a}else this._lastHighlightedSelector||(s="clear"),this._lastHighlightedAriaTemplateJSON="undefined"}s==="clear"?this.highlight.clearHighlight():s!=="noop"&&this.highlight.updateHighlight(s)}clearHighlight(){this.updateHighlight(null,!1)}_onClick(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onClick(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onClick)==null||a.call(s,e))}_onDblClick(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onDblClick(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onDblClick)==null||a.call(s,e))}_onContextMenu(e){var i,s;e.isTrusted&&((s=(i=this._currentTool).onContextMenu)==null||s.call(i,e))}_onDragStart(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onDragStart)==null||s.call(i,e))}_onPointerDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onPointerDown)==null||s.call(i,e))}_onPointerUp(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onPointerUp)==null||s.call(i,e))}_onMouseDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseDown)==null||s.call(i,e))}_onMouseUp(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onMouseUp(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onMouseUp)==null||a.call(s,e))}_onMouseMove(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onMouseMove(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onMouseMove)==null||a.call(s,e))}_onMouseEnter(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseEnter)==null||s.call(i,e))}_onMouseLeave(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseLeave)==null||s.call(i,e))}_onFocus(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onFocus)==null||s.call(i,e))}_onScroll(e){var i,s;e.isTrusted&&(this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this.highlight.hideActionPoint(),(s=(i=this._currentTool).onScroll)==null||s.call(i,e))}_onInput(e){var i,s;this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onInput)==null||s.call(i,e)}_onKeyDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onKeyDown)==null||s.call(i,e))}_onKeyUp(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onKeyUp)==null||s.call(i,e))}updateHighlight(e,i){this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this._updateHighlight(e,i)}_updateHighlight(e,i){var a,o;let s=e==null?void 0:e.tooltipText;s===void 0&&(e!=null&&e.selector)&&(s=this.injectedScript.utils.asLocator(this.state.language,e.selector)),e?this.highlight.updateHighlight(e.elements.map(u=>({element:u,color:e.color,tooltipText:s}))):this.highlight.clearHighlight(),i&&((o=(a=this._delegate).highlightUpdated)==null||o.call(a))}_ignoreOverlayEvent(e){return e.composedPath().some(i=>(i.nodeName||"").toLowerCase()==="x-pw-glass")}deepEventTarget(e){var i;for(const s of e.composedPath())if(!((i=this.overlay)!=null&&i.contains(s)))return s;return e.composedPath()[0]}setMode(e){var i,s;(s=(i=this._delegate).setMode)==null||s.call(i,e)}_captureAutoExpectSnapshot(){const e=this.injectedScript.document.documentElement;return e?this.injectedScript.utils.generateAriaTree(e,{mode:"autoexpect"}):void 0}async performAction(e){var s,a;const i=this._lastActionAutoexpectSnapshot;if(this._lastActionAutoexpectSnapshot=this._captureAutoExpectSnapshot(),!rA(e)&&this._lastActionAutoexpectSnapshot){const o=aA(i,this._lastActionAutoexpectSnapshot);e.preconditionSelector=o?this.injectedScript.generateSelector(o,{testIdAttributeName:this.state.testIdAttributeName}).selector:void 0,e.preconditionSelector===e.selector&&(e.preconditionSelector=void 0)}await((a=(s=this._delegate).performAction)==null?void 0:a.call(s,e).catch(()=>{}))}recordAction(e){var i,s;this._lastActionAutoexpectSnapshot=this._captureAutoExpectSnapshot(),(s=(i=this._delegate).recordAction)==null||s.call(i,e)}setOverlayState(e){var i,s;(s=(i=this._delegate).setOverlayState)==null||s.call(i,e)}elementPicked(e,i){var a,o;const s=this.injectedScript.ariaSnapshot(i.elements[0],{mode:"expect"});(o=(a=this._delegate).elementPicked)==null||o.call(a,{selector:e,ariaSnapshot:s})}}let av=class{constructor(e){this._dialogElement=null,this._recorder=e}isShowing(){return!!this._dialogElement}show(e){const i=this._recorder.document.createElement("x-pw-tool-item");i.title="Accept",i.classList.add("accept"),i.appendChild(this._recorder.document.createElement("x-div")),i.addEventListener("click",()=>{var f;return(f=e.onCommit)==null?void 0:f.call(e)});const s=this._recorder.document.createElement("x-pw-tool-item");s.title="Close",s.classList.add("cancel"),s.appendChild(this._recorder.document.createElement("x-div")),s.addEventListener("click",()=>{var f;this.close(),(f=e.onCancel)==null||f.call(e)}),this._dialogElement=this._recorder.document.createElement("x-pw-dialog"),e.autosize&&this._dialogElement.classList.add("autosize"),this._keyboardListener=f=>{var d;if(f.key==="Escape"){this.close(),(d=e.onCancel)==null||d.call(e);return}if(e.onCommit&&f.key==="Enter"&&(f.ctrlKey||f.metaKey)){this._dialogElement&&e.onCommit();return}},this._onGlassPaneClickHandler=f=>{var d;this.close(),(d=e.onCancel)==null||d.call(e)};const a=this._recorder.document.createElement("x-pw-tools-list"),o=this._recorder.document.createElement("label");o.textContent=e.label,a.appendChild(o),a.appendChild(this._recorder.document.createElement("x-spacer")),e.onCommit&&a.appendChild(i),a.appendChild(s),this._dialogElement.appendChild(a);const u=this._recorder.document.createElement("x-pw-dialog-body");return u.appendChild(e.body),this._dialogElement.appendChild(u),this._recorder.highlight.appendChild(this._dialogElement),this._recorder.highlight.onGlassPaneClick(this._onGlassPaneClickHandler),this._recorder.document.addEventListener("keydown",this._keyboardListener,!0),this._dialogElement}moveTo(e,i){this._dialogElement&&(this._dialogElement.style.top=e+"px",this._dialogElement.style.left=i+"px")}close(){this._dialogElement&&(this._dialogElement.remove(),this._recorder.highlight.offGlassPaneClick(this._onGlassPaneClickHandler),this._recorder.document.removeEventListener("keydown",this._keyboardListener),this._dialogElement=null)}};function iA(n){let e=n.activeElement;for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function lr(n){return(n.altKey?1:0)|(n.ctrlKey?2:0)|(n.metaKey?4:0)|(n.shiftKey?8:0)}function xh(n){switch(n.which){case 1:return"left";case 2:return"middle";case 3:return"right"}return"left"}function Ga(n){if(n.target.nodeName==="CANVAS")return{x:n.offsetX,y:n.offsetY}}function ze(n){n.preventDefault(),n.stopPropagation(),n.stopImmediatePropagation()}function Ka(n){if(!n||n.nodeName!=="INPUT")return null;const e=n;return["checkbox","radio"].includes(e.type)?e:null}function Ya(n){return!n||n.nodeName!=="INPUT"?!1:n.type.toLowerCase()==="range"}function De(n,e,i,s){return n.addEventListener(e,i,s),()=>{n.removeEventListener(e,i,s)}}function lv(n){for(const e of n)e();n.splice(0,n.length)}function sA(n,e,i,s){try{const a=n.parseSelector(i),o=n.querySelectorAll(a,s),u=o.length>1?an.multiple:an.single,f=n.utils.asLocator(e,i);return o.map((d,p)=>{const m=o.length>1?` [${p+1} of ${o.length}]`:"";return{element:d,color:u,tooltipText:f+m}})}catch{return[]}}function ov(n,{tagName:e,attrs:i,children:s}){const a=n.createElementNS("http://www.w3.org/2000/svg",e);if(i)for(const[o,u]of Object.entries(i))a.setAttribute(o,u);if(s)for(const o of s)a.appendChild(ov(n,o));return a}function rA(n){return n.name.startsWith("assert")}function aA(n,e){var u,f;function i(d,p,m){let y=1,b=m+y;for(const w of d.children||[])typeof w=="string"?(y++,b++):(y+=i(w,p,b),b+=y);if(!["none","presentation","fragment","iframe","generic"].includes(d.role)&&d.name){let w=p.get(d.role);w||(w=new Map,p.set(d.role,w));const E=w.get(d.name),x=y*100-m;(!E||E.sizeAndPosition<x)&&w.set(d.name,{node:d,sizeAndPosition:x})}return y}const s=new Map;n&&i(n.root,s,0);const a=new Map;i(e.root,a,0);const o=[];for(const[d,p]of a)for(const[m,y]of p)((u=s.get(d))==null?void 0:u.get(m))||o.push(y);return o.sort((d,p)=>p.sizeAndPosition-d.sizeAndPosition),(f=o[0])==null?void 0:f.node.element}function lA(n,e){n=n.replace(/AriaRole\s*\.\s*([\w]+)/g,(o,u)=>u.toLowerCase()).replace(/(get_by_role|getByRole)\s*\(\s*(?:["'`])([^'"`]+)['"`]/g,(o,u,f)=>`${u}(${f.toLowerCase()}`);const i=[];let s="";for(let o=0;o<n.length;++o){const u=n[o];if(u!=='"'&&u!=="'"&&u!=="`"&&u!=="/"){s+=u;continue}const f=n[o-1]==="r"||n[o]==="/";++o;let d="";for(;o<n.length;){if(n[o]==="\\"){f?(n[o+1]!==u&&(d+=n[o]),++o,d+=n[o]):(++o,n[o]==="n"?d+=`
|
|
128
|
+
`:n[o]==="r"?d+="\r":n[o]==="t"?d+=" ":d+=n[o]),++o;continue}if(n[o]!==u){d+=n[o++];continue}break}i.push({quote:u,text:d}),s+=(u==="/"?"r":"")+"$"+i.length}s=s.toLowerCase().replace(/get_by_alt_text/g,"getbyalttext").replace(/get_by_test_id/g,"getbytestid").replace(/get_by_([\w]+)/g,"getby$1").replace(/has_not_text/g,"hasnottext").replace(/has_text/g,"hastext").replace(/has_not/g,"hasnot").replace(/frame_locator/g,"framelocator").replace(/content_frame/g,"contentframe").replace(/[{}\s]/g,"").replace(/new\(\)/g,"").replace(/new[\w]+\.[\w]+options\(\)/g,"").replace(/\.set/g,",set").replace(/\.or_\(/g,"or(").replace(/\.and_\(/g,"and(").replace(/:/g,"=").replace(/,re\.ignorecase/g,"i").replace(/,pattern.case_insensitive/g,"i").replace(/,regexoptions.ignorecase/g,"i").replace(/re.compile\(([^)]+)\)/g,"$1").replace(/pattern.compile\(([^)]+)\)/g,"r$1").replace(/newregex\(([^)]+)\)/g,"r$1").replace(/string=/g,"=").replace(/regex=/g,"=").replace(/,,/g,",").replace(/,\)/g,")");const a=i.map(o=>o.quote).filter(o=>"'\"`".includes(o))[0];return{selector:cv(s,i,e),preferredQuote:a}}function s0(n){return[...n.matchAll(/\$\d+/g)].length}function r0(n,e){return n.replace(/\$(\d+)/g,(i,s)=>`$${s-e}`)}function cv(n,e,i){for(;;){const a=n.match(/filter\(,?(has=|hasnot=|sethas\(|sethasnot\()/);if(!a)break;const o=a.index+a[0].length;let u=0,f=o;for(;f<n.length&&(n[f]==="("?u++:n[f]===")"&&u--,!(u<0));f++);let d=n.substring(0,o),p=0;["sethas(","sethasnot("].includes(a[1])&&(p=1,d=d.replace(/sethas\($/,"has=").replace(/sethasnot\($/,"hasnot="));const m=s0(n.substring(0,o)),y=r0(n.substring(o,f),m),b=s0(y),w=e.slice(m,m+b),E=JSON.stringify(cv(y,w,i));n=d.replace(/=$/,"2=")+`$${m+1}`+r0(n.substring(f+p),b-1);const x=e.slice(0,m),_=e.slice(m+b);e=x.concat([{quote:'"',text:E}]).concat(_)}n=n.replace(/\,set([\w]+)\(([^)]+)\)/g,(a,o,u)=>","+o.toLowerCase()+"="+u.toLowerCase()).replace(/framelocator\(([^)]+)\)/g,"$1.internal:control=enter-frame").replace(/contentframe(\(\))?/g,"internal:control=enter-frame").replace(/locator\(([^)]+),hastext=([^),]+)\)/g,"locator($1).internal:has-text=$2").replace(/locator\(([^)]+),hasnottext=([^),]+)\)/g,"locator($1).internal:has-not-text=$2").replace(/locator\(([^)]+),hastext=([^),]+)\)/g,"locator($1).internal:has-text=$2").replace(/locator\(([^)]+)\)/g,"$1").replace(/getbyrole\(([^)]+)\)/g,"internal:role=$1").replace(/getbytext\(([^)]+)\)/g,"internal:text=$1").replace(/getbylabel\(([^)]+)\)/g,"internal:label=$1").replace(/getbytestid\(([^)]+)\)/g,`internal:testid=[${i}=$1]`).replace(/getby(placeholder|alt|title)(?:text)?\(([^)]+)\)/g,"internal:attr=[$1=$2]").replace(/first(\(\))?/g,"nth=0").replace(/last(\(\))?/g,"nth=-1").replace(/nth\(([^)]+)\)/g,"nth=$1").replace(/filter\(,?visible=true\)/g,"visible=true").replace(/filter\(,?visible=false\)/g,"visible=false").replace(/filter\(,?hastext=([^)]+)\)/g,"internal:has-text=$1").replace(/filter\(,?hasnottext=([^)]+)\)/g,"internal:has-not-text=$1").replace(/filter\(,?has2=([^)]+)\)/g,"internal:has=$1").replace(/filter\(,?hasnot2=([^)]+)\)/g,"internal:has-not=$1").replace(/,exact=false/g,"").replace(/,exact=true/g,"s").replace(/,includehidden=/g,",include-hidden=").replace(/\,/g,"][");const s=n.split(".");for(let a=0;a<s.length-1;a++)if(s[a]==="internal:control=enter-frame"&&s[a+1].startsWith("nth=")){const[o]=s.splice(a,1);s.splice(a+1,0,o)}return s.map(a=>!a.startsWith("internal:")||a==="internal:control"?a.replace(/\$(\d+)/g,(o,u)=>e[+u-1].text):(a=a.includes("[")?a.replace(/\]/,"")+"]":a,a=a.replace(/(?:r)\$(\d+)(i)?/g,(o,u,f)=>{const d=e[+u-1];return a.startsWith("internal:attr")||a.startsWith("internal:testid")||a.startsWith("internal:role")?xt(new RegExp(d.text),!1)+(f||""):Lt(new RegExp(d.text,f),!1)}).replace(/\$(\d+)(i|s)?/g,(o,u,f)=>{const d=e[+u-1];return a.startsWith("internal:has=")||a.startsWith("internal:has-not=")?d.text:a.startsWith("internal:testid")?xt(d.text,!0):a.startsWith("internal:attr")||a.startsWith("internal:role")?xt(d.text,f==="s"):Lt(d.text,f==="s")}),a)).join(" >> ")}function oA(n,e,i){try{return cA(n,e,i)}catch{return""}}function cA(n,e,i){try{return tl(e),e}catch{}const{selector:s,preferredQuote:a}=lA(e,i),o=P0(n,s,void 0,void 0,a),u=a0(n,e);return o.some(f=>a0(n,f)===u)?s:""}function a0(n,e){return e=e.replace(/\s/g,""),n==="javascript"&&(e=e.replace(/\\?["`]/g,"'").replace(/,{}/g,"")),e}const uA=({url:n})=>v.jsxs("div",{className:"browser-frame-header",children:[v.jsxs("div",{className:"browser-traffic-lights",children:[v.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(242, 95, 88)"}}),v.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(251, 190, 60)"}}),v.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(88, 203, 66)"}})]}),v.jsxs("div",{className:"browser-frame-address-bar",title:n||"about:blank",children:[v.jsx("span",{className:"browser-frame-address",children:n||"about:blank"}),n&&v.jsx(Bh,{value:n})]}),v.jsx("div",{style:{marginLeft:"auto"},children:v.jsxs("div",{children:[v.jsx("span",{className:"browser-frame-menu-bar"}),v.jsx("span",{className:"browser-frame-menu-bar"}),v.jsx("span",{className:"browser-frame-menu-bar"})]})})]}),ld=Symbol.for("yaml.alias"),_h=Symbol.for("yaml.document"),Si=Symbol.for("yaml.map"),uv=Symbol.for("yaml.pair"),Tn=Symbol.for("yaml.scalar"),yr=Symbol.for("yaml.seq"),on=Symbol.for("yaml.node.type"),is=n=>!!n&&typeof n=="object"&&n[on]===ld,ss=n=>!!n&&typeof n=="object"&&n[on]===_h,br=n=>!!n&&typeof n=="object"&&n[on]===Si,Be=n=>!!n&&typeof n=="object"&&n[on]===uv,Re=n=>!!n&&typeof n=="object"&&n[on]===Tn,vr=n=>!!n&&typeof n=="object"&&n[on]===yr;function He(n){if(n&&typeof n=="object")switch(n[on]){case Si:case yr:return!0}return!1}function qe(n){if(n&&typeof n=="object")switch(n[on]){case ld:case Si:case Tn:case yr:return!0}return!1}const fA=n=>(Re(n)||He(n))&&!!n.anchor,Dt=Symbol("break visit"),fv=Symbol("skip children"),_n=Symbol("remove node");function wi(n,e){const i=hv(e);ss(n)?ir(null,n.contents,i,Object.freeze([n]))===_n&&(n.contents=null):ir(null,n,i,Object.freeze([]))}wi.BREAK=Dt;wi.SKIP=fv;wi.REMOVE=_n;function ir(n,e,i,s){const a=dv(n,e,i,s);if(qe(a)||Be(a))return pv(n,s,a),ir(n,a,i,s);if(typeof a!="symbol"){if(He(e)){s=Object.freeze(s.concat(e));for(let o=0;o<e.items.length;++o){const u=ir(o,e.items[o],i,s);if(typeof u=="number")o=u-1;else{if(u===Dt)return Dt;u===_n&&(e.items.splice(o,1),o-=1)}}}else if(Be(e)){s=Object.freeze(s.concat(e));const o=ir("key",e.key,i,s);if(o===Dt)return Dt;o===_n&&(e.key=null);const u=ir("value",e.value,i,s);if(u===Dt)return Dt;u===_n&&(e.value=null)}}return a}async function uc(n,e){const i=hv(e);ss(n)?await sr(null,n.contents,i,Object.freeze([n]))===_n&&(n.contents=null):await sr(null,n,i,Object.freeze([]))}uc.BREAK=Dt;uc.SKIP=fv;uc.REMOVE=_n;async function sr(n,e,i,s){const a=await dv(n,e,i,s);if(qe(a)||Be(a))return pv(n,s,a),sr(n,a,i,s);if(typeof a!="symbol"){if(He(e)){s=Object.freeze(s.concat(e));for(let o=0;o<e.items.length;++o){const u=await sr(o,e.items[o],i,s);if(typeof u=="number")o=u-1;else{if(u===Dt)return Dt;u===_n&&(e.items.splice(o,1),o-=1)}}}else if(Be(e)){s=Object.freeze(s.concat(e));const o=await sr("key",e.key,i,s);if(o===Dt)return Dt;o===_n&&(e.key=null);const u=await sr("value",e.value,i,s);if(u===Dt)return Dt;u===_n&&(e.value=null)}}return a}function hv(n){return typeof n=="object"&&(n.Collection||n.Node||n.Value)?Object.assign({Alias:n.Node,Map:n.Node,Scalar:n.Node,Seq:n.Node},n.Value&&{Map:n.Value,Scalar:n.Value,Seq:n.Value},n.Collection&&{Map:n.Collection,Seq:n.Collection},n):n}function dv(n,e,i,s){var a,o,u,f,d;if(typeof i=="function")return i(n,e,s);if(br(e))return(a=i.Map)==null?void 0:a.call(i,n,e,s);if(vr(e))return(o=i.Seq)==null?void 0:o.call(i,n,e,s);if(Be(e))return(u=i.Pair)==null?void 0:u.call(i,n,e,s);if(Re(e))return(f=i.Scalar)==null?void 0:f.call(i,n,e,s);if(is(e))return(d=i.Alias)==null?void 0:d.call(i,n,e,s)}function pv(n,e,i){const s=e[e.length-1];if(He(s))s.items[n]=i;else if(Be(s))n==="key"?s.key=i:s.value=i;else if(ss(s))s.contents=i;else{const a=is(s)?"alias":"scalar";throw new Error(`Cannot replace node with ${a} parent`)}}const hA={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},dA=n=>n.replace(/[!,[\]{}]/g,e=>hA[e]);class wt{constructor(e,i){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},wt.defaultYaml,e),this.tags=Object.assign({},wt.defaultTags,i)}clone(){const e=new wt(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){const e=new wt(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:wt.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},wt.defaultTags);break}return e}add(e,i){this.atNextDocument&&(this.yaml={explicit:wt.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},wt.defaultTags),this.atNextDocument=!1);const s=e.trim().split(/[ \t]+/),a=s.shift();switch(a){case"%TAG":{if(s.length!==2&&(i(0,"%TAG directive should contain exactly two parts"),s.length<2))return!1;const[o,u]=s;return this.tags[o]=u,!0}case"%YAML":{if(this.yaml.explicit=!0,s.length!==1)return i(0,"%YAML directive should contain exactly one part"),!1;const[o]=s;if(o==="1.1"||o==="1.2")return this.yaml.version=o,!0;{const u=/^\d+\.\d+$/.test(o);return i(6,`Unsupported YAML version ${o}`,u),!1}}default:return i(0,`Unknown directive ${a}`,!0),!1}}tagName(e,i){if(e==="!")return"!";if(e[0]!=="!")return i(`Not a valid tag: ${e}`),null;if(e[1]==="<"){const u=e.slice(2,-1);return u==="!"||u==="!!"?(i(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(e[e.length-1]!==">"&&i("Verbatim tags must end with a >"),u)}const[,s,a]=e.match(/^(.*!)([^!]*)$/s);a||i(`The ${e} tag has no suffix`);const o=this.tags[s];if(o)try{return o+decodeURIComponent(a)}catch(u){return i(String(u)),null}return s==="!"?e:(i(`Could not resolve tag: ${e}`),null)}tagString(e){for(const[i,s]of Object.entries(this.tags))if(e.startsWith(s))return i+dA(e.substring(s.length));return e[0]==="!"?e:`!<${e}>`}toString(e){const i=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],s=Object.entries(this.tags);let a;if(e&&s.length>0&&qe(e.contents)){const o={};wi(e.contents,(u,f)=>{qe(f)&&f.tag&&(o[f.tag]=!0)}),a=Object.keys(o)}else a=[];for(const[o,u]of s)o==="!!"&&u==="tag:yaml.org,2002:"||(!e||a.some(f=>f.startsWith(u)))&&i.push(`%TAG ${o} ${u}`);return i.join(`
|
|
129
|
+
`)}}wt.defaultYaml={explicit:!1,version:"1.2"};wt.defaultTags={"!!":"tag:yaml.org,2002:"};function gv(n){if(/[\x00-\x19\s,[\]{}]/.test(n)){const i=`Anchor must not contain whitespace or control characters: ${JSON.stringify(n)}`;throw new Error(i)}return!0}function mv(n){const e=new Set;return wi(n,{Value(i,s){s.anchor&&e.add(s.anchor)}}),e}function yv(n,e){for(let i=1;;++i){const s=`${n}${i}`;if(!e.has(s))return s}}function pA(n,e){const i=[],s=new Map;let a=null;return{onAnchor:o=>{i.push(o),a||(a=mv(n));const u=yv(e,a);return a.add(u),u},setAnchors:()=>{for(const o of i){const u=s.get(o);if(typeof u=="object"&&u.anchor&&(Re(u.node)||He(u.node)))u.node.anchor=u.anchor;else{const f=new Error("Failed to resolve repeated object (this should not happen)");throw f.source=o,f}}},sourceObjects:s}}function rr(n,e,i,s){if(s&&typeof s=="object")if(Array.isArray(s))for(let a=0,o=s.length;a<o;++a){const u=s[a],f=rr(n,s,String(a),u);f===void 0?delete s[a]:f!==u&&(s[a]=f)}else if(s instanceof Map)for(const a of Array.from(s.keys())){const o=s.get(a),u=rr(n,s,a,o);u===void 0?s.delete(a):u!==o&&s.set(a,u)}else if(s instanceof Set)for(const a of Array.from(s)){const o=rr(n,s,a,a);o===void 0?s.delete(a):o!==a&&(s.delete(a),s.add(o))}else for(const[a,o]of Object.entries(s)){const u=rr(n,s,a,o);u===void 0?delete s[a]:u!==o&&(s[a]=u)}return n.call(e,i,s)}function ln(n,e,i){if(Array.isArray(n))return n.map((s,a)=>ln(s,String(a),i));if(n&&typeof n.toJSON=="function"){if(!i||!fA(n))return n.toJSON(e,i);const s={aliasCount:0,count:1,res:void 0};i.anchors.set(n,s),i.onCreate=o=>{s.res=o,delete i.onCreate};const a=n.toJSON(e,i);return i.onCreate&&i.onCreate(a),a}return typeof n=="bigint"&&!(i!=null&&i.keep)?Number(n):n}class od{constructor(e){Object.defineProperty(this,on,{value:e})}clone(){const e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:i,maxAliasCount:s,onAnchor:a,reviver:o}={}){if(!ss(e))throw new TypeError("A document argument is required");const u={anchors:new Map,doc:e,keep:!0,mapAsMap:i===!0,mapKeyWarned:!1,maxAliasCount:typeof s=="number"?s:100},f=ln(this,"",u);if(typeof a=="function")for(const{count:d,res:p}of u.anchors.values())a(p,d);return typeof o=="function"?rr(o,{"":f},"",f):f}}class fc extends od{constructor(e){super(ld),this.source=e,Object.defineProperty(this,"tag",{set(){throw new Error("Alias nodes cannot have tags")}})}resolve(e){let i;return wi(e,{Node:(s,a)=>{if(a===this)return wi.BREAK;a.anchor===this.source&&(i=a)}}),i}toJSON(e,i){if(!i)return{source:this.source};const{anchors:s,doc:a,maxAliasCount:o}=i,u=this.resolve(a);if(!u){const d=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new ReferenceError(d)}let f=s.get(u);if(f||(ln(u,null,i),f=s.get(u)),!f||f.res===void 0){const d="This should not happen: Alias anchor was not resolved?";throw new ReferenceError(d)}if(o>=0&&(f.count+=1,f.aliasCount===0&&(f.aliasCount=zo(a,u,s)),f.count*f.aliasCount>o)){const d="Excessive alias count indicates a resource exhaustion attack";throw new ReferenceError(d)}return f.res}toString(e,i,s){const a=`*${this.source}`;if(e){if(gv(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){const o=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new Error(o)}if(e.implicitKey)return`${a} `}return a}}function zo(n,e,i){if(is(e)){const s=e.resolve(n),a=i&&s&&i.get(s);return a?a.count*a.aliasCount:0}else if(He(e)){let s=0;for(const a of e.items){const o=zo(n,a,i);o>s&&(s=o)}return s}else if(Be(e)){const s=zo(n,e.key,i),a=zo(n,e.value,i);return Math.max(s,a)}return 1}const bv=n=>!n||typeof n!="function"&&typeof n!="object";class fe extends od{constructor(e){super(Tn),this.value=e}toJSON(e,i){return i!=null&&i.keep?this.value:ln(this.value,e,i)}toString(){return String(this.value)}}fe.BLOCK_FOLDED="BLOCK_FOLDED";fe.BLOCK_LITERAL="BLOCK_LITERAL";fe.PLAIN="PLAIN";fe.QUOTE_DOUBLE="QUOTE_DOUBLE";fe.QUOTE_SINGLE="QUOTE_SINGLE";const gA="tag:yaml.org,2002:";function mA(n,e,i){if(e){const s=i.filter(o=>o.tag===e),a=s.find(o=>!o.format)??s[0];if(!a)throw new Error(`Tag ${e} not found`);return a}return i.find(s=>{var a;return((a=s.identify)==null?void 0:a.call(s,n))&&!s.format})}function Za(n,e,i){var y,b,w;if(ss(n)&&(n=n.contents),qe(n))return n;if(Be(n)){const E=(b=(y=i.schema[Si]).createNode)==null?void 0:b.call(y,i.schema,null,i);return E.items.push(n),E}(n instanceof String||n instanceof Number||n instanceof Boolean||typeof BigInt<"u"&&n instanceof BigInt)&&(n=n.valueOf());const{aliasDuplicateObjects:s,onAnchor:a,onTagObj:o,schema:u,sourceObjects:f}=i;let d;if(s&&n&&typeof n=="object"){if(d=f.get(n),d)return d.anchor||(d.anchor=a(n)),new fc(d.anchor);d={anchor:null,node:null},f.set(n,d)}e!=null&&e.startsWith("!!")&&(e=gA+e.slice(2));let p=mA(n,e,u.tags);if(!p){if(n&&typeof n.toJSON=="function"&&(n=n.toJSON()),!n||typeof n!="object"){const E=new fe(n);return d&&(d.node=E),E}p=n instanceof Map?u[Si]:Symbol.iterator in Object(n)?u[yr]:u[Si]}o&&(o(p),delete i.onTagObj);const m=p!=null&&p.createNode?p.createNode(i.schema,n,i):typeof((w=p==null?void 0:p.nodeClass)==null?void 0:w.from)=="function"?p.nodeClass.from(i.schema,n,i):new fe(n);return e?m.tag=e:p.default||(m.tag=p.tag),d&&(d.node=m),m}function Wo(n,e,i){let s=i;for(let a=e.length-1;a>=0;--a){const o=e[a];if(typeof o=="number"&&Number.isInteger(o)&&o>=0){const u=[];u[o]=s,s=u}else s=new Map([[o,s]])}return Za(s,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw new Error("This should not happen, please report a bug.")},schema:n,sourceObjects:new Map})}const Ha=n=>n==null||typeof n=="object"&&!!n[Symbol.iterator]().next().done;class vv extends od{constructor(e,i){super(e),Object.defineProperty(this,"schema",{value:i,configurable:!0,enumerable:!1,writable:!0})}clone(e){const i=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(i.schema=e),i.items=i.items.map(s=>qe(s)||Be(s)?s.clone(e):s),this.range&&(i.range=this.range.slice()),i}addIn(e,i){if(Ha(e))this.add(i);else{const[s,...a]=e,o=this.get(s,!0);if(He(o))o.addIn(a,i);else if(o===void 0&&this.schema)this.set(s,Wo(this.schema,a,i));else throw new Error(`Expected YAML collection at ${s}. Remaining path: ${a}`)}}deleteIn(e){const[i,...s]=e;if(s.length===0)return this.delete(i);const a=this.get(i,!0);if(He(a))return a.deleteIn(s);throw new Error(`Expected YAML collection at ${i}. Remaining path: ${s}`)}getIn(e,i){const[s,...a]=e,o=this.get(s,!0);return a.length===0?!i&&Re(o)?o.value:o:He(o)?o.getIn(a,i):void 0}hasAllNullValues(e){return this.items.every(i=>{if(!Be(i))return!1;const s=i.value;return s==null||e&&Re(s)&&s.value==null&&!s.commentBefore&&!s.comment&&!s.tag})}hasIn(e){const[i,...s]=e;if(s.length===0)return this.has(i);const a=this.get(i,!0);return He(a)?a.hasIn(s):!1}setIn(e,i){const[s,...a]=e;if(a.length===0)this.set(s,i);else{const o=this.get(s,!0);if(He(o))o.setIn(a,i);else if(o===void 0&&this.schema)this.set(s,Wo(this.schema,a,i));else throw new Error(`Expected YAML collection at ${s}. Remaining path: ${a}`)}}}const yA=n=>n.replace(/^(?!$)(?: $)?/gm,"#");function Kn(n,e){return/^\n+$/.test(n)?n.substring(1):e?n.replace(/^(?! *$)/gm,e):n}const Fi=(n,e,i)=>n.endsWith(`
|
|
130
130
|
`)?Kn(i,e):i.includes(`
|
|
131
131
|
`)?`
|
|
132
|
-
`+Kn(i,e):(n.endsWith(" ")?"":" ")+i,
|
|
132
|
+
`+Kn(i,e):(n.endsWith(" ")?"":" ")+i,Sv="flow",Th="block",Ho="quoted";function hc(n,e,i="flow",{indentAtStart:s,lineWidth:a=80,minContentWidth:o=20,onFold:u,onOverflow:f}={}){if(!a||a<0)return n;a<o&&(o=0);const d=Math.max(1+o,1+a-e.length);if(n.length<=d)return n;const p=[],m={};let y=a-e.length;typeof s=="number"&&(s>a-Math.max(2,o)?p.push(0):y=a-s);let b,w,E=!1,x=-1,_=-1,k=-1;i===Th&&(x=l0(n,x,e.length),x!==-1&&(y=x+d));for(let V;V=n[x+=1];){if(i===Ho&&V==="\\"){switch(_=x,n[x+1]){case"x":x+=3;break;case"u":x+=5;break;case"U":x+=9;break;default:x+=1}k=x}if(V===`
|
|
133
133
|
`)i===Th&&(x=l0(n,x,e.length)),y=x+e.length+d,b=void 0;else{if(V===" "&&w&&w!==" "&&w!==`
|
|
134
134
|
`&&w!==" "){const I=n[x+1];I&&I!==" "&&I!==`
|
|
135
135
|
`&&I!==" "&&(b=x)}if(x>=y)if(b)p.push(b),y=b+d,b=void 0;else if(i===Ho){for(;w===" "||w===" ";)w=V,V=n[x+=1],E=!0;const I=x>k+1?x-2:_-1;if(m[I])return n;p.push(I),m[I]=!0,y=I+d,b=void 0}else E=!0}w=V}if(E&&f&&f(),p.length===0)return n;u&&u();let C=n.slice(0,p[0]);for(let V=0;V<p.length;++V){const I=p[V],B=p[V+1]||n.length;I===0?C=`
|
|
136
136
|
${e}${n.slice(0,B)}`:(i===Ho&&m[I]&&(C+=`${n[I]}\\`),C+=`
|
|
137
137
|
${e}${n.slice(I+1,B)}`)}return C}function l0(n,e,i){let s=e,a=e+1,o=n[a];for(;o===" "||o===" ";)if(e<a+i)o=n[++e];else{do o=n[++e];while(o&&o!==`
|
|
138
|
-
`);s=e,a=e+1,o=n[a]}return s}const dc=(n,e)=>({indentAtStart:e?n.indent.length:n.indentAtStart,lineWidth:n.options.lineWidth,minContentWidth:n.options.minContentWidth}),pc=n=>/^(%|---|\.\.\.)/m.test(n);function
|
|
138
|
+
`);s=e,a=e+1,o=n[a]}return s}const dc=(n,e)=>({indentAtStart:e?n.indent.length:n.indentAtStart,lineWidth:n.options.lineWidth,minContentWidth:n.options.minContentWidth}),pc=n=>/^(%|---|\.\.\.)/m.test(n);function bA(n,e,i){if(!e||e<0)return!1;const s=e-i,a=n.length;if(a<=s)return!1;for(let o=0,u=0;o<a;++o)if(n[o]===`
|
|
139
139
|
`){if(o-u>s)return!0;if(u=o+1,a-u<=s)return!1}return!0}function Xa(n,e){const i=JSON.stringify(n);if(e.options.doubleQuotedAsJSON)return i;const{implicitKey:s}=e,a=e.options.doubleQuotedMinMultiLineLength,o=e.indent||(pc(n)?" ":"");let u="",f=0;for(let d=0,p=i[d];p;p=i[++d])if(p===" "&&i[d+1]==="\\"&&i[d+2]==="n"&&(u+=i.slice(f,d)+"\\ ",d+=1,f=d,p="\\"),p==="\\")switch(i[d+1]){case"u":{u+=i.slice(f,d);const m=i.substr(d+2,4);switch(m){case"0000":u+="\\0";break;case"0007":u+="\\a";break;case"000b":u+="\\v";break;case"001b":u+="\\e";break;case"0085":u+="\\N";break;case"00a0":u+="\\_";break;case"2028":u+="\\L";break;case"2029":u+="\\P";break;default:m.substr(0,2)==="00"?u+="\\x"+m.substr(2):u+=i.substr(d,6)}d+=5,f=d+1}break;case"n":if(s||i[d+2]==='"'||i.length<a)d+=1;else{for(u+=i.slice(f,d)+`
|
|
140
140
|
|
|
141
141
|
`;i[d+2]==="\\"&&i[d+3]==="n"&&i[d+4]!=='"';)u+=`
|
|
142
142
|
`,d+=2;u+=o,i[d+2]===" "&&(u+="\\"),d+=1,f=d+1}break;default:d+=1}return u=f?u+i.slice(f):i,s?u:hc(u,o,Ho,dc(e,!1))}function Eh(n,e){if(e.options.singleQuote===!1||e.implicitKey&&n.includes(`
|
|
143
143
|
`)||/[ \t]\n|\n[ \t]/.test(n))return Xa(n,e);const i=e.indent||(pc(n)?" ":""),s="'"+n.replace(/'/g,"''").replace(/\n+/g,`$&
|
|
144
|
-
${i}`)+"'";return e.implicitKey?s:hc(s,i,
|
|
144
|
+
${i}`)+"'";return e.implicitKey?s:hc(s,i,Sv,dc(e,!1))}function ar(n,e){const{singleQuote:i}=e.options;let s;if(i===!1)s=Xa;else{const a=n.includes('"'),o=n.includes("'");a&&!o?s=Eh:o&&!a?s=Xa:s=i?Eh:Xa}return s(n,e)}let Ah;try{Ah=new RegExp(`(^|(?<!
|
|
145
145
|
))
|
|
146
146
|
+(?!
|
|
147
|
-
|$)`,"g")}catch{Ah=/\n+(?!\n|$)/g}function qo({comment:n,type:e,value:i},s,a,o){const{blockQuote:u,commentString:f,lineWidth:d}=s.options;if(!u||/\n[\t ]+$/.test(i)||/^\s*$/.test(i))return ar(i,s);const p=s.indent||(s.forceBlockIndent||pc(i)?" ":""),m=u==="literal"?!0:u==="folded"||e===fe.BLOCK_FOLDED?!1:e===fe.BLOCK_LITERAL?!0:!
|
|
147
|
+
|$)`,"g")}catch{Ah=/\n+(?!\n|$)/g}function qo({comment:n,type:e,value:i},s,a,o){const{blockQuote:u,commentString:f,lineWidth:d}=s.options;if(!u||/\n[\t ]+$/.test(i)||/^\s*$/.test(i))return ar(i,s);const p=s.indent||(s.forceBlockIndent||pc(i)?" ":""),m=u==="literal"?!0:u==="folded"||e===fe.BLOCK_FOLDED?!1:e===fe.BLOCK_LITERAL?!0:!bA(i,d,p.length);if(!i)return m?`|
|
|
148
148
|
`:`>
|
|
149
149
|
`;let y,b;for(b=i.length;b>0;--b){const G=i[b-1];if(G!==`
|
|
150
150
|
`&&G!==" "&&G!==" ")break}let w=i.substring(b);const E=w.indexOf(`
|
|
@@ -153,12 +153,12 @@ ${i}`)+"'";return e.implicitKey?s:hc(s,i,vv,dc(e,!1))}function ar(n,e){const{sin
|
|
|
153
153
|
`)k=_;else break}let C=i.substring(0,k<_?k+1:_);C&&(i=i.substring(C.length),C=C.replace(/\n+/g,`$&${p}`));let I=(m?"|":">")+(x?p?"2":"1":"")+y;if(n&&(I+=" "+f(n.replace(/ ?[\r\n]+/g," ")),a&&a()),m)return i=i.replace(/\n+/g,`$&${p}`),`${I}
|
|
154
154
|
${p}${C}${i}${w}`;i=i.replace(/\n+/g,`
|
|
155
155
|
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${p}`);const B=hc(`${C}${i}${w}`,p,Th,dc(s,!0));return`${I}
|
|
156
|
-
${p}${B}`}function
|
|
156
|
+
${p}${B}`}function vA(n,e,i,s){const{type:a,value:o}=n,{actualString:u,implicitKey:f,indent:d,indentStep:p,inFlow:m}=e;if(f&&o.includes(`
|
|
157
157
|
`)||m&&/[[\]{},]/.test(o))return ar(o,e);if(!o||/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(o))return f||m||!o.includes(`
|
|
158
158
|
`)?ar(o,e):qo(n,e,i,s);if(!f&&!m&&a!==fe.PLAIN&&o.includes(`
|
|
159
159
|
`))return qo(n,e,i,s);if(pc(o)){if(d==="")return e.forceBlockIndent=!0,qo(n,e,i,s);if(f&&d===p)return ar(o,e)}const y=o.replace(/\n+/g,`$&
|
|
160
|
-
${d}`);if(u){const b=x=>{var _;return x.default&&x.tag!=="tag:yaml.org,2002:str"&&((_=x.test)==null?void 0:_.test(y))},{compat:w,tags:E}=e.doc.schema;if(E.some(b)||w!=null&&w.some(b))return ar(o,e)}return f?y:hc(y,d,
|
|
161
|
-
${e.indent}${f}`:f}function
|
|
160
|
+
${d}`);if(u){const b=x=>{var _;return x.default&&x.tag!=="tag:yaml.org,2002:str"&&((_=x.test)==null?void 0:_.test(y))},{compat:w,tags:E}=e.doc.schema;if(E.some(b)||w!=null&&w.some(b))return ar(o,e)}return f?y:hc(y,d,Sv,dc(e,!1))}function nl(n,e,i,s){const{implicitKey:a,inFlow:o}=e,u=typeof n.value=="string"?n:Object.assign({},n,{value:String(n.value)});let{type:f}=n;f!==fe.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(u.value)&&(f=fe.QUOTE_DOUBLE);const d=m=>{switch(m){case fe.BLOCK_FOLDED:case fe.BLOCK_LITERAL:return a||o?ar(u.value,e):qo(u,e,i,s);case fe.QUOTE_DOUBLE:return Xa(u.value,e);case fe.QUOTE_SINGLE:return Eh(u.value,e);case fe.PLAIN:return vA(u,e,i,s);default:return null}};let p=d(f);if(p===null){const{defaultKeyType:m,defaultStringType:y}=e.options,b=a&&m||y;if(p=d(b),p===null)throw new Error(`Unsupported default string type ${b}`)}return p}function wv(n,e){const i=Object.assign({blockQuote:!0,commentString:yA,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trueStr:"true",verifyAliasOrder:!0},n.schema.toStringOptions,e);let s;switch(i.collectionStyle){case"block":s=!1;break;case"flow":s=!0;break;default:s=null}return{anchors:new Set,doc:n,flowCollectionPadding:i.flowCollectionPadding?" ":"",indent:"",indentStep:typeof i.indent=="number"?" ".repeat(i.indent):" ",inFlow:s,options:i}}function SA(n,e){var a;if(e.tag){const o=n.filter(u=>u.tag===e.tag);if(o.length>0)return o.find(u=>u.format===e.format)??o[0]}let i,s;if(Re(e)){s=e.value;let o=n.filter(u=>{var f;return(f=u.identify)==null?void 0:f.call(u,s)});if(o.length>1){const u=o.filter(f=>f.test);u.length>0&&(o=u)}i=o.find(u=>u.format===e.format)??o.find(u=>!u.format)}else s=e,i=n.find(o=>o.nodeClass&&s instanceof o.nodeClass);if(!i){const o=((a=s==null?void 0:s.constructor)==null?void 0:a.name)??typeof s;throw new Error(`Tag not resolved for ${o} value`)}return i}function wA(n,e,{anchors:i,doc:s}){if(!s.directives)return"";const a=[],o=(Re(n)||He(n))&&n.anchor;o&&gv(o)&&(i.add(o),a.push(`&${o}`));const u=n.tag?n.tag:e.default?null:e.tag;return u&&a.push(s.directives.tagString(u)),a.join(" ")}function fr(n,e,i,s){var d;if(Be(n))return n.toString(e,i,s);if(is(n)){if(e.doc.directives)return n.toString(e);if((d=e.resolvedAliases)!=null&&d.has(n))throw new TypeError("Cannot stringify circular structure without alias nodes");e.resolvedAliases?e.resolvedAliases.add(n):e.resolvedAliases=new Set([n]),n=n.resolve(e.doc)}let a;const o=qe(n)?n:e.doc.createNode(n,{onTagObj:p=>a=p});a||(a=SA(e.doc.schema.tags,o));const u=wA(o,a,e);u.length>0&&(e.indentAtStart=(e.indentAtStart??0)+u.length+1);const f=typeof a.stringify=="function"?a.stringify(o,e,i,s):Re(o)?nl(o,e,i,s):o.toString(e,i,s);return u?Re(o)||f[0]==="{"||f[0]==="["?`${u} ${f}`:`${u}
|
|
161
|
+
${e.indent}${f}`:f}function xA({key:n,value:e},i,s,a){const{allNullValues:o,doc:u,indent:f,indentStep:d,options:{commentString:p,indentSeq:m,simpleKeys:y}}=i;let b=qe(n)&&n.comment||null;if(y){if(b)throw new Error("With simple keys, key nodes cannot have comments");if(He(n)||!qe(n)&&typeof n=="object"){const J="With simple keys, collection cannot be used as a key value";throw new Error(J)}}let w=!y&&(!n||b&&e==null&&!i.inFlow||He(n)||(Re(n)?n.type===fe.BLOCK_FOLDED||n.type===fe.BLOCK_LITERAL:typeof n=="object"));i=Object.assign({},i,{allNullValues:!1,implicitKey:!w&&(y||!o),indent:f+d});let E=!1,x=!1,_=fr(n,i,()=>E=!0,()=>x=!0);if(!w&&!i.inFlow&&_.length>1024){if(y)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");w=!0}if(i.inFlow){if(o||e==null)return E&&s&&s(),_===""?"?":w?`? ${_}`:_}else if(o&&!y||e==null&&w)return _=`? ${_}`,b&&!E?_+=Fi(_,i.indent,p(b)):x&&a&&a(),_;E&&(b=null),w?(b&&(_+=Fi(_,i.indent,p(b))),_=`? ${_}
|
|
162
162
|
${f}:`):(_=`${_}:`,b&&(_+=Fi(_,i.indent,p(b))));let k,C,V;qe(e)?(k=!!e.spaceBefore,C=e.commentBefore,V=e.comment):(k=!1,C=null,V=null,e&&typeof e=="object"&&(e=u.createNode(e))),i.implicitKey=!1,!w&&!b&&Re(e)&&(i.indentAtStart=_.length+1),x=!1,!m&&d.length>=2&&!i.inFlow&&!w&&vr(e)&&!e.flow&&!e.tag&&!e.anchor&&(i.indent=i.indent.substring(2));let I=!1;const B=fr(e,i,()=>I=!0,()=>x=!0);let G=" ";if(b||k||C){if(G=k?`
|
|
163
163
|
`:"",C){const J=p(C);G+=`
|
|
164
164
|
${Kn(J,i.indent)}`}B===""&&!i.inFlow?G===`
|
|
@@ -168,32 +168,32 @@ ${Kn(J,i.indent)}`}B===""&&!i.inFlow?G===`
|
|
|
168
168
|
${i.indent}`}else if(!w&&He(e)){const J=B[0],$=B.indexOf(`
|
|
169
169
|
`),R=$!==-1,ee=i.inFlow??e.flow??e.items.length===0;if(R||!ee){let re=!1;if(R&&(J==="&"||J==="!")){let j=B.indexOf(" ");J==="&"&&j!==-1&&j<$&&B[j+1]==="!"&&(j=B.indexOf(" ",j+1)),(j===-1||$<j)&&(re=!0)}re||(G=`
|
|
170
170
|
${i.indent}`)}}else(B===""||B[0]===`
|
|
171
|
-
`)&&(G="");return _+=G+B,i.inFlow?I&&s&&s():V&&!I?_+=Fi(_,i.indent,p(V)):x&&a&&a(),_}function
|
|
171
|
+
`)&&(G="");return _+=G+B,i.inFlow?I&&s&&s():V&&!I?_+=Fi(_,i.indent,p(V)):x&&a&&a(),_}function xv(n,e){(n==="debug"||n==="warn")&&(typeof process<"u"&&process.emitWarning?process.emitWarning(e):console.warn(e))}const To="<<",Yn={identify:n=>n===To||typeof n=="symbol"&&n.description===To,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new fe(Symbol(To)),{addToJSMap:_v}),stringify:()=>To},_A=(n,e)=>(Yn.identify(e)||Re(e)&&(!e.type||e.type===fe.PLAIN)&&Yn.identify(e.value))&&(n==null?void 0:n.doc.schema.tags.some(i=>i.tag===Yn.tag&&i.default));function _v(n,e,i){if(i=n&&is(i)?i.resolve(n.doc):i,vr(i))for(const s of i.items)ih(n,e,s);else if(Array.isArray(i))for(const s of i)ih(n,e,s);else ih(n,e,i)}function ih(n,e,i){const s=n&&is(i)?i.resolve(n.doc):i;if(!br(s))throw new Error("Merge sources must be maps or map aliases");const a=s.toJSON(null,n,Map);for(const[o,u]of a)e instanceof Map?e.has(o)||e.set(o,u):e instanceof Set?e.add(o):Object.prototype.hasOwnProperty.call(e,o)||Object.defineProperty(e,o,{value:u,writable:!0,enumerable:!0,configurable:!0});return e}function Tv(n,e,{key:i,value:s}){if(qe(i)&&i.addToJSMap)i.addToJSMap(n,e,s);else if(_A(n,i))_v(n,e,s);else{const a=ln(i,"",n);if(e instanceof Map)e.set(a,ln(s,a,n));else if(e instanceof Set)e.add(a);else{const o=TA(i,a,n),u=ln(s,o,n);o in e?Object.defineProperty(e,o,{value:u,writable:!0,enumerable:!0,configurable:!0}):e[o]=u}}return e}function TA(n,e,i){if(e===null)return"";if(typeof e!="object")return String(e);if(qe(n)&&(i!=null&&i.doc)){const s=wv(i.doc,{});s.anchors=new Set;for(const o of i.anchors.keys())s.anchors.add(o.anchor);s.inFlow=!0,s.inStringifyKey=!0;const a=n.toString(s);if(!i.mapKeyWarned){let o=JSON.stringify(a);o.length>40&&(o=o.substring(0,36)+'..."'),xv(i.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${o}. Set mapAsMap: true to use object keys.`),i.mapKeyWarned=!0}return a}return JSON.stringify(e)}function cd(n,e,i){const s=Za(n,void 0,i),a=Za(e,void 0,i);return new bt(s,a)}class bt{constructor(e,i=null){Object.defineProperty(this,on,{value:uv}),this.key=e,this.value=i}clone(e){let{key:i,value:s}=this;return qe(i)&&(i=i.clone(e)),qe(s)&&(s=s.clone(e)),new bt(i,s)}toJSON(e,i){const s=i!=null&&i.mapAsMap?new Map:{};return Tv(i,s,this)}toString(e,i,s){return e!=null&&e.doc?xA(this,e,i,s):JSON.stringify(this)}}function Ev(n,e,i){return(e.inFlow??n.flow?AA:EA)(n,e,i)}function EA({comment:n,items:e},i,{blockItemPrefix:s,flowChars:a,itemIndent:o,onChompKeep:u,onComment:f}){const{indent:d,options:{commentString:p}}=i,m=Object.assign({},i,{indent:o,type:null});let y=!1;const b=[];for(let E=0;E<e.length;++E){const x=e[E];let _=null;if(qe(x))!y&&x.spaceBefore&&b.push(""),ec(i,b,x.commentBefore,y),x.comment&&(_=x.comment);else if(Be(x)){const C=qe(x.key)?x.key:null;C&&(!y&&C.spaceBefore&&b.push(""),ec(i,b,C.commentBefore,y))}y=!1;let k=fr(x,m,()=>_=null,()=>y=!0);_&&(k+=Fi(k,o,p(_))),y&&_&&(y=!1),b.push(s+k)}let w;if(b.length===0)w=a.start+a.end;else{w=b[0];for(let E=1;E<b.length;++E){const x=b[E];w+=x?`
|
|
172
172
|
${d}${x}`:`
|
|
173
173
|
`}}return n?(w+=`
|
|
174
|
-
`+Kn(p(n),d),f&&f()):y&&u&&u(),w}function
|
|
174
|
+
`+Kn(p(n),d),f&&f()):y&&u&&u(),w}function AA({items:n},e,{flowChars:i,itemIndent:s}){const{indent:a,indentStep:o,flowCollectionPadding:u,options:{commentString:f}}=e;s+=o;const d=Object.assign({},e,{indent:s,inFlow:!0,type:null});let p=!1,m=0;const y=[];for(let E=0;E<n.length;++E){const x=n[E];let _=null;if(qe(x))x.spaceBefore&&y.push(""),ec(e,y,x.commentBefore,!1),x.comment&&(_=x.comment);else if(Be(x)){const C=qe(x.key)?x.key:null;C&&(C.spaceBefore&&y.push(""),ec(e,y,C.commentBefore,!1),C.comment&&(p=!0));const V=qe(x.value)?x.value:null;V?(V.comment&&(_=V.comment),V.commentBefore&&(p=!0)):x.value==null&&(C!=null&&C.comment)&&(_=C.comment)}_&&(p=!0);let k=fr(x,d,()=>_=null);E<n.length-1&&(k+=","),_&&(k+=Fi(k,s,f(_))),!p&&(y.length>m||k.includes(`
|
|
175
175
|
`))&&(p=!0),y.push(k),m=y.length}const{start:b,end:w}=i;if(y.length===0)return b+w;if(!p){const E=y.reduce((x,_)=>x+_.length+2,2);p=e.options.lineWidth>0&&E>e.options.lineWidth}if(p){let E=b;for(const x of y)E+=x?`
|
|
176
176
|
${o}${a}${x}`:`
|
|
177
177
|
`;return`${E}
|
|
178
|
-
${a}${w}`}else return`${b}${u}${y.join(" ")}${u}${w}`}function ec({indent:n,options:{commentString:e}},i,s,a){if(s&&a&&(s=s.replace(/^\n+/,"")),s){const o=Kn(e(s),n);i.push(o.trimStart())}}function Qi(n,e){const i=Re(e)?e.value:e;for(const s of n)if(Be(s)&&(s.key===e||s.key===i||Re(s.key)&&s.key.value===i))return s}class Xt extends
|
|
179
|
-
`:" ")}return nl({comment:n,type:e,value:f},s,a,o)}};function
|
|
178
|
+
${a}${w}`}else return`${b}${u}${y.join(" ")}${u}${w}`}function ec({indent:n,options:{commentString:e}},i,s,a){if(s&&a&&(s=s.replace(/^\n+/,"")),s){const o=Kn(e(s),n);i.push(o.trimStart())}}function Qi(n,e){const i=Re(e)?e.value:e;for(const s of n)if(Be(s)&&(s.key===e||s.key===i||Re(s.key)&&s.key.value===i))return s}class Xt extends vv{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(Si,e),this.items=[]}static from(e,i,s){const{keepUndefined:a,replacer:o}=s,u=new this(e),f=(d,p)=>{if(typeof o=="function")p=o.call(i,d,p);else if(Array.isArray(o)&&!o.includes(d))return;(p!==void 0||a)&&u.items.push(cd(d,p,s))};if(i instanceof Map)for(const[d,p]of i)f(d,p);else if(i&&typeof i=="object")for(const d of Object.keys(i))f(d,i[d]);return typeof e.sortMapEntries=="function"&&u.items.sort(e.sortMapEntries),u}add(e,i){var u;let s;Be(e)?s=e:!e||typeof e!="object"||!("key"in e)?s=new bt(e,e==null?void 0:e.value):s=new bt(e.key,e.value);const a=Qi(this.items,s.key),o=(u=this.schema)==null?void 0:u.sortMapEntries;if(a){if(!i)throw new Error(`Key ${s.key} already set`);Re(a.value)&&bv(s.value)?a.value.value=s.value:a.value=s.value}else if(o){const f=this.items.findIndex(d=>o(s,d)<0);f===-1?this.items.push(s):this.items.splice(f,0,s)}else this.items.push(s)}delete(e){const i=Qi(this.items,e);return i?this.items.splice(this.items.indexOf(i),1).length>0:!1}get(e,i){const s=Qi(this.items,e),a=s==null?void 0:s.value;return(!i&&Re(a)?a.value:a)??void 0}has(e){return!!Qi(this.items,e)}set(e,i){this.add(new bt(e,i),!0)}toJSON(e,i,s){const a=s?new s:i!=null&&i.mapAsMap?new Map:{};i!=null&&i.onCreate&&i.onCreate(a);for(const o of this.items)Tv(i,a,o);return a}toString(e,i,s){if(!e)return JSON.stringify(this);for(const a of this.items)if(!Be(a))throw new Error(`Map items must all be pairs; found ${JSON.stringify(a)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),Ev(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:s,onComment:i})}}const Sr={collection:"map",default:!0,nodeClass:Xt,tag:"tag:yaml.org,2002:map",resolve(n,e){return br(n)||e("Expected a mapping for this tag"),n},createNode:(n,e,i)=>Xt.from(n,e,i)};class xi extends vv{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(yr,e),this.items=[]}add(e){this.items.push(e)}delete(e){const i=Eo(e);return typeof i!="number"?!1:this.items.splice(i,1).length>0}get(e,i){const s=Eo(e);if(typeof s!="number")return;const a=this.items[s];return!i&&Re(a)?a.value:a}has(e){const i=Eo(e);return typeof i=="number"&&i<this.items.length}set(e,i){const s=Eo(e);if(typeof s!="number")throw new Error(`Expected a valid index, not ${e}.`);const a=this.items[s];Re(a)&&bv(i)?a.value=i:this.items[s]=i}toJSON(e,i){const s=[];i!=null&&i.onCreate&&i.onCreate(s);let a=0;for(const o of this.items)s.push(ln(o,String(a++),i));return s}toString(e,i,s){return e?Ev(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+" ",onChompKeep:s,onComment:i}):JSON.stringify(this)}static from(e,i,s){const{replacer:a}=s,o=new this(e);if(i&&Symbol.iterator in Object(i)){let u=0;for(let f of i){if(typeof a=="function"){const d=i instanceof Set?f:String(u++);f=a.call(i,d,f)}o.items.push(Za(f,void 0,s))}}return o}}function Eo(n){let e=Re(n)?n.value:n;return e&&typeof e=="string"&&(e=Number(e)),typeof e=="number"&&Number.isInteger(e)&&e>=0?e:null}const wr={collection:"seq",default:!0,nodeClass:xi,tag:"tag:yaml.org,2002:seq",resolve(n,e){return vr(n)||e("Expected a sequence for this tag"),n},createNode:(n,e,i)=>xi.from(n,e,i)},gc={identify:n=>typeof n=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:n=>n,stringify(n,e,i,s){return e=Object.assign({actualString:!0},e),nl(n,e,i,s)}},mc={identify:n=>n==null,createNode:()=>new fe(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new fe(null),stringify:({source:n},e)=>typeof n=="string"&&mc.test.test(n)?n:e.options.nullStr},ud={identify:n=>typeof n=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:n=>new fe(n[0]==="t"||n[0]==="T"),stringify({source:n,value:e},i){if(n&&ud.test.test(n)){const s=n[0]==="t"||n[0]==="T";if(e===s)return n}return e?i.options.trueStr:i.options.falseStr}};function pn({format:n,minFractionDigits:e,tag:i,value:s}){if(typeof s=="bigint")return String(s);const a=typeof s=="number"?s:Number(s);if(!isFinite(a))return isNaN(a)?".nan":a<0?"-.inf":".inf";let o=JSON.stringify(s);if(!n&&e&&(!i||i==="tag:yaml.org,2002:float")&&/^\d/.test(o)){let u=o.indexOf(".");u<0&&(u=o.length,o+=".");let f=e-(o.length-u-1);for(;f-- >0;)o+="0"}return o}const Av={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:n=>n.slice(-3).toLowerCase()==="nan"?NaN:n[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:pn},Nv={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:n=>parseFloat(n),stringify(n){const e=Number(n.value);return isFinite(e)?e.toExponential():pn(n)}},Cv={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(n){const e=new fe(parseFloat(n)),i=n.indexOf(".");return i!==-1&&n[n.length-1]==="0"&&(e.minFractionDigits=n.length-i-1),e},stringify:pn},yc=n=>typeof n=="bigint"||Number.isInteger(n),fd=(n,e,i,{intAsBigInt:s})=>s?BigInt(n):parseInt(n.substring(e),i);function kv(n,e,i){const{value:s}=n;return yc(s)&&s>=0?i+s.toString(e):pn(n)}const Mv={identify:n=>yc(n)&&n>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(n,e,i)=>fd(n,2,8,i),stringify:n=>kv(n,8,"0o")},Ov={identify:yc,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(n,e,i)=>fd(n,0,10,i),stringify:pn},Rv={identify:n=>yc(n)&&n>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(n,e,i)=>fd(n,2,16,i),stringify:n=>kv(n,16,"0x")},NA=[Sr,wr,gc,mc,ud,Mv,Ov,Rv,Av,Nv,Cv];function o0(n){return typeof n=="bigint"||Number.isInteger(n)}const Ao=({value:n})=>JSON.stringify(n),CA=[{identify:n=>typeof n=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:n=>n,stringify:Ao},{identify:n=>n==null,createNode:()=>new fe(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:Ao},{identify:n=>typeof n=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true|false$/,resolve:n=>n==="true",stringify:Ao},{identify:o0,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(n,e,{intAsBigInt:i})=>i?BigInt(n):parseInt(n,10),stringify:({value:n})=>o0(n)?n.toString():JSON.stringify(n)},{identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:n=>parseFloat(n),stringify:Ao}],kA={default:!0,tag:"",test:/^/,resolve(n,e){return e(`Unresolved plain scalar ${JSON.stringify(n)}`),n}},MA=[Sr,wr].concat(CA,kA),hd={identify:n=>n instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(n,e){if(typeof Buffer=="function")return Buffer.from(n,"base64");if(typeof atob=="function"){const i=atob(n.replace(/[\n\r]/g,"")),s=new Uint8Array(i.length);for(let a=0;a<i.length;++a)s[a]=i.charCodeAt(a);return s}else return e("This environment does not support reading binary tags; either Buffer or atob is required"),n},stringify({comment:n,type:e,value:i},s,a,o){const u=i;let f;if(typeof Buffer=="function")f=u instanceof Buffer?u.toString("base64"):Buffer.from(u.buffer).toString("base64");else if(typeof btoa=="function"){let d="";for(let p=0;p<u.length;++p)d+=String.fromCharCode(u[p]);f=btoa(d)}else throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(e||(e=fe.BLOCK_LITERAL),e!==fe.QUOTE_DOUBLE){const d=Math.max(s.options.lineWidth-s.indent.length,s.options.minContentWidth),p=Math.ceil(f.length/d),m=new Array(p);for(let y=0,b=0;y<p;++y,b+=d)m[y]=f.substr(b,d);f=m.join(e===fe.BLOCK_LITERAL?`
|
|
179
|
+
`:" ")}return nl({comment:n,type:e,value:f},s,a,o)}};function jv(n,e){if(vr(n))for(let i=0;i<n.items.length;++i){let s=n.items[i];if(!Be(s)){if(br(s)){s.items.length>1&&e("Each pair must have its own sequence indicator");const a=s.items[0]||new bt(new fe(null));if(s.commentBefore&&(a.key.commentBefore=a.key.commentBefore?`${s.commentBefore}
|
|
180
180
|
${a.key.commentBefore}`:s.commentBefore),s.comment){const o=a.value??a.key;o.comment=o.comment?`${s.comment}
|
|
181
|
-
${o.comment}`:s.comment}s=a}n.items[i]=Be(s)?s:new bt(s)}}else e("Expected a sequence for this tag");return n}function
|
|
181
|
+
${o.comment}`:s.comment}s=a}n.items[i]=Be(s)?s:new bt(s)}}else e("Expected a sequence for this tag");return n}function Lv(n,e,i){const{replacer:s}=i,a=new xi(n);a.tag="tag:yaml.org,2002:pairs";let o=0;if(e&&Symbol.iterator in Object(e))for(let u of e){typeof s=="function"&&(u=s.call(e,String(o++),u));let f,d;if(Array.isArray(u))if(u.length===2)f=u[0],d=u[1];else throw new TypeError(`Expected [key, value] tuple: ${u}`);else if(u&&u instanceof Object){const p=Object.keys(u);if(p.length===1)f=p[0],d=u[f];else throw new TypeError(`Expected tuple with one key, not ${p.length} keys`)}else f=u;a.items.push(cd(f,d,i))}return a}const dd={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:jv,createNode:Lv};class or extends xi{constructor(){super(),this.add=Xt.prototype.add.bind(this),this.delete=Xt.prototype.delete.bind(this),this.get=Xt.prototype.get.bind(this),this.has=Xt.prototype.has.bind(this),this.set=Xt.prototype.set.bind(this),this.tag=or.tag}toJSON(e,i){if(!i)return super.toJSON(e);const s=new Map;i!=null&&i.onCreate&&i.onCreate(s);for(const a of this.items){let o,u;if(Be(a)?(o=ln(a.key,"",i),u=ln(a.value,o,i)):o=ln(a,"",i),s.has(o))throw new Error("Ordered maps must not include duplicate keys");s.set(o,u)}return s}static from(e,i,s){const a=Lv(e,i,s),o=new this;return o.items=a.items,o}}or.tag="tag:yaml.org,2002:omap";const pd={collection:"seq",identify:n=>n instanceof Map,nodeClass:or,default:!1,tag:"tag:yaml.org,2002:omap",resolve(n,e){const i=jv(n,e),s=[];for(const{key:a}of i.items)Re(a)&&(s.includes(a.value)?e(`Ordered maps must not include duplicate keys: ${a.value}`):s.push(a.value));return Object.assign(new or,i)},createNode:(n,e,i)=>or.from(n,e,i)};function Dv({value:n,source:e},i){return e&&(n?Bv:Uv).test.test(e)?e:n?i.options.trueStr:i.options.falseStr}const Bv={identify:n=>n===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new fe(!0),stringify:Dv},Uv={identify:n=>n===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new fe(!1),stringify:Dv},OA={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:n=>n.slice(-3).toLowerCase()==="nan"?NaN:n[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:pn},RA={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:n=>parseFloat(n.replace(/_/g,"")),stringify(n){const e=Number(n.value);return isFinite(e)?e.toExponential():pn(n)}},jA={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(n){const e=new fe(parseFloat(n.replace(/_/g,""))),i=n.indexOf(".");if(i!==-1){const s=n.substring(i+1).replace(/_/g,"");s[s.length-1]==="0"&&(e.minFractionDigits=s.length)}return e},stringify:pn},il=n=>typeof n=="bigint"||Number.isInteger(n);function bc(n,e,i,{intAsBigInt:s}){const a=n[0];if((a==="-"||a==="+")&&(e+=1),n=n.substring(e).replace(/_/g,""),s){switch(i){case 2:n=`0b${n}`;break;case 8:n=`0o${n}`;break;case 16:n=`0x${n}`;break}const u=BigInt(n);return a==="-"?BigInt(-1)*u:u}const o=parseInt(n,i);return a==="-"?-1*o:o}function gd(n,e,i){const{value:s}=n;if(il(s)){const a=s.toString(e);return s<0?"-"+i+a.substr(1):i+a}return pn(n)}const LA={identify:il,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(n,e,i)=>bc(n,2,2,i),stringify:n=>gd(n,2,"0b")},DA={identify:il,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(n,e,i)=>bc(n,1,8,i),stringify:n=>gd(n,8,"0")},BA={identify:il,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(n,e,i)=>bc(n,0,10,i),stringify:pn},UA={identify:il,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(n,e,i)=>bc(n,2,16,i),stringify:n=>gd(n,16,"0x")};class cr extends Xt{constructor(e){super(e),this.tag=cr.tag}add(e){let i;Be(e)?i=e:e&&typeof e=="object"&&"key"in e&&"value"in e&&e.value===null?i=new bt(e.key,null):i=new bt(e,null),Qi(this.items,i.key)||this.items.push(i)}get(e,i){const s=Qi(this.items,e);return!i&&Be(s)?Re(s.key)?s.key.value:s.key:s}set(e,i){if(typeof i!="boolean")throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof i}`);const s=Qi(this.items,e);s&&!i?this.items.splice(this.items.indexOf(s),1):!s&&i&&this.items.push(new bt(e))}toJSON(e,i){return super.toJSON(e,i,Set)}toString(e,i,s){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),i,s);throw new Error("Set items must all have null values")}static from(e,i,s){const{replacer:a}=s,o=new this(e);if(i&&Symbol.iterator in Object(i))for(let u of i)typeof a=="function"&&(u=a.call(i,u,u)),o.items.push(cd(u,null,s));return o}}cr.tag="tag:yaml.org,2002:set";const md={collection:"map",identify:n=>n instanceof Set,nodeClass:cr,default:!1,tag:"tag:yaml.org,2002:set",createNode:(n,e,i)=>cr.from(n,e,i),resolve(n,e){if(br(n)){if(n.hasAllNullValues(!0))return Object.assign(new cr,n);e("Set items must all have null values")}else e("Expected a mapping for this tag");return n}};function yd(n,e){const i=n[0],s=i==="-"||i==="+"?n.substring(1):n,a=u=>e?BigInt(u):Number(u),o=s.replace(/_/g,"").split(":").reduce((u,f)=>u*a(60)+a(f),a(0));return i==="-"?a(-1)*o:o}function zv(n){let{value:e}=n,i=u=>u;if(typeof e=="bigint")i=u=>BigInt(u);else if(isNaN(e)||!isFinite(e))return pn(n);let s="";e<0&&(s="-",e*=i(-1));const a=i(60),o=[e%a];return e<60?o.unshift(0):(e=(e-o[0])/a,o.unshift(e%a),e>=60&&(e=(e-o[0])/a,o.unshift(e))),s+o.map(u=>String(u).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}const Hv={identify:n=>typeof n=="bigint"||Number.isInteger(n),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(n,e,{intAsBigInt:i})=>yd(n,i),stringify:zv},qv={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:n=>yd(n,!1),stringify:zv},vc={identify:n=>n instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve(n){const e=n.match(vc.test);if(!e)throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd");const[,i,s,a,o,u,f]=e.map(Number),d=e[7]?Number((e[7]+"00").substr(1,3)):0;let p=Date.UTC(i,s-1,a,o||0,u||0,f||0,d);const m=e[8];if(m&&m!=="Z"){let y=yd(m,!1);Math.abs(y)<30&&(y*=60),p-=6e4*y}return new Date(p)},stringify:({value:n})=>n.toISOString().replace(/((T00:00)?:00)?\.000Z$/,"")},c0=[Sr,wr,gc,mc,Bv,Uv,LA,DA,BA,UA,OA,RA,jA,hd,Yn,pd,dd,md,Hv,qv,vc],u0=new Map([["core",NA],["failsafe",[Sr,wr,gc]],["json",MA],["yaml11",c0],["yaml-1.1",c0]]),f0={binary:hd,bool:ud,float:Cv,floatExp:Nv,floatNaN:Av,floatTime:qv,int:Ov,intHex:Rv,intOct:Mv,intTime:Hv,map:Sr,merge:Yn,null:mc,omap:pd,pairs:dd,seq:wr,set:md,timestamp:vc},zA={"tag:yaml.org,2002:binary":hd,"tag:yaml.org,2002:merge":Yn,"tag:yaml.org,2002:omap":pd,"tag:yaml.org,2002:pairs":dd,"tag:yaml.org,2002:set":md,"tag:yaml.org,2002:timestamp":vc};function sh(n,e,i){const s=u0.get(e);if(s&&!n)return i&&!s.includes(Yn)?s.concat(Yn):s.slice();let a=s;if(!a)if(Array.isArray(n))a=[];else{const o=Array.from(u0.keys()).filter(u=>u!=="yaml11").map(u=>JSON.stringify(u)).join(", ");throw new Error(`Unknown schema "${e}"; use one of ${o} or define customTags array`)}if(Array.isArray(n))for(const o of n)a=a.concat(o);else typeof n=="function"&&(a=n(a.slice()));return i&&(a=a.concat(Yn)),a.reduce((o,u)=>{const f=typeof u=="string"?f0[u]:u;if(!f){const d=JSON.stringify(u),p=Object.keys(f0).map(m=>JSON.stringify(m)).join(", ");throw new Error(`Unknown custom tag ${d}; use one of ${p}`)}return o.includes(f)||o.push(f),o},[])}const HA=(n,e)=>n.key<e.key?-1:n.key>e.key?1:0;class Sc{constructor({compat:e,customTags:i,merge:s,resolveKnownTags:a,schema:o,sortMapEntries:u,toStringDefaults:f}){this.compat=Array.isArray(e)?sh(e,"compat"):e?sh(null,e):null,this.name=typeof o=="string"&&o||"core",this.knownTags=a?zA:{},this.tags=sh(i,this.name,s),this.toStringOptions=f??null,Object.defineProperty(this,Si,{value:Sr}),Object.defineProperty(this,Tn,{value:gc}),Object.defineProperty(this,yr,{value:wr}),this.sortMapEntries=typeof u=="function"?u:u===!0?HA:null}clone(){const e=Object.create(Sc.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}function qA(n,e){var d;const i=[];let s=e.directives===!0;if(e.directives!==!1&&n.directives){const p=n.directives.toString(n);p?(i.push(p),s=!0):n.directives.docStart&&(s=!0)}s&&i.push("---");const a=wv(n,e),{commentString:o}=a.options;if(n.commentBefore){i.length!==1&&i.unshift("");const p=o(n.commentBefore);i.unshift(Kn(p,""))}let u=!1,f=null;if(n.contents){if(qe(n.contents)){if(n.contents.spaceBefore&&s&&i.push(""),n.contents.commentBefore){const y=o(n.contents.commentBefore);i.push(Kn(y,""))}a.forceBlockIndent=!!n.comment,f=n.contents.comment}const p=f?void 0:()=>u=!0;let m=fr(n.contents,a,()=>f=null,p);f&&(m+=Fi(m,"",o(f))),(m[0]==="|"||m[0]===">")&&i[i.length-1]==="---"?i[i.length-1]=`--- ${m}`:i.push(m)}else i.push(fr(n.contents,a));if((d=n.directives)!=null&&d.docEnd)if(n.comment){const p=o(n.comment);p.includes(`
|
|
182
182
|
`)?(i.push("..."),i.push(Kn(p,""))):i.push(`... ${p}`)}else i.push("...");else{let p=n.comment;p&&u&&(p=p.replace(/^\n+/,"")),p&&((!u||f)&&i[i.length-1]!==""&&i.push(""),i.push(Kn(o(p),"")))}return i.join(`
|
|
183
183
|
`)+`
|
|
184
|
-
`}class xr{constructor(e,i,s){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,on,{value:_h});let a=null;typeof i=="function"||Array.isArray(i)?a=i:s===void 0&&i&&(s=i,i=void 0);const o=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},s);this.options=o;let{version:u}=o;s!=null&&s._directives?(this.directives=s._directives.atDocument(),this.directives.yaml.explicit&&(u=this.directives.yaml.version)):this.directives=new wt({version:u}),this.setSchema(u,s),this.contents=e===void 0?null:this.createNode(e,a,s)}clone(){const e=Object.create(xr.prototype,{[on]:{value:_h}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=qe(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){Zs(this.contents)&&this.contents.add(e)}addIn(e,i){Zs(this.contents)&&this.contents.addIn(e,i)}createAlias(e,i){if(!e.anchor){const s=
|
|
184
|
+
`}class xr{constructor(e,i,s){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,on,{value:_h});let a=null;typeof i=="function"||Array.isArray(i)?a=i:s===void 0&&i&&(s=i,i=void 0);const o=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},s);this.options=o;let{version:u}=o;s!=null&&s._directives?(this.directives=s._directives.atDocument(),this.directives.yaml.explicit&&(u=this.directives.yaml.version)):this.directives=new wt({version:u}),this.setSchema(u,s),this.contents=e===void 0?null:this.createNode(e,a,s)}clone(){const e=Object.create(xr.prototype,{[on]:{value:_h}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=qe(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){Zs(this.contents)&&this.contents.add(e)}addIn(e,i){Zs(this.contents)&&this.contents.addIn(e,i)}createAlias(e,i){if(!e.anchor){const s=mv(this);e.anchor=!i||s.has(i)?yv(i||"a",s):i}return new fc(e.anchor)}createNode(e,i,s){let a;if(typeof i=="function")e=i.call({"":e},"",e),a=i;else if(Array.isArray(i)){const _=C=>typeof C=="number"||C instanceof String||C instanceof Number,k=i.filter(_).map(String);k.length>0&&(i=i.concat(k)),a=i}else s===void 0&&i&&(s=i,i=void 0);const{aliasDuplicateObjects:o,anchorPrefix:u,flow:f,keepUndefined:d,onTagObj:p,tag:m}=s??{},{onAnchor:y,setAnchors:b,sourceObjects:w}=pA(this,u||"a"),E={aliasDuplicateObjects:o??!0,keepUndefined:d??!1,onAnchor:y,onTagObj:p,replacer:a,schema:this.schema,sourceObjects:w},x=Za(e,m,E);return f&&He(x)&&(x.flow=!0),b(),x}createPair(e,i,s={}){const a=this.createNode(e,null,s),o=this.createNode(i,null,s);return new bt(a,o)}delete(e){return Zs(this.contents)?this.contents.delete(e):!1}deleteIn(e){return Ha(e)?this.contents==null?!1:(this.contents=null,!0):Zs(this.contents)?this.contents.deleteIn(e):!1}get(e,i){return He(this.contents)?this.contents.get(e,i):void 0}getIn(e,i){return Ha(e)?!i&&Re(this.contents)?this.contents.value:this.contents:He(this.contents)?this.contents.getIn(e,i):void 0}has(e){return He(this.contents)?this.contents.has(e):!1}hasIn(e){return Ha(e)?this.contents!==void 0:He(this.contents)?this.contents.hasIn(e):!1}set(e,i){this.contents==null?this.contents=Wo(this.schema,[e],i):Zs(this.contents)&&this.contents.set(e,i)}setIn(e,i){Ha(e)?this.contents=i:this.contents==null?this.contents=Wo(this.schema,Array.from(e),i):Zs(this.contents)&&this.contents.setIn(e,i)}setSchema(e,i={}){typeof e=="number"&&(e=String(e));let s;switch(e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new wt({version:"1.1"}),s={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new wt({version:e}),s={resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,s=null;break;default:{const a=JSON.stringify(e);throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${a}`)}}if(i.schema instanceof Object)this.schema=i.schema;else if(s)this.schema=new Sc(Object.assign(s,i));else throw new Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:i,mapAsMap:s,maxAliasCount:a,onAnchor:o,reviver:u}={}){const f={anchors:new Map,doc:this,keep:!e,mapAsMap:s===!0,mapKeyWarned:!1,maxAliasCount:typeof a=="number"?a:100},d=ln(this.contents,i??"",f);if(typeof o=="function")for(const{count:p,res:m}of f.anchors.values())o(m,p);return typeof u=="function"?rr(u,{"":d},"",d):d}toJSON(e,i){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:i})}toString(e={}){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){const i=JSON.stringify(e.indent);throw new Error(`"indent" option must be a positive integer, not ${i}`)}return qA(this,e)}}function Zs(n){if(He(n))return!0;throw new Error("Expected a YAML collection as document contents")}class bd extends Error{constructor(e,i,s,a){super(),this.name=e,this.code=s,this.message=a,this.pos=i}}class Zi extends bd{constructor(e,i,s){super("YAMLParseError",e,i,s)}}class $v extends bd{constructor(e,i,s){super("YAMLWarning",e,i,s)}}const tc=(n,e)=>i=>{if(i.pos[0]===-1)return;i.linePos=i.pos.map(f=>e.linePos(f));const{line:s,col:a}=i.linePos[0];i.message+=` at line ${s}, column ${a}`;let o=a-1,u=n.substring(e.lineStarts[s-1],e.lineStarts[s]).replace(/[\n\r]+$/,"");if(o>=60&&u.length>80){const f=Math.min(o-39,u.length-79);u="…"+u.substring(f),o-=f-1}if(u.length>80&&(u=u.substring(0,79)+"…"),s>1&&/^ *$/.test(u.substring(0,o))){let f=n.substring(e.lineStarts[s-2],e.lineStarts[s-1]);f.length>80&&(f=f.substring(0,79)+`…
|
|
185
185
|
`),u=f+u}if(/[^ ]/.test(u)){let f=1;const d=i.linePos[1];d&&d.line===s&&d.col>a&&(f=Math.max(1,Math.min(d.col-a,80-o)));const p=" ".repeat(o)+"^".repeat(f);i.message+=`:
|
|
186
186
|
|
|
187
187
|
${u}
|
|
188
188
|
${p}
|
|
189
189
|
`}};function hr(n,{flow:e,indicator:i,next:s,offset:a,onError:o,parentIndent:u,startOnNewline:f}){let d=!1,p=f,m=f,y="",b="",w=!1,E=!1,x=null,_=null,k=null,C=null,V=null,I=null,B=null;for(const $ of n)switch(E&&($.type!=="space"&&$.type!=="newline"&&$.type!=="comma"&&o($.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),E=!1),x&&(p&&$.type!=="comment"&&$.type!=="newline"&&o(x,"TAB_AS_INDENT","Tabs are not allowed as indentation"),x=null),$.type){case"space":!e&&(i!=="doc-start"||(s==null?void 0:s.type)!=="flow-collection")&&$.source.includes(" ")&&(x=$),m=!0;break;case"comment":{m||o($,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const R=$.source.substring(1)||" ";y?y+=b+R:y=R,b="",p=!1;break}case"newline":p?y?y+=$.source:d=!0:b+=$.source,p=!0,w=!0,(_||k)&&(C=$),m=!0;break;case"anchor":_&&o($,"MULTIPLE_ANCHORS","A node can have at most one anchor"),$.source.endsWith(":")&&o($.offset+$.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0),_=$,B===null&&(B=$.offset),p=!1,m=!1,E=!0;break;case"tag":{k&&o($,"MULTIPLE_TAGS","A node can have at most one tag"),k=$,B===null&&(B=$.offset),p=!1,m=!1,E=!0;break}case i:(_||k)&&o($,"BAD_PROP_ORDER",`Anchors and tags must be after the ${$.source} indicator`),I&&o($,"UNEXPECTED_TOKEN",`Unexpected ${$.source} in ${e??"collection"}`),I=$,p=i==="seq-item-ind"||i==="explicit-key-ind",m=!1;break;case"comma":if(e){V&&o($,"UNEXPECTED_TOKEN",`Unexpected , in ${e}`),V=$,p=!1,m=!1;break}default:o($,"UNEXPECTED_TOKEN",`Unexpected ${$.type} token`),p=!1,m=!1}const G=n[n.length-1],J=G?G.offset+G.source.length:a;return E&&s&&s.type!=="space"&&s.type!=="newline"&&s.type!=="comma"&&(s.type!=="scalar"||s.source!=="")&&o(s.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),x&&(p&&x.indent<=u||(s==null?void 0:s.type)==="block-map"||(s==null?void 0:s.type)==="block-seq")&&o(x,"TAB_AS_INDENT","Tabs are not allowed as indentation"),{comma:V,found:I,spaceBefore:d,comment:y,hasNewline:w,anchor:_,tag:k,newlineAfterProp:C,end:J,start:B??J}}function Ja(n){if(!n)return null;switch(n.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(n.source.includes(`
|
|
190
|
-
`))return!0;if(n.end){for(const e of n.end)if(e.type==="newline")return!0}return!1;case"flow-collection":for(const e of n.items){for(const i of e.start)if(i.type==="newline")return!0;if(e.sep){for(const i of e.sep)if(i.type==="newline")return!0}if(Ja(e.key)||Ja(e.value))return!0}return!1;default:return!0}}function Nh(n,e,i){if((e==null?void 0:e.type)==="flow-collection"){const s=e.end[0];s.indent===n&&(s.source==="]"||s.source==="}")&&Ja(e)&&i(s,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}function
|
|
191
|
-
`+_.comment:f.comment=_.comment);continue}(_.newlineAfterProp||Ja(w))&&a(w??b[b.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else((m=_.found)==null?void 0:m.indent)!==s.indent&&a(d,"BAD_INDENT",h0);i.atKey=!0;const C=_.end,V=w?n(i,w,_,a):e(i,C,b,null,_,a);i.schema.compat&&Nh(s.indent,w,a),i.atKey=!1
|
|
192
|
-
`+I.comment:V.comment=I.comment);const B=new bt(V);i.options.keepSourceTokens&&(B.srcToken=y),f.items.push(B)}}return p&&p<d&&a(p,"IMPOSSIBLE","Map comment with trailing content"),f.range=[s.offset,d,p??d],f}function
|
|
190
|
+
`))return!0;if(n.end){for(const e of n.end)if(e.type==="newline")return!0}return!1;case"flow-collection":for(const e of n.items){for(const i of e.start)if(i.type==="newline")return!0;if(e.sep){for(const i of e.sep)if(i.type==="newline")return!0}if(Ja(e.key)||Ja(e.value))return!0}return!1;default:return!0}}function Nh(n,e,i){if((e==null?void 0:e.type)==="flow-collection"){const s=e.end[0];s.indent===n&&(s.source==="]"||s.source==="}")&&Ja(e)&&i(s,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}function Iv(n,e,i){const{uniqueKeys:s}=n.options;if(s===!1)return!1;const a=typeof s=="function"?s:(o,u)=>o===u||Re(o)&&Re(u)&&o.value===u.value;return e.some(o=>a(o.key,i))}const h0="All mapping items must start at the same column";function $A({composeNode:n,composeEmptyNode:e},i,s,a,o){var m;const u=(o==null?void 0:o.nodeClass)??Xt,f=new u(i.schema);i.atRoot&&(i.atRoot=!1);let d=s.offset,p=null;for(const y of s.items){const{start:b,key:w,sep:E,value:x}=y,_=hr(b,{indicator:"explicit-key-ind",next:w??(E==null?void 0:E[0]),offset:d,onError:a,parentIndent:s.indent,startOnNewline:!0}),k=!_.found;if(k){if(w&&(w.type==="block-seq"?a(d,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key"):"indent"in w&&w.indent!==s.indent&&a(d,"BAD_INDENT",h0)),!_.anchor&&!_.tag&&!E){p=_.end,_.comment&&(f.comment?f.comment+=`
|
|
191
|
+
`+_.comment:f.comment=_.comment);continue}(_.newlineAfterProp||Ja(w))&&a(w??b[b.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else((m=_.found)==null?void 0:m.indent)!==s.indent&&a(d,"BAD_INDENT",h0);i.atKey=!0;const C=_.end,V=w?n(i,w,_,a):e(i,C,b,null,_,a);i.schema.compat&&Nh(s.indent,w,a),i.atKey=!1,Iv(i,f.items,V)&&a(C,"DUPLICATE_KEY","Map keys must be unique");const I=hr(E??[],{indicator:"map-value-ind",next:x,offset:V.range[2],onError:a,parentIndent:s.indent,startOnNewline:!w||w.type==="block-scalar"});if(d=I.end,I.found){k&&((x==null?void 0:x.type)==="block-map"&&!I.hasNewline&&a(d,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings"),i.options.strict&&_.start<I.found.offset-1024&&a(V.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));const B=x?n(i,x,I,a):e(i,d,E,null,I,a);i.schema.compat&&Nh(s.indent,x,a),d=B.range[2];const G=new bt(V,B);i.options.keepSourceTokens&&(G.srcToken=y),f.items.push(G)}else{k&&a(V.range,"MISSING_CHAR","Implicit map keys need to be followed by map values"),I.comment&&(V.comment?V.comment+=`
|
|
192
|
+
`+I.comment:V.comment=I.comment);const B=new bt(V);i.options.keepSourceTokens&&(B.srcToken=y),f.items.push(B)}}return p&&p<d&&a(p,"IMPOSSIBLE","Map comment with trailing content"),f.range=[s.offset,d,p??d],f}function IA({composeNode:n,composeEmptyNode:e},i,s,a,o){const u=(o==null?void 0:o.nodeClass)??xi,f=new u(i.schema);i.atRoot&&(i.atRoot=!1),i.atKey&&(i.atKey=!1);let d=s.offset,p=null;for(const{start:m,value:y}of s.items){const b=hr(m,{indicator:"seq-item-ind",next:y,offset:d,onError:a,parentIndent:s.indent,startOnNewline:!0});if(!b.found)if(b.anchor||b.tag||y)y&&y.type==="block-seq"?a(b.end,"BAD_INDENT","All sequence items must start at the same column"):a(d,"MISSING_CHAR","Sequence item without - indicator");else{p=b.end,b.comment&&(f.comment=b.comment);continue}const w=y?n(i,y,b,a):e(i,b.end,m,null,b,a);i.schema.compat&&Nh(s.indent,y,a),d=w.range[2],f.items.push(w)}return f.range=[s.offset,d,p??d],f}function sl(n,e,i,s){let a="";if(n){let o=!1,u="";for(const f of n){const{source:d,type:p}=f;switch(p){case"space":o=!0;break;case"comment":{i&&!o&&s(f,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const m=d.substring(1)||" ";a?a+=u+m:a=m,u="";break}case"newline":a&&(u+=d),o=!0;break;default:s(f,"UNEXPECTED_TOKEN",`Unexpected ${p} at node end`)}e+=d.length}}return{comment:a,offset:e}}const rh="Block collections are not allowed within flow collections",ah=n=>n&&(n.type==="block-map"||n.type==="block-seq");function VA({composeNode:n,composeEmptyNode:e},i,s,a,o){const u=s.start.source==="{",f=u?"flow map":"flow sequence",d=(o==null?void 0:o.nodeClass)??(u?Xt:xi),p=new d(i.schema);p.flow=!0;const m=i.atRoot;m&&(i.atRoot=!1),i.atKey&&(i.atKey=!1);let y=s.offset+s.start.source.length;for(let _=0;_<s.items.length;++_){const k=s.items[_],{start:C,key:V,sep:I,value:B}=k,G=hr(C,{flow:f,indicator:"explicit-key-ind",next:V??(I==null?void 0:I[0]),offset:y,onError:a,parentIndent:s.indent,startOnNewline:!1});if(!G.found){if(!G.anchor&&!G.tag&&!I&&!B){_===0&&G.comma?a(G.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${f}`):_<s.items.length-1&&a(G.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${f}`),G.comment&&(p.comment?p.comment+=`
|
|
193
193
|
`+G.comment:p.comment=G.comment),y=G.end;continue}!u&&i.options.strict&&Ja(V)&&a(V,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(_===0)G.comma&&a(G.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${f}`);else if(G.comma||a(G.start,"MISSING_CHAR",`Missing , between ${f} items`),G.comment){let J="";e:for(const $ of C)switch($.type){case"comma":case"space":break;case"comment":J=$.source.substring(1);break e;default:break e}if(J){let $=p.items[p.items.length-1];Be($)&&($=$.value??$.key),$.comment?$.comment+=`
|
|
194
194
|
`+J:$.comment=J,G.comment=G.comment.substring(J.length+1)}}if(!u&&!I&&!G.found){const J=B?n(i,B,G,a):e(i,G.end,I,null,G,a);p.items.push(J),y=J.range[2],ah(B)&&a(J.range,"BLOCK_IN_FLOW",rh)}else{i.atKey=!0;const J=G.end,$=V?n(i,V,G,a):e(i,J,C,null,G,a);ah(V)&&a($.range,"BLOCK_IN_FLOW",rh),i.atKey=!1;const R=hr(I??[],{flow:f,indicator:"map-value-ind",next:B,offset:$.range[2],onError:a,parentIndent:s.indent,startOnNewline:!1});if(R.found){if(!u&&!G.found&&i.options.strict){if(I)for(const j of I){if(j===R.found)break;if(j.type==="newline"){a(j,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}G.start<R.found.offset-1024&&a(R.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else B&&("source"in B&&B.source&&B.source[0]===":"?a(B,"MISSING_CHAR",`Missing space after : in ${f}`):a(R.start,"MISSING_CHAR",`Missing , or : between ${f} items`));const ee=B?n(i,B,R,a):R.found?e(i,R.end,I,null,R,a):null;ee?ah(B)&&a(ee.range,"BLOCK_IN_FLOW",rh):R.comment&&($.comment?$.comment+=`
|
|
195
|
-
`+R.comment:$.comment=R.comment);const re=new bt($,ee);if(i.options.keepSourceTokens&&(re.srcToken=k),u){const j=p
|
|
196
|
-
`+_.comment:p.comment=_.comment),p.range=[s.offset,x,_.offset]}else p.range=[s.offset,x,x];return p}function lh(n,e,i,s,a,o){const u=i.type==="block-map"
|
|
195
|
+
`+R.comment:$.comment=R.comment);const re=new bt($,ee);if(i.options.keepSourceTokens&&(re.srcToken=k),u){const j=p;Iv(i,j.items,$)&&a(J,"DUPLICATE_KEY","Map keys must be unique"),j.items.push(re)}else{const j=new Xt(i.schema);j.flow=!0,j.items.push(re);const F=(ee??$).range;j.range=[$.range[0],F[1],F[2]],p.items.push(j)}y=ee?ee.range[2]:R.end}}const b=u?"}":"]",[w,...E]=s.end;let x=y;if(w&&w.source===b)x=w.offset+w.source.length;else{const _=f[0].toUpperCase()+f.substring(1),k=m?`${_} must end with a ${b}`:`${_} in block collection must be sufficiently indented and end with a ${b}`;a(y,m?"MISSING_CHAR":"BAD_INDENT",k),w&&w.source.length!==1&&E.unshift(w)}if(E.length>0){const _=sl(E,x,i.options.strict,a);_.comment&&(p.comment?p.comment+=`
|
|
196
|
+
`+_.comment:p.comment=_.comment),p.range=[s.offset,x,_.offset]}else p.range=[s.offset,x,x];return p}function lh(n,e,i,s,a,o){const u=i.type==="block-map"?$A(n,e,i,s,o):i.type==="block-seq"?IA(n,e,i,s,o):VA(n,e,i,s,o),f=u.constructor;return a==="!"||a===f.tagName?(u.tag=f.tagName,u):(a&&(u.tag=a),u)}function GA(n,e,i,s,a){var b;const o=s.tag,u=o?e.directives.tagName(o.source,w=>a(o,"TAG_RESOLVE_FAILED",w)):null;if(i.type==="block-seq"){const{anchor:w,newlineAfterProp:E}=s,x=w&&o?w.offset>o.offset?w:o:w??o;x&&(!E||E.offset<x.offset)&&a(x,"MISSING_CHAR","Missing newline after block sequence props")}const f=i.type==="block-map"?"map":i.type==="block-seq"?"seq":i.start.source==="{"?"map":"seq";if(!o||!u||u==="!"||u===Xt.tagName&&f==="map"||u===xi.tagName&&f==="seq")return lh(n,e,i,a,u);let d=e.schema.tags.find(w=>w.tag===u&&w.collection===f);if(!d){const w=e.schema.knownTags[u];if(w&&w.collection===f)e.schema.tags.push(Object.assign({},w,{default:!1})),d=w;else return w!=null&&w.collection?a(o,"BAD_COLLECTION_TYPE",`${w.tag} used for ${f} collection, but expects ${w.collection}`,!0):a(o,"TAG_RESOLVE_FAILED",`Unresolved tag: ${u}`,!0),lh(n,e,i,a,u)}const p=lh(n,e,i,a,u,d),m=((b=d.resolve)==null?void 0:b.call(d,p,w=>a(o,"TAG_RESOLVE_FAILED",w),e.options))??p,y=qe(m)?m:new fe(m);return y.range=p.range,y.tag=u,d!=null&&d.format&&(y.format=d.format),y}function Vv(n,e,i){const s=e.offset,a=KA(e,n.options.strict,i);if(!a)return{value:"",type:null,comment:"",range:[s,s,s]};const o=a.mode===">"?fe.BLOCK_FOLDED:fe.BLOCK_LITERAL,u=e.source?YA(e.source):[];let f=u.length;for(let x=u.length-1;x>=0;--x){const _=u[x][1];if(_===""||_==="\r")f=x;else break}if(f===0){const x=a.chomp==="+"&&u.length>0?`
|
|
197
197
|
`.repeat(Math.max(1,u.length-1)):"";let _=s+a.length;return e.source&&(_+=e.source.length),{value:x,type:o,comment:a.comment,range:[s,_,_]}}let d=e.indent+a.indent,p=e.offset+a.length,m=0;for(let x=0;x<f;++x){const[_,k]=u[x];if(k===""||k==="\r")a.indent===0&&_.length>d&&(d=_.length);else{_.length<d&&i(p+_.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator"),a.indent===0&&(d=_.length),m=x,d===0&&!n.atRoot&&i(p,"BAD_INDENT","Block scalar values in collections must be indented");break}p+=_.length+k.length+1}for(let x=u.length-1;x>=f;--x)u[x][0].length>d&&(f=x+1);let y="",b="",w=!1;for(let x=0;x<m;++x)y+=u[x][0].slice(d)+`
|
|
198
198
|
`;for(let x=m;x<f;++x){let[_,k]=u[x];p+=_.length+k.length+1;const C=k[k.length-1]==="\r";if(C&&(k=k.slice(0,-1)),k&&_.length<d){const I=`Block scalar lines must not be less indented than their ${a.indent?"explicit indentation indicator":"first line"}`;i(p-k.length-(C?2:1),"BAD_INDENT",I),_=""}o===fe.BLOCK_LITERAL?(y+=b+_.slice(d)+k,b=`
|
|
199
199
|
`):_.length>d||k[0]===" "?(b===" "?b=`
|
|
@@ -208,41 +208,41 @@ ${p}
|
|
|
208
208
|
`+u[x][0].slice(d);y[y.length-1]!==`
|
|
209
209
|
`&&(y+=`
|
|
210
210
|
`);break;default:y+=`
|
|
211
|
-
`}const E=s+a.length+e.source.length;return{value:y,type:o,comment:a.comment,range:[s,E,E]}}function
|
|
211
|
+
`}const E=s+a.length+e.source.length;return{value:y,type:o,comment:a.comment,range:[s,E,E]}}function KA({offset:n,props:e},i,s){if(e[0].type!=="block-scalar-header")return s(e[0],"IMPOSSIBLE","Block scalar header not found"),null;const{source:a}=e[0],o=a[0];let u=0,f="",d=-1;for(let b=1;b<a.length;++b){const w=a[b];if(!f&&(w==="-"||w==="+"))f=w;else{const E=Number(w);!u&&E?u=E:d===-1&&(d=n+b)}}d!==-1&&s(d,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${a}`);let p=!1,m="",y=a.length;for(let b=1;b<e.length;++b){const w=e[b];switch(w.type){case"space":p=!0;case"newline":y+=w.source.length;break;case"comment":i&&!p&&s(w,"MISSING_CHAR","Comments must be separated from other tokens by white space characters"),y+=w.source.length,m=w.source.substring(1);break;case"error":s(w,"UNEXPECTED_TOKEN",w.message),y+=w.source.length;break;default:{const E=`Unexpected token in block scalar header: ${w.type}`;s(w,"UNEXPECTED_TOKEN",E);const x=w.source;x&&typeof x=="string"&&(y+=x.length)}}}return{mode:o,indent:u,chomp:f,comment:m,length:y}}function YA(n){const e=n.split(/\n( *)/),i=e[0],s=i.match(/^( *)/),o=[s!=null&&s[1]?[s[1],i.slice(s[1].length)]:["",i]];for(let u=1;u<e.length;u+=2)o.push([e[u],e[u+1]]);return o}function Gv(n,e,i){const{offset:s,type:a,source:o,end:u}=n;let f,d;const p=(b,w,E)=>i(s+b,w,E);switch(a){case"scalar":f=fe.PLAIN,d=XA(o,p);break;case"single-quoted-scalar":f=fe.QUOTE_SINGLE,d=PA(o,p);break;case"double-quoted-scalar":f=fe.QUOTE_DOUBLE,d=FA(o,p);break;default:return i(n,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${a}`),{value:"",type:null,comment:"",range:[s,s+o.length,s+o.length]}}const m=s+o.length,y=sl(u,m,e,i);return{value:d,type:f,comment:y.comment,range:[s,m,y.offset]}}function XA(n,e){let i="";switch(n[0]){case" ":i="a tab character";break;case",":i="flow indicator character ,";break;case"%":i="directive indicator character %";break;case"|":case">":{i=`block scalar indicator ${n[0]}`;break}case"@":case"`":{i=`reserved character ${n[0]}`;break}}return i&&e(0,"BAD_SCALAR_START",`Plain value cannot start with ${i}`),Kv(n)}function PA(n,e){return(n[n.length-1]!=="'"||n.length===1)&&e(n.length,"MISSING_CHAR","Missing closing 'quote"),Kv(n.slice(1,-1)).replace(/''/g,"'")}function Kv(n){let e,i;try{e=new RegExp(`(.*?)(?<![ ])[ ]*\r?
|
|
212
212
|
`,"sy"),i=new RegExp(`[ ]*(.*?)(?:(?<![ ])[ ]*)?\r?
|
|
213
213
|
`,"sy")}catch{e=/(.*?)[ \t]*\r?\n/sy,i=/[ \t]*(.*?)[ \t]*\r?\n/sy}let s=e.exec(n);if(!s)return n;let a=s[1],o=" ",u=e.lastIndex;for(i.lastIndex=u;s=i.exec(n);)s[1]===""?o===`
|
|
214
214
|
`?a+=o:o=`
|
|
215
|
-
`:(a+=o+s[1],o=" "),u=i.lastIndex;const f=/[ \t]*(.*)/sy;return f.lastIndex=u,s=f.exec(n),a+o+((s==null?void 0:s[1])??"")}function
|
|
215
|
+
`:(a+=o+s[1],o=" "),u=i.lastIndex;const f=/[ \t]*(.*)/sy;return f.lastIndex=u,s=f.exec(n),a+o+((s==null?void 0:s[1])??"")}function FA(n,e){let i="";for(let s=1;s<n.length-1;++s){const a=n[s];if(!(a==="\r"&&n[s+1]===`
|
|
216
216
|
`))if(a===`
|
|
217
|
-
`){const{fold:o,offset:u}=
|
|
217
|
+
`){const{fold:o,offset:u}=QA(n,s);i+=o,s=u}else if(a==="\\"){let o=n[++s];const u=ZA[o];if(u)i+=u;else if(o===`
|
|
218
218
|
`)for(o=n[s+1];o===" "||o===" ";)o=n[++s+1];else if(o==="\r"&&n[s+1]===`
|
|
219
|
-
`)for(o=n[++s+1];o===" "||o===" ";)o=n[++s+1];else if(o==="x"||o==="u"||o==="U"){const f={x:2,u:4,U:8}[o];i+=
|
|
219
|
+
`)for(o=n[++s+1];o===" "||o===" ";)o=n[++s+1];else if(o==="x"||o==="u"||o==="U"){const f={x:2,u:4,U:8}[o];i+=JA(n,s+1,f,e),s+=f}else{const f=n.substr(s-1,2);e(s-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${f}`),i+=f}}else if(a===" "||a===" "){const o=s;let u=n[s+1];for(;u===" "||u===" ";)u=n[++s+1];u!==`
|
|
220
220
|
`&&!(u==="\r"&&n[s+2]===`
|
|
221
|
-
`)&&(i+=s>o?n.slice(o,s+1):a)}else i+=a}return(n[n.length-1]!=='"'||n.length===1)&&e(n.length,"MISSING_CHAR",'Missing closing "quote'),i}function
|
|
221
|
+
`)&&(i+=s>o?n.slice(o,s+1):a)}else i+=a}return(n[n.length-1]!=='"'||n.length===1)&&e(n.length,"MISSING_CHAR",'Missing closing "quote'),i}function QA(n,e){let i="",s=n[e+1];for(;(s===" "||s===" "||s===`
|
|
222
222
|
`||s==="\r")&&!(s==="\r"&&n[e+2]!==`
|
|
223
223
|
`);)s===`
|
|
224
224
|
`&&(i+=`
|
|
225
|
-
`),e+=1,s=n[e+1];return i||(i=" "),{fold:i,offset:e}}const
|
|
226
|
-
`,r:"\r",t:" ",v:"\v",N:"
",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\"," ":" "};function
|
|
225
|
+
`),e+=1,s=n[e+1];return i||(i=" "),{fold:i,offset:e}}const ZA={0:"\0",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:`
|
|
226
|
+
`,r:"\r",t:" ",v:"\v",N:"
",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\"," ":" "};function JA(n,e,i,s){const a=n.substr(e,i),u=a.length===i&&/^[0-9a-fA-F]+$/.test(a)?parseInt(a,16):NaN;if(isNaN(u)){const f=n.substr(e-2,i+2);return s(e-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${f}`),f}return String.fromCodePoint(u)}function Yv(n,e,i,s){const{value:a,type:o,comment:u,range:f}=e.type==="block-scalar"?Vv(n,e,s):Gv(e,n.options.strict,s),d=i?n.directives.tagName(i.source,y=>s(i,"TAG_RESOLVE_FAILED",y)):null;let p;n.options.stringKeys&&n.atKey?p=n.schema[Tn]:d?p=WA(n.schema,a,d,i,s):e.type==="scalar"?p=eN(n,a,e,s):p=n.schema[Tn];let m;try{const y=p.resolve(a,b=>s(i??e,"TAG_RESOLVE_FAILED",b),n.options);m=Re(y)?y:new fe(y)}catch(y){const b=y instanceof Error?y.message:String(y);s(i??e,"TAG_RESOLVE_FAILED",b),m=new fe(a)}return m.range=f,m.source=a,o&&(m.type=o),d&&(m.tag=d),p.format&&(m.format=p.format),u&&(m.comment=u),m}function WA(n,e,i,s,a){var f;if(i==="!")return n[Tn];const o=[];for(const d of n.tags)if(!d.collection&&d.tag===i)if(d.default&&d.test)o.push(d);else return d;for(const d of o)if((f=d.test)!=null&&f.test(e))return d;const u=n.knownTags[i];return u&&!u.collection?(n.tags.push(Object.assign({},u,{default:!1,test:void 0})),u):(a(s,"TAG_RESOLVE_FAILED",`Unresolved tag: ${i}`,i!=="tag:yaml.org,2002:str"),n[Tn])}function eN({atKey:n,directives:e,schema:i},s,a,o){const u=i.tags.find(f=>{var d;return(f.default===!0||n&&f.default==="key")&&((d=f.test)==null?void 0:d.test(s))})||i[Tn];if(i.compat){const f=i.compat.find(d=>{var p;return d.default&&((p=d.test)==null?void 0:p.test(s))})??i[Tn];if(u.tag!==f.tag){const d=e.tagString(u.tag),p=e.tagString(f.tag),m=`Value may be parsed as either ${d} or ${p}`;o(a,"TAG_RESOLVE_FAILED",m,!0)}}return u}function tN(n,e,i){if(e){i===null&&(i=e.length);for(let s=i-1;s>=0;--s){let a=e[s];switch(a.type){case"space":case"comment":case"newline":n-=a.source.length;continue}for(a=e[++s];(a==null?void 0:a.type)==="space";)n+=a.source.length,a=e[++s];break}}return n}const nN={composeNode:Xv,composeEmptyNode:vd};function Xv(n,e,i,s){const a=n.atKey,{spaceBefore:o,comment:u,anchor:f,tag:d}=i;let p,m=!0;switch(e.type){case"alias":p=iN(n,e,s),(f||d)&&s(e,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":p=Yv(n,e,d,s),f&&(p.anchor=f.source.substring(1));break;case"block-map":case"block-seq":case"flow-collection":p=GA(nN,n,e,i,s),f&&(p.anchor=f.source.substring(1));break;default:{const y=e.type==="error"?e.message:`Unsupported token (type: ${e.type})`;s(e,"UNEXPECTED_TOKEN",y),p=vd(n,e.offset,void 0,null,i,s),m=!1}}return f&&p.anchor===""&&s(f,"BAD_ALIAS","Anchor cannot be an empty string"),a&&n.options.stringKeys&&(!Re(p)||typeof p.value!="string"||p.tag&&p.tag!=="tag:yaml.org,2002:str")&&s(d??e,"NON_STRING_KEY","With stringKeys, all keys must be strings"),o&&(p.spaceBefore=!0),u&&(e.type==="scalar"&&e.source===""?p.comment=u:p.commentBefore=u),n.options.keepSourceTokens&&m&&(p.srcToken=e),p}function vd(n,e,i,s,{spaceBefore:a,comment:o,anchor:u,tag:f,end:d},p){const m={type:"scalar",offset:tN(e,i,s),indent:-1,source:""},y=Yv(n,m,f,p);return u&&(y.anchor=u.source.substring(1),y.anchor===""&&p(u,"BAD_ALIAS","Anchor cannot be an empty string")),a&&(y.spaceBefore=!0),o&&(y.comment=o,y.range[2]=d),y}function iN({options:n},{offset:e,source:i,end:s},a){const o=new fc(i.substring(1));o.source===""&&a(e,"BAD_ALIAS","Alias cannot be an empty string"),o.source.endsWith(":")&&a(e+i.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);const u=e+i.length,f=sl(s,u,n.strict,a);return o.range=[e,u,f.offset],f.comment&&(o.comment=f.comment),o}function sN(n,e,{offset:i,start:s,value:a,end:o},u){const f=Object.assign({_directives:e},n),d=new xr(void 0,f),p={atKey:!1,atRoot:!0,directives:d.directives,options:d.options,schema:d.schema},m=hr(s,{indicator:"doc-start",next:a??(o==null?void 0:o[0]),offset:i,onError:u,parentIndent:0,startOnNewline:!0});m.found&&(d.directives.docStart=!0,a&&(a.type==="block-map"||a.type==="block-seq")&&!m.hasNewline&&u(m.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")),d.contents=a?Xv(p,a,m,u):vd(p,m.end,s,null,m,u);const y=d.contents.range[2],b=sl(o,y,!1,u);return b.comment&&(d.comment=b.comment),d.range=[i,y,b.offset],d}function Oa(n){if(typeof n=="number")return[n,n+1];if(Array.isArray(n))return n.length===2?n:[n[0],n[1]];const{offset:e,source:i}=n;return[e,e+(typeof i=="string"?i.length:1)]}function d0(n){var a;let e="",i=!1,s=!1;for(let o=0;o<n.length;++o){const u=n[o];switch(u[0]){case"#":e+=(e===""?"":s?`
|
|
227
227
|
|
|
228
228
|
`:`
|
|
229
|
-
`)+(u.substring(1)||" "),i=!0,s=!1;break;case"%":((a=n[o+1])==null?void 0:a[0])!=="#"&&(o+=1),i=!1;break;default:i||(s=!0),i=!1}}return{comment:e,afterEmptyLine:s}}class Sd{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(i,s,a,o)=>{const u=Oa(i);o?this.warnings.push(new
|
|
229
|
+
`)+(u.substring(1)||" "),i=!0,s=!1;break;case"%":((a=n[o+1])==null?void 0:a[0])!=="#"&&(o+=1),i=!1;break;default:i||(s=!0),i=!1}}return{comment:e,afterEmptyLine:s}}class Sd{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(i,s,a,o)=>{const u=Oa(i);o?this.warnings.push(new $v(u,s,a)):this.errors.push(new Zi(u,s,a))},this.directives=new wt({version:e.version||"1.2"}),this.options=e}decorate(e,i){const{comment:s,afterEmptyLine:a}=d0(this.prelude);if(s){const o=e.contents;if(i)e.comment=e.comment?`${e.comment}
|
|
230
230
|
${s}`:s;else if(a||e.directives.docStart||!o)e.commentBefore=s;else if(He(o)&&!o.flow&&o.items.length>0){let u=o.items[0];Be(u)&&(u=u.key);const f=u.commentBefore;u.commentBefore=f?`${s}
|
|
231
231
|
${f}`:s}else{const u=o.commentBefore;o.commentBefore=u?`${s}
|
|
232
|
-
${u}`:s}}i?(Array.prototype.push.apply(e.errors,this.errors),Array.prototype.push.apply(e.warnings,this.warnings)):(e.errors=this.errors,e.warnings=this.warnings),this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:d0(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,i=!1,s=-1){for(const a of e)yield*this.next(a);yield*this.end(i,s)}*next(e){switch(e.type){case"directive":this.directives.add(e.source,(i,s,a)=>{const o=Oa(e);o[0]+=i,this.onError(o,"BAD_DIRECTIVE",s,a)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{const i=
|
|
233
|
-
${i.comment}`:i.comment}this.doc.range[2]=i.offset;break}default:this.errors.push(new Zi(Oa(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,i=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){const s=Object.assign({_directives:this.directives},this.options),a=new xr(void 0,s);this.atDirectives&&this.onError(i,"MISSING_CHAR","Missing directives-end indicator line"),a.range=[0,i,i],this.decorate(a,!1),yield a}}}function
|
|
232
|
+
${u}`:s}}i?(Array.prototype.push.apply(e.errors,this.errors),Array.prototype.push.apply(e.warnings,this.warnings)):(e.errors=this.errors,e.warnings=this.warnings),this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:d0(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,i=!1,s=-1){for(const a of e)yield*this.next(a);yield*this.end(i,s)}*next(e){switch(e.type){case"directive":this.directives.add(e.source,(i,s,a)=>{const o=Oa(e);o[0]+=i,this.onError(o,"BAD_DIRECTIVE",s,a)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{const i=sN(this.options,this.directives,e,this.onError);this.atDirectives&&!i.directives.docStart&&this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line"),this.decorate(i,!1),this.doc&&(yield this.doc),this.doc=i,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{const i=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,s=new Zi(Oa(e),"UNEXPECTED_TOKEN",i);this.atDirectives||!this.doc?this.errors.push(s):this.doc.errors.push(s);break}case"doc-end":{if(!this.doc){const s="Unexpected doc-end without preceding document";this.errors.push(new Zi(Oa(e),"UNEXPECTED_TOKEN",s));break}this.doc.directives.docEnd=!0;const i=sl(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),i.comment){const s=this.doc.comment;this.doc.comment=s?`${s}
|
|
233
|
+
${i.comment}`:i.comment}this.doc.range[2]=i.offset;break}default:this.errors.push(new Zi(Oa(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,i=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){const s=Object.assign({_directives:this.directives},this.options),a=new xr(void 0,s);this.atDirectives&&this.onError(i,"MISSING_CHAR","Missing directives-end indicator line"),a.range=[0,i,i],this.decorate(a,!1),yield a}}}function rN(n,e=!0,i){if(n){const s=(a,o,u)=>{const f=typeof a=="number"?a:Array.isArray(a)?a[0]:a.offset;if(i)i(f,o,u);else throw new Zi([f,f+1],o,u)};switch(n.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return Gv(n,e,s);case"block-scalar":return Vv({options:{strict:e}},n,s)}}return null}function aN(n,e){const{implicitKey:i=!1,indent:s,inFlow:a=!1,offset:o=-1,type:u="PLAIN"}=e,f=nl({type:u,value:n},{implicitKey:i,indent:s>0?" ".repeat(s):"",inFlow:a,options:{blockQuote:!0,lineWidth:-1}}),d=e.end??[{type:"newline",offset:-1,indent:s,source:`
|
|
234
234
|
`}];switch(f[0]){case"|":case">":{const p=f.indexOf(`
|
|
235
235
|
`),m=f.substring(0,p),y=f.substring(p+1)+`
|
|
236
|
-
`,b=[{type:"block-scalar-header",offset:o,indent:s,source:m}];return
|
|
237
|
-
`}),{type:"block-scalar",offset:o,indent:s,props:b,source:y}}case'"':return{type:"double-quoted-scalar",offset:o,indent:s,source:f,end:d};case"'":return{type:"single-quoted-scalar",offset:o,indent:s,source:f,end:d};default:return{type:"scalar",offset:o,indent:s,source:f,end:d}}}function
|
|
236
|
+
`,b=[{type:"block-scalar-header",offset:o,indent:s,source:m}];return Pv(b,d)||b.push({type:"newline",offset:-1,indent:s,source:`
|
|
237
|
+
`}),{type:"block-scalar",offset:o,indent:s,props:b,source:y}}case'"':return{type:"double-quoted-scalar",offset:o,indent:s,source:f,end:d};case"'":return{type:"single-quoted-scalar",offset:o,indent:s,source:f,end:d};default:return{type:"scalar",offset:o,indent:s,source:f,end:d}}}function lN(n,e,i={}){let{afterKey:s=!1,implicitKey:a=!1,inFlow:o=!1,type:u}=i,f="indent"in n?n.indent:null;if(s&&typeof f=="number"&&(f+=2),!u)switch(n.type){case"single-quoted-scalar":u="QUOTE_SINGLE";break;case"double-quoted-scalar":u="QUOTE_DOUBLE";break;case"block-scalar":{const p=n.props[0];if(p.type!=="block-scalar-header")throw new Error("Invalid block scalar header");u=p.source[0]===">"?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:u="PLAIN"}const d=nl({type:u,value:e},{implicitKey:a||f===null,indent:f!==null&&f>0?" ".repeat(f):"",inFlow:o,options:{blockQuote:!0,lineWidth:-1}});switch(d[0]){case"|":case">":oN(n,d);break;case'"':oh(n,d,"double-quoted-scalar");break;case"'":oh(n,d,"single-quoted-scalar");break;default:oh(n,d,"scalar")}}function oN(n,e){const i=e.indexOf(`
|
|
238
238
|
`),s=e.substring(0,i),a=e.substring(i+1)+`
|
|
239
|
-
`;if(n.type==="block-scalar"){const o=n.props[0];if(o.type!=="block-scalar-header")throw new Error("Invalid block scalar header");o.source=s,n.source=a}else{const{offset:o}=n,u="indent"in n?n.indent:-1,f=[{type:"block-scalar-header",offset:o,indent:u,source:s}];
|
|
240
|
-
`});for(const d of Object.keys(n))d!=="type"&&d!=="offset"&&delete n[d];Object.assign(n,{type:"block-scalar",indent:u,props:f,source:a})}}function
|
|
241
|
-
`};delete n.items,Object.assign(n,{type:i,source:e,end:[a]});break}default:{const s="indent"in n?n.indent:-1,a="end"in n&&Array.isArray(n.end)?n.end.filter(o=>o.type==="space"||o.type==="comment"||o.type==="newline"):[];for(const o of Object.keys(n))o!=="type"&&o!=="offset"&&delete n[o];Object.assign(n,{type:i,indent:s,source:e,end:a})}}}const
|
|
239
|
+
`;if(n.type==="block-scalar"){const o=n.props[0];if(o.type!=="block-scalar-header")throw new Error("Invalid block scalar header");o.source=s,n.source=a}else{const{offset:o}=n,u="indent"in n?n.indent:-1,f=[{type:"block-scalar-header",offset:o,indent:u,source:s}];Pv(f,"end"in n?n.end:void 0)||f.push({type:"newline",offset:-1,indent:u,source:`
|
|
240
|
+
`});for(const d of Object.keys(n))d!=="type"&&d!=="offset"&&delete n[d];Object.assign(n,{type:"block-scalar",indent:u,props:f,source:a})}}function Pv(n,e){if(e)for(const i of e)switch(i.type){case"space":case"comment":n.push(i);break;case"newline":return n.push(i),!0}return!1}function oh(n,e,i){switch(n.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":n.type=i,n.source=e;break;case"block-scalar":{const s=n.props.slice(1);let a=e.length;n.props[0].type==="block-scalar-header"&&(a-=n.props[0].source.length);for(const o of s)o.offset+=a;delete n.props,Object.assign(n,{type:i,source:e,end:s});break}case"block-map":case"block-seq":{const a={type:"newline",offset:n.offset+e.length,indent:n.indent,source:`
|
|
241
|
+
`};delete n.items,Object.assign(n,{type:i,source:e,end:[a]});break}default:{const s="indent"in n?n.indent:-1,a="end"in n&&Array.isArray(n.end)?n.end.filter(o=>o.type==="space"||o.type==="comment"||o.type==="newline"):[];for(const o of Object.keys(n))o!=="type"&&o!=="offset"&&delete n[o];Object.assign(n,{type:i,indent:s,source:e,end:a})}}}const cN=n=>"type"in n?nc(n):$o(n);function nc(n){switch(n.type){case"block-scalar":{let e="";for(const i of n.props)e+=nc(i);return e+n.source}case"block-map":case"block-seq":{let e="";for(const i of n.items)e+=$o(i);return e}case"flow-collection":{let e=n.start.source;for(const i of n.items)e+=$o(i);for(const i of n.end)e+=i.source;return e}case"document":{let e=$o(n);if(n.end)for(const i of n.end)e+=i.source;return e}default:{let e=n.source;if("end"in n&&n.end)for(const i of n.end)e+=i.source;return e}}}function $o({start:n,key:e,sep:i,value:s}){let a="";for(const o of n)a+=o.source;if(e&&(a+=nc(e)),i)for(const o of i)a+=o.source;return s&&(a+=nc(s)),a}const Ch=Symbol("break visit"),uN=Symbol("skip children"),Fv=Symbol("remove item");function es(n,e){"type"in n&&n.type==="document"&&(n={start:n.start,value:n.value}),Qv(Object.freeze([]),n,e)}es.BREAK=Ch;es.SKIP=uN;es.REMOVE=Fv;es.itemAtPath=(n,e)=>{let i=n;for(const[s,a]of e){const o=i==null?void 0:i[s];if(o&&"items"in o)i=o.items[a];else return}return i};es.parentCollection=(n,e)=>{const i=es.itemAtPath(n,e.slice(0,-1)),s=e[e.length-1][0],a=i==null?void 0:i[s];if(a&&"items"in a)return a;throw new Error("Parent collection not found")};function Qv(n,e,i){let s=i(e,n);if(typeof s=="symbol")return s;for(const a of["key","value"]){const o=e[a];if(o&&"items"in o){for(let u=0;u<o.items.length;++u){const f=Qv(Object.freeze(n.concat([[a,u]])),o.items[u],i);if(typeof f=="number")u=f-1;else{if(f===Ch)return Ch;f===Fv&&(o.items.splice(u,1),u-=1)}}typeof s=="function"&&a==="key"&&(s=s(e,n))}}return typeof s=="function"?s(e,n):s}const wc="\uFEFF",xc="",_c="",Wa="",fN=n=>!!n&&"items"in n,hN=n=>!!n&&(n.type==="scalar"||n.type==="single-quoted-scalar"||n.type==="double-quoted-scalar"||n.type==="block-scalar");function dN(n){switch(n){case wc:return"<BOM>";case xc:return"<DOC>";case _c:return"<FLOW_END>";case Wa:return"<SCALAR>";default:return JSON.stringify(n)}}function Zv(n){switch(n){case wc:return"byte-order-mark";case xc:return"doc-mode";case _c:return"flow-error-end";case Wa:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case`
|
|
242
242
|
`:case`\r
|
|
243
|
-
`:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(n[0]){case" ":case" ":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}const
|
|
244
|
-
`:case"\r":case" ":return!0;default:return!1}}const p0=new Set("0123456789ABCDEFabcdef"),
|
|
245
|
-
\r `),ch=n=>!n||
|
|
243
|
+
`:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(n[0]){case" ":case" ":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}const pN=Object.freeze(Object.defineProperty({__proto__:null,BOM:wc,DOCUMENT:xc,FLOW_END:_c,SCALAR:Wa,createScalarToken:aN,isCollection:fN,isScalar:hN,prettyToken:dN,resolveAsScalar:rN,setScalarValue:lN,stringify:cN,tokenType:Zv,visit:es},Symbol.toStringTag,{value:"Module"}));function hn(n){switch(n){case void 0:case" ":case`
|
|
244
|
+
`:case"\r":case" ":return!0;default:return!1}}const p0=new Set("0123456789ABCDEFabcdef"),gN=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),No=new Set(",[]{}"),mN=new Set(` ,[]{}
|
|
245
|
+
\r `),ch=n=>!n||mN.has(n);class Jv{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,i=!1){if(e){if(typeof e!="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!i;let s=this.next??"stream";for(;s&&(i||this.hasChars(1));)s=yield*this.parseNext(s)}atLineEnd(){let e=this.pos,i=this.buffer[e];for(;i===" "||i===" ";)i=this.buffer[++e];return!i||i==="#"||i===`
|
|
246
246
|
`?!0:i==="\r"?this.buffer[e+1]===`
|
|
247
247
|
`:!1}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let i=this.buffer[e];if(this.indentNext>0){let s=0;for(;i===" ";)i=this.buffer[++s+e];if(i==="\r"){const a=this.buffer[s+e+1];if(a===`
|
|
248
248
|
`||!a&&!this.atEnd)return e+s+1}return i===`
|
|
@@ -257,10 +257,10 @@ ${i.comment}`:i.comment}this.doc.range[2]=i.offset;break}default:this.errors.pus
|
|
|
257
257
|
`&&o>=this.pos&&o+1+i>f)e=o;else break}while(!0);return yield Wa,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){const e=this.flowLevel>0;let i=this.pos-1,s=this.pos-1,a;for(;a=this.buffer[++s];)if(a===":"){const o=this.buffer[s+1];if(hn(o)||e&&No.has(o))break;i=s}else if(hn(a)){let o=this.buffer[s+1];if(a==="\r"&&(o===`
|
|
258
258
|
`?(s+=1,a=`
|
|
259
259
|
`,o=this.buffer[s+1]):i=s),o==="#"||e&&No.has(o))break;if(a===`
|
|
260
|
-
`){const u=this.continueScalar(s+1);if(u===-1)break;s=Math.max(s,u-2)}}else{if(e&&No.has(a))break;i=s}return!a&&!this.atEnd?this.setNext("plain-scalar"):(yield Wa,yield*this.pushToIndex(i+1,!0),e?"flow":"doc")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,i){const s=this.buffer.slice(this.pos,e);return s?(yield s,this.pos+=s.length,s.length):(i&&(yield""),0)}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(ch))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{const e=this.flowLevel>0,i=this.charAt(1);if(hn(i)||e&&No.has(i))return e?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}return 0}*pushTag(){if(this.charAt(1)==="<"){let e=this.pos+2,i=this.buffer[e];for(;!hn(i)&&i!==">";)i=this.buffer[++e];return yield*this.pushToIndex(i===">"?e+1:e,!1)}else{let e=this.pos+1,i=this.buffer[e];for(;i;)if(
|
|
260
|
+
`){const u=this.continueScalar(s+1);if(u===-1)break;s=Math.max(s,u-2)}}else{if(e&&No.has(a))break;i=s}return!a&&!this.atEnd?this.setNext("plain-scalar"):(yield Wa,yield*this.pushToIndex(i+1,!0),e?"flow":"doc")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,i){const s=this.buffer.slice(this.pos,e);return s?(yield s,this.pos+=s.length,s.length):(i&&(yield""),0)}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(ch))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{const e=this.flowLevel>0,i=this.charAt(1);if(hn(i)||e&&No.has(i))return e?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}return 0}*pushTag(){if(this.charAt(1)==="<"){let e=this.pos+2,i=this.buffer[e];for(;!hn(i)&&i!==">";)i=this.buffer[++e];return yield*this.pushToIndex(i===">"?e+1:e,!1)}else{let e=this.pos+1,i=this.buffer[e];for(;i;)if(gN.has(i))i=this.buffer[++e];else if(i==="%"&&p0.has(this.buffer[e+1])&&p0.has(this.buffer[e+2]))i=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){const e=this.buffer[this.pos];return e===`
|
|
261
261
|
`?yield*this.pushCount(1):e==="\r"&&this.charAt(1)===`
|
|
262
|
-
`?yield*this.pushCount(2):0}*pushSpaces(e){let i=this.pos-1,s;do s=this.buffer[++i];while(s===" "||e&&s===" ");const a=i-this.pos;return a>0&&(yield this.buffer.substr(this.pos,a),this.pos=i),a}*pushUntil(e){let i=this.pos,s=this.buffer[i];for(;!e(s);)s=this.buffer[++i];return yield*this.pushToIndex(i,!1)}}class
|
|
262
|
+
`?yield*this.pushCount(2):0}*pushSpaces(e){let i=this.pos-1,s;do s=this.buffer[++i];while(s===" "||e&&s===" ");const a=i-this.pos;return a>0&&(yield this.buffer.substr(this.pos,a),this.pos=i),a}*pushUntil(e){let i=this.pos,s=this.buffer[i];for(;!e(s);)s=this.buffer[++i];return yield*this.pushToIndex(i,!1)}}class Wv{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let i=0,s=this.lineStarts.length;for(;i<s;){const o=i+s>>1;this.lineStarts[o]<e?i=o+1:s=o}if(this.lineStarts[i]===e)return{line:i+1,col:1};if(i===0)return{line:0,col:e};const a=this.lineStarts[i-1];return{line:i,col:e-a+1}}}}function Pi(n,e){for(let i=0;i<n.length;++i)if(n[i].type===e)return!0;return!1}function g0(n){for(let e=0;e<n.length;++e)switch(n[e].type){case"space":case"comment":case"newline":break;default:return e}return-1}function eS(n){switch(n==null?void 0:n.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function Co(n){switch(n.type){case"document":return n.start;case"block-map":{const e=n.items[n.items.length-1];return e.sep??e.start}case"block-seq":return n.items[n.items.length-1].start;default:return[]}}function Js(n){var i;if(n.length===0)return[];let e=n.length;e:for(;--e>=0;)switch(n[e].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}for(;((i=n[++e])==null?void 0:i.type)==="space";);return n.splice(e,n.length)}function m0(n){if(n.start.type==="flow-seq-start")for(const e of n.items)e.sep&&!e.value&&!Pi(e.start,"explicit-key-ind")&&!Pi(e.sep,"map-value-ind")&&(e.key&&(e.value=e.key),delete e.key,eS(e.value)?e.value.end?Array.prototype.push.apply(e.value.end,e.sep):e.value.end=e.sep:Array.prototype.push.apply(e.start,e.sep),delete e.sep)}class wd{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new Jv,this.onNewLine=e}*parse(e,i=!1){this.onNewLine&&this.offset===0&&this.onNewLine(0);for(const s of this.lexer.lex(e,i))yield*this.next(s);i||(yield*this.end())}*next(e){if(this.source=e,this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}const i=Zv(e);if(i)if(i==="scalar")this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=i,yield*this.step(),i){case"newline":this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case"space":this.atNewLine&&e[0]===" "&&(this.indent+=e.length);break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":this.atNewLine&&(this.indent+=e.length);break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=e.length}else{const s=`Not a YAML token: ${e}`;yield*this.pop({type:"error",offset:this.offset,message:s,source:e}),this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){const e=this.peek(1);if(this.type==="doc-end"&&(!e||e.type!=="doc-end")){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}peek(e){return this.stack[this.stack.length-e]}*pop(e){const i=e??this.stack.pop();if(!i)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield i;else{const s=this.peek(1);switch(i.type==="block-scalar"?i.indent="indent"in s?s.indent:0:i.type==="flow-collection"&&s.type==="document"&&(i.indent=0),i.type==="flow-collection"&&m0(i),s.type){case"document":s.value=i;break;case"block-scalar":s.props.push(i);break;case"block-map":{const a=s.items[s.items.length-1];if(a.value){s.items.push({start:[],key:i,sep:[]}),this.onKeyLine=!0;return}else if(a.sep)a.value=i;else{Object.assign(a,{key:i,sep:[]}),this.onKeyLine=!a.explicitKey;return}break}case"block-seq":{const a=s.items[s.items.length-1];a.value?s.items.push({start:[],value:i}):a.value=i;break}case"flow-collection":{const a=s.items[s.items.length-1];!a||a.value?s.items.push({start:[],key:i,sep:[]}):a.sep?a.value=i:Object.assign(a,{key:i,sep:[]});return}default:yield*this.pop(),yield*this.pop(i)}if((s.type==="document"||s.type==="block-map"||s.type==="block-seq")&&(i.type==="block-map"||i.type==="block-seq")){const a=i.items[i.items.length-1];a&&!a.sep&&!a.value&&a.start.length>0&&g0(a.start)===-1&&(i.indent===0||a.start.every(o=>o.type!=="comment"||o.indent<i.indent))&&(s.type==="document"?s.end=a.start:s.items.push({start:a.start}),i.items.splice(-1,1))}}}*stream(){switch(this.type){case"directive-line":yield{type:"directive",offset:this.offset,source:this.source};return;case"byte-order-mark":case"space":case"comment":case"newline":yield this.sourceToken;return;case"doc-mode":case"doc-start":{const e={type:"document",offset:this.offset,start:[]};this.type==="doc-start"&&e.start.push(this.sourceToken),this.stack.push(e);return}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case"doc-start":{g0(e.start)!==-1?(yield*this.pop(),yield*this.step()):e.start.push(this.sourceToken);return}case"anchor":case"tag":case"space":case"comment":case"newline":e.start.push(this.sourceToken);return}const i=this.startBlockValue(e);i?this.stack.push(i):yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if(this.type==="map-value-ind"){const i=Co(this.peek(2)),s=Js(i);let a;e.end?(a=e.end,a.push(this.sourceToken),delete e.end):a=[this.sourceToken];const o={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:s,key:e,sep:a}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=o}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case"space":case"comment":case"newline":e.props.push(this.sourceToken);return;case"scalar":if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let i=this.source.indexOf(`
|
|
263
263
|
`)+1;for(;i!==0;)this.onNewLine(this.offset+i),i=this.source.indexOf(`
|
|
264
|
-
`,i)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){var s;const i=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,i.value){const a="end"in i.value?i.value.end:void 0,o=Array.isArray(a)?a[a.length-1]:void 0;(o==null?void 0:o.type)==="comment"?a==null||a.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"space":case"comment":if(i.value)e.items.push({start:[this.sourceToken]});else if(i.sep)i.sep.push(this.sourceToken);else{if(this.atIndentedComment(i.start,e.indent)){const a=e.items[e.items.length-2],o=(s=a==null?void 0:a.value)==null?void 0:s.end;if(Array.isArray(o)){Array.prototype.push.apply(o,i.start),o.push(this.sourceToken),e.items.pop();return}}i.start.push(this.sourceToken)}return}if(this.indent>=e.indent){const a=!this.onKeyLine&&this.indent===e.indent,o=a&&(i.sep||i.explicitKey)&&this.type!=="seq-item-ind";let u=[];if(o&&i.sep&&!i.value){const f=[];for(let d=0;d<i.sep.length;++d){const p=i.sep[d];switch(p.type){case"newline":f.push(d);break;case"space":break;case"comment":p.indent>e.indent&&(f.length=0);break;default:f.length=0}}f.length>=2&&(u=i.sep.splice(f[1]))}switch(this.type){case"anchor":case"tag":o||i.value?(u.push(this.sourceToken),e.items.push({start:u}),this.onKeyLine=!0):i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"explicit-key-ind":!i.sep&&!i.explicitKey?(i.start.push(this.sourceToken),i.explicitKey=!0):o||i.value?(u.push(this.sourceToken),e.items.push({start:u,explicitKey:!0})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case"map-value-ind":if(i.explicitKey)if(i.sep)if(i.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Pi(i.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:u,key:null,sep:[this.sourceToken]}]});else if(
|
|
264
|
+
`,i)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){var s;const i=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,i.value){const a="end"in i.value?i.value.end:void 0,o=Array.isArray(a)?a[a.length-1]:void 0;(o==null?void 0:o.type)==="comment"?a==null||a.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"space":case"comment":if(i.value)e.items.push({start:[this.sourceToken]});else if(i.sep)i.sep.push(this.sourceToken);else{if(this.atIndentedComment(i.start,e.indent)){const a=e.items[e.items.length-2],o=(s=a==null?void 0:a.value)==null?void 0:s.end;if(Array.isArray(o)){Array.prototype.push.apply(o,i.start),o.push(this.sourceToken),e.items.pop();return}}i.start.push(this.sourceToken)}return}if(this.indent>=e.indent){const a=!this.onKeyLine&&this.indent===e.indent,o=a&&(i.sep||i.explicitKey)&&this.type!=="seq-item-ind";let u=[];if(o&&i.sep&&!i.value){const f=[];for(let d=0;d<i.sep.length;++d){const p=i.sep[d];switch(p.type){case"newline":f.push(d);break;case"space":break;case"comment":p.indent>e.indent&&(f.length=0);break;default:f.length=0}}f.length>=2&&(u=i.sep.splice(f[1]))}switch(this.type){case"anchor":case"tag":o||i.value?(u.push(this.sourceToken),e.items.push({start:u}),this.onKeyLine=!0):i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"explicit-key-ind":!i.sep&&!i.explicitKey?(i.start.push(this.sourceToken),i.explicitKey=!0):o||i.value?(u.push(this.sourceToken),e.items.push({start:u,explicitKey:!0})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case"map-value-ind":if(i.explicitKey)if(i.sep)if(i.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Pi(i.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:u,key:null,sep:[this.sourceToken]}]});else if(eS(i.key)&&!Pi(i.sep,"newline")){const f=Js(i.start),d=i.key,p=i.sep;p.push(this.sourceToken),delete i.key,delete i.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:f,key:d,sep:p}]})}else u.length>0?i.sep=i.sep.concat(u,this.sourceToken):i.sep.push(this.sourceToken);else if(Pi(i.start,"newline"))Object.assign(i,{key:null,sep:[this.sourceToken]});else{const f=Js(i.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:f,key:null,sep:[this.sourceToken]}]})}else i.sep?i.value||o?e.items.push({start:u,key:null,sep:[this.sourceToken]}):Pi(i.sep,"map-value-ind")?this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):i.sep.push(this.sourceToken):Object.assign(i,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const f=this.flowScalar(this.type);o||i.value?(e.items.push({start:u,key:f,sep:[]}),this.onKeyLine=!0):i.sep?this.stack.push(f):(Object.assign(i,{key:f,sep:[]}),this.onKeyLine=!0);return}default:{const f=this.startBlockValue(e);if(f){a&&f.type!=="block-seq"&&e.items.push({start:u}),this.stack.push(f);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){var s;const i=e.items[e.items.length-1];switch(this.type){case"newline":if(i.value){const a="end"in i.value?i.value.end:void 0,o=Array.isArray(a)?a[a.length-1]:void 0;(o==null?void 0:o.type)==="comment"?a==null||a.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else i.start.push(this.sourceToken);return;case"space":case"comment":if(i.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(i.start,e.indent)){const a=e.items[e.items.length-2],o=(s=a==null?void 0:a.value)==null?void 0:s.end;if(Array.isArray(o)){Array.prototype.push.apply(o,i.start),o.push(this.sourceToken),e.items.pop();return}}i.start.push(this.sourceToken)}return;case"anchor":case"tag":if(i.value||this.indent<=e.indent)break;i.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;i.value||Pi(i.start,"seq-item-ind")?e.items.push({start:[this.sourceToken]}):i.start.push(this.sourceToken);return}if(this.indent>e.indent){const a=this.startBlockValue(e);if(a){this.stack.push(a);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){const i=e.items[e.items.length-1];if(this.type==="flow-error-end"){let s;do yield*this.pop(),s=this.peek(1);while(s&&s.type==="flow-collection")}else if(e.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":!i||i.sep?e.items.push({start:[this.sourceToken]}):i.start.push(this.sourceToken);return;case"map-value-ind":!i||i.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):i.sep?i.sep.push(this.sourceToken):Object.assign(i,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":!i||i.value?e.items.push({start:[this.sourceToken]}):i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const a=this.flowScalar(this.type);!i||i.value?e.items.push({start:[],key:a,sep:[]}):i.sep?this.stack.push(a):Object.assign(i,{key:a,sep:[]});return}case"flow-map-end":case"flow-seq-end":e.end.push(this.sourceToken);return}const s=this.startBlockValue(e);s?this.stack.push(s):(yield*this.pop(),yield*this.step())}else{const s=this.peek(2);if(s.type==="block-map"&&(this.type==="map-value-ind"&&s.indent===e.indent||this.type==="newline"&&!s.items[s.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&s.type!=="flow-collection"){const a=Co(s),o=Js(a);m0(e);const u=e.end.splice(1,e.end.length);u.push(this.sourceToken);const f={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:o,key:e,sep:u}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=f}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let i=this.source.indexOf(`
|
|
265
265
|
`)+1;for(;i!==0;)this.onNewLine(this.offset+i),i=this.source.indexOf(`
|
|
266
|
-
`,i)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;const i=Co(e),s=Js(i);return s.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;const i=Co(e),s=Js(i);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,i){return this.type!=="comment"||this.indent<=i?!1:e.every(s=>s.type==="newline"||s.type==="space")}*documentEnd(e){this.type!=="doc-mode"&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop())}}}function eS(n){const e=n.prettyErrors!==!1;return{lineCounter:n.lineCounter||e&&new Jv||null,prettyErrors:e}}function mN(n,e={}){const{lineCounter:i,prettyErrors:s}=eS(e),a=new wd(i==null?void 0:i.addNewLine),o=new Sd(e),u=Array.from(o.compose(a.parse(n)));if(s&&i)for(const f of u)f.errors.forEach(tc(n,i)),f.warnings.forEach(tc(n,i));return u.length>0?u:Object.assign([],{empty:!0},o.streamInfo())}function tS(n,e={}){const{lineCounter:i,prettyErrors:s}=eS(e),a=new wd(i==null?void 0:i.addNewLine),o=new Sd(e);let u=null;for(const f of o.compose(a.parse(n),!0,n.length))if(!u)u=f;else if(u.options.logLevel!=="silent"){u.errors.push(new Zi(f.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}return s&&i&&(u.errors.forEach(tc(n,i)),u.warnings.forEach(tc(n,i))),u}function yN(n,e,i){let s;typeof e=="function"?s=e:i===void 0&&e&&typeof e=="object"&&(i=e);const a=tS(n,i);if(!a)return null;if(a.warnings.forEach(o=>wv(a.options.logLevel,o)),a.errors.length>0){if(a.options.logLevel!=="silent")throw a.errors[0];a.errors=[]}return a.toJS(Object.assign({reviver:s},i))}function bN(n,e,i){let s=null;if(typeof e=="function"||Array.isArray(e)?s=e:i===void 0&&e&&(i=e),typeof i=="string"&&(i=i.length),typeof i=="number"){const a=Math.round(i);i=a<1?void 0:a>8?{indent:8}:{indent:a}}if(n===void 0){const{keepUndefined:a}=i??e??{};if(!a)return}return ss(n)&&!s?n.toString(i):new xr(n,s,i).toString(i)}const nS=Object.freeze(Object.defineProperty({__proto__:null,Alias:fc,CST:dN,Composer:Sd,Document:xr,Lexer:Zv,LineCounter:Jv,Pair:bt,Parser:wd,Scalar:fe,Schema:Sc,YAMLError:bd,YAMLMap:Xt,YAMLParseError:Zi,YAMLSeq:xi,YAMLWarning:qv,isAlias:is,isCollection:He,isDocument:ss,isMap:br,isNode:qe,isPair:Be,isScalar:Re,isSeq:vr,parse:yN,parseAllDocuments:mN,parseDocument:tS,stringify:bN,visit:wi,visitAsync:uc},Symbol.toStringTag,{value:"Module"})),vN=({action:n,model:e,sdkLanguage:i,testIdAttributeName:s,isInspecting:a,setIsInspecting:o,highlightedElement:u,setHighlightedElement:f})=>{const[d,p]=U.useState("action"),[m]=xn("shouldPopulateCanvasFromScreenshot",!1),y=U.useMemo(()=>_N(n),[n]),{snapshotInfoUrl:b,snapshotUrl:w,popoutUrl:E}=U.useMemo(()=>{const _=y[d];return e&&_?TN(e.traceUrl,_,m):{snapshotInfoUrl:void 0,snapshotUrl:void 0,popoutUrl:void 0}},[y,d,m,e]),x=U.useMemo(()=>b!==void 0?{snapshotInfoUrl:b,snapshotUrl:w,popoutUrl:E}:void 0,[b,w,E]);return v.jsxs("div",{className:"snapshot-tab vbox",children:[v.jsxs(Uh,{children:[v.jsx(zt,{className:"pick-locator",title:"Pick locator",icon:"target",toggled:a,onClick:()=>o(!a)}),["action","before","after"].map(_=>v.jsx(sb,{id:_,title:xN(_),selected:d===_,onSelect:()=>p(_)},_)),v.jsx("div",{style:{flex:"auto"}}),v.jsx(zt,{icon:"link-external",title:"Open snapshot in a new tab",disabled:!(x!=null&&x.popoutUrl),onClick:()=>{const _=window.open((x==null?void 0:x.popoutUrl)||"","_blank");_==null||_.addEventListener("DOMContentLoaded",()=>{new sv(_,{isUnderTest:sS,sdkLanguage:i,testIdAttributeName:s,stableRafCount:1,browserName:"chromium",customEngines:[]}).consoleApi.install()})}})]}),v.jsx(SN,{snapshotUrls:x,sdkLanguage:i,testIdAttributeName:s,isInspecting:a,setIsInspecting:o,highlightedElement:u,setHighlightedElement:f})]})},SN=({snapshotUrls:n,sdkLanguage:e,testIdAttributeName:i,isInspecting:s,setIsInspecting:a,highlightedElement:o,setHighlightedElement:u})=>{const f=U.useRef(null),d=U.useRef(null),[p,m]=U.useState({viewport:rS,url:""}),y=U.useRef({iteration:0,visibleIframe:0});return U.useEffect(()=>{(async()=>{const b=y.current.iteration+1,w=1-y.current.visibleIframe;y.current.iteration=b;const E=await EN(n==null?void 0:n.snapshotInfoUrl);if(y.current.iteration!==b)return;const x=[f,d][w].current;if(x){let _=()=>{};const k=new Promise(C=>_=C);try{x.addEventListener("load",_),x.addEventListener("error",_);const C=(n==null?void 0:n.snapshotUrl)||AN;x.contentWindow?x.contentWindow.location.replace(C):x.src=C,await k}catch{}finally{x.removeEventListener("load",_),x.removeEventListener("error",_)}}y.current.iteration===b&&(y.current.visibleIframe=w,m(E))})()},[n]),v.jsxs("div",{className:"vbox",tabIndex:0,onKeyDown:b=>{b.key==="Escape"&&s&&a(!1)},children:[v.jsx(y0,{isInspecting:s,sdkLanguage:e,testIdAttributeName:i,highlightedElement:o,setHighlightedElement:u,iframe:f.current,iteration:y.current.iteration}),v.jsx(y0,{isInspecting:s,sdkLanguage:e,testIdAttributeName:i,highlightedElement:o,setHighlightedElement:u,iframe:d.current,iteration:y.current.iteration}),v.jsx(wN,{snapshotInfo:p,children:v.jsxs("div",{className:"snapshot-switcher",children:[v.jsx("iframe",{ref:f,name:"snapshot",title:"DOM Snapshot",className:Ke(y.current.visibleIframe===0&&"snapshot-visible")}),v.jsx("iframe",{ref:d,name:"snapshot",title:"DOM Snapshot",className:Ke(y.current.visibleIframe===1&&"snapshot-visible")})]})})]})},wN=({snapshotInfo:n,children:e})=>{const[i,s]=ts(),a=40,o={width:n.viewport.width,height:n.viewport.height},u={width:Math.max(o.width,480),height:Math.max(o.height+a,320)},f=Math.min(i.width/u.width,i.height/u.height,1),d={x:(i.width-u.width)/2,y:(i.height-u.height)/2};return v.jsx("div",{ref:s,className:"snapshot-wrapper",children:v.jsxs("div",{className:"snapshot-container",style:{width:u.width+"px",height:u.height+"px",transform:`translate(${d.x}px, ${d.y}px) scale(${f})`},children:[v.jsx(cA,{url:n.url}),v.jsx("div",{className:"snapshot-browser-body",children:v.jsx("div",{style:{width:o.width+"px",height:o.height+"px"},children:e})})]})})};function xN(n){return n==="before"?"Before":n==="after"?"After":n==="action"?"Action":n}const y0=({iframe:n,isInspecting:e,sdkLanguage:i,testIdAttributeName:s,highlightedElement:a,setHighlightedElement:o,iteration:u})=>(U.useEffect(()=>{const f=a.lastEdited==="ariaSnapshot"?a.ariaSnapshot:void 0,d=a.lastEdited==="locator"?a.locator:void 0,p=!!f||!!d||e,m=[],y=new URLSearchParams(window.location.search).get("isUnderTest")==="true";try{iS(m,p,i,s,y,"",n==null?void 0:n.contentWindow)}catch{}const b=f?zh(nS,f):void 0,w=d?lA(i,d,s):void 0;for(const{recorder:E,frameSelector:x}of m){const _=w!=null&&w.startsWith(x)?w.substring(x.length).trim():void 0,k=(b==null?void 0:b.errors.length)===0?b.fragment:void 0;E.setUIState({mode:e?"inspecting":"none",actionSelector:_,ariaTemplate:k,language:i,testIdAttributeName:s,overlay:{offsetX:0}},{async elementPicked(C){o({locator:Wi(i,x+C.selector),ariaSnapshot:C.ariaSnapshot,lastEdited:"none"})},highlightUpdated(){for(const C of m)C.recorder!==E&&C.recorder.clearHighlight()}})}},[n,e,a,o,i,s,u]),v.jsx(v.Fragment,{}));function iS(n,e,i,s,a,o,u){if(!u)return;const f=u;if(!f._recorder&&e){const d=new sv(u,{isUnderTest:a,sdkLanguage:i,testIdAttributeName:s,stableRafCount:1,browserName:"chromium",customEngines:[]}),p=new tA(d);f._injectedScript=d,f._recorder={recorder:p,frameSelector:o},a&&(window._weakRecordersForTest=window._weakRecordersForTest||new Set,window._weakRecordersForTest.add(new WeakRef(p)))}f._recorder&&n.push(f._recorder);for(let d=0;d<u.frames.length;++d){const p=u.frames[d],m=p.frameElement?f._injectedScript.generateSelectorSimple(p.frameElement,{omitInternalEngines:!0,testIdAttributeName:s})+" >> internal:control=enter-frame >> ":"";iS(n,e,i,s,a,o+m,p)}}const Ra=(n,e,i=!1)=>{if(!n)return;const s=n[e];if(s){if(!n.pageId){console.error("snapshot action must have a pageId");return}return{action:n,snapshotName:s,pageId:n.pageId,point:n.point,hasInputTarget:i}}};function _N(n){if(!n)return{};let e=Ra(n,"beforeSnapshot");if(!e){for(let a=Ey(n);a;a=Ey(a))if(a.endTime<=n.startTime&&a.afterSnapshot){e=Ra(a,"afterSnapshot");break}}let i=Ra(n,"afterSnapshot");if(!i){let a;for(let o=Ay(n);o&&o.startTime<=n.endTime;o=Ay(o))o.endTime>n.endTime||!o.afterSnapshot||a&&a.endTime>o.endTime||(a=o);a?i=Ra(a,"afterSnapshot"):i=e}const s=Ra(n,"inputSnapshot",!0)??i;return s&&(s.point=n.point),{action:s,before:e,after:i}}const sS=new URLSearchParams(window.location.search).has("isUnderTest");function TN(n,e,i){const s=new URLSearchParams;s.set("trace",n),s.set("name",e.snapshotName),sS&&s.set("isUnderTest","true"),e.point&&(s.set("pointX",String(e.point.x)),s.set("pointY",String(e.point.y)),e.hasInputTarget&&s.set("hasInputTarget","1")),i&&s.set("shouldPopulateCanvasFromScreenshot","1");const a=new URL(`snapshot/${e.pageId}?${s.toString()}`,window.location.href).toString(),o=new URL(`snapshotInfo/${e.pageId}?${s.toString()}`,window.location.href).toString(),u=new URLSearchParams;u.set("r",a),u.set("trace",n);const f=new URL(`snapshot.html?${u.toString()}`,window.location.href).toString();return{snapshotInfoUrl:o,snapshotUrl:a,popoutUrl:f}}async function EN(n){const e={url:"",viewport:rS,timestamp:void 0,wallTime:void 0};if(n){const s=await(await fetch(n)).json();s.error||(e.url=s.url,e.viewport=s.viewport,e.timestamp=s.timestamp,e.wallTime=s.wallTime)}return e}const rS={width:1280,height:720},AN='data:text/html,<body style="background: #ddd"></body>',aS={width:200,height:45},er=2.5,NN=aS.height+er*2,CN=({boundaries:n,previewPoint:e})=>{var m,y;const i=U.useContext(Xn),[s,a]=ts(),o=U.useRef(null);let u=0;if(o.current&&e){const b=o.current.getBoundingClientRect();u=(e.clientY-b.top+o.current.scrollTop)/NN|0}const f=(y=(m=i==null?void 0:i.pages)==null?void 0:m[u])==null?void 0:y.screencastFrames;let d,p;if(e!==void 0&&f&&f.length){const b=n.minimum+(n.maximum-n.minimum)*e.x/s.width;d=f[v0(f,b,lS)-1];const w={width:Math.min(800,window.innerWidth/2|0),height:Math.min(800,window.innerHeight/2|0)};p=d?oS({width:d.width,height:d.height},w):void 0}return v.jsxs("div",{className:"film-strip",ref:a,children:[v.jsx("div",{className:"film-strip-lanes",ref:o,children:i==null?void 0:i.pages.map((b,w)=>b.screencastFrames.length?v.jsx(kN,{boundaries:n,page:b,width:s.width},w):null)}),i&&(e==null?void 0:e.x)!==void 0&&v.jsxs("div",{className:"film-strip-hover",style:{top:s.bottom+5,left:Math.min(e.x,s.width-(p?p.width:0)-10)},children:[e.action&&v.jsx("div",{className:"film-strip-hover-title",children:Dh(e.action,e)}),d&&p&&v.jsx("div",{style:{width:p.width,height:p.height},children:v.jsx("img",{src:i.createRelativeUrl(`sha1/${d.sha1}`),width:p.width,height:p.height})})]})]})},kN=({boundaries:n,page:e,width:i})=>{const s=U.useContext(Xn),a={width:0,height:0},o=e.screencastFrames;for(const _ of o)a.width=Math.max(a.width,_.width),a.height=Math.max(a.height,_.height);const u=oS(a,aS),f=o[0].timestamp,d=o[o.length-1].timestamp,p=n.maximum-n.minimum,m=(f-n.minimum)/p*i,y=(n.maximum-d)/p*i,w=(d-f)/p*i/(u.width+2*er)|0,E=(d-f)/w,x=[];for(let _=0;f&&E&&_<w;++_){const k=f+E*_,C=v0(o,k,lS)-1;x.push(v.jsx("div",{className:"film-strip-frame",style:{width:u.width,height:u.height,backgroundImage:`url(${s==null?void 0:s.createRelativeUrl("sha1/"+o[C].sha1)})`,backgroundSize:`${u.width}px ${u.height}px`,margin:er,marginRight:er}},_))}return x.push(v.jsx("div",{className:"film-strip-frame",style:{width:u.width,height:u.height,backgroundImage:`url(${s==null?void 0:s.createRelativeUrl("sha1/"+o[o.length-1].sha1)})`,backgroundSize:`${u.width}px ${u.height}px`,margin:er,marginRight:er}},x.length)),v.jsx("div",{className:"film-strip-lane",style:{marginLeft:m+"px",marginRight:y+"px"},children:x})};function lS(n,e){return n-e.timestamp}function oS(n,e){const i=Math.max(n.width/e.width,n.height/e.height);return{width:n.width/i|0,height:n.height/i|0}}const MN=({model:n,boundaries:e,consoleEntries:i,onSelected:s,highlightedAction:a,highlightedEntry:o,highlightedConsoleEntry:u,selectedTime:f,setSelectedTime:d,sdkLanguage:p})=>{const[m,y]=ts(),[b,w]=U.useState(),[E,x]=U.useState(),[_]=xn("actionsFilter",[]),{offsets:k,curtainLeft:C,curtainRight:V}=U.useMemo(()=>{let j=f||e;if(b&&b.startX!==b.endX){const q=wn(m.width,e,b.startX),Z=wn(m.width,e,b.endX);j={minimum:Math.min(q,Z),maximum:Math.max(q,Z)}}const F=sn(m.width,e,j.minimum),me=sn(m.width,e,e.maximum)-sn(m.width,e,j.maximum);return{offsets:ON(m.width,e),curtainLeft:F,curtainRight:me}},[f,e,b,m]),I=U.useMemo(()=>n==null?void 0:n.filteredActions(_),[n,_]),B=U.useMemo(()=>{const j=[];for(const F of I||[])j.push({action:F,leftTime:F.startTime,rightTime:F.endTime||e.maximum,leftPosition:sn(m.width,e,F.startTime),rightPosition:sn(m.width,e,F.endTime||e.maximum),active:!1,error:!!F.error});for(const F of(n==null?void 0:n.resources)||[]){const ge=F._monotonicTime,me=F._monotonicTime+F.time;j.push({resource:F,leftTime:ge,rightTime:me,leftPosition:sn(m.width,e,ge),rightPosition:sn(m.width,e,me),active:!1,error:!1})}for(const F of i||[])j.push({consoleMessage:F,leftTime:F.timestamp,rightTime:F.timestamp,leftPosition:sn(m.width,e,F.timestamp),rightPosition:sn(m.width,e,F.timestamp),active:!1,error:F.isError});return j},[n,I,i,e,m]);U.useMemo(()=>{for(const j of B)a?j.active=j.action===a:o?j.active=j.resource===o:u?j.active=j.consoleMessage===u:j.active=!1},[B,a,o,u]);const G=U.useCallback(j=>{if(x(void 0),!y.current)return;const F=j.clientX-y.current.getBoundingClientRect().left,ge=wn(m.width,e,F),me=f?sn(m.width,e,f.minimum):0,q=f?sn(m.width,e,f.maximum):0;f&&Math.abs(F-me)<10?w({startX:q,endX:F,type:"resize"}):f&&Math.abs(F-q)<10?w({startX:me,endX:F,type:"resize"}):f&&ge>f.minimum&&ge<f.maximum&&j.clientY-y.current.getBoundingClientRect().top<20?w({startX:me,endX:q,pivot:F,type:"move"}):w({startX:F,endX:F,type:"resize"})},[e,m,y,f]),J=U.useCallback(j=>{if(!y.current)return;const F=j.clientX-y.current.getBoundingClientRect().left,ge=wn(m.width,e,F),me=I==null?void 0:I.findLast(Se=>Se.startTime<=ge);if(!j.buttons){w(void 0);return}if(me&&s(me),!b)return;let q=b;if(b.type==="resize")q={...b,endX:F};else{const Se=F-b.pivot;let N=b.startX+Se,X=b.endX+Se;N<0&&(N=0,X=N+(b.endX-b.startX)),X>m.width&&(X=m.width,N=X-(b.endX-b.startX)),q={...b,startX:N,endX:X,pivot:F}}w(q);const Z=wn(m.width,e,q.startX),ne=wn(m.width,e,q.endX);Z!==ne&&d({minimum:Math.min(Z,ne),maximum:Math.max(Z,ne)})},[e,b,m,I,s,y,d]),$=U.useCallback(()=>{if(x(void 0),!!b){if(b.startX!==b.endX){const j=wn(m.width,e,b.startX),F=wn(m.width,e,b.endX);d({minimum:Math.min(j,F),maximum:Math.max(j,F)})}else{const j=wn(m.width,e,b.startX),F=I==null?void 0:I.findLast(ge=>ge.startTime<=j);F&&s(F),d(void 0)}w(void 0)}},[e,b,m,I,d,s]),R=U.useCallback(j=>{if(!y.current)return;const F=j.clientX-y.current.getBoundingClientRect().left,ge=wn(m.width,e,F),me=I==null?void 0:I.findLast(q=>q.startTime<=ge);x({x:F,clientY:j.clientY,action:me,sdkLanguage:p})},[e,m,I,y,p]),ee=U.useCallback(()=>{x(void 0)},[]),re=U.useCallback(()=>{d(void 0)},[d]);return v.jsxs("div",{className:"timeline-view-container",children:[!!b&&v.jsx(W0,{cursor:(b==null?void 0:b.type)==="resize"?"ew-resize":"grab",onPaneMouseUp:$,onPaneMouseMove:J,onPaneDoubleClick:re}),v.jsxs("div",{ref:y,className:"timeline-view",onMouseDown:G,onMouseMove:R,onMouseLeave:ee,children:[v.jsx("div",{className:"timeline-grid",children:k.map((j,F)=>v.jsx("div",{className:"timeline-divider",style:{left:j.position+"px"},children:v.jsx("div",{className:"timeline-time",children:_t(j.time-e.minimum)})},F))}),v.jsx("div",{style:{height:8}}),v.jsx(CN,{boundaries:e,previewPoint:E}),v.jsx("div",{className:"timeline-bars",children:B.filter(j=>!j.action||j.action.class!=="Test").map((j,F)=>v.jsx("div",{className:Ke("timeline-bar",j.action&&"action",j.resource&&"network",j.consoleMessage&&"console-message",j.active&&"active",j.error&&"error"),style:{left:j.leftPosition,width:Math.max(5,j.rightPosition-j.leftPosition),top:RN(j),bottom:0}},F))}),v.jsx("div",{className:"timeline-marker",style:{display:E!==void 0?"block":"none",left:((E==null?void 0:E.x)||0)+"px"}}),f&&v.jsxs("div",{className:"timeline-window",children:[v.jsx("div",{className:"timeline-window-curtain left",style:{width:C}}),v.jsx("div",{className:"timeline-window-resizer",style:{left:-5}}),v.jsx("div",{className:"timeline-window-center",children:v.jsx("div",{className:"timeline-window-drag"})}),v.jsx("div",{className:"timeline-window-resizer",style:{left:5}}),v.jsx("div",{className:"timeline-window-curtain right",style:{width:V}})]})]})]})};function ON(n,e){let s=n/64;const a=e.maximum-e.minimum,o=n/a;let u=a/s;const f=Math.ceil(Math.log(u)/Math.LN10);u=Math.pow(10,f),u*o>=320&&(u=u/5),u*o>=128&&(u=u/2);const d=e.minimum;let p=e.maximum;p+=64/o,s=Math.ceil((p-d)/u),u||(s=0);const m=[];for(let y=0;y<s;++y){const b=d+u*y;m.push({position:sn(n,e,b),time:b})}return m}function sn(n,e,i){return(i-e.minimum)/(e.maximum-e.minimum)*n}function wn(n,e,i){return i/n*(e.maximum-e.minimum)+e.minimum}function RN(n){return n.resource?25:20}const jN=({model:n})=>{var i,s;if(!n)return v.jsx(v.Fragment,{});const e=n.wallTime!==void 0?new Date(n.wallTime).toLocaleString(void 0,{timeZoneName:"short"}):void 0;return v.jsxs("div",{style:{flex:"auto",display:"block",overflow:"hidden auto"},children:[v.jsx("div",{className:"call-section",style:{paddingTop:2},children:"Time"}),!!e&&v.jsxs("div",{className:"call-line",children:["start time:",v.jsx("span",{className:"call-value datetime",title:e,children:e})]}),v.jsxs("div",{className:"call-line",children:["duration:",v.jsx("span",{className:"call-value number",title:_t(n.endTime-n.startTime),children:_t(n.endTime-n.startTime)})]}),v.jsx("div",{className:"call-section",children:"Browser"}),v.jsxs("div",{className:"call-line",children:["engine:",v.jsx("span",{className:"call-value string",title:n.browserName,children:n.browserName})]}),n.channel&&v.jsxs("div",{className:"call-line",children:["channel:",v.jsx("span",{className:"call-value string",title:n.channel,children:n.channel})]}),n.platform&&v.jsxs("div",{className:"call-line",children:["platform:",v.jsx("span",{className:"call-value string",title:n.platform,children:n.platform})]}),n.options.userAgent&&v.jsxs("div",{className:"call-line",children:["user agent:",v.jsx("span",{className:"call-value datetime",title:n.options.userAgent,children:n.options.userAgent})]}),n.options.baseURL&&v.jsxs(v.Fragment,{children:[v.jsx("div",{className:"call-section",style:{paddingTop:2},children:"Config"}),v.jsxs("div",{className:"call-line",children:["baseURL:",v.jsx("a",{className:"call-value string",href:n.options.baseURL,title:n.options.baseURL,target:"_blank",rel:"noopener noreferrer",children:n.options.baseURL})]})]}),v.jsx("div",{className:"call-section",children:"Viewport"}),n.options.viewport&&v.jsxs("div",{className:"call-line",children:["width:",v.jsx("span",{className:"call-value number",title:String(!!((i=n.options.viewport)!=null&&i.width)),children:n.options.viewport.width})]}),n.options.viewport&&v.jsxs("div",{className:"call-line",children:["height:",v.jsx("span",{className:"call-value number",title:String(!!((s=n.options.viewport)!=null&&s.height)),children:n.options.viewport.height})]}),v.jsxs("div",{className:"call-line",children:["is mobile:",v.jsx("span",{className:"call-value boolean",title:String(!!n.options.isMobile),children:String(!!n.options.isMobile)})]}),n.options.deviceScaleFactor&&v.jsxs("div",{className:"call-line",children:["device scale:",v.jsx("span",{className:"call-value number",title:String(n.options.deviceScaleFactor),children:String(n.options.deviceScaleFactor)})]}),v.jsx("div",{className:"call-section",children:"Counts"}),v.jsxs("div",{className:"call-line",children:["pages:",v.jsx("span",{className:"call-value number",children:n.pages.length})]}),v.jsxs("div",{className:"call-line",children:["actions:",v.jsx("span",{className:"call-value number",children:n.actions.length})]}),v.jsxs("div",{className:"call-line",children:["events:",v.jsx("span",{className:"call-value number",children:n.events.length})]})]})},LN=({annotations:n})=>n.length?v.jsx("div",{className:"annotations-tab",children:n.map((e,i)=>v.jsxs("div",{className:"annotation-item",children:[v.jsx("span",{style:{fontWeight:"bold"},children:e.type}),e.description&&v.jsxs("span",{children:[": ",tb(e.description)]})]},`annotation-${i}`))}):v.jsx(ns,{text:"No annotations"}),DN=({sdkLanguage:n,isInspecting:e,setIsInspecting:i,highlightedElement:s,setHighlightedElement:a})=>{const[o,u]=U.useState(),f=U.useCallback(d=>{const{errors:p}=zh(nS,d,{prettyErrors:!1}),m=p.map(y=>({message:y.message,line:y.range[1].line,column:y.range[1].col,type:"subtle-error"}));u(m),a({...s,ariaSnapshot:d,lastEdited:"ariaSnapshot"}),i(!1)},[s,a,i]);return v.jsxs("div",{style:{flex:"auto",backgroundColor:"var(--vscode-sideBar-background)",padding:"0 10px 10px 10px",overflow:"auto"},children:[v.jsxs("div",{className:"hbox",style:{lineHeight:"28px",color:"var(--vscode-editorCodeLens-foreground)"},children:[v.jsx("div",{children:"Locator"}),v.jsx(zt,{style:{margin:"0 4px"},title:"Pick locator",icon:"target",toggled:e,onClick:()=>i(!e)}),v.jsx("div",{style:{flex:"auto"}}),v.jsx(zt,{icon:"files",title:"Copy locator",onClick:()=>{gy(s.locator||"")}})]}),v.jsx("div",{style:{height:50},children:v.jsx(ur,{text:s.locator||"",highlighter:n,isFocused:!0,wrapLines:!0,onChange:d=>{a({...s,locator:d,lastEdited:"locator"}),i(!1)}})}),v.jsxs("div",{className:"hbox",style:{lineHeight:"28px",color:"var(--vscode-editorCodeLens-foreground)"},children:[v.jsx("div",{style:{flex:"auto"},children:"Aria snapshot"}),v.jsx(zt,{icon:"files",title:"Copy snapshot",onClick:()=>{gy(s.ariaSnapshot||"")}})]}),v.jsx("div",{style:{height:150},children:v.jsx(ur,{text:s.ariaSnapshot||"",highlighter:"yaml",wrapLines:!1,highlight:o,onChange:f})})]})},BN=({className:n,style:e,open:i,isModal:s,minWidth:a,verticalOffset:o,requestClose:u,anchor:f,dataTestId:d,children:p})=>{const m=U.useRef(null),[y,b]=U.useState(0),[w]=uh(m),[E,x]=uh(f),_=UN(w,E,o);return U.useEffect(()=>{const k=V=>{!m.current||!(V.target instanceof Node)||m.current.contains(V.target)||u==null||u()},C=V=>{V.key==="Escape"&&(u==null||u())};return i?(document.addEventListener("mousedown",k),document.addEventListener("keydown",C),()=>{document.removeEventListener("mousedown",k),document.removeEventListener("keydown",C)}):()=>{}},[i,u]),U.useLayoutEffect(()=>x(),[i,x]),U.useEffect(()=>{const k=()=>b(C=>C+1);return window.addEventListener("resize",k),()=>{window.removeEventListener("resize",k)}},[]),U.useLayoutEffect(()=>{m.current&&(i?s?m.current.showModal():m.current.show():m.current.close())},[i,s]),v.jsx("dialog",{ref:m,style:{position:"fixed",margin:0,zIndex:110,top:_.top,left:_.left,minWidth:a||0,...e},className:n,"data-testid":d,children:p})};function UN(n,e,i=4,s=4){let a=Math.max(s,e.left);a+n.width>window.innerWidth-s&&(a=window.innerWidth-n.width-s);let o=Math.max(0,e.bottom)+i;return o+n.height>window.innerHeight-i&&(Math.max(0,e.top)>n.height+i?o=Math.max(0,e.top)-n.height-i:o=window.innerHeight-i-n.height),{left:a,top:o}}const zN=({title:n,icon:e,dialogDataTestId:i,children:s})=>{const a=U.useRef(null),[o,u]=U.useState(!1);return v.jsxs(v.Fragment,{children:[v.jsx(zt,{ref:a,icon:e,title:n,onClick:()=>u(f=>!f)}),v.jsx(BN,{style:{backgroundColor:"var(--vscode-sideBar-background)",padding:"4px 8px"},open:o,verticalOffset:8,requestClose:()=>u(!1),anchor:a,dataTestId:i,children:s})]})},cS=({settings:n})=>v.jsx("div",{className:"vbox settings-view",children:n.map(e=>{const i=`setting-${e.name.replaceAll(/\s+/g,"-")}`;return v.jsx("div",{className:`setting setting-${e.type}`,title:e.title,children:HN(e,i)},e.name)})}),HN=(n,e)=>{switch(n.type){case"check":return v.jsxs(v.Fragment,{children:[v.jsx("input",{type:"checkbox",id:e,checked:n.value,onChange:()=>n.set(!n.value)}),v.jsxs("label",{htmlFor:e,children:[n.name,!!n.count&&v.jsx("span",{className:"setting-counter",children:n.count})]})]});case"select":return v.jsxs(v.Fragment,{children:[v.jsxs("label",{htmlFor:e,children:[n.name,":",!!n.count&&v.jsx("span",{className:"setting-counter",children:n.count})]}),v.jsx("select",{id:e,value:n.value,onChange:i=>n.set(i.target.value),children:n.options.map(i=>v.jsx("option",{value:i.value,children:i.label},i.value))})]});default:return null}},PN=({showSourcesFirst:n,rootDir:e,fallbackLocation:i,isLive:s,hideTimeline:a,status:o,annotations:u,inert:f,onOpenExternally:d,revealSource:p,testRunMetadata:m})=>{var Ei;const y=U.useContext(Xn),[b,w]=U.useState(void 0),[E,x]=U.useState(void 0),[_,k]=U.useState(void 0),[C,V]=U.useState(),[I,B]=U.useState(),[G,J]=U.useState(),[$,R]=U.useState("actions"),[ee,re]=xn("propertiesTab",n?"source":"call"),[j,F]=U.useState(!1),[ge,me]=U.useState({lastEdited:"none"}),[q,Z]=U.useState(),[ne,Se]=xn("propertiesSidebarLocation","bottom"),[N]=xn("actionsFilter",[]),X=U.useCallback(le=>{w(le==null?void 0:le.callId),x(void 0)},[]),Q=U.useMemo(()=>y==null?void 0:y.filteredActions(N),[y,N]),W=((y==null?void 0:y.actions.length)??0)-((Q==null?void 0:Q.length)??0),se=U.useMemo(()=>Q==null?void 0:Q.find(le=>le.callId===C),[Q,C]),ve=U.useCallback(le=>{V(le==null?void 0:le.callId)},[]),ue=U.useMemo(()=>(y==null?void 0:y.sources)||new Map,[y]);U.useEffect(()=>{Z(void 0),x(void 0)},[y]);const We=U.useMemo(()=>{if(b){const dt=Q==null?void 0:Q.find(At=>At.callId===b);if(dt)return dt}const le=y==null?void 0:y.failedAction();if(le)return le;if(Q!=null&&Q.length){let dt=Q.length-1;for(let At=0;At<Q.length;++At)if(Q[At].title==="After Hooks"&&At){dt=At-1;break}return Q[dt]}},[y,Q,b]),xe=U.useMemo(()=>se||We,[We,se]),gn=U.useMemo(()=>E?E.stack:xe==null?void 0:xe.stack,[xe,E]),rs=U.useCallback(le=>{X(le),ve(void 0)},[X,ve]),ht=U.useCallback(le=>{re(le),le!=="inspector"&&F(!1)},[re]),as=U.useCallback(le=>{!j&&le&&ht("inspector"),F(le)},[F,ht,j]),_r=U.useCallback(le=>{me(le),ht("inspector")},[ht]),Tr=U.useCallback(le=>{ht("attachments"),k(dt=>{if(!dt)return[le,0];const At=dt[1];return[le,At+1]})},[ht]);U.useEffect(()=>{p&&ht("source")},[p,ht]);const Er=w_(y,q),rl=Y_(y,q),Ht=m_(y),Pn=(y==null?void 0:y.sdkLanguage)||"javascript",al={id:"inspector",title:"Locator",render:()=>v.jsx(DN,{sdkLanguage:Pn,isInspecting:j,setIsInspecting:as,highlightedElement:ge,setHighlightedElement:me})},ll={id:"call",title:"Call",render:()=>v.jsx(Bx,{action:xe,startTimeOffset:(y==null?void 0:y.startTime)??0,sdkLanguage:Pn})},ls={id:"log",title:"Log",render:()=>v.jsx(Hx,{action:xe,isLive:s})},Tc={id:"errors",title:"Errors",errorCount:Ht.errors.size,render:()=>v.jsx(b_,{errorsModel:Ht,testRunMetadata:m,sdkLanguage:Pn,revealInSource:le=>{le.action?X(le.action):x(le),ht("source")},wallTime:(y==null?void 0:y.wallTime)??0})};let Ar;!We&&i&&(Ar=(Ei=i.source)==null?void 0:Ei.errors.length);const Nr={id:"source",title:"Source",errorCount:Ar,render:()=>v.jsx(d_,{stack:gn,sources:ue,rootDir:e,stackFrameLocation:ne==="bottom"?"right":"bottom",fallbackLocation:i,onOpenExternally:d})},Ec={id:"console",title:"Console",count:Er.entries.length,render:()=>v.jsx(x_,{consoleModel:Er,boundaries:rt,selectedTime:q,onAccepted:le=>Z({minimum:le.timestamp,maximum:le.timestamp}),onEntryHovered:J})},Ti={id:"network",title:"Network",count:rl.resources.length,render:()=>v.jsx(X_,{boundaries:rt,networkModel:rl,onEntryHovered:B,sdkLanguage:(y==null?void 0:y.sdkLanguage)??"javascript"})},vt={id:"attachments",title:"Attachments",count:y==null?void 0:y.visibleAttachments.length,render:()=>v.jsx(s_,{revealedAttachment:_})},Et=[al,ll,ls,Tc,Ec,Ti,Nr,vt];if(u!==void 0){const le={id:"annotations",title:"Annotations",count:u.length,render:()=>v.jsx(LN,{annotations:u})};Et.push(le)}if(n){const le=Et.indexOf(Nr);Et.splice(le,1),Et.splice(1,0,Nr)}const{boundaries:rt}=U.useMemo(()=>{const le={minimum:(y==null?void 0:y.startTime)||0,maximum:(y==null?void 0:y.endTime)||3e4};return le.minimum>le.maximum&&(le.minimum=0,le.maximum=3e4),le.maximum+=(le.maximum-le.minimum)/20,{boundaries:le}},[y]);let os=0;!s&&y&&y.endTime>=0?os=y.endTime-y.startTime:y&&y.wallTime&&(os=Date.now()-y.wallTime);const Ac={id:"actions",title:"Actions",component:v.jsxs("div",{className:"vbox",children:[o&&v.jsxs("div",{className:"workbench-run-status",children:[v.jsx("span",{className:Ke("codicon",Z0(o))}),v.jsx("div",{children:jx(o)}),v.jsx("div",{className:"spacer"}),v.jsx("div",{className:"workbench-run-duration",children:os?_t(os):""})]}),v.jsx(Dx,{sdkLanguage:Pn,actions:Q||[],selectedAction:y?We:void 0,selectedTime:q,setSelectedTime:Z,onSelected:rs,onHighlighted:ve,revealAttachment:Tr,revealConsole:()=>ht("console"),isLive:s}),v.jsxs("div",{className:"workbench-actions-status-bar",children:[!!W&&v.jsxs("span",{className:"workbench-actions-hidden-count",title:W+" actions hidden by filters",children:[W," hidden"]}),v.jsx(qN,{counters:y==null?void 0:y.actionCounters})]})]})},Nc={id:"metadata",title:"Metadata",component:v.jsx(jN,{model:y})};return v.jsxs("div",{className:"vbox workbench",...f?{inert:!0}:{},children:[!a&&v.jsx(MN,{model:y,consoleEntries:Er.entries,boundaries:rt,highlightedAction:se,highlightedEntry:I,highlightedConsoleEntry:G,onSelected:rs,sdkLanguage:Pn,selectedTime:q,setSelectedTime:Z}),v.jsx(Vo,{sidebarSize:250,orientation:ne==="bottom"?"vertical":"horizontal",settingName:"propertiesSidebar",main:v.jsx(Vo,{sidebarSize:250,orientation:"horizontal",sidebarIsFirst:!0,settingName:"actionListSidebar",main:v.jsx(vN,{action:xe,model:y,sdkLanguage:Pn,testIdAttributeName:(y==null?void 0:y.testIdAttributeName)||"data-testid",isInspecting:j,setIsInspecting:as,highlightedElement:ge,setHighlightedElement:_r}),sidebar:v.jsx(gh,{tabs:[Ac,Nc],selectedTab:$,setSelectedTab:R})}),sidebar:v.jsx(gh,{tabs:Et,selectedTab:ee,setSelectedTab:ht,rightToolbar:[ne==="bottom"?v.jsx(zt,{title:"Dock to right",icon:"layout-sidebar-right-off",onClick:()=>{Se("right")}}):v.jsx(zt,{title:"Dock to bottom",icon:"layout-panel-off",onClick:()=>{Se("bottom")}})],mode:ne==="bottom"?"default":"select"})})]})},qN=({counters:n})=>{const[e,i]=xn("actionsFilter",[]);return v.jsx(zN,{icon:"filter",title:"Filter actions",dialogDataTestId:"actions-filter-dialog",children:v.jsx(cS,{settings:[{type:"check",value:e.includes("getter"),set:s=>i(s?[...e,"getter"]:e.filter(a=>a!=="getter")),name:"Getters",count:n==null?void 0:n.get("getter")},{type:"check",value:e.includes("route"),set:s=>i(s?[...e,"route"]:e.filter(a=>a!=="route")),name:"Network routes",count:n==null?void 0:n.get("route")},{type:"check",value:e.includes("configuration"),set:s=>i(s?[...e,"configuration"]:e.filter(a=>a!=="configuration")),name:"Configuration",count:n==null?void 0:n.get("configuration")}]})})};var b0;(n=>{function e(i){for(const s of i.splice(0))s.dispose()}n.disposeAll=e})(b0||(b0={}));class ja{constructor(){this._listeners=new Set,this.event=(e,i)=>{this._listeners.add(e);let s=!1;const a=this,o={dispose(){s||(s=!0,a._listeners.delete(e))}};return i&&i.push(o),o}}fire(e){const i=!this._deliveryQueue;this._deliveryQueue||(this._deliveryQueue=[]);for(const s of this._listeners)this._deliveryQueue.push({listener:s,event:e});if(i){for(let s=0;s<this._deliveryQueue.length;s++){const{listener:a,event:o}=this._deliveryQueue[s];a.call(null,o)}this._deliveryQueue=void 0}}dispose(){this._listeners.clear(),this._deliveryQueue&&(this._deliveryQueue=[])}}class FN{constructor(e){this._ws=new WebSocket(e)}onmessage(e){this._ws.addEventListener("message",i=>e(i.data.toString()))}onopen(e){this._ws.addEventListener("open",e)}onerror(e){this._ws.addEventListener("error",e)}onclose(e){this._ws.addEventListener("close",e)}send(e){this._ws.send(e)}close(){this._ws.close()}}class QN{constructor(e){this._onCloseEmitter=new ja,this._onReportEmitter=new ja,this._onStdioEmitter=new ja,this._onTestFilesChangedEmitter=new ja,this._onLoadTraceRequestedEmitter=new ja,this._lastId=0,this._callbacks=new Map,this._isClosed=!1,this.onClose=this._onCloseEmitter.event,this.onReport=this._onReportEmitter.event,this.onStdio=this._onStdioEmitter.event,this.onTestFilesChanged=this._onTestFilesChangedEmitter.event,this.onLoadTraceRequested=this._onLoadTraceRequestedEmitter.event,this._transport=e,this._transport.onmessage(s=>{const a=JSON.parse(s),{id:o,result:u,error:f,method:d,params:p}=a;if(o){const m=this._callbacks.get(o);if(!m)return;this._callbacks.delete(o),f?m.reject(new Error(f)):m.resolve(u)}else this._dispatchEvent(d,p)});const i=setInterval(()=>this._sendMessage("ping").catch(()=>{}),3e4);this._connectedPromise=new Promise((s,a)=>{this._transport.onopen(s),this._transport.onerror(a)}),this._transport.onclose(()=>{this._isClosed=!0,this._onCloseEmitter.fire(),clearInterval(i)})}isClosed(){return this._isClosed}async _sendMessage(e,i){const s=globalThis.__logForTest;s==null||s({method:e,params:i}),await this._connectedPromise;const a=++this._lastId,o={id:a,method:e,params:i};return this._transport.send(JSON.stringify(o)),new Promise((u,f)=>{this._callbacks.set(a,{resolve:u,reject:f})})}_sendMessageNoReply(e,i){this._sendMessage(e,i).catch(()=>{})}_dispatchEvent(e,i){e==="report"?this._onReportEmitter.fire(i):e==="stdio"?this._onStdioEmitter.fire(i):e==="testFilesChanged"?this._onTestFilesChangedEmitter.fire(i):e==="loadTraceRequested"&&this._onLoadTraceRequestedEmitter.fire(i)}async initialize(e){await this._sendMessage("initialize",e)}async ping(e){await this._sendMessage("ping",e)}async pingNoReply(e){this._sendMessageNoReply("ping",e)}async watch(e){await this._sendMessage("watch",e)}watchNoReply(e){this._sendMessageNoReply("watch",e)}async open(e){await this._sendMessage("open",e)}openNoReply(e){this._sendMessageNoReply("open",e)}async resizeTerminal(e){await this._sendMessage("resizeTerminal",e)}resizeTerminalNoReply(e){this._sendMessageNoReply("resizeTerminal",e)}async checkBrowsers(e){return await this._sendMessage("checkBrowsers",e)}async installBrowsers(e){await this._sendMessage("installBrowsers",e)}async runGlobalSetup(e){return await this._sendMessage("runGlobalSetup",e)}async runGlobalTeardown(e){return await this._sendMessage("runGlobalTeardown",e)}async startDevServer(e){return await this._sendMessage("startDevServer",e)}async stopDevServer(e){return await this._sendMessage("stopDevServer",e)}async clearCache(e){return await this._sendMessage("clearCache",e)}async listFiles(e){return await this._sendMessage("listFiles",e)}async listTests(e){return await this._sendMessage("listTests",e)}async runTests(e){return await this._sendMessage("runTests",e)}async findRelatedTestFiles(e){return await this._sendMessage("findRelatedTestFiles",e)}async stopTests(e){await this._sendMessage("stopTests",e)}stopTestsNoReply(e){this._sendMessageNoReply("stopTests",e)}async closeGracefully(e){await this._sendMessage("closeGracefully",e)}close(){try{this._transport.close()}catch{}}}const ZN=()=>{const[n,e]=xn("shouldPopulateCanvasFromScreenshot",!1),[i,s]=jw(),[a,o]=xn("mergeFiles",!1);return v.jsx(cS,{settings:[{type:"check",value:i,set:s,name:"Dark mode"},{type:"check",value:a,set:o,name:"Merge files"},{type:"check",value:n,set:e,name:"Display canvas content",title:"Attempt to display the captured canvas appearance in the snapshot preview. May not be accurate."}]})};export{zN as D,t_ as E,YN as M,Ut as R,Vo as S,QN as T,FN as W,Px as _,ZN as a,Xn as b,PN as c,BN as d,IN as e,KN as f,fh as g,VN as h,GN as i,v as j,Ke as k,Ox as l,_t as m,Uh as n,zt as o,xn as p,cS as q,U as r,Yi as s,Z0 as t,ts as u,Ew as v};
|
|
266
|
+
`,i)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;const i=Co(e),s=Js(i);return s.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;const i=Co(e),s=Js(i);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,i){return this.type!=="comment"||this.indent<=i?!1:e.every(s=>s.type==="newline"||s.type==="space")}*documentEnd(e){this.type!=="doc-mode"&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop())}}}function tS(n){const e=n.prettyErrors!==!1;return{lineCounter:n.lineCounter||e&&new Wv||null,prettyErrors:e}}function yN(n,e={}){const{lineCounter:i,prettyErrors:s}=tS(e),a=new wd(i==null?void 0:i.addNewLine),o=new Sd(e),u=Array.from(o.compose(a.parse(n)));if(s&&i)for(const f of u)f.errors.forEach(tc(n,i)),f.warnings.forEach(tc(n,i));return u.length>0?u:Object.assign([],{empty:!0},o.streamInfo())}function nS(n,e={}){const{lineCounter:i,prettyErrors:s}=tS(e),a=new wd(i==null?void 0:i.addNewLine),o=new Sd(e);let u=null;for(const f of o.compose(a.parse(n),!0,n.length))if(!u)u=f;else if(u.options.logLevel!=="silent"){u.errors.push(new Zi(f.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}return s&&i&&(u.errors.forEach(tc(n,i)),u.warnings.forEach(tc(n,i))),u}function bN(n,e,i){let s;typeof e=="function"?s=e:i===void 0&&e&&typeof e=="object"&&(i=e);const a=nS(n,i);if(!a)return null;if(a.warnings.forEach(o=>xv(a.options.logLevel,o)),a.errors.length>0){if(a.options.logLevel!=="silent")throw a.errors[0];a.errors=[]}return a.toJS(Object.assign({reviver:s},i))}function vN(n,e,i){let s=null;if(typeof e=="function"||Array.isArray(e)?s=e:i===void 0&&e&&(i=e),typeof i=="string"&&(i=i.length),typeof i=="number"){const a=Math.round(i);i=a<1?void 0:a>8?{indent:8}:{indent:a}}if(n===void 0){const{keepUndefined:a}=i??e??{};if(!a)return}return ss(n)&&!s?n.toString(i):new xr(n,s,i).toString(i)}const iS=Object.freeze(Object.defineProperty({__proto__:null,Alias:fc,CST:pN,Composer:Sd,Document:xr,Lexer:Jv,LineCounter:Wv,Pair:bt,Parser:wd,Scalar:fe,Schema:Sc,YAMLError:bd,YAMLMap:Xt,YAMLParseError:Zi,YAMLSeq:xi,YAMLWarning:$v,isAlias:is,isCollection:He,isDocument:ss,isMap:br,isNode:qe,isPair:Be,isScalar:Re,isSeq:vr,parse:bN,parseAllDocuments:yN,parseDocument:nS,stringify:vN,visit:wi,visitAsync:uc},Symbol.toStringTag,{value:"Module"})),SN=({action:n,model:e,sdkLanguage:i,testIdAttributeName:s,isInspecting:a,setIsInspecting:o,highlightedElement:u,setHighlightedElement:f})=>{const[d,p]=U.useState("action"),[m]=xn("shouldPopulateCanvasFromScreenshot",!1),y=U.useMemo(()=>TN(n),[n]),{snapshotInfoUrl:b,snapshotUrl:w,popoutUrl:E}=U.useMemo(()=>{const _=y[d];return e&&_?EN(e.traceUrl,_,m):{snapshotInfoUrl:void 0,snapshotUrl:void 0,popoutUrl:void 0}},[y,d,m,e]),x=U.useMemo(()=>b!==void 0?{snapshotInfoUrl:b,snapshotUrl:w,popoutUrl:E}:void 0,[b,w,E]);return v.jsxs("div",{className:"snapshot-tab vbox",children:[v.jsxs(Uh,{children:[v.jsx(zt,{className:"pick-locator",title:"Pick locator",icon:"target",toggled:a,onClick:()=>o(!a)}),["action","before","after"].map(_=>v.jsx(sb,{id:_,title:_N(_),selected:d===_,onSelect:()=>p(_)},_)),v.jsx("div",{style:{flex:"auto"}}),v.jsx(zt,{icon:"link-external",title:"Open snapshot in a new tab",disabled:!(x!=null&&x.popoutUrl),onClick:()=>{const _=window.open((x==null?void 0:x.popoutUrl)||"","_blank");_==null||_.addEventListener("DOMContentLoaded",()=>{new rv(_,{isUnderTest:rS,sdkLanguage:i,testIdAttributeName:s,stableRafCount:1,browserName:"chromium",customEngines:[]}).consoleApi.install()})}})]}),v.jsx(wN,{snapshotUrls:x,sdkLanguage:i,testIdAttributeName:s,isInspecting:a,setIsInspecting:o,highlightedElement:u,setHighlightedElement:f})]})},wN=({snapshotUrls:n,sdkLanguage:e,testIdAttributeName:i,isInspecting:s,setIsInspecting:a,highlightedElement:o,setHighlightedElement:u})=>{const f=U.useRef(null),d=U.useRef(null),[p,m]=U.useState({viewport:aS,url:""}),y=U.useRef({iteration:0,visibleIframe:0});return U.useEffect(()=>{(async()=>{const b=y.current.iteration+1,w=1-y.current.visibleIframe;y.current.iteration=b;const E=await AN(n==null?void 0:n.snapshotInfoUrl);if(y.current.iteration!==b)return;const x=[f,d][w].current;if(x){let _=()=>{};const k=new Promise(C=>_=C);try{x.addEventListener("load",_),x.addEventListener("error",_);const C=(n==null?void 0:n.snapshotUrl)||NN;x.contentWindow?x.contentWindow.location.replace(C):x.src=C,await k}catch{}finally{x.removeEventListener("load",_),x.removeEventListener("error",_)}}y.current.iteration===b&&(y.current.visibleIframe=w,m(E))})()},[n]),v.jsxs("div",{className:"vbox",tabIndex:0,onKeyDown:b=>{b.key==="Escape"&&s&&a(!1)},children:[v.jsx(y0,{isInspecting:s,sdkLanguage:e,testIdAttributeName:i,highlightedElement:o,setHighlightedElement:u,iframe:f.current,iteration:y.current.iteration}),v.jsx(y0,{isInspecting:s,sdkLanguage:e,testIdAttributeName:i,highlightedElement:o,setHighlightedElement:u,iframe:d.current,iteration:y.current.iteration}),v.jsx(xN,{snapshotInfo:p,children:v.jsxs("div",{className:"snapshot-switcher",children:[v.jsx("iframe",{ref:f,name:"snapshot",title:"DOM Snapshot",className:Ke(y.current.visibleIframe===0&&"snapshot-visible")}),v.jsx("iframe",{ref:d,name:"snapshot",title:"DOM Snapshot",className:Ke(y.current.visibleIframe===1&&"snapshot-visible")})]})})]})},xN=({snapshotInfo:n,children:e})=>{const[i,s]=ts(),a=40,o={width:n.viewport.width,height:n.viewport.height},u={width:Math.max(o.width,480),height:Math.max(o.height+a,320)},f=Math.min(i.width/u.width,i.height/u.height,1),d={x:(i.width-u.width)/2,y:(i.height-u.height)/2};return v.jsx("div",{ref:s,className:"snapshot-wrapper",children:v.jsxs("div",{className:"snapshot-container",style:{width:u.width+"px",height:u.height+"px",transform:`translate(${d.x}px, ${d.y}px) scale(${f})`},children:[v.jsx(uA,{url:n.url}),v.jsx("div",{className:"snapshot-browser-body",children:v.jsx("div",{style:{width:o.width+"px",height:o.height+"px"},children:e})})]})})};function _N(n){return n==="before"?"Before":n==="after"?"After":n==="action"?"Action":n}const y0=({iframe:n,isInspecting:e,sdkLanguage:i,testIdAttributeName:s,highlightedElement:a,setHighlightedElement:o,iteration:u})=>(U.useEffect(()=>{const f=a.lastEdited==="ariaSnapshot"?a.ariaSnapshot:void 0,d=a.lastEdited==="locator"?a.locator:void 0,p=!!f||!!d||e,m=[],y=new URLSearchParams(window.location.search).get("isUnderTest")==="true";try{sS(m,p,i,s,y,"",n==null?void 0:n.contentWindow)}catch{}const b=f?zh(iS,f):void 0,w=d?oA(i,d,s):void 0;for(const{recorder:E,frameSelector:x}of m){const _=w!=null&&w.startsWith(x)?w.substring(x.length).trim():void 0,k=(b==null?void 0:b.errors.length)===0?b.fragment:void 0;E.setUIState({mode:e?"inspecting":"none",actionSelector:_,ariaTemplate:k,language:i,testIdAttributeName:s,overlay:{offsetX:0}},{async elementPicked(C){o({locator:Wi(i,x+C.selector),ariaSnapshot:C.ariaSnapshot,lastEdited:"none"})},highlightUpdated(){for(const C of m)C.recorder!==E&&C.recorder.clearHighlight()}})}},[n,e,a,o,i,s,u]),v.jsx(v.Fragment,{}));function sS(n,e,i,s,a,o,u){if(!u)return;const f=u;if(!f._recorder&&e){const d=new rv(u,{isUnderTest:a,sdkLanguage:i,testIdAttributeName:s,stableRafCount:1,browserName:"chromium",customEngines:[]}),p=new nA(d);f._injectedScript=d,f._recorder={recorder:p,frameSelector:o},a&&(window._weakRecordersForTest=window._weakRecordersForTest||new Set,window._weakRecordersForTest.add(new WeakRef(p)))}f._recorder&&n.push(f._recorder);for(let d=0;d<u.frames.length;++d){const p=u.frames[d],m=p.frameElement?f._injectedScript.generateSelectorSimple(p.frameElement,{omitInternalEngines:!0,testIdAttributeName:s})+" >> internal:control=enter-frame >> ":"";sS(n,e,i,s,a,o+m,p)}}const Ra=(n,e,i=!1)=>{if(!n)return;const s=n[e];if(s){if(!n.pageId){console.error("snapshot action must have a pageId");return}return{action:n,snapshotName:s,pageId:n.pageId,point:n.point,hasInputTarget:i}}};function TN(n){if(!n)return{};let e=Ra(n,"beforeSnapshot");if(!e){for(let a=Ey(n);a;a=Ey(a))if(a.endTime<=n.startTime&&a.afterSnapshot){e=Ra(a,"afterSnapshot");break}}let i=Ra(n,"afterSnapshot");if(!i){let a;for(let o=Ay(n);o&&o.startTime<=n.endTime;o=Ay(o))o.endTime>n.endTime||!o.afterSnapshot||a&&a.endTime>o.endTime||(a=o);a?i=Ra(a,"afterSnapshot"):i=e}const s=Ra(n,"inputSnapshot",!0)??i;return s&&(s.point=n.point),{action:s,before:e,after:i}}const rS=new URLSearchParams(window.location.search).has("isUnderTest");function EN(n,e,i){const s=new URLSearchParams;s.set("trace",n),s.set("name",e.snapshotName),rS&&s.set("isUnderTest","true"),e.point&&(s.set("pointX",String(e.point.x)),s.set("pointY",String(e.point.y)),e.hasInputTarget&&s.set("hasInputTarget","1")),i&&s.set("shouldPopulateCanvasFromScreenshot","1");const a=new URL(`snapshot/${e.pageId}?${s.toString()}`,window.location.href).toString(),o=new URL(`snapshotInfo/${e.pageId}?${s.toString()}`,window.location.href).toString(),u=new URLSearchParams;u.set("r",a),u.set("trace",n);const f=new URL(`snapshot.html?${u.toString()}`,window.location.href).toString();return{snapshotInfoUrl:o,snapshotUrl:a,popoutUrl:f}}async function AN(n){const e={url:"",viewport:aS,timestamp:void 0,wallTime:void 0};if(n){const s=await(await fetch(n)).json();s.error||(e.url=s.url,e.viewport=s.viewport,e.timestamp=s.timestamp,e.wallTime=s.wallTime)}return e}const aS={width:1280,height:720},NN='data:text/html,<body style="background: #ddd"></body>',lS={width:200,height:45},er=2.5,CN=lS.height+er*2,kN=({boundaries:n,previewPoint:e})=>{var m,y;const i=U.useContext(Xn),[s,a]=ts(),o=U.useRef(null);let u=0;if(o.current&&e){const b=o.current.getBoundingClientRect();u=(e.clientY-b.top+o.current.scrollTop)/CN|0}const f=(y=(m=i==null?void 0:i.pages)==null?void 0:m[u])==null?void 0:y.screencastFrames;let d,p;if(e!==void 0&&f&&f.length){const b=n.minimum+(n.maximum-n.minimum)*e.x/s.width;d=f[v0(f,b,oS)-1];const w={width:Math.min(800,window.innerWidth/2|0),height:Math.min(800,window.innerHeight/2|0)};p=d?cS({width:d.width,height:d.height},w):void 0}return v.jsxs("div",{className:"film-strip",ref:a,children:[v.jsx("div",{className:"film-strip-lanes",ref:o,children:i==null?void 0:i.pages.map((b,w)=>b.screencastFrames.length?v.jsx(MN,{boundaries:n,page:b,width:s.width},w):null)}),i&&(e==null?void 0:e.x)!==void 0&&v.jsxs("div",{className:"film-strip-hover",style:{top:s.bottom+5,left:Math.min(e.x,s.width-(p?p.width:0)-10)},children:[e.action&&v.jsx("div",{className:"film-strip-hover-title",children:Dh(e.action,e)}),d&&p&&v.jsx("div",{style:{width:p.width,height:p.height},children:v.jsx("img",{src:i.createRelativeUrl(`sha1/${d.sha1}`),width:p.width,height:p.height})})]})]})},MN=({boundaries:n,page:e,width:i})=>{const s=U.useContext(Xn),a={width:0,height:0},o=e.screencastFrames;for(const _ of o)a.width=Math.max(a.width,_.width),a.height=Math.max(a.height,_.height);const u=cS(a,lS),f=o[0].timestamp,d=o[o.length-1].timestamp,p=n.maximum-n.minimum,m=(f-n.minimum)/p*i,y=(n.maximum-d)/p*i,w=(d-f)/p*i/(u.width+2*er)|0,E=(d-f)/w,x=[];for(let _=0;f&&E&&_<w;++_){const k=f+E*_,C=v0(o,k,oS)-1;x.push(v.jsx("div",{className:"film-strip-frame",style:{width:u.width,height:u.height,backgroundImage:`url(${s==null?void 0:s.createRelativeUrl("sha1/"+o[C].sha1)})`,backgroundSize:`${u.width}px ${u.height}px`,margin:er,marginRight:er}},_))}return x.push(v.jsx("div",{className:"film-strip-frame",style:{width:u.width,height:u.height,backgroundImage:`url(${s==null?void 0:s.createRelativeUrl("sha1/"+o[o.length-1].sha1)})`,backgroundSize:`${u.width}px ${u.height}px`,margin:er,marginRight:er}},x.length)),v.jsx("div",{className:"film-strip-lane",style:{marginLeft:m+"px",marginRight:y+"px"},children:x})};function oS(n,e){return n-e.timestamp}function cS(n,e){const i=Math.max(n.width/e.width,n.height/e.height);return{width:n.width/i|0,height:n.height/i|0}}const ON=({model:n,boundaries:e,consoleEntries:i,onSelected:s,highlightedAction:a,highlightedEntry:o,highlightedConsoleEntry:u,selectedTime:f,setSelectedTime:d,sdkLanguage:p})=>{const[m,y]=ts(),[b,w]=U.useState(),[E,x]=U.useState(),[_]=xn("actionsFilter",[]),{offsets:k,curtainLeft:C,curtainRight:V}=U.useMemo(()=>{let j=f||e;if(b&&b.startX!==b.endX){const q=wn(m.width,e,b.startX),Z=wn(m.width,e,b.endX);j={minimum:Math.min(q,Z),maximum:Math.max(q,Z)}}const F=sn(m.width,e,j.minimum),me=sn(m.width,e,e.maximum)-sn(m.width,e,j.maximum);return{offsets:RN(m.width,e),curtainLeft:F,curtainRight:me}},[f,e,b,m]),I=U.useMemo(()=>n==null?void 0:n.filteredActions(_),[n,_]),B=U.useMemo(()=>{const j=[];for(const F of I||[])j.push({action:F,leftTime:F.startTime,rightTime:F.endTime||e.maximum,leftPosition:sn(m.width,e,F.startTime),rightPosition:sn(m.width,e,F.endTime||e.maximum),active:!1,error:!!F.error});for(const F of(n==null?void 0:n.resources)||[]){const ge=F._monotonicTime,me=F._monotonicTime+F.time;j.push({resource:F,leftTime:ge,rightTime:me,leftPosition:sn(m.width,e,ge),rightPosition:sn(m.width,e,me),active:!1,error:!1})}for(const F of i||[])j.push({consoleMessage:F,leftTime:F.timestamp,rightTime:F.timestamp,leftPosition:sn(m.width,e,F.timestamp),rightPosition:sn(m.width,e,F.timestamp),active:!1,error:F.isError});return j},[n,I,i,e,m]);U.useMemo(()=>{for(const j of B)a?j.active=j.action===a:o?j.active=j.resource===o:u?j.active=j.consoleMessage===u:j.active=!1},[B,a,o,u]);const G=U.useCallback(j=>{if(x(void 0),!y.current)return;const F=j.clientX-y.current.getBoundingClientRect().left,ge=wn(m.width,e,F),me=f?sn(m.width,e,f.minimum):0,q=f?sn(m.width,e,f.maximum):0;f&&Math.abs(F-me)<10?w({startX:q,endX:F,type:"resize"}):f&&Math.abs(F-q)<10?w({startX:me,endX:F,type:"resize"}):f&&ge>f.minimum&&ge<f.maximum&&j.clientY-y.current.getBoundingClientRect().top<20?w({startX:me,endX:q,pivot:F,type:"move"}):w({startX:F,endX:F,type:"resize"})},[e,m,y,f]),J=U.useCallback(j=>{if(!y.current)return;const F=j.clientX-y.current.getBoundingClientRect().left,ge=wn(m.width,e,F),me=I==null?void 0:I.findLast(Se=>Se.startTime<=ge);if(!j.buttons){w(void 0);return}if(me&&s(me),!b)return;let q=b;if(b.type==="resize")q={...b,endX:F};else{const Se=F-b.pivot;let N=b.startX+Se,X=b.endX+Se;N<0&&(N=0,X=N+(b.endX-b.startX)),X>m.width&&(X=m.width,N=X-(b.endX-b.startX)),q={...b,startX:N,endX:X,pivot:F}}w(q);const Z=wn(m.width,e,q.startX),ne=wn(m.width,e,q.endX);Z!==ne&&d({minimum:Math.min(Z,ne),maximum:Math.max(Z,ne)})},[e,b,m,I,s,y,d]),$=U.useCallback(()=>{if(x(void 0),!!b){if(b.startX!==b.endX){const j=wn(m.width,e,b.startX),F=wn(m.width,e,b.endX);d({minimum:Math.min(j,F),maximum:Math.max(j,F)})}else{const j=wn(m.width,e,b.startX),F=I==null?void 0:I.findLast(ge=>ge.startTime<=j);F&&s(F),d(void 0)}w(void 0)}},[e,b,m,I,d,s]),R=U.useCallback(j=>{if(!y.current)return;const F=j.clientX-y.current.getBoundingClientRect().left,ge=wn(m.width,e,F),me=I==null?void 0:I.findLast(q=>q.startTime<=ge);x({x:F,clientY:j.clientY,action:me,sdkLanguage:p})},[e,m,I,y,p]),ee=U.useCallback(()=>{x(void 0)},[]),re=U.useCallback(()=>{d(void 0)},[d]);return v.jsxs("div",{className:"timeline-view-container",children:[!!b&&v.jsx(W0,{cursor:(b==null?void 0:b.type)==="resize"?"ew-resize":"grab",onPaneMouseUp:$,onPaneMouseMove:J,onPaneDoubleClick:re}),v.jsxs("div",{ref:y,className:"timeline-view",onMouseDown:G,onMouseMove:R,onMouseLeave:ee,children:[v.jsx("div",{className:"timeline-grid",children:k.map((j,F)=>v.jsx("div",{className:"timeline-divider",style:{left:j.position+"px"},children:v.jsx("div",{className:"timeline-time",children:_t(j.time-e.minimum)})},F))}),v.jsx("div",{style:{height:8}}),v.jsx(kN,{boundaries:e,previewPoint:E}),v.jsx("div",{className:"timeline-bars",children:B.filter(j=>!j.action||j.action.class!=="Test").map((j,F)=>v.jsx("div",{className:Ke("timeline-bar",j.action&&"action",j.resource&&"network",j.consoleMessage&&"console-message",j.active&&"active",j.error&&"error"),style:{left:j.leftPosition,width:Math.max(5,j.rightPosition-j.leftPosition),top:jN(j),bottom:0}},F))}),v.jsx("div",{className:"timeline-marker",style:{display:E!==void 0?"block":"none",left:((E==null?void 0:E.x)||0)+"px"}}),f&&v.jsxs("div",{className:"timeline-window",children:[v.jsx("div",{className:"timeline-window-curtain left",style:{width:C}}),v.jsx("div",{className:"timeline-window-resizer",style:{left:-5}}),v.jsx("div",{className:"timeline-window-center",children:v.jsx("div",{className:"timeline-window-drag"})}),v.jsx("div",{className:"timeline-window-resizer",style:{left:5}}),v.jsx("div",{className:"timeline-window-curtain right",style:{width:V}})]})]})]})};function RN(n,e){let s=n/64;const a=e.maximum-e.minimum,o=n/a;let u=a/s;const f=Math.ceil(Math.log(u)/Math.LN10);u=Math.pow(10,f),u*o>=320&&(u=u/5),u*o>=128&&(u=u/2);const d=e.minimum;let p=e.maximum;p+=64/o,s=Math.ceil((p-d)/u),u||(s=0);const m=[];for(let y=0;y<s;++y){const b=d+u*y;m.push({position:sn(n,e,b),time:b})}return m}function sn(n,e,i){return(i-e.minimum)/(e.maximum-e.minimum)*n}function wn(n,e,i){return i/n*(e.maximum-e.minimum)+e.minimum}function jN(n){return n.resource?25:20}const LN=({model:n})=>{var i,s;if(!n)return v.jsx(v.Fragment,{});const e=n.wallTime!==void 0?new Date(n.wallTime).toLocaleString(void 0,{timeZoneName:"short"}):void 0;return v.jsxs("div",{style:{flex:"auto",display:"block",overflow:"hidden auto"},children:[v.jsx("div",{className:"call-section",style:{paddingTop:2},children:"Time"}),!!e&&v.jsxs("div",{className:"call-line",children:["start time:",v.jsx("span",{className:"call-value datetime",title:e,children:e})]}),v.jsxs("div",{className:"call-line",children:["duration:",v.jsx("span",{className:"call-value number",title:_t(n.endTime-n.startTime),children:_t(n.endTime-n.startTime)})]}),v.jsx("div",{className:"call-section",children:"Browser"}),v.jsxs("div",{className:"call-line",children:["engine:",v.jsx("span",{className:"call-value string",title:n.browserName,children:n.browserName})]}),n.channel&&v.jsxs("div",{className:"call-line",children:["channel:",v.jsx("span",{className:"call-value string",title:n.channel,children:n.channel})]}),n.platform&&v.jsxs("div",{className:"call-line",children:["platform:",v.jsx("span",{className:"call-value string",title:n.platform,children:n.platform})]}),n.options.userAgent&&v.jsxs("div",{className:"call-line",children:["user agent:",v.jsx("span",{className:"call-value datetime",title:n.options.userAgent,children:n.options.userAgent})]}),n.options.baseURL&&v.jsxs(v.Fragment,{children:[v.jsx("div",{className:"call-section",style:{paddingTop:2},children:"Config"}),v.jsxs("div",{className:"call-line",children:["baseURL:",v.jsx("a",{className:"call-value string",href:n.options.baseURL,title:n.options.baseURL,target:"_blank",rel:"noopener noreferrer",children:n.options.baseURL})]})]}),v.jsx("div",{className:"call-section",children:"Viewport"}),n.options.viewport&&v.jsxs("div",{className:"call-line",children:["width:",v.jsx("span",{className:"call-value number",title:String(!!((i=n.options.viewport)!=null&&i.width)),children:n.options.viewport.width})]}),n.options.viewport&&v.jsxs("div",{className:"call-line",children:["height:",v.jsx("span",{className:"call-value number",title:String(!!((s=n.options.viewport)!=null&&s.height)),children:n.options.viewport.height})]}),v.jsxs("div",{className:"call-line",children:["is mobile:",v.jsx("span",{className:"call-value boolean",title:String(!!n.options.isMobile),children:String(!!n.options.isMobile)})]}),n.options.deviceScaleFactor&&v.jsxs("div",{className:"call-line",children:["device scale:",v.jsx("span",{className:"call-value number",title:String(n.options.deviceScaleFactor),children:String(n.options.deviceScaleFactor)})]}),v.jsx("div",{className:"call-section",children:"Counts"}),v.jsxs("div",{className:"call-line",children:["pages:",v.jsx("span",{className:"call-value number",children:n.pages.length})]}),v.jsxs("div",{className:"call-line",children:["actions:",v.jsx("span",{className:"call-value number",children:n.actions.length})]}),v.jsxs("div",{className:"call-line",children:["events:",v.jsx("span",{className:"call-value number",children:n.events.length})]})]})},DN=({annotations:n})=>n.length?v.jsx("div",{className:"annotations-tab",children:n.map((e,i)=>v.jsxs("div",{className:"annotation-item",children:[v.jsx("span",{style:{fontWeight:"bold"},children:e.type}),e.description&&v.jsxs("span",{children:[": ",tb(e.description)]})]},`annotation-${i}`))}):v.jsx(ns,{text:"No annotations"}),BN=({sdkLanguage:n,isInspecting:e,setIsInspecting:i,highlightedElement:s,setHighlightedElement:a})=>{const[o,u]=U.useState(),f=U.useCallback(d=>{const{errors:p}=zh(iS,d,{prettyErrors:!1}),m=p.map(y=>({message:y.message,line:y.range[1].line,column:y.range[1].col,type:"subtle-error"}));u(m),a({...s,ariaSnapshot:d,lastEdited:"ariaSnapshot"}),i(!1)},[s,a,i]);return v.jsxs("div",{style:{flex:"auto",backgroundColor:"var(--vscode-sideBar-background)",padding:"0 10px 10px 10px",overflow:"auto"},children:[v.jsxs("div",{className:"hbox",style:{lineHeight:"28px",color:"var(--vscode-editorCodeLens-foreground)"},children:[v.jsx("div",{children:"Locator"}),v.jsx(zt,{style:{margin:"0 4px"},title:"Pick locator",icon:"target",toggled:e,onClick:()=>i(!e)}),v.jsx("div",{style:{flex:"auto"}}),v.jsx(zt,{icon:"files",title:"Copy locator",onClick:()=>{gy(s.locator||"")}})]}),v.jsx("div",{style:{height:50},children:v.jsx(ur,{text:s.locator||"",highlighter:n,isFocused:!0,wrapLines:!0,onChange:d=>{a({...s,locator:d,lastEdited:"locator"}),i(!1)}})}),v.jsxs("div",{className:"hbox",style:{lineHeight:"28px",color:"var(--vscode-editorCodeLens-foreground)"},children:[v.jsx("div",{style:{flex:"auto"},children:"Aria snapshot"}),v.jsx(zt,{icon:"files",title:"Copy snapshot",onClick:()=>{gy(s.ariaSnapshot||"")}})]}),v.jsx("div",{style:{height:150},children:v.jsx(ur,{text:s.ariaSnapshot||"",highlighter:"yaml",wrapLines:!1,highlight:o,onChange:f})})]})},UN=({className:n,style:e,open:i,isModal:s,minWidth:a,verticalOffset:o,requestClose:u,anchor:f,dataTestId:d,children:p})=>{const m=U.useRef(null),[y,b]=U.useState(0),[w]=uh(m),[E,x]=uh(f),_=zN(w,E,o);return U.useEffect(()=>{const k=V=>{!m.current||!(V.target instanceof Node)||m.current.contains(V.target)||u==null||u()},C=V=>{V.key==="Escape"&&(u==null||u())};return i?(document.addEventListener("mousedown",k),document.addEventListener("keydown",C),()=>{document.removeEventListener("mousedown",k),document.removeEventListener("keydown",C)}):()=>{}},[i,u]),U.useLayoutEffect(()=>x(),[i,x]),U.useEffect(()=>{const k=()=>b(C=>C+1);return window.addEventListener("resize",k),()=>{window.removeEventListener("resize",k)}},[]),U.useLayoutEffect(()=>{m.current&&(i?s?m.current.showModal():m.current.show():m.current.close())},[i,s]),v.jsx("dialog",{ref:m,style:{position:"fixed",margin:0,zIndex:110,top:_.top,left:_.left,minWidth:a||0,...e},className:n,"data-testid":d,children:p})};function zN(n,e,i=4,s=4){let a=Math.max(s,e.left);a+n.width>window.innerWidth-s&&(a=window.innerWidth-n.width-s);let o=Math.max(0,e.bottom)+i;return o+n.height>window.innerHeight-i&&(Math.max(0,e.top)>n.height+i?o=Math.max(0,e.top)-n.height-i:o=window.innerHeight-i-n.height),{left:a,top:o}}const HN=({title:n,icon:e,dialogDataTestId:i,children:s})=>{const a=U.useRef(null),[o,u]=U.useState(!1);return v.jsxs(v.Fragment,{children:[v.jsx(zt,{ref:a,icon:e,title:n,onClick:()=>u(f=>!f)}),v.jsx(UN,{style:{backgroundColor:"var(--vscode-sideBar-background)",padding:"4px 8px"},open:o,verticalOffset:8,requestClose:()=>u(!1),anchor:a,dataTestId:i,children:s})]})},uS=({settings:n})=>v.jsx("div",{className:"vbox settings-view",children:n.map(e=>{const i=`setting-${e.name.replaceAll(/\s+/g,"-")}`;return v.jsx("div",{className:`setting setting-${e.type}`,title:e.title,children:qN(e,i)},e.name)})}),qN=(n,e)=>{switch(n.type){case"check":return v.jsxs(v.Fragment,{children:[v.jsx("input",{type:"checkbox",id:e,checked:n.value,onChange:()=>n.set(!n.value)}),v.jsxs("label",{htmlFor:e,children:[n.name,!!n.count&&v.jsx("span",{className:"setting-counter",children:n.count})]})]});case"select":return v.jsxs(v.Fragment,{children:[v.jsxs("label",{htmlFor:e,children:[n.name,":",!!n.count&&v.jsx("span",{className:"setting-counter",children:n.count})]}),v.jsx("select",{id:e,value:n.value,onChange:i=>n.set(i.target.value),children:n.options.map(i=>v.jsx("option",{value:i.value,children:i.label},i.value))})]});default:return null}},FN=({showSourcesFirst:n,rootDir:e,fallbackLocation:i,isLive:s,hideTimeline:a,status:o,annotations:u,inert:f,onOpenExternally:d,revealSource:p,testRunMetadata:m})=>{var Ei;const y=U.useContext(Xn),[b,w]=U.useState(void 0),[E,x]=U.useState(void 0),[_,k]=U.useState(void 0),[C,V]=U.useState(),[I,B]=U.useState(),[G,J]=U.useState(),[$,R]=U.useState("actions"),[ee,re]=xn("propertiesTab",n?"source":"call"),[j,F]=U.useState(!1),[ge,me]=U.useState({lastEdited:"none"}),[q,Z]=U.useState(),[ne,Se]=xn("propertiesSidebarLocation","bottom"),[N]=xn("actionsFilter",[]),X=U.useCallback(le=>{w(le==null?void 0:le.callId),x(void 0)},[]),Q=U.useMemo(()=>y==null?void 0:y.filteredActions(N),[y,N]),W=((y==null?void 0:y.actions.length)??0)-((Q==null?void 0:Q.length)??0),se=U.useMemo(()=>Q==null?void 0:Q.find(le=>le.callId===C),[Q,C]),ve=U.useCallback(le=>{V(le==null?void 0:le.callId)},[]),ue=U.useMemo(()=>(y==null?void 0:y.sources)||new Map,[y]);U.useEffect(()=>{Z(void 0),x(void 0)},[y]);const We=U.useMemo(()=>{if(b){const dt=Q==null?void 0:Q.find(At=>At.callId===b);if(dt)return dt}const le=y==null?void 0:y.failedAction();if(le)return le;if(Q!=null&&Q.length){let dt=Q.length-1;for(let At=0;At<Q.length;++At)if(Q[At].title==="After Hooks"&&At){dt=At-1;break}return Q[dt]}},[y,Q,b]),xe=U.useMemo(()=>se||We,[We,se]),gn=U.useMemo(()=>E?E.stack:xe==null?void 0:xe.stack,[xe,E]),rs=U.useCallback(le=>{X(le),ve(void 0)},[X,ve]),ht=U.useCallback(le=>{re(le),le!=="inspector"&&F(!1)},[re]),as=U.useCallback(le=>{!j&&le&&ht("inspector"),F(le)},[F,ht,j]),_r=U.useCallback(le=>{me(le),ht("inspector")},[ht]),Tr=U.useCallback(le=>{ht("attachments"),k(dt=>{if(!dt)return[le,0];const At=dt[1];return[le,At+1]})},[ht]);U.useEffect(()=>{p&&ht("source")},[p,ht]);const Er=x_(y,q),rl=X_(y,q),Ht=y_(y),Pn=(y==null?void 0:y.sdkLanguage)||"javascript",al={id:"inspector",title:"Locator",render:()=>v.jsx(BN,{sdkLanguage:Pn,isInspecting:j,setIsInspecting:as,highlightedElement:ge,setHighlightedElement:me})},ll={id:"call",title:"Call",render:()=>v.jsx(Ux,{action:xe,startTimeOffset:(y==null?void 0:y.startTime)??0,sdkLanguage:Pn})},ls={id:"log",title:"Log",render:()=>v.jsx(qx,{action:xe,isLive:s})},Tc={id:"errors",title:"Errors",errorCount:Ht.errors.size,render:()=>v.jsx(v_,{errorsModel:Ht,testRunMetadata:m,sdkLanguage:Pn,revealInSource:le=>{le.action?X(le.action):x(le),ht("source")},wallTime:(y==null?void 0:y.wallTime)??0})};let Ar;!We&&i&&(Ar=(Ei=i.source)==null?void 0:Ei.errors.length);const Nr={id:"source",title:"Source",errorCount:Ar,render:()=>v.jsx(p_,{stack:gn,sources:ue,rootDir:e,stackFrameLocation:ne==="bottom"?"right":"bottom",fallbackLocation:i,onOpenExternally:d})},Ec={id:"console",title:"Console",count:Er.entries.length,render:()=>v.jsx(__,{consoleModel:Er,boundaries:rt,selectedTime:q,onAccepted:le=>Z({minimum:le.timestamp,maximum:le.timestamp}),onEntryHovered:J})},Ti={id:"network",title:"Network",count:rl.resources.length,render:()=>v.jsx(P_,{boundaries:rt,networkModel:rl,onEntryHovered:B,sdkLanguage:(y==null?void 0:y.sdkLanguage)??"javascript"})},vt={id:"attachments",title:"Attachments",count:y==null?void 0:y.visibleAttachments.length,render:()=>v.jsx(r_,{revealedAttachment:_})},Et=[al,ll,ls,Tc,Ec,Ti,Nr,vt];if(u!==void 0){const le={id:"annotations",title:"Annotations",count:u.length,render:()=>v.jsx(DN,{annotations:u})};Et.push(le)}if(n){const le=Et.indexOf(Nr);Et.splice(le,1),Et.splice(1,0,Nr)}const{boundaries:rt}=U.useMemo(()=>{const le={minimum:(y==null?void 0:y.startTime)||0,maximum:(y==null?void 0:y.endTime)||3e4};return le.minimum>le.maximum&&(le.minimum=0,le.maximum=3e4),le.maximum+=(le.maximum-le.minimum)/20,{boundaries:le}},[y]);let os=0;!s&&y&&y.endTime>=0?os=y.endTime-y.startTime:y&&y.wallTime&&(os=Date.now()-y.wallTime);const Ac={id:"actions",title:"Actions",component:v.jsxs("div",{className:"vbox",children:[o&&v.jsxs("div",{className:"workbench-run-status",children:[v.jsx("span",{className:Ke("codicon",Z0(o))}),v.jsx("div",{children:Lx(o)}),v.jsx("div",{className:"spacer"}),v.jsx("div",{className:"workbench-run-duration",children:os?_t(os):""})]}),v.jsx(Bx,{sdkLanguage:Pn,actions:Q||[],selectedAction:y?We:void 0,selectedTime:q,setSelectedTime:Z,onSelected:rs,onHighlighted:ve,revealAttachment:Tr,revealConsole:()=>ht("console"),isLive:s}),v.jsxs("div",{className:"workbench-actions-status-bar",children:[!!W&&v.jsxs("span",{className:"workbench-actions-hidden-count",title:W+" actions hidden by filters",children:[W," hidden"]}),v.jsx($N,{counters:y==null?void 0:y.actionCounters})]})]})},Nc={id:"metadata",title:"Metadata",component:v.jsx(LN,{model:y})};return v.jsxs("div",{className:"vbox workbench",...f?{inert:!0}:{},children:[!a&&v.jsx(ON,{model:y,consoleEntries:Er.entries,boundaries:rt,highlightedAction:se,highlightedEntry:I,highlightedConsoleEntry:G,onSelected:rs,sdkLanguage:Pn,selectedTime:q,setSelectedTime:Z}),v.jsx(Vo,{sidebarSize:250,orientation:ne==="bottom"?"vertical":"horizontal",settingName:"propertiesSidebar",main:v.jsx(Vo,{sidebarSize:250,orientation:"horizontal",sidebarIsFirst:!0,settingName:"actionListSidebar",main:v.jsx(SN,{action:xe,model:y,sdkLanguage:Pn,testIdAttributeName:(y==null?void 0:y.testIdAttributeName)||"data-testid",isInspecting:j,setIsInspecting:as,highlightedElement:ge,setHighlightedElement:_r}),sidebar:v.jsx(gh,{tabs:[Ac,Nc],selectedTab:$,setSelectedTab:R})}),sidebar:v.jsx(gh,{tabs:Et,selectedTab:ee,setSelectedTab:ht,rightToolbar:[ne==="bottom"?v.jsx(zt,{title:"Dock to right",icon:"layout-sidebar-right-off",onClick:()=>{Se("right")}}):v.jsx(zt,{title:"Dock to bottom",icon:"layout-panel-off",onClick:()=>{Se("bottom")}})],mode:ne==="bottom"?"default":"select"})})]})},$N=({counters:n})=>{const[e,i]=xn("actionsFilter",[]);return v.jsx(HN,{icon:"filter",title:"Filter actions",dialogDataTestId:"actions-filter-dialog",children:v.jsx(uS,{settings:[{type:"check",value:e.includes("getter"),set:s=>i(s?[...e,"getter"]:e.filter(a=>a!=="getter")),name:"Getters",count:n==null?void 0:n.get("getter")},{type:"check",value:e.includes("route"),set:s=>i(s?[...e,"route"]:e.filter(a=>a!=="route")),name:"Network routes",count:n==null?void 0:n.get("route")},{type:"check",value:e.includes("configuration"),set:s=>i(s?[...e,"configuration"]:e.filter(a=>a!=="configuration")),name:"Configuration",count:n==null?void 0:n.get("configuration")}]})})};var b0;(n=>{function e(i){for(const s of i.splice(0))s.dispose()}n.disposeAll=e})(b0||(b0={}));class ja{constructor(){this._listeners=new Set,this.event=(e,i)=>{this._listeners.add(e);let s=!1;const a=this,o={dispose(){s||(s=!0,a._listeners.delete(e))}};return i&&i.push(o),o}}fire(e){const i=!this._deliveryQueue;this._deliveryQueue||(this._deliveryQueue=[]);for(const s of this._listeners)this._deliveryQueue.push({listener:s,event:e});if(i){for(let s=0;s<this._deliveryQueue.length;s++){const{listener:a,event:o}=this._deliveryQueue[s];a.call(null,o)}this._deliveryQueue=void 0}}dispose(){this._listeners.clear(),this._deliveryQueue&&(this._deliveryQueue=[])}}class QN{constructor(e){this._ws=new WebSocket(e)}onmessage(e){this._ws.addEventListener("message",i=>e(i.data.toString()))}onopen(e){this._ws.addEventListener("open",e)}onerror(e){this._ws.addEventListener("error",e)}onclose(e){this._ws.addEventListener("close",e)}send(e){this._ws.send(e)}close(){this._ws.close()}}class ZN{constructor(e){this._onCloseEmitter=new ja,this._onReportEmitter=new ja,this._onStdioEmitter=new ja,this._onTestFilesChangedEmitter=new ja,this._onLoadTraceRequestedEmitter=new ja,this._lastId=0,this._callbacks=new Map,this._isClosed=!1,this.onClose=this._onCloseEmitter.event,this.onReport=this._onReportEmitter.event,this.onStdio=this._onStdioEmitter.event,this.onTestFilesChanged=this._onTestFilesChangedEmitter.event,this.onLoadTraceRequested=this._onLoadTraceRequestedEmitter.event,this._transport=e,this._transport.onmessage(s=>{const a=JSON.parse(s),{id:o,result:u,error:f,method:d,params:p}=a;if(o){const m=this._callbacks.get(o);if(!m)return;this._callbacks.delete(o),f?m.reject(new Error(f)):m.resolve(u)}else this._dispatchEvent(d,p)});const i=setInterval(()=>this._sendMessage("ping").catch(()=>{}),3e4);this._connectedPromise=new Promise((s,a)=>{this._transport.onopen(s),this._transport.onerror(a)}),this._transport.onclose(()=>{this._isClosed=!0,this._onCloseEmitter.fire(),clearInterval(i)})}isClosed(){return this._isClosed}async _sendMessage(e,i){const s=globalThis.__logForTest;s==null||s({method:e,params:i}),await this._connectedPromise;const a=++this._lastId,o={id:a,method:e,params:i};return this._transport.send(JSON.stringify(o)),new Promise((u,f)=>{this._callbacks.set(a,{resolve:u,reject:f})})}_sendMessageNoReply(e,i){this._sendMessage(e,i).catch(()=>{})}_dispatchEvent(e,i){e==="report"?this._onReportEmitter.fire(i):e==="stdio"?this._onStdioEmitter.fire(i):e==="testFilesChanged"?this._onTestFilesChangedEmitter.fire(i):e==="loadTraceRequested"&&this._onLoadTraceRequestedEmitter.fire(i)}async initialize(e){await this._sendMessage("initialize",e)}async ping(e){await this._sendMessage("ping",e)}async pingNoReply(e){this._sendMessageNoReply("ping",e)}async watch(e){await this._sendMessage("watch",e)}watchNoReply(e){this._sendMessageNoReply("watch",e)}async open(e){await this._sendMessage("open",e)}openNoReply(e){this._sendMessageNoReply("open",e)}async resizeTerminal(e){await this._sendMessage("resizeTerminal",e)}resizeTerminalNoReply(e){this._sendMessageNoReply("resizeTerminal",e)}async checkBrowsers(e){return await this._sendMessage("checkBrowsers",e)}async installBrowsers(e){await this._sendMessage("installBrowsers",e)}async runGlobalSetup(e){return await this._sendMessage("runGlobalSetup",e)}async runGlobalTeardown(e){return await this._sendMessage("runGlobalTeardown",e)}async startDevServer(e){return await this._sendMessage("startDevServer",e)}async stopDevServer(e){return await this._sendMessage("stopDevServer",e)}async clearCache(e){return await this._sendMessage("clearCache",e)}async listFiles(e){return await this._sendMessage("listFiles",e)}async listTests(e){return await this._sendMessage("listTests",e)}async runTests(e){return await this._sendMessage("runTests",e)}async findRelatedTestFiles(e){return await this._sendMessage("findRelatedTestFiles",e)}async stopTests(e){await this._sendMessage("stopTests",e)}stopTestsNoReply(e){this._sendMessageNoReply("stopTests",e)}async closeGracefully(e){await this._sendMessage("closeGracefully",e)}close(){try{this._transport.close()}catch{}}}const JN=()=>{const[n,e]=xn("shouldPopulateCanvasFromScreenshot",!1),[i,s]=Lw(),[a,o]=xn("mergeFiles",!1);return v.jsx(uS,{settings:[{type:"check",value:i,set:s,name:"Dark mode"},{type:"check",value:a,set:o,name:"Merge files"},{type:"check",value:n,set:e,name:"Display canvas content",title:"Attempt to display the captured canvas appearance in the snapshot preview. May not be accurate."}]})};export{HN as D,n_ as E,XN as M,Ut as R,Vo as S,ZN as T,QN as W,Fx as _,JN as a,Xn as b,FN as c,UN as d,VN as e,YN as f,fh as g,GN as h,KN as i,v as j,Ke as k,Rx as l,_t as m,Uh as n,zt as o,xn as p,uS as q,U as r,Yi as s,Z0 as t,ts as u,Aw as v};
|