@reticlehq/browser 3.8.2 → 3.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,46 +1,46 @@
1
- "use strict";var ReticleSdk=(()=>{var Zg=Object.defineProperty;var x5=Object.getOwnPropertyDescriptor;var A5=Object.getOwnPropertyNames;var y5=Object.prototype.hasOwnProperty;var EA=e=>{throw TypeError(e)};var y=(e,t,n)=>()=>{if(n)throw n[0];try{return e&&(t=e(e=0)),t}catch(r){throw n=[r],r}};var Ya=(e,t)=>{for(var n in t)Zg(e,n,{get:t[n],enumerable:!0})},w5=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of A5(t))!y5.call(e,o)&&o!==n&&Zg(e,o,{get:()=>t[o],enumerable:!(r=x5(t,o))||r.enumerable});return e};var v5=e=>w5(Zg({},"__esModule",{value:!0}),e);var Wg=(e,t,n)=>t.has(e)||EA("Cannot "+n);var c=(e,t,n)=>(Wg(e,t,"read from private field"),n?n.call(e):t.get(e)),x=(e,t,n)=>t.has(e)?EA("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),g=(e,t,n,r)=>(Wg(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),T=(e,t,n)=>(Wg(e,t,"access private method"),n);var bA=(e,t,n,r)=>({set _(o){g(e,t,o,n)},get _(){return c(e,t,r)}});var _A=y(()=>{"use strict"});var ne={};Ya(ne,{BIGINT_FORMAT_RANGES:()=>tf,CONSTANT_CATCH:()=>OA,Class:()=>qg,NUMBER_FORMAT_RANGES:()=>hu,aborted:()=>zn,allowsEval:()=>rE,assert:()=>L5,assertEqual:()=>N5,assertIs:()=>I5,assertNever:()=>C5,assertNotEqual:()=>R5,assignProp:()=>kn,attachSchema:()=>mu,base64ToUint8Array:()=>NA,base64urlToUint8Array:()=>q5,cached:()=>Qa,captureStackTrace:()=>Qp,cleanEnum:()=>X5,cleanRegex:()=>fu,clone:()=>Rr,cloneDef:()=>z5,codePointLength:()=>gu,constantCatch:()=>IA,createTransparentProxy:()=>F5,defineLazy:()=>eE,defineLazyInternal:()=>_e,derived:()=>tU,esc:()=>tE,escapeRegex:()=>Bo,explicitlyAborted:()=>sE,extend:()=>V5,finalizeIssue:()=>Ir,floatSafeRemainder:()=>Qg,getElementAtPath:()=>D5,getEnumValues:()=>qa,getLengthableOrigin:()=>Eu,getParsedType:()=>H5,getSizableOrigin:()=>vA,hexToUint8Array:()=>Q5,hide:()=>of,installLazyProp:()=>iU,isObject:()=>Cs,isPlainObject:()=>Ii,issue:()=>tc,joinValues:()=>Jp,jsonStringifyReplacer:()=>Ja,members:()=>cE,merge:()=>K5,mergeDefs:()=>Fo,normalizeParams:()=>te,nullish:()=>Jg,numKeys:()=>U5,objectClone:()=>$5,omit:()=>G5,optionalKeys:()=>iE,own:()=>Oi,parsedType:()=>aE,partial:()=>Z5,pick:()=>B5,prefixIssues:()=>Or,primitiveTypes:()=>yA,promiseAllObject:()=>P5,propertyKeyTypes:()=>oE,randomString:()=>M5,rawShape:()=>ec,required:()=>W5,safeExtend:()=>j5,shallowClone:()=>AA,sizeCaps:()=>rf,slugify:()=>nE,stringifyPrimitive:()=>ef,toZod:()=>O5,uint8ArrayToBase64:()=>RA,uint8ArrayToBase64url:()=>J5,uint8ArrayToHex:()=>eU,unwrapMessage:()=>Xa});function N5(e){return e}function R5(e){return e}function O5(){return e=>e}function I5(e){}function C5(e){throw new Error("Unexpected value in exhaustive check")}function L5(e){}function qa(e){let t=Object.values(e).filter(r=>typeof r=="number");return Object.entries(e).filter(([r,o])=>t.indexOf(+r)===-1).map(([r,o])=>o)}function Jp(e,t="|"){return e.map(n=>ef(n)).join(t)}function Ja(e,t){return typeof t=="bigint"?t.toString():t}function Qa(e){return new Xg(e)}function Jg(e){return e==null}function fu(e){let t=e.startsWith("^")?1:0,n=e.endsWith("$")?e.length-1:e.length;return e.slice(t,n)}function Qg(e,t){let n=e/t,r=Math.round(n),o=4*Number.EPSILON*Math.max(Math.abs(n),1);return Math.abs(n-r)<o?0:n-r}function eE(e,t,n){let r;Object.defineProperty(e,t,{get(){if(r!==SA)return r===void 0&&(r=SA,r=n()),r},set(o){Object.defineProperty(e,t,{value:o})},configurable:!0})}function $5(e){return Object.create(Object.getPrototypeOf(e),Object.getOwnPropertyDescriptors(e))}function kn(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function ec(e){let t=Object.getOwnPropertyDescriptor(e,"shape");return t!=null&&t.get?t.get.raw:t==null?void 0:t.value}function Ho(e){var t;return(t=ec(e._zod.def))!=null?t:e._zod.def.shape}function TA(e,t,n){Object.defineProperty(e,t,{get(){let r=n();return kn(this,t,r),r},enumerable:!0,configurable:!0})}function xA(e,t,n){t in e?kn(e,t,n):e[t]=n}function Is(e,t,n,r){let o=Ho(t);for(let i of n){let s=Object.getOwnPropertyDescriptor(o,i);s.enumerable&&(s.get?TA(e,i,()=>{let a=t._zod.def.shape[i];return r?r(a,i):a}):xA(e,i,r?r(s.value,i):s.value))}}function k5(e,t){for(let n of Reflect.ownKeys(t)){let r=Object.getOwnPropertyDescriptor(t,n);r.enumerable&&(r.get?TA(e,n,()=>t[n]):xA(e,n,r.value))}}function Fo(...e){let t={};for(let n of e){let r=Object.getOwnPropertyDescriptors(n);Object.assign(t,r)}return Object.defineProperties({},t)}function z5(e){return Fo(e._zod.def)}function D5(e,t){return t?t.reduce((n,r)=>n==null?void 0:n[r],e):e}function P5(e){let t=Object.keys(e),n=t.map(r=>e[r]);return Promise.all(n).then(r=>{let o={};for(let i=0;i<t.length;i++)o[t[i]]=r[i];return o})}function M5(e=10){let t="abcdefghijklmnopqrstuvwxyz",n="";for(let r=0;r<e;r++)n+=t[Math.floor(Math.random()*t.length)];return n}function tE(e){return JSON.stringify(e)}function nE(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}function Cs(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function Ii(e){if(Cs(e)===!1)return!1;let t=e.constructor;if(t===void 0||typeof t!="function")return!0;let n=t.prototype;return!(Cs(n)===!1||Object.prototype.hasOwnProperty.call(n,"isPrototypeOf")===!1)}function AA(e){return Ii(e)?{...e}:Array.isArray(e)?[...e]:e instanceof Map?new Map(e):e instanceof Set?new Set(e):e}function U5(e){let t=0;for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&t++;return t}function Bo(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Rr(e,t,n){let r=new e._zod.constr(t!=null?t:e._zod.def);return(!t||n!=null&&n.parent)&&(r._zod.parent=e),r}function te(e){let t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if((t==null?void 0:t.message)!==void 0){if((t==null?void 0:t.error)!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function F5(e){let t;return new Proxy({},{get(n,r,o){return t!=null||(t=e()),Reflect.get(t,r,o)},set(n,r,o,i){return t!=null||(t=e()),Reflect.set(t,r,o,i)},has(n,r){return t!=null||(t=e()),Reflect.has(t,r)},deleteProperty(n,r){return t!=null||(t=e()),Reflect.deleteProperty(t,r)},ownKeys(n){return t!=null||(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(n,r){return t!=null||(t=e()),Reflect.getOwnPropertyDescriptor(t,r)},defineProperty(n,r,o){return t!=null||(t=e()),Reflect.defineProperty(t,r,o)}})}function ef(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function iE(e){return Object.keys(e).filter(t=>e[t]._zod.optin!==void 0&&e[t]._zod.optout==="optional")}function B5(e,t){let n=e._zod.def,r=n.checks;if(r&&r.length>0)throw new Error(".pick() cannot be used on object schemas containing refinements");let i={};return Is(i,e,nf(e,t)),Rr(e,Fo(n,{shape:i,checks:[]}))}function nf(e,t){var o;let n=Ho(e),r=[];for(let i of Reflect.ownKeys(t)){if(!((o=Object.getOwnPropertyDescriptor(n,i))!=null&&o.enumerable))throw new Error(`Unrecognized key: "${String(i)}"`);t[i]&&r.push(i)}return r}function G5(e,t){let n=e._zod.def,r=n.checks;if(r&&r.length>0)throw new Error(".omit() cannot be used on object schemas containing refinements");let i=new Set(nf(e,t)),s={};return Is(s,e,Reflect.ownKeys(Ho(e)).filter(a=>!i.has(a))),Rr(e,Fo(n,{shape:s,checks:[]}))}function V5(e,t){if(!Ii(t))throw new Error("Invalid input to extend: expected a plain object");let n=e._zod.def.checks;if(n&&n.length>0){let o=Ho(e);for(let i of Reflect.ownKeys(t))if(Object.getOwnPropertyDescriptor(o,i)!==void 0)throw new Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}return Rr(e,Fo(e._zod.def,{shape:wA(e,t)}))}function wA(e,t){let n={};return Is(n,e,Reflect.ownKeys(Ho(e))),k5(n,t),n}function j5(e,t){if(!Ii(t))throw new Error("Invalid input to safeExtend: expected a plain object");return Rr(e,Fo(e._zod.def,{shape:wA(e,t)}))}function K5(e,t){var o,i,s;if(!((o=t==null?void 0:t._zod)!=null&&o.def))throw new Error("Invalid input to merge: expected an object schema. To merge a plain shape, use `.extend()`.");if((i=e._zod.def.checks)!=null&&i.length)throw new Error(".merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.");let n={};Is(n,e,Reflect.ownKeys(Ho(e))),Is(n,t,Reflect.ownKeys(Ho(t)));let r=Fo(e._zod.def,{shape:n,get catchall(){return t._zod.def.catchall},checks:(s=t._zod.def.checks)!=null?s:[]});return Rr(e,r)}function Z5(e,t,n,r="partial"){let i=t._zod.def.checks;if(i&&i.length>0)throw new Error(`.${r}() cannot be used on object schemas containing refinements`);let a=n?new Set(nf(t,n)):void 0,l={};return Is(l,t,Reflect.ownKeys(Ho(t)),e&&((u,d)=>a&&!a.has(d)?u:new e({type:"optional",innerType:u}))),Rr(t,Fo(t._zod.def,{shape:l,checks:[]}))}function W5(e,t,n){let r=n?new Set(nf(t,n)):void 0,o={};return Is(o,t,Reflect.ownKeys(Ho(t)),(i,s)=>r&&!r.has(s)?i:new e({type:"nonoptional",innerType:i})),Rr(t,Fo(t._zod.def,{shape:o}))}function zn(e,t=0){var n;if(e.aborted===!0)return!0;for(let r=t;r<e.issues.length;r++)if(((n=e.issues[r])==null?void 0:n.continue)!==!0)return!0;return!1}function sE(e,t=0){var n;if(e.aborted===!0)return!0;for(let r=t;r<e.issues.length;r++)if(((n=e.issues[r])==null?void 0:n.continue)===!1)return!0;return!1}function Or(e,t){return t.map(n=>{var o;var r;return(o=(r=n).path)!=null||(r.path=[]),n.path.unshift(e),n})}function Xa(e){return typeof e=="string"?e:e==null?void 0:e.message}function rf(e){var n,r;let t=[];for(let o of e!=null?e:[]){let i=o._zod.def;if(!/_(length|size)$|_equals$/.test(i.check))break;let s=(r=(n=i.maximum)!=null?n:i.length)!=null?r:i.size;s>=0&&t.push([s,o])}return t}function mu(e,t,n){var o;var r;for(let i=t;i<e.length;i++)(o=(r=e[i]).schema)!=null||(r.schema=n)}function Ir(e,t,n){var l,u,d,f,m,h,E,_,A,v,N,O,k,j,Y,X,G;var r;let o=(u=(l=e.inst)==null?void 0:l._zod)==null?void 0:u.traits;o!=null&&o.has("$ZodType")&&(o.has("$ZodCheck")?(d=(r=e).schema)!=null||(r.schema=e.inst):e.schema=e.inst);let i=e.schema!==e.inst?(m=(f=e.schema)==null?void 0:f._zod.def)==null?void 0:m.error:void 0,s=e.message?e.message:(X=(Y=(k=(N=(A=Xa((_=(E=(h=e.inst)==null?void 0:h._zod.def)==null?void 0:E.error)==null?void 0:_.call(E,e)))!=null?A:Xa(i==null?void 0:i(e)))!=null?N:Xa((v=t==null?void 0:t.error)==null?void 0:v.call(t,e)))!=null?k:Xa((O=n.customError)==null?void 0:O.call(n,e)))!=null?Y:Xa((j=n.localeError)==null?void 0:j.call(n,e)))!=null?X:"Invalid input",a={};for(let ee of Object.keys(e))ee==="inst"||ee==="schema"||ee==="continue"||ee==="input"||ee==="__proto__"||(a[ee]=e[ee]);return(G=a.path)!=null||(a.path=[]),a.message=s,t!=null&&t.reportInput&&(a.input=e.input),a}function vA(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function gu(e){let t=e.length;if(!Y5.test(e))return t;let n=t;for(let r=0;r<t-1;r++)(e.charCodeAt(r)&64512)===55296&&(e.charCodeAt(r+1)&64512)===56320&&(n--,r++);return n}function Eu(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function aE(e){let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"nan":"number";case"object":{if(e===null)return"null";if(Array.isArray(e))return"array";let n=e;if(n&&Object.getPrototypeOf(n)!==Object.prototype&&"constructor"in n&&n.constructor)return n.constructor.name}}return t}function tc(...e){let[t,n,r]=e;return typeof t=="string"?{message:t,code:"custom",input:n,inst:r}:{...t}}function X5(e){return Object.entries(e).filter(([t,n])=>Number.isNaN(Number.parseInt(t,10))).map(t=>t[1])}function NA(e){let t=atob(e),n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=t.charCodeAt(r);return n}function RA(e){let t="";for(let n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return btoa(t)}function q5(e){let t=e.replace(/-/g,"+").replace(/_/g,"/"),n="=".repeat((4-t.length%4)%4);return NA(t+n)}function J5(e){return RA(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function Q5(e){let t=e.replace(/^0x/,"");if(t.length%2!==0)throw new Error("Invalid hex string length");let n=new Uint8Array(t.length/2);for(let r=0;r<t.length;r+=2)n[r/2]=Number.parseInt(t.slice(r,r+2),16);return n}function eU(e){return Array.from(e).map(t=>t.toString(16).padStart(2,"0")).join("")}function cE(e,t){for(let n in t){let r=Object.getOwnPropertyDescriptor(t,n);r.get?Object.defineProperty(e,n,{...r,enumerable:!1}):nU(e,n,r.value)}}function Oi(e,t,n,r=!0){return Object.defineProperty(e,t,{configurable:!0,writable:!0,enumerable:r,value:n}),n}function of(e,t,n){return Oi(e,t,n,!1)}function tU(e,t){for(let n in e){let r=e[n];Object.defineProperty(t,n,{configurable:!0,enumerable:!0,get(){return Oi(this,n,r(this))},set(o){Oi(this,n,o)}})}return t}function nU(e,t,n){Object.defineProperty(e,t,{configurable:!0,get(){return this==null?n:Oi(this,t,n.bind(this))},set(r){Oi(this,t,r)}})}function rU(e,t){let n=Object.getPrototypeOf(e);return t in n?void 0:n}function _e(e,t,n){let r=Object.getPrototypeOf(e._zod);if(t in r&&Yg!==e._zod){Yg=void 0;return}Yg=e._zod,Object.defineProperty(r,t,{configurable:!0,get(){Object.defineProperty(this,t,oU);let o=Ri;Ri=!1;try{let i=n(this);return Ri?delete this[t]:Object.defineProperty(this,t,{configurable:!0,writable:!0,value:i}),Ri=Ri||o,i}catch(i){throw delete this[t],Ri=Ri||o,i}},set(o){Object.defineProperty(this,t,{configurable:!0,writable:!0,value:o})}})}function iU(e,t,n,r){let o=rU(e,t);o&&Object.defineProperty(o,t,{configurable:!0,get(){let i={configurable:!0,writable:!0,enumerable:r,value:void 0};return Object.defineProperty(this,t,i),i.value=n(this),Object.defineProperty(this,t,i),i.value},set(i){Object.defineProperty(this,t,{configurable:!0,writable:!0,enumerable:r,value:i})}})}function IA(e){let t=()=>e;return t[OA]=!0,t}var Xg,SA,Qp,rE,H5,oE,yA,hu,tf,Y5,qg,Yg,Ri,oU,OA,Sn=y(()=>{Ls();Xg=class{constructor(t){this._getter=t,this._value=void 0}get value(){let t=this._getter;return t!==void 0&&(this._value=t(),this._getter=void 0),this._value}};SA=Symbol("evaluating");Qp="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};rE=Qa(()=>{var e;if(nn.jitless||typeof navigator!="undefined"&&((e=navigator==null?void 0:navigator.userAgent)!=null&&e.includes("Cloudflare")))return!1;try{let t=Function;return new t(""),!0}catch{return!1}});H5=e=>{let t=typeof e;switch(t){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map!="undefined"&&e instanceof Map?"map":typeof Set!="undefined"&&e instanceof Set?"set":typeof Date!="undefined"&&e instanceof Date?"date":typeof File!="undefined"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${t}`)}},oE=new Set(["string","number","symbol"]),yA=new Set(["string","number","bigint","boolean","symbol","undefined"]);hu={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},tf={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};Y5=/[\uD800-\uDBFF]/;qg=class{constructor(...t){}};Ri=!1,oU={configurable:!0,get(){Ri=!0}};OA="~constantCatch"});function sU(e){let t=LA;if(t){let n=t.stackTraceLimit;if(typeof n=="number"){try{t.stackTraceLimit=0}catch{return LA=null,new e}try{return new e}finally{t.stackTraceLimit=n}}}return new e}function I(e,t,n,r){var m;let o={};function i(h){this.def=h,this.constr=f,this.traits=new Set}i.prototype=o;let s=n,a=s&&new WeakSet;function l(h,E){if(h._zod){if(h._zod.traits.has(e))return}else{lE.value=new i(E);try{Object.defineProperty(h,"_zod",lE)}finally{lE.value=void 0}}if(h._zod.traits.add(e),t(h,E),a){let A=Object.getPrototypeOf(h),v=h._zod.constr.prototype,N=A;for(;N&&N!==v;)N=Object.getPrototypeOf(N);let O=N!=null?N:A;a.has(O)||(a.add(O),cE(O,s))}let _=f.prototype;for(let A in _)Object.prototype.hasOwnProperty.call(_,A)&&(A in h||(h[A]=_[A].bind(h)))}let u=(m=r==null?void 0:r.Parent)!=null?m:Object;class d extends u{}Object.defineProperty(d,"name",{value:e});function f(h){var v;let E=r!=null&&r.Parent?sU(d):this;l(E,h);let _=E._zod.deferred;if(_){for(let N of _)N();E._zod.deferred=void 0}let A=(v=globalThis.__zod_globalConfig)==null?void 0:v.postProcessor;return A&&A(E),E}return Object.defineProperty(f,"init",{value:l}),Object.defineProperty(f,Symbol.hasInstance,{value:h=>{var E,_;return r!=null&&r.Parent&&h instanceof r.Parent?!0:(_=(E=h==null?void 0:h._zod)==null?void 0:E.traits)==null?void 0:_.has(e)}}),Object.defineProperty(f,"name",{value:e}),f}function Dn(e){return e&&Object.assign(nn,e),nn}var CA,lE,LA,Cr,nc,$A,nn,Ls=y(()=>{Sn();lE={value:void 0,enumerable:!1},LA="captureStackTrace"in Error?Error:null;Cr=class extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},nc=class extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}};($A=(CA=globalThis).__zod_globalConfig)!=null||(CA.__zod_globalConfig={});nn=globalThis.__zod_globalConfig});function aU(){var t;let e=this._zod;return(t=e.message)!=null||(e.message=JSON.stringify(e.def,Ja,2)),e.message}function cU(e){this._zod.message=e}function uU(e,t,n){return Object.prototype.hasOwnProperty.call(e,t)||(t==="__proto__"?Object.defineProperty(e,t,{value:n(),writable:!0,enumerable:!0,configurable:!0}):e[t]=n()),e[t]}function PA(e,t=n=>n.message){let n={},r=[];for(let o of e.issues)o.path.length>0?uU(n,o.path[0],()=>[]).push(t(o)):r.push(t(o));return{formErrors:r,fieldErrors:n}}function MA(e,t=n=>n.message){let n={_errors:[]},r=(o,i=[])=>{for(let s of o.issues)if(s.code==="invalid_union"&&s.errors.length)s.errors.map(a=>r({issues:a},[...i,...s.path]));else if(s.code==="invalid_key")r({issues:s.issues},[...i,...s.path]);else if(s.code==="invalid_element")r({issues:s.issues},[...i,...s.path]);else{let a=[...i,...s.path];if(a.length===0)n._errors.push(t(s));else{let l=n,u=0;for(;u<a.length;){let d=a[u],f=u===a.length-1;if(d==="_errors"){f&&l._errors.push(t(s)),u++;continue}Object.prototype.hasOwnProperty.call(l,d)||Object.defineProperty(l,d,{value:{_errors:[]},enumerable:!0,writable:!0,configurable:!0});let m=l[d];f&&m._errors.push(t(s)),l=m,u++}}}};return r(e),n}var lU,dE,kA,zA,DA,aY,UA=y(()=>{Ls();Sn();lU={get:aU,set:cU,enumerable:!0,configurable:!0},dE={value:void 0,enumerable:!1},kA=new WeakSet([Object.prototype,Error.prototype]),zA=(e,t)=>{e.name="$ZodError",dE.value=t,Object.defineProperty(e,"issues",dE),dE.value=void 0,Object.defineProperty(e,"message",lU);let n=Object.getPrototypeOf(e);kA.has(n)||(kA.add(n),Object.defineProperty(n,"toString",{configurable:!0,enumerable:!1,get(){let r=()=>this.message;return Object.defineProperty(this,"toString",{value:r,configurable:!0,writable:!0}),r},set(r){Object.defineProperty(this,"toString",{value:r,configurable:!0,writable:!0})}}))},DA=I("$ZodError",zA),aY=I("$ZodError",zA,void 0,{Parent:Error})});function sf(e,t){var n;return{callee:(n=t==null?void 0:t.callee)!=null?n:e,Err:t==null?void 0:t.Err}}function HA(e,t,n){let r;return{success:!1,get error(){return r||(r=new e(t.map(o=>Ir(o,n,Dn()))),t=void 0,n=void 0),r},set error(o){r=o,t=void 0,n=void 0}}}function fU(e,t,n){let r=n?{...n,async:!1,abortEarly:!0}:{async:!1,abortEarly:!0},o=e._zod.bag.fallbackRun,i;if(o?(r[pU]=!0,i=o({value:t,issues:[]},r)):i=e._zod.run({value:t,issues:[]},r),i instanceof Promise)throw new Cr;return i.issues.length===0}var af,cf,lf,uf,dU,pU,pE,fE,FA,BA,GA,VA,jA,KA,ZA,WA,YA=y(()=>{Ls();Sn();af=e=>{let t=(n,r,o,i)=>{var l,u;let s=o?{...o,async:!1}:{async:!1},a=n._zod.run({value:r,issues:[]},s);if(a instanceof Promise)throw new Cr;if(a.issues.length){let d=new((l=i==null?void 0:i.Err)!=null?l:e)(a.issues.map(f=>Ir(f,s,Dn())));throw Qp(d,(u=i==null?void 0:i.callee)!=null?u:t),d}return a.value};return t},cf=e=>{let t=async(n,r,o,i)=>{var l,u;let s=o?{...o,async:!0}:{async:!0},a=n._zod.run({value:r,issues:[]},s);if(a instanceof Promise&&(a=await a),a.issues.length){let d=new((l=i==null?void 0:i.Err)!=null?l:e)(a.issues.map(f=>Ir(f,s,Dn())));throw Qp(d,(u=i==null?void 0:i.callee)!=null?u:t),d}return a.value};return t},lf=e=>(t,n,r)=>{let o=r?{...r,async:!1}:{async:!1},i=t._zod.run({value:n,issues:[]},o);if(i instanceof Promise)throw new Cr;return i.issues.length?HA(e,i.issues,o):{success:!0,data:i.value}};uf=e=>async(t,n,r)=>{let o=r?{...r,async:!0}:{async:!0},i=t._zod.run({value:n,issues:[]},o);return i instanceof Promise&&(i=await i),i.issues.length?HA(e,i.issues,o):{success:!0,data:i.value}},dU=Symbol.for("zod.compile.invalid"),pU=Symbol.for("zod.compile.fallback"),pE=((e,t,n)=>{let r=e._zod.bag.validator;if(r!==void 0){if(r(t)!==dU)return!0;if(r.definite===!0&&n===void 0)return!1}return fU(e,t,n)});fE=async(e,t,n)=>{let r=n?{...n,async:!0,abortEarly:!0}:{async:!0,abortEarly:!0},o=e._zod.run({value:t,issues:[]},r);return o instanceof Promise&&(o=await o),o.issues.length===0},FA=e=>{let t=af(e),n=(r,o,i,s)=>{let a=i?{...i,direction:"backward"}:{direction:"backward"};return t(r,o,a,sf(n,s))};return n},BA=e=>{let t=af(e),n=(r,o,i,s)=>t(r,o,i,sf(n,s));return n},GA=e=>{let t=cf(e),n=async(r,o,i,s)=>{let a=i?{...i,direction:"backward"}:{direction:"backward"};return await t(r,o,a,sf(n,s))};return n},VA=e=>{let t=cf(e),n=async(r,o,i,s)=>await t(r,o,i,sf(n,s));return n},jA=e=>(t,n,r)=>{let o=r?{...r,direction:"backward"}:{direction:"backward"};return lf(e)(t,n,o)},KA=e=>(t,n,r)=>lf(e)(t,n,r),ZA=e=>async(t,n,r)=>{let o=r?{...r,direction:"backward"}:{direction:"backward"};return uf(e)(t,n,o)},WA=e=>async(t,n,r)=>uf(e)(t,n,r)});function ny(e){return new RegExp(`^[a-zA-Z0-9_-]{${e}}$`)}function sy(){return new RegExp(hU,"u")}function mU(e){return new RegExp(`^${e}$`)}function hE(e){let t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:e.seconds?`${t}:[0-5]\\d(?:\\.\\d+)?`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function Ey(e){return new RegExp(`^${hE(e)}$`)}function by(e){let t=["Z"];e.offset&&t.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");let n=`${hE({precision:e.precision,seconds:!0})}(?:${t.join("|")})`,r=e.local?`${n}|${hE({precision:e.precision})}`:n;return new RegExp(`^${my}T(?:${r})$`)}var XA,qA,JA,QA,ey,ty,ry,oy,mE,iy,hU,ay,cy,ly,uy,dy,py,fy,hy,my,gy,_y,gE,bu,Sy,Ty,xy,Ay,yy,pf=y(()=>{XA=/^[cC][0-9a-z]{6,}$/,qA=/^[0-9a-z]+$/,JA=/^[0-7][0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{25}$/,QA=/^[0-9a-vA-V]{20}$/,ey=/^[A-Za-z0-9]{27}$/,ty=/^[a-zA-Z0-9_-]{21}$/;ry=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,oy=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,mE=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,iy=/^(?:[A-Za-z0-9_'+\-]+\.)*[A-Za-z0-9_'+\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,hU="^(?=[\\s\\S]*[\\p{Extended_Pictographic}\\p{Regional_Indicator}\\u20E3])[\\p{Extended_Pictographic}\\p{Emoji_Component}]+$";ay=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,cy=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,ly=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,uy=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,dy=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,py=/^(?:[A-Za-z0-9_-]{4})*(?:[A-Za-z0-9_-]{2,3})?$/,fy=/^https?$/,hy=/^\+[1-9]\d{6,14}$/,my="(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))";gy=mU(my);_y=/^[\s\S]{0,}$/,gE=/^-?\d+$/,bu=/^-?\d+(?:\.\d+)?$/,Sy=/^(?:true|false)$/i,Ty=/^null$/i,xy=/^undefined$/i,Ay=/^[^A-Z]*$/,yy=/^[^a-z]*$/});var zt,EE,ff,bE,_E,wy,vy,Ny,Ry,Oy,_u,Iy,Cy,Ly,$y,ky,zy,Dy,hf=y(()=>{Ls();pf();Sn();zt=I("$ZodCheck",(e,t)=>{var r,o;var n;(r=e._zod)!=null||(e._zod={}),e._zod.def=t,(o=(n=e._zod).onattach)!=null||(n.onattach=[])}),EE=e=>{let t=e.value;return!Jg(t)&&t.length!==void 0},ff={number:"number",bigint:"bigint",object:"date"},bE=I("$ZodCheckLessThan",(e,t)=>{zt.init(e,t);let n=ff[typeof t.value];e._zod.check=r=>{var o;(t.inclusive?r.value<=t.value:r.value<t.value)||r.issues.push({origin:(o=ff[typeof r.value])!=null?o:n,code:"too_big",maximum:typeof t.value=="object"?t.value.getTime():t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),_E=I("$ZodCheckGreaterThan",(e,t)=>{zt.init(e,t);let n=ff[typeof t.value];e._zod.check=r=>{var o;(t.inclusive?r.value>=t.value:r.value>t.value)||r.issues.push({origin:(o=ff[typeof r.value])!=null?o:n,code:"too_small",minimum:typeof t.value=="object"?t.value.getTime():t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),wy=I("$ZodCheckMultipleOf",(e,t)=>{zt.init(e,t),e._zod.check=n=>{if(typeof n.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof n.value=="bigint"?t.value!==BigInt(0)&&n.value%t.value===BigInt(0):Qg(n.value,t.value)===0)||n.issues.push({origin:typeof n.value,code:"not_multiple_of",divisor:t.value,input:n.value,inst:e,continue:!t.abort})}}),vy=I("$ZodCheckNumberFormat",(e,t)=>{var s;zt.init(e,t),t.format=t.format||"float64";let n=(s=t.format)==null?void 0:s.includes("int"),r=n?"int":"number",[o,i]=hu[t.format];e._zod.check=a=>{let l=a.value;if(n){if(!Number.isInteger(l)){a.issues.push({expected:r,format:t.format,code:"invalid_type",continue:!1,input:l,inst:e});return}if(!Number.isSafeInteger(l)){l>0?a.issues.push({input:l,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,inclusive:!0,continue:!t.abort}):a.issues.push({input:l,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,inclusive:!0,continue:!t.abort});return}}l<o&&a.issues.push({origin:"number",input:l,code:"too_small",minimum:o,inclusive:!0,inst:e,continue:!t.abort}),l>i&&a.issues.push({origin:"number",input:l,code:"too_big",maximum:i,inclusive:!0,inst:e,continue:!t.abort})}}),Ny=I("$ZodCheckMaxLength",(e,t)=>{var r;var n;zt.init(e,t),(r=(n=e._zod.def).when)!=null||(n.when=EE),e._zod.check=o=>{let i=o.value,s=i.length;if((typeof i=="string"&&s>t.maximum?gu(i):s)<=t.maximum)return;let l=Eu(i);o.issues.push({origin:l,code:"too_big",maximum:t.maximum,inclusive:!0,input:i,inst:e,continue:!t.abort})}}),Ry=I("$ZodCheckMinLength",(e,t)=>{var r;var n;zt.init(e,t),(r=(n=e._zod.def).when)!=null||(n.when=EE),e._zod.check=o=>{let i=o.value,s=i.length;if((typeof i=="string"&&s>=t.minimum&&s<t.minimum*2?gu(i):s)>=t.minimum)return;let l=Eu(i);o.issues.push({origin:l,code:"too_small",minimum:t.minimum,inclusive:!0,input:i,inst:e,continue:!t.abort})}}),Oy=I("$ZodCheckLengthEquals",(e,t)=>{var r;var n;zt.init(e,t),(r=(n=e._zod.def).when)!=null||(n.when=EE),e._zod.check=o=>{let i=o.value,s=i.length,a=typeof i=="string"&&s>=t.length&&s<=t.length*2?gu(i):s;if(a===t.length)return;let l=Eu(i),u=a>t.length;o.issues.push({origin:l,...u?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),_u=I("$ZodCheckStringFormat",(e,t)=>{var o,i;var n,r;zt.init(e,t),t.pattern?(o=(n=e._zod).check)!=null||(n.check=s=>{t.pattern.lastIndex=0,!t.pattern.test(s.value)&&s.issues.push({origin:"string",code:"invalid_format",format:t.format,input:s.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(i=(r=e._zod).check)!=null||(r.check=()=>{})}),Iy=I("$ZodCheckRegex",(e,t)=>{_u.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:"regex",input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),Cy=I("$ZodCheckLowerCase",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Ay),_u.init(e,t)}),Ly=I("$ZodCheckUpperCase",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=yy),_u.init(e,t)}),$y=I("$ZodCheckIncludes",(e,t)=>{zt.init(e,t);let n=Bo(t.includes),r=new RegExp(typeof t.position=="number"?`^.{${t.position},}${n}`:n);t.pattern=r,e._zod.check=o=>{o.value.includes(t.includes,t.position)||o.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:o.value,inst:e,continue:!t.abort})}}),ky=I("$ZodCheckStartsWith",(e,t)=>{var r;zt.init(e,t);let n=new RegExp(`^${Bo(t.prefix)}.*`);(r=t.pattern)!=null||(t.pattern=n),e._zod.check=o=>{o.value.startsWith(t.prefix)||o.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:o.value,inst:e,continue:!t.abort})}}),zy=I("$ZodCheckEndsWith",(e,t)=>{var r;zt.init(e,t);let n=new RegExp(`.*${Bo(t.suffix)}$`);(r=t.pattern)!=null||(t.pattern=n),e._zod.check=o=>{o.value.endsWith(t.suffix)||o.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:o.value,inst:e,continue:!t.abort})}}),Dy=I("$ZodCheckOverwrite",(e,t)=>{zt.init(e,t),e._zod.check=n=>{n.value=t.tx(n.value)}})});var mf,SE=y(()=>{mf=class{constructor(t=[],n={}){this.content=[],this.indent=0,this.args=t,this.closed=n}indented(t){this.indent+=1;try{t(this)}finally{this.indent-=1}}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}let r=t.split(`
1
+ "use strict";var ReticleSdk=(()=>{var Jg=Object.defineProperty;var P5=Object.getOwnPropertyDescriptor;var M5=Object.getOwnPropertyNames;var U5=Object.prototype.hasOwnProperty;var RA=e=>{throw TypeError(e)};var y=(e,t,n)=>()=>{if(n)throw n[0];try{return e&&(t=e(e=0)),t}catch(r){throw n=[r],r}};var qa=(e,t)=>{for(var n in t)Jg(e,n,{get:t[n],enumerable:!0})},H5=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of M5(t))!U5.call(e,o)&&o!==n&&Jg(e,o,{get:()=>t[o],enumerable:!(r=P5(t,o))||r.enumerable});return e};var F5=e=>H5(Jg({},"__esModule",{value:!0}),e);var Qg=(e,t,n)=>t.has(e)||RA("Cannot "+n);var c=(e,t,n)=>(Qg(e,t,"read from private field"),n?n.call(e):t.get(e)),x=(e,t,n)=>t.has(e)?RA("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),g=(e,t,n,r)=>(Qg(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),T=(e,t,n)=>(Qg(e,t,"access private method"),n);var OA=(e,t,n,r)=>({set _(o){g(e,t,o,n)},get _(){return c(e,t,r)}});var IA=y(()=>{"use strict"});var ne={};qa(ne,{BIGINT_FORMAT_RANGES:()=>sf,CONSTANT_CATCH:()=>HA,Class:()=>nE,NUMBER_FORMAT_RANGES:()=>bu,aborted:()=>Dn,allowsEval:()=>cE,assert:()=>Z5,assertEqual:()=>B5,assertIs:()=>j5,assertNever:()=>K5,assertNotEqual:()=>G5,assignProp:()=>zn,attachSchema:()=>_u,base64ToUint8Array:()=>MA,base64urlToUint8Array:()=>pU,cached:()=>tc,captureStackTrace:()=>rf,cleanEnum:()=>dU,cleanRegex:()=>Eu,clone:()=>Ir,cloneDef:()=>X5,codePointLength:()=>Su,constantCatch:()=>FA,createTransparentProxy:()=>nU,defineLazy:()=>iE,defineLazyInternal:()=>_e,derived:()=>gU,esc:()=>sE,escapeRegex:()=>Vo,explicitlyAborted:()=>dE,extend:()=>iU,finalizeIssue:()=>Lr,floatSafeRemainder:()=>oE,getElementAtPath:()=>q5,getEnumValues:()=>Qa,getLengthableOrigin:()=>Tu,getParsedType:()=>tU,getSizableOrigin:()=>PA,hexToUint8Array:()=>hU,hide:()=>lf,installLazyProp:()=>SU,isObject:()=>Cs,isPlainObject:()=>Ci,issue:()=>rc,joinValues:()=>nf,jsonStringifyReplacer:()=>ec,members:()=>fE,merge:()=>aU,mergeDefs:()=>Go,normalizeParams:()=>te,nullish:()=>rE,numKeys:()=>eU,objectClone:()=>W5,omit:()=>oU,optionalKeys:()=>uE,own:()=>Ii,parsedType:()=>pE,partial:()=>cU,pick:()=>rU,prefixIssues:()=>Cr,primitiveTypes:()=>zA,promiseAllObject:()=>J5,propertyKeyTypes:()=>lE,randomString:()=>Q5,rawShape:()=>nc,required:()=>lU,safeExtend:()=>sU,shallowClone:()=>kA,sizeCaps:()=>cf,slugify:()=>aE,stringifyPrimitive:()=>of,toZod:()=>V5,uint8ArrayToBase64:()=>UA,uint8ArrayToBase64url:()=>fU,uint8ArrayToHex:()=>mU,unwrapMessage:()=>Ja});function B5(e){return e}function G5(e){return e}function V5(){return e=>e}function j5(e){}function K5(e){throw new Error("Unexpected value in exhaustive check")}function Z5(e){}function Qa(e){let t=Object.values(e).filter(r=>typeof r=="number");return Object.entries(e).filter(([r,o])=>t.indexOf(+r)===-1).map(([r,o])=>o)}function nf(e,t="|"){return e.map(n=>of(n)).join(t)}function ec(e,t){return typeof t=="bigint"?t.toString():t}function tc(e){return new tE(e)}function rE(e){return e==null}function Eu(e){let t=e.startsWith("^")?1:0,n=e.endsWith("$")?e.length-1:e.length;return e.slice(t,n)}function oE(e,t){let n=e/t,r=Math.round(n),o=4*Number.EPSILON*Math.max(Math.abs(n),1);return Math.abs(n-r)<o?0:n-r}function iE(e,t,n){let r;Object.defineProperty(e,t,{get(){if(r!==CA)return r===void 0&&(r=CA,r=n()),r},set(o){Object.defineProperty(e,t,{value:o})},configurable:!0})}function W5(e){return Object.create(Object.getPrototypeOf(e),Object.getOwnPropertyDescriptors(e))}function zn(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function nc(e){let t=Object.getOwnPropertyDescriptor(e,"shape");return t!=null&&t.get?t.get.raw:t==null?void 0:t.value}function Bo(e){var t;return(t=nc(e._zod.def))!=null?t:e._zod.def.shape}function LA(e,t,n){Object.defineProperty(e,t,{get(){let r=n();return zn(this,t,r),r},enumerable:!0,configurable:!0})}function $A(e,t,n){t in e?zn(e,t,n):e[t]=n}function Is(e,t,n,r){let o=Bo(t);for(let i of n){let s=Object.getOwnPropertyDescriptor(o,i);s.enumerable&&(s.get?LA(e,i,()=>{let a=t._zod.def.shape[i];return r?r(a,i):a}):$A(e,i,r?r(s.value,i):s.value))}}function Y5(e,t){for(let n of Reflect.ownKeys(t)){let r=Object.getOwnPropertyDescriptor(t,n);r.enumerable&&(r.get?LA(e,n,()=>t[n]):$A(e,n,r.value))}}function Go(...e){let t={};for(let n of e){let r=Object.getOwnPropertyDescriptors(n);Object.assign(t,r)}return Object.defineProperties({},t)}function X5(e){return Go(e._zod.def)}function q5(e,t){return t?t.reduce((n,r)=>n==null?void 0:n[r],e):e}function J5(e){let t=Object.keys(e),n=t.map(r=>e[r]);return Promise.all(n).then(r=>{let o={};for(let i=0;i<t.length;i++)o[t[i]]=r[i];return o})}function Q5(e=10){let t="abcdefghijklmnopqrstuvwxyz",n="";for(let r=0;r<e;r++)n+=t[Math.floor(Math.random()*t.length)];return n}function sE(e){return JSON.stringify(e)}function aE(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}function Cs(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function Ci(e){if(Cs(e)===!1)return!1;let t=e.constructor;if(t===void 0||typeof t!="function")return!0;let n=t.prototype;return!(Cs(n)===!1||Object.prototype.hasOwnProperty.call(n,"isPrototypeOf")===!1)}function kA(e){return Ci(e)?{...e}:Array.isArray(e)?[...e]:e instanceof Map?new Map(e):e instanceof Set?new Set(e):e}function eU(e){let t=0;for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&t++;return t}function Vo(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Ir(e,t,n){let r=new e._zod.constr(t!=null?t:e._zod.def);return(!t||n!=null&&n.parent)&&(r._zod.parent=e),r}function te(e){let t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if((t==null?void 0:t.message)!==void 0){if((t==null?void 0:t.error)!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function nU(e){let t;return new Proxy({},{get(n,r,o){return t!=null||(t=e()),Reflect.get(t,r,o)},set(n,r,o,i){return t!=null||(t=e()),Reflect.set(t,r,o,i)},has(n,r){return t!=null||(t=e()),Reflect.has(t,r)},deleteProperty(n,r){return t!=null||(t=e()),Reflect.deleteProperty(t,r)},ownKeys(n){return t!=null||(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(n,r){return t!=null||(t=e()),Reflect.getOwnPropertyDescriptor(t,r)},defineProperty(n,r,o){return t!=null||(t=e()),Reflect.defineProperty(t,r,o)}})}function of(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function uE(e){return Object.keys(e).filter(t=>e[t]._zod.optin!==void 0&&e[t]._zod.optout==="optional")}function rU(e,t){let n=e._zod.def,r=n.checks;if(r&&r.length>0)throw new Error(".pick() cannot be used on object schemas containing refinements");let i={};return Is(i,e,af(e,t)),Ir(e,Go(n,{shape:i,checks:[]}))}function af(e,t){var o;let n=Bo(e),r=[];for(let i of Reflect.ownKeys(t)){if(!((o=Object.getOwnPropertyDescriptor(n,i))!=null&&o.enumerable))throw new Error(`Unrecognized key: "${String(i)}"`);t[i]&&r.push(i)}return r}function oU(e,t){let n=e._zod.def,r=n.checks;if(r&&r.length>0)throw new Error(".omit() cannot be used on object schemas containing refinements");let i=new Set(af(e,t)),s={};return Is(s,e,Reflect.ownKeys(Bo(e)).filter(a=>!i.has(a))),Ir(e,Go(n,{shape:s,checks:[]}))}function iU(e,t){if(!Ci(t))throw new Error("Invalid input to extend: expected a plain object");let n=e._zod.def.checks;if(n&&n.length>0){let o=Bo(e);for(let i of Reflect.ownKeys(t))if(Object.getOwnPropertyDescriptor(o,i)!==void 0)throw new Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}return Ir(e,Go(e._zod.def,{shape:DA(e,t)}))}function DA(e,t){let n={};return Is(n,e,Reflect.ownKeys(Bo(e))),Y5(n,t),n}function sU(e,t){if(!Ci(t))throw new Error("Invalid input to safeExtend: expected a plain object");return Ir(e,Go(e._zod.def,{shape:DA(e,t)}))}function aU(e,t){var o,i,s;if(!((o=t==null?void 0:t._zod)!=null&&o.def))throw new Error("Invalid input to merge: expected an object schema. To merge a plain shape, use `.extend()`.");if((i=e._zod.def.checks)!=null&&i.length)throw new Error(".merge() cannot be used on object schemas containing refinements. Use .safeExtend() instead.");let n={};Is(n,e,Reflect.ownKeys(Bo(e))),Is(n,t,Reflect.ownKeys(Bo(t)));let r=Go(e._zod.def,{shape:n,get catchall(){return t._zod.def.catchall},checks:(s=t._zod.def.checks)!=null?s:[]});return Ir(e,r)}function cU(e,t,n,r="partial"){let i=t._zod.def.checks;if(i&&i.length>0)throw new Error(`.${r}() cannot be used on object schemas containing refinements`);let a=n?new Set(af(t,n)):void 0,l={};return Is(l,t,Reflect.ownKeys(Bo(t)),e&&((u,d)=>a&&!a.has(d)?u:new e({type:"optional",innerType:u}))),Ir(t,Go(t._zod.def,{shape:l,checks:[]}))}function lU(e,t,n){let r=n?new Set(af(t,n)):void 0,o={};return Is(o,t,Reflect.ownKeys(Bo(t)),(i,s)=>r&&!r.has(s)?i:new e({type:"nonoptional",innerType:i})),Ir(t,Go(t._zod.def,{shape:o}))}function Dn(e,t=0){var n;if(e.aborted===!0)return!0;for(let r=t;r<e.issues.length;r++)if(((n=e.issues[r])==null?void 0:n.continue)!==!0)return!0;return!1}function dE(e,t=0){var n;if(e.aborted===!0)return!0;for(let r=t;r<e.issues.length;r++)if(((n=e.issues[r])==null?void 0:n.continue)===!1)return!0;return!1}function Cr(e,t){return t.map(n=>{var o;var r;return(o=(r=n).path)!=null||(r.path=[]),n.path.unshift(e),n})}function Ja(e){return typeof e=="string"?e:e==null?void 0:e.message}function cf(e){var n,r;let t=[];for(let o of e!=null?e:[]){let i=o._zod.def;if(!/_(length|size)$|_equals$/.test(i.check))break;let s=(r=(n=i.maximum)!=null?n:i.length)!=null?r:i.size;s>=0&&t.push([s,o])}return t}function _u(e,t,n){var o;var r;for(let i=t;i<e.length;i++)(o=(r=e[i]).schema)!=null||(r.schema=n)}function Lr(e,t,n){var l,u,d,f,m,h,E,S,A,w,N,O,k,G,V,W,K;var r;let o=(u=(l=e.inst)==null?void 0:l._zod)==null?void 0:u.traits;o!=null&&o.has("$ZodType")&&(o.has("$ZodCheck")?(d=(r=e).schema)!=null||(r.schema=e.inst):e.schema=e.inst);let i=e.schema!==e.inst?(m=(f=e.schema)==null?void 0:f._zod.def)==null?void 0:m.error:void 0,s=e.message?e.message:(W=(V=(k=(N=(A=Ja((S=(E=(h=e.inst)==null?void 0:h._zod.def)==null?void 0:E.error)==null?void 0:S.call(E,e)))!=null?A:Ja(i==null?void 0:i(e)))!=null?N:Ja((w=t==null?void 0:t.error)==null?void 0:w.call(t,e)))!=null?k:Ja((O=n.customError)==null?void 0:O.call(n,e)))!=null?V:Ja((G=n.localeError)==null?void 0:G.call(n,e)))!=null?W:"Invalid input",a={};for(let J of Object.keys(e))J==="inst"||J==="schema"||J==="continue"||J==="input"||J==="__proto__"||(a[J]=e[J]);return(K=a.path)!=null||(a.path=[]),a.message=s,t!=null&&t.reportInput&&(a.input=e.input),a}function PA(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function Su(e){let t=e.length;if(!uU.test(e))return t;let n=t;for(let r=0;r<t-1;r++)(e.charCodeAt(r)&64512)===55296&&(e.charCodeAt(r+1)&64512)===56320&&(n--,r++);return n}function Tu(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function pE(e){let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"nan":"number";case"object":{if(e===null)return"null";if(Array.isArray(e))return"array";let n=e;if(n&&Object.getPrototypeOf(n)!==Object.prototype&&"constructor"in n&&n.constructor)return n.constructor.name}}return t}function rc(...e){let[t,n,r]=e;return typeof t=="string"?{message:t,code:"custom",input:n,inst:r}:{...t}}function dU(e){return Object.entries(e).filter(([t,n])=>Number.isNaN(Number.parseInt(t,10))).map(t=>t[1])}function MA(e){let t=atob(e),n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=t.charCodeAt(r);return n}function UA(e){let t="";for(let n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return btoa(t)}function pU(e){let t=e.replace(/-/g,"+").replace(/_/g,"/"),n="=".repeat((4-t.length%4)%4);return MA(t+n)}function fU(e){return UA(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function hU(e){let t=e.replace(/^0x/,"");if(t.length%2!==0)throw new Error("Invalid hex string length");let n=new Uint8Array(t.length/2);for(let r=0;r<t.length;r+=2)n[r/2]=Number.parseInt(t.slice(r,r+2),16);return n}function mU(e){return Array.from(e).map(t=>t.toString(16).padStart(2,"0")).join("")}function fE(e,t){for(let n in t){let r=Object.getOwnPropertyDescriptor(t,n);r.get?Object.defineProperty(e,n,{...r,enumerable:!1}):EU(e,n,r.value)}}function Ii(e,t,n,r=!0){return Object.defineProperty(e,t,{configurable:!0,writable:!0,enumerable:r,value:n}),n}function lf(e,t,n){return Ii(e,t,n,!1)}function gU(e,t){for(let n in e){let r=e[n];Object.defineProperty(t,n,{configurable:!0,enumerable:!0,get(){return Ii(this,n,r(this))},set(o){Ii(this,n,o)}})}return t}function EU(e,t,n){Object.defineProperty(e,t,{configurable:!0,get(){return this==null?n:Ii(this,t,n.bind(this))},set(r){Ii(this,t,r)}})}function bU(e,t){let n=Object.getPrototypeOf(e);return t in n?void 0:n}function _e(e,t,n){let r=Object.getPrototypeOf(e._zod);if(t in r&&eE!==e._zod){eE=void 0;return}eE=e._zod,Object.defineProperty(r,t,{configurable:!0,get(){Object.defineProperty(this,t,_U);let o=Oi;Oi=!1;try{let i=n(this);return Oi?delete this[t]:Object.defineProperty(this,t,{configurable:!0,writable:!0,value:i}),Oi=Oi||o,i}catch(i){throw delete this[t],Oi=Oi||o,i}},set(o){Object.defineProperty(this,t,{configurable:!0,writable:!0,value:o})}})}function SU(e,t,n,r){let o=bU(e,t);o&&Object.defineProperty(o,t,{configurable:!0,get(){let i={configurable:!0,writable:!0,enumerable:r,value:void 0};return Object.defineProperty(this,t,i),i.value=n(this),Object.defineProperty(this,t,i),i.value},set(i){Object.defineProperty(this,t,{configurable:!0,writable:!0,enumerable:r,value:i})}})}function FA(e){let t=()=>e;return t[HA]=!0,t}var tE,CA,rf,cE,tU,lE,zA,bu,sf,uU,nE,eE,Oi,_U,HA,Sn=y(()=>{Ls();tE=class{constructor(t){this._getter=t,this._value=void 0}get value(){let t=this._getter;return t!==void 0&&(this._value=t(),this._getter=void 0),this._value}};CA=Symbol("evaluating");rf="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};cE=tc(()=>{var e;if(nn.jitless||typeof navigator!="undefined"&&((e=navigator==null?void 0:navigator.userAgent)!=null&&e.includes("Cloudflare")))return!1;try{let t=Function;return new t(""),!0}catch{return!1}});tU=e=>{let t=typeof e;switch(t){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map!="undefined"&&e instanceof Map?"map":typeof Set!="undefined"&&e instanceof Set?"set":typeof Date!="undefined"&&e instanceof Date?"date":typeof File!="undefined"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${t}`)}},lE=new Set(["string","number","symbol"]),zA=new Set(["string","number","bigint","boolean","symbol","undefined"]);bu={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},sf={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};uU=/[\uD800-\uDBFF]/;nE=class{constructor(...t){}};Oi=!1,_U={configurable:!0,get(){Oi=!0}};HA="~constantCatch"});function TU(e){let t=GA;if(t){let n=t.stackTraceLimit;if(typeof n=="number"){try{t.stackTraceLimit=0}catch{return GA=null,new e}try{return new e}finally{t.stackTraceLimit=n}}}return new e}function I(e,t,n,r){var m;let o={};function i(h){this.def=h,this.constr=f,this.traits=new Set}i.prototype=o;let s=n,a=s&&new WeakSet;function l(h,E){if(h._zod){if(h._zod.traits.has(e))return}else{hE.value=new i(E);try{Object.defineProperty(h,"_zod",hE)}finally{hE.value=void 0}}if(h._zod.traits.add(e),t(h,E),a){let A=Object.getPrototypeOf(h),w=h._zod.constr.prototype,N=A;for(;N&&N!==w;)N=Object.getPrototypeOf(N);let O=N!=null?N:A;a.has(O)||(a.add(O),fE(O,s))}let S=f.prototype;for(let A in S)Object.prototype.hasOwnProperty.call(S,A)&&(A in h||(h[A]=S[A].bind(h)))}let u=(m=r==null?void 0:r.Parent)!=null?m:Object;class d extends u{}Object.defineProperty(d,"name",{value:e});function f(h){var w;let E=r!=null&&r.Parent?TU(d):this;l(E,h);let S=E._zod.deferred;if(S){for(let N of S)N();E._zod.deferred=void 0}let A=(w=globalThis.__zod_globalConfig)==null?void 0:w.postProcessor;return A&&A(E),E}return Object.defineProperty(f,"init",{value:l}),Object.defineProperty(f,Symbol.hasInstance,{value:h=>{var E,S;return r!=null&&r.Parent&&h instanceof r.Parent?!0:(S=(E=h==null?void 0:h._zod)==null?void 0:E.traits)==null?void 0:S.has(e)}}),Object.defineProperty(f,"name",{value:e}),f}function Pn(e){return e&&Object.assign(nn,e),nn}var BA,hE,GA,$r,oc,VA,nn,Ls=y(()=>{Sn();hE={value:void 0,enumerable:!1},GA="captureStackTrace"in Error?Error:null;$r=class extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},oc=class extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}};(VA=(BA=globalThis).__zod_globalConfig)!=null||(BA.__zod_globalConfig={});nn=globalThis.__zod_globalConfig});function xU(){var t;let e=this._zod;return(t=e.message)!=null||(e.message=JSON.stringify(e.def,ec,2)),e.message}function AU(e){this._zod.message=e}function wU(e,t,n){return Object.prototype.hasOwnProperty.call(e,t)||(t==="__proto__"?Object.defineProperty(e,t,{value:n(),writable:!0,enumerable:!0,configurable:!0}):e[t]=n()),e[t]}function WA(e,t=n=>n.message){let n={},r=[];for(let o of e.issues)o.path.length>0?wU(n,o.path[0],()=>[]).push(t(o)):r.push(t(o));return{formErrors:r,fieldErrors:n}}function YA(e,t=n=>n.message){let n={_errors:[]},r=(o,i=[])=>{for(let s of o.issues)if(s.code==="invalid_union"&&s.errors.length)s.errors.map(a=>r({issues:a},[...i,...s.path]));else if(s.code==="invalid_key")r({issues:s.issues},[...i,...s.path]);else if(s.code==="invalid_element")r({issues:s.issues},[...i,...s.path]);else{let a=[...i,...s.path];if(a.length===0)n._errors.push(t(s));else{let l=n,u=0;for(;u<a.length;){let d=a[u],f=u===a.length-1;if(d==="_errors"){f&&l._errors.push(t(s)),u++;continue}Object.prototype.hasOwnProperty.call(l,d)||Object.defineProperty(l,d,{value:{_errors:[]},enumerable:!0,writable:!0,configurable:!0});let m=l[d];f&&m._errors.push(t(s)),l=m,u++}}}};return r(e),n}var yU,gE,jA,KA,ZA,VY,XA=y(()=>{Ls();Sn();yU={get:xU,set:AU,enumerable:!0,configurable:!0},gE={value:void 0,enumerable:!1},jA=new WeakSet([Object.prototype,Error.prototype]),KA=(e,t)=>{e.name="$ZodError",gE.value=t,Object.defineProperty(e,"issues",gE),gE.value=void 0,Object.defineProperty(e,"message",yU);let n=Object.getPrototypeOf(e);jA.has(n)||(jA.add(n),Object.defineProperty(n,"toString",{configurable:!0,enumerable:!1,get(){let r=()=>this.message;return Object.defineProperty(this,"toString",{value:r,configurable:!0,writable:!0}),r},set(r){Object.defineProperty(this,"toString",{value:r,configurable:!0,writable:!0})}}))},ZA=I("$ZodError",KA),VY=I("$ZodError",KA,void 0,{Parent:Error})});function uf(e,t){var n;return{callee:(n=t==null?void 0:t.callee)!=null?n:e,Err:t==null?void 0:t.Err}}function qA(e,t,n){let r;return{success:!1,get error(){return r||(r=new e(t.map(o=>Lr(o,n,Pn()))),t=void 0,n=void 0),r},set error(o){r=o,t=void 0,n=void 0}}}function RU(e,t,n){let r=n?{...n,async:!1,abortEarly:!0}:{async:!1,abortEarly:!0},o=e._zod.bag.fallbackRun,i;if(o?(r[NU]=!0,i=o({value:t,issues:[]},r)):i=e._zod.run({value:t,issues:[]},r),i instanceof Promise)throw new $r;return i.issues.length===0}var df,pf,ff,hf,vU,NU,EE,bE,JA,QA,ey,ty,ny,ry,oy,iy,sy=y(()=>{Ls();Sn();df=e=>{let t=(n,r,o,i)=>{var l,u;let s=o?{...o,async:!1}:{async:!1},a=n._zod.run({value:r,issues:[]},s);if(a instanceof Promise)throw new $r;if(a.issues.length){let d=new((l=i==null?void 0:i.Err)!=null?l:e)(a.issues.map(f=>Lr(f,s,Pn())));throw rf(d,(u=i==null?void 0:i.callee)!=null?u:t),d}return a.value};return t},pf=e=>{let t=async(n,r,o,i)=>{var l,u;let s=o?{...o,async:!0}:{async:!0},a=n._zod.run({value:r,issues:[]},s);if(a instanceof Promise&&(a=await a),a.issues.length){let d=new((l=i==null?void 0:i.Err)!=null?l:e)(a.issues.map(f=>Lr(f,s,Pn())));throw rf(d,(u=i==null?void 0:i.callee)!=null?u:t),d}return a.value};return t},ff=e=>(t,n,r)=>{let o=r?{...r,async:!1}:{async:!1},i=t._zod.run({value:n,issues:[]},o);if(i instanceof Promise)throw new $r;return i.issues.length?qA(e,i.issues,o):{success:!0,data:i.value}};hf=e=>async(t,n,r)=>{let o=r?{...r,async:!0}:{async:!0},i=t._zod.run({value:n,issues:[]},o);return i instanceof Promise&&(i=await i),i.issues.length?qA(e,i.issues,o):{success:!0,data:i.value}},vU=Symbol.for("zod.compile.invalid"),NU=Symbol.for("zod.compile.fallback"),EE=((e,t,n)=>{let r=e._zod.bag.validator;if(r!==void 0){if(r(t)!==vU)return!0;if(r.definite===!0&&n===void 0)return!1}return RU(e,t,n)});bE=async(e,t,n)=>{let r=n?{...n,async:!0,abortEarly:!0}:{async:!0,abortEarly:!0},o=e._zod.run({value:t,issues:[]},r);return o instanceof Promise&&(o=await o),o.issues.length===0},JA=e=>{let t=df(e),n=(r,o,i,s)=>{let a=i?{...i,direction:"backward"}:{direction:"backward"};return t(r,o,a,uf(n,s))};return n},QA=e=>{let t=df(e),n=(r,o,i,s)=>t(r,o,i,uf(n,s));return n},ey=e=>{let t=pf(e),n=async(r,o,i,s)=>{let a=i?{...i,direction:"backward"}:{direction:"backward"};return await t(r,o,a,uf(n,s))};return n},ty=e=>{let t=pf(e),n=async(r,o,i,s)=>await t(r,o,i,uf(n,s));return n},ny=e=>(t,n,r)=>{let o=r?{...r,direction:"backward"}:{direction:"backward"};return ff(e)(t,n,o)},ry=e=>(t,n,r)=>ff(e)(t,n,r),oy=e=>async(t,n,r)=>{let o=r?{...r,direction:"backward"}:{direction:"backward"};return hf(e)(t,n,o)},iy=e=>async(t,n,r)=>hf(e)(t,n,r)});function fy(e){return new RegExp(`^[a-zA-Z0-9_-]{${e}}$`)}function Ey(){return new RegExp(OU,"u")}function IU(e){return new RegExp(`^${e}$`)}function _E(e){let t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:e.seconds?`${t}:[0-5]\\d(?:\\.\\d+)?`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function Ry(e){return new RegExp(`^${_E(e)}$`)}function Oy(e){let t=["Z"];e.offset&&t.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");let n=`${_E({precision:e.precision,seconds:!0})}(?:${t.join("|")})`,r=e.local?`${n}|${_E({precision:e.precision})}`:n;return new RegExp(`^${vy}T(?:${r})$`)}var ay,cy,ly,uy,dy,py,hy,my,SE,gy,OU,by,_y,Sy,Ty,xy,Ay,yy,wy,vy,Ny,Iy,TE,xu,Cy,Ly,$y,ky,zy,gf=y(()=>{ay=/^[cC][0-9a-z]{6,}$/,cy=/^[0-9a-z]+$/,ly=/^[0-7][0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{25}$/,uy=/^[0-9a-vA-V]{20}$/,dy=/^[A-Za-z0-9]{27}$/,py=/^[a-zA-Z0-9_-]{21}$/;hy=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,my=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,SE=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,gy=/^(?:[A-Za-z0-9_'+\-]+\.)*[A-Za-z0-9_'+\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,OU="^(?=[\\s\\S]*[\\p{Extended_Pictographic}\\p{Regional_Indicator}\\u20E3])[\\p{Extended_Pictographic}\\p{Emoji_Component}]+$";by=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,_y=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,Sy=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,Ty=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,xy=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Ay=/^(?:[A-Za-z0-9_-]{4})*(?:[A-Za-z0-9_-]{2,3})?$/,yy=/^https?$/,wy=/^\+[1-9]\d{6,14}$/,vy="(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))";Ny=IU(vy);Iy=/^[\s\S]{0,}$/,TE=/^-?\d+$/,xu=/^-?\d+(?:\.\d+)?$/,Cy=/^(?:true|false)$/i,Ly=/^null$/i,$y=/^undefined$/i,ky=/^[^A-Z]*$/,zy=/^[^a-z]*$/});var Pt,xE,Ef,AE,yE,Dy,Py,My,Uy,Hy,Au,Fy,By,Gy,Vy,jy,Ky,Zy,bf=y(()=>{Ls();gf();Sn();Pt=I("$ZodCheck",(e,t)=>{var r,o;var n;(r=e._zod)!=null||(e._zod={}),e._zod.def=t,(o=(n=e._zod).onattach)!=null||(n.onattach=[])}),xE=e=>{let t=e.value;return!rE(t)&&t.length!==void 0},Ef={number:"number",bigint:"bigint",object:"date"},AE=I("$ZodCheckLessThan",(e,t)=>{Pt.init(e,t);let n=Ef[typeof t.value];e._zod.check=r=>{var o;(t.inclusive?r.value<=t.value:r.value<t.value)||r.issues.push({origin:(o=Ef[typeof r.value])!=null?o:n,code:"too_big",maximum:typeof t.value=="object"?t.value.getTime():t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),yE=I("$ZodCheckGreaterThan",(e,t)=>{Pt.init(e,t);let n=Ef[typeof t.value];e._zod.check=r=>{var o;(t.inclusive?r.value>=t.value:r.value>t.value)||r.issues.push({origin:(o=Ef[typeof r.value])!=null?o:n,code:"too_small",minimum:typeof t.value=="object"?t.value.getTime():t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),Dy=I("$ZodCheckMultipleOf",(e,t)=>{Pt.init(e,t),e._zod.check=n=>{if(typeof n.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof n.value=="bigint"?t.value!==BigInt(0)&&n.value%t.value===BigInt(0):oE(n.value,t.value)===0)||n.issues.push({origin:typeof n.value,code:"not_multiple_of",divisor:t.value,input:n.value,inst:e,continue:!t.abort})}}),Py=I("$ZodCheckNumberFormat",(e,t)=>{var s;Pt.init(e,t),t.format=t.format||"float64";let n=(s=t.format)==null?void 0:s.includes("int"),r=n?"int":"number",[o,i]=bu[t.format];e._zod.check=a=>{let l=a.value;if(n){if(!Number.isInteger(l)){a.issues.push({expected:r,format:t.format,code:"invalid_type",continue:!1,input:l,inst:e});return}if(!Number.isSafeInteger(l)){l>0?a.issues.push({input:l,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,inclusive:!0,continue:!t.abort}):a.issues.push({input:l,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,inclusive:!0,continue:!t.abort});return}}l<o&&a.issues.push({origin:"number",input:l,code:"too_small",minimum:o,inclusive:!0,inst:e,continue:!t.abort}),l>i&&a.issues.push({origin:"number",input:l,code:"too_big",maximum:i,inclusive:!0,inst:e,continue:!t.abort})}}),My=I("$ZodCheckMaxLength",(e,t)=>{var r;var n;Pt.init(e,t),(r=(n=e._zod.def).when)!=null||(n.when=xE),e._zod.check=o=>{let i=o.value,s=i.length;if((typeof i=="string"&&s>t.maximum?Su(i):s)<=t.maximum)return;let l=Tu(i);o.issues.push({origin:l,code:"too_big",maximum:t.maximum,inclusive:!0,input:i,inst:e,continue:!t.abort})}}),Uy=I("$ZodCheckMinLength",(e,t)=>{var r;var n;Pt.init(e,t),(r=(n=e._zod.def).when)!=null||(n.when=xE),e._zod.check=o=>{let i=o.value,s=i.length;if((typeof i=="string"&&s>=t.minimum&&s<t.minimum*2?Su(i):s)>=t.minimum)return;let l=Tu(i);o.issues.push({origin:l,code:"too_small",minimum:t.minimum,inclusive:!0,input:i,inst:e,continue:!t.abort})}}),Hy=I("$ZodCheckLengthEquals",(e,t)=>{var r;var n;Pt.init(e,t),(r=(n=e._zod.def).when)!=null||(n.when=xE),e._zod.check=o=>{let i=o.value,s=i.length,a=typeof i=="string"&&s>=t.length&&s<=t.length*2?Su(i):s;if(a===t.length)return;let l=Tu(i),u=a>t.length;o.issues.push({origin:l,...u?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),Au=I("$ZodCheckStringFormat",(e,t)=>{var o,i;var n,r;Pt.init(e,t),t.pattern?(o=(n=e._zod).check)!=null||(n.check=s=>{t.pattern.lastIndex=0,!t.pattern.test(s.value)&&s.issues.push({origin:"string",code:"invalid_format",format:t.format,input:s.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(i=(r=e._zod).check)!=null||(r.check=()=>{})}),Fy=I("$ZodCheckRegex",(e,t)=>{Au.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:"regex",input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),By=I("$ZodCheckLowerCase",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=ky),Au.init(e,t)}),Gy=I("$ZodCheckUpperCase",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=zy),Au.init(e,t)}),Vy=I("$ZodCheckIncludes",(e,t)=>{Pt.init(e,t);let n=Vo(t.includes),r=new RegExp(typeof t.position=="number"?`^.{${t.position},}${n}`:n);t.pattern=r,e._zod.check=o=>{o.value.includes(t.includes,t.position)||o.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:o.value,inst:e,continue:!t.abort})}}),jy=I("$ZodCheckStartsWith",(e,t)=>{var r;Pt.init(e,t);let n=new RegExp(`^${Vo(t.prefix)}.*`);(r=t.pattern)!=null||(t.pattern=n),e._zod.check=o=>{o.value.startsWith(t.prefix)||o.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:o.value,inst:e,continue:!t.abort})}}),Ky=I("$ZodCheckEndsWith",(e,t)=>{var r;Pt.init(e,t);let n=new RegExp(`.*${Vo(t.suffix)}$`);(r=t.pattern)!=null||(t.pattern=n),e._zod.check=o=>{o.value.endsWith(t.suffix)||o.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:o.value,inst:e,continue:!t.abort})}}),Zy=I("$ZodCheckOverwrite",(e,t)=>{Pt.init(e,t),e._zod.check=n=>{n.value=t.tx(n.value)}})});var _f,wE=y(()=>{_f=class{constructor(t=[],n={}){this.content=[],this.indent=0,this.args=t,this.closed=n}indented(t){this.indent+=1;try{t(this)}finally{this.indent-=1}}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}let r=t.split(`
2
2
  `).filter(s=>s),o=Math.min(...r.map(s=>s.length-s.trimStart().length)),i=r.map(s=>s.slice(o)).map(s=>" ".repeat(this.indent*2)+s);for(let s of i)this.content.push(s)}compile(){var o;let t=Function,n=(o=this==null?void 0:this.content)!=null?o:[""];return new t(...Object.keys(this.closed),`return function (${this.args.join(", ")}) {
3
3
  ${n.join(`
4
4
  `)}
5
- };`)(...Object.values(this.closed))}}});var My,TE=y(()=>{My={major:4,minor:6,patch:7}});async function gU(e,t){let n={async:!0};return Jy(await e._zod.run({value:t,issues:[]},n),n)}function AE(e){return{validate:t=>{let n={async:!1};try{let r=e._zod.run({value:t,issues:[]},n);if(!(r instanceof Promise))return Jy(r,n)}catch{}return gU(e,t)},vendor:"zod",version:1}}function rw(e){try{return typeof URL!="undefined"&&typeof URL.canParse=="function"?URL.canParse(e):(new URL(e),!0)}catch{return!1}}function EU(e,t){return!("normalize"in t)&&!("hostname"in t)&&!("protocol"in t)?rw(e)||Ef:bU(e,t)}function bU(e,t){var n,r;if(!t.normalize&&((n=t.protocol)==null?void 0:n.source)===fy.source&&!/^https?:\/\//i.test(e))return nw;try{if(typeof URL!="undefined"){let o=URL;if(typeof o.parse=="function")return(r=o.parse(e))!=null?r:Ef}return new URL(e)}catch{return Ef}}function Uy(e){return e.replace(_U,"")}function SU(e,t){return t.lastIndex=0,t.test(e.hostname)}function TU(e,t){return t.lastIndex=0,t.test(e.protocol.endsWith(":")?e.protocol.slice(0,-1):e.protocol)}function Ew(e){return xU.test(e)?rw(`http://[${e}]`):!1}function AU(e){let t=e.split("/");if(t.length!==2)return!1;let[n,r]=t;if(!r)return!1;let o=Number(r);return`${o}`!==r||o<0||o>128?!1:Ew(n)}function Tw(e){if(e==="")return!0;if(/\s/.test(e)||e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}function yU(e){if(!Sf.test(e))return!1;let t=e.replace(/[-_]/g,r=>r==="-"?"+":"/"),n=t.padEnd(Math.ceil(t.length/4)*4,"=");return Tw(n)}function wU(e,t=null){try{let n=e.split(".");if(n.length!==3)return!1;let[r]=n;if(!r)return!1;let o=JSON.parse(atob(r));return!("typ"in o&&(o==null?void 0:o.typ)!=="JWT"||!o.alg||t&&(!("alg"in o)||o.alg!==t))}catch{return!1}}function vU(e,t){let n=rf(e._zod.def.checks);if(!n.length)return;let r=Math.min(...n.map(i=>i[0])),o=e._zod.parse;e._zod.parse=(i,s)=>{let a=t(i.value);if(a>r&&!(s!=null&&s.skipChecks)&&(s==null?void 0:s.direction)!=="backward"){for(let[l,u]of rf(e._zod.def.checks))if(a>l&&u._zod.def.when(i)){let d=i.issues.length;return u._zod.check(i),i.issues[d].continue=!1,mu(i.issues,d,e),i}}return o(i,s)}}function Hy(e,t,n){e.issues.length&&t.issues.push(...Or(n,e.issues)),t.value[n]=e.value}function bf(e,t,n,r,o,i){let s=n in r,a=i==="optional";if(!(!s&&a&&o==="optional")){if(e.issues.length){if(o!==void 0&&a&&!s)return;t.issues.push(...Or(n,e.issues))}if(!s&&o===void 0){e.issues.length||t.issues.push({code:"invalid_type",expected:"nonoptional",input:void 0,path:[n]});return}e.value===void 0?(s||o==="defaulted"&&!a)&&(t.value[n]=void 0):t.value[n]=e.value}}function $w(e){var s,a,l,u;let t=Object.keys(e.shape),n=Object.getOwnPropertySymbols(e.shape),r=n.length?n:RU,o=r.length?[...t,...r]:t;for(let d of o)if(!((u=(l=(a=(s=e.shape)==null?void 0:s[d])==null?void 0:a._zod)==null?void 0:l.traits)!=null&&u.has("$ZodType")))throw new Error(`Invalid element at key "${String(d)}": expected a Zod schema`);let i=iE(e.shape);return{...e,allKeys:o,symbolKeys:r,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(i)}}function kw(e,t,n,r,o,i,s){let a=[],l=o.keySet,u=o.catchall._zod,d=u.def.type,f=u.optin,m=u.optout,h=0;for(let E in t){if(s&&n.issues.length!==h){if(zn(n,h))break;h=n.issues.length}if(l.has(E))continue;if(E==="__proto__"){d==="never"&&a.push(E);continue}if(d==="never"){a.push(E);continue}let _=u.run({value:t[E],issues:[]},r);_ instanceof Promise?e.push(_.then(A=>bf(A,n,E,t,f,m))):bf(_,n,E,t,f,m)}return a.length&&n.issues.push({code:"unrecognized_keys",keys:a,input:t,inst:i,continue:!0}),e.length?Promise.all(e).then(()=>n):n}function Fy(e,t,n,r){for(let i of e)if(i.issues.length===0)return t.value=i.value,t;let o=e.filter(i=>!zn(i));return o.length===1?(t.value=o[0].value,o[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:n,errors:e.map(i=>i.issues.map(s=>Ir(s,r,Dn())))}),t)}function IU(e){var n;let t=new Map;for(let r of e.options){let o=(n=r._zod.propValues)==null?void 0:n[e.discriminator];if(!o||o.size===0)throw new Error(`Invalid discriminated union option at index "${e.options.indexOf(r)}"`);for(let i of o)if(t.has(i)){if(i!==void 0)throw new Error(`Duplicate discriminator value "${String(i)}"`);t.set(i,null)}else t.set(i,r)}return t}function xE(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(Ii(e)&&Ii(t)){let n=Object.keys(t),r=Object.keys(e).filter(i=>n.indexOf(i)!==-1),o={...e,...t};Object.prototype.hasOwnProperty.call(o,"__proto__")&&delete o.__proto__;for(let i of r){if(i==="__proto__")continue;let s=xE(e[i],t[i]);if(!s.valid)return{valid:!1,mergeErrorPath:[i,...s.mergeErrorPath]};o[i]=s.data}return{valid:!0,data:o}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let n=[];for(let r=0;r<e.length;r++){let o=e[r],i=t[r],s=xE(o,i);if(!s.valid)return{valid:!1,mergeErrorPath:[r,...s.mergeErrorPath]};n.push(s.data)}return{valid:!0,data:n}}return{valid:!1,mergeErrorPath:[]}}function By(e,t,n){let r=new Map,o,i=new Map,s=(u,d)=>{var m,h;let f;if(u.code==="unrecognized_keys"&&!((m=u.path)!=null&&m.length))o!=null||(o=u),f=u.keys;else if(u.code==="invalid_key"&&u.origin==="record"&&((h=u.path)==null?void 0:h.length)===1){let E=String(u.path[0]);i.has(E)||i.set(E,u),f=[E]}else return!1;for(let E of f)r.has(E)||r.set(E,{}),r.get(E)[d]=!0;return!0};for(let u of t.issues)s(u,"l")||e.issues.push(u);for(let u of n.issues)s(u,"r")||e.issues.push(u);let a=[...r].filter(([,u])=>u.l&&u.r).map(([u])=>u);if(a.length){let u=o?a.filter(d=>o.keys.includes(d)):[];u.length&&e.issues.push({...o,keys:u});for(let d of a)!u.includes(d)&&i.has(d)&&e.issues.push(i.get(d))}let l=xE(t.value,n.value);if(!l.valid){if(zn(e))return e;throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(l.mergeErrorPath)}`)}return e.value=l.data,e}function Gy(e,t){for(let n=e.length-1;n>=0;n--)if(!(t==="optin"?e[n]._zod.optin!==void 0:e[n]._zod.optout==="optional"))return n+1;return 0}function Vy(e,t,n){e.issues.length&&t.issues.push(...Or(n,e.issues)),t.value[n]=e.value}function jy(e,t,n,r,o){for(let i=0;i<n.length;i++){let s=e[i],a=i<r.length;if(!a&&i>=o&&n[i]._zod.optin==="optional"){t.value.length=i;break}if(s.issues.length){if(!a&&i>=o){t.value.length=i;break}t.issues.push(...Or(i,s.issues))}t.value[i]=s.value}for(let i=t.value.length-1;i>=r.length&&(n[i]._zod.optout==="optional"&&t.value[i]===void 0);i--)t.value.length=i;return t}function Ky(e,t){return e.value=t.issues.length?void 0:t.value,e}function Zy(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}function Wy(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}function Yy(e,t,n,r){return t.issues.length?(e.value=n.catchValue({...t,value:e.value,error:{issues:t.issues.map(o=>Ir(o,r,Dn()))},input:e.value}),e):(e.value=t.value,t.memo&&(e.memo=!0),e)}function gf(e,t,n){return e.issues.some(r=>r.code!=="unrecognized_keys")?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},n)}function Xy(e){return e.memo||(e.value=Object.freeze(e.value)),e}function qy(e,t,n,r){var o;if(!e){let i={code:"custom",input:n,inst:r,path:[...(o=r._zod.def.path)!=null?o:[]],continue:!r._zod.def.abort};r._zod.def.params&&(i.params=r._zod.def.params),t.issues.push(tc(i))}}var De,Jy,_f,Be,Qy,ew,tw,nw,Ef,_U,ow,iw,sw,aw,cw,lw,uw,dw,pw,fw,hw,mw,gw,xU,bw,_w,Sw,yE,xw,Sf,Aw,yw,ww,wE,vw,Nw,Rw,Ow,Iw,Cw,NU,Lw,RU,OU,zw,vE,Dw,Pw,Mw,Uw,Hw,Fw,Bw,NE,Gw,Vw,jw,Kw,Zw,Ww,RE,Yw,Xw,qw,Jw,OE=y(()=>{hf();Ls();SE();pf();Sn();TE();Sn();De=I("$ZodType",(e,t)=>{var i,s;var n;e!=null||(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=My;let r=e._zod.def.checks,o=e._zod.traits.has("$ZodCheck")?[e,...r!=null?r:[]]:r!=null&&r.length?[...r]:[];for(let a of o)for(let l of a._zod.onattach)l(e);if(o.length===0)(i=(n=e._zod).deferred)!=null||(n.deferred=[]),(s=e._zod.deferred)==null||s.push(()=>{e._zod.run=e._zod.parse});else{let a=(u,d,f)=>{if(u.memo)return u;let m=zn(u),h;for(let E of d){if(E._zod.def.when){if(sE(u)||!E._zod.def.when(u))continue}else if(m)continue;let _=u.issues.length,A=E._zod.check(u);if(A instanceof Promise&&(f==null?void 0:f.async)===!1)throw new Cr;if(h||A instanceof Promise)h=(h!=null?h:Promise.resolve()).then(async()=>{await A,u.issues.length!==_&&(mu(u.issues,_,e),m||(m=zn(u,_)))});else{if(u.issues.length===_)continue;mu(u.issues,_,e),m||(m=zn(u,_))}}return h?h.then(()=>u):u},l=(u,d,f)=>{if(zn(u))return u.aborted=!0,u;let m=a(d,o,f);if(m instanceof Promise){if(f.async===!1)throw new Cr;return m.then(h=>e._zod.parse(h,f))}return e._zod.parse(m,f)};e._zod.run=(u,d)=>{if(d.skipChecks)return e._zod.parse(u,d);if(d.direction==="backward"){let m=e._zod.parse({value:u.value,issues:[]},{...d,skipChecks:!0});return m instanceof Promise?m.then(h=>l(h,u,d)):l(m,u,d)}let f=e._zod.parse(u,d);if(f instanceof Promise){if(d.async===!1)throw new Cr;return f.then(m=>a(m,o,d))}return a(f,o,d)}}},{get"~standard"(){return of(this,"~standard",AE(this))},set"~standard"(e){Oi(this,"~standard",e)}}),Jy=(e,t)=>e.issues.length?{issues:e.issues.map(n=>Ir(n,t,Dn()))}:{value:e.value};_f=I("$ZodString",(e,t)=>{var n;De.init(e,t),e._zod.pattern=(n=t.pattern)!=null?n:_y,e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=String(r.value)}catch{}return typeof r.value=="string"||r.issues.push({expected:"string",code:"invalid_type",input:r.value,inst:e}),r}}),Be=I("$ZodStringFormat",(e,t)=>{_u.init(e,t),_f.init(e,t)}),Qy=I("$ZodGUID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=oy),Be.init(e,t)}),ew=I("$ZodUUID",(e,t)=>{var n,r;if(t.version){let i={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(i===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);(n=t.pattern)!=null||(t.pattern=mE(i))}else(r=t.pattern)!=null||(t.pattern=mE());Be.init(e,t)}),tw=I("$ZodEmail",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=iy),Be.init(e,t)}),nw=1,Ef=2;_U=/[\t\n\r]/g;ow=I("$ZodURL",(e,t)=>{Be.init(e,t),e._zod.check=n=>{try{let r=n.value.trim(),o=EU(r,t);if(o===nw){n.issues.push({code:"invalid_format",format:"url",note:"Invalid URL format",input:n.value,inst:e,continue:!t.abort});return}if(o===Ef){n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!t.abort});return}if(o===!0){n.value=Uy(r);return}t.hostname&&!SU(o,t.hostname)&&n.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:t.hostname.source,input:n.value,inst:e,continue:!t.abort}),t.protocol&&!TU(o,t.protocol)&&n.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:n.value,inst:e,continue:!t.abort}),n.value=t.normalize?o.href:Uy(r);return}catch{n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!t.abort})}}}),iw=I("$ZodEmoji",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=sy()),Be.init(e,t)}),sw=I("$ZodNanoID",(e,t)=>{var n;if(t.length!==void 0&&(!Number.isInteger(t.length)||t.length<1))throw new Error(`Invalid nanoid length: ${t.length}`);(n=t.pattern)!=null||(t.pattern=t.length===void 0?ty:ny(t.length)),Be.init(e,t)}),aw=I("$ZodCUID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=XA),Be.init(e,t)}),cw=I("$ZodCUID2",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=qA),Be.init(e,t)}),lw=I("$ZodULID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=JA),Be.init(e,t)}),uw=I("$ZodXID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=QA),Be.init(e,t)}),dw=I("$ZodKSUID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=ey),Be.init(e,t)}),pw=I("$ZodISODateTime",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=by(t)),Be.init(e,t)}),fw=I("$ZodISODate",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=gy),Be.init(e,t)}),hw=I("$ZodISOTime",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Ey(t)),Be.init(e,t)}),mw=I("$ZodISODuration",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=ry),Be.init(e,t)}),gw=I("$ZodIPv4",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=ay),Be.init(e,t)}),xU=/^[0-9a-fA-F:.]+$/;bw=I("$ZodIPv6",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=cy),Be.init(e,t),e._zod.check=r=>{Ew(r.value)||r.issues.push({code:"invalid_format",format:"ipv6",input:r.value,inst:e,continue:!t.abort})}}),_w=I("$ZodCIDRv4",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=ly),Be.init(e,t)});Sw=I("$ZodCIDRv6",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=uy),Be.init(e,t),e._zod.check=r=>{AU(r.value)||r.issues.push({code:"invalid_format",format:"cidrv6",input:r.value,inst:e,continue:!t.abort})}});yE=/^[0-9a-zA-Z+/]*={0,2}$/,xw=I("$ZodBase64",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=yE),Be.init(e,t),e._zod.check=r=>{Tw(r.value)||r.issues.push({code:"invalid_format",format:"base64",input:r.value,inst:e,continue:!t.abort})}}),Sf=/^[A-Za-z0-9_-]*$/;Aw=I("$ZodBase64URL",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Sf),Be.init(e,t),e._zod.check=r=>{yU(r.value)||r.issues.push({code:"invalid_format",format:"base64url",input:r.value,inst:e,continue:!t.abort})}}),yw=I("$ZodE164",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=hy),Be.init(e,t)});ww=I("$ZodJWT",(e,t)=>{Be.init(e,t),e._zod.check=n=>{wU(n.value,t.alg)||n.issues.push({code:"invalid_format",format:"jwt",input:n.value,inst:e,continue:!t.abort})}}),wE=I("$ZodNumber",(e,t)=>{De.init(e,t),e._zod.pattern=bu,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=Number(n.value)}catch{}let o=n.value;if(typeof o=="number"&&!Number.isNaN(o)&&Number.isFinite(o))return n;let i=typeof o=="number"?Number.isNaN(o)?"NaN":Number.isFinite(o)?void 0:String(o):void 0;return n.issues.push({expected:"number",code:"invalid_type",input:o,inst:e,...i?{received:i}:{}}),n}}),vw=I("$ZodNumberFormat",(e,t)=>{vy.init(e,t),wE.init(e,t)}),Nw=I("$ZodBoolean",(e,t)=>{De.init(e,t),e._zod.pattern=Sy,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=!!n.value}catch{}let o=n.value;return typeof o=="boolean"||n.issues.push({expected:"boolean",code:"invalid_type",input:o,inst:e}),n}}),Rw=I("$ZodUndefined",(e,t)=>{De.init(e,t),e._zod.pattern=xy,e._zod.values=new Set([void 0]),e._zod.parse=(n,r)=>{let o=n.value;return typeof o=="undefined"||n.issues.push({expected:"undefined",code:"invalid_type",input:o,inst:e}),n}}),Ow=I("$ZodNull",(e,t)=>{De.init(e,t),e._zod.pattern=Ty,e._zod.values=new Set([null]),e._zod.parse=(n,r)=>{let o=n.value;return o===null||n.issues.push({expected:"null",code:"invalid_type",input:o,inst:e}),n}}),Iw=I("$ZodUnknown",(e,t)=>{De.init(e,t),e._zod.parse=n=>n}),Cw=I("$ZodNever",(e,t)=>{De.init(e,t),e._zod.parse=(n,r)=>(n.issues.push({expected:"never",code:"invalid_type",input:n.value,inst:e}),n)});NU=e=>Array.isArray(e)?e.length:-1;Lw=I("$ZodArray",(e,t)=>{De.init(e,t);let n=nn.memoizer;n==null||n.attach(e),e._zod.parse=(r,o)=>{let i=r.value;if(!Array.isArray(i))return r.issues.push({expected:"array",code:"invalid_type",input:i,inst:e}),r;r.value=n?n.alloc(e,r,Array(i.length),o):Array(i.length);let s=[],a=o==null?void 0:o.abortEarly;for(let l=0;l<i.length;l++){let u=i[l],d=t.element._zod.run({value:u,issues:[]},o);if(d instanceof Promise)s.push(d.then(f=>Hy(f,r,l)));else if(Hy(d,r,l),a&&d.issues.length!==0&&zn(d))break}return s.length?Promise.all(s).then(()=>r):r},vU(e,NU)});RU=[];OU=I("$ZodObject",(e,t)=>{var u;De.init(e,t);let n=Object.getOwnPropertyDescriptor(t,"shape"),r=n!=null&&n.get?n.get.raw:(u=t.shape)!=null?u:{};if(r){let d=()=>{let f={...r};return Object.defineProperty(t,"shape",{value:f}),d.raw=f,f};d.raw=r,Object.defineProperty(t,"shape",{get:d})}let o=Qa(()=>$w(t));_e(e,"propValues",d=>{let f=d.def.shape,m={};for(let h in f){let E=f[h]._zod;if(E.values){Object.prototype.hasOwnProperty.call(m,h)||kn(m,h,new Set);for(let _ of E.values)m[h].add(_);E.optin!==void 0&&m[h].add(void 0)}}return m});let i=Cs,s=t.catchall,a,l=nn.memoizer;l==null||l.attach(e),e._zod.parse=(d,f)=>{a!=null||(a=o.value);let m=d.value;if(!i(m))return d.issues.push({expected:"object",code:"invalid_type",input:m,inst:e}),d;d.value=l?l.alloc(e,d,{},f):{};let h=[],E=a.shape,_=f==null?void 0:f.abortEarly,A=d.issues.length;for(let v of a.allKeys){if(_&&d.issues.length!==A){if(zn(d,A))break;A=d.issues.length}if(v==="__proto__")continue;let N=E[v],O=N._zod.optin,k=N._zod.optout,j=N._zod.run({value:m[v],issues:[]},f);j instanceof Promise?h.push(j.then(Y=>bf(Y,d,v,m,O,k))):bf(j,d,v,m,O,k)}return s?kw(h,m,d,f,o.value,e,_===!0):h.length?Promise.all(h).then(()=>d):d}}),zw=I("$ZodObjectJIT",(e,t)=>{OU.init(e,t);let n=e._zod.parse,r=Qa(()=>$w(t)),o=nn.memoizer,i=h=>{var j,Y;let E=r.value,_=E.symbolKeys,A=new mf(["payload","ctx"],{shape:h,inst:e,memo:o,syms:_}),v=X=>`shape[${X}]._zod.run({ value: input[${X}], issues: [] }, ctx)`,N=(X,G)=>`
6
- let ${X}_ab = false;
7
- for (let i = 0; i < ${X}.issues.length; i++) {
8
- const iss = ${X}.issues[i];
9
- iss.path = iss.path ? [${G}, ...iss.path] : [${G}];
5
+ };`)(...Object.values(this.closed))}}});var Yy,vE=y(()=>{Yy={major:4,minor:6,patch:7}});async function CU(e,t){let n={async:!0};return lw(await e._zod.run({value:t,issues:[]},n),n)}function RE(e){return{validate:t=>{let n={async:!1};try{let r=e._zod.run({value:t,issues:[]},n);if(!(r instanceof Promise))return lw(r,n)}catch{}return CU(e,t)},vendor:"zod",version:1}}function hw(e){try{return typeof URL!="undefined"&&typeof URL.canParse=="function"?URL.canParse(e):(new URL(e),!0)}catch{return!1}}function LU(e,t){return!("normalize"in t)&&!("hostname"in t)&&!("protocol"in t)?hw(e)||Tf:$U(e,t)}function $U(e,t){var n,r;if(!t.normalize&&((n=t.protocol)==null?void 0:n.source)===yy.source&&!/^https?:\/\//i.test(e))return fw;try{if(typeof URL!="undefined"){let o=URL;if(typeof o.parse=="function")return(r=o.parse(e))!=null?r:Tf}return new URL(e)}catch{return Tf}}function Xy(e){return e.replace(kU,"")}function zU(e,t){return t.lastIndex=0,t.test(e.hostname)}function DU(e,t){return t.lastIndex=0,t.test(e.protocol.endsWith(":")?e.protocol.slice(0,-1):e.protocol)}function Rw(e){return PU.test(e)?hw(`http://[${e}]`):!1}function MU(e){let t=e.split("/");if(t.length!==2)return!1;let[n,r]=t;if(!r)return!1;let o=Number(r);return`${o}`!==r||o<0||o>128?!1:Rw(n)}function Lw(e){if(e==="")return!0;if(/\s/.test(e)||e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}function UU(e){if(!yf.test(e))return!1;let t=e.replace(/[-_]/g,r=>r==="-"?"+":"/"),n=t.padEnd(Math.ceil(t.length/4)*4,"=");return Lw(n)}function HU(e,t=null){try{let n=e.split(".");if(n.length!==3)return!1;let[r]=n;if(!r)return!1;let o=JSON.parse(atob(r));return!("typ"in o&&(o==null?void 0:o.typ)!=="JWT"||!o.alg||t&&(!("alg"in o)||o.alg!==t))}catch{return!1}}function FU(e,t){let n=cf(e._zod.def.checks);if(!n.length)return;let r=Math.min(...n.map(i=>i[0])),o=e._zod.parse;e._zod.parse=(i,s)=>{let a=t(i.value);if(a>r&&!(s!=null&&s.skipChecks)&&(s==null?void 0:s.direction)!=="backward"){for(let[l,u]of cf(e._zod.def.checks))if(a>l&&u._zod.def.when(i)){let d=i.issues.length;return u._zod.check(i),i.issues[d].continue=!1,_u(i.issues,d,e),i}}return o(i,s)}}function qy(e,t,n){e.issues.length&&t.issues.push(...Cr(n,e.issues)),t.value[n]=e.value}function xf(e,t,n,r,o,i){let s=n in r,a=i==="optional";if(!(!s&&a&&o==="optional")){if(e.issues.length){if(o!==void 0&&a&&!s)return;t.issues.push(...Cr(n,e.issues))}if(!s&&o===void 0){e.issues.length||t.issues.push({code:"invalid_type",expected:"nonoptional",input:void 0,path:[n]});return}e.value===void 0?(s||o==="defaulted"&&!a)&&(t.value[n]=void 0):t.value[n]=e.value}}function Vw(e){var s,a,l,u;let t=Object.keys(e.shape),n=Object.getOwnPropertySymbols(e.shape),r=n.length?n:GU,o=r.length?[...t,...r]:t;for(let d of o)if(!((u=(l=(a=(s=e.shape)==null?void 0:s[d])==null?void 0:a._zod)==null?void 0:l.traits)!=null&&u.has("$ZodType")))throw new Error(`Invalid element at key "${String(d)}": expected a Zod schema`);let i=uE(e.shape);return{...e,allKeys:o,symbolKeys:r,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(i)}}function jw(e,t,n,r,o,i,s){let a=[],l=o.keySet,u=o.catchall._zod,d=u.def.type,f=u.optin,m=u.optout,h=0;for(let E in t){if(s&&n.issues.length!==h){if(Dn(n,h))break;h=n.issues.length}if(l.has(E))continue;if(E==="__proto__"){d==="never"&&a.push(E);continue}if(d==="never"){a.push(E);continue}let S=u.run({value:t[E],issues:[]},r);S instanceof Promise?e.push(S.then(A=>xf(A,n,E,t,f,m))):xf(S,n,E,t,f,m)}return a.length&&n.issues.push({code:"unrecognized_keys",keys:a,input:t,inst:i,continue:!0}),e.length?Promise.all(e).then(()=>n):n}function Jy(e,t,n,r){for(let i of e)if(i.issues.length===0)return t.value=i.value,t;let o=e.filter(i=>!Dn(i));return o.length===1?(t.value=o[0].value,o[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:n,errors:e.map(i=>i.issues.map(s=>Lr(s,r,Pn())))}),t)}function jU(e){var n;let t=new Map;for(let r of e.options){let o=(n=r._zod.propValues)==null?void 0:n[e.discriminator];if(!o||o.size===0)throw new Error(`Invalid discriminated union option at index "${e.options.indexOf(r)}"`);for(let i of o)if(t.has(i)){if(i!==void 0)throw new Error(`Duplicate discriminator value "${String(i)}"`);t.set(i,null)}else t.set(i,r)}return t}function NE(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(Ci(e)&&Ci(t)){let n=Object.keys(t),r=Object.keys(e).filter(i=>n.indexOf(i)!==-1),o={...e,...t};Object.prototype.hasOwnProperty.call(o,"__proto__")&&delete o.__proto__;for(let i of r){if(i==="__proto__")continue;let s=NE(e[i],t[i]);if(!s.valid)return{valid:!1,mergeErrorPath:[i,...s.mergeErrorPath]};o[i]=s.data}return{valid:!0,data:o}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let n=[];for(let r=0;r<e.length;r++){let o=e[r],i=t[r],s=NE(o,i);if(!s.valid)return{valid:!1,mergeErrorPath:[r,...s.mergeErrorPath]};n.push(s.data)}return{valid:!0,data:n}}return{valid:!1,mergeErrorPath:[]}}function Qy(e,t,n){let r=new Map,o,i=new Map,s=(u,d)=>{var m,h;let f;if(u.code==="unrecognized_keys"&&!((m=u.path)!=null&&m.length))o!=null||(o=u),f=u.keys;else if(u.code==="invalid_key"&&u.origin==="record"&&((h=u.path)==null?void 0:h.length)===1){let E=String(u.path[0]);i.has(E)||i.set(E,u),f=[E]}else return!1;for(let E of f)r.has(E)||r.set(E,{}),r.get(E)[d]=!0;return!0};for(let u of t.issues)s(u,"l")||e.issues.push(u);for(let u of n.issues)s(u,"r")||e.issues.push(u);let a=[...r].filter(([,u])=>u.l&&u.r).map(([u])=>u);if(a.length){let u=o?a.filter(d=>o.keys.includes(d)):[];u.length&&e.issues.push({...o,keys:u});for(let d of a)!u.includes(d)&&i.has(d)&&e.issues.push(i.get(d))}let l=NE(t.value,n.value);if(!l.valid){if(Dn(e))return e;throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(l.mergeErrorPath)}`)}return e.value=l.data,e}function ew(e,t){for(let n=e.length-1;n>=0;n--)if(!(t==="optin"?e[n]._zod.optin!==void 0:e[n]._zod.optout==="optional"))return n+1;return 0}function tw(e,t,n){e.issues.length&&t.issues.push(...Cr(n,e.issues)),t.value[n]=e.value}function nw(e,t,n,r,o){for(let i=0;i<n.length;i++){let s=e[i],a=i<r.length;if(!a&&i>=o&&n[i]._zod.optin==="optional"){t.value.length=i;break}if(s.issues.length){if(!a&&i>=o){t.value.length=i;break}t.issues.push(...Cr(i,s.issues))}t.value[i]=s.value}for(let i=t.value.length-1;i>=r.length&&(n[i]._zod.optout==="optional"&&t.value[i]===void 0);i--)t.value.length=i;return t}function rw(e,t){return e.value=t.issues.length?void 0:t.value,e}function ow(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}function iw(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}function sw(e,t,n,r){return t.issues.length?(e.value=n.catchValue({...t,value:e.value,error:{issues:t.issues.map(o=>Lr(o,r,Pn()))},input:e.value}),e):(e.value=t.value,t.memo&&(e.memo=!0),e)}function Sf(e,t,n){return e.issues.some(r=>r.code!=="unrecognized_keys")?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},n)}function aw(e){return e.memo||(e.value=Object.freeze(e.value)),e}function cw(e,t,n,r){var o;if(!e){let i={code:"custom",input:n,inst:r,path:[...(o=r._zod.def.path)!=null?o:[]],continue:!r._zod.def.abort};r._zod.def.params&&(i.params=r._zod.def.params),t.issues.push(rc(i))}}var De,lw,Af,Be,uw,dw,pw,fw,Tf,kU,mw,gw,Ew,bw,_w,Sw,Tw,xw,Aw,yw,ww,vw,Nw,PU,Ow,Iw,Cw,OE,$w,yf,kw,zw,Dw,IE,Pw,Mw,Uw,Hw,Fw,Bw,BU,Gw,GU,VU,Kw,CE,Zw,Ww,Yw,Xw,qw,Jw,Qw,LE,ev,tv,nv,rv,ov,iv,$E,sv,av,cv,lv,kE=y(()=>{bf();Ls();wE();gf();Sn();vE();Sn();De=I("$ZodType",(e,t)=>{var i,s;var n;e!=null||(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=Yy;let r=e._zod.def.checks,o=e._zod.traits.has("$ZodCheck")?[e,...r!=null?r:[]]:r!=null&&r.length?[...r]:[];for(let a of o)for(let l of a._zod.onattach)l(e);if(o.length===0)(i=(n=e._zod).deferred)!=null||(n.deferred=[]),(s=e._zod.deferred)==null||s.push(()=>{e._zod.run=e._zod.parse});else{let a=(u,d,f)=>{if(u.memo)return u;let m=Dn(u),h;for(let E of d){if(E._zod.def.when){if(dE(u)||!E._zod.def.when(u))continue}else if(m)continue;let S=u.issues.length,A=E._zod.check(u);if(A instanceof Promise&&(f==null?void 0:f.async)===!1)throw new $r;if(h||A instanceof Promise)h=(h!=null?h:Promise.resolve()).then(async()=>{await A,u.issues.length!==S&&(_u(u.issues,S,e),m||(m=Dn(u,S)))});else{if(u.issues.length===S)continue;_u(u.issues,S,e),m||(m=Dn(u,S))}}return h?h.then(()=>u):u},l=(u,d,f)=>{if(Dn(u))return u.aborted=!0,u;let m=a(d,o,f);if(m instanceof Promise){if(f.async===!1)throw new $r;return m.then(h=>e._zod.parse(h,f))}return e._zod.parse(m,f)};e._zod.run=(u,d)=>{if(d.skipChecks)return e._zod.parse(u,d);if(d.direction==="backward"){let m=e._zod.parse({value:u.value,issues:[]},{...d,skipChecks:!0});return m instanceof Promise?m.then(h=>l(h,u,d)):l(m,u,d)}let f=e._zod.parse(u,d);if(f instanceof Promise){if(d.async===!1)throw new $r;return f.then(m=>a(m,o,d))}return a(f,o,d)}}},{get"~standard"(){return lf(this,"~standard",RE(this))},set"~standard"(e){Ii(this,"~standard",e)}}),lw=(e,t)=>e.issues.length?{issues:e.issues.map(n=>Lr(n,t,Pn()))}:{value:e.value};Af=I("$ZodString",(e,t)=>{var n;De.init(e,t),e._zod.pattern=(n=t.pattern)!=null?n:Iy,e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=String(r.value)}catch{}return typeof r.value=="string"||r.issues.push({expected:"string",code:"invalid_type",input:r.value,inst:e}),r}}),Be=I("$ZodStringFormat",(e,t)=>{Au.init(e,t),Af.init(e,t)}),uw=I("$ZodGUID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=my),Be.init(e,t)}),dw=I("$ZodUUID",(e,t)=>{var n,r;if(t.version){let i={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(i===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);(n=t.pattern)!=null||(t.pattern=SE(i))}else(r=t.pattern)!=null||(t.pattern=SE());Be.init(e,t)}),pw=I("$ZodEmail",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=gy),Be.init(e,t)}),fw=1,Tf=2;kU=/[\t\n\r]/g;mw=I("$ZodURL",(e,t)=>{Be.init(e,t),e._zod.check=n=>{try{let r=n.value.trim(),o=LU(r,t);if(o===fw){n.issues.push({code:"invalid_format",format:"url",note:"Invalid URL format",input:n.value,inst:e,continue:!t.abort});return}if(o===Tf){n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!t.abort});return}if(o===!0){n.value=Xy(r);return}t.hostname&&!zU(o,t.hostname)&&n.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:t.hostname.source,input:n.value,inst:e,continue:!t.abort}),t.protocol&&!DU(o,t.protocol)&&n.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:n.value,inst:e,continue:!t.abort}),n.value=t.normalize?o.href:Xy(r);return}catch{n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!t.abort})}}}),gw=I("$ZodEmoji",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Ey()),Be.init(e,t)}),Ew=I("$ZodNanoID",(e,t)=>{var n;if(t.length!==void 0&&(!Number.isInteger(t.length)||t.length<1))throw new Error(`Invalid nanoid length: ${t.length}`);(n=t.pattern)!=null||(t.pattern=t.length===void 0?py:fy(t.length)),Be.init(e,t)}),bw=I("$ZodCUID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=ay),Be.init(e,t)}),_w=I("$ZodCUID2",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=cy),Be.init(e,t)}),Sw=I("$ZodULID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=ly),Be.init(e,t)}),Tw=I("$ZodXID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=uy),Be.init(e,t)}),xw=I("$ZodKSUID",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=dy),Be.init(e,t)}),Aw=I("$ZodISODateTime",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Oy(t)),Be.init(e,t)}),yw=I("$ZodISODate",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Ny),Be.init(e,t)}),ww=I("$ZodISOTime",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Ry(t)),Be.init(e,t)}),vw=I("$ZodISODuration",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=hy),Be.init(e,t)}),Nw=I("$ZodIPv4",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=by),Be.init(e,t)}),PU=/^[0-9a-fA-F:.]+$/;Ow=I("$ZodIPv6",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=_y),Be.init(e,t),e._zod.check=r=>{Rw(r.value)||r.issues.push({code:"invalid_format",format:"ipv6",input:r.value,inst:e,continue:!t.abort})}}),Iw=I("$ZodCIDRv4",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Sy),Be.init(e,t)});Cw=I("$ZodCIDRv6",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=Ty),Be.init(e,t),e._zod.check=r=>{MU(r.value)||r.issues.push({code:"invalid_format",format:"cidrv6",input:r.value,inst:e,continue:!t.abort})}});OE=/^[0-9a-zA-Z+/]*={0,2}$/,$w=I("$ZodBase64",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=OE),Be.init(e,t),e._zod.check=r=>{Lw(r.value)||r.issues.push({code:"invalid_format",format:"base64",input:r.value,inst:e,continue:!t.abort})}}),yf=/^[A-Za-z0-9_-]*$/;kw=I("$ZodBase64URL",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=yf),Be.init(e,t),e._zod.check=r=>{UU(r.value)||r.issues.push({code:"invalid_format",format:"base64url",input:r.value,inst:e,continue:!t.abort})}}),zw=I("$ZodE164",(e,t)=>{var n;(n=t.pattern)!=null||(t.pattern=wy),Be.init(e,t)});Dw=I("$ZodJWT",(e,t)=>{Be.init(e,t),e._zod.check=n=>{HU(n.value,t.alg)||n.issues.push({code:"invalid_format",format:"jwt",input:n.value,inst:e,continue:!t.abort})}}),IE=I("$ZodNumber",(e,t)=>{De.init(e,t),e._zod.pattern=xu,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=Number(n.value)}catch{}let o=n.value;if(typeof o=="number"&&!Number.isNaN(o)&&Number.isFinite(o))return n;let i=typeof o=="number"?Number.isNaN(o)?"NaN":Number.isFinite(o)?void 0:String(o):void 0;return n.issues.push({expected:"number",code:"invalid_type",input:o,inst:e,...i?{received:i}:{}}),n}}),Pw=I("$ZodNumberFormat",(e,t)=>{Py.init(e,t),IE.init(e,t)}),Mw=I("$ZodBoolean",(e,t)=>{De.init(e,t),e._zod.pattern=Cy,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=!!n.value}catch{}let o=n.value;return typeof o=="boolean"||n.issues.push({expected:"boolean",code:"invalid_type",input:o,inst:e}),n}}),Uw=I("$ZodUndefined",(e,t)=>{De.init(e,t),e._zod.pattern=$y,e._zod.values=new Set([void 0]),e._zod.parse=(n,r)=>{let o=n.value;return typeof o=="undefined"||n.issues.push({expected:"undefined",code:"invalid_type",input:o,inst:e}),n}}),Hw=I("$ZodNull",(e,t)=>{De.init(e,t),e._zod.pattern=Ly,e._zod.values=new Set([null]),e._zod.parse=(n,r)=>{let o=n.value;return o===null||n.issues.push({expected:"null",code:"invalid_type",input:o,inst:e}),n}}),Fw=I("$ZodUnknown",(e,t)=>{De.init(e,t),e._zod.parse=n=>n}),Bw=I("$ZodNever",(e,t)=>{De.init(e,t),e._zod.parse=(n,r)=>(n.issues.push({expected:"never",code:"invalid_type",input:n.value,inst:e}),n)});BU=e=>Array.isArray(e)?e.length:-1;Gw=I("$ZodArray",(e,t)=>{De.init(e,t);let n=nn.memoizer;n==null||n.attach(e),e._zod.parse=(r,o)=>{let i=r.value;if(!Array.isArray(i))return r.issues.push({expected:"array",code:"invalid_type",input:i,inst:e}),r;r.value=n?n.alloc(e,r,Array(i.length),o):Array(i.length);let s=[],a=o==null?void 0:o.abortEarly;for(let l=0;l<i.length;l++){let u=i[l],d=t.element._zod.run({value:u,issues:[]},o);if(d instanceof Promise)s.push(d.then(f=>qy(f,r,l)));else if(qy(d,r,l),a&&d.issues.length!==0&&Dn(d))break}return s.length?Promise.all(s).then(()=>r):r},FU(e,BU)});GU=[];VU=I("$ZodObject",(e,t)=>{var u;De.init(e,t);let n=Object.getOwnPropertyDescriptor(t,"shape"),r=n!=null&&n.get?n.get.raw:(u=t.shape)!=null?u:{};if(r){let d=()=>{let f={...r};return Object.defineProperty(t,"shape",{value:f}),d.raw=f,f};d.raw=r,Object.defineProperty(t,"shape",{get:d})}let o=tc(()=>Vw(t));_e(e,"propValues",d=>{let f=d.def.shape,m={};for(let h in f){let E=f[h]._zod;if(E.values){Object.prototype.hasOwnProperty.call(m,h)||zn(m,h,new Set);for(let S of E.values)m[h].add(S);E.optin!==void 0&&m[h].add(void 0)}}return m});let i=Cs,s=t.catchall,a,l=nn.memoizer;l==null||l.attach(e),e._zod.parse=(d,f)=>{a!=null||(a=o.value);let m=d.value;if(!i(m))return d.issues.push({expected:"object",code:"invalid_type",input:m,inst:e}),d;d.value=l?l.alloc(e,d,{},f):{};let h=[],E=a.shape,S=f==null?void 0:f.abortEarly,A=d.issues.length;for(let w of a.allKeys){if(S&&d.issues.length!==A){if(Dn(d,A))break;A=d.issues.length}if(w==="__proto__")continue;let N=E[w],O=N._zod.optin,k=N._zod.optout,G=N._zod.run({value:m[w],issues:[]},f);G instanceof Promise?h.push(G.then(V=>xf(V,d,w,m,O,k))):xf(G,d,w,m,O,k)}return s?jw(h,m,d,f,o.value,e,S===!0):h.length?Promise.all(h).then(()=>d):d}}),Kw=I("$ZodObjectJIT",(e,t)=>{VU.init(e,t);let n=e._zod.parse,r=tc(()=>Vw(t)),o=nn.memoizer,i=h=>{var G,V;let E=r.value,S=E.symbolKeys,A=new _f(["payload","ctx"],{shape:h,inst:e,memo:o,syms:S}),w=W=>`shape[${W}]._zod.run({ value: input[${W}], issues: [] }, ctx)`,N=(W,K)=>`
6
+ let ${W}_ab = false;
7
+ for (let i = 0; i < ${W}.issues.length; i++) {
8
+ const iss = ${W}.issues[i];
9
+ iss.path = iss.path ? [${K}, ...iss.path] : [${K}];
10
10
  payload.issues.push(iss);
11
- if (iss.continue !== true) ${X}_ab = true;
11
+ if (iss.continue !== true) ${W}_ab = true;
12
12
  }
13
- if (${X}_ab && ctx && ctx.abortEarly) {
13
+ if (${W}_ab && ctx && ctx.abortEarly) {
14
14
  payload.value = newResult;
15
15
  return payload;
16
- }`;A.write("const input = payload.value;");let O=Object.create(null),k=0;for(let X of E.allKeys)O[X]=`key_${k++}`;A.write(o?"const newResult = memo.alloc(inst, payload, {}, ctx);":"const newResult = {};");for(let X of E.allKeys){if(X==="__proto__")continue;let G=O[X],ee=typeof X=="symbol"?`syms[${_.indexOf(X)}]`:tE(X),be=`${ee} in input`,me=h[X],it=(j=me==null?void 0:me._zod)==null?void 0:j.optin,Xp=it!==void 0,Wa=((Y=me==null?void 0:me._zod)==null?void 0:Y.optout)==="optional";if(A.write(`const ${G} = ${v(ee)};`),Xp&&Wa){let wi=it==="optional"?`${G}_present`:`${G}.value !== undefined || ${G}_present`;A.write(`
17
- const ${G}_present = ${be};
18
- if (!${G}.issues.length || ${G}_present) {
19
- if (${G}.issues.length) {${N(G,ee)}
16
+ }`;A.write("const input = payload.value;");let O=Object.create(null),k=0;for(let W of E.allKeys)O[W]=`key_${k++}`;A.write(o?"const newResult = memo.alloc(inst, payload, {}, ctx);":"const newResult = {};");for(let W of E.allKeys){if(W==="__proto__")continue;let K=O[W],J=typeof W=="symbol"?`syms[${S.indexOf(W)}]`:sE(W),le=`${J} in input`,ge=h[W],Xe=(G=ge==null?void 0:ge._zod)==null?void 0:G.optin,gu=Xe!==void 0,Yg=((V=ge==null?void 0:ge._zod)==null?void 0:V.optout)==="optional";if(A.write(`const ${K} = ${w(J)};`),gu&&Yg){let Ya=Xe==="optional"?`${K}_present`:`${K}.value !== undefined || ${K}_present`;A.write(`
17
+ const ${K}_present = ${le};
18
+ if (!${K}.issues.length || ${K}_present) {
19
+ if (${K}.issues.length) {${N(K,J)}
20
20
  }
21
21
 
22
- if (${wi}) {
23
- newResult[${ee}] = ${G}.value;
22
+ if (${Ya}) {
23
+ newResult[${J}] = ${K}.value;
24
24
  }
25
25
  }
26
26
 
27
- `)}else Xp?(A.write(`
28
- if (${G}.issues.length) {${N(G,ee)}
27
+ `)}else gu?(A.write(`
28
+ if (${K}.issues.length) {${N(K,J)}
29
29
  }
30
- `),it==="defaulted"?A.write(`newResult[${ee}] = ${G}.value;`):A.write(`
31
- if (${G}.value !== undefined || ${be}) {
32
- newResult[${ee}] = ${G}.value;
30
+ `),Xe==="defaulted"?A.write(`newResult[${J}] = ${K}.value;`):A.write(`
31
+ if (${K}.value !== undefined || ${le}) {
32
+ newResult[${J}] = ${K}.value;
33
33
  }
34
34
  `)):A.write(`
35
- const ${G}_present = ${be};
36
- if (${G}.issues.length) {${N(G,ee)}
35
+ const ${K}_present = ${le};
36
+ if (${K}.issues.length) {${N(K,J)}
37
37
  }
38
- if (!${G}_present && !${G}.issues.length) {
38
+ if (!${K}_present && !${K}.issues.length) {
39
39
  payload.issues.push({
40
40
  code: "invalid_type",
41
41
  expected: "nonoptional",
42
42
  input: undefined,
43
- path: [${ee}]
43
+ path: [${J}]
44
44
  });
45
45
  if (ctx && ctx.abortEarly) {
46
46
  payload.value = newResult;
@@ -48,70 +48,70 @@ ${n.join(`
48
48
  }
49
49
  }
50
50
 
51
- if (${G}_present) {
52
- newResult[${ee}] = ${G}.value;
51
+ if (${K}_present) {
52
+ newResult[${J}] = ${K}.value;
53
53
  }
54
54
 
55
- `)}return A.write("payload.value = newResult;"),A.write("return payload;"),A.compile()},s,a=Cs,l=!nn.jitless,d=l&&rE.value,f=t.catchall,m;e._zod.parse=(h,E)=>{m!=null||(m=r.value);let _=h.value;return a(_)?l&&d&&(E==null?void 0:E.async)===!1&&E.jitless!==!0?(s||(s=i(t.shape)),h=s(h,E),f?kw([],_,h,E,m,e,(E==null?void 0:E.abortEarly)===!0):h):n(h,E):(h.issues.push({expected:"object",code:"invalid_type",input:_,inst:e}),h)}});vE=I("$ZodUnion",(e,t)=>{De.init(e,t),_e(e,"optin",r=>r.def.options.some(o=>o._zod.optin==="defaulted")?"defaulted":r.def.options.some(o=>o._zod.optin!==void 0)?"optional":void 0),_e(e,"optout",r=>r.def.options.some(o=>o._zod.optout==="optional")?"optional":void 0),_e(e,"values",r=>{if(r.def.options.every(o=>o._zod.values))return new Set(r.def.options.flatMap(o=>Array.from(o._zod.values)))}),_e(e,"pattern",r=>{if(r.def.options.every(o=>o._zod.pattern)){let o=r.def.options.map(i=>i._zod.pattern);return new RegExp(`^(${o.map(i=>fu(i.source)).join("|")})$`)}});let n=t.options.length===1?t.options[0]._zod.run:null;e._zod.parse=(r,o)=>{if(n)return n(r,o);let i=!1,s=[];for(let a of t.options){let l=a._zod.run({value:r.value,issues:[]},o);if(l instanceof Promise)s.push(l),i=!0;else{if(l.issues.length===0)return l;s.push(l)}}return i?Promise.all(s).then(a=>Fy(a,r,e,o)):Fy(s,r,e,o)}});Dw=I("$ZodDiscriminatedUnion",(e,t)=>{t.inclusive=!1,vE.init(e,t);let n=e._zod.parse;_e(e,"propValues",o=>{var a,l;let i={},s=0;for(let u of o.def.options){let d=u._zod.propValues;if(!d||Object.keys(d).length===0)throw new Error(`Invalid discriminated union option at index "${o.def.options.indexOf(u)}"`);(a=d[o.def.discriminator])!=null&&a.has(void 0)&&s++;for(let[f,m]of Object.entries(d)){Object.prototype.hasOwnProperty.call(i,f)||kn(i,f,new Set);for(let h of m)i[f].add(h)}}return!o.def.unionFallback&&s>1&&((l=i[o.def.discriminator])==null||l.delete(void 0)),i}),t.options.forEach((o,i)=>{let s=ec(o._zod.def);if(s&&!Object.prototype.hasOwnProperty.call(s,t.discriminator))throw new Error(`Invalid discriminated union option at index "${i}"`)});let r=Qa(()=>IU(t));e._zod.parse=(o,i)=>{let s=o.value;if(!Cs(s))return o.issues.push({code:"invalid_type",expected:"object",input:s,inst:e}),o;let a=s==null?void 0:s[t.discriminator],l=r.value.get(a);return l&&(a!==void 0||i.direction!=="backward")?l._zod.run(o,i):t.unionFallback||i.direction==="backward"?n(o,i):(o.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,options:Array.from(r.value.keys()).filter(u=>r.value.get(u)!==null),input:s,path:[t.discriminator],inst:e}),o)}}),Pw=I("$ZodIntersection",(e,t)=>{De.init(e,t),e._zod.parse=(n,r)=>{let o=n.value,i=t.left._zod.run({value:o,issues:[]},r),s=t.right._zod.run({value:o,issues:[]},r);return i instanceof Promise||s instanceof Promise?Promise.all([i,s]).then(([l,u])=>By(n,l,u)):By(n,i,s)}});Mw=I("$ZodTuple",(e,t)=>{De.init(e,t);let n=t.items,r=nn.memoizer;r==null||r.attach(e),e._zod.parse=(o,i)=>{let s=o.value;if(!Array.isArray(s))return o.issues.push({input:s,inst:e,expected:"tuple",code:"invalid_type"}),o;o.value=r?r.alloc(e,o,[],i):[];let a=[],l=Gy(n,"optin"),u=Gy(n,"optout");if(!t.rest){if(s.length<l)return o.issues.push({code:"too_small",minimum:l,inclusive:!0,input:s,inst:e,origin:"array"}),o;s.length>n.length&&o.issues.push({code:"too_big",maximum:n.length,inclusive:!0,input:s,inst:e,origin:"array"})}let d=new Array(n.length),f=t.rest?i==null?void 0:i.abortEarly:void 0,m=!1;for(let h=0;h<n.length;h++){let E=n[h]._zod.run({value:s[h],issues:[]},i);E instanceof Promise?a.push(E.then(_=>{d[h]=_})):(d[h]=E,f&&!m&&E.issues.length&&(m=zn(E)))}if(t.rest&&!m){let h=n.length-1,E=s.slice(n.length),_=o.issues.length;for(let A of E){if(f&&o.issues.length!==_){if(zn(o,_))break;_=o.issues.length}h++;let v=t.rest._zod.run({value:A,issues:[]},i);v instanceof Promise?a.push(v.then(N=>Vy(N,o,h))):Vy(v,o,h)}}return a.length?Promise.all(a).then(()=>jy(d,o,n,s,u)):jy(d,o,n,s,u)}});Uw=I("$ZodRecord",(e,t)=>{De.init(e,t);let n=nn.memoizer;n==null||n.attach(e),e._zod.parse=(r,o)=>{let i=r.value;if(!Ii(i))return r.issues.push({expected:"record",code:"invalid_type",input:i,inst:e}),r;let s=[],a=t.keyType._zod.values;if(a&&!t.partial){r.value=n?n.alloc(e,r,{},o):{};let l=new Set;for(let d of a)if(typeof d=="string"||typeof d=="number"||typeof d=="symbol"){if(l.add(typeof d=="number"?d.toString():d),d==="__proto__")continue;let f=t.keyType._zod.run({value:d,issues:[]},o);if(f instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(f.issues.length){r.issues.push({code:"invalid_key",origin:"record",issues:f.issues.map(E=>Ir(E,o,Dn())),input:d,path:[d],inst:e});continue}let m=f.value;if(m==="__proto__")continue;let h=t.valueType._zod.run({value:i[d],issues:[]},o);h instanceof Promise?s.push(h.then(E=>{E.issues.length&&r.issues.push(...Or(d,E.issues)),r.value[m]=E.value})):(h.issues.length&&r.issues.push(...Or(d,h.issues)),r.value[m]=h.value)}let u;for(let d in i)if(!l.has(d))if(t.mode==="loose"){if(d==="__proto__")continue;r.value[d]=i[d]}else u=u!=null?u:[],u.push(d);u&&u.length>0&&r.issues.push({code:"unrecognized_keys",input:i,inst:e,keys:u,continue:!0})}else{r.value=n?n.alloc(e,r,{},o):{};let l;for(let u of Reflect.ownKeys(i)){if(u==="__proto__"||!Object.prototype.propertyIsEnumerable.call(i,u))continue;let d=t.keyType._zod.run({value:u,issues:[]},o);if(d instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof u=="string"&&bu.test(u)&&d.issues.length){let E=t.keyType._zod.run({value:Number(u),issues:[]},o);if(E instanceof Promise)throw new Error("Async schemas not supported in object keys currently");E.issues.length===0&&(d=E)}if(d.issues.length){t.mode==="loose"?r.value[u]=i[u]:a?(l=l!=null?l:[],l.push(u)):r.issues.push({code:"invalid_key",origin:"record",issues:d.issues.map(E=>Ir(E,o,Dn())),input:u,path:[u],inst:e});continue}let m=d.value;if(m==="__proto__")continue;let h=t.valueType._zod.run({value:i[u],issues:[]},o);h instanceof Promise?s.push(h.then(E=>{E.issues.length&&r.issues.push(...Or(u,E.issues)),r.value[m]=E.value})):(h.issues.length&&r.issues.push(...Or(u,h.issues)),r.value[m]=h.value)}l&&l.length>0&&r.issues.push({code:"unrecognized_keys",input:i,inst:e,keys:l,continue:!0})}return s.length?Promise.all(s).then(()=>r):r}}),Hw=I("$ZodEnum",(e,t)=>{De.init(e,t);let n=qa(t.entries),r=new Set(n);e._zod.values=r,_e(e,"pattern",o=>{let i=qa(o.def.entries).filter(s=>oE.has(typeof s));return new RegExp(i.length?`^(${i.map(s=>Bo(s.toString())).join("|")})$`:"^[^\\s\\S]$")}),e._zod.parse=(o,i)=>{let s=o.value;return r.has(s)||o.issues.push({code:"invalid_value",values:n,input:s,inst:e}),o}}),Fw=I("$ZodLiteral",(e,t)=>{De.init(e,t);let n=new Set(t.values);e._zod.values=n,_e(e,"pattern",r=>{let o=r.def.values;return new RegExp(o.length?`^(${o.map(i=>typeof i=="string"?Bo(i):i?Bo(i.toString()):String(i)).join("|")})$`:"^[^\\s\\S]$")}),e._zod.parse=(r,o)=>{let i=r.value;return n.has(i)||r.issues.push({code:"invalid_value",values:t.values,input:i,inst:e}),r}}),Bw=I("$ZodTransform",(e,t)=>{var n;De.init(e,t),e._zod.optin="optional",(n=nn.memoizer)==null||n.guard(e),e._zod.parse=(r,o)=>{if(o.direction==="backward")throw new nc(e.constructor.name);let i=t.transform(r.value,r);if(o.async)return(i instanceof Promise?i:Promise.resolve(i)).then(a=>(r.value=a,r));if(i instanceof Promise)throw new Cr;return r.value=i,r}});NE=I("$ZodOptional",(e,t)=>{De.init(e,t),_e(e,"optin",n=>n.def.innerType._zod.optin==="defaulted"?"defaulted":"optional"),e._zod.optout="optional",_e(e,"values",n=>{let r=n.def.innerType._zod.values;return r?new Set([...r,void 0]):void 0}),_e(e,"pattern",n=>{let r=n.def.innerType._zod.pattern;return r?new RegExp(`^(${fu(r.source)})?$`):void 0}),e._zod.parse=(n,r)=>{if(n.value===void 0){if(t.innerType._zod.optin!=="defaulted")return n;let o=t.innerType._zod.run({value:n.value,issues:[]},r);return o instanceof Promise?o.then(i=>Ky(n,i)):Ky(n,o)}return t.innerType._zod.run(n,r)}}),Gw=I("$ZodExactOptional",(e,t)=>{NE.init(e,t),_e(e,"values",n=>n.def.innerType._zod.values),_e(e,"pattern",n=>n.def.innerType._zod.pattern),e._zod.parse=(n,r)=>t.innerType._zod.run(n,r)}),Vw=I("$ZodNullable",(e,t)=>{De.init(e,t),_e(e,"optin",n=>n.def.innerType._zod.optin),_e(e,"optout",n=>n.def.innerType._zod.optout),_e(e,"pattern",n=>{let r=n.def.innerType._zod.pattern;return r?new RegExp(`^(${fu(r.source)}|null)$`):void 0}),_e(e,"values",n=>n.def.innerType._zod.values?new Set([...n.def.innerType._zod.values,null]):void 0),e._zod.parse=(n,r)=>n.value===null?n:t.innerType._zod.run(n,r)}),jw=I("$ZodDefault",(e,t)=>{De.init(e,t),e._zod.optin="defaulted",_e(e,"values",n=>n.def.innerType._zod.values),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);if(n.value===void 0)return n.value=t.defaultValue,n;let o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(i=>Zy(i,t)):Zy(o,t)}});Kw=I("$ZodPrefault",(e,t)=>{De.init(e,t),e._zod.optin="defaulted",_e(e,"values",n=>n.def.innerType._zod.values),e._zod.parse=(n,r)=>(r.direction==="backward"||n.value===void 0&&(n.value=t.defaultValue),t.innerType._zod.run(n,r))}),Zw=I("$ZodNonOptional",(e,t)=>{De.init(e,t),_e(e,"values",n=>{let r=n.def.innerType._zod.values;return r?new Set([...r].filter(o=>o!==void 0)):void 0}),e._zod.parse=(n,r)=>{let o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(i=>Wy(i,e)):Wy(o,e)}});Ww=I("$ZodCatch",(e,t)=>{De.init(e,t),_e(e,"optin",n=>n.def.innerType._zod.optin==="defaulted"?"defaulted":"optional"),_e(e,"optout",n=>n.def.innerType._zod.optout),_e(e,"values",n=>n.def.innerType._zod.values),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);let o=t.innerType._zod.run({value:n.value,issues:[]},r);return o instanceof Promise?o.then(i=>Yy(n,i,t,r)):Yy(n,o,t,r)}}),RE=I("$ZodPipe",(e,t)=>{De.init(e,t),_e(e,"values",n=>n.def.in._zod.values),_e(e,"optin",n=>n.def.in._zod.optin),_e(e,"optout",n=>n.def.out._zod.optout),_e(e,"propValues",n=>n.def.in._zod.propValues),e._zod.parse=(n,r)=>{if(r.direction==="backward"){let i=t.out._zod.run(n,r);return i instanceof Promise?i.then(s=>gf(s,t.in,r)):gf(i,t.in,r)}let o=t.in._zod.run(n,r);return o instanceof Promise?o.then(i=>gf(i,t.out,r)):gf(o,t.out,r)}});Yw=I("$ZodPreprocess",(e,t)=>{RE.init(e,t)}),Xw=I("$ZodReadonly",(e,t)=>{De.init(e,t),_e(e,"propValues",n=>n.def.innerType._zod.propValues),_e(e,"values",n=>n.def.innerType._zod.values),_e(e,"optin",n=>{var r,o;return(o=(r=n.def.innerType)==null?void 0:r._zod)==null?void 0:o.optin}),_e(e,"optout",n=>{var r,o;return(o=(r=n.def.innerType)==null?void 0:r._zod)==null?void 0:o.optout}),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);let o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(Xy):Xy(o)}});qw=I("$ZodLazy",(e,t)=>{De.init(e,t),eE(e._zod,"innerType",()=>{let n=t;return n._cachedInner||(n._cachedInner=t.getter()),n._cachedInner}),_e(e,"pattern",n=>{var r,o;return(o=(r=n.innerType)==null?void 0:r._zod)==null?void 0:o.pattern}),_e(e,"propValues",n=>{var r,o;return(o=(r=n.innerType)==null?void 0:r._zod)==null?void 0:o.propValues}),_e(e,"optin",n=>{var r,o,i;return(i=(o=(r=n.innerType)==null?void 0:r._zod)==null?void 0:o.optin)!=null?i:void 0}),_e(e,"optout",n=>{var r,o,i;return(i=(o=(r=n.innerType)==null?void 0:r._zod)==null?void 0:o.optout)!=null?i:void 0}),e._zod.parse=(n,r)=>e._zod.innerType._zod.run(n,r)}),Jw=I("$ZodCustom",(e,t)=>{zt.init(e,t),De.init(e,t),e._zod.parse=(n,r)=>n,e._zod.check=n=>{let r=n.value,o=t.fn(r);if(o instanceof Promise)return o.then(i=>qy(i,n,r,e));qy(o,n,r,e)}})});function ev(e){return e!==null&&typeof e=="object"}function IE(e){return e.map(t=>t.path?{...t,path:t.path.slice()}:{...t})}function yf(e,t,n){var d;let r=tv.get(e);if(r!==void 0)return r?Tu:Su;if(t.has(e))return Tu;t.add(e);let o=Su,i=f=>{if(o!==Tu&&(f!=null&&f._zod)){let m=yf(f,t,n);m>o&&(o=m)}},s=(f,m)=>{var E;let h=Su;for(let _ of Reflect.ownKeys(f)){let A=Object.getOwnPropertyDescriptor(f,_);if(m&&!A.enumerable)continue;let v=A.get?Af:(E=A.value)!=null&&E._zod?yf(A.value,t,n):Su;v>h&&(h=v)}return h},a=f=>{f>o&&(o=f)},l=e._zod.def,u=l.type;switch(u){case"object":{let f=ec(l);a(f?s(f,!0):Af),i(l.catchall);break}case"array":i(l.element);break;case"tuple":for(let f of l.items)i(f);i(l.rest);break;case"record":case"map":i(l.keyType),i(l.valueType);break;case"set":i(l.valueType);break;case"union":for(let f of l.options)i(f);break;case"intersection":i(l.left),i(l.right);break;case"optional":case"nullable":case"default":case"prefault":case"catch":case"readonly":case"nonoptional":case"promise":case"success":i(l.innerType);break;case"pipe":i(l.in),i(l.out);break;case"function":i(l.input),i(l.output);break;case"lazy":{let f=(d=l._cachedInner)!=null?d:n?e._zod.innerType:void 0;a(f?yf(f,t,!1):Af);break}case"template_literal":case"string":case"number":case"int":case"boolean":case"bigint":case"symbol":case"undefined":case"null":case"void":case"never":case"any":case"unknown":case"date":case"nan":case"enum":case"literal":case"file":case"transform":case"custom":break;default:for(let f in l){let m=Object.getOwnPropertyDescriptor(l,f);if(!m||m.get)continue;let h=m.value;if(!(!h||typeof h!="object")){if(h._zod)i(h);else if(Array.isArray(h))for(let E of h)i(E)}}}return t.delete(e),CU(e,o)}function CU(e,t){return t!==Af&&tv.set(e,t===Tu),t}function LU(e,t){let n=e.buckets.get(t);return n||(n=new WeakMap,e.buckets.set(t,n)),n}function nv(){return $U}function kU(e,t){var r;let n=(r=e[LE])==null?void 0:r.backEdges;return n!==void 0&&ev(t)&&n.has(t)}var CE,LE,Qw,tv,Su,Af,Tu,Tf,xf,$U,rv=y(()=>{Sn();CE=class extends Error{constructor(){super("Cannot parse a reference cycle that closes through a transform"),this.name="ZodCyclicError"}},LE="~memo",Qw=[];tv=new WeakMap,Su=0,Af=1,Tu=2;xf=[],$U={alloc(e,t,n){let r=Tf;if(!r)return n;Tf=void 0;let o={value:n,issues:null};return r.set(t.value,o),xf.push(o),n},guard(e){var n;var t;(n=(t=e._zod).deferred)!=null||(t.deferred=[]),e._zod.deferred.push(()=>{let r=e._zod.parse,o=(i,s)=>{if(s.direction!=="backward"&&kU(s,i.value))throw new CE;return r(i,s)};e._zod.parse=o,e._zod.run===r&&(e._zod.run=o)})},attach(e){var s;var t;let n,r=!1,o,i;(s=(t=e._zod).deferred)!=null||(t.deferred=[]),e._zod.deferred.push(()=>{let a=e._zod.parse,l=(u,d)=>{var N;if(n===void 0){let O=yf(e,new Set,!1);if(O===Su)return e._zod.parse=a,e._zod.run===l&&(e._zod.run=a),a(u,d);O===Tu||r?n=!0:r=!0}let f=u.value;if(!ev(f))return a(u,d);let m=d[LE];m||(m={buckets:new WeakMap,backEdges:void 0},d[LE]=m);let h;o===d?h=i:(h=LU(m,e),o=d,i=h);let E=h.get(f);if(E)return u.value=E.value,E.issues?E.issues.length&&u.issues.push(...IE(E.issues)):(u.memo=!0,(N=m.backEdges)!=null||(m.backEdges=new WeakSet),m.backEdges.add(E.value)),u;Tf=h;let _=xf.length,A=a(u,d);Tf=void 0;let v=xf.length>_?xf.pop():void 0;return A instanceof Promise?A.then(O=>(v&&(v.issues=O.issues.length?IE(O.issues):Qw),O)):(v&&(v.issues=A.issues.length?IE(A.issues):Qw),A)};e._zod.parse=l,e._zod.run===a&&(e._zod.run=l)})}}});function ov(){return{localeError:zU()}}var zU,iv=y(()=>{Sn();zU=()=>{let e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"},map:{unit:"entries",verb:"to have"}};function t(i){var s;return(s=e[i])!=null?s:null}let n={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",mac:"MAC address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",currency_code:"currency code",credit_card:"credit card number",iban:"IBAN",jwt:"JWT",template_literal:"input"},r={nan:"NaN"};function o(i,s){var a;return i==="number"&&typeof s=="number"&&!Number.isFinite(s)?String(s):(a=r[i])!=null?a:i}return i=>{var s,a,l,u;switch(i.code){case"invalid_type":{let d=o(i.expected),f=aE(i.input),m=o(f,i.input);return`Invalid input: expected ${d}, received ${m}`}case"invalid_value":return i.values.length===1?`Invalid input: expected ${ef(i.values[0])}`:`Invalid option: expected one of ${Jp(i.values,"|")}`;case"too_big":{let d=i.exact?"exactly ":i.inclusive?"<=":"<",f=t(i.origin);return f?`Too big: expected ${(s=i.origin)!=null?s:"value"} to have ${d}${i.maximum.toString()} ${(a=f.unit)!=null?a:"elements"}`:`Too big: expected ${(l=i.origin)!=null?l:"value"} to be ${d}${i.maximum.toString()}`}case"too_small":{let d=i.exact?"exactly ":i.inclusive?">=":">",f=t(i.origin);return f?`Too small: expected ${i.origin} to have ${d}${i.minimum.toString()} ${f.unit}`:`Too small: expected ${i.origin} to be ${d}${i.minimum.toString()}`}case"invalid_format":{let d=i;return d.format==="starts_with"?`Invalid string: must start with "${d.prefix}"`:d.format==="ends_with"?`Invalid string: must end with "${d.suffix}"`:d.format==="includes"?`Invalid string: must include "${d.includes}"`:d.format==="regex"?`Invalid string: must match pattern ${d.pattern}`:`Invalid ${(u=n[d.format])!=null?u:i.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${i.divisor}`;case"unrecognized_keys":return`Unrecognized key${i.keys.length>1?"s":""}: ${Jp(i.keys,", ")}`;case"invalid_key":return`Invalid key in ${i.origin}`;case"invalid_union":return i.options&&Array.isArray(i.options)&&i.options.length>0?`Invalid discriminator value. Expected ${i.options.map(f=>`'${f}'`).join(" | ")}`:i.inclusive===!1?"Invalid input: more than one option matched":"Invalid input";case"invalid_element":return`Invalid value in ${i.origin}`;default:return"Invalid input"}}}});function DU(){return new $E}var sv,$E,av,$s,kE=y(()=>{$E=class{constructor(){this._map=new WeakMap,this._idmap=new Map}add(t,...n){let r=n[0];return this._map.set(t,r),r&&typeof r=="object"&&"id"in r&&this._idmap.set(r.id,t),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(t){let n=this._map.get(t);return n&&typeof n=="object"&&"id"in n&&this._idmap.delete(n.id),this._map.delete(t),this}get(t){var r;let n=t._zod.parent;if(n){let o={...(r=this.get(n))!=null?r:{}};delete o.id;let i={...o,...this._map.get(t)};return Object.keys(i).length?i:void 0}return this._map.get(t)}has(t){return this._map.has(t)}};(av=(sv=globalThis).__zod_globalRegistry)!=null||(sv.__zod_globalRegistry=DU());$s=globalThis.__zod_globalRegistry});var cv=y(()=>{});function lv(e){return e.checks&&(e.checks=[...e.checks]),e}function uv(e,t){return new e(lv({type:"string",...te(t)}))}function dv(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...te(t)})}function pv(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...te(t)})}function fv(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...te(t)})}function hv(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...te(t)})}function mv(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...te(t)})}function gv(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...te(t)})}function Ev(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...te(t)})}function bv(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...te(t)})}function _v(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...te(t)})}function Sv(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...te(t)})}function Tv(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...te(t)})}function xv(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...te(t)})}function Av(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...te(t)})}function yv(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...te(t)})}function wv(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...te(t)})}function vv(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...te(t)})}function Nv(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...te(t)})}function Rv(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...te(t)})}function Ov(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...te(t)})}function Iv(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...te(t)})}function Cv(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...te(t)})}function Lv(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...te(t)})}function $v(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...te(t)})}function kv(e,t){return new e({type:"string",format:"date",check:"string_format",...te(t)})}function zv(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...te(t)})}function Dv(e,t){return new e({type:"string",format:"duration",check:"string_format",...te(t)})}function Pv(e,t){return new e(lv({type:"number",checks:[],...te(t)}))}function Mv(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...te(t)})}function Uv(e,t){return new e({type:"boolean",...te(t)})}function Hv(e,t){return new e({type:"undefined",...te(t)})}function Fv(e,t){return new e({type:"null",...te(t)})}function Bv(e){return new e({type:"unknown"})}function Gv(e,t){return new e({type:"never",...te(t)})}function wf(e,t){return new bE({check:"less_than",...te(t),value:e,inclusive:!1})}function xu(e,t){return new bE({check:"less_than",...te(t),value:e,inclusive:!0})}function vf(e,t){return new _E({check:"greater_than",...te(t),value:e,inclusive:!1})}function Au(e,t){return new _E({check:"greater_than",...te(t),value:e,inclusive:!0})}function Nf(e,t){return new wy({check:"multiple_of",...te(t),value:e})}function Rf(e,t){return new Ny({check:"max_length",...te(t),maximum:e})}function rc(e,t){return new Ry({check:"min_length",...te(t),minimum:e})}function Of(e,t){return new Oy({check:"length_equals",...te(t),length:e})}function zE(e,t){return new Iy({check:"string_format",format:"regex",...te(t),pattern:e})}function DE(e){return new Cy({check:"string_format",format:"lowercase",...te(e)})}function PE(e){return new Ly({check:"string_format",format:"uppercase",...te(e)})}function ME(e,t){return new $y({check:"string_format",format:"includes",...te(t),includes:e})}function UE(e,t){return new ky({check:"string_format",format:"starts_with",...te(t),prefix:e})}function HE(e,t){return new zy({check:"string_format",format:"ends_with",...te(t),suffix:e})}function Ci(e){return new Dy({check:"overwrite",tx:e})}function FE(e){return Ci(t=>t.normalize(e))}function BE(){return Ci(e=>e.trim())}function GE(){return Ci(e=>e.toLowerCase())}function VE(){return Ci(e=>e.toUpperCase())}function jE(){return Ci(e=>nE(e))}function Vv(e,t,n){return new e({type:"array",element:t,...te(n)})}function jv(e,t,n){return new e({type:"custom",check:"custom",fn:t,...te(n)})}function Kv(e,t){let n=PU(r=>(r.addIssue=o=>{var i,s,a;if(typeof o=="string")r.issues.push(tc(o,r.value,n._zod.def));else{let l=o;l.fatal&&(l.continue=!1),(i=l.code)!=null||(l.code="custom"),"input"in l||(l.input=r.value),(s=l.inst)!=null||(l.inst=n),(a=l.continue)!=null||(l.continue=!n._zod.def.abort),r.issues.push(tc(l))}},e(r.value,r)),t);return n}function PU(e,t){let n=new zt({check:"custom",...te(t)});return n._zod.check=e,n}var Zv=y(()=>{hf();Sn()});function yu(e,...t){for(let n of t)for(let r of Reflect.ownKeys(n))Object.prototype.propertyIsEnumerable.call(n,r)&&kn(e,r,n[r]);return e}function ZE(e){var n,r,o,i,s,a,l,u,d;let t=(n=e==null?void 0:e.target)!=null?n:"draft-2020-12";return t==="draft-4"&&(t="draft-04"),t==="draft-7"&&(t="draft-07"),{processors:(r=e.processors)!=null?r:{},metadataRegistry:(o=e==null?void 0:e.metadata)!=null?o:$s,target:t,unrepresentable:(i=e==null?void 0:e.unrepresentable)!=null?i:"throw",override:(s=e==null?void 0:e.override)!=null?s:(()=>{}),io:(a=e==null?void 0:e.io)!=null?a:"output",counter:0,seen:new Map,sharedDefsExtractedFor:void 0,sharedEmitDoneFor:void 0,cycles:(l=e==null?void 0:e.cycles)!=null?l:"ref",reused:(u=e==null?void 0:e.reused)!=null?u:"inline",intersections:[],deferred:[],external:(d=e==null?void 0:e.external)!=null?d:void 0}}function ro(e,t,n,r,o){let i=typeof t.unrepresentable=="function"?t.unrepresentable({zodSchema:e,path:r.path,message:o}):t.unrepresentable;if(i==="any")return!1;if(i===void 0||i==="throw")throw new Error(o);return Object.assign(n,i),!0}function Ve(e,t,n={path:[],schemaPath:[]}){var d,f,m;var r;let o=e._zod.def,i=t.seen.get(e);if(i)return i.count++,n.schemaPath.includes(e)&&(i.cycle=n.path),i.schema;let s={schema:{},count:1,cycle:void 0,path:n.path};t.seen.set(e,s),t.sharedDefsExtractedFor=void 0,t.sharedEmitDoneFor=void 0;let a=(f=(d=e._zod).toJSONSchema)==null?void 0:f.call(d);if(a)s.schema=a;else{let h={...n,schemaPath:[...n.schemaPath,e],path:n.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(t,s.schema,h);else{let _=s.schema,A=t.processors[o.type];if(!A)throw new Error(`[toJSONSchema]: Non-representable type encountered: ${o.type}`);A(e,t,_,h)}let E=e._zod.parent;E&&(s.ref||(s.ref=E),Ve(E,t,h),t.seen.get(E).isParent=!0)}let l=t.metadataRegistry.get(e);return l&&yu(s.schema,l),t.io==="input"&&rn(e)&&(delete s.schema.examples,delete s.schema.default),t.io==="input"&&"_prefault"in s.schema&&((m=(r=s.schema).default)!=null||(r.default=s.schema._prefault)),delete s.schema._prefault,t.seen.get(e).schema}function Wv(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}function WE(e,t){var s,a,l,u;let n=e.seen.get(t);if(!n)throw new Error("Unprocessed schema. This is a bug in Zod.");if(e.external&&e.sharedDefsExtractedFor===e.external)return;let r=new Map;for(let d of e.seen.entries()){let f=(s=e.metadataRegistry.get(d[0]))==null?void 0:s.id;if(f){let m=r.get(f);if(m&&m!==d[0])throw new Error(`Duplicate schema id "${f}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);r.set(f,d[0])}}let o=d=>{var _,A,v,N,O;let f=e.target==="draft-2020-12"?"$defs":"definitions";if(e.external){let k=(_=e.external.registry.get(d[0]))==null?void 0:_.id,j=(A=e.external.uri)!=null?A:(X=>X);if(k)return{ref:j(k)};let Y=(N=(v=d[1].defId)!=null?v:d[1].schema.id)!=null?N:`schema${e.counter++}`;return d[1].defId=Y,{defId:Y,ref:`${j("__shared")}#/${f}/${Wv(Y)}`}}let m="#",h=`${m}/${f}/`;if(d[1]===n&&!d[1].schema.id)return{ref:m};let E=(O=d[1].schema.id)!=null?O:`__schema${e.counter++}`;return{defId:E,ref:h+Wv(E)}},i=d=>{if(d[1].schema.$ref)return;let f=d[1],{ref:m,defId:h}=o(d);f.def={...f.schema},h&&(f.defId=h);let E=f.schema;for(let _ in E)delete E[_];E.$ref=m};if(e.cycles==="throw")for(let d of e.seen.entries()){let f=d[1];if(f.cycle)throw new Error(`Cycle detected: #/${(a=f.cycle)==null?void 0:a.join("/")}/<root>
55
+ `)}return A.write("payload.value = newResult;"),A.write("return payload;"),A.compile()},s,a=Cs,l=!nn.jitless,d=l&&cE.value,f=t.catchall,m;e._zod.parse=(h,E)=>{m!=null||(m=r.value);let S=h.value;return a(S)?l&&d&&(E==null?void 0:E.async)===!1&&E.jitless!==!0?(s||(s=i(t.shape)),h=s(h,E),f?jw([],S,h,E,m,e,(E==null?void 0:E.abortEarly)===!0):h):n(h,E):(h.issues.push({expected:"object",code:"invalid_type",input:S,inst:e}),h)}});CE=I("$ZodUnion",(e,t)=>{De.init(e,t),_e(e,"optin",r=>r.def.options.some(o=>o._zod.optin==="defaulted")?"defaulted":r.def.options.some(o=>o._zod.optin!==void 0)?"optional":void 0),_e(e,"optout",r=>r.def.options.some(o=>o._zod.optout==="optional")?"optional":void 0),_e(e,"values",r=>{if(r.def.options.every(o=>o._zod.values))return new Set(r.def.options.flatMap(o=>Array.from(o._zod.values)))}),_e(e,"pattern",r=>{if(r.def.options.every(o=>o._zod.pattern)){let o=r.def.options.map(i=>i._zod.pattern);return new RegExp(`^(${o.map(i=>Eu(i.source)).join("|")})$`)}});let n=t.options.length===1?t.options[0]._zod.run:null;e._zod.parse=(r,o)=>{if(n)return n(r,o);let i=!1,s=[];for(let a of t.options){let l=a._zod.run({value:r.value,issues:[]},o);if(l instanceof Promise)s.push(l),i=!0;else{if(l.issues.length===0)return l;s.push(l)}}return i?Promise.all(s).then(a=>Jy(a,r,e,o)):Jy(s,r,e,o)}});Zw=I("$ZodDiscriminatedUnion",(e,t)=>{t.inclusive=!1,CE.init(e,t);let n=e._zod.parse;_e(e,"propValues",o=>{var a,l;let i={},s=0;for(let u of o.def.options){let d=u._zod.propValues;if(!d||Object.keys(d).length===0)throw new Error(`Invalid discriminated union option at index "${o.def.options.indexOf(u)}"`);(a=d[o.def.discriminator])!=null&&a.has(void 0)&&s++;for(let[f,m]of Object.entries(d)){Object.prototype.hasOwnProperty.call(i,f)||zn(i,f,new Set);for(let h of m)i[f].add(h)}}return!o.def.unionFallback&&s>1&&((l=i[o.def.discriminator])==null||l.delete(void 0)),i}),t.options.forEach((o,i)=>{let s=nc(o._zod.def);if(s&&!Object.prototype.hasOwnProperty.call(s,t.discriminator))throw new Error(`Invalid discriminated union option at index "${i}"`)});let r=tc(()=>jU(t));e._zod.parse=(o,i)=>{let s=o.value;if(!Cs(s))return o.issues.push({code:"invalid_type",expected:"object",input:s,inst:e}),o;let a=s==null?void 0:s[t.discriminator],l=r.value.get(a);return l&&(a!==void 0||i.direction!=="backward")?l._zod.run(o,i):t.unionFallback||i.direction==="backward"?n(o,i):(o.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,options:Array.from(r.value.keys()).filter(u=>r.value.get(u)!==null),input:s,path:[t.discriminator],inst:e}),o)}}),Ww=I("$ZodIntersection",(e,t)=>{De.init(e,t),e._zod.parse=(n,r)=>{let o=n.value,i=t.left._zod.run({value:o,issues:[]},r),s=t.right._zod.run({value:o,issues:[]},r);return i instanceof Promise||s instanceof Promise?Promise.all([i,s]).then(([l,u])=>Qy(n,l,u)):Qy(n,i,s)}});Yw=I("$ZodTuple",(e,t)=>{De.init(e,t);let n=t.items,r=nn.memoizer;r==null||r.attach(e),e._zod.parse=(o,i)=>{let s=o.value;if(!Array.isArray(s))return o.issues.push({input:s,inst:e,expected:"tuple",code:"invalid_type"}),o;o.value=r?r.alloc(e,o,[],i):[];let a=[],l=ew(n,"optin"),u=ew(n,"optout");if(!t.rest){if(s.length<l)return o.issues.push({code:"too_small",minimum:l,inclusive:!0,input:s,inst:e,origin:"array"}),o;s.length>n.length&&o.issues.push({code:"too_big",maximum:n.length,inclusive:!0,input:s,inst:e,origin:"array"})}let d=new Array(n.length),f=t.rest?i==null?void 0:i.abortEarly:void 0,m=!1;for(let h=0;h<n.length;h++){let E=n[h]._zod.run({value:s[h],issues:[]},i);E instanceof Promise?a.push(E.then(S=>{d[h]=S})):(d[h]=E,f&&!m&&E.issues.length&&(m=Dn(E)))}if(t.rest&&!m){let h=n.length-1,E=s.slice(n.length),S=o.issues.length;for(let A of E){if(f&&o.issues.length!==S){if(Dn(o,S))break;S=o.issues.length}h++;let w=t.rest._zod.run({value:A,issues:[]},i);w instanceof Promise?a.push(w.then(N=>tw(N,o,h))):tw(w,o,h)}}return a.length?Promise.all(a).then(()=>nw(d,o,n,s,u)):nw(d,o,n,s,u)}});Xw=I("$ZodRecord",(e,t)=>{De.init(e,t);let n=nn.memoizer;n==null||n.attach(e),e._zod.parse=(r,o)=>{let i=r.value;if(!Ci(i))return r.issues.push({expected:"record",code:"invalid_type",input:i,inst:e}),r;let s=[],a=t.keyType._zod.values;if(a&&!t.partial){r.value=n?n.alloc(e,r,{},o):{};let l=new Set;for(let d of a)if(typeof d=="string"||typeof d=="number"||typeof d=="symbol"){if(l.add(typeof d=="number"?d.toString():d),d==="__proto__")continue;let f=t.keyType._zod.run({value:d,issues:[]},o);if(f instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(f.issues.length){r.issues.push({code:"invalid_key",origin:"record",issues:f.issues.map(E=>Lr(E,o,Pn())),input:d,path:[d],inst:e});continue}let m=f.value;if(m==="__proto__")continue;let h=t.valueType._zod.run({value:i[d],issues:[]},o);h instanceof Promise?s.push(h.then(E=>{E.issues.length&&r.issues.push(...Cr(d,E.issues)),r.value[m]=E.value})):(h.issues.length&&r.issues.push(...Cr(d,h.issues)),r.value[m]=h.value)}let u;for(let d in i)if(!l.has(d))if(t.mode==="loose"){if(d==="__proto__")continue;r.value[d]=i[d]}else u=u!=null?u:[],u.push(d);u&&u.length>0&&r.issues.push({code:"unrecognized_keys",input:i,inst:e,keys:u,continue:!0})}else{r.value=n?n.alloc(e,r,{},o):{};let l;for(let u of Reflect.ownKeys(i)){if(u==="__proto__"||!Object.prototype.propertyIsEnumerable.call(i,u))continue;let d=t.keyType._zod.run({value:u,issues:[]},o);if(d instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof u=="string"&&xu.test(u)&&d.issues.length){let E=t.keyType._zod.run({value:Number(u),issues:[]},o);if(E instanceof Promise)throw new Error("Async schemas not supported in object keys currently");E.issues.length===0&&(d=E)}if(d.issues.length){t.mode==="loose"?r.value[u]=i[u]:a?(l=l!=null?l:[],l.push(u)):r.issues.push({code:"invalid_key",origin:"record",issues:d.issues.map(E=>Lr(E,o,Pn())),input:u,path:[u],inst:e});continue}let m=d.value;if(m==="__proto__")continue;let h=t.valueType._zod.run({value:i[u],issues:[]},o);h instanceof Promise?s.push(h.then(E=>{E.issues.length&&r.issues.push(...Cr(u,E.issues)),r.value[m]=E.value})):(h.issues.length&&r.issues.push(...Cr(u,h.issues)),r.value[m]=h.value)}l&&l.length>0&&r.issues.push({code:"unrecognized_keys",input:i,inst:e,keys:l,continue:!0})}return s.length?Promise.all(s).then(()=>r):r}}),qw=I("$ZodEnum",(e,t)=>{De.init(e,t);let n=Qa(t.entries),r=new Set(n);e._zod.values=r,_e(e,"pattern",o=>{let i=Qa(o.def.entries).filter(s=>lE.has(typeof s));return new RegExp(i.length?`^(${i.map(s=>Vo(s.toString())).join("|")})$`:"^[^\\s\\S]$")}),e._zod.parse=(o,i)=>{let s=o.value;return r.has(s)||o.issues.push({code:"invalid_value",values:n,input:s,inst:e}),o}}),Jw=I("$ZodLiteral",(e,t)=>{De.init(e,t);let n=new Set(t.values);e._zod.values=n,_e(e,"pattern",r=>{let o=r.def.values;return new RegExp(o.length?`^(${o.map(i=>typeof i=="string"?Vo(i):i?Vo(i.toString()):String(i)).join("|")})$`:"^[^\\s\\S]$")}),e._zod.parse=(r,o)=>{let i=r.value;return n.has(i)||r.issues.push({code:"invalid_value",values:t.values,input:i,inst:e}),r}}),Qw=I("$ZodTransform",(e,t)=>{var n;De.init(e,t),e._zod.optin="optional",(n=nn.memoizer)==null||n.guard(e),e._zod.parse=(r,o)=>{if(o.direction==="backward")throw new oc(e.constructor.name);let i=t.transform(r.value,r);if(o.async)return(i instanceof Promise?i:Promise.resolve(i)).then(a=>(r.value=a,r));if(i instanceof Promise)throw new $r;return r.value=i,r}});LE=I("$ZodOptional",(e,t)=>{De.init(e,t),_e(e,"optin",n=>n.def.innerType._zod.optin==="defaulted"?"defaulted":"optional"),e._zod.optout="optional",_e(e,"values",n=>{let r=n.def.innerType._zod.values;return r?new Set([...r,void 0]):void 0}),_e(e,"pattern",n=>{let r=n.def.innerType._zod.pattern;return r?new RegExp(`^(${Eu(r.source)})?$`):void 0}),e._zod.parse=(n,r)=>{if(n.value===void 0){if(t.innerType._zod.optin!=="defaulted")return n;let o=t.innerType._zod.run({value:n.value,issues:[]},r);return o instanceof Promise?o.then(i=>rw(n,i)):rw(n,o)}return t.innerType._zod.run(n,r)}}),ev=I("$ZodExactOptional",(e,t)=>{LE.init(e,t),_e(e,"values",n=>n.def.innerType._zod.values),_e(e,"pattern",n=>n.def.innerType._zod.pattern),e._zod.parse=(n,r)=>t.innerType._zod.run(n,r)}),tv=I("$ZodNullable",(e,t)=>{De.init(e,t),_e(e,"optin",n=>n.def.innerType._zod.optin),_e(e,"optout",n=>n.def.innerType._zod.optout),_e(e,"pattern",n=>{let r=n.def.innerType._zod.pattern;return r?new RegExp(`^(${Eu(r.source)}|null)$`):void 0}),_e(e,"values",n=>n.def.innerType._zod.values?new Set([...n.def.innerType._zod.values,null]):void 0),e._zod.parse=(n,r)=>n.value===null?n:t.innerType._zod.run(n,r)}),nv=I("$ZodDefault",(e,t)=>{De.init(e,t),e._zod.optin="defaulted",_e(e,"values",n=>n.def.innerType._zod.values),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);if(n.value===void 0)return n.value=t.defaultValue,n;let o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(i=>ow(i,t)):ow(o,t)}});rv=I("$ZodPrefault",(e,t)=>{De.init(e,t),e._zod.optin="defaulted",_e(e,"values",n=>n.def.innerType._zod.values),e._zod.parse=(n,r)=>(r.direction==="backward"||n.value===void 0&&(n.value=t.defaultValue),t.innerType._zod.run(n,r))}),ov=I("$ZodNonOptional",(e,t)=>{De.init(e,t),_e(e,"values",n=>{let r=n.def.innerType._zod.values;return r?new Set([...r].filter(o=>o!==void 0)):void 0}),e._zod.parse=(n,r)=>{let o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(i=>iw(i,e)):iw(o,e)}});iv=I("$ZodCatch",(e,t)=>{De.init(e,t),_e(e,"optin",n=>n.def.innerType._zod.optin==="defaulted"?"defaulted":"optional"),_e(e,"optout",n=>n.def.innerType._zod.optout),_e(e,"values",n=>n.def.innerType._zod.values),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);let o=t.innerType._zod.run({value:n.value,issues:[]},r);return o instanceof Promise?o.then(i=>sw(n,i,t,r)):sw(n,o,t,r)}}),$E=I("$ZodPipe",(e,t)=>{De.init(e,t),_e(e,"values",n=>n.def.in._zod.values),_e(e,"optin",n=>n.def.in._zod.optin),_e(e,"optout",n=>n.def.out._zod.optout),_e(e,"propValues",n=>n.def.in._zod.propValues),e._zod.parse=(n,r)=>{if(r.direction==="backward"){let i=t.out._zod.run(n,r);return i instanceof Promise?i.then(s=>Sf(s,t.in,r)):Sf(i,t.in,r)}let o=t.in._zod.run(n,r);return o instanceof Promise?o.then(i=>Sf(i,t.out,r)):Sf(o,t.out,r)}});sv=I("$ZodPreprocess",(e,t)=>{$E.init(e,t)}),av=I("$ZodReadonly",(e,t)=>{De.init(e,t),_e(e,"propValues",n=>n.def.innerType._zod.propValues),_e(e,"values",n=>n.def.innerType._zod.values),_e(e,"optin",n=>{var r,o;return(o=(r=n.def.innerType)==null?void 0:r._zod)==null?void 0:o.optin}),_e(e,"optout",n=>{var r,o;return(o=(r=n.def.innerType)==null?void 0:r._zod)==null?void 0:o.optout}),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);let o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(aw):aw(o)}});cv=I("$ZodLazy",(e,t)=>{De.init(e,t),iE(e._zod,"innerType",()=>{let n=t;return n._cachedInner||(n._cachedInner=t.getter()),n._cachedInner}),_e(e,"pattern",n=>{var r,o;return(o=(r=n.innerType)==null?void 0:r._zod)==null?void 0:o.pattern}),_e(e,"propValues",n=>{var r,o;return(o=(r=n.innerType)==null?void 0:r._zod)==null?void 0:o.propValues}),_e(e,"optin",n=>{var r,o,i;return(i=(o=(r=n.innerType)==null?void 0:r._zod)==null?void 0:o.optin)!=null?i:void 0}),_e(e,"optout",n=>{var r,o,i;return(i=(o=(r=n.innerType)==null?void 0:r._zod)==null?void 0:o.optout)!=null?i:void 0}),e._zod.parse=(n,r)=>e._zod.innerType._zod.run(n,r)}),lv=I("$ZodCustom",(e,t)=>{Pt.init(e,t),De.init(e,t),e._zod.parse=(n,r)=>n,e._zod.check=n=>{let r=n.value,o=t.fn(r);if(o instanceof Promise)return o.then(i=>cw(i,n,r,e));cw(o,n,r,e)}})});function dv(e){return e!==null&&typeof e=="object"}function zE(e){return e.map(t=>t.path?{...t,path:t.path.slice()}:{...t})}function Rf(e,t,n){var d;let r=pv.get(e);if(r!==void 0)return r?wu:yu;if(t.has(e))return wu;t.add(e);let o=yu,i=f=>{if(o!==wu&&(f!=null&&f._zod)){let m=Rf(f,t,n);m>o&&(o=m)}},s=(f,m)=>{var E;let h=yu;for(let S of Reflect.ownKeys(f)){let A=Object.getOwnPropertyDescriptor(f,S);if(m&&!A.enumerable)continue;let w=A.get?Nf:(E=A.value)!=null&&E._zod?Rf(A.value,t,n):yu;w>h&&(h=w)}return h},a=f=>{f>o&&(o=f)},l=e._zod.def,u=l.type;switch(u){case"object":{let f=nc(l);a(f?s(f,!0):Nf),i(l.catchall);break}case"array":i(l.element);break;case"tuple":for(let f of l.items)i(f);i(l.rest);break;case"record":case"map":i(l.keyType),i(l.valueType);break;case"set":i(l.valueType);break;case"union":for(let f of l.options)i(f);break;case"intersection":i(l.left),i(l.right);break;case"optional":case"nullable":case"default":case"prefault":case"catch":case"readonly":case"nonoptional":case"promise":case"success":i(l.innerType);break;case"pipe":i(l.in),i(l.out);break;case"function":i(l.input),i(l.output);break;case"lazy":{let f=(d=l._cachedInner)!=null?d:n?e._zod.innerType:void 0;a(f?Rf(f,t,!1):Nf);break}case"template_literal":case"string":case"number":case"int":case"boolean":case"bigint":case"symbol":case"undefined":case"null":case"void":case"never":case"any":case"unknown":case"date":case"nan":case"enum":case"literal":case"file":case"transform":case"custom":break;default:for(let f in l){let m=Object.getOwnPropertyDescriptor(l,f);if(!m||m.get)continue;let h=m.value;if(!(!h||typeof h!="object")){if(h._zod)i(h);else if(Array.isArray(h))for(let E of h)i(E)}}}return t.delete(e),KU(e,o)}function KU(e,t){return t!==Nf&&pv.set(e,t===wu),t}function ZU(e,t){let n=e.buckets.get(t);return n||(n=new WeakMap,e.buckets.set(t,n)),n}function fv(){return WU}function YU(e,t){var r;let n=(r=e[PE])==null?void 0:r.backEdges;return n!==void 0&&dv(t)&&n.has(t)}var DE,PE,uv,pv,yu,Nf,wu,wf,vf,WU,hv=y(()=>{Sn();DE=class extends Error{constructor(){super("Cannot parse a reference cycle that closes through a transform"),this.name="ZodCyclicError"}},PE="~memo",uv=[];pv=new WeakMap,yu=0,Nf=1,wu=2;vf=[],WU={alloc(e,t,n){let r=wf;if(!r)return n;wf=void 0;let o={value:n,issues:null};return r.set(t.value,o),vf.push(o),n},guard(e){var n;var t;(n=(t=e._zod).deferred)!=null||(t.deferred=[]),e._zod.deferred.push(()=>{let r=e._zod.parse,o=(i,s)=>{if(s.direction!=="backward"&&YU(s,i.value))throw new DE;return r(i,s)};e._zod.parse=o,e._zod.run===r&&(e._zod.run=o)})},attach(e){var s;var t;let n,r=!1,o,i;(s=(t=e._zod).deferred)!=null||(t.deferred=[]),e._zod.deferred.push(()=>{let a=e._zod.parse,l=(u,d)=>{var N;if(n===void 0){let O=Rf(e,new Set,!1);if(O===yu)return e._zod.parse=a,e._zod.run===l&&(e._zod.run=a),a(u,d);O===wu||r?n=!0:r=!0}let f=u.value;if(!dv(f))return a(u,d);let m=d[PE];m||(m={buckets:new WeakMap,backEdges:void 0},d[PE]=m);let h;o===d?h=i:(h=ZU(m,e),o=d,i=h);let E=h.get(f);if(E)return u.value=E.value,E.issues?E.issues.length&&u.issues.push(...zE(E.issues)):(u.memo=!0,(N=m.backEdges)!=null||(m.backEdges=new WeakSet),m.backEdges.add(E.value)),u;wf=h;let S=vf.length,A=a(u,d);wf=void 0;let w=vf.length>S?vf.pop():void 0;return A instanceof Promise?A.then(O=>(w&&(w.issues=O.issues.length?zE(O.issues):uv),O)):(w&&(w.issues=A.issues.length?zE(A.issues):uv),A)};e._zod.parse=l,e._zod.run===a&&(e._zod.run=l)})}}});function mv(){return{localeError:XU()}}var XU,gv=y(()=>{Sn();XU=()=>{let e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"},map:{unit:"entries",verb:"to have"}};function t(i){var s;return(s=e[i])!=null?s:null}let n={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",mac:"MAC address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",currency_code:"currency code",credit_card:"credit card number",iban:"IBAN",jwt:"JWT",template_literal:"input"},r={nan:"NaN"};function o(i,s){var a;return i==="number"&&typeof s=="number"&&!Number.isFinite(s)?String(s):(a=r[i])!=null?a:i}return i=>{var s,a,l,u;switch(i.code){case"invalid_type":{let d=o(i.expected),f=pE(i.input),m=o(f,i.input);return`Invalid input: expected ${d}, received ${m}`}case"invalid_value":return i.values.length===1?`Invalid input: expected ${of(i.values[0])}`:`Invalid option: expected one of ${nf(i.values,"|")}`;case"too_big":{let d=i.exact?"exactly ":i.inclusive?"<=":"<",f=t(i.origin);return f?`Too big: expected ${(s=i.origin)!=null?s:"value"} to have ${d}${i.maximum.toString()} ${(a=f.unit)!=null?a:"elements"}`:`Too big: expected ${(l=i.origin)!=null?l:"value"} to be ${d}${i.maximum.toString()}`}case"too_small":{let d=i.exact?"exactly ":i.inclusive?">=":">",f=t(i.origin);return f?`Too small: expected ${i.origin} to have ${d}${i.minimum.toString()} ${f.unit}`:`Too small: expected ${i.origin} to be ${d}${i.minimum.toString()}`}case"invalid_format":{let d=i;return d.format==="starts_with"?`Invalid string: must start with "${d.prefix}"`:d.format==="ends_with"?`Invalid string: must end with "${d.suffix}"`:d.format==="includes"?`Invalid string: must include "${d.includes}"`:d.format==="regex"?`Invalid string: must match pattern ${d.pattern}`:`Invalid ${(u=n[d.format])!=null?u:i.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${i.divisor}`;case"unrecognized_keys":return`Unrecognized key${i.keys.length>1?"s":""}: ${nf(i.keys,", ")}`;case"invalid_key":return`Invalid key in ${i.origin}`;case"invalid_union":return i.options&&Array.isArray(i.options)&&i.options.length>0?`Invalid discriminator value. Expected ${i.options.map(f=>`'${f}'`).join(" | ")}`:i.inclusive===!1?"Invalid input: more than one option matched":"Invalid input";case"invalid_element":return`Invalid value in ${i.origin}`;default:return"Invalid input"}}}});function qU(){return new ME}var Ev,ME,bv,$s,UE=y(()=>{ME=class{constructor(){this._map=new WeakMap,this._idmap=new Map}add(t,...n){let r=n[0];return this._map.set(t,r),r&&typeof r=="object"&&"id"in r&&this._idmap.set(r.id,t),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(t){let n=this._map.get(t);return n&&typeof n=="object"&&"id"in n&&this._idmap.delete(n.id),this._map.delete(t),this}get(t){var r;let n=t._zod.parent;if(n){let o={...(r=this.get(n))!=null?r:{}};delete o.id;let i={...o,...this._map.get(t)};return Object.keys(i).length?i:void 0}return this._map.get(t)}has(t){return this._map.has(t)}};(bv=(Ev=globalThis).__zod_globalRegistry)!=null||(Ev.__zod_globalRegistry=qU());$s=globalThis.__zod_globalRegistry});var _v=y(()=>{});function Sv(e){return e.checks&&(e.checks=[...e.checks]),e}function Tv(e,t){return new e(Sv({type:"string",...te(t)}))}function xv(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...te(t)})}function Av(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...te(t)})}function yv(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...te(t)})}function wv(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...te(t)})}function vv(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...te(t)})}function Nv(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...te(t)})}function Rv(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...te(t)})}function Ov(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...te(t)})}function Iv(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...te(t)})}function Cv(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...te(t)})}function Lv(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...te(t)})}function $v(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...te(t)})}function kv(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...te(t)})}function zv(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...te(t)})}function Dv(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...te(t)})}function Pv(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...te(t)})}function Mv(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...te(t)})}function Uv(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...te(t)})}function Hv(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...te(t)})}function Fv(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...te(t)})}function Bv(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...te(t)})}function Gv(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...te(t)})}function Vv(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...te(t)})}function jv(e,t){return new e({type:"string",format:"date",check:"string_format",...te(t)})}function Kv(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...te(t)})}function Zv(e,t){return new e({type:"string",format:"duration",check:"string_format",...te(t)})}function Wv(e,t){return new e(Sv({type:"number",checks:[],...te(t)}))}function Yv(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...te(t)})}function Xv(e,t){return new e({type:"boolean",...te(t)})}function qv(e,t){return new e({type:"undefined",...te(t)})}function Jv(e,t){return new e({type:"null",...te(t)})}function Qv(e){return new e({type:"unknown"})}function eN(e,t){return new e({type:"never",...te(t)})}function Of(e,t){return new AE({check:"less_than",...te(t),value:e,inclusive:!1})}function vu(e,t){return new AE({check:"less_than",...te(t),value:e,inclusive:!0})}function If(e,t){return new yE({check:"greater_than",...te(t),value:e,inclusive:!1})}function Nu(e,t){return new yE({check:"greater_than",...te(t),value:e,inclusive:!0})}function Cf(e,t){return new Dy({check:"multiple_of",...te(t),value:e})}function Lf(e,t){return new My({check:"max_length",...te(t),maximum:e})}function ic(e,t){return new Uy({check:"min_length",...te(t),minimum:e})}function $f(e,t){return new Hy({check:"length_equals",...te(t),length:e})}function HE(e,t){return new Fy({check:"string_format",format:"regex",...te(t),pattern:e})}function FE(e){return new By({check:"string_format",format:"lowercase",...te(e)})}function BE(e){return new Gy({check:"string_format",format:"uppercase",...te(e)})}function GE(e,t){return new Vy({check:"string_format",format:"includes",...te(t),includes:e})}function VE(e,t){return new jy({check:"string_format",format:"starts_with",...te(t),prefix:e})}function jE(e,t){return new Ky({check:"string_format",format:"ends_with",...te(t),suffix:e})}function Li(e){return new Zy({check:"overwrite",tx:e})}function KE(e){return Li(t=>t.normalize(e))}function ZE(){return Li(e=>e.trim())}function WE(){return Li(e=>e.toLowerCase())}function YE(){return Li(e=>e.toUpperCase())}function XE(){return Li(e=>aE(e))}function tN(e,t,n){return new e({type:"array",element:t,...te(n)})}function nN(e,t,n){return new e({type:"custom",check:"custom",fn:t,...te(n)})}function rN(e,t){let n=JU(r=>(r.addIssue=o=>{var i,s,a;if(typeof o=="string")r.issues.push(rc(o,r.value,n._zod.def));else{let l=o;l.fatal&&(l.continue=!1),(i=l.code)!=null||(l.code="custom"),"input"in l||(l.input=r.value),(s=l.inst)!=null||(l.inst=n),(a=l.continue)!=null||(l.continue=!n._zod.def.abort),r.issues.push(rc(l))}},e(r.value,r)),t);return n}function JU(e,t){let n=new Pt({check:"custom",...te(t)});return n._zod.check=e,n}var oN=y(()=>{bf();Sn()});function Ru(e,...t){for(let n of t)for(let r of Reflect.ownKeys(n))Object.prototype.propertyIsEnumerable.call(n,r)&&zn(e,r,n[r]);return e}function JE(e){var n,r,o,i,s,a,l,u,d;let t=(n=e==null?void 0:e.target)!=null?n:"draft-2020-12";return t==="draft-4"&&(t="draft-04"),t==="draft-7"&&(t="draft-07"),{processors:(r=e.processors)!=null?r:{},metadataRegistry:(o=e==null?void 0:e.metadata)!=null?o:$s,target:t,unrepresentable:(i=e==null?void 0:e.unrepresentable)!=null?i:"throw",override:(s=e==null?void 0:e.override)!=null?s:(()=>{}),io:(a=e==null?void 0:e.io)!=null?a:"output",counter:0,seen:new Map,sharedDefsExtractedFor:void 0,sharedEmitDoneFor:void 0,cycles:(l=e==null?void 0:e.cycles)!=null?l:"ref",reused:(u=e==null?void 0:e.reused)!=null?u:"inline",intersections:[],deferred:[],external:(d=e==null?void 0:e.external)!=null?d:void 0}}function so(e,t,n,r,o){let i=typeof t.unrepresentable=="function"?t.unrepresentable({zodSchema:e,path:r.path,message:o}):t.unrepresentable;if(i==="any")return!1;if(i===void 0||i==="throw")throw new Error(o);return Object.assign(n,i),!0}function Ve(e,t,n={path:[],schemaPath:[]}){var d,f,m;var r;let o=e._zod.def,i=t.seen.get(e);if(i)return i.count++,n.schemaPath.includes(e)&&(i.cycle=n.path),i.schema;let s={schema:{},count:1,cycle:void 0,path:n.path};t.seen.set(e,s),t.sharedDefsExtractedFor=void 0,t.sharedEmitDoneFor=void 0;let a=(f=(d=e._zod).toJSONSchema)==null?void 0:f.call(d);if(a)s.schema=a;else{let h={...n,schemaPath:[...n.schemaPath,e],path:n.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(t,s.schema,h);else{let S=s.schema,A=t.processors[o.type];if(!A)throw new Error(`[toJSONSchema]: Non-representable type encountered: ${o.type}`);A(e,t,S,h)}let E=e._zod.parent;E&&(s.ref||(s.ref=E),Ve(E,t,h),t.seen.get(E).isParent=!0)}let l=t.metadataRegistry.get(e);return l&&Ru(s.schema,l),t.io==="input"&&rn(e)&&(delete s.schema.examples,delete s.schema.default),t.io==="input"&&"_prefault"in s.schema&&((m=(r=s.schema).default)!=null||(r.default=s.schema._prefault)),delete s.schema._prefault,t.seen.get(e).schema}function iN(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}function QE(e,t){var s,a,l,u;let n=e.seen.get(t);if(!n)throw new Error("Unprocessed schema. This is a bug in Zod.");if(e.external&&e.sharedDefsExtractedFor===e.external)return;let r=new Map;for(let d of e.seen.entries()){let f=(s=e.metadataRegistry.get(d[0]))==null?void 0:s.id;if(f){let m=r.get(f);if(m&&m!==d[0])throw new Error(`Duplicate schema id "${f}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);r.set(f,d[0])}}let o=d=>{var S,A,w,N,O;let f=e.target==="draft-2020-12"?"$defs":"definitions";if(e.external){let k=(S=e.external.registry.get(d[0]))==null?void 0:S.id,G=(A=e.external.uri)!=null?A:(W=>W);if(k)return{ref:G(k)};let V=(N=(w=d[1].defId)!=null?w:d[1].schema.id)!=null?N:`schema${e.counter++}`;return d[1].defId=V,{defId:V,ref:`${G("__shared")}#/${f}/${iN(V)}`}}let m="#",h=`${m}/${f}/`;if(d[1]===n&&!d[1].schema.id)return{ref:m};let E=(O=d[1].schema.id)!=null?O:`__schema${e.counter++}`;return{defId:E,ref:h+iN(E)}},i=d=>{if(d[1].schema.$ref)return;let f=d[1],{ref:m,defId:h}=o(d);f.def={...f.schema},h&&(f.defId=h);let E=f.schema;for(let S in E)delete E[S];E.$ref=m};if(e.cycles==="throw")for(let d of e.seen.entries()){let f=d[1];if(f.cycle)throw new Error(`Cycle detected: #/${(a=f.cycle)==null?void 0:a.join("/")}/<root>
56
56
 
57
- Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let d of e.seen.entries()){let f=d[1];if(t===d[0]){i(d);continue}if(e.external){let h=(l=e.external.registry.get(d[0]))==null?void 0:l.id;if(t!==d[0]&&h){i(d);continue}}if((u=e.metadataRegistry.get(d[0]))==null?void 0:u.id){i(d);continue}if(f.cycle){i(d);continue}f.count>1&&e.reused==="ref"&&i(d)}e.external&&(e.sharedDefsExtractedFor=e.external)}function qv(e){let t=e.anyOf;if(!Array.isArray(t)||t.length===0||e.type!==void 0)return;let n=[];for(let r of t){if(!r||typeof r!="object")return;qv(r);let o=Object.keys(r);if(o.length!==1||o[0]!=="type")return;let i=r.type;for(let s of Array.isArray(i)?i:[i]){if(typeof s!="string")return;n.includes(s)||n.push(s)}}delete e.anyOf,e.type=n.length===1?n[0]:n}function Xv(e){let t=e.additionalProperties;return t===void 0||t===!1||typeof t!="object"||t===null?null:Object.keys(t).length?t:null}function KE(e){var i,s,a,l;let t=[];for(let u of e){if(typeof u!="object"||u.type!=="object")return null;for(let d in u)if(!Jv.has(d))return null;t.push(u)}let n={},r=new Set;for(let u of t){for(let d in u.properties){if(Object.prototype.hasOwnProperty.call(n,d))continue;let f=[];for(let h of t){let E=(s=(i=h.properties)==null?void 0:i[d])!=null?s:Xv(h);E!=null&&(f.some(_=>JSON.stringify(_)===JSON.stringify(E))||f.push(E))}let m=f.length===1?f[0]:(a=KE(f))!=null?a:{allOf:f};kn(n,d,m)}for(let d of(l=u.required)!=null?l:[])r.add(d)}let o={type:"object",properties:n};if(r.size&&(o.required=[...r]),t.every(u=>u.additionalProperties===!1))o.additionalProperties=!1;else{let u=[];for(let d of t){let f=Xv(d);f&&!u.some(m=>JSON.stringify(m)===JSON.stringify(f))&&u.push(f)}u.length===1?o.additionalProperties=u[0]:u.length>1&&(o.additionalProperties={allOf:u})}return o}function MU(e){let t=e.allOf;if(!Array.isArray(t)||t.length<2)return;for(let o of Jv)if(o in e)return;let n=t.filter(o=>Yv.some(i=>Array.isArray(o[i]))),r=null;if(!n.length)r=KE(t);else{let o=n[0],i=Yv.find(l=>Array.isArray(o[l]));if(Object.keys(o).length!==1)return;let s=t.filter(l=>l!==o),a=o[i].map(l=>KE([...s,l]));if(a.some(l=>!l))return;r={[i]:a}}r&&(delete e.allOf,yu(e,r))}function YE(e,t){var a,l,u,d,f,m,h,E;let n=e.seen.get(t);if(!n)throw new Error("Unprocessed schema. This is a bug in Zod.");let r=_=>{var j,Y,X;let A=e.seen.get(_);if(A.ref===null)return;let v=(j=A.def)!=null?j:A.schema,N={...v},O=A.ref;if(A.ref=null,O){r(O);let G=e.seen.get(O),ee=G.schema;if(ee.$ref&&(e.target==="draft-07"||e.target==="draft-04"||e.target==="openapi-3.0")?(v.allOf=(Y=v.allOf)!=null?Y:[],v.allOf.push(ee)):yu(v,ee),yu(v,N),_._zod.parent===O)for(let me in v)me==="$ref"||me==="allOf"||me in N||delete v[me];if(ee.$ref&&G.def)for(let me in v)me==="$ref"||me==="allOf"||me in G.def&&JSON.stringify(v[me])===JSON.stringify(G.def[me])&&delete v[me]}let k=_._zod.parent;if(k&&k!==O){r(k);let G=e.seen.get(k);if(G!=null&&G.schema.$ref&&(v.$ref=G.schema.$ref,G.def))for(let ee in v)ee==="$ref"||ee==="allOf"||ee in G.def&&JSON.stringify(v[ee])===JSON.stringify(G.def[ee])&&delete v[ee]}e.override({zodSchema:_,jsonSchema:v,path:(X=A.path)!=null?X:[]})};if(!e.external||e.sharedEmitDoneFor!==e.external){for(let _ of[...e.seen.entries()].reverse())r(_[0]);if(e.target!=="openapi-3.0")for(let _ of e.seen.entries())qv((a=_[1].def)!=null?a:_[1].schema);for(let _ of e.deferred)_();if(e.intersections.length){let _=new Map;for(let A of e.seen.values())for(let v of[A.schema,A.def]){let N=v==null?void 0:v.allOf;if(!Array.isArray(N))continue;let O=_.get(N);O?O.push(v):_.set(N,[v])}for(let A of e.intersections)for(let v of(l=_.get(A))!=null?l:[])MU(v)}}let o={};if(e.target==="draft-2020-12"?o.$schema="https://json-schema.org/draft/2020-12/schema":e.target==="draft-07"?o.$schema="http://json-schema.org/draft-07/schema#":e.target==="draft-04"?o.$schema="http://json-schema.org/draft-04/schema#":e.target,(u=e.external)!=null&&u.uri){let _=(d=e.external.registry.get(t))==null?void 0:d.id;if(!_)throw new Error("Schema is missing an `id` property");o.$id=e.external.uri(_)}yu(o,n.defId?n.schema:(f=n.def)!=null?f:n.schema);let i=(m=e.metadataRegistry.get(t))==null?void 0:m.id;i!==void 0&&o.id===i&&delete o.id;let s=(E=(h=e.external)==null?void 0:h.defs)!=null?E:{};if(!e.external||e.sharedEmitDoneFor!==e.external)for(let _ of e.seen.entries()){let A=_[1];A.def&&A.defId&&(A.def.id===A.defId&&delete A.def.id,kn(s,A.defId,A.def))}e.external&&(e.sharedEmitDoneFor=e.external),e.external||Object.keys(s).length>0&&(e.target==="draft-2020-12"?o.$defs=s:o.definitions=s);try{let _=JSON.parse(JSON.stringify(o));return Object.defineProperty(_,"~standard",{value:{...t["~standard"],jsonSchema:{input:wu(t,"input",e.processors),output:wu(t,"output",e.processors)}},enumerable:!1,writable:!1}),_}catch{throw new Error("Error converting schema to JSON.")}}function rn(e,t){let n=t!=null?t:{seen:new Set};if(n.seen.has(e))return!1;n.seen.add(e);let r=e._zod.def;if(r.type==="transform")return!0;if(r.type==="array")return rn(r.element,n);if(r.type==="set")return rn(r.valueType,n);if(r.type==="lazy")return rn(r.getter(),n);if(r.type==="promise"||r.type==="optional"||r.type==="nonoptional"||r.type==="nullable"||r.type==="readonly"||r.type==="default"||r.type==="prefault"||r.type==="catch")return rn(r.innerType,n);if(r.type==="intersection")return rn(r.left,n)||rn(r.right,n);if(r.type==="record"||r.type==="map")return rn(r.keyType,n)||rn(r.valueType,n);if(r.type==="pipe")return e._zod.traits.has("$ZodCodec")?!0:rn(r.in,n)||rn(r.out,n);if(r.type==="object"){for(let o in r.shape)if(rn(r.shape[o],n))return!0;return!1}if(r.type==="union"){for(let o of r.options)if(rn(o,n))return!0;return!1}if(r.type==="tuple"){for(let o of r.items)if(rn(o,n))return!0;return!!(r.rest&&rn(r.rest,n))}return!1}var Jv,Yv,Qv,wu,If=y(()=>{kE();Sn();Jv=new Set(["type","properties","required","additionalProperties"]),Yv=["oneOf","anyOf"];Qv=(e,t={})=>n=>{let r=ZE({...n,processors:t});return Ve(e,r),WE(r,e),YE(r,e)},wu=(e,t,n={})=>r=>{let{libraryOptions:o,target:i}=r!=null?r:{},s=ZE({...o!=null?o:{},target:i,io:t,processors:n});return Ve(e,s),WE(s,e),YE(s,e)}});function Pn(e){var i,s,a,l,u;let t={},n=e._zod.def,r=e._zod.traits.has("$ZodCheck")?[e,...(i=n.checks)!=null?i:[]]:(s=n.checks)!=null?s:[];for(let d of r)(a=XE[d._zod.def.check])==null||a.call(XE,t,d._zod.def);let o=e._zod.bag;o.minimum!==void 0&&oc(t,"minimum",o.minimum),o.exclusiveMinimum!==void 0&&oc(t,"exclusiveMinimum",o.exclusiveMinimum),o.maximum!==void 0&&ic(t,"maximum",o.maximum),o.exclusiveMaximum!==void 0&&ic(t,"exclusiveMaximum",o.exclusiveMaximum),o.multipleOf!==void 0&&oN(t,o.multipleOf),o.format!==void 0&&((l=t.format)!=null||(t.format=o.format),o.format.includes("int")&&(t.isInt=!0)),o.mime&&sN(t,o.mime);for(let d of(u=o.patterns)!=null?u:[])iN(t,d);return t}function vu(e){let t=e._zod.def;return t.type==="pipe"&&t.in._zod.traits.has("$ZodTransform")?vu(t.out):t.type==="catch"?vu(t.innerType):e._zod.optin}function qE(e,t,n){var E,_;if(t.$ref){if(n.has(t))return t;n.add(t);let A=(E=e.get(t))==null?void 0:E.def;if(!A)return t;let v=qE(e,A,n);return v===A?t:v}for(let A of["anyOf","oneOf"]){let v=t[A];if(!Array.isArray(v))continue;let N=v.map(O=>qE(e,O,n));N.some((O,k)=>O!==v[k])&&(t={...t,[A]:N})}let r=Array.isArray(t.type)?t.type:[t.type],o=!r.includes("string")&&r.some(A=>A==="number"||A==="integer"),i=(_=t.enum)!=null?_:t.const!==void 0?[t.const]:void 0;if(!o&&!(i!=null&&i.some(A=>typeof A=="number")))return t;let{minimum:s,maximum:a,exclusiveMinimum:l,exclusiveMaximum:u,multipleOf:d,format:f,id:m,...h}=t;return h.enum?h.enum=h.enum.map(A=>typeof A=="number"?String(A):A):typeof h.const=="number"&&(h.const=String(h.const)),o&&(h.type="string",i||(h.pattern=(r.includes("number")?bu:gE).source)),h}function FU(e){var r,o,i;let t=new Map;for(let s of e.seen.values())s.def&&!t.has(s.schema)&&t.set(s.schema,s);let n=new Map;for(let s of(r=JE.get(e))!=null?r:[]){let a=e.seen.get(s),l=(i=(o=a==null?void 0:a.def)!=null?o:a==null?void 0:a.schema)==null?void 0:i.propertyNames;if(!l||l===!0||n.has(l))continue;let u=qE(t,l,new Set);u!==l&&n.set(l,u)}if(n.size)for(let s of e.seen.values())for(let a of[s.schema,s.def]){let l=a&&n.get(a.propertyNames);l&&(a.propertyNames=l)}}function RN(e,t,n,r,o){let i=!1,s=JSON.stringify(e,(a,l)=>typeof l!="bigint"?l:(i=!0,null));return i?(ro(t,n,r,o,"BigInt defaults cannot be represented in JSON Schema"),QE):JSON.parse(s)}var oc,ic,eN,oN,iN,sN,aN,tN,nN,rN,XE,UU,HU,cN,lN,uN,dN,pN,fN,hN,mN,gN,EN,bN,_N,SN,TN,xN,AN,yN,JE,wN,vN,NN,QE,ON,IN,CN,LN,$N,eb,kN,zN=y(()=>{pf();OE();If();Sn();oc=(e,t,n)=>{(e[t]===void 0||n>e[t])&&(e[t]=n)},ic=(e,t,n)=>{(e[t]===void 0||n<e[t])&&(e[t]=n)},eN=(e,t)=>{oc(e,"minimum",t),ic(e,"maximum",t)},oN=(e,t)=>{var n;(n=e.multipleOf)!=null||(e.multipleOf=[]),e.multipleOf.includes(t)||e.multipleOf.push(t)},iN=(e,t)=>{var n;(n=e.patterns)!=null||(e.patterns=new Set),e.patterns.add(t)},sN=(e,t)=>{e.mime=e.mime?e.mime.filter(n=>t.includes(n)):[...t]},aN=(e,t)=>{e.format=t,t.includes("int")&&(e.isInt=!0)},tN=(e,t)=>oc(e,"minimum",t.minimum),nN=(e,t)=>ic(e,"maximum",t.maximum),rN=e=>(t,n)=>{aN(t,n.format);let[r,o]=e[n.format];oc(t,"minimum",r),ic(t,"maximum",o)},XE={greater_than:(e,t)=>oc(e,t.inclusive?"minimum":"exclusiveMinimum",t.value),less_than:(e,t)=>ic(e,t.inclusive?"maximum":"exclusiveMaximum",t.value),multiple_of:(e,t)=>oN(e,t.value),number_format:rN(hu),bigint_format:rN(tf),min_length:tN,max_length:nN,length_equals:(e,t)=>eN(e,t.length),min_size:tN,max_size:nN,size_equals:(e,t)=>eN(e,t.size),string_format:(e,t)=>{aN(e,t.format),t.pattern&&iN(e,t.pattern),(t.format==="base64"||t.format==="base64url")&&(e.contentEncoding=t.format),(t.local||t.precision===-1)&&(e.laxFormat=!0)},mime_type:(e,t)=>sN(e,t.mime)};UU={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},HU=new Map([[yE,dy],[Sf,py]]),cN=e=>{var t;return(t=HU.get(e))!=null?t:e},lN=(e,t,n,r)=>{var f;let o=n;o.type="string";let{minimum:i,maximum:s,format:a,patterns:l,contentEncoding:u,laxFormat:d}=Pn(e);if(typeof i=="number"&&(o.minLength=i),typeof s=="number"&&(o.maxLength=s),a&&(o.format=(f=UU[a])!=null?f:a,o.format===""&&delete o.format,(a==="time"||d)&&delete o.format),u&&(o.contentEncoding=u),l&&l.size>0){let m=[...l].map(cN);m.length===1?o.pattern=m[0].source:m.length>1&&(o.allOf=[...m.map(h=>({...t.target==="draft-07"||t.target==="draft-04"||t.target==="openapi-3.0"?{type:"string"}:{},pattern:h.source}))])}},uN=(e,t,n,r)=>{var E;let o=n,{minimum:i,maximum:s,multipleOf:a,exclusiveMaximum:l,exclusiveMinimum:u,isInt:d}=Pn(e);o.type=d?"integer":"number";let f=typeof u=="number"&&u>=(i!=null?i:Number.NEGATIVE_INFINITY),m=typeof l=="number"&&l<=(s!=null?s:Number.POSITIVE_INFINITY),h=t.target==="draft-04"||t.target==="openapi-3.0";if(f?h?(o.minimum=u,o.exclusiveMinimum=!0):o.exclusiveMinimum=u:typeof i=="number"&&(o.minimum=i),m?h?(o.maximum=l,o.exclusiveMaximum=!0):o.exclusiveMaximum=l:typeof s=="number"&&(o.maximum=s),a){let _=new Set;for(let N of a)Number.isFinite(N)&&N!==0?_.add(Math.abs(N)):ro(e,t,o,r,`A multipleOf divisor of ${N} cannot be represented in JSON Schema`);let[A,...v]=_;A!==void 0&&(o.multipleOf=A),v.length&&(o.allOf=[...(E=o.allOf)!=null?E:[],...v.map(N=>({multipleOf:N}))])}},dN=(e,t,n,r)=>{n.type="boolean"},pN=(e,t,n,r)=>{t.target==="openapi-3.0"?(n.type="string",n.nullable=!0,n.enum=[null]):n.type="null"},fN=(e,t,n,r)=>{ro(e,t,n,r,"Undefined cannot be represented in JSON Schema")},hN=(e,t,n,r)=>{n.not={}},mN=(e,t,n,r)=>{},gN=(e,t,n,r)=>{let o=e._zod.def,i=qa(o.entries);if(i.length===0){n.not={};return}i.every(s=>typeof s=="number")&&(n.type="number"),i.every(s=>typeof s=="string")&&(n.type="string"),n.enum=i},EN=(e,t,n,r)=>{let o=e._zod.def;if(o.values.length===0){n.not={};return}let i=[];for(let s of o.values)if(s===void 0){if(ro(e,t,n,r,"Literal `undefined` cannot be represented in JSON Schema"))return}else if(typeof s=="bigint"){if(ro(e,t,n,r,"BigInt literals cannot be represented in JSON Schema"))return;i.push(Number(s))}else i.push(s);if(i.length!==0)if(i.length===1){let s=i[0];n.type=s===null?"null":typeof s,t.target==="draft-04"||t.target==="openapi-3.0"?n.enum=[s]:n.const=s}else i.every(s=>typeof s=="number")&&(n.type="number"),i.every(s=>typeof s=="string")&&(n.type="string"),i.every(s=>typeof s=="boolean")&&(n.type="boolean"),i.every(s=>s===null)&&(n.type="null"),n.enum=i},bN=(e,t,n,r)=>{ro(e,t,n,r,"Custom types cannot be represented in JSON Schema")},_N=(e,t,n,r)=>{ro(e,t,n,r,"Transforms cannot be represented in JSON Schema")},SN=(e,t,n,r)=>{let o=n,i=e._zod.def,{minimum:s,maximum:a}=Pn(e);typeof s=="number"&&(o.minItems=s),typeof a=="number"&&(o.maxItems=a),o.type="array",o.items=Ve(i.element,t,{...r,path:[...r.path,"items"]})};TN=(e,t,n,r)=>{var u;let o=n,i=e._zod.def,s=i.shape;if(Object.getOwnPropertySymbols(s).length&&ro(e,t,o,r,"Symbol keys cannot be represented in JSON Schema"))return;o.type="object",o.properties={};for(let d in s)kn(o.properties,d,Ve(s[d],t,{...r,path:[...r.path,"properties",d]}));let l=[];for(let d of Object.keys(s)){let f=i.shape[d];(t.io==="input"?vu(f)===void 0:f._zod.optout===void 0)&&l.push(d)}l.length>0&&(o.required=l),((u=i.catchall)==null?void 0:u._zod.def.type)==="never"?o.additionalProperties=!1:i.catchall?i.catchall&&(o.additionalProperties=Ve(i.catchall,t,{...r,path:[...r.path,"additionalProperties"]})):t.io==="output"&&(o.additionalProperties=!1)},xN=(e,t,n,r)=>{let o=e._zod.def,i=o.inclusive===!1,s=o.options.map((a,l)=>Ve(a,t,{...r,path:[...r.path,i?"oneOf":"anyOf",l]}));i?n.oneOf=s:n.anyOf=s},AN=(e,t,n,r)=>{let o=e._zod.def,i=Ve(o.left,t,{...r,path:[...r.path,"allOf",0]}),s=Ve(o.right,t,{...r,path:[...r.path,"allOf",1]}),a=u=>"allOf"in u&&Object.keys(u).length===1,l=[...a(i)?i.allOf:[i],...a(s)?s.allOf:[s]];n.allOf=l,t.intersections.push(l)},yN=(e,t,n,r)=>{let o=n,i=e._zod.def;o.type="array";let s=t.target==="draft-2020-12"?"prefixItems":"items",a=t.target==="draft-2020-12"||t.target==="openapi-3.0"?"items":"additionalItems",l=i.items.map((_,A)=>Ve(_,t,{...r,path:[...r.path,s,A]})),u=i.rest?Ve(i.rest,t,{...r,path:[...r.path,a,...t.target==="openapi-3.0"?[i.items.length]:[]]}):null,d=i.items.length;for(;d>0;){let _=i.items[d-1];if(!(t.io==="input"?vu(_)!==void 0:_._zod.optout==="optional"))break;d--}let f=i.items.length,m=!i.rest;t.target==="draft-2020-12"?(o.prefixItems=l,m?o.items=!1:u&&(o.items=u),d>0&&(o.minItems=d),m&&(o.maxItems=f)):t.target==="openapi-3.0"?(o.items={anyOf:l},u&&o.items.anyOf.push(u),d>0&&(o.minItems=d),m&&(o.maxItems=f)):(o.items=l,m?o.additionalItems=!1:u&&(o.additionalItems=u),d>0&&(o.minItems=d),m&&(o.maxItems=f));let{minimum:h,maximum:E}=Pn(e);typeof h=="number"&&(o.minItems=h),typeof E=="number"&&(o.maxItems=E)};JE=new WeakMap;wN=(e,t,n,r)=>{let o=n,i=e._zod.def;o.type="object";let s=i.keyType,a=Pn(s).patterns;if(i.mode==="loose"&&a&&a.size>0){let d=Ve(i.valueType,t,{...r,path:[...r.path,"patternProperties","*"]});o.patternProperties={};for(let f of a)kn(o.patternProperties,cN(f).source,d)}else{if(t.target==="draft-07"||t.target==="draft-2020-12"){o.propertyNames=Ve(i.keyType,t,{...r,path:[...r.path,"propertyNames"]});let d=JE.get(t);d||(d=[],JE.set(t,d),t.deferred.push(()=>FU(t))),d.push(e)}o.additionalProperties=Ve(i.valueType,t,{...r,path:[...r.path,"additionalProperties"]})}let l=s._zod.values,u=t.io==="input"&&vu(i.valueType)!==void 0;if(l&&!i.partial&&!u){let d=[...l].filter(f=>typeof f=="string"||typeof f=="number");d.length>0&&(o.required=d.map(String))}},vN=(e,t,n,r)=>{let o=e._zod.def,i=Ve(o.innerType,t,r),s=t.seen.get(e);t.target==="openapi-3.0"?(s.ref=o.innerType,n.nullable=!0):n.anyOf=[i,{type:"null"}]},NN=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType},QE=Symbol();ON=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType;let s=RN(o.defaultValue,e,t,n,r);s!==QE&&(n.default=s)},IN=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);if(i.ref=o.innerType,t.io!=="input")return;let s=RN(o.defaultValue,e,t,n,r);s!==QE&&(n._prefault=s)},CN=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType;let s;try{s=o.catchValue(void 0)}catch{ro(e,t,n,r,"Dynamic catch values are not supported in JSON Schema");return}n.default=s},LN=(e,t,n,r)=>{let o=e._zod.def,i=o.in._zod.traits.has("$ZodTransform"),s=t.io==="input"?i?o.out:o.in:o.out;Ve(s,t,r);let a=t.seen.get(e);a.ref=s},$N=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType,n.readOnly=!0},eb=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType},kN=(e,t,n,r)=>{let o=e._zod.innerType;Ve(o,t,r);let i=t.seen.get(e);i.ref=o}});var Li=y(()=>{Ls();YA();UA();OE();rv();hf();TE();Sn();kE();SE();cv();Zv();If()});var nb=y(()=>{Li()});function Cf(e,t,n){Object.defineProperty(e,t,{configurable:!0,enumerable:!1,get(){let r=n(this);return Object.defineProperty(this,t,{value:r,configurable:!0,writable:!0}),r},set(r){Object.defineProperty(this,t,{value:r,configurable:!0,writable:!0})}})}var DN,YU,Mn,rb=y(()=>{Li();Li();Sn();DN=new WeakSet([Object.prototype,Error.prototype]);YU=(e,t)=>{DA.init(e,t),e.name="ZodError";let n=Object.getPrototypeOf(e);DN.has(n)||(DN.add(n),Cf(n,"format",r=>o=>MA(r,o)),Cf(n,"flatten",r=>o=>PA(r,o)),Cf(n,"addIssue",r=>o=>{r.issues.push(o),r.message=JSON.stringify(r.issues,Ja,2)}),Cf(n,"addIssues",r=>o=>{r.issues.push(...o),r.message=JSON.stringify(r.issues,Ja,2)}),Object.defineProperty(n,"isEmpty",{configurable:!0,enumerable:!1,get(){return this.issues.length===0}}))},Mn=I("ZodError",YU,void 0,{Parent:Error})});var PN,MN,UN,HN,FN,BN,GN,VN,jN,KN,ZN,WN,ob=y(()=>{Li();rb();Li();PN=af(Mn),MN=cf(Mn),UN=lf(Mn),HN=uf(Mn),FN=FA(Mn),BN=BA(Mn),GN=GA(Mn),VN=VA(Mn),jN=jA(Mn),KN=KA(Mn),ZN=ZA(Mn),WN=WA(Mn)});function qU(){nn.localeError||Dn(ov())}function Nu(){nn.memoizer||Dn({memoizer:nv()})}function p(e){return uv(JU,e)}function S(e){return Pv(eR,e)}function YN(e){return Mv(TH,e)}function L(e){return Uv(xH,e)}function Ru(e){return Hv(AH,e)}function tR(e){return Fv(yH,e)}function q(){return Bv(wH)}function NH(e){return Gv(vH,e)}function C(e,t){return Vv(RH,e,t)}function b(e,t){let n={type:"object",shape:e!=null?e:{},...ne.normalizeParams(t)};return new OH(n)}function wt(e,t){return new nR({type:"union",options:e,...ne.normalizeParams(t)})}function vt(e,t,n){return new IH({type:"union",options:t,discriminator:e,...ne.normalizeParams(n)})}function LH(e,t){return new CH({type:"intersection",left:e,right:t})}function kf(e,t,n){let r=t instanceof De,o=r?n:t,i=r?t:null;return new $H({type:"tuple",items:e,rest:i,...ne.normalizeParams(o)})}function ie(e,t,n){return!t||!t._zod?new ib({type:"record",keyType:p(),valueType:e,...ne.normalizeParams(t)}):new ib({type:"record",keyType:e,valueType:t,...ne.normalizeParams(n)})}function sb(e,t,n){return new ib({type:"record",keyType:e,valueType:t,...ne.normalizeParams(n),partial:!0})}function pe(e,t){let n=Array.isArray(e)?Object.fromEntries(e.map(r=>[r,r])):e;return new $f({type:"enum",entries:n,...ne.normalizeParams(t)})}function R(e,t){return new $f({type:"enum",entries:e,...ne.normalizeParams(t)})}function U(e,t){return new rR({type:"literal",values:Array.isArray(e)?e:[e],...ne.normalizeParams(t)})}function oR(e){return new kH({type:"transform",transform:e})}function XN(e){return new ab({type:"optional",innerType:e})}function zH(e){return new iR({type:"optional",innerType:e})}function qN(e){return new DH({type:"nullable",innerType:e})}function MH(e,t){return new PH({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():ne.shallowClone(t)}})}function HH(e,t){return new UH({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():ne.shallowClone(t)}})}function FH(e,t){return new sR({type:"nonoptional",innerType:e,...ne.normalizeParams(t)})}function GH(e,t){return new BH({type:"catch",innerType:e,catchValue:typeof t=="function"?t:ne.constantCatch(t)})}function JN(e,t){return new aR({type:"pipe",in:e,out:t})}function KH(e){return new jH({type:"readonly",innerType:e})}function zf(e){return new ZH({type:"lazy",getter:e})}function YH(e,t={}){return jv(WH,e,t)}function XH(e,t){return Kv(e,t)}function Ou(e,t){return new VH({type:"pipe",in:oR(e),out:t})}var Me,QN,JU,Ye,QU,eH,tH,nH,rH,oH,Lf,iH,sH,aH,cH,lH,uH,dH,pH,fH,hH,mH,gH,EH,bH,_H,SH,eR,TH,xH,AH,yH,wH,vH,RH,OH,nR,IH,CH,$H,ib,$f,rR,kH,ab,iR,DH,PH,UH,sR,BH,aR,VH,jH,ZH,WH,cR=y(()=>{Li();Li();zN();If();iv();nb();ob();Me=I("ZodType",(e,t)=>(qU(),De.init(e,t),e.def=t,e.type=t.type,e),{check(...e){var n;let t=this.def;return this.clone(ne.mergeDefs(t,{checks:[...(n=t.checks)!=null?n:[],...e.map(r=>typeof r=="function"?{_zod:{check:r,def:{check:"custom"},onattach:[]}}:r)]}),{parent:!0})},with(...e){return this.check(...e)},clone(e,t){return Rr(this,e,t)},brand(){return this},register(e,t){return e.add(this,t),this},refine(e,t){return this.check(YH(e,t))},superRefine(e,t){return this.check(XH(e,t))},overwrite(e){return this.check(Ci(e))},optional(){return XN(this)},exactOptional(){return zH(this)},nullable(){return qN(this)},nullish(){return XN(qN(this))},nonoptional(e){return FH(this,e)},array(){return C(this)},or(e){return wt([this,e])},and(e){return LH(this,e)},transform(e){return JN(this,oR(e))},default(e){return MH(this,e)},prefault(e){return HH(this,e)},catch(e){return GH(this,e)},pipe(e){return JN(this,e)},readonly(){return KH(this)},describe(e){let t=this.clone();return $s.add(t,{description:e}),t},meta(...e){if(e.length===0)return $s.get(this);let t=this.clone();return $s.add(t,e[0]),t},isOptional(){return this.safeParse(void 0).success},isNullable(){return this.safeParse(null).success},apply(e,...t){return t.length===0?e(this):e(this,...t)},get"~standard"(){return ne.hide(this,"~standard",{...AE(this),jsonSchema:{input:wu(this,"input"),output:wu(this,"output")}})},set"~standard"(e){ne.own(this,"~standard",e)},parse:function e(t,n){return PN(this,t,n,{callee:e})},parseAsync:async function e(t,n){return await MN(this,t,n,{callee:e})},safeParse(e,t){return UN(this,e,t)},async safeParseAsync(e,t){return HN(this,e,t)},get spa(){return this==null?void 0:this.safeParseAsync},set spa(e){ne.own(this,"spa",e)},validate(e,t){return pE(this,e,t)},validateAsync(e,t){return fE(this,e,t)},encode:function e(t,n){return FN(this,t,n,{callee:e})},decode:function e(t,n){return BN(this,t,n,{callee:e})},encodeAsync:async function e(t,n){return await GN(this,t,n,{callee:e})},decodeAsync:async function e(t,n){return await VN(this,t,n,{callee:e})},safeEncode(e,t){return jN(this,e,t)},safeDecode(e,t){return KN(this,e,t)},async safeEncodeAsync(e,t){return ZN(this,e,t)},async safeDecodeAsync(e,t){return WN(this,e,t)},toJSONSchema(e){return Qv(this,{})(e)},get description(){var e;return(e=$s.get(this))==null?void 0:e.description},get _def(){return this._zod.def}}),QN=I("_ZodString",(e,t)=>{_f.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>lN(e,n,r,o)},ne.derived({format:e=>{var t;return(t=Pn(e).format)!=null?t:null},minLength:e=>{var t;return(t=Pn(e).minimum)!=null?t:null},maxLength:e=>{var t;return(t=Pn(e).maximum)!=null?t:null}},{regex(...e){return this.check(zE(...e))},includes(...e){return this.check(ME(...e))},startsWith(...e){return this.check(UE(...e))},endsWith(...e){return this.check(HE(...e))},min(...e){return this.check(rc(...e))},max(...e){return this.check(Rf(...e))},length(...e){return this.check(Of(...e))},nonempty(...e){return this.check(rc(1,...e))},lowercase(e){return this.check(DE(e))},uppercase(e){return this.check(PE(e))},trim(){return this.check(BE())},normalize(...e){return this.check(FE(...e))},toLowerCase(){return this.check(GE())},toUpperCase(){return this.check(VE())},slugify(){return this.check(jE())}})),JU=I("ZodString",(e,t)=>{_f.init(e,t),QN.init(e,t)},{email(e){return this.check(dv(rH,e))},url(e){return this.check(Ev(iH,e))},jwt(e){return this.check(Lv(SH,e))},emoji(e){return this.check(bv(sH,e))},guid(e){return this.check(pv(oH,e))},uuid(e){return this.check(fv(Lf,e))},uuidv4(e){return this.check(hv(Lf,e))},uuidv6(e){return this.check(mv(Lf,e))},uuidv7(e){return this.check(gv(Lf,e))},nanoid(e){return this.check(_v(aH,e))},cuid(e){return this.check(Sv(cH,e))},cuid2(e){return this.check(Tv(lH,e))},ulid(e){return this.check(xv(uH,e))},base64(e){return this.check(Ov(EH,e))},base64url(e){return this.check(Iv(bH,e))},xid(e){return this.check(Av(dH,e))},ksuid(e){return this.check(yv(pH,e))},ipv4(e){return this.check(wv(fH,e))},ipv6(e){return this.check(vv(hH,e))},cidrv4(e){return this.check(Nv(mH,e))},cidrv6(e){return this.check(Rv(gH,e))},e164(e){return this.check(Cv(_H,e))},datetime(e){return this.check($v(QU,e))},date(e){return this.check(kv(eH,e))},time(e){return this.check(zv(tH,e))},duration(e){return this.check(Dv(nH,e))}});Ye=I("ZodStringFormat",(e,t)=>{Be.init(e,t),QN.init(e,t)}),QU=I("ZodISODateTime",(e,t)=>{pw.init(e,t),Ye.init(e,t)}),eH=I("ZodISODate",(e,t)=>{fw.init(e,t),Ye.init(e,t)}),tH=I("ZodISOTime",(e,t)=>{hw.init(e,t),Ye.init(e,t)}),nH=I("ZodISODuration",(e,t)=>{mw.init(e,t),Ye.init(e,t)}),rH=I("ZodEmail",(e,t)=>{tw.init(e,t),Ye.init(e,t)}),oH=I("ZodGUID",(e,t)=>{Qy.init(e,t),Ye.init(e,t)}),Lf=I("ZodUUID",(e,t)=>{ew.init(e,t),Ye.init(e,t)}),iH=I("ZodURL",(e,t)=>{ow.init(e,t),Ye.init(e,t)}),sH=I("ZodEmoji",(e,t)=>{iw.init(e,t),Ye.init(e,t)}),aH=I("ZodNanoID",(e,t)=>{sw.init(e,t),Ye.init(e,t)}),cH=I("ZodCUID",(e,t)=>{aw.init(e,t),Ye.init(e,t)}),lH=I("ZodCUID2",(e,t)=>{cw.init(e,t),Ye.init(e,t)}),uH=I("ZodULID",(e,t)=>{lw.init(e,t),Ye.init(e,t)}),dH=I("ZodXID",(e,t)=>{uw.init(e,t),Ye.init(e,t)}),pH=I("ZodKSUID",(e,t)=>{dw.init(e,t),Ye.init(e,t)}),fH=I("ZodIPv4",(e,t)=>{gw.init(e,t),Ye.init(e,t)}),hH=I("ZodIPv6",(e,t)=>{bw.init(e,t),Ye.init(e,t)}),mH=I("ZodCIDRv4",(e,t)=>{_w.init(e,t),Ye.init(e,t)}),gH=I("ZodCIDRv6",(e,t)=>{Sw.init(e,t),Ye.init(e,t)}),EH=I("ZodBase64",(e,t)=>{xw.init(e,t),Ye.init(e,t)}),bH=I("ZodBase64URL",(e,t)=>{Aw.init(e,t),Ye.init(e,t)}),_H=I("ZodE164",(e,t)=>{yw.init(e,t),Ye.init(e,t)}),SH=I("ZodJWT",(e,t)=>{ww.init(e,t),Ye.init(e,t)}),eR=I("ZodNumber",(e,t)=>{wE.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>uN(e,n,r,o),e.isFinite=!0},ne.derived({minValue:e=>{let{minimum:t,exclusiveMinimum:n}=Pn(e);return Math.max(t!=null?t:Number.NEGATIVE_INFINITY,n!=null?n:Number.NEGATIVE_INFINITY)},maxValue:e=>{let{maximum:t,exclusiveMaximum:n}=Pn(e);return Math.min(t!=null?t:Number.POSITIVE_INFINITY,n!=null?n:Number.POSITIVE_INFINITY)},isInt:e=>{let{isInt:t,multipleOf:n}=Pn(e);return!!t||!!(n!=null&&n.some(Number.isSafeInteger))},format:e=>{var t;return(t=Pn(e).format)!=null?t:null}},{gt(e,t){return this.check(vf(e,t))},gte(e,t){return this.check(Au(e,t))},min(e,t){return this.check(Au(e,t))},lt(e,t){return this.check(wf(e,t))},lte(e,t){return this.check(xu(e,t))},max(e,t){return this.check(xu(e,t))},int(e){return this.check(YN(e))},safe(e){return this.check(YN(e))},positive(e){return this.check(vf(0,e))},nonnegative(e){return this.check(Au(0,e))},negative(e){return this.check(wf(0,e))},nonpositive(e){return this.check(xu(0,e))},multipleOf(e,t){return this.check(Nf(e,t))},step(e,t){return this.check(Nf(e,t))},finite(){return this}}));TH=I("ZodNumberFormat",(e,t)=>{vw.init(e,t),eR.init(e,t)});xH=I("ZodBoolean",(e,t)=>{Nw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>dN(e,n,r,o)});AH=I("ZodUndefined",(e,t)=>{Rw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>fN(e,n,r,o)});yH=I("ZodNull",(e,t)=>{Ow.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>pN(e,n,r,o)});wH=I("ZodUnknown",(e,t)=>{Iw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>mN(e,n,r,o)});vH=I("ZodNever",(e,t)=>{Cw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>hN(e,n,r,o)});RH=I("ZodArray",(e,t)=>{Nu(),Lw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>SN(e,n,r,o),e.element=t.element},{min(e,t){return this.check(rc(e,t))},nonempty(e){return this.check(rc(1,e))},max(e,t){return this.check(Rf(e,t))},length(e,t){return this.check(Of(e,t))},unwrap(){return this.element}});OH=I("ZodObject",(e,t)=>{Nu(),zw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>TN(e,n,r,o),ne.installLazyProp(e,"shape",n=>n._zod.def.shape,!1)},{keyof(){return pe(Object.keys(this._zod.def.shape))},catchall(e){return this.clone(ne.mergeDefs(this._zod.def,{catchall:e}))},passthrough(){return this.clone(ne.mergeDefs(this._zod.def,{catchall:q()}))},loose(){return this.clone(ne.mergeDefs(this._zod.def,{catchall:q()}))},strict(){return this.clone(ne.mergeDefs(this._zod.def,{catchall:NH()}))},strip(){return this.clone(ne.mergeDefs(this._zod.def,{catchall:void 0}))},extend(e){return ne.extend(this,e)},safeExtend(e){return ne.safeExtend(this,e)},merge(e){return ne.merge(this,e)},pick(e){return ne.pick(this,e)},omit(e){return ne.omit(this,e)},partial(...e){return ne.partial(ab,this,e[0])},exactPartial(...e){return ne.partial(iR,this,e[0],"exactPartial")},required(...e){return ne.required(sR,this,e[0])}});nR=I("ZodUnion",(e,t)=>{vE.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>xN(e,n,r,o),e.options=t.options});IH=I("ZodDiscriminatedUnion",(e,t)=>{nR.init(e,t),Dw.init(e,t)});CH=I("ZodIntersection",(e,t)=>{Pw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>AN(e,n,r,o)});$H=I("ZodTuple",(e,t)=>{Nu(),Mw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>yN(e,n,r,o)},{rest(e){return this.clone({...this._zod.def,rest:e})},partial(){var t;let e=this._zod.def;if((t=e.checks)!=null&&t.length)throw new Error(".partial() cannot be used on tuple schemas containing refinements");return this.clone({...e,items:e.items.map(n=>new ab({type:"optional",innerType:n}))})}});ib=I("ZodRecord",(e,t)=>{Nu(),Uw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>wN(e,n,r,o),e.keyType=t.keyType,e.valueType=t.valueType});$f=I("ZodEnum",(e,t)=>{Hw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(r,o,i)=>gN(e,r,o,i),e.enum=t.entries,e.options=[...e._zod.values];let n=new Set(Object.keys(t.entries));e.extract=(r,o)=>{let i={};for(let s of r)if(n.has(s))i[s]=t.entries[s];else throw new Error(`Key ${s} not found in enum`);return new $f({...t,checks:[],...ne.normalizeParams(o),entries:i})},e.exclude=(r,o)=>{let i={...t.entries};for(let s of r)if(n.has(s))delete i[s];else throw new Error(`Key ${s} not found in enum`);return new $f({...t,checks:[],...ne.normalizeParams(o),entries:i})}});rR=I("ZodLiteral",(e,t)=>{Fw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>EN(e,n,r,o),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});kH=I("ZodTransform",(e,t)=>{Nu(),Bw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>_N(e,n,r,o),e._zod.parse=(n,r)=>{if(r.direction==="backward")throw new nc(e.constructor.name);n.addIssue=i=>{var s,a;if(typeof i=="string")n.issues.push(ne.issue(i,n.value,t));else{let l=i;l.fatal&&(l.continue=!1),(s=l.code)!=null||(l.code="custom"),"input"in l||(l.input=n.value),(a=l.inst)!=null||(l.inst=e),n.issues.push(ne.issue(l))}};let o=t.transform(n.value,n);return o instanceof Promise?o.then(i=>(n.value=i,n)):(n.value=o,n)}});ab=I("ZodOptional",(e,t)=>{NE.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>eb(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});iR=I("ZodExactOptional",(e,t)=>{Gw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>eb(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});DH=I("ZodNullable",(e,t)=>{Vw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>vN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});PH=I("ZodDefault",(e,t)=>{jw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>ON(e,n,r,o),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});UH=I("ZodPrefault",(e,t)=>{Kw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>IN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});sR=I("ZodNonOptional",(e,t)=>{Zw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>NN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});BH=I("ZodCatch",(e,t)=>{Ww.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>CN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});aR=I("ZodPipe",(e,t)=>{RE.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>LN(e,n,r,o),e.in=t.in,e.out=t.out});VH=I("ZodPreprocess",(e,t)=>{aR.init(e,t),Yw.init(e,t)}),jH=I("ZodReadonly",(e,t)=>{Xw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>$N(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});ZH=I("ZodLazy",(e,t)=>{qw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>kN(e,n,r,o),e.unwrap=()=>e._zod.def.getter()});WH=I("ZodCustom",(e,t)=>{Jw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>bN(e,n,r,o)})});var Go,lR,uR=y(()=>{Go={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};lR||(lR={})});var dR=y(()=>{cR();nb();rb();ob();uR()});var ae=y(()=>{dR()});var sc,cb=y(()=>{"use strict";sc={ACT:"reticle_act",ACT_SEQUENCE:"reticle_act_sequence",ACT_AND_WAIT:"reticle_act_and_wait",INVOKE:"reticle_invoke"}});var Df,lb,ub,z,S7,qH,T7,Vo=y(()=>{"use strict";Df={SIGNAL:"signal",NET:"net",STATE:"state"},lb={ELEMENT:"element",TEXT:"text"},ub={NETWORK:"network",APP:"app"},z={ELEMENT:lb.ELEMENT,TEXT:lb.TEXT,SIGNAL:Df.SIGNAL,NET:Df.NET,STATE:Df.STATE,ROUTE:"route",CONSOLE:"console",ANIMATION:"animation",SETTLED:"settled",COMPARE:"compare",ALL_OF:"allOf",ANY_OF:"anyOf",NOT:"not"},S7=new Set(Object.values(Df)),qH=new Set(Object.values(lb)),T7=new Set([...qH,z.ROUTE])});var pR,fR,hR,db,JH,mR,nr,gR,je,on,Pf,Iu=y(()=>{"use strict";pR=1,fR={FLOW_REPLAY:"flow_replay",MANUAL:"manual"},hR={PASS:"pass",DRIFT:"drift",ERROR:"error",FAIL:"fail"},db=2,JH=3,mR=new Set([1,db,JH]),nr={TESTID:"testid",ROLE:"role",SIGNAL:"signal",COMPONENT:"component"},gR="unresolved",je={ASSERT_SIGNAL:"assert-signal",ASSERT_VISIBLE:"assert-visible",ASSERT_STATE:"assert-state",ASSERT_NET:"assert-net",MARK_DYNAMIC:"mark-dynamic",SUCCESS_STATE:"success-state",INTENT:"intent"},on={IDLE:"idle",RECORDING:"recording",ANNOTATING:"annotating"},Pf={ACTIVE:"active",QUARANTINED:"quarantined",DRAFT:"draft"}});var ER,pb=y(()=>{"use strict";ER={READ:"read",IDEMPOTENT:"idempotent",COMMITS:"commits"}});var bR=y(()=>{"use strict"});var w,Cu,ks,_R=y(()=>{"use strict";w={DOM_ADDED:"dom.added",DOM_REMOVED:"dom.removed",DOM_ATTR:"dom.attr",DOM_TEXT:"dom.text",NET_REQUEST:"net.request",NET_PENDING:"net.pending",NET_STREAM:"net.stream",PERF:"perf",ROUTE_CHANGE:"route.change",CONSOLE_LOG:"console.log",CONSOLE_WARN:"console.warn",CONSOLE_ERROR:"console.error",CONSOLE_INFO:"console.info",CONSOLE_DEBUG:"console.debug",ERROR_UNCAUGHT:"error.uncaught",VISIBLE_SHOWN:"visible.shown",ANIM_START:"anim.start",ANIM_END:"anim.end",SCROLL_POSITION:"scroll.position",REVEAL_SHOWN:"reveal.shown",SIGNAL:"signal",STATE_CHANGE:"state.change",STORAGE_CHANGE:"storage.change",PAGE_HEALTH:"page.health",CONTEXT_OPENED:"context.opened",DIALOG_OPENED:"dialog.opened",RENDER_COMMIT:"render.commit",FOCUS_CHANGE:"focus.change",FIELD_CHANGE:"field.change",FLOW_RECORDED:"flow.recorded",TRANSPORT_OVERFLOW:"transport.overflow",TRUNCATED:"truncated",BLIND_SPOT:"blind-spot",SDK_FAILED:"sdk.failed",NET_DETAIL:"net.detail",NET_RESPONSE_BODY:"net.response-body",HUMAN_CONTROL:"human.control",HUMAN_MARK:"human.mark",DOWNLOAD:"download",HUD_USED:"hud.used",MEDIA_STATE:"media.state",CANVAS_DIGEST:"canvas.digest"},Cu={PLAY:"play",PLAYING:"playing",PAUSE:"pause",SEEKED:"seeked",ENDED:"ended",LOADED_DATA:"loadeddata",CAN_PLAY:"canplay",WAITING:"waiting",ERROR:"error"},ks={POLL:"poll",ACT:"act"}});function TR(e=fb,t=QH){return`ws://${t}:${String(e)}${zs}`}var fb,zs,Mf,SR,QH,rr,Uf,N7,Z,ve,Hf,xR,AR,yR,ac,R7,wR,I7,Lu,Ff,Bf,vR,cc,$u,eF,C7,D,NR,RR,Se,at,H,ct,lc,sn,Kt=y(()=>{"use strict";bR();_R();fb=4400,zs="/reticle",Mf=1,SR=1,QH="localhost";rr={SESSION:"__reticle_session",PROJECT:"__reticle_project",OPENED:"__reticle_opened",HUD:"__reticle_hud"},Uf="https://app.reticle.sh",N7={MAX_RUNS:50,MAX_BYTES:4*1024*1024},Z={MAX_MESSAGE_BYTES:1024*1024,MAX_MESSAGES_PER_SECOND:2e4,MAX_SESSIONS:32,MAX_PENDING_CONNECTIONS:16,HELLO_TIMEOUT_MS:5e3,MAX_BUFFER_BYTES:8*1024*1024,MAX_SESSION_ID_LENGTH:128,MAX_URL_LENGTH:4096,MAX_TITLE_LENGTH:512,MAX_ADAPTERS:32,MAX_CONTRACT_NAMES:128,MAX_ADAPTER_NAME_LENGTH:128,MAX_TOKEN_LENGTH:512,MAX_COMMAND_ID_LENGTH:128,MAX_COMMAND_NAME_LENGTH:128,MAX_REF_LENGTH:128,MAX_ERROR_LENGTH:4096,MAX_STACK_LENGTH:4e3,MAX_SERIALIZE_DEPTH:8,MAX_COLLECTION_ITEMS:200,MAX_OBJECT_KEYS:200,MAX_STRING_LENGTH:64*1024,MAX_MARK_NOTE_LENGTH:2e3,MAX_MARK_LABEL_LENGTH:256},ve="[REDACTED]",Hf="confirmDangerous",xR="native",AR="reveal",yR="inViewport",ac={NO_PROVIDER:"no-visual-provider",CAPTURE_FAILED:"capture-failed",BASELINE_MISSING:"baseline-missing",DIMENSION_MISMATCH:"dimension-mismatch",FULL_PAGE_UNSUPPORTED:"full-page-unsupported",CROP_UNSUPPORTED:"crop-unsupported",NOT_COMPOSITED:"window-not-composited"},R7=1440*60*1e3,wR=1,I7={MAX_EVENTS:2e3,MAX_AGE_MS:6e4,MAX_BYTES:Z.MAX_BUFFER_BYTES},Lu="reticle:busy",Ff="__reticle_renders",Bf={DOM:"dom",JOURNAL:"journal"},vR={WINDOW:"window"},cc={LCP:"lcp",CLS:"cls",LONGTASK:"longtask"},$u={HOVER_NATIVE_ENTER_LEAVE:"target has enter/leave handlers; synthetic hover may not trigger them \u2014 expect no state change",REAL_INPUT_FELL_BACK:"real-input provider was available but failed; fell back to synthetic dispatch",CLICK_OCCLUDED:"target is visually occluded by another element; a real user could not click it (synthetic dispatch still delivered the event) \u2014 dismiss the overlay or scroll the target clear",GLOBAL_PRESS:"press landed on the focused element or document \u2014 no named target was given, so this effect does not claim one",CLICK_NOT_A_CONTROL:"target is not a control and sits inside none (no button/link/input role, onclick, tabindex or pointer cursor), so a click on it may do nothing \u2014 if nothing happened, target the control inside it by role"},eF="console.",C7=[w.CONSOLE_LOG,w.CONSOLE_WARN,w.CONSOLE_ERROR,w.CONSOLE_INFO].map(e=>e.slice(eF.length)),D={CLICK:"click",DBLCLICK:"dblclick",HOVER:"hover",FOCUS:"focus",BLUR:"blur",FILL:"fill",TYPE:"type",CLEAR:"clear",SELECT:"select",CHECK:"check",UNCHECK:"uncheck",SUBMIT:"submit",PRESS:"press",UPLOAD:"upload",SCROLL_INTO_VIEW:"scrollIntoView",SCROLL:"scroll",DRAG:"drag",TAP:"tap",ZOOM:"zoom"},NR={TIMEOUT:"timeout",THROTTLED:"throttled"},RR={UNAVAILABLE:"component-state-unavailable"},Se={VISIBLE:"visible",HIDDEN:"hidden",ENABLED:"enabled",DISABLED:"disabled",CHECKED:"checked",EXPANDED:"expanded",PRESSED:"pressed",FOCUSED:"focused",PRESENT:"present",IN_VIEWPORT:"inViewport"},at={ROLE:"role",TEXT:"text",LABEL:"label",PLACEHOLDER:"placeholder",TESTID:"testid",ALT:"alt",COMPONENT:"component"},H={SNAPSHOT:"snapshot",QUERY:"query",MATCH:"match",INSPECT:"inspect",ACT:"act",ACT_SEQUENCE:"act_sequence",ANIMATIONS:"animations",NARRATE:"narrate",CLOCK:"clock",CAPABILITIES:"capabilities",STATE_READ:"state_read",STORAGE_READ:"storage_read",SCROLL:"scroll",SESSION_CONFIG:"session_config",PRESENTER:"presenter",IMPACT:"impact",CAPTURE:"capture",RENDER:"render",NAVIGATE:"navigate",REFRESH:"refresh",FLOWS:"flows",FLOW_PROGRESS:"flow.progress",PLAN:"plan",MARKERS:"markers"},ct={IDLE:"idle",READING:"reading",ACTING:"acting"},lc={FULL:"full",INTERACTIVE:"interactive",STATUS:"status"},sn={HELLO:"hello",COMMAND:"command",COMMAND_RESULT:"command_result",EVENT:"event"}});var or,tF,ir,k7,Ds=y(()=>{"use strict";ae();or={WEB:"web",DESKTOP:"desktop",MOBILE:"mobile",SERVICE:"service",GAME:"game",DEVICE:"device"},tF=wt([R(or),p().regex(/^x-[a-z0-9-]+$/,"a surface this specification does not name must start with x-")]),ir=b({surface:tF,instance:p().min(1),epoch:S().int().nonnegative().optional(),locator:p().optional(),revision:p().optional()}),k7=b({kind:pe(["instance","epoch"]),from:p(),to:p()})});var $,Un,Tn,an,hb,mb,Lr=y(()=>{"use strict";ae();$={UI:"ui",NET:"net",STATE:"state",SIGNAL:"signal",LOG:"log",ROUTE:"route",STORAGE:"storage",TIME:"time",VISUAL:"visual"},Un=wt([R($),p().regex(/^x-[a-z0-9-]+$/,"a channel this specification does not name must start with x-")]),Tn={INDEPENDENT:"independent",ACTUATION_DERIVED:"actuation-derived"},an={CONSEQUENCE:"consequence",PRESENCE:"presence",CONTEXT:"context"},hb=b({id:Un,independence:R(Tn),grade:R(an),note:p().optional()}),mb={[$.UI]:{independence:Tn.ACTUATION_DERIVED,grade:an.PRESENCE},[$.NET]:{independence:Tn.INDEPENDENT,grade:an.CONSEQUENCE},[$.STATE]:{independence:Tn.ACTUATION_DERIVED,grade:an.CONSEQUENCE},[$.SIGNAL]:{independence:Tn.ACTUATION_DERIVED,grade:an.CONSEQUENCE},[$.LOG]:{independence:Tn.INDEPENDENT,grade:an.CONTEXT},[$.ROUTE]:{independence:Tn.ACTUATION_DERIVED,grade:an.PRESENCE},[$.STORAGE]:{independence:Tn.ACTUATION_DERIVED,grade:an.CONSEQUENCE},[$.TIME]:{independence:Tn.INDEPENDENT,grade:an.CONTEXT},[$.VISUAL]:{independence:Tn.ACTUATION_DERIVED,grade:an.PRESENCE}}});var OR=y(()=>{"use strict"});var U7,IR=y(()=>{"use strict";ae();Ds();U7=b({id:p().min(1),subject:ir,capturedAt:S().int(),payload:q().optional()})});var F7,CR=y(()=>{"use strict";ae();F7=b({mutation:p().min(1)})});var nF,gb,rF,oF,LR,$R,Eb,kR,zR,ku=y(()=>{"use strict";ae();Lr();nF={USER:"user",DEVELOPER:"developer",AGENT:"agent",SYSTEM:"system",WORKFLOW:"workflow",DERIVED:"derived"},gb={DECLARED:"declared",BOUND:"bound",ABANDONED:"abandoned"},rF=b({id:p().min(1),statement:p().min(1),origin:R(nF),claims:C(p()).default([]),declaredAt:S().int().optional()}),oF=vt("status",[b({status:U(gb.ABANDONED),abandonedBecause:p().trim().min(1)}),b({status:U(gb.DECLARED),abandonedBecause:Ru().optional()}),b({status:U(gb.BOUND),abandonedBecause:Ru().optional()})]),LR=rF.and(oF),$R={BEFORE_ACTION:"before-action",AFTER_ACTION:"after-action"},Eb=b({id:p().min(1),predicate:q().optional(),reads:p().min(1),channels:C(Un).min(1)}),kR=b({id:p().min(1),intent:p().optional(),statement:p().min(1),declaredAt:R($R),assertions:C(Eb).default([])}),zR=b({id:p().min(1),statement:p().min(1),predicate:q().optional(),channels:C(Un).min(1),severity:pe(["blocking","advisory"]).default("blocking")})});var iF,uc,Z7,bb,DR,PR,sF,MR,$i=y(()=>{"use strict";ae();Lr();Ds();iF=b({id:p().min(1),window:p().min(1),channel:Un,at:S().int(),value:q().optional(),summary:p().min(1)}),uc={AUTHORITATIVE:"authoritative",DERIVED:"derived",OBSERVED:"observed",LEARNED:"learned"},Z7={[uc.LEARNED]:0,[uc.OBSERVED]:1,[uc.DERIVED]:2,[uc.AUTHORITATIVE]:3},bb=b({class:R(uc),source:p().min(1),method:p().min(1),subject:ir,at:S().int(),confidence:S().min(0).max(1).optional()}),DR=b({observation:iF,provenance:bb,independence:R(Tn),grade:R(an)}),PR={CHANNEL_UNOBSERVED:"channel-unobserved",BOUNDARY_UNCROSSABLE:"boundary-uncrossable",BUFFER_TRUNCATED:"buffer-truncated",REDACTED:"redacted",STILL_IN_FLIGHT:"still-in-flight",EFFECT_ELSEWHERE:"effect-elsewhere"},sF=b({kind:R(PR),channel:Un.optional(),detail:p().min(1),impeaching:L(),remedy:p().optional()}),MR=b({window:p().min(1),observed:C(Un),blindSpots:C(sF)})});var cF,lF,Gf,uF,Vf,_b,q7,UR=y(()=>{"use strict";ae();Lr();$i();cF=b({channel:Un}),lF=wt([b({summary:p().min(1),valueContains:p().min(1)}),b({summary:p().min(1).optional(),valueContains:Ru().optional()})]),Gf=cF.and(lF),uF={EXACTLY:"exactly",AT_LEAST:"at-least",AT_MOST:"at-most"},Vf={COUNT:"count",PRESENT:"present",ABSENT:"absent",MEASURE:"measure"},_b={EQUALS:"equals",AT_LEAST:"at-least",AT_MOST:"at-most"},q7=vt("kind",[b({kind:U(Vf.COUNT),match:Gf,op:R(uF),value:S().int().nonnegative()}),b({kind:U(Vf.PRESENT),match:Gf}),b({kind:U(Vf.ABSENT),match:Gf}),b({kind:U(Vf.MEASURE),match:Gf,op:R(_b),value:S().finite(),tolerance:S().nonnegative().finite().default(0)})])});var eq,Sb,tq,jf,HR,zu,FR,nq,Ps=y(()=>{"use strict";ae();Ds();eq=b({name:p().min(1),meaning:p().min(1),parameters:q().optional(),mutating:L()}),Sb={UNDECLARED:"undeclared",UNSUPPORTED:"unsupported",UNRESOLVED:"unresolved",UNAVAILABLE:"unavailable",GUARDED:"guarded",MALFORMED:"malformed"},tq=b({ref:p().min(1),describes:p().min(1),at:p().optional()}),jf=b({id:p().min(1),actor:p().min(1),capability:p().min(1),target:p().optional(),parameters:q().optional(),at:S().int()}),HR=b({action:p().min(1),dispatched:L(),refused:b({reason:R(Sb),detail:p().min(1)}).optional(),subject:ir,at:S().int()}),zu={QUIESCENCE:"quiescence",TICKS:"ticks",ACK:"ack",SIGNAL:"signal",SETTLED_PHYSICAL:"settled-physical",EXIT:"exit",TERMINATED:"terminated",BUDGET_EXHAUSTED:"budget-exhausted"},FR=b({id:p().min(1),openedAt:S().int(),closedAt:S().int().optional(),budgetMs:S().int().positive(),closes:R(zu),closedBy:R(zu).optional(),subject:ir}),nq=new Set([zu.BUDGET_EXHAUSTED,zu.TERMINATED])});var Kf,dF,BR,pF,Tb,xb,GR,dc=y(()=>{"use strict";ae();Lr();Kf={YES:"yes",NO:"no",UNKNOWN:"unknown",NO_FAULT:"no-fault"},dF=p().min(1),BR={ADVANCED_OVER_FAILURE:"advanced-over-failure",CLAIMED_OVER_FAILURE:"claimed-over-failure",EFFECT_DISCARDED:"effect-discarded",CLAIM_UNCORROBORATED:"claim-uncorroborated",FAILURE_INSIDE_SUCCESS:"failure-inside-success",VALUE_NOT_APPLIED:"value-not-applied",DUPLICATED_EFFECT:"duplicated-effect",STALE_APPLIED:"stale-applied",NO_EFFECT:"no-effect",FAULT_MISATTRIBUTED:"fault-misattributed",EVIDENCE_SUPERSEDED:"evidence-superseded",EVIDENCE_PREDATES_EDIT:"evidence-predates-edit"},pF=wt([R(BR),p().regex(/^x-[a-z0-9-]+$/,"an anomaly this specification does not name must start with x-")]),Tb={OBSERVED:"observed",ABSENCE_DERIVED:"absence-derived",ADVISORY:"advisory"},xb=b({kind:pF,tier:R(Tb),claim:p().min(1),counter:p().min(1),between:kf([Un,Un]),evidence:C(p()).default([])}),GR=b({id:p().min(1),claim:p().min(1),window:p().min(1),verdict:R(Kf),grade:R(an).optional(),reasons:C(dF).default([]),evidence:C(p()).default([]),anomalies:C(xb).default([]),supersedes:p().optional(),at:S().int()})});var fF,hF,mF,uq,VR,gF,dq,Ab=y(()=>{"use strict";ae();Ps();ku();$i();dc();fF=p().min(1).regex(/^(?!.*(?:^|\/)\.{1,2}(?:\/|$))[^/]+(?:\/[^/]+)*$/,{message:"a flow name is `/`-separated segments: no empty segment, no leading or trailing slash, no `.` or `..`"}),hF=b({id:p().min(1),invoke:fF,with:q().optional(),at:S().int()}),mF=wt([jf,hF]),uq=b({name:p().min(1),version:S().int().positive(),startState:q().optional(),requires:q().optional(),ensures:q().optional(),claim:p().min(1),steps:C(mF),expects:C(Eb).default([]),mayRebind:L().default(!1)}),VR=b({verdict:p().min(1),expected:p().min(1),actual:p().min(1),evidence:C(p()).min(1),location:b({file:p(),line:S().int().optional(),symbol:p().optional()}).optional(),instruction:p().min(1)}),gF={INVARIANT:"invariant",FAILURE_MODE:"failure-mode",GAP:"gap",REPAIR_OUTCOME:"repair-outcome"},dq=b({id:p().min(1),kind:R(gF),statement:p().min(1),provenance:bb,observations:S().int().nonnegative().default(0),promotedBy:p().optional(),promotedAt:S().int().optional()})});var EF,bF,Sq,jR=y(()=>{"use strict";ae();Lr();ku();Ps();$i();dc();Ab();Ds();EF="1.0",bF=b({constraint:p().min(1),at:S().int(),detail:p().min(1),evidence:C(p()).default([])}),Sq=b({ovp:U(EF),id:p().min(1),verifier:b({name:p().min(1),version:p().min(1),profile:p().optional()}),subject:ir,channels:C(hb),witnesses:C(b({name:p().min(1),subject:ir,channels:C(hb)})).default([]),intents:C(LR).default([]),claims:C(kR).default([]),constraints:C(zR).default([]),actions:C(jf).default([]),receipts:C(HR).default([]),windows:C(FR).default([]),evidence:C(DR).default([]),coverage:C(MR).default([]),anomalies:C(xb).default([]),verdicts:C(GR).default([]),violations:C(bF).default([]),repairs:C(VR).default([]),startedAt:S().int(),endedAt:S().int()})});var yb=y(()=>{"use strict";dc()});var wb=y(()=>{"use strict";ku();Lr();$i();Ps();dc()});var vb=y(()=>{"use strict";Ps();Lr();yb();$i();wb()});var Nb=y(()=>{"use strict"});var KR=y(()=>{"use strict";Nb()});var Ms,Vq,jq,Kq,ZR=y(()=>{"use strict";ae();Lr();Ms={EFFECT:"effect",IN_REALM:"in-realm",SURFACE:"surface"},Vq=[Ms.EFFECT,Ms.IN_REALM,Ms.SURFACE],jq={[Ms.EFFECT]:[$.NET,$.LOG],[Ms.IN_REALM]:[$.NET,$.LOG,$.STATE,$.SIGNAL],[Ms.SURFACE]:[$.NET,$.LOG,$.STATE,$.SIGNAL,$.UI]},Kq=b({name:p().min(1),version:p().min(1),platform:p().min(1),claims:R(Ms),homepage:p().optional()})});var WR=y(()=>{"use strict";vb();Lr();Ps();$i();Ds()});var pc=y(()=>{"use strict";Ds();Lr();OR();IR();CR();ku();UR();Ps();$i();dc();Ab();jR();vb();yb();Nb();KR();wb();ZR();WR()});var Hn,lt,YR,cn,jo=y(()=>{"use strict";Hn={YES:"yes",NO:"no",UNKNOWN:"unknown",NO_FAULT:"no-fault"},lt={VERSION_SKEW:"version_skew",CAPABILITY_ABSENT:"capability-absent",INCONCLUSIVE:"inconclusive",OBSERVATION_LOST:"observation_lost",WINDOW_CLOSED_EARLY:"window_closed_early",ASSERTION_FAILED:"assertion_failed",CONTRADICTED:"contradicted",ALREADY_TRUE:"already_true",HIDDEN_MATCH:"hidden_match",UNCLEAN_CAPTURE:"unclean_capture",VACUOUS_GRADE:"vacuous_grade",NOTHING_DECLARED:"nothing_declared",OUTCOME_PENDING:"outcome_pending",OUTCOME_UNREAD:"outcome_unread",UNSETTLED:"unsettled",EVIDENCE_INCOMPLETE:"evidence_incomplete",PROVED:"proved",ABSENCE_BLIND_SPOT:"absence_blind_spot"},YR={BUFFER_LOSS:"buffer_loss",TRANSPORT_GAP:"transport_gap",BLIND_SPOT:"blind_spot",JOURNAL_LOSS:"journal_loss",OTHER:"other"},cn={CLOSED_SHADOW_ROOT:"closed-shadow-root",RATE_LIMITED:"rate-limited",CROSS_ORIGIN_IFRAME:"cross-origin-iframe",UNINSTRUMENTED_FRAME:"uninstrumented-frame",VIRTUALIZED_UNMOUNTED:"virtualized-unmounted",WRAPPED_NETWORK:"wrapped-network",UNOBSERVED_IPC:"unobserved-ipc",VERDICTLESS_SEND:"verdictless-send",UNWATCHED_STATE:"unwatched-state"}});var TF,xF,XR,Rb=y(()=>{"use strict";ae();jo();TF={FINDABLE:"findable",DISCOVERABILITY:"discoverability",AGENT_ASSUMPTION:"agent_assumption",DEFECT:"defect"},xF=20,XR=b({goal:p().min(1).max(500),kind:R(TF),agent:b({verified:R(Hn),claim:p().max(2e3)}),harness:b({verified:R(Hn),found:L(),searched:C(p().max(500)).max(xF),gaveUpAt:p().max(500).optional()})})});var AF,yF,wF,vF,NF,RF,qR,OF,Zf,IF,CF,LF,$F,kF,zF,DF,PF,MF,UF,OJ,HF,Ob,Ib,FF,BF,GF,VF,jF,KF,ZF,WF,YF,XF,IJ,Cb=y(()=>{"use strict";ae();pc();Vo();jo();Rb();AF=3,yF=1,wF=2,vF={pass:Hn.YES,fail:Hn.NO},NF={network:z.NET,layout:z.ELEMENT},RF=p().brand(),qR={PASS:"pass",FAIL:"fail",PARTIAL:"partial",UNKNOWN:"unknown"},OF={PASS:"pass",FAIL:"fail",SKIPPED:"skipped",HEALED:"healed"},Zf={AUTH:"auth",PAYMENT:"payment",DB:"db",MIGRATION:"migration",RLS:"rls",SECRETS:"secrets",DESTRUCTIVE:"destructive",EXTERNAL:"external"},IF={LOW:"low",MEDIUM:"medium",HIGH:"high",CRITICAL:"critical"},CF={EDIT:"edit",CI:"ci",MANUAL:"manual",OEM:"oem"},LF={ADDED:"added",MODIFIED:"modified",DELETED:"deleted"},$F={CODING_AGENT:"coding-agent",OEM_PIPELINE:"oem-pipeline",HUMAN:"human"},kF={REACT:"react",NEXT:"next",VITE:"vite",OTHER:"other"},zF={PREVIEW:"preview",CI:"ci",LOCAL:"local"},DF={HIGH:"high",MEDIUM:"medium",LOW:"low"},PF={DEV:"dev",PROD_PREVIEW:"prod-preview"},MF=b({file:p(),line:S().optional(),component:p().optional()}),UF=b({path:p(),changeKind:R(LF),risk:C(R(Zf)).default([])}),OJ=64*1024,HF={BROWSER:"browser",RENDERED:"rendered"},Ob={RUNS_DIR:"runs",MANIFEST_FILE:"shots.jsonl",JPEG_QUALITY:.7,MAX_SIDE_PX:1600,MAX_PER_RUN:300,MAX_BYTES:1.5*1024*1024,FRAME_TOOL:"frame"},Ib=b({file:p(),source:R(HF),width:S(),height:S(),sha256:p()}),FF=Ib.extend({seq:S(),tool:p(),step:p().optional(),verdict:L().optional(),checkId:p().optional(),actionId:p().optional()}),BF=b({step:S(),anchor:p(),ok:L(),page:p().optional(),endPage:p().optional(),consequence:p().optional(),error:p().optional(),drift:p().optional(),screenshot:Ib.optional()}),GF=b({startPath:p().optional(),steps:C(q())}),VF=b({name:p(),template:p().optional(),status:R(OF),steps:S(),durationMs:S(),oracle:p().optional(),healed:b({from:p(),to:p(),consequenceVerified:L()}).optional(),evidenceRef:p().optional(),failureReason:p().optional(),stepResults:C(BF).optional(),recording:GF.optional(),recordingOmitted:L().optional()}),jF=b({kind:Ou(e=>{var t;return typeof e=="string"&&(t=NF[e])!=null?t:e},R(z).optional()),predicate:p(),status:Ou(e=>{var t;return typeof e=="string"&&(t=vF[e])!=null?t:e},R(Hn)),evidence:q().optional(),declaredBeforeActing:L().optional(),expected:p().optional(),observed:p().optional(),grade:p().optional(),couldNotSee:C(p()).optional(),reason:p().optional(),checkId:p().optional(),actionId:p().optional(),intent:p().optional(),intentDerived:L().optional(),failedPart:S().int().min(0).optional(),screenshot:Ib.optional(),supersedes:p().optional()}),KF=b({surface:R(Zf),severity:R(IF),detail:p(),evidence:b({file:p().optional(),line:S().optional(),network:p().optional()}).optional(),gated:L().default(!1)}),ZF=b({consoleErrors:C(b({level:p(),message:p(),at:S()})).default([]),networkAnomalies:C(b({method:p(),url:p(),status:S().optional(),issue:p()})).default([]),stateAssertions:C(b({store:p(),path:p(),expected:q().optional(),actual:q().optional(),ok:L()})).default([]),timeline:C(b({at:S(),kind:p(),summary:p()})).default([])}),WF=b({flow:p().optional(),step:S().optional(),expected:p(),actual:p(),sourceLocation:MF.optional(),suggestedPrompt:p()}),YF=b({status:R(qR),reasons:C(p()).default([]),confidence:R(DF),blockingRisks:S().default(0),checkId:p().optional(),supersedes:p().optional()}),XF=b({alg:p(),value:p(),signedAt:S()}),IJ=b({schemaVersion:wt([U(AF),U(wF),U(yF)]),runId:RF,createdAt:S(),durationMs:S(),profile:R(PF),project:b({name:p(),framework:R(kF),commit:p().optional(),branch:p().optional(),env:R(zF).optional(),previewUrl:p().optional()}),agent:b({id:p(),kind:R($F),model:p().optional()}),episodeId:p().optional(),agentSession:p().optional(),trigger:b({kind:R(CF),diffRef:p().optional(),note:p().optional()}),editEpoch:S().optional(),subject:ir.optional(),context:ie(p(),q()).optional(),changedFiles:C(UF).default([]),flows:C(VF).default([]),checks:C(jF).default([]),risks:C(KF).default([]),evidence:ZF,repair:b({failurePackets:C(WF).default([])}).optional(),screenshots:C(FF).optional(),verdict:YF,signature:XF.optional(),disparity:C(XR).optional(),agentClaim:R(qR).optional()})});var qF,Du,JF,QF,eB,tB,DJ,nB,rB,oB,PJ,MJ,Lb=y(()=>{"use strict";ae();Kt();Iu();Cb();qF=C(p().refine(e=>!e.includes("="),{error:e=>`\`attrs\` takes attribute NAMES only, not \`name=value\` \u2014 got ${JSON.stringify(e.input)}. It PROJECTS each attribute onto the match, it does not filter on it. Drop the \`=value\` half and read the returned \`attrs\` map, or assert the value with an \`element\` predicate carrying \`value\`.`})),Du=b({by:R(at).optional(),value:p().optional(),role:p().optional(),name:p().optional(),text:p().optional(),label:p().optional(),placeholder:p().optional(),testid:p().optional(),alt:p().optional(),component:p().optional(),attrs:qF.optional(),source:b({file:p(),line:S(),column:S().optional()}).strict().optional(),scope:p().optional(),self:L().optional(),matchCase:L().optional()}).strict(),JF=b({name:p(),steps:C(p())}),QF=b({surface:R(Zf),paths:C(p()).optional(),note:p().optional()}),eB=b({owner:p().optional(),safety:C(p()).optional(),scope:C(p()).optional(),redact:C(p()).optional(),risk:C(QF).optional()}),tB=b({testids:C(p()),signals:C(p()),stores:C(p()),flows:C(JF),governance:eB.optional()}),DJ=b({version:U(wR),generatedAt:S(),capabilities:tB}),nB=b({consoleErrors:S().optional(),networkErrors:S().optional(),driftSteps:S().optional()}),rB=b({kind:R(fR),name:p(),status:R(hR),at:S(),summary:p().optional(),evidence:nB.optional(),durationMs:S().optional()}),oB=b({flows:C(p()).optional(),routes:C(p()).optional(),bestObservability:b({percent:S(),at:S()}).optional()}),PJ=b({version:U(pR),learned:oB.optional(),runs:C(rB)}),MJ=vt("kind",[b({kind:U(je.ASSERT_SIGNAL),name:p().min(1),dataMatches:ie(p(),q()).optional()}),b({kind:U(je.ASSERT_VISIBLE),testid:p().min(1)}),b({kind:U(je.ASSERT_STATE),statePath:p().min(1),store:p().min(1).optional(),equals:q().optional()}),b({kind:U(je.ASSERT_NET),net:b({method:p().min(1).optional(),urlContains:p().min(1).optional(),status:S().optional(),count:S().int().nonnegative().optional()})}),b({kind:U(je.MARK_DYNAMIC),testid:p().min(1)}),b({kind:U(je.SUCCESS_STATE),signal:p().min(1).optional(),testid:p().min(1).optional(),statePath:p().min(1).optional(),store:p().min(1).optional(),equals:q().optional(),hold:L().optional(),net:b({method:p().min(1).optional(),urlContains:p().min(1).optional(),status:S().optional(),count:S().int().nonnegative().optional()}).optional(),console:b({level:p().min(1).optional(),absent:L().optional()}).optional(),text:b({contains:p().min(1),scope:p().min(1).optional(),absent:L().optional(),visible:L().optional()}).optional()}),b({kind:U(je.INTENT),text:p().min(1)})])});function QR(e,t){let n=JR(e),r=JR(t);return[...new Set([...Object.keys(n),...Object.keys(r)])].every(i=>n[i]===r[i])}function JR(e){var t,n;return z.NET===e.from?{...e,body:(t=e.body)!=null?t:kb.RESPONSE,method:(n=e.method)==null?void 0:n.toUpperCase()}:{...e}}var kb,Wf,$b,zb,Db=y(()=>{"use strict";ae();Vo();kb={RESPONSE:"response",REQUEST:"request"},Wf={VALUE:"value",NUMBER:"number"},$b=p().min(1),zb=vt("from",[b({from:U(z.NET),urlContains:p().min(1),method:p().optional(),body:pe([kb.RESPONSE,kb.REQUEST]).optional(),path:$b}).strict(),b({from:U(z.SIGNAL),name:p().min(1),path:$b}).strict(),b({from:U(z.STATE),store:p().optional(),path:$b}).strict(),b({from:U(z.TEXT),scope:p().min(1)}).strict()])});var eO,Pb,Mb=y(()=>{"use strict";ae();pc();eO=b({op:R(_b),value:S().finite(),tolerance:S().finite().nonnegative().optional()}).strict(),Pb=vt("property",[b({property:U("nonEmpty")}).strict(),b({property:U("oneOf"),values:C(q()).min(1)}).strict(),b({property:U("withinTolerance"),of:S().finite(),tolerance:S().finite().nonnegative()}).strict(),b({property:U("matchesPattern"),pattern:p().min(1)}).strict(),b({property:U("type"),is:pe(["string","number","boolean","array","object"])}).strict(),b({property:U("changed")}).strict(),b({property:U("unchanged")}).strict(),b({property:U("increased"),by:eO.optional()}).strict(),b({property:U("decreased"),by:eO.optional()}).strict()])});function rO(e){if(e.kind!==void 0||typeof e[Ub]!="string")return e;let t={...e,kind:e[Ub]};return delete t[Ub],t}function oO(){var t;if(Hb!==void 0)return Hb;let e=new Map;for(let n of sO().options){let r=n.shape,o=String(r.kind.value),i=z.ELEMENT===o?nO:[];e.set(o,new Set([...Object.keys(r).filter(s=>s!=="kind"),...Object.keys((t=tO[o])!=null?t:{}),...i]))}return Hb=e,e}function sB(e){let t=iO(e);if(t.length===0)return;let n=oO(),r=a=>{let l=n.get(a);return l!==void 0&&t.every(u=>l.has(u))},o=t.flatMap(a=>{let l=iB[a];return l===void 0?[]:[l]});if(1<o.length)return;let[i]=o;if(i!==void 0)return r(i)?i:void 0;let s=[...n.keys()].filter(r);return s.length===1?s[0]:void 0}function aB(e){let t=rO(e);return t.kind===void 0?sB(t):void 0}function cB(e){let t=rO(e),n=aB(e);return n===void 0?t:{...t,kind:n}}function lB(e){let t=iO(e).map(n=>`\`${n}\``);return`this predicate has no \`kind\`, and its keys (${t.length>0?t.join(", "):"none"}) do not fit exactly one kind. Add \`kind\`: one of ${[...oO().keys()].join(", ")}`}function uB(e,t){if(typeof e!="object"||e===null||Array.isArray(e))return e;let r=cB(e);r.kind===void 0&&t.addIssue({code:Go.custom,message:lB(r)});let o=typeof r.kind=="string"?r.kind:"",i=tO[o],s=r;if(i!==void 0){s={...r};for(let[a,l]of Object.entries(i))s[a]!==void 0&&(s[l]===void 0&&(s[l]=s[a]),delete s[a])}return z.ELEMENT===o?dB(s):s}function dB(e){if(e.query!==void 0)return e;let t=nO.filter(o=>e[o]!==void 0);if(t.length===0)return e;let n={...e},r={};for(let o of t)r[o]=n[o],delete n[o];return n.query=r,n}function sO(){return vt("kind",[b({kind:U(z.ELEMENT),query:Du,state:R(Se).optional(),absent:L().optional()}).strict(),b({kind:U(z.TEXT),contains:p().optional(),visible:L().optional(),absent:L().optional(),scope:p().optional(),self:L().optional(),satisfies:Pb.optional(),ignoreCase:L().optional()}).strict(),b({kind:U(z.NET),method:p().optional(),urlContains:p().optional(),status:S().optional(),ok:L().optional(),since:S().optional(),count:S().int().nonnegative().optional(),bodyContains:p().min(1).optional(),bodyMatches:ie(p(),q()).optional(),requestBodyContains:p().min(1).optional(),requestBodyMatches:ie(p(),q()).optional(),repeatable:L().optional()}).strict(),b({kind:U(z.ROUTE),pathname:p().optional(),contains:p().optional(),since:S().optional()}).strict(),b({kind:U(z.CONSOLE),level:p().optional(),contains:p().min(1).optional(),absent:L().optional(),since:S().optional()}).strict(),b({kind:U(z.ANIMATION),name:p().optional(),target:p().optional(),completed:L().optional(),since:S().optional()}).strict(),b({kind:U(z.SIGNAL),name:p().optional(),dataMatches:ie(p(),q()).optional(),count:S().int().nonnegative().optional(),since:S().optional()}).strict(),b({kind:U(z.STATE),store:p().optional(),path:p(),equals:q().optional(),satisfies:Pb.optional()}).strict(),b({kind:U(z.SETTLED),quietMs:S().positive().optional(),channel:pe([ub.NETWORK,ub.APP]).optional()}).strict(),b({kind:U(z.COMPARE),left:zb,right:zb,as:pe([Wf.VALUE,Wf.NUMBER]).optional(),tolerance:S().finite().nonnegative().optional()}).strict(),b({kind:U(z.ALL_OF),predicates:C(Pu).min(1)}).strict(),b({kind:U(z.ANY_OF),predicates:C(Pu).min(1)}).strict(),b({kind:U(z.NOT),predicate:Pu}).strict()])}function pB(e,t){if(typeof e!="object"||e===null)return;let n=e;if(z.NET===n.kind){fB(n.repeatable,n.urlContains,t);return}if(z.COMPARE===n.kind){hB(e,t);return}z.TEXT===n.kind&&(n.contains===void 0&&n.satisfies===void 0&&t.addIssue({code:Go.custom,message:"a text predicate must say WHAT about the text: `contains` for a substring, `satisfies` for a property of it. With neither it matches any element with any text and cannot fail"}),n.satisfies!==void 0&&n.contains===void 0&&n.scope===void 0&&t.addIssue({code:Go.custom,message:"`satisfies` needs a subject: add `scope` (the element whose text is tested, with `self: true` to read the scope root itself) or a `contains` that selects one. Without either, the locator is every element on the page and the property would run against whichever one happened to match first"}))}function fB(e,t,n){e===!0&&(typeof t=="string"&&t.trim().length>0||n.addIssue({code:Go.custom,message:'`repeatable: true` needs a non-empty `urlContains` naming the read endpoint, for example `{ kind: "net", method: "POST", urlContains: "/graphql", repeatable: true }`. Without one it would excuse every request in the window from duplicate-request, a real double submit included'}))}function hB(e,t){QR(e.left,e.right)&&t.addIssue({code:Go.custom,message:"`left` and `right` read the same value, so this comparison agrees with itself on every page and cannot fail. Compare two different readings: what the page shows against what the server answered, or what was sent against what came back"}),e.tolerance!==void 0&&Wf.NUMBER!==e.as&&t.addIssue({code:Go.custom,message:'`tolerance` applies to a numeric comparison only: add `as: "number"`'})}var tO,Ub,nO,iB,Hb,iO,Pu,Fb=y(()=>{"use strict";ae();Lb();Kt();Db();Vo();Mb();tO={[z.TEXT]:{text:"contains",value:"contains",query:"contains"},[z.ROUTE]:{path:"pathname",urlContains:"contains",url:"contains",pathContains:"contains"},[z.NET]:{url:"urlContains",responseBodyMatches:"bodyMatches",pathContains:"urlContains"},[z.CONSOLE]:{textContains:"contains"},[z.SIGNAL]:{data:"dataMatches"},[z.ALL_OF]:{of:"predicates",allOf:"predicates"},[z.ANY_OF]:{of:"predicates",anyOf:"predicates"},[z.NOT]:{of:"predicate",not:"predicate"}},Ub="type",nO=Object.keys(Du.shape);iB={text:z.TEXT,allOf:z.ALL_OF,anyOf:z.ANY_OF,not:z.NOT};iO=e=>Object.keys(e).filter(t=>e[t]!==void 0);Pu=zf(()=>Ou(uB,sO()).superRefine(pB))});function aO(e){return`${e} is an element ref, which only exists in the session that minted it \u2014 scope by a CSS selector or a testid so the flow can check it again`}function Yf(e){let t=(n,r)=>r!==void 0&&mB.test(r)?`${n} "${r}"`:void 0;switch(e.kind){case z.ALL_OF:case z.ANY_OF:for(let n of e.predicates){let r=Yf(n);if(r!==void 0)return r}return;case z.NOT:return Yf(e.predicate);case z.TEXT:return t("text.scope",e.scope);case z.ELEMENT:return t("element.query.scope",e.query.scope);case z.ANIMATION:return t("animation.target",e.target);case z.COMPARE:for(let[n,r]of[["left",e.left],["right",e.right]]){if(z.TEXT!==r.from)continue;let o=t(`compare.${n}.scope`,r.scope);if(o!==void 0)return o}return;default:return}}var mB,Bb=y(()=>{"use strict";Vo();mB=/^e\d+$/});function lO(e){let t=[];if(e.signal!==void 0){let s={kind:z.SIGNAL,name:e.signal};e.signalData!==void 0&&(s.dataMatches=e.signalData),e.signalCount!==void 0&&(s.count=e.signalCount,t.push({kind:z.SETTLED})),t.push(s)}if(e.route!==void 0){let s={kind:z.ROUTE};return e.route.pathname!==void 0&&(s.pathname=e.route.pathname),e.route.contains!==void 0&&(s.contains=e.route.contains),s}if(e.net!==void 0){let s={kind:z.NET};e.net.method!==void 0&&(s.method=e.net.method),e.net.urlContains!==void 0&&(s.urlContains=e.net.urlContains),e.net.status!==void 0&&(s.status=e.net.status),e.net.count!==void 0&&(s.count=e.net.count,t.push({kind:z.SETTLED})),t.push(s)}if(e.console!==void 0){let s={kind:z.CONSOLE};e.console.level!==void 0&&(s.level=e.console.level),e.console.absent!==void 0&&(s.absent=e.console.absent,e.console.absent&&t.push({kind:z.SETTLED})),t.push(s)}let n=e.state;if(n!==void 0){let s={kind:z.STATE,path:n.path};n.store!==void 0&&(s.store=n.store),n.equals!==void 0&&(s.equals=n.equals),n.hold===!0&&t.push({kind:z.SETTLED}),t.push(s)}let r=e.element;if(r!==void 0){let s={};r.testid!==void 0&&(s.testid=r.testid),r.role!==void 0&&(s.role=r.role),r.name!==void 0&&(s.name=r.name),Object.keys(s).length>0&&t.push({kind:z.ELEMENT,query:s})}let o=e.text;if(o!==void 0){let s={kind:z.TEXT,contains:o.contains};o.scope!==void 0&&(s.scope=o.scope),o.visible!==void 0&&(s.visible=o.visible),o.absent===!0&&(s.absent=!0,t.push({kind:z.SETTLED})),t.push(s)}let[i]=t;if(t.length!==0)return t.length===1&&i!==void 0?i:{kind:z.ALL_OF,predicates:t}}var cO,Gb=y(()=>{"use strict";ae();Vo();cO=b({route:b({pathname:p().optional(),contains:p().optional()}).optional(),signal:p().optional(),signalData:ie(p(),q()).optional(),signalCount:S().int().nonnegative().optional(),net:b({method:p().optional(),urlContains:p().optional(),status:S().optional(),count:S().int().nonnegative().optional()}).strict().optional(),console:b({level:p().optional(),absent:L().optional()}).strict().optional(),element:b({testid:p().optional(),role:p().optional(),name:p().optional()}).strict().optional(),text:b({contains:p().min(1),scope:p().optional(),absent:L().optional(),visible:L().optional()}).strict().optional(),state:b({store:p().optional(),path:p(),equals:q().optional(),hold:L().optional()}).strict().optional()}).strict()});var uO=y(()=>{"use strict"});var pO,gB,Vb,dO,EB,fO,bB,cQ,hO=y(()=>{"use strict";ae();Iu();pb();Kt();Fb();Bb();Gb();Iu();uO();pO=vt("kind",[b({kind:U(nr.TESTID),value:p().min(1),of:S().int().min(2).optional(),source:b({file:p(),line:S(),column:S().optional()}).optional()}),b({kind:U(nr.ROLE),role:p().min(1),name:p().optional(),nth:S().int().min(0).optional(),of:S().int().min(2).optional()}),b({kind:U(nr.SIGNAL),name:p().min(1)}),b({kind:U(nr.COMPONENT),component:p().optional(),source:b({file:p(),line:S(),column:S().optional()}).optional(),role:p().optional(),name:p().optional()})]),gB=Pu.superRefine((e,t)=>{let n=Yf(e);n!==void 0&&t.addIssue({code:Go.custom,message:aO(n)})}),Vb=wt([gB,cO.transform(e=>lO(e))]),dO=C(Vb).transform(e=>e.filter(t=>t!==void 0)),EB=b({tool:p(),anchor:pO,source:b({file:p().min(1),line:S().int().positive().optional()}).optional(),id:p().min(1).optional(),effect:R(ER).optional(),healed:b({from:p(),at:S()}).optional(),writes:L().optional(),action:R(D).optional(),args:ie(p(),q()).optional(),expect:Vb.optional(),degraded:L().optional(),timeoutMs:S().int().nonnegative().optional(),invoke:p().min(1).optional(),page:p().optional(),endPage:p().optional()}),fO=EB.extend({steps:zf(()=>C(fO).optional())}),bB=b({version:S().int().refine(e=>mR.has(e)),name:p(),intent:p().optional(),intentDerived:L().optional(),intentId:p().optional(),projectId:p().optional(),startPath:p().optional(),template:p().min(1).optional(),fixture:p().optional(),requires:dO.optional(),ensures:dO.optional(),author:b({agent:p().min(1).optional(),person:p().min(1).optional()}).optional(),createdAt:S(),steps:C(fO),signalTimeoutMs:S().int().positive().optional(),success:Vb.optional(),dynamic:C(pO).optional(),labels:C(p().min(1)).optional(),needs:C(p().min(1)).optional(),status:pe([Pf.ACTIVE,Pf.QUARANTINED,Pf.DRAFT]).optional(),learned:C(b({kind:p().min(1),step:S().int().min(-1),state:pe(["open","guarded"]),cleanRuns:S().int().nonnegative().optional()})).optional(),knownBugs:C(b({id:p().min(1),summary:p().min(1),assertions:C(p())})).optional(),quarantine:b({reason:p().min(1),since:p().min(1),owner:p().min(1),until:p().optional()}).optional()}),cQ=b({name:p(),flow:bB})});var mO=y(()=>{"use strict"});var gO=y(()=>{"use strict"});var EO=y(()=>{"use strict"});var xn,jb,Mu,_B,hQ,bO,Uu,_O,Kb,Xf,Hu=y(()=>{"use strict";xn={FETCH:"fetch",XHR:"xhr",BEACON:"beacon",IPC:"ipc",DOCUMENT:"document",NAVIGATION:"navigation"},jb="ipc://",Mu={OK:200,ERROR:500},_B={NEXT_DEV_OVERLAY:"/__nextjs",NEXT_HMR:"/_next/webpack-hmr",NEXT_HMR_CHUNKS:"/_next/static/webpack/",WEBPACK_HOT_UPDATE:".hot-update.",VITE_CLIENT:"/@vite/",VITE_REACT_REFRESH:"/@react-refresh",VITE_PING:"/__vite_ping"},hQ=Object.values(_B),bO="urlRaw",Uu="requestShape",_O="none",Kb="Next-Action",Xf="nextAction"});var bQ,SO=y(()=>{"use strict";Hu();bQ=new Set([xn.FETCH,xn.XHR])});var sr,Zb=y(()=>{"use strict";sr={ERROR_STATUS:"error-status",STREAMING:"streaming",NOT_TEXT:"not-text",UNREADABLE:"unreadable"}});var fc,qf,TO,xO=y(()=>{"use strict";fc="data-reticle-source",qf="__RETICLE_ROOT__",TO="__RETICLE_SDK_VERSION__"});var Us,AO,yO,wO=y(()=>{"use strict";Us="data-testid",AO=["data-test-subj","data-cy","data-test","data-qa","data-e2e"],yO=/^[a-zA-Z_][\w-]*$/});var vO,NO=y(()=>{"use strict";Kt();vO=new Set([w.DOM_TEXT,w.ANIM_START,w.ANIM_END,w.RENDER_COMMIT,w.PAGE_HEALTH,w.SCROLL_POSITION])});function Wb(e){let t=e.text;if(typeof t=="string"&&0<t.length)return t;let n=e.key;return typeof n=="string"&&0<n.length?n:SB}function Yb(e){let t=e.keys;if(!Array.isArray(t))return[];let n=[];for(let r of t)typeof r=="string"&&0<r.length&&n.push(r);return n}function OO(e){let t=e.modifiers;if(!Array.isArray(t))return[];let n=new Set;for(let r of t){if(typeof r!="string")continue;let o=AB[r.toLowerCase()];o!==void 0&&n.add(o)}return xB.filter(r=>n.has(r))}function yB(e){let t=e.modifiers;return Array.isArray(t)&&0<t.length}function IO(e){if(yB(e))return!0;let t=Yb(e);if(1<t.length)return!0;if(t.length===1){let n=t[0];return n!==void 0&&RO.has(n.toLowerCase())}return RO.has(Wb(e).toLowerCase())}var SB,TB,RO,xB,AB,Xb=y(()=>{"use strict";SB="Enter",TB=["Escape","Tab"],RO=new Set(TB.map(e=>e.toLowerCase()));xB=["Alt","Control","Meta","Shift"],AB={alt:"Alt",option:"Alt",opt:"Alt",control:"Control",ctrl:"Control",meta:"Meta",cmd:"Meta",command:"Meta",super:"Meta",win:"Meta",shift:"Shift"}});function qb(e){let t=e.button;if(t===void 0)return ar.LEFT;if(typeof t!="string")return;let n=t.toLowerCase();return CO.find(r=>r===n)}function LO(e,t){let n=qb(t);if(n===void 0)return`unsupported click button ${JSON.stringify(t.button)}: use ${CO.join(", ")}`;if(e===D.DBLCLICK&&n!==ar.LEFT)return"a dblclick uses the left button only: a browser sends no dblclick for another button";let r=t.modifiers;if(Array.isArray(r)){let o=r.filter(i=>OO({modifiers:[i]}).length===0);if(0<o.length)return`unsupported click modifier ${JSON.stringify(o[0])}: use Meta, Control, Shift or Alt`}}var ar,CO,$O=y(()=>{"use strict";Kt();Xb();ar={LEFT:"left",MIDDLE:"middle",RIGHT:"right"},CO=Object.values(ar)});function hc(e){return typeof e!="number"||!Number.isFinite(e)||e<=0?0:Math.min(e,3e4)}var kO=y(()=>{"use strict"});var wB,CQ,vB,LQ,zO=y(()=>{"use strict";ae();jo();wB="https://app.reticle.sh",CQ=`Reticle Cloud (not linked): keeps this history across runs and agents, adds a team view and the hosted Harness. Plans and prices: ${wB}`,vB=b({claim:p(),verified:R(Hn),evidence:p().optional()}),LQ=b({verified:R(Hn),claims:C(vB),caught:C(p()),flows:b({saved:C(p()),replayed:C(b({name:p(),verified:R(Hn)}))}),memory:b({written:S().int().min(0),read:S().int().min(0)}),wallMs:S().int().min(0),firstVerdictMs:S().int().min(0).optional(),cloud:p().optional()})});var Nt,zQ,DO=y(()=>{"use strict";jo();Nt={CODE:"code",ENVIRONMENT:"environment",HARNESS:"harness",COULD_NOT_SEE:"could-not-see",NONE:"none"},zQ={[lt.ASSERTION_FAILED]:Nt.CODE,[lt.CONTRADICTED]:Nt.CODE,[lt.OUTCOME_PENDING]:Nt.ENVIRONMENT,[lt.UNSETTLED]:Nt.ENVIRONMENT,[lt.VERSION_SKEW]:Nt.HARNESS,[lt.WINDOW_CLOSED_EARLY]:Nt.HARNESS,[lt.NOTHING_DECLARED]:Nt.HARNESS,[lt.VACUOUS_GRADE]:Nt.HARNESS,[lt.ALREADY_TRUE]:Nt.HARNESS,[lt.HIDDEN_MATCH]:Nt.HARNESS,[lt.CAPABILITY_ABSENT]:Nt.COULD_NOT_SEE,[lt.OBSERVATION_LOST]:Nt.COULD_NOT_SEE,[lt.UNCLEAN_CAPTURE]:Nt.COULD_NOT_SEE,[lt.EVIDENCE_INCOMPLETE]:Nt.COULD_NOT_SEE,[lt.ABSENCE_BLIND_SPOT]:Nt.COULD_NOT_SEE,[lt.OUTCOME_UNREAD]:Nt.COULD_NOT_SEE,[lt.INCONCLUSIVE]:Nt.COULD_NOT_SEE,[lt.PROVED]:Nt.NONE}});var Hs,NB,RB,OB,PQ,PO=y(()=>{"use strict";ae();Hs={CONNECTING:"connecting",WAITING_FOR_APP:"waiting_for_app",FLOWS_FOUND:"flows_found",FLOW_STARTED:"flow_started",FLOW_FINISHED:"flow_finished",GRADING:"grading",PUSHED:"pushed"},NB=120,RB=200,OB=b({phase:pe([Hs.CONNECTING,Hs.WAITING_FOR_APP,Hs.FLOWS_FOUND,Hs.FLOW_STARTED,Hs.FLOW_FINISHED,Hs.GRADING,Hs.PUSHED]),index:S().int().nonnegative().optional(),total:S().int().nonnegative().optional(),name:p().max(NB).optional(),ok:L().optional(),at:S().int().nonnegative()}),PQ=b({runId:p().min(1).max(200),events:C(OB).max(RB)})});function MO(e){return e===Xe.ACTIVE||e===Xe.PAUSED||e===Xe.ENDED}var Xe,Fu,ln,Fs,UO,HO,Bs,Jb=y(()=>{"use strict";Xe={ACTIVE:"active",PAUSED:"paused",ENDED:"ended"};Fu="auto",ln={PAUSE:"pause",RESUME:"resume",END:"end",MESSAGE:"message",REPLAY:"replay",SYNC:"sync",SIGNIN:"signin",HARNESS:"harness",HARNESS_RUN:"harness-run",HARNESS_STOP:"harness-stop",HARNESS_LINK:"harness-link"},Fs={TESTID:"testid",COMPONENT:"component",ROLE:"role",POSITION:"position"},UO={HEARTBEAT_MS:5e3,STALE_THRESHOLD_MS:12e3,LEDGER_NOTICE_FRACTION:.25},HO={IDLE_END_MS:3e5,IDLE_END_MIN_MS:5e3,REAP_INTERVAL_MS:5e3,BRIDGE_LOST_MS:15e3,DAEMON_IDLE_SHUTDOWN_MS:3e5,DAEMON_IDLE_CHECK_MS:3e4,DAEMON_AGENT_RECENT_MS:18e5},Bs={VISIBILITY:"visibilitychange",FOCUS:"focus",BLUR:"blur",HEARTBEAT:"heartbeat",INITIAL:"initial"}});var Fn,Dt,ki,Bu,Bn,FO,Jf,mc,An,Gu=y(()=>{"use strict";Fn={BUBBLE:"bubble",COLLAPSED:"collapsed",EXPANDED:"expanded"},Dt={CHAT:"chat",FLOWS:"flows",NOTES:"notes",HARNESS:"harness",SETTINGS:"settings",REPORT:"report",ACCOUNT:"account",NONE:"none"},ki={RAIL:"rail",HARNESS:"harness",HEADER:"header"},Bu={ON:"on",OFF:"off"},Bn={SHOWN:"shown",HIDDEN:"hidden",REMOVED:"removed"},FO="reload to restore",Jf={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right"},mc={PLAYING:"playing",PASSED:"passed",FAILED:"failed"},An={PENDING:"pending",RUNNING:"running",PASSED:"passed",FAILED:"failed",BLOCKED:"blocked",NOT_TAKEN:"not-taken",UNDECIDED:"undecided"}});var Vu,FQ,BO=y(()=>{"use strict";Vu="[data-reticle-overlay],[data-reticle-cursor],[data-reticle-hud],[data-reticle-glow],[data-reticle-mark],[data-reticle-blocker],[data-reticle-tour]",FQ=`${Vu}{display:none !important}`});var Qb,GO,IB,CB,LB,VQ,jQ,Gs,Qf,e_=y(()=>{"use strict";ae();Gu();Qb={TAB:"tab",HEADLESS:"headless",HEADED:"headed"},GO={LOCAL:"local",PLATFORM:"platform"},IB=2e3,CB=128,LB=500,VQ={target:pe([Qb.TAB,Qb.HEADLESS,Qb.HEADED]),mode:pe([GO.LOCAL,GO.PLATFORM]),url:p().url().refine(e=>/^https?:/i.test(e)),hud:pe([Bn.SHOWN,Bn.HIDDEN,Bn.REMOVED]),persona:p().min(1).max(IB),maxSteps:S().int().min(1).max(LB),record:L(),plan:p().min(1).max(CB),confirmDangerous:L()},jQ=b({seq:S().int().nonnegative(),tool:p().min(1).max(100),args:ie(p(),q()).default({})}),Gs={SOURCE:"source",TESTID:"testid"},Qf="file:line source mapping"});var eh,jO,KO,VO,ZQ,ZO=y(()=>{"use strict";eh="https://calendar.app.google/h9NRDbBBQetyTzWM6",jO="hey@reticle.sh",KO="mailto:hey@reticle.sh?subject=Reticle%20feedback",VO='npx @reticlehq/server feedback --contact you@company.com "what you are building"',ZQ={HUMAN:`Stuck, or want Reticle to work differently? Talk to the founder: ${eh} \xB7 or send a note with your email: ${VO}`,AGENT:`If the person you are working with is stuck or Reticle got in their way, offer them a call with the founder (${eh}) or a note with their email (${VO}). Offer it; never book a call or submit an email for them.`}});function WO(e){let t="";for(let n=0;n<8;n++){let r=Math.floor(e()*t_.length);t+=t_[Math.min(Math.max(r,0),t_.length-1)]}return t}var t_,YO=y(()=>{"use strict";t_="0123456789abcdefghijklmnopqrstuvwxyz"});var XO=y(()=>{"use strict"});function n_(e){return $B.test(e)}function qO(e){let t=new Set;for(let n of e!=null?e:[]){let r=n.trim().toLowerCase();r.length>0&&t.add(r)}return t}function JO(e,t){var s,a;let n=qO((s=e==null?void 0:e.keys)==null?void 0:s.filter(l=>typeof l=="string")),r=((a=e==null?void 0:e.keys)!=null?a:[]).filter(l=>l instanceof RegExp),o=qO(e==null?void 0:e.allow),i=[...o].filter(l=>n_(l)&&!n.has(l));return i.length>0&&t!==void 0&&t(`[reticle] redact.allow is exempting ${i.join(", ")} from redaction. The default rule treats ${i.length===1?"that key":"those keys"} as a credential, so ${i.length===1?"its value":"their values"} will now reach the agent transcript and the on-disk journal in cleartext.`),{isSensitiveKey:l=>{let u=l.toLowerCase();if(n.has(u))return!0;for(let d of r)if(d.lastIndex=0,d.test(l))return!0;return o.has(u)?!1:n_(l)}}}function QO(e){r_=e}function St(e){return r_===void 0?n_(e):r_.isSensitiveKey(e)}function DB(e){return new TextEncoder().encode(e).byteLength}function PB(e){if(!/^data:/i.test(e))return;let t=e.indexOf(","),n=t===-1?e.slice(5):e.slice(5,t),[r="",...o]=n.split(";"),i=/^[\w.+-]+\/[\w.+-]+$/.test(r)?r:"text/plain",s=o.some(l=>l.toLowerCase()==="base64")?";base64":"",a=t===-1?"":e.slice(t+1);return`data:${i}${s},<\u2026${String(DB(a))} bytes\u2026>`}function cr(e,t=St){var A;let n=PB(e);if(n!==void 0)return n;let r=e.indexOf("#"),o=r===-1?"":e.slice(r),i=r===-1?e:e.slice(0,r),s=i.indexOf("?"),a=s===-1?i:i.slice(0,s),l=s===-1?"":i.slice(s+1),u=!1,d=a,f=/^([a-z][a-z0-9+.-]*:\/\/)[^/]*@/i.exec(a);f!==null&&(d=`${(A=f[1])!=null?A:""}${ve}@${a.slice(f[0].length)}`,u=!0);let m=l;if(l!==""){let v=new URLSearchParams(l),N=!1;for(let O of[...v.keys()])t(O)&&(v.set(O,ve),N=!0);N&&(m=v.toString(),u=!0)}let h=d.split("/");for(let v=0;v+1<h.length;v++){let N=h[v],O=h[v+1];N!==void 0&&O!==void 0&&O.length>=zB&&kB.test(N)&&(h[v+1]=ve,u=!0)}let E=o;if(o.length>1&&(E=o.replace(/(^|[#&?/])([A-Za-z0-9_.-]+)=([^&\s]+)/g,(v,N,O)=>t(O)?`${N}${O}=${ve}`:v),E!==o&&(u=!0)),!u)return e;let _=s===-1?"":`?${m}`;return`${h.join("/")}${_}${E}`}function oo(e,t=St){let n=cr(e,t);return n===e?{url:n}:{url:n,[bO]:e}}function eI(e){var r;let t=new Set,n=[];for(let o of(r=e==null?void 0:e.keys)!=null?r:[]){if(typeof o!="string")continue;let i=o.trim();if(i.length===0||i.length>i_)continue;let s=i.toLowerCase();if(!t.has(s)&&(t.add(s),n.push(i),n.length>=o_))break}return n}function io(e){return e.replace(MB,ve)}var $B,r_,kB,zB,o_,i_,MB,s_=y(()=>{"use strict";Kt();Hu();$B=/password|passwd|passcode|pass[-_]?phrase|(?:otp|totp|mfa|recovery|backup)[-_]?codes?|(?:^|[-_])(?:otp|totp)(?=$|[-_])|secret|(?:(?:access|refresh|auth|bearer|api|id|session|csrf|client)[-_]?tokens?|(?:^|[-_])tokens?(?=$|[-_]))|session[-_]?id|(?:^|[-_])(?:sid|pwd|jwt)(?=$|[-_])|authorization|(?:^|[-_])(?:set[-_])?cookie(?=$|[-_])|api[-_]?key|access[-_]?key|private[-_]?key|client[-_]?secret|credit[-_]?card|card[-_]?(?:number|num|no|pan)(?=$|[-_])|(?:^|[-_])(?:card|pan)(?=$|[-_])|cvv|cvc|ssn|(?:^|[-_])(?:signature|sig)$|(?:^|[-_])credential$|x-(?:amz|goog)-(?:signature|credential|security-token)$/i;kB=/^(reset|verify|verification|confirm|activate|invite|magic|magiclink|token|key|oauth|unsubscribe|password)$/i,zB=12;o_=64,i_=128;MB=/eyJ[A-Za-z0-9_-]{4,}\.[A-Za-z0-9_-]{4,}\.[A-Za-z0-9_-]{4,}|(?:sk|rk)_(?:live|test)_[A-Za-z0-9]{10,}|sk-(?:ant|proj|svcacct|admin)-[A-Za-z0-9_-]{20,}|(?:AKIA|ASIA)[0-9A-Z]{16}|gh[pousr]_[A-Za-z0-9]{20,}|github_pat_[A-Za-z0-9_]{22,}|AIza[0-9A-Za-z_-]{35}|xox[baprs]-[A-Za-z0-9-]{10,}|ya29\.[A-Za-z0-9._-]{20,}/g});var so,th=y(()=>{"use strict";so={WEB:"web",WEBVIEW:"webview",NATIVE:"native",SERVICE:"service"}});function a_(){return[$.UI,$.NET,$.STATE,$.SIGNAL,$.LOG,$.ROUTE,$.TIME]}var ree,oee,nh=y(()=>{"use strict";pc();Vo();ree={[z.ELEMENT]:[$.UI],[z.TEXT]:[$.UI],[z.SIGNAL]:[$.SIGNAL],[z.NET]:[$.NET],[z.STATE]:[$.STATE],[z.ROUTE]:[$.ROUTE],[z.CONSOLE]:[$.LOG],[z.ANIMATION]:[$.UI,$.TIME],[z.SETTLED]:[$.TIME,$.NET],[z.COMPARE]:[$.UI,$.NET,$.STATE,$.SIGNAL],[z.ALL_OF]:a_(),[z.ANY_OF]:a_(),[z.NOT]:a_()};oee=Object.fromEntries(Object.entries(mb).map(([e,t])=>[e,t.independence]))});var tI,rh,oh,ih=y(()=>{"use strict";tI={DEVELOPMENT:"development",PRODUCTION:"production"},rh={OBSERVE:"observe",ACT:"act"},oh={INSTALLED:"installed",INJECTED:"injected"}});function c_(e){let t=e.toLowerCase().replace(/^\[|\]$/g,"");if(BB.includes(t))return!0;let n=t.split(".");return VB===n.length&&GB===n[0]&&n.every(r=>{if(!/^\d{1,3}$/.test(r))return!1;let o=Number(r);return o>=0&&o<=jB})}function KB(e){let t=e.toLowerCase();return t.endsWith(nI)&&t.length>nI.length&&!t.startsWith(".")}function sI(e,t){return c_(t)||KB(t)?!0:ZB.includes(e.toLowerCase())}function qB(e){for(let t=e.lastIndexOf(".");1<=t;t=e.lastIndexOf(".",t-1)){let n=t+1,r="";for(;n<e.length&&XB.test(e.charAt(n));)r+=e.charAt(n).toLowerCase(),n+=1;if(!WB.has(r))continue;let o=e.charAt(n);if(o===""||o==="."||o==="-")return n}return 0}function ju(e){return e.replace(YB,t=>{let n=qB(t);return n===0?t:` ${t.slice(n)}`})}function aI(e,t){return t!==void 0&&iI.has(t.trim().toLowerCase())?!1:HB.test(e.replace(oI," "))}function cI(e){return JB.test(e)}function lI(e){return uI(e)||FB.test(e.replace(oI," "))}function uI(e){let t;try{t=new URL(e).hostname.toLowerCase()}catch{return!1}return eG.some(n=>t===n||t.endsWith(`.${n}`))}function dI(e){var n;if(tG.test((n=e.autocomplete)!=null?n:""))return!0;let t=[e.name,e.id,e.label].map(r=>(r!=null?r:"").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/[_-]+/g," ")).join(" ");return nG.test(t)}function pI(e,t){var r;if(t!==void 0&&iI.has(t.trim().toLowerCase()))return;if(e.split(/\s+/).some(uI))return Tt.PAY;let n=e.replace(/[_-]+/g," ");return(r=QB.find(([o,i])=>o!==Tt.PAY&&i.test(n)))==null?void 0:r[0]}var rI,UB,HB,FB,oI,iI,BB,nI,GB,VB,jB,ZB,WB,YB,XB,JB,Tt,QB,eG,tG,nG,l_,u_=y(()=>{"use strict";rI="delete|remove|destroy|erase|drop|terminate|revoke|reset|close account|cancel subscription",UB="purchase|buy|pay|payment|place order|confirm order|send money|send funds|transfer|withdraw|refund",HB=new RegExp(`\\b(${rI}|${UB})\\b`,"i"),FB=new RegExp(`\\b(${rI})\\b`,"i"),oI=/[_-]+/g,iI=new Set(["option","radio"]),BB=["localhost","::1","0:0:0:0:0:0:0:1"],nI=".localhost",GB="127",VB=4,jB=255;ZB=["file:","app:","tauri:"];WB=new Set(["webm","mp4","mov","mkv","avi","mp3","wav","ogg","flac","png","jpg","jpeg","gif","webp","svg","avif","bmp","pdf","zip","tar","gz","txt","csv","json","xml","doc","docx","xls","xlsx","ppt","pptx"]),YB=/[\w.-]+/g,XB=/[a-zA-Z0-9]/;JB=/^\s*(#.*|javascript:.*)?$/i;Tt={INVITE:"invite",SEND:"send",SHARE:"share",DELETE:"delete",PAY:"pay",PUBLISH:"publish",REVOKE:"revoke",TRANSFER:"transfer",SIGN_OUT:"sign out",CHANGE_ROLE:"change role",CREATE_KEY:"create key",CHANGE_STATE:"change state"},QB=[[Tt.INVITE,/\binvit(?:e|es|ed|ing|ation|ations)\b|\/invit/i],[Tt.TRANSFER,/\b(?:transfer|send money|send funds|withdraw)\b/i],[Tt.SEND,/\b(?:send|sends|sending|resend|email (?:it|them|the))\b/i],[Tt.SHARE,/\b(?:share|shares|sharing)\b/i],[Tt.DELETE,/\b(?:delete|deletes|deleting|remove|removes|removing|destroy|erase|drop)\b/i],[Tt.PAY,/\b(?:pay|pays|paying|payment|purchase|buy|checkout|check out|subscribe|upgrade|place order|confirm order|refund|add (?:a )?card|start (?:the |your |a )?(?:\d+-day |free )?trial)\b|\/(?:billing|checkout)\b/i],[Tt.PUBLISH,/\b(?:publish|publishes|deploy|deploys|go live)\b/i],[Tt.REVOKE,/\b(?:revoke|revokes|deactivate|suspend)\b/i],[Tt.SIGN_OUT,/\b(?:sign ?out|log ?out|sign off)\b/i],[Tt.CHANGE_ROLE,/\b(?:change (?:the |their |his |her )?role|make (?:an? )?(?:admin|owner)|promote|demote|set role)\b/i],[Tt.CREATE_KEY,/\b(?:create|generate|new|mint)(?: an?)?(?: api)? key\b|\/keys\b/i],[Tt.CHANGE_STATE,/\b(?:reassign|reassigns|reopen|reopens|re-open|archive|archives|unarchive|approve|approves|reject|rejects|mark as (?:fixed|resolved|done|closed))\b/i]],eG=["stripe.com","checkout.dodopayments.com","paddle.com","lemonsqueezy.com","paypal.com","razorpay.com","braintreegateway.com"];tG=/\bcc-(?:number|csc|exp(?:-month|-year)?)\b/i,nG=/card ?(?:number|no\b)|\bcc ?num|\b(?:cvc|cvv|csc|cvc2|cvv2)\b|security code|card ?code|\bexpir(?:y|ation|es)\b|\bexp ?date\b|\bmm ?\/ ?yy\b|\biban\b|account ?number|routing ?number|sort ?code/i;l_=e=>`would need to ${e} \u2014 not done (outward action): the journey does not ask for it`});var sh,fI,rG,hI,mI,gI,oG,iG,Ku,p_,sG,aG,Eee,f_=y(()=>{"use strict";ae();Gu();Kt();Jb();s_();th();nh();ih();u_();sh=p().min(1).max(Z.MAX_SESSION_ID_LENGTH),fI=p().max(Z.MAX_REF_LENGTH),rG=p().min(1).max(8),hI=b({kind:R(ln),text:p().optional()}),mI=b({control:p().max(48).regex(/^[a-z][a-zA-Z-]*(\.[a-zA-Z-]+)?$/).optional(),toggle:R(Bu).optional(),view:R(Fn).optional(),panel:R(Dt).optional(),slide:p().max(56).optional(),prompt:R(ki).optional()}),gI=b({note:p().min(1).max(Z.MAX_MARK_NOTE_LENGTH),anchor:p().max(Z.MAX_REF_LENGTH),strategy:R(Fs),label:p().max(Z.MAX_MARK_LABEL_LENGTH).optional(),source:b({file:p().max(Z.MAX_URL_LENGTH),line:S().int().min(0)}).optional(),route:p().max(Z.MAX_URL_LENGTH).optional()}),oG=b({t:S(),type:R(w),sessionId:sh,ref:fI.optional(),seq:S().int().min(0).optional(),actionId:fI.optional(),attribution:R(vR).optional(),documentId:rG.optional(),editEpoch:S().int().min(0).optional(),data:ie(p(),q()).default({})}),iG=b({kind:U(sn.HELLO),protocolVersion:S().int().min(SR).max(Mf),sessionId:sh,url:p().max(Z.MAX_URL_LENGTH),title:p().max(Z.MAX_TITLE_LENGTH),projectId:sh.optional(),adapters:C(p().max(Z.MAX_ADAPTER_NAME_LENGTH)).max(Z.MAX_ADAPTERS),token:p().max(Z.MAX_TOKEN_LENGTH).optional(),env:R(tI).optional(),scope:R(rh).optional(),platform:R(so).optional(),channels:C(R($)).max(Z.MAX_ADAPTERS).optional(),commands:C(p().max(Z.MAX_TOKEN_LENGTH)).max(Z.MAX_ADAPTERS).optional(),contractParts:b({commands:C(p()).max(Z.MAX_CONTRACT_NAMES),events:C(p()).max(Z.MAX_CONTRACT_NAMES),actions:C(p()).max(Z.MAX_CONTRACT_NAMES)}).optional(),hasCapabilities:L().optional(),captureBodies:L().optional(),sourceMapping:L().optional(),instrumentation:R(oh).optional(),sdkVersion:p().max(Z.MAX_ADAPTER_NAME_LENGTH).optional(),contract:p().max(Z.MAX_ADAPTER_NAME_LENGTH).optional(),redactKeys:C(p().min(1).max(i_)).max(o_).optional()}),Ku={HARNESS:"harness"},p_=b({kind:U(sn.COMMAND),id:p().min(1).max(Z.MAX_COMMAND_ID_LENGTH),sessionId:sh.optional(),name:p().min(1).max(Z.MAX_COMMAND_NAME_LENGTH),args:ie(p(),q()).default({}),by:R(Ku).optional(),outward:b({allowed:C(R(Tt)).max(16)}).optional()}),sG=b({kind:U(sn.COMMAND_RESULT),id:p().min(1).max(Z.MAX_COMMAND_ID_LENGTH),ok:L(),result:q().optional(),error:p().max(Z.MAX_ERROR_LENGTH).optional()}),aG=b({kind:U(sn.EVENT),event:oG}),Eee=vt("kind",[iG,p_,sG,aG])});var yn,cG,lG,uG,dG,pG,See,Tee,xee,EI=y(()=>{"use strict";ae();ih();yn={PAYMENT:"payment or checkout",DELETE_WORKSPACE:"delete a workspace or project",REVOKE_KEY:"revoke or rotate a key",SEND_INVITE:"send an invite or email",CANCEL_SUBSCRIPTION:"cancel a subscription",CHANGE_ROLE:"change a member's role",OBSERVE_ONLY:"the session scope is observe, so it does not act",OFF_ORIGIN:"leave the activated origin",EXPIRED:"the session nonce expired"},cG=[yn.PAYMENT,yn.DELETE_WORKSPACE,yn.REVOKE_KEY,yn.SEND_INVITE,yn.CANCEL_SUBSCRIPTION,yn.CHANGE_ROLE],lG=64,uG=256,dG=b({rule:pe(cG),methods:C(p().min(1).max(16)).min(1).max(8),path:p().min(1).max(uG).refine(e=>{try{return new RegExp(e,"i"),!0}catch{return!1}},"not a valid regular expression")}),pG=C(dG).max(lG),See=[{rule:yn.CANCEL_SUBSCRIPTION,methods:["DELETE"],path:"/subscriptions?(/[^/]+)?/?$"},{rule:yn.CANCEL_SUBSCRIPTION,methods:["POST","PUT","PATCH"],path:"/subscriptions?(/[^/]+)?/cancel"},{rule:yn.PAYMENT,methods:["POST","PUT","PATCH"],path:"/(billing|checkout|payments?|subscriptions?|purchases?|orders?)(/|$)"},{rule:yn.DELETE_WORKSPACE,methods:["DELETE"],path:"/(workspaces?|orgs?|organi[sz]ations?|projects?)/[^/]+/?$"},{rule:yn.REVOKE_KEY,methods:["DELETE"],path:"/(api-?)?keys?/[^/]+/?$"},{rule:yn.REVOKE_KEY,methods:["POST","PUT","PATCH"],path:"/(api-?keys?|keys?|tokens?|secrets?)(/[^/]+)?/(rotate|revoke|regenerate|roll)"},{rule:yn.SEND_INVITE,methods:["POST","PUT"],path:"/(invites?|invitations?|emails?|mail)(/|$)"},{rule:yn.CHANGE_ROLE,methods:["PATCH","PUT","POST"],path:"/members?/[^/]+(/role)?/?$"}],Tee=b({workspaceId:p().min(1).max(128),nonce:p().min(1).max(256),bridgePort:S().int().min(1).max(65535),scope:R(rh),origin:p().url().max(2048).optional(),bridge:p().url().max(2048).optional()}),xee=b({ticket:p().min(1).max(4096),expiresAt:p().max(64).optional(),policy:pG.optional()})});var bI=y(()=>{"use strict"});function xG(e){return e.length<=SI&&TG.test(e)}var fG,_I,wee,zi,hG,qe,mG,gG,EG,bG,_G,SG,h_,SI,TG,TI,AG,xI,gc=y(()=>{"use strict";ae();fG={AGENT:"agent",HUMAN:"human"},_I={BUG:"bug",GAP:"gap",AMBIGUITY:"ambiguity",FEATURE_REQUEST:"feature_request",IMPROVEMENT:"improvement",EXPERIENCE:"experience"},wee=`<${Object.values(_I).join("|")}>`,zi={WEB:"web",ELECTRON:"electron",TAURI:"tauri"},hG={BLINK:"blink",GECKO:"gecko",WEBKIT:"webkit"},qe={CHROME:"chrome",EDGE:"edge",ARC:"arc",DIA:"dia",BRAVE:"brave",OPERA:"opera",FIREFOX:"firefox",SAFARI:"safari",OTHER:"other"},mG={CDP:"cdp",SDK:"sdk"},gG={USER:"user",PROJECT:"project"},EG=4e3,bG=8e3,_G=1,SG=5,h_=1e3,SI=254,TG=/^[^\s@,;<>]+@[^\s@,;<>]+\.[^\s@,;<>]+$/;TI=b({source:R(fG),kind:R(_I),text:p().min(1).max(EG),trace:p().max(bG).optional(),rating:S().int().min(_G).max(SG).optional(),need:p().max(h_).optional(),impact:p().max(h_).optional(),currentApproach:p().max(h_).optional(),model:p().min(1).max(64).optional(),clientVersion:p().min(1).max(32).optional(),stack:p().min(1).max(64).optional(),stackMajor:S().int().nonnegative().optional(),runtime:R(zi).optional(),engine:R(hG).optional(),driver:R(mG).optional(),client:p().min(1).max(64).optional(),mcpScope:R(gG).optional(),contact:p().max(SI).refine(xG).optional()}),AG={COMPANY:"company",SIDE_PROJECT:"side_project",OPEN_SOURCE:"open_source",LEARNING:"learning"},xI=b({context:R(AG),company:p().min(1).max(128).optional(),email:p().min(3).max(254).optional()})});var ao,co,ch,Wu,m_,Yu,Pt,Vs,yG,wG,$ee,ah,vG,NG,RG,Zu,kee,AI=y(()=>{"use strict";ae();Kt();Zb();jo();gc();f_();Hu();ao={SSE:"sse",WS:"ws",FETCH:"fetch"},co={OPEN:"open",IN:"in",OUT:"out",CLOSE:"close"},ch={UP:"up",DOWN:"down"},Wu={PUSH:"push",REPLACE:"replace",POP:"pop"},m_="how",Yu={INPUT:"input",CHANGE:"change",SETTLED:"settled"},Pt={FIELD:"field",KIND:"kind",LENGTH:"length",VALUE:"value",REDACTED:"redacted",CHECKED:"checked",PREVIOUS:"previous",PREVIOUS_CHECKED:"previousChecked"},Vs={LOCAL:"local",SESSION:"session",COOKIE:"cookies"},yG=b({name:p().describe("Cookie name."),value:p().describe("Cookie value."),domain:p().optional().describe("Cookie domain. Defaults to the navigation URL domain."),path:p().optional().describe('Cookie path. Defaults to "/".'),url:p().optional().describe("Cookie URL. Defaults to the navigation URL."),httpOnly:L().optional().describe("Whether the cookie is httpOnly."),secure:L().optional().describe("Whether the cookie is secure."),sameSite:pe(["Strict","Lax","None"]).optional().describe("SameSite policy."),expires:S().optional().describe("Unix timestamp in seconds for cookie expiration.")}),wG=wt([ie(p(),p()),C(yG)]),$ee=b({local:ie(p(),p()).optional().describe("Key-value pairs to seed into window.localStorage before first navigation."),session:ie(p(),p()).optional().describe("Key-value pairs to seed into window.sessionStorage before first navigation."),cookies:wG.optional().describe("Cookies to seed before first navigation: a name-value record scoped to the lease URL or an array of cookie objects.")}).strict(),ah=b({role:p().optional(),name:p().optional()}),vG=b({mimeType:p(),bytes:S(),filename:p().optional(),lines:S().optional(),preview:p().optional(),previewTruncated:L().optional()}).passthrough(),NG=b({transport:R(ao),direction:R(co),url:p(),urlRaw:p().optional()}).passthrough(),RG=b({id:p(),method:p(),url:p(),status:S(),ok:L(),durationMs:S(),initiator:p(),urlRaw:p().optional(),[Xf]:p().optional(),[Uu]:p().optional()}).passthrough(),Zu=b({message:p()}).passthrough(),kee={[w.DOM_ADDED]:ah,[w.DOM_REMOVED]:ah,[w.DOM_ATTR]:b({attr:p(),value:p().optional(),old:p().optional()}).passthrough(),[w.DOM_TEXT]:b({text:p(),old:p().optional(),testid:p().optional(),initial:L().optional()}),[w.NET_REQUEST]:RG,[w.NET_PENDING]:b({id:p(),method:p(),url:p(),initiator:p(),urlRaw:p().optional()}),[w.NET_STREAM]:NG,[w.DOWNLOAD]:vG,[w.PERF]:b({metric:R(cc),value:S(),at:S(),shifted:b({ref:p(),selector:p()}).optional()}),[w.ROUTE_CHANGE]:b({from:p(),to:p(),pathname:p(),search:p(),hash:p(),[m_]:R(Wu),pattern:p().optional()}),[w.CONSOLE_LOG]:Zu,[w.CONSOLE_WARN]:Zu,[w.CONSOLE_ERROR]:Zu,[w.CONSOLE_INFO]:Zu,[w.CONSOLE_DEBUG]:Zu,[w.ERROR_UNCAUGHT]:b({message:p(),source:p().optional(),line:S().optional(),kind:p().optional()}).passthrough(),[w.VISIBLE_SHOWN]:ah,[w.ANIM_START]:b({name:p()}),[w.ANIM_END]:b({name:p()}),[w.SCROLL_POSITION]:b({x:S(),y:S(),percent:S(),direction:R(ch)}),[w.REVEAL_SHOWN]:ah.passthrough(),[w.SIGNAL]:b({name:p(),data:q().optional()}),[w.STATE_CHANGE]:b({name:p(),value:q().optional()}).passthrough(),[w.STORAGE_CHANGE]:b({area:R(Vs),key:p(),old:p().optional(),new:p().optional()}),[w.PAGE_HEALTH]:b({hidden:L(),focused:L(),reason:p().optional(),brand:R(qe).optional(),runtime:p().optional(),engine:p().optional(),windowLabel:p().optional(),documentStatus:S().int().optional()}).passthrough(),[w.CONTEXT_OPENED]:b({href:p().optional()}).passthrough(),[w.DIALOG_OPENED]:b({kind:pe(["alert","confirm","prompt"]),message:p().optional(),answered:wt([L(),tR()]).optional()}).passthrough(),[w.RENDER_COMMIT]:b({commits:S()}),[w.FOCUS_CHANGE]:b({to:p().optional(),from:p().optional(),toBody:L()}),[w.FIELD_CHANGE]:b({[Pt.FIELD]:p(),[Pt.KIND]:R(Yu),[Pt.LENGTH]:S().int().nonnegative(),[Pt.VALUE]:p().optional(),[Pt.REDACTED]:U(!0).optional(),[Pt.CHECKED]:L().optional(),[Pt.PREVIOUS]:p().optional(),[Pt.PREVIOUS_CHECKED]:L().optional()}),[w.FLOW_RECORDED]:b({name:p(),flow:q().optional()}),[w.TRANSPORT_OVERFLOW]:b({dropped:S()}),[w.TRUNCATED]:b({channel:p(),dropped:S()}),[w.BLIND_SPOT]:b({kind:R(cn),count:S()}),[w.SDK_FAILED]:b({site:p().max(64),message:p().max(500),errorType:p().max(64).optional()}),[w.NET_DETAIL]:b({url:p(),method:p().optional(),status:S(),headers:ie(p(),p()),resourceType:p().optional()}).passthrough(),[w.NET_RESPONSE_BODY]:b({id:p(),method:p(),url:p(),urlRaw:p().optional(),responseBody:p(),responseBodyTruncated:L().optional(),responseBodyReason:R(sr).optional()}).passthrough(),[w.HUMAN_CONTROL]:hI,[w.HUMAN_MARK]:gI,[w.HUD_USED]:mI,[w.MEDIA_STATE]:b({event:R(Cu),tag:pe(["video","audio"]),currentTime:S(),duration:S().optional(),readyState:S().int().min(0).max(4),paused:L()}),[w.CANVAS_DIGEST]:b({digest:p(),width:S().int().nonnegative(),height:S().int().nonnegative(),mean:kf([S(),S(),S()]),trigger:R(ks).optional()})}});var Pee,yI=y(()=>{"use strict";Kt();Pee=new Set([w.NET_REQUEST,w.NET_PENDING,w.NET_STREAM,w.NET_DETAIL,w.NET_RESPONSE_BODY,w.CONSOLE_ERROR,w.CONSOLE_WARN,w.ERROR_UNCAUGHT,w.ROUTE_CHANGE,w.SIGNAL,w.STORAGE_CHANGE,w.FLOW_RECORDED,w.TRANSPORT_OVERFLOW,w.TRUNCATED,w.BLIND_SPOT])});var wI=y(()=>{"use strict"});var vI,NI=y(()=>{"use strict";vI=e=>e});var ye,Gee,Vee,jee,RI=y(()=>{"use strict";nh();ye={UI_ADVANCED_REQUEST_FAILED:"ui-advanced-request-failed",UI_ADVANCED_UNSIGNALLED:"ui-advanced-unsignalled",SIGNAL_CONTRADICTED:"signal-contradicted",RESPONSE_IGNORED:"response-ignored",SIGNAL_WITHOUT_CONSEQUENCE:"signal-without-consequence",STATE_VS_RENDER:"state-vs-render",CONSEQUENCE_ELSEWHERE:"consequence-elsewhere",DUPLICATE_REQUEST:"duplicate-request",DUPLICATE_REQUEST_UNRELATED:"duplicate-request-unrelated",SCREEN_REQUEST_MISMATCH:"screen-request-mismatch",STALE_RESPONSE_APPLIED:"stale-response-applied",PARTIAL_FAILURE_IN_OK_RESPONSE:"partial-failure-in-ok-response",UNIT_MISMATCH:"unit-mismatch",PAGINATION_NOT_FETCHED:"pagination-not-fetched",WRITE_FIELD_IGNORED:"write-field-ignored",REQUEST_NEVER_SETTLED:"request-never-settled",FAILURE_MISATTRIBUTED:"failure-misattributed",ACTION_HAD_NO_EFFECT:"action-had-no-effect",ROUTE_RENDERED_NOTHING:"route-rendered-nothing",ROUTE_RENDERED_NOTHING_CRASHED:"route-rendered-nothing-crashed",EVIDENCE_SUPERSEDED:"evidence-superseded",EVIDENCE_PREDATES_EDIT:"evidence-predates-edit"},Gee=new Set([ye.REQUEST_NEVER_SETTLED,ye.UI_ADVANCED_UNSIGNALLED,ye.RESPONSE_IGNORED,ye.SIGNAL_WITHOUT_CONSEQUENCE,ye.STATE_VS_RENDER,ye.CONSEQUENCE_ELSEWHERE,ye.ROUTE_RENDERED_NOTHING,ye.ACTION_HAD_NO_EFFECT,ye.DUPLICATE_REQUEST,ye.EVIDENCE_SUPERSEDED,ye.EVIDENCE_PREDATES_EDIT]),Vee=new Set([ye.DUPLICATE_REQUEST_UNRELATED,ye.SCREEN_REQUEST_MISMATCH]),jee={[ye.UI_ADVANCED_REQUEST_FAILED]:[$.UI,$.NET],[ye.UI_ADVANCED_UNSIGNALLED]:[$.UI,$.NET],[ye.SIGNAL_CONTRADICTED]:[$.SIGNAL,$.NET],[ye.RESPONSE_IGNORED]:[$.NET,$.UI],[ye.SIGNAL_WITHOUT_CONSEQUENCE]:[$.SIGNAL,$.NET],[ye.STATE_VS_RENDER]:[$.STATE,$.UI],[ye.CONSEQUENCE_ELSEWHERE]:[$.NET,$.UI],[ye.DUPLICATE_REQUEST]:[$.NET,$.NET],[ye.DUPLICATE_REQUEST_UNRELATED]:[$.NET,$.NET],[ye.SCREEN_REQUEST_MISMATCH]:[$.UI,$.NET],[ye.STALE_RESPONSE_APPLIED]:[$.NET,$.UI],[ye.PARTIAL_FAILURE_IN_OK_RESPONSE]:[$.NET,$.NET],[ye.UNIT_MISMATCH]:[$.UI,$.NET],[ye.PAGINATION_NOT_FETCHED]:[$.UI,$.NET],[ye.WRITE_FIELD_IGNORED]:[$.NET,$.NET],[ye.REQUEST_NEVER_SETTLED]:[$.TIME,$.NET],[ye.FAILURE_MISATTRIBUTED]:[$.UI,$.NET],[ye.ACTION_HAD_NO_EFFECT]:[$.NET,$.UI],[ye.ROUTE_RENDERED_NOTHING]:[$.ROUTE,$.NET],[ye.ROUTE_RENDERED_NOTHING_CRASHED]:[$.ROUTE,$.LOG],[ye.EVIDENCE_SUPERSEDED]:[$.TIME,$.UI],[ye.EVIDENCE_PREDATES_EDIT]:[$.TIME,$.UI]}});var Ko,lh,Wee,Yee,OI=y(()=>{"use strict";Kt();Ko="__reticleIpc",lh="reticle_capture",Wee=ac.FULL_PAGE_UNSUPPORTED,Yee=ac.NOT_COMPOSITED});var II=y(()=>{"use strict"});var CI=y(()=>{"use strict"});var LI=y(()=>{"use strict"});function $I(e){return e===Ec.CALM||e===Ec.WAITING||e===Ec.ASK||e===Ec.WARN}var Ec,kI,ete,tte,zI=y(()=>{"use strict";Ec={CALM:"calm",WAITING:"waiting",ASK:"ask",WARN:"warn"};kI="note that a lease is a SEPARATE context: the human watching this tab sees nothing of what you do there, so prefer this tab while someone is following along",ete='tab hidden and may be un-focusable from here; timers and rAF are clamped in a background tab, so an action can land on a page that never advances. Refocus it, or acquire a guaranteed scriptable context yourself with `reticle_run { tool: "reticle_lease", args: { action: "acquire", url } }` (a human can equivalently run `reticle drive <url>`) \u2014 '+kI,tte="tab is not hidden but has not reported health recently \u2014 usually a quiet page rather than a stuck one, and very often still driveable. This is also the tab a human can see, so try it first. Timing-sensitive work (animations, debounces, gestures) is what degrades: pass `refuseWhenThrottled: true` to refuse rather than act over events that may not land. Lease a separate context only if a drive here actually fails; "+kI});var DI,OG,ste,ate,cte,PI=y(()=>{"use strict";ae();Kt();jo();Vo();DI=1,OG=b({harness:p().min(1).max(Z.MAX_REF_LENGTH),driver:p().min(1).max(Z.MAX_COMMAND_NAME_LENGTH),persona:p().max(1e3).optional()}),ste=b({v:U(DI),actionId:p().min(1).max(Z.MAX_REF_LENGTH),tool:p().min(1).max(Z.MAX_COMMAND_NAME_LENGTH),args:ie(p(),q()).default({}),effect:q().optional(),settled:L().optional(),settledInMs:S().int().min(0).optional(),seqRange:b({from:S().int().min(0),to:S().int().min(0)}).optional(),tRange:b({from:S().int().min(0),to:S().int().min(0)}),at:S().int().min(0),drivenBy:OG.optional(),agent:p().min(1).max(Z.MAX_REF_LENGTH).optional()}),ate=b({v:U(DI),channel:U(Bf.JOURNAL),capBytes:S().int().min(1).optional(),bytesOnDisk:S().int().min(0).optional(),droppedInBatch:S().int().min(0).optional(),at:S().optional()}),cte=b({claim:p().min(1).max(Z.MAX_STRING_LENGTH),verified:R(Hn),source:p().max(Z.MAX_URL_LENGTH).optional(),observed:p().max(Z.MAX_STRING_LENGTH).optional(),expected:p().max(Z.MAX_STRING_LENGTH).optional(),kind:R(z).optional(),declaredBeforeActing:L().optional(),net:C(b({method:p().max(Z.MAX_COMMAND_NAME_LENGTH),url:p().max(Z.MAX_URL_LENGTH),status:S().optional(),body:p().max(Z.MAX_STRING_LENGTH).optional()})).max(5).optional(),grade:p().max(Z.MAX_STRING_LENGTH).optional(),couldNotSee:C(p().max(Z.MAX_STRING_LENGTH)).optional(),reason:p().max(Z.MAX_STRING_LENGTH).optional(),intent:p().max(Z.MAX_STRING_LENGTH).optional(),intentDerived:L().optional(),failedPart:S().int().min(0).optional()})});var MI=y(()=>{"use strict"});var dte,UI=y(()=>{"use strict";ae();dte=b({port:S(),pid:S(),cwd:p(),projectId:p().optional(),startedAt:S()})});var fte,HI=y(()=>{"use strict";ae();fte=b({port:S(),pid:S(),root:p(),url:p(),sdkVersion:p().min(1).optional(),startedAt:S(),projectId:p().optional()})});var IG,mte,FI=y(()=>{"use strict";ae();IG=b({directory:p().min(1),lastSeenAt:S()}),mte=b({version:U(1),projects:ie(p(),IG)})});var CG,g_,LG,$G,kG,Ete,BI=y(()=>{"use strict";ae();CG=1,g_={DECLARED:"declared",BOUND:"bound",PROVED:"proved"},LG=b({route:p().optional(),flow:p().optional(),files:C(p()).optional()}),$G=b({verdictId:p(),grade:p(),at:S(),runId:p().optional()}),kG=b({id:p().min(1),statement:p().min(1),state:pe([g_.DECLARED,g_.BOUND,g_.PROVED]),declaredAt:S(),binding:q().optional(),surface:LG.optional(),provenBy:$G.optional(),amended:C(b({statement:p(),at:S()})).optional()}),Ete=b({version:U(CG),intents:ie(p(),kG)})});var GI=y(()=>{"use strict"});function Xu(e){return zG[e]}var mt,zG,DG,Ste,E_=y(()=>{"use strict";ae();mt={NO_SOURCE_MAPPING:"no-source-mapping",NO_STORE_REGISTERED:"no-store-registered",NO_SIGNAL_ON_MUTATION:"no-signal-on-mutation",UNDECLARED_CONTROL:"undeclared-control",MISSING_TESTID:"missing-testid",UNDECLARED_CHANGE:"undeclared-change",INTENT_UNDISCHARGED:"intent-undischarged",NO_FLOW_INTENT:"no-flow-intent",SOURCE_MAPPING_OFF:"source-mapping-off"},zG={[mt.NO_SOURCE_MAPPING]:"add the Reticle build plugin (@reticlehq/vite-plugin, @reticlehq/next, or the babel plugin) so elements carry data-reticle-source",[mt.NO_STORE_REGISTERED]:"import { registerStore } from '@reticlehq/browser' and call registerStore(name, store) with a subscribable store so its changes are observed; a bare getter is readable but does not report changes. For component-local React state, import { useReticleStore } from '@reticlehq/react/store' and call useReticleStore(name, value), assert the DOM, or read it with reticle_look { action: 'state', ref: '...' }",[mt.NO_SIGNAL_ON_MUTATION]:"fire reticle.signal(name, data) where this state is committed \u2014 commitAndSignal binds the two so they cannot drift",[mt.UNDECLARED_CONTROL]:"add this control to reticle.describe() so the capability contract matches what the app actually exposes",[mt.MISSING_TESTID]:'add data-testid="..." on this control so the flow can name it after a refactor',[mt.UNDECLARED_CHANGE]:'declare it with reticle_intent { action: "declare", intents: [{ id, statement }] } \u2014 the statement is prose, in your own words: which user does what, and what should become true',[mt.INTENT_UNDISCHARGED]:'draw a verdict whose `until` asserts the intent itself, then it discharges \u2014 or call reticle_run({ tool: "reticle_context" }) to see exactly what is still owed',[mt.SOURCE_MAPPING_OFF]:"nothing to install \u2014 this build has sourceMapping turned off, so no element carries data-reticle-source. Re-enable it in the Reticle plugin options unless this app renders through a non-DOM reconciler (react-three-fiber, react-pdf, ink), where the stamp is what would break it",[mt.NO_FLOW_INTENT]:'save it again with intent: "<which user does what, and what should become true>" \u2014 prose, in your own words \u2014 or set intentId to an intent already in the ledger'};DG={PIXELS_UNOBSERVED:"pixels-unobserved",CLAIM_ARITHMETIC_UNCHECKED:"claim-arithmetic-unchecked"},Ste=b({kind:R(DG),detail:p().min(1)})});var Zo,VI,wte,vte,jI=y(()=>{"use strict";ae();pc();E_();e_();Zo={PAGE_CONNECTED:"page connected",DOM_ACTIONS:"DOM actions",NETWORK:"network",CONSOLE:"console",APP_STATE:"app state (store registered)",SIGNALS:"signals on mutation",SOURCE_MAPPING:Qf,TEST_IDS:"stable test ids"},VI="run `npx @reticlehq/server init` in the app so its pages connect to Reticle in development",wte=[{capability:Zo.PAGE_CONNECTED,gaps:[],cost:"no page has connected, so nothing can be verified",fix:VI},{capability:Zo.DOM_ACTIONS,channel:$.UI,always:!0,gaps:[],cost:"controls cannot be driven or read",fix:VI},{capability:Zo.NETWORK,channel:$.NET,always:!0,gaps:[],cost:"requests cannot be asserted, so a save that never reached the server can pass",fix:"update @reticlehq/browser so the page reports its network channel"},{capability:Zo.CONSOLE,channel:$.LOG,always:!0,gaps:[],cost:"errors thrown in the page are invisible to a verdict",fix:"update @reticlehq/browser so the page reports its console channel"},{capability:Zo.APP_STATE,channel:$.STATE,gaps:[mt.NO_STORE_REGISTERED],cost:"state predicates fall back to reading the DOM",fix:Xu(mt.NO_STORE_REGISTERED)},{capability:Zo.SIGNALS,channel:$.SIGNAL,gaps:[mt.NO_SIGNAL_ON_MUTATION],cost:"the app never says it succeeded, so every verdict infers success from the DOM",fix:Xu(mt.NO_SIGNAL_ON_MUTATION)},{capability:Zo.SOURCE_MAPPING,channel:Gs.SOURCE,gaps:[mt.NO_SOURCE_MAPPING,mt.SOURCE_MAPPING_OFF],perControl:[mt.NO_SOURCE_MAPPING],cost:"a broken control is named, never the line that renders it",fix:Xu(mt.NO_SOURCE_MAPPING)},{capability:Zo.TEST_IDS,channel:Gs.TESTID,gaps:[mt.MISSING_TESTID],cost:"a saved flow loses its controls after a refactor",fix:Xu(mt.MISSING_TESTID)}],vte=C(R(Zo)).max(8)});var KI=y(()=>{"use strict"});function PG(e){return Array.isArray(e)||typeof e=="string"}function MG(e){if(Array.isArray(e))return{keys:[...e.slice(0,49).map((n,r)=>String(r)),b_],total:e.length+1};if(typeof e=="string")return{keys:[b_],total:1};if(e instanceof Map){let t=[],n=0;for(let r of e.keys())n+=1,typeof r=="string"&&t.length<49&&t.push(r);return e.has(qu)?{keys:t,total:n}:{keys:[...t,qu],total:n+1}}if(e instanceof Set){let t=[];for(let n of e)typeof n=="string"&&t.length<49&&t.push(n);return{keys:[...t,qu],total:e.size+1}}if(typeof e=="object"&&e!==null){let t=Object.keys(e);return{keys:t.slice(0,50),total:t.length}}return{keys:[],total:0}}function uh(e){let{keys:t,total:n}=MG(e);return{found:!1,value:null,availableKeys:t,...n>t.length?{totalKeys:n}:{}}}function ZI(e,t){let n=t.split(".").filter(o=>o.length>0),r=e;for(let o of n){if(b_===o&&PG(r)){r=r.length;continue}if(Array.isArray(r)){let i=Number(o);if(!Number.isInteger(i)||i<0||String(i)!==o||i>=r.length)return uh(r);r=r[i];continue}if(r instanceof Map){if(r.has(o)){r=r.get(o);continue}if(qu===o){r=r.size;continue}return uh(r)}if(r instanceof Set){if(qu===o){r=r.size;continue}if(r.has(o)){r=!0;continue}return uh(r)}if(typeof r=="object"&&r!==null&&Object.hasOwn(r,o)){r=r[o];continue}return uh(r)}return{found:!0,value:r}}function bc(e,t){if(t<0)return e;if(e instanceof Date)return Number.isNaN(e.getTime())?null:e.toISOString();if(e instanceof Set)return t===0?`[Set(${String(e.size)})]`:[...e].map(n=>bc(n,t-1));if(e instanceof Map){if(t===0)return`{Map(${String(e.size)})}`;let n=Object.create(null);for(let[r,o]of e)n[String(r)]=bc(o,t-1);return n}if(Array.isArray(e))return t===0?`[Array(${String(e.length)})]`:e.map(n=>bc(n,t-1));if(typeof e=="object"&&e!==null){let n=Object.keys(e);if(t===0)return`{\u2026${String(n.length)} keys}`;let r=Object.create(null);for(let o of n)r[o]=bc(e[o],t-1);return r}return e}var b_,qu,WI=y(()=>{"use strict";b_="length";qu="size"});var Cte,Lte,YI=y(()=>{"use strict";Kt();Cte={[Se.ENABLED]:"en",[Se.DISABLED]:"dis",[Se.CHECKED]:"chk",[Se.EXPANDED]:"exp",[Se.PRESSED]:"prs",[Se.FOCUSED]:"focus"},Lte=new Set([Se.PRESENT,Se.VISIBLE,Se.HIDDEN])});var js,kte,zte,XI=y(()=>{"use strict";ae();js={SHARE_PROOF:"share_proof",RUN_HISTORY:"run_history",TEAM_REVIEW:"team_review",CORPUS_HEAL:"corpus_heal",CI_GATE:"ci_gate",HOSTED_RUNNER:"hosted_runner"},kte=b({capability:R(js),reason:p(),unlockedBy:p(),learnMoreUrl:p().url()}),zte={[js.SHARE_PROOF]:{reason:"Sharing a verification result with a teammate needs a hosted, linkable proof page.",unlockedBy:"Link a free Reticle Cloud account (reticle connect), then share the run."},[js.RUN_HISTORY]:{reason:"Run history beyond this session lives in the hosted dashboard; local keeps only a buffer.",unlockedBy:"Link a free Reticle Cloud account to keep run history and trends."},[js.TEAM_REVIEW]:{reason:"A shared review queue of pinned mistakes is a team feature \u2014 it needs a hosted store.",unlockedBy:"Add your team to Reticle Cloud to share a review queue."},[js.CORPUS_HEAL]:{reason:"Corpus-ranked heal uses refactor outcomes learned across the fleet, served from the cloud.",unlockedBy:"Enable the hosted heal service on Reticle Cloud."},[js.CI_GATE]:{reason:"Verify-before-merge is a governance gate that runs in your CI against a hosted policy.",unlockedBy:"Configure the Reticle Cloud CI gate for your repository."},[js.HOSTED_RUNNER]:{reason:"Verifying without a local browser (CI, a background agent, or a deployed URL) needs a browser we run for you.",unlockedBy:"Link a Reticle Cloud account to run verifications on hosted browsers."}}});var Ju,qI,JI,QI,UG,e0,t0=y(()=>{"use strict";ae();Ju={INSTALL:"install",ONBOARD:"onboard",FIRST_RUN:"first_run"},qI={STARTED:"started",COMPLETED:"completed",FAILED:"failed",ABANDONED:"abandoned",SKIPPED:"skipped"},JI={[Ju.INSTALL]:["script_started","runtime_ready","cli_installed","agents_detected","mcp_registered"],[Ju.ONBOARD]:["tour_started","concept_shown","first_look","first_act","first_verdict"],[Ju.FIRST_RUN]:["project_detected","next_step_offered","instrumented","app_connected","driven","flow_recorded","verdict_produced"]},QI={LEASE:"lease",INIT_CONSENT:"init_consent"},UG=Object.values(JI).flatMap(e=>[...e]),e0=b({phase:R(Ju),step:pe(UG),status:R(qI),elapsedMs:S().int().nonnegative().optional(),reason:p().max(64).optional(),stack:p().max(64).optional(),unattended:L().optional(),firstEver:L().optional(),offered:R(QI).optional(),nextFollowed:L().optional()})});var n0,__=y(()=>{"use strict";n0={AUTH_REFUSED:"auth_refused",LEASE_EXPIRED:"lease_expired",TAB_GONE:"tab_gone",NAVIGATED_AWAY:"navigated_away",ROUTE_SERVER_ERROR:"route_server_error",APP_NOT_REOPENED:"app_not_reopened",CONFIG_ELSEWHERE:"config_elsewhere",NO_LISTENER_NO_CONFIG:"no_listener_no_config",NO_LISTENER:"no_listener",NO_CONFIG:"no_config",SDK_NOT_REACHING_DAEMON:"sdk_not_reaching_daemon"}});var HG,r0,S_=y(()=>{"use strict";ae();__();HG={NO_SESSION:"no_session",NO_MATCH:"no_match",UNSUPPORTED:"unsupported",BAD_ARGS:"bad_args",NOT_READY:"not_ready",OTHER:"other"},r0=b({tool:p().min(1).max(64),reason:R(HG),noSessionReason:R(n0).optional(),retried:L()})});var FG,i0,Fte,o0,BG,GG,T_,VG,jG,s0,KG,ZG,a0,x_=y(()=>{"use strict";ae();FG={CONNECT:"connect",CLOSE_GAPS:"close_gaps",SWITCH_ON:"switch_on",EXPLORE:"explore"},i0={B0:"0-19",B20:"20-39",B40:"40-59",B60:"60-79",B80:"80-100"},Fte=Object.values(i0),o0=b({fingerprint:p().min(1).max(64),count:S().int().nonnegative(),message:p().max(300),tool:p().max(64).optional()}),BG={NONE:"none",LOCAL_ONLY:"local_only",REMOTE:"remote"},GG={GITHUB:"github",GITLAB:"gitlab",BITBUCKET:"bitbucket",AZURE:"azure",SOURCEHUT:"sourcehut",CODEBERG:"codeberg",SELF_HOSTED:"self_hosted"},T_=b({rssMb:S().int().nonnegative(),heapUsedMb:S().int().nonnegative(),freeMemMb:S().int().nonnegative(),totalMemMb:S().int().nonnegative(),load1x100:S().int().nonnegative(),cpuCount:S().int().nonnegative()}),VG=b({totalMs:S().int().nonnegative(),maxMs:S().int().nonnegative()}),jG=b({attempts:S().int().nonnegative(),successes:S().int().nonnegative(),failures:ie(p(),S().int().nonnegative()).optional()}),s0=b({durationMs:S().int().nonnegative(),toolCalls:S().int().nonnegative(),toolCounts:ie(p(),S().int().nonnegative()),toolErrors:S().int().nonnegative(),errors:C(o0).max(40).optional(),sdkFailures:S().int().nonnegative().optional(),sdkErrors:C(o0).max(40).optional(),verifications:S().int().nonnegative(),bugsFound:S().int().nonnegative().optional(),bugKinds:ie(p(),S().int().nonnegative()).optional(),toolParams:ie(p(),ie(p(),S().int().nonnegative())).optional(),connections:ie(p(),jG).optional(),toolTiming:ie(p(),VG).optional(),busyMs:S().int().nonnegative().optional(),browserMs:S().int().nonnegative().optional(),browserCommands:S().int().nonnegative().optional(),peakConcurrentTools:S().int().nonnegative().optional(),unknownToolCalls:S().int().nonnegative().optional(),unknownTools:ie(p().max(64),S().int().nonnegative()).optional(),noSessionErrors:S().int().nonnegative().optional(),postSocketFailures:S().int().nonnegative().optional(),postRetriesSaved:S().int().nonnegative().optional(),consecutiveRepeats:ie(p(),S().int().positive()).optional(),abandonedActions:S().int().nonnegative().optional(),machine:T_.optional(),clients:C(p().max(64)).max(8).optional(),clientVersions:ie(p().max(64),p().max(32)).optional(),surface:p().max(32).optional(),appConnects:S().int().nonnegative().optional(),msToFirstApp:S().int().nonnegative().optional(),sdkVersion:p().min(1).max(32).optional(),toolCallsBeforeApp:S().int().nonnegative().optional(),endReason:pe(["never_used","explored","abandoned","verified","client_left"]).optional(),feedbackPrompted:S().int().nonnegative().optional(),errorClasses:ie(p().max(16),S().int().nonnegative()).optional(),errorsRecovered:S().int().nonnegative().optional(),errorsRepeated:S().int().nonnegative().optional(),endedWithVerdict:L().optional(),lifetimeToolCalls:S().int().nonnegative().optional(),lifetimeVerifications:S().int().nonnegative().optional(),lifetimeBugsFound:S().int().nonnegative().optional(),updateNudged:L().optional(),updateOffered:p().max(32).optional(),hudControls:ie(p(),S()).optional(),hudViewMs:ie(p(),S()).optional(),hudPanelMs:ie(p(),S()).optional(),hudSlides:ie(p(),S()).optional(),hudJourney:C(p().max(64)).max(60).optional(),hudJourneyCut:U(!0).optional(),nudgesShown:sb(R(FG),S().int().positive()).optional(),harnessRefusedCoverage:sb(R(i0),S().int().positive()).optional(),final:L(),exit:pe(["idle","signal","unknown"]).optional()}),KG={TINY:"tiny",SMALL:"small",MEDIUM:"medium",LARGE:"large",HUGE:"huge"},ZG={NO_APP_FOUND:"no_app_found",MANIFEST_UNRECOGNISED:"manifest_unrecognised",WORKSPACE_APPS_UNRECOGNISED:"workspace_apps_unrecognised",WORKSPACE_ROOT_NO_APPS:"workspace_root_no_apps",DISCOVERY_FAILED:"discovery_failed"},a0=b({stack:p().min(1).max(64).optional(),stackSource:pe(["cwd","workspace"]).optional(),stackUnknownReason:R(ZG).optional(),stackMajor:S().int().nonnegative().optional(),size:R(KG).optional(),monorepo:L().optional(),git:R(BG),forge:R(GG).optional(),ageWeeks:S().int().nonnegative().optional(),flowCount:S().int().nonnegative(),baselineCount:S().int().nonnegative(),visualBaselineCount:S().int().nonnegative(),runCount:S().int().nonnegative(),hasContract:L(),initialized:L().optional(),appConnectedBefore:L().optional(),capsuleCount:S().int().nonnegative(),featuresUsed:C(p().max(32)).max(24),featureDepth:S().min(0).max(1)})});var c0,A_=y(()=>{"use strict";c0={ACTIVE:"active",MISSING:"missing",INVALID:"invalid",EXPIRED:"expired",EVAL:"eval"}});var WG,YG,XG,y_,qG,JG,QG,eV,tV,nV,rV,oV,l0,u0,iV,sV,aV,cV,lV,uV,d0,w_=y(()=>{"use strict";ae();Gu();WG={SIGNED_OUT:"signed_out",SIGNED_IN:"signed_in",LINKED:"linked"},YG={CLAUDE_CODE:"claude_code",CLAUDE_DESKTOP:"claude_desktop",CODEX:"codex",CURSOR:"cursor",GEMINI_CLI:"gemini_cli",ANTIGRAVITY:"antigravity",WINDSURF:"windsurf",CLINE:"cline",OPENCODE:"opencode",ZED:"zed",VSCODE:"vscode",OTHER:"other"},XG={NPX:"npx",GLOBAL:"global",PROJECT:"project",OTHER:"other"},y_={ZERO:"0",ONE:"1",TWO_THREE:"2-3",FOUR_NINE:"4-9",TEN_PLUS:"10+"},qG=b({view:R(Dt).optional(),surface:R(ki).optional(),tabs:R(y_).optional()}),JG={CONNECT:"connect",HUD:"hud",LINK:"link"},QG=b({via:R(JG)}),eV={STARTED:"started",COMPLETED:"completed"},tV={PROVED:"proved",NOT_PROVED:"not_proved",FAILED:"failed",BLOCKED:"blocked",STOPPED:"stopped"},nV={NOT_LINKED:"not_linked",PLATFORM_UNREACHABLE:"platform_unreachable",HARNESS_OFF:"harness_off",NO_CREDITS:"no_credits",NOT_ENTITLED:"not_entitled",COVERAGE_GATE:"coverage_gate",VERSION_SKEW:"version_skew",BROKEN:"broken",OTHER:"other"},rV={AGENT:"agent",HUD:"hud",DASHBOARD:"dashboard",CLI_TRY:"cli_try",PLAN:"plan"},oV=b({phase:R(eV),source:R(rV),hosted:L(),outcome:R(tV).optional(),journeys:R(y_).optional(),replayed:R(y_).optional(),reason:R(nV).optional()}),l0={accountState:R(WG).optional(),linked:L().optional(),workspaceId:p().min(1).max(128).optional(),client:R(YG).optional(),launch:R(XG).optional(),hud:qG.optional(),link:QG.optional(),harness:oV.optional()},u0={ECONNRESET:"ECONNRESET",ECONNREFUSED:"ECONNREFUSED",EPIPE:"EPIPE",ETIMEDOUT:"ETIMEDOUT",OTHER:"other"},iV={STDIN_END:"stdin_end",IDLE:"idle",CLIENT_GONE_STORM:"client_gone_storm",WAKE_FAILED:"wake_failed"},sV=b({reason:R(iV),uptimeMs:S().int().nonnegative(),drops:S().int().nonnegative(),toolCalls:S().int().nonnegative(),proxyId:p().min(1).max(64).optional()}),aV=b({ageMs:S().int().nonnegative()}),cV={DETACHED:"detached",WMI:"wmi",WMI_FALLBACK:"wmi_fallback"},lV={FOREIGN:"foreign",OTHER_PROJECT:"other_project"},uV=b({presence:R(lV)}),d0={proxyExit:sV.optional(),daemonDeath:aV.optional(),wakeRefusal:uV.optional(),spawnMethod:R(cV).optional()}});var dV,pV,p0,v_=y(()=>{"use strict";ae();dV={CONTRADICTION:"contradiction",CRAWL:"crawl",REPLAY:"replay",ASSERTION:"assertion"},pV={APP:"app",REQUEST:"request",RETICLE:"reticle",UNCLASSIFIED:"unclassified"},p0=b({source:R(dV),kind:p().min(1).max(64),falseGreen:L(),tool:p().min(1).max(64).optional(),repeat:L(),attribution:R(pV),fingerprint:p().max(16).optional(),occurrence:S().int().positive().optional()})});var fV,un,nne,hV,mV,gV,EV,bV,f0,_V,SV,TV,xV,AV,yV,wV,vV,NV,RV,OV,rne,h0=y(()=>{"use strict";ae();t0();S_();x_();gc();jo();gc();A_();w_();v_();v_();fV=3,un={RETICLE_INSTALLED:"reticle_installed",CLI_COMMAND_RUN:"cli_command_run",DAEMON_STARTED:"daemon_started",DAEMON_STOPPED:"daemon_stopped",SESSION_PROGRESS:"session_progress",VERIFICATION_COMPLETED:"verification_completed",PROJECT_PROFILED:"project_profiled",VERSION_CHANGED:"version_changed",RUNTIME_CRASHED:"runtime_crashed",FEEDBACK_SUBMITTED:"feedback_submitted",IDENTIFIED:"identified",MCP_CLIENT_CONNECTED:"mcp_client_connected",APP_INSTRUMENTED:"app_instrumented",MCP_CONNECTION_LOST:"mcp_connection_lost",MCP_PROXY_EXITED:"mcp_proxy_exited",DAEMON_DIED_UNCLEAN:"daemon_died_unclean",WAKE_REFUSED:"wake_refused",INIT_COMPLETED:"init_completed",ONBOARDING_STEP:"onboarding_step",BUG_FOUND:"bug_found",TOOL_REFUSED:"tool_refused",HUD_VIEWED:"hud_viewed",HUD_SIGNIN_PROMPTED:"hud_signin_prompted",PLATFORM_LINKED:"platform_linked",HARNESS_RUN:"harness_run"},nne=new Set([un.DAEMON_STARTED,un.DAEMON_STOPPED,un.SESSION_PROGRESS,un.MCP_CLIENT_CONNECTED,un.APP_INSTRUMENTED,un.PROJECT_PROFILED,un.VERIFICATION_COMPLETED,un.BUG_FOUND,un.RUNTIME_CRASHED,un.FEEDBACK_SUBMITTED,un.TOOL_REFUSED,un.HUD_VIEWED,un.HUD_SIGNIN_PROMPTED,un.HARNESS_RUN]),hV={HUMAN:"human",AGENT:"agent"},mV={GIT_ORIGIN:"git_origin",GIT_ROOT:"git_root",PACKAGE_ROOT:"package_root",CWD:"cwd"},gV={HARNESS:"harness"},EV=b({via:p().min(1).max(64),verified:p().min(1).max(16),passed:L(),falseGreenCaught:L(),durationMs:S().int().nonnegative().optional(),browser:p().min(1).max(16).optional(),brand:R(qe).optional(),reason:R(lt).optional(),uncleanLoss:R(YR).optional(),driven:R(gV).optional(),sdkVersion:p().min(1).max(32).optional()}),bV=b({from:p().min(1).max(64),to:p().min(1).max(64),nudged:L().optional(),direction:p().min(1).max(16)}),f0={RETICLE:"reticle",OTHER:"other"},_V=b({kind:p().min(1).max(32),errorType:p().min(1).max(64).optional(),fingerprint:p().min(1).max(64).optional(),message:p().max(300).optional(),frames:C(p().max(120)).max(12).optional(),tool:p().min(1).max(64).optional(),breadcrumb:C(p().max(64)).max(12).optional(),nodeVersion:p().max(24).optional(),arch:p().max(16).optional(),machine:T_.optional(),syscall:p().max(32).optional(),errno:p().max(32).optional(),loopback:L().optional(),port:pe([f0.RETICLE,f0.OTHER]).optional(),internalFrame:p().max(64).optional()}),SV=b({reconnect:L(),daemonAgeMs:S().int().nonnegative(),client:p().min(1).max(64).optional(),appConnected:L().optional(),proxyId:p().min(1).max(64).optional()}),TV=b({initialized:L(),agentAttached:L(),msToFirstApp:S().int().nonnegative(),firstEver:L().optional()}),xV={FIRST:"first",BUDGET_SPENT:"budget_spent",RECOVERED:"recovered"},AV={SSE_ENDED:"sse_ended",DAEMON_SHUTDOWN:"daemon_shutdown",SSE_ERROR:"sse_error",SSE_ABORTED:"sse_aborted",SSE_CLOSED:"sse_closed",CONNECT_ERROR:"connect_error",SSE_RESET:"sse_reset",OTHER:"other"},yV=b({stage:R(xV),reason:R(AV),attempts:S().int().nonnegative(),pendingLost:S().int().nonnegative().optional(),errCode:R(u0).optional(),responded:L().optional(),proxyId:p().min(1).max(64).optional()}),wV={SKILL_FILE:"skill_file",NPX_SKILL:"npx_skill",PLUGIN:"plugin",INSTALL_SCRIPT:"install_script",DOCS_SITE:"docs_site",README:"readme",BLOG:"blog",CLI_DIRECT:"cli_direct",UNKNOWN:"unknown"},vV={CONTAINER:"container",HOSTED_WORKSPACE:"hosted_workspace",CI_RUNNER:"ci_runner",AGENT_SANDBOX:"agent_sandbox"},NV={CONNECTED:"connected",NO_DAEMON:"no_daemon",NO_SESSION:"no_session",NO_PAGE:"no_page"},RV={NO_DEV_COMMAND:"no_dev_command",SPLIT_LOOPBACK:"split_loopback",PORT_BUSY:"port_busy",DEV_SERVER_EXITED:"dev_server_exited",NO_URL:"no_url",NOT_READY:"not_ready",PAGE_NOT_SERVED:"page_not_served",PAGE_TLS_REFUSED:"page_tls_refused",SDK_MISSING:"sdk_missing",NO_SESSION:"no_session",DESKTOP_NO_SESSION:"desktop_no_session"},OV=b({ok:L(),reason:p().max(64).optional(),stack:p().max(64).optional(),mcpRegistered:L().optional(),confirmation:R(NV).optional(),stop:R(RV).optional()}),rne=b({v:U(fV),anonymousId:p().min(1).max(128),projectId:p().min(1).max(128).optional(),sessionId:p().min(1).max(64).optional(),event:R(un),ts:S().int().nonnegative(),version:p().min(1).max(64),ci:L(),automation:R(vV).optional(),projectIdSource:R(mV).optional(),os:p().min(1).max(32),tzOffsetMin:S().int().min(-900).max(900).optional(),internal:L().optional(),idEphemeral:L().optional(),feedback:TI.optional(),actor:R(hV).optional(),command:p().min(1).max(32).optional(),flags:C(p().max(32)).max(16).optional(),session:s0.optional(),project:a0.optional(),verification:EV.optional(),versionChange:bV.optional(),crash:_V.optional(),identity:xI.optional(),connection:SV.optional(),init:OV.optional(),onboarding:e0.optional(),bug:p0.optional(),refusal:r0.optional(),outage:yV.optional(),instrumentation:TV.optional(),installSource:R(wV).optional(),licenseId:p().min(1).max(64).optional(),licenseStatus:R(c0).optional(),licenseKeyPresent:L().optional(),...l0,...d0})});var m0=y(()=>{"use strict"});var g0,N_=y(()=>{"use strict";cb();g0={SESSIONS:"reticle_sessions",LOOK:"reticle_look",SNAPSHOT:"reticle_snapshot",QUERY:"reticle_query",INSPECT:"reticle_inspect",ACT:sc.ACT,ACT_SEQUENCE:sc.ACT_SEQUENCE,ACT_AND_WAIT:sc.ACT_AND_WAIT,OBSERVE:"reticle_observe",LINEAGE:"reticle_lineage",WAIT_FOR:"reticle_wait_for",NETWORK:"reticle_network",CONSOLE:"reticle_console",ANIMATIONS:"reticle_animations",ASSERT:"reticle_assert",RECONCILE:"reticle_reconcile",BASELINE_SAVE:"reticle_baseline_save",BASELINE_LIST:"reticle_baseline_list",DIFF:"reticle_diff",RECORD_START:"reticle_record_start",RECORD_STOP:"reticle_record_stop",REPLAY:"reticle_replay",EXPLORE:"reticle_explore",NARRATE:"reticle_narrate",CLOCK:"reticle_clock",STATE:"reticle_state",STORAGE:"reticle_storage",CAPABILITIES:"reticle_capabilities",CONTRACT_SAVE:"reticle_contract_save",DOMAIN:"reticle_domain",FLOW_SAVE:"reticle_flow_save",FLOW_LIST:"reticle_flow_list",FLOW_LOAD:"reticle_flow_load",FLOW_DELETE:"reticle_flow_delete",FLOW_REPLAY:"reticle_flow_replay",FLOW_VERIFY:"reticle_flow_verify",FLOW_SAVE_RECORDED:"reticle_flow_save_recorded",FLOW_HEAL:"reticle_flow_heal",FLOW_MUTATE:"reticle_flow_mutate",ANNOTATE:"reticle_annotate",AFFECTED:"reticle_affected",COVERAGE:"reticle_coverage",VERIFY_CHANGE:"reticle_verify_change",VERIFY_EXPLORE:"reticle_verify_explore",INTENT:"reticle_intent",CONTEXT:"reticle_context",MAP:"reticle_map",VERIFY:"reticle_verify",PROJECT:"reticle_project",ACCOUNT:"reticle_account",MEMORY:"reticle_memory",RUN_RECORD:"reticle_run_record",SCREENSHOT:"reticle_screenshot",NETWORK_MOCK:"reticle_network_mock",VIEWPORT:"reticle_viewport",VISUAL_DIFF:"reticle_visual_diff",CRAWL:"reticle_crawl",SCROLL_TO:"reticle_scroll_to",SESSION_TUNE:"reticle_session_tune",END_SESSION:"reticle_end_session",YIELD:"reticle_yield",RESUME:"reticle_resume",MESSAGES:"reticle_messages",REVIEW:"reticle_review",WAIT_READY:"reticle_wait_ready",NAVIGATE:"reticle_navigate",REFRESH:"reticle_refresh",RUN_EXPORT:"reticle_run_export",BASELINE:"reticle_baseline",SESSION:"reticle_session",RECORD:"reticle_record",FLOW:"reticle_flow",LEASE:"reticle_lease",LEASE_ACQUIRE:"reticle_lease_acquire",LEASE_RELEASE:"reticle_lease_release",TOOLS:"reticle_tools",RUN:"reticle_run",FEEDBACK:"reticle_feedback"}});var E0,IV,dh,CV,une,dne,pne,b0=y(()=>{"use strict";ae();N_();E0="reticle connect",IV={HARNESS_NOT_LINKED:"harness_not_linked"},dh={HUMAN:"human",AGENT:"agent"},CV=vt("who",[b({who:U(dh.HUMAN),run:p()}),b({who:U(dh.AGENT),tool:p()})]),une=b({code:pe([IV.HARNESS_NOT_LINKED]),next:C(CV)}),dne=[{who:dh.HUMAN,run:E0},{who:dh.AGENT,tool:g0.ACT_AND_WAIT}],pne=`Connect your Reticle account to run the Harness: \`${E0}\`.`});var _0=y(()=>{"use strict"});var S0=y(()=>{"use strict"});var Sne,Tne,xne,Ane,T0=y(()=>{"use strict";pc();gc();th();Kt();Sne={[zi.WEB]:{surface:or.WEB,isDesktopShell:!1,usesWebKit:!1,ownsCoverageKinds:!1,hasOwnBaselineDirectory:!1},[zi.ELECTRON]:{surface:or.DESKTOP,isDesktopShell:!0,projectMarker:{dependency:"electron"},usesWebKit:!1,ownsCoverageKinds:!0,hasOwnBaselineDirectory:!0},[zi.TAURI]:{surface:or.DESKTOP,isDesktopShell:!0,projectMarker:{file:"src-tauri/tauri.conf.json"},usesWebKit:!0,ownsCoverageKinds:!1,hasOwnBaselineDirectory:!0}},Tne=new Set(Object.values(rr)),xne={[zi.WEB]:so.WEB,[zi.ELECTRON]:so.WEBVIEW,[zi.TAURI]:so.WEBVIEW},Ane={[or.WEB]:{reset:"cheap",replayPrefix:"free",time:"injectable",observation:"exact",actions:"reversible"},[or.DESKTOP]:{reset:"cheap",replayPrefix:"free",time:"injectable",observation:"exact",actions:"reversible"},[or.MOBILE]:{reset:"costly",replayPrefix:"costly",time:"wall",observation:"exact",actions:"reversible"},[or.SERVICE]:{reset:"costly",replayPrefix:"unsafe",time:"wall",observation:"exact",actions:"irreversible"},[or.GAME]:{reset:"cheap",replayPrefix:"free",time:"stepped",observation:"exact",actions:"reversible"},[or.DEVICE]:{reset:"costly",replayPrefix:"unsafe",time:"wall",observation:"sampled",actions:"irreversible"}}});var y0,LV,$V,x0,kV,w0,zV,A0,DV,xt,PV,MV,UV,HV,FV,BV,v0,GV,VV,N0,R_=y(()=>{"use strict";ae();y0=b({calls:S().int().nonnegative(),verdicts:S().int().nonnegative(),passed:S().int().nonnegative(),failed:S().int().nonnegative(),unknown:S().int().nonnegative(),refusals:S().int().nonnegative(),marks:S().int().nonnegative(),sessions:S().int().nonnegative(),tokensReturned:S().int().nonnegative(),drivingMs:S().int().nonnegative()}),LV=b({date:p(),counts:y0}),$V=b({longestRunMs:S().int().nonnegative(),bestVerdictDay:S().int().nonnegative(),bestDefectDay:S().int().nonnegative(),streakDays:S().int().nonnegative(),bestStreakDays:S().int().nonnegative()}),x0=b({value:S().nonnegative(),basis:p()}),kV=b({tokens:x0,minutes:x0}),w0=10,zV=b({at:S().int().nonnegative(),title:p(),detail:p().optional(),source:p().optional()}),A0=b({counts:y0,days:C(LV),records:$V,savings:kV,since:S().int().nonnegative(),defects:C(zV).default([])}),DV=b({signedIn:L(),org:p().optional(),email:p().optional(),host:p().optional()}),xt={FREE:"free",TRIAL:"trial",PAID:"paid"},PV=b({provider:p(),harnessEnabled:L(),harnessEntitled:L(),providerReady:L().optional(),credits:b({used:S().min(0),limit:S().min(0),kind:pe([xt.FREE,xt.TRIAL,xt.PAID]).optional(),daysLeft:S().int().min(0).optional()}).optional(),platformUrl:p().optional(),planUrl:p().optional(),plan:b({kind:pe([xt.FREE,xt.TRIAL,xt.PAID]),daysLeft:S().int().min(0).optional(),seats:S().int().min(0).optional()}).optional(),harnessRuns:S().int().min(0).optional(),memoryEntries:S().int().min(0).optional()}),MV=60,UV=b({runId:p(),steps:S().int().min(0),lines:C(p()).max(MV).optional()}),HV=b({runUrl:p().optional(),said:p().optional(),seq:S().int().min(0).optional()}),FV=500,BV=5,v0=64,GV=b({text:p().max(FV),seen:L(),by:p().max(v0).optional()}),VV=b({agents:C(p().max(v0)).max(8),notes:C(GV).max(BV)}),N0=b({schemaVersion:S().int().positive(),project:A0,global:A0,projectName:p().optional(),dashboardUrl:p().optional(),account:DV.optional(),harnessConfig:PV.optional(),harnessDrive:UV.optional(),lastDrive:HV.optional(),agent:VV.optional(),notices:C(q()).max(8).optional(),coverage:ie(p(),S()).optional(),sync:ie(p(),q()).optional(),instrumentation:ie(p(),q()).optional()})});var R0=y(()=>{"use strict"});function _c(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619)>>>0;return t.toString(16).padStart(8,"0")}function O0(e){let t=Object.keys(e).sort().map(n=>{var r;return`${n}:${[...(r=e[n])!=null?r:[]].sort().join(",")}`}).join("|");return _c(t)}var O_,Qu,I0=y(()=>{"use strict";Kt();O_=O0({messageKinds:Object.values(sn),commands:Object.values(H),actions:Object.values(D),events:Object.values(w)}),Qu={commands:Object.values(H),events:Object.values(w),actions:Object.values(D)}});var C0,L0=y(()=>{"use strict";C0="[Reticle] this page could not open a websocket to "});var $0=y(()=>{"use strict"});var M=y(()=>{"use strict";_A();mO();gO();EO();SO();Kt();Zb();xO();wO();NO();$O();Xb();kO();jo();zO();DO();PO();Jb();Gu();BO();e_();ZO();YO();XO();f_();ih();EI();bI();AI();yI();Iu();cb();hO();pb();wI();Cb();Rb();Lb();NI();Hu();RI();OI();Vo();Mb();Db();Fb();Bb();Gb();II();CI();LI();zI();PI();MI();UI();HI();FI();BI();GI();E_();jI();KI();u_();s_();WI();YI();XI();h0();__();S_();m0();N_();b0();_0();th();nh();S0();T0();x_();w_();A_();gc();R_();R0();I0();L0();$0()});function ke(e,t){return e[t]}function k0(e){let t=Object.getOwnPropertyDescriptor(e,"value");return t===void 0?void 0:ke(t,"set")}var Wo=y(()=>{"use strict"});function ZV(){for(let e of Di)e.deref()===void 0&&Di.delete(e);for(;Di.size>jV;){let e=Di.values().next();if(e.done===!0)break;Di.delete(e.value)}}function P0(){let e=[];for(let t of Di){let n=t.deref();n!==void 0&&e.push(n)}return e}function D0(e,t){if(!z0.has(e)){z0.add(e),Di.add(new WeakRef(e)),C_+=1,C_>=KV&&(C_=0,ZV()),L_.add(t);for(let n of ph)n(e)}}function M0(){return P0()}function U0(e){return L_.has(e)}function Ks(e){if(!L_.has(e))return null;for(let t of P0())if(t.host===e)return t;return null}function H0(e){return ph.add(e),()=>ph.delete(e)}function F0(){let e=Element.prototype,t=ke(e,"attachShadow");if(typeof t!="function")return()=>{};I_+=1;let n=function(i){let s=t.call(this,i);return D0(s,this),s};e.attachShadow=n;let r=o=>{for(let i of o.querySelectorAll("*")){let s=i.shadowRoot;s!==null&&(D0(s,i),r(s))}};return document.documentElement!==null&&r(document.documentElement),()=>{ke(e,"attachShadow")===n&&(e.attachShadow=t),I_-=1,!(I_>0)&&(Di.clear(),ph.clear())}}function WV(e){let t=e.parentElement;if(t===null||t.shadowRoot!==null)return null;let n=Ks(t);if(n===null)return null;for(let r of Array.from(n.querySelectorAll("slot")))if(r.assignedElements().includes(e))return r;return null}function Pi(e){var r;let t=(r=e.assignedSlot)!=null?r:WV(e);if(t!==null)return t;if(e.parentElement!==null)return e.parentElement;let n=e.getRootNode().host;return n!=null?n:null}var I_,Di,z0,L_,jV,KV,C_,ph,Yo=y(()=>{"use strict";Wo();I_=0,Di=new Set,z0=new WeakSet,L_=new WeakSet,jV=4e3,KV=250,C_=0;ph=new Set});function B0(e,t){var o;if(e===null||typeof e!="object")return;let r=((o=e.ownerDocument)!=null?o:e).defaultView;if(r!=null)return r[t]}function Gn(e,t,n){var o;let r=(o=B0(e,t))!=null?o:n;return typeof r=="function"&&e instanceof r}function Z0(e){let t=vn(e)?"HTMLTextAreaElement":"HTMLInputElement",n=B0(e,t);if(typeof n!="function")return;let r=n.prototype;return typeof r=="object"&&r!==null?r:void 0}var wn,$_,ut,YV,Mi,He,vn,$r,ed,G0,V0,j0,K0,fh,dn=y(()=>{"use strict";wn=e=>Gn(e,"Element",typeof Element=="undefined"?void 0:Element),$_=e=>Gn(e,"HTMLImageElement",typeof HTMLImageElement=="undefined"?void 0:HTMLImageElement),ut=e=>Gn(e,"HTMLElement",typeof HTMLElement=="undefined"?void 0:HTMLElement),YV=e=>Gn(e,"SVGElement",typeof SVGElement=="undefined"?void 0:SVGElement),Mi=e=>ut(e)||YV(e),He=e=>Gn(e,"HTMLInputElement",typeof HTMLInputElement=="undefined"?void 0:HTMLInputElement),vn=e=>Gn(e,"HTMLTextAreaElement",typeof HTMLTextAreaElement=="undefined"?void 0:HTMLTextAreaElement),$r=e=>Gn(e,"HTMLSelectElement",typeof HTMLSelectElement=="undefined"?void 0:HTMLSelectElement),ed=e=>Gn(e,"HTMLButtonElement",typeof HTMLButtonElement=="undefined"?void 0:HTMLButtonElement),G0=e=>Gn(e,"HTMLMeterElement",typeof HTMLMeterElement=="undefined"?void 0:HTMLMeterElement),V0=e=>Gn(e,"HTMLOutputElement",typeof HTMLOutputElement=="undefined"?void 0:HTMLOutputElement),j0=e=>Gn(e,"HTMLProgressElement",typeof HTMLProgressElement=="undefined"?void 0:HTMLProgressElement),K0=e=>Gn(e,"HTMLFormElement",typeof HTMLFormElement=="undefined"?void 0:HTMLFormElement),fh=e=>Gn(e,"HTMLIFrameElement",typeof HTMLIFrameElement=="undefined"?void 0:HTMLIFrameElement)});function JV(e){if(e.id.length>0)return`#${e.id}`;let t=e.getAttribute("class");return t!==null&&t.trim().length>0?`.${t.trim().split(/\s+/).join(".")}`:e.tagName.toLowerCase()}function W0(e){let t=e.ownerDocument.defaultView;if(t===null)return[];let n=[];for(let r=e;r!==null&&r!==e.ownerDocument.documentElement;r=r.parentElement){let o=t.getComputedStyle(r);for(let i of XV){let s=o.getPropertyValue(i);s.length>0&&s!==qV[i]&&n.push({on:JV(r),property:i,value:s})}}return n}function hh(e){var o;let t=(o=e==null?void 0:e.overflow)!=null?o:"",[n="visible",r=n]=(t===""?"visible":t).split(/\s+/);return[e===null||e.overflowX===""?n:e.overflowX,e===null||e.overflowY===""?r:e.overflowY]}function k_(e,t){var Y;if(t.clipBox!==void 0)return t.clipBox;let n=e.getBoundingClientRect(),r=t.style,o=X=>Number.parseFloat(X!=null?X:"")||0,i=(X,G)=>G===void 0||G===""||G==="none"||G==="hidden"?0:o(X),s=ut(e)&&e.offsetWidth>0?n.width/e.offsetWidth:1,a=ut(e)&&e.offsetHeight>0?n.height/e.offsetHeight:1,l=ut(e)&&e.offsetWidth>0?n.left+e.clientLeft*s:n.left+i(r==null?void 0:r.borderLeftWidth,r==null?void 0:r.borderLeftStyle),u=ut(e)&&e.offsetHeight>0?n.top+e.clientTop*a:n.top+i(r==null?void 0:r.borderTopWidth,r==null?void 0:r.borderTopStyle),d=ut(e)&&e.offsetWidth>0?l+e.clientWidth*s:n.right-i(r==null?void 0:r.borderRightWidth,r==null?void 0:r.borderRightStyle),f=ut(e)&&e.offsetHeight>0?u+e.clientHeight*a:n.bottom-i(r==null?void 0:r.borderBottomWidth,r==null?void 0:r.borderBottomStyle),m=((Y=r==null?void 0:r.overflowClipMargin)!=null?Y:"").split(/\s+/),h=o(m.at(-1)),E=m.includes("border-box"),_=m.includes("content-box"),[A,v]=hh(r),N=A==="clip"?(E?n.left:l+(_?o(r==null?void 0:r.paddingLeft)*s:0))-h*s:l,O=A==="clip"?(E?n.right:d-(_?o(r==null?void 0:r.paddingRight)*s:0))+h*s:d,k=v==="clip"?(E?n.top:u+(_?o(r==null?void 0:r.paddingTop)*a:0))-h*a:u,j=v==="clip"?(E?n.bottom:f-(_?o(r==null?void 0:r.paddingBottom)*a:0))+h*a:f;return t.clipBox={left:N,right:O,top:k,bottom:j,width:O-N,height:j-k},t.clipBox}function Y0(e,t,n,r){let o=(u,d,f,m,h)=>{if(d>m&&u<h)return[u,d];let E=Math.min(f,h-m);return u>=h?[h-E,h]:[m,m+E]},[i,s]=n?o(e.left,e.right,e.width,t.left,t.right):[e.left,e.right],[a,l]=r?o(e.top,e.bottom,e.height,t.top,t.bottom):[e.top,e.bottom];return{left:i,right:s,top:a,bottom:l,width:s-i,height:l-a}}var XV,qV,z_=y(()=>{"use strict";dn();XV=["filter","opacity","transform","mix-blend-mode","backdrop-filter"],qV={filter:"none",opacity:"1",transform:"none","mix-blend-mode":"normal","backdrop-filter":"none"}});function QV(e){let t=e.parentElement;if(t===null)return!1;let n=t.closest(D_);if(n===null||n.hasAttribute(P_))return!1;let r=Array.from(n.children).find(o=>mh===o.localName);return r===void 0||!r.contains(e)}function e4(e){return!e.ownerDocument.hidden||!("getAnimations"in e)?!1:e.getAnimations().some(t=>t.playState==="running"||t.pending)}function n4(e){return e.hasAttribute(t4)}function M_(e,t){return!!(ut(e)&&e.hidden||QV(e)||t!==null&&(t.display==="none"||t.visibility==="hidden"||t.visibility==="collapse"||Number.parseFloat(t.opacity||"1")===0&&!e4(e)||r4(t)))}function r4(e){var u,d,f,m;let t=/^rect\((.*)\)$/.exec(e.getPropertyValue("clip").trim());if(t!==null&&(e.position==="absolute"||e.position==="fixed")){let[h,E,_,A]=((u=t[1])!=null?u:"").split(/[\s,]+/).map(Number.parseFloat);if(E!==void 0&&A!==void 0&&E<=A||_!==void 0&&h!==void 0&&_<=h)return!0}let n=/^inset\(([^)]*)\)$/.exec(e.getPropertyValue("clip-path").trim()),r=(m=(f=(d=n==null?void 0:n[1])==null?void 0:d.split(/\s+round\s/)[0])==null?void 0:f.trim().split(/\s+/))!=null?m:[],o=h=>h.endsWith("%")||Number.parseFloat(h)===0;if(r.length===0||!r.every(o))return!1;let[i=0,s=i,a=i,l=s]=r.map(Number.parseFloat);return i+a>=100||l+s>=100}function o4(e,t){return e.getAttribute("aria-hidden")==="true"&&!n4(e)?!0:M_(e,t)}function eC(e){var r,o;let t=!1,n=e;for(;n!==null;){n.getAttribute("aria-hidden")==="true"&&(t=!0);let i=(o=(r=n.ownerDocument.defaultView)==null?void 0:r.getComputedStyle(n))!=null?o:null;if(M_(n,i))return!1;n=Pi(n)}return t}function tC(e){var n,r;let t=e;for(;t!==null;){if(t.getAttribute("aria-hidden")==="true")return!1;let o=(r=(n=t.ownerDocument.defaultView)==null?void 0:n.getComputedStyle(t))!=null?r:null;if(M_(t,o))return!1;t=Pi(t)}return!0}function oC(e){if(e===void 0)return new Map;let t=Q0.get(e);return t===void 0&&(t=new Map,Q0.set(e,t)),t}function lo(e,t){var r,o,i;let n=t.get(e);if(n===void 0){let s=(o=(r=e.ownerDocument.defaultView)==null?void 0:r.getComputedStyle(e))!=null?o:null;if(o4(e,s))return n={hidden:!0,style:s,parent:null,clipX:!1,clipY:!1,scrollX:!1,scrollY:!1,hasClipping:!1},t.set(e,n),n;let a=Pi(e),l=a===null?void 0:lo(a,t),[u,d]=hh(s),f=e.ownerDocument.documentElement,h=!(e===f||e===e.ownerDocument.body&&hh(lo(f,t).style).every(A=>A==="visible"))&&!nC.has((i=s==null?void 0:s.display)!=null?i:"")&&!(ut(e)&&(s==null?void 0:s.display)==="inline"),E=h&&X0.has(u),_=h&&X0.has(d);n={hidden:(l==null?void 0:l.hidden)===!0,style:s,parent:a,clipX:E,clipY:_,scrollX:h&&q0.has(u),scrollY:h&&q0.has(d),hasClipping:E||_||(l==null?void 0:l.hasClipping)===!0},t.set(e,n)}return n}function a4(e,t,n){for(let r=lo(e,n).parent;r!==null;r=lo(r,n).parent){let o=lo(r,n).style;if(o===null||o.display==="contents")continue;if(!t&&o.position!==""&&o.position!=="static")return r;let i=!(o.display==="inline"&&ut(r)&&!s4.has(r.localName))&&o.display!=="table-column"&&o.display!=="table-column-group",s=a=>i||!rC.has(a);if([...J0].some(a=>{let l=o.getPropertyValue(a);return s(a)&&l!==""&&l!=="none"})||o.willChange.split(",").some(a=>J0.has(a.trim())&&s(a.trim()))||i&&!nC.has(o.display)&&(o.contain.split(/\s+/).some(a=>i4.has(a))||o.contentVisibility==="auto"))return r}return null}function iC(e,t,n,r=!1){let o=n,i=lo(e,t);if(i.hidden)return null;if(i.parent===null||!lo(i.parent,t).hasClipping)return o;let s;for(let a=e;a!==null;a=lo(a,t).parent){let l=lo(a,t);if(l.hidden)return null;a===s&&(s=void 0);let u=l.style;if(r&&a!==e&&s===void 0&&(l.scrollX||l.scrollY)&&(o!=null||(o=e.getBoundingClientRect()),o.width>0&&o.height>0&&(o=Y0(o,k_(a,l),l.scrollX,l.scrollY))),a!==e&&s===void 0&&(l.clipX||l.clipY)&&(o!=null||(o=e.getBoundingClientRect()),o.width>0&&o.height>0)){let d=k_(a,l),f=l.clipX?Math.max(o.left,d.left):o.left,m=l.clipX?Math.min(o.right,d.right):o.right,h=l.clipY?Math.max(o.top,d.top):o.top,E=l.clipY?Math.min(o.bottom,d.bottom):o.bottom;if(m<=f||E<=h)return null;o={left:f,right:m,top:h,bottom:E,width:m-f,height:E-h}}s===void 0&&((u==null?void 0:u.position)==="absolute"||(u==null?void 0:u.position)==="fixed")&&(s=a4(a,(u==null?void 0:u.position)==="fixed",t))}return o}function U_(e,t){if(!Je(e,t))return!1;let n=e.ownerDocument.defaultView;if(n===null)return!1;let r=iC(e,oC(t),e.getBoundingClientRect());return r==null||r.width<=0||r.height<=0?!1:r.bottom>0&&r.right>0&&r.top<n.innerHeight&&r.left<n.innerWidth}function c4(e,t){let n=lo(e,t);if(!n.clipX&&!n.clipY)return!1;let r=Array.from(e.getClientRects());return r.length>0&&r.every(o=>n.clipX&&o.width===0||n.clipY&&o.height===0||n.clipX&&n.clipY&&o.width<=1&&o.height<=1)}function Je(e,t){if(!e.isConnected)return!1;let n=t==null?void 0:t.get(e);if(n!==void 0)return n;let r=oC(t),o=iC(e,r,void 0,!0)!==null&&!c4(e,r);return t!==void 0&&t.set(e,o),o}var D_,P_,mh,t4,X0,q0,nC,rC,J0,i4,s4,Q0,uo=y(()=>{"use strict";dn();Yo();z_();D_="details",P_="open",mh="summary";t4="data-aria-hidden";X0=new Set(["hidden","clip"]),q0=new Set(["auto","scroll"]),nC=new Set(["contents","table-row","table-row-group","table-header-group","table-footer-group","table-column","table-column-group"]),rC=new Set(["transform","translate","rotate","scale","perspective"]),J0=new Set([...rC,"filter","backdrop-filter"]),i4=new Set(["layout","paint","strict","content"]),s4=new Set(["img","video","audio","canvas","iframe","embed","object","input","textarea","select"]),Q0=new WeakMap});function cC(e){F_=e}function B_(e){lC=e}function dC(){return F_}function pC(e){aC=e.join(",")}function Rt(e){return e.closest(Ui)!==null}function Hi(e){return Rt(e)?!uC()||e.closest(u4)===null:!1}function lr(e){return e!==null&&e.closest(Ui)!==null}function Mt(e){let n=[uC()?d4:Ui,l4,aC].filter(r=>r.length>0).join(",");return e.closest(n)!==null}function td(e){return Mt(e)||Rt(e)}function h4(e){var r;let t=e.querySelector(f4);if(t!==null)return{name:H_.VITE,host:t};for(let o of Array.from(e.querySelectorAll(p4))){let i=(r=o.shadowRoot)!=null?r:Ks(o),s=(i!=null?i:o).querySelector(sC);if(s!==null&&Je(s))return{name:H_.NEXT,host:o}}let n=e.querySelector(sC);if(!(n===null||!Je(n)))return{name:H_.NEXT,host:n}}function fC(e){let t=e[0];if(t===void 0)return;let n=h4(t.ownerDocument);if(n!==void 0)return e.some(r=>!m4(r,n.host))?n.name:void 0}function m4(e,t){var n;for(let r=e;r!==null;){if(r===t)return!0;let o=r.getRootNode();r=(n=r.parentNode)!=null?n:o instanceof ShadowRoot?o.host:null}return!1}function gh(e){for(let t of Array.from(e.querySelectorAll(g4)))if(t.closest(Ui)===null&&!(t instanceof HTMLElement&&(t.hidden||t.closest("[hidden]")!==null))&&!(t instanceof HTMLElement&&getComputedStyle(t).display==="none"))return!0;return!1}var Ui,l4,aC,F_,lC,uC,u4,d4,H_,p4,sC,f4,g4,nt=y(()=>{"use strict";M();Yo();uo();Ui=Vu,l4="[data-agentation],#__next-build-watcher,nextjs-portal,[data-nextjs-dialog],[data-nextjs-toast]",aC="",F_=!1;lC=!1;uC=()=>F_&&!lC;u4="[data-reticle-dock]";d4="[data-reticle-log],[data-reticle-harness-log],[data-reticle-chat-pill-text],[data-reticle-agent-said],[data-reticle-agent-note],[data-reticle-act-line]";H_={NEXT:"Next.js error dialog",VITE:"Vite error overlay"},p4="nextjs-portal",sC="[data-nextjs-dialog]",f4="vite-error-overlay";g4='dialog[open], [aria-modal="true"]'});function Fi(){return Eh}function Vn(){return`[${Eh}]`}function Ne(e){return e.getAttribute(Eh)}function _C(e){Eh=e!==void 0&&yO.test(e)?e:Us}var Eh,Ot=y(()=>{"use strict";M();Eh=Us});function Th(e){return T4.has(e)||e.startsWith(bh)||e.startsWith(_h)||e.startsWith(Sh)}var At,bh,_h,Sh,T4,po=y(()=>{"use strict";At={SESSION:"__reticle_session",REF_BASE:"__reticle_ref_base",PRESENTER_LOG:"reticle-presenter-log",PRESENTER_LOG_OWNER:"reticle-presenter-log-owner",PRESENTER_SETTINGS:"reticle-presenter-settings",PRESENTER_MINIMISED:"reticle-presenter-minimised",PRESENTER_OPEN:"reticle-presenter-open",PRESENTER_VIEW:"reticle-presenter-view",CAROUSEL_DISMISSED:"reticle.carousel.dismissed",ANNOTATION_HISTORY:"reticle.annotations.history.v1"},bh="reticle.tour.seen.",_h="reticle.harness.persona.",Sh="reticle.impact.seen.",T4=new Set(Object.values(At))});function kr(e){let t=Z.MAX_REF_LENGTH;return t>=e.length?e:`${e.slice(0,t)}${x4}`}function w4(e){try{let t=e==null?void 0:e.getItem(TC),n=t==null?Number.NaN:Number(t);return Number.isSafeInteger(n)&&n>0?n:0}catch{return 0}}var SC,x4,G_,A4,TC,y4,rd,It,od,Xo,Sc,Tc,xc,qo,xC,V_,AC,nd,re,gt=y(()=>{"use strict";M();po();SC=1e4,x4="\u2026",G_="e";A4=1e3,TC=At.REF_BASE,y4=100;nd=class{constructor(t=()=>globalThis.sessionStorage){x(this,qo);x(this,rd,new WeakMap);x(this,It,new Map);x(this,od);x(this,Xo,0);x(this,Sc,0);x(this,Tc,0);x(this,xc,0);g(this,od,t)}get size(){return c(this,It).size}markEdited(){g(this,xc,c(this,Xo))}mintedBeforeLastEdit(t){if(c(this,xc)===0||!t.startsWith(G_))return!1;let n=Number(t.slice(G_.length));return Number.isSafeInteger(n)&&n>0&&n<=c(this,xc)}refFor(t){let n=c(this,rd).get(t);if(n!==void 0){let o=c(this,It).get(n);return c(this,It).delete(n),c(this,It).set(n,o!=null?o:new WeakRef(t)),n}c(this,Xo)>=c(this,Sc)&&T(this,qo,xC).call(this),g(this,Xo,c(this,Xo)+1);let r=vI(`${G_}${String(c(this,Xo))}`);return c(this,rd).set(t,r),c(this,It).set(r,new WeakRef(t)),g(this,Tc,c(this,Tc)+1),c(this,Tc)>=A4?(g(this,Tc,0),T(this,qo,AC).call(this)):c(this,It).size>SC&&T(this,qo,V_).call(this),r}resolve(t){let n=c(this,It).get(t);if(n===void 0)return null;let r=n.deref();return r===void 0||!r.isConnected?(c(this,It).delete(t),null):(c(this,It).delete(t),c(this,It).set(t,n),r)}};rd=new WeakMap,It=new WeakMap,od=new WeakMap,Xo=new WeakMap,Sc=new WeakMap,Tc=new WeakMap,xc=new WeakMap,qo=new WeakSet,xC=function(){let t;try{t=c(this,od).call(this)}catch{t=void 0}let n=Math.max(w4(t),c(this,Xo));g(this,Sc,n+y4);try{t==null||t.setItem(TC,String(c(this,Sc)))}catch{}g(this,Xo,n)},V_=function(){let t=c(this,It).keys().next();t.done!==!0&&c(this,It).delete(t.value)},AC=function(){for(let[t,n]of c(this,It)){let r=n.deref();(r===void 0||!r.isConnected)&&c(this,It).delete(t)}for(;c(this,It).size>SC;)T(this,qo,V_).call(this)};re=new nd});function yC(e){var n;return((n=e.match(/-?\d*\.?\d+(?:e[-+]?\d+)?|NaN|Infinity|-Infinity/gi))!=null?n:[]).map(r=>Number(r))}function R4(e){return/NaN|Infinity/i.test(e)?!0:yC(e).some(t=>!Number.isFinite(t))}function O4(e){let t=yC(e).filter(i=>Number.isFinite(i));if(t.length===0)return!0;let n=t.filter((i,s)=>s%2===0),r=t.filter((i,s)=>s%2===1),o=i=>i.every(s=>s===i[0]);return n.length>1&&o(n)&&o(r)}function xh(e){let t=[],n=0;for(let o of v4)for(let i of Array.from(e.querySelectorAll(o)))for(let s of N4){let a=i.getAttribute(s);if(a===null)continue;n+=1;let l=a.length>120?`${a.slice(0,120)}\u2026`:a;R4(a)?t.push({kind:"non-finite-coordinates",tag:o,attr:s,sample:l}):a.trim().length===0?t.push({kind:"empty-geometry",tag:o,attr:s,sample:l}):O4(a)&&t.push({kind:"degenerate-geometry",tag:o,attr:s,sample:l})}let r=e.querySelectorAll("canvas").length>0;return{examined:n,findings:t,canvas:r}}function wC(e,t){var i,s,a,l,u,d,f;let n=t,r=(s=(i=n.Chart)==null?void 0:i.getChart)==null?void 0:s.call(i,e);if(r!=null)return{library:"chartjs",data:(a=r.data)!=null?a:null};let o=(u=(l=n.echarts)==null?void 0:l.getInstanceByDom)==null?void 0:u.call(l,e);return o!=null?{library:"echarts",data:(f=(d=o.getOption)==null?void 0:d.call(o))!=null?f:null}:null}var v4,N4,j_=y(()=>{"use strict";v4=["path","polyline","polygon"],N4=["d","points"]});function id(e,t,n){let r=Math.max(0,Math.min(n,t.remainingCharacters));if(e.length<=r)return t.remainingCharacters-=e.length,e;t.truncatedValues+=1;let o=r<=sd.length?sd.slice(0,r):`${e.slice(0,r-sd.length)}${sd}`;return t.remainingCharacters-=o.length,o}function ad(e,t,n,r){if(r!==void 0&&St(r))return ve;if(n>Z.MAX_SERIALIZE_DEPTH||t.nodes>=Ac)return t.truncatedValues+=1,sd;if(t.nodes+=1,e===null||typeof e=="boolean")return e;if(typeof e=="string")return id(io(e),t,(r==null?void 0:r.toLowerCase())==="error"?Z.MAX_ERROR_LENGTH:Z.MAX_STRING_LENGTH);if(typeof e=="number")return Number.isFinite(e)?e:null;if(typeof e=="bigint")return e.toString();if(typeof e=="undefined"||typeof e=="function"||typeof e=="symbol")return yc;if(e instanceof Date)return Number.isNaN(e.getTime())?null:e.toISOString();if(e instanceof Map){let o=Object.create(null),i=0;for(let[s,a]of e){if(t.nodes>=Ac||i>=Z.MAX_COLLECTION_ITEMS){t.droppedItems+=e.size-i;break}let l=id(typeof s=="string"?s:String(s),t,vC),u=ad(a,t,n+1,l);u!==yc&&(o[l]=u),i+=1}return o}if(e instanceof Set){let o=[],i=0;for(let s of e){if(t.nodes>=Ac||i>=Z.MAX_COLLECTION_ITEMS){t.droppedItems+=e.size-i;break}let a=ad(s,t,n+1);o.push(a===yc?null:a),i+=1}return o}if(ArrayBuffer.isView(e)&&!(e instanceof DataView)){let o=e.length,i=[],s=0;for(let a of e){if(t.nodes>=Ac||s>=Z.MAX_COLLECTION_ITEMS){t.droppedItems+=o-s;break}i.push(a),t.nodes+=1,s+=1}return i}if(e instanceof Error)return{name:id(e.name,t,256),message:id(e.message,t,Z.MAX_ERROR_LENGTH)};if(t.seen.has(e))return"[CIRCULAR]";t.seen.add(e);try{if(Array.isArray(e)){let l=[],u=e.slice(0,Z.MAX_COLLECTION_ITEMS);t.droppedItems+=Math.max(0,e.length-u.length);for(let d of u){if(t.nodes>=Ac){t.droppedItems+=1;continue}let f=ad(d,t,n+1);if(t.nodes>=Ac){t.droppedItems+=1;continue}l.push(f===yc?null:f)}return l}let o=Object.create(null),i=Object.keys(e),s=i.slice(0,Z.MAX_OBJECT_KEYS);t.droppedItems+=Math.max(0,i.length-s.length);let a=s.map(l=>{try{let u=e[l];return{key:l,value:u,scalar:u===null||typeof u!="object",ok:!0}}catch{return{key:l,value:void 0,scalar:!0,ok:!1}}});for(let l of[...a.filter(u=>u.scalar),...a.filter(u=>!u.scalar)]){let u=id(l.key,t,vC);if(!l.ok){o[u]=K_;continue}try{let d=ad(l.value,t,n+1,l.key);d!==yc&&(o[u]=d)}catch{o[u]=K_}}return o}finally{t.seen.delete(e)}}function cd(e){return Zs(e).value}function Zs(e){let t={seen:new WeakSet,remainingCharacters:I4,nodes:0,droppedItems:0,truncatedValues:0},n=ad(e,t,0),r=n===yc?null:n;if(t.droppedItems===0&&t.truncatedValues===0)return{value:r};let o=[];return t.droppedItems>0&&o.push(`${t.droppedItems} item(s) dropped`),t.truncatedValues>0&&o.push(`${t.truncatedValues} value(s) truncated`),{value:r,truncation:{droppedItems:t.droppedItems,truncatedValues:t.truncatedValues,note:`partial \u2014 ${o.join(", ")}; this is NOT the whole value. Scope the read with \`path\`/\`depth\` to see the rest.`}}}function fo(e){try{return JSON.stringify(cd(e))}catch{return JSON.stringify(K_)}}var sd,K_,yc,vC,I4,Ac,ur=y(()=>{"use strict";M();sd="[TRUNCATED]",K_="[UNSERIALIZABLE]",yc=Symbol("omit"),vC=256,I4=Math.floor(Z.MAX_MESSAGE_BYTES/4),Ac=Z.MAX_COLLECTION_ITEMS*5});function C4(e){if(e===null)return;let t=/^(.*):(\d+):(\d+)$/.exec(e);if(t===null)return;let n=t[1],r=Number(t[2]);if(!(n===void 0||n.length===0||!Number.isFinite(r)))return{file:n,line:r}}function ld(e){let t=e.closest(`[${Z_}]`);return t!==null?C4(t.getAttribute(Z_)):void 0}function Ah(e,t){return t!==void 0?{file:t.file,line:t.line}:ld(e)}function NC(e){return e.querySelector(`[${Z_}]`)!==null}function yh(e){return e===void 0?void 0:`${e.file}:${String(e.line)}`}var Z_,ud=y(()=>{"use strict";M();Z_=fc});function k4(e){let t=e.type.toLowerCase();return t==="search"?"searchbox":$4.has(t)?"textbox":t==="checkbox"?"checkbox":t==="radio"?"radio":t==="range"?"slider":t==="number"?"spinbutton":t==="submit"||t==="button"||t==="reset"?"button":"textbox"}function z4(e){let t=e.getAttribute("aria-label");if(t!==null&&t.trim().length>0)return!0;let n=e.getAttribute("aria-labelledby");if(n!==null&&n.trim().length>0)return!0;let r=e.getAttribute("title");return r!==null&&r.trim().length>0}function Le(e){var r;let t=e.getAttribute("role");if(t!==null&&t.trim().length>0)return t.trim();switch(e.tagName.toLowerCase()){case"a":return e.hasAttribute("href")?"link":"generic";case"button":return"button";case"input":return k4(e);case"textarea":return"textbox";case"select":return e.multiple?"listbox":"combobox";case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":return"heading";case"ul":case"ol":return"list";case"li":return"listitem";case"nav":return"navigation";case"main":return"main";case"aside":return"complementary";case"dialog":return"dialog";case"img":return"img";case"table":return"table";case"tr":return"row";case"tbody":case"thead":case"tfoot":return"rowgroup";case"td":return e.closest('[role~="grid"], [role~="treegrid"]')!==null?"gridcell":"cell";case"th":{let o=((r=e.getAttribute("scope"))!=null?r:"").toLowerCase();return o==="row"||o==="rowgroup"?"rowheader":"columnheader"}case"option":return"option";case"optgroup":return"group";case"section":return z4(e)?"region":"generic";case"article":return"article";case"fieldset":return"group";case"details":return"group";case"summary":return"button";case"progress":return"progressbar";case"meter":return"meter";case"output":return"status";case"hr":return"separator";case"area":return e.hasAttribute("href")?"link":"generic";case"form":return"form";case"p":return"paragraph";case"header":return"banner";case"footer":return"contentinfo";default:return"generic"}}function Bi(e){return e.replace(/\s+/g," ").trim()}function D4(e){let t=e.getAttribute("aria-labelledby");if(t===null)return null;let n=[];for(let o of t.split(/\s+/)){let i=e.ownerDocument.getElementById(o);i!==null&&n.push(Bi(Ws(i)))}let r=n.join(" ").trim();return r.length>0?r:null}function Ws(e){var o;if(e.nodeType===Node.TEXT_NODE)return(o=e.textContent)!=null?o:"";if(e.nodeType!==Node.ELEMENT_NODE)return"";let t=e;if(t.getAttribute("aria-hidden")==="true")return"";if($_(t)){let i=t.getAttribute("alt");return i===null?"":i}let n="",r=!1;for(let i of t.childNodes){let s=Ws(i);if(s.length===0)continue;let a=Node.ELEMENT_NODE===i.nodeType;n.length>0&&(a||r)&&(n+=" "),n+=s,r=a}return n}function we(e){let t=D4(e);if(t!==null)return t;let n=e.getAttribute("aria-label");if(n!==null&&n.trim().length>0)return n.trim();if($_(e)){let i=e.getAttribute("alt");if(i!==null)return i.trim()}if(He(e)||vn(e)||$r(e)||ed(e)||G0(e)||V0(e)||j0(e)){let i=e.labels;if(i!==null&&i.length>0){let s=[...i].map(a=>Bi(Ws(a))).join(" ").trim();if(s.length>0)return s}}if(e.tagName.toLowerCase()==="fieldset"){let i=[...e.children].find(s=>s.tagName.toLowerCase()==="legend");if(i!==void 0){let s=Bi(Ws(i));if(s.length>0)return s}}if(e.tagName.toLowerCase()==="table"){let i=[...e.children].find(s=>s.tagName.toLowerCase()==="caption");if(i!==void 0){let s=Bi(Ws(i));if(s.length>0)return s}}if(e.tagName.toLowerCase()==="figure"){let i=[...e.children].find(s=>s.tagName.toLowerCase()==="figcaption");if(i!==void 0){let s=Bi(Ws(i));if(s.length>0)return s}}if(He(e)||vn(e)||$r(e)){if(He(e)){let i=e.type.toLowerCase();if(i==="submit"||i==="button"||i==="reset"){let s=Bi(e.value);if(s.length>0)return s}}if(He(e)||vn(e)){let i=e.getAttribute("placeholder");if(i!==null&&i.trim().length>0)return i.trim()}}if(L4.has(Le(e))){let i=Bi(Ws(e));if(i.length>0)return i}let o=e.getAttribute("title");return o!==null&&o.trim().length>0?o.trim():""}function wh(e,t){let n=e.getAttribute(t);if(n!==null)return n==="true"}function Jo(e,t=Je(e)){let n=[Se.PRESENT];n.push(t?Se.VISIBLE:Se.HIDDEN);let r=e.matches(":disabled")||wh(e,"aria-disabled")===!0;return n.push(r?Se.DISABLED:Se.ENABLED),(He(e)&&(e.type==="checkbox"||e.type==="radio")&&e.checked||wh(e,"aria-checked")===!0)&&n.push(Se.CHECKED),(wh(e,"aria-expanded")===!0||P4(e))&&n.push(Se.EXPANDED),wh(e,"aria-pressed")===!0&&n.push(Se.PRESSED),e.ownerDocument.activeElement===e&&n.push(Se.FOCUSED),n}function P4(e){let t=e.parentElement;return mh!==e.localName||t===null||D_!==t.localName?!1:Array.from(t.children).find(r=>mh===r.localName)===e&&t.hasAttribute(P_)}function pn(e){var o,i,s,a,l;if(!He(e)&&!vn(e)&&!$r(e))return!1;let t=(o=e.getAttribute("autocomplete"))!=null?o:"",n=[(i=e.getAttribute("name"))!=null?i:"",e.id,(s=Ne(e))!=null?s:"",(a=e.getAttribute(Us))!=null?a:"",(l=e.getAttribute("aria-label"))!=null?l:""],r=M4.test(t);return He(e)&&e.type.toLowerCase()==="password"||r||n.some(St)}function W_(e){if(He(e)||vn(e)||$r(e))return pn(e)?e.value===""?"":ve:e.value;let t=e.getAttribute("aria-valuenow");return t!=null?t:void 0}function U4(e){var n;let t=Bi((n=e.textContent)!=null?n:"");return t.length>RC?`${t.slice(0,RC)}\u2026`:t}function ho(e,t){let n=W_(e),r=U4(e),o=we(e),i=Je(e,t),s={ref:re.refFor(e),role:Le(e),name:o,states:Jo(e,i),visible:i};n!==void 0&&n.length>0&&(s.value=n),r.length>0&&r!==o&&(s.text=r);let a=yh(ld(e));if(a!==void 0&&(s.source=a),e.querySelector("path, polyline, polygon")!==null){let l=xh(e).findings;l.length>0&&(s.chart=l)}return s}var L4,$4,M4,RC,Et=y(()=>{"use strict";Ot();M();dn();gt();j_();ur();ud();uo();L4=new Set(["button","link","heading","option","listitem","cell","checkbox","columnheader","radio","row","rowheader","tab","tooltip","menuitem","menuitemcheckbox","menuitemradio","treeitem","gridcell","switch","status","alert"]),$4=new Set(["text","email","tel","url","password",""]);M4=/\b(cc-|current-password|new-password|one-time-code)/i;RC=80});function HC(e){Nc.some(t=>t.name===e.name)||Nc.push(e)}function dr(e){for(let t of Nc){let n;try{n=t.identify(e)}catch{continue}if(n!=null)return n}return null}function Nh(e){for(let t of Nc){if(t.readState===void 0)continue;let n=t.readState(e);if(n!==void 0)return n}}function Rh(e){for(let t of Nc)if(t.hasHoverHandlers!==void 0&&t.hasHoverHandlers(e))return!0;return!1}function hd(){return Nc.map(e=>e.name)}var J_,UC,Nc,Qo=y(()=>{"use strict";J_=globalThis,Nc=(UC=J_.__reticleAdapters)!=null?UC:J_.__reticleAdapters=[]});function Oh(){return cr(location.href)}function Ih(e=!0){return cr(`${location.pathname}${location.search}${e?location.hash:""}`)}var md=y(()=>{"use strict";M()});function lL(e){var o;let t=[],n=new Set,r;try{r=e.querySelectorAll(Vn())}catch{return t}for(let i=0;i<r.length&&t.length<Aj;i+=1){let s=(o=r[i])==null?void 0:o.getAttribute(Fi());if(s==null)continue;let a=s.trim();a.length===0||n.has(a)||a.startsWith(yj)||(n.add(a),t.push(a))}return t}var Aj,yj,uL=y(()=>{"use strict";Ot();Aj=200,yj="reticle-"});var nS,dL,rS,zr,gd=y(()=>{"use strict";nS=globalThis,rS=typeof((dL=nS.console)==null?void 0:dL.warn)=="function"?nS.console.warn.bind(nS.console):null,zr=(...e)=>{rS==null||rS(...e)}});function EL(e){return oS.add(e),()=>oS.delete(e)}function wj(e){if(e===null||typeof e!="object"&&typeof e!="function")return!1;let t=e;return typeof t.getState=="function"&&typeof t.subscribe=="function"}function bL(e,t,n){if(Rj(e,t),wj(t)){let r=()=>t.getState(),o=i=>t.subscribe(i);Oc.set(e,r),$h.set(e,o),pL(e,r,o);return}if(typeof t!="function"){let r=typeof t=="object"&&t!==null&&"subscribe"in t;zr(`[reticle] store "${e}" is neither a getter function nor a {getState, subscribe} store`+(r?" \u2014 it has subscribe but no getState. Wrap it with an adapter or add getState.":"."));return}if(Oc.set(e,t),n!==void 0){$h.set(e,n),pL(e,t,n);return}Nj(e)}function pL(e,t,n){for(let r of oS)try{r([e,t,n])}catch{}}function _L(e){Oc.delete(e),$h.delete(e)}function Vi(){return[...Oc.keys()]}function SL(){let e=[];for(let[t,n]of $h){let r=Oc.get(t);r!==void 0&&e.push([t,r,n])}return e}function sS(e){let t={};for(let[n,r]of Oc)if(!(e!==void 0&&n!==e))try{t[n]=r()}catch(o){t[n]={__error:o instanceof Error?o.message:String(o)}}return t}function TL(e){return Ed(e).stores}function Ed(e){let t={},n={};for(let[r,o]of Object.entries(sS(e))){let i=Zs(o);t[r]=i.value,i.truncation!==void 0&&(n[r]=i.truncation)}return Object.keys(n).length>0?{stores:t,truncation:n}:{stores:t}}function Nj(e){vj.has(e)||fL.has(e)||(fL.add(e),zr(`[reticle] store "${e}" was registered without a subscribe function. It can be READ, but its changes are invisible: no STATE_CHANGE events, no state diffs in causal summaries, and a state predicate will never see it update. Pass the store object (or a subscribe callback) to fix.`))}function kh(e,t){xL.set(e,t)}function Rj(e,t){if(t===null||typeof t!="object"&&typeof t!="function")return;iS.set(t,e);let n=xL.get(t);n!==void 0&&iS.set(n,e)}function AL(e){if(!(e===null||typeof e!="object"&&typeof e!="function"))return iS.get(e)}var ei,hL,Oc,mL,$h,gL,oS,fL,vj,iS,xL,Ys=y(()=>{"use strict";M();gd();ur();ei=globalThis,Oc=(hL=ei.__reticleStores)!=null?hL:ei.__reticleStores=new Map,$h=(mL=ei.__reticleStoreSubs)!=null?mL:ei.__reticleStoreSubs=new Map,oS=(gL=ei.__reticleStoreListeners)!=null?gL:ei.__reticleStoreListeners=new Set;fL=new Set,vj=new Set([Ff]);iS=new WeakMap,xL=new WeakMap});function wL(){return typeof document=="undefined"?[]:lL(document)}function vL(){return Vi().filter(e=>Ff!==e)}function Dh(e,t){let n=[...e];for(let r of t)n.includes(r)||n.push(r);return n}function Oj(){return{testids:[],signals:[],stores:[],flows:[]}}function cS(e,t){if(t!==void 0)for(let n of t)e.includes(n)||e.push(n)}function Ph(e){zh=e}function Ic(e){if(cS(Nn.testids,e.testids),cS(Nn.signals,e.signals),cS(Nn.stores,e.stores),e.flows!==void 0)for(let t of e.flows){let n=Nn.flows.find(r=>r.name===t.name);n===void 0?Nn.flows.push({name:t.name,steps:[...t.steps]}):n.steps=[...t.steps]}zh==null||zh()}function ji(){return{testids:Dh(Nn.testids,wL()),signals:[...Nn.signals],stores:Dh(Nn.stores,vL()),flows:Nn.flows.map(e=>({name:e.name,steps:[...e.steps]})),...dC()?{presenterExposed:!0}:{}}}function NL(){return[...Nn.testids]}function Mh(){return Nn.signals.length>0||Nn.flows.length>0||Dh(Nn.testids,wL()).length>0||Dh(Nn.stores,vL()).length>0}var aS,yL,Nn,zh,Ki=y(()=>{"use strict";M();nt();uL();Ys();aS=globalThis;Nn=(yL=aS.__reticleCapabilities)!=null?yL:aS.__reticleCapabilities=Oj()});function jh(){return mS>0}function rt(e){mS+=1;try{return e()}finally{mS-=1}}var mS,Lc=y(()=>{"use strict";mS=0});function e$(e){if(!(typeof e!="number"||!Number.isFinite(e)))return Math.max(0,Math.min(e,SS))}var fr,WL,_S,YL,qL,XL,Zh,ue,Re,Wh,SS,JL,mo,QL,dt=y(()=>{"use strict";fr=globalThis,WL=typeof fr.setTimeout=="function"?fr.setTimeout.bind(fr):null,_S=typeof fr.clearTimeout=="function"?fr.clearTimeout.bind(fr):null,YL=typeof fr.requestAnimationFrame=="function"?fr.requestAnimationFrame.bind(fr):null,XL=typeof((qL=fr.performance)==null?void 0:qL.now)=="function"?fr.performance.now.bind(fr.performance):null,Zh=()=>XL?XL():0,ue=(e,t=0)=>WL?WL(e,t):0,Re=e=>{_S==null||_S(e)},Wh=(e,t)=>{let n=!1,r=0,o=()=>{n||(e(),!n&&(r=ue(o,t)))};return r=ue(o,t),()=>{n=!0,Re(r)}},SS=200,JL=(e=SS)=>new Promise(t=>{let n=!1,r=i=>{n||(n=!0,Re(o),t({settled:i}))},o=ue(()=>r(!1),e);YL?YL(()=>r(!0)):ue(()=>r(!0),0)}),mo=()=>JL().then(()=>{}),QL=async(e=SS)=>(await Promise.resolve(),JL(e))});var ck={};Ya(ck,{MASK:()=>sk,cloneForRender:()=>ak,renderPage:()=>u3});function o3(e){var t;return e instanceof HTMLInputElement&&e.type==="password"?!0:[e.name,e.id,(t=e.getAttribute("autocomplete"))!=null?t:""].some(n=>n.length>0&&St(n))}function i3(e,t){if(e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement){let n=o3(e)&&e.value.length>0?sk:e.value;e instanceof HTMLTextAreaElement?t.textContent=n:t.setAttribute("value",n)}e instanceof HTMLInputElement&&(e.checked?t.setAttribute("checked",""):t.removeAttribute("checked")),e instanceof HTMLOptionElement&&(e.selected?t.setAttribute("selected",""):t.removeAttribute("selected"))}function s3(e){var r;let t=[...Array.from(e.styleSheets),...(r=e.adoptedStyleSheets)!=null?r:[]],n=[];for(let o of t)try{for(let i of Array.from(o.cssRules))n.push(i.cssText)}catch{}return n.join(`
58
- `)}function ak(e){var a;let t=e.documentElement,n=t.cloneNode(!0),r=t.querySelectorAll("*"),o=n.querySelectorAll("*");r.forEach((l,u)=>{let d=o[u];d!==void 0&&i3(l,d)});let i=[Ui,"script","noscript",'link[rel~="stylesheet"]',"style"];n.querySelectorAll(i.join(",")).forEach(l=>l.remove());let s=e.createElement("style");return s.textContent=s3(e),((a=n.querySelector("head"))!=null?a:n).append(s),n}function a3(e){let t=e.defaultView;for(let n of[e.body,e.documentElement]){if(t===null||n===null)continue;let r=t.getComputedStyle(n).backgroundColor;if(r.length>0&&r!=="transparent"&&r!=="rgba(0, 0, 0, 0)")return r}return t3}function c3(e){return new Promise((t,n)=>{let r=new Image,o=setTimeout(()=>n(new Error("the page did not render in time")),QK);r.onload=()=>{clearTimeout(o),t(r)},r.onerror=()=>{clearTimeout(o),n(new Error("the page could not be drawn as an image"))},r.src=e})}function l3(e){let t=[];for(let n=0;n<e.length;n+=ik)t.push(e.slice(n,n+ik));return t}async function u3(){try{let e=Math.max(1,window.innerWidth),t=Math.max(1,window.innerHeight),n=ak(document);n.style.transform=`translate(${String(-window.scrollX)}px, ${String(-window.scrollY)}px)`;let r=new XMLSerializer().serializeToString(n),o=`<svg xmlns="${e3}" width="${String(e)}" height="${String(t)}"><foreignObject x="0" y="0" width="100%" height="100%">${r}</foreignObject></svg>`,i=await c3(`data:image/svg+xml;charset=utf-8,${encodeURIComponent(o)}`),s=a3(document),a=Math.min(1,Ob.MAX_SIDE_PX/Math.max(e,t));for(let l=0;l<JK;l+=1,a*=qK){let u=document.createElement("canvas");u.width=Math.max(1,Math.round(e*a)),u.height=Math.max(1,Math.round(t*a));let d=u.getContext("2d");if(d===null)return{ok:!1,reason:"this page has no 2D canvas to draw into"};d.fillStyle=s,d.fillRect(0,0,u.width,u.height),d.drawImage(i,0,0,u.width,u.height);let f=u.toDataURL(n3,Ob.JPEG_QUALITY).replace(r3,"");if(f.length<=XK)return{ok:!0,width:u.width,height:u.height,chunks:l3(f)}}return{ok:!1,reason:"the rendered page was too large to send, even scaled down"}}catch(e){return{ok:!1,reason:e instanceof Error?e.message:String(e)}}}var sk,XK,ik,qK,JK,QK,e3,t3,n3,r3,lk=y(()=>{"use strict";M();nt();sk="\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022",XK=24e4,ik=6e4,qK=.75,JK=4,QK=5e3,e3="http://www.w3.org/2000/svg",t3="#ffffff",n3="image/jpeg",r3=/^data:[^,]*,/});function pm(e,t){return`${C0}${e}. ${String(t)} attempts, all failed. That is everything the page can see: from inside the browser it cannot tell a daemon that is not there from one it is not allowed to reach, so this is not evidence about the daemon. What answers it: run \`npx @reticlehq/server status\` to see whether one is listening and on which port. If your app runs in a container, devcontainer or WSL, the daemon is on a different host, so point the page at it: RETICLE_PORT or reticle({ port }) with the Vite plugin, reticle.connect({ url }) by hand. An https page cannot open a ws:// socket. Still retrying\u2026`}var bk,MS=y(()=>{"use strict";M();bk="Can't reach Reticle from this page. Run reticle status to check, or reticle serve to start it."});var Ge,Kn,hn,JS=y(()=>{"use strict";Ge={READ:"read",ACT:"act",NARRATION:"narration",HUMAN:"human"},Kn={PASS:"pass",FAIL:"fail"},hn={AGENT:"agent",HARNESS:"harness"}});function kd(e){switch(e){case D.CLICK:case D.DBLCLICK:return"Clicking";case D.FILL:case D.TYPE:return"Typing into";case D.HOVER:return"Hovering";case D.SELECT:return"Selecting";case D.SUBMIT:return"Submitting";case D.CHECK:case D.UNCHECK:return"Toggling";case D.UPLOAD:return"Uploading to";case D.DRAG:return"Dragging";default:return e}}var QS=y(()=>{"use strict";M()});function si(e){return typeof e=="string"&&e.length>0}function yZ(e){var n;return`${(n=e.file.split("/").pop())!=null?n:e.file}:${e.line}`}function qz(e){var t;if(si(e.testid))return{strategy:Mr.TESTID,value:e.testid,stable:!0};if(si(e.component)&&e.source!==void 0)return{strategy:Mr.COMPONENT,value:`${e.component}@${yZ(e.source)}`,stable:!0};if(si(e.component)&&(si(e.role)||si(e.name))){let n=si(e.name)?e.name:e.role;return{strategy:Mr.COMPONENT,value:`${e.component}[${n!=null?n:""}]`,stable:!0}}if(si(e.role)&&si(e.name))return{strategy:Mr.ROLE,value:`${e.role}:${e.name}`,stable:!1};if(si(e.role)){let n=e.nth!==void 0?`#${e.nth}`:"";return{strategy:Mr.ROLE,value:`${e.role}${n}`,stable:!1}}return{strategy:Mr.POSITION,value:`el#${(t=e.nth)!=null?t:0}`,stable:!1}}var Mr,Jz=y(()=>{"use strict";Mr={TESTID:"testid",COMPONENT:"component",ROLE:"role",POSITION:"position"}});function vZ(e,t,n){return n.length>0?t.length>0?`${t} "${n}"`:`"${n}"`:t.length>0?t:e.tagName.toLowerCase()}function Ud(e){var d;let t=(d=Ne(e))!=null?d:void 0,n=dr(e),r=n==null?void 0:n.componentStack[0],o=Ah(e,n==null?void 0:n.source),i=Le(e),s=we(e),a={};t!==void 0&&(a.testid=t),r!==void 0&&(a.component=r),o!==void 0&&(a.source=o),i.length>0&&(a.role=i),s.length>0&&(a.name=s);let l=qz(a),u={anchor:l.value,strategy:wZ[l.strategy],label:vZ(e,i,s)};return o!==void 0&&(u.source=o),u}var wZ,oT=y(()=>{"use strict";Ot();M();Jz();Et();Qo();ud();wZ={[Mr.TESTID]:Fs.TESTID,[Mr.COMPONENT]:Fs.COMPONENT,[Mr.ROLE]:Fs.ROLE,[Mr.POSITION]:Fs.POSITION}});function Qz(e){return`${String(e)} ${e===1?"note":"notes"} on this page`}function Am(e,t){let n=e.length,r=`I marked ${String(n)} ${n===1?"issue":"issues"} on ${t} with Reticle. Fix each one, then verify it in the running app:`,o=e.map((i,s)=>{let a=i.source===void 0?i.anchor:`${i.anchor}, ${i.source}`;return`${String(s+1)}. ${i.note}
57
+ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let d of e.seen.entries()){let f=d[1];if(t===d[0]){i(d);continue}if(e.external){let h=(l=e.external.registry.get(d[0]))==null?void 0:l.id;if(t!==d[0]&&h){i(d);continue}}if((u=e.metadataRegistry.get(d[0]))==null?void 0:u.id){i(d);continue}if(f.cycle){i(d);continue}f.count>1&&e.reused==="ref"&&i(d)}e.external&&(e.sharedDefsExtractedFor=e.external)}function cN(e){let t=e.anyOf;if(!Array.isArray(t)||t.length===0||e.type!==void 0)return;let n=[];for(let r of t){if(!r||typeof r!="object")return;cN(r);let o=Object.keys(r);if(o.length!==1||o[0]!=="type")return;let i=r.type;for(let s of Array.isArray(i)?i:[i]){if(typeof s!="string")return;n.includes(s)||n.push(s)}}delete e.anyOf,e.type=n.length===1?n[0]:n}function aN(e){let t=e.additionalProperties;return t===void 0||t===!1||typeof t!="object"||t===null?null:Object.keys(t).length?t:null}function qE(e){var i,s,a,l;let t=[];for(let u of e){if(typeof u!="object"||u.type!=="object")return null;for(let d in u)if(!lN.has(d))return null;t.push(u)}let n={},r=new Set;for(let u of t){for(let d in u.properties){if(Object.prototype.hasOwnProperty.call(n,d))continue;let f=[];for(let h of t){let E=(s=(i=h.properties)==null?void 0:i[d])!=null?s:aN(h);E!=null&&(f.some(S=>JSON.stringify(S)===JSON.stringify(E))||f.push(E))}let m=f.length===1?f[0]:(a=qE(f))!=null?a:{allOf:f};zn(n,d,m)}for(let d of(l=u.required)!=null?l:[])r.add(d)}let o={type:"object",properties:n};if(r.size&&(o.required=[...r]),t.every(u=>u.additionalProperties===!1))o.additionalProperties=!1;else{let u=[];for(let d of t){let f=aN(d);f&&!u.some(m=>JSON.stringify(m)===JSON.stringify(f))&&u.push(f)}u.length===1?o.additionalProperties=u[0]:u.length>1&&(o.additionalProperties={allOf:u})}return o}function QU(e){let t=e.allOf;if(!Array.isArray(t)||t.length<2)return;for(let o of lN)if(o in e)return;let n=t.filter(o=>sN.some(i=>Array.isArray(o[i]))),r=null;if(!n.length)r=qE(t);else{let o=n[0],i=sN.find(l=>Array.isArray(o[l]));if(Object.keys(o).length!==1)return;let s=t.filter(l=>l!==o),a=o[i].map(l=>qE([...s,l]));if(a.some(l=>!l))return;r={[i]:a}}r&&(delete e.allOf,Ru(e,r))}function eb(e,t){var a,l,u,d,f,m,h,E;let n=e.seen.get(t);if(!n)throw new Error("Unprocessed schema. This is a bug in Zod.");let r=S=>{var G,V,W;let A=e.seen.get(S);if(A.ref===null)return;let w=(G=A.def)!=null?G:A.schema,N={...w},O=A.ref;if(A.ref=null,O){r(O);let K=e.seen.get(O),J=K.schema;if(J.$ref&&(e.target==="draft-07"||e.target==="draft-04"||e.target==="openapi-3.0")?(w.allOf=(V=w.allOf)!=null?V:[],w.allOf.push(J)):Ru(w,J),Ru(w,N),S._zod.parent===O)for(let ge in w)ge==="$ref"||ge==="allOf"||ge in N||delete w[ge];if(J.$ref&&K.def)for(let ge in w)ge==="$ref"||ge==="allOf"||ge in K.def&&JSON.stringify(w[ge])===JSON.stringify(K.def[ge])&&delete w[ge]}let k=S._zod.parent;if(k&&k!==O){r(k);let K=e.seen.get(k);if(K!=null&&K.schema.$ref&&(w.$ref=K.schema.$ref,K.def))for(let J in w)J==="$ref"||J==="allOf"||J in K.def&&JSON.stringify(w[J])===JSON.stringify(K.def[J])&&delete w[J]}e.override({zodSchema:S,jsonSchema:w,path:(W=A.path)!=null?W:[]})};if(!e.external||e.sharedEmitDoneFor!==e.external){for(let S of[...e.seen.entries()].reverse())r(S[0]);if(e.target!=="openapi-3.0")for(let S of e.seen.entries())cN((a=S[1].def)!=null?a:S[1].schema);for(let S of e.deferred)S();if(e.intersections.length){let S=new Map;for(let A of e.seen.values())for(let w of[A.schema,A.def]){let N=w==null?void 0:w.allOf;if(!Array.isArray(N))continue;let O=S.get(N);O?O.push(w):S.set(N,[w])}for(let A of e.intersections)for(let w of(l=S.get(A))!=null?l:[])QU(w)}}let o={};if(e.target==="draft-2020-12"?o.$schema="https://json-schema.org/draft/2020-12/schema":e.target==="draft-07"?o.$schema="http://json-schema.org/draft-07/schema#":e.target==="draft-04"?o.$schema="http://json-schema.org/draft-04/schema#":e.target,(u=e.external)!=null&&u.uri){let S=(d=e.external.registry.get(t))==null?void 0:d.id;if(!S)throw new Error("Schema is missing an `id` property");o.$id=e.external.uri(S)}Ru(o,n.defId?n.schema:(f=n.def)!=null?f:n.schema);let i=(m=e.metadataRegistry.get(t))==null?void 0:m.id;i!==void 0&&o.id===i&&delete o.id;let s=(E=(h=e.external)==null?void 0:h.defs)!=null?E:{};if(!e.external||e.sharedEmitDoneFor!==e.external)for(let S of e.seen.entries()){let A=S[1];A.def&&A.defId&&(A.def.id===A.defId&&delete A.def.id,zn(s,A.defId,A.def))}e.external&&(e.sharedEmitDoneFor=e.external),e.external||Object.keys(s).length>0&&(e.target==="draft-2020-12"?o.$defs=s:o.definitions=s);try{let S=JSON.parse(JSON.stringify(o));return Object.defineProperty(S,"~standard",{value:{...t["~standard"],jsonSchema:{input:Ou(t,"input",e.processors),output:Ou(t,"output",e.processors)}},enumerable:!1,writable:!1}),S}catch{throw new Error("Error converting schema to JSON.")}}function rn(e,t){let n=t!=null?t:{seen:new Set};if(n.seen.has(e))return!1;n.seen.add(e);let r=e._zod.def;if(r.type==="transform")return!0;if(r.type==="array")return rn(r.element,n);if(r.type==="set")return rn(r.valueType,n);if(r.type==="lazy")return rn(r.getter(),n);if(r.type==="promise"||r.type==="optional"||r.type==="nonoptional"||r.type==="nullable"||r.type==="readonly"||r.type==="default"||r.type==="prefault"||r.type==="catch")return rn(r.innerType,n);if(r.type==="intersection")return rn(r.left,n)||rn(r.right,n);if(r.type==="record"||r.type==="map")return rn(r.keyType,n)||rn(r.valueType,n);if(r.type==="pipe")return e._zod.traits.has("$ZodCodec")?!0:rn(r.in,n)||rn(r.out,n);if(r.type==="object"){for(let o in r.shape)if(rn(r.shape[o],n))return!0;return!1}if(r.type==="union"){for(let o of r.options)if(rn(o,n))return!0;return!1}if(r.type==="tuple"){for(let o of r.items)if(rn(o,n))return!0;return!!(r.rest&&rn(r.rest,n))}return!1}var lN,sN,uN,Ou,kf=y(()=>{UE();Sn();lN=new Set(["type","properties","required","additionalProperties"]),sN=["oneOf","anyOf"];uN=(e,t={})=>n=>{let r=JE({...n,processors:t});return Ve(e,r),QE(r,e),eb(r,e)},Ou=(e,t,n={})=>r=>{let{libraryOptions:o,target:i}=r!=null?r:{},s=JE({...o!=null?o:{},target:i,io:t,processors:n});return Ve(e,s),QE(s,e),eb(s,e)}});function Mn(e){var i,s,a,l,u;let t={},n=e._zod.def,r=e._zod.traits.has("$ZodCheck")?[e,...(i=n.checks)!=null?i:[]]:(s=n.checks)!=null?s:[];for(let d of r)(a=tb[d._zod.def.check])==null||a.call(tb,t,d._zod.def);let o=e._zod.bag;o.minimum!==void 0&&sc(t,"minimum",o.minimum),o.exclusiveMinimum!==void 0&&sc(t,"exclusiveMinimum",o.exclusiveMinimum),o.maximum!==void 0&&ac(t,"maximum",o.maximum),o.exclusiveMaximum!==void 0&&ac(t,"exclusiveMaximum",o.exclusiveMaximum),o.multipleOf!==void 0&&mN(t,o.multipleOf),o.format!==void 0&&((l=t.format)!=null||(t.format=o.format),o.format.includes("int")&&(t.isInt=!0)),o.mime&&EN(t,o.mime);for(let d of(u=o.patterns)!=null?u:[])gN(t,d);return t}function Iu(e){let t=e._zod.def;return t.type==="pipe"&&t.in._zod.traits.has("$ZodTransform")?Iu(t.out):t.type==="catch"?Iu(t.innerType):e._zod.optin}function nb(e,t,n){var E,S;if(t.$ref){if(n.has(t))return t;n.add(t);let A=(E=e.get(t))==null?void 0:E.def;if(!A)return t;let w=nb(e,A,n);return w===A?t:w}for(let A of["anyOf","oneOf"]){let w=t[A];if(!Array.isArray(w))continue;let N=w.map(O=>nb(e,O,n));N.some((O,k)=>O!==w[k])&&(t={...t,[A]:N})}let r=Array.isArray(t.type)?t.type:[t.type],o=!r.includes("string")&&r.some(A=>A==="number"||A==="integer"),i=(S=t.enum)!=null?S:t.const!==void 0?[t.const]:void 0;if(!o&&!(i!=null&&i.some(A=>typeof A=="number")))return t;let{minimum:s,maximum:a,exclusiveMinimum:l,exclusiveMaximum:u,multipleOf:d,format:f,id:m,...h}=t;return h.enum?h.enum=h.enum.map(A=>typeof A=="number"?String(A):A):typeof h.const=="number"&&(h.const=String(h.const)),o&&(h.type="string",i||(h.pattern=(r.includes("number")?xu:TE).source)),h}function nH(e){var r,o,i;let t=new Map;for(let s of e.seen.values())s.def&&!t.has(s.schema)&&t.set(s.schema,s);let n=new Map;for(let s of(r=rb.get(e))!=null?r:[]){let a=e.seen.get(s),l=(i=(o=a==null?void 0:a.def)!=null?o:a==null?void 0:a.schema)==null?void 0:i.propertyNames;if(!l||l===!0||n.has(l))continue;let u=nb(t,l,new Set);u!==l&&n.set(l,u)}if(n.size)for(let s of e.seen.values())for(let a of[s.schema,s.def]){let l=a&&n.get(a.propertyNames);l&&(a.propertyNames=l)}}function UN(e,t,n,r,o){let i=!1,s=JSON.stringify(e,(a,l)=>typeof l!="bigint"?l:(i=!0,null));return i?(so(t,n,r,o,"BigInt defaults cannot be represented in JSON Schema"),ob):JSON.parse(s)}var sc,ac,dN,mN,gN,EN,bN,pN,fN,hN,tb,eH,tH,_N,SN,TN,xN,AN,yN,wN,vN,NN,RN,ON,IN,CN,LN,$N,kN,zN,rb,DN,PN,MN,ob,HN,FN,BN,GN,VN,ib,jN,KN=y(()=>{gf();kE();kf();Sn();sc=(e,t,n)=>{(e[t]===void 0||n>e[t])&&(e[t]=n)},ac=(e,t,n)=>{(e[t]===void 0||n<e[t])&&(e[t]=n)},dN=(e,t)=>{sc(e,"minimum",t),ac(e,"maximum",t)},mN=(e,t)=>{var n;(n=e.multipleOf)!=null||(e.multipleOf=[]),e.multipleOf.includes(t)||e.multipleOf.push(t)},gN=(e,t)=>{var n;(n=e.patterns)!=null||(e.patterns=new Set),e.patterns.add(t)},EN=(e,t)=>{e.mime=e.mime?e.mime.filter(n=>t.includes(n)):[...t]},bN=(e,t)=>{e.format=t,t.includes("int")&&(e.isInt=!0)},pN=(e,t)=>sc(e,"minimum",t.minimum),fN=(e,t)=>ac(e,"maximum",t.maximum),hN=e=>(t,n)=>{bN(t,n.format);let[r,o]=e[n.format];sc(t,"minimum",r),ac(t,"maximum",o)},tb={greater_than:(e,t)=>sc(e,t.inclusive?"minimum":"exclusiveMinimum",t.value),less_than:(e,t)=>ac(e,t.inclusive?"maximum":"exclusiveMaximum",t.value),multiple_of:(e,t)=>mN(e,t.value),number_format:hN(bu),bigint_format:hN(sf),min_length:pN,max_length:fN,length_equals:(e,t)=>dN(e,t.length),min_size:pN,max_size:fN,size_equals:(e,t)=>dN(e,t.size),string_format:(e,t)=>{bN(e,t.format),t.pattern&&gN(e,t.pattern),(t.format==="base64"||t.format==="base64url")&&(e.contentEncoding=t.format),(t.local||t.precision===-1)&&(e.laxFormat=!0)},mime_type:(e,t)=>EN(e,t.mime)};eH={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},tH=new Map([[OE,xy],[yf,Ay]]),_N=e=>{var t;return(t=tH.get(e))!=null?t:e},SN=(e,t,n,r)=>{var f;let o=n;o.type="string";let{minimum:i,maximum:s,format:a,patterns:l,contentEncoding:u,laxFormat:d}=Mn(e);if(typeof i=="number"&&(o.minLength=i),typeof s=="number"&&(o.maxLength=s),a&&(o.format=(f=eH[a])!=null?f:a,o.format===""&&delete o.format,(a==="time"||d)&&delete o.format),u&&(o.contentEncoding=u),l&&l.size>0){let m=[...l].map(_N);m.length===1?o.pattern=m[0].source:m.length>1&&(o.allOf=[...m.map(h=>({...t.target==="draft-07"||t.target==="draft-04"||t.target==="openapi-3.0"?{type:"string"}:{},pattern:h.source}))])}},TN=(e,t,n,r)=>{var E;let o=n,{minimum:i,maximum:s,multipleOf:a,exclusiveMaximum:l,exclusiveMinimum:u,isInt:d}=Mn(e);o.type=d?"integer":"number";let f=typeof u=="number"&&u>=(i!=null?i:Number.NEGATIVE_INFINITY),m=typeof l=="number"&&l<=(s!=null?s:Number.POSITIVE_INFINITY),h=t.target==="draft-04"||t.target==="openapi-3.0";if(f?h?(o.minimum=u,o.exclusiveMinimum=!0):o.exclusiveMinimum=u:typeof i=="number"&&(o.minimum=i),m?h?(o.maximum=l,o.exclusiveMaximum=!0):o.exclusiveMaximum=l:typeof s=="number"&&(o.maximum=s),a){let S=new Set;for(let N of a)Number.isFinite(N)&&N!==0?S.add(Math.abs(N)):so(e,t,o,r,`A multipleOf divisor of ${N} cannot be represented in JSON Schema`);let[A,...w]=S;A!==void 0&&(o.multipleOf=A),w.length&&(o.allOf=[...(E=o.allOf)!=null?E:[],...w.map(N=>({multipleOf:N}))])}},xN=(e,t,n,r)=>{n.type="boolean"},AN=(e,t,n,r)=>{t.target==="openapi-3.0"?(n.type="string",n.nullable=!0,n.enum=[null]):n.type="null"},yN=(e,t,n,r)=>{so(e,t,n,r,"Undefined cannot be represented in JSON Schema")},wN=(e,t,n,r)=>{n.not={}},vN=(e,t,n,r)=>{},NN=(e,t,n,r)=>{let o=e._zod.def,i=Qa(o.entries);if(i.length===0){n.not={};return}i.every(s=>typeof s=="number")&&(n.type="number"),i.every(s=>typeof s=="string")&&(n.type="string"),n.enum=i},RN=(e,t,n,r)=>{let o=e._zod.def;if(o.values.length===0){n.not={};return}let i=[];for(let s of o.values)if(s===void 0){if(so(e,t,n,r,"Literal `undefined` cannot be represented in JSON Schema"))return}else if(typeof s=="bigint"){if(so(e,t,n,r,"BigInt literals cannot be represented in JSON Schema"))return;i.push(Number(s))}else i.push(s);if(i.length!==0)if(i.length===1){let s=i[0];n.type=s===null?"null":typeof s,t.target==="draft-04"||t.target==="openapi-3.0"?n.enum=[s]:n.const=s}else i.every(s=>typeof s=="number")&&(n.type="number"),i.every(s=>typeof s=="string")&&(n.type="string"),i.every(s=>typeof s=="boolean")&&(n.type="boolean"),i.every(s=>s===null)&&(n.type="null"),n.enum=i},ON=(e,t,n,r)=>{so(e,t,n,r,"Custom types cannot be represented in JSON Schema")},IN=(e,t,n,r)=>{so(e,t,n,r,"Transforms cannot be represented in JSON Schema")},CN=(e,t,n,r)=>{let o=n,i=e._zod.def,{minimum:s,maximum:a}=Mn(e);typeof s=="number"&&(o.minItems=s),typeof a=="number"&&(o.maxItems=a),o.type="array",o.items=Ve(i.element,t,{...r,path:[...r.path,"items"]})};LN=(e,t,n,r)=>{var u;let o=n,i=e._zod.def,s=i.shape;if(Object.getOwnPropertySymbols(s).length&&so(e,t,o,r,"Symbol keys cannot be represented in JSON Schema"))return;o.type="object",o.properties={};for(let d in s)zn(o.properties,d,Ve(s[d],t,{...r,path:[...r.path,"properties",d]}));let l=[];for(let d of Object.keys(s)){let f=i.shape[d];(t.io==="input"?Iu(f)===void 0:f._zod.optout===void 0)&&l.push(d)}l.length>0&&(o.required=l),((u=i.catchall)==null?void 0:u._zod.def.type)==="never"?o.additionalProperties=!1:i.catchall?i.catchall&&(o.additionalProperties=Ve(i.catchall,t,{...r,path:[...r.path,"additionalProperties"]})):t.io==="output"&&(o.additionalProperties=!1)},$N=(e,t,n,r)=>{let o=e._zod.def,i=o.inclusive===!1,s=o.options.map((a,l)=>Ve(a,t,{...r,path:[...r.path,i?"oneOf":"anyOf",l]}));i?n.oneOf=s:n.anyOf=s},kN=(e,t,n,r)=>{let o=e._zod.def,i=Ve(o.left,t,{...r,path:[...r.path,"allOf",0]}),s=Ve(o.right,t,{...r,path:[...r.path,"allOf",1]}),a=u=>"allOf"in u&&Object.keys(u).length===1,l=[...a(i)?i.allOf:[i],...a(s)?s.allOf:[s]];n.allOf=l,t.intersections.push(l)},zN=(e,t,n,r)=>{let o=n,i=e._zod.def;o.type="array";let s=t.target==="draft-2020-12"?"prefixItems":"items",a=t.target==="draft-2020-12"||t.target==="openapi-3.0"?"items":"additionalItems",l=i.items.map((S,A)=>Ve(S,t,{...r,path:[...r.path,s,A]})),u=i.rest?Ve(i.rest,t,{...r,path:[...r.path,a,...t.target==="openapi-3.0"?[i.items.length]:[]]}):null,d=i.items.length;for(;d>0;){let S=i.items[d-1];if(!(t.io==="input"?Iu(S)!==void 0:S._zod.optout==="optional"))break;d--}let f=i.items.length,m=!i.rest;t.target==="draft-2020-12"?(o.prefixItems=l,m?o.items=!1:u&&(o.items=u),d>0&&(o.minItems=d),m&&(o.maxItems=f)):t.target==="openapi-3.0"?(o.items={anyOf:l},u&&o.items.anyOf.push(u),d>0&&(o.minItems=d),m&&(o.maxItems=f)):(o.items=l,m?o.additionalItems=!1:u&&(o.additionalItems=u),d>0&&(o.minItems=d),m&&(o.maxItems=f));let{minimum:h,maximum:E}=Mn(e);typeof h=="number"&&(o.minItems=h),typeof E=="number"&&(o.maxItems=E)};rb=new WeakMap;DN=(e,t,n,r)=>{let o=n,i=e._zod.def;o.type="object";let s=i.keyType,a=Mn(s).patterns;if(i.mode==="loose"&&a&&a.size>0){let d=Ve(i.valueType,t,{...r,path:[...r.path,"patternProperties","*"]});o.patternProperties={};for(let f of a)zn(o.patternProperties,_N(f).source,d)}else{if(t.target==="draft-07"||t.target==="draft-2020-12"){o.propertyNames=Ve(i.keyType,t,{...r,path:[...r.path,"propertyNames"]});let d=rb.get(t);d||(d=[],rb.set(t,d),t.deferred.push(()=>nH(t))),d.push(e)}o.additionalProperties=Ve(i.valueType,t,{...r,path:[...r.path,"additionalProperties"]})}let l=s._zod.values,u=t.io==="input"&&Iu(i.valueType)!==void 0;if(l&&!i.partial&&!u){let d=[...l].filter(f=>typeof f=="string"||typeof f=="number");d.length>0&&(o.required=d.map(String))}},PN=(e,t,n,r)=>{let o=e._zod.def,i=Ve(o.innerType,t,r),s=t.seen.get(e);t.target==="openapi-3.0"?(s.ref=o.innerType,n.nullable=!0):n.anyOf=[i,{type:"null"}]},MN=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType},ob=Symbol();HN=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType;let s=UN(o.defaultValue,e,t,n,r);s!==ob&&(n.default=s)},FN=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);if(i.ref=o.innerType,t.io!=="input")return;let s=UN(o.defaultValue,e,t,n,r);s!==ob&&(n._prefault=s)},BN=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType;let s;try{s=o.catchValue(void 0)}catch{so(e,t,n,r,"Dynamic catch values are not supported in JSON Schema");return}n.default=s},GN=(e,t,n,r)=>{let o=e._zod.def,i=o.in._zod.traits.has("$ZodTransform"),s=t.io==="input"?i?o.out:o.in:o.out;Ve(s,t,r);let a=t.seen.get(e);a.ref=s},VN=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType,n.readOnly=!0},ib=(e,t,n,r)=>{let o=e._zod.def;Ve(o.innerType,t,r);let i=t.seen.get(e);i.ref=o.innerType},jN=(e,t,n,r)=>{let o=e._zod.innerType;Ve(o,t,r);let i=t.seen.get(e);i.ref=o}});var $i=y(()=>{Ls();sy();XA();kE();hv();bf();vE();Sn();UE();wE();_v();oN();kf()});var ab=y(()=>{$i()});function zf(e,t,n){Object.defineProperty(e,t,{configurable:!0,enumerable:!1,get(){let r=n(this);return Object.defineProperty(this,t,{value:r,configurable:!0,writable:!0}),r},set(r){Object.defineProperty(this,t,{value:r,configurable:!0,writable:!0})}})}var ZN,uH,Un,cb=y(()=>{$i();$i();Sn();ZN=new WeakSet([Object.prototype,Error.prototype]);uH=(e,t)=>{ZA.init(e,t),e.name="ZodError";let n=Object.getPrototypeOf(e);ZN.has(n)||(ZN.add(n),zf(n,"format",r=>o=>YA(r,o)),zf(n,"flatten",r=>o=>WA(r,o)),zf(n,"addIssue",r=>o=>{r.issues.push(o),r.message=JSON.stringify(r.issues,ec,2)}),zf(n,"addIssues",r=>o=>{r.issues.push(...o),r.message=JSON.stringify(r.issues,ec,2)}),Object.defineProperty(n,"isEmpty",{configurable:!0,enumerable:!1,get(){return this.issues.length===0}}))},Un=I("ZodError",uH,void 0,{Parent:Error})});var WN,YN,XN,qN,JN,QN,eR,tR,nR,rR,oR,iR,lb=y(()=>{$i();cb();$i();WN=df(Un),YN=pf(Un),XN=ff(Un),qN=hf(Un),JN=JA(Un),QN=QA(Un),eR=ey(Un),tR=ty(Un),nR=ny(Un),rR=ry(Un),oR=oy(Un),iR=iy(Un)});function pH(){nn.localeError||Pn(mv())}function Cu(){nn.memoizer||Pn({memoizer:fv()})}function p(e){return Tv(fH,e)}function _(e){return Wv(dR,e)}function sR(e){return Yv(DH,e)}function L(e){return Xv(PH,e)}function Lu(e){return qv(MH,e)}function pR(e){return Jv(UH,e)}function q(){return Qv(HH)}function BH(e){return eN(FH,e)}function C(e,t){return tN(GH,e,t)}function b(e,t){let n={type:"object",shape:e!=null?e:{},...ne.normalizeParams(t)};return new VH(n)}function wt(e,t){return new fR({type:"union",options:e,...ne.normalizeParams(t)})}function vt(e,t,n){return new jH({type:"union",options:t,discriminator:e,...ne.normalizeParams(n)})}function ZH(e,t){return new KH({type:"intersection",left:e,right:t})}function Mf(e,t,n){let r=t instanceof De,o=r?n:t,i=r?t:null;return new WH({type:"tuple",items:e,rest:i,...ne.normalizeParams(o)})}function ie(e,t,n){return!t||!t._zod?new ub({type:"record",keyType:p(),valueType:e,...ne.normalizeParams(t)}):new ub({type:"record",keyType:e,valueType:t,...ne.normalizeParams(n)})}function db(e,t,n){return new ub({type:"record",keyType:e,valueType:t,...ne.normalizeParams(n),partial:!0})}function fe(e,t){let n=Array.isArray(e)?Object.fromEntries(e.map(r=>[r,r])):e;return new Pf({type:"enum",entries:n,...ne.normalizeParams(t)})}function R(e,t){return new Pf({type:"enum",entries:e,...ne.normalizeParams(t)})}function U(e,t){return new hR({type:"literal",values:Array.isArray(e)?e:[e],...ne.normalizeParams(t)})}function mR(e){return new YH({type:"transform",transform:e})}function aR(e){return new pb({type:"optional",innerType:e})}function XH(e){return new gR({type:"optional",innerType:e})}function cR(e){return new qH({type:"nullable",innerType:e})}function QH(e,t){return new JH({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():ne.shallowClone(t)}})}function tF(e,t){return new eF({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():ne.shallowClone(t)}})}function nF(e,t){return new ER({type:"nonoptional",innerType:e,...ne.normalizeParams(t)})}function oF(e,t){return new rF({type:"catch",innerType:e,catchValue:typeof t=="function"?t:ne.constantCatch(t)})}function lR(e,t){return new bR({type:"pipe",in:e,out:t})}function aF(e){return new sF({type:"readonly",innerType:e})}function Uf(e){return new cF({type:"lazy",getter:e})}function uF(e,t={}){return nN(lF,e,t)}function dF(e,t){return rN(e,t)}function $u(e,t){return new iF({type:"pipe",in:mR(e),out:t})}var Me,uR,fH,qe,hH,mH,gH,EH,bH,_H,Df,SH,TH,xH,AH,yH,wH,vH,NH,RH,OH,IH,CH,LH,$H,kH,zH,dR,DH,PH,MH,UH,HH,FH,GH,VH,fR,jH,KH,WH,ub,Pf,hR,YH,pb,gR,qH,JH,eF,ER,rF,bR,iF,sF,cF,lF,_R=y(()=>{$i();$i();KN();kf();gv();ab();lb();Me=I("ZodType",(e,t)=>(pH(),De.init(e,t),e.def=t,e.type=t.type,e),{check(...e){var n;let t=this.def;return this.clone(ne.mergeDefs(t,{checks:[...(n=t.checks)!=null?n:[],...e.map(r=>typeof r=="function"?{_zod:{check:r,def:{check:"custom"},onattach:[]}}:r)]}),{parent:!0})},with(...e){return this.check(...e)},clone(e,t){return Ir(this,e,t)},brand(){return this},register(e,t){return e.add(this,t),this},refine(e,t){return this.check(uF(e,t))},superRefine(e,t){return this.check(dF(e,t))},overwrite(e){return this.check(Li(e))},optional(){return aR(this)},exactOptional(){return XH(this)},nullable(){return cR(this)},nullish(){return aR(cR(this))},nonoptional(e){return nF(this,e)},array(){return C(this)},or(e){return wt([this,e])},and(e){return ZH(this,e)},transform(e){return lR(this,mR(e))},default(e){return QH(this,e)},prefault(e){return tF(this,e)},catch(e){return oF(this,e)},pipe(e){return lR(this,e)},readonly(){return aF(this)},describe(e){let t=this.clone();return $s.add(t,{description:e}),t},meta(...e){if(e.length===0)return $s.get(this);let t=this.clone();return $s.add(t,e[0]),t},isOptional(){return this.safeParse(void 0).success},isNullable(){return this.safeParse(null).success},apply(e,...t){return t.length===0?e(this):e(this,...t)},get"~standard"(){return ne.hide(this,"~standard",{...RE(this),jsonSchema:{input:Ou(this,"input"),output:Ou(this,"output")}})},set"~standard"(e){ne.own(this,"~standard",e)},parse:function e(t,n){return WN(this,t,n,{callee:e})},parseAsync:async function e(t,n){return await YN(this,t,n,{callee:e})},safeParse(e,t){return XN(this,e,t)},async safeParseAsync(e,t){return qN(this,e,t)},get spa(){return this==null?void 0:this.safeParseAsync},set spa(e){ne.own(this,"spa",e)},validate(e,t){return EE(this,e,t)},validateAsync(e,t){return bE(this,e,t)},encode:function e(t,n){return JN(this,t,n,{callee:e})},decode:function e(t,n){return QN(this,t,n,{callee:e})},encodeAsync:async function e(t,n){return await eR(this,t,n,{callee:e})},decodeAsync:async function e(t,n){return await tR(this,t,n,{callee:e})},safeEncode(e,t){return nR(this,e,t)},safeDecode(e,t){return rR(this,e,t)},async safeEncodeAsync(e,t){return oR(this,e,t)},async safeDecodeAsync(e,t){return iR(this,e,t)},toJSONSchema(e){return uN(this,{})(e)},get description(){var e;return(e=$s.get(this))==null?void 0:e.description},get _def(){return this._zod.def}}),uR=I("_ZodString",(e,t)=>{Af.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>SN(e,n,r,o)},ne.derived({format:e=>{var t;return(t=Mn(e).format)!=null?t:null},minLength:e=>{var t;return(t=Mn(e).minimum)!=null?t:null},maxLength:e=>{var t;return(t=Mn(e).maximum)!=null?t:null}},{regex(...e){return this.check(HE(...e))},includes(...e){return this.check(GE(...e))},startsWith(...e){return this.check(VE(...e))},endsWith(...e){return this.check(jE(...e))},min(...e){return this.check(ic(...e))},max(...e){return this.check(Lf(...e))},length(...e){return this.check($f(...e))},nonempty(...e){return this.check(ic(1,...e))},lowercase(e){return this.check(FE(e))},uppercase(e){return this.check(BE(e))},trim(){return this.check(ZE())},normalize(...e){return this.check(KE(...e))},toLowerCase(){return this.check(WE())},toUpperCase(){return this.check(YE())},slugify(){return this.check(XE())}})),fH=I("ZodString",(e,t)=>{Af.init(e,t),uR.init(e,t)},{email(e){return this.check(xv(bH,e))},url(e){return this.check(Rv(SH,e))},jwt(e){return this.check(Gv(zH,e))},emoji(e){return this.check(Ov(TH,e))},guid(e){return this.check(Av(_H,e))},uuid(e){return this.check(yv(Df,e))},uuidv4(e){return this.check(wv(Df,e))},uuidv6(e){return this.check(vv(Df,e))},uuidv7(e){return this.check(Nv(Df,e))},nanoid(e){return this.check(Iv(xH,e))},cuid(e){return this.check(Cv(AH,e))},cuid2(e){return this.check(Lv(yH,e))},ulid(e){return this.check($v(wH,e))},base64(e){return this.check(Hv(LH,e))},base64url(e){return this.check(Fv($H,e))},xid(e){return this.check(kv(vH,e))},ksuid(e){return this.check(zv(NH,e))},ipv4(e){return this.check(Dv(RH,e))},ipv6(e){return this.check(Pv(OH,e))},cidrv4(e){return this.check(Mv(IH,e))},cidrv6(e){return this.check(Uv(CH,e))},e164(e){return this.check(Bv(kH,e))},datetime(e){return this.check(Vv(hH,e))},date(e){return this.check(jv(mH,e))},time(e){return this.check(Kv(gH,e))},duration(e){return this.check(Zv(EH,e))}});qe=I("ZodStringFormat",(e,t)=>{Be.init(e,t),uR.init(e,t)}),hH=I("ZodISODateTime",(e,t)=>{Aw.init(e,t),qe.init(e,t)}),mH=I("ZodISODate",(e,t)=>{yw.init(e,t),qe.init(e,t)}),gH=I("ZodISOTime",(e,t)=>{ww.init(e,t),qe.init(e,t)}),EH=I("ZodISODuration",(e,t)=>{vw.init(e,t),qe.init(e,t)}),bH=I("ZodEmail",(e,t)=>{pw.init(e,t),qe.init(e,t)}),_H=I("ZodGUID",(e,t)=>{uw.init(e,t),qe.init(e,t)}),Df=I("ZodUUID",(e,t)=>{dw.init(e,t),qe.init(e,t)}),SH=I("ZodURL",(e,t)=>{mw.init(e,t),qe.init(e,t)}),TH=I("ZodEmoji",(e,t)=>{gw.init(e,t),qe.init(e,t)}),xH=I("ZodNanoID",(e,t)=>{Ew.init(e,t),qe.init(e,t)}),AH=I("ZodCUID",(e,t)=>{bw.init(e,t),qe.init(e,t)}),yH=I("ZodCUID2",(e,t)=>{_w.init(e,t),qe.init(e,t)}),wH=I("ZodULID",(e,t)=>{Sw.init(e,t),qe.init(e,t)}),vH=I("ZodXID",(e,t)=>{Tw.init(e,t),qe.init(e,t)}),NH=I("ZodKSUID",(e,t)=>{xw.init(e,t),qe.init(e,t)}),RH=I("ZodIPv4",(e,t)=>{Nw.init(e,t),qe.init(e,t)}),OH=I("ZodIPv6",(e,t)=>{Ow.init(e,t),qe.init(e,t)}),IH=I("ZodCIDRv4",(e,t)=>{Iw.init(e,t),qe.init(e,t)}),CH=I("ZodCIDRv6",(e,t)=>{Cw.init(e,t),qe.init(e,t)}),LH=I("ZodBase64",(e,t)=>{$w.init(e,t),qe.init(e,t)}),$H=I("ZodBase64URL",(e,t)=>{kw.init(e,t),qe.init(e,t)}),kH=I("ZodE164",(e,t)=>{zw.init(e,t),qe.init(e,t)}),zH=I("ZodJWT",(e,t)=>{Dw.init(e,t),qe.init(e,t)}),dR=I("ZodNumber",(e,t)=>{IE.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>TN(e,n,r,o),e.isFinite=!0},ne.derived({minValue:e=>{let{minimum:t,exclusiveMinimum:n}=Mn(e);return Math.max(t!=null?t:Number.NEGATIVE_INFINITY,n!=null?n:Number.NEGATIVE_INFINITY)},maxValue:e=>{let{maximum:t,exclusiveMaximum:n}=Mn(e);return Math.min(t!=null?t:Number.POSITIVE_INFINITY,n!=null?n:Number.POSITIVE_INFINITY)},isInt:e=>{let{isInt:t,multipleOf:n}=Mn(e);return!!t||!!(n!=null&&n.some(Number.isSafeInteger))},format:e=>{var t;return(t=Mn(e).format)!=null?t:null}},{gt(e,t){return this.check(If(e,t))},gte(e,t){return this.check(Nu(e,t))},min(e,t){return this.check(Nu(e,t))},lt(e,t){return this.check(Of(e,t))},lte(e,t){return this.check(vu(e,t))},max(e,t){return this.check(vu(e,t))},int(e){return this.check(sR(e))},safe(e){return this.check(sR(e))},positive(e){return this.check(If(0,e))},nonnegative(e){return this.check(Nu(0,e))},negative(e){return this.check(Of(0,e))},nonpositive(e){return this.check(vu(0,e))},multipleOf(e,t){return this.check(Cf(e,t))},step(e,t){return this.check(Cf(e,t))},finite(){return this}}));DH=I("ZodNumberFormat",(e,t)=>{Pw.init(e,t),dR.init(e,t)});PH=I("ZodBoolean",(e,t)=>{Mw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>xN(e,n,r,o)});MH=I("ZodUndefined",(e,t)=>{Uw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>yN(e,n,r,o)});UH=I("ZodNull",(e,t)=>{Hw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>AN(e,n,r,o)});HH=I("ZodUnknown",(e,t)=>{Fw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>vN(e,n,r,o)});FH=I("ZodNever",(e,t)=>{Bw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>wN(e,n,r,o)});GH=I("ZodArray",(e,t)=>{Cu(),Gw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>CN(e,n,r,o),e.element=t.element},{min(e,t){return this.check(ic(e,t))},nonempty(e){return this.check(ic(1,e))},max(e,t){return this.check(Lf(e,t))},length(e,t){return this.check($f(e,t))},unwrap(){return this.element}});VH=I("ZodObject",(e,t)=>{Cu(),Kw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>LN(e,n,r,o),ne.installLazyProp(e,"shape",n=>n._zod.def.shape,!1)},{keyof(){return fe(Object.keys(this._zod.def.shape))},catchall(e){return this.clone(ne.mergeDefs(this._zod.def,{catchall:e}))},passthrough(){return this.clone(ne.mergeDefs(this._zod.def,{catchall:q()}))},loose(){return this.clone(ne.mergeDefs(this._zod.def,{catchall:q()}))},strict(){return this.clone(ne.mergeDefs(this._zod.def,{catchall:BH()}))},strip(){return this.clone(ne.mergeDefs(this._zod.def,{catchall:void 0}))},extend(e){return ne.extend(this,e)},safeExtend(e){return ne.safeExtend(this,e)},merge(e){return ne.merge(this,e)},pick(e){return ne.pick(this,e)},omit(e){return ne.omit(this,e)},partial(...e){return ne.partial(pb,this,e[0])},exactPartial(...e){return ne.partial(gR,this,e[0],"exactPartial")},required(...e){return ne.required(ER,this,e[0])}});fR=I("ZodUnion",(e,t)=>{CE.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>$N(e,n,r,o),e.options=t.options});jH=I("ZodDiscriminatedUnion",(e,t)=>{fR.init(e,t),Zw.init(e,t)});KH=I("ZodIntersection",(e,t)=>{Ww.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>kN(e,n,r,o)});WH=I("ZodTuple",(e,t)=>{Cu(),Yw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>zN(e,n,r,o)},{rest(e){return this.clone({...this._zod.def,rest:e})},partial(){var t;let e=this._zod.def;if((t=e.checks)!=null&&t.length)throw new Error(".partial() cannot be used on tuple schemas containing refinements");return this.clone({...e,items:e.items.map(n=>new pb({type:"optional",innerType:n}))})}});ub=I("ZodRecord",(e,t)=>{Cu(),Xw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>DN(e,n,r,o),e.keyType=t.keyType,e.valueType=t.valueType});Pf=I("ZodEnum",(e,t)=>{qw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(r,o,i)=>NN(e,r,o,i),e.enum=t.entries,e.options=[...e._zod.values];let n=new Set(Object.keys(t.entries));e.extract=(r,o)=>{let i={};for(let s of r)if(n.has(s))i[s]=t.entries[s];else throw new Error(`Key ${s} not found in enum`);return new Pf({...t,checks:[],...ne.normalizeParams(o),entries:i})},e.exclude=(r,o)=>{let i={...t.entries};for(let s of r)if(n.has(s))delete i[s];else throw new Error(`Key ${s} not found in enum`);return new Pf({...t,checks:[],...ne.normalizeParams(o),entries:i})}});hR=I("ZodLiteral",(e,t)=>{Jw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>RN(e,n,r,o),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});YH=I("ZodTransform",(e,t)=>{Cu(),Qw.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>IN(e,n,r,o),e._zod.parse=(n,r)=>{if(r.direction==="backward")throw new oc(e.constructor.name);n.addIssue=i=>{var s,a;if(typeof i=="string")n.issues.push(ne.issue(i,n.value,t));else{let l=i;l.fatal&&(l.continue=!1),(s=l.code)!=null||(l.code="custom"),"input"in l||(l.input=n.value),(a=l.inst)!=null||(l.inst=e),n.issues.push(ne.issue(l))}};let o=t.transform(n.value,n);return o instanceof Promise?o.then(i=>(n.value=i,n)):(n.value=o,n)}});pb=I("ZodOptional",(e,t)=>{LE.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>ib(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});gR=I("ZodExactOptional",(e,t)=>{ev.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>ib(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});qH=I("ZodNullable",(e,t)=>{tv.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>PN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});JH=I("ZodDefault",(e,t)=>{nv.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>HN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});eF=I("ZodPrefault",(e,t)=>{rv.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>FN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});ER=I("ZodNonOptional",(e,t)=>{ov.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>MN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});rF=I("ZodCatch",(e,t)=>{iv.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>BN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});bR=I("ZodPipe",(e,t)=>{$E.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>GN(e,n,r,o),e.in=t.in,e.out=t.out});iF=I("ZodPreprocess",(e,t)=>{bR.init(e,t),sv.init(e,t)}),sF=I("ZodReadonly",(e,t)=>{av.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>VN(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});cF=I("ZodLazy",(e,t)=>{cv.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>jN(e,n,r,o),e.unwrap=()=>e._zod.def.getter()});lF=I("ZodCustom",(e,t)=>{lv.init(e,t),Me.init(e,t),e._zod.processJSONSchema=(n,r,o)=>ON(e,n,r,o)})});var ao,SR,TR=y(()=>{ao={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};SR||(SR={})});var xR=y(()=>{_R();ab();cb();lb();TR()});var ae=y(()=>{xR()});var cc,fb=y(()=>{"use strict";cc={ACT:"reticle_act",ACT_SEQUENCE:"reticle_act_sequence",ACT_AND_WAIT:"reticle_act_and_wait",INVOKE:"reticle_invoke"}});var Hf,hb,mb,z,rq,pF,oq,jo=y(()=>{"use strict";Hf={SIGNAL:"signal",NET:"net",STATE:"state"},hb={ELEMENT:"element",TEXT:"text"},mb={NETWORK:"network",APP:"app"},z={ELEMENT:hb.ELEMENT,TEXT:hb.TEXT,SIGNAL:Hf.SIGNAL,NET:Hf.NET,STATE:Hf.STATE,ROUTE:"route",CONSOLE:"console",ANIMATION:"animation",SETTLED:"settled",COMPARE:"compare",ALL_OF:"allOf",ANY_OF:"anyOf",NOT:"not"},rq=new Set(Object.values(Hf)),pF=new Set(Object.values(hb)),oq=new Set([...pF,z.ROUTE])});var AR,yR,wR,gb,fF,vR,rr,NR,je,on,Ff,ku=y(()=>{"use strict";AR=1,yR={FLOW_REPLAY:"flow_replay",MANUAL:"manual"},wR={PASS:"pass",DRIFT:"drift",ERROR:"error",FAIL:"fail"},gb=2,fF=3,vR=new Set([1,gb,fF]),rr={TESTID:"testid",ROLE:"role",SIGNAL:"signal",COMPONENT:"component"},NR="unresolved",je={ASSERT_SIGNAL:"assert-signal",ASSERT_VISIBLE:"assert-visible",ASSERT_STATE:"assert-state",ASSERT_NET:"assert-net",MARK_DYNAMIC:"mark-dynamic",SUCCESS_STATE:"success-state",INTENT:"intent"},on={IDLE:"idle",RECORDING:"recording",ANNOTATING:"annotating"},Ff={ACTIVE:"active",QUARANTINED:"quarantined",DRAFT:"draft"}});var RR,Eb=y(()=>{"use strict";RR={READ:"read",IDEMPOTENT:"idempotent",COMMITS:"commits"}});var OR=y(()=>{"use strict"});var v,zu,ks,IR=y(()=>{"use strict";v={DOM_ADDED:"dom.added",DOM_REMOVED:"dom.removed",DOM_ATTR:"dom.attr",DOM_TEXT:"dom.text",NET_REQUEST:"net.request",NET_PENDING:"net.pending",NET_STREAM:"net.stream",PERF:"perf",ROUTE_CHANGE:"route.change",CONSOLE_LOG:"console.log",CONSOLE_WARN:"console.warn",CONSOLE_ERROR:"console.error",CONSOLE_INFO:"console.info",CONSOLE_DEBUG:"console.debug",ERROR_UNCAUGHT:"error.uncaught",VISIBLE_SHOWN:"visible.shown",ANIM_START:"anim.start",ANIM_END:"anim.end",SCROLL_POSITION:"scroll.position",REVEAL_SHOWN:"reveal.shown",SIGNAL:"signal",STATE_CHANGE:"state.change",STORAGE_CHANGE:"storage.change",PAGE_HEALTH:"page.health",CONTEXT_OPENED:"context.opened",DIALOG_OPENED:"dialog.opened",RENDER_COMMIT:"render.commit",FOCUS_CHANGE:"focus.change",FIELD_CHANGE:"field.change",FLOW_RECORDED:"flow.recorded",TRANSPORT_OVERFLOW:"transport.overflow",TRUNCATED:"truncated",BLIND_SPOT:"blind-spot",SDK_FAILED:"sdk.failed",NET_DETAIL:"net.detail",NET_RESPONSE_BODY:"net.response-body",HUMAN_CONTROL:"human.control",HUMAN_MARK:"human.mark",DOWNLOAD:"download",HUD_USED:"hud.used",MEDIA_STATE:"media.state",CANVAS_DIGEST:"canvas.digest"},zu={PLAY:"play",PLAYING:"playing",PAUSE:"pause",SEEKED:"seeked",ENDED:"ended",LOADED_DATA:"loadeddata",CAN_PLAY:"canplay",WAITING:"waiting",ERROR:"error"},ks={POLL:"poll",ACT:"act"}});function LR(e=bb,t=hF){return`ws://${t}:${String(e)}${zs}`}var bb,zs,Bf,CR,hF,or,Gf,uq,Z,ve,Vf,$R,kR,zR,lc,dq,DR,fq,Du,jf,Kf,PR,uc,Pu,mF,hq,D,MR,UR,Se,Je,H,ct,dc,sn,Kt=y(()=>{"use strict";OR();IR();bb=4400,zs="/reticle",Bf=1,CR=1,hF="localhost";or={SESSION:"__reticle_session",PROJECT:"__reticle_project",OPENED:"__reticle_opened",HUD:"__reticle_hud"},Gf="https://app.reticle.sh",uq={MAX_RUNS:50,MAX_BYTES:4*1024*1024},Z={MAX_MESSAGE_BYTES:1024*1024,MAX_MESSAGES_PER_SECOND:2e4,MAX_SESSIONS:32,MAX_PENDING_CONNECTIONS:16,HELLO_TIMEOUT_MS:5e3,MAX_BUFFER_BYTES:8*1024*1024,MAX_SESSION_ID_LENGTH:128,MAX_URL_LENGTH:4096,MAX_TITLE_LENGTH:512,MAX_ADAPTERS:32,MAX_CONTRACT_NAMES:128,MAX_ADAPTER_NAME_LENGTH:128,MAX_TOKEN_LENGTH:512,MAX_COMMAND_ID_LENGTH:128,MAX_COMMAND_NAME_LENGTH:128,MAX_REF_LENGTH:128,MAX_ERROR_LENGTH:4096,MAX_STACK_LENGTH:4e3,MAX_SERIALIZE_DEPTH:8,MAX_COLLECTION_ITEMS:200,MAX_DESCRIBED_TEXT:80,MAX_FULL_TEXT:4e3,MAX_FULL_TEXT_ELEMENTS:32,MAX_OBJECT_KEYS:200,MAX_STRING_LENGTH:64*1024,MAX_MARK_NOTE_LENGTH:2e3,MAX_MARK_LABEL_LENGTH:256},ve="[REDACTED]",Vf="confirmDangerous",$R="native",kR="reveal",zR="inViewport",lc={NO_PROVIDER:"no-visual-provider",CAPTURE_FAILED:"capture-failed",BASELINE_MISSING:"baseline-missing",DIMENSION_MISMATCH:"dimension-mismatch",FULL_PAGE_UNSUPPORTED:"full-page-unsupported",CROP_UNSUPPORTED:"crop-unsupported",NOT_COMPOSITED:"window-not-composited"},dq=1440*60*1e3,DR=1,fq={MAX_EVENTS:2e3,MAX_AGE_MS:6e4,MAX_BYTES:Z.MAX_BUFFER_BYTES},Du="reticle:busy",jf="__reticle_renders",Kf={DOM:"dom",JOURNAL:"journal"},PR={WINDOW:"window"},uc={LCP:"lcp",CLS:"cls",LONGTASK:"longtask"},Pu={HOVER_NATIVE_ENTER_LEAVE:"target has enter/leave handlers; synthetic hover may not trigger them \u2014 expect no state change",REAL_INPUT_FELL_BACK:"real-input provider was available but failed; fell back to synthetic dispatch",CLICK_OCCLUDED:"target is visually occluded by another element; a real user could not click it (synthetic dispatch still delivered the event) \u2014 dismiss the overlay or scroll the target clear",GLOBAL_PRESS:"press landed on the focused element or document \u2014 no named target was given, so this effect does not claim one",CLICK_NOT_A_CONTROL:"target is not a control and sits inside none (no button/link/input role, onclick, tabindex or pointer cursor), so a click on it may do nothing \u2014 if nothing happened, target the control inside it by role"},mF="console.",hq=[v.CONSOLE_LOG,v.CONSOLE_WARN,v.CONSOLE_ERROR,v.CONSOLE_INFO].map(e=>e.slice(mF.length)),D={CLICK:"click",DBLCLICK:"dblclick",HOVER:"hover",FOCUS:"focus",BLUR:"blur",FILL:"fill",TYPE:"type",CLEAR:"clear",SELECT:"select",CHECK:"check",UNCHECK:"uncheck",SUBMIT:"submit",PRESS:"press",UPLOAD:"upload",SCROLL_INTO_VIEW:"scrollIntoView",SCROLL:"scroll",DRAG:"drag",TAP:"tap",ZOOM:"zoom"},MR={TIMEOUT:"timeout",THROTTLED:"throttled"},UR={UNAVAILABLE:"component-state-unavailable"},Se={VISIBLE:"visible",HIDDEN:"hidden",ENABLED:"enabled",DISABLED:"disabled",CHECKED:"checked",EXPANDED:"expanded",PRESSED:"pressed",FOCUSED:"focused",PRESENT:"present",IN_VIEWPORT:"inViewport"},Je={ROLE:"role",TEXT:"text",LABEL:"label",PLACEHOLDER:"placeholder",TESTID:"testid",ALT:"alt",COMPONENT:"component"},H={SNAPSHOT:"snapshot",QUERY:"query",MATCH:"match",INSPECT:"inspect",ACT:"act",ACT_SEQUENCE:"act_sequence",ANIMATIONS:"animations",NARRATE:"narrate",CLOCK:"clock",CAPABILITIES:"capabilities",STATE_READ:"state_read",STORAGE_READ:"storage_read",SCROLL:"scroll",SESSION_CONFIG:"session_config",PRESENTER:"presenter",IMPACT:"impact",CAPTURE:"capture",RENDER:"render",NAVIGATE:"navigate",REFRESH:"refresh",FLOWS:"flows",FLOW_PROGRESS:"flow.progress",PLAN:"plan",MARKERS:"markers"},ct={IDLE:"idle",READING:"reading",ACTING:"acting"},dc={FULL:"full",INTERACTIVE:"interactive",STATUS:"status"},sn={HELLO:"hello",COMMAND:"command",COMMAND_RESULT:"command_result",EVENT:"event"}});var ir,gF,sr,Eq,Ds=y(()=>{"use strict";ae();ir={WEB:"web",DESKTOP:"desktop",MOBILE:"mobile",SERVICE:"service",GAME:"game",DEVICE:"device"},gF=wt([R(ir),p().regex(/^x-[a-z0-9-]+$/,"a surface this specification does not name must start with x-")]),sr=b({surface:gF,instance:p().min(1),epoch:_().int().nonnegative().optional(),locator:p().optional(),revision:p().optional()}),Eq=b({kind:fe(["instance","epoch"]),from:p(),to:p()})});var $,Hn,Tn,an,_b,Sb,kr=y(()=>{"use strict";ae();$={UI:"ui",NET:"net",STATE:"state",SIGNAL:"signal",LOG:"log",ROUTE:"route",STORAGE:"storage",TIME:"time",VISUAL:"visual"},Hn=wt([R($),p().regex(/^x-[a-z0-9-]+$/,"a channel this specification does not name must start with x-")]),Tn={INDEPENDENT:"independent",ACTUATION_DERIVED:"actuation-derived"},an={CONSEQUENCE:"consequence",PRESENCE:"presence",CONTEXT:"context"},_b=b({id:Hn,independence:R(Tn),grade:R(an),note:p().optional()}),Sb={[$.UI]:{independence:Tn.ACTUATION_DERIVED,grade:an.PRESENCE},[$.NET]:{independence:Tn.INDEPENDENT,grade:an.CONSEQUENCE},[$.STATE]:{independence:Tn.ACTUATION_DERIVED,grade:an.CONSEQUENCE},[$.SIGNAL]:{independence:Tn.ACTUATION_DERIVED,grade:an.CONSEQUENCE},[$.LOG]:{independence:Tn.INDEPENDENT,grade:an.CONTEXT},[$.ROUTE]:{independence:Tn.ACTUATION_DERIVED,grade:an.PRESENCE},[$.STORAGE]:{independence:Tn.ACTUATION_DERIVED,grade:an.CONSEQUENCE},[$.TIME]:{independence:Tn.INDEPENDENT,grade:an.CONTEXT},[$.VISUAL]:{independence:Tn.ACTUATION_DERIVED,grade:an.PRESENCE}}});var HR=y(()=>{"use strict"});var xq,FR=y(()=>{"use strict";ae();Ds();xq=b({id:p().min(1),subject:sr,capturedAt:_().int(),payload:q().optional()})});var yq,BR=y(()=>{"use strict";ae();yq=b({mutation:p().min(1)})});var EF,Tb,bF,_F,GR,VR,xb,jR,KR,Mu=y(()=>{"use strict";ae();kr();EF={USER:"user",DEVELOPER:"developer",AGENT:"agent",SYSTEM:"system",WORKFLOW:"workflow",DERIVED:"derived"},Tb={DECLARED:"declared",BOUND:"bound",ABANDONED:"abandoned"},bF=b({id:p().min(1),statement:p().min(1),origin:R(EF),claims:C(p()).default([]),declaredAt:_().int().optional()}),_F=vt("status",[b({status:U(Tb.ABANDONED),abandonedBecause:p().trim().min(1)}),b({status:U(Tb.DECLARED),abandonedBecause:Lu().optional()}),b({status:U(Tb.BOUND),abandonedBecause:Lu().optional()})]),GR=bF.and(_F),VR={BEFORE_ACTION:"before-action",AFTER_ACTION:"after-action"},xb=b({id:p().min(1),predicate:q().optional(),reads:p().min(1),channels:C(Hn).min(1)}),jR=b({id:p().min(1),intent:p().optional(),statement:p().min(1),declaredAt:R(VR),assertions:C(xb).default([])}),KR=b({id:p().min(1),statement:p().min(1),predicate:q().optional(),channels:C(Hn).min(1),severity:fe(["blocking","advisory"]).default("blocking")})});var SF,pc,Iq,Ab,ZR,WR,TF,YR,ki=y(()=>{"use strict";ae();kr();Ds();SF=b({id:p().min(1),window:p().min(1),channel:Hn,at:_().int(),value:q().optional(),summary:p().min(1)}),pc={AUTHORITATIVE:"authoritative",DERIVED:"derived",OBSERVED:"observed",LEARNED:"learned"},Iq={[pc.LEARNED]:0,[pc.OBSERVED]:1,[pc.DERIVED]:2,[pc.AUTHORITATIVE]:3},Ab=b({class:R(pc),source:p().min(1),method:p().min(1),subject:sr,at:_().int(),confidence:_().min(0).max(1).optional()}),ZR=b({observation:SF,provenance:Ab,independence:R(Tn),grade:R(an)}),WR={CHANNEL_UNOBSERVED:"channel-unobserved",BOUNDARY_UNCROSSABLE:"boundary-uncrossable",BUFFER_TRUNCATED:"buffer-truncated",REDACTED:"redacted",STILL_IN_FLIGHT:"still-in-flight",EFFECT_ELSEWHERE:"effect-elsewhere"},TF=b({kind:R(WR),channel:Hn.optional(),detail:p().min(1),impeaching:L(),remedy:p().optional()}),YR=b({window:p().min(1),observed:C(Hn),blindSpots:C(TF)})});var AF,yF,Zf,wF,Wf,yb,kq,XR=y(()=>{"use strict";ae();kr();ki();AF=b({channel:Hn}),yF=wt([b({summary:p().min(1),valueContains:p().min(1)}),b({summary:p().min(1).optional(),valueContains:Lu().optional()})]),Zf=AF.and(yF),wF={EXACTLY:"exactly",AT_LEAST:"at-least",AT_MOST:"at-most"},Wf={COUNT:"count",PRESENT:"present",ABSENT:"absent",MEASURE:"measure"},yb={EQUALS:"equals",AT_LEAST:"at-least",AT_MOST:"at-most"},kq=vt("kind",[b({kind:U(Wf.COUNT),match:Zf,op:R(wF),value:_().int().nonnegative()}),b({kind:U(Wf.PRESENT),match:Zf}),b({kind:U(Wf.ABSENT),match:Zf}),b({kind:U(Wf.MEASURE),match:Zf,op:R(yb),value:_().finite(),tolerance:_().nonnegative().finite().default(0)})])});var Pq,wb,Mq,Yf,qR,Uu,JR,Uq,Ps=y(()=>{"use strict";ae();Ds();Pq=b({name:p().min(1),meaning:p().min(1),parameters:q().optional(),mutating:L()}),wb={UNDECLARED:"undeclared",UNSUPPORTED:"unsupported",UNRESOLVED:"unresolved",UNAVAILABLE:"unavailable",GUARDED:"guarded",MALFORMED:"malformed"},Mq=b({ref:p().min(1),describes:p().min(1),at:p().optional()}),Yf=b({id:p().min(1),actor:p().min(1),capability:p().min(1),target:p().optional(),parameters:q().optional(),at:_().int()}),qR=b({action:p().min(1),dispatched:L(),refused:b({reason:R(wb),detail:p().min(1)}).optional(),subject:sr,at:_().int()}),Uu={QUIESCENCE:"quiescence",TICKS:"ticks",ACK:"ack",SIGNAL:"signal",SETTLED_PHYSICAL:"settled-physical",EXIT:"exit",TERMINATED:"terminated",BUDGET_EXHAUSTED:"budget-exhausted"},JR=b({id:p().min(1),openedAt:_().int(),closedAt:_().int().optional(),budgetMs:_().int().positive(),closes:R(Uu),closedBy:R(Uu).optional(),subject:sr}),Uq=new Set([Uu.BUDGET_EXHAUSTED,Uu.TERMINATED])});var Xf,vF,QR,NF,vb,Nb,eO,fc=y(()=>{"use strict";ae();kr();Xf={YES:"yes",NO:"no",UNKNOWN:"unknown",NO_FAULT:"no-fault"},vF=p().min(1),QR={ADVANCED_OVER_FAILURE:"advanced-over-failure",CLAIMED_OVER_FAILURE:"claimed-over-failure",EFFECT_DISCARDED:"effect-discarded",CLAIM_UNCORROBORATED:"claim-uncorroborated",FAILURE_INSIDE_SUCCESS:"failure-inside-success",VALUE_NOT_APPLIED:"value-not-applied",DUPLICATED_EFFECT:"duplicated-effect",STALE_APPLIED:"stale-applied",NO_EFFECT:"no-effect",FAULT_MISATTRIBUTED:"fault-misattributed",EVIDENCE_SUPERSEDED:"evidence-superseded",EVIDENCE_PREDATES_EDIT:"evidence-predates-edit"},NF=wt([R(QR),p().regex(/^x-[a-z0-9-]+$/,"an anomaly this specification does not name must start with x-")]),vb={OBSERVED:"observed",ABSENCE_DERIVED:"absence-derived",ADVISORY:"advisory"},Nb=b({kind:NF,tier:R(vb),claim:p().min(1),counter:p().min(1),between:Mf([Hn,Hn]),evidence:C(p()).default([])}),eO=b({id:p().min(1),claim:p().min(1),window:p().min(1),verdict:R(Xf),grade:R(an).optional(),reasons:C(vF).default([]),evidence:C(p()).default([]),anomalies:C(Nb).default([]),supersedes:p().optional(),at:_().int()})});var RF,OF,IF,Zq,tO,CF,Wq,Rb=y(()=>{"use strict";ae();Ps();Mu();ki();fc();RF=p().min(1).regex(/^(?!.*(?:^|\/)\.{1,2}(?:\/|$))[^/]+(?:\/[^/]+)*$/,{message:"a flow name is `/`-separated segments: no empty segment, no leading or trailing slash, no `.` or `..`"}),OF=b({id:p().min(1),invoke:RF,with:q().optional(),at:_().int()}),IF=wt([Yf,OF]),Zq=b({name:p().min(1),version:_().int().positive(),startState:q().optional(),requires:q().optional(),ensures:q().optional(),claim:p().min(1),steps:C(IF),expects:C(xb).default([]),mayRebind:L().default(!1)}),tO=b({verdict:p().min(1),expected:p().min(1),actual:p().min(1),evidence:C(p()).min(1),location:b({file:p(),line:_().int().optional(),symbol:p().optional()}).optional(),instruction:p().min(1)}),CF={INVARIANT:"invariant",FAILURE_MODE:"failure-mode",GAP:"gap",REPAIR_OUTCOME:"repair-outcome"},Wq=b({id:p().min(1),kind:R(CF),statement:p().min(1),provenance:Ab,observations:_().int().nonnegative().default(0),promotedBy:p().optional(),promotedAt:_().int().optional()})});var LF,$F,rJ,nO=y(()=>{"use strict";ae();kr();Mu();Ps();ki();fc();Rb();Ds();LF="1.0",$F=b({constraint:p().min(1),at:_().int(),detail:p().min(1),evidence:C(p()).default([])}),rJ=b({ovp:U(LF),id:p().min(1),verifier:b({name:p().min(1),version:p().min(1),profile:p().optional()}),subject:sr,channels:C(_b),witnesses:C(b({name:p().min(1),subject:sr,channels:C(_b)})).default([]),intents:C(GR).default([]),claims:C(jR).default([]),constraints:C(KR).default([]),actions:C(Yf).default([]),receipts:C(qR).default([]),windows:C(JR).default([]),evidence:C(ZR).default([]),coverage:C(YR).default([]),anomalies:C(Nb).default([]),verdicts:C(eO).default([]),violations:C($F).default([]),repairs:C(tO).default([]),startedAt:_().int(),endedAt:_().int()})});var Ob=y(()=>{"use strict";fc()});var Ib=y(()=>{"use strict";Mu();kr();ki();Ps();fc()});var Cb=y(()=>{"use strict";Ps();kr();Ob();ki();Ib()});var Lb=y(()=>{"use strict"});var rO=y(()=>{"use strict";Lb()});var Ms,NJ,RJ,OJ,oO=y(()=>{"use strict";ae();kr();Ms={EFFECT:"effect",IN_REALM:"in-realm",SURFACE:"surface"},NJ=[Ms.EFFECT,Ms.IN_REALM,Ms.SURFACE],RJ={[Ms.EFFECT]:[$.NET,$.LOG],[Ms.IN_REALM]:[$.NET,$.LOG,$.STATE,$.SIGNAL],[Ms.SURFACE]:[$.NET,$.LOG,$.STATE,$.SIGNAL,$.UI]},OJ=b({name:p().min(1),version:p().min(1),platform:p().min(1),claims:R(Ms),homepage:p().optional()})});var iO=y(()=>{"use strict";Cb();kr();Ps();ki();Ds()});var hc=y(()=>{"use strict";Ds();kr();HR();FR();BR();Mu();XR();Ps();ki();fc();Rb();nO();Cb();Ob();Lb();rO();Ib();oO();iO()});var Fn,lt,sO,cn,Ko=y(()=>{"use strict";Fn={YES:"yes",NO:"no",UNKNOWN:"unknown",NO_FAULT:"no-fault"},lt={VERSION_SKEW:"version_skew",CAPABILITY_ABSENT:"capability-absent",INCONCLUSIVE:"inconclusive",OBSERVATION_LOST:"observation_lost",WINDOW_CLOSED_EARLY:"window_closed_early",ASSERTION_FAILED:"assertion_failed",CONTRADICTED:"contradicted",ALREADY_TRUE:"already_true",HIDDEN_MATCH:"hidden_match",UNCLEAN_CAPTURE:"unclean_capture",VACUOUS_GRADE:"vacuous_grade",NOTHING_DECLARED:"nothing_declared",OUTCOME_PENDING:"outcome_pending",OUTCOME_UNREAD:"outcome_unread",UNSETTLED:"unsettled",EVIDENCE_INCOMPLETE:"evidence_incomplete",PROVED:"proved",ABSENCE_BLIND_SPOT:"absence_blind_spot"},sO={BUFFER_LOSS:"buffer_loss",TRANSPORT_GAP:"transport_gap",BLIND_SPOT:"blind_spot",JOURNAL_LOSS:"journal_loss",OTHER:"other"},cn={CLOSED_SHADOW_ROOT:"closed-shadow-root",RATE_LIMITED:"rate-limited",CROSS_ORIGIN_IFRAME:"cross-origin-iframe",UNINSTRUMENTED_FRAME:"uninstrumented-frame",VIRTUALIZED_UNMOUNTED:"virtualized-unmounted",WRAPPED_NETWORK:"wrapped-network",UNOBSERVED_IPC:"unobserved-ipc",VERDICTLESS_SEND:"verdictless-send",UNWATCHED_STATE:"unwatched-state"}});var DF,PF,aO,$b=y(()=>{"use strict";ae();Ko();DF={FINDABLE:"findable",DISCOVERABILITY:"discoverability",AGENT_ASSUMPTION:"agent_assumption",DEFECT:"defect"},PF=20,aO=b({goal:p().min(1).max(500),kind:R(DF),agent:b({verified:R(Fn),claim:p().max(2e3)}),harness:b({verified:R(Fn),found:L(),searched:C(p().max(500)).max(PF),gaveUpAt:p().max(500).optional()})})});var MF,UF,HF,FF,BF,GF,cO,VF,qf,jF,KF,ZF,WF,YF,XF,qF,JF,QF,eB,pQ,tB,kb,zb,nB,rB,oB,iB,sB,aB,cB,lB,uB,dB,fQ,Db=y(()=>{"use strict";ae();hc();jo();Ko();$b();MF=3,UF=1,HF=2,FF={pass:Fn.YES,fail:Fn.NO},BF={network:z.NET,layout:z.ELEMENT},GF=p().brand(),cO={PASS:"pass",FAIL:"fail",PARTIAL:"partial",UNKNOWN:"unknown"},VF={PASS:"pass",FAIL:"fail",SKIPPED:"skipped",HEALED:"healed"},qf={AUTH:"auth",PAYMENT:"payment",DB:"db",MIGRATION:"migration",RLS:"rls",SECRETS:"secrets",DESTRUCTIVE:"destructive",EXTERNAL:"external"},jF={LOW:"low",MEDIUM:"medium",HIGH:"high",CRITICAL:"critical"},KF={EDIT:"edit",CI:"ci",MANUAL:"manual",OEM:"oem"},ZF={ADDED:"added",MODIFIED:"modified",DELETED:"deleted"},WF={CODING_AGENT:"coding-agent",OEM_PIPELINE:"oem-pipeline",HUMAN:"human"},YF={REACT:"react",NEXT:"next",VITE:"vite",OTHER:"other"},XF={PREVIEW:"preview",CI:"ci",LOCAL:"local"},qF={HIGH:"high",MEDIUM:"medium",LOW:"low"},JF={DEV:"dev",PROD_PREVIEW:"prod-preview"},QF=b({file:p(),line:_().optional(),component:p().optional()}),eB=b({path:p(),changeKind:R(ZF),risk:C(R(qf)).default([])}),pQ=64*1024,tB={BROWSER:"browser",RENDERED:"rendered"},kb={RUNS_DIR:"runs",MANIFEST_FILE:"shots.jsonl",JPEG_QUALITY:.7,MAX_SIDE_PX:1600,MAX_PER_RUN:300,MAX_BYTES:1.5*1024*1024,FRAME_TOOL:"frame"},zb=b({file:p(),source:R(tB),width:_(),height:_(),sha256:p()}),nB=zb.extend({seq:_(),tool:p(),step:p().optional(),verdict:L().optional(),checkId:p().optional(),actionId:p().optional()}),rB=b({step:_(),anchor:p(),ok:L(),page:p().optional(),endPage:p().optional(),consequence:p().optional(),error:p().optional(),drift:p().optional(),screenshot:zb.optional()}),oB=b({startPath:p().optional(),steps:C(q())}),iB=b({name:p(),template:p().optional(),status:R(VF),steps:_(),durationMs:_(),oracle:p().optional(),healed:b({from:p(),to:p(),consequenceVerified:L()}).optional(),evidenceRef:p().optional(),failureReason:p().optional(),stepResults:C(rB).optional(),recording:oB.optional(),recordingOmitted:L().optional()}),sB=b({kind:$u(e=>{var t;return typeof e=="string"&&(t=BF[e])!=null?t:e},R(z).optional()),predicate:p(),status:$u(e=>{var t;return typeof e=="string"&&(t=FF[e])!=null?t:e},R(Fn)),evidence:q().optional(),declaredBeforeActing:L().optional(),expected:p().optional(),observed:p().optional(),grade:p().optional(),couldNotSee:C(p()).optional(),reason:p().optional(),checkId:p().optional(),actionId:p().optional(),intent:p().optional(),intentDerived:L().optional(),failedPart:_().int().min(0).optional(),screenshot:zb.optional(),supersedes:p().optional()}),aB=b({surface:R(qf),severity:R(jF),detail:p(),evidence:b({file:p().optional(),line:_().optional(),network:p().optional()}).optional(),gated:L().default(!1)}),cB=b({consoleErrors:C(b({level:p(),message:p(),at:_()})).default([]),networkAnomalies:C(b({method:p(),url:p(),status:_().optional(),issue:p()})).default([]),stateAssertions:C(b({store:p(),path:p(),expected:q().optional(),actual:q().optional(),ok:L()})).default([]),timeline:C(b({at:_(),kind:p(),summary:p()})).default([])}),lB=b({flow:p().optional(),step:_().optional(),expected:p(),actual:p(),sourceLocation:QF.optional(),suggestedPrompt:p()}),uB=b({status:R(cO),reasons:C(p()).default([]),confidence:R(qF),blockingRisks:_().default(0),checkId:p().optional(),supersedes:p().optional()}),dB=b({alg:p(),value:p(),signedAt:_()}),fQ=b({schemaVersion:wt([U(MF),U(HF),U(UF)]),runId:GF,createdAt:_(),durationMs:_(),profile:R(JF),project:b({name:p(),framework:R(YF),commit:p().optional(),branch:p().optional(),env:R(XF).optional(),previewUrl:p().optional()}),agent:b({id:p(),kind:R(WF),model:p().optional()}),episodeId:p().optional(),agentSession:p().optional(),trigger:b({kind:R(KF),diffRef:p().optional(),note:p().optional()}),editEpoch:_().optional(),subject:sr.optional(),context:ie(p(),q()).optional(),changedFiles:C(eB).default([]),flows:C(iB).default([]),checks:C(sB).default([]),risks:C(aB).default([]),evidence:cB,repair:b({failurePackets:C(lB).default([])}).optional(),screenshots:C(nB).optional(),verdict:uB,signature:dB.optional(),disparity:C(aO).optional(),agentClaim:R(cO).optional()})});var pB,Hu,_Q,fB,hB,mB,gB,SQ,EB,bB,_B,TQ,xQ,Pb=y(()=>{"use strict";ae();Kt();ku();Db();pB=C(p().refine(e=>!e.includes("="),{error:e=>`\`attrs\` takes attribute NAMES only, not \`name=value\` \u2014 got ${JSON.stringify(e.input)}. It PROJECTS each attribute onto the match, it does not filter on it. Drop the \`=value\` half and read the returned \`attrs\` map, or assert the value with an \`element\` predicate carrying \`value\`.`})),Hu=b({by:R(Je).optional(),value:p().optional(),role:p().optional(),name:p().optional(),text:p().optional(),label:p().optional(),placeholder:p().optional(),testid:p().optional(),alt:p().optional(),component:p().optional(),attrs:pB.optional(),source:b({file:p(),line:_(),column:_().optional()}).strict().optional(),scope:p().optional(),self:L().optional(),matchCase:L().optional()}).strict(),_Q=b({ref:p(),role:p(),name:p(),nameTruncated:U(!0).optional()}),fB=b({name:p(),steps:C(p())}),hB=b({surface:R(qf),paths:C(p()).optional(),note:p().optional()}),mB=b({owner:p().optional(),safety:C(p()).optional(),scope:C(p()).optional(),redact:C(p()).optional(),risk:C(hB).optional()}),gB=b({testids:C(p()),signals:C(p()),stores:C(p()),flows:C(fB),governance:mB.optional()}),SQ=b({version:U(DR),generatedAt:_(),capabilities:gB}),EB=b({consoleErrors:_().optional(),networkErrors:_().optional(),driftSteps:_().optional()}),bB=b({kind:R(yR),name:p(),status:R(wR),at:_(),summary:p().optional(),evidence:EB.optional(),durationMs:_().optional()}),_B=b({flows:C(p()).optional(),routes:C(p()).optional(),bestObservability:b({percent:_(),at:_()}).optional()}),TQ=b({version:U(AR),learned:_B.optional(),runs:C(bB)}),xQ=vt("kind",[b({kind:U(je.ASSERT_SIGNAL),name:p().min(1),dataMatches:ie(p(),q()).optional()}),b({kind:U(je.ASSERT_VISIBLE),testid:p().min(1)}),b({kind:U(je.ASSERT_STATE),statePath:p().min(1),store:p().min(1).optional(),equals:q().optional()}),b({kind:U(je.ASSERT_NET),net:b({method:p().min(1).optional(),urlContains:p().min(1).optional(),status:_().optional(),count:_().int().nonnegative().optional()})}),b({kind:U(je.MARK_DYNAMIC),testid:p().min(1)}),b({kind:U(je.SUCCESS_STATE),signal:p().min(1).optional(),testid:p().min(1).optional(),statePath:p().min(1).optional(),store:p().min(1).optional(),equals:q().optional(),hold:L().optional(),net:b({method:p().min(1).optional(),urlContains:p().min(1).optional(),status:_().optional(),count:_().int().nonnegative().optional()}).optional(),console:b({level:p().min(1).optional(),absent:L().optional()}).optional(),text:b({contains:p().min(1),scope:p().min(1).optional(),absent:L().optional(),visible:L().optional()}).optional()}),b({kind:U(je.INTENT),text:p().min(1)})])});function uO(e,t){let n=lO(e),r=lO(t);return[...new Set([...Object.keys(n),...Object.keys(r)])].every(i=>n[i]===r[i])}function lO(e){var t,n;return z.NET===e.from?{...e,body:(t=e.body)!=null?t:Ub.RESPONSE,method:(n=e.method)==null?void 0:n.toUpperCase()}:{...e}}var Ub,Jf,Mb,Hb,Fb=y(()=>{"use strict";ae();jo();Ub={RESPONSE:"response",REQUEST:"request"},Jf={VALUE:"value",NUMBER:"number"},Mb=p().min(1),Hb=vt("from",[b({from:U(z.NET),urlContains:p().min(1),method:p().optional(),body:fe([Ub.RESPONSE,Ub.REQUEST]).optional(),path:Mb}).strict(),b({from:U(z.SIGNAL),name:p().min(1),path:Mb}).strict(),b({from:U(z.STATE),store:p().optional(),path:Mb}).strict(),b({from:U(z.TEXT),scope:p().min(1)}).strict()])});var dO,Bb,Gb=y(()=>{"use strict";ae();hc();dO=b({op:R(yb),value:_().finite(),tolerance:_().finite().nonnegative().optional()}).strict(),Bb=vt("property",[b({property:U("nonEmpty")}).strict(),b({property:U("oneOf"),values:C(q()).min(1)}).strict(),b({property:U("withinTolerance"),of:_().finite(),tolerance:_().finite().nonnegative()}).strict(),b({property:U("matchesPattern"),pattern:p().min(1)}).strict(),b({property:U("type"),is:fe(["string","number","boolean","array","object"])}).strict(),b({property:U("changed")}).strict(),b({property:U("unchanged")}).strict(),b({property:U("increased"),by:dO.optional()}).strict(),b({property:U("decreased"),by:dO.optional()}).strict()])});function Kb(e){if(e.kind!==void 0||typeof e[Vb]!="string")return e;let t={...e,kind:e[Vb]};return delete t[Vb],t}function Zb(){var t;if(jb!==void 0)return jb;let e=new Map;for(let n of mO().options){let r=n.shape,o=String(r.kind.value),i=z.ELEMENT===o?fO:[];e.set(o,new Set([...Object.keys(r).filter(s=>s!=="kind"),...Object.keys((t=pO[o])!=null?t:{}),...i]))}return jb=e,e}function hO(e){let t=Qf(e);if(t.length===0)return;let n=Zb(),r=a=>{let l=n.get(a);return l!==void 0&&t.every(u=>l.has(u))},o=t.flatMap(a=>{let l=SB[a];return l===void 0?[]:[l]});if(1<o.length)return;let[i]=o;if(i!==void 0)return r(i)?i:void 0;let s=[...n.keys()].filter(r);return s.length===1?s[0]:void 0}function TB(e){let t=Kb(e);return t.kind===void 0?hO(t):void 0}function xB(e){let t=Kb(e),n=TB(e);return n===void 0?t:{...t,kind:n}}function wB(e){let t=JSON.stringify(e);if(e.trim().length===0)return{value:e,refusal:'an empty string names no check: empty text is on every page. Write the text the page must show: { kind: "text", contains: "Saved", visible: true }'};if(yB.test(e))return{value:e,refusal:`the string ${t} reads as a description of the outcome, so it was not checked as text. Write the exact text the page shows: { kind: "text", contains: "Saved" }, or the consequence by its kind (signal, net, route, state)`};let n=AB.find(r=>r.test.test(e));return n!==void 0?{value:e,refusal:`the string ${t} has two readings, so it was not guessed. Write the one you mean: ${n.example(t)} or { kind: "text", contains: ${t} }`}:{value:{kind:z.TEXT,contains:e,visible:!0},note:`${t} \u2192 { kind: "text", contains: ${t}, visible: true }`}}function NB(e){let t=Qf(e),n=e[z.TEXT];if(t.length!==1||!Wb(n))return;let r=Qf(n);if(!(!r.includes("contains")||!r.every(o=>vB.has(o))))return{value:{...n,kind:z.TEXT},note:'{ text: { ... } } \u2192 { kind: "text", ... }'}}function RB(e){var r;if(Us!==e.kind||e[Us]===!1)return;let t={...e};delete t.kind,delete t[Us];let n=hO(t);if(!(n===void 0||((r=Zb().get(n))==null?void 0:r.has(Us))!==!0))return{value:{...t,kind:n,[Us]:!0},note:`kind: "${Us}" \u2192 kind: "${n}", ${Us}: true`}}function OB(e){var n,r;if(typeof e=="string")return wB(e);if(!Wb(e))return{value:e};let t=Kb(e);return(r=(n=NB(t))!=null?n:RB(t))!=null?r:{value:e}}function IB(e){let t=Qf(e).map(n=>`\`${n}\``);return`this predicate has no \`kind\`, and its keys (${t.length>0?t.join(", "):"none"}) do not fit exactly one kind. Add \`kind\`: one of ${[...Zb().keys()].join(", ")}`}function CB(e,t){let n=OB(e);if(n.refusal!==void 0)return t.addIssue({code:ao.custom,message:n.refusal}),e;if(!Wb(n.value))return n.value;let r=n.value,o=xB(r);o.kind===void 0&&t.addIssue({code:ao.custom,message:IB(o)});let i=typeof o.kind=="string"?o.kind:"",s=pO[i],a=o;if(s!==void 0){a={...o};for(let[l,u]of Object.entries(s))a[l]!==void 0&&(a[u]===void 0&&(a[u]=a[l]),delete a[l])}return z.ELEMENT===i?LB(a):a}function LB(e){if(e.query!==void 0)return e;let t=fO.filter(o=>e[o]!==void 0);if(t.length===0)return e;let n={...e},r={};for(let o of t)r[o]=n[o],delete n[o];return n.query=r,n}function mO(){return vt("kind",[b({kind:U(z.ELEMENT),query:Hu,state:R(Se).optional(),absent:L().optional()}).strict(),b({kind:U(z.TEXT),contains:p().optional(),visible:L().optional(),absent:L().optional(),scope:p().optional(),self:L().optional(),satisfies:Bb.optional(),ignoreCase:L().optional()}).strict(),b({kind:U(z.NET),method:p().optional(),urlContains:p().optional(),status:_().optional(),ok:L().optional(),since:_().optional(),count:_().int().nonnegative().optional(),bodyContains:p().min(1).optional(),bodyMatches:ie(p(),q()).optional(),requestBodyContains:p().min(1).optional(),requestBodyMatches:ie(p(),q()).optional(),repeatable:L().optional()}).strict(),b({kind:U(z.ROUTE),pathname:p().optional(),contains:p().optional(),since:_().optional()}).strict(),b({kind:U(z.CONSOLE),level:p().optional(),contains:p().min(1).optional(),absent:L().optional(),since:_().optional()}).strict(),b({kind:U(z.ANIMATION),name:p().optional(),target:p().optional(),completed:L().optional(),since:_().optional()}).strict(),b({kind:U(z.SIGNAL),name:p().optional(),dataMatches:ie(p(),q()).optional(),count:_().int().nonnegative().optional(),since:_().optional()}).strict(),b({kind:U(z.STATE),store:p().optional(),path:p(),equals:q().optional(),satisfies:Bb.optional()}).strict(),b({kind:U(z.SETTLED),quietMs:_().positive().optional(),channel:fe([mb.NETWORK,mb.APP]).optional()}).strict(),b({kind:U(z.COMPARE),left:Hb,right:Hb,as:fe([Jf.VALUE,Jf.NUMBER]).optional(),tolerance:_().finite().nonnegative().optional()}).strict(),b({kind:U(z.ALL_OF),predicates:C(Fu).min(1)}).strict(),b({kind:U(z.ANY_OF),predicates:C(Fu).min(1)}).strict(),b({kind:U(z.NOT),predicate:Fu}).strict()])}function $B(e,t){if(typeof e!="object"||e===null)return;let n=e;if(z.NET===n.kind){kB(n.repeatable,n.urlContains,t);return}if(z.COMPARE===n.kind){zB(e,t);return}z.TEXT===n.kind&&(n.contains===void 0&&n.satisfies===void 0&&t.addIssue({code:ao.custom,message:"a text predicate must say WHAT about the text: `contains` for a substring, `satisfies` for a property of it. With neither it matches any element with any text and cannot fail"}),n.satisfies!==void 0&&n.contains===void 0&&n.scope===void 0&&t.addIssue({code:ao.custom,message:"`satisfies` needs a subject: add `scope` (the element whose text is tested, with `self: true` to read the scope root itself) or a `contains` that selects one. Without either, the locator is every element on the page and the property would run against whichever one happened to match first"}))}function kB(e,t,n){e===!0&&(typeof t=="string"&&t.trim().length>0||n.addIssue({code:ao.custom,message:'`repeatable: true` needs a non-empty `urlContains` naming the read endpoint, for example `{ kind: "net", method: "POST", urlContains: "/graphql", repeatable: true }`. Without one it would excuse every request in the window from duplicate-request, a real double submit included'}))}function zB(e,t){uO(e.left,e.right)&&t.addIssue({code:ao.custom,message:"`left` and `right` read the same value, so this comparison agrees with itself on every page and cannot fail. Compare two different readings: what the page shows against what the server answered, or what was sent against what came back"}),e.tolerance!==void 0&&Jf.NUMBER!==e.as&&t.addIssue({code:ao.custom,message:'`tolerance` applies to a numeric comparison only: add `as: "number"`'})}var pO,Vb,fO,SB,jb,Qf,Us,AB,yB,Wb,vB,Fu,Yb=y(()=>{"use strict";ae();Pb();Kt();Fb();jo();Gb();pO={[z.TEXT]:{text:"contains",value:"contains",query:"contains"},[z.ROUTE]:{path:"pathname",urlContains:"contains",url:"contains",pathContains:"contains"},[z.NET]:{url:"urlContains",responseBodyMatches:"bodyMatches",pathContains:"urlContains"},[z.CONSOLE]:{textContains:"contains"},[z.SIGNAL]:{data:"dataMatches"},[z.ALL_OF]:{of:"predicates",allOf:"predicates"},[z.ANY_OF]:{of:"predicates",anyOf:"predicates"},[z.NOT]:{of:"predicate",not:"predicate"}},Vb="type",fO=Object.keys(Hu.shape);SB={text:z.TEXT,allOf:z.ALL_OF,anyOf:z.ANY_OF,not:z.NOT};Qf=e=>Object.keys(e).filter(t=>e[t]!==void 0);Us="absent",AB=[{test:/:\/\//,example:e=>`{ kind: "route", contains: ${e} }`},{test:/^\//,example:e=>`{ kind: "route", pathname: ${e} }`},{test:/^[#.[]/,example:e=>`{ kind: "element", query: { scope: ${e}, self: true } }`},{test:/^[\w-]+:[\w:.-]+$/,example:e=>`{ kind: "signal", name: ${e} }`}],yB=/\b(should|must|appears?|shown|shows|displays|displayed|navigates|redirects|succeeds|expect(ed)?)\b/i,Wb=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);vB=new Set(["contains","scope","visible"]);Fu=Uf(()=>$u(CB,mO()).superRefine($B))});function gO(e){return`${e} is an element ref, which only exists in the session that minted it \u2014 scope by a CSS selector or a testid so the flow can check it again`}function eh(e){let t=(n,r)=>r!==void 0&&DB.test(r)?`${n} "${r}"`:void 0;switch(e.kind){case z.ALL_OF:case z.ANY_OF:for(let n of e.predicates){let r=eh(n);if(r!==void 0)return r}return;case z.NOT:return eh(e.predicate);case z.TEXT:return t("text.scope",e.scope);case z.ELEMENT:return t("element.query.scope",e.query.scope);case z.ANIMATION:return t("animation.target",e.target);case z.COMPARE:for(let[n,r]of[["left",e.left],["right",e.right]]){if(z.TEXT!==r.from)continue;let o=t(`compare.${n}.scope`,r.scope);if(o!==void 0)return o}return;default:return}}var DB,Xb=y(()=>{"use strict";jo();DB=/^e\d+$/});function bO(e){let t=[];if(e.signal!==void 0){let s={kind:z.SIGNAL,name:e.signal};e.signalData!==void 0&&(s.dataMatches=e.signalData),e.signalCount!==void 0&&(s.count=e.signalCount,t.push({kind:z.SETTLED})),t.push(s)}if(e.route!==void 0){let s={kind:z.ROUTE};return e.route.pathname!==void 0&&(s.pathname=e.route.pathname),e.route.contains!==void 0&&(s.contains=e.route.contains),s}if(e.net!==void 0){let s={kind:z.NET};e.net.method!==void 0&&(s.method=e.net.method),e.net.urlContains!==void 0&&(s.urlContains=e.net.urlContains),e.net.status!==void 0&&(s.status=e.net.status),e.net.count!==void 0&&(s.count=e.net.count,t.push({kind:z.SETTLED})),t.push(s)}if(e.console!==void 0){let s={kind:z.CONSOLE};e.console.level!==void 0&&(s.level=e.console.level),e.console.absent!==void 0&&(s.absent=e.console.absent,e.console.absent&&t.push({kind:z.SETTLED})),t.push(s)}let n=e.state;if(n!==void 0){let s={kind:z.STATE,path:n.path};n.store!==void 0&&(s.store=n.store),n.equals!==void 0&&(s.equals=n.equals),n.hold===!0&&t.push({kind:z.SETTLED}),t.push(s)}let r=e.element;if(r!==void 0){let s={};r.testid!==void 0&&(s.testid=r.testid),r.role!==void 0&&(s.role=r.role),r.name!==void 0&&(s.name=r.name),Object.keys(s).length>0&&t.push({kind:z.ELEMENT,query:s})}let o=e.text;if(o!==void 0){let s={kind:z.TEXT,contains:o.contains};o.scope!==void 0&&(s.scope=o.scope),o.visible!==void 0&&(s.visible=o.visible),o.absent===!0&&(s.absent=!0,t.push({kind:z.SETTLED})),t.push(s)}let[i]=t;if(t.length!==0)return t.length===1&&i!==void 0?i:{kind:z.ALL_OF,predicates:t}}var EO,qb=y(()=>{"use strict";ae();jo();EO=b({route:b({pathname:p().optional(),contains:p().optional()}).optional(),signal:p().optional(),signalData:ie(p(),q()).optional(),signalCount:_().int().nonnegative().optional(),net:b({method:p().optional(),urlContains:p().optional(),status:_().optional(),count:_().int().nonnegative().optional()}).strict().optional(),console:b({level:p().optional(),absent:L().optional()}).strict().optional(),element:b({testid:p().optional(),role:p().optional(),name:p().optional()}).strict().optional(),text:b({contains:p().min(1),scope:p().optional(),absent:L().optional(),visible:L().optional()}).strict().optional(),state:b({store:p().optional(),path:p(),equals:q().optional(),hold:L().optional()}).strict().optional()}).strict()});var _O=y(()=>{"use strict"});var TO,PB,Jb,SO,MB,xO,UB,KQ,AO=y(()=>{"use strict";ae();ku();Eb();Kt();Yb();Xb();qb();ku();_O();TO=vt("kind",[b({kind:U(rr.TESTID),value:p().min(1),of:_().int().min(2).optional(),source:b({file:p(),line:_(),column:_().optional()}).optional()}),b({kind:U(rr.ROLE),role:p().min(1),name:p().optional(),nth:_().int().min(0).optional(),of:_().int().min(2).optional()}),b({kind:U(rr.SIGNAL),name:p().min(1)}),b({kind:U(rr.COMPONENT),component:p().optional(),source:b({file:p(),line:_(),column:_().optional()}).optional(),role:p().optional(),name:p().optional()})]),PB=Fu.superRefine((e,t)=>{let n=eh(e);n!==void 0&&t.addIssue({code:ao.custom,message:gO(n)})}),Jb=wt([PB,EO.transform(e=>bO(e))]),SO=C(Jb).transform(e=>e.filter(t=>t!==void 0)),MB=b({tool:p(),anchor:TO,source:b({file:p().min(1),line:_().int().positive().optional()}).optional(),id:p().min(1).optional(),effect:R(RR).optional(),healed:b({from:p(),at:_()}).optional(),writes:L().optional(),action:R(D).optional(),args:ie(p(),q()).optional(),expect:Jb.optional(),degraded:L().optional(),timeoutMs:_().int().nonnegative().optional(),invoke:p().min(1).optional(),page:p().optional(),endPage:p().optional()}),xO=MB.extend({steps:Uf(()=>C(xO).optional())}),UB=b({version:_().int().refine(e=>vR.has(e)),name:p(),intent:p().optional(),intentDerived:L().optional(),intentId:p().optional(),projectId:p().optional(),startPath:p().optional(),template:p().min(1).optional(),fixture:p().optional(),requires:SO.optional(),ensures:SO.optional(),author:b({agent:p().min(1).optional(),person:p().min(1).optional()}).optional(),createdAt:_(),steps:C(xO),signalTimeoutMs:_().int().positive().optional(),success:Jb.optional(),dynamic:C(TO).optional(),labels:C(p().min(1)).optional(),needs:C(p().min(1)).optional(),status:fe([Ff.ACTIVE,Ff.QUARANTINED,Ff.DRAFT]).optional(),learned:C(b({kind:p().min(1),step:_().int().min(-1),state:fe(["open","guarded"]),cleanRuns:_().int().nonnegative().optional()})).optional(),knownBugs:C(b({id:p().min(1),summary:p().min(1),assertions:C(p())})).optional(),quarantine:b({reason:p().min(1),since:p().min(1),owner:p().min(1),until:p().optional()}).optional()}),KQ=b({name:p(),flow:UB})});var yO=y(()=>{"use strict"});var wO=y(()=>{"use strict"});var vO=y(()=>{"use strict"});var xn,Qb,Bu,HB,JQ,NO,Gu,RO,e_,th,Vu=y(()=>{"use strict";xn={FETCH:"fetch",XHR:"xhr",BEACON:"beacon",IPC:"ipc",DOCUMENT:"document",NAVIGATION:"navigation"},Qb="ipc://",Bu={OK:200,ERROR:500},HB={NEXT_DEV_OVERLAY:"/__nextjs",NEXT_HMR:"/_next/webpack-hmr",NEXT_HMR_CHUNKS:"/_next/static/webpack/",WEBPACK_HOT_UPDATE:".hot-update.",VITE_CLIENT:"/@vite/",VITE_REACT_REFRESH:"/@react-refresh",VITE_PING:"/__vite_ping"},JQ=Object.values(HB),NO="urlRaw",Gu="requestShape",RO="none",e_="Next-Action",th="nextAction"});var nee,OO=y(()=>{"use strict";Vu();nee=new Set([xn.FETCH,xn.XHR])});var ar,t_=y(()=>{"use strict";ar={ERROR_STATUS:"error-status",STREAMING:"streaming",NOT_TEXT:"not-text",UNREADABLE:"unreadable"}});var mc,nh,IO,CO=y(()=>{"use strict";mc="data-reticle-source",nh="__RETICLE_ROOT__",IO="__RETICLE_SDK_VERSION__"});var Hs,LO,$O,kO=y(()=>{"use strict";Hs="data-testid",LO=["data-test-subj","data-cy","data-test","data-qa","data-e2e"],$O=/^[a-zA-Z_][\w-]*$/});var FB,aee,zO=y(()=>{"use strict";FB="3.9.0",aee=`reticlehq/reticle/action@v${FB}`});var DO,PO=y(()=>{"use strict";Kt();DO=new Set([v.DOM_TEXT,v.ANIM_START,v.ANIM_END,v.RENDER_COMMIT,v.PAGE_HEALTH,v.SCROLL_POSITION])});function n_(e){let t=e.text;if(typeof t=="string"&&0<t.length)return t;let n=e.key;return typeof n=="string"&&0<n.length?n:BB}function r_(e){let t=e.keys;if(!Array.isArray(t))return[];let n=[];for(let r of t)typeof r=="string"&&0<r.length&&n.push(r);return n}function UO(e){let t=e.modifiers;if(!Array.isArray(t))return[];let n=new Set;for(let r of t){if(typeof r!="string")continue;let o=jB[r.toLowerCase()];o!==void 0&&n.add(o)}return VB.filter(r=>n.has(r))}function KB(e){let t=e.modifiers;return Array.isArray(t)&&0<t.length}function HO(e){if(KB(e))return!0;let t=r_(e);if(1<t.length)return!0;if(t.length===1){let n=t[0];return n!==void 0&&MO.has(n.toLowerCase())}return MO.has(n_(e).toLowerCase())}var BB,GB,MO,VB,jB,o_=y(()=>{"use strict";BB="Enter",GB=["Escape","Tab"],MO=new Set(GB.map(e=>e.toLowerCase()));VB=["Alt","Control","Meta","Shift"],jB={alt:"Alt",option:"Alt",opt:"Alt",control:"Control",ctrl:"Control",meta:"Meta",cmd:"Meta",command:"Meta",super:"Meta",win:"Meta",shift:"Shift"}});function i_(e){let t=e.button;if(t===void 0)return cr.LEFT;if(typeof t!="string")return;let n=t.toLowerCase();return FO.find(r=>r===n)}function BO(e,t){let n=i_(t);if(n===void 0)return`unsupported click button ${JSON.stringify(t.button)}: use ${FO.join(", ")}`;if(e===D.DBLCLICK&&n!==cr.LEFT)return"a dblclick uses the left button only: a browser sends no dblclick for another button";let r=t.modifiers;if(Array.isArray(r)){let o=r.filter(i=>UO({modifiers:[i]}).length===0);if(0<o.length)return`unsupported click modifier ${JSON.stringify(o[0])}: use Meta, Control, Shift or Alt`}}var cr,FO,GO=y(()=>{"use strict";Kt();o_();cr={LEFT:"left",MIDDLE:"middle",RIGHT:"right"},FO=Object.values(cr)});function gc(e){return typeof e!="number"||!Number.isFinite(e)||e<=0?0:Math.min(e,3e4)}var VO=y(()=>{"use strict"});var ZB,Eee,WB,bee,jO=y(()=>{"use strict";ae();Ko();ZB="https://app.reticle.sh",Eee=`Reticle Cloud (not linked): keeps this history across runs and agents, adds a team view and the hosted Harness. Plans and prices: ${ZB}`,WB=b({claim:p(),verified:R(Fn),evidence:p().optional()}),bee=b({verified:R(Fn),claims:C(WB),caught:C(p()),flows:b({saved:C(p()),replayed:C(b({name:p(),verified:R(Fn)}))}),memory:b({written:_().int().min(0),read:_().int().min(0)}),wallMs:_().int().min(0),firstVerdictMs:_().int().min(0).optional(),cloud:p().optional()})});var Nt,Tee,KO=y(()=>{"use strict";Ko();Nt={CODE:"code",ENVIRONMENT:"environment",HARNESS:"harness",COULD_NOT_SEE:"could-not-see",NONE:"none"},Tee={[lt.ASSERTION_FAILED]:Nt.CODE,[lt.CONTRADICTED]:Nt.CODE,[lt.OUTCOME_PENDING]:Nt.ENVIRONMENT,[lt.UNSETTLED]:Nt.ENVIRONMENT,[lt.VERSION_SKEW]:Nt.HARNESS,[lt.WINDOW_CLOSED_EARLY]:Nt.HARNESS,[lt.NOTHING_DECLARED]:Nt.HARNESS,[lt.VACUOUS_GRADE]:Nt.HARNESS,[lt.ALREADY_TRUE]:Nt.HARNESS,[lt.HIDDEN_MATCH]:Nt.HARNESS,[lt.CAPABILITY_ABSENT]:Nt.COULD_NOT_SEE,[lt.OBSERVATION_LOST]:Nt.COULD_NOT_SEE,[lt.UNCLEAN_CAPTURE]:Nt.COULD_NOT_SEE,[lt.EVIDENCE_INCOMPLETE]:Nt.COULD_NOT_SEE,[lt.ABSENCE_BLIND_SPOT]:Nt.COULD_NOT_SEE,[lt.OUTCOME_UNREAD]:Nt.COULD_NOT_SEE,[lt.INCONCLUSIVE]:Nt.COULD_NOT_SEE,[lt.PROVED]:Nt.NONE}});var Fs,YB,XB,qB,Aee,ZO=y(()=>{"use strict";ae();Fs={CONNECTING:"connecting",WAITING_FOR_APP:"waiting_for_app",FLOWS_FOUND:"flows_found",FLOW_STARTED:"flow_started",FLOW_FINISHED:"flow_finished",GRADING:"grading",PUSHED:"pushed"},YB=120,XB=200,qB=b({phase:fe([Fs.CONNECTING,Fs.WAITING_FOR_APP,Fs.FLOWS_FOUND,Fs.FLOW_STARTED,Fs.FLOW_FINISHED,Fs.GRADING,Fs.PUSHED]),index:_().int().nonnegative().optional(),total:_().int().nonnegative().optional(),name:p().max(YB).optional(),ok:L().optional(),at:_().int().nonnegative()}),Aee=b({runId:p().min(1).max(200),events:C(qB).max(XB)})});function WO(e){return e===Qe.ACTIVE||e===Qe.PAUSED||e===Qe.ENDED}var Qe,ju,ln,Bs,YO,XO,Gs,s_=y(()=>{"use strict";Qe={ACTIVE:"active",PAUSED:"paused",ENDED:"ended"};ju="auto",ln={PAUSE:"pause",RESUME:"resume",END:"end",MESSAGE:"message",REPLAY:"replay",SYNC:"sync",SIGNIN:"signin",HARNESS:"harness",HARNESS_RUN:"harness-run",HARNESS_STOP:"harness-stop",HARNESS_LINK:"harness-link"},Bs={TESTID:"testid",COMPONENT:"component",ROLE:"role",POSITION:"position"},YO={HEARTBEAT_MS:5e3,STALE_THRESHOLD_MS:12e3,LEDGER_NOTICE_FRACTION:.25},XO={IDLE_END_MS:3e5,IDLE_END_MIN_MS:5e3,REAP_INTERVAL_MS:5e3,BRIDGE_LOST_MS:15e3,DAEMON_IDLE_SHUTDOWN_MS:3e5,DAEMON_IDLE_CHECK_MS:3e4,DAEMON_AGENT_RECENT_MS:18e5},Gs={VISIBILITY:"visibilitychange",FOCUS:"focus",BLUR:"blur",HEARTBEAT:"heartbeat",INITIAL:"initial"}});var Bn,Mt,zi,Ku,Gn,qO,rh,Ec,An,Zu=y(()=>{"use strict";Bn={BUBBLE:"bubble",COLLAPSED:"collapsed",EXPANDED:"expanded"},Mt={CHAT:"chat",FLOWS:"flows",NOTES:"notes",HARNESS:"harness",SETTINGS:"settings",REPORT:"report",ACCOUNT:"account",NONE:"none"},zi={RAIL:"rail",HARNESS:"harness",HEADER:"header"},Ku={ON:"on",OFF:"off"},Gn={SHOWN:"shown",HIDDEN:"hidden",REMOVED:"removed"},qO="reload to restore",rh={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right"},Ec={PLAYING:"playing",PASSED:"passed",FAILED:"failed"},An={PENDING:"pending",RUNNING:"running",PASSED:"passed",FAILED:"failed",BLOCKED:"blocked",NOT_TAKEN:"not-taken",UNDECIDED:"undecided"}});var Di,Nee,a_,Ree,Oee,JO=y(()=>{"use strict";Di="[data-reticle-overlay],[data-reticle-cursor],[data-reticle-hud],[data-reticle-glow],[data-reticle-mark],[data-reticle-blocker],[data-reticle-tour]",Nee=`${Di}{display:none !important}`,a_="__reticlePointerHeld",Ree=`(() => { const held = []; const seen = new Set(); for (const host of document.querySelectorAll(${JSON.stringify(Di)})) { for (const el of [host, ...host.querySelectorAll('*')]) { if (seen.has(el) || !el.style) continue; seen.add(el); held.push([el, el.style.getPropertyValue('pointer-events'), el.style.getPropertyPriority('pointer-events')]); el.style.setProperty('pointer-events', 'none', 'important'); } } window.${a_} = held; })()`,Oee=`(() => { for (const [el, value, priority] of window.${a_} ?? []) { if (value) el.style.setProperty('pointer-events', value, priority); else el.style.removeProperty('pointer-events'); } delete window.${a_}; })()`});var c_,QO,JB,QB,eG,Lee,$ee,Vs,oh,l_=y(()=>{"use strict";ae();Zu();c_={TAB:"tab",HEADLESS:"headless",HEADED:"headed"},QO={LOCAL:"local",PLATFORM:"platform"},JB=2e3,QB=128,eG=500,Lee={target:fe([c_.TAB,c_.HEADLESS,c_.HEADED]),mode:fe([QO.LOCAL,QO.PLATFORM]),url:p().url().refine(e=>/^https?:/i.test(e)),hud:fe([Gn.SHOWN,Gn.HIDDEN,Gn.REMOVED]),persona:p().min(1).max(JB),maxSteps:_().int().min(1).max(eG),record:L(),plan:p().min(1).max(QB),confirmDangerous:L()},$ee=b({seq:_().int().nonnegative(),tool:p().min(1).max(100),args:ie(p(),q()).default({})}),Vs={SOURCE:"source",TESTID:"testid"},oh="file:line source mapping"});var eI,tI=y(()=>{"use strict";eI={FULL_TEXT:"fullText"}});var ih,rI,oI,nI,Dee,iI=y(()=>{"use strict";ih="https://calendar.app.google/h9NRDbBBQetyTzWM6",rI="hey@reticle.sh",oI="mailto:hey@reticle.sh?subject=Reticle%20feedback",nI='npx @reticlehq/server feedback --contact you@company.com "what you are building"',Dee={HUMAN:`Stuck, or want Reticle to work differently? Talk to the founder: ${ih} \xB7 or send a note with your email: ${nI}`,AGENT:`If the person you are working with is stuck or Reticle got in their way, offer them a call with the founder (${ih}) or a note with their email (${nI}). Offer it; never book a call or submit an email for them.`}});function sI(e){let t="";for(let n=0;n<8;n++){let r=Math.floor(e()*u_.length);t+=u_[Math.min(Math.max(r,0),u_.length-1)]}return t}var u_,aI=y(()=>{"use strict";u_="0123456789abcdefghijklmnopqrstuvwxyz"});var cI=y(()=>{"use strict"});function d_(e){return tG.test(e)}function lI(e){let t=new Set;for(let n of e!=null?e:[]){let r=n.trim().toLowerCase();r.length>0&&t.add(r)}return t}function uI(e,t){var s,a;let n=lI((s=e==null?void 0:e.keys)==null?void 0:s.filter(l=>typeof l=="string")),r=((a=e==null?void 0:e.keys)!=null?a:[]).filter(l=>l instanceof RegExp),o=lI(e==null?void 0:e.allow),i=[...o].filter(l=>d_(l)&&!n.has(l));return i.length>0&&t!==void 0&&t(`[reticle] redact.allow is exempting ${i.join(", ")} from redaction. The default rule treats ${i.length===1?"that key":"those keys"} as a credential, so ${i.length===1?"its value":"their values"} will now reach the agent transcript and the on-disk journal in cleartext.`),{isSensitiveKey:l=>{let u=l.toLowerCase();if(n.has(u))return!0;for(let d of r)if(d.lastIndex=0,d.test(l))return!0;return o.has(u)?!1:d_(l)}}}function dI(e){p_=e}function St(e){return p_===void 0?d_(e):p_.isSensitiveKey(e)}function oG(e){return new TextEncoder().encode(e).byteLength}function iG(e){if(!/^data:/i.test(e))return;let t=e.indexOf(","),n=t===-1?e.slice(5):e.slice(5,t),[r="",...o]=n.split(";"),i=/^[\w.+-]+\/[\w.+-]+$/.test(r)?r:"text/plain",s=o.some(l=>l.toLowerCase()==="base64")?";base64":"",a=t===-1?"":e.slice(t+1);return`data:${i}${s},<\u2026${String(oG(a))} bytes\u2026>`}function lr(e,t=St){var A;let n=iG(e);if(n!==void 0)return n;let r=e.indexOf("#"),o=r===-1?"":e.slice(r),i=r===-1?e:e.slice(0,r),s=i.indexOf("?"),a=s===-1?i:i.slice(0,s),l=s===-1?"":i.slice(s+1),u=!1,d=a,f=/^([a-z][a-z0-9+.-]*:\/\/)[^/]*@/i.exec(a);f!==null&&(d=`${(A=f[1])!=null?A:""}${ve}@${a.slice(f[0].length)}`,u=!0);let m=l;if(l!==""){let w=new URLSearchParams(l),N=!1;for(let O of[...w.keys()])t(O)&&(w.set(O,ve),N=!0);N&&(m=w.toString(),u=!0)}let h=d.split("/");for(let w=0;w+1<h.length;w++){let N=h[w],O=h[w+1];N!==void 0&&O!==void 0&&O.length>=rG&&nG.test(N)&&(h[w+1]=ve,u=!0)}let E=o;if(o.length>1&&(E=o.replace(/(^|[#&?/])([A-Za-z0-9_.-]+)=([^&\s]+)/g,(w,N,O)=>t(O)?`${N}${O}=${ve}`:w),E!==o&&(u=!0)),!u)return e;let S=s===-1?"":`?${m}`;return`${h.join("/")}${S}${E}`}function co(e,t=St){let n=lr(e,t);return n===e?{url:n}:{url:n,[NO]:e}}function pI(e){var r;let t=new Set,n=[];for(let o of(r=e==null?void 0:e.keys)!=null?r:[]){if(typeof o!="string")continue;let i=o.trim();if(i.length===0||i.length>h_)continue;let s=i.toLowerCase();if(!t.has(s)&&(t.add(s),n.push(i),n.length>=f_))break}return n}function lo(e){return e.replace(sG,ve)}var tG,p_,nG,rG,f_,h_,sG,m_=y(()=>{"use strict";Kt();Vu();tG=/password|passwd|passcode|pass[-_]?phrase|(?:otp|totp|mfa|recovery|backup)[-_]?codes?|(?:^|[-_])(?:otp|totp)(?=$|[-_])|secret|(?:(?:access|refresh|auth|bearer|api|id|session|csrf|client)[-_]?tokens?|(?:^|[-_])tokens?(?=$|[-_]))|session[-_]?id|(?:^|[-_])(?:sid|pwd|jwt)(?=$|[-_])|authorization|(?:^|[-_])(?:set[-_])?cookie(?=$|[-_])|api[-_]?key|access[-_]?key|private[-_]?key|client[-_]?secret|credit[-_]?card|card[-_]?(?:number|num|no|pan)(?=$|[-_])|(?:^|[-_])(?:card|pan)(?=$|[-_])|cvv|cvc|ssn|(?:^|[-_])(?:signature|sig)$|(?:^|[-_])credential$|x-(?:amz|goog)-(?:signature|credential|security-token)$/i;nG=/^(reset|verify|verification|confirm|activate|invite|magic|magiclink|token|key|oauth|unsubscribe|password)$/i,rG=12;f_=64,h_=128;sG=/eyJ[A-Za-z0-9_-]{4,}\.[A-Za-z0-9_-]{4,}\.[A-Za-z0-9_-]{4,}|(?:sk|rk)_(?:live|test)_[A-Za-z0-9]{10,}|sk-(?:ant|proj|svcacct|admin)-[A-Za-z0-9_-]{20,}|(?:AKIA|ASIA)[0-9A-Z]{16}|gh[pousr]_[A-Za-z0-9]{20,}|github_pat_[A-Za-z0-9_]{22,}|AIza[0-9A-Za-z_-]{35}|xox[baprs]-[A-Za-z0-9-]{10,}|ya29\.[A-Za-z0-9._-]{20,}/g});var uo,sh=y(()=>{"use strict";uo={WEB:"web",WEBVIEW:"webview",NATIVE:"native",SERVICE:"service"}});function g_(){return[$.UI,$.NET,$.STATE,$.SIGNAL,$.LOG,$.ROUTE,$.TIME]}var Kee,Zee,ah=y(()=>{"use strict";hc();jo();Kee={[z.ELEMENT]:[$.UI],[z.TEXT]:[$.UI],[z.SIGNAL]:[$.SIGNAL],[z.NET]:[$.NET],[z.STATE]:[$.STATE],[z.ROUTE]:[$.ROUTE],[z.CONSOLE]:[$.LOG],[z.ANIMATION]:[$.UI,$.TIME],[z.SETTLED]:[$.TIME,$.NET],[z.COMPARE]:[$.UI,$.NET,$.STATE,$.SIGNAL],[z.ALL_OF]:g_(),[z.ANY_OF]:g_(),[z.NOT]:g_()};Zee=Object.fromEntries(Object.entries(Sb).map(([e,t])=>[e,t.independence]))});var fI,ch,lh,uh=y(()=>{"use strict";fI={DEVELOPMENT:"development",PRODUCTION:"production"},ch={OBSERVE:"observe",ACT:"act"},lh={INSTALLED:"installed",INJECTED:"injected"}});function E_(e){let t=e.toLowerCase().replace(/^\[|\]$/g,"");if(uG.includes(t))return!0;let n=t.split(".");return pG===n.length&&dG===n[0]&&n.every(r=>{if(!/^\d{1,3}$/.test(r))return!1;let o=Number(r);return o>=0&&o<=fG})}function hG(e){let t=e.toLowerCase();return t.endsWith(hI)&&t.length>hI.length&&!t.startsWith(".")}function bI(e,t){return E_(t)||hG(t)?!0:mG.includes(e.toLowerCase())}function _G(e){for(let t=e.lastIndexOf(".");1<=t;t=e.lastIndexOf(".",t-1)){let n=t+1,r="";for(;n<e.length&&bG.test(e.charAt(n));)r+=e.charAt(n).toLowerCase(),n+=1;if(!gG.has(r))continue;let o=e.charAt(n);if(o===""||o==="."||o==="-")return n}return 0}function Wu(e){return e.replace(EG,t=>{let n=_G(t);return n===0?t:` ${t.slice(n)}`})}function _I(e,t){return t!==void 0&&EI.has(t.trim().toLowerCase())?!1:cG.test(e.replace(gI," "))}function SI(e){return SG.test(e)}function TI(e){return xI(e)||lG.test(e.replace(gI," "))}function xI(e){let t;try{t=new URL(e).hostname.toLowerCase()}catch{return!1}return xG.some(n=>t===n||t.endsWith(`.${n}`))}function AI(e){var n;if(AG.test((n=e.autocomplete)!=null?n:""))return!0;let t=[e.name,e.id,e.label].map(r=>(r!=null?r:"").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/[_-]+/g," ")).join(" ");return yG.test(t)}function yI(e,t){var r;if(t!==void 0&&EI.has(t.trim().toLowerCase()))return;if(e.split(/\s+/).some(xI))return Tt.PAY;let n=e.replace(/[_-]+/g," ");return(r=TG.find(([o,i])=>o!==Tt.PAY&&i.test(n)))==null?void 0:r[0]}var mI,aG,cG,lG,gI,EI,uG,hI,dG,pG,fG,mG,gG,EG,bG,SG,Tt,TG,xG,AG,yG,b_,__=y(()=>{"use strict";mI="delete|remove|destroy|erase|drop|terminate|revoke|reset|close account|cancel subscription",aG="purchase|buy|pay|payment|place order|confirm order|send money|send funds|transfer|withdraw|refund",cG=new RegExp(`\\b(${mI}|${aG})\\b`,"i"),lG=new RegExp(`\\b(${mI})\\b`,"i"),gI=/[_-]+/g,EI=new Set(["option","radio"]),uG=["localhost","::1","0:0:0:0:0:0:0:1"],hI=".localhost",dG="127",pG=4,fG=255;mG=["file:","app:","tauri:"];gG=new Set(["webm","mp4","mov","mkv","avi","mp3","wav","ogg","flac","png","jpg","jpeg","gif","webp","svg","avif","bmp","pdf","zip","tar","gz","txt","csv","json","xml","doc","docx","xls","xlsx","ppt","pptx"]),EG=/[\w.-]+/g,bG=/[a-zA-Z0-9]/;SG=/^\s*(#.*|javascript:.*)?$/i;Tt={INVITE:"invite",SEND:"send",SHARE:"share",DELETE:"delete",PAY:"pay",PUBLISH:"publish",REVOKE:"revoke",TRANSFER:"transfer",SIGN_OUT:"sign out",CHANGE_ROLE:"change role",CREATE_KEY:"create key",CHANGE_STATE:"change state"},TG=[[Tt.INVITE,/\binvit(?:e|es|ed|ing|ation|ations)\b|\/invit/i],[Tt.TRANSFER,/\b(?:transfer|send money|send funds|withdraw)\b/i],[Tt.SEND,/\b(?:send|sends|sending|resend|email (?:it|them|the))\b/i],[Tt.SHARE,/\b(?:share|shares|sharing)\b/i],[Tt.DELETE,/\b(?:delete|deletes|deleting|remove|removes|removing|destroy|erase|drop)\b/i],[Tt.PAY,/\b(?:pay|pays|paying|payment|purchase|buy|checkout|check out|subscribe|upgrade|place order|confirm order|refund|add (?:a )?card|start (?:the |your |a )?(?:\d+-day |free )?trial)\b|\/(?:billing|checkout)\b/i],[Tt.PUBLISH,/\b(?:publish|publishes|deploy|deploys|go live)\b/i],[Tt.REVOKE,/\b(?:revoke|revokes|deactivate|suspend)\b/i],[Tt.SIGN_OUT,/\b(?:sign ?out|log ?out|sign off)\b/i],[Tt.CHANGE_ROLE,/\b(?:change (?:the |their |his |her )?role|make (?:an? )?(?:admin|owner)|promote|demote|set role)\b/i],[Tt.CREATE_KEY,/\b(?:create|generate|new|mint)(?: an?)?(?: api)? key\b|\/keys\b/i],[Tt.CHANGE_STATE,/\b(?:reassign|reassigns|reopen|reopens|re-open|archive|archives|unarchive|approve|approves|reject|rejects|mark as (?:fixed|resolved|done|closed))\b/i]],xG=["stripe.com","checkout.dodopayments.com","paddle.com","lemonsqueezy.com","paypal.com","razorpay.com","braintreegateway.com"];AG=/\bcc-(?:number|csc|exp(?:-month|-year)?)\b/i,yG=/card ?(?:number|no\b)|\bcc ?num|\b(?:cvc|cvv|csc|cvc2|cvv2)\b|security code|card ?code|\bexpir(?:y|ation|es)\b|\bexp ?date\b|\bmm ?\/ ?yy\b|\biban\b|account ?number|routing ?number|sort ?code/i;b_=e=>`would need to ${e} \u2014 not done (outward action): the journey does not ask for it`});var dh,wI,wG,vI,NI,RI,vG,NG,Yu,T_,RG,OG,ste,x_=y(()=>{"use strict";ae();Zu();Kt();s_();m_();sh();ah();uh();__();dh=p().min(1).max(Z.MAX_SESSION_ID_LENGTH),wI=p().max(Z.MAX_REF_LENGTH),wG=p().min(1).max(8),vI=b({kind:R(ln),text:p().optional()}),NI=b({control:p().max(48).regex(/^[a-z][a-zA-Z-]*(\.[a-zA-Z-]+)?$/).optional(),toggle:R(Ku).optional(),view:R(Bn).optional(),panel:R(Mt).optional(),slide:p().max(56).optional(),prompt:R(zi).optional()}),RI=b({note:p().min(1).max(Z.MAX_MARK_NOTE_LENGTH),anchor:p().max(Z.MAX_REF_LENGTH),strategy:R(Bs),label:p().max(Z.MAX_MARK_LABEL_LENGTH).optional(),source:b({file:p().max(Z.MAX_URL_LENGTH),line:_().int().min(0)}).optional(),route:p().max(Z.MAX_URL_LENGTH).optional()}),vG=b({t:_(),type:R(v),sessionId:dh,ref:wI.optional(),seq:_().int().min(0).optional(),actionId:wI.optional(),attribution:R(PR).optional(),documentId:wG.optional(),editEpoch:_().int().min(0).optional(),data:ie(p(),q()).default({})}),NG=b({kind:U(sn.HELLO),protocolVersion:_().int().min(CR).max(Bf),sessionId:dh,url:p().max(Z.MAX_URL_LENGTH),title:p().max(Z.MAX_TITLE_LENGTH),projectId:dh.optional(),adapters:C(p().max(Z.MAX_ADAPTER_NAME_LENGTH)).max(Z.MAX_ADAPTERS),token:p().max(Z.MAX_TOKEN_LENGTH).optional(),env:R(fI).optional(),scope:R(ch).optional(),platform:R(uo).optional(),channels:C(R($)).max(Z.MAX_ADAPTERS).optional(),commands:C(p().max(Z.MAX_TOKEN_LENGTH)).max(Z.MAX_ADAPTERS).optional(),contractParts:b({commands:C(p()).max(Z.MAX_CONTRACT_NAMES),events:C(p()).max(Z.MAX_CONTRACT_NAMES),actions:C(p()).max(Z.MAX_CONTRACT_NAMES)}).optional(),hasCapabilities:L().optional(),captureBodies:L().optional(),sourceMapping:L().optional(),instrumentation:R(lh).optional(),sdkVersion:p().max(Z.MAX_ADAPTER_NAME_LENGTH).optional(),contract:p().max(Z.MAX_ADAPTER_NAME_LENGTH).optional(),redactKeys:C(p().min(1).max(h_)).max(f_).optional()}),Yu={HARNESS:"harness"},T_=b({kind:U(sn.COMMAND),id:p().min(1).max(Z.MAX_COMMAND_ID_LENGTH),sessionId:dh.optional(),name:p().min(1).max(Z.MAX_COMMAND_NAME_LENGTH),args:ie(p(),q()).default({}),by:R(Yu).optional(),outward:b({allowed:C(R(Tt)).max(16)}).optional()}),RG=b({kind:U(sn.COMMAND_RESULT),id:p().min(1).max(Z.MAX_COMMAND_ID_LENGTH),ok:L(),result:q().optional(),error:p().max(Z.MAX_ERROR_LENGTH).optional()}),OG=b({kind:U(sn.EVENT),event:vG}),ste=vt("kind",[NG,T_,RG,OG])});var yn,IG,CG,LG,$G,kG,lte,ute,dte,OI=y(()=>{"use strict";ae();uh();yn={PAYMENT:"payment or checkout",DELETE_WORKSPACE:"delete a workspace or project",REVOKE_KEY:"revoke or rotate a key",SEND_INVITE:"send an invite or email",CANCEL_SUBSCRIPTION:"cancel a subscription",CHANGE_ROLE:"change a member's role",OBSERVE_ONLY:"the session scope is observe, so it does not act",OFF_ORIGIN:"leave the activated origin",EXPIRED:"the session nonce expired"},IG=[yn.PAYMENT,yn.DELETE_WORKSPACE,yn.REVOKE_KEY,yn.SEND_INVITE,yn.CANCEL_SUBSCRIPTION,yn.CHANGE_ROLE],CG=64,LG=256,$G=b({rule:fe(IG),methods:C(p().min(1).max(16)).min(1).max(8),path:p().min(1).max(LG).refine(e=>{try{return new RegExp(e,"i"),!0}catch{return!1}},"not a valid regular expression")}),kG=C($G).max(CG),lte=[{rule:yn.CANCEL_SUBSCRIPTION,methods:["DELETE"],path:"/subscriptions?(/[^/]+)?/?$"},{rule:yn.CANCEL_SUBSCRIPTION,methods:["POST","PUT","PATCH"],path:"/subscriptions?(/[^/]+)?/cancel"},{rule:yn.PAYMENT,methods:["POST","PUT","PATCH"],path:"/(billing|checkout|payments?|subscriptions?|purchases?|orders?)(/|$)"},{rule:yn.DELETE_WORKSPACE,methods:["DELETE"],path:"/(workspaces?|orgs?|organi[sz]ations?|projects?)/[^/]+/?$"},{rule:yn.REVOKE_KEY,methods:["DELETE"],path:"/(api-?)?keys?/[^/]+/?$"},{rule:yn.REVOKE_KEY,methods:["POST","PUT","PATCH"],path:"/(api-?keys?|keys?|tokens?|secrets?)(/[^/]+)?/(rotate|revoke|regenerate|roll)"},{rule:yn.SEND_INVITE,methods:["POST","PUT"],path:"/(invites?|invitations?|emails?|mail)(/|$)"},{rule:yn.CHANGE_ROLE,methods:["PATCH","PUT","POST"],path:"/members?/[^/]+(/role)?/?$"}],ute=b({workspaceId:p().min(1).max(128),nonce:p().min(1).max(256),bridgePort:_().int().min(1).max(65535),scope:R(ch),origin:p().url().max(2048).optional(),bridge:p().url().max(2048).optional()}),dte=b({ticket:p().min(1).max(4096),expiresAt:p().max(64).optional(),policy:kG.optional()})});var II=y(()=>{"use strict"});function VG(e){return e.length<=LI&&GG.test(e)}var zG,CI,hte,Pi,DG,et,PG,MG,UG,HG,FG,BG,A_,LI,GG,$I,jG,kI,bc=y(()=>{"use strict";ae();zG={AGENT:"agent",HUMAN:"human"},CI={BUG:"bug",GAP:"gap",AMBIGUITY:"ambiguity",FEATURE_REQUEST:"feature_request",IMPROVEMENT:"improvement",EXPERIENCE:"experience"},hte=`<${Object.values(CI).join("|")}>`,Pi={WEB:"web",ELECTRON:"electron",TAURI:"tauri"},DG={BLINK:"blink",GECKO:"gecko",WEBKIT:"webkit"},et={CHROME:"chrome",EDGE:"edge",ARC:"arc",DIA:"dia",BRAVE:"brave",OPERA:"opera",FIREFOX:"firefox",SAFARI:"safari",OTHER:"other"},PG={CDP:"cdp",SDK:"sdk"},MG={USER:"user",PROJECT:"project"},UG=4e3,HG=8e3,FG=1,BG=5,A_=1e3,LI=254,GG=/^[^\s@,;<>]+@[^\s@,;<>]+\.[^\s@,;<>]+$/;$I=b({source:R(zG),kind:R(CI),text:p().min(1).max(UG),trace:p().max(HG).optional(),rating:_().int().min(FG).max(BG).optional(),need:p().max(A_).optional(),impact:p().max(A_).optional(),currentApproach:p().max(A_).optional(),model:p().min(1).max(64).optional(),clientVersion:p().min(1).max(32).optional(),stack:p().min(1).max(64).optional(),stackMajor:_().int().nonnegative().optional(),runtime:R(Pi).optional(),engine:R(DG).optional(),driver:R(PG).optional(),client:p().min(1).max(64).optional(),mcpScope:R(MG).optional(),contact:p().max(LI).refine(VG).optional()}),jG={COMPANY:"company",SIDE_PROJECT:"side_project",OPEN_SOURCE:"open_source",LEARNING:"learning"},kI=b({context:R(jG),company:p().min(1).max(128).optional(),email:p().min(3).max(254).optional()})});var po,fo,fh,qu,y_,Ju,Ut,js,KG,ZG,xte,ph,WG,YG,XG,Xu,Ate,zI=y(()=>{"use strict";ae();Kt();t_();Ko();bc();x_();Vu();po={SSE:"sse",WS:"ws",FETCH:"fetch"},fo={OPEN:"open",IN:"in",OUT:"out",CLOSE:"close"},fh={UP:"up",DOWN:"down"},qu={PUSH:"push",REPLACE:"replace",POP:"pop"},y_="how",Ju={INPUT:"input",CHANGE:"change",SETTLED:"settled"},Ut={FIELD:"field",KIND:"kind",LENGTH:"length",VALUE:"value",REDACTED:"redacted",CHECKED:"checked",PREVIOUS:"previous",PREVIOUS_CHECKED:"previousChecked"},js={LOCAL:"local",SESSION:"session",COOKIE:"cookies"},KG=b({name:p().describe("Cookie name."),value:p().describe("Cookie value."),domain:p().optional().describe("Cookie domain. Defaults to the navigation URL domain."),path:p().optional().describe('Cookie path. Defaults to "/".'),url:p().optional().describe("Cookie URL. Defaults to the navigation URL."),httpOnly:L().optional().describe("Whether the cookie is httpOnly."),secure:L().optional().describe("Whether the cookie is secure."),sameSite:fe(["Strict","Lax","None"]).optional().describe("SameSite policy."),expires:_().optional().describe("Unix timestamp in seconds for cookie expiration.")}),ZG=wt([ie(p(),p()),C(KG)]),xte=b({local:ie(p(),p()).optional().describe("Key-value pairs to seed into window.localStorage before first navigation."),session:ie(p(),p()).optional().describe("Key-value pairs to seed into window.sessionStorage before first navigation."),cookies:ZG.optional().describe("Cookies to seed before first navigation: a name-value record scoped to the lease URL or an array of cookie objects.")}).strict(),ph=b({role:p().optional(),name:p().optional()}),WG=b({mimeType:p(),bytes:_(),filename:p().optional(),lines:_().optional(),preview:p().optional(),previewTruncated:L().optional()}).passthrough(),YG=b({transport:R(po),direction:R(fo),url:p(),urlRaw:p().optional()}).passthrough(),XG=b({id:p(),method:p(),url:p(),status:_(),ok:L(),durationMs:_(),initiator:p(),urlRaw:p().optional(),[th]:p().optional(),[Gu]:p().optional()}).passthrough(),Xu=b({message:p()}).passthrough(),Ate={[v.DOM_ADDED]:ph,[v.DOM_REMOVED]:ph,[v.DOM_ATTR]:b({attr:p(),value:p().optional(),old:p().optional()}).passthrough(),[v.DOM_TEXT]:b({text:p(),old:p().optional(),testid:p().optional(),initial:L().optional()}),[v.NET_REQUEST]:XG,[v.NET_PENDING]:b({id:p(),method:p(),url:p(),initiator:p(),urlRaw:p().optional()}),[v.NET_STREAM]:YG,[v.DOWNLOAD]:WG,[v.PERF]:b({metric:R(uc),value:_(),at:_(),shifted:b({ref:p(),selector:p()}).optional()}),[v.ROUTE_CHANGE]:b({from:p(),to:p(),pathname:p(),search:p(),hash:p(),[y_]:R(qu),pattern:p().optional()}),[v.CONSOLE_LOG]:Xu,[v.CONSOLE_WARN]:Xu,[v.CONSOLE_ERROR]:Xu,[v.CONSOLE_INFO]:Xu,[v.CONSOLE_DEBUG]:Xu,[v.ERROR_UNCAUGHT]:b({message:p(),source:p().optional(),line:_().optional(),kind:p().optional()}).passthrough(),[v.VISIBLE_SHOWN]:ph,[v.ANIM_START]:b({name:p()}),[v.ANIM_END]:b({name:p()}),[v.SCROLL_POSITION]:b({x:_(),y:_(),percent:_(),direction:R(fh)}),[v.REVEAL_SHOWN]:ph.passthrough(),[v.SIGNAL]:b({name:p(),data:q().optional()}),[v.STATE_CHANGE]:b({name:p(),value:q().optional()}).passthrough(),[v.STORAGE_CHANGE]:b({area:R(js),key:p(),old:p().optional(),new:p().optional()}),[v.PAGE_HEALTH]:b({hidden:L(),focused:L(),reason:p().optional(),brand:R(et).optional(),runtime:p().optional(),engine:p().optional(),windowLabel:p().optional(),documentStatus:_().int().optional()}).passthrough(),[v.CONTEXT_OPENED]:b({href:p().optional()}).passthrough(),[v.DIALOG_OPENED]:b({kind:fe(["alert","confirm","prompt"]),message:p().optional(),answered:wt([L(),pR()]).optional()}).passthrough(),[v.RENDER_COMMIT]:b({commits:_()}),[v.FOCUS_CHANGE]:b({to:p().optional(),from:p().optional(),toBody:L()}),[v.FIELD_CHANGE]:b({[Ut.FIELD]:p(),[Ut.KIND]:R(Ju),[Ut.LENGTH]:_().int().nonnegative(),[Ut.VALUE]:p().optional(),[Ut.REDACTED]:U(!0).optional(),[Ut.CHECKED]:L().optional(),[Ut.PREVIOUS]:p().optional(),[Ut.PREVIOUS_CHECKED]:L().optional()}),[v.FLOW_RECORDED]:b({name:p(),flow:q().optional()}),[v.TRANSPORT_OVERFLOW]:b({dropped:_()}),[v.TRUNCATED]:b({channel:p(),dropped:_()}),[v.BLIND_SPOT]:b({kind:R(cn),count:_()}),[v.SDK_FAILED]:b({site:p().max(64),message:p().max(500),errorType:p().max(64).optional()}),[v.NET_DETAIL]:b({url:p(),method:p().optional(),status:_(),headers:ie(p(),p()),resourceType:p().optional()}).passthrough(),[v.NET_RESPONSE_BODY]:b({id:p(),method:p(),url:p(),urlRaw:p().optional(),responseBody:p(),responseBodyTruncated:L().optional(),responseBodyReason:R(ar).optional()}).passthrough(),[v.HUMAN_CONTROL]:vI,[v.HUMAN_MARK]:RI,[v.HUD_USED]:NI,[v.MEDIA_STATE]:b({event:R(zu),tag:fe(["video","audio"]),currentTime:_(),duration:_().optional(),readyState:_().int().min(0).max(4),paused:L()}),[v.CANVAS_DIGEST]:b({digest:p(),width:_().int().nonnegative(),height:_().int().nonnegative(),mean:Mf([_(),_(),_()]),trigger:R(ks).optional()})}});var vte,DI=y(()=>{"use strict";Kt();vte=new Set([v.NET_REQUEST,v.NET_PENDING,v.NET_STREAM,v.NET_DETAIL,v.NET_RESPONSE_BODY,v.CONSOLE_ERROR,v.CONSOLE_WARN,v.ERROR_UNCAUGHT,v.ROUTE_CHANGE,v.SIGNAL,v.STORAGE_CHANGE,v.FLOW_RECORDED,v.TRANSPORT_OVERFLOW,v.TRUNCATED,v.BLIND_SPOT])});var PI=y(()=>{"use strict"});var MI,UI=y(()=>{"use strict";MI=e=>e});var we,Lte,$te,kte,HI=y(()=>{"use strict";ah();we={UI_ADVANCED_REQUEST_FAILED:"ui-advanced-request-failed",UI_ADVANCED_UNSIGNALLED:"ui-advanced-unsignalled",SIGNAL_CONTRADICTED:"signal-contradicted",RESPONSE_IGNORED:"response-ignored",SIGNAL_WITHOUT_CONSEQUENCE:"signal-without-consequence",STATE_VS_RENDER:"state-vs-render",CONSEQUENCE_ELSEWHERE:"consequence-elsewhere",DUPLICATE_REQUEST:"duplicate-request",DUPLICATE_REQUEST_UNRELATED:"duplicate-request-unrelated",SCREEN_REQUEST_MISMATCH:"screen-request-mismatch",STALE_RESPONSE_APPLIED:"stale-response-applied",PARTIAL_FAILURE_IN_OK_RESPONSE:"partial-failure-in-ok-response",UNIT_MISMATCH:"unit-mismatch",PAGINATION_NOT_FETCHED:"pagination-not-fetched",WRITE_FIELD_IGNORED:"write-field-ignored",REQUEST_NEVER_SETTLED:"request-never-settled",FAILURE_MISATTRIBUTED:"failure-misattributed",ACTION_HAD_NO_EFFECT:"action-had-no-effect",ROUTE_RENDERED_NOTHING:"route-rendered-nothing",ROUTE_RENDERED_NOTHING_CRASHED:"route-rendered-nothing-crashed",EVIDENCE_SUPERSEDED:"evidence-superseded",EVIDENCE_PREDATES_EDIT:"evidence-predates-edit"},Lte=new Set([we.REQUEST_NEVER_SETTLED,we.UI_ADVANCED_UNSIGNALLED,we.RESPONSE_IGNORED,we.SIGNAL_WITHOUT_CONSEQUENCE,we.STATE_VS_RENDER,we.CONSEQUENCE_ELSEWHERE,we.ROUTE_RENDERED_NOTHING,we.ACTION_HAD_NO_EFFECT,we.DUPLICATE_REQUEST,we.EVIDENCE_SUPERSEDED,we.EVIDENCE_PREDATES_EDIT]),$te=new Set([we.DUPLICATE_REQUEST_UNRELATED,we.SCREEN_REQUEST_MISMATCH]),kte={[we.UI_ADVANCED_REQUEST_FAILED]:[$.UI,$.NET],[we.UI_ADVANCED_UNSIGNALLED]:[$.UI,$.NET],[we.SIGNAL_CONTRADICTED]:[$.SIGNAL,$.NET],[we.RESPONSE_IGNORED]:[$.NET,$.UI],[we.SIGNAL_WITHOUT_CONSEQUENCE]:[$.SIGNAL,$.NET],[we.STATE_VS_RENDER]:[$.STATE,$.UI],[we.CONSEQUENCE_ELSEWHERE]:[$.NET,$.UI],[we.DUPLICATE_REQUEST]:[$.NET,$.NET],[we.DUPLICATE_REQUEST_UNRELATED]:[$.NET,$.NET],[we.SCREEN_REQUEST_MISMATCH]:[$.UI,$.NET],[we.STALE_RESPONSE_APPLIED]:[$.NET,$.UI],[we.PARTIAL_FAILURE_IN_OK_RESPONSE]:[$.NET,$.NET],[we.UNIT_MISMATCH]:[$.UI,$.NET],[we.PAGINATION_NOT_FETCHED]:[$.UI,$.NET],[we.WRITE_FIELD_IGNORED]:[$.NET,$.NET],[we.REQUEST_NEVER_SETTLED]:[$.TIME,$.NET],[we.FAILURE_MISATTRIBUTED]:[$.UI,$.NET],[we.ACTION_HAD_NO_EFFECT]:[$.NET,$.UI],[we.ROUTE_RENDERED_NOTHING]:[$.ROUTE,$.NET],[we.ROUTE_RENDERED_NOTHING_CRASHED]:[$.ROUTE,$.LOG],[we.EVIDENCE_SUPERSEDED]:[$.TIME,$.UI],[we.EVIDENCE_PREDATES_EDIT]:[$.TIME,$.UI]}});var Zo,hh,Pte,Mte,FI=y(()=>{"use strict";Kt();Zo="__reticleIpc",hh="reticle_capture",Pte=lc.FULL_PAGE_UNSUPPORTED,Mte=lc.NOT_COMPOSITED});var BI=y(()=>{"use strict"});var GI=y(()=>{"use strict"});var VI=y(()=>{"use strict"});function jI(e){return e===_c.CALM||e===_c.WAITING||e===_c.ASK||e===_c.WARN}var _c,KI,Gte,Vte,ZI=y(()=>{"use strict";_c={CALM:"calm",WAITING:"waiting",ASK:"ask",WARN:"warn"};KI="note that a lease is a SEPARATE context: the human watching this tab sees nothing of what you do there, so prefer this tab while someone is following along",Gte='tab hidden and may be un-focusable from here; timers and rAF are clamped in a background tab, so an action can land on a page that never advances. Refocus it, or acquire a guaranteed scriptable context yourself with `reticle_run { tool: "reticle_lease", args: { action: "acquire", url } }` (a human can equivalently run `reticle drive <url>`) \u2014 '+KI,Vte="tab is not hidden but has not reported health recently \u2014 usually a quiet page rather than a stuck one, and very often still driveable. This is also the tab a human can see, so try it first. Timing-sensitive work (animations, debounces, gestures) is what degrades: pass `refuseWhenThrottled: true` to refuse rather than act over events that may not land. Lease a separate context only if a drive here actually fails; "+KI});var WI,qG,Yte,Xte,qte,YI=y(()=>{"use strict";ae();Kt();Ko();jo();WI=1,qG=b({harness:p().min(1).max(Z.MAX_REF_LENGTH),driver:p().min(1).max(Z.MAX_COMMAND_NAME_LENGTH),persona:p().max(1e3).optional()}),Yte=b({v:U(WI),actionId:p().min(1).max(Z.MAX_REF_LENGTH),tool:p().min(1).max(Z.MAX_COMMAND_NAME_LENGTH),args:ie(p(),q()).default({}),effect:q().optional(),settled:L().optional(),settledInMs:_().int().min(0).optional(),seqRange:b({from:_().int().min(0),to:_().int().min(0)}).optional(),tRange:b({from:_().int().min(0),to:_().int().min(0)}),at:_().int().min(0),drivenBy:qG.optional(),agent:p().min(1).max(Z.MAX_REF_LENGTH).optional()}),Xte=b({v:U(WI),channel:U(Kf.JOURNAL),capBytes:_().int().min(1).optional(),bytesOnDisk:_().int().min(0).optional(),droppedInBatch:_().int().min(0).optional(),at:_().optional()}),qte=b({claim:p().min(1).max(Z.MAX_STRING_LENGTH),verified:R(Fn),source:p().max(Z.MAX_URL_LENGTH).optional(),observed:p().max(Z.MAX_STRING_LENGTH).optional(),expected:p().max(Z.MAX_STRING_LENGTH).optional(),kind:R(z).optional(),declaredBeforeActing:L().optional(),net:C(b({method:p().max(Z.MAX_COMMAND_NAME_LENGTH),url:p().max(Z.MAX_URL_LENGTH),status:_().optional(),body:p().max(Z.MAX_STRING_LENGTH).optional()})).max(5).optional(),grade:p().max(Z.MAX_STRING_LENGTH).optional(),couldNotSee:C(p().max(Z.MAX_STRING_LENGTH)).optional(),reason:p().max(Z.MAX_STRING_LENGTH).optional(),intent:p().max(Z.MAX_STRING_LENGTH).optional(),intentDerived:L().optional(),failedPart:_().int().min(0).optional()})});var XI=y(()=>{"use strict"});var ene,qI=y(()=>{"use strict";ae();ene=b({port:_(),pid:_(),cwd:p(),projectId:p().optional(),startedAt:_()})});var nne,JI=y(()=>{"use strict";ae();nne=b({port:_(),pid:_(),root:p(),url:p(),sdkVersion:p().min(1).optional(),startedAt:_(),projectId:p().optional()})});var JG,one,QI=y(()=>{"use strict";ae();JG=b({directory:p().min(1),lastSeenAt:_()}),one=b({version:U(1),projects:ie(p(),JG)})});var QG,w_,eV,tV,nV,sne,e0=y(()=>{"use strict";ae();QG=1,w_={DECLARED:"declared",BOUND:"bound",PROVED:"proved"},eV=b({route:p().optional(),flow:p().optional(),files:C(p()).optional()}),tV=b({verdictId:p(),grade:p(),at:_(),runId:p().optional()}),nV=b({id:p().min(1),statement:p().min(1),state:fe([w_.DECLARED,w_.BOUND,w_.PROVED]),declaredAt:_(),binding:q().optional(),surface:eV.optional(),provenBy:tV.optional(),amended:C(b({statement:p(),at:_()})).optional()}),sne=b({version:U(QG),intents:ie(p(),nV)})});var t0=y(()=>{"use strict"});function Qu(e){return rV[e]}var mt,rV,oV,lne,v_=y(()=>{"use strict";ae();mt={NO_SOURCE_MAPPING:"no-source-mapping",NO_STORE_REGISTERED:"no-store-registered",NO_SIGNAL_ON_MUTATION:"no-signal-on-mutation",UNDECLARED_CONTROL:"undeclared-control",MISSING_TESTID:"missing-testid",UNDECLARED_CHANGE:"undeclared-change",INTENT_UNDISCHARGED:"intent-undischarged",NO_FLOW_INTENT:"no-flow-intent",SOURCE_MAPPING_OFF:"source-mapping-off"},rV={[mt.NO_SOURCE_MAPPING]:"add the Reticle build plugin (@reticlehq/vite-plugin, @reticlehq/next, or the babel plugin) so elements carry data-reticle-source",[mt.NO_STORE_REGISTERED]:"import { registerStore } from '@reticlehq/browser' and call registerStore(name, store) with a subscribable store so its changes are observed; a bare getter is readable but does not report changes. For component-local React state, import { useReticleStore } from '@reticlehq/react/store' and call useReticleStore(name, value), assert the DOM, or read it with reticle_look { action: 'state', ref: '...' }",[mt.NO_SIGNAL_ON_MUTATION]:"fire reticle.signal(name, data) where this state is committed \u2014 commitAndSignal binds the two so they cannot drift",[mt.UNDECLARED_CONTROL]:"add this control to reticle.describe() so the capability contract matches what the app actually exposes",[mt.MISSING_TESTID]:'add data-testid="..." on this control so the flow can name it after a refactor',[mt.UNDECLARED_CHANGE]:'declare it with reticle_intent { action: "declare", intents: [{ id, statement }] } \u2014 the statement is prose, in your own words: which user does what, and what should become true',[mt.INTENT_UNDISCHARGED]:'draw a verdict whose `until` asserts the intent itself, then it discharges \u2014 or call reticle_run({ tool: "reticle_context" }) to see exactly what is still owed',[mt.SOURCE_MAPPING_OFF]:"nothing to install \u2014 this build has sourceMapping turned off, so no element carries data-reticle-source. Re-enable it in the Reticle plugin options unless this app renders through a non-DOM reconciler (react-three-fiber, react-pdf, ink), where the stamp is what would break it",[mt.NO_FLOW_INTENT]:'save it again with intent: "<which user does what, and what should become true>" \u2014 prose, in your own words \u2014 or set intentId to an intent already in the ledger'};oV={PIXELS_UNOBSERVED:"pixels-unobserved",CLAIM_ARITHMETIC_UNCHECKED:"claim-arithmetic-unchecked"},lne=b({kind:R(oV),detail:p().min(1)})});var Wo,n0,hne,mne,r0=y(()=>{"use strict";ae();hc();v_();l_();Wo={PAGE_CONNECTED:"page connected",DOM_ACTIONS:"DOM actions",NETWORK:"network",CONSOLE:"console",APP_STATE:"app state (store registered)",SIGNALS:"signals on mutation",SOURCE_MAPPING:oh,TEST_IDS:"stable test ids"},n0="run `npx @reticlehq/server init` in the app so its pages connect to Reticle in development",hne=[{capability:Wo.PAGE_CONNECTED,gaps:[],cost:"no page has connected, so nothing can be verified",fix:n0},{capability:Wo.DOM_ACTIONS,channel:$.UI,always:!0,gaps:[],cost:"controls cannot be driven or read",fix:n0},{capability:Wo.NETWORK,channel:$.NET,always:!0,gaps:[],cost:"requests cannot be asserted, so a save that never reached the server can pass",fix:"update @reticlehq/browser so the page reports its network channel"},{capability:Wo.CONSOLE,channel:$.LOG,always:!0,gaps:[],cost:"errors thrown in the page are invisible to a verdict",fix:"update @reticlehq/browser so the page reports its console channel"},{capability:Wo.APP_STATE,channel:$.STATE,gaps:[mt.NO_STORE_REGISTERED],cost:"state predicates fall back to reading the DOM",fix:Qu(mt.NO_STORE_REGISTERED)},{capability:Wo.SIGNALS,channel:$.SIGNAL,gaps:[mt.NO_SIGNAL_ON_MUTATION],cost:"the app never says it succeeded, so every verdict infers success from the DOM",fix:Qu(mt.NO_SIGNAL_ON_MUTATION)},{capability:Wo.SOURCE_MAPPING,channel:Vs.SOURCE,gaps:[mt.NO_SOURCE_MAPPING,mt.SOURCE_MAPPING_OFF],perControl:[mt.NO_SOURCE_MAPPING],cost:"a broken control is named, never the line that renders it",fix:Qu(mt.NO_SOURCE_MAPPING)},{capability:Wo.TEST_IDS,channel:Vs.TESTID,gaps:[mt.MISSING_TESTID],cost:"a saved flow loses its controls after a refactor",fix:Qu(mt.MISSING_TESTID)}],mne=C(R(Wo)).max(8)});var o0=y(()=>{"use strict"});function iV(e){return Array.isArray(e)||typeof e=="string"}function sV(e){if(Array.isArray(e))return{keys:[...e.slice(0,49).map((n,r)=>String(r)),N_],total:e.length+1};if(typeof e=="string")return{keys:[N_],total:1};if(e instanceof Map){let t=[],n=0;for(let r of e.keys())n+=1,typeof r=="string"&&t.length<49&&t.push(r);return e.has(ed)?{keys:t,total:n}:{keys:[...t,ed],total:n+1}}if(e instanceof Set){let t=[];for(let n of e)typeof n=="string"&&t.length<49&&t.push(n);return{keys:[...t,ed],total:e.size+1}}if(typeof e=="object"&&e!==null){let t=Object.keys(e);return{keys:t.slice(0,50),total:t.length}}return{keys:[],total:0}}function mh(e){let{keys:t,total:n}=sV(e);return{found:!1,value:null,availableKeys:t,...n>t.length?{totalKeys:n}:{}}}function i0(e,t){let n=t.split(".").filter(o=>o.length>0),r=e;for(let o of n){if(N_===o&&iV(r)){r=r.length;continue}if(Array.isArray(r)){let i=Number(o);if(!Number.isInteger(i)||i<0||String(i)!==o||i>=r.length)return mh(r);r=r[i];continue}if(r instanceof Map){if(r.has(o)){r=r.get(o);continue}if(ed===o){r=r.size;continue}return mh(r)}if(r instanceof Set){if(ed===o){r=r.size;continue}if(r.has(o)){r=!0;continue}return mh(r)}if(typeof r=="object"&&r!==null&&Object.hasOwn(r,o)){r=r[o];continue}return mh(r)}return{found:!0,value:r}}function Sc(e,t){if(t<0)return e;if(e instanceof Date)return Number.isNaN(e.getTime())?null:e.toISOString();if(e instanceof Set)return t===0?`[Set(${String(e.size)})]`:[...e].map(n=>Sc(n,t-1));if(e instanceof Map){if(t===0)return`{Map(${String(e.size)})}`;let n=Object.create(null);for(let[r,o]of e)n[String(r)]=Sc(o,t-1);return n}if(Array.isArray(e))return t===0?`[Array(${String(e.length)})]`:e.map(n=>Sc(n,t-1));if(typeof e=="object"&&e!==null){let n=Object.keys(e);if(t===0)return`{\u2026${String(n.length)} keys}`;let r=Object.create(null);for(let o of n)r[o]=Sc(e[o],t-1);return r}return e}var N_,ed,s0=y(()=>{"use strict";N_="length";ed="size"});var Sne,Tne,a0=y(()=>{"use strict";Kt();Sne={[Se.ENABLED]:"en",[Se.DISABLED]:"dis",[Se.CHECKED]:"chk",[Se.EXPANDED]:"exp",[Se.PRESSED]:"prs",[Se.FOCUSED]:"focus"},Tne=new Set([Se.PRESENT,Se.VISIBLE,Se.HIDDEN])});var Ks,Ane,yne,c0=y(()=>{"use strict";ae();Ks={SHARE_PROOF:"share_proof",RUN_HISTORY:"run_history",TEAM_REVIEW:"team_review",CORPUS_HEAL:"corpus_heal",CI_GATE:"ci_gate",HOSTED_RUNNER:"hosted_runner"},Ane=b({capability:R(Ks),reason:p(),unlockedBy:p(),learnMoreUrl:p().url()}),yne={[Ks.SHARE_PROOF]:{reason:"Sharing a verification result with a teammate needs a hosted, linkable proof page.",unlockedBy:"Link a free Reticle Cloud account (reticle connect), then share the run."},[Ks.RUN_HISTORY]:{reason:"Run history beyond this session lives in the hosted dashboard; local keeps only a buffer.",unlockedBy:"Link a free Reticle Cloud account to keep run history and trends."},[Ks.TEAM_REVIEW]:{reason:"A shared review queue of pinned mistakes is a team feature \u2014 it needs a hosted store.",unlockedBy:"Add your team to Reticle Cloud to share a review queue."},[Ks.CORPUS_HEAL]:{reason:"Corpus-ranked heal uses refactor outcomes learned across the fleet, served from the cloud.",unlockedBy:"Enable the hosted heal service on Reticle Cloud."},[Ks.CI_GATE]:{reason:"Verify-before-merge is a governance gate that runs in your CI against a hosted policy.",unlockedBy:"Configure the Reticle Cloud CI gate for your repository."},[Ks.HOSTED_RUNNER]:{reason:"Verifying without a local browser (CI, a background agent, or a deployed URL) needs a browser we run for you.",unlockedBy:"Link a Reticle Cloud account to run verifications on hosted browsers."}}});var td,l0,u0,d0,p0,aV,f0,h0=y(()=>{"use strict";ae();td={INSTALL:"install",ONBOARD:"onboard",FIRST_RUN:"first_run"},l0={STARTED:"started",COMPLETED:"completed",FAILED:"failed",ABANDONED:"abandoned",SKIPPED:"skipped"},u0={[td.INSTALL]:["script_started","runtime_ready","cli_installed","agents_detected","mcp_registered"],[td.ONBOARD]:["tour_started","concept_shown","first_look","first_act","first_verdict"],[td.FIRST_RUN]:["project_detected","next_step_offered","instrumented","app_connected","driven","flow_recorded","verdict_produced"]},d0={LEASE:"lease",INIT_CONSENT:"init_consent"},p0={NO_NODE:"no_node",NODE_TOO_OLD:"node_too_old",CLI_INSTALL_FAILED:"cli_install_failed",MCP_NOT_REGISTERED:"mcp_not_registered",NO_WEB_APP:"no_web_app",SETUP_FAILED:"setup_failed",DEV_SERVER_FAILED:"dev_server_failed",APP_NOT_CONNECTED:"app_not_connected",INTERRUPTED:"interrupted",AGENT_NOT_RESTARTED:"agent_not_restarted",CHROMIUM_UNAVAILABLE:"chromium_unavailable",UNCLASSIFIED:"unclassified"},aV=Object.values(u0).flatMap(e=>[...e]),f0=b({phase:R(td),step:fe(aV),status:R(l0),elapsedMs:_().int().nonnegative().optional(),reason:p().max(64).optional(),stack:p().max(64).optional(),unattended:L().optional(),firstEver:L().optional(),offered:R(d0).optional(),nextFollowed:L().optional(),stop:R(p0).optional()})});var m0,R_=y(()=>{"use strict";m0={AUTH_REFUSED:"auth_refused",LEASE_EXPIRED:"lease_expired",TAB_GONE:"tab_gone",NAVIGATED_AWAY:"navigated_away",ROUTE_SERVER_ERROR:"route_server_error",APP_NOT_REOPENED:"app_not_reopened",CONFIG_ELSEWHERE:"config_elsewhere",NO_LISTENER_NO_CONFIG:"no_listener_no_config",NO_LISTENER:"no_listener",NO_CONFIG:"no_config",SDK_NOT_REACHING_DAEMON:"sdk_not_reaching_daemon"}});var cV,g0,O_=y(()=>{"use strict";ae();R_();cV={NO_SESSION:"no_session",NO_MATCH:"no_match",UNSUPPORTED:"unsupported",BAD_ARGS:"bad_args",NOT_READY:"not_ready",OTHER:"other"},g0=b({tool:p().min(1).max(64),reason:R(cV),noSessionReason:R(m0).optional(),retried:L(),params:C(p().min(1).max(64)).max(16).optional()})});var lV,b0,Ine,E0,uV,dV,I_,pV,fV,_0,hV,mV,S0,C_=y(()=>{"use strict";ae();lV={CONNECT:"connect",CLOSE_GAPS:"close_gaps",SWITCH_ON:"switch_on",EXPLORE:"explore"},b0={B0:"0-19",B20:"20-39",B40:"40-59",B60:"60-79",B80:"80-100"},Ine=Object.values(b0),E0=b({fingerprint:p().min(1).max(64),count:_().int().nonnegative(),message:p().max(300),tool:p().max(64).optional()}),uV={NONE:"none",LOCAL_ONLY:"local_only",REMOTE:"remote"},dV={GITHUB:"github",GITLAB:"gitlab",BITBUCKET:"bitbucket",AZURE:"azure",SOURCEHUT:"sourcehut",CODEBERG:"codeberg",SELF_HOSTED:"self_hosted"},I_=b({rssMb:_().int().nonnegative(),heapUsedMb:_().int().nonnegative(),freeMemMb:_().int().nonnegative(),totalMemMb:_().int().nonnegative(),load1x100:_().int().nonnegative(),cpuCount:_().int().nonnegative()}),pV=b({totalMs:_().int().nonnegative(),maxMs:_().int().nonnegative()}),fV=b({attempts:_().int().nonnegative(),successes:_().int().nonnegative(),failures:ie(p(),_().int().nonnegative()).optional()}),_0=b({durationMs:_().int().nonnegative(),toolCalls:_().int().nonnegative(),toolCounts:ie(p(),_().int().nonnegative()),toolErrors:_().int().nonnegative(),errors:C(E0).max(40).optional(),sdkFailures:_().int().nonnegative().optional(),sdkErrors:C(E0).max(40).optional(),verifications:_().int().nonnegative(),bugsFound:_().int().nonnegative().optional(),bugKinds:ie(p(),_().int().nonnegative()).optional(),toolParams:ie(p(),ie(p(),_().int().nonnegative())).optional(),connections:ie(p(),fV).optional(),toolTiming:ie(p(),pV).optional(),busyMs:_().int().nonnegative().optional(),browserMs:_().int().nonnegative().optional(),browserCommands:_().int().nonnegative().optional(),peakConcurrentTools:_().int().nonnegative().optional(),unknownToolCalls:_().int().nonnegative().optional(),unknownTools:ie(p().max(64),_().int().nonnegative()).optional(),noSessionErrors:_().int().nonnegative().optional(),postSocketFailures:_().int().nonnegative().optional(),postRetriesSaved:_().int().nonnegative().optional(),consecutiveRepeats:ie(p(),_().int().positive()).optional(),abandonedActions:_().int().nonnegative().optional(),machine:I_.optional(),clients:C(p().max(64)).max(8).optional(),clientVersions:ie(p().max(64),p().max(32)).optional(),surface:p().max(32).optional(),appConnects:_().int().nonnegative().optional(),msToFirstApp:_().int().nonnegative().optional(),sdkVersion:p().min(1).max(32).optional(),toolCallsBeforeApp:_().int().nonnegative().optional(),endReason:fe(["never_used","explored","abandoned","verified","client_left"]).optional(),feedbackPrompted:_().int().nonnegative().optional(),errorClasses:ie(p().max(16),_().int().nonnegative()).optional(),errorsRecovered:_().int().nonnegative().optional(),errorsRepeated:_().int().nonnegative().optional(),endedWithVerdict:L().optional(),lifetimeToolCalls:_().int().nonnegative().optional(),lifetimeVerifications:_().int().nonnegative().optional(),lifetimeBugsFound:_().int().nonnegative().optional(),updateNudged:L().optional(),updateOffered:p().max(32).optional(),hudControls:ie(p(),_()).optional(),hudViewMs:ie(p(),_()).optional(),hudPanelMs:ie(p(),_()).optional(),hudSlides:ie(p(),_()).optional(),hudJourney:C(p().max(64)).max(60).optional(),hudJourneyCut:U(!0).optional(),nudgesShown:db(R(lV),_().int().positive()).optional(),harnessRefusedCoverage:db(R(b0),_().int().positive()).optional(),final:L(),exit:fe(["idle","signal","unknown"]).optional()}),hV={TINY:"tiny",SMALL:"small",MEDIUM:"medium",LARGE:"large",HUGE:"huge"},mV={NO_APP_FOUND:"no_app_found",MANIFEST_UNRECOGNISED:"manifest_unrecognised",WORKSPACE_APPS_UNRECOGNISED:"workspace_apps_unrecognised",WORKSPACE_ROOT_NO_APPS:"workspace_root_no_apps",DISCOVERY_FAILED:"discovery_failed"},S0=b({stack:p().min(1).max(64).optional(),stackSource:fe(["cwd","workspace"]).optional(),stackUnknownReason:R(mV).optional(),stackMajor:_().int().nonnegative().optional(),size:R(hV).optional(),monorepo:L().optional(),git:R(uV),forge:R(dV).optional(),ageWeeks:_().int().nonnegative().optional(),flowCount:_().int().nonnegative(),baselineCount:_().int().nonnegative(),visualBaselineCount:_().int().nonnegative(),runCount:_().int().nonnegative(),hasContract:L(),initialized:L().optional(),appConnectedBefore:L().optional(),capsuleCount:_().int().nonnegative(),featuresUsed:C(p().max(32)).max(24),featureDepth:_().min(0).max(1)})});var T0,L_=y(()=>{"use strict";T0={ACTIVE:"active",MISSING:"missing",INVALID:"invalid",EXPIRED:"expired",EVAL:"eval"}});var gV,EV,bV,$_,_V,SV,TV,xV,AV,yV,wV,vV,NV,RV,x0,A0,OV,IV,CV,LV,$V,kV,zV,DV,PV,y0,k_=y(()=>{"use strict";ae();Zu();gV={SIGNED_OUT:"signed_out",SIGNED_IN:"signed_in",LINKED:"linked"},EV={CLAUDE_CODE:"claude_code",CLAUDE_DESKTOP:"claude_desktop",CODEX:"codex",CURSOR:"cursor",GEMINI_CLI:"gemini_cli",ANTIGRAVITY:"antigravity",WINDSURF:"windsurf",CLINE:"cline",OPENCODE:"opencode",ZED:"zed",VSCODE:"vscode",OTHER:"other"},bV={NPX:"npx",GLOBAL:"global",PROJECT:"project",OTHER:"other"},$_={ZERO:"0",ONE:"1",TWO_THREE:"2-3",FOUR_NINE:"4-9",TEN_PLUS:"10+"},_V=b({view:R(Mt).optional(),surface:R(zi).optional(),tabs:R($_).optional()}),SV={CONNECT:"connect",HUD:"hud",LINK:"link"},TV=b({via:R(SV)}),xV={STARTED:"started",COMPLETED:"completed"},AV={PROVED:"proved",NOT_PROVED:"not_proved",FAILED:"failed",BLOCKED:"blocked",STOPPED:"stopped"},yV={NOT_LINKED:"not_linked",PLATFORM_UNREACHABLE:"platform_unreachable",HARNESS_OFF:"harness_off",NO_CREDITS:"no_credits",NOT_ENTITLED:"not_entitled",COVERAGE_GATE:"coverage_gate",VERSION_SKEW:"version_skew",BROKEN:"broken",OTHER:"other"},wV={AGENT:"agent",HUD:"hud",DASHBOARD:"dashboard",CLI_TRY:"cli_try",PLAN:"plan"},vV=b({phase:R(xV),source:R(wV),hosted:L(),outcome:R(AV).optional(),journeys:R($_).optional(),replayed:R($_).optional(),reason:R(yV).optional()}),NV={PASS:"pass",FAIL:"fail",NOTHING_TO_CHECK:"nothing_to_check",REGRESSION:"regression",ERROR:"error"},RV=b({outcome:R(NV),flowsChecked:_().int().nonnegative().optional()}),x0={accountState:R(gV).optional(),linked:L().optional(),workspaceId:p().min(1).max(128).optional(),client:R(EV).optional(),launch:R(bV).optional(),hud:_V.optional(),link:TV.optional(),harness:vV.optional(),gate:RV.optional()},A0={ECONNRESET:"ECONNRESET",ECONNREFUSED:"ECONNREFUSED",EPIPE:"EPIPE",ETIMEDOUT:"ETIMEDOUT",OTHER:"other"},OV={STDIN_END:"stdin_end",IDLE:"idle",CLIENT_GONE_STORM:"client_gone_storm",WAKE_FAILED:"wake_failed"},IV=b({reason:R(OV),uptimeMs:_().int().nonnegative(),drops:_().int().nonnegative(),toolCalls:_().int().nonnegative(),proxyId:p().min(1).max(64).optional()}),CV={ALIVE:"alive",CLEAN:"clean",SIGNALLED:"signalled",DIED_SILENTLY:"died_silently",UNKNOWN:"unknown"},LV=/^SIG[A-Z0-9]{1,12}$/,$V=/^(E[A-Z0-9]{2,30}|ERR_[A-Z0-9_]{2,60})$/,kV=b({ageMs:_().int().nonnegative(),end:R(CV).optional(),silentMs:_().int().nonnegative().optional(),signal:p().regex(LV).optional(),sessions:_().int().nonnegative().optional(),served:L().optional(),rssMb:_().int().nonnegative().optional(),error:p().regex($V).optional()}),zV={DETACHED:"detached",WMI:"wmi",WMI_FALLBACK:"wmi_fallback"},DV={FOREIGN:"foreign",OTHER_PROJECT:"other_project"},PV=b({presence:R(DV)}),y0={proxyExit:IV.optional(),daemonDeath:kV.optional(),wakeRefusal:PV.optional(),spawnMethod:R(zV).optional()}});var MV,UV,w0,z_=y(()=>{"use strict";ae();MV={CONTRADICTION:"contradiction",CRAWL:"crawl",REPLAY:"replay",ASSERTION:"assertion"},UV={APP:"app",REQUEST:"request",RETICLE:"reticle",UNCLASSIFIED:"unclassified"},w0=b({source:R(MV),kind:p().min(1).max(64),falseGreen:L(),tool:p().min(1).max(64).optional(),repeat:L(),attribution:R(UV),fingerprint:p().max(16).optional(),occurrence:_().int().positive().optional()})});var HV,un,jne,FV,BV,GV,VV,jV,v0,KV,ZV,WV,YV,XV,qV,JV,QV,e4,t4,n4,Kne,N0=y(()=>{"use strict";ae();h0();O_();C_();bc();Ko();bc();L_();k_();z_();z_();HV=3,un={RETICLE_INSTALLED:"reticle_installed",CLI_COMMAND_RUN:"cli_command_run",DAEMON_STARTED:"daemon_started",DAEMON_STOPPED:"daemon_stopped",SESSION_PROGRESS:"session_progress",VERIFICATION_COMPLETED:"verification_completed",PROJECT_PROFILED:"project_profiled",VERSION_CHANGED:"version_changed",RUNTIME_CRASHED:"runtime_crashed",FEEDBACK_SUBMITTED:"feedback_submitted",IDENTIFIED:"identified",MCP_CLIENT_CONNECTED:"mcp_client_connected",APP_INSTRUMENTED:"app_instrumented",MCP_CONNECTION_LOST:"mcp_connection_lost",MCP_PROXY_EXITED:"mcp_proxy_exited",DAEMON_DIED_UNCLEAN:"daemon_died_unclean",WAKE_REFUSED:"wake_refused",INIT_COMPLETED:"init_completed",ONBOARDING_STEP:"onboarding_step",BUG_FOUND:"bug_found",TOOL_REFUSED:"tool_refused",HUD_VIEWED:"hud_viewed",HUD_SIGNIN_PROMPTED:"hud_signin_prompted",PLATFORM_LINKED:"platform_linked",HARNESS_RUN:"harness_run",GATE_COMPLETED:"gate_completed"},jne=new Set([un.DAEMON_STARTED,un.DAEMON_STOPPED,un.SESSION_PROGRESS,un.MCP_CLIENT_CONNECTED,un.APP_INSTRUMENTED,un.PROJECT_PROFILED,un.VERIFICATION_COMPLETED,un.BUG_FOUND,un.RUNTIME_CRASHED,un.FEEDBACK_SUBMITTED,un.TOOL_REFUSED,un.HUD_VIEWED,un.HUD_SIGNIN_PROMPTED,un.HARNESS_RUN]),FV={HUMAN:"human",AGENT:"agent"},BV={GIT_ORIGIN:"git_origin",GIT_ROOT:"git_root",PACKAGE_ROOT:"package_root",CWD:"cwd"},GV={HARNESS:"harness"},VV=b({via:p().min(1).max(64),verified:p().min(1).max(16),passed:L(),falseGreenCaught:L(),durationMs:_().int().nonnegative().optional(),browser:p().min(1).max(16).optional(),brand:R(et).optional(),reason:R(lt).optional(),uncleanLoss:R(sO).optional(),driven:R(GV).optional(),sdkVersion:p().min(1).max(32).optional()}),jV=b({from:p().min(1).max(64),to:p().min(1).max(64),nudged:L().optional(),direction:p().min(1).max(16)}),v0={RETICLE:"reticle",OTHER:"other"},KV=b({kind:p().min(1).max(32),errorType:p().min(1).max(64).optional(),fingerprint:p().min(1).max(64).optional(),message:p().max(300).optional(),frames:C(p().max(120)).max(12).optional(),tool:p().min(1).max(64).optional(),breadcrumb:C(p().max(64)).max(12).optional(),nodeVersion:p().max(24).optional(),arch:p().max(16).optional(),machine:I_.optional(),syscall:p().max(32).optional(),errno:p().max(32).optional(),loopback:L().optional(),port:fe([v0.RETICLE,v0.OTHER]).optional(),internalFrame:p().max(64).optional()}),ZV=b({reconnect:L(),daemonAgeMs:_().int().nonnegative(),client:p().min(1).max(64).optional(),appConnected:L().optional(),proxyId:p().min(1).max(64).optional()}),WV=b({initialized:L(),agentAttached:L(),msToFirstApp:_().int().nonnegative(),firstEver:L().optional()}),YV={FIRST:"first",BUDGET_SPENT:"budget_spent",RECOVERED:"recovered"},XV={SSE_ENDED:"sse_ended",DAEMON_SHUTDOWN:"daemon_shutdown",SSE_ERROR:"sse_error",SSE_ABORTED:"sse_aborted",SSE_CLOSED:"sse_closed",CONNECT_ERROR:"connect_error",SSE_RESET:"sse_reset",OTHER:"other"},qV=b({stage:R(YV),reason:R(XV),attempts:_().int().nonnegative(),pendingLost:_().int().nonnegative().optional(),errCode:R(A0).optional(),responded:L().optional(),proxyId:p().min(1).max(64).optional()}),JV={SKILL_FILE:"skill_file",NPX_SKILL:"npx_skill",PLUGIN:"plugin",INSTALL_SCRIPT:"install_script",DOCS_SITE:"docs_site",README:"readme",BLOG:"blog",CLI_DIRECT:"cli_direct",UNKNOWN:"unknown"},QV={CONTAINER:"container",HOSTED_WORKSPACE:"hosted_workspace",CI_RUNNER:"ci_runner",AGENT_SANDBOX:"agent_sandbox"},e4={CONNECTED:"connected",NO_DAEMON:"no_daemon",NO_SESSION:"no_session",NO_PAGE:"no_page"},t4={NO_DEV_COMMAND:"no_dev_command",SPLIT_LOOPBACK:"split_loopback",PORT_BUSY:"port_busy",DEV_SERVER_EXITED:"dev_server_exited",NO_URL:"no_url",NOT_READY:"not_ready",PAGE_NOT_SERVED:"page_not_served",PAGE_TLS_REFUSED:"page_tls_refused",SDK_MISSING:"sdk_missing",NO_SESSION:"no_session",DESKTOP_NO_SESSION:"desktop_no_session"},n4=b({ok:L(),reason:p().max(64).optional(),stack:p().max(64).optional(),mcpRegistered:L().optional(),confirmation:R(e4).optional(),stop:R(t4).optional()}),Kne=b({v:U(HV),anonymousId:p().min(1).max(128),projectId:p().min(1).max(128).optional(),sessionId:p().min(1).max(64).optional(),event:R(un),ts:_().int().nonnegative(),version:p().min(1).max(64),ci:L(),automation:R(QV).optional(),projectIdSource:R(BV).optional(),os:p().min(1).max(32),tzOffsetMin:_().int().min(-900).max(900).optional(),internal:L().optional(),idEphemeral:L().optional(),feedback:$I.optional(),actor:R(FV).optional(),command:p().min(1).max(32).optional(),flags:C(p().max(32)).max(16).optional(),session:_0.optional(),project:S0.optional(),verification:VV.optional(),versionChange:jV.optional(),crash:KV.optional(),identity:kI.optional(),connection:ZV.optional(),init:n4.optional(),onboarding:f0.optional(),bug:w0.optional(),refusal:g0.optional(),outage:qV.optional(),instrumentation:WV.optional(),installSource:R(JV).optional(),licenseId:p().min(1).max(64).optional(),licenseStatus:R(T0).optional(),licenseKeyPresent:L().optional(),...x0,...y0})});var R0=y(()=>{"use strict"});var O0,D_=y(()=>{"use strict";fb();O0={SESSIONS:"reticle_sessions",LOOK:"reticle_look",SNAPSHOT:"reticle_snapshot",QUERY:"reticle_query",INSPECT:"reticle_inspect",ACT:cc.ACT,ACT_SEQUENCE:cc.ACT_SEQUENCE,ACT_AND_WAIT:cc.ACT_AND_WAIT,OBSERVE:"reticle_observe",LINEAGE:"reticle_lineage",WAIT_FOR:"reticle_wait_for",NETWORK:"reticle_network",CONSOLE:"reticle_console",ANIMATIONS:"reticle_animations",ASSERT:"reticle_assert",RECONCILE:"reticle_reconcile",BASELINE_SAVE:"reticle_baseline_save",BASELINE_LIST:"reticle_baseline_list",DIFF:"reticle_diff",RECORD_START:"reticle_record_start",RECORD_STOP:"reticle_record_stop",REPLAY:"reticle_replay",EXPLORE:"reticle_explore",NARRATE:"reticle_narrate",CLOCK:"reticle_clock",STATE:"reticle_state",STORAGE:"reticle_storage",CAPABILITIES:"reticle_capabilities",CONTRACT_SAVE:"reticle_contract_save",DOMAIN:"reticle_domain",FLOW_SAVE:"reticle_flow_save",FLOW_LIST:"reticle_flow_list",FLOW_LOAD:"reticle_flow_load",FLOW_DELETE:"reticle_flow_delete",FLOW_REPLAY:"reticle_flow_replay",FLOW_VERIFY:"reticle_flow_verify",FLOW_SAVE_RECORDED:"reticle_flow_save_recorded",FLOW_HEAL:"reticle_flow_heal",FLOW_MUTATE:"reticle_flow_mutate",ANNOTATE:"reticle_annotate",AFFECTED:"reticle_affected",COVERAGE:"reticle_coverage",VERIFY_CHANGE:"reticle_verify_change",VERIFY_EXPLORE:"reticle_verify_explore",INTENT:"reticle_intent",CONTEXT:"reticle_context",MAP:"reticle_map",VERIFY:"reticle_verify",PROJECT:"reticle_project",ACCOUNT:"reticle_account",MEMORY:"reticle_memory",RUN_RECORD:"reticle_run_record",SCREENSHOT:"reticle_screenshot",NETWORK_MOCK:"reticle_network_mock",VIEWPORT:"reticle_viewport",VISUAL_DIFF:"reticle_visual_diff",CRAWL:"reticle_crawl",SCROLL_TO:"reticle_scroll_to",SESSION_TUNE:"reticle_session_tune",END_SESSION:"reticle_end_session",YIELD:"reticle_yield",RESUME:"reticle_resume",MESSAGES:"reticle_messages",REVIEW:"reticle_review",WAIT_READY:"reticle_wait_ready",NAVIGATE:"reticle_navigate",REFRESH:"reticle_refresh",RUN_EXPORT:"reticle_run_export",BASELINE:"reticle_baseline",SESSION:"reticle_session",RECORD:"reticle_record",FLOW:"reticle_flow",LEASE:"reticle_lease",LEASE_ACQUIRE:"reticle_lease_acquire",LEASE_RELEASE:"reticle_lease_release",TOOLS:"reticle_tools",RUN:"reticle_run",FEEDBACK:"reticle_feedback"}});var I0,r4,gh,o4,Qne,ere,tre,C0=y(()=>{"use strict";ae();D_();I0="reticle connect",r4={HARNESS_NOT_LINKED:"harness_not_linked"},gh={HUMAN:"human",AGENT:"agent"},o4=vt("who",[b({who:U(gh.HUMAN),run:p()}),b({who:U(gh.AGENT),tool:p()})]),Qne=b({code:fe([r4.HARNESS_NOT_LINKED]),next:C(o4)}),ere=[{who:gh.HUMAN,run:I0},{who:gh.AGENT,tool:O0.ACT_AND_WAIT}],tre=`Connect your Reticle account to run the Harness: \`${I0}\`.`});var L0=y(()=>{"use strict"});var $0=y(()=>{"use strict"});var lre,ure,dre,pre,k0=y(()=>{"use strict";hc();bc();sh();Kt();lre={[Pi.WEB]:{surface:ir.WEB,isDesktopShell:!1,usesWebKit:!1,ownsCoverageKinds:!1,hasOwnBaselineDirectory:!1},[Pi.ELECTRON]:{surface:ir.DESKTOP,isDesktopShell:!0,projectMarker:{dependency:"electron"},usesWebKit:!1,ownsCoverageKinds:!0,hasOwnBaselineDirectory:!0},[Pi.TAURI]:{surface:ir.DESKTOP,isDesktopShell:!0,projectMarker:{file:"src-tauri/tauri.conf.json"},usesWebKit:!0,ownsCoverageKinds:!1,hasOwnBaselineDirectory:!0}},ure=new Set(Object.values(or)),dre={[Pi.WEB]:uo.WEB,[Pi.ELECTRON]:uo.WEBVIEW,[Pi.TAURI]:uo.WEBVIEW},pre={[ir.WEB]:{reset:"cheap",replayPrefix:"free",time:"injectable",observation:"exact",actions:"reversible"},[ir.DESKTOP]:{reset:"cheap",replayPrefix:"free",time:"injectable",observation:"exact",actions:"reversible"},[ir.MOBILE]:{reset:"costly",replayPrefix:"costly",time:"wall",observation:"exact",actions:"reversible"},[ir.SERVICE]:{reset:"costly",replayPrefix:"unsafe",time:"wall",observation:"exact",actions:"irreversible"},[ir.GAME]:{reset:"cheap",replayPrefix:"free",time:"stepped",observation:"exact",actions:"reversible"},[ir.DEVICE]:{reset:"costly",replayPrefix:"unsafe",time:"wall",observation:"sampled",actions:"irreversible"}}});var P0,i4,s4,z0,a4,M0,c4,D0,l4,xt,u4,d4,p4,f4,h4,m4,U0,g4,E4,H0,P_=y(()=>{"use strict";ae();P0=b({calls:_().int().nonnegative(),verdicts:_().int().nonnegative(),passed:_().int().nonnegative(),failed:_().int().nonnegative(),unknown:_().int().nonnegative(),refusals:_().int().nonnegative(),marks:_().int().nonnegative(),sessions:_().int().nonnegative(),tokensReturned:_().int().nonnegative(),drivingMs:_().int().nonnegative()}),i4=b({date:p(),counts:P0}),s4=b({longestRunMs:_().int().nonnegative(),bestVerdictDay:_().int().nonnegative(),bestDefectDay:_().int().nonnegative(),streakDays:_().int().nonnegative(),bestStreakDays:_().int().nonnegative()}),z0=b({value:_().nonnegative(),basis:p()}),a4=b({tokens:z0,minutes:z0}),M0=10,c4=b({at:_().int().nonnegative(),title:p(),detail:p().optional(),source:p().optional()}),D0=b({counts:P0,days:C(i4),records:s4,savings:a4,since:_().int().nonnegative(),defects:C(c4).default([])}),l4=b({signedIn:L(),org:p().optional(),email:p().optional(),host:p().optional()}),xt={FREE:"free",TRIAL:"trial",PAID:"paid"},u4=b({provider:p(),harnessEnabled:L(),harnessEntitled:L(),providerReady:L().optional(),credits:b({used:_().min(0),limit:_().min(0),kind:fe([xt.FREE,xt.TRIAL,xt.PAID]).optional(),daysLeft:_().int().min(0).optional()}).optional(),platformUrl:p().optional(),planUrl:p().optional(),plan:b({kind:fe([xt.FREE,xt.TRIAL,xt.PAID]),daysLeft:_().int().min(0).optional(),seats:_().int().min(0).optional()}).optional(),harnessRuns:_().int().min(0).optional(),memoryEntries:_().int().min(0).optional()}),d4=60,p4=b({runId:p(),steps:_().int().min(0),lines:C(p()).max(d4).optional()}),f4=b({runUrl:p().optional(),said:p().optional(),seq:_().int().min(0).optional()}),h4=500,m4=5,U0=64,g4=b({text:p().max(h4),seen:L(),by:p().max(U0).optional()}),E4=b({agents:C(p().max(U0)).max(8),notes:C(g4).max(m4)}),H0=b({schemaVersion:_().int().positive(),project:D0,global:D0,projectName:p().optional(),dashboardUrl:p().optional(),account:l4.optional(),harnessConfig:u4.optional(),harnessDrive:p4.optional(),lastDrive:f4.optional(),agent:E4.optional(),notices:C(q()).max(8).optional(),coverage:ie(p(),_()).optional(),sync:ie(p(),q()).optional(),instrumentation:ie(p(),q()).optional()})});var F0=y(()=>{"use strict"});function Tc(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619)>>>0;return t.toString(16).padStart(8,"0")}function B0(e){let t=Object.keys(e).sort().map(n=>{var r;return`${n}:${[...(r=e[n])!=null?r:[]].sort().join(",")}`}).join("|");return Tc(t)}var M_,nd,G0=y(()=>{"use strict";Kt();M_=B0({messageKinds:Object.values(sn),commands:Object.values(H),actions:Object.values(D),events:Object.values(v)}),nd={commands:Object.values(H),events:Object.values(v),actions:Object.values(D)}});var V0,j0=y(()=>{"use strict";V0="[Reticle] this page could not open a websocket to "});var K0=y(()=>{"use strict"});var M=y(()=>{"use strict";IA();yO();wO();vO();OO();Kt();t_();CO();kO();zO();PO();GO();o_();VO();Ko();jO();KO();ZO();s_();Zu();JO();l_();tI();iI();aI();cI();x_();uh();OI();II();zI();DI();ku();fb();AO();Eb();PI();Db();$b();Pb();UI();Vu();HI();FI();jo();Gb();Fb();Yb();Xb();qb();BI();GI();VI();ZI();YI();XI();qI();JI();QI();e0();t0();v_();r0();o0();__();m_();s0();a0();c0();N0();R_();O_();R0();D_();C0();L0();sh();ah();$0();k0();C_();k_();L_();bc();P_();F0();G0();j0();K0()});function ke(e,t){return e[t]}function Z0(e){let t=Object.getOwnPropertyDescriptor(e,"value");return t===void 0?void 0:ke(t,"set")}var Yo=y(()=>{"use strict"});function S4(){for(let e of Mi)e.deref()===void 0&&Mi.delete(e);for(;Mi.size>b4;){let e=Mi.values().next();if(e.done===!0)break;Mi.delete(e.value)}}function X0(){let e=[];for(let t of Mi){let n=t.deref();n!==void 0&&e.push(n)}return e}function Y0(e,t){if(!W0.has(e)){W0.add(e),Mi.add(new WeakRef(e)),H_+=1,H_>=_4&&(H_=0,S4()),F_.add(t);for(let n of Eh)n(e)}}function q0(){return X0()}function J0(e){return F_.has(e)}function Zs(e){if(!F_.has(e))return null;for(let t of X0())if(t.host===e)return t;return null}function Q0(e){return Eh.add(e),()=>Eh.delete(e)}function eC(){let e=Element.prototype,t=ke(e,"attachShadow");if(typeof t!="function")return()=>{};U_+=1;let n=function(i){let s=t.call(this,i);return Y0(s,this),s};e.attachShadow=n;let r=o=>{for(let i of o.querySelectorAll("*")){let s=i.shadowRoot;s!==null&&(Y0(s,i),r(s))}};return document.documentElement!==null&&r(document.documentElement),()=>{ke(e,"attachShadow")===n&&(e.attachShadow=t),U_-=1,!(U_>0)&&(Mi.clear(),Eh.clear())}}function T4(e){let t=e.parentElement;if(t===null||t.shadowRoot!==null)return null;let n=Zs(t);if(n===null)return null;for(let r of Array.from(n.querySelectorAll("slot")))if(r.assignedElements().includes(e))return r;return null}function Xo(e){var r;let t=(r=e.assignedSlot)!=null?r:T4(e);if(t!==null)return t;if(e.parentElement!==null)return e.parentElement;let n=e.getRootNode().host;return n!=null?n:null}var U_,Mi,W0,F_,b4,_4,H_,Eh,qo=y(()=>{"use strict";Yo();U_=0,Mi=new Set,W0=new WeakSet,F_=new WeakSet,b4=4e3,_4=250,H_=0;Eh=new Set});function tC(e,t){var o;if(e===null||typeof e!="object")return;let r=((o=e.ownerDocument)!=null?o:e).defaultView;if(r!=null)return r[t]}function Vn(e,t,n){var o;let r=(o=tC(e,t))!=null?o:n;return typeof r=="function"&&e instanceof r}function sC(e){let t=vn(e)?"HTMLTextAreaElement":"HTMLInputElement",n=tC(e,t);if(typeof n!="function")return;let r=n.prototype;return typeof r=="object"&&r!==null?r:void 0}var wn,B_,ut,x4,Jo,He,vn,zr,rd,nC,rC,oC,iC,bh,dn=y(()=>{"use strict";wn=e=>Vn(e,"Element",typeof Element=="undefined"?void 0:Element),B_=e=>Vn(e,"HTMLImageElement",typeof HTMLImageElement=="undefined"?void 0:HTMLImageElement),ut=e=>Vn(e,"HTMLElement",typeof HTMLElement=="undefined"?void 0:HTMLElement),x4=e=>Vn(e,"SVGElement",typeof SVGElement=="undefined"?void 0:SVGElement),Jo=e=>ut(e)||x4(e),He=e=>Vn(e,"HTMLInputElement",typeof HTMLInputElement=="undefined"?void 0:HTMLInputElement),vn=e=>Vn(e,"HTMLTextAreaElement",typeof HTMLTextAreaElement=="undefined"?void 0:HTMLTextAreaElement),zr=e=>Vn(e,"HTMLSelectElement",typeof HTMLSelectElement=="undefined"?void 0:HTMLSelectElement),rd=e=>Vn(e,"HTMLButtonElement",typeof HTMLButtonElement=="undefined"?void 0:HTMLButtonElement),nC=e=>Vn(e,"HTMLMeterElement",typeof HTMLMeterElement=="undefined"?void 0:HTMLMeterElement),rC=e=>Vn(e,"HTMLOutputElement",typeof HTMLOutputElement=="undefined"?void 0:HTMLOutputElement),oC=e=>Vn(e,"HTMLProgressElement",typeof HTMLProgressElement=="undefined"?void 0:HTMLProgressElement),iC=e=>Vn(e,"HTMLFormElement",typeof HTMLFormElement=="undefined"?void 0:HTMLFormElement),bh=e=>Vn(e,"HTMLIFrameElement",typeof HTMLIFrameElement=="undefined"?void 0:HTMLIFrameElement)});function w4(e){if(e.id.length>0)return`#${e.id}`;let t=e.getAttribute("class");return t!==null&&t.trim().length>0?`.${t.trim().split(/\s+/).join(".")}`:e.tagName.toLowerCase()}function aC(e){let t=e.ownerDocument.defaultView;if(t===null)return[];let n=[];for(let r=e;r!==null&&r!==e.ownerDocument.documentElement;r=r.parentElement){let o=t.getComputedStyle(r);for(let i of A4){let s=o.getPropertyValue(i);s.length>0&&s!==y4[i]&&n.push({on:w4(r),property:i,value:s})}}return n}function _h(e){var o;let t=(o=e==null?void 0:e.overflow)!=null?o:"",[n="visible",r=n]=(t===""?"visible":t).split(/\s+/);return[e===null||e.overflowX===""?n:e.overflowX,e===null||e.overflowY===""?r:e.overflowY]}function G_(e,t){var V;if(t.clipBox!==void 0)return t.clipBox;let n=e.getBoundingClientRect(),r=t.style,o=W=>Number.parseFloat(W!=null?W:"")||0,i=(W,K)=>K===void 0||K===""||K==="none"||K==="hidden"?0:o(W),s=ut(e)&&e.offsetWidth>0?n.width/e.offsetWidth:1,a=ut(e)&&e.offsetHeight>0?n.height/e.offsetHeight:1,l=ut(e)&&e.offsetWidth>0?n.left+e.clientLeft*s:n.left+i(r==null?void 0:r.borderLeftWidth,r==null?void 0:r.borderLeftStyle),u=ut(e)&&e.offsetHeight>0?n.top+e.clientTop*a:n.top+i(r==null?void 0:r.borderTopWidth,r==null?void 0:r.borderTopStyle),d=ut(e)&&e.offsetWidth>0?l+e.clientWidth*s:n.right-i(r==null?void 0:r.borderRightWidth,r==null?void 0:r.borderRightStyle),f=ut(e)&&e.offsetHeight>0?u+e.clientHeight*a:n.bottom-i(r==null?void 0:r.borderBottomWidth,r==null?void 0:r.borderBottomStyle),m=((V=r==null?void 0:r.overflowClipMargin)!=null?V:"").split(/\s+/),h=o(m.at(-1)),E=m.includes("border-box"),S=m.includes("content-box"),[A,w]=_h(r),N=A==="clip"?(E?n.left:l+(S?o(r==null?void 0:r.paddingLeft)*s:0))-h*s:l,O=A==="clip"?(E?n.right:d-(S?o(r==null?void 0:r.paddingRight)*s:0))+h*s:d,k=w==="clip"?(E?n.top:u+(S?o(r==null?void 0:r.paddingTop)*a:0))-h*a:u,G=w==="clip"?(E?n.bottom:f-(S?o(r==null?void 0:r.paddingBottom)*a:0))+h*a:f;return t.clipBox={left:N,right:O,top:k,bottom:G,width:O-N,height:G-k},t.clipBox}function cC(e,t,n,r){let o=(u,d,f,m,h)=>{if(d>m&&u<h)return[u,d];let E=Math.min(f,h-m);return u>=h?[h-E,h]:[m,m+E]},[i,s]=n?o(e.left,e.right,e.width,t.left,t.right):[e.left,e.right],[a,l]=r?o(e.top,e.bottom,e.height,t.top,t.bottom):[e.top,e.bottom];return{left:i,right:s,top:a,bottom:l,width:s-i,height:l-a}}var A4,y4,V_=y(()=>{"use strict";dn();A4=["filter","opacity","transform","mix-blend-mode","backdrop-filter"],y4={filter:"none",opacity:"1",transform:"none","mix-blend-mode":"normal","backdrop-filter":"none"}});function v4(e){let t=e.parentElement;if(t===null)return!1;let n=t.closest(j_);if(n===null||n.hasAttribute(K_))return!1;let r=Array.from(n.children).find(o=>Sh===o.localName);return r===void 0||!r.contains(e)}function Z_(e){return!e.ownerDocument.hidden||!("getAnimations"in e)?!1:e.getAnimations().some(t=>t.playState==="running"||t.pending)}function O4(e){return e.hasAttribute(N4)?!0:I4(e)}function I4(e){let t=e.ownerDocument.body;if(e.parentElement!==t)return!1;let r=Array.from(t.children).filter(i=>i!==e&&!R4.has(i.localName)&&!i.matches(Di)).filter(i=>i.getAttribute("aria-hidden")!=="true"),o=r[0];return r.length===1&&o!==void 0&&C4(o)}function C4(e){var n,r;let t=e.matches(lC)?e:e.querySelector(lC);for(let o=t;o!==null;o=o.parentElement){let i=(r=(n=o.ownerDocument.defaultView)==null?void 0:n.getComputedStyle(o))!=null?r:null;if(Th(o,i))return!1;if(o===e)return!0}return!1}function Th(e,t){return!!(ut(e)&&e.hidden||v4(e)||t!==null&&(t.display==="none"||t.visibility==="hidden"||t.visibility==="collapse"||Number.parseFloat(t.opacity||"1")===0&&!Z_(e)||L4(t)))}function L4(e){var u,d,f,m;let t=/^rect\((.*)\)$/.exec(e.getPropertyValue("clip").trim());if(t!==null&&(e.position==="absolute"||e.position==="fixed")){let[h,E,S,A]=((u=t[1])!=null?u:"").split(/[\s,]+/).map(Number.parseFloat);if(E!==void 0&&A!==void 0&&E<=A||S!==void 0&&h!==void 0&&S<=h)return!0}let n=/^inset\(([^)]*)\)$/.exec(e.getPropertyValue("clip-path").trim()),r=(m=(f=(d=n==null?void 0:n[1])==null?void 0:d.split(/\s+round\s/)[0])==null?void 0:f.trim().split(/\s+/))!=null?m:[],o=h=>h.endsWith("%")||Number.parseFloat(h)===0;if(r.length===0||!r.every(o))return!1;let[i=0,s=i,a=i,l=s]=r.map(Number.parseFloat);return i+a>=100||l+s>=100}function $4(e,t){return e.getAttribute("aria-hidden")==="true"&&!O4(e)?!0:Th(e,t)}function mC(e){var r,o;let t=!1,n=e;for(;n!==null;){n.getAttribute("aria-hidden")==="true"&&(t=!0);let i=(o=(r=n.ownerDocument.defaultView)==null?void 0:r.getComputedStyle(n))!=null?o:null;if(Th(n,i))return!1;n=Xo(n)}return t}function gC(e){var n,r;let t=e;for(;t!==null;){if(t.getAttribute("aria-hidden")==="true")return!1;let o=(r=(n=t.ownerDocument.defaultView)==null?void 0:n.getComputedStyle(t))!=null?r:null;if(Th(t,o))return!1;t=Xo(t)}return!0}function k4(e){if(typeof DOMMatrix=="undefined")return null;try{let t=e==null?void 0:e.transform;return t===void 0||t===""||t==="none"?new DOMMatrix:new DOMMatrix(t)}catch{return null}}function z4(e){return Number.isFinite(e.m33)&&0>e.m33}function D4(e,t){let n=[],r=!1;for(let i=e;i!==null;i=Xo(i)){let s=ur(i,t).style;uC===(s==null?void 0:s.backfaceVisibility)&&(r=!0),n.push(i)}if(!r)return!1;let o=null;for(let i=n.length-1;i>=0;i-=1){let s=n[i];if(s===void 0)return!1;let a=ur(s,t).style,l=k4(a);if(l===null)return!1;if(o=o===null?l:o.multiply(l),uC===(a==null?void 0:a.backfaceVisibility)&&z4(o))return!0}return!1}function _C(e){if(e===void 0)return new Map;let t=hC.get(e);return t===void 0&&(t=new Map,hC.set(e,t)),t}function ur(e,t){var r,o,i;let n=t.get(e);if(n===void 0){let s=(o=(r=e.ownerDocument.defaultView)==null?void 0:r.getComputedStyle(e))!=null?o:null;if($4(e,s))return n={hidden:!0,style:s,parent:null,clipX:!1,clipY:!1,scrollX:!1,scrollY:!1,hasClipping:!1},t.set(e,n),n;let a=Xo(e),l=a===null?void 0:ur(a,t),[u,d]=_h(s),f=e.ownerDocument.documentElement,h=!(e===f||e===e.ownerDocument.body&&_h(ur(f,t).style).every(A=>A==="visible"))&&!EC.has((i=s==null?void 0:s.display)!=null?i:"")&&!(ut(e)&&(s==null?void 0:s.display)==="inline"),E=h&&dC.has(u),S=h&&dC.has(d);n={hidden:(l==null?void 0:l.hidden)===!0,style:s,parent:a,clipX:E,clipY:S,scrollX:h&&pC.has(u),scrollY:h&&pC.has(d),hasClipping:E||S||(l==null?void 0:l.hasClipping)===!0},t.set(e,n)}return n}function U4(e,t,n){for(let r=ur(e,n).parent;r!==null;r=ur(r,n).parent){let o=ur(r,n).style;if(o===null||o.display==="contents")continue;if(!t&&o.position!==""&&o.position!=="static")return r;let i=!(o.display==="inline"&&ut(r)&&!M4.has(r.localName))&&o.display!=="table-column"&&o.display!=="table-column-group",s=a=>i||!bC.has(a);if([...fC].some(a=>{let l=o.getPropertyValue(a);return s(a)&&l!==""&&l!=="none"})||o.willChange.split(",").some(a=>fC.has(a.trim())&&s(a.trim()))||i&&!EC.has(o.display)&&(o.contain.split(/\s+/).some(a=>P4.has(a))||o.contentVisibility==="auto"))return r}return null}function SC(e,t,n,r=!1){let o=n,i=ur(e,t);if(i.hidden)return null;if(i.parent===null||!ur(i.parent,t).hasClipping)return o;let s;for(let a=e;a!==null;a=ur(a,t).parent){let l=ur(a,t);if(l.hidden)return null;a===s&&(s=void 0);let u=l.style;if(r&&a!==e&&s===void 0&&(l.scrollX||l.scrollY)&&(o!=null||(o=e.getBoundingClientRect()),o.width>0&&o.height>0&&(o=cC(o,G_(a,l),l.scrollX,l.scrollY))),a!==e&&s===void 0&&(l.clipX||l.clipY)&&(o!=null||(o=e.getBoundingClientRect()),o.width>0&&o.height>0)){let d=G_(a,l),f=l.clipX?Math.max(o.left,d.left):o.left,m=l.clipX?Math.min(o.right,d.right):o.right,h=l.clipY?Math.max(o.top,d.top):o.top,E=l.clipY?Math.min(o.bottom,d.bottom):o.bottom;if(m<=f||E<=h)return null;o={left:f,right:m,top:h,bottom:E,width:m-f,height:E-h}}s===void 0&&((u==null?void 0:u.position)==="absolute"||(u==null?void 0:u.position)==="fixed")&&(s=U4(a,(u==null?void 0:u.position)==="fixed",t))}return o}function W_(e,t){if(!Ke(e,t))return!1;let n=e.ownerDocument.defaultView;if(n===null)return!1;let r=SC(e,_C(t),e.getBoundingClientRect());return r==null||r.width<=0||r.height<=0?!1:r.bottom>0&&r.right>0&&r.top<n.innerHeight&&r.left<n.innerWidth}function H4(e,t){let n=ur(e,t);if(!n.clipX&&!n.clipY)return!1;let r=Array.from(e.getClientRects());return r.length>0&&r.every(o=>n.clipX&&o.width===0||n.clipY&&o.height===0||n.clipX&&n.clipY&&o.width<=1&&o.height<=1)}function Ke(e,t){if(!e.isConnected)return!1;let n=t==null?void 0:t.get(e);if(n!==void 0)return n;let r=_C(t),o=SC(e,r,void 0,!0)!==null&&!H4(e,r)&&!D4(e,r);return t!==void 0&&t.set(e,o),o}var j_,K_,Sh,N4,lC,R4,uC,dC,pC,EC,bC,fC,P4,M4,hC,Dr=y(()=>{"use strict";M();dn();qo();V_();j_="details",K_="open",Sh="summary";N4="data-aria-hidden",lC='[role="dialog"], [role="alertdialog"], [role="menu"], [role="listbox"], dialog[open], [aria-modal="true"]',R4=new Set(["script","style","template","noscript","link","meta"]);uC="hidden";dC=new Set(["hidden","clip"]),pC=new Set(["auto","scroll"]),EC=new Set(["contents","table-row","table-row-group","table-header-group","table-footer-group","table-column","table-column-group"]),bC=new Set(["transform","translate","rotate","scale","perspective"]),fC=new Set([...bC,"filter","backdrop-filter"]),P4=new Set(["layout","paint","strict","content"]),M4=new Set(["img","video","audio","canvas","iframe","embed","object","input","textarea","select"]),hC=new WeakMap});function AC(e){X_=e}function q_(e){yC=e}function vC(){return X_}function NC(e){xC=e.join(",")}function Rt(e){return e.closest(Ui)!==null}function Hi(e){return Rt(e)?!wC()||e.closest(B4)===null:!1}function dr(e){return e!==null&&e.closest(Ui)!==null}function Ot(e){let n=[wC()?G4:Ui,F4,xC].filter(r=>r.length>0).join(",");return e.closest(n)!==null}function od(e){return Ot(e)||Rt(e)}function K4(e){var r;let t=e.querySelector(j4);if(t!==null)return{name:Y_.VITE,host:t};for(let o of Array.from(e.querySelectorAll(V4))){let i=(r=o.shadowRoot)!=null?r:Zs(o),s=(i!=null?i:o).querySelector(TC);if(s!==null&&Ke(s))return{name:Y_.NEXT,host:o}}let n=e.querySelector(TC);if(!(n===null||!Ke(n)))return{name:Y_.NEXT,host:n}}function RC(e){let t=e[0];if(t===void 0)return;let n=K4(t.ownerDocument);if(n!==void 0)return e.some(r=>!Z4(r,n.host))?n.name:void 0}function Z4(e,t){var n;for(let r=e;r!==null;){if(r===t)return!0;let o=r.getRootNode();r=(n=r.parentNode)!=null?n:o instanceof ShadowRoot?o.host:null}return!1}function xh(e){for(let t of Array.from(e.querySelectorAll(W4)))if(t.closest(Ui)===null&&!(t instanceof HTMLElement&&(t.hidden||t.closest("[hidden]")!==null))&&!(t instanceof HTMLElement&&getComputedStyle(t).display==="none"))return!0;return!1}var Ui,F4,xC,X_,yC,wC,B4,G4,Y_,V4,TC,j4,W4,ot=y(()=>{"use strict";M();qo();Dr();Ui=Di,F4="[data-agentation],#__next-build-watcher,nextjs-portal,[data-nextjs-dialog],[data-nextjs-toast]",xC="",X_=!1;yC=!1;wC=()=>X_&&!yC;B4="[data-reticle-dock]";G4="[data-reticle-log],[data-reticle-harness-log],[data-reticle-chat-pill-text],[data-reticle-agent-said],[data-reticle-agent-note],[data-reticle-act-line]";Y_={NEXT:"Next.js error dialog",VITE:"Vite error overlay"},V4="nextjs-portal",TC="[data-nextjs-dialog]",j4="vite-error-overlay";W4='dialog[open], [aria-modal="true"]'});function Fi(){return Ah}function jn(){return`[${Ah}]`}function Ne(e){return e.getAttribute(Ah)}function kC(e){Ah=e!==void 0&&$O.test(e)?e:Hs}var Ah,It=y(()=>{"use strict";M();Ah=Hs});function Nh(e){return Q4.has(e)||e.startsWith(yh)||e.startsWith(wh)||e.startsWith(vh)}var At,yh,wh,vh,Q4,ho=y(()=>{"use strict";At={SESSION:"__reticle_session",REF_BASE:"__reticle_ref_base",PRESENTER_LOG:"reticle-presenter-log",PRESENTER_LOG_OWNER:"reticle-presenter-log-owner",PRESENTER_SETTINGS:"reticle-presenter-settings",PRESENTER_MINIMISED:"reticle-presenter-minimised",PRESENTER_OPEN:"reticle-presenter-open",PRESENTER_VIEW:"reticle-presenter-view",CAROUSEL_DISMISSED:"reticle.carousel.dismissed",ANNOTATION_HISTORY:"reticle.annotations.history.v1"},yh="reticle.tour.seen.",wh="reticle.harness.persona.",vh="reticle.impact.seen.",Q4=new Set(Object.values(At))});function Pr(e){let t=Z.MAX_REF_LENGTH;return t>=e.length?e:`${e.slice(0,t)}${ej}`}function rj(e){try{let t=e==null?void 0:e.getItem(DC),n=t==null?Number.NaN:Number(t);return Number.isSafeInteger(n)&&n>0?n:0}catch{return 0}}var zC,ej,J_,tj,DC,nj,sd,Ct,ad,Qo,xc,Ac,yc,ei,PC,Q_,MC,id,re,gt=y(()=>{"use strict";M();ho();zC=1e4,ej="\u2026",J_="e";tj=1e3,DC=At.REF_BASE,nj=100;id=class{constructor(t=()=>globalThis.sessionStorage){x(this,ei);x(this,sd,new WeakMap);x(this,Ct,new Map);x(this,ad);x(this,Qo,0);x(this,xc,0);x(this,Ac,0);x(this,yc,0);g(this,ad,t)}get size(){return c(this,Ct).size}markEdited(){g(this,yc,c(this,Qo))}mintedBeforeLastEdit(t){if(c(this,yc)===0||!t.startsWith(J_))return!1;let n=Number(t.slice(J_.length));return Number.isSafeInteger(n)&&n>0&&n<=c(this,yc)}refFor(t){let n=c(this,sd).get(t);if(n!==void 0){let o=c(this,Ct).get(n);return c(this,Ct).delete(n),c(this,Ct).set(n,o!=null?o:new WeakRef(t)),n}c(this,Qo)>=c(this,xc)&&T(this,ei,PC).call(this),g(this,Qo,c(this,Qo)+1);let r=MI(`${J_}${String(c(this,Qo))}`);return c(this,sd).set(t,r),c(this,Ct).set(r,new WeakRef(t)),g(this,Ac,c(this,Ac)+1),c(this,Ac)>=tj?(g(this,Ac,0),T(this,ei,MC).call(this)):c(this,Ct).size>zC&&T(this,ei,Q_).call(this),r}resolve(t){let n=c(this,Ct).get(t);if(n===void 0)return null;let r=n.deref();return r===void 0||!r.isConnected?(c(this,Ct).delete(t),null):(c(this,Ct).delete(t),c(this,Ct).set(t,n),r)}};sd=new WeakMap,Ct=new WeakMap,ad=new WeakMap,Qo=new WeakMap,xc=new WeakMap,Ac=new WeakMap,yc=new WeakMap,ei=new WeakSet,PC=function(){let t;try{t=c(this,ad).call(this)}catch{t=void 0}let n=Math.max(rj(t),c(this,Qo));g(this,xc,n+nj);try{t==null||t.setItem(DC,String(c(this,xc)))}catch{}g(this,Qo,n)},Q_=function(){let t=c(this,Ct).keys().next();t.done!==!0&&c(this,Ct).delete(t.value)},MC=function(){for(let[t,n]of c(this,Ct)){let r=n.deref();(r===void 0||!r.isConnected)&&c(this,Ct).delete(t)}for(;c(this,Ct).size>zC;)T(this,ei,Q_).call(this)};re=new id});function UC(e){var n;return((n=e.match(/-?\d*\.?\d+(?:e[-+]?\d+)?|NaN|Infinity|-Infinity/gi))!=null?n:[]).map(r=>Number(r))}function sj(e){return/NaN|Infinity/i.test(e)?!0:UC(e).some(t=>!Number.isFinite(t))}function aj(e){let t=UC(e).filter(i=>Number.isFinite(i));if(t.length===0)return!0;let n=t.filter((i,s)=>s%2===0),r=t.filter((i,s)=>s%2===1),o=i=>i.every(s=>s===i[0]);return n.length>1&&o(n)&&o(r)}function Rh(e){let t=[],n=0;for(let o of oj)for(let i of Array.from(e.querySelectorAll(o)))for(let s of ij){let a=i.getAttribute(s);if(a===null)continue;n+=1;let l=a.length>120?`${a.slice(0,120)}\u2026`:a;sj(a)?t.push({kind:"non-finite-coordinates",tag:o,attr:s,sample:l}):a.trim().length===0?t.push({kind:"empty-geometry",tag:o,attr:s,sample:l}):aj(a)&&t.push({kind:"degenerate-geometry",tag:o,attr:s,sample:l})}let r=e.querySelectorAll("canvas").length>0;return{examined:n,findings:t,canvas:r}}function HC(e,t){var i,s,a,l,u,d,f;let n=t,r=(s=(i=n.Chart)==null?void 0:i.getChart)==null?void 0:s.call(i,e);if(r!=null)return{library:"chartjs",data:(a=r.data)!=null?a:null};let o=(u=(l=n.echarts)==null?void 0:l.getInstanceByDom)==null?void 0:u.call(l,e);return o!=null?{library:"echarts",data:(f=(d=o.getOption)==null?void 0:d.call(o))!=null?f:null}:null}var oj,ij,eS=y(()=>{"use strict";oj=["path","polyline","polygon"],ij=["d","points"]});function cd(e,t,n){let r=Math.max(0,Math.min(n,t.remainingCharacters));if(e.length<=r)return t.remainingCharacters-=e.length,e;t.truncatedValues+=1;let o=r<=ld.length?ld.slice(0,r):`${e.slice(0,r-ld.length)}${ld}`;return t.remainingCharacters-=o.length,o}function ud(e,t,n,r){if(r!==void 0&&St(r))return ve;if(n>Z.MAX_SERIALIZE_DEPTH||t.nodes>=wc)return t.truncatedValues+=1,ld;if(t.nodes+=1,e===null||typeof e=="boolean")return e;if(typeof e=="string")return cd(lo(e),t,(r==null?void 0:r.toLowerCase())==="error"?Z.MAX_ERROR_LENGTH:Z.MAX_STRING_LENGTH);if(typeof e=="number")return Number.isFinite(e)?e:null;if(typeof e=="bigint")return e.toString();if(typeof e=="undefined"||typeof e=="function"||typeof e=="symbol")return vc;if(e instanceof Date)return Number.isNaN(e.getTime())?null:e.toISOString();if(e instanceof Map){let o=Object.create(null),i=0;for(let[s,a]of e){if(t.nodes>=wc||i>=Z.MAX_COLLECTION_ITEMS){t.droppedItems+=e.size-i;break}let l=cd(typeof s=="string"?s:String(s),t,FC),u=ud(a,t,n+1,l);u!==vc&&(o[l]=u),i+=1}return o}if(e instanceof Set){let o=[],i=0;for(let s of e){if(t.nodes>=wc||i>=Z.MAX_COLLECTION_ITEMS){t.droppedItems+=e.size-i;break}let a=ud(s,t,n+1);o.push(a===vc?null:a),i+=1}return o}if(ArrayBuffer.isView(e)&&!(e instanceof DataView)){let o=e.length,i=[],s=0;for(let a of e){if(t.nodes>=wc||s>=Z.MAX_COLLECTION_ITEMS){t.droppedItems+=o-s;break}i.push(a),t.nodes+=1,s+=1}return i}if(e instanceof Error)return{name:cd(e.name,t,256),message:cd(e.message,t,Z.MAX_ERROR_LENGTH)};if(t.seen.has(e))return"[CIRCULAR]";t.seen.add(e);try{if(Array.isArray(e)){let l=[],u=e.slice(0,Z.MAX_COLLECTION_ITEMS);t.droppedItems+=Math.max(0,e.length-u.length);for(let d of u){if(t.nodes>=wc){t.droppedItems+=1;continue}let f=ud(d,t,n+1);if(t.nodes>=wc){t.droppedItems+=1;continue}l.push(f===vc?null:f)}return l}let o=Object.create(null),i=Object.keys(e),s=i.slice(0,Z.MAX_OBJECT_KEYS);t.droppedItems+=Math.max(0,i.length-s.length);let a=s.map(l=>{try{let u=e[l];return{key:l,value:u,scalar:u===null||typeof u!="object",ok:!0}}catch{return{key:l,value:void 0,scalar:!0,ok:!1}}});for(let l of[...a.filter(u=>u.scalar),...a.filter(u=>!u.scalar)]){let u=cd(l.key,t,FC);if(!l.ok){o[u]=tS;continue}try{let d=ud(l.value,t,n+1,l.key);d!==vc&&(o[u]=d)}catch{o[u]=tS}}return o}finally{t.seen.delete(e)}}function dd(e){return Ws(e).value}function Ws(e){let t={seen:new WeakSet,remainingCharacters:cj,nodes:0,droppedItems:0,truncatedValues:0},n=ud(e,t,0),r=n===vc?null:n;if(t.droppedItems===0&&t.truncatedValues===0)return{value:r};let o=[];return t.droppedItems>0&&o.push(`${t.droppedItems} item(s) dropped`),t.truncatedValues>0&&o.push(`${t.truncatedValues} value(s) truncated`),{value:r,truncation:{droppedItems:t.droppedItems,truncatedValues:t.truncatedValues,note:`partial \u2014 ${o.join(", ")}; this is NOT the whole value. Scope the read with \`path\`/\`depth\` to see the rest.`}}}function mo(e){try{return JSON.stringify(dd(e))}catch{return JSON.stringify(tS)}}var ld,tS,vc,FC,cj,wc,pr=y(()=>{"use strict";M();ld="[TRUNCATED]",tS="[UNSERIALIZABLE]",vc=Symbol("omit"),FC=256,cj=Math.floor(Z.MAX_MESSAGE_BYTES/4),wc=Z.MAX_COLLECTION_ITEMS*5});function lj(e){if(e===null)return;let t=/^(.*):(\d+):(\d+)$/.exec(e);if(t===null)return;let n=t[1],r=Number(t[2]);if(!(n===void 0||n.length===0||!Number.isFinite(r)))return{file:n,line:r}}function pd(e){let t=e.closest(`[${nS}]`);return t!==null?lj(t.getAttribute(nS)):void 0}function Oh(e,t){return t!==void 0?{file:t.file,line:t.line}:pd(e)}function BC(e){return e.querySelector(`[${nS}]`)!==null}function Ih(e){return e===void 0?void 0:`${e.file}:${String(e.line)}`}var nS,fd=y(()=>{"use strict";M();nS=mc});function pj(e){let t=e.type.toLowerCase();return t==="search"?"searchbox":dj.has(t)?"textbox":t==="checkbox"?"checkbox":t==="radio"?"radio":t==="range"?"slider":t==="number"?"spinbutton":t==="submit"||t==="button"||t==="reset"?"button":"textbox"}function fj(e){let t=e.getAttribute("aria-label");if(t!==null&&t.trim().length>0)return!0;let n=e.getAttribute("aria-labelledby");if(n!==null&&n.trim().length>0)return!0;let r=e.getAttribute("title");return r!==null&&r.trim().length>0}function Re(e){var r;let t=e.getAttribute("role");if(t!==null&&t.trim().length>0)return t.trim();switch(e.tagName.toLowerCase()){case"a":return e.hasAttribute("href")?"link":"generic";case"button":return"button";case"input":return pj(e);case"textarea":return"textbox";case"select":return e.multiple?"listbox":"combobox";case"h1":case"h2":case"h3":case"h4":case"h5":case"h6":return"heading";case"ul":case"ol":return"list";case"li":return"listitem";case"nav":return"navigation";case"main":return"main";case"aside":return"complementary";case"dialog":return"dialog";case"img":return"img";case"table":return"table";case"tr":return"row";case"tbody":case"thead":case"tfoot":return"rowgroup";case"td":return e.closest('[role~="grid"], [role~="treegrid"]')!==null?"gridcell":"cell";case"th":{let o=((r=e.getAttribute("scope"))!=null?r:"").toLowerCase();return o==="row"||o==="rowgroup"?"rowheader":"columnheader"}case"option":return"option";case"optgroup":return"group";case"section":return fj(e)?"region":"generic";case"article":return"article";case"fieldset":return"group";case"details":return"group";case"summary":return"button";case"progress":return"progressbar";case"meter":return"meter";case"output":return"status";case"hr":return"separator";case"area":return e.hasAttribute("href")?"link":"generic";case"form":return"form";case"p":return"paragraph";case"header":return"banner";case"footer":return"contentinfo";default:return"generic"}}function Bi(e){return e.replace(/\s+/g," ").trim()}function hj(e){let t=e.getAttribute("aria-labelledby");if(t===null)return null;let n=[];for(let o of t.split(/\s+/)){let i=e.ownerDocument.getElementById(o);i!==null&&n.push(Bi(Ys(i)))}let r=n.join(" ").trim();return r.length>0?r:null}function Ys(e){var o;if(e.nodeType===Node.TEXT_NODE)return(o=e.textContent)!=null?o:"";if(e.nodeType!==Node.ELEMENT_NODE)return"";let t=e;if(t.getAttribute("aria-hidden")==="true")return"";if(B_(t)){let i=t.getAttribute("alt");return i===null?"":i}let n="",r=!1;for(let i of t.childNodes){let s=Ys(i);if(s.length===0)continue;let a=Node.ELEMENT_NODE===i.nodeType;n.length>0&&(a||r)&&(n+=" "),n+=s,r=a}return n}function Ae(e){let t=hj(e);if(t!==null)return t;let n=e.getAttribute("aria-label");if(n!==null&&n.trim().length>0)return n.trim();if(B_(e)){let i=e.getAttribute("alt");if(i!==null)return i.trim()}if(He(e)||vn(e)||zr(e)||rd(e)||nC(e)||rC(e)||oC(e)){let i=e.labels;if(i!==null&&i.length>0){let s=[...i].map(a=>Bi(Ys(a))).join(" ").trim();if(s.length>0)return s}}if(e.tagName.toLowerCase()==="fieldset"){let i=[...e.children].find(s=>s.tagName.toLowerCase()==="legend");if(i!==void 0){let s=Bi(Ys(i));if(s.length>0)return s}}if(e.tagName.toLowerCase()==="table"){let i=[...e.children].find(s=>s.tagName.toLowerCase()==="caption");if(i!==void 0){let s=Bi(Ys(i));if(s.length>0)return s}}if(e.tagName.toLowerCase()==="figure"){let i=[...e.children].find(s=>s.tagName.toLowerCase()==="figcaption");if(i!==void 0){let s=Bi(Ys(i));if(s.length>0)return s}}if(He(e)||vn(e)||zr(e)){if(He(e)){let i=e.type.toLowerCase();if(i==="submit"||i==="button"||i==="reset"){let s=Bi(e.value);if(s.length>0)return s}}if(He(e)||vn(e)){let i=e.getAttribute("placeholder");if(i!==null&&i.trim().length>0)return i.trim()}}if(uj.has(Re(e))){let i=Bi(Ys(e));if(i.length>0)return i}let o=e.getAttribute("title");return o!==null&&o.trim().length>0?o.trim():""}function Ch(e,t){let n=e.getAttribute(t);if(n!==null)return n==="true"}function ti(e,t=Ke(e)){let n=[Se.PRESENT];n.push(t?Se.VISIBLE:Se.HIDDEN);let r=e.matches(":disabled")||Ch(e,"aria-disabled")===!0;return n.push(r?Se.DISABLED:Se.ENABLED),(He(e)&&(e.type==="checkbox"||e.type==="radio")&&e.checked||Ch(e,"aria-checked")===!0)&&n.push(Se.CHECKED),(Ch(e,"aria-expanded")===!0||mj(e))&&n.push(Se.EXPANDED),Ch(e,"aria-pressed")===!0&&n.push(Se.PRESSED),e.ownerDocument.activeElement===e&&n.push(Se.FOCUSED),n}function mj(e){let t=e.parentElement;return Sh!==e.localName||t===null||j_!==t.localName?!1:Array.from(t.children).find(r=>Sh===r.localName)===e&&t.hasAttribute(K_)}function pn(e){var o,i,s,a,l;if(!He(e)&&!vn(e)&&!zr(e))return!1;let t=(o=e.getAttribute("autocomplete"))!=null?o:"",n=[(i=e.getAttribute("name"))!=null?i:"",e.id,(s=Ne(e))!=null?s:"",(a=e.getAttribute(Hs))!=null?a:"",(l=e.getAttribute("aria-label"))!=null?l:""],r=gj.test(t);return He(e)&&e.type.toLowerCase()==="password"||r||n.some(St)}function rS(e){if(He(e)||vn(e)||zr(e))return pn(e)?e.value===""?"":ve:e.value;let t=e.getAttribute("aria-valuenow");return t!=null?t:void 0}function Ej(e,t){var o;let n=Bi((o=e.textContent)!=null?o:""),r=t?Z.MAX_FULL_TEXT:Z.MAX_DESCRIBED_TEXT;return n.length>r?`${n.slice(0,r)}\u2026`:n}function go(e,t,n=!1){let r=rS(e),o=Ej(e,n),i=Ae(e),s=Ke(e,t),a={ref:re.refFor(e),role:Re(e),name:i,states:ti(e,s),visible:s};r!==void 0&&r.length>0&&(a.value=r),o.length>0&&(n||o!==i)&&(a.text=o);let l=Ih(pd(e));if(l!==void 0&&(a.source=l),e.querySelector("path, polyline, polygon")!==null){let u=Rh(e).findings;u.length>0&&(a.chart=u)}return a}var uj,dj,gj,Et=y(()=>{"use strict";It();M();dn();gt();eS();pr();fd();Dr();uj=new Set(["button","link","heading","option","listitem","cell","checkbox","columnheader","radio","row","rowheader","tab","tooltip","menuitem","menuitemcheckbox","menuitemradio","treeitem","gridcell","switch","status","alert"]),dj=new Set(["text","email","tel","url","password",""]);gj=/\b(cc-|current-password|new-password|one-time-code)/i});function tL(e){Oc.some(t=>t.name===e.name)||Oc.push(e)}function fr(e){for(let t of Oc){let n;try{n=t.identify(e)}catch{continue}if(n!=null)return n}return null}function $h(e){for(let t of Oc){if(t.readState===void 0)continue;let n=t.readState(e);if(n!==void 0)return n}}function kh(e){for(let t of Oc)if(t.hasHoverHandlers!==void 0&&t.hasHoverHandlers(e))return!0;return!1}function Ed(){return Oc.map(e=>e.name)}var aS,eL,Oc,ni=y(()=>{"use strict";aS=globalThis,Oc=(eL=aS.__reticleAdapters)!=null?eL:aS.__reticleAdapters=[]});function zh(){return lr(location.href)}function Dh(e=!0){return lr(`${location.pathname}${location.search}${e?location.hash:""}`)}var bd=y(()=>{"use strict";M()});function yL(e){var o;let t=[],n=new Set,r;try{r=e.querySelectorAll(jn())}catch{return t}for(let i=0;i<r.length&&t.length<t6;i+=1){let s=(o=r[i])==null?void 0:o.getAttribute(Fi());if(s==null)continue;let a=s.trim();a.length===0||n.has(a)||a.startsWith(n6)||(n.add(a),t.push(a))}return t}var t6,n6,wL=y(()=>{"use strict";It();t6=200,n6="reticle-"});var dS,vL,pS,Mr,_d=y(()=>{"use strict";dS=globalThis,pS=typeof((vL=dS.console)==null?void 0:vL.warn)=="function"?dS.console.warn.bind(dS.console):null,Mr=(...e)=>{pS==null||pS(...e)}});function LL(e){return fS.add(e),()=>fS.delete(e)}function r6(e){if(e===null||typeof e!="object"&&typeof e!="function")return!1;let t=e;return typeof t.getState=="function"&&typeof t.subscribe=="function"}function $L(e,t,n){if(s6(e,t),r6(t)){let r=()=>t.getState(),o=i=>t.subscribe(i);Ic.set(e,r),Uh.set(e,o),NL(e,r,o);return}if(typeof t!="function"){let r=typeof t=="object"&&t!==null&&"subscribe"in t;Mr(`[reticle] store "${e}" is neither a getter function nor a {getState, subscribe} store`+(r?" \u2014 it has subscribe but no getState. Wrap it with an adapter or add getState.":"."));return}if(Ic.set(e,t),n!==void 0){Uh.set(e,n),NL(e,t,n);return}i6(e)}function NL(e,t,n){for(let r of fS)try{r([e,t,n])}catch{}}function kL(e){Ic.delete(e),Uh.delete(e)}function ji(){return[...Ic.keys()]}function zL(){let e=[];for(let[t,n]of Uh){let r=Ic.get(t);r!==void 0&&e.push([t,r,n])}return e}function mS(e){let t={};for(let[n,r]of Ic)if(!(e!==void 0&&n!==e))try{t[n]=r()}catch(o){t[n]={__error:o instanceof Error?o.message:String(o)}}return t}function DL(e){return Sd(e).stores}function Sd(e){let t={},n={};for(let[r,o]of Object.entries(mS(e))){let i=Ws(o);t[r]=i.value,i.truncation!==void 0&&(n[r]=i.truncation)}return Object.keys(n).length>0?{stores:t,truncation:n}:{stores:t}}function i6(e){o6.has(e)||RL.has(e)||(RL.add(e),Mr(`[reticle] store "${e}" was registered without a subscribe function. It can be READ, but its changes are invisible: no STATE_CHANGE events, no state diffs in causal summaries, and a state predicate will never see it update. Pass the store object (or a subscribe callback) to fix.`))}function Hh(e,t){PL.set(e,t)}function s6(e,t){if(t===null||typeof t!="object"&&typeof t!="function")return;hS.set(t,e);let n=PL.get(t);n!==void 0&&hS.set(n,e)}function ML(e){if(!(e===null||typeof e!="object"&&typeof e!="function"))return hS.get(e)}var ri,OL,Ic,IL,Uh,CL,fS,RL,o6,hS,PL,Xs=y(()=>{"use strict";M();_d();pr();ri=globalThis,Ic=(OL=ri.__reticleStores)!=null?OL:ri.__reticleStores=new Map,Uh=(IL=ri.__reticleStoreSubs)!=null?IL:ri.__reticleStoreSubs=new Map,fS=(CL=ri.__reticleStoreListeners)!=null?CL:ri.__reticleStoreListeners=new Set;RL=new Set,o6=new Set([jf]);hS=new WeakMap,PL=new WeakMap});function HL(){return typeof document=="undefined"?[]:yL(document)}function FL(){return ji().filter(e=>jf!==e)}function Bh(e,t){let n=[...e];for(let r of t)n.includes(r)||n.push(r);return n}function a6(){return{testids:[],signals:[],stores:[],flows:[]}}function ES(e,t){if(t!==void 0)for(let n of t)e.includes(n)||e.push(n)}function Gh(e){Fh=e}function Cc(e){if(ES(Nn.testids,e.testids),ES(Nn.signals,e.signals),ES(Nn.stores,e.stores),e.flows!==void 0)for(let t of e.flows){let n=Nn.flows.find(r=>r.name===t.name);n===void 0?Nn.flows.push({name:t.name,steps:[...t.steps]}):n.steps=[...t.steps]}Fh==null||Fh()}function Ki(){return{testids:Bh(Nn.testids,HL()),signals:[...Nn.signals],stores:Bh(Nn.stores,FL()),flows:Nn.flows.map(e=>({name:e.name,steps:[...e.steps]})),...vC()?{presenterExposed:!0}:{}}}function BL(){return[...Nn.testids]}function Vh(){return Nn.signals.length>0||Nn.flows.length>0||Bh(Nn.testids,HL()).length>0||Bh(Nn.stores,FL()).length>0}var gS,UL,Nn,Fh,Zi=y(()=>{"use strict";M();ot();wL();Xs();gS=globalThis;Nn=(UL=gS.__reticleCapabilities)!=null?UL:gS.__reticleCapabilities=a6()});function Yh(){return wS>0}function it(e){wS+=1;try{return e()}finally{wS-=1}}var wS,zc=y(()=>{"use strict";wS=0});function g$(e){if(!(typeof e!="number"||!Number.isFinite(e)))return Math.max(0,Math.min(e,IS))}var mr,u$,OS,d$,f$,p$,qh,de,Oe,Jh,IS,h$,Eo,m$,dt=y(()=>{"use strict";mr=globalThis,u$=typeof mr.setTimeout=="function"?mr.setTimeout.bind(mr):null,OS=typeof mr.clearTimeout=="function"?mr.clearTimeout.bind(mr):null,d$=typeof mr.requestAnimationFrame=="function"?mr.requestAnimationFrame.bind(mr):null,p$=typeof((f$=mr.performance)==null?void 0:f$.now)=="function"?mr.performance.now.bind(mr.performance):null,qh=()=>p$?p$():0,de=(e,t=0)=>u$?u$(e,t):0,Oe=e=>{OS==null||OS(e)},Jh=(e,t)=>{let n=!1,r=0,o=()=>{n||(e(),!n&&(r=de(o,t)))};return r=de(o,t),()=>{n=!0,Oe(r)}},IS=200,h$=(e=IS)=>new Promise(t=>{let n=!1,r=i=>{n||(n=!0,Oe(o),t({settled:i}))},o=de(()=>r(!1),e);d$?d$(()=>r(!0)):de(()=>r(!0),0)}),Eo=()=>h$().then(()=>{}),m$=async(e=IS)=>(await Promise.resolve(),h$(e))});var Ak={};qa(Ak,{MASK:()=>Tk,cloneForRender:()=>xk,renderPage:()=>Z3});function F3(e){var t;return e instanceof HTMLInputElement&&e.type==="password"?!0:[e.name,e.id,(t=e.getAttribute("autocomplete"))!=null?t:""].some(n=>n.length>0&&St(n))}function B3(e,t){if(e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement){let n=F3(e)&&e.value.length>0?Tk:e.value;e instanceof HTMLTextAreaElement?t.textContent=n:t.setAttribute("value",n)}e instanceof HTMLInputElement&&(e.checked?t.setAttribute("checked",""):t.removeAttribute("checked")),e instanceof HTMLOptionElement&&(e.selected?t.setAttribute("selected",""):t.removeAttribute("selected"))}function G3(e){var r;let t=[...Array.from(e.styleSheets),...(r=e.adoptedStyleSheets)!=null?r:[]],n=[];for(let o of t)try{for(let i of Array.from(o.cssRules))n.push(i.cssText)}catch{}return n.join(`
58
+ `)}function xk(e){var a;let t=e.documentElement,n=t.cloneNode(!0),r=t.querySelectorAll("*"),o=n.querySelectorAll("*");r.forEach((l,u)=>{let d=o[u];d!==void 0&&B3(l,d)});let i=[Ui,"script","noscript",'link[rel~="stylesheet"]',"style"];n.querySelectorAll(i.join(",")).forEach(l=>l.remove());let s=e.createElement("style");return s.textContent=G3(e),((a=n.querySelector("head"))!=null?a:n).append(s),n}function V3(e){let t=e.defaultView;for(let n of[e.body,e.documentElement]){if(t===null||n===null)continue;let r=t.getComputedStyle(n).backgroundColor;if(r.length>0&&r!=="transparent"&&r!=="rgba(0, 0, 0, 0)")return r}return M3}function j3(e){return new Promise((t,n)=>{let r=new Image,o=setTimeout(()=>n(new Error("the page did not render in time")),D3);r.onload=()=>{clearTimeout(o),t(r)},r.onerror=()=>{clearTimeout(o),n(new Error("the page could not be drawn as an image"))},r.src=e})}function K3(e){let t=[];for(let n=0;n<e.length;n+=Sk)t.push(e.slice(n,n+Sk));return t}async function Z3(){try{let e=Math.max(1,window.innerWidth),t=Math.max(1,window.innerHeight),n=xk(document);n.style.transform=`translate(${String(-window.scrollX)}px, ${String(-window.scrollY)}px)`;let r=new XMLSerializer().serializeToString(n),o=`<svg xmlns="${P3}" width="${String(e)}" height="${String(t)}"><foreignObject x="0" y="0" width="100%" height="100%">${r}</foreignObject></svg>`,i=await j3(`data:image/svg+xml;charset=utf-8,${encodeURIComponent(o)}`),s=V3(document),a=Math.min(1,kb.MAX_SIDE_PX/Math.max(e,t));for(let l=0;l<z3;l+=1,a*=k3){let u=document.createElement("canvas");u.width=Math.max(1,Math.round(e*a)),u.height=Math.max(1,Math.round(t*a));let d=u.getContext("2d");if(d===null)return{ok:!1,reason:"this page has no 2D canvas to draw into"};d.fillStyle=s,d.fillRect(0,0,u.width,u.height),d.drawImage(i,0,0,u.width,u.height);let f=u.toDataURL(U3,kb.JPEG_QUALITY).replace(H3,"");if(f.length<=$3)return{ok:!0,width:u.width,height:u.height,chunks:K3(f)}}return{ok:!1,reason:"the rendered page was too large to send, even scaled down"}}catch(e){return{ok:!1,reason:e instanceof Error?e.message:String(e)}}}var Tk,$3,Sk,k3,z3,D3,P3,M3,U3,H3,yk=y(()=>{"use strict";M();ot();Tk="\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022",$3=24e4,Sk=6e4,k3=.75,z3=4,D3=5e3,P3="http://www.w3.org/2000/svg",M3="#ffffff",U3="image/jpeg",H3=/^data:[^,]*,/});function gm(e,t){return`${V0}${e}. ${String(t)} attempts, all failed. That is everything the page can see: from inside the browser it cannot tell a daemon that is not there from one it is not allowed to reach, so this is not evidence about the daemon. What answers it: run \`npx @reticlehq/server status\` to see whether one is listening and on which port. If your app runs in a container, devcontainer or WSL, the daemon is on a different host, so point the page at it: RETICLE_PORT or reticle({ port }) with the Vite plugin, reticle.connect({ url }) by hand. An https page cannot open a ws:// socket. Still retrying\u2026`}var $k,YS=y(()=>{"use strict";M();$k="Can't reach Reticle from this page. Run reticle status to check, or reticle serve to start it."});var Ge,Kn,hn,lT=y(()=>{"use strict";Ge={READ:"read",ACT:"act",NARRATION:"narration",HUMAN:"human"},Kn={PASS:"pass",FAIL:"fail"},hn={AGENT:"agent",HARNESS:"harness"}});function Md(e){switch(e){case D.CLICK:case D.DBLCLICK:return"Clicking";case D.FILL:case D.TYPE:return"Typing into";case D.HOVER:return"Hovering";case D.SELECT:return"Selecting";case D.SUBMIT:return"Submitting";case D.CHECK:case D.UNCHECK:return"Toggling";case D.UPLOAD:return"Uploading to";case D.DRAG:return"Dragging";default:return e}}var uT=y(()=>{"use strict";M()});function li(e){return typeof e=="string"&&e.length>0}function a9(e){var n;return`${(n=e.file.split("/").pop())!=null?n:e.file}:${e.line}`}function pD(e){var t;if(li(e.testid))return{strategy:Fr.TESTID,value:e.testid,stable:!0};if(li(e.component)&&e.source!==void 0)return{strategy:Fr.COMPONENT,value:`${e.component}@${a9(e.source)}`,stable:!0};if(li(e.component)&&(li(e.role)||li(e.name))){let n=li(e.name)?e.name:e.role;return{strategy:Fr.COMPONENT,value:`${e.component}[${n!=null?n:""}]`,stable:!0}}if(li(e.role)&&li(e.name))return{strategy:Fr.ROLE,value:`${e.role}:${e.name}`,stable:!1};if(li(e.role)){let n=e.nth!==void 0?`#${e.nth}`:"";return{strategy:Fr.ROLE,value:`${e.role}${n}`,stable:!1}}return{strategy:Fr.POSITION,value:`el#${(t=e.nth)!=null?t:0}`,stable:!1}}var Fr,fD=y(()=>{"use strict";Fr={TESTID:"testid",COMPONENT:"component",ROLE:"role",POSITION:"position"}});function l9(e,t,n){return n.length>0?t.length>0?`${t} "${n}"`:`"${n}"`:t.length>0?t:e.tagName.toLowerCase()}function Gd(e){var d;let t=(d=Ne(e))!=null?d:void 0,n=fr(e),r=n==null?void 0:n.componentStack[0],o=Oh(e,n==null?void 0:n.source),i=Re(e),s=Ae(e),a={};t!==void 0&&(a.testid=t),r!==void 0&&(a.component=r),o!==void 0&&(a.source=o),i.length>0&&(a.role=i),s.length>0&&(a.name=s);let l=pD(a),u={anchor:l.value,strategy:c9[l.strategy],label:l9(e,i,s)};return o!==void 0&&(u.source=o),u}var c9,mT=y(()=>{"use strict";It();M();fD();Et();ni();fd();c9={[Fr.TESTID]:Bs.TESTID,[Fr.COMPONENT]:Bs.COMPONENT,[Fr.ROLE]:Bs.ROLE,[Fr.POSITION]:Bs.POSITION}});function hD(e){return`${String(e)} ${e===1?"note":"notes"} on this page`}function Nm(e,t){let n=e.length,r=`I marked ${String(n)} ${n===1?"issue":"issues"} on ${t} with Reticle. Fix each one, then verify it in the running app:`,o=e.map((i,s)=>{let a=i.source===void 0?i.anchor:`${i.anchor}, ${i.source}`;return`${String(s+1)}. ${i.note}
59
59
  ${i.label} (${a}) on ${i.route}`});return[r,"",...o].join(`
60
- `)}var iT=y(()=>{"use strict"});var ym,Oe,sT,nD,rD,oD,eD,iD,sD,aD=y(()=>{"use strict";ym="data-reticle-mark",Oe=e=>`[${ym}="${e}"]`,sT="What should change?",nD="Add",rD="Cancel",oD="+",eD=2147483601,iD=`
61
- ${Oe("root")}{position:fixed;inset:0;pointer-events:none;z-index:${String(eD)};}
62
- ${Oe("root")}[data-hide="1"] ${Oe("pin")}{display:none;}
60
+ `)}var gT=y(()=>{"use strict"});var Rm,Ie,ET,ED,bD,_D,mD,SD,TD,xD=y(()=>{"use strict";Rm="data-reticle-mark",Ie=e=>`[${Rm}="${e}"]`,ET="What should change?",ED="Add",bD="Cancel",_D="+",mD=2147483601,SD=`
61
+ ${Ie("root")}{position:fixed;inset:0;pointer-events:none;z-index:${String(mD)};}
62
+ ${Ie("root")}[data-hide="1"] ${Ie("pin")}{display:none;}
63
63
  html[data-reticle-mark-active] *{cursor:crosshair !important;}
64
64
  html[data-reticle-mark-active] [data-reticle-overlay],
65
65
  html[data-reticle-mark-active] [data-reticle-overlay] *,
66
- html[data-reticle-mark-active] ${Oe("pop")},
67
- html[data-reticle-mark-active] ${Oe("pop")} *,
68
- html[data-reticle-mark-active] ${Oe("pin")},
69
- html[data-reticle-mark-active] ${Oe("pending")}{cursor:pointer !important;}
70
- ${Oe("hi")}{position:fixed;pointer-events:none;opacity:0;box-sizing:border-box;
66
+ html[data-reticle-mark-active] ${Ie("pop")},
67
+ html[data-reticle-mark-active] ${Ie("pop")} *,
68
+ html[data-reticle-mark-active] ${Ie("pin")},
69
+ html[data-reticle-mark-active] ${Ie("pending")}{cursor:pointer !important;}
70
+ ${Ie("hi")}{position:fixed;pointer-events:none;opacity:0;box-sizing:border-box;
71
71
  border:2px solid color-mix(in srgb, var(--reticle-mark-accent, #0088ff) 50%, transparent);
72
72
  border-radius:4px;background:color-mix(in srgb, var(--reticle-mark-accent, #0088ff) 4%, transparent);}
73
- ${Oe("hi")}[data-on="1"]{opacity:1;animation:reticle-mark-hi-in .12s ease-out;}
74
- ${Oe("hilabel")}{position:absolute;top:-28px;left:0;font:500 11px/1.2 system-ui,sans-serif;color:#fff;
73
+ ${Ie("hi")}[data-on="1"]{opacity:1;animation:reticle-mark-hi-in .12s ease-out;}
74
+ ${Ie("hilabel")}{position:absolute;top:-28px;left:0;font:500 11px/1.2 system-ui,sans-serif;color:#fff;
75
75
  background:rgba(0,0,0,.85);padding:.35rem .6rem;border-radius:.375rem;white-space:nowrap;
76
76
  max-width:280px;overflow:hidden;text-overflow:ellipsis;pointer-events:none;}
77
- ${Oe("sel")}{position:fixed;pointer-events:none;box-sizing:border-box;border-radius:4px;
77
+ ${Ie("sel")}{position:fixed;pointer-events:none;box-sizing:border-box;border-radius:4px;
78
78
  border:2px solid color-mix(in srgb, var(--reticle-mark-accent, #0088ff) 60%, transparent);
79
79
  background:color-mix(in srgb, var(--reticle-mark-accent, #0088ff) 5%, transparent);}
80
- ${Oe("pin")},${Oe("pending")}{position:fixed;pointer-events:auto;width:22px;height:22px;
80
+ ${Ie("pin")},${Ie("pending")}{position:fixed;pointer-events:auto;width:22px;height:22px;
81
81
  margin:0;border:none;border-radius:50%;background:var(--reticle-mark-accent, #0088ff);color:#fff;
82
82
  font:600 11px/22px system-ui,sans-serif;text-align:center;cursor:pointer;
83
83
  box-shadow:0 2px 6px rgba(0,0,0,.2),inset 0 0 0 1px rgba(0,0,0,.04);
84
84
  transform:translate(-50%,-50%);user-select:none;z-index:1;}
85
- ${Oe("pin")}:hover{transform:translate(-50%,-50%) scale(1.1);z-index:2;}
86
- ${Oe("pin")}[data-stale="1"]{opacity:.45;}
87
- ${Oe("pending")}{cursor:default;}
88
- ${Oe("tip")}{position:absolute;top:calc(100% + 10px);left:50%;transform:translateX(-50%) scale(.909);
85
+ ${Ie("pin")}:hover{transform:translate(-50%,-50%) scale(1.1);z-index:2;}
86
+ ${Ie("pin")}[data-stale="1"]{opacity:.45;}
87
+ ${Ie("pending")}{cursor:default;}
88
+ ${Ie("tip")}{position:absolute;top:calc(100% + 10px);left:50%;transform:translateX(-50%) scale(.909);
89
89
  background:#1a1a1a;color:#fff;padding:8px 12px;border-radius:12px;min-width:120px;max-width:200px;
90
90
  box-shadow:0 4px 20px rgba(0,0,0,.3),0 0 0 1px rgba(255,255,255,.08);pointer-events:none;text-align:left;
91
91
  font:400 13px/1.4 system-ui,sans-serif;display:none;z-index:3;}
92
- ${Oe("pin")}:hover ${Oe("tip")}{display:block;}
93
- ${Oe("tipq")}{display:block;font-size:12px;font-style:italic;color:rgba(255,255,255,.6);
92
+ ${Ie("pin")}:hover ${Ie("tip")}{display:block;}
93
+ ${Ie("tipq")}{display:block;font-size:12px;font-style:italic;color:rgba(255,255,255,.6);
94
94
  margin-bottom:5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
95
- ${Oe("tipn")}{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
96
- ${Oe("pop")}{position:fixed;pointer-events:auto;width:280px;box-sizing:border-box;padding:12px 16px 14px;
97
- background:#1a1a1a;border-radius:16px;color:#fff;z-index:${String(eD+8)};
95
+ ${Ie("tipn")}{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
96
+ ${Ie("pop")}{position:fixed;pointer-events:auto;width:280px;box-sizing:border-box;padding:12px 16px 14px;
97
+ background:#1a1a1a;border-radius:16px;color:#fff;z-index:${String(mD+8)};
98
98
  box-shadow:0 4px 24px rgba(0,0,0,.3),0 0 0 1px rgba(255,255,255,.08);
99
99
  font:13px/1.45 system-ui,-apple-system,"Segoe UI",sans-serif;transform:translateX(-50%);opacity:0;}
100
- ${Oe("pop")}[data-in="1"]{opacity:1;animation:reticle-mark-pop-in .2s cubic-bezier(.34,1.56,.64,1) forwards;}
101
- ${Oe("pop")}.reticle-mark-shake{animation:reticle-mark-shake .25s ease-out;}
102
- ${Oe("pop")} .reticle-mark-where{font-size:12px;font-weight:400;color:rgba(255,255,255,.5);
100
+ ${Ie("pop")}[data-in="1"]{opacity:1;animation:reticle-mark-pop-in .2s cubic-bezier(.34,1.56,.64,1) forwards;}
101
+ ${Ie("pop")}.reticle-mark-shake{animation:reticle-mark-shake .25s ease-out;}
102
+ ${Ie("pop")} .reticle-mark-where{font-size:12px;font-weight:400;color:rgba(255,255,255,.5);
103
103
  margin-bottom:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
104
- ${Oe("pop")} textarea{box-sizing:border-box;width:100%;min-height:52px;resize:none;padding:8px 10px;
104
+ ${Ie("pop")} textarea{box-sizing:border-box;width:100%;min-height:52px;resize:none;padding:8px 10px;
105
105
  font:13px/1.45 inherit;background:rgba(255,255,255,.05);color:#fff;
106
106
  border:1px solid rgba(255,255,255,.15);border-radius:8px;outline:none;}
107
- ${Oe("pop")} textarea:focus{border-color:var(--reticle-mark-accent, #0088ff);}
108
- ${Oe("pop")} textarea::placeholder{color:rgba(255,255,255,.35);}
109
- ${Oe("pop")} .reticle-mark-row{display:flex;justify-content:flex-end;gap:6px;margin-top:8px;}
110
- ${Oe("pop")} button{font:500 12px/1 system-ui,sans-serif;padding:.4rem .875rem;border-radius:1rem;
107
+ ${Ie("pop")} textarea:focus{border-color:var(--reticle-mark-accent, #0088ff);}
108
+ ${Ie("pop")} textarea::placeholder{color:rgba(255,255,255,.35);}
109
+ ${Ie("pop")} .reticle-mark-row{display:flex;justify-content:flex-end;gap:6px;margin-top:8px;}
110
+ ${Ie("pop")} button{font:500 12px/1 system-ui,sans-serif;padding:.4rem .875rem;border-radius:1rem;
111
111
  border:none;cursor:pointer;background:transparent;color:rgba(255,255,255,.5);}
112
- ${Oe("pop")} button:hover{background:rgba(255,255,255,.1);color:rgba(255,255,255,.8);}
113
- ${Oe("pop")} button[data-send]{background:var(--reticle-mark-accent, #0088ff);color:#fff;}
114
- ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
112
+ ${Ie("pop")} button:hover{background:rgba(255,255,255,.1);color:rgba(255,255,255,.8);}
113
+ ${Ie("pop")} button[data-send]{background:var(--reticle-mark-accent, #0088ff);color:#fff;}
114
+ ${Ie("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
115
115
  @keyframes reticle-mark-hi-in{from{opacity:0;transform:scale(.98)}to{opacity:1;transform:scale(1)}}
116
116
  @keyframes reticle-mark-pop-in{from{opacity:0;transform:translateX(-50%) scale(.95) translateY(4px)}
117
117
  to{opacity:1;transform:translateX(-50%) scale(1) translateY(0)}}
@@ -121,23 +121,23 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
121
121
  40%{transform:translateX(calc(-50% + 3px))}
122
122
  60%{transform:translateX(calc(-50% - 2px))}
123
123
  80%{transform:translateX(calc(-50% + 2px))}}
124
- `,sD=`<div ${ym}="hi"><span ${ym}="hilabel"></span></div><div ${ym}="sel" hidden></div>`});function uD(e){return e.source===void 0?void 0:`${e.source.file}:${String(e.source.line)}`}function vm(){return typeof location=="undefined"?"":location.pathname+location.search}function OZ(e){return Ud(e).anchor}function IZ(e){if(e===void 0||typeof getComputedStyle=="undefined")return!1;let t=getComputedStyle(e).position;return t==="fixed"||t==="sticky"}function pD(e,t){let n=document.elementsFromPoint.bind(document);if(n!==void 0){for(let r of n(e,t))if(!lr(r))return r}}function fD(e,t){let n=window.innerWidth,r=window.innerHeight,o=Math.min(Math.max(e,wm+cD/2),n-wm-cD/2),i=t+12;return i+lD>r-wm&&(i=Math.max(wm,t-lD-12)),{left:o,top:i}}function CZ(e){var i;let t=Ne(e);if(t!==null&&t.length>0)return t;let n=e.tagName.toLowerCase(),r=e.getAttribute("aria-label");if(r!==null&&r.length>0)return`${n} "${r}"`;let o=((i=e.textContent)!=null?i:"").trim().replace(/\s+/g," ").slice(0,40);return o.length>0?`${n} "${o}"`:n}function yD(e){let t=new da(e);return t.mount(),t}var NZ,RZ,cD,lD,wm,_o,aT,ai,el,tl,Fd,Bd,Gd,Wn,Yn,nl,na,Rn,ra,mr,ci,gr,Ut,rs,oa,li,ui,ia,sa,Vd,jd,aa,rl,ol,ca,V,hD,Qc,mD,gD,ED,bD,Nm,cT,lT,_D,uT,la,ua,SD,dT,pT,TD,fT,hT,xD,Hd,mT,AD,Ur,da,dD,gT=y(()=>{"use strict";Ot();Lc();M();nt();oT();iT();dt();aD();NZ=130,RZ=250,cD=280,lD=170,wm=8,_o="data-reticle-mark",aT="data-reticle-mark-active",ai=e=>`[${_o}="${e}"]`,da=class{constructor(t){x(this,V);x(this,el);x(this,tl);x(this,Fd);x(this,Bd);x(this,Gd);x(this,Wn);x(this,Yn);x(this,nl);x(this,na);x(this,Rn);x(this,ra);x(this,mr);x(this,ci);x(this,gr,!1);x(this,Ut,[]);x(this,rs);x(this,oa);x(this,li);x(this,ui);x(this,ia);x(this,sa);x(this,Vd);x(this,jd);x(this,aa);x(this,rl);x(this,ol);x(this,ca);x(this,la);x(this,ua,{x:0,y:0});var n;g(this,el,t.emit),g(this,tl,t.now),g(this,Fd,t.onMark),g(this,Bd,(n=t.shouldBlock)!=null?n:(()=>!0)),g(this,Gd,t.onCountChange)}get active(){return c(this,gr)}get markCount(){return c(this,Ut).length}annotations(){return c(this,Ut).map(({id:t,createdAt:n,note:r,label:o,anchor:i,route:s,source:a})=>({id:t,createdAt:n,note:r,label:o,anchor:i,route:s,...a===void 0?{}:{source:a}}))}mount(){var o,i,s;if(c(this,Wn)!==void 0||typeof document=="undefined")return;let t=document.createElement("style");t.setAttribute(_o,"style"),t.textContent=iD,document.head.appendChild(t);let n=document.createElement("div");n.setAttribute(_o,"root"),n.innerHTML=sD,document.body.appendChild(n),g(this,Wn,n),g(this,Yn,(o=n.querySelector(ai("hi")))!=null?o:void 0),g(this,nl,(i=n.querySelector(ai("hilabel")))!=null?i:void 0),g(this,na,(s=n.querySelector(ai("sel")))!=null?s:void 0);let r=new AbortController;g(this,ol,r),document.addEventListener("click",a=>T(this,V,gD).call(this,a),{capture:!0,signal:r.signal}),document.addEventListener("mousemove",a=>T(this,V,ED).call(this,a),{passive:!0,capture:!0,signal:r.signal}),document.addEventListener("keydown",a=>T(this,V,mD).call(this,a),{signal:r.signal}),window.addEventListener("scroll",()=>T(this,V,mT).call(this),{capture:!0,signal:r.signal}),window.addEventListener("resize",()=>T(this,V,mT).call(this),{signal:r.signal}),g(this,ca,new MutationObserver(()=>this.syncAnchors())),c(this,ca).observe(document.documentElement,{childList:!0,subtree:!0}),c(this,rl)!==void 0&&this.setAccent(c(this,rl))}setAccent(t){var n;g(this,rl,t),(n=c(this,Wn))==null||n.style.setProperty("--reticle-mark-accent",t)}attachChrome(t){var n,r;g(this,ui,t.markersBtn),g(this,ia,t.clearBtn),g(this,sa,t.copyRow),g(this,Vd,t.onCount),g(this,jd,t.onMarksChange),g(this,aa,t.countEl),(n=c(this,ui))==null||n.addEventListener("click",o=>{o.stopPropagation(),T(this,V,hD).call(this)}),(r=c(this,ia))==null||r.addEventListener("click",o=>{o.stopPropagation(),this.clearAll()}),T(this,V,Qc).call(this)}destroy(){var t,n,r;(t=c(this,ol))==null||t.abort(),g(this,ol,void 0),(n=c(this,ca))==null||n.disconnect(),g(this,ca,void 0),c(this,mr)!==void 0&&Re(c(this,mr)),c(this,ci)!==void 0&&Re(c(this,ci)),T(this,V,Ur).call(this),document.documentElement.removeAttribute(aT),(r=c(this,Wn))==null||r.remove(),document.querySelectorAll(`style[${_o}="style"]`).forEach(o=>o.remove()),g(this,Wn,void 0),g(this,gr,!1),g(this,Ut,[])}toggle(t){g(this,gr,t!=null?t:!c(this,gr)),c(this,gr)?document.documentElement.setAttribute(aT,"1"):(document.documentElement.removeAttribute(aT),T(this,V,Nm).call(this),T(this,V,Ur).call(this)),T(this,V,Qc).call(this)}agentPrompt(t){return Am(c(this,Ut),t)}clearAll(){T(this,V,Ur).call(this);for(let t of c(this,Ut))t.pin.remove();g(this,Ut,[]),T(this,V,Qc).call(this)}syncAnchors(){let t=vm();for(let n of c(this,Ut))n.target!==void 0&&document.contains(n.target)?n.pin.removeAttribute("data-stale"):(n.target=void 0,n.pin.setAttribute("data-stale","1")),n.pin.hidden=n.route!==t;T(this,V,Hd).call(this)}};el=new WeakMap,tl=new WeakMap,Fd=new WeakMap,Bd=new WeakMap,Gd=new WeakMap,Wn=new WeakMap,Yn=new WeakMap,nl=new WeakMap,na=new WeakMap,Rn=new WeakMap,ra=new WeakMap,mr=new WeakMap,ci=new WeakMap,gr=new WeakMap,Ut=new WeakMap,rs=new WeakMap,oa=new WeakMap,li=new WeakMap,ui=new WeakMap,ia=new WeakMap,sa=new WeakMap,Vd=new WeakMap,jd=new WeakMap,aa=new WeakMap,rl=new WeakMap,ol=new WeakMap,ca=new WeakMap,V=new WeakSet,hD=function(){var r,o;let t=c(this,Wn);if(t===void 0)return;let n=t.getAttribute("data-hide")==="1"?"0":"1";n==="1"?t.setAttribute("data-hide","1"):t.removeAttribute("data-hide"),(r=c(this,ui))==null||r.setAttribute("data-active",n==="0"?"0":"1"),(o=c(this,ui))==null||o.setAttribute("aria-pressed",n==="1"?"true":"false")},Qc=function(){var n,r,o,i,s;let t=c(this,Ut).length;if((n=c(this,Gd))==null||n.call(this,t),c(this,aa)!==void 0&&(c(this,aa).textContent=String(t),c(this,aa).hidden=t===0),(r=c(this,ia))==null||r.toggleAttribute("disabled",t===0),(o=c(this,Vd))==null||o.call(this,t),(i=c(this,jd))==null||i.call(this,this.annotations()),c(this,sa)!==void 0){c(this,sa).hidden=t===0;let a=c(this,sa).querySelector("[data-reticle-marks-text]");a!==null&&(a.textContent=Qz(t))}(s=c(this,ui))==null||s.toggleAttribute("disabled",t===0)},mD=function(t){if(!(t.key!=="Escape"||!c(this,gr))){if(c(this,Rn)!==void 0){t.preventDefault(),T(this,V,Ur).call(this);return}this.toggle(!1)}},gD=function(t){var a,l;if(!c(this,gr)||jh())return;let n=t.target;if(!(n instanceof Element))return;let r=n.hasAttribute(dD)?pD(t.clientX,t.clientY):n;if(r===void 0||Rt(r)||((a=c(this,ui))==null?void 0:a.contains(r))===!0||((l=c(this,ia))==null?void 0:l.contains(r))===!0||r.closest(ai("pin"))!==null||r.closest(ai("pop"))!==null)return;if(c(this,Rn)!==void 0){t.preventDefault(),t.stopPropagation(),T(this,V,pT).call(this);return}let o=r instanceof HTMLElement?r:r.parentElement;if(o===null)return;c(this,Bd).call(this)?(t.preventDefault(),t.stopPropagation()):t.preventDefault();let i=OZ(o),s=c(this,Ut).find(u=>u.anchor===i&&u.route===vm());if(s!==void 0){T(this,V,cT).call(this,s);return}T(this,V,_D).call(this,o,t.clientX,t.clientY)},ED=function(t){c(this,mr)!==void 0&&Re(c(this,mr)),g(this,mr,ue(()=>{g(this,mr,void 0),T(this,V,bD).call(this,t)},NZ))},bD=function(t){if(c(this,Yn)===void 0)return;let n=t.target,r=n instanceof Element&&n.hasAttribute(dD)?pD(t.clientX,t.clientY):n;if(!c(this,gr)||c(this,Rn)!==void 0||!(r instanceof Element)||Rt(r)||r.closest(ai("pin"))!==null){c(this,Yn).setAttribute("data-on","0");return}let i=r.getBoundingClientRect();if(i.width===0&&i.height===0){c(this,Yn).setAttribute("data-on","0");return}c(this,Yn).style.left=`${String(i.left)}px`,c(this,Yn).style.top=`${String(i.top)}px`,c(this,Yn).style.width=`${String(i.width)}px`,c(this,Yn).style.height=`${String(i.height)}px`,c(this,Yn).setAttribute("data-on","1"),c(this,nl)!==void 0&&(c(this,nl).textContent=CZ(r))},Nm=function(){var t;c(this,mr)!==void 0&&(Re(c(this,mr)),g(this,mr,void 0)),(t=c(this,Yn))==null||t.setAttribute("data-on","0")},cT=function(t){T(this,V,Ur).call(this),g(this,rs,t),g(this,oa,t.anchor),g(this,li,t.target),T(this,V,Nm).call(this);let n=T(this,V,lT).call(this,t);T(this,V,uT).call(this,t.label,n.x,n.y,t.note),T(this,V,hT).call(this,n.x,n.y),T(this,V,Hd).call(this)},lT=function(t){let n=t.target;if(n!==void 0&&n.isConnected){let r=n.getBoundingClientRect();if(r.width>0||r.height>0)return{x:r.left+r.width/2,y:r.top+r.height/2}}return{x:t.clientX,y:t.isFixed?t.clientY:t.yDoc-window.scrollY}},_D=function(t,n,r){let o=Ud(t),i=o.anchor;if(c(this,oa)===i&&c(this,Rn)!==void 0){T(this,V,pT).call(this);return}T(this,V,Ur).call(this),T(this,V,Nm).call(this),g(this,rs,void 0),g(this,oa,i),g(this,li,t);let s=o.source!==void 0?`${o.label} \xB7 ${o.source.file}:${String(o.source.line)}`:o.label;T(this,V,uT).call(this,s,n,r,""),T(this,V,hT).call(this,n,r),T(this,V,Hd).call(this),T(this,V,SD).call(this,o,n,r)},uT=function(t,n,r,o){var d,f;let i=document.createElement("div");i.setAttribute(_o,"pop"),i.setAttribute("role","dialog"),i.setAttribute("aria-label",sT),i.innerHTML=`<div class="reticle-mark-where"></div>
125
- <textarea rows="2" placeholder="${sT}"></textarea>
124
+ `,TD=`<div ${Rm}="hi"><span ${Rm}="hilabel"></span></div><div ${Rm}="sel" hidden></div>`});function wD(e){return e.source===void 0?void 0:`${e.source.file}:${String(e.source.line)}`}function Im(){return typeof location=="undefined"?"":location.pathname+location.search}function p9(e){return Gd(e).anchor}function f9(e){if(e===void 0||typeof getComputedStyle=="undefined")return!1;let t=getComputedStyle(e).position;return t==="fixed"||t==="sticky"}function ND(e,t){let n=document.elementsFromPoint.bind(document);if(n!==void 0){for(let r of n(e,t))if(!dr(r))return r}}function RD(e,t){let n=window.innerWidth,r=window.innerHeight,o=Math.min(Math.max(e,Om+AD/2),n-Om-AD/2),i=t+12;return i+yD>r-Om&&(i=Math.max(Om,t-yD-12)),{left:o,top:i}}function h9(e){var i;let t=Ne(e);if(t!==null&&t.length>0)return t;let n=e.tagName.toLowerCase(),r=e.getAttribute("aria-label");if(r!==null&&r.length>0)return`${n} "${r}"`;let o=((i=e.textContent)!=null?i:"").trim().replace(/\s+/g," ").slice(0,40);return o.length>0?`${n} "${o}"`:n}function UD(e){let t=new pa(e);return t.mount(),t}var u9,d9,AD,yD,Om,To,bT,ui,rl,ol,jd,Kd,Zd,Wn,Yn,il,ra,On,oa,Er,di,br,Ht,os,ia,pi,fi,sa,aa,Wd,Yd,ca,sl,al,la,j,OD,nl,ID,CD,LD,$D,Cm,_T,ST,kD,TT,ua,da,zD,xT,AT,DD,yT,wT,PD,Vd,vT,MD,Br,pa,vD,NT=y(()=>{"use strict";It();zc();M();ot();mT();gT();dt();xD();u9=130,d9=250,AD=280,yD=170,Om=8,To="data-reticle-mark",bT="data-reticle-mark-active",ui=e=>`[${To}="${e}"]`,pa=class{constructor(t){x(this,j);x(this,rl);x(this,ol);x(this,jd);x(this,Kd);x(this,Zd);x(this,Wn);x(this,Yn);x(this,il);x(this,ra);x(this,On);x(this,oa);x(this,Er);x(this,di);x(this,br,!1);x(this,Ht,[]);x(this,os);x(this,ia);x(this,pi);x(this,fi);x(this,sa);x(this,aa);x(this,Wd);x(this,Yd);x(this,ca);x(this,sl);x(this,al);x(this,la);x(this,ua);x(this,da,{x:0,y:0});var n;g(this,rl,t.emit),g(this,ol,t.now),g(this,jd,t.onMark),g(this,Kd,(n=t.shouldBlock)!=null?n:(()=>!0)),g(this,Zd,t.onCountChange)}get active(){return c(this,br)}get markCount(){return c(this,Ht).length}annotations(){return c(this,Ht).map(({id:t,createdAt:n,note:r,label:o,anchor:i,route:s,source:a})=>({id:t,createdAt:n,note:r,label:o,anchor:i,route:s,...a===void 0?{}:{source:a}}))}mount(){var o,i,s;if(c(this,Wn)!==void 0||typeof document=="undefined")return;if(document.head===null||document.body===null){document.addEventListener("DOMContentLoaded",()=>this.mount(),{once:!0});return}let t=document.createElement("style");t.setAttribute(To,"style"),t.textContent=SD,document.head.appendChild(t);let n=document.createElement("div");n.setAttribute(To,"root"),n.innerHTML=TD,document.body.appendChild(n),g(this,Wn,n),g(this,Yn,(o=n.querySelector(ui("hi")))!=null?o:void 0),g(this,il,(i=n.querySelector(ui("hilabel")))!=null?i:void 0),g(this,ra,(s=n.querySelector(ui("sel")))!=null?s:void 0);let r=new AbortController;g(this,al,r),document.addEventListener("click",a=>T(this,j,CD).call(this,a),{capture:!0,signal:r.signal}),document.addEventListener("mousemove",a=>T(this,j,LD).call(this,a),{passive:!0,capture:!0,signal:r.signal}),document.addEventListener("keydown",a=>T(this,j,ID).call(this,a),{signal:r.signal}),window.addEventListener("scroll",()=>T(this,j,vT).call(this),{capture:!0,signal:r.signal}),window.addEventListener("resize",()=>T(this,j,vT).call(this),{signal:r.signal}),g(this,la,new MutationObserver(()=>this.syncAnchors())),c(this,la).observe(document.documentElement,{childList:!0,subtree:!0}),c(this,sl)!==void 0&&this.setAccent(c(this,sl))}setAccent(t){var n;g(this,sl,t),(n=c(this,Wn))==null||n.style.setProperty("--reticle-mark-accent",t)}attachChrome(t){var n,r;g(this,fi,t.markersBtn),g(this,sa,t.clearBtn),g(this,aa,t.copyRow),g(this,Wd,t.onCount),g(this,Yd,t.onMarksChange),g(this,ca,t.countEl),(n=c(this,fi))==null||n.addEventListener("click",o=>{o.stopPropagation(),T(this,j,OD).call(this)}),(r=c(this,sa))==null||r.addEventListener("click",o=>{o.stopPropagation(),this.clearAll()}),T(this,j,nl).call(this)}destroy(){var t,n,r;(t=c(this,al))==null||t.abort(),g(this,al,void 0),(n=c(this,la))==null||n.disconnect(),g(this,la,void 0),c(this,Er)!==void 0&&Oe(c(this,Er)),c(this,di)!==void 0&&Oe(c(this,di)),T(this,j,Br).call(this),document.documentElement.removeAttribute(bT),(r=c(this,Wn))==null||r.remove(),document.querySelectorAll(`style[${To}="style"]`).forEach(o=>o.remove()),g(this,Wn,void 0),g(this,br,!1),g(this,Ht,[])}toggle(t){g(this,br,t!=null?t:!c(this,br)),c(this,br)?document.documentElement.setAttribute(bT,"1"):(document.documentElement.removeAttribute(bT),T(this,j,Cm).call(this),T(this,j,Br).call(this)),T(this,j,nl).call(this)}agentPrompt(t){return Nm(c(this,Ht),t)}clearAll(){T(this,j,Br).call(this);for(let t of c(this,Ht))t.pin.remove();g(this,Ht,[]),T(this,j,nl).call(this)}syncAnchors(){let t=Im();for(let n of c(this,Ht))n.target!==void 0&&document.contains(n.target)?n.pin.removeAttribute("data-stale"):(n.target=void 0,n.pin.setAttribute("data-stale","1")),n.pin.hidden=n.route!==t;T(this,j,Vd).call(this)}};rl=new WeakMap,ol=new WeakMap,jd=new WeakMap,Kd=new WeakMap,Zd=new WeakMap,Wn=new WeakMap,Yn=new WeakMap,il=new WeakMap,ra=new WeakMap,On=new WeakMap,oa=new WeakMap,Er=new WeakMap,di=new WeakMap,br=new WeakMap,Ht=new WeakMap,os=new WeakMap,ia=new WeakMap,pi=new WeakMap,fi=new WeakMap,sa=new WeakMap,aa=new WeakMap,Wd=new WeakMap,Yd=new WeakMap,ca=new WeakMap,sl=new WeakMap,al=new WeakMap,la=new WeakMap,j=new WeakSet,OD=function(){var r,o;let t=c(this,Wn);if(t===void 0)return;let n=t.getAttribute("data-hide")==="1"?"0":"1";n==="1"?t.setAttribute("data-hide","1"):t.removeAttribute("data-hide"),(r=c(this,fi))==null||r.setAttribute("data-active",n==="0"?"0":"1"),(o=c(this,fi))==null||o.setAttribute("aria-pressed",n==="1"?"true":"false")},nl=function(){var n,r,o,i,s;let t=c(this,Ht).length;if((n=c(this,Zd))==null||n.call(this,t),c(this,ca)!==void 0&&(c(this,ca).textContent=String(t),c(this,ca).hidden=t===0),(r=c(this,sa))==null||r.toggleAttribute("disabled",t===0),(o=c(this,Wd))==null||o.call(this,t),(i=c(this,Yd))==null||i.call(this,this.annotations()),c(this,aa)!==void 0){c(this,aa).hidden=t===0;let a=c(this,aa).querySelector("[data-reticle-marks-text]");a!==null&&(a.textContent=hD(t))}(s=c(this,fi))==null||s.toggleAttribute("disabled",t===0)},ID=function(t){if(!(t.key!=="Escape"||!c(this,br))){if(c(this,On)!==void 0){t.preventDefault(),T(this,j,Br).call(this);return}this.toggle(!1)}},CD=function(t){var a,l;if(!c(this,br)||Yh())return;let n=t.target;if(!(n instanceof Element))return;let r=n.hasAttribute(vD)?ND(t.clientX,t.clientY):n;if(r===void 0||Rt(r)||((a=c(this,fi))==null?void 0:a.contains(r))===!0||((l=c(this,sa))==null?void 0:l.contains(r))===!0||r.closest(ui("pin"))!==null||r.closest(ui("pop"))!==null)return;if(c(this,On)!==void 0){t.preventDefault(),t.stopPropagation(),T(this,j,AT).call(this);return}let o=r instanceof HTMLElement?r:r.parentElement;if(o===null)return;c(this,Kd).call(this)?(t.preventDefault(),t.stopPropagation()):t.preventDefault();let i=p9(o),s=c(this,Ht).find(u=>u.anchor===i&&u.route===Im());if(s!==void 0){T(this,j,_T).call(this,s);return}T(this,j,kD).call(this,o,t.clientX,t.clientY)},LD=function(t){c(this,Er)!==void 0&&Oe(c(this,Er)),g(this,Er,de(()=>{g(this,Er,void 0),T(this,j,$D).call(this,t)},u9))},$D=function(t){if(c(this,Yn)===void 0)return;let n=t.target,r=n instanceof Element&&n.hasAttribute(vD)?ND(t.clientX,t.clientY):n;if(!c(this,br)||c(this,On)!==void 0||!(r instanceof Element)||Rt(r)||r.closest(ui("pin"))!==null){c(this,Yn).setAttribute("data-on","0");return}let i=r.getBoundingClientRect();if(i.width===0&&i.height===0){c(this,Yn).setAttribute("data-on","0");return}c(this,Yn).style.left=`${String(i.left)}px`,c(this,Yn).style.top=`${String(i.top)}px`,c(this,Yn).style.width=`${String(i.width)}px`,c(this,Yn).style.height=`${String(i.height)}px`,c(this,Yn).setAttribute("data-on","1"),c(this,il)!==void 0&&(c(this,il).textContent=h9(r))},Cm=function(){var t;c(this,Er)!==void 0&&(Oe(c(this,Er)),g(this,Er,void 0)),(t=c(this,Yn))==null||t.setAttribute("data-on","0")},_T=function(t){T(this,j,Br).call(this),g(this,os,t),g(this,ia,t.anchor),g(this,pi,t.target),T(this,j,Cm).call(this);let n=T(this,j,ST).call(this,t);T(this,j,TT).call(this,t.label,n.x,n.y,t.note),T(this,j,wT).call(this,n.x,n.y),T(this,j,Vd).call(this)},ST=function(t){let n=t.target;if(n!==void 0&&n.isConnected){let r=n.getBoundingClientRect();if(r.width>0||r.height>0)return{x:r.left+r.width/2,y:r.top+r.height/2}}return{x:t.clientX,y:t.isFixed?t.clientY:t.yDoc-window.scrollY}},kD=function(t,n,r){let o=Gd(t),i=o.anchor;if(c(this,ia)===i&&c(this,On)!==void 0){T(this,j,AT).call(this);return}T(this,j,Br).call(this),T(this,j,Cm).call(this),g(this,os,void 0),g(this,ia,i),g(this,pi,t);let s=o.source!==void 0?`${o.label} \xB7 ${o.source.file}:${String(o.source.line)}`:o.label;T(this,j,TT).call(this,s,n,r,""),T(this,j,wT).call(this,n,r),T(this,j,Vd).call(this),T(this,j,zD).call(this,o,n,r)},TT=function(t,n,r,o){var d,f;let i=document.createElement("div");i.setAttribute(To,"pop"),i.setAttribute("role","dialog"),i.setAttribute("aria-label",ET),i.innerHTML=`<div class="reticle-mark-where"></div>
125
+ <textarea rows="2" placeholder="${ET}"></textarea>
126
126
  <div class="reticle-mark-row">
127
- <button type="button" data-cancel data-reticle-mark-cancel>${rD}</button>
128
- <button type="button" data-send data-reticle-mark-send disabled>${nD}</button>
129
- </div>`;let s=i.querySelector(".reticle-mark-where");s!==null&&(s.textContent=t);let a=fD(n,r);i.style.left=`${String(a.left)}px`,i.style.top=`${String(a.top)}px`,(d=c(this,Wn))==null||d.appendChild(i),g(this,Rn,i),requestAnimationFrame(()=>i.setAttribute("data-in","1"));let l=i.querySelector("textarea"),u=i.querySelector("button[data-send]");l!==null&&(l.value=o,u!==null&&(u.disabled=l.value.trim().length===0),l.addEventListener("input",()=>{u!==null&&(u.disabled=l.value.trim().length===0)}),l.addEventListener("keydown",m=>{m.stopPropagation(),!m.isComposing&&(m.key==="Escape"?(m.preventDefault(),T(this,V,Ur).call(this)):m.key==="Enter"&&!m.shiftKey&&(m.preventDefault(),T(this,V,dT).call(this)))}),ue(()=>l.focus(),50)),(f=i.querySelector("button[data-cancel]"))==null||f.addEventListener("click",()=>T(this,V,Ur).call(this)),u==null||u.addEventListener("click",()=>T(this,V,dT).call(this)),g(this,la,void 0),g(this,ua,{x:n,y:r})},la=new WeakMap,ua=new WeakMap,SD=function(t,n,r){g(this,la,t),g(this,ua,{x:n,y:r})},dT=function(){var o,i,s;let t=(s=(i=(o=c(this,Rn))==null?void 0:o.querySelector("textarea"))==null?void 0:i.value.trim())!=null?s:"";if(t.length===0)return;let n=c(this,rs);if(n!==void 0){n.note=t;let a=n.pin.querySelector(ai("tipn"));a!==null&&(a.textContent=t),c(this,el).call(this,w.HUMAN_MARK,{note:t,anchor:n.anchor,label:n.label,route:n.route}),T(this,V,fT).call(this,t,n.anchor,n.label,c(this,Ut).indexOf(n)+1,n.source),T(this,V,Qc).call(this),T(this,V,Ur).call(this);return}let r=c(this,la);r!==void 0&&(T(this,V,TD).call(this,t,r,c(this,ua).x,c(this,ua).y),T(this,V,Ur).call(this))},pT=function(){let t=c(this,Rn);t!==void 0&&(t.classList.remove("reticle-mark-shake"),t.offsetWidth,t.classList.add("reticle-mark-shake"),c(this,ci)!==void 0&&Re(c(this,ci)),g(this,ci,ue(()=>{t.classList.remove("reticle-mark-shake"),g(this,ci,void 0)},RZ)))},TD=function(t,n,r,o){let i={note:t,anchor:n.anchor,strategy:n.strategy,label:n.label,route:vm()};n.source!==void 0&&(i.source=n.source),c(this,el).call(this,w.HUMAN_MARK,i),c(this,tl).call(this),T(this,V,xD).call(this,n,t,r,o),T(this,V,fT).call(this,t,n.anchor,n.label,c(this,Ut).length,uD(n))},fT=function(t,n,r,o,i){var a;let s={note:t,anchor:n,label:r,index:o};i!==void 0&&(s.source=i),(a=c(this,Fd))==null||a.call(this,s)},hT=function(t,n){var o,i;(o=c(this,ra))==null||o.remove();let r=document.createElement("div");r.setAttribute(_o,"pending"),r.textContent=oD,r.style.left=`${String(t)}px`,r.style.top=`${String(n)}px`,(i=c(this,Wn))==null||i.appendChild(r),g(this,ra,r)},xD=function(t,n,r,o){if(c(this,Wn)===void 0)return;let i=document.createElement("button");i.type="button",i.setAttribute(_o,"pin"),i.setAttribute("aria-label",t.label);let s=c(this,Ut).length+1;i.innerHTML=`<span>${String(s)}</span><span ${_o}="tip"><span ${_o}="tipq"></span><span ${_o}="tipn"></span></span>`;let a=i.querySelector(ai("tipq")),l=i.querySelector(ai("tipn"));a!==null&&(a.textContent=t.label),l!==null&&(l.textContent=n);let u=IZ(c(this,li)),d=u?o:o+window.scrollY;i.style.left=`${String(r/window.innerWidth*100)}%`,i.style.top=`${String(u?o:d-window.scrollY)}px`,c(this,Wn).appendChild(i);let f=c(this,tl).call(this),m={id:`${t.anchor}:${String(f)}:${String(s)}`,createdAt:f,note:n,label:t.label,anchor:t.anchor,route:vm(),xPct:r/window.innerWidth*100,yDoc:d,clientX:r,clientY:o,isFixed:u,pin:i,target:c(this,li),source:uD(t)};i.addEventListener("click",h=>{h.preventDefault(),h.stopPropagation(),c(this,gr)&&T(this,V,cT).call(this,m)}),c(this,Ut).push(m),T(this,V,Qc).call(this)},Hd=function(){let t=c(this,na);if(t===void 0)return;let n=c(this,li);if(n===void 0||!document.contains(n)||c(this,Rn)===void 0){t.hidden=!0;return}let r=n.getBoundingClientRect();t.hidden=!1,t.style.left=`${String(r.left)}px`,t.style.top=`${String(r.top)}px`,t.style.width=`${String(r.width)}px`,t.style.height=`${String(r.height)}px`},mT=function(){for(let t of c(this,Ut)){if(t.isFixed){t.pin.style.top=`${String(t.clientY)}px`;continue}t.pin.style.top=`${String(t.yDoc-window.scrollY)}px`}T(this,V,AD).call(this),T(this,V,Hd).call(this)},AD=function(){let t=c(this,Rn),n=c(this,rs);if(t===void 0||n===void 0)return;let r=T(this,V,lT).call(this,n),o=fD(r.x,r.y);t.style.left=`${String(o.left)}px`,t.style.top=`${String(o.top)}px`},Ur=function(){var t,n;(t=c(this,Rn))==null||t.remove(),g(this,Rn,void 0),(n=c(this,ra))==null||n.remove(),g(this,ra,void 0),g(this,oa,void 0),g(this,li,void 0),g(this,la,void 0),g(this,rs,void 0),c(this,na)!==void 0&&(c(this,na).hidden=!0)};dD="data-reticle-blocker"});var LZ,Rm,$Z,RD,OD=y(()=>{"use strict";LZ={view:'<g><path d="M15 12a3 3 0 1 1-6 0a3 3 0 0 1 6 0"/><path d="M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7c-1.274 4.057-5.064 7-9.542 7s-8.268-2.943-9.542-7"/></g>',pointer:'<path d="M15.042 21.672L13.684 16.6m0 0l-2.51 2.225l.569-9.47l5.227 7.917l-3.286-.672ZM12 2.25V4.5m5.834.166l-1.591 1.591M20.25 10.5H18M7.757 14.743l-1.59 1.59M6 10.5H3.75m4.007-4.243l-1.59-1.59"/>',send:'<path d="M6 12 3.269 3.126A59.768 59.768 0 0 1 21.485 12 59.77 59.77 0 0 1 3.27 20.876L5.999 12Zm0 0h7.5"/>',chart:'<path d="M9 19v-6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2a2 2 0 0 0 2-2m0 0V9a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v10m-6 0a2 2 0 0 0 2 2h2a2 2 0 0 0 2-2m0 0V5a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-2a2 2 0 0 1-2-2"/>',"caret-down":'<path d="m19 9l-7 7l-7-7"/>',check:'<path d="m5 13l4 4L19 7"/>',remove:'<path d="m4.5 19.5l15-15m-15 0l15 15"/>',pause:'<path d="M8 5v14M16 5v14"/>',play:'<path d="M8 5.75v12.5L18 12 8 5.75Z"/>',stop:'<rect x="6.5" y="6.5" width="11" height="11" rx="2"/>',copy:'<path d="M8 7v8a2 2 0 0 0 2 2h6M8 7V5a2 2 0 0 1 2-2h4.586a1 1 0 0 1 .707.293l4.414 4.414a1 1 0 0 1 .293.707V15a2 2 0 0 1-2 2h-2M8 7H6a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2v-2"/>',download:'<path d="M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5M16.5 12L12 16.5m0 0L7.5 12m4.5 4.5V3"/>',message:'<path d="M8.625 9.75a.375.375 0 1 1-.75 0a.375.375 0 0 1 .75 0Zm0 0H8.25m4.125 0a.375.375 0 1 1-.75 0a.375.375 0 0 1 .75 0Zm0 0H12m4.125 0a.375.375 0 1 1-.75 0a.375.375 0 0 1 .75 0Zm0 0h-.375m-13.5 3.01c0 1.6 1.123 2.994 2.707 3.227c1.087.16 2.185.283 3.293.369V21l4.184-4.183a1.14 1.14 0 0 1 .778-.332a48.294 48.294 0 0 0 5.83-.498c1.585-.233 2.708-1.626 2.708-3.228V6.741c0-1.602-1.123-2.995-2.707-3.228A48.394 48.394 0 0 0 12 3c-2.392 0-4.744.175-7.043.513C3.373 3.746 2.25 5.14 2.25 6.741v6.018Z"/>',gear:'<g><path d="M9.594 3.94c.09-.542.56-.94 1.11-.94h2.593c.55 0 1.02.398 1.11.94l.213 1.281c.063.374.313.686.645.87c.074.04.147.083.22.127c.324.196.72.257 1.075.124l1.217-.456a1.125 1.125 0 0 1 1.37.49l1.296 2.247a1.125 1.125 0 0 1-.26 1.431l-1.003.827c-.293.24-.438.613-.431.992a6.759 6.759 0 0 1 0 .255c-.007.378.138.75.43.99l1.005.828c.424.35.534.954.26 1.43l-1.298 2.247a1.125 1.125 0 0 1-1.369.491l-1.217-.456c-.355-.133-.75-.072-1.076.124a6.57 6.57 0 0 1-.22.128c-.331.183-.581.495-.644.869l-.213 1.28c-.09.543-.56.941-1.11.941h-2.594c-.55 0-1.02-.398-1.11-.94l-.213-1.281c-.062-.374-.312-.686-.644-.87a6.52 6.52 0 0 1-.22-.127c-.325-.196-.72-.257-1.076-.124l-1.217.456a1.125 1.125 0 0 1-1.369-.49l-1.297-2.247a1.125 1.125 0 0 1 .26-1.431l1.004-.827c.292-.24.437-.613.43-.992a6.932 6.932 0 0 1 0-.255c.007-.378-.138-.75-.43-.99l-1.004-.828a1.125 1.125 0 0 1-.26-1.43l1.297-2.247a1.125 1.125 0 0 1 1.37-.491l1.216.456c.356.133.751.072 1.076-.124c.072-.044.146-.087.22-.128c.332-.183.582-.495.644-.869l.214-1.281Z"/><path d="M15 12a3 3 0 1 1-6 0a3 3 0 0 1 6 0Z"/></g>',layout:'<path d="M3.75 6A2.25 2.25 0 0 1 6 3.75h2.25A2.25 2.25 0 0 1 10.5 6v2.25a2.25 2.25 0 0 1-2.25 2.25H6a2.25 2.25 0 0 1-2.25-2.25V6Zm0 9.75A2.25 2.25 0 0 1 6 13.5h2.25a2.25 2.25 0 0 1 2.25 2.25V18a2.25 2.25 0 0 1-2.25 2.25H6A2.25 2.25 0 0 1 3.75 18v-2.25ZM13.5 6a2.25 2.25 0 0 1 2.25-2.25H18A2.25 2.25 0 0 1 20.25 6v2.25A2.25 2.25 0 0 1 18 10.5h-2.25a2.25 2.25 0 0 1-2.25-2.25V6Zm0 9.75a2.25 2.25 0 0 1 2.25-2.25H18a2.25 2.25 0 0 1 2.25 2.25V18A2.25 2.25 0 0 1 18 20.25h-2.25A2.25 2.25 0 0 1 13.5 18v-2.25Z"/>',notes:'<path d="M9 12h3.75M9 15h3.75M9 18h3.75m3 .75H18a2.25 2.25 0 0 0 2.25-2.25V6.108c0-1.135-.845-2.098-1.976-2.192a48.424 48.424 0 0 0-1.123-.08m-5.801 0c-.065.21-.1.433-.1.664c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75a2.25 2.25 0 0 0-.1-.664m-5.8 0A2.251 2.251 0 0 1 13.5 2.25H15a2.25 2.25 0 0 1 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m0 0H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V9.375c0-.621-.504-1.125-1.125-1.125H8.25ZM6.75 12h.008v.008H6.75V12Zm0 3h.008v.008H6.75V15Zm0 3h.008v.008H6.75V18Z"/>',trash:'<path d="m19 7l-.867 12.142A2 2 0 0 1 16.138 21H7.862a2 2 0 0 1-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v3M4 7h16"/>',help:'<path d="M8.228 9c.549-1.165 2.03-2 3.772-2c2.21 0 4 1.343 4 3c0 1.4-1.278 2.575-3.006 2.907c-.542.104-.994.54-.994 1.093m0 3h.01M21 12a9 9 0 1 1-18 0a9 9 0 0 1 18 0"/>',"caret-right":'<path d="m9 5l7 7l-7 7"/>',annotate:'<path d="m16.862 4.487l1.687-1.688a1.875 1.875 0 1 1 2.652 2.652L10.582 16.07a4.5 4.5 0 0 1-1.897 1.13L6 18l.8-2.685a4.5 4.5 0 0 1 1.13-1.897l8.932-8.931Zm0 0L19.5 7.125M18 14v4.75A2.25 2.25 0 0 1 15.75 21H5.25A2.25 2.25 0 0 1 3 18.75V8.25A2.25 2.25 0 0 1 5.25 6H10"/>',sync:'<path d="M4.5 12c0-1.232.046-2.453.138-3.662a4.006 4.006 0 0 1 3.7-3.7a48.678 48.678 0 0 1 7.324 0a4.006 4.006 0 0 1 3.7 3.7c.017.22.032.441.046.662M4.5 12l-3-3m3 3l3-3m12 3c0 1.232-.046 2.453-.138 3.662a4.006 4.006 0 0 1-3.7 3.7a48.657 48.657 0 0 1-7.324 0a4.006 4.006 0 0 1-3.7-3.7c-.017-.22-.032-.441-.046-.662M19.5 12l-3 3m3-3l3 3"/>'},Rm=LZ,$Z={chart:'<path fill="currentColor" d="M2 11a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v5a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1zm6-4a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v9a1 1 0 0 1-1 1H9a1 1 0 0 1-1-1zm6-3a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v12a1 1 0 0 1-1 1h-2a1 1 0 0 1-1-1z"/>',annotate:'<path fill="currentColor" fill-rule="evenodd" d="m5.433 13.916l1.262-3.154a4 4 0 0 1 .885-1.343L14.5 2.5a2.121 2.121 0 1 1 3 3l-6.92 6.919c-.383.383-.84.684-1.343.885l-3.154 1.262a.5.5 0 0 1-.65-.65ZM2.5 5.75c0-.69.56-1.25 1.25-1.25H10A.75.75 0 0 0 10 3H3.75A2.75 2.75 0 0 0 1 5.75v10.5A2.75 2.75 0 0 0 3.75 19h10.5A2.75 2.75 0 0 0 17 16.25V10a.75.75 0 0 0-1.5 0v6.25c0 .69-.56 1.25-1.25 1.25H3.75c-.69 0-1.25-.56-1.25-1.25V5.75Z" clip-rule="evenodd"/>',message:'<path fill="currentColor" fill-rule="evenodd" d="M10 2c-2.236 0-4.43.18-6.57.524C1.993 2.755 1 4.014 1 5.426v5.148c0 1.413.993 2.67 2.43 2.902c.848.137 1.705.248 2.57.331v3.443a.75.75 0 0 0 1.28.53l3.58-3.579a.78.78 0 0 1 .527-.224a41.202 41.202 0 0 0 5.183-.5c1.437-.232 2.43-1.49 2.43-2.903V5.426c0-1.413-.993-2.67-2.43-2.902A41.289 41.289 0 0 0 10 2Zm0 7a1 1 0 1 0 0-2a1 1 0 0 0 0 2ZM8 8a1 1 0 1 1-2 0a1 1 0 0 1 2 0Zm5 1a1 1 0 1 0 0-2a1 1 0 0 0 0 2Z" clip-rule="evenodd"/>',view:'<g fill="currentColor"><path d="M10 12a2 2 0 1 0 0-4a2 2 0 0 0 0 4"/><path fill-rule="evenodd" d="M.458 10C1.732 5.943 5.522 3 10 3s8.268 2.943 9.542 7c-1.274 4.057-5.064 7-9.542 7S1.732 14.057.458 10M14 10a4 4 0 1 1-8 0a4 4 0 0 1 8 0" clip-rule="evenodd"/></g>',gear:'<path fill="currentColor" fill-rule="evenodd" d="M7.84 1.804A1 1 0 0 1 8.82 1h2.36a1 1 0 0 1 .98.804l.331 1.652a6.993 6.993 0 0 1 1.929 1.115l1.598-.54a1 1 0 0 1 1.186.447l1.18 2.044a1 1 0 0 1-.205 1.251l-1.267 1.113a7.047 7.047 0 0 1 0 2.228l1.267 1.113a1 1 0 0 1 .206 1.25l-1.18 2.045a1 1 0 0 1-1.187.447l-1.598-.54a6.993 6.993 0 0 1-1.929 1.115l-.33 1.652a1 1 0 0 1-.98.804H8.82a1 1 0 0 1-.98-.804l-.331-1.652a6.993 6.993 0 0 1-1.929-1.115l-1.598.54a1 1 0 0 1-1.186-.447l-1.18-2.044a1 1 0 0 1 .205-1.251l1.267-1.114a7.05 7.05 0 0 1 0-2.227L1.821 7.773a1 1 0 0 1-.206-1.25l1.18-2.045a1 1 0 0 1 1.187-.447l1.598.54a6.993 6.993 0 0 1 1.93-1.115l.33-1.652ZM10 13a3 3 0 1 0 0-6a3 3 0 0 0 0 6Z" clip-rule="evenodd"/>'},RD=$Z});function kZ(e,t){let n=`${e}:${String(t)}`,r=ID.get(n);if(r!==void 0)return document.importNode(r,!0);let o=Rm[e];if(o===void 0)throw new Error(`missing heroicon body: ${String(e)}`);let s=new DOMParser().parseFromString(`<svg xmlns="${Kd}" viewBox="${Zd}" fill="none">${o}</svg>`,"image/svg+xml").documentElement,a=s instanceof SVGSVGElement?document.importNode(s,!0):document.createElementNS(Kd,"svg");return a.setAttribute("viewBox",Zd),a.setAttribute("width",String(t)),a.setAttribute("height",String(t)),a.setAttribute("fill","none"),s instanceof SVGSVGElement||(a.innerHTML=o),ID.set(n,a),document.importNode(a,!0)}function So(e,t=16){let n=document.createElement("span");return n.className="reticle-hi-icon",n.setAttribute("aria-hidden","true"),n.style.width=`${String(t)}px`,n.style.height=`${String(t)}px`,n.appendChild(kZ(e,t)),n}function ET(e,t,n=16){e.replaceChildren(So(t,n))}function Ie(e,t=16){let n=Rm[e];if(n===void 0)throw new Error(`missing heroicon body: ${String(e)}`);return`<span class="reticle-hi-icon" aria-hidden="true" style="width:${String(t)}px;height:${String(t)}px"><svg xmlns="${Kd}" viewBox="${Zd}" width="${String(t)}" height="${String(t)}" fill="none">${n}</svg></span>`}function Om(e,t=16){let n=Rm[e],r=RD[e];if(n===void 0||r===void 0)throw new Error(`missing heroicon toggle pair: ${String(e)}`);let o=String(t);return`<span class="reticle-hi-toggle" aria-hidden="true" style="width:${o}px;height:${o}px"><span class="reticle-hi-icon reticle-hi-icon--outline" style="width:${o}px;height:${o}px"><svg xmlns="${Kd}" viewBox="${Zd}" width="${o}" height="${o}" fill="none">${n}</svg></span><span class="reticle-hi-icon reticle-hi-icon--solid" style="width:${o}px;height:${o}px"><svg xmlns="${Kd}" viewBox="${Zd}" width="${o}" height="${o}" fill="currentColor">${r}</svg></span></span>`}var se,Ae,Kd,Zd,ID,Hr=y(()=>{"use strict";OD();se={VIEW:"view",POINTER:"pointer",SEND:"send",CHART:"chart",CARET_DOWN:"caret-down",CHECK:"check",REMOVE:"remove",PAUSE:"pause",PLAY:"play",STOP:"stop",COPY:"copy",DOWNLOAD:"download",MESSAGE:"message",NOTES:"notes",GEAR:"gear",LAYOUT:"layout",TRASH:"trash",HELP:"help",CARET_RIGHT:"caret-right",ANNOTATE:"annotate",SYNC:"sync"},Ae={CHIP:11,LOG:11,TALLY:12,CTL:10,SEND:14,MIN:12,HELP:12,NAV:18,TOOLBAR:18,FAB:22},Kd="http://www.w3.org/2000/svg",Zd="0 0 24 24",ID=new Map});function Wd(e){e.scrollTop=e.scrollHeight,e.toggleAttribute(GZ,e.scrollHeight>e.clientHeight+1)}function UD(e){Wd(e),requestAnimationFrame(()=>{Wd(e),requestAnimationFrame(()=>Wd(e))}),ue(()=>Wd(e),BZ)}function HD(e){return[...e.children].filter(t=>t.hasAttribute($m))}function zm(e,t){let n=HD(e);for(let r of n.slice(0,Math.max(0,n.length-t)))r.remove()}function Dm(e){for(let t of HD(e))t.remove()}function TT(e){return e===void 0||!Number.isFinite(e)||e<=0?zZ:Math.floor(e)}function Xd(e){let t=Math.max(0,Math.floor(e/1e3));if(t<60)return`${t}s`;let n=Math.floor(t/60);if(n<60)return t%60===0?`${n}m`:`${n}m ${t%60}s`;let r=Math.floor(n/60);return n%60===0?`${r}h`:`${r}h ${n%60}m`}function FD(e){return Xd(e)}function Pm(e,t,n,r,o,i=hn.AGENT){var _,A,v;let s=t===Ge.READ?VZ(e,n,i):void 0;if(s!==void 0){let N=Number((_=s.getAttribute($D))!=null?_:"1")+1;s.setAttribute($D,String(N));let O=s.querySelector(`.${kD}`);O===null&&(O=document.createElement("span"),O.className=kD,(A=s.querySelector(`.${Cm}`))==null||A.after(O)),O.textContent=`\xD7${String(N)}`;let k=s.querySelector(`[${Yd}]`);k!==null&&(k.textContent=r);let j=s.querySelector(`.${km}`);return j===null?{result:()=>{}}:zD(s,j)}let a=t===Ge.ACT||t===Ge.READ;if(a&&((v=e.getAttribute(Lm))!=null?v:hn.AGENT)!==i){let N=document.createElement("div");N.setAttribute($m,""),N.setAttribute(_T,HZ),N.setAttribute(bT,i);let O=document.createElement("span");O.className=Cm,O.textContent=UZ[i],N.appendChild(O),e.appendChild(N)}a&&e.setAttribute(Lm,i);let l=document.createElement("div");l.setAttribute($m,""),l.setAttribute(_T,t),l.setAttribute(bT,i),t===Ge.ACT&&l.setAttribute(PD,"running");let u=document.createElement("span");u.setAttribute(Yd,""),u.textContent=r;let d=[];t!==Ge.HUMAN&&d.push(u);let f=DZ[t],m=PZ[t];if(f.length>0||m!==void 0){let N=document.createElement("span");if(N.className=FZ,N.setAttribute("data-mode",MZ[t]),m!==void 0&&N.appendChild(So(m,Ae.LOG)),f.length>0){let O=document.createElement("span");O.className="reticle-chip-label",O.textContent=f,N.appendChild(O)}d.push(N)}let h=document.createElement("span");h.className=Cm,h.textContent=n;let E=document.createElement("span");return E.className=km,d.push(h),t!==Ge.HUMAN&&d.push(E),l.append(...d),e.appendChild(l),zm(e,o),requestAnimationFrame(()=>{Wd(e)}),zD(l,E)}function VZ(e,t,n){var o;let r=e.lastElementChild;if(!(!(r instanceof HTMLElement)||!r.hasAttribute($m))&&!(r.getAttribute(_T)!==Ge.READ||r.getAttribute(bT)!==n))return((o=r.querySelector(`.${Cm}`))==null?void 0:o.textContent)===t?r:void 0}function zD(e,t){return{result:n=>{if(e.setAttribute(PD,n),n===Kn.PASS){t.textContent=CD.pass,t.className=`${km} ${LD.pass}`;return}t.textContent=` ${CD[n]}`,t.className=`${km} ${LD[n]}`}}}var zZ,DZ,PZ,DD,MZ,CD,UZ,Lm,bT,PD,HZ,LD,ST,$m,Yd,_T,Cm,$D,kD,km,FZ,Im,BZ,MD,GZ,di=y(()=>{"use strict";M();JS();dt();Hr();zZ=50,DZ={read:"READ",act:"ACT",narration:"",human:""},PZ={read:se.VIEW,act:se.POINTER},DD={[ct.IDLE]:"",[ct.READING]:"READING",[ct.ACTING]:"ACTING"},MZ={read:ct.READING,act:ct.ACTING,narration:ct.IDLE,human:ct.IDLE},CD={pass:"\u2713",fail:"Fail"},UZ={agent:"Your agent is driving",harness:"Reticle Harness is driving"},Lm="data-reticle-log-actor",bT="data-actor",PD="data-state",HZ="handover",LD={pass:"reticle-pass",fail:"reticle-fail"},ST="data-reticle-log",$m="data-reticle-log-row",Yd="data-reticle-log-time",_T="data-kind",Cm="reticle-log-text",$D="data-reticle-repeat",kD="reticle-log-repeat",km="reticle-res",FZ="reticle-chip",Im={TITLE:"Reticle checks your app from the inside.",OFFLINE_TITLE:"Not connected yet.",OFFLINE_BODY:"Once Reticle is running, this page connects by itself and the steps show here.",BODY:"Ask your coding agent to verify a change with Reticle: each step shows here, live.\\AOr open Harness below: Reticle clicks through the app as the person you pick and reports what breaks."},BZ=160,MD=`
127
+ <button type="button" data-cancel data-reticle-mark-cancel>${bD}</button>
128
+ <button type="button" data-send data-reticle-mark-send disabled>${ED}</button>
129
+ </div>`;let s=i.querySelector(".reticle-mark-where");s!==null&&(s.textContent=t);let a=RD(n,r);i.style.left=`${String(a.left)}px`,i.style.top=`${String(a.top)}px`,(d=c(this,Wn))==null||d.appendChild(i),g(this,On,i),requestAnimationFrame(()=>i.setAttribute("data-in","1"));let l=i.querySelector("textarea"),u=i.querySelector("button[data-send]");l!==null&&(l.value=o,u!==null&&(u.disabled=l.value.trim().length===0),l.addEventListener("input",()=>{u!==null&&(u.disabled=l.value.trim().length===0)}),l.addEventListener("keydown",m=>{m.stopPropagation(),!m.isComposing&&(m.key==="Escape"?(m.preventDefault(),T(this,j,Br).call(this)):m.key==="Enter"&&!m.shiftKey&&(m.preventDefault(),T(this,j,xT).call(this)))}),de(()=>l.focus(),50)),(f=i.querySelector("button[data-cancel]"))==null||f.addEventListener("click",()=>T(this,j,Br).call(this)),u==null||u.addEventListener("click",()=>T(this,j,xT).call(this)),g(this,ua,void 0),g(this,da,{x:n,y:r})},ua=new WeakMap,da=new WeakMap,zD=function(t,n,r){g(this,ua,t),g(this,da,{x:n,y:r})},xT=function(){var o,i,s;let t=(s=(i=(o=c(this,On))==null?void 0:o.querySelector("textarea"))==null?void 0:i.value.trim())!=null?s:"";if(t.length===0)return;let n=c(this,os);if(n!==void 0){n.note=t;let a=n.pin.querySelector(ui("tipn"));a!==null&&(a.textContent=t),c(this,rl).call(this,v.HUMAN_MARK,{note:t,anchor:n.anchor,label:n.label,route:n.route}),T(this,j,yT).call(this,t,n.anchor,n.label,c(this,Ht).indexOf(n)+1,n.source),T(this,j,nl).call(this),T(this,j,Br).call(this);return}let r=c(this,ua);r!==void 0&&(T(this,j,DD).call(this,t,r,c(this,da).x,c(this,da).y),T(this,j,Br).call(this))},AT=function(){let t=c(this,On);t!==void 0&&(t.classList.remove("reticle-mark-shake"),t.offsetWidth,t.classList.add("reticle-mark-shake"),c(this,di)!==void 0&&Oe(c(this,di)),g(this,di,de(()=>{t.classList.remove("reticle-mark-shake"),g(this,di,void 0)},d9)))},DD=function(t,n,r,o){let i={note:t,anchor:n.anchor,strategy:n.strategy,label:n.label,route:Im()};n.source!==void 0&&(i.source=n.source),c(this,rl).call(this,v.HUMAN_MARK,i),c(this,ol).call(this),T(this,j,PD).call(this,n,t,r,o),T(this,j,yT).call(this,t,n.anchor,n.label,c(this,Ht).length,wD(n))},yT=function(t,n,r,o,i){var a;let s={note:t,anchor:n,label:r,index:o};i!==void 0&&(s.source=i),(a=c(this,jd))==null||a.call(this,s)},wT=function(t,n){var o,i;(o=c(this,oa))==null||o.remove();let r=document.createElement("div");r.setAttribute(To,"pending"),r.textContent=_D,r.style.left=`${String(t)}px`,r.style.top=`${String(n)}px`,(i=c(this,Wn))==null||i.appendChild(r),g(this,oa,r)},PD=function(t,n,r,o){if(c(this,Wn)===void 0)return;let i=document.createElement("button");i.type="button",i.setAttribute(To,"pin"),i.setAttribute("aria-label",t.label);let s=c(this,Ht).length+1;i.innerHTML=`<span>${String(s)}</span><span ${To}="tip"><span ${To}="tipq"></span><span ${To}="tipn"></span></span>`;let a=i.querySelector(ui("tipq")),l=i.querySelector(ui("tipn"));a!==null&&(a.textContent=t.label),l!==null&&(l.textContent=n);let u=f9(c(this,pi)),d=u?o:o+window.scrollY;i.style.left=`${String(r/window.innerWidth*100)}%`,i.style.top=`${String(u?o:d-window.scrollY)}px`,c(this,Wn).appendChild(i);let f=c(this,ol).call(this),m={id:`${t.anchor}:${String(f)}:${String(s)}`,createdAt:f,note:n,label:t.label,anchor:t.anchor,route:Im(),xPct:r/window.innerWidth*100,yDoc:d,clientX:r,clientY:o,isFixed:u,pin:i,target:c(this,pi),source:wD(t)};i.addEventListener("click",h=>{h.preventDefault(),h.stopPropagation(),c(this,br)&&T(this,j,_T).call(this,m)}),c(this,Ht).push(m),T(this,j,nl).call(this)},Vd=function(){let t=c(this,ra);if(t===void 0)return;let n=c(this,pi);if(n===void 0||!document.contains(n)||c(this,On)===void 0){t.hidden=!0;return}let r=n.getBoundingClientRect();t.hidden=!1,t.style.left=`${String(r.left)}px`,t.style.top=`${String(r.top)}px`,t.style.width=`${String(r.width)}px`,t.style.height=`${String(r.height)}px`},vT=function(){for(let t of c(this,Ht)){if(t.isFixed){t.pin.style.top=`${String(t.clientY)}px`;continue}t.pin.style.top=`${String(t.yDoc-window.scrollY)}px`}T(this,j,MD).call(this),T(this,j,Vd).call(this)},MD=function(){let t=c(this,On),n=c(this,os);if(t===void 0||n===void 0)return;let r=T(this,j,ST).call(this,n),o=RD(r.x,r.y);t.style.left=`${String(o.left)}px`,t.style.top=`${String(o.top)}px`},Br=function(){var t,n;(t=c(this,On))==null||t.remove(),g(this,On,void 0),(n=c(this,oa))==null||n.remove(),g(this,oa,void 0),g(this,ia,void 0),g(this,pi,void 0),g(this,ua,void 0),g(this,os,void 0),c(this,ra)!==void 0&&(c(this,ra).hidden=!0)};vD="data-reticle-blocker"});var m9,Lm,g9,GD,VD=y(()=>{"use strict";m9={view:'<g><path d="M15 12a3 3 0 1 1-6 0a3 3 0 0 1 6 0"/><path d="M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7c-1.274 4.057-5.064 7-9.542 7s-8.268-2.943-9.542-7"/></g>',pointer:'<path d="M15.042 21.672L13.684 16.6m0 0l-2.51 2.225l.569-9.47l5.227 7.917l-3.286-.672ZM12 2.25V4.5m5.834.166l-1.591 1.591M20.25 10.5H18M7.757 14.743l-1.59 1.59M6 10.5H3.75m4.007-4.243l-1.59-1.59"/>',send:'<path d="M6 12 3.269 3.126A59.768 59.768 0 0 1 21.485 12 59.77 59.77 0 0 1 3.27 20.876L5.999 12Zm0 0h7.5"/>',chart:'<path d="M9 19v-6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2a2 2 0 0 0 2-2m0 0V9a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v10m-6 0a2 2 0 0 0 2 2h2a2 2 0 0 0 2-2m0 0V5a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-2a2 2 0 0 1-2-2"/>',"caret-down":'<path d="m19 9l-7 7l-7-7"/>',check:'<path d="m5 13l4 4L19 7"/>',remove:'<path d="m4.5 19.5l15-15m-15 0l15 15"/>',pause:'<path d="M8 5v14M16 5v14"/>',play:'<path d="M8 5.75v12.5L18 12 8 5.75Z"/>',stop:'<rect x="6.5" y="6.5" width="11" height="11" rx="2"/>',copy:'<path d="M8 7v8a2 2 0 0 0 2 2h6M8 7V5a2 2 0 0 1 2-2h4.586a1 1 0 0 1 .707.293l4.414 4.414a1 1 0 0 1 .293.707V15a2 2 0 0 1-2 2h-2M8 7H6a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2v-2"/>',download:'<path d="M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5M16.5 12L12 16.5m0 0L7.5 12m4.5 4.5V3"/>',message:'<path d="M8.625 9.75a.375.375 0 1 1-.75 0a.375.375 0 0 1 .75 0Zm0 0H8.25m4.125 0a.375.375 0 1 1-.75 0a.375.375 0 0 1 .75 0Zm0 0H12m4.125 0a.375.375 0 1 1-.75 0a.375.375 0 0 1 .75 0Zm0 0h-.375m-13.5 3.01c0 1.6 1.123 2.994 2.707 3.227c1.087.16 2.185.283 3.293.369V21l4.184-4.183a1.14 1.14 0 0 1 .778-.332a48.294 48.294 0 0 0 5.83-.498c1.585-.233 2.708-1.626 2.708-3.228V6.741c0-1.602-1.123-2.995-2.707-3.228A48.394 48.394 0 0 0 12 3c-2.392 0-4.744.175-7.043.513C3.373 3.746 2.25 5.14 2.25 6.741v6.018Z"/>',gear:'<g><path d="M9.594 3.94c.09-.542.56-.94 1.11-.94h2.593c.55 0 1.02.398 1.11.94l.213 1.281c.063.374.313.686.645.87c.074.04.147.083.22.127c.324.196.72.257 1.075.124l1.217-.456a1.125 1.125 0 0 1 1.37.49l1.296 2.247a1.125 1.125 0 0 1-.26 1.431l-1.003.827c-.293.24-.438.613-.431.992a6.759 6.759 0 0 1 0 .255c-.007.378.138.75.43.99l1.005.828c.424.35.534.954.26 1.43l-1.298 2.247a1.125 1.125 0 0 1-1.369.491l-1.217-.456c-.355-.133-.75-.072-1.076.124a6.57 6.57 0 0 1-.22.128c-.331.183-.581.495-.644.869l-.213 1.28c-.09.543-.56.941-1.11.941h-2.594c-.55 0-1.02-.398-1.11-.94l-.213-1.281c-.062-.374-.312-.686-.644-.87a6.52 6.52 0 0 1-.22-.127c-.325-.196-.72-.257-1.076-.124l-1.217.456a1.125 1.125 0 0 1-1.369-.49l-1.297-2.247a1.125 1.125 0 0 1 .26-1.431l1.004-.827c.292-.24.437-.613.43-.992a6.932 6.932 0 0 1 0-.255c.007-.378-.138-.75-.43-.99l-1.004-.828a1.125 1.125 0 0 1-.26-1.43l1.297-2.247a1.125 1.125 0 0 1 1.37-.491l1.216.456c.356.133.751.072 1.076-.124c.072-.044.146-.087.22-.128c.332-.183.582-.495.644-.869l.214-1.281Z"/><path d="M15 12a3 3 0 1 1-6 0a3 3 0 0 1 6 0Z"/></g>',layout:'<path d="M3.75 6A2.25 2.25 0 0 1 6 3.75h2.25A2.25 2.25 0 0 1 10.5 6v2.25a2.25 2.25 0 0 1-2.25 2.25H6a2.25 2.25 0 0 1-2.25-2.25V6Zm0 9.75A2.25 2.25 0 0 1 6 13.5h2.25a2.25 2.25 0 0 1 2.25 2.25V18a2.25 2.25 0 0 1-2.25 2.25H6A2.25 2.25 0 0 1 3.75 18v-2.25ZM13.5 6a2.25 2.25 0 0 1 2.25-2.25H18A2.25 2.25 0 0 1 20.25 6v2.25A2.25 2.25 0 0 1 18 10.5h-2.25a2.25 2.25 0 0 1-2.25-2.25V6Zm0 9.75a2.25 2.25 0 0 1 2.25-2.25H18a2.25 2.25 0 0 1 2.25 2.25V18A2.25 2.25 0 0 1 18 20.25h-2.25A2.25 2.25 0 0 1 13.5 18v-2.25Z"/>',notes:'<path d="M9 12h3.75M9 15h3.75M9 18h3.75m3 .75H18a2.25 2.25 0 0 0 2.25-2.25V6.108c0-1.135-.845-2.098-1.976-2.192a48.424 48.424 0 0 0-1.123-.08m-5.801 0c-.065.21-.1.433-.1.664c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75a2.25 2.25 0 0 0-.1-.664m-5.8 0A2.251 2.251 0 0 1 13.5 2.25H15a2.25 2.25 0 0 1 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m0 0H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V9.375c0-.621-.504-1.125-1.125-1.125H8.25ZM6.75 12h.008v.008H6.75V12Zm0 3h.008v.008H6.75V15Zm0 3h.008v.008H6.75V18Z"/>',trash:'<path d="m19 7l-.867 12.142A2 2 0 0 1 16.138 21H7.862a2 2 0 0 1-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v3M4 7h16"/>',help:'<path d="M8.228 9c.549-1.165 2.03-2 3.772-2c2.21 0 4 1.343 4 3c0 1.4-1.278 2.575-3.006 2.907c-.542.104-.994.54-.994 1.093m0 3h.01M21 12a9 9 0 1 1-18 0a9 9 0 0 1 18 0"/>',"caret-right":'<path d="m9 5l7 7l-7 7"/>',annotate:'<path d="m16.862 4.487l1.687-1.688a1.875 1.875 0 1 1 2.652 2.652L10.582 16.07a4.5 4.5 0 0 1-1.897 1.13L6 18l.8-2.685a4.5 4.5 0 0 1 1.13-1.897l8.932-8.931Zm0 0L19.5 7.125M18 14v4.75A2.25 2.25 0 0 1 15.75 21H5.25A2.25 2.25 0 0 1 3 18.75V8.25A2.25 2.25 0 0 1 5.25 6H10"/>',sync:'<path d="M4.5 12c0-1.232.046-2.453.138-3.662a4.006 4.006 0 0 1 3.7-3.7a48.678 48.678 0 0 1 7.324 0a4.006 4.006 0 0 1 3.7 3.7c.017.22.032.441.046.662M4.5 12l-3-3m3 3l3-3m12 3c0 1.232-.046 2.453-.138 3.662a4.006 4.006 0 0 1-3.7 3.7a48.657 48.657 0 0 1-7.324 0a4.006 4.006 0 0 1-3.7-3.7c-.017-.22-.032-.441-.046-.662M19.5 12l-3 3m3-3l3 3"/>'},Lm=m9,g9={chart:'<path fill="currentColor" d="M2 11a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v5a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1zm6-4a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v9a1 1 0 0 1-1 1H9a1 1 0 0 1-1-1zm6-3a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v12a1 1 0 0 1-1 1h-2a1 1 0 0 1-1-1z"/>',annotate:'<path fill="currentColor" fill-rule="evenodd" d="m5.433 13.916l1.262-3.154a4 4 0 0 1 .885-1.343L14.5 2.5a2.121 2.121 0 1 1 3 3l-6.92 6.919c-.383.383-.84.684-1.343.885l-3.154 1.262a.5.5 0 0 1-.65-.65ZM2.5 5.75c0-.69.56-1.25 1.25-1.25H10A.75.75 0 0 0 10 3H3.75A2.75 2.75 0 0 0 1 5.75v10.5A2.75 2.75 0 0 0 3.75 19h10.5A2.75 2.75 0 0 0 17 16.25V10a.75.75 0 0 0-1.5 0v6.25c0 .69-.56 1.25-1.25 1.25H3.75c-.69 0-1.25-.56-1.25-1.25V5.75Z" clip-rule="evenodd"/>',message:'<path fill="currentColor" fill-rule="evenodd" d="M10 2c-2.236 0-4.43.18-6.57.524C1.993 2.755 1 4.014 1 5.426v5.148c0 1.413.993 2.67 2.43 2.902c.848.137 1.705.248 2.57.331v3.443a.75.75 0 0 0 1.28.53l3.58-3.579a.78.78 0 0 1 .527-.224a41.202 41.202 0 0 0 5.183-.5c1.437-.232 2.43-1.49 2.43-2.903V5.426c0-1.413-.993-2.67-2.43-2.902A41.289 41.289 0 0 0 10 2Zm0 7a1 1 0 1 0 0-2a1 1 0 0 0 0 2ZM8 8a1 1 0 1 1-2 0a1 1 0 0 1 2 0Zm5 1a1 1 0 1 0 0-2a1 1 0 0 0 0 2Z" clip-rule="evenodd"/>',view:'<g fill="currentColor"><path d="M10 12a2 2 0 1 0 0-4a2 2 0 0 0 0 4"/><path fill-rule="evenodd" d="M.458 10C1.732 5.943 5.522 3 10 3s8.268 2.943 9.542 7c-1.274 4.057-5.064 7-9.542 7S1.732 14.057.458 10M14 10a4 4 0 1 1-8 0a4 4 0 0 1 8 0" clip-rule="evenodd"/></g>',gear:'<path fill="currentColor" fill-rule="evenodd" d="M7.84 1.804A1 1 0 0 1 8.82 1h2.36a1 1 0 0 1 .98.804l.331 1.652a6.993 6.993 0 0 1 1.929 1.115l1.598-.54a1 1 0 0 1 1.186.447l1.18 2.044a1 1 0 0 1-.205 1.251l-1.267 1.113a7.047 7.047 0 0 1 0 2.228l1.267 1.113a1 1 0 0 1 .206 1.25l-1.18 2.045a1 1 0 0 1-1.187.447l-1.598-.54a6.993 6.993 0 0 1-1.929 1.115l-.33 1.652a1 1 0 0 1-.98.804H8.82a1 1 0 0 1-.98-.804l-.331-1.652a6.993 6.993 0 0 1-1.929-1.115l-1.598.54a1 1 0 0 1-1.186-.447l-1.18-2.044a1 1 0 0 1 .205-1.251l1.267-1.114a7.05 7.05 0 0 1 0-2.227L1.821 7.773a1 1 0 0 1-.206-1.25l1.18-2.045a1 1 0 0 1 1.187-.447l1.598.54a6.993 6.993 0 0 1 1.93-1.115l.33-1.652ZM10 13a3 3 0 1 0 0-6a3 3 0 0 0 0 6Z" clip-rule="evenodd"/>'},GD=g9});function E9(e,t){let n=`${e}:${String(t)}`,r=jD.get(n);if(r!==void 0)return document.importNode(r,!0);let o=Lm[e];if(o===void 0)throw new Error(`missing heroicon body: ${String(e)}`);let s=new DOMParser().parseFromString(`<svg xmlns="${Xd}" viewBox="${qd}" fill="none">${o}</svg>`,"image/svg+xml").documentElement,a=s instanceof SVGSVGElement?document.importNode(s,!0):document.createElementNS(Xd,"svg");return a.setAttribute("viewBox",qd),a.setAttribute("width",String(t)),a.setAttribute("height",String(t)),a.setAttribute("fill","none"),s instanceof SVGSVGElement||(a.innerHTML=o),jD.set(n,a),document.importNode(a,!0)}function xo(e,t=16){let n=document.createElement("span");return n.className="reticle-hi-icon",n.setAttribute("aria-hidden","true"),n.style.width=`${String(t)}px`,n.style.height=`${String(t)}px`,n.appendChild(E9(e,t)),n}function RT(e,t,n=16){e.replaceChildren(xo(t,n))}function Ce(e,t=16){let n=Lm[e];if(n===void 0)throw new Error(`missing heroicon body: ${String(e)}`);return`<span class="reticle-hi-icon" aria-hidden="true" style="width:${String(t)}px;height:${String(t)}px"><svg xmlns="${Xd}" viewBox="${qd}" width="${String(t)}" height="${String(t)}" fill="none">${n}</svg></span>`}function $m(e,t=16){let n=Lm[e],r=GD[e];if(n===void 0||r===void 0)throw new Error(`missing heroicon toggle pair: ${String(e)}`);let o=String(t);return`<span class="reticle-hi-toggle" aria-hidden="true" style="width:${o}px;height:${o}px"><span class="reticle-hi-icon reticle-hi-icon--outline" style="width:${o}px;height:${o}px"><svg xmlns="${Xd}" viewBox="${qd}" width="${o}" height="${o}" fill="none">${n}</svg></span><span class="reticle-hi-icon reticle-hi-icon--solid" style="width:${o}px;height:${o}px"><svg xmlns="${Xd}" viewBox="${qd}" width="${o}" height="${o}" fill="currentColor">${r}</svg></span></span>`}var se,ye,Xd,qd,jD,Gr=y(()=>{"use strict";VD();se={VIEW:"view",POINTER:"pointer",SEND:"send",CHART:"chart",CARET_DOWN:"caret-down",CHECK:"check",REMOVE:"remove",PAUSE:"pause",PLAY:"play",STOP:"stop",COPY:"copy",DOWNLOAD:"download",MESSAGE:"message",NOTES:"notes",GEAR:"gear",LAYOUT:"layout",TRASH:"trash",HELP:"help",CARET_RIGHT:"caret-right",ANNOTATE:"annotate",SYNC:"sync"},ye={CHIP:11,LOG:11,TALLY:12,CTL:10,SEND:14,MIN:12,HELP:12,NAV:18,TOOLBAR:18,FAB:22},Xd="http://www.w3.org/2000/svg",qd="0 0 24 24",jD=new Map});function Jd(e){e.scrollTop=e.scrollHeight,e.toggleAttribute(v9,e.scrollHeight>e.clientHeight+1)}function e1(e){Jd(e),requestAnimationFrame(()=>{Jd(e),requestAnimationFrame(()=>Jd(e))}),de(()=>Jd(e),w9)}function t1(e){return[...e.children].filter(t=>t.hasAttribute(Pm))}function Um(e,t){let n=t1(e);for(let r of n.slice(0,Math.max(0,n.length-t)))r.remove()}function Hm(e){for(let t of t1(e))t.remove()}function LT(e){return e===void 0||!Number.isFinite(e)||e<=0?b9:Math.floor(e)}function ep(e){let t=Math.max(0,Math.floor(e/1e3));if(t<60)return`${t}s`;let n=Math.floor(t/60);if(n<60)return t%60===0?`${n}m`:`${n}m ${t%60}s`;let r=Math.floor(n/60);return n%60===0?`${r}h`:`${r}h ${n%60}m`}function n1(e){return ep(e)}function Fm(e,t,n,r,o,i=hn.AGENT){var S,A,w;let s=t===Ge.READ?N9(e,n,i):void 0;if(s!==void 0){let N=Number((S=s.getAttribute(WD))!=null?S:"1")+1;s.setAttribute(WD,String(N));let O=s.querySelector(`.${YD}`);O===null&&(O=document.createElement("span"),O.className=YD,(A=s.querySelector(`.${zm}`))==null||A.after(O)),O.textContent=`\xD7${String(N)}`;let k=s.querySelector(`[${Qd}]`);k!==null&&(k.textContent=r);let G=s.querySelector(`.${Mm}`);return G===null?{result:()=>{}}:XD(s,G)}let a=t===Ge.ACT||t===Ge.READ;if(a&&((w=e.getAttribute(Dm))!=null?w:hn.AGENT)!==i){let N=document.createElement("div");N.setAttribute(Pm,""),N.setAttribute(IT,A9),N.setAttribute(OT,i);let O=document.createElement("span");O.className=zm,O.textContent=x9[i],N.appendChild(O),e.appendChild(N)}a&&e.setAttribute(Dm,i);let l=document.createElement("div");l.setAttribute(Pm,""),l.setAttribute(IT,t),l.setAttribute(OT,i),t===Ge.ACT&&l.setAttribute(JD,"running");let u=document.createElement("span");u.setAttribute(Qd,""),u.textContent=r;let d=[];t!==Ge.HUMAN&&d.push(u);let f=_9[t],m=S9[t];if(f.length>0||m!==void 0){let N=document.createElement("span");if(N.className=y9,N.setAttribute("data-mode",T9[t]),m!==void 0&&N.appendChild(xo(m,ye.LOG)),f.length>0){let O=document.createElement("span");O.className="reticle-chip-label",O.textContent=f,N.appendChild(O)}d.push(N)}let h=document.createElement("span");h.className=zm,h.textContent=n;let E=document.createElement("span");return E.className=Mm,d.push(h),t!==Ge.HUMAN&&d.push(E),l.append(...d),e.appendChild(l),Um(e,o),requestAnimationFrame(()=>{Jd(e)}),XD(l,E)}function N9(e,t,n){var o;let r=e.lastElementChild;if(!(!(r instanceof HTMLElement)||!r.hasAttribute(Pm))&&!(r.getAttribute(IT)!==Ge.READ||r.getAttribute(OT)!==n))return((o=r.querySelector(`.${zm}`))==null?void 0:o.textContent)===t?r:void 0}function XD(e,t){return{result:n=>{if(e.setAttribute(JD,n),n===Kn.PASS){t.textContent=KD.pass,t.className=`${Mm} ${ZD.pass}`;return}t.textContent=` ${KD[n]}`,t.className=`${Mm} ${ZD[n]}`}}}var b9,_9,S9,qD,T9,KD,x9,Dm,OT,JD,A9,ZD,CT,Pm,Qd,IT,zm,WD,YD,Mm,y9,km,w9,QD,v9,hi=y(()=>{"use strict";M();lT();dt();Gr();b9=50,_9={read:"READ",act:"ACT",narration:"",human:""},S9={read:se.VIEW,act:se.POINTER},qD={[ct.IDLE]:"",[ct.READING]:"READING",[ct.ACTING]:"ACTING"},T9={read:ct.READING,act:ct.ACTING,narration:ct.IDLE,human:ct.IDLE},KD={pass:"\u2713",fail:"Fail"},x9={agent:"Your agent is driving",harness:"Reticle Harness is driving"},Dm="data-reticle-log-actor",OT="data-actor",JD="data-state",A9="handover",ZD={pass:"reticle-pass",fail:"reticle-fail"},CT="data-reticle-log",Pm="data-reticle-log-row",Qd="data-reticle-log-time",IT="data-kind",zm="reticle-log-text",WD="data-reticle-repeat",YD="reticle-log-repeat",Mm="reticle-res",y9="reticle-chip",km={TITLE:"Reticle checks your app from the inside.",OFFLINE_TITLE:"Not connected yet.",OFFLINE_BODY:"Once Reticle is running, this page connects by itself and the steps show here.",BODY:"Ask your coding agent to verify a change with Reticle: each step shows here, live.\\AOr open Harness below: Reticle clicks through the app as the person you pick and reports what breaks."},w9=160,QD=`
130
130
  [data-reticle-log]{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;pointer-events:auto;touch-action:pan-y;
131
131
  display:flex;flex-direction:column;
132
132
  gap:4px;padding:8px 10px 10px;scrollbar-width:thin;scrollbar-color:rgba(255,255,255,.16) transparent;
133
133
  background:transparent;}
134
134
  [data-reticle-log]:empty{align-items:center;justify-content:center;gap:6px;padding:16px 18px;}
135
- [data-reticle-log]:empty::before{content:"${Im.TITLE}";display:block;text-align:center;
135
+ [data-reticle-log]:empty::before{content:"${km.TITLE}";display:block;text-align:center;
136
136
  color:var(--reticle-hud-text);font-size:var(--reticle-hud-size-base);font-weight:600;line-height:1.4;}
137
- [data-reticle-log]:empty::after{content:"${Im.BODY}";display:block;max-width:260px;text-align:center;white-space:pre-line;
137
+ [data-reticle-log]:empty::after{content:"${km.BODY}";display:block;max-width:260px;text-align:center;white-space:pre-line;
138
138
  color:var(--reticle-hud-text-muted);font-size:var(--reticle-hud-size-sm);line-height:1.5;}
139
- [data-reticle-state="unreachable"] [data-reticle-log]:empty::before{content:"${Im.OFFLINE_TITLE}";}
140
- [data-reticle-state="unreachable"] [data-reticle-log]:empty::after{content:"${Im.OFFLINE_BODY}";}
139
+ [data-reticle-state="unreachable"] [data-reticle-log]:empty::before{content:"${km.OFFLINE_TITLE}";}
140
+ [data-reticle-state="unreachable"] [data-reticle-log]:empty::after{content:"${km.OFFLINE_BODY}";}
141
141
  [data-reticle-log]::-webkit-scrollbar{width:8px;}
142
142
  [data-reticle-log]::-webkit-scrollbar-thumb{background:rgba(255,255,255,.14);border-radius:8px;border:2px solid transparent;background-clip:content-box;}
143
143
  [data-reticle-log]::-webkit-scrollbar-thumb:hover{background:rgba(255,255,255,.26);background-clip:content-box;}
@@ -160,7 +160,7 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
160
160
  [data-reticle-log] [data-reticle-log-row] .reticle-chip-label{
161
161
  position:absolute;width:1px;height:1px;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;}
162
162
  [data-reticle-log] [data-reticle-log-row][data-kind="read"] .reticle-chip{opacity:.5;}
163
- [${Yd}]{flex:none;color:var(--reticle-faint);font-size:11px;font-variant-numeric:tabular-nums;padding-top:2px;min-width:2em;opacity:.85;}
163
+ [${Qd}]{flex:none;color:var(--reticle-faint);font-size:11px;font-variant-numeric:tabular-nums;padding-top:2px;min-width:2em;opacity:.85;}
164
164
  [data-reticle-log] .reticle-log-text{flex:1;min-width:0;color:var(--reticle-muted);overflow-wrap:anywhere;word-break:break-word;}
165
165
  [data-reticle-log] .reticle-log-repeat{flex:none;color:var(--reticle-muted);font-variant-numeric:tabular-nums;opacity:.7;}
166
166
  [data-reticle-log] .reticle-res{flex:none;font-size:7.5px;font-weight:600;letter-spacing:.05em;text-transform:uppercase;color:var(--reticle-bad);opacity:.75;padding-top:2px;}
@@ -191,11 +191,11 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
191
191
  /* What the Harness or the daemon says about a drive reads as a notice, not an aside. */
192
192
  [data-reticle-log-row][data-kind="narration"]{font-style:normal;color:var(--reticle-fg);margin:4px 0;padding:7px 10px;
193
193
  border-radius:10px;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.08);}
194
- `;GZ="data-reticle-log-scrollable"});function VD(e,t=typeof navigator=="undefined"?void 0:navigator){return e!==void 0?e:(t==null?void 0:t.webdriver)===!0?0:jZ}var pa,BD,qd,GD,Mm,jZ,Fr,jD,KD,ZD,Br,WD,YD,XD,pi,os,gn,Um,xT,Ze,yt,F,qD,Hm,En,fi,is,Xt,il,Fm,Bm,Gm,Vm,JD,jm,AT,On,B,yT,Ht,ft,Jd,P,wT,sl,vT,Km,Zm,QD,Qd,e1,al,Wm,To,t1,Ym,Xm,qm,NT,Jm,n1,r1,RT,Ct=y(()=>{"use strict";po();pa={SESSION:"session",BUSY:"busy"},BD=pa.SESSION,qd="data-busy",GD="1",Mm="0",jZ=450;Fr={IDLE:"idle",BUSY:"busy",FADING:"fading"},jD=700,KD=1e3,ZD=4e3,Br={READY:"Ready",PLANNING_PREFIX:"planning next action \xB7 ",STOPPED:"stopped",STOPPED_PREFIX:"stopped \xB7 ",NOW:"now",SINCE_LAST:" since last action",harnessTesting:e=>`Testing \xB7 Harness \xB7 ${String(e)} step${e===1?"":"s"}`},WD=3e5,YD=5e3,XD=250,pi="1",os="0",gn="data-on",Um="data-reticle-state",xT="unreachable",Ze="data-reticle-min",yt="data-reticle-chat",F="data-reticle-dock",qD="data-reticle-fab",Hm="data-reticle-chat-toggle",En="data-reticle-chat-panel",fi="data-reticle-chat-placement",is="data-reticle-settings-placement",Xt="data-reticle-dock-align",il={ABOVE:"above",BELOW:"below"},Fm="data-reticle-markers-btn",Bm="data-reticle-clear-marks",Gm="data-reticle-copy-marks",Vm="data-reticle-marks-row",JD="data-reticle-mark-count",jm="data-reticle-annotate-btn",AT="data-reticle-chat-min",On="data-reticle-report",B="data-reticle-report-panel",yT="data-reticle-report-close",Ht="data-reticle-chat-pill",ft="data-reticle-settings",Jd="data-reticle-settings-btn",P="data-reticle-settings-panel",wT="data-reticle-settings-close",sl="data-reticle-setting",vT=At.PRESENTER_SETTINGS,Km=At.PRESENTER_MINIMISED,Zm=At.PRESENTER_OPEN,QD="data-reticle-ambient-glow",Qd="data-reticle-live",e1="data-reticle-block",al="data-reticle-hidden",Wm="data-reticle-log-ts",To="data-reticle-reduce-motion",t1="https://github.com/reticlehq/reticle/blob/main/docs/getting-started.md",Ym="data-dragged",Xm="--reticle-hud-x",qm="--reticle-hud-y",NT=4,Jm=8,n1="[data-reticle-pause], [data-reticle-annotate-btn], [data-reticle-markers-btn], [data-reticle-clear-marks], [data-reticle-copy-marks], [data-reticle-end], [data-reticle-min-btn], [data-reticle-settings-btn], [data-reticle-settings-panel], [data-reticle-report-btn], [data-reticle-report-panel], [data-reticle-chat-panel], [data-reticle-chat-toggle], [data-reticle-workspace-btn], [data-reticle-workspace-menu], [data-reticle-copy], [data-reticle-export], .reticle-toolbar-chrome button, .reticle-toolbar-actions button, input, textarea, select, a, .reticle-head-ctl, [data-reticle-tally], .reticle-maxhint",r1="data-reticle-throttled",RT=100});var Xn,OT,ep,Gr,cl,o1,Qm,i1,Vr=y(()=>{"use strict";Xn="reticle-hud-surface",OT="linear-gradient(165deg,#121218 0%,#09090c 42%,#000 100%)",ep=`background:${OT};box-shadow:inset 0 1px 0 rgba(255,255,255,.09),0 0 0 1px rgba(255,255,255,.09);`,Gr="0 16px 40px rgba(0,0,0,.58),0 0 0 1px rgba(255,255,255,.08)",cl=["background:radial-gradient(130% 80% at 50% 0%,color-mix(in srgb,var(--reticle-c-active) 20%,transparent),transparent 62%),","linear-gradient(180deg,#121a2e,#080b14);","border:1px solid color-mix(in srgb,var(--reticle-c-active) 30%,rgba(255,255,255,.1));",`box-shadow:${Gr},0 0 64px -12px color-mix(in srgb,var(--reticle-c-active) 75%,transparent);`].join(""),o1=`
194
+ `;v9="data-reticle-log-scrollable"});function i1(e,t=typeof navigator=="undefined"?void 0:navigator){return e!==void 0?e:(t==null?void 0:t.webdriver)===!0?0:R9}var fa,r1,tp,o1,Bm,R9,Vr,s1,a1,c1,jr,l1,u1,d1,mi,is,gn,Gm,$T,We,yt,F,p1,Vm,En,gi,ss,Xt,cl,jm,Km,Zm,Wm,f1,Ym,kT,In,B,zT,Ft,ft,np,P,DT,ll,PT,Xm,qm,h1,rp,m1,ul,Jm,Ao,g1,Qm,eg,tg,MT,ng,E1,b1,UT,Lt=y(()=>{"use strict";ho();fa={SESSION:"session",BUSY:"busy"},r1=fa.SESSION,tp="data-busy",o1="1",Bm="0",R9=450;Vr={IDLE:"idle",BUSY:"busy",FADING:"fading"},s1=700,a1=1e3,c1=4e3,jr={READY:"Ready",PLANNING_PREFIX:"planning next action \xB7 ",STOPPED:"stopped",STOPPED_PREFIX:"stopped \xB7 ",NOW:"now",SINCE_LAST:" since last action",harnessTesting:e=>`Testing \xB7 Harness \xB7 ${String(e)} step${e===1?"":"s"}`},l1=3e5,u1=5e3,d1=250,mi="1",is="0",gn="data-on",Gm="data-reticle-state",$T="unreachable",We="data-reticle-min",yt="data-reticle-chat",F="data-reticle-dock",p1="data-reticle-fab",Vm="data-reticle-chat-toggle",En="data-reticle-chat-panel",gi="data-reticle-chat-placement",ss="data-reticle-settings-placement",Xt="data-reticle-dock-align",cl={ABOVE:"above",BELOW:"below"},jm="data-reticle-markers-btn",Km="data-reticle-clear-marks",Zm="data-reticle-copy-marks",Wm="data-reticle-marks-row",f1="data-reticle-mark-count",Ym="data-reticle-annotate-btn",kT="data-reticle-chat-min",In="data-reticle-report",B="data-reticle-report-panel",zT="data-reticle-report-close",Ft="data-reticle-chat-pill",ft="data-reticle-settings",np="data-reticle-settings-btn",P="data-reticle-settings-panel",DT="data-reticle-settings-close",ll="data-reticle-setting",PT=At.PRESENTER_SETTINGS,Xm=At.PRESENTER_MINIMISED,qm=At.PRESENTER_OPEN,h1="data-reticle-ambient-glow",rp="data-reticle-live",m1="data-reticle-block",ul="data-reticle-hidden",Jm="data-reticle-log-ts",Ao="data-reticle-reduce-motion",g1="https://github.com/reticlehq/reticle/blob/main/docs/getting-started.md",Qm="data-dragged",eg="--reticle-hud-x",tg="--reticle-hud-y",MT=4,ng=8,E1="[data-reticle-pause], [data-reticle-annotate-btn], [data-reticle-markers-btn], [data-reticle-clear-marks], [data-reticle-copy-marks], [data-reticle-end], [data-reticle-min-btn], [data-reticle-settings-btn], [data-reticle-settings-panel], [data-reticle-report-btn], [data-reticle-report-panel], [data-reticle-chat-panel], [data-reticle-chat-toggle], [data-reticle-workspace-btn], [data-reticle-workspace-menu], [data-reticle-copy], [data-reticle-export], .reticle-toolbar-chrome button, .reticle-toolbar-actions button, input, textarea, select, a, .reticle-head-ctl, [data-reticle-tally], .reticle-maxhint",b1="data-reticle-throttled",UT=100});var Xn,HT,op,Kr,dl,_1,rg,S1,Zr=y(()=>{"use strict";Xn="reticle-hud-surface",HT="linear-gradient(165deg,#121218 0%,#09090c 42%,#000 100%)",op=`background:${HT};box-shadow:inset 0 1px 0 rgba(255,255,255,.09),0 0 0 1px rgba(255,255,255,.09);`,Kr="0 16px 40px rgba(0,0,0,.58),0 0 0 1px rgba(255,255,255,.08)",dl=["background:radial-gradient(130% 80% at 50% 0%,color-mix(in srgb,var(--reticle-c-active) 20%,transparent),transparent 62%),","linear-gradient(180deg,#121a2e,#080b14);","border:1px solid color-mix(in srgb,var(--reticle-c-active) 30%,rgba(255,255,255,.1));",`box-shadow:${Kr},0 0 64px -12px color-mix(in srgb,var(--reticle-c-active) 75%,transparent);`].join(""),_1=`
195
195
  .${Xn}{
196
196
  position:relative;overflow:hidden;
197
197
  contain:layout style paint;
198
- ${ep}
198
+ ${op}
199
199
  }
200
200
  .${Xn}::before,
201
201
  [data-reticle-hud] .reticle-hud-deco::after{
@@ -204,8 +204,8 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
204
204
  radial-gradient(ellipse 120% 70% at 50% -18%,rgba(255,255,255,.07),transparent 52%),
205
205
  linear-gradient(180deg,rgba(255,255,255,.035) 0%,transparent 36%,rgba(0,0,0,.12) 100%);
206
206
  }
207
- .${Xn} > *{position:relative;z-index:2;}`,Qm="reticle-hud-log-well",i1=`
208
- .${Qm}{
207
+ .${Xn} > *{position:relative;z-index:2;}`,rg="reticle-hud-log-well",S1=`
208
+ .${rg}{
209
209
  /* A settled height, but still allowed to shrink: pinned with flex:none it pushed the composer
210
210
  off the bottom of the panel the moment the rest of the content grew. */
211
211
  /* A flex column, so the feed inside actually FILLS the height: as a plain block the log was only
@@ -215,7 +215,7 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
215
215
  flex:1 1 auto;height:240px;min-height:120px;max-height:300px;overflow:hidden;
216
216
  contain:layout style paint;
217
217
  margin:0 6px;border-radius:12px;background:transparent;}
218
- .${Qm} > *{position:relative;z-index:1;}`});function ll(e){return e.getAttribute(Ym)==="1"}function ul(e,t,n,r,o,i,s=Jm){let a=s,l=s,u=Math.max(a,o-n-s),d=Math.max(l,i-r-s);return{left:Math.max(a,Math.min(e,u)),top:Math.max(l,Math.min(t,d))}}function ss(e,t,n){e.setAttribute(Ym,"1"),e.style.setProperty(Xm,`${String(t)}px`),e.style.setProperty(qm,`${String(n)}px`)}function tp(e){e.removeAttribute(Ym),e.style.removeProperty(Xm),e.style.removeProperty(qm)}function dl(e){let t=e.getBoundingClientRect();return{left:t.left,top:t.top,width:t.width,height:t.height}}function eg(e){let t=e.style.getPropertyValue(Xm),n=e.style.getPropertyValue(qm);if(t!==""&&n!=="")return{left:Number.parseFloat(t),top:Number.parseFloat(n)};let r=e.getBoundingClientRect();return{left:r.left,top:r.top}}function np(e){if(!ll(e))return;let{left:t,top:n}=eg(e),{width:r,height:o}=dl(e),i=ul(t,n,r,o,window.innerWidth,window.innerHeight);ss(e,i.left,i.top)}var rp=y(()=>{"use strict";Ct()});function YZ(e){var i,s,a,l,u,d,f,m;if(e.length===0)return;let t=(s=(i=e[0])==null?void 0:i.left)!=null?s:0,n=(l=(a=e[0])==null?void 0:a.top)!=null?l:0,r=(d=(u=e[0])==null?void 0:u.right)!=null?d:0,o=(m=(f=e[0])==null?void 0:f.bottom)!=null?m:0;for(let h of e.slice(1))t=Math.min(t,h.left),n=Math.min(n,h.top),r=Math.max(r,h.right),o=Math.max(o,h.bottom);return{left:t,top:n,right:r,bottom:o}}function d1(e,t,n){return e>=n?il.ABOVE:t>=n?il.BELOW:t>e?il.BELOW:il.ABOVE}function p1(e,t,n,r){let o=il.ABOVE===e?t-r:n-r;return Math.max(0,o)}function f1(e,t,n){let r=`${String(n)}px`;e.style.setProperty(t,r),e.style.maxHeight=r}function h1(e,t){e.style.removeProperty(t),e.style.removeProperty("max-height")}function tg(e){if(e===null)return!1;let t=window.getComputedStyle(e);return t.display!=="none"&&t.visibility!=="hidden"}function XZ(e){let t=e.querySelector(`[${s1}]`);if(t instanceof HTMLElement)return t;if(e.hasAttribute(s1)||ll(e))return e}function m1(e,t){let n=XZ(e);if(n===void 0)return;let r=t.getAttribute(yt)==="1",o=t.getAttribute(ft)==="1",i=e.querySelector(`[${En}]`),s=e.querySelector(`[${P}]`),a=Jm,l=window.innerWidth,u=window.innerHeight,d=n.getBoundingClientRect(),f=d.top-a,m=u-d.bottom-a;if(r&&i instanceof HTMLElement&&tg(i)){let k=i.getBoundingClientRect().height||l1,j=d1(f,m,k+a1);e.setAttribute(fi,j);let Y=Math.min(l1,Math.max(ZZ,p1(j,f,m,a1)));f1(i,"--reticle-chat-max-h",Y)}else e.removeAttribute(fi),i instanceof HTMLElement&&h1(i,"--reticle-chat-max-h");if(o&&s instanceof HTMLElement&&tg(s)){let k=s.getBoundingClientRect().height||u1,j=d1(f,m,k+KZ+c1);e.setAttribute(is,j);let Y=Math.min(u1,Math.max(WZ,p1(j,f,m,c1)));f1(s,"--reticle-settings-max-h",Y)}else e.removeAttribute(is),s instanceof HTMLElement&&h1(s,"--reticle-settings-max-h");let h=Math.max(r&&i instanceof HTMLElement?i.getBoundingClientRect().width:0,o&&s instanceof HTMLElement?s.getBoundingClientRect().width:0);if(r||o){let k=d.right-h,j=d.left+h;k<a||d.left<a?e.setAttribute(Xt,"start"):j>l-a||d.right>l-a?e.setAttribute(Xt,"end"):e.setAttribute(Xt,"end")}else e.removeAttribute(Xt);if(!r&&!o){ll(e)&&np(e);return}let E=[d];r&&i instanceof HTMLElement&&tg(i)&&E.push(i.getBoundingClientRect()),o&&s instanceof HTMLElement&&tg(s)&&E.push(s.getBoundingClientRect());let _=YZ(E);if(_===void 0)return;let A=0,v=0;if(_.left<a?A=a-_.left:_.right>l-a&&(A=l-a-_.right),_.top<a?v=a-_.top:_.bottom>u-a&&(v=u-a-_.bottom),A===0&&v===0)return;let N=e.getBoundingClientRect(),O=ll(e)?eg(e):{left:N.left,top:N.top};ss(e,O.left+A,O.top+v)}function jr(e,t){ng!==void 0&&cancelAnimationFrame(ng),ng=requestAnimationFrame(()=>{ng=void 0,m1(e,t),requestAnimationFrame(()=>m1(e,t))})}function g1(e){let t=e.querySelector(`[${F}]`);return t instanceof HTMLElement?t:void 0}var s1,a1,c1,KZ,ZZ,l1,u1,WZ,ng,op=y(()=>{"use strict";Ct();rp();s1="data-reticle-hud",a1=8,c1=12,KZ=44,ZZ=160,l1=440,u1=520,WZ=200});function b1(e,t){var u,d;let n=()=>{jr(e,t)},r=new AbortController,{signal:o}=r,i=()=>n();window.addEventListener("resize",i,{signal:o});let s;typeof ResizeObserver!="undefined"&&(s=new ResizeObserver(()=>n()),s.observe(e));let a=new MutationObserver(()=>n());a.observe(t,{attributes:!0,attributeFilter:[Ze,yt,ft]});let l=()=>n();return(u=window.visualViewport)==null||u.addEventListener("resize",l,{signal:o}),(d=window.visualViewport)==null||d.addEventListener("scroll",l,{signal:o}),()=>{r.abort(),s==null||s.disconnect(),a.disconnect()}}function qZ(e,t,n={}){let r=!1,o=0,i=0,s=0,a=0,l=!1,u,d=()=>{var O;let N=l;if(r=!1,t.classList.remove(E1),u=void 0,l=!1,N){let k=e.parentElement;k instanceof HTMLElement?jr(e,k):np(e)}(O=n.onDragEnd)==null||O.call(n,N)},f=N=>{if(N.button!==0)return;let O=N.target;if(!(O instanceof Element)||O.closest(n1)!==null)return;let k=e.getBoundingClientRect();o=N.clientX,i=N.clientY,s=k.left,a=k.top,r=!0,l=!1,u=N.pointerId,t.classList.add(E1),typeof t.setPointerCapture=="function"&&t.setPointerCapture(N.pointerId),N.preventDefault()},m=N=>{var X;if(!r||N.pointerId!==u)return;let O=N.clientX-o,k=N.clientY-i;if(!l&&Math.abs(O)<NT&&Math.abs(k)<NT)return;l=!0,(X=n.onDragMove)==null||X.call(n);let j=dl(e),Y=ul(s+O,a+k,j.width,j.height,window.innerWidth,window.innerHeight);ss(e,Y.left,Y.top),N.preventDefault()},h=N=>{typeof t.releasePointerCapture=="function"&&t.releasePointerCapture(N)},E=N=>{!r||N.pointerId!==u||(l&&N.preventDefault(),h(N.pointerId),d())},_=N=>{!r||N.pointerId!==u||(h(N.pointerId),d())},A=new AbortController,{signal:v}=A;return t.addEventListener("pointerdown",f,{signal:v}),t.addEventListener("pointermove",m,{signal:v}),t.addEventListener("pointerup",E,{signal:v}),t.addEventListener("pointercancel",_,{signal:v}),()=>{A.abort(),r&&h(u!=null?u:0),d()}}function _1(e,t,n={}){let r=t.map(o=>qZ(e,o,n));return()=>{for(let o of r)o()}}var E1,IT=y(()=>{"use strict";Ct();op();rp();rp();E1="reticle-drag-handle--dragging"});var rg,CT=y(()=>{"use strict";Ct();Vr();rg=`
218
+ .${rg} > *{position:relative;z-index:1;}`});function pl(e){return e.getAttribute(Qm)==="1"}function fl(e,t,n,r,o,i,s=ng){let a=s,l=s,u=Math.max(a,o-n-s),d=Math.max(l,i-r-s);return{left:Math.max(a,Math.min(e,u)),top:Math.max(l,Math.min(t,d))}}function as(e,t,n){e.setAttribute(Qm,"1"),e.style.setProperty(eg,`${String(t)}px`),e.style.setProperty(tg,`${String(n)}px`)}function ip(e){e.removeAttribute(Qm),e.style.removeProperty(eg),e.style.removeProperty(tg)}function hl(e){let t=e.getBoundingClientRect();return{left:t.left,top:t.top,width:t.width,height:t.height}}function og(e){let t=e.style.getPropertyValue(eg),n=e.style.getPropertyValue(tg);if(t!==""&&n!=="")return{left:Number.parseFloat(t),top:Number.parseFloat(n)};let r=e.getBoundingClientRect();return{left:r.left,top:r.top}}function sp(e){if(!pl(e))return;let{left:t,top:n}=og(e),{width:r,height:o}=hl(e),i=fl(t,n,r,o,window.innerWidth,window.innerHeight);as(e,i.left,i.top)}var ap=y(()=>{"use strict";Lt()});function L9(e){var i,s,a,l,u,d,f,m;if(e.length===0)return;let t=(s=(i=e[0])==null?void 0:i.left)!=null?s:0,n=(l=(a=e[0])==null?void 0:a.top)!=null?l:0,r=(d=(u=e[0])==null?void 0:u.right)!=null?d:0,o=(m=(f=e[0])==null?void 0:f.bottom)!=null?m:0;for(let h of e.slice(1))t=Math.min(t,h.left),n=Math.min(n,h.top),r=Math.max(r,h.right),o=Math.max(o,h.bottom);return{left:t,top:n,right:r,bottom:o}}function v1(e,t,n){return e>=n?cl.ABOVE:t>=n?cl.BELOW:t>e?cl.BELOW:cl.ABOVE}function N1(e,t,n,r){let o=cl.ABOVE===e?t-r:n-r;return Math.max(0,o)}function R1(e,t,n){let r=`${String(n)}px`;e.style.setProperty(t,r),e.style.maxHeight=r}function O1(e,t){e.style.removeProperty(t),e.style.removeProperty("max-height")}function ig(e){if(e===null)return!1;let t=window.getComputedStyle(e);return t.display!=="none"&&t.visibility!=="hidden"}function $9(e){let t=e.querySelector(`[${T1}]`);if(t instanceof HTMLElement)return t;if(e.hasAttribute(T1)||pl(e))return e}function I1(e,t){let n=$9(e);if(n===void 0)return;let r=t.getAttribute(yt)==="1",o=t.getAttribute(ft)==="1",i=e.querySelector(`[${En}]`),s=e.querySelector(`[${P}]`),a=ng,l=window.innerWidth,u=window.innerHeight,d=n.getBoundingClientRect(),f=d.top-a,m=u-d.bottom-a;if(r&&i instanceof HTMLElement&&ig(i)){let k=i.getBoundingClientRect().height||y1,G=v1(f,m,k+x1);e.setAttribute(gi,G);let V=Math.min(y1,Math.max(I9,N1(G,f,m,x1)));R1(i,"--reticle-chat-max-h",V)}else e.removeAttribute(gi),i instanceof HTMLElement&&O1(i,"--reticle-chat-max-h");if(o&&s instanceof HTMLElement&&ig(s)){let k=s.getBoundingClientRect().height||w1,G=v1(f,m,k+O9+A1);e.setAttribute(ss,G);let V=Math.min(w1,Math.max(C9,N1(G,f,m,A1)));R1(s,"--reticle-settings-max-h",V)}else e.removeAttribute(ss),s instanceof HTMLElement&&O1(s,"--reticle-settings-max-h");let h=Math.max(r&&i instanceof HTMLElement?i.getBoundingClientRect().width:0,o&&s instanceof HTMLElement?s.getBoundingClientRect().width:0);if(r||o){let k=d.right-h,G=d.left+h;k<a||d.left<a?e.setAttribute(Xt,"start"):G>l-a||d.right>l-a?e.setAttribute(Xt,"end"):e.setAttribute(Xt,"end")}else e.removeAttribute(Xt);if(!r&&!o){pl(e)&&sp(e);return}let E=[d];r&&i instanceof HTMLElement&&ig(i)&&E.push(i.getBoundingClientRect()),o&&s instanceof HTMLElement&&ig(s)&&E.push(s.getBoundingClientRect());let S=L9(E);if(S===void 0)return;let A=0,w=0;if(S.left<a?A=a-S.left:S.right>l-a&&(A=l-a-S.right),S.top<a?w=a-S.top:S.bottom>u-a&&(w=u-a-S.bottom),A===0&&w===0)return;let N=e.getBoundingClientRect(),O=pl(e)?og(e):{left:N.left,top:N.top};as(e,O.left+A,O.top+w)}function Wr(e,t){sg!==void 0&&cancelAnimationFrame(sg),sg=requestAnimationFrame(()=>{sg=void 0,I1(e,t),requestAnimationFrame(()=>I1(e,t))})}function C1(e){let t=e.querySelector(`[${F}]`);return t instanceof HTMLElement?t:void 0}var T1,x1,A1,O9,I9,y1,w1,C9,sg,cp=y(()=>{"use strict";Lt();ap();T1="data-reticle-hud",x1=8,A1=12,O9=44,I9=160,y1=440,w1=520,C9=200});function $1(e,t){var u,d;let n=()=>{Wr(e,t)},r=new AbortController,{signal:o}=r,i=()=>n();window.addEventListener("resize",i,{signal:o});let s;typeof ResizeObserver!="undefined"&&(s=new ResizeObserver(()=>n()),s.observe(e));let a=new MutationObserver(()=>n());a.observe(t,{attributes:!0,attributeFilter:[We,yt,ft]});let l=()=>n();return(u=window.visualViewport)==null||u.addEventListener("resize",l,{signal:o}),(d=window.visualViewport)==null||d.addEventListener("scroll",l,{signal:o}),()=>{r.abort(),s==null||s.disconnect(),a.disconnect()}}function k9(e,t,n={}){let r=!1,o=0,i=0,s=0,a=0,l=!1,u,d=()=>{var O;let N=l;if(r=!1,t.classList.remove(L1),u=void 0,l=!1,N){let k=e.parentElement;k instanceof HTMLElement?Wr(e,k):sp(e)}(O=n.onDragEnd)==null||O.call(n,N)},f=N=>{if(N.button!==0)return;let O=N.target;if(!(O instanceof Element)||O.closest(E1)!==null)return;let k=e.getBoundingClientRect();o=N.clientX,i=N.clientY,s=k.left,a=k.top,r=!0,l=!1,u=N.pointerId,t.classList.add(L1),typeof t.setPointerCapture=="function"&&t.setPointerCapture(N.pointerId),N.preventDefault()},m=N=>{var W;if(!r||N.pointerId!==u)return;let O=N.clientX-o,k=N.clientY-i;if(!l&&Math.abs(O)<MT&&Math.abs(k)<MT)return;l=!0,(W=n.onDragMove)==null||W.call(n);let G=hl(e),V=fl(s+O,a+k,G.width,G.height,window.innerWidth,window.innerHeight);as(e,V.left,V.top),N.preventDefault()},h=N=>{typeof t.releasePointerCapture=="function"&&t.releasePointerCapture(N)},E=N=>{!r||N.pointerId!==u||(l&&N.preventDefault(),h(N.pointerId),d())},S=N=>{!r||N.pointerId!==u||(h(N.pointerId),d())},A=new AbortController,{signal:w}=A;return t.addEventListener("pointerdown",f,{signal:w}),t.addEventListener("pointermove",m,{signal:w}),t.addEventListener("pointerup",E,{signal:w}),t.addEventListener("pointercancel",S,{signal:w}),()=>{A.abort(),r&&h(u!=null?u:0),d()}}function k1(e,t,n={}){let r=t.map(o=>k9(e,o,n));return()=>{for(let o of r)o()}}var L1,FT=y(()=>{"use strict";Lt();cp();ap();ap();L1="reticle-drag-handle--dragging"});var ag,BT=y(()=>{"use strict";Lt();Zr();ag=`
219
219
  [data-reticle-overlay][${ft}="1"] [data-reticle-chat-panel]{
220
220
  display:none !important;visibility:hidden !important;pointer-events:none !important;}
221
221
  [${P}]{
@@ -224,17 +224,17 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
224
224
  max-width:min(272px,calc(100vw - 16px));
225
225
  max-height:min(var(--reticle-settings-max-h,78vh),calc(100vh - 96px));
226
226
  padding:0;border:none;border-radius:16px;overflow:hidden;
227
- box-shadow:${Gr};
227
+ box-shadow:${Kr};
228
228
  color:var(--reticle-fg);font-size:13px;line-height:1.35;
229
229
  opacity:0;pointer-events:none;visibility:hidden;touch-action:manipulation;
230
230
  transform:translate3d(0,6px,0) scale(.98);
231
231
  transition:opacity .14s ease,transform .18s cubic-bezier(.22,1,.36,1),visibility .14s;
232
- contain:none;isolation:isolate;${ep}}
233
- [${F}][${is}="below"] [${P}]{
232
+ contain:none;isolation:isolate;${op}}
233
+ [${F}][${ss}="below"] [${P}]{
234
234
  bottom:auto;top:calc(100% + 12px);}
235
235
  [${F}][${Xt}="start"] [${P}]{
236
236
  right:auto;left:0;}
237
- [${F}][${is}="below"] [${P}].${Xn}::after{
237
+ [${F}][${ss}="below"] [${P}].${Xn}::after{
238
238
  top:auto;bottom:100%;margin-top:0;margin-bottom:-4px;box-shadow:-1px -1px 0 0 rgba(255,255,255,.08);}
239
239
  [${F}][${Xt}="start"] [${P}].${Xn}::after{
240
240
  right:auto;left:14px;}
@@ -380,76 +380,76 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
380
380
  [data-reticle-overlay][data-reticle-hidden="1"] [${F}],
381
381
  [data-reticle-overlay][data-reticle-hidden="1"] [${P}]{display:none !important;}
382
382
 
383
- `});function T1(e){return ip!=null||(ip=new Set([...JZ,...Object.entries(QZ).flatMap(([t,n])=>n.map(r=>`${t}.${r}`))])),ip.has(e)}var JZ,S1,QZ,ip,x1=y(()=>{"use strict";JZ=["fab","pause","chat-toggle","markers-btn","end","clear-marks","copy-marks","copy","export","annotate-btn","report-btn","settings-btn","min-btn","chat-min","chat-pill","chat-impact","copy-all-notes","promo-link","replay","carousel-dot","carousel-prev","carousel-next","carousel-close","page-close","team-open","team-save","talk-book","account-signin","account-trigger","account-signout","account-dashboard","sync-now","report-scope","report-close","share-x","share-in","share-copy","refer","settings-close","settings-help","settings-reset","settings-mcp","settings-kill","feedback-email","feedback-call","workspace-btn","workspace-copy","mark-cancel","mark-send","harness-switch","harness-run","harness-stop","harness-open","harness-toggle","harness-link","agent-copy","defects-all","plan-close","plan-journey"],S1=["setting","check","settings-cycle","theme","tour-target","link","annotation-tab","chat-view-btn"],QZ={setting:["autoOpenChat","showTimestamps","showTally","reactComponents","hideUntilRestart","harnessEnabled","reduceMotion","ambientGlow"],check:["blockPageInteractions","clearOnCopy"],"settings-cycle":["outputDetail"],theme:["signal","traffic","mono","neon","ember"],"tour-target":["copy","back","done","next","skip"],link:["docs","github","site","discord","defect","dashboard"],"annotation-tab":["current","history"],"chat-view-btn":["activity","flows","annotations","harness"]}});function r9(e){try{let t=new URL(e);return t.protocol!=="https:"?!1:e9.has(t.hostname)?!0:t9===t.hostname&&t.pathname.startsWith(n9)}catch{return!1}}var e9,t9,n9,LT,o9,Npe,A1=y(()=>{"use strict";ae();e9=new Set(["reticle.sh","www.reticle.sh","app.reticle.sh","docs.reticle.sh"]),t9="github.com",n9="/reticlehq/";LT=b({id:p().regex(/^[a-z0-9-]{1,48}$/),kicker:p().min(1).max(40).optional(),title:p().min(1).max(80),detail:p().min(1).max(120).optional(),cta:b({label:p().min(1).max(24),url:p().refine(r9)}).optional()}),o9=b({signedIn:L().optional(),entitled:L().optional()}),Npe=LT.extend({audience:o9.optional(),from:p().optional(),until:p().optional(),minSdk:p().optional(),weight:S().optional()})});function as(e){return e!==void 0&&e.used>=e.limit}function N1(e){let t=`${fa(Math.max(0,e.limit-e.used))} of ${fa(e.limit)}`;return xt.FREE===e.kind?`${t} free credits`:xt.TRIAL===e.kind?`${t} trial credits`:`${t} credits left`}function kT(e){let t=e.kind===void 0?void 0:i9[e.kind],n=Math.max(0,e.limit-e.used),r=e.daysLeft===void 0?"":` \xB7 ${String(e.daysLeft)} day${e.daysLeft===1?"":"s"} left`;return`${t===void 0?"":`${t}: `}${fa(e.used)} of ${fa(e.limit)} credits used \xB7 ${fa(n)} left${r}`}function og(e){return xt.FREE===e.kind?{said:`Your ${fa(e.limit)} free credits are used.`,action:`Add a card to start your ${String($T)}-day trial`}:xt.TRIAL===e.kind?{said:`Your ${fa(e.limit)} trial credits are used. Pro starts when your trial ends.`}:{said:"This month's credits are used. They renew over the next 30 days."}}var $T,y1,w1,v1,fa,i9,R1=y(()=>{"use strict";R_();$T=14,y1=500,w1=`Sign up: free credits to try Reticle \xB7 add a card for a ${String(y1)}-credit, ${String($T)}-day trial`,v1=`a card starts a ${String($T)}-day trial with ${String(y1)} credits; without one, free sign-up credits`,fa=e=>e.toLocaleString("en-US",{maximumFractionDigits:2});i9={[xt.FREE]:"Free",[xt.TRIAL]:"Trial"}});var pl=y(()=>{"use strict";x1();A1();R1()});function de(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;")}function Er(e){try{let t=new URL(e).protocol;return t==="https:"||t==="http:"}catch{return!1}}var ha=y(()=>{"use strict"});function sp(e,t){let n=document.createElement("template");n.innerHTML=t,O1(e,n.content)}function O1(e,t){let n=[...e.childNodes],r=[...t.childNodes];r.forEach((o,i)=>{let s=n[i];s===void 0?e.appendChild(o):s.nodeType===o.nodeType&&s.nodeName===o.nodeName?s9(s,o):e.replaceChild(o,s)});for(let o of n.slice(r.length))e.removeChild(o)}function s9(e,t){if(!(e instanceof Element)||!(t instanceof Element)){e.nodeValue!==t.nodeValue&&(e.nodeValue=t.nodeValue);return}for(let{name:n}of[...e.attributes])t.hasAttribute(n)||e.removeAttribute(n);for(let{name:n,value:r}of[...t.attributes])e.getAttribute(n)!==r&&e.setAttribute(n,r);O1(e,t)}var zT=y(()=>{"use strict"});function C1(e){let n=(e!=null?e:"").trim().split(/[\s._-]+/).filter(r=>r.length>0).slice(0,2).map(r=>{var o;return(o=[...r][0])!=null?o:""}).join("");return n.length>0?n.toUpperCase():fe.AVATAR_FALLBACK}function hl(e,t={},n=!1){var a;if(e===void 0)return"";if(!e.signedIn)return n?`<div class="reticle-account" ${I1}><button type="button" class="reticle-account-signin" ${qt} title="${fe.SIGNIN_TITLE}" aria-label="${fe.SIGNIN_TITLE}">${fe.SIGNED_OUT}</button></div>`:"";let r=(a=e.org)!=null?a:"",o=r.length>0?de(r):fe.SIGNED_IN_AS,i=`<span class="reticle-account-avatar" aria-hidden="true">${de(C1(e.org))}</span>`,s=`<button type="button" class="reticle-account-trigger" ${sg} aria-haspopup="true" aria-expanded="false" title="${fe.TRIGGER_TITLE}" aria-label="${fe.TRIGGER_TITLE}: ${o}">${i}</button>`;return`<div class="reticle-account" ${I1}>${s}${u9(e,t)}</div>`}function hi(e,t){return t===void 0||t.length===0?"":`<div class="reticle-account-row"><span class="reticle-account-k">${de(e)}</span><span class="reticle-account-v" title="${de(t)}">${de(t)}</span></div>`}function u9(e,t){var l,u;let n=(l=e.org)!=null?l:"",r=`<div class="reticle-account-head"><span class="reticle-account-avatar reticle-account-avatar--lg" aria-hidden="true">${de(C1(e.org))}</span><span class="reticle-account-who"><span class="reticle-account-org">${n.length>0?de(n):fe.SIGNED_IN_AS}</span>`+(e.email!==void 0&&e.email.length>0?`<span class="reticle-account-email" title="${de(e.email)}">${de(e.email)}</span>`:n.length>0?`<span class="reticle-account-email">${fe.SIGNED_IN_AS}</span>`:"")+"</span></div>",o=hi(fe.HOST_LABEL,e.host)+hi(fe.PROJECT_LABEL,t.projectName)+hi(fe.VERDICTS_LABEL,t.verdicts!==void 0?String(t.verdicts):void 0)+hi(fe.DEFECTS_LABEL,t.defects!==void 0?String(t.defects):void 0)+hi(fe.ON_PLATFORM_LABEL,t.onPlatform)+hi(fe.PLAN_LABEL,t.plan)+hi(fe.CREDITS_LABEL,t.credits)+hi(fe.HARNESS_RUNS_LABEL,t.harnessRuns)+hi(fe.MEMORY_LABEL,t.memory),s=t.dashboardUrl!==void 0&&Er(t.dashboardUrl)?`<a class="reticle-account-action" data-reticle-account-dashboard href="${de((u=t.dashboardUrl)!=null?u:"")}" target="_blank" rel="noreferrer noopener" title="${fe.DASHBOARD_TITLE}">${Ie(se.VIEW,Ae.HELP)}<span>${fe.DASHBOARD_ACTION}</span></a>`:`<button type="button" class="reticle-account-action reticle-account-action--hint" ${qt} data-reticle-copy="${fe.LINK_COMMAND}" title="${fe.LINK_HINT}"><span>${fe.LINK_HINT}</span></button>`,a=`<button type="button" class="reticle-account-action" ${a9} data-reticle-copy="${fe.SIGNOUT_COMMAND}" title="${fe.SIGNOUT_TITLE}"><span>${fe.SIGNOUT_ACTION}</span></button>`;return`<div class="reticle-account-menu" ${cs} role="menu" aria-label="${fe.MENU_LABEL}" aria-hidden="true" hidden>`+r+(o.length>0?`<div class="reticle-account-rows">${o}</div>`:"")+`<div class="reticle-account-actions">${s}${a}</div></div>`}function L1(e,t){let n=e==null?void 0:e.plan,r=t==null?void 0:t.onPlatform;return{...n===void 0?{}:{plan:[d9[n.kind],n.daysLeft===void 0?"":`${DT(n.daysLeft,"day","days")} left`,n.seats===void 0?"":DT(n.seats,"seat","seats")].filter(o=>o.length>0).join(" \xB7 ")},...(e==null?void 0:e.credits)===void 0?{}:{credits:`${Math.max(0,e.credits.limit-e.credits.used).toLocaleString("en-US")} of ${e.credits.limit.toLocaleString("en-US")} left`},...(e==null?void 0:e.harnessRuns)===void 0?{}:{harnessRuns:String(e.harnessRuns)},...(e==null?void 0:e.memoryEntries)===void 0?{}:{memory:DT(e.memoryEntries,"entry","entries")},...typeof r=="number"?{onPlatform:String(r)}:{}}}function $1(e,t){return e===void 0||!e.signedIn?"":t!==void 0&&Er(t)?`<a ${c9} class="reticle-team-link" href="${de(t)}" target="_blank" rel="noreferrer noopener" title="${de(ig.OPEN_TITLE)}">${ig.OPEN}</a>`:`<button type="button" ${ap} class="reticle-team-link" title="${de(ig.SAVE_TITLE)}"><span>${ig.SAVE_LINK}</span></button>`}function cp(e,t){var o;let n=e.querySelector(`[${cs}]:not([hidden])`)!==null;if(sp(e,t),!n)return;let r=e.querySelector(`[${cs}]`);r!==null&&(r.removeAttribute("hidden"),r.setAttribute("aria-hidden","false"),(o=e.querySelector(`[${sg}]`))==null||o.setAttribute("aria-expanded","true"))}function MT(e){return e===void 0||!Er(e)?"":`<button type="button" class="reticle-sync-now" ${PT} title="${fe.SYNC_TITLE}" aria-label="${fe.SYNC_TITLE}">${Ie(se.SYNC,Ae.HELP)}</button>`}function k1(e,t){let n=new AbortController,{signal:r}=n,o=a=>{for(let l of e.querySelectorAll(`[${cs}]`))l!==a&&(l.setAttribute("hidden",""),l.setAttribute("aria-hidden","true"));for(let l of e.querySelectorAll(`[${sg}]`))a!==void 0&&l.parentElement===a.parentElement||l.setAttribute("aria-expanded","false")},i=(a,l)=>{var f;let u=(f=a.querySelector("span"))!=null?f:a,d=u.textContent;u.textContent=l,setTimeout(()=>{u.textContent=d},l9)},s=async(a,l)=>{try{if(navigator.clipboard===void 0)throw new Error("Clipboard unavailable");await navigator.clipboard.writeText(a),i(l,fe.COPIED)}catch{i(l,a===fe.SIGNOUT_COMMAND?fe.SIGNOUT_COPY_FAILED:`Run ${a} in terminal`)}};return e.addEventListener("click",a=>{var m,h;let l=a.target;if(!(l instanceof Element))return;let u=l.closest(`[${sg}]`);if(u instanceof HTMLElement){a.preventDefault(),a.stopPropagation();let E=(m=u.parentElement)==null?void 0:m.querySelector(`[${cs}]`);if(!(E instanceof HTMLElement))return;let _=!E.hasAttribute("hidden");if(o(),_)return;E.removeAttribute("hidden"),E.setAttribute("aria-hidden","false"),u.setAttribute("aria-expanded","true");return}let d=l.closest("[data-reticle-copy]");if(d instanceof HTMLElement){a.preventDefault(),a.stopPropagation();let E=(h=d.getAttribute("data-reticle-copy"))!=null?h:"";E.length>0&&s(E,d);return}let f=l.closest(`[${qt}]`);if(f instanceof HTMLElement){a.preventDefault(),a.stopPropagation(),t==null||t(),s(fe.SIGNIN_COMMAND,f);return}o()},{signal:r}),document.addEventListener("pointerdown",a=>{let l=a.target;l instanceof Node&&e.contains(l)||o()},{signal:r}),document.addEventListener("keydown",a=>{a.key!=="Escape"||e.querySelector(`[${cs}]:not([hidden])`)===null||(a.stopPropagation(),o())},{signal:r}),()=>n.abort()}var I1,qt,PT,sg,cs,a9,c9,ap,fl,ig,fe,l9,d9,DT,xo=y(()=>{"use strict";M();pl();Hr();ha();zT();I1="data-reticle-account",qt="data-reticle-account-signin",PT="data-reticle-sync-now",sg="data-reticle-account-trigger",cs="data-reticle-account-menu",a9="data-reticle-account-signout",c9="data-reticle-team-open",ap="data-reticle-team-save",fl="data-reticle-team",ig={OPEN:"Open on dashboard \u2197",OPEN_TITLE:"This project's runs, kept for your team on the Reticle dashboard",SAVE_LINK:"Save runs for your team",SAVE_TITLE:`Keep every run, flow and Harness result on a dashboard your team shares. On Reticle, ${v1}.`},fe={SIGNED_OUT:"Sign in",SIGNIN_TITLE:"Sign in through your browser. Also copies `reticle connect`, for a terminal",SIGNIN_COMMAND:"reticle connect",DASHBOARD_TITLE:"Open this project on the dashboard",SYNC_TITLE:"Push to the dashboard now, instead of waiting for the next sync",COPIED:"Copied",AVATAR_FALLBACK:"\u2022",MENU_LABEL:"Reticle account",TRIGGER_TITLE:"Your Reticle account",SIGNED_IN_AS:"Signed in",DASHBOARD_ACTION:"Open dashboard",LINK_HINT:"Not linked \u2014 run `reticle connect` to keep a record on the dashboard",LINK_COMMAND:"reticle connect",SIGNOUT_ACTION:"Copy sign-out command",SIGNOUT_TITLE:"Copy `reticle logout` to run in your terminal",SIGNOUT_COMMAND:"reticle logout",SIGNOUT_COPY_FAILED:"Run reticle logout in terminal",PROJECT_LABEL:"Project",HOST_LABEL:"Host",VERDICTS_LABEL:"Verdicts",DEFECTS_LABEL:"Defects found",PLAN_LABEL:"Plan",CREDITS_LABEL:"Credits",HARNESS_RUNS_LABEL:"Harness runs",MEMORY_LABEL:"Memory",ON_PLATFORM_LABEL:"Runs on dashboard"},l9=1200;d9={[xt.FREE]:"Free",[xt.TRIAL]:"Trial",[xt.PAID]:"Pro"},DT=(e,t,n)=>`${String(e)} ${e===1?t:n}`});var K1={};Ya(K1,{HARNESS_LOCKED_HELP:()=>F1,OutputDetail:()=>Kr,PresenterSettingsPanel:()=>up,SETTINGS_ACCOUNT_ATTR:()=>ZT,SETTINGS_CSS:()=>rg,blockerHtml:()=>qT,creditsLeft:()=>B1,getPresenterSettings:()=>Tr,loadPresenterSettings:()=>KT,paintHarnessRow:()=>G1,paintSdkVersion:()=>YT,paintSettingsAccount:()=>WT,settingsPanelHtml:()=>XT,statusTheme:()=>dp,syncPageBlocker:()=>lg});function dp(e){var t;return(t=jT.find(n=>n.id===e))!=null?t:p9}function Tr(){return Ft}function KT(){if(typeof localStorage=="undefined")return{...br};try{let e=localStorage.getItem(vT);if(e===null)return{...br};let t=JSON.parse(e);if(typeof t!="object"||t===null)return{...br};let n=t;return{outputDetail:f9(n.outputDetail)?n.outputDetail:br.outputDetail,reactComponents:n.reactComponents===!0,hideUntilRestart:!1,statusThemeId:h9(n.statusThemeId)?n.statusThemeId:br.statusThemeId,ambientGlow:typeof n.ambientGlow=="boolean"?n.ambientGlow:br.ambientGlow,clearOnCopy:n.clearOnCopy===!0,blockPageInteractions:typeof n.blockPageInteractions=="boolean"?n.blockPageInteractions:br.blockPageInteractions,showTally:typeof n.showTally=="boolean"?n.showTally:br.showTally,showTimestamps:typeof n.showTimestamps=="boolean"?n.showTimestamps:br.showTimestamps,autoOpenChat:typeof n.autoOpenChat=="boolean"?n.autoOpenChat:br.autoOpenChat,reduceMotion:typeof n.reduceMotion=="boolean"?n.reduceMotion:br.reduceMotion}}catch{return{...br}}}function f9(e){return e===Kr.MINIMAL||e===Kr.STANDARD||e===Kr.VERBOSE}function h9(e){return jT.some(t=>t.id===e)}function m9(e){if(Ft=e,typeof localStorage!="undefined")try{localStorage.setItem(vT,JSON.stringify(e))}catch{}}function g9(e){let t={...Ft,...e};return m9(t),t}function E9(){return Ie(se.HELP,Ae.HELP)}function UT(e,t,n=""){let r=E9(),o=n===""?"":`<span class="reticle-settings-desc">${n}</span>`;return`<span class="reticle-settings-labelcol"><span class="reticle-settings-label">${e}<button type="button" class="reticle-settings-help" data-reticle-settings-help title="${t}" aria-label="${t}">${r}</button></span>${o}</span>`}function ls(e,t,n=""){let[r,o]=ml[e];return`<div class="reticle-settings-row" ${n}>
384
- ${UT(r,t,o)}
385
- <button type="button" class="reticle-settings-toggle" ${sl}="${e}" role="switch" aria-checked="false"></button>
386
- </div>`}function z1(e,t){let[n,r]=ml[e];return`<label class="reticle-settings-checkrow" data-reticle-check-row="${e}">
383
+ `});function D1(e){return lp!=null||(lp=new Set([...z9,...Object.entries(D9).flatMap(([t,n])=>n.map(r=>`${t}.${r}`))])),lp.has(e)}var z9,z1,D9,lp,P1=y(()=>{"use strict";z9=["fab","pause","chat-toggle","markers-btn","end","clear-marks","copy-marks","copy","export","annotate-btn","report-btn","settings-btn","min-btn","chat-min","chat-pill","chat-impact","copy-all-notes","promo-link","replay","carousel-dot","carousel-prev","carousel-next","carousel-close","page-close","team-open","team-save","talk-book","account-signin","account-trigger","account-signout","account-dashboard","sync-now","report-scope","report-close","share-x","share-in","share-copy","refer","settings-close","settings-help","settings-reset","settings-mcp","settings-kill","feedback-email","feedback-call","workspace-btn","workspace-copy","mark-cancel","mark-send","harness-switch","harness-run","harness-stop","harness-open","harness-toggle","harness-link","agent-copy","defects-all","plan-close","plan-journey"],z1=["setting","check","settings-cycle","theme","tour-target","link","annotation-tab","chat-view-btn"],D9={setting:["autoOpenChat","showTimestamps","showTally","reactComponents","hideUntilRestart","harnessEnabled","reduceMotion","ambientGlow"],check:["blockPageInteractions","clearOnCopy"],"settings-cycle":["outputDetail"],theme:["signal","traffic","mono","neon","ember"],"tour-target":["copy","back","done","next","skip"],link:["docs","github","site","discord","defect","dashboard"],"annotation-tab":["current","history"],"chat-view-btn":["activity","flows","annotations","harness"]}});function H9(e){try{let t=new URL(e);return t.protocol!=="https:"?!1:P9.has(t.hostname)?!0:M9===t.hostname&&t.pathname.startsWith(U9)}catch{return!1}}var P9,M9,U9,GT,F9,Tfe,M1=y(()=>{"use strict";ae();P9=new Set(["reticle.sh","www.reticle.sh","app.reticle.sh","docs.reticle.sh"]),M9="github.com",U9="/reticlehq/";GT=b({id:p().regex(/^[a-z0-9-]{1,48}$/),kicker:p().min(1).max(40).optional(),title:p().min(1).max(80),detail:p().min(1).max(120).optional(),cta:b({label:p().min(1).max(24),url:p().refine(H9)}).optional()}),F9=b({signedIn:L().optional(),entitled:L().optional()}),Tfe=GT.extend({audience:F9.optional(),from:p().optional(),until:p().optional(),minSdk:p().optional(),weight:_().optional()})});function cs(e){return e!==void 0&&e.used>=e.limit}function B1(e){let t=`${ha(Math.max(0,e.limit-e.used))} of ${ha(e.limit)}`;return xt.FREE===e.kind?`${t} free credits`:xt.TRIAL===e.kind?`${t} trial credits`:`${t} credits left`}function jT(e){let t=e.kind===void 0?void 0:B9[e.kind],n=Math.max(0,e.limit-e.used),r=e.daysLeft===void 0?"":` \xB7 ${String(e.daysLeft)} day${e.daysLeft===1?"":"s"} left`;return`${t===void 0?"":`${t}: `}${ha(e.used)} of ${ha(e.limit)} credits used \xB7 ${ha(n)} left${r}`}function cg(e){return xt.FREE===e.kind?{said:`Your ${ha(e.limit)} free credits are used.`,action:`Add a card to start your ${String(VT)}-day trial`}:xt.TRIAL===e.kind?{said:`Your ${ha(e.limit)} trial credits are used. Pro starts when your trial ends.`}:{said:"This month's credits are used. They renew over the next 30 days."}}var VT,U1,H1,F1,ha,B9,G1=y(()=>{"use strict";P_();VT=14,U1=500,H1=`Sign up: free credits to try Reticle \xB7 add a card for a ${String(U1)}-credit, ${String(VT)}-day trial`,F1=`a card starts a ${String(VT)}-day trial with ${String(U1)} credits; without one, free sign-up credits`,ha=e=>e.toLocaleString("en-US",{maximumFractionDigits:2});B9={[xt.FREE]:"Free",[xt.TRIAL]:"Trial"}});var ml=y(()=>{"use strict";P1();M1();G1()});function pe(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;")}function _r(e){try{let t=new URL(e).protocol;return t==="https:"||t==="http:"}catch{return!1}}var ma=y(()=>{"use strict"});function up(e,t){let n=document.createElement("template");n.innerHTML=t,V1(e,n.content)}function V1(e,t){let n=[...e.childNodes],r=[...t.childNodes];r.forEach((o,i)=>{let s=n[i];s===void 0?e.appendChild(o):s.nodeType===o.nodeType&&s.nodeName===o.nodeName?G9(s,o):e.replaceChild(o,s)});for(let o of n.slice(r.length))e.removeChild(o)}function G9(e,t){if(!(e instanceof Element)||!(t instanceof Element)){e.nodeValue!==t.nodeValue&&(e.nodeValue=t.nodeValue);return}for(let{name:n}of[...e.attributes])t.hasAttribute(n)||e.removeAttribute(n);for(let{name:n,value:r}of[...t.attributes])e.getAttribute(n)!==r&&e.setAttribute(n,r);V1(e,t)}var KT=y(()=>{"use strict"});function K1(e){let n=(e!=null?e:"").trim().split(/[\s._-]+/).filter(r=>r.length>0).slice(0,2).map(r=>{var o;return(o=[...r][0])!=null?o:""}).join("");return n.length>0?n.toUpperCase():he.AVATAR_FALLBACK}function El(e,t={},n=!1){var a;if(e===void 0)return"";if(!e.signedIn)return n?`<div class="reticle-account" ${j1}><button type="button" class="reticle-account-signin" ${qt} title="${he.SIGNIN_TITLE}" aria-label="${he.SIGNIN_TITLE}">${he.SIGNED_OUT}</button></div>`:"";let r=(a=e.org)!=null?a:"",o=r.length>0?pe(r):he.SIGNED_IN_AS,i=`<span class="reticle-account-avatar" aria-hidden="true">${pe(K1(e.org))}</span>`,s=`<button type="button" class="reticle-account-trigger" ${ug} aria-haspopup="true" aria-expanded="false" title="${he.TRIGGER_TITLE}" aria-label="${he.TRIGGER_TITLE}: ${o}">${i}</button>`;return`<div class="reticle-account" ${j1}>${s}${Z9(e,t)}</div>`}function Ei(e,t){return t===void 0||t.length===0?"":`<div class="reticle-account-row"><span class="reticle-account-k">${pe(e)}</span><span class="reticle-account-v" title="${pe(t)}">${pe(t)}</span></div>`}function Z9(e,t){var l,u;let n=(l=e.org)!=null?l:"",r=`<div class="reticle-account-head"><span class="reticle-account-avatar reticle-account-avatar--lg" aria-hidden="true">${pe(K1(e.org))}</span><span class="reticle-account-who"><span class="reticle-account-org">${n.length>0?pe(n):he.SIGNED_IN_AS}</span>`+(e.email!==void 0&&e.email.length>0?`<span class="reticle-account-email" title="${pe(e.email)}">${pe(e.email)}</span>`:n.length>0?`<span class="reticle-account-email">${he.SIGNED_IN_AS}</span>`:"")+"</span></div>",o=Ei(he.HOST_LABEL,e.host)+Ei(he.PROJECT_LABEL,t.projectName)+Ei(he.VERDICTS_LABEL,t.verdicts!==void 0?String(t.verdicts):void 0)+Ei(he.DEFECTS_LABEL,t.defects!==void 0?String(t.defects):void 0)+Ei(he.ON_PLATFORM_LABEL,t.onPlatform)+Ei(he.PLAN_LABEL,t.plan)+Ei(he.CREDITS_LABEL,t.credits)+Ei(he.HARNESS_RUNS_LABEL,t.harnessRuns)+Ei(he.MEMORY_LABEL,t.memory),s=t.dashboardUrl!==void 0&&_r(t.dashboardUrl)?`<a class="reticle-account-action" data-reticle-account-dashboard href="${pe((u=t.dashboardUrl)!=null?u:"")}" target="_blank" rel="noreferrer noopener" title="${he.DASHBOARD_TITLE}">${Ce(se.VIEW,ye.HELP)}<span>${he.DASHBOARD_ACTION}</span></a>`:`<button type="button" class="reticle-account-action reticle-account-action--hint" ${qt} data-reticle-copy="${he.LINK_COMMAND}" title="${he.LINK_HINT}"><span>${he.LINK_HINT}</span></button>`,a=`<button type="button" class="reticle-account-action" ${V9} data-reticle-copy="${he.SIGNOUT_COMMAND}" title="${he.SIGNOUT_TITLE}"><span>${he.SIGNOUT_ACTION}</span></button>`;return`<div class="reticle-account-menu" ${ls} role="menu" aria-label="${he.MENU_LABEL}" aria-hidden="true" hidden>`+r+(o.length>0?`<div class="reticle-account-rows">${o}</div>`:"")+`<div class="reticle-account-actions">${s}${a}</div></div>`}function Z1(e,t){let n=e==null?void 0:e.plan,r=t==null?void 0:t.onPlatform;return{...n===void 0?{}:{plan:[W9[n.kind],n.daysLeft===void 0?"":`${ZT(n.daysLeft,"day","days")} left`,n.seats===void 0?"":ZT(n.seats,"seat","seats")].filter(o=>o.length>0).join(" \xB7 ")},...(e==null?void 0:e.credits)===void 0?{}:{credits:`${Math.max(0,e.credits.limit-e.credits.used).toLocaleString("en-US")} of ${e.credits.limit.toLocaleString("en-US")} left`},...(e==null?void 0:e.harnessRuns)===void 0?{}:{harnessRuns:String(e.harnessRuns)},...(e==null?void 0:e.memoryEntries)===void 0?{}:{memory:ZT(e.memoryEntries,"entry","entries")},...typeof r=="number"?{onPlatform:String(r)}:{}}}function W1(e,t){return e===void 0||!e.signedIn?"":t!==void 0&&_r(t)?`<a ${j9} class="reticle-team-link" href="${pe(t)}" target="_blank" rel="noreferrer noopener" title="${pe(lg.OPEN_TITLE)}">${lg.OPEN}</a>`:`<button type="button" ${dp} class="reticle-team-link" title="${pe(lg.SAVE_TITLE)}"><span>${lg.SAVE_LINK}</span></button>`}function pp(e,t){var o;let n=e.querySelector(`[${ls}]:not([hidden])`)!==null;if(up(e,t),!n)return;let r=e.querySelector(`[${ls}]`);r!==null&&(r.removeAttribute("hidden"),r.setAttribute("aria-hidden","false"),(o=e.querySelector(`[${ug}]`))==null||o.setAttribute("aria-expanded","true"))}function YT(e){return e===void 0||!_r(e)?"":`<button type="button" class="reticle-sync-now" ${WT} title="${he.SYNC_TITLE}" aria-label="${he.SYNC_TITLE}">${Ce(se.SYNC,ye.HELP)}</button>`}function Y1(e,t){let n=new AbortController,{signal:r}=n,o=a=>{for(let l of e.querySelectorAll(`[${ls}]`))l!==a&&(l.setAttribute("hidden",""),l.setAttribute("aria-hidden","true"));for(let l of e.querySelectorAll(`[${ug}]`))a!==void 0&&l.parentElement===a.parentElement||l.setAttribute("aria-expanded","false")},i=(a,l)=>{var f;let u=(f=a.querySelector("span"))!=null?f:a,d=u.textContent;u.textContent=l,setTimeout(()=>{u.textContent=d},K9)},s=async(a,l)=>{try{if(navigator.clipboard===void 0)throw new Error("Clipboard unavailable");await navigator.clipboard.writeText(a),i(l,he.COPIED)}catch{i(l,a===he.SIGNOUT_COMMAND?he.SIGNOUT_COPY_FAILED:`Run ${a} in terminal`)}};return e.addEventListener("click",a=>{var m,h;let l=a.target;if(!(l instanceof Element))return;let u=l.closest(`[${ug}]`);if(u instanceof HTMLElement){a.preventDefault(),a.stopPropagation();let E=(m=u.parentElement)==null?void 0:m.querySelector(`[${ls}]`);if(!(E instanceof HTMLElement))return;let S=!E.hasAttribute("hidden");if(o(),S)return;E.removeAttribute("hidden"),E.setAttribute("aria-hidden","false"),u.setAttribute("aria-expanded","true");return}let d=l.closest("[data-reticle-copy]");if(d instanceof HTMLElement){a.preventDefault(),a.stopPropagation();let E=(h=d.getAttribute("data-reticle-copy"))!=null?h:"";E.length>0&&s(E,d);return}let f=l.closest(`[${qt}]`);if(f instanceof HTMLElement){a.preventDefault(),a.stopPropagation(),t==null||t(),s(he.SIGNIN_COMMAND,f);return}o()},{signal:r}),document.addEventListener("pointerdown",a=>{let l=a.target;l instanceof Node&&e.contains(l)||o()},{signal:r}),document.addEventListener("keydown",a=>{a.key!=="Escape"||e.querySelector(`[${ls}]:not([hidden])`)===null||(a.stopPropagation(),o())},{signal:r}),()=>n.abort()}var j1,qt,WT,ug,ls,V9,j9,dp,gl,lg,he,K9,W9,ZT,yo=y(()=>{"use strict";M();ml();Gr();ma();KT();j1="data-reticle-account",qt="data-reticle-account-signin",WT="data-reticle-sync-now",ug="data-reticle-account-trigger",ls="data-reticle-account-menu",V9="data-reticle-account-signout",j9="data-reticle-team-open",dp="data-reticle-team-save",gl="data-reticle-team",lg={OPEN:"Open on dashboard \u2197",OPEN_TITLE:"This project's runs, kept for your team on the Reticle dashboard",SAVE_LINK:"Save runs for your team",SAVE_TITLE:`Keep every run, flow and Harness result on a dashboard your team shares. On Reticle, ${F1}.`},he={SIGNED_OUT:"Sign in",SIGNIN_TITLE:"Sign in through your browser. Also copies `reticle connect`, for a terminal",SIGNIN_COMMAND:"reticle connect",DASHBOARD_TITLE:"Open this project on the dashboard",SYNC_TITLE:"Push to the dashboard now, instead of waiting for the next sync",COPIED:"Copied",AVATAR_FALLBACK:"\u2022",MENU_LABEL:"Reticle account",TRIGGER_TITLE:"Your Reticle account",SIGNED_IN_AS:"Signed in",DASHBOARD_ACTION:"Open dashboard",LINK_HINT:"Not linked \u2014 run `reticle connect` to keep a record on the dashboard",LINK_COMMAND:"reticle connect",SIGNOUT_ACTION:"Copy sign-out command",SIGNOUT_TITLE:"Copy `reticle logout` to run in your terminal",SIGNOUT_COMMAND:"reticle logout",SIGNOUT_COPY_FAILED:"Run reticle logout in terminal",PROJECT_LABEL:"Project",HOST_LABEL:"Host",VERDICTS_LABEL:"Verdicts",DEFECTS_LABEL:"Defects found",PLAN_LABEL:"Plan",CREDITS_LABEL:"Credits",HARNESS_RUNS_LABEL:"Harness runs",MEMORY_LABEL:"Memory",ON_PLATFORM_LABEL:"Runs on dashboard"},K9=1200;W9={[xt.FREE]:"Free",[xt.TRIAL]:"Trial",[xt.PAID]:"Pro"},ZT=(e,t,n)=>`${String(e)} ${e===1?t:n}`});var aP={};qa(aP,{HARNESS_LOCKED_HELP:()=>nP,OutputDetail:()=>Yr,PresenterSettingsPanel:()=>hp,SETTINGS_ACCOUNT_ATTR:()=>ox,SETTINGS_CSS:()=>ag,blockerHtml:()=>cx,creditsLeft:()=>rP,getPresenterSettings:()=>Ar,loadPresenterSettings:()=>rx,paintHarnessRow:()=>oP,paintSdkVersion:()=>sx,paintSettingsAccount:()=>ix,settingsPanelHtml:()=>ax,statusTheme:()=>mp,syncPageBlocker:()=>fg});function mp(e){var t;return(t=nx.find(n=>n.id===e))!=null?t:Y9}function Ar(){return Bt}function rx(){if(typeof localStorage=="undefined")return{...Sr};try{let e=localStorage.getItem(PT);if(e===null)return{...Sr};let t=JSON.parse(e);if(typeof t!="object"||t===null)return{...Sr};let n=t;return{outputDetail:X9(n.outputDetail)?n.outputDetail:Sr.outputDetail,reactComponents:n.reactComponents===!0,hideUntilRestart:!1,statusThemeId:q9(n.statusThemeId)?n.statusThemeId:Sr.statusThemeId,ambientGlow:typeof n.ambientGlow=="boolean"?n.ambientGlow:Sr.ambientGlow,clearOnCopy:n.clearOnCopy===!0,blockPageInteractions:typeof n.blockPageInteractions=="boolean"?n.blockPageInteractions:Sr.blockPageInteractions,showTally:typeof n.showTally=="boolean"?n.showTally:Sr.showTally,showTimestamps:typeof n.showTimestamps=="boolean"?n.showTimestamps:Sr.showTimestamps,autoOpenChat:typeof n.autoOpenChat=="boolean"?n.autoOpenChat:Sr.autoOpenChat,reduceMotion:typeof n.reduceMotion=="boolean"?n.reduceMotion:Sr.reduceMotion}}catch{return{...Sr}}}function X9(e){return e===Yr.MINIMAL||e===Yr.STANDARD||e===Yr.VERBOSE}function q9(e){return nx.some(t=>t.id===e)}function J9(e){if(Bt=e,typeof localStorage!="undefined")try{localStorage.setItem(PT,JSON.stringify(e))}catch{}}function Q9(e){let t={...Bt,...e};return J9(t),t}function eW(){return Ce(se.HELP,ye.HELP)}function XT(e,t,n=""){let r=eW(),o=n===""?"":`<span class="reticle-settings-desc">${n}</span>`;return`<span class="reticle-settings-labelcol"><span class="reticle-settings-label">${e}<button type="button" class="reticle-settings-help" data-reticle-settings-help title="${t}" aria-label="${t}">${r}</button></span>${o}</span>`}function us(e,t,n=""){let[r,o]=bl[e];return`<div class="reticle-settings-row" ${n}>
384
+ ${XT(r,t,o)}
385
+ <button type="button" class="reticle-settings-toggle" ${ll}="${e}" role="switch" aria-checked="false"></button>
386
+ </div>`}function X1(e,t){let[n,r]=bl[e];return`<label class="reticle-settings-checkrow" data-reticle-check-row="${e}">
387
387
  <span class="reticle-settings-check" data-reticle-check="${e}" role="checkbox" aria-checked="${t?"true":"false"}" tabindex="0"></span>
388
388
  <span class="reticle-settings-labelcol"><span class="reticle-settings-check-label">${n}</span><span class="reticle-settings-desc">${r}</span></span>
389
- </label>`}function B1(e){return e===void 0?"":as(e)?og(e).said:N1(e)}function G1(e,t){let n=e.querySelector(`[${U1}]`);if(!(n instanceof HTMLElement))return;if(t===void 0){n.hidden=!0;return}n.hidden=!1;let r=n.querySelector(`[${sl}="harnessEnabled"]`);if(!(r instanceof HTMLElement))return;let o=t.harnessEntitled;r.setAttribute("aria-checked",t.harnessEnabled&&o?"true":"false"),r.setAttribute("aria-disabled",o?"false":"true");let i=n.querySelector("[data-reticle-settings-help]"),s=B1(t.credits);i instanceof HTMLElement&&(i.title=o?[H1,s].filter(a=>0<a.length).join(" "):as(t.credits)?s:F1)}function WT(e,t,n,r={}){let o=e.querySelector(`[${M1}]`),i=e.querySelector(`[${ZT}]`);if(!(o instanceof HTMLElement)||!(i instanceof HTMLElement))return;let s=hl(t,{...r,dashboardUrl:n},!0);o.hidden=s.length===0,cp(i,s)}function YT(e,t){let n=e.querySelector(`[${V1}]`);n!==null&&(n.textContent=t===void 0?FT.UNKNOWN:FT.KNOWN(t))}function XT(){let e=Ie(se.REMOVE,Ae.MIN),t=Ie(se.CARET_RIGHT,Ae.HELP),n="How much detail is included when you copy or export the run",r="Include React component paths in exported run state when available",o="Hide the Reticle HUD until you reload the page",i=H1;return`<div ${P} class="reticle-settings ${Xn}" role="region" aria-label="Reticle settings" aria-hidden="true">
389
+ </label>`}function rP(e){return e===void 0?"":cs(e)?cg(e).said:B1(e)}function oP(e,t){let n=e.querySelector(`[${eP}]`);if(!(n instanceof HTMLElement))return;if(t===void 0){n.hidden=!0;return}n.hidden=!1;let r=n.querySelector(`[${ll}="harnessEnabled"]`);if(!(r instanceof HTMLElement))return;let o=t.harnessEntitled;r.setAttribute("aria-checked",t.harnessEnabled&&o?"true":"false"),r.setAttribute("aria-disabled",o?"false":"true");let i=n.querySelector("[data-reticle-settings-help]"),s=rP(t.credits);i instanceof HTMLElement&&(i.title=o?[tP,s].filter(a=>0<a.length).join(" "):cs(t.credits)?s:nP)}function ix(e,t,n,r={}){let o=e.querySelector(`[${Q1}]`),i=e.querySelector(`[${ox}]`);if(!(o instanceof HTMLElement)||!(i instanceof HTMLElement))return;let s=El(t,{...r,dashboardUrl:n},!0);o.hidden=s.length===0,pp(i,s)}function sx(e,t){let n=e.querySelector(`[${iP}]`);n!==null&&(n.textContent=t===void 0?JT.UNKNOWN:JT.KNOWN(t))}function ax(){let e=Ce(se.REMOVE,ye.MIN),t=Ce(se.CARET_RIGHT,ye.HELP),n="How much detail is included when you copy or export the run",r="Include React component paths in exported run state when available",o="Hide the Reticle HUD until you reload the page",i=tP;return`<div ${P} class="reticle-settings ${Xn}" role="region" aria-label="Reticle settings" aria-hidden="true">
390
390
  <div class="reticle-settings-inner">
391
391
  <div class="reticle-settings-head">
392
392
  <span class="reticle-settings-title">Settings</span>
393
- <button type="button" ${wT} class="reticle-settings-close" title="Close settings" aria-label="Close settings">${e}</button>
393
+ <button type="button" ${DT} class="reticle-settings-close" title="Close settings" aria-label="Close settings">${e}</button>
394
394
  </div>
395
395
  <div class="reticle-settings-body">
396
396
  <div class="reticle-settings-section">Session</div>
397
397
  <div class="reticle-settings-row">
398
- ${UT(ml.outputDetail[0],n,ml.outputDetail[1])}
398
+ ${XT(bl.outputDetail[0],n,bl.outputDetail[1])}
399
399
  <button type="button" class="reticle-settings-cycle" data-reticle-settings-cycle="outputDetail"><span data-reticle-cycle-label></span><span class="reticle-settings-dots" data-reticle-cycle-dots></span></button>
400
400
  </div>
401
- ${ls("autoOpenChat","On by default. Opens the agent chat by itself when a session starts and when you expand the HUD. Off leaves the toolbar bare until you ask for the chat.")}
402
- ${ls("showTimestamps","Show relative timestamps on each activity-log row")}
403
- ${ls("showTally","Show the pass/fail score pill in the toolbar")}
401
+ ${us("autoOpenChat","On by default. Opens the agent chat by itself when a session starts and when you expand the HUD. Off leaves the toolbar bare until you ask for the chat.")}
402
+ ${us("showTimestamps","Show relative timestamps on each activity-log row")}
403
+ ${us("showTally","Show the pass/fail score pill in the toolbar")}
404
404
  <div class="reticle-settings-section">Inspector</div>
405
- ${ls("reactComponents",r,"data-reticle-settings-react-row")}
405
+ ${us("reactComponents",r,"data-reticle-settings-react-row")}
406
406
  <div class="reticle-settings-section">Interaction</div>
407
- ${z1("blockPageInteractions",!0)}
408
- ${z1("clearOnCopy",!1)}
409
- ${ls("hideUntilRestart",o)}
410
- ${ls("harnessEnabled",i,`${U1} hidden`)}
411
- ${ls("reduceMotion","Reduce HUD animations for accessibility")}
407
+ ${X1("blockPageInteractions",!0)}
408
+ ${X1("clearOnCopy",!1)}
409
+ ${us("hideUntilRestart",o)}
410
+ ${us("harnessEnabled",i,`${eP} hidden`)}
411
+ ${us("reduceMotion","Reduce HUD animations for accessibility")}
412
412
  <div class="reticle-settings-section">Account</div>
413
- <div class="reticle-settings-row" ${M1} hidden>
414
- ${UT(ml.workspace[0],b9,ml.workspace[1])}
415
- <span ${ZT}></span>
413
+ <div class="reticle-settings-row" ${Q1} hidden>
414
+ ${XT(bl.workspace[0],tW,bl.workspace[1])}
415
+ <span ${ox}></span>
416
416
  </div>
417
417
  <div class="reticle-settings-section">Status theme</div>
418
- ${ls("ambientGlow","Glow the page edges in the status colour while a session is live. Off keeps the HUD signals and leaves your app alone.")}
418
+ ${us("ambientGlow","Glow the page edges in the status colour while a session is live. Off keeps the HUD signals and leaves your app alone.")}
419
419
  <div class="reticle-settings-themes" data-reticle-settings-themes></div>
420
420
  <div class="reticle-settings-section">Help</div>
421
421
  <div class="reticle-settings-foot">
422
422
  <button type="button" class="reticle-settings-reset" data-reticle-settings-reset>Reset HUD position</button>
423
423
  <button type="button" class="reticle-settings-link" data-reticle-settings-mcp>MCP setup guide<span class="reticle-settings-link-caret" aria-hidden="true">${t}</span></button>
424
- <a class="reticle-settings-link" data-reticle-feedback-email href="${KO}" target="_blank" rel="noopener noreferrer" title="${ag.EMAIL_TITLE}">${ag.EMAIL}<span class="reticle-settings-link-caret" aria-hidden="true">${t}</span></a>
425
- <a class="reticle-settings-link" data-reticle-feedback-call href="${eh}" target="_blank" rel="noopener noreferrer" title="${ag.CALL_TITLE}">${ag.CALL}<span class="reticle-settings-link-caret" aria-hidden="true">${t}</span></a>
426
- <p class="reticle-settings-kill-sub" ${V1}>${FT.UNKNOWN}</p>
424
+ <a class="reticle-settings-link" data-reticle-feedback-email href="${oI}" target="_blank" rel="noopener noreferrer" title="${dg.EMAIL_TITLE}">${dg.EMAIL}<span class="reticle-settings-link-caret" aria-hidden="true">${t}</span></a>
425
+ <a class="reticle-settings-link" data-reticle-feedback-call href="${ih}" target="_blank" rel="noopener noreferrer" title="${dg.CALL_TITLE}">${dg.CALL}<span class="reticle-settings-link-caret" aria-hidden="true">${t}</span></a>
426
+ <p class="reticle-settings-kill-sub" ${iP}>${JT.UNKNOWN}</p>
427
427
  <div class="reticle-settings-kill-row">
428
- <button type="button" class="reticle-settings-kill" ${HT}><span data-reticle-kill-label>${cg.LABEL}</span></button>
429
- <p class="reticle-settings-kill-sub">${cg.WARNING}</p>
428
+ <button type="button" class="reticle-settings-kill" ${qT}><span data-reticle-kill-label>${pg.LABEL}</span></button>
429
+ <p class="reticle-settings-kill-sub">${pg.WARNING}</p>
430
430
  </div>
431
431
  </div>
432
432
  </div>
433
433
  </div>
434
- </div>`}function P1(e,t){let n=dp(t.statusThemeId);e.style.setProperty("--reticle-mark-accent",n.active),e.style.setProperty("--reticle-accent",n.active),e.style.setProperty("--reticle-c-active",n.active),e.style.setProperty("--reticle-c-idle",n.idle),e.style.setProperty("--reticle-c-ended",n.ended),e.setAttribute(QD,t.ambientGlow?"1":"0"),t.hideUntilRestart?e.setAttribute(al,"1"):e.removeAttribute(al),e.setAttribute(Wm,t.showTimestamps?"1":"0"),e.setAttribute(To,t.reduceMotion?"1":"0");let r=e.querySelector("[data-reticle-tally]");r instanceof HTMLElement&&!t.showTally&&r.setAttribute("hidden","")}function lg(e,t,n){e.setAttribute(e1,t.blockPageInteractions&&n?"1":"0")}function qT(){return'<div data-reticle-blocker aria-hidden="true"></div>'}var Kr,ma,jT,p9,lp,br,Ft,ml,ZT,M1,D1,U1,H1,F1,b9,ag,HT,cg,V1,FT,bn,Bt,Sr,Ao,Ce,BT,_r,GT,us,VT,j1,up,gl=y(()=>{"use strict";Ct();Hr();Vr();IT();op();CT();pl();M();xo();Kr={MINIMAL:"minimal",STANDARD:"standard",VERBOSE:"verbose"},ma={SIGNAL:"signal",TRAFFIC:"traffic",MONO:"mono",NEON:"neon",EMBER:"ember"},jT=[{id:ma.SIGNAL,label:"Signal",active:"#3b82f6",idle:"#eab308",ended:"#ef4444"},{id:ma.TRAFFIC,label:"Traffic",active:"#22c55e",idle:"#eab308",ended:"#ef4444"},{id:ma.MONO,label:"Mono",active:"#fafafa",idle:"#a3a3a3",ended:"#525252"},{id:ma.NEON,label:"Neon",active:"#06b6d4",idle:"#a855f7",ended:"#f43f5e"},{id:ma.EMBER,label:"Ember",active:"#f97316",idle:"#facc15",ended:"#7f1d1d"}],p9={id:ma.SIGNAL,label:"Signal",active:"#3b82f6",idle:"#eab308",ended:"#ef4444"};lp=[{value:Kr.MINIMAL,label:"Minimal"},{value:Kr.STANDARD,label:"Standard"},{value:Kr.VERBOSE,label:"Verbose"}],br={outputDetail:Kr.STANDARD,statusThemeId:ma.SIGNAL,ambientGlow:!0,reactComponents:!1,hideUntilRestart:!1,clearOnCopy:!1,blockPageInteractions:!0,showTally:!1,showTimestamps:!0,autoOpenChat:!0,reduceMotion:!1},Ft=KT();ml={outputDetail:["Output detail","How much a copied run includes."],autoOpenChat:["Open the log automatically","Opens this panel when an agent starts to act in this tab."],showTimestamps:["Show timestamps","Shows how long ago each log row happened."],showTally:["Show pass/fail count","A score pill for this session in the toolbar."],reactComponents:["React component names","Adds component names to copied runs."],blockPageInteractions:["Block page while adding notes","Clicks pin a note instead of using the app."],clearOnCopy:["Clear notes after copying","Starts fresh once your notes are copied."],hideUntilRestart:["Hide until reload","Hides the HUD until this page reloads."],harnessEnabled:["Allow Reticle to drive","Off by default. Lets Run Harness test this project."],reduceMotion:["Reduce motion","Fewer HUD animations."],ambientGlow:["Page glow","Tints the page edges while a session runs."],workspace:["Workspace","The Reticle account this machine is signed in to."]};ZT="data-reticle-settings-account",M1="data-reticle-settings-account-row",D1="data-reticle-settings-helptext",U1="data-reticle-settings-harness-row",H1="Let Reticle test this app by itself to find defects, from Run Harness or from your coding agent. Off blocks every run. Set here or in your dashboard \u2014 both write to the same place.",F1="The Harness is not available to this workspace right now: see Plan in your Reticle dashboard.";b9=`Whether this machine is signed in to a Reticle workspace. Press ${fe.SIGNED_OUT} to sign in through your browser.`;ag={EMAIL:"Email the founder",EMAIL_TITLE:`Write to ${jO}: a problem, a wish, anything`,CALL:"Book a call",CALL_TITLE:"Pick a time to talk it through"},HT="data-reticle-settings-kill",cg={LABEL:"Kill Reticle",ARMED:"Click again to kill Reticle",WARNING:"Disconnects Reticle from this page: no HUD, no agent, nothing recorded. To bring it back, restart your dev server or reload the page."},V1="data-reticle-sdk-version",FT={UNKNOWN:"Reticle SDK version unknown",KNOWN:e=>`Reticle SDK ${e}`};up=class{constructor(t={}){x(this,Ce);x(this,bn);x(this,Bt);x(this,Sr);x(this,Ao);g(this,Ao,t),Ft=KT()}contains(t){var n;return((n=c(this,Bt))==null?void 0:n.contains(t))===!0}mount(t){var i,s,a,l,u,d,f;g(this,bn,t);let n=t.querySelector(`[${P}]`);g(this,Bt,n instanceof HTMLElement?n:void 0),(i=c(this,Bt))==null||i.addEventListener("pointerdown",m=>{m.stopPropagation()});let r=t.querySelector(`[${Jd}]`);g(this,Sr,r instanceof HTMLElement?r:void 0);let o=t.querySelector(`[${wT}]`);if(o instanceof HTMLElement&&ET(o,se.REMOVE,Ae.MIN),c(this,Sr)!==void 0){let m=c(this,Sr).querySelector(".reticle-nav-label");ET(c(this,Sr),se.GEAR,Ae.TOOLBAR),m!==null&&c(this,Sr).append(m),c(this,Sr).addEventListener("click",h=>{h.stopPropagation(),this.open()})}(s=t.querySelector('[data-reticle-settings-cycle="outputDetail"]'))==null||s.addEventListener("click",m=>{m.stopPropagation();let h=lp.findIndex(_=>_.value===Ft.outputDetail),E=lp[(h+1)%lp.length];E!==void 0&&T(this,Ce,_r).call(this,{outputDetail:E.value})});for(let m of t.querySelectorAll(".reticle-settings-help"))m.setAttribute("aria-expanded","false"),m.addEventListener("click",h=>{var v;h.stopPropagation();let E=m.closest(".reticle-settings-row");if(E===null)return;let _=E.querySelector(`[${D1}]`);if(_!==null){_.remove(),m.setAttribute("aria-expanded","false");return}let A=document.createElement("p");A.className="reticle-settings-helptext",A.setAttribute(D1,""),A.textContent=(v=m.getAttribute("title"))!=null?v:"",E.appendChild(A),m.setAttribute("aria-expanded","true")});for(let m of t.querySelectorAll(`[${sl}]`)){let h=()=>{var _,A,v,N;if(!(m instanceof HTMLElement))return;let E=m.getAttribute(sl);if(E==="harnessEnabled"){if(m.getAttribute("aria-disabled")==="true")return;let O=m.getAttribute("aria-checked")!=="true";m.setAttribute("aria-checked",O?"true":"false"),(A=(_=c(this,Ao)).onHarness)==null||A.call(_,O)}else if(E==="reactComponents")T(this,Ce,_r).call(this,{reactComponents:!Ft.reactComponents});else if(E==="hideUntilRestart"){let O=!Ft.hideUntilRestart;T(this,Ce,_r).call(this,{hideUntilRestart:O}),O&&((N=(v=c(this,Ao)).onHideUntilRestart)==null||N.call(v))}else E==="showTally"?T(this,Ce,_r).call(this,{showTally:!Ft.showTally}):E==="autoOpenChat"?T(this,Ce,_r).call(this,{autoOpenChat:!Ft.autoOpenChat}):E==="showTimestamps"?T(this,Ce,_r).call(this,{showTimestamps:!Ft.showTimestamps}):E==="reduceMotion"?T(this,Ce,_r).call(this,{reduceMotion:!Ft.reduceMotion}):E==="ambientGlow"&&T(this,Ce,_r).call(this,{ambientGlow:!Ft.ambientGlow})};m.addEventListener("click",E=>{E.stopPropagation(),h()}),m.addEventListener("keydown",E=>{E instanceof KeyboardEvent&&(E.key===" "||E.key==="Enter")&&(E.preventDefault(),E.stopPropagation(),h())})}for(let m of t.querySelectorAll("[data-reticle-check]")){let h=()=>{if(!(m instanceof HTMLElement))return;let _=m.getAttribute("data-reticle-check");_==="clearOnCopy"?T(this,Ce,_r).call(this,{clearOnCopy:!Ft.clearOnCopy}):_==="blockPageInteractions"&&T(this,Ce,_r).call(this,{blockPageInteractions:!Ft.blockPageInteractions})},E=m.closest("[data-reticle-check-row]");E==null||E.addEventListener("click",_=>{_.stopPropagation(),!(_.target instanceof HTMLElement&&_.target.classList.contains("reticle-settings-help"))&&h()}),m.addEventListener("keydown",_=>{_ instanceof KeyboardEvent&&(_.key===" "||_.key==="Enter")&&(_.preventDefault(),h())})}(a=t.querySelector("[data-reticle-settings-mcp]"))==null||a.addEventListener("click",m=>{m.stopPropagation(),window.open(t1,"_blank","noopener,noreferrer")}),(l=t.querySelector("[data-reticle-settings-reset]"))==null||l.addEventListener("click",m=>{m.stopPropagation();let h=t.querySelector(`[${F}]`);h instanceof HTMLElement&&tp(h)}),(u=t.querySelector(`[${HT}]`))==null||u.addEventListener("click",m=>{var _,A;m.stopPropagation();let h=m.currentTarget;if(!(h instanceof HTMLElement))return;if(h.getAttribute("data-armed")==="1"){(A=(_=c(this,Ao)).onKill)==null||A.call(_);return}h.setAttribute("data-armed","1");let E=h.querySelector("[data-reticle-kill-label]");E!==null&&(E.textContent=cg.ARMED)}),o==null||o.addEventListener("click",m=>{m.stopPropagation(),this.close()}),T(this,Ce,j1).call(this),T(this,Ce,GT).call(this),P1(t,Ft),(f=(d=c(this,Ao)).onSettingsChange)==null||f.call(d,Ft)}paintHarness(t){let n=c(this,Bt);n!==void 0&&G1(n,t)}teardown(){g(this,bn,void 0),g(this,Bt,void 0),g(this,Sr,void 0)}isOpen(){var t;return((t=c(this,bn))==null?void 0:t.getAttribute(ft))==="1"}open(){var t,n,r,o;c(this,bn)!==void 0&&((n=(t=c(this,Ao)).onBeforeOpen)==null||n.call(t),c(this,bn).setAttribute(ft,"1"),(r=c(this,Bt))==null||r.setAttribute("aria-hidden","false"),(o=c(this,Sr))==null||o.setAttribute("data-active","1"),T(this,Ce,BT).call(this))}close(){var n,r,o;if(c(this,bn)===void 0)return;let t=(n=c(this,Bt))==null?void 0:n.querySelector(`[${HT}]`);if(t instanceof HTMLElement){t.removeAttribute("data-armed");let i=t.querySelector("[data-reticle-kill-label]");i!==null&&(i.textContent=cg.LABEL)}c(this,bn).setAttribute(ft,"0"),(r=c(this,Bt))==null||r.setAttribute("aria-hidden","true"),(o=c(this,Sr))==null||o.setAttribute("data-active","0"),T(this,Ce,BT).call(this)}toggle(){this.isOpen()?this.close():this.open()}};bn=new WeakMap,Bt=new WeakMap,Sr=new WeakMap,Ao=new WeakMap,Ce=new WeakSet,BT=function(){if(c(this,bn)===void 0)return;let t=g1(c(this,bn));t!==void 0&&jr(t,c(this,bn))},_r=function(t){var r,o;let n=g9(t);c(this,bn)!==void 0&&P1(c(this,bn),n),T(this,Ce,GT).call(this),(o=(r=c(this,Ao)).onSettingsChange)==null||o.call(r,n)},GT=function(){var o,i,s,a,l,u;let t=Ft,n=(o=c(this,Bt))==null?void 0:o.querySelector("[data-reticle-cycle-label]");n!=null&&(n.textContent=(s=(i=lp.find(d=>d.value===t.outputDetail))==null?void 0:i.label)!=null?s:"Standard");let r=(a=c(this,Bt))==null?void 0:a.querySelector("[data-reticle-cycle-dots]");r!=null&&r.replaceChildren(...lp.map(d=>{let f=document.createElement("span");return f.className="reticle-settings-dot",f.setAttribute("data-on",d.value===t.outputDetail?"1":"0"),f})),T(this,Ce,us).call(this,"reactComponents",t.reactComponents),T(this,Ce,us).call(this,"hideUntilRestart",t.hideUntilRestart),T(this,Ce,us).call(this,"showTally",t.showTally),T(this,Ce,us).call(this,"autoOpenChat",t.autoOpenChat),T(this,Ce,us).call(this,"showTimestamps",t.showTimestamps),T(this,Ce,us).call(this,"reduceMotion",t.reduceMotion),T(this,Ce,us).call(this,"ambientGlow",t.ambientGlow),T(this,Ce,VT).call(this,"clearOnCopy",t.clearOnCopy),T(this,Ce,VT).call(this,"blockPageInteractions",t.blockPageInteractions);for(let d of(u=(l=c(this,Bt))==null?void 0:l.querySelectorAll("[data-reticle-theme]"))!=null?u:[])d instanceof HTMLElement&&d.setAttribute("data-on",d.getAttribute("data-reticle-theme")===t.statusThemeId?"1":"0")},us=function(t,n){var o;let r=(o=c(this,Bt))==null?void 0:o.querySelector(`[${sl}="${t}"]`);r instanceof HTMLElement&&(r.setAttribute("data-on",n?"1":"0"),r.setAttribute("aria-checked",n?"true":"false"))},VT=function(t,n){var o;let r=(o=c(this,Bt))==null?void 0:o.querySelector(`[data-reticle-check="${t}"]`);r instanceof HTMLElement&&(r.setAttribute("data-on",n?"1":"0"),r.setAttribute("aria-checked",n?"true":"false"),r.textContent=n?"\u2713":"")},j1=function(){var n;let t=(n=c(this,Bt))==null?void 0:n.querySelector("[data-reticle-settings-themes]");t!=null&&t.replaceChildren(...jT.map(r=>{let o=document.createElement("button");o.type="button",o.className="reticle-settings-theme",o.setAttribute("data-reticle-theme",r.id),o.title=r.label,o.setAttribute("aria-label",`${r.label} status theme`);for(let s of[r.active,r.idle,r.ended]){let a=document.createElement("span");a.className="reticle-settings-theme-band",a.style.background=s,o.appendChild(a)}let i=document.createElement("span");return i.className="reticle-settings-theme-name",i.textContent=r.label,o.appendChild(i),o.addEventListener("click",s=>{s.stopPropagation(),T(this,Ce,_r).call(this,{statusThemeId:r.id})}),o}))}});function y9(){let e=globalThis[qf];return typeof e=="string"&&e.length>0?e:void 0}function w9(e){let n=e.replace(/\\/g,"/").replace(/\/+$/,"").split("/").filter(o=>o.length>0),r=n[n.length-1];return r!==void 0&&r.length>0?r:tx}function v9(){if(typeof window=="undefined")return;let e=new URLSearchParams(window.location.search).get(rr.PROJECT);return e!==null&&e.length>0?e:void 0}function Q1(){let e=y9(),t=v9(),n=e!==void 0?w9(e):tx;if(e===void 0&&t===void 0)return{folder:n};let r={folder:n};return e!==void 0&&(r.root=e),t!==void 0&&(r.projectId=t),r}function eP(){let e=Ie(se.LAYOUT,Ae.HELP),t=Ie(se.CARET_DOWN,Ae.HELP),n=Ie(se.COPY,Ae.HELP);return`<div class="reticle-workspace-wrap">
435
- <button type="button" class="reticle-workspace" ${ug} aria-haspopup="true" aria-expanded="false" title="${T9}">
434
+ </div>`}function J1(e,t){let n=mp(t.statusThemeId);e.style.setProperty("--reticle-mark-accent",n.active),e.style.setProperty("--reticle-accent",n.active),e.style.setProperty("--reticle-c-active",n.active),e.style.setProperty("--reticle-c-idle",n.idle),e.style.setProperty("--reticle-c-ended",n.ended),e.setAttribute(h1,t.ambientGlow?"1":"0"),t.hideUntilRestart?e.setAttribute(ul,"1"):e.removeAttribute(ul),e.setAttribute(Jm,t.showTimestamps?"1":"0"),e.setAttribute(Ao,t.reduceMotion?"1":"0");let r=e.querySelector("[data-reticle-tally]");r instanceof HTMLElement&&!t.showTally&&r.setAttribute("hidden","")}function fg(e,t,n){e.setAttribute(m1,t.blockPageInteractions&&n?"1":"0")}function cx(){return'<div data-reticle-blocker aria-hidden="true"></div>'}var Yr,ga,nx,Y9,fp,Sr,Bt,bl,ox,Q1,q1,eP,tP,nP,tW,dg,qT,pg,iP,JT,bn,Gt,xr,wo,Le,QT,Tr,ex,ds,tx,sP,hp,_l=y(()=>{"use strict";Lt();Gr();Zr();FT();cp();BT();ml();M();yo();Yr={MINIMAL:"minimal",STANDARD:"standard",VERBOSE:"verbose"},ga={SIGNAL:"signal",TRAFFIC:"traffic",MONO:"mono",NEON:"neon",EMBER:"ember"},nx=[{id:ga.SIGNAL,label:"Signal",active:"#3b82f6",idle:"#eab308",ended:"#ef4444"},{id:ga.TRAFFIC,label:"Traffic",active:"#22c55e",idle:"#eab308",ended:"#ef4444"},{id:ga.MONO,label:"Mono",active:"#fafafa",idle:"#a3a3a3",ended:"#525252"},{id:ga.NEON,label:"Neon",active:"#06b6d4",idle:"#a855f7",ended:"#f43f5e"},{id:ga.EMBER,label:"Ember",active:"#f97316",idle:"#facc15",ended:"#7f1d1d"}],Y9={id:ga.SIGNAL,label:"Signal",active:"#3b82f6",idle:"#eab308",ended:"#ef4444"};fp=[{value:Yr.MINIMAL,label:"Minimal"},{value:Yr.STANDARD,label:"Standard"},{value:Yr.VERBOSE,label:"Verbose"}],Sr={outputDetail:Yr.STANDARD,statusThemeId:ga.SIGNAL,ambientGlow:!0,reactComponents:!1,hideUntilRestart:!1,clearOnCopy:!1,blockPageInteractions:!0,showTally:!1,showTimestamps:!0,autoOpenChat:!0,reduceMotion:!1},Bt=rx();bl={outputDetail:["Output detail","How much a copied run includes."],autoOpenChat:["Open the log automatically","Opens this panel when an agent starts to act in this tab."],showTimestamps:["Show timestamps","Shows how long ago each log row happened."],showTally:["Show pass/fail count","A score pill for this session in the toolbar."],reactComponents:["React component names","Adds component names to copied runs."],blockPageInteractions:["Block page while adding notes","Clicks pin a note instead of using the app."],clearOnCopy:["Clear notes after copying","Starts fresh once your notes are copied."],hideUntilRestart:["Hide until reload","Hides the HUD until this page reloads."],harnessEnabled:["Allow Reticle to drive","Off by default. Lets Run Harness test this project."],reduceMotion:["Reduce motion","Fewer HUD animations."],ambientGlow:["Page glow","Tints the page edges while a session runs."],workspace:["Workspace","The Reticle account this machine is signed in to."]};ox="data-reticle-settings-account",Q1="data-reticle-settings-account-row",q1="data-reticle-settings-helptext",eP="data-reticle-settings-harness-row",tP="Let Reticle test this app by itself to find defects, from Run Harness or from your coding agent. Off blocks every run. Set here or in your dashboard \u2014 both write to the same place.",nP="The Harness is not available to this workspace right now: see Plan in your Reticle dashboard.";tW=`Whether this machine is signed in to a Reticle workspace. Press ${he.SIGNED_OUT} to sign in through your browser.`;dg={EMAIL:"Email the founder",EMAIL_TITLE:`Write to ${rI}: a problem, a wish, anything`,CALL:"Book a call",CALL_TITLE:"Pick a time to talk it through"},qT="data-reticle-settings-kill",pg={LABEL:"Kill Reticle",ARMED:"Click again to kill Reticle",WARNING:"Disconnects Reticle from this page: no HUD, no agent, nothing recorded. To bring it back, restart your dev server or reload the page."},iP="data-reticle-sdk-version",JT={UNKNOWN:"Reticle SDK version unknown",KNOWN:e=>`Reticle SDK ${e}`};hp=class{constructor(t={}){x(this,Le);x(this,bn);x(this,Gt);x(this,xr);x(this,wo);g(this,wo,t),Bt=rx()}contains(t){var n;return((n=c(this,Gt))==null?void 0:n.contains(t))===!0}mount(t){var i,s,a,l,u,d,f;g(this,bn,t);let n=t.querySelector(`[${P}]`);g(this,Gt,n instanceof HTMLElement?n:void 0),(i=c(this,Gt))==null||i.addEventListener("pointerdown",m=>{m.stopPropagation()});let r=t.querySelector(`[${np}]`);g(this,xr,r instanceof HTMLElement?r:void 0);let o=t.querySelector(`[${DT}]`);if(o instanceof HTMLElement&&RT(o,se.REMOVE,ye.MIN),c(this,xr)!==void 0){let m=c(this,xr).querySelector(".reticle-nav-label");RT(c(this,xr),se.GEAR,ye.TOOLBAR),m!==null&&c(this,xr).append(m),c(this,xr).addEventListener("click",h=>{h.stopPropagation(),this.open()})}(s=t.querySelector('[data-reticle-settings-cycle="outputDetail"]'))==null||s.addEventListener("click",m=>{m.stopPropagation();let h=fp.findIndex(S=>S.value===Bt.outputDetail),E=fp[(h+1)%fp.length];E!==void 0&&T(this,Le,Tr).call(this,{outputDetail:E.value})});for(let m of t.querySelectorAll(".reticle-settings-help"))m.setAttribute("aria-expanded","false"),m.addEventListener("click",h=>{var w;h.stopPropagation();let E=m.closest(".reticle-settings-row");if(E===null)return;let S=E.querySelector(`[${q1}]`);if(S!==null){S.remove(),m.setAttribute("aria-expanded","false");return}let A=document.createElement("p");A.className="reticle-settings-helptext",A.setAttribute(q1,""),A.textContent=(w=m.getAttribute("title"))!=null?w:"",E.appendChild(A),m.setAttribute("aria-expanded","true")});for(let m of t.querySelectorAll(`[${ll}]`)){let h=()=>{var S,A,w,N;if(!(m instanceof HTMLElement))return;let E=m.getAttribute(ll);if(E==="harnessEnabled"){if(m.getAttribute("aria-disabled")==="true")return;let O=m.getAttribute("aria-checked")!=="true";m.setAttribute("aria-checked",O?"true":"false"),(A=(S=c(this,wo)).onHarness)==null||A.call(S,O)}else if(E==="reactComponents")T(this,Le,Tr).call(this,{reactComponents:!Bt.reactComponents});else if(E==="hideUntilRestart"){let O=!Bt.hideUntilRestart;T(this,Le,Tr).call(this,{hideUntilRestart:O}),O&&((N=(w=c(this,wo)).onHideUntilRestart)==null||N.call(w))}else E==="showTally"?T(this,Le,Tr).call(this,{showTally:!Bt.showTally}):E==="autoOpenChat"?T(this,Le,Tr).call(this,{autoOpenChat:!Bt.autoOpenChat}):E==="showTimestamps"?T(this,Le,Tr).call(this,{showTimestamps:!Bt.showTimestamps}):E==="reduceMotion"?T(this,Le,Tr).call(this,{reduceMotion:!Bt.reduceMotion}):E==="ambientGlow"&&T(this,Le,Tr).call(this,{ambientGlow:!Bt.ambientGlow})};m.addEventListener("click",E=>{E.stopPropagation(),h()}),m.addEventListener("keydown",E=>{E instanceof KeyboardEvent&&(E.key===" "||E.key==="Enter")&&(E.preventDefault(),E.stopPropagation(),h())})}for(let m of t.querySelectorAll("[data-reticle-check]")){let h=()=>{if(!(m instanceof HTMLElement))return;let S=m.getAttribute("data-reticle-check");S==="clearOnCopy"?T(this,Le,Tr).call(this,{clearOnCopy:!Bt.clearOnCopy}):S==="blockPageInteractions"&&T(this,Le,Tr).call(this,{blockPageInteractions:!Bt.blockPageInteractions})},E=m.closest("[data-reticle-check-row]");E==null||E.addEventListener("click",S=>{S.stopPropagation(),!(S.target instanceof HTMLElement&&S.target.classList.contains("reticle-settings-help"))&&h()}),m.addEventListener("keydown",S=>{S instanceof KeyboardEvent&&(S.key===" "||S.key==="Enter")&&(S.preventDefault(),h())})}(a=t.querySelector("[data-reticle-settings-mcp]"))==null||a.addEventListener("click",m=>{m.stopPropagation(),window.open(g1,"_blank","noopener,noreferrer")}),(l=t.querySelector("[data-reticle-settings-reset]"))==null||l.addEventListener("click",m=>{m.stopPropagation();let h=t.querySelector(`[${F}]`);h instanceof HTMLElement&&ip(h)}),(u=t.querySelector(`[${qT}]`))==null||u.addEventListener("click",m=>{var S,A;m.stopPropagation();let h=m.currentTarget;if(!(h instanceof HTMLElement))return;if(h.getAttribute("data-armed")==="1"){(A=(S=c(this,wo)).onKill)==null||A.call(S);return}h.setAttribute("data-armed","1");let E=h.querySelector("[data-reticle-kill-label]");E!==null&&(E.textContent=pg.ARMED)}),o==null||o.addEventListener("click",m=>{m.stopPropagation(),this.close()}),T(this,Le,sP).call(this),T(this,Le,ex).call(this),J1(t,Bt),(f=(d=c(this,wo)).onSettingsChange)==null||f.call(d,Bt)}paintHarness(t){let n=c(this,Gt);n!==void 0&&oP(n,t)}teardown(){g(this,bn,void 0),g(this,Gt,void 0),g(this,xr,void 0)}isOpen(){var t;return((t=c(this,bn))==null?void 0:t.getAttribute(ft))==="1"}open(){var t,n,r,o;c(this,bn)!==void 0&&((n=(t=c(this,wo)).onBeforeOpen)==null||n.call(t),c(this,bn).setAttribute(ft,"1"),(r=c(this,Gt))==null||r.setAttribute("aria-hidden","false"),(o=c(this,xr))==null||o.setAttribute("data-active","1"),T(this,Le,QT).call(this))}close(){var n,r,o;if(c(this,bn)===void 0)return;let t=(n=c(this,Gt))==null?void 0:n.querySelector(`[${qT}]`);if(t instanceof HTMLElement){t.removeAttribute("data-armed");let i=t.querySelector("[data-reticle-kill-label]");i!==null&&(i.textContent=pg.LABEL)}c(this,bn).setAttribute(ft,"0"),(r=c(this,Gt))==null||r.setAttribute("aria-hidden","true"),(o=c(this,xr))==null||o.setAttribute("data-active","0"),T(this,Le,QT).call(this)}toggle(){this.isOpen()?this.close():this.open()}};bn=new WeakMap,Gt=new WeakMap,xr=new WeakMap,wo=new WeakMap,Le=new WeakSet,QT=function(){if(c(this,bn)===void 0)return;let t=C1(c(this,bn));t!==void 0&&Wr(t,c(this,bn))},Tr=function(t){var r,o;let n=Q9(t);c(this,bn)!==void 0&&J1(c(this,bn),n),T(this,Le,ex).call(this),(o=(r=c(this,wo)).onSettingsChange)==null||o.call(r,n)},ex=function(){var o,i,s,a,l,u;let t=Bt,n=(o=c(this,Gt))==null?void 0:o.querySelector("[data-reticle-cycle-label]");n!=null&&(n.textContent=(s=(i=fp.find(d=>d.value===t.outputDetail))==null?void 0:i.label)!=null?s:"Standard");let r=(a=c(this,Gt))==null?void 0:a.querySelector("[data-reticle-cycle-dots]");r!=null&&r.replaceChildren(...fp.map(d=>{let f=document.createElement("span");return f.className="reticle-settings-dot",f.setAttribute("data-on",d.value===t.outputDetail?"1":"0"),f})),T(this,Le,ds).call(this,"reactComponents",t.reactComponents),T(this,Le,ds).call(this,"hideUntilRestart",t.hideUntilRestart),T(this,Le,ds).call(this,"showTally",t.showTally),T(this,Le,ds).call(this,"autoOpenChat",t.autoOpenChat),T(this,Le,ds).call(this,"showTimestamps",t.showTimestamps),T(this,Le,ds).call(this,"reduceMotion",t.reduceMotion),T(this,Le,ds).call(this,"ambientGlow",t.ambientGlow),T(this,Le,tx).call(this,"clearOnCopy",t.clearOnCopy),T(this,Le,tx).call(this,"blockPageInteractions",t.blockPageInteractions);for(let d of(u=(l=c(this,Gt))==null?void 0:l.querySelectorAll("[data-reticle-theme]"))!=null?u:[])d instanceof HTMLElement&&d.setAttribute("data-on",d.getAttribute("data-reticle-theme")===t.statusThemeId?"1":"0")},ds=function(t,n){var o;let r=(o=c(this,Gt))==null?void 0:o.querySelector(`[${ll}="${t}"]`);r instanceof HTMLElement&&(r.setAttribute("data-on",n?"1":"0"),r.setAttribute("aria-checked",n?"true":"false"))},tx=function(t,n){var o;let r=(o=c(this,Gt))==null?void 0:o.querySelector(`[data-reticle-check="${t}"]`);r instanceof HTMLElement&&(r.setAttribute("data-on",n?"1":"0"),r.setAttribute("aria-checked",n?"true":"false"),r.textContent=n?"\u2713":"")},sP=function(){var n;let t=(n=c(this,Gt))==null?void 0:n.querySelector("[data-reticle-settings-themes]");t!=null&&t.replaceChildren(...nx.map(r=>{let o=document.createElement("button");o.type="button",o.className="reticle-settings-theme",o.setAttribute("data-reticle-theme",r.id),o.title=r.label,o.setAttribute("aria-label",`${r.label} status theme`);for(let s of[r.active,r.idle,r.ended]){let a=document.createElement("span");a.className="reticle-settings-theme-band",a.style.background=s,o.appendChild(a)}let i=document.createElement("span");return i.className="reticle-settings-theme-name",i.textContent=r.label,o.appendChild(i),o.addEventListener("click",s=>{s.stopPropagation(),T(this,Le,Tr).call(this,{statusThemeId:r.id})}),o}))}});function aW(){let e=globalThis[nh];return typeof e=="string"&&e.length>0?e:void 0}function cW(e){let n=e.replace(/\\/g,"/").replace(/\/+$/,"").split("/").filter(o=>o.length>0),r=n[n.length-1];return r!==void 0&&r.length>0?r:px}function lW(){if(typeof window=="undefined")return;let e=new URLSearchParams(window.location.search).get(or.PROJECT);return e!==null&&e.length>0?e:void 0}function hP(){let e=aW(),t=lW(),n=e!==void 0?cW(e):px;if(e===void 0&&t===void 0)return{folder:n};let r={folder:n};return e!==void 0&&(r.root=e),t!==void 0&&(r.projectId=t),r}function mP(){let e=Ce(se.LAYOUT,ye.HELP),t=Ce(se.CARET_DOWN,ye.HELP),n=Ce(se.COPY,ye.HELP);return`<div class="reticle-workspace-wrap">
435
+ <button type="button" class="reticle-workspace" ${hg} aria-haspopup="true" aria-expanded="false" title="${oW}">
436
436
  <span class="reticle-workspace-icon" aria-hidden="true">${e}</span>
437
- <span class="reticle-workspace-k">${S9}</span>
438
- <span class="reticle-workspace-name" ${X1}>${tx}</span>
437
+ <span class="reticle-workspace-k">${rW}</span>
438
+ <span class="reticle-workspace-name" ${dP}>${px}</span>
439
439
  <span class="reticle-workspace-caret" aria-hidden="true">${t}</span>
440
440
  </button>
441
- <div class="reticle-workspace-menu" ${Y1} role="region" aria-label="${JT}" aria-hidden="true" hidden>
441
+ <div class="reticle-workspace-menu" ${uP} role="region" aria-label="${lx}" aria-hidden="true" hidden>
442
442
  <div class="reticle-workspace-menu-head">
443
- <div class="reticle-workspace-menu-title">${JT}</div>
443
+ <div class="reticle-workspace-menu-title">${lx}</div>
444
444
  <div class="reticle-workspace-menu-actions">
445
- <button type="button" class="reticle-workspace-copy" ${QT} title="${Z1}" aria-label="${Z1}">${n}</button>
445
+ <button type="button" class="reticle-workspace-copy" ${ux} title="${cP}" aria-label="${cP}">${n}</button>
446
446
  </div>
447
447
  </div>
448
448
  <div class="reticle-workspace-menu-row"><span class="reticle-workspace-menu-k">Folder</span><span class="reticle-workspace-menu-v" data-reticle-workspace-folder></span></div>
449
- <div class="reticle-workspace-menu-row"><span class="reticle-workspace-menu-k">Path</span><span class="reticle-workspace-menu-v reticle-workspace-menu-path" ${q1}></span></div>
450
- <div class="reticle-workspace-menu-row" data-reticle-workspace-project-row hidden><span class="reticle-workspace-menu-k">${x9}</span><span class="reticle-workspace-menu-v" ${J1}></span></div>
449
+ <div class="reticle-workspace-menu-row"><span class="reticle-workspace-menu-k">Path</span><span class="reticle-workspace-menu-v reticle-workspace-menu-path" ${pP}></span></div>
450
+ <div class="reticle-workspace-menu-row" data-reticle-workspace-project-row hidden><span class="reticle-workspace-menu-k">${iW}</span><span class="reticle-workspace-menu-v" ${fP}></span></div>
451
451
  </div>
452
- </div>`}function W1(e){var d,f;let t=Q1(),n=e.querySelector(".reticle-workspace-wrap");if(n instanceof HTMLElement){let m=t.root!==void 0||t.projectId!==void 0;n.toggleAttribute("hidden",!m)}let r=e.querySelector(`[${ug}] [${X1}]`);r instanceof HTMLElement&&(r.textContent=t.folder);let o=e.querySelector("[data-reticle-workspace-folder]");o instanceof HTMLElement&&(o.textContent=t.folder);let i=e.querySelector(`[${q1}]`);i instanceof HTMLElement&&(i.textContent=(d=t.root)!=null?d:"-",i.title=(f=t.root)!=null?f:"");let s=e.querySelector(`[${J1}]`),a=e.querySelector("[data-reticle-workspace-project-row]"),l=e.querySelector(`[${QT}]`);t.projectId!==void 0?(a==null||a.removeAttribute("hidden"),s instanceof HTMLElement&&(s.textContent=t.projectId)):(a==null||a.setAttribute("hidden",""),s instanceof HTMLElement&&(s.textContent="")),l instanceof HTMLButtonElement&&(l.disabled=t.root===void 0);let u=e.querySelector(`[${ug}]`);u instanceof HTMLElement&&t.root!==void 0&&(u.title=`${JT}: ${t.root}`)}function tP(e){let t=new AbortController;W1(e);let n=e.querySelector(`[${ug}]`),r=e.querySelector(`[${Y1}]`),o=e.querySelector(`[${QT}]`);if(!(n instanceof HTMLElement)||!(r instanceof HTMLElement))return()=>{};let i=()=>{r.setAttribute("aria-hidden","true"),r.setAttribute("hidden",""),n.setAttribute("aria-expanded","false")},s=()=>{W1(e),r.removeAttribute("hidden"),r.setAttribute("aria-hidden","false"),n.setAttribute("aria-expanded","true")},a=()=>{r.getAttribute("aria-hidden")==="true"||r.hasAttribute("hidden")?s():i()},l=h=>{h.stopPropagation(),a()},u=h=>{var v;let E=h.target;if(!(E instanceof Element))return;let _=E.closest(`[${qt}]`);if(_===null)return;h.stopPropagation(),(v=navigator.clipboard)==null||v.writeText(fe.SIGNIN_COMMAND).catch(()=>{});let A=_.textContent;_.textContent=fe.COPIED,setTimeout(()=>{_.textContent=A},_9)};r.addEventListener("click",u);let d=h=>{let E=h.target;E instanceof Node&&(n.contains(E)||r.contains(E)||i())},f=h=>{h.key==="Escape"&&(r.getAttribute("aria-hidden")==="true"||r.hasAttribute("hidden")||(h.preventDefault(),h.stopPropagation(),i()))},m=h=>{var _;h.stopPropagation();let E=Q1().root;if(E!==void 0&&((_=navigator.clipboard)==null||_.writeText(E),o instanceof HTMLButtonElement)){let A=o.title;o.title=A9,window.setTimeout(()=>{o.title=A},1200)}};return n.addEventListener("click",l),r.addEventListener("pointerdown",h=>h.stopPropagation()),o==null||o.addEventListener("click",m),document.addEventListener("pointerdown",d,{signal:t.signal}),document.addEventListener("keydown",f,{signal:t.signal}),()=>{n.removeEventListener("click",l),o==null||o.removeEventListener("click",m),t.abort()}}function nP(e,t,n,r={}){let o=e.querySelector(`[${fl}]`);o instanceof HTMLElement&&cp(o,$1(t,n));let i=e.querySelector(`[${ex}]`);if(!(i instanceof HTMLElement))return;let s=!(o instanceof HTMLElement);cp(i,hl(t,{...r,dashboardUrl:n},s))}var ug,Y1,X1,q1,J1,QT,ex,_9,JT,S9,T9,x9,Z1,A9,tx,nx=y(()=>{"use strict";M();Hr();xo();ug="data-reticle-workspace-btn",Y1="data-reticle-workspace-menu",X1="data-reticle-workspace-name",q1="data-reticle-workspace-path",J1="data-reticle-workspace-project",QT="data-reticle-workspace-copy",ex="data-reticle-toolbar-account",_9=1200,JT="Workspace",S9="Project",T9="The project folder this page is served from, which Reticle reports to. Click for its path.",x9="Project",Z1="Copy path",A9="Copied",tx="This page"});function iP(e){return typeof e=="string"&&N9.has(e)?e:An.PENDING}function pp(e){return typeof e=="string"?e:""}function ox(e){return Array.isArray(e)?e.filter(t=>typeof t=="object"&&t!==null):[]}function lP(e){let t=ox(e.lanes).map(r=>({id:pp(r.id),journeys:ox(r.journeys).map(o=>({id:pp(o.id),title:pp(o.title),...typeof o.persona=="string"?{persona:o.persona}:{},waitsOn:Array.isArray(o.waitsOn)?o.waitsOn.map(pp):[],status:iP(o.status),steps:ox(o.steps).map(i=>({label:pp(i.label),status:iP(i.status)}))}))}));return t.length===0?void 0:{parallel:typeof e.parallel=="number"?e.parallel:1,lanes:t}}function Gt(e,t,n){let r=document.createElement(e);return r.className=t,n!==void 0&&(r.textContent=n),r}var sP,rP,rx,aP,El,oP,cP,N9,bl,hp,ga,_l,mi,fp,uP,dg,pg=y(()=>{"use strict";M();sP="data-reticle-plan",rP="data-reticle-plan-close",rx="data-reticle-plan-journey",aP=`<div ${sP} class="reticle-plan" hidden></div>`,El={TITLE:"Harness plan",CLOSE:"Hide the plan",WAITS:"waits on",AT_ONCE:"at once",LANE:"Lane"},oP={[An.PENDING]:"\u25CB",[An.RUNNING]:"\u25D0",[An.PASSED]:"\u2713",[An.FAILED]:"\u2717",[An.BLOCKED]:"\u2298",[An.NOT_TAKEN]:"\u2013",[An.UNDECIDED]:"?"},cP=`
452
+ </div>`}function lP(e){var d,f;let t=hP(),n=e.querySelector(".reticle-workspace-wrap");if(n instanceof HTMLElement){let m=t.root!==void 0||t.projectId!==void 0;n.toggleAttribute("hidden",!m)}let r=e.querySelector(`[${hg}] [${dP}]`);r instanceof HTMLElement&&(r.textContent=t.folder);let o=e.querySelector("[data-reticle-workspace-folder]");o instanceof HTMLElement&&(o.textContent=t.folder);let i=e.querySelector(`[${pP}]`);i instanceof HTMLElement&&(i.textContent=(d=t.root)!=null?d:"-",i.title=(f=t.root)!=null?f:"");let s=e.querySelector(`[${fP}]`),a=e.querySelector("[data-reticle-workspace-project-row]"),l=e.querySelector(`[${ux}]`);t.projectId!==void 0?(a==null||a.removeAttribute("hidden"),s instanceof HTMLElement&&(s.textContent=t.projectId)):(a==null||a.setAttribute("hidden",""),s instanceof HTMLElement&&(s.textContent="")),l instanceof HTMLButtonElement&&(l.disabled=t.root===void 0);let u=e.querySelector(`[${hg}]`);u instanceof HTMLElement&&t.root!==void 0&&(u.title=`${lx}: ${t.root}`)}function gP(e){let t=new AbortController;lP(e);let n=e.querySelector(`[${hg}]`),r=e.querySelector(`[${uP}]`),o=e.querySelector(`[${ux}]`);if(!(n instanceof HTMLElement)||!(r instanceof HTMLElement))return()=>{};let i=()=>{r.setAttribute("aria-hidden","true"),r.setAttribute("hidden",""),n.setAttribute("aria-expanded","false")},s=()=>{lP(e),r.removeAttribute("hidden"),r.setAttribute("aria-hidden","false"),n.setAttribute("aria-expanded","true")},a=()=>{r.getAttribute("aria-hidden")==="true"||r.hasAttribute("hidden")?s():i()},l=h=>{h.stopPropagation(),a()},u=h=>{var w;let E=h.target;if(!(E instanceof Element))return;let S=E.closest(`[${qt}]`);if(S===null)return;h.stopPropagation(),(w=navigator.clipboard)==null||w.writeText(he.SIGNIN_COMMAND).catch(()=>{});let A=S.textContent;S.textContent=he.COPIED,setTimeout(()=>{S.textContent=A},nW)};r.addEventListener("click",u);let d=h=>{let E=h.target;E instanceof Node&&(n.contains(E)||r.contains(E)||i())},f=h=>{h.key==="Escape"&&(r.getAttribute("aria-hidden")==="true"||r.hasAttribute("hidden")||(h.preventDefault(),h.stopPropagation(),i()))},m=h=>{var S;h.stopPropagation();let E=hP().root;if(E!==void 0&&((S=navigator.clipboard)==null||S.writeText(E),o instanceof HTMLButtonElement)){let A=o.title;o.title=sW,window.setTimeout(()=>{o.title=A},1200)}};return n.addEventListener("click",l),r.addEventListener("pointerdown",h=>h.stopPropagation()),o==null||o.addEventListener("click",m),document.addEventListener("pointerdown",d,{signal:t.signal}),document.addEventListener("keydown",f,{signal:t.signal}),()=>{n.removeEventListener("click",l),o==null||o.removeEventListener("click",m),t.abort()}}function EP(e,t,n,r={}){let o=e.querySelector(`[${gl}]`);o instanceof HTMLElement&&pp(o,W1(t,n));let i=e.querySelector(`[${dx}]`);if(!(i instanceof HTMLElement))return;let s=!(o instanceof HTMLElement);pp(i,El(t,{...r,dashboardUrl:n},s))}var hg,uP,dP,pP,fP,ux,dx,nW,lx,rW,oW,iW,cP,sW,px,fx=y(()=>{"use strict";M();Gr();yo();hg="data-reticle-workspace-btn",uP="data-reticle-workspace-menu",dP="data-reticle-workspace-name",pP="data-reticle-workspace-path",fP="data-reticle-workspace-project",ux="data-reticle-workspace-copy",dx="data-reticle-toolbar-account",nW=1200,lx="Workspace",rW="Project",oW="The project folder this page is served from, which Reticle reports to. Click for its path.",iW="Project",cP="Copy path",sW="Copied",px="This page"});function SP(e){return typeof e=="string"&&uW.has(e)?e:An.PENDING}function gp(e){return typeof e=="string"?e:""}function mx(e){return Array.isArray(e)?e.filter(t=>typeof t=="object"&&t!==null):[]}function yP(e){let t=mx(e.lanes).map(r=>({id:gp(r.id),journeys:mx(r.journeys).map(o=>({id:gp(o.id),title:gp(o.title),...typeof o.persona=="string"?{persona:o.persona}:{},waitsOn:Array.isArray(o.waitsOn)?o.waitsOn.map(gp):[],status:SP(o.status),steps:mx(o.steps).map(i=>({label:gp(i.label),status:SP(i.status)}))}))}));return t.length===0?void 0:{parallel:typeof e.parallel=="number"?e.parallel:1,lanes:t}}function Vt(e,t,n){let r=document.createElement(e);return r.className=t,n!==void 0&&(r.textContent=n),r}var TP,bP,hx,xP,Sl,_P,AP,uW,Tl,bp,Ea,xl,bi,Ep,wP,mg,gg=y(()=>{"use strict";M();TP="data-reticle-plan",bP="data-reticle-plan-close",hx="data-reticle-plan-journey",xP=`<div ${TP} class="reticle-plan" hidden></div>`,Sl={TITLE:"Harness plan",CLOSE:"Hide the plan",WAITS:"waits on",AT_ONCE:"at once",LANE:"Lane"},_P={[An.PENDING]:"\u25CB",[An.RUNNING]:"\u25D0",[An.PASSED]:"\u2713",[An.FAILED]:"\u2717",[An.BLOCKED]:"\u2298",[An.NOT_TAKEN]:"\u2013",[An.UNDECIDED]:"?"},AP=`
453
453
  [data-reticle-page-panel="harness"] .reticle-plan{flex:none;margin:0 10px 8px;padding:8px 10px;border:1px solid var(--reticle-hud-border);border-radius:10px;background:rgba(255,255,255,.03);}
454
454
  [data-reticle-page-panel="harness"] .reticle-plan[hidden]{display:none;}
455
455
  [data-reticle-page-panel="harness"] .reticle-plan-head{display:flex;align-items:center;gap:8px;margin-bottom:6px;font-size:var(--reticle-hud-size-xs);color:var(--reticle-hud-text-muted);}
@@ -474,7 +474,7 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
474
474
  [data-reticle-page-panel="harness"] .reticle-plan-steps{margin:4px 0 0 18px;display:flex;flex-direction:column;gap:2px;}
475
475
  [data-reticle-page-panel="harness"] .reticle-plan-step{display:flex;gap:6px;color:var(--reticle-hud-text-muted);font-size:11px;min-width:0;}
476
476
  [data-reticle-page-panel="harness"] .reticle-plan-step span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
477
- `,N9=new Set(Object.values(An));dg=class{constructor(){x(this,mi);x(this,bl);x(this,hp);x(this,ga,!1);x(this,_l,new Map)}mount(t){var n,r;g(this,bl,(n=t.querySelector(`[${sP}]`))!=null?n:void 0),(r=c(this,bl))==null||r.addEventListener("click",o=>{let i=o.target;if(!(i instanceof Element))return;if(i.closest(`[${rP}]`)!==null){g(this,ga,!0),T(this,mi,fp).call(this);return}let s=i.closest(`[${rx}]`),a=s==null?void 0:s.getAttribute(rx);a!=null&&(c(this,_l).set(a,(s==null?void 0:s.getAttribute("aria-expanded"))!=="true"),T(this,mi,fp).call(this))}),T(this,mi,fp).call(this)}paint(t){t.lanes.every(r=>r.journeys.every(o=>An.PENDING===o.status))&&(g(this,ga,!1),c(this,_l).clear()),g(this,hp,t),T(this,mi,fp).call(this)}};bl=new WeakMap,hp=new WeakMap,ga=new WeakMap,_l=new WeakMap,mi=new WeakSet,fp=function(){let t=c(this,bl),n=c(this,hp);if(t===void 0||(t.replaceChildren(),t.hidden=n===void 0||c(this,ga),n===void 0||c(this,ga)))return;let r=n.lanes.flatMap(l=>l.journeys),o=r.filter(l=>An.PASSED===l.status).length,i=Gt("div","reticle-plan-head");i.append(Gt("strong","",El.TITLE),Gt("span","",`${String(o)} of ${String(r.length)} passed \xB7 ${String(n.lanes.length)} lane(s)`+(1<n.parallel?`, ${String(n.parallel)} ${El.AT_ONCE}`:"")));let s=Gt("button","reticle-plan-close","\xD7");s.setAttribute("type","button"),s.setAttribute(rP,""),s.setAttribute("aria-label",El.CLOSE),s.setAttribute("title",El.CLOSE),i.append(s);let a=Gt("div","reticle-plan-lanes");for(let l of n.lanes){let u=Gt("div","reticle-plan-lane"),d=Gt("span","reticle-plan-lane-name",l.id);d.setAttribute("title",`${El.LANE} ${l.id}`);let f=Gt("div","reticle-plan-lane-journeys");for(let m of l.journeys)f.append(T(this,mi,uP).call(this,l.id,m));u.append(d,f),a.append(u)}t.append(i,a)},uP=function(t,n){var l;let r=`${t}/${n.id}`,o=(l=c(this,_l).get(r))!=null?l:An.RUNNING===n.status||An.FAILED===n.status,i=Gt("button","reticle-plan-journey");i.setAttribute("type","button"),i.setAttribute(rx,r),i.setAttribute("data-status",n.status),i.setAttribute("aria-expanded",String(o));let s=Gt("span","reticle-plan-row");s.append(Gt("span","reticle-plan-glyph",oP[n.status]),Gt("b","",n.title)),i.append(s);let a=[n.persona,0<n.waitsOn.length?`${El.WAITS} ${n.waitsOn.join(", ")}`:void 0].filter(u=>u!==void 0&&0<u.length);if(0<a.length&&i.append(Gt("span","reticle-plan-meta",a.join(" \xB7 "))),o&&0<n.steps.length){let u=Gt("span","reticle-plan-steps");for(let d of n.steps){let f=Gt("span","reticle-plan-step");f.setAttribute("data-status",d.status),f.append(Gt("span","reticle-plan-glyph",oP[d.status]),Gt("span","",d.label)),u.append(f)}i.append(u)}return i}});function hg(e){return sx.find(t=>t.id===e)}function dP(e,t){let n=hg(e);if(n!==void 0)return`${n.label}: ${n.hint}`;let r=t.trim();return r.length===0?void 0:r}function ax(e){var t,n;return(n=(t=hg(e))==null?void 0:t.label)!=null?n:Ea.CUSTOM_SHORT}function pP(e,t=!1){var o,i;let n=[...sx.map(s=>({id:s.id,label:s.label,hint:s.hint})),{id:ix,label:Ea.CUSTOM,hint:Ea.CUSTOM_HINT}].map(s=>`<option value="${s.id}" title="${de(s.hint)}"${s.id===e?" selected":""}>${de(s.label)}</option>`).join(""),r=de((i=(o=hg(e))==null?void 0:o.hint)!=null?i:Ea.CUSTOM_HINT);return`<label class="reticle-harness-as" for="${Sl}">${Ea.LABEL}</label><select id="${Sl}" data-reticle-harness-persona-pick class="reticle-harness-persona" title="${r}" aria-describedby="${Sl}-hint"${t?" disabled":""}>${n}</select><span id="${Sl}-hint" class="reticle-sr">${r}</span>`}function cx(e,t=!1){return ix===e?`<input type="text" id="${R9}" data-reticle-harness-persona class="reticle-harness-persona" aria-label="${Ea.CUSTOM_HINT}" placeholder="${Ea.CUSTOM_PLACEHOLDER}"${t?" disabled":""}>`:""}function lx(e){return e!=null&&(ix===e||hg(e))?e:void 0}function fP(e){var t;try{return(t=lx(localStorage.getItem(`${_h}${e!=null?e:""}`)))!=null?t:fg}catch{return fg}}function hP(e,t){try{localStorage.setItem(`${_h}${e!=null?e:""}`,t)}catch{}}var ix,sx,fg,Ea,Sl,R9,ux=y(()=>{"use strict";po();ha();ix="custom",sx=[{id:"first-time",label:"First-time visitor",hint:"starts from the first page, reads the labels and follows the obvious path"},{id:"power-user",label:"Returning power user",hint:"goes straight to the main task, takes shortcuts and repeats it quickly"},{id:"phone",label:"On a phone, slow connection",hint:"small-screen habits: taps, waits on loading, retries when nothing seems to happen"},{id:"keyboard",label:"Keyboard only",hint:"Tab, Enter and Escape only: focus order, traps and controls it cannot reach"},{id:"careless",label:"Careless user (bad and unexpected input)",hint:"empty fields, wrong formats, very long text, double submits, going back mid-flow"},{id:"admin",label:"Admin / settings",hint:"changes settings and permissions, then checks they stick after a reload"}],fg=sx[0].id,Ea={LABEL:"As",CUSTOM:"Custom\u2026",CUSTOM_SHORT:"Custom",CUSTOM_HINT:"Describe who to be or what to try, in your own words.",CUSTOM_PLACEHOLDER:"e.g. a first-time shopper paying by card"},Sl="reticle-harness-persona-pick",R9="reticle-harness-persona"});function EP(e){return e===void 0||as(e)?"":kT(e)}function O9(e,t){if(e.kind===void 0)return ba(`${gi(Ee.NO_CREDITS)}${Tl(t,Ee.MORE)}`);let n=og(e),r=n.action!==void 0?Tl(t,`${n.action} \u2197`):xt.TRIAL===e.kind?Tl(t,Ee.PLAN):"";return gg(`${gi(n.said)}${r}`)}function I9(e){if(e.starting===!0)return Ee.STARTING;let t=e.config;if(t===void 0)return Ee.FOOT_LINK;if(t.credits!==void 0&&as(t.credits))return Ee.FOOT_NO_CREDITS;if(!t.harnessEntitled)return Ee.FOOT_NOT_ENTITLED;if(t.providerReady===!1)return Ee.FOOT_NO_PROVIDER;let n=t.credits;return n===void 0?"":Ee.creditsLeft(Math.max(0,n.limit-n.used),n.daysLeft)}function C9(e){let t=e.config;return t===void 0||t.credits!==void 0&&as(t.credits)?!1:t.harnessEntitled&&t.providerReady!==!1}function bP(e){var i,s;if(e.account===void 0||!e.account.signedIn)return"";if(e.drive!==void 0&&e.canDrive)return ba(`<button type="button" ${mg} class="reticle-harness-open"><span class="reticle-harness-name">${Ee.NAME}</span><span class="reticle-harness-state">${de(Ee.driving(e.startedAs===void 0?void 0:ax(e.startedAs),e.drive.steps))}</span><span class="reticle-harness-chev" aria-hidden="true">\u203A</span></button>${gP}`);let t=((i=e.config)==null?void 0:i.harnessEnabled)===!0,n=(s=e.config)==null?void 0:s.credits,r=n===void 0?"":` title="${de(kT(n))}"`,o=C9(e)?`<button type="button" role="switch" ${px} class="reticle-harness-toggle" aria-checked="${String(t)}" aria-label="${Ee.TOGGLE}"><span class="reticle-harness-knob"></span></button>`:"";return ba(`<button type="button" ${mg} class="reticle-harness-open"${r}><span class="reticle-harness-name">${Ee.NAME}</span><span class="reticle-harness-state">${de(I9(e))}</span><span class="reticle-harness-chev" aria-hidden="true">\u203A</span></button>${o}`)}function _P(e){if(e.account===void 0)return"";if(!e.account.signedIn)return gg(`${gi(Ee.SIGNED_OUT)}<button type="button" ${qt} class="reticle-harness-link">${Ee.SIGN_IN}</button>`);if(e.drive!==void 0&&e.canDrive)return mP(gi(Ee.driving(e.startedAs===void 0?void 0:ax(e.startedAs),e.drive.steps)),gP)+cx(e.pick,!0);let t=e.config;if(t===void 0)return gg(`${gi(Ee.UNLINKED)}<button type="button" ${mp} class="reticle-harness-run"${e.linking===!0?" disabled":""}>${e.linking===!0?Ee.LINKING:Ee.LINK}</button>`);if(t.credits!==void 0&&as(t.credits))return O9(t.credits,e.planUrl);if(!t.harnessEntitled)return ba(`${gi(Ee.NOT_ENTITLED)}${Tl(e.planUrl,Ee.PLANS)}`);if(t.providerReady===!1)return ba(`${gi(Ee.NO_PROVIDER)}${Tl(e.setupUrl,Ee.SET_UP)}`);if(!t.harnessEnabled)return ba(`${gi(Ee.OFF)}<button type="button" ${dx} class="reticle-harness-run">${Ee.TURN_ON}</button>`);if(!e.canDrive)return"";let n=e.starting===!0;return mP(pP(e.pick,n),`<button type="button" data-reticle-harness-run class="reticle-harness-run"${n?" disabled":""}>${n?Ee.STARTING:Ee.RUN}</button>`)+cx(e.pick,n)+(n?"":L9(e.last))}function L9(e){return e===void 0||e.said===void 0&&e.runUrl===void 0?"":gg(`${e.said===void 0?"":gi(de(e.said))}${e.runUrl===void 0?"":Tl(e.runUrl,Ee.RESULT)}`)}var Ee,dx,mp,mg,Eg,px,ba,gg,gi,mP,gP,Tl,fx,bg=y(()=>{"use strict";M();pl();ha();xo();ux();Ee={RUN:"Run Harness",STARTING:"Starting\u2026",STOP:"Stop",SIGNED_OUT:w1,SIGN_IN:"Sign in",UNLINKED:"This project is not on your dashboard yet.",LINK:"Link this project",LINKING:"Linking\u2026",NOT_ENTITLED:"Harness is not on your plan",NO_CREDITS:"No credits left",NO_PROVIDER:"No model provider set",OFF:"Harness is off",TURN_ON:"Switch on",SET_UP:"Set up \u2197",PLANS:"See plans \u2197",PLAN:"Plan \u2197",MORE:"Get more \u2197",driving:(e,t)=>`Driving${e===void 0?"":` as ${e}`} \xB7 ${String(t)} step${t===1?"":"s"}`,NAME:"Harness",TOGGLE:"Reticle Harness on this project",creditsLeft:(e,t)=>`${e.toLocaleString("en-US")} credit${e===1?"":"s"}${t===void 0?"":` \xB7 ${String(t)} day${t===1?"":"s"}`}`,FOOT_LINK:"Link project",FOOT_NO_CREDITS:"No credits",FOOT_NOT_ENTITLED:"Not on your plan",FOOT_NO_PROVIDER:"No model provider",PAGE_TITLE:"Reticle Harness",LOG_LABEL:"What the Harness did",LOG_EMPTY:"Runs show here, step by step.",PAGE_SUBTITLE:"Tests your app by itself",RESULT:"See the result \u2197"},dx="data-reticle-harness-switch",mp="data-reticle-harness-link",mg="data-reticle-harness-open",Eg="data-reticle-harness-log",px="data-reticle-harness-toggle",ba=e=>`<div class="reticle-harness-row">${e}</div>`,gg=e=>`<div class="reticle-harness-row reticle-harness-row-wrap">${e}</div>`,gi=e=>`<span class="reticle-harness-said">${e}</span>`,mP=(e,t)=>ba(`<span class="reticle-harness-lead">${e}</span>${t}`),gP=`<button type="button" data-reticle-harness-stop class="reticle-harness-run reticle-harness-stop">${Ee.STOP}</button>`,Tl=(e,t)=>`<a class="reticle-harness-link" href="${e}" target="_blank" rel="noopener noreferrer">${t}</a>`;fx=`
477
+ `,uW=new Set(Object.values(An));mg=class{constructor(){x(this,bi);x(this,Tl);x(this,bp);x(this,Ea,!1);x(this,xl,new Map)}mount(t){var n,r;g(this,Tl,(n=t.querySelector(`[${TP}]`))!=null?n:void 0),(r=c(this,Tl))==null||r.addEventListener("click",o=>{let i=o.target;if(!(i instanceof Element))return;if(i.closest(`[${bP}]`)!==null){g(this,Ea,!0),T(this,bi,Ep).call(this);return}let s=i.closest(`[${hx}]`),a=s==null?void 0:s.getAttribute(hx);a!=null&&(c(this,xl).set(a,(s==null?void 0:s.getAttribute("aria-expanded"))!=="true"),T(this,bi,Ep).call(this))}),T(this,bi,Ep).call(this)}paint(t){t.lanes.every(r=>r.journeys.every(o=>An.PENDING===o.status))&&(g(this,Ea,!1),c(this,xl).clear()),g(this,bp,t),T(this,bi,Ep).call(this)}};Tl=new WeakMap,bp=new WeakMap,Ea=new WeakMap,xl=new WeakMap,bi=new WeakSet,Ep=function(){let t=c(this,Tl),n=c(this,bp);if(t===void 0||(t.replaceChildren(),t.hidden=n===void 0||c(this,Ea),n===void 0||c(this,Ea)))return;let r=n.lanes.flatMap(l=>l.journeys),o=r.filter(l=>An.PASSED===l.status).length,i=Vt("div","reticle-plan-head");i.append(Vt("strong","",Sl.TITLE),Vt("span","",`${String(o)} of ${String(r.length)} passed \xB7 ${String(n.lanes.length)} lane(s)`+(1<n.parallel?`, ${String(n.parallel)} ${Sl.AT_ONCE}`:"")));let s=Vt("button","reticle-plan-close","\xD7");s.setAttribute("type","button"),s.setAttribute(bP,""),s.setAttribute("aria-label",Sl.CLOSE),s.setAttribute("title",Sl.CLOSE),i.append(s);let a=Vt("div","reticle-plan-lanes");for(let l of n.lanes){let u=Vt("div","reticle-plan-lane"),d=Vt("span","reticle-plan-lane-name",l.id);d.setAttribute("title",`${Sl.LANE} ${l.id}`);let f=Vt("div","reticle-plan-lane-journeys");for(let m of l.journeys)f.append(T(this,bi,wP).call(this,l.id,m));u.append(d,f),a.append(u)}t.append(i,a)},wP=function(t,n){var l;let r=`${t}/${n.id}`,o=(l=c(this,xl).get(r))!=null?l:An.RUNNING===n.status||An.FAILED===n.status,i=Vt("button","reticle-plan-journey");i.setAttribute("type","button"),i.setAttribute(hx,r),i.setAttribute("data-status",n.status),i.setAttribute("aria-expanded",String(o));let s=Vt("span","reticle-plan-row");s.append(Vt("span","reticle-plan-glyph",_P[n.status]),Vt("b","",n.title)),i.append(s);let a=[n.persona,0<n.waitsOn.length?`${Sl.WAITS} ${n.waitsOn.join(", ")}`:void 0].filter(u=>u!==void 0&&0<u.length);if(0<a.length&&i.append(Vt("span","reticle-plan-meta",a.join(" \xB7 "))),o&&0<n.steps.length){let u=Vt("span","reticle-plan-steps");for(let d of n.steps){let f=Vt("span","reticle-plan-step");f.setAttribute("data-status",d.status),f.append(Vt("span","reticle-plan-glyph",_P[d.status]),Vt("span","",d.label)),u.append(f)}i.append(u)}return i}});function bg(e){return Ex.find(t=>t.id===e)}function vP(e,t){let n=bg(e);if(n!==void 0)return`${n.label}: ${n.hint}`;let r=t.trim();return r.length===0?void 0:r}function bx(e){var t,n;return(n=(t=bg(e))==null?void 0:t.label)!=null?n:ba.CUSTOM_SHORT}function NP(e,t=!1){var o,i;let n=[...Ex.map(s=>({id:s.id,label:s.label,hint:s.hint})),{id:gx,label:ba.CUSTOM,hint:ba.CUSTOM_HINT}].map(s=>`<option value="${s.id}" title="${pe(s.hint)}"${s.id===e?" selected":""}>${pe(s.label)}</option>`).join(""),r=pe((i=(o=bg(e))==null?void 0:o.hint)!=null?i:ba.CUSTOM_HINT);return`<label class="reticle-harness-as" for="${Al}">${ba.LABEL}</label><select id="${Al}" data-reticle-harness-persona-pick class="reticle-harness-persona" title="${r}" aria-describedby="${Al}-hint"${t?" disabled":""}>${n}</select><span id="${Al}-hint" class="reticle-sr">${r}</span>`}function _x(e,t=!1){return gx===e?`<input type="text" id="${dW}" data-reticle-harness-persona class="reticle-harness-persona" aria-label="${ba.CUSTOM_HINT}" placeholder="${ba.CUSTOM_PLACEHOLDER}"${t?" disabled":""}>`:""}function Sx(e){return e!=null&&(gx===e||bg(e))?e:void 0}function RP(e){var t;try{return(t=Sx(localStorage.getItem(`${wh}${e!=null?e:""}`)))!=null?t:Eg}catch{return Eg}}function OP(e,t){try{localStorage.setItem(`${wh}${e!=null?e:""}`,t)}catch{}}var gx,Ex,Eg,ba,Al,dW,Tx=y(()=>{"use strict";ho();ma();gx="custom",Ex=[{id:"first-time",label:"First-time visitor",hint:"starts from the first page, reads the labels and follows the obvious path"},{id:"power-user",label:"Returning power user",hint:"goes straight to the main task, takes shortcuts and repeats it quickly"},{id:"phone",label:"On a phone, slow connection",hint:"small-screen habits: taps, waits on loading, retries when nothing seems to happen"},{id:"keyboard",label:"Keyboard only",hint:"Tab, Enter and Escape only: focus order, traps and controls it cannot reach"},{id:"careless",label:"Careless user (bad and unexpected input)",hint:"empty fields, wrong formats, very long text, double submits, going back mid-flow"},{id:"admin",label:"Admin / settings",hint:"changes settings and permissions, then checks they stick after a reload"}],Eg=Ex[0].id,ba={LABEL:"As",CUSTOM:"Custom\u2026",CUSTOM_SHORT:"Custom",CUSTOM_HINT:"Describe who to be or what to try, in your own words.",CUSTOM_PLACEHOLDER:"e.g. a first-time shopper paying by card"},Al="reticle-harness-persona-pick",dW="reticle-harness-persona"});function LP(e){return e===void 0||cs(e)?"":jT(e)}function pW(e,t){if(e.kind===void 0)return _a(`${_i(be.NO_CREDITS)}${yl(t,be.MORE)}`);let n=cg(e),r=n.action!==void 0?yl(t,`${n.action} \u2197`):xt.TRIAL===e.kind?yl(t,be.PLAN):"";return Sg(`${_i(n.said)}${r}`)}function fW(e){if(e.starting===!0)return be.STARTING;let t=e.config;if(t===void 0)return be.FOOT_LINK;if(t.credits!==void 0&&cs(t.credits))return be.FOOT_NO_CREDITS;if(!t.harnessEntitled)return be.FOOT_NOT_ENTITLED;if(t.providerReady===!1)return be.FOOT_NO_PROVIDER;let n=t.credits;return n===void 0?"":be.creditsLeft(Math.max(0,n.limit-n.used),n.daysLeft)}function hW(e){let t=e.config;return t===void 0||t.credits!==void 0&&cs(t.credits)?!1:t.harnessEntitled&&t.providerReady!==!1}function $P(e){var i,s;if(e.account===void 0||!e.account.signedIn)return"";if(e.drive!==void 0&&e.canDrive)return _a(`<button type="button" ${_g} class="reticle-harness-open"><span class="reticle-harness-name">${be.NAME}</span><span class="reticle-harness-state">${pe(be.driving(e.startedAs===void 0?void 0:bx(e.startedAs),e.drive.steps))}</span><span class="reticle-harness-chev" aria-hidden="true">\u203A</span></button>${CP}`);let t=((i=e.config)==null?void 0:i.harnessEnabled)===!0,n=(s=e.config)==null?void 0:s.credits,r=n===void 0?"":` title="${pe(jT(n))}"`,o=hW(e)?`<button type="button" role="switch" ${Ax} class="reticle-harness-toggle" aria-checked="${String(t)}" aria-label="${be.TOGGLE}"><span class="reticle-harness-knob"></span></button>`:"";return _a(`<button type="button" ${_g} class="reticle-harness-open"${r}><span class="reticle-harness-name">${be.NAME}</span><span class="reticle-harness-state">${pe(fW(e))}</span><span class="reticle-harness-chev" aria-hidden="true">\u203A</span></button>${o}`)}function kP(e){if(e.account===void 0)return"";if(!e.account.signedIn)return Sg(`${_i(be.SIGNED_OUT)}<button type="button" ${qt} class="reticle-harness-link">${be.SIGN_IN}</button>`);if(e.drive!==void 0&&e.canDrive)return IP(_i(be.driving(e.startedAs===void 0?void 0:bx(e.startedAs),e.drive.steps)),CP)+_x(e.pick,!0);let t=e.config;if(t===void 0)return Sg(`${_i(be.UNLINKED)}<button type="button" ${_p} class="reticle-harness-run"${e.linking===!0?" disabled":""}>${e.linking===!0?be.LINKING:be.LINK}</button>`);if(t.credits!==void 0&&cs(t.credits))return pW(t.credits,e.planUrl);if(!t.harnessEntitled)return _a(`${_i(be.NOT_ENTITLED)}${yl(e.planUrl,be.PLANS)}`);if(t.providerReady===!1)return _a(`${_i(be.NO_PROVIDER)}${yl(e.setupUrl,be.SET_UP)}`);if(!t.harnessEnabled)return _a(`${_i(be.OFF)}<button type="button" ${xx} class="reticle-harness-run">${be.TURN_ON}</button>`);if(!e.canDrive)return"";let n=e.starting===!0;return IP(NP(e.pick,n),`<button type="button" data-reticle-harness-run class="reticle-harness-run"${n?" disabled":""}>${n?be.STARTING:be.RUN}</button>`)+_x(e.pick,n)+(n?"":mW(e.last))}function mW(e){return e===void 0||e.said===void 0&&e.runUrl===void 0?"":Sg(`${e.said===void 0?"":_i(pe(e.said))}${e.runUrl===void 0?"":yl(e.runUrl,be.RESULT)}`)}var be,xx,_p,_g,Tg,Ax,_a,Sg,_i,IP,CP,yl,yx,xg=y(()=>{"use strict";M();ml();ma();yo();Tx();be={RUN:"Run Harness",STARTING:"Starting\u2026",STOP:"Stop",SIGNED_OUT:H1,SIGN_IN:"Sign in",UNLINKED:"This project is not on your dashboard yet.",LINK:"Link this project",LINKING:"Linking\u2026",NOT_ENTITLED:"Harness is not on your plan",NO_CREDITS:"No credits left",NO_PROVIDER:"No model provider set",OFF:"Harness is off",TURN_ON:"Switch on",SET_UP:"Set up \u2197",PLANS:"See plans \u2197",PLAN:"Plan \u2197",MORE:"Get more \u2197",driving:(e,t)=>`Driving${e===void 0?"":` as ${e}`} \xB7 ${String(t)} step${t===1?"":"s"}`,NAME:"Harness",TOGGLE:"Reticle Harness on this project",creditsLeft:(e,t)=>`${e.toLocaleString("en-US")} credit${e===1?"":"s"}${t===void 0?"":` \xB7 ${String(t)} day${t===1?"":"s"}`}`,FOOT_LINK:"Link project",FOOT_NO_CREDITS:"No credits",FOOT_NOT_ENTITLED:"Not on your plan",FOOT_NO_PROVIDER:"No model provider",PAGE_TITLE:"Reticle Harness",LOG_LABEL:"What the Harness did",LOG_EMPTY:"Runs show here, step by step.",PAGE_SUBTITLE:"Tests your app by itself",RESULT:"See the result \u2197"},xx="data-reticle-harness-switch",_p="data-reticle-harness-link",_g="data-reticle-harness-open",Tg="data-reticle-harness-log",Ax="data-reticle-harness-toggle",_a=e=>`<div class="reticle-harness-row">${e}</div>`,Sg=e=>`<div class="reticle-harness-row reticle-harness-row-wrap">${e}</div>`,_i=e=>`<span class="reticle-harness-said">${e}</span>`,IP=(e,t)=>_a(`<span class="reticle-harness-lead">${e}</span>${t}`),CP=`<button type="button" data-reticle-harness-stop class="reticle-harness-run reticle-harness-stop">${be.STOP}</button>`,yl=(e,t)=>`<a class="reticle-harness-link" href="${e}" target="_blank" rel="noopener noreferrer">${t}</a>`;yx=`
478
478
  [data-reticle-chat-panel] .reticle-harness-spot{flex:none;display:flex;flex-direction:column;gap:4px;}
479
479
  [data-reticle-chat-panel] .reticle-harness-spot[hidden],[data-reticle-chat-panel] .reticle-harness-spot:empty{display:none;}
480
480
  [data-reticle-chat-panel] .reticle-harness-row{display:flex;align-items:center;gap:6px;min-height:30px;min-width:0;}
@@ -513,10 +513,10 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
513
513
  [data-reticle-chat-panel] .reticle-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;}
514
514
  [data-reticle-chat-panel] .reticle-foot-meta{margin:0;font-size:11px;line-height:1.3;color:var(--reticle-hud-text-muted);overflow-wrap:anywhere;}
515
515
  [data-reticle-chat-panel] .reticle-foot-meta:empty{display:none;}
516
- `});function yo(e){return e<1e3?String(Math.round(e)):e<1e6?`${TP(e/1e3)}k`:`${TP(e/1e6)}M`}function TP(e){return e>=10?String(Math.round(e)):String(Math.round(e*10)/10)}function gp(e){let t=Math.floor(e/1e3);if(t<60)return`${String(t)}s`;let n=Math.floor(t/60);if(n<60)return`${String(n)}m`;let r=Math.floor(n/60);return n%60===0?`${String(r)}h`:`${String(r)}h ${String(n%60)}m`}function hx(e,t){let n=e.counts,r=t!==void 0&&t.length>0?` on ${t}`:"",o=[`My agent verified its own work ${String(n.verdicts)} times${r}.`,`${String(n.failed)} checks it refused to pass before I looked at any of them.`];return n.unknown>0&&o.push(`${String(n.unknown)} came back "unknown" - it drove the app and could not tell. That is the number I watch.`),e.records.longestRunMs>0&&o.push(`Longest unattended run: ${gp(e.records.longestRunMs)}.`),o.join(`
517
- `)}function xP(e){let t=new URLSearchParams({text:e,url:ds.SITE});return SP.length>0&&t.set("via",SP),`https://twitter.com/intent/tweet?${t.toString()}`}function AP(){return`https://www.linkedin.com/sharing/share-offsite/?url=${encodeURIComponent(ds.SITE)}`}function mx(){return`I have been verifying my agent's work from inside the running app with Reticle - it returns pass/fail with the file:line to fix. ${ds.SITE}`}function yP(e){let t=N0.safeParse(e);return t.success?t.data:void 0}var ds,SP,Q,wP,_g=y(()=>{"use strict";M();ds={DOCS:"https://docs.reticle.sh",SITE:"https://reticle.sh",GITHUB:"https://github.com/reticlehq/reticle",DISCORD:"https://discord.gg/BwAbzv9ZRz"},SP="",Q={TITLE:"Impact",COVERAGE:"Reticle Coverage",COVERAGE_HELP:"How much of this app Reticle has reached, touched and proved, from the coverage ledger in .reticle",PROJECT:"This project",GLOBAL:"All projects",GLOBAL_TITLE:"Every project on this computer",SCOPE_LABEL:"Show impact for",heroDefects:e=>`failed check${e===1?"":"s"} caught before you shipped`,VERDICTS:"Verdicts",PASSED:"passed",FAILED:"failed",UNKNOWN:"unknown",UNKNOWN_HELP:"Reticle drove the app and could not tell what happened. Not a pass - shown, not hidden.",CALLS:"Tool calls",TOKENS:"Tokens returned",DRIVING:"Time driving",SESSIONS:"Sessions",STREAK:"day streak",LONGEST:"Longest run",SAVED_TOKENS:"Tokens saved",SAVED_MINUTES:"Time saved",ESTIMATE_TAG:"estimate",CHART:"Verdicts, last 30 days",DEFECTS:"What broke",DEFECTS_MORE:"Manage all of them on the dashboard \u2014 triage, assign, and push to GitHub",DEFECTS_SEE_ALL:"See all on the dashboard",DEFECTS_SEE_ALL_TITLE:"Sign up free, link this project, and see every bug Reticle caught",DEFECT_LINK_TITLE:"Open on the dashboard to triage or push to GitHub",LOCAL_ONLY:"This record stops at this machine.",LOCAL_ONLY_ACTION:"reticle connect",LOCAL_ONLY_TAIL:"keeps it, and lets a team see it.",UNLINKED:"Signed in, but this repo is not linked.",UNLINKED_ACTION:"reticle connect",UNLINKED_TAIL:"sends this record to your workspace.",DEFECTS_NONE:"Nothing has failed a declared consequence yet.",EMPTY:"Nothing recorded yet. Drive the app once and this fills in.",SHARE:"Share",COPY:"Copy",COPIED:"Copied",SEE_RUN:"See it in your dashboard",KEY_REFUSED:"Key refused",NOT_SENT:"not synced",NOT_SENT_HELP:"Runs saved on this machine but not on your dashboard yet. Run reticle connect in this project to send them.",COPY_PROMPT:"Copy prompt for your coding agent",SHARE_LABEL:"Share",POST_X:"X",POST_IN:"LinkedIn",REFER:"Invite a friend"};wP=[{key:"reached",label:"routes reached"},{key:"touched",label:"controls touched"},{key:"proved",label:"controls proved"},{key:"branched",label:"write failures driven"},{key:"executed",label:"code executed"}]});var $9,Ep,vP,NP,xl,Sg,RP=y(()=>{"use strict";_g();$9=1600,Ep={NONE:"No coding agent connected",named:e=>`${e} connected`,COPY:"Copy prompt",prompt:e=>`Use Reticle to check ${e} in my running app, then tell me the verdict.`},vP=`<div data-reticle-agent-spot class="reticle-agent-spot" hidden>
518
- <div class="reticle-agent-row"><span data-reticle-agent-dot class="reticle-agent-dot" aria-hidden="true"></span><span data-reticle-agent-said class="reticle-agent-said">${Ep.NONE}</span><button type="button" data-reticle-agent-copy class="reticle-agent-copy" aria-label="${Q.COPY_PROMPT}" title="${Q.COPY_PROMPT}">${Ep.COPY}</button></div>
519
- </div>`,NP=`
516
+ `});function vo(e){return e<1e3?String(Math.round(e)):e<1e6?`${DP(e/1e3)}k`:`${DP(e/1e6)}M`}function DP(e){return e>=10?String(Math.round(e)):String(Math.round(e*10)/10)}function Sp(e){let t=Math.floor(e/1e3);if(t<60)return`${String(t)}s`;let n=Math.floor(t/60);if(n<60)return`${String(n)}m`;let r=Math.floor(n/60);return n%60===0?`${String(r)}h`:`${String(r)}h ${String(n%60)}m`}function wx(e,t){let n=e.counts,r=t!==void 0&&t.length>0?` on ${t}`:"",o=[`My agent verified its own work ${String(n.verdicts)} times${r}.`,`${String(n.failed)} checks it refused to pass before I looked at any of them.`];return n.unknown>0&&o.push(`${String(n.unknown)} came back "unknown" - it drove the app and could not tell. That is the number I watch.`),e.records.longestRunMs>0&&o.push(`Longest unattended run: ${Sp(e.records.longestRunMs)}.`),o.join(`
517
+ `)}function PP(e){let t=new URLSearchParams({text:e,url:ps.SITE});return zP.length>0&&t.set("via",zP),`https://twitter.com/intent/tweet?${t.toString()}`}function MP(){return`https://www.linkedin.com/sharing/share-offsite/?url=${encodeURIComponent(ps.SITE)}`}function vx(){return`I have been verifying my agent's work from inside the running app with Reticle - it returns pass/fail with the file:line to fix. ${ps.SITE}`}function UP(e){let t=H0.safeParse(e);return t.success?t.data:void 0}var ps,zP,ee,HP,Ag=y(()=>{"use strict";M();ps={DOCS:"https://docs.reticle.sh",SITE:"https://reticle.sh",GITHUB:"https://github.com/reticlehq/reticle",DISCORD:"https://discord.gg/BwAbzv9ZRz"},zP="",ee={TITLE:"Impact",COVERAGE:"Reticle Coverage",COVERAGE_HELP:"How much of this app Reticle has reached, touched and proved, from the coverage ledger in .reticle",PROJECT:"This project",GLOBAL:"All projects",GLOBAL_TITLE:"Every project on this computer",SCOPE_LABEL:"Show impact for",heroDefects:e=>`failed check${e===1?"":"s"} caught before you shipped`,VERDICTS:"Verdicts",PASSED:"passed",FAILED:"failed",UNKNOWN:"unknown",UNKNOWN_HELP:"Reticle drove the app and could not tell what happened. Not a pass - shown, not hidden.",CALLS:"Tool calls",TOKENS:"Tokens returned",DRIVING:"Time driving",SESSIONS:"Sessions",STREAK:"day streak",LONGEST:"Longest run",SAVED_TOKENS:"Tokens saved",SAVED_MINUTES:"Time saved",ESTIMATE_TAG:"estimate",CHART:"Verdicts, last 30 days",DEFECTS:"What broke",DEFECTS_MORE:"Manage all of them on the dashboard \u2014 triage, assign, and push to GitHub",DEFECTS_SEE_ALL:"See all on the dashboard",DEFECTS_SEE_ALL_TITLE:"Sign up free, link this project, and see every bug Reticle caught",DEFECT_LINK_TITLE:"Open on the dashboard to triage or push to GitHub",LOCAL_ONLY:"This record stops at this machine.",LOCAL_ONLY_ACTION:"reticle connect",LOCAL_ONLY_TAIL:"keeps it, and lets a team see it.",UNLINKED:"Signed in, but this repo is not linked.",UNLINKED_ACTION:"reticle connect",UNLINKED_TAIL:"sends this record to your workspace.",DEFECTS_NONE:"Nothing has failed a declared consequence yet.",EMPTY:"Nothing recorded yet. Drive the app once and this fills in.",SHARE:"Share",COPY:"Copy",COPIED:"Copied",SEE_RUN:"See it in your dashboard",KEY_REFUSED:"Key refused",NOT_SENT:"not synced",NOT_SENT_HELP:"Runs saved on this machine but not on your dashboard yet. Run reticle connect in this project to send them.",COPY_PROMPT:"Copy prompt for your coding agent",SHARE_LABEL:"Share",POST_X:"X",POST_IN:"LinkedIn",REFER:"Invite a friend"};HP=[{key:"reached",label:"routes reached"},{key:"touched",label:"controls touched"},{key:"proved",label:"controls proved"},{key:"branched",label:"write failures driven"},{key:"executed",label:"code executed"}]});var gW,Tp,FP,BP,wl,yg,GP=y(()=>{"use strict";Ag();gW=1600,Tp={NONE:"No coding agent connected",named:e=>`${e} connected`,COPY:"Copy prompt",prompt:e=>`Use Reticle to check ${e} in my running app, then tell me the verdict.`},FP=`<div data-reticle-agent-spot class="reticle-agent-spot" hidden>
518
+ <div class="reticle-agent-row"><span data-reticle-agent-dot class="reticle-agent-dot" aria-hidden="true"></span><span data-reticle-agent-said class="reticle-agent-said">${Tp.NONE}</span><button type="button" data-reticle-agent-copy class="reticle-agent-copy" aria-label="${ee.COPY_PROMPT}" title="${ee.COPY_PROMPT}">${Tp.COPY}</button></div>
519
+ </div>`,BP=`
520
520
  [data-reticle-chat-panel] .reticle-agent-spot{flex:none;display:flex;flex-direction:column;gap:3px;}
521
521
  [data-reticle-chat-panel] .reticle-agent-spot[hidden]{display:none;}
522
522
  [data-reticle-chat-panel] .reticle-agent-row{display:flex;align-items:center;gap:8px;min-width:0;min-height:30px;padding:0 var(--reticle-hud-space-2);}
@@ -527,40 +527,40 @@ ${Oe("pop")} button[data-send]:disabled{opacity:.4;cursor:not-allowed;}
527
527
  [data-reticle-chat-panel] .reticle-agent-copy{flex:none;height:22px;padding:0 9px;border:1px solid var(--reticle-hud-border-strong);border-radius:11px;background:transparent;color:var(--reticle-hud-text);font:inherit;font-size:11px;font-weight:600;cursor:pointer;white-space:nowrap;}
528
528
  [data-reticle-chat-panel] .reticle-agent-copy:hover{border-color:var(--reticle-hud-brand);color:var(--reticle-hud-brand);}
529
529
  [data-reticle-chat-panel] .reticle-agent-copy[hidden]{display:none;}
530
- `,Sg=class{constructor(){x(this,xl)}mount(t,n){var r;g(this,xl,t),(r=t.querySelector("[data-reticle-agent-copy]"))==null||r.addEventListener("click",o=>{var s;let i=o.currentTarget;(s=navigator.clipboard)==null||s.writeText(Ep.prompt(location.href)).catch(()=>{}).finally(()=>{i instanceof HTMLElement&&(i.textContent=Q.COPIED,window.setTimeout(()=>i.textContent=Q.COPY_PROMPT,$9))})},{signal:n})}teardown(){g(this,xl,void 0)}paint(t){var a;let n=c(this,xl),r=n==null?void 0:n.querySelector("[data-reticle-agent-spot]");if(n===void 0||r===null||r===void 0||(r.hidden=t===void 0,t===void 0))return;let o=0<t.agents.length;(a=r.querySelector(".reticle-agent-row"))==null||a.setAttribute("data-connected",o?"1":"0");let i=r.querySelector("[data-reticle-agent-said]");i!==null&&(i.textContent=o?Ep.named(t.agents.join(", ")):Ep.NONE);let s=r.querySelector("[data-reticle-agent-copy]");s!==null&&(s.hidden=o)}};xl=new WeakMap});function yx(e,t){let n=[P9(e==null?void 0:e.planUrl),e==null?void 0:e.platformUrl,t.host].find(r=>r!==void 0&&Er(r));return de((n!=null?n:Uf).replace(/\/+$/,""))}function P9(e){if(!(e===void 0||!Er(e)))try{return new URL(e).origin}catch{return}}function M9(e){if(typeof e!="object"||e===null)return!1;let t=e;return typeof t.id=="string"&&typeof t.note=="string"&&typeof t.label=="string"&&typeof t.anchor=="string"&&typeof t.route=="string"&&typeof t.createdAt=="number"&&typeof t.pageUrl=="string"}function U9(){var e;try{let t=JSON.parse((e=localStorage.getItem(DP))!=null?e:"[]");return Array.isArray(t)?t.filter(M9).slice(0,Ax):[]}catch{return[]}}function H9(e){var t;try{return Number((t=localStorage.getItem(`${Sh}${e!=null?e:""}`))!=null?t:0)||0}catch{return}}function IP(e,t){try{localStorage.setItem(`${Sh}${e!=null?e:""}`,String(t))}catch{}}function F9(e){try{localStorage.setItem(DP,JSON.stringify(e.slice(0,Ax)))}catch{}}function kP(){var e,t;try{let n=JSON.parse((e=globalThis.sessionStorage.getItem(At.PRESENTER_VIEW))!=null?e:"{}"),r=n!==null&&typeof n=="object"?n:{};return{view:(t=zP.find(i=>i===r.view))!=null?t:"activity",runFocused:r.runFocused===!0}}catch{return{view:"activity",runFocused:!1}}}function bx(e){try{globalThis.sessionStorage.setItem(At.PRESENTER_VIEW,JSON.stringify(e))}catch{}}var zP,DP,Ax,k9,z9,D9,OP,PP,MP,bp,ps,_x,_a,UP,gx,CP,LP,$P,Al,HP,FP,BP,Ex,_n,Ei,Sp,yl,wo,Tp,Sa,wl,vl,fs,Nl,xp,Rl,Ta,vo,xa,No,hs,Aa,Ol,Il,ya,Ro,Cl,wa,Ll,Oo,Ap,yp,he,Sx,Tg,xg,Zr,Tx,Ag,_p,GP,xx,yg,wg=y(()=>{"use strict";M();pg();iT();Ct();Hr();Vr();di();bg();ha();zT();po();ux();RP();xo();zP=["flows","annotations","harness"],DP=At.ANNOTATION_HISTORY,Ax=200,k9="/settings?group=project",z9="#model",D9="/settings?group=billing",OP=2e4;PP=`${vP}
531
- <div data-reticle-harness-spot class="reticle-harness-spot" hidden></div>`,MP=`<section data-reticle-page-panel="flows" class="reticle-page-panel reticle-flows-view" role="region" aria-label="Saved Flows" hidden>
530
+ `,yg=class{constructor(){x(this,wl)}mount(t,n){var r;g(this,wl,t),(r=t.querySelector("[data-reticle-agent-copy]"))==null||r.addEventListener("click",o=>{var s;let i=o.currentTarget;(s=navigator.clipboard)==null||s.writeText(Tp.prompt(location.href)).catch(()=>{}).finally(()=>{i instanceof HTMLElement&&(i.textContent=ee.COPIED,window.setTimeout(()=>i.textContent=ee.COPY_PROMPT,gW))})},{signal:n})}teardown(){g(this,wl,void 0)}paint(t){var a;let n=c(this,wl),r=n==null?void 0:n.querySelector("[data-reticle-agent-spot]");if(n===void 0||r===null||r===void 0||(r.hidden=t===void 0,t===void 0))return;let o=0<t.agents.length;(a=r.querySelector(".reticle-agent-row"))==null||a.setAttribute("data-connected",o?"1":"0");let i=r.querySelector("[data-reticle-agent-said]");i!==null&&(i.textContent=o?Tp.named(t.agents.join(", ")):Tp.NONE);let s=r.querySelector("[data-reticle-agent-copy]");s!==null&&(s.hidden=o)}};wl=new WeakMap});function zx(e,t){let n=[SW(e==null?void 0:e.planUrl),e==null?void 0:e.platformUrl,t.host].find(r=>r!==void 0&&_r(r));return pe((n!=null?n:Gf).replace(/\/+$/,""))}function SW(e){if(!(e===void 0||!_r(e)))try{return new URL(e).origin}catch{return}}function TW(e){if(typeof e!="object"||e===null)return!1;let t=e;return typeof t.id=="string"&&typeof t.note=="string"&&typeof t.label=="string"&&typeof t.anchor=="string"&&typeof t.route=="string"&&typeof t.createdAt=="number"&&typeof t.pageUrl=="string"}function xW(){var e;try{let t=JSON.parse((e=localStorage.getItem(qP))!=null?e:"[]");return Array.isArray(t)?t.filter(TW).slice(0,kx):[]}catch{return[]}}function AW(e){var t;try{return Number((t=localStorage.getItem(`${vh}${e!=null?e:""}`))!=null?t:0)||0}catch{return}}function jP(e,t){try{localStorage.setItem(`${vh}${e!=null?e:""}`,String(t))}catch{}}function yW(e){try{localStorage.setItem(qP,JSON.stringify(e.slice(0,kx)))}catch{}}function YP(){var e,t;try{let n=JSON.parse((e=globalThis.sessionStorage.getItem(At.PRESENTER_VIEW))!=null?e:"{}"),r=n!==null&&typeof n=="object"?n:{};return{view:(t=XP.find(i=>i===r.view))!=null?t:"activity",runFocused:r.runFocused===!0}}catch{return{view:"activity",runFocused:!1}}}function Ox(e){try{globalThis.sessionStorage.setItem(At.PRESENTER_VIEW,JSON.stringify(e))}catch{}}var XP,qP,kx,EW,bW,_W,VP,JP,QP,xp,fs,Ix,Sa,eM,Nx,KP,ZP,WP,vl,tM,nM,rM,Rx,_n,Si,yp,Nl,No,wp,Ta,Rl,Ol,hs,Il,vp,Cl,xa,Ro,Aa,Oo,ms,ya,Ll,$l,wa,Io,kl,va,zl,Co,Np,Rp,me,Cx,wg,vg,Xr,Lx,Ng,Ap,oM,$x,Rg,Og=y(()=>{"use strict";M();gg();gT();Lt();Gr();Zr();hi();xg();ma();KT();ho();Tx();GP();yo();XP=["flows","annotations","harness"],qP=At.ANNOTATION_HISTORY,kx=200,EW="/settings?group=project",bW="#model",_W="/settings?group=billing",VP=2e4;JP=`${FP}
531
+ <div data-reticle-harness-spot class="reticle-harness-spot" hidden></div>`,QP=`<section data-reticle-page-panel="flows" class="reticle-page-panel reticle-flows-view" role="region" aria-label="Saved Flows" hidden>
532
532
  <div class="reticle-page-heading"><span class="reticle-page-titles"><strong>Saved flows</strong><span class="reticle-page-subtitle">Journeys your agent verified, replayable here</span></span><button type="button" data-reticle-page-close aria-label="Close Saved Flows" title="Close">\xD7</button></div>
533
533
  <div data-reticle-all-flows class="reticle-all-flows"></div>
534
- </section>`,bp=Ae.NAV,ps={LOG:"Log",FLOWS:"Flows",NOTES:"Notes",IMPACT:"Impact",HARNESS:"Harness",SETTINGS:"Settings",HIDE:"Hide"},_x={SEEN:"Open Impact",NEW:"Open Impact, new results"},_a=e=>`<span class="reticle-nav-label">${e}</span>`,UP=`<nav class="reticle-chat-nav" aria-label="Reticle views">
535
- <button type="button" ${Hm} data-reticle-chat-view-btn="activity" aria-label="Agent log" title="Agent log" aria-current="page">${Ie(se.MESSAGE,bp)}${_a(ps.LOG)}</button>
536
- <button type="button" data-reticle-chat-view-btn="harness" aria-label="${Ee.PAGE_TITLE}" title="${Ee.PAGE_TITLE}" hidden>${Ie(se.PLAY,bp)}${_a(ps.HARNESS)}</button>
537
- <button type="button" data-reticle-chat-view-btn="flows" aria-label="Saved flows" title="Saved flows">${Ie(se.LAYOUT,bp)}${_a(ps.FLOWS)}</button>
538
- <button type="button" data-reticle-chat-view-btn="annotations" aria-label="Notes" title="Notes">${Ie(se.NOTES,bp)}<span class="reticle-nav-label">${ps.NOTES}<span data-reticle-note-count class="reticle-nav-count" hidden></span></span></button>
539
- <button type="button" data-reticle-chat-impact class="reticle-chat-impact" aria-label="${_x.SEEN}" title="Impact">${Ie(se.CHART,bp)}${_a(ps.IMPACT)}<span data-reticle-impact-dot class="reticle-nav-dot" aria-hidden="true" hidden></span></button>
540
- </nav>`,gx=Ae.TOOLBAR,CP="Show note markers on the page",LP="Clear notes from this page",$P="Copy all notes",Al={SUBTITLE:"Feedback for your agent",SUBTITLE_FULL:"Pin feedback on the page for your agent",PAGE_EMPTY:"No notes on this page",PAGE_HINT:"Select Add notes, then click anything on the page to pin feedback for your agent.",HISTORY_EMPTY:"No saved notes yet",HISTORY_HINT:"Notes from every page you annotate are kept here."},HP=`<section data-reticle-page-panel="harness" class="reticle-page-panel reticle-harness-page" role="region" aria-label="${Ee.PAGE_TITLE}" hidden>
541
- <div class="reticle-page-heading"><span class="reticle-page-titles"><strong>${Ee.PAGE_TITLE}</strong><span class="reticle-page-subtitle">${Ee.PAGE_SUBTITLE}</span></span><button type="button" data-reticle-page-close aria-label="Close ${Ee.PAGE_TITLE}" title="Close">\xD7</button></div>
534
+ </section>`,xp=ye.NAV,fs={LOG:"Log",FLOWS:"Flows",NOTES:"Notes",IMPACT:"Impact",HARNESS:"Harness",SETTINGS:"Settings",HIDE:"Hide"},Ix={SEEN:"Open Impact",NEW:"Open Impact, new results"},Sa=e=>`<span class="reticle-nav-label">${e}</span>`,eM=`<nav class="reticle-chat-nav" aria-label="Reticle views">
535
+ <button type="button" ${Vm} data-reticle-chat-view-btn="activity" aria-label="Agent log" title="Agent log" aria-current="page">${Ce(se.MESSAGE,xp)}${Sa(fs.LOG)}</button>
536
+ <button type="button" data-reticle-chat-view-btn="harness" aria-label="${be.PAGE_TITLE}" title="${be.PAGE_TITLE}" hidden>${Ce(se.PLAY,xp)}${Sa(fs.HARNESS)}</button>
537
+ <button type="button" data-reticle-chat-view-btn="flows" aria-label="Saved flows" title="Saved flows">${Ce(se.LAYOUT,xp)}${Sa(fs.FLOWS)}</button>
538
+ <button type="button" data-reticle-chat-view-btn="annotations" aria-label="Notes" title="Notes">${Ce(se.NOTES,xp)}<span class="reticle-nav-label">${fs.NOTES}<span data-reticle-note-count class="reticle-nav-count" hidden></span></span></button>
539
+ <button type="button" data-reticle-chat-impact class="reticle-chat-impact" aria-label="${Ix.SEEN}" title="Impact">${Ce(se.CHART,xp)}${Sa(fs.IMPACT)}<span data-reticle-impact-dot class="reticle-nav-dot" aria-hidden="true" hidden></span></button>
540
+ </nav>`,Nx=ye.TOOLBAR,KP="Show note markers on the page",ZP="Clear notes from this page",WP="Copy all notes",vl={SUBTITLE:"Feedback for your agent",SUBTITLE_FULL:"Pin feedback on the page for your agent",PAGE_EMPTY:"No notes on this page",PAGE_HINT:"Select Add notes, then click anything on the page to pin feedback for your agent.",HISTORY_EMPTY:"No saved notes yet",HISTORY_HINT:"Notes from every page you annotate are kept here."},tM=`<section data-reticle-page-panel="harness" class="reticle-page-panel reticle-harness-page" role="region" aria-label="${be.PAGE_TITLE}" hidden>
541
+ <div class="reticle-page-heading"><span class="reticle-page-titles"><strong>${be.PAGE_TITLE}</strong><span class="reticle-page-subtitle">${be.PAGE_SUBTITLE}</span></span><button type="button" data-reticle-page-close aria-label="Close ${be.PAGE_TITLE}" title="Close">\xD7</button></div>
542
542
  <div data-reticle-harness-page class="reticle-harness-body"></div>
543
- ${aP}
544
- <div ${Eg} ${Lm}="${hn.HARNESS}" class="reticle-harness-log" aria-live="polite" aria-label="${Ee.LOG_LABEL}"></div>
543
+ ${xP}
544
+ <div ${Tg} ${Dm}="${hn.HARNESS}" class="reticle-harness-log" aria-live="polite" aria-label="${be.LOG_LABEL}"></div>
545
545
  <p data-reticle-harness-page-meta class="reticle-foot-meta"></p>
546
- </section>`,FP=`<section data-reticle-page-panel="annotations" class="reticle-page-panel reticle-annotations-view" role="region" aria-label="Notes" hidden>
547
- <div class="reticle-page-heading"><span class="reticle-page-titles"><strong>Notes</strong><span class="reticle-page-subtitle" title="${Al.SUBTITLE_FULL}">${Al.SUBTITLE}</span></span><button type="button" ${jm} class="reticle-add-notes reticle-primary-btn" title="Add notes" aria-label="Add notes" aria-pressed="false" data-active="0"><span class="reticle-add-notes-icon">${Ie(se.ANNOTATE,Ae.TOOLBAR)}</span><span data-reticle-notes-toggle-label>Add notes</span></button><button type="button" data-reticle-page-close aria-label="Close Notes" title="Close">\xD7</button></div>
546
+ </section>`,nM=`<section data-reticle-page-panel="annotations" class="reticle-page-panel reticle-annotations-view" role="region" aria-label="Notes" hidden>
547
+ <div class="reticle-page-heading"><span class="reticle-page-titles"><strong>Notes</strong><span class="reticle-page-subtitle" title="${vl.SUBTITLE_FULL}">${vl.SUBTITLE}</span></span><button type="button" ${Ym} class="reticle-add-notes reticle-primary-btn" title="Add notes" aria-label="Add notes" aria-pressed="false" data-active="0"><span class="reticle-add-notes-icon">${Ce(se.ANNOTATE,ye.TOOLBAR)}</span><span data-reticle-notes-toggle-label>Add notes</span></button><button type="button" data-reticle-page-close aria-label="Close Notes" title="Close">\xD7</button></div>
548
548
  <div class="reticle-annotations-tabs" role="group" aria-label="Notes lists">
549
549
  <span class="reticle-segmented"><button type="button" data-reticle-annotation-tab="current" aria-pressed="true">This page</button><button type="button" data-reticle-annotation-tab="history" aria-pressed="false">History</button></span>
550
550
  <div data-reticle-current-annotation-actions class="reticle-annotation-actions" aria-label="Current page note actions">
551
- <button type="button" ${Fm} class="reticle-annotation-icon-btn reticle-annotation-marker-toggle" title="${CP}" aria-label="${CP}" aria-pressed="false" data-active="0" disabled>${Om(se.VIEW,gx)}</button>
552
- <button type="button" ${Bm} class="reticle-annotation-icon-btn" title="${LP}" aria-label="${LP}" disabled>${Ie(se.TRASH,gx)}</button>
551
+ <button type="button" ${jm} class="reticle-annotation-icon-btn reticle-annotation-marker-toggle" title="${KP}" aria-label="${KP}" aria-pressed="false" data-active="0" disabled>${$m(se.VIEW,Nx)}</button>
552
+ <button type="button" ${Km} class="reticle-annotation-icon-btn" title="${ZP}" aria-label="${ZP}" disabled>${Ce(se.TRASH,Nx)}</button>
553
553
  </div>
554
- <button type="button" data-reticle-copy-all-notes class="reticle-annotation-icon-btn reticle-copy-all" title="${$P}" aria-label="${$P}">${Ie(se.COPY,gx)}</button>
554
+ <button type="button" data-reticle-copy-all-notes class="reticle-annotation-icon-btn reticle-copy-all" title="${WP}" aria-label="${WP}">${Ce(se.COPY,Nx)}</button>
555
555
  </div>
556
556
  <div data-reticle-annotation-list class="reticle-annotation-list"></div>
557
- </section>`,BP=`
558
- ${fx}
559
- ${fx.replaceAll("[data-reticle-chat-panel]",'[data-reticle-page-panel="harness"]')}
557
+ </section>`,rM=`
558
+ ${yx}
559
+ ${yx.replaceAll("[data-reticle-chat-panel]",'[data-reticle-page-panel="harness"]')}
560
560
  [data-reticle-page-panel="harness"] .reticle-harness-body{flex:none;display:flex;flex-direction:column;gap:var(--reticle-hud-space-2);padding:var(--reticle-hud-space-3);}
561
561
  /* The run as it happens, then its result: the Harness's rows only, scrolling under the controls. */
562
562
  [data-reticle-page-panel="harness"] .reticle-harness-log{flex:1;min-height:0;overflow-y:auto;padding:0 var(--reticle-hud-space-3) var(--reticle-hud-space-2);}
563
- [data-reticle-page-panel="harness"] .reticle-harness-log:empty::before{content:"${Ee.LOG_EMPTY}";display:block;padding:var(--reticle-hud-space-2) 0;color:var(--reticle-hud-text-faint);font-size:11px;}
563
+ [data-reticle-page-panel="harness"] .reticle-harness-log:empty::before{content:"${be.LOG_EMPTY}";display:block;padding:var(--reticle-hud-space-2) 0;color:var(--reticle-hud-text-faint);font-size:11px;}
564
564
  [data-reticle-page-panel="harness"] .reticle-foot-meta{flex:none;padding:0 var(--reticle-hud-space-3) var(--reticle-hud-space-3);}
565
565
  [data-reticle-page-open="harness"] [data-reticle-page-panel="harness"]{display:flex;}
566
566
  [data-reticle-page-open="harness"] [data-reticle-chat-panel]{display:none!important;}
@@ -581,7 +581,7 @@ ${fx.replaceAll("[data-reticle-chat-panel]",'[data-reticle-page-panel="harness"]
581
581
  /* New results since Impact was last opened: a dot on the icon's corner, out of the flow, so no number can push the label. */
582
582
  [data-reticle-hud] .reticle-chat-nav .reticle-nav-dot{position:absolute;top:4px;left:calc(50% + 5px);width:7px;height:7px;border-radius:50%;background:var(--reticle-hud-brand);box-shadow:0 0 0 2px var(--reticle-hud-surface);pointer-events:none;}
583
583
  [data-reticle-hud] .reticle-chat-nav .reticle-nav-dot[hidden]{display:none;}
584
- [data-reticle-page-panel]{position:absolute;right:0;left:auto;bottom:calc(100% + 8px);z-index:6;box-sizing:border-box;width:var(--reticle-dock-w);max-width:min(var(--reticle-dock-w),calc(100vw - 16px));height:min(var(--reticle-chat-max-h,var(--reticle-chat-h)),calc(100vh - 120px));max-height:min(var(--reticle-chat-max-h,var(--reticle-chat-h)),calc(100vh - 120px));flex-direction:column;overflow:hidden;border-radius:var(--reticle-hud-radius-lg);${cl}color:var(--reticle-hud-text);font-size:13px;line-height:1.5;pointer-events:auto;text-align:left;}
584
+ [data-reticle-page-panel]{position:absolute;right:0;left:auto;bottom:calc(100% + 8px);z-index:6;box-sizing:border-box;width:var(--reticle-dock-w);max-width:min(var(--reticle-dock-w),calc(100vw - 16px));height:min(var(--reticle-chat-max-h,var(--reticle-chat-h)),calc(100vh - 120px));max-height:min(var(--reticle-chat-max-h,var(--reticle-chat-h)),calc(100vh - 120px));flex-direction:column;overflow:hidden;border-radius:var(--reticle-hud-radius-lg);${dl}color:var(--reticle-hud-text);font-size:13px;line-height:1.5;pointer-events:auto;text-align:left;}
585
585
  [data-reticle-page-panel][hidden]{display:none!important;}
586
586
  [data-reticle-page-open="annotations"] [data-reticle-page-panel="annotations"],[data-reticle-page-open="flows"] [data-reticle-page-panel="flows"]{display:flex;}
587
587
  [data-reticle-page-open="annotations"] [data-reticle-chat-panel],[data-reticle-page-open="flows"] [data-reticle-chat-panel]{display:none!important;}
@@ -616,7 +616,7 @@ ${fx.replaceAll("[data-reticle-chat-panel]",'[data-reticle-page-panel="harness"]
616
616
  [data-reticle-page-panel="annotations"] .reticle-annotation-content span{display:block;margin-top:3px;font-size:var(--reticle-hud-size-xs);color:var(--reticle-hud-text-muted);overflow-wrap:anywhere;}
617
617
  [data-reticle-page-panel="annotations"] .reticle-annotation-item button{flex:none;border:1px solid var(--reticle-line);border-radius:6px;background:rgba(255,255,255,.04);color:var(--reticle-muted);font:inherit;font-size:11px;padding:4px 6px;cursor:pointer;}
618
618
  [data-reticle-page-panel="annotations"] .reticle-annotation-item button:hover{color:#fff;background:rgba(255,255,255,.1);}
619
- ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reticle-harness-stop])";yg=class{constructor(t,n,r){x(this,he);x(this,_n);x(this,Ei,kP().view);x(this,Sp,kP().runFocused);x(this,yl,!1);x(this,wo,"current");x(this,Tp,[]);x(this,Sa,U9());x(this,wl);x(this,vl);x(this,fs,0);x(this,Nl,!1);x(this,xp);x(this,Rl);x(this,Ta);x(this,vo);x(this,xa);x(this,No);x(this,hs,fg);x(this,Aa,"");x(this,Ol,"");x(this,Il,"");x(this,ya,!1);x(this,Ro);x(this,Cl,new Sg);x(this,wa);x(this,Ll);x(this,Oo);x(this,Ap);x(this,yp);g(this,xp,t),g(this,Rl,n),g(this,vo,r)}mount(t){var i,s,a,l,u,d,f;g(this,_n,t),g(this,Ta,new AbortController);let n=c(this,Ta).signal;t.querySelectorAll("[data-reticle-chat-view-btn]").forEach(m=>m.addEventListener("click",()=>{let h=m.getAttribute("data-reticle-chat-view-btn");c(this,Rl).call(this,h),this.open(h)},{signal:n})),(i=t.querySelector("[data-reticle-chat-impact]"))==null||i.addEventListener("click",()=>c(this,xp).call(this),{signal:n});let r=m=>{var v,N,O,k,j;let h=m.target;if(!(h instanceof Element))return;if(h.closest(`[${mg}]`)!==null){c(this,Rl).call(this,"harness"),this.open("harness");return}if(h.closest(`[${dx}]`)!==null){(v=c(this,vo))==null||v.setHarness(!0);return}let E=h.closest(`[${px}]`);if(E!==null){let Y=E.getAttribute("aria-checked")!=="true";E.setAttribute("aria-checked",String(Y)),(N=c(this,vo))==null||N.setHarness(Y);return}let _=h.closest(`[${mp}],[${ap}]:not([${qt}])`);if(_!==null){if(_.disabled)return;g(this,ya,!0),c(this,Ro)!==void 0&&clearTimeout(c(this,Ro)),g(this,Ro,setTimeout(()=>{g(this,Ro,void 0),g(this,ya,!1),T(this,he,Zr).call(this)},OP)),(O=c(this,vo))==null||O.link(),T(this,he,Zr).call(this);return}let A=h.closest("[data-reticle-harness-run]");if(A!==null){if(A.disabled)return;g(this,wa,c(this,hs)),g(this,yp,c(this,Ap)),T(this,he,Tg).call(this,!0),(k=c(this,vo))==null||k.run(dP(c(this,hs),c(this,Aa)));return}if(h.closest("[data-reticle-harness-stop]")!==null){(j=c(this,vo))==null||j.stop();return}};(s=t.querySelector("[data-reticle-harness-spot]"))==null||s.addEventListener("click",r,{signal:n}),(a=t.querySelector("[data-reticle-harness-page]"))==null||a.addEventListener("click",r,{signal:n}),(l=t.querySelector(`[${fl}]`))==null||l.addEventListener("click",r,{signal:n});let o=t.querySelector("[data-reticle-harness-page]");o==null||o.addEventListener("change",m=>{var _,A;let h=m.target;if(!(h instanceof HTMLSelectElement))return;let E=lx(h.value);E!==void 0&&(g(this,hs,E),hP(c(this,No),E),T(this,he,Zr).call(this),(A=(_=c(this,_n))==null?void 0:_.querySelector(`#${Sl}`))==null||A.focus())},{signal:n}),o==null||o.addEventListener("input",m=>{m.target instanceof HTMLInputElement&&g(this,Aa,m.target.value)},{signal:n}),c(this,Cl).mount(t,n),t.querySelectorAll("[data-reticle-annotation-tab]").forEach(m=>m.addEventListener("click",()=>{g(this,wo,m.getAttribute("data-reticle-annotation-tab")==="history"?"history":"current"),T(this,he,_p).call(this)},{signal:n})),(u=t.querySelector("[data-reticle-annotate-btn]"))==null||u.addEventListener("click",()=>{g(this,wo,"current"),T(this,he,_p).call(this)},{signal:n}),(d=t.querySelector("[data-reticle-copy-all-notes]"))==null||d.addEventListener("click",()=>T(this,he,GP).call(this),{signal:n}),t.querySelectorAll("[data-reticle-page-close]").forEach(m=>m.addEventListener("click",()=>this.closePage(),{signal:n})),(f=t.querySelector("[data-reticle-annotation-list]"))==null||f.addEventListener("click",m=>{let h=m.target;if(!(h instanceof Element))return;let E=h.closest("[data-reticle-copy-note]");if(E===null)return;let _=Number(E.getAttribute("data-reticle-copy-note"));if(!Number.isInteger(_))return;let A=T(this,he,Ag).call(this)[_];A!==void 0&&T(this,he,xx).call(this,[A],"pageUrl"in A?A.pageUrl:location.href)},{signal:n}),t.addEventListener("focusin",m=>T(this,he,Sx).call(this,m.target instanceof Element&&m.target.matches(Ex)),{signal:n}),t.addEventListener("focusout",m=>{let h=m.relatedTarget;T(this,he,Sx).call(this,h instanceof Element&&h.matches(Ex))},{signal:n}),this.open(c(this,Ei)),T(this,he,Zr).call(this),this.paintImpact(c(this,fs)),T(this,he,_p).call(this)}teardown(){var t;T(this,he,Tg).call(this,!1),(t=c(this,Ta))==null||t.abort(),g(this,Ta,void 0),g(this,_n,void 0),g(this,Ol,""),g(this,Il,""),c(this,Cl).teardown()}open(t){var o;if(t!=="activity"&&!zP.includes(t))return;g(this,Ei,t),bx({view:t,runFocused:c(this,yl)});let n=c(this,_n);if(n===void 0)return;t==="activity"?n.removeAttribute("data-reticle-page-open"):n.setAttribute("data-reticle-page-open",t);let r=n.querySelector("[data-reticle-chat-panel]");r!==null&&(r.hidden=t!=="activity"),n.querySelectorAll("[data-reticle-page-panel]").forEach(i=>{i.hidden=i.getAttribute("data-reticle-page-panel")!==t}),(o=c(this,_n))==null||o.querySelectorAll("[data-reticle-chat-view-btn]").forEach(i=>{i.getAttribute("data-reticle-chat-view-btn")===t?i.setAttribute("aria-current","page"):i.removeAttribute("aria-current")})}closePage(){let t=c(this,_n);t!==void 0&&(t.removeAttribute("data-reticle-page-open"),t.querySelectorAll("[data-reticle-page-panel]").forEach(n=>{n.hidden=!0}),g(this,Ei,"activity"),bx({view:"activity",runFocused:!1}),t.querySelectorAll("[data-reticle-chat-view-btn]").forEach(n=>{n.removeAttribute("aria-current")}))}setProjectId(t){g(this,No,t),g(this,hs,fP(t)),T(this,he,Zr).call(this),T(this,he,xg).call(this)}paintAgent(t){c(this,Cl).paint(t),T(this,he,Tx).call(this)}paintAccount(t){var r;g(this,wl,t);let n=(r=c(this,_n))==null?void 0:r.querySelector('[data-reticle-chat-view-btn="harness"]');n!=null&&(n.hidden=(t==null?void 0:t.signedIn)!==!0),T(this,he,Zr).call(this)}paintDrive(t,n){g(this,xa,t);let r=(n==null?void 0:n.runUrl)!==void 0&&Er(n.runUrl)?de(n.runUrl):void 0;g(this,Ll,n===void 0?void 0:{...r===void 0?{}:{runUrl:r},...n.said===void 0?{}:{said:n.said}}),g(this,Ap,n==null?void 0:n.seq);let o=(n==null?void 0:n.seq)!==void 0&&n.seq!==c(this,yp)&&c(this,Oo)!==void 0;(t!==void 0||o)&&T(this,he,Tg).call(this,!1),t===void 0&&c(this,Oo)===void 0&&g(this,wa,void 0),T(this,he,Zr).call(this)}paintHarness(t){t!==void 0&&(g(this,ya,!1),c(this,Ro)!==void 0&&clearTimeout(c(this,Ro)),g(this,Ro,void 0)),g(this,vl,t),T(this,he,Zr).call(this)}paintImpact(t){g(this,fs,t),c(this,Nl)&&IP(c(this,No),t),T(this,he,xg).call(this)}setImpactOpen(t){g(this,Nl,t),t&&IP(c(this,No),c(this,fs)),T(this,he,xg).call(this)}paintAnnotations(t){var i;g(this,Tp,[...t]);let n=location.href,r=new Map(c(this,Sa).map(s=>[s.id,s]));for(let s of t)r.set(s.id,{...s,pageUrl:n});g(this,Sa,[...r.values()].sort((s,a)=>a.createdAt-s.createdAt).slice(0,Ax)),F9(c(this,Sa));let o=(i=c(this,_n))==null?void 0:i.querySelector("[data-reticle-note-count]");o!=null&&(o.hidden=t.length===0,o.textContent=String(t.length)),T(this,he,_p).call(this)}};_n=new WeakMap,Ei=new WeakMap,Sp=new WeakMap,yl=new WeakMap,wo=new WeakMap,Tp=new WeakMap,Sa=new WeakMap,wl=new WeakMap,vl=new WeakMap,fs=new WeakMap,Nl=new WeakMap,xp=new WeakMap,Rl=new WeakMap,Ta=new WeakMap,vo=new WeakMap,xa=new WeakMap,No=new WeakMap,hs=new WeakMap,Aa=new WeakMap,Ol=new WeakMap,Il=new WeakMap,ya=new WeakMap,Ro=new WeakMap,Cl=new WeakMap,wa=new WeakMap,Ll=new WeakMap,Oo=new WeakMap,Ap=new WeakMap,yp=new WeakMap,he=new WeakSet,Sx=function(t){t!==c(this,yl)&&(g(this,yl,t),bx({view:c(this,Ei),runFocused:t}))},Tg=function(t){c(this,Oo)!==void 0&&clearTimeout(c(this,Oo)),g(this,Oo,t?setTimeout(()=>{g(this,Oo,void 0),c(this,xa)===void 0&&g(this,wa,void 0),T(this,he,Zr).call(this)},OP):void 0),t&&T(this,he,Zr).call(this)},xg=function(){var i;let t=(i=c(this,_n))==null?void 0:i.querySelector("[data-reticle-chat-impact]"),n=t==null?void 0:t.querySelector("[data-reticle-impact-dot]");if(t==null||n===void 0||n===null)return;let r=c(this,Nl)?c(this,fs):H9(c(this,No)),o=r!==void 0&&c(this,fs)>r;n.hidden=!o,t.setAttribute("aria-label",o?_x.NEW:_x.SEEN)},Zr=function(){let t=c(this,_n),n=t==null?void 0:t.querySelector("[data-reticle-harness-spot]");if(t===void 0||n===null||n===void 0)return;let r=c(this,wl),o=c(this,vl);n.hidden=!1;let i=yx(o,r!=null?r:{signedIn:!1}),s=c(this,No)===void 0?"":`&project=${encodeURIComponent(c(this,No))}`,a={account:r,config:o,drive:c(this,xa),canDrive:c(this,vo)!==void 0,pick:c(this,hs),startedAs:c(this,wa),setupUrl:`${i}${k9}${s}${z9}`,planUrl:(o==null?void 0:o.planUrl)!==void 0&&Er(o.planUrl)?de(o.planUrl):`${i}${D9}`,linking:c(this,ya),starting:c(this,Oo)!==void 0&&c(this,xa)===void 0,...c(this,Ll)===void 0?{}:{last:c(this,Ll)}},l=bP(a);l!==c(this,Ol)&&(sp(n,l),g(this,Ol,l)),r!==void 0&&!r.signedIn&&c(this,Ei)==="harness"&&this.closePage();let u=t.querySelector("[data-reticle-harness-page]");if(u!==null){let d=_P(a);d!==c(this,Il)&&(sp(u,d),g(this,Il,d));let f=c(this,Sp)?u.querySelector(Ex):null;f!==null&&c(this,Ei)==="harness"&&(g(this,Sp,!1),f.focus());let m=u.querySelector("[data-reticle-harness-persona]");m!==null&&m.value!==c(this,Aa)&&(m.value=c(this,Aa))}T(this,he,Tx).call(this)},Tx=function(){var r,o,i;let t=((r=c(this,wl))==null?void 0:r.signedIn)===!0,n=(o=c(this,_n))==null?void 0:o.querySelector("[data-reticle-harness-page-meta]");n!=null&&(n.textContent=t?EP((i=c(this,vl))==null?void 0:i.credits):"")},Ag=function(){return c(this,wo)==="history"?c(this,Sa):c(this,Tp)},_p=function(){let t=c(this,_n);if(t===void 0)return;let n=t.querySelector("[data-reticle-current-annotation-actions]");n!==null&&(n.hidden=c(this,wo)==="history"),t.querySelectorAll("[data-reticle-annotation-tab]").forEach(i=>i.setAttribute("aria-pressed",String(i.getAttribute("data-reticle-annotation-tab")===c(this,wo))));let r=t.querySelector("[data-reticle-annotation-list]");if(r===null)return;r.replaceChildren();let o=T(this,he,Ag).call(this);if(o.length===0){let i=document.createElement("div");i.className="reticle-annotation-empty";let s=document.createElement("strong"),a=document.createElement("span"),l=c(this,wo)==="history";s.textContent=l?Al.HISTORY_EMPTY:Al.PAGE_EMPTY,a.textContent=l?Al.HISTORY_HINT:Al.PAGE_HINT,i.append(s,a),r.appendChild(i);return}o.forEach((i,s)=>{let a=document.createElement("div");a.className="reticle-annotation-item";let l=document.createElement("div");l.className="reticle-annotation-content";let u=document.createElement("strong");u.textContent=i.note;let d=document.createElement("span");d.textContent=`${i.label} \xB7 ${i.route}${i.source===void 0?"":` \xB7 ${i.source}`}`,l.append(u,d);let f=document.createElement("button");f.type="button",f.textContent="Copy",f.setAttribute("data-reticle-copy-note",String(s)),a.append(l,f),r.appendChild(a)})},GP=function(){let t=T(this,he,Ag).call(this);t.length>0&&T(this,he,xx).call(this,t,c(this,wo)==="history"?location.origin:location.href)},xx=function(t,n){var r;(r=navigator.clipboard)==null||r.writeText(Am(t,n)).catch(()=>{})}});function W9(e){let{name:t,done:n,total:r,status:o}=e;if(!(typeof t!="string"||typeof n!="number"||typeof r!="number")&&Object.values(mc).includes(o))return{name:t,done:n,total:r,status:o}}function q9(e){let t=e.replace(/[-_]+/g," ").trim();return t.length===0?e:t.charAt(0).toUpperCase()+t.slice(1)}function ZP(e,t){let n=t?se.PLAY:se.PAUSE,r=t?$l.RESUME:$l.PAUSE;e.setAttribute("aria-label",r),e.setAttribute("title",r),e.replaceChildren(So(n,Ae.TOOLBAR)),e.classList.toggle("reticle-tb-btn--primary",t),e.setAttribute("data-active",t?"1":"0")}function J9(e){var t,n,r,o,i,s,a;return{pauseBtn:(t=e.querySelector("[data-reticle-pause]"))!=null?t:void 0,endBtn:(n=e.querySelector("[data-reticle-end]"))!=null?n:void 0,banner:(r=e.querySelector("[data-reticle-banner]"))!=null?r:void 0,copyBtn:(o=e.querySelector("[data-reticle-copy]"))!=null?o:void 0,exportBtn:(i=e.querySelector("[data-reticle-export]"))!=null?i:void 0,exportMsg:(s=e.querySelector("[data-reticle-export-msg]"))!=null?s:void 0,allFlows:(a=e.querySelector("[data-reticle-all-flows]"))!=null?a:void 0}}var B9,VP,G9,V9,$l,j9,YP,jP,KP,K9,Z9,Y9,X9,XP,vg,qP,WP,Ng,JP,QP,eM,tM,In,bi,Io,va,wp,kl,zl,Dl,Pl,Na,qn,ht,wx,nM,rM,oM,iM,Rg,Og,Ig,vx=y(()=>{"use strict";Ot();M();dt();Ct();Hr();gl();nx();wg();B9="data-reticle-state",VP="data-reticle-tone",G9="data-on",V9="0",$l={PAUSE:"Pause",RESUME:"Resume",END:"End",SEND:"Send"},j9="PAUSED",YP="Session ended",jP="Copy run",KP="Export",K9=6e3,Z9={[mc.PLAYING]:"\u23F5",[mc.PASSED]:"\u2713",[mc.FAILED]:"\u2717"};Y9="Copied \u2713",X9="reticle-run.json",XP=4e3,vg={REPLAYABLE:"Replay without an agent",ELSEWHERE:"Starts on another page",EMPTY_TITLE:"No saved flows yet",EMPTY_HINT:"Every journey your agent verifies is saved here, ready to replay in one click."};qP=`
619
+ ${BP}`,Rx="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reticle-harness-stop])";Rg=class{constructor(t,n,r){x(this,me);x(this,_n);x(this,Si,YP().view);x(this,yp,YP().runFocused);x(this,Nl,!1);x(this,No,"current");x(this,wp,[]);x(this,Ta,xW());x(this,Rl);x(this,Ol);x(this,hs,0);x(this,Il,!1);x(this,vp);x(this,Cl);x(this,xa);x(this,Ro);x(this,Aa);x(this,Oo);x(this,ms,Eg);x(this,ya,"");x(this,Ll,"");x(this,$l,"");x(this,wa,!1);x(this,Io);x(this,kl,new yg);x(this,va);x(this,zl);x(this,Co);x(this,Np);x(this,Rp);g(this,vp,t),g(this,Cl,n),g(this,Ro,r)}mount(t){var i,s,a,l,u,d,f;g(this,_n,t),g(this,xa,new AbortController);let n=c(this,xa).signal;t.querySelectorAll("[data-reticle-chat-view-btn]").forEach(m=>m.addEventListener("click",()=>{let h=m.getAttribute("data-reticle-chat-view-btn");c(this,Cl).call(this,h),this.open(h)},{signal:n})),(i=t.querySelector("[data-reticle-chat-impact]"))==null||i.addEventListener("click",()=>c(this,vp).call(this),{signal:n});let r=m=>{var w,N,O,k,G;let h=m.target;if(!(h instanceof Element))return;if(h.closest(`[${_g}]`)!==null){c(this,Cl).call(this,"harness"),this.open("harness");return}if(h.closest(`[${xx}]`)!==null){(w=c(this,Ro))==null||w.setHarness(!0);return}let E=h.closest(`[${Ax}]`);if(E!==null){let V=E.getAttribute("aria-checked")!=="true";E.setAttribute("aria-checked",String(V)),(N=c(this,Ro))==null||N.setHarness(V);return}let S=h.closest(`[${_p}],[${dp}]:not([${qt}])`);if(S!==null){if(S.disabled)return;g(this,wa,!0),c(this,Io)!==void 0&&clearTimeout(c(this,Io)),g(this,Io,setTimeout(()=>{g(this,Io,void 0),g(this,wa,!1),T(this,me,Xr).call(this)},VP)),(O=c(this,Ro))==null||O.link(),T(this,me,Xr).call(this);return}let A=h.closest("[data-reticle-harness-run]");if(A!==null){if(A.disabled)return;g(this,va,c(this,ms)),g(this,Rp,c(this,Np)),T(this,me,wg).call(this,!0),(k=c(this,Ro))==null||k.run(vP(c(this,ms),c(this,ya)));return}if(h.closest("[data-reticle-harness-stop]")!==null){(G=c(this,Ro))==null||G.stop();return}};(s=t.querySelector("[data-reticle-harness-spot]"))==null||s.addEventListener("click",r,{signal:n}),(a=t.querySelector("[data-reticle-harness-page]"))==null||a.addEventListener("click",r,{signal:n}),(l=t.querySelector(`[${gl}]`))==null||l.addEventListener("click",r,{signal:n});let o=t.querySelector("[data-reticle-harness-page]");o==null||o.addEventListener("change",m=>{var S,A;let h=m.target;if(!(h instanceof HTMLSelectElement))return;let E=Sx(h.value);E!==void 0&&(g(this,ms,E),OP(c(this,Oo),E),T(this,me,Xr).call(this),(A=(S=c(this,_n))==null?void 0:S.querySelector(`#${Al}`))==null||A.focus())},{signal:n}),o==null||o.addEventListener("input",m=>{m.target instanceof HTMLInputElement&&g(this,ya,m.target.value)},{signal:n}),c(this,kl).mount(t,n),t.querySelectorAll("[data-reticle-annotation-tab]").forEach(m=>m.addEventListener("click",()=>{g(this,No,m.getAttribute("data-reticle-annotation-tab")==="history"?"history":"current"),T(this,me,Ap).call(this)},{signal:n})),(u=t.querySelector("[data-reticle-annotate-btn]"))==null||u.addEventListener("click",()=>{g(this,No,"current"),T(this,me,Ap).call(this)},{signal:n}),(d=t.querySelector("[data-reticle-copy-all-notes]"))==null||d.addEventListener("click",()=>T(this,me,oM).call(this),{signal:n}),t.querySelectorAll("[data-reticle-page-close]").forEach(m=>m.addEventListener("click",()=>this.closePage(),{signal:n})),(f=t.querySelector("[data-reticle-annotation-list]"))==null||f.addEventListener("click",m=>{let h=m.target;if(!(h instanceof Element))return;let E=h.closest("[data-reticle-copy-note]");if(E===null)return;let S=Number(E.getAttribute("data-reticle-copy-note"));if(!Number.isInteger(S))return;let A=T(this,me,Ng).call(this)[S];A!==void 0&&T(this,me,$x).call(this,[A],"pageUrl"in A?A.pageUrl:location.href)},{signal:n}),t.addEventListener("focusin",m=>T(this,me,Cx).call(this,m.target instanceof Element&&m.target.matches(Rx)),{signal:n}),t.addEventListener("focusout",m=>{let h=m.relatedTarget;T(this,me,Cx).call(this,h instanceof Element&&h.matches(Rx))},{signal:n}),this.open(c(this,Si)),T(this,me,Xr).call(this),this.paintImpact(c(this,hs)),T(this,me,Ap).call(this)}teardown(){var t;T(this,me,wg).call(this,!1),(t=c(this,xa))==null||t.abort(),g(this,xa,void 0),g(this,_n,void 0),g(this,Ll,""),g(this,$l,""),c(this,kl).teardown()}open(t){var o;if(t!=="activity"&&!XP.includes(t))return;g(this,Si,t),Ox({view:t,runFocused:c(this,Nl)});let n=c(this,_n);if(n===void 0)return;t==="activity"?n.removeAttribute("data-reticle-page-open"):n.setAttribute("data-reticle-page-open",t);let r=n.querySelector("[data-reticle-chat-panel]");r!==null&&(r.hidden=t!=="activity"),n.querySelectorAll("[data-reticle-page-panel]").forEach(i=>{i.hidden=i.getAttribute("data-reticle-page-panel")!==t}),(o=c(this,_n))==null||o.querySelectorAll("[data-reticle-chat-view-btn]").forEach(i=>{i.getAttribute("data-reticle-chat-view-btn")===t?i.setAttribute("aria-current","page"):i.removeAttribute("aria-current")})}closePage(){let t=c(this,_n);t!==void 0&&(t.removeAttribute("data-reticle-page-open"),t.querySelectorAll("[data-reticle-page-panel]").forEach(n=>{n.hidden=!0}),g(this,Si,"activity"),Ox({view:"activity",runFocused:!1}),t.querySelectorAll("[data-reticle-chat-view-btn]").forEach(n=>{n.removeAttribute("aria-current")}))}setProjectId(t){g(this,Oo,t),g(this,ms,RP(t)),T(this,me,Xr).call(this),T(this,me,vg).call(this)}paintAgent(t){c(this,kl).paint(t),T(this,me,Lx).call(this)}paintAccount(t){var r;g(this,Rl,t);let n=(r=c(this,_n))==null?void 0:r.querySelector('[data-reticle-chat-view-btn="harness"]');n!=null&&(n.hidden=(t==null?void 0:t.signedIn)!==!0),T(this,me,Xr).call(this)}paintDrive(t,n){g(this,Aa,t);let r=(n==null?void 0:n.runUrl)!==void 0&&_r(n.runUrl)?pe(n.runUrl):void 0;g(this,zl,n===void 0?void 0:{...r===void 0?{}:{runUrl:r},...n.said===void 0?{}:{said:n.said}}),g(this,Np,n==null?void 0:n.seq);let o=(n==null?void 0:n.seq)!==void 0&&n.seq!==c(this,Rp)&&c(this,Co)!==void 0;(t!==void 0||o)&&T(this,me,wg).call(this,!1),t===void 0&&c(this,Co)===void 0&&g(this,va,void 0),T(this,me,Xr).call(this)}paintHarness(t){t!==void 0&&(g(this,wa,!1),c(this,Io)!==void 0&&clearTimeout(c(this,Io)),g(this,Io,void 0)),g(this,Ol,t),T(this,me,Xr).call(this)}paintImpact(t){g(this,hs,t),c(this,Il)&&jP(c(this,Oo),t),T(this,me,vg).call(this)}setImpactOpen(t){g(this,Il,t),t&&jP(c(this,Oo),c(this,hs)),T(this,me,vg).call(this)}paintAnnotations(t){var i;g(this,wp,[...t]);let n=location.href,r=new Map(c(this,Ta).map(s=>[s.id,s]));for(let s of t)r.set(s.id,{...s,pageUrl:n});g(this,Ta,[...r.values()].sort((s,a)=>a.createdAt-s.createdAt).slice(0,kx)),yW(c(this,Ta));let o=(i=c(this,_n))==null?void 0:i.querySelector("[data-reticle-note-count]");o!=null&&(o.hidden=t.length===0,o.textContent=String(t.length)),T(this,me,Ap).call(this)}};_n=new WeakMap,Si=new WeakMap,yp=new WeakMap,Nl=new WeakMap,No=new WeakMap,wp=new WeakMap,Ta=new WeakMap,Rl=new WeakMap,Ol=new WeakMap,hs=new WeakMap,Il=new WeakMap,vp=new WeakMap,Cl=new WeakMap,xa=new WeakMap,Ro=new WeakMap,Aa=new WeakMap,Oo=new WeakMap,ms=new WeakMap,ya=new WeakMap,Ll=new WeakMap,$l=new WeakMap,wa=new WeakMap,Io=new WeakMap,kl=new WeakMap,va=new WeakMap,zl=new WeakMap,Co=new WeakMap,Np=new WeakMap,Rp=new WeakMap,me=new WeakSet,Cx=function(t){t!==c(this,Nl)&&(g(this,Nl,t),Ox({view:c(this,Si),runFocused:t}))},wg=function(t){c(this,Co)!==void 0&&clearTimeout(c(this,Co)),g(this,Co,t?setTimeout(()=>{g(this,Co,void 0),c(this,Aa)===void 0&&g(this,va,void 0),T(this,me,Xr).call(this)},VP):void 0),t&&T(this,me,Xr).call(this)},vg=function(){var i;let t=(i=c(this,_n))==null?void 0:i.querySelector("[data-reticle-chat-impact]"),n=t==null?void 0:t.querySelector("[data-reticle-impact-dot]");if(t==null||n===void 0||n===null)return;let r=c(this,Il)?c(this,hs):AW(c(this,Oo)),o=r!==void 0&&c(this,hs)>r;n.hidden=!o,t.setAttribute("aria-label",o?Ix.NEW:Ix.SEEN)},Xr=function(){let t=c(this,_n),n=t==null?void 0:t.querySelector("[data-reticle-harness-spot]");if(t===void 0||n===null||n===void 0)return;let r=c(this,Rl),o=c(this,Ol);n.hidden=!1;let i=zx(o,r!=null?r:{signedIn:!1}),s=c(this,Oo)===void 0?"":`&project=${encodeURIComponent(c(this,Oo))}`,a={account:r,config:o,drive:c(this,Aa),canDrive:c(this,Ro)!==void 0,pick:c(this,ms),startedAs:c(this,va),setupUrl:`${i}${EW}${s}${bW}`,planUrl:(o==null?void 0:o.planUrl)!==void 0&&_r(o.planUrl)?pe(o.planUrl):`${i}${_W}`,linking:c(this,wa),starting:c(this,Co)!==void 0&&c(this,Aa)===void 0,...c(this,zl)===void 0?{}:{last:c(this,zl)}},l=$P(a);l!==c(this,Ll)&&(up(n,l),g(this,Ll,l)),r!==void 0&&!r.signedIn&&c(this,Si)==="harness"&&this.closePage();let u=t.querySelector("[data-reticle-harness-page]");if(u!==null){let d=kP(a);d!==c(this,$l)&&(up(u,d),g(this,$l,d));let f=c(this,yp)?u.querySelector(Rx):null;f!==null&&c(this,Si)==="harness"&&(g(this,yp,!1),f.focus());let m=u.querySelector("[data-reticle-harness-persona]");m!==null&&m.value!==c(this,ya)&&(m.value=c(this,ya))}T(this,me,Lx).call(this)},Lx=function(){var r,o,i;let t=((r=c(this,Rl))==null?void 0:r.signedIn)===!0,n=(o=c(this,_n))==null?void 0:o.querySelector("[data-reticle-harness-page-meta]");n!=null&&(n.textContent=t?LP((i=c(this,Ol))==null?void 0:i.credits):"")},Ng=function(){return c(this,No)==="history"?c(this,Ta):c(this,wp)},Ap=function(){let t=c(this,_n);if(t===void 0)return;let n=t.querySelector("[data-reticle-current-annotation-actions]");n!==null&&(n.hidden=c(this,No)==="history"),t.querySelectorAll("[data-reticle-annotation-tab]").forEach(i=>i.setAttribute("aria-pressed",String(i.getAttribute("data-reticle-annotation-tab")===c(this,No))));let r=t.querySelector("[data-reticle-annotation-list]");if(r===null)return;r.replaceChildren();let o=T(this,me,Ng).call(this);if(o.length===0){let i=document.createElement("div");i.className="reticle-annotation-empty";let s=document.createElement("strong"),a=document.createElement("span"),l=c(this,No)==="history";s.textContent=l?vl.HISTORY_EMPTY:vl.PAGE_EMPTY,a.textContent=l?vl.HISTORY_HINT:vl.PAGE_HINT,i.append(s,a),r.appendChild(i);return}o.forEach((i,s)=>{let a=document.createElement("div");a.className="reticle-annotation-item";let l=document.createElement("div");l.className="reticle-annotation-content";let u=document.createElement("strong");u.textContent=i.note;let d=document.createElement("span");d.textContent=`${i.label} \xB7 ${i.route}${i.source===void 0?"":` \xB7 ${i.source}`}`,l.append(u,d);let f=document.createElement("button");f.type="button",f.textContent="Copy",f.setAttribute("data-reticle-copy-note",String(s)),a.append(l,f),r.appendChild(a)})},oM=function(){let t=T(this,me,Ng).call(this);t.length>0&&T(this,me,$x).call(this,t,c(this,No)==="history"?location.origin:location.href)},$x=function(t,n){var r;(r=navigator.clipboard)==null||r.writeText(Nm(t,n)).catch(()=>{})}});function CW(e){let{name:t,done:n,total:r,status:o}=e;if(!(typeof t!="string"||typeof n!="number"||typeof r!="number")&&Object.values(Ec).includes(o))return{name:t,done:n,total:r,status:o}}function kW(e){let t=e.replace(/[-_]+/g," ").trim();return t.length===0?e:t.charAt(0).toUpperCase()+t.slice(1)}function cM(e,t){let n=t?se.PLAY:se.PAUSE,r=t?Dl.RESUME:Dl.PAUSE;e.setAttribute("aria-label",r),e.setAttribute("title",r),e.replaceChildren(xo(n,ye.TOOLBAR)),e.classList.toggle("reticle-tb-btn--primary",t),e.setAttribute("data-active",t?"1":"0")}function zW(e){var t,n,r,o,i,s,a;return{pauseBtn:(t=e.querySelector("[data-reticle-pause]"))!=null?t:void 0,endBtn:(n=e.querySelector("[data-reticle-end]"))!=null?n:void 0,banner:(r=e.querySelector("[data-reticle-banner]"))!=null?r:void 0,copyBtn:(o=e.querySelector("[data-reticle-copy]"))!=null?o:void 0,exportBtn:(i=e.querySelector("[data-reticle-export]"))!=null?i:void 0,exportMsg:(s=e.querySelector("[data-reticle-export-msg]"))!=null?s:void 0,allFlows:(a=e.querySelector("[data-reticle-all-flows]"))!=null?a:void 0}}var wW,iM,vW,NW,Dl,RW,uM,sM,aM,OW,IW,LW,$W,dM,Ig,pM,lM,Cg,fM,hM,mM,gM,Cn,Ti,Lo,Na,Op,Pl,Ml,Ul,Hl,Ra,qn,ht,Dx,EM,bM,_M,SM,Lg,$g,kg,Px=y(()=>{"use strict";It();M();dt();Lt();Gr();_l();fx();Og();wW="data-reticle-state",iM="data-reticle-tone",vW="data-on",NW="0",Dl={PAUSE:"Pause",RESUME:"Resume",END:"End",SEND:"Send"},RW="PAUSED",uM="Session ended",sM="Copy run",aM="Export",OW=6e3,IW={[Ec.PLAYING]:"\u23F5",[Ec.PASSED]:"\u2713",[Ec.FAILED]:"\u2717"};LW="Copied \u2713",$W="reticle-run.json",dM=4e3,Ig={REPLAYABLE:"Replay without an agent",ELSEWHERE:"Starts on another page",EMPTY_TITLE:"No saved flows yet",EMPTY_HINT:"Every journey your agent verifies is saved here, ready to replay in one click."};pM=`
620
620
  [data-reticle-chat-panel] [data-reticle-foot]{flex:none;padding:6px 10px 8px;border-top:1px solid rgba(255,255,255,.07);
621
621
  background:linear-gradient(180deg,rgba(0,0,0,.35) 0%,rgba(0,0,0,.55) 100%);pointer-events:auto;}
622
622
  [data-reticle-chat-panel] .reticle-foot-workspace-row{display:flex;flex-wrap:wrap;align-items:center;min-width:0;}
@@ -719,7 +719,7 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
719
719
  [data-reticle-chat-panel] .reticle-marks-copy[data-copied="1"]{color:#22c55e;border-color:#22c55e;}
720
720
  [data-reticle-hud] .reticle-export-msg{position:absolute;width:1px;height:1px;margin:-1px;padding:0;
721
721
  overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0;}
722
- `;WP="Copy for your agent",Ng=Ae.TOOLBAR,JP=`<button type="button" data-reticle-pause class="reticle-status-btn" title="${$l.PAUSE}" aria-label="${$l.PAUSE}">${Ie(se.PAUSE,Ng)}</button><span data-reticle-badge class="reticle-pause-badge">${j9}</span><button type="button" data-reticle-end class="reticle-status-btn reticle-status-stop" title="${$l.END}" aria-label="${$l.END}">${Ie(se.STOP,Ng)}</button><button type="button" data-reticle-copy class="reticle-status-btn" title="${jP}" aria-label="${jP}" hidden>${Ie(se.COPY,Ng)}</button><button type="button" data-reticle-export class="reticle-status-btn" title="${KP}" aria-label="${KP}" hidden>${Ie(se.DOWNLOAD,Ng)}</button><span data-reticle-export-msg class="reticle-export-msg" aria-live="polite"></span>`,QP=`<div data-reticle-banner class="reticle-banner">${YP}</div>`,eM=`<div ${Vm} class="reticle-marks-row" hidden><span data-reticle-marks-text class="reticle-marks-text"></span><button type="button" ${Gm} class="reticle-marks-copy" title="${WP}">${Ie(se.COPY,Ae.HELP)}<span>${WP}</span></button></div>`,tM=`<div data-reticle-foot><div class="reticle-foot-stack">${PP}<div class="reticle-foot-workspace-row">${eP()}</div></div></div>`;Ig=class{constructor(t){x(this,ht);x(this,In,{pauseBtn:void 0,endBtn:void 0,banner:void 0,copyBtn:void 0,exportBtn:void 0,exportMsg:void 0,allFlows:void 0});x(this,bi,Xe.ACTIVE);x(this,Io);x(this,va);x(this,wp);x(this,kl,[]);x(this,zl);x(this,Dl);x(this,Pl);x(this,Na);x(this,qn);g(this,qn,t)}get state(){return c(this,bi)}mount(t,n){var s,a,l,u,d;g(this,Na,new AbortController);let{signal:r}=c(this,Na);g(this,va,t),g(this,wp,n),g(this,In,J9(t));let o=c(this,In).pauseBtn;o!==void 0&&ZP(o,c(this,bi)===Xe.PAUSED),(s=c(this,In).pauseBtn)==null||s.addEventListener("click",()=>T(this,ht,oM).call(this),{signal:r}),(a=c(this,In).endBtn)==null||a.addEventListener("click",()=>T(this,ht,iM).call(this),{signal:r});let i=f=>{let m=f.target;if(!(m instanceof HTMLElement))return;let h=m.closest("[data-reticle-replay]");if(h===null||h.disabled)return;let E=h.getAttribute("data-reticle-replay");E!==null&&E.length>0&&c(this,qn).emit(ln.REPLAY,E)};(l=c(this,In).allFlows)==null||l.addEventListener("click",i,{signal:r}),(u=c(this,In).copyBtn)==null||u.addEventListener("click",()=>T(this,ht,nM).call(this),{signal:r}),(d=c(this,In).exportBtn)==null||d.addEventListener("click",()=>T(this,ht,rM).call(this),{signal:r}),g(this,Pl,tP(t)),T(this,ht,Og).call(this),this.setState(Xe.ACTIVE)}teardown(){var t,n;(t=c(this,Na))==null||t.abort(),g(this,Na,void 0),(n=c(this,Pl))==null||n.call(this),g(this,Pl,void 0),c(this,Io)!==void 0&&Re(c(this,Io)),g(this,Io,void 0)}setFlowProgress(t){let n=W9(t);n!==void 0&&(g(this,zl,n),c(this,Dl)!==void 0&&Re(c(this,Dl)),g(this,Dl,mc.PLAYING===n.status?void 0:ue(()=>{g(this,zl,void 0),T(this,ht,Rg).call(this)},K9)),T(this,ht,Rg).call(this))}setFlows(t){let n=Array.isArray(t)?t:[];g(this,kl,n.map(r=>{if(typeof r=="string")return r.length>0?{name:r}:null;if(typeof r=="object"&&r!==null){let o=r,i=o.name;if(typeof i!="string"||i.length===0)return null;let s=o.start,a=o.createdAt;return{name:i,...typeof s=="string"&&s.length>0?{start:s}:{},...typeof a=="number"&&Number.isFinite(a)?{createdAt:a}:{}}}return null}).filter(r=>r!==null)),T(this,ht,Og).call(this)}refilterFlows(){T(this,ht,Og).call(this)}setState(t,n,r){var a,l,u,d,f;g(this,bi,t),(a=c(this,va))==null||a.setAttribute(B9,t);let o=r!==void 0&&r!==Ec.CALM;o?(l=c(this,va))==null||l.setAttribute(VP,r):(u=c(this,va))==null||u.removeAttribute(VP),c(this,Io)!==void 0&&(Re(c(this,Io)),g(this,Io,void 0));let i=c(this,In),s=t===Xe.ENDED;if(i.pauseBtn!==void 0&&(ZP(i.pauseBtn,t===Xe.PAUSED),i.pauseBtn.hidden=s),i.endBtn!==void 0&&(i.endBtn.hidden=s),i.copyBtn!==void 0&&(s?i.copyBtn.removeAttribute("hidden"):i.copyBtn.setAttribute("hidden","")),i.exportBtn!==void 0&&(s?i.exportBtn.removeAttribute("hidden"):i.exportBtn.setAttribute("hidden","")),i.banner!==void 0){let m=n!==void 0&&n.trim().length>0?n.trim():"";i.banner.textContent=o&&m.length>0?m:`${YP}${m.length>0?` \xB7 ${m}`:""}`}if(s){let m=c(this,wp);g(this,Io,ue(()=>{m==null||m.setAttribute(G9,V9)},c(this,qn).endedFadeMs))}(f=(d=c(this,qn)).onStateChange)==null||f.call(d,t)}};In=new WeakMap,bi=new WeakMap,Io=new WeakMap,va=new WeakMap,wp=new WeakMap,kl=new WeakMap,zl=new WeakMap,Dl=new WeakMap,Pl=new WeakMap,Na=new WeakMap,qn=new WeakMap,ht=new WeakSet,wx=function(){return JSON.stringify(c(this,qn).runState(),null,2)},nM=function(){var n,r,o;(n=navigator.clipboard)==null||n.writeText(T(this,ht,wx).call(this)),Tr().clearOnCopy&&((o=(r=c(this,qn)).clearRunLog)==null||o.call(r));let t=c(this,In).exportMsg;t!==void 0&&(t.textContent=Y9,t.setAttribute("data-show","1"),ue(()=>t.setAttribute("data-show","0"),1600))},rM=function(){var o,i;let t=new Blob([T(this,ht,wx).call(this)],{type:"application/json"}),n=URL.createObjectURL(t),r=document.createElement("a");r.href=n,r.download=X9,r.click(),URL.revokeObjectURL(n),Tr().clearOnCopy&&((i=(o=c(this,qn)).clearRunLog)==null||i.call(o))},oM=function(){c(this,bi)===Xe.PAUSED?(c(this,qn).emit(ln.RESUME),this.setState(Xe.ACTIVE)):c(this,bi)===Xe.ACTIVE&&(c(this,qn).emit(ln.PAUSE),this.setState(Xe.PAUSED))},iM=function(){c(this,bi)!==Xe.ENDED&&(c(this,qn).emit(ln.END),this.setState(Xe.ENDED))},Rg=function(){var n,r,o;let t=c(this,zl);for(let i of(r=(n=c(this,In).allFlows)==null?void 0:n.querySelectorAll("[data-reticle-replay]"))!=null?r:[]){let s=(o=i.getAttribute("data-reticle-replay"))!=null?o:"";if(!(t!==void 0&&t.name===s)){i.removeAttribute("data-state"),i.style.removeProperty("--reticle-flow-progress"),i.classList.contains("reticle-flow")&&(i.textContent=`\u25B6 ${s}`);continue}let l=0<t.total?Math.round(100*t.done/t.total):4;i.setAttribute("data-state",t.status),i.style.setProperty("--reticle-flow-progress",`${String(Math.max(4,l))}%`);let u=Z9[t.status];i.classList.contains("reticle-flow")&&(i.textContent=`${u} ${s}`);let d=i.querySelector(".reticle-flow-play");d!==null&&(d.textContent=u);let f=i.querySelector(".reticle-flow-meta");f!==null&&0<t.total&&(f.textContent=`Step ${String(t.done)} of ${String(t.total)}`)}},Og=function(){let t=c(this,In).allFlows;if(t===void 0)return;let n=t.ownerDocument,r=new Set(Array.from(n.querySelectorAll(Vn())).map(s=>Ne(s))),o=s=>s.start===void 0||r.has(s.start);t.replaceChildren();let i=(s,a,l)=>{let u=n.createElement("button");u.type="button",u.className="reticle-flow-row",u.setAttribute("data-reticle-replay",a.name),u.title=a.name,u.disabled=!l;let d=n.createElement("span");d.className="reticle-flow-play",d.setAttribute("aria-hidden","true"),d.textContent="\u25B6";let f=n.createElement("span");f.className="reticle-flow-text";let m=n.createElement("span");m.className="reticle-flow-name",m.textContent=q9(a.name);let h=n.createElement("span");h.className="reticle-flow-meta",h.textContent=l?vg.REPLAYABLE:vg.ELSEWHERE,f.append(m,h),u.append(d,f),s.appendChild(u)};if(c(this,kl).length===0){let s=n.createElement("div");s.className="reticle-flows-empty";let a=n.createElement("strong");a.textContent=vg.EMPTY_TITLE;let l=n.createElement("span");l.textContent=vg.EMPTY_HINT,s.append(a,l),t.appendChild(s)}else for(let s of[...c(this,kl)].sort((a,l)=>{var u,d;return((u=l.createdAt)!=null?u:0)-((d=a.createdAt)!=null?d:0)}))i(t,s,o(s));T(this,ht,Rg).call(this)}});var ge,K,ce,Wr,Nx,sM,aM=y(()=>{"use strict";di();Ct();Ct();Vr();ge="data-reticle-overlay",K="data-reticle-hud",ce="data-reticle-chat-panel",Wr="data-reticle-state",Nx="data-reticle-tone",sM=`
722
+ `;lM="Copy for your agent",Cg=ye.TOOLBAR,fM=`<button type="button" data-reticle-pause class="reticle-status-btn" title="${Dl.PAUSE}" aria-label="${Dl.PAUSE}">${Ce(se.PAUSE,Cg)}</button><span data-reticle-badge class="reticle-pause-badge">${RW}</span><button type="button" data-reticle-end class="reticle-status-btn reticle-status-stop" title="${Dl.END}" aria-label="${Dl.END}">${Ce(se.STOP,Cg)}</button><button type="button" data-reticle-copy class="reticle-status-btn" title="${sM}" aria-label="${sM}" hidden>${Ce(se.COPY,Cg)}</button><button type="button" data-reticle-export class="reticle-status-btn" title="${aM}" aria-label="${aM}" hidden>${Ce(se.DOWNLOAD,Cg)}</button><span data-reticle-export-msg class="reticle-export-msg" aria-live="polite"></span>`,hM=`<div data-reticle-banner class="reticle-banner">${uM}</div>`,mM=`<div ${Wm} class="reticle-marks-row" hidden><span data-reticle-marks-text class="reticle-marks-text"></span><button type="button" ${Zm} class="reticle-marks-copy" title="${lM}">${Ce(se.COPY,ye.HELP)}<span>${lM}</span></button></div>`,gM=`<div data-reticle-foot><div class="reticle-foot-stack">${JP}<div class="reticle-foot-workspace-row">${mP()}</div></div></div>`;kg=class{constructor(t){x(this,ht);x(this,Cn,{pauseBtn:void 0,endBtn:void 0,banner:void 0,copyBtn:void 0,exportBtn:void 0,exportMsg:void 0,allFlows:void 0});x(this,Ti,Qe.ACTIVE);x(this,Lo);x(this,Na);x(this,Op);x(this,Pl,[]);x(this,Ml);x(this,Ul);x(this,Hl);x(this,Ra);x(this,qn);g(this,qn,t)}get state(){return c(this,Ti)}mount(t,n){var s,a,l,u,d;g(this,Ra,new AbortController);let{signal:r}=c(this,Ra);g(this,Na,t),g(this,Op,n),g(this,Cn,zW(t));let o=c(this,Cn).pauseBtn;o!==void 0&&cM(o,c(this,Ti)===Qe.PAUSED),(s=c(this,Cn).pauseBtn)==null||s.addEventListener("click",()=>T(this,ht,_M).call(this),{signal:r}),(a=c(this,Cn).endBtn)==null||a.addEventListener("click",()=>T(this,ht,SM).call(this),{signal:r});let i=f=>{let m=f.target;if(!(m instanceof HTMLElement))return;let h=m.closest("[data-reticle-replay]");if(h===null||h.disabled)return;let E=h.getAttribute("data-reticle-replay");E!==null&&E.length>0&&c(this,qn).emit(ln.REPLAY,E)};(l=c(this,Cn).allFlows)==null||l.addEventListener("click",i,{signal:r}),(u=c(this,Cn).copyBtn)==null||u.addEventListener("click",()=>T(this,ht,EM).call(this),{signal:r}),(d=c(this,Cn).exportBtn)==null||d.addEventListener("click",()=>T(this,ht,bM).call(this),{signal:r}),g(this,Hl,gP(t)),T(this,ht,$g).call(this),this.setState(Qe.ACTIVE)}teardown(){var t,n;(t=c(this,Ra))==null||t.abort(),g(this,Ra,void 0),(n=c(this,Hl))==null||n.call(this),g(this,Hl,void 0),c(this,Lo)!==void 0&&Oe(c(this,Lo)),g(this,Lo,void 0)}setFlowProgress(t){let n=CW(t);n!==void 0&&(g(this,Ml,n),c(this,Ul)!==void 0&&Oe(c(this,Ul)),g(this,Ul,Ec.PLAYING===n.status?void 0:de(()=>{g(this,Ml,void 0),T(this,ht,Lg).call(this)},OW)),T(this,ht,Lg).call(this))}setFlows(t){let n=Array.isArray(t)?t:[];g(this,Pl,n.map(r=>{if(typeof r=="string")return r.length>0?{name:r}:null;if(typeof r=="object"&&r!==null){let o=r,i=o.name;if(typeof i!="string"||i.length===0)return null;let s=o.start,a=o.createdAt;return{name:i,...typeof s=="string"&&s.length>0?{start:s}:{},...typeof a=="number"&&Number.isFinite(a)?{createdAt:a}:{}}}return null}).filter(r=>r!==null)),T(this,ht,$g).call(this)}refilterFlows(){T(this,ht,$g).call(this)}setState(t,n,r){var a,l,u,d,f;g(this,Ti,t),(a=c(this,Na))==null||a.setAttribute(wW,t);let o=r!==void 0&&r!==_c.CALM;o?(l=c(this,Na))==null||l.setAttribute(iM,r):(u=c(this,Na))==null||u.removeAttribute(iM),c(this,Lo)!==void 0&&(Oe(c(this,Lo)),g(this,Lo,void 0));let i=c(this,Cn),s=t===Qe.ENDED;if(i.pauseBtn!==void 0&&(cM(i.pauseBtn,t===Qe.PAUSED),i.pauseBtn.hidden=s),i.endBtn!==void 0&&(i.endBtn.hidden=s),i.copyBtn!==void 0&&(s?i.copyBtn.removeAttribute("hidden"):i.copyBtn.setAttribute("hidden","")),i.exportBtn!==void 0&&(s?i.exportBtn.removeAttribute("hidden"):i.exportBtn.setAttribute("hidden","")),i.banner!==void 0){let m=n!==void 0&&n.trim().length>0?n.trim():"";i.banner.textContent=o&&m.length>0?m:`${uM}${m.length>0?` \xB7 ${m}`:""}`}if(s){let m=c(this,Op);g(this,Lo,de(()=>{m==null||m.setAttribute(vW,NW)},c(this,qn).endedFadeMs))}(f=(d=c(this,qn)).onStateChange)==null||f.call(d,t)}};Cn=new WeakMap,Ti=new WeakMap,Lo=new WeakMap,Na=new WeakMap,Op=new WeakMap,Pl=new WeakMap,Ml=new WeakMap,Ul=new WeakMap,Hl=new WeakMap,Ra=new WeakMap,qn=new WeakMap,ht=new WeakSet,Dx=function(){return JSON.stringify(c(this,qn).runState(),null,2)},EM=function(){var n,r,o;(n=navigator.clipboard)==null||n.writeText(T(this,ht,Dx).call(this)),Ar().clearOnCopy&&((o=(r=c(this,qn)).clearRunLog)==null||o.call(r));let t=c(this,Cn).exportMsg;t!==void 0&&(t.textContent=LW,t.setAttribute("data-show","1"),de(()=>t.setAttribute("data-show","0"),1600))},bM=function(){var o,i;let t=new Blob([T(this,ht,Dx).call(this)],{type:"application/json"}),n=URL.createObjectURL(t),r=document.createElement("a");r.href=n,r.download=$W,r.click(),URL.revokeObjectURL(n),Ar().clearOnCopy&&((i=(o=c(this,qn)).clearRunLog)==null||i.call(o))},_M=function(){c(this,Ti)===Qe.PAUSED?(c(this,qn).emit(ln.RESUME),this.setState(Qe.ACTIVE)):c(this,Ti)===Qe.ACTIVE&&(c(this,qn).emit(ln.PAUSE),this.setState(Qe.PAUSED))},SM=function(){c(this,Ti)!==Qe.ENDED&&(c(this,qn).emit(ln.END),this.setState(Qe.ENDED))},Lg=function(){var n,r,o;let t=c(this,Ml);for(let i of(r=(n=c(this,Cn).allFlows)==null?void 0:n.querySelectorAll("[data-reticle-replay]"))!=null?r:[]){let s=(o=i.getAttribute("data-reticle-replay"))!=null?o:"";if(!(t!==void 0&&t.name===s)){i.removeAttribute("data-state"),i.style.removeProperty("--reticle-flow-progress"),i.classList.contains("reticle-flow")&&(i.textContent=`\u25B6 ${s}`);continue}let l=0<t.total?Math.round(100*t.done/t.total):4;i.setAttribute("data-state",t.status),i.style.setProperty("--reticle-flow-progress",`${String(Math.max(4,l))}%`);let u=IW[t.status];i.classList.contains("reticle-flow")&&(i.textContent=`${u} ${s}`);let d=i.querySelector(".reticle-flow-play");d!==null&&(d.textContent=u);let f=i.querySelector(".reticle-flow-meta");f!==null&&0<t.total&&(f.textContent=`Step ${String(t.done)} of ${String(t.total)}`)}},$g=function(){let t=c(this,Cn).allFlows;if(t===void 0)return;let n=t.ownerDocument,r=new Set(Array.from(n.querySelectorAll(jn())).map(s=>Ne(s))),o=s=>s.start===void 0||r.has(s.start);t.replaceChildren();let i=(s,a,l)=>{let u=n.createElement("button");u.type="button",u.className="reticle-flow-row",u.setAttribute("data-reticle-replay",a.name),u.title=a.name,u.disabled=!l;let d=n.createElement("span");d.className="reticle-flow-play",d.setAttribute("aria-hidden","true"),d.textContent="\u25B6";let f=n.createElement("span");f.className="reticle-flow-text";let m=n.createElement("span");m.className="reticle-flow-name",m.textContent=kW(a.name);let h=n.createElement("span");h.className="reticle-flow-meta",h.textContent=l?Ig.REPLAYABLE:Ig.ELSEWHERE,f.append(m,h),u.append(d,f),s.appendChild(u)};if(c(this,Pl).length===0){let s=n.createElement("div");s.className="reticle-flows-empty";let a=n.createElement("strong");a.textContent=Ig.EMPTY_TITLE;let l=n.createElement("span");l.textContent=Ig.EMPTY_HINT,s.append(a,l),t.appendChild(s)}else for(let s of[...c(this,Pl)].sort((a,l)=>{var u,d;return((u=l.createdAt)!=null?u:0)-((d=a.createdAt)!=null?d:0)}))i(t,s,o(s));T(this,ht,Lg).call(this)}});var Ee,Y,ce,qr,Mx,TM,xM=y(()=>{"use strict";hi();Lt();Lt();Zr();Ee="data-reticle-overlay",Y="data-reticle-hud",ce="data-reticle-chat-panel",qr="data-reticle-state",Mx="data-reticle-tone",TM=`
723
723
  /**
724
724
  * ONE colour says what the session is doing, and the user picks all three.
725
725
  *
@@ -728,12 +728,12 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
728
728
  * The defaults are blue / amber / red; the settings panel writes --reticle-c-* from the swatches,
729
729
  * because a signal colour that disappears into the user's own palette is not a signal.
730
730
  */
731
- [${ge}]{
731
+ [${Ee}]{
732
732
  --reticle-c-active:#3b82f6;--reticle-c-idle:#eab308;--reticle-c-ended:#ef4444;
733
733
  --reticle-state:var(--reticle-c-idle);}
734
- [${ge}][${Qd}="active"]{--reticle-state:var(--reticle-c-active);}
735
- [${ge}][${Wr}="paused"]{--reticle-state:var(--reticle-c-idle);}
736
- [${ge}][${Wr}="ended"]{--reticle-state:var(--reticle-c-ended);}
734
+ [${Ee}][${rp}="active"]{--reticle-state:var(--reticle-c-active);}
735
+ [${Ee}][${qr}="paused"]{--reticle-state:var(--reticle-c-idle);}
736
+ [${Ee}][${qr}="ended"]{--reticle-state:var(--reticle-c-ended);}
737
737
  [${F}]{
738
738
  --reticle-surface:color-mix(in srgb,var(--reticle-hud-surface) 78%,transparent);
739
739
  /* No literal here: --reticle-accent is published on the overlay from the chosen status theme.
@@ -769,7 +769,7 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
769
769
  * expensive thing in the whole SDK.
770
770
  */
771
771
  [${ce}]{
772
- ${cl}
772
+ ${dl}
773
773
  display:none;position:absolute;right:0;left:auto;bottom:calc(100% + 8px);top:auto;z-index:5;
774
774
  box-sizing:border-box;width:var(--reticle-dock-w);max-width:min(var(--reticle-dock-w),calc(100vw - 16px));
775
775
  height:min(var(--reticle-chat-max-h,var(--reticle-chat-h)),calc(100vh - 120px));
@@ -780,14 +780,14 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
780
780
  contain:layout style paint;
781
781
  transform:translateZ(0);
782
782
  pointer-events:none;}
783
- [${F}][${fi}="below"] [${ce}]{
783
+ [${F}][${gi}="below"] [${ce}]{
784
784
  bottom:auto;top:calc(100% + 8px);}
785
785
  [${F}][${Xt}="start"] [${ce}]{
786
786
  right:auto;left:0;}
787
- [${ge}][${yt}="1"] [${ce}]{
787
+ [${Ee}][${yt}="1"] [${ce}]{
788
788
  display:flex;pointer-events:auto;}
789
789
  [${ce}][hidden]{display:none!important;}
790
- [${F}][${fi}="below"] [data-reticle-page-panel]{bottom:auto;top:calc(100% + 8px);}
790
+ [${F}][${gi}="below"] [data-reticle-page-panel]{bottom:auto;top:calc(100% + 8px);}
791
791
  [${F}][${Xt}="start"] [data-reticle-page-panel]{right:auto;left:0;}
792
792
  /**
793
793
  * Idle, and not blocking the page: the card is not in use.
@@ -796,13 +796,13 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
796
796
  * under the card landed on an empty transcript. Playwright named that div. The card passes the
797
797
  * event through. The buttons stay clickable, which is the chrome a person still needs (#992).
798
798
  */
799
- [${ge}][data-reticle-mode="idle"][data-reticle-block="0"] [${ce}],
800
- [${ge}][data-reticle-mode="idle"][data-reticle-block="0"] [${ce}] [data-reticle-log]{
799
+ [${Ee}][data-reticle-mode="idle"][data-reticle-block="0"] [${ce}],
800
+ [${Ee}][data-reticle-mode="idle"][data-reticle-block="0"] [${ce}] [data-reticle-log]{
801
801
  pointer-events:none;}
802
802
  /* ...except a log with more than it shows: a feed nobody can scroll back through is not a log. */
803
- [${ge}][data-reticle-mode="idle"][data-reticle-block="0"] [${ce}] [data-reticle-log][data-reticle-log-scrollable]{
803
+ [${Ee}][data-reticle-mode="idle"][data-reticle-block="0"] [${ce}] [data-reticle-log][data-reticle-log-scrollable]{
804
804
  pointer-events:auto;}
805
- [${ge}][data-reticle-mode="idle"][data-reticle-block="0"] [${ce}] :is(button,a,input,select,textarea){
805
+ [${Ee}][data-reticle-mode="idle"][data-reticle-block="0"] [${ce}] :is(button,a,input,select,textarea){
806
806
  pointer-events:auto;}
807
807
  /**
808
808
  * Minimising the chat leaves a CAPSULE, not a hole: the same glass, the same state dot, the last
@@ -810,7 +810,7 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
810
810
  * clicked. Leaving the toolbar alone above an empty gap would make a minimised session look
811
811
  * identical to no session at all.
812
812
  */
813
- [${Ht}]{
813
+ [${Ft}]{
814
814
  display:none;position:absolute;right:0;left:auto;bottom:calc(100% + 8px);z-index:5;
815
815
  box-sizing:border-box;width:var(--reticle-dock-w);
816
816
  max-width:min(var(--reticle-dock-w),calc(100vw - 16px));
@@ -819,18 +819,18 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
819
819
  radial-gradient(120% 160% at 50% 0%,color-mix(in srgb,var(--reticle-state) 18%,transparent),transparent 70%),
820
820
  linear-gradient(180deg,rgba(13,15,22,.96),rgba(19,22,32,.94));
821
821
  border:1px solid color-mix(in srgb,var(--reticle-state) 26%,rgba(255,255,255,.1));
822
- box-shadow:${Gr},0 0 34px -14px var(--reticle-state);
822
+ box-shadow:${Kr},0 0 34px -14px var(--reticle-state);
823
823
  color:var(--reticle-muted);font-family:var(--reticle-font);font-size:11px;line-height:1;
824
824
  transition:transform .1s ease,border-color .2s ease;}
825
- [${F}][${fi}="below"] [${Ht}]{bottom:auto;top:calc(100% + 8px);}
826
- [${F}][${Xt}="start"] [${Ht}]{right:auto;left:0;}
827
- [${ge}][${Ze}="0"]:not([${yt}="1"]) [${Ht}]{
825
+ [${F}][${gi}="below"] [${Ft}]{bottom:auto;top:calc(100% + 8px);}
826
+ [${F}][${Xt}="start"] [${Ft}]{right:auto;left:0;}
827
+ [${Ee}][${We}="0"]:not([${yt}="1"]) [${Ft}]{
828
828
  display:inline-flex;pointer-events:auto;}
829
- [${Ht}]:hover{border-color:color-mix(in srgb,var(--reticle-c-active) 45%,transparent);}
830
- [${Ht}]:active{transform:scale(.98);}
829
+ [${Ft}]:hover{border-color:color-mix(in srgb,var(--reticle-c-active) 45%,transparent);}
830
+ [${Ft}]:active{transform:scale(.98);}
831
831
  /* No dot in the capsule: the mark, the border and the glow already carry the state colour, and a
832
832
  pulsing dot next to a line of text that changes on its own was two things moving for one fact. */
833
- [${Ht}] .reticle-mark{flex:none;height:14px;width:auto;color:var(--reticle-fg);opacity:.9;}
833
+ [${Ft}] .reticle-mark{flex:none;height:14px;width:auto;color:var(--reticle-fg);opacity:.9;}
834
834
  /* Header: who this panel belongs to, and what the session is doing right now. */
835
835
  [${ce}] .reticle-chat-head{
836
836
  flex:none;display:flex;align-items:center;gap:8px;padding:11px 44px 9px 14px;
@@ -857,15 +857,15 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
857
857
  [${ce}] .reticle-view-heading strong{font-size:11px;font-weight:600;}
858
858
  /* No state word here: the activity strip immediately below already says "idle \xB7 21s", and the
859
859
  dot in front of it carries the same colour. One fact, one place. */
860
- [${Ht}] .reticle-chat-pill-text{
860
+ [${Ft}] .reticle-chat-pill-text{
861
861
  flex:1;text-align:left;
862
862
  min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
863
863
  font-variant-numeric:tabular-nums;letter-spacing:.01em;}
864
- [${Ht}] .reticle-chat-pill-time{
864
+ [${Ft}] .reticle-chat-pill-time{
865
865
  flex:none;color:var(--reticle-faint);font-variant-numeric:tabular-nums;}
866
- [${Ht}] .reticle-chat-pill-caret{
866
+ [${Ft}] .reticle-chat-pill-caret{
867
867
  flex:none;display:inline-flex;color:var(--reticle-faint);line-height:0;transform:rotate(180deg);}
868
- [${Ht}] .reticle-chat-pill-caret svg{
868
+ [${Ft}] .reticle-chat-pill-caret svg{
869
869
  display:block;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;}
870
870
  /* Minimise the chat without collapsing the whole HUD \u2014 sits over the panel's top-right corner. */
871
871
  [${F}] .reticle-chat-min{
@@ -876,44 +876,44 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
876
876
  [${F}] .reticle-chat-min:hover{background:rgba(255,255,255,.07);color:var(--reticle-fg);}
877
877
  [${F}] .reticle-chat-min svg{display:block;fill:none;stroke:currentColor;stroke-width:1.5;
878
878
  stroke-linecap:round;stroke-linejoin:round;}
879
- [${ge}][${Wm}="0"] [${Yd}]{display:none;}
880
- [${ge}][${To}="1"] [${K}],
881
- [${ge}][${To}="1"] [${ce}],
882
- [${ge}][${To}="1"] [data-reticle-settings-panel]{
879
+ [${Ee}][${Jm}="0"] [${Qd}]{display:none;}
880
+ [${Ee}][${Ao}="1"] [${Y}],
881
+ [${Ee}][${Ao}="1"] [${ce}],
882
+ [${Ee}][${Ao}="1"] [data-reticle-settings-panel]{
883
883
  transition-duration:.01ms !important;}
884
- [${ge}][${To}="1"] .reticle-fab-pulse,
885
- [${ge}][${To}="1"] .reticle-act-dot,
886
- [${ge}][${To}="1"] [data-bump="1"]{animation:none !important;}
887
- [${K}]{
884
+ [${Ee}][${Ao}="1"] .reticle-fab-pulse,
885
+ [${Ee}][${Ao}="1"] .reticle-act-dot,
886
+ [${Ee}][${Ao}="1"] [data-bump="1"]{animation:none !important;}
887
+ [${Y}]{
888
888
  /* Centre the toolbar in the pill. The toolbar is 32px inside a 36px content box and, as a plain
889
889
  block child, sat flush against padding-top - every icon rode 2px high in a rounded bar, which
890
890
  is exactly the offset the eye picks up on a pill. */
891
891
  position:relative;box-sizing:border-box;pointer-events:auto;flex:none;
892
892
  display:flex;align-items:center;
893
893
  width:44px;height:44px;min-height:44px;max-height:44px;overflow:visible;
894
- background:${OT};
894
+ background:${HT};
895
895
  color:#fff;border:none;border-radius:22px;
896
896
  box-shadow:0 2px 12px rgba(0,0,0,.45),inset 0 1px 0 rgba(255,255,255,.06),0 0 0 1px rgba(255,255,255,.1);
897
897
  contain:layout style;
898
898
  transition:width .26s var(--reticle-shell-ease),border-radius .26s var(--reticle-shell-ease),
899
899
  transform var(--reticle-shell-fast),opacity .18s ease;
900
900
  will-change:width,border-radius,transform;}
901
- [${ge}][${Ze}="0"] [${K}]{
901
+ [${Ee}][${We}="0"] [${Y}]{
902
902
  box-shadow:0 4px 20px rgba(0,0,0,.5),inset 0 1px 0 rgba(255,255,255,.08),0 0 0 1px rgba(255,255,255,.12);}
903
- [${K}] .reticle-hud-deco{
903
+ [${Y}] .reticle-hud-deco{
904
904
  position:absolute;inset:0;z-index:0;border-radius:inherit;pointer-events:none;
905
905
  opacity:0;visibility:hidden;}
906
- [${ge}][${Ze}="0"] [${K}] .reticle-hud-deco{
906
+ [${Ee}][${We}="0"] [${Y}] .reticle-hud-deco{
907
907
  opacity:1;visibility:visible;}
908
- [${K}][data-on="0"]{opacity:0;transform:scale(.8);pointer-events:none;}
909
- [${K}][data-on="1"]{opacity:1;transform:scale(1);}
908
+ [${Y}][data-on="0"]{opacity:0;transform:scale(.8);pointer-events:none;}
909
+ [${Y}][data-on="1"]{opacity:1;transform:scale(1);}
910
910
  /* The expanded HUD IS the shared column width; the toolbar fills its content box. Sizing the
911
911
  toolbar to the dock width instead pushed it past the HUD's padding, and the last button - Exit -
912
912
  rendered outside the rounded box it belongs to. */
913
- [${ge}][${Ze}="0"] [${K}]{
913
+ [${Ee}][${We}="0"] [${Y}]{
914
914
  width:min(calc(100vw - 24px),var(--reticle-dock-w));height:44px;min-height:44px;max-height:44px;
915
915
  min-width:44px;border-radius:24px;padding:4px 6px;}
916
- [${K}] .reticle-fab{
916
+ [${Y}] .reticle-fab{
917
917
  position:absolute;inset:0;z-index:2;display:inline-flex;align-items:center;justify-content:center;
918
918
  width:44px;height:44px;padding:0;margin:0;border:none;border-radius:22px;cursor:pointer;
919
919
  background:transparent;color:var(--reticle-fg);line-height:0;
@@ -923,116 +923,116 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
923
923
  * waiting or done. It carries the state colour as a halo: breathing while the agent drives, a
924
924
  * steady soft ring while idle, and a flat dim ring once the session has ended.
925
925
  */
926
- [${ge}][${Ze}="1"] [${K}] .reticle-fab{
926
+ [${Ee}][${We}="1"] [${Y}] .reticle-fab{
927
927
  cursor:grab;touch-action:none;user-select:none;
928
928
  box-shadow:0 0 0 1px color-mix(in srgb,var(--reticle-state) 55%,transparent),
929
929
  0 0 14px -2px color-mix(in srgb,var(--reticle-state) 45%,transparent);}
930
- [${ge}][${Ze}="1"][${Qd}="active"] [${K}] .reticle-fab{
930
+ [${Ee}][${We}="1"][${rp}="active"] [${Y}] .reticle-fab{
931
931
  animation:reticle-fab-breathe 1.6s ease-in-out infinite;}
932
- [${ge}][${Ze}="1"][${Wr}="ended"] [${K}] .reticle-fab{
932
+ [${Ee}][${We}="1"][${qr}="ended"] [${Y}] .reticle-fab{
933
933
  animation:none;box-shadow:0 0 0 1px color-mix(in srgb,var(--reticle-state) 40%,transparent);}
934
934
  @keyframes reticle-fab-breathe{
935
935
  0%,100%{box-shadow:0 0 0 1px color-mix(in srgb,var(--reticle-state) 70%,transparent),
936
936
  0 0 16px -2px color-mix(in srgb,var(--reticle-state) 55%,transparent)}
937
937
  50%{box-shadow:0 0 0 2px var(--reticle-state),
938
938
  0 0 28px 2px color-mix(in srgb,var(--reticle-state) 70%,transparent)}}
939
- [${ge}][${To}="1"] [${K}] .reticle-fab{animation:none;}
940
- [${ge}][${Ze}="1"] [${K}] .reticle-fab.reticle-drag-handle--dragging{
939
+ [${Ee}][${Ao}="1"] [${Y}] .reticle-fab{animation:none;}
940
+ [${Ee}][${We}="1"] [${Y}] .reticle-fab.reticle-drag-handle--dragging{
941
941
  cursor:grabbing;}
942
- [${K}] .reticle-fab-mark{height:22px;width:auto;pointer-events:none;}
943
- [${K}] .reticle-fab:hover{background:rgba(255,255,255,.08);}
944
- [${K}] .reticle-fab:active{transform:scale(.95);}
945
- [${K}] .reticle-fab:focus-visible{outline:2px solid color-mix(in srgb,var(--reticle-accent) 75%,transparent);outline-offset:2px;}
946
- [${K}] .reticle-fab-pulse{
942
+ [${Y}] .reticle-fab-mark{height:22px;width:auto;pointer-events:none;}
943
+ [${Y}] .reticle-fab:hover{background:rgba(255,255,255,.08);}
944
+ [${Y}] .reticle-fab:active{transform:scale(.95);}
945
+ [${Y}] .reticle-fab:focus-visible{outline:2px solid color-mix(in srgb,var(--reticle-accent) 75%,transparent);outline-offset:2px;}
946
+ [${Y}] .reticle-fab-pulse{
947
947
  position:absolute;top:6px;right:6px;width:6px;height:6px;border-radius:50%;
948
948
  background:var(--reticle-accent);opacity:0;transform:scale(.6);transition:opacity .2s,transform .2s;}
949
- [${K}] .reticle-fab[data-pulse="1"] .reticle-fab-pulse{opacity:1;transform:scale(1);}
950
- [${K}] .reticle-fab-badge{
949
+ [${Y}] .reticle-fab[data-pulse="1"] .reticle-fab-pulse{opacity:1;transform:scale(1);}
950
+ [${Y}] .reticle-fab-badge{
951
951
  position:absolute;top:-13px;right:-13px;min-width:18px;height:18px;padding:0 5px;border-radius:9px;
952
952
  background:var(--reticle-accent);color:#fff;font-size:10px;font-weight:600;
953
953
  display:flex;align-items:center;justify-content:center;pointer-events:none;
954
954
  box-shadow:0 1px 3px rgba(0,0,0,.15);}
955
- [${K}] .reticle-fab-badge[hidden]{display:none;}
956
- [${ge}][${Ze}="0"] [${K}] .reticle-fab{
955
+ [${Y}] .reticle-fab-badge[hidden]{display:none;}
956
+ [${Ee}][${We}="0"] [${Y}] .reticle-fab{
957
957
  opacity:0;pointer-events:none;visibility:hidden;}
958
958
  /* The toolbar is the third element in the same column, so it carries the same width as the chat
959
959
  and the capsule above it and spreads its groups across it, rather than hugging its icons. */
960
- [${K}] .reticle-toolbar{
960
+ [${Y}] .reticle-toolbar{
961
961
  position:relative;z-index:1;display:none;align-items:center;justify-content:space-between;
962
962
  box-sizing:border-box;width:100%;
963
963
  gap:4px;height:32px;padding:0 2px;
964
964
  overflow:visible;opacity:0;transform:scale(.94);pointer-events:none;
965
965
  transition:opacity .2s var(--reticle-shell-ease),transform .18s var(--reticle-shell-ease);}
966
- [${ge}][${Ze}="0"] [${K}] .reticle-toolbar{
966
+ [${Ee}][${We}="0"] [${Y}] .reticle-toolbar{
967
967
  display:flex;opacity:1;transform:scale(1);pointer-events:auto;}
968
968
  /* The HUD block is transformed, which makes it a stacking context at level 0 inside the dock, so a
969
969
  tooltip's z-index only ranked it within the block and it drew behind the chat and settings panels,
970
970
  its siblings. Lift the block while a tooltip can show. */
971
- [${K}]:hover,[${K}]:focus-within{z-index:${String(RT)};}
972
- [${K}] .reticle-toolbar-drag{cursor:grab;touch-action:none;user-select:none;}
973
- [${K}] .reticle-toolbar-drag.reticle-drag-handle--dragging{cursor:grabbing;}
974
- [${K}] .reticle-toolbar-actions{
971
+ [${Y}]:hover,[${Y}]:focus-within{z-index:${String(UT)};}
972
+ [${Y}] .reticle-toolbar-drag{cursor:grab;touch-action:none;user-select:none;}
973
+ [${Y}] .reticle-toolbar-drag.reticle-drag-handle--dragging{cursor:grabbing;}
974
+ [${Y}] .reticle-toolbar-actions{
975
975
  display:inline-flex;align-items:center;gap:2px;flex:none;
976
976
  padding:2px;border-radius:999px;background:rgba(0,0,0,.2);}
977
- [${K}] .reticle-toolbar-chrome{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);align-items:center;gap:var(--reticle-hud-space-1);flex:1;min-width:0;}
978
- [${K}] .reticle-tb-sep{width:1px;height:14px;background:rgba(255,255,255,.12);margin:0 4px;flex:none;align-self:center;}
977
+ [${Y}] .reticle-toolbar-chrome{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);align-items:center;gap:var(--reticle-hud-space-1);flex:1;min-width:0;}
978
+ [${Y}] .reticle-tb-sep{width:1px;height:14px;background:rgba(255,255,255,.12);margin:0 4px;flex:none;align-self:center;}
979
979
 
980
- [${K}] .reticle-tb-wrap{position:relative;display:flex;align-items:center;justify-content:center;overflow:visible;}
981
- [${K}] .reticle-tb-btn{
980
+ [${Y}] .reticle-tb-wrap{position:relative;display:flex;align-items:center;justify-content:center;overflow:visible;}
981
+ [${Y}] .reticle-tb-btn{
982
982
  flex:none;display:inline-flex;align-items:center;justify-content:center;
983
983
  width:var(--reticle-hud-control-size);height:var(--reticle-hud-control-size);padding:0;border:none;border-radius:var(--reticle-hud-radius-pill);cursor:pointer;
984
984
  background:transparent;color:rgba(255,255,255,.85);line-height:0;
985
985
  transition:background-color .15s ease,color .15s ease,transform .1s ease,opacity .2s ease;}
986
- [${K}] .reticle-tb-btn:hover{background:rgba(255,255,255,.12);color:#fff;}
987
- [${K}] .reticle-tb-btn:active{transform:scale(.92);}
988
- [${K}] .reticle-tb-btn:focus-visible{outline:2px solid color-mix(in srgb,var(--reticle-accent) 65%,transparent);outline-offset:1px;}
989
- [${K}] .reticle-tb-btn:disabled{opacity:.35;cursor:not-allowed;transform:none;}
990
- [${K}] .reticle-tb-btn[data-active="1"]{color:var(--reticle-accent);
986
+ [${Y}] .reticle-tb-btn:hover{background:rgba(255,255,255,.12);color:#fff;}
987
+ [${Y}] .reticle-tb-btn:active{transform:scale(.92);}
988
+ [${Y}] .reticle-tb-btn:focus-visible{outline:2px solid color-mix(in srgb,var(--reticle-accent) 65%,transparent);outline-offset:1px;}
989
+ [${Y}] .reticle-tb-btn:disabled{opacity:.35;cursor:not-allowed;transform:none;}
990
+ [${Y}] .reticle-tb-btn[data-active="1"]{color:var(--reticle-accent);
991
991
  background:color-mix(in srgb, var(--reticle-accent) 25%, transparent);}
992
- [${K}] .reticle-tb-btn--toggle[data-active="1"]{
992
+ [${Y}] .reticle-tb-btn--toggle[data-active="1"]{
993
993
  color:var(--reticle-accent);background:transparent;}
994
- [${K}] .reticle-tb-btn--toggle[data-active="1"]:hover{background:rgba(255,255,255,.06);color:var(--reticle-accent);}
995
- [${K}] .reticle-hi-toggle{
994
+ [${Y}] .reticle-tb-btn--toggle[data-active="1"]:hover{background:rgba(255,255,255,.06);color:var(--reticle-accent);}
995
+ [${Y}] .reticle-hi-toggle{
996
996
  position:relative;display:inline-flex;align-items:center;justify-content:center;
997
997
  width:18px;height:18px;line-height:0;flex:none;}
998
- [${K}] .reticle-hi-toggle .reticle-hi-icon{
998
+ [${Y}] .reticle-hi-toggle .reticle-hi-icon{
999
999
  position:absolute;inset:0;display:inline-flex;align-items:center;justify-content:center;
1000
1000
  transition:opacity .14s ease;}
1001
- [${K}] .reticle-hi-toggle .reticle-hi-icon--solid{opacity:0;}
1002
- [${K}] .reticle-hi-toggle .reticle-hi-icon--solid svg{
1001
+ [${Y}] .reticle-hi-toggle .reticle-hi-icon--solid{opacity:0;}
1002
+ [${Y}] .reticle-hi-toggle .reticle-hi-icon--solid svg{
1003
1003
  transform:scale(1.12);transform-origin:center;}
1004
1004
  /*
1005
1005
  * Active toggles keep the OUTLINE icon. The solid heroicon is a filled glyph next to 1.5px strokes
1006
1006
  * everywhere else, so a pressed button reads as a heavier typeface rather than as a state. Accent
1007
1007
  * colour and the background above already carry the state without changing the icon's weight.
1008
1008
  */
1009
- [${K}] .reticle-tb-btn--toggle[data-active="1"] .reticle-hi-icon--outline{opacity:1;}
1010
- [${K}] .reticle-tb-btn--toggle .reticle-hi-icon--solid{opacity:0;}
1011
- [${K}] .reticle-tb-btn--toggle .reticle-hi-icon--solid svg{color:inherit;}
1012
- [${K}] .reticle-tb-btn--primary[data-active="1"]{
1009
+ [${Y}] .reticle-tb-btn--toggle[data-active="1"] .reticle-hi-icon--outline{opacity:1;}
1010
+ [${Y}] .reticle-tb-btn--toggle .reticle-hi-icon--solid{opacity:0;}
1011
+ [${Y}] .reticle-tb-btn--toggle .reticle-hi-icon--solid svg{color:inherit;}
1012
+ [${Y}] .reticle-tb-btn--primary[data-active="1"]{
1013
1013
  color:#fff;background:rgba(255,255,255,.14);}
1014
- [${K}] .reticle-tb-btn[data-danger]:hover:not(:disabled){color:#ff383c;
1014
+ [${Y}] .reticle-tb-btn[data-danger]:hover:not(:disabled){color:#ff383c;
1015
1015
  background:color-mix(in srgb, #ff383c 25%, transparent);}
1016
- [${K}] .reticle-tb-tip{
1016
+ [${Y}] .reticle-tb-tip{
1017
1017
  position:absolute;bottom:calc(100% + 14px);left:50%;transform:translateX(-50%) scale(.95);
1018
1018
  padding:6px 10px;background:#1a1a1a;color:rgba(255,255,255,.9);font-size:12px;font-weight:500;
1019
- border-radius:8px;white-space:nowrap;opacity:0;visibility:hidden;pointer-events:none;z-index:${String(RT)};
1019
+ border-radius:8px;white-space:nowrap;opacity:0;visibility:hidden;pointer-events:none;z-index:${String(UT)};
1020
1020
  box-shadow:0 2px 8px rgba(0,0,0,.3);transition:opacity .135s ease,transform .135s ease,visibility .135s;}
1021
- [${K}] .reticle-tb-tip::after{
1021
+ [${Y}] .reticle-tb-tip::after{
1022
1022
  content:"";position:absolute;top:calc(100% - 4px);left:50%;transform:translateX(-50%) rotate(45deg);
1023
1023
  width:8px;height:8px;background:#1a1a1a;border-radius:0 0 2px 0;}
1024
- [${K}] .reticle-tb-wrap:hover .reticle-tb-tip{
1024
+ [${Y}] .reticle-tb-wrap:hover .reticle-tb-tip{
1025
1025
  opacity:1;visibility:visible;transform:translateX(-50%) scale(1);transition-delay:.3s;}
1026
- [${K}] .reticle-tb-wrap:has(.reticle-tb-btn:disabled):hover .reticle-tb-tip{opacity:0;visibility:hidden;}
1027
- [${K}] .reticle-tb-wrap--pause:hover .reticle-pause-badge{opacity:0;}
1028
- [${K}] .reticle-tb-kbd{margin-left:4px;opacity:.5;}
1029
- [${K}] .reticle-pause-badge{
1026
+ [${Y}] .reticle-tb-wrap:has(.reticle-tb-btn:disabled):hover .reticle-tb-tip{opacity:0;visibility:hidden;}
1027
+ [${Y}] .reticle-tb-wrap--pause:hover .reticle-pause-badge{opacity:0;}
1028
+ [${Y}] .reticle-tb-kbd{margin-left:4px;opacity:.5;}
1029
+ [${Y}] .reticle-pause-badge{
1030
1030
  display:none;position:absolute;bottom:calc(100% + 5px);left:50%;transform:translateX(-50%);
1031
1031
  align-items:center;flex:none;font-weight:600;letter-spacing:.08em;font-size:7px;
1032
1032
  color:var(--reticle-fg);border:1px solid rgba(255,255,255,.16);background:rgba(0,0,0,.55);
1033
1033
  padding:2px 6px;border-radius:999px;white-space:nowrap;pointer-events:none;z-index:2;
1034
1034
  transition:opacity .12s ease;}
1035
- [${ge}][${Wr}="paused"] [data-reticle-badge]{display:inline-flex;}
1035
+ [${Ee}][${qr}="paused"] [data-reticle-badge]{display:inline-flex;}
1036
1036
  /**
1037
1037
  * The mode, ON the status row rather than under it.
1038
1038
  *
@@ -1063,9 +1063,9 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1063
1063
  [${F}] .reticle-tally .reticle-hi-icon{opacity:.92;}
1064
1064
  @keyframes reticle-tally-pop{0%{transform:scale(1)}38%{transform:scale(1.3)}100%{transform:scale(1)}}
1065
1065
  [${F}] .reticle-tally [data-bump="1"]{display:inline-flex;animation:reticle-tally-pop .36s cubic-bezier(.16,1,.3,1);}
1066
- [${K}] .reticle-hi-icon{display:inline-flex;align-items:center;justify-content:center;line-height:1;flex-shrink:0;color:inherit;}
1067
- [${K}] .reticle-hi-icon svg{display:block;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;}
1068
- [${K}] .reticle-live{display:none;}
1066
+ [${Y}] .reticle-hi-icon{display:inline-flex;align-items:center;justify-content:center;line-height:1;flex-shrink:0;color:inherit;}
1067
+ [${Y}] .reticle-hi-icon svg{display:block;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;}
1068
+ [${Y}] .reticle-live{display:none;}
1069
1069
  [${ce}] .reticle-act-strip{flex:none;display:flex;align-items:center;gap:7px;min-height:36px;box-sizing:border-box;padding:4px 12px;
1070
1070
  border-bottom:1px solid rgba(255,255,255,.07);background:rgba(0,0,0,.22);}
1071
1071
  [${ce}] .reticle-act-dot{flex:none;width:7px;height:7px;border-radius:50%;background:var(--reticle-faint);
@@ -1087,12 +1087,12 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1087
1087
  * Muted rather than alarming. Nothing is broken in the user's app \u2014 Reticle simply has nobody to
1088
1088
  * talk to \u2014 and a dev overlay that shouts about its own plumbing is one the user turns off.
1089
1089
  */
1090
- [${ge}][${Wr}="unreachable"]{--reticle-state:var(--reticle-faint);}
1091
- [${ge}][${Wr}="unreachable"] [${ce}] .reticle-act-dot{animation:none;}
1090
+ [${Ee}][${qr}="unreachable"]{--reticle-state:var(--reticle-faint);}
1091
+ [${Ee}][${qr}="unreachable"] [${ce}] .reticle-act-dot{animation:none;}
1092
1092
  /* The one status that is a sentence to act on: two lines, full contrast, the detail on hover. */
1093
- [${ge}][${Wr}="unreachable"] [${ce}] .reticle-act{white-space:normal;line-height:1.35;color:var(--reticle-fg);cursor:help;}
1094
- [${ge}][${Wr}="paused"] [${ce}] .reticle-act-dot,
1095
- [${ge}][${Wr}="ended"] [${ce}] .reticle-act-dot{animation:none;}
1093
+ [${Ee}][${qr}="unreachable"] [${ce}] .reticle-act{white-space:normal;line-height:1.35;color:var(--reticle-fg);cursor:help;}
1094
+ [${Ee}][${qr}="paused"] [${ce}] .reticle-act-dot,
1095
+ [${Ee}][${qr}="ended"] [${ce}] .reticle-act-dot{animation:none;}
1096
1096
  @keyframes reticle-idle-pulse{0%,100%{opacity:.45;transform:scale(.92)}50%{opacity:1;transform:scale(1)}}
1097
1097
  [${ce}] .reticle-act{display:block;flex:1;min-width:0;color:var(--reticle-muted);font-size:11px;
1098
1098
  font-variant-numeric:tabular-nums;letter-spacing:.01em;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
@@ -1106,7 +1106,7 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1106
1106
  [${ce}] .reticle-status-stop:hover:not(:disabled){color:var(--reticle-state);border-color:var(--reticle-state);}
1107
1107
  [${ce}] .reticle-act-actions .reticle-pause-badge{display:none;position:static;transform:none;padding:2px 5px;font-size:8px;}
1108
1108
  [${ce}] .reticle-act-strip[data-liveness="active"] .reticle-act{color:var(--reticle-fg);}
1109
- [${K}] .reticle-pass{color:var(--reticle-ok);}[${K}] .reticle-fail{color:var(--reticle-bad);}
1109
+ [${Y}] .reticle-pass{color:var(--reticle-ok);}[${Y}] .reticle-fail{color:var(--reticle-bad);}
1110
1110
  /**
1111
1111
  * Paused and ended keep the STATE colour rather than washing out to grey.
1112
1112
  *
@@ -1116,19 +1116,19 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1116
1116
  * the theme's own paused/ended colour now, so "which state am I in" is answered by the same hue
1117
1117
  * everywhere: the dot, the glow, the FAB halo, and the toolbar.
1118
1118
  */
1119
- [${ge}][${Wr}="paused"] [${K}],
1120
- [${ge}][${Wr}="ended"] [${K}],
1121
- [${ge}][${Nx}="waiting"] [${K}]{
1119
+ [${Ee}][${qr}="paused"] [${Y}],
1120
+ [${Ee}][${qr}="ended"] [${Y}],
1121
+ [${Ee}][${Mx}="waiting"] [${Y}]{
1122
1122
  --reticle-accent:var(--reticle-state);
1123
1123
  --reticle-accent-soft:color-mix(in srgb,var(--reticle-state) 18%,transparent);}
1124
- [${ge}][${Nx}="ask"] [${K}],
1125
- [${ge}][${Nx}="warn"] [${K}]{
1124
+ [${Ee}][${Mx}="ask"] [${Y}],
1125
+ [${Ee}][${Mx}="warn"] [${Y}]{
1126
1126
  --reticle-accent:var(--reticle-state);
1127
1127
  --reticle-accent-soft:color-mix(in srgb,var(--reticle-state) 18%,transparent);}
1128
1128
  @media (max-width:480px){
1129
1129
  [${ce}]{width:min(100vw - 24px,320px);max-height:min(440px,calc(100vh - 100px));}
1130
- [${ge}][${Ze}="0"] [${K}]{max-width:calc(100vw - 24px);}
1131
- }`});var cM,lM,uM,dM=y(()=>{"use strict";Vr();cM=20,lM=28,uM=`
1130
+ [${Ee}][${We}="0"] [${Y}]{max-width:calc(100vw - 24px);}
1131
+ }`});var AM,yM,wM,vM=y(()=>{"use strict";Zr();AM=20,yM=28,wM=`
1132
1132
  /* The control establishes its own stacking context, and a high one.
1133
1133
  Its menu is absolutely positioned inside a panel whose other children (the log well, the act strip)
1134
1134
  are themselves positioned with their own z-index, so a z-index on the MENU alone was being compared
@@ -1146,11 +1146,11 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1146
1146
  .reticle-account{position:relative;z-index:9;display:inline-flex;align-items:center;gap:6px;flex:none;}
1147
1147
  .reticle-account-avatar{
1148
1148
  display:inline-flex;align-items:center;justify-content:center;
1149
- width:${String(cM)}px;height:${String(cM)}px;border-radius:999px;
1149
+ width:${String(AM)}px;height:${String(AM)}px;border-radius:999px;
1150
1150
  font-size:9px;font-weight:600;letter-spacing:.02em;
1151
1151
  background:rgba(255,255,255,.12);color:rgba(255,255,255,.92);user-select:none;}
1152
1152
  .reticle-account-avatar--lg{
1153
- width:${String(lM)}px;height:${String(lM)}px;font-size:11px;}
1153
+ width:${String(yM)}px;height:${String(yM)}px;font-size:11px;}
1154
1154
 
1155
1155
  /* The trigger is the avatar plus a hit area, never a second visual element: an avatar that looks
1156
1156
  like a button reads as an action, and this one opens a menu about a state. */
@@ -1180,8 +1180,8 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1180
1180
  /* The HUD's own surface tokens, not a colour invented here. A menu with its own near-black is a
1181
1181
  second design language in the same panel, and a translucent one lets the panel's empty-state text
1182
1182
  read straight through the rows -- which is what the first version did. */
1183
- ${ep}
1184
- box-shadow:inset 0 1px 0 rgba(255,255,255,.09),${Gr};
1183
+ ${op}
1184
+ box-shadow:inset 0 1px 0 rgba(255,255,255,.09),${Kr};
1185
1185
  font-size:11px;color:rgba(255,255,255,.78);text-align:left;}
1186
1186
  .reticle-account-menu[hidden]{display:none;}
1187
1187
 
@@ -1223,7 +1223,7 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1223
1223
  display:inline-flex;align-items:center;justify-content:center;
1224
1224
  border:none;background:transparent;color:rgba(255,255,255,.6);cursor:pointer;line-height:0;padding:2px;}
1225
1225
  .reticle-account-dashboard:hover{color:#fff;}
1226
- `});var Q9,pM,fM=y(()=>{"use strict";Vr();Ct();Q9="data-reticle-overlay",pM=`
1226
+ `});var DW,NM,RM=y(()=>{"use strict";Zr();Lt();DW="data-reticle-overlay",NM=`
1227
1227
  [${B}]{
1228
1228
  position:absolute;right:0;left:auto;bottom:calc(100% + 12px);z-index:31;
1229
1229
  box-sizing:border-box;display:flex;flex-direction:column;width:var(--reticle-dock-w);
@@ -1233,11 +1233,11 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1233
1233
  background:
1234
1234
  radial-gradient(130% 90% at 50% 0%,color-mix(in srgb,var(--reticle-c-active) 18%,transparent),transparent 62%),
1235
1235
  linear-gradient(180deg,rgba(13,15,22,.96),rgba(19,22,32,.94));
1236
- box-shadow:${Gr},0 0 54px -18px var(--reticle-c-active);
1236
+ box-shadow:${Kr},0 0 54px -18px var(--reticle-c-active);
1237
1237
  color:var(--reticle-fg);font-family:var(--reticle-font);
1238
1238
  transition:opacity .18s ease,transform .18s ease,visibility .18s;}
1239
1239
  [${F}][${Xt}="start"] [${B}]{right:auto;left:0;}
1240
- [${Q9}][${On}="1"] [${B}]{
1240
+ [${DW}][${In}="1"] [${B}]{
1241
1241
  opacity:1;visibility:visible;transform:translate3d(0,0,0) scale(1);pointer-events:auto;}
1242
1242
  [${B}] .reticle-report-inner{
1243
1243
  display:flex;flex-direction:column;min-height:0;overflow:hidden;}
@@ -1372,15 +1372,15 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1372
1372
  @keyframes reticle-sync-spin{to{transform:rotate(360deg);}}
1373
1373
  @media (prefers-reduced-motion:reduce){
1374
1374
  [${B}] .reticle-sync-now[data-syncing="1"]{animation:none;}}
1375
- `});var hM,mM=y(()=>{"use strict";hM=`
1375
+ `});var OM,IM=y(()=>{"use strict";OM=`
1376
1376
  .reticle-talk-title{display:block;font-weight:600;font-size:12px;padding-right:18px;}
1377
1377
  .reticle-talk-body{margin:6px 0 8px;font-size:11px;line-height:1.45;opacity:.8;}
1378
1378
  .reticle-talk-book{display:inline-block;font-size:11px;font-weight:600;padding:4px 10px;border-radius:6px;background:var(--reticle-accent,#4f7cff);color:#fff;text-decoration:none;}
1379
- `});function Ox(e){let t=Rx.get(e);t!==void 0&&clearInterval(t),Rx.delete(e)}function tW(){var e;try{return((e=globalThis.matchMedia)==null?void 0:e.call(globalThis,"(prefers-reduced-motion: reduce)").matches)===!0}catch{return!1}}function Cg(e,t){e.setAttribute("data-active",String(t));let n=e.querySelectorAll(`[${vp}]`),r=e.querySelector(`[${TM}]`);r!==null&&(r.textContent=`${String(t+1)} / ${String(n.length)}`),n.forEach((o,i)=>{o.hidden=i!==t}),e.querySelectorAll(`[${Lg}]`).forEach((o,i)=>{o.setAttribute("aria-current",String(i===t))})}function rW(e,t){if(e.length===0)return"";let n=nW(t,e.length),r=e.map((i,s)=>`<div ${vp}="${i.id}" class="reticle-carousel-slide"${s===n?"":" hidden"}>${i.html}</div>`).join(""),o=e.length===1?"":`<div class="reticle-carousel-controls"><button type="button" ${_M} aria-label="Previous message" class="reticle-carousel-arrow">\u2039</button><div class="reticle-carousel-dots">${e.map((i,s)=>`<button type="button" ${Lg}="${String(s)}" class="reticle-carousel-dot" aria-label="Show ${i.id}" aria-current="${String(s===n)}"></button>`).join("")}</div><span ${TM} aria-live="polite">${String(n+1)} / ${String(e.length)}</span><button type="button" ${SM} aria-label="Next message" class="reticle-carousel-arrow">\u203A</button></div>`;return`<div ${EM} class="reticle-carousel" role="region" aria-label="Reticle" data-active="${String(n)}">
1380
- <button type="button" ${bM} class="reticle-carousel-close" aria-label="${gM}" title="${gM}">\xD7</button>
1379
+ `});function Hx(e){let t=Ux.get(e);t!==void 0&&clearInterval(t),Ux.delete(e)}function MW(){var e;try{return((e=globalThis.matchMedia)==null?void 0:e.call(globalThis,"(prefers-reduced-motion: reduce)").matches)===!0}catch{return!1}}function zg(e,t){e.setAttribute("data-active",String(t));let n=e.querySelectorAll(`[${Ip}]`),r=e.querySelector(`[${DM}]`);r!==null&&(r.textContent=`${String(t+1)} / ${String(n.length)}`),n.forEach((o,i)=>{o.hidden=i!==t}),e.querySelectorAll(`[${Dg}]`).forEach((o,i)=>{o.setAttribute("aria-current",String(i===t))})}function HW(e,t){if(e.length===0)return"";let n=UW(t,e.length),r=e.map((i,s)=>`<div ${Ip}="${i.id}" class="reticle-carousel-slide"${s===n?"":" hidden"}>${i.html}</div>`).join(""),o=e.length===1?"":`<div class="reticle-carousel-controls"><button type="button" ${kM} aria-label="Previous message" class="reticle-carousel-arrow">\u2039</button><div class="reticle-carousel-dots">${e.map((i,s)=>`<button type="button" ${Dg}="${String(s)}" class="reticle-carousel-dot" aria-label="Show ${i.id}" aria-current="${String(s===n)}"></button>`).join("")}</div><span ${DM} aria-live="polite">${String(n+1)} / ${String(e.length)}</span><button type="button" ${zM} aria-label="Next message" class="reticle-carousel-arrow">\u203A</button></div>`;return`<div ${LM} class="reticle-carousel" role="region" aria-label="Reticle" data-active="${String(n)}">
1380
+ <button type="button" ${$M} class="reticle-carousel-close" aria-label="${CM}" title="${CM}">\xD7</button>
1381
1381
  <div class="reticle-carousel-track">${r}</div>
1382
1382
  ${o}
1383
- </div>`}function oW(e){try{return(e==null?void 0:e.getItem(xM))==="1"}catch{return!1}}function AM(e,t,n){var a,l,u,d;let r=e.querySelector(`:scope > [${EM}]`),o=Number((a=r==null?void 0:r.getAttribute("data-active"))!=null?a:"0");if(r==null||r.remove(),Ox(e),oW(n))return;let i=rW(t,o);if(i==="")return;e.insertAdjacentHTML("afterbegin",i);let s=e.firstElementChild;if(s instanceof HTMLElement){(l=s.querySelector(`[${bM}]`))==null||l.addEventListener("click",f=>{f.preventDefault(),f.stopPropagation();try{n==null||n.setItem(xM,"1")}catch{}Ox(e),s.remove()});for(let f of s.querySelectorAll(`[${Lg}]`))f.addEventListener("click",m=>{m.preventDefault(),m.stopPropagation(),Cg(s,Number(f.getAttribute(Lg)))});(u=s.querySelector(`[${_M}]`))==null||u.addEventListener("click",f=>{f.preventDefault(),f.stopPropagation(),Cg(s,(Number(s.getAttribute("data-active"))+t.length-1)%t.length)}),(d=s.querySelector(`[${SM}]`))==null||d.addEventListener("click",f=>{f.preventDefault(),f.stopPropagation(),Cg(s,(Number(s.getAttribute("data-active"))+1)%t.length)}),iW(e,s,t.length)}}function iW(e,t,n){if(n<2||tW())return;let r=!1,o=()=>{r=!0},i=()=>{r=!1};t.addEventListener("mouseenter",o),t.addEventListener("mouseleave",i),t.addEventListener("focusin",o),t.addEventListener("focusout",i),Rx.set(e,setInterval(()=>{if(!t.isConnected){Ox(e);return}r||Cg(t,(Number(t.getAttribute("data-active"))+1)%n)},eW))}var EM,vp,Lg,bM,_M,SM,TM,xM,gM,eW,Rx,nW,yM,$g=y(()=>{"use strict";po();EM="data-reticle-carousel",vp="data-reticle-carousel-slide",Lg="data-reticle-carousel-dot",bM="data-reticle-carousel-close",_M="data-reticle-carousel-prev",SM="data-reticle-carousel-next",TM="data-reticle-carousel-position",xM=At.CAROUSEL_DISMISSED,gM="Close",eW=6e3,Rx=new WeakMap;nW=(e,t)=>Number.isInteger(e)&&e>=0&&e<t?e:0;yM=`
1383
+ </div>`}function FW(e){try{return(e==null?void 0:e.getItem(PM))==="1"}catch{return!1}}function MM(e,t,n){var a,l,u,d;let r=e.querySelector(`:scope > [${LM}]`),o=Number((a=r==null?void 0:r.getAttribute("data-active"))!=null?a:"0");if(r==null||r.remove(),Hx(e),FW(n))return;let i=HW(t,o);if(i==="")return;e.insertAdjacentHTML("afterbegin",i);let s=e.firstElementChild;if(s instanceof HTMLElement){(l=s.querySelector(`[${$M}]`))==null||l.addEventListener("click",f=>{f.preventDefault(),f.stopPropagation();try{n==null||n.setItem(PM,"1")}catch{}Hx(e),s.remove()});for(let f of s.querySelectorAll(`[${Dg}]`))f.addEventListener("click",m=>{m.preventDefault(),m.stopPropagation(),zg(s,Number(f.getAttribute(Dg)))});(u=s.querySelector(`[${kM}]`))==null||u.addEventListener("click",f=>{f.preventDefault(),f.stopPropagation(),zg(s,(Number(s.getAttribute("data-active"))+t.length-1)%t.length)}),(d=s.querySelector(`[${zM}]`))==null||d.addEventListener("click",f=>{f.preventDefault(),f.stopPropagation(),zg(s,(Number(s.getAttribute("data-active"))+1)%t.length)}),BW(e,s,t.length)}}function BW(e,t,n){if(n<2||MW())return;let r=!1,o=()=>{r=!0},i=()=>{r=!1};t.addEventListener("mouseenter",o),t.addEventListener("mouseleave",i),t.addEventListener("focusin",o),t.addEventListener("focusout",i),Ux.set(e,setInterval(()=>{if(!t.isConnected){Hx(e);return}r||zg(t,(Number(t.getAttribute("data-active"))+1)%n)},PW))}var LM,Ip,Dg,$M,kM,zM,DM,PM,CM,PW,Ux,UW,UM,Pg=y(()=>{"use strict";ho();LM="data-reticle-carousel",Ip="data-reticle-carousel-slide",Dg="data-reticle-carousel-dot",$M="data-reticle-carousel-close",kM="data-reticle-carousel-prev",zM="data-reticle-carousel-next",DM="data-reticle-carousel-position",PM=At.CAROUSEL_DISMISSED,CM="Close",PW=6e3,Ux=new WeakMap;UW=(e,t)=>Number.isInteger(e)&&e>=0&&e<t?e:0;UM=`
1384
1384
  .reticle-carousel{position:relative;margin:8px 10px;padding:10px 12px 8px;border:1px solid var(--reticle-line,#2a2f3a);border-radius:10px;background:var(--reticle-surface-inset,rgba(255,255,255,.03));}
1385
1385
  .reticle-carousel-track{height:100px;overflow:hidden;}
1386
1386
  .reticle-carousel-slide .reticle-talk{margin:0;padding:0;border:0;background:none;}
@@ -1393,23 +1393,23 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1393
1393
  .reticle-carousel-arrow{width:24px;height:24px;flex:none;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--reticle-line);border-radius:6px;background:rgba(255,255,255,.04);color:var(--reticle-fg);font:inherit;font-size:18px;line-height:1;cursor:pointer;}
1394
1394
  .reticle-carousel-arrow:hover{border-color:var(--reticle-accent);background:var(--reticle-accent-soft);}
1395
1395
  .reticle-carousel-position{margin-left:auto;color:var(--reticle-muted);font-size:11px;font-variant-numeric:tabular-nums;white-space:nowrap;}
1396
- `});function RM(e,t){let n=e.querySelector(`[${xr}]`),r=e.querySelector(`[${tt}]`),o=t!==void 0&&!t.signedIn;n!==null&&(n.hidden=!o),r!==null&&(r.hidden=o)}var tt,xr,$x,sW,Jt,kg,Ix,vM,NM,Cx,Lx,wM,OM,zg=y(()=>{"use strict";xo();Ct();Vr();tt="data-reticle-rail",xr="data-reticle-rail-signin",$x="data-reticle-rail-promo",sW="data-reticle-page-open",Jt="data-reticle-page-panel",kg="data-reticle-overlay",Ix={TITLE:"Sign in to try Reticle Harness",DETAIL:"Free credits to start.",CTA:"Sign in"},vM=`<div ${xr} class="reticle-rail-signin" hidden>
1397
- <span class="reticle-rail-copy"><strong>${Ix.TITLE}</strong><span>${Ix.DETAIL}</span></span>
1398
- <button type="button" ${qt} class="reticle-rail-cta" title="${fe.SIGNIN_TITLE}">${Ix.CTA}</button>
1399
- </div>`,NM=`<div ${tt} class="reticle-rail" role="complementary" aria-label="Reticle">
1400
- <div ${$x} class="reticle-rail-promo"></div>
1401
- </div>`;Cx=`:is([${En}],[${Jt}],[${B}],[${P}])`,Lx=`[${kg}][${Ze}="0"]:is([${yt}="1"],[${sW}],[${On}="1"],[${ft}="1"])`,wM=`[${F}]:is([${fi}="below"],[${is}="below"])`,OM=`
1396
+ `});function GM(e,t){let n=e.querySelector(`[${yr}]`),r=e.querySelector(`[${rt}]`),o=t!==void 0&&!t.signedIn;n!==null&&(n.hidden=!o),r!==null&&(r.hidden=o)}var rt,yr,Vx,GW,Jt,Mg,Fx,FM,BM,Bx,Gx,HM,VM,Ug=y(()=>{"use strict";yo();Lt();Zr();rt="data-reticle-rail",yr="data-reticle-rail-signin",Vx="data-reticle-rail-promo",GW="data-reticle-page-open",Jt="data-reticle-page-panel",Mg="data-reticle-overlay",Fx={TITLE:"Sign in to try Reticle Harness",DETAIL:"Free credits to start.",CTA:"Sign in"},FM=`<div ${yr} class="reticle-rail-signin" hidden>
1397
+ <span class="reticle-rail-copy"><strong>${Fx.TITLE}</strong><span>${Fx.DETAIL}</span></span>
1398
+ <button type="button" ${qt} class="reticle-rail-cta" title="${he.SIGNIN_TITLE}">${Fx.CTA}</button>
1399
+ </div>`,BM=`<div ${rt} class="reticle-rail" role="complementary" aria-label="Reticle">
1400
+ <div ${Vx} class="reticle-rail-promo"></div>
1401
+ </div>`;Bx=`:is([${En}],[${Jt}],[${B}],[${P}])`,Gx=`[${Mg}][${We}="0"]:is([${yt}="1"],[${GW}],[${In}="1"],[${ft}="1"])`,HM=`[${F}]:is([${gi}="below"],[${ss}="below"])`,VM=`
1402
1402
  [${F}]{
1403
1403
  /* Short enough to leave most of a laptop screen to the app; the log scrolls inside it. */
1404
1404
  --reticle-frame-h:min(440px,60vh,calc(100vh - 190px));
1405
1405
  --reticle-rail-h:52px;--reticle-frame-gap:6px;}
1406
- [${F}] ${Cx}{
1406
+ [${F}] ${Bx}{
1407
1407
  right:0;left:auto;top:auto;
1408
1408
  bottom:calc(100% + 8px + var(--reticle-rail-h) + var(--reticle-frame-gap));
1409
1409
  width:var(--reticle-dock-w);max-width:min(var(--reticle-dock-w),calc(100vw - 24px));
1410
1410
  height:var(--reticle-frame-h);max-height:var(--reticle-frame-h);
1411
1411
  border-radius:var(--reticle-hud-radius-lg);
1412
- ${cl}}
1412
+ ${dl}}
1413
1413
  [${F}] [${P}]::after{display:none;}
1414
1414
  [${F}] [${P}] .reticle-settings-inner{height:100%;}
1415
1415
  [${F}] [${P}] :is(.reticle-settings-body,.reticle-settings-foot){background:transparent;}
@@ -1422,17 +1422,17 @@ ${NP}`,Ex="[data-reticle-harness-page] :is([data-reticle-harness-run],[data-reti
1422
1422
  * handoff notice) takes the status text's place instead of arriving as a row of its own, and the
1423
1423
  * Harness block sits in the footer above the project capsule.
1424
1424
  */
1425
- [${kg}] [${En}] .reticle-act-strip .reticle-banner{display:none;flex:1;min-width:0;min-height:0;padding:0;border:0;background:none;
1425
+ [${Mg}] [${En}] .reticle-act-strip .reticle-banner{display:none;flex:1;min-width:0;min-height:0;padding:0;border:0;background:none;
1426
1426
  font-size:11px;font-weight:600;line-height:1.3;color:var(--reticle-hud-text);
1427
1427
  overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:2;}
1428
- [${kg}][data-reticle-state="ended"] [${En}] .reticle-act-strip .reticle-banner{display:-webkit-box;}
1429
- [${kg}][data-reticle-state="ended"] [${En}] .reticle-act-strip .reticle-act{display:none;}
1428
+ [${Mg}][data-reticle-state="ended"] [${En}] .reticle-act-strip .reticle-banner{display:-webkit-box;}
1429
+ [${Mg}][data-reticle-state="ended"] [${En}] .reticle-act-strip .reticle-act{display:none;}
1430
1430
  [${En}] .reticle-foot-workspace-row{gap:var(--reticle-hud-space-2);}
1431
1431
  /* The Harness block sits above the project capsule, full width: one clear thing to press. */
1432
1432
  [${En}] [data-reticle-foot] .reticle-foot-stack{display:flex;flex-direction:column;gap:var(--reticle-hud-space-2);}
1433
1433
  [${En}] [data-reticle-foot] .reticle-foot-workspace-row:has(> .reticle-workspace-wrap[hidden]){display:none;}
1434
- ${wM} ${Cx}{bottom:auto;top:calc(100% + 8px + var(--reticle-rail-h) + var(--reticle-frame-gap));}
1435
- [${F}][${Xt}="start"] :is(${Cx},[${tt}]){right:auto;left:0;}
1434
+ ${HM} ${Bx}{bottom:auto;top:calc(100% + 8px + var(--reticle-rail-h) + var(--reticle-frame-gap));}
1435
+ [${F}][${Xt}="start"] :is(${Bx},[${rt}]){right:auto;left:0;}
1436
1436
 
1437
1437
  /* \u2500\u2500 Every page's header: title over a one-line subtitle, its actions, then close. \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 */
1438
1438
  [${F}] :is(.reticle-page-heading,.reticle-report-head,.reticle-settings-head){
@@ -1514,52 +1514,52 @@ ${wM} ${Cx}{bottom:auto;top:calc(100% + 8px + var(--reticle-rail-h) + var(--reti
1514
1514
  [data-reticle-hud] .reticle-toolbar-chrome .reticle-tb-btn[data-active="1"],
1515
1515
  [data-reticle-hud] .reticle-toolbar-chrome .reticle-tb-btn[data-active="1"]:hover{background:transparent;color:var(--reticle-hud-text);}
1516
1516
 
1517
- [${tt}]{
1517
+ [${rt}]{
1518
1518
  display:none;position:absolute;right:0;left:auto;bottom:calc(100% + 8px);z-index:7;
1519
1519
  box-sizing:border-box;width:var(--reticle-dock-w);max-width:min(var(--reticle-dock-w),calc(100vw - 24px));
1520
1520
  height:var(--reticle-rail-h);padding:0 var(--reticle-hud-space-3);align-items:center;
1521
1521
  border:1px solid color-mix(in srgb,var(--reticle-hud-brand) 30%,var(--reticle-hud-border));
1522
1522
  border-radius:var(--reticle-hud-radius-lg);
1523
1523
  background:linear-gradient(135deg,var(--reticle-hud-brand-soft),var(--reticle-hud-surface) 65%);
1524
- box-shadow:${Gr};color:var(--reticle-hud-text);font-family:var(--reticle-font);
1524
+ box-shadow:${Kr};color:var(--reticle-hud-text);font-family:var(--reticle-font);
1525
1525
  pointer-events:auto;}
1526
- ${wM} [${tt}]{bottom:auto;top:calc(100% + 8px);}
1527
- ${Lx} [${tt}]{display:flex;}
1528
- ${Lx} [${tt}][hidden]{display:none;}
1526
+ ${HM} [${rt}]{bottom:auto;top:calc(100% + 8px);}
1527
+ ${Gx} [${rt}]{display:flex;}
1528
+ ${Gx} [${rt}][hidden]{display:none;}
1529
1529
  /* No rail, no gap for it: the page sits straight above the toolbar. */
1530
- [${F}]:has(> [${tt}][hidden]){--reticle-rail-h:0px;--reticle-frame-gap:0px;}
1530
+ [${F}]:has(> [${rt}][hidden]){--reticle-rail-h:0px;--reticle-frame-gap:0px;}
1531
1531
  /* The capsule and the rail share a slot: the capsule is for "nothing open", the rail for "a page is". */
1532
- ${Lx} [${Ht}]{display:none !important;}
1533
- [${tt}] > [hidden]{display:none !important;}
1534
- [${tt}] .reticle-rail-promo{flex:1;min-width:0;}
1532
+ ${Gx} [${Ft}]{display:none !important;}
1533
+ [${rt}] > [hidden]{display:none !important;}
1534
+ [${rt}] .reticle-rail-promo{flex:1;min-width:0;}
1535
1535
  /* The sign-in ask: one row in the Agent Log, above its footer. */
1536
- [${xr}]{display:flex;flex:none;align-items:center;gap:var(--reticle-hud-space-3);
1536
+ [${yr}]{display:flex;flex:none;align-items:center;gap:var(--reticle-hud-space-3);
1537
1537
  margin:0 var(--reticle-hud-space-3) var(--reticle-hud-space-2);padding:var(--reticle-hud-space-2) var(--reticle-hud-space-3);
1538
1538
  border:1px solid color-mix(in srgb,var(--reticle-hud-brand) 30%,var(--reticle-hud-border));border-radius:var(--reticle-hud-radius-md);
1539
1539
  background:linear-gradient(135deg,var(--reticle-hud-brand-soft),transparent 65%);}
1540
- [${xr}][hidden]{display:none;}
1541
- [${xr}] .reticle-rail-copy{display:flex;flex:1;min-width:0;flex-direction:column;line-height:1.3;}
1542
- [${xr}] .reticle-rail-copy strong{font-size:var(--reticle-hud-size-sm);font-weight:600;}
1543
- [${xr}] .reticle-rail-copy span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--reticle-hud-size-xs);color:var(--reticle-hud-text-muted);}
1544
- [${xr}] .reticle-rail-cta{flex:none;height:28px;padding:0 var(--reticle-hud-space-3);border:0;border-radius:var(--reticle-hud-radius-pill);
1540
+ [${yr}][hidden]{display:none;}
1541
+ [${yr}] .reticle-rail-copy{display:flex;flex:1;min-width:0;flex-direction:column;line-height:1.3;}
1542
+ [${yr}] .reticle-rail-copy strong{font-size:var(--reticle-hud-size-sm);font-weight:600;}
1543
+ [${yr}] .reticle-rail-copy span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--reticle-hud-size-xs);color:var(--reticle-hud-text-muted);}
1544
+ [${yr}] .reticle-rail-cta{flex:none;height:28px;padding:0 var(--reticle-hud-space-3);border:0;border-radius:var(--reticle-hud-radius-pill);
1545
1545
  background:var(--reticle-hud-brand);color:#160b02;font:inherit;font-size:var(--reticle-hud-size-sm);font-weight:700;cursor:pointer;}
1546
- [${xr}] .reticle-rail-cta:hover{filter:brightness(1.08);}
1547
- [${xr}] .reticle-rail-cta:focus-visible{outline:2px solid var(--reticle-hud-text);outline-offset:2px;}
1546
+ [${yr}] .reticle-rail-cta:hover{filter:brightness(1.08);}
1547
+ [${yr}] .reticle-rail-cta:focus-visible{outline:2px solid var(--reticle-hud-text);outline-offset:2px;}
1548
1548
  /* The promo: one line of copy, its link, and dots. The carousel draws no frame of its own here. */
1549
- [${tt}] .reticle-carousel{margin:0;padding:0;border:0;background:none;}
1550
- [${tt}] .reticle-carousel-track{height:32px;overflow:hidden;}
1551
- [${tt}] :is(.reticle-carousel-close,.reticle-carousel-arrow,[data-reticle-carousel-position]){display:none;}
1552
- [${tt}] .reticle-carousel-controls{position:absolute;right:var(--reticle-hud-space-3);top:6px;height:auto;margin:0;}
1553
- [${tt}] .reticle-carousel-dots{position:static;display:flex;gap:4px;margin:0;}
1554
- [${tt}] .reticle-carousel-dot{width:10px;height:3px;padding:0;border:0;border-radius:99px;background:var(--reticle-hud-text-muted);opacity:.35;cursor:pointer;}
1555
- [${tt}] .reticle-carousel-dot[aria-current="true"]{background:var(--reticle-hud-brand);opacity:1;}
1556
- [${tt}] .reticle-promo-copy{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:8px;padding-right:0;}
1557
- [${tt}] .reticle-promo-kicker{display:none;}
1558
- [${tt}] .reticle-promo-title{grid-column:1/-1;overflow:hidden;padding-right:40px;font-size:var(--reticle-hud-size-sm);font-weight:600;line-height:1.3;text-overflow:ellipsis;white-space:nowrap;}
1559
- [${tt}] .reticle-promo-detail{grid-column:1;overflow:hidden;color:var(--reticle-hud-text-muted);font-size:var(--reticle-hud-size-xs);line-height:1.3;text-overflow:ellipsis;white-space:nowrap;}
1560
- [${tt}] .reticle-promo-link{position:static;grid-column:2;color:var(--reticle-hud-brand);font-size:var(--reticle-hud-size-xs);font-weight:600;text-decoration:none;white-space:nowrap;}
1561
- [${tt}] .reticle-promo-link:hover{text-decoration:underline;}
1562
- `});var IM,CM=y(()=>{"use strict";IM=`
1549
+ [${rt}] .reticle-carousel{margin:0;padding:0;border:0;background:none;}
1550
+ [${rt}] .reticle-carousel-track{height:32px;overflow:hidden;}
1551
+ [${rt}] :is(.reticle-carousel-close,.reticle-carousel-arrow,[data-reticle-carousel-position]){display:none;}
1552
+ [${rt}] .reticle-carousel-controls{position:absolute;right:var(--reticle-hud-space-3);top:6px;height:auto;margin:0;}
1553
+ [${rt}] .reticle-carousel-dots{position:static;display:flex;gap:4px;margin:0;}
1554
+ [${rt}] .reticle-carousel-dot{width:10px;height:3px;padding:0;border:0;border-radius:99px;background:var(--reticle-hud-text-muted);opacity:.35;cursor:pointer;}
1555
+ [${rt}] .reticle-carousel-dot[aria-current="true"]{background:var(--reticle-hud-brand);opacity:1;}
1556
+ [${rt}] .reticle-promo-copy{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:8px;padding-right:0;}
1557
+ [${rt}] .reticle-promo-kicker{display:none;}
1558
+ [${rt}] .reticle-promo-title{grid-column:1/-1;overflow:hidden;padding-right:40px;font-size:var(--reticle-hud-size-sm);font-weight:600;line-height:1.3;text-overflow:ellipsis;white-space:nowrap;}
1559
+ [${rt}] .reticle-promo-detail{grid-column:1;overflow:hidden;color:var(--reticle-hud-text-muted);font-size:var(--reticle-hud-size-xs);line-height:1.3;text-overflow:ellipsis;white-space:nowrap;}
1560
+ [${rt}] .reticle-promo-link{position:static;grid-column:2;color:var(--reticle-hud-brand);font-size:var(--reticle-hud-size-xs);font-weight:600;text-decoration:none;white-space:nowrap;}
1561
+ [${rt}] .reticle-promo-link:hover{text-decoration:underline;}
1562
+ `});var jM,KM=y(()=>{"use strict";jM=`
1563
1563
  [data-reticle-overlay]{
1564
1564
  --reticle-hud-space-0:0px;
1565
1565
  --reticle-hud-space-1:4px;
@@ -1592,8 +1592,8 @@ ${Lx} [${Ht}]{display:none !important;}
1592
1592
  --reticle-hud-brand-soft:#2a1b0d;
1593
1593
  --reticle-hud-ease:cubic-bezier(.4,0,.2,1);
1594
1594
  }
1595
- `});var LM,$M=y(()=>{"use strict";di();vx();aM();CT();dM();Vr();fM();mM();$g();wg();pg();zg();CM();LM=`
1596
- ${IM}
1595
+ `});var ZM,WM=y(()=>{"use strict";hi();Px();xM();BT();vM();Zr();RM();IM();Pg();Og();gg();Ug();KM();ZM=`
1596
+ ${jM}
1597
1597
  [data-reticle-overlay]{position:fixed;inset:0;pointer-events:none;z-index:${String(2147483600)};}
1598
1598
  /**
1599
1599
  * The session glow: the page itself says an agent is here, and BREATHES while it is working.
@@ -1643,97 +1643,97 @@ ${IM}
1643
1643
  [data-reticle-overlay] .reticle-sl-icon{display:inline-flex;align-items:center;justify-content:center;line-height:1;flex-shrink:0;color:inherit;overflow:visible;}
1644
1644
  [data-reticle-overlay] .reticle-hi-icon svg,
1645
1645
  [data-reticle-overlay] .reticle-sl-icon svg{display:block;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;overflow:visible;}
1646
- ${o1}
1647
- ${i1}
1648
- ${sM}
1649
- ${rg}
1646
+ ${_1}
1647
+ ${S1}
1648
+ ${TM}
1649
+ ${ag}
1650
+ ${NM}
1651
+ ${wM}
1652
+ ${OM}
1653
+ ${UM}
1654
+ ${QD}
1655
+ ${rM}
1656
+ ${AP}
1650
1657
  ${pM}
1651
- ${uM}
1652
- ${hM}
1653
- ${yM}
1654
- ${MD}
1655
- ${BP}
1656
- ${cP}
1657
- ${qP}
1658
- ${OM}`});function UM(){let e=Ie(se.REMOVE,Ae.MIN);return`<div ${B} class="reticle-report ${Xn}" role="region" aria-label="Reticle impact" aria-hidden="true">
1658
+ ${VM}`});function e2(){let e=Ce(se.REMOVE,ye.MIN);return`<div ${B} class="reticle-report ${Xn}" role="region" aria-label="Reticle impact" aria-hidden="true">
1659
1659
  <div class="reticle-report-inner">
1660
1660
  <div class="reticle-report-head">
1661
- <span class="reticle-report-title">${Q.TITLE}</span>
1662
- <span class="reticle-segmented reticle-report-scopes" role="group" aria-label="${Q.SCOPE_LABEL}"><button type="button" ${Pg}="${kx.PROJECT}" aria-pressed="true">${Q.PROJECT}</button><button type="button" ${Pg}="${kx.MACHINE}" aria-pressed="false" title="${Q.GLOBAL_TITLE}">${Q.GLOBAL}</button></span>
1663
- <button type="button" ${yT} class="reticle-report-close" title="Close" aria-label="Close impact">${e}</button>
1661
+ <span class="reticle-report-title">${ee.TITLE}</span>
1662
+ <span class="reticle-segmented reticle-report-scopes" role="group" aria-label="${ee.SCOPE_LABEL}"><button type="button" ${Fg}="${jx.PROJECT}" aria-pressed="true">${ee.PROJECT}</button><button type="button" ${Fg}="${jx.MACHINE}" aria-pressed="false" title="${ee.GLOBAL_TITLE}">${ee.GLOBAL}</button></span>
1663
+ <button type="button" ${zT} class="reticle-report-close" title="Close" aria-label="Close impact">${e}</button>
1664
1664
  </div>
1665
1665
  <div class="reticle-report-body" data-reticle-report-body></div>
1666
- <div class="reticle-report-foot" role="group" aria-label="${Q.SHARE_LABEL}">
1667
- <span class="reticle-report-share-label">${Q.SHARE_LABEL}</span>
1668
- <button type="button" ${zM} class="reticle-report-share">${Q.POST_X}</button>
1669
- <button type="button" ${DM} class="reticle-report-share">${Q.POST_IN}</button>
1670
- <button type="button" ${PM} class="reticle-report-share">${Q.COPY}</button>
1671
- <button type="button" ${MM} class="reticle-report-share reticle-report-refer">${Q.REFER}</button>
1666
+ <div class="reticle-report-foot" role="group" aria-label="${ee.SHARE_LABEL}">
1667
+ <span class="reticle-report-share-label">${ee.SHARE_LABEL}</span>
1668
+ <button type="button" ${XM} class="reticle-report-share">${ee.POST_X}</button>
1669
+ <button type="button" ${qM} class="reticle-report-share">${ee.POST_IN}</button>
1670
+ <button type="button" ${JM} class="reticle-report-share">${ee.COPY}</button>
1671
+ <button type="button" ${QM} class="reticle-report-share reticle-report-refer">${ee.REFER}</button>
1672
1672
  </div>
1673
1673
  <div class="reticle-report-links">
1674
- <a data-reticle-link="docs" href="${ds.DOCS}" target="_blank" rel="noreferrer noopener">Docs</a>
1675
- <a data-reticle-link="github" href="${ds.GITHUB}" target="_blank" rel="noreferrer noopener">GitHub</a>
1676
- <a data-reticle-link="site" href="${ds.SITE}" target="_blank" rel="noreferrer noopener">reticle.sh</a>
1677
- <a data-reticle-link="discord" href="${ds.DISCORD}" target="_blank" rel="noreferrer noopener">Discord</a>
1674
+ <a data-reticle-link="docs" href="${ps.DOCS}" target="_blank" rel="noreferrer noopener">Docs</a>
1675
+ <a data-reticle-link="github" href="${ps.GITHUB}" target="_blank" rel="noreferrer noopener">GitHub</a>
1676
+ <a data-reticle-link="site" href="${ps.SITE}" target="_blank" rel="noreferrer noopener">reticle.sh</a>
1677
+ <a data-reticle-link="discord" href="${ps.DISCORD}" target="_blank" rel="noreferrer noopener">Discord</a>
1678
1678
  </div>
1679
1679
  </div>
1680
- </div>`}function ms(e,t,n){let r=n===void 0?"":`<span class="reticle-report-basis" title="${n}">${Q.ESTIMATE_TAG}</span>`;return`<div class="reticle-report-card"><span class="reticle-report-value">${e}</span><span class="reticle-report-label">${t}${r}</span></div>`}function cW(e){let t=e.days.slice(-30);if(t.length===0)return"";let n=Math.max(1,...t.map(o=>o.counts.verdicts)),r=t.map(o=>{let i=Math.max(4,Math.round(o.counts.verdicts/n*100)),s=`${o.date}: ${String(o.counts.verdicts)} verdicts, ${String(o.counts.failed)} defects`,a=o.counts.failed>0?' data-hot="1"':"";return`<span class="reticle-report-bar" style="height:${String(i)}%" title="${s}"${a}></span>`}).join("");return`<div class="reticle-report-chart-wrap"><span class="reticle-report-section">${Q.CHART}</span><div class="reticle-report-chart">${r}</div></div>`}function lW(e,t){var u;let n=((u=e.defects)!=null?u:[]).slice(0,w0);if(n.length===0)return"";let r=t!==void 0&&Er(t),o=r?`<a class="reticle-report-defect-link" data-reticle-link="defect" href="${de(t)}" target="_blank" rel="noreferrer noopener" title="${Q.DEFECT_LINK_TITLE}" aria-label="${Q.DEFECT_LINK_TITLE}">${Ie(se.VIEW,Ae.SEND)}</a>`:"",i=n.map(d=>{let f=d.detail===void 0?"":`<span class="reticle-report-defect-detail">${de(d.detail)}</span>`,m=d.source===void 0?"":`<span class="reticle-report-defect-source">${de(d.source)}</span>`;return`<li class="reticle-report-defect"><span class="reticle-report-defect-title">${de(d.title)}</span>${f}${m}${o}</li>`}).join(""),s=e.counts.failed>n.length,a=r?`<a class="reticle-report-defects-more" data-reticle-link="dashboard" href="${de(t)}" target="_blank" rel="noreferrer noopener">${Q.DEFECTS_MORE}${s?` (${String(e.counts.failed)})`:""}</a>`:s?`<button type="button" data-reticle-defects-all ${qt} class="reticle-report-defects-all" title="${Q.DEFECTS_SEE_ALL_TITLE}">${Q.DEFECTS_SEE_ALL} (${String(e.counts.failed)}) \u2192</button>`:"",l=MT(t);return`<div class="reticle-report-defects-wrap"><div class="reticle-report-defects-head"><span class="reticle-report-section">${Q.DEFECTS}</span>${l}</div><ul class="reticle-report-defects">${i}</ul>${a}</div>`}function uW(e){if(e===void 0)return"";let t=l=>typeof e[l]=="number"?e[l]:0,n=e.status,r=typeof e.keyRefused=="string"?e.keyRefused:void 0,o=r!==void 0?Q.KEY_REFUSED:n==="refused"?`${String(t("refused"))} refused`:n==="pending"?`${String(t("pending"))} waiting`:n==="on-platform"?`Synced \xB7 ${String(t("onPlatform"))}`:n==="local-only"?`${String(t("pending"))} ${Q.NOT_SENT}`:void 0;if(o===void 0)return"";let i=r!==void 0?r:n==="local-only"?Q.NOT_SENT_HELP:typeof e.said=="string"?e.said:"",s=e.runUrl,a=typeof s=="string"&&Er(s)?` <a class="reticle-sync-run" data-reticle-link="run" href="${de(s)}" target="_blank" rel="noreferrer noopener">${Q.SEE_RUN}</a>`:"";return`<span class="reticle-sync-status" data-reticle-sync-status="${de(String(n))}" title="${de(i)}">${o}</span>${a}`}function dW(e){var i,s;if(e===void 0)return"";let t=wP.filter(a=>typeof e[a.key]=="number");if(t.length===0)return"";let n=a=>{var l;return`${String(Math.round((l=e[a])!=null?l:0))}%`},r=typeof e.proved=="number"?n("proved"):n((s=(i=t[0])==null?void 0:i.key)!=null?s:""),o=t.map(a=>`<span class="reticle-report-coverage-level">${n(a.key)} ${a.label}</span>`).join("");return`<div class="reticle-report-coverage" title="${Q.COVERAGE_HELP}"><span class="reticle-report-section">${Q.COVERAGE}</span><span class="reticle-report-coverage-value">${r}</span><div class="reticle-report-coverage-levels">${o}</div></div>`}function pW(e,t,n,r,o,i){let s=e.counts;if(s.calls===0)return`<p class="reticle-report-empty">${Q.EMPTY}</p>`;let a=e.records.streakDays>0?`<span class="reticle-report-streak" title="Consecutive days with at least one verdict">\u{1F525} ${String(e.records.streakDays)} <span class="reticle-report-streak-label">${Q.STREAK}</span></span>`:"",l=`<div class="reticle-report-hero"><span class="reticle-report-hero-value">${yo(s.failed)}</span><span class="reticle-report-hero-label">${Q.heroDefects(s.failed)}</span></div>`,u=`<div class="reticle-report-verdicts" title="${Q.UNKNOWN_HELP}">
1681
- <span class="reticle-report-verdict" data-kind="pass">${yo(s.passed)} ${Q.PASSED}</span>
1682
- <span class="reticle-report-verdict" data-kind="fail">${yo(s.failed)} ${Q.FAILED}</span>
1683
- <span class="reticle-report-verdict" data-kind="unknown">${yo(s.unknown)} ${Q.UNKNOWN}</span>
1684
- </div>`,d=[ms(yo(s.verdicts),Q.VERDICTS),ms(yo(s.calls),Q.CALLS),ms(gp(s.drivingMs),Q.DRIVING),ms(yo(s.sessions),Q.SESSIONS),ms(gp(e.records.longestRunMs),Q.LONGEST),ms(yo(s.tokensReturned),Q.TOKENS),ms(yo(e.savings.tokens.value),Q.SAVED_TOKENS,e.savings.tokens.basis),ms(gp(e.savings.minutes.value*6e4),Q.SAVED_MINUTES,e.savings.minutes.basis)].join(""),f=`<div class="reticle-report-identity">${hl(n,{dashboardUrl:t,projectName:r,verdicts:s.verdicts,defects:s.failed})}${MT(t)}${uW(i)}</div>`;return`<div class="reticle-report-top">${a}${f}</div>${l}${u}${dW(o)}<div class="reticle-report-grid">${d}</div>${lW(e,t)}${cW(e)}${fW(e,t,n)}`}function fW(e,t,n){if(t!==void 0||e.counts.verdicts<=0||n===void 0)return"";let[r,o,i]=n.signedIn?[Q.UNLINKED,Q.UNLINKED_ACTION,Q.UNLINKED_TAIL]:[Q.LOCAL_ONLY,Q.LOCAL_ONLY_ACTION,Q.LOCAL_ONLY_TAIL];return`<p class="reticle-report-local-only">${r} <code>${o}</code> ${i}</p>`}var Pg,kx,zM,DM,PM,MM,aW,hW,kM,Ra,Ml,gs,Ar,Es,Ul,Qt,HM,Dg,zx,Np,Mg,FM=y(()=>{"use strict";M();Hr();Vr();ha();xo();Ct();_g();Pg="data-reticle-report-scope",kx={PROJECT:"project",MACHINE:"machine"},zM="data-reticle-share-x",DM="data-reticle-share-in",PM="data-reticle-share-copy",MM="data-reticle-refer",aW=1600;hW=1200,kM="data-syncing",Mg=class{constructor(t={}){x(this,Qt);x(this,Ra);x(this,Ml);x(this,gs);x(this,Ar);x(this,Es,!1);x(this,Ul);g(this,Ul,t)}mount(t){var r,o,i,s,a,l,u;g(this,gs,t),g(this,Ra,(r=t.querySelector(`[${B}]`))!=null?r:void 0),g(this,Ml,(o=t.querySelector("[data-reticle-report-body]"))!=null?o:void 0),(i=t.querySelector(`[${yT}]`))==null||i.addEventListener("click",d=>{d.stopPropagation(),this.close()});let n=t.querySelectorAll(`[${Pg}]`);for(let d of n)d.addEventListener("click",f=>{f.stopPropagation(),g(this,Es,kx.MACHINE===d.getAttribute(Pg));for(let m of n)m.setAttribute("aria-pressed",m===d?"true":"false");T(this,Qt,Dg).call(this)});(s=t.querySelector(`[${zM}]`))==null||s.addEventListener("click",d=>{d.stopPropagation(),T(this,Qt,zx).call(this,xP(this.shareText()))}),(a=t.querySelector(`[${DM}]`))==null||a.addEventListener("click",d=>{d.stopPropagation(),T(this,Qt,Np).call(this,this.shareText()),T(this,Qt,zx).call(this,AP())}),(l=t.querySelector(`[${PM}]`))==null||l.addEventListener("click",d=>{d.stopPropagation(),T(this,Qt,Np).call(this,this.shareText(),d.currentTarget)}),(u=t.querySelector(`[${MM}]`))==null||u.addEventListener("click",d=>{d.stopPropagation(),T(this,Qt,Np).call(this,mx(),d.currentTarget)}),t.addEventListener("click",d=>{var E,_;let f=d.target;if(!(f instanceof Element))return;let m=f.closest(`[${qt}]`);if(m!==null){d.stopPropagation(),T(this,Qt,Np).call(this,fe.SIGNIN_COMMAND,m);return}let h=f.closest(`[${PT}]`);h!==null&&(d.stopPropagation(),(_=(E=c(this,Ul)).onSyncNow)==null||_.call(E),h.setAttribute(kM,"1"),setTimeout(()=>h.removeAttribute(kM),hW))})}setSnapshot(t){g(this,Ar,t),this.isOpen()&&T(this,Qt,Dg).call(this)}snapshot(){return c(this,Ar)}isOpen(){var t;return((t=c(this,gs))==null?void 0:t.getAttribute(On))==="1"}open(){var t,n,r;c(this,gs)!==void 0&&((n=(t=c(this,Ul)).onBeforeOpen)==null||n.call(t),T(this,Qt,Dg).call(this),c(this,gs).setAttribute(On,"1"),(r=c(this,Ra))==null||r.setAttribute("aria-hidden","false"))}close(){var t,n;(t=c(this,gs))==null||t.setAttribute(On,"0"),(n=c(this,Ra))==null||n.setAttribute("aria-hidden","true")}toggle(){this.isOpen()?this.close():this.open()}contains(t){var n;return((n=c(this,Ra))==null?void 0:n.contains(t))===!0}shareText(){let t=c(this,Ar);return t===void 0?mx():c(this,Es)?hx(t.global):hx(t.project,t.projectName)}};Ra=new WeakMap,Ml=new WeakMap,gs=new WeakMap,Ar=new WeakMap,Es=new WeakMap,Ul=new WeakMap,Qt=new WeakSet,HM=function(){let t=c(this,Ar);if(t!==void 0)return c(this,Es)?t.global:t.project},Dg=function(){var n,r,o,i,s;let t=T(this,Qt,HM).call(this);c(this,Ml)!==void 0&&(c(this,Ml).innerHTML=t===void 0?`<p class="reticle-report-empty">${Q.EMPTY}</p>`:pW(t,(n=c(this,Ar))==null?void 0:n.dashboardUrl,(r=c(this,Ar))==null?void 0:r.account,(o=c(this,Ar))==null?void 0:o.projectName,c(this,Es)||(i=c(this,Ar))==null?void 0:i.coverage,c(this,Es)||(s=c(this,Ar))==null?void 0:s.sync))},zx=function(t){window.open(t,"_blank","noopener,noreferrer")},Np=async function(t,n){var r,o;try{await((r=navigator.clipboard)==null?void 0:r.writeText(t))}catch{}if(n instanceof HTMLElement){let i=(o=n.textContent)!=null?o:"";n.textContent=Q.COPIED,window.setTimeout(()=>{n.textContent=i},aW)}}});function _W(e){let t=e.kicker===void 0?"":`<span class="reticle-promo-kicker">${de(e.kicker)}</span>`,n=e.detail===void 0?"":`<span class="reticle-promo-detail" title="${de(e.detail)}">${de(e.detail)}</span>`,r=e.cta===void 0?"":`<a data-reticle-promo-link class="reticle-promo-link" href="${de(e.cta.url)}" target="_blank" rel="noopener noreferrer">${de(e.cta.label)} \u2192</a>`;return{id:`${bW}${e.id}`,html:`<div class="reticle-promo-copy">${t}<strong class="reticle-promo-title">${de(e.title)}</strong>${n}${r}</div>`}}function GM(e=[],t=Uf){let n=e.flatMap(r=>{let o=LT.safeParse(r);return o.success&&!o.data.id.startsWith(EW)?[o.data]:[]});return 0<n.length?n.map(_W):[...gW(t)]}var mW,BM,Rp,gW,EW,bW,VM=y(()=>{"use strict";pl();ha();M();mW="/settings?group=billing",BM={REPLAY:"replay-confidence",NOTES:"notes-for-agent"},Rp={REPLAY_TITLE:"Replay what your agent verified",REPLAY_DETAIL:"Saved flows re-run after each edit.",REPLAY_LINK:"See how \u2192",NOTES_TITLE:"Point your agent at anything",NOTES_DETAIL:"Open Notes, then click an element."},gW=e=>[{id:BM.REPLAY,html:`<div class="reticle-promo-copy"><strong class="reticle-promo-title">${Rp.REPLAY_TITLE}</strong><span class="reticle-promo-detail">${Rp.REPLAY_DETAIL}</span><a data-reticle-promo-link class="reticle-promo-link" href="${e}${mW}" target="_blank" rel="noopener noreferrer">${Rp.REPLAY_LINK}</a></div>`},{id:BM.NOTES,html:`<div class="reticle-promo-copy"><strong class="reticle-promo-title">${Rp.NOTES_TITLE}</strong><span class="reticle-promo-detail">${Rp.NOTES_DETAIL}</span></div>`}],EW="harness",bW="notice-"});var SW,jM,Dx,TW,KM,ZM=y(()=>{"use strict";SW="Reticle",jM='<path d="M92.82 92.16C93.07 93.4 91.77 94.4 90.63 93.83C89.62 93.33 88.62 92.82 87.63 92.3C71.14 83.78 54.79 72.27 39.61 57.96C39.09 57.49 38.57 56.98 38.06 56.49C22.45 41.52 9.78 25.14 .33 8.52C0.29 8.45 .25 8.38 .2 8.31C-0.44 7.2 .51 5.84 1.79 6.05L24.07 9.71C43.06 12.83 60.63 11.75 75.55 6.53L93.95 .09C95.15-0.33 96.31 .78 95.93 1.98L90.1 20.49C85.37 35.48 84.9 52.97 88.69 71.73L92.83 92.16H92.82Z"/><path d="M58.72 89.23L6.15 92.8C5.24 92.86 4.48 92.13 4.51 91.22L6.56 30.39C6.61 28.91 8.51 28.36 9.35 29.57C16.23 39.43 24.98 52.35 33.01 61.26C41.05 70.17 50.6 78.72 59.62 86.56C60.65 87.45 60.08 89.13 58.72 89.23Z"/>',Dx=`<svg class="reticle-mark" viewBox="0 0 96 94" fill="currentColor" aria-hidden="true">${jM}</svg>`,TW=`<svg class="reticle-fab-mark" viewBox="0 0 96 94" fill="currentColor" aria-hidden="true">${jM}</svg>`,KM=`<button type="button" class="reticle-fab" data-reticle-fab aria-label="Start ${SW}" aria-expanded="false">${TW}<span class="reticle-fab-pulse" aria-hidden="true"></span><span data-reticle-mark-count class="reticle-fab-badge" hidden>0</span></button>`});function Ux(e,t=[],n){let r=e.querySelector(`[${$x}]`);if(r===null)return;let o;try{o=window.sessionStorage}catch{o=void 0}AM(r,GM(t,n),o)}function QM(){try{return globalThis.sessionStorage.getItem(Km)==="1"}catch{return!1}}function qM(e){try{e?globalThis.sessionStorage.setItem(Km,"1"):globalThis.sessionStorage.removeItem(Km)}catch{}}function yW(){try{return globalThis.localStorage.getItem(Zm)==="1"}catch{return!1}}function Hl(e){try{e?globalThis.localStorage.setItem(Zm,"1"):globalThis.localStorage.removeItem(Zm)}catch{}}function Bx(){return yW()&&!QM()}function e2(e){return e&&!QM()}var WM,xW,YM,XM,Px,AW,Mx,$e,en,yr,Oa,Fl,Vt,bt,Bl,Gl,Ia,Ca,Co,bs,La,$a,Lo,Yr,ka,Vl,Ip,_i,jl,Cn,Ug,Hx,Fx,JM,Hg,Fg,Op,Gx=y(()=>{"use strict";nt();FM();nx();xo();gl();Ct();$g();VM();zg();ZM();di();IT();op();Hr();Vr();wg();gl();WM="reticle-toolbar-drag",xW=120,YM="Minimise chat",XM="Open agent chat",Px="Settings",AW="Reticle",Mx="Exit";Op=class{constructor(t={}){x(this,Cn);x(this,$e);x(this,en);x(this,yr);x(this,Oa);x(this,Fl);x(this,Vt);x(this,bt);x(this,Bl);x(this,Gl);x(this,Ia,!1);x(this,Ca,!1);x(this,Co);x(this,bs,!1);x(this,La);x(this,$a);x(this,Lo,new Mg({onBeforeOpen:()=>{c(this,Vt).close(),this.closeChat()},onSyncNow:()=>{var t,n;return(n=(t=c(this,Yr)).onSyncNow)==null?void 0:n.call(t)}}));x(this,Yr);x(this,ka);x(this,Vl,[]);x(this,Ip);x(this,_i);x(this,jl);x(this,Hg,t=>{if(c(this,$e)===void 0||c(this,en)===void 0||!c(this,Vt).isOpen())return;let n=t.target;n instanceof Node&&(c(this,en).contains(n)||c(this,Vt).contains(n)||c(this,Vt).close())});x(this,Fg,t=>{if(t.key!=="Escape"||c(this,$e)===void 0||t.defaultPrevented||gh(document))return;let n=t.target;if(!(n instanceof HTMLElement&&(n.tagName==="INPUT"||n.tagName==="TEXTAREA"||n.isContentEditable===!0))){if(this.isChatOpen()){Hl(!1),this.closeChat();return}if(c(this,Vt).isOpen()){c(this,Vt).close();return}this.isCollapsed()||(Hl(!1),this.collapse())}});g(this,Yr,t),g(this,bt,new yg(()=>{c(this,bt).closePage(),this.closeChat(),c(this,Lo).open()},n=>{if(n==="activity"){c(this,bt).open(n),this.showChat();return}this.isCollapsed()&&this.expand(),this.closeChat(),c(this,Vt).close(),c(this,Lo).close()},{run:n=>{var r;return(r=t.onHarnessRun)==null?void 0:r.call(t,n)},stop:()=>{var n;return(n=t.onHarnessStop)==null?void 0:n.call(t)},setHarness:n=>{var r;return(r=t.onHarness)==null?void 0:r.call(t,n)},link:()=>{var n;return(n=t.onHarnessLink)==null?void 0:n.call(t)}})),g(this,Vt,new up({...t.settings,onBeforeOpen:()=>{var n,r;this.closeChat(),c(this,bt).closePage(),c(this,Lo).close(),(r=(n=t.settings)==null?void 0:n.onBeforeOpen)==null||r.call(n)}}))}setProjectId(t){c(this,bt).setProjectId(t)}paintHarnessDrive(t,n){c(this,bt).paintDrive(t,n)}paintAgent(t){c(this,bt).paintAgent(t)}paintHarness(t){g(this,Ip,t),c(this,Vt).paintHarness(t),c(this,bt).paintHarness(t),T(this,Cn,Hx).call(this)}paintImpact(t){c(this,bt).paintImpact(t)}paintAnnotations(t){c(this,bt).paintAnnotations(t)}openView(t){t==="activity"?this.showChat():(this.isCollapsed()&&this.expand(),this.closeChat(),c(this,Vt).close(),c(this,Lo).close()),c(this,bt).open(t)}paintAccount(t,n,r={}){g(this,ka,{account:t,dashboardUrl:n,details:r}),c(this,$e)!==void 0&&(nP(c(this,$e),t,n,r),WT(c(this,$e),t,n,r),RM(c(this,$e),t),c(this,bt).paintAccount(t),T(this,Cn,Hx).call(this))}paintNotices(t=[]){g(this,Vl,t),g(this,_i,T(this,Cn,Ug).call(this)),c(this,$e)!==void 0&&Ux(c(this,$e),t,c(this,_i))}static dockHtml(t,n,r,o,i){let s=Om(se.GEAR,Ae.TOOLBAR),a=Ie(se.REMOVE,Ae.TOOLBAR);return`<div ${F} role="complementary" aria-label="Reticle">
1680
+ </div>`}function gs(e,t,n){let r=n===void 0?"":`<span class="reticle-report-basis" title="${n}">${ee.ESTIMATE_TAG}</span>`;return`<div class="reticle-report-card"><span class="reticle-report-value">${e}</span><span class="reticle-report-label">${t}${r}</span></div>`}function jW(e){let t=e.days.slice(-30);if(t.length===0)return"";let n=Math.max(1,...t.map(o=>o.counts.verdicts)),r=t.map(o=>{let i=Math.max(4,Math.round(o.counts.verdicts/n*100)),s=`${o.date}: ${String(o.counts.verdicts)} verdicts, ${String(o.counts.failed)} defects`,a=o.counts.failed>0?' data-hot="1"':"";return`<span class="reticle-report-bar" style="height:${String(i)}%" title="${s}"${a}></span>`}).join("");return`<div class="reticle-report-chart-wrap"><span class="reticle-report-section">${ee.CHART}</span><div class="reticle-report-chart">${r}</div></div>`}function KW(e,t){var u;let n=((u=e.defects)!=null?u:[]).slice(0,M0);if(n.length===0)return"";let r=t!==void 0&&_r(t),o=r?`<a class="reticle-report-defect-link" data-reticle-link="defect" href="${pe(t)}" target="_blank" rel="noreferrer noopener" title="${ee.DEFECT_LINK_TITLE}" aria-label="${ee.DEFECT_LINK_TITLE}">${Ce(se.VIEW,ye.SEND)}</a>`:"",i=n.map(d=>{let f=d.detail===void 0?"":`<span class="reticle-report-defect-detail">${pe(d.detail)}</span>`,m=d.source===void 0?"":`<span class="reticle-report-defect-source">${pe(d.source)}</span>`;return`<li class="reticle-report-defect"><span class="reticle-report-defect-title">${pe(d.title)}</span>${f}${m}${o}</li>`}).join(""),s=e.counts.failed>n.length,a=r?`<a class="reticle-report-defects-more" data-reticle-link="dashboard" href="${pe(t)}" target="_blank" rel="noreferrer noopener">${ee.DEFECTS_MORE}${s?` (${String(e.counts.failed)})`:""}</a>`:s?`<button type="button" data-reticle-defects-all ${qt} class="reticle-report-defects-all" title="${ee.DEFECTS_SEE_ALL_TITLE}">${ee.DEFECTS_SEE_ALL} (${String(e.counts.failed)}) \u2192</button>`:"",l=YT(t);return`<div class="reticle-report-defects-wrap"><div class="reticle-report-defects-head"><span class="reticle-report-section">${ee.DEFECTS}</span>${l}</div><ul class="reticle-report-defects">${i}</ul>${a}</div>`}function ZW(e){if(e===void 0)return"";let t=l=>typeof e[l]=="number"?e[l]:0,n=e.status,r=typeof e.keyRefused=="string"?e.keyRefused:void 0,o=r!==void 0?ee.KEY_REFUSED:n==="refused"?`${String(t("refused"))} refused`:n==="pending"?`${String(t("pending"))} waiting`:n==="on-platform"?`Synced \xB7 ${String(t("onPlatform"))}`:n==="local-only"?`${String(t("pending"))} ${ee.NOT_SENT}`:void 0;if(o===void 0)return"";let i=r!==void 0?r:n==="local-only"?ee.NOT_SENT_HELP:typeof e.said=="string"?e.said:"",s=e.runUrl,a=typeof s=="string"&&_r(s)?` <a class="reticle-sync-run" data-reticle-link="run" href="${pe(s)}" target="_blank" rel="noreferrer noopener">${ee.SEE_RUN}</a>`:"";return`<span class="reticle-sync-status" data-reticle-sync-status="${pe(String(n))}" title="${pe(i)}">${o}</span>${a}`}function WW(e){var i,s;if(e===void 0)return"";let t=HP.filter(a=>typeof e[a.key]=="number");if(t.length===0)return"";let n=a=>{var l;return`${String(Math.round((l=e[a])!=null?l:0))}%`},r=typeof e.proved=="number"?n("proved"):n((s=(i=t[0])==null?void 0:i.key)!=null?s:""),o=t.map(a=>`<span class="reticle-report-coverage-level">${n(a.key)} ${a.label}</span>`).join("");return`<div class="reticle-report-coverage" title="${ee.COVERAGE_HELP}"><span class="reticle-report-section">${ee.COVERAGE}</span><span class="reticle-report-coverage-value">${r}</span><div class="reticle-report-coverage-levels">${o}</div></div>`}function YW(e,t,n,r,o,i){let s=e.counts;if(s.calls===0)return`<p class="reticle-report-empty">${ee.EMPTY}</p>`;let a=e.records.streakDays>0?`<span class="reticle-report-streak" title="Consecutive days with at least one verdict">\u{1F525} ${String(e.records.streakDays)} <span class="reticle-report-streak-label">${ee.STREAK}</span></span>`:"",l=`<div class="reticle-report-hero"><span class="reticle-report-hero-value">${vo(s.failed)}</span><span class="reticle-report-hero-label">${ee.heroDefects(s.failed)}</span></div>`,u=`<div class="reticle-report-verdicts" title="${ee.UNKNOWN_HELP}">
1681
+ <span class="reticle-report-verdict" data-kind="pass">${vo(s.passed)} ${ee.PASSED}</span>
1682
+ <span class="reticle-report-verdict" data-kind="fail">${vo(s.failed)} ${ee.FAILED}</span>
1683
+ <span class="reticle-report-verdict" data-kind="unknown">${vo(s.unknown)} ${ee.UNKNOWN}</span>
1684
+ </div>`,d=[gs(vo(s.verdicts),ee.VERDICTS),gs(vo(s.calls),ee.CALLS),gs(Sp(s.drivingMs),ee.DRIVING),gs(vo(s.sessions),ee.SESSIONS),gs(Sp(e.records.longestRunMs),ee.LONGEST),gs(vo(s.tokensReturned),ee.TOKENS),gs(vo(e.savings.tokens.value),ee.SAVED_TOKENS,e.savings.tokens.basis),gs(Sp(e.savings.minutes.value*6e4),ee.SAVED_MINUTES,e.savings.minutes.basis)].join(""),f=`<div class="reticle-report-identity">${El(n,{dashboardUrl:t,projectName:r,verdicts:s.verdicts,defects:s.failed})}${YT(t)}${ZW(i)}</div>`;return`<div class="reticle-report-top">${a}${f}</div>${l}${u}${WW(o)}<div class="reticle-report-grid">${d}</div>${KW(e,t)}${jW(e)}${XW(e,t,n)}`}function XW(e,t,n){if(t!==void 0||e.counts.verdicts<=0||n===void 0)return"";let[r,o,i]=n.signedIn?[ee.UNLINKED,ee.UNLINKED_ACTION,ee.UNLINKED_TAIL]:[ee.LOCAL_ONLY,ee.LOCAL_ONLY_ACTION,ee.LOCAL_ONLY_TAIL];return`<p class="reticle-report-local-only">${r} <code>${o}</code> ${i}</p>`}var Fg,jx,XM,qM,JM,QM,VW,qW,YM,Oa,Fl,Es,wr,bs,Bl,Qt,t2,Hg,Kx,Cp,Bg,n2=y(()=>{"use strict";M();Gr();Zr();ma();yo();Lt();Ag();Fg="data-reticle-report-scope",jx={PROJECT:"project",MACHINE:"machine"},XM="data-reticle-share-x",qM="data-reticle-share-in",JM="data-reticle-share-copy",QM="data-reticle-refer",VW=1600;qW=1200,YM="data-syncing",Bg=class{constructor(t={}){x(this,Qt);x(this,Oa);x(this,Fl);x(this,Es);x(this,wr);x(this,bs,!1);x(this,Bl);g(this,Bl,t)}mount(t){var r,o,i,s,a,l,u;g(this,Es,t),g(this,Oa,(r=t.querySelector(`[${B}]`))!=null?r:void 0),g(this,Fl,(o=t.querySelector("[data-reticle-report-body]"))!=null?o:void 0),(i=t.querySelector(`[${zT}]`))==null||i.addEventListener("click",d=>{d.stopPropagation(),this.close()});let n=t.querySelectorAll(`[${Fg}]`);for(let d of n)d.addEventListener("click",f=>{f.stopPropagation(),g(this,bs,jx.MACHINE===d.getAttribute(Fg));for(let m of n)m.setAttribute("aria-pressed",m===d?"true":"false");T(this,Qt,Hg).call(this)});(s=t.querySelector(`[${XM}]`))==null||s.addEventListener("click",d=>{d.stopPropagation(),T(this,Qt,Kx).call(this,PP(this.shareText()))}),(a=t.querySelector(`[${qM}]`))==null||a.addEventListener("click",d=>{d.stopPropagation(),T(this,Qt,Cp).call(this,this.shareText()),T(this,Qt,Kx).call(this,MP())}),(l=t.querySelector(`[${JM}]`))==null||l.addEventListener("click",d=>{d.stopPropagation(),T(this,Qt,Cp).call(this,this.shareText(),d.currentTarget)}),(u=t.querySelector(`[${QM}]`))==null||u.addEventListener("click",d=>{d.stopPropagation(),T(this,Qt,Cp).call(this,vx(),d.currentTarget)}),t.addEventListener("click",d=>{var E,S;let f=d.target;if(!(f instanceof Element))return;let m=f.closest(`[${qt}]`);if(m!==null){d.stopPropagation(),T(this,Qt,Cp).call(this,he.SIGNIN_COMMAND,m);return}let h=f.closest(`[${WT}]`);h!==null&&(d.stopPropagation(),(S=(E=c(this,Bl)).onSyncNow)==null||S.call(E),h.setAttribute(YM,"1"),setTimeout(()=>h.removeAttribute(YM),qW))})}setSnapshot(t){g(this,wr,t),this.isOpen()&&T(this,Qt,Hg).call(this)}snapshot(){return c(this,wr)}isOpen(){var t;return((t=c(this,Es))==null?void 0:t.getAttribute(In))==="1"}open(){var t,n,r;c(this,Es)!==void 0&&((n=(t=c(this,Bl)).onBeforeOpen)==null||n.call(t),T(this,Qt,Hg).call(this),c(this,Es).setAttribute(In,"1"),(r=c(this,Oa))==null||r.setAttribute("aria-hidden","false"))}close(){var t,n;(t=c(this,Es))==null||t.setAttribute(In,"0"),(n=c(this,Oa))==null||n.setAttribute("aria-hidden","true")}toggle(){this.isOpen()?this.close():this.open()}contains(t){var n;return((n=c(this,Oa))==null?void 0:n.contains(t))===!0}shareText(){let t=c(this,wr);return t===void 0?vx():c(this,bs)?wx(t.global):wx(t.project,t.projectName)}};Oa=new WeakMap,Fl=new WeakMap,Es=new WeakMap,wr=new WeakMap,bs=new WeakMap,Bl=new WeakMap,Qt=new WeakSet,t2=function(){let t=c(this,wr);if(t!==void 0)return c(this,bs)?t.global:t.project},Hg=function(){var n,r,o,i,s;let t=T(this,Qt,t2).call(this);c(this,Fl)!==void 0&&(c(this,Fl).innerHTML=t===void 0?`<p class="reticle-report-empty">${ee.EMPTY}</p>`:YW(t,(n=c(this,wr))==null?void 0:n.dashboardUrl,(r=c(this,wr))==null?void 0:r.account,(o=c(this,wr))==null?void 0:o.projectName,c(this,bs)||(i=c(this,wr))==null?void 0:i.coverage,c(this,bs)||(s=c(this,wr))==null?void 0:s.sync))},Kx=function(t){window.open(t,"_blank","noopener,noreferrer")},Cp=async function(t,n){var r,o;try{await((r=navigator.clipboard)==null?void 0:r.writeText(t))}catch{}if(n instanceof HTMLElement){let i=(o=n.textContent)!=null?o:"";n.textContent=ee.COPIED,window.setTimeout(()=>{n.textContent=i},VW)}}});function nY(e){let t=e.kicker===void 0?"":`<span class="reticle-promo-kicker">${pe(e.kicker)}</span>`,n=e.detail===void 0?"":`<span class="reticle-promo-detail" title="${pe(e.detail)}">${pe(e.detail)}</span>`,r=e.cta===void 0?"":`<a data-reticle-promo-link class="reticle-promo-link" href="${pe(e.cta.url)}" target="_blank" rel="noopener noreferrer">${pe(e.cta.label)} \u2192</a>`;return{id:`${tY}${e.id}`,html:`<div class="reticle-promo-copy">${t}<strong class="reticle-promo-title">${pe(e.title)}</strong>${n}${r}</div>`}}function o2(e=[],t=Gf){let n=e.flatMap(r=>{let o=GT.safeParse(r);return o.success&&!o.data.id.startsWith(eY)?[o.data]:[]});return 0<n.length?n.map(nY):[...QW(t)]}var JW,r2,Lp,QW,eY,tY,i2=y(()=>{"use strict";ml();ma();M();JW="/settings?group=billing",r2={REPLAY:"replay-confidence",NOTES:"notes-for-agent"},Lp={REPLAY_TITLE:"Replay what your agent verified",REPLAY_DETAIL:"Saved flows re-run after each edit.",REPLAY_LINK:"See how \u2192",NOTES_TITLE:"Point your agent at anything",NOTES_DETAIL:"Open Notes, then click an element."},QW=e=>[{id:r2.REPLAY,html:`<div class="reticle-promo-copy"><strong class="reticle-promo-title">${Lp.REPLAY_TITLE}</strong><span class="reticle-promo-detail">${Lp.REPLAY_DETAIL}</span><a data-reticle-promo-link class="reticle-promo-link" href="${e}${JW}" target="_blank" rel="noopener noreferrer">${Lp.REPLAY_LINK}</a></div>`},{id:r2.NOTES,html:`<div class="reticle-promo-copy"><strong class="reticle-promo-title">${Lp.NOTES_TITLE}</strong><span class="reticle-promo-detail">${Lp.NOTES_DETAIL}</span></div>`}],eY="harness",tY="notice-"});var rY,s2,Zx,oY,a2,c2=y(()=>{"use strict";rY="Reticle",s2='<path d="M92.82 92.16C93.07 93.4 91.77 94.4 90.63 93.83C89.62 93.33 88.62 92.82 87.63 92.3C71.14 83.78 54.79 72.27 39.61 57.96C39.09 57.49 38.57 56.98 38.06 56.49C22.45 41.52 9.78 25.14 .33 8.52C0.29 8.45 .25 8.38 .2 8.31C-0.44 7.2 .51 5.84 1.79 6.05L24.07 9.71C43.06 12.83 60.63 11.75 75.55 6.53L93.95 .09C95.15-0.33 96.31 .78 95.93 1.98L90.1 20.49C85.37 35.48 84.9 52.97 88.69 71.73L92.83 92.16H92.82Z"/><path d="M58.72 89.23L6.15 92.8C5.24 92.86 4.48 92.13 4.51 91.22L6.56 30.39C6.61 28.91 8.51 28.36 9.35 29.57C16.23 39.43 24.98 52.35 33.01 61.26C41.05 70.17 50.6 78.72 59.62 86.56C60.65 87.45 60.08 89.13 58.72 89.23Z"/>',Zx=`<svg class="reticle-mark" viewBox="0 0 96 94" fill="currentColor" aria-hidden="true">${s2}</svg>`,oY=`<svg class="reticle-fab-mark" viewBox="0 0 96 94" fill="currentColor" aria-hidden="true">${s2}</svg>`,a2=`<button type="button" class="reticle-fab" data-reticle-fab aria-label="Start ${rY}" aria-expanded="false">${oY}<span class="reticle-fab-pulse" aria-hidden="true"></span><span data-reticle-mark-count class="reticle-fab-badge" hidden>0</span></button>`});function Xx(e,t=[],n){let r=e.querySelector(`[${Vx}]`);if(r===null)return;let o;try{o=window.sessionStorage}catch{o=void 0}MM(r,o2(t,n),o)}function h2(){try{return globalThis.sessionStorage.getItem(Xm)==="1"}catch{return!1}}function p2(e){try{e?globalThis.sessionStorage.setItem(Xm,"1"):globalThis.sessionStorage.removeItem(Xm)}catch{}}function aY(){try{return globalThis.localStorage.getItem(qm)==="1"}catch{return!1}}function Gl(e){try{e?globalThis.localStorage.setItem(qm,"1"):globalThis.localStorage.removeItem(qm)}catch{}}function Qx(){return aY()&&!h2()}function m2(e){return e&&!h2()}var l2,iY,u2,d2,Wx,sY,Yx,$e,en,vr,Ia,Vl,jt,bt,jl,Kl,Ca,La,$o,_s,$a,ka,ko,Jr,za,Zl,kp,xi,Wl,Ln,Gg,qx,Jx,f2,Vg,jg,$p,eA=y(()=>{"use strict";ot();n2();fx();yo();_l();Lt();Pg();i2();Ug();c2();hi();FT();cp();Gr();Zr();Og();_l();l2="reticle-toolbar-drag",iY=120,u2="Minimise chat",d2="Open agent chat",Wx="Settings",sY="Reticle",Yx="Exit";$p=class{constructor(t={}){x(this,Ln);x(this,$e);x(this,en);x(this,vr);x(this,Ia);x(this,Vl);x(this,jt);x(this,bt);x(this,jl);x(this,Kl);x(this,Ca,!1);x(this,La,!1);x(this,$o);x(this,_s,!1);x(this,$a);x(this,ka);x(this,ko,new Bg({onBeforeOpen:()=>{c(this,jt).close(),this.closeChat()},onSyncNow:()=>{var t,n;return(n=(t=c(this,Jr)).onSyncNow)==null?void 0:n.call(t)}}));x(this,Jr);x(this,za);x(this,Zl,[]);x(this,kp);x(this,xi);x(this,Wl);x(this,Vg,t=>{if(c(this,$e)===void 0||c(this,en)===void 0||!c(this,jt).isOpen())return;let n=t.target;n instanceof Node&&(c(this,en).contains(n)||c(this,jt).contains(n)||c(this,jt).close())});x(this,jg,t=>{if(t.key!=="Escape"||c(this,$e)===void 0||t.defaultPrevented||xh(document))return;let n=t.target;if(!(n instanceof HTMLElement&&(n.tagName==="INPUT"||n.tagName==="TEXTAREA"||n.isContentEditable===!0))){if(this.isChatOpen()){Gl(!1),this.closeChat();return}if(c(this,jt).isOpen()){c(this,jt).close();return}this.isCollapsed()||(Gl(!1),this.collapse())}});g(this,Jr,t),g(this,bt,new Rg(()=>{c(this,bt).closePage(),this.closeChat(),c(this,ko).open()},n=>{if(n==="activity"){c(this,bt).open(n),this.showChat();return}this.isCollapsed()&&this.expand(),this.closeChat(),c(this,jt).close(),c(this,ko).close()},{run:n=>{var r;return(r=t.onHarnessRun)==null?void 0:r.call(t,n)},stop:()=>{var n;return(n=t.onHarnessStop)==null?void 0:n.call(t)},setHarness:n=>{var r;return(r=t.onHarness)==null?void 0:r.call(t,n)},link:()=>{var n;return(n=t.onHarnessLink)==null?void 0:n.call(t)}})),g(this,jt,new hp({...t.settings,onBeforeOpen:()=>{var n,r;this.closeChat(),c(this,bt).closePage(),c(this,ko).close(),(r=(n=t.settings)==null?void 0:n.onBeforeOpen)==null||r.call(n)}}))}setProjectId(t){c(this,bt).setProjectId(t)}paintHarnessDrive(t,n){c(this,bt).paintDrive(t,n)}paintAgent(t){c(this,bt).paintAgent(t)}paintHarness(t){g(this,kp,t),c(this,jt).paintHarness(t),c(this,bt).paintHarness(t),T(this,Ln,qx).call(this)}paintImpact(t){c(this,bt).paintImpact(t)}paintAnnotations(t){c(this,bt).paintAnnotations(t)}openView(t){t==="activity"?this.showChat():(this.isCollapsed()&&this.expand(),this.closeChat(),c(this,jt).close(),c(this,ko).close()),c(this,bt).open(t)}paintAccount(t,n,r={}){g(this,za,{account:t,dashboardUrl:n,details:r}),c(this,$e)!==void 0&&(EP(c(this,$e),t,n,r),ix(c(this,$e),t,n,r),GM(c(this,$e),t),c(this,bt).paintAccount(t),T(this,Ln,qx).call(this))}paintNotices(t=[]){g(this,Zl,t),g(this,xi,T(this,Ln,Gg).call(this)),c(this,$e)!==void 0&&Xx(c(this,$e),t,c(this,xi))}static dockHtml(t,n,r,o,i){let s=$m(se.GEAR,ye.TOOLBAR),a=Ce(se.REMOVE,ye.TOOLBAR);return`<div ${F} role="complementary" aria-label="Reticle">
1685
1685
  <div ${En} class="reticle-chat-panel ${Xn}" role="region" aria-label="Agent Log" aria-hidden="true">
1686
1686
  <div class="reticle-chat-head">
1687
- <span class="reticle-chat-brand">${Dx}<span class="reticle-chat-brandname">${AW}</span></span>
1688
- <span ${fl} class="reticle-head-team"></span>
1689
- <span ${ex} class="reticle-head-account"></span>
1687
+ <span class="reticle-chat-brand">${Zx}<span class="reticle-chat-brandname">${sY}</span></span>
1688
+ <span ${gl} class="reticle-head-team"></span>
1689
+ <span ${dx} class="reticle-head-account"></span>
1690
1690
  </div>
1691
- <button type="button" ${AT} class="reticle-chat-min" title="${YM}" aria-label="${YM}">${Ie(se.CARET_DOWN,Ae.TOOLBAR)}</button>
1691
+ <button type="button" ${kT} class="reticle-chat-min" title="${u2}" aria-label="${u2}">${Ce(se.CARET_DOWN,ye.TOOLBAR)}</button>
1692
1692
  ${t}
1693
1693
  <span class="reticle-tally" data-reticle-tally hidden></span>
1694
1694
  <section class="reticle-chat-view" role="region" aria-label="Agent Log">
1695
1695
  ${n}
1696
- <div class="${Qm}"><div ${r}></div></div>
1696
+ <div class="${rg}"><div ${r}></div></div>
1697
1697
  ${o}
1698
1698
  </section>
1699
- ${vM}
1699
+ ${FM}
1700
1700
  ${i}
1701
1701
  </div>
1702
- ${MP}
1703
- ${HP}
1704
- ${FP}
1705
- <button type="button" ${Ht} class="reticle-chat-pill" title="${XM}" aria-label="${XM}">
1706
- ${Dx}
1702
+ ${QP}
1703
+ ${tM}
1704
+ ${nM}
1705
+ <button type="button" ${Ft} class="reticle-chat-pill" title="${d2}" aria-label="${d2}">
1706
+ ${Zx}
1707
1707
  <span class="reticle-chat-pill-text" data-reticle-chat-pill-text></span>
1708
1708
  <span class="reticle-chat-pill-time" data-reticle-chat-pill-time></span>
1709
- <span class="reticle-chat-pill-caret" aria-hidden="true">${Ie(se.CARET_DOWN,Ae.TOOLBAR)}</span>
1709
+ <span class="reticle-chat-pill-caret" aria-hidden="true">${Ce(se.CARET_DOWN,ye.TOOLBAR)}</span>
1710
1710
  </button>
1711
- ${XT()}
1712
- ${UM()}
1713
- ${NM}
1711
+ ${ax()}
1712
+ ${e2()}
1713
+ ${BM}
1714
1714
  <div data-reticle-hud>
1715
1715
  <div class="reticle-hud-deco" aria-hidden="true"></div>
1716
- ${KM}
1717
- <div class="reticle-toolbar ${WM}" role="toolbar" aria-label="Reticle controls">
1716
+ ${a2}
1717
+ <div class="reticle-toolbar ${l2}" role="toolbar" aria-label="Reticle controls">
1718
1718
  <div class="reticle-toolbar-chrome">
1719
- ${UP}
1719
+ ${eM}
1720
1720
  <div class="reticle-tb-wrap">
1721
- <button type="button" ${Jd} class="reticle-tb-btn reticle-tb-btn--toggle" title="${Px}" aria-label="${Px}" aria-pressed="false" data-active="0">${s}${_a(ps.SETTINGS)}</button>
1722
- <span class="reticle-tb-tip">${Px}</span>
1721
+ <button type="button" ${np} class="reticle-tb-btn reticle-tb-btn--toggle" title="${Wx}" aria-label="${Wx}" aria-pressed="false" data-active="0">${s}${Sa(fs.SETTINGS)}</button>
1722
+ <span class="reticle-tb-tip">${Wx}</span>
1723
1723
  </div>
1724
1724
  <div class="reticle-tb-wrap">
1725
- <button type="button" data-reticle-min-btn class="reticle-tb-btn" title="${Mx}" aria-label="${Mx}">${a}${_a(ps.HIDE)}</button>
1726
- <span class="reticle-tb-tip">${Mx}<span class="reticle-tb-kbd">Esc</span></span>
1725
+ <button type="button" data-reticle-min-btn class="reticle-tb-btn" title="${Yx}" aria-label="${Yx}">${a}${Sa(fs.HIDE)}</button>
1726
+ <span class="reticle-tb-tip">${Yx}<span class="reticle-tb-kbd">Esc</span></span>
1727
1727
  </div>
1728
1728
  </div>
1729
1729
  </div>
1730
1730
  </div>
1731
- </div>`}get report(){return c(this,Lo)}isAnnotateOn(){return c(this,bs)}setAnnotateOn(t){var r,o,i,s,a,l,u;g(this,bs,t),(r=c(this,Co))==null||r.setAttribute("aria-pressed",t?"true":"false"),(o=c(this,Co))==null||o.setAttribute("data-active",t?"1":"0"),(i=c(this,Co))==null||i.setAttribute("aria-label",t?"Stop adding notes":"Add notes"),(s=c(this,Co))==null||s.setAttribute("title",t?"Stop adding notes":"Add notes");let n=(a=c(this,Co))==null?void 0:a.querySelector("[data-reticle-notes-toggle-label]");n!=null&&(n.textContent=t?"Stop adding notes":"Add notes"),(u=(l=c(this,$e))==null?void 0:l.querySelector('[data-reticle-chat-view-btn="annotations"]'))==null||u.setAttribute("data-capture",t?"1":"0")}mount(t){var f,m,h,E;g(this,$a,new AbortController);let{signal:n}=c(this,$a);g(this,$e,t),g(this,en,(f=t.querySelector(`[${F}]`))!=null?f:void 0);let r=t.querySelector(`[${qD}]`);g(this,yr,r instanceof HTMLButtonElement?r:void 0);let o=t.querySelector(`[${En}]`);g(this,Oa,o instanceof HTMLElement?o:void 0);let i=t.querySelector(`[${jm}]`);g(this,Co,i instanceof HTMLButtonElement?i:void 0),this.setAnnotateOn(c(this,bs)),(m=c(this,Co))==null||m.addEventListener("click",_=>{var A,v;_.preventDefault(),_.stopPropagation(),this.setAnnotateOn(!c(this,bs)),(v=(A=c(this,Yr)).onAnnotateToggle)==null||v.call(A,c(this,bs))},{signal:n});let s=t.querySelector(`[${Ht}]`);s==null||s.addEventListener("click",_=>{_.preventDefault(),_.stopPropagation(),Hl(!0),this.showChat()},{signal:n});let a=t.querySelector(`[${AT}]`);a==null||a.addEventListener("click",_=>{_.preventDefault(),_.stopPropagation(),Hl(!1),this.closeChat()},{signal:n});let l=t.querySelector("[data-reticle-min-btn]");g(this,Fl,l instanceof HTMLButtonElement?l:void 0),t.setAttribute(Ze,"1"),t.setAttribute(ft,"0"),t.removeAttribute(yt),c(this,Vt).mount(t),c(this,Lo).mount(t),c(this,bt).mount(t),g(this,_i,T(this,Cn,Ug).call(this)),Ux(t,c(this,Vl),c(this,_i)),g(this,La,new MutationObserver(()=>T(this,Cn,Fx).call(this))),c(this,La).observe(t,{attributes:!0,attributeFilter:[yt,ft,On]}),T(this,Cn,Fx).call(this),(h=c(this,yr))==null||h.addEventListener("click",_=>{if(_.stopPropagation(),c(this,Ca)){g(this,Ca,!1);return}Hl(!0),this.expand()},{signal:n}),(E=c(this,Fl))==null||E.addEventListener("click",_=>{_.stopPropagation(),Hl(!1),this.collapse()},{signal:n});let u=t.querySelector(`.${WM}`),d=[c(this,yr),u].filter(_=>_ instanceof HTMLElement);if(c(this,en)!==void 0&&d.length>0&&(g(this,Bl,_1(c(this,en),d,{onDragMove:()=>{g(this,Ca,!0)},onDragEnd:_=>{g(this,Ca,_&&this.isCollapsed())}})),g(this,Gl,b1(c(this,en),t))),document.addEventListener("pointerdown",c(this,Hg),{signal:n}),document.addEventListener("keydown",c(this,Fg),{signal:n}),g(this,jl,k1(t,()=>{var _,A;return(A=(_=c(this,Yr)).onSignIn)==null?void 0:A.call(_)})),c(this,ka)!==void 0){let _=c(this,ka);this.paintAccount(_.account,_.dashboardUrl,_.details)}}teardown(){var t,n,r,o,i;(t=c(this,jl))==null||t.call(this),g(this,jl,void 0),(n=c(this,$a))==null||n.abort(),g(this,$a,void 0),(r=c(this,La))==null||r.disconnect(),g(this,La,void 0),(o=c(this,Bl))==null||o.call(this),g(this,Bl,void 0),(i=c(this,Gl))==null||i.call(this),g(this,Gl,void 0),c(this,Vt).teardown(),c(this,bt).teardown(),g(this,$e,void 0),g(this,en,void 0),g(this,yr,void 0),g(this,Oa,void 0),g(this,Fl,void 0)}isCollapsed(){var t;return((t=c(this,$e))==null?void 0:t.getAttribute(Ze))==="1"}isChatOpen(){var t;return((t=c(this,$e))==null?void 0:t.getAttribute(yt))==="1"}expand(){var t,n;c(this,$e)===void 0||!this.isCollapsed()||c(this,Ia)||(T(this,Cn,JM).call(this),c(this,$e).setAttribute(Ze,"0"),qM(!1),c(this,yr)!==void 0&&c(this,yr).setAttribute("aria-expanded","true"),(n=(t=c(this,Yr)).onExpand)==null||n.call(t),this.openChat(),c(this,en)!==void 0&&jr(c(this,en),c(this,$e)))}collapse(){var t,n;c(this,$e)!==void 0&&(g(this,Ia,!1),this.closeChat(),c(this,Vt).close(),c(this,$e).setAttribute(Ze,"1"),qM(!0),c(this,yr)!==void 0&&c(this,yr).setAttribute("aria-expanded","false"),(n=(t=c(this,Yr)).onCollapse)==null||n.call(t))}openChat(){var n,r,o;if(c(this,$e)===void 0||(this.isCollapsed()&&this.expand(),c(this,Vt).close(),c(this,bt).closePage(),c(this,bt).open("activity"),this.isChatOpen()))return;c(this,$e).setAttribute(yt,"1");let t=c(this,$e).querySelector("[data-reticle-log]");t!==null&&UD(t),(n=c(this,Oa))==null||n.setAttribute("aria-hidden","false"),(o=(r=c(this,Yr)).onChatOpen)==null||o.call(r),c(this,en)!==void 0&&jr(c(this,en),c(this,$e))}closeChat(){var t,n,r;c(this,$e)===void 0||!this.isChatOpen()||(c(this,$e).removeAttribute(yt),(t=c(this,Oa))==null||t.setAttribute("aria-hidden","true"),(r=(n=c(this,Yr)).onChatClose)==null||r.call(n),c(this,en)!==void 0&&jr(c(this,en),c(this,$e)))}toggleChat(){this.isChatOpen()?this.closeChat():this.showChat()}showChat(){c(this,Lo).close(),this.openChat()}pulseFab(t){var n;(n=c(this,yr))==null||n.setAttribute("data-pulse",t?"1":"0")}};$e=new WeakMap,en=new WeakMap,yr=new WeakMap,Oa=new WeakMap,Fl=new WeakMap,Vt=new WeakMap,bt=new WeakMap,Bl=new WeakMap,Gl=new WeakMap,Ia=new WeakMap,Ca=new WeakMap,Co=new WeakMap,bs=new WeakMap,La=new WeakMap,$a=new WeakMap,Lo=new WeakMap,Yr=new WeakMap,ka=new WeakMap,Vl=new WeakMap,Ip=new WeakMap,_i=new WeakMap,jl=new WeakMap,Cn=new WeakSet,Ug=function(){var t,n;return yx(c(this,Ip),(n=(t=c(this,ka))==null?void 0:t.account)!=null?n:{signedIn:!1})},Hx=function(){let t=T(this,Cn,Ug).call(this);c(this,$e)===void 0||t===c(this,_i)||(g(this,_i,t),Ux(c(this,$e),c(this,Vl),t))},Fx=function(){let t=c(this,$e);if(t===void 0)return;let n=(o,i)=>{let s=t.querySelector(`[${o}]`);s==null||s.setAttribute("data-active",i?"1":"0"),s==null||s.setAttribute("aria-pressed",i?"true":"false")};n(Hm,t.getAttribute(yt)==="1"),n(Jd,t.getAttribute(ft)==="1");let r=t.querySelector("[data-reticle-chat-impact]");if(r!==null){let o=t.getAttribute(On)==="1";r.setAttribute("data-active",o?"1":"0"),c(this,bt).setImpactOpen(o),o?r.setAttribute("aria-current","page"):r.removeAttribute("aria-current")}},JM=function(){g(this,Ia,!0),window.setTimeout(()=>{g(this,Ia,!1)},xW)},Hg=new WeakMap,Fg=new WeakMap});function t2(e){var r,o;let t=(r=e.startMs)!=null?r:e.now,n={reads:0,acts:0,narrations:0,human:0,passes:0,fails:0};for(let i of e.runLog)i.kind===Ge.READ?n.reads+=1:i.kind===Ge.ACT?n.acts+=1:i.kind===Ge.NARRATION?n.narrations+=1:i.kind===Ge.HUMAN&&(n.human+=1),i.result===Kn.PASS?n.passes+=1:i.result===Kn.FAIL&&(n.fails+=1);return{session:e.sessionId,url:typeof location=="undefined"?"":Oh(),state:e.state,startedMs:t,durationMs:Math.max(0,((o=e.endMs)!=null?o:e.now)-t),counts:n,capabilities:ji(),log:e.runLog.map(i=>({...i}))}}var n2=y(()=>{"use strict";md();di();Ki()});function r2(e,t,n){e!==void 0&&(e.setAttribute("data-on","1"),e.style.transform=`translate(${String(t)}px, ${String(n)}px)`)}function o2(e,t){e!==void 0&&(e.style.left=`${String(t.left-4)}px`,e.style.top=`${String(t.top-4)}px`,e.style.width=`${String(t.width+8)}px`,e.style.height=`${String(t.height+8)}px`,e.setAttribute("data-on","1"),ue(()=>e.setAttribute("data-on","0"),700))}function i2(e,t,n){if(e===void 0)return;let r=document.createElement("div");r.setAttribute("data-reticle-ripple",""),r.style.left=`${String(t)}px`,r.style.top=`${String(n)}px`,e.appendChild(r),ue(()=>r.remove(),520)}function Vx(e){return new Promise(t=>ue(t,e))}var s2=y(()=>{"use strict";dt()});var Xr,za,qr,Jr,_s,Kl,Zl,Da,Cp,Wl,Lp,wr,a2,jx,Kx,c2,Bg,l2=y(()=>{"use strict";M();dt();Ct();Bg=class{constructor(t){x(this,wr);x(this,Xr,Fr.IDLE);x(this,za,0);x(this,qr);x(this,Jr);x(this,_s);x(this,Kl);x(this,Zl);x(this,Da);x(this,Cp);x(this,Wl);x(this,Lp);g(this,Zl,t.now),g(this,Da,t.idleAfterMs),g(this,Cp,t.glowFadeMs),g(this,Wl,t.borderMode),g(this,Lp,t.setMode)}setElements(t,n){g(this,_s,t),g(this,Kl,n)}phase(){return c(this,Xr)}lastActivityMs(){return c(this,za)}resetActivity(t){g(this,za,t)}markActivity(t=c(this,Zl).call(this)){g(this,za,t),(c(this,Xr)===Fr.IDLE||c(this,Xr)===Fr.FADING)&&T(this,wr,a2).call(this),T(this,wr,jx).call(this)}scheduleIdle(){T(this,wr,jx).call(this)}teardown(){c(this,qr)!==void 0&&Re(c(this,qr)),c(this,Jr)!==void 0&&Re(c(this,Jr)),g(this,qr,void 0),g(this,Jr,void 0)}};Xr=new WeakMap,za=new WeakMap,qr=new WeakMap,Jr=new WeakMap,_s=new WeakMap,Kl=new WeakMap,Zl=new WeakMap,Da=new WeakMap,Cp=new WeakMap,Wl=new WeakMap,Lp=new WeakMap,wr=new WeakSet,a2=function(){var t,n,r;c(this,Jr)!==void 0&&(Re(c(this,Jr)),g(this,Jr,void 0)),g(this,Xr,Fr.BUSY),c(this,Wl)===pa.SESSION?(t=c(this,_s))==null||t.setAttribute(qd,GD):(n=c(this,_s))==null||n.setAttribute(gn,pi),(r=c(this,Kl))==null||r.setAttribute(gn,pi)},jx=function(){c(this,qr)!==void 0&&Re(c(this,qr)),g(this,qr,ue(()=>T(this,wr,Kx).call(this),c(this,Da)))},Kx=function(){if(g(this,qr,void 0),c(this,Xr)!==Fr.BUSY)return;let t=c(this,Zl).call(this)-c(this,za);if(t<c(this,Da)){g(this,qr,ue(()=>T(this,wr,Kx).call(this),c(this,Da)-t));return}T(this,wr,c2).call(this)},c2=function(){var t,n,r;g(this,Xr,Fr.FADING),c(this,Wl)===pa.SESSION?(t=c(this,_s))==null||t.setAttribute(qd,Mm):(n=c(this,_s))==null||n.setAttribute(gn,os),(r=c(this,Kl))==null||r.setAttribute(gn,os),c(this,Lp).call(this,ct.IDLE),g(this,Jr,ue(()=>{g(this,Jr,void 0),c(this,Xr)===Fr.FADING&&g(this,Xr,Fr.IDLE)},c(this,Cp)))}});function u2(e,t,n){let r=wW(t);if(e===void 0)return r;if(r.passes===0&&r.fails===0)return e.setAttribute("hidden",""),e.replaceChildren(),r;let o=e.ownerDocument;e.removeAttribute("hidden"),e.className="reticle-tally reticle-pill-group reticle-head-ctl",e.replaceChildren();let i=o.createElement("span");if(i.className="reticle-t-pass reticle-pill-segment",r.passes===0&&i.setAttribute("data-z","1"),r.passes>n.passes&&i.setAttribute("data-bump","1"),i.append(So(se.CHECK,Ae.TALLY)),r.passes>0){let l=o.createElement("span");l.className="reticle-pill-count",l.textContent=String(r.passes),i.append(l)}let s=o.createElement("span");s.className="reticle-pill-sep",s.setAttribute("aria-hidden","true");let a=o.createElement("span");if(a.className="reticle-t-fail reticle-pill-segment",r.fails===0&&a.setAttribute("data-z","1"),r.fails>n.fails&&a.setAttribute("data-bump","1"),a.append(So(se.REMOVE,Ae.TALLY)),r.fails>0){let l=o.createElement("span");l.className="reticle-pill-count",l.textContent=String(r.fails),a.append(l)}return e.append(i,s,a),r}function wW(e){let t=0,n=0;for(let r of e)r.result===Kn.PASS?t+=1:r.result===Kn.FAIL&&(n+=1);return{passes:t,fails:n}}var d2=y(()=>{"use strict";di();Hr()});function h2(e){for(let t of Array.from(e.attributes)){if(!t.name.startsWith(p2))continue;let n=t.name.slice(p2.length),r=S1.includes(n)?`${n}.${t.value}`:n;if(T1(r))return r}}function NW(e){for(let t of e)if(t instanceof Element&&h2(t)!==void 0)return t}function Zx(e){let t=RW(e);return Fn.BUBBLE===t.view||e.querySelector(`[${cs}]:not([hidden])`)===null?t:{view:t.view,panel:Dt.ACCOUNT}}function RW(e){if(e.getAttribute(Ze)==="1")return{view:Fn.BUBBLE,panel:Dt.NONE};if(e.getAttribute(ft)==="1")return{view:Fn.EXPANDED,panel:Dt.SETTINGS};if(e.getAttribute(On)==="1")return{view:Fn.EXPANDED,panel:Dt.REPORT};let t=e.getAttribute(f2);return t==="flows"?{view:Fn.EXPANDED,panel:Dt.FLOWS}:t==="annotations"?{view:Fn.EXPANDED,panel:Dt.NOTES}:t==="harness"?{view:Fn.EXPANDED,panel:Dt.HARNESS}:e.getAttribute(yt)==="1"?{view:Fn.EXPANDED,panel:Dt.CHAT}:{view:Fn.COLLAPSED,panel:Dt.NONE}}function m2(e,t,n){let r=h=>{try{n(h)}catch{}},o=h=>{var A;let E=NW(h.composedPath());if(E===void 0||!lr(E))return;let _=h2(E);if(_!==void 0){if(!vW.has((A=E.getAttribute("role"))!=null?A:"")){r({control:_});return}ue(()=>{let v=E.getAttribute("aria-checked")==="true";r({control:_,toggle:v?Bu.ON:Bu.OFF})},0)}},i="",s=()=>{let h=Zx(t),E=`${h.view}/${h.panel}`;E!==i&&(i=E,r(h))},a="",l=()=>{var _;if(Dt.CHAT!==Zx(t).panel)return;let h=t.querySelector(`[${vp}]:not([hidden])`),E=(_=h==null?void 0:h.getAttribute(vp))!=null?_:"";E.length===0||E===a||(a=E,r({slide:E}))},u=new Set,d=()=>{let h=Zx(t);for(let E of OW){if(u.has(E.surface)||!E.shown(h))continue;let _=t.querySelector(E.selector);_===null||!IW(_)||(u.add(E.surface),r({prompt:E.surface}))}},f=new MutationObserver(()=>{l(),s(),d()});f.observe(t,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["data-active","hidden"]}),e.addEventListener("click",o,!0);let m=new MutationObserver(h=>{s(),0<h.length&&l(),d()});return m.observe(t,{attributes:!0,attributeFilter:[Ze,yt,ft,On,f2]}),s(),d(),()=>{e.removeEventListener("click",o,!0),m.disconnect(),f.disconnect()}}var p2,f2,vW,OW,IW,g2=y(()=>{"use strict";pl();M();nt();dt();Ct();$g();xo();bg();zg();p2="data-reticle-",f2="data-reticle-page-open",vW=new Set(["switch","checkbox"]);OW=[{surface:ki.RAIL,selector:`[${xr}]`,shown:e=>Dt.CHAT===e.panel},{surface:ki.HARNESS,selector:`[data-reticle-page-panel="harness"] :is([${qt}],[${mp}])`,shown:e=>Dt.HARNESS===e.panel},{surface:ki.HEADER,selector:`[${ap}]`,shown:e=>Fn.BUBBLE!==e.view}],IW=e=>e.closest("[hidden]")===null});function E2(){var e;try{let t=JSON.parse((e=globalThis.sessionStorage.getItem(Wx))!=null?e:"[]");return Array.isArray(t)?t.filter(n=>typeof n=="object"&&n!==null&&typeof n.text=="string"&&typeof n.kind=="string"&&typeof n.ts=="string"&&typeof n.at=="number"):[]}catch{return[]}}function $p(e){try{globalThis.sessionStorage.setItem(Wx,JSON.stringify(e))}catch{}}function b2(e){try{let t=e!=null?e:"",n=globalThis.sessionStorage.getItem(At.PRESENTER_LOG_OWNER);return globalThis.sessionStorage.setItem(At.PRESENTER_LOG_OWNER,t),n===null||n===t?!1:(globalThis.sessionStorage.removeItem(Wx),!0)}catch{return!1}}var Wx,_2=y(()=>{"use strict";po();Wx=At.PRESENTER_LOG});var I2={};Ya(I2,{GlowPhase:()=>Fr,LOG_KIND:()=>Ge,LOG_RESULT:()=>Kn,Presenter:()=>Yx});var CW,Xl,We,Si,Ma,kp,Ua,Qr,ql,Jl,Ts,Ti,Ha,Ql,eu,Jn,tu,zp,Fa,Qn,$o,Dp,tn,nu,Pp,Mp,Ba,ko,eo,Up,Ln,vr,to,Hp,xs,Fp,Nr,zo,er,ru,ou,tr,Pe,iu,Bp,J,S2,T2,Pa,Xx,x2,A2,Ss,qx,y2,w2,Jx,v2,N2,Qx,R2,Yl,O2,Yx,C2=y(()=>{"use strict";M();gt();MS();QS();dt();di();$M();Gx();bg();xo();_g();op();rp();Ct();n2();s2();l2();Hr();d2();vx();gl();Gx();g2();pg();_2();Ct();di();CW=1600,Yx=class{constructor(t={}){x(this,J);x(this,Xl);x(this,We);x(this,Si);x(this,Ma);x(this,kp);x(this,Ua);x(this,Qr);x(this,ql);x(this,Jl);x(this,Ts);x(this,Ti);x(this,Ha);x(this,Ql,{passes:0,fails:0});x(this,eu,ct.IDLE);x(this,Jn);x(this,tu);x(this,zp);x(this,Fa);x(this,Qn);x(this,$o,"");x(this,Dp);x(this,tn);x(this,nu);x(this,Pp);x(this,Mp);x(this,Ba);x(this,ko,[]);x(this,eo,!1);x(this,Up,!1);x(this,Ln);x(this,vr);x(this,to);x(this,Hp);x(this,xs);x(this,Fp,new dg);x(this,Nr,[]);x(this,zo);x(this,er);x(this,ru);x(this,ou);x(this,tr);x(this,Pe);x(this,iu);x(this,Bp,!1);var n,r,o,i,s,a,l,u,d;g(this,Xl,VD(t.paceMs)),g(this,Jn,(n=t.now)!=null?n:Zh),g(this,tu,(r=t.heartbeatMs)!=null?r:KD),g(this,zp,(o=t.idleNoticeMs)!=null?o:ZD),g(this,nu,(i=t.idleEndMs)!=null?i:WD),g(this,Pp,(s=t.sessionId)!=null?s:""),g(this,Fa,(a=t.border)!=null?a:BD),g(this,Qn,new Bg({now:c(this,Jn),idleAfterMs:(l=t.idleAfterMs)!=null?l:jD,glowFadeMs:(u=t.glowFadeMs)!=null?u:XD,borderMode:c(this,Fa),setMode:f=>this.setMode(f)})),g(this,Ln,TT(t.logMax)),g(this,er,t.onControl),g(this,ru,t.onHudUse),g(this,tr,new Ig({emit:(f,m)=>{var h;return(h=c(this,er))==null?void 0:h.call(this,m!==void 0?{kind:f,text:m}:{kind:f})},logHuman:f=>{this.log(Ge.HUMAN,f)},endedFadeMs:(d=t.endedFadeMs)!=null?d:XP,runState:()=>this.runState(),clearRunLog:()=>T(this,J,Jx).call(this),onStateChange:()=>T(this,J,Pa).call(this)})),g(this,Pe,new Op({onChatOpen:()=>c(this,Pe).pulseFab(!1),onExpand:()=>T(this,J,Pa).call(this),onAnnotateToggle:()=>T(this,J,Pa).call(this),onCollapse:()=>T(this,J,Pa).call(this),onSyncNow:()=>{var f;return(f=c(this,er))==null?void 0:f.call(this,{kind:ln.SYNC})},onSignIn:()=>{var f;return(f=c(this,er))==null?void 0:f.call(this,{kind:ln.SIGNIN})},onHarness:f=>{var m;return(m=c(this,er))==null?void 0:m.call(this,{kind:ln.HARNESS,text:f?"on":"off"})},onHarnessRun:f=>{var m;return(m=c(this,er))==null?void 0:m.call(this,{kind:ln.HARNESS_RUN,...f===void 0?{}:{text:f}})},onHarnessStop:()=>{var f;return(f=c(this,er))==null?void 0:f.call(this,{kind:ln.HARNESS_STOP})},onHarnessLink:()=>{var f;return(f=c(this,er))==null?void 0:f.call(this,{kind:ln.HARNESS_LINK})},settings:{onBeforeOpen:()=>{c(this,Pe).isCollapsed()&&c(this,Pe).expand()},onHideUntilRestart:()=>T(this,J,v2).call(this),onKill:()=>{var f;return(f=t.onKill)==null?void 0:f.call(t)},onSettingsChange:f=>T(this,J,N2).call(this,f),onHarness:f=>{var m;return(m=c(this,er))==null?void 0:m.call(this,{kind:ln.HARNESS,text:f?"on":"off"})}}})),c(this,Pe).setProjectId(t.projectId)}setControlHandler(t){g(this,er,t)}get state(){return c(this,tr).state}get sessionActive(){return c(this,eo)}setState(t,n,r){c(this,tr).setState(t,n,r)}refilterFlows(){c(this,tr).refilterFlows()}showSdkVersion(t){c(this,We)!==void 0&&YT(c(this,We),t)}handlePush(t){var s;let n=t.args;if(t.name===H.FLOWS)return void c(this,tr).setFlows(n.flows);if(t.name===H.FLOW_PROGRESS)return void c(this,tr).setFlowProgress(n);if(t.name===H.PLAN){let a=lP(n);a!==void 0&&c(this,Fp).paint(a);return}if(t.name===H.IMPACT){let a=yP(n.snapshot);if(a!==void 0){c(this,Pe).report.setSnapshot(a),c(this,Pe).paintNotices(a.notices),c(this,Pe).paintHarness(a.harnessConfig),c(this,Pe).paintHarnessDrive(a.harnessDrive,a.lastDrive),T(this,J,A2).call(this,a.harnessDrive),c(this,Pe).paintAgent(a.agent),c(this,Pe).paintImpact(a.project.counts.verdicts);let l=((s=a.account)==null?void 0:s.signedIn)===!0?a.account.email:void 0;b2(l)&&T(this,J,Jx).call(this),c(this,Pe).paintAccount(a.account,a.dashboardUrl,{projectName:a.projectName,dashboardUrl:a.dashboardUrl,verdicts:a.project.counts.verdicts,defects:a.project.counts.failed,...L1(a.harnessConfig,a.sync)})}return}let r=n.state,o=n.tone,i=typeof n.text=="string"&&n.text.length>0?n.text:void 0;MO(r)&&this.setState(r,i,$I(o)?o:void 0)}get logMax(){return c(this,Ln)}set logMax(t){g(this,Ln,TT(t)),T(this,J,O2).call(this)}mount(){var o,i,s,a,l,u,d,f,m,h,E,_;if(c(this,We)!==void 0||typeof document=="undefined")return;let t=document.createElement("style");t.setAttribute("data-reticle-overlay",""),t.textContent=LM,document.head.appendChild(t);let n=document.createElement("div");n.setAttribute("data-reticle-overlay","");let r=`<div class="reticle-act-strip" data-liveness="idle"><span class="reticle-act-dot" aria-hidden="true"></span><span class="reticle-act" data-reticle-act-line>${Br.READY}</span>${QP}<span class="reticle-chip" data-reticle-chip></span><div class="reticle-act-actions">${JP}</div></div>`;n.innerHTML=`
1732
- ${qT()}
1731
+ </div>`}get report(){return c(this,ko)}isAnnotateOn(){return c(this,_s)}setAnnotateOn(t){var r,o,i,s,a,l,u;g(this,_s,t),(r=c(this,$o))==null||r.setAttribute("aria-pressed",t?"true":"false"),(o=c(this,$o))==null||o.setAttribute("data-active",t?"1":"0"),(i=c(this,$o))==null||i.setAttribute("aria-label",t?"Stop adding notes":"Add notes"),(s=c(this,$o))==null||s.setAttribute("title",t?"Stop adding notes":"Add notes");let n=(a=c(this,$o))==null?void 0:a.querySelector("[data-reticle-notes-toggle-label]");n!=null&&(n.textContent=t?"Stop adding notes":"Add notes"),(u=(l=c(this,$e))==null?void 0:l.querySelector('[data-reticle-chat-view-btn="annotations"]'))==null||u.setAttribute("data-capture",t?"1":"0")}mount(t){var f,m,h,E;g(this,ka,new AbortController);let{signal:n}=c(this,ka);g(this,$e,t),g(this,en,(f=t.querySelector(`[${F}]`))!=null?f:void 0);let r=t.querySelector(`[${p1}]`);g(this,vr,r instanceof HTMLButtonElement?r:void 0);let o=t.querySelector(`[${En}]`);g(this,Ia,o instanceof HTMLElement?o:void 0);let i=t.querySelector(`[${Ym}]`);g(this,$o,i instanceof HTMLButtonElement?i:void 0),this.setAnnotateOn(c(this,_s)),(m=c(this,$o))==null||m.addEventListener("click",S=>{var A,w;S.preventDefault(),S.stopPropagation(),this.setAnnotateOn(!c(this,_s)),(w=(A=c(this,Jr)).onAnnotateToggle)==null||w.call(A,c(this,_s))},{signal:n});let s=t.querySelector(`[${Ft}]`);s==null||s.addEventListener("click",S=>{S.preventDefault(),S.stopPropagation(),Gl(!0),this.showChat()},{signal:n});let a=t.querySelector(`[${kT}]`);a==null||a.addEventListener("click",S=>{S.preventDefault(),S.stopPropagation(),Gl(!1),this.closeChat()},{signal:n});let l=t.querySelector("[data-reticle-min-btn]");g(this,Vl,l instanceof HTMLButtonElement?l:void 0),t.setAttribute(We,"1"),t.setAttribute(ft,"0"),t.removeAttribute(yt),c(this,jt).mount(t),c(this,ko).mount(t),c(this,bt).mount(t),g(this,xi,T(this,Ln,Gg).call(this)),Xx(t,c(this,Zl),c(this,xi)),g(this,$a,new MutationObserver(()=>T(this,Ln,Jx).call(this))),c(this,$a).observe(t,{attributes:!0,attributeFilter:[yt,ft,In]}),T(this,Ln,Jx).call(this),(h=c(this,vr))==null||h.addEventListener("click",S=>{if(S.stopPropagation(),c(this,La)){g(this,La,!1);return}Gl(!0),this.expand()},{signal:n}),(E=c(this,Vl))==null||E.addEventListener("click",S=>{S.stopPropagation(),Gl(!1),this.collapse()},{signal:n});let u=t.querySelector(`.${l2}`),d=[c(this,vr),u].filter(S=>S instanceof HTMLElement);if(c(this,en)!==void 0&&d.length>0&&(g(this,jl,k1(c(this,en),d,{onDragMove:()=>{g(this,La,!0)},onDragEnd:S=>{g(this,La,S&&this.isCollapsed())}})),g(this,Kl,$1(c(this,en),t))),document.addEventListener("pointerdown",c(this,Vg),{signal:n}),document.addEventListener("keydown",c(this,jg),{signal:n}),g(this,Wl,Y1(t,()=>{var S,A;return(A=(S=c(this,Jr)).onSignIn)==null?void 0:A.call(S)})),c(this,za)!==void 0){let S=c(this,za);this.paintAccount(S.account,S.dashboardUrl,S.details)}}teardown(){var t,n,r,o,i;(t=c(this,Wl))==null||t.call(this),g(this,Wl,void 0),(n=c(this,ka))==null||n.abort(),g(this,ka,void 0),(r=c(this,$a))==null||r.disconnect(),g(this,$a,void 0),(o=c(this,jl))==null||o.call(this),g(this,jl,void 0),(i=c(this,Kl))==null||i.call(this),g(this,Kl,void 0),c(this,jt).teardown(),c(this,bt).teardown(),g(this,$e,void 0),g(this,en,void 0),g(this,vr,void 0),g(this,Ia,void 0),g(this,Vl,void 0)}isCollapsed(){var t;return((t=c(this,$e))==null?void 0:t.getAttribute(We))==="1"}isChatOpen(){var t;return((t=c(this,$e))==null?void 0:t.getAttribute(yt))==="1"}expand(){var t,n;c(this,$e)===void 0||!this.isCollapsed()||c(this,Ca)||(T(this,Ln,f2).call(this),c(this,$e).setAttribute(We,"0"),p2(!1),c(this,vr)!==void 0&&c(this,vr).setAttribute("aria-expanded","true"),(n=(t=c(this,Jr)).onExpand)==null||n.call(t),this.openChat(),c(this,en)!==void 0&&Wr(c(this,en),c(this,$e)))}collapse(){var t,n;c(this,$e)!==void 0&&(g(this,Ca,!1),this.closeChat(),c(this,jt).close(),c(this,$e).setAttribute(We,"1"),p2(!0),c(this,vr)!==void 0&&c(this,vr).setAttribute("aria-expanded","false"),(n=(t=c(this,Jr)).onCollapse)==null||n.call(t))}openChat(){var n,r,o;if(c(this,$e)===void 0||(this.isCollapsed()&&this.expand(),c(this,jt).close(),c(this,bt).closePage(),c(this,bt).open("activity"),this.isChatOpen()))return;c(this,$e).setAttribute(yt,"1");let t=c(this,$e).querySelector("[data-reticle-log]");t!==null&&e1(t),(n=c(this,Ia))==null||n.setAttribute("aria-hidden","false"),(o=(r=c(this,Jr)).onChatOpen)==null||o.call(r),c(this,en)!==void 0&&Wr(c(this,en),c(this,$e))}closeChat(){var t,n,r;c(this,$e)===void 0||!this.isChatOpen()||(c(this,$e).removeAttribute(yt),(t=c(this,Ia))==null||t.setAttribute("aria-hidden","true"),(r=(n=c(this,Jr)).onChatClose)==null||r.call(n),c(this,en)!==void 0&&Wr(c(this,en),c(this,$e)))}toggleChat(){this.isChatOpen()?this.closeChat():this.showChat()}showChat(){c(this,ko).close(),this.openChat()}pulseFab(t){var n;(n=c(this,vr))==null||n.setAttribute("data-pulse",t?"1":"0")}};$e=new WeakMap,en=new WeakMap,vr=new WeakMap,Ia=new WeakMap,Vl=new WeakMap,jt=new WeakMap,bt=new WeakMap,jl=new WeakMap,Kl=new WeakMap,Ca=new WeakMap,La=new WeakMap,$o=new WeakMap,_s=new WeakMap,$a=new WeakMap,ka=new WeakMap,ko=new WeakMap,Jr=new WeakMap,za=new WeakMap,Zl=new WeakMap,kp=new WeakMap,xi=new WeakMap,Wl=new WeakMap,Ln=new WeakSet,Gg=function(){var t,n;return zx(c(this,kp),(n=(t=c(this,za))==null?void 0:t.account)!=null?n:{signedIn:!1})},qx=function(){let t=T(this,Ln,Gg).call(this);c(this,$e)===void 0||t===c(this,xi)||(g(this,xi,t),Xx(c(this,$e),c(this,Zl),t))},Jx=function(){let t=c(this,$e);if(t===void 0)return;let n=(o,i)=>{let s=t.querySelector(`[${o}]`);s==null||s.setAttribute("data-active",i?"1":"0"),s==null||s.setAttribute("aria-pressed",i?"true":"false")};n(Vm,t.getAttribute(yt)==="1"),n(np,t.getAttribute(ft)==="1");let r=t.querySelector("[data-reticle-chat-impact]");if(r!==null){let o=t.getAttribute(In)==="1";r.setAttribute("data-active",o?"1":"0"),c(this,bt).setImpactOpen(o),o?r.setAttribute("aria-current","page"):r.removeAttribute("aria-current")}},f2=function(){g(this,Ca,!0),window.setTimeout(()=>{g(this,Ca,!1)},iY)},Vg=new WeakMap,jg=new WeakMap});function g2(e){var r,o;let t=(r=e.startMs)!=null?r:e.now,n={reads:0,acts:0,narrations:0,human:0,passes:0,fails:0};for(let i of e.runLog)i.kind===Ge.READ?n.reads+=1:i.kind===Ge.ACT?n.acts+=1:i.kind===Ge.NARRATION?n.narrations+=1:i.kind===Ge.HUMAN&&(n.human+=1),i.result===Kn.PASS?n.passes+=1:i.result===Kn.FAIL&&(n.fails+=1);return{session:e.sessionId,url:typeof location=="undefined"?"":zh(),state:e.state,startedMs:t,durationMs:Math.max(0,((o=e.endMs)!=null?o:e.now)-t),counts:n,capabilities:Ki(),log:e.runLog.map(i=>({...i}))}}var E2=y(()=>{"use strict";bd();hi();Zi()});function b2(e,t,n){e!==void 0&&(e.setAttribute("data-on","1"),e.style.transform=`translate(${String(t)}px, ${String(n)}px)`)}function _2(e,t){e!==void 0&&(e.style.left=`${String(t.left-4)}px`,e.style.top=`${String(t.top-4)}px`,e.style.width=`${String(t.width+8)}px`,e.style.height=`${String(t.height+8)}px`,e.setAttribute("data-on","1"),de(()=>e.setAttribute("data-on","0"),700))}function S2(e,t,n){if(e===void 0)return;let r=document.createElement("div");r.setAttribute("data-reticle-ripple",""),r.style.left=`${String(t)}px`,r.style.top=`${String(n)}px`,e.appendChild(r),de(()=>r.remove(),520)}function tA(e){return new Promise(t=>de(t,e))}var T2=y(()=>{"use strict";dt()});var Qr,Da,eo,to,Ss,Yl,Xl,Pa,zp,ql,Dp,Nr,x2,nA,rA,A2,Kg,y2=y(()=>{"use strict";M();dt();Lt();Kg=class{constructor(t){x(this,Nr);x(this,Qr,Vr.IDLE);x(this,Da,0);x(this,eo);x(this,to);x(this,Ss);x(this,Yl);x(this,Xl);x(this,Pa);x(this,zp);x(this,ql);x(this,Dp);g(this,Xl,t.now),g(this,Pa,t.idleAfterMs),g(this,zp,t.glowFadeMs),g(this,ql,t.borderMode),g(this,Dp,t.setMode)}setElements(t,n){g(this,Ss,t),g(this,Yl,n)}phase(){return c(this,Qr)}lastActivityMs(){return c(this,Da)}resetActivity(t){g(this,Da,t)}markActivity(t=c(this,Xl).call(this)){g(this,Da,t),(c(this,Qr)===Vr.IDLE||c(this,Qr)===Vr.FADING)&&T(this,Nr,x2).call(this),T(this,Nr,nA).call(this)}scheduleIdle(){T(this,Nr,nA).call(this)}teardown(){c(this,eo)!==void 0&&Oe(c(this,eo)),c(this,to)!==void 0&&Oe(c(this,to)),g(this,eo,void 0),g(this,to,void 0)}};Qr=new WeakMap,Da=new WeakMap,eo=new WeakMap,to=new WeakMap,Ss=new WeakMap,Yl=new WeakMap,Xl=new WeakMap,Pa=new WeakMap,zp=new WeakMap,ql=new WeakMap,Dp=new WeakMap,Nr=new WeakSet,x2=function(){var t,n,r;c(this,to)!==void 0&&(Oe(c(this,to)),g(this,to,void 0)),g(this,Qr,Vr.BUSY),c(this,ql)===fa.SESSION?(t=c(this,Ss))==null||t.setAttribute(tp,o1):(n=c(this,Ss))==null||n.setAttribute(gn,mi),(r=c(this,Yl))==null||r.setAttribute(gn,mi)},nA=function(){c(this,eo)!==void 0&&Oe(c(this,eo)),g(this,eo,de(()=>T(this,Nr,rA).call(this),c(this,Pa)))},rA=function(){if(g(this,eo,void 0),c(this,Qr)!==Vr.BUSY)return;let t=c(this,Xl).call(this)-c(this,Da);if(t<c(this,Pa)){g(this,eo,de(()=>T(this,Nr,rA).call(this),c(this,Pa)-t));return}T(this,Nr,A2).call(this)},A2=function(){var t,n,r;g(this,Qr,Vr.FADING),c(this,ql)===fa.SESSION?(t=c(this,Ss))==null||t.setAttribute(tp,Bm):(n=c(this,Ss))==null||n.setAttribute(gn,is),(r=c(this,Yl))==null||r.setAttribute(gn,is),c(this,Dp).call(this,ct.IDLE),g(this,to,de(()=>{g(this,to,void 0),c(this,Qr)===Vr.FADING&&g(this,Qr,Vr.IDLE)},c(this,zp)))}});function w2(e,t,n){let r=cY(t);if(e===void 0)return r;if(r.passes===0&&r.fails===0)return e.setAttribute("hidden",""),e.replaceChildren(),r;let o=e.ownerDocument;e.removeAttribute("hidden"),e.className="reticle-tally reticle-pill-group reticle-head-ctl",e.replaceChildren();let i=o.createElement("span");if(i.className="reticle-t-pass reticle-pill-segment",r.passes===0&&i.setAttribute("data-z","1"),r.passes>n.passes&&i.setAttribute("data-bump","1"),i.append(xo(se.CHECK,ye.TALLY)),r.passes>0){let l=o.createElement("span");l.className="reticle-pill-count",l.textContent=String(r.passes),i.append(l)}let s=o.createElement("span");s.className="reticle-pill-sep",s.setAttribute("aria-hidden","true");let a=o.createElement("span");if(a.className="reticle-t-fail reticle-pill-segment",r.fails===0&&a.setAttribute("data-z","1"),r.fails>n.fails&&a.setAttribute("data-bump","1"),a.append(xo(se.REMOVE,ye.TALLY)),r.fails>0){let l=o.createElement("span");l.className="reticle-pill-count",l.textContent=String(r.fails),a.append(l)}return e.append(i,s,a),r}function cY(e){let t=0,n=0;for(let r of e)r.result===Kn.PASS?t+=1:r.result===Kn.FAIL&&(n+=1);return{passes:t,fails:n}}var v2=y(()=>{"use strict";hi();Gr()});function O2(e){for(let t of Array.from(e.attributes)){if(!t.name.startsWith(N2))continue;let n=t.name.slice(N2.length),r=z1.includes(n)?`${n}.${t.value}`:n;if(D1(r))return r}}function uY(e){for(let t of e)if(t instanceof Element&&O2(t)!==void 0)return t}function oA(e){let t=dY(e);return Bn.BUBBLE===t.view||e.querySelector(`[${ls}]:not([hidden])`)===null?t:{view:t.view,panel:Mt.ACCOUNT}}function dY(e){if(e.getAttribute(We)==="1")return{view:Bn.BUBBLE,panel:Mt.NONE};if(e.getAttribute(ft)==="1")return{view:Bn.EXPANDED,panel:Mt.SETTINGS};if(e.getAttribute(In)==="1")return{view:Bn.EXPANDED,panel:Mt.REPORT};let t=e.getAttribute(R2);return t==="flows"?{view:Bn.EXPANDED,panel:Mt.FLOWS}:t==="annotations"?{view:Bn.EXPANDED,panel:Mt.NOTES}:t==="harness"?{view:Bn.EXPANDED,panel:Mt.HARNESS}:e.getAttribute(yt)==="1"?{view:Bn.EXPANDED,panel:Mt.CHAT}:{view:Bn.COLLAPSED,panel:Mt.NONE}}function I2(e,t,n){let r=h=>{try{n(h)}catch{}},o=h=>{var A;let E=uY(h.composedPath());if(E===void 0||!dr(E))return;let S=O2(E);if(S!==void 0){if(!lY.has((A=E.getAttribute("role"))!=null?A:"")){r({control:S});return}de(()=>{let w=E.getAttribute("aria-checked")==="true";r({control:S,toggle:w?Ku.ON:Ku.OFF})},0)}},i="",s=()=>{let h=oA(t),E=`${h.view}/${h.panel}`;E!==i&&(i=E,r(h))},a="",l=()=>{var S;if(Mt.CHAT!==oA(t).panel)return;let h=t.querySelector(`[${Ip}]:not([hidden])`),E=(S=h==null?void 0:h.getAttribute(Ip))!=null?S:"";E.length===0||E===a||(a=E,r({slide:E}))},u=new Set,d=()=>{let h=oA(t);for(let E of pY){if(u.has(E.surface)||!E.shown(h))continue;let S=t.querySelector(E.selector);S===null||!fY(S)||(u.add(E.surface),r({prompt:E.surface}))}},f=new MutationObserver(()=>{l(),s(),d()});f.observe(t,{subtree:!0,childList:!0,attributes:!0,attributeFilter:["data-active","hidden"]}),e.addEventListener("click",o,!0);let m=new MutationObserver(h=>{s(),0<h.length&&l(),d()});return m.observe(t,{attributes:!0,attributeFilter:[We,yt,ft,In,R2]}),s(),d(),()=>{e.removeEventListener("click",o,!0),m.disconnect(),f.disconnect()}}var N2,R2,lY,pY,fY,C2=y(()=>{"use strict";ml();M();ot();dt();Lt();Pg();yo();xg();Ug();N2="data-reticle-",R2="data-reticle-page-open",lY=new Set(["switch","checkbox"]);pY=[{surface:zi.RAIL,selector:`[${yr}]`,shown:e=>Mt.CHAT===e.panel},{surface:zi.HARNESS,selector:`[data-reticle-page-panel="harness"] :is([${qt}],[${_p}])`,shown:e=>Mt.HARNESS===e.panel},{surface:zi.HEADER,selector:`[${dp}]`,shown:e=>Bn.BUBBLE!==e.view}],fY=e=>e.closest("[hidden]")===null});function L2(){var e;try{let t=JSON.parse((e=globalThis.sessionStorage.getItem(iA))!=null?e:"[]");return Array.isArray(t)?t.filter(n=>typeof n=="object"&&n!==null&&typeof n.text=="string"&&typeof n.kind=="string"&&typeof n.ts=="string"&&typeof n.at=="number"):[]}catch{return[]}}function Pp(e){try{globalThis.sessionStorage.setItem(iA,JSON.stringify(e))}catch{}}function $2(e){try{let t=e!=null?e:"",n=globalThis.sessionStorage.getItem(At.PRESENTER_LOG_OWNER);return globalThis.sessionStorage.setItem(At.PRESENTER_LOG_OWNER,t),n===null||n===t?!1:(globalThis.sessionStorage.removeItem(iA),!0)}catch{return!1}}var iA,k2=y(()=>{"use strict";ho();iA=At.PRESENTER_LOG});var j2={};qa(j2,{GlowPhase:()=>Vr,LOG_KIND:()=>Ge,LOG_RESULT:()=>Kn,Presenter:()=>sA});var hY,Ql,Ye,Ai,Ua,Mp,Ha,no,eu,tu,xs,yi,Fa,nu,ru,Jn,ou,Up,Ba,Qn,zo,Hp,tn,iu,Fp,Bp,Ga,Do,ro,Gp,$n,Rr,oo,Vp,As,jp,Or,Po,er,su,au,tr,Pe,cu,Kp,Q,z2,D2,Ma,aA,P2,M2,Ts,cA,U2,H2,lA,F2,B2,uA,G2,Jl,V2,sA,K2=y(()=>{"use strict";M();gt();YS();uT();dt();hi();WM();eA();xg();yo();Ag();cp();ap();Lt();E2();T2();y2();Gr();v2();Px();_l();eA();C2();gg();k2();Lt();hi();hY=1600,sA=class{constructor(t={}){x(this,Q);x(this,Ql);x(this,Ye);x(this,Ai);x(this,Ua);x(this,Mp);x(this,Ha);x(this,no);x(this,eu);x(this,tu);x(this,xs);x(this,yi);x(this,Fa);x(this,nu,{passes:0,fails:0});x(this,ru,ct.IDLE);x(this,Jn);x(this,ou);x(this,Up);x(this,Ba);x(this,Qn);x(this,zo,"");x(this,Hp);x(this,tn);x(this,iu);x(this,Fp);x(this,Bp);x(this,Ga);x(this,Do,[]);x(this,ro,!1);x(this,Gp,!1);x(this,$n);x(this,Rr);x(this,oo);x(this,Vp);x(this,As);x(this,jp,new mg);x(this,Or,[]);x(this,Po);x(this,er);x(this,su);x(this,au);x(this,tr);x(this,Pe);x(this,cu);x(this,Kp,!1);var n,r,o,i,s,a,l,u,d;g(this,Ql,i1(t.paceMs)),g(this,Jn,(n=t.now)!=null?n:qh),g(this,ou,(r=t.heartbeatMs)!=null?r:a1),g(this,Up,(o=t.idleNoticeMs)!=null?o:c1),g(this,iu,(i=t.idleEndMs)!=null?i:l1),g(this,Fp,(s=t.sessionId)!=null?s:""),g(this,Ba,(a=t.border)!=null?a:r1),g(this,Qn,new Kg({now:c(this,Jn),idleAfterMs:(l=t.idleAfterMs)!=null?l:s1,glowFadeMs:(u=t.glowFadeMs)!=null?u:d1,borderMode:c(this,Ba),setMode:f=>this.setMode(f)})),g(this,$n,LT(t.logMax)),g(this,er,t.onControl),g(this,su,t.onHudUse),g(this,tr,new kg({emit:(f,m)=>{var h;return(h=c(this,er))==null?void 0:h.call(this,m!==void 0?{kind:f,text:m}:{kind:f})},logHuman:f=>{this.log(Ge.HUMAN,f)},endedFadeMs:(d=t.endedFadeMs)!=null?d:dM,runState:()=>this.runState(),clearRunLog:()=>T(this,Q,lA).call(this),onStateChange:()=>T(this,Q,Ma).call(this)})),g(this,Pe,new $p({onChatOpen:()=>c(this,Pe).pulseFab(!1),onExpand:()=>T(this,Q,Ma).call(this),onAnnotateToggle:()=>T(this,Q,Ma).call(this),onCollapse:()=>T(this,Q,Ma).call(this),onSyncNow:()=>{var f;return(f=c(this,er))==null?void 0:f.call(this,{kind:ln.SYNC})},onSignIn:()=>{var f;return(f=c(this,er))==null?void 0:f.call(this,{kind:ln.SIGNIN})},onHarness:f=>{var m;return(m=c(this,er))==null?void 0:m.call(this,{kind:ln.HARNESS,text:f?"on":"off"})},onHarnessRun:f=>{var m;return(m=c(this,er))==null?void 0:m.call(this,{kind:ln.HARNESS_RUN,...f===void 0?{}:{text:f}})},onHarnessStop:()=>{var f;return(f=c(this,er))==null?void 0:f.call(this,{kind:ln.HARNESS_STOP})},onHarnessLink:()=>{var f;return(f=c(this,er))==null?void 0:f.call(this,{kind:ln.HARNESS_LINK})},settings:{onBeforeOpen:()=>{c(this,Pe).isCollapsed()&&c(this,Pe).expand()},onHideUntilRestart:()=>T(this,Q,F2).call(this),onKill:()=>{var f;return(f=t.onKill)==null?void 0:f.call(t)},onSettingsChange:f=>T(this,Q,B2).call(this,f),onHarness:f=>{var m;return(m=c(this,er))==null?void 0:m.call(this,{kind:ln.HARNESS,text:f?"on":"off"})}}})),c(this,Pe).setProjectId(t.projectId)}setControlHandler(t){g(this,er,t)}get state(){return c(this,tr).state}get sessionActive(){return c(this,ro)}setState(t,n,r){c(this,tr).setState(t,n,r)}refilterFlows(){c(this,tr).refilterFlows()}showSdkVersion(t){c(this,Ye)!==void 0&&sx(c(this,Ye),t)}handlePush(t){var s;let n=t.args;if(t.name===H.FLOWS)return void c(this,tr).setFlows(n.flows);if(t.name===H.FLOW_PROGRESS)return void c(this,tr).setFlowProgress(n);if(t.name===H.PLAN){let a=yP(n);a!==void 0&&c(this,jp).paint(a);return}if(t.name===H.IMPACT){let a=UP(n.snapshot);if(a!==void 0){c(this,Pe).report.setSnapshot(a),c(this,Pe).paintNotices(a.notices),c(this,Pe).paintHarness(a.harnessConfig),c(this,Pe).paintHarnessDrive(a.harnessDrive,a.lastDrive),T(this,Q,M2).call(this,a.harnessDrive),c(this,Pe).paintAgent(a.agent),c(this,Pe).paintImpact(a.project.counts.verdicts);let l=((s=a.account)==null?void 0:s.signedIn)===!0?a.account.email:void 0;$2(l)&&T(this,Q,lA).call(this),c(this,Pe).paintAccount(a.account,a.dashboardUrl,{projectName:a.projectName,dashboardUrl:a.dashboardUrl,verdicts:a.project.counts.verdicts,defects:a.project.counts.failed,...Z1(a.harnessConfig,a.sync)})}return}let r=n.state,o=n.tone,i=typeof n.text=="string"&&n.text.length>0?n.text:void 0;WO(r)&&this.setState(r,i,jI(o)?o:void 0)}get logMax(){return c(this,$n)}set logMax(t){g(this,$n,LT(t)),T(this,Q,V2).call(this)}mount(){var o,i,s,a,l,u,d,f,m,h,E,S;if(c(this,Ye)!==void 0||typeof document=="undefined")return;let t=document.createElement("style");t.setAttribute("data-reticle-overlay",""),t.textContent=ZM,document.head.appendChild(t);let n=document.createElement("div");n.setAttribute("data-reticle-overlay","");let r=`<div class="reticle-act-strip" data-liveness="idle"><span class="reticle-act-dot" aria-hidden="true"></span><span class="reticle-act" data-reticle-act-line>${jr.READY}</span>${hM}<span class="reticle-chip" data-reticle-chip></span><div class="reticle-act-actions">${fM}</div></div>`;n.innerHTML=`
1732
+ ${cx()}
1733
1733
  <div data-reticle-glow></div>
1734
1734
  <div data-reticle-cursor></div>
1735
1735
  <div data-reticle-ring></div>
1736
- ${Op.dockHtml(r,"",ST,eM,tM)}`,document.body.appendChild(n),g(this,We,n),g(this,Si,(o=n.querySelector("[data-reticle-glow]"))!=null?o:void 0),g(this,Ma,(i=n.querySelector("[data-reticle-cursor]"))!=null?i:void 0),g(this,kp,(s=n.querySelector("[data-reticle-ring]"))!=null?s:void 0),g(this,Ua,(a=n.querySelector("[data-reticle-hud]"))!=null?a:void 0),g(this,Qr,(l=n.querySelector(".reticle-act"))!=null?l:void 0),g(this,ql,(u=n.querySelector(".reticle-act-strip"))!=null?u:void 0),g(this,Jl,(d=n.querySelector("[data-reticle-chat-pill-text]"))!=null?d:void 0),g(this,Ts,(f=n.querySelector("[data-reticle-chat-pill-time]"))!=null?f:void 0),g(this,vr,(m=n.querySelector(`[${ST}]`))!=null?m:void 0),g(this,to,(h=n.querySelector(`[${Eg}]`))!=null?h:void 0),g(this,Ti,(E=n.querySelector("[data-reticle-chip]"))!=null?E:void 0),g(this,Ha,(_=n.querySelector("[data-reticle-tally]"))!=null?_:void 0),c(this,Pe).mount(n),lg(n,Tr(),!1),c(this,Qn).setElements(c(this,Si),c(this,Ma)),c(this,tr).mount(n,c(this,Si)),c(this,Fp).mount(n),c(this,ru)!==void 0&&g(this,ou,m2(document,n,c(this,ru))),this.setMode(c(this,eu)),T(this,J,S2).call(this),T(this,J,Yl).call(this)}bindAnnotator(t){g(this,iu,t);let n=c(this,We);if(n===void 0)return;let r=n.querySelector(`[${Fm}]`),o=n.querySelector(`[${Bm}]`),i=n.querySelector(`[${JD}]`),s=n.querySelector(`[${Gm}]`),a=n.querySelector(`[${Vm}]`),l={};a instanceof HTMLElement&&(l.copyRow=a);let u=t.markCount;l.onCount=d=>{u===0&&d>0&&c(this,Pe).openView("annotations"),u=d},l.onMarksChange=d=>c(this,Pe).paintAnnotations(d),s instanceof HTMLElement&&s.addEventListener("click",d=>{d.stopPropagation(),T(this,J,T2).call(this,t,s)}),r instanceof HTMLElement&&(l.markersBtn=r),o instanceof HTMLElement&&(l.clearBtn=o),i instanceof HTMLElement&&(l.countEl=i),t.attachChrome(l),t.setAccent(dp(Tr().statusThemeId).active),T(this,J,Pa).call(this)}destroy(){var t,n;c(this,Qn).teardown(),c(this,tn)!==void 0&&Re(c(this,tn)),g(this,tn,void 0),(t=c(this,ou))==null||t.call(this),g(this,ou,void 0),c(this,Pe).teardown(),c(this,tr).teardown(),g(this,eo,!1),g(this,zo,void 0),g(this,vr,void 0),g(this,to,void 0),g(this,Nr,[]),$p([]),(n=c(this,We))==null||n.remove(),document.querySelectorAll("style[data-reticle-overlay]").forEach(r=>r.remove()),g(this,We,void 0)}sessionStart(){var t,n;if(this.state===Xe.ENDED){T(this,J,x2).call(this);return}c(this,eo)||(xT===((t=c(this,We))==null?void 0:t.getAttribute(Um))&&c(this,We).removeAttribute(Um),g(this,eo,!0),(n=c(this,Mp))!=null||g(this,Mp,c(this,Jn).call(this)),g(this,Ba,void 0),T(this,J,Xx).call(this),c(this,Qn).resetActivity(c(this,Jn).call(this)),T(this,J,qx).call(this),Bx()&&c(this,Pe).openChat())}showUnreachable(t,n){var o,i,s,a;if(c(this,eo))return;(o=c(this,We))==null||o.setAttribute(Um,xT);let r=(i=c(this,We))==null?void 0:i.querySelector("[data-reticle-dock]");r==null||r.setAttribute(gn,pi),(s=c(this,Ua))==null||s.setAttribute(gn,pi),g(this,$o,bk),T(this,J,Ss).call(this,c(this,$o),!0),(a=c(this,Qr))==null||a.setAttribute("title",pm(t,n)),Bx()&&c(this,Pe).openChat()}sessionEnd(){var n,r,o,i;if(!c(this,eo))return;g(this,eo,!1),c(this,tn)!==void 0&&(Re(c(this,tn)),g(this,tn,void 0));let t=(n=c(this,We))==null?void 0:n.querySelector("[data-reticle-dock]");t==null||t.setAttribute(gn,os),(r=c(this,Ua))==null||r.setAttribute(gn,os),c(this,Pe).collapse(),c(this,Fa)===pa.SESSION&&((o=c(this,Si))==null||o.setAttribute(gn,os),(i=c(this,Si))==null||i.setAttribute(qd,Mm))}markActivity(){c(this,Qn).markActivity()}scheduleIdle(){c(this,Qn).scheduleIdle()}glowPhase(){return c(this,Qn).phase()}get mode(){return c(this,eu)}setMode(t){var n,r;if(g(this,eu,t),(n=c(this,We))==null||n.setAttribute("data-reticle-mode",t),c(this,Ti)!==void 0){let o=DD[t];if(c(this,Ti).setAttribute("data-mode",t),c(this,Ti).replaceChildren(),o.length>0){let i=t===ct.READING?se.VIEW:t===ct.ACTING?se.POINTER:void 0;i!==void 0&&c(this,Ti).appendChild(So(i,Ae.CHIP));let s=document.createElement("span");s.className="reticle-chip-label",s.textContent=o,c(this,Ti).appendChild(s)}}t===ct.READING&&((r=c(this,Ma))==null||r.setAttribute(gn,os))}status(t){this.markActivity(),c(this,Ts)!==void 0&&(c(this,Ts).textContent=Br.NOW),g(this,$o,t),T(this,J,Ss).call(this,t,!1)}placeHud(t,n){let r=c(this,We);if(r===void 0)return c(this,Bp)?[FO]:[];let o=[];if(Bn.REMOVED===t)return g(this,Bp,!0),this.destroy(),[t];Bn.HIDDEN===t&&r.setAttribute(al,"1"),Bn.SHOWN===t&&r.removeAttribute(al),t!==void 0&&o.push(t);let i=r.querySelector(`[${F}]`);if(n!==void 0&&i instanceof HTMLElement){if(Jf.BOTTOM_RIGHT===n)tp(i);else{let s=dl(i),a=n.endsWith("left")?0:window.innerWidth,l=n.startsWith("top")?0:window.innerHeight,u=ul(a,l,s.width,s.height,window.innerWidth,window.innerHeight);ss(i,u.left,u.top)}o.push(n),jr(i,r)}return o}setIdleEndMs(t){Number.isFinite(t)&&g(this,nu,Math.max(YD,Math.floor(t)))}runState(){let t=t2({sessionId:c(this,Pp),state:this.state,startMs:c(this,Mp),endMs:c(this,Ba),now:c(this,Jn).call(this),runLog:c(this,ko)}),n=Tr();return n.outputDetail===Kr.MINIMAL?{session:t.session,url:t.url,state:t.state,startedMs:t.startedMs,durationMs:t.durationMs,counts:t.counts}:n.outputDetail===Kr.VERBOSE&&n.reactComponents?{...t,includeReactComponents:!0}:t}log(t,n,r,o,i=!1){var h;let s=c(this,Jn).call(this);if(c(this,Qn).markActivity(s),g(this,Dp,o),c(this,vr)===void 0)return;let a=n.trim();if(a.length===0)return;(h=c(this,zo))!=null||g(this,zo,s);let l=r!==void 0?{at:s-c(this,zo),kind:t,text:a,result:r}:{at:s-c(this,zo),kind:t,text:a};for(c(this,ko).push(l);c(this,ko).length>c(this,Ln);)c(this,ko).shift();let u=FD(s-c(this,zo)),d=T(this,J,Qx).call(this,o,i).map(E=>Pm(E,t,a,u,c(this,Ln),o)),f={result:E=>d.forEach(_=>_.result(E))};r!==void 0&&f.result(r);let m={kind:t,text:a,ts:u,at:s-c(this,zo),...o===void 0?{}:{actor:o},...i?{summary:!0}:{},...r===void 0?{}:{result:r}};for(c(this,Nr).push(m);c(this,Nr).length>c(this,Ln);)c(this,Nr).shift();return $p(c(this,Nr)),T(this,J,R2).call(this,t),c(this,Pe).isCollapsed()&&c(this,Pe).pulseFab(!0),T(this,J,Yl).call(this),{result:E=>{f.result(E),l.result=E,m.result=E,$p(c(this,Nr)),T(this,J,Yl).call(this)}}}narrate(t,n="info",r=hn.AGENT,o=!1){let i=n==="info"?t:`[${n}] ${t}`;return this.log(Ge.NARRATION,i,void 0,r,o)}setThrottled(t){var n;(n=c(this,We))==null||n.setAttribute(r1,t?"1":"0"),t&&c(this,Qr)!==void 0&&(c(this,Qr).textContent="Tab backgrounded - actions throttled. Bring tab to front or use `reticle drive`.")}async beforeAct(t,n,r){let o=re.resolve(t);if(this.status(`${kd(n)} ${r}`),!(o instanceof HTMLElement)){await Vx(c(this,Xl));return}let i=o.getBoundingClientRect(),s=i.left+i.width/2,a=i.top+i.height/2;r2(c(this,Ma),s,a),o2(c(this,kp),i),await Vx(c(this,Xl)),(D.CLICK===n||D.DBLCLICK===n||D.SUBMIT===n)&&i2(c(this,We),s,a)}};Xl=new WeakMap,We=new WeakMap,Si=new WeakMap,Ma=new WeakMap,kp=new WeakMap,Ua=new WeakMap,Qr=new WeakMap,ql=new WeakMap,Jl=new WeakMap,Ts=new WeakMap,Ti=new WeakMap,Ha=new WeakMap,Ql=new WeakMap,eu=new WeakMap,Jn=new WeakMap,tu=new WeakMap,zp=new WeakMap,Fa=new WeakMap,Qn=new WeakMap,$o=new WeakMap,Dp=new WeakMap,tn=new WeakMap,nu=new WeakMap,Pp=new WeakMap,Mp=new WeakMap,Ba=new WeakMap,ko=new WeakMap,eo=new WeakMap,Up=new WeakMap,Ln=new WeakMap,vr=new WeakMap,to=new WeakMap,Hp=new WeakMap,xs=new WeakMap,Fp=new WeakMap,Nr=new WeakMap,zo=new WeakMap,er=new WeakMap,ru=new WeakMap,ou=new WeakMap,tr=new WeakMap,Pe=new WeakMap,iu=new WeakMap,Bp=new WeakMap,J=new WeakSet,S2=function(){if(!(c(this,vr)===void 0||0<c(this,Nr).length))for(let t of E2().slice(-c(this,Ln))){for(let n of T(this,J,Qx).call(this,t.actor,t.summary===!0)){let r=Pm(n,t.kind,t.text,t.ts,c(this,Ln),t.actor);t.result!==void 0&&r.result(t.result)}g(this,zo,c(this,Jn).call(this)-t.at),c(this,ko).push({at:t.at,kind:t.kind,text:t.text,...t.result===void 0?{}:{result:t.result}}),c(this,Nr).push(t)}},T2=function(t,n){var o;let r=t.agentPrompt(window.location.href);(o=navigator.clipboard)==null||o.writeText(r).catch(()=>{}),n.setAttribute("data-copied","1"),ue(()=>n.removeAttribute("data-copied"),CW),Tr().clearOnCopy&&t.clearAll()},Pa=function(){var n;let t=!c(this,Pe).isCollapsed()&&c(this,Pe).isAnnotateOn();(n=c(this,iu))==null||n.toggle(t),c(this,We)!==void 0&&lg(c(this,We),Tr(),t)},Xx=function(){var n,r,o;let t=(n=c(this,We))==null?void 0:n.querySelector("[data-reticle-dock]");t==null||t.setAttribute(gn,pi),(r=c(this,Ua))==null||r.setAttribute(gn,pi),c(this,Fa)===pa.SESSION&&((o=c(this,Si))==null||o.setAttribute(gn,pi))},x2=function(){c(this,tr).setState(Xe.ACTIVE),g(this,Ba,void 0),T(this,J,Xx).call(this),c(this,Qn).resetActivity(c(this,Jn).call(this)),T(this,J,qx).call(this)},A2=function(t){var o;let n=c(this,to);if(t!==void 0&&t.runId!==c(this,Hp)&&(g(this,Hp,t.runId),n!==void 0&&Dm(n)),n!==void 0&&n.childElementCount===0)for(let i of(o=t==null?void 0:t.lines)!=null?o:[])Pm(n,Ge.NARRATION,i,"",c(this,Ln),hn.HARNESS);let r=c(this,xs);g(this,xs,t==null?void 0:t.steps),t!==void 0?T(this,J,Ss).call(this,c(this,$o),!1):r!==void 0&&T(this,J,Ss).call(this,Br.READY,!0)},Ss=function(t,n){var i;let r=c(this,xs)===void 0?t:Br.harnessTesting(c(this,xs));c(this,Qr)!==void 0&&(c(this,Qr).textContent=r,c(this,Qr).removeAttribute("title"));let o=n?"idle":"active";c(this,ql)!==void 0&&c(this,ql).setAttribute("data-liveness",o),(i=c(this,We))==null||i.setAttribute(Qd,o),c(this,Jl)!==void 0&&(c(this,Jl).textContent=n?c(this,$o)!==""?c(this,$o):Br.READY:r)},qx=function(){c(this,tn)!==void 0&&Re(c(this,tn));let t=()=>{T(this,J,y2).call(this),g(this,tn,ue(t,c(this,tu)))};g(this,tn,ue(t,c(this,tu)))},y2=function(){if(!c(this,eo)||c(this,Qr)===void 0||this.state===Xe.ENDED)return;let t=c(this,Jn).call(this)-c(this,Qn).lastActivityMs();if(t>=c(this,nu)){T(this,J,w2).call(this,t);return}if(t<c(this,zp)||c(this,$o)===""||c(this,xs)!==void 0)return;if(hn.HARNESS===c(this,Dp)){T(this,J,Ss).call(this,Br.READY,!0);return}let n=Br.SINCE_LAST;T(this,J,Ss).call(this,`${Br.PLANNING_PREFIX}${Xd(t)}${n}`,!0),c(this,Ts)!==void 0&&(c(this,Ts).textContent=Xd(t))},w2=function(t){g(this,Ba,c(this,Jn).call(this)),c(this,tr).setState(Xe.ENDED,`${Br.STOPPED_PREFIX}${Xd(t)} quiet`),T(this,J,Ss).call(this,Br.STOPPED,!1),c(this,tn)!==void 0&&(Re(c(this,tn)),g(this,tn,void 0))},Jx=function(){g(this,ko,[]),g(this,Nr,[]),$p([]),g(this,Ql,{passes:0,fails:0}),c(this,vr)!==void 0&&Dm(c(this,vr)),c(this,to)!==void 0&&Dm(c(this,to)),T(this,J,Yl).call(this)},v2=function(){var t;(t=c(this,We))==null||t.setAttribute("data-reticle-hidden","1"),c(this,Pe).collapse()},N2=function(t){var n,r;(n=c(this,iu))==null||n.setAccent(dp(t.statusThemeId).active),t.showTally?T(this,J,Yl).call(this):(r=c(this,Ha))==null||r.setAttribute("hidden",""),T(this,J,Pa).call(this)},Qx=function(t,n){let r=c(this,vr),o=c(this,to);return hn.HARNESS!==t||o===void 0?r===void 0?[]:[r]:n&&r!==void 0?[r,o]:[o]},R2=function(t){c(this,Up)||Ge.HUMAN===t||(g(this,Up,!0),e2(Tr().autoOpenChat)&&c(this,Pe).openChat())},Yl=function(){var t;if(!Tr().showTally){(t=c(this,Ha))==null||t.setAttribute("hidden","");return}g(this,Ql,u2(c(this,Ha),c(this,ko),c(this,Ql)))},O2=function(){c(this,vr)!==void 0&&(zm(c(this,vr),c(this,Ln)),c(this,to)!==void 0&&zm(c(this,to),c(this,Ln)))}});var ot,L2,$2,k2,z2=y(()=>{"use strict";ot={NONE:"none",HUD:"hud",APP:"app",HUD_CHAT:"hud-chat",HUD_FLOWS:"hud-flows",HUD_ANNOTATE:"hud-annotate",HUD_IMPACT:"hud-impact",HUD_SETTINGS:"hud-settings"},L2=[{label:"Verify one flow",text:"verify the login flow with Reticle, and tell me the verdict"},{label:"Check what is proved",text:"/reticle"},{label:"Let it loose",text:"monkey-test the checkout flow with Reticle and tell me what breaks"}],$2=[{id:"connect",title:"Yayyy! It is connected",say:"That panel is Reticle. Seeing it is your proof the SDK is connected to your app.",why:"It only mounts on a connected session, so it cannot show up without one. Having the tools is not the same as being set up.",call:'reticle_session { action: "list" }',anchor:ot.HUD},{id:"look",title:"Look, without pixels",say:"Take a semantic snapshot. You get the controls and their refs, not pixels, so you can point at things by name.",why:"A ref is stable across snapshots, which is what lets you plan several steps before spending any of them.",call:'reticle_look { action: "page" }',anchor:ot.APP},{id:"declare",title:"Say it first",say:'Decide what should happen BEFORE you touch anything. "Clicking Pay makes the receipt appear" is a claim that can be wrong.',why:"This is the whole idea. A consequence named first is a check; the same sentence written after the fact is a rationalisation, and it is the difference between a verdict and a story.",call:'until: { signal: "order:placed" } // a consequence \u2014 not until: { ms: 500 }',anchor:ot.NONE},{id:"verdict",title:"Act, and prove it",say:"Act and prove in one call. The answer says verified yes / no / unknown, and `because` names the evidence that decided it.",why:'Only `reticle_act_and_wait` and `reticle_assert` produce a verdict. A drive that ends without one has no result, however many tools it used \u2014 and "unknown" is an honest answer, not a pass.',call:'reticle_act_and_wait { ref, action: "click", until: { signal: "order:placed" } }',anchor:ot.HUD}],k2=[{id:"hud-chat",title:"Agent Log",say:"Watch what your agent is doing in your app, as it happens, and which steps it proved.",anchor:ot.HUD_CHAT,tryIt:"Open it."},{id:"hud-flows",title:"Saved flows",say:"Every journey your agent verifies is saved here. Replay one with a click, with no agent in the loop.",anchor:ot.HUD_FLOWS,tryIt:"Open them."},{id:"hud-annotate",title:"Notes",say:"Open Notes, then click anywhere in your app to drop a numbered pin with a note. Hand the pins to your agent and it fixes them.",anchor:ot.HUD_ANNOTATE,tryIt:"Open Notes, then pin something in your app."},{id:"hud-impact",title:"What's the impact?",say:"Everything Reticle has done here. Every bug it caught, every metric.",anchor:ot.HUD_IMPACT,tryIt:"Take a look."},{id:"hud-settings",title:"Make it yours",say:"Change how Reticle looks and behaves.",anchor:ot.HUD_SETTINGS,tryIt:"Open it."}]});var eA=y(()=>{"use strict";z2()});function rA(){return[...tA.map($W),{index:LW,title:"Get Started",body:"Paste one of these into Claude Code, Cursor, Codex, or whatever you use.",anchor:ot.NONE,prompts:L2}]}function Gp(e){return e.split("&").join("&amp;").split("<").join("&lt;").split(">").join("&gt;").split('"').join("&quot;")}function kW(e){return Gp(e).replace(/`([^`]+)`/g,'<code class="reticle-tour-code">$1</code>')}function oA(e,t){let n=e+t;return n<0?0:n>Gg-1?Gg-1:n}function H2(e,t,n){let r=Math.max(0,e.left),o=Math.max(0,e.top),i=Math.min(t,e.left+e.width),s=Math.min(n,e.top+e.height);return[{left:0,top:0,width:t,height:o},{left:0,top:s,width:t,height:n-s},{left:0,top:o,width:r,height:s-o},{left:i,top:o,width:t-i,height:s-o}].filter(l=>l.width>0&&l.height>0)}function F2(e){let t=rA().map(s=>`<span class="reticle-tour-dot${s.index===e.index?" is-on":""}" aria-hidden="true"></span>`).join(""),n=e.tryIt===void 0?"":`<p class="reticle-tour-try" ${xi}="try">${Gp(e.tryIt)}</p>`,r=e.prompts===void 0?"":'<div class="reticle-tour-prompts">'+e.prompts.map((s,a)=>`<div class="reticle-tour-prompt" ${Vp}="${String(a)}"><span class="reticle-tour-prompt-label">${Gp(s.label)}</span><pre class="reticle-tour-prompt-text">${Gp(s.text)}</pre><button type="button" class="reticle-tour-copy" ${xi}="copy" ${Vp}="${String(a)}">${nA}</button></div>`).join("")+"</div>",o=e.index===0?"":`<button type="button" class="reticle-tour-back" ${xi}="back">Back</button>`,i=iA(e.index)?`<button type="button" class="reticle-tour-next" ${xi}="done">Done</button>`:`<button type="button" class="reticle-tour-next" ${xi}="next">Next</button>`;return`<div class="reticle-tour-card" role="dialog" aria-modal="false" aria-label="Reticle tour"><button type="button" class="reticle-tour-skip" ${xi}="skip" aria-label="Skip the tour">Skip</button><p class="reticle-tour-step">Step ${String(e.index+1)} of ${String(Gg)}</p><h2 class="reticle-tour-title">${Gp(e.title)}</h2><p class="reticle-tour-body">${kW(e.body)}</p>`+n+r+`<div class="reticle-tour-foot"><div class="reticle-tour-dots">${t}</div><div class="reticle-tour-nav">${o}${i}</div></div></div>`}var tA,LW,Gg,Te,xi,Vp,nA,D2,P2,M2,$W,U2,iA,B2,G2=y(()=>{"use strict";eA();tA=[...$2.slice(0,1),...k2],LW=tA.length,Gg=tA.length+1,Te="data-reticle-tour",xi="data-reticle-tour-target",Vp="data-reticle-tour-prompt",nA="Copy",D2="Copied",P2="Selected \u2014 press Ctrl/Cmd+C",M2=1600,$W=(e,t)=>{var n;return{index:t,title:e.title,body:e.say,anchor:(n=e.anchor)!=null?n:ot.NONE,...e.tryIt===void 0?{}:{tryIt:e.tryIt}}},U2=e=>e.tryIt!==void 0;iA=e=>e===Gg-1;B2=`
1736
+ ${$p.dockHtml(r,"",CT,mM,gM)}`,document.body.appendChild(n),g(this,Ye,n),g(this,Ai,(o=n.querySelector("[data-reticle-glow]"))!=null?o:void 0),g(this,Ua,(i=n.querySelector("[data-reticle-cursor]"))!=null?i:void 0),g(this,Mp,(s=n.querySelector("[data-reticle-ring]"))!=null?s:void 0),g(this,Ha,(a=n.querySelector("[data-reticle-hud]"))!=null?a:void 0),g(this,no,(l=n.querySelector(".reticle-act"))!=null?l:void 0),g(this,eu,(u=n.querySelector(".reticle-act-strip"))!=null?u:void 0),g(this,tu,(d=n.querySelector("[data-reticle-chat-pill-text]"))!=null?d:void 0),g(this,xs,(f=n.querySelector("[data-reticle-chat-pill-time]"))!=null?f:void 0),g(this,Rr,(m=n.querySelector(`[${CT}]`))!=null?m:void 0),g(this,oo,(h=n.querySelector(`[${Tg}]`))!=null?h:void 0),g(this,yi,(E=n.querySelector("[data-reticle-chip]"))!=null?E:void 0),g(this,Fa,(S=n.querySelector("[data-reticle-tally]"))!=null?S:void 0),c(this,Pe).mount(n),fg(n,Ar(),!1),c(this,Qn).setElements(c(this,Ai),c(this,Ua)),c(this,tr).mount(n,c(this,Ai)),c(this,jp).mount(n),c(this,su)!==void 0&&g(this,au,I2(document,n,c(this,su))),this.setMode(c(this,ru)),T(this,Q,z2).call(this),T(this,Q,Jl).call(this)}bindAnnotator(t){g(this,cu,t);let n=c(this,Ye);if(n===void 0)return;let r=n.querySelector(`[${jm}]`),o=n.querySelector(`[${Km}]`),i=n.querySelector(`[${f1}]`),s=n.querySelector(`[${Zm}]`),a=n.querySelector(`[${Wm}]`),l={};a instanceof HTMLElement&&(l.copyRow=a);let u=t.markCount;l.onCount=d=>{u===0&&d>0&&c(this,Pe).openView("annotations"),u=d},l.onMarksChange=d=>c(this,Pe).paintAnnotations(d),s instanceof HTMLElement&&s.addEventListener("click",d=>{d.stopPropagation(),T(this,Q,D2).call(this,t,s)}),r instanceof HTMLElement&&(l.markersBtn=r),o instanceof HTMLElement&&(l.clearBtn=o),i instanceof HTMLElement&&(l.countEl=i),t.attachChrome(l),t.setAccent(mp(Ar().statusThemeId).active),T(this,Q,Ma).call(this)}destroy(){var t,n;c(this,Qn).teardown(),c(this,tn)!==void 0&&Oe(c(this,tn)),g(this,tn,void 0),(t=c(this,au))==null||t.call(this),g(this,au,void 0),c(this,Pe).teardown(),c(this,tr).teardown(),g(this,ro,!1),g(this,Po,void 0),g(this,Rr,void 0),g(this,oo,void 0),g(this,Or,[]),Pp([]),(n=c(this,Ye))==null||n.remove(),document.querySelectorAll("style[data-reticle-overlay]").forEach(r=>r.remove()),g(this,Ye,void 0)}sessionStart(){var t,n;if(this.state===Qe.ENDED){T(this,Q,P2).call(this);return}c(this,ro)||($T===((t=c(this,Ye))==null?void 0:t.getAttribute(Gm))&&c(this,Ye).removeAttribute(Gm),g(this,ro,!0),(n=c(this,Bp))!=null||g(this,Bp,c(this,Jn).call(this)),g(this,Ga,void 0),T(this,Q,aA).call(this),c(this,Qn).resetActivity(c(this,Jn).call(this)),T(this,Q,cA).call(this),Qx()&&c(this,Pe).openChat())}showUnreachable(t,n){var o,i,s,a;if(c(this,ro))return;(o=c(this,Ye))==null||o.setAttribute(Gm,$T);let r=(i=c(this,Ye))==null?void 0:i.querySelector("[data-reticle-dock]");r==null||r.setAttribute(gn,mi),(s=c(this,Ha))==null||s.setAttribute(gn,mi),g(this,zo,$k),T(this,Q,Ts).call(this,c(this,zo),!0),(a=c(this,no))==null||a.setAttribute("title",gm(t,n)),Qx()&&c(this,Pe).openChat()}sessionEnd(){var n,r,o,i;if(!c(this,ro))return;g(this,ro,!1),c(this,tn)!==void 0&&(Oe(c(this,tn)),g(this,tn,void 0));let t=(n=c(this,Ye))==null?void 0:n.querySelector("[data-reticle-dock]");t==null||t.setAttribute(gn,is),(r=c(this,Ha))==null||r.setAttribute(gn,is),c(this,Pe).collapse(),c(this,Ba)===fa.SESSION&&((o=c(this,Ai))==null||o.setAttribute(gn,is),(i=c(this,Ai))==null||i.setAttribute(tp,Bm))}markActivity(){c(this,Qn).markActivity()}scheduleIdle(){c(this,Qn).scheduleIdle()}glowPhase(){return c(this,Qn).phase()}get mode(){return c(this,ru)}setMode(t){var n,r;if(g(this,ru,t),(n=c(this,Ye))==null||n.setAttribute("data-reticle-mode",t),c(this,yi)!==void 0){let o=qD[t];if(c(this,yi).setAttribute("data-mode",t),c(this,yi).replaceChildren(),o.length>0){let i=t===ct.READING?se.VIEW:t===ct.ACTING?se.POINTER:void 0;i!==void 0&&c(this,yi).appendChild(xo(i,ye.CHIP));let s=document.createElement("span");s.className="reticle-chip-label",s.textContent=o,c(this,yi).appendChild(s)}}t===ct.READING&&((r=c(this,Ua))==null||r.setAttribute(gn,is))}status(t){this.markActivity(),c(this,xs)!==void 0&&(c(this,xs).textContent=jr.NOW),g(this,zo,t),T(this,Q,Ts).call(this,t,!1)}placeHud(t,n){let r=c(this,Ye);if(r===void 0)return c(this,Kp)?[qO]:[];let o=[];if(Gn.REMOVED===t)return g(this,Kp,!0),this.destroy(),[t];Gn.HIDDEN===t&&r.setAttribute(ul,"1"),Gn.SHOWN===t&&r.removeAttribute(ul),t!==void 0&&o.push(t);let i=r.querySelector(`[${F}]`);if(n!==void 0&&i instanceof HTMLElement){if(rh.BOTTOM_RIGHT===n)ip(i);else{let s=hl(i),a=n.endsWith("left")?0:window.innerWidth,l=n.startsWith("top")?0:window.innerHeight,u=fl(a,l,s.width,s.height,window.innerWidth,window.innerHeight);as(i,u.left,u.top)}o.push(n),Wr(i,r)}return o}setIdleEndMs(t){Number.isFinite(t)&&g(this,iu,Math.max(u1,Math.floor(t)))}runState(){let t=g2({sessionId:c(this,Fp),state:this.state,startMs:c(this,Bp),endMs:c(this,Ga),now:c(this,Jn).call(this),runLog:c(this,Do)}),n=Ar();return n.outputDetail===Yr.MINIMAL?{session:t.session,url:t.url,state:t.state,startedMs:t.startedMs,durationMs:t.durationMs,counts:t.counts}:n.outputDetail===Yr.VERBOSE&&n.reactComponents?{...t,includeReactComponents:!0}:t}log(t,n,r,o,i=!1){var h;let s=c(this,Jn).call(this);if(c(this,Qn).markActivity(s),g(this,Hp,o),c(this,Rr)===void 0)return;let a=n.trim();if(a.length===0)return;(h=c(this,Po))!=null||g(this,Po,s);let l=r!==void 0?{at:s-c(this,Po),kind:t,text:a,result:r}:{at:s-c(this,Po),kind:t,text:a};for(c(this,Do).push(l);c(this,Do).length>c(this,$n);)c(this,Do).shift();let u=n1(s-c(this,Po)),d=T(this,Q,uA).call(this,o,i).map(E=>Fm(E,t,a,u,c(this,$n),o)),f={result:E=>d.forEach(S=>S.result(E))};r!==void 0&&f.result(r);let m={kind:t,text:a,ts:u,at:s-c(this,Po),...o===void 0?{}:{actor:o},...i?{summary:!0}:{},...r===void 0?{}:{result:r}};for(c(this,Or).push(m);c(this,Or).length>c(this,$n);)c(this,Or).shift();return Pp(c(this,Or)),T(this,Q,G2).call(this,t),c(this,Pe).isCollapsed()&&c(this,Pe).pulseFab(!0),T(this,Q,Jl).call(this),{result:E=>{f.result(E),l.result=E,m.result=E,Pp(c(this,Or)),T(this,Q,Jl).call(this)}}}narrate(t,n="info",r=hn.AGENT,o=!1){let i=n==="info"?t:`[${n}] ${t}`;return this.log(Ge.NARRATION,i,void 0,r,o)}setThrottled(t){var n;(n=c(this,Ye))==null||n.setAttribute(b1,t?"1":"0"),t&&c(this,no)!==void 0&&(c(this,no).textContent="Tab backgrounded - actions throttled. Bring tab to front or use `reticle drive`.")}async beforeAct(t,n,r){let o=re.resolve(t);if(this.status(`${Md(n)} ${r}`),!(o instanceof HTMLElement)){await tA(c(this,Ql));return}let i=o.getBoundingClientRect(),s=i.left+i.width/2,a=i.top+i.height/2;b2(c(this,Ua),s,a),_2(c(this,Mp),i),await tA(c(this,Ql)),(D.CLICK===n||D.DBLCLICK===n||D.SUBMIT===n)&&S2(c(this,Ye),s,a)}};Ql=new WeakMap,Ye=new WeakMap,Ai=new WeakMap,Ua=new WeakMap,Mp=new WeakMap,Ha=new WeakMap,no=new WeakMap,eu=new WeakMap,tu=new WeakMap,xs=new WeakMap,yi=new WeakMap,Fa=new WeakMap,nu=new WeakMap,ru=new WeakMap,Jn=new WeakMap,ou=new WeakMap,Up=new WeakMap,Ba=new WeakMap,Qn=new WeakMap,zo=new WeakMap,Hp=new WeakMap,tn=new WeakMap,iu=new WeakMap,Fp=new WeakMap,Bp=new WeakMap,Ga=new WeakMap,Do=new WeakMap,ro=new WeakMap,Gp=new WeakMap,$n=new WeakMap,Rr=new WeakMap,oo=new WeakMap,Vp=new WeakMap,As=new WeakMap,jp=new WeakMap,Or=new WeakMap,Po=new WeakMap,er=new WeakMap,su=new WeakMap,au=new WeakMap,tr=new WeakMap,Pe=new WeakMap,cu=new WeakMap,Kp=new WeakMap,Q=new WeakSet,z2=function(){if(!(c(this,Rr)===void 0||0<c(this,Or).length))for(let t of L2().slice(-c(this,$n))){for(let n of T(this,Q,uA).call(this,t.actor,t.summary===!0)){let r=Fm(n,t.kind,t.text,t.ts,c(this,$n),t.actor);t.result!==void 0&&r.result(t.result)}g(this,Po,c(this,Jn).call(this)-t.at),c(this,Do).push({at:t.at,kind:t.kind,text:t.text,...t.result===void 0?{}:{result:t.result}}),c(this,Or).push(t)}},D2=function(t,n){var o;let r=t.agentPrompt(window.location.href);(o=navigator.clipboard)==null||o.writeText(r).catch(()=>{}),n.setAttribute("data-copied","1"),de(()=>n.removeAttribute("data-copied"),hY),Ar().clearOnCopy&&t.clearAll()},Ma=function(){var n;let t=!c(this,Pe).isCollapsed()&&c(this,Pe).isAnnotateOn();(n=c(this,cu))==null||n.toggle(t),c(this,Ye)!==void 0&&fg(c(this,Ye),Ar(),t)},aA=function(){var n,r,o;let t=(n=c(this,Ye))==null?void 0:n.querySelector("[data-reticle-dock]");t==null||t.setAttribute(gn,mi),(r=c(this,Ha))==null||r.setAttribute(gn,mi),c(this,Ba)===fa.SESSION&&((o=c(this,Ai))==null||o.setAttribute(gn,mi))},P2=function(){c(this,tr).setState(Qe.ACTIVE),g(this,Ga,void 0),T(this,Q,aA).call(this),c(this,Qn).resetActivity(c(this,Jn).call(this)),T(this,Q,cA).call(this)},M2=function(t){var o;let n=c(this,oo);if(t!==void 0&&t.runId!==c(this,Vp)&&(g(this,Vp,t.runId),n!==void 0&&Hm(n)),n!==void 0&&n.childElementCount===0)for(let i of(o=t==null?void 0:t.lines)!=null?o:[])Fm(n,Ge.NARRATION,i,"",c(this,$n),hn.HARNESS);let r=c(this,As);g(this,As,t==null?void 0:t.steps),t!==void 0?T(this,Q,Ts).call(this,c(this,zo),!1):r!==void 0&&T(this,Q,Ts).call(this,jr.READY,!0)},Ts=function(t,n){var i;let r=c(this,As)===void 0?t:jr.harnessTesting(c(this,As));c(this,no)!==void 0&&(c(this,no).textContent=r,c(this,no).removeAttribute("title"));let o=n?"idle":"active";c(this,eu)!==void 0&&c(this,eu).setAttribute("data-liveness",o),(i=c(this,Ye))==null||i.setAttribute(rp,o),c(this,tu)!==void 0&&(c(this,tu).textContent=n?c(this,zo)!==""?c(this,zo):jr.READY:r)},cA=function(){c(this,tn)!==void 0&&Oe(c(this,tn));let t=()=>{T(this,Q,U2).call(this),g(this,tn,de(t,c(this,ou)))};g(this,tn,de(t,c(this,ou)))},U2=function(){if(!c(this,ro)||c(this,no)===void 0||this.state===Qe.ENDED)return;let t=c(this,Jn).call(this)-c(this,Qn).lastActivityMs();if(t>=c(this,iu)){T(this,Q,H2).call(this,t);return}if(t<c(this,Up)||c(this,zo)===""||c(this,As)!==void 0)return;if(hn.HARNESS===c(this,Hp)){T(this,Q,Ts).call(this,jr.READY,!0);return}let n=jr.SINCE_LAST;T(this,Q,Ts).call(this,`${jr.PLANNING_PREFIX}${ep(t)}${n}`,!0),c(this,xs)!==void 0&&(c(this,xs).textContent=ep(t))},H2=function(t){g(this,Ga,c(this,Jn).call(this)),c(this,tr).setState(Qe.ENDED,`${jr.STOPPED_PREFIX}${ep(t)} quiet`),T(this,Q,Ts).call(this,jr.STOPPED,!1),c(this,tn)!==void 0&&(Oe(c(this,tn)),g(this,tn,void 0))},lA=function(){g(this,Do,[]),g(this,Or,[]),Pp([]),g(this,nu,{passes:0,fails:0}),c(this,Rr)!==void 0&&Hm(c(this,Rr)),c(this,oo)!==void 0&&Hm(c(this,oo)),T(this,Q,Jl).call(this)},F2=function(){var t;(t=c(this,Ye))==null||t.setAttribute("data-reticle-hidden","1"),c(this,Pe).collapse()},B2=function(t){var n,r;(n=c(this,cu))==null||n.setAccent(mp(t.statusThemeId).active),t.showTally?T(this,Q,Jl).call(this):(r=c(this,Fa))==null||r.setAttribute("hidden",""),T(this,Q,Ma).call(this)},uA=function(t,n){let r=c(this,Rr),o=c(this,oo);return hn.HARNESS!==t||o===void 0?r===void 0?[]:[r]:n&&r!==void 0?[r,o]:[o]},G2=function(t){c(this,Gp)||Ge.HUMAN===t||(g(this,Gp,!0),m2(Ar().autoOpenChat)&&c(this,Pe).openChat())},Jl=function(){var t;if(!Ar().showTally){(t=c(this,Fa))==null||t.setAttribute("hidden","");return}g(this,nu,w2(c(this,Fa),c(this,Do),c(this,nu)))},V2=function(){c(this,Rr)!==void 0&&(Um(c(this,Rr),c(this,$n)),c(this,oo)!==void 0&&Um(c(this,oo),c(this,$n)))}});var st,Z2,W2,Y2,X2=y(()=>{"use strict";st={NONE:"none",HUD:"hud",APP:"app",HUD_CHAT:"hud-chat",HUD_FLOWS:"hud-flows",HUD_ANNOTATE:"hud-annotate",HUD_IMPACT:"hud-impact",HUD_SETTINGS:"hud-settings"},Z2=[{label:"Verify one flow",text:"verify the login flow with Reticle, and tell me the verdict"},{label:"Check what is proved",text:"/reticle"},{label:"Let it loose",text:"monkey-test the checkout flow with Reticle and tell me what breaks"}],W2=[{id:"connect",title:"Yayyy! It is connected",say:"That panel is Reticle. Seeing it is your proof the SDK is connected to your app.",why:"It only mounts on a connected session, so it cannot show up without one. Having the tools is not the same as being set up.",call:'reticle_session { action: "list" }',anchor:st.HUD},{id:"look",title:"Look, without pixels",say:"Take a semantic snapshot. You get the controls and their refs, not pixels, so you can point at things by name.",why:"A ref is stable across snapshots, which is what lets you plan several steps before spending any of them.",call:'reticle_look { action: "page" }',anchor:st.APP},{id:"declare",title:"Say it first",say:'Decide what should happen BEFORE you touch anything. "Clicking Pay makes the receipt appear" is a claim that can be wrong.',why:"This is the whole idea. A consequence named first is a check; the same sentence written after the fact is a rationalisation, and it is the difference between a verdict and a story.",call:'until: { signal: "order:placed" } // a consequence \u2014 not until: { ms: 500 }',anchor:st.NONE},{id:"verdict",title:"Act, and prove it",say:"Act and prove in one call. The answer says verified yes / no / unknown, and `because` names the evidence that decided it.",why:'Only `reticle_act_and_wait` and `reticle_assert` produce a verdict. A drive that ends without one has no result, however many tools it used \u2014 and "unknown" is an honest answer, not a pass.',call:'reticle_act_and_wait { ref, action: "click", until: { signal: "order:placed" } }',anchor:st.HUD}],Y2=[{id:"hud-chat",title:"Agent Log",say:"Watch what your agent is doing in your app, as it happens, and which steps it proved.",anchor:st.HUD_CHAT,tryIt:"Open it."},{id:"hud-flows",title:"Saved flows",say:"Every journey your agent verifies is saved here. Replay one with a click, with no agent in the loop.",anchor:st.HUD_FLOWS,tryIt:"Open them."},{id:"hud-annotate",title:"Notes",say:"Open Notes, then click anywhere in your app to drop a numbered pin with a note. Hand the pins to your agent and it fixes them.",anchor:st.HUD_ANNOTATE,tryIt:"Open Notes, then pin something in your app."},{id:"hud-impact",title:"What's the impact?",say:"Everything Reticle has done here. Every bug it caught, every metric.",anchor:st.HUD_IMPACT,tryIt:"Take a look."},{id:"hud-settings",title:"Make it yours",say:"Change how Reticle looks and behaves.",anchor:st.HUD_SETTINGS,tryIt:"Open it."}]});var dA=y(()=>{"use strict";X2()});function hA(){return[...pA.map(gY),{index:mY,title:"Get Started",body:"Paste one of these into Claude Code, Cursor, Codex, or whatever you use.",anchor:st.NONE,prompts:Z2}]}function Zp(e){return e.split("&").join("&amp;").split("<").join("&lt;").split(">").join("&gt;").split('"').join("&quot;")}function EY(e){return Zp(e).replace(/`([^`]+)`/g,'<code class="reticle-tour-code">$1</code>')}function mA(e,t){let n=e+t;return n<0?0:n>Zg-1?Zg-1:n}function t5(e,t,n){let r=Math.max(0,e.left),o=Math.max(0,e.top),i=Math.min(t,e.left+e.width),s=Math.min(n,e.top+e.height);return[{left:0,top:0,width:t,height:o},{left:0,top:s,width:t,height:n-s},{left:0,top:o,width:r,height:s-o},{left:i,top:o,width:t-i,height:s-o}].filter(l=>l.width>0&&l.height>0)}function n5(e){let t=hA().map(s=>`<span class="reticle-tour-dot${s.index===e.index?" is-on":""}" aria-hidden="true"></span>`).join(""),n=e.tryIt===void 0?"":`<p class="reticle-tour-try" ${wi}="try">${Zp(e.tryIt)}</p>`,r=e.prompts===void 0?"":'<div class="reticle-tour-prompts">'+e.prompts.map((s,a)=>`<div class="reticle-tour-prompt" ${Wp}="${String(a)}"><span class="reticle-tour-prompt-label">${Zp(s.label)}</span><pre class="reticle-tour-prompt-text">${Zp(s.text)}</pre><button type="button" class="reticle-tour-copy" ${wi}="copy" ${Wp}="${String(a)}">${fA}</button></div>`).join("")+"</div>",o=e.index===0?"":`<button type="button" class="reticle-tour-back" ${wi}="back">Back</button>`,i=gA(e.index)?`<button type="button" class="reticle-tour-next" ${wi}="done">Done</button>`:`<button type="button" class="reticle-tour-next" ${wi}="next">Next</button>`;return`<div class="reticle-tour-card" role="dialog" aria-modal="false" aria-label="Reticle tour"><button type="button" class="reticle-tour-skip" ${wi}="skip" aria-label="Skip the tour">Skip</button><p class="reticle-tour-step">Step ${String(e.index+1)} of ${String(Zg)}</p><h2 class="reticle-tour-title">${Zp(e.title)}</h2><p class="reticle-tour-body">${EY(e.body)}</p>`+n+r+`<div class="reticle-tour-foot"><div class="reticle-tour-dots">${t}</div><div class="reticle-tour-nav">${o}${i}</div></div></div>`}var pA,mY,Zg,Te,wi,Wp,fA,q2,J2,Q2,gY,e5,gA,r5,o5=y(()=>{"use strict";dA();pA=[...W2.slice(0,1),...Y2],mY=pA.length,Zg=pA.length+1,Te="data-reticle-tour",wi="data-reticle-tour-target",Wp="data-reticle-tour-prompt",fA="Copy",q2="Copied",J2="Selected \u2014 press Ctrl/Cmd+C",Q2=1600,gY=(e,t)=>{var n;return{index:t,title:e.title,body:e.say,anchor:(n=e.anchor)!=null?n:st.NONE,...e.tryIt===void 0?{}:{tryIt:e.tryIt}}},e5=e=>e.tryIt!==void 0;gA=e=>e===Zg-1;r5=`
1737
1737
  [${Te}]{position:fixed;inset:0;z-index:${String(2147483630)};pointer-events:none;
1738
1738
  font:13px/1.55 ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,sans-serif;}
1739
1739
  [${Te}] .reticle-tour-scrim{position:absolute;inset:0;background:rgba(6,8,14,.55);
@@ -1821,16 +1821,16 @@ ${OM}`});function UM(){let e=Ie(se.REMOVE,Ae.MIN);return`<div ${B} class="reticl
1821
1821
  @media (prefers-reduced-motion:reduce){
1822
1822
  [${Te}] .reticle-tour-ring{transition:none;}
1823
1823
  }
1824
- `});var Z2={};Ya(Z2,{HUD_CONTROL_SELECTORS:()=>V2,TOUR_SEEN_KEY_PREFIX:()=>bh,isLastSlide:()=>iA,mountTour:()=>HW,openedByReticle:()=>j2,safeLocalStorage:()=>FW,tourAlreadySeen:()=>K2,tourSeenKey:()=>sA});function PW(e,t){var s;let n=Number.POSITIVE_INFINITY,r=Number.POSITIVE_INFINITY,o=Number.NEGATIVE_INFINITY,i=Number.NEGATIVE_INFINITY;for(let a of t){let l=(s=e.querySelector(a))==null?void 0:s.getBoundingClientRect();l===void 0||l.width<=0||l.height<=0||(n=Math.min(n,l.left),r=Math.min(r,l.top),o=Math.max(o,l.left+l.width),i=Math.max(i,l.top+l.height))}if(o!==Number.NEGATIVE_INFINITY)return{left:n,top:r,width:o-n,height:i-r}}function MW(e,t){var r;if(ot.HUD===t)return PW(e,DW);let n=V2[t];if(n!==void 0){let o=(r=e.querySelector(n))==null?void 0:r.getBoundingClientRect();return o===void 0?void 0:o}if(ot.APP===t)for(let o of zW){let i=e.querySelector(o);if(i===null)continue;let s=i.getBoundingClientRect();if(s.width>0)return s}}function j2(e){if(e===void 0||e==="")return!1;let t=new URLSearchParams(e.startsWith("?")?e.slice(1):e);return t.has(rr.OPENED)||t.has(rr.SESSION)||t.has(rr.PROJECT)}function K2(e,t){if(e===void 0)return!0;try{return e.getItem(sA(t))!==null}catch{return!0}}function UW(e,t){try{e==null||e.setItem(sA(t),"1")}catch{}}function HW(e){var A;if(e.isDriving()||j2(e.search)||((A=e.navigator)==null?void 0:A.webdriver)===!0||K2(e.storage,e.projectId))return;let t=e.document,n=t.createElement("style");n.setAttribute(Te,""),n.textContent=B2,t.head.appendChild(n);let r=t.createElement("div");r.setAttribute(Te,"");let o=rA(),i=0,s=!0,a=()=>{},l=()=>{},u=()=>{s&&(s=!1,a(),l(),r.remove(),n.remove())},d=()=>{s&&(UW(e.storage,e.projectId),u())},f=()=>{e.isDriving()&&u()},m=()=>{var N,O,k,j;let v=o[i];if(v!==void 0&&(r.innerHTML=`<div class="reticle-tour-scrim"></div>${F2(v)}`,ot.NONE!==v.anchor)){let Y=MW(t,v.anchor);if(Y!==void 0&&Y.width>0){let X=ot.APP===v.anchor,G=t.createElement("div");G.className=X?"reticle-tour-ring is-region":"reticle-tour-ring";let ee=X?-2:6;if(G.style.left=`${String(Math.round(Y.left-ee))}px`,G.style.top=`${String(Math.round(Y.top-ee))}px`,G.style.width=`${String(Math.round(Y.width+ee*2))}px`,G.style.height=`${String(Math.round(Y.height+ee*2))}px`,r.appendChild(G),X||(N=r.querySelector(".reticle-tour-scrim"))==null||N.classList.add("is-clear"),U2(v)){G.classList.add("is-live"),(O=r.querySelector(".reticle-tour-scrim"))==null||O.remove();let be=t.defaultView;for(let me of H2({left:Y.left-ee,top:Y.top-ee,width:Y.width+ee*2,height:Y.height+ee*2},(k=be==null?void 0:be.innerWidth)!=null?k:t.documentElement.clientWidth,(j=be==null?void 0:be.innerHeight)!=null?j:t.documentElement.clientHeight)){let it=t.createElement("div");it.className="reticle-tour-blocker",it.style.left=`${String(Math.round(me.left))}px`,it.style.top=`${String(Math.round(me.top))}px`,it.style.width=`${String(Math.round(me.width))}px`,it.style.height=`${String(Math.round(me.height))}px`,r.appendChild(it)}}}}},h=v=>{var G,ee;let N=o[i],O=Number(v.getAttribute(Vp)),k=(G=N==null?void 0:N.prompts)==null?void 0:G[O];if(k===void 0)return;let j=(be,me)=>{var it;v.textContent=be,v.classList.add(me),(it=t.defaultView)==null||it.setTimeout(()=>{v.textContent=nA,v.classList.remove(me)},M2)},Y=be=>{var it;if(be){j(D2,"is-done");return}let me=r.querySelector(`.reticle-tour-prompt[${Vp}="${String(O)}"] .reticle-tour-prompt-text`);me!==null&&((it=e.select)==null||it.call(e,me)),j(P2,"is-manual")},X=(ee=e.copy)==null?void 0:ee.call(e,k.text);if(X===void 0){Y(!1);return}if(typeof X=="boolean"){Y(X);return}X.then(Y).catch(()=>{Y(!1)})};r.addEventListener("click",v=>{let N=v.target;if(!(N instanceof Element))return;let O=N.closest(`[${xi}]`);if(O===null)return;let k=O.getAttribute(xi);if(k===null)return;if(v.preventDefault(),v.stopPropagation(),k==="skip"||k==="done"){d();return}if(k==="copy"){h(O);return}let j=oA(i,k==="back"?-1:1);j!==i&&(i=j,m())});let E=v=>{if(!s||gh(t))return;let N=v.key==="ArrowRight"?1:v.key==="ArrowLeft"?-1:0;if(v.key==="Escape"){v.preventDefault(),d();return}if(N===0)return;let O=oA(i,N);O!==i&&(v.preventDefault(),i=O,m())};t.addEventListener("keydown",E),a=()=>{t.removeEventListener("keydown",E)},m(),t.body.appendChild(r);let _=t.querySelector("[data-reticle-overlay]");if(_!==null){let v=new MutationObserver(f);v.observe(_,{attributes:!0,attributeFilter:["data-reticle-mode"]}),l=()=>v.disconnect(),f()}return{destroy:d,isOpen:()=>s}}function FW(){try{return window.localStorage}catch{return}}var zW,DW,V2,sA,W2=y(()=>{"use strict";G2();eA();M();nt();po();zW=["main","#root","#app"],DW=["[data-reticle-hud]","[data-reticle-chat-panel]"];V2={[ot.HUD_CHAT]:"[data-reticle-chat-toggle]",[ot.HUD_FLOWS]:'[data-reticle-chat-view-btn="flows"]',[ot.HUD_ANNOTATE]:'[data-reticle-chat-view-btn="annotations"]',[ot.HUD_IMPACT]:"[data-reticle-chat-impact]",[ot.HUD_SETTINGS]:"[data-reticle-settings-btn]"};sA=e=>`${bh}${e}`});var tY={};Ya(tY,{Annotator:()=>da,RefRegistry:()=>nd,Reticle:()=>du,SESSION_AUTO:()=>Fu,adapterNames:()=>hd,buildSnapshot:()=>Lh,canvasChartData:()=>wC,commitAndSignal:()=>E5,createReticleEmitter:()=>g5,describe:()=>ho,elementHasHoverHandlers:()=>Rh,executeAction:()=>Nd,executeSequence:()=>im,getAccessibleName:()=>we,getCapabilities:()=>ji,getRole:()=>Le,getStates:()=>Jo,hasCapabilities:()=>Mh,identifyComponent:()=>dr,inspectChart:()=>xh,installAnnotator:()=>yD,isVisible:()=>Je,jotaiStore:()=>c5,markAdapterSource:()=>kh,matchQuery:()=>_d,mobxStore:()=>d5,piniaStore:()=>h5,pushStore:()=>m5,readComponentState:()=>Nh,readStores:()=>TL,readStoresWithTruncation:()=>Ed,recoilStore:()=>p5,refs:()=>re,registerAdapter:()=>HC,registerCapabilities:()=>Ic,registerReticleDomain:()=>b5,registerStore:()=>bL,resolveMarkAnchor:()=>Ud,reticle:()=>pu,runQuery:()=>Vh,setCapabilitiesListener:()=>Ph,setIgnoreSelectors:()=>pC,sourceOwner:()=>AL,storeNames:()=>Vi,svelteStore:()=>f5,tanstackQueryStore:()=>a5,trackShortTimers:()=>eY,unregisterStore:()=>_L,valtioStore:()=>u5,xstateStore:()=>l5});nt();M();Wo();function hC(e,t){t(Lu,{delta:1});let n=()=>{t(Lu,{delta:-1})};return e.then(n,n),e}var E4=1e3;function mC(e,t=E4){let n=ke(window,"setTimeout"),r=ke(window,"clearTimeout"),o=n.bind(window),i=r.bind(window),s=new Set,a=l=>{s.delete(l)&&e(Lu,{delta:-1})};return window.setTimeout=((l,u=0,...d)=>{if(typeof l!="function"||u>t)return Reflect.apply(n,window,[l,u,...d]);e(Lu,{delta:1});let f=o(()=>{a(f),l(...d)},u);return s.add(f),f}),window.clearTimeout=(l=>{l!==void 0&&a(l),i(l)}),()=>{window.setTimeout=n,window.clearTimeout=r}}M();function oe(e){try{e()}catch{}}function Zt(e){try{return e()}catch{return}}Wo();M();function b4(){return{pathname:location.pathname,search:location.search,hash:location.hash,href:location.href}}var gC=[];function EC(e){gC=e.map(t=>({pattern:t,parts:t.split("/").filter(Boolean)}))}function _4(){var t,n;let e=(n=(t=globalThis.next)==null?void 0:t.router)==null?void 0:n.pathname;if(!(typeof e!="string"||!e.startsWith("/")))return e.replace(/\[\.\.\.[^\]]+\]/g,"*").replace(/\[([^\]]+)\]/g,":$1")}function S4(e){var r;let t=e.split("/").filter(Boolean),n;for(let{pattern:o,parts:i}of gC){let s=i.at(-1)==="*",a=s?i.slice(0,-1):i;if((s?t.length<a.length:t.length!==a.length)||!a.every((u,d)=>u.startsWith(":")||u===t[d]))continue;let l=i.filter(u=>u.startsWith(":")||u==="*").length;(n===void 0||l<n.params)&&(n={pattern:o,params:l})}return(r=n==null?void 0:n.pattern)!=null?r:_4()}function bC(e){let t=new AbortController,n=ke(history,"pushState"),r=ke(history,"replaceState"),o=n.bind(history),i=r.bind(history),s=location.href,a=(f,m)=>{oe(()=>{let h=b4();if(h.href===f)return;s=h.href;let E=S4(h.pathname);e(w.ROUTE_CHANGE,{from:cr(f),to:cr(h.href),pathname:h.pathname,...E===void 0?{}:{pattern:E},search:cr(h.search),hash:cr(h.hash),[m_]:m})})},l=(f,m,h)=>{let E=location.href;o(f,m,h!=null?h:null),a(E,Wu.PUSH)},u=(f,m,h)=>{let E=location.href;i(f,m,h!=null?h:null),a(E,Wu.REPLACE)};history.pushState=l,history.replaceState=u;let d=()=>{a(s,Wu.POP)};return window.addEventListener("popstate",d,{signal:t.signal}),window.addEventListener("hashchange",d,{signal:t.signal}),()=>{history.pushState===l&&(history.pushState=n),history.replaceState===u&&(history.replaceState=r),t.abort()}}M();Et();dn();var H4=new Set(["submit","button","reset","image"]);function F4(e){return ut(e)&&e.isContentEditable||e instanceof HTMLTextAreaElement?!0:e instanceof HTMLInputElement?!H4.has(e.type.toLowerCase()):!1}var B4="A";function OC(e){if(B4!==e.tagName)return;let t=e.getAttribute("href");return t===null||cI(t)?void 0:t}function IC(e){var o,i,s,a,l,u;let t=OC(e);if(t!==void 0)return t;let n=e.closest("form"),r=F4(e)?["",""]:[(o=e.textContent)!=null?o:"",(i=e.getAttribute("value"))!=null?i:""];return[ju(we(e)),ju(r.join(" ")),ju((s=e.getAttribute("title"))!=null?s:""),ju((a=e.getAttribute("aria-label"))!=null?a:""),(l=e.getAttribute("href"))!=null?l:"",(u=n==null?void 0:n.getAttribute("action"))!=null?u:""].join(" ")}var G4='button[type="submit"], input[type="submit"], button:not([type]):not([type=""])';function CC(e){var n;let t=(n=e.closest("form"))==null?void 0:n.querySelector(G4);return ut(t)?t:null}function vh(e){let t=OC(e);return t!==void 0?lI(t):aI(IC(e),Le(e))}var dd;function Y_(e){dd=e}function LC(e){if(dd!==void 0)for(let t of e){if(t===null)continue;let n=pI(IC(t),Le(t));if(n!==void 0&&!dd.includes(n))throw new Error(l_(n))}}function $C(e){var n,r,o,i,s;if(dd===void 0||dd.includes(Tt.PAY))return;let t={autocomplete:(n=e.getAttribute("autocomplete"))!=null?n:void 0,name:(r=e.getAttribute("name"))!=null?r:void 0,id:(o=e.getAttribute("id"))!=null?o:void 0,inputMode:(i=e.getAttribute("inputmode"))!=null?i:void 0,label:`${we(e)} ${(s=e.getAttribute("placeholder"))!=null?s:""}`};if(dI(t))throw new Error(l_(Tt.PAY))}M();Ot();var kC=(e,t)=>Array.from(e.querySelectorAll(t)).some(n=>n.closest(Vu)===null);function zC(e){return[...kC(e,`[${fc}]`)?[Gs.SOURCE]:[],...kC(e,Vn())?[Gs.TESTID]:[]]}function DC(e){return e.buildPlugin||0<e.adapters.length||e.markers.includes(Gs.SOURCE)?[]:[Qf]}M();po();var PC=At.SESSION;function MC(e,t,n){var a;let r=()=>{try{let l=t==null?void 0:t.getItem(PC);return l!=null&&l.length>0?l:void 0}catch{return}},o=l=>{try{t==null||t.setItem(PC,l)}catch{}},i=e!==void 0&&e.length>0?e:void 0,s=(a=i!=null?i:r())!=null?a:n();return o(s),s}gt();var V4="vite:afterUpdate",j4=3,K4="no longer resolves to an element",Z4="the code changed underneath it";function X_(e){return e!==null&&typeof e=="object"?e:void 0}function W4(e){var t;return typeof((t=X_(e))==null?void 0:t.on)=="function"}function Y4(e){var r,o;let t=(r=X_(e))==null?void 0:r.updates;if(!Array.isArray(t))return[];let n=[];for(let i of t){let s=(o=X_(i))==null?void 0:o.path;typeof s=="string"&&s.length>0&&!n.includes(s)&&n.push(s)}return n}var pd,wc,vc,q_=class{constructor(t){x(this,pd,0);x(this,wc,[]);x(this,vc);g(this,vc,t)}get current(){return c(this,pd)}observe(t){W4(t)&&t.on(V4,n=>this.applied(Y4(n)))}applied(t){g(this,pd,c(this,pd)+1),g(this,wc,t.slice(0,j4)),c(this,vc).markEdited()}staleRefMessage(t){let n=`ref '${kr(t)}' ${K4}`;if(!c(this,vc).mintedBeforeLastEdit(t))return n;let r=c(this,wc).length===0?"the page hot-updated":`${c(this,wc).join(", ")} hot-updated`;return`${n} \u2014 ${r} after this ref was taken, so ${Z4} and the framework replaced the node. Query again for a fresh ref: this is your own edit landing, not the app failing.`}};pd=new WeakMap,wc=new WeakMap,vc=new WeakMap;var fd=new q_(re);M();M();Yo();dn();Et();uo();gt();Ot();Qo();gt();Et();nt();var Q_={CLIPPED:"clipped",OVERLAP:"overlap",CONTRAST:"contrast"},eS=20,X4=300,q4=60,FC=1,BC=.25,J4=4.5,Q4=3,ej=24,tj=18.66,nj=700,rj='button, a[href], input:not([type="hidden"]), select, textarea, [role="button"], [role="link"], [role="tab"], [role="menuitem"]',GC=/rect\(\s*0(px)?[\s,]+0(px)?[\s,]+0(px)?[\s,]+0(px)?\s*\)|inset\(\s*50%/,VC=4,jC=e=>{let t=e.getBoundingClientRect();if(t.width<VC||t.height<VC)return null;let n=getComputedStyle(e);return n.visibility==="hidden"||n.display==="none"||n.opacity==="0"||GC.test(n.clip)||GC.test(n.clipPath)?null:t},KC=e=>{var t;return(we(e)||((t=e.textContent)!=null?t:"")).replace(/\s+/g," ").trim().slice(0,q4)},oj=e=>[...e.childNodes].filter(t=>Node.TEXT_NODE===t.nodeType).map(t=>{var n;return(n=t.textContent)!=null?n:""}).join("").trim(),ZC=new Set(["hidden","clip"]),ij=e=>{let t=getComputedStyle(e),n=e.scrollWidth>e.clientWidth+FC&&ZC.has(t.overflowX),r=e.scrollHeight>e.clientHeight+FC&&ZC.has(t.overflowY);return t.textOverflow==="ellipsis"||t.getPropertyValue("-webkit-line-clamp")!==""&&t.getPropertyValue("-webkit-line-clamp")!=="none"||!n&&!r?null:n?{detail:`${String(e.scrollWidth)}px of text in a ${String(e.clientWidth)}px box, cut with no ellipsis`,value:e.scrollWidth,bound:e.clientWidth}:{detail:`${String(e.scrollHeight)}px of text in a ${String(e.clientHeight)}px box, cut with no line clamp`,value:e.scrollHeight,bound:e.clientHeight}},sj=/rgba?\(\s*([\d.]+)[\s,]+([\d.]+)[\s,]+([\d.]+)(?:[\s,/]+([\d.]+%?))?\s*\)/,XC=e=>{let t=sj.exec(e);if(t===null)return null;let n=t[4],r=1;return n!==void 0&&(r=n.endsWith("%")?Number(n.slice(0,-1))/100:Number(n)),[Number(t[1]),Number(t[2]),Number(t[3]),r]},WC=([e,t,n])=>{let r=o=>{let i=o/255;return i<=.03928?i/12.92:((i+.055)/1.055)**2.4};return .2126*r(e)+.7152*r(t)+.0722*r(n)},qC=(e,t)=>{let n=e[3];return[e[0]*n+t[0]*(1-n),e[1]*n+t[1]*(1-n),e[2]*n+t[2]*(1-n),1]},aj=e=>{let t=[];for(let n=e;n!==null;n=n.parentElement){let r=getComputedStyle(n);if(r.backgroundImage!=="none"&&r.backgroundImage!=="")return null;let o=XC(r.backgroundColor);if(o!==null&&o[3]>0&&(t.push(o),o[3]===1))break}return t.reduceRight((n,r)=>qC(r,n),[255,255,255,1])},cj=e=>{let t=getComputedStyle(e),n=XC(t.color),r=aj(e);if(n===null||r===null)return null;let o=qC(n,r),[i,s]=[WC(o),WC(r)].sort((d,f)=>f-d),a=Number.parseFloat(t.fontSize),l=Number.parseInt(t.fontWeight,10),u=a>=ej||a>=tj&&l>=nj;return{ratio:(i+.05)/(s+.05),min:u?Q4:J4}},JC=(e,t,...n)=>{if(typeof document.elementFromPoint!="function")return!0;let r=document.elementFromPoint(e,t);return r!==null&&n.some(o=>o===r||o.contains(r))},Gi=2,YC=(e,t)=>[[t.left+t.width/2,t.top+t.height/2],[t.left+Gi,t.top+Gi],[t.right-Gi,t.top+Gi],[t.left+Gi,t.bottom-Gi],[t.right-Gi,t.bottom-Gi]].some(([n=0,r=0])=>JC(n,r,e)),lj=(e,t)=>{let n=Math.min(e.right,t.right)-Math.max(e.left,t.left),r=Math.min(e.bottom,t.bottom)-Math.max(e.top,t.top);return n<=0||r<=0?0:n*r/Math.min(e.width*e.height,t.width*t.height)};function QC(e=document.body){let t=[],n=(o,i,s)=>{t.length<eS&&t.push({kind:o,ref:re.refFor(i),what:KC(i),...s})};for(let o of e.querySelectorAll("*")){if(t.length>=eS)break;if(Mt(o)||oj(o)==="")continue;let i=jC(o);if(i===null||!JC(i.left+i.width/2,i.top+i.height/2,o))continue;let s=ij(o);s!==null&&n(Q_.CLIPPED,o,s);let a=cj(o);a!==null&&a.ratio<a.min&&n(Q_.CONTRAST,o,{detail:`contrast ${a.ratio.toFixed(2)}:1, under ${String(a.min)}:1`,value:Math.round(a.ratio*100)/100,bound:a.min})}let r=[...e.querySelectorAll(rj)].filter(o=>!Mt(o)).slice(0,X4).flatMap(o=>{let i=jC(o);return i===null?[]:[{el:o,rect:i}]});for(let[o,i]of r.entries())for(let s of r.slice(o+1)){if(t.length>=eS)return t;if(i.el.contains(s.el)||s.el.contains(i.el))continue;let a=lj(i.rect,s.rect);a>=BC&&YC(i.el,i.rect)&&YC(s.el,s.rect)&&n(Q_.OVERLAP,i.el,{detail:`drawn over "${KC(s.el)}" (${re.refFor(s.el)})`,value:Math.round(a*100)/100,bound:BC})}return t}md();nt();var Rc=new Set(["button","link","textbox","searchbox","checkbox","radio","combobox","listbox","slider","spinbutton","switch","tab","menuitem","option"]),uj=new Set(["script","style","noscript","template","head","meta","link"]),dj=new Set(["alert","status"]);function nL(e,t){if(dj.has(t))return!0;let n=e.getAttribute("aria-live");return n!==null&&n!=="off"}var eL=80;function pj(e){let t=rL(e),n=(t.own?t.text:"").replace(/\s+/g," ").trim();return n.length>eL?`${n.slice(0,eL)}\u2026`:n}function rL(e){var r,o;let t="",n=!1;for(let i of e.childNodes)if(i.nodeType===3)t+=(r=i.textContent)!=null?r:"",n||(n=0<((o=i.textContent)!=null?o:"").trim().length);else if(wn(i)&&iL(i)){let s=rL(i);t+=s.text,n||(n=s.own)}else wn(i)&&oL(i)&&Rc.has(Le(i))&&(t+=we(i));return{text:t,own:n}}function oL(e){let t=e.ownerDocument.defaultView,n=e.parentElement;if(t===null||n===null)return!1;let r=t.getComputedStyle(n).display;return r.includes("flex")||r.includes("grid")?!1:t.getComputedStyle(e).display==="inline"}function iL(e){if(aL(e)||!oL(e))return!1;let t=Le(e);return!Rc.has(t)&&!nL(e,t)&&we(e).length===0}var fj=50;function sL(e){return e.getAttribute("aria-hidden")==="true"?!0:e instanceof HTMLElement&&e.hidden}function aL(e){return uj.has(e.tagName.toLowerCase())||Mt(e)?!0:sL(e)}function hj(e){let t=Jo(e).filter(n=>n===Se.DISABLED||n===Se.CHECKED||n===Se.EXPANDED||n===Se.PRESSED||n===Se.FOCUSED);return t.length>0?` [${t.join(",")}]`:""}function mj(e,t,n,r,o,i="",s=!1){let a=" ".repeat(t),l=W_(e),u=r,d=u.length>0?` "${u}"`:"",f=Rc.has(n)||u.length>0?` (ref=${re.refFor(e)})`:"",m=l!==void 0&&l.length>0?` [value="${l}"]`:"",h=o.length>0?` [${o}]`:"",E=i.length>0?` [text="${i}"]`:"",_=s?Ne(e):null,A=s?dr(e):null,v=_===null?A==null?void 0:A.componentStack[0]:void 0,N=A==null?void 0:A.source,O="";_!==null?O=` [testid=${_}]`:v!==void 0&&(O=` [component=${v}]`);let k=`${O}${N===void 0?"":` [src=${N.file}:${String(N.line)}]`}`;return`${a}- ${n}${d}${f}${m}${E}${h}${hj(e)}${k}`}function gj(e,t){return`${" ".repeat(e)}- text "${t}"`}function Ej(e){if(e===null)return"";let t=e.display;if(t==="grid"||t==="inline-grid"){let n=e.gridTemplateColumns;return n!==""&&n!=="none"?`grid-cols:${n}`:"grid"}return""}var cL=e=>e.hasAttribute("data-aria-hidden")&&e.getAttribute("aria-hidden")==="true";function tL(e,t){for(let n of e){if(t.unread.length>=fj){t.unreadOverflow=!0;return}t.unread.push(re.refFor(n))}}function bj(e){var r,o;let t=[...e.children],n=(r=e.shadowRoot)!=null?r:Ks(e);if(n!==null&&t.push(...n.children),fh(e))try{let i=(o=e.contentDocument)==null?void 0:o.body;i!=null&&t.push(...i.children)}catch{}return t}function tS(e,t,n,r){if(!(n.throughOverlay===!0&&cL(e)&&!Mt(e)&&!(e instanceof HTMLElement&&e.hidden))&&aL(e)){sL(e)&&(n.hiddenSkipped+=1);return}let i=e.ownerDocument.defaultView,s=i!==null?i.getComputedStyle(e):null;if(s!==null&&s.display==="none"){n.hiddenSkipped+=1;return}if(s!==null&&s.display==="inline"&&!r&&iL(e)){Ch(e,t,n,r);return}let a=Le(e),l=we(e),u=Rc.has(a),d=r||nL(e,a),f=n.mode===lc.INTERACTIVE&&!d,m=!f&&l.length===0?pj(e):"",h=f?"":Ej(s),E=u,_=E||a!=="generic"||l.length>0||m.length>0||h.length>0,A=f?E:_;f&&!A&&_&&(n.leanSkipped+=1),A?(n.nodes+=1,n.lines.push(a==="generic"&&m.length>0&&h.length===0?gj(t,m):mj(e,t,a,l,h,m,n.ids===!0)),Ch(e,t+1,n,d)):Ch(e,t,n,d)}function Ch(e,t,n,r=!1){let o=bj(e);if(t>n.maxDepth){o.length>0&&(n.truncated=!0,tL([e],n));return}for(let i=0;i<o.length;i+=1){if(n.nodes>=n.maxNodes){n.truncated=!0,tL(o.slice(i),n);return}let s=o[i];s!==void 0&&tS(s,t,n,r)}}function _j(e){let t=e.querySelectorAll('[role="dialog"], dialog[open], [aria-modal="true"]'),n=[];for(let r of t)Rt(r)||Je(r)&&n.push(we(r)||"(unnamed dialog)");return n}var Sj='[role="dialog"], [role="alertdialog"], dialog[open], [aria-modal="true"]';function Tj(e){if(e!==document.body)return;let t=document.body.querySelectorAll('[role="dialog"], dialog[open], [aria-modal="true"]'),n,r;for(let s of t)if(!Rt(s)){if(Je(s)){n=s;break}r!=null||(r=s)}if(n!=null||(n=r),n===void 0)return;let o=n,i=Array.from(document.body.children).filter(s=>!s.contains(o));if(i.length!==0&&i.every(s=>s.getAttribute("aria-hidden")==="true"))return"the rest of the page is aria-hidden behind an open overlay (a focus-trap modal), so this snapshot shows only the overlay. If it will not close its cleanup may be stuck on a throttled tab: dismiss the overlay, or snapshot with { scope } inside it."}function xj(e){let t=_j(e),n=Tj(e);return{route:Ih(),title:document.title,...t.length>0?{visibleDialogs:t}:{},...n!==void 0?{overlayHidingPage:n}:{}}}function Lh(e={}){var l,u,d,f;let t=(l=e.mode)!=null?l:lc.FULL,n=(u=e.scope)==null?void 0:u.trim(),r=document.body;if(n!==void 0&&n!==""&&(r=re.resolve(n),r===null))try{r=document.querySelector(n)}catch{}let o=r===null,i=r!=null?r:document.body,s=xj(i);if(o)return{tree:"",status:s,nodes:0,truncated:!1,scopeMissing:!0};if(t===lc.STATUS)return{tree:"",status:s,nodes:0,truncated:!1};let a={lines:[],nodes:0,leanSkipped:0,hiddenSkipped:0,truncated:!1,mode:t,maxNodes:(d=e.maxNodes)!=null?d:400,maxDepth:(f=e.maxDepth)!=null?f:20,unread:[],unreadOverflow:!1,...e.ids===!0?{ids:!0}:{}};if(e.includeRoot===!0?tS(i,0,a,!1):Ch(i,0,a),a.nodes===0&&i===document.body){a.throughOverlay=!0;for(let m of Array.from(i.children))cL(m)&&m.querySelector(Sj)!==null&&tS(m,0,a,!1);a.throughOverlay=!1}return{tree:a.lines.join(`
1825
- `),status:s,nodes:a.nodes,truncated:a.truncated,...a.nodes===0?{domElements:i.querySelectorAll("*").length}:{},...a.leanSkipped>0?{leanSkipped:a.leanSkipped}:{},...a.hiddenSkipped>0?{hiddenSkipped:a.hiddenSkipped}:{},...a.unread.length>0?{unread:a.unread}:{},...a.unreadOverflow?{unreadOverflow:!0}:{},...e.audit===!0?{audit:QC(i)}:{}}}z_();M();dn();Yo();Et();uo();nt();ur();Ki();gt();Ot();Ot();function RL(e){let t=Ij(e);if(t===void 0)return;let n=e.ownerDocument.querySelectorAll(t);return n.length===1&&n[0]===e?t:void 0}function Ij(e){let t=Ne(e);if(t!==null&&0<t.length){let r=t.replace(/\\/g,"\\\\").replace(/"/g,'\\"');return`[${Fi()}="${r}"]`}let n=e.getAttribute("id");if(n!==null&&/^[A-Za-z_][A-Za-z0-9_-]*$/.test(n))return`#${n}`}Yo();function Uh(e){return e.replace(/\s+/g," ").trim().normalize("NFC")}var Cj=/[\u2018\u2019]/g,Lj=/[\u201c\u201d]/g,$j=/[\u2013\u2014]/g;function Hh(e){return e.replace(Cj,"'").replace(Lj,'"').replace($j,"-")}function pr(e){return Hh(Uh(e))}function Zi(e,t){return pr(e).toLowerCase().includes(pr(t).toLowerCase())}function Cc(e,t,n){return t.matchCase!==!0?Zi(e,n):pr(e).includes(pr(n))}function $L(e,t){return pr(e)===pr(t)}var lS={uppercase:e=>e.toUpperCase(),lowercase:e=>e.toLowerCase(),capitalize:e=>e.replace(/(^|\s)(\p{L})/gu,(t,n,r)=>n+r.toUpperCase())};function kL(e,t){var r,o,i;let n=(o=(r=e.ownerDocument.defaultView)==null?void 0:r.getComputedStyle(e).textTransform)!=null?o:"";return(i=lS[n])==null?void 0:i.call(lS,t)}var kj=1.5,zj=.05,Dj=[255,255,255,1];function OL(e){let t=/^rgba?\(\s*([\d.]+)[\s,]+([\d.]+)[\s,]+([\d.]+)(?:[\s,/]+([\d.]+))?\s*\)$/.exec(e);if(t!==null)return[Number(t[1]),Number(t[2]),Number(t[3]),t[4]===void 0?1:Number(t[4])]}function IL(e,t){let n=e[3],r=(o,i)=>o*n+i*(1-n);return[r(e[0],t[0]),r(e[1],t[1]),r(e[2],t[2]),1]}function uS(e){let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4}function CL(e){return .2126*uS(e[0])+.7152*uS(e[1])+.0722*uS(e[2])}function Pj(e,t){let n=CL(e),r=CL(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function LL(e){return`rgb(${[e[0],e[1],e[2]].map(t=>String(Math.round(t))).join(", ")})`}function Mj(e){let t=Number.parseFloat(e.getPropertyValue("-webkit-text-stroke-width"));return/\dpx/.test(e.textShadow)||t>0}function Uj(e){let t=e.ownerDocument.defaultView;if(t===null)return;let n=t.getComputedStyle(e),r=OL(n.color);if(r===void 0||Mj(n))return;let o=1,i=[],s=!1;for(let d=e;d!==null;d=Pi(d)){let f=t.getComputedStyle(d),m=Number.parseFloat(f.opacity);if(o*=Number.isNaN(m)?1:m,s)continue;if(f.backgroundImage!==""&&f.backgroundImage!=="none")return;let h=OL(f.backgroundColor);if(h===void 0)return;h[3]>0&&i.push(h),s=h[3]>=1}if(o<zj)return`the composed opacity is ${o.toFixed(2)}`;let a=i.reduceRight((d,f)=>IL(f,d),Dj),l=IL(r,a),u=Pj(l,a);if(!(u>=kj))return`text ${LL(l)} on ${LL(a)}: contrast ${u.toFixed(2)}:1`}function zL(e){let t=e.map(Uj);return t.length>0&&t.every(n=>n!==void 0)?t[0]:void 0}md();M();dn();Et();uo();Qo();Ot();var GL=fc,Hj=2e3,Fj=()=>`[${GL}], ${Vn()}, button, a, input, select, textarea, [role]`;function jn(e){return[...Node.ELEMENT_NODE===e.nodeType?[e]:[],...Array.from(e.querySelectorAll("*"))]}var Bj=["script","style","template","noscript"];function dS(e){return Bj.includes(e.tagName.toLowerCase())}function Gj(e){if(He(e)){let t=e.type.toLowerCase();if(t==="submit"||t==="button"||t==="reset")return e.value}return dS(e)?"":Array.from(e.childNodes).filter(t=>Node.TEXT_NODE===t.nodeType).map(t=>{var n;return(n=t.textContent)!=null?n:""}).join("")}function Vj(e){if(He(e)||vn(e)||$r(e))return!0;let t=e.tagName.toLowerCase();return t==="button"||t==="meter"||t==="output"||t==="progress"||e.hasAttribute("aria-label")||e.hasAttribute("aria-labelledby")}function jj(e,t){let n=`${t.file}:${t.line}:`.replace(/\\/g,"\\\\").replace(/"/g,'\\"');try{return Array.from(e.querySelectorAll(`[${GL}^="${n}"]`))}catch{return[]}}function Kj(e,t){let n=[],r=0;for(let o of Array.from(e.querySelectorAll(Fj()))){if(r>=Hj)break;r+=1;let i=dr(o);i!==null&&i.componentStack[0]===t&&n.push(o)}return n}function DL(e,t){if(t.source!==void 0){let n=jj(e,t.source);if(n.length>0)return n}return t.component!==void 0&&t.component.length>0?Kj(e,t.component):[]}function Zj(e,t){return e===t||t==="textbox"&&e==="searchbox"}var Wj="option",Yj="option",Xj="select",PL=1;function pS(e){if(Yj!==e.localName)return!1;let t=e.closest(Xj);return $r(t)?Je(t)?qj(t):!0:!1}function qj(e){let t=e.getBoundingClientRect();return t.width>0&&t.height>0&&t.width<=PL&&t.height<=PL}function Jj(e,t){if(Wj!==e)return t;let n=t.filter(r=>!pS(r));return n.length===t.length?t:n}function Fh(e,t,n){let r=jn(e).filter(o=>Zj(Le(o),t)&&(n===void 0||$L(we(o),n)));return Jj(t,r)}function ML(e,t,n){return jn(e).filter(r=>{let o=Gj(r);if(Cc(o,n,t))return!0;if(n.matchCase!==!0||!Zi(o,t))return!1;let i=kL(r,o);return i!==void 0&&Cc(i,n,t)})}function UL(e,t){let n=pr(t).toLowerCase(),r=[],o=[];for(let i of jn(e)){if(!Vj(i))continue;let s=pr(we(i)).toLowerCase();s.includes(n)&&(s===n?r:o).push(i)}return r.length>0?r:o}function HL(e,t){return jn(e).filter(n=>{let r=n.getAttribute("placeholder");return r!==null&&Zi(r,t)})}function FL(e,t){return jn(e).filter(n=>Ne(n)===t)}function BL(e,t){return jn(e).filter(n=>{let r=n.getAttribute("alt");return r!==null&&Zi(r,t)})}function fS(e,t){var o;let n=t.by,r=t.value;if(n!==void 0&&r!==void 0)switch(n){case at.ROLE:return Fh(e,r,t.name);case at.TEXT:return ML(e,r,t);case at.LABEL:return UL(e,r);case at.PLACEHOLDER:return HL(e,r);case at.TESTID:return FL(e,r);case at.ALT:return BL(e,r);case at.COMPONENT:return DL(e,{...t,component:(o=t.component)!=null?o:r});default:throw new Error(`unsupported query strategy '${String(n)}' - use one of: ${Object.values(at).join(", ")}`)}return t.component!==void 0||t.source!==void 0?DL(e,t):t.role!==void 0?Fh(e,t.role,t.name):t.text!==void 0?ML(e,t.text,t):t.label!==void 0?UL(e,t.label):t.placeholder!==void 0?HL(e,t.placeholder):t.testid!==void 0?FL(e,t.testid):t.alt!==void 0?BL(e,t.alt):[]}var Qj=12;function bd(e,t){var i;if(dS(e)||td(e))return"";let n=Je(e,t),r=e6(e),o="";for(let s of Array.from(e.childNodes))if(Node.TEXT_NODE===s.nodeType&&n)o+=(i=s.textContent)!=null?i:"";else if(wn(s)){let a=bd(s,t);o+=r||t6(s)?` ${a} `:a}return o}function e6(e){var n,r;let t=(r=(n=e.ownerDocument.defaultView)==null?void 0:n.getComputedStyle(e).display)!=null?r:"";return t.includes("flex")||t.includes("grid")}function t6(e){var n,r;let t=(r=(n=e.ownerDocument.defaultView)==null?void 0:n.getComputedStyle(e).display)!=null?r:"inline";return!t.startsWith("inline")&&t!=="contents"}function Gh(e){if(e===void 0)return{container:document.body,scopeMissing:!1};let t=re.resolve(e);if(Mi(t))return{container:t,scopeMissing:!1};try{let n=document.querySelector(e);if(Mi(n))return{container:n,scopeMissing:!1}}catch{}return{container:null,scopeMissing:!0}}function n6(e){var t,n;try{return(n=(t=e.contentDocument)==null?void 0:t.body)!=null?n:null}catch{return null}}var r6=3;function o6(e){let t=[],n=(r,o)=>{var i;for(let s of r.querySelectorAll("*")){let a=(i=s.shadowRoot)!=null?i:Ks(s);if(a!==null){t.push(a),n(a,o);continue}if(o>=r6||!fh(s))continue;let l=n6(s);l!==null&&(t.push(l),n(l,o+1))}};return n(e,0),t}function jL(e){let{container:t,scopeMissing:n}=Gh(e.scope);if(t===null)return{candidates:[],scopeMissing:!0};if(e.self===!0)return e.scope===void 0?{candidates:[],scopeMissing:n}:e.text!==void 0&&!Cc(bd(t,new Map),e,e.text)?{candidates:[],scopeMissing:n}:{candidates:Mt(t)?[]:[t],scopeMissing:n};let r=new Set,o=[],i=Bh(e)===void 0?Mt:td,s=a=>{for(let l of a)r.has(l)||i(l)||(r.add(l),o.push(l))};s(fS(t,e));for(let a of o6(t))s(fS(a,e));return{candidates:o,scopeMissing:n}}var i6=512,s6=12;function a6(e,t){let n={};for(let r of t.slice(0,s6)){let o=e.getAttribute(r);o!==null&&(n[r]=St(r)?ve:o.slice(0,i6))}return Object.keys(n).length>0?n:void 0}function c6(e,t,n){return Se.IN_VIEWPORT===t?U_(e,n):Jo(e,Je(e,n)).includes(t)}var VL=Z.MAX_COLLECTION_ITEMS;function _d(e,t,n=VL,r=!0,o=!0){let i=jL(e),s=i.scopeMissing,a=r&&f6(e)?Bh(e):void 0,l=i.candidates.length===0?Gh(e.scope).container:null,u=l===null||a===void 0?void 0:KL(l,a,e),d=u===void 0?i.candidates:[u],f=new Map,m=t===void 0?d:d.filter(O=>c6(O,t,f)),h=e.attrs,E=m.slice(0,Math.max(0,Math.min(n,VL))),_=E.length>1||Se.IN_VIEWPORT===t,A=E.map(O=>{let k=ho(O,f);if(_&&U_(O,f)&&!k.states.includes(Se.IN_VIEWPORT)&&(k={...k,states:[...k.states,Se.IN_VIEWPORT]}),h===void 0||h.length===0)return k;let j=a6(O,h);return j===void 0?k:{...k,attrs:j}}),v=fC(m),N=Bh(e)===void 0?void 0:zL(E);return{matched:m.length>0,count:m.length,elements:A,...s?{scopeMissing:!0}:{},...v===void 0?{}:{coveredBy:v},...N===void 0?{}:{unreadable:N},...m.length===0?{hint:ZL(e,t,o)}:{}}}function l6(e){let t=e.getAttribute("aria-labelledby");if(t===null)return;let n=t.split(/\s+/).map(r=>{var o,i,s;return r.length>0&&(s=(i=(o=e.ownerDocument.getElementById(r))==null?void 0:o.textContent)==null?void 0:i.trim())!=null?s:""}).filter(r=>r.length>0).join(" ");return n.length>0?n:void 0}function u6(e){var o,i,s,a,l,u,d,f;let t=(o=Gh(e.scope).container)!=null?o:document.body,n=[],r=["list","listbox","grid","table","tree","treegrid","dialog","alertdialog","navigation","main","banner","form","search","menu","menubar","tablist"];for(let m of r){let h=Fh(t,m,void 0);for(let E of h){if(Rt(E))continue;let _=(a=(s=(i=E.getAttribute("aria-label"))!=null?i:l6(E))!=null?s:Ne(E))!=null?a:void 0,A=E.querySelectorAll("[role]"),v=[];for(let O of Array.from(A)){if(v.length>=3)break;let k=O.getAttribute("role"),j=(f=(d=(l=O.getAttribute("aria-label"))!=null?l:Ne(O))!=null?d:(u=O.textContent)==null?void 0:u.trim().slice(0,40))!=null?f:"";k!==null&&j.length>0&&v.push(`${k}[${j}]`)}let N={role:m,childCount:A.length,sample:v};if(_!==void 0&&_.length>0&&(N.name=_),n.push(N),n.length>=10)return n}}return n}function KL(e,t,n){let r,o=-1,i=new Map;for(let s of jn(e)){if(Mt(s)||!Cc(bd(s,i),n,t))continue;let a=0;for(let l=s.parentElement;l!==null;l=l.parentElement)a++;a>o&&(r=s,o=a)}return r}function d6(e,t){let n=pr(t).toLowerCase();if(n.length===0)return;let r=new Map;for(let o of jn(e)){if(Mt(o))continue;let i=Uh(bd(o,r)),s=Hh(i).toLowerCase().indexOf(n);if(s!==-1)return i.slice(s,s+n.length)}}var p6=new Set(["text","matchCase","scope","by","value"]);function f6(e){return(e.by===void 0||at.TEXT===e.by)&&Object.keys(e).every(t=>p6.has(t))}function Bh(e){return e.text!==void 0?e.text:at.TEXT===e.by?e.value:void 0}var h6=5;function m6(e,t){let n=at.ROLE===t.by?t.value:t.role,r=t.name;if(n===void 0||r===void 0||r.length===0)return[];let o=pr(r).toLowerCase();if(o.length===0)return[];let i=[];for(let s of jn(e)){if(Mt(s)||Le(s)!==n)continue;let a=Uh(we(s));if(a.length===0)continue;let l=Hh(a).toLowerCase();if(!(!l.includes(o)&&!o.includes(l))&&(i.includes(a)||i.push(a),i.length>=h6))break}return i}function g6(e,t){if(at.TESTID!==t.by||t.value===void 0)return;let n=Fi();for(let r of[Us,...AO]){if(r===n)continue;if(jn(e).some(i=>i.getAttribute(r)===t.value&&!Mt(i)))return r}}function E6(e,t){var o;let n=!1;for(let i of jn(e))if(!Mt(i)&&eC(i)&&Zi((o=i.textContent)!=null?o:"",t)){n=!0;break}if(!n)return!1;let r=new Map;for(let i of jn(e))if(!Mt(i)&&tC(i)&&Zi(bd(i,r),t))return!1;return!0}function ZL(e,t,n=!0){var E;let r=(E=Gh(e.scope).container)!=null?E:document.body,o=r.querySelectorAll(Vn()),i=[],s=new Set;for(let _ of Array.from(o)){if(Mt(_))continue;let A=Ne(_);A===null||A.length===0||s.has(A)||(s.add(A),i.length<Qj&&i.push(A))}let a=NL(),l=i.some(_=>a.includes(_)),d={route:Ih(!1),presentTestids:i,...s.size>i.length?{presentTestidsTotal:s.size}:{},presentRegions:u6(e),knownEmptyState:l},f=Bh(e);if(f!==void 0){let _=KL(r,f,e);if(_!==void 0){let A=ho(_),v=RL(_);d.splitText=v===void 0?A:{...A,selector:v}}else if(e.matchCase===!0){let A=d6(r,f);A!==void 0&&(d.caseMiss=A)}}n&&f!==void 0&&d.splitText===void 0&&(t===void 0||Se.VISIBLE===t||Se.IN_VIEWPORT===t)&&E6(r,f)&&(d.ariaHiddenMatch=!0);let m=m6(r,e);m.length>0&&(d.nameNearMiss=m);let h=g6(r,e);return h!==void 0&&(d.testidFoundUnder=h),d}function hS(e){return jL(e).candidates}function Vh(e,t){let n=_d(e,void 0,t,!1),r=n.scopeMissing===!0?{scopeMissing:!0}:{};return n.elements.length===0?{elements:n.elements,count:n.count,hint:ZL(e),...r}:{elements:n.elements,count:n.count,...r}}M();nt();Lc();gt();Wo();dn();var b6=/\b(current|new)-password\b/,_6=/Chrome|Chromium|Edg\/|Firefox|Gecko\//;function gS(e,t=navigator.userAgent){var r,o,i;return!(e instanceof HTMLInputElement)||!(e.type.toLowerCase()==="password"||b6.test((r=e.getAttribute("autocomplete"))!=null?r:""))||_6.test(t)?!1:600<=Number((i=(o=/AppleWebKit\/(\d+)/.exec(t))==null?void 0:o[1])!=null?i:0)}function Kh(e,t){let n=Z0(e),r=n===void 0?void 0:k0(n);r!==void 0?r.call(e,t):e.value=t;let o=e.dispatchEvent(new Event("input",{bubbles:!0,cancelable:!0}));return e.dispatchEvent(new Event("change",{bubbles:!0})),!o}function S6(e){let t=e.getAttribute("contenteditable");if(ut(e)&&e.isContentEditable||t!==null&&t!=="false"||e.getAttribute("role")==="textbox")return!0;if(!("editContext"in e))return!1;let n=e;return n.editContext!==null&&n.editContext!==void 0}function ES(e,t){if(S6(e))throw new Error(`cannot ${t} a contenteditable or EditContext editor; use press or an input`)}function bS(e,t){if(e.disabled)throw new Error(`cannot ${t} a disabled <${e.tagName.toLowerCase()}> \u2014 a user could not edit it, so forcing the value would put the app in a state nobody can reach`);if(e.readOnly)throw new Error(`cannot ${t} a readonly <${e.tagName.toLowerCase()}> \u2014 a user could not edit it, so forcing the value would put the app in a state nobody can reach`)}Et();uo();gt();Et();nt();uo();dt();var T6=30,x6="option";function t$(e){return we(e).trim()}function A6(e){var i,s;let t=e.ownerDocument,r=((s=(i=e.getAttribute("aria-controls"))!=null?i:e.getAttribute("aria-owns"))!=null?s:"").split(/\s+/).filter(a=>0<a.length).map(a=>t.getElementById(a)).filter(a=>a!==null);return(0<r.length?r:[t]).flatMap(a=>Array.from(a.querySelectorAll(`[role="${x6}"]`))).filter(a=>!lr(a)&&Je(a))}async function y6(e){for(let t=0;t<T6;t+=1){let n=A6(e);if(0<n.length)return n;await mo()}return[]}function w6(e,t){let n=t.trim();return t$(e)===n||e.getAttribute("data-value")===t||e.getAttribute("value")===t}async function n$(e,t,n,r){let o=e.getAttribute("aria-expanded")!=="true";o&&await n(e);let i=await y6(e),s=i.filter(u=>w6(u,t)),[a]=s,l=i.length===0?r:v6(s,i,t);if(a===void 0||l!==void 0)throw o&&await n(e),new Error(l!=null?l:"no option");return(await n(a)).prevented}function v6(e,t,n){let[r]=e;if(r===void 0)return`no option '${kr(n)}' \u2014 available: ${t.map(t$).join(", ")}`;if(1<e.length)return`${e.length} options match '${kr(n)}' \u2014 name one by its exact label`;if(r.getAttribute("aria-disabled")==="true")return`cannot select a disabled option '${kr(n)}' \u2014 a real user could not, so neither will Reticle`}Qo();dn();dt();Ot();M();Et();var r$=160,N6=150,R6="checkbox",O6="radio",Sd;function Yh(e){return e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement||e instanceof HTMLSelectElement}function i$(e){return e instanceof HTMLInputElement&&(R6===e.type||O6===e.type)}function TS(e){return i$(e)?{value:e.value,checked:e.checked}:{value:e.value}}function I6(e,t){return e.checked!==void 0||t.checked!==void 0?e.checked!==t.checked:e.value!==t.value}function o$(e){return e.length>r$?`${e.slice(0,r$)}\u2026`:e}function C6(e){let t=Ne(e);if(t!==null&&t.length>0)return t;if(e.name.length>0)return e.name;let n=we(e);if(n.length>0)return n;let r=e.getAttribute("id");return r!==null&&r.length>0?r:e.tagName.toLowerCase()}function s$(e,t,n,r){let o=pn(e),i={[Pt.FIELD]:C6(e),[Pt.KIND]:t,[Pt.LENGTH]:n.value.length};return n.checked!==void 0&&(i[Pt.CHECKED]=n.checked),(r==null?void 0:r.checked)!==void 0&&(i[Pt.PREVIOUS_CHECKED]=r.checked),o?(i[Pt.REDACTED]=!0,i):(i[Pt.VALUE]=o$(n.value),r!==void 0&&r.checked===void 0&&(i[Pt.PREVIOUS]=o$(r.value)),i)}function L6(e){return i$(e)?"checked":"value"}function $6(e,t){for(let n=Object.getPrototypeOf(e);n!==null;){let r=Object.getOwnPropertyDescriptor(n,t);if(r!==void 0)return r;n=Object.getPrototypeOf(n)}}function k6(e,t){var u;let n=Object.getOwnPropertyDescriptor(e,t),r=n!=null?n:$6(e,t),o=r===void 0?void 0:Reflect.get(r,"get"),i=r===void 0?void 0:Reflect.get(r,"set"),s=!1;if(!(typeof o=="function"&&typeof i=="function")||(n==null?void 0:n.configurable)===!1)return{stop:()=>{},written:()=>s};Object.defineProperty(e,t,{configurable:!0,enumerable:(u=r==null?void 0:r.enumerable)!=null?u:!1,get(){return Reflect.apply(o,this,[])},set(d){s=!0,Reflect.apply(i,this,[d])}});let l=!1;return{stop:()=>{l||(l=!0,n===void 0?Reflect.deleteProperty(e,t):Object.defineProperty(e,t,n))},written:()=>s}}function a$(e){if(!(!Yh(e)||e instanceof HTMLSelectElement))return{before:TS(e),...k6(e,L6(e))}}function c$(e,t){let n=Sd;if(t===void 0||(t.stop(),n===void 0||!Yh(e)||!e.isConnected||!t.written()))return;let r=t.before;if(pn(e)&&r.checked===void 0)return;let o=TS(e);I6(r,o)&&n(w.FIELD_CHANGE,s$(e,Yu.SETTLED,o,r))}function l$(e){let t=new AbortController,{signal:n}=t,r=Sd;Sd=e;let o=new Map,i=(u,d)=>{e(w.FIELD_CHANGE,s$(u,d,TS(u)))},s=u=>{let d=o.get(u);d!==void 0&&clearTimeout(d),o.delete(u)},a=u=>{let d=u.target;Yh(d)&&(s(d),o.set(d,setTimeout(()=>{o.delete(d),i(d,Yu.INPUT)},N6)))},l=u=>{let d=u.target;Yh(d)&&(s(d),i(d,Yu.CHANGE))};return document.addEventListener("input",a,{signal:n,capture:!0}),document.addEventListener("change",l,{signal:n,capture:!0}),()=>{for(let u of o.values())clearTimeout(u);o.clear(),Sd===e&&(Sd=r),t.abort()}}nt();Et();var xS=200,u$=" | ",z6=3,D6=/\p{L}/u;function P6(e){return D6.test(e)}var M6=3;function U6(e){return e instanceof Element&&e.querySelectorAll("*").length>M6}var $c,Td,Wi,AS,yS,Xh=class{constructor(){x(this,Wi);x(this,$c,new Set);x(this,Td,0)}collect(t){for(let n of t){if(T(this,Wi,AS).call(this))return;if(n.type==="characterData"){T(this,Wi,yS).call(this,n.target.textContent,n.target.parentElement);continue}for(let r of n.addedNodes){if(T(this,Wi,AS).call(this))return;if(U6(r))continue;let o=z6===r.nodeType?r.parentElement:H6(r);T(this,Wi,yS).call(this,r.textContent,o)}}}effect(t){let n=[...c(this,$c)].filter(o=>o!==t);if(n.length===0)return{};let r=n.join(u$);return{appeared:r.length>xS?`${r.slice(0,xS)}\u2026`:r}}};$c=new WeakMap,Td=new WeakMap,Wi=new WeakSet,AS=function(){return c(this,Td)>xS},yS=function(t,n){if(n!==null&&td(n)||n!==null&&pn(n))return;let r=(t!=null?t:"").replace(/\s+/g," ").trim();r.length!==0&&P6(r)&&(c(this,$c).has(r)||(c(this,$c).add(r),g(this,Td,c(this,Td)+(r.length+u$.length))))};function H6(e){return e instanceof Element?e:e.parentElement}M();dn();var F6=new Set(["checkbox","switch"]),d$="aria-checked",qh=e=>{var t;return!He(e)&&F6.has((t=e.getAttribute("role"))!=null?t:"")},p$=e=>e.getAttribute(d$)==="true";function f$(e,t,n){var o;if(n||!qh(e)||t!==D.CHECK&&t!==D.UNCHECK)return;let r=t===D.CHECK;if(p$(e)!==r)throw new Error(`${t} clicked the ${(o=e.getAttribute("role"))!=null?o:""} but ${d$} is still "${String(!r)}" \u2014 the app did not toggle it`)}function Jh(e,t){if(t!==D.CHECK&&t!==D.UNCHECK)return!1;let n=t===D.CHECK;return He(e)?e.checked===n:qh(e)&&p$(e)===n}M();Lc();dt();dn();var wS=e=>new Promise(t=>ue(t,e));function B6(e,t=""){return typeof e=="string"?e:t}function em(e){return Wb(e)}var G6=["metaKey","ctrlKey","shiftKey","altKey"],E$={meta:"metaKey",cmd:"metaKey",command:"metaKey",super:"metaKey",win:"metaKey",control:"ctrlKey",ctrl:"ctrlKey",shift:"shiftKey",alt:"altKey",option:"altKey",opt:"altKey"};function tm(e){let t=e.modifiers,n=Array.isArray(t)?t.map(o=>B6(o).toLowerCase()):[],r={metaKey:!1,ctrlKey:!1,shiftKey:!1,altKey:!1};for(let o of n){let i=E$[o];i!==void 0&&(r[i]=!0)}return r}function h$(e){return E$[e.toLowerCase()]}function Qh(e,t){let n=e.code;return typeof n=="string"&&0<n.length?n:t===" "?"Space":t.length===1?/[a-z]/i.test(t)?`Key${t.toUpperCase()}`:/[0-9]/.test(t)?`Digit${t}`:"":/^[A-Z][A-Za-z0-9]*$/.test(t)&&K6.has(t)?t:""}function nm(e,t,n,r,o=!1){if(m$!==t&&t.length!==1)return;let i=new KeyboardEvent("keypress",{key:t,code:n,bubbles:!0,cancelable:!0,repeat:o,...r}),s=m$===t?V6:t.charCodeAt(0);for(let a of j6)Object.defineProperty(i,a,{value:s});rt(()=>e.dispatchEvent(i))}var m$="Enter",V6=13,j6=["keyCode","charCode","which"],K6=new Set(["Enter","Escape","Tab","Backspace","Delete","Home","End","PageUp","PageDown","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Insert","F1","F2","F3","F4","F5","F6","F7","F8","F9","F10","F11","F12"]),Z6="no document to press into";function b$(){let e=document.activeElement;if(ut(e)&&document.body!==e)return e;if(ut(document.body))return document.body;let t=document.documentElement;if(ut(t))return t;throw new Error(Z6)}function _$(e,t,n){return e.length===0&&IO(n)&&D.PRESS===t}function S$(e){return Yb(e)}var W6=33,g$=500,Y6={Backspace:8,Tab:9,Enter:13,Shift:16,Control:17,Alt:18,Escape:27," ":32,PageUp:33,PageDown:34,End:35,Home:36,ArrowLeft:37,ArrowUp:38,ArrowRight:39,ArrowDown:40,Delete:46,Meta:91},X6=/^[a-z0-9]$/i,q6=e=>{var t;return(t=Y6[e])!=null?t:X6.test(e)?e.toUpperCase().charCodeAt(0):0};function xd(e,t){let n=new KeyboardEvent(e,t),r=q6(t.key);for(let o of["keyCode","which"])Object.defineProperty(n,o,{get:()=>r});return n}async function T$(e,t,n,r,o){let i=Date.now();for(o>g$&&await wS(g$);Date.now()-i<o;)rt(()=>e.dispatchEvent(xd("keydown",{key:t,code:n,bubbles:!0,cancelable:!0,repeat:!0,...r})))&&nm(e,t,n,r,!0),await wS(Math.min(W6,Math.max(0,o-(Date.now()-i))))}async function x$(e,t,n,r){let o={...n},i=(d,f)=>{let m=Qh({},f);return rt(()=>e.dispatchEvent(xd(d,{key:f,code:m,bubbles:!0,cancelable:!0,...o})))},s=new Map;for(let d of G6)o[d]&&s.set(d,1);let a=d=>{var f;s.set(d,((f=s.get(d))!=null?f:0)+1),o[d]=!0},l=d=>{var m;let f=((m=s.get(d))!=null?m:1)-1;s.set(d,f),f<=0&&(o[d]=!1)},u=!1;for(let d of t){let f=h$(d);f!==void 0&&a(f);let m=i("keydown",d);m||(u=!0),m&&nm(e,d,Qh({},d),o),vS(e,d,m)}r>0&&await wS(r);for(let d of[...t].reverse()){let f=h$(d);f!==void 0&&l(f),i("keyup",d)}return u}function vS(e,t,n){var r,o;if(!(t!=="Escape"||!n))for(let i=e.closest("dialog");i!==null;i=(o=(r=i.parentElement)==null?void 0:r.closest("dialog"))!=null?o:null){try{if(!i.open||!i.matches(":modal"))continue}catch{return}typeof i.requestClose=="function"?i.requestClose():i.dispatchEvent(new Event("cancel",{cancelable:!0}))&&i.close();return}}Ot();M();Et();Qo();nt();var J6="canvas";function A$(e){var o,i,s,a;let t=(i=(o=e.defaultView)==null?void 0:o.innerWidth)!=null?i:0,n=(a=(s=e.defaultView)==null?void 0:s.innerHeight)!=null?a:0,r=0;for(let l of e.querySelectorAll(J6)){if(lr(l))continue;let u=l.getBoundingClientRect(),d=u.width>0&&u.height>0,f=u.bottom>0&&u.right>0&&u.top<n&&u.left<t;d&&f&&(r+=1)}return r}function y$(e){var a;let t=(a=Ne(e))!=null?a:void 0,n=dr(e),r={};if(t!==void 0){r.testid=t;let l=hS({by:at.TESTID,value:t}).length;1<l&&(r.testidOf=l)}let o=n==null?void 0:n.componentStack[0];o!==void 0&&(r.component=o),(n==null?void 0:n.source)!==void 0&&(r.source=n.source);let i=Le(e),s=we(e);if(i.length>0&&(r.role=i),s.length>0&&(r.name=s),pn(e)&&(r.secret=!0),i.length>0&&s.length>0){let l=hS({by:at.ROLE,value:i,name:s}),u=l.indexOf(e);1<l.length&&0<=u&&(r.nth=u,r.of=l.length)}return r}var w$=(e,t,n,r,o,i,s)=>{let a={ok:!0,ref:e,action:t,dispatched:!0,settled:r,settleReason:o,effect:n};return i.testid!==void 0&&(a.testid=i.testid),i.testidOf!==void 0&&(a.testidOf=i.testidOf),i.component!==void 0&&(a.component=i.component),i.source!==void 0&&(a.source=i.source),i.role!==void 0&&(a.role=i.role),i.name!==void 0&&(a.name=i.name),i.nth!==void 0&&(a.nth=i.nth),i.of!==void 0&&(a.of=i.of),i.secret!==void 0&&(a.secret=i.secret),s!==void 0&&(a.warning=s),a};gt();Ot();Et();nt();var Q6=[[.5,.5],[.25,.25],[.75,.25],[.25,.75],[.75,.75]],eK=3;function rm(e,t){var u;if(t.width===0||t.height===0)return null;let n=e.ownerDocument;if(typeof n.elementFromPoint!="function")return null;let r=n,o=d=>lr(d)&&d!==e&&!e.contains(d)&&!d.contains(e),i=(d,f)=>{var h,E,_;return(_=((E=(h=r.elementsFromPoint)==null?void 0:h.call(r,d,f))!=null?E:[n.elementFromPoint(d,f)]).find(A=>A!==null&&!o(A)))!=null?_:null},s=new Map;for(let[d,f]of Q6){let m=i(t.left+t.width*d,t.top+t.height*f);m!==null&&(m===e||e.contains(m)||m.contains(e)||s.set(m,((u=s.get(m))!=null?u:0)+1))}let a=null,l=0;for(let[d,f]of s)f>l&&(a=d,l=f);return l>=eK?a:null}dt();Lc();M();var Ad={occluded:!1,occludedBy:null,scrolledIntoView:!1};function Yi(e,t,n={}){return new MouseEvent(t,{...n,view:e.ownerDocument.defaultView})}function om(e,t,n){let r={...n,view:e.ownerDocument.defaultView};return typeof PointerEvent=="function"?new PointerEvent(t,r):new MouseEvent(t,r)}var Wt=1,yd=0,O$={modifiers:{metaKey:!1,ctrlKey:!1,shiftKey:!1,altKey:!1},button:ar.LEFT},I$={[ar.LEFT]:{button:0,bit:1},[ar.RIGHT]:{button:2,bit:2},[ar.MIDDLE]:{button:1,bit:4}};function RS(e){var t;return{modifiers:tm(e),button:(t=qb(e))!=null?t:ar.LEFT}}function Ke(e,t,n,r,o,i=0,s=O$){let a={bubbles:!(t.endsWith("enter")||t.endsWith("leave")),cancelable:!0,detail:i,clientX:n.x,clientY:n.y,screenX:n.x,screenY:n.y,buttons:r,button:I$[s.button].button,...s.modifiers,...o!==void 0?{relatedTarget:o}:{}};return e.dispatchEvent(t.startsWith("pointer")?om(e,t,{...a,pointerId:1,isPrimary:!0}):Yi(e,t,a))}async function kc(e,t,n,r=O$){var h;let o=e.ownerDocument,i=(h=o.activeElement)!=null?h:o.body,s=NS(e),a=n!=null?n:0,l=I$[r.button].bit,u=ar.LEFT===r.button,d=!0;rt(()=>Ke(e,"pointerdown",s,l,i,a,r)),rt(()=>Ke(e,"mousedown",s,l,void 0,a,r)),ar.RIGHT===r.button&&(d=rt(()=>Ke(e,"contextmenu",s,l,void 0,a,r))),e.tabIndex>=0&&typeof e.focus=="function"&&e.focus();let f=0;if(t!==void 0&&t.ms>0){let E=t.now();await t.sleep(t.ms),f=t.now()-E}rt(()=>Ke(e,"pointerup",s,yd,i,a,r)),rt(()=>Ke(e,"mouseup",s,yd,void 0,a,r));let m=rt(()=>Ke(e,u?"click":"auxclick",s,yd,void 0,a,r));return ar.RIGHT!==r.button&&(d=m),{prevented:!d,heldMs:f}}function tK(e){return e.width>0||e.height>0}function wd(e,t){let n=e.ownerDocument.defaultView;if(n===null)return!1;let r=t.left+t.width/2,o=t.top+t.height/2;return r<0||o<0||r>n.innerWidth||o>n.innerHeight}function nK(e,t){let n=rm(e,t);return n===null?{occluded:!1,occludedBy:null}:{occluded:!0,occludedBy:re.refFor(n),occluderName:rK(n)}}function rK(e){let t=Ne(e);if(t!==null&&t.length>0)return`[data-testid="${t}"]`;let n=we(e).trim();return n.length>0?`${Le(e)} "${n.slice(0,40)}"`:e.tagName.toLowerCase()}function oK(e){if(typeof e.getClientRects!="function")return!1;let t=Array.from(e.getClientRects());return t.length>0&&t.every(n=>n.width===0||n.height===0)}function C$(e){if(typeof e.getBoundingClientRect!="function")return Ad;let t=e.getBoundingClientRect();if(!tK(t))return oK(e)?{...Ad,noSize:!0}:Ad;let n=!1;wd(e,t)&&typeof e.scrollIntoView=="function"&&(e.scrollIntoView({block:"center",inline:"center"}),n=!0,t=e.getBoundingClientRect());let r=n&&wd(e,t);return{...nK(e,t),scrolledIntoView:n,...r?{offViewport:!0}:{}}}function OS(e,t,n=null){rt(()=>e.dispatchEvent(om(e,t,{bubbles:!0,cancelable:!0,relatedTarget:n})))}function L$(e,t,n=null){rt(()=>e.dispatchEvent(om(e,t,{bubbles:!1,cancelable:!0,relatedTarget:n})))}function iK(e){if(typeof DataTransfer!="function")return null;let t=new DataTransfer,n=Array.isArray(e)?e:e!==void 0?[e]:[];for(let r of n)if(typeof r=="object"&&r!==null){let o=r;typeof o.mime=="string"&&typeof o.value=="string"&&t.setData(o.mime,o.value)}return t}var v$=5;function NS(e){let t=e.getBoundingClientRect();return{x:t.left+t.width/2,y:t.top+t.height/2}}function sK(e,t,n){return{x:Math.round(e.x+(t.x-e.x)*n),y:Math.round(e.y+(t.y-e.y)*n)}}async function IS(e,t,n){let r=t!=null?t:e,o=NS(e),i=NS(r),s=e.getBoundingClientRect(),a=t!==null?r.getBoundingClientRect():null,l=(m,h)=>h.x>=m.left&&h.x<=m.right&&h.y>=m.top&&h.y<=m.bottom;Ke(e,"pointerdown",o,Wt),Ke(e,"mousedown",o,Wt),await mo();let u=!1,d=!1;for(let m=1;m<=v$;m+=1){let h=sK(o,i,m/v$);!u&&!l(s,h)&&(u=!0,Ke(e,"pointerout",h,Wt,r),Ke(e,"mouseout",h,Wt,r),Ke(e,"pointerleave",h,Wt,r),Ke(e,"mouseleave",h,Wt,r)),u&&!d&&a!==null&&l(a,h)&&(d=!0,Ke(r,"pointerover",h,Wt,e),Ke(r,"mouseover",h,Wt,e),Ke(r,"pointerenter",h,Wt,e),Ke(r,"mouseenter",h,Wt,e)),Ke(r,"pointermove",h,Wt),Ke(r,"mousemove",h,Wt),await mo()}!d&&a!==null&&(Ke(r,"pointerover",i,Wt,e),Ke(r,"mouseover",i,Wt,e),Ke(r,"pointerenter",i,Wt,e),Ke(r,"mouseenter",i,Wt,e)),Ke(r,"pointerup",i,yd),Ke(r,"mouseup",i,yd);let f=!1;if(typeof DragEvent=="function"){let m=iK(n),h={bubbles:!0,cancelable:!0};m!==null&&(h.dataTransfer=m),e.dispatchEvent(new DragEvent("dragstart",h)),await mo(),r.dispatchEvent(new DragEvent("dragenter",h)),r.dispatchEvent(new DragEvent("dragover",h)),await mo(),f=!r.dispatchEvent(new DragEvent("drop",h)),e.dispatchEvent(new DragEvent("dragend",h))}return f}async function $$(e,t){let n=aK(e);N$(e,"pointerdown"),rt(()=>e.dispatchEvent(R$("touchstart",n))),e.tabIndex>=0&&typeof e.focus=="function"&&e.focus();let r=0;if(t!==void 0&&t.ms>0){let i=t.now();await t.sleep(t.ms),r=t.now()-i}return rt(()=>e.dispatchEvent(R$("touchend",[]))),N$(e,"pointerup"),{prevented:!rt(()=>e.dispatchEvent(Yi(e,"click",{bubbles:!0,cancelable:!0}))),heldMs:r}}function N$(e,t){rt(()=>e.dispatchEvent(om(e,t,{bubbles:!0,cancelable:!0,pointerType:"touch",isPrimary:!0,width:23,height:23})))}function aK(e){if(typeof Touch!="function"||typeof e.getBoundingClientRect!="function")return[];let t=e.getBoundingClientRect();try{return[new Touch({identifier:0,target:e,clientX:t.left+t.width/2,clientY:t.top+t.height/2})]}catch{return[]}}function R$(e,t){if(typeof TouchEvent=="function")try{return new TouchEvent(e,{bubbles:!0,cancelable:!0,touches:t,targetTouches:t,changedTouches:t})}catch{}return new Event(e,{bubbles:!0,cancelable:!0})}var cK=new Set(["menu","menubar","listbox","dialog","alertdialog","tooltip"]),lK="closed";function k$(e){var t,n;for(let r=e.parentElement;r!==null;r=r.parentElement)if(lK===r.getAttribute("data-state")&&cK.has((t=r.getAttribute("role"))!=null?t:""))throw new Error(`'${(n=r.getAttribute("role"))!=null?n:"popup"}' holding this element is closing (data-state="closed"), so a person could not click it: look again once it has gone and act on what is open`)}gt();var uK=400,dK=.8,pK="scroll fraction must be between 0 and 1, got ";function fK(e){return`${pK}${e}`}function hK(e,t){var r;let n=e;for(;n!==null&&n!==document.body;){let o=getComputedStyle(n),i=t==="x"?o.overflowX:o.overflowY,s=t==="x"?n.scrollWidth>n.clientWidth:n.scrollHeight>n.clientHeight;if((i==="auto"||i==="scroll")&&s)return n;n=n.parentElement}return(r=document.scrollingElement)!=null?r:document.documentElement}function z$(e,t,n,r){let o=e!==void 0?re.resolve(e):null;return CS(o instanceof Element?o:void 0,t,n,r)}function CS(e,t,n,r){var d;if(n!==void 0&&(n<0||n>1||Number.isNaN(n)))throw new RangeError(fK(n));let i=e!==void 0?hK(e,r!==void 0&&r!==0&&(t===void 0||t===0)?"x":"y"):(d=document.scrollingElement)!=null?d:document.documentElement,s=i.scrollTop,a=i.scrollLeft;if(n!==void 0)i.scrollTop=Math.round(i.scrollHeight*n);else if(r!==void 0&&r!==0&&(i.scrollLeft=a+r),r===void 0||t!==void 0&&t!==0){let f=t!=null?t:Math.round(i.clientHeight*dK)||uK;i.scrollTop=s+f}i.dispatchEvent(new Event("scroll",{bubbles:!1}));let l=i.scrollTop,u=i.scrollLeft;return{scrolled:l!==s||u!==a,scrollTop:l,scrollHeight:i.scrollHeight,clientHeight:i.clientHeight,atEnd:l+i.clientHeight>=i.scrollHeight-1,atStart:l<=1,scrollLeft:u,scrollWidth:i.scrollWidth,clientWidth:i.clientWidth,atLeftEnd:u<=1,atRightEnd:u+i.clientWidth>=i.scrollWidth-1}}M();Et();Yo();var mK='label, summary, [onclick], [tabindex], [contenteditable]:not([contenteditable="false"])';function D$(e,t){if(D.CLICK!==t&&D.DBLCLICK!==t)return!1;for(let n=e;n!==null;n=Pi(n))if(Rc.has(Le(n))||n.matches(mK))return!1;return getComputedStyle(e).cursor!=="pointer"}function vd(e,t=""){return typeof e=="string"?e:t}function gK(e){let t=re.resolve(e);if(t===null)throw new Error(`ref '${kr(e)}' no longer resolves to an element`);if(!Mi(t))throw new Error(`ref '${kr(e)}' is not an HTML or SVG element`);return t}var EK=new Set([D.FILL,D.TYPE,D.CLEAR,D.SELECT]),bK=e=>EK.has(e),H$=new Set([D.CLICK,D.DBLCLICK,D.CHECK,D.UNCHECK]);function F$(e){let t=vd(e.toRef);return t!==""?t:vd(e.target)}var P$=new Set(["content","name","type","__base64"]),_K=new Set([Hf,xR,"holdMs"]);function SK(e){let t=Object.keys(e),n=t.filter(o=>!P$.has(o)&&!_K.has(o));if(n.length===0&&t.some(o=>P$.has(o)))return;let r=n.length===0?"no file was described":`upload does not read ${n.join(", ")}, so it would be dropped`;throw new Error(`upload needs the file described as args: { name, content?, type? } \u2014 ${r}. To upload a file from disk, use the reticle daemon which reads it via args.path and delivers real bytes; calling with { path } directly reaches only fabricated content.`)}function TK(e,t,n){let r=t===D.CLICK||t===D.DBLCLICK||t===D.CHECK||t===D.UNCHECK||t===D.DRAG||t===D.SUBMIT||t===D.PRESS&&em(n)==="Enter",o=t===D.DRAG?re.resolve(F$(n)):null,i=t===D.PRESS&&em(n)==="Enter"?CC(e):null;r&&LC([e,i,Mi(o)?o:null]),(t===D.FILL||t===D.TYPE)&&$C(e);let s=vh(e)||i!==null&&vh(i),a=Mi(o)&&vh(o);if(r&&(s||a)&&n[Hf]!==!0)throw new Error(`potentially destructive action blocked; retry with args.${Hf}=true`);if(H$.has(t)&&e instanceof HTMLElement&&pS(e))throw new Error("cannot click a native <option> inside a visually-hidden <select> \u2014 open the dropdown and target the visible option")}function xK(e,t){var r,o;if(e.some(i=>i.value===t))return t;let n=e.filter(i=>i.label.trim()===t.trim());return n.length===1&&(o=(r=n[0])==null?void 0:r.value)!=null?o:t}function B$(e){return!Jo(e).includes(Se.DISABLED)}function M$(e){if(He(e)||vn(e)||$r(e))return e.value}function U$(e){let t=e.ownerDocument.activeElement;return t===null||t===e.ownerDocument.body?null:re.refFor(t)}async function AK(e,t,n){if(D.CLICK===t){let r=hc(n.holdMs);return await kc(e,r===0?void 0:{ms:r,sleep:$S,now:()=>Date.now()},void 0,RS(n))}if(D.TAP===t){let r=hc(n.holdMs);return await $$(e,r===0?void 0:{ms:r,sleep:$S,now:()=>Date.now()})}return{prevented:await NK(e,t,n),heldMs:0}}var yK="cannot zoom from inside the page \u2014 CSS zoom changes how it LOOKS without changing the layout viewport, visualViewport or media queries, so a layout that breaks at 200% would be reported as checked and passing. Drive a real browser (reticle drive <url>, or reticle_lease) and zoom there.";function wK(e){return Le(e)==="combobox"||e.getAttribute("aria-haspopup")==="listbox"}var vK=e=>`cannot select on a <${e}> \u2014 it is an ARIA combobox, not a native <select>. Click the combobox to open it, then click the option with { role: "option", name: "<label>" }.`;function LS(e){return typeof e=="number"&&Number.isFinite(e)?e:void 0}async function NK(e,t,n){var r;switch(t){case D.DBLCLICK:{let o=RS(n);return await kc(e,void 0,1,o),await kc(e,void 0,2,o),!rt(()=>e.dispatchEvent(Yi(e,"dblclick",{bubbles:!0,cancelable:!0,detail:2,...o.modifiers})))}case D.HOVER:{let o=e.ownerDocument,i=(r=o.activeElement)!=null?r:o.body;OS(e,"pointerover",i),e.dispatchEvent(Yi(e,"mouseover",{bubbles:!0,relatedTarget:i})),L$(e,"pointerenter",i),e.dispatchEvent(Yi(e,"mouseenter",{relatedTarget:i})),OS(e,"pointermove",i);let s=e.dispatchEvent(Yi(e,"mousemove",{bubbles:!0,cancelable:!0})),a=hc(n.holdMs);return a>0&&await $S(a),!s}case D.FOCUS:return e.focus(),e.dispatchEvent(new FocusEvent("focusin",{bubbles:!0})),!1;case D.BLUR:{let i=e.getRootNode().activeElement===e;return e.blur(),i||(e.dispatchEvent(new FocusEvent("blur")),e.dispatchEvent(new FocusEvent("focusout",{bubbles:!0}))),!1}case D.FILL:if(He(e)||vn(e)){if(typeof n.value!="string")throw new Error("fill requires a string `value` \u2014 pass it nested, as args: { value: '\u2026' }. To empty a field on purpose use the `clear` action, or fill with an explicit \"\".");return bS(e,"fill"),gS(e)||e.focus(),Kh(e,n.value)}throw ES(e,"fill"),new Error(`cannot fill a <${e.tagName.toLowerCase()}>`);case D.TYPE:if(He(e)||vn(e)){if(typeof n.text!="string")throw new Error("type requires a string `text` \u2014 pass it nested, as args: { text: '\u2026' }.");return bS(e,"type"),e.focus(),Kh(e,e.value+n.text)}throw ES(e,"type into"),new Error(`cannot type into a <${e.tagName.toLowerCase()}>`);case D.CLEAR:if(He(e)||vn(e))return Kh(e,"");throw new Error(`cannot clear a <${e.tagName.toLowerCase()}>`);case D.SELECT:if($r(e)){if(typeof n.value!="string")throw new Error("select requires a string `value` \u2014 pass it nested, as args: { value: '\u2026' }.");let o=Array.from(e.options),i=xK(o,n.value);if(!o.some(s=>s.value===i)){let s=o.map(a=>`${a.value} (${a.label})`).join(", ");throw new Error(`no <option> with value '${kr(i)}' \u2014 available: ${o.length===0?"(none)":s}`)}return e.value=i,e.dispatchEvent(new Event("change",{bubbles:!0})),!1}if(wK(e)){if(typeof n.value!="string")throw new Error("select requires a string `value` \u2014 pass it nested, as args: { value: '\u2026' }.");return await n$(e,n.value,o=>kc(o),vK(e.tagName.toLowerCase()))}throw new Error(`cannot select on a <${e.tagName.toLowerCase()}>`);case D.CHECK:case D.UNCHECK:{let o=qh(e);if(!He(e)&&!o)throw new Error(`cannot (un)check a <${e.tagName.toLowerCase()}>`);if(!B$(e))throw new Error(`cannot ${t} a disabled control \u2014 a real user could not, so neither will Reticle`);if(!He(e))return Jh(e,t)?!1:(await kc(e)).prevented;if(e.type==="radio"&&t===D.UNCHECK)throw new Error("cannot uncheck a radio button \u2014 a real user could not; select another radio in the group");if(Jh(e,t))return!1;let i=Yi(e,"click",{bubbles:!0,cancelable:!0,composed:!0});return!rt(()=>e.dispatchEvent(i))||i.defaultPrevented}case D.SUBMIT:{let o=K0(e)?e:e.closest("form");if(o===null)throw new Error("no form to submit");return o.requestSubmit(),!1}case D.PRESS:{let o=tm(n),i=S$(n);if(i.length>0)return await x$(e,i,o,hc(n.holdMs));let s=em(n),a=Qh(n,s),l=rt(()=>e.dispatchEvent(xd("keydown",{key:s,code:a,bubbles:!0,cancelable:!0,...o})));vS(e,s,l),l&&nm(e,s,a,o);let u=hc(n.holdMs);return u>0&&await T$(e,s,a,o,u),rt(()=>e.dispatchEvent(xd("keyup",{key:s,code:a,bubbles:!0,...o}))),!l}case D.SCROLL_INTO_VIEW:return e.scrollIntoView(),!1;case D.ZOOM:throw new Error(yK);case D.SCROLL:{let o=LS(n.dy),i=LS(n.dx),s=LS(n.fraction);return CS(e,o,s,i),!1}case D.UPLOAD:{if(!He(e)||e.type!=="file")throw new Error('upload target must be a <input type="file">');SK(n);let o=vd(n.content,"reticle test file"),i=o;if(n.__base64===!0){let u=atob(o),d=new Uint8Array(u.length);for(let f=0;f<u.length;f++)d[f]=u.charCodeAt(f);i=d.buffer.slice(0)}let s=new File([i],vd(n.name,"file.txt"),{type:vd(n.type,"text/plain")}),a=new DataTransfer;a.items.add(s),e.files=a.files;let l=e.dispatchEvent(new Event("input",{bubbles:!0,cancelable:!0}));return e.dispatchEvent(new Event("change",{bubbles:!0})),!l}case D.DRAG:{let o=F$(n);if(o==="")return await IS(e,null,n.data);let i=re.resolve(o);if(!Mi(i))throw new Error(`drag target '${kr(o)}' did not resolve to an element \u2014 pass a ref from reticle_snapshot or reticle_query as args.toRef (alias: args.target)`);return await IS(e,i,n.data)}default:throw new Error(`unknown action '${t}'`)}}async function Nd(e,t,n={}){let r=0<e.length;if(D.CLICK===t||D.DBLCLICK===t){let be=LO(t,n);if(be!==void 0)throw new Error(`cannot ${t}: ${be}`)}let o=_$(e,t,n)?b$():gK(e);r&&TK(o,t,n),r&&k$(o);let i=r?y$(o):{},s=Je(o),a=B$(o),l=U$(o),u=M$(o),d=a$(o),f=H$.has(t)?C$(o):Ad,m=Jh(o,t),h=D$(o,t),E=0,_=new Xh,A=new MutationObserver(be=>{E+=be.length,_.collect(be)});A.observe(o.ownerDocument.documentElement,{subtree:!0,childList:!0,attributes:!0,characterData:!0});let v=!1,N=0,O=!1,k=null;try{let be=await AK(o,t,n);v=be.prevented,N=be.heldMs}finally{let be=e$(n.settleMs),me=await QL(be);O=me.settled,k=me.settled?null:NR.TIMEOUT,A.disconnect(),d==null||d.stop()}f$(o,t,m);let j=M$(o);c$(o,d);let Y=U$(o),X={dispatched:!0,targetMatched:r&&o.isConnected,visible:s,enabled:a,defaultPrevented:v,focusMoved:l!==Y?`${l!=null?l:"null"}->${Y!=null?Y:"null"}`:null,valueChanged:bK(t)?u!==j:!1,...D.FILL===t&&gS(o)?{autofillSafe:!0}:{},domMutatedWithin:E,..._.effect(j),occluded:f.occluded,occludedBy:f.occludedBy,scrolledIntoView:f.scrolledIntoView,...f.occluderName===void 0?{}:{occluderName:f.occluderName},...f.noSize===!0?{noSize:!0}:{},...f.offViewport===!0?{offViewport:!0}:{},...N>0?{heldMs:N}:{},...m?{alreadyAtValue:!0}:{},...RK()},G;r?f.occluded?G=$u.CLICK_OCCLUDED:t===D.HOVER&&Rh(o)?G=$u.HOVER_NATIVE_ENTER_LEAVE:h&&(G=$u.CLICK_NOT_A_CONTROL):G=$u.GLOBAL_PRESS;let ee=w$(e,t,X,O,k,i,G);return lr(o)?{...ee,reticleUi:!0}:ee}function RK(){let e=A$(document);return e>0?{canvases:e}:{}}var $S=e=>new Promise(t=>ue(t,e));async function im(e){var r;let t=[],n=[];for(let o of e){let i=await Nd(o.ref,o.action,(r=o.args)!=null?r:{});t.push(i.effect);let s={ref:i.ref,action:i.action,dispatched:i.dispatched,settled:i.settled,settleReason:i.settleReason};i.testid!==void 0&&(s.testid=i.testid),i.component!==void 0&&(s.component=i.component),i.role!==void 0&&(s.role=i.role),i.name!==void 0&&(s.name=i.name),i.source!==void 0&&(s.source=i.source),i.secret!==void 0&&(s.secret=i.secret),i.warning!==void 0&&(s.warning=i.warning),n.push(s)}return{ok:!0,count:e.length,effects:t,steps:n}}Et();ud();var G$="data-theme";function OK(e){return"cssRules"in e&&e.cssRules instanceof CSSRuleList}function K$(e,t,n){if(!(n<=0))for(let r of Array.from(e))if(r instanceof CSSStyleRule)for(let o of Array.from(r.style))o.startsWith("--")&&t.add(o);else OK(r)&&K$(r.cssRules,t,n-1)}function IK(){let e=new Set;for(let t of Array.from(document.styleSheets)){let n=null;try{n=t.cssRules}catch{continue}n!==null&&K$(n,e,8)}return e}function CK(){var o;let e=new Map,t=(o=document.body)!=null?o:document.documentElement;if(t===null)return e;let n=getComputedStyle(t),r=document.createElement("span");r.style.position="absolute",r.style.pointerEvents="none",document.body.appendChild(r);try{for(let i of IK()){let s=LK(r,n.getPropertyValue(i).trim());if(s===null)continue;let a=e.get(s);a===void 0?e.set(s,[i]):a.push(i)}}finally{r.remove()}for(let i of e.values())i.sort();return e}function LK(e,t){return t.length===0||(e.style.color="",e.style.color=t,e.style.color==="")?null:getComputedStyle(e).color}function V$(e){return e==="rgba(0, 0, 0, 0)"||e==="transparent"}function $K(){let e=document.documentElement;if(e===null)return null;let t=Array.from(e.classList).map(o=>`.${o}`).join(""),n=e.getAttribute(G$),r=`${t}${n===null?"":`[${G$}="${n}"]`}`;return r.length===0?null:r}function j$(e){var t;return e.length===1&&(t=e[0])!=null?t:null}function Z$(e){var a,l;let t=CK(),n=(a=t.get(e.color))!=null?a:[],r=(l=t.get(e.backgroundColor))!=null?l:[],o=!V$(e.color)&&n.length===0,i=!V$(e.backgroundColor)&&r.length===0,s=0;for(let u of t.values())s+=u.length;return{colorToken:j$(n),colorTokens:n,backgroundToken:j$(r),backgroundTokens:r,offTheme:s>0&&(o||i),tokenCount:s,themeScope:$K()}}gt();dn();M();ur();po();function Rd(e){try{return e()}catch{return null}}function sm(e){var n;let t={};if(e===null)return t;for(let r=0;r<e.length;r+=1){let o=e.key(r);if(o===null)continue;let i=(n=e.getItem(o))!=null?n:"";t[o]=St(o)?ve:io(i)}return t}function W$(){let e={},t="";try{t=typeof document!="undefined"?document.cookie:""}catch{return e}for(let n of t.split(";")){let r=n.indexOf("=");if(r===-1)continue;let o=n.slice(0,r).trim();if(o==="")continue;if(St(o)){e[o]=ve;continue}let i="";try{i=decodeURIComponent(n.slice(r+1).trim())}catch{i=n.slice(r+1).trim()}e[o]=io(i)}return e}function Y$(e){return e===Vs.LOCAL?sm(Rd(()=>window.localStorage)):e===Vs.SESSION?sm(Rd(()=>window.sessionStorage)):Vs.COOKIE===e?W$():{local:sm(Rd(()=>window.localStorage)),session:sm(Rd(()=>window.sessionStorage)),cookies:W$()}}function Xs(e,t){if(t!==null)return St(e)?ve:io(t)}function X$(e){var d,f,m;if(typeof Storage=="undefined")return()=>{};let t=Storage.prototype,n=(d=Object.getOwnPropertyDescriptor(t,"setItem"))==null?void 0:d.value,r=(f=Object.getOwnPropertyDescriptor(t,"removeItem"))==null?void 0:f.value,o=(m=Object.getOwnPropertyDescriptor(t,"clear"))==null?void 0:m.value;if(n===void 0||r===void 0||o===void 0)return()=>{};let i=h=>h===Rd(()=>window.sessionStorage)?Vs.SESSION:Vs.LOCAL,s=(h,E)=>{try{return h.getItem(E)}catch{return null}},a=function(h,E){var A;let _=(A=Zt(()=>s(this,h)))!=null?A:null;n.call(this,h,E),_!==E&&(Th(h)||oe(()=>{var v;e(w.STORAGE_CHANGE,{area:i(this),key:h,...Xs(h,_)===void 0?{}:{old:Xs(h,_)},new:(v=Xs(h,E))!=null?v:ve})}))};t.setItem=a;let l=function(h){var _;let E=(_=Zt(()=>s(this,h)))!=null?_:null;r.call(this,h),!Th(h)&&oe(()=>{e(w.STORAGE_CHANGE,{area:i(this),key:h,...Xs(h,E)===void 0?{}:{old:Xs(h,E)}})})};t.removeItem=l;let u=function(){let h=i(this),E=[];try{for(let _=0;_<this.length;_+=1){let A=this.key(_);A!==null&&!Th(A)&&E.push({key:A,old:s(this,A)})}}catch{}o.call(this);for(let{key:_,old:A}of E)oe(()=>{e(w.STORAGE_CHANGE,{area:h,key:_,...Xs(_,A)===void 0?{}:{old:Xs(_,A)}})})};return t.clear=u,()=>{t.setItem===a&&(t.setItem=n),t.removeItem===l&&(t.removeItem=r),t.clear===u&&(t.clear=o)}}M();gt();dt();var zc=16,kK=500,zK=4,DK=2166136261,PK=16777619,MK=8;function UK(e){var i,s;let t=DK,n=[0,0,0],r=Math.max(1,e.length/4);for(let a=0;a<e.length;a+=4)for(let l=0;l<3;l+=1){let u=(i=e[a+l])!=null?i:0;n[l]=((s=n[l])!=null?s:0)+u,t=Math.imul(t^Math.floor(u/MK),PK)>>>0}let o=n.map(a=>Math.round(a/r));return{digest:t.toString(16).padStart(8,"0"),mean:o}}function HK(e){if(e.width===0||e.height===0)return;let t=document.createElement("canvas");t.width=zc,t.height=zc;let n=t.getContext("2d");if(n===null)return;let r=Zt(()=>(n.drawImage(e,0,0,zc,zc),n.getImageData(0,0,zc,zc).data));return r===void 0?void 0:{data:r,width:e.width,height:e.height}}var Dc;function kS(){Dc==null||Dc(ks.ACT)}function q$(e,t={}){var a,l;let n=(a=t.sample)!=null?a:HK,r=(l=t.every)!=null?l:Wh,o=new WeakMap,i=u=>{oe(()=>{let d=Array.from(document.querySelectorAll("canvas")).slice(0,zK);for(let f of d){let m=n(f);if(m===void 0)continue;let{digest:h,mean:E}=UK(m.data);ks.POLL===u&&o.get(f)===h||(o.set(f,h),e(w.CANVAS_DIGEST,{digest:h,width:m.width,height:m.height,mean:E,trigger:u},re.refFor(f)))}})};Dc=i;let s=r(()=>i(ks.POLL),kK);return()=>{s(),Dc===i&&(Dc=void 0)}}M();dt();nt();var FK=ac.FULL_PAGE_UNSUPPORTED,BK=[FK,ac.NOT_COMPOSITED],GK="__TAURI_INTERNALS__";function VK(){let e=window[GK];if(typeof(e==null?void 0:e.invoke)!="function")return;let t=e.invoke.bind(e);return async n=>{let r=await t(lh,{fullPage:n===!0});return typeof r=="string"?r:null}}async function jK(e){let t=[...document.querySelectorAll(Ui)],n=t.map(r=>r.style.visibility);for(let r of t)r.style.visibility="hidden";try{return t.length>0&&(await mo(),await mo()),await e()}finally{t.forEach((r,o)=>{var i;r.style.visibility=(i=n[o])!=null?i:""})}}async function J$(e=!1){let t=window[Ko],n=typeof(t==null?void 0:t.capture)=="function"?t.capture:VK();if(n===void 0)return{ok:!1,reason:"no desktop capture helper installed"};try{let r=await jK(()=>n(e));return typeof r=="string"&&r.length>0?{ok:!0,path:r}:{ok:!1,reason:"capture returned no image"}}catch(r){let o=r instanceof Error?r.message:String(r);for(let i of BK)if(o.includes(i))return{ok:!1,reason:i};return{ok:!1,reason:o}}}Qo();Ys();ur();Ki();function KK(e,t){var n;return(n=Object.getOwnPropertyDescriptor(e,t))==null?void 0:n.value}function Dr(e,t){let n=KK(e,t);if(n===void 0)throw new Error(`[Reticle] cannot patch ${String(t)}: it is not an own property of the target`);return n}Wo();var ZK=12e4,Mc=!1,ti=0,Q$=0,ek=1,ni=[],Pc=null,qs,am={};function tk(){if(Pc===null)return;let e=Pc,t=e.clearTimeout.bind(window);qs!==void 0&&t(qs),qs=e.setTimeout.bind(window)(()=>{qs=void 0,Uc()},ZK)}function nk(){return Mc}function rk(){if(Mc||typeof window=="undefined")return;Mc=!0,ti=0,Q$=Date.now(),Pc={setTimeout:Dr(window,"setTimeout"),clearTimeout:Dr(window,"clearTimeout"),setInterval:Dr(window,"setInterval"),clearInterval:Dr(window,"clearInterval"),dateNow:Dr(Date,"now")};let e=(r,o,i)=>{let s=ek;return ek+=1,ni.push({id:s,time:ti+Math.max(0,o),cb:r,interval:i}),s},t=r=>{ni=ni.filter(o=>o.id!==r)},n=(r,o)=>()=>{r(...o)};window.setTimeout=((r,o=0,...i)=>e(n(r,i),o)),window.clearTimeout=(r=>t(r)),window.setInterval=((r,o=0,...i)=>e(n(r,i),o,Math.max(1,o))),window.clearInterval=(r=>t(r)),am={setTimeout:ke(window,"setTimeout"),clearTimeout:ke(window,"clearTimeout"),setInterval:ke(window,"setInterval"),clearInterval:ke(window,"clearInterval")},Date.now=()=>Q$+ti,am.dateNow=ke(Date,"now"),tk()}function ok(e){if(!Mc)return;let t=ti+Math.max(0,e),n=0;for(;n+=1,!(n>1e5);){let o=ni.filter(i=>i.time<=t).sort((i,s)=>i.time-s.time)[0];if(o===void 0)break;ni=ni.filter(i=>i!==o),ti=o.time,o.cb(),o.interval!==void 0&&ni.push({...o,time:ti+o.interval})}ti=t,tk()}function Uc(){if(!Mc||Pc===null)return;let e=Pc,t=ni;qs!==void 0&&(e.clearTimeout.bind(window)(qs),qs=void 0);let n=am;am={},window.setTimeout===n.setTimeout&&(window.setTimeout=e.setTimeout),window.clearTimeout===n.clearTimeout&&(window.clearTimeout=e.clearTimeout),window.setInterval===n.setInterval&&(window.setInterval=e.setInterval),window.clearInterval===n.clearInterval&&(window.clearInterval=e.clearInterval),Date.now===n.dateNow&&(Date.now=e.dateNow);let r=ti;if(Pc=null,ni=[],Mc=!1,ti=0,t.length===0)return;let o=e.setTimeout.bind(window),i=e.setInterval.bind(window),s=new Map,a={},l=u=>{s.delete(u),s.size===0&&a.current!==void 0&&YK(e,a.current)};for(let u of t)u.interval!==void 0?s.set(u.id,i(u.cb,u.interval)):s.set(u.id,o(()=>{l(u.id),u.cb()},Math.max(0,u.time-r)));a.current=WK(s,e,l)}function WK(e,t,n){let r=o=>{let i=o.bind(window);return(s=>{let a=e.get(s);if(a===void 0){i(s);return}i(a),n(s)})};return window.clearTimeout=r(t.clearTimeout),window.clearInterval=r(t.clearInterval),{clearTimeout:ke(window,"clearTimeout"),clearInterval:ke(window,"clearInterval")}}function YK(e,t){window.clearTimeout===t.clearTimeout&&(window.clearTimeout=e.clearTimeout),window.clearInterval===t.clearInterval&&(window.clearInterval=e.clearInterval)}var cm="_reticle_reload";function Qe(e){return typeof e=="string"?e:void 0}function pk(e){return typeof e=="number"?e:void 0}function uk(e){return typeof e=="object"&&e!==null?e:{}}function d3(e){if(typeof e!="object"||e===null)return;let t=e;if(!(typeof t.file!="string"||typeof t.line!="number"))return{file:t.file,line:t.line,column:pk(t.column)}}function p3(e){return{by:Qe(e.by),value:Qe(e.value),role:Qe(e.role),name:Qe(e.name),text:Qe(e.text),label:Qe(e.label),placeholder:Qe(e.placeholder),testid:Qe(e.testid),alt:Qe(e.alt),component:Qe(e.component),scope:Qe(e.scope),self:e.self===!0?!0:void 0,attrs:Array.isArray(e.attrs)?e.attrs.filter(t=>typeof t=="string"):void 0,source:d3(e.source)}}function f3(e,t=!1){var h,E,_,A,v,N,O;let n=re.resolve(e);if(n===null)throw new Error(fd.staleRefMessage(e));let r=t&&typeof n.scrollIntoView=="function"&&wd(n,n.getBoundingClientRect());r&&n.scrollIntoView({block:"center",inline:"center"});let o=n.getBoundingClientRect(),i=dr(n),s=n.ownerDocument.defaultView,a=s!==null?s.getComputedStyle(n):null,l=a!==null?{color:a.color,backgroundColor:a.backgroundColor,opacity:a.opacity,cursor:a.cursor,display:a.display,visibility:a.visibility}:null,u=yh(Ah(n,i==null?void 0:i.source)),d=u!==void 0?void 0:NC(n.ownerDocument)?"This element has no source stamp. Others on the page do, so the stamping loader is running \u2014 the nearest stamped ancestor is out of range, or this element is rendered outside instrumented code.":"No element in this document carries a source stamp, so the stamping loader is not running: an older adapter, a bundler whose hook never ran, or a build the plugin was dropped from. Add @reticlehq/vite-plugin (or @reticlehq/babel-plugin) to the dev build and restart the dev server to get `file:line` back.",f={scrollTop:n.scrollTop,scrollHeight:n.scrollHeight,clientHeight:n.clientHeight,overflowY:(h=a==null?void 0:a.overflowY)!=null?h:"visible",scrollLeft:n.scrollLeft,scrollWidth:n.scrollWidth,clientWidth:n.clientWidth,overflowX:(E=a==null?void 0:a.overflowX)!=null?E:"visible"},m=W0(n);return{...ho(n),...u!==void 0?{source:u}:{},...m.length>0?{paintContext:m}:{},...d!==void 0?{sourceUnavailable:d}:{},tag:n.tagName.toLowerCase(),href:(_=n.getAttribute("href"))!=null?_:void 0,formAction:(ed(n)||He(n))&&(v=(A=n.form)==null?void 0:A.getAttribute("action"))!=null?v:void 0,formText:(ed(n)||He(n))&&(O=(N=n.form)==null?void 0:N.textContent)!=null?O:void 0,box:{x:o.x,y:o.y,width:o.width,height:o.height},...r?{scrolledIntoView:!0}:{},...t?{[yR]:!wd(n,o)}:{},occluded:h3(n,o),styles:l,scroll:f,theme:a!==null?Z$(a):null,component:i}}function h3(e,t){return rm(e,t)!==null}function m3(e){return typeof e=="object"&&e!==null&&"ok"in e&&typeof e.ok=="boolean"}var dk={ok:!1,reason:RR.UNAVAILABLE};function g3(e,t,n,r){let o=Vi();if(n!==void 0||r!==void 0){let l=sS(t);if(t!==void 0&&!Object.hasOwn(l,t))return{store:t,path:n,found:!1,value:null,storeNames:o};let u=t!==void 0?l[t]:{stores:l,storeNames:o},d=n!==void 0?ZI(u,n):{found:!0,value:u},f=d.found&&r!==void 0?bc(d.value,r):d.value,m=Zs(f);return{store:t,path:n,found:d.found,value:m.value,...m.truncation===void 0?{}:{truncation:m.truncation},..."availableKeys"in d?{availableKeys:d.availableKeys}:{},..."totalKeys"in d?{totalKeys:d.totalKeys}:{},storeNames:o}}let{stores:i,truncation:s}=Ed(t),a={stores:i,storeNames:o};if(s!==void 0&&(a.truncation=s),e!==void 0&&e.length>0){let l=re.resolve(e);if(l===null)a.component=dk;else{let u=Nh(l);a.component=m3(u)?u:dk}}return a}function E3(){let e=document;return typeof e.getAnimations!="function"?{animations:[]}:{animations:e.getAnimations().map(n=>{var s;let r=n.effect,o=r==null?void 0:r.getTiming(),i=(s=r==null?void 0:r.target)!=null?s:null;return{playState:n.playState,currentTime:n.currentTime,duration:o==null?void 0:o.duration,target:i===null?null:ho(i)}})}}function b3(e,t){if(e.length===0||e.length>Z.MAX_URL_LENGTH)return null;try{let n=new URL(e,t);return n.protocol==="http:"||n.protocol==="https:"?n.toString():null}catch{return null}}function fk(){let e=new Map;return e.set(H.SNAPSHOT,t=>{var n;return Lh({scope:Qe(t.scope),mode:(n=Qe(t.mode))!=null?n:lc.FULL,includeRoot:t.includeRoot===!0,ids:t.ids===!0,audit:t.audit===!0})}),e.set(H.QUERY,t=>{let n=t.limit;return Vh(p3(t),typeof n=="number"?n:void 0)}),e.set(H.MATCH,t=>_d(Du.parse(uk(t.query)),Qe(t.state),void 0,void 0,t.diagnose===!0)),e.set(H.ACT,async t=>{var o,i;let n=(o=Qe(t.action))!=null?o:"",r=await Nd((i=Qe(t.ref))!=null?i:"",n,uk(t.args));return kS(),r}),e.set(H.ACT_SEQUENCE,async t=>{let n=await im(Array.isArray(t.steps)?t.steps:[]);return kS(),n}),e.set(H.INSPECT,t=>{var n;return f3((n=Qe(t.ref))!=null?n:"",t[AR]===!0)}),e.set(H.ANIMATIONS,()=>E3()),e.set(H.CLOCK,t=>{if(t.reset===!0)Uc();else{t.freeze===!0&&rk();let n=t.advanceMs;typeof n=="number"&&ok(n)}return{frozen:nk()}}),e.set(H.STATE_READ,t=>g3(Qe(t.ref),Qe(t.store),Qe(t.path),pk(t.depth))),e.set(H.STORAGE_READ,t=>Y$(Qe(t.area))),e.set(H.CAPABILITIES,()=>ji()),e.set(H.CAPTURE,t=>J$(t.fullPage===!0)),e.set(H.RENDER,()=>Promise.resolve().then(()=>(lk(),ck)).then(t=>t.renderPage())),e.set(H.SCROLL,t=>{let n=t.dy,r=t.fraction;return z$(Qe(t.ref),typeof n=="number"?n:void 0,typeof r=="number"?r:void 0)}),e.set(H.NAVIGATE,t=>{let n=Qe(t.url);if(n===void 0||n.length===0)return{ok:!1,reason:"url required"};let r=b3(n,window.location.href);return r===null?{ok:!1,reason:"only http(s) navigation is allowed"}:(window.location.assign(r),{ok:!0,url:r})}),e.set(H.REFRESH,t=>{if(t.hard===!0){let n=new URL(window.location.href);n.searchParams.set(cm,String(Date.now())),window.location.replace(n.toString())}else window.location.reload();return{ok:!0}}),e}M();dt();gd();ur();function _3(e){if(typeof document=="undefined")return()=>{};let t=()=>{document.visibilityState==="visible"&&e()};return document.addEventListener("visibilitychange",t),()=>document.removeEventListener("visibilitychange",t)}var lm=1e3,S3=3e4;function T3(e){return Math.min(e*2,S3)}var x3=500,A3=1008,y3=3,Yt,ri,Xi,dm,go,qi,Fc,Bc,Ji,Gc,Id,Vc,Cd,jc,Js,Kc,Zc,fn,Ld,ze,hk,Hc,zS,mk,DS,PS,gk,Od,Ek,um=class{constructor(t){x(this,ze);x(this,Yt);x(this,ri,[]);x(this,Xi,[]);x(this,dm,0);x(this,go,!1);x(this,qi,!1);x(this,Fc,!1);x(this,Bc);x(this,Ji,lm);x(this,Gc,!1);x(this,Id,!1);x(this,Vc,0);x(this,Cd,!1);x(this,jc,0);x(this,Js);x(this,Kc);x(this,Zc);x(this,fn);x(this,Ld);var n;g(this,fn,t),g(this,Ld,(n=t.now)!=null?n:Zh)}connect(){var t,n;typeof WebSocket!="undefined"&&(g(this,go,!1),(n=c(this,Zc))!=null||g(this,Zc,((t=c(this,fn).onVisible)!=null?t:_3)(()=>T(this,ze,hk).call(this))),T(this,ze,Hc).call(this))}sendEvent(t){T(this,ze,Od).call(this,fo({kind:sn.EVENT,event:t}),{seq:t.seq,t:t.t,type:t.type})}redialAfterRefusal(){if(!c(this,go)){if(c(this,qi)&&c(this,Yt)===void 0){g(this,qi,!1),g(this,Ji,lm),T(this,ze,Hc).call(this);return}g(this,Fc,!0)}}reannounce(){c(this,Yt)===void 0||c(this,Yt).readyState!==WebSocket.OPEN||c(this,Yt).send(JSON.stringify(c(this,fn).hello()))}close(){var t,n;g(this,go,!0),(t=c(this,Zc))==null||t.call(this),g(this,Zc,void 0),(n=c(this,Yt))==null||n.close(),g(this,Yt,void 0)}};Yt=new WeakMap,ri=new WeakMap,Xi=new WeakMap,dm=new WeakMap,go=new WeakMap,qi=new WeakMap,Fc=new WeakMap,Bc=new WeakMap,Ji=new WeakMap,Gc=new WeakMap,Id=new WeakMap,Vc=new WeakMap,Cd=new WeakMap,jc=new WeakMap,Js=new WeakMap,Kc=new WeakMap,Zc=new WeakMap,fn=new WeakMap,Ld=new WeakMap,ze=new WeakSet,hk=function(){c(this,go)||(g(this,Ji,lm),c(this,Yt)===void 0&&(g(this,qi,!1),T(this,ze,Hc).call(this)))},Hc=function(){let t;try{t=new WebSocket(c(this,fn).url)}catch{T(this,ze,PS).call(this),T(this,ze,DS).call(this),T(this,ze,zS).call(this);return}g(this,Yt,t),t.onopen=()=>{var o,i,s;g(this,Bc,void 0),g(this,Gc,!1),g(this,Id,!0),g(this,Ji,lm);let n=c(this,fn).hello();(o=c(this,Kc))!=null||g(this,Kc,n.sessionId),t.send(JSON.stringify(n)),T(this,ze,Ek).call(this,t,n.sessionId);let r=[...c(this,ri),...c(this,Xi)].sort((a,l)=>a.order-l.order);for(let a of r)t.send(a.text);g(this,ri,[]),g(this,Xi,[]),(s=(i=c(this,fn)).onConnected)==null||s.call(i)},t.onmessage=n=>{let r=n.data;T(this,ze,gk).call(this,typeof r=="string"?r:String(r))},t.onclose=n=>{var r,o;if(g(this,Yt,void 0),n.code===A3){if(c(this,Fc)&&!c(this,go)){g(this,Fc,!1),T(this,ze,Hc).call(this);return}g(this,qi,!0);let i=n.reason.length>0?n.reason:"policy violation";zr(`[reticle] bridge refused the connection: ${i} \u2014 not retrying until you come back to this tab.`),(o=(r=c(this,fn)).onConnectionLost)==null||o.call(r);return}T(this,ze,PS).call(this),T(this,ze,DS).call(this),T(this,ze,zS).call(this)},t.onerror=()=>{t.close()}},zS=function(){var r;if(c(this,go)||c(this,qi))return;let t=c(this,Ji);g(this,Ji,T3(t)),((r=c(this,fn).schedule)!=null?r:ue)(()=>T(this,ze,mk).call(this),t)},mk=function(){c(this,go)||c(this,Yt)!==void 0||T(this,ze,Hc).call(this)},DS=function(){var t,n;c(this,Id)||c(this,Cd)||(g(this,Vc,c(this,Vc)+1),c(this,Vc)>=y3&&(g(this,Cd,!0),(n=(t=c(this,fn)).onUnreachable)==null||n.call(t,{url:c(this,fn).url,attempts:c(this,Vc)})))},PS=function(){var n,r,o;let t=c(this,Ld).call(this);(n=c(this,Bc))!=null||g(this,Bc,t),!c(this,Gc)&&t-c(this,Bc)>=HO.BRIDGE_LOST_MS&&(g(this,Gc,!0),(o=(r=c(this,fn)).onConnectionLost)==null||o.call(r))},gk=async function(t){var s;let n;try{n=JSON.parse(t)}catch{return}let r=p_.safeParse(n);if(!r.success){let a=n==null?void 0:n.id;typeof a=="string"&&a.length>0&&T(this,ze,Od).call(this,fo({kind:sn.COMMAND_RESULT,id:a,ok:!1,error:"this page could not parse the command \u2014 the @reticlehq/browser SDK and the daemon are probably different versions. Nothing ran."}));return}let o=r.data;if(o.sessionId!==void 0&&o.sessionId!==c(this,Kc)){T(this,ze,Od).call(this,fo({kind:sn.COMMAND_RESULT,id:o.id,ok:!1,error:`command addressed to session ${o.sessionId} but this page is ${(s=c(this,Kc))!=null?s:"(none)"} \u2014 the page reconnected under a new id, or two sessions share a socket. Nothing ran.`}));return}let i;try{i=await c(this,fn).handleCommand(o)}catch(a){i={ok:!1,error:a instanceof Error?a.message:String(a)}}T(this,ze,Od).call(this,fo({kind:sn.COMMAND_RESULT,id:o.id,ok:i.ok,result:i.result,error:i.error}))},Od=function(t,n){if(c(this,Yt)!==void 0&&c(this,Yt).readyState===WebSocket.OPEN){c(this,Yt).send(t);return}if(c(this,ri).length+c(this,Xi).length>=x3){let i=c(this,ri).length>0?c(this,ri).shift():c(this,Xi).shift();if((i==null?void 0:i.event)!==void 0){g(this,jc,c(this,jc)+1);let s=c(this,Js);(s===void 0||i.event.t<s.t)&&g(this,Js,i.event)}}let r=n!==void 0&&vO.has(n.type),o=bA(this,dm)._++;r?c(this,ri).push({text:t,event:n,order:o}):c(this,Xi).push({text:t,event:n,order:o})},Ek=function(t,n){let r=c(this,Js);if(r===void 0)return;let o={t:r.t,seq:r.seq,type:w.TRANSPORT_OVERFLOW,sessionId:n,data:{dropped:c(this,jc)}};t.send(fo({kind:sn.EVENT,event:o})),g(this,Js,void 0),g(this,jc,0)};MS();Qo();M();Ys();function _k(){let e=[$.UI,$.NET,$.LOG,$.ROUTE,$.STORAGE,$.TIME,$.SIGNAL];return Vi().length>0?[...e,$.STATE]:e}M();var w3="__TAURI_INTERNALS__";function Sk(){if(typeof window=="undefined")return so.SERVICE;let e=window;return e[Ko]!==void 0||e[w3]!==void 0?so.WEBVIEW:so.WEB}var v3=[H.SNAPSHOT,H.QUERY,H.MATCH,H.INSPECT,H.ACT,H.ACT_SEQUENCE,H.ANIMATIONS,H.NARRATE,H.CLOCK,H.CAPABILITIES,H.STATE_READ,H.STORAGE_READ,H.SCROLL,H.SESSION_CONFIG,H.PRESENTER,H.IMPACT,H.CAPTURE,H.RENDER,H.NAVIGATE,H.REFRESH,H.FLOWS,H.FLOW_PROGRESS,H.PLAN,H.MARKERS];function Tk(){return[...v3]}Ki();Ot();M();Et();uo();gt();nt();Yo();dn();function N3(e){var t,n;try{return(n=(t=e.contentDocument)==null?void 0:t.body)!=null?n:null}catch{return null}}function US(e){let t=[],n=(r,o)=>{if(!(o>=3))for(let i of r.querySelectorAll("iframe")){let s=N3(i);s!==null&&(t.push(s),n(s,o+1))}};return n(e,0),t}function xk(e){let t=new AbortController,n=()=>{for(let o of US(document))e(o)};n();let r=o=>{o.target instanceof HTMLIFrameElement&&n()};return document.addEventListener("load",r,{capture:!0,signal:t.signal}),()=>t.abort()}function Ak(e){var r;let t=wn(e)?e:null;if(t===null)return;let n=t.closest(Vn());return(r=n?Ne(n):null)!=null?r:re.refFor(t)}var R3=["class","hidden","disabled","open","aria-hidden","aria-expanded","aria-selected","aria-checked","data-state","style","src","href","value"],yk=120;function fm(e){if(e!==null)return e.length>yk?`${e.slice(0,yk)}\u2026`:e}var O3=new Set(["dialog","alertdialog"]),I3=new Set(["alert","status"]),$d=40;function wk(e,t){return e!=="generic"||t.length>0}var C3=40;function vk(e){let t=Le(e),n=we(e);if(wk(t,n))return{role:t,name:n,el:e};let r=0;for(let o of e.querySelectorAll("*")){if(r>=C3)return;if(r+=1,Hi(o))continue;let i=Le(o),s=we(o);if(wk(i,s))return{role:i,name:s,el:o}}}var L3=3;function HS(e){var r;let t="";for(let o of e)o.nodeType===L3&&(t+=(r=o.nodeValue)!=null?r:"");let n=t.trim();return n.length>0?n:void 0}var $3=new Set(["class","style","type","disabled","readonly","required","hidden"]);function k3(e,t){return!$3.has(t)&&!t.startsWith("aria-")&&pn(e)}var z3=3,D3=50;function P3(e){let t=e;for(let n=0;t!==null&&n<=z3;n+=1){let r=Ne(t);if(r!==null&&r.length>0)return r;t=t.parentElement}}var Nk=e=>{let t=P3(e);return t===void 0?{}:{testid:t}};function Rk(e){let t=F0(),n=new MutationObserver(s=>{var m,h,E,_,A,v,N;let a=0,l=0,u=0,d=0,f=0;for(let O of s){if(O.type==="attributes"){let k=O.target;if(wn(k)&&O.attributeName!==null&&!Hi(k)){if(u>=$d){f+=1;continue}u+=1;let j=k3(k,O.attributeName),Y=j?ve:fm(k.getAttribute(O.attributeName)),X=j&&O.oldValue!==null?ve:fm(O.oldValue);e(w.DOM_ATTR,{attr:O.attributeName,...Y===void 0?{}:{value:Y},...X===void 0?{}:{old:X}},re.refFor(k))}continue}if(O.type==="characterData"){let k=O.target.parentElement;if(k!==null&&!Hi(k)){if(u>=$d){f+=1;continue}u+=1;let j=pn(k),Y=j?ve:((m=O.target.textContent)!=null?m:"").trim().slice(0,80),X=j?void 0:fm((E=(h=O.oldValue)==null?void 0:h.trim())!=null?E:null);e(w.DOM_TEXT,{text:Y,...X===void 0?{}:{old:X},...Nk(k)},re.refFor(k))}continue}if(HS(O.addedNodes)!==void 0||HS(O.removedNodes)!==void 0){let k=wn(O.target)?O.target:null;if(k!==null&&!Hi(k))if(u>=$d)f+=1;else{u+=1;let j=pn(k),Y=j?ve:((_=k.textContent)!=null?_:"").trim().slice(0,80),X=j?void 0:fm((A=HS(O.removedNodes))!=null?A:null);e(w.DOM_TEXT,{text:Y,...X===void 0?{}:{old:X},...Nk(k)},re.refFor(k))}}for(let k of O.addedNodes){if(!wn(k))continue;if(a>=$d){f+=1;continue}if(Hi(k))continue;let j=[k,...Array.from(k.querySelectorAll(Vn()))].filter(be=>Ne(be)!==null);for(let be of j){let me=((v=be.textContent)!=null?v:"").trim();if(me.length===0)continue;if(d>=D3){f+=1;continue}d+=1;let it=pn(be)?ve:me.slice(0,80);e(w.DOM_TEXT,{text:it,testid:(N=Ne(be))!=null?N:"",initial:!0},re.refFor(be))}let Y=vk(k);if(Y===void 0)continue;let{role:X,name:G}=Y;a+=1;let ee=re.refFor(Y.el);e(w.DOM_ADDED,{role:X,name:G,region:Ak(O.target)},ee),(O3.has(X)||I3.has(X)||k.getAttribute("aria-modal")==="true")&&Je(k)&&e(w.VISIBLE_SHOWN,{role:X,name:G},ee)}for(let k of O.removedNodes){if(!wn(k))continue;if(l>=$d){f+=1;continue}if(Hi(k)||wn(O.target)&&Hi(O.target))continue;let j=vk(k);if(j===void 0)continue;let{role:Y,name:X}=j;l+=1,e(w.DOM_REMOVED,{role:Y,name:X,region:Ak(O.target)})}}f>0&&e(w.TRUNCATED,{channel:Bf.DOM,dropped:f})}),r={subtree:!0,childList:!0,attributes:!0,attributeFilter:R3,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0};n.observe(document.documentElement,r);for(let s of M0())n.observe(s,r);let o=H0(s=>n.observe(s,r)),i=xk(s=>n.observe(s,r));return()=>{i(),o(),t(),n.disconnect()}}M();Ys();ur();function Ok(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function M3(e,t){if(!Ok(e)||!Ok(t))return Object.is(e,t)?[]:[{path:"",old:e,new:t}];let n=[];for(let r of new Set([...Object.keys(e),...Object.keys(t)]))Object.is(e[r],t[r])||n.push({path:r,old:e[r],new:t[r]});return n}function Ik(e,t){return St(e)?ve:cd(t)}function Ck(e,t){if(Object.is(e,t))return!0;try{return JSON.stringify(e)===JSON.stringify(t)}catch{return!1}}function Lk(e){try{return e()}catch{return}}function $k(e){let t=new Map,n=([o,i,s])=>{var l;try{(l=t.get(o))==null||l()}catch{}let a=Lk(i);t.set(o,s(()=>{oe(()=>{let u=Lk(i),d=M3(a,u);a=u;for(let f of d){let m=Ik(f.path,f.new),h=Ik(f.path,f.old);(St(f.path)?Ck(cd(f.old),cd(f.new)):Ck(h,m))||oe(()=>e(w.STATE_CHANGE,{name:o,path:f.path,value:m,old:h}))}})}))};for(let o of SL())n(o);t.size===0&&e(w.BLIND_SPOT,{kind:cn.UNWATCHED_STATE,count:1});let r=EL(o=>{let i=t.size===0;n(o),i&&t.size>0&&e(w.BLIND_SPOT,{kind:cn.UNWATCHED_STATE,count:0})});return()=>{r();for(let o of t.values())try{o()}catch{}t.clear()}}M();Et();function Wc(e){if(!(e instanceof Element)||e===document.body)return;let t=Le(e),n=we(e);return n.length>0?`${t} "${n}"`:t}function U3(e){return e===null||e===document.body}function kk(e){let t=new AbortController,{signal:n}=t,r=null,o=s=>{let a=s.target,l=r;r=a,e(w.FOCUS_CHANGE,{...Wc(a)===void 0?{}:{to:Wc(a)},...Wc(l)===void 0?{}:{from:Wc(l)},toBody:U3(a)})},i=s=>{if(s.relatedTarget!==null)return;let a=r;r=null,e(w.FOCUS_CHANGE,{...Wc(a)===void 0?{}:{from:Wc(a)},toBody:!0})};return document.addEventListener("focusin",o,{signal:n}),document.addEventListener("focusout",i,{signal:n}),()=>t.abort()}M();function H3(e){let t=e;for(let n=0;n<3;n+=1){let r=Array.from(t.children).filter(i=>i instanceof HTMLElement),o=r.length===1?r[0]:void 0;if(o===void 0||o.offsetHeight<t.scrollHeight*.9)return t;t=o}return t}function F3(e){let t=e.scrollHeight,n=e.clientHeight;if(n<=0||t<n*1.2)return 0;let r=H3(e),o=Array.from(r.children).filter(m=>m instanceof HTMLElement);if(o.length<2)return 0;let i=1/0,s=0,a=0,l=e.getBoundingClientRect(),u=e.offsetHeight>0&&l.height>0?l.height/e.offsetHeight:1;for(let m of o){let h=(m.getBoundingClientRect().top-l.top)/u-e.clientTop+e.scrollTop,E=h+m.offsetHeight;h<i&&(i=h),E>s&&(s=E),a+=m.offsetHeight}let d=Math.max(0,i)+Math.max(0,t-s);if(d<t*.25)return 0;let f=a/o.length;return f<=0?0:Math.round(d/f)}function zk(){let e=0;for(let t of document.querySelectorAll("*"))t.scrollHeight<=t.clientHeight||(e+=F3(t));return e}Yo();dt();function B3(){var t;let e=0;for(let n of document.querySelectorAll("*"))n.tagName.includes("-")&&n.shadowRoot===null&&(U0(n)||n.children.length>0||((t=n.textContent)!=null?t:"").trim().length>0||n.offsetHeight<=0&&n.offsetWidth<=0||(e+=1));return e}function G3(e){let t=e.getAttribute("src");if(t===null||t.length===0)return!1;try{return e.contentDocument===null}catch{return!0}}function V3(e){let t=0;for(let n of e)G3(n)&&(t+=1);return t}function j3(){return V3(Array.from(document.querySelectorAll("iframe")))}function K3(){return US(document).length}var Z3=250;function Dk(e){let t=[{kind:cn.CROSS_ORIGIN_IFRAME,count:j3},{kind:cn.UNINSTRUMENTED_FRAME,count:K3},{kind:cn.CLOSED_SHADOW_ROOT,count:B3},{kind:cn.VIRTUALIZED_UNMOUNTED,count:zk}],n=new Map,r=()=>{for(let s of t){let a=s.count(),l=n.get(s.kind);a!==l&&(n.set(s.kind,a),(a>0||l!==void 0)&&e(w.BLIND_SPOT,{kind:s.kind,count:a}))}};r();let o,i=new MutationObserver(()=>{o===void 0&&(o=ue(()=>{o=void 0,r()},Z3))});return i.observe(document.documentElement,{childList:!0,subtree:!0}),()=>{o!==void 0&&Re(o),i.disconnect()}}M();Wo();M();ur();dt();M();ur();var W3=/^text\/event-stream(?:\s*;|\s*$)/i,FS="data:",Y3="data",X3=/^[{[]/,q3=/^\[[A-Z_]+\]$/;function Qi(e){return e!==null&&W3.test(e)}function Pk(e){return Y3===e||e.startsWith(FS)}function Mk(e){let t=!1;return{body:e.replace(/\r\n?/g,`
1824
+ `});var c5={};qa(c5,{HUD_CONTROL_SELECTORS:()=>i5,TOUR_SEEN_KEY_PREFIX:()=>yh,isLastSlide:()=>gA,mountTour:()=>AY,openedByReticle:()=>s5,safeLocalStorage:()=>yY,tourAlreadySeen:()=>a5,tourSeenKey:()=>EA});function SY(e,t){var s;let n=Number.POSITIVE_INFINITY,r=Number.POSITIVE_INFINITY,o=Number.NEGATIVE_INFINITY,i=Number.NEGATIVE_INFINITY;for(let a of t){let l=(s=e.querySelector(a))==null?void 0:s.getBoundingClientRect();l===void 0||l.width<=0||l.height<=0||(n=Math.min(n,l.left),r=Math.min(r,l.top),o=Math.max(o,l.left+l.width),i=Math.max(i,l.top+l.height))}if(o!==Number.NEGATIVE_INFINITY)return{left:n,top:r,width:o-n,height:i-r}}function TY(e,t){var r;if(st.HUD===t)return SY(e,_Y);let n=i5[t];if(n!==void 0){let o=(r=e.querySelector(n))==null?void 0:r.getBoundingClientRect();return o===void 0?void 0:o}if(st.APP===t)for(let o of bY){let i=e.querySelector(o);if(i===null)continue;let s=i.getBoundingClientRect();if(s.width>0)return s}}function s5(e){if(e===void 0||e==="")return!1;let t=new URLSearchParams(e.startsWith("?")?e.slice(1):e);return t.has(or.OPENED)||t.has(or.SESSION)||t.has(or.PROJECT)}function a5(e,t){if(e===void 0)return!0;try{return e.getItem(EA(t))!==null}catch{return!0}}function xY(e,t){try{e==null||e.setItem(EA(t),"1")}catch{}}function AY(e){var A;if(e.isDriving()||s5(e.search)||((A=e.navigator)==null?void 0:A.webdriver)===!0||a5(e.storage,e.projectId))return;let t=e.document,n=t.createElement("style");n.setAttribute(Te,""),n.textContent=r5,t.head.appendChild(n);let r=t.createElement("div");r.setAttribute(Te,"");let o=hA(),i=0,s=!0,a=()=>{},l=()=>{},u=()=>{s&&(s=!1,a(),l(),r.remove(),n.remove())},d=()=>{s&&(xY(e.storage,e.projectId),u())},f=()=>{e.isDriving()&&u()},m=()=>{var N,O,k,G;let w=o[i];if(w!==void 0&&(r.innerHTML=`<div class="reticle-tour-scrim"></div>${n5(w)}`,st.NONE!==w.anchor)){let V=TY(t,w.anchor);if(V!==void 0&&V.width>0){let W=st.APP===w.anchor,K=t.createElement("div");K.className=W?"reticle-tour-ring is-region":"reticle-tour-ring";let J=W?-2:6;if(K.style.left=`${String(Math.round(V.left-J))}px`,K.style.top=`${String(Math.round(V.top-J))}px`,K.style.width=`${String(Math.round(V.width+J*2))}px`,K.style.height=`${String(Math.round(V.height+J*2))}px`,r.appendChild(K),W||(N=r.querySelector(".reticle-tour-scrim"))==null||N.classList.add("is-clear"),e5(w)){K.classList.add("is-live"),(O=r.querySelector(".reticle-tour-scrim"))==null||O.remove();let le=t.defaultView;for(let ge of t5({left:V.left-J,top:V.top-J,width:V.width+J*2,height:V.height+J*2},(k=le==null?void 0:le.innerWidth)!=null?k:t.documentElement.clientWidth,(G=le==null?void 0:le.innerHeight)!=null?G:t.documentElement.clientHeight)){let Xe=t.createElement("div");Xe.className="reticle-tour-blocker",Xe.style.left=`${String(Math.round(ge.left))}px`,Xe.style.top=`${String(Math.round(ge.top))}px`,Xe.style.width=`${String(Math.round(ge.width))}px`,Xe.style.height=`${String(Math.round(ge.height))}px`,r.appendChild(Xe)}}}}},h=w=>{var K,J;let N=o[i],O=Number(w.getAttribute(Wp)),k=(K=N==null?void 0:N.prompts)==null?void 0:K[O];if(k===void 0)return;let G=(le,ge)=>{var Xe;w.textContent=le,w.classList.add(ge),(Xe=t.defaultView)==null||Xe.setTimeout(()=>{w.textContent=fA,w.classList.remove(ge)},Q2)},V=le=>{var Xe;if(le){G(q2,"is-done");return}let ge=r.querySelector(`.reticle-tour-prompt[${Wp}="${String(O)}"] .reticle-tour-prompt-text`);ge!==null&&((Xe=e.select)==null||Xe.call(e,ge)),G(J2,"is-manual")},W=(J=e.copy)==null?void 0:J.call(e,k.text);if(W===void 0){V(!1);return}if(typeof W=="boolean"){V(W);return}W.then(V).catch(()=>{V(!1)})};r.addEventListener("click",w=>{let N=w.target;if(!(N instanceof Element))return;let O=N.closest(`[${wi}]`);if(O===null)return;let k=O.getAttribute(wi);if(k===null)return;if(w.preventDefault(),w.stopPropagation(),k==="skip"||k==="done"){d();return}if(k==="copy"){h(O);return}let G=mA(i,k==="back"?-1:1);G!==i&&(i=G,m())});let E=w=>{if(!s||xh(t))return;let N=w.key==="ArrowRight"?1:w.key==="ArrowLeft"?-1:0;if(w.key==="Escape"){w.preventDefault(),d();return}if(N===0)return;let O=mA(i,N);O!==i&&(w.preventDefault(),i=O,m())};t.addEventListener("keydown",E),a=()=>{t.removeEventListener("keydown",E)},m(),t.body.appendChild(r);let S=t.querySelector("[data-reticle-overlay]");if(S!==null){let w=new MutationObserver(f);w.observe(S,{attributes:!0,attributeFilter:["data-reticle-mode"]}),l=()=>w.disconnect(),f()}return{destroy:d,isOpen:()=>s}}function yY(){try{return window.localStorage}catch{return}}var bY,_Y,i5,EA,l5=y(()=>{"use strict";o5();dA();M();ot();ho();bY=["main","#root","#app"],_Y=["[data-reticle-hud]","[data-reticle-chat-panel]"];i5={[st.HUD_CHAT]:"[data-reticle-chat-toggle]",[st.HUD_FLOWS]:'[data-reticle-chat-view-btn="flows"]',[st.HUD_ANNOTATE]:'[data-reticle-chat-view-btn="annotations"]',[st.HUD_IMPACT]:"[data-reticle-chat-impact]",[st.HUD_SETTINGS]:"[data-reticle-settings-btn]"};EA=e=>`${yh}${e}`});var MY={};qa(MY,{Annotator:()=>pa,RefRegistry:()=>id,Reticle:()=>hu,SESSION_AUTO:()=>ju,adapterNames:()=>Ed,buildSnapshot:()=>Mh,canvasChartData:()=>HC,commitAndSignal:()=>L5,createReticleEmitter:()=>C5,describe:()=>go,elementHasHoverHandlers:()=>kh,executeAction:()=>Cd,executeSequence:()=>lm,getAccessibleName:()=>Ae,getCapabilities:()=>Ki,getRole:()=>Re,getStates:()=>ti,hasCapabilities:()=>Vh,identifyComponent:()=>fr,inspectChart:()=>Rh,installAnnotator:()=>UD,isVisible:()=>Ke,jotaiStore:()=>A5,markAdapterSource:()=>Hh,matchQuery:()=>xd,mobxStore:()=>v5,piniaStore:()=>O5,pushStore:()=>I5,readComponentState:()=>$h,readStores:()=>DL,readStoresWithTruncation:()=>Sd,recoilStore:()=>N5,refs:()=>re,registerAdapter:()=>tL,registerCapabilities:()=>Cc,registerReticleDomain:()=>$5,registerStore:()=>$L,resolveMarkAnchor:()=>Gd,reticle:()=>mu,runQuery:()=>Wh,setCapabilitiesListener:()=>Gh,setIgnoreSelectors:()=>NC,sourceOwner:()=>ML,storeNames:()=>ji,svelteStore:()=>R5,tanstackQueryStore:()=>x5,trackShortTimers:()=>PY,unregisterStore:()=>kL,valtioStore:()=>w5,xstateStore:()=>y5});ot();M();Yo();function OC(e,t){t(Du,{delta:1});let n=()=>{t(Du,{delta:-1})};return e.then(n,n),e}var Y4=1e3;function IC(e,t=Y4){let n=ke(window,"setTimeout"),r=ke(window,"clearTimeout"),o=n.bind(window),i=r.bind(window),s=new Set,a=l=>{s.delete(l)&&e(Du,{delta:-1})};return window.setTimeout=((l,u=0,...d)=>{if(typeof l!="function"||u>t)return Reflect.apply(n,window,[l,u,...d]);e(Du,{delta:1});let f=o(()=>{a(f),l(...d)},u);return s.add(f),f}),window.clearTimeout=(l=>{l!==void 0&&a(l),i(l)}),()=>{window.setTimeout=n,window.clearTimeout=r}}M();function oe(e){try{e()}catch{}}function Zt(e){try{return e()}catch{return}}Yo();M();function X4(){return{pathname:location.pathname,search:location.search,hash:location.hash,href:location.href}}var CC=[];function LC(e){CC=e.map(t=>({pattern:t,parts:t.split("/").filter(Boolean)}))}function q4(){var t,n;let e=(n=(t=globalThis.next)==null?void 0:t.router)==null?void 0:n.pathname;if(!(typeof e!="string"||!e.startsWith("/")))return e.replace(/\[\.\.\.[^\]]+\]/g,"*").replace(/\[([^\]]+)\]/g,":$1")}function J4(e){var r;let t=e.split("/").filter(Boolean),n;for(let{pattern:o,parts:i}of CC){let s=i.at(-1)==="*",a=s?i.slice(0,-1):i;if((s?t.length<a.length:t.length!==a.length)||!a.every((u,d)=>u.startsWith(":")||u===t[d]))continue;let l=i.filter(u=>u.startsWith(":")||u==="*").length;(n===void 0||l<n.params)&&(n={pattern:o,params:l})}return(r=n==null?void 0:n.pattern)!=null?r:q4()}function $C(e){let t=new AbortController,n=ke(history,"pushState"),r=ke(history,"replaceState"),o=n.bind(history),i=r.bind(history),s=location.href,a=(f,m)=>{oe(()=>{let h=X4();if(h.href===f)return;s=h.href;let E=J4(h.pathname);e(v.ROUTE_CHANGE,{from:lr(f),to:lr(h.href),pathname:h.pathname,...E===void 0?{}:{pattern:E},search:lr(h.search),hash:lr(h.hash),[y_]:m})})},l=(f,m,h)=>{let E=location.href;o(f,m,h!=null?h:null),a(E,qu.PUSH)},u=(f,m,h)=>{let E=location.href;i(f,m,h!=null?h:null),a(E,qu.REPLACE)};history.pushState=l,history.replaceState=u;let d=()=>{a(s,qu.POP)};return window.addEventListener("popstate",d,{signal:t.signal}),window.addEventListener("hashchange",d,{signal:t.signal}),()=>{history.pushState===l&&(history.pushState=n),history.replaceState===u&&(history.replaceState=r),t.abort()}}M();Et();dn();var bj=new Set(["submit","button","reset","image"]);function _j(e){return ut(e)&&e.isContentEditable||e instanceof HTMLTextAreaElement?!0:e instanceof HTMLInputElement?!bj.has(e.type.toLowerCase()):!1}var Sj="A";function GC(e){if(Sj!==e.tagName)return;let t=e.getAttribute("href");return t===null||SI(t)?void 0:t}function VC(e){var o,i,s,a,l,u;let t=GC(e);if(t!==void 0)return t;let n=e.closest("form"),r=_j(e)?["",""]:[(o=e.textContent)!=null?o:"",(i=e.getAttribute("value"))!=null?i:""];return[Wu(Ae(e)),Wu(r.join(" ")),Wu((s=e.getAttribute("title"))!=null?s:""),Wu((a=e.getAttribute("aria-label"))!=null?a:""),(l=e.getAttribute("href"))!=null?l:"",(u=n==null?void 0:n.getAttribute("action"))!=null?u:""].join(" ")}var Tj='button[type="submit"], input[type="submit"], button:not([type]):not([type=""])';function jC(e){var n;let t=(n=e.closest("form"))==null?void 0:n.querySelector(Tj);return ut(t)?t:null}function Lh(e){let t=GC(e);return t!==void 0?TI(t):_I(VC(e),Re(e))}var hd;function oS(e){hd=e}function KC(e){if(hd!==void 0)for(let t of e){if(t===null)continue;let n=yI(VC(t),Re(t));if(n!==void 0&&!hd.includes(n))throw new Error(b_(n))}}function ZC(e){var n,r,o,i,s;if(hd===void 0||hd.includes(Tt.PAY))return;let t={autocomplete:(n=e.getAttribute("autocomplete"))!=null?n:void 0,name:(r=e.getAttribute("name"))!=null?r:void 0,id:(o=e.getAttribute("id"))!=null?o:void 0,inputMode:(i=e.getAttribute("inputmode"))!=null?i:void 0,label:`${Ae(e)} ${(s=e.getAttribute("placeholder"))!=null?s:""}`};if(AI(t))throw new Error(b_(Tt.PAY))}M();It();var WC=(e,t)=>Array.from(e.querySelectorAll(t)).some(n=>n.closest(Di)===null);function YC(e){return[...WC(e,`[${mc}]`)?[Vs.SOURCE]:[],...WC(e,jn())?[Vs.TESTID]:[]]}function XC(e){return e.buildPlugin||0<e.adapters.length||e.markers.includes(Vs.SOURCE)?[]:[oh]}M();ho();var qC=At.SESSION;function JC(e,t,n){var a;let r=()=>{try{let l=t==null?void 0:t.getItem(qC);return l!=null&&l.length>0?l:void 0}catch{return}},o=l=>{try{t==null||t.setItem(qC,l)}catch{}},i=e!==void 0&&e.length>0?e:void 0,s=(a=i!=null?i:r())!=null?a:n();return o(s),s}function QC(e){let t;try{t=e.top===e}catch{t=!1}if(t)try{return e.sessionStorage}catch{return}}gt();var xj="vite:afterUpdate",Aj=3,yj="no longer resolves to an element",wj="the code changed underneath it";function iS(e){return e!==null&&typeof e=="object"?e:void 0}function vj(e){var t;return typeof((t=iS(e))==null?void 0:t.on)=="function"}function Nj(e){var r,o;let t=(r=iS(e))==null?void 0:r.updates;if(!Array.isArray(t))return[];let n=[];for(let i of t){let s=(o=iS(i))==null?void 0:o.path;typeof s=="string"&&s.length>0&&!n.includes(s)&&n.push(s)}return n}var md,Nc,Rc,sS=class{constructor(t){x(this,md,0);x(this,Nc,[]);x(this,Rc);g(this,Rc,t)}get current(){return c(this,md)}observe(t){vj(t)&&t.on(xj,n=>this.applied(Nj(n)))}applied(t){g(this,md,c(this,md)+1),g(this,Nc,t.slice(0,Aj)),c(this,Rc).markEdited()}staleRefMessage(t){let n=`ref '${Pr(t)}' ${yj}`;if(!c(this,Rc).mintedBeforeLastEdit(t))return n;let r=c(this,Nc).length===0?"the page hot-updated":`${c(this,Nc).join(", ")} hot-updated`;return`${n} \u2014 ${r} after this ref was taken, so ${wj} and the framework replaced the node. Query again for a fresh ref: this is your own edit landing, not the app failing.`}};md=new WeakMap,Nc=new WeakMap,Rc=new WeakMap;var gd=new sS(re);M();M();qo();dn();Et();Dr();gt();It();ni();gt();Et();ot();var cS={CLIPPED:"clipped",OVERLAP:"overlap",CONTRAST:"contrast"},lS=20,Rj=300,Oj=60,nL=1,rL=.25,Ij=4.5,Cj=3,Lj=24,$j=18.66,kj=700,zj='button, a[href], input:not([type="hidden"]), select, textarea, [role="button"], [role="link"], [role="tab"], [role="menuitem"]',oL=/rect\(\s*0(px)?[\s,]+0(px)?[\s,]+0(px)?[\s,]+0(px)?\s*\)|inset\(\s*50%/,iL=4,sL=e=>{let t=e.getBoundingClientRect();if(t.width<iL||t.height<iL)return null;let n=getComputedStyle(e);return n.visibility==="hidden"||n.display==="none"||n.opacity==="0"||oL.test(n.clip)||oL.test(n.clipPath)?null:t},aL=e=>{var t;return(Ae(e)||((t=e.textContent)!=null?t:"")).replace(/\s+/g," ").trim().slice(0,Oj)},Dj=e=>[...e.childNodes].filter(t=>Node.TEXT_NODE===t.nodeType).map(t=>{var n;return(n=t.textContent)!=null?n:""}).join("").trim(),cL=new Set(["hidden","clip"]),Pj=e=>{let t=getComputedStyle(e),n=e.scrollWidth>e.clientWidth+nL&&cL.has(t.overflowX),r=e.scrollHeight>e.clientHeight+nL&&cL.has(t.overflowY);return t.textOverflow==="ellipsis"||t.getPropertyValue("-webkit-line-clamp")!==""&&t.getPropertyValue("-webkit-line-clamp")!=="none"||!n&&!r?null:n?{detail:`${String(e.scrollWidth)}px of text in a ${String(e.clientWidth)}px box, cut with no ellipsis`,value:e.scrollWidth,bound:e.clientWidth}:{detail:`${String(e.scrollHeight)}px of text in a ${String(e.clientHeight)}px box, cut with no line clamp`,value:e.scrollHeight,bound:e.clientHeight}},Mj=/rgba?\(\s*([\d.]+)[\s,]+([\d.]+)[\s,]+([\d.]+)(?:[\s,/]+([\d.]+%?))?\s*\)/,dL=e=>{let t=Mj.exec(e);if(t===null)return null;let n=t[4],r=1;return n!==void 0&&(r=n.endsWith("%")?Number(n.slice(0,-1))/100:Number(n)),[Number(t[1]),Number(t[2]),Number(t[3]),r]},lL=([e,t,n])=>{let r=o=>{let i=o/255;return i<=.03928?i/12.92:((i+.055)/1.055)**2.4};return .2126*r(e)+.7152*r(t)+.0722*r(n)},pL=(e,t)=>{let n=e[3];return[e[0]*n+t[0]*(1-n),e[1]*n+t[1]*(1-n),e[2]*n+t[2]*(1-n),1]},Uj=e=>{let t=[];for(let n=e;n!==null;n=n.parentElement){let r=getComputedStyle(n);if(r.backgroundImage!=="none"&&r.backgroundImage!=="")return null;let o=dL(r.backgroundColor);if(o!==null&&o[3]>0&&(t.push(o),o[3]===1))break}return t.reduceRight((n,r)=>pL(r,n),[255,255,255,1])},Hj=e=>{let t=getComputedStyle(e),n=dL(t.color),r=Uj(e);if(n===null||r===null)return null;let o=pL(n,r),[i,s]=[lL(o),lL(r)].sort((d,f)=>f-d),a=Number.parseFloat(t.fontSize),l=Number.parseInt(t.fontWeight,10),u=a>=Lj||a>=$j&&l>=kj;return{ratio:(i+.05)/(s+.05),min:u?Cj:Ij}},fL=(e,t,...n)=>{if(typeof document.elementFromPoint!="function")return!0;let r=document.elementFromPoint(e,t);return r!==null&&n.some(o=>o===r||o.contains(r))},Gi=2,uL=(e,t)=>[[t.left+t.width/2,t.top+t.height/2],[t.left+Gi,t.top+Gi],[t.right-Gi,t.top+Gi],[t.left+Gi,t.bottom-Gi],[t.right-Gi,t.bottom-Gi]].some(([n=0,r=0])=>fL(n,r,e)),Fj=(e,t)=>{let n=Math.min(e.right,t.right)-Math.max(e.left,t.left),r=Math.min(e.bottom,t.bottom)-Math.max(e.top,t.top);return n<=0||r<=0?0:n*r/Math.min(e.width*e.height,t.width*t.height)};function hL(e=document.body){let t=[],n=(o,i,s)=>{t.length<lS&&t.push({kind:o,ref:re.refFor(i),what:aL(i),...s})};for(let o of e.querySelectorAll("*")){if(t.length>=lS)break;if(Ot(o)||Dj(o)==="")continue;let i=sL(o);if(i===null||!fL(i.left+i.width/2,i.top+i.height/2,o))continue;let s=Pj(o);s!==null&&n(cS.CLIPPED,o,s);let a=Hj(o);a!==null&&a.ratio<a.min&&n(cS.CONTRAST,o,{detail:`contrast ${a.ratio.toFixed(2)}:1, under ${String(a.min)}:1`,value:Math.round(a.ratio*100)/100,bound:a.min})}let r=[...e.querySelectorAll(zj)].filter(o=>!Ot(o)).slice(0,Rj).flatMap(o=>{let i=sL(o);return i===null?[]:[{el:o,rect:i}]});for(let[o,i]of r.entries())for(let s of r.slice(o+1)){if(t.length>=lS)return t;if(i.el.contains(s.el)||s.el.contains(i.el))continue;let a=Fj(i.rect,s.rect);a>=rL&&uL(i.el,i.rect)&&uL(s.el,s.rect)&&n(cS.OVERLAP,i.el,{detail:`drawn over "${aL(s.el)}" (${re.refFor(s.el)})`,value:Math.round(a*100)/100,bound:rL})}return t}bd();ot();var Vi=new Set(["button","link","textbox","searchbox","checkbox","radio","combobox","listbox","slider","spinbutton","switch","tab","menuitem","option"]),Bj=new Set(["script","style","noscript","template","head","meta","link"]),Gj=new Set(["alert","status"]);function EL(e,t){if(Gj.has(t))return!0;let n=e.getAttribute("aria-live");return n!==null&&n!=="off"}var mL=80;function Vj(e){let t=bL(e),n=(t.own?t.text:"").replace(/\s+/g," ").trim();return n.length>mL?`${n.slice(0,mL)}\u2026`:n}function bL(e){var r,o;let t="",n=!1;for(let i of e.childNodes)if(i.nodeType===3)t+=(r=i.textContent)!=null?r:"",n||(n=0<((o=i.textContent)!=null?o:"").trim().length);else if(wn(i)&&SL(i)){let s=bL(i);t+=s.text,n||(n=s.own)}else wn(i)&&_L(i)&&Vi.has(Re(i))&&(t+=Ae(i));return{text:t,own:n}}function _L(e){let t=e.ownerDocument.defaultView,n=e.parentElement;if(t===null||n===null)return!1;let r=t.getComputedStyle(n).display;return r.includes("flex")||r.includes("grid")?!1:t.getComputedStyle(e).display==="inline"}function SL(e){if(xL(e)||!_L(e))return!1;let t=Re(e);return!Vi.has(t)&&!EL(e,t)&&Ae(e).length===0}var jj=50;function TL(e){return e.getAttribute("aria-hidden")==="true"?!0:e instanceof HTMLElement&&e.hidden}function xL(e){return Bj.has(e.tagName.toLowerCase())||Ot(e)?!0:TL(e)}function Kj(e){let t=ti(e).filter(n=>n===Se.DISABLED||n===Se.CHECKED||n===Se.EXPANDED||n===Se.PRESSED||n===Se.FOCUSED);return t.length>0?` [${t.join(",")}]`:""}function Zj(e,t,n,r,o,i="",s=!1){let a=" ".repeat(t),l=rS(e),u=r,d=u.length>0?` "${u}"`:"",f=Vi.has(n)||u.length>0?` (ref=${re.refFor(e)})`:"",m=l!==void 0&&l.length>0?` [value="${l}"]`:"",h=o.length>0?` [${o}]`:"",E=i.length>0?` [text="${i}"]`:"",S=s?Ne(e):null,A=s?fr(e):null,w=S===null?A==null?void 0:A.componentStack[0]:void 0,N=A==null?void 0:A.source,O="";S!==null?O=` [testid=${S}]`:w!==void 0&&(O=` [component=${w}]`);let k=`${O}${N===void 0?"":` [src=${N.file}:${String(N.line)}]`}`;return`${a}- ${n}${d}${f}${m}${E}${h}${Kj(e)}${k}`}function Wj(e,t){return`${" ".repeat(e)}- text "${t}"`}function Yj(e){if(e===null)return"";let t=e.display;if(t==="grid"||t==="inline-grid"){let n=e.gridTemplateColumns;return n!==""&&n!=="none"?`grid-cols:${n}`:"grid"}return""}var AL=e=>e.hasAttribute("data-aria-hidden")&&e.getAttribute("aria-hidden")==="true";function gL(e,t){for(let n of e){if(t.unread.length>=jj){t.unreadOverflow=!0;return}t.unread.push(re.refFor(n))}}function Xj(e){var r,o;let t=[...e.children],n=(r=e.shadowRoot)!=null?r:Zs(e);if(n!==null&&t.push(...n.children),bh(e))try{let i=(o=e.contentDocument)==null?void 0:o.body;i!=null&&t.push(...i.children)}catch{}return t}function uS(e,t,n,r){if(!(n.throughOverlay===!0&&AL(e)&&!Ot(e)&&!(e instanceof HTMLElement&&e.hidden))&&xL(e)){TL(e)&&(n.hiddenSkipped+=1);return}let i=e.ownerDocument.defaultView,s=i!==null?i.getComputedStyle(e):null;if(s!==null&&s.display==="none"){n.hiddenSkipped+=1;return}if(s!==null&&s.display==="inline"&&!r&&SL(e)){Ph(e,t,n,r);return}let a=Re(e),l=Ae(e),u=Vi.has(a),d=r||EL(e,a),f=n.mode===dc.INTERACTIVE&&!d,m=!f&&l.length===0?Vj(e):"",h=f?"":Yj(s),E=u,S=E||a!=="generic"||l.length>0||m.length>0||h.length>0,A=f?E:S;f&&!A&&S&&(n.leanSkipped+=1),A?(n.nodes+=1,n.lines.push(a==="generic"&&m.length>0&&h.length===0?Wj(t,m):Zj(e,t,a,l,h,m,n.ids===!0)),Ph(e,t+1,n,d)):Ph(e,t,n,d)}function Ph(e,t,n,r=!1){let o=Xj(e);if(t>n.maxDepth){o.length>0&&(n.truncated=!0,gL([e],n));return}for(let i=0;i<o.length;i+=1){if(n.nodes>=n.maxNodes){n.truncated=!0,gL(o.slice(i),n);return}let s=o[i];s!==void 0&&uS(s,t,n,r)}}function qj(e){let t=e.querySelectorAll('[role="dialog"], dialog[open], [aria-modal="true"]'),n=[];for(let r of t)Rt(r)||Ke(r)&&n.push(Ae(r)||"(unnamed dialog)");return n}var Jj='[role="dialog"], [role="alertdialog"], dialog[open], [aria-modal="true"]';function Qj(e){if(e!==document.body)return;let t=document.body.querySelectorAll('[role="dialog"], dialog[open], [aria-modal="true"]'),n,r;for(let s of t)if(!Rt(s)){if(Ke(s)){n=s;break}r!=null||(r=s)}if(n!=null||(n=r),n===void 0)return;let o=n,i=Array.from(document.body.children).filter(s=>!s.contains(o));if(i.length!==0&&i.every(s=>s.getAttribute("aria-hidden")==="true"))return"the rest of the page is aria-hidden behind an open overlay (a focus-trap modal), so this snapshot shows only the overlay. If it will not close its cleanup may be stuck on a throttled tab: dismiss the overlay, or snapshot with { scope } inside it."}function e6(e){let t=qj(e),n=Qj(e);return{route:Dh(),title:document.title,...t.length>0?{visibleDialogs:t}:{},...n!==void 0?{overlayHidingPage:n}:{}}}function Mh(e={}){var l,u,d,f;let t=(l=e.mode)!=null?l:dc.FULL,n=(u=e.scope)==null?void 0:u.trim(),r=document.body;if(n!==void 0&&n!==""&&(r=re.resolve(n),r===null))try{r=document.querySelector(n)}catch{}let o=r===null,i=r!=null?r:document.body,s=e6(i);if(o)return{tree:"",status:s,nodes:0,truncated:!1,scopeMissing:!0};if(t===dc.STATUS)return{tree:"",status:s,nodes:0,truncated:!1};let a={lines:[],nodes:0,leanSkipped:0,hiddenSkipped:0,truncated:!1,mode:t,maxNodes:(d=e.maxNodes)!=null?d:400,maxDepth:(f=e.maxDepth)!=null?f:20,unread:[],unreadOverflow:!1,...e.ids===!0?{ids:!0}:{}};if(e.includeRoot===!0?uS(i,0,a,!1):Ph(i,0,a),a.nodes===0&&i===document.body){a.throughOverlay=!0;for(let m of Array.from(i.children))AL(m)&&m.querySelector(Jj)!==null&&uS(m,0,a,!1);a.throughOverlay=!1}return{tree:a.lines.join(`
1825
+ `),status:s,nodes:a.nodes,truncated:a.truncated,...a.nodes===0?{domElements:i.querySelectorAll("*").length}:{},...a.leanSkipped>0?{leanSkipped:a.leanSkipped}:{},...a.hiddenSkipped>0?{hiddenSkipped:a.hiddenSkipped}:{},...a.unread.length>0?{unread:a.unread}:{},...a.unreadOverflow?{unreadOverflow:!0}:{},...e.audit===!0?{audit:hL(i)}:{}}}V_();M();dn();qo();Et();Dr();ot();pr();Zi();gt();It();It();function GL(e){let t=c6(e);if(t===void 0)return;let n=e.ownerDocument.querySelectorAll(t);return n.length===1&&n[0]===e?t:void 0}function c6(e){let t=Ne(e);if(t!==null&&0<t.length){let r=t.replace(/\\/g,"\\\\").replace(/"/g,'\\"');return`[${Fi()}="${r}"]`}let n=e.getAttribute("id");if(n!==null&&/^[A-Za-z_][A-Za-z0-9_-]*$/.test(n))return`#${n}`}qo();Dr();function Lc(e){return e.replace(/\s+/g," ").trim().normalize("NFC")}var l6=/[\u2018\u2019]/g,u6=/[\u201c\u201d]/g,d6=/[\u2013\u2014]/g;function $c(e){return e.replace(l6,"'").replace(u6,'"').replace(d6,"-")}function hr(e){return $c(Lc(e))}function Wi(e,t){return hr(e).toLowerCase().includes(hr(t).toLowerCase())}function kc(e,t,n){return t.matchCase!==!0?Wi(e,n):hr(e).includes(hr(n))}function WL(e,t){return hr(e)===hr(t)}var bS={uppercase:e=>e.toUpperCase(),lowercase:e=>e.toLowerCase(),capitalize:e=>e.replace(/(^|\s)(\p{L})/gu,(t,n,r)=>n+r.toUpperCase())};function YL(e,t){var r,o,i;let n=(o=(r=e.ownerDocument.defaultView)==null?void 0:r.getComputedStyle(e).textTransform)!=null?o:"";return(i=bS[n])==null?void 0:i.call(bS,t)}var p6=1.5,f6=.05,h6=[255,255,255,1];function VL(e){let t=/^rgba?\(\s*([\d.]+)[\s,]+([\d.]+)[\s,]+([\d.]+)(?:[\s,/]+([\d.]+))?\s*\)$/.exec(e);if(t!==null)return[Number(t[1]),Number(t[2]),Number(t[3]),t[4]===void 0?1:Number(t[4])]}function jL(e,t){let n=e[3],r=(o,i)=>o*n+i*(1-n);return[r(e[0],t[0]),r(e[1],t[1]),r(e[2],t[2]),1]}function _S(e){let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4}function KL(e){return .2126*_S(e[0])+.7152*_S(e[1])+.0722*_S(e[2])}function m6(e,t){let n=KL(e),r=KL(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function ZL(e){return`rgb(${[e[0],e[1],e[2]].map(t=>String(Math.round(t))).join(", ")})`}function g6(e){let t=Number.parseFloat(e.getPropertyValue("-webkit-text-stroke-width"));return/\dpx/.test(e.textShadow)||t>0}function E6(e){let t=e.ownerDocument.defaultView;if(t===null)return;let n=t.getComputedStyle(e),r=VL(n.color);if(r===void 0||g6(n))return;let o=1,i=[],s=!1;for(let d=e;d!==null;d=Xo(d)){let f=t.getComputedStyle(d),m=Z_(d)?1:Number.parseFloat(f.opacity);if(o*=Number.isNaN(m)?1:m,s)continue;if(f.backgroundImage!==""&&f.backgroundImage!=="none")return;let h=VL(f.backgroundColor);if(h===void 0)return;h[3]>0&&i.push(h),s=h[3]>=1}if(o<f6)return`the composed opacity is ${o.toFixed(2)}`;let a=i.reduceRight((d,f)=>jL(f,d),h6),l=jL(r,a),u=m6(l,a);if(!(u>=p6))return`text ${ZL(l)} on ${ZL(a)}: contrast ${u.toFixed(2)}:1`}function XL(e){let t=e.map(E6);return t.length>0&&t.every(n=>n!==void 0)?t[0]:void 0}bd();M();dn();Et();Dr();ni();It();var o$=mc,b6=2e3,_6=()=>`[${o$}], ${jn()}, button, a, input, select, textarea, [role]`;function Rn(e){return[...Node.ELEMENT_NODE===e.nodeType?[e]:[],...Array.from(e.querySelectorAll("*"))]}var S6=["script","style","template","noscript"];function SS(e){return S6.includes(e.tagName.toLowerCase())}function T6(e){if(He(e)){let t=e.type.toLowerCase();if(t==="submit"||t==="button"||t==="reset")return e.value}return SS(e)?"":Array.from(e.childNodes).filter(t=>Node.TEXT_NODE===t.nodeType).map(t=>{var n;return(n=t.textContent)!=null?n:""}).join("")}function x6(e){if(He(e)||vn(e)||zr(e))return!0;let t=e.tagName.toLowerCase();return t==="button"||t==="meter"||t==="output"||t==="progress"||e.hasAttribute("aria-label")||e.hasAttribute("aria-labelledby")}function A6(e,t){let n=`${t.file}:${t.line}:`.replace(/\\/g,"\\\\").replace(/"/g,'\\"');try{return Array.from(e.querySelectorAll(`[${o$}^="${n}"]`))}catch{return[]}}function y6(e,t){let n=[],r=0;for(let o of Array.from(e.querySelectorAll(_6()))){if(r>=b6)break;r+=1;let i=fr(o);i!==null&&i.componentStack[0]===t&&n.push(o)}return n}function qL(e,t){if(t.source!==void 0){let n=A6(e,t.source);if(n.length>0)return n}return t.component!==void 0&&t.component.length>0?y6(e,t.component):[]}function w6(e,t){return e===t||t==="textbox"&&e==="searchbox"}var v6="option",N6="option",R6="select",JL=1;function TS(e){if(N6!==e.localName)return!1;let t=e.closest(R6);return zr(t)?Ke(t)?O6(t):!0:!1}function O6(e){let t=e.getBoundingClientRect();return t.width>0&&t.height>0&&t.width<=JL&&t.height<=JL}function I6(e,t){if(v6!==e)return t;let n=t.filter(r=>!TS(r));return n.length===t.length?t:n}function jh(e,t,n){let r=Rn(e).filter(o=>w6(Re(o),t)&&(n===void 0||WL(Ae(o),n)));return I6(t,r)}function QL(e,t,n){return Rn(e).filter(r=>{let o=T6(r);if(kc(o,n,t))return!0;if(n.matchCase!==!0||!Wi(o,t))return!1;let i=YL(r,o);return i!==void 0&&kc(i,n,t)})}function e$(e,t){let n=hr(t).toLowerCase(),r=[],o=[];for(let i of Rn(e)){if(!x6(i))continue;let s=hr(Ae(i)).toLowerCase();s.includes(n)&&(s===n?r:o).push(i)}return r.length>0?r:o}function t$(e,t){return Rn(e).filter(n=>{let r=n.getAttribute("placeholder");return r!==null&&Wi(r,t)})}function n$(e,t){return Rn(e).filter(n=>Ne(n)===t)}function r$(e,t){return Rn(e).filter(n=>{let r=n.getAttribute("alt");return r!==null&&Wi(r,t)})}function xS(e,t){var o;let n=t.by,r=t.value;if(n!==void 0&&r!==void 0)switch(n){case Je.ROLE:return jh(e,r,t.name);case Je.TEXT:return QL(e,r,t);case Je.LABEL:return e$(e,r);case Je.PLACEHOLDER:return t$(e,r);case Je.TESTID:return n$(e,r);case Je.ALT:return r$(e,r);case Je.COMPONENT:return qL(e,{...t,component:(o=t.component)!=null?o:r});default:throw new Error(`unsupported query strategy '${String(n)}' - use one of: ${Object.values(Je).join(", ")}`)}return t.component!==void 0||t.source!==void 0?qL(e,t):t.role!==void 0?jh(e,t.role,t.name):t.text!==void 0?QL(e,t.text,t):t.label!==void 0?e$(e,t.label):t.placeholder!==void 0?t$(e,t.placeholder):t.testid!==void 0?n$(e,t.testid):t.alt!==void 0?r$(e,t.alt):[]}var C6=12;function Td(e,t){var i;if(SS(e)||od(e))return"";let n=Ke(e,t),r=L6(e),o="";for(let s of Array.from(e.childNodes))if(Node.TEXT_NODE===s.nodeType&&n)o+=(i=s.textContent)!=null?i:"";else if(wn(s)){let a=Td(s,t);o+=r||$6(s)?` ${a} `:a}return o}function L6(e){var n,r;let t=(r=(n=e.ownerDocument.defaultView)==null?void 0:n.getComputedStyle(e).display)!=null?r:"";return t.includes("flex")||t.includes("grid")}function $6(e){var n,r;let t=(r=(n=e.ownerDocument.defaultView)==null?void 0:n.getComputedStyle(e).display)!=null?r:"inline";return!t.startsWith("inline")&&t!=="contents"}function Zh(e){if(e===void 0)return{container:document.body,scopeMissing:!1};let t=re.resolve(e);if(Jo(t))return{container:t,scopeMissing:!1};try{let n=document.querySelector(e);if(Jo(n))return{container:n,scopeMissing:!1}}catch{}return{container:null,scopeMissing:!0}}function k6(e){var t,n;try{return(n=(t=e.contentDocument)==null?void 0:t.body)!=null?n:null}catch{return null}}var z6=3;function D6(e){let t=[],n=(r,o)=>{var i;for(let s of r.querySelectorAll("*")){let a=(i=s.shadowRoot)!=null?i:Zs(s);if(a!==null){t.push(a),n(a,o);continue}if(o>=z6||!bh(s))continue;let l=k6(s);l!==null&&(t.push(l),n(l,o+1))}};return n(e,0),t}function a$(e){let{container:t,scopeMissing:n}=Zh(e.scope);if(t===null)return{candidates:[],scopeMissing:!0};if(e.self===!0)return e.scope===void 0?{candidates:[],scopeMissing:n}:e.text!==void 0&&!kc(Td(t,new Map),e,e.text)?{candidates:[],scopeMissing:n}:{candidates:Ot(t)?[]:[t],scopeMissing:n};let r=new Set,o=[],i=Kh(e)===void 0?Ot:od,s=a=>{for(let l of a)r.has(l)||i(l)||(r.add(l),o.push(l))};s(xS(t,e));for(let a of D6(t))s(xS(a,e));return{candidates:o,scopeMissing:n}}var P6=512,M6=12;function U6(e,t){let n={};for(let r of t.slice(0,M6)){let o=e.getAttribute(r);o!==null&&(n[r]=St(r)?ve:o.slice(0,P6))}return Object.keys(n).length>0?n:void 0}function H6(e,t,n){return Se.IN_VIEWPORT===t?W_(e,n):ti(e,Ke(e,n)).includes(t)}var AS=Z.MAX_COLLECTION_ITEMS;function xd(e,t,n=AS,r=!0,o=!0,i=!1){let s=a$(e),a=s.scopeMissing,l=r&&j6(e)?Kh(e):void 0,u=s.candidates.length===0?Zh(e.scope).container:null,d=u===null||l===void 0?void 0:c$(u,l,e),f=d===void 0?s.candidates:[d],m=new Map,h=t===void 0?f:f.filter(G=>H6(G,t,m)),E=e.attrs,S=i?Math.min(AS,Z.MAX_FULL_TEXT_ELEMENTS):AS,A=h.slice(0,Math.max(0,Math.min(n,S))),w=A.length>1||Se.IN_VIEWPORT===t,N=A.map(G=>{let V=go(G,m,i);if(w&&W_(G,m)&&!V.states.includes(Se.IN_VIEWPORT)&&(V={...V,states:[...V.states,Se.IN_VIEWPORT]}),E===void 0||E.length===0)return V;let W=U6(G,E);return W===void 0?V:{...V,attrs:W}}),O=RC(h),k=Kh(e)===void 0?void 0:XL(A);return{matched:h.length>0,count:h.length,elements:N,...i?{fullText:!0}:{},...a?{scopeMissing:!0}:{},...O===void 0?{}:{coveredBy:O},...k===void 0?{}:{unreadable:k},...h.length===0?{hint:l$(e,t,o)}:{}}}function F6(e){let t=e.getAttribute("aria-labelledby");if(t===null)return;let n=t.split(/\s+/).map(r=>{var o,i,s;return r.length>0&&(s=(i=(o=e.ownerDocument.getElementById(r))==null?void 0:o.textContent)==null?void 0:i.trim())!=null?s:""}).filter(r=>r.length>0).join(" ");return n.length>0?n:void 0}function B6(e){var o,i,s,a,l,u,d,f;let t=(o=Zh(e.scope).container)!=null?o:document.body,n=[],r=["list","listbox","grid","table","tree","treegrid","dialog","alertdialog","navigation","main","banner","form","search","menu","menubar","tablist"];for(let m of r){let h=jh(t,m,void 0);for(let E of h){if(Rt(E))continue;let S=(a=(s=(i=E.getAttribute("aria-label"))!=null?i:F6(E))!=null?s:Ne(E))!=null?a:void 0,A=E.querySelectorAll("[role]"),w=[];for(let O of Array.from(A)){if(w.length>=3)break;let k=O.getAttribute("role"),G=(f=(d=(l=O.getAttribute("aria-label"))!=null?l:Ne(O))!=null?d:(u=O.textContent)==null?void 0:u.trim().slice(0,40))!=null?f:"";k!==null&&G.length>0&&w.push(`${k}[${G}]`)}let N={role:m,childCount:A.length,sample:w};if(S!==void 0&&S.length>0&&(N.name=S),n.push(N),n.length>=10)return n}}return n}function c$(e,t,n){let r,o=-1,i=new Map;for(let s of Rn(e)){if(Ot(s)||!kc(Td(s,i),n,t))continue;let a=0;for(let l=s.parentElement;l!==null;l=l.parentElement)a++;a>o&&(r=s,o=a)}return r}function G6(e,t){let n=hr(t).toLowerCase();if(n.length===0)return;let r=new Map;for(let o of Rn(e)){if(Ot(o))continue;let i=Lc(Td(o,r)),s=$c(i).toLowerCase().indexOf(n);if(s!==-1)return i.slice(s,s+n.length)}}var V6=new Set(["text","matchCase","scope","by","value"]);function j6(e){return(e.by===void 0||Je.TEXT===e.by)&&Object.keys(e).every(t=>V6.has(t))}function Kh(e){return e.text!==void 0?e.text:Je.TEXT===e.by?e.value:void 0}var K6=5;function Z6(e,t){let n=Je.ROLE===t.by?t.value:t.role,r=t.name;if(n===void 0||r===void 0||r.length===0)return[];let o=hr(r).toLowerCase();if(o.length===0)return[];let i=[];for(let s of Rn(e)){if(Ot(s)||Re(s)!==n)continue;let a=Lc(Ae(s));if(a.length===0)continue;let l=$c(a).toLowerCase();if(!(!l.includes(o)&&!o.includes(l))&&(i.includes(a)||i.push(a),i.length>=K6))break}return i}var W6=3,i$=60;function s$(e){let t=` ${e} `,n=new Set;for(let r=0;r<t.length-1;r+=1)n.add(t.slice(r,r+2));return n}function Y6(e,t){let n=s$($c(e).toLowerCase()),r=s$($c(t).toLowerCase()),o=0;for(let i of n)r.has(i)&&(o+=1);return 2*o/(n.size+r.size)}function X6(e){return Je.ROLE===e.by?e.value:e.role}function q6(e){var r,o,i,s,a,l;let t=Je.ROLE===e.by?void 0:e.value,n=(l=(a=(s=(i=(o=(r=e.name)!=null?r:t)!=null?o:e.text)!=null?i:e.label)!=null?s:e.placeholder)!=null?a:e.testid)!=null?l:e.alt;return n===void 0?"":Lc(n)}function J6(e,t){let n=X6(t),r=q6(t);if(n===void 0&&r.length===0)return[];let o=new Map,i=[];for(let s of Rn(e)){let a=Re(s),l=n!==void 0&&a===n;if(!l&&!Vi.has(a)||Ot(s)||!Ke(s,o))continue;let u=Lc(Ae(s));if(u.length===0)continue;let d=r.length===0?0:Y6(r,u);!l&&d===0||i.push({el:s,role:a,name:u,roleMatch:l,score:d})}return i.sort((s,a)=>Number(a.roleMatch)-Number(s.roleMatch)||a.score-s.score),i.slice(0,W6).map(s=>{let a={ref:re.refFor(s.el),role:s.role,name:s.name.slice(0,i$)};return s.name.length>i$&&(a.nameTruncated=!0),a})}function Q6(e,t){if(Je.TESTID!==t.by||t.value===void 0)return;let n=Fi();for(let r of[Hs,...LO]){if(r===n)continue;if(Rn(e).some(i=>i.getAttribute(r)===t.value&&!Ot(i)))return r}}function eK(e,t){var o;let n=!1;for(let i of Rn(e))if(!Ot(i)&&mC(i)&&Wi((o=i.textContent)!=null?o:"",t)){n=!0;break}if(!n)return!1;let r=new Map;for(let i of Rn(e))if(!Ot(i)&&gC(i)&&Wi(Td(i,r),t))return!1;return!0}function l$(e,t,n=!0){var S;let r=(S=Zh(e.scope).container)!=null?S:document.body,o=r.querySelectorAll(jn()),i=[],s=new Set;for(let A of Array.from(o)){if(Ot(A))continue;let w=Ne(A);w===null||w.length===0||s.has(w)||(s.add(w),i.length<C6&&i.push(w))}let a=BL(),l=i.some(A=>a.includes(A)),d={route:Dh(!1),presentTestids:i,...s.size>i.length?{presentTestidsTotal:s.size}:{},presentRegions:B6(e),knownEmptyState:l},f=Kh(e);if(f!==void 0){let A=c$(r,f,e);if(A!==void 0){let w=go(A),N=GL(A);d.splitText=N===void 0?w:{...w,selector:N}}else if(e.matchCase===!0){let w=G6(r,f);w!==void 0&&(d.caseMiss=w)}}n&&f!==void 0&&d.splitText===void 0&&(t===void 0||Se.VISIBLE===t||Se.IN_VIEWPORT===t)&&eK(r,f)&&(d.ariaHiddenMatch=!0);let m=Z6(r,e);m.length>0&&(d.nameNearMiss=m);let h=Q6(r,e);h!==void 0&&(d.testidFoundUnder=h);let E=n?J6(r,e):[];return E.length>0&&(d.nearest=E),d}function yS(e){return a$(e).candidates}function Wh(e,t){var o;let n=xd(e,void 0,t,!1),r=n.scopeMissing===!0?{scopeMissing:!0}:{};return n.elements.length===0?{elements:n.elements,count:n.count,hint:(o=n.hint)!=null?o:l$(e),...r}:{elements:n.elements,count:n.count,...r}}M();ot();zc();gt();Yo();dn();var tK=/\b(current|new)-password\b/,nK=/Chrome|Chromium|Edg\/|Firefox|Gecko\//;function vS(e,t=navigator.userAgent){var r,o,i;return!(e instanceof HTMLInputElement)||!(e.type.toLowerCase()==="password"||tK.test((r=e.getAttribute("autocomplete"))!=null?r:""))||nK.test(t)?!1:600<=Number((i=(o=/AppleWebKit\/(\d+)/.exec(t))==null?void 0:o[1])!=null?i:0)}function Xh(e,t){let n=sC(e),r=n===void 0?void 0:Z0(n);r!==void 0?r.call(e,t):e.value=t;let o=e.dispatchEvent(new Event("input",{bubbles:!0,cancelable:!0}));return e.dispatchEvent(new Event("change",{bubbles:!0})),!o}function rK(e){let t=e.getAttribute("contenteditable");if(ut(e)&&e.isContentEditable||t!==null&&t!=="false"||e.getAttribute("role")==="textbox")return!0;if(!("editContext"in e))return!1;let n=e;return n.editContext!==null&&n.editContext!==void 0}function NS(e,t){if(rK(e))throw new Error(`cannot ${t} a contenteditable or EditContext editor; use press or an input`)}function RS(e,t){if(e.disabled)throw new Error(`cannot ${t} a disabled <${e.tagName.toLowerCase()}> \u2014 a user could not edit it, so forcing the value would put the app in a state nobody can reach`);if(e.readOnly)throw new Error(`cannot ${t} a readonly <${e.tagName.toLowerCase()}> \u2014 a user could not edit it, so forcing the value would put the app in a state nobody can reach`)}Et();Dr();gt();Et();ot();Dr();dt();var oK=30,iK="option";function E$(e){return Ae(e).trim()}function sK(e){var i,s;let t=e.ownerDocument,r=((s=(i=e.getAttribute("aria-controls"))!=null?i:e.getAttribute("aria-owns"))!=null?s:"").split(/\s+/).filter(a=>0<a.length).map(a=>t.getElementById(a)).filter(a=>a!==null);return(0<r.length?r:[t]).flatMap(a=>Array.from(a.querySelectorAll(`[role="${iK}"]`))).filter(a=>!dr(a)&&Ke(a))}async function aK(e){for(let t=0;t<oK;t+=1){let n=sK(e);if(0<n.length)return n;await Eo()}return[]}function cK(e,t){let n=t.trim();return E$(e)===n||e.getAttribute("data-value")===t||e.getAttribute("value")===t}async function b$(e,t,n,r){let o=e.getAttribute("aria-expanded")!=="true";o&&await n(e);let i=await aK(e),s=i.filter(u=>cK(u,t)),[a]=s,l=i.length===0?r:lK(s,i,t);if(a===void 0||l!==void 0)throw o&&await n(e),new Error(l!=null?l:"no option");return(await n(a)).prevented}function lK(e,t,n){let[r]=e;if(r===void 0)return`no option '${Pr(n)}' \u2014 available: ${t.map(E$).join(", ")}`;if(1<e.length)return`${e.length} options match '${Pr(n)}' \u2014 name one by its exact label`;if(r.getAttribute("aria-disabled")==="true")return`cannot select a disabled option '${Pr(n)}' \u2014 a real user could not, so neither will Reticle`}ni();dn();dt();It();M();Et();var _$=160,uK=150,dK="checkbox",pK="radio",Ad;function Qh(e){return e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement||e instanceof HTMLSelectElement}function T$(e){return e instanceof HTMLInputElement&&(dK===e.type||pK===e.type)}function CS(e){return T$(e)?{value:e.value,checked:e.checked}:{value:e.value}}function fK(e,t){return e.checked!==void 0||t.checked!==void 0?e.checked!==t.checked:e.value!==t.value}function S$(e){return e.length>_$?`${e.slice(0,_$)}\u2026`:e}function hK(e){let t=Ne(e);if(t!==null&&t.length>0)return t;if(e.name.length>0)return e.name;let n=Ae(e);if(n.length>0)return n;let r=e.getAttribute("id");return r!==null&&r.length>0?r:e.tagName.toLowerCase()}function x$(e,t,n,r){let o=pn(e),i={[Ut.FIELD]:hK(e),[Ut.KIND]:t,[Ut.LENGTH]:n.value.length};return n.checked!==void 0&&(i[Ut.CHECKED]=n.checked),(r==null?void 0:r.checked)!==void 0&&(i[Ut.PREVIOUS_CHECKED]=r.checked),o?(i[Ut.REDACTED]=!0,i):(i[Ut.VALUE]=S$(n.value),r!==void 0&&r.checked===void 0&&(i[Ut.PREVIOUS]=S$(r.value)),i)}function mK(e){return T$(e)?"checked":"value"}function gK(e,t){for(let n=Object.getPrototypeOf(e);n!==null;){let r=Object.getOwnPropertyDescriptor(n,t);if(r!==void 0)return r;n=Object.getPrototypeOf(n)}}function EK(e,t){var u;let n=Object.getOwnPropertyDescriptor(e,t),r=n!=null?n:gK(e,t),o=r===void 0?void 0:Reflect.get(r,"get"),i=r===void 0?void 0:Reflect.get(r,"set"),s=!1;if(!(typeof o=="function"&&typeof i=="function")||(n==null?void 0:n.configurable)===!1)return{stop:()=>{},written:()=>s};Object.defineProperty(e,t,{configurable:!0,enumerable:(u=r==null?void 0:r.enumerable)!=null?u:!1,get(){return Reflect.apply(o,this,[])},set(d){s=!0,Reflect.apply(i,this,[d])}});let l=!1;return{stop:()=>{l||(l=!0,n===void 0?Reflect.deleteProperty(e,t):Object.defineProperty(e,t,n))},written:()=>s}}function A$(e){if(!(!Qh(e)||e instanceof HTMLSelectElement))return{before:CS(e),...EK(e,mK(e))}}function y$(e,t){let n=Ad;if(t===void 0||(t.stop(),n===void 0||!Qh(e)||!e.isConnected||!t.written()))return;let r=t.before;if(pn(e)&&r.checked===void 0)return;let o=CS(e);fK(r,o)&&n(v.FIELD_CHANGE,x$(e,Ju.SETTLED,o,r))}function w$(e){let t=new AbortController,{signal:n}=t,r=Ad;Ad=e;let o=new Map,i=(u,d)=>{e(v.FIELD_CHANGE,x$(u,d,CS(u)))},s=u=>{let d=o.get(u);d!==void 0&&clearTimeout(d),o.delete(u)},a=u=>{let d=u.target;Qh(d)&&(s(d),o.set(d,setTimeout(()=>{o.delete(d),i(d,Ju.INPUT)},uK)))},l=u=>{let d=u.target;Qh(d)&&(s(d),i(d,Ju.CHANGE))};return document.addEventListener("input",a,{signal:n,capture:!0}),document.addEventListener("change",l,{signal:n,capture:!0}),()=>{for(let u of o.values())clearTimeout(u);o.clear(),Ad===e&&(Ad=r),t.abort()}}ot();Et();var LS=200,v$=" | ",bK=3,_K=/\p{L}/u;function SK(e){return _K.test(e)}var TK=3;function xK(e){return e instanceof Element&&e.querySelectorAll("*").length>TK}var Dc,yd,Yi,$S,kS,em=class{constructor(){x(this,Yi);x(this,Dc,new Set);x(this,yd,0)}collect(t){for(let n of t){if(T(this,Yi,$S).call(this))return;if(n.type==="characterData"){T(this,Yi,kS).call(this,n.target.textContent,n.target.parentElement);continue}for(let r of n.addedNodes){if(T(this,Yi,$S).call(this))return;if(xK(r))continue;let o=bK===r.nodeType?r.parentElement:AK(r);T(this,Yi,kS).call(this,r.textContent,o)}}}effect(t){let n=[...c(this,Dc)].filter(o=>o!==t);if(n.length===0)return{};let r=n.join(v$);return{appeared:r.length>LS?`${r.slice(0,LS)}\u2026`:r}}};Dc=new WeakMap,yd=new WeakMap,Yi=new WeakSet,$S=function(){return c(this,yd)>LS},kS=function(t,n){if(n!==null&&od(n)||n!==null&&pn(n))return;let r=(t!=null?t:"").replace(/\s+/g," ").trim();r.length!==0&&SK(r)&&(c(this,Dc).has(r)||(c(this,Dc).add(r),g(this,yd,c(this,yd)+(r.length+v$.length))))};function AK(e){return e instanceof Element?e:e.parentElement}M();dn();var yK=new Set(["checkbox","switch"]),N$="aria-checked",tm=e=>{var t;return!He(e)&&yK.has((t=e.getAttribute("role"))!=null?t:"")},R$=e=>e.getAttribute(N$)==="true";function O$(e,t,n){var o;if(n||!tm(e)||t!==D.CHECK&&t!==D.UNCHECK)return;let r=t===D.CHECK;if(R$(e)!==r)throw new Error(`${t} clicked the ${(o=e.getAttribute("role"))!=null?o:""} but ${N$} is still "${String(!r)}" \u2014 the app did not toggle it`)}function nm(e,t){if(t!==D.CHECK&&t!==D.UNCHECK)return!1;let n=t===D.CHECK;return He(e)?e.checked===n:tm(e)&&R$(e)===n}M();zc();dt();dn();var zS=e=>new Promise(t=>de(t,e));function wK(e,t=""){return typeof e=="string"?e:t}function om(e){return n_(e)}var vK=["metaKey","ctrlKey","shiftKey","altKey"],$$={meta:"metaKey",cmd:"metaKey",command:"metaKey",super:"metaKey",win:"metaKey",control:"ctrlKey",ctrl:"ctrlKey",shift:"shiftKey",alt:"altKey",option:"altKey",opt:"altKey"};function im(e){let t=e.modifiers,n=Array.isArray(t)?t.map(o=>wK(o).toLowerCase()):[],r={metaKey:!1,ctrlKey:!1,shiftKey:!1,altKey:!1};for(let o of n){let i=$$[o];i!==void 0&&(r[i]=!0)}return r}function I$(e){return $$[e.toLowerCase()]}function rm(e,t){let n=e.code;return typeof n=="string"&&0<n.length?n:t===" "?"Space":t.length===1?/[a-z]/i.test(t)?`Key${t.toUpperCase()}`:/[0-9]/.test(t)?`Digit${t}`:"":/^[A-Z][A-Za-z0-9]*$/.test(t)&&OK.has(t)?t:""}function sm(e,t,n,r,o=!1){if(C$!==t&&t.length!==1)return;let i=new KeyboardEvent("keypress",{key:t,code:n,bubbles:!0,cancelable:!0,repeat:o,...r}),s=C$===t?NK:t.charCodeAt(0);for(let a of RK)Object.defineProperty(i,a,{value:s});it(()=>e.dispatchEvent(i))}var C$="Enter",NK=13,RK=["keyCode","charCode","which"],OK=new Set(["Enter","Escape","Tab","Backspace","Delete","Home","End","PageUp","PageDown","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Insert","F1","F2","F3","F4","F5","F6","F7","F8","F9","F10","F11","F12"]),IK="no document to press into";function k$(){let e=document.activeElement;if(ut(e)&&document.body!==e)return e;if(ut(document.body))return document.body;let t=document.documentElement;if(ut(t))return t;throw new Error(IK)}function z$(e,t,n){return e.length===0&&HO(n)&&D.PRESS===t}function D$(e){return r_(e)}var CK=33,L$=500,LK={Backspace:8,Tab:9,Enter:13,Shift:16,Control:17,Alt:18,Escape:27," ":32,PageUp:33,PageDown:34,End:35,Home:36,ArrowLeft:37,ArrowUp:38,ArrowRight:39,ArrowDown:40,Delete:46,Meta:91},$K=/^[a-z0-9]$/i,kK=e=>{var t;return(t=LK[e])!=null?t:$K.test(e)?e.toUpperCase().charCodeAt(0):0};function wd(e,t){let n=new KeyboardEvent(e,t),r=kK(t.key);for(let o of["keyCode","which"])Object.defineProperty(n,o,{get:()=>r});return n}async function P$(e,t,n,r,o){let i=Date.now();for(o>L$&&await zS(L$);Date.now()-i<o;)it(()=>e.dispatchEvent(wd("keydown",{key:t,code:n,bubbles:!0,cancelable:!0,repeat:!0,...r})))&&sm(e,t,n,r,!0),await zS(Math.min(CK,Math.max(0,o-(Date.now()-i))))}async function M$(e,t,n,r){let o={...n},i=(d,f)=>{let m=rm({},f);return it(()=>e.dispatchEvent(wd(d,{key:f,code:m,bubbles:!0,cancelable:!0,...o})))},s=new Map;for(let d of vK)o[d]&&s.set(d,1);let a=d=>{var f;s.set(d,((f=s.get(d))!=null?f:0)+1),o[d]=!0},l=d=>{var m;let f=((m=s.get(d))!=null?m:1)-1;s.set(d,f),f<=0&&(o[d]=!1)},u=!1;for(let d of t){let f=I$(d);f!==void 0&&a(f);let m=i("keydown",d);m||(u=!0),m&&sm(e,d,rm({},d),o),DS(e,d,m)}r>0&&await zS(r);for(let d of[...t].reverse()){let f=I$(d);f!==void 0&&l(f),i("keyup",d)}return u}function DS(e,t,n){var r,o;if(!(t!=="Escape"||!n))for(let i=e.closest("dialog");i!==null;i=(o=(r=i.parentElement)==null?void 0:r.closest("dialog"))!=null?o:null){try{if(!i.open||!i.matches(":modal"))continue}catch{return}typeof i.requestClose=="function"?i.requestClose():i.dispatchEvent(new Event("cancel",{cancelable:!0}))&&i.close();return}}It();M();Et();ni();ot();var zK="canvas";function U$(e){var o,i,s,a;let t=(i=(o=e.defaultView)==null?void 0:o.innerWidth)!=null?i:0,n=(a=(s=e.defaultView)==null?void 0:s.innerHeight)!=null?a:0,r=0;for(let l of e.querySelectorAll(zK)){if(dr(l))continue;let u=l.getBoundingClientRect(),d=u.width>0&&u.height>0,f=u.bottom>0&&u.right>0&&u.top<n&&u.left<t;d&&f&&(r+=1)}return r}function H$(e){var a;let t=(a=Ne(e))!=null?a:void 0,n=fr(e),r={};if(t!==void 0){r.testid=t;let l=yS({by:Je.TESTID,value:t}).length;1<l&&(r.testidOf=l)}let o=n==null?void 0:n.componentStack[0];o!==void 0&&(r.component=o),(n==null?void 0:n.source)!==void 0&&(r.source=n.source);let i=Re(e),s=Ae(e);if(i.length>0&&(r.role=i),s.length>0&&(r.name=s),pn(e)&&(r.secret=!0),i.length>0&&s.length>0){let l=yS({by:Je.ROLE,value:i,name:s}),u=l.indexOf(e);1<l.length&&0<=u&&(r.nth=u,r.of=l.length)}return r}var F$=(e,t,n,r,o,i,s)=>{let a={ok:!0,ref:e,action:t,dispatched:!0,settled:r,settleReason:o,effect:n};return i.testid!==void 0&&(a.testid=i.testid),i.testidOf!==void 0&&(a.testidOf=i.testidOf),i.component!==void 0&&(a.component=i.component),i.source!==void 0&&(a.source=i.source),i.role!==void 0&&(a.role=i.role),i.name!==void 0&&(a.name=i.name),i.nth!==void 0&&(a.nth=i.nth),i.of!==void 0&&(a.of=i.of),i.secret!==void 0&&(a.secret=i.secret),s!==void 0&&(a.warning=s),a};gt();It();Et();ot();var DK=[[.5,.5],[.25,.25],[.75,.25],[.25,.75],[.75,.75]],PK=3;function am(e,t){var u;if(t.width===0||t.height===0)return null;let n=e.ownerDocument;if(typeof n.elementFromPoint!="function")return null;let r=n,o=d=>dr(d)&&d!==e&&!e.contains(d)&&!d.contains(e),i=(d,f)=>{var h,E,S;return(S=((E=(h=r.elementsFromPoint)==null?void 0:h.call(r,d,f))!=null?E:[n.elementFromPoint(d,f)]).find(A=>A!==null&&!o(A)))!=null?S:null},s=new Map;for(let[d,f]of DK){let m=i(t.left+t.width*d,t.top+t.height*f);m!==null&&(m===e||e.contains(m)||m.contains(e)||s.set(m,((u=s.get(m))!=null?u:0)+1))}let a=null,l=0;for(let[d,f]of s)f>l&&(a=d,l=f);return l>=PK?a:null}dt();zc();M();var vd={occluded:!1,occludedBy:null,scrolledIntoView:!1};function Xi(e,t,n={}){return new MouseEvent(t,{...n,view:e.ownerDocument.defaultView})}function cm(e,t,n){let r={...n,view:e.ownerDocument.defaultView};return typeof PointerEvent=="function"?new PointerEvent(t,r):new MouseEvent(t,r)}var Wt=1,Nd=0,j$={modifiers:{metaKey:!1,ctrlKey:!1,shiftKey:!1,altKey:!1},button:cr.LEFT},K$={[cr.LEFT]:{button:0,bit:1},[cr.RIGHT]:{button:2,bit:2},[cr.MIDDLE]:{button:1,bit:4}};function MS(e){var t;return{modifiers:im(e),button:(t=i_(e))!=null?t:cr.LEFT}}function Ze(e,t,n,r,o,i=0,s=j$){let a={bubbles:!(t.endsWith("enter")||t.endsWith("leave")),cancelable:!0,detail:i,clientX:n.x,clientY:n.y,screenX:n.x,screenY:n.y,buttons:r,button:K$[s.button].button,...s.modifiers,...o!==void 0?{relatedTarget:o}:{}};return e.dispatchEvent(t.startsWith("pointer")?cm(e,t,{...a,pointerId:1,isPrimary:!0}):Xi(e,t,a))}async function Pc(e,t,n,r=j$){var h;let o=e.ownerDocument,i=(h=o.activeElement)!=null?h:o.body,s=PS(e),a=n!=null?n:0,l=K$[r.button].bit,u=cr.LEFT===r.button,d=!0;it(()=>Ze(e,"pointerdown",s,l,i,a,r)),it(()=>Ze(e,"mousedown",s,l,void 0,a,r)),cr.RIGHT===r.button&&(d=it(()=>Ze(e,"contextmenu",s,l,void 0,a,r))),e.tabIndex>=0&&typeof e.focus=="function"&&e.focus();let f=0;if(t!==void 0&&t.ms>0){let E=t.now();await t.sleep(t.ms),f=t.now()-E}it(()=>Ze(e,"pointerup",s,Nd,i,a,r)),it(()=>Ze(e,"mouseup",s,Nd,void 0,a,r));let m=it(()=>Ze(e,u?"click":"auxclick",s,Nd,void 0,a,r));return cr.RIGHT!==r.button&&(d=m),{prevented:!d,heldMs:f}}function MK(e){return e.width>0||e.height>0}function Od(e,t={}){e.scrollIntoView({...t,behavior:"instant"})}function Rd(e,t){let n=e.ownerDocument.defaultView;if(n===null)return!1;let r=t.left+t.width/2,o=t.top+t.height/2;return r<0||o<0||r>n.innerWidth||o>n.innerHeight}function UK(e,t){let n=am(e,t);return n===null?{occluded:!1,occludedBy:null}:{occluded:!0,occludedBy:re.refFor(n),occluderName:HK(n)}}function HK(e){let t=Ne(e);if(t!==null&&t.length>0)return`[data-testid="${t}"]`;let n=Ae(e).trim();return n.length>0?`${Re(e)} "${n.slice(0,40)}"`:e.tagName.toLowerCase()}function FK(e){if(typeof e.getClientRects!="function")return!1;let t=Array.from(e.getClientRects());return t.length>0&&t.every(n=>n.width===0||n.height===0)}function Z$(e){if(typeof e.getBoundingClientRect!="function")return vd;let t=e.getBoundingClientRect();if(!MK(t))return FK(e)?{...vd,noSize:!0}:vd;let n=!1;Rd(e,t)&&typeof e.scrollIntoView=="function"&&(Od(e,{block:"center",inline:"center"}),n=!0,t=e.getBoundingClientRect());let r=n&&Rd(e,t);return{...UK(e,t),scrolledIntoView:n,...r?{offViewport:!0}:{}}}function US(e,t,n=null){it(()=>e.dispatchEvent(cm(e,t,{bubbles:!0,cancelable:!0,relatedTarget:n})))}function W$(e,t,n=null){it(()=>e.dispatchEvent(cm(e,t,{bubbles:!1,cancelable:!0,relatedTarget:n})))}function BK(e){if(typeof DataTransfer!="function")return null;let t=new DataTransfer,n=Array.isArray(e)?e:e!==void 0?[e]:[];for(let r of n)if(typeof r=="object"&&r!==null){let o=r;typeof o.mime=="string"&&typeof o.value=="string"&&t.setData(o.mime,o.value)}return t}var B$=5;function PS(e){let t=e.getBoundingClientRect();return{x:t.left+t.width/2,y:t.top+t.height/2}}function GK(e,t,n){return{x:Math.round(e.x+(t.x-e.x)*n),y:Math.round(e.y+(t.y-e.y)*n)}}async function HS(e,t,n){let r=t!=null?t:e,o=PS(e),i=PS(r),s=e.getBoundingClientRect(),a=t!==null?r.getBoundingClientRect():null,l=(m,h)=>h.x>=m.left&&h.x<=m.right&&h.y>=m.top&&h.y<=m.bottom;Ze(e,"pointerdown",o,Wt),Ze(e,"mousedown",o,Wt),await Eo();let u=!1,d=!1;for(let m=1;m<=B$;m+=1){let h=GK(o,i,m/B$);!u&&!l(s,h)&&(u=!0,Ze(e,"pointerout",h,Wt,r),Ze(e,"mouseout",h,Wt,r),Ze(e,"pointerleave",h,Wt,r),Ze(e,"mouseleave",h,Wt,r)),u&&!d&&a!==null&&l(a,h)&&(d=!0,Ze(r,"pointerover",h,Wt,e),Ze(r,"mouseover",h,Wt,e),Ze(r,"pointerenter",h,Wt,e),Ze(r,"mouseenter",h,Wt,e)),Ze(r,"pointermove",h,Wt),Ze(r,"mousemove",h,Wt),await Eo()}!d&&a!==null&&(Ze(r,"pointerover",i,Wt,e),Ze(r,"mouseover",i,Wt,e),Ze(r,"pointerenter",i,Wt,e),Ze(r,"mouseenter",i,Wt,e)),Ze(r,"pointerup",i,Nd),Ze(r,"mouseup",i,Nd);let f=!1;if(typeof DragEvent=="function"){let m=BK(n),h={bubbles:!0,cancelable:!0};m!==null&&(h.dataTransfer=m),e.dispatchEvent(new DragEvent("dragstart",h)),await Eo(),r.dispatchEvent(new DragEvent("dragenter",h)),r.dispatchEvent(new DragEvent("dragover",h)),await Eo(),f=!r.dispatchEvent(new DragEvent("drop",h)),e.dispatchEvent(new DragEvent("dragend",h))}return f}async function Y$(e,t){let n=VK(e);G$(e,"pointerdown"),it(()=>e.dispatchEvent(V$("touchstart",n))),e.tabIndex>=0&&typeof e.focus=="function"&&e.focus();let r=0;if(t!==void 0&&t.ms>0){let i=t.now();await t.sleep(t.ms),r=t.now()-i}return it(()=>e.dispatchEvent(V$("touchend",[]))),G$(e,"pointerup"),{prevented:!it(()=>e.dispatchEvent(Xi(e,"click",{bubbles:!0,cancelable:!0}))),heldMs:r}}function G$(e,t){it(()=>e.dispatchEvent(cm(e,t,{bubbles:!0,cancelable:!0,pointerType:"touch",isPrimary:!0,width:23,height:23})))}function VK(e){if(typeof Touch!="function"||typeof e.getBoundingClientRect!="function")return[];let t=e.getBoundingClientRect();try{return[new Touch({identifier:0,target:e,clientX:t.left+t.width/2,clientY:t.top+t.height/2})]}catch{return[]}}function V$(e,t){if(typeof TouchEvent=="function")try{return new TouchEvent(e,{bubbles:!0,cancelable:!0,touches:t,targetTouches:t,changedTouches:t})}catch{}return new Event(e,{bubbles:!0,cancelable:!0})}var jK=new Set(["menu","menubar","listbox","dialog","alertdialog","tooltip"]),KK="closed";function X$(e){var t,n;for(let r=e.parentElement;r!==null;r=r.parentElement)if(KK===r.getAttribute("data-state")&&jK.has((t=r.getAttribute("role"))!=null?t:""))throw new Error(`'${(n=r.getAttribute("role"))!=null?n:"popup"}' holding this element is closing (data-state="closed"), so a person could not click it: look again once it has gone and act on what is open`)}gt();var ZK=400,WK=.8,YK="scroll fraction must be between 0 and 1, got ";function XK(e){return`${YK}${e}`}function qK(e,t){var r;let n=e;for(;n!==null&&n!==document.body;){let o=getComputedStyle(n),i=t==="x"?o.overflowX:o.overflowY,s=t==="x"?n.scrollWidth>n.clientWidth:n.scrollHeight>n.clientHeight;if((i==="auto"||i==="scroll")&&s)return n;n=n.parentElement}return(r=document.scrollingElement)!=null?r:document.documentElement}function q$(e,t,n,r){let o=e!==void 0?re.resolve(e):null;return FS(o instanceof Element?o:void 0,t,n,r)}function FS(e,t,n,r){var d;if(n!==void 0&&(n<0||n>1||Number.isNaN(n)))throw new RangeError(XK(n));let i=e!==void 0?qK(e,r!==void 0&&r!==0&&(t===void 0||t===0)?"x":"y"):(d=document.scrollingElement)!=null?d:document.documentElement,s=i.scrollTop,a=i.scrollLeft;if(n!==void 0)i.scrollTop=Math.round(i.scrollHeight*n);else if(r!==void 0&&r!==0&&(i.scrollLeft=a+r),r===void 0||t!==void 0&&t!==0){let f=t!=null?t:Math.round(i.clientHeight*WK)||ZK;i.scrollTop=s+f}i.dispatchEvent(new Event("scroll",{bubbles:!1}));let l=i.scrollTop,u=i.scrollLeft;return{scrolled:l!==s||u!==a,scrollTop:l,scrollHeight:i.scrollHeight,clientHeight:i.clientHeight,atEnd:l+i.clientHeight>=i.scrollHeight-1,atStart:l<=1,scrollLeft:u,scrollWidth:i.scrollWidth,clientWidth:i.clientWidth,atLeftEnd:u<=1,atRightEnd:u+i.clientWidth>=i.scrollWidth-1}}M();Et();qo();var JK='label, summary, [onclick], [tabindex], [contenteditable]:not([contenteditable="false"])';function J$(e,t){if(D.CLICK!==t&&D.DBLCLICK!==t)return!1;for(let n=e;n!==null;n=Xo(n))if(Vi.has(Re(n))||n.matches(JK))return!1;return getComputedStyle(e).cursor!=="pointer"}function Id(e,t=""){return typeof e=="string"?e:t}function QK(e){let t=re.resolve(e);if(t===null)throw new Error(`ref '${Pr(e)}' no longer resolves to an element`);if(!Jo(t))throw new Error(`ref '${Pr(e)}' is not an HTML or SVG element`);return t}var e3=new Set([D.FILL,D.TYPE,D.CLEAR,D.SELECT]),t3=e=>e3.has(e),nk=new Set([D.CLICK,D.DBLCLICK,D.CHECK,D.UNCHECK]);function rk(e){let t=Id(e.toRef);return t!==""?t:Id(e.target)}var Q$=new Set(["content","name","type","__base64"]),n3=new Set([Vf,$R,"holdMs"]);function r3(e){let t=Object.keys(e),n=t.filter(o=>!Q$.has(o)&&!n3.has(o));if(n.length===0&&t.some(o=>Q$.has(o)))return;let r=n.length===0?"no file was described":`upload does not read ${n.join(", ")}, so it would be dropped`;throw new Error(`upload needs the file described as args: { name, content?, type? } \u2014 ${r}. To upload a file from disk, use the reticle daemon which reads it via args.path and delivers real bytes; calling with { path } directly reaches only fabricated content.`)}function o3(e,t,n){let r=t===D.CLICK||t===D.DBLCLICK||t===D.CHECK||t===D.UNCHECK||t===D.DRAG||t===D.SUBMIT||t===D.PRESS&&om(n)==="Enter",o=t===D.DRAG?re.resolve(rk(n)):null,i=t===D.PRESS&&om(n)==="Enter"?jC(e):null;r&&KC([e,i,Jo(o)?o:null]),(t===D.FILL||t===D.TYPE)&&ZC(e);let s=Lh(e)||i!==null&&Lh(i),a=Jo(o)&&Lh(o);if(r&&(s||a)&&n[Vf]!==!0)throw new Error(`potentially destructive action blocked; retry with args.${Vf}=true`);if(nk.has(t)&&e instanceof HTMLElement&&TS(e))throw new Error("cannot click a native <option> inside a visually-hidden <select> \u2014 open the dropdown and target the visible option")}function i3(e,t){var r,o;if(e.some(i=>i.value===t))return t;let n=e.filter(i=>i.label.trim()===t.trim());return n.length===1&&(o=(r=n[0])==null?void 0:r.value)!=null?o:t}function GS(e){return!ti(e).includes(Se.DISABLED)}function ek(e){if(He(e)||vn(e)||zr(e))return e.value}function tk(e){let t=e.ownerDocument.activeElement;return t===null||t===e.ownerDocument.body?null:re.refFor(t)}async function s3(e,t,n){if(D.CLICK===t){let r=gc(n.holdMs);return await Pc(e,r===0?void 0:{ms:r,sleep:VS,now:()=>Date.now()},void 0,MS(n))}if(D.TAP===t){let r=gc(n.holdMs);return await Y$(e,r===0?void 0:{ms:r,sleep:VS,now:()=>Date.now()})}return{prevented:await u3(e,t,n),heldMs:0}}var a3="cannot zoom from inside the page \u2014 CSS zoom changes how it LOOKS without changing the layout viewport, visualViewport or media queries, so a layout that breaks at 200% would be reported as checked and passing. Drive a real browser (reticle drive <url>, or reticle_lease) and zoom there.";function c3(e){return Re(e)==="combobox"||e.getAttribute("aria-haspopup")==="listbox"}var l3=e=>`cannot select on a <${e}> \u2014 it is an ARIA combobox, not a native <select>. Click the combobox to open it, then click the option with { role: "option", name: "<label>" }.`;function BS(e){return typeof e=="number"&&Number.isFinite(e)?e:void 0}async function u3(e,t,n){var r;switch(t){case D.DBLCLICK:{let o=MS(n);return await Pc(e,void 0,1,o),await Pc(e,void 0,2,o),!it(()=>e.dispatchEvent(Xi(e,"dblclick",{bubbles:!0,cancelable:!0,detail:2,...o.modifiers})))}case D.HOVER:{let o=e.ownerDocument,i=(r=o.activeElement)!=null?r:o.body;US(e,"pointerover",i),e.dispatchEvent(Xi(e,"mouseover",{bubbles:!0,relatedTarget:i})),W$(e,"pointerenter",i),e.dispatchEvent(Xi(e,"mouseenter",{relatedTarget:i})),US(e,"pointermove",i);let s=e.dispatchEvent(Xi(e,"mousemove",{bubbles:!0,cancelable:!0})),a=gc(n.holdMs);return a>0&&await VS(a),!s}case D.FOCUS:return e.focus(),e.dispatchEvent(new FocusEvent("focusin",{bubbles:!0})),!1;case D.BLUR:{let i=e.getRootNode().activeElement===e;return e.blur(),i||(e.dispatchEvent(new FocusEvent("blur")),e.dispatchEvent(new FocusEvent("focusout",{bubbles:!0}))),!1}case D.FILL:if(He(e)||vn(e)){if(typeof n.value!="string")throw new Error("fill requires a string `value` \u2014 pass it nested, as args: { value: '\u2026' }. To empty a field on purpose use the `clear` action, or fill with an explicit \"\".");return RS(e,"fill"),vS(e)||e.focus(),Xh(e,n.value)}throw NS(e,"fill"),new Error(`cannot fill a <${e.tagName.toLowerCase()}>`);case D.TYPE:if(He(e)||vn(e)){if(typeof n.text!="string")throw new Error("type requires a string `text` \u2014 pass it nested, as args: { text: '\u2026' }.");return RS(e,"type"),e.focus(),Xh(e,e.value+n.text)}throw NS(e,"type into"),new Error(`cannot type into a <${e.tagName.toLowerCase()}>`);case D.CLEAR:if(He(e)||vn(e))return Xh(e,"");throw new Error(`cannot clear a <${e.tagName.toLowerCase()}>`);case D.SELECT:if(zr(e)){if(typeof n.value!="string")throw new Error("select requires a string `value` \u2014 pass it nested, as args: { value: '\u2026' }.");let o=Array.from(e.options),i=i3(o,n.value);if(!o.some(s=>s.value===i)){let s=o.map(a=>`${a.value} (${a.label})`).join(", ");throw new Error(`no <option> with value '${Pr(i)}' \u2014 available: ${o.length===0?"(none)":s}`)}return e.value=i,e.dispatchEvent(new Event("change",{bubbles:!0})),!1}if(c3(e)){if(typeof n.value!="string")throw new Error("select requires a string `value` \u2014 pass it nested, as args: { value: '\u2026' }.");return await b$(e,n.value,o=>Pc(o),l3(e.tagName.toLowerCase()))}throw new Error(`cannot select on a <${e.tagName.toLowerCase()}>`);case D.CHECK:case D.UNCHECK:{let o=tm(e);if(!He(e)&&!o)throw new Error(`cannot (un)check a <${e.tagName.toLowerCase()}>`);if(!GS(e))throw new Error(`cannot ${t} a disabled control \u2014 a real user could not, so neither will Reticle`);if(!He(e))return nm(e,t)?!1:(await Pc(e)).prevented;if(e.type==="radio"&&t===D.UNCHECK)throw new Error("cannot uncheck a radio button \u2014 a real user could not; select another radio in the group");if(nm(e,t))return!1;let i=Xi(e,"click",{bubbles:!0,cancelable:!0,composed:!0});return!it(()=>e.dispatchEvent(i))||i.defaultPrevented}case D.SUBMIT:{let o=iC(e)?e:e.closest("form");if(o===null)throw new Error("no form to submit");return o.requestSubmit(),!1}case D.PRESS:{let o=im(n),i=D$(n);if(i.length>0)return await M$(e,i,o,gc(n.holdMs));let s=om(n),a=rm(n,s),l=it(()=>e.dispatchEvent(wd("keydown",{key:s,code:a,bubbles:!0,cancelable:!0,...o})));DS(e,s,l),l&&sm(e,s,a,o);let u=gc(n.holdMs);return u>0&&await P$(e,s,a,o,u),it(()=>e.dispatchEvent(wd("keyup",{key:s,code:a,bubbles:!0,...o}))),!l}case D.SCROLL_INTO_VIEW:return Od(e),!1;case D.ZOOM:throw new Error(a3);case D.SCROLL:{let o=BS(n.dy),i=BS(n.dx),s=BS(n.fraction);return FS(e,o,s,i),!1}case D.UPLOAD:{if(!He(e)||e.type!=="file")throw new Error('upload target must be a <input type="file">');r3(n);let o=Id(n.content,"reticle test file"),i=o;if(n.__base64===!0){let u=atob(o),d=new Uint8Array(u.length);for(let f=0;f<u.length;f++)d[f]=u.charCodeAt(f);i=d.buffer.slice(0)}let s=new File([i],Id(n.name,"file.txt"),{type:Id(n.type,"text/plain")}),a=new DataTransfer;a.items.add(s),e.files=a.files;let l=e.dispatchEvent(new Event("input",{bubbles:!0,cancelable:!0}));return e.dispatchEvent(new Event("change",{bubbles:!0})),!l}case D.DRAG:{let o=rk(n);if(o==="")return await HS(e,null,n.data);let i=re.resolve(o);if(!Jo(i))throw new Error(`drag target '${Pr(o)}' did not resolve to an element \u2014 pass a ref from reticle_snapshot or reticle_query as args.toRef (alias: args.target)`);return await HS(e,i,n.data)}default:throw new Error(`unknown action '${t}'`)}}async function Cd(e,t,n={}){let r=0<e.length;if(D.CLICK===t||D.DBLCLICK===t){let le=BO(t,n);if(le!==void 0)throw new Error(`cannot ${t}: ${le}`)}let o=z$(e,t,n)?k$():QK(e);r&&o3(o,t,n),r&&X$(o);let i=r?H$(o):{},s=tk(o);if((D.CLICK===t||D.DBLCLICK===t)&&!GS(o)){let le=o.ownerDocument.activeElement;le!==null&&le!==o&&le!==o.ownerDocument.body&&Jo(le)&&(le.blur(),await Promise.resolve())}let a=Ke(o),l=GS(o),u=ek(o),d=A$(o),f=nk.has(t)?Z$(o):vd,m=nm(o,t),h=J$(o,t),E=0,S=new em,A=new MutationObserver(le=>{E+=le.length,S.collect(le)});A.observe(o.ownerDocument.documentElement,{subtree:!0,childList:!0,attributes:!0,characterData:!0});let w=!1,N=0,O=!1,k=null;try{let le=await s3(o,t,n);w=le.prevented,N=le.heldMs}finally{let le=g$(n.settleMs),ge=await m$(le);O=ge.settled,k=ge.settled?null:MR.TIMEOUT,A.disconnect(),d==null||d.stop()}O$(o,t,m);let G=ek(o);y$(o,d);let V=tk(o),W={dispatched:!0,targetMatched:r&&o.isConnected,visible:a,enabled:l,defaultPrevented:w,focusMoved:s!==V?`${s!=null?s:"null"}->${V!=null?V:"null"}`:null,valueChanged:t3(t)?u!==G:!1,...D.FILL===t&&vS(o)?{autofillSafe:!0}:{},domMutatedWithin:E,...S.effect(G),occluded:f.occluded,occludedBy:f.occludedBy,scrolledIntoView:f.scrolledIntoView,...f.occluderName===void 0?{}:{occluderName:f.occluderName},...f.noSize===!0?{noSize:!0}:{},...f.offViewport===!0?{offViewport:!0}:{},...N>0?{heldMs:N}:{},...m?{alreadyAtValue:!0}:{},...d3()},K;r?f.occluded?K=Pu.CLICK_OCCLUDED:t===D.HOVER&&kh(o)?K=Pu.HOVER_NATIVE_ENTER_LEAVE:h&&(K=Pu.CLICK_NOT_A_CONTROL):K=Pu.GLOBAL_PRESS;let J=F$(e,t,W,O,k,i,K);return dr(o)?{...J,reticleUi:!0}:J}function d3(){let e=U$(document);return e>0?{canvases:e}:{}}var VS=e=>new Promise(t=>de(t,e));async function lm(e){var r;let t=[],n=[];for(let o of e){let i=await Cd(o.ref,o.action,(r=o.args)!=null?r:{});t.push(i.effect);let s={ref:i.ref,action:i.action,dispatched:i.dispatched,settled:i.settled,settleReason:i.settleReason};i.testid!==void 0&&(s.testid=i.testid),i.component!==void 0&&(s.component=i.component),i.role!==void 0&&(s.role=i.role),i.name!==void 0&&(s.name=i.name),i.source!==void 0&&(s.source=i.source),i.secret!==void 0&&(s.secret=i.secret),i.warning!==void 0&&(s.warning=i.warning),n.push(s)}return{ok:!0,count:e.length,effects:t,steps:n}}Et();fd();var ok="data-theme";function p3(e){return"cssRules"in e&&e.cssRules instanceof CSSRuleList}function ak(e,t,n){if(!(n<=0))for(let r of Array.from(e))if(r instanceof CSSStyleRule)for(let o of Array.from(r.style))o.startsWith("--")&&t.add(o);else p3(r)&&ak(r.cssRules,t,n-1)}function f3(){let e=new Set;for(let t of Array.from(document.styleSheets)){let n=null;try{n=t.cssRules}catch{continue}n!==null&&ak(n,e,8)}return e}function h3(){var o;let e=new Map,t=(o=document.body)!=null?o:document.documentElement;if(t===null)return e;let n=getComputedStyle(t),r=document.createElement("span");r.style.position="absolute",r.style.pointerEvents="none",document.body.appendChild(r);try{for(let i of f3()){let s=m3(r,n.getPropertyValue(i).trim());if(s===null)continue;let a=e.get(s);a===void 0?e.set(s,[i]):a.push(i)}}finally{r.remove()}for(let i of e.values())i.sort();return e}function m3(e,t){return t.length===0||(e.style.color="",e.style.color=t,e.style.color==="")?null:getComputedStyle(e).color}function ik(e){return e==="rgba(0, 0, 0, 0)"||e==="transparent"}function g3(){let e=document.documentElement;if(e===null)return null;let t=Array.from(e.classList).map(o=>`.${o}`).join(""),n=e.getAttribute(ok),r=`${t}${n===null?"":`[${ok}="${n}"]`}`;return r.length===0?null:r}function sk(e){var t;return e.length===1&&(t=e[0])!=null?t:null}function ck(e){var a,l;let t=h3(),n=(a=t.get(e.color))!=null?a:[],r=(l=t.get(e.backgroundColor))!=null?l:[],o=!ik(e.color)&&n.length===0,i=!ik(e.backgroundColor)&&r.length===0,s=0;for(let u of t.values())s+=u.length;return{colorToken:sk(n),colorTokens:n,backgroundToken:sk(r),backgroundTokens:r,offTheme:s>0&&(o||i),tokenCount:s,themeScope:g3()}}gt();dn();M();pr();ho();function Ld(e){try{return e()}catch{return null}}function um(e){var n;let t={};if(e===null)return t;for(let r=0;r<e.length;r+=1){let o=e.key(r);if(o===null)continue;let i=(n=e.getItem(o))!=null?n:"";t[o]=St(o)?ve:lo(i)}return t}function lk(){let e={},t="";try{t=typeof document!="undefined"?document.cookie:""}catch{return e}for(let n of t.split(";")){let r=n.indexOf("=");if(r===-1)continue;let o=n.slice(0,r).trim();if(o==="")continue;if(St(o)){e[o]=ve;continue}let i="";try{i=decodeURIComponent(n.slice(r+1).trim())}catch{i=n.slice(r+1).trim()}e[o]=lo(i)}return e}function uk(e){return e===js.LOCAL?um(Ld(()=>window.localStorage)):e===js.SESSION?um(Ld(()=>window.sessionStorage)):js.COOKIE===e?lk():{local:um(Ld(()=>window.localStorage)),session:um(Ld(()=>window.sessionStorage)),cookies:lk()}}function qs(e,t){if(t!==null)return St(e)?ve:lo(t)}function dk(e){var d,f,m;if(typeof Storage=="undefined")return()=>{};let t=Storage.prototype,n=(d=Object.getOwnPropertyDescriptor(t,"setItem"))==null?void 0:d.value,r=(f=Object.getOwnPropertyDescriptor(t,"removeItem"))==null?void 0:f.value,o=(m=Object.getOwnPropertyDescriptor(t,"clear"))==null?void 0:m.value;if(n===void 0||r===void 0||o===void 0)return()=>{};let i=h=>h===Ld(()=>window.sessionStorage)?js.SESSION:js.LOCAL,s=(h,E)=>{try{return h.getItem(E)}catch{return null}},a=function(h,E){var A;let S=(A=Zt(()=>s(this,h)))!=null?A:null;n.call(this,h,E),S!==E&&(Nh(h)||oe(()=>{var w;e(v.STORAGE_CHANGE,{area:i(this),key:h,...qs(h,S)===void 0?{}:{old:qs(h,S)},new:(w=qs(h,E))!=null?w:ve})}))};t.setItem=a;let l=function(h){var S;let E=(S=Zt(()=>s(this,h)))!=null?S:null;r.call(this,h),!Nh(h)&&oe(()=>{e(v.STORAGE_CHANGE,{area:i(this),key:h,...qs(h,E)===void 0?{}:{old:qs(h,E)}})})};t.removeItem=l;let u=function(){let h=i(this),E=[];try{for(let S=0;S<this.length;S+=1){let A=this.key(S);A!==null&&!Nh(A)&&E.push({key:A,old:s(this,A)})}}catch{}o.call(this);for(let{key:S,old:A}of E)oe(()=>{e(v.STORAGE_CHANGE,{area:h,key:S,...qs(S,A)===void 0?{}:{old:qs(S,A)}})})};return t.clear=u,()=>{t.setItem===a&&(t.setItem=n),t.removeItem===l&&(t.removeItem=r),t.clear===u&&(t.clear=o)}}M();gt();dt();var Mc=16,E3=500,b3=4,_3=2166136261,S3=16777619,T3=8;function x3(e){var i,s;let t=_3,n=[0,0,0],r=Math.max(1,e.length/4);for(let a=0;a<e.length;a+=4)for(let l=0;l<3;l+=1){let u=(i=e[a+l])!=null?i:0;n[l]=((s=n[l])!=null?s:0)+u,t=Math.imul(t^Math.floor(u/T3),S3)>>>0}let o=n.map(a=>Math.round(a/r));return{digest:t.toString(16).padStart(8,"0"),mean:o}}function A3(e){if(e.width===0||e.height===0)return;let t=document.createElement("canvas");t.width=Mc,t.height=Mc;let n=t.getContext("2d");if(n===null)return;let r=Zt(()=>(n.drawImage(e,0,0,Mc,Mc),n.getImageData(0,0,Mc,Mc).data));return r===void 0?void 0:{data:r,width:e.width,height:e.height}}var Uc;function jS(){Uc==null||Uc(ks.ACT)}function pk(e,t={}){var a,l;let n=(a=t.sample)!=null?a:A3,r=(l=t.every)!=null?l:Jh,o=new WeakMap,i=u=>{oe(()=>{let d=Array.from(document.querySelectorAll("canvas")).slice(0,b3);for(let f of d){let m=n(f);if(m===void 0)continue;let{digest:h,mean:E}=x3(m.data);ks.POLL===u&&o.get(f)===h||(o.set(f,h),e(v.CANVAS_DIGEST,{digest:h,width:m.width,height:m.height,mean:E,trigger:u},re.refFor(f)))}})};Uc=i;let s=r(()=>i(ks.POLL),E3);return()=>{s(),Uc===i&&(Uc=void 0)}}M();dt();ot();var y3=lc.FULL_PAGE_UNSUPPORTED,w3=[y3,lc.NOT_COMPOSITED],v3="__TAURI_INTERNALS__";function N3(){let e=window[v3];if(typeof(e==null?void 0:e.invoke)!="function")return;let t=e.invoke.bind(e);return async n=>{let r=await t(hh,{fullPage:n===!0});return typeof r=="string"?r:null}}async function R3(e){let t=[...document.querySelectorAll(Ui)],n=t.map(r=>r.style.visibility);for(let r of t)r.style.visibility="hidden";try{return t.length>0&&(await Eo(),await Eo()),await e()}finally{t.forEach((r,o)=>{var i;r.style.visibility=(i=n[o])!=null?i:""})}}async function fk(e=!1){let t=window[Zo],n=typeof(t==null?void 0:t.capture)=="function"?t.capture:N3();if(n===void 0)return{ok:!1,reason:"no desktop capture helper installed"};try{let r=await R3(()=>n(e));return typeof r=="string"&&r.length>0?{ok:!0,path:r}:{ok:!1,reason:"capture returned no image"}}catch(r){let o=r instanceof Error?r.message:String(r);for(let i of w3)if(o.includes(i))return{ok:!1,reason:i};return{ok:!1,reason:o}}}ni();Xs();pr();Zi();function O3(e,t){var n;return(n=Object.getOwnPropertyDescriptor(e,t))==null?void 0:n.value}function Ur(e,t){let n=O3(e,t);if(n===void 0)throw new Error(`[Reticle] cannot patch ${String(t)}: it is not an own property of the target`);return n}Yo();var I3=12e4,Fc=!1,oi=0,hk=0,mk=1,ii=[],Hc=null,Js,dm={};function gk(){if(Hc===null)return;let e=Hc,t=e.clearTimeout.bind(window);Js!==void 0&&t(Js),Js=e.setTimeout.bind(window)(()=>{Js=void 0,Bc()},I3)}function Ek(){return Fc}function bk(){if(Fc||typeof window=="undefined")return;Fc=!0,oi=0,hk=Date.now(),Hc={setTimeout:Ur(window,"setTimeout"),clearTimeout:Ur(window,"clearTimeout"),setInterval:Ur(window,"setInterval"),clearInterval:Ur(window,"clearInterval"),dateNow:Ur(Date,"now")};let e=(r,o,i)=>{let s=mk;return mk+=1,ii.push({id:s,time:oi+Math.max(0,o),cb:r,interval:i}),s},t=r=>{ii=ii.filter(o=>o.id!==r)},n=(r,o)=>()=>{r(...o)};window.setTimeout=((r,o=0,...i)=>e(n(r,i),o)),window.clearTimeout=(r=>t(r)),window.setInterval=((r,o=0,...i)=>e(n(r,i),o,Math.max(1,o))),window.clearInterval=(r=>t(r)),dm={setTimeout:ke(window,"setTimeout"),clearTimeout:ke(window,"clearTimeout"),setInterval:ke(window,"setInterval"),clearInterval:ke(window,"clearInterval")},Date.now=()=>hk+oi,dm.dateNow=ke(Date,"now"),gk()}function _k(e){if(!Fc)return;let t=oi+Math.max(0,e),n=0;for(;n+=1,!(n>1e5);){let o=ii.filter(i=>i.time<=t).sort((i,s)=>i.time-s.time)[0];if(o===void 0)break;ii=ii.filter(i=>i!==o),oi=o.time,o.cb(),o.interval!==void 0&&ii.push({...o,time:oi+o.interval})}oi=t,gk()}function Bc(){if(!Fc||Hc===null)return;let e=Hc,t=ii;Js!==void 0&&(e.clearTimeout.bind(window)(Js),Js=void 0);let n=dm;dm={},window.setTimeout===n.setTimeout&&(window.setTimeout=e.setTimeout),window.clearTimeout===n.clearTimeout&&(window.clearTimeout=e.clearTimeout),window.setInterval===n.setInterval&&(window.setInterval=e.setInterval),window.clearInterval===n.clearInterval&&(window.clearInterval=e.clearInterval),Date.now===n.dateNow&&(Date.now=e.dateNow);let r=oi;if(Hc=null,ii=[],Fc=!1,oi=0,t.length===0)return;let o=e.setTimeout.bind(window),i=e.setInterval.bind(window),s=new Map,a={},l=u=>{s.delete(u),s.size===0&&a.current!==void 0&&L3(e,a.current)};for(let u of t)u.interval!==void 0?s.set(u.id,i(u.cb,u.interval)):s.set(u.id,o(()=>{l(u.id),u.cb()},Math.max(0,u.time-r)));a.current=C3(s,e,l)}function C3(e,t,n){let r=o=>{let i=o.bind(window);return(s=>{let a=e.get(s);if(a===void 0){i(s);return}i(a),n(s)})};return window.clearTimeout=r(t.clearTimeout),window.clearInterval=r(t.clearInterval),{clearTimeout:ke(window,"clearTimeout"),clearInterval:ke(window,"clearInterval")}}function L3(e,t){window.clearTimeout===t.clearTimeout&&(window.clearTimeout=e.clearTimeout),window.clearInterval===t.clearInterval&&(window.clearInterval=e.clearInterval)}var pm="_reticle_reload";function tt(e){return typeof e=="string"?e:void 0}function Nk(e){return typeof e=="number"?e:void 0}function wk(e){return typeof e=="object"&&e!==null?e:{}}function W3(e){if(typeof e!="object"||e===null)return;let t=e;if(!(typeof t.file!="string"||typeof t.line!="number"))return{file:t.file,line:t.line,column:Nk(t.column)}}function Y3(e){return{by:tt(e.by),value:tt(e.value),role:tt(e.role),name:tt(e.name),text:tt(e.text),label:tt(e.label),placeholder:tt(e.placeholder),testid:tt(e.testid),alt:tt(e.alt),component:tt(e.component),scope:tt(e.scope),self:e.self===!0?!0:void 0,attrs:Array.isArray(e.attrs)?e.attrs.filter(t=>typeof t=="string"):void 0,source:W3(e.source)}}function X3(e,t=!1){var h,E,S,A,w,N,O;let n=re.resolve(e);if(n===null)throw new Error(gd.staleRefMessage(e));let r=t&&typeof n.scrollIntoView=="function"&&Rd(n,n.getBoundingClientRect());r&&Od(n,{block:"center",inline:"center"});let o=n.getBoundingClientRect(),i=fr(n),s=n.ownerDocument.defaultView,a=s!==null?s.getComputedStyle(n):null,l=a!==null?{color:a.color,backgroundColor:a.backgroundColor,opacity:a.opacity,cursor:a.cursor,display:a.display,visibility:a.visibility}:null,u=Ih(Oh(n,i==null?void 0:i.source)),d=u!==void 0?void 0:BC(n.ownerDocument)?"This element has no source stamp. Others on the page do, so the stamping loader is running \u2014 the nearest stamped ancestor is out of range, or this element is rendered outside instrumented code.":"No element in this document carries a source stamp, so the stamping loader is not running: an older adapter, a bundler whose hook never ran, or a build the plugin was dropped from. Add @reticlehq/vite-plugin (or @reticlehq/babel-plugin) to the dev build and restart the dev server to get `file:line` back.",f={scrollTop:n.scrollTop,scrollHeight:n.scrollHeight,clientHeight:n.clientHeight,overflowY:(h=a==null?void 0:a.overflowY)!=null?h:"visible",scrollLeft:n.scrollLeft,scrollWidth:n.scrollWidth,clientWidth:n.clientWidth,overflowX:(E=a==null?void 0:a.overflowX)!=null?E:"visible"},m=aC(n);return{...go(n),...u!==void 0?{source:u}:{},...m.length>0?{paintContext:m}:{},...d!==void 0?{sourceUnavailable:d}:{},tag:n.tagName.toLowerCase(),href:(S=n.getAttribute("href"))!=null?S:void 0,formAction:(rd(n)||He(n))&&(w=(A=n.form)==null?void 0:A.getAttribute("action"))!=null?w:void 0,formText:(rd(n)||He(n))&&(O=(N=n.form)==null?void 0:N.textContent)!=null?O:void 0,box:{x:o.x,y:o.y,width:o.width,height:o.height},...r?{scrolledIntoView:!0}:{},...t?{[zR]:!Rd(n,o)}:{},occluded:q3(n,o),styles:l,scroll:f,theme:a!==null?ck(a):null,component:i}}function q3(e,t){return am(e,t)!==null}function J3(e){return typeof e=="object"&&e!==null&&"ok"in e&&typeof e.ok=="boolean"}var vk={ok:!1,reason:UR.UNAVAILABLE};function Q3(e,t,n,r){let o=ji();if(n!==void 0||r!==void 0){let l=mS(t);if(t!==void 0&&!Object.hasOwn(l,t))return{store:t,path:n,found:!1,value:null,storeNames:o};let u=t!==void 0?l[t]:{stores:l,storeNames:o},d=n!==void 0?i0(u,n):{found:!0,value:u},f=d.found&&r!==void 0?Sc(d.value,r):d.value,m=Ws(f);return{store:t,path:n,found:d.found,value:m.value,...m.truncation===void 0?{}:{truncation:m.truncation},..."availableKeys"in d?{availableKeys:d.availableKeys}:{},..."totalKeys"in d?{totalKeys:d.totalKeys}:{},storeNames:o}}let{stores:i,truncation:s}=Sd(t),a={stores:i,storeNames:o};if(s!==void 0&&(a.truncation=s),e!==void 0&&e.length>0){let l=re.resolve(e);if(l===null)a.component=vk;else{let u=$h(l);a.component=J3(u)?u:vk}}return a}function e8(){let e=document;return typeof e.getAnimations!="function"?{animations:[]}:{animations:e.getAnimations().map(n=>{var s;let r=n.effect,o=r==null?void 0:r.getTiming(),i=(s=r==null?void 0:r.target)!=null?s:null;return{playState:n.playState,currentTime:n.currentTime,duration:o==null?void 0:o.duration,target:i===null?null:go(i)}})}}function t8(e,t){if(e.length===0||e.length>Z.MAX_URL_LENGTH)return null;try{let n=new URL(e,t);return n.protocol==="http:"||n.protocol==="https:"?n.toString():null}catch{return null}}function Rk(){let e=new Map;return e.set(H.SNAPSHOT,t=>{var n;return Mh({scope:tt(t.scope),mode:(n=tt(t.mode))!=null?n:dc.FULL,includeRoot:t.includeRoot===!0,ids:t.ids===!0,audit:t.audit===!0})}),e.set(H.QUERY,t=>{let n=t.limit;return Wh(Y3(t),typeof n=="number"?n:void 0)}),e.set(H.MATCH,t=>xd(Hu.parse(wk(t.query)),tt(t.state),void 0,void 0,t.diagnose===!0,t[eI.FULL_TEXT]===!0)),e.set(H.ACT,async t=>{var o,i;let n=(o=tt(t.action))!=null?o:"",r=await Cd((i=tt(t.ref))!=null?i:"",n,wk(t.args));return jS(),r}),e.set(H.ACT_SEQUENCE,async t=>{let n=await lm(Array.isArray(t.steps)?t.steps:[]);return jS(),n}),e.set(H.INSPECT,t=>{var n;return X3((n=tt(t.ref))!=null?n:"",t[kR]===!0)}),e.set(H.ANIMATIONS,()=>e8()),e.set(H.CLOCK,t=>{if(t.reset===!0)Bc();else{t.freeze===!0&&bk();let n=t.advanceMs;typeof n=="number"&&_k(n)}return{frozen:Ek()}}),e.set(H.STATE_READ,t=>Q3(tt(t.ref),tt(t.store),tt(t.path),Nk(t.depth))),e.set(H.STORAGE_READ,t=>uk(tt(t.area))),e.set(H.CAPABILITIES,()=>Ki()),e.set(H.CAPTURE,t=>fk(t.fullPage===!0)),e.set(H.RENDER,()=>Promise.resolve().then(()=>(yk(),Ak)).then(t=>t.renderPage())),e.set(H.SCROLL,t=>{let n=t.dy,r=t.fraction;return q$(tt(t.ref),typeof n=="number"?n:void 0,typeof r=="number"?r:void 0)}),e.set(H.NAVIGATE,t=>{let n=tt(t.url);if(n===void 0||n.length===0)return{ok:!1,reason:"url required"};let r=t8(n,window.location.href);return r===null?{ok:!1,reason:"only http(s) navigation is allowed"}:(window.location.assign(r),{ok:!0,url:r})}),e.set(H.REFRESH,t=>{if(t.hard===!0){let n=new URL(window.location.href);n.searchParams.set(pm,String(Date.now())),window.location.replace(n.toString())}else window.location.reload();return{ok:!0}}),e}M();dt();_d();pr();function n8(e){if(typeof document=="undefined")return()=>{};let t=()=>{document.visibilityState==="visible"&&e()};return document.addEventListener("visibilitychange",t),()=>document.removeEventListener("visibilitychange",t)}var fm=1e3,r8=3e4;function o8(e){return Math.min(e*2,r8)}var i8=500,s8=1008,a8=3,Yt,si,qi,mm,bo,Ji,Vc,jc,Qi,Kc,kd,Zc,zd,Wc,Qs,Yc,Xc,fn,Dd,ze,Ok,Gc,KS,Ik,ZS,WS,Ck,$d,Lk,hm=class{constructor(t){x(this,ze);x(this,Yt);x(this,si,[]);x(this,qi,[]);x(this,mm,0);x(this,bo,!1);x(this,Ji,!1);x(this,Vc,!1);x(this,jc);x(this,Qi,fm);x(this,Kc,!1);x(this,kd,!1);x(this,Zc,0);x(this,zd,!1);x(this,Wc,0);x(this,Qs);x(this,Yc);x(this,Xc);x(this,fn);x(this,Dd);var n;g(this,fn,t),g(this,Dd,(n=t.now)!=null?n:qh)}connect(){var t,n;typeof WebSocket!="undefined"&&(g(this,bo,!1),(n=c(this,Xc))!=null||g(this,Xc,((t=c(this,fn).onVisible)!=null?t:n8)(()=>T(this,ze,Ok).call(this))),T(this,ze,Gc).call(this))}sendEvent(t){T(this,ze,$d).call(this,mo({kind:sn.EVENT,event:t}),{seq:t.seq,t:t.t,type:t.type})}redialAfterRefusal(){if(!c(this,bo)){if(c(this,Ji)&&c(this,Yt)===void 0){g(this,Ji,!1),g(this,Qi,fm),T(this,ze,Gc).call(this);return}g(this,Vc,!0)}}reannounce(){c(this,Yt)===void 0||c(this,Yt).readyState!==WebSocket.OPEN||c(this,Yt).send(JSON.stringify(c(this,fn).hello()))}close(){var t,n;g(this,bo,!0),(t=c(this,Xc))==null||t.call(this),g(this,Xc,void 0),(n=c(this,Yt))==null||n.close(),g(this,Yt,void 0)}};Yt=new WeakMap,si=new WeakMap,qi=new WeakMap,mm=new WeakMap,bo=new WeakMap,Ji=new WeakMap,Vc=new WeakMap,jc=new WeakMap,Qi=new WeakMap,Kc=new WeakMap,kd=new WeakMap,Zc=new WeakMap,zd=new WeakMap,Wc=new WeakMap,Qs=new WeakMap,Yc=new WeakMap,Xc=new WeakMap,fn=new WeakMap,Dd=new WeakMap,ze=new WeakSet,Ok=function(){c(this,bo)||(g(this,Qi,fm),c(this,Yt)===void 0&&(g(this,Ji,!1),T(this,ze,Gc).call(this)))},Gc=function(){let t;try{t=new WebSocket(c(this,fn).url)}catch{T(this,ze,WS).call(this),T(this,ze,ZS).call(this),T(this,ze,KS).call(this);return}g(this,Yt,t),t.onopen=()=>{var o,i,s;g(this,jc,void 0),g(this,Kc,!1),g(this,kd,!0),g(this,Qi,fm);let n=c(this,fn).hello();(o=c(this,Yc))!=null||g(this,Yc,n.sessionId),t.send(JSON.stringify(n)),T(this,ze,Lk).call(this,t,n.sessionId);let r=[...c(this,si),...c(this,qi)].sort((a,l)=>a.order-l.order);for(let a of r)t.send(a.text);g(this,si,[]),g(this,qi,[]),(s=(i=c(this,fn)).onConnected)==null||s.call(i)},t.onmessage=n=>{let r=n.data;T(this,ze,Ck).call(this,typeof r=="string"?r:String(r))},t.onclose=n=>{var r,o;if(g(this,Yt,void 0),n.code===s8){if(c(this,Vc)&&!c(this,bo)){g(this,Vc,!1),T(this,ze,Gc).call(this);return}g(this,Ji,!0);let i=n.reason.length>0?n.reason:"policy violation";Mr(`[reticle] bridge refused the connection: ${i} \u2014 not retrying until you come back to this tab.`),(o=(r=c(this,fn)).onConnectionLost)==null||o.call(r);return}T(this,ze,WS).call(this),T(this,ze,ZS).call(this),T(this,ze,KS).call(this)},t.onerror=()=>{t.close()}},KS=function(){var r;if(c(this,bo)||c(this,Ji))return;let t=c(this,Qi);g(this,Qi,o8(t)),((r=c(this,fn).schedule)!=null?r:de)(()=>T(this,ze,Ik).call(this),t)},Ik=function(){c(this,bo)||c(this,Yt)!==void 0||T(this,ze,Gc).call(this)},ZS=function(){var t,n;c(this,kd)||c(this,zd)||(g(this,Zc,c(this,Zc)+1),c(this,Zc)>=a8&&(g(this,zd,!0),(n=(t=c(this,fn)).onUnreachable)==null||n.call(t,{url:c(this,fn).url,attempts:c(this,Zc)})))},WS=function(){var n,r,o;let t=c(this,Dd).call(this);(n=c(this,jc))!=null||g(this,jc,t),!c(this,Kc)&&t-c(this,jc)>=XO.BRIDGE_LOST_MS&&(g(this,Kc,!0),(o=(r=c(this,fn)).onConnectionLost)==null||o.call(r))},Ck=async function(t){var s;let n;try{n=JSON.parse(t)}catch{return}let r=T_.safeParse(n);if(!r.success){let a=n==null?void 0:n.id;typeof a=="string"&&a.length>0&&T(this,ze,$d).call(this,mo({kind:sn.COMMAND_RESULT,id:a,ok:!1,error:"this page could not parse the command \u2014 the @reticlehq/browser SDK and the daemon are probably different versions. Nothing ran."}));return}let o=r.data;if(o.sessionId!==void 0&&o.sessionId!==c(this,Yc)){T(this,ze,$d).call(this,mo({kind:sn.COMMAND_RESULT,id:o.id,ok:!1,error:`command addressed to session ${o.sessionId} but this page is ${(s=c(this,Yc))!=null?s:"(none)"} \u2014 the page reconnected under a new id, or two sessions share a socket. Nothing ran.`}));return}let i;try{i=await c(this,fn).handleCommand(o)}catch(a){i={ok:!1,error:a instanceof Error?a.message:String(a)}}T(this,ze,$d).call(this,mo({kind:sn.COMMAND_RESULT,id:o.id,ok:i.ok,result:i.result,error:i.error}))},$d=function(t,n){if(c(this,Yt)!==void 0&&c(this,Yt).readyState===WebSocket.OPEN){c(this,Yt).send(t);return}if(c(this,si).length+c(this,qi).length>=i8){let i=c(this,si).length>0?c(this,si).shift():c(this,qi).shift();if((i==null?void 0:i.event)!==void 0){g(this,Wc,c(this,Wc)+1);let s=c(this,Qs);(s===void 0||i.event.t<s.t)&&g(this,Qs,i.event)}}let r=n!==void 0&&DO.has(n.type),o=OA(this,mm)._++;r?c(this,si).push({text:t,event:n,order:o}):c(this,qi).push({text:t,event:n,order:o})},Lk=function(t,n){let r=c(this,Qs);if(r===void 0)return;let o={t:r.t,seq:r.seq,type:v.TRANSPORT_OVERFLOW,sessionId:n,data:{dropped:c(this,Wc)}};t.send(mo({kind:sn.EVENT,event:o})),g(this,Qs,void 0),g(this,Wc,0)};YS();ni();M();Xs();function kk(){let e=[$.UI,$.NET,$.LOG,$.ROUTE,$.STORAGE,$.TIME,$.SIGNAL];return ji().length>0?[...e,$.STATE]:e}M();var c8="__TAURI_INTERNALS__";function zk(){if(typeof window=="undefined")return uo.SERVICE;let e=window;return e[Zo]!==void 0||e[c8]!==void 0?uo.WEBVIEW:uo.WEB}var l8=[H.SNAPSHOT,H.QUERY,H.MATCH,H.INSPECT,H.ACT,H.ACT_SEQUENCE,H.ANIMATIONS,H.NARRATE,H.CLOCK,H.CAPABILITIES,H.STATE_READ,H.STORAGE_READ,H.SCROLL,H.SESSION_CONFIG,H.PRESENTER,H.IMPACT,H.CAPTURE,H.RENDER,H.NAVIGATE,H.REFRESH,H.FLOWS,H.FLOW_PROGRESS,H.PLAN,H.MARKERS];function Dk(){return[...l8]}Zi();It();M();Et();Dr();gt();ot();qo();dn();function u8(e){var t,n;try{return(n=(t=e.contentDocument)==null?void 0:t.body)!=null?n:null}catch{return null}}function XS(e){let t=[],n=(r,o)=>{if(!(o>=3))for(let i of r.querySelectorAll("iframe")){let s=u8(i);s!==null&&(t.push(s),n(s,o+1))}};return n(e,0),t}function Pk(e){let t=new AbortController,n=()=>{for(let o of XS(document))e(o)};n();let r=o=>{o.target instanceof HTMLIFrameElement&&n()};return document.addEventListener("load",r,{capture:!0,signal:t.signal}),()=>t.abort()}function Mk(e){var r;let t=wn(e)?e:null;if(t===null)return;let n=t.closest(jn());return(r=n?Ne(n):null)!=null?r:re.refFor(t)}var d8=["class","hidden","disabled","open","aria-hidden","aria-expanded","aria-selected","aria-checked","data-state","style","src","href","value"],Uk=120;function Em(e){if(e!==null)return e.length>Uk?`${e.slice(0,Uk)}\u2026`:e}var p8=new Set(["dialog","alertdialog"]),f8=new Set(["alert","status"]),Pd=40;function Hk(e,t){return e!=="generic"||t.length>0}var h8=40;function Fk(e){let t=Re(e),n=Ae(e);if(Hk(t,n))return{role:t,name:n,el:e};let r=0;for(let o of e.querySelectorAll("*")){if(r>=h8)return;if(r+=1,Hi(o))continue;let i=Re(o),s=Ae(o);if(Hk(i,s))return{role:i,name:s,el:o}}}var m8=3;function qS(e){var r;let t="";for(let o of e)o.nodeType===m8&&(t+=(r=o.nodeValue)!=null?r:"");let n=t.trim();return n.length>0?n:void 0}var g8=new Set(["class","style","type","disabled","readonly","required","hidden"]);function E8(e,t){return!g8.has(t)&&!t.startsWith("aria-")&&pn(e)}var b8=3,_8=50;function S8(e){let t=e;for(let n=0;t!==null&&n<=b8;n+=1){let r=Ne(t);if(r!==null&&r.length>0)return r;t=t.parentElement}}var Bk=e=>{let t=S8(e);return t===void 0?{}:{testid:t}};function Gk(e){let t=eC(),n=new MutationObserver(s=>{var m,h,E,S,A,w,N;let a=0,l=0,u=0,d=0,f=0;for(let O of s){if(O.type==="attributes"){let k=O.target;if(wn(k)&&O.attributeName!==null&&!Hi(k)){if(u>=Pd){f+=1;continue}u+=1;let G=E8(k,O.attributeName),V=G?ve:Em(k.getAttribute(O.attributeName)),W=G&&O.oldValue!==null?ve:Em(O.oldValue);e(v.DOM_ATTR,{attr:O.attributeName,...V===void 0?{}:{value:V},...W===void 0?{}:{old:W}},re.refFor(k))}continue}if(O.type==="characterData"){let k=O.target.parentElement;if(k!==null&&!Hi(k)){if(u>=Pd){f+=1;continue}u+=1;let G=pn(k),V=G?ve:((m=O.target.textContent)!=null?m:"").trim().slice(0,80),W=G?void 0:Em((E=(h=O.oldValue)==null?void 0:h.trim())!=null?E:null);e(v.DOM_TEXT,{text:V,...W===void 0?{}:{old:W},...Bk(k)},re.refFor(k))}continue}if(qS(O.addedNodes)!==void 0||qS(O.removedNodes)!==void 0){let k=wn(O.target)?O.target:null;if(k!==null&&!Hi(k))if(u>=Pd)f+=1;else{u+=1;let G=pn(k),V=G?ve:((S=k.textContent)!=null?S:"").trim().slice(0,80),W=G?void 0:Em((A=qS(O.removedNodes))!=null?A:null);e(v.DOM_TEXT,{text:V,...W===void 0?{}:{old:W},...Bk(k)},re.refFor(k))}}for(let k of O.addedNodes){if(!wn(k))continue;if(a>=Pd){f+=1;continue}if(Hi(k))continue;let G=[k,...Array.from(k.querySelectorAll(jn()))].filter(le=>Ne(le)!==null);for(let le of G){let ge=((w=le.textContent)!=null?w:"").trim();if(ge.length===0)continue;if(d>=_8){f+=1;continue}d+=1;let Xe=pn(le)?ve:ge.slice(0,80);e(v.DOM_TEXT,{text:Xe,testid:(N=Ne(le))!=null?N:"",initial:!0},re.refFor(le))}let V=Fk(k);if(V===void 0)continue;let{role:W,name:K}=V;a+=1;let J=re.refFor(V.el);e(v.DOM_ADDED,{role:W,name:K,region:Mk(O.target)},J),(p8.has(W)||f8.has(W)||k.getAttribute("aria-modal")==="true")&&Ke(k)&&e(v.VISIBLE_SHOWN,{role:W,name:K},J)}for(let k of O.removedNodes){if(!wn(k))continue;if(l>=Pd){f+=1;continue}if(Hi(k)||wn(O.target)&&Hi(O.target))continue;let G=Fk(k);if(G===void 0)continue;let{role:V,name:W}=G;l+=1,e(v.DOM_REMOVED,{role:V,name:W,region:Mk(O.target)})}}f>0&&e(v.TRUNCATED,{channel:Kf.DOM,dropped:f})}),r={subtree:!0,childList:!0,attributes:!0,attributeFilter:d8,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0};n.observe(document.documentElement,r);for(let s of q0())n.observe(s,r);let o=Q0(s=>n.observe(s,r)),i=Pk(s=>n.observe(s,r));return()=>{i(),o(),t(),n.disconnect()}}M();Xs();pr();function Vk(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function T8(e,t){if(!Vk(e)||!Vk(t))return Object.is(e,t)?[]:[{path:"",old:e,new:t}];let n=[];for(let r of new Set([...Object.keys(e),...Object.keys(t)]))Object.is(e[r],t[r])||n.push({path:r,old:e[r],new:t[r]});return n}function jk(e,t){return St(e)?ve:dd(t)}function Kk(e,t){if(Object.is(e,t))return!0;try{return JSON.stringify(e)===JSON.stringify(t)}catch{return!1}}function Zk(e){try{return e()}catch{return}}function Wk(e){let t=new Map,n=([o,i,s])=>{var l;try{(l=t.get(o))==null||l()}catch{}let a=Zk(i);t.set(o,s(()=>{oe(()=>{let u=Zk(i),d=T8(a,u);a=u;for(let f of d){let m=jk(f.path,f.new),h=jk(f.path,f.old);(St(f.path)?Kk(dd(f.old),dd(f.new)):Kk(h,m))||oe(()=>e(v.STATE_CHANGE,{name:o,path:f.path,value:m,old:h}))}})}))};for(let o of zL())n(o);t.size===0&&e(v.BLIND_SPOT,{kind:cn.UNWATCHED_STATE,count:1});let r=LL(o=>{let i=t.size===0;n(o),i&&t.size>0&&e(v.BLIND_SPOT,{kind:cn.UNWATCHED_STATE,count:0})});return()=>{r();for(let o of t.values())try{o()}catch{}t.clear()}}M();Et();function qc(e){if(!(e instanceof Element)||e===document.body)return;let t=Re(e),n=Ae(e);return n.length>0?`${t} "${n}"`:t}function x8(e){return e===null||e===document.body}function Yk(e){let t=new AbortController,{signal:n}=t,r=null,o=s=>{let a=s.target,l=r;r=a,e(v.FOCUS_CHANGE,{...qc(a)===void 0?{}:{to:qc(a)},...qc(l)===void 0?{}:{from:qc(l)},toBody:x8(a)})},i=s=>{if(s.relatedTarget!==null)return;let a=r;r=null,e(v.FOCUS_CHANGE,{...qc(a)===void 0?{}:{from:qc(a)},toBody:!0})};return document.addEventListener("focusin",o,{signal:n}),document.addEventListener("focusout",i,{signal:n}),()=>t.abort()}M();function A8(e){let t=e;for(let n=0;n<3;n+=1){let r=Array.from(t.children).filter(i=>i instanceof HTMLElement),o=r.length===1?r[0]:void 0;if(o===void 0||o.offsetHeight<t.scrollHeight*.9)return t;t=o}return t}function y8(e){let t=e.scrollHeight,n=e.clientHeight;if(n<=0||t<n*1.2)return 0;let r=A8(e),o=Array.from(r.children).filter(m=>m instanceof HTMLElement);if(o.length<2)return 0;let i=1/0,s=0,a=0,l=e.getBoundingClientRect(),u=e.offsetHeight>0&&l.height>0?l.height/e.offsetHeight:1;for(let m of o){let h=(m.getBoundingClientRect().top-l.top)/u-e.clientTop+e.scrollTop,E=h+m.offsetHeight;h<i&&(i=h),E>s&&(s=E),a+=m.offsetHeight}let d=Math.max(0,i)+Math.max(0,t-s);if(d<t*.25)return 0;let f=a/o.length;return f<=0?0:Math.round(d/f)}function Xk(){let e=0;for(let t of document.querySelectorAll("*"))t.scrollHeight<=t.clientHeight||(e+=y8(t));return e}qo();dt();function w8(){var t;let e=0;for(let n of document.querySelectorAll("*"))n.tagName.includes("-")&&n.shadowRoot===null&&(J0(n)||n.children.length>0||((t=n.textContent)!=null?t:"").trim().length>0||n.offsetHeight<=0&&n.offsetWidth<=0||(e+=1));return e}function v8(e){let t=e.getAttribute("src");if(t===null||t.length===0)return!1;try{return e.contentDocument===null}catch{return!0}}function N8(e){let t=0;for(let n of e)v8(n)&&(t+=1);return t}function R8(){return N8(Array.from(document.querySelectorAll("iframe")))}function O8(){return XS(document).length}var I8=250;function qk(e){let t=[{kind:cn.CROSS_ORIGIN_IFRAME,count:R8},{kind:cn.UNINSTRUMENTED_FRAME,count:O8},{kind:cn.CLOSED_SHADOW_ROOT,count:w8},{kind:cn.VIRTUALIZED_UNMOUNTED,count:Xk}],n=new Map,r=()=>{for(let s of t){let a=s.count(),l=n.get(s.kind);a!==l&&(n.set(s.kind,a),(a>0||l!==void 0)&&e(v.BLIND_SPOT,{kind:s.kind,count:a}))}};r();let o,i=new MutationObserver(()=>{o===void 0&&(o=de(()=>{o=void 0,r()},I8))});return i.observe(document.documentElement,{childList:!0,subtree:!0}),()=>{o!==void 0&&Oe(o),i.disconnect()}}M();Yo();M();pr();dt();M();pr();var C8=/^text\/event-stream(?:\s*;|\s*$)/i,JS="data:",L8="data",$8=/^[{[]/,k8=/^\[[A-Z_]+\]$/;function es(e){return e!==null&&C8.test(e)}function Jk(e){return L8===e||e.startsWith(JS)}function Qk(e){let t=!1;return{body:e.replace(/\r\n?/g,`
1826
1826
  `).split(`
1827
1827
 
1828
1828
  `).map(o=>{let i=o.split(`
1829
- `),s=i.filter(Pk).map(u=>u.slice(FS.length).replace(/^ /,"")).join(`
1830
- `);if(!X3.test(s.trimStart())||q3.test(s.trim()))return o;let a;try{let u=Zs(JSON.parse(s));a=JSON.stringify(u.value),u.truncation!==void 0&&(t=!0)}catch{a=ve,t=!0}let l=!0;return i.flatMap(u=>Pk(u)?l?(l=!1,[`${FS} ${a}`]):[]:[u]).join(`
1829
+ `),s=i.filter(Jk).map(u=>u.slice(JS.length).replace(/^ /,"")).join(`
1830
+ `);if(!$8.test(s.trimStart())||k8.test(s.trim()))return o;let a;try{let u=Ws(JSON.parse(s));a=JSON.stringify(u.value),u.truncation!==void 0&&(t=!0)}catch{a=ve,t=!0}let l=!0;return i.flatMap(u=>Jk(u)?l?(l=!1,[`${JS} ${a}`]):[]:[u]).join(`
1831
1831
  `)}).join(`
1832
1832
 
1833
- `),truncated:t}}var J3=/application\/json|text\/|application\/xml|x-www-form-urlencoded|graphql/i,Hk=/event-stream|x-ndjson|application\/stream/i,Q3=/event-stream/i;function Fk(e,t){return e!==null&&Q3.test(e)?!1:t===null}var e8=500;async function Bk(e){let t;try{return await Promise.race([e,new Promise(n=>{t=ue(()=>n(void 0),e8)})])}finally{t!==void 0&&Re(t)}}function GS(e){if(e!==null)return Hk.test(e)?sr.STREAMING:sr.NOT_TEXT}function VS(e){return e===null||Hk.test(e)?!1:J3.test(e)}var Gk=8192,t8=262144,n8=256,Yc=Gk;function Vk(e){Number.isFinite(e)&&(Yc=Math.min(t8,Math.max(n8,Math.floor(e))))}function jk(){return Yc}var r8=Gk*2;function o8(e){let t=Yc*2;return e?Math.min(t,r8):t}var i8=/\b(Bearer|Basic)\s+(?=[A-Za-z0-9._~+/=-]{16,})(?=[A-Za-z0-9._~+/=-]*[\d._~+/=-])[A-Za-z0-9._~+/=-]+/gi;function BS(e){return e.replace(i8,(t,n)=>`${n} ${ve}`).replace(/([A-Za-z0-9_.-]+)("?\s*[=:]\s*)("(?:\\.|[^"\\])*"?|[^&\s,;"}]+)/g,(t,n,r,o)=>{if(!St(n))return t;let i=o.startsWith('"')?`"${ve}"`:ve;return`${n}${r}${i}`})}var Uk=4096;function jS(e,t){return t&&e>=400}function hm(e,t){let n=Eo(e,t);return n.body.length<=Uk?n:{body:n.body.slice(0,Uk),truncated:!0}}function Eo(e,t){let n=t!==null&&/json|graphql/i.test(t),r=o8(!n),o=e.length>r,i=o?e.slice(0,r):e,s=!1,a;if(n)try{a=fo(JSON.parse(i))}catch{a=BS(i)}else if(Qi(t)){let u=Mk(i);a=BS(u.body),s=u.truncated}else a=BS(i);a=io(a);let l=s||o||a.length>Yc;return{body:a.length>Yc?a.slice(0,Yc):a,truncated:l}}var s8=/text\/|json|csv|xml|ndjson|javascript/i,a8=2e3;function Kk(e,t={}){if(typeof URL.createObjectURL!="function")return()=>{};let n=new AbortController,r=URL.createObjectURL.bind(URL),o=new Map,i=ke(URL,"createObjectURL"),s=function(h){let E=r(h);return oe(()=>{if(typeof Blob!="undefined"&&h instanceof Blob){let _=s8.test(h.type)?h.text().catch(()=>{}):Promise.resolve(void 0);o.set(E,{type:h.type,size:h.size,text:_})}}),E};URL.createObjectURL=s;let a=(m,h)=>{let E=o.get(m);E!==void 0&&(o.delete(m),E.text.then(_=>{oe(()=>{l(E,h,_)})}))},l=(m,h,E)=>{let _={mimeType:m.type,bytes:m.size};if(h!==void 0&&h.length>0&&(_.filename=h),E!==void 0&&(_.lines=E.split(`
1834
- `).filter(A=>A.length>0).length,t.capturePreview===!0)){let{body:A,truncated:v}=Eo(E.slice(0,a8),m.type);_.preview=A,v&&(_.previewTruncated=!0)}e(w.DOWNLOAD,_)},u=m=>{oe(()=>{var _,A;let h=m.target,E=h instanceof Element?h.closest("a[download]"):null;E!==null&&a((_=E.getAttribute("href"))!=null?_:"",(A=E.getAttribute("download"))!=null?A:void 0)})};document.addEventListener("click",u,{capture:!0,signal:n.signal});let d=ke(HTMLAnchorElement.prototype,"click"),f=function(){let h=Zt(()=>{var E,_;return this.hasAttribute("download")?{href:(E=this.getAttribute("href"))!=null?E:"",name:(_=this.getAttribute("download"))!=null?_:void 0}:void 0});d.call(this),oe(()=>{h!==void 0&&a(h.href,h.name)})};return HTMLAnchorElement.prototype.click=f,()=>{n.abort(),URL.createObjectURL===s&&(URL.createObjectURL=i),HTMLAnchorElement.prototype.click===f&&(HTMLAnchorElement.prototype.click=d),o.clear()}}M();Wo();function Zk(e){let t=ke(window,"open");if(t===void 0)return()=>{};let r=function(o,i,s){let a=t.call(this,o,i,s);return oe(()=>{e(w.CONTEXT_OPENED,{...o===void 0?{}:{href:o}})}),a};return window.open=r,()=>{window.open===r&&(window.open=t)}}M();Wo();M();dt();var c8=1e4,l8=4,u8=2;async function d8(e,t){var f;if(t.aborted||typeof((f=e.body)==null?void 0:f.getReader)!="function")return;let n=e.body.getReader(),r=new TextDecoder,o=jk()*u8,i="",s=!1,a=!1,l=()=>{},u=new Promise(m=>{l=()=>{a=!0,m()}}),d=ue(l,c8);t.addEventListener("abort",l,{once:!0});try{await Promise.race([(async()=>{for(;!a&&!t.aborted;){let m=await n.read();if(a||t.aborted)return;if(m.done){i+=r.decode(),s=!0;return}let h=o-i.length,E=m.value.subarray(0,h*l8),_=r.decode(E,{stream:!0});if(i+=_.slice(0,h),i.length>=o||E.byteLength<m.value.byteLength)return}})(),u])}catch{}finally{Re(d),t.removeEventListener("abort",l),s||n.cancel().catch(()=>{}),n.releaseLock()}return!s&&i.length===0?void 0:{text:i,complete:s}}async function KS(e,t,n,r){let o=n?{responseBodyReason:sr.UNREADABLE}:{};if(Qi(t)&&(!n||r.aborted))return o;try{let i=e.clone(),s,a=!1;if(Qi(t)){let u=await d8(i,r);s=u==null?void 0:u.text,a=(u==null?void 0:u.complete)===!1}else s=await Bk(i.text());if(s===void 0)return o;let l=n?Eo(s,t):hm(s,t);return{responseBody:l.body,...a||l.truncated?{responseBodyTruncated:!0}:{},...n?{}:{responseBodyReason:sr.ERROR_STATUS}}}catch{return o}}M();M();dt();var p8=1e4;function Wk(e,t,n,r,o,i){var l;if(!Fk(o,i)||typeof((l=t.body)==null?void 0:l.getReader)!="function")return;let s;try{s=t.clone()}catch{return}let a=s.body;a!==null&&(e(w.NET_STREAM,{transport:ao.FETCH,direction:co.OPEN,...r,id:n}),(async()=>{let u=a.getReader(),d=!1,f,m=new Promise(h=>{f=ue(()=>h("expired"),p8)});try{for(;;){let h=await Promise.race([u.read(),m]);if(h==="expired"){d=!0,u.cancel().catch(()=>{});break}if(h.done)break}}catch{}finally{f!==void 0&&Re(f)}e(w.NET_STREAM,{transport:ao.FETCH,direction:co.CLOSE,...r,id:n,...d?{gaveUp:!0}:{}})})())}M();function f8(e){if(e instanceof ArrayBuffer)return e.byteLength;if(typeof Blob!="undefined"&&e instanceof Blob)return e.size;if(ArrayBuffer.isView(e))return e.byteLength}function mm(e,t){if(typeof e!="string"){let r=f8(e);return r===void 0?{frameType:typeof e}:{frameType:"binary",frameBytes:r}}let n={frameBytes:e.length};if(t){let{body:r,truncated:o}=Eo(e,"application/json");n.frame=r,o&&(n.frameTruncated=!0)}return n}function Yk(e){try{return new URL(e,location.href).pathname===zs}catch{return e.includes(zs)}}var Xc={NULL:"0",STRING:"s",NUMBER:"n",BOOLEAN:"b",OTHER:"?"};function bm(e){if(e===null)return Xc.NULL;if(Array.isArray(e))return`[${e.map(bm).join(",")}]`;if(typeof e=="object"){let t=e;return`{${Object.keys(t).sort().map(n=>`${n}:${bm(t[n])}`).join(",")}}`}return typeof e=="string"?Xc.STRING:typeof e=="number"?Xc.NUMBER:typeof e=="boolean"?Xc.BOOLEAN:Xc.OTHER}function YS(e,t){return _c(`${e}#${String(t)}`)}function h8(e){try{return bm(JSON.parse(e))}catch{return Xc.OTHER}}var m8=1<<20,g8=9,E8=10,b8=13,_8=32,S8=127;function T8(e){for(let t=0;t<e.length;t+=1){let n=e.charCodeAt(t);if(n===S8||n<_8&&n!==g8&&n!==E8&&n!==b8)return!0}return!1}function x8(e){if((e instanceof ArrayBuffer||ArrayBuffer.isView(e))&&!(e.byteLength>m8))try{let t=new TextDecoder("utf-8",{fatal:!0}).decode(e);return T8(t)?void 0:t}catch{return}}function A8(e){let t=[],n=0;return e.forEach((r,o)=>{typeof r=="string"&&(n+=r.length),t.push(JSON.stringify([o,typeof r=="string"?0:[r.type,r.size]]))}),t.length===0?void 0:YS(t.sort().join(),n)}function ZS(e,t){let n,r="application/json",o=_O,i=x8(e),s=()=>{var d,f;return(f=(d=e.constructor)==null?void 0:d.name)!=null?f:typeof e};if(typeof e=="string"||i!==void 0)n=i!=null?i:e,n.length>0&&(o=YS(h8(n),n.length));else if(typeof FormData!="undefined"&&e instanceof FormData){let d=A8(e);return{...d===void 0?{}:{[Uu]:d},...t?{requestBodyType:s()}:{}}}else if(typeof URLSearchParams!="undefined"&&e instanceof URLSearchParams){if(n=e.toString(),r="application/x-www-form-urlencoded",n.length>0){let d=Object.fromEntries(new URLSearchParams(n));o=YS(bm(d),n.length)}}else if(e!=null)return t?{requestBodyType:s()}:{};let a={[Uu]:o};if(!t||n===void 0||n.length===0)return a;let{body:l,truncated:u}=Eo(n,r);return u?{...a,requestBody:l,requestBodyTruncated:!0}:{...a,requestBody:l}}function Xk(e){return e>=200&&e<400}function qk(e,t,n){let r={};e!==""&&(r.statusText=e),t!==null&&t!==""&&(r.contentType=t);let o=n!==null?Number.parseInt(n,10):Number.NaN;return Number.isFinite(o)&&(r.responseSize=o),r}function y8(e){return typeof e=="string"?e:e instanceof URL?e.href:e.url}function w8(e,t){return(t==null?void 0:t.method)!==void 0?t.method.toUpperCase():e instanceof Request?e.method.toUpperCase():"GET"}function v8(e,t){var n,r;if(t!==void 0&&t.headers!==void 0)return(n=Zt(()=>new Headers(t.headers).get(Kb)))!=null?n:void 0;if(e instanceof Request)return(r=Zt(()=>e.headers.get(Kb)))!=null?r:void 0}var N8=/@reticlehq|reticle\.ts|network\.ts|transport\.ts|<anonymous>|new Promise|node:internal/i,R8=/node_modules|\/\.vite\/deps\//i;function O8(e){var r;if(e===void 0)return;let t=e.split(`
1835
- `).slice(1).map(o=>o.trim()).filter(o=>o.length>0&&!N8.test(o)),n=t.find(o=>!R8.test(o));return(r=n!=null?n:t[0])==null?void 0:r.slice(0,300)}function WS(){return O8(new Error().stack)}function I8(e){if(e===void 0)return{};let t={};return e.responseStart>0&&e.requestStart>0&&(t.ttfbMs=Math.round(e.responseStart-e.requestStart)),e.transferSize>0&&(t.transferSize=e.transferSize),t}function Jk(e){try{let t=performance.getEntriesByName(e,"resource");return I8(t[t.length-1])}catch{return{}}}function C8(e){try{return Function.prototype.toString.call(e).includes("native code")}catch{return!1}}var Qk=new WeakSet,gm=Symbol.for("reticle.network"),Em=()=>window;function ez(e,t={}){var wi,dA,pA;if(Em()[gm]!==void 0)return()=>{};let n={};Em()[gm]=n;let r=t.captureBodies===!0,o=new AbortController,i=t.captureErrorBodies!==!1,s=t.reinterpret,a=Dr(window,"fetch"),l=a.bind(window);!C8(a)&&!Qk.has(a)&&e(w.BLIND_SPOT,{kind:cn.WRAPPED_NETWORK,count:1});let u=0,d=()=>`n${++u}`;window.fetch=async(Fe,xe)=>{var fA,hA,mA;let _t=y8(Fe);if(((fA=t.ignore)==null?void 0:fA.call(t,_t))===!0)return l(Fe,xe);let Lt=d(),st=performance.now(),$t=w8(Fe,xe),jt=v8(Fe,xe),vi=jt===void 0?{}:{[Xf]:jt},vs=(hA=Zt(()=>ZS(xe==null?void 0:xe.body,r)))!=null?hA:{},Ni=oo(_t),Ns=Ni.url,qp=Zt(()=>WS()),jg=qp===void 0?{}:{initiatorStack:qp};oe(()=>{e(w.NET_PENDING,{id:Lt,method:$t,...Ni,initiator:"fetch",...jg})});try{let kt=await l(Fe,xe),_5=performance.now(),Rs=(mA=Zt(()=>kt.headers.get("content-type")))!=null?mA:null;oe(()=>{Wk(e,kt,Lt,Ni,Rs,kt.headers.get("content-length"))}),me.add(_t);let Kg=Os=>{oe(()=>{var gA;e(w.NET_REQUEST,{id:Lt,method:$t,...Ni,status:kt.status,ok:Xk(kt.status),durationMs:Math.round(_5-st),initiator:"fetch",...jg,...Jk(_t),...qk(kt.statusText,Rs,kt.headers.get("content-length")),...vs,...vi,...Os,...(gA=s==null?void 0:s(Ns,T5=>kt.headers.get(T5)))!=null?gA:{}})})},S5=jS(kt.status,i);if(r&&Qi(Rs))Kg({responseBodyReason:sr.UNREADABLE}),KS(kt,Rs,!0,o.signal).then(Os=>{typeof Os.responseBody=="string"&&oe(()=>e(w.NET_RESPONSE_BODY,{id:Lt,method:$t,...Ni,...Os}))}).catch(()=>{});else if((r||S5)&&VS(Rs))KS(kt,Rs,r,o.signal).then(Kg).catch(()=>{});else{let Os=r?GS(Rs):void 0;Kg(Os===void 0?{}:{responseBodyReason:Os})}return kt}catch(kt){throw oe(()=>{e(w.NET_REQUEST,{id:Lt,method:$t,url:Ns,status:0,ok:!1,error:kt instanceof Error?kt.message:String(kt),durationMs:Math.round(performance.now()-st),initiator:"fetch",...jg,...vi})}),kt}};let f=Dr(window,"fetch");Qk.add(f);let m=new WeakMap,h=XMLHttpRequest.prototype,E=ke(h,"open"),_=ke(h,"send"),A=E;h.open=function(Fe,xe,..._t){oe(()=>{m.set(this,{id:d(),method:Fe.toUpperCase(),url:cr(String(xe)),rawUrl:String(xe),start:0})}),A.call(this,Fe,xe,..._t)};let v=ke(h,"open"),N=new WeakSet;h.send=function(Fe){oe(()=>{var _t;let xe=m.get(this);if(xe!==void 0){xe.start=performance.now(),xe.reqFields=(_t=Zt(()=>ZS(Fe!=null?Fe:null,r)))!=null?_t:{},xe.initiatorStack=WS();let Lt=xe.initiatorStack===void 0?{}:{initiatorStack:xe.initiatorStack};e(w.NET_PENDING,{id:xe.id,method:xe.method,...oo(xe.rawUrl),initiator:"xhr",...Lt}),N.has(this)||(N.add(this),this.addEventListener("loadend",()=>{oe(()=>{let st=m.get(this);if(st===void 0)return;me.add(st.rawUrl);let $t=this.getResponseHeader("content-type"),jt={},vi=this.responseType===""||this.responseType==="text",vs=jS(this.status,i),Ni=VS($t)||r&&Qi($t);if(r){let Ns=Ni?sr.UNREADABLE:GS($t);Ns!==void 0&&(jt={responseBodyReason:Ns})}if((r||vs)&&vi&&Ni)try{let{body:Ns,truncated:qp}=r?Eo(this.responseText,$t):hm(this.responseText,$t);jt={responseBody:Ns,...qp?{responseBodyTruncated:!0}:{},...r?{}:{responseBodyReason:sr.ERROR_STATUS}}}catch{}e(w.NET_REQUEST,{id:st.id,method:st.method,...oo(st.rawUrl),status:this.status,ok:Xk(this.status),durationMs:Math.round(performance.now()-st.start),initiator:"xhr",...st.initiatorStack===void 0?{}:{initiatorStack:st.initiatorStack},...Jk(st.rawUrl),...qk(this.statusText,$t,this.getResponseHeader("content-length")),...st.reqFields,...jt})})}))}}),_.call(this,Fe!=null?Fe:null)};let O=ke(h,"send"),k=window.EventSource,j=window.WebSocket,Y,X;r&&typeof k=="function"&&(window.EventSource=class extends k{constructor(Fe,xe){super(Fe,xe),oe(()=>{let _t=oo(String(Fe));e(w.NET_STREAM,{transport:ao.SSE,direction:co.OPEN,..._t}),this.addEventListener("message",Lt=>{oe(()=>{e(w.NET_STREAM,{transport:ao.SSE,direction:co.IN,..._t,...mm(Lt.data,r)})})})})}},Y=window.EventSource),r&&typeof j=="function"&&(window.WebSocket=(dA=class extends j{constructor(xe,_t){super(xe,_t);x(this,wi);g(this,wi,Yk(String(xe))),!c(this,wi)&&oe(()=>{let Lt=oo(String(xe));e(w.NET_STREAM,{transport:ao.WS,direction:co.OPEN,...Lt}),this.addEventListener("message",st=>{oe(()=>{e(w.NET_STREAM,{transport:ao.WS,direction:co.IN,...Lt,...mm(st.data,r)})})})})}send(xe){if(c(this,wi)){super.send(xe);return}super.send(xe),oe(()=>{e(w.NET_STREAM,{transport:ao.WS,direction:co.OUT,...oo(this.url),...mm(xe,r)})})}},wi=new WeakMap,dA),X=window.WebSocket);let G=typeof navigator!="undefined"?Object.getPrototypeOf(navigator):null,ee=G===null||(pA=Object.getOwnPropertyDescriptor(G,"sendBeacon"))==null?void 0:pA.value,be;G!==null&&ee!==void 0&&(be=function(Fe,xe){let _t=d(),Lt=Zt(()=>oo(String(Fe))),st=Zt(()=>WS()),$t=ee.call(this,Fe,xe);return oe(()=>{e(w.NET_REQUEST,{id:_t,method:"POST",...Lt,status:0,ok:$t,queued:$t,durationMs:0,initiator:"beacon",...st===void 0?{}:{initiatorStack:st},...ZS(xe,!1)})}),$t},G.sendBeacon=be);let me=new Set,it=0,Xp=200,Wa;if(typeof PerformanceObserver!="undefined")try{let Fe=new PerformanceObserver(xe=>{var _t,Lt,st;for(let $t of xe.getEntries()){let jt=$t;if(it>=Xp)return;let vi=jt.initiatorType||"other";if(vi==="fetch"||vi==="xmlhttprequest")continue;let vs=jt.name;me.has(vs)||(me.add(vs),it+=1,e(w.NET_REQUEST,{id:d(),method:"GET",...oo(vs),durationMs:Math.round(jt.duration),initiator:vi,...jt.transferSize>0?{transferSize:jt.transferSize}:{},...((_t=jt.responseStatus)!=null?_t:0)>0?{status:jt.responseStatus,ok:((Lt=jt.responseStatus)!=null?Lt:0)>=200&&((st=jt.responseStatus)!=null?st:0)<400}:{}}))}});Wa=Fe,Fe.observe({type:"resource",buffered:!0})}catch{}return()=>{Em()[gm]===n&&delete Em()[gm],o.abort(),Wa==null||Wa.disconnect(),window.fetch===f&&(window.fetch=a),ke(h,"open")===v&&(h.open=E),ke(h,"send")===O&&(h.send=_),Y!==void 0&&window.EventSource===Y&&(window.EventSource=k),X!==void 0&&window.WebSocket===X&&(window.WebSocket=j),G!==null&&ee!==void 0&&G.sendBeacon===be&&(G.sendBeacon=ee)}}M();var L8="Tauri-Response",$8="error",tz={OK:"Ok",ERROR:"Err"},nz=/^(?:ipc:\/\/[^/]*|https?:\/\/ipc\.localhost(?::\d+)?)\/(.+)$/;function rz(e,t){let n=nz.exec(e),r=n==null?void 0:n[1];if(r===void 0)return;let o=t(L8)!==$8;return{url:`${jb}${r}`,initiator:xn.IPC,method:xn.IPC,ok:o,status:o?Mu.OK:Mu.ERROR,statusText:o?tz.OK:tz.ERROR}}function oz(e){var t;return((t=nz.exec(e))==null?void 0:t[1])===lh}function k8(){return navigator.userAgent.includes("Electron")}function iz(e,t={}){let n=window[Ko];if(typeof(n==null?void 0:n.subscribe)!="function")return k8()&&e(w.BLIND_SPOT,{kind:cn.UNOBSERVED_IPC,count:1}),()=>{};let r=n.subscribe(o=>{oe(()=>{var l;let i=`${jb}${o.channel}`;if(o.phase==="start"){e(w.NET_PENDING,{id:o.id,method:xn.IPC,url:i,initiator:xn.IPC});return}let s=o.oneWay===!0&&o.ok===void 0;s&&e(w.BLIND_SPOT,{kind:cn.VERDICTLESS_SEND,count:1});let a=o.ok===!0;e(w.NET_REQUEST,{id:o.id,method:xn.IPC,url:i,...s?{}:{ok:a,status:a?Mu.OK:Mu.ERROR},...o.oneWay===!0?{oneWay:!0}:{},durationMs:(l=o.durationMs)!=null?l:0,initiator:xn.IPC,...o.error===void 0?{}:{error:o.error},...o.responseSize===void 0?{}:{responseSize:o.responseSize},...t.captureBodies===!0?{...o.requestBody===void 0?{}:{requestBody:o.requestBody},...o.responseBody===void 0?{}:{responseBody:o.responseBody},...o.responseBodyTruncated===!0?{responseBodyTruncated:!0}:{}}:{}})})});return()=>{var o;(o=n.unsubscribe)==null||o.call(n,r)}}M();gt();Ot();nt();dn();var sz=e=>e===void 0?0:Math.max(0,e.width)*Math.max(0,e.height);function az(e){let t=globalThis.CSS;if(typeof(t==null?void 0:t.escape)=="function")return t.escape(e);let n="";for(let[r,o]of[...e].entries())/\d/.test(o)&&(r===0||r===1&&e.startsWith("-"))?n+=`\\${o.charCodeAt(0).toString(16)} `:/[\w-]/.test(o)?n+=o:n+=`\\${o}`;return n}function z8(e){let t=Ne(e);if(t!==null)return`[${Fi()}="${t.replace(/["\\]/g,"\\$&")}"]`;let n=e.tagName.toLowerCase();if(0<e.id.length)return`${n}#${az(e.id)}`;let r=e.classList.item(0);return r===null?n:`${n}.${az(r)}`}function D8(e){var n;let t;for(let r of e!=null?e:[]){let o=(n=r.node)!=null?n:null,i=o===null?null:wn(o)?o:o.parentElement;if(i===null||Rt(i))continue;let s=Math.max(sz(r.previousRect),sz(r.currentRect));(t===void 0||s>t.area)&&(t={el:i,area:s})}return t===void 0?void 0:{ref:re.refFor(t.el),selector:z8(t.el)}}function cz(e){if(typeof PerformanceObserver!="function")return()=>{};let t=[],n=(i,s)=>{try{let a=new PerformanceObserver(l=>{for(let u of l.getEntries())s(u)});a.observe({type:i,buffered:!0}),t.push(a)}catch{}},r=0,o=0;return n("largest-contentful-paint",i=>{let s=Math.round(i.startTime);s<=o||(o=s,e(w.PERF,{metric:cc.LCP,value:s,at:s}))}),n("layout-shift",i=>{var l;let s=i;if(s.hadRecentInput===!0)return;r+=(l=s.value)!=null?l:0;let a=D8(s.sources);e(w.PERF,{metric:cc.CLS,value:r,at:Math.round(i.startTime),...a===void 0?{}:{shifted:a}})}),n("longtask",i=>{e(w.PERF,{metric:cc.LONGTASK,value:Math.round(i.duration),at:Math.round(i.startTime)})}),()=>{for(let i of t)i.disconnect()}}M();var P8=new Set(["navigate","reload","back_forward"]);function M8(){try{let[e]=performance.getEntriesByType("navigation");return e}catch{return}}function lz(e){var s,a;let t=M8(),n=t==null?void 0:t.type,r=t==null?void 0:t.name;if(t===void 0||typeof r!="string"||r.length===0)return()=>{};if(typeof n!="string"||!P8.has(n))return()=>{};let o=t.responseStatus,i=typeof o=="number"&&o>0;return e(w.NET_REQUEST,{id:`doc-${String(Math.round((s=t.duration)!=null?s:0))}`,method:"GET",url:r,initiator:xn.DOCUMENT,durationMs:Math.round((a=t.duration)!=null?a:0),...i?{status:o,ok:o<400}:{},navigationType:n,...typeof t.transferSize=="number"?{transferSize:t.transferSize}:{}}),()=>{}}M();var U8=/^(javascript|mailto|tel|sms|blob|data):/i;function H8(){if(typeof window=="undefined")return;let e=window.navigation;return e instanceof EventTarget?e:void 0}function F8(e){if(!(e instanceof Element))return;let t=e.closest("a");return t instanceof HTMLAnchorElement?t:void 0}var B8=1e3;function uz(e,t,n){if(e.length===0||U8.test(e))return!1;if(t)return!0;try{let r=new URL(e,n),o=new URL(n);return r.origin===o.origin?r.pathname!==o.pathname||r.search!==o.search:!0}catch{return!1}}function dz(e){if(typeof document=="undefined")return()=>{};let t=0,n,r=(a,l)=>{let u=Date.now();n!==void 0&&n.url===a&&u-n.at<B8||(n={url:a,at:u},t+=1,e(w.NET_PENDING,{id:`nav-${String(t)}`,method:"GET",url:a,initiator:xn.NAVIGATION,...l?{download:!0}:{}}))},o=a=>{oe(()=>{var h;let l=F8(a.target);if(l===void 0)return;let u=(h=l.getAttribute("href"))!=null?h:"",d=document.location.href,f=l.hasAttribute("download");if(!uz(u,f,d))return;let m=new URL(u,d).toString();queueMicrotask(()=>{oe(()=>{a.defaultPrevented||r(m,f)})})})},i=a=>{oe(()=>{let l=a.destination;if(l===void 0||l.sameDocument)return;let u=l.url;uz(u,!1,document.location.href)&&queueMicrotask(()=>{oe(()=>{a.defaultPrevented||r(u,!1)})})})},s=H8();return s!==void 0&&s.addEventListener("navigate",i),document.addEventListener("click",o,!0),()=>{document.removeEventListener("click",o,!0),s!==void 0&&s.removeEventListener("navigate",i)}}M();ur();M();var G8=3,V8=256,j8={emit:!0},K8={emit:!1};function Z8(e){if(e<10)return!1;let t=e;for(;t%10===0;)t/=10;return t===1}function W8(e){var t,n,r;return _c([e.message,(t=e.source)!=null?t:"",e.line===void 0?"":String(e.line),(n=e.kind)!=null?n:"",(r=e.stack)!=null?r:""].join("\0"))}function pz(e=G8,t=V8){let n=new Map;return{admit(r){var s,a;let o=W8(r),i=((s=n.get(o))!=null?s:0)+1;if(n.delete(o),n.size>=t){let l=n.keys().next();(a=l.done)!=null&&a||n.delete(l.value)}return n.set(o,i),i<=e?j8:Z8(i)?{emit:!0,repeats:i}:K8}}}var fz="securitypolicyviolation",Y8="report",X8={log:w.CONSOLE_LOG,warn:w.CONSOLE_WARN,error:w.CONSOLE_ERROR,info:w.CONSOLE_INFO,debug:w.CONSOLE_DEBUG};function q8(e){return e.map(t=>typeof t=="string"?t:t instanceof Error?t.message:fo(t)).join(" ")}var hz=Z.MAX_STACK_LENGTH;function XS(e){if(!(e===void 0||e.length===0))return e.length>hz?e.slice(0,hz):e}function J8(e){for(let t of e)if(t instanceof Error)return XS(t.stack)}function mz(e){let t=["log","warn","error","info","debug"],n=new Map,r=new Map;for(let f of t){let m=Dr(console,f);n.set(f,m);let h=m.bind(console),E=(..._)=>{h(..._),oe(()=>{let A=f==="error"?J8(_):void 0;e(X8[f],{message:q8(_),...A===void 0?{}:{stack:A}})})};r.set(f,E),console[f]=E}let o=pz(),i=f=>{let m=o.admit(f);m.emit&&e(w.ERROR_UNCAUGHT,{...f,...m.repeats===void 0?{}:{repeats:m.repeats}})},s=f=>{var m,h;if(!(f instanceof ErrorEvent)){let E=f.target;if(!(E instanceof Element)||E===document)return;let _=E.tagName.toLowerCase(),A=(h=(m=E.getAttribute("src"))!=null?m:E.getAttribute("href"))!=null?h:"";oe(()=>{let v=`<${_}> failed to load${A.length===0?"":`: ${A}`}`;i({message:v,kind:"resource",...A.length===0?{}:{source:A}})});return}oe(()=>{let E=XS(f.error instanceof Error?f.error.stack:void 0),_={message:f.message,source:f.filename,line:f.lineno,...E===void 0?{}:{stack:E}};i(_)})},a=f=>{oe(()=>{let m=f.reason,h=XS(m instanceof Error?m.stack:void 0),E={message:m instanceof Error?m.message:String(m),kind:"unhandledrejection",...h===void 0?{}:{stack:h}};i(E)})},l=f=>{let m=f.blockedURI.length===0?"inline content":f.blockedURI,h=Y8===f.disposition;e(h?w.CONSOLE_WARN:w.CONSOLE_ERROR,{message:h?`[Report Only] Content Security Policy directive: ${f.violatedDirective} would block ${m}`:`Content Security Policy directive: ${f.violatedDirective} blocked ${m}`,kind:fz,...f.blockedURI.length===0?{}:{source:f.blockedURI}})},u=new AbortController,{signal:d}=u;return window.addEventListener("error",s,{capture:!0,signal:d}),window.addEventListener("unhandledrejection",a,{signal:d}),window.addEventListener(fz,l,{capture:!0,signal:d}),()=>{for(let[f,m]of n)console[f]===r.get(f)&&(console[f]=m);u.abort()}}M();Lc();var Q8={alert:void 0,confirm:!1,prompt:null},eZ=["alert","confirm","prompt"];function gz(e){let t=window,n=new Map,r=new Map;for(let o of eZ){let i=t[o];if(typeof i!="function")continue;n.set(o,i);let s=i.bind(window),a=(...l)=>{if(!jh())return s(...l);let u=Q8[o],d=l[0];return oe(()=>{e(w.DIALOG_OPENED,{kind:o,...typeof d=="string"?{message:d}:{},...u===void 0?{}:{answered:u}})}),u};r.set(o,a),t[o]=a}return()=>{for(let[o,i]of n)t[o]===r.get(o)&&(t[o]=i)}}M();gt();nt();function Ez(e){let t=new AbortController,{signal:n}=t,r=s=>{let a=s.target;a instanceof Element&&!Rt(a)&&e(w.ANIM_START,{name:s.animationName},re.refFor(a))},o=s=>{let a=s.target;a instanceof Element&&!Rt(a)&&e(w.ANIM_END,{name:s.animationName},re.refFor(a))},i=s=>{let a=s.target;a instanceof Element&&!Rt(a)&&e(w.ANIM_END,{name:s.propertyName,kind:"transition"},re.refFor(a))};return document.addEventListener("animationstart",r,{capture:!0,signal:n}),document.addEventListener("animationend",o,{capture:!0,signal:n}),document.addEventListener("transitionend",i,{capture:!0,signal:n}),()=>t.abort()}M();gt();dt();var bz=100,tZ="[data-reticle-reveal], [data-reveal], section";function _z(e){let t=new AbortController,{signal:n}=t,r=0,o=0,i,s=()=>{r=performance.now();let u=window.scrollY,d=Math.max(1,document.documentElement.scrollHeight-window.innerHeight);e(w.SCROLL_POSITION,{x:window.scrollX,y:u,percent:Math.round(u/d*100),direction:u>=o?ch.DOWN:ch.UP}),o=u},a=()=>{let u=performance.now()-r;if(u>=bz){i!==void 0&&(Re(i),i=void 0),s();return}i===void 0&&(i=ue(()=>{i=void 0,s()},bz-u))};window.addEventListener("scroll",a,{passive:!0,signal:n});let l;if(typeof IntersectionObserver=="function"){l=new IntersectionObserver(d=>{for(let f of d)f.isIntersecting&&e(w.REVEAL_SHOWN,{ratio:f.intersectionRatio},re.refFor(f.target))},{threshold:.25});let u=l;for(let d of document.querySelectorAll(tZ))u.observe(d)}return()=>{t.abort(),i!==void 0&&Re(i),l==null||l.disconnect()}}M();dt();function Tz(){let e=window;return e.__TAURI_INTERNALS__!==void 0||e.__TAURI__!==void 0?"tauri":navigator.userAgent.includes("Electron")||e[Ko]!==void 0?"electron":"web"}function nZ(){let e=navigator.userAgent;return/Chrome|Chromium|Edg\//.test(e)?"blink":/Gecko\/|Firefox/.test(e)?"gecko":"webkit"}var rZ={"google chrome":qe.CHROME,chrome:qe.CHROME,"microsoft edge":qe.EDGE,edge:qe.EDGE,brave:qe.BRAVE,opera:qe.OPERA,arc:qe.ARC,dia:qe.DIA,firefox:qe.FIREFOX,safari:qe.SAFARI};function oZ(e){return e==="chromium"||e.includes("not")&&e.includes("brand")}function iZ(){var t;try{let r=(t=navigator.userAgentData)==null?void 0:t.brands;if(Array.isArray(r)){let o;for(let i of r){let s=typeof(i==null?void 0:i.brand)=="string"?i.brand.toLowerCase():"";if(s===""||oZ(s))continue;let a=rZ[s];if(a!==void 0)if(qe.CHROME===a)o=a;else return a}return o!=null?o:qe.OTHER}}catch{}let e=navigator.userAgent;return/Edg\//.test(e)?qe.EDGE:/OPR\/|Opera/.test(e)?qe.OPERA:/Firefox/.test(e)?qe.FIREFOX:/Chrome|Chromium/.test(e)?qe.CHROME:/Safari/.test(e)?qe.SAFARI:qe.OTHER}var Sz=typeof window!="undefined"&&typeof window.fetch=="function"?window.fetch.bind(window):void 0;function sZ(){var n,r;let e=window.__TAURI_INTERNALS__,t=(r=(n=e==null?void 0:e.metadata)==null?void 0:n.currentWindow)==null?void 0:r.label;return typeof t=="string"&&t.length>0?t:void 0}function aZ(){try{let[e]=performance.getEntriesByType("navigation"),t=e==null?void 0:e.responseStatus;return typeof t=="number"&&t>0?t:void 0}catch{return}}async function cZ(e){let t=aZ();if(t!==void 0)return t;try{return e==="web"||Sz===void 0||!/^https?:$/.test(location.protocol)?void 0:(await Sz(location.href,{method:"HEAD",cache:"no-store"})).status}catch{return}}async function lZ(){let e=window[Ko];if(typeof(e==null?void 0:e.windowLabel)=="function")try{let t=await e.windowLabel();return typeof t=="string"&&t.length>0?t:void 0}catch{return}}function uZ(e){return{hidden:document.visibilityState==="hidden",focused:document.hasFocus(),runtime:Tz(),engine:nZ(),brand:iZ(),...e===void 0?{}:{windowLabel:e}}}function xz(e){let t=new AbortController,{signal:n}=t,r,o=sZ(),i=a=>{e(w.PAGE_HEALTH,{...uZ(o),...r===void 0?{}:{documentStatus:r},reason:a})};document.addEventListener("visibilitychange",()=>i(Bs.VISIBILITY),{signal:n}),window.addEventListener("focus",()=>i(Bs.FOCUS),{signal:n}),window.addEventListener("blur",()=>i(Bs.BLUR),{signal:n}),i(Bs.INITIAL),Promise.all([cZ(Tz()),o===void 0?lZ():Promise.resolve(o)]).then(([a,l])=>{n.aborted||a===void 0&&l===o||(r=a,o=l,i(Bs.HEARTBEAT))});let s=Wh(()=>i(Bs.HEARTBEAT),UO.HEARTBEAT_MS);return()=>{s(),t.abort()}}M();gt();var dZ={VIDEO:"video",AUDIO:"audio"};function Az(e){let t=new AbortController,n=r=>{oe(()=>{let o=r.target;if(!(o instanceof HTMLMediaElement))return;let i=dZ[o.tagName];if(i===void 0)return;let s=Number.isFinite(o.duration)?o.duration:void 0;e(w.MEDIA_STATE,{event:r.type,tag:i,currentTime:o.currentTime,...s===void 0?{}:{duration:s},readyState:o.readyState,paused:o.paused},re.refFor(o))})};for(let r of Object.values(Cu))document.addEventListener(r,n,{capture:!0,signal:t.signal});return()=>t.abort()}M();var et={CONNECT:"connect",DOM_OBSERVER:"dom_observer",NETWORK_OBSERVER:"network_observer",CONSOLE_OBSERVER:"console_observer",IPC_OBSERVER:"ipc_observer",HEALTH_OBSERVER:"health_observer",ROUTER_OBSERVER:"router_observer",ANIMATION_OBSERVER:"animation_observer",STORE_ADAPTER:"store_adapter",SNAPSHOT:"snapshot",ACTION:"action",COMMAND:"command",RECORDER:"recorder",TRANSPORT:"transport",TEARDOWN:"teardown"},pZ=500;function qS(e,t,n){try{let r=n instanceof Error?n.message:String(n);e(w.SDK_FAILED,{site:t,message:r.slice(0,pZ),...n instanceof Error?{errorType:n.constructor.name.slice(0,64)}:{}})}catch{}}function pt(e,t,n){try{return n()}catch(r){return qS(e,t,r),()=>{}}}function yz(e,t){for(let n of t)try{n()}catch(r){qS(e,et.TEARDOWN,r)}}function wz(e,t){return[pt(e,et.NETWORK_OBSERVER,()=>ez(e,{captureBodies:t.captureBodies,...t.captureErrorBodies===void 0?{}:{captureErrorBodies:t.captureErrorBodies},reinterpret:rz,ignore:oz})),pt(e,et.IPC_OBSERVER,()=>iz(e,{captureBodies:t.captureBodies})),pt(e,et.ANIMATION_OBSERVER,()=>cz(e)),pt(e,et.ROUTER_OBSERVER,()=>bC(e)),pt(e,et.NETWORK_OBSERVER,()=>lz(e)),pt(e,et.NETWORK_OBSERVER,()=>dz(e)),pt(e,et.CONSOLE_OBSERVER,()=>mz(e)),pt(e,et.CONSOLE_OBSERVER,()=>gz(e)),pt(e,et.ANIMATION_OBSERVER,()=>Ez(e)),pt(e,et.DOM_OBSERVER,()=>_z(e)),pt(e,et.DOM_OBSERVER,()=>Rk(e)),pt(e,et.STORE_ADAPTER,()=>X$(e)),pt(e,et.STORE_ADAPTER,()=>$k(e)),pt(e,et.DOM_OBSERVER,()=>kk(e)),pt(e,et.DOM_OBSERVER,()=>l$(e)),pt(e,et.NETWORK_OBSERVER,()=>Kk(e,{capturePreview:t.captureBodies})),pt(e,et.DOM_OBSERVER,()=>Dk(e)),pt(e,et.HEALTH_OBSERVER,()=>xz(e)),pt(e,et.DOM_OBSERVER,()=>Zk(e)),pt(e,et.DOM_OBSERVER,()=>Az(e)),pt(e,et.DOM_OBSERVER,()=>q$(e))]}Ot();md();ur();var fZ=["position:fixed","bottom:8px","right:8px","z-index:2147483647","font:11px ui-monospace,SFMono-Regular,Menlo,monospace","background:#151823","color:#e6e9f0","border:1px solid #2a2f3d","border-radius:8px","padding:6px 10px","pointer-events:none","opacity:0.85"].join(";");function vz(){let e=document.createElement("div");return e.setAttribute("data-reticle-overlay",""),e.style.cssText=fZ,e.textContent="Reticle: connecting\u2026",document.body.appendChild(e),{update:t=>{e.textContent=`Reticle ${t.connected?"\u25CF":"\u25CB"} ${String(t.events)} events`},destroy:()=>{e.remove()}}}JS();QS();M();gt();Et();function Zn(e,t=""){return typeof e=="string"?e:t}function oi(e){let t=Zn(e);return t===""?void 0:t}function _m(e){let t=re.resolve(e);if(!(t instanceof Element))return e;let n=ho(t);return n.name.length>0?`${n.role} "${n.name}"`:`${n.role} (${e})`}function Nz(e){switch(e){case H.ACT:case H.ACT_SEQUENCE:return ct.ACTING;case H.SNAPSHOT:case H.QUERY:case H.MATCH:case H.INSPECT:case H.ANIMATIONS:case H.STATE_READ:case H.CAPABILITIES:return ct.READING;default:return ct.IDLE}}function Rz(e,t={}){var n;switch(e){case H.SNAPSHOT:return"Looking at the page";case H.QUERY:case H.MATCH:{let r=e===H.MATCH?(n=t.query)!=null?n:{}:t,o=hZ(r);return o!==void 0?`Finding ${o}`:"Finding an element"}case H.INSPECT:{let r=oi(t.ref);return r!==void 0?`Inspecting ${_m(r)}`:"Inspecting an element"}case H.ANIMATIONS:return"Reading animations";case H.STATE_READ:{let r=oi(t.store);return r!==void 0?`Reading state: ${r}`:"Reading state"}case H.CAPABILITIES:return"Reading capabilities";default:return e}}function hZ(e){var o,i,s,a;let t=(o=oi(e.testid))!=null?o:at.TESTID===Zn(e.by)?oi(e.value):void 0;if(t!==void 0)return`[testid=${t}]`;let n=oi(e.name),r=(a=(s=(i=oi(e.value))!=null?i:oi(e.text))!=null?s:oi(e.label))!=null?a:oi(e.role);return r!==void 0?n!==void 0?`"${r}" (${n})`:`"${r}"`:n!==void 0?`"${n}"`:void 0}gd();Ot();M();M();ud();Et();nt();Ki();var Oz=["position:fixed","top:8px","left:50%","transform:translateX(-50%)","z-index:2147483647","display:flex","gap:6px","align-items:center","flex-wrap:wrap","max-width:90vw","font:12px ui-sans-serif,system-ui,sans-serif","background:#151823","color:#e6e9f0","border:1px solid #2a2f3d","border-radius:10px","padding:6px 10px","box-shadow:0 8px 30px rgba(0,0,0,.5)"].join(";"),Sm=["font:inherit","cursor:pointer","background:#262b3a","color:#e6e9f0","border:1px solid #3a4151","border-radius:7px","padding:3px 9px"].join(";"),eT=["font:inherit","background:#0e1018","color:#e6e9f0","border:1px solid #3a4151","border-radius:7px","padding:3px 8px"].join(";"),Iz=["opacity:.75","margin-left:4px"].join(";"),Cz=["display:flex","gap:6px","align-items:center","flex-wrap:wrap"].join(";");var mZ="recorded 0 steps",gZ="recording\u2026",Lz="ready",EZ="pick an annotation",bZ=sc.ACT,tT={record:"Record",stop:"Stop",annotate:"Annotate"},_Z={[je.ASSERT_SIGNAL]:"assert signal",[je.ASSERT_VISIBLE]:"assert visible",[je.ASSERT_STATE]:"assert state",[je.ASSERT_NET]:"assert request",[je.MARK_DYNAMIC]:"mark dynamic",[je.SUCCESS_STATE]:"success state",[je.INTENT]:"intent"},SZ=new Set([je.ASSERT_SIGNAL,je.SUCCESS_STATE]),TZ="recorded-flow";function zz(e){let t=Ne(e);if(t!==null&&t.length>0)return{anchor:{kind:nr.TESTID,value:t},degraded:!1};let n=Le(e),r=we(e);return n!=="generic"&&(n.length>0||r.length>0)?{anchor:r.length>0?{kind:nr.ROLE,role:n,name:r}:{kind:nr.ROLE,role:n},degraded:!1}:{anchor:{kind:nr.ROLE,role:gR},degraded:!0}}function $z(e){return e instanceof HTMLTextAreaElement?!0:e instanceof HTMLInputElement&&zd(e)==="textbox"}function zd(e){let t=e.type.toLowerCase();return t==="checkbox"?"checkbox":t==="radio"?"radio":["text","email","tel","url","search","password",""].includes(t)?"textbox":"other"}function qc(e,t,n){let{anchor:r,degraded:o}=zz(e),i={tool:bZ,anchor:r,action:t};n!==void 0&&(i.args=n),o&&(i.degraded=!0);let s=ld(e);return s!==void 0&&(i.source=s.line===void 0?{file:s.file}:{file:s.file,line:s.line}),i}function xZ(e,t,n,r,o){let i=t.map(u=>({...u})),s=[],a;for(let u of n){if(u.kind===je.MARK_DYNAMIC){s.push(u.anchor);continue}if(u.kind===je.SUCCESS_STATE){u.signal!==void 0&&(a={kind:z.SIGNAL,name:u.signal});continue}let d=i.at(-1);d!==void 0&&(u.kind===je.ASSERT_SIGNAL&&u.signal!==void 0?d.expect=kz(d.expect,{kind:z.SIGNAL,name:u.signal}):u.kind===je.ASSERT_VISIBLE&&(d.expect=kz(d.expect,{kind:z.ELEMENT,query:AZ(u.anchor)})))}let l={version:db,name:e,createdAt:r,steps:i};return o!==void 0&&o.length>0&&(l.startPath=o),s.length>0&&(l.dynamic=s),a!==void 0&&(l.success=a),l}function kz(e,t){return e===void 0?t:e.kind===z.ALL_OF?{kind:z.ALL_OF,predicates:[...e.predicates,t]}:{kind:z.ALL_OF,predicates:[e,t]}}function AZ(e){return e.kind===nr.TESTID?{testid:e.value}:e.kind===nr.ROLE?e.name!==void 0?{role:e.role,name:e.name}:{role:e.role}:{}}var ea,hr,mn,Md,ts,ii,Jc,ns,ta,bo,Pr,W,Dz,Dd,Pz,Mz,Uz,Hz,es,Fz,Bz,rT,Gz,Vz,jz,Qs,Kz,Tm,Zz,Wz,Pd,xm,Yz,nT=class{constructor(t){x(this,W);x(this,ea);x(this,hr,on.IDLE);x(this,mn,[]);x(this,Md);x(this,ts,[]);x(this,ii);x(this,Jc);x(this,ns);x(this,ta);x(this,bo);x(this,Pr);g(this,ea,t)}phase(){return c(this,hr)}steps(){return c(this,mn).map(t=>({...t}))}mount(){c(this,ns)===void 0&&typeof document!="undefined"&&(T(this,W,Kz).call(this),T(this,W,Dz).call(this))}destroy(){var t,n;(t=c(this,Jc))==null||t.abort(),g(this,Jc,void 0),(n=c(this,ns))==null||n.remove(),g(this,ns,void 0),g(this,ta,void 0),g(this,bo,void 0),g(this,hr,on.IDLE),g(this,mn,[]),g(this,ts,[]),g(this,Pr,void 0),g(this,ii,void 0)}};ea=new WeakMap,hr=new WeakMap,mn=new WeakMap,Md=new WeakMap,ts=new WeakMap,ii=new WeakMap,Jc=new WeakMap,ns=new WeakMap,ta=new WeakMap,bo=new WeakMap,Pr=new WeakMap,W=new WeakSet,Dz=function(){let t=new AbortController;g(this,Jc,t);let n={capture:!0,signal:t.signal};document.addEventListener("click",r=>T(this,W,Pz).call(this,r),n),document.addEventListener("input",r=>T(this,W,Mz).call(this,r),n),document.addEventListener("change",r=>T(this,W,Uz).call(this,r),n),document.addEventListener("submit",r=>T(this,W,Hz).call(this,r),n)},Dd=function(t){let n=t.target;if(n instanceof Element&&!Rt(n))return n},Pz=function(t){let n=T(this,W,Dd).call(this,t);if(n!==void 0){if(c(this,hr)===on.ANNOTATING){T(this,W,Fz).call(this,n);return}c(this,hr)===on.RECORDING&&(n instanceof HTMLInputElement&&(zd(n)==="checkbox"||zd(n)==="radio")||n instanceof HTMLSelectElement||(T(this,W,es).call(this),c(this,mn).push(qc(n,D.CLICK))))}},Mz=function(t){if(c(this,hr)!==on.RECORDING)return;let n=T(this,W,Dd).call(this,t);n===void 0||!$z(n)||g(this,ii,{el:n,value:n.value})},Uz=function(t){if(c(this,hr)!==on.RECORDING)return;let n=T(this,W,Dd).call(this,t);if(n!==void 0){if(n instanceof HTMLInputElement&&zd(n)==="checkbox"){T(this,W,es).call(this),c(this,mn).push(qc(n,n.checked?D.CHECK:D.UNCHECK));return}if(n instanceof HTMLInputElement&&zd(n)==="radio"){T(this,W,es).call(this),c(this,mn).push(qc(n,D.CHECK));return}if(n instanceof HTMLSelectElement){T(this,W,es).call(this),c(this,mn).push(qc(n,D.SELECT,{value:n.value}));return}$z(n)&&(g(this,ii,{el:n,value:n.value}),T(this,W,es).call(this))}},Hz=function(t){if(c(this,hr)!==on.RECORDING)return;let n=T(this,W,Dd).call(this,t);n!==void 0&&(T(this,W,es).call(this),c(this,mn).push(qc(n,D.SUBMIT)))},es=function(){let t=c(this,ii);if(t===void 0)return;g(this,ii,void 0);let n=pn(t.el)?ve:t.value;c(this,mn).push(qc(t.el,D.FILL,{value:n}))},Fz=function(t){let n=c(this,Pr);if(n===void 0)return;let{anchor:r}=zz(t),o={kind:n.kind,anchor:r},i=T(this,W,rT).call(this);i!==void 0&&(o.signal=i),c(this,ts).push(o),g(this,Pr,void 0),T(this,W,Qs).call(this,on.RECORDING),T(this,W,Pd).call(this)},Bz=function(){let t=c(this,Pr);if(t===void 0)return;let n=c(this,mn).at(-1);if(n===void 0){g(this,Pr,void 0),T(this,W,Qs).call(this,on.RECORDING),T(this,W,Pd).call(this);return}let r={kind:t.kind,anchor:n.anchor},o=T(this,W,rT).call(this);o!==void 0&&(r.signal=o),c(this,ts).push(r),g(this,Pr,void 0),T(this,W,Qs).call(this,on.RECORDING),T(this,W,Pd).call(this)},rT=function(){var r,o;let t=(r=c(this,bo))==null?void 0:r.querySelector("[data-reticle-signal]"),n=(o=t==null?void 0:t.value)!=null?o:"";return n.length>0?n:void 0},Gz=function(){g(this,mn,[]),g(this,Md,typeof location=="undefined"?void 0:location.pathname),g(this,ts,[]),g(this,ii,void 0),g(this,Pr,void 0),T(this,W,Qs).call(this,on.RECORDING),T(this,W,xm).call(this,gZ)},Vz=function(){var r,o;T(this,W,es).call(this);let t=(o=(r=T(this,W,Yz).call(this))!=null?r:c(this,ea).defaultName)!=null?o:TZ,n=xZ(t,c(this,mn),c(this,ts),c(this,ea).now(),c(this,Md));c(this,ea).emit(w.FLOW_RECORDED,{name:t,flow:n}),T(this,W,xm).call(this,c(this,mn).length===0?mZ:Lz),T(this,W,Qs).call(this,on.IDLE),T(this,W,Pd).call(this)},jz=function(){c(this,hr)===on.RECORDING&&(T(this,W,Qs).call(this,on.ANNOTATING),T(this,W,xm).call(this,EZ),T(this,W,Zz).call(this))},Qs=function(t){g(this,hr,t)},Kz=function(){let t=document.createElement("div");t.setAttribute("data-reticle-overlay",""),t.style.cssText=Oz;let n=document.createElement("input");n.setAttribute("data-reticle-name",""),n.setAttribute("placeholder","flow name"),n.style.cssText=eT,t.appendChild(n),t.appendChild(T(this,W,Tm).call(this,"record",tT.record,()=>T(this,W,Gz).call(this))),t.appendChild(T(this,W,Tm).call(this,"stop",tT.stop,()=>T(this,W,Vz).call(this))),t.appendChild(T(this,W,Tm).call(this,"annotate",tT.annotate,()=>T(this,W,jz).call(this)));let r=document.createElement("span");r.setAttribute("data-reticle-status",""),r.style.cssText=Iz,r.textContent=Lz,t.appendChild(r);let o=document.createElement("div");o.setAttribute("data-reticle-menu",""),o.style.cssText=Cz,t.appendChild(o),document.body.appendChild(t),g(this,ns,t),g(this,ta,r),g(this,bo,o)},Tm=function(t,n,r){let o=document.createElement("button");return o.setAttribute("data-reticle-action",t),o.textContent=n,o.style.cssText=Sm,o.addEventListener("click",r),o},Zz=function(){let t=c(this,bo);if(t!==void 0){t.textContent="";for(let n of Object.values(je)){if(n===je.INTENT)continue;let r=document.createElement("button");r.setAttribute("data-reticle-annkind",n),r.textContent=_Z[n],r.style.cssText=Sm,r.addEventListener("click",()=>T(this,W,Wz).call(this,n)),t.appendChild(r)}}},Wz=function(t){g(this,Pr,{kind:t});let n=c(this,bo);if(n===void 0)return;if(SZ.has(t)){let o=document.createElement("select");o.setAttribute("data-reticle-signal",""),o.style.cssText=eT;for(let i of ji().signals){let s=document.createElement("option");s.value=i,s.textContent=i,o.appendChild(s)}n.appendChild(o)}let r=document.createElement("button");r.setAttribute("data-reticle-action","annotate-confirm"),r.textContent="on prior step",r.style.cssText=Sm,r.addEventListener("click",()=>T(this,W,Bz).call(this)),n.appendChild(r)},Pd=function(){c(this,bo)!==void 0&&(c(this,bo).textContent="")},xm=function(t){c(this,ta)!==void 0&&(c(this,ta).textContent=t)},Yz=function(){var r,o;let t=(r=c(this,ns))==null?void 0:r.querySelector("[data-reticle-name]"),n=(o=t==null?void 0:t.value.trim())!=null?o:"";return n.length>0?n:void 0};function Xz(e){return new nT(e)}gT();M();function wD(e){return{...e.env===void 0?{}:{env:e.env},...e.scope===void 0?{}:{scope:e.scope},...e.injected===!0?{instrumentation:oh.INJECTED}:{}}}function vD(e,t){return e==="production"&&!t}function ND(e,t){let n=e.token;if(!(e.lease!==!0||n===void 0||n.length===0||n===t))return n}function BW(e){let t;try{t=new URL(e)}catch{return{url:e,adjusted:!1}}return t.protocol!=="ws:"&&t.protocol!=="wss:"||t.pathname!==""&&t.pathname!=="/"?{url:e,adjusted:!1}:(t.pathname=zs,{url:t.toString(),adjusted:!0})}function GW(e,t,n,r,o="http:"){var l;let i;try{i=new URL(t)}catch{return{allowed:!1,reason:"invalid Reticle bridge URL"}}if(i.protocol!=="ws:"&&i.protocol!=="wss:")return{allowed:!1,reason:"Reticle bridge URL must use ws:// or wss://"};if(((l=r==null?void 0:r.length)!=null?l:0)>Z.MAX_TOKEN_LENGTH)return{allowed:!1,reason:`Reticle pairing token exceeds ${String(Z.MAX_TOKEN_LENGTH)} characters`};let s=!c_(i.hostname);return s&&i.protocol!=="wss:"?{allowed:!1,reason:"a non-local Reticle bridge must use wss://"}:!sI(o,e)||s?n?r===void 0||r.length===0?{allowed:!1,reason:"a pairing token is required outside localhost"}:{allowed:!0}:{allowed:!1,reason:"Reticle is disabled outside localhost unless allowNonLocalhost is explicitly enabled"}:{allowed:!0}}var VW=20,jW="[Reticle] killed for this page. Restart your dev server or reload the page to bring it back.",KW="Session ended - lost connection to Reticle (the agent is no longer running).";function ZW(e,t){return e===void 0||e===Fu?t():e}function WW(){try{let e=new URL(window.location.href);if(!e.searchParams.has(cm))return;e.searchParams.delete(cm),window.history.replaceState(window.history.state,"",e.toString())}catch{}}function aA(e){let t=new URLSearchParams(e),n={},r=t.get(rr.SESSION),o=t.get(rr.PROJECT),i=cA(Bn,t.get(rr.HUD));return r!==null&&r.length>0&&(n.session=r),o!==null&&o.length>0&&(n.projectId=o),i!==void 0&&(n.hud=i),n}function YW(e){return e===void 0?{placed:[]}:{remember:e,placed:Bn.SHOWN===e?[]:[e]}}function Y2(e,t){var i;let n=aA(t),r=e.session!==void 0&&e.session!==Fu?e.session:void 0,o=(i=e.projectId)!=null?i:n.projectId;return{session:r!=null?r:n.session,projectId:o!==void 0&&o.length>0?o:void 0}}function XW(e){return{t:e.t,seq:e.seq,type:e.type,sessionId:e.sessionId,ref:e.ref,documentId:e.documentId,editEpoch:0===e.editEpoch?void 0:e.editEpoch,data:e.data}}var no,jp,Ga,Do,Va,Vg,Kp,As,Ue,su,ja,Ai,Zp,au,Wp,Ka,Po,cu,ys,Yp,ws,lu,Za,Mo,uu,yi,$n,q2,Uo,J2,Q2,e5,t5,n5,du=class{constructor(){x(this,$n);x(this,no);x(this,jp,new Map);x(this,Ga,[]);x(this,Do,!1);x(this,Va,"default");x(this,Vg,WO(Math.random));x(this,Kp,0);x(this,As);x(this,Ue);x(this,su,new Map);x(this,ja,[]);x(this,Ai);x(this,Zp);x(this,au,!1);x(this,Wp,!1);x(this,Ka);x(this,Po);x(this,cu,0);x(this,ys);x(this,Yp,{});x(this,ws);x(this,lu,!1);x(this,Za);x(this,Mo);x(this,uu,[]);x(this,yi);x(this,Uo,(t,n,r)=>{var i,s,a;let o=XW({seq:c(this,cu),t:Math.round(performance.now()-c(this,Kp)),type:t,sessionId:c(this,Va),documentId:c(this,Vg),editEpoch:fd.current,data:n,ref:r});try{(i=c(this,no))==null||i.sendEvent(o),g(this,cu,c(this,cu)+1),(s=c(this,As))==null||s.update({connected:!0,events:c(this,cu)}),t===w.ROUTE_CHANGE&&((a=c(this,Ue))==null||a.refilterFlows())}catch{}})}connect(t={}){var f,m,h,E,_,A,v;if(c(this,Do)){let N=ND(t,c(this,ys));N!==void 0&&(g(this,ys,N),(f=c(this,no))==null||f.redialAfterRefusal()),T(this,$n,Q2).call(this,t);return}if(typeof window=="undefined"||typeof document=="undefined")return;let n=globalThis.process,r=(m=n==null?void 0:n.env)==null?void 0:m.NODE_ENV;if(vD(r,t.allowInProduction===!0)){globalThis.console.warn("[Reticle] disabled in production (NODE_ENV=production). Gate the import behind import.meta.env.DEV, or pass allowInProduction:true to override.");return}WW();let o=BW((h=t.url)!=null?h:TR(fb)),i=o.url;o.adjusted&&globalThis.console.warn(`[Reticle] bridge URL has no path; using ${i} (the bridge only accepts WebSocket upgrades on ${zs}).`);let s=GW(window.location.hostname,i,t.allowNonLocalhost===!0,t.token,window.location.protocol);if(!s.allowed){globalThis.console.warn(`[Reticle] ${(E=s.reason)!=null?E:"connection blocked"}`);return}t.root!==void 0&&t.root.length>0&&(globalThis[qf]=t.root);let a=(_=t.sdkVersion)!=null?_:globalThis[TO];g(this,ws,typeof a=="string"&&a.length>0?a:void 0);let l=Y2(t,window.location.search),u=ZW(l.session,()=>"");g(this,Va,MC(u.length>0?u:void 0,typeof globalThis.sessionStorage=="undefined"?void 0:globalThis.sessionStorage,()=>{var N;return typeof((N=globalThis.crypto)==null?void 0:N.randomUUID)=="function"?`s${globalThis.crypto.randomUUID()}`:`s${Date.now().toString(36)}`})),g(this,ys,t.token!==void 0&&t.token.length>0?t.token:void 0),g(this,Mo,l.projectId),g(this,Yp,wD(t)),T(this,$n,J2).call(this,t.redact),g(this,Kp,performance.now()),g(this,jp,fk()),g(this,no,new um({url:i,hello:()=>T(this,$n,e5).call(this),handleCommand:N=>T(this,$n,t5).call(this,N),onConnected:()=>{var N;g(this,Wp,!0),(N=c(this,Ue))==null||N.sessionStart()},onConnectionLost:()=>{var N;Uc(),((N=c(this,Ue))==null?void 0:N.sessionActive)===!0&&c(this,Ue).setState(Xe.ENDED,KW)},onUnreachable:({url:N,attempts:O})=>{var k;zr(pm(N,O)),(k=c(this,Ue))==null||k.showUnreachable(N,O)}})),Ph(()=>{var N;return(N=c(this,no))==null?void 0:N.reannounce()}),cC(t.exposePresenter===!0),_C(t.testIdAttribute),t.networkBodyMaxChars!==void 0&&Vk(t.networkBodyMaxChars);let d=c(this,Uo);g(this,lu,t.captureNetworkBodies===!0),g(this,Za,typeof t.sourceMapping=="boolean"?t.sourceMapping:void 0),g(this,Ga,wz(d,{captureBodies:c(this,lu),...t.captureErrorBodies===void 0?{}:{captureErrorBodies:t.captureErrorBodies}})),t.overlay===!0&&(g(this,As,vz()),c(this,As).update({connected:!0,events:0})),g(this,Ai,aA(window.location.search).hud),t.present!==!1&&Bn.REMOVED!==c(this,Ai)&&T(this,$n,q2).call(this,t),t.recorder===!0&&(g(this,Ka,Xz({emit:d,now:()=>Date.now()})),c(this,Ka).mount()),((A=t.annotate)!=null?A:t.present!==!1)&&(g(this,Po,new da({emit:d,now:()=>Date.now(),onMark:N=>{var O;return(O=c(this,Ue))==null?void 0:O.log(Ge.HUMAN,`\u{1F6A9} #${String(N.index)} ${N.label}${N.source!==void 0?` \xB7 ${N.source}`:""} \u2014 ${N.note}`)},shouldBlock:()=>{var N,O;return(O=(N=c(this,Zp))==null?void 0:N.call(this).blockPageInteractions)!=null?O:!0}})),c(this,Po).mount(),(v=c(this,Ue))==null||v.bindAnnotator(c(this,Po))),c(this,no).connect(),g(this,Do,!0)}get connected(){return c(this,Do)}routes(t){EC(t)}signal(t,n={}){c(this,Uo).call(this,w.SIGNAL,{name:t,data:n})}busy(t){return hC(t,(n,r)=>{this.signal(n,r)})}state(t,n){c(this,Uo).call(this,w.STATE_CHANGE,{name:t,value:n})}renderCommit(t){t>0&&c(this,Uo).call(this,w.RENDER_COMMIT,{commits:t})}describe(t){Ic(t)}endSession(){var t;(t=c(this,Ue))==null||t.setState(Xe.ENDED)}observeHotUpdates(t){fd.observe(t)}disconnect(){var t,n,r,o,i,s;c(this,Do)&&(yz(c(this,Uo),c(this,Ga)),g(this,Ga,[]),(t=c(this,no))==null||t.close(),g(this,no,void 0),(n=c(this,As))==null||n.destroy(),g(this,As,void 0),(r=c(this,Ue))==null||r.sessionEnd(),(o=c(this,Ue))==null||o.destroy(),g(this,Ue,void 0),(i=c(this,Ka))==null||i.destroy(),g(this,Ka,void 0),(s=c(this,Po))==null||s.destroy(),g(this,Po,void 0),Uc(),g(this,Do,!1))}};no=new WeakMap,jp=new WeakMap,Ga=new WeakMap,Do=new WeakMap,Va=new WeakMap,Vg=new WeakMap,Kp=new WeakMap,As=new WeakMap,Ue=new WeakMap,su=new WeakMap,ja=new WeakMap,Ai=new WeakMap,Zp=new WeakMap,au=new WeakMap,Wp=new WeakMap,Ka=new WeakMap,Po=new WeakMap,cu=new WeakMap,ys=new WeakMap,Yp=new WeakMap,ws=new WeakMap,lu=new WeakMap,Za=new WeakMap,Mo=new WeakMap,uu=new WeakMap,yi=new WeakMap,$n=new WeakSet,q2=function(t){c(this,au)||(g(this,au,!0),Promise.resolve().then(()=>(C2(),I2)).then(({Presenter:n})=>Promise.resolve().then(()=>(gl(),K1)).then(r=>({Presenter:n,settings:r}))).then(({Presenter:n,settings:r})=>{if(!c(this,Do))return;g(this,Zp,r.getPresenterSettings);let o={};t.pace!==void 0&&(o.paceMs=t.pace),t.narrationDwellMs!==void 0&&(o.narrationDwellMs=t.narrationDwellMs),t.border!==void 0&&(o.border=t.border),t.logMax!==void 0&&(o.logMax=t.logMax),t.endedFadeMs!==void 0&&(o.endedFadeMs=t.endedFadeMs),t.idleEndMs!==void 0&&(o.idleEndMs=t.idleEndMs),o.sessionId=c(this,Va),c(this,Mo)!==void 0&&(o.projectId=c(this,Mo)),o.onControl=s=>c(this,Uo).call(this,w.HUMAN_CONTROL,s.text!==void 0?{kind:s.kind,text:s.text}:{kind:s.kind}),o.onHudUse=s=>c(this,Uo).call(this,w.HUD_USED,{...s}),o.onKill=()=>{this.disconnect(),zr(jW)};let i=new n(o);g(this,Ue,i),i.mount(),i.showSdkVersion(c(this,ws));for(let s of c(this,su).values())i.handlePush(s);c(this,su).clear(),0<c(this,ja).length&&i.sessionStart();for(let s of c(this,ja).splice(0))i.narrate(s.text,s.level,s.actor,s.summary);c(this,Ai)!==void 0&&i.placeHud(c(this,Ai),void 0),g(this,Ai,void 0),Promise.resolve().then(()=>(W2(),Z2)).then(s=>{var l;if(!c(this,Do))return;let a=s.mountTour({document,storage:s.safeLocalStorage(),projectId:(l=aA(window.location.search).projectId)!=null?l:window.location.origin,isDriving:()=>ct.IDLE!==i.mode,search:window.location.search,navigator,copy:u=>{var d,f;return(f=(d=navigator.clipboard)==null?void 0:d.writeText(u).then(()=>!0,()=>!1))!=null?f:!1},select:u=>{let d=window.getSelection();if(d===null)return;let f=document.createRange();f.selectNodeContents(u),d.removeAllRanges(),d.addRange(f)}});a!==void 0&&c(this,Ga).push(a.destroy)}),c(this,Wp)&&i.sessionStart(),c(this,Po)!==void 0&&i.bindAnnotator(c(this,Po))}).catch(()=>{}))},Uo=new WeakMap,J2=function(t){QO(JO(t,zr)),g(this,uu,eI(t))},Q2=function(t){var r;if(c(this,Mo)!==void 0)return;let n=Y2(t,window.location.search).projectId;n!==void 0&&(g(this,Mo,n),(r=c(this,no))==null||r.reannounce())},e5=function(){return{kind:sn.HELLO,protocolVersion:Mf,sessionId:c(this,Va),...c(this,Mo)===void 0?{}:{projectId:c(this,Mo)},url:Oh(),title:io(document.title),adapters:hd(),...c(this,ys)===void 0?{}:{token:c(this,ys)},...c(this,Yp),hasCapabilities:Mh(),channels:_k(),platform:Sk(),commands:Tk(),captureBodies:c(this,lu),...c(this,Za)===void 0?{}:{sourceMapping:c(this,Za)},...c(this,ws)===void 0?{}:{sdkVersion:c(this,ws)},contract:O_,contractParts:{commands:[...Qu.commands],events:[...Qu.events],actions:[...Qu.actions]},...c(this,uu).length===0?{}:{redactKeys:c(this,uu)}}},t5=async function(t){var r,o,i,s,a,l,u,d;if(t.name===H.MARKERS){let f=zC(document),m=c(this,ws)!==void 0||c(this,Za)!==void 0,h=DC({buildPlugin:m,adapters:hd(),markers:f});return{ok:!0,result:{markers:f,...h.length===0?{}:{notApplicable:h}}}}if(t.name===H.NARRATE)return c(this,Ue)===void 0&&c(this,au)?(c(this,ja).length<VW&&c(this,ja).push({text:Zn(t.args.text),level:Zn(t.args.level,"info"),actor:X2(t.args),summary:t.args.summary===!0}),{ok:!0,result:{shown:!1,buffered:!0}}):((r=c(this,Ue))==null||r.sessionStart(),(o=c(this,Ue))==null||o.narrate(Zn(t.args.text),Zn(t.args.level,"info"),X2(t.args),t.args.summary===!0),{ok:!0,result:{shown:c(this,Ue)!==void 0}});if(t.name===H.SESSION_CONFIG){let f=t.args.idleEndMs;typeof f=="number"&&((i=c(this,Ue))==null||i.setIdleEndMs(f));let m=cA(Bn,t.args.hud),h=cA(Jf,t.args.corner),E=c(this,Ue),_;if(E!==void 0)_=E.placeHud(m,h);else{let A=YW(m);A.remember!==void 0&&g(this,Ai,A.remember),_=A.placed}return{ok:!0,result:{applied:c(this,Ue)!==void 0,idleEndMs:f,...0<_.length?{hud:_}:{}}}}if(t.name===H.PRESENTER||t.name===H.FLOWS||t.name===H.FLOW_PROGRESS||t.name===H.PLAN||t.name===H.IMPACT)return c(this,Ue)===void 0?(c(this,su).set(t.name,t),{ok:!0,result:{applied:!1,buffered:!0}}):(c(this,Ue).handlePush(t),{ok:!0,result:{applied:!0}});let n=c(this,jp).get(t.name);if(n===void 0)return{ok:!1,error:`unknown command '${t.name}'`};(s=c(this,Ue))==null||s.sessionStart(),await T(this,$n,n5).call(this,t),B_(Ku.HARNESS===t.by),Y_((a=t.outward)==null?void 0:a.allowed);try{let f=await n(t.args);return(l=c(this,yi))==null||l.result(Kn.PASS),{ok:!0,result:f}}catch(f){return(u=c(this,yi))==null||u.result(Kn.FAIL),{ok:!1,error:f instanceof Error?f.message:String(f)}}finally{B_(!1),Y_(void 0),g(this,yi,void 0),(d=c(this,Ue))==null||d.scheduleIdle()}},n5=async function(t){let n=c(this,Ue);if(n===void 0)return;n.setMode(Nz(t.name)),g(this,yi,void 0);let r=Ku.HARNESS===t.by?hn.HARNESS:hn.AGENT;if(t.name===H.ACT){let o=Zn(t.args.ref),i=_m(o);g(this,yi,n.log(Ge.ACT,`${kd(Zn(t.args.action))} ${i}`,void 0,r)),await n.beforeAct(o,Zn(t.args.action),i)}else if(t.name===H.ACT_SEQUENCE){let o=Array.isArray(t.args.steps)?t.args.steps:[];for(let i of o){let s=i,a=Zn(s.ref),l=_m(a);g(this,yi,n.log(Ge.ACT,`${kd(Zn(s.action))} ${l}`,void 0,r)),await n.beforeAct(a,Zn(s.action),l)}}else{let o=Rz(t.name,t.args);n.status(o),n.log(Ge.READ,o,void 0,r)}};function X2(e){return Ku.HARNESS===e.actor?hn.HARNESS:hn.AGENT}function cA(e,t){return Object.values(e).includes(t)?t:void 0}var lA=globalThis,r5,pu=(r5=lA.__reticleInstance)!=null?r5:lA.__reticleInstance=new du;M();nt();Qo();Ys();gd();Ys();function s5(e){try{return uA(e,new WeakMap)}catch{return e}}function uA(e,t){if(typeof e!="object"||e===null)return e;let n=t.get(e);if(n!==void 0)return n;if(Array.isArray(e)){let i=[];t.set(e,i);for(let s of e)i.push(uA(s,t));return i}let r=Object.getPrototypeOf(e);if(r!==Object.prototype&&r!==null)return e;let o={};t.set(e,o);for(let[i,s]of Object.entries(e))o[i]=uA(s,t);return o}function qW(e){return typeof e!="object"||e===null?String(e):JSON.stringify(e,(t,n)=>{if(typeof n!="object"||n===null||Array.isArray(n))return n;let r=Object.getPrototypeOf(n);if(r!==Object.prototype&&r!==null)return n;let o=n,i={};for(let s of Object.keys(o).sort())i[s]=o[s];return i})}function a5(e){let t={getState:()=>{var r,o,i;let n={};for(let s of e.getQueryCache().getAll()){let a=s.queryKey.map(qW).join("/");n[a]={status:s.state.status,fetchStatus:s.state.fetchStatus,isStale:(r=s.isStale)==null?void 0:r.call(s),isInvalidated:s.state.isInvalidated,dataUpdatedAt:s.state.dataUpdatedAt,error:(i=(o=s.state.error)==null?void 0:o.message)!=null?i:null,data:s.state.data}}return n},subscribe:n=>e.getQueryCache().subscribe(n)};return kh(t,e),t}function c5(e,t){return{getState:()=>{let n={};for(let[r,o]of Object.entries(t))n[r]=e.get(o);return n},subscribe:n=>{let r=Object.values(t).map(o=>e.sub(o,n));return()=>{for(let o of r)o()}}}}function l5(e){return{getState:()=>e.getSnapshot(),subscribe:t=>{let n=e.subscribe(t);return()=>n.unsubscribe()}}}function u5(e,t,n){return{getState:()=>t(e),subscribe:r=>n(e,r)}}function d5(e,t,n){return{getState:()=>t(e),subscribe:r=>n(()=>t(e),()=>r())}}var o5={HAS_VALUE:"hasValue",LOADING:"loading",HAS_ERROR:"hasError"};function JW(e){if(e.state===o5.HAS_ERROR){let t=e.contents;return{status:e.state,value:null,error:t instanceof Error?t.message:String(t)}}return e.state!==o5.HAS_VALUE?{status:e.state,value:null,error:null}:{status:e.state,value:e.contents,error:null}}function p5(e,t,n){return{getState:()=>{let r=t(),o={};for(let[i,s]of Object.entries(e))o[i]=JW(r.getLoadable(s));return o},subscribe:n}}function i5(e){if(typeof e=="function"){e();return}e.unsubscribe()}function f5(e,t=zr){let n=!1;return{getState:()=>{let r,o=!1;return i5(e.subscribe(i=>{r=s5(i),o=!0})),!o&&!n&&(n=!0,t("[reticle] a store passed to svelteStore did not call its subscriber synchronously, so its current value cannot be read. reticle_state will report undefined for it. Svelte stores always call back immediately; an RxJS Observable does not unless it is a BehaviorSubject.")),r},subscribe:r=>{let o=!0,i=e.subscribe(()=>{o||r()});return o=!1,()=>i5(i)}}}var QW={detached:!0,flush:"sync"};function h5(e){return{getState:()=>s5(e.$state),subscribe:t=>e.$subscribe(()=>t(),{...QW})}}function m5(e){let t=e,n=new Set;return{store:{getState:()=>t,subscribe:o=>(n.add(o),()=>n.delete(o))},push:o=>{t=o;for(let i of n)i()}}}Ki();function g5(e={}){var n;let t=(n=e.target)!=null?n:pu;return{signal(r,o={}){t.connected&&t.signal(r,o)},state(r,o){t.connected&&t.state(r,o)}}}function E5(e,t,n,r){let o=t();return e.signal(n,r),o}Ki();function b5(e){let t={};e.testids!==void 0&&(t.testids=[...e.testids]),e.signals!==void 0&&(t.signals=[...e.signals]),e.stores!==void 0&&(t.stores=[...e.stores]),Ic(t)}j_();Et();uo();gt();gT();oT();var eY=e=>mC((t,n)=>{pu.signal(t,n)},e);return v5(tY);})();
1833
+ `),truncated:t}}var z8=/application\/json|text\/|application\/xml|x-www-form-urlencoded|graphql/i,tz=/event-stream|x-ndjson|application\/stream/i,D8=/event-stream/i;function nz(e,t){return e!==null&&D8.test(e)?!1:t===null}var P8=500;async function rz(e){let t;try{return await Promise.race([e,new Promise(n=>{t=de(()=>n(void 0),P8)})])}finally{t!==void 0&&Oe(t)}}function eT(e){if(e!==null)return tz.test(e)?ar.STREAMING:ar.NOT_TEXT}function tT(e){return e===null||tz.test(e)?!1:z8.test(e)}var oz=8192,M8=262144,U8=256,Jc=oz;function iz(e){Number.isFinite(e)&&(Jc=Math.min(M8,Math.max(U8,Math.floor(e))))}function sz(){return Jc}var H8=oz*2;function F8(e){let t=Jc*2;return e?Math.min(t,H8):t}var B8=/\b(Bearer|Basic)\s+(?=[A-Za-z0-9._~+/=-]{16,})(?=[A-Za-z0-9._~+/=-]*[\d._~+/=-])[A-Za-z0-9._~+/=-]+/gi;function QS(e){return e.replace(B8,(t,n)=>`${n} ${ve}`).replace(/([A-Za-z0-9_.-]+)("?\s*[=:]\s*)("(?:\\.|[^"\\])*"?|[^&\s,;"}]+)/g,(t,n,r,o)=>{if(!St(n))return t;let i=o.startsWith('"')?`"${ve}"`:ve;return`${n}${r}${i}`})}var ez=4096;function nT(e,t){return t&&e>=400}function bm(e,t){let n=_o(e,t);return n.body.length<=ez?n:{body:n.body.slice(0,ez),truncated:!0}}function _o(e,t){let n=t!==null&&/json|graphql/i.test(t),r=F8(!n),o=e.length>r,i=o?e.slice(0,r):e,s=!1,a;if(n)try{a=mo(JSON.parse(i))}catch{a=QS(i)}else if(es(t)){let u=Qk(i);a=QS(u.body),s=u.truncated}else a=QS(i);a=lo(a);let l=s||o||a.length>Jc;return{body:a.length>Jc?a.slice(0,Jc):a,truncated:l}}var G8=/text\/|json|csv|xml|ndjson|javascript/i,V8=2e3;function az(e,t={}){if(typeof URL.createObjectURL!="function")return()=>{};let n=new AbortController,r=URL.createObjectURL.bind(URL),o=new Map,i=ke(URL,"createObjectURL"),s=function(h){let E=r(h);return oe(()=>{if(typeof Blob!="undefined"&&h instanceof Blob){let S=G8.test(h.type)?h.text().catch(()=>{}):Promise.resolve(void 0);o.set(E,{type:h.type,size:h.size,text:S})}}),E};URL.createObjectURL=s;let a=(m,h)=>{let E=o.get(m);E!==void 0&&(o.delete(m),E.text.then(S=>{oe(()=>{l(E,h,S)})}))},l=(m,h,E)=>{let S={mimeType:m.type,bytes:m.size};if(h!==void 0&&h.length>0&&(S.filename=h),E!==void 0&&(S.lines=E.split(`
1834
+ `).filter(A=>A.length>0).length,t.capturePreview===!0)){let{body:A,truncated:w}=_o(E.slice(0,V8),m.type);S.preview=A,w&&(S.previewTruncated=!0)}e(v.DOWNLOAD,S)},u=m=>{oe(()=>{var S,A;let h=m.target,E=h instanceof Element?h.closest("a[download]"):null;E!==null&&a((S=E.getAttribute("href"))!=null?S:"",(A=E.getAttribute("download"))!=null?A:void 0)})};document.addEventListener("click",u,{capture:!0,signal:n.signal});let d=ke(HTMLAnchorElement.prototype,"click"),f=function(){let h=Zt(()=>{var E,S;return this.hasAttribute("download")?{href:(E=this.getAttribute("href"))!=null?E:"",name:(S=this.getAttribute("download"))!=null?S:void 0}:void 0});d.call(this),oe(()=>{h!==void 0&&a(h.href,h.name)})};return HTMLAnchorElement.prototype.click=f,()=>{n.abort(),URL.createObjectURL===s&&(URL.createObjectURL=i),HTMLAnchorElement.prototype.click===f&&(HTMLAnchorElement.prototype.click=d),o.clear()}}M();Yo();function cz(e){let t=ke(window,"open");if(t===void 0)return()=>{};let r=function(o,i,s){let a=t.call(this,o,i,s);return oe(()=>{e(v.CONTEXT_OPENED,{...o===void 0?{}:{href:o}})}),a};return window.open=r,()=>{window.open===r&&(window.open=t)}}M();Yo();M();dt();var j8=1e4,K8=4,Z8=2;async function W8(e,t){var f;if(t.aborted||typeof((f=e.body)==null?void 0:f.getReader)!="function")return;let n=e.body.getReader(),r=new TextDecoder,o=sz()*Z8,i="",s=!1,a=!1,l=()=>{},u=new Promise(m=>{l=()=>{a=!0,m()}}),d=de(l,j8);t.addEventListener("abort",l,{once:!0});try{await Promise.race([(async()=>{for(;!a&&!t.aborted;){let m=await n.read();if(a||t.aborted)return;if(m.done){i+=r.decode(),s=!0;return}let h=o-i.length,E=m.value.subarray(0,h*K8),S=r.decode(E,{stream:!0});if(i+=S.slice(0,h),i.length>=o||E.byteLength<m.value.byteLength)return}})(),u])}catch{}finally{Oe(d),t.removeEventListener("abort",l),s||n.cancel().catch(()=>{}),n.releaseLock()}return!s&&i.length===0?void 0:{text:i,complete:s}}async function rT(e,t,n,r){let o=n?{responseBodyReason:ar.UNREADABLE}:{};if(es(t)&&(!n||r.aborted))return o;try{let i=e.clone(),s,a=!1;if(es(t)){let u=await W8(i,r);s=u==null?void 0:u.text,a=(u==null?void 0:u.complete)===!1}else s=await rz(i.text());if(s===void 0)return o;let l=n?_o(s,t):bm(s,t);return{responseBody:l.body,...a||l.truncated?{responseBodyTruncated:!0}:{},...n?{}:{responseBodyReason:ar.ERROR_STATUS}}}catch{return o}}M();M();dt();var Y8=1e4;function lz(e,t,n,r,o,i){var l;if(!nz(o,i)||typeof((l=t.body)==null?void 0:l.getReader)!="function")return;let s;try{s=t.clone()}catch{return}let a=s.body;a!==null&&(e(v.NET_STREAM,{transport:po.FETCH,direction:fo.OPEN,...r,id:n}),(async()=>{let u=a.getReader(),d=!1,f,m=new Promise(h=>{f=de(()=>h("expired"),Y8)});try{for(;;){let h=await Promise.race([u.read(),m]);if(h==="expired"){d=!0,u.cancel().catch(()=>{});break}if(h.done)break}}catch{}finally{f!==void 0&&Oe(f)}e(v.NET_STREAM,{transport:po.FETCH,direction:fo.CLOSE,...r,id:n,...d?{gaveUp:!0}:{}})})())}M();function X8(e){if(e instanceof ArrayBuffer)return e.byteLength;if(typeof Blob!="undefined"&&e instanceof Blob)return e.size;if(ArrayBuffer.isView(e))return e.byteLength}function _m(e,t){if(typeof e!="string"){let r=X8(e);return r===void 0?{frameType:typeof e}:{frameType:"binary",frameBytes:r}}let n={frameBytes:e.length};if(t){let{body:r,truncated:o}=_o(e,"application/json");n.frame=r,o&&(n.frameTruncated=!0)}return n}function uz(e){try{return new URL(e,location.href).pathname===zs}catch{return e.includes(zs)}}var Qc={NULL:"0",STRING:"s",NUMBER:"n",BOOLEAN:"b",OTHER:"?"};function xm(e){if(e===null)return Qc.NULL;if(Array.isArray(e))return`[${e.map(xm).join(",")}]`;if(typeof e=="object"){let t=e;return`{${Object.keys(t).sort().map(n=>`${n}:${xm(t[n])}`).join(",")}}`}return typeof e=="string"?Qc.STRING:typeof e=="number"?Qc.NUMBER:typeof e=="boolean"?Qc.BOOLEAN:Qc.OTHER}function sT(e,t){return Tc(`${e}#${String(t)}`)}function q8(e){try{return xm(JSON.parse(e))}catch{return Qc.OTHER}}var J8=1<<20,Q8=9,eZ=10,tZ=13,nZ=32,rZ=127;function oZ(e){for(let t=0;t<e.length;t+=1){let n=e.charCodeAt(t);if(n===rZ||n<nZ&&n!==Q8&&n!==eZ&&n!==tZ)return!0}return!1}function iZ(e){if((e instanceof ArrayBuffer||ArrayBuffer.isView(e))&&!(e.byteLength>J8))try{let t=new TextDecoder("utf-8",{fatal:!0}).decode(e);return oZ(t)?void 0:t}catch{return}}function sZ(e){let t=[],n=0;return e.forEach((r,o)=>{typeof r=="string"&&(n+=r.length),t.push(JSON.stringify([o,typeof r=="string"?0:[r.type,r.size]]))}),t.length===0?void 0:sT(t.sort().join(),n)}function oT(e,t){let n,r="application/json",o=RO,i=iZ(e),s=()=>{var d,f;return(f=(d=e.constructor)==null?void 0:d.name)!=null?f:typeof e};if(typeof e=="string"||i!==void 0)n=i!=null?i:e,n.length>0&&(o=sT(q8(n),n.length));else if(typeof FormData!="undefined"&&e instanceof FormData){let d=sZ(e);return{...d===void 0?{}:{[Gu]:d},...t?{requestBodyType:s()}:{}}}else if(typeof URLSearchParams!="undefined"&&e instanceof URLSearchParams){if(n=e.toString(),r="application/x-www-form-urlencoded",n.length>0){let d=Object.fromEntries(new URLSearchParams(n));o=sT(xm(d),n.length)}}else if(e!=null)return t?{requestBodyType:s()}:{};let a={[Gu]:o};if(!t||n===void 0||n.length===0)return a;let{body:l,truncated:u}=_o(n,r);return u?{...a,requestBody:l,requestBodyTruncated:!0}:{...a,requestBody:l}}function dz(e){return e>=200&&e<400}function pz(e,t,n){let r={};e!==""&&(r.statusText=e),t!==null&&t!==""&&(r.contentType=t);let o=n!==null?Number.parseInt(n,10):Number.NaN;return Number.isFinite(o)&&(r.responseSize=o),r}function aZ(e){return typeof e=="string"?e:e instanceof URL?e.href:e.url}function cZ(e,t){return(t==null?void 0:t.method)!==void 0?t.method.toUpperCase():e instanceof Request?e.method.toUpperCase():"GET"}function lZ(e,t){var n,r;if(t!==void 0&&t.headers!==void 0)return(n=Zt(()=>new Headers(t.headers).get(e_)))!=null?n:void 0;if(e instanceof Request)return(r=Zt(()=>e.headers.get(e_)))!=null?r:void 0}var uZ=/@reticlehq|reticle\.ts|network\.ts|transport\.ts|<anonymous>|new Promise|node:internal/i,dZ=/node_modules|\/\.vite\/deps\//i;function pZ(e){var r;if(e===void 0)return;let t=e.split(`
1835
+ `).slice(1).map(o=>o.trim()).filter(o=>o.length>0&&!uZ.test(o)),n=t.find(o=>!dZ.test(o));return(r=n!=null?n:t[0])==null?void 0:r.slice(0,300)}function iT(){return pZ(new Error().stack)}function fZ(e){if(e===void 0)return{};let t={};return e.responseStart>0&&e.requestStart>0&&(t.ttfbMs=Math.round(e.responseStart-e.requestStart)),e.transferSize>0&&(t.transferSize=e.transferSize),t}function fz(e){try{let t=performance.getEntriesByName(e,"resource");return fZ(t[t.length-1])}catch{return{}}}function hZ(e){try{return Function.prototype.toString.call(e).includes("native code")}catch{return!1}}var hz=new WeakSet,Sm=Symbol.for("reticle.network"),Tm=()=>window;function mz(e,t={}){var Xa,xA,AA;if(Tm()[Sm]!==void 0)return()=>{};let n={};Tm()[Sm]=n;let r=performance.now(),o=t.captureBodies===!0,i=new AbortController,s=t.captureErrorBodies!==!1,a=t.reinterpret,l=Ur(window,"fetch"),u=l.bind(window);!hZ(l)&&!hz.has(l)&&e(v.BLIND_SPOT,{kind:cn.WRAPPED_NETWORK,count:1});let d=0,f=()=>`n${++d}`;window.fetch=async(Fe,xe)=>{var yA,wA,vA;let _t=aZ(Fe);if(((yA=t.ignore)==null?void 0:yA.call(t,_t))===!0)return u(Fe,xe);let $t=f(),at=performance.now(),kt=cZ(Fe,xe),zt=lZ(Fe,xe),Ri=zt===void 0?{}:{[th]:zt},ef=(wA=Zt(()=>oT(xe==null?void 0:xe.body,o)))!=null?wA:{},nr=co(_t),Ns=nr.url,tf=Zt(()=>iT()),Xg=tf===void 0?{}:{initiatorStack:tf};oe(()=>{e(v.NET_PENDING,{id:$t,method:kt,...nr,initiator:"fetch",...Xg})});try{let Dt=await u(Fe,xe),k5=performance.now(),Rs=(vA=Zt(()=>Dt.headers.get("content-type")))!=null?vA:null;oe(()=>{lz(e,Dt,$t,nr,Rs,Dt.headers.get("content-length"))}),Xe.add(_t);let qg=Os=>{oe(()=>{var NA;e(v.NET_REQUEST,{id:$t,method:kt,...nr,status:Dt.status,ok:dz(Dt.status),durationMs:Math.round(k5-at),initiator:"fetch",...Xg,...fz(_t),...pz(Dt.statusText,Rs,Dt.headers.get("content-length")),...ef,...Ri,...Os,...(NA=a==null?void 0:a(Ns,D5=>Dt.headers.get(D5)))!=null?NA:{}})})},z5=nT(Dt.status,s);if(o&&es(Rs))qg({responseBodyReason:ar.UNREADABLE}),rT(Dt,Rs,!0,i.signal).then(Os=>{typeof Os.responseBody=="string"&&oe(()=>e(v.NET_RESPONSE_BODY,{id:$t,method:kt,...nr,...Os}))}).catch(()=>{});else if((o||z5)&&tT(Rs))rT(Dt,Rs,o,i.signal).then(qg).catch(()=>{});else{let Os=o?eT(Rs):void 0;qg(Os===void 0?{}:{responseBodyReason:Os})}return Dt}catch(Dt){throw oe(()=>{e(v.NET_REQUEST,{id:$t,method:kt,url:Ns,status:0,ok:!1,error:Dt instanceof Error?Dt.message:String(Dt),durationMs:Math.round(performance.now()-at),initiator:"fetch",...Xg,...Ri})}),Dt}};let m=Ur(window,"fetch");hz.add(m);let h=new WeakMap,E=XMLHttpRequest.prototype,S=ke(E,"open"),A=ke(E,"send"),w=S;E.open=function(Fe,xe,..._t){oe(()=>{h.set(this,{id:f(),method:Fe.toUpperCase(),url:lr(String(xe)),rawUrl:String(xe),start:0})}),w.call(this,Fe,xe,..._t)};let N=ke(E,"open"),O=new WeakSet;E.send=function(Fe){oe(()=>{var _t;let xe=h.get(this);if(xe!==void 0){xe.start=performance.now(),xe.reqFields=(_t=Zt(()=>oT(Fe!=null?Fe:null,o)))!=null?_t:{},xe.initiatorStack=iT();let $t=xe.initiatorStack===void 0?{}:{initiatorStack:xe.initiatorStack};e(v.NET_PENDING,{id:xe.id,method:xe.method,...co(xe.rawUrl),initiator:"xhr",...$t}),O.has(this)||(O.add(this),this.addEventListener("loadend",()=>{oe(()=>{let at=h.get(this);if(at===void 0)return;Xe.add(at.rawUrl);let kt=this.getResponseHeader("content-type"),zt={},Ri=this.responseType===""||this.responseType==="text",ef=nT(this.status,s),nr=tT(kt)||o&&es(kt);if(o){let Ns=nr?ar.UNREADABLE:eT(kt);Ns!==void 0&&(zt={responseBodyReason:Ns})}if((o||ef)&&Ri&&nr)try{let{body:Ns,truncated:tf}=o?_o(this.responseText,kt):bm(this.responseText,kt);zt={responseBody:Ns,...tf?{responseBodyTruncated:!0}:{},...o?{}:{responseBodyReason:ar.ERROR_STATUS}}}catch{}e(v.NET_REQUEST,{id:at.id,method:at.method,...co(at.rawUrl),status:this.status,ok:dz(this.status),durationMs:Math.round(performance.now()-at.start),initiator:"xhr",...at.initiatorStack===void 0?{}:{initiatorStack:at.initiatorStack},...fz(at.rawUrl),...pz(this.statusText,kt,this.getResponseHeader("content-length")),...at.reqFields,...zt})})}))}}),A.call(this,Fe!=null?Fe:null)};let k=ke(E,"send"),G=window.EventSource,V=window.WebSocket,W,K;o&&typeof G=="function"&&(window.EventSource=class extends G{constructor(Fe,xe){super(Fe,xe),oe(()=>{let _t=co(String(Fe));e(v.NET_STREAM,{transport:po.SSE,direction:fo.OPEN,..._t}),this.addEventListener("message",$t=>{oe(()=>{e(v.NET_STREAM,{transport:po.SSE,direction:fo.IN,..._t,..._m($t.data,o)})})})})}},W=window.EventSource),o&&typeof V=="function"&&(window.WebSocket=(xA=class extends V{constructor(xe,_t){super(xe,_t);x(this,Xa);g(this,Xa,uz(String(xe))),!c(this,Xa)&&oe(()=>{let $t=co(String(xe));e(v.NET_STREAM,{transport:po.WS,direction:fo.OPEN,...$t}),this.addEventListener("message",at=>{oe(()=>{e(v.NET_STREAM,{transport:po.WS,direction:fo.IN,...$t,..._m(at.data,o)})})})})}send(xe){if(c(this,Xa)){super.send(xe);return}super.send(xe),oe(()=>{e(v.NET_STREAM,{transport:po.WS,direction:fo.OUT,...co(this.url),..._m(xe,o)})})}},Xa=new WeakMap,xA),K=window.WebSocket);let J=typeof navigator!="undefined"?Object.getPrototypeOf(navigator):null,le=J===null||(AA=Object.getOwnPropertyDescriptor(J,"sendBeacon"))==null?void 0:AA.value,ge;J!==null&&le!==void 0&&(ge=function(Fe,xe){let _t=f(),$t=Zt(()=>co(String(Fe))),at=Zt(()=>iT()),kt=le.call(this,Fe,xe);return oe(()=>{e(v.NET_REQUEST,{id:_t,method:"POST",...$t,status:0,ok:kt,queued:kt,durationMs:0,initiator:"beacon",...at===void 0?{}:{initiatorStack:at},...oT(xe,!1)})}),kt},J.sendBeacon=ge);let Xe=new Set,gu=0,Yg=200,Ya;if(typeof PerformanceObserver!="undefined")try{let Fe=new PerformanceObserver(xe=>{var _t,$t,at;for(let kt of xe.getEntries()){let zt=kt;if(gu>=Yg)return;let Ri=zt.initiatorType||"other";if((Ri==="fetch"||Ri==="xmlhttprequest")&&zt.startTime>=r)continue;let nr=zt.name;Xe.has(nr)||(Xe.add(nr),gu+=1,e(v.NET_REQUEST,{id:f(),method:"GET",...co(nr),durationMs:Math.round(zt.duration),initiator:Ri,...zt.transferSize>0?{transferSize:zt.transferSize}:{},...((_t=zt.responseStatus)!=null?_t:0)>0?{status:zt.responseStatus,ok:(($t=zt.responseStatus)!=null?$t:0)>=200&&((at=zt.responseStatus)!=null?at:0)<400}:{}}))}});Ya=Fe,Fe.observe({type:"resource",buffered:!0})}catch{}return()=>{Tm()[Sm]===n&&delete Tm()[Sm],i.abort(),Ya==null||Ya.disconnect(),window.fetch===m&&(window.fetch=l),ke(E,"open")===N&&(E.open=S),ke(E,"send")===k&&(E.send=A),W!==void 0&&window.EventSource===W&&(window.EventSource=G),K!==void 0&&window.WebSocket===K&&(window.WebSocket=V),J!==null&&le!==void 0&&J.sendBeacon===ge&&(J.sendBeacon=le)}}M();var mZ="Tauri-Response",gZ="error",gz={OK:"Ok",ERROR:"Err"},Ez=/^(?:ipc:\/\/[^/]*|https?:\/\/ipc\.localhost(?::\d+)?)\/(.+)$/;function bz(e,t){let n=Ez.exec(e),r=n==null?void 0:n[1];if(r===void 0)return;let o=t(mZ)!==gZ;return{url:`${Qb}${r}`,initiator:xn.IPC,method:xn.IPC,ok:o,status:o?Bu.OK:Bu.ERROR,statusText:o?gz.OK:gz.ERROR}}function _z(e){var t;return((t=Ez.exec(e))==null?void 0:t[1])===hh}function EZ(){return navigator.userAgent.includes("Electron")}function Sz(e,t={}){let n=window[Zo];if(typeof(n==null?void 0:n.subscribe)!="function")return EZ()&&e(v.BLIND_SPOT,{kind:cn.UNOBSERVED_IPC,count:1}),()=>{};let r=n.subscribe(o=>{oe(()=>{var l;let i=`${Qb}${o.channel}`;if(o.phase==="start"){e(v.NET_PENDING,{id:o.id,method:xn.IPC,url:i,initiator:xn.IPC});return}let s=o.oneWay===!0&&o.ok===void 0;s&&e(v.BLIND_SPOT,{kind:cn.VERDICTLESS_SEND,count:1});let a=o.ok===!0;e(v.NET_REQUEST,{id:o.id,method:xn.IPC,url:i,...s?{}:{ok:a,status:a?Bu.OK:Bu.ERROR},...o.oneWay===!0?{oneWay:!0}:{},durationMs:(l=o.durationMs)!=null?l:0,initiator:xn.IPC,...o.error===void 0?{}:{error:o.error},...o.responseSize===void 0?{}:{responseSize:o.responseSize},...t.captureBodies===!0?{...o.requestBody===void 0?{}:{requestBody:o.requestBody},...o.responseBody===void 0?{}:{responseBody:o.responseBody},...o.responseBodyTruncated===!0?{responseBodyTruncated:!0}:{}}:{}})})});return()=>{var o;(o=n.unsubscribe)==null||o.call(n,r)}}M();gt();It();ot();dn();var Tz=e=>e===void 0?0:Math.max(0,e.width)*Math.max(0,e.height);function xz(e){let t=globalThis.CSS;if(typeof(t==null?void 0:t.escape)=="function")return t.escape(e);let n="";for(let[r,o]of[...e].entries())/\d/.test(o)&&(r===0||r===1&&e.startsWith("-"))?n+=`\\${o.charCodeAt(0).toString(16)} `:/[\w-]/.test(o)?n+=o:n+=`\\${o}`;return n}function bZ(e){let t=Ne(e);if(t!==null)return`[${Fi()}="${t.replace(/["\\]/g,"\\$&")}"]`;let n=e.tagName.toLowerCase();if(0<e.id.length)return`${n}#${xz(e.id)}`;let r=e.classList.item(0);return r===null?n:`${n}.${xz(r)}`}function _Z(e){var n;let t;for(let r of e!=null?e:[]){let o=(n=r.node)!=null?n:null,i=o===null?null:wn(o)?o:o.parentElement;if(i===null||Rt(i))continue;let s=Math.max(Tz(r.previousRect),Tz(r.currentRect));(t===void 0||s>t.area)&&(t={el:i,area:s})}return t===void 0?void 0:{ref:re.refFor(t.el),selector:bZ(t.el)}}function Az(e){if(typeof PerformanceObserver!="function")return()=>{};let t=[],n=(i,s)=>{try{let a=new PerformanceObserver(l=>{for(let u of l.getEntries())s(u)});a.observe({type:i,buffered:!0}),t.push(a)}catch{}},r=0,o=0;return n("largest-contentful-paint",i=>{let s=Math.round(i.startTime);s<=o||(o=s,e(v.PERF,{metric:uc.LCP,value:s,at:s}))}),n("layout-shift",i=>{var l;let s=i;if(s.hadRecentInput===!0)return;r+=(l=s.value)!=null?l:0;let a=_Z(s.sources);e(v.PERF,{metric:uc.CLS,value:r,at:Math.round(i.startTime),...a===void 0?{}:{shifted:a}})}),n("longtask",i=>{e(v.PERF,{metric:uc.LONGTASK,value:Math.round(i.duration),at:Math.round(i.startTime)})}),()=>{for(let i of t)i.disconnect()}}M();var SZ=new Set(["navigate","reload","back_forward"]);function TZ(){try{let[e]=performance.getEntriesByType("navigation");return e}catch{return}}function yz(e){var s,a;let t=TZ(),n=t==null?void 0:t.type,r=t==null?void 0:t.name;if(t===void 0||typeof r!="string"||r.length===0)return()=>{};if(typeof n!="string"||!SZ.has(n))return()=>{};let o=t.responseStatus,i=typeof o=="number"&&o>0;return e(v.NET_REQUEST,{id:`doc-${String(Math.round((s=t.duration)!=null?s:0))}`,method:"GET",url:r,initiator:xn.DOCUMENT,durationMs:Math.round((a=t.duration)!=null?a:0),...i?{status:o,ok:o<400}:{},navigationType:n,...typeof t.transferSize=="number"?{transferSize:t.transferSize}:{}}),()=>{}}M();var xZ=/^(javascript|mailto|tel|sms|blob|data):/i;function AZ(){if(typeof window=="undefined")return;let e=window.navigation;return e instanceof EventTarget?e:void 0}function yZ(e){if(!(e instanceof Element))return;let t=e.closest("a");return t instanceof HTMLAnchorElement?t:void 0}var wZ=1e3;function wz(e,t,n){if(e.length===0||xZ.test(e))return!1;if(t)return!0;try{let r=new URL(e,n),o=new URL(n);return r.origin===o.origin?r.pathname!==o.pathname||r.search!==o.search:!0}catch{return!1}}function vz(e){if(typeof document=="undefined")return()=>{};let t=0,n,r=(a,l)=>{let u=Date.now();n!==void 0&&n.url===a&&u-n.at<wZ||(n={url:a,at:u},t+=1,e(v.NET_PENDING,{id:`nav-${String(t)}`,method:"GET",url:a,initiator:xn.NAVIGATION,...l?{download:!0}:{}}))},o=a=>{oe(()=>{var h;let l=yZ(a.target);if(l===void 0)return;let u=(h=l.getAttribute("href"))!=null?h:"",d=document.location.href,f=l.hasAttribute("download");if(!wz(u,f,d))return;let m=new URL(u,d).toString();queueMicrotask(()=>{oe(()=>{a.defaultPrevented||r(m,f)})})})},i=a=>{oe(()=>{let l=a.destination;if(l===void 0||l.sameDocument)return;let u=l.url;wz(u,!1,document.location.href)&&queueMicrotask(()=>{oe(()=>{a.defaultPrevented||r(u,!1)})})})},s=AZ();return s!==void 0&&s.addEventListener("navigate",i),document.addEventListener("click",o,!0),()=>{document.removeEventListener("click",o,!0),s!==void 0&&s.removeEventListener("navigate",i)}}M();pr();M();var vZ=3,NZ=256,RZ={emit:!0},OZ={emit:!1};function IZ(e){if(e<10)return!1;let t=e;for(;t%10===0;)t/=10;return t===1}function CZ(e){var t,n,r;return Tc([e.message,(t=e.source)!=null?t:"",e.line===void 0?"":String(e.line),(n=e.kind)!=null?n:"",(r=e.stack)!=null?r:""].join("\0"))}function Nz(e=vZ,t=NZ){let n=new Map;return{admit(r){var s,a;let o=CZ(r),i=((s=n.get(o))!=null?s:0)+1;if(n.delete(o),n.size>=t){let l=n.keys().next();(a=l.done)!=null&&a||n.delete(l.value)}return n.set(o,i),i<=e?RZ:IZ(i)?{emit:!0,repeats:i}:OZ}}}var Rz="securitypolicyviolation",LZ="report",$Z={log:v.CONSOLE_LOG,warn:v.CONSOLE_WARN,error:v.CONSOLE_ERROR,info:v.CONSOLE_INFO,debug:v.CONSOLE_DEBUG};function kZ(e){return e.map(t=>typeof t=="string"?t:t instanceof Error?t.message:mo(t)).join(" ")}var Oz=Z.MAX_STACK_LENGTH;function aT(e){if(!(e===void 0||e.length===0))return e.length>Oz?e.slice(0,Oz):e}function zZ(e){for(let t of e)if(t instanceof Error)return aT(t.stack)}function Iz(e){let t=["log","warn","error","info","debug"],n=new Map,r=new Map;for(let f of t){let m=Ur(console,f);n.set(f,m);let h=m.bind(console),E=(...S)=>{h(...S),oe(()=>{let A=f==="error"?zZ(S):void 0;e($Z[f],{message:kZ(S),...A===void 0?{}:{stack:A}})})};r.set(f,E),console[f]=E}let o=Nz(),i=f=>{let m=o.admit(f);m.emit&&e(v.ERROR_UNCAUGHT,{...f,...m.repeats===void 0?{}:{repeats:m.repeats}})},s=f=>{var m,h;if(!(f instanceof ErrorEvent)){let E=f.target;if(!(E instanceof Element)||E===document)return;let S=E.tagName.toLowerCase(),A=(h=(m=E.getAttribute("src"))!=null?m:E.getAttribute("href"))!=null?h:"";oe(()=>{let w=`<${S}> failed to load${A.length===0?"":`: ${A}`}`;i({message:w,kind:"resource",...A.length===0?{}:{source:A}})});return}oe(()=>{let E=aT(f.error instanceof Error?f.error.stack:void 0),S={message:f.message,source:f.filename,line:f.lineno,...E===void 0?{}:{stack:E}};i(S)})},a=f=>{oe(()=>{let m=f.reason,h=aT(m instanceof Error?m.stack:void 0),E={message:m instanceof Error?m.message:String(m),kind:"unhandledrejection",...h===void 0?{}:{stack:h}};i(E)})},l=f=>{let m=f.blockedURI.length===0?"inline content":f.blockedURI,h=LZ===f.disposition;e(h?v.CONSOLE_WARN:v.CONSOLE_ERROR,{message:h?`[Report Only] Content Security Policy directive: ${f.violatedDirective} would block ${m}`:`Content Security Policy directive: ${f.violatedDirective} blocked ${m}`,kind:Rz,...f.blockedURI.length===0?{}:{source:f.blockedURI}})},u=new AbortController,{signal:d}=u;return window.addEventListener("error",s,{capture:!0,signal:d}),window.addEventListener("unhandledrejection",a,{signal:d}),window.addEventListener(Rz,l,{capture:!0,signal:d}),()=>{for(let[f,m]of n)console[f]===r.get(f)&&(console[f]=m);u.abort()}}M();zc();var DZ={alert:void 0,confirm:!1,prompt:null},PZ=["alert","confirm","prompt"];function Cz(e){let t=window,n=new Map,r=new Map;for(let o of PZ){let i=t[o];if(typeof i!="function")continue;n.set(o,i);let s=i.bind(window),a=(...l)=>{if(!Yh())return s(...l);let u=DZ[o],d=l[0];return oe(()=>{e(v.DIALOG_OPENED,{kind:o,...typeof d=="string"?{message:d}:{},...u===void 0?{}:{answered:u}})}),u};r.set(o,a),t[o]=a}return()=>{for(let[o,i]of n)t[o]===r.get(o)&&(t[o]=i)}}M();gt();ot();function Lz(e){let t=new AbortController,{signal:n}=t,r=s=>{let a=s.target;a instanceof Element&&!Rt(a)&&e(v.ANIM_START,{name:s.animationName},re.refFor(a))},o=s=>{let a=s.target;a instanceof Element&&!Rt(a)&&e(v.ANIM_END,{name:s.animationName},re.refFor(a))},i=s=>{let a=s.target;a instanceof Element&&!Rt(a)&&e(v.ANIM_END,{name:s.propertyName,kind:"transition"},re.refFor(a))};return document.addEventListener("animationstart",r,{capture:!0,signal:n}),document.addEventListener("animationend",o,{capture:!0,signal:n}),document.addEventListener("transitionend",i,{capture:!0,signal:n}),()=>t.abort()}M();gt();dt();var $z=100,MZ="[data-reticle-reveal], [data-reveal], section";function kz(e){let t=new AbortController,{signal:n}=t,r=0,o=0,i,s=()=>{r=performance.now();let u=window.scrollY,d=Math.max(1,document.documentElement.scrollHeight-window.innerHeight);e(v.SCROLL_POSITION,{x:window.scrollX,y:u,percent:Math.round(u/d*100),direction:u>=o?fh.DOWN:fh.UP}),o=u},a=()=>{let u=performance.now()-r;if(u>=$z){i!==void 0&&(Oe(i),i=void 0),s();return}i===void 0&&(i=de(()=>{i=void 0,s()},$z-u))};window.addEventListener("scroll",a,{passive:!0,signal:n});let l;if(typeof IntersectionObserver=="function"){l=new IntersectionObserver(d=>{for(let f of d)f.isIntersecting&&e(v.REVEAL_SHOWN,{ratio:f.intersectionRatio},re.refFor(f.target))},{threshold:.25});let u=l;for(let d of document.querySelectorAll(MZ))u.observe(d)}return()=>{t.abort(),i!==void 0&&Oe(i),l==null||l.disconnect()}}M();dt();function Dz(){let e=window;return e.__TAURI_INTERNALS__!==void 0||e.__TAURI__!==void 0?"tauri":navigator.userAgent.includes("Electron")||e[Zo]!==void 0?"electron":"web"}function UZ(){let e=navigator.userAgent;return/Chrome|Chromium|Edg\//.test(e)?"blink":/Gecko\/|Firefox/.test(e)?"gecko":"webkit"}var HZ={"google chrome":et.CHROME,chrome:et.CHROME,"microsoft edge":et.EDGE,edge:et.EDGE,brave:et.BRAVE,opera:et.OPERA,arc:et.ARC,dia:et.DIA,firefox:et.FIREFOX,safari:et.SAFARI};function FZ(e){return e==="chromium"||e.includes("not")&&e.includes("brand")}function BZ(){var t;try{let r=(t=navigator.userAgentData)==null?void 0:t.brands;if(Array.isArray(r)){let o;for(let i of r){let s=typeof(i==null?void 0:i.brand)=="string"?i.brand.toLowerCase():"";if(s===""||FZ(s))continue;let a=HZ[s];if(a!==void 0)if(et.CHROME===a)o=a;else return a}return o!=null?o:et.OTHER}}catch{}let e=navigator.userAgent;return/Edg\//.test(e)?et.EDGE:/OPR\/|Opera/.test(e)?et.OPERA:/Firefox/.test(e)?et.FIREFOX:/Chrome|Chromium/.test(e)?et.CHROME:/Safari/.test(e)?et.SAFARI:et.OTHER}var zz=typeof window!="undefined"&&typeof window.fetch=="function"?window.fetch.bind(window):void 0;function GZ(){var n,r;let e=window.__TAURI_INTERNALS__,t=(r=(n=e==null?void 0:e.metadata)==null?void 0:n.currentWindow)==null?void 0:r.label;return typeof t=="string"&&t.length>0?t:void 0}function VZ(){try{let[e]=performance.getEntriesByType("navigation"),t=e==null?void 0:e.responseStatus;return typeof t=="number"&&t>0?t:void 0}catch{return}}async function jZ(e){let t=VZ();if(t!==void 0)return t;try{return e==="web"||zz===void 0||!/^https?:$/.test(location.protocol)?void 0:(await zz(location.href,{method:"HEAD",cache:"no-store"})).status}catch{return}}async function KZ(){let e=window[Zo];if(typeof(e==null?void 0:e.windowLabel)=="function")try{let t=await e.windowLabel();return typeof t=="string"&&t.length>0?t:void 0}catch{return}}function ZZ(e){return{hidden:document.visibilityState==="hidden",focused:document.hasFocus(),runtime:Dz(),engine:UZ(),brand:BZ(),...e===void 0?{}:{windowLabel:e}}}function Pz(e){let t=new AbortController,{signal:n}=t,r,o=GZ(),i=a=>{e(v.PAGE_HEALTH,{...ZZ(o),...r===void 0?{}:{documentStatus:r},reason:a})};document.addEventListener("visibilitychange",()=>i(Gs.VISIBILITY),{signal:n}),window.addEventListener("focus",()=>i(Gs.FOCUS),{signal:n}),window.addEventListener("blur",()=>i(Gs.BLUR),{signal:n}),i(Gs.INITIAL),Promise.all([jZ(Dz()),o===void 0?KZ():Promise.resolve(o)]).then(([a,l])=>{n.aborted||a===void 0&&l===o||(r=a,o=l,i(Gs.HEARTBEAT))});let s=Jh(()=>i(Gs.HEARTBEAT),YO.HEARTBEAT_MS);return()=>{s(),t.abort()}}M();gt();var WZ={VIDEO:"video",AUDIO:"audio"};function Mz(e){let t=new AbortController,n=r=>{oe(()=>{let o=r.target;if(!(o instanceof HTMLMediaElement))return;let i=WZ[o.tagName];if(i===void 0)return;let s=Number.isFinite(o.duration)?o.duration:void 0;e(v.MEDIA_STATE,{event:r.type,tag:i,currentTime:o.currentTime,...s===void 0?{}:{duration:s},readyState:o.readyState,paused:o.paused},re.refFor(o))})};for(let r of Object.values(zu))document.addEventListener(r,n,{capture:!0,signal:t.signal});return()=>t.abort()}M();var nt={CONNECT:"connect",DOM_OBSERVER:"dom_observer",NETWORK_OBSERVER:"network_observer",CONSOLE_OBSERVER:"console_observer",IPC_OBSERVER:"ipc_observer",HEALTH_OBSERVER:"health_observer",ROUTER_OBSERVER:"router_observer",ANIMATION_OBSERVER:"animation_observer",STORE_ADAPTER:"store_adapter",SNAPSHOT:"snapshot",ACTION:"action",COMMAND:"command",RECORDER:"recorder",TRANSPORT:"transport",TEARDOWN:"teardown"},YZ=500;function cT(e,t,n){try{let r=n instanceof Error?n.message:String(n);e(v.SDK_FAILED,{site:t,message:r.slice(0,YZ),...n instanceof Error?{errorType:n.constructor.name.slice(0,64)}:{}})}catch{}}function pt(e,t,n){try{return n()}catch(r){return cT(e,t,r),()=>{}}}function Uz(e,t){for(let n of t)try{n()}catch(r){cT(e,nt.TEARDOWN,r)}}function Hz(e,t){return[pt(e,nt.NETWORK_OBSERVER,()=>mz(e,{captureBodies:t.captureBodies,...t.captureErrorBodies===void 0?{}:{captureErrorBodies:t.captureErrorBodies},reinterpret:bz,ignore:_z})),pt(e,nt.IPC_OBSERVER,()=>Sz(e,{captureBodies:t.captureBodies})),pt(e,nt.ANIMATION_OBSERVER,()=>Az(e)),pt(e,nt.ROUTER_OBSERVER,()=>$C(e)),pt(e,nt.NETWORK_OBSERVER,()=>yz(e)),pt(e,nt.NETWORK_OBSERVER,()=>vz(e)),pt(e,nt.CONSOLE_OBSERVER,()=>Iz(e)),pt(e,nt.CONSOLE_OBSERVER,()=>Cz(e)),pt(e,nt.ANIMATION_OBSERVER,()=>Lz(e)),pt(e,nt.DOM_OBSERVER,()=>kz(e)),pt(e,nt.DOM_OBSERVER,()=>Gk(e)),pt(e,nt.STORE_ADAPTER,()=>dk(e)),pt(e,nt.STORE_ADAPTER,()=>Wk(e)),pt(e,nt.DOM_OBSERVER,()=>Yk(e)),pt(e,nt.DOM_OBSERVER,()=>w$(e)),pt(e,nt.NETWORK_OBSERVER,()=>az(e,{capturePreview:t.captureBodies})),pt(e,nt.DOM_OBSERVER,()=>qk(e)),pt(e,nt.HEALTH_OBSERVER,()=>Pz(e)),pt(e,nt.DOM_OBSERVER,()=>cz(e)),pt(e,nt.DOM_OBSERVER,()=>Mz(e)),pt(e,nt.DOM_OBSERVER,()=>pk(e))]}It();bd();pr();var XZ=["position:fixed","bottom:8px","right:8px","z-index:2147483647","font:11px ui-monospace,SFMono-Regular,Menlo,monospace","background:#151823","color:#e6e9f0","border:1px solid #2a2f3d","border-radius:8px","padding:6px 10px","pointer-events:none","opacity:0.85"].join(";");function Fz(){let e=document.createElement("div");return e.setAttribute("data-reticle-overlay",""),e.style.cssText=XZ,e.textContent="Reticle: connecting\u2026",document.body.appendChild(e),{update:t=>{e.textContent=`Reticle ${t.connected?"\u25CF":"\u25CB"} ${String(t.events)} events`},destroy:()=>{e.remove()}}}lT();uT();M();gt();Et();function Zn(e,t=""){return typeof e=="string"?e:t}function ai(e){let t=Zn(e);return t===""?void 0:t}function Am(e){let t=re.resolve(e);if(!(t instanceof Element))return e;let n=go(t);return n.name.length>0?`${n.role} "${n.name}"`:`${n.role} (${e})`}function Bz(e){switch(e){case H.ACT:case H.ACT_SEQUENCE:return ct.ACTING;case H.SNAPSHOT:case H.QUERY:case H.MATCH:case H.INSPECT:case H.ANIMATIONS:case H.STATE_READ:case H.CAPABILITIES:return ct.READING;default:return ct.IDLE}}function Gz(e,t={}){var n;switch(e){case H.SNAPSHOT:return"Looking at the page";case H.QUERY:case H.MATCH:{let r=e===H.MATCH?(n=t.query)!=null?n:{}:t,o=qZ(r);return o!==void 0?`Finding ${o}`:"Finding an element"}case H.INSPECT:{let r=ai(t.ref);return r!==void 0?`Inspecting ${Am(r)}`:"Inspecting an element"}case H.ANIMATIONS:return"Reading animations";case H.STATE_READ:{let r=ai(t.store);return r!==void 0?`Reading state: ${r}`:"Reading state"}case H.CAPABILITIES:return"Reading capabilities";default:return e}}function qZ(e){var o,i,s,a;let t=(o=ai(e.testid))!=null?o:Je.TESTID===Zn(e.by)?ai(e.value):void 0;if(t!==void 0)return`[testid=${t}]`;let n=ai(e.name),r=(a=(s=(i=ai(e.value))!=null?i:ai(e.text))!=null?s:ai(e.label))!=null?a:ai(e.role);return r!==void 0?n!==void 0?`"${r}" (${n})`:`"${r}"`:n!==void 0?`"${n}"`:void 0}_d();It();M();M();fd();Et();ot();Zi();var Vz=["position:fixed","top:8px","left:50%","transform:translateX(-50%)","z-index:2147483647","display:flex","gap:6px","align-items:center","flex-wrap:wrap","max-width:90vw","font:12px ui-sans-serif,system-ui,sans-serif","background:#151823","color:#e6e9f0","border:1px solid #2a2f3d","border-radius:10px","padding:6px 10px","box-shadow:0 8px 30px rgba(0,0,0,.5)"].join(";"),ym=["font:inherit","cursor:pointer","background:#262b3a","color:#e6e9f0","border:1px solid #3a4151","border-radius:7px","padding:3px 9px"].join(";"),dT=["font:inherit","background:#0e1018","color:#e6e9f0","border:1px solid #3a4151","border-radius:7px","padding:3px 8px"].join(";"),jz=["opacity:.75","margin-left:4px"].join(";"),Kz=["display:flex","gap:6px","align-items:center","flex-wrap:wrap"].join(";");var JZ="recorded 0 steps",QZ="recording\u2026",Zz="ready",e9="pick an annotation",t9=cc.ACT,pT={record:"Record",stop:"Stop",annotate:"Annotate"},n9={[je.ASSERT_SIGNAL]:"assert signal",[je.ASSERT_VISIBLE]:"assert visible",[je.ASSERT_STATE]:"assert state",[je.ASSERT_NET]:"assert request",[je.MARK_DYNAMIC]:"mark dynamic",[je.SUCCESS_STATE]:"success state",[je.INTENT]:"intent"},r9=new Set([je.ASSERT_SIGNAL,je.SUCCESS_STATE]),o9="recorded-flow";function Xz(e){let t=Ne(e);if(t!==null&&t.length>0)return{anchor:{kind:rr.TESTID,value:t},degraded:!1};let n=Re(e),r=Ae(e);return n!=="generic"&&(n.length>0||r.length>0)?{anchor:r.length>0?{kind:rr.ROLE,role:n,name:r}:{kind:rr.ROLE,role:n},degraded:!1}:{anchor:{kind:rr.ROLE,role:NR},degraded:!0}}function Wz(e){return e instanceof HTMLTextAreaElement?!0:e instanceof HTMLInputElement&&Ud(e)==="textbox"}function Ud(e){let t=e.type.toLowerCase();return t==="checkbox"?"checkbox":t==="radio"?"radio":["text","email","tel","url","search","password",""].includes(t)?"textbox":"other"}function el(e,t,n){let{anchor:r,degraded:o}=Xz(e),i={tool:t9,anchor:r,action:t};n!==void 0&&(i.args=n),o&&(i.degraded=!0);let s=pd(e);return s!==void 0&&(i.source=s.line===void 0?{file:s.file}:{file:s.file,line:s.line}),i}function i9(e,t,n,r,o){let i=t.map(u=>({...u})),s=[],a;for(let u of n){if(u.kind===je.MARK_DYNAMIC){s.push(u.anchor);continue}if(u.kind===je.SUCCESS_STATE){u.signal!==void 0&&(a={kind:z.SIGNAL,name:u.signal});continue}let d=i.at(-1);d!==void 0&&(u.kind===je.ASSERT_SIGNAL&&u.signal!==void 0?d.expect=Yz(d.expect,{kind:z.SIGNAL,name:u.signal}):u.kind===je.ASSERT_VISIBLE&&(d.expect=Yz(d.expect,{kind:z.ELEMENT,query:s9(u.anchor)})))}let l={version:gb,name:e,createdAt:r,steps:i};return o!==void 0&&o.length>0&&(l.startPath=o),s.length>0&&(l.dynamic=s),a!==void 0&&(l.success=a),l}function Yz(e,t){return e===void 0?t:e.kind===z.ALL_OF?{kind:z.ALL_OF,predicates:[...e.predicates,t]}:{kind:z.ALL_OF,predicates:[e,t]}}function s9(e){return e.kind===rr.TESTID?{testid:e.value}:e.kind===rr.ROLE?e.name!==void 0?{role:e.role,name:e.name}:{role:e.role}:{}}var ta,gr,mn,Bd,ns,ci,tl,rs,na,So,Hr,X,qz,Hd,Jz,Qz,eD,tD,ts,nD,rD,hT,oD,iD,sD,ea,aD,wm,cD,lD,Fd,vm,uD,fT=class{constructor(t){x(this,X);x(this,ta);x(this,gr,on.IDLE);x(this,mn,[]);x(this,Bd);x(this,ns,[]);x(this,ci);x(this,tl);x(this,rs);x(this,na);x(this,So);x(this,Hr);g(this,ta,t)}phase(){return c(this,gr)}steps(){return c(this,mn).map(t=>({...t}))}mount(){c(this,rs)===void 0&&typeof document!="undefined"&&(T(this,X,aD).call(this),T(this,X,qz).call(this))}destroy(){var t,n;(t=c(this,tl))==null||t.abort(),g(this,tl,void 0),(n=c(this,rs))==null||n.remove(),g(this,rs,void 0),g(this,na,void 0),g(this,So,void 0),g(this,gr,on.IDLE),g(this,mn,[]),g(this,ns,[]),g(this,Hr,void 0),g(this,ci,void 0)}};ta=new WeakMap,gr=new WeakMap,mn=new WeakMap,Bd=new WeakMap,ns=new WeakMap,ci=new WeakMap,tl=new WeakMap,rs=new WeakMap,na=new WeakMap,So=new WeakMap,Hr=new WeakMap,X=new WeakSet,qz=function(){let t=new AbortController;g(this,tl,t);let n={capture:!0,signal:t.signal};document.addEventListener("click",r=>T(this,X,Jz).call(this,r),n),document.addEventListener("input",r=>T(this,X,Qz).call(this,r),n),document.addEventListener("change",r=>T(this,X,eD).call(this,r),n),document.addEventListener("submit",r=>T(this,X,tD).call(this,r),n)},Hd=function(t){let n=t.target;if(n instanceof Element&&!Rt(n))return n},Jz=function(t){let n=T(this,X,Hd).call(this,t);if(n!==void 0){if(c(this,gr)===on.ANNOTATING){T(this,X,nD).call(this,n);return}c(this,gr)===on.RECORDING&&(n instanceof HTMLInputElement&&(Ud(n)==="checkbox"||Ud(n)==="radio")||n instanceof HTMLSelectElement||(T(this,X,ts).call(this),c(this,mn).push(el(n,D.CLICK))))}},Qz=function(t){if(c(this,gr)!==on.RECORDING)return;let n=T(this,X,Hd).call(this,t);n===void 0||!Wz(n)||g(this,ci,{el:n,value:n.value})},eD=function(t){if(c(this,gr)!==on.RECORDING)return;let n=T(this,X,Hd).call(this,t);if(n!==void 0){if(n instanceof HTMLInputElement&&Ud(n)==="checkbox"){T(this,X,ts).call(this),c(this,mn).push(el(n,n.checked?D.CHECK:D.UNCHECK));return}if(n instanceof HTMLInputElement&&Ud(n)==="radio"){T(this,X,ts).call(this),c(this,mn).push(el(n,D.CHECK));return}if(n instanceof HTMLSelectElement){T(this,X,ts).call(this),c(this,mn).push(el(n,D.SELECT,{value:n.value}));return}Wz(n)&&(g(this,ci,{el:n,value:n.value}),T(this,X,ts).call(this))}},tD=function(t){if(c(this,gr)!==on.RECORDING)return;let n=T(this,X,Hd).call(this,t);n!==void 0&&(T(this,X,ts).call(this),c(this,mn).push(el(n,D.SUBMIT)))},ts=function(){let t=c(this,ci);if(t===void 0)return;g(this,ci,void 0);let n=pn(t.el)?ve:t.value;c(this,mn).push(el(t.el,D.FILL,{value:n}))},nD=function(t){let n=c(this,Hr);if(n===void 0)return;let{anchor:r}=Xz(t),o={kind:n.kind,anchor:r},i=T(this,X,hT).call(this);i!==void 0&&(o.signal=i),c(this,ns).push(o),g(this,Hr,void 0),T(this,X,ea).call(this,on.RECORDING),T(this,X,Fd).call(this)},rD=function(){let t=c(this,Hr);if(t===void 0)return;let n=c(this,mn).at(-1);if(n===void 0){g(this,Hr,void 0),T(this,X,ea).call(this,on.RECORDING),T(this,X,Fd).call(this);return}let r={kind:t.kind,anchor:n.anchor},o=T(this,X,hT).call(this);o!==void 0&&(r.signal=o),c(this,ns).push(r),g(this,Hr,void 0),T(this,X,ea).call(this,on.RECORDING),T(this,X,Fd).call(this)},hT=function(){var r,o;let t=(r=c(this,So))==null?void 0:r.querySelector("[data-reticle-signal]"),n=(o=t==null?void 0:t.value)!=null?o:"";return n.length>0?n:void 0},oD=function(){g(this,mn,[]),g(this,Bd,typeof location=="undefined"?void 0:location.pathname),g(this,ns,[]),g(this,ci,void 0),g(this,Hr,void 0),T(this,X,ea).call(this,on.RECORDING),T(this,X,vm).call(this,QZ)},iD=function(){var r,o;T(this,X,ts).call(this);let t=(o=(r=T(this,X,uD).call(this))!=null?r:c(this,ta).defaultName)!=null?o:o9,n=i9(t,c(this,mn),c(this,ns),c(this,ta).now(),c(this,Bd));c(this,ta).emit(v.FLOW_RECORDED,{name:t,flow:n}),T(this,X,vm).call(this,c(this,mn).length===0?JZ:Zz),T(this,X,ea).call(this,on.IDLE),T(this,X,Fd).call(this)},sD=function(){c(this,gr)===on.RECORDING&&(T(this,X,ea).call(this,on.ANNOTATING),T(this,X,vm).call(this,e9),T(this,X,cD).call(this))},ea=function(t){g(this,gr,t)},aD=function(){let t=document.createElement("div");t.setAttribute("data-reticle-overlay",""),t.style.cssText=Vz;let n=document.createElement("input");n.setAttribute("data-reticle-name",""),n.setAttribute("placeholder","flow name"),n.style.cssText=dT,t.appendChild(n),t.appendChild(T(this,X,wm).call(this,"record",pT.record,()=>T(this,X,oD).call(this))),t.appendChild(T(this,X,wm).call(this,"stop",pT.stop,()=>T(this,X,iD).call(this))),t.appendChild(T(this,X,wm).call(this,"annotate",pT.annotate,()=>T(this,X,sD).call(this)));let r=document.createElement("span");r.setAttribute("data-reticle-status",""),r.style.cssText=jz,r.textContent=Zz,t.appendChild(r);let o=document.createElement("div");o.setAttribute("data-reticle-menu",""),o.style.cssText=Kz,t.appendChild(o),document.body.appendChild(t),g(this,rs,t),g(this,na,r),g(this,So,o)},wm=function(t,n,r){let o=document.createElement("button");return o.setAttribute("data-reticle-action",t),o.textContent=n,o.style.cssText=ym,o.addEventListener("click",r),o},cD=function(){let t=c(this,So);if(t!==void 0){t.textContent="";for(let n of Object.values(je)){if(n===je.INTENT)continue;let r=document.createElement("button");r.setAttribute("data-reticle-annkind",n),r.textContent=n9[n],r.style.cssText=ym,r.addEventListener("click",()=>T(this,X,lD).call(this,n)),t.appendChild(r)}}},lD=function(t){g(this,Hr,{kind:t});let n=c(this,So);if(n===void 0)return;if(r9.has(t)){let o=document.createElement("select");o.setAttribute("data-reticle-signal",""),o.style.cssText=dT;for(let i of Ki().signals){let s=document.createElement("option");s.value=i,s.textContent=i,o.appendChild(s)}n.appendChild(o)}let r=document.createElement("button");r.setAttribute("data-reticle-action","annotate-confirm"),r.textContent="on prior step",r.style.cssText=ym,r.addEventListener("click",()=>T(this,X,rD).call(this)),n.appendChild(r)},Fd=function(){c(this,So)!==void 0&&(c(this,So).textContent="")},vm=function(t){c(this,na)!==void 0&&(c(this,na).textContent=t)},uD=function(){var r,o;let t=(r=c(this,rs))==null?void 0:r.querySelector("[data-reticle-name]"),n=(o=t==null?void 0:t.value.trim())!=null?o:"";return n.length>0?n:void 0};function dD(e){return new fT(e)}NT();M();function HD(e){return{...e.env===void 0?{}:{env:e.env},...e.scope===void 0?{}:{scope:e.scope},...e.injected===!0?{instrumentation:lh.INJECTED}:{}}}function FD(e,t){return e==="production"&&!t}function BD(e,t){let n=e.token;if(!(e.lease!==!0||n===void 0||n.length===0||n===t))return n}function wY(e){let t;try{t=new URL(e)}catch{return{url:e,adjusted:!1}}return t.protocol!=="ws:"&&t.protocol!=="wss:"||t.pathname!==""&&t.pathname!=="/"?{url:e,adjusted:!1}:(t.pathname=zs,{url:t.toString(),adjusted:!0})}function vY(e,t,n,r,o="http:"){var l;let i;try{i=new URL(t)}catch{return{allowed:!1,reason:"invalid Reticle bridge URL"}}if(i.protocol!=="ws:"&&i.protocol!=="wss:")return{allowed:!1,reason:"Reticle bridge URL must use ws:// or wss://"};if(((l=r==null?void 0:r.length)!=null?l:0)>Z.MAX_TOKEN_LENGTH)return{allowed:!1,reason:`Reticle pairing token exceeds ${String(Z.MAX_TOKEN_LENGTH)} characters`};let s=!E_(i.hostname);return s&&i.protocol!=="wss:"?{allowed:!1,reason:"a non-local Reticle bridge must use wss://"}:!bI(o,e)||s?n?r===void 0||r.length===0?{allowed:!1,reason:"a pairing token is required outside localhost"}:{allowed:!0}:{allowed:!1,reason:"Reticle is disabled outside localhost unless allowNonLocalhost is explicitly enabled"}:{allowed:!0}}var NY=20,RY="[Reticle] killed for this page. Restart your dev server or reload the page to bring it back.",OY="Session ended - lost connection to Reticle (the agent is no longer running).";function IY(e,t){return e===void 0||e===ju?t():e}function CY(){try{let e=new URL(window.location.href);if(!e.searchParams.has(pm))return;e.searchParams.delete(pm),window.history.replaceState(window.history.state,"",e.toString())}catch{}}function bA(e){let t=new URLSearchParams(e),n={},r=t.get(or.SESSION),o=t.get(or.PROJECT),i=_A(Gn,t.get(or.HUD));return r!==null&&r.length>0&&(n.session=r),o!==null&&o.length>0&&(n.projectId=o),i!==void 0&&(n.hud=i),n}function LY(e){return e===void 0?{placed:[]}:{remember:e,placed:Gn.SHOWN===e?[]:[e]}}function u5(e,t){var i;let n=bA(t),r=e.session!==void 0&&e.session!==ju?e.session:void 0,o=(i=e.projectId)!=null?i:n.projectId;return{session:r!=null?r:n.session,projectId:o!==void 0&&o.length>0?o:void 0}}function $Y(e){return{t:e.t,seq:e.seq,type:e.type,sessionId:e.sessionId,ref:e.ref,documentId:e.documentId,editEpoch:0===e.editEpoch?void 0:e.editEpoch,data:e.data}}var io,Yp,Va,Mo,ja,Wg,Xp,ys,Ue,lu,Ka,vi,qp,uu,Jp,Za,Uo,du,ws,Qp,vs,pu,Wa,Ho,fu,Ni,kn,p5,Fo,f5,h5,m5,g5,E5,hu=class{constructor(){x(this,kn);x(this,io);x(this,Yp,new Map);x(this,Va,[]);x(this,Mo,!1);x(this,ja,"default");x(this,Wg,sI(Math.random));x(this,Xp,0);x(this,ys);x(this,Ue);x(this,lu,new Map);x(this,Ka,[]);x(this,vi);x(this,qp);x(this,uu,!1);x(this,Jp,!1);x(this,Za);x(this,Uo);x(this,du,0);x(this,ws);x(this,Qp,{});x(this,vs);x(this,pu,!1);x(this,Wa);x(this,Ho);x(this,fu,[]);x(this,Ni);x(this,Fo,(t,n,r)=>{var i,s,a;let o=$Y({seq:c(this,du),t:Math.round(performance.now()-c(this,Xp)),type:t,sessionId:c(this,ja),documentId:c(this,Wg),editEpoch:gd.current,data:n,ref:r});try{(i=c(this,io))==null||i.sendEvent(o),g(this,du,c(this,du)+1),(s=c(this,ys))==null||s.update({connected:!0,events:c(this,du)}),t===v.ROUTE_CHANGE&&((a=c(this,Ue))==null||a.refilterFlows())}catch{}})}connect(t={}){var f,m,h,E,S,A,w;if(c(this,Mo)){let N=BD(t,c(this,ws));N!==void 0&&(g(this,ws,N),(f=c(this,io))==null||f.redialAfterRefusal()),T(this,kn,h5).call(this,t);return}if(typeof window=="undefined"||typeof document=="undefined")return;let n=globalThis.process,r=(m=n==null?void 0:n.env)==null?void 0:m.NODE_ENV;if(FD(r,t.allowInProduction===!0)){globalThis.console.warn("[Reticle] disabled in production (NODE_ENV=production). Gate the import behind import.meta.env.DEV, or pass allowInProduction:true to override.");return}CY();let o=wY((h=t.url)!=null?h:LR(bb)),i=o.url;o.adjusted&&globalThis.console.warn(`[Reticle] bridge URL has no path; using ${i} (the bridge only accepts WebSocket upgrades on ${zs}).`);let s=vY(window.location.hostname,i,t.allowNonLocalhost===!0,t.token,window.location.protocol);if(!s.allowed){globalThis.console.warn(`[Reticle] ${(E=s.reason)!=null?E:"connection blocked"}`);return}t.root!==void 0&&t.root.length>0&&(globalThis[nh]=t.root);let a=(S=t.sdkVersion)!=null?S:globalThis[IO];g(this,vs,typeof a=="string"&&a.length>0?a:void 0);let l=u5(t,window.location.search),u=IY(l.session,()=>"");g(this,ja,JC(u.length>0?u:void 0,QC(window),()=>{var N;return typeof((N=globalThis.crypto)==null?void 0:N.randomUUID)=="function"?`s${globalThis.crypto.randomUUID()}`:`s${Date.now().toString(36)}`})),g(this,ws,t.token!==void 0&&t.token.length>0?t.token:void 0),g(this,Ho,l.projectId),g(this,Qp,HD(t)),T(this,kn,f5).call(this,t.redact),g(this,Xp,performance.now()),g(this,Yp,Rk()),g(this,io,new hm({url:i,hello:()=>T(this,kn,m5).call(this),handleCommand:N=>T(this,kn,g5).call(this,N),onConnected:()=>{var N;g(this,Jp,!0),(N=c(this,Ue))==null||N.sessionStart()},onConnectionLost:()=>{var N;Bc(),((N=c(this,Ue))==null?void 0:N.sessionActive)===!0&&c(this,Ue).setState(Qe.ENDED,OY)},onUnreachable:({url:N,attempts:O})=>{var k;Mr(gm(N,O)),(k=c(this,Ue))==null||k.showUnreachable(N,O)}})),Gh(()=>{var N;return(N=c(this,io))==null?void 0:N.reannounce()}),AC(t.exposePresenter===!0),kC(t.testIdAttribute),t.networkBodyMaxChars!==void 0&&iz(t.networkBodyMaxChars);let d=c(this,Fo);g(this,pu,t.captureNetworkBodies===!0),g(this,Wa,typeof t.sourceMapping=="boolean"?t.sourceMapping:void 0),g(this,Va,Hz(d,{captureBodies:c(this,pu),...t.captureErrorBodies===void 0?{}:{captureErrorBodies:t.captureErrorBodies}})),t.overlay===!0&&(g(this,ys,Fz()),c(this,ys).update({connected:!0,events:0})),g(this,vi,bA(window.location.search).hud),t.present!==!1&&Gn.REMOVED!==c(this,vi)&&T(this,kn,p5).call(this,t),t.recorder===!0&&(g(this,Za,dD({emit:d,now:()=>Date.now()})),c(this,Za).mount()),((A=t.annotate)!=null?A:t.present!==!1)&&(g(this,Uo,new pa({emit:d,now:()=>Date.now(),onMark:N=>{var O;return(O=c(this,Ue))==null?void 0:O.log(Ge.HUMAN,`\u{1F6A9} #${String(N.index)} ${N.label}${N.source!==void 0?` \xB7 ${N.source}`:""} \u2014 ${N.note}`)},shouldBlock:()=>{var N,O;return(O=(N=c(this,qp))==null?void 0:N.call(this).blockPageInteractions)!=null?O:!0}})),c(this,Uo).mount(),(w=c(this,Ue))==null||w.bindAnnotator(c(this,Uo))),c(this,io).connect(),g(this,Mo,!0)}get connected(){return c(this,Mo)}routes(t){LC(t)}signal(t,n={}){c(this,Fo).call(this,v.SIGNAL,{name:t,data:n})}busy(t){return OC(t,(n,r)=>{this.signal(n,r)})}state(t,n){c(this,Fo).call(this,v.STATE_CHANGE,{name:t,value:n})}renderCommit(t){t>0&&c(this,Fo).call(this,v.RENDER_COMMIT,{commits:t})}describe(t){Cc(t)}endSession(){var t;(t=c(this,Ue))==null||t.setState(Qe.ENDED)}observeHotUpdates(t){gd.observe(t)}disconnect(){var t,n,r,o,i,s;c(this,Mo)&&(Uz(c(this,Fo),c(this,Va)),g(this,Va,[]),(t=c(this,io))==null||t.close(),g(this,io,void 0),(n=c(this,ys))==null||n.destroy(),g(this,ys,void 0),(r=c(this,Ue))==null||r.sessionEnd(),(o=c(this,Ue))==null||o.destroy(),g(this,Ue,void 0),(i=c(this,Za))==null||i.destroy(),g(this,Za,void 0),(s=c(this,Uo))==null||s.destroy(),g(this,Uo,void 0),Bc(),g(this,Mo,!1))}};io=new WeakMap,Yp=new WeakMap,Va=new WeakMap,Mo=new WeakMap,ja=new WeakMap,Wg=new WeakMap,Xp=new WeakMap,ys=new WeakMap,Ue=new WeakMap,lu=new WeakMap,Ka=new WeakMap,vi=new WeakMap,qp=new WeakMap,uu=new WeakMap,Jp=new WeakMap,Za=new WeakMap,Uo=new WeakMap,du=new WeakMap,ws=new WeakMap,Qp=new WeakMap,vs=new WeakMap,pu=new WeakMap,Wa=new WeakMap,Ho=new WeakMap,fu=new WeakMap,Ni=new WeakMap,kn=new WeakSet,p5=function(t){c(this,uu)||(g(this,uu,!0),Promise.resolve().then(()=>(K2(),j2)).then(({Presenter:n})=>Promise.resolve().then(()=>(_l(),aP)).then(r=>({Presenter:n,settings:r}))).then(({Presenter:n,settings:r})=>{if(!c(this,Mo))return;g(this,qp,r.getPresenterSettings);let o={};t.pace!==void 0&&(o.paceMs=t.pace),t.narrationDwellMs!==void 0&&(o.narrationDwellMs=t.narrationDwellMs),t.border!==void 0&&(o.border=t.border),t.logMax!==void 0&&(o.logMax=t.logMax),t.endedFadeMs!==void 0&&(o.endedFadeMs=t.endedFadeMs),t.idleEndMs!==void 0&&(o.idleEndMs=t.idleEndMs),o.sessionId=c(this,ja),c(this,Ho)!==void 0&&(o.projectId=c(this,Ho)),o.onControl=s=>c(this,Fo).call(this,v.HUMAN_CONTROL,s.text!==void 0?{kind:s.kind,text:s.text}:{kind:s.kind}),o.onHudUse=s=>c(this,Fo).call(this,v.HUD_USED,{...s}),o.onKill=()=>{this.disconnect(),Mr(RY)};let i=new n(o);g(this,Ue,i),i.mount(),i.showSdkVersion(c(this,vs));for(let s of c(this,lu).values())i.handlePush(s);c(this,lu).clear(),0<c(this,Ka).length&&i.sessionStart();for(let s of c(this,Ka).splice(0))i.narrate(s.text,s.level,s.actor,s.summary);c(this,vi)!==void 0&&i.placeHud(c(this,vi),void 0),g(this,vi,void 0),Promise.resolve().then(()=>(l5(),c5)).then(s=>{var l;if(!c(this,Mo))return;let a=s.mountTour({document,storage:s.safeLocalStorage(),projectId:(l=bA(window.location.search).projectId)!=null?l:window.location.origin,isDriving:()=>ct.IDLE!==i.mode,search:window.location.search,navigator,copy:u=>{var d,f;return(f=(d=navigator.clipboard)==null?void 0:d.writeText(u).then(()=>!0,()=>!1))!=null?f:!1},select:u=>{let d=window.getSelection();if(d===null)return;let f=document.createRange();f.selectNodeContents(u),d.removeAllRanges(),d.addRange(f)}});a!==void 0&&c(this,Va).push(a.destroy)}),c(this,Jp)&&i.sessionStart(),c(this,Uo)!==void 0&&i.bindAnnotator(c(this,Uo))}).catch(()=>{}))},Fo=new WeakMap,f5=function(t){dI(uI(t,Mr)),g(this,fu,pI(t))},h5=function(t){var r;if(c(this,Ho)!==void 0)return;let n=u5(t,window.location.search).projectId;n!==void 0&&(g(this,Ho,n),(r=c(this,io))==null||r.reannounce())},m5=function(){return{kind:sn.HELLO,protocolVersion:Bf,sessionId:c(this,ja),...c(this,Ho)===void 0?{}:{projectId:c(this,Ho)},url:zh(),title:lo(document.title),adapters:Ed(),...c(this,ws)===void 0?{}:{token:c(this,ws)},...c(this,Qp),hasCapabilities:Vh(),channels:kk(),platform:zk(),commands:Dk(),captureBodies:c(this,pu),...c(this,Wa)===void 0?{}:{sourceMapping:c(this,Wa)},...c(this,vs)===void 0?{}:{sdkVersion:c(this,vs)},contract:M_,contractParts:{commands:[...nd.commands],events:[...nd.events],actions:[...nd.actions]},...c(this,fu).length===0?{}:{redactKeys:c(this,fu)}}},g5=async function(t){var r,o,i,s,a,l,u,d;if(t.name===H.MARKERS){let f=YC(document),m=c(this,vs)!==void 0||c(this,Wa)!==void 0,h=XC({buildPlugin:m,adapters:Ed(),markers:f});return{ok:!0,result:{markers:f,...h.length===0?{}:{notApplicable:h}}}}if(t.name===H.NARRATE)return c(this,Ue)===void 0&&c(this,uu)?(c(this,Ka).length<NY&&c(this,Ka).push({text:Zn(t.args.text),level:Zn(t.args.level,"info"),actor:d5(t.args),summary:t.args.summary===!0}),{ok:!0,result:{shown:!1,buffered:!0}}):((r=c(this,Ue))==null||r.sessionStart(),(o=c(this,Ue))==null||o.narrate(Zn(t.args.text),Zn(t.args.level,"info"),d5(t.args),t.args.summary===!0),{ok:!0,result:{shown:c(this,Ue)!==void 0}});if(t.name===H.SESSION_CONFIG){let f=t.args.idleEndMs;typeof f=="number"&&((i=c(this,Ue))==null||i.setIdleEndMs(f));let m=_A(Gn,t.args.hud),h=_A(rh,t.args.corner),E=c(this,Ue),S;if(E!==void 0)S=E.placeHud(m,h);else{let A=LY(m);A.remember!==void 0&&g(this,vi,A.remember),S=A.placed}return{ok:!0,result:{applied:c(this,Ue)!==void 0,idleEndMs:f,...0<S.length?{hud:S}:{}}}}if(t.name===H.PRESENTER||t.name===H.FLOWS||t.name===H.FLOW_PROGRESS||t.name===H.PLAN||t.name===H.IMPACT)return c(this,Ue)===void 0?(c(this,lu).set(t.name,t),{ok:!0,result:{applied:!1,buffered:!0}}):(c(this,Ue).handlePush(t),{ok:!0,result:{applied:!0}});let n=c(this,Yp).get(t.name);if(n===void 0)return{ok:!1,error:`unknown command '${t.name}'`};(s=c(this,Ue))==null||s.sessionStart(),await T(this,kn,E5).call(this,t),q_(Yu.HARNESS===t.by),oS((a=t.outward)==null?void 0:a.allowed);try{let f=await n(t.args);return(l=c(this,Ni))==null||l.result(Kn.PASS),{ok:!0,result:f}}catch(f){return(u=c(this,Ni))==null||u.result(Kn.FAIL),{ok:!1,error:f instanceof Error?f.message:String(f)}}finally{q_(!1),oS(void 0),g(this,Ni,void 0),(d=c(this,Ue))==null||d.scheduleIdle()}},E5=async function(t){let n=c(this,Ue);if(n===void 0)return;n.setMode(Bz(t.name)),g(this,Ni,void 0);let r=Yu.HARNESS===t.by?hn.HARNESS:hn.AGENT;if(t.name===H.ACT){let o=Zn(t.args.ref),i=Am(o);g(this,Ni,n.log(Ge.ACT,`${Md(Zn(t.args.action))} ${i}`,void 0,r)),await n.beforeAct(o,Zn(t.args.action),i)}else if(t.name===H.ACT_SEQUENCE){let o=Array.isArray(t.args.steps)?t.args.steps:[];for(let i of o){let s=i,a=Zn(s.ref),l=Am(a);g(this,Ni,n.log(Ge.ACT,`${Md(Zn(s.action))} ${l}`,void 0,r)),await n.beforeAct(a,Zn(s.action),l)}}else{let o=Gz(t.name,t.args);n.status(o),n.log(Ge.READ,o,void 0,r)}};function d5(e){return Yu.HARNESS===e.actor?hn.HARNESS:hn.AGENT}function _A(e,t){return Object.values(e).includes(t)?t:void 0}var SA=globalThis,b5,mu=(b5=SA.__reticleInstance)!=null?b5:SA.__reticleInstance=new hu;M();ot();ni();Xs();_d();Xs();function T5(e){try{return TA(e,new WeakMap)}catch{return e}}function TA(e,t){if(typeof e!="object"||e===null)return e;let n=t.get(e);if(n!==void 0)return n;if(Array.isArray(e)){let i=[];t.set(e,i);for(let s of e)i.push(TA(s,t));return i}let r=Object.getPrototypeOf(e);if(r!==Object.prototype&&r!==null)return e;let o={};t.set(e,o);for(let[i,s]of Object.entries(e))o[i]=TA(s,t);return o}function kY(e){return typeof e!="object"||e===null?String(e):JSON.stringify(e,(t,n)=>{if(typeof n!="object"||n===null||Array.isArray(n))return n;let r=Object.getPrototypeOf(n);if(r!==Object.prototype&&r!==null)return n;let o=n,i={};for(let s of Object.keys(o).sort())i[s]=o[s];return i})}function x5(e){let t={getState:()=>{var r,o,i;let n={};for(let s of e.getQueryCache().getAll()){let a=s.queryKey.map(kY).join("/");n[a]={status:s.state.status,fetchStatus:s.state.fetchStatus,isStale:(r=s.isStale)==null?void 0:r.call(s),isInvalidated:s.state.isInvalidated,dataUpdatedAt:s.state.dataUpdatedAt,error:(i=(o=s.state.error)==null?void 0:o.message)!=null?i:null,data:s.state.data}}return n},subscribe:n=>e.getQueryCache().subscribe(n)};return Hh(t,e),t}function A5(e,t){return{getState:()=>{let n={};for(let[r,o]of Object.entries(t))n[r]=e.get(o);return n},subscribe:n=>{let r=Object.values(t).map(o=>e.sub(o,n));return()=>{for(let o of r)o()}}}}function y5(e){return{getState:()=>e.getSnapshot(),subscribe:t=>{let n=e.subscribe(t);return()=>n.unsubscribe()}}}function w5(e,t,n){return{getState:()=>t(e),subscribe:r=>n(e,r)}}function v5(e,t,n){return{getState:()=>t(e),subscribe:r=>n(()=>t(e),()=>r())}}var _5={HAS_VALUE:"hasValue",LOADING:"loading",HAS_ERROR:"hasError"};function zY(e){if(e.state===_5.HAS_ERROR){let t=e.contents;return{status:e.state,value:null,error:t instanceof Error?t.message:String(t)}}return e.state!==_5.HAS_VALUE?{status:e.state,value:null,error:null}:{status:e.state,value:e.contents,error:null}}function N5(e,t,n){return{getState:()=>{let r=t(),o={};for(let[i,s]of Object.entries(e))o[i]=zY(r.getLoadable(s));return o},subscribe:n}}function S5(e){if(typeof e=="function"){e();return}e.unsubscribe()}function R5(e,t=Mr){let n=!1;return{getState:()=>{let r,o=!1;return S5(e.subscribe(i=>{r=T5(i),o=!0})),!o&&!n&&(n=!0,t("[reticle] a store passed to svelteStore did not call its subscriber synchronously, so its current value cannot be read. reticle_state will report undefined for it. Svelte stores always call back immediately; an RxJS Observable does not unless it is a BehaviorSubject.")),r},subscribe:r=>{let o=!0,i=e.subscribe(()=>{o||r()});return o=!1,()=>S5(i)}}}var DY={detached:!0,flush:"sync"};function O5(e){return{getState:()=>T5(e.$state),subscribe:t=>e.$subscribe(()=>t(),{...DY})}}function I5(e){let t=e,n=new Set;return{store:{getState:()=>t,subscribe:o=>(n.add(o),()=>n.delete(o))},push:o=>{t=o;for(let i of n)i()}}}Zi();function C5(e={}){var n;let t=(n=e.target)!=null?n:mu;return{signal(r,o={}){t.connected&&t.signal(r,o)},state(r,o){t.connected&&t.state(r,o)}}}function L5(e,t,n,r){let o=t();return e.signal(n,r),o}Zi();function $5(e){let t={};e.testids!==void 0&&(t.testids=[...e.testids]),e.signals!==void 0&&(t.signals=[...e.signals]),e.stores!==void 0&&(t.stores=[...e.stores]),Cc(t)}eS();Et();Dr();gt();NT();mT();var PY=e=>IC((t,n)=>{mu.signal(t,n)},e);return F5(MY);})();
1836
1836
  if(typeof module==="object"&&module&&module.exports)module.exports=ReticleSdk;