@canonry/canonry 6.0.0 → 6.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/assets/{AuditHistoryPanel-Bz2NVB6-.js → AuditHistoryPanel-Dtt7cbYo.js} +1 -1
- package/assets/assets/{BacklinksPage-Dte5-usf.js → BacklinksPage-h25kHk3u.js} +1 -1
- package/assets/assets/{HistoryPage-C1S4nw3I.js → HistoryPage-70YWNYBU.js} +1 -1
- package/assets/assets/{MeasurementPropertyPage-DWjsHZdt.js → MeasurementPropertyPage-CBPQ3A99.js} +1 -1
- package/assets/assets/ProjectPage-Dbbxf8yl.js +8 -0
- package/assets/assets/{RunsPage-D9wEJFfV.js → RunsPage-B6LqcDRg.js} +1 -1
- package/assets/assets/{SettingsPage-CN3Gew7Y.js → SettingsPage-DNV6Is27.js} +1 -1
- package/assets/assets/{SiteHealthSection-Bft5TfoU.js → SiteHealthSection-CWEIYXut.js} +3 -3
- package/assets/assets/{TrafficPage-tkNvySQH.js → TrafficPage-ZZqGgMyL.js} +2 -2
- package/assets/assets/{TrafficSourceDetailPage-RhRfPizo.js → TrafficSourceDetailPage-_RMyqM86.js} +1 -1
- package/assets/assets/{extract-error-message-tfl_SU7q.js → extract-error-message-D-AaTlPU.js} +1 -1
- package/assets/assets/index-BCKrocfL.js +86 -0
- package/assets/assets/index-C17E5ZcA.css +1 -0
- package/assets/assets/{react-sigma_core.esm.min-BUu3mcQJ.js → react-sigma_core.esm.min-CaRTZKvV.js} +1 -1
- package/assets/assets/{v2-overview-adapter-CzeGhaXn.js → v2-overview-adapter-C16fKgpq.js} +1 -1
- package/assets/index.html +2 -2
- package/dist/{chunk-ZO62Z2WN.js → chunk-B5W7HDCG.js} +23 -10
- package/dist/{chunk-K4356AGP.js → chunk-DMU3SFC4.js} +2 -2
- package/dist/{chunk-6M7HSNXJ.js → chunk-HTTYBQN4.js} +2 -2
- package/dist/{chunk-HAALQW4R.js → chunk-LXHE4DVO.js} +20 -2
- package/dist/{chunk-4NC5ZAC2.js → chunk-MJ3QINUW.js} +3 -3
- package/dist/{chunk-XGERCNUR.js → chunk-PDOMOHOP.js} +2 -2
- package/dist/{chunk-F4G7I7T7.js → chunk-QFI47QVP.js} +25 -10
- package/dist/cli.js +17 -9
- package/dist/{demo-server-54OUTZMY.js → demo-server-VP6CP33U.js} +4 -4
- package/dist/index.js +6 -6
- package/dist/{intelligence-service-MEIAMMLT.js → intelligence-service-6F63MYQ5.js} +2 -2
- package/dist/mcp.js +4 -4
- package/package.json +14 -14
- package/assets/assets/ProjectPage-CAJ9XvNt.js +0 -8
- package/assets/assets/index-B11OXdEC.css +0 -1
- package/assets/assets/index-Cu_xgdb1.js +0 -86
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./SiteHealthSection-CWEIYXut.js","./vendor-tanstack-ZXXkndVj.js","./vendor-lucide-N6vOpZmh.js","./ChartPrimitives-B5okB5g-.js","./vendor-recharts-llkUFBGR.js","./ProjectPage-Dbbxf8yl.js","./v2-overview-adapter-C16fKgpq.js","./vendor-markdown-B4giJcws.js","./extract-error-message-D-AaTlPU.js","./AuditHistoryPanel-Dtt7cbYo.js","./vendor-radix-twS1M3FF.js","./vendor-yaml-GWJz5H2G.js","./RunsPage-B6LqcDRg.js","./HistoryPage-70YWNYBU.js","./SettingsPage-DNV6Is27.js","./BacklinksPage-h25kHk3u.js","./TrafficPage-ZZqGgMyL.js","./TrafficSourceDetailPage-_RMyqM86.js","./MeasurementPropertyPage-CBPQ3A99.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{c as i5,d as s5,r as C,j as l,Q as o5,M as r5,q as be,e as Ec,L as We,a as l5,t as jr,u as yt,f as c5,h as ta,k as Ts,l as HS,m as u5,n as QS,O as zf,o as Ha,p as d5,s as Mt,v as FS,x as Es,y as m5,z as p5,A as h5}from"./vendor-tanstack-ZXXkndVj.js";import{S as f5,O as Ag,P as ZS,C as Cg,a as YS,T as Ng,D as XS,R as JS}from"./vendor-radix-twS1M3FF.js";import{c as WS}from"./vendor-recharts-llkUFBGR.js";import{A as wc,X as Hr,S as _g,a as ek,G as tk,C as Rc,L as Ir,R as id,M as g5,b as y5,P as If,H as nk,c as b5,d as v5,e as im,f as Tg,T as ak,W as x5,g as Eg,h as w5,i as S5,j as k5,k as j5,l as A5,m as C5,n as N5,B as _5,F as T5,o as E5,p as R5,q as D5,r as z5,s as ik,t as sk,u as Of,v as ok,w as I5,x as rk,E as O5}from"./vendor-lucide-N6vOpZmh.js";import{M as q5,r as P5}from"./vendor-markdown-B4giJcws.js";import{p as M5}from"./vendor-yaml-GWJz5H2G.js";(function(){const n=document.createElement("link").relList;if(n&&n.supports&&n.supports("modulepreload"))return;for(const u of document.querySelectorAll('link[rel="modulepreload"]'))r(u);new MutationObserver(u=>{for(const h of u)if(h.type==="childList")for(const f of h.addedNodes)f.tagName==="LINK"&&f.rel==="modulepreload"&&r(f)}).observe(document,{childList:!0,subtree:!0});function i(u){const h={};return u.integrity&&(h.integrity=u.integrity),u.referrerPolicy&&(h.referrerPolicy=u.referrerPolicy),u.crossOrigin==="use-credentials"?h.credentials="include":u.crossOrigin==="anonymous"?h.credentials="omit":h.credentials="same-origin",h}function r(u){if(u.ep)return;u.ep=!0;const h=i(u);fetch(u.href,h)}})();var Hh={exports:{}},ic={},Qh={exports:{}},Fh={};var ax;function B5(){return ax||(ax=1,(function(e){function n(q,X){var ve=q.length;q.push(X);e:for(;0<ve;){var ke=ve-1>>>1,J=q[ke];if(0<u(J,X))q[ke]=X,q[ve]=J,ve=ke;else break e}}function i(q){return q.length===0?null:q[0]}function r(q){if(q.length===0)return null;var X=q[0],ve=q.pop();if(ve!==X){q[0]=ve;e:for(var ke=0,J=q.length,Ne=J>>>1;ke<Ne;){var Me=2*(ke+1)-1,xe=q[Me],le=Me+1,re=q[le];if(0>u(xe,ve))le<J&&0>u(re,xe)?(q[ke]=re,q[le]=ve,ke=le):(q[ke]=xe,q[Me]=ve,ke=Me);else if(le<J&&0>u(re,ve))q[ke]=re,q[le]=ve,ke=le;else break e}}return X}function u(q,X){var ve=q.sortIndex-X.sortIndex;return ve!==0?ve:q.id-X.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var h=performance;e.unstable_now=function(){return h.now()}}else{var f=Date,b=f.now();e.unstable_now=function(){return f.now()-b}}var v=[],x=[],S=1,k=null,T=3,N=!1,I=!1,P=!1,E=!1,$=typeof setTimeout=="function"?setTimeout:null,ee=typeof clearTimeout=="function"?clearTimeout:null,L=typeof setImmediate<"u"?setImmediate:null;function F(q){for(var X=i(x);X!==null;){if(X.callback===null)r(x);else if(X.startTime<=q)r(x),X.sortIndex=X.expirationTime,n(v,X);else break;X=i(x)}}function Z(q){if(P=!1,F(q),!I)if(i(v)!==null)I=!0,ae||(ae=!0,Ge());else{var X=i(x);X!==null&&Ve(Z,X.startTime-q)}}var ae=!1,M=-1,Y=5,ue=-1;function Xe(){return E?!0:!(e.unstable_now()-ue<Y)}function nt(){if(E=!1,ae){var q=e.unstable_now();ue=q;var X=!0;try{e:{I=!1,P&&(P=!1,ee(M),M=-1),N=!0;var ve=T;try{t:{for(F(q),k=i(v);k!==null&&!(k.expirationTime>q&&Xe());){var ke=k.callback;if(typeof ke=="function"){k.callback=null,T=k.priorityLevel;var J=ke(k.expirationTime<=q);if(q=e.unstable_now(),typeof J=="function"){k.callback=J,F(q),X=!0;break t}k===i(v)&&r(v),F(q)}else r(v);k=i(v)}if(k!==null)X=!0;else{var Ne=i(x);Ne!==null&&Ve(Z,Ne.startTime-q),X=!1}}break e}finally{k=null,T=ve,N=!1}X=void 0}}finally{X?Ge():ae=!1}}}var Ge;if(typeof L=="function")Ge=function(){L(nt)};else if(typeof MessageChannel<"u"){var Pe=new MessageChannel,Se=Pe.port2;Pe.port1.onmessage=nt,Ge=function(){Se.postMessage(null)}}else Ge=function(){$(nt,0)};function Ve(q,X){M=$(function(){q(e.unstable_now())},X)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(q){q.callback=null},e.unstable_forceFrameRate=function(q){0>q||125<q?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Y=0<q?Math.floor(1e3/q):5},e.unstable_getCurrentPriorityLevel=function(){return T},e.unstable_next=function(q){switch(T){case 1:case 2:case 3:var X=3;break;default:X=T}var ve=T;T=X;try{return q()}finally{T=ve}},e.unstable_requestPaint=function(){E=!0},e.unstable_runWithPriority=function(q,X){switch(q){case 1:case 2:case 3:case 4:case 5:break;default:q=3}var ve=T;T=q;try{return X()}finally{T=ve}},e.unstable_scheduleCallback=function(q,X,ve){var ke=e.unstable_now();switch(typeof ve=="object"&&ve!==null?(ve=ve.delay,ve=typeof ve=="number"&&0<ve?ke+ve:ke):ve=ke,q){case 1:var J=-1;break;case 2:J=250;break;case 5:J=1073741823;break;case 4:J=1e4;break;default:J=5e3}return J=ve+J,q={id:S++,callback:X,priorityLevel:q,startTime:ve,expirationTime:J,sortIndex:-1},ve>ke?(q.sortIndex=ve,n(x,q),i(v)===null&&q===i(x)&&(P?(ee(M),M=-1):P=!0,Ve(Z,ve-ke))):(q.sortIndex=J,n(v,q),I||N||(I=!0,ae||(ae=!0,Ge()))),q},e.unstable_shouldYield=Xe,e.unstable_wrapCallback=function(q){var X=T;return function(){var ve=T;T=X;try{return q.apply(this,arguments)}finally{T=ve}}}})(Fh)),Fh}var ix;function L5(){return ix||(ix=1,Qh.exports=B5()),Qh.exports}var sx;function $5(){if(sx)return ic;sx=1;var e=L5(),n=i5(),i=s5();function r(t){var a="https://react.dev/errors/"+t;if(1<arguments.length){a+="?args[]="+encodeURIComponent(arguments[1]);for(var s=2;s<arguments.length;s++)a+="&args[]="+encodeURIComponent(arguments[s])}return"Minified React error #"+t+"; visit "+a+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function u(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function h(t){var a=t,s=t;if(t.alternate)for(;a.return;)a=a.return;else{t=a;do a=t,(a.flags&4098)!==0&&(s=a.return),t=a.return;while(t)}return a.tag===3?s:null}function f(t){if(t.tag===13){var a=t.memoizedState;if(a===null&&(t=t.alternate,t!==null&&(a=t.memoizedState)),a!==null)return a.dehydrated}return null}function b(t){if(t.tag===31){var a=t.memoizedState;if(a===null&&(t=t.alternate,t!==null&&(a=t.memoizedState)),a!==null)return a.dehydrated}return null}function v(t){if(h(t)!==t)throw Error(r(188))}function x(t){var a=t.alternate;if(!a){if(a=h(t),a===null)throw Error(r(188));return a!==t?null:t}for(var s=t,c=a;;){var p=s.return;if(p===null)break;var g=p.alternate;if(g===null){if(c=p.return,c!==null){s=c;continue}break}if(p.child===g.child){for(g=p.child;g;){if(g===s)return v(p),t;if(g===c)return v(p),a;g=g.sibling}throw Error(r(188))}if(s.return!==c.return)s=p,c=g;else{for(var w=!1,A=p.child;A;){if(A===s){w=!0,s=p,c=g;break}if(A===c){w=!0,c=p,s=g;break}A=A.sibling}if(!w){for(A=g.child;A;){if(A===s){w=!0,s=g,c=p;break}if(A===c){w=!0,c=g,s=p;break}A=A.sibling}if(!w)throw Error(r(189))}}if(s.alternate!==c)throw Error(r(190))}if(s.tag!==3)throw Error(r(188));return s.stateNode.current===s?t:a}function S(t){var a=t.tag;if(a===5||a===26||a===27||a===6)return t;for(t=t.child;t!==null;){if(a=S(t),a!==null)return a;t=t.sibling}return null}var k=Object.assign,T=Symbol.for("react.element"),N=Symbol.for("react.transitional.element"),I=Symbol.for("react.portal"),P=Symbol.for("react.fragment"),E=Symbol.for("react.strict_mode"),$=Symbol.for("react.profiler"),ee=Symbol.for("react.consumer"),L=Symbol.for("react.context"),F=Symbol.for("react.forward_ref"),Z=Symbol.for("react.suspense"),ae=Symbol.for("react.suspense_list"),M=Symbol.for("react.memo"),Y=Symbol.for("react.lazy"),ue=Symbol.for("react.activity"),Xe=Symbol.for("react.memo_cache_sentinel"),nt=Symbol.iterator;function Ge(t){return t===null||typeof t!="object"?null:(t=nt&&t[nt]||t["@@iterator"],typeof t=="function"?t:null)}var Pe=Symbol.for("react.client.reference");function Se(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===Pe?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case P:return"Fragment";case $:return"Profiler";case E:return"StrictMode";case Z:return"Suspense";case ae:return"SuspenseList";case ue:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case I:return"Portal";case L:return t.displayName||"Context";case ee:return(t._context.displayName||"Context")+".Consumer";case F:var a=t.render;return t=t.displayName,t||(t=a.displayName||a.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case M:return a=t.displayName||null,a!==null?a:Se(t.type)||"Memo";case Y:a=t._payload,t=t._init;try{return Se(t(a))}catch{}}return null}var Ve=Array.isArray,q=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,X=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ve={pending:!1,data:null,method:null,action:null},ke=[],J=-1;function Ne(t){return{current:t}}function Me(t){0>J||(t.current=ke[J],ke[J]=null,J--)}function xe(t,a){J++,ke[J]=t.current,t.current=a}var le=Ne(null),re=Ne(null),H=Ne(null),pe=Ne(null);function ze(t,a){switch(xe(H,a),xe(re,t),xe(le,null),a.nodeType){case 9:case 11:t=(t=a.documentElement)&&(t=t.namespaceURI)?Cv(t):0;break;default:if(t=a.tagName,a=a.namespaceURI)a=Cv(a),t=Nv(a,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}Me(le),xe(le,t)}function je(){Me(le),Me(re),Me(H)}function it(t){t.memoizedState!==null&&xe(pe,t);var a=le.current,s=Nv(a,t.type);a!==s&&(xe(re,t),xe(le,s))}function Ue(t){re.current===t&&(Me(le),Me(re)),pe.current===t&&(Me(pe),ec._currentValue=ve)}var jt,He;function me(t){if(jt===void 0)try{throw Error()}catch(s){var a=s.stack.trim().match(/\n( *(at )?)/);jt=a&&a[1]||"",He=-1<s.stack.indexOf(`
|
|
3
|
+
at`)?" (<anonymous>)":-1<s.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
4
|
+
`+jt+t+He}var ot=!1;function It(t,a){if(!t||ot)return"";ot=!0;var s=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var c={DetermineComponentFrameRoot:function(){try{if(a){var se=function(){throw Error()};if(Object.defineProperty(se.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(se,[])}catch(Q){var K=Q}Reflect.construct(t,[],se)}else{try{se.call()}catch(Q){K=Q}t.call(se.prototype)}}else{try{throw Error()}catch(Q){K=Q}(se=t())&&typeof se.catch=="function"&&se.catch(function(){})}}catch(Q){if(Q&&K&&typeof Q.stack=="string")return[Q.stack,K.stack]}return[null,null]}};c.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var p=Object.getOwnPropertyDescriptor(c.DetermineComponentFrameRoot,"name");p&&p.configurable&&Object.defineProperty(c.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var g=c.DetermineComponentFrameRoot(),w=g[0],A=g[1];if(w&&A){var D=w.split(`
|
|
5
|
+
`),U=A.split(`
|
|
6
|
+
`);for(p=c=0;c<D.length&&!D[c].includes("DetermineComponentFrameRoot");)c++;for(;p<U.length&&!U[p].includes("DetermineComponentFrameRoot");)p++;if(c===D.length||p===U.length)for(c=D.length-1,p=U.length-1;1<=c&&0<=p&&D[c]!==U[p];)p--;for(;1<=c&&0<=p;c--,p--)if(D[c]!==U[p]){if(c!==1||p!==1)do if(c--,p--,0>p||D[c]!==U[p]){var te=`
|
|
7
|
+
`+D[c].replace(" at new "," at ");return t.displayName&&te.includes("<anonymous>")&&(te=te.replace("<anonymous>",t.displayName)),te}while(1<=c&&0<=p);break}}}finally{ot=!1,Error.prepareStackTrace=s}return(s=t?t.displayName||t.name:"")?me(s):""}function Bn(t,a){switch(t.tag){case 26:case 27:case 5:return me(t.type);case 16:return me("Lazy");case 13:return t.child!==a&&a!==null?me("Suspense Fallback"):me("Suspense");case 19:return me("SuspenseList");case 0:case 15:return It(t.type,!1);case 11:return It(t.type.render,!1);case 1:return It(t.type,!0);case 31:return me("Activity");default:return""}}function Kt(t){try{var a="",s=null;do a+=Bn(t,s),s=t,t=t.return;while(t);return a}catch(c){return`
|
|
8
|
+
Error generating stack: `+c.message+`
|
|
9
|
+
`+c.stack}}var Be=Object.prototype.hasOwnProperty,ct=e.unstable_scheduleCallback,Ht=e.unstable_cancelCallback,Qt=e.unstable_shouldYield,zn=e.unstable_requestPaint,$t=e.unstable_now,mi=e.unstable_getCurrentPriorityLevel,Bs=e.unstable_ImmediatePriority,Hn=e.unstable_UserBlockingPriority,pi=e.unstable_NormalPriority,Ls=e.unstable_LowPriority,Ki=e.unstable_IdlePriority,Hi=e.log,$s=e.unstable_setDisableYieldValue,yn=null,At=null;function bn(t){if(typeof Hi=="function"&&$s(t),At&&typeof At.setStrictMode=="function")try{At.setStrictMode(yn,t)}catch{}}var An=Math.clz32?Math.clz32:oe,Vs=Math.log,ya=Math.LN2;function oe(t){return t>>>=0,t===0?32:31-(Vs(t)/ya|0)|0}var Ie=256,Ye=262144,Ft=4194304;function st(t){var a=t&42;if(a!==0)return a;switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function et(t,a,s){var c=t.pendingLanes;if(c===0)return 0;var p=0,g=t.suspendedLanes,w=t.pingedLanes;t=t.warmLanes;var A=c&134217727;return A!==0?(c=A&~g,c!==0?p=st(c):(w&=A,w!==0?p=st(w):s||(s=A&~t,s!==0&&(p=st(s))))):(A=c&~g,A!==0?p=st(A):w!==0?p=st(w):s||(s=c&~t,s!==0&&(p=st(s)))),p===0?0:a!==0&&a!==p&&(a&g)===0&&(g=p&-p,s=a&-a,g>=s||g===32&&(s&4194048)!==0)?a:p}function Wt(t,a){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&a)===0}function Xa(t,a){switch(t){case 1:case 2:case 4:case 8:case 64:return a+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return a+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Us(){var t=Ft;return Ft<<=1,(Ft&62914560)===0&&(Ft=4194304),t}function Bo(t){for(var a=[],s=0;31>s;s++)a.push(t);return a}function Gs(t,a){t.pendingLanes|=a,a!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function Fc(t,a,s,c,p,g){var w=t.pendingLanes;t.pendingLanes=s,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=s,t.entangledLanes&=s,t.errorRecoveryDisabledLanes&=s,t.shellSuspendCounter=0;var A=t.entanglements,D=t.expirationTimes,U=t.hiddenUpdates;for(s=w&~s;0<s;){var te=31-An(s),se=1<<te;A[te]=0,D[te]=-1;var K=U[te];if(K!==null)for(U[te]=null,te=0;te<K.length;te++){var Q=K[te];Q!==null&&(Q.lane&=-536870913)}s&=~se}c!==0&&il(t,c,0),g!==0&&p===0&&t.tag!==0&&(t.suspendedLanes|=g&~(w&~a))}function il(t,a,s){t.pendingLanes|=a,t.suspendedLanes&=~a;var c=31-An(a);t.entangledLanes|=a,t.entanglements[c]=t.entanglements[c]|1073741824|s&261930}function sl(t,a){var s=t.entangledLanes|=a;for(t=t.entanglements;s;){var c=31-An(s),p=1<<c;p&a|t[c]&a&&(t[c]|=a),s&=~p}}function ol(t,a){var s=a&-a;return s=(s&42)!==0?1:rl(s),(s&(t.suspendedLanes|a))!==0?0:s}function rl(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function ll(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function Lo(){var t=X.p;return t!==0?t:(t=window.event,t===void 0?32:Yv(t.type))}function Zc(t,a){var s=X.p;try{return X.p=t,a()}finally{X.p=s}}var ba=Math.random().toString(36).slice(2),on="__reactFiber$"+ba,In="__reactProps$"+ba,Qi="__reactContainer$"+ba,$o="__reactEvents$"+ba,Yc="__reactListeners$"+ba,Vo="__reactHandles$"+ba,aa="__reactResources$"+ba,Fi="__reactMarker$"+ba;function cl(t){delete t[on],delete t[In],delete t[$o],delete t[Yc],delete t[Vo]}function hi(t){var a=t[on];if(a)return a;for(var s=t.parentNode;s;){if(a=s[Qi]||s[on]){if(s=a.alternate,a.child!==null||s!==null&&s.child!==null)for(t=Iv(t);t!==null;){if(s=t[on])return s;t=Iv(t)}return a}t=s,s=t.parentNode}return null}function Zi(t){if(t=t[on]||t[Qi]){var a=t.tag;if(a===5||a===6||a===13||a===31||a===26||a===27||a===3)return t}return null}function Yi(t){var a=t.tag;if(a===5||a===26||a===27||a===6)return t.stateNode;throw Error(r(33))}function Xi(t){var a=t[aa];return a||(a=t[aa]={hoistableStyles:new Map,hoistableScripts:new Map}),a}function en(t){t[Fi]=!0}var ul=new Set,dl={};function Ja(t,a){Ks(t,a),Ks(t+"Capture",a)}function Ks(t,a){for(dl[t]=a,t=0;t<a.length;t++)ul.add(a[t])}var ml=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),pl={},Wa={};function Km(t){return Be.call(Wa,t)?!0:Be.call(pl,t)?!1:ml.test(t)?Wa[t]=!0:(pl[t]=!0,!1)}function fi(t,a,s){if(Km(a))if(s===null)t.removeAttribute(a);else{switch(typeof s){case"undefined":case"function":case"symbol":t.removeAttribute(a);return;case"boolean":var c=a.toLowerCase().slice(0,5);if(c!=="data-"&&c!=="aria-"){t.removeAttribute(a);return}}t.setAttribute(a,""+s)}}function Hs(t,a,s){if(s===null)t.removeAttribute(a);else{switch(typeof s){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(a);return}t.setAttribute(a,""+s)}}function Cn(t,a,s,c){if(c===null)t.removeAttribute(s);else{switch(typeof c){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(s);return}t.setAttributeNS(a,s,""+c)}}function On(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function Ji(t){var a=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(a==="checkbox"||a==="radio")}function Hm(t,a,s){var c=Object.getOwnPropertyDescriptor(t.constructor.prototype,a);if(!t.hasOwnProperty(a)&&typeof c<"u"&&typeof c.get=="function"&&typeof c.set=="function"){var p=c.get,g=c.set;return Object.defineProperty(t,a,{configurable:!0,get:function(){return p.call(this)},set:function(w){s=""+w,g.call(this,w)}}),Object.defineProperty(t,a,{enumerable:c.enumerable}),{getValue:function(){return s},setValue:function(w){s=""+w},stopTracking:function(){t._valueTracker=null,delete t[a]}}}}function hl(t){if(!t._valueTracker){var a=Ji(t)?"checked":"value";t._valueTracker=Hm(t,a,""+t[a])}}function ei(t){if(!t)return!1;var a=t._valueTracker;if(!a)return!0;var s=a.getValue(),c="";return t&&(c=Ji(t)?t.checked?"true":"false":t.value),t=c,t!==s?(a.setValue(t),!0):!1}function Wi(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var Xc=/[\n"\\]/g;function qn(t){return t.replace(Xc,function(a){return"\\"+a.charCodeAt(0).toString(16)+" "})}function Uo(t,a,s,c,p,g,w,A){t.name="",w!=null&&typeof w!="function"&&typeof w!="symbol"&&typeof w!="boolean"?t.type=w:t.removeAttribute("type"),a!=null?w==="number"?(a===0&&t.value===""||t.value!=a)&&(t.value=""+On(a)):t.value!==""+On(a)&&(t.value=""+On(a)):w!=="submit"&&w!=="reset"||t.removeAttribute("value"),a!=null?Go(t,w,On(a)):s!=null?Go(t,w,On(s)):c!=null&&t.removeAttribute("value"),p==null&&g!=null&&(t.defaultChecked=!!g),p!=null&&(t.checked=p&&typeof p!="function"&&typeof p!="symbol"),A!=null&&typeof A!="function"&&typeof A!="symbol"&&typeof A!="boolean"?t.name=""+On(A):t.removeAttribute("name")}function fl(t,a,s,c,p,g,w,A){if(g!=null&&typeof g!="function"&&typeof g!="symbol"&&typeof g!="boolean"&&(t.type=g),a!=null||s!=null){if(!(g!=="submit"&&g!=="reset"||a!=null)){hl(t);return}s=s!=null?""+On(s):"",a=a!=null?""+On(a):s,A||a===t.value||(t.value=a),t.defaultValue=a}c=c??p,c=typeof c!="function"&&typeof c!="symbol"&&!!c,t.checked=A?t.checked:!!c,t.defaultChecked=!!c,w!=null&&typeof w!="function"&&typeof w!="symbol"&&typeof w!="boolean"&&(t.name=w),hl(t)}function Go(t,a,s){a==="number"&&Wi(t.ownerDocument)===t||t.defaultValue===""+s||(t.defaultValue=""+s)}function Qn(t,a,s,c){if(t=t.options,a){a={};for(var p=0;p<s.length;p++)a["$"+s[p]]=!0;for(s=0;s<t.length;s++)p=a.hasOwnProperty("$"+t[s].value),t[s].selected!==p&&(t[s].selected=p),p&&c&&(t[s].defaultSelected=!0)}else{for(s=""+On(s),a=null,p=0;p<t.length;p++){if(t[p].value===s){t[p].selected=!0,c&&(t[p].defaultSelected=!0);return}a!==null||t[p].disabled||(a=t[p])}a!==null&&(a.selected=!0)}}function ia(t,a,s){if(a!=null&&(a=""+On(a),a!==t.value&&(t.value=a),s==null)){t.defaultValue!==a&&(t.defaultValue=a);return}t.defaultValue=s!=null?""+On(s):""}function gi(t,a,s,c){if(a==null){if(c!=null){if(s!=null)throw Error(r(92));if(Ve(c)){if(1<c.length)throw Error(r(93));c=c[0]}s=c}s==null&&(s=""),a=s}s=On(a),t.defaultValue=s,c=t.textContent,c===s&&c!==""&&c!==null&&(t.value=c),hl(t)}function va(t,a){if(a){var s=t.firstChild;if(s&&s===t.lastChild&&s.nodeType===3){s.nodeValue=a;return}}t.textContent=a}var xa=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Qm(t,a,s){var c=a.indexOf("--")===0;s==null||typeof s=="boolean"||s===""?c?t.setProperty(a,""):a==="float"?t.cssFloat="":t[a]="":c?t.setProperty(a,s):typeof s!="number"||s===0||xa.has(a)?a==="float"?t.cssFloat=s:t[a]=(""+s).trim():t[a]=s+"px"}function ti(t,a,s){if(a!=null&&typeof a!="object")throw Error(r(62));if(t=t.style,s!=null){for(var c in s)!s.hasOwnProperty(c)||a!=null&&a.hasOwnProperty(c)||(c.indexOf("--")===0?t.setProperty(c,""):c==="float"?t.cssFloat="":t[c]="");for(var p in a)c=a[p],a.hasOwnProperty(p)&&s[p]!==c&&Qm(t,p,c)}else for(var g in a)a.hasOwnProperty(g)&&Qm(t,g,a[g])}function Ma(t){if(t.indexOf("-")===-1)return!1;switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Ko=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Fm=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Ho(t){return Fm.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function Ba(){}var gl=null;function yl(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var yi=null,Ln=null;function Qo(t){var a=Zi(t);if(a&&(t=a.stateNode)){var s=t[In]||null;e:switch(t=a.stateNode,a.type){case"input":if(Uo(t,s.value,s.defaultValue,s.defaultValue,s.checked,s.defaultChecked,s.type,s.name),a=s.name,s.type==="radio"&&a!=null){for(s=t;s.parentNode;)s=s.parentNode;for(s=s.querySelectorAll('input[name="'+qn(""+a)+'"][type="radio"]'),a=0;a<s.length;a++){var c=s[a];if(c!==t&&c.form===t.form){var p=c[In]||null;if(!p)throw Error(r(90));Uo(c,p.value,p.defaultValue,p.defaultValue,p.checked,p.defaultChecked,p.type,p.name)}}for(a=0;a<s.length;a++)c=s[a],c.form===t.form&&ei(c)}break e;case"textarea":ia(t,s.value,s.defaultValue);break e;case"select":a=s.value,a!=null&&Qn(t,!!s.multiple,a,!1)}}}var bl=!1;function Jc(t,a,s){if(bl)return t(a,s);bl=!0;try{var c=t(a);return c}finally{if(bl=!1,(yi!==null||Ln!==null)&&(qu(),yi&&(a=yi,t=Ln,Ln=yi=null,Qo(a),t)))for(a=0;a<t.length;a++)Qo(t[a])}}function Qs(t,a){var s=t.stateNode;if(s===null)return null;var c=s[In]||null;if(c===null)return null;s=c[a];e:switch(a){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(c=!c.disabled)||(t=t.type,c=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!c;break e;default:t=!1}if(t)return null;if(s&&typeof s!="function")throw Error(r(231,a,typeof s));return s}var wa=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),vl=!1;if(wa)try{var Fs={};Object.defineProperty(Fs,"passive",{get:function(){vl=!0}}),window.addEventListener("test",Fs,Fs),window.removeEventListener("test",Fs,Fs)}catch{vl=!1}var ni=null,G=null,Fe=null;function bi(){if(Fe)return Fe;var t,a=G,s=a.length,c,p="value"in ni?ni.value:ni.textContent,g=p.length;for(t=0;t<s&&a[t]===p[t];t++);var w=s-t;for(c=1;c<=w&&a[s-c]===p[g-c];c++);return Fe=p.slice(t,1<c?1-c:void 0)}function La(t){var a=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&a===13&&(t=13)):t=a,t===10&&(t=13),32<=t||t===13?t:0}function Fo(){return!0}function Wc(){return!1}function Nn(t){function a(s,c,p,g,w){this._reactName=s,this._targetInst=p,this.type=c,this.nativeEvent=g,this.target=w,this.currentTarget=null;for(var A in t)t.hasOwnProperty(A)&&(s=t[A],this[A]=s?s(g):g[A]);return this.isDefaultPrevented=(g.defaultPrevented!=null?g.defaultPrevented:g.returnValue===!1)?Fo:Wc,this.isPropagationStopped=Wc,this}return k(a.prototype,{preventDefault:function(){this.defaultPrevented=!0;var s=this.nativeEvent;s&&(s.preventDefault?s.preventDefault():typeof s.returnValue!="unknown"&&(s.returnValue=!1),this.isDefaultPrevented=Fo)},stopPropagation:function(){var s=this.nativeEvent;s&&(s.stopPropagation?s.stopPropagation():typeof s.cancelBubble!="unknown"&&(s.cancelBubble=!0),this.isPropagationStopped=Fo)},persist:function(){},isPersistent:Fo}),a}var ai={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Zs=Nn(ai),Ys=k({},ai,{view:0,detail:0}),Xs=Nn(Ys),$a,Zm,xl,eu=k({},Ys,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Xm,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==xl&&(xl&&t.type==="mousemove"?($a=t.screenX-xl.screenX,Zm=t.screenY-xl.screenY):Zm=$a=0,xl=t),$a)},movementY:function(t){return"movementY"in t?t.movementY:Zm}}),T1=Nn(eu),a4=k({},eu,{dataTransfer:0}),i4=Nn(a4),s4=k({},Ys,{relatedTarget:0}),Ym=Nn(s4),o4=k({},ai,{animationName:0,elapsedTime:0,pseudoElement:0}),r4=Nn(o4),l4=k({},ai,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),c4=Nn(l4),u4=k({},ai,{data:0}),E1=Nn(u4),d4={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},m4={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},p4={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function h4(t){var a=this.nativeEvent;return a.getModifierState?a.getModifierState(t):(t=p4[t])?!!a[t]:!1}function Xm(){return h4}var f4=k({},Ys,{key:function(t){if(t.key){var a=d4[t.key]||t.key;if(a!=="Unidentified")return a}return t.type==="keypress"?(t=La(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?m4[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Xm,charCode:function(t){return t.type==="keypress"?La(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?La(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),g4=Nn(f4),y4=k({},eu,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),R1=Nn(y4),b4=k({},Ys,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Xm}),v4=Nn(b4),x4=k({},ai,{propertyName:0,elapsedTime:0,pseudoElement:0}),w4=Nn(x4),S4=k({},eu,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),k4=Nn(S4),j4=k({},ai,{newState:0,oldState:0}),A4=Nn(j4),C4=[9,13,27,32],Jm=wa&&"CompositionEvent"in window,wl=null;wa&&"documentMode"in document&&(wl=document.documentMode);var N4=wa&&"TextEvent"in window&&!wl,D1=wa&&(!Jm||wl&&8<wl&&11>=wl),z1=" ",I1=!1;function O1(t,a){switch(t){case"keyup":return C4.indexOf(a.keyCode)!==-1;case"keydown":return a.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function q1(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Zo=!1;function _4(t,a){switch(t){case"compositionend":return q1(a);case"keypress":return a.which!==32?null:(I1=!0,z1);case"textInput":return t=a.data,t===z1&&I1?null:t;default:return null}}function T4(t,a){if(Zo)return t==="compositionend"||!Jm&&O1(t,a)?(t=bi(),Fe=G=ni=null,Zo=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(a.ctrlKey||a.altKey||a.metaKey)||a.ctrlKey&&a.altKey){if(a.char&&1<a.char.length)return a.char;if(a.which)return String.fromCharCode(a.which)}return null;case"compositionend":return D1&&a.locale!=="ko"?null:a.data;default:return null}}var E4={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function P1(t){var a=t&&t.nodeName&&t.nodeName.toLowerCase();return a==="input"?!!E4[t.type]:a==="textarea"}function M1(t,a,s,c){yi?Ln?Ln.push(c):Ln=[c]:yi=c,a=Uu(a,"onChange"),0<a.length&&(s=new Zs("onChange","change",null,s,c),t.push({event:s,listeners:a}))}var Sl=null,kl=null;function R4(t){xv(t,0)}function tu(t){var a=Yi(t);if(ei(a))return t}function B1(t,a){if(t==="change")return a}var L1=!1;if(wa){var Wm;if(wa){var ep="oninput"in document;if(!ep){var $1=document.createElement("div");$1.setAttribute("oninput","return;"),ep=typeof $1.oninput=="function"}Wm=ep}else Wm=!1;L1=Wm&&(!document.documentMode||9<document.documentMode)}function V1(){Sl&&(Sl.detachEvent("onpropertychange",U1),kl=Sl=null)}function U1(t){if(t.propertyName==="value"&&tu(kl)){var a=[];M1(a,kl,t,yl(t)),Jc(R4,a)}}function D4(t,a,s){t==="focusin"?(V1(),Sl=a,kl=s,Sl.attachEvent("onpropertychange",U1)):t==="focusout"&&V1()}function z4(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return tu(kl)}function I4(t,a){if(t==="click")return tu(a)}function O4(t,a){if(t==="input"||t==="change")return tu(a)}function q4(t,a){return t===a&&(t!==0||1/t===1/a)||t!==t&&a!==a}var sa=typeof Object.is=="function"?Object.is:q4;function jl(t,a){if(sa(t,a))return!0;if(typeof t!="object"||t===null||typeof a!="object"||a===null)return!1;var s=Object.keys(t),c=Object.keys(a);if(s.length!==c.length)return!1;for(c=0;c<s.length;c++){var p=s[c];if(!Be.call(a,p)||!sa(t[p],a[p]))return!1}return!0}function G1(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function K1(t,a){var s=G1(t);t=0;for(var c;s;){if(s.nodeType===3){if(c=t+s.textContent.length,t<=a&&c>=a)return{node:s,offset:a-t};t=c}e:{for(;s;){if(s.nextSibling){s=s.nextSibling;break e}s=s.parentNode}s=void 0}s=G1(s)}}function H1(t,a){return t&&a?t===a?!0:t&&t.nodeType===3?!1:a&&a.nodeType===3?H1(t,a.parentNode):"contains"in t?t.contains(a):t.compareDocumentPosition?!!(t.compareDocumentPosition(a)&16):!1:!1}function Q1(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var a=Wi(t.document);a instanceof t.HTMLIFrameElement;){try{var s=typeof a.contentWindow.location.href=="string"}catch{s=!1}if(s)t=a.contentWindow;else break;a=Wi(t.document)}return a}function tp(t){var a=t&&t.nodeName&&t.nodeName.toLowerCase();return a&&(a==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||a==="textarea"||t.contentEditable==="true")}var P4=wa&&"documentMode"in document&&11>=document.documentMode,Yo=null,np=null,Al=null,ap=!1;function F1(t,a,s){var c=s.window===s?s.document:s.nodeType===9?s:s.ownerDocument;ap||Yo==null||Yo!==Wi(c)||(c=Yo,"selectionStart"in c&&tp(c)?c={start:c.selectionStart,end:c.selectionEnd}:(c=(c.ownerDocument&&c.ownerDocument.defaultView||window).getSelection(),c={anchorNode:c.anchorNode,anchorOffset:c.anchorOffset,focusNode:c.focusNode,focusOffset:c.focusOffset}),Al&&jl(Al,c)||(Al=c,c=Uu(np,"onSelect"),0<c.length&&(a=new Zs("onSelect","select",null,a,s),t.push({event:a,listeners:c}),a.target=Yo)))}function Js(t,a){var s={};return s[t.toLowerCase()]=a.toLowerCase(),s["Webkit"+t]="webkit"+a,s["Moz"+t]="moz"+a,s}var Xo={animationend:Js("Animation","AnimationEnd"),animationiteration:Js("Animation","AnimationIteration"),animationstart:Js("Animation","AnimationStart"),transitionrun:Js("Transition","TransitionRun"),transitionstart:Js("Transition","TransitionStart"),transitioncancel:Js("Transition","TransitionCancel"),transitionend:Js("Transition","TransitionEnd")},ip={},Z1={};wa&&(Z1=document.createElement("div").style,"AnimationEvent"in window||(delete Xo.animationend.animation,delete Xo.animationiteration.animation,delete Xo.animationstart.animation),"TransitionEvent"in window||delete Xo.transitionend.transition);function Ws(t){if(ip[t])return ip[t];if(!Xo[t])return t;var a=Xo[t],s;for(s in a)if(a.hasOwnProperty(s)&&s in Z1)return ip[t]=a[s];return t}var Y1=Ws("animationend"),X1=Ws("animationiteration"),J1=Ws("animationstart"),M4=Ws("transitionrun"),B4=Ws("transitionstart"),L4=Ws("transitioncancel"),W1=Ws("transitionend"),ey=new Map,sp="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");sp.push("scrollEnd");function Va(t,a){ey.set(t,a),Ja(a,[t])}var nu=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var a=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(a))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},Sa=[],Jo=0,op=0;function au(){for(var t=Jo,a=op=Jo=0;a<t;){var s=Sa[a];Sa[a++]=null;var c=Sa[a];Sa[a++]=null;var p=Sa[a];Sa[a++]=null;var g=Sa[a];if(Sa[a++]=null,c!==null&&p!==null){var w=c.pending;w===null?p.next=p:(p.next=w.next,w.next=p),c.pending=p}g!==0&&ty(s,p,g)}}function iu(t,a,s,c){Sa[Jo++]=t,Sa[Jo++]=a,Sa[Jo++]=s,Sa[Jo++]=c,op|=c,t.lanes|=c,t=t.alternate,t!==null&&(t.lanes|=c)}function rp(t,a,s,c){return iu(t,a,s,c),su(t)}function eo(t,a){return iu(t,null,null,a),su(t)}function ty(t,a,s){t.lanes|=s;var c=t.alternate;c!==null&&(c.lanes|=s);for(var p=!1,g=t.return;g!==null;)g.childLanes|=s,c=g.alternate,c!==null&&(c.childLanes|=s),g.tag===22&&(t=g.stateNode,t===null||t._visibility&1||(p=!0)),t=g,g=g.return;return t.tag===3?(g=t.stateNode,p&&a!==null&&(p=31-An(s),t=g.hiddenUpdates,c=t[p],c===null?t[p]=[a]:c.push(a),a.lane=s|536870912),g):null}function su(t){if(50<Ql)throw Ql=0,gh=null,Error(r(185));for(var a=t.return;a!==null;)t=a,a=t.return;return t.tag===3?t.stateNode:null}var Wo={};function $4(t,a,s,c){this.tag=t,this.key=s,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=c,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function oa(t,a,s,c){return new $4(t,a,s,c)}function lp(t){return t=t.prototype,!(!t||!t.isReactComponent)}function vi(t,a){var s=t.alternate;return s===null?(s=oa(t.tag,a,t.key,t.mode),s.elementType=t.elementType,s.type=t.type,s.stateNode=t.stateNode,s.alternate=t,t.alternate=s):(s.pendingProps=a,s.type=t.type,s.flags=0,s.subtreeFlags=0,s.deletions=null),s.flags=t.flags&65011712,s.childLanes=t.childLanes,s.lanes=t.lanes,s.child=t.child,s.memoizedProps=t.memoizedProps,s.memoizedState=t.memoizedState,s.updateQueue=t.updateQueue,a=t.dependencies,s.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},s.sibling=t.sibling,s.index=t.index,s.ref=t.ref,s.refCleanup=t.refCleanup,s}function ny(t,a){t.flags&=65011714;var s=t.alternate;return s===null?(t.childLanes=0,t.lanes=a,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=s.childLanes,t.lanes=s.lanes,t.child=s.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=s.memoizedProps,t.memoizedState=s.memoizedState,t.updateQueue=s.updateQueue,t.type=s.type,a=s.dependencies,t.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext}),t}function ou(t,a,s,c,p,g){var w=0;if(c=t,typeof t=="function")lp(t)&&(w=1);else if(typeof t=="string")w=HN(t,s,le.current)?26:t==="html"||t==="head"||t==="body"?27:5;else e:switch(t){case ue:return t=oa(31,s,a,p),t.elementType=ue,t.lanes=g,t;case P:return to(s.children,p,g,a);case E:w=8,p|=24;break;case $:return t=oa(12,s,a,p|2),t.elementType=$,t.lanes=g,t;case Z:return t=oa(13,s,a,p),t.elementType=Z,t.lanes=g,t;case ae:return t=oa(19,s,a,p),t.elementType=ae,t.lanes=g,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case L:w=10;break e;case ee:w=9;break e;case F:w=11;break e;case M:w=14;break e;case Y:w=16,c=null;break e}w=29,s=Error(r(130,t===null?"null":typeof t,"")),c=null}return a=oa(w,s,a,p),a.elementType=t,a.type=c,a.lanes=g,a}function to(t,a,s,c){return t=oa(7,t,c,a),t.lanes=s,t}function cp(t,a,s){return t=oa(6,t,null,a),t.lanes=s,t}function ay(t){var a=oa(18,null,null,0);return a.stateNode=t,a}function up(t,a,s){return a=oa(4,t.children!==null?t.children:[],t.key,a),a.lanes=s,a.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},a}var iy=new WeakMap;function ka(t,a){if(typeof t=="object"&&t!==null){var s=iy.get(t);return s!==void 0?s:(a={value:t,source:a,stack:Kt(a)},iy.set(t,a),a)}return{value:t,source:a,stack:Kt(a)}}var er=[],tr=0,ru=null,Cl=0,ja=[],Aa=0,es=null,ii=1,si="";function xi(t,a){er[tr++]=Cl,er[tr++]=ru,ru=t,Cl=a}function sy(t,a,s){ja[Aa++]=ii,ja[Aa++]=si,ja[Aa++]=es,es=t;var c=ii;t=si;var p=32-An(c)-1;c&=~(1<<p),s+=1;var g=32-An(a)+p;if(30<g){var w=p-p%5;g=(c&(1<<w)-1).toString(32),c>>=w,p-=w,ii=1<<32-An(a)+p|s<<p|c,si=g+t}else ii=1<<g|s<<p|c,si=t}function dp(t){t.return!==null&&(xi(t,1),sy(t,1,0))}function mp(t){for(;t===ru;)ru=er[--tr],er[tr]=null,Cl=er[--tr],er[tr]=null;for(;t===es;)es=ja[--Aa],ja[Aa]=null,si=ja[--Aa],ja[Aa]=null,ii=ja[--Aa],ja[Aa]=null}function oy(t,a){ja[Aa++]=ii,ja[Aa++]=si,ja[Aa++]=es,ii=a.id,si=a.overflow,es=t}var _n=null,qt=null,ht=!1,ts=null,Ca=!1,pp=Error(r(519));function ns(t){var a=Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Nl(ka(a,t)),pp}function ry(t){var a=t.stateNode,s=t.type,c=t.memoizedProps;switch(a[on]=t,a[In]=c,s){case"dialog":lt("cancel",a),lt("close",a);break;case"iframe":case"object":case"embed":lt("load",a);break;case"video":case"audio":for(s=0;s<Zl.length;s++)lt(Zl[s],a);break;case"source":lt("error",a);break;case"img":case"image":case"link":lt("error",a),lt("load",a);break;case"details":lt("toggle",a);break;case"input":lt("invalid",a),fl(a,c.value,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name,!0);break;case"select":lt("invalid",a);break;case"textarea":lt("invalid",a),gi(a,c.value,c.defaultValue,c.children)}s=c.children,typeof s!="string"&&typeof s!="number"&&typeof s!="bigint"||a.textContent===""+s||c.suppressHydrationWarning===!0||jv(a.textContent,s)?(c.popover!=null&&(lt("beforetoggle",a),lt("toggle",a)),c.onScroll!=null&<("scroll",a),c.onScrollEnd!=null&<("scrollend",a),c.onClick!=null&&(a.onclick=Ba),a=!0):a=!1,a||ns(t,!0)}function ly(t){for(_n=t.return;_n;)switch(_n.tag){case 5:case 31:case 13:Ca=!1;return;case 27:case 3:Ca=!0;return;default:_n=_n.return}}function nr(t){if(t!==_n)return!1;if(!ht)return ly(t),ht=!0,!1;var a=t.tag,s;if((s=a!==3&&a!==27)&&((s=a===5)&&(s=t.type,s=!(s!=="form"&&s!=="button")||Rh(t.type,t.memoizedProps)),s=!s),s&&qt&&ns(t),ly(t),a===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(r(317));qt=zv(t)}else if(a===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(r(317));qt=zv(t)}else a===27?(a=qt,gs(t.type)?(t=qh,qh=null,qt=t):qt=a):qt=_n?_a(t.stateNode.nextSibling):null;return!0}function no(){qt=_n=null,ht=!1}function hp(){var t=ts;return t!==null&&(Xn===null?Xn=t:Xn.push.apply(Xn,t),ts=null),t}function Nl(t){ts===null?ts=[t]:ts.push(t)}var fp=Ne(null),ao=null,wi=null;function as(t,a,s){xe(fp,a._currentValue),a._currentValue=s}function Si(t){t._currentValue=fp.current,Me(fp)}function gp(t,a,s){for(;t!==null;){var c=t.alternate;if((t.childLanes&a)!==a?(t.childLanes|=a,c!==null&&(c.childLanes|=a)):c!==null&&(c.childLanes&a)!==a&&(c.childLanes|=a),t===s)break;t=t.return}}function yp(t,a,s,c){var p=t.child;for(p!==null&&(p.return=t);p!==null;){var g=p.dependencies;if(g!==null){var w=p.child;g=g.firstContext;e:for(;g!==null;){var A=g;g=p;for(var D=0;D<a.length;D++)if(A.context===a[D]){g.lanes|=s,A=g.alternate,A!==null&&(A.lanes|=s),gp(g.return,s,t),c||(w=null);break e}g=A.next}}else if(p.tag===18){if(w=p.return,w===null)throw Error(r(341));w.lanes|=s,g=w.alternate,g!==null&&(g.lanes|=s),gp(w,s,t),w=null}else w=p.child;if(w!==null)w.return=p;else for(w=p;w!==null;){if(w===t){w=null;break}if(p=w.sibling,p!==null){p.return=w.return,w=p;break}w=w.return}p=w}}function ar(t,a,s,c){t=null;for(var p=a,g=!1;p!==null;){if(!g){if((p.flags&524288)!==0)g=!0;else if((p.flags&262144)!==0)break}if(p.tag===10){var w=p.alternate;if(w===null)throw Error(r(387));if(w=w.memoizedProps,w!==null){var A=p.type;sa(p.pendingProps.value,w.value)||(t!==null?t.push(A):t=[A])}}else if(p===pe.current){if(w=p.alternate,w===null)throw Error(r(387));w.memoizedState.memoizedState!==p.memoizedState.memoizedState&&(t!==null?t.push(ec):t=[ec])}p=p.return}t!==null&&yp(a,t,s,c),a.flags|=262144}function lu(t){for(t=t.firstContext;t!==null;){if(!sa(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function io(t){ao=t,wi=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function Tn(t){return cy(ao,t)}function cu(t,a){return ao===null&&io(t),cy(t,a)}function cy(t,a){var s=a._currentValue;if(a={context:a,memoizedValue:s,next:null},wi===null){if(t===null)throw Error(r(308));wi=a,t.dependencies={lanes:0,firstContext:a},t.flags|=524288}else wi=wi.next=a;return s}var V4=typeof AbortController<"u"?AbortController:function(){var t=[],a=this.signal={aborted:!1,addEventListener:function(s,c){t.push(c)}};this.abort=function(){a.aborted=!0,t.forEach(function(s){return s()})}},U4=e.unstable_scheduleCallback,G4=e.unstable_NormalPriority,rn={$$typeof:L,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function bp(){return{controller:new V4,data:new Map,refCount:0}}function _l(t){t.refCount--,t.refCount===0&&U4(G4,function(){t.controller.abort()})}var Tl=null,vp=0,ir=0,sr=null;function K4(t,a){if(Tl===null){var s=Tl=[];vp=0,ir=Sh(),sr={status:"pending",value:void 0,then:function(c){s.push(c)}}}return vp++,a.then(uy,uy),a}function uy(){if(--vp===0&&Tl!==null){sr!==null&&(sr.status="fulfilled");var t=Tl;Tl=null,ir=0,sr=null;for(var a=0;a<t.length;a++)(0,t[a])()}}function H4(t,a){var s=[],c={status:"pending",value:null,reason:null,then:function(p){s.push(p)}};return t.then(function(){c.status="fulfilled",c.value=a;for(var p=0;p<s.length;p++)(0,s[p])(a)},function(p){for(c.status="rejected",c.reason=p,p=0;p<s.length;p++)(0,s[p])(void 0)}),c}var dy=q.S;q.S=function(t,a){Fb=$t(),typeof a=="object"&&a!==null&&typeof a.then=="function"&&K4(t,a),dy!==null&&dy(t,a)};var so=Ne(null);function xp(){var t=so.current;return t!==null?t:Dt.pooledCache}function uu(t,a){a===null?xe(so,so.current):xe(so,a.pool)}function my(){var t=xp();return t===null?null:{parent:rn._currentValue,pool:t}}var or=Error(r(460)),wp=Error(r(474)),du=Error(r(542)),mu={then:function(){}};function py(t){return t=t.status,t==="fulfilled"||t==="rejected"}function hy(t,a,s){switch(s=t[s],s===void 0?t.push(a):s!==a&&(a.then(Ba,Ba),a=s),a.status){case"fulfilled":return a.value;case"rejected":throw t=a.reason,gy(t),t;default:if(typeof a.status=="string")a.then(Ba,Ba);else{if(t=Dt,t!==null&&100<t.shellSuspendCounter)throw Error(r(482));t=a,t.status="pending",t.then(function(c){if(a.status==="pending"){var p=a;p.status="fulfilled",p.value=c}},function(c){if(a.status==="pending"){var p=a;p.status="rejected",p.reason=c}})}switch(a.status){case"fulfilled":return a.value;case"rejected":throw t=a.reason,gy(t),t}throw ro=a,or}}function oo(t){try{var a=t._init;return a(t._payload)}catch(s){throw s!==null&&typeof s=="object"&&typeof s.then=="function"?(ro=s,or):s}}var ro=null;function fy(){if(ro===null)throw Error(r(459));var t=ro;return ro=null,t}function gy(t){if(t===or||t===du)throw Error(r(483))}var rr=null,El=0;function pu(t){var a=El;return El+=1,rr===null&&(rr=[]),hy(rr,t,a)}function Rl(t,a){a=a.props.ref,t.ref=a!==void 0?a:null}function hu(t,a){throw a.$$typeof===T?Error(r(525)):(t=Object.prototype.toString.call(a),Error(r(31,t==="[object Object]"?"object with keys {"+Object.keys(a).join(", ")+"}":t)))}function yy(t){function a(B,O){if(t){var V=B.deletions;V===null?(B.deletions=[O],B.flags|=16):V.push(O)}}function s(B,O){if(!t)return null;for(;O!==null;)a(B,O),O=O.sibling;return null}function c(B){for(var O=new Map;B!==null;)B.key!==null?O.set(B.key,B):O.set(B.index,B),B=B.sibling;return O}function p(B,O){return B=vi(B,O),B.index=0,B.sibling=null,B}function g(B,O,V){return B.index=V,t?(V=B.alternate,V!==null?(V=V.index,V<O?(B.flags|=67108866,O):V):(B.flags|=67108866,O)):(B.flags|=1048576,O)}function w(B){return t&&B.alternate===null&&(B.flags|=67108866),B}function A(B,O,V,ie){return O===null||O.tag!==6?(O=cp(V,B.mode,ie),O.return=B,O):(O=p(O,V),O.return=B,O)}function D(B,O,V,ie){var $e=V.type;return $e===P?te(B,O,V.props.children,ie,V.key):O!==null&&(O.elementType===$e||typeof $e=="object"&&$e!==null&&$e.$$typeof===Y&&oo($e)===O.type)?(O=p(O,V.props),Rl(O,V),O.return=B,O):(O=ou(V.type,V.key,V.props,null,B.mode,ie),Rl(O,V),O.return=B,O)}function U(B,O,V,ie){return O===null||O.tag!==4||O.stateNode.containerInfo!==V.containerInfo||O.stateNode.implementation!==V.implementation?(O=up(V,B.mode,ie),O.return=B,O):(O=p(O,V.children||[]),O.return=B,O)}function te(B,O,V,ie,$e){return O===null||O.tag!==7?(O=to(V,B.mode,ie,$e),O.return=B,O):(O=p(O,V),O.return=B,O)}function se(B,O,V){if(typeof O=="string"&&O!==""||typeof O=="number"||typeof O=="bigint")return O=cp(""+O,B.mode,V),O.return=B,O;if(typeof O=="object"&&O!==null){switch(O.$$typeof){case N:return V=ou(O.type,O.key,O.props,null,B.mode,V),Rl(V,O),V.return=B,V;case I:return O=up(O,B.mode,V),O.return=B,O;case Y:return O=oo(O),se(B,O,V)}if(Ve(O)||Ge(O))return O=to(O,B.mode,V,null),O.return=B,O;if(typeof O.then=="function")return se(B,pu(O),V);if(O.$$typeof===L)return se(B,cu(B,O),V);hu(B,O)}return null}function K(B,O,V,ie){var $e=O!==null?O.key:null;if(typeof V=="string"&&V!==""||typeof V=="number"||typeof V=="bigint")return $e!==null?null:A(B,O,""+V,ie);if(typeof V=="object"&&V!==null){switch(V.$$typeof){case N:return V.key===$e?D(B,O,V,ie):null;case I:return V.key===$e?U(B,O,V,ie):null;case Y:return V=oo(V),K(B,O,V,ie)}if(Ve(V)||Ge(V))return $e!==null?null:te(B,O,V,ie,null);if(typeof V.then=="function")return K(B,O,pu(V),ie);if(V.$$typeof===L)return K(B,O,cu(B,V),ie);hu(B,V)}return null}function Q(B,O,V,ie,$e){if(typeof ie=="string"&&ie!==""||typeof ie=="number"||typeof ie=="bigint")return B=B.get(V)||null,A(O,B,""+ie,$e);if(typeof ie=="object"&&ie!==null){switch(ie.$$typeof){case N:return B=B.get(ie.key===null?V:ie.key)||null,D(O,B,ie,$e);case I:return B=B.get(ie.key===null?V:ie.key)||null,U(O,B,ie,$e);case Y:return ie=oo(ie),Q(B,O,V,ie,$e)}if(Ve(ie)||Ge(ie))return B=B.get(V)||null,te(O,B,ie,$e,null);if(typeof ie.then=="function")return Q(B,O,V,pu(ie),$e);if(ie.$$typeof===L)return Q(B,O,V,cu(O,ie),$e);hu(O,ie)}return null}function Ae(B,O,V,ie){for(var $e=null,bt=null,Te=O,tt=O=0,dt=null;Te!==null&&tt<V.length;tt++){Te.index>tt?(dt=Te,Te=null):dt=Te.sibling;var vt=K(B,Te,V[tt],ie);if(vt===null){Te===null&&(Te=dt);break}t&&Te&&vt.alternate===null&&a(B,Te),O=g(vt,O,tt),bt===null?$e=vt:bt.sibling=vt,bt=vt,Te=dt}if(tt===V.length)return s(B,Te),ht&&xi(B,tt),$e;if(Te===null){for(;tt<V.length;tt++)Te=se(B,V[tt],ie),Te!==null&&(O=g(Te,O,tt),bt===null?$e=Te:bt.sibling=Te,bt=Te);return ht&&xi(B,tt),$e}for(Te=c(Te);tt<V.length;tt++)dt=Q(Te,B,tt,V[tt],ie),dt!==null&&(t&&dt.alternate!==null&&Te.delete(dt.key===null?tt:dt.key),O=g(dt,O,tt),bt===null?$e=dt:bt.sibling=dt,bt=dt);return t&&Te.forEach(function(ws){return a(B,ws)}),ht&&xi(B,tt),$e}function Ke(B,O,V,ie){if(V==null)throw Error(r(151));for(var $e=null,bt=null,Te=O,tt=O=0,dt=null,vt=V.next();Te!==null&&!vt.done;tt++,vt=V.next()){Te.index>tt?(dt=Te,Te=null):dt=Te.sibling;var ws=K(B,Te,vt.value,ie);if(ws===null){Te===null&&(Te=dt);break}t&&Te&&ws.alternate===null&&a(B,Te),O=g(ws,O,tt),bt===null?$e=ws:bt.sibling=ws,bt=ws,Te=dt}if(vt.done)return s(B,Te),ht&&xi(B,tt),$e;if(Te===null){for(;!vt.done;tt++,vt=V.next())vt=se(B,vt.value,ie),vt!==null&&(O=g(vt,O,tt),bt===null?$e=vt:bt.sibling=vt,bt=vt);return ht&&xi(B,tt),$e}for(Te=c(Te);!vt.done;tt++,vt=V.next())vt=Q(Te,B,tt,vt.value,ie),vt!==null&&(t&&vt.alternate!==null&&Te.delete(vt.key===null?tt:vt.key),O=g(vt,O,tt),bt===null?$e=vt:bt.sibling=vt,bt=vt);return t&&Te.forEach(function(a5){return a(B,a5)}),ht&&xi(B,tt),$e}function Rt(B,O,V,ie){if(typeof V=="object"&&V!==null&&V.type===P&&V.key===null&&(V=V.props.children),typeof V=="object"&&V!==null){switch(V.$$typeof){case N:e:{for(var $e=V.key;O!==null;){if(O.key===$e){if($e=V.type,$e===P){if(O.tag===7){s(B,O.sibling),ie=p(O,V.props.children),ie.return=B,B=ie;break e}}else if(O.elementType===$e||typeof $e=="object"&&$e!==null&&$e.$$typeof===Y&&oo($e)===O.type){s(B,O.sibling),ie=p(O,V.props),Rl(ie,V),ie.return=B,B=ie;break e}s(B,O);break}else a(B,O);O=O.sibling}V.type===P?(ie=to(V.props.children,B.mode,ie,V.key),ie.return=B,B=ie):(ie=ou(V.type,V.key,V.props,null,B.mode,ie),Rl(ie,V),ie.return=B,B=ie)}return w(B);case I:e:{for($e=V.key;O!==null;){if(O.key===$e)if(O.tag===4&&O.stateNode.containerInfo===V.containerInfo&&O.stateNode.implementation===V.implementation){s(B,O.sibling),ie=p(O,V.children||[]),ie.return=B,B=ie;break e}else{s(B,O);break}else a(B,O);O=O.sibling}ie=up(V,B.mode,ie),ie.return=B,B=ie}return w(B);case Y:return V=oo(V),Rt(B,O,V,ie)}if(Ve(V))return Ae(B,O,V,ie);if(Ge(V)){if($e=Ge(V),typeof $e!="function")throw Error(r(150));return V=$e.call(V),Ke(B,O,V,ie)}if(typeof V.then=="function")return Rt(B,O,pu(V),ie);if(V.$$typeof===L)return Rt(B,O,cu(B,V),ie);hu(B,V)}return typeof V=="string"&&V!==""||typeof V=="number"||typeof V=="bigint"?(V=""+V,O!==null&&O.tag===6?(s(B,O.sibling),ie=p(O,V),ie.return=B,B=ie):(s(B,O),ie=cp(V,B.mode,ie),ie.return=B,B=ie),w(B)):s(B,O)}return function(B,O,V,ie){try{El=0;var $e=Rt(B,O,V,ie);return rr=null,$e}catch(Te){if(Te===or||Te===du)throw Te;var bt=oa(29,Te,null,B.mode);return bt.lanes=ie,bt.return=B,bt}}}var lo=yy(!0),by=yy(!1),is=!1;function Sp(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function kp(t,a){t=t.updateQueue,a.updateQueue===t&&(a.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function ss(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function os(t,a,s){var c=t.updateQueue;if(c===null)return null;if(c=c.shared,(wt&2)!==0){var p=c.pending;return p===null?a.next=a:(a.next=p.next,p.next=a),c.pending=a,a=su(t),ty(t,null,s),a}return iu(t,c,a,s),su(t)}function Dl(t,a,s){if(a=a.updateQueue,a!==null&&(a=a.shared,(s&4194048)!==0)){var c=a.lanes;c&=t.pendingLanes,s|=c,a.lanes=s,sl(t,s)}}function jp(t,a){var s=t.updateQueue,c=t.alternate;if(c!==null&&(c=c.updateQueue,s===c)){var p=null,g=null;if(s=s.firstBaseUpdate,s!==null){do{var w={lane:s.lane,tag:s.tag,payload:s.payload,callback:null,next:null};g===null?p=g=w:g=g.next=w,s=s.next}while(s!==null);g===null?p=g=a:g=g.next=a}else p=g=a;s={baseState:c.baseState,firstBaseUpdate:p,lastBaseUpdate:g,shared:c.shared,callbacks:c.callbacks},t.updateQueue=s;return}t=s.lastBaseUpdate,t===null?s.firstBaseUpdate=a:t.next=a,s.lastBaseUpdate=a}var Ap=!1;function zl(){if(Ap){var t=sr;if(t!==null)throw t}}function Il(t,a,s,c){Ap=!1;var p=t.updateQueue;is=!1;var g=p.firstBaseUpdate,w=p.lastBaseUpdate,A=p.shared.pending;if(A!==null){p.shared.pending=null;var D=A,U=D.next;D.next=null,w===null?g=U:w.next=U,w=D;var te=t.alternate;te!==null&&(te=te.updateQueue,A=te.lastBaseUpdate,A!==w&&(A===null?te.firstBaseUpdate=U:A.next=U,te.lastBaseUpdate=D))}if(g!==null){var se=p.baseState;w=0,te=U=D=null,A=g;do{var K=A.lane&-536870913,Q=K!==A.lane;if(Q?(ut&K)===K:(c&K)===K){K!==0&&K===ir&&(Ap=!0),te!==null&&(te=te.next={lane:0,tag:A.tag,payload:A.payload,callback:null,next:null});e:{var Ae=t,Ke=A;K=a;var Rt=s;switch(Ke.tag){case 1:if(Ae=Ke.payload,typeof Ae=="function"){se=Ae.call(Rt,se,K);break e}se=Ae;break e;case 3:Ae.flags=Ae.flags&-65537|128;case 0:if(Ae=Ke.payload,K=typeof Ae=="function"?Ae.call(Rt,se,K):Ae,K==null)break e;se=k({},se,K);break e;case 2:is=!0}}K=A.callback,K!==null&&(t.flags|=64,Q&&(t.flags|=8192),Q=p.callbacks,Q===null?p.callbacks=[K]:Q.push(K))}else Q={lane:K,tag:A.tag,payload:A.payload,callback:A.callback,next:null},te===null?(U=te=Q,D=se):te=te.next=Q,w|=K;if(A=A.next,A===null){if(A=p.shared.pending,A===null)break;Q=A,A=Q.next,Q.next=null,p.lastBaseUpdate=Q,p.shared.pending=null}}while(!0);te===null&&(D=se),p.baseState=D,p.firstBaseUpdate=U,p.lastBaseUpdate=te,g===null&&(p.shared.lanes=0),ds|=w,t.lanes=w,t.memoizedState=se}}function vy(t,a){if(typeof t!="function")throw Error(r(191,t));t.call(a)}function xy(t,a){var s=t.callbacks;if(s!==null)for(t.callbacks=null,t=0;t<s.length;t++)vy(s[t],a)}var lr=Ne(null),fu=Ne(0);function wy(t,a){t=Ri,xe(fu,t),xe(lr,a),Ri=t|a.baseLanes}function Cp(){xe(fu,Ri),xe(lr,lr.current)}function Np(){Ri=fu.current,Me(lr),Me(fu)}var ra=Ne(null),Na=null;function rs(t){var a=t.alternate;xe(tn,tn.current&1),xe(ra,t),Na===null&&(a===null||lr.current!==null||a.memoizedState!==null)&&(Na=t)}function _p(t){xe(tn,tn.current),xe(ra,t),Na===null&&(Na=t)}function Sy(t){t.tag===22?(xe(tn,tn.current),xe(ra,t),Na===null&&(Na=t)):ls()}function ls(){xe(tn,tn.current),xe(ra,ra.current)}function la(t){Me(ra),Na===t&&(Na=null),Me(tn)}var tn=Ne(0);function gu(t){for(var a=t;a!==null;){if(a.tag===13){var s=a.memoizedState;if(s!==null&&(s=s.dehydrated,s===null||Ih(s)||Oh(s)))return a}else if(a.tag===19&&(a.memoizedProps.revealOrder==="forwards"||a.memoizedProps.revealOrder==="backwards"||a.memoizedProps.revealOrder==="unstable_legacy-backwards"||a.memoizedProps.revealOrder==="together")){if((a.flags&128)!==0)return a}else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===t)break;for(;a.sibling===null;){if(a.return===null||a.return===t)return null;a=a.return}a.sibling.return=a.return,a=a.sibling}return null}var ki=0,Je=null,Tt=null,ln=null,yu=!1,cr=!1,co=!1,bu=0,Ol=0,ur=null,Q4=0;function Xt(){throw Error(r(321))}function Tp(t,a){if(a===null)return!1;for(var s=0;s<a.length&&s<t.length;s++)if(!sa(t[s],a[s]))return!1;return!0}function Ep(t,a,s,c,p,g){return ki=g,Je=a,a.memoizedState=null,a.updateQueue=null,a.lanes=0,q.H=t===null||t.memoizedState===null?sb:Kp,co=!1,g=s(c,p),co=!1,cr&&(g=jy(a,s,c,p)),ky(t),g}function ky(t){q.H=Ml;var a=Tt!==null&&Tt.next!==null;if(ki=0,ln=Tt=Je=null,yu=!1,Ol=0,ur=null,a)throw Error(r(300));t===null||cn||(t=t.dependencies,t!==null&&lu(t)&&(cn=!0))}function jy(t,a,s,c){Je=t;var p=0;do{if(cr&&(ur=null),Ol=0,cr=!1,25<=p)throw Error(r(301));if(p+=1,ln=Tt=null,t.updateQueue!=null){var g=t.updateQueue;g.lastEffect=null,g.events=null,g.stores=null,g.memoCache!=null&&(g.memoCache.index=0)}q.H=ob,g=a(s,c)}while(cr);return g}function F4(){var t=q.H,a=t.useState()[0];return a=typeof a.then=="function"?ql(a):a,t=t.useState()[0],(Tt!==null?Tt.memoizedState:null)!==t&&(Je.flags|=1024),a}function Rp(){var t=bu!==0;return bu=0,t}function Dp(t,a,s){a.updateQueue=t.updateQueue,a.flags&=-2053,t.lanes&=~s}function zp(t){if(yu){for(t=t.memoizedState;t!==null;){var a=t.queue;a!==null&&(a.pending=null),t=t.next}yu=!1}ki=0,ln=Tt=Je=null,cr=!1,Ol=bu=0,ur=null}function $n(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return ln===null?Je.memoizedState=ln=t:ln=ln.next=t,ln}function nn(){if(Tt===null){var t=Je.alternate;t=t!==null?t.memoizedState:null}else t=Tt.next;var a=ln===null?Je.memoizedState:ln.next;if(a!==null)ln=a,Tt=t;else{if(t===null)throw Je.alternate===null?Error(r(467)):Error(r(310));Tt=t,t={memoizedState:Tt.memoizedState,baseState:Tt.baseState,baseQueue:Tt.baseQueue,queue:Tt.queue,next:null},ln===null?Je.memoizedState=ln=t:ln=ln.next=t}return ln}function vu(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function ql(t){var a=Ol;return Ol+=1,ur===null&&(ur=[]),t=hy(ur,t,a),a=Je,(ln===null?a.memoizedState:ln.next)===null&&(a=a.alternate,q.H=a===null||a.memoizedState===null?sb:Kp),t}function xu(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return ql(t);if(t.$$typeof===L)return Tn(t)}throw Error(r(438,String(t)))}function Ip(t){var a=null,s=Je.updateQueue;if(s!==null&&(a=s.memoCache),a==null){var c=Je.alternate;c!==null&&(c=c.updateQueue,c!==null&&(c=c.memoCache,c!=null&&(a={data:c.data.map(function(p){return p.slice()}),index:0})))}if(a==null&&(a={data:[],index:0}),s===null&&(s=vu(),Je.updateQueue=s),s.memoCache=a,s=a.data[a.index],s===void 0)for(s=a.data[a.index]=Array(t),c=0;c<t;c++)s[c]=Xe;return a.index++,s}function ji(t,a){return typeof a=="function"?a(t):a}function wu(t){var a=nn();return Op(a,Tt,t)}function Op(t,a,s){var c=t.queue;if(c===null)throw Error(r(311));c.lastRenderedReducer=s;var p=t.baseQueue,g=c.pending;if(g!==null){if(p!==null){var w=p.next;p.next=g.next,g.next=w}a.baseQueue=p=g,c.pending=null}if(g=t.baseState,p===null)t.memoizedState=g;else{a=p.next;var A=w=null,D=null,U=a,te=!1;do{var se=U.lane&-536870913;if(se!==U.lane?(ut&se)===se:(ki&se)===se){var K=U.revertLane;if(K===0)D!==null&&(D=D.next={lane:0,revertLane:0,gesture:null,action:U.action,hasEagerState:U.hasEagerState,eagerState:U.eagerState,next:null}),se===ir&&(te=!0);else if((ki&K)===K){U=U.next,K===ir&&(te=!0);continue}else se={lane:0,revertLane:U.revertLane,gesture:null,action:U.action,hasEagerState:U.hasEagerState,eagerState:U.eagerState,next:null},D===null?(A=D=se,w=g):D=D.next=se,Je.lanes|=K,ds|=K;se=U.action,co&&s(g,se),g=U.hasEagerState?U.eagerState:s(g,se)}else K={lane:se,revertLane:U.revertLane,gesture:U.gesture,action:U.action,hasEagerState:U.hasEagerState,eagerState:U.eagerState,next:null},D===null?(A=D=K,w=g):D=D.next=K,Je.lanes|=se,ds|=se;U=U.next}while(U!==null&&U!==a);if(D===null?w=g:D.next=A,!sa(g,t.memoizedState)&&(cn=!0,te&&(s=sr,s!==null)))throw s;t.memoizedState=g,t.baseState=w,t.baseQueue=D,c.lastRenderedState=g}return p===null&&(c.lanes=0),[t.memoizedState,c.dispatch]}function qp(t){var a=nn(),s=a.queue;if(s===null)throw Error(r(311));s.lastRenderedReducer=t;var c=s.dispatch,p=s.pending,g=a.memoizedState;if(p!==null){s.pending=null;var w=p=p.next;do g=t(g,w.action),w=w.next;while(w!==p);sa(g,a.memoizedState)||(cn=!0),a.memoizedState=g,a.baseQueue===null&&(a.baseState=g),s.lastRenderedState=g}return[g,c]}function Ay(t,a,s){var c=Je,p=nn(),g=ht;if(g){if(s===void 0)throw Error(r(407));s=s()}else s=a();var w=!sa((Tt||p).memoizedState,s);if(w&&(p.memoizedState=s,cn=!0),p=p.queue,Bp(_y.bind(null,c,p,t),[t]),p.getSnapshot!==a||w||ln!==null&&ln.memoizedState.tag&1){if(c.flags|=2048,dr(9,{destroy:void 0},Ny.bind(null,c,p,s,a),null),Dt===null)throw Error(r(349));g||(ki&127)!==0||Cy(c,a,s)}return s}function Cy(t,a,s){t.flags|=16384,t={getSnapshot:a,value:s},a=Je.updateQueue,a===null?(a=vu(),Je.updateQueue=a,a.stores=[t]):(s=a.stores,s===null?a.stores=[t]:s.push(t))}function Ny(t,a,s,c){a.value=s,a.getSnapshot=c,Ty(a)&&Ey(t)}function _y(t,a,s){return s(function(){Ty(a)&&Ey(t)})}function Ty(t){var a=t.getSnapshot;t=t.value;try{var s=a();return!sa(t,s)}catch{return!0}}function Ey(t){var a=eo(t,2);a!==null&&Jn(a,t,2)}function Pp(t){var a=$n();if(typeof t=="function"){var s=t;if(t=s(),co){bn(!0);try{s()}finally{bn(!1)}}}return a.memoizedState=a.baseState=t,a.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ji,lastRenderedState:t},a}function Ry(t,a,s,c){return t.baseState=s,Op(t,Tt,typeof c=="function"?c:ji)}function Z4(t,a,s,c,p){if(ju(t))throw Error(r(485));if(t=a.action,t!==null){var g={payload:p,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(w){g.listeners.push(w)}};q.T!==null?s(!0):g.isTransition=!1,c(g),s=a.pending,s===null?(g.next=a.pending=g,Dy(a,g)):(g.next=s.next,a.pending=s.next=g)}}function Dy(t,a){var s=a.action,c=a.payload,p=t.state;if(a.isTransition){var g=q.T,w={};q.T=w;try{var A=s(p,c),D=q.S;D!==null&&D(w,A),zy(t,a,A)}catch(U){Mp(t,a,U)}finally{g!==null&&w.types!==null&&(g.types=w.types),q.T=g}}else try{g=s(p,c),zy(t,a,g)}catch(U){Mp(t,a,U)}}function zy(t,a,s){s!==null&&typeof s=="object"&&typeof s.then=="function"?s.then(function(c){Iy(t,a,c)},function(c){return Mp(t,a,c)}):Iy(t,a,s)}function Iy(t,a,s){a.status="fulfilled",a.value=s,Oy(a),t.state=s,a=t.pending,a!==null&&(s=a.next,s===a?t.pending=null:(s=s.next,a.next=s,Dy(t,s)))}function Mp(t,a,s){var c=t.pending;if(t.pending=null,c!==null){c=c.next;do a.status="rejected",a.reason=s,Oy(a),a=a.next;while(a!==c)}t.action=null}function Oy(t){t=t.listeners;for(var a=0;a<t.length;a++)(0,t[a])()}function qy(t,a){return a}function Py(t,a){if(ht){var s=Dt.formState;if(s!==null){e:{var c=Je;if(ht){if(qt){t:{for(var p=qt,g=Ca;p.nodeType!==8;){if(!g){p=null;break t}if(p=_a(p.nextSibling),p===null){p=null;break t}}g=p.data,p=g==="F!"||g==="F"?p:null}if(p){qt=_a(p.nextSibling),c=p.data==="F!";break e}}ns(c)}c=!1}c&&(a=s[0])}}return s=$n(),s.memoizedState=s.baseState=a,c={pending:null,lanes:0,dispatch:null,lastRenderedReducer:qy,lastRenderedState:a},s.queue=c,s=nb.bind(null,Je,c),c.dispatch=s,c=Pp(!1),g=Gp.bind(null,Je,!1,c.queue),c=$n(),p={state:a,dispatch:null,action:t,pending:null},c.queue=p,s=Z4.bind(null,Je,p,g,s),p.dispatch=s,c.memoizedState=t,[a,s,!1]}function My(t){var a=nn();return By(a,Tt,t)}function By(t,a,s){if(a=Op(t,a,qy)[0],t=wu(ji)[0],typeof a=="object"&&a!==null&&typeof a.then=="function")try{var c=ql(a)}catch(w){throw w===or?du:w}else c=a;a=nn();var p=a.queue,g=p.dispatch;return s!==a.memoizedState&&(Je.flags|=2048,dr(9,{destroy:void 0},Y4.bind(null,p,s),null)),[c,g,t]}function Y4(t,a){t.action=a}function Ly(t){var a=nn(),s=Tt;if(s!==null)return By(a,s,t);nn(),a=a.memoizedState,s=nn();var c=s.queue.dispatch;return s.memoizedState=t,[a,c,!1]}function dr(t,a,s,c){return t={tag:t,create:s,deps:c,inst:a,next:null},a=Je.updateQueue,a===null&&(a=vu(),Je.updateQueue=a),s=a.lastEffect,s===null?a.lastEffect=t.next=t:(c=s.next,s.next=t,t.next=c,a.lastEffect=t),t}function $y(){return nn().memoizedState}function Su(t,a,s,c){var p=$n();Je.flags|=t,p.memoizedState=dr(1|a,{destroy:void 0},s,c===void 0?null:c)}function ku(t,a,s,c){var p=nn();c=c===void 0?null:c;var g=p.memoizedState.inst;Tt!==null&&c!==null&&Tp(c,Tt.memoizedState.deps)?p.memoizedState=dr(a,g,s,c):(Je.flags|=t,p.memoizedState=dr(1|a,g,s,c))}function Vy(t,a){Su(8390656,8,t,a)}function Bp(t,a){ku(2048,8,t,a)}function X4(t){Je.flags|=4;var a=Je.updateQueue;if(a===null)a=vu(),Je.updateQueue=a,a.events=[t];else{var s=a.events;s===null?a.events=[t]:s.push(t)}}function Uy(t){var a=nn().memoizedState;return X4({ref:a,nextImpl:t}),function(){if((wt&2)!==0)throw Error(r(440));return a.impl.apply(void 0,arguments)}}function Gy(t,a){return ku(4,2,t,a)}function Ky(t,a){return ku(4,4,t,a)}function Hy(t,a){if(typeof a=="function"){t=t();var s=a(t);return function(){typeof s=="function"?s():a(null)}}if(a!=null)return t=t(),a.current=t,function(){a.current=null}}function Qy(t,a,s){s=s!=null?s.concat([t]):null,ku(4,4,Hy.bind(null,a,t),s)}function Lp(){}function Fy(t,a){var s=nn();a=a===void 0?null:a;var c=s.memoizedState;return a!==null&&Tp(a,c[1])?c[0]:(s.memoizedState=[t,a],t)}function Zy(t,a){var s=nn();a=a===void 0?null:a;var c=s.memoizedState;if(a!==null&&Tp(a,c[1]))return c[0];if(c=t(),co){bn(!0);try{t()}finally{bn(!1)}}return s.memoizedState=[c,a],c}function $p(t,a,s){return s===void 0||(ki&1073741824)!==0&&(ut&261930)===0?t.memoizedState=a:(t.memoizedState=s,t=Yb(),Je.lanes|=t,ds|=t,s)}function Yy(t,a,s,c){return sa(s,a)?s:lr.current!==null?(t=$p(t,s,c),sa(t,a)||(cn=!0),t):(ki&42)===0||(ki&1073741824)!==0&&(ut&261930)===0?(cn=!0,t.memoizedState=s):(t=Yb(),Je.lanes|=t,ds|=t,a)}function Xy(t,a,s,c,p){var g=X.p;X.p=g!==0&&8>g?g:8;var w=q.T,A={};q.T=A,Gp(t,!1,a,s);try{var D=p(),U=q.S;if(U!==null&&U(A,D),D!==null&&typeof D=="object"&&typeof D.then=="function"){var te=H4(D,c);Pl(t,a,te,da(t))}else Pl(t,a,c,da(t))}catch(se){Pl(t,a,{then:function(){},status:"rejected",reason:se},da())}finally{X.p=g,w!==null&&A.types!==null&&(w.types=A.types),q.T=w}}function J4(){}function Vp(t,a,s,c){if(t.tag!==5)throw Error(r(476));var p=Jy(t).queue;Xy(t,p,a,ve,s===null?J4:function(){return Wy(t),s(c)})}function Jy(t){var a=t.memoizedState;if(a!==null)return a;a={memoizedState:ve,baseState:ve,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ji,lastRenderedState:ve},next:null};var s={};return a.next={memoizedState:s,baseState:s,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ji,lastRenderedState:s},next:null},t.memoizedState=a,t=t.alternate,t!==null&&(t.memoizedState=a),a}function Wy(t){var a=Jy(t);a.next===null&&(a=t.alternate.memoizedState),Pl(t,a.next.queue,{},da())}function Up(){return Tn(ec)}function eb(){return nn().memoizedState}function tb(){return nn().memoizedState}function W4(t){for(var a=t.return;a!==null;){switch(a.tag){case 24:case 3:var s=da();t=ss(s);var c=os(a,t,s);c!==null&&(Jn(c,a,s),Dl(c,a,s)),a={cache:bp()},t.payload=a;return}a=a.return}}function eN(t,a,s){var c=da();s={lane:c,revertLane:0,gesture:null,action:s,hasEagerState:!1,eagerState:null,next:null},ju(t)?ab(a,s):(s=rp(t,a,s,c),s!==null&&(Jn(s,t,c),ib(s,a,c)))}function nb(t,a,s){var c=da();Pl(t,a,s,c)}function Pl(t,a,s,c){var p={lane:c,revertLane:0,gesture:null,action:s,hasEagerState:!1,eagerState:null,next:null};if(ju(t))ab(a,p);else{var g=t.alternate;if(t.lanes===0&&(g===null||g.lanes===0)&&(g=a.lastRenderedReducer,g!==null))try{var w=a.lastRenderedState,A=g(w,s);if(p.hasEagerState=!0,p.eagerState=A,sa(A,w))return iu(t,a,p,0),Dt===null&&au(),!1}catch{}if(s=rp(t,a,p,c),s!==null)return Jn(s,t,c),ib(s,a,c),!0}return!1}function Gp(t,a,s,c){if(c={lane:2,revertLane:Sh(),gesture:null,action:c,hasEagerState:!1,eagerState:null,next:null},ju(t)){if(a)throw Error(r(479))}else a=rp(t,s,c,2),a!==null&&Jn(a,t,2)}function ju(t){var a=t.alternate;return t===Je||a!==null&&a===Je}function ab(t,a){cr=yu=!0;var s=t.pending;s===null?a.next=a:(a.next=s.next,s.next=a),t.pending=a}function ib(t,a,s){if((s&4194048)!==0){var c=a.lanes;c&=t.pendingLanes,s|=c,a.lanes=s,sl(t,s)}}var Ml={readContext:Tn,use:xu,useCallback:Xt,useContext:Xt,useEffect:Xt,useImperativeHandle:Xt,useLayoutEffect:Xt,useInsertionEffect:Xt,useMemo:Xt,useReducer:Xt,useRef:Xt,useState:Xt,useDebugValue:Xt,useDeferredValue:Xt,useTransition:Xt,useSyncExternalStore:Xt,useId:Xt,useHostTransitionStatus:Xt,useFormState:Xt,useActionState:Xt,useOptimistic:Xt,useMemoCache:Xt,useCacheRefresh:Xt};Ml.useEffectEvent=Xt;var sb={readContext:Tn,use:xu,useCallback:function(t,a){return $n().memoizedState=[t,a===void 0?null:a],t},useContext:Tn,useEffect:Vy,useImperativeHandle:function(t,a,s){s=s!=null?s.concat([t]):null,Su(4194308,4,Hy.bind(null,a,t),s)},useLayoutEffect:function(t,a){return Su(4194308,4,t,a)},useInsertionEffect:function(t,a){Su(4,2,t,a)},useMemo:function(t,a){var s=$n();a=a===void 0?null:a;var c=t();if(co){bn(!0);try{t()}finally{bn(!1)}}return s.memoizedState=[c,a],c},useReducer:function(t,a,s){var c=$n();if(s!==void 0){var p=s(a);if(co){bn(!0);try{s(a)}finally{bn(!1)}}}else p=a;return c.memoizedState=c.baseState=p,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:p},c.queue=t,t=t.dispatch=eN.bind(null,Je,t),[c.memoizedState,t]},useRef:function(t){var a=$n();return t={current:t},a.memoizedState=t},useState:function(t){t=Pp(t);var a=t.queue,s=nb.bind(null,Je,a);return a.dispatch=s,[t.memoizedState,s]},useDebugValue:Lp,useDeferredValue:function(t,a){var s=$n();return $p(s,t,a)},useTransition:function(){var t=Pp(!1);return t=Xy.bind(null,Je,t.queue,!0,!1),$n().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,a,s){var c=Je,p=$n();if(ht){if(s===void 0)throw Error(r(407));s=s()}else{if(s=a(),Dt===null)throw Error(r(349));(ut&127)!==0||Cy(c,a,s)}p.memoizedState=s;var g={value:s,getSnapshot:a};return p.queue=g,Vy(_y.bind(null,c,g,t),[t]),c.flags|=2048,dr(9,{destroy:void 0},Ny.bind(null,c,g,s,a),null),s},useId:function(){var t=$n(),a=Dt.identifierPrefix;if(ht){var s=si,c=ii;s=(c&~(1<<32-An(c)-1)).toString(32)+s,a="_"+a+"R_"+s,s=bu++,0<s&&(a+="H"+s.toString(32)),a+="_"}else s=Q4++,a="_"+a+"r_"+s.toString(32)+"_";return t.memoizedState=a},useHostTransitionStatus:Up,useFormState:Py,useActionState:Py,useOptimistic:function(t){var a=$n();a.memoizedState=a.baseState=t;var s={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return a.queue=s,a=Gp.bind(null,Je,!0,s),s.dispatch=a,[t,a]},useMemoCache:Ip,useCacheRefresh:function(){return $n().memoizedState=W4.bind(null,Je)},useEffectEvent:function(t){var a=$n(),s={impl:t};return a.memoizedState=s,function(){if((wt&2)!==0)throw Error(r(440));return s.impl.apply(void 0,arguments)}}},Kp={readContext:Tn,use:xu,useCallback:Fy,useContext:Tn,useEffect:Bp,useImperativeHandle:Qy,useInsertionEffect:Gy,useLayoutEffect:Ky,useMemo:Zy,useReducer:wu,useRef:$y,useState:function(){return wu(ji)},useDebugValue:Lp,useDeferredValue:function(t,a){var s=nn();return Yy(s,Tt.memoizedState,t,a)},useTransition:function(){var t=wu(ji)[0],a=nn().memoizedState;return[typeof t=="boolean"?t:ql(t),a]},useSyncExternalStore:Ay,useId:eb,useHostTransitionStatus:Up,useFormState:My,useActionState:My,useOptimistic:function(t,a){var s=nn();return Ry(s,Tt,t,a)},useMemoCache:Ip,useCacheRefresh:tb};Kp.useEffectEvent=Uy;var ob={readContext:Tn,use:xu,useCallback:Fy,useContext:Tn,useEffect:Bp,useImperativeHandle:Qy,useInsertionEffect:Gy,useLayoutEffect:Ky,useMemo:Zy,useReducer:qp,useRef:$y,useState:function(){return qp(ji)},useDebugValue:Lp,useDeferredValue:function(t,a){var s=nn();return Tt===null?$p(s,t,a):Yy(s,Tt.memoizedState,t,a)},useTransition:function(){var t=qp(ji)[0],a=nn().memoizedState;return[typeof t=="boolean"?t:ql(t),a]},useSyncExternalStore:Ay,useId:eb,useHostTransitionStatus:Up,useFormState:Ly,useActionState:Ly,useOptimistic:function(t,a){var s=nn();return Tt!==null?Ry(s,Tt,t,a):(s.baseState=t,[t,s.queue.dispatch])},useMemoCache:Ip,useCacheRefresh:tb};ob.useEffectEvent=Uy;function Hp(t,a,s,c){a=t.memoizedState,s=s(c,a),s=s==null?a:k({},a,s),t.memoizedState=s,t.lanes===0&&(t.updateQueue.baseState=s)}var Qp={enqueueSetState:function(t,a,s){t=t._reactInternals;var c=da(),p=ss(c);p.payload=a,s!=null&&(p.callback=s),a=os(t,p,c),a!==null&&(Jn(a,t,c),Dl(a,t,c))},enqueueReplaceState:function(t,a,s){t=t._reactInternals;var c=da(),p=ss(c);p.tag=1,p.payload=a,s!=null&&(p.callback=s),a=os(t,p,c),a!==null&&(Jn(a,t,c),Dl(a,t,c))},enqueueForceUpdate:function(t,a){t=t._reactInternals;var s=da(),c=ss(s);c.tag=2,a!=null&&(c.callback=a),a=os(t,c,s),a!==null&&(Jn(a,t,s),Dl(a,t,s))}};function rb(t,a,s,c,p,g,w){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(c,g,w):a.prototype&&a.prototype.isPureReactComponent?!jl(s,c)||!jl(p,g):!0}function lb(t,a,s,c){t=a.state,typeof a.componentWillReceiveProps=="function"&&a.componentWillReceiveProps(s,c),typeof a.UNSAFE_componentWillReceiveProps=="function"&&a.UNSAFE_componentWillReceiveProps(s,c),a.state!==t&&Qp.enqueueReplaceState(a,a.state,null)}function uo(t,a){var s=a;if("ref"in a){s={};for(var c in a)c!=="ref"&&(s[c]=a[c])}if(t=t.defaultProps){s===a&&(s=k({},s));for(var p in t)s[p]===void 0&&(s[p]=t[p])}return s}function cb(t){nu(t)}function ub(t){console.error(t)}function db(t){nu(t)}function Au(t,a){try{var s=t.onUncaughtError;s(a.value,{componentStack:a.stack})}catch(c){setTimeout(function(){throw c})}}function mb(t,a,s){try{var c=t.onCaughtError;c(s.value,{componentStack:s.stack,errorBoundary:a.tag===1?a.stateNode:null})}catch(p){setTimeout(function(){throw p})}}function Fp(t,a,s){return s=ss(s),s.tag=3,s.payload={element:null},s.callback=function(){Au(t,a)},s}function pb(t){return t=ss(t),t.tag=3,t}function hb(t,a,s,c){var p=s.type.getDerivedStateFromError;if(typeof p=="function"){var g=c.value;t.payload=function(){return p(g)},t.callback=function(){mb(a,s,c)}}var w=s.stateNode;w!==null&&typeof w.componentDidCatch=="function"&&(t.callback=function(){mb(a,s,c),typeof p!="function"&&(ms===null?ms=new Set([this]):ms.add(this));var A=c.stack;this.componentDidCatch(c.value,{componentStack:A!==null?A:""})})}function tN(t,a,s,c,p){if(s.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){if(a=s.alternate,a!==null&&ar(a,s,p,!0),s=ra.current,s!==null){switch(s.tag){case 31:case 13:return Na===null?Pu():s.alternate===null&&Jt===0&&(Jt=3),s.flags&=-257,s.flags|=65536,s.lanes=p,c===mu?s.flags|=16384:(a=s.updateQueue,a===null?s.updateQueue=new Set([c]):a.add(c),vh(t,c,p)),!1;case 22:return s.flags|=65536,c===mu?s.flags|=16384:(a=s.updateQueue,a===null?(a={transitions:null,markerInstances:null,retryQueue:new Set([c])},s.updateQueue=a):(s=a.retryQueue,s===null?a.retryQueue=new Set([c]):s.add(c)),vh(t,c,p)),!1}throw Error(r(435,s.tag))}return vh(t,c,p),Pu(),!1}if(ht)return a=ra.current,a!==null?((a.flags&65536)===0&&(a.flags|=256),a.flags|=65536,a.lanes=p,c!==pp&&(t=Error(r(422),{cause:c}),Nl(ka(t,s)))):(c!==pp&&(a=Error(r(423),{cause:c}),Nl(ka(a,s))),t=t.current.alternate,t.flags|=65536,p&=-p,t.lanes|=p,c=ka(c,s),p=Fp(t.stateNode,c,p),jp(t,p),Jt!==4&&(Jt=2)),!1;var g=Error(r(520),{cause:c});if(g=ka(g,s),Hl===null?Hl=[g]:Hl.push(g),Jt!==4&&(Jt=2),a===null)return!0;c=ka(c,s),s=a;do{switch(s.tag){case 3:return s.flags|=65536,t=p&-p,s.lanes|=t,t=Fp(s.stateNode,c,t),jp(s,t),!1;case 1:if(a=s.type,g=s.stateNode,(s.flags&128)===0&&(typeof a.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(ms===null||!ms.has(g))))return s.flags|=65536,p&=-p,s.lanes|=p,p=pb(p),hb(p,t,s,c),jp(s,p),!1}s=s.return}while(s!==null);return!1}var Zp=Error(r(461)),cn=!1;function En(t,a,s,c){a.child=t===null?by(a,null,s,c):lo(a,t.child,s,c)}function fb(t,a,s,c,p){s=s.render;var g=a.ref;if("ref"in c){var w={};for(var A in c)A!=="ref"&&(w[A]=c[A])}else w=c;return io(a),c=Ep(t,a,s,w,g,p),A=Rp(),t!==null&&!cn?(Dp(t,a,p),Ai(t,a,p)):(ht&&A&&dp(a),a.flags|=1,En(t,a,c,p),a.child)}function gb(t,a,s,c,p){if(t===null){var g=s.type;return typeof g=="function"&&!lp(g)&&g.defaultProps===void 0&&s.compare===null?(a.tag=15,a.type=g,yb(t,a,g,c,p)):(t=ou(s.type,null,c,a,a.mode,p),t.ref=a.ref,t.return=a,a.child=t)}if(g=t.child,!ah(t,p)){var w=g.memoizedProps;if(s=s.compare,s=s!==null?s:jl,s(w,c)&&t.ref===a.ref)return Ai(t,a,p)}return a.flags|=1,t=vi(g,c),t.ref=a.ref,t.return=a,a.child=t}function yb(t,a,s,c,p){if(t!==null){var g=t.memoizedProps;if(jl(g,c)&&t.ref===a.ref)if(cn=!1,a.pendingProps=c=g,ah(t,p))(t.flags&131072)!==0&&(cn=!0);else return a.lanes=t.lanes,Ai(t,a,p)}return Yp(t,a,s,c,p)}function bb(t,a,s,c){var p=c.children,g=t!==null?t.memoizedState:null;if(t===null&&a.stateNode===null&&(a.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),c.mode==="hidden"){if((a.flags&128)!==0){if(g=g!==null?g.baseLanes|s:s,t!==null){for(c=a.child=t.child,p=0;c!==null;)p=p|c.lanes|c.childLanes,c=c.sibling;c=p&~g}else c=0,a.child=null;return vb(t,a,g,s,c)}if((s&536870912)!==0)a.memoizedState={baseLanes:0,cachePool:null},t!==null&&uu(a,g!==null?g.cachePool:null),g!==null?wy(a,g):Cp(),Sy(a);else return c=a.lanes=536870912,vb(t,a,g!==null?g.baseLanes|s:s,s,c)}else g!==null?(uu(a,g.cachePool),wy(a,g),ls(),a.memoizedState=null):(t!==null&&uu(a,null),Cp(),ls());return En(t,a,p,s),a.child}function Bl(t,a){return t!==null&&t.tag===22||a.stateNode!==null||(a.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),a.sibling}function vb(t,a,s,c,p){var g=xp();return g=g===null?null:{parent:rn._currentValue,pool:g},a.memoizedState={baseLanes:s,cachePool:g},t!==null&&uu(a,null),Cp(),Sy(a),t!==null&&ar(t,a,c,!0),a.childLanes=p,null}function Cu(t,a){return a=_u({mode:a.mode,children:a.children},t.mode),a.ref=t.ref,t.child=a,a.return=t,a}function xb(t,a,s){return lo(a,t.child,null,s),t=Cu(a,a.pendingProps),t.flags|=2,la(a),a.memoizedState=null,t}function nN(t,a,s){var c=a.pendingProps,p=(a.flags&128)!==0;if(a.flags&=-129,t===null){if(ht){if(c.mode==="hidden")return t=Cu(a,c),a.lanes=536870912,Bl(null,t);if(_p(a),(t=qt)?(t=Dv(t,Ca),t=t!==null&&t.data==="&"?t:null,t!==null&&(a.memoizedState={dehydrated:t,treeContext:es!==null?{id:ii,overflow:si}:null,retryLane:536870912,hydrationErrors:null},s=ay(t),s.return=a,a.child=s,_n=a,qt=null)):t=null,t===null)throw ns(a);return a.lanes=536870912,null}return Cu(a,c)}var g=t.memoizedState;if(g!==null){var w=g.dehydrated;if(_p(a),p)if(a.flags&256)a.flags&=-257,a=xb(t,a,s);else if(a.memoizedState!==null)a.child=t.child,a.flags|=128,a=null;else throw Error(r(558));else if(cn||ar(t,a,s,!1),p=(s&t.childLanes)!==0,cn||p){if(c=Dt,c!==null&&(w=ol(c,s),w!==0&&w!==g.retryLane))throw g.retryLane=w,eo(t,w),Jn(c,t,w),Zp;Pu(),a=xb(t,a,s)}else t=g.treeContext,qt=_a(w.nextSibling),_n=a,ht=!0,ts=null,Ca=!1,t!==null&&oy(a,t),a=Cu(a,c),a.flags|=4096;return a}return t=vi(t.child,{mode:c.mode,children:c.children}),t.ref=a.ref,a.child=t,t.return=a,t}function Nu(t,a){var s=a.ref;if(s===null)t!==null&&t.ref!==null&&(a.flags|=4194816);else{if(typeof s!="function"&&typeof s!="object")throw Error(r(284));(t===null||t.ref!==s)&&(a.flags|=4194816)}}function Yp(t,a,s,c,p){return io(a),s=Ep(t,a,s,c,void 0,p),c=Rp(),t!==null&&!cn?(Dp(t,a,p),Ai(t,a,p)):(ht&&c&&dp(a),a.flags|=1,En(t,a,s,p),a.child)}function wb(t,a,s,c,p,g){return io(a),a.updateQueue=null,s=jy(a,c,s,p),ky(t),c=Rp(),t!==null&&!cn?(Dp(t,a,g),Ai(t,a,g)):(ht&&c&&dp(a),a.flags|=1,En(t,a,s,g),a.child)}function Sb(t,a,s,c,p){if(io(a),a.stateNode===null){var g=Wo,w=s.contextType;typeof w=="object"&&w!==null&&(g=Tn(w)),g=new s(c,g),a.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,g.updater=Qp,a.stateNode=g,g._reactInternals=a,g=a.stateNode,g.props=c,g.state=a.memoizedState,g.refs={},Sp(a),w=s.contextType,g.context=typeof w=="object"&&w!==null?Tn(w):Wo,g.state=a.memoizedState,w=s.getDerivedStateFromProps,typeof w=="function"&&(Hp(a,s,w,c),g.state=a.memoizedState),typeof s.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(w=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),w!==g.state&&Qp.enqueueReplaceState(g,g.state,null),Il(a,c,g,p),zl(),g.state=a.memoizedState),typeof g.componentDidMount=="function"&&(a.flags|=4194308),c=!0}else if(t===null){g=a.stateNode;var A=a.memoizedProps,D=uo(s,A);g.props=D;var U=g.context,te=s.contextType;w=Wo,typeof te=="object"&&te!==null&&(w=Tn(te));var se=s.getDerivedStateFromProps;te=typeof se=="function"||typeof g.getSnapshotBeforeUpdate=="function",A=a.pendingProps!==A,te||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(A||U!==w)&&lb(a,g,c,w),is=!1;var K=a.memoizedState;g.state=K,Il(a,c,g,p),zl(),U=a.memoizedState,A||K!==U||is?(typeof se=="function"&&(Hp(a,s,se,c),U=a.memoizedState),(D=is||rb(a,s,D,c,K,U,w))?(te||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount()),typeof g.componentDidMount=="function"&&(a.flags|=4194308)):(typeof g.componentDidMount=="function"&&(a.flags|=4194308),a.memoizedProps=c,a.memoizedState=U),g.props=c,g.state=U,g.context=w,c=D):(typeof g.componentDidMount=="function"&&(a.flags|=4194308),c=!1)}else{g=a.stateNode,kp(t,a),w=a.memoizedProps,te=uo(s,w),g.props=te,se=a.pendingProps,K=g.context,U=s.contextType,D=Wo,typeof U=="object"&&U!==null&&(D=Tn(U)),A=s.getDerivedStateFromProps,(U=typeof A=="function"||typeof g.getSnapshotBeforeUpdate=="function")||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(w!==se||K!==D)&&lb(a,g,c,D),is=!1,K=a.memoizedState,g.state=K,Il(a,c,g,p),zl();var Q=a.memoizedState;w!==se||K!==Q||is||t!==null&&t.dependencies!==null&&lu(t.dependencies)?(typeof A=="function"&&(Hp(a,s,A,c),Q=a.memoizedState),(te=is||rb(a,s,te,c,K,Q,D)||t!==null&&t.dependencies!==null&&lu(t.dependencies))?(U||typeof g.UNSAFE_componentWillUpdate!="function"&&typeof g.componentWillUpdate!="function"||(typeof g.componentWillUpdate=="function"&&g.componentWillUpdate(c,Q,D),typeof g.UNSAFE_componentWillUpdate=="function"&&g.UNSAFE_componentWillUpdate(c,Q,D)),typeof g.componentDidUpdate=="function"&&(a.flags|=4),typeof g.getSnapshotBeforeUpdate=="function"&&(a.flags|=1024)):(typeof g.componentDidUpdate!="function"||w===t.memoizedProps&&K===t.memoizedState||(a.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||w===t.memoizedProps&&K===t.memoizedState||(a.flags|=1024),a.memoizedProps=c,a.memoizedState=Q),g.props=c,g.state=Q,g.context=D,c=te):(typeof g.componentDidUpdate!="function"||w===t.memoizedProps&&K===t.memoizedState||(a.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||w===t.memoizedProps&&K===t.memoizedState||(a.flags|=1024),c=!1)}return g=c,Nu(t,a),c=(a.flags&128)!==0,g||c?(g=a.stateNode,s=c&&typeof s.getDerivedStateFromError!="function"?null:g.render(),a.flags|=1,t!==null&&c?(a.child=lo(a,t.child,null,p),a.child=lo(a,null,s,p)):En(t,a,s,p),a.memoizedState=g.state,t=a.child):t=Ai(t,a,p),t}function kb(t,a,s,c){return no(),a.flags|=256,En(t,a,s,c),a.child}var Xp={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Jp(t){return{baseLanes:t,cachePool:my()}}function Wp(t,a,s){return t=t!==null?t.childLanes&~s:0,a&&(t|=ua),t}function jb(t,a,s){var c=a.pendingProps,p=!1,g=(a.flags&128)!==0,w;if((w=g)||(w=t!==null&&t.memoizedState===null?!1:(tn.current&2)!==0),w&&(p=!0,a.flags&=-129),w=(a.flags&32)!==0,a.flags&=-33,t===null){if(ht){if(p?rs(a):ls(),(t=qt)?(t=Dv(t,Ca),t=t!==null&&t.data!=="&"?t:null,t!==null&&(a.memoizedState={dehydrated:t,treeContext:es!==null?{id:ii,overflow:si}:null,retryLane:536870912,hydrationErrors:null},s=ay(t),s.return=a,a.child=s,_n=a,qt=null)):t=null,t===null)throw ns(a);return Oh(t)?a.lanes=32:a.lanes=536870912,null}var A=c.children;return c=c.fallback,p?(ls(),p=a.mode,A=_u({mode:"hidden",children:A},p),c=to(c,p,s,null),A.return=a,c.return=a,A.sibling=c,a.child=A,c=a.child,c.memoizedState=Jp(s),c.childLanes=Wp(t,w,s),a.memoizedState=Xp,Bl(null,c)):(rs(a),eh(a,A))}var D=t.memoizedState;if(D!==null&&(A=D.dehydrated,A!==null)){if(g)a.flags&256?(rs(a),a.flags&=-257,a=th(t,a,s)):a.memoizedState!==null?(ls(),a.child=t.child,a.flags|=128,a=null):(ls(),A=c.fallback,p=a.mode,c=_u({mode:"visible",children:c.children},p),A=to(A,p,s,null),A.flags|=2,c.return=a,A.return=a,c.sibling=A,a.child=c,lo(a,t.child,null,s),c=a.child,c.memoizedState=Jp(s),c.childLanes=Wp(t,w,s),a.memoizedState=Xp,a=Bl(null,c));else if(rs(a),Oh(A)){if(w=A.nextSibling&&A.nextSibling.dataset,w)var U=w.dgst;w=U,c=Error(r(419)),c.stack="",c.digest=w,Nl({value:c,source:null,stack:null}),a=th(t,a,s)}else if(cn||ar(t,a,s,!1),w=(s&t.childLanes)!==0,cn||w){if(w=Dt,w!==null&&(c=ol(w,s),c!==0&&c!==D.retryLane))throw D.retryLane=c,eo(t,c),Jn(w,t,c),Zp;Ih(A)||Pu(),a=th(t,a,s)}else Ih(A)?(a.flags|=192,a.child=t.child,a=null):(t=D.treeContext,qt=_a(A.nextSibling),_n=a,ht=!0,ts=null,Ca=!1,t!==null&&oy(a,t),a=eh(a,c.children),a.flags|=4096);return a}return p?(ls(),A=c.fallback,p=a.mode,D=t.child,U=D.sibling,c=vi(D,{mode:"hidden",children:c.children}),c.subtreeFlags=D.subtreeFlags&65011712,U!==null?A=vi(U,A):(A=to(A,p,s,null),A.flags|=2),A.return=a,c.return=a,c.sibling=A,a.child=c,Bl(null,c),c=a.child,A=t.child.memoizedState,A===null?A=Jp(s):(p=A.cachePool,p!==null?(D=rn._currentValue,p=p.parent!==D?{parent:D,pool:D}:p):p=my(),A={baseLanes:A.baseLanes|s,cachePool:p}),c.memoizedState=A,c.childLanes=Wp(t,w,s),a.memoizedState=Xp,Bl(t.child,c)):(rs(a),s=t.child,t=s.sibling,s=vi(s,{mode:"visible",children:c.children}),s.return=a,s.sibling=null,t!==null&&(w=a.deletions,w===null?(a.deletions=[t],a.flags|=16):w.push(t)),a.child=s,a.memoizedState=null,s)}function eh(t,a){return a=_u({mode:"visible",children:a},t.mode),a.return=t,t.child=a}function _u(t,a){return t=oa(22,t,null,a),t.lanes=0,t}function th(t,a,s){return lo(a,t.child,null,s),t=eh(a,a.pendingProps.children),t.flags|=2,a.memoizedState=null,t}function Ab(t,a,s){t.lanes|=a;var c=t.alternate;c!==null&&(c.lanes|=a),gp(t.return,a,s)}function nh(t,a,s,c,p,g){var w=t.memoizedState;w===null?t.memoizedState={isBackwards:a,rendering:null,renderingStartTime:0,last:c,tail:s,tailMode:p,treeForkCount:g}:(w.isBackwards=a,w.rendering=null,w.renderingStartTime=0,w.last=c,w.tail=s,w.tailMode=p,w.treeForkCount=g)}function Cb(t,a,s){var c=a.pendingProps,p=c.revealOrder,g=c.tail;c=c.children;var w=tn.current,A=(w&2)!==0;if(A?(w=w&1|2,a.flags|=128):w&=1,xe(tn,w),En(t,a,c,s),c=ht?Cl:0,!A&&t!==null&&(t.flags&128)!==0)e:for(t=a.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&Ab(t,s,a);else if(t.tag===19)Ab(t,s,a);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===a)break e;for(;t.sibling===null;){if(t.return===null||t.return===a)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(p){case"forwards":for(s=a.child,p=null;s!==null;)t=s.alternate,t!==null&&gu(t)===null&&(p=s),s=s.sibling;s=p,s===null?(p=a.child,a.child=null):(p=s.sibling,s.sibling=null),nh(a,!1,p,s,g,c);break;case"backwards":case"unstable_legacy-backwards":for(s=null,p=a.child,a.child=null;p!==null;){if(t=p.alternate,t!==null&&gu(t)===null){a.child=p;break}t=p.sibling,p.sibling=s,s=p,p=t}nh(a,!0,s,null,g,c);break;case"together":nh(a,!1,null,null,void 0,c);break;default:a.memoizedState=null}return a.child}function Ai(t,a,s){if(t!==null&&(a.dependencies=t.dependencies),ds|=a.lanes,(s&a.childLanes)===0)if(t!==null){if(ar(t,a,s,!1),(s&a.childLanes)===0)return null}else return null;if(t!==null&&a.child!==t.child)throw Error(r(153));if(a.child!==null){for(t=a.child,s=vi(t,t.pendingProps),a.child=s,s.return=a;t.sibling!==null;)t=t.sibling,s=s.sibling=vi(t,t.pendingProps),s.return=a;s.sibling=null}return a.child}function ah(t,a){return(t.lanes&a)!==0?!0:(t=t.dependencies,!!(t!==null&&lu(t)))}function aN(t,a,s){switch(a.tag){case 3:ze(a,a.stateNode.containerInfo),as(a,rn,t.memoizedState.cache),no();break;case 27:case 5:it(a);break;case 4:ze(a,a.stateNode.containerInfo);break;case 10:as(a,a.type,a.memoizedProps.value);break;case 31:if(a.memoizedState!==null)return a.flags|=128,_p(a),null;break;case 13:var c=a.memoizedState;if(c!==null)return c.dehydrated!==null?(rs(a),a.flags|=128,null):(s&a.child.childLanes)!==0?jb(t,a,s):(rs(a),t=Ai(t,a,s),t!==null?t.sibling:null);rs(a);break;case 19:var p=(t.flags&128)!==0;if(c=(s&a.childLanes)!==0,c||(ar(t,a,s,!1),c=(s&a.childLanes)!==0),p){if(c)return Cb(t,a,s);a.flags|=128}if(p=a.memoizedState,p!==null&&(p.rendering=null,p.tail=null,p.lastEffect=null),xe(tn,tn.current),c)break;return null;case 22:return a.lanes=0,bb(t,a,s,a.pendingProps);case 24:as(a,rn,t.memoizedState.cache)}return Ai(t,a,s)}function Nb(t,a,s){if(t!==null)if(t.memoizedProps!==a.pendingProps)cn=!0;else{if(!ah(t,s)&&(a.flags&128)===0)return cn=!1,aN(t,a,s);cn=(t.flags&131072)!==0}else cn=!1,ht&&(a.flags&1048576)!==0&&sy(a,Cl,a.index);switch(a.lanes=0,a.tag){case 16:e:{var c=a.pendingProps;if(t=oo(a.elementType),a.type=t,typeof t=="function")lp(t)?(c=uo(t,c),a.tag=1,a=Sb(null,a,t,c,s)):(a.tag=0,a=Yp(null,a,t,c,s));else{if(t!=null){var p=t.$$typeof;if(p===F){a.tag=11,a=fb(null,a,t,c,s);break e}else if(p===M){a.tag=14,a=gb(null,a,t,c,s);break e}}throw a=Se(t)||t,Error(r(306,a,""))}}return a;case 0:return Yp(t,a,a.type,a.pendingProps,s);case 1:return c=a.type,p=uo(c,a.pendingProps),Sb(t,a,c,p,s);case 3:e:{if(ze(a,a.stateNode.containerInfo),t===null)throw Error(r(387));c=a.pendingProps;var g=a.memoizedState;p=g.element,kp(t,a),Il(a,c,null,s);var w=a.memoizedState;if(c=w.cache,as(a,rn,c),c!==g.cache&&yp(a,[rn],s,!0),zl(),c=w.element,g.isDehydrated)if(g={element:c,isDehydrated:!1,cache:w.cache},a.updateQueue.baseState=g,a.memoizedState=g,a.flags&256){a=kb(t,a,c,s);break e}else if(c!==p){p=ka(Error(r(424)),a),Nl(p),a=kb(t,a,c,s);break e}else for(t=a.stateNode.containerInfo,t.nodeType===9?t=t.body:t=t.nodeName==="HTML"?t.ownerDocument.body:t,qt=_a(t.firstChild),_n=a,ht=!0,ts=null,Ca=!0,s=by(a,null,c,s),a.child=s;s;)s.flags=s.flags&-3|4096,s=s.sibling;else{if(no(),c===p){a=Ai(t,a,s);break e}En(t,a,c,s)}a=a.child}return a;case 26:return Nu(t,a),t===null?(s=Mv(a.type,null,a.pendingProps,null))?a.memoizedState=s:ht||(s=a.type,t=a.pendingProps,c=Gu(H.current).createElement(s),c[on]=a,c[In]=t,Rn(c,s,t),en(c),a.stateNode=c):a.memoizedState=Mv(a.type,t.memoizedProps,a.pendingProps,t.memoizedState),null;case 27:return it(a),t===null&&ht&&(c=a.stateNode=Ov(a.type,a.pendingProps,H.current),_n=a,Ca=!0,p=qt,gs(a.type)?(qh=p,qt=_a(c.firstChild)):qt=p),En(t,a,a.pendingProps.children,s),Nu(t,a),t===null&&(a.flags|=4194304),a.child;case 5:return t===null&&ht&&((p=c=qt)&&(c=zN(c,a.type,a.pendingProps,Ca),c!==null?(a.stateNode=c,_n=a,qt=_a(c.firstChild),Ca=!1,p=!0):p=!1),p||ns(a)),it(a),p=a.type,g=a.pendingProps,w=t!==null?t.memoizedProps:null,c=g.children,Rh(p,g)?c=null:w!==null&&Rh(p,w)&&(a.flags|=32),a.memoizedState!==null&&(p=Ep(t,a,F4,null,null,s),ec._currentValue=p),Nu(t,a),En(t,a,c,s),a.child;case 6:return t===null&&ht&&((t=s=qt)&&(s=IN(s,a.pendingProps,Ca),s!==null?(a.stateNode=s,_n=a,qt=null,t=!0):t=!1),t||ns(a)),null;case 13:return jb(t,a,s);case 4:return ze(a,a.stateNode.containerInfo),c=a.pendingProps,t===null?a.child=lo(a,null,c,s):En(t,a,c,s),a.child;case 11:return fb(t,a,a.type,a.pendingProps,s);case 7:return En(t,a,a.pendingProps,s),a.child;case 8:return En(t,a,a.pendingProps.children,s),a.child;case 12:return En(t,a,a.pendingProps.children,s),a.child;case 10:return c=a.pendingProps,as(a,a.type,c.value),En(t,a,c.children,s),a.child;case 9:return p=a.type._context,c=a.pendingProps.children,io(a),p=Tn(p),c=c(p),a.flags|=1,En(t,a,c,s),a.child;case 14:return gb(t,a,a.type,a.pendingProps,s);case 15:return yb(t,a,a.type,a.pendingProps,s);case 19:return Cb(t,a,s);case 31:return nN(t,a,s);case 22:return bb(t,a,s,a.pendingProps);case 24:return io(a),c=Tn(rn),t===null?(p=xp(),p===null&&(p=Dt,g=bp(),p.pooledCache=g,g.refCount++,g!==null&&(p.pooledCacheLanes|=s),p=g),a.memoizedState={parent:c,cache:p},Sp(a),as(a,rn,p)):((t.lanes&s)!==0&&(kp(t,a),Il(a,null,null,s),zl()),p=t.memoizedState,g=a.memoizedState,p.parent!==c?(p={parent:c,cache:c},a.memoizedState=p,a.lanes===0&&(a.memoizedState=a.updateQueue.baseState=p),as(a,rn,c)):(c=g.cache,as(a,rn,c),c!==p.cache&&yp(a,[rn],s,!0))),En(t,a,a.pendingProps.children,s),a.child;case 29:throw a.pendingProps}throw Error(r(156,a.tag))}function Ci(t){t.flags|=4}function ih(t,a,s,c,p){if((a=(t.mode&32)!==0)&&(a=!1),a){if(t.flags|=16777216,(p&335544128)===p)if(t.stateNode.complete)t.flags|=8192;else if(ev())t.flags|=8192;else throw ro=mu,wp}else t.flags&=-16777217}function _b(t,a){if(a.type!=="stylesheet"||(a.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!Uv(a))if(ev())t.flags|=8192;else throw ro=mu,wp}function Tu(t,a){a!==null&&(t.flags|=4),t.flags&16384&&(a=t.tag!==22?Us():536870912,t.lanes|=a,fr|=a)}function Ll(t,a){if(!ht)switch(t.tailMode){case"hidden":a=t.tail;for(var s=null;a!==null;)a.alternate!==null&&(s=a),a=a.sibling;s===null?t.tail=null:s.sibling=null;break;case"collapsed":s=t.tail;for(var c=null;s!==null;)s.alternate!==null&&(c=s),s=s.sibling;c===null?a||t.tail===null?t.tail=null:t.tail.sibling=null:c.sibling=null}}function Pt(t){var a=t.alternate!==null&&t.alternate.child===t.child,s=0,c=0;if(a)for(var p=t.child;p!==null;)s|=p.lanes|p.childLanes,c|=p.subtreeFlags&65011712,c|=p.flags&65011712,p.return=t,p=p.sibling;else for(p=t.child;p!==null;)s|=p.lanes|p.childLanes,c|=p.subtreeFlags,c|=p.flags,p.return=t,p=p.sibling;return t.subtreeFlags|=c,t.childLanes=s,a}function iN(t,a,s){var c=a.pendingProps;switch(mp(a),a.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Pt(a),null;case 1:return Pt(a),null;case 3:return s=a.stateNode,c=null,t!==null&&(c=t.memoizedState.cache),a.memoizedState.cache!==c&&(a.flags|=2048),Si(rn),je(),s.pendingContext&&(s.context=s.pendingContext,s.pendingContext=null),(t===null||t.child===null)&&(nr(a)?Ci(a):t===null||t.memoizedState.isDehydrated&&(a.flags&256)===0||(a.flags|=1024,hp())),Pt(a),null;case 26:var p=a.type,g=a.memoizedState;return t===null?(Ci(a),g!==null?(Pt(a),_b(a,g)):(Pt(a),ih(a,p,null,c,s))):g?g!==t.memoizedState?(Ci(a),Pt(a),_b(a,g)):(Pt(a),a.flags&=-16777217):(t=t.memoizedProps,t!==c&&Ci(a),Pt(a),ih(a,p,t,c,s)),null;case 27:if(Ue(a),s=H.current,p=a.type,t!==null&&a.stateNode!=null)t.memoizedProps!==c&&Ci(a);else{if(!c){if(a.stateNode===null)throw Error(r(166));return Pt(a),null}t=le.current,nr(a)?ry(a):(t=Ov(p,c,s),a.stateNode=t,Ci(a))}return Pt(a),null;case 5:if(Ue(a),p=a.type,t!==null&&a.stateNode!=null)t.memoizedProps!==c&&Ci(a);else{if(!c){if(a.stateNode===null)throw Error(r(166));return Pt(a),null}if(g=le.current,nr(a))ry(a);else{var w=Gu(H.current);switch(g){case 1:g=w.createElementNS("http://www.w3.org/2000/svg",p);break;case 2:g=w.createElementNS("http://www.w3.org/1998/Math/MathML",p);break;default:switch(p){case"svg":g=w.createElementNS("http://www.w3.org/2000/svg",p);break;case"math":g=w.createElementNS("http://www.w3.org/1998/Math/MathML",p);break;case"script":g=w.createElement("div"),g.innerHTML="<script><\/script>",g=g.removeChild(g.firstChild);break;case"select":g=typeof c.is=="string"?w.createElement("select",{is:c.is}):w.createElement("select"),c.multiple?g.multiple=!0:c.size&&(g.size=c.size);break;default:g=typeof c.is=="string"?w.createElement(p,{is:c.is}):w.createElement(p)}}g[on]=a,g[In]=c;e:for(w=a.child;w!==null;){if(w.tag===5||w.tag===6)g.appendChild(w.stateNode);else if(w.tag!==4&&w.tag!==27&&w.child!==null){w.child.return=w,w=w.child;continue}if(w===a)break e;for(;w.sibling===null;){if(w.return===null||w.return===a)break e;w=w.return}w.sibling.return=w.return,w=w.sibling}a.stateNode=g;e:switch(Rn(g,p,c),p){case"button":case"input":case"select":case"textarea":c=!!c.autoFocus;break e;case"img":c=!0;break e;default:c=!1}c&&Ci(a)}}return Pt(a),ih(a,a.type,t===null?null:t.memoizedProps,a.pendingProps,s),null;case 6:if(t&&a.stateNode!=null)t.memoizedProps!==c&&Ci(a);else{if(typeof c!="string"&&a.stateNode===null)throw Error(r(166));if(t=H.current,nr(a)){if(t=a.stateNode,s=a.memoizedProps,c=null,p=_n,p!==null)switch(p.tag){case 27:case 5:c=p.memoizedProps}t[on]=a,t=!!(t.nodeValue===s||c!==null&&c.suppressHydrationWarning===!0||jv(t.nodeValue,s)),t||ns(a,!0)}else t=Gu(t).createTextNode(c),t[on]=a,a.stateNode=t}return Pt(a),null;case 31:if(s=a.memoizedState,t===null||t.memoizedState!==null){if(c=nr(a),s!==null){if(t===null){if(!c)throw Error(r(318));if(t=a.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(r(557));t[on]=a}else no(),(a.flags&128)===0&&(a.memoizedState=null),a.flags|=4;Pt(a),t=!1}else s=hp(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=s),t=!0;if(!t)return a.flags&256?(la(a),a):(la(a),null);if((a.flags&128)!==0)throw Error(r(558))}return Pt(a),null;case 13:if(c=a.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(p=nr(a),c!==null&&c.dehydrated!==null){if(t===null){if(!p)throw Error(r(318));if(p=a.memoizedState,p=p!==null?p.dehydrated:null,!p)throw Error(r(317));p[on]=a}else no(),(a.flags&128)===0&&(a.memoizedState=null),a.flags|=4;Pt(a),p=!1}else p=hp(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=p),p=!0;if(!p)return a.flags&256?(la(a),a):(la(a),null)}return la(a),(a.flags&128)!==0?(a.lanes=s,a):(s=c!==null,t=t!==null&&t.memoizedState!==null,s&&(c=a.child,p=null,c.alternate!==null&&c.alternate.memoizedState!==null&&c.alternate.memoizedState.cachePool!==null&&(p=c.alternate.memoizedState.cachePool.pool),g=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(g=c.memoizedState.cachePool.pool),g!==p&&(c.flags|=2048)),s!==t&&s&&(a.child.flags|=8192),Tu(a,a.updateQueue),Pt(a),null);case 4:return je(),t===null&&Ch(a.stateNode.containerInfo),Pt(a),null;case 10:return Si(a.type),Pt(a),null;case 19:if(Me(tn),c=a.memoizedState,c===null)return Pt(a),null;if(p=(a.flags&128)!==0,g=c.rendering,g===null)if(p)Ll(c,!1);else{if(Jt!==0||t!==null&&(t.flags&128)!==0)for(t=a.child;t!==null;){if(g=gu(t),g!==null){for(a.flags|=128,Ll(c,!1),t=g.updateQueue,a.updateQueue=t,Tu(a,t),a.subtreeFlags=0,t=s,s=a.child;s!==null;)ny(s,t),s=s.sibling;return xe(tn,tn.current&1|2),ht&&xi(a,c.treeForkCount),a.child}t=t.sibling}c.tail!==null&&$t()>Iu&&(a.flags|=128,p=!0,Ll(c,!1),a.lanes=4194304)}else{if(!p)if(t=gu(g),t!==null){if(a.flags|=128,p=!0,t=t.updateQueue,a.updateQueue=t,Tu(a,t),Ll(c,!0),c.tail===null&&c.tailMode==="hidden"&&!g.alternate&&!ht)return Pt(a),null}else 2*$t()-c.renderingStartTime>Iu&&s!==536870912&&(a.flags|=128,p=!0,Ll(c,!1),a.lanes=4194304);c.isBackwards?(g.sibling=a.child,a.child=g):(t=c.last,t!==null?t.sibling=g:a.child=g,c.last=g)}return c.tail!==null?(t=c.tail,c.rendering=t,c.tail=t.sibling,c.renderingStartTime=$t(),t.sibling=null,s=tn.current,xe(tn,p?s&1|2:s&1),ht&&xi(a,c.treeForkCount),t):(Pt(a),null);case 22:case 23:return la(a),Np(),c=a.memoizedState!==null,t!==null?t.memoizedState!==null!==c&&(a.flags|=8192):c&&(a.flags|=8192),c?(s&536870912)!==0&&(a.flags&128)===0&&(Pt(a),a.subtreeFlags&6&&(a.flags|=8192)):Pt(a),s=a.updateQueue,s!==null&&Tu(a,s.retryQueue),s=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(s=t.memoizedState.cachePool.pool),c=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(c=a.memoizedState.cachePool.pool),c!==s&&(a.flags|=2048),t!==null&&Me(so),null;case 24:return s=null,t!==null&&(s=t.memoizedState.cache),a.memoizedState.cache!==s&&(a.flags|=2048),Si(rn),Pt(a),null;case 25:return null;case 30:return null}throw Error(r(156,a.tag))}function sN(t,a){switch(mp(a),a.tag){case 1:return t=a.flags,t&65536?(a.flags=t&-65537|128,a):null;case 3:return Si(rn),je(),t=a.flags,(t&65536)!==0&&(t&128)===0?(a.flags=t&-65537|128,a):null;case 26:case 27:case 5:return Ue(a),null;case 31:if(a.memoizedState!==null){if(la(a),a.alternate===null)throw Error(r(340));no()}return t=a.flags,t&65536?(a.flags=t&-65537|128,a):null;case 13:if(la(a),t=a.memoizedState,t!==null&&t.dehydrated!==null){if(a.alternate===null)throw Error(r(340));no()}return t=a.flags,t&65536?(a.flags=t&-65537|128,a):null;case 19:return Me(tn),null;case 4:return je(),null;case 10:return Si(a.type),null;case 22:case 23:return la(a),Np(),t!==null&&Me(so),t=a.flags,t&65536?(a.flags=t&-65537|128,a):null;case 24:return Si(rn),null;case 25:return null;default:return null}}function Tb(t,a){switch(mp(a),a.tag){case 3:Si(rn),je();break;case 26:case 27:case 5:Ue(a);break;case 4:je();break;case 31:a.memoizedState!==null&&la(a);break;case 13:la(a);break;case 19:Me(tn);break;case 10:Si(a.type);break;case 22:case 23:la(a),Np(),t!==null&&Me(so);break;case 24:Si(rn)}}function $l(t,a){try{var s=a.updateQueue,c=s!==null?s.lastEffect:null;if(c!==null){var p=c.next;s=p;do{if((s.tag&t)===t){c=void 0;var g=s.create,w=s.inst;c=g(),w.destroy=c}s=s.next}while(s!==p)}}catch(A){Nt(a,a.return,A)}}function cs(t,a,s){try{var c=a.updateQueue,p=c!==null?c.lastEffect:null;if(p!==null){var g=p.next;c=g;do{if((c.tag&t)===t){var w=c.inst,A=w.destroy;if(A!==void 0){w.destroy=void 0,p=a;var D=s,U=A;try{U()}catch(te){Nt(p,D,te)}}}c=c.next}while(c!==g)}}catch(te){Nt(a,a.return,te)}}function Eb(t){var a=t.updateQueue;if(a!==null){var s=t.stateNode;try{xy(a,s)}catch(c){Nt(t,t.return,c)}}}function Rb(t,a,s){s.props=uo(t.type,t.memoizedProps),s.state=t.memoizedState;try{s.componentWillUnmount()}catch(c){Nt(t,a,c)}}function Vl(t,a){try{var s=t.ref;if(s!==null){switch(t.tag){case 26:case 27:case 5:var c=t.stateNode;break;case 30:c=t.stateNode;break;default:c=t.stateNode}typeof s=="function"?t.refCleanup=s(c):s.current=c}}catch(p){Nt(t,a,p)}}function oi(t,a){var s=t.ref,c=t.refCleanup;if(s!==null)if(typeof c=="function")try{c()}catch(p){Nt(t,a,p)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof s=="function")try{s(null)}catch(p){Nt(t,a,p)}else s.current=null}function Db(t){var a=t.type,s=t.memoizedProps,c=t.stateNode;try{e:switch(a){case"button":case"input":case"select":case"textarea":s.autoFocus&&c.focus();break e;case"img":s.src?c.src=s.src:s.srcSet&&(c.srcset=s.srcSet)}}catch(p){Nt(t,t.return,p)}}function sh(t,a,s){try{var c=t.stateNode;NN(c,t.type,s,a),c[In]=a}catch(p){Nt(t,t.return,p)}}function zb(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&gs(t.type)||t.tag===4}function oh(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||zb(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&gs(t.type)||t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function rh(t,a,s){var c=t.tag;if(c===5||c===6)t=t.stateNode,a?(s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s).insertBefore(t,a):(a=s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s,a.appendChild(t),s=s._reactRootContainer,s!=null||a.onclick!==null||(a.onclick=Ba));else if(c!==4&&(c===27&&gs(t.type)&&(s=t.stateNode,a=null),t=t.child,t!==null))for(rh(t,a,s),t=t.sibling;t!==null;)rh(t,a,s),t=t.sibling}function Eu(t,a,s){var c=t.tag;if(c===5||c===6)t=t.stateNode,a?s.insertBefore(t,a):s.appendChild(t);else if(c!==4&&(c===27&&gs(t.type)&&(s=t.stateNode),t=t.child,t!==null))for(Eu(t,a,s),t=t.sibling;t!==null;)Eu(t,a,s),t=t.sibling}function Ib(t){var a=t.stateNode,s=t.memoizedProps;try{for(var c=t.type,p=a.attributes;p.length;)a.removeAttributeNode(p[0]);Rn(a,c,s),a[on]=t,a[In]=s}catch(g){Nt(t,t.return,g)}}var Ni=!1,un=!1,lh=!1,Ob=typeof WeakSet=="function"?WeakSet:Set,vn=null;function oN(t,a){if(t=t.containerInfo,Th=Xu,t=Q1(t),tp(t)){if("selectionStart"in t)var s={start:t.selectionStart,end:t.selectionEnd};else e:{s=(s=t.ownerDocument)&&s.defaultView||window;var c=s.getSelection&&s.getSelection();if(c&&c.rangeCount!==0){s=c.anchorNode;var p=c.anchorOffset,g=c.focusNode;c=c.focusOffset;try{s.nodeType,g.nodeType}catch{s=null;break e}var w=0,A=-1,D=-1,U=0,te=0,se=t,K=null;t:for(;;){for(var Q;se!==s||p!==0&&se.nodeType!==3||(A=w+p),se!==g||c!==0&&se.nodeType!==3||(D=w+c),se.nodeType===3&&(w+=se.nodeValue.length),(Q=se.firstChild)!==null;)K=se,se=Q;for(;;){if(se===t)break t;if(K===s&&++U===p&&(A=w),K===g&&++te===c&&(D=w),(Q=se.nextSibling)!==null)break;se=K,K=se.parentNode}se=Q}s=A===-1||D===-1?null:{start:A,end:D}}else s=null}s=s||{start:0,end:0}}else s=null;for(Eh={focusedElem:t,selectionRange:s},Xu=!1,vn=a;vn!==null;)if(a=vn,t=a.child,(a.subtreeFlags&1028)!==0&&t!==null)t.return=a,vn=t;else for(;vn!==null;){switch(a=vn,g=a.alternate,t=a.flags,a.tag){case 0:if((t&4)!==0&&(t=a.updateQueue,t=t!==null?t.events:null,t!==null))for(s=0;s<t.length;s++)p=t[s],p.ref.impl=p.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&g!==null){t=void 0,s=a,p=g.memoizedProps,g=g.memoizedState,c=s.stateNode;try{var Ae=uo(s.type,p);t=c.getSnapshotBeforeUpdate(Ae,g),c.__reactInternalSnapshotBeforeUpdate=t}catch(Ke){Nt(s,s.return,Ke)}}break;case 3:if((t&1024)!==0){if(t=a.stateNode.containerInfo,s=t.nodeType,s===9)zh(t);else if(s===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":zh(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(r(163))}if(t=a.sibling,t!==null){t.return=a.return,vn=t;break}vn=a.return}}function qb(t,a,s){var c=s.flags;switch(s.tag){case 0:case 11:case 15:Ti(t,s),c&4&&$l(5,s);break;case 1:if(Ti(t,s),c&4)if(t=s.stateNode,a===null)try{t.componentDidMount()}catch(w){Nt(s,s.return,w)}else{var p=uo(s.type,a.memoizedProps);a=a.memoizedState;try{t.componentDidUpdate(p,a,t.__reactInternalSnapshotBeforeUpdate)}catch(w){Nt(s,s.return,w)}}c&64&&Eb(s),c&512&&Vl(s,s.return);break;case 3:if(Ti(t,s),c&64&&(t=s.updateQueue,t!==null)){if(a=null,s.child!==null)switch(s.child.tag){case 27:case 5:a=s.child.stateNode;break;case 1:a=s.child.stateNode}try{xy(t,a)}catch(w){Nt(s,s.return,w)}}break;case 27:a===null&&c&4&&Ib(s);case 26:case 5:Ti(t,s),a===null&&c&4&&Db(s),c&512&&Vl(s,s.return);break;case 12:Ti(t,s);break;case 31:Ti(t,s),c&4&&Bb(t,s);break;case 13:Ti(t,s),c&4&&Lb(t,s),c&64&&(t=s.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(s=fN.bind(null,s),ON(t,s))));break;case 22:if(c=s.memoizedState!==null||Ni,!c){a=a!==null&&a.memoizedState!==null||un,p=Ni;var g=un;Ni=c,(un=a)&&!g?Ei(t,s,(s.subtreeFlags&8772)!==0):Ti(t,s),Ni=p,un=g}break;case 30:break;default:Ti(t,s)}}function Pb(t){var a=t.alternate;a!==null&&(t.alternate=null,Pb(a)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(a=t.stateNode,a!==null&&cl(a)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var Vt=null,Fn=!1;function _i(t,a,s){for(s=s.child;s!==null;)Mb(t,a,s),s=s.sibling}function Mb(t,a,s){if(At&&typeof At.onCommitFiberUnmount=="function")try{At.onCommitFiberUnmount(yn,s)}catch{}switch(s.tag){case 26:un||oi(s,a),_i(t,a,s),s.memoizedState?s.memoizedState.count--:s.stateNode&&(s=s.stateNode,s.parentNode.removeChild(s));break;case 27:un||oi(s,a);var c=Vt,p=Fn;gs(s.type)&&(Vt=s.stateNode,Fn=!1),_i(t,a,s),Xl(s.stateNode),Vt=c,Fn=p;break;case 5:un||oi(s,a);case 6:if(c=Vt,p=Fn,Vt=null,_i(t,a,s),Vt=c,Fn=p,Vt!==null)if(Fn)try{(Vt.nodeType===9?Vt.body:Vt.nodeName==="HTML"?Vt.ownerDocument.body:Vt).removeChild(s.stateNode)}catch(g){Nt(s,a,g)}else try{Vt.removeChild(s.stateNode)}catch(g){Nt(s,a,g)}break;case 18:Vt!==null&&(Fn?(t=Vt,Ev(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,s.stateNode),kr(t)):Ev(Vt,s.stateNode));break;case 4:c=Vt,p=Fn,Vt=s.stateNode.containerInfo,Fn=!0,_i(t,a,s),Vt=c,Fn=p;break;case 0:case 11:case 14:case 15:cs(2,s,a),un||cs(4,s,a),_i(t,a,s);break;case 1:un||(oi(s,a),c=s.stateNode,typeof c.componentWillUnmount=="function"&&Rb(s,a,c)),_i(t,a,s);break;case 21:_i(t,a,s);break;case 22:un=(c=un)||s.memoizedState!==null,_i(t,a,s),un=c;break;default:_i(t,a,s)}}function Bb(t,a){if(a.memoizedState===null&&(t=a.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{kr(t)}catch(s){Nt(a,a.return,s)}}}function Lb(t,a){if(a.memoizedState===null&&(t=a.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{kr(t)}catch(s){Nt(a,a.return,s)}}function rN(t){switch(t.tag){case 31:case 13:case 19:var a=t.stateNode;return a===null&&(a=t.stateNode=new Ob),a;case 22:return t=t.stateNode,a=t._retryCache,a===null&&(a=t._retryCache=new Ob),a;default:throw Error(r(435,t.tag))}}function Ru(t,a){var s=rN(t);a.forEach(function(c){if(!s.has(c)){s.add(c);var p=gN.bind(null,t,c);c.then(p,p)}})}function Zn(t,a){var s=a.deletions;if(s!==null)for(var c=0;c<s.length;c++){var p=s[c],g=t,w=a,A=w;e:for(;A!==null;){switch(A.tag){case 27:if(gs(A.type)){Vt=A.stateNode,Fn=!1;break e}break;case 5:Vt=A.stateNode,Fn=!1;break e;case 3:case 4:Vt=A.stateNode.containerInfo,Fn=!0;break e}A=A.return}if(Vt===null)throw Error(r(160));Mb(g,w,p),Vt=null,Fn=!1,g=p.alternate,g!==null&&(g.return=null),p.return=null}if(a.subtreeFlags&13886)for(a=a.child;a!==null;)$b(a,t),a=a.sibling}var Ua=null;function $b(t,a){var s=t.alternate,c=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:Zn(a,t),Yn(t),c&4&&(cs(3,t,t.return),$l(3,t),cs(5,t,t.return));break;case 1:Zn(a,t),Yn(t),c&512&&(un||s===null||oi(s,s.return)),c&64&&Ni&&(t=t.updateQueue,t!==null&&(c=t.callbacks,c!==null&&(s=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=s===null?c:s.concat(c))));break;case 26:var p=Ua;if(Zn(a,t),Yn(t),c&512&&(un||s===null||oi(s,s.return)),c&4){var g=s!==null?s.memoizedState:null;if(c=t.memoizedState,s===null)if(c===null)if(t.stateNode===null){e:{c=t.type,s=t.memoizedProps,p=p.ownerDocument||p;t:switch(c){case"title":g=p.getElementsByTagName("title")[0],(!g||g[Fi]||g[on]||g.namespaceURI==="http://www.w3.org/2000/svg"||g.hasAttribute("itemprop"))&&(g=p.createElement(c),p.head.insertBefore(g,p.querySelector("head > title"))),Rn(g,c,s),g[on]=t,en(g),c=g;break e;case"link":var w=$v("link","href",p).get(c+(s.href||""));if(w){for(var A=0;A<w.length;A++)if(g=w[A],g.getAttribute("href")===(s.href==null||s.href===""?null:s.href)&&g.getAttribute("rel")===(s.rel==null?null:s.rel)&&g.getAttribute("title")===(s.title==null?null:s.title)&&g.getAttribute("crossorigin")===(s.crossOrigin==null?null:s.crossOrigin)){w.splice(A,1);break t}}g=p.createElement(c),Rn(g,c,s),p.head.appendChild(g);break;case"meta":if(w=$v("meta","content",p).get(c+(s.content||""))){for(A=0;A<w.length;A++)if(g=w[A],g.getAttribute("content")===(s.content==null?null:""+s.content)&&g.getAttribute("name")===(s.name==null?null:s.name)&&g.getAttribute("property")===(s.property==null?null:s.property)&&g.getAttribute("http-equiv")===(s.httpEquiv==null?null:s.httpEquiv)&&g.getAttribute("charset")===(s.charSet==null?null:s.charSet)){w.splice(A,1);break t}}g=p.createElement(c),Rn(g,c,s),p.head.appendChild(g);break;default:throw Error(r(468,c))}g[on]=t,en(g),c=g}t.stateNode=c}else Vv(p,t.type,t.stateNode);else t.stateNode=Lv(p,c,t.memoizedProps);else g!==c?(g===null?s.stateNode!==null&&(s=s.stateNode,s.parentNode.removeChild(s)):g.count--,c===null?Vv(p,t.type,t.stateNode):Lv(p,c,t.memoizedProps)):c===null&&t.stateNode!==null&&sh(t,t.memoizedProps,s.memoizedProps)}break;case 27:Zn(a,t),Yn(t),c&512&&(un||s===null||oi(s,s.return)),s!==null&&c&4&&sh(t,t.memoizedProps,s.memoizedProps);break;case 5:if(Zn(a,t),Yn(t),c&512&&(un||s===null||oi(s,s.return)),t.flags&32){p=t.stateNode;try{va(p,"")}catch(Ae){Nt(t,t.return,Ae)}}c&4&&t.stateNode!=null&&(p=t.memoizedProps,sh(t,p,s!==null?s.memoizedProps:p)),c&1024&&(lh=!0);break;case 6:if(Zn(a,t),Yn(t),c&4){if(t.stateNode===null)throw Error(r(162));c=t.memoizedProps,s=t.stateNode;try{s.nodeValue=c}catch(Ae){Nt(t,t.return,Ae)}}break;case 3:if(Qu=null,p=Ua,Ua=Ku(a.containerInfo),Zn(a,t),Ua=p,Yn(t),c&4&&s!==null&&s.memoizedState.isDehydrated)try{kr(a.containerInfo)}catch(Ae){Nt(t,t.return,Ae)}lh&&(lh=!1,Vb(t));break;case 4:c=Ua,Ua=Ku(t.stateNode.containerInfo),Zn(a,t),Yn(t),Ua=c;break;case 12:Zn(a,t),Yn(t);break;case 31:Zn(a,t),Yn(t),c&4&&(c=t.updateQueue,c!==null&&(t.updateQueue=null,Ru(t,c)));break;case 13:Zn(a,t),Yn(t),t.child.flags&8192&&t.memoizedState!==null!=(s!==null&&s.memoizedState!==null)&&(zu=$t()),c&4&&(c=t.updateQueue,c!==null&&(t.updateQueue=null,Ru(t,c)));break;case 22:p=t.memoizedState!==null;var D=s!==null&&s.memoizedState!==null,U=Ni,te=un;if(Ni=U||p,un=te||D,Zn(a,t),un=te,Ni=U,Yn(t),c&8192)e:for(a=t.stateNode,a._visibility=p?a._visibility&-2:a._visibility|1,p&&(s===null||D||Ni||un||mo(t)),s=null,a=t;;){if(a.tag===5||a.tag===26){if(s===null){D=s=a;try{if(g=D.stateNode,p)w=g.style,typeof w.setProperty=="function"?w.setProperty("display","none","important"):w.display="none";else{A=D.stateNode;var se=D.memoizedProps.style,K=se!=null&&se.hasOwnProperty("display")?se.display:null;A.style.display=K==null||typeof K=="boolean"?"":(""+K).trim()}}catch(Ae){Nt(D,D.return,Ae)}}}else if(a.tag===6){if(s===null){D=a;try{D.stateNode.nodeValue=p?"":D.memoizedProps}catch(Ae){Nt(D,D.return,Ae)}}}else if(a.tag===18){if(s===null){D=a;try{var Q=D.stateNode;p?Rv(Q,!0):Rv(D.stateNode,!1)}catch(Ae){Nt(D,D.return,Ae)}}}else if((a.tag!==22&&a.tag!==23||a.memoizedState===null||a===t)&&a.child!==null){a.child.return=a,a=a.child;continue}if(a===t)break e;for(;a.sibling===null;){if(a.return===null||a.return===t)break e;s===a&&(s=null),a=a.return}s===a&&(s=null),a.sibling.return=a.return,a=a.sibling}c&4&&(c=t.updateQueue,c!==null&&(s=c.retryQueue,s!==null&&(c.retryQueue=null,Ru(t,s))));break;case 19:Zn(a,t),Yn(t),c&4&&(c=t.updateQueue,c!==null&&(t.updateQueue=null,Ru(t,c)));break;case 30:break;case 21:break;default:Zn(a,t),Yn(t)}}function Yn(t){var a=t.flags;if(a&2){try{for(var s,c=t.return;c!==null;){if(zb(c)){s=c;break}c=c.return}if(s==null)throw Error(r(160));switch(s.tag){case 27:var p=s.stateNode,g=oh(t);Eu(t,g,p);break;case 5:var w=s.stateNode;s.flags&32&&(va(w,""),s.flags&=-33);var A=oh(t);Eu(t,A,w);break;case 3:case 4:var D=s.stateNode.containerInfo,U=oh(t);rh(t,U,D);break;default:throw Error(r(161))}}catch(te){Nt(t,t.return,te)}t.flags&=-3}a&4096&&(t.flags&=-4097)}function Vb(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var a=t;Vb(a),a.tag===5&&a.flags&1024&&a.stateNode.reset(),t=t.sibling}}function Ti(t,a){if(a.subtreeFlags&8772)for(a=a.child;a!==null;)qb(t,a.alternate,a),a=a.sibling}function mo(t){for(t=t.child;t!==null;){var a=t;switch(a.tag){case 0:case 11:case 14:case 15:cs(4,a,a.return),mo(a);break;case 1:oi(a,a.return);var s=a.stateNode;typeof s.componentWillUnmount=="function"&&Rb(a,a.return,s),mo(a);break;case 27:Xl(a.stateNode);case 26:case 5:oi(a,a.return),mo(a);break;case 22:a.memoizedState===null&&mo(a);break;case 30:mo(a);break;default:mo(a)}t=t.sibling}}function Ei(t,a,s){for(s=s&&(a.subtreeFlags&8772)!==0,a=a.child;a!==null;){var c=a.alternate,p=t,g=a,w=g.flags;switch(g.tag){case 0:case 11:case 15:Ei(p,g,s),$l(4,g);break;case 1:if(Ei(p,g,s),c=g,p=c.stateNode,typeof p.componentDidMount=="function")try{p.componentDidMount()}catch(U){Nt(c,c.return,U)}if(c=g,p=c.updateQueue,p!==null){var A=c.stateNode;try{var D=p.shared.hiddenCallbacks;if(D!==null)for(p.shared.hiddenCallbacks=null,p=0;p<D.length;p++)vy(D[p],A)}catch(U){Nt(c,c.return,U)}}s&&w&64&&Eb(g),Vl(g,g.return);break;case 27:Ib(g);case 26:case 5:Ei(p,g,s),s&&c===null&&w&4&&Db(g),Vl(g,g.return);break;case 12:Ei(p,g,s);break;case 31:Ei(p,g,s),s&&w&4&&Bb(p,g);break;case 13:Ei(p,g,s),s&&w&4&&Lb(p,g);break;case 22:g.memoizedState===null&&Ei(p,g,s),Vl(g,g.return);break;case 30:break;default:Ei(p,g,s)}a=a.sibling}}function ch(t,a){var s=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(s=t.memoizedState.cachePool.pool),t=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(t=a.memoizedState.cachePool.pool),t!==s&&(t!=null&&t.refCount++,s!=null&&_l(s))}function uh(t,a){t=null,a.alternate!==null&&(t=a.alternate.memoizedState.cache),a=a.memoizedState.cache,a!==t&&(a.refCount++,t!=null&&_l(t))}function Ga(t,a,s,c){if(a.subtreeFlags&10256)for(a=a.child;a!==null;)Ub(t,a,s,c),a=a.sibling}function Ub(t,a,s,c){var p=a.flags;switch(a.tag){case 0:case 11:case 15:Ga(t,a,s,c),p&2048&&$l(9,a);break;case 1:Ga(t,a,s,c);break;case 3:Ga(t,a,s,c),p&2048&&(t=null,a.alternate!==null&&(t=a.alternate.memoizedState.cache),a=a.memoizedState.cache,a!==t&&(a.refCount++,t!=null&&_l(t)));break;case 12:if(p&2048){Ga(t,a,s,c),t=a.stateNode;try{var g=a.memoizedProps,w=g.id,A=g.onPostCommit;typeof A=="function"&&A(w,a.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(D){Nt(a,a.return,D)}}else Ga(t,a,s,c);break;case 31:Ga(t,a,s,c);break;case 13:Ga(t,a,s,c);break;case 23:break;case 22:g=a.stateNode,w=a.alternate,a.memoizedState!==null?g._visibility&2?Ga(t,a,s,c):Ul(t,a):g._visibility&2?Ga(t,a,s,c):(g._visibility|=2,mr(t,a,s,c,(a.subtreeFlags&10256)!==0||!1)),p&2048&&ch(w,a);break;case 24:Ga(t,a,s,c),p&2048&&uh(a.alternate,a);break;default:Ga(t,a,s,c)}}function mr(t,a,s,c,p){for(p=p&&((a.subtreeFlags&10256)!==0||!1),a=a.child;a!==null;){var g=t,w=a,A=s,D=c,U=w.flags;switch(w.tag){case 0:case 11:case 15:mr(g,w,A,D,p),$l(8,w);break;case 23:break;case 22:var te=w.stateNode;w.memoizedState!==null?te._visibility&2?mr(g,w,A,D,p):Ul(g,w):(te._visibility|=2,mr(g,w,A,D,p)),p&&U&2048&&ch(w.alternate,w);break;case 24:mr(g,w,A,D,p),p&&U&2048&&uh(w.alternate,w);break;default:mr(g,w,A,D,p)}a=a.sibling}}function Ul(t,a){if(a.subtreeFlags&10256)for(a=a.child;a!==null;){var s=t,c=a,p=c.flags;switch(c.tag){case 22:Ul(s,c),p&2048&&ch(c.alternate,c);break;case 24:Ul(s,c),p&2048&&uh(c.alternate,c);break;default:Ul(s,c)}a=a.sibling}}var Gl=8192;function pr(t,a,s){if(t.subtreeFlags&Gl)for(t=t.child;t!==null;)Gb(t,a,s),t=t.sibling}function Gb(t,a,s){switch(t.tag){case 26:pr(t,a,s),t.flags&Gl&&t.memoizedState!==null&&QN(s,Ua,t.memoizedState,t.memoizedProps);break;case 5:pr(t,a,s);break;case 3:case 4:var c=Ua;Ua=Ku(t.stateNode.containerInfo),pr(t,a,s),Ua=c;break;case 22:t.memoizedState===null&&(c=t.alternate,c!==null&&c.memoizedState!==null?(c=Gl,Gl=16777216,pr(t,a,s),Gl=c):pr(t,a,s));break;default:pr(t,a,s)}}function Kb(t){var a=t.alternate;if(a!==null&&(t=a.child,t!==null)){a.child=null;do a=t.sibling,t.sibling=null,t=a;while(t!==null)}}function Kl(t){var a=t.deletions;if((t.flags&16)!==0){if(a!==null)for(var s=0;s<a.length;s++){var c=a[s];vn=c,Qb(c,t)}Kb(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Hb(t),t=t.sibling}function Hb(t){switch(t.tag){case 0:case 11:case 15:Kl(t),t.flags&2048&&cs(9,t,t.return);break;case 3:Kl(t);break;case 12:Kl(t);break;case 22:var a=t.stateNode;t.memoizedState!==null&&a._visibility&2&&(t.return===null||t.return.tag!==13)?(a._visibility&=-3,Du(t)):Kl(t);break;default:Kl(t)}}function Du(t){var a=t.deletions;if((t.flags&16)!==0){if(a!==null)for(var s=0;s<a.length;s++){var c=a[s];vn=c,Qb(c,t)}Kb(t)}for(t=t.child;t!==null;){switch(a=t,a.tag){case 0:case 11:case 15:cs(8,a,a.return),Du(a);break;case 22:s=a.stateNode,s._visibility&2&&(s._visibility&=-3,Du(a));break;default:Du(a)}t=t.sibling}}function Qb(t,a){for(;vn!==null;){var s=vn;switch(s.tag){case 0:case 11:case 15:cs(8,s,a);break;case 23:case 22:if(s.memoizedState!==null&&s.memoizedState.cachePool!==null){var c=s.memoizedState.cachePool.pool;c!=null&&c.refCount++}break;case 24:_l(s.memoizedState.cache)}if(c=s.child,c!==null)c.return=s,vn=c;else e:for(s=t;vn!==null;){c=vn;var p=c.sibling,g=c.return;if(Pb(c),c===s){vn=null;break e}if(p!==null){p.return=g,vn=p;break e}vn=g}}}var lN={getCacheForType:function(t){var a=Tn(rn),s=a.data.get(t);return s===void 0&&(s=t(),a.data.set(t,s)),s},cacheSignal:function(){return Tn(rn).controller.signal}},cN=typeof WeakMap=="function"?WeakMap:Map,wt=0,Dt=null,rt=null,ut=0,Ct=0,ca=null,us=!1,hr=!1,dh=!1,Ri=0,Jt=0,ds=0,po=0,mh=0,ua=0,fr=0,Hl=null,Xn=null,ph=!1,zu=0,Fb=0,Iu=1/0,Ou=null,ms=null,mn=0,ps=null,gr=null,Di=0,hh=0,fh=null,Zb=null,Ql=0,gh=null;function da(){return(wt&2)!==0&&ut!==0?ut&-ut:q.T!==null?Sh():Lo()}function Yb(){if(ua===0)if((ut&536870912)===0||ht){var t=Ye;Ye<<=1,(Ye&3932160)===0&&(Ye=262144),ua=t}else ua=536870912;return t=ra.current,t!==null&&(t.flags|=32),ua}function Jn(t,a,s){(t===Dt&&(Ct===2||Ct===9)||t.cancelPendingCommit!==null)&&(yr(t,0),hs(t,ut,ua,!1)),Gs(t,s),((wt&2)===0||t!==Dt)&&(t===Dt&&((wt&2)===0&&(po|=s),Jt===4&&hs(t,ut,ua,!1)),ri(t))}function Xb(t,a,s){if((wt&6)!==0)throw Error(r(327));var c=!s&&(a&127)===0&&(a&t.expiredLanes)===0||Wt(t,a),p=c?mN(t,a):bh(t,a,!0),g=c;do{if(p===0){hr&&!c&&hs(t,a,0,!1);break}else{if(s=t.current.alternate,g&&!uN(s)){p=bh(t,a,!1),g=!1;continue}if(p===2){if(g=a,t.errorRecoveryDisabledLanes&g)var w=0;else w=t.pendingLanes&-536870913,w=w!==0?w:w&536870912?536870912:0;if(w!==0){a=w;e:{var A=t;p=Hl;var D=A.current.memoizedState.isDehydrated;if(D&&(yr(A,w).flags|=256),w=bh(A,w,!1),w!==2){if(dh&&!D){A.errorRecoveryDisabledLanes|=g,po|=g,p=4;break e}g=Xn,Xn=p,g!==null&&(Xn===null?Xn=g:Xn.push.apply(Xn,g))}p=w}if(g=!1,p!==2)continue}}if(p===1){yr(t,0),hs(t,a,0,!0);break}e:{switch(c=t,g=p,g){case 0:case 1:throw Error(r(345));case 4:if((a&4194048)!==a)break;case 6:hs(c,a,ua,!us);break e;case 2:Xn=null;break;case 3:case 5:break;default:throw Error(r(329))}if((a&62914560)===a&&(p=zu+300-$t(),10<p)){if(hs(c,a,ua,!us),et(c,0,!0)!==0)break e;Di=a,c.timeoutHandle=_v(Jb.bind(null,c,s,Xn,Ou,ph,a,ua,po,fr,us,g,"Throttled",-0,0),p);break e}Jb(c,s,Xn,Ou,ph,a,ua,po,fr,us,g,null,-0,0)}}break}while(!0);ri(t)}function Jb(t,a,s,c,p,g,w,A,D,U,te,se,K,Q){if(t.timeoutHandle=-1,se=a.subtreeFlags,se&8192||(se&16785408)===16785408){se={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Ba},Gb(a,g,se);var Ae=(g&62914560)===g?zu-$t():(g&4194048)===g?Fb-$t():0;if(Ae=FN(se,Ae),Ae!==null){Di=g,t.cancelPendingCommit=Ae(ov.bind(null,t,a,g,s,c,p,w,A,D,te,se,null,K,Q)),hs(t,g,w,!U);return}}ov(t,a,g,s,c,p,w,A,D)}function uN(t){for(var a=t;;){var s=a.tag;if((s===0||s===11||s===15)&&a.flags&16384&&(s=a.updateQueue,s!==null&&(s=s.stores,s!==null)))for(var c=0;c<s.length;c++){var p=s[c],g=p.getSnapshot;p=p.value;try{if(!sa(g(),p))return!1}catch{return!1}}if(s=a.child,a.subtreeFlags&16384&&s!==null)s.return=a,a=s;else{if(a===t)break;for(;a.sibling===null;){if(a.return===null||a.return===t)return!0;a=a.return}a.sibling.return=a.return,a=a.sibling}}return!0}function hs(t,a,s,c){a&=~mh,a&=~po,t.suspendedLanes|=a,t.pingedLanes&=~a,c&&(t.warmLanes|=a),c=t.expirationTimes;for(var p=a;0<p;){var g=31-An(p),w=1<<g;c[g]=-1,p&=~w}s!==0&&il(t,s,a)}function qu(){return(wt&6)===0?(Fl(0),!1):!0}function yh(){if(rt!==null){if(Ct===0)var t=rt.return;else t=rt,wi=ao=null,zp(t),rr=null,El=0,t=rt;for(;t!==null;)Tb(t.alternate,t),t=t.return;rt=null}}function yr(t,a){var s=t.timeoutHandle;s!==-1&&(t.timeoutHandle=-1,EN(s)),s=t.cancelPendingCommit,s!==null&&(t.cancelPendingCommit=null,s()),Di=0,yh(),Dt=t,rt=s=vi(t.current,null),ut=a,Ct=0,ca=null,us=!1,hr=Wt(t,a),dh=!1,fr=ua=mh=po=ds=Jt=0,Xn=Hl=null,ph=!1,(a&8)!==0&&(a|=a&32);var c=t.entangledLanes;if(c!==0)for(t=t.entanglements,c&=a;0<c;){var p=31-An(c),g=1<<p;a|=t[p],c&=~g}return Ri=a,au(),s}function Wb(t,a){Je=null,q.H=Ml,a===or||a===du?(a=fy(),Ct=3):a===wp?(a=fy(),Ct=4):Ct=a===Zp?8:a!==null&&typeof a=="object"&&typeof a.then=="function"?6:1,ca=a,rt===null&&(Jt=1,Au(t,ka(a,t.current)))}function ev(){var t=ra.current;return t===null?!0:(ut&4194048)===ut?Na===null:(ut&62914560)===ut||(ut&536870912)!==0?t===Na:!1}function tv(){var t=q.H;return q.H=Ml,t===null?Ml:t}function nv(){var t=q.A;return q.A=lN,t}function Pu(){Jt=4,us||(ut&4194048)!==ut&&ra.current!==null||(hr=!0),(ds&134217727)===0&&(po&134217727)===0||Dt===null||hs(Dt,ut,ua,!1)}function bh(t,a,s){var c=wt;wt|=2;var p=tv(),g=nv();(Dt!==t||ut!==a)&&(Ou=null,yr(t,a)),a=!1;var w=Jt;e:do try{if(Ct!==0&&rt!==null){var A=rt,D=ca;switch(Ct){case 8:yh(),w=6;break e;case 3:case 2:case 9:case 6:ra.current===null&&(a=!0);var U=Ct;if(Ct=0,ca=null,br(t,A,D,U),s&&hr){w=0;break e}break;default:U=Ct,Ct=0,ca=null,br(t,A,D,U)}}dN(),w=Jt;break}catch(te){Wb(t,te)}while(!0);return a&&t.shellSuspendCounter++,wi=ao=null,wt=c,q.H=p,q.A=g,rt===null&&(Dt=null,ut=0,au()),w}function dN(){for(;rt!==null;)av(rt)}function mN(t,a){var s=wt;wt|=2;var c=tv(),p=nv();Dt!==t||ut!==a?(Ou=null,Iu=$t()+500,yr(t,a)):hr=Wt(t,a);e:do try{if(Ct!==0&&rt!==null){a=rt;var g=ca;t:switch(Ct){case 1:Ct=0,ca=null,br(t,a,g,1);break;case 2:case 9:if(py(g)){Ct=0,ca=null,iv(a);break}a=function(){Ct!==2&&Ct!==9||Dt!==t||(Ct=7),ri(t)},g.then(a,a);break e;case 3:Ct=7;break e;case 4:Ct=5;break e;case 7:py(g)?(Ct=0,ca=null,iv(a)):(Ct=0,ca=null,br(t,a,g,7));break;case 5:var w=null;switch(rt.tag){case 26:w=rt.memoizedState;case 5:case 27:var A=rt;if(w?Uv(w):A.stateNode.complete){Ct=0,ca=null;var D=A.sibling;if(D!==null)rt=D;else{var U=A.return;U!==null?(rt=U,Mu(U)):rt=null}break t}}Ct=0,ca=null,br(t,a,g,5);break;case 6:Ct=0,ca=null,br(t,a,g,6);break;case 8:yh(),Jt=6;break e;default:throw Error(r(462))}}pN();break}catch(te){Wb(t,te)}while(!0);return wi=ao=null,q.H=c,q.A=p,wt=s,rt!==null?0:(Dt=null,ut=0,au(),Jt)}function pN(){for(;rt!==null&&!Qt();)av(rt)}function av(t){var a=Nb(t.alternate,t,Ri);t.memoizedProps=t.pendingProps,a===null?Mu(t):rt=a}function iv(t){var a=t,s=a.alternate;switch(a.tag){case 15:case 0:a=wb(s,a,a.pendingProps,a.type,void 0,ut);break;case 11:a=wb(s,a,a.pendingProps,a.type.render,a.ref,ut);break;case 5:zp(a);default:Tb(s,a),a=rt=ny(a,Ri),a=Nb(s,a,Ri)}t.memoizedProps=t.pendingProps,a===null?Mu(t):rt=a}function br(t,a,s,c){wi=ao=null,zp(a),rr=null,El=0;var p=a.return;try{if(tN(t,p,a,s,ut)){Jt=1,Au(t,ka(s,t.current)),rt=null;return}}catch(g){if(p!==null)throw rt=p,g;Jt=1,Au(t,ka(s,t.current)),rt=null;return}a.flags&32768?(ht||c===1?t=!0:hr||(ut&536870912)!==0?t=!1:(us=t=!0,(c===2||c===9||c===3||c===6)&&(c=ra.current,c!==null&&c.tag===13&&(c.flags|=16384))),sv(a,t)):Mu(a)}function Mu(t){var a=t;do{if((a.flags&32768)!==0){sv(a,us);return}t=a.return;var s=iN(a.alternate,a,Ri);if(s!==null){rt=s;return}if(a=a.sibling,a!==null){rt=a;return}rt=a=t}while(a!==null);Jt===0&&(Jt=5)}function sv(t,a){do{var s=sN(t.alternate,t);if(s!==null){s.flags&=32767,rt=s;return}if(s=t.return,s!==null&&(s.flags|=32768,s.subtreeFlags=0,s.deletions=null),!a&&(t=t.sibling,t!==null)){rt=t;return}rt=t=s}while(t!==null);Jt=6,rt=null}function ov(t,a,s,c,p,g,w,A,D){t.cancelPendingCommit=null;do Bu();while(mn!==0);if((wt&6)!==0)throw Error(r(327));if(a!==null){if(a===t.current)throw Error(r(177));if(g=a.lanes|a.childLanes,g|=op,Fc(t,s,g,w,A,D),t===Dt&&(rt=Dt=null,ut=0),gr=a,ps=t,Di=s,hh=g,fh=p,Zb=c,(a.subtreeFlags&10256)!==0||(a.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,yN(pi,function(){return dv(),null})):(t.callbackNode=null,t.callbackPriority=0),c=(a.flags&13878)!==0,(a.subtreeFlags&13878)!==0||c){c=q.T,q.T=null,p=X.p,X.p=2,w=wt,wt|=4;try{oN(t,a,s)}finally{wt=w,X.p=p,q.T=c}}mn=1,rv(),lv(),cv()}}function rv(){if(mn===1){mn=0;var t=ps,a=gr,s=(a.flags&13878)!==0;if((a.subtreeFlags&13878)!==0||s){s=q.T,q.T=null;var c=X.p;X.p=2;var p=wt;wt|=4;try{$b(a,t);var g=Eh,w=Q1(t.containerInfo),A=g.focusedElem,D=g.selectionRange;if(w!==A&&A&&A.ownerDocument&&H1(A.ownerDocument.documentElement,A)){if(D!==null&&tp(A)){var U=D.start,te=D.end;if(te===void 0&&(te=U),"selectionStart"in A)A.selectionStart=U,A.selectionEnd=Math.min(te,A.value.length);else{var se=A.ownerDocument||document,K=se&&se.defaultView||window;if(K.getSelection){var Q=K.getSelection(),Ae=A.textContent.length,Ke=Math.min(D.start,Ae),Rt=D.end===void 0?Ke:Math.min(D.end,Ae);!Q.extend&&Ke>Rt&&(w=Rt,Rt=Ke,Ke=w);var B=K1(A,Ke),O=K1(A,Rt);if(B&&O&&(Q.rangeCount!==1||Q.anchorNode!==B.node||Q.anchorOffset!==B.offset||Q.focusNode!==O.node||Q.focusOffset!==O.offset)){var V=se.createRange();V.setStart(B.node,B.offset),Q.removeAllRanges(),Ke>Rt?(Q.addRange(V),Q.extend(O.node,O.offset)):(V.setEnd(O.node,O.offset),Q.addRange(V))}}}}for(se=[],Q=A;Q=Q.parentNode;)Q.nodeType===1&&se.push({element:Q,left:Q.scrollLeft,top:Q.scrollTop});for(typeof A.focus=="function"&&A.focus(),A=0;A<se.length;A++){var ie=se[A];ie.element.scrollLeft=ie.left,ie.element.scrollTop=ie.top}}Xu=!!Th,Eh=Th=null}finally{wt=p,X.p=c,q.T=s}}t.current=a,mn=2}}function lv(){if(mn===2){mn=0;var t=ps,a=gr,s=(a.flags&8772)!==0;if((a.subtreeFlags&8772)!==0||s){s=q.T,q.T=null;var c=X.p;X.p=2;var p=wt;wt|=4;try{qb(t,a.alternate,a)}finally{wt=p,X.p=c,q.T=s}}mn=3}}function cv(){if(mn===4||mn===3){mn=0,zn();var t=ps,a=gr,s=Di,c=Zb;(a.subtreeFlags&10256)!==0||(a.flags&10256)!==0?mn=5:(mn=0,gr=ps=null,uv(t,t.pendingLanes));var p=t.pendingLanes;if(p===0&&(ms=null),ll(s),a=a.stateNode,At&&typeof At.onCommitFiberRoot=="function")try{At.onCommitFiberRoot(yn,a,void 0,(a.current.flags&128)===128)}catch{}if(c!==null){a=q.T,p=X.p,X.p=2,q.T=null;try{for(var g=t.onRecoverableError,w=0;w<c.length;w++){var A=c[w];g(A.value,{componentStack:A.stack})}}finally{q.T=a,X.p=p}}(Di&3)!==0&&Bu(),ri(t),p=t.pendingLanes,(s&261930)!==0&&(p&42)!==0?t===gh?Ql++:(Ql=0,gh=t):Ql=0,Fl(0)}}function uv(t,a){(t.pooledCacheLanes&=a)===0&&(a=t.pooledCache,a!=null&&(t.pooledCache=null,_l(a)))}function Bu(){return rv(),lv(),cv(),dv()}function dv(){if(mn!==5)return!1;var t=ps,a=hh;hh=0;var s=ll(Di),c=q.T,p=X.p;try{X.p=32>s?32:s,q.T=null,s=fh,fh=null;var g=ps,w=Di;if(mn=0,gr=ps=null,Di=0,(wt&6)!==0)throw Error(r(331));var A=wt;if(wt|=4,Hb(g.current),Ub(g,g.current,w,s),wt=A,Fl(0,!1),At&&typeof At.onPostCommitFiberRoot=="function")try{At.onPostCommitFiberRoot(yn,g)}catch{}return!0}finally{X.p=p,q.T=c,uv(t,a)}}function mv(t,a,s){a=ka(s,a),a=Fp(t.stateNode,a,2),t=os(t,a,2),t!==null&&(Gs(t,2),ri(t))}function Nt(t,a,s){if(t.tag===3)mv(t,t,s);else for(;a!==null;){if(a.tag===3){mv(a,t,s);break}else if(a.tag===1){var c=a.stateNode;if(typeof a.type.getDerivedStateFromError=="function"||typeof c.componentDidCatch=="function"&&(ms===null||!ms.has(c))){t=ka(s,t),s=pb(2),c=os(a,s,2),c!==null&&(hb(s,c,a,t),Gs(c,2),ri(c));break}}a=a.return}}function vh(t,a,s){var c=t.pingCache;if(c===null){c=t.pingCache=new cN;var p=new Set;c.set(a,p)}else p=c.get(a),p===void 0&&(p=new Set,c.set(a,p));p.has(s)||(dh=!0,p.add(s),t=hN.bind(null,t,a,s),a.then(t,t))}function hN(t,a,s){var c=t.pingCache;c!==null&&c.delete(a),t.pingedLanes|=t.suspendedLanes&s,t.warmLanes&=~s,Dt===t&&(ut&s)===s&&(Jt===4||Jt===3&&(ut&62914560)===ut&&300>$t()-zu?(wt&2)===0&&yr(t,0):mh|=s,fr===ut&&(fr=0)),ri(t)}function pv(t,a){a===0&&(a=Us()),t=eo(t,a),t!==null&&(Gs(t,a),ri(t))}function fN(t){var a=t.memoizedState,s=0;a!==null&&(s=a.retryLane),pv(t,s)}function gN(t,a){var s=0;switch(t.tag){case 31:case 13:var c=t.stateNode,p=t.memoizedState;p!==null&&(s=p.retryLane);break;case 19:c=t.stateNode;break;case 22:c=t.stateNode._retryCache;break;default:throw Error(r(314))}c!==null&&c.delete(a),pv(t,s)}function yN(t,a){return ct(t,a)}var Lu=null,vr=null,xh=!1,$u=!1,wh=!1,fs=0;function ri(t){t!==vr&&t.next===null&&(vr===null?Lu=vr=t:vr=vr.next=t),$u=!0,xh||(xh=!0,vN())}function Fl(t,a){if(!wh&&$u){wh=!0;do for(var s=!1,c=Lu;c!==null;){if(t!==0){var p=c.pendingLanes;if(p===0)var g=0;else{var w=c.suspendedLanes,A=c.pingedLanes;g=(1<<31-An(42|t)+1)-1,g&=p&~(w&~A),g=g&201326741?g&201326741|1:g?g|2:0}g!==0&&(s=!0,yv(c,g))}else g=ut,g=et(c,c===Dt?g:0,c.cancelPendingCommit!==null||c.timeoutHandle!==-1),(g&3)===0||Wt(c,g)||(s=!0,yv(c,g));c=c.next}while(s);wh=!1}}function bN(){hv()}function hv(){$u=xh=!1;var t=0;fs!==0&&TN()&&(t=fs);for(var a=$t(),s=null,c=Lu;c!==null;){var p=c.next,g=fv(c,a);g===0?(c.next=null,s===null?Lu=p:s.next=p,p===null&&(vr=s)):(s=c,(t!==0||(g&3)!==0)&&($u=!0)),c=p}mn!==0&&mn!==5||Fl(t),fs!==0&&(fs=0)}function fv(t,a){for(var s=t.suspendedLanes,c=t.pingedLanes,p=t.expirationTimes,g=t.pendingLanes&-62914561;0<g;){var w=31-An(g),A=1<<w,D=p[w];D===-1?((A&s)===0||(A&c)!==0)&&(p[w]=Xa(A,a)):D<=a&&(t.expiredLanes|=A),g&=~A}if(a=Dt,s=ut,s=et(t,t===a?s:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),c=t.callbackNode,s===0||t===a&&(Ct===2||Ct===9)||t.cancelPendingCommit!==null)return c!==null&&c!==null&&Ht(c),t.callbackNode=null,t.callbackPriority=0;if((s&3)===0||Wt(t,s)){if(a=s&-s,a===t.callbackPriority)return a;switch(c!==null&&Ht(c),ll(s)){case 2:case 8:s=Hn;break;case 32:s=pi;break;case 268435456:s=Ki;break;default:s=pi}return c=gv.bind(null,t),s=ct(s,c),t.callbackPriority=a,t.callbackNode=s,a}return c!==null&&c!==null&&Ht(c),t.callbackPriority=2,t.callbackNode=null,2}function gv(t,a){if(mn!==0&&mn!==5)return t.callbackNode=null,t.callbackPriority=0,null;var s=t.callbackNode;if(Bu()&&t.callbackNode!==s)return null;var c=ut;return c=et(t,t===Dt?c:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),c===0?null:(Xb(t,c,a),fv(t,$t()),t.callbackNode!=null&&t.callbackNode===s?gv.bind(null,t):null)}function yv(t,a){if(Bu())return null;Xb(t,a,!0)}function vN(){RN(function(){(wt&6)!==0?ct(Bs,bN):hv()})}function Sh(){if(fs===0){var t=ir;t===0&&(t=Ie,Ie<<=1,(Ie&261888)===0&&(Ie=256)),fs=t}return fs}function bv(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:Ho(""+t)}function vv(t,a){var s=a.ownerDocument.createElement("input");return s.name=a.name,s.value=a.value,t.id&&s.setAttribute("form",t.id),a.parentNode.insertBefore(s,a),t=new FormData(t),s.parentNode.removeChild(s),t}function xN(t,a,s,c,p){if(a==="submit"&&s&&s.stateNode===p){var g=bv((p[In]||null).action),w=c.submitter;w&&(a=(a=w[In]||null)?bv(a.formAction):w.getAttribute("formAction"),a!==null&&(g=a,w=null));var A=new Zs("action","action",null,c,p);t.push({event:A,listeners:[{instance:null,listener:function(){if(c.defaultPrevented){if(fs!==0){var D=w?vv(p,w):new FormData(p);Vp(s,{pending:!0,data:D,method:p.method,action:g},null,D)}}else typeof g=="function"&&(A.preventDefault(),D=w?vv(p,w):new FormData(p),Vp(s,{pending:!0,data:D,method:p.method,action:g},g,D))},currentTarget:p}]})}}for(var kh=0;kh<sp.length;kh++){var jh=sp[kh],wN=jh.toLowerCase(),SN=jh[0].toUpperCase()+jh.slice(1);Va(wN,"on"+SN)}Va(Y1,"onAnimationEnd"),Va(X1,"onAnimationIteration"),Va(J1,"onAnimationStart"),Va("dblclick","onDoubleClick"),Va("focusin","onFocus"),Va("focusout","onBlur"),Va(M4,"onTransitionRun"),Va(B4,"onTransitionStart"),Va(L4,"onTransitionCancel"),Va(W1,"onTransitionEnd"),Ks("onMouseEnter",["mouseout","mouseover"]),Ks("onMouseLeave",["mouseout","mouseover"]),Ks("onPointerEnter",["pointerout","pointerover"]),Ks("onPointerLeave",["pointerout","pointerover"]),Ja("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ja("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ja("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ja("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ja("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ja("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Zl="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),kN=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Zl));function xv(t,a){a=(a&4)!==0;for(var s=0;s<t.length;s++){var c=t[s],p=c.event;c=c.listeners;e:{var g=void 0;if(a)for(var w=c.length-1;0<=w;w--){var A=c[w],D=A.instance,U=A.currentTarget;if(A=A.listener,D!==g&&p.isPropagationStopped())break e;g=A,p.currentTarget=U;try{g(p)}catch(te){nu(te)}p.currentTarget=null,g=D}else for(w=0;w<c.length;w++){if(A=c[w],D=A.instance,U=A.currentTarget,A=A.listener,D!==g&&p.isPropagationStopped())break e;g=A,p.currentTarget=U;try{g(p)}catch(te){nu(te)}p.currentTarget=null,g=D}}}}function lt(t,a){var s=a[$o];s===void 0&&(s=a[$o]=new Set);var c=t+"__bubble";s.has(c)||(wv(a,t,2,!1),s.add(c))}function Ah(t,a,s){var c=0;a&&(c|=4),wv(s,t,c,a)}var Vu="_reactListening"+Math.random().toString(36).slice(2);function Ch(t){if(!t[Vu]){t[Vu]=!0,ul.forEach(function(s){s!=="selectionchange"&&(kN.has(s)||Ah(s,!1,t),Ah(s,!0,t))});var a=t.nodeType===9?t:t.ownerDocument;a===null||a[Vu]||(a[Vu]=!0,Ah("selectionchange",!1,a))}}function wv(t,a,s,c){switch(Yv(a)){case 2:var p=XN;break;case 8:p=JN;break;default:p=$h}s=p.bind(null,a,s,t),p=void 0,!vl||a!=="touchstart"&&a!=="touchmove"&&a!=="wheel"||(p=!0),c?p!==void 0?t.addEventListener(a,s,{capture:!0,passive:p}):t.addEventListener(a,s,!0):p!==void 0?t.addEventListener(a,s,{passive:p}):t.addEventListener(a,s,!1)}function Nh(t,a,s,c,p){var g=c;if((a&1)===0&&(a&2)===0&&c!==null)e:for(;;){if(c===null)return;var w=c.tag;if(w===3||w===4){var A=c.stateNode.containerInfo;if(A===p)break;if(w===4)for(w=c.return;w!==null;){var D=w.tag;if((D===3||D===4)&&w.stateNode.containerInfo===p)return;w=w.return}for(;A!==null;){if(w=hi(A),w===null)return;if(D=w.tag,D===5||D===6||D===26||D===27){c=g=w;continue e}A=A.parentNode}}c=c.return}Jc(function(){var U=g,te=yl(s),se=[];e:{var K=ey.get(t);if(K!==void 0){var Q=Zs,Ae=t;switch(t){case"keypress":if(La(s)===0)break e;case"keydown":case"keyup":Q=g4;break;case"focusin":Ae="focus",Q=Ym;break;case"focusout":Ae="blur",Q=Ym;break;case"beforeblur":case"afterblur":Q=Ym;break;case"click":if(s.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":Q=T1;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":Q=i4;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":Q=v4;break;case Y1:case X1:case J1:Q=r4;break;case W1:Q=w4;break;case"scroll":case"scrollend":Q=Xs;break;case"wheel":Q=k4;break;case"copy":case"cut":case"paste":Q=c4;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":Q=R1;break;case"toggle":case"beforetoggle":Q=A4}var Ke=(a&4)!==0,Rt=!Ke&&(t==="scroll"||t==="scrollend"),B=Ke?K!==null?K+"Capture":null:K;Ke=[];for(var O=U,V;O!==null;){var ie=O;if(V=ie.stateNode,ie=ie.tag,ie!==5&&ie!==26&&ie!==27||V===null||B===null||(ie=Qs(O,B),ie!=null&&Ke.push(Yl(O,ie,V))),Rt)break;O=O.return}0<Ke.length&&(K=new Q(K,Ae,null,s,te),se.push({event:K,listeners:Ke}))}}if((a&7)===0){e:{if(K=t==="mouseover"||t==="pointerover",Q=t==="mouseout"||t==="pointerout",K&&s!==gl&&(Ae=s.relatedTarget||s.fromElement)&&(hi(Ae)||Ae[Qi]))break e;if((Q||K)&&(K=te.window===te?te:(K=te.ownerDocument)?K.defaultView||K.parentWindow:window,Q?(Ae=s.relatedTarget||s.toElement,Q=U,Ae=Ae?hi(Ae):null,Ae!==null&&(Rt=h(Ae),Ke=Ae.tag,Ae!==Rt||Ke!==5&&Ke!==27&&Ke!==6)&&(Ae=null)):(Q=null,Ae=U),Q!==Ae)){if(Ke=T1,ie="onMouseLeave",B="onMouseEnter",O="mouse",(t==="pointerout"||t==="pointerover")&&(Ke=R1,ie="onPointerLeave",B="onPointerEnter",O="pointer"),Rt=Q==null?K:Yi(Q),V=Ae==null?K:Yi(Ae),K=new Ke(ie,O+"leave",Q,s,te),K.target=Rt,K.relatedTarget=V,ie=null,hi(te)===U&&(Ke=new Ke(B,O+"enter",Ae,s,te),Ke.target=V,Ke.relatedTarget=Rt,ie=Ke),Rt=ie,Q&&Ae)t:{for(Ke=jN,B=Q,O=Ae,V=0,ie=B;ie;ie=Ke(ie))V++;ie=0;for(var $e=O;$e;$e=Ke($e))ie++;for(;0<V-ie;)B=Ke(B),V--;for(;0<ie-V;)O=Ke(O),ie--;for(;V--;){if(B===O||O!==null&&B===O.alternate){Ke=B;break t}B=Ke(B),O=Ke(O)}Ke=null}else Ke=null;Q!==null&&Sv(se,K,Q,Ke,!1),Ae!==null&&Rt!==null&&Sv(se,Rt,Ae,Ke,!0)}}e:{if(K=U?Yi(U):window,Q=K.nodeName&&K.nodeName.toLowerCase(),Q==="select"||Q==="input"&&K.type==="file")var bt=B1;else if(P1(K))if(L1)bt=O4;else{bt=z4;var Te=D4}else Q=K.nodeName,!Q||Q.toLowerCase()!=="input"||K.type!=="checkbox"&&K.type!=="radio"?U&&Ma(U.elementType)&&(bt=B1):bt=I4;if(bt&&(bt=bt(t,U))){M1(se,bt,s,te);break e}Te&&Te(t,K,U),t==="focusout"&&U&&K.type==="number"&&U.memoizedProps.value!=null&&Go(K,"number",K.value)}switch(Te=U?Yi(U):window,t){case"focusin":(P1(Te)||Te.contentEditable==="true")&&(Yo=Te,np=U,Al=null);break;case"focusout":Al=np=Yo=null;break;case"mousedown":ap=!0;break;case"contextmenu":case"mouseup":case"dragend":ap=!1,F1(se,s,te);break;case"selectionchange":if(P4)break;case"keydown":case"keyup":F1(se,s,te)}var tt;if(Jm)e:{switch(t){case"compositionstart":var dt="onCompositionStart";break e;case"compositionend":dt="onCompositionEnd";break e;case"compositionupdate":dt="onCompositionUpdate";break e}dt=void 0}else Zo?O1(t,s)&&(dt="onCompositionEnd"):t==="keydown"&&s.keyCode===229&&(dt="onCompositionStart");dt&&(D1&&s.locale!=="ko"&&(Zo||dt!=="onCompositionStart"?dt==="onCompositionEnd"&&Zo&&(tt=bi()):(ni=te,G="value"in ni?ni.value:ni.textContent,Zo=!0)),Te=Uu(U,dt),0<Te.length&&(dt=new E1(dt,t,null,s,te),se.push({event:dt,listeners:Te}),tt?dt.data=tt:(tt=q1(s),tt!==null&&(dt.data=tt)))),(tt=N4?_4(t,s):T4(t,s))&&(dt=Uu(U,"onBeforeInput"),0<dt.length&&(Te=new E1("onBeforeInput","beforeinput",null,s,te),se.push({event:Te,listeners:dt}),Te.data=tt)),xN(se,t,U,s,te)}xv(se,a)})}function Yl(t,a,s){return{instance:t,listener:a,currentTarget:s}}function Uu(t,a){for(var s=a+"Capture",c=[];t!==null;){var p=t,g=p.stateNode;if(p=p.tag,p!==5&&p!==26&&p!==27||g===null||(p=Qs(t,s),p!=null&&c.unshift(Yl(t,p,g)),p=Qs(t,a),p!=null&&c.push(Yl(t,p,g))),t.tag===3)return c;t=t.return}return[]}function jN(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function Sv(t,a,s,c,p){for(var g=a._reactName,w=[];s!==null&&s!==c;){var A=s,D=A.alternate,U=A.stateNode;if(A=A.tag,D!==null&&D===c)break;A!==5&&A!==26&&A!==27||U===null||(D=U,p?(U=Qs(s,g),U!=null&&w.unshift(Yl(s,U,D))):p||(U=Qs(s,g),U!=null&&w.push(Yl(s,U,D)))),s=s.return}w.length!==0&&t.push({event:a,listeners:w})}var AN=/\r\n?/g,CN=/\u0000|\uFFFD/g;function kv(t){return(typeof t=="string"?t:""+t).replace(AN,`
|
|
10
|
+
`).replace(CN,"")}function jv(t,a){return a=kv(a),kv(t)===a}function Et(t,a,s,c,p,g){switch(s){case"children":typeof c=="string"?a==="body"||a==="textarea"&&c===""||va(t,c):(typeof c=="number"||typeof c=="bigint")&&a!=="body"&&va(t,""+c);break;case"className":Hs(t,"class",c);break;case"tabIndex":Hs(t,"tabindex",c);break;case"dir":case"role":case"viewBox":case"width":case"height":Hs(t,s,c);break;case"style":ti(t,c,g);break;case"data":if(a!=="object"){Hs(t,"data",c);break}case"src":case"href":if(c===""&&(a!=="a"||s!=="href")){t.removeAttribute(s);break}if(c==null||typeof c=="function"||typeof c=="symbol"||typeof c=="boolean"){t.removeAttribute(s);break}c=Ho(""+c),t.setAttribute(s,c);break;case"action":case"formAction":if(typeof c=="function"){t.setAttribute(s,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof g=="function"&&(s==="formAction"?(a!=="input"&&Et(t,a,"name",p.name,p,null),Et(t,a,"formEncType",p.formEncType,p,null),Et(t,a,"formMethod",p.formMethod,p,null),Et(t,a,"formTarget",p.formTarget,p,null)):(Et(t,a,"encType",p.encType,p,null),Et(t,a,"method",p.method,p,null),Et(t,a,"target",p.target,p,null)));if(c==null||typeof c=="symbol"||typeof c=="boolean"){t.removeAttribute(s);break}c=Ho(""+c),t.setAttribute(s,c);break;case"onClick":c!=null&&(t.onclick=Ba);break;case"onScroll":c!=null&<("scroll",t);break;case"onScrollEnd":c!=null&<("scrollend",t);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(r(61));if(s=c.__html,s!=null){if(p.children!=null)throw Error(r(60));t.innerHTML=s}}break;case"multiple":t.multiple=c&&typeof c!="function"&&typeof c!="symbol";break;case"muted":t.muted=c&&typeof c!="function"&&typeof c!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(c==null||typeof c=="function"||typeof c=="boolean"||typeof c=="symbol"){t.removeAttribute("xlink:href");break}s=Ho(""+c),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",s);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":c!=null&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(s,""+c):t.removeAttribute(s);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":c&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(s,""):t.removeAttribute(s);break;case"capture":case"download":c===!0?t.setAttribute(s,""):c!==!1&&c!=null&&typeof c!="function"&&typeof c!="symbol"?t.setAttribute(s,c):t.removeAttribute(s);break;case"cols":case"rows":case"size":case"span":c!=null&&typeof c!="function"&&typeof c!="symbol"&&!isNaN(c)&&1<=c?t.setAttribute(s,c):t.removeAttribute(s);break;case"rowSpan":case"start":c==null||typeof c=="function"||typeof c=="symbol"||isNaN(c)?t.removeAttribute(s):t.setAttribute(s,c);break;case"popover":lt("beforetoggle",t),lt("toggle",t),fi(t,"popover",c);break;case"xlinkActuate":Cn(t,"http://www.w3.org/1999/xlink","xlink:actuate",c);break;case"xlinkArcrole":Cn(t,"http://www.w3.org/1999/xlink","xlink:arcrole",c);break;case"xlinkRole":Cn(t,"http://www.w3.org/1999/xlink","xlink:role",c);break;case"xlinkShow":Cn(t,"http://www.w3.org/1999/xlink","xlink:show",c);break;case"xlinkTitle":Cn(t,"http://www.w3.org/1999/xlink","xlink:title",c);break;case"xlinkType":Cn(t,"http://www.w3.org/1999/xlink","xlink:type",c);break;case"xmlBase":Cn(t,"http://www.w3.org/XML/1998/namespace","xml:base",c);break;case"xmlLang":Cn(t,"http://www.w3.org/XML/1998/namespace","xml:lang",c);break;case"xmlSpace":Cn(t,"http://www.w3.org/XML/1998/namespace","xml:space",c);break;case"is":fi(t,"is",c);break;case"innerText":case"textContent":break;default:(!(2<s.length)||s[0]!=="o"&&s[0]!=="O"||s[1]!=="n"&&s[1]!=="N")&&(s=Ko.get(s)||s,fi(t,s,c))}}function _h(t,a,s,c,p,g){switch(s){case"style":ti(t,c,g);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(r(61));if(s=c.__html,s!=null){if(p.children!=null)throw Error(r(60));t.innerHTML=s}}break;case"children":typeof c=="string"?va(t,c):(typeof c=="number"||typeof c=="bigint")&&va(t,""+c);break;case"onScroll":c!=null&<("scroll",t);break;case"onScrollEnd":c!=null&<("scrollend",t);break;case"onClick":c!=null&&(t.onclick=Ba);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!dl.hasOwnProperty(s))e:{if(s[0]==="o"&&s[1]==="n"&&(p=s.endsWith("Capture"),a=s.slice(2,p?s.length-7:void 0),g=t[In]||null,g=g!=null?g[s]:null,typeof g=="function"&&t.removeEventListener(a,g,p),typeof c=="function")){typeof g!="function"&&g!==null&&(s in t?t[s]=null:t.hasAttribute(s)&&t.removeAttribute(s)),t.addEventListener(a,c,p);break e}s in t?t[s]=c:c===!0?t.setAttribute(s,""):fi(t,s,c)}}}function Rn(t,a,s){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":lt("error",t),lt("load",t);var c=!1,p=!1,g;for(g in s)if(s.hasOwnProperty(g)){var w=s[g];if(w!=null)switch(g){case"src":c=!0;break;case"srcSet":p=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,a));default:Et(t,a,g,w,s,null)}}p&&Et(t,a,"srcSet",s.srcSet,s,null),c&&Et(t,a,"src",s.src,s,null);return;case"input":lt("invalid",t);var A=g=w=p=null,D=null,U=null;for(c in s)if(s.hasOwnProperty(c)){var te=s[c];if(te!=null)switch(c){case"name":p=te;break;case"type":w=te;break;case"checked":D=te;break;case"defaultChecked":U=te;break;case"value":g=te;break;case"defaultValue":A=te;break;case"children":case"dangerouslySetInnerHTML":if(te!=null)throw Error(r(137,a));break;default:Et(t,a,c,te,s,null)}}fl(t,g,A,D,U,w,p,!1);return;case"select":lt("invalid",t),c=w=g=null;for(p in s)if(s.hasOwnProperty(p)&&(A=s[p],A!=null))switch(p){case"value":g=A;break;case"defaultValue":w=A;break;case"multiple":c=A;default:Et(t,a,p,A,s,null)}a=g,s=w,t.multiple=!!c,a!=null?Qn(t,!!c,a,!1):s!=null&&Qn(t,!!c,s,!0);return;case"textarea":lt("invalid",t),g=p=c=null;for(w in s)if(s.hasOwnProperty(w)&&(A=s[w],A!=null))switch(w){case"value":c=A;break;case"defaultValue":p=A;break;case"children":g=A;break;case"dangerouslySetInnerHTML":if(A!=null)throw Error(r(91));break;default:Et(t,a,w,A,s,null)}gi(t,c,p,g);return;case"option":for(D in s)s.hasOwnProperty(D)&&(c=s[D],c!=null)&&(D==="selected"?t.selected=c&&typeof c!="function"&&typeof c!="symbol":Et(t,a,D,c,s,null));return;case"dialog":lt("beforetoggle",t),lt("toggle",t),lt("cancel",t),lt("close",t);break;case"iframe":case"object":lt("load",t);break;case"video":case"audio":for(c=0;c<Zl.length;c++)lt(Zl[c],t);break;case"image":lt("error",t),lt("load",t);break;case"details":lt("toggle",t);break;case"embed":case"source":case"link":lt("error",t),lt("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(U in s)if(s.hasOwnProperty(U)&&(c=s[U],c!=null))switch(U){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,a));default:Et(t,a,U,c,s,null)}return;default:if(Ma(a)){for(te in s)s.hasOwnProperty(te)&&(c=s[te],c!==void 0&&_h(t,a,te,c,s,void 0));return}}for(A in s)s.hasOwnProperty(A)&&(c=s[A],c!=null&&Et(t,a,A,c,s,null))}function NN(t,a,s,c){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var p=null,g=null,w=null,A=null,D=null,U=null,te=null;for(Q in s){var se=s[Q];if(s.hasOwnProperty(Q)&&se!=null)switch(Q){case"checked":break;case"value":break;case"defaultValue":D=se;default:c.hasOwnProperty(Q)||Et(t,a,Q,null,c,se)}}for(var K in c){var Q=c[K];if(se=s[K],c.hasOwnProperty(K)&&(Q!=null||se!=null))switch(K){case"type":g=Q;break;case"name":p=Q;break;case"checked":U=Q;break;case"defaultChecked":te=Q;break;case"value":w=Q;break;case"defaultValue":A=Q;break;case"children":case"dangerouslySetInnerHTML":if(Q!=null)throw Error(r(137,a));break;default:Q!==se&&Et(t,a,K,Q,c,se)}}Uo(t,w,A,D,U,te,g,p);return;case"select":Q=w=A=K=null;for(g in s)if(D=s[g],s.hasOwnProperty(g)&&D!=null)switch(g){case"value":break;case"multiple":Q=D;default:c.hasOwnProperty(g)||Et(t,a,g,null,c,D)}for(p in c)if(g=c[p],D=s[p],c.hasOwnProperty(p)&&(g!=null||D!=null))switch(p){case"value":K=g;break;case"defaultValue":A=g;break;case"multiple":w=g;default:g!==D&&Et(t,a,p,g,c,D)}a=A,s=w,c=Q,K!=null?Qn(t,!!s,K,!1):!!c!=!!s&&(a!=null?Qn(t,!!s,a,!0):Qn(t,!!s,s?[]:"",!1));return;case"textarea":Q=K=null;for(A in s)if(p=s[A],s.hasOwnProperty(A)&&p!=null&&!c.hasOwnProperty(A))switch(A){case"value":break;case"children":break;default:Et(t,a,A,null,c,p)}for(w in c)if(p=c[w],g=s[w],c.hasOwnProperty(w)&&(p!=null||g!=null))switch(w){case"value":K=p;break;case"defaultValue":Q=p;break;case"children":break;case"dangerouslySetInnerHTML":if(p!=null)throw Error(r(91));break;default:p!==g&&Et(t,a,w,p,c,g)}ia(t,K,Q);return;case"option":for(var Ae in s)K=s[Ae],s.hasOwnProperty(Ae)&&K!=null&&!c.hasOwnProperty(Ae)&&(Ae==="selected"?t.selected=!1:Et(t,a,Ae,null,c,K));for(D in c)K=c[D],Q=s[D],c.hasOwnProperty(D)&&K!==Q&&(K!=null||Q!=null)&&(D==="selected"?t.selected=K&&typeof K!="function"&&typeof K!="symbol":Et(t,a,D,K,c,Q));return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Ke in s)K=s[Ke],s.hasOwnProperty(Ke)&&K!=null&&!c.hasOwnProperty(Ke)&&Et(t,a,Ke,null,c,K);for(U in c)if(K=c[U],Q=s[U],c.hasOwnProperty(U)&&K!==Q&&(K!=null||Q!=null))switch(U){case"children":case"dangerouslySetInnerHTML":if(K!=null)throw Error(r(137,a));break;default:Et(t,a,U,K,c,Q)}return;default:if(Ma(a)){for(var Rt in s)K=s[Rt],s.hasOwnProperty(Rt)&&K!==void 0&&!c.hasOwnProperty(Rt)&&_h(t,a,Rt,void 0,c,K);for(te in c)K=c[te],Q=s[te],!c.hasOwnProperty(te)||K===Q||K===void 0&&Q===void 0||_h(t,a,te,K,c,Q);return}}for(var B in s)K=s[B],s.hasOwnProperty(B)&&K!=null&&!c.hasOwnProperty(B)&&Et(t,a,B,null,c,K);for(se in c)K=c[se],Q=s[se],!c.hasOwnProperty(se)||K===Q||K==null&&Q==null||Et(t,a,se,K,c,Q)}function Av(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function _N(){if(typeof performance.getEntriesByType=="function"){for(var t=0,a=0,s=performance.getEntriesByType("resource"),c=0;c<s.length;c++){var p=s[c],g=p.transferSize,w=p.initiatorType,A=p.duration;if(g&&A&&Av(w)){for(w=0,A=p.responseEnd,c+=1;c<s.length;c++){var D=s[c],U=D.startTime;if(U>A)break;var te=D.transferSize,se=D.initiatorType;te&&Av(se)&&(D=D.responseEnd,w+=te*(D<A?1:(A-U)/(D-U)))}if(--c,a+=8*(g+w)/(p.duration/1e3),t++,10<t)break}}if(0<t)return a/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t=="number")?t:5}var Th=null,Eh=null;function Gu(t){return t.nodeType===9?t:t.ownerDocument}function Cv(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Nv(t,a){if(t===0)switch(a){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&a==="foreignObject"?0:t}function Rh(t,a){return t==="textarea"||t==="noscript"||typeof a.children=="string"||typeof a.children=="number"||typeof a.children=="bigint"||typeof a.dangerouslySetInnerHTML=="object"&&a.dangerouslySetInnerHTML!==null&&a.dangerouslySetInnerHTML.__html!=null}var Dh=null;function TN(){var t=window.event;return t&&t.type==="popstate"?t===Dh?!1:(Dh=t,!0):(Dh=null,!1)}var _v=typeof setTimeout=="function"?setTimeout:void 0,EN=typeof clearTimeout=="function"?clearTimeout:void 0,Tv=typeof Promise=="function"?Promise:void 0,RN=typeof queueMicrotask=="function"?queueMicrotask:typeof Tv<"u"?function(t){return Tv.resolve(null).then(t).catch(DN)}:_v;function DN(t){setTimeout(function(){throw t})}function gs(t){return t==="head"}function Ev(t,a){var s=a,c=0;do{var p=s.nextSibling;if(t.removeChild(s),p&&p.nodeType===8)if(s=p.data,s==="/$"||s==="/&"){if(c===0){t.removeChild(p),kr(a);return}c--}else if(s==="$"||s==="$?"||s==="$~"||s==="$!"||s==="&")c++;else if(s==="html")Xl(t.ownerDocument.documentElement);else if(s==="head"){s=t.ownerDocument.head,Xl(s);for(var g=s.firstChild;g;){var w=g.nextSibling,A=g.nodeName;g[Fi]||A==="SCRIPT"||A==="STYLE"||A==="LINK"&&g.rel.toLowerCase()==="stylesheet"||s.removeChild(g),g=w}}else s==="body"&&Xl(t.ownerDocument.body);s=p}while(s);kr(a)}function Rv(t,a){var s=t;t=0;do{var c=s.nextSibling;if(s.nodeType===1?a?(s._stashedDisplay=s.style.display,s.style.display="none"):(s.style.display=s._stashedDisplay||"",s.getAttribute("style")===""&&s.removeAttribute("style")):s.nodeType===3&&(a?(s._stashedText=s.nodeValue,s.nodeValue=""):s.nodeValue=s._stashedText||""),c&&c.nodeType===8)if(s=c.data,s==="/$"){if(t===0)break;t--}else s!=="$"&&s!=="$?"&&s!=="$~"&&s!=="$!"||t++;s=c}while(s)}function zh(t){var a=t.firstChild;for(a&&a.nodeType===10&&(a=a.nextSibling);a;){var s=a;switch(a=a.nextSibling,s.nodeName){case"HTML":case"HEAD":case"BODY":zh(s),cl(s);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(s.rel.toLowerCase()==="stylesheet")continue}t.removeChild(s)}}function zN(t,a,s,c){for(;t.nodeType===1;){var p=s;if(t.nodeName.toLowerCase()!==a.toLowerCase()){if(!c&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(c){if(!t[Fi])switch(a){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(g=t.getAttribute("rel"),g==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(g!==p.rel||t.getAttribute("href")!==(p.href==null||p.href===""?null:p.href)||t.getAttribute("crossorigin")!==(p.crossOrigin==null?null:p.crossOrigin)||t.getAttribute("title")!==(p.title==null?null:p.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(g=t.getAttribute("src"),(g!==(p.src==null?null:p.src)||t.getAttribute("type")!==(p.type==null?null:p.type)||t.getAttribute("crossorigin")!==(p.crossOrigin==null?null:p.crossOrigin))&&g&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(a==="input"&&t.type==="hidden"){var g=p.name==null?null:""+p.name;if(p.type==="hidden"&&t.getAttribute("name")===g)return t}else return t;if(t=_a(t.nextSibling),t===null)break}return null}function IN(t,a,s){if(a==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!s||(t=_a(t.nextSibling),t===null))return null;return t}function Dv(t,a){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!a||(t=_a(t.nextSibling),t===null))return null;return t}function Ih(t){return t.data==="$?"||t.data==="$~"}function Oh(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function ON(t,a){var s=t.ownerDocument;if(t.data==="$~")t._reactRetry=a;else if(t.data!=="$?"||s.readyState!=="loading")a();else{var c=function(){a(),s.removeEventListener("DOMContentLoaded",c)};s.addEventListener("DOMContentLoaded",c),t._reactRetry=c}}function _a(t){for(;t!=null;t=t.nextSibling){var a=t.nodeType;if(a===1||a===3)break;if(a===8){if(a=t.data,a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"||a==="F!"||a==="F")break;if(a==="/$"||a==="/&")return null}}return t}var qh=null;function zv(t){t=t.nextSibling;for(var a=0;t;){if(t.nodeType===8){var s=t.data;if(s==="/$"||s==="/&"){if(a===0)return _a(t.nextSibling);a--}else s!=="$"&&s!=="$!"&&s!=="$?"&&s!=="$~"&&s!=="&"||a++}t=t.nextSibling}return null}function Iv(t){t=t.previousSibling;for(var a=0;t;){if(t.nodeType===8){var s=t.data;if(s==="$"||s==="$!"||s==="$?"||s==="$~"||s==="&"){if(a===0)return t;a--}else s!=="/$"&&s!=="/&"||a++}t=t.previousSibling}return null}function Ov(t,a,s){switch(a=Gu(s),t){case"html":if(t=a.documentElement,!t)throw Error(r(452));return t;case"head":if(t=a.head,!t)throw Error(r(453));return t;case"body":if(t=a.body,!t)throw Error(r(454));return t;default:throw Error(r(451))}}function Xl(t){for(var a=t.attributes;a.length;)t.removeAttributeNode(a[0]);cl(t)}var Ta=new Map,qv=new Set;function Ku(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var zi=X.d;X.d={f:qN,r:PN,D:MN,C:BN,L:LN,m:$N,X:UN,S:VN,M:GN};function qN(){var t=zi.f(),a=qu();return t||a}function PN(t){var a=Zi(t);a!==null&&a.tag===5&&a.type==="form"?Wy(a):zi.r(t)}var xr=typeof document>"u"?null:document;function Pv(t,a,s){var c=xr;if(c&&typeof a=="string"&&a){var p=qn(a);p='link[rel="'+t+'"][href="'+p+'"]',typeof s=="string"&&(p+='[crossorigin="'+s+'"]'),qv.has(p)||(qv.add(p),t={rel:t,crossOrigin:s,href:a},c.querySelector(p)===null&&(a=c.createElement("link"),Rn(a,"link",t),en(a),c.head.appendChild(a)))}}function MN(t){zi.D(t),Pv("dns-prefetch",t,null)}function BN(t,a){zi.C(t,a),Pv("preconnect",t,a)}function LN(t,a,s){zi.L(t,a,s);var c=xr;if(c&&t&&a){var p='link[rel="preload"][as="'+qn(a)+'"]';a==="image"&&s&&s.imageSrcSet?(p+='[imagesrcset="'+qn(s.imageSrcSet)+'"]',typeof s.imageSizes=="string"&&(p+='[imagesizes="'+qn(s.imageSizes)+'"]')):p+='[href="'+qn(t)+'"]';var g=p;switch(a){case"style":g=wr(t);break;case"script":g=Sr(t)}Ta.has(g)||(t=k({rel:"preload",href:a==="image"&&s&&s.imageSrcSet?void 0:t,as:a},s),Ta.set(g,t),c.querySelector(p)!==null||a==="style"&&c.querySelector(Jl(g))||a==="script"&&c.querySelector(Wl(g))||(a=c.createElement("link"),Rn(a,"link",t),en(a),c.head.appendChild(a)))}}function $N(t,a){zi.m(t,a);var s=xr;if(s&&t){var c=a&&typeof a.as=="string"?a.as:"script",p='link[rel="modulepreload"][as="'+qn(c)+'"][href="'+qn(t)+'"]',g=p;switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":g=Sr(t)}if(!Ta.has(g)&&(t=k({rel:"modulepreload",href:t},a),Ta.set(g,t),s.querySelector(p)===null)){switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(s.querySelector(Wl(g)))return}c=s.createElement("link"),Rn(c,"link",t),en(c),s.head.appendChild(c)}}}function VN(t,a,s){zi.S(t,a,s);var c=xr;if(c&&t){var p=Xi(c).hoistableStyles,g=wr(t);a=a||"default";var w=p.get(g);if(!w){var A={loading:0,preload:null};if(w=c.querySelector(Jl(g)))A.loading=5;else{t=k({rel:"stylesheet",href:t,"data-precedence":a},s),(s=Ta.get(g))&&Ph(t,s);var D=w=c.createElement("link");en(D),Rn(D,"link",t),D._p=new Promise(function(U,te){D.onload=U,D.onerror=te}),D.addEventListener("load",function(){A.loading|=1}),D.addEventListener("error",function(){A.loading|=2}),A.loading|=4,Hu(w,a,c)}w={type:"stylesheet",instance:w,count:1,state:A},p.set(g,w)}}}function UN(t,a){zi.X(t,a);var s=xr;if(s&&t){var c=Xi(s).hoistableScripts,p=Sr(t),g=c.get(p);g||(g=s.querySelector(Wl(p)),g||(t=k({src:t,async:!0},a),(a=Ta.get(p))&&Mh(t,a),g=s.createElement("script"),en(g),Rn(g,"link",t),s.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},c.set(p,g))}}function GN(t,a){zi.M(t,a);var s=xr;if(s&&t){var c=Xi(s).hoistableScripts,p=Sr(t),g=c.get(p);g||(g=s.querySelector(Wl(p)),g||(t=k({src:t,async:!0,type:"module"},a),(a=Ta.get(p))&&Mh(t,a),g=s.createElement("script"),en(g),Rn(g,"link",t),s.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},c.set(p,g))}}function Mv(t,a,s,c){var p=(p=H.current)?Ku(p):null;if(!p)throw Error(r(446));switch(t){case"meta":case"title":return null;case"style":return typeof s.precedence=="string"&&typeof s.href=="string"?(a=wr(s.href),s=Xi(p).hoistableStyles,c=s.get(a),c||(c={type:"style",instance:null,count:0,state:null},s.set(a,c)),c):{type:"void",instance:null,count:0,state:null};case"link":if(s.rel==="stylesheet"&&typeof s.href=="string"&&typeof s.precedence=="string"){t=wr(s.href);var g=Xi(p).hoistableStyles,w=g.get(t);if(w||(p=p.ownerDocument||p,w={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},g.set(t,w),(g=p.querySelector(Jl(t)))&&!g._p&&(w.instance=g,w.state.loading=5),Ta.has(t)||(s={rel:"preload",as:"style",href:s.href,crossOrigin:s.crossOrigin,integrity:s.integrity,media:s.media,hrefLang:s.hrefLang,referrerPolicy:s.referrerPolicy},Ta.set(t,s),g||KN(p,t,s,w.state))),a&&c===null)throw Error(r(528,""));return w}if(a&&c!==null)throw Error(r(529,""));return null;case"script":return a=s.async,s=s.src,typeof s=="string"&&a&&typeof a!="function"&&typeof a!="symbol"?(a=Sr(s),s=Xi(p).hoistableScripts,c=s.get(a),c||(c={type:"script",instance:null,count:0,state:null},s.set(a,c)),c):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,t))}}function wr(t){return'href="'+qn(t)+'"'}function Jl(t){return'link[rel="stylesheet"]['+t+"]"}function Bv(t){return k({},t,{"data-precedence":t.precedence,precedence:null})}function KN(t,a,s,c){t.querySelector('link[rel="preload"][as="style"]['+a+"]")?c.loading=1:(a=t.createElement("link"),c.preload=a,a.addEventListener("load",function(){return c.loading|=1}),a.addEventListener("error",function(){return c.loading|=2}),Rn(a,"link",s),en(a),t.head.appendChild(a))}function Sr(t){return'[src="'+qn(t)+'"]'}function Wl(t){return"script[async]"+t}function Lv(t,a,s){if(a.count++,a.instance===null)switch(a.type){case"style":var c=t.querySelector('style[data-href~="'+qn(s.href)+'"]');if(c)return a.instance=c,en(c),c;var p=k({},s,{"data-href":s.href,"data-precedence":s.precedence,href:null,precedence:null});return c=(t.ownerDocument||t).createElement("style"),en(c),Rn(c,"style",p),Hu(c,s.precedence,t),a.instance=c;case"stylesheet":p=wr(s.href);var g=t.querySelector(Jl(p));if(g)return a.state.loading|=4,a.instance=g,en(g),g;c=Bv(s),(p=Ta.get(p))&&Ph(c,p),g=(t.ownerDocument||t).createElement("link"),en(g);var w=g;return w._p=new Promise(function(A,D){w.onload=A,w.onerror=D}),Rn(g,"link",c),a.state.loading|=4,Hu(g,s.precedence,t),a.instance=g;case"script":return g=Sr(s.src),(p=t.querySelector(Wl(g)))?(a.instance=p,en(p),p):(c=s,(p=Ta.get(g))&&(c=k({},s),Mh(c,p)),t=t.ownerDocument||t,p=t.createElement("script"),en(p),Rn(p,"link",c),t.head.appendChild(p),a.instance=p);case"void":return null;default:throw Error(r(443,a.type))}else a.type==="stylesheet"&&(a.state.loading&4)===0&&(c=a.instance,a.state.loading|=4,Hu(c,s.precedence,t));return a.instance}function Hu(t,a,s){for(var c=s.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),p=c.length?c[c.length-1]:null,g=p,w=0;w<c.length;w++){var A=c[w];if(A.dataset.precedence===a)g=A;else if(g!==p)break}g?g.parentNode.insertBefore(t,g.nextSibling):(a=s.nodeType===9?s.head:s,a.insertBefore(t,a.firstChild))}function Ph(t,a){t.crossOrigin==null&&(t.crossOrigin=a.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=a.referrerPolicy),t.title==null&&(t.title=a.title)}function Mh(t,a){t.crossOrigin==null&&(t.crossOrigin=a.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=a.referrerPolicy),t.integrity==null&&(t.integrity=a.integrity)}var Qu=null;function $v(t,a,s){if(Qu===null){var c=new Map,p=Qu=new Map;p.set(s,c)}else p=Qu,c=p.get(s),c||(c=new Map,p.set(s,c));if(c.has(t))return c;for(c.set(t,null),s=s.getElementsByTagName(t),p=0;p<s.length;p++){var g=s[p];if(!(g[Fi]||g[on]||t==="link"&&g.getAttribute("rel")==="stylesheet")&&g.namespaceURI!=="http://www.w3.org/2000/svg"){var w=g.getAttribute(a)||"";w=t+w;var A=c.get(w);A?A.push(g):c.set(w,[g])}}return c}function Vv(t,a,s){t=t.ownerDocument||t,t.head.insertBefore(s,a==="title"?t.querySelector("head > title"):null)}function HN(t,a,s){if(s===1||a.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof a.precedence!="string"||typeof a.href!="string"||a.href==="")break;return!0;case"link":if(typeof a.rel!="string"||typeof a.href!="string"||a.href===""||a.onLoad||a.onError)break;return a.rel==="stylesheet"?(t=a.disabled,typeof a.precedence=="string"&&t==null):!0;case"script":if(a.async&&typeof a.async!="function"&&typeof a.async!="symbol"&&!a.onLoad&&!a.onError&&a.src&&typeof a.src=="string")return!0}return!1}function Uv(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function QN(t,a,s,c){if(s.type==="stylesheet"&&(typeof c.media!="string"||matchMedia(c.media).matches!==!1)&&(s.state.loading&4)===0){if(s.instance===null){var p=wr(c.href),g=a.querySelector(Jl(p));if(g){a=g._p,a!==null&&typeof a=="object"&&typeof a.then=="function"&&(t.count++,t=Fu.bind(t),a.then(t,t)),s.state.loading|=4,s.instance=g,en(g);return}g=a.ownerDocument||a,c=Bv(c),(p=Ta.get(p))&&Ph(c,p),g=g.createElement("link"),en(g);var w=g;w._p=new Promise(function(A,D){w.onload=A,w.onerror=D}),Rn(g,"link",c),s.instance=g}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(s,a),(a=s.state.preload)&&(s.state.loading&3)===0&&(t.count++,s=Fu.bind(t),a.addEventListener("load",s),a.addEventListener("error",s))}}var Bh=0;function FN(t,a){return t.stylesheets&&t.count===0&&Yu(t,t.stylesheets),0<t.count||0<t.imgCount?function(s){var c=setTimeout(function(){if(t.stylesheets&&Yu(t,t.stylesheets),t.unsuspend){var g=t.unsuspend;t.unsuspend=null,g()}},6e4+a);0<t.imgBytes&&Bh===0&&(Bh=62500*_N());var p=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&Yu(t,t.stylesheets),t.unsuspend)){var g=t.unsuspend;t.unsuspend=null,g()}},(t.imgBytes>Bh?50:800)+a);return t.unsuspend=s,function(){t.unsuspend=null,clearTimeout(c),clearTimeout(p)}}:null}function Fu(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Yu(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var Zu=null;function Yu(t,a){t.stylesheets=null,t.unsuspend!==null&&(t.count++,Zu=new Map,a.forEach(ZN,t),Zu=null,Fu.call(t))}function ZN(t,a){if(!(a.state.loading&4)){var s=Zu.get(t);if(s)var c=s.get(null);else{s=new Map,Zu.set(t,s);for(var p=t.querySelectorAll("link[data-precedence],style[data-precedence]"),g=0;g<p.length;g++){var w=p[g];(w.nodeName==="LINK"||w.getAttribute("media")!=="not all")&&(s.set(w.dataset.precedence,w),c=w)}c&&s.set(null,c)}p=a.instance,w=p.getAttribute("data-precedence"),g=s.get(w)||c,g===c&&s.set(null,p),s.set(w,p),this.count++,c=Fu.bind(this),p.addEventListener("load",c),p.addEventListener("error",c),g?g.parentNode.insertBefore(p,g.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(p,t.firstChild)),a.state.loading|=4}}var ec={$$typeof:L,Provider:null,Consumer:null,_currentValue:ve,_currentValue2:ve,_threadCount:0};function YN(t,a,s,c,p,g,w,A,D){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Bo(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Bo(0),this.hiddenUpdates=Bo(null),this.identifierPrefix=c,this.onUncaughtError=p,this.onCaughtError=g,this.onRecoverableError=w,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=D,this.incompleteTransitions=new Map}function Gv(t,a,s,c,p,g,w,A,D,U,te,se){return t=new YN(t,a,s,w,D,U,te,se,A),a=1,g===!0&&(a|=24),g=oa(3,null,null,a),t.current=g,g.stateNode=t,a=bp(),a.refCount++,t.pooledCache=a,a.refCount++,g.memoizedState={element:c,isDehydrated:s,cache:a},Sp(g),t}function Kv(t){return t?(t=Wo,t):Wo}function Hv(t,a,s,c,p,g){p=Kv(p),c.context===null?c.context=p:c.pendingContext=p,c=ss(a),c.payload={element:s},g=g===void 0?null:g,g!==null&&(c.callback=g),s=os(t,c,a),s!==null&&(Jn(s,t,a),Dl(s,t,a))}function Qv(t,a){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var s=t.retryLane;t.retryLane=s!==0&&s<a?s:a}}function Lh(t,a){Qv(t,a),(t=t.alternate)&&Qv(t,a)}function Fv(t){if(t.tag===13||t.tag===31){var a=eo(t,67108864);a!==null&&Jn(a,t,67108864),Lh(t,67108864)}}function Zv(t){if(t.tag===13||t.tag===31){var a=da();a=rl(a);var s=eo(t,a);s!==null&&Jn(s,t,a),Lh(t,a)}}var Xu=!0;function XN(t,a,s,c){var p=q.T;q.T=null;var g=X.p;try{X.p=2,$h(t,a,s,c)}finally{X.p=g,q.T=p}}function JN(t,a,s,c){var p=q.T;q.T=null;var g=X.p;try{X.p=8,$h(t,a,s,c)}finally{X.p=g,q.T=p}}function $h(t,a,s,c){if(Xu){var p=Vh(c);if(p===null)Nh(t,a,c,Ju,s),Xv(t,c);else if(e5(p,t,a,s,c))c.stopPropagation();else if(Xv(t,c),a&4&&-1<WN.indexOf(t)){for(;p!==null;){var g=Zi(p);if(g!==null)switch(g.tag){case 3:if(g=g.stateNode,g.current.memoizedState.isDehydrated){var w=st(g.pendingLanes);if(w!==0){var A=g;for(A.pendingLanes|=2,A.entangledLanes|=2;w;){var D=1<<31-An(w);A.entanglements[1]|=D,w&=~D}ri(g),(wt&6)===0&&(Iu=$t()+500,Fl(0))}}break;case 31:case 13:A=eo(g,2),A!==null&&Jn(A,g,2),qu(),Lh(g,2)}if(g=Vh(c),g===null&&Nh(t,a,c,Ju,s),g===p)break;p=g}p!==null&&c.stopPropagation()}else Nh(t,a,c,null,s)}}function Vh(t){return t=yl(t),Uh(t)}var Ju=null;function Uh(t){if(Ju=null,t=hi(t),t!==null){var a=h(t);if(a===null)t=null;else{var s=a.tag;if(s===13){if(t=f(a),t!==null)return t;t=null}else if(s===31){if(t=b(a),t!==null)return t;t=null}else if(s===3){if(a.stateNode.current.memoizedState.isDehydrated)return a.tag===3?a.stateNode.containerInfo:null;t=null}else a!==t&&(t=null)}}return Ju=t,null}function Yv(t){switch(t){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(mi()){case Bs:return 2;case Hn:return 8;case pi:case Ls:return 32;case Ki:return 268435456;default:return 32}default:return 32}}var Gh=!1,ys=null,bs=null,vs=null,tc=new Map,nc=new Map,xs=[],WN="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Xv(t,a){switch(t){case"focusin":case"focusout":ys=null;break;case"dragenter":case"dragleave":bs=null;break;case"mouseover":case"mouseout":vs=null;break;case"pointerover":case"pointerout":tc.delete(a.pointerId);break;case"gotpointercapture":case"lostpointercapture":nc.delete(a.pointerId)}}function ac(t,a,s,c,p,g){return t===null||t.nativeEvent!==g?(t={blockedOn:a,domEventName:s,eventSystemFlags:c,nativeEvent:g,targetContainers:[p]},a!==null&&(a=Zi(a),a!==null&&Fv(a)),t):(t.eventSystemFlags|=c,a=t.targetContainers,p!==null&&a.indexOf(p)===-1&&a.push(p),t)}function e5(t,a,s,c,p){switch(a){case"focusin":return ys=ac(ys,t,a,s,c,p),!0;case"dragenter":return bs=ac(bs,t,a,s,c,p),!0;case"mouseover":return vs=ac(vs,t,a,s,c,p),!0;case"pointerover":var g=p.pointerId;return tc.set(g,ac(tc.get(g)||null,t,a,s,c,p)),!0;case"gotpointercapture":return g=p.pointerId,nc.set(g,ac(nc.get(g)||null,t,a,s,c,p)),!0}return!1}function Jv(t){var a=hi(t.target);if(a!==null){var s=h(a);if(s!==null){if(a=s.tag,a===13){if(a=f(s),a!==null){t.blockedOn=a,Zc(t.priority,function(){Zv(s)});return}}else if(a===31){if(a=b(s),a!==null){t.blockedOn=a,Zc(t.priority,function(){Zv(s)});return}}else if(a===3&&s.stateNode.current.memoizedState.isDehydrated){t.blockedOn=s.tag===3?s.stateNode.containerInfo:null;return}}}t.blockedOn=null}function Wu(t){if(t.blockedOn!==null)return!1;for(var a=t.targetContainers;0<a.length;){var s=Vh(t.nativeEvent);if(s===null){s=t.nativeEvent;var c=new s.constructor(s.type,s);gl=c,s.target.dispatchEvent(c),gl=null}else return a=Zi(s),a!==null&&Fv(a),t.blockedOn=s,!1;a.shift()}return!0}function Wv(t,a,s){Wu(t)&&s.delete(a)}function t5(){Gh=!1,ys!==null&&Wu(ys)&&(ys=null),bs!==null&&Wu(bs)&&(bs=null),vs!==null&&Wu(vs)&&(vs=null),tc.forEach(Wv),nc.forEach(Wv)}function ed(t,a){t.blockedOn===a&&(t.blockedOn=null,Gh||(Gh=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,t5)))}var td=null;function ex(t){td!==t&&(td=t,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){td===t&&(td=null);for(var a=0;a<t.length;a+=3){var s=t[a],c=t[a+1],p=t[a+2];if(typeof c!="function"){if(Uh(c||s)===null)continue;break}var g=Zi(s);g!==null&&(t.splice(a,3),a-=3,Vp(g,{pending:!0,data:p,method:s.method,action:c},c,p))}}))}function kr(t){function a(D){return ed(D,t)}ys!==null&&ed(ys,t),bs!==null&&ed(bs,t),vs!==null&&ed(vs,t),tc.forEach(a),nc.forEach(a);for(var s=0;s<xs.length;s++){var c=xs[s];c.blockedOn===t&&(c.blockedOn=null)}for(;0<xs.length&&(s=xs[0],s.blockedOn===null);)Jv(s),s.blockedOn===null&&xs.shift();if(s=(t.ownerDocument||t).$$reactFormReplay,s!=null)for(c=0;c<s.length;c+=3){var p=s[c],g=s[c+1],w=p[In]||null;if(typeof g=="function")w||ex(s);else if(w){var A=null;if(g&&g.hasAttribute("formAction")){if(p=g,w=g[In]||null)A=w.formAction;else if(Uh(p)!==null)continue}else A=w.action;typeof A=="function"?s[c+1]=A:(s.splice(c,3),c-=3),ex(s)}}}function tx(){function t(g){g.canIntercept&&g.info==="react-transition"&&g.intercept({handler:function(){return new Promise(function(w){return p=w})},focusReset:"manual",scroll:"manual"})}function a(){p!==null&&(p(),p=null),c||setTimeout(s,20)}function s(){if(!c&&!navigation.transition){var g=navigation.currentEntry;g&&g.url!=null&&navigation.navigate(g.url,{state:g.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var c=!1,p=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",a),navigation.addEventListener("navigateerror",a),setTimeout(s,100),function(){c=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",a),navigation.removeEventListener("navigateerror",a),p!==null&&(p(),p=null)}}}function Kh(t){this._internalRoot=t}nd.prototype.render=Kh.prototype.render=function(t){var a=this._internalRoot;if(a===null)throw Error(r(409));var s=a.current,c=da();Hv(s,c,t,a,null,null)},nd.prototype.unmount=Kh.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var a=t.containerInfo;Hv(t.current,2,null,t,null,null),qu(),a[Qi]=null}};function nd(t){this._internalRoot=t}nd.prototype.unstable_scheduleHydration=function(t){if(t){var a=Lo();t={blockedOn:null,target:t,priority:a};for(var s=0;s<xs.length&&a!==0&&a<xs[s].priority;s++);xs.splice(s,0,t),s===0&&Jv(t)}};var nx=n.version;if(nx!=="19.2.4")throw Error(r(527,nx,"19.2.4"));X.findDOMNode=function(t){var a=t._reactInternals;if(a===void 0)throw typeof t.render=="function"?Error(r(188)):(t=Object.keys(t).join(","),Error(r(268,t)));return t=x(a),t=t!==null?S(t):null,t=t===null?null:t.stateNode,t};var n5={bundleType:0,version:"19.2.4",rendererPackageName:"react-dom",currentDispatcherRef:q,reconcilerVersion:"19.2.4"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ad=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ad.isDisabled&&ad.supportsFiber)try{yn=ad.inject(n5),At=ad}catch{}}return ic.createRoot=function(t,a){if(!u(t))throw Error(r(299));var s=!1,c="",p=cb,g=ub,w=db;return a!=null&&(a.unstable_strictMode===!0&&(s=!0),a.identifierPrefix!==void 0&&(c=a.identifierPrefix),a.onUncaughtError!==void 0&&(p=a.onUncaughtError),a.onCaughtError!==void 0&&(g=a.onCaughtError),a.onRecoverableError!==void 0&&(w=a.onRecoverableError)),a=Gv(t,1,!1,null,null,s,c,null,p,g,w,tx),t[Qi]=a.current,Ch(t),new Kh(a)},ic.hydrateRoot=function(t,a,s){if(!u(t))throw Error(r(299));var c=!1,p="",g=cb,w=ub,A=db,D=null;return s!=null&&(s.unstable_strictMode===!0&&(c=!0),s.identifierPrefix!==void 0&&(p=s.identifierPrefix),s.onUncaughtError!==void 0&&(g=s.onUncaughtError),s.onCaughtError!==void 0&&(w=s.onCaughtError),s.onRecoverableError!==void 0&&(A=s.onRecoverableError),s.formState!==void 0&&(D=s.formState)),a=Gv(t,1,!0,a,s??null,c,p,D,g,w,A,tx),a.context=Kv(null),s=a.current,c=da(),c=rl(c),p=ss(c),p.callback=null,os(s,p,c),s=c,a.current.lanes=s,Gs(a,s),ri(a),t[Qi]=a.current,Ch(t),new nd(a)},ic.version="19.2.4",ic}var ox;function V5(){if(ox)return Hh.exports;ox=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(n){console.error(n)}}return e(),Hh.exports=$5(),Hh.exports}var U5=V5();const G5={bodySerializer:e=>JSON.stringify(e,(n,i)=>typeof i=="bigint"?i.toString():i)},K5=({onRequest:e,onSseError:n,onSseEvent:i,responseTransformer:r,responseValidator:u,sseDefaultRetryDelay:h,sseMaxRetryAttempts:f,sseMaxRetryDelay:b,sseSleepFn:v,url:x,...S})=>{let k;const T=v??(P=>new Promise(E=>setTimeout(E,P)));return{stream:async function*(){let P=h??3e3,E=0;const $=S.signal??new AbortController().signal;for(;!$.aborted;){E++;const ee=S.headers instanceof Headers?S.headers:new Headers(S.headers);k!==void 0&&ee.set("Last-Event-ID",k);try{const L={redirect:"follow",...S,body:S.serializedBody,headers:ee,signal:$};let F=new Request(x,L);e&&(F=await e(x,L));const ae=await(S.fetch??globalThis.fetch)(F);if(!ae.ok)throw new Error(`SSE failed: ${ae.status} ${ae.statusText}`);if(!ae.body)throw new Error("No body in SSE response");const M=ae.body.pipeThrough(new TextDecoderStream).getReader();let Y="";const ue=()=>{try{M.cancel()}catch{}};$.addEventListener("abort",ue);try{for(;;){const{done:Xe,value:nt}=await M.read();if(Xe)break;Y+=nt;const Ge=Y.split(`
|
|
11
|
+
|
|
12
|
+
`);Y=Ge.pop()??"";for(const Pe of Ge){const Se=Pe.split(`
|
|
13
|
+
`),Ve=[];let q;for(const ke of Se)if(ke.startsWith("data:"))Ve.push(ke.replace(/^data:\s*/,""));else if(ke.startsWith("event:"))q=ke.replace(/^event:\s*/,"");else if(ke.startsWith("id:"))k=ke.replace(/^id:\s*/,"");else if(ke.startsWith("retry:")){const J=Number.parseInt(ke.replace(/^retry:\s*/,""),10);Number.isNaN(J)||(P=J)}let X,ve=!1;if(Ve.length){const ke=Ve.join(`
|
|
14
|
+
`);try{X=JSON.parse(ke),ve=!0}catch{X=ke}}ve&&(u&&await u(X),r&&(X=await r(X))),i?.({data:X,event:q,id:k,retry:P}),Ve.length&&(yield X)}}}finally{$.removeEventListener("abort",ue),M.releaseLock()}break}catch(L){if(n?.(L),f!==void 0&&E>=f)break;const F=Math.min(P*2**(E-1),b??3e4);await T(F)}}}()}},H5=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},Q5=e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},F5=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},lk=({allowReserved:e,explode:n,name:i,style:r,value:u})=>{if(!n){const b=(e?u:u.map(v=>encodeURIComponent(v))).join(Q5(r));switch(r){case"label":return`.${b}`;case"matrix":return`;${i}=${b}`;case"simple":return b;default:return`${i}=${b}`}}const h=H5(r),f=u.map(b=>r==="label"||r==="simple"?e?b:encodeURIComponent(b):sm({allowReserved:e,name:i,value:b})).join(h);return r==="label"||r==="matrix"?h+f:f},sm=({allowReserved:e,name:n,value:i})=>{if(i==null)return"";if(typeof i=="object")throw new Error("Deeply-nested arrays/objects aren’t supported. Provide your own `querySerializer()` to handle these.");return`${n}=${e?i:encodeURIComponent(i)}`},ck=({allowReserved:e,explode:n,name:i,style:r,value:u,valueOnly:h})=>{if(u instanceof Date)return h?u.toISOString():`${i}=${u.toISOString()}`;if(r!=="deepObject"&&!n){let v=[];Object.entries(u).forEach(([S,k])=>{v=[...v,S,e?k:encodeURIComponent(k)]});const x=v.join(",");switch(r){case"form":return`${i}=${x}`;case"label":return`.${x}`;case"matrix":return`;${i}=${x}`;default:return x}}const f=F5(r),b=Object.entries(u).map(([v,x])=>sm({allowReserved:e,name:r==="deepObject"?`${i}[${v}]`:v,value:x})).join(f);return r==="label"||r==="matrix"?f+b:b},Z5=/\{[^{}]+\}/g,Y5=({path:e,url:n})=>{let i=n;const r=n.match(Z5);if(r)for(const u of r){let h=!1,f=u.substring(1,u.length-1),b="simple";f.endsWith("*")&&(h=!0,f=f.substring(0,f.length-1)),f.startsWith(".")?(f=f.substring(1),b="label"):f.startsWith(";")&&(f=f.substring(1),b="matrix");const v=e[f];if(v==null)continue;if(Array.isArray(v)){i=i.replace(u,lk({explode:h,name:f,style:b,value:v}));continue}if(typeof v=="object"){i=i.replace(u,ck({explode:h,name:f,style:b,value:v,valueOnly:!0}));continue}if(b==="matrix"){i=i.replace(u,`;${sm({name:f,value:v})}`);continue}const x=encodeURIComponent(b==="label"?`.${v}`:v);i=i.replace(u,x)}return i},X5=({baseUrl:e,path:n,query:i,querySerializer:r,url:u})=>{const h=u.startsWith("/")?u:`/${u}`;let f=(e??"")+h;n&&(f=Y5({path:n,url:f}));let b=i?r(i):"";return b.startsWith("?")&&(b=b.substring(1)),b&&(f+=`?${b}`),f};function J5(e){const n=e.body!==void 0;if(n&&e.bodySerializer)return"serializedBody"in e?e.serializedBody!==void 0&&e.serializedBody!==""?e.serializedBody:null:e.body!==""?e.body:null;if(n)return e.body}const W5=async(e,n)=>{const i=typeof n=="function"?await n(e):n;if(i)return e.scheme==="bearer"?`Bearer ${i}`:e.scheme==="basic"?`Basic ${btoa(i)}`:i},uk=({allowReserved:e,array:n,object:i}={})=>u=>{const h=[];if(u&&typeof u=="object")for(const f in u){const b=u[f];if(b!=null)if(Array.isArray(b)){const v=lk({allowReserved:e,explode:!0,name:f,style:"form",value:b,...n});v&&h.push(v)}else if(typeof b=="object"){const v=ck({allowReserved:e,explode:!0,name:f,style:"deepObject",value:b,...i});v&&h.push(v)}else{const v=sm({allowReserved:e,name:f,value:b});v&&h.push(v)}}return h.join("&")},e6=e=>{if(!e)return"stream";const n=e.split(";")[0]?.trim();if(n){if(n.startsWith("application/json")||n.endsWith("+json"))return"json";if(n==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(i=>n.startsWith(i)))return"blob";if(n.startsWith("text/"))return"text"}},t6=(e,n)=>n?!!(e.headers.has(n)||e.query?.[n]||e.headers.get("Cookie")?.includes(`${n}=`)):!1,n6=async({security:e,...n})=>{for(const i of e){if(t6(n,i.name))continue;const r=await W5(i,n.auth);if(!r)continue;const u=i.name??"Authorization";switch(i.in){case"query":n.query||(n.query={}),n.query[u]=r;break;case"cookie":n.headers.append("Cookie",`${u}=${r}`);break;default:n.headers.set(u,r);break}}},rx=e=>X5({baseUrl:e.baseUrl,path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:uk(e.querySerializer),url:e.url}),lx=(e,n)=>{const i={...e,...n};return i.baseUrl?.endsWith("/")&&(i.baseUrl=i.baseUrl.substring(0,i.baseUrl.length-1)),i.headers=dk(e.headers,n.headers),i},a6=e=>{const n=[];return e.forEach((i,r)=>{n.push([r,i])}),n},dk=(...e)=>{const n=new Headers;for(const i of e){if(!i)continue;const r=i instanceof Headers?a6(i):Object.entries(i);for(const[u,h]of r)if(h===null)n.delete(u);else if(Array.isArray(h))for(const f of h)n.append(u,f);else h!==void 0&&n.set(u,typeof h=="object"?JSON.stringify(h):h)}return n};class Zh{fns=[];clear(){this.fns=[]}eject(n){const i=this.getInterceptorIndex(n);this.fns[i]&&(this.fns[i]=null)}exists(n){const i=this.getInterceptorIndex(n);return!!this.fns[i]}getInterceptorIndex(n){return typeof n=="number"?this.fns[n]?n:-1:this.fns.indexOf(n)}update(n,i){const r=this.getInterceptorIndex(n);return this.fns[r]?(this.fns[r]=i,n):!1}use(n){return this.fns.push(n),this.fns.length-1}}const i6=()=>({error:new Zh,request:new Zh,response:new Zh}),s6=uk({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),o6={"Content-Type":"application/json"},mk=(e={})=>({...G5,headers:o6,parseAs:"auto",querySerializer:s6,...e}),pk=(e={})=>{let n=lx(mk(),e);const i=()=>({...n}),r=x=>(n=lx(n,x),i()),u=i6(),h=async x=>{const S={...n,...x,fetch:x.fetch??n.fetch??globalThis.fetch,headers:dk(n.headers,x.headers),serializedBody:void 0};S.security&&await n6({...S,security:S.security}),S.requestValidator&&await S.requestValidator(S),S.body!==void 0&&S.bodySerializer&&(S.serializedBody=S.bodySerializer(S.body)),(S.body===void 0||S.serializedBody==="")&&S.headers.delete("Content-Type");const k=rx(S);return{opts:S,url:k}},f=async x=>{const{opts:S,url:k}=await h(x),T={redirect:"follow",...S,body:J5(S)};let N=new Request(k,T);for(const Z of u.request.fns)Z&&(N=await Z(N,S));const I=S.fetch;let P=await I(N);for(const Z of u.response.fns)Z&&(P=await Z(P,N,S));const E={request:N,response:P};if(P.ok){const Z=(S.parseAs==="auto"?e6(P.headers.get("Content-Type")):S.parseAs)??"json";if(P.status===204||P.headers.get("Content-Length")==="0"){let M;switch(Z){case"arrayBuffer":case"blob":case"text":M=await P[Z]();break;case"formData":M=new FormData;break;case"stream":M=P.body;break;default:M={};break}return S.responseStyle==="data"?M:{data:M,...E}}let ae;switch(Z){case"arrayBuffer":case"blob":case"formData":case"json":case"text":ae=await P[Z]();break;case"stream":return S.responseStyle==="data"?P.body:{data:P.body,...E}}return Z==="json"&&(S.responseValidator&&await S.responseValidator(ae),S.responseTransformer&&(ae=await S.responseTransformer(ae))),S.responseStyle==="data"?ae:{data:ae,...E}}const $=await P.text();let ee;try{ee=JSON.parse($)}catch{}const L=ee??$;let F=L;for(const Z of u.error.fns)Z&&(F=await Z(L,P,N,S));if(F=F||{},S.throwOnError)throw F;return S.responseStyle==="data"?void 0:{error:F,...E}},b=x=>S=>f({...S,method:x}),v=x=>async S=>{const{opts:k,url:T}=await h(S);return K5({...k,body:k.body,headers:k.headers,method:x,onRequest:async(N,I)=>{let P=new Request(N,I);for(const E of u.request.fns)E&&(P=await E(P,k));return P},url:T})};return{buildUrl:rx,connect:b("CONNECT"),delete:b("DELETE"),get:b("GET"),getConfig:i,head:b("HEAD"),interceptors:u,options:b("OPTIONS"),patch:b("PATCH"),post:b("POST"),put:b("PUT"),request:f,setConfig:r,sse:{connect:v("CONNECT"),delete:v("DELETE"),get:v("GET"),head:v("HEAD"),options:v("OPTIONS"),patch:v("PATCH"),post:v("POST"),put:v("PUT"),trace:v("TRACE")},trace:b("TRACE")}},z=pk(mk()),r6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/sitemaps/submit",...e,headers:{"Content-Type":"application/json",...e.headers}}),l6=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects",...e}),c6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects",...e,headers:{"Content-Type":"application/json",...e.headers}}),u6=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}",...e}),hk=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}",...e}),d6=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}",...e,headers:{"Content-Type":"application/json",...e.headers}}),m6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan",...e}),p6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-report",...e}),h6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-setup",...e}),PW=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft",...e}),MW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/create",...e,headers:{"Content-Type":"application/json",...e.headers}}),BW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/import-sitemap",...e,headers:{"Content-Type":"application/json",...e.headers}}),LW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/apply-sitemap-selection",...e,headers:{"Content-Type":"application/json",...e.headers}}),$W=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/upsert-target",...e,headers:{"Content-Type":"application/json",...e.headers}}),VW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/exclude-target",...e,headers:{"Content-Type":"application/json",...e.headers}}),UW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/apply-assignments",...e,headers:{"Content-Type":"application/json",...e.headers}}),GW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/preview-assignments",...e,headers:{"Content-Type":"application/json",...e.headers}}),KW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/replace-assignments",...e,headers:{"Content-Type":"application/json",...e.headers}}),HW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/apply-paired-assignments",...e,headers:{"Content-Type":"application/json",...e.headers}}),QW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/remove-assignment",...e,headers:{"Content-Type":"application/json",...e.headers}}),FW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/upsert-group",...e,headers:{"Content-Type":"application/json",...e.headers}}),ZW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/remove-group",...e,headers:{"Content-Type":"application/json",...e.headers}}),YW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/preview-group-membership",...e,headers:{"Content-Type":"application/json",...e.headers}}),XW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/apply-group-membership",...e,headers:{"Content-Type":"application/json",...e.headers}}),JW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/upsert-competitor",...e,headers:{"Content-Type":"application/json",...e.headers}}),f6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/pin-competitor",...e,headers:{"Content-Type":"application/json",...e.headers}}),WW=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/remove-competitor",...e,headers:{"Content-Type":"application/json",...e.headers}}),eee=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/compile-preview",...e}),tee=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/diff-preview",...e}),nee=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/publish",...e,headers:{"Content-Type":"application/json",...e.headers}}),aee=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-plan/draft/actions/discard",...e}),fk=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-overview",...e}),g6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/sentiment/settings",...e}),y6=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/sentiment/settings",...e,headers:{"Content-Type":"application/json",...e.headers}}),b6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/sentiment",...e}),v6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/sentiment/evidence",...e}),x6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/sentiment/backfill-preview",...e}),w6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/sentiment/backfills",...e,headers:{"Content-Type":"application/json",...e.headers}}),S6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/sentiment/jobs",...e}),k6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/sentiment/jobs/{jobId}",...e}),j6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/visibility-report",...e}),A6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-property-evidence",...e}),C6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-question-result",...e}),N6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-property-competitors",...e}),_6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-query-templates",...e}),T6=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/measurement-query-templates/{templateId}",...e,headers:{"Content-Type":"application/json",...e.headers}}),E6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/research/runs",...e}),R6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/research/batches",...e,headers:{"Content-Type":"application/json",...e.headers}}),D6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/query-tracking",...e}),z6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/query-tracking/preview",...e,headers:{"Content-Type":"application/json",...e.headers}}),I6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/query-tracking/commit",...e,headers:{"Content-Type":"application/json",...e.headers}}),O6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/research/runs/{runId}",...e}),q6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/locations",...e,headers:{"Content-Type":"application/json",...e.headers}}),P6=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/locations/{label}",...e}),M6=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/locations/default",...e,headers:{"Content-Type":"application/json",...e.headers}}),B6=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/queries",...e,headers:{"Content-Type":"application/json",...e.headers}}),gk=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/queries",...e}),L6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/queries",...e,headers:{"Content-Type":"application/json",...e.headers}}),$6=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/queries",...e,headers:{"Content-Type":"application/json",...e.headers}}),V6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/queries/generate",...e,headers:{"Content-Type":"application/json",...e.headers}}),U6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/competitors",...e,headers:{"Content-Type":"application/json",...e.headers}}),G6=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/competitors",...e,headers:{"Content-Type":"application/json",...e.headers}}),K6=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/competitors/{id}",...e}),H6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/analytics/competitors",...e}),yk=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/runs",...e}),Q6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/runs",...e,headers:{"Content-Type":"application/json",...e.headers}}),F6=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/runs",...e}),Z6=e=>(e?.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/runs",...e,headers:{"Content-Type":"application/json",...e?.headers}}),bk=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/runs/{id}",...e}),Y6=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/apply",...e,headers:{"Content-Type":"application/json",...e.headers}}),X6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/history",...e}),J6=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/history",...e}),W6=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/timeline",...e}),e_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/analytics/metrics",...e}),t_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/snapshots/diff",...e}),vk=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/settings",...e}),n_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/settings/providers/{name}",...e,headers:{"Content-Type":"application/json",...e.headers}}),a_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/settings/google",...e,headers:{"Content-Type":"application/json",...e.headers}}),i_=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/keys/self",...e}),s_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/settings/bing",...e,headers:{"Content-Type":"application/json",...e.headers}}),o_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/settings/cdp",...e,headers:{"Content-Type":"application/json",...e.headers}}),r_=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/schedule",...e}),l_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/schedule",...e}),c_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/schedule",...e,headers:{"Content-Type":"application/json",...e.headers}}),u_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/schedules",...e}),d_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/notifications",...e}),m_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/notifications",...e,headers:{"Content-Type":"application/json",...e.headers}}),p_=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/notifications/{id}",...e}),h_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/notifications/{id}/test",...e}),f_=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/telemetry",...e}),g_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/telemetry",...e,headers:{"Content-Type":"application/json",...e.headers}}),y_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/telemetry/onboarding",...e,headers:{"Content-Type":"application/json",...e.headers}}),xk=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/cdp/status",...e}),b_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google-ads/status",...e}),v_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google-ads/oauth/connect",...e,headers:{"Content-Type":"application/json",...e.headers}}),x_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google-ads/customers",...e}),w_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google-ads/selection",...e,headers:{"Content-Type":"application/json",...e.headers}}),S_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google-ads/sync",...e}),k_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google-ads/performance",...e}),j_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google-ads/snapshots",...e}),A_=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google-ads/connection",...e}),C_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/status",...e}),N_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/oauth/connect",...e,headers:{"Content-Type":"application/json",...e.headers}}),__=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/accounts",...e}),T_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/accounts/{accountId}/containers",...e}),E_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/accounts/{accountId}/containers/{containerId}/workspaces",...e}),R_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/selection",...e,headers:{"Content-Type":"application/json",...e.headers}}),D_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/sync",...e}),z_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/snapshots",...e}),I_=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gtm/connection",...e}),O_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/conversion-tracking/options",...e}),q_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/conversion-tracking/contracts",...e}),P_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/conversion-tracking/contracts",...e,headers:{"Content-Type":"application/json",...e.headers}}),M_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/conversion-tracking/contracts/{contractId}/integrity",...e}),B_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/connections",...e}),L_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/connect",...e,headers:{"Content-Type":"application/json",...e.headers}}),$_=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/connections/{type}",...e}),V_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/properties",...e}),U_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/connections/{type}/property",...e,headers:{"Content-Type":"application/json",...e.headers}}),G_=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/connections/{type}/sitemap",...e,headers:{"Content-Type":"application/json",...e.headers}}),K_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/sync",...e,headers:{"Content-Type":"application/json",...e.headers}}),H_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/performance",...e}),Q_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/performance/daily",...e}),F_=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/inspect",...e,headers:{"Content-Type":"application/json",...e.headers}}),Z_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/inspections",...e}),Y_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/deindexed",...e}),X_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/coverage",...e}),J_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/coverage/history",...e}),W_=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/sitemaps",...e}),eT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/gsc/inspect-sitemap",...e,headers:{"Content-Type":"application/json",...e.headers}}),tT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/google/indexing/request",...e,headers:{"Content-Type":"application/json",...e.headers}}),nT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gbp/locations",...e}),aT=e=>(e.client??z).put({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gbp/locations/{locationName}/selection",...e,headers:{"Content-Type":"application/json",...e.headers}}),iT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gbp/sync",...e,headers:{"Content-Type":"application/json",...e.headers}}),sT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gbp/keywords",...e}),oT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gbp/place-actions",...e}),rT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gbp/lodging",...e}),lT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gbp/places",...e}),cT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/gbp/summary",...e}),uT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/connect",...e,headers:{"Content-Type":"application/json",...e.headers}}),dT=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/disconnect",...e}),mT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/status",...e}),pT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/sites",...e}),hT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/set-site",...e,headers:{"Content-Type":"application/json",...e.headers}}),fT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/coverage",...e}),gT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/inspections",...e}),yT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/inspect-url",...e,headers:{"Content-Type":"application/json",...e.headers}}),bT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/inspect-sitemap",...e,headers:{"Content-Type":"application/json",...e.headers}}),vT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/request-indexing",...e,headers:{"Content-Type":"application/json",...e.headers}}),xT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/bing/performance",...e}),wT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/ga/connect",...e,headers:{"Content-Type":"application/json",...e.headers}}),ST=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/ga/disconnect",...e}),kT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/ga/status",...e}),jT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/ga/sync",...e,headers:{"Content-Type":"application/json",...e.headers}}),AT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/ga/traffic",...e}),CT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/ga/ai-referral-daily",...e}),NT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/ga/social-referral-history",...e}),_T=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/ga/session-history",...e}),TT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/insights",...e}),ET=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/report",...e}),RT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/health/history",...e}),DT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/citations/visibility",...e}),zT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/content/dismissals",...e,headers:{"Content-Type":"application/json",...e.headers}}),IT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/overview",...e}),OT=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/backlinks/status",...e}),qT=e=>(e?.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/backlinks/install",...e}),PT=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/backlinks/syncs",...e}),MT=e=>(e?.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/backlinks/syncs",...e,headers:{"Content-Type":"application/json",...e?.headers}}),BT=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/backlinks/syncs/latest",...e}),LT=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/backlinks/releases",...e}),$T=e=>(e?.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/backlinks/latest-release",...e}),VT=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/backlinks/cache/{release}",...e}),UT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/backlinks/extract",...e,headers:{"Content-Type":"application/json",...e.headers}}),GT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/backlinks/summary",...e}),KT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/backlinks/domains",...e}),HT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/backlinks/history",...e}),QT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/connect/cloud-run",...e,headers:{"Content-Type":"application/json",...e.headers}}),FT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/connect/wordpress",...e,headers:{"Content-Type":"application/json",...e.headers}}),ZT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/connect/vercel",...e,headers:{"Content-Type":"application/json",...e.headers}}),YT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/sources/{id}/sync",...e,headers:{"Content-Type":"application/json",...e.headers}}),XT=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/sources/{id}/backfill",...e,headers:{"Content-Type":"application/json",...e.headers}}),JT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/sources",...e}),WT=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/status",...e}),e8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/sources/{id}",...e}),t8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/traffic/events",...e}),n8=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/discover/run",...e,headers:{"Content-Type":"application/json",...e.headers}}),a8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/discover/sessions",...e}),i8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/discover/sessions/{id}",...e}),s8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo",...e}),o8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/pages",...e}),r8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/trend",...e}),l8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/crawl",...e}),c8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/graph",...e}),u8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/crawl/pages/audit",...e}),wk=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/crawl/pages",...e}),d8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/structure",...e}),m8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/internal-links/neighbors",...e}),p8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/dead-links",...e}),h8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/runs",...e}),f8=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/runs",...e,headers:{"Content-Type":"application/json",...e.headers}}),g8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/runs/{runId}/progress",...e}),y8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/technical-aeo/runs/{runId}/page-health-preview",...e}),b8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/agent/conversations",...e}),v8=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/agent/conversations",...e,headers:{"Content-Type":"application/json",...e.headers}}),x8=e=>(e.client??z).delete({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/agent/conversations/{id}",...e}),w8=e=>(e.client??z).post({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/agent/conversations/{id}/resume",...e}),S8=e=>(e.client??z).get({security:[{scheme:"bearer",type:"http"}],url:"/api/v1/projects/{name}/agent/providers",...e});function k8(e){const n={baseUrl:e.baseUrl,fetch:e.fetch,headers:{...e.headers??{}}};return pk(n)}function ne(e,n,i){function r(b,v){if(b._zod||Object.defineProperty(b,"_zod",{value:{def:v,constr:f,traits:new Set},enumerable:!1}),b._zod.traits.has(e))return;b._zod.traits.add(e),n(b,v);const x=f.prototype,S=Object.keys(x);for(let k=0;k<S.length;k++){const T=S[k];T in b||(b[T]=x[T].bind(b))}}const u=i?.Parent??Object;class h extends u{}Object.defineProperty(h,"name",{value:e});function f(b){var v;const x=i?.Parent?new h:this;r(x,b),(v=x._zod).deferred??(v.deferred=[]);for(const S of x._zod.deferred)S();return x}return Object.defineProperty(f,"init",{value:r}),Object.defineProperty(f,Symbol.hasInstance,{value:b=>i?.Parent&&b instanceof i.Parent?!0:b?._zod?.traits?.has(e)}),Object.defineProperty(f,"name",{value:e}),f}class Rr extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class Sk extends Error{constructor(n){super(`Encountered unidirectional transform during encode: ${n}`),this.name="ZodEncodeError"}}const kk={};function Cs(e){return kk}function jk(e){const n=Object.values(e).filter(r=>typeof r=="number");return Object.entries(e).filter(([r,u])=>n.indexOf(+r)===-1).map(([r,u])=>u)}function qf(e,n){return typeof n=="bigint"?n.toString():n}function om(e){return{get value(){{const n=e();return Object.defineProperty(this,"value",{value:n}),n}}}}function Rg(e){return e==null}function Dg(e){const n=e.startsWith("^")?1:0,i=e.endsWith("$")?e.length-1:e.length;return e.slice(n,i)}function j8(e,n){const i=(e.toString().split(".")[1]||"").length,r=n.toString();let u=(r.split(".")[1]||"").length;if(u===0&&/\d?e-\d?/.test(r)){const v=r.match(/\d?e-(\d?)/);v?.[1]&&(u=Number.parseInt(v[1]))}const h=i>u?i:u,f=Number.parseInt(e.toFixed(h).replace(".","")),b=Number.parseInt(n.toFixed(h).replace(".",""));return f%b/10**h}const cx=Symbol("evaluating");function gt(e,n,i){let r;Object.defineProperty(e,n,{get(){if(r!==cx)return r===void 0&&(r=cx,r=i()),r},set(u){Object.defineProperty(e,n,{value:u})},configurable:!0})}function To(e,n,i){Object.defineProperty(e,n,{value:i,writable:!0,enumerable:!0,configurable:!0})}function Rs(...e){const n={};for(const i of e){const r=Object.getOwnPropertyDescriptors(i);Object.assign(n,r)}return Object.defineProperties({},n)}function ux(e){return JSON.stringify(e)}function A8(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}const Ak="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Sc(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const C8=om(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{const e=Function;return new e(""),!0}catch{return!1}});function Or(e){if(Sc(e)===!1)return!1;const n=e.constructor;if(n===void 0||typeof n!="function")return!0;const i=n.prototype;return!(Sc(i)===!1||Object.prototype.hasOwnProperty.call(i,"isPrototypeOf")===!1)}function Ck(e){return Or(e)?{...e}:Array.isArray(e)?[...e]:e}const N8=new Set(["string","number","symbol"]);function qr(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Ds(e,n,i){const r=new e._zod.constr(n??e._zod.def);return(!n||i?.parent)&&(r._zod.parent=e),r}function De(e){const n=e;if(!n)return{};if(typeof n=="string")return{error:()=>n};if(n?.message!==void 0){if(n?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");n.error=n.message}return delete n.message,typeof n.error=="string"?{...n,error:()=>n.error}:n}function _8(e){return Object.keys(e).filter(n=>e[n]._zod.optin==="optional"&&e[n]._zod.optout==="optional")}const T8={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]};function E8(e,n){const i=e._zod.def,r=i.checks;if(r&&r.length>0)throw new Error(".pick() cannot be used on object schemas containing refinements");const h=Rs(e._zod.def,{get shape(){const f={};for(const b in n){if(!(b in i.shape))throw new Error(`Unrecognized key: "${b}"`);n[b]&&(f[b]=i.shape[b])}return To(this,"shape",f),f},checks:[]});return Ds(e,h)}function R8(e,n){const i=e._zod.def,r=i.checks;if(r&&r.length>0)throw new Error(".omit() cannot be used on object schemas containing refinements");const h=Rs(e._zod.def,{get shape(){const f={...e._zod.def.shape};for(const b in n){if(!(b in i.shape))throw new Error(`Unrecognized key: "${b}"`);n[b]&&delete f[b]}return To(this,"shape",f),f},checks:[]});return Ds(e,h)}function D8(e,n){if(!Or(n))throw new Error("Invalid input to extend: expected a plain object");const i=e._zod.def.checks;if(i&&i.length>0){const h=e._zod.def.shape;for(const f in n)if(Object.getOwnPropertyDescriptor(h,f)!==void 0)throw new Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}const u=Rs(e._zod.def,{get shape(){const h={...e._zod.def.shape,...n};return To(this,"shape",h),h}});return Ds(e,u)}function z8(e,n){if(!Or(n))throw new Error("Invalid input to safeExtend: expected a plain object");const i=Rs(e._zod.def,{get shape(){const r={...e._zod.def.shape,...n};return To(this,"shape",r),r}});return Ds(e,i)}function I8(e,n){const i=Rs(e._zod.def,{get shape(){const r={...e._zod.def.shape,...n._zod.def.shape};return To(this,"shape",r),r},get catchall(){return n._zod.def.catchall},checks:[]});return Ds(e,i)}function O8(e,n,i){const u=n._zod.def.checks;if(u&&u.length>0)throw new Error(".partial() cannot be used on object schemas containing refinements");const f=Rs(n._zod.def,{get shape(){const b=n._zod.def.shape,v={...b};if(i)for(const x in i){if(!(x in b))throw new Error(`Unrecognized key: "${x}"`);i[x]&&(v[x]=e?new e({type:"optional",innerType:b[x]}):b[x])}else for(const x in b)v[x]=e?new e({type:"optional",innerType:b[x]}):b[x];return To(this,"shape",v),v},checks:[]});return Ds(n,f)}function q8(e,n,i){const r=Rs(n._zod.def,{get shape(){const u=n._zod.def.shape,h={...u};if(i)for(const f in i){if(!(f in h))throw new Error(`Unrecognized key: "${f}"`);i[f]&&(h[f]=new e({type:"nonoptional",innerType:u[f]}))}else for(const f in u)h[f]=new e({type:"nonoptional",innerType:u[f]});return To(this,"shape",h),h}});return Ds(n,r)}function _r(e,n=0){if(e.aborted===!0)return!0;for(let i=n;i<e.issues.length;i++)if(e.issues[i]?.continue!==!0)return!0;return!1}function Tr(e,n){return n.map(i=>{var r;return(r=i).path??(r.path=[]),i.path.unshift(e),i})}function sd(e){return typeof e=="string"?e:e?.message}function Ns(e,n,i){const r={...e,path:e.path??[]};if(!e.message){const u=sd(e.inst?._zod.def?.error?.(e))??sd(n?.error?.(e))??sd(i.customError?.(e))??sd(i.localeError?.(e))??"Invalid input";r.message=u}return delete r.inst,delete r.continue,n?.reportInput||delete r.input,r}function zg(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function kc(...e){const[n,i,r]=e;return typeof n=="string"?{message:n,code:"custom",input:i,inst:r}:{...n}}const Nk=(e,n)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:n,enumerable:!1}),e.message=JSON.stringify(n,qf,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},_k=ne("$ZodError",Nk),Tk=ne("$ZodError",Nk,{Parent:Error});function P8(e,n=i=>i.message){const i={},r=[];for(const u of e.issues)u.path.length>0?(i[u.path[0]]=i[u.path[0]]||[],i[u.path[0]].push(n(u))):r.push(n(u));return{formErrors:r,fieldErrors:i}}function M8(e,n=i=>i.message){const i={_errors:[]},r=u=>{for(const h of u.issues)if(h.code==="invalid_union"&&h.errors.length)h.errors.map(f=>r({issues:f}));else if(h.code==="invalid_key")r({issues:h.issues});else if(h.code==="invalid_element")r({issues:h.issues});else if(h.path.length===0)i._errors.push(n(h));else{let f=i,b=0;for(;b<h.path.length;){const v=h.path[b];b===h.path.length-1?(f[v]=f[v]||{_errors:[]},f[v]._errors.push(n(h))):f[v]=f[v]||{_errors:[]},f=f[v],b++}}};return r(e),i}const Ig=e=>(n,i,r,u)=>{const h=r?Object.assign(r,{async:!1}):{async:!1},f=n._zod.run({value:i,issues:[]},h);if(f instanceof Promise)throw new Rr;if(f.issues.length){const b=new(u?.Err??e)(f.issues.map(v=>Ns(v,h,Cs())));throw Ak(b,u?.callee),b}return f.value},Og=e=>async(n,i,r,u)=>{const h=r?Object.assign(r,{async:!0}):{async:!0};let f=n._zod.run({value:i,issues:[]},h);if(f instanceof Promise&&(f=await f),f.issues.length){const b=new(u?.Err??e)(f.issues.map(v=>Ns(v,h,Cs())));throw Ak(b,u?.callee),b}return f.value},rm=e=>(n,i,r)=>{const u=r?{...r,async:!1}:{async:!1},h=n._zod.run({value:i,issues:[]},u);if(h instanceof Promise)throw new Rr;return h.issues.length?{success:!1,error:new(e??_k)(h.issues.map(f=>Ns(f,u,Cs())))}:{success:!0,data:h.value}},B8=rm(Tk),lm=e=>async(n,i,r)=>{const u=r?Object.assign(r,{async:!0}):{async:!0};let h=n._zod.run({value:i,issues:[]},u);return h instanceof Promise&&(h=await h),h.issues.length?{success:!1,error:new e(h.issues.map(f=>Ns(f,u,Cs())))}:{success:!0,data:h.value}},L8=lm(Tk),$8=e=>(n,i,r)=>{const u=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Ig(e)(n,i,u)},V8=e=>(n,i,r)=>Ig(e)(n,i,r),U8=e=>async(n,i,r)=>{const u=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Og(e)(n,i,u)},G8=e=>async(n,i,r)=>Og(e)(n,i,r),K8=e=>(n,i,r)=>{const u=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return rm(e)(n,i,u)},H8=e=>(n,i,r)=>rm(e)(n,i,r),Q8=e=>async(n,i,r)=>{const u=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return lm(e)(n,i,u)},F8=e=>async(n,i,r)=>lm(e)(n,i,r),Z8=/^[cC][^\s-]{8,}$/,Y8=/^[0-9a-z]+$/,X8=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,J8=/^[0-9a-vA-V]{20}$/,W8=/^[A-Za-z0-9]{27}$/,e7=/^[a-zA-Z0-9_-]{21}$/,t7=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,n7=/^([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})$/,dx=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)$/,a7=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,i7="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function s7(){return new RegExp(i7,"u")}const o7=/^(?:(?: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])$/,r7=/^(([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}|:))$/,l7=/^((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])$/,c7=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,u7=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Ek=/^[A-Za-z0-9_-]*$/,d7=/^\+[1-9]\d{6,14}$/,Rk="(?:(?:\\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])))",m7=new RegExp(`^${Rk}$`);function Dk(e){const n="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${n}`:e.precision===0?`${n}:[0-5]\\d`:`${n}:[0-5]\\d\\.\\d{${e.precision}}`:`${n}(?::[0-5]\\d(?:\\.\\d+)?)?`}function p7(e){return new RegExp(`^${Dk(e)}$`)}function h7(e){const n=Dk({precision:e.precision}),i=["Z"];e.local&&i.push(""),e.offset&&i.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");const r=`${n}(?:${i.join("|")})`;return new RegExp(`^${Rk}T(?:${r})$`)}const f7=e=>{const n=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${n}$`)},g7=/^-?\d+$/,zk=/^-?\d+(?:\.\d+)?$/,y7=/^(?:true|false)$/i,b7=/^null$/i,v7=/^[^A-Z]*$/,x7=/^[^a-z]*$/,na=ne("$ZodCheck",(e,n)=>{var i;e._zod??(e._zod={}),e._zod.def=n,(i=e._zod).onattach??(i.onattach=[])}),Ik={number:"number",bigint:"bigint",object:"date"},Ok=ne("$ZodCheckLessThan",(e,n)=>{na.init(e,n);const i=Ik[typeof n.value];e._zod.onattach.push(r=>{const u=r._zod.bag,h=(n.inclusive?u.maximum:u.exclusiveMaximum)??Number.POSITIVE_INFINITY;n.value<h&&(n.inclusive?u.maximum=n.value:u.exclusiveMaximum=n.value)}),e._zod.check=r=>{(n.inclusive?r.value<=n.value:r.value<n.value)||r.issues.push({origin:i,code:"too_big",maximum:typeof n.value=="object"?n.value.getTime():n.value,input:r.value,inclusive:n.inclusive,inst:e,continue:!n.abort})}}),qk=ne("$ZodCheckGreaterThan",(e,n)=>{na.init(e,n);const i=Ik[typeof n.value];e._zod.onattach.push(r=>{const u=r._zod.bag,h=(n.inclusive?u.minimum:u.exclusiveMinimum)??Number.NEGATIVE_INFINITY;n.value>h&&(n.inclusive?u.minimum=n.value:u.exclusiveMinimum=n.value)}),e._zod.check=r=>{(n.inclusive?r.value>=n.value:r.value>n.value)||r.issues.push({origin:i,code:"too_small",minimum:typeof n.value=="object"?n.value.getTime():n.value,input:r.value,inclusive:n.inclusive,inst:e,continue:!n.abort})}}),w7=ne("$ZodCheckMultipleOf",(e,n)=>{na.init(e,n),e._zod.onattach.push(i=>{var r;(r=i._zod.bag).multipleOf??(r.multipleOf=n.value)}),e._zod.check=i=>{if(typeof i.value!=typeof n.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof i.value=="bigint"?i.value%n.value===BigInt(0):j8(i.value,n.value)===0)||i.issues.push({origin:typeof i.value,code:"not_multiple_of",divisor:n.value,input:i.value,inst:e,continue:!n.abort})}}),S7=ne("$ZodCheckNumberFormat",(e,n)=>{na.init(e,n),n.format=n.format||"float64";const i=n.format?.includes("int"),r=i?"int":"number",[u,h]=T8[n.format];e._zod.onattach.push(f=>{const b=f._zod.bag;b.format=n.format,b.minimum=u,b.maximum=h,i&&(b.pattern=g7)}),e._zod.check=f=>{const b=f.value;if(i){if(!Number.isInteger(b)){f.issues.push({expected:r,format:n.format,code:"invalid_type",continue:!1,input:b,inst:e});return}if(!Number.isSafeInteger(b)){b>0?f.issues.push({input:b,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,inclusive:!0,continue:!n.abort}):f.issues.push({input:b,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,inclusive:!0,continue:!n.abort});return}}b<u&&f.issues.push({origin:"number",input:b,code:"too_small",minimum:u,inclusive:!0,inst:e,continue:!n.abort}),b>h&&f.issues.push({origin:"number",input:b,code:"too_big",maximum:h,inclusive:!0,inst:e,continue:!n.abort})}}),k7=ne("$ZodCheckMaxLength",(e,n)=>{var i;na.init(e,n),(i=e._zod.def).when??(i.when=r=>{const u=r.value;return!Rg(u)&&u.length!==void 0}),e._zod.onattach.push(r=>{const u=r._zod.bag.maximum??Number.POSITIVE_INFINITY;n.maximum<u&&(r._zod.bag.maximum=n.maximum)}),e._zod.check=r=>{const u=r.value;if(u.length<=n.maximum)return;const f=zg(u);r.issues.push({origin:f,code:"too_big",maximum:n.maximum,inclusive:!0,input:u,inst:e,continue:!n.abort})}}),j7=ne("$ZodCheckMinLength",(e,n)=>{var i;na.init(e,n),(i=e._zod.def).when??(i.when=r=>{const u=r.value;return!Rg(u)&&u.length!==void 0}),e._zod.onattach.push(r=>{const u=r._zod.bag.minimum??Number.NEGATIVE_INFINITY;n.minimum>u&&(r._zod.bag.minimum=n.minimum)}),e._zod.check=r=>{const u=r.value;if(u.length>=n.minimum)return;const f=zg(u);r.issues.push({origin:f,code:"too_small",minimum:n.minimum,inclusive:!0,input:u,inst:e,continue:!n.abort})}}),A7=ne("$ZodCheckLengthEquals",(e,n)=>{var i;na.init(e,n),(i=e._zod.def).when??(i.when=r=>{const u=r.value;return!Rg(u)&&u.length!==void 0}),e._zod.onattach.push(r=>{const u=r._zod.bag;u.minimum=n.length,u.maximum=n.length,u.length=n.length}),e._zod.check=r=>{const u=r.value,h=u.length;if(h===n.length)return;const f=zg(u),b=h>n.length;r.issues.push({origin:f,...b?{code:"too_big",maximum:n.length}:{code:"too_small",minimum:n.length},inclusive:!0,exact:!0,input:r.value,inst:e,continue:!n.abort})}}),cm=ne("$ZodCheckStringFormat",(e,n)=>{var i,r;na.init(e,n),e._zod.onattach.push(u=>{const h=u._zod.bag;h.format=n.format,n.pattern&&(h.patterns??(h.patterns=new Set),h.patterns.add(n.pattern))}),n.pattern?(i=e._zod).check??(i.check=u=>{n.pattern.lastIndex=0,!n.pattern.test(u.value)&&u.issues.push({origin:"string",code:"invalid_format",format:n.format,input:u.value,...n.pattern?{pattern:n.pattern.toString()}:{},inst:e,continue:!n.abort})}):(r=e._zod).check??(r.check=()=>{})}),C7=ne("$ZodCheckRegex",(e,n)=>{cm.init(e,n),e._zod.check=i=>{n.pattern.lastIndex=0,!n.pattern.test(i.value)&&i.issues.push({origin:"string",code:"invalid_format",format:"regex",input:i.value,pattern:n.pattern.toString(),inst:e,continue:!n.abort})}}),N7=ne("$ZodCheckLowerCase",(e,n)=>{n.pattern??(n.pattern=v7),cm.init(e,n)}),_7=ne("$ZodCheckUpperCase",(e,n)=>{n.pattern??(n.pattern=x7),cm.init(e,n)}),T7=ne("$ZodCheckIncludes",(e,n)=>{na.init(e,n);const i=qr(n.includes),r=new RegExp(typeof n.position=="number"?`^.{${n.position}}${i}`:i);n.pattern=r,e._zod.onattach.push(u=>{const h=u._zod.bag;h.patterns??(h.patterns=new Set),h.patterns.add(r)}),e._zod.check=u=>{u.value.includes(n.includes,n.position)||u.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:n.includes,input:u.value,inst:e,continue:!n.abort})}}),E7=ne("$ZodCheckStartsWith",(e,n)=>{na.init(e,n);const i=new RegExp(`^${qr(n.prefix)}.*`);n.pattern??(n.pattern=i),e._zod.onattach.push(r=>{const u=r._zod.bag;u.patterns??(u.patterns=new Set),u.patterns.add(i)}),e._zod.check=r=>{r.value.startsWith(n.prefix)||r.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:n.prefix,input:r.value,inst:e,continue:!n.abort})}}),R7=ne("$ZodCheckEndsWith",(e,n)=>{na.init(e,n);const i=new RegExp(`.*${qr(n.suffix)}$`);n.pattern??(n.pattern=i),e._zod.onattach.push(r=>{const u=r._zod.bag;u.patterns??(u.patterns=new Set),u.patterns.add(i)}),e._zod.check=r=>{r.value.endsWith(n.suffix)||r.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:n.suffix,input:r.value,inst:e,continue:!n.abort})}}),D7=ne("$ZodCheckOverwrite",(e,n)=>{na.init(e,n),e._zod.check=i=>{i.value=n.tx(i.value)}});class z7{constructor(n=[]){this.content=[],this.indent=0,this&&(this.args=n)}indented(n){this.indent+=1,n(this),this.indent-=1}write(n){if(typeof n=="function"){n(this,{execution:"sync"}),n(this,{execution:"async"});return}const r=n.split(`
|
|
15
|
+
`).filter(f=>f),u=Math.min(...r.map(f=>f.length-f.trimStart().length)),h=r.map(f=>f.slice(u)).map(f=>" ".repeat(this.indent*2)+f);for(const f of h)this.content.push(f)}compile(){const n=Function,i=this?.args,u=[...(this?.content??[""]).map(h=>` ${h}`)];return new n(...i,u.join(`
|
|
16
|
+
`))}}const I7={major:4,minor:3,patch:6},Bt=ne("$ZodType",(e,n)=>{var i;e??(e={}),e._zod.def=n,e._zod.bag=e._zod.bag||{},e._zod.version=I7;const r=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&r.unshift(e);for(const u of r)for(const h of u._zod.onattach)h(e);if(r.length===0)(i=e._zod).deferred??(i.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{const u=(f,b,v)=>{let x=_r(f),S;for(const k of b){if(k._zod.def.when){if(!k._zod.def.when(f))continue}else if(x)continue;const T=f.issues.length,N=k._zod.check(f);if(N instanceof Promise&&v?.async===!1)throw new Rr;if(S||N instanceof Promise)S=(S??Promise.resolve()).then(async()=>{await N,f.issues.length!==T&&(x||(x=_r(f,T)))});else{if(f.issues.length===T)continue;x||(x=_r(f,T))}}return S?S.then(()=>f):f},h=(f,b,v)=>{if(_r(f))return f.aborted=!0,f;const x=u(b,r,v);if(x instanceof Promise){if(v.async===!1)throw new Rr;return x.then(S=>e._zod.parse(S,v))}return e._zod.parse(x,v)};e._zod.run=(f,b)=>{if(b.skipChecks)return e._zod.parse(f,b);if(b.direction==="backward"){const x=e._zod.parse({value:f.value,issues:[]},{...b,skipChecks:!0});return x instanceof Promise?x.then(S=>h(S,f,b)):h(x,f,b)}const v=e._zod.parse(f,b);if(v instanceof Promise){if(b.async===!1)throw new Rr;return v.then(x=>u(x,r,b))}return u(v,r,b)}}gt(e,"~standard",()=>({validate:u=>{try{const h=B8(e,u);return h.success?{value:h.data}:{issues:h.error?.issues}}catch{return L8(e,u).then(f=>f.success?{value:f.data}:{issues:f.error?.issues})}},vendor:"zod",version:1}))}),qg=ne("$ZodString",(e,n)=>{Bt.init(e,n),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??f7(e._zod.bag),e._zod.parse=(i,r)=>{if(n.coerce)try{i.value=String(i.value)}catch{}return typeof i.value=="string"||i.issues.push({expected:"string",code:"invalid_type",input:i.value,inst:e}),i}}),Gt=ne("$ZodStringFormat",(e,n)=>{cm.init(e,n),qg.init(e,n)}),O7=ne("$ZodGUID",(e,n)=>{n.pattern??(n.pattern=n7),Gt.init(e,n)}),q7=ne("$ZodUUID",(e,n)=>{if(n.version){const r={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[n.version];if(r===void 0)throw new Error(`Invalid UUID version: "${n.version}"`);n.pattern??(n.pattern=dx(r))}else n.pattern??(n.pattern=dx());Gt.init(e,n)}),P7=ne("$ZodEmail",(e,n)=>{n.pattern??(n.pattern=a7),Gt.init(e,n)}),M7=ne("$ZodURL",(e,n)=>{Gt.init(e,n),e._zod.check=i=>{try{const r=i.value.trim(),u=new URL(r);n.hostname&&(n.hostname.lastIndex=0,n.hostname.test(u.hostname)||i.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:n.hostname.source,input:i.value,inst:e,continue:!n.abort})),n.protocol&&(n.protocol.lastIndex=0,n.protocol.test(u.protocol.endsWith(":")?u.protocol.slice(0,-1):u.protocol)||i.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:n.protocol.source,input:i.value,inst:e,continue:!n.abort})),n.normalize?i.value=u.href:i.value=r;return}catch{i.issues.push({code:"invalid_format",format:"url",input:i.value,inst:e,continue:!n.abort})}}}),B7=ne("$ZodEmoji",(e,n)=>{n.pattern??(n.pattern=s7()),Gt.init(e,n)}),L7=ne("$ZodNanoID",(e,n)=>{n.pattern??(n.pattern=e7),Gt.init(e,n)}),$7=ne("$ZodCUID",(e,n)=>{n.pattern??(n.pattern=Z8),Gt.init(e,n)}),V7=ne("$ZodCUID2",(e,n)=>{n.pattern??(n.pattern=Y8),Gt.init(e,n)}),U7=ne("$ZodULID",(e,n)=>{n.pattern??(n.pattern=X8),Gt.init(e,n)}),G7=ne("$ZodXID",(e,n)=>{n.pattern??(n.pattern=J8),Gt.init(e,n)}),K7=ne("$ZodKSUID",(e,n)=>{n.pattern??(n.pattern=W8),Gt.init(e,n)}),H7=ne("$ZodISODateTime",(e,n)=>{n.pattern??(n.pattern=h7(n)),Gt.init(e,n)}),Q7=ne("$ZodISODate",(e,n)=>{n.pattern??(n.pattern=m7),Gt.init(e,n)}),F7=ne("$ZodISOTime",(e,n)=>{n.pattern??(n.pattern=p7(n)),Gt.init(e,n)}),Z7=ne("$ZodISODuration",(e,n)=>{n.pattern??(n.pattern=t7),Gt.init(e,n)}),Y7=ne("$ZodIPv4",(e,n)=>{n.pattern??(n.pattern=o7),Gt.init(e,n),e._zod.bag.format="ipv4"}),X7=ne("$ZodIPv6",(e,n)=>{n.pattern??(n.pattern=r7),Gt.init(e,n),e._zod.bag.format="ipv6",e._zod.check=i=>{try{new URL(`http://[${i.value}]`)}catch{i.issues.push({code:"invalid_format",format:"ipv6",input:i.value,inst:e,continue:!n.abort})}}}),J7=ne("$ZodCIDRv4",(e,n)=>{n.pattern??(n.pattern=l7),Gt.init(e,n)}),W7=ne("$ZodCIDRv6",(e,n)=>{n.pattern??(n.pattern=c7),Gt.init(e,n),e._zod.check=i=>{const r=i.value.split("/");try{if(r.length!==2)throw new Error;const[u,h]=r;if(!h)throw new Error;const f=Number(h);if(`${f}`!==h)throw new Error;if(f<0||f>128)throw new Error;new URL(`http://[${u}]`)}catch{i.issues.push({code:"invalid_format",format:"cidrv6",input:i.value,inst:e,continue:!n.abort})}}});function Pk(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}const eE=ne("$ZodBase64",(e,n)=>{n.pattern??(n.pattern=u7),Gt.init(e,n),e._zod.bag.contentEncoding="base64",e._zod.check=i=>{Pk(i.value)||i.issues.push({code:"invalid_format",format:"base64",input:i.value,inst:e,continue:!n.abort})}});function tE(e){if(!Ek.test(e))return!1;const n=e.replace(/[-_]/g,r=>r==="-"?"+":"/"),i=n.padEnd(Math.ceil(n.length/4)*4,"=");return Pk(i)}const nE=ne("$ZodBase64URL",(e,n)=>{n.pattern??(n.pattern=Ek),Gt.init(e,n),e._zod.bag.contentEncoding="base64url",e._zod.check=i=>{tE(i.value)||i.issues.push({code:"invalid_format",format:"base64url",input:i.value,inst:e,continue:!n.abort})}}),aE=ne("$ZodE164",(e,n)=>{n.pattern??(n.pattern=d7),Gt.init(e,n)});function iE(e,n=null){try{const i=e.split(".");if(i.length!==3)return!1;const[r]=i;if(!r)return!1;const u=JSON.parse(atob(r));return!("typ"in u&&u?.typ!=="JWT"||!u.alg||n&&(!("alg"in u)||u.alg!==n))}catch{return!1}}const sE=ne("$ZodJWT",(e,n)=>{Gt.init(e,n),e._zod.check=i=>{iE(i.value,n.alg)||i.issues.push({code:"invalid_format",format:"jwt",input:i.value,inst:e,continue:!n.abort})}}),Mk=ne("$ZodNumber",(e,n)=>{Bt.init(e,n),e._zod.pattern=e._zod.bag.pattern??zk,e._zod.parse=(i,r)=>{if(n.coerce)try{i.value=Number(i.value)}catch{}const u=i.value;if(typeof u=="number"&&!Number.isNaN(u)&&Number.isFinite(u))return i;const h=typeof u=="number"?Number.isNaN(u)?"NaN":Number.isFinite(u)?void 0:"Infinity":void 0;return i.issues.push({expected:"number",code:"invalid_type",input:u,inst:e,...h?{received:h}:{}}),i}}),oE=ne("$ZodNumberFormat",(e,n)=>{S7.init(e,n),Mk.init(e,n)}),rE=ne("$ZodBoolean",(e,n)=>{Bt.init(e,n),e._zod.pattern=y7,e._zod.parse=(i,r)=>{if(n.coerce)try{i.value=!!i.value}catch{}const u=i.value;return typeof u=="boolean"||i.issues.push({expected:"boolean",code:"invalid_type",input:u,inst:e}),i}}),lE=ne("$ZodNull",(e,n)=>{Bt.init(e,n),e._zod.pattern=b7,e._zod.values=new Set([null]),e._zod.parse=(i,r)=>{const u=i.value;return u===null||i.issues.push({expected:"null",code:"invalid_type",input:u,inst:e}),i}}),cE=ne("$ZodUnknown",(e,n)=>{Bt.init(e,n),e._zod.parse=i=>i}),uE=ne("$ZodNever",(e,n)=>{Bt.init(e,n),e._zod.parse=(i,r)=>(i.issues.push({expected:"never",code:"invalid_type",input:i.value,inst:e}),i)});function mx(e,n,i){e.issues.length&&n.issues.push(...Tr(i,e.issues)),n.value[i]=e.value}const dE=ne("$ZodArray",(e,n)=>{Bt.init(e,n),e._zod.parse=(i,r)=>{const u=i.value;if(!Array.isArray(u))return i.issues.push({expected:"array",code:"invalid_type",input:u,inst:e}),i;i.value=Array(u.length);const h=[];for(let f=0;f<u.length;f++){const b=u[f],v=n.element._zod.run({value:b,issues:[]},r);v instanceof Promise?h.push(v.then(x=>mx(x,i,f))):mx(v,i,f)}return h.length?Promise.all(h).then(()=>i):i}});function Dd(e,n,i,r,u){if(e.issues.length){if(u&&!(i in r))return;n.issues.push(...Tr(i,e.issues))}e.value===void 0?i in r&&(n.value[i]=void 0):n.value[i]=e.value}function Bk(e){const n=Object.keys(e.shape);for(const r of n)if(!e.shape?.[r]?._zod?.traits?.has("$ZodType"))throw new Error(`Invalid element at key "${r}": expected a Zod schema`);const i=_8(e.shape);return{...e,keys:n,keySet:new Set(n),numKeys:n.length,optionalKeys:new Set(i)}}function Lk(e,n,i,r,u,h){const f=[],b=u.keySet,v=u.catchall._zod,x=v.def.type,S=v.optout==="optional";for(const k in n){if(b.has(k))continue;if(x==="never"){f.push(k);continue}const T=v.run({value:n[k],issues:[]},r);T instanceof Promise?e.push(T.then(N=>Dd(N,i,k,n,S))):Dd(T,i,k,n,S)}return f.length&&i.issues.push({code:"unrecognized_keys",keys:f,input:n,inst:h}),e.length?Promise.all(e).then(()=>i):i}const mE=ne("$ZodObject",(e,n)=>{if(Bt.init(e,n),!Object.getOwnPropertyDescriptor(n,"shape")?.get){const b=n.shape;Object.defineProperty(n,"shape",{get:()=>{const v={...b};return Object.defineProperty(n,"shape",{value:v}),v}})}const r=om(()=>Bk(n));gt(e._zod,"propValues",()=>{const b=n.shape,v={};for(const x in b){const S=b[x]._zod;if(S.values){v[x]??(v[x]=new Set);for(const k of S.values)v[x].add(k)}}return v});const u=Sc,h=n.catchall;let f;e._zod.parse=(b,v)=>{f??(f=r.value);const x=b.value;if(!u(x))return b.issues.push({expected:"object",code:"invalid_type",input:x,inst:e}),b;b.value={};const S=[],k=f.shape;for(const T of f.keys){const N=k[T],I=N._zod.optout==="optional",P=N._zod.run({value:x[T],issues:[]},v);P instanceof Promise?S.push(P.then(E=>Dd(E,b,T,x,I))):Dd(P,b,T,x,I)}return h?Lk(S,x,b,v,r.value,e):S.length?Promise.all(S).then(()=>b):b}}),pE=ne("$ZodObjectJIT",(e,n)=>{mE.init(e,n);const i=e._zod.parse,r=om(()=>Bk(n)),u=T=>{const N=new z7(["shape","payload","ctx"]),I=r.value,P=L=>{const F=ux(L);return`shape[${F}]._zod.run({ value: input[${F}], issues: [] }, ctx)`};N.write("const input = payload.value;");const E=Object.create(null);let $=0;for(const L of I.keys)E[L]=`key_${$++}`;N.write("const newResult = {};");for(const L of I.keys){const F=E[L],Z=ux(L),M=T[L]?._zod?.optout==="optional";N.write(`const ${F} = ${P(L)};`),M?N.write(`
|
|
17
|
+
if (${F}.issues.length) {
|
|
18
|
+
if (${Z} in input) {
|
|
19
|
+
payload.issues = payload.issues.concat(${F}.issues.map(iss => ({
|
|
20
|
+
...iss,
|
|
21
|
+
path: iss.path ? [${Z}, ...iss.path] : [${Z}]
|
|
22
|
+
})));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
if (${F}.value === undefined) {
|
|
27
|
+
if (${Z} in input) {
|
|
28
|
+
newResult[${Z}] = undefined;
|
|
29
|
+
}
|
|
30
|
+
} else {
|
|
31
|
+
newResult[${Z}] = ${F}.value;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
`):N.write(`
|
|
35
|
+
if (${F}.issues.length) {
|
|
36
|
+
payload.issues = payload.issues.concat(${F}.issues.map(iss => ({
|
|
37
|
+
...iss,
|
|
38
|
+
path: iss.path ? [${Z}, ...iss.path] : [${Z}]
|
|
39
|
+
})));
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
if (${F}.value === undefined) {
|
|
43
|
+
if (${Z} in input) {
|
|
44
|
+
newResult[${Z}] = undefined;
|
|
45
|
+
}
|
|
46
|
+
} else {
|
|
47
|
+
newResult[${Z}] = ${F}.value;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
`)}N.write("payload.value = newResult;"),N.write("return payload;");const ee=N.compile();return(L,F)=>ee(T,L,F)};let h;const f=Sc,b=!kk.jitless,x=b&&C8.value,S=n.catchall;let k;e._zod.parse=(T,N)=>{k??(k=r.value);const I=T.value;return f(I)?b&&x&&N?.async===!1&&N.jitless!==!0?(h||(h=u(n.shape)),T=h(T,N),S?Lk([],I,T,N,k,e):T):i(T,N):(T.issues.push({expected:"object",code:"invalid_type",input:I,inst:e}),T)}});function px(e,n,i,r){for(const h of e)if(h.issues.length===0)return n.value=h.value,n;const u=e.filter(h=>!_r(h));return u.length===1?(n.value=u[0].value,u[0]):(n.issues.push({code:"invalid_union",input:n.value,inst:i,errors:e.map(h=>h.issues.map(f=>Ns(f,r,Cs())))}),n)}const $k=ne("$ZodUnion",(e,n)=>{Bt.init(e,n),gt(e._zod,"optin",()=>n.options.some(u=>u._zod.optin==="optional")?"optional":void 0),gt(e._zod,"optout",()=>n.options.some(u=>u._zod.optout==="optional")?"optional":void 0),gt(e._zod,"values",()=>{if(n.options.every(u=>u._zod.values))return new Set(n.options.flatMap(u=>Array.from(u._zod.values)))}),gt(e._zod,"pattern",()=>{if(n.options.every(u=>u._zod.pattern)){const u=n.options.map(h=>h._zod.pattern);return new RegExp(`^(${u.map(h=>Dg(h.source)).join("|")})$`)}});const i=n.options.length===1,r=n.options[0]._zod.run;e._zod.parse=(u,h)=>{if(i)return r(u,h);let f=!1;const b=[];for(const v of n.options){const x=v._zod.run({value:u.value,issues:[]},h);if(x instanceof Promise)b.push(x),f=!0;else{if(x.issues.length===0)return x;b.push(x)}}return f?Promise.all(b).then(v=>px(v,u,e,h)):px(b,u,e,h)}}),hE=ne("$ZodDiscriminatedUnion",(e,n)=>{n.inclusive=!1,$k.init(e,n);const i=e._zod.parse;gt(e._zod,"propValues",()=>{const u={};for(const h of n.options){const f=h._zod.propValues;if(!f||Object.keys(f).length===0)throw new Error(`Invalid discriminated union option at index "${n.options.indexOf(h)}"`);for(const[b,v]of Object.entries(f)){u[b]||(u[b]=new Set);for(const x of v)u[b].add(x)}}return u});const r=om(()=>{const u=n.options,h=new Map;for(const f of u){const b=f._zod.propValues?.[n.discriminator];if(!b||b.size===0)throw new Error(`Invalid discriminated union option at index "${n.options.indexOf(f)}"`);for(const v of b){if(h.has(v))throw new Error(`Duplicate discriminator value "${String(v)}"`);h.set(v,f)}}return h});e._zod.parse=(u,h)=>{const f=u.value;if(!Sc(f))return u.issues.push({code:"invalid_type",expected:"object",input:f,inst:e}),u;const b=r.value.get(f?.[n.discriminator]);return b?b._zod.run(u,h):n.unionFallback?i(u,h):(u.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:n.discriminator,input:f,path:[n.discriminator],inst:e}),u)}}),fE=ne("$ZodIntersection",(e,n)=>{Bt.init(e,n),e._zod.parse=(i,r)=>{const u=i.value,h=n.left._zod.run({value:u,issues:[]},r),f=n.right._zod.run({value:u,issues:[]},r);return h instanceof Promise||f instanceof Promise?Promise.all([h,f]).then(([v,x])=>hx(i,v,x)):hx(i,h,f)}});function Pf(e,n){if(e===n)return{valid:!0,data:e};if(e instanceof Date&&n instanceof Date&&+e==+n)return{valid:!0,data:e};if(Or(e)&&Or(n)){const i=Object.keys(n),r=Object.keys(e).filter(h=>i.indexOf(h)!==-1),u={...e,...n};for(const h of r){const f=Pf(e[h],n[h]);if(!f.valid)return{valid:!1,mergeErrorPath:[h,...f.mergeErrorPath]};u[h]=f.data}return{valid:!0,data:u}}if(Array.isArray(e)&&Array.isArray(n)){if(e.length!==n.length)return{valid:!1,mergeErrorPath:[]};const i=[];for(let r=0;r<e.length;r++){const u=e[r],h=n[r],f=Pf(u,h);if(!f.valid)return{valid:!1,mergeErrorPath:[r,...f.mergeErrorPath]};i.push(f.data)}return{valid:!0,data:i}}return{valid:!1,mergeErrorPath:[]}}function hx(e,n,i){const r=new Map;let u;for(const b of n.issues)if(b.code==="unrecognized_keys"){u??(u=b);for(const v of b.keys)r.has(v)||r.set(v,{}),r.get(v).l=!0}else e.issues.push(b);for(const b of i.issues)if(b.code==="unrecognized_keys")for(const v of b.keys)r.has(v)||r.set(v,{}),r.get(v).r=!0;else e.issues.push(b);const h=[...r].filter(([,b])=>b.l&&b.r).map(([b])=>b);if(h.length&&u&&e.issues.push({...u,keys:h}),_r(e))return e;const f=Pf(n.value,i.value);if(!f.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(f.mergeErrorPath)}`);return e.value=f.data,e}const gE=ne("$ZodRecord",(e,n)=>{Bt.init(e,n),e._zod.parse=(i,r)=>{const u=i.value;if(!Or(u))return i.issues.push({expected:"record",code:"invalid_type",input:u,inst:e}),i;const h=[],f=n.keyType._zod.values;if(f){i.value={};const b=new Set;for(const x of f)if(typeof x=="string"||typeof x=="number"||typeof x=="symbol"){b.add(typeof x=="number"?x.toString():x);const S=n.valueType._zod.run({value:u[x],issues:[]},r);S instanceof Promise?h.push(S.then(k=>{k.issues.length&&i.issues.push(...Tr(x,k.issues)),i.value[x]=k.value})):(S.issues.length&&i.issues.push(...Tr(x,S.issues)),i.value[x]=S.value)}let v;for(const x in u)b.has(x)||(v=v??[],v.push(x));v&&v.length>0&&i.issues.push({code:"unrecognized_keys",input:u,inst:e,keys:v})}else{i.value={};for(const b of Reflect.ownKeys(u)){if(b==="__proto__")continue;let v=n.keyType._zod.run({value:b,issues:[]},r);if(v instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof b=="string"&&zk.test(b)&&v.issues.length){const k=n.keyType._zod.run({value:Number(b),issues:[]},r);if(k instanceof Promise)throw new Error("Async schemas not supported in object keys currently");k.issues.length===0&&(v=k)}if(v.issues.length){n.mode==="loose"?i.value[b]=u[b]:i.issues.push({code:"invalid_key",origin:"record",issues:v.issues.map(k=>Ns(k,r,Cs())),input:b,path:[b],inst:e});continue}const S=n.valueType._zod.run({value:u[b],issues:[]},r);S instanceof Promise?h.push(S.then(k=>{k.issues.length&&i.issues.push(...Tr(b,k.issues)),i.value[v.value]=k.value})):(S.issues.length&&i.issues.push(...Tr(b,S.issues)),i.value[v.value]=S.value)}}return h.length?Promise.all(h).then(()=>i):i}}),yE=ne("$ZodEnum",(e,n)=>{Bt.init(e,n);const i=jk(n.entries),r=new Set(i);e._zod.values=r,e._zod.pattern=new RegExp(`^(${i.filter(u=>N8.has(typeof u)).map(u=>typeof u=="string"?qr(u):u.toString()).join("|")})$`),e._zod.parse=(u,h)=>{const f=u.value;return r.has(f)||u.issues.push({code:"invalid_value",values:i,input:f,inst:e}),u}}),bE=ne("$ZodLiteral",(e,n)=>{if(Bt.init(e,n),n.values.length===0)throw new Error("Cannot create literal schema with no valid values");const i=new Set(n.values);e._zod.values=i,e._zod.pattern=new RegExp(`^(${n.values.map(r=>typeof r=="string"?qr(r):r?qr(r.toString()):String(r)).join("|")})$`),e._zod.parse=(r,u)=>{const h=r.value;return i.has(h)||r.issues.push({code:"invalid_value",values:n.values,input:h,inst:e}),r}}),vE=ne("$ZodTransform",(e,n)=>{Bt.init(e,n),e._zod.parse=(i,r)=>{if(r.direction==="backward")throw new Sk(e.constructor.name);const u=n.transform(i.value,i);if(r.async)return(u instanceof Promise?u:Promise.resolve(u)).then(f=>(i.value=f,i));if(u instanceof Promise)throw new Rr;return i.value=u,i}});function fx(e,n){return e.issues.length&&n===void 0?{issues:[],value:void 0}:e}const Vk=ne("$ZodOptional",(e,n)=>{Bt.init(e,n),e._zod.optin="optional",e._zod.optout="optional",gt(e._zod,"values",()=>n.innerType._zod.values?new Set([...n.innerType._zod.values,void 0]):void 0),gt(e._zod,"pattern",()=>{const i=n.innerType._zod.pattern;return i?new RegExp(`^(${Dg(i.source)})?$`):void 0}),e._zod.parse=(i,r)=>{if(n.innerType._zod.optin==="optional"){const u=n.innerType._zod.run(i,r);return u instanceof Promise?u.then(h=>fx(h,i.value)):fx(u,i.value)}return i.value===void 0?i:n.innerType._zod.run(i,r)}}),xE=ne("$ZodExactOptional",(e,n)=>{Vk.init(e,n),gt(e._zod,"values",()=>n.innerType._zod.values),gt(e._zod,"pattern",()=>n.innerType._zod.pattern),e._zod.parse=(i,r)=>n.innerType._zod.run(i,r)}),wE=ne("$ZodNullable",(e,n)=>{Bt.init(e,n),gt(e._zod,"optin",()=>n.innerType._zod.optin),gt(e._zod,"optout",()=>n.innerType._zod.optout),gt(e._zod,"pattern",()=>{const i=n.innerType._zod.pattern;return i?new RegExp(`^(${Dg(i.source)}|null)$`):void 0}),gt(e._zod,"values",()=>n.innerType._zod.values?new Set([...n.innerType._zod.values,null]):void 0),e._zod.parse=(i,r)=>i.value===null?i:n.innerType._zod.run(i,r)}),SE=ne("$ZodDefault",(e,n)=>{Bt.init(e,n),e._zod.optin="optional",gt(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(i,r)=>{if(r.direction==="backward")return n.innerType._zod.run(i,r);if(i.value===void 0)return i.value=n.defaultValue,i;const u=n.innerType._zod.run(i,r);return u instanceof Promise?u.then(h=>gx(h,n)):gx(u,n)}});function gx(e,n){return e.value===void 0&&(e.value=n.defaultValue),e}const kE=ne("$ZodPrefault",(e,n)=>{Bt.init(e,n),e._zod.optin="optional",gt(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(i,r)=>(r.direction==="backward"||i.value===void 0&&(i.value=n.defaultValue),n.innerType._zod.run(i,r))}),jE=ne("$ZodNonOptional",(e,n)=>{Bt.init(e,n),gt(e._zod,"values",()=>{const i=n.innerType._zod.values;return i?new Set([...i].filter(r=>r!==void 0)):void 0}),e._zod.parse=(i,r)=>{const u=n.innerType._zod.run(i,r);return u instanceof Promise?u.then(h=>yx(h,e)):yx(u,e)}});function yx(e,n){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:n}),e}const AE=ne("$ZodCatch",(e,n)=>{Bt.init(e,n),gt(e._zod,"optin",()=>n.innerType._zod.optin),gt(e._zod,"optout",()=>n.innerType._zod.optout),gt(e._zod,"values",()=>n.innerType._zod.values),e._zod.parse=(i,r)=>{if(r.direction==="backward")return n.innerType._zod.run(i,r);const u=n.innerType._zod.run(i,r);return u instanceof Promise?u.then(h=>(i.value=h.value,h.issues.length&&(i.value=n.catchValue({...i,error:{issues:h.issues.map(f=>Ns(f,r,Cs()))},input:i.value}),i.issues=[]),i)):(i.value=u.value,u.issues.length&&(i.value=n.catchValue({...i,error:{issues:u.issues.map(h=>Ns(h,r,Cs()))},input:i.value}),i.issues=[]),i)}}),CE=ne("$ZodPipe",(e,n)=>{Bt.init(e,n),gt(e._zod,"values",()=>n.in._zod.values),gt(e._zod,"optin",()=>n.in._zod.optin),gt(e._zod,"optout",()=>n.out._zod.optout),gt(e._zod,"propValues",()=>n.in._zod.propValues),e._zod.parse=(i,r)=>{if(r.direction==="backward"){const h=n.out._zod.run(i,r);return h instanceof Promise?h.then(f=>od(f,n.in,r)):od(h,n.in,r)}const u=n.in._zod.run(i,r);return u instanceof Promise?u.then(h=>od(h,n.out,r)):od(u,n.out,r)}});function od(e,n,i){return e.issues.length?(e.aborted=!0,e):n._zod.run({value:e.value,issues:e.issues},i)}const NE=ne("$ZodReadonly",(e,n)=>{Bt.init(e,n),gt(e._zod,"propValues",()=>n.innerType._zod.propValues),gt(e._zod,"values",()=>n.innerType._zod.values),gt(e._zod,"optin",()=>n.innerType?._zod?.optin),gt(e._zod,"optout",()=>n.innerType?._zod?.optout),e._zod.parse=(i,r)=>{if(r.direction==="backward")return n.innerType._zod.run(i,r);const u=n.innerType._zod.run(i,r);return u instanceof Promise?u.then(bx):bx(u)}});function bx(e){return e.value=Object.freeze(e.value),e}const _E=ne("$ZodLazy",(e,n)=>{Bt.init(e,n),gt(e._zod,"innerType",()=>n.getter()),gt(e._zod,"pattern",()=>e._zod.innerType?._zod?.pattern),gt(e._zod,"propValues",()=>e._zod.innerType?._zod?.propValues),gt(e._zod,"optin",()=>e._zod.innerType?._zod?.optin??void 0),gt(e._zod,"optout",()=>e._zod.innerType?._zod?.optout??void 0),e._zod.parse=(i,r)=>e._zod.innerType._zod.run(i,r)}),TE=ne("$ZodCustom",(e,n)=>{na.init(e,n),Bt.init(e,n),e._zod.parse=(i,r)=>i,e._zod.check=i=>{const r=i.value,u=n.fn(r);if(u instanceof Promise)return u.then(h=>vx(h,i,r,e));vx(u,i,r,e)}});function vx(e,n,i,r){if(!e){const u={code:"custom",input:i,inst:r,path:[...r._zod.def.path??[]],continue:!r._zod.def.abort};r._zod.def.params&&(u.params=r._zod.def.params),n.issues.push(kc(u))}}var xx;class EE{constructor(){this._map=new WeakMap,this._idmap=new Map}add(n,...i){const r=i[0];return this._map.set(n,r),r&&typeof r=="object"&&"id"in r&&this._idmap.set(r.id,n),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(n){const i=this._map.get(n);return i&&typeof i=="object"&&"id"in i&&this._idmap.delete(i.id),this._map.delete(n),this}get(n){const i=n._zod.parent;if(i){const r={...this.get(i)??{}};delete r.id;const u={...r,...this._map.get(n)};return Object.keys(u).length?u:void 0}return this._map.get(n)}has(n){return this._map.has(n)}}function RE(){return new EE}(xx=globalThis).__zod_globalRegistry??(xx.__zod_globalRegistry=RE());const dc=globalThis.__zod_globalRegistry;function DE(e,n){return new e({type:"string",...De(n)})}function zE(e,n){return new e({type:"string",format:"email",check:"string_format",abort:!1,...De(n)})}function wx(e,n){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...De(n)})}function Uk(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...De(n)})}function IE(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...De(n)})}function OE(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...De(n)})}function qE(e,n){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...De(n)})}function PE(e,n){return new e({type:"string",format:"url",check:"string_format",abort:!1,...De(n)})}function ME(e,n){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...De(n)})}function BE(e,n){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...De(n)})}function LE(e,n){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...De(n)})}function $E(e,n){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...De(n)})}function VE(e,n){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...De(n)})}function UE(e,n){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...De(n)})}function GE(e,n){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...De(n)})}function KE(e,n){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...De(n)})}function HE(e,n){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...De(n)})}function QE(e,n){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...De(n)})}function FE(e,n){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...De(n)})}function ZE(e,n){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...De(n)})}function YE(e,n){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...De(n)})}function XE(e,n){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...De(n)})}function JE(e,n){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...De(n)})}function WE(e,n){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...De(n)})}function eR(e,n){return new e({type:"string",format:"date",check:"string_format",...De(n)})}function tR(e,n){return new e({type:"string",format:"time",check:"string_format",precision:null,...De(n)})}function nR(e,n){return new e({type:"string",format:"duration",check:"string_format",...De(n)})}function aR(e,n){return new e({type:"number",checks:[],...De(n)})}function iR(e,n){return new e({type:"number",coerce:!0,checks:[],...De(n)})}function sR(e,n){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...De(n)})}function oR(e,n){return new e({type:"boolean",...De(n)})}function rR(e,n){return new e({type:"null",...De(n)})}function lR(e){return new e({type:"unknown"})}function cR(e,n){return new e({type:"never",...De(n)})}function Sx(e,n){return new Ok({check:"less_than",...De(n),value:e,inclusive:!1})}function Yh(e,n){return new Ok({check:"less_than",...De(n),value:e,inclusive:!0})}function kx(e,n){return new qk({check:"greater_than",...De(n),value:e,inclusive:!1})}function Xh(e,n){return new qk({check:"greater_than",...De(n),value:e,inclusive:!0})}function jx(e,n){return new w7({check:"multiple_of",...De(n),value:e})}function Gk(e,n){return new k7({check:"max_length",...De(n),maximum:e})}function zd(e,n){return new j7({check:"min_length",...De(n),minimum:e})}function Kk(e,n){return new A7({check:"length_equals",...De(n),length:e})}function uR(e,n){return new C7({check:"string_format",format:"regex",...De(n),pattern:e})}function dR(e){return new N7({check:"string_format",format:"lowercase",...De(e)})}function mR(e){return new _7({check:"string_format",format:"uppercase",...De(e)})}function pR(e,n){return new T7({check:"string_format",format:"includes",...De(n),includes:e})}function hR(e,n){return new E7({check:"string_format",format:"starts_with",...De(n),prefix:e})}function fR(e,n){return new R7({check:"string_format",format:"ends_with",...De(n),suffix:e})}function Qr(e){return new D7({check:"overwrite",tx:e})}function gR(e){return Qr(n=>n.normalize(e))}function yR(){return Qr(e=>e.trim())}function bR(){return Qr(e=>e.toLowerCase())}function vR(){return Qr(e=>e.toUpperCase())}function xR(){return Qr(e=>A8(e))}function wR(e,n,i){return new e({type:"array",element:n,...De(i)})}function SR(e,n,i){return new e({type:"custom",check:"custom",fn:n,...De(i)})}function kR(e){const n=jR(i=>(i.addIssue=r=>{if(typeof r=="string")i.issues.push(kc(r,i.value,n._zod.def));else{const u=r;u.fatal&&(u.continue=!1),u.code??(u.code="custom"),u.input??(u.input=i.value),u.inst??(u.inst=n),u.continue??(u.continue=!n._zod.def.abort),i.issues.push(kc(u))}},e(i.value,i)));return n}function jR(e,n){const i=new na({check:"custom",...De(n)});return i._zod.check=e,i}function Hk(e){let n=e?.target??"draft-2020-12";return n==="draft-4"&&(n="draft-04"),n==="draft-7"&&(n="draft-07"),{processors:e.processors??{},metadataRegistry:e?.metadata??dc,target:n,unrepresentable:e?.unrepresentable??"throw",override:e?.override??(()=>{}),io:e?.io??"output",counter:0,seen:new Map,cycles:e?.cycles??"ref",reused:e?.reused??"inline",external:e?.external??void 0}}function an(e,n,i={path:[],schemaPath:[]}){var r;const u=e._zod.def,h=n.seen.get(e);if(h)return h.count++,i.schemaPath.includes(e)&&(h.cycle=i.path),h.schema;const f={schema:{},count:1,cycle:void 0,path:i.path};n.seen.set(e,f);const b=e._zod.toJSONSchema?.();if(b)f.schema=b;else{const S={...i,schemaPath:[...i.schemaPath,e],path:i.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(n,f.schema,S);else{const T=f.schema,N=n.processors[u.type];if(!N)throw new Error(`[toJSONSchema]: Non-representable type encountered: ${u.type}`);N(e,n,T,S)}const k=e._zod.parent;k&&(f.ref||(f.ref=k),an(k,n,S),n.seen.get(k).isParent=!0)}const v=n.metadataRegistry.get(e);return v&&Object.assign(f.schema,v),n.io==="input"&&Vn(e)&&(delete f.schema.examples,delete f.schema.default),n.io==="input"&&f.schema._prefault&&((r=f.schema).default??(r.default=f.schema._prefault)),delete f.schema._prefault,n.seen.get(e).schema}function Qk(e,n){const i=e.seen.get(n);if(!i)throw new Error("Unprocessed schema. This is a bug in Zod.");const r=new Map;for(const f of e.seen.entries()){const b=e.metadataRegistry.get(f[0])?.id;if(b){const v=r.get(b);if(v&&v!==f[0])throw new Error(`Duplicate schema id "${b}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);r.set(b,f[0])}}const u=f=>{const b=e.target==="draft-2020-12"?"$defs":"definitions";if(e.external){const k=e.external.registry.get(f[0])?.id,T=e.external.uri??(I=>I);if(k)return{ref:T(k)};const N=f[1].defId??f[1].schema.id??`schema${e.counter++}`;return f[1].defId=N,{defId:N,ref:`${T("__shared")}#/${b}/${N}`}}if(f[1]===i)return{ref:"#"};const x=`#/${b}/`,S=f[1].schema.id??`__schema${e.counter++}`;return{defId:S,ref:x+S}},h=f=>{if(f[1].schema.$ref)return;const b=f[1],{ref:v,defId:x}=u(f);b.def={...b.schema},x&&(b.defId=x);const S=b.schema;for(const k in S)delete S[k];S.$ref=v};if(e.cycles==="throw")for(const f of e.seen.entries()){const b=f[1];if(b.cycle)throw new Error(`Cycle detected: #/${b.cycle?.join("/")}/<root>
|
|
51
|
+
|
|
52
|
+
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(const f of e.seen.entries()){const b=f[1];if(n===f[0]){h(f);continue}if(e.external){const x=e.external.registry.get(f[0])?.id;if(n!==f[0]&&x){h(f);continue}}if(e.metadataRegistry.get(f[0])?.id){h(f);continue}if(b.cycle){h(f);continue}if(b.count>1&&e.reused==="ref"){h(f);continue}}}function Fk(e,n){const i=e.seen.get(n);if(!i)throw new Error("Unprocessed schema. This is a bug in Zod.");const r=f=>{const b=e.seen.get(f);if(b.ref===null)return;const v=b.def??b.schema,x={...v},S=b.ref;if(b.ref=null,S){r(S);const T=e.seen.get(S),N=T.schema;if(N.$ref&&(e.target==="draft-07"||e.target==="draft-04"||e.target==="openapi-3.0")?(v.allOf=v.allOf??[],v.allOf.push(N)):Object.assign(v,N),Object.assign(v,x),f._zod.parent===S)for(const P in v)P==="$ref"||P==="allOf"||P in x||delete v[P];if(N.$ref&&T.def)for(const P in v)P==="$ref"||P==="allOf"||P in T.def&&JSON.stringify(v[P])===JSON.stringify(T.def[P])&&delete v[P]}const k=f._zod.parent;if(k&&k!==S){r(k);const T=e.seen.get(k);if(T?.schema.$ref&&(v.$ref=T.schema.$ref,T.def))for(const N in v)N==="$ref"||N==="allOf"||N in T.def&&JSON.stringify(v[N])===JSON.stringify(T.def[N])&&delete v[N]}e.override({zodSchema:f,jsonSchema:v,path:b.path??[]})};for(const f of[...e.seen.entries()].reverse())r(f[0]);const u={};if(e.target==="draft-2020-12"?u.$schema="https://json-schema.org/draft/2020-12/schema":e.target==="draft-07"?u.$schema="http://json-schema.org/draft-07/schema#":e.target==="draft-04"?u.$schema="http://json-schema.org/draft-04/schema#":e.target,e.external?.uri){const f=e.external.registry.get(n)?.id;if(!f)throw new Error("Schema is missing an `id` property");u.$id=e.external.uri(f)}Object.assign(u,i.def??i.schema);const h=e.external?.defs??{};for(const f of e.seen.entries()){const b=f[1];b.def&&b.defId&&(h[b.defId]=b.def)}e.external||Object.keys(h).length>0&&(e.target==="draft-2020-12"?u.$defs=h:u.definitions=h);try{const f=JSON.parse(JSON.stringify(u));return Object.defineProperty(f,"~standard",{value:{...n["~standard"],jsonSchema:{input:Id(n,"input",e.processors),output:Id(n,"output",e.processors)}},enumerable:!1,writable:!1}),f}catch{throw new Error("Error converting schema to JSON.")}}function Vn(e,n){const i=n??{seen:new Set};if(i.seen.has(e))return!1;i.seen.add(e);const r=e._zod.def;if(r.type==="transform")return!0;if(r.type==="array")return Vn(r.element,i);if(r.type==="set")return Vn(r.valueType,i);if(r.type==="lazy")return Vn(r.getter(),i);if(r.type==="promise"||r.type==="optional"||r.type==="nonoptional"||r.type==="nullable"||r.type==="readonly"||r.type==="default"||r.type==="prefault")return Vn(r.innerType,i);if(r.type==="intersection")return Vn(r.left,i)||Vn(r.right,i);if(r.type==="record"||r.type==="map")return Vn(r.keyType,i)||Vn(r.valueType,i);if(r.type==="pipe")return Vn(r.in,i)||Vn(r.out,i);if(r.type==="object"){for(const u in r.shape)if(Vn(r.shape[u],i))return!0;return!1}if(r.type==="union"){for(const u of r.options)if(Vn(u,i))return!0;return!1}if(r.type==="tuple"){for(const u of r.items)if(Vn(u,i))return!0;return!!(r.rest&&Vn(r.rest,i))}return!1}const AR=(e,n={})=>i=>{const r=Hk({...i,processors:n});return an(e,r),Qk(r,e),Fk(r,e)},Id=(e,n,i={})=>r=>{const{libraryOptions:u,target:h}=r??{},f=Hk({...u??{},target:h,io:n,processors:i});return an(e,f),Qk(f,e),Fk(f,e)},CR={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},NR=(e,n,i,r)=>{const u=i;u.type="string";const{minimum:h,maximum:f,format:b,patterns:v,contentEncoding:x}=e._zod.bag;if(typeof h=="number"&&(u.minLength=h),typeof f=="number"&&(u.maxLength=f),b&&(u.format=CR[b]??b,u.format===""&&delete u.format,b==="time"&&delete u.format),x&&(u.contentEncoding=x),v&&v.size>0){const S=[...v];S.length===1?u.pattern=S[0].source:S.length>1&&(u.allOf=[...S.map(k=>({...n.target==="draft-07"||n.target==="draft-04"||n.target==="openapi-3.0"?{type:"string"}:{},pattern:k.source}))])}},_R=(e,n,i,r)=>{const u=i,{minimum:h,maximum:f,format:b,multipleOf:v,exclusiveMaximum:x,exclusiveMinimum:S}=e._zod.bag;typeof b=="string"&&b.includes("int")?u.type="integer":u.type="number",typeof S=="number"&&(n.target==="draft-04"||n.target==="openapi-3.0"?(u.minimum=S,u.exclusiveMinimum=!0):u.exclusiveMinimum=S),typeof h=="number"&&(u.minimum=h,typeof S=="number"&&n.target!=="draft-04"&&(S>=h?delete u.minimum:delete u.exclusiveMinimum)),typeof x=="number"&&(n.target==="draft-04"||n.target==="openapi-3.0"?(u.maximum=x,u.exclusiveMaximum=!0):u.exclusiveMaximum=x),typeof f=="number"&&(u.maximum=f,typeof x=="number"&&n.target!=="draft-04"&&(x<=f?delete u.maximum:delete u.exclusiveMaximum)),typeof v=="number"&&(u.multipleOf=v)},TR=(e,n,i,r)=>{i.type="boolean"},ER=(e,n,i,r)=>{n.target==="openapi-3.0"?(i.type="string",i.nullable=!0,i.enum=[null]):i.type="null"},RR=(e,n,i,r)=>{i.not={}},DR=(e,n,i,r)=>{},zR=(e,n,i,r)=>{const u=e._zod.def,h=jk(u.entries);h.every(f=>typeof f=="number")&&(i.type="number"),h.every(f=>typeof f=="string")&&(i.type="string"),i.enum=h},IR=(e,n,i,r)=>{const u=e._zod.def,h=[];for(const f of u.values)if(f===void 0){if(n.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof f=="bigint"){if(n.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");h.push(Number(f))}else h.push(f);if(h.length!==0)if(h.length===1){const f=h[0];i.type=f===null?"null":typeof f,n.target==="draft-04"||n.target==="openapi-3.0"?i.enum=[f]:i.const=f}else h.every(f=>typeof f=="number")&&(i.type="number"),h.every(f=>typeof f=="string")&&(i.type="string"),h.every(f=>typeof f=="boolean")&&(i.type="boolean"),h.every(f=>f===null)&&(i.type="null"),i.enum=h},OR=(e,n,i,r)=>{if(n.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema")},qR=(e,n,i,r)=>{if(n.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema")},PR=(e,n,i,r)=>{const u=i,h=e._zod.def,{minimum:f,maximum:b}=e._zod.bag;typeof f=="number"&&(u.minItems=f),typeof b=="number"&&(u.maxItems=b),u.type="array",u.items=an(h.element,n,{...r,path:[...r.path,"items"]})},MR=(e,n,i,r)=>{const u=i,h=e._zod.def;u.type="object",u.properties={};const f=h.shape;for(const x in f)u.properties[x]=an(f[x],n,{...r,path:[...r.path,"properties",x]});const b=new Set(Object.keys(f)),v=new Set([...b].filter(x=>{const S=h.shape[x]._zod;return n.io==="input"?S.optin===void 0:S.optout===void 0}));v.size>0&&(u.required=Array.from(v)),h.catchall?._zod.def.type==="never"?u.additionalProperties=!1:h.catchall?h.catchall&&(u.additionalProperties=an(h.catchall,n,{...r,path:[...r.path,"additionalProperties"]})):n.io==="output"&&(u.additionalProperties=!1)},BR=(e,n,i,r)=>{const u=e._zod.def,h=u.inclusive===!1,f=u.options.map((b,v)=>an(b,n,{...r,path:[...r.path,h?"oneOf":"anyOf",v]}));h?i.oneOf=f:i.anyOf=f},LR=(e,n,i,r)=>{const u=e._zod.def,h=an(u.left,n,{...r,path:[...r.path,"allOf",0]}),f=an(u.right,n,{...r,path:[...r.path,"allOf",1]}),b=x=>"allOf"in x&&Object.keys(x).length===1,v=[...b(h)?h.allOf:[h],...b(f)?f.allOf:[f]];i.allOf=v},$R=(e,n,i,r)=>{const u=i,h=e._zod.def;u.type="object";const f=h.keyType,v=f._zod.bag?.patterns;if(h.mode==="loose"&&v&&v.size>0){const S=an(h.valueType,n,{...r,path:[...r.path,"patternProperties","*"]});u.patternProperties={};for(const k of v)u.patternProperties[k.source]=S}else(n.target==="draft-07"||n.target==="draft-2020-12")&&(u.propertyNames=an(h.keyType,n,{...r,path:[...r.path,"propertyNames"]})),u.additionalProperties=an(h.valueType,n,{...r,path:[...r.path,"additionalProperties"]});const x=f._zod.values;if(x){const S=[...x].filter(k=>typeof k=="string"||typeof k=="number");S.length>0&&(u.required=S)}},VR=(e,n,i,r)=>{const u=e._zod.def,h=an(u.innerType,n,r),f=n.seen.get(e);n.target==="openapi-3.0"?(f.ref=u.innerType,i.nullable=!0):i.anyOf=[h,{type:"null"}]},UR=(e,n,i,r)=>{const u=e._zod.def;an(u.innerType,n,r);const h=n.seen.get(e);h.ref=u.innerType},GR=(e,n,i,r)=>{const u=e._zod.def;an(u.innerType,n,r);const h=n.seen.get(e);h.ref=u.innerType,i.default=JSON.parse(JSON.stringify(u.defaultValue))},KR=(e,n,i,r)=>{const u=e._zod.def;an(u.innerType,n,r);const h=n.seen.get(e);h.ref=u.innerType,n.io==="input"&&(i._prefault=JSON.parse(JSON.stringify(u.defaultValue)))},HR=(e,n,i,r)=>{const u=e._zod.def;an(u.innerType,n,r);const h=n.seen.get(e);h.ref=u.innerType;let f;try{f=u.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}i.default=f},QR=(e,n,i,r)=>{const u=e._zod.def,h=n.io==="input"?u.in._zod.def.type==="transform"?u.out:u.in:u.out;an(h,n,r);const f=n.seen.get(e);f.ref=h},FR=(e,n,i,r)=>{const u=e._zod.def;an(u.innerType,n,r);const h=n.seen.get(e);h.ref=u.innerType,i.readOnly=!0},Zk=(e,n,i,r)=>{const u=e._zod.def;an(u.innerType,n,r);const h=n.seen.get(e);h.ref=u.innerType},ZR=(e,n,i,r)=>{const u=e._zod.innerType;an(u,n,r);const h=n.seen.get(e);h.ref=u},YR=ne("ZodISODateTime",(e,n)=>{H7.init(e,n),Yt.init(e,n)});function Yk(e){return WE(YR,e)}const XR=ne("ZodISODate",(e,n)=>{Q7.init(e,n),Yt.init(e,n)});function Xk(e){return eR(XR,e)}const JR=ne("ZodISOTime",(e,n)=>{F7.init(e,n),Yt.init(e,n)});function WR(e){return tR(JR,e)}const eD=ne("ZodISODuration",(e,n)=>{Z7.init(e,n),Yt.init(e,n)});function tD(e){return nR(eD,e)}const nD=(e,n)=>{_k.init(e,n),e.name="ZodError",Object.defineProperties(e,{format:{value:i=>M8(e,i)},flatten:{value:i=>P8(e,i)},addIssue:{value:i=>{e.issues.push(i),e.message=JSON.stringify(e.issues,qf,2)}},addIssues:{value:i=>{e.issues.push(...i),e.message=JSON.stringify(e.issues,qf,2)}},isEmpty:{get(){return e.issues.length===0}}})},Oa=ne("ZodError",nD,{Parent:Error}),aD=Ig(Oa),iD=Og(Oa),sD=rm(Oa),oD=lm(Oa),rD=$8(Oa),lD=V8(Oa),cD=U8(Oa),uD=G8(Oa),dD=K8(Oa),mD=H8(Oa),pD=Q8(Oa),hD=F8(Oa),Lt=ne("ZodType",(e,n)=>(Bt.init(e,n),Object.assign(e["~standard"],{jsonSchema:{input:Id(e,"input"),output:Id(e,"output")}}),e.toJSONSchema=AR(e,{}),e.def=n,e.type=n.type,Object.defineProperty(e,"_def",{value:n}),e.check=(...i)=>e.clone(Rs(n,{checks:[...n.checks??[],...i.map(r=>typeof r=="function"?{_zod:{check:r,def:{check:"custom"},onattach:[]}}:r)]}),{parent:!0}),e.with=e.check,e.clone=(i,r)=>Ds(e,i,r),e.brand=()=>e,e.register=((i,r)=>(i.add(e,r),e)),e.parse=(i,r)=>aD(e,i,r,{callee:e.parse}),e.safeParse=(i,r)=>sD(e,i,r),e.parseAsync=async(i,r)=>iD(e,i,r,{callee:e.parseAsync}),e.safeParseAsync=async(i,r)=>oD(e,i,r),e.spa=e.safeParseAsync,e.encode=(i,r)=>rD(e,i,r),e.decode=(i,r)=>lD(e,i,r),e.encodeAsync=async(i,r)=>cD(e,i,r),e.decodeAsync=async(i,r)=>uD(e,i,r),e.safeEncode=(i,r)=>dD(e,i,r),e.safeDecode=(i,r)=>mD(e,i,r),e.safeEncodeAsync=async(i,r)=>pD(e,i,r),e.safeDecodeAsync=async(i,r)=>hD(e,i,r),e.refine=(i,r)=>e.check(uz(i,r)),e.superRefine=i=>e.check(dz(i)),e.overwrite=i=>e.check(Qr(i)),e.optional=()=>Nx(e),e.exactOptional=()=>ZD(e),e.nullable=()=>_x(e),e.nullish=()=>Nx(_x(e)),e.nonoptional=i=>tz(e,i),e.array=()=>y(e),e.or=i=>Ze([e,i]),e.and=i=>GD(e,i),e.transform=i=>Bf(e,t2(i)),e.default=i=>JD(e,i),e.prefault=i=>ez(e,i),e.catch=i=>az(e,i),e.pipe=i=>Bf(e,i),e.readonly=()=>oz(e),e.describe=i=>{const r=e.clone();return dc.add(r,{description:i}),r},Object.defineProperty(e,"description",{get(){return dc.get(e)?.description},configurable:!0}),e.meta=(...i)=>{if(i.length===0)return dc.get(e);const r=e.clone();return dc.add(r,i[0]),r},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e.apply=i=>i(e),e)),Jk=ne("_ZodString",(e,n)=>{qg.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(r,u,h)=>NR(e,r,u);const i=e._zod.bag;e.format=i.format??null,e.minLength=i.minimum??null,e.maxLength=i.maximum??null,e.regex=(...r)=>e.check(uR(...r)),e.includes=(...r)=>e.check(pR(...r)),e.startsWith=(...r)=>e.check(hR(...r)),e.endsWith=(...r)=>e.check(fR(...r)),e.min=(...r)=>e.check(zd(...r)),e.max=(...r)=>e.check(Gk(...r)),e.length=(...r)=>e.check(Kk(...r)),e.nonempty=(...r)=>e.check(zd(1,...r)),e.lowercase=r=>e.check(dR(r)),e.uppercase=r=>e.check(mR(r)),e.trim=()=>e.check(yR()),e.normalize=(...r)=>e.check(gR(...r)),e.toLowerCase=()=>e.check(bR()),e.toUpperCase=()=>e.check(vR()),e.slugify=()=>e.check(xR())}),fD=ne("ZodString",(e,n)=>{qg.init(e,n),Jk.init(e,n),e.email=i=>e.check(zE(gD,i)),e.url=i=>e.check(PE(bD,i)),e.jwt=i=>e.check(JE(zD,i)),e.emoji=i=>e.check(ME(vD,i)),e.guid=i=>e.check(wx(Ax,i)),e.uuid=i=>e.check(Uk(mc,i)),e.uuidv4=i=>e.check(IE(mc,i)),e.uuidv6=i=>e.check(OE(mc,i)),e.uuidv7=i=>e.check(qE(mc,i)),e.nanoid=i=>e.check(BE(xD,i)),e.guid=i=>e.check(wx(Ax,i)),e.cuid=i=>e.check(LE(wD,i)),e.cuid2=i=>e.check($E(SD,i)),e.ulid=i=>e.check(VE(kD,i)),e.base64=i=>e.check(ZE(ED,i)),e.base64url=i=>e.check(YE(RD,i)),e.xid=i=>e.check(UE(jD,i)),e.ksuid=i=>e.check(GE(AD,i)),e.ipv4=i=>e.check(KE(CD,i)),e.ipv6=i=>e.check(HE(ND,i)),e.cidrv4=i=>e.check(QE(_D,i)),e.cidrv6=i=>e.check(FE(TD,i)),e.e164=i=>e.check(XE(DD,i)),e.datetime=i=>e.check(Yk(i)),e.date=i=>e.check(Xk(i)),e.time=i=>e.check(WR(i)),e.duration=i=>e.check(tD(i))});function o(e){return DE(fD,e)}const Yt=ne("ZodStringFormat",(e,n)=>{Gt.init(e,n),Jk.init(e,n)}),gD=ne("ZodEmail",(e,n)=>{P7.init(e,n),Yt.init(e,n)}),Ax=ne("ZodGUID",(e,n)=>{O7.init(e,n),Yt.init(e,n)}),mc=ne("ZodUUID",(e,n)=>{q7.init(e,n),Yt.init(e,n)});function yD(e){return Uk(mc,e)}const bD=ne("ZodURL",(e,n)=>{M7.init(e,n),Yt.init(e,n)}),vD=ne("ZodEmoji",(e,n)=>{B7.init(e,n),Yt.init(e,n)}),xD=ne("ZodNanoID",(e,n)=>{L7.init(e,n),Yt.init(e,n)}),wD=ne("ZodCUID",(e,n)=>{$7.init(e,n),Yt.init(e,n)}),SD=ne("ZodCUID2",(e,n)=>{V7.init(e,n),Yt.init(e,n)}),kD=ne("ZodULID",(e,n)=>{U7.init(e,n),Yt.init(e,n)}),jD=ne("ZodXID",(e,n)=>{G7.init(e,n),Yt.init(e,n)}),AD=ne("ZodKSUID",(e,n)=>{K7.init(e,n),Yt.init(e,n)}),CD=ne("ZodIPv4",(e,n)=>{Y7.init(e,n),Yt.init(e,n)}),ND=ne("ZodIPv6",(e,n)=>{X7.init(e,n),Yt.init(e,n)}),_D=ne("ZodCIDRv4",(e,n)=>{J7.init(e,n),Yt.init(e,n)}),TD=ne("ZodCIDRv6",(e,n)=>{W7.init(e,n),Yt.init(e,n)}),ED=ne("ZodBase64",(e,n)=>{eE.init(e,n),Yt.init(e,n)}),RD=ne("ZodBase64URL",(e,n)=>{nE.init(e,n),Yt.init(e,n)}),DD=ne("ZodE164",(e,n)=>{aE.init(e,n),Yt.init(e,n)}),zD=ne("ZodJWT",(e,n)=>{sE.init(e,n),Yt.init(e,n)}),Pg=ne("ZodNumber",(e,n)=>{Mk.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(r,u,h)=>_R(e,r,u),e.gt=(r,u)=>e.check(kx(r,u)),e.gte=(r,u)=>e.check(Xh(r,u)),e.min=(r,u)=>e.check(Xh(r,u)),e.lt=(r,u)=>e.check(Sx(r,u)),e.lte=(r,u)=>e.check(Yh(r,u)),e.max=(r,u)=>e.check(Yh(r,u)),e.int=r=>e.check(Cx(r)),e.safe=r=>e.check(Cx(r)),e.positive=r=>e.check(kx(0,r)),e.nonnegative=r=>e.check(Xh(0,r)),e.negative=r=>e.check(Sx(0,r)),e.nonpositive=r=>e.check(Yh(0,r)),e.multipleOf=(r,u)=>e.check(jx(r,u)),e.step=(r,u)=>e.check(jx(r,u)),e.finite=()=>e;const i=e._zod.bag;e.minValue=Math.max(i.minimum??Number.NEGATIVE_INFINITY,i.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(i.maximum??Number.POSITIVE_INFINITY,i.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(i.format??"").includes("int")||Number.isSafeInteger(i.multipleOf??.5),e.isFinite=!0,e.format=i.format??null});function m(e){return aR(Pg,e)}const ID=ne("ZodNumberFormat",(e,n)=>{oE.init(e,n),Pg.init(e,n)});function Cx(e){return sR(ID,e)}const OD=ne("ZodBoolean",(e,n)=>{rE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>TR(e,i,r)});function _(e){return oR(OD,e)}const qD=ne("ZodNull",(e,n)=>{lE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>ER(e,i,r)});function de(e){return rR(qD,e)}const PD=ne("ZodUnknown",(e,n)=>{cE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>DR()});function jn(){return lR(PD)}const MD=ne("ZodNever",(e,n)=>{uE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>RR(e,i,r)});function BD(e){return cR(MD,e)}const LD=ne("ZodArray",(e,n)=>{dE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>PR(e,i,r,u),e.element=n.element,e.min=(i,r)=>e.check(zd(i,r)),e.nonempty=i=>e.check(zd(1,i)),e.max=(i,r)=>e.check(Gk(i,r)),e.length=(i,r)=>e.check(Kk(i,r)),e.unwrap=()=>e.element});function y(e,n){return wR(LD,e,n)}const Wk=ne("ZodObject",(e,n)=>{pE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>MR(e,i,r,u),gt(e,"shape",()=>n.shape),e.keyof=()=>j(Object.keys(e._zod.def.shape)),e.catchall=i=>e.clone({...e._zod.def,catchall:i}),e.passthrough=()=>e.clone({...e._zod.def,catchall:jn()}),e.loose=()=>e.clone({...e._zod.def,catchall:jn()}),e.strict=()=>e.clone({...e._zod.def,catchall:BD()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=i=>D8(e,i),e.safeExtend=i=>z8(e,i),e.merge=i=>I8(e,i),e.pick=i=>E8(e,i),e.omit=i=>R8(e,i),e.partial=(...i)=>O8(n2,e,i[0]),e.required=(...i)=>q8(a2,e,i[0])});function d(e,n){const i={type:"object",shape:e??{},...De(n)};return new Wk(i)}function $D(e,n){return new Wk({type:"object",shape:e,catchall:jn(),...De(n)})}const e2=ne("ZodUnion",(e,n)=>{$k.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>BR(e,i,r,u),e.options=n.options});function Ze(e,n){return new e2({type:"union",options:e,...De(n)})}const VD=ne("ZodDiscriminatedUnion",(e,n)=>{e2.init(e,n),hE.init(e,n)});function Le(e,n,i){return new VD({type:"union",options:n,discriminator:e,...De(i)})}const UD=ne("ZodIntersection",(e,n)=>{fE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>LR(e,i,r,u)});function GD(e,n){return new UD({type:"intersection",left:e,right:n})}const KD=ne("ZodRecord",(e,n)=>{gE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>$R(e,i,r,u),e.keyType=n.keyType,e.valueType=n.valueType});function Qe(e,n,i){return new KD({type:"record",keyType:e,valueType:n,...De(i)})}const Mf=ne("ZodEnum",(e,n)=>{yE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(r,u,h)=>zR(e,r,u),e.enum=n.entries,e.options=Object.values(n.entries);const i=new Set(Object.keys(n.entries));e.extract=(r,u)=>{const h={};for(const f of r)if(i.has(f))h[f]=n.entries[f];else throw new Error(`Key ${f} not found in enum`);return new Mf({...n,checks:[],...De(u),entries:h})},e.exclude=(r,u)=>{const h={...n.entries};for(const f of r)if(i.has(f))delete h[f];else throw new Error(`Key ${f} not found in enum`);return new Mf({...n,checks:[],...De(u),entries:h})}});function j(e,n){const i=Array.isArray(e)?Object.fromEntries(e.map(r=>[r,r])):e;return new Mf({type:"enum",entries:i,...De(n)})}const HD=ne("ZodLiteral",(e,n)=>{bE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>IR(e,i,r),e.values=new Set(n.values),Object.defineProperty(e,"value",{get(){if(n.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return n.values[0]}})});function R(e,n){return new HD({type:"literal",values:Array.isArray(e)?e:[e],...De(n)})}const QD=ne("ZodTransform",(e,n)=>{vE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>qR(e,i),e._zod.parse=(i,r)=>{if(r.direction==="backward")throw new Sk(e.constructor.name);i.addIssue=h=>{if(typeof h=="string")i.issues.push(kc(h,i.value,n));else{const f=h;f.fatal&&(f.continue=!1),f.code??(f.code="custom"),f.input??(f.input=i.value),f.inst??(f.inst=e),i.issues.push(kc(f))}};const u=n.transform(i.value,i);return u instanceof Promise?u.then(h=>(i.value=h,i)):(i.value=u,i)}});function t2(e){return new QD({type:"transform",transform:e})}const n2=ne("ZodOptional",(e,n)=>{Vk.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>Zk(e,i,r,u),e.unwrap=()=>e._zod.def.innerType});function Nx(e){return new n2({type:"optional",innerType:e})}const FD=ne("ZodExactOptional",(e,n)=>{xE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>Zk(e,i,r,u),e.unwrap=()=>e._zod.def.innerType});function ZD(e){return new FD({type:"optional",innerType:e})}const YD=ne("ZodNullable",(e,n)=>{wE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>VR(e,i,r,u),e.unwrap=()=>e._zod.def.innerType});function _x(e){return new YD({type:"nullable",innerType:e})}const XD=ne("ZodDefault",(e,n)=>{SE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>GR(e,i,r,u),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function JD(e,n){return new XD({type:"default",innerType:e,get defaultValue(){return typeof n=="function"?n():Ck(n)}})}const WD=ne("ZodPrefault",(e,n)=>{kE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>KR(e,i,r,u),e.unwrap=()=>e._zod.def.innerType});function ez(e,n){return new WD({type:"prefault",innerType:e,get defaultValue(){return typeof n=="function"?n():Ck(n)}})}const a2=ne("ZodNonOptional",(e,n)=>{jE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>UR(e,i,r,u),e.unwrap=()=>e._zod.def.innerType});function tz(e,n){return new a2({type:"nonoptional",innerType:e,...De(n)})}const nz=ne("ZodCatch",(e,n)=>{AE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>HR(e,i,r,u),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function az(e,n){return new nz({type:"catch",innerType:e,catchValue:typeof n=="function"?n:()=>n})}const iz=ne("ZodPipe",(e,n)=>{CE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>QR(e,i,r,u),e.in=n.in,e.out=n.out});function Bf(e,n){return new iz({type:"pipe",in:e,out:n})}const sz=ne("ZodReadonly",(e,n)=>{NE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>FR(e,i,r,u),e.unwrap=()=>e._zod.def.innerType});function oz(e){return new sz({type:"readonly",innerType:e})}const rz=ne("ZodLazy",(e,n)=>{_E.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>ZR(e,i,r,u),e.unwrap=()=>e._zod.def.getter()});function lz(e){return new rz({type:"lazy",getter:e})}const cz=ne("ZodCustom",(e,n)=>{TE.init(e,n),Lt.init(e,n),e._zod.processJSONSchema=(i,r,u)=>OR(e,i)});function uz(e,n={}){return SR(cz,e,n)}function dz(e){return kR(e)}function zs(e,n){return Bf(t2(e),n)}const ye={custom:"custom"};function Bi(e){return iR(Pg,e)}const i2=d({id:o(),name:o(),keyPrefix:o(),scopes:y(o()),projectId:o().nullable(),projectName:o().nullable(),readOnly:_(),operator:_().optional(),createdAt:o(),lastUsedAt:o().nullable(),revokedAt:o().nullable()});d({keys:y(i2)});d({name:o().min(1).max(100),scopes:y(o()).min(1).optional(),projectId:o().optional()});i2.extend({key:o()});const Mg=j(["used","not-used","unknown","not-applicable"]);Mg.enum;const Bg=j(["native-auto-v1","search-required-v1"]);Bg.enum;const mz=d({maxConcurrency:m().int().positive(),maxRequestsPerMinute:m().int().positive(),maxRequestsPerDay:m().int().positive()}),kt=o().min(1),Lg=Qe(o(),o().trim().min(1));o().min(1);const dn=d({label:o().min(1),city:o().min(1),region:o().min(1),country:o().length(2),timezone:o().optional()}),$g=j(["answer-visibility","traffic-sync","gbp-sync","data-refresh","backlinks-sync","site-audit","ads-sync","doctor"]);$g.enum;const Vg=d({everyDays:m().int().min(1).max(3650),startDate:o().date(),time:o().regex(/^([01]\d|2[0-3]):[0-5]\d$/,"Time must be HH:mm")}).strict();d({id:o(),projectId:o(),kind:$g,cronExpr:o(),recurrence:Vg.nullable().optional(),preset:o().nullable().optional(),timezone:o().default("UTC"),enabled:_().default(!0),providers:y(kt).default([]),sourceId:o().nullable().optional(),lastRunAt:o().nullable().optional(),nextRunAt:o().nullable().optional(),createdAt:o(),updatedAt:o()});const pz=o().datetime();d({kind:$g.optional(),preset:o().min(1).optional(),cron:o().min(1).optional(),recurrence:Vg.optional(),timezone:o().optional().default("UTC"),enabled:_().optional().default(!0),providers:y(kt).optional().default([]),sourceId:o().optional(),expectedUpdatedAt:pz.nullable().optional()}).refine(e=>[e.preset,e.cron,e.recurrence].filter(n=>n!==void 0).length===1,{message:'Exactly one of "preset", "cron", or "recurrence" must be provided'});const Ug=j(["citation.lost","citation.gained","run.completed","run.failed","insight.critical","insight.high","health.degraded","health.recovered","review.negative","review.rating-dropped"]);d({id:o(),projectId:o(),channel:R("webhook"),url:o().url(),urlDisplay:o(),urlHost:o(),events:y(Ug),enabled:_().default(!0),source:o().optional(),webhookSecret:o().optional(),createdAt:o(),updatedAt:o()});d({channel:R("webhook"),url:o().url(),events:y(Ug).min(1),source:o().optional()});class hz extends Error{code;statusCode;details;constructor(n,i,r,u){super(i),this.name="AppError",this.code=n,this.statusCode=r,this.details=u}toJSON(){return{error:{code:this.code,message:this.message,...this.details?{details:this.details}:{}}}}}function Tx(e,n){return new hz("VALIDATION_ERROR",e,400,n)}function Oi(e){if(e instanceof Error)return e.message;if(typeof e=="string")return e;if(e==null)return"unknown error";try{const n=JSON.stringify(e);if(n!==void 0)return n}catch{}try{return String(e)}catch{return"unknown error"}}const fz=j(["fraction","percent"]),xt=fz.enum,gz="x-unit";function s2(e,n){return e.meta({[gz]:n})}function we(e=m()){return s2(e,xt.fraction)}function Oe(e=m()){return s2(e,xt.percent)}const yz={[xt.fraction]:8,[xt.percent]:6};function bz(e,n){const i=10**yz[n];return(Math.round(Number((e*i).toFixed(6)))+0)/i}function Jh(e,n=!1){const i=new Set,r=[];for(const u of e){const h=n?u.toLowerCase():u;i.has(h)||(i.add(h),r.push(u))}return r}function Ex(e){try{const n=e.includes("://"),i=new URL(n?e:`https://${e}`);if(!n&&(i.pathname!=="/"||i.search||i.hash)||i.username||i.password||i.port)return null;const r=i.hostname.trim().toLowerCase().replace(/^www\./,"");return!r||r.includes("/")||r.includes("?")||r.includes("#")?null:r}catch{return null}}const vz=o().trim().min(1).refine(e=>Ex(e)!==null,{message:"Marketing hosts must be valid hostnames without credentials or ports"}).overwrite(e=>Ex(e)??e),xz=o().trim().min(1),wz=o().trim().regex(/^[a-z]\w{0,39}$/i,{message:"GA4 event names must start with a letter and contain only letters, numbers, or underscores"}),Gg=d({marketingHosts:y(vz).overwrite(e=>Jh(e,!0)),brandTerms:y(xz).overwrite(e=>Jh(e,!0)),leadEventNames:y(wz).overwrite(e=>Jh(e))});function Sz(){return{marketingHosts:[],brandTerms:[],leadEventNames:["generate_lead"]}}const Wh=Object.freeze({marketingHosts:Object.freeze([]),brandTerms:Object.freeze([]),leadEventNames:Object.freeze(["generate_lead"])}),o2=()=>Sz(),Rx=j(["never-synced","ready","error"]),kz=j(["landing-page","channel"]),jz=j(["30d","60d","90d"]),Az=j(["marketing","all"]),pc=Xk(),Dc=d({label:j(["earliest","middle","previous","latest"]),startDate:pc,endDate:pc}),ef=Dc.extend({sessions:m().int().nonnegative()}),Dx=Dc.extend({eventCount:m().int().nonnegative()}),zx=Dc.extend({clicks:m().int().nonnegative(),impressions:m().int().nonnegative()}),Cz=Dc.extend({propertyClicks:m().int().nonnegative(),propertyImpressions:m().int().nonnegative(),reportedQueryClicks:m().int().nonnegative(),reportedQueryImpressions:m().int().nonnegative(),brandedClicks:m().int().nonnegative(),brandedImpressions:m().int().nonnegative(),nonBrandedClicks:m().int().nonnegative(),nonBrandedImpressions:m().int().nonnegative(),unreportedClicks:m().int().nonnegative(),unreportedImpressions:m().int().nonnegative()}),Nz=Dc.extend({sessions:m().int().nonnegative(),engagementRate:we(m().min(0).max(1)).nullable(),dailyTotalUsers:m().int().nonnegative().nullable(),dailyNewUsers:m().int().nonnegative().nullable(),metricsAvailable:_(),daysInPeriod:m().int().nonnegative(),daysWithEngagementRate:m().int().nonnegative(),daysWithUserSplit:m().int().nonnegative()}),_z=d({window:jz,bucketDays:R(30),filters:d({hostScope:Az,marketingHosts:y(o()),pathPrefix:o().nullable(),brandTerms:y(o()),queryMixScope:R("property")}),acquisition:d({status:Rx,error:o().nullable(),syncedAt:o().datetime().nullable(),periods:y(ef),channels:y(d({channelGroup:o(),periods:y(ef)})),pages:y(d({hostName:o(),landingPage:o(),periods:y(ef)}))}),leads:d({status:Rx,error:o().nullable(),syncedAt:o().datetime().nullable(),attributionScope:kz.nullable(),hostAndPathFiltersApplied:_(),periods:y(Dx),channels:y(d({channelGroup:o(),periods:y(Dx)}))}),engagement:d({status:j(["ready","unavailable"]),availableFromDate:pc.nullable(),latestDate:pc.nullable(),periods:y(Nz)}),searchDemand:d({status:j(["ready","unavailable"]),periods:y(Cz),queries:y(d({query:o(),classification:j(["branded","non-branded"]),periods:y(zx)})),pages:y(d({hostName:o(),landingPage:o(),periods:y(zx)})),latestDate:pc.nullable()})}),zc=j(["sync","batch"]);zc.enum;const Kg=Qe(o(),zc),r2=j(["submitting","submitted","ended","ingested","cancelled","failed","unknown"]),Ix=r2.enum;Ix.submitted,Ix.ended;const Hg=j(["standard","batch"]),Ox=Hg.enum,Tz=d({inputTokens:m().int().nonnegative(),cachedInputTokens:m().int().nonnegative(),cacheWriteTokens:m().int().nonnegative(),outputTokens:m().int().nonnegative(),searchCount:m().int().nonnegative()}),Ez=Tz.extend({pricingTier:Hg,estimatedCostMicros:m().int().nonnegative().nullable(),priceSource:Ze([j(["default","override"]),de()])}),l2=d({inputPerMTok:m().nonnegative(),cachedInputPerMTok:m().nonnegative().optional(),cacheWritePerMTok:m().nonnegative().optional(),outputPerMTok:m().nonnegative(),searchPer1k:m().nonnegative().optional(),searchUnit:j(["query","prompt"]).optional(),batchTokenDiscount:m().min(0).max(1).optional()}).strict();d({models:Qe(o().min(1),l2).default({})}).strict();d({enabled:_().default(!1),maxRequestsPerBatch:m().int().positive().optional(),deadlineHours:m().positive().optional()}).strict();const Rz=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,Dz=/[\0-\x1F\x7F-\x9F]/,zz=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B4E\u1B4F\u1B5A-\u1B60\u1B7D-\u1B7F\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDD6E\uDEAD\uDED0\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9\uDFD4\uDFD5\uDFD7\uDFD8]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09\uDFE1]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDD6D-\uDD6F\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD839\uDDFF|\uD83A[\uDD5E\uDD5F]/,Iz=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/;var Oz=class{src_Any=Rz.source;src_Cc=Dz.source;src_Z=Iz.source;src_P=zz.source;src_ZPCc=[this.src_Z,this.src_P,this.src_Cc].join("|");src_ZCc=[this.src_Z,this.src_Cc].join("|");cache={};opts={maxLength:1e4,urlAuth:!1,schema_names:[]};constructor(e={}){this.opts={...this.opts,...e}}set(e={}){return this.opts={...this.opts,...e},this.cache={},this}escapeRE(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}nestedPairRE(e,n,i=4){const r=this.escapeRE(e),u=this.escapeRE(n),h=`(?:(?!${this.src_ZCc}|${r}|${u}).)`;let f=`${r}${h}{0,1000}${u}`;for(let b=2;b<=i;b++)f=`${r}(?:${h}|${f}){0,1000}${u}`;return f}get_text_separators(){return this.cache.text_separators??=/[><\uff5c]/}get_pseudo_letter(){return this.cache.src_pseudo_letter??=new RegExp(`(?:(?!${this.get_text_separators().source}|${this.src_ZPCc})${this.src_Any})`)}get_ipv4_addr(){return this.cache.src_ip4??=new RegExp("(?:(?:25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])[.]){3}(?:25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])")}get_ipv6_addr(){const e="[0-9A-Fa-f]{1,4}",n=`(?:(?:${e}:${e})|${this.get_ipv4_addr().source})`;return this.cache.src_ip6_addr??=new RegExp(`(?:(?:${e}:){6}${n}|::(?:${e}:){5}${n}|(?:${e})?::(?:${e}:){4}${n}|(?:(?:${e}:){0,1}${e})?::(?:${e}:){3}${n}|(?:(?:${e}:){0,2}${e})?::(?:${e}:){2}${n}|(?:(?:${e}:){0,3}${e})?::${e}:${n}|(?:(?:${e}:){0,4}${e})?::${n}|(?:(?:${e}:){0,5}${e})?::${e}|(?:(?:${e}:){0,6}${e})?::)`)}get_ipv6_url_host(){return this.cache.src_ip6_host??=new RegExp(`\\[${this.get_ipv6_addr().source}\\]`)}get_ipv6_mail_host(){return this.cache.src_ipv6_mail_host??=new RegExp(`\\[IPv6:${this.get_ipv6_addr().source}\\]`)}get_auth(){return this.cache.src_auth??=new RegExp(`(?:(?:(?!${this.src_ZCc}|[@/\\[\\]()]).){1,50}@)?`)}get_port(){return this.cache.src_port??=new RegExp("(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?")}get_host_terminator(){return this.cache.src_host_terminator??=new RegExp(`(?=$|${this.get_text_separators().source}|${this.src_ZPCc})(?!${this.opts["---"]?"-(?!--)|":"-|"}_|:\\d|\\.-|\\.(?!$|${this.src_ZPCc}))`)}get_path_terminator(){return this.cache.src_path_terminator??=new RegExp(`${this.src_ZPCc}|${this.get_text_separators().source}`)}get_path(){return this.cache.src_path??=new RegExp(`(?:[/?#](?:${this.nestedPairRE("[","]")}|${this.nestedPairRE("(",")")}|${this.nestedPairRE("{","}")}|\\"(?:(?!${this.src_ZCc}|["]).){1,100}\\"|\\'(?:(?!${this.src_ZCc}|[']).){1,100}\\'|\\'(?=${this.get_pseudo_letter().source}|[-])|\\.{2,20}[:]?[a-zA-Z0-9%/&]|\\.(?!${this.src_ZCc}|[.]|$)|`+(this.opts["---"]?"\\-(?!--(?:[^-]|$))(?:-{0,19})|":"\\-{1,20}|")+`,(?!${this.src_ZCc}|$)|;(?!${this.src_ZCc}|$)|\\!{1,20}(?!${this.src_ZCc}|[!]|$)|\\?(?!${this.src_ZCc}|[?]|$)|`+this.get_path_extra().source+`[\\\\/:%@#&=_~*]|(?!${this.get_path_terminator().source}).){1,${this.opts.maxLength}}|\\/)?`)}get_mail_name(){return this.cache.src_mail_name??=new RegExp("[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9](?:[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9]|[.](?=[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9])){0,63}")}get_xn(){return this.cache.src_xn??=new RegExp("xn--[a-z0-9\\-]{1,59}")}get_tld(){if(this.cache.tld)return this.cache.tld;const e=[...new Set(this.opts.tlds||[])].sort().reverse().join("|");return this.cache.tld=new RegExp(`${e||"$#none#$"}|${this.get_xn().source}`),this.cache.tld}get_domain_root(){return this.cache.src_domain_root??=new RegExp("(?:"+this.get_xn().source+`|${this.get_pseudo_letter().source}{1,63})`)}get_domain(){return this.cache.src_domain??=new RegExp("(?:"+this.get_xn().source+`|(?:${this.get_pseudo_letter().source})|(?:${this.get_pseudo_letter().source}(?:-|${this.get_pseudo_letter().source}){0,61}${this.get_pseudo_letter().source}))`)}get_url_host_port(){return this.cache.url_host_port??=new RegExp("(?:"+this.get_ipv6_url_host().source+`|(?:(?:(?:${this.get_domain().source})\\.){0,10}${this.get_domain().source}))`+this.get_port().source+this.get_host_terminator().source)}get_fuzzy_url_host_port(){return this.cache.fuzzy_url_host_port??=new RegExp("(?:"+(this.opts.fuzzyIP?this.get_ipv4_addr().source+"|":"")+`(?:(?:(?:${this.get_domain().source})\\.){1,10}(?:${this.get_tld().source})))`+this.get_host_terminator().source)}get_mail_host(){return this.cache.src_mail_host??=new RegExp("(?:"+this.get_ipv6_mail_host().source+`|(?:(?:(?:${this.get_domain().source})\\.){0,4}${this.get_domain().source}))`+this.get_host_terminator().source)}get_fuzzy_mail_host(){return this.cache.src_fuzzy_mail_host??=new RegExp("(?:"+this.get_ipv6_mail_host().source+`|(?:(?:(?:${this.get_domain().source})[.]){1,4}${this.get_domain_root().source}))`+this.get_host_terminator().source)}get_path_extra(){return this.cache.src_path_extra??=new RegExp("")}get_fuzzy_mail_host_search(){return this.cache.mail_fuzzy_host_search??=new RegExp(`@${this.get_fuzzy_mail_host().source}`,"ig")}get_fuzzy_link_search(){return this.cache.link_fuzzy_search??=new RegExp(`(^|(?![.:/\\-_@])(?:[$+<=>^\`||]|${this.src_ZPCc}))(?:(?![$+<=>^\`||])${this.get_fuzzy_url_host_port().source}${this.get_path().source})`,"ig")}get_http_validator(){return this.cache.http_validator??=new RegExp("\\/\\/"+(this.opts.urlAuth?this.get_auth().source:"")+this.get_url_host_port().source+this.get_path().source,"iy")}get_relative_proto_validator(){return this.cache.relative_proto_validator??=new RegExp((this.opts.urlAuth?this.get_auth().source:"")+`(?:localhost|${this.get_ipv6_url_host().source}|(?:(?:${this.get_domain().source})[.]){1,10}${this.get_domain_root().source})`+this.get_port().source+this.get_host_terminator().source+this.get_path().source,"iy")}get_mail_name_validator(){return this.cache.mail_name_validator??=new RegExp(`(?:^|${this.get_text_separators().source}|"|\\(|${this.src_ZCc})(${this.get_mail_name().source})$`)}get_mailto_validator(){return this.cache.mailto_validator??=new RegExp(`${this.get_mail_name().source}@${this.get_mail_host().source}`,"iy")}get_schema_names(){return this.cache.schema_names??=new RegExp((this.opts.schema_names||[]).map(e=>this.escapeRE(e)).join("|"))}get_schema_search(){return this.cache.schema_search??=new RegExp(`(^|(?!_)(?:[><|]|${this.src_ZPCc}))(${this.get_schema_names().source})`,"ig")}get_schema_at_start(){return this.cache.schema_at_start??=new RegExp(`^${this.get_schema_search().source}`,"i")}},tf={validate:(e,n,i)=>{const r=i.re.get_http_validator();r.lastIndex=n;const u=r.exec(e);return u?u[0].length:0},normalize:(e,n)=>n.normalize(e)},qz={"http:":tf,"https:":tf,"ftp:":tf,"//":{validate:function(e,n,i){const r=i.re.get_relative_proto_validator();r.lastIndex=n;const u=r.exec(e);return u?n>=3&&e[n-3]===":"||n>=3&&e[n-3]==="/"?0:u[0].length:0},normalize:(e,n)=>n.normalize(e)},"mailto:":{validate:function(e,n,i){const r=i.re.get_mailto_validator();r.lastIndex=n;const u=r.exec(e);return u?u[0].length:0},normalize:(e,n)=>n.normalize(e)}},Pz="a:cdefgilmnoqrstuwxz|b:abdefghijmnorstvwyz|c:acdfghiklmnoruvwxyz|d:ejkmoz|e:cegrstu|f:ijkmor|g:abdefghilmnpqrstuwy|h:kmnrtu|i:delmnoqrst|j:emop|k:eghimnprwyz|l:abcikrstuvy|m:acdeghklmnopqrstuvwxyz|n:acefgilopruz|o:m|p:aefghklmnrstwy|q:a|r:eosuw|s:abcdeghijklmnortuvxyz|t:cdfghjklmnortvwz|u:agksyz|v:aceginu|w:fs|y:et|z:amw",Mz="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф";function Bz(){const e=Mz.split("|");return Pz.split("|").forEach(n=>{const i=n.indexOf(":"),r=n.slice(0,i);for(const u of n.slice(i+1))e.push(r+u)}),e}var Lz={fuzzyLink:!1,fuzzyEmail:!0,fuzzyIP:!1,"---":!1,tlds:Bz(),urlAuth:!1,maxLength:1e4},qx=class{schema;index;lastIndex;raw;text;url;constructor(e,n,i,r){const u=e.slice(i,r);this.schema=n.toLowerCase(),this.index=i,this.lastIndex=r,this.raw=u,this.text=u,this.url=u}},$z=class{__opts__;__schemas__;re;constructor(e={}){const{rebuilder:n,...i}=e;this.__opts__={...Lz,...i},this.__schemas__={...qz},this.re=n||new Oz,this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)})}add(e,n=null){if(!n)delete this.__schemas__[e];else{const i={normalize:(r,u)=>u.normalize(r),...n};this.__schemas__[e]=i}return this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}set(e={}){return this.__opts__={...this.__opts__,...e},this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}test(e){if(!e.length)return!1;let n,i;for(i=this.re.get_schema_search(),i.lastIndex=0;(n=i.exec(e))!==null;)if(this.testSchemaAt(e,n[2],i.lastIndex))return!0;if(this.__opts__.fuzzyLink&&this.__schemas__["http:"]&&(i=this.re.get_fuzzy_link_search(),i.lastIndex=0,i.exec(e)!==null))return!0;if(this.__opts__.fuzzyEmail&&this.__schemas__["mailto:"]&&e.indexOf("@")>=0){const r=this.re.get_fuzzy_mail_host_search(),u=this.re.get_mail_name_validator();for(r.lastIndex=0;(n=r.exec(e))!==null;){const h=e.slice(Math.max(0,n.index-65),n.index);if(u.test(h))return!0}}return!1}testSchemaAt(e,n,i){return this.__schemas__[n.toLowerCase()]?this.__schemas__[n.toLowerCase()].validate(e.slice(0,i+this.__opts__.maxLength),i,this):0}match(e){const n=[],i=this.re.get_schema_search();let r,u,h,f,b,v,x=!1,S=!1,k=!1,T=0;if(!e.length)return null;for(i.lastIndex=0,this.__opts__.fuzzyLink&&this.__schemas__["http:"]&&(r=this.re.get_fuzzy_link_search(),r.lastIndex=0),this.__opts__.fuzzyEmail&&this.__schemas__["mailto:"]&&(u=this.re.get_fuzzy_mail_host_search(),u.lastIndex=0,h=this.re.get_mail_name_validator());;){const N=Math.max(T-1,0);if(u&&h&&!k&&(!b||b.index<T))for(u.lastIndex<N&&(u.lastIndex=N);;){const ee=u.exec(e);if(!ee){k=!0,b=void 0;break}const L=h.exec(e.slice(Math.max(0,ee.index-65),ee.index));if(L){if(b={schema:"mailto:",index:ee.index-L[1].length,lastIndex:ee.index+ee[0].length},b.index>=T)break;u.lastIndex<N&&(u.lastIndex=N)}}if(r&&!S&&(!f||f.index<T))for(r.lastIndex<N&&(r.lastIndex=N);;){const ee=r.exec(e);if(!ee){S=!0,f=void 0;break}if(f={schema:"",index:ee.index+ee[1].length,lastIndex:ee.index+ee[0].length},f.index>=T)break;r.lastIndex<N&&(r.lastIndex=N)}let I=b;(!I||f&&(f.index<I.index||f.index===I.index&&f.lastIndex>I.lastIndex))&&(I=f);let P;if(!x)for(;;){if(!v){i.lastIndex<N&&(i.lastIndex=N);const F=i.exec(e);if(!F){x=!0;break}v={schema:F[2],index:F.index+F[1].length,lastIndex:F.index+F[0].length}}if(v.index<T){v=void 0;continue}if(I&&v.index>I.index)break;const ee=v;v=void 0;const L=this.testSchemaAt(e,ee.schema,ee.lastIndex);if(L){P={schema:ee.schema,index:ee.index,lastIndex:ee.lastIndex+L};break}}let E=P;if((!E||b&&(b.index<E.index||b.index===E.index&&b.lastIndex>E.lastIndex))&&(E=b),(!E||f&&(f.index<E.index||f.index===E.index&&f.lastIndex>E.lastIndex))&&(E=f),!E)break;E===b?b=void 0:E===f&&(f=void 0);const $=new qx(e,E.schema,E.index,E.lastIndex);$.schema?this.__schemas__[$.schema].normalize($,this):this.normalize($),n.push($),T=E.lastIndex}return n.length?n:null}matchAtStart(e){if(!e.length)return null;const n=this.re.get_schema_at_start().exec(e);if(!n)return null;const i=this.testSchemaAt(e,n[2],n[0].length);if(!i)return null;const r=new qx(e,n[2],n.index+n[1].length,n.index+n[0].length+i);return this.__schemas__[r.schema].normalize(r,this),r}tlds(e,n=!1){return e=Array.isArray(e)?e:[e],n?this.__opts__.tlds=this.__opts__.tlds.concat(e):this.__opts__.tlds=e,this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}normalize(e){e.schema||(e.url=`http://${e.url}`),e.schema==="mailto:"&&!/^mailto:/i.test(e.url)&&(e.url=`mailto:${e.url}`)}};const c2=JSON.parse('["aaa","aarp","abb","abbott","abbvie","abc","able","abogado","abudhabi","ac","academy","accenture","accountant","accountants","aco","actor","ad","ads","adult","ae","aeg","aero","aetna","af","afl","africa","ag","agakhan","agency","ai","aig","airbus","airforce","airtel","akdn","al","alibaba","alipay","allfinanz","allstate","ally","alsace","alstom","am","amazon","americanexpress","americanfamily","amex","amfam","amica","amsterdam","analytics","android","anquan","anz","ao","aol","apartments","app","apple","aq","aquarelle","ar","arab","aramco","archi","army","arpa","art","arte","as","asda","asia","associates","at","athleta","attorney","au","auction","audi","audible","audio","auspost","author","auto","autos","aw","aws","ax","axa","az","azure","ba","baby","baidu","banamex","band","bank","bar","barcelona","barclaycard","barclays","barefoot","bargains","baseball","basketball","bauhaus","bayern","bb","bbc","bbt","bbva","bcg","bcn","bd","be","beats","beauty","beer","berlin","best","bestbuy","bet","bf","bg","bh","bharti","bi","bible","bid","bike","bing","bingo","bio","biz","bj","black","blackfriday","blockbuster","blog","bloomberg","blue","bm","bms","bmw","bn","bnpparibas","bo","boats","boehringer","bofa","bom","bond","boo","book","booking","bosch","bostik","boston","bot","boutique","box","br","bradesco","bridgestone","broadway","broker","brother","brussels","bs","bt","build","builders","business","buy","buzz","bv","bw","by","bz","bzh","ca","cab","cafe","cal","call","calvinklein","cam","camera","camp","canon","capetown","capital","capitalone","car","caravan","cards","care","career","careers","cars","casa","case","cash","casino","cat","catering","catholic","cba","cbn","cbre","cc","cd","center","ceo","cern","cf","cfa","cfd","cg","ch","chanel","channel","charity","chase","chat","cheap","chintai","christmas","chrome","church","ci","cipriani","circle","cisco","citadel","citi","citic","city","ck","cl","claims","cleaning","click","clinic","clinique","clothing","cloud","club","clubmed","cm","cn","co","coach","codes","coffee","college","cologne","com","commbank","community","company","compare","computer","comsec","condos","construction","consulting","contact","contractors","cooking","cool","coop","corsica","country","coupon","coupons","courses","cpa","cr","credit","creditcard","creditunion","cricket","crown","crs","cruise","cruises","cu","cuisinella","cv","cw","cx","cy","cymru","cyou","cz","dad","dance","data","date","dating","datsun","day","dclk","dds","de","deal","dealer","deals","degree","delivery","dell","deloitte","delta","democrat","dental","dentist","desi","design","dev","dhl","diamonds","diet","digital","direct","directory","discount","discover","dish","diy","dj","dk","dm","dnp","do","docs","doctor","dog","domains","dot","download","drive","dtv","dubai","dupont","durban","dvag","dvr","dz","earth","eat","ec","eco","edeka","edu","education","ee","eg","email","emerck","energy","engineer","engineering","enterprises","epson","equipment","er","ericsson","erni","es","esq","estate","et","eu","eurovision","eus","events","exchange","expert","exposed","express","extraspace","fage","fail","fairwinds","faith","family","fan","fans","farm","farmers","fashion","fast","fedex","feedback","ferrari","ferrero","fi","fidelity","fido","film","final","finance","financial","fire","firestone","firmdale","fish","fishing","fit","fitness","fj","fk","flickr","flights","flir","florist","flowers","fly","fm","fo","foo","food","football","ford","forex","forsale","forum","foundation","fox","fr","free","fresenius","frl","frogans","frontier","ftr","fujitsu","fun","fund","furniture","futbol","fyi","ga","gal","gallery","gallo","gallup","game","games","gap","garden","gay","gb","gbiz","gd","gdn","ge","gea","gent","genting","george","gf","gg","ggee","gh","gi","gift","gifts","gives","giving","gl","glass","gle","global","globo","gm","gmail","gmbh","gmo","gmx","gn","godaddy","gold","goldpoint","golf","goo","goodyear","goog","google","gop","got","gov","gp","gq","gr","grainger","graphics","gratis","green","gripe","grocery","group","gs","gt","gu","gucci","guge","guide","guitars","guru","gw","gy","hair","hamburg","hangout","haus","hbo","hdfc","hdfcbank","health","healthcare","help","helsinki","here","hermes","hiphop","hisamitsu","hitachi","hiv","hk","hkt","hm","hn","hockey","holdings","holiday","homedepot","homegoods","homes","homesense","honda","horse","hospital","host","hosting","hot","hotels","hotmail","house","how","hr","hsbc","ht","hu","hughes","hyatt","hyundai","ibm","icbc","ice","icu","id","ie","ieee","ifm","ikano","il","im","imamat","imdb","immo","immobilien","in","inc","industries","infiniti","info","ing","ink","institute","insurance","insure","int","international","intuit","investments","io","ipiranga","iq","ir","irish","is","ismaili","ist","istanbul","it","itau","itv","jaguar","java","jcb","je","jeep","jetzt","jewelry","jio","jll","jm","jmp","jnj","jo","jobs","joburg","jot","joy","jp","jpmorgan","jprs","juegos","juniper","kaufen","kddi","ke","kerryhotels","kerryproperties","kfh","kg","kh","ki","kia","kids","kim","kindle","kitchen","kiwi","km","kn","koeln","komatsu","kosher","kp","kpmg","kpn","kr","krd","kred","kuokgroup","kw","ky","kyoto","kz","la","lacaixa","lamborghini","lamer","land","landrover","lanxess","lasalle","lat","latino","latrobe","law","lawyer","lb","lc","lds","lease","leclerc","lefrak","legal","lego","lexus","lgbt","li","lidl","life","lifeinsurance","lifestyle","lighting","like","lilly","limited","limo","lincoln","link","live","living","lk","llc","llp","loan","loans","locker","locus","lol","london","lotte","lotto","love","lpl","lplfinancial","lr","ls","lt","ltd","ltda","lu","lundbeck","luxe","luxury","lv","ly","ma","madrid","maif","maison","makeup","man","management","mango","map","market","marketing","markets","marriott","marshalls","mattel","mba","mc","mckinsey","md","me","med","media","meet","melbourne","meme","memorial","men","menu","merckmsd","mg","mh","miami","microsoft","mil","mini","mint","mit","mitsubishi","mk","ml","mlb","mls","mm","mma","mn","mo","mobi","mobile","moda","moe","moi","mom","monash","money","monster","mormon","mortgage","moscow","moto","motorcycles","mov","movie","mp","mq","mr","ms","msd","mt","mtn","mtr","mu","museum","music","mv","mw","mx","my","mz","na","nab","nagoya","name","navy","nba","nc","ne","nec","net","netbank","netflix","network","neustar","new","news","next","nextdirect","nexus","nf","nfl","ng","ngo","nhk","ni","nico","nike","nikon","ninja","nissan","nissay","nl","no","nokia","norton","now","nowruz","nowtv","np","nr","nra","nrw","ntt","nu","nyc","nz","obi","observer","office","okinawa","olayan","olayangroup","ollo","om","omega","one","ong","onl","online","ooo","open","oracle","orange","org","organic","origins","osaka","otsuka","ott","ovh","pa","page","panasonic","paris","pars","partners","parts","party","pay","pccw","pe","pet","pf","pfizer","pg","ph","pharmacy","phd","philips","phone","photo","photography","photos","physio","pics","pictet","pictures","pid","pin","ping","pink","pioneer","pizza","pk","pl","place","play","playstation","plumbing","plus","pm","pn","pnc","pohl","poker","politie","porn","post","pr","praxi","press","prime","pro","prod","productions","prof","progressive","promo","properties","property","protection","pru","prudential","ps","pt","pub","pw","pwc","py","qa","qpon","quebec","quest","racing","radio","re","read","realestate","realtor","realty","recipes","red","redumbrella","rehab","reise","reisen","reit","reliance","ren","rent","rentals","repair","report","republican","rest","restaurant","review","reviews","rexroth","rich","richardli","ricoh","ril","rio","rip","ro","rocks","rodeo","rogers","room","rs","rsvp","ru","rugby","ruhr","run","rw","rwe","ryukyu","sa","saarland","safe","safety","sakura","sale","salon","samsclub","samsung","sandvik","sandvikcoromant","sanofi","sap","sarl","sas","save","saxo","sb","sbi","sbs","sc","scb","schaeffler","schmidt","scholarships","school","schule","schwarz","science","scot","sd","se","search","seat","secure","security","seek","select","sener","services","seven","sew","sex","sexy","sfr","sg","sh","shangrila","sharp","shell","shia","shiksha","shoes","shop","shopping","shouji","show","si","silk","sina","singles","site","sj","sk","ski","skin","sky","skype","sl","sling","sm","smart","smile","sn","sncf","so","soccer","social","softbank","software","sohu","solar","solutions","song","sony","soy","spa","space","sport","spot","sr","srl","ss","st","stada","staples","star","statebank","statefarm","stc","stcgroup","stockholm","storage","store","stream","studio","study","style","su","sucks","supplies","supply","support","surf","surgery","suzuki","sv","swatch","swiss","sx","sy","sydney","systems","sz","tab","taipei","talk","taobao","target","tatamotors","tatar","tattoo","tax","taxi","tc","tci","td","tdk","team","tech","technology","tel","temasek","tennis","teva","tf","tg","th","thd","theater","theatre","tiaa","tickets","tienda","tips","tires","tirol","tj","tjmaxx","tjx","tk","tkmaxx","tl","tm","tmall","tn","to","today","tokyo","tools","top","toray","toshiba","total","tours","town","toyota","toys","tr","trade","trading","training","travel","travelers","travelersinsurance","trust","trv","tt","tube","tui","tunes","tushu","tv","tvs","tw","tz","ua","ubank","ubs","ug","uk","unicom","university","uno","uol","ups","us","uy","uz","va","vacations","vana","vanguard","vc","ve","vegas","ventures","verisign","vermögensberater","vermögensberatung","versicherung","vet","vg","vi","viajes","video","vig","viking","villas","vin","vip","virgin","visa","vision","viva","vivo","vlaanderen","vn","vodka","volvo","vote","voting","voto","voyage","vu","wales","walmart","walter","wang","wanggou","watch","watches","weather","weatherchannel","webcam","weber","website","wed","wedding","weibo","weir","wf","whoswho","wien","wiki","williamhill","win","windows","wine","winners","wme","wolterskluwer","woodside","work","works","world","wow","ws","wtc","wtf","xbox","xerox","xihuan","xin","xxx","xyz","yachts","yahoo","yamaxun","yandex","ye","yodobashi","yoga","yokohama","you","youtube","yt","yun","za","zappos","zara","zero","zip","zm","zone","zuerich","zw","ελ","ευ","бг","бел","дети","ею","католик","ком","мкд","мон","москва","онлайн","орг","рус","рф","сайт","срб","укр","қаз","հայ","ישראל","קום","ابوظبي","ارامكو","الاردن","البحرين","الجزائر","السعودية","العليان","المغرب","امارات","ایران","بارت","بازار","بيتك","بھارت","تونس","سودان","سورية","شبكة","عراق","عرب","عمان","فلسطين","قطر","كاثوليك","كوم","مصر","مليسيا","موريتانيا","موقع","همراه","پاکستان","ڀارت","कॉम","नेट","भारत","भारतम्","भारोत","संगठन","বাংলা","ভারত","ভাৰত","ਭਾਰਤ","ભારત","ଭାରତ","இந்தியா","இலங்கை","சிங்கப்பூர்","భారత్","ಭಾರತ","ഭാരതം","ලංකා","คอม","ไทย","ລາວ","გე","みんな","アマゾン","クラウド","グーグル","コム","ストア","セール","ファッション","ポイント","世界","中信","中国","中國","中文网","亚马逊","企业","佛山","信息","健康","八卦","公司","公益","台湾","台灣","商城","商店","商标","嘉里","嘉里大酒店","在线","大拿","天主教","娱乐","家電","广东","微博","慈善","我爱你","手机","招聘","政务","政府","新加坡","新闻","时尚","書籍","机构","淡马锡","游戏","澳門","点看","移动","组织机构","网址","网店","网站","网络","联通","谷歌","购物","通販","集团","電訊盈科","飞利浦","食品","餐厅","香格里拉","香港","닷넷","닷컴","삼성","한국"]');function Vz(e,n){return e.endsWith(n)?e.length===n.length||e[e.length-n.length-1]===".":!1}function Uz(e,n){const i=e.length-n.length-2,r=e.lastIndexOf(".",i);return r===-1?e:e.slice(r+1)}function Gz(e,n,i){if(i.validHosts!==null){const u=i.validHosts;for(const h of u)if(Vz(n,h))return h}let r=0;if(n.startsWith("."))for(;r<n.length&&n[r]===".";)r+=1;return e.length===n.length-r?null:Uz(n,e)}function Kz(e,n){return e.slice(0,-n.length-1)}const nf=/[\t\n\r]/g;let Lf=!1;function Px(e){return e>=97&&e<=122||e>=48&&e<=57||e>127||e>=65&&e<=90||e===45||e===95}function Mx(e,n,i){const r=i-n,u=e.charCodeAt(n)|32;if(r===2)return u===119&&(e.charCodeAt(n+1)|32)===115?1:0;if(r===3){const h=e.charCodeAt(n+1)|32,f=e.charCodeAt(n+2)|32;return u===119&&h===115&&f===115||u===102&&h===116&&f===112?1:0}else if(r===4){const h=e.charCodeAt(n+1)|32,f=e.charCodeAt(n+2)|32,b=e.charCodeAt(n+3)|32;return u===104&&h===116&&f===116&&b===112?1:u===102&&h===105&&f===108&&b===101?2:0}else if(r===5)return u===104&&(e.charCodeAt(n+1)|32)===116&&(e.charCodeAt(n+2)|32)===116&&(e.charCodeAt(n+3)|32)===112&&(e.charCodeAt(n+4)|32)===115?1:0;return 0}function hc(e,n,i=!1){let r=0,u=e.length,h=!1,f=!1;if(Lf=!1,!n){if(e.startsWith("data:"))return null;for(;r<e.length&&e.charCodeAt(r)<=32;)r+=1;for(;u>r+1&&e.charCodeAt(u-1)<=32;)u-=1;if(e.charCodeAt(r)===47&&e.charCodeAt(r+1)===47)r+=2;else{const E=e.indexOf(":/",r);if(E!==-1){const $=Mx(e,r,E);if($===1)for(f=!0,r=E+2;e.charCodeAt(r)===47||e.charCodeAt(r)===92;)r+=1;else if($===2){f=!0,r=E+1;let ee=0;for(;(e.charCodeAt(r)===47||e.charCodeAt(r)===92)&&ee<2;)r+=1,ee+=1;if(ee<2)return null}else{for(let ee=r;ee<E;ee+=1){const L=e.charCodeAt(ee)|32;if(!(L>=97&&L<=122||L>=48&&L<=57||L===46||L===45||L===43)){const F=e.charCodeAt(ee);return F===9||F===10||F===13?hc(e.replace(nf,""),n,i):null}}if(e.charCodeAt(E+2)===47)r=E+3;else return null}}else if(e.charCodeAt(r)!==91){let $=-1;for(let ee=r;ee<u;ee+=1){const L=e.charCodeAt(ee);if(L===9||L===10||L===13)return hc(e.replace(nf,""),n,i);if(L===58){$=ee;break}if(L===47||L===92||L===63||L===35)break}if($!==-1){let ee=!1;for(let L=$+1;L<u;L+=1){const F=e.charCodeAt(L);if(F===47||F===92||F===63||F===35)break;if(F===64){ee=!0;break}}if(!ee){let L=!0,F=$+1;for(;F<u;F+=1){const Z=e.charCodeAt(F);if(Z===47||Z===92||Z===63||Z===35)break;if(Z<48||Z>57){L=!1;break}}if(F===$+1&&(L=!1),!L){const Z=Mx(e,r,$);if(Z===0){let ae=!1;for(let M=$+1;M<u;M+=1){const Y=e.charCodeAt(M);if(Y===47||Y===92||Y===63||Y===35)break;if(Y===58){ae=!0;break}}if(!ae)return null}else if(f=!0,r=$+1,Z===2){let ae=0;for(;(e.charCodeAt(r)===47||e.charCodeAt(r)===92)&&ae<2;)r+=1,ae+=1;if(ae<2)return null}else for(;e.charCodeAt(r)===47||e.charCodeAt(r)===92;)r+=1}}}}}let v=-1,x=-1,S=-1,k=-1,T=!1,N=i,I=r-1,P=-1;if(i&&r<u){const E=e.charCodeAt(r);(!(Px(E)||E===46||E===95)||E===45)&&(N=!1)}for(let E=r;E<u;E+=1){const $=e.charCodeAt(E);if($<64)if($===47||$===35||$===63){u=E;break}else $===58?(k===-1&&(k=E),S=E):$===9||$===10||$===13?T=!0:i&&($===46?((E-I>64||P===46||P===45)&&(N=!1),I=E):($<48||$>57)&&($!==45||P===46)&&(N=!1));else if(f&&$===92){u=E;break}else $===64?(v=E,k=-1):$===93?x=E:$>=65&&$<=90?h=!0:i&&!Px($)&&(N=!1);i&&(P=$)}if(T)return hc(e.replace(nf,""),n,i);if(v!==-1&&v>=r&&v<u&&(r=v+1),e.charCodeAt(r)===91)return x!==-1?e.slice(r+1,x).toLowerCase():null;if(S!==-1&&S>r&&S<u&&k===S&&(u=S),r>=u)return null;i&&N&&v===-1&&S===-1&&x===-1&&e.charCodeAt(u-1)!==46&&u-r<=255&&u-I-1<=63&&P!==45&&(Lf=!0)}for(;u>r+1&&e.charCodeAt(u-1)===46;)u-=1;const b=r!==0||u!==e.length?e.slice(r,u):e;return h?b.toLowerCase():b}function Hz(e){if(e.length<7||e.length>15)return!1;let n=0;for(let i=0;i<e.length;i+=1){const r=e.charCodeAt(i);if(r===46)n+=1;else if(r<48||r>57)return!1}return n===3&&e.charCodeAt(0)!==46&&e.charCodeAt(e.length-1)!==46}function Qz(e){if(e.length<3)return!1;let n=e.startsWith("[")?1:0,i=e.length;if(e[i-1]==="]"&&(i-=1),i-n>39)return!1;let r=!1;for(;n<i;n+=1){const u=e.charCodeAt(n);if(u===58)r=!0;else if(!(u>=48&&u<=57||u>=97&&u<=102||u>=65&&u<=70))return!1}return r}function Fz(e){return Qz(e)||Hz(e)}const Zz=["test","localhost","invalid","example","example.com","example.net","example.org","local","onion","alt","home.arpa","ipv4only.arpa","resolver.arpa","service.arpa","6tisch.arpa","eap.arpa"];function Yz(e){for(const n of Zz)if(e.endsWith(n)&&(e.length===n.length||e.charCodeAt(e.length-n.length-1)===46))return!0;return!1}function Bx(e){return e>=97&&e<=122||e>=48&&e<=57||e>127}function Lx(e){if(e.length>255||e.length===0||!Bx(e.charCodeAt(0))&&e.charCodeAt(0)!==46&&e.charCodeAt(0)!==95)return!1;let n=-1,i=-1;const r=e.length;for(let u=0;u<r;u+=1){const h=e.charCodeAt(u);if(h===46){if(u-n>64||i===46||i===45)return!1;n=u}else if(!(Bx(h)||h===45||h===95)||h===45&&i===46)return!1;i=h}return r-n-1<=63&&i!==45}function u2({allowIcannDomains:e=!0,allowPrivateDomains:n=!1,detectIp:i=!0,detectSpecialUse:r=!1,extractHostname:u=!0,mixedInputs:h=!0,validHosts:f=null,validateHostname:b=!0}){return{allowIcannDomains:e,allowPrivateDomains:n,detectIp:i,detectSpecialUse:r,extractHostname:u,mixedInputs:h,validHosts:f,validateHostname:b}}const Xz=u2({});function Jz(e){return e===void 0?Xz:u2(e)}function Wz(e,n){return n.length===e.length?"":e.slice(0,-n.length-1)}function e9(){return{domain:null,domainWithoutSuffix:null,hostname:null,isIcann:null,isIp:null,isPrivate:null,isSpecialUse:null,publicSuffix:null,subdomain:null}}function d2(e){e.domain=null,e.domainWithoutSuffix=null,e.hostname=null,e.isIcann=null,e.isIp=null,e.isPrivate=null,e.isSpecialUse=null,e.publicSuffix=null,e.subdomain=null}function m2(e,n,i,r,u){const h=Jz(r);if(typeof e!="string")return u;let f=!1;return h.extractHostname?h.mixedInputs?(f=Lx(e),u.hostname=hc(e,f,h.validateHostname)):u.hostname=hc(e,!1,h.validateHostname):u.hostname=e,h.detectIp&&u.hostname!==null&&(u.isIp=Fz(u.hostname),u.isIp)?u:h.validateHostname&&h.extractHostname&&u.hostname!==null&&!(f&&u.hostname===e)&&!Lf&&!Lx(u.hostname)?(u.hostname=null,u):(n===0||u.hostname===null||(n===5&&h.detectSpecialUse&&(u.isSpecialUse=Yz(u.hostname)),i(u.hostname,h,u),n===2||u.publicSuffix===null)||(u.domain=Gz(u.publicSuffix,u.hostname,h),n===3||u.domain===null)||(u.subdomain=Wz(u.hostname,u.domain),n===4)||(u.domainWithoutSuffix=Kz(u.domain,u.publicSuffix)),u)}function t9(e,n,i){if(!n.allowPrivateDomains&&e.length>3){const r=e.length-1,u=e.charCodeAt(r),h=e.charCodeAt(r-1),f=e.charCodeAt(r-2),b=e.charCodeAt(r-3);if(u===109&&h===111&&f===99&&b===46)return i.isIcann=!0,i.isPrivate=!1,i.publicSuffix="com",!0;if(u===103&&h===114&&f===111&&b===46)return i.isIcann=!0,i.isPrivate=!1,i.publicSuffix="org",!0;if(u===117&&h===100&&f===101&&b===46)return i.isIcann=!0,i.isPrivate=!1,i.publicSuffix="edu",!0;if(u===118&&h===111&&f===103&&b===46)return i.isIcann=!0,i.isPrivate=!1,i.publicSuffix="gov",!0;if(u===116&&h===101&&f===110&&b===46)return i.isIcann=!0,i.isPrivate=!1,i.publicSuffix="net",!0;if(u===101&&h===100&&f===46)return i.isIcann=!0,i.isPrivate=!1,i.publicSuffix="de",!0}return!1}const So=new Uint8Array([1,2,1,1,1,1,1,1,1,1,1,1,0,2,2,2,0,2,2,0,2,0,0,1,0,0,2,1,1,1,1,1,1,0,0,0,1,0,1,1,1,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,1,1,1,1,1,0,0,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1,1,0,1,0,1,1,0,1,1,0,0,0,0,0,0,1,1,1,0,2,0,0,0,0,0,0,0,2,0,2,2,0,0,2,2,0,0,0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,0,2,1,1,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,2,0,0,0,0,2,0,0,0,0,0,0,0,0,0,2,0,2,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,2,2,1,1,1,1,1,1,1,1,1,0,1,1,0,0,0,0,1,0,2,2,0,0,0,2,0,1,1,0,2,0,2,2,0,1,1,1,1,1,1,1,1,0,1,1,1,0,1,1,1,1,0,0,0,0,1,0,1,1,1,1,0,0,1,1,1,1,1,1,1,1,1,1,2,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,2,2,0,2,2,0,0,0,0,0,1,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,0,2,0,2,2,2,2,0,0,0,0,2,0,0,0,0,0,0,2,2,0,0,0,2,2,1,1,1,1,2,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,0,0,0,2,2,0,0,2,1,1,1,1,1,1,1,1,1,1,1,1,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,2,2,1,2,1,1,1,2,1,1,1,1,1,0,1,1,1,1,1,1,1,1,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,0,1,1,1,1,1,2,1,1,1,1,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1,0,0,0,0,0]),Od=new Uint16Array([0,0,0,10,11,18,106,111,117,124,130,136,145,146,147,148,149,150,151,153,154,155,157,159,226,239,241,242,243,258,265,266,269,270,271,274,276,295,296,298,307,312,313,331,332,335,337,338,340,374,375,377,380,381,385,387,391,394,426,429,442,443,451,452,454,464,478,479,480,489,490,527,532,548,568,574,615,616,643,670,671,819,825,828,829,830,835,840,849,871,872,873,874,875,876,877,895,897,898,901,903,904,906,908,923,938,943,944,946,947,948,949,950,952,955,960,961,962,964,965,968,971,972,973,986,988,1e3,1011,1019,1021,1061,1064,1068,1069,1071,1074,1085,1087,1097,1099,1105,1107,1108,1110,1113,1114,1115,1167,1169,1171,1191,1192,1193,1194,1196,1207,1238,1249,1261,1270,1277,1282,1295,1306,1319,1320,1331,1365,1366,1367,1382,1397,1469,1470,1472,1473,1507,1508,1509,1512,1516,1518,1547,1548,1556,1557,1558,1560,1562,1563,1565,1566,1567,1578,1579,1580,1581,1582,1583,1584,1585,1586,1587,1588,1589,1590,1591,1592,1594,1595,1596,1598,2053,2056,2057,2059,2066,2073,2083,2087,2098,2099,2100,2112,2113,2115,2117,2118,2125,2126,2128,2129,2131,2132,2133,2134,2135,2209,2211,2232,2233,2234,2236,2262,2263,2314,2315,2317,2324,2330,2340,2350,2403,2404,2405,2415,2429,2430,2433,2440,2441,2449,2450,2451,2452,2453,2464,2465,2466,2468,2469,2470,2471,2473,2483,2495,2501,2533,2537,2539,2540,2542,2543,2554,2555,2557,2565,2572,2578,2583,2584,2590,2593,2599,2606,2607,2614,2622,2623,2624,2662,2668,2683,2684,2689,2707,2738,2756,2758,2761,2769,2771,2778,2830,2854,2855,2856,2857,2858,2859,2860,2861,2868,2869,2870,2871,2872,2873,2875,2876,2880,2964,2977,2978,3414,3418,3432,3484,3512,3534,3592,3614,3629,3692,3743,3781,3817,3842,3984,4030,4081,4100,4134,4149,4169,4199,4230,4253,4284,4314,4346,4373,4448,4470,4508,4518,4552,4571,4597,4639,4689,4715,4784,4785,4787,4810,4833,4869,4900,4917,4974,4987,5011,5040,5042,5076,5092,5120,5425,5434,5443,5450,5467,5471,5477,5516,5518,5525,5532,5541,5548,5549,5560,5563,5578,5579,5588,5589,5598,5607,5613,5615,5616,5617,5653,5654,5656,5664,5671,5684,5688,5690,5691,5697,5704,5718,5728,5733,5741,5749,5755,5756,5760,5762,5763,5775,5776,5777,5778,5780,5781,5784,5786,5789,5793,5794,5800,5801,5802,5804,5806,5808,5809,5810,5813,5815,5818,5819,5821,6019,6026,6027,6037,6042,6059,6073,6082,6083,6084,6088,6089,6091,6093,6099,6100,6103,6104,6106,6107,6108,7008,7009,7013,7031,7040,7043,7050,7051,7053,7054,7055,7057,7109,7110,7113,7114,7231,7232,7243,7254,7261,7264,7273,7274,7275,7290,7345,7536,7538,7539,7541,7546,7559,7574,7581,7590,7593,7596,7603,7611,7615,7616,7617,7631,7635,7644,7645,7646,7650,7685,7686,7703,7710,7718,7719,7724,7732,7776,7777,7783,7786,7797,7802,7803,7806,7839,7840,7846,7853,7854,7863,7872,7887,7891,7943,7944,7949,7951,7954,7956,7957,7958,7967,7981,7989,8003,8015,8016,8018,8020,8042,8053,8059,8060,8072,8084,8171,8183,8185,8194,8197,8203,8228,8231,8232,8233,8235,8238,8241,8252,8254,8256,8284,8358,8365,8369,8370,8379,8401,8402,8407,8408,8487,8489,8491,8500,8504,8510,8516,8522,8532,8537,8538,8556,8567,8572,8577,8587,8593,8597,8603,8609,10217,10218,10219,10226,10228]),qd=new Uint8Array([3,3,3,3,3,3,3,3,5,8,8,2,2,3,3,3,3,3,8,5,5,5,5,5,3,3,5,5,9,12,19,8,19,8,11,9,9,8,7,7,6,8,9,16,10,7,7,11,8,6,6,9,7,11,7,14,4,4,4,4,4,4,10,7,6,6,6,6,10,10,6,10,10,22,11,9,10,10,10,9,10,8,7,7,7,8,21,13,11,11,9,10,9,13,10,8,8,9,12,9,7,10,7,7,13,7,3,3,3,3,3,2,3,3,3,3,3,3,3,3,3,3,8,6,3,3,3,3,3,3,2,5,3,3,3,7,2,2,2,2,2,2,3,3,3,1,1,7,8,5,2,2,7,2,2,1,4,1,11,9,9,5,5,8,5,5,5,5,5,5,5,3,3,3,3,3,5,11,9,9,13,7,14,7,6,6,6,7,6,6,6,6,6,10,7,11,9,4,4,4,4,4,4,6,6,6,6,6,8,7,10,9,9,9,8,9,8,10,6,9,9,8,10,10,7,8,1,9,10,12,12,12,10,9,9,10,10,9,9,1,1,5,3,3,3,3,3,3,3,3,3,3,3,3,6,6,6,4,3,3,3,7,4,4,4,3,3,6,7,3,4,1,2,2,2,6,1,2,2,2,2,2,12,5,3,8,9,13,4,4,13,9,9,11,7,3,12,9,2,2,2,3,3,3,3,3,8,2,2,3,3,3,3,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,4,4,3,7,10,15,7,15,15,20,15,9,10,10,12,14,14,14,12,12,12,12,12,14,14,10,10,10,10,14,9,9,9,10,14,14,14,13,13,9,9,9,9,9,9,7,8,6,8,8,6,8,13,8,8,6,13,8,11,13,8,6,13,8,6,9,10,10,12,14,14,14,12,12,12,12,14,14,10,10,10,10,9,9,9,10,14,14,11,13,13,9,9,9,9,9,9,2,6,9,2,2,3,3,3,3,3,3,3,3,3,4,4,4,2,3,3,3,3,3,3,7,7,2,3,2,2,5,3,3,3,3,3,3,4,2,2,2,2,2,2,3,3,3,3,3,3,3,4,5,7,2,2,12,8,10,8,10,7,18,4,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,5,2,2,3,3,3,5,5,3,8,8,6,8,6,6,4,6,7,7,7,10,11,2,5,5,3,3,3,3,3,3,5,5,6,11,10,7,7,7,4,4,4,2,3,3,3,3,3,2,7,5,5,3,3,3,3,3,3,3,3,7,7,7,11,7,6,9,6,6,8,10,8,6,8,13,4,4,4,4,4,10,8,11,8,8,8,10,10,7,10,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,2,2,2,2,2,2,5,5,5,5,5,5,5,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,7,10,13,7,8,7,11,8,8,6,9,8,8,6,6,6,8,8,6,6,6,6,6,9,7,6,4,4,4,4,4,4,4,6,6,6,9,7,8,10,8,8,2,3,3,3,3,3,2,8,9,9,2,2,2,3,3,3,2,3,3,3,9,2,2,3,3,3,3,3,3,5,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,12,5,5,3,5,4,2,3,2,4,3,9,2,2,2,2,2,5,5,3,8,8,13,6,10,9,4,7,9,11,2,3,7,3,3,4,1,3,4,2,9,3,3,12,5,3,7,10,10,7,4,4,6,14,7,9,7,13,2,2,2,2,2,2,3,3,3,3,3,8,15,4,4,2,3,3,3,7,4,9,9,2,3,3,3,5,3,2,2,7,2,7,6,6,7,2,4,2,2,2,2,2,2,8,8,8,9,5,2,3,3,3,3,3,3,10,7,4,4,4,4,3,4,2,3,3,3,3,3,10,7,4,4,4,4,2,3,3,3,3,10,7,4,4,4,4,3,9,6,6,6,9,13,9,2,2,2,8,7,9,5,3,3,3,5,5,12,9,10,7,8,7,6,8,6,11,12,7,9,10,4,4,7,8,11,6,7,9,8,7,10,8,9,15,7,8,5,4,7,2,3,3,3,2,14,10,2,14,10,2,14,3,9,13,13,10,14,16,17,11,2,14,2,14,3,9,13,10,14,16,17,11,14,10,14,2,7,3,10,7,14,10,2,14,10,9,9,17,6,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,10,10,10,12,9,4,10,11,8,8,8,7,9,5,3,3,3,3,3,3,3,3,5,8,4,4,4,4,4,4,6,16,3,3,14,3,14,2,14,9,13,10,10,14,16,17,11,6,9,10,10,12,14,14,14,12,12,12,12,14,14,10,10,10,10,14,9,9,9,10,14,14,14,9,9,9,9,9,9,2,14,9,13,10,10,14,16,17,11,6,2,14,9,17,13,10,10,14,16,17,11,6,2,14,9,13,10,14,16,17,11,2,14,9,13,10,16,11,2,14,10,19,7,2,14,9,13,10,19,10,7,14,16,17,11,6,2,14,9,13,10,19,7,14,16,17,11,2,14,9,13,17,13,10,10,14,16,17,11,6,3,2,14,9,13,10,10,14,16,17,11,6,9,10,12,14,14,14,12,12,12,12,12,14,14,14,10,10,10,14,9,9,9,9,14,14,14,13,13,14,9,9,9,9,9,9,4,11,2,14,9,13,17,13,10,19,10,7,14,16,17,11,6,2,14,9,13,17,13,10,19,10,7,14,16,17,11,6,2,9,10,10,7,17,3,3,12,12,16,15,15,12,14,14,14,20,20,13,12,12,12,12,12,12,20,25,14,14,12,12,10,10,10,10,9,9,9,25,4,9,17,10,7,14,16,21,13,13,14,20,14,13,17,24,9,12,13,25,13,21,20,17,9,9,9,9,9,9,12,17,4,4,9,9,9,10,10,12,14,14,14,12,12,12,12,12,14,14,10,10,10,10,14,9,9,9,10,14,14,14,13,13,9,9,9,9,9,9,1,8,7,11,11,1,3,3,3,4,8,9,10,14,14,12,12,12,12,14,14,10,10,10,10,14,9,9,9,10,14,14,14,13,13,9,9,9,9,9,7,4,4,4,4,4,4,4,4,4,4,9,12,6,14,4,12,7,2,2,1,2,7,6,4,4,4,6,8,8,7,4,5,6,3,3,3,3,4,16,8,3,5,4,3,3,3,5,2,2,8,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,11,12,7,7,13,9,10,12,8,9,7,8,5,12,10,13,14,5,5,5,13,5,5,5,3,3,3,5,16,5,5,5,5,5,7,12,14,8,12,8,10,12,9,11,7,9,7,10,7,13,9,7,12,8,17,7,7,16,10,13,13,8,10,10,14,17,7,16,16,15,8,10,10,12,17,7,17,14,7,10,17,8,7,7,7,8,15,15,7,14,10,10,10,11,11,7,7,13,8,10,7,16,7,8,7,14,17,12,10,11,21,8,9,7,13,9,8,13,6,12,7,6,13,10,10,10,8,18,9,17,13,10,12,6,13,6,11,8,13,10,13,18,13,11,13,8,16,7,10,8,16,12,10,8,8,6,14,11,8,15,8,8,7,7,12,7,8,9,14,15,8,9,10,9,15,7,8,8,12,13,9,10,15,15,13,7,10,10,20,7,6,9,6,6,14,11,14,11,12,9,10,16,16,12,7,11,28,8,11,10,7,21,8,7,9,4,4,4,17,7,8,6,9,6,6,13,6,6,6,6,18,20,14,8,11,12,9,10,13,15,19,8,9,12,7,10,16,12,9,9,9,14,12,11,9,12,11,18,9,9,9,10,7,7,16,8,9,7,13,12,10,18,7,8,11,7,7,8,8,13,7,7,7,11,15,13,11,7,8,15,11,7,8,18,14,13,18,15,10,12,12,9,7,11,11,8,7,10,8,14,12,10,18,7,10,9,7,8,13,10,14,9,10,8,8,23,7,7,11,12,12,17,7,7,11,11,17,16,16,7,8,11,14,14,8,10,7,7,16,16,13,9,11,9,15,15,11,11,7,7,14,7,9,7,7,16,10,13,10,11,14,7,11,10,11,7,11,10,11,15,11,15,10,12,17,10,14,13,11,11,12,13,10,7,13,10,16,12,21,9,10,10,7,11,14,17,7,7,8,11,12,8,15,14,14,8,17,12,10,10,7,9,11,7,10,7,11,18,7,11,7,12,11,8,8,14,12,7,8,15,3,7,7,5,2,9,2,2,2,2,2,2,2,3,3,3,3,3,3,3,2,5,3,3,3,3,3,3,4,4,3,3,3,3,3,3,5,11,6,4,7,10,7,7,11,1,10,2,2,3,3,3,3,3,3,3,3,5,7,3,5,6,3,3,5,2,2,5,3,4,13,11,3,3,6,3,5,14,2,2,3,8,2,2,12,5,18,5,3,3,3,16,5,5,5,10,7,13,12,13,9,12,14,19,9,9,21,9,9,10,6,9,6,15,10,6,12,8,6,10,15,4,4,6,6,9,9,12,16,14,23,7,7,7,14,9,7,7,11,14,10,7,10,10,10,12,6,11,10,13,11,15,11,7,12,10,3,7,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,4,3,7,2,5,5,3,3,5,5,5,5,7,6,6,6,4,4,4,4,4,4,6,6,6,6,6,7,10,2,2,2,5,5,5,5,3,3,3,3,3,5,5,10,9,11,8,7,12,8,9,7,6,13,11,6,13,7,9,9,4,4,4,4,4,4,6,10,7,8,13,8,8,9,14,8,10,7,7,7,9,6,9,7,2,12,5,3,3,13,4,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,3,3,3,3,3,3,3,3,4,5,5,5,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,8,4,4,4,4,4,4,4,4,4,4,4,4,9,3,3,3,3,3,3,3,3,3,3,4,2,2,2,5,3,3,3,3,3,3,3,3,4,4,1,7,6,4,12,3,3,3,3,3,8,7,3,3,3,3,3,3,4,4,11,14,2,8,3,5,5,8,10,8,6,4,7,17,7,4,5,2,6,3,5,2,4,4,2,12,5,5,3,15,13,10,8,11,2,2,3,3,3,3,3,3,3,3,4,4,5,3,3,3,3,4,18,2,12,5,3,3,3,3,3,5,16,8,8,9,6,6,4,4,4,4,31,6,6,10,11,21,10,9,7,10,7,7,2,4,4,4,4,6,5,3,3,4,3,3,3,3,3,3,3,3,3,6,6,6,2,2,2,5,3,3,3,7,7,4,3,3,3,3,3,3,3,3,3,3,3,3,3,2,3,3,3,3,8,2,3,3,3,3,3,5,9,11,3,3,3,3,4,4,3,3,3,3,3,5,10,9,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,2,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,11,10,10,10,10,10,11,10,11,10,11,10,9,9,11,3,3,3,3,3,3,5,3,7,8,8,7,6,6,11,4,4,4,7,8,9,9,2,3,7,4,4,2,5,5,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,2,2,5,5,5,5,5,3,3,5,5,5,7,7,6,6,6,4,4,4,4,4,4,4,4,4,4,6,6,8,8,1,2,2,2,2,2,2,3,3,3,3,3,3,3,4,4,6,9,12,3,7,10,7,2,2,3,3,3,3,3,4,3,3,2,2,2,2,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,5,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,5,5,8,8,6,6,8,6,7,4,4,4,4,4,4,6,7,5,5,20,19,8,10,9,7,10,6,8,11,6,6,6,6,13,12,8,6,7,14,11,9,2,5,3,3,6,2,3,2,2,2,2,2,2,2,5,4,3,7,6,4,7,4,3,6,4,7,2,7,7,7,5,5,5,5,3,3,3,3,3,3,3,3,3,3,5,9,10,10,8,11,7,8,20,7,8,9,8,12,6,6,6,8,9,8,12,6,6,8,13,10,12,6,6,7,7,8,9,6,4,4,4,4,4,4,4,10,6,6,6,7,14,11,10,7,8,10,8,11,14,11,11,9,7,9,8,11,9,17,10,9,2,2,2,9,3,3,3,3,15,14,9,5,5,2,8,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,15,12,22,19,17,18,18,19,21,7,16,16,5,5,5,5,5,5,5,5,5,5,5,7,5,5,5,5,5,5,5,5,5,5,5,9,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,5,7,16,11,11,7,7,7,7,17,7,8,12,15,9,19,7,19,8,16,21,11,12,19,14,22,7,7,7,7,7,7,7,7,7,7,7,16,16,19,24,12,7,14,7,12,7,8,10,10,13,7,12,12,7,7,10,18,15,12,16,7,14,12,17,10,16,17,12,17,25,7,7,7,13,6,9,6,9,18,6,6,11,20,10,6,6,6,6,6,6,6,17,6,6,6,15,6,6,6,6,6,8,14,11,12,15,13,19,17,21,7,18,8,13,13,8,12,8,6,6,13,6,15,15,16,6,6,16,6,6,6,14,6,18,6,6,6,17,18,9,13,15,8,19,8,15,15,18,14,16,4,4,4,4,4,4,4,4,4,4,4,4,6,11,10,11,6,21,23,12,17,12,11,14,13,22,15,15,11,12,14,12,7,12,8,14,12,18,10,8,16,19,17,12,14,15,8,9,19,17,12,13,13,15,18,13,23,24,23,21,17,24,8,21,8,14,14,16,14,8,8,15,20,8,19,21,9,8,13,12,13,15,11,8,11,9,9,8,11,8,21,14,21,15,15,13,7,19,7,7,7,7,7,7,16,12,17,18,7,7,11,11,7,9,9,2,2,3,3,2,2,2,3,3,3,3,3,3,3,3,3,3,4,5,5,5,5,5,5,5,5,3,3,10,10,7,9,7,7,7,6,8,6,6,6,6,6,6,6,7,6,8,6,6,9,7,7,7,4,4,4,4,4,4,4,4,8,9,8,7,8,7,8,10,7,5,5,5,5,5,5,3,9,7,7,8,6,6,6,6,6,6,6,6,9,6,6,9,11,13,7,8,9,9,5,5,5,7,8,6,6,6,6,6,6,6,7,8,9,7,10,9,10,7,8,5,5,5,5,5,5,7,7,9,8,7,7,6,6,6,6,6,6,10,6,6,6,6,6,6,6,6,6,6,6,9,10,4,4,4,4,8,7,7,10,10,9,8,8,15,9,8,8,8,8,8,9,10,9,10,7,8,13,5,5,5,5,5,3,3,7,7,8,6,6,6,4,4,11,9,7,8,9,10,7,5,5,5,5,5,3,3,7,6,6,13,7,9,8,7,5,5,5,5,5,5,5,5,3,3,3,3,7,8,7,8,13,6,6,6,6,6,6,6,6,6,6,6,6,6,6,8,8,6,6,6,6,7,6,7,6,6,9,7,4,4,4,4,4,4,4,7,8,7,8,9,8,8,8,7,10,7,8,5,5,5,5,5,5,5,5,3,7,7,7,7,9,7,10,9,6,6,6,6,6,8,8,6,6,6,7,6,6,6,9,9,4,4,13,7,10,9,9,12,7,8,8,10,8,8,8,8,8,8,5,5,5,5,3,7,7,11,7,9,8,8,6,6,10,6,8,8,8,6,7,6,6,12,4,4,4,4,4,4,4,4,4,9,8,8,16,8,9,8,7,5,5,5,5,5,3,3,7,7,7,10,15,8,9,8,9,9,6,6,6,6,6,6,7,4,8,7,8,8,7,8,11,8,5,5,5,5,5,3,7,7,6,11,16,7,6,4,4,4,4,9,9,8,8,8,13,12,8,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,11,7,8,8,9,13,7,7,7,9,8,8,9,12,7,12,7,12,8,7,10,12,9,9,6,6,8,8,6,6,6,6,6,6,6,9,8,9,11,8,6,6,6,6,6,12,7,6,6,6,9,7,7,6,6,6,6,6,11,9,6,6,6,6,6,7,9,4,4,4,4,4,4,4,4,9,9,9,9,7,7,7,7,7,11,7,7,8,8,8,8,8,8,9,8,9,9,7,7,11,11,7,12,8,8,8,8,8,7,8,8,8,8,8,13,12,8,8,8,8,7,7,7,9,5,5,5,5,5,5,5,3,3,7,7,11,7,8,8,8,6,6,6,6,6,6,6,6,6,6,6,10,11,6,7,9,4,4,4,4,4,4,9,9,8,9,8,8,8,7,7,5,5,5,5,5,5,5,5,5,5,3,3,11,7,7,7,9,6,6,11,8,10,6,6,6,12,8,8,7,6,6,8,7,4,4,4,4,4,4,4,4,9,10,9,9,8,10,9,11,8,5,5,5,7,6,6,8,7,4,4,4,4,8,7,7,8,7,8,8,5,5,5,5,7,7,8,8,8,6,6,6,6,6,10,8,9,13,6,7,6,6,8,7,8,4,4,4,4,11,8,8,8,10,5,5,8,7,8,13,8,7,6,8,6,9,7,8,7,5,5,5,5,5,5,3,3,7,8,9,6,4,8,10,10,8,12,9,13,2,7,5,5,5,5,5,7,7,10,6,6,6,6,6,6,6,8,4,4,9,8,8,8,14,8,8,8,9,8,5,5,5,5,5,3,3,9,6,6,6,6,10,12,6,6,6,6,6,6,6,4,4,4,4,11,8,7,8,8,8,5,5,3,3,3,3,7,7,6,8,6,8,11,7,6,6,6,7,4,8,11,9,10,5,5,5,3,3,3,7,7,8,9,8,15,9,6,6,6,6,6,6,11,11,4,4,4,4,4,7,9,9,10,8,7,5,5,5,5,5,5,3,3,8,6,6,6,6,6,6,6,6,6,9,7,4,4,4,4,4,9,9,8,8,10,13,5,5,5,3,17,7,7,7,7,7,8,6,8,13,6,6,6,6,6,6,6,6,4,4,4,9,10,8,8,8,5,5,5,5,3,7,7,7,8,8,6,6,6,8,8,8,9,10,8,4,8,10,9,8,8,8,9,13,10,5,5,5,5,5,5,5,5,5,5,3,3,7,8,9,9,7,7,7,10,9,9,8,9,8,8,8,6,6,6,6,6,6,6,6,6,6,6,6,6,8,12,6,6,6,6,6,6,6,6,6,12,4,4,4,4,4,4,4,4,4,4,4,11,8,8,9,9,10,8,9,7,7,5,5,5,5,5,5,3,7,8,7,6,6,8,6,6,10,4,7,8,9,12,8,7,7,5,5,5,5,5,5,3,3,7,14,7,9,8,8,6,6,8,12,12,6,6,7,7,10,4,4,4,4,4,9,9,14,9,13,8,7,5,5,5,6,6,6,7,4,8,7,5,5,5,5,5,5,5,5,3,3,7,7,7,8,6,6,6,6,6,6,12,6,6,6,6,4,4,9,9,8,8,11,7,7,7,5,5,5,3,9,8,6,6,7,4,4,4,4,4,4,8,8,11,5,5,5,7,7,7,9,6,6,6,6,6,6,9,8,4,4,4,4,7,12,9,8,8,8,7,10,10,5,5,5,5,5,5,5,3,11,14,8,7,8,8,6,6,6,6,6,8,7,6,6,6,7,6,8,9,4,4,4,7,8,9,7,9,7,7,9,8,5,5,5,5,5,5,5,5,5,11,3,9,7,7,12,14,8,6,6,12,11,8,6,6,6,6,6,6,6,6,6,15,7,4,4,4,16,9,9,9,8,9,9,9,9,9,8,8,8,13,11,8,5,5,5,5,3,7,6,6,8,8,8,6,6,7,10,7,4,4,4,4,9,7,8,7,7,7,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,3,7,7,7,9,6,6,6,6,6,8,8,7,7,9,6,6,6,7,6,6,6,6,6,15,4,4,4,4,4,8,8,7,8,12,9,8,8,8,8,8,9,8,8,10,8,8,8,8,16,9,10,2,5,5,5,5,5,5,5,9,7,6,8,9,4,4,4,4,4,7,8,8,8,9,8,11,10,5,5,5,5,3,7,8,6,6,6,6,6,8,6,6,6,6,4,12,10,12,7,7,7,7,7,7,7,5,5,5,5,3,3,7,7,10,8,9,7,6,10,7,6,6,4,4,8,9,7,9,9,9,9,8,8,8,8,10,5,5,5,5,5,5,8,7,6,6,6,10,6,7,10,7,4,4,4,4,4,4,4,12,9,10,7,7,10,8,10,5,12,9,6,6,6,6,6,7,6,4,4,4,10,9,9,8,7,7,5,5,5,5,5,5,3,3,13,7,7,9,7,7,7,8,9,9,7,8,6,6,6,6,6,6,6,6,6,6,6,6,6,7,13,9,15,15,4,4,4,4,4,10,10,9,8,9,8,8,9,7,8,7,8,5,5,7,6,6,6,4,4,4,7,8,11,8,5,5,5,5,5,5,5,7,6,6,6,6,6,6,9,11,10,7,4,4,4,9,8,8,5,5,5,5,5,9,9,6,6,6,6,6,6,6,9,9,4,4,4,4,8,8,8,9,9,8,8,8,13,2,4,2,7,5,5,5,5,5,5,9,9,6,6,6,6,10,8,8,8,6,6,6,4,4,9,8,10,8,9,8,8,8,9,8,8,5,3,3,3,11,6,6,6,7,6,6,6,4,4,9,8,5,5,5,5,5,3,11,8,6,6,6,6,6,9,7,4,4,14,10,9,8,12,8,8,8,11,15,8,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,11,11,11,10,10,7,7,3,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,5,5,5,5,5,5,5,5,5,5,3,3,3,7,11,7,7,11,11,7,8,9,10,7,7,9,9,9,9,7,7,10,8,13,8,8,8,8,11,10,6,6,8,10,11,14,14,6,6,6,6,6,6,9,11,7,7,6,8,12,11,11,6,6,10,6,6,6,6,6,10,7,7,6,6,11,6,6,6,11,8,9,7,6,10,11,9,10,11,7,11,8,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,8,6,6,8,9,10,9,6,6,6,10,6,6,6,6,11,10,11,10,9,8,7,7,7,7,11,14,8,10,9,9,8,8,7,11,8,8,8,11,11,10,10,9,10,8,11,10,8,11,9,12,8,10,8,11,8,9,9,11,11,10,11,13,8,7,8,8,9,7,8,8,8,8,7,8,2,2,2,2,2,2,2,4,4,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,4,2,3,3,3,3,3,3,3,3,8,6,4,4,4,11,7,11,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,5,5,5,5,3,3,3,3,8,7,7,8,8,4,8,7,7,7,9,7,8,9,8,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,6,3,3,3,3,3,3,3,3,4,2,2,3,3,3,3,3,4,5,5,3,8,8,6,9,4,4,10,7,3,3,3,2,5,3,3,3,3,3,3,3,3,3,3,3,3,4,3,2,2,2,3,3,3,3,3,4,10,2,3,3,3,3,3,3,3,4,2,3,3,3,3,3,3,3,3,2,2,3,3,3,5,2,4,2,6,2,2,9,5,5,3,3,3,3,3,3,3,5,5,5,9,8,7,6,6,11,4,4,4,4,4,4,4,4,6,6,7,7,11,8,8,6,5,11,2,3,3,3,3,3,3,3,3,3,3,3,3,3,4,2,2,3,3,3,3,3,3,6,4,4,4,4,3,3,3,3,5,7,2,3,3,3,3,3,8,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,6,4,4,4,4,2,2,3,3,3,3,3,3,3,4,3,3,3,3,3,3,3,3,3,3,3,3,4,2,2,3,3,3,3,3,3,2,3,3,3,3,3,6,3,3,8,10,3,4,4,1,1,1,1,1,1,1,8,9,10,7,7,1,1,3,8,7,7,8,8,8,1,6,1,1,6,3,3,4,7,3,5,5,4,4,4,4,4,2,7,7,8,12,3,4,5,1,3,4,4,10,4,3,3,3,8,7,7,2,2,2,2,2,2,2,2,2,12,9,20,7,5,5,5,9,13,5,5,5,5,5,3,3,3,16,5,5,5,13,7,8,8,11,8,7,9,7,11,12,9,9,8,8,11,10,14,7,12,10,11,13,7,9,11,17,17,14,13,7,8,7,10,10,7,16,13,7,8,17,12,9,8,6,7,10,6,6,12,6,8,10,8,8,8,6,8,6,14,6,6,6,13,6,10,6,6,7,14,8,6,6,10,11,10,9,9,7,7,6,6,6,9,9,7,9,10,9,13,12,4,4,4,4,4,4,4,4,4,6,6,6,8,8,6,8,9,10,9,7,10,10,8,7,8,7,10,12,9,8,15,8,7,8,8,7,7,15,13,7,10,9,14,18,16,7,24,7,8,10,11,16,8,14,7,9,9,9,11,13,19,14,15,14,11,7,13,9,10,7,13,9,10,11,12,8,9,2,3,5,8,7,4,4,10,5,3,3,3,3,3,5,4,4,4,2,2,2,2,2,1,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,2,2,2,3,3,3,3,3,3,3,3,3,3,4,2,12,5,3,8,10,15,6,7,2,3,2,5,5,12,2,5,5,5,5,2,2,5,5,12,9,5,2,2,9,5,5,12,12,5,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,9,12,5,8,8,9,5,5,5,8,19,7,16,15,14,9,9,9,9,7,11,11,11,7,14,10,10,5,5,5,5,5,5,5,5,5,15,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,9,9,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,14,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,15,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,5,5,5,5,5,5,5,12,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,9,9,12,9,9,12,12,12,15,7,11,7,14,11,18,13,8,18,15,18,12,14,12,8,8,8,8,9,9,9,12,7,10,10,8,8,12,12,12,7,12,12,9,7,7,7,7,7,8,15,12,9,10,10,7,10,10,13,11,10,9,22,11,9,8,8,8,8,8,13,18,13,9,15,19,9,7,7,10,7,7,7,11,8,13,17,7,7,10,10,10,7,20,16,7,7,7,7,7,7,11,21,12,12,13,11,14,16,8,8,13,11,7,7,13,7,7,14,15,15,6,6,6,6,6,6,6,6,6,6,13,10,18,6,6,6,6,6,6,6,6,6,11,8,8,12,12,11,11,8,12,9,9,9,13,13,9,9,9,9,9,9,6,10,12,6,6,6,6,17,11,7,7,7,7,14,14,12,6,7,7,6,6,15,10,13,10,6,8,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,13,9,9,15,13,6,12,12,6,19,11,10,7,7,16,8,19,17,9,9,9,9,9,6,6,6,10,8,16,8,6,6,9,6,6,6,6,6,6,6,6,8,8,8,6,7,6,6,6,6,6,6,6,6,6,6,6,14,6,6,6,6,20,6,9,6,14,9,9,9,6,9,8,8,12,9,8,8,8,8,7,8,12,7,8,8,8,6,8,6,6,6,6,6,6,6,9,8,8,6,6,13,9,12,13,12,14,13,12,11,11,6,8,8,8,6,13,12,11,11,12,6,11,12,11,13,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,15,6,6,6,6,6,6,6,13,6,6,6,6,6,6,6,6,6,6,6,6,6,8,8,8,8,6,18,6,12,13,13,13,9,10,15,9,12,6,6,6,6,6,6,6,6,9,15,10,9,10,13,9,19,8,18,17,10,10,8,8,6,6,6,6,6,6,10,14,8,16,16,9,8,15,8,8,10,12,14,7,7,8,8,7,7,7,7,8,13,13,11,9,9,9,12,10,17,8,11,9,7,7,14,8,14,14,7,7,7,7,7,7,14,7,7,7,7,7,10,10,8,14,7,7,7,7,8,8,8,8,8,17,9,7,15,7,8,12,7,9,14,7,7,7,9,13,8,14,7,16,18,13,15,14,12,13,10,15,9,7,7,7,10,13,15,15,9,9,9,9,19,11,7,11,11,13,8,8,8,8,7,12,19,17,9,9,13,7,7,7,9,7,7,7,12,13,15,10,8,8,14,15,12,13,13,8,12,14,7,11,7,14,15,13,12,8,8,8,8,11,13,15,15,8,13,12,8,8,8,13,10,16,14,11,8,8,12,12,9,15,15,12,12,13,8,8,9,12,13,9,8,8,8,8,8,8,8,8,8,8,8,11,12,11,7,14,7,13,13,13,12,18,16,7,12,11,10,10,15,9,9,9,21,7,7,7,11,16,8,8,11,11,7,7,7,7,7,19,7,7,7,7,7,7,7,7,7,12,8,9,12,14,11,9,9,9,22,12,3,8,8,15,4,2,2,5,5,3,3,3,3,3,3,6,6,4,4,4,12,7,10,2,3,3,3,3,3,3,3,6,7,3,7,5,14,4,4,7,8,10,4,1,3,3,6,2,4,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,4,2,2,5,3,4,2,2,2,2,2,2,11,5,5,5,11,5,5,3,5,5,5,5,11,14,13,9,11,9,12,8,11,11,8,11,16,9,9,7,10,9,12,8,15,6,7,6,6,13,10,8,11,8,6,6,6,12,16,6,11,7,8,9,18,6,6,9,4,4,6,13,6,6,6,6,8,8,9,16,7,7,14,7,8,8,8,7,7,7,7,7,7,15,13,7,10,7,7,10,12,16,15,7,9,9,14,11,11,10,9,10,8,12,7,8,7,7,10,12,7,12,8,7,2,3,3,3,3,3,3,3,3,3,3,5,3,3,5,5,5,10,4,8,7,10,3,3,3,3,3,3,3,3,3,3,1,3,3,3,3,3,3,3,7,4,5,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,5,5,5,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,5,6,6,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,9,8,2,2,2,8,12,7,7,5,5,5,5,5,5,5,5,5,5,5,5,8,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,5,5,5,7,11,9,8,8,8,7,8,9,7,7,9,7,7,7,10,7,7,10,9,10,6,6,6,6,6,6,15,7,8,9,9,8,6,6,10,9,6,8,13,9,7,6,6,6,6,6,6,12,6,6,7,6,7,6,6,6,10,10,7,6,6,6,4,4,4,4,4,4,4,4,4,4,4,4,4,4,6,14,6,6,7,7,9,6,6,6,6,9,9,8,9,10,9,8,9,12,7,7,7,8,7,10,12,11,9,10,7,7,7,9,10,10,8,12,9,7,7,9,8,8,8,10,7,7,8,9,9,7,7,7,8,2,4,6,3,4,2,3,3,3,3,2,3,3,3,3,3,3,3,3,4,4,4,4,5,5,3,3,3,3,3,3,3,3,5,8,6,4,7,3,3,3,3,3,3,3,12,3,3,3,3,3,3,4,4,2,3,5,3,4,7,3,3,3,3,3,3,4,3,3,3,3,3,3,3,4,3,3,6,4,3,4,2,2,2,5,3,3,3,3,3,5,4,4,4,4,7,6,8,9,2,2,2,2,3,3,3,5,7,2,3,3,8,7,7,2,2,8,5,3,3,3,3,3,3,3,3,3,3,3,3,3,5,5,8,8,7,7,6,10,6,9,7,11,4,6,8,8,7,8,4,5,5,5,3,3,11,8,9,6,6,8,7,4,4,7,8,7,2,2,3,3,3,3,4,3,3,3,3,3,3,3,3,7,2,2,5,3,3,2,3,3,3,3,3,3,4,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,12,5,5,3,3,3,5,10,12,6,15,4,6,6,7,14,9,3,3,3,3,3,8,2,2,3,5,3,3,3,3,3,3,8,8,8,7,5,8,4,6,11,2,2,6,7,2,9,8,5,5,3,3,5,5,7,7,6,6,10,6,6,8,9,7,4,4,4,4,7,6,6,7,7,10,9,8,11,8,3,3,3,3,3,4,4,2,3,3,3,3,3,7,6,2,5,6,7,6,4,8,9,11,2,2,3,3,3,3,3,3,3,2,2,5,3,3,3,3,3,9,9,6,4,8,7,7,5,9,8,6,8,7,8,5,5,5,5,5,3,3,3,16,8,7,7,7,8,7,7,7,7,9,6,9,6,10,7,7,7,6,10,8,9,11,11,8,4,4,10,8,8,6,9,6,11,8,8,8,15,7,8,9,5,3,3,3,3,3,5,11,2,2,3,8,9,10,3,2,2,2,2,2,2,3,6,4,2,2,3,3,3,3,3,3,3,3,3,3,4,4,2,3,3,3,3,3,3,3,11,5,3,3,3,3,3,3,3,3,6,7,4,4,2,3,3,3,3,3,3,3,3,12,7,4,12,4,6,5,4,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,2,3,3,3,3,3,3,3,3,4,4,11,10,6,4,6,10,8,3,3,3,3,3,3,3,3,5,4,4,4,2,2,2,2,2,2,2,2,5,3,4,4,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,10,5,5,5,5,5,5,3,3,3,3,3,3,3,3,7,8,8,7,13,12,10,10,8,8,7,7,9,12,11,6,6,8,8,9,7,7,7,10,15,10,4,4,4,4,4,11,8,8,9,7,9,14,14,12,2,2,2,2,2,2,2,3,3,3,3,3,2,2,12,5,5,5,8,11,10,7,9,3,8,7,3,15,13,11,4,4,2,2,2,19,7,5,5,3,3,3,3,3,3,3,5,22,18,6,14,17,4,4,19,16,18,2,3,3,2,3,2,3,3,6,4,2,3,3,2,5,3,3,3,3,3,3,3,9,9,2,3,2,2,2,3,3,3,5,7,14,7,7,12,9,13,6,11,6,10,9,7,7,8,12,12,8,8,8,10,7,7,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,5,8,10,7,8,11,8,12,9,4,7,7,9,13,2,3,3,3,3,3,3,2,3,3,3,1,2,2,3,3,3,3,3,3,5,2,2,5,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,8,4,4,4,3,2,3,3,3,3,5,2,2,2,2,5,5,5,5,3,3,3,3,3,3,3,3,3,7,7,7,7,7,8,8,8,8,8,12,9,8,8,9,8,6,17,6,6,6,8,8,6,6,6,6,6,6,6,6,6,6,6,7,4,4,8,8,9,9,9,7,7,7,7,7,7,7,9,9,9,7,8,8,8,10,7,13,10,8,9,3,3,5,13,3,3,3,3,3,7,7,6,6,10,13,11,11,8,8,9,8,9,9,10,10,10,11,10,10,13,13,16,15,11,12,9,9,10,9,11,10,9,9,14,7,8,3,10,7,7,3,2,2,2,5,3,3,3,3,3,3,3,3,3,3,3,3,6,7,2,2,3,3,3,3,3,3,3,3,4,11,6,7,4,6,2,2,3,3,3,1,3,3,3,3,3,3,6,4,4,2,2,2,3,3,3,3,4,4,6,6,6,6,5,4,4,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,9,11,6,10,9,12,7,7,11,14,9,7,12,3,3,7,12,11,12,7,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,9,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,3,3,3,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,11,5,5,5,5,5,5,5,5,11,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,5,5,5,5,5,5,5,3,3,3,5,5,5,5,5,5,5,5,5,5,5,3,3,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,5,5,5,5,5,5,5,5,5,5,5,5,5,3,10,3,3,3,11,3,5,9,11,8,12,14,9,7,8,7,7,11,11,7,7,10,9,8,10,9,7,7,7,7,7,7,8,8,7,11,8,8,8,7,7,10,8,7,13,12,7,17,10,8,8,11,7,11,11,14,7,11,7,8,6,9,20,8,7,9,16,7,10,6,11,10,8,9,7,16,11,11,9,8,9,8,8,8,11,8,15,8,8,9,7,8,8,11,10,7,5,7,10,10,15,7,7,7,8,7,8,8,10,11,10,10,10,11,11,7,8,6,8,8,8,10,6,8,6,6,7,8,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,16,6,15,6,7,11,11,7,9,10,11,13,10,6,16,8,10,12,11,6,6,6,6,6,6,6,10,6,10,7,7,7,7,11,7,11,6,6,6,6,6,6,17,7,7,6,6,12,22,6,6,6,6,6,8,6,6,6,6,7,6,6,5,6,6,8,11,6,9,14,11,9,11,7,7,8,6,6,6,8,10,9,6,6,6,6,9,7,6,6,6,6,6,15,6,4,4,4,6,4,17,8,11,6,6,9,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,6,6,6,6,10,6,10,6,6,6,6,12,8,6,6,6,6,6,6,6,6,6,9,6,6,6,6,18,6,6,6,8,9,10,7,8,9,10,11,7,13,6,8,8,6,6,14,7,7,7,7,10,7,14,9,6,6,9,15,9,7,14,6,11,14,13,7,12,8,7,7,7,7,7,12,7,10,9,16,6,8,6,5,17,6,8,10,4,6,4,10,15,17,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,8,4,4,11,7,4,4,7,7,7,6,6,6,6,6,6,6,6,6,6,6,6,19,17,6,10,11,6,6,6,6,18,6,6,11,4,4,4,5,6,6,6,9,5,6,4,6,6,4,6,6,6,6,10,6,6,4,6,6,10,6,10,6,6,6,6,11,6,6,10,6,6,8,6,6,6,8,6,11,4,11,9,10,9,11,4,8,4,11,12,7,9,8,6,7,7,8,12,12,11,13,10,11,7,7,7,9,7,11,10,7,7,7,16,11,10,11,17,9,9,8,8,7,7,7,9,7,7,7,14,7,13,9,11,10,14,10,10,12,11,10,7,10,5,14,8,8,8,9,7,8,7,7,9,8,7,8,7,7,7,7,7,7,7,11,8,10,8,7,8,14,11,8,9,9,9,8,24,10,10,12,7,7,15,11,8,8,12,11,8,9,9,7,8,9,10,11,10,11,7,12,7,7,11,9,8,14,13,12,8,11,10,8,8,7,7,14,9,10,8,9,11,7,14,8,8,13,8,8,12,7,10,14,14,11,9,10,9,9,7,7,11,11,13,9,13,5,5,5,7,9,5,11,12,14,8,7,7,11,10,9,7,8,8,7,10,11,11,5,5,7,5,5,5,7,7,15,7,7,8,7,15,12,12,10,7,8,7,11,7,7,7,23,11,8,8,11,10,7,8,11,7,19,7,7,6,9,9,9,11,3,4,7,8,6,6,4,10,8,2,2]),$x=new Uint16Array([0,0,0,1,0,0,0,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,1,1,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,12,1,1,1,1,1,17,1,1,1,12,1,12,1,12,13,1,1,1,1,12,1,12,1,1,1,1,1,14,21,1,1,1,1,1,1,1,19,12,1,1,1,1,1,1,1,20,1,1,1,16,1,18,1,1,15,1,1,1,1,12,1,1,1,1,1,1,22,1,1,1,12,1,1,1,1,1,1,1,1,1,12,12,12,12,12,12,12,12,12,12,12,12,1,24,25,26,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,1,1,12,12,12,12,1,32,0,0,0,1,1,1,1,35,34,1,1,1,1,1,33,1,1,1,1,37,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,38,0,0,0,0,39,40,0,0,0,41,0,12,1,1,12,1,1,1,1,44,45,45,45,44,45,44,44,46,45,44,45,44,44,44,44,44,44,46,44,44,44,44,44,44,45,47,47,45,44,44,44,44,44,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,50,52,50,50,50,52,50,51,50,53,50,51,51,50,50,50,51,53,51,53,50,51,51,12,55,55,54,56,51,53,50,50,48,49,57,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,60,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,1,1,67,1,12,1,1,66,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,78,0,0,0,0,0,0,0,0,0,0,0,0,0,76,79,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,77,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,1,1,1,1,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,1,0,1,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,1,12,1,1,1,1,89,1,91,1,1,1,1,1,1,1,1,94,1,1,1,1,1,1,1,1,1,1,1,1,0,1,97,97,1,1,12,1,100,1,1,1,1,1,1,1,98,1,99,1,101,1,1,1,1,1,102,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,110,111,1,1,1,1,1,1,113,113,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,121,122,1,1,1,1,1,1,1,1,1,1,1,1,1,122,1,1,1,1,1,1,1,1,1,1,122,1,1,1,1,1,1,1,1,1,126,123,125,120,1,124,1,1,114,1,1,1,1,117,1,127,1,1,1,1,1,119,1,108,1,109,1,12,128,106,1,112,1,1,1,1,1,107,115,1,12,12,12,118,116,1,1,1,1,1,1,0,0,0,0,1,12,12,1,1,1,1,1,12,134,1,1,1,1,1,1,1,1,1,1,1,12,136,1,1,1,1,1,1,1,1,137,138,12,12,135,133,45,45,140,50,50,139,142,141,1,1,0,0,0,0,0,0,0,0,0,0,0,0,145,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,143,0,0,0,0,1,0,144,132,1,0,1,12,12,1,1,1,1,1,0,0,0,0,0,0,0,1,148,147,20,1,1,12,12,1,20,12,12,1,1,1,1,1,134,1,1,152,1,1,1,1,153,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,1,1,136,1,1,152,1,1,1,1,153,1,1,134,1,1,1,152,1,1,1,1,153,1,1,134,1,1,1,1,1,1,1,1,134,1,1,1,1,1,1,1,1,1,1,1,160,1,1,1,152,1,1,1,1,1,153,1,1,160,1,1,1,1,1,1,1,1,1,1,134,1,1,1,1,152,1,1,1,1,153,1,1,1,134,1,1,152,1,1,1,1,164,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,1,167,1,1,160,1,1,1,1,1,152,1,1,1,1,1,153,1,1,160,1,1,1,1,1,152,1,1,1,1,1,153,1,154,158,158,12,1,12,166,1,1,1,1,1,158,158,158,154,1,1,1,157,158,161,165,1,1,1,1,157,157,1,1,156,154,154,157,170,156,170,1,1,168,1,156,155,157,1,1,1,1,157,1,159,1,1,1,12,1,162,1,162,1,1,1,162,161,163,169,156,154,1,1,1,1,1,1,172,172,172,172,172,172,172,172,172,172,172,172,172,172,172,172,172,172,172,173,172,173,172,172,172,172,174,174,172,173,172,173,172,172,12,12,12,12,12,1,12,12,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,193,1,1,1,1,12,199,200,201,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,151,1,1,1,1,1,1,1,1,1,1,1,196,1,1,1,184,1,210,1,1,1,208,1,1,205,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,12,1,1,1,1,1,12,1,1,1,1,1,1,1,1,190,1,1,1,186,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,182,1,1,1,1,1,1,1,191,1,1,1,1,195,1,1,1,1,171,1,1,189,1,1,1,192,1,1,1,12,1,1,1,1,1,1,1,1,1,1,1,1,180,1,12,1,1,12,1,1,1,1,183,1,1,1,188,1,203,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,12,1,1,209,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,194,1,1,1,1,1,12,1,1,1,1,1,1,1,1,176,12,1,1,1,178,12,1,1,1,1,1,1,1,198,1,1,1,1,1,1,1,1,1,1,177,1,1,1,1,1,1,204,1,1,1,181,1,1,1,187,1,12,1,1,12,1,1,1,1,1,1,1,1,1,1,191,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,175,1,1,1,1,1,1,1,1,1,1,185,1,1,1,1,1,1,1,1,1,1,1,206,1,1,1,1,1,1,1,1,1,1,1,1,1,207,1,1,12,1,1,1,1,179,1,1,1,185,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,12,1,1,1,197,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,12,12,1,1,1,1,1,1,1,1,1,202,1,1,12,1,1,1,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,1,0,1,1,1,1,1,1,1,1,1,1,220,0,0,0,0,0,221,0,0,0,0,0,0,1,12,1,1,1,225,1,1,1,0,226,223,224,1,1,1,1,1,1,231,1,233,1,1,1,1,1,1,1,1,1,1,1,229,1,1,1,1,1,235,1,1,12,1,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,234,1,1,1,12,1,1,1,1,230,1,1,1,228,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,232,1,1,1,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,12,1,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,241,13,1,1,1,12,12,238,239,1,1,1,1,240,1,1,12,1,1,1,1,1,1,1,242,1,1,12,16,1,1,1,1,1,1,1,243,1,1,1,12,12,1,1,1,1,1,243,12,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,1,252,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,256,256,1,0,0,0,0,0,1,12,0,0,0,0,0,0,0,0,172,261,262,1,12,1,1,1,1,12,264,1,1,263,1,1,266,1,1,1,1,1,1,1,1,1,0,1,1,1,271,272,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,12,1,0,1,0,0,0,0,1,0,1,0,1,1,1,1,1,0,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,1,1,12,0,283,0,0,284,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,1,1,12,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,60,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,1,1,1,0,308,0,0,0,0,0,0,0,0,0,310,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,12,1,1,1,1,1,1,1,1,1,12,1,1,1,1,1,327,327,328,327,0,185,1,1,13,323,1,321,0,0,0,0,1,0,0,0,324,1,1,329,1,205,1,1,1,1,1,322,1,319,1,325,1,317,1,326,1,318,1,1,1,1,1,1,1,12,1,1,1,12,1,12,320,320,1,1,1,316,184,1,1,12,1,1,1,1,1,1,1,1,1,1,12,1,1,1,1,12,1,1,1,1,315,1,0,0,0,1,0,0,0,0,0,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,332,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,266,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,372,372,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,364,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,0,1,340,351,1,1,339,374,1,345,1,1,337,369,1,1,355,336,341,1,1,1,348,379,357,1,1,1,1,1,1,358,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,0,367,371,0,0,79,1,1,0,365,342,378,343,346,353,1,368,0,1,0,79,362,360,1,0,0,1,1,1,0,0,0,0,381,1,1,352,1,79,1,0,1,1,1,384,1,0,0,79,359,0,1,338,1,1,1,0,1,1,361,1,0,1,1,1,0,1,386,349,1,1,0,1,0,0,377,0,1,1,1,79,370,1,1,366,363,1,1,1,1,1,1,1,1,1,1,1,344,1,1,1,1,1,1,1,1,1,1,1,376,0,79,1,1,1,1,0,1,1,1,1,1,1,0,0,1,1,380,1,1,1,0,0,383,0,0,0,1,356,1,0,79,382,1,0,0,0,0,385,1,1,0,0,1,0,1,0,354,0,350,0,1,1,1,0,1,1,0,373,347,375,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,0,0,0,1,0,0,1,0,0,0,0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,1,0,0,1,0,0,0,0,0,1,1,1,400,400,1,1,12,12,1,400,1,1,12,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,1,1,1,1,1,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,412,1,1,0,1,1,1,1,205,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,1,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,430,430,1,1,0,0,317,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,442,1,441,1,1,1,1,1,1,1,1,445,1,12,12,1,1,1,1,1,12,1,1,1,1,453,1,1,1,455,1,1,1,1,1,1,1,1,1,1,452,1,447,1,1,1,1,435,1,1,1,1,1,1,1,1,448,12,1,1,1,1,454,1,1,1,449,444,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,317,1,433,1,1,12,451,1,1,317,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,437,1,1,1,1,1,1,1,1,1,1,1,454,1,1,1,1,317,1,450,1,1,1,439,1,1,1,1,1,440,1,456,443,1,1,1,1,1,438,1,1,1,1,1,1,1,1,1,434,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,446,1,1,1,1,1,1,1,12,1,1,1,1,1,436,1,1,1,1,1,1,1,220,457,1,1,1,1,1,12,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,0,1,0,0,1,0,1,0,1,1,0,0,0,462,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,12,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,466,0,466,466,466,466,466,466,466,0,466,466,466,466,466,1,466,466,466,0,466,466,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,471,470,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,475,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,468,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,469,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,477,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,466,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,474,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,467,0,0,478,473,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,472,0,0,0,0,0,0,0,0,0,0,0,0,0,466,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,467,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,466,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,476,0,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,1,12,1,1,1,1,1,1,1,1,1,1,1,1,488,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,198,198,1,492,1,1,1,491,1,1,1,1,487,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,489,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,493,1,1,490,1,1,1,1,1,1,1,1,372,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,494,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,1,0,0,0,0,1,0,1,0,0,0,0,0,0,0,1,0,0,0,505,0,0,0,0,0,0,0,0,0,1,1,1,1,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,1,1,0,0,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,1,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,1,0,1,0,0,0,1,0,0,0,1,0,0,0,0,1,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,1,0,0,0,0,0,0,1,0,1,0,0,12,1,507,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,1,1,0,0,1,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,12,12,1,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,1,1,0,1,0,0,0,0,0,0,0,1,0,0,1,0,1,1,1,1,0,0,0,1,0,0,0,1,60,1,1,12,12,12,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,526,1,1,1,1,1,1,1,527,1,1,1,1,1,1,1,525,1,1,12,1,529,239,1,1,12,12,1,1,12,1,12,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,533,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,1,1,0,0,0,1,0,0,0,1,0,0,0,0,0,1,1,1,1,1,0,0,0,0,0,1,1,1,539,1,1,1,1,1,1,1,1,1,1,1,1,1,1,132,1,12,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,107,1,1,12,1,1,1,12,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,548,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,12,0,0,0,0,0,0,0,0,0,1,1,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,1,1,0,0,0,1,1,1,1,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,0,0,0,144,1,1,1,228,1,1,12,30,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,0,0,1,572,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,577,1,220,1,328,1,1,1,1,1,1,1,1,1,0,0,578,1,1,1,1,0,580,0,79,0,579,0,1,1,1,0,1,1,1,1,1,1,12,0,0,0,0,1,0,0,0,0,0,0,586,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,1,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,582,582,0,585,583,582,582,582,582,582,587,582,582,591,582,582,582,582,582,582,582,582,582,582,588,585,582,582,585,582,582,582,582,582,582,582,582,582,582,582,582,582,583,582,582,582,582,582,589,582,582,582,582,582,582,0,0,0,1,590,1,1,1,1,584,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,1,12,595,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,0,0,0,0,0,1,12,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,12,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,12,1,1,12,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,96,65,280,306,411,535,0,4,68,236,254,282,307,334,388,413,0,499,519,536,597,9,0,61,88,398,409,429,575,0,497,518,532,612,0,30,6,0,461,500,602,560,70,0,7,285,255,389,463,416,538,79,598,0,576,309,418,465,9,105,288,506,6,30,0,311,79,391,79,483,10,6,131,248,275,0,613,509,0,563,0,64,6,6,251,95,2,432,399,410,596,0,6,0,6,286,103,6,561,501,540,0,464,390,273,287,8,71,104,599,543,392,312,300,419,146,74,290,546,510,601,564,335,330,479,6,75,149,11,0,249,522,547,565,514,551,570,611,36,6,260,295,333,304,218,30,528,553,218,42,216,265,296,305,406,423,481,274,0,73,562,0,403,417,299,79,247,79,0,581,545,504,292,421,79,393,387,0,0,0,9,555,571,217,0,424,407,531,516,573,615,85,218,43,297,396,425,569,0,511,293,276,79,215,80,28,390,30,6,394,331,303,604,592,524,550,513,0,258,81,30,405,422,0,30,426,0,219,593,517,9,408,427,218,248,86,222,594,574,557,482,428,397,250,227,87,59,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,620,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,414,0,0,0,0,0,0,0,0,82,0,129,0,0,84,549,0,0,0,0,0,0,0,27,0,552,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,414,0,0,0,0,503,0,257,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,294,0,0,0,0,0,0,0,617,0,0,0,0,0,616,0,0,0,0,0,0,0,0,0,0,0,0,0,0,395,0,0,0,484,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,69,0,0,0,0,0,0,495,0,0,0,0,0,0,404,0,0,0,0,0,0,0,0,0,0,0,0,0,211,0,0,0,0,0,0,0,0,0,0,515,0,0,0,0,0,0,0,0,0,0,0,0,496,0,0,0,0,0,0,0,0,0,0,0,0,0,0,269,281,0,0,0,0,0,530,277,0,0,0,0,0,0,0,0,0,0,0,0,0,512,0,0,0,0,0,0,0,0,0,0,0,458,0,0,0,314,0,0,0,0,0,0,253,0,0,0,0,0,0,23,0,0,0,0,568,0,0,0,0,600,521,0,0,0,0,244,0,0,0,0,0,0,0,0,0,480,0,0,0,0,0,62,0,0,0,267,58,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,246,0,0,0,0,0,279,610,0,72,0,0,0,0,0,0,0,0,0,619,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,150,0,278,0,0,0,0,0,0,567,0,0,0,0,0,0,523,0,0,0,0,0,0,0,0,0,566,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,213,0,0,0,0,0,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,84,0,502,0,0,0,0,0,554,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,84,83,0,0,0,0,0,0,0,0,0,0,0,0,486,0,485,0,0,0,0,0,0,0,0,0,0,259,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,459,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,289,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,537,0,0,0,0,0,0,0,0,298,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,69,237,0,0,0,0,0,0,0,0,0,0,84,0,606,0,0,0,0,0,0,0,0,0,0,0,0,245,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,609,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,520,0,0,0,84,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,498,0,614,0,0,431,0,0,0,0,0,0,0,0,0,0,0,0,402,0,0,0,544,0,93,0,0,0,0,0,0,0,0,0,0,31,0,0,0,0,0,0,29,92,0,0,0,0,0,0,0,0,0,0,0,0,291,0,0,0,214,0,0,0,0,0,0,558,0,270,0,0,130,0,0,0,0,0,559,0,0,0,0,0,0,0,414,420,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,313,0,0,0,0,0,5,0,0,0,0,0,0,0,301,0,0,0,0,0,0,0,0,0,0,0,0,0,534,0,0,0,415,0,0,401,0,0,0,0,0,0,603,0,0,0,541,0,0,90,0,542,0,0,0,0,0,0,0,0,0,0,508,460,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,268,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,414,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,608,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,607,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,618,0,0,0,0,0,556,0,0,0,0,0,0,0,0,0,0,302,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,605,0,0,212,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,623,623,623,623,623,623,623,622,624]),$f="orgmilcomschnetedugovdrrformsfeedbackofficialaccoorgmilschnetgovmagazinemediaunioncargopilotgroupcaarespressworksaerodromeworkinggroupair-traffic-controlaircraftaccident-preventioneducatormarketplaceambulanceinsurancecateringairportrepbodyenginesoftwaremodellingair-surveillanceconsultingchartertrainermaintenanceservicesdesignflightskydivingfreightassociationstudentgroundhandlingdgcafuelclubtaxicrewshowballooningexpresstraderbrokerauthoragentsairtrafficjournalistsafetyconsultantmicrolightaccident-investigationparachutingequipmentproductionfederationrecreationscientistnavigationengineertradingglidingleasingresearchpassenger-associationentertainmentparaglidinghangglidingaerobaticrotorcraftemergencycertificationgovernmentaeroclubexchangelogisticschampionshiphomebuiltcouncilconferencecontrolairlinecivilaviationjournalorgcomnetedugovcoorgcomnomnetobjofforgcomnetuwukiloappsframerorgmilcomnetedugovcoradioorgcomnetcommuneedogpbcoitgvorgedugov*spreviewfrontendrelayononstagingupid*mtls*privatelinktypedreamdeveloperbravemochawindsurfaivenmirenupsunwnextbegetngrokclerkwale2bwebcsbrunputerflutterflowspawnbaseshiptodaymagicpatternsnetlifyondigitaloceanrailwayhostedclaudehasurabotdashvercelgithubluyanigadgetreplitcloudflaretelebitedgecomputeevervaultdetaexponyatnoopencrpplxzeaburwasmerframerzeropsconvexmedusajsspritesonherculeseasypanelstreamlitsnowflakemesserliloginlinehackclubnorthflankbase44corespeedadaptableleapcellngrok-freeclerkstagelovableon-fleek*us-west-3ap-south-2us-central-2us-central-1eu-central-1ap-south-1us-west-2us-east-2eu-north-1ap-north-1us-west-1us-east-1*rcloudintsegorgmilcomgobbetnetintedugovturmusicasenasamutualcoopip6uriurnin-addre164homeirisgovdixdaemoncloudnssthwien*inexexkunden4accogvormymyspreadshop4lima2ixortsinfofuturecmsfuturehosting12hpprivfuturemailinglima-cityfunkfeuer123webseitednshomemelmyspreadshopcloudletswasantqldvicactnswtascatholicwasaqldvictasvpsidwasantozqldorgcomvicasnactnetedugovnswtasconfhrsncomairflowlambda-urltransfer-webappairflowtransfer-webapptransfer-webapptransfer-webapp-fipstransfer-webappeu-west-3ap-south-2eu-south-2eu-central-2ap-southeast-3ap-southeast-4ap-northeast-3eu-central-1mx-central-1me-central-1ca-central-1il-central-1ap-northeast-1ap-southeast-1me-south-1af-south-1eu-south-1ap-south-1ap-southeast-7us-west-2eu-west-2us-east-2eu-north-1ap-southeast-2ap-northeast-2ap-southeast-5us-gov-west-1us-gov-east-1ca-west-1us-west-1eu-west-1us-east-1ap-east-1sa-east-1privatenotebookstudiolabelingnotebookstudionotebooknotebook-fipslabelingnotebookstudionotebook-fipsnotebookstudio-fipsnotebook-fipsnotebookstudionotebook-fipsnotebookstudioeu-west-3ap-south-2eu-south-2eu-central-2ap-southeast-3ap-southeast-4ap-northeast-3eu-central-1me-central-1ca-central-1il-central-1ap-northeast-1ap-southeast-1me-south-1af-south-1eu-south-1ap-south-1us-west-2eu-west-2us-east-2eu-north-1ap-southeast-2ap-northeast-2experimentsus-gov-west-1us-gov-east-1ca-west-1us-west-1eu-west-1us-east-1ap-east-1sa-east-1onrepostsagemakercopporgmilcompronetintedugovbiznameinfoshoprsorgmilcomnetedugovbrendlyresolvenzauscotvstoreorgcomnetedugovbizinfoidacaicoittvorgmilcomschnetedugovinfocloudezproxyacmymyspreadshopkuleuvenwebhostingtransurl123websitecloudnsinterhostsolutionsddns5476103298edgfacbmlonihkjutwvqpsryxzbarsycoororgcomedumyftpno-iporxcloud-ipfor-somemmafanfor-morewebhopselfipjozidyndnscloudnsdscloudfor-thefor-betteractivetrailcoeconorestooteorgcomeconeteduassurmoneyafricaarchitectesrestaurantloisirstourismavocatsinfoagrounivcoorgcomnetedugovtvdeportesaludtksatorgmilcomwebgobnetinteducienciaboliviarevistacooperativaempresanombreindustriamusicapatriamedicinademocraciapoliticapuebloindigenaplurinacionalarteblogwikiinfoagrotransportenoticiasprofesionalacademiaeconomiaecologiamovimientotecnologianaturalsimplesitecepesebamapadfmgalampbacscpirngorotomtrjspaprrprrsesmscepesebamapadfmgalampbacscpirngorotomtrjspaprrprrsesms*biaamfmtcmptvfeirasampajampanatalbelemananiradiog12medindfndbmdtrdthepoaggfjdfdefinfenflegsegongengcngorgzlgslglogppgmillelqslcimcomnomadmjabimbbibbsbabcrectecsjcetcpscpvhudieticriapipsiecnbiorioecogeoteoodoproatoartfstmatvetdetbetnetcntnotfotgrueduajuespappreptmpemparqsrvadvdevgovntrturagrjorfarjusmusdesvixxyzcozfozslzbhzmaringasantamariacampinagrandegoianiasorocabafloripasaobernardocuritibaboavistarecifeaparecidasaogoncasalvadorcuiabamorenamacapalondrinacontagemsocialfortalmaceioleilaoosascoriobranconiteroi9guacutcheblogflogvlogwikitaxicoopmanauspalmascaxiasjoinvillebaruericampinassantoandreribeiraoriopretoweorgcomnetedugovv0windsurfshiptodaycloudsitecoaccoorgnetgovofmilcomgovmediatechzacoorgcomnetedugsjgovmydnspenfnlabnbmbgcbcqconcontnuyksknsmyspreadshopno-ipawdevboxbarsyonidatemfuinabusavinstanceseceuguukussryzespawncsxcloud-ipmyphotosfantasyleaguetwmailcleverappsscrappingccwucloudnsftpaccessgame-serverccgovobjectsrmalpgcust*svcalp1aeappenginermalpgmyspreadshop4lima2ixsquare7cloudscale123websitefirenet12hpflowgotdnslinkyard-cloudcloudnslima-citydnskingobjectstorageedaccogoorusorgcomnetinteduaéroportxn--aroport-byaassogouvcomilgobgovcloudnses-1eu-west-1us-east-1euvipit1eurarubait1s3lbwebsites3websiteru-spbru-mskelasticcsrunstnukukcaukusnl-ams-1fr-par-1fr-par-2functionsnodess3ddlwhmrdbfnck8sifrs3-websitecockpitscblmgdbdtwhkafkpubprivs3ddlwhmrdbk8sifrs3-websitecockpitscblmgdbdtwhkafks3ddlrdbk8sifrs3-websitecockpitscblmgdbdtwhkafkk8sscalebookpl-wawfr-parnl-amsbaremetalsmartlabelinginstancesdechk2kuleuvenlaravelvoorloperurownoxazapscwhstgrvaporobservablehqelementorantagonistreclaimjoteluluencowaydiademjelasticmatlabmagentositetrendhostingaxarnetperspectajenv-arubajelejoteravendbemergenttrafficplexconvexkeliwebserveboltbegetcdnstaticson-rancherprimetelonstackitunison-servicesdnshomelinkyardbarsyjelecloudnscocomnetgovmycn-northwest-1cn-north-1s3s3-accesspoints3-websites3s3-accesspointrdsdualstacks3-deprecatedemrappui-prods3-websiteemrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apis3s3-accesspoints3s3-accesspointrdsdualstackemrappui-prods3-websiteemrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicn-northwest-1cn-north-1cn-northwest-1ebcomputeelbcn-north-1airflowcn-northwest-1cn-north-1oncn-northwest-1cn-north-1amazonawssagemakeramazonwebservicesdirectasgdsdhehahljlnmhbacscahqhshhihnlnynsnmofjbjzjxjtjhkcqtwgsjssxnxjxgxxzgz網絡网络公司orgmilcomnetedugovxn--55qx5dcanva-appsxn--io0a7iquickconnectcanvasitekhsjxn--od0algmyqnapcloudsrvrlessclustersrealtimestorageleadpagescarrdcrdorgmilcomnomnetedugovhidnssupabaserdpareplmypiumsoxmitotaplpagesfirewalledreplitowodevwebview-assetsvfswebview-assetss3s3-accesspointdualstackemrappui-prods3-websiteaws-cloud9emrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicloud9eu-west-3ap-south-2eu-south-2eu-central-2ap-southeast-3ap-southeast-4ap-northeast-3eu-central-1me-central-1ca-central-1il-central-1ap-northeast-1ap-southeast-1me-south-1af-south-1eu-south-1ap-south-1ap-southeast-7us-west-2eu-west-2us-east-2eu-north-1ap-southeast-2ap-northeast-2ap-southeast-5ca-west-1us-west-1eu-west-1us-east-1ap-east-1sa-east-1s3s3-accesspointdualstackemrappui-prods3-websiteaws-cloud9emrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicloud9s3s3-accesspointdualstackanalytics-gatewayemrappui-prods3-websiteaws-cloud9emrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicloud9s3s3-accesspointdualstackemrappui-prods3-websiteemrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apis3s3-accesspointdualstacks3-deprecateds3-websites3-object-lambdaexecute-apis3s3-accesspoints3-websites3-accesspoint-fipss3-fipss3s3-accesspointdualstackemrappui-prods3-websites3-accesspoint-fipsaws-cloud9s3-fipsemrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicloud9s3s3-accesspointdualstackemrappui-prods3-websites3-accesspoint-fipss3-fipsemrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apis3s3-accesspointdualstacks3-deprecatedanalytics-gatewayemrappui-prods3-websiteaws-cloud9emrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicloud9vfss3s3-accesspointdualstackemrappui-prods3-websiteaws-cloud9emrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicloud9eu-west-3ap-south-2eu-central-2ap-southeast-3ap-southeast-4ap-northeast-3eu-central-1mx-central-1me-central-1ca-central-1il-central-1ap-northeast-1us-northeast-1ap-southeast-1me-south-1af-south-1ap-south-1ap-southeast-7us-west-2eu-west-2ap-east-2us-east-2ap-southeast-2ap-northeast-2ap-southeast-5us-gov-west-1us-gov-east-1ap-southeast-6ca-west-1us-west-1eu-west-1us-east-1ap-east-1sa-east-1mrapaccesspoints3s3-accesspointdualstacks3-deprecatedanalytics-gatewayemrappui-prods3-websites3-accesspoint-fipsaws-cloud9s3-fipsemrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicloud9s3s3-accesspointdualstacks3-deprecatedanalytics-gatewayemrappui-prods3-websites3-accesspoint-fipsaws-cloud9s3-fipsemrstudio-prods3-object-lambdaemrnotebooks-prodexecute-apicloud9s3eu-west-3ap-south-2eu-south-2computes3-ap-northeast-2elbrdss3-ap-east-1s3-sa-east-1s3-us-gov-west-1s3-eu-central-1s3-ca-central-1eu-central-2ap-southeast-3ap-southeast-4ap-northeast-3s3-website-us-west-2s3-website-eu-west-1s3-external-1eu-central-1me-central-1ca-central-1il-central-1s3-us-west-1s3-eu-west-1s3-website-sa-east-1s3-website-ap-southeast-2ap-northeast-1ap-southeast-1s3-us-west-2s3-eu-west-2me-south-1af-south-1eu-south-1ap-south-1us-west-2eu-west-2us-east-2s3-website-ap-southeast-1s3-1s3-globals3-ap-northeast-3eu-north-1airflowap-southeast-2s3-us-gov-east-1s3-fips-us-gov-east-1s3-me-south-1s3-ap-south-1ap-northeast-2s3-website-us-west-1ap-southeast-5s3-eu-north-1s3-ap-southeast-1s3-website-us-gov-west-1compute-1s3-eu-west-3us-gov-west-1s3-website-ap-northeast-1us-gov-east-1s3-fips-us-gov-west-1s3-website-us-east-1s3-ap-southeast-2ca-west-1us-west-1eu-west-1us-east-1ap-east-1sa-east-1s3-us-east-2s3-ap-northeast-1authauthauth-fipsauth-fipseu-west-3ap-south-2eu-south-2eu-central-2ap-southeast-3ap-southeast-4ap-northeast-3eu-central-1mx-central-1me-central-1ca-central-1il-central-1ap-northeast-1ap-southeast-1me-south-1af-south-1eu-south-1ap-south-1ap-southeast-7us-west-2eu-west-2us-east-2eu-north-1ap-southeast-2ap-northeast-2ap-southeast-5us-gov-west-1us-gov-east-1ca-west-1us-west-1eu-west-1us-east-1ap-east-1sa-east-1rservicesbuilderstg-builderdev-builder*ociocpocsdemoinstanceeu-west-3eu-south-2ap-southeast-3ap-northeast-3eu-central-1me-central-1ca-central-1il-central-1ap-northeast-1ap-southeast-1me-south-1af-south-1eu-south-1ap-south-1ap-southeast-7us-west-2eu-west-2us-east-2eu-north-1ap-southeast-2ap-northeast-2ap-southeast-5us-gov-west-1us-gov-east-1us-west-1eu-west-1us-east-1ap-east-1sa-east-1previeweu-4us-4us-1eu-1us-2eu-2us-3eu-3appspaasrag-cloudrag-cloud-chjcloudjcloud-ver-jpcdemonodebalancermembersipeuxvsoncillaocelotonzayalilynxsphinxfentigercustomercaracalo365cloudstaticxendevapp001testcode-builder-stgplatformapimediasiteprojedrydpagesjsu2u2-localx0desazacncoitrueu4uhkukgrbrushatenadiarymyspreadshopfrom-flfrom-wvwebspace-hosttheworkpchatenablogservesarcasmapplinzisakuratanwixsiteappchizigiizeis-into-carsdnsiskinkyadobeaemcloudis-a-therapistpgfogmyvncdojinis-an-actress1kappfldrvkozowqa2jpnmexprgmrfirewall-gatewaydynnscafjsfbsbxooguyxnbayfrom-gawoltlab-demois-a-anarchistwiardwebteaches-yogadattowebtb-hostinglive-websiteservegamegotpantheonfrom-nhsubsc-payfrom-ohvipsinaappfrom-cadyndns-officehomelinuxfrom-mahercules-appservebbsstreakusercontentfrom-okfrom-wyfastly-terrariumis-a-llamaqualyhqportalserveexchangeon-vaporvivenushopciscofreakgrayjayleaguesmetaaiusercontentfrom-iais-a-libertariansaves-the-whalestaveusercontentyolasiteoperaunitepoint2thisis-a-catererlinodeusercontentfrom-vagithubusercontentsells-for-lesshosteurcanva-appsplaystation-cloudddnsfreefrom-pafrom-prfrom-waddnskingoutsystemscloudhotelwithflightmydattois-a-nascarfanmydbserverminiserverdamnserverservehumouris-a-playerfrom-nvfrom-nmemergentagentgentappsamplifyappfrom-kyis-an-accountantnfshostserveircfrom-akpythonanywherestackhero-networkpostman-echolikescandydyndns-mailobservableusercontentserveftpfreeboxosfrom-utcdn77-storageamazonawsneat-urldyndns-serverlinodeis-a-teacherfrom-vtgleezemythic-beastsus1-pleniteu1-plenitla1-plenitpaywhirlservecounterstrikejdevcloudhealth-carereformis-into-animegoogleapisis-a-painterafricaisa-hockeynutatmetais-an-actora2hostedis-a-democratdatadetectest-le-patrondigitaloceanspacesis-a-designeris-a-hunterlinodeobjectstemp-dnsissmarterthanyoufrom-arsimplesiteevennodetownnews-stagingis-a-liberalgooglecodejelasticservemp3stdlibqualyhqpartnerdyndns-free1cooldnsest-a-la-masiondrayddnsdynuddnsfrom-orfrom-miis-a-bloggerfrom-himydobisscanvacodeis-an-engineerest-a-la-maisonupsunappdevinappswafflecellmyasustorwpenginepoweredfrom-ctservep2psame-appmyshopblocksthingdustdatalikes-piediscordsezis-with-thebanddev-myqnapcloudlpusercontentis-leetshopitsite3utilitiesis-a-personaltrainersinaappladeskis-a-cheflogoipselfipbase44-sandboxnospamproxyalibabacloudcsmesswithdnsauthgearappsiamallamawithgooglelutrausercontentmochausercontentframercanvasmytabitdyndns-homew-credentialless-staticblitzcpserverdiscordsaysis-a-nurseappspotatlassian-isolated-3premotewdfrom-mtwixstudiocode0emm180rmyactivedirectoryawsappsmytuleapdnsabrpolyspaceqbuserrenderbuiltwithdarkboutirgotdnsabrdnsdopaascanva-hosted-embedawsglobalacceleratorhomesecuritypcmyiphostditchyouripclever-clouddyndns-ipon-aptibleis-a-musiciansecuritytacticsappspaceusercontenthomeunixstrapiappsame-previewcf-ipfsmycloudnaselasticbeanstalkis-certifieddontexistkasserverik-serverdrive-platformatlassian-3pfirebaseappherokuappawsapprunnerbarsycenteris-a-cubicle-slaveservehttpmyshopifyis-a-guruquicksytessiiitesorsitesmagicpatternsappis-a-cpameteorappfrom-wiis-a-rockstarbumbleshrimpdattolocalreadthedocs-hostedfrom-rifamilydsdyndns-picsplesknsbplaceddnsaliasdynaliasdyndns-remotedoomdnsip-ddnsblogdnsis-a-doctorroutingthecloudamazoncognitobarsyonlinedsmynasddnsgurucloudflare-ipfsdeus-canvasfrom-idsmushcdnpagespeedmobilizerdyndns-at-homeunusualpersonhosted-by-previderis-a-republicandyn-o-saurstreamlitappworkisboringonthewificprapidqualifioappis-uberleetis-slickgetmyipwpdevcloudtypeformdyndns-at-workgentlentapismynascloudw-corp-staticblitzfrom-ingeekgalaxyservebeerfrom-mdonrenderspace-to-rentaivencloudappspacehostedonfabricawafaicloudcodespotblogspotatlassian-3p-us-gov-modfrom-ndfrom-msis-a-techieis-a-studentcustomer-ociis-a-photographerdurumisfrom-ksmassivegriddyndns-wikiis-an-entertaineris-a-hard-workermysecuritycamerafrom-mnrackmazedyndns-blogis-a-bulls-fanwritesthisblogfreemyipsimple-urlfrom-sdreservdauthgear-stagingest-mon-blogueuris-into-gamesrice-labsxtooldevicesakurawebis-an-anarchistoraclecloudappsdyndns-worksells-for-urhcloudfrom-dcfastvps-serverwpmucdnis-a-geekscrysecfrom-txis-into-cartoonsmodelscapetrycloudflarelocaltonetstreak-linkbalena-devicesfrom-njforgeblocksfreebox-oswebadorsitefrom-ncdoesntexisthobby-sitestreaklinkshomesecuritymacownprovidertuleap-partnersdattorelaywphostedmailalpha-myqnapcloudservequakeis-a-socialistservehalflifepivohostingdynuhostingquipelementsw-staticblitzdyndns-webfrom-deproject-studyaliases121is-not-certifiedhercules-devis-a-financialadvisorservepicsis-a-greenloseyouripfrom-ilwithyoutubemwcloudnonprodwiredbladehostingdnsdojofrom-tnpixolinomyqnapcloudis-an-artisthostedpiis-a-landscaperauiusercontentoaiusercontenton-forgeis-a-conservativedreamhostersnet-freaksapps-1and1is-goneencoreapifastly-edgefrom-nesalesforcefrom-scdeployagentoraclegovcloudappsfrom-alis-a-lawyercechirevultrobjectsstufftoreadisa-geekddnsgeeklovableprojecttry-snowplowfrom-moblogsyteis-a-bookkeepernogmyforumravendbmyboxdeelementoredsaacficogoorinforgcomgobnatneteduidstoreorgcomnetintedudevnomepublorgcomneteduathgovtestscalculatorspaynowinfoquizzesresearchedcloudnsfunnelsassessmentsjscaleforcetmacltdorgmilcompronetgovbizpresseklogesrsccloudcustomfltusrcloude4corealmgovmunicontentproxy9metacentrumdyndyndyndnsdynpagespages-researchitionoccustomercomymyspreadshopipv64diskussionsbereich4limacomrub2ixfirewall-gatewayddnssspdnsbarsykeymachinesquare7myhome-serverspeedpartnercommunity-proschuldockxenonconnectgünstigliefernbwcloud-os-instancedyndnssecmy-routerxn--gnstigliefern-wobin-butterl-o-g-i-nisteingeekin-dslin-berlinin-brbfuettertdasnetzleitungsenin-vpnlcube-serverdyn-ip24logoipdyn-berlinruhr-uni-bochum12hpgoipsrvdnsfruskygit-repossvn-reposinternet-dnsgünstigbestellenhome-webserverxn--gnstigbestellen-zvbbplacedheimdnscosidnswebspaceconfiglima-citydyndns1istmeinvirtualuserschulplattformmy-gatewayddnsseclebtimnetztest-iservmein-iservvirtual-userhome64iservschuletaifun-dnstraeumtgeradeschulserverdynamisches-dns123webseitednshomehs-heilbronndnsupdaterbssgraphicdwadpdwdaepeweaawapaafpfwfabwbpbacwcpcciwebuserapiobjectsidsiskospockkimodorikerbonesteamsparisjanewaypicardglobaltarpitreedpikekiraworfsulukirkarchertuckerhackercanarywesleystagingprereleaset3r2lpbravepanelngrokiservstglclcrmerpflypagesbarsyvivenushoplocalcertlocalplayerbearbloggatewaydeno-stagingis-not-ais-a-goodbotdashvercelmocha-sandboxplatter-appreplitgithubpreviewworkersinbrowserevervaultdetais-ahrsndenoxmitmodxmyaddrstorageapipayloadgrebedocruncontainersstgstagelclstageloginlineis-a-fullstackleapcellngrok-freeis-coolstoragewebharemediatechlibp2pdiscourseimaginecomyspreadshopstoreregbiz123hjemmesidefirmcoorgcomnetedugovsldorgmilcomwebgobartnetedugovtmorgpolcomsocartnetedugovassoagrondiscoodontk12medcuegyecpaabgengorgmilgalsaltulcomadmesmgobpubdocmonfindgnriouioproartlatvetnetfotedulojgovntrturibrbarxxxofficialbasechefprofmktgpsictechinfoarqtcontdentrrpppsiqgit-pagesritmedfieorgcomlibprieduaipgovriikmeactvsportorgmilcomscieunnetedugovnameinfopintouchtawktotawkmyspreadshoporgcomnomgobedu123miwebcomputeorgcomnetedugovbiznameinfocognito-idpeusc-de-east-1onjelasticnxaspdnsbarsydirectwpdeuxfleurstransurldogadoprvwcloudnsamazonwebservicesdnshomeuserpartycokoobinmkmstorjfidemopaasdymyspreadshopalandkapsiikixn--hkkinen-5wacloudplatformdatacenterhäkkinen123kotisivuidacorgmilcompronetedugovbiznameinforadioorgcomneteduuserexperts-comptablestmmyspreadshopgretaprdcomnomynhccifbxoshuissier-justicenotairesaeroportfreeboxoson-webavocatassoportgouvkdnschirurgiens-dentistes-en-franceavouesfbx-os123sitewebveterinairechirurgiens-dentistespharmacienchambagrimedecinfreebox-osdediboxgoupilemszicpyicpvicppleysheezypagesedugovcnpyorgcomcybllcpvtnetedugovtnxonlineschooldaemond6atcopanelorgnetplybotdashstackitkaasorgmilcomnetedugovbizmodltdorgcomedugovcoorgcomneteduappwriteacorgcomnetedugovcloudtranslateusercontentorgcomnetedumobiassoorgcomnetedugovbarsysimplesitediscourseindorgmilcomgobneteduorgcomwebnetedugovguaminfonxhra教育敎育網絡网絡组織組織网络網络组织組织公司政府個人个人箇人ltdorgcomincneteduidvgovxn--uc0ay4axn--55qx5dxn--mk0axixn--io0a7ixn--uc0atvxn--zf0avxxn--lcvr32dxn--od0algxn--wcvs22dxn--gmqw5axn--od0aq3bxn--mxtq1mxn--ciqpnxn--tn0agxn--gmq050iorgmilcomgobneteduiservwp2tempurlmircloudfreesitewpmudevmyfastgadgetcloudaccessjelehalfboltfastvpsemergenteasypanelopencraftizcombrendlynamefromrtpersoadultmedorgpolrelcomproartnetedufirminfoassoshopcoopgouvtmcomediahotelforumvideosportorgsexagrargameslakaseroticaerotikatozsdereklamcasino2000filmsuliinfoboltshopprivnewsszexcityutazasjogaszkonyveloingatlaneacaicogoormyᬩᬮᬶmilwebschnetkopbizzonedesaponpesxn--9tfkymyspreadshopgovmytabittabitorderravpageaccok12idforgnetgovmuniltdplcaccotttvorgcomnetmeca6g5gpgamubacaicniocoukuptverdruscsdelhiindorgmilcomwebnicfingenpronetintedugovresbizbiharbarsyinternetbusinessschooltravelsupabasealumnigujaratfirminfoaeropostbankcoopindevscloudnsno-ipbarsybarrell-of-knowledgebarrel-of-knowledgensupdategroks-thisdnsupdatefor-ourknowsitalldvrcammittwalddynamic-dnsv-infowebhopselfipdyndnshere-for-moreilovecollegemayfirstforumzcloudnsmittwaldservertypo3servergroks-theeusekd1uk0cdndyndnsidrawsainaueuapjpusstagemocksysdevicesclientcustreservdcustdevdisrecprodtestingcobeebyteutwenteboxfusebravepstmndedynngrokorgmilcomnomhzcnetedugovqcxqzzbarsythingdustmo-siemensrb-hostingprotonetfh-muenstergitbookbluebitecloudbeesusercontentnodeartkiloappsforgerockdarklangresinstagingapigeebubbleb-datascryptedhypernodedappnodepantheonsitegitlabgithubkeeneticvirtualservercleverappshostyhostingon-rioedugitticketstelebiton-acornwixstudioon-k3sicp0icp12038jeleqotobigvlairbubbleappsmyaddrstolosmyrdbxwebflowdrive-platformbeagleboardhasura-applolipopdefinimavaporcloudmusicianwebflowtestazurecontainerresindevicereadthedocsloginlineeditorxmoonscalesandcatsbasicserverwebthingsbrowsersafetymarkbeebyteappbitbucketidaccovistablogorgschnetgovxn--mgba3a4f16axn--mgba3a4fraarvanedgeايرانایرانjclaspeziapdudcefegelemeperetevebacanatavaparasabgagfgogrgpgalclblimfmrmcbmbvbfclcmcvcrcpcchlimifibicivipirisimncnbnanenrnpntnnolomobocoaogorosopotoptvtatctbtmtltotpulunutpspapaqsvpvvvtvavvrtrsrprgrfrcrbrarorkrvstsssbscsmsispzczbzbozen-suedtirolmyspreadshopxn--bulsan-sdtirol-nsbxn--valledaoste-ebbtrentinoaltoadigetrentin-sued-tirolxn--forlcesena-c8axn--forl-cesena-fcbxn--bozen-sdtirol-2obtriestetrentinsuedtiroltrentino-s-tirollecceudineaostesienaparmaluccapaviagenoapaduaaostamonzaabruzzoternirietiturinmilanbozenlaziofermoleccocuneonuoropratola-speziavdataaligfvgpugmolcalcamlomumbsicpmnvenvaoedugovabrsarmaremrbastoslazibxosfirenzetrentinosüdtirolval-d-aostavalle-aostamessinacremonaravennatoscanatrentin-suedtirolbolognacalabriaurbinopesarofriuli-v-giuliaogliastraxn--valle-aoste-ebblaquilaandriatranibarlettasyncloudtrentinosudtirolxn--valle-d-aoste-ehbaostavalleyvalled-aostatrentino-alto-adigevallee-d-aostexn--balsan-sdtirol-nsbpistoiasicilialucaniacataniaiserniaperugiabresciaveneziagorizialiguriaimperiabulsan-suedtirolbalsan-suedtirolbarlettatraniandriaxn--trentino-sdtirol-szbforlì-cesenatuscanyvallée-d-aostemantovavallée-aostecasertapiemontevalleaostaval-daostafriulivgiuliatrevisoforli-cesenavalléedaosteferrarapescaravald-aostatrentino-altoadigefriuli-vegiuliavallee-aostecarboniaiglesiastarantomediocampidanovalleedaostetrentinosud-tirolcampobassotrentinsüd-tiroltrentinosüd-tirolmonzabrianzatrentino-südtirolxn--trentino-sd-tirol-c3bpotenzacosenzavicenzaemiliaromagnavenicefrosinonemarchepordenonetrentinosued-tirolvaresemolisevalléeaostefriuli-veneziagiuliabasilicatalatinaanconasavonaveronamodenaaquilabiellabolzano-altoadigepugliafoggiaumbriatrentino-stirolgenovapadovamateranovararagusapiacenzatrentinostirolvalleeaostetempio-olbiatrentinsudtirolmassa-carrarafriuliveneziagiuliatrentinosuedtirolandria-barletta-tranitrapanixn--cesenaforl-i8amaceratacaltanissettaascoli-picenobrindisicarraramassacagliaririmininapolivibo-valentiachietibulsan-sudtirolbalsan-sudtiroltrentino-a-adigebulsanbalsaniglesiascarboniamilanotorinoteramodell-ogliastraarezzotrentinoalto-adigerovigotrentovenetoiglesias-carboniatrentino-sud-tirolaltoadigereggio-emiliareggio-calabriasardegnatranibarlettaandriapiedmontxn--sdtirol-n2amedio-campidanotrentino-süd-tirolfriuli-vgiuliafriuli-ve-giuliaromeennaromapisa32-b16-b64-blodiastibarineencomonaplesforlicesenailiadboxosalessandriasicilytrani-barletta-andriaxn--trentin-sdtirol-7vbpesarourbinotrentinsued-tirolcesena-forliforlìcesenaemilia-romagnamonzaebrianzaxn--trentinsdtirol-nsbtrentinos-tiroltrentinsüdtirolvalledaostaolbia-tempiocampidanomediovibovalentiasassarivalle-daostalombardyfriulivegiuliareggioemiliamonzaedellabrianzaalto-adigevercellitrentin-sudtiroltraniandriabarlettatrentino-sudtirolascolipicenobozen-südtirolfriulive-giuliaflorencevaldaostaxn--cesena-forl-mcbcarbonia-iglesiasaosta-valleycarrara-massadellogliastratrentinoa-adigexn--valleaoste-e7apesaro-urbinoxn--trentinosdtirol-7vbxn--trentin-sd-tirol-rzbxn--trentinsd-tirol-6vbtrani-andria-barlettatrentin-süd-tirolxn--trentinosd-tirol-rzbgrossetomonza-e-della-brianzasüdtirolreggiocalabriatrentinoaadigetrentin-südtirolfriuliv-giuliaverbaniacampaniatrentino-aadigefriulivenezia-giuliasardiniaandriabarlettatranibarletta-trani-andriacatanzarooristanourbino-pesarocesena-forlìvalle-d-aostacampidano-medio123homepagesiracusatempioolbiasuedtirollombardiaavellinocesenaforlìtrentinofriuli-venezia-giuliabozen-sudtirolandria-trani-barlettabulsan-südtirolbalsan-südtirolmonza-brianzabolzanotrentino-sued-tirolbellunosalernolivornocrotonesondriodnshometrentinsud-tirolmassacarraratrentin-sud-tiroltrentino-suedtirolviterbobergamocesenaforliolbiatempiopalermobeneventoagrigentoofcoorgnetfmaitvphdengorgmilcomschnetedugovperagrikanieasukehandachitatokaiaisaikonanoharuamaobuhigashiuraowariasahiinuyamatobishimaiwakurashitarainazawatoyonegamagorimihamatoyotataharakariyayatomioguchikomakimiyoshinishiotokonamekiyosuchiryutoyohashiokazakiisshikikasugaikotakiratoeianjotogofusosetohazutsushimashinshirotakahamanisshinshikatsuhekinantoyokawaichinomiyatoyoakeodateogataakitaikawakyowahonjoogayurihonjonoshirokamiokakatagamimitanegojomeyokotekosakadaisenkazunonikahohonjyomoriyoshimisatohappoukamikoanihachirogatahigashinarusesembokufujisatokitaakitaitayanagiowanitakkomutsutsurutahirosakigonoheoirasetowadamisawanohejiaomorishingohiranairokunohehashikamitsugarushichinohehachinohenakadomarisannohekuroishisakaeisumiasahiotakiinzaiabikomatsudoyachiyomutsuzawakujukuriomigawakashiwatoganemihamanaritasakuranagaramobarahanamigawachoshishiroichoseikozakishisuikatorimidorichonankyonanfuttsuonjukufunabashinagareyamanodasosatakochuotohnoshourayasukimitsuyokaichibayotsukaidosodegauratateyamakamagayayokoshibahikariyachimatakatsuuratomisatokisarazukamogawaichikawanarashinoichinomiyashimofusaminamibososhirakoichiharaoamishirasatoikatahonaiainansaijoseiyoiyoozuuwajimaniihamanamikatamasakiuchikokihokutobetoonshikokuchuomatsuyamaimabarikamijimakumakogenyawatahamamatsunosabaeikedaobamasakaifukuiohionotsurugamihamawakasaminamiechizeneiheijikatsuyamatakahamaechizensoedaukihaomutaokawanishiogoribuzenonojosueumiokiotochikugosasagurisaigawamizumakishinyoshitomikurumekurateyamadakasuganakamamiyamanogatatakatahakataiizukakawaratagawakasuyaashiyainatsukimunakataminamitsuikishonaikurogifukuchikeisenhigashimiyakoshinguyukuhashiokagakiyamekogaongausuikahotohochuotoyotsumiyawakadazaifuhisayamatachiaraiyanagawanakagawahirokawachikujochikushinochikuhochikuzennamieotamaokumashowateneiiwakikoorinangoononishigoshimogoomotegomishimafukushimaasakawakagamiishishirakawaiitatefutabahiratayugawahanawakitakatakawamatakunimiyabukibandaihigashihironoyamatomiharuyamatsuriaizubangedatesomaaizuwakamatsuyanaizuaizumisatonishiaizuizumizakikitashiobarataishinkaneyamakoriyamainawashirotanagurafurudonosamegawasukagawaishikawatamakawaikedaogakitaruiginanenahashimahichisonakatsugawaibigawashirakawamizunamiminokamomitakekawauesekigaharatomikasakahogikitagatayamagatatajimianpachimotosuyaotsukakamigaharahidakanisekitokigujominogodoyorogifukasamatsutakayamawanouchihigashishirakawakasaharashimonitatsumagoichiyodakannakanrashowameiwakiryuotaoratomiokafujiokaitakuranaganoharahigashiagatsumatakasakishibukawaminakamikatashinatsukiyonokawabanumataannakaoizumimidorishintoisesakiuenoyoshiokakusatsutakayamanakanojonanmokutamamuratatebayashimaebashiotakekaitadaiwahongofuchukuietajimashobaramiharahatsukaichihigashihiroshimamiyoshikumanokurenakasakaseraseranishiasaminamifukuyamashinichionomichiosakikamijimajinsekikogentakeharaotobenanaeikedatohmaozoraobiraabirakyowaeniwataikibibaisharirebunerimohiroooketootarupippunishiokoppechitosefurubirahakodateshiranukakitahiroshimakushiroobihironanporoiwamizawaniikappukunneppufukushimanakasatsunaitoyourakuromatsunaiakabirakamisunagawashibechaurakawakamifuranonakatombetsuasahikawashimokawakayabeokoppebiratoriabashirisaromaatsumanumatahidakabifukamukawamikasahorokanaitoyotomisarufutsuhigashikawaishikarikitamiyoichiesashiiwanaitomariminamifuranoakkeshifuranotoyakoyakumootoineppushikaoishiraoinemuronayorohaboroashorobihororishirifujiutashinaihokutotakasuebetsuurausuassabukikonaishimamakinaiedatetoyabieinikiesanuryuoumuteshikagarikubetsuashibetsukimobetsuaibetsutobetsusobetsuembetsushimizuchippubetsurishirihokuryuhoronobeshintokutsubetsushibetsuhonbetsumombetsutsukigatakuriyamakoshimizushiriuchikutchanmurorannoboribetsukamishihorowassamushinshinotsukembuchiwakkanaikamoenaikiyosatotakinoueshikabesunagawafukagawanakagawatakikawakamikawahigashikagurahamatonbetsumatsumaemoseushirankoshishakotanimakanemashikeotofuketomakomaisandatambaitamiawajikasaiasagoshisoonoakoyashirotoyookaminamiawajiinagawafukusakitakasagokamigorikasugaharimayokawaashiyahimejiakashitaishiaogakisannantakinosumototakarazukanishinomiyashingugoshikinishiwakiyokatakaaioimikisayoyabukawanishiamagasakisasayamashinonsenkakogawaichikawakamikawatatsunotsukubaiwamaogawaasahisakaitokaioaraiitakobandodaigosuifuinaamikasumigaurakashimaomitamayachiyoshimodatetomobetoridehitachinakainashikisakuragawakasamayawaramoriyahitachiomiyanamegatayamagatahitachikamisuushikutakahagiibarakitonekoganakasowayukimihojosomitoryugasakishimotsumafujishirotsuchiurachikuseihitachiotashirosatotamatsukuriuchiharashikahakuinanaotsubatawajimakahokukawakitatsurugikaganominotosuzuuchinadakomatsuanamizunakanotohakusannonoichikanazawaiwateshiwafudaikawaimoriokaofunatohanamakikuzumakikitakamininohekunoheyamadayahabasumitaichinosekitanohatahiraizumirikuzentakatajobojiotsuchihironomiyakoiwaizumikarumaiichinohenodakujitonooshushizukuishifujisawamizusawakamaishikanegasakimannoutazukotohiraayagawazentsujihigashikagawauchinomikanonjisanukimarugamemitoyotakamatsutadotsunaoshimatonoshoakuneamamiizumihiokiyusuikinkoisasookouyamanakatanekagoshimakanoyaisenkawanabeminamitanemakurazakitarumizunishinoomotematsumotosatsumasendaioimatsudaayaseebinamiurazushinakaiodawaraiseharasagamiharahakoneaikawakaiseiatsugitsukuihadanoyamatoyamakitazamaoisochigasakininomiyayokosukakamakuraminamiashigarafujisawasamukawakiyokawahiratsukayugawaraokawaumajikochitsunootoyoakiinonishitosayasudahidakamiharasakawaniyodogawahigashitsunokagamigeiseisusakiotsukinaharisukumomurototosakamiochitoyotosashimizumotoyamanankokunakamurakitagawayusuharaogunichoyoukiasoutoozugyokutoamakusamifunetakamoriyamagaminamataminamiogunikikuchisumotoyamatonagasumashikiaraokumamotokamiamakusanishiharayatsushiroayabeseikasakyoideineujinakagyokameokakyotangokyotanabekyotambaminamiyamashiroyamashinatanabeyawatawazukaminaminantanmiyazuhigashiyamafukuchiyamakitamukokamojoyokizumaizuruujitawaraoyamazakinagaokakyokumiyamakawagoeinabeshimameiwaasahitaikiudonoisetsukisosakikuwanamihamamiyamasuzukatamakimisuginabarikumanokomonominamiisewataraitobakiwatakikihotadomatsusakayokkaichikameyamaureshinoishinomakishichikashukuohirataiwaosakizaohigashimatsushimashikamaiwanumashibataogawaraonagawakawasakiseminemarumoriminamisanrikukakudamuratawakuyatomiyanatoriwataritagajomisatotomekamirifushiroishimatsushimayamamotoshiogamafurukawahyugaebinotsunosaitoayakushimanobeokakitauramiyazakitakazakigokaseshiibamimatashintomikunitomikitakatakobayashikawaminamitakaharukijotakanabemiyakonojonishimeranichinankitagawakadogawamorotsukakisofukushimaminamimakisakaeobuseikedaogawamiasaokayaasahiotakiotarichinoinaomichikumakomaganechikuhokukaruizawayasuokaooshikaikusakaminamiaikitogakushimatsukawakawakamitateshinatakamorikitaaikishiojirimiyadahakubaiizunaiijimaiiyamamiyotasuzakayasakatoguraookuwanagawaminowahirayayamagataminamiminowafujimiomachisakakitakaginaganonakanosakuhokomoronagisoshinanomachiwadauedaiidaharasuwatomiachiaokianankisosakunozawaonsenagematsutakayamashimosuwamatsumotoyamanouchinakagawamochizukiazuminotatsunoobamaomuraseihiunzenosetofutsuikichijiwanagasakiisahayahasamisaikaikawatanasasebohiradokuchinotsugototogitsutsushimashimabarashinkamigotomatsuurayamazoekashibaikomakawaitenrioyodosangokoryoudaojiikarugayamatokoriyamatenkawakatsuragikurotakikawakamimiyakemitsuetakatorikamikitayamayamatotakadahegurishinjokanmakisakuraitawaramotogoseoudanarasoniandokawanishishimoichihigashiyoshinokashiharashimokitayamanosegawayoshinomintsivorytopazsakuragehirnsumomoaseinetopalmail-boxmokurenyoitamuikaojiyagosensanjoaganomyokoseiroagaomishibataniigatanagaokamurakamiuonumayuzawakariwatagamitainaitsunanminamiuonumatochioyahikojoetsuseiroukamosadoizumozakitokamachiitoigawasekikawakashiwazakitsubamemitsukekokonoesaikiusukibeppuusahimeshimakunisakihasamataketatsukumihitaoitahijikusuyufukujukamitsuebungoonobungotakadaibaraniimibizentsuyamaokayamakasaokahayashimayakagemaniwaakaiwamisakishinjotamanotakahashikibichuowakesojanagishookumenannishiawakurakurashikiasakuchisetouchikagaminosatoshotomigusukunakagusukuyaeseizenaurumaiheyaaguniogiminanjokinminamidaitokitanakagusukuyonaguniokinawaishigakikunigamiurasoekadenataramahiraraginozataketomishimojizamamitonakiitomanhigashimotobuyonabarugushikamionnanahanagohaebarukumejimakitadaitonakijinnishiharayomitanginowantokashikiishikawaikedasuitaminohizuminishisakaikananabenodaitoosakasayamayaokishiwadatadaokakaizukatondabayashichihayaakasakakumatorikadomasayamahigashiosakashijonawatehirakatataishimisakitajirihannansennankatanotoyonominatosettsuhigashiyodogawaibarakinosekitachuohigashisumiyoshifujiiderakashiwaraizumiotsutoyonakamatsubaramoriguchiizumisanoshimamototakatsukineyagawahabikinotakaishikawachinaganoyoshinogarikamiminearitaouchiimarihizenogikashimaariakekiyamafukudomikitagatakitahataomachigenkaikanzakinishiaritakyuragisagataratosutakushiroishikaratsuhamatamakouhokukawagoeyoshidasatteogoseirumaasakaurawaogawaniizaomiyayoriiotakishikihonjooganohannohanyuinasaitamaokegawaarakawayoshikawayokozehasudasayamahidakafukayachichibuiwatsukiryokamiyoshimikamiizumifujimiwarabiranzanmiyoshiminanoyashiosakadosugitomisatohigashichichibutodasokakukiyonokazoshiraokakasukabekounosukawajimatsurugashimamiyashirokitamotohatoyamamoroyamahatogayakumagayakawaguchinagatorokamisatomatsubushinamegawatokigawakamikawafujiminohigashimatsuyamakoshigayatokorozawas3isk01isk02ryuohkoseikonanaishorittotakashimamaibarahikonetorahimenishiazaikokagamokotoyasuotsukusatsunagahamamoriyamatoyosatotakatsukinotogawaomihachimanhigashiomiakagiunnanizumogotsuamayatsukakakinokimatsuehamadamasudahikawahikimiokuizumoyasugiyakumomisatotamayuohdahigashiizumookinoshimanishinoshimatsuwanoshimaneshimadafujiedayoshidashimodagotembaiwataatamikosaiyaizuitoizumishimahaibaramakinoharaomaezakikawanehonkannamisusonohigashiizufukuroinumazukawazufujiaraishizuokahamamatsushimizuizunokunimatsuzakimorimachiminamiizunishiizukikugawakakegawafujikawafujinomiyaujiietsugaoyamayaitaohiranikkoashikagakuroisokanumasakurashioyakarasuyamamotegiichikaikaminokawatochigihagamokanogisanobatonasumibunasushiobaranishikatautsunomiyaiwafunemashikoshimotsukeohtawaratakanezawaitanokomatsushimatokushimaichibaminamiaizumiwajikikainanmiyoshinarutomimamugiananmatsushigesanagochishishikuinakagawamachidachiyodakomaefussainagitaitochofufuchuomeotahigashiyamatotoshimaokutamaaogashimakodairaedogawaarakawahachiojishinagawatachikawashibuyasuginamihinodekiyosesumidaoshimanerimamitakahamuraadachinakanomizuhobunkyomegurominatokoganeihigashikurumekokubunjihigashimurayamamusashimurayamatamakitahinochuokotokatsushikakouzushimaogasawaraakishimakunitachishinjukusetagayamusashinohachijoitabashiakirunohinoharachizunanbukotouramisasawakasayonagokogehinoyazutottorinichinansakaiminatokawaharaoyabetairainamiasahinantoimizufuchutakaokakurobeyamadajohanatoyamatonaminyuzenfunahashinakaniikawanamerikawaunazukitogahimiuozufukumitsutateyamakamiichiiwadearidayuasainamitaijikatsuragiaridagawatanabemihamahidakakainankiminomisatoshingushirahamakamitondayurakozakoyagobokitayamawakayamakudoyamahashimotokushimotokozagawahirogawakinokawanachikatsuurarsuseroeoishidasagaeoguniasahinagaitendonanyoobanazawanishikawasakataohkuratozawamikawamamurogawayamagatafunagatatakahatashonaishinjokahokuiideyuzakawanishitsuruokakaminoyamayamanobeshiratakamurayamanakayamakaneyamahigashineyonezawasakegawamitouubeyuuabushimonosekitabuseoshimatoyotaiwakunihikarishunannagatohagihofukudamatsutokuyamashowadoshitsurunanbukoshukaiminami-alpsnirasakikosugeotsukioshinohokutominobuyamanashifuefukichuokofuichikawamisatoyamanakakonakamichitabayamanishikatsuranarusawafujikawahayakawafujiyoshidafujikawaguchikouenohara長野京都岐阜大阪三重群馬千葉滋賀佐賀奈良adednelgaccogogror秋田愛知高知埼玉沖縄栃木熊本岩手青森山梨新潟島根鳥取長崎香川宮城石川大分宮崎茨城山口兵庫山形徳島広島福島福岡岡山富山静岡愛媛福井東京xn--4it168dhatenadiaryxn--vgu402ckawaiishophatenablogcocottenamaste北海道penneehimeiwateversestabachibashigagonnagunmapermahaccaakitaosakauh-ohblushkochiaichifukuikuroncapooitigohyogotokyokyotopunyuthickcheap0t00g00j0mie2-ddaapyawjg0amfemsubxiiboomoobutchueekpgwrgrherskrboyrdyupperunderflierchipsmydnsheavyangryhippygirlyrulez神奈川鹿児島和歌山bambinaxn--nit225kokayamasaitamaxn--k7yn95exn--1lqs03nsapporoparasitelolipopmcxn--efvn9sniigatafukuokatokushimafukushimahiroshimakagoshimafakefurokinawaxn--8pvr4ucoolblogxn--0trq7p7nnkawasakinagasakimiyazakichilloutxn--8ltr62kxn--klty5xpeeweezombiecutegirlxn--rny31hxn--uuwu58axn--ntso0iqx3axn--djrs72d6uytoyamanikitanyantakagawamimozanagoyaboyfriendxn--2m4a15egreaterchowderegoismyamagatafashionstorexn--elqq16hxn--pssu33lsendaimiyagixn--rht27zpecoriaomorisaloonwatsonvivianxn--djty4knobushipigboatnaganopinokoxn--f6qx53asadistvelvetsecretxn--5js045dchicappayamanashiibarakidigickgirlfriendxn--1lqs71dmongolianxn--c3s14mxn--qqqt11mtochigixn--5rtq34kparallelo0o0mondkobesagabonadecaoitanarafoolkilldecimainhiholomosblokilociaoundopupugifutankcrapflopnooroopsmodsholyjeezstripperpepperbittershizuokaxn--rht3dkitakyushureadymadeicurusversusmatrixxn--rht61ehungryfloppygloomycrankyhandcraftedlittlestarxn--klt787dxn--kltx9awhitesnowsunnydaytottorilovepoptheshopbuyshopxn--5rtp49cxn--d5qv7z876cwebaccelxn--kbrq7oxn--4pvxsxn--1ctwolovesickkumamotocatfoodxn--tor131oyokohamawakayamatonkotsuxn--ehqz56nxn--uist22hxn--6btw5axn--kltp7dyamaguchifrenchkisspussycatxn--4it797kxn--uisz3gbabybluexn--zbx025dnetgamersxn--7t0a264ckanagawaxn--6orx2rishikawaxn--ntsq17ghalfmoonschoolbusjellybeanxn--mkru45iusercontentlolitapunkxn--32vp30hsakurastoragehokkaidoshimanecandypopbabymilksupersaleweblikeraindropbackdropwebsozaikikirarahateblodaynightmeneacsccogoormobiinfoaeusxxorgmilcomnetedugovorgcomnetedugovbizinfotmprdorgmilcomnomedugovassnotairespresseassocoopgouvveterinairemedecinpharmaciensorgnetedugovtraorgcomedurepgovmeneperekgacscaiiocogoitoresmshsseoulbusanulsandaeguc01milvkimmvchungnamjeonnamjeonbukeliv-dnsgyeonggijejueliv-cdnincheondaejeongangwongyeongbukgwangjuchungbukgyeongnameliv-apicoeduindorgcomembnetedugovorgmilcomnetedugovjcloudorgcomnetintedugovperbnrinfocooyorgcomnetedugovipfscanvamypepw3sstorachakeeneticjoinmcinbrowserdwebcyonnftstoragemyfritzaemewphlxachotelltdorgcomwebsocschngonetintedugrpgovassnomgacsccoorgnetedugovbizinfo123websiteidorgmilcomasnnetedugovconfidmedorgcomplcschnetedugovaccoorgnetgovpresstmassoirseproxaccosoundcasthoptocraftvp4c66orgnetedugovitsmcdirmyboxbarsyedgestacksynologylogintonohostwebhopdiskstationi234tcp4hoocgroknoipprivmydsddnsdnsforlohmustransipdscloudfilegear-sgbrasiliafilegearframerbarsybarsyonlinecoprdorgmilcomnomedugovinforgcomnetedugovnameacprorgcomartnetedugovpresseinfoassoinstgouvorgnycedugovbarsydscloudjuorgcomnetedugovminisiteaccoororgcomnetgovorgmilcompronetintedugovbizmuseumnameinfoaerocoopaccoorgcomnetintedugovbizcooporgcomgobneteduorgmilcomnetedugovbiznameaccoorgmilneteduadvgovcoorgcomnetaltgovforgotherhiskeeneticispmanagernomassoprod5476132eastasiacentraluswesteuropewestus2eastus2rucdnwest1-usfra1-desandboxjls-sto1jls-sto3jls-sto2aglobalabglobalsslmapprodfreetlsmaplon-1lon-2ny-1fr-1sg-1ny-2paassnwebpaashostingjelasticnordeste-idcsocuserpagescwebfileblobservicebuscoreatlricnjsjelasticwebsitestoragesezagbinruhuukjptsmyspreadshopmynetnameakamaiorigin-stagingfrom-coipv64dynv6cdn77serveblogadobeaemcloudhicamsprytdnsupno-ipownipde5ovhicpfirewall-gatewaysytesmypsxbarsyusgovcloudapimyamazemyradwebakamaihdsaveincloudfastlylbfrom-lasubsc-paysquare7in-the-bandblackbaudcdnhomelinuxoninfernoctfcloudservebbsdns-dynamiccloudfrontakamai-stagingipifonyham-radio-opsenseeringclickrisingcommunity-profrom-nylocalcertgrafana-devedgesuite-stagingcloudflareanycasteating-organicatlassian-devmydattofeste-iplocaltotorprojectknx-serveredgekeycloudflareglobalcloudyclustercasacamserveftpakamaized-stagingakamaiorigindns-cloudmyeffectboomlabotdashbuyshousestwmailhetemlazure-mobilein-dslthruhereredirectmedynuddnsbouncemesupabaseluyanicloudappakamaicloudfunctionsdebiannhlfanpgafanstatic-accessin-vpnmysynologymafeloappudohomeftptrafficmanagersiteleafseidatmemsetcloudflarecloudaccesskeyword-onazure-apiis-a-chefdoes-itgets-itwebhopselfiphomeipkicks-assedgesuitewindowsserver-ontunnelmolemydissentscrapper-sitecloudflarecnuni5srcfggffiobbzabcdenodynuopikddnsvpndnsakadnselastxkinghostvps-hostfastlyhomeunixazureedgeshopselectdontexistmyfritzcloudjiffyalwaysdatasells-itsquaresbroke-itazurefddattolocalat-band-campmeinforumfamilydsazurestaticappsdefinimabplaceddnsaliasdynaliasnow-dnsblogdnsroutingthecloudendofinternetdsmynasakamaiedgemymediapcadobeio-staticakamaiedge-stagingakamaihd-stagingddns-ipprivatizehealthinsurancelive-onkrellianschokokeksmassivegridmysecuritycamerarackmazeserveminecraftfrom-azis-a-geekakamaizedmoonscalecryptonomicoffice-on-theusgovtrafficmanageradobeioruntimeedgekey-stagingreserve-onlinechannelsdvrdnsdojousgovcloudappcdn77-sslapps-1and1podzoneazurewebsitesdynathomescaleforceyandexcloudvusercontentisa-geekcdn-edgescoaemalcesappwriteazimuthtlonarvonoticeablestorecomwebrecnetperotherfirminfoartslgdloncogoiltdorgmilcolcomplcschgenngonetedugovbiznamefirmmobiacincoorgmilcomnomwebgobnetintedubizinfocomyspreadshopdemongovtransurl123websitehosting-clusterkhplaycistrongsnesosvalervålerxn--vler-qoaossandeheroysandeherøybøboheroyherøyxn--hery-iraxn--b-5gavalerbøboxn--b-5gasandesandexn--hery-iraxn--vler-qoavålerhåreålaahavaofsfvfhlolnlalrlhmfmtmahcostntbuåstrmreigersundmyspreadshopgálsáeidsvolltingvollgildeskalflorøvadsøvardøvanylvenxn--bhccavuotna-k7astrandaxn--kvnangen-k0axn--sknland-fxaxn--mosjen-eyarakkestadhyllestadnannestadvevelstadvaapstenordre-landsondre-landsøndre-landtjieltexn--vrggt-xqadsør-aurdalsor-aurdalheradstordmoldefordeførdeseljefedjeryggehemnexn--krehamn-dxasognegranesøgnebrynetjomevallebykletokkegiskedovretjømehobølvoldasaudatolgasømnaviknadønnasomnadonnatranafrananesnaraumasmolatrænafrænalesjasmølaørstaorstahitrafloraaukraloppafrøyarissasnasahalsagalsaromsaraisaráisafroyasnåsagronghobolfjelltydalårdalardalaskimharamkraanghkekråanghkesorumbarumhurumbærumsørummodumsálátbálátfrognbjugnvåganvagangulenskienløtenlotenstrynvefsnxn--merker-kuaskaunsveiobømlobomloskjåkvardoflorovadsosalatbalatsálatklæbuklabuselbubarduulvikskjakklepprisørxn--nttery-byaeflåeidflahofmilgolholsellomskifetvikdepvgsfhsaskerrisorhamarasnesåsnesrørosrorosxn--slat-5namasoynaroyvaroyluroydyroyaskoyradoyandoyrodoymeloyradøyandøyrødøymeløyaskøylurøydyrøymåsøyværøynærøyhoylandethøylandetdivtasvuodnalørenskoglorenskognesoddtangenxn--tjme-hraxn--smla-hraxn--stjrdal-s1aunjargalillehammerunjárgaxn--hamary-fyadavvenjargaxn--bearalvhki-y4a123hjemmesidegjerdrumxn--brnnysund-m8acxn--tnsberg-q1axn--mlatvuopmi-s4axn--snsa-roaxn--skierv-utaxn--brum-voatysfjordkvafjordeidfjordkvæfjordsongdalenmjondalenmjøndalenxn--gls-elackragerogáŋgaviikagangaviikasørreisasorreisasør-varangersor-varangerxn--risr-iraskiervaxn--frna-woaxn--trna-woakvinesdalleksvikleirvikrøyrvikroyrviksvelvikvenneslaevje-og-hornnessandnessjøenmarnardalvindafjordsandefjordenebakksnillfjordullensvangxn--trany-yuabrønnøysundnamsskoganaustevollxn--stjrdalshalsen-sqbnord-aurdalnord-frontrøgstadtrogstadgrimstadflakstadgjerstadxn--sandy-yuaxn--leagaviika-52bnore-og-uvdalvegarsheixn--rlingen-mxaxn--ggaviika-8ya47hvegårsheikarlsoykvitsoymasfjordenhamaroyinderoyosteroydavvenjárgasauheradguovdageaidnuxn--vre-eiker-k8abronnoysiellakkrødsheradkrodsheradkvinnheradbrønnøyxn--mtta-vrjjat-k7afxn--lrenskog-54akvitsøyvárggátkarlsøyosterøyinderøyhamarøybronnoysundxn--aurskog-hland-jnbbahccavuotnabáhccavuotnagiehtavuoatnastor-elvdalmidtre-gauldalxn--gildeskl-g0akarasjokevenassixn--bievt-0qaxn--yer-znalebesbynessebyxn--hbmer-xqamalselvmålselvxn--unjrga-rtamøre-og-romsdalmore-og-romsdalhareidmelandørlandorlandstrandålgårdsolundalgardafjordåfjorddielddanuorrikautokeinoxn--stre-toten-zcbskodjeaejriestangeliernebamblestokkefauskesnåasesnaasekongsvingerlangevagberlevagxn--flor-jrahattfjelldalostre-totenøstre-totenvestfoldxn--mely-iraálaheadjualaheadjunordreisaxn--troms-zuaxn--lgrd-poacporsangerflatangerstavangerleikangerbremangersamnangergieldakarasjohkaxn--rdy-0nabfrostautsirasnoasatromsaxn--sr-aurdal-l8aflekkefjordjølsterjolsteraremarkhedmarknååmesjevuemienaamesjevuemiexn--vard-jrarollagmeråkermerakerorskogørskogxn--bdddj-mrabdákŋoluoktaxn--osyro-wuaaknoluoktatrysilskjervøymandaljondalbindalrindalmeldalsuldalorkdalsigdalalvdallærdalhurdalsirdalverdallerdallardaloppdalåseralaseralhadselkragerødivttasvuotnaoverhallasteinkjerxn--hnefoss-q1askedsmokorsettromsøxn--dyry-iravestre-totenmuseumxn--sandnessjen-ogbrahkkeravjufylkesbiblbájddarbajddarxn--laheadju-7yarennesøyxn--koluokta-7ya57hxn--hgebostad-g3aleirfjordstorfjordbalsfjordbåtsfjordbatsfjordmuosátbievátloabátkárášjohkanøtterøyxn--mjndalen-64anordkappláhppilahppialstahaugsiljanverranrøykenroykenhaldenlyngenbergenhortenhønefosshonefosstroandinbeiarnvarggatosoyroosøyrotromsoidrettmuosatbievatruovatloabatvoagattynsetnessetxn--indery-fyaskánitskanitraholtråholtxn--ystre-slidre-ujbandebusarpsborgbearduxn--karlsy-fyahordalandjorpelandjørpelanddeatnuringsakersør-odalsor-odalxn--slt-elabringerikeaudnedalnittedalnissedalhemsedalslattumsurnadalxn--blt-elabelverumstjørdalnaustdalhjartdalgjøvikfyresdalhasviknarviklarvikgjovikmalvikgamviklenvikporsgrunnstjordalengerdaldrobakdrøbakxn--msy-ula0hvestvagoyxn--vgan-qoaxn--ryken-vuaxn--lten-graxn--stfold-9xaxn--hpmir-xqaxn--lury-iramálatvuopmimalatvuopmitysværkirkenesbirkenesmoskenesbáidárxn--fjord-lraxn--rdal-poabahcavuotnabáhcavuotnaxn--frde-gralindåsbearalvahkixn--hobl-iraráhkkerávjuxn--loabt-0qavågåáltábodøsundlundraderådeetnetimeholeauregrueoddavagavegaranatanaarnasolasulaaltalekafusavangbergkvamåmliamlibokntinnroangranosenoslobodorøstroststatåmotamotivguprivøyeroyerliermossvossxn--nvuotna-hwalusterlunnermarkerhábmerhabmerhvalerfjalerxn--rholt-mratysvarbaidarfitjargaularhápmirhapmirmelhusfosnesøksnesoksnestysneshemnesevenesflesbergeidsbergtonsbergtønsberglindasxn--sndre-land-0cbnamsosxn--srum-graøystre-slidreoystre-slidrevestre-slidretrondheimbalestrandxn--langevg-jxaaustrheimxn--skjk-soavagsoyaveroysandoykarmoyfinnoytranoyvestbytranbysykkylvenxn--hyanger-q1aspjelkavikandasuoloxn--fl-ziaxn--drbak-wuastathellexn--sr-varanger-ggbtelemarkxn--bhcavuotna-s4axn--porsgu-sta26fčáhcesuolocahcesuoloakrehamnåkrehamnsandøykarmøyfinnøytranøyvågsøyaverøynamdalseidxn--lesund-huabadaddjaxn--vegrshei-c0axn--btsfjord-9zagildeskålporsanguxn--trgstad-r1anávuotnanavuotnahammerfestxn--sgne-graxn--brnny-wuacibestadharstadnarviikaevenáššivestnesgjemnessandnesagdenesrennesoyxn--avery-yuaxn--tysvr-vrabearalváhkikongsbergspydebergrandabergxn--andy-iradavvesiidaxn--krdsherad-m8aporsáŋgufredrikstadbjerkreimringeburennebuaurskog-holandnotteroyxn--vgsy-qoa0jxn--rmskog-byaskierváivelandbyglandfrolandaurlandforsandxn--bjddar-ptamidsundålesundalesundfetsundfarsundovre-eikerøvre-eikerakershusxn--moreke-juasørfoldøstfoldostfoldsorfoldhøyangerhoyangerlevangerorkangertanangerxn--vestvgy-ixa6olillesandulsteinxn--rennesy-v1agranvinskjervoyxn--klbu-woalavagisxn--h-2faxn--ryrvik-byakafjordkåfjordseljordfolkebiblxn--gjvik-wuajevnakerxn--kfjord-iuabudejjuxn--kranghke-b0axn--davvenjrga-y4axn--rland-uuaxn--ldingen-q1axn--mlselv-iuaxn--rady-iraxn--linds-prabrumunddalxn--ygarden-p1amo-i-ranaeidskogrømskogromskoghjelmelandxn--finny-yuaxn--sr-odal-q1axn--skjervy-v1aballangenkvanangenkvænangengratangenxn--hmmrfeasta-s4acvossevangensuohkanxn--rde-ulaxn--mli-tlaxn--ksnes-uuanordlandskanlandskånlandsortlandfuoiskuxn--rros-graxn--hcesuolo-7ya35bxn--eveni-0qa01gagaivuotnagáivuotnaxn--seral-lradrammenmodalenmosjoenjan-mayentorskensteigengloppenxn--snes-poamatta-varjjatxn--sr-fron-q1aomasvuotnajessheimbådåddjåxn--krager-gyaxn--kvfjord-nxaxn--asky-iraxn--snase-nraxn--bidr-5nacholtålenxn--vads-jraxn--jlster-byamosjøenxn--rst-0nastavernxn--ostery-fyaxn--oppegrd-ixaxn--sknit-yqaxn--risa-5naoppegårdskiptvetrendalenholtalenxn--mot-tlaxn--lhppi-xqaxn--holtlen-hxaxn--srreisa-q1akopervikxn--muost-0qaxn--bmlo-grahokksundkvalsundegersundxn--karmy-yuaullensakerxn--hylandet-54axn--kvitsy-fyaxn--bod-2nalangevågberlevågkristiansandxn--rsta-frahornindalstjørdalshalsenstjordalshalsensandnessjoenhámmárfeastaxn--lrdal-srasør-fronsor-fronnord-odalkristiansundmátta-várjjatvestvågøynesoddennotoddenbuskerudøygardenoygardensalangenlavangenralingenrælingenlodingenlødingenleaŋgaviikalaakesvuemieleangaviikauenorgexn--srfold-byaaskvollxn--rskog-uuaxn--nry-yla5gxn--vry-yla5ghammarfeastaxn--rhkkervju-01afxn--givuotna-8yakommunekrokstadelvanedre-eikerhagebostadhægebostadxn--berlevg-jxakviteseidxn--s-1faxn--l-1faxn--nmesjevuemie-tcbafuosskomoårekemoarekexn--lt-liacxn--jrpeland-54asvalbardoppegardholmestrandtvedestrandsogndalsokndalarendalsunndalfolldalxn--krjohka-hwab49jlyngdaletnedalnorddalsaltdalgausdalskedsmovaksdalgjesdalstordalxn--frya-hraaarbortedrangedalxn--smna-graaurskog-hølandxn--vg-yiabtjeldsundhaugesundlindesnesxn--mre-og-romsdal-qqbxn--dnna-gradynmerseineshacknetenterprisecloudmineaccomaorimāoriorgmilcriiwigennetschoolhealthkiwigovtgeekxn--mori-qsacloudnsparliamentcomedorgcompronetedugovmuseumwebsitekinservicebarsywebsitebuildereerobookheimdnsleapcelleero-stagetechcrscsslorigingohomecdbedeeeiemesecabgngilnlalplchfisiincnnoroptatitmtltruauhulumkdkukskjplvtrgrfrkrhrusesismycynzcznetinteduassoososcloudstgbetaaezaeuhkusjshatenadiarycdn77hoptozaptois-a-knightmyftpno-ipjpnddnssdpdnsspdnsbarsysweetpepperis-a-bruinsfanis-very-sweetservegameis-a-soxfanhomelinuxcdn77-secureservebbsmisconfusedwebredirectblogsitefreedesktopcouchpotatofriestoolforgeaccesscamis-lostreadmyblogsmall-webfedorapeopleserveftpis-a-celticsfanmywirepotagertwmailin-dslsellsyourhomeread-booksfreeddnscable-modemis-savednflfanufcfanmlbfanstuff-4-saleendoftheinternetin-vpnmy-firewallhomeftpis-localis-a-chefboldlygoingnowherewebhopselfipkicks-assroxatunkcamdvrfedoraprojectgotdnsdvrdnsdyndnspubtlspimientahomeunixdontexistfedorainfracloudwmflabsfspagesbmoattachmentsteckidsfamilydsdnsaliasdynaliasnow-dnscloudnsdoomdnsduckdnsblogdnshomednsroutingthecloudendofinternetdsmynasip-dynamicpoivronhttpbinmyfirewallis-very-evilmysecuritycamerais-a-linux-userwmcloudis-a-geektuxfamilyis-a-candidatedoesntexistis-very-badhobby-sitegame-hostaltervistais-foundis-a-patsfandnsdojohepforgepodzonedynservcollegefanis-very-goodfrom-meis-very-niceisa-geeknerdpolacmedsldingorgcomnomgobabonetedupleskaemhlxmyboxrockyprvcydeuxfleurspdnscodebergheyflowstatichostorgmilcomnomgobneteduorgcomeduiorgmilcomngonetedugovcloudns1337ngrokacorggogfamcomwebgobnetedugokgopgkpgovgosbizpasaugumicsopozpapuwmwsrprusiskwpspkppspkmpspokeoiawsawifoumsdnskokwpmuppuppsppiwwiwoowuzswkzoschrzpisdnwzmiuwwitdpssewsseumigugimoirmpinbwinbwiihupporzgwgriwupowwskrwioswuozstarostwokonsulattmpccopruszkowmyspreadshopostrodakartuzyopolegminamediaustkazgorajgoraolawailawalomzawloclradombytomjaworznotargilubinkoninzagantorunkutnokepnonakloczestsopotsanokturekplockslasksklepzarowlukowmedaidgdaorgmilrelcomnomatmgsmartneteduelkgovwawsossexbiztgorysejnytychypomorzeboleslawiechomesklepsdscloudunicloudzakopanelegnicarawa-mazbydgoszczswidnikkrasnikwloclawekbielawamragowograjeworealestatebeskidykaszubymalopolskaprzeworskswiebodzinlecznadfirmaszkolawarmiagdyniamiastakazimierz-dolnymalborkswidnicadlugolekaostrolekapodlasieelblagtravelsimplesitezachpomormielecszczecinnieruchomosciwalbrzychlezajsklublinbedzinpoznanwielunmielnooleckostarachowicedkontopowiatwroclawrybniksuwalkileborkslupskgdanskostrowwlkptarnobrzegtourismwegrowkrakowglogowyou2pilanysamailwrocinfoagroautobeepshopprivlapypiszlodzcfolksecommerce-shopmazurypulawyskoczowrzeszowpomorskiezgierzkaliszolkuszlowiczostrowiecsosnowiecmazowszewodzislawbialowiezazgorzeleckatowicepabianicejelenia-gorawolominkarpaczsieradznowarudaczeladzkonskowolaskierniewiceswinoujscieturystykabieszczadycieszynketrzynolsztynbialystokbabia-goraprochowicewarszawastalowa-wolapolkowicegorlicegliwiceponiatowalimanowalubartowaugustowkobierzyceopocznognieznoszczytnokolobrzegshoparenapodhalebielskoklodzkostargardatwithplayitownnamecoorgnetedugovacorgcomproestnetedugovbiznameislaprofinforechtngrokmedaaaacacpaenglawjurbarbarsykeeneticavocatacctcloudnsorgcomsecplonetedugov123paginaweborgcomnetintedugovnomepublidkinbarsygovx443cloudnsorgmilcomnetedugovcooporgmilcomschnetedugovnamecomcannetlibassoaemclantmcontstoreorgcomnomrecwwwbarsyfirminfoshopartsstackitmyddnswebspacelima-cityacincooxorgedugovbarsybrendlyhbvpsvpsspectrumlandinghostingacppmordoviamcprecbgorgmilcomspbnetintedumsknovgovbirrasmcdirmytismircloudvladimirnalchikadygeyamarinepyatigorskmyjinobashkiriaeurodirvladikavkazna4ugroznykustanaikalmykiacldmaildagestaniranbuildcanvaliaravalwixdevelopmentappwritemigrationneedleverceldatabasestackitcodereplravendbonporterlovableaccoorgmilnetgovcoopmedorgcompubschnetedugovservicemecomygovorggovtvmedorgcomnetedugovinfoedgfacbmlonihkutwpsryxzbdtmacfhppmyspreadshopbrandpartiorgcomfhvpress123minsidaitcouldbeworlanbibkommunalforbundfhskiopsyskomvuxkomforbnaturbruksgymnloginlineorgcomnetedugovenscaledeuusentbotdaorgmilcomnetgovnowteleporthashbangplatformlovablebarsyshopwarebasehoplixbarsyonlinemsf5gitappgitpagecofigma-govcaffeinefigmacanvasoltstputerbarsysupportchatgptsquareomniweopensocialcpanelnotionnovecorewpsquaredpreviewjelecyonbyensrhtfastvpspieboxconvexjouwwebheyflowplatformshloginlinemadethissourcecraftclouderaorgorgcomartedugouvunivmeorgcomnetedugovsurveysstatichfheiyuxs4allprojectmyfastubervibehostapp-ionosdeployagentmecoorgcomschnetedugovbizcncostoreorgmilcomneteduembaixadaconsuladokiraranohoprincipesaotomeheliohobarsystorebaseshopwaresellfyabkhaziavologdamordoviapenzalenugsochinavoiexnetspbmsknovnorth-kazakhstanashgabadkareliaarmeniageorgiavladimirnalchikivanovobukharaadygeyakhakassiakalugakrasnodarjambylaktyubinsktroitskbryanskobninskkurganazerbaijanpokrovskbashkiriatselinogradvladikavkazmurmansktulatuvamangyshlaktashkentchimkentgroznykaragandatermezarkhangelskkustanaikalmykiabalashoveast-kazakhstankaracoldagestantogliattibarsyredorgcomgobedumirenknightpointaccoorgjelasticdiscoursecleverappsschacmiincogoornetonlineshopcogoorgmilcomwebnicnetintedugovbiznametestcoorgmilcomnomnetedugovorangecloudpersoindorgcomfinnatnetgovensmincomtourismintlinfox0611oyaorgmilcomnetedugovquickconnectvpnplusnettprequalifymeaddrmyaddrntdllwadlnctvavdrk12orgmilpolbeltelcomwebgennetedutskkepgovbbsbiznameinfocoorgmilcompronetedugovbiznameinfobetter-thanworse-thansakurafromdyndnson-the-webmymailerorgmilurlcomneteduidvgovmydnsgameclubebizmeneacsccogotvorhotelmilmobiinfovodteiflgplkmsmsbcckhincndnvncoztltmkckppzpdprvcvkvlvcrkrkscxuzchernovtsyrivneyaltaodesavolynrovnolutskltdinforgcomnetedugovbizvinnicazhitomirternopilpoltavakropyvnytskyizaporizhzhiasevastopolsebastopoluzhgoroduzhhorodkharkovkharkivvinnytsiakhmelnytskyizaporizhzhecrimeaodessazhytomyrnikolaevcherkassydonetskluganskluhanskkirovogradivano-frankivskchernivtsikrymkievkyivlvivsumyzakarpattiamykolaivcherkasychernigovkhersonchernihivdnipropetrovskdnepropetrovskkhmelnitskiyneacsccogoorusorgmilcomedugovvmdhmyspreadshopadimono-ipbarsybytemarkbarsyonlinelayershiftnh-servretrosnubapicampaignservicelugaffinitylotteryweeklylotteryraffleentrygluglugsmeaccoindependent-inquestnimsitecopropymntltdorgplcschnetgovnhsbarsyindependent-commissionindependent-reviewpolicepublic-inquiryindependent-panelconnhospindependent-inquiryroyal-commissionoraclegovcloudappscck12libccphxcclibpvtparochchtrcck12libcceatonk12coglibtecgendstmusann-arborwashtenawcck12glghcck12sealibforksolympiabainbridge-islkeyporthoquiamyarrow-pointcentraliaport-townsendsequimport-ludlowrentonsilverdalebremertonredmondsheltonbellevueport-orchardport-angeleskingstonchehalisaberdeengig-harborseattlepoulsboidmdndsddemenegacalamaiavawapailalflnmdcncscohnhmihiviwiriinmntnmocoutvtctmtgunjokakwvnvprarorasmskstxwynykyazisadninsnngosrvis-bymircloudservernamepointtoenscaledland-4-salefreeddnsstuff-4-saleazure-apinoipcloudnsgolffanheliohostazurewebsitesgvorgmilcomgubneteducoorgcomnetd0egvorgmilcomnetedugovmydnsiacostoree12orgmilcomnomwebgobbibrectecnetintedugovraremprendefirminfoartseducok12orgcomnethidnsidacaiiosonlahanamhanoicamauhueorgcompronetintedugovbizbacninhtayninhhoabinhnamdinhtravinhhaiphongvinhlonghaiduongquangnamquangtrithuathienhuequangninhbacgianghaugiangquangbinhsoctrangbentrethanhphohochiminhdanangkontumhatinhkhanhhoathanhhoahealthgialailaocaiyenbaibackanngheanlonganphuyenphuthocanthodaklakdongnainameinfovinhphucdongthapkiengiangtiengiangquangngailaichaulangsonlamdongdaknonghagiangangiangcaobangbinhduongninhthuanbinhthuanbaclieuthaibinhninhbinhbinhdinhtuyenquanghungyenbaria-vungtauthainguyendienbienbinhphuocschbizputerimagine-proxyorgcomnetedugovcloud66advisormypetsdyndnsxn--8dbq2axn--4dbgdty6cxn--5dbhl8dxn--hebda8bxn--80auxn--d1atxn--c1avgxn--o1acxn--o1achxn--90azhxn--55qx5dxn--uc0atvxn--od0algxn--wcvs22dxn--gmqw5axn--mxtq1mxn--12c1fe0brxn--h3cuzk1dixn--12co0c3b4evaxn--12cfi8ixb8lxn--o3cyx2axn--m3ch0j3axn--j1adpxn--90amcxn--90a1afxn--h1ahnxn--j1ael8bxn--h1alizxn--c1avgxn--j1aefxn--80aaa0cvacxn--41acaffeineexeopentunnelbotdashtelebitorgtmaccoagricorgmilnomwebnicngonetaltedugovlawnisschoolgrondaraccoorgmilcomschnetedugovbizinfoprg1-zeropstritonstackitlimazeropsaccoorgmilgovяспборгкоммскбизмирсамаракрымсочиакодпроргобрупрצהלממשלישובאקדמיהองค์กรธุรกิจรัฐบาลศึกษาทหารเน็ต教育網絡組織公司政府個人닷넷한국澳门新闻澳門联通家電嘉里招聘通販닷컴삼성コムგეбгрфеюadcdbdgdidmdsdtdaebedeeegeiejekemenepereseveyegabacalamanauavapaqasazacfbfafgfnfpfwftfbgcgagggegkgngmgsgpgvgtgugilmlnlalclglplsltlhmimjmkmmmomambmcmdmfmgmzmpmsmtmgbbblbsbecccacnclcmcvctcscmhkhghchbhthphshlinikifigiaibicivisikninhnmncnbngnsnpnvntnjoionomobocoaofodorosotoptstttytatbtetgtithtmtltrusuvuaucueuguhulumunufjdjbjtjsjlkmkhkfkdkcktkukskpkgpmpnpkpjpgqaqmqiqsvtvcvbvmvlvrwpwtwzwbwcwawgwkwmwtrsrprgrfrercrbrarnrmrlrkrirhrwsusrssspsgsesbsaslsmsissxmxaxcxuypysylymykygybycyuztzsznzmzkzdzczbzazελευ世界台灣购物公益点看臺灣网络書籍在线网站手机机构大拿游戏信息台湾谷歌慈善商标香港中国餐厅网址中國商城食品微博政务移动集团公司八卦商店健康网店政府时尚佛山中信娱乐广东企业homedepotengineeringاماراتrepublicankuokgroupversicherungchannelcitadelxn--pgbs0dhxn--b4w605ferdstatebankwebsitexn--mgb9awbf亚马逊淡马锡alibabaxn--ngbc5azdxn--mgbbh1axn--45br5cyltoshibabuildworldcloudtradeguideplacespacedancemoviephoneprimesmilebiblestyleappleazurestoreskypegripexn--l1accdrivelottehorsehouseleasechasereisestadahondaomegaaetnaamicaninjanokiamediadeltavodkaedekaosakapizzaslingemailgmailtirolshelltmallfinallegaltotalhotelamfamforumrehabmusicciticricohcoachwatchboschearthfaithirishmiamiarchidubaiguccipraxiみんなストアセールcanonsalononionnikonepsonkoelngreensevencrownikanoradioaudioweiboglobopromogalloyahoociscorodeovideomangobingotokyovolvolottokyotophotosmartsportquesttrusthyattjetztadultcymrubaidutushuxn--kprw13dubankclickblackmerckgroupsharpcheapnowtvxn--h2brj9cקוםհայоргсрбмонкомбелмкдқазрусукрمصرقطرعربكومdadcfdmedwedredphdthdbidpidkrdmsdltdiceonewmeglemoerwecfageacbanbambaaaammakianraspacpaaxawtfbcgaegongingaigvigorgdogdhlmilrilonlaolloluoljllcalgalnflafltelsrlfrllplkimibmcamcombommomifmabbjcbscbcabnabtabmlbpubabcbbcnecincpncllcstcwtcpwcnyckfhbzhovhmoiskiobisbitcifyituipinvinwinxincbnbcnmanfangdnmenrenkpnmtnyunrunfununobiojioriohbogmofooboooooacoecoceongoproartistottnttbbtcateatlatvetpetbetnethktmitfitintjothotgotdotbotprueduicujnjyouinknhktdkappsapgapmapdnptopgopllpjmpzipvipripesqtrvdtvitvdevmovgovhivnrwlawsewnewbmwwownowhowdvrftrmtrsfrbarcartvscrseusawsupsubssbsadsddsldssasbmsmlsxxxboxfoxgmxtjxsextaxbuyflydiysoyjoyskypaydaygayxyzanzbizwebersenerpokerlameractortatarsolarລາວคอมไทยtourslocusnexuslexusgiftsbeatsboatspartspressglassswissकॉमनेटtiresgivescodeshomesgamestunesshoescardswalesloansvegastoolsdealsautosparisファッションworkssucksrocksxeroxforexfedexpartylillymoneystudyrugbytoraytoday中文网xn--unup4y天主教飞利浦新加坡enterprises我爱你嘉里大酒店christmasxn--fct429kholdingsxn--8y0a063axn--mgbx4cd0ablifestyleabogadoallstatenetbankكاثوليكxn--s9brj9cxn--gk3at1ebestbuycharityxn--55qx5dmicrosoftpropertybasketballhomegoodscorsicajewelrygallerygrocerysurgerycountrybrusselsverisignferreroxn--czr694bhdfcbankcommbanksoftbankپاكستانپاکستانnextdirectالسعوديهالعليانxn--h2brj9c8cxn--80adxhksshikshaxn--mgbai9azgqp6jcuisinellabarclayscatholicxn--kpry57dcompanyxn--xhq521bblackfridayxn--mgba3a3ejtsandvikxn--d1acj3bacademydownloadمليسياxn--j1amhxn--w4r85el8fhu5dnraipirangaathletaxn--fhbeixn--mgbqly7cvafrzuerichxn--c2br7gஇலங்கைcontractorsxn--io0a7igraphicsinsurancetemasekxn--xkc2al3hye2amotorcyclesphotographydirectoryplumbingxn--vhquvclothingtrainingcleaningwilliamhilllightingxn--mgba3a4f16ashoppingcateringeducationokinawapicturesventuresproductionsxn--9et52uwalmartഭാരതംsupportrealestatecapitalonexn--nqv7fs00emaauspostfloristdentistxn--qxamgodaddybradescobargainsmitsubishikerryhotelsxn--9dbq2axn--3pxu8kimmobilienxn--fjq720axn--mgbtx2bholidaymckinseymadridbusinessbuildershelsinkixn--4gbrimмоскваالسعودیةcoffeedegreelacaixapartnersalsaceofficeabbvievoyageorangegeorgeonlinechromemobilekindlegoogleoraclecircleschulesecureinsurexn--mgba7c0bbn0aestatexn--mgbc0a9azcgcruisehangoutxn--vuq861bxn--42c2d9arexrothfirestoneuniversityxn--nnx388alifeinsuranceextraspaceонлайнvermögensberatersoftwarexn--fiqs8sxn--mgbab2bdxn--w4rs40ltiendaभारतम्africatoyotaotsukasakuracameracreditcardnagoyaconsultingnetworkjunipertheatermonsterprogressivepioneerxn--55qw42gracingdatingvotingvikinglivinggivingxn--bck1b9a5dre4cbrotherweatherjoburgفلسطينlplfinancialxn--clchc0ea0b2g2a9gcdfutbolschoolsocialglobaldentalwoodsidechanelairtelmatteltravelrealtorwebcamstreamభారత్unicomalstomxn--nodexn--6frz82gmuseumfurniturexn--rvc1e0am3exn--mix891faccenturexn--11b4c3dismailineustardiscountquebeccomsecclinicservicesxn--y9a3aqxn--c1avgswatchchurchsearchالاردنmarketingcontacthealthmonashshoujisanofitaipeiamericanexpresssuzukiアマゾンクラウドポイントbhartiグーグルxn--mgberp4a5d4armemorialxn--1qqw23alondonmormoninstitutevisionbostonnortoncouponmaisonamazonvirginberlindesigndurbanolayannissananquanxihuanhitachikaufengardenreisenbayerntechnologydatsunxn--90a3aclatinocasinostudiophysioxn--ngbe9e0apharmacytattootaobaoaramcoexpertreportabbottdirectselectimamatfairwindspictettargetmarketintuittravelersinsurancecreditdupontryukyusuppliesxn--tckwebnpparibasschmidtmerckmsdyodobashirestaurantbridgestonecricketxn--fpcrj9c3dbostikbroadwayattorneylefrakemerckxn--fiq228c5hscareersfarmerswinnersflowersxn--wgbh1cguitarsxn--54b7fta0ccxn--p1acfmakeupgalluplandroverxn--kcrx77d1x4agoldpointbauhausxn--mgbayh7gpahiphopplaystationxn--mgba3a4fraxn--eckvdtc9dhyundaixn--gckr3f0fistanbulticketsmarketsflightschintaireviewsxn--3e0b707ewindowsxn--fiqz9sfinancialxn--fzys8d69uvgmابوظبيdiscoverreviewবাংলাxn--5su34j936bgsgmoscowobserverapartmentsдетиارامكوсайтeurovisionxn--i1b6b1a6a2exn--xkc2dl3a5ee0hتونسموقعبارتڀارتشبكةعمانبيتكعراقreadkredbondlandbandfundfoodprodgoldfordtubecafesafelifeggeeieeefreefagepagegugezonewinememenamegamesaleablebikenikelikecarecbreherefiresaveloveliveblueartedatesitevotecaseluxebofamodaltdaasdatiaayogasinavanashiaasiajavabbvatevavivadatazaraarpacasavisasncfprofmaifsurfgolfdvagsongbingpingwangkpmggoogblogpohlfailcooldellcalldeallidlsarlfilmteamroomfarmimdbarabclubhdfcicbchsbcgmbhrichtechfishdishcashminiernikddiaudiwikimobitaxicitikiwidesiqponskinloanakdnwienopenporncerntownimmolimoolloinfonicofidolegosaxozeroaerovivoautovotomotofastbestresthostpostnextlgbtchatseatgiftmeetdietreitmintrentgentspotscotguruitausohumenucyoubanklinkpinkdclktalksilkbookseekworkrsvpaarpjeepshopcoophelpcamppccwshowbeerstarruhrflirweirhaircarsparsjprshausplusnewstipstoysjobskidsfanspicsdocsxboxamexsexynavycitysonyarmyallybabyplaydeliverybuzzgbizlamborghiniphilipsලංකාಭಾರತfitnessexpresslanxesspfizercenterwalterlawyersoccercareerkosherbrokerlockerdealerdoctorauthorxn--mgbqly7c0a67fbcvermögensberatungjaguarxn--pssy2uxn--hxt814eflickrrepairrogersairbusxn--mgbai9a5eva00beventsyachtsxn--t60b56aভাৰতভারতभारतभारोतviajeshermeshughesxn--j1aefसंगठनvillasଭାରତclaimshotelsભારતzapposphotosjuegoscondostatamotorsgratistennisਭਾਰਤtkmaxxtjmaxxschaeffleryandexxn--80aswgrealtysafetybeautyluxuryxn--3ds443gsupplyfamilyxn--o3cw4hhockeysydneyxn--90aenissayalipayenergycomputeragencyxn--rovu88b電訊盈科xn--gecrj9cstatefarmaccountantaquarelleolayangroup香格里拉xn--p1ai组织机构xn--1ck2e1bxn--mgbt3dhdschwarzموريتانياabudhabinowruzkomatsufujitsuhospitalxn--80asehdbxn--mgbtf8flxn--j6w193gxn--yfro4i67oprudentialxn--flw351ecruisescoursesrecipesxn--e1a4cferrarixn--ses554gxn--wgbl6awatchesstaplessinglesxn--mgbcpq6gpa1axn--otu796dpropertiescreditunionxn--mgbah1a3hjkrdstockholmhisamitsuالسعوديةstcgroupdomainsoriginscouponsbloombergclubmedfroganslimitedxn--80aqecdr1aexposedinternationalequipmentbarclaycardxn--q7ce6axn--mgbi4ecexpprotectionassociatesconstructionxn--cck2b3bxn--45q11candroidfoundationישראלxn--mgbca7dzdocliniqueboutiqueengineerxn--qxa6asystemsfirmdalefashionauctionxn--nqv7finfinitirentalsreliancetradingweddingfishinghostinggentingbookingcookingxn--3hcrj9cgraingerxn--czrs0tdemocratsamsungyokohamaxn--h2breg3evexn--nyqy26alundbeckmelbournevacationssolutionsfrontierxn--vermgensberatung-pwbmanagementxn--cg4bkixn--mgb2ddeslincolnhamburgsandvikcoromantblockbusterairforcebarefootxn--4dbrk0ceinvestmentsfeedbackcommunityxn--ngbrxالبحرينdiamondsamsterdamhealthcareredumbrellaxn--mxtq1mxn--2scrj9cagakhanxn--mgbpl2fhкатоликcaravanசிங்கப்பூர்richardlimortgageamericanfamilyxn--fzc2c9e2cscholarshipssaarlandxn--imr513nvlaanderensamsclubgoodyearkitchenஇந்தியாweatherchannelallfinanzxn--kput3iالسعودیۃxn--90aisxn--efvy88hالجزائرxn--mgbaam7a8hexchangejpmorganxn--tiq49xqyjfidelitysecurityxn--mk1bu44cwanggouxn--fiq64bxn--6qq986b3xlxn--mgbbh1a71exn--80ao21amarshallsxn--5tzm5gtravelerspanasoniclatrobeyoutubeaccountantsxn--rhqv96gxn--cckwcxetdanalyticsxn--ygbi2ammxبازاربھارتسوريةorganicfreseniusسورياxn--9krt00axn--qcka1pmcxn--jlq480n2rgdeloittesciencefinancexn--jvr189mxn--30rr7yhomesensehotmailbaseballfootballleclercboehringerxn--q9jyb4cxn--mix082fاليمنهمراهpolitieسودانايرانایرانnetflixyamaxunxn--lgbbat1ad8jcollegestoragecapetowncolognekerrypropertiesxn--mgbgu82axn--ogbpf8flxn--czru2dwhoswhociprianilasallexn--g2xx48cforsalebanamexaudiblexn--vermgensberater-ctbxn--zfr164bericssonvanguardxn--45brj9cindustriestheatremarriottxn--3bst00mcomparexn--mgberp4a5d4a87gcapitaldigitalالمغربbarcelonashangrilaxn--d1alfcalvinkleinwwwcitysapporokawasakinagoyasendaikobekitakyushuyokohamackjp",n9=621,a9=625,p2=So.length,h2=qd.length,f2=new Uint32Array(h2),Sd=new Uint32Array(h2),Vf=new Int32Array(p2).fill(-1);for(let e=0,n=0;e<p2;e+=1)for(let i=Od[e];i<Od[e+1];i+=1){f2[i]=n;const r=n+qd[i];let u=5381;for(let h=r-1;h>=n;h-=1)u=u*33^$f.charCodeAt(h);Sd[i]=u>>>0,qd[i]===1&&$f.charCodeAt(n)===42&&(Vf[e]=i),n=r}let qi=-1,Uf=0,Gf=0;function Vx(e,n,i,r){if(qd[e]!==r)return!1;const u=f2[e];for(let h=0;h<r;h+=1)if($f.charCodeAt(u+h)!==n.charCodeAt(i+h))return!1;return!0}function Ux(e,n,i,r,u){let h=Od[e],f=Od[e+1];for(;h<f;){const b=h+f>>>1,v=Sd[b];if(v<n)h=b+1;else if(v>n)f=b;else{for(let x=b;x>=h&&Sd[x]===n;x-=1)if(Vx(x,i,r,u))return x;for(let x=b+1;x<f&&Sd[x]===n;x+=1)if(Vx(x,i,r,u))return x;return-1}}return-1}function Gx(e,n,i){let r=n,u=e.length,h=5381;qi=-1;for(let b=e.length-1;b>=0;b-=1){const v=e.charCodeAt(b);if(v===46){const x=b+1;let S=Ux(r,h>>>0,e,x,u-x);if(S===-1&&(S=Vf[r]),S===-1)return qi!==-1;r=$x[S],(So[r]&i)!==0&&(qi=r,Uf=x,Gf=u),u=b,h=5381}else h=h*33^v}let f=Ux(r,h>>>0,e,0,u);return f===-1&&(f=Vf[r]),f!==-1&&(r=$x[f],(So[r]&i)!==0&&(qi=r,Uf=0,Gf=u)),qi!==-1}function g2(e,n,i){if(t9(e,n,i))return;const r=(n.allowPrivateDomains?2:0)|(n.allowIcannDomains?1:0);if(Gx(e,a9,r)){i.isIcann=(So[qi]&1)!==0,i.isPrivate=(So[qi]&2)!==0,i.publicSuffix=e.slice(Gf+1);return}if(Gx(e,n9,r)){i.isIcann=(So[qi]&1)!==0,i.isPrivate=(So[qi]&2)!==0,i.publicSuffix=e.slice(Uf);return}i.isIcann=!1,i.isPrivate=!1;const u=e.lastIndexOf(".");i.publicSuffix=u===-1?e:e.slice(u+1)}const Pd=e9();function i9(e,n){return d2(Pd),m2(e,0,g2,n,Pd).hostname}function s9(e,n){return d2(Pd),m2(e,5,g2,n,Pd).domainWithoutSuffix}const o9={allowPrivateDomains:!0};new $z({fuzzyLink:!0,fuzzyEmail:!1}).tlds(c2);function iee(e,n){if(!e)return"";const i=e.trim();if(!i)return"";if(/^https?:\/\//i.test(i))return i;if(i.startsWith("//"))return`https:${i}`;const r=n.trim().replace(/^https?:\/\//i,"").replace(/\/+$/,"");return r?i.startsWith("/")?`https://${r}${i}`:`https://${r}/${i}`:i}function see(e){const n=(e??"").trim();return n&&(n.startsWith("/")||/^https?:\/\//i.test(n)||/^mailto:/i.test(n))?n:"#"}function oee(e){const n=e??"",i=n.indexOf("?"),r=i===-1?n:n.slice(0,i),u=i===-1?"":n.slice(i+1),h=r||"/";if(!u)return{path:h,querySummary:null,raw:n};let f="";try{f=r9(new URLSearchParams(u))}catch{f="tracking params"}return{path:h,querySummary:f||null,raw:n}}function r9(e){const i=Array.from(e.keys()).length;if(i===0)return"";const r=i===1?"param":"params",u=l9(e);return u?`${u} · ${i} ${r}`:`${i} tracking ${r}`}function l9(e){if(e.has("fbclid"))return"Facebook Ad";if(e.has("gclid")||e.has("gbraid")||e.has("wbraid"))return"Google Ad";if(e.has("msclkid"))return"Microsoft Ad";if(e.has("ttclid"))return"TikTok Ad";if(e.has("li_fat_id"))return"LinkedIn Ad";if(e.has("twclid"))return"X / Twitter Ad";if(e.has("epik"))return"Pinterest Ad";for(const r of e.keys())if(r.startsWith("hsa_"))return"Search Ad";const n=e.get("utm_source"),i=e.get("utm_medium");return n&&i?`${n} / ${i}`:n?`Source: ${n}`:i?`Medium: ${i}`:null}function Ic(e){if(e==null)return null;const n=e.trim();if(!n)return null;const i=i9(n);return i?i.replace(/^www\./i,"").toLowerCase():null}function Qg(e){return e==null||e.trim()===""?"":s9(e,o9)?.toLowerCase()??""}function ree(e){return Qg(e)||e}const c9=new Intl.Segmenter("en",{granularity:"word"}),u9=/[^\p{L}\p{N}]+/gu,d9=/[\p{L}\p{N}]+/gu,m9=/[\p{Script=Latin}\p{Script=Greek}\p{Script=Cyrillic}]/u,p9=new RegExp("\\P{ASCII}","u");function h9(e){if(!p9.test(e))return e;let n="";for(const i of e){if(i.charCodeAt(0)<128){n+=i;continue}const r=i.normalize("NFD"),u=r[0];n+=r.length>1&&m9.test(u)?u:i}return n}function y2(e){return h9(e.normalize("NFKC")).toLocaleLowerCase("en")}function b2(e){const n=[];for(const i of c9.segment(e))if(i.isWordLike)for(const r of i.segment.match(d9)??[])n.push(r);return n}function f9(e){return b2(y2(e))}function Qa(e){return f9(e).join("")}const Kx=new WeakMap;function g9(e){if(!e)return null;const n=y2(e);return{normalized:n,stripped:n.replace(u9,"")}}function y9(e){const n=Kx.get(e);if(n)return n;const i=b2(e.normalized);return Kx.set(e,i),i}function b9(e){const n=new Set;let i=0;for(const r of e){if(!r)continue;const u=Qa(r);u&&(n.add(u),u.length>i&&(i=u.length))}return{keys:n,longest:i}}function v9(e,n){if(!n||e.keys.size===0)return!1;const i=typeof n=="string"?g9(n):n;if(!i)return!1;let r=!1;for(const h of e.keys)if(i.stripped.includes(h)){r=!0;break}if(!r)return!1;const u=y9(i);for(let h=0;h<u.length;h++){let f="";for(let b=h;b<u.length;b++){if(f+=u[b],e.keys.has(f))return!0;if(f.length>=e.longest)break}}return!1}const x9=d({name:o(),accountName:o().nullable(),type:o().nullable(),role:o().nullable()});d({accounts:y(x9),total:m().int().nonnegative()});const w9=d({id:o(),projectId:o(),accountName:o(),locationName:o(),displayName:o(),primaryCategoryDisplayName:o().nullable(),storefrontAddress:o().nullable(),websiteUri:o().nullable(),placeId:o().nullable(),mapsUri:o().nullable(),additionalCategories:y(o()),description:o().nullable(),serviceArea:Qe(o(),jn()).nullable(),regularHours:Qe(o(),jn()).nullable(),primaryPhone:o().nullable(),openStatus:o().nullable(),openingDate:o().nullable(),selected:_(),syncedAt:o().nullable(),createdAt:o(),updatedAt:o()});d({locations:y(w9),totalDiscovered:m().int().nonnegative(),totalSelected:m().int().nonnegative()});d({selectAllNew:_().default(!0),accountName:o().optional(),switchAccount:_().default(!1)});d({selected:_()});d({locationNames:y(o()).optional(),daysOfMetrics:m().int().positive().max(540).optional(),monthsOfKeywords:m().int().positive().max(18).optional()});d({runId:o(),status:o()});const S9=d({locationName:o(),date:o(),metric:o(),value:m().int()});d({metrics:y(S9),total:m().int().nonnegative()});const k9=d({locationName:o(),periodStart:o(),periodEnd:o(),keyword:o(),valueCount:m().int().nullable(),valueThreshold:m().int().nullable()});d({keywords:y(k9),total:m().int().nonnegative(),thresholdedPct:Oe(m().min(0).max(100))});const j9=d({locationName:o(),placeActionLinkName:o(),placeActionType:o(),uri:o().nullable(),isPreferred:_(),providerType:o().nullable()});d({placeActions:y(j9),total:m().int().nonnegative()});const A9=d({locationName:o(),populatedGroupCount:m().int().nonnegative(),syncedAt:o(),attributes:Qe(o(),jn())});d({lodging:y(A9),total:m().int().nonnegative()});const C9=d({name:o(),valueType:o(),values:y(Ze([_(),o()])),unsetValues:y(o()),uris:y(o())}),N9=d({locationName:o(),attributeCount:m().int().nonnegative(),syncedAt:o(),attributes:y(C9)});d({attributes:y(N9),total:m().int().nonnegative()});const _9=d({locationName:o(),placeId:o(),tier:o(),amenities:y(o()),syncedAt:o(),place:Qe(o(),jn())});d({places:y(_9),total:m().int().nonnegative()});const v2=j(["gbp","places"]),Fg=m().int().min(1).max(4),T9=j(["ok","unavailable","error"]),x2=j(["none","baseline","stale","pending","sent","skipped","suppressed"]);x2.enum;const E9=d({locationName:o(),origin:v2,reviewName:o(),starRating:m().int().min(1).max(5).nullable(),negative:_(),comment:o().nullable(),reviewerName:o().nullable(),createTime:o().nullable(),updateTime:o(),replied:_().nullable(),replyComment:o().nullable(),replyUpdateTime:o().nullable(),reviewUri:o().nullable(),firstSeenAt:o(),lastSeenAt:o(),alertState:x2,alertStateAt:o().nullable()}),R9=d({locationName:o(),displayName:o(),reviewsAccess:T9.nullable(),reviewsAccessReason:o().nullable(),reviewsCheckedAt:o().nullable(),rating:m().nullable(),reviewCount:m().int().nonnegative().nullable(),ratingOrigin:v2.nullable(),ratingObservedAt:o().nullable()});d({negativeMaxStars:m().int().min(1).max(4),locations:y(R9),reviews:y(E9),total:m().int().nonnegative()});d({scope:d({locationName:o().nullable(),locationCount:m().int().nonnegative()}),performance:d({totals:Qe(o(),m()),recent7d:Qe(o(),m()),prior7d:Qe(o(),m()),deltaPct:Qe(o(),Oe().nullable())}),freshness:d({dataThroughDate:o().nullable(),latestStoredDate:o().nullable(),pendingDays:m().int().nonnegative()}),timeseries:y(d({date:o(),pending:_(),metrics:Qe(o(),m())})),keywords:d({total:m().int().nonnegative(),thresholdedCount:m().int().nonnegative(),thresholdedPct:Oe(m().min(0).max(100))}),placeActions:d({total:m().int().nonnegative(),hasReservationCta:_(),hasBookingCta:_(),hasDirectMerchantCta:_()}),lodging:d({lodgingLocationCount:m().int().nonnegative(),populatedLodgingCount:m().int().nonnegative(),emptyLodgingCount:m().int().nonnegative()}),profileCompleteness:d({locationCount:m().int().nonnegative(),withSecondaryCategories:m().int().nonnegative(),secondaryCategoryTotal:m().int().nonnegative(),withDescription:m().int().nonnegative(),withServiceArea:m().int().nonnegative(),withHours:m().int().nonnegative(),withPrimaryPhone:m().int().nonnegative(),permanentlyClosed:m().int().nonnegative(),temporarilyClosed:m().int().nonnegative()})});const D9={BUSINESS_DIRECTION_REQUESTS:"Direction requests",WEBSITE_CLICKS:"Website clicks",CALL_CLICKS:"Call clicks",BUSINESS_BOOKINGS:"Bookings",BUSINESS_CONVERSATIONS:"Conversations",BUSINESS_FOOD_ORDERS:"Food orders",BUSINESS_FOOD_MENU_CLICKS:"Food menu clicks",BUSINESS_IMPRESSIONS_DESKTOP_SEARCH:"Search impressions (desktop)",BUSINESS_IMPRESSIONS_MOBILE_SEARCH:"Search impressions (mobile)",BUSINESS_IMPRESSIONS_DESKTOP_MAPS:"Maps impressions (desktop)",BUSINESS_IMPRESSIONS_MOBILE_MAPS:"Maps impressions (mobile)"};function z9(e){const n=e.replace(/^BUSINESS_/,"").split("_").filter(Boolean).map(r=>r.toLowerCase());if(n.length===0)return e;const i=n.join(" ");return i.charAt(0).toUpperCase()+i.slice(1)}function lee(e){return D9[e]??z9(e)}const I9=["BUSINESS_DIRECTION_REQUESTS","WEBSITE_CLICKS","CALL_CLICKS"],O9=["BUSINESS_IMPRESSIONS_DESKTOP_SEARCH","BUSINESS_IMPRESSIONS_MOBILE_SEARCH","BUSINESS_IMPRESSIONS_DESKTOP_MAPS","BUSINESS_IMPRESSIONS_MOBILE_MAPS"];function cee(e){return I9.includes(e)?"conversion":O9.includes(e)?"reach":"other"}new Set(c2.map(e=>e.toLowerCase()));const q9=4,w2=j(["cli","api","config-file"]);function P9(e){const n=new Set,i=new Set;for(const r of e){if(n.has(r.label)){i.add(r.label);continue}n.add(r.label)}return[...i]}function M9(e,n){return n?e.some(i=>i.label===n):!0}const S2=20,k2=200,B9=d({displayName:o().min(1),canonicalDomain:o().min(1),ownedDomains:y(o().min(1)).optional(),aliases:y(o()).optional(),country:o().length(2),language:o().min(2),tags:y(o()).optional(),labels:Qe(o(),o()).optional(),providers:y(kt).optional(),providerModels:Lg.optional(),providerDispatchModes:Kg.optional(),locations:y(dn).optional(),defaultLocation:o().nullable().optional(),measurement:Gg.optional(),autoExtractBacklinks:_().optional(),qualifiedAliases:y(o().trim().min(1).max(k2)).max(S2).optional(),negativeReviewMaxStars:Fg.nullable().optional(),configSource:w2.optional()});B9.extend({name:o().trim().min(1).max(120)});const L9=d({id:o(),name:o(),displayName:o().optional(),canonicalDomain:o(),ownedDomains:y(o()).default([]),aliases:y(o()).default([]),qualifiedAliases:y(o()).default([]),country:o().length(2),language:o().min(2),tags:y(o()).default([]),labels:Qe(o(),o()).default({}),providers:y(o()).default([]),providerModels:Lg.default({}),providerDispatchModes:Kg.default({}),locations:y(dn).default([]),defaultLocation:o().nullable().optional(),measurement:Gg.default(o2),autoExtractBacklinks:_().default(!1),negativeReviewMaxStars:Fg.nullable().optional(),configSource:w2.default("cli"),configRevision:m().int().positive().default(1),createdAt:o().optional(),updatedAt:o().optional()});d({id:o(),query:o(),createdAt:o()});d({id:o(),keyword:o(),createdAt:o()});d({queries:y(o().trim().min(1)).min(1)});d({keywords:y(o().trim().min(1)).min(1)});d({provider:kt,count:m().int().min(1).max(20).optional()});d({id:o(),domain:o(),createdAt:o()});d({competitors:y(o().trim().min(1)).min(1)});function Md(e){return Ic(e)??e.trim().toLowerCase().replace(/^www\./,"")}function j2(e){const n=[e.canonicalDomain,...e.ownedDomains??[]],i=new Set,r=[];for(const u of n){const h=u.trim();if(!h)continue;const f=Md(h);i.has(f)||(i.add(f),r.push(h))}return r}function $9(e,n){if(!n||n.length===0)return[];const i=e?.trim().toLowerCase()??"",r=new Set,u=[];for(const h of n){const f=h.trim();if(!f)continue;const b=f.toLowerCase();b!==i&&(r.has(b)||(r.add(b),u.push(f)))}return u}function V9(e){const n=[],i=new Set,r=h=>{const f=Qa(h);!f||i.has(f)||(i.add(f),n.push(h))},u=e.displayName?.trim()??"";u&&r(u);for(const h of $9(e.displayName,e.aliases))r(h);for(const h of j2({canonicalDomain:e.canonicalDomain??"",ownedDomains:e.ownedDomains??[]})){const f=Qg(h);if(Qa(f).length>=q9)r(f);else{const b=Md(h);b.includes(".")&&r(b)}}return n}const U9=d({name:o().min(1).max(63).regex(/^[a-z0-9]([a-z0-9-]*[a-z0-9])?$/,{message:"Name must be a lowercase slug (letters, numbers, hyphens)"}),labels:Qe(o(),o()).optional().default({})}),G9=d({preset:o().min(1).optional(),cron:o().min(1).optional(),recurrence:Vg.optional(),timezone:o().optional().default("UTC"),providers:y(kt).optional().default([]),enabled:_().optional()}).refine(e=>[e.preset,e.cron,e.recurrence].filter(n=>n!==void 0).length===1,{message:'Exactly one of "preset", "cron", or "recurrence" must be provided'}).optional(),K9=d({channel:R("webhook"),url:o().url(),events:y(Ug).min(1)}),H9=d({gsc:d({propertyUrl:o()}).optional(),syncSchedule:d({preset:o().optional(),cron:o().optional()}).optional()}).optional(),Hx=y(o().min(1)),Q9=d({displayName:o().min(1),canonicalDomain:o().min(1),ownedDomains:y(o().min(1)).optional().default([]),aliases:y(o().min(1)).optional().default([]),qualifiedAliases:y(o().min(1).max(k2)).max(S2).optional(),country:o().length(2),language:o().min(2),queries:Hx.optional(),keywords:Hx.optional(),competitors:y(o().min(1)).optional().default([]),providers:y(kt).optional().default([]),providerModels:Lg.optional().default({}),providerDispatchModes:Kg.optional(),locations:y(dn).optional().default([]),defaultLocation:o().optional(),measurement:Gg.optional().default(o2),schedule:G9,notifications:y(K9).optional().default([]),google:H9,autoExtractBacklinks:_().optional().default(!1),negativeReviewMaxStars:Fg.optional()}).superRefine((e,n)=>{e.queries!==void 0&&e.keywords!==void 0&&n.addIssue({code:"custom",message:"Use spec.queries; spec.keywords is accepted only as a legacy alias when spec.queries is omitted",path:["keywords"]});const i=P9(e.locations);i.length>0&&n.addIssue({code:"custom",message:`Duplicate location labels are not allowed: ${i.join(", ")}`,path:["locations"]}),M9(e.locations,e.defaultLocation)||n.addIssue({code:"custom",message:`defaultLocation "${e.defaultLocation}" must match a configured location label`,path:["defaultLocation"]})});d({apiVersion:R("canonry/v1"),kind:R("Project"),metadata:U9,spec:Q9});const F9=["branded","non-brand"],Fr=j(F9),Zg=j(["all","branded","non-brand"]);function Z9(e){const n=e.filter(r=>Qa(r).length>0);if(n.length===0)return null;const i=b9(n);return i.keys.size===0?null:{matcher:i,classify(r){return v9(i,r)?"branded":"non-brand"}}}const Y9=2,X9=o().regex(/^[a-f0-9]{64}$/),um=o().trim().min(1).max(256),Qx=j(["sensitive","insensitive"]),ge=o().trim().min(1).max(128).regex(/^[a-z0-9][\w.~-]*$/i,"Must be a URL-safe stable key"),J9=o().trim().min(1).refine(e=>Ic(e)!==null,"A competitor domain must be a valid hostname"),W9=Le("kind",[d({kind:R("exact"),url:o().min(1),pathCase:Qx}).strict(),d({kind:R("prefix"),host:o().min(1),pathPrefix:o().min(1),pathCase:Qx}).strict(),d({kind:R("host"),host:o().min(1)}).strict()]),eI=d({canonicalHost:o().min(1),ownedHosts:y(o().min(1)),names:y(o().min(1))}).strict(),tI=d({projectBrand:eI}).strict(),nI=d({stableKey:ge,label:o().trim().min(1),aliases:y(o().min(1)),identityAliases:y(o().trim().min(1)).optional(),urlMatchers:y(W9),mentionNotApplicable:_(),discoveryIdentity:o().min(1).nullable()}).strict(),A2=d({stableKey:ge,label:o().trim().min(1),domain:J9,aliases:y(o().min(1))}).strict(),aI=d({stableKey:ge,label:o().trim().min(1),parentGroupKey:ge.optional(),targetKeys:y(ge),competitors:y(A2)}).strict(),iI=j(["manual","query-set","template","discovery","research"]),sI=d({templateId:o().trim().min(1).max(256),templateVersion:o().trim().min(1).max(256),template:o().trim().min(1).max(4e3),bindings:Qe(o().trim().min(1).max(128),o().trim().min(1).max(128)),output:o().trim().min(1).max(4e3)}).strict(),C2=d({source:iI,sourceId:o().min(1).nullable(),capturedAt:o().datetime(),template:sI.optional()}).strict(),oI=d({queryId:um,queryText:o().min(1),provenance:C2}).strict(),dm=d({providers:y(kt).min(1),models:Qe(kt,o().min(1)),location:dn.nullable()}).strict(),rI=d({stableKey:o().min(1),queryId:um,queryText:o().min(1),context:dm,expectedSnapshots:m().int().nonnegative()}).strict(),Yg=Fr,lI=d({targetKey:ge,queryId:um,queryClass:Yg,classificationSource:j(["server","operator"]).optional(),executionNodeKey:o().min(1)}).strict(),Xg=d({executionNodeKey:o().min(1),targetKey:ge,queryId:um}).strict(),N2=d({stableKey:ge,label:o().trim().min(1),kind:R("market"),groupKey:ge.optional(),usageEdges:y(Xg)}).strict();function Fx(e){return[e.executionNodeKey,e.targetKey,e.queryId].join("\0")}const mm=d({schemaVersion:R(Y9),identities:tI,targets:y(nI),groups:y(aI),querySnapshots:y(oI),assignments:y(lI),executionNodes:y(rI),usageEdges:y(Xg),reportingScopes:y(N2).optional(),compiledChecksum:X9}).strict().superRefine((e,n)=>{const i=new Set;for(const b of e.executionNodes)i.has(b.stableKey)&&n.addIssue({code:ye.custom,path:["executionNodes"],message:`Duplicate execution node key "${b.stableKey}"`}),i.add(b.stableKey);const r=new Set(e.targets.map(b=>b.stableKey));e.usageEdges.forEach((b,v)=>{i.has(b.executionNodeKey)||n.addIssue({code:ye.custom,path:["usageEdges",v,"executionNodeKey"],message:`Usage edge references unknown execution node "${b.executionNodeKey}"`}),r.has(b.targetKey)||n.addIssue({code:ye.custom,path:["usageEdges",v,"targetKey"],message:`Usage edge references unknown Target "${b.targetKey}"`})});const u=new Set(e.usageEdges.map(Fx)),h=new Set;e.reportingScopes?.forEach((b,v)=>{if(h.has(b.stableKey)&&n.addIssue({code:ye.custom,path:["reportingScopes",v,"stableKey"],message:`Duplicate reporting scope key "${b.stableKey}"`}),h.add(b.stableKey),b.groupKey!==void 0){const S=e.groups.find(k=>k.stableKey===b.groupKey);(!S||b.usageEdges.some(k=>!S.targetKeys.includes(k.targetKey)))&&n.addIssue({code:ye.custom,path:["reportingScopes",v,"groupKey"],message:"A market must link to an existing group containing all its assigned properties."})}const x=new Set;b.usageEdges.forEach((S,k)=>{const T=Fx(S);u.has(T)||n.addIssue({code:ye.custom,path:["reportingScopes",v,"usageEdges",k],message:`Reporting scope "${b.stableKey}" references a usage edge that this revision does not contain.`}),x.has(T)&&n.addIssue({code:ye.custom,path:["reportingScopes",v,"usageEdges",k],message:`Reporting scope "${b.stableKey}" repeats a usage edge.`}),x.add(T)})}),e.assignments.forEach((b,v)=>{r.has(b.targetKey)||n.addIssue({code:ye.custom,path:["assignments",v,"targetKey"],message:`Assignment references unknown Target "${b.targetKey}"`})});const f=new Map;e.groups.forEach((b,v)=>{f.has(b.stableKey)&&n.addIssue({code:ye.custom,path:["groups",v,"stableKey"],message:"Duplicate group stable key "+b.stableKey}),f.set(b.stableKey,b)}),e.groups.forEach((b,v)=>{const x=b.parentGroupKey;if(x===void 0)return;if(x===b.stableKey){n.addIssue({code:ye.custom,path:["groups",v,"parentGroupKey"],message:"A group cannot be its own parent."});return}const S=f.get(x);if(!S){n.addIssue({code:ye.custom,path:["groups",v,"parentGroupKey"],message:"Group parent does not exist: "+x});return}const k=new Set(S.targetKeys);b.targetKeys.forEach((I,P)=>{k.has(I)||n.addIssue({code:ye.custom,path:["groups",v,"targetKeys",P],message:"Group target membership must be a subset of its parent."})});const T=new Set([b.stableKey]);let N=S;for(;N.parentGroupKey!==void 0;){if(T.has(N.stableKey)){n.addIssue({code:ye.custom,path:["groups",v,"parentGroupKey"],message:"Group parent relationships cannot contain a cycle."});break}T.add(N.stableKey);const I=f.get(N.parentGroupKey);if(!I)break;N=I}});for(const b of e.groups)for(const v of b.targetKeys)r.has(v)||n.addIssue({code:ye.custom,path:["groups"],message:`Group "${b.stableKey}" references unknown Target "${v}"`})}),Jg=100;function Pr(e){return d({items:y(e),nextCursor:o().min(1).nullable(),totalEstimate:m().int().nonnegative().optional()}).strict()}const Oc=j(["no_completed_run","plan_v1","no_population","evidence_incomplete","identity_ambiguous","not_applicable"]),wn=Le("state",[d({state:R("available"),value:we(),numerator:m().int().nonnegative().optional(),denominator:m().int().positive().optional(),unattributed:m().int().positive().optional()}).strict(),d({state:R("unavailable"),reason:Oc}).strict()]),jc=Le("state",[d({state:R("available"),value:m().int().nonnegative(),numerator:m().int().nonnegative().optional(),denominator:m().int().positive().optional()}).strict(),d({state:R("unavailable"),reason:Oc}).strict()]),Wg=j(["all","group","property"]),qa=Zg,cI=j(["label-asc","label-desc","citationCoverage-asc","citationCoverage-desc","mentionCoverage-asc","mentionCoverage-desc"]),e0=j(["not_measured","queued","running","complete","partial","failed"]),uI=j(["run_measurement","review_flags","complete_setup","republish_setup","none"]);d({scope:Wg,groupKey:ge.optional(),targetKey:ge.optional(),queryClass:qa.optional(),provider:kt.optional(),location:o().trim().min(1).optional(),from:o().trim().min(1).optional(),to:o().trim().min(1).optional(),runId:o().trim().min(1).optional(),search:o().optional(),sort:cI.optional(),cursor:o().trim().min(1).optional(),limit:m().int().positive().max(Jg).optional()}).strict();const dI=d({provider:kt,mentionCoverage:wn,citationCoverage:wn}).strict(),mI=d({bothSignals:m().int().nonnegative(),mentionedOnly:m().int().nonnegative(),citedOnly:m().int().nonnegative(),neither:m().int().nonnegative(),notMeasured:m().int().nonnegative(),total:m().int().nonnegative()}).strict(),Kf=d({groupKey:ge,label:o().trim().min(1)}).strict(),pI=d({targetKey:ge,label:o().min(1),metro:Kf.nullable().optional(),otherMetros:y(Kf).min(1).optional(),mentionCoverage:wn,citationCoverage:wn,providers:y(dI),flags:m().int().nonnegative()}).strict(),hI=d({kind:j(["project","competitor"]),stableKey:o().min(1),label:o().min(1),domain:o().min(1),credits:m().int().nonnegative(),share:we(m().min(0).max(1))}).strict(),fI=d({groupKey:ge,queryClass:R("non-brand"),denominator:m().int().positive(),entries:y(hI)}).strict();d({mode:j(["active-v1","active-v2"]),scope:d({kind:Wg,key:o().min(1).optional(),label:o().min(1)}).strict(),queryClass:qa,measurement:d({state:e0,currentRunId:o().min(1).optional(),displayedRunId:o().min(1).optional(),completed:m().int().nonnegative(),expected:m().int().nonnegative(),completedAt:o().datetime().optional(),includesHistoricalData:_().optional()}).strict(),nextAction:d({kind:uI,count:m().int().nonnegative().optional()}).strict(),metrics:d({propertiesMentioned:jc,mentionCoverage:wn,citationCoverage:wn,brandPresence:wn,sov:wn.describe("Deprecated alias of brandPresence carrying the identical value. Remove once the browser migrates.")}).strict(),properties:Pr(pI),outcomes:mI,flags:d({total:m().int().nonnegative()}).strict(),namedShareOfVoice:fI.optional()}).strict();const _2=j(["sources","answers"]),gI=_2.enum;gI.sources;d({targetKey:ge,queryClass:qa.optional(),provider:kt.optional(),location:o().trim().min(1).optional(),runId:o().trim().min(1).optional(),shape:_2.optional(),cursor:o().trim().min(1).optional(),limit:m().int().positive().max(Jg).optional()}).strict();const T2=1,qc=m().int().positive(),gn=o().trim().min(1).max(128).regex(/^[a-z0-9][\w.~-]*$/i,"Must be a URL-safe stable key"),Pc=o().trim().min(1).max(256),Zx=j(["sensitive","insensitive"]);function Bd(e){const n=Ic(e);if(!n)throw new Error(`Invalid measurement host: ${e}`);return n}function yI(e){const n=[];let i=!1;for(let r=0;r<e.length;r++){const u=e[r];u==="/"?(i||n.push(u),i=!0):(n.push(u),i=!1)}for(;n.length>1&&n.at(-1)==="/";)n.pop();return n.length?n.join(""):"/"}function Yx(e){try{return decodeURI(e).normalize("NFC").toLowerCase()}catch{return e.normalize("NFC").toLowerCase()}}function E2(e){const n=new URL(`https://measurement.invalid${e}`).pathname;return yI(n.replace(/%[0-9a-f]{2}/gi,i=>i.toUpperCase()))}function Hf(e){const n=e.trim();if(!n||n.includes("?")||n.includes("#")||n.includes("://")||n.includes("\\"))throw new Error(`Invalid measurement path prefix: ${e}`);const i=n.startsWith("/")?n:`/${n}`;for(const r of i.split("/")){let u;try{u=decodeURIComponent(r)}catch{throw new Error(`Invalid measurement path prefix: ${e}`)}if(u==="."||u==="..")throw new Error(`Invalid measurement path prefix: ${e}`)}try{return E2(i)}catch{throw new Error(`Invalid measurement path prefix: ${e}`)}}function bI(e){const n=/^[a-z][a-z0-9+.-]*:\/\/[^/?#]*/i.exec(e);if(!n)throw new Error(`Invalid exact measurement URL: ${e}`);return e.slice(n[0].length).split(/[?#]/,1)[0]||"/"}function Xx(e){const n=e.trim();if(!n||n.includes("\\"))throw new Error(`Invalid exact measurement URL: ${e}`);let i;try{i=new URL(n)}catch{throw new Error(`Invalid exact measurement URL: ${e}`)}if(i.protocol!=="http:"&&i.protocol!=="https:"||i.username||i.password||i.port||i.search||i.hash)throw new Error(`Invalid exact measurement URL: ${e}`);const r=Bd(i.hostname),u=Hf(bI(n));return`https://${r}${u}`}const Ac=o().trim().min(1).refine(e=>{try{return Bd(e),!0}catch{return!1}},"A target URL matcher host must be a valid hostname").overwrite(e=>Bd(e)),vI=o().trim().min(1).refine(e=>{try{return Hf(e),!0}catch{return!1}},"A target URL matcher pathPrefix must be an absolute path without query or fragment").overwrite(e=>Hf(e)),xI=o().trim().min(1).refine(e=>{try{return Xx(e),!0}catch{return!1}},"A target exact matcher must be an HTTP(S) URL without credentials, port, query, or fragment").overwrite(e=>Xx(e)),wI=Le("kind",[d({kind:R("exact"),url:xI,pathCase:Zx}).strict(),d({kind:R("prefix"),host:Ac,pathPrefix:vI,pathCase:Zx}).strict(),d({kind:R("host"),host:Ac}).strict()]),R2=o().trim().min(1).max(256).refine(e=>Qa(e).length>0,"A target alias must contain mention text"),SI=Qe(o().trim().min(1),o()),kI=Ac,D2=d({stableKey:gn,label:o().trim().min(1),urls:y(wI).min(1),aliases:y(R2),metadata:SI.optional()}).strict(),t0=d({stableKey:gn,label:o().trim().min(1),targetKeys:y(gn).min(1),competitors:y(kI).optional()}).strict(),z2=d({targetKey:gn,queryIds:y(Pc).min(1),context:dn.nullable().optional()}).strict();function jI(e,n){return e<n?-1:e>n?1:0}function AI(e,n=i=>i){const i=new Set,r=new Set;for(const u of e){const h=n(u);i.has(h)&&r.add(h),i.add(h)}return r}function af(e,n,i,r,u){for(const h of AI(n,u))e.addIssue({code:"custom",path:[...i],message:`Duplicate ${r}: ${h}`})}function Jx(e){if(e.kind==="host")return{host:e.host,pathname:null};if(e.kind==="prefix")return{host:e.host,pathname:e.pathPrefix};const n=new URL(e.url);return{host:Bd(n.hostname),pathname:E2(n.pathname||"/")}}function CI(e,n,i,r){return e===i||(n==="insensitive"||r==="insensitive")&&Yx(e)===Yx(i)}function NI(e,n){if(e.kind!==n.kind)return!1;const i=Jx(e),r=Jx(n);return i.host!==r.host?!1:e.kind==="host"||n.kind==="host"?!0:CI(i.pathname,e.pathCase,r.pathname,n.pathCase)}function _I(e){const n=new Set;return[...e].sort(jI).filter(i=>{const r=Qa(i);return n.has(r)?!1:(n.add(r),!0)})}const I2=d({schemaVersion:R(T2),targets:y(D2).min(1),groups:y(t0).optional(),targetQuerySelections:y(z2).optional()}).strict().superRefine((e,n)=>{const i=e.groups??[],r=e.targetQuerySelections??[];af(n,e.targets.map(v=>v.stableKey),["targets"],"target stable key"),af(n,i.map(v=>v.stableKey),["groups"],"group stable key");const u=new Set(e.targets.map(v=>v.stableKey)),h=new Set(i.map(v=>v.stableKey));for(const v of u)h.has(v)&&n.addIssue({code:"custom",path:["groups"],message:`Target and group stable keys must be globally unique: ${v}`});const f=new Map,b=[];e.targets.forEach((v,x)=>{for(const S of _I(v.aliases)){const k=Qa(S),T=f.get(k);T&&T!==v.stableKey&&n.addIssue({code:"custom",path:["targets",x,"aliases"],message:`Target alias is already assigned to target ${T}: ${S}`}),f.set(k,v.stableKey)}v.urls.forEach((S,k)=>{b.find(N=>N.targetKey!==v.stableKey&&NI(N.matcher,S))&&n.addIssue({code:"custom",path:["targets",x,"urls",k],message:"Target URL matcher has an equal-specificity cross-target tie"}),b.push({targetKey:v.stableKey,matcher:S})})}),i.forEach((v,x)=>{af(n,v.targetKeys,["groups",x,"targetKeys"],"group target key");for(let S=0;S<v.targetKeys.length;S++){const k=v.targetKeys[S];u.has(k)||n.addIssue({code:"custom",path:["groups",x,"targetKeys",S],message:`Unknown target: ${k}`})}}),r.forEach((v,x)=>{u.has(v.targetKey)||n.addIssue({code:"custom",path:["targetQuerySelections",x,"targetKey"],message:`Unknown target: ${v.targetKey}`})})});I2.transform(e=>({...e,groups:e.groups??[],targetQuerySelections:e.targetQuerySelections??[]}));d({expectedActiveRevision:qc.nullable(),plan:I2}).strict();const TI=d({queryId:Pc,queryText:o().min(1)}).strict(),n0=d({stableKey:o().min(1),queryText:o().min(1),context:dn.nullable(),expectedSnapshots:m().int().nonnegative()}).strict(),EI=d({kind:R("baseline"),executionNodeKey:o().min(1),queryId:Pc}).strict(),RI=d({kind:R("target"),executionNodeKey:o().min(1),queryId:Pc,targetKey:gn}).strict(),Qf=Le("kind",[EI,RI]),O2=d({code:R("target-alias-prefix-overlap"),message:o().min(1),targetKeys:y(gn).min(1),aliases:y(o().min(1)).min(1)}).strict(),q2=D2.extend({mentionNotApplicable:_()}),P2=d({schemaVersion:R(T2),defaultContext:dn.nullable(),effectiveOwnedHosts:y(Ac),projectCanonicalHost:Ac,projectBrandNames:y(R2),targets:y(q2),groups:y(t0),targetQuerySelections:y(z2),querySnapshots:y(TI),executionNodes:y(n0),usageEdges:y(Qf),warnings:y(O2)}).strict(),DI=P2,M2=Le("schemaVersion",[P2,mm]),a0=o().regex(/^[a-f0-9]{64}$/),i0=o().datetime(),B2=d({schemaVersion:R(1),language:o().min(1).optional(),providers:y(o().min(1)).min(1),models:Qe(o().min(1),o().min(1)),checksum:o().regex(/^[a-f0-9]{64}$/)}).strict(),zI=d({groups:y(gn).optional(),targets:y(gn).optional()}).strict(),II=d({groups:y(gn),targets:y(gn),queries:y(o().min(1)),resolvedTargets:y(gn)}).strict().superRefine((e,n)=>{e.resolvedTargets.length===0&&e.queries.length===0&&n.addIssue({code:"custom",path:["resolvedTargets"],message:"A recorded scope must name something it measured"})});d({stableKey:gn,retiredAt:o().datetime()});d({active:d({revision:qc,checksum:a0,createdAt:i0,plan:M2}).nullable()});d({versions:y(d({revision:qc,checksum:a0,createdAt:i0,active:_()}))});d({version:d({revision:qc,checksum:a0,createdAt:i0,active:_(),plan:M2})});const kd=d({targets:m().int(),groups:m().int(),queries:m().int(),executionNodes:m().int(),usageEdges:m().int(),baselineEdges:m().int(),targetEdges:m().int(),dedupSavings:m().int()}).strict(),OI=j(["invalid-authoring","duplicate-identity","unknown-target","unknown-query","invalid-project-context","unowned-target-url","owned-competitor","target-query-context-conflict","target-url-ownership-tie","target-alias-cross-target-collision","target-alias-project-brand-collision","target-alias-prefix-overlap"]),L2=d({id:OI,severity:j(["fail","warn"]),message:o().min(1),path:y(Ze([o(),m().int()]))}).strict(),qI=d({baseline:m().int().nonnegative(),target:m().int().nonnegative()}).strict(),$2=d({ok:R(!0),checks:y(L2),executionNodes:y(n0),dedupSaved:m().int().nonnegative(),usageEdges:qI,estCostUsd:de(),plan:DI,warnings:y(O2),counts:kd}).strict(),V2=d({ok:R(!1),checks:y(L2).min(1),executionNodes:y(n0).length(0),dedupSaved:R(0),usageEdges:d({baseline:R(0),target:R(0)}).strict(),estCostUsd:de()}).strict();Le("ok",[$2,V2]);const rd=d({targetKey:gn,context:dn.nullable(),queryIds:y(Pc)}).strict();function Wx(e){return d({added:y(e),removed:y(e),changed:y(d({stableKey:gn,before:e,after:e}).strict()),unchanged:y(gn)}).strict()}const PI=$2.extend({diff:d({activeRevision:qc.nullable(),targets:Wx(q2),groups:Wx(t0),querySelections:d({added:y(rd),removed:y(rd),changed:y(d({targetKey:gn,before:rd,after:rd}).strict()),unchanged:y(d({targetKey:gn,context:dn.nullable()}).strict())}).strict(),execution:d({addedNodeKeys:y(o().min(1)),removedNodeKeys:y(o().min(1)),addedUsageEdges:y(Qf),removedUsageEdges:y(Qf),counts:d({before:kd.nullable(),after:kd,delta:kd.nullable()}).strict()}).strict()}).strict()}).strict(),MI=V2.extend({diff:de()}).strict();Le("ok",[PI,MI]);const BI=1,LI=o().refine(e=>e.trim().length>0,{message:"Must not be blank"}),U2=d({displayName:o(),aliases:y(o()),canonicalDomain:o(),ownedDomains:y(o()),qualifiedAliases:y(o()).optional()}).strict(),G2=d({provider:kt.refine(e=>e.trim().length>0,{message:"Provider must not be blank"}),requestedModel:o().nullable()}).strict(),K2=d({domain:o(),label:o(),aliases:y(o())}).strict(),H2=d({queryId:LI,queryText:o(),provenance:o().nullable()}).strict(),$I=H2.extend({queryClass:Fr.nullable()}).strict();function Q2(e,n){const i=new Set;e.engines.forEach((h,f)=>{const b=h.provider.trim().toLocaleLowerCase("en");i.has(b)&&n.addIssue({code:ye.custom,path:["engines",f,"provider"],message:`Duplicate engine provider "${h.provider}"`}),i.add(b)});const r=new Set;e.queries.forEach((h,f)=>{r.has(h.queryId)&&n.addIssue({code:ye.custom,path:["queries",f,"queryId"],message:`Duplicate query id "${h.queryId}"`}),r.add(h.queryId)});const u=new Set;e.competitors?.forEach((h,f)=>{const b=h.domain;u.has(b)&&n.addIssue({code:ye.custom,path:["competitors",f,"domain"],message:`Duplicate competitor domain "${h.domain}"`}),u.add(b)})}d({capturedAt:o().datetime(),identity:U2,country:o(),language:o(),location:dn.nullable(),engines:y(G2).min(1),competitors:y(K2).optional(),queries:y(H2)}).strict().superRefine(Q2);d({schemaVersion:R(BI),capturedAt:o().datetime(),identity:U2,country:o(),language:o(),location:dn.nullable(),engines:y(G2).min(1),competitors:y(K2).optional(),queries:y($I)}).strict().superRefine(Q2);const VI=j(["auto","simple","advanced"]),F2=j(["simple","advanced"]),Z2=j(["branded","non-brand","unknown","all"]),UI=j(["branded","non-brand","unknown"]),s0=j(["project","group","market","property"]),Y2=Le("kind",[d({kind:R("all")}).strict(),d({kind:R("none")}).strict(),d({kind:R("exact"),value:o().trim().min(1)}).strict()]);function GI(e){if(e===void 0||e==="")return{kind:"all"};const n=e.normalize("NFKC").trim();return n===""?{kind:"all"}:n.toLocaleLowerCase("en")==="none"?{kind:"none"}:{kind:"exact",value:n}}const St=o().trim().min(1),Li=o().datetime(),KI={mode:VI.default("auto"),queryClass:Z2.default("non-brand"),scope:s0.default("project"),scopeKey:St.optional(),marketKey:St.optional(),provider:St.optional(),model:St.optional(),location:o().trim().min(1).optional(),from:Li.optional(),to:Li.optional(),revision:m().int().positive().optional(),runId:St.optional(),queryKey:St.optional(),queryId:St.optional(),search:o().trim().min(1).optional(),cursor:St.optional(),limit:m().int().min(1).max(100).default(50)},Ld=d(KI).strict().superRefine((e,n)=>{e.scope!=="project"&&e.scopeKey===void 0&&n.addIssue({code:ye.custom,path:["scopeKey"],message:`scopeKey is required for ${e.scope} scope`}),e.scope==="project"&&e.scopeKey!==void 0&&n.addIssue({code:ye.custom,path:["scopeKey"],message:"scopeKey is not valid for project scope"}),e.scope==="market"&&e.marketKey!==void 0&&n.addIssue({code:ye.custom,path:["marketKey"],message:"marketKey is not valid for market scope"}),e.from!==void 0&&e.to!==void 0&&e.from>e.to&&n.addIssue({code:ye.custom,path:["to"],message:"to must be on or after from"}),e.queryKey!==void 0&&e.queryId!==void 0&&n.addIssue({code:ye.custom,path:["queryId"],message:"queryKey and queryId cannot both be supplied"})});Ld.transform(e=>({...e,location:GI(e.location)}));const za=d({numerator:m().int().nonnegative().nullable(),denominator:m().int().nonnegative().nullable(),rate:we(m().min(0).max(1)).nullable(),reason:j(["no-population","incomplete","evidence-incomplete","identity-ambiguous","not-applicable"]).optional(),unattributed:m().int().positive().optional()}).strict().superRefine((e,n)=>{if(e.numerator===null||e.denominator===null||e.rate===null){(e.numerator!==null||e.denominator!==null||e.rate!==null||e.reason===void 0)&&n.addIssue({code:ye.custom,message:"Unavailable rates require null values and a reason"}),e.unattributed!==void 0&&n.addIssue({code:ye.custom,path:["unattributed"],message:"Only an available rate can leave answers out"});return}e.reason!==void 0&&n.addIssue({code:ye.custom,message:"Available rates cannot carry a reason"});const{numerator:r,denominator:u}=e;u===null||r===null||(u===0&&n.addIssue({code:ye.custom,path:["denominator"],message:"Available rates require a positive denominator"}),r>u&&n.addIssue({code:ye.custom,path:["numerator"],message:"Numerator cannot exceed denominator"}))}),X2=Le("kind",[d({kind:R("frozen-simple"),definitionRevision:de()}).strict(),d({kind:R("legacy-simple"),definitionRevision:de()}).strict(),d({kind:R("frozen-advanced"),definitionRevision:m().int().positive()}).strict(),d({kind:R("unsupported-advanced-v1"),definitionRevision:m().int().positive()}).strict()]),$d=d({id:St,label:o().trim().min(1),kind:s0,targetCount:m().int().nonnegative(),parentGroupIds:y(St).optional(),marketKeys:y(St).optional()}).strict(),HI=d({provider:St,model:St}).strict(),QI=d({providers:y(St),models:y(HI),locations:y(Y2)}).strict(),FI=d({queryCount:m().int().nonnegative(),answerCount:m().int().nonnegative(),mentionCoverage:za,citationCoverage:za,propertyReach:za,outcomes:d({bothSignals:m().int().nonnegative(),mentionedOnly:m().int().nonnegative(),citedOnly:m().int().nonnegative(),neither:m().int().nonnegative(),notMeasured:m().int().nonnegative(),total:m().int().nonnegative()}).strict().superRefine((e,n)=>{e.bothSignals+e.mentionedOnly+e.citedOnly+e.neither+e.notMeasured!==e.total&&n.addIssue({code:ye.custom,message:"Outcome partition must sum to total"})})}).strict(),ZI=d({runId:St,createdAt:Li,revision:m().int().positive().nullable(),provenance:X2,queryCount:m().int().nonnegative(),answerCount:m().int().nonnegative(),mentionCoverage:za,citationCoverage:za,continuity:d({state:j(["first","comparable","definition-changed","model-changed","legacy-unknown"]),comparedRunId:o().nullable()}).strict()}).strict(),YI=d({sourceSnapshotIds:y(St).default([]),queryKey:St,queryId:o().nullable(),query:o(),provider:St,model:o().nullable(),location:o().nullable(),targetKeys:y(St),marketKeys:y(St).optional(),answerCount:m().int().nonnegative(),mentionCoverage:za,citationCoverage:za}).strict(),XI=d({answerId:St,runId:St,queryKey:St,query:o(),provider:St,model:o().nullable(),location:o().nullable(),targetKeys:y(St),mentioned:_().nullable(),mentionUnavailableReason:R("identity-ambiguous").optional(),cited:_().nullable(),answerText:o().nullable(),createdAt:Li,sources:y(o()),observedCompetitors:y(St)}).strict(),JI=d({domain:St,answerCount:m().int().nonnegative(),mentionCoverage:za,citationCoverage:za}).strict(),WI=d({name:St,answerCount:m().int().nonnegative()}).strict(),eO=Le("state",[d({state:R("available")}).strict(),d({state:R("unavailable"),reason:R("frozen-competitor-identity-missing")}).strict()]),ew=d({id:St,label:o().trim().min(1),queryCount:m().int().nonnegative(),mentionCoverage:za,citationCoverage:za}).strict();function tw(e){return d({items:y(e),nextCursor:o().nullable(),total:m().int().nonnegative()}).strict()}const J2=j(["current-unavailable","previous-unavailable","not-applicable"]),uee=J2.enum,sf=Le("state",[d({state:R("available"),previous:za,delta:we(m().min(-1).max(1))}).strict(),d({state:R("unavailable"),reason:J2}).strict()]),nw=d({id:St,createdAt:Li,completedAt:Li.nullable()}).strict(),W2=j(["no-selected-run","no-previous-run","scoped-run","partial-run","definition-changed","model-changed","legacy-unknown"]),dee=W2.enum,tO=Le("state",[d({state:R("available"),previousRun:nw,mentionCoverage:sf,citationCoverage:sf,propertyReach:sf}).strict(),d({state:R("unavailable"),reason:W2,previousRun:nw.nullable()}).strict()]),ej=d({queryClass:UI,summary:FI,trend:y(ZI),comparison:tO.optional(),queries:tw(YI),evidence:tw(XI),competitorAvailability:eO,competitors:y(JI),observedCompetitors:y(WI),breakdown:d({properties:y(ew),groups:y(ew)}).strict()}).strict(),nO=j(["measured","not-measured","partial"]),aO=d({state:nO,activeRevision:m().int().positive().nullable(),measuredRevision:m().int().positive().nullable(),awaitingSweep:_(),pendingAssignmentCount:m().int().nonnegative(),completedAt:Li.nullable()}).strict(),tj=d({mode:F2,queryClass:Z2,scope:$d,market:$d.optional(),provider:o().nullable(),model:o().nullable(),location:Y2,time:d({from:Li.nullable(),to:Li.nullable()}).strict(),revision:m().int().positive().nullable(),run:d({id:o().nullable(),explicit:_()}).strict(),provenance:X2,measurement:aO,availability:Le("state",[d({state:R("available")}).strict(),d({state:R("unsupported"),reason:R("advanced-v1")}).strict()])}).strict();d({selection:tj,scopeOptions:y($d),filterOptions:QI,populations:y(ej).min(1)}).strict().superRefine((e,n)=>{const i=e.selection.queryClass==="all"?["branded","non-brand","unknown"]:[e.selection.queryClass],r=e.populations.map(u=>u.queryClass);(r.length!==i.length||r.some((u,h)=>u!==i[h]))&&n.addIssue({code:ye.custom,path:["populations"],message:"Populations must exactly match the selected query class order"});for(const[u,h]of e.populations.entries()){const f=h.comparison;if(f?.state==="available")for(const b of["mentionCoverage","citationCoverage","propertyReach"]){const v=f[b];if(v.state!=="available")continue;const x=["populations",u,"comparison",b],S=h.summary[b].rate,k=v.previous.rate;S===null&&n.addIssue({code:ye.custom,path:x,message:"Available changes require a current rate"}),k===null&&n.addIssue({code:ye.custom,path:[...x,"previous","rate"],message:"Available changes require a previous rate"}),S!==null&&k!==null&&Math.abs(v.delta-(S-k))>Number.EPSILON&&n.addIssue({code:ye.custom,path:[...x,"delta"],message:"Delta must equal current minus previous"}),e.selection.run.id===null&&n.addIssue({code:ye.custom,path:x,message:"Available changes require a selected run"})}}});const nj=j(["retired-scope","retired-market"]),iO=nj.enum,sO=d({reason:nj,kind:s0.exclude(["project"]),key:St}).strict().superRefine((e,n)=>{e.reason===iO["retired-market"]&&e.kind!=="market"&&n.addIssue({code:ye.custom,path:["kind"],message:"retired-market details must name a market"})});function mee(e){const n=sO.safeParse(e);return n.success?n.data:void 0}function oO(e,n){let i=e;for(const[r,u]of Object.entries(n))i=i.split(`{${r}}`).join(u);return i.trim()}const o0=o().regex(/^[a-f0-9]{64}$/),ma=o().trim().min(1).max(256),Fa=o().trim().min(1).max(4e3),r0=o().datetime(),pm=o().regex(/^qtw_[a-f0-9]{64}$/),aj=o().regex(/^qtp_[a-f0-9]{64}$/),l0=j(["simple","advanced"]),ij=d({templateId:ma,templateVersion:o().trim().min(1).max(256),template:Fa,bindings:Qe(o().trim().min(1).max(128),o().trim().min(1).max(128)),output:Fa}).strict(),rO=d({source:j(["manual","query-set","template","research","discovery"]),sourceId:ma.nullable(),capturedAt:o().datetime(),template:ij.optional()}).strict().superRefine((e,n)=>{e.source==="template"&&e.template===void 0&&n.addIssue({code:ye.custom,path:["template"],message:"Template provenance is required for a template query."}),e.source!=="template"&&e.template!==void 0&&n.addIssue({code:ye.custom,path:["template"],message:"Only a template query may carry template provenance."})}),lO=Le("source",[d({source:R("manual"),text:Fa}).strict(),d({source:R("template"),templateId:ma,templateVersion:o().trim().min(1).max(256),template:Fa}).strict(),d({source:R("research"),researchRunQueryId:ma}).strict(),d({source:R("discovery"),discoveryProbeId:ma}).strict()]),c0=d({targetKeys:y(ge).optional(),groupKeys:y(ge).optional(),marketKeys:y(ge).optional()}).strict(),cO=d({providers:y(kt).min(1),models:Qe(kt,o().trim().min(1)),location:o().trim().min(1).nullable()}).strict(),uO=d({input:lO,audience:c0.optional(),contexts:y(cO).min(1).optional(),queryClass:Fr.optional()}).strict(),dO=d({queryId:ma.optional(),queryText:Fa.optional(),audience:c0.optional()}).strict().superRefine((e,n)=>{e.queryId===void 0==(e.queryText===void 0)&&n.addIssue({code:ye.custom,message:"Provide exactly one of queryId or queryText."})}),mO=d({queryId:ma,audience:c0.optional(),text:Fa.optional(),queryClass:Ze([Fr,de()]).optional()}).strict().superRefine((e,n)=>{e.text===void 0&&e.queryClass===void 0&&n.addIssue({code:ye.custom,message:"Provide query text or a classification change."})}),pO=d({additions:y(uO),removals:y(dO),edits:y(mO).optional()}).strict(),hO=pO.extend({expectedWorkspaceVersion:pm}).strict();hO.extend({previewToken:aj,reviewedAt:r0}).strict();const fO=d({stableKey:ge,label:o().trim().min(1)}).strict(),gO=d({stableKey:ge,parentGroupKey:ge.optional(),label:o().trim().min(1),targetKeys:y(ge)}).strict(),yO=d({stableKey:ge,groupKey:ge.optional(),label:o().trim().min(1),usageEdges:y(Xg)}).strict(),bO=d({targetKey:ge,groupKeys:y(ge),marketKeys:y(ge),queryClass:Fr.nullable(),classificationSource:j(["frozen","server","operator"]),contexts:y(dm).min(1)}).strict(),sj=d({queryId:ma,queryText:Fa,normalizedText:Fa,provenance:rO.nullable(),state:j(["tracked","awaiting-sweep"]),lastMeasuredAt:o().datetime().nullable(),assignments:y(bO)}).strict(),vO=d({researchRunId:ma,researchRunQueryId:ma,queryText:Fa,createdAt:o().datetime()}).strict(),xO=d({discoverySessionId:ma,discoveryProbeId:ma,queryText:Fa,createdAt:o().datetime()}).strict();d({mode:l0,workspaceVersion:pm,active:d({revision:m().int().positive(),compiledChecksum:o0}).strict().nullable(),defaultContexts:y(dm),targets:y(fO),groups:y(gO),markets:y(yO),scopeOptions:y($d).optional(),tracked:y(sj),savedSources:d({research:y(vO),discovery:y(xO)}).strict()}).strict();const ld=d({queryId:ma,queryText:Fa,assignmentCount:m().int().nonnegative()}).strict(),oj=d({added:y(ld),removed:y(ld),reused:y(ld),unchanged:y(ld),noOp:_()}).strict(),rj=d({existingNodes:m().int().nonnegative(),existingProviderCalls:m().int().nonnegative(),nextSweepNodes:m().int().nonnegative(),nextSweepProviderCalls:m().int().nonnegative(),addedNodes:m().int().nonnegative(),addedProviderCalls:m().int().nonnegative(),removedNodes:m().int().nonnegative(),removedProviderCalls:m().int().nonnegative()}).strict();d({mode:l0,workspaceVersion:pm,previewToken:aj,reviewedAt:r0,active:d({revision:m().int().positive(),compiledChecksum:o0}).strict().nullable(),tracked:y(sj),diff:oj,workload:rj}).strict();d({committed:_(),mode:l0,workspaceVersion:pm,reviewedAt:r0,active:d({revision:m().int().positive(),compiledChecksum:o0}).strict().nullable(),diff:oj,workload:rj}).strict();const hm=j(["complete","partial","failed","unsupported"]);hm.enum;j(["proposed","alias","shared","unmatched","excluded"]);j(["primary-match","exact-slug-match","excluded-slug","shared-path","unmatched-path","alias-without-primary","unsupported-slug"]);const wO=j(["invalid-url","unowned-host","duplicate-url","url-cap-reached"]),SO=d({kind:j(["exact","prefix","suffix","contains"]),value:o().trim().min(1)}).strict(),aw=d({host:o().trim().min(1),pathTemplate:o().trim().min(1)}).strict(),u0=d({primary:aw,aliases:y(aw).optional(),excludedSlugSuffixes:y(o().trim().min(1)).optional(),excludedSlugPatterns:y(SO).optional()}).strict();d({sitemapUrl:o().url().refine(e=>{try{const n=new URL(e).protocol;return n==="http:"||n==="https:"}catch{return!1}},"Sitemap URL must use http or https"),rule:u0,maxUrls:m().int().positive().max(1e4).optional()}).strict();const of=d({url:o(),canonicalUrl:o().nullable(),classification:j(["shared","unmatched","excluded"]),reason:j(["excluded-slug","shared-path","unmatched-path","alias-without-primary","unsupported-slug"])}).strict().superRefine((e,n)=>{({shared:["shared-path"],unmatched:["unmatched-path","alias-without-primary","unsupported-slug"],excluded:["excluded-slug"]})[e.classification].includes(e.reason)||n.addIssue({code:"custom",message:"Discovery classification and reason do not match"})}),kO=d({classification:R("proposed"),reason:R("primary-match"),stableKey:gn,slug:o().trim().min(1),label:o().trim().min(1),primaryUrl:o().url(),aliasCoverageUrls:y(o().url())}).strict(),jO=d({classification:R("alias"),reason:R("exact-slug-match"),slug:o().trim().min(1),url:o().url(),targetStableKey:gn}).strict(),AO=d({kind:wO,url:o(),canonicalUrl:o().nullable(),duplicateOf:o().optional()}).strict();d({proposed:y(kO),aliases:y(jO),shared:y(of),unmatched:y(of),excluded:y(of),diagnostics:y(AO)}).strict().superRefine((e,n)=>{const i=[["shared",["shared"]],["unmatched",["unmatched"]],["excluded",["excluded"]]];for(const[r,u]of i)for(const h of e[r])u.includes(h.classification)||n.addIssue({code:"custom",path:[r],message:"Discovery item is in the wrong result bucket"})});const d0=j(["assigned","sibling","ownedUnmapped","external","ambiguous","invalid"]),lj=j(["baseline","target"]),cj=j(["incomplete","evidence-incomplete","identity-ambiguous","no-population","aliasless","no-competitors","no-project-aliases"]),Ao=Ze([d({numerator:m().int().nonnegative(),denominator:m().int().positive(),rate:we(m().min(0).max(1)),unattributed:m().int().positive().optional()}).strict(),d({numerator:de(),denominator:de(),rate:de(),reason:cj}).strict()]).superRefine((e,n)=>{e.numerator!==null&&e.numerator>e.denominator&&n.addIssue({code:"custom",path:["numerator"],message:"Rate numerator cannot exceed denominator"})}),CO=o().trim().min(1).overwrite(e=>e.toLocaleLowerCase("en")),NO=d({executionId:o().trim().min(1),queryText:o().trim().min(1),provider:CO,context:dn.nullable(),requestedModel:o().trim().min(1).optional()}).strict();d({schemaVersion:R(1),expectedSlots:y(NO)}).strict().superRefine((e,n)=>{const i=new Set;for(const[r,u]of e.expectedSlots.entries()){const h=[u.executionId,u.provider].join("\0");i.has(h)&&n.addIssue({code:"custom",path:["expectedSlots",r],message:"Duplicate expected provider slot"}),i.add(h)}});const fm=d({executed:m().int().nonnegative(),expected:m().int().nonnegative(),complete:_(),sourceComplete:_(),sourceCompleteObservations:m().int().nonnegative(),answerComplete:_()}).strict(),iw=Ze([d({domain:o().trim().min(1),own:_(),presentIn:m().int().nonnegative(),of:m().int().positive()}).strict(),d({domain:o().trim().min(1),own:_(),presentIn:de(),of:de(),reason:cj}).strict()]),_O=d({domains:y(iw),providers:y(d({provider:kt,domains:y(iw)}).strict())}).strict(),TO=d({provider:kt,completeness:fm,answerCoverage:Ao}).strict(),EO=d({id:o().trim().min(1),label:o().trim().min(1),targetIds:y(o().trim().min(1)),completeness:fm,answerCoverage:Ao,targetCoverage:Ao,sov:_O,providers:y(TO)}).strict(),RO=d({provider:kt,completeness:fm,citationCoverage:Ao,mentionCoverage:Ao}).strict(),DO=d({id:o().trim().min(1),label:o().trim().min(1),completeness:fm,citationCoverage:Ao,mentionCoverage:Ao,providers:y(RO)}).strict(),uj=d({observationId:o().trim().min(1),expectedSlotId:o().trim().min(1),executionId:o().trim().min(1),usageEdgeId:o().trim().min(1),usageEdgeType:lj,provider:kt,queryText:o().trim().min(1),location:o().nullable(),sourceUrl:o(),bridged:_(),historical:_(),evidenceComplete:_(),classification:d0,normalizedUrl:o().nullable(),matchedTargetIds:y(o().trim().min(1)),matchedUrlIds:y(o().trim().min(1))}).strict(),zO=d({sourceUrl:o(),normalizedUrl:o().nullable(),classification:d0,matchedTargetIds:y(o().trim().min(1)),matchedUrlIds:y(o().trim().min(1))}).strict(),IO=d({observationId:o().trim().min(1),expectedSlotId:o().trim().min(1),executionId:o().trim().min(1),usageEdgeId:o().trim().min(1),usageEdgeType:lj,provider:kt,queryText:o().trim().min(1),location:o().nullable(),queryClass:Ze([j(["branded","non-brand"]),de()]),mentioned:_().nullable(),cited:_().nullable(),sources:y(zO),sourceCount:m().int().nonnegative(),sourcesTruncated:_(),bridged:_(),historical:_(),evidenceComplete:_()}).strict(),OO=d({bridgedObservationIds:y(o()),historicalObservationIds:y(o()),evidenceIncompleteObservationIds:y(o()),ambiguousObservationIds:y(o()),unmatchedObservationIds:y(o())}).strict(),qO=d({id:o().trim().min(1),status:j(["completed","partial"]),createdAt:o().datetime(),startedAt:o().datetime().nullable(),finishedAt:o().datetime().nullable()}).strict();d({revision:m().int().positive(),run:qO.nullable(),groups:y(EO),targets:y(DO),evidence:y(uj),diagnostics:OO}).strict();d({property:d({targetKey:ge,label:o().min(1)}).strict(),queryClass:qa,measurement:d({state:e0,displayedRunId:o().min(1).optional(),completedAt:o().datetime().optional()}).strict(),evidence:Pr(uj).optional(),answers:Pr(IO).optional()}).strict().refine(e=>e.evidence===void 0!=(e.answers===void 0),{message:"Exactly one of evidence or answers is present, naming the shape that was served."});const ha=j(["queued","running","completed","partial","failed","cancelled"]),Zt=ha.enum,m0=j(["answer-visibility","site-audit","gsc-sync","inspect-sitemap","ga-sync","bing-inspect","bing-inspect-sitemap","backlink-extract","traffic-sync","aeo-discover-seed","aeo-discover-probe","gbp-sync","ads-sync","google-ads-sync","gtm-sync"]),Re=m0.enum;d({kind:m0.optional(),status:ha.optional()});const p0=j(["manual","scheduled","config-apply","backfill","probe"]),ci=p0.enum,$i=j(["cited","not-cited"]),fc=$i.enum,Vd=j(["visible","not-visible"]);Vd.enum;const Cc=j(["mentioned","not-mentioned"]);Cc.enum;const dj=j(["new","cited","lost","emerging","not-cited"]);dj.enum;const PO=j(["new","mentioned","lost","emerging","not-mentioned"]);PO.enum;const MO=j([ci.manual,ci.probe]);d({kind:R(Re["answer-visibility"]).optional(),trigger:MO.optional(),providers:y(kt).optional(),queries:y(o().min(1)).min(1).optional(),measurementScope:zI.optional(),location:o().min(1).optional(),allLocations:_().optional(),noLocation:_().optional(),dispatchMode:zc.optional()}).refine(e=>+!!e.location+ +!!e.allLocations+ +!!e.noLocation<=1,{message:'Only one of "location", "allLocations", or "noLocation" may be provided'});const BO=d({message:o(),raw:jn().optional()}),LO=d({message:o().optional(),providers:Qe(o(),BO).optional()}),$O=Qe(o(),R(zc.enum.batch)),VO=d({id:o(),provider:o(),model:o(),status:r2,requestCount:m().int().nonnegative(),ingestedCount:m().int().nonnegative(),recordedCount:m().int().nonnegative(),submittedAt:o().nullable(),endedAt:o().nullable(),deadlineAt:o(),error:o().nullable()}),UO=d({provider:o(),pricingTier:Hg,answers:m().int().nonnegative(),inputTokens:m().int().nonnegative(),cachedInputTokens:m().int().nonnegative(),cacheWriteTokens:m().int().nonnegative(),outputTokens:m().int().nonnegative(),searchCount:m().int().nonnegative(),estimatedCostMicros:m().int().nonnegative().nullable(),unpricedAnswers:m().int().nonnegative()}),GO=d({id:o(),projectId:o(),kind:m0,status:ha,trigger:p0.default("manual"),measurementPlanVersionId:o().nullable().optional(),measurementManifest:Qe(o(),jn()).nullable().optional(),measurementScope:II.nullable().optional(),measurementExecutionIdentity:B2.nullable().optional(),location:o().nullable().optional(),queries:y(o()).nullable().optional(),startedAt:o().nullable().optional(),finishedAt:o().nullable().optional(),error:LO.nullable().optional(),queryBasketRevision:m().int().nullable().optional(),dispatchModes:$O.optional(),createdAt:o()});function h0(e){if(e.providers){const n=Object.entries(e.providers);if(n.length===1){const[i,r]=n[0];return`${i}: ${r.message}`}if(n.length>1)return n.map(([i,r])=>`${i}: ${r.message}`).join(" • ")}return e.message??"Run failed."}const gm=d({uri:o(),title:o()}),KO=d({status:j(["applied","ignored","browser-implicit","unknown"]),resolved:dn.nullable().optional()}),mj=d({id:o(),runId:o(),queryId:o(),query:o().optional(),provider:kt,citationState:$i,answerMentioned:_().optional(),visibilityState:Vd.optional(),mentionState:Cc.optional(),transition:dj.optional(),answerText:o().nullable().optional(),citedDomains:y(o()).default([]),citedUrls:y(o()).nullable().default(null),captureStatus:Ze([hm,de()]).default(null),sourceCount:m().int().nonnegative().nullable().default(null),resolvedCount:m().int().nonnegative().nullable().default(null),captureVersion:m().int().positive().nullable().default(null),retrievalStatus:Ze([Mg,de()]).default(null),retrievalContract:Ze([Bg,de()]).default(null),competitorOverlap:y(o()).default([]),citedCompetitorDomains:y(o()).default([]),mentionedCompetitorDomains:y(o()).default([]),recommendedCompetitors:y(o()).default([]),matchedTerms:y(o()).default([]),groundingSources:y(gm).default([]),searchQueries:y(o()).default([]),model:o().nullable().optional(),servedModel:o().nullable().optional(),location:o().nullable().optional(),requestedContext:dn.nullable().optional(),supportedContext:KO.nullable().optional(),dispatchMode:Ze([zc,de()]).optional(),stopReason:o().nullable().optional(),usage:Ez.nullable().optional(),createdAt:o()});d({snapshots:y(mj),total:m().int().nonnegative()});const HO=d({queryId:o().nullable(),query:o().nullable(),run1State:$i.nullable(),run2State:$i.nullable(),run1AnswerMentioned:_().nullable(),run2AnswerMentioned:_().nullable(),run1VisibilityState:Vd.nullable(),run2VisibilityState:Vd.nullable(),run1MentionState:Cc.nullable().optional(),run2MentionState:Cc.nullable().optional(),changed:_(),visibilityChanged:_()});d({run1:o(),run2:o(),diff:y(HO)});const QO=GO.extend({snapshots:y(mj).optional(),providerBatches:y(VO).optional(),usage:y(UO).optional()}),FO=d({totalRuns:m().int().nonnegative(),run:QO.nullable()});d({id:o(),projectId:o().nullable().optional(),actor:o(),action:o(),entityType:o(),entityId:o().nullable().optional(),diff:jn().optional(),userAgent:o().nullable().optional(),actorSession:o().nullable().optional(),requestId:o().nullable().optional(),credentialId:o().nullable().optional(),createdAt:o()});const f0=j(["queued","running","completed","partial","failed"]);f0.enum;const pj=j(["not_answer_visibility","not_plan_run","scoped_or_probe","status_not_partial","plan_revision_changed","manifest_unreadable","model_not_frozen","model_retired","provider_not_in_plan","provider_nothing_missing","provider_not_configured","too_old","superseded","quota_insufficient"]);pj.enum;d({providers:y(kt).min(1).optional(),dryRun:_().optional()}).strict();const hj=d({id:o(),runId:o(),projectId:o(),status:f0,providers:y(o()),expected:m().int().nonnegative(),filled:m().int().nonnegative(),error:o().nullable(),createdAt:o(),startedAt:o().nullable(),finishedAt:o().nullable()}),ZO=d({runId:o(),status:ha,planned:_(),readable:_(),expected:m().int().nonnegative(),executed:m().int().nonnegative(),missing:m().int().nonnegative(),missingByProvider:Qe(o(),m().int().nonnegative()),fillable:_(),refusal:d({code:pj,message:o()}).nullable(),latestFill:hj.nullable()}),YO=j(["queued","already-complete","dry-run"]);d({outcome:YO,completeness:ZO,fill:hj.nullable()});const Za=o().trim().min(1),Eo=o().trim().min(1),XO=o().trim().min(1),qe=m().int().nonnegative(),Mc=d({state:e0,displayedRunId:Za.nullable(),planRevision:m().int().positive(),completedAt:o().datetime().nullable()}).strict(),Ro=d({targetKey:ge,label:Eo}).strict(),pa={runId:Za.optional(),provider:kt.optional(),location:XO.optional()},Mr=o().trim().min(1),rf=5,JO=10,WO=10,eq="tied Properties are ordered by name, not ranked";d({runId:pa.runId,groupKey:ge.optional(),queryClass:qa.default("non-brand"),provider:pa.provider,location:pa.location,limit:m().int().positive().max(50).optional(),includeNestedMarkets:_().optional()}).strict();const sw=Kf,fj={metro:sw.nullable(),otherMetros:y(sw).min(1).optional(),submarkets:y(Eo),queries:qe},gj=d({name:Mr,answers:qe}).strict(),tq=d({name:Mr,occurrences:qe}).strict(),g0=d({domain:o().trim().min(1),answers:qe}).strict(),nq=Ro.extend({...fj,mentionCoverage:wn,citationCoverage:wn,flags:qe,namedInsteadInAnswerText:y(gj).max(rf),namedInsteadInAnswerTextTotal:qe,citedDomains:y(g0).max(rf),citedDomainsTotal:qe,recommendedInstead:y(tq).max(rf).meta({deprecated:!0,description:"Deprecated: read namedInsteadInAnswerText, which carries the same names in the same order. occurrences counts answers, exactly as answers does there."}),recommendedInsteadTotal:qe.meta({deprecated:!0,description:"Deprecated: read namedInsteadInAnswerTextTotal, which it always equals."}),recommendedInsteadTruncated:_().meta({deprecated:!0,description:"Deprecated: true when namedInsteadInAnswerTextTotal exceeds the names returned in namedInsteadInAnswerText."})}).strict().superRefine((e,n)=>{e.namedInsteadInAnswerText.length>e.namedInsteadInAnswerTextTotal&&n.addIssue({code:ye.custom,path:["namedInsteadInAnswerTextTotal"],message:"Total cannot be smaller than the returned names"}),e.citedDomains.length>e.citedDomainsTotal&&n.addIssue({code:ye.custom,path:["citedDomainsTotal"],message:"Total cannot be smaller than the returned domains"}),e.recommendedInsteadTotal!==e.namedInsteadInAnswerTextTotal&&n.addIssue({code:ye.custom,path:["recommendedInsteadTotal"],message:"The deprecated total must equal namedInsteadInAnswerTextTotal"}),e.recommendedInstead.length>e.recommendedInsteadTotal&&n.addIssue({code:ye.custom,path:["recommendedInsteadTotal"],message:"Total cannot be smaller than the returned replacements"}),e.recommendedInsteadTruncated!==e.recommendedInstead.length<e.recommendedInsteadTotal&&n.addIssue({code:ye.custom,path:["recommendedInsteadTruncated"],message:"Truncation must agree with the replacement total"})}),aq=d({metro:Eo.nullable(),count:m().int().positive()}).strict(),iq=d({count:m().int().min(2),mentionRate:we(),citationRate:we(),note:R(eq),byMetro:y(aq).optional(),namedInstead:y(gj).max(WO).optional(),namedInsteadTotal:qe.optional()}).strict().superRefine((e,n)=>{e.namedInstead!==void 0&&(e.namedInsteadTotal===void 0||e.namedInstead.length>e.namedInsteadTotal)&&n.addIssue({code:ye.custom,path:["namedInsteadTotal"],message:"Total cannot be smaller than the returned names"})}),sq=d({properties:qe,answers:qe,domains:y(g0).max(JO),domainTotal:qe,ownDomainAnswers:qe.optional()}).strict().superRefine((e,n)=>{e.ownDomainAnswers!==void 0&&e.ownDomainAnswers>e.answers&&n.addIssue({code:ye.custom,path:["ownDomainAnswers"],message:"Own-domain answers cannot exceed the basis"}),e.domains.length>e.domainTotal&&n.addIssue({code:ye.custom,path:["domainTotal"],message:"Total cannot be smaller than the returned domains"}),e.domains.some(i=>i.answers>e.answers)&&n.addIssue({code:ye.custom,path:["domains"],message:"A domain cannot be cited by more answers than the basis holds"})}),oq=d({groupKey:ge,label:Eo,parentGroupKey:ge.nullable(),childMarketCount:qe,propertyCount:qe,propertiesMentioned:jc,mentionCoverage:wn,citationCoverage:wn}).strict(),ow=Ro.extend({...fj,mentionCoverage:wn.options[0],citationCoverage:wn}).strict(),rq=d({eligiblePropertyCount:qe,strongest:y(ow).max(50),weakest:y(ow).max(50),excluded:y(Ro.extend({reason:Oc}).strict()),truncated:_()}).strict();d({portfolio:d({groupKey:ge.nullable(),label:Eo.nullable(),measurementScope:Ze([j(["full","spot_check"]),de()])}).strict(),measurement:Mc,queryClass:qa,engines:y(kt),metrics:d({propertiesMentioned:jc,mentionCoverage:wn,citationCoverage:wn}).strict(),weakestProperties:y(nq),tiedAtWeakest:iq.nullable(),weakestAnswerSources:sq.nullable(),mentionRanking:rq,markets:y(oq),totalMarkets:qe,marketsTruncated:_(),totalProperties:qe,truncated:_()}).strict().superRefine((e,n)=>{e.marketsTruncated!==e.markets.length<e.totalMarkets&&n.addIssue({code:ye.custom,path:["marketsTruncated"],message:"Market truncation must agree with the market total"})});d({targetKey:ge,runId:pa.runId,provider:pa.provider,location:pa.location,queryClass:qa.optional(),offset:m().int().nonnegative().optional(),limit:m().int().positive().max(100).optional()}).strict();j(["answered","missing"]);const Ff={queryId:Za,text:Eo,class:Yg,provider:kt,requestedModel:o().nullable(),servedModel:o().nullable(),location:o().nullable()},lq=Le("status",[d({resultId:Za,...Ff,status:R("answered"),mentioned:_().nullable(),cited:_().nullable(),recommendedInstead:y(Mr),answerExcerpt:o().nullable()}).strict(),d({resultId:de(),...Ff,status:R("missing"),mentioned:de(),cited:de(),recommendedInstead:y(Mr).length(0),answerExcerpt:de()}).strict()]);d({property:Ro,measurement:Mc,queryClass:qa,questions:y(lq),total:qe,truncated:_()}).strict();d({targetKey:ge,resultId:Za}).strict();const cq=d({url:Za,classification:d0,matchedTargetKeys:y(ge),assigned:_(),historical:_(),evidenceComplete:_()}).strict().superRefine((e,n)=>{e.assigned!==(e.classification==="assigned")&&n.addIssue({code:ye.custom,path:["assigned"],message:"Assigned must agree with the source attribution classification"})});d({property:Ro,measurement:Mc,question:d({resultId:Za,...Ff,status:R("answered")}).strict(),mentioned:_().nullable(),cited:_().nullable(),recommendedInstead:y(Mr),answer:o().nullable(),sources:y(cq),captureStatus:Ze([hm,de()]),retrievalStatus:Ze([Mg,de()]),retrievalContract:Ze([Bg,de()])}).strict();d({targetKey:ge,runId:pa.runId,provider:pa.provider,location:pa.location,queryClass:qa.optional(),limit:m().int().positive().max(50).optional()}).strict();const uq=Le("state",[d({state:R("available"),answeredResults:qe,targetMissResults:qe,recommendationOccurrences:qe}).strict(),d({state:R("unavailable"),reason:Oc}).strict()]),dq=d({name:Mr,occurrences:qe,providers:y(kt).max(5),providerTotal:qe,providersTruncated:_(),questions:y(Eo).max(5),questionTotal:qe,questionsTruncated:_()}).strict().superRefine((e,n)=>{(e.providers.length>e.providerTotal||e.questions.length>e.questionTotal)&&n.addIssue({code:ye.custom,message:"Evidence totals cannot be smaller than returned evidence"}),e.providersTruncated!==e.providers.length<e.providerTotal&&n.addIssue({code:ye.custom,path:["providersTruncated"],message:"Provider truncation must agree with its total"}),e.questionsTruncated!==e.questions.length<e.questionTotal&&n.addIssue({code:ye.custom,path:["questionsTruncated"],message:"Question truncation must agree with its total"})}),mq=10;d({property:Ro,measurement:Mc,queryClass:qa,basis:uq,competitors:y(dq),total:qe,truncated:_(),citedDomains:y(g0).max(mq).optional(),citedDomainsTotal:qe.optional(),citedDomainsAnswers:qe.optional()}).strict().superRefine((e,n)=>{const{citedDomains:i,citedDomainsTotal:r,citedDomainsAnswers:u}=e;if(i!==void 0){if(r===void 0||u===void 0){n.addIssue({code:ye.custom,path:["citedDomains"],message:"Cited domains require their total and answer basis"});return}i.length>r&&n.addIssue({code:ye.custom,path:["citedDomainsTotal"],message:"Total cannot be smaller than the returned domains"}),i.some(h=>h.answers>u)&&n.addIssue({code:ye.custom,path:["citedDomains"],message:"A domain cannot be cited by more answers than the basis holds"})}});const yj=j(["magnitude","label"]),pq=2;d({runId:pa.runId,scope:Wg.default("all"),groupKey:ge.optional(),targetKey:ge.optional(),queryClass:qa.default("all"),provider:pa.provider,location:pa.location,limit:m().int().positive().max(50).optional(),sort:yj.optional()}).strict().superRefine((e,n)=>{e.scope==="all"&&(e.groupKey!==void 0||e.targetKey!==void 0)&&n.addIssue({code:ye.custom,path:["scope"],message:"All scope cannot name a group or Property"}),e.scope==="group"&&(e.groupKey===void 0||e.targetKey!==void 0)&&n.addIssue({code:ye.custom,path:["groupKey"],message:"Group scope requires groupKey only"}),e.scope==="property"&&(e.targetKey===void 0||e.groupKey!==void 0)&&n.addIssue({code:ye.custom,path:["targetKey"],message:"Property scope requires targetKey only"})});const bj=j(["no_previous_run","execution_identity_changed","incomplete","not_comparable"]),vj=Mc.extend({executionIdentity:Za.nullable(),measurementScope:Ze([j(["full","spot_check"]),de()])}).strict();function xj(e,n){if(e.previous.state!=="available"||e.current.state!=="available"){n.addIssue({code:ye.custom,message:"Available deltas require two available metrics"});return}Math.abs(e.delta-(e.current.value-e.previous.value))>Number.EPSILON&&n.addIssue({code:ye.custom,path:["delta"],message:"Delta must equal current minus previous"})}const wj=d({state:R("unavailable"),reason:Oc}).strict(),Ud=Le("state",[d({state:R("available"),previous:wn,current:wn,delta:we()}).strict().superRefine(xj),wj]),hq=Le("state",[d({state:R("available"),previous:jc,current:jc,delta:m().int()}).strict().superRefine(xj),wj]),lf=d({propertiesMentioned:hq,mentionCoverage:Ud,citationCoverage:Ud}).strict(),fq=d({improved:qe,declined:qe,mixed:qe,withinNoise:qe,unchanged:qe,notComparable:qe,total:qe,noiseAnswers:R(pq)}).strict().superRefine((e,n)=>{e.improved+e.declined+e.mixed+e.withinNoise+e.unchanged+e.notComparable!==e.total&&n.addIssue({code:ye.custom,path:["total"],message:"Move buckets must sum to total"})}),gq=Ro.extend({mentionCoverage:Ud,citationCoverage:Ud,flags:qe,mentionAnswersDelta:m().int().nullable().optional(),citationAnswersDelta:m().int().nullable().optional(),denominatorChanged:_().optional(),withinNoise:_().optional(),mentionWithinNoise:_().nullable().optional(),citationWithinNoise:_().nullable().optional()}).strict();d({current:vj,queryClass:qa.optional(),comparison:Le("state",[d({state:R("available"),previous:d({displayedRunId:Za,planRevision:m().int().positive(),completedAt:o().datetime().nullable(),executionIdentity:Za,measurementScope:j(["full","spot_check"])}).strict(),metrics:lf,metricsByClass:d({branded:lf,nonBrand:lf}).strict().optional(),sort:yj.optional(),distribution:fq.optional(),changedProperties:y(gq),totalProperties:qe,truncated:_()}).strict(),d({state:R("unavailable"),reason:bj}).strict()])}).strict().superRefine((e,n)=>{if(e.comparison.state!=="available")return;const{distribution:i}=e.comparison;if(i!==void 0&&i.total-i.unchanged!==e.comparison.totalProperties&&n.addIssue({code:ye.custom,path:["comparison","distribution"],message:"Changed Properties must equal the distribution total less unchanged"}),e.current.displayedRunId===null||e.current.executionIdentity===null){n.addIssue({code:ye.custom,path:["current"],message:"A comparison requires an identified current run"});return}e.comparison.previous.planRevision!==e.current.planRevision&&n.addIssue({code:ye.custom,path:["comparison","previous","planRevision"],message:"Comparisons cannot cross plan revisions"}),e.comparison.previous.executionIdentity!==e.current.executionIdentity&&n.addIssue({code:ye.custom,path:["comparison","previous","executionIdentity"],message:"Comparisons cannot cross execution identities"})});d({runId:pa.runId}).strict();const yq=j(["no_completed_run","incomplete","evidence_incomplete","no_population","not_applicable"]),Bc=d({state:R("unavailable"),reason:yq}).strict(),bq=d({state:R("available"),expected:qe,executed:qe,answered:qe,missing:qe}).strict(),vq=Le("state",[bq,Bc]).superRefine((e,n)=>{e.state==="available"&&(e.executed+e.missing!==e.expected&&n.addIssue({code:ye.custom,message:"Expected must equal executed plus missing"}),e.answered>e.executed&&n.addIssue({code:ye.custom,path:["answered"],message:"Answered cannot exceed executed"}))}),xq=d({state:R("available"),complete:qe,partial:qe,failed:qe,unsupported:qe,notRecorded:qe}).strict(),wq=Le("state",[xq,Bc]),Sq=d({state:R("available"),used:qe,notUsed:qe,unknown:qe,notApplicable:qe,notRecorded:qe}).strict(),kq=Le("state",[Sq,Bc]),jq=d({state:R("available"),expectedQuestions:qe,answeredQuestions:qe,missingQuestions:qe}).strict(),Aq=Le("state",[jq,Bc]).superRefine((e,n)=>{e.state==="available"&&e.answeredQuestions+e.missingQuestions!==e.expectedQuestions&&n.addIssue({code:ye.custom,message:"Expected questions must equal answered plus missing"})}),rw=Le("state",[d({state:R("available"),answered:qe,unattributed:qe}).strict(),Bc]).superRefine((e,n)=>{e.state==="available"&&e.unattributed>e.answered&&n.addIssue({code:ye.custom,path:["unattributed"],message:"Unattributed answers cannot exceed answered"})}),Cq=d({status:f0,providers:y(o()),expected:qe,filled:qe,createdAt:o(),finishedAt:o().nullable()}).strict();d({run:vj,completeness:vq,capture:wq,retrieval:kq,population:Aq,comparison:Le("state",[d({state:R("available"),previousDisplayedRunId:Za}).strict(),d({state:R("unavailable"),reason:bj}).strict()]),unattributedByClass:d({branded:rw,nonBrand:rw}).strict().optional(),latestFill:Cq.nullable().optional()}).strict().superRefine((e,n)=>{if(e.completeness.state!=="available")return;const i=e.completeness.executed;e.capture.state==="available"&&e.capture.complete+e.capture.partial+e.capture.failed+e.capture.unsupported+e.capture.notRecorded!==i&&n.addIssue({code:ye.custom,path:["capture"],message:"Capture counts must total executed snapshots"}),e.retrieval.state==="available"&&e.retrieval.used+e.retrieval.notUsed+e.retrieval.unknown+e.retrieval.notApplicable+e.retrieval.notRecorded!==i&&n.addIssue({code:ye.custom,path:["retrieval"],message:"Retrieval counts must total executed snapshots"})});const Br=o().regex(/^[a-f0-9]{64}$/),Ya=o().trim().min(1).max(256),ui=m().int().positive(),lw=d({kind:j(["user","api-key","system"]),id:o().trim().min(1),label:o().trim().min(1)}).strict(),Nq=j(["proposed","included","excluded"]),_q=j(["manual","sitemap"]),y0=d({stableKey:ge,label:o().trim().min(1),status:Nq,aliases:y(o().trim().min(1)),identityAliases:y(o().trim().min(1)).optional(),urlMatchers:y(o().trim().min(1)),source:_q,discoveredUrl:o().trim().min(1).optional(),discoveryIdentity:o().trim().min(1).optional()}).strict(),ym=d({providers:y(kt).optional(),models:Qe(kt,o().trim().min(1)).optional(),locations:y(o().trim().min(1)).optional()}).strict(),Tq=j(["branded","non-brand","unclassified"]),Eq=j(["rule","operator"]),Sj=d({targetKey:ge,queryId:Ya,contextOverride:ym.optional(),executionContexts:y(dm.extend({executionNodeKey:o().min(1).optional()})).min(1).optional(),queryProvenance:C2.optional(),queryClass:Tq,classificationSource:Eq}).strict().superRefine((e,n)=>{e.contextOverride!==void 0&&e.executionContexts!==void 0&&n.addIssue({code:"custom",path:["executionContexts"],message:"Use either frozen execution contexts or a context override, not both."})}),bm=A2,kj=d({stableKey:ge,label:o().trim().min(1),parentGroupKey:ge.optional(),targetKeys:y(ge),competitors:y(bm)}).strict(),Rq=d({sitemapUrl:o().url(),rule:u0,exclusions:y(o().trim().min(1)),inputChecksum:Br,reviewedAt:o().datetime().optional()}).strict(),Dq=d({providers:y(kt),models:Qe(kt,o().trim().min(1)).optional(),locations:y(o().trim().min(1))}).strict(),jj=N2,zq=d({defaultContext:Dq,targets:y(y0),assignments:y(Sj),groups:y(kj),reportingScopes:y(jj).optional(),discovery:Rq.optional()}).strict(),Iq=d({id:o().trim().min(1),projectId:o().trim().min(1),schemaVersion:R(2),baseActiveVersionId:o().trim().min(1).nullable(),baseActiveRevision:ui.nullable(),authoring:zq,createdBy:lw,updatedBy:lw,createdAt:o().datetime(),updatedAt:o().datetime()}).strict(),b0=d({targets:m().int().nonnegative(),includedTargets:m().int().nonnegative(),assignments:m().int().nonnegative(),unclassifiedAssignments:m().int().nonnegative(),groups:m().int().nonnegative(),competitors:m().int().nonnegative()}).strict(),Oq=d({code:o().trim().min(1),message:o().trim().min(1),path:y(Ze([o(),m().int()]))}).strict(),Aj=d({etag:o().trim().min(1),changed:_(),warnings:y(Oq),counts:b0}).strict();d({draft:Iq.nullable(),etag:o().trim().min(1).nullable()}).strict();Pr(y0);Pr(Sj);Pr(kj);d({search:o().optional(),cursor:o().trim().min(1).optional(),limit:m().int().positive().max(Jg).optional()}).strict();d({expectedActiveRevision:ui.nullable()}).strict();d({sitemapUrl:o().url(),rule:u0,exclusions:y(o().trim().min(1)).optional()}).strict();const qq=d({discoveryIdentity:o().trim().min(1),action:j(["create","rebind","ignore"]),targetKey:ge.optional(),label:o().trim().min(1).optional()}).strict();d({selections:y(qq),selectedTargetKeys:y(ge).optional()}).strict().superRefine((e,n)=>{e.selections.length===0&&e.selectedTargetKeys===void 0&&n.addIssue({code:"custom",message:"A proposal or reviewed Property selection is required."}),e.selectedTargetKeys&&new Set(e.selectedTargetKeys).size!==e.selectedTargetKeys.length&&n.addIssue({code:"custom",path:["selectedTargetKeys"],message:"Property keys must be unique."})});d({target:y0}).strict();d({targetKey:ge,label:o().trim().min(1)}).strict();d({targetKey:ge,mergedKeys:y(ge).min(1)}).strict();d({targetKey:ge,cleanup:R("assignments-and-group-memberships").optional()}).strict();d({targetKey:ge,discoveryIdentity:o().trim().min(1),discoveredUrl:o().url()}).strict();const Cj={targetKeys:y(ge).optional(),groupKeys:y(ge).optional()};function Nj(e,n){(e.targetKeys?.length??0)===0&&(e.groupKeys?.length??0)===0&&n.addIssue({code:"custom",message:"At least one Target or group selector is required."})}d(Cj).strict().superRefine(Nj);const Pq=d({...Cj,queryIds:y(Ya).min(1),contextOverride:ym.optional()}).strict().superRefine(Nj);Ze([d({targetKey:ge,queryIds:y(Ya).min(1),contextOverride:ym.optional()}).strict(),Pq]);const Mq=d({groupKey:ge,label:o().trim().min(1),memberCount:m().int().positive()}).strict();d({draftEtag:o().trim().min(1),groups:y(Mq),resolvedTargetKeys:y(ge),overlapCount:m().int().nonnegative(),assignments:d({requested:m().int().nonnegative(),added:m().int().nonnegative(),alreadyPresent:m().int().nonnegative()}).strict(),execution:d({addedNodes:m().int().nonnegative(),addedProviderCalls:m().int().nonnegative(),fullRunNodes:m().int().nonnegative(),fullRunProviderCalls:m().int().nonnegative()}).strict()}).strict();d({pairs:y(d({targetKey:ge,queryId:Ya}).strict()).min(1),contextOverride:ym.optional()}).strict();Ze([d({targetKey:ge,queryId:Ya}).strict(),d({targetKeys:y(ge).min(1),queryId:Ya}).strict()]);d({targetKey:ge}).strict();d({queryClass:Yg,assignments:y(d({targetKey:ge,queryId:Ya}).strict()).min(1)}).strict();d({group:d({stableKey:ge,label:o().trim().min(1),parentGroupKey:ge.nullable().optional(),targetKeys:y(ge),competitors:y(bm).optional()}).strict()}).strict();d({market:jj}).strict();d({groupKey:ge}).strict();d({groupKey:ge,competitor:bm}).strict();d({expectedActiveRevision:ui,groupKey:ge,domain:o().trim().min(1).refine(e=>Ic(e)!==null,"A competitor domain must be a valid hostname"),label:o().trim().min(1).optional(),aliases:y(o().trim().min(1)).optional()}).strict();Aj.extend({groupKey:ge,competitor:bm,draftCreated:_(),published:d({revision:ui,competitorsChanged:R(!1)}).strict()}).strict();d({groupKey:ge,competitorKey:ge}).strict();const Gd=d({ruleId:o().trim().min(1),severity:j(["fail","warn"]),message:o().trim().min(1),path:y(Ze([o(),m().int()]))}).strict();Le("ok",[d({ok:R(!0),compiledChecksum:Br,checks:y(Gd),counts:b0,plan:mm}).strict(),d({ok:R(!1),compiledChecksum:de(),checks:y(Gd).min(1)}).strict()]);const cw=d({added:y(o().trim().min(1)),removed:y(o().trim().min(1)),changed:y(o().trim().min(1)),unchanged:y(o().trim().min(1))}).strict(),Bq=d({activeRevision:ui.nullable(),targets:cw,groups:cw,assignments:d({added:m().int().nonnegative(),removed:m().int().nonnegative(),reclassified:m().int().nonnegative()}).strict(),execution:d({addedNodeKeys:y(o().trim().min(1)),removedNodeKeys:y(o().trim().min(1))}).strict()}).strict();Le("ok",[d({ok:R(!0),compiledChecksum:Br,checks:y(Gd),counts:b0,plan:mm,diff:Bq}).strict(),d({ok:R(!1),compiledChecksum:de(),checks:y(Gd).min(1),diff:de()}).strict()]);d({expectedActiveRevision:ui.nullable(),expectedCompiledChecksum:Br}).strict();d({published:_(),active:d({revision:ui,checksum:Br,compiledChecksum:Br,createdAt:o().datetime(),plan:mm}).strict()}).strict();d({discarded:_()}).strict();d({expectedActiveRevision:ui}).strict();d({deactivated:_(),previousRevision:ui.nullable()}).strict();const Lq=j(["republish_required","setup_in_progress","awaiting_first_run","operational","simple"]),$q=j(["republish_setup","continue_setup","run_measurement","view_measurement","start_setup"]),Vq=j(["simple","draft-only","active-v1","active-v2"]);d({state:Lq,nextAction:$q,mode:Vq,answerVisibilityProviderReady:_(),activeRevision:ui.nullable(),activeSchemaVersion:Ze([R(1),R(2)]).nullable(),draft:d({etag:o().trim().min(1),updatedAt:o().datetime()}).strict().nullable()}).strict();const _j=d({id:o().trim().min(1),projectId:o().trim().min(1),name:o().trim().min(1),description:o().nullable(),itemCount:m().int().nonnegative(),createdAt:o().datetime(),updatedAt:o().datetime()}).strict(),Uq=d({queryId:Ya,queryText:o().min(1),position:m().int().nonnegative()}).strict();_j.extend({items:y(Uq)}).strict();d({querySets:y(_j)}).strict();d({name:o().trim().min(1),description:o().nullable().optional(),queryIds:y(Ya)}).strict();const Gq=d({id:o().trim().min(1),projectId:o().trim().min(1),name:o().trim().min(1),description:o().nullable(),pattern:o().trim().min(1),variables:y(o().trim().min(1)),createdAt:o().datetime(),updatedAt:o().datetime()}).strict();d({templates:y(Gq)}).strict();d({name:o().trim().min(1),description:o().nullable().optional(),pattern:o().trim().min(1),variables:y(o().trim().min(1))}).strict();d({bindings:y(Qe(o().trim().min(1),o().trim().min(1))).min(1),querySetId:o().trim().min(1).optional()}).strict();d({created:y(d({queryId:Ya,queryText:o().min(1)}).strict()),existing:y(d({queryId:Ya,queryText:o().min(1)}).strict())}).strict();const Kd=o().regex(/^[a-f0-9]{64}$/),vm=m().int().positive();d({stableKey:ge,kind:j(["target","group"]),retiredAt:o().datetime().nullable()}).strict();d({csv:o()}).strict();j(["matched","ambiguous","unmatched","invalid","duplicate","proposed","excluded"]);const Kq=j(["column-count","missing-property","missing-group","invalid-url","property-not-found","property-label-ambiguous","url-not-exact-match","target-proposed","target-excluded","group-label-ambiguous","group-key-conflict"]),Zf=d({dataRow:vm,property:o(),group:o(),url:o().nullable(),normalizedProperty:o(),normalizedGroupLabel:o()}).strict(),sc=Zf.extend({reason:Kq}),Hq=d({source:j(["draft-target","draft-group","persisted-segment","retired-segment","proposed-group"]),stableKey:ge,kind:j(["target","group"]).optional(),retiredAt:o().datetime().nullable().optional(),normalizedGroupLabel:o().optional()}).strict(),Qq=d({proposedGroupKey:ge,evidence:y(Hq).min(1)}).strict(),Fq=Le("status",[Zf.extend({status:R("matched"),targetKey:ge,groupKey:ge}).strict(),sc.extend({status:R("ambiguous"),candidateTargetKeys:y(ge).min(1).optional(),candidateGroupKeys:y(ge).min(1).optional()}).strict(),sc.extend({status:R("unmatched")}).strict(),sc.extend({status:R("invalid"),groupKeyConflict:Qq.optional()}).strict(),Zf.extend({status:R("duplicate"),duplicateOfRow:vm,targetKey:ge,groupKey:ge}).strict(),sc.extend({status:R("proposed"),targetKey:ge}).strict(),sc.extend({status:R("excluded"),targetKey:ge}).strict()]),Zq=d({normalizedGroupLabel:o(),groupKey:ge,label:o().trim().min(1),action:j(["create","extend"]),matchedRows:y(vm),targetKeys:y(ge),addedTargetKeys:y(ge),unchangedTargetKeys:y(ge)}).strict(),Yq=d({dataRows:m().int().nonnegative(),matchedRows:m().int().nonnegative(),ambiguousRows:m().int().nonnegative(),unmatchedRows:m().int().nonnegative(),invalidRows:m().int().nonnegative(),duplicateRows:m().int().nonnegative(),proposedRows:m().int().nonnegative(),excludedRows:m().int().nonnegative(),needsAttention:m().int().nonnegative(),groupsReady:m().int().nonnegative(),groupsToCreate:m().int().nonnegative(),groupsToExtend:m().int().nonnegative(),membershipsReady:m().int().nonnegative(),addedMemberships:m().int().nonnegative(),unchangedMemberships:m().int().nonnegative()}).strict();d({draftEtag:o().trim().min(1),sourceChecksum:Kd,previewChecksum:Kd,rows:y(Fq),groupChanges:y(Zq),counts:Yq}).strict();d({csv:o(),sourceChecksum:Kd,previewChecksum:Kd,acceptedRows:y(vm).min(1)}).strict().superRefine((e,n)=>{new Set(e.acceptedRows).size!==e.acceptedRows.length&&n.addIssue({code:"custom",path:["acceptedRows"],message:"Accepted CSV data rows must be unique."})});Aj.extend({appliedRows:m().int().nonnegative(),addedMemberships:m().int().nonnegative(),unchangedMemberships:m().int().nonnegative()}).strict();function Tj(e,n){return Number((n===xt.percent?e:e*100).toFixed(6))}function Ej(e){return Math.round(Number((e*10).toFixed(4)))/10}function sn(e,n=xt.fraction){if(e==null||!Number.isFinite(e))return"—";const i=Tj(e,n);if(i===0)return"0%";const r=i<0?"-":"",u=Math.abs(i);if(u===100)return`${r}100%`;const h=Ej(u);return h===0?`${r}<0.1%`:h===100&&u<100?`${r}>99.9%`:`${r}${h.toFixed(1)}%`}function Un(e){return Number.isFinite(e)?Math.abs(e)>=1e6?`${(e/1e6).toFixed(1)}M`:Math.abs(e)>=1e3?`${(e/1e3).toFixed(1)}K`:e.toLocaleString("en-US"):"—"}function jo(e){if(!e)return"—";try{const n=/^(\d{4})-(\d{2})-(\d{2})$/.exec(e),i={month:"short",day:"numeric",year:"numeric"},r=n&&n[1]&&n[2]&&n[3]?new Date(Date.UTC(Number(n[1]),Number(n[2])-1,Number(n[3]))):new Date(e);return Number.isNaN(r.getTime())?e:r.toLocaleDateString("en-US",n?{...i,timeZone:"UTC"}:i)}catch{return e}}const Xq=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function gc(e,n=new Date){const i=/^(\d{4})-(\d{2})-(\d{2})$/.exec(e),r=i?Xq[Number(i[2])-1]:void 0;if(!i||!r)return e;const u=`${r} ${Number(i[3])}`;return Number(i[1])===n.getFullYear()?u:`${u}, ${i[1]}`}function pee(e,n,i=800){const r=[];if(!/^\d{4}-\d{2}-\d{2}$/.test(e)||!/^\d{4}-\d{2}-\d{2}$/.test(n))return r;for(let u=e;u<=n&&(r.push(u),!(r.length>=i));u=Jq(u,1));return r}function Jq(e,n){if(!Number.isFinite(n))return e;const i=/^(\d{4})-(\d{2})-(\d{2})$/.exec(e);if(!i?.[1]||!i[2]||!i[3])return e;const r=new Date(Date.UTC(Number(i[1]),Number(i[2])-1,Number(i[3])+Math.trunc(n)));if(Number.isNaN(r.getTime()))return e;const u=r.getUTCFullYear(),h=String(r.getUTCMonth()+1).padStart(2,"0"),f=String(r.getUTCDate()).padStart(2,"0");return`${u}-${h}-${f}`}function Wq(e,n){return!e&&!n?"":e&&n?`${jo(e)} → ${jo(n)}`:jo(e||n)}function eP(e,n){if(!Number.isFinite(e)||!Number.isFinite(n)||n<=0)return null;const i=(e-n)/n;return Number.isFinite(i)?i:null}function hee(e,n){const i=eP(e,n);return i===null?null:bz(i*100,xt.percent)}function v0(e,n=xt.fraction){return`${e>0?"+":""}${sn(e,n)}`}function fee(e){return e===null||e===0?"neutral":e>0?"positive":"negative"}function gee(e,n,i="vs prior 7 days"){return e.deltaPct===null?e.prior===0?"First baseline week":"":e.deltaPct>0?`Up ${sn(e.deltaPct,xt.percent)} ${i} (${Un(e.prior)} ${n})`:e.deltaPct<0?`Down ${sn(Math.abs(e.deltaPct),xt.percent)} ${i} (${Un(e.prior)} ${n})`:`Flat ${i} (${Un(e.prior)} ${n})`}const Rj=30;function uw(e){return Math.round(e*10)/10}function tP(e){return e.prior>=Rj&&e.deltaPct!==null?`${v0(e.deltaPct,xt.percent)} vs prior`:`${e.deltaAbs>0?"+":""}${uw(e.deltaAbs)} vs ${uw(e.prior)}`}function yee(e,n,i){return e.prior>=Rj&&e.deltaPct!==null?`${v0(e.deltaPct,xt.percent)} ${i}`:`${e.deltaAbs>0?"+":""}${Un(Math.round(e.deltaAbs))} ${n} ${i}`}function Dj(e,n=xt.fraction){const i=Tj(e,n);if(i===0)return{direction:"none",magnitude:"0"};const r=Ej(Math.abs(i));return{direction:i>0?"up":"down",magnitude:r===0?"<0.1":r.toFixed(1)}}function nP(e,n=xt.fraction){const{direction:i,magnitude:r}=Dj(e,n);return`${i==="up"?"+":i==="down"?"-":""}${r} pts`}function bee(e,n="UTC"){const i=new Date(e);if(!Number.isFinite(i.getTime()))return null;const r={weekday:"short",year:"numeric",month:"short",day:"numeric",hour:"numeric",minute:"2-digit",timeZoneName:"short"};try{return i.toLocaleString("en-US",{...r,timeZone:n})}catch{return i.toLocaleString("en-US",{...r,timeZone:"UTC"})}}const zj=j(["introduced","repointed","retired"]),aP=zj.enum;d({modelId:o().trim().min(1),date:o().regex(/^\d{4}-\d{2}-\d{2}$/,"date must be YYYY-MM-DD"),kind:zj,confirmed:_(),sourceUrl:o().url(),note:o().min(1)});const iP=[{modelId:"chatgpt-4o-latest",date:"2024-08-15",kind:"introduced",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:'Verbatim: "Released dynamic model for chatgpt-4o-latest—this model will point to the latest GPT-4o model used by ChatGPT." First moving id in the lineage.'},{modelId:"chatgpt-4o-latest",date:"2026-02-17",kind:"retired",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/deprecations.md",note:'Shutdown 2026-02-17, replacement gpt-5.1-chat-latest. Announced under the heading "2025-11-18: chatgpt-4o-latest snapshot".'},{modelId:"gpt-5.1-chat-latest",date:"2025-11-13",kind:"introduced",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:"Introduced inside the GPT-5.1 launch entry, not as a standalone entry."},{modelId:"gpt-5.2-chat-latest",date:"2025-12-11",kind:"introduced",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:"Introduced inside the GPT-5.2 launch entry."},{modelId:"gpt-5.2-chat-latest",date:"2026-02-10",kind:"repointed",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:'Verbatim: "Updated the gpt-5.2-chat-latest slug to point to the latest model currently used in ChatGPT." Target model NOT named.'},{modelId:"gpt-5.3-chat-latest",date:"2026-03-03",kind:"introduced",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:'Verbatim: "Released gpt-5.3-chat-latest to the Chat Completions and Responses API. This model points to the GPT-5.3 Instant snapshot currently used in ChatGPT."'},{modelId:"gpt-5.3-chat-latest",date:"2026-03-16",kind:"repointed",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:'Verbatim: "Updated the gpt-5.3-chat-latest slug to point to the latest model currently used in ChatGPT." Target model NOT named.'},{modelId:"chat-latest",date:"2026-05-05",kind:"introduced",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:'Verbatim: "Released chat-latest snapshot which points to the latest Instant model currently used in ChatGPT... The underlying model snapshot will be regularly updated."'},{modelId:"chat-latest",date:"2026-05-28",kind:"repointed",confirmed:!1,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:'UNCONFIRMED. The entry reads "Released chat-latest snapshot..." — the verb is "Released", the same boilerplate as the 2026-05-05 entry, not "Updated" as used on 2026-06-24. Only "the latest improvements" vs "our latest improvements" differs. Either a real change logged with copy-pasted text, or a duplicated entry; the record does not disambiguate.'},{modelId:"chat-latest",date:"2026-06-24",kind:"repointed",confirmed:!0,sourceUrl:"https://developers.openai.com/api/docs/changelog",note:'Verbatim (re-read at source 2026-07-20): "Updated the chat-latest snapshot, which points to the latest Instant model currently used in ChatGPT." The verb is "Updated", unlike the "Released" boilerplate of 2026-05-05 and 2026-05-28, which is the wording the changelog reserves for a real change. Target model NOT named. The only unambiguous chat-latest change on record.'}];aP.repointed;new Set(iP.map(e=>e.modelId.toLowerCase()));const sP=j(["not-exposed","no-known-change","known-change"]);sP.enum;const oP=d({modelId:o().trim().min(1),date:o().regex(/^\d{4}-\d{2}-\d{2}$/),confirmed:_(),sourceUrl:o().url()}),rP=d({status:j(["no-known-change","known-change"]),modelIds:y(o().trim().min(1)).min(1),changes:y(oP),changeCount:m().int().nonnegative(),unverifiedChangeCount:m().int().nonnegative(),firstChangeDate:o().optional(),lastChangeDate:o().optional(),knownGoodAsOf:o(),checkedThroughPeriodEnd:_()}),lP={openai:"ChatGPT",chatgpt:"ChatGPT",anthropic:"Claude",claude:"Claude",google:"Gemini",gemini:"Gemini",perplexity:"Perplexity"};function cP(e){const n=e.trim().toLowerCase();return lP[n]??e.charAt(0).toUpperCase()+e.slice(1)}function cf(e){return typeof e=="number"&&Number.isFinite(e)&&e>0?Math.floor(e):0}function oc(e){return typeof e=="string"&&e.trim().length>=10?e.trim().slice(0,10):null}function uf(e){return[...new Set(e.filter(n=>n!==null))].sort()}function uP(e,n,i){const r=i(e),u=Array.isArray(n.changes)?n.changes:[],h=cf(n.changeCount)||u.length,f=Math.min(h,cf(n.unverifiedChangeCount)||cf(n.unconfirmedChangeCount)||u.filter(k=>k.confirmed===!1).length),b=oc(n.knownGoodAsOf),v=n.checkedThroughPeriodEnd!==!1,x={engine:r,confirmedCount:h-f,unconfirmedCount:f,knownGoodAsOf:b,checkedThroughPeriodEnd:v};if(u.length>0)return{...x,confirmedDates:uf(u.filter(k=>k.confirmed!==!1).map(k=>oc(k.date))),unconfirmedDates:uf(u.filter(k=>k.confirmed===!1).map(k=>oc(k.date)))};const S=uf([oc(n.firstChangeDate),oc(n.lastChangeDate)]);return h===0?{...x,confirmedDates:[],unconfirmedDates:[]}:f===0?{...x,confirmedDates:S,unconfirmedDates:[]}:x.confirmedCount===0?{...x,confirmedDates:[],unconfirmedDates:S}:{...x,confirmedDates:[],unconfirmedDates:[]}}function dP(e){return e.length===1?e[0]:e.length===2?`${e[0]} and ${e[1]}`:`${e.slice(0,-1).join(", ")}, and ${e[e.length-1]}`}function dw(e,n){return e.length===0?null:e.length===1&&n<=1?`on ${gc(e[0])}`:`more than once between ${gc(e[0])} and ${gc(e[e.length-1])}`}function mP(e){const n=dw(e.confirmedDates,e.confirmedCount),i=dw(e.unconfirmedDates,e.unconfirmedCount),r=`The model behind ${e.engine}`;if(e.confirmedCount>0&&e.unconfirmedCount===0)return n?`${r} was updated ${n}, inside this period.`:`${r} was updated inside this period.`;if(e.confirmedCount===0)return i?`${r} may have been updated ${i}, inside this period, though that is not confirmed.`:`${r} may have been updated inside this period, though that is not confirmed.`;if(n&&i)return`${r} was updated ${n}, inside this period, and may also have been updated ${i}.`;const u=e.unconfirmedCount>1?"more times":"once more";return`${r} was updated inside this period, and may have been updated ${u}, though that is not confirmed.`}function mw(e){const n=e.filter(r=>!r.checkedThroughPeriodEnd&&r.knownGoodAsOf!==null);if(n.length===0)return null;const i=n.map(r=>r.knownGoodAsOf).sort()[0];return`We last checked for model updates on ${gc(i)}, and this period runs past that date, so there may be later updates we do not know about.`}function vee(e,n={}){const i=n.engineName??cP,r=Object.entries(e??{}).map(([S,k])=>uP(S,k??{},i)).sort((S,k)=>S.engine.localeCompare(k.engine));if(r.length===0)return null;const u=r.filter(S=>S.confirmedCount+S.unconfirmedCount>0);if(u.length===0){const S=[...new Set(r.map(P=>P.engine))],k=S.length>1,T=mw(r),N=[...new Set(r.map(P=>P.knownGoodAsOf).filter(P=>P!==null))].sort(),I=T??(N.length>0?`We last checked for model updates on ${gc(N[0])}.`:null);return{kind:"no-known-change",text:`No model updates are on record for ${dP(S)} in this period.`,detail:`${k?"These engines":"This engine"} can be moved onto a different underlying model without the data ever showing a different model name, so we check each period against a record of known updates. Nothing is listed inside this one.${I?` ${I}`:""}`}}const h=u.reduce((S,k)=>S+k.confirmedCount+k.unconfirmedCount,0),f=u.some(S=>S.confirmedCount>0),b=h===1?"this update":"these updates",v=f?`Some of the movement in these numbers may come from ${b} rather than from a real change in how AI answers about you, so compare periods carefully.`:`If so, some of the movement in these numbers may come from ${b} rather than from a real change in how AI answers about you, so compare periods carefully.`,x=mw(r);return{kind:"change",text:`${u.map(mP).join(" ")} ${v}${x?` ${x}`:""}`}}const ko=d({slope:m(),intercept:m(),r2:m(),start:m(),end:m(),n:m(),startIndex:m(),endIndex:m()}),pP=j(["gsc","ga4","gbp"]);d({id:o(),domain:o(),connectionType:pP,propertyId:o().nullable().optional(),sitemapUrl:o().nullable().optional(),scopes:y(o()).default([]),createdAt:o(),updatedAt:o()});const hP=d({date:o(),query:o(),page:o(),country:o().nullable().optional(),device:o().nullable().optional(),clicks:m(),impressions:m(),ctr:we(),position:m()});j(["clicks","impressions","date"]);d({rows:y(hP),totalMatching:m(),truncated:_(),latestAvailableDate:o().nullable()});const fP=d({date:o(),clicks:m(),impressions:m(),ctr:we(),position:m().nullable()}),Ij=d({startDate:o().nullable(),endDate:o().nullable(),latestDataDate:o().nullable(),daysSinceLatestData:m().nullable()}),gP=d({clicks:ko.nullable(),impressions:ko.nullable(),ctr:ko.nullable(),position:ko.nullable()}),pw=d({startDate:o(),endDate:o(),clicks:m(),impressions:m(),ctr:we().nullable(),position:m().nullable(),source:j(["property-daily","dimensioned","mixed","empty"])}),yP=d({days:m(),basis:j(["prior-window","split-window"]).optional(),prior:pw,trailing:pw,comparable:_(),change:d({clicks:we().nullable(),impressions:we().nullable(),ctr:we().nullable(),position:we().nullable()})});d({totals:d({clicks:m(),impressions:m(),ctr:we(),position:m().nullable(),positionDays:m(),days:m()}),daily:y(fP),window:Ij.optional(),trends:gP.optional(),periodComparison:yP.nullable().optional()});const bP=d({page:o(),clicks:m(),impressions:m(),ctr:we()});d({rows:y(bP),totals:d({clicks:m(),impressions:m(),ctr:we(),days:m(),coveredFrom:o().nullable(),coveredThrough:o().nullable(),complete:_()}).nullable(),totalsSource:R("property-daily"),rankedFrom:o().nullable(),rankedThrough:o().nullable()});const vP=j(["google","page-summed","mixed"]),xP=d({query:o(),clicks:m(),impressions:m(),ctr:we(),position:m(),days:m(),source:vP});d({rows:y(xP),totalMatching:m(),truncated:_(),window:Ij});const Yf=d({id:o(),url:o(),indexingState:o().nullable().optional(),verdict:o().nullable().optional(),coverageState:o().nullable().optional(),pageFetchState:o().nullable().optional(),robotsTxtState:o().nullable().optional(),crawlTime:o().nullable().optional(),lastCrawlResult:o().nullable().optional(),isMobileFriendly:_().nullable().optional(),richResults:y(o()).default([]),referringUrls:y(o()).default([]),inspectedAt:o()});j(["stable","reindexed","deindexed","still-missing","new"]);const wP=d({url:o(),previousState:o().nullable(),currentState:o().nullable(),transitionDate:o()}),SP=d({reason:o(),count:m(),urls:y(Yf).default([])});d({summary:d({total:m(),indexed:m(),notIndexed:m(),deindexed:m(),percentage:Oe(),indexedShare:we(m().min(0).max(1)).nullable(),notIndexedShare:we(m().min(0).max(1)).nullable()}),lastInspectedAt:o().nullable(),lastSyncedAt:o().nullable(),indexed:y(Yf).default([]),notIndexed:y(Yf).default([]),deindexed:y(wP).default([]),reasonGroups:y(SP).default([])});d({url:o(),type:j(["URL_UPDATED","URL_DELETED"]),notifiedAt:o()});const kP=d({url:o(),type:j(["URL_UPDATED","URL_DELETED"]),notifiedAt:o(),status:j(["success","error"]),error:o().optional()});d({summary:d({total:m().int().nonnegative(),succeeded:m().int().nonnegative(),failed:m().int().nonnegative()}),results:y(kP).default([])});d({date:o(),indexed:m(),notIndexed:m(),unknownPages:m().default(0),verifiedByInspection:m().default(0),derivedFromImpressions:m().default(0),reasonBreakdown:Qe(o(),m()).default({})});const jP=d({siteUrl:o(),permissionLevel:o()});d({sites:y(jP).default([])});const AP=d({type:o(),submitted:o(),indexed:o().optional().describe("Deprecated compatibility field.")}),Oj=d({path:o(),parentSitemapUrl:o().optional(),lastSubmitted:o().optional(),isPending:_().optional(),isSitemapsIndex:_().optional(),type:o().optional(),lastDownloaded:o().optional(),warnings:o().optional(),errors:o().optional(),contents:y(AP).optional()});d({sitemaps:y(Oj).default([]),summary:d({total:m().int().nonnegative(),indexes:m().int().nonnegative(),files:m().int().nonnegative()}),preferredSubmissionUrls:y(o()).default([])});d({sitemapUrls:y(o().url().refine(e=>{const n=new URL(e).protocol;return n==="http:"||n==="https:"},{message:"Sitemap URL must use http or https."})).min(1).max(50)});const CP=d({sitemapUrl:o(),status:j(["accepted","error"]),submittedAt:o().optional(),error:o().optional()});d({summary:d({total:m().int().nonnegative(),accepted:m().int().nonnegative(),failed:m().int().nonnegative()}),results:y(CP)});d({sitemaps:y(Oj),primarySitemapUrl:o(),run:d({id:o(),projectId:o(),kind:o(),status:o(),trigger:o(),createdAt:o()}).nullable()});const pt=o().trim().min(1),hw=o().regex(/^[a-f0-9]{64}$/i);function NP(e){if(!/^\d{4}-\d{2}-\d{2}$/.test(e))return!1;const n=new Date(`${e}T00:00:00.000Z`);return!Number.isNaN(n.getTime())&&n.toISOString().slice(0,10)===e}const ea=o().refine(NP,{message:"Expected a calendar date as YYYY-MM-DD."});function _P(e,n){const i=Date.parse(`${e}T00:00:00.000Z`),r=Date.parse(`${n}T00:00:00.000Z`);return Math.floor((r-i)/864e5)+1}const TP=j(["not-connected","selection-required","connected","stale"]),cd=TP.enum,qj=j(["enabled","suspended","closed","canceled","unspecified","unknown"]);qj.enum;const x0=j(["enabled","paused","removed","unknown"]);x0.enum;const Pj=j(["enabled","hidden","removed","unknown"]);Pj.enum;const w0=j(["customer","campaign"]);w0.enum;const Mj=j(["customer-goal","campaign-goal","custom-goal"]);Mj.enum;const Bj=d({loginCustomerId:pt.nullable(),customerId:pt.nullable(),selectedAt:o().nullable()}).strict(),df=d({id:pt,projectId:pt,scopes:y(o()).default([]),selection:Bj,lastValidatedAt:o().nullable(),lastInventorySnapshotAt:o().nullable(),lastMetricsSnapshotAt:o().nullable(),createdAt:o(),updatedAt:o()}).strict(),Xf=d({resourceName:pt,customerId:pt,parentCustomerId:pt.nullable(),descriptiveName:o().nullable(),currencyCode:o().nullable(),timeZone:o().nullable(),manager:_(),hidden:_(),testAccount:_(),level:m().int().nonnegative(),status:qj}).strict(),EP=d({customers:y(Xf),totalAccessible:m().int().nonnegative(),truncated:_(),selection:Bj,fetchedAt:o()}).strict();Le("status",[d({connected:R(!1),status:R(cd["not-connected"]),connection:de(),selectedCustomer:de()}).strict(),d({connected:R(!0),status:R(cd["selection-required"]),connection:df,selectedCustomer:de()}).strict(),d({connected:R(!0),status:R(cd.connected),connection:df,selectedCustomer:Xf}).strict(),d({connected:R(!0),status:R(cd.stale),connection:df,selectedCustomer:Xf}).strict()]);const RP=d({id:pt,resourceName:pt,name:o(),status:x0,advertisingChannelType:o().nullable(),biddingStrategyType:o().nullable()}).strict(),DP=d({id:pt,resourceName:pt,name:o(),status:Pj,category:o(),origin:o(),primaryForGoal:_(),includeInConversionsMetric:_()}).strict(),zP=d({category:o(),origin:o(),biddable:_()}).strict(),IP=d({campaignId:pt,category:o(),origin:o(),biddable:_()}).strict(),OP=d({id:pt,name:o(),conversionActionIds:y(pt)}).strict(),qP=d({campaignId:pt,goalConfigLevel:w0,customGoalId:pt.nullable()}).strict(),PP=d({customerId:pt,fetchedAt:o(),campaigns:y(RP),conversionActions:y(DP),customerConversionGoals:y(zP),campaignConversionGoals:y(IP),campaignConversionGoalsComplete:_().optional(),customConversionGoals:y(OP),campaignGoalConfigurations:y(qP)}).strict(),MP=d({source:Mj,category:o().nullable(),origin:o().nullable(),customGoalId:pt.nullable(),biddable:_().nullable(),conversionActionIds:y(pt),primaryConversionActionIds:y(pt),secondaryConversionActionIds:y(pt),missingConversionActionIds:y(pt)}).strict(),BP=d({campaignId:pt,goalConfigLevel:w0,customGoalId:pt.nullable(),missingCustomGoalId:pt.nullable(),goals:y(MP)}).strict();d({customerId:pt,derivedAt:o(),campaigns:y(BP)}).strict();const Lj=50,Jf=31,LP=Lj*Jf,$P=d({campaignIds:y(pt).min(1).max(Lj),startDate:ea,endDate:ea}).strict().superRefine((e,n)=>{if(new Set(e.campaignIds).size!==e.campaignIds.length&&n.addIssue({code:ye.custom,path:["campaignIds"],message:"Campaign IDs must be unique."}),e.endDate<e.startDate){n.addIssue({code:ye.custom,path:["endDate"],message:"endDate must not precede startDate."});return}_P(e.startDate,e.endDate)>Jf&&n.addIssue({code:ye.custom,path:["endDate"],message:`Campaign metrics may cover at most ${Jf} calendar days.`})}),VP=d({campaignId:pt,date:ea,impressions:m().int().nonnegative(),clicks:m().int().nonnegative(),costMicros:m().int().nonnegative(),conversions:m().nonnegative(),conversionValueMicros:m().int().nonnegative().nullable()}).strict(),UP=d({query:$P,rows:y(VP).max(LP),truncated:_(),fetchedAt:o()}).strict(),$j=j(["accessible-customers","inventory","campaign-metrics"]),mf=$j.enum,S0=d({id:pt,projectId:pt,connectionId:pt,runId:pt,kind:$j,customerId:pt.nullable(),payloadChecksum:hw,rawPayloadSha256:hw.nullable(),rawPayloadBytes:m().int().nonnegative().nullable(),redactedFieldCount:m().int().nonnegative(),capturedAt:o(),createdAt:o()}).strict(),GP=Le("kind",[d({kind:R(mf["accessible-customers"]),data:EP}).strict(),d({kind:R(mf.inventory),data:PP}).strict(),d({kind:R(mf["campaign-metrics"]),data:UP}).strict()]),KP=d({metadata:S0,payload:GP}).strict().superRefine((e,n)=>{e.metadata.kind!==e.payload.kind&&n.addIssue({code:ye.custom,path:["payload","kind"],message:"Snapshot metadata and payload kinds must match."})}),HP=j(["7d","14d","30d"]),k0=d({impressions:m().int().nonnegative(),clicks:m().int().nonnegative(),costMicros:m().int().nonnegative(),conversions:m().nonnegative(),conversionValueMicros:m().int().nonnegative().nullable(),ctr:we().nullable(),cpcMicros:m().int().nonnegative().nullable(),conversionRate:we().nullable(),costPerConversionMicros:m().int().nonnegative().nullable()}),QP=d({date:ea,origin:j(["provider","filled"]),impressions:m().int().nonnegative(),clicks:m().int().nonnegative(),costMicros:m().int().nonnegative(),conversions:m().nonnegative(),ctr:we().nullable()}),FP=d({campaignId:pt,name:o().nullable(),status:x0,totals:k0}),ZP=d({snapshotId:pt,capturedAt:o(),customerId:pt,currencyCode:o().nullable(),timeZone:o().nullable(),asOfDate:ea,openDate:ea.nullable(),truncated:_(),campaignsQueried:m().int().nonnegative(),campaignsInInventory:m().int().nonnegative()}),YP=d({startDate:ea,endDate:ea,days:m().int().positive(),totals:k0}),XP=d({days:m().int().positive(),prior:YP,change:d({impressions:we().nullable(),clicks:we().nullable(),costMicros:we().nullable(),conversions:we().nullable(),ctr:we().nullable(),conversionRate:we().nullable()})});d({window:HP,startDate:ea,endDate:ea,days:m().int().positive(),totals:k0,daily:y(QP),campaigns:y(FP),comparison:XP.nullable(),comparisonUnavailableReason:j(["insufficient-history","no-snapshot"]).nullable(),source:ZP.nullable()});const mt=o().trim().min(1),fw=o().regex(/^[a-f0-9]{64}$/i),JP=j(["not-connected","selection-required","connected","stale"]),ud=JP.enum,WP=j(["live","draft"]),Vj=WP.enum,jd=d({accountId:mt.nullable(),containerId:mt.nullable(),workspaceId:mt.nullable(),selectedAt:o().nullable()}).strict(),pf=d({id:mt,projectId:mt,scopes:y(o()).default([]),selection:jd,lastValidatedAt:o().nullable(),lastSnapshotAt:o().nullable(),createdAt:o(),updatedAt:o()}).strict(),Uj=d({id:mt,path:o(),name:o(),shareData:_().nullable()}).strict(),Gj=d({accountId:mt,id:mt,path:o(),name:o(),publicId:o().nullable(),domainName:o().nullable(),usageContexts:y(o())}).strict(),j0=d({accountId:mt,containerId:mt,id:mt,path:o(),name:o(),description:o().nullable(),fingerprint:o().nullable()}).strict(),eM=d({accounts:y(Uj),totalAccessible:m().int().nonnegative(),truncated:_(),fetchedAt:o()}).strict();d({accountId:mt,containers:y(Gj),totalAccessible:m().int().nonnegative(),truncated:_(),fetchedAt:o()}).strict();d({accountId:mt,containerId:mt,workspaces:y(j0),totalAccessible:m().int().nonnegative(),truncated:_(),fetchedAt:o()}).strict();const tM=d({id:mt,name:o(),type:o(),paused:_(),firingTriggerIds:y(mt),blockingTriggerIds:y(mt),referencedVariableIds:y(mt),parameterKeys:y(o()),fingerprint:o().nullable()}).strict(),nM=d({id:mt,name:o(),type:o(),customEventNames:y(o()),filterKeys:y(o()),autoEventFilterKeys:y(o()),fingerprint:o().nullable()}).strict(),aM=d({id:mt,name:o(),type:o(),dataLayerVariableName:o().nullable(),parameterKeys:y(o()),fingerprint:o().nullable()}).strict(),Kj=j(["recognized","unknown"]),gw=Kj.enum,iM=j(["literal","variable-ref","absent","unknown"]),xm=iM.enum,sM=o().trim().min(5).max(132).regex(/^\{\{\w[\w ./-]{0,127}\}\}$/),Zr=d({source:R(xm.absent),literal:de(),variableRef:de()}).strict(),Yr=d({source:R(xm.unknown),literal:de(),variableRef:de()}).strict(),Xr=d({source:R(xm["variable-ref"]),literal:de(),variableRef:sM}).strict();function Lc(e){return d({source:R(xm.literal),literal:e,variableRef:de()}).strict()}const oM=o().trim().max(23).regex(/^(?:AW-)?\d{1,20}$/i),rM=o().trim().min(1).max(128).regex(/^[\w-]+$/),lM=o().trim().min(1).max(20).regex(/^(?:0|[1-9]\d{0,11})(?:\.\d{1,6})?$/),cM=o().trim().length(3).regex(/^[a-z]{3}$/i);Le("source",[Lc(o().trim().min(1).max(256)),Xr,Zr,Yr]);const uM=Le("source",[Lc(oM),Xr,Zr,Yr]),dM=Le("source",[Lc(rM),Xr,Zr,Yr]),mM=Le("source",[Lc(lM),Xr,Zr,Yr]),pM=Le("source",[Xr,Zr,Yr]),hM=Le("source",[Lc(cM),Xr,Zr,Yr]),Hj=j(["all-pages","custom-event","filtered","unknown"]);Hj.enum;const yw=d({operator:o().trim().min(1).max(64),value:o().max(2048),negated:_(),ignoreCase:_()}).strict(),fM=d({triggerId:mt,triggerType:o(),eventPredicates:y(yw),hostnamePredicates:y(yw),unsupportedConditionCount:m().int().nonnegative()}).strict(),Qj=j(["not-google-ads-tag","unsupported-tag-type","custom-html-opaque","conversion-id-unresolved","conversion-label-unresolved","value-mapping-missing","transaction-id-mapping-missing","currency-mapping-missing","trigger-unresolved","hostname-filter-unresolved"]);Qj.enum;const gM=d({tagId:mt,tagType:o(),recognition:Kj,recognitionReason:o().nullable(),conversionId:uM,conversionLabel:dM,value:mM,transactionId:pM,currency:hM,triggerStrategy:Hj,triggerIds:y(mt),triggerPredicates:y(fM),reviewReasons:y(Qj)}).strict().superRefine((e,n)=>{e.recognition===gw.recognized&&e.recognitionReason!==null&&n.addIssue({code:ye.custom,path:["recognitionReason"],message:"Recognized assessments cannot carry an unknown-recognition reason."}),e.recognition===gw.unknown&&!e.recognitionReason&&n.addIssue({code:ye.custom,path:["recognitionReason"],message:"Unknown assessments require a recognition reason."})}),Fj=d({accountId:mt,containerId:mt,workspaceId:mt.nullable(),tags:y(tM),triggers:y(nM),variables:y(aM),googleAdsTagAssessments:y(gM).default([])}).strict(),yM=d({accountId:mt,containerId:mt,id:mt,path:o(),name:o(),description:o().nullable(),fingerprint:o().nullable(),deleted:_()}).strict(),Zj=d({source:R(Vj.live),version:yM,graph:Fj,fetchedAt:o()}).strict(),Yj=d({source:R(Vj.draft),workspace:j0,graph:Fj,conflictCount:m().int().nonnegative(),fetchedAt:o()}).strict(),bM=d({account:Uj,container:Gj,workspaces:y(j0),live:Zj.nullable(),draft:Yj.nullable(),fetchedAt:o()}).strict();Le("status",[d({connected:R(!1),status:R(ud["not-connected"]),connection:de(),selection:de()}).strict(),d({connected:R(!0),status:R(ud["selection-required"]),connection:pf,selection:jd}).strict(),d({connected:R(!0),status:R(ud.connected),connection:pf,selection:jd}).strict(),d({connected:R(!0),status:R(ud.stale),connection:pf,selection:jd}).strict()]);const Xj=j(["accounts","container","live","draft"]),dd=Xj.enum,A0=d({id:mt,projectId:mt,connectionId:mt,runId:mt,kind:Xj,accountId:mt.nullable(),containerId:mt.nullable(),workspaceId:mt.nullable(),payloadChecksum:fw,rawPayloadSha256:fw.nullable(),rawPayloadBytes:m().int().nonnegative().nullable(),redactedFieldCount:m().int().nonnegative(),capturedAt:o(),createdAt:o()}).strict(),vM=Le("kind",[d({kind:R(dd.accounts),data:eM}).strict(),d({kind:R(dd.container),data:bM}).strict(),d({kind:R(dd.live),data:Zj}).strict(),d({kind:R(dd.draft),data:Yj}).strict()]),xM=d({metadata:A0,payload:vM}).strict().superRefine((e,n)=>{e.metadata.kind!==e.payload.kind&&n.addIssue({code:ye.custom,path:["payload","kind"],message:"Snapshot metadata and payload kinds must match."})}),Wn=o().trim().min(1),wM=o().trim().min(1).refine(e=>Ic(e)!==null,"Expected a hostname or http(s) URL."),C0=j(["configured","statically-consistent","runtime-unverified","observed"]);C0.enum;const Jj=j(["pass","fail","unknown"]);Jj.enum;const Wj=j(["ads-connection-missing","ads-conversion-action-missing","ads-goal-missing","ads-goal-not-biddable","ads-action-not-primary","gtm-connection-missing","gtm-live-graph-missing","gtm-tag-missing","gtm-tag-unrecognized","gtm-tag-paused","gtm-trigger-missing","gtm-variable-missing","gtm-event-mismatch","gtm-hostname-mismatch","gtm-value-mapping-missing","gtm-transaction-id-mapping-missing","gtm-currency-mapping-missing","gtm-conversion-id-mismatch","gtm-conversion-label-mismatch","runtime-event-not-observed","runtime-gtm-not-observed","runtime-ads-not-observed"]);Wj.enum;const e3=d({id:Wn,projectId:Wn,name:o().trim().min(1),eventName:o().trim().min(1),googleAds:d({customerId:Wn,conversionActionId:Wn,conversionId:o().trim().min(1).optional(),conversionLabel:o().trim().min(1).optional(),campaignIds:y(Wn).max(50).default([]),requireBiddableGoal:_().default(!0),requirePrimaryAction:_().default(!0)}).strict(),gtm:d({accountId:Wn,containerId:Wn,tagId:Wn,triggerIds:y(Wn).default([]),variableIds:y(Wn).default([])}).strict(),runtime:d({verificationRequired:_().default(!0),requireTransactionId:_().default(!0),requireValue:_().default(!0),requireCurrency:_().default(!0),productionHosts:y(wM).default([])}).strict(),createdAt:o(),updatedAt:o()}).strict();e3.omit({id:!0,projectId:!0,createdAt:!0,updatedAt:!0});const t3=j(["not-run","consistent","inconsistent"]);t3.enum;const n3=j(["not-run","not-observed","observed"]);n3.enum;d({staticCheck:t3,runtimeVerificationRequired:_(),runtimeObservation:n3}).strict();const SM=d({code:Wj,subject:o().trim().min(1),outcome:Jj,status:C0,evidenceIds:y(Wn).default([])}).strict(),kM=d({contract:e3,status:C0,findings:y(SM),evaluatedAt:o()}).strict(),bw=d({id:Wn,name:o(),detail:o(),active:_()});d({googleAds:d({customerId:Wn.nullable(),syncedAt:o().nullable(),conversionActions:y(bw)}),gtm:d({containerId:Wn.nullable(),syncedAt:o().nullable(),tags:y(bw)})});const yc=o().trim().min(1);function vw(e){const n=e.trim();return/^\d{10}$/.test(n)?n:/^\d{3}-\d{3}-\d{4}$/.test(n)?n.replaceAll("-",""):null}const jM=/^[\w-]+$/;function N0(e){const n=e.trim();return jM.test(n)?n:null}function AM(e){const n=e.trim();return/^accounts\/([\w-]+)$/.exec(n)?.[1]??N0(n)}function CM(e,n){const i=e.trim(),r=/^accounts\/([\w-]+)\/containers\/([\w-]+)$/.exec(i);return r?r[1]===n?r[2]:null:N0(i)}function NM(e,n,i){const r=e.trim(),u=/^accounts\/([\w-]+)\/containers\/([\w-]+)\/workspaces\/([\w-]+)$/.exec(r);return u?u[1]===n&&u[2]===i?u[3]:null:N0(r)}function _M(e){const n=vw(e.customerId);if(!n)return null;if(e.loginCustomerId===null)return{loginCustomerId:null,customerId:n};if(e.loginCustomerId===void 0)return{customerId:n};const i=vw(e.loginCustomerId);return i?{loginCustomerId:i,customerId:n}:null}function TM(e){const n=AM(e.accountId);if(!n)return null;const i=CM(e.containerId,n);if(!i)return null;if(e.workspaceId===void 0)return{accountId:n,containerId:i};const r=NM(e.workspaceId,n,i);return r?{accountId:n,containerId:i,workspaceId:r}:null}const wm=j(["google-ads","gtm"]);wm.enum;d({provider:wm,publicUrl:o().url().optional(),developerToken:o().trim().min(1).max(512).optional()}).strict();d({provider:wm,authorizationUrl:o().url(),redirectUri:o().url(),expiresAt:o().nullable()}).strict();d({loginCustomerId:yc.nullable().optional(),customerId:yc}).strict().superRefine((e,n)=>{_M(e)||n.addIssue({code:ye.custom,message:"Expected ten-digit Google Ads customer IDs, with optional 3-3-4 display hyphens."})});d({accountId:yc,containerId:yc,workspaceId:yc.optional()}).strict().superRefine((e,n)=>{TM(e)||n.addIssue({code:ye.custom,message:"GTM resource paths must match the selected account and container."})});d({provider:wm,disconnected:_()}).strict();const a3=100;d({snapshots:y(S0).max(a3),nextCursor:o().nullable(),total:m().int().nonnegative()}).strict();d({snapshot:KP}).strict();d({snapshots:y(A0).max(a3),nextCursor:o().nullable(),total:m().int().nonnegative()}).strict();d({snapshot:xM}).strict();d({assessment:kM,googleAdsSnapshot:S0.nullable(),gtmSnapshot:A0.nullable()}).strict();d({id:o(),domain:o(),siteUrl:o().nullable().optional(),createdAt:o(),updatedAt:o()});const hf=d({id:o(),url:o(),httpCode:m().nullable().optional(),inIndex:_().nullable().optional(),lastCrawledDate:o().nullable().optional(),inIndexDate:o().nullable().optional(),inspectedAt:o(),documentSize:m().nullable().optional(),anchorCount:m().nullable().optional(),discoveryDate:o().nullable().optional()});d({summary:d({total:m(),indexed:m(),notIndexed:m(),unknown:m().optional(),percentage:Oe()}),lastInspectedAt:o().nullable(),indexed:y(hf).default([]),notIndexed:y(hf).default([]),unknown:y(hf).default([]).optional()});d({query:o(),impressions:m(),clicks:m(),ctr:we(),averagePosition:m()});d({date:o(),indexed:m(),notIndexed:m(),unknown:m()});const EM=d({url:o(),status:j(["success","error"]),submittedAt:o(),error:o().optional()});d({summary:d({total:m().int().nonnegative(),succeeded:m().int().nonnegative(),failed:m().int().nonnegative()}),results:y(EM).default([])});const i3=d({url:o(),verified:_()});d({sites:y(i3).default([])});d({connected:_(),domain:o(),siteUrl:o().nullable(),createdAt:o().nullable(),updatedAt:o().nullable()});d({connected:_(),domain:o(),siteUrl:o().nullable(),availableSites:y(i3).default([])});d({siteUrl:o()});const RM=d({name:o(),alive:_(),lastUsed:o().nullable()});d({connected:_(),endpoint:o(),version:o().optional(),browserVersion:o().optional(),targets:y(RM).default([])});const Jr=j(["live","staging"]);d({projectName:o(),url:o(),stagingUrl:o().optional(),username:o(),defaultEnv:Jr,createdAt:o(),updatedAt:o()});const xw=d({url:o(),reachable:_(),pageCount:m().nullable().optional(),version:o().nullable().optional(),error:o().nullable().optional(),plugins:y(o()).optional(),authenticatedUser:d({id:m(),slug:o()}).nullable().optional()});d({connected:_(),projectName:o(),defaultEnv:Jr,live:xw.nullable(),staging:xw.nullable(),adminUrl:o().nullable().optional()});const DM=d({id:m(),slug:o(),title:o(),status:o(),modifiedAt:o().nullable().optional(),link:o().nullable().optional()}),s3=d({title:o().nullable(),description:o().nullable(),noindex:_().nullable(),writable:_().default(!1),writeTargets:y(o()).default([])}),zM=d({type:o(),json:Qe(o(),jn())}),IM=DM.extend({env:Jr,content:o(),seo:s3,schemaBlocks:y(zM).default([])}),ww=IM.extend({contentHash:o(),contentSnippet:o()}),o3=d({manualRequired:R(!0),targetUrl:o(),adminUrl:o().nullable().optional(),content:o(),nextSteps:y(o()).default([])}),OM=d({slug:o(),severity:j(["high","medium","low"]),code:j(["noindex","missing-seo-title","missing-meta-description","missing-schema","thin-content"]),message:o()});d({slug:o(),title:o(),status:o(),wordCount:m(),seo:s3,schemaPresent:_(),issues:y(OM).default([])});const qM=d({slug:o(),status:j(["applied","skipped","manual"]),error:o().optional(),manualAssist:o3.optional()});d({env:Jr,strategy:j(["plugin","manual"]),results:y(qM)});const PM=d({slug:o(),status:j(["deployed","stripped","skipped","failed"]),schemasInjected:y(o()).optional(),manualAssist:o3.optional(),error:o().optional()});d({env:Jr,results:y(PM)});const MM=d({slug:o(),title:o(),canonrySchemas:y(o()),thirdPartySchemas:y(o()),hasCanonrySchema:_()});d({env:Jr,pages:y(MM)});const BM=d({name:o(),status:j(["completed","skipped","failed"]),summary:o().optional(),error:o().optional()});d({projectName:o(),steps:y(BM)});d({slug:o(),live:ww,staging:ww,hasDifferences:_(),differences:d({title:_(),slug:_(),content:_(),seoTitle:_(),seoDescription:_(),noindex:_(),schema:_()})});const LM=l2.shape.searchUnit.unwrap().enum;LM.query;const $M=d({name:o(),displayName:o().optional(),keyUrl:o().optional(),modelHint:o().optional(),model:o().optional(),defaultModel:o().optional(),configured:_(),quota:mz.optional(),vertexConfigured:_().optional()}),VM=d({name:o(),displayName:o(),mode:j(["api","browser"]),modelConfigurable:_(),defaultModel:o(),knownModels:y(d({id:o(),displayName:o(),tier:j(["flagship","standard","fast","economy"])})).default([]),modelValidationPattern:d({source:o(),flags:o()}),modelValidationHint:o()}),Sw=d({configured:_()});d({providers:y($M).default([]),providerCatalog:y(VM).default([]),google:Sw,bing:Sw});const UM=j(["recorded","errored","expired","canceled","parse_failed","duplicate"]);UM.enum;const GM=j(["not_plan_run","scoped_run","probe_run","batch_unavailable","model_not_frozen"]);GM.enum;Ox.standard,Ox.batch;const r3=j(["all","api","browser"]);r3.enum;const KM=j(["yes","no","unknown","not-mentioned"]),kw=y(o().min(1)),jw=d({companyName:o().min(1),domain:o().min(1),queries:kw.optional(),phrases:kw.optional(),competitors:y(o().min(1)).optional(),providers:y(o().trim().min(1)).min(1).optional().describe("Configured provider names to use for both answers and analysis. Omit to use all providers matching providerMode."),providerMode:r3.optional().describe("Filter providers by transport; defaults to all. Browser-only selection requires manual queries and uses no API provider for analysis.")}).superRefine((e,n)=>{e.queries!==void 0&&e.phrases!==void 0&&n.addIssue({code:"custom",message:"Use queries; phrases is accepted only as a legacy alias when queries is omitted",path:["phrases"]})});jw.safeExtend({competitors:jw.shape.competitors.default([])});const HM=d({name:o(),count:m().int().nonnegative()}),QM=d({id:o(),name:o(),weight:m(),score:m(),findings:y(d({type:o(),message:o()})).default([]),recommendations:y(o()).default([])}),FM=d({url:o(),finalUrl:o(),auditedAt:o(),overallScore:m(),summary:o(),factors:y(QM).default([])}),ZM=d({industry:o(),summary:o(),services:y(o()).default([]),categoryTerms:y(o()).default([])}),YM=d({provider:o(),displayName:o(),model:o().nullable().optional(),mentioned:_(),cited:_(),describedAccurately:KM,accuracyNotes:o().nullable().optional(),incorrectClaims:y(o()).default([]),recommendedCompetitors:y(o()).default([]),citedDomains:y(o()).default([]),groundingSources:y(gm).default([]),searchQueries:y(o()).default([]),answerText:o(),error:o().nullable().optional()}),XM=d({query:o(),providerResults:y(YM).default([])}),JM=d({totalQueries:m().int().nonnegative(),totalProviders:m().int().nonnegative(),totalComparisons:m().int().nonnegative(),mentionCount:m().int().nonnegative(),citationCount:m().int().nonnegative(),topCompetitors:y(HM).default([]),visibilityGap:o(),whatThisMeans:y(o()).default([]),recommendedActions:y(o()).default([])});d({companyName:o(),domain:o(),homepageUrl:o(),generatedAt:o(),queries:y(o()).default([]),competitors:y(o()).default([]),profile:ZM,audit:FM,queryResults:y(XM).default([]),summary:JM});const l3=Ze([ha,de()]),_0=j(["pass","partial","fail"]);_0.enum;const c3=j(["up","down","flat"]);c3.enum;const WM=d({id:o(),name:o(),weight:m(),sharePct:Oe(m().min(0).max(100)).nullable().default(null),avgScore:m(),status:_0,pagesPassing:m().int().nonnegative(),pagesPartial:m().int().nonnegative(),pagesFailing:m().int().nonnegative()}),eB=d({factorId:o(),factorName:o(),avgScore:m(),affectedPages:m().int().nonnegative(),totalPages:m().int().nonnegative(),affectedPct:Oe(m().nonnegative()),topRecommendations:y(o()).default([])});d({project:o(),hasData:_(),runId:o().nullable(),runStatus:l3,sitemapUrl:o().nullable(),auditedAt:o().nullable(),aggregateScore:m(),pagesDiscovered:m().int().nonnegative(),pagesAudited:m().int().nonnegative(),pagesSkipped:m().int().nonnegative(),pagesErrored:m().int().nonnegative(),deltaScore:m().nullable(),trend:Ze([c3,de()]),previousScore:m().nullable(),previousAuditedAt:o().nullable(),factors:y(WM).default([]),crossCuttingIssues:y(eB).default([]),prioritizedFixes:y(o()).default([])});const u3=d({id:o(),name:o(),weight:m(),score:m(),sharePct:Oe(m().min(0).max(100)).nullable().default(null)}),tB=d({url:o(),overallScore:m(),status:j(["success","error"]),error:o().nullable().optional(),factors:y(u3).default([])});d({project:o(),runId:o().nullable(),auditedAt:o().nullable(),total:m().int().nonnegative(),pages:y(tB).default([])});const nB=d({runId:o(),auditedAt:o(),aggregateScore:m(),pagesAudited:m().int().nonnegative()});d({project:o(),points:y(nB).default([])});const aB=j(["disabled","complete","partial","unavailable"]);aB.enum;const iB=d({pagesDiscovered:m().int().nonnegative(),pagesFetched:m().int().nonnegative(),pagesEligible:m().int().nonnegative(),edges:m().int().nonnegative(),findings:m().int().nonnegative()}),sB=Le("state",[d({state:R("unavailable")}),d({state:R("disabled")}),d({state:R("complete"),checked:m().int().nonnegative(),found:m().int().nonnegative(),unverified:m().int().nonnegative()}),d({state:R("partial"),checked:m().int().nonnegative(),found:m().int().nonnegative(),unverified:m().int().nonnegative()})]);d({project:o(),hasCrawlData:_(),legacyAuditAvailable:_(),runId:o().nullable(),runStatus:l3,requestedRootUrl:o().nullable(),rootUrl:o().nullable(),crawlSchemaVersion:o().nullable().optional(),engineVersion:o().nullable().optional(),normalizationVersion:o().nullable().optional(),indexabilityVersion:o().nullable().optional(),linkScoreVersion:o().nullable().optional(),effectiveOptions:Qe(o(),jn()).default({}),complete:_(),termination:o().nullable(),detailsAvailable:_(),counts:iB,deadLinks:sB});j(["complete","unknown","max-pages","max-edges","max-fetches","max-duration","max-bytes","max-page-bytes","max-depth","max-links-per-page","max-query-variants","max-sitemap-fanout","max-sitemap-urls","root-host-redirect"]);const Sm=j(["eligible","hidden","resource","redirect","failed","unchecked"]),xee=Sm.enum,wee=Sm.options,Ar={discovered:"discovered",robotsBlocked:"robots-blocked",html:"html",redirect:"redirect",nonHtml:"non-html",fetchError:"fetch-error"},md={indexable:"indexable",noindex:"noindex",blocked:"blocked",unknown:"unknown"},oB={robotsDisallow:"robots-disallow",redirectTerminal:"redirect-terminal",metaRobotsNoindex:"meta-robots-noindex",xRobotsNoindex:"x-robots-noindex",canonicalToOther:"canonical-to-other",notHtmlOrUnavailable:"not-html-or-unavailable"};function rB(e){return e.indexabilityReasons?.some(n=>n===oB.canonicalToOther)===!0||e.nodeKey!==void 0&&e.canonicalNodeKey!==null&&e.canonicalNodeKey!==void 0&&e.canonicalNodeKey!==e.nodeKey}function See(e){switch(e.fetchState){case Ar.fetchError:return"failed";case Ar.discovered:return"unchecked";case Ar.nonHtml:return"resource";case Ar.redirect:return"redirect";case Ar.robotsBlocked:return"hidden";case Ar.html:break;default:return"unchecked"}if(rB(e))return"hidden";switch(e.indexabilityState){case md.indexable:return"eligible";case md.noindex:case md.blocked:return"hidden";case md.unknown:default:return"unchecked"}}const kee=15,lB=j(["navigation","content","unknown"]);lB.enum;const cB=d({navigation:m().int().nonnegative(),content:m().int().nonnegative(),unknown:m().int().nonnegative()}),d3=j(["placement","ubiquity","unmeasured"]);d3.enum;const km=j(["applied","applied-placement","applied-placement-with-ubiquity","applied-placement-partial","unavailable-too-few-pages","unavailable-legacy-scan"]);km.enum;function jee(e){switch(e){case"applied":case"applied-placement":case"applied-placement-with-ubiquity":case"applied-placement-partial":return!0;case"unavailable-too-few-pages":case"unavailable-legacy-scan":return!1}}const jm=j(["all","content","template"]);jm.enum;const uB=j(["anchor","redirect","canonical","link"]);uB.enum;const Nc=d({nodeKey:o(),url:o(),finalUrl:o().nullable(),path:o(),parentPath:o(),discoverySource:o(),fetchState:o(),httpStatus:m().int().nullable(),canonicalUrl:o().nullable(),indexabilityState:o(),indexabilityReasons:y(o()).default([]),auditState:o(),auditScore:m().nullable(),inventoryEligible:_(),depth:m().int().nullable(),inboundUniqueEdges:m().int().nonnegative(),outboundUniqueEdges:m().int().nonnegative(),inboundOccurrences:m().int().nonnegative(),outboundOccurrences:m().int().nonnegative(),linkScoreRaw:m().nullable(),linkScoreNormalized:Oe().nullable(),healthState:Sm}),dB=d({type:j(["found","missing","info","timeout","unreachable"]),code:o().min(1),message:o().min(1)}),Aw=u3.extend({status:_0,applicable:_().nullable(),findings:y(dB).default([]),recommendations:y(o()).default([])}),Cw=d({id:o().min(1),severity:j(["critical","warning"]),detail:o().min(1),recommendation:o().min(1)}),pd=d({project:o(),runId:o(),complete:_(),termination:o().nullable()}),Nw=d({nodeKey:o(),url:o(),auditState:o()});Le("state",[d({state:R("no-crawl"),project:o(),runId:de()}),pd.extend({state:R("details-unavailable")}),pd.extend({state:R("not-found")}),pd.merge(Nw).extend({state:R("not-audited"),auditScore:de(),factors:y(Aw).length(0).default([]),criticalDefects:y(Cw).length(0).default([])}),pd.merge(Nw).extend({state:R("ready"),auditScore:m(),evidenceState:j(["complete","scores-only"]),factors:y(Aw).default([]),criticalDefects:y(Cw).default([])})]);const mB=j(["applied","unavailable-legacy-scan"]);d({project:o(),hasCrawlData:_(),runId:o().nullable(),total:m().int().nonnegative(),nextCursor:o().nullable(),healthStateFilter:Ze([mB,de()]).default(null),pages:y(Nc).default([])});const pB=d({path:o(),url:o().nullable(),hasPage:_(),pageCount:m().int().positive(),inventoryEligibleCount:m().int().nonnegative(),fetchedCount:m().int().nonnegative()});d({project:o(),hasCrawlData:_(),runId:o().nullable(),parentPath:o(),nextCursor:o().nullable(),children:y(pB).default([])});const Co=d({edgeKey:o(),sourceNodeKey:o(),sourceUrl:o(),targetNodeKey:o().nullable(),targetUrl:o(),relation:o(),internal:_(),followable:_(),occurrences:m().int().positive(),followableOccurrences:m().int().nonnegative(),nofollowOccurrences:m().int().nonnegative(),anchors:y(o()).default([]),isTemplate:Ze([_(),de()]),templateRatio:Ze([we(),de()]),templateSource:d3,placementOccurrences:Ze([cB,de()])}),hB=d({nodeKey:o(),url:o(),path:o(),depth:m().int().nonnegative().nullable(),indexabilityState:o(),fetchState:o(),auditState:o(),auditScore:m().nullable(),inventoryEligible:_(),inboundUniqueEdges:m().int().nonnegative(),outboundUniqueEdges:m().int().nonnegative(),linkScoreNormalized:Oe().nullable(),healthState:Sm,x:m(),y:m()}),fB=d({edgeKey:o(),sourceNodeKey:o(),targetNodeKey:o(),followable:_(),occurrences:m().int().positive(),isTemplate:_()}),gB=j(["no-crawl","legacy-snapshot","details-unavailable","layout-failed","empty-crawl"]),yB=Le("state",[d({state:R("ready"),version:o().min(1),computedAt:o().min(1),templateLinksExcluded:_()}),d({state:R("unavailable"),version:de(),reason:gB})]);d({project:o(),hasCrawlData:_(),runId:o().nullable(),rootNodeKey:o().nullable(),layout:yB,templateDetection:km,linkKind:jm,totalNodes:m().int().nonnegative(),totalEdges:m().int().nonnegative(),totalTemplateEdges:m().int().nonnegative(),totalContentEdges:m().int().nonnegative(),nodes:y(hB).default([]),edges:y(fB).default([]),omittedNodes:m().int().nonnegative(),omittedEdges:m().int().nonnegative(),sampled:_()});const Aee=2e4,Cee=5e4,bB=j(["focus","inbound","outbound","both","transitive"]),vB=Nc.extend({distance:m().int().nonnegative(),relationToFocus:bB});d({project:o(),hasCrawlData:_(),runId:o().nullable(),complete:_(),termination:o().nullable(),state:j(["no-crawl","details-unavailable","ready"]),focusNodeKey:o().nullable(),focusUrl:o().nullable(),hops:m().int().min(0).max(3),totalNodes:m().int().nonnegative(),totalEdges:m().int().nonnegative(),nodes:y(vB).default([]),edges:y(Co).default([]),omittedNodes:m().int().nonnegative(),omittedEdges:m().int().nonnegative(),countAccuracy:j(["exact","lower-bound"]),truncated:_()});const _w=d({nodeKey:o(),url:o(),path:o()});d({project:o(),runId:o().nullable(),complete:_(),termination:o().nullable(),state:j(["no-crawl","details-unavailable","found","unreachable","truncated"]),from:_w.nullable(),to:_w.nullable(),maxDepth:m().int().positive(),visitedNodes:m().int().nonnegative(),nodes:y(Nc).default([]),edges:y(Co).default([])});const m3=j(["added","removed","changed"]),xB=d({entity:R("page"),change:m3,key:o(),changedFields:y(o()).default([]),before:Nc.nullable(),after:Nc.nullable()}),wB=d({entity:R("link"),change:m3,key:o(),changedFields:y(o()).default([]),before:Co.nullable(),after:Co.nullable()}),SB=Le("entity",[xB,wB]),Tw=d({added:m().int().nonnegative(),removed:m().int().nonnegative(),changed:m().int().nonnegative()}),kB=d({scope:j(["all","pages","links"]),change:j(["all","added","removed","changed"])});Le("state",[d({project:o(),state:R("unavailable"),reason:j(["no-crawl","insufficient-history","details-unavailable","partial-not-comparable"]),fromRunId:o().nullable(),toRunId:o().nullable()}),d({project:o(),state:R("incompatible"),reason:R("incompatible-versions"),fromRunId:o(),toRunId:o(),mismatchedVersions:y(o()).min(1)}),d({project:o(),state:R("ready"),fromRunId:o(),toRunId:o(),versions:d({crawlSchema:o(),normalization:o(),indexability:o(),linkScore:o()}),filters:kB,summaryState:j(["exact","omitted-on-continuation"]),summary:d({pages:Tw,links:Tw}).nullable(),total:m().int().nonnegative().nullable(),nextCursor:o().nullable(),changes:y(SB).default([])})]);d({project:o(),hasCrawlData:_(),runId:o().nullable(),total:m().int().nonnegative(),nextCursor:o().nullable(),templateDetection:km,linkKind:jm,edges:y(Co).default([])});d({project:o(),hasCrawlData:_(),runId:o().nullable(),nodeKey:o().nullable(),url:o().nullable(),templateDetection:km,linkKind:jm,inbound:y(Co).default([]),outbound:y(Co).default([]),inboundTruncated:_(),outboundTruncated:_()});const Ew=d({findingKey:o(),severity:o(),sourceNodeKey:o().nullable(),sourceUrl:o().nullable(),targetNodeKey:o().nullable(),targetUrl:o().nullable(),evidence:Qe(o(),jn()).default({})});Le("state",[d({project:o(),runId:o().nullable(),state:R("unavailable"),legacyAuditAvailable:_()}),d({project:o(),runId:o(),state:R("disabled"),checkDeadLinks:R(!1)}),d({project:o(),runId:o(),state:R("complete"),checkDeadLinks:R(!0),checked:m().int().nonnegative(),found:m().int().nonnegative(),unverified:m().int().nonnegative(),total:m().int().nonnegative(),nextCursor:o().nullable(),deadLinks:y(Ew).default([])}),d({project:o(),runId:o(),state:R("partial"),checkDeadLinks:R(!0),checked:m().int().nonnegative(),found:m().int().nonnegative(),unverified:m().int().nonnegative(),total:m().int().nonnegative(),nextCursor:o().nullable(),deadLinks:y(Ew).default([])})]);const Nee=1e3,_ee=10,p3=100;d({sitemapUrl:o().url().optional(),limit:m().int().positive().max(2e3).optional(),maxPages:m().int().positive().max(5e4).optional(),maxEdges:m().int().positive().max(1e6).optional(),maxDepth:m().int().min(0).max(100).optional(),checkDeadLinks:_().default(!1)});d({runId:o(),status:ha});const jB=d({runId:o(),status:ha,createdAt:o(),startedAt:o().nullable(),finishedAt:o().nullable(),hasCrawlData:_()});d({project:o(),scans:y(jB).default([])});const AB=j(["queued","discovering","checking","arranging-map","completed","partial","failed","cancelled"]),CB=d({state:j(["pending","ready","unavailable"]),layoutVersion:o().nullable(),failureCode:o().nullable(),updatedAt:o().nullable()}),NB=d({id:o(),state:o(),pagesDiscovered:m().int().nonnegative(),pagesFetched:m().int().nonnegative(),pagesEligible:m().int().nonnegative(),pagesErrored:m().int().nonnegative(),edgesDiscovered:m().int().nonnegative(),lastUpdatedAt:o(),startedAt:o().nullable(),finishedAt:o().nullable(),error:o().nullable()});d({project:o(),runId:o(),status:ha,phase:AB,attempt:NB.nullable(),layout:CB,error:o().nullable()});const _B=j(["waiting","collecting","terminal"]),TB=d({nodeKey:o(),url:o(),auditScore:m(),checksNeedingAttention:m().int().nonnegative()});d({project:o(),runId:o(),status:ha,state:_B,attemptId:o().nullable(),pagesAudited:m().int().nonnegative(),updatedAt:o().nullable(),examples:y(TB).max(12).default([])});const EB=d({basis:j(["tracked","observed"]).nullable(),availability:j(["measured","not-measured","unavailable"]),reason:j(["select-query-class","no-competitors","insufficient-observed","no-answers","no-mentions","unavailable"]).nullable()}),T0=EB.partial().shape;function Tee(e){switch(e){case"select-query-class":return"Select a query class.";case"no-competitors":return"No competitors configured.";case"insufficient-observed":return"Requires 3 observed competitors mentioned in at least 3 answers each.";case"no-answers":return"No answer text in scope.";case"no-mentions":return"No brands mentioned in scope.";case"unavailable":return"Competitor evidence is unavailable.";default:return""}}function RB(e,n){const i=n?.availability==="unavailable"?"Unavailable":n?.availability==="not-measured"||e===null?"Not measured":sn(e,xt.percent);return n?.basis?`${i} · ${n.basis} competitors`:i}function Eee(e,n,i){return`Share of voice · ${n} queries: ${RB(e,i)}${i?.measurementScope==="all-markets"?" · all markets":""}`}const E0=j(["competitor","directory","social","forum","news","reference","blog","ecommerce","video","academic","other"]),Ad=E0.enum,R0=j(["cited","aspirational","wasted-surface"]),Rw=R0.enum;Rw.cited,Rw.aspirational;const Am=j(["direct-competitor","ota-aggregator","editorial-media","other","unknown"]),DB=Am.enum;DB["direct-competitor"];const Cm=j(["queued","seeding","probing","completed","failed"]);Cm.enum;const h3=d({domain:o().min(1),hits:m().int().positive(),competitorType:Am.default("unknown")}),zB=d({id:o(),sessionId:o(),projectId:o(),query:o(),bucket:R0.nullable().default(null),citationState:$i,citedDomains:y(o()).default([]),answerMentioned:_().nullable().default(null),createdAt:o()}),IB=d({id:o(),projectId:o(),status:Cm,icpDescription:o().nullable().optional(),seedProvider:o().nullable().optional(),seedCountRaw:m().int().nullable().optional(),seedCount:m().int().nullable().optional(),seedFromAnswerCount:m().int().nullable().optional(),seedFromGroundingCount:m().int().nullable().optional(),seedBrandFilteredCount:m().int().nullable().optional(),buyerDescription:o().nullable().optional(),locations:y(dn).nullable().optional(),seedRawCandidates:y(o()).nullable().optional(),dedupClusterMinSims:y(m()).nullable().optional(),dedupBandPairFraction:we().nullable().optional(),dedupPairsTotal:m().int().nullable().optional(),seedProviders:y(o()).nullable().optional(),seedProviderCounts:Qe(o(),m().int()).nullable().optional(),canonicalCount:m().int().nullable().optional(),dedupThreshold:m().nullable().optional(),probeCount:m().int().nullable().optional(),citedCount:m().int().nullable().default(null),aspirationalCount:m().int().nullable().default(null),wastedCount:m().int().nullable().default(null),competitorMap:y(h3).default([]),warning:o().nullable().optional(),error:o().nullable().optional(),startedAt:o().nullable().optional(),finishedAt:o().nullable().optional(),createdAt:o()});IB.extend({probes:y(zB).default([])});const OB=500,qB=8,PB=["gemini","openai"],MB=j(PB);d({icpDescription:o().min(1).optional(),buyerDescription:o().min(1).optional(),seedProviders:y(MB).min(1).transform(e=>[...new Set(e)].sort()).optional(),dedupThreshold:m().min(0).max(1).optional(),maxProbes:m().int().positive().max(OB).optional(),probeConcurrency:m().int().min(1).max(qB).optional(),locations:y(o().min(1)).optional()});d({buckets:y(R0).min(1).optional(),includeCompetitors:_().optional(),competitorTypes:y(Am).min(1).optional()});d({sessionId:o(),projectId:o(),status:Cm,queriesByBucket:d({cited:y(o()),aspirational:y(o()),"wasted-surface":y(o())}),suggestedCompetitors:y(h3)});d({sessionId:o(),projectId:o(),promoted:d({queries:y(o()),competitors:y(o())}),skipped:d({queries:y(o()),competitors:y(o())})});Ze([R("cli"),o().regex(/^discovery:.+$/)]);const BB=d({query:o().min(1),probeHits:m().int().positive()}),LB=d({rawCandidates:m().int().nonnegative(),admitted:m().int().nonnegative(),rejected:d({belowFloor:m().int().nonnegative(),length:m().int().nonnegative(),navigational:m().int().nonnegative(),duplicate:m().int().nonnegative(),offAnchor:m().int().nonnegative(),semanticDuplicate:m().int().nonnegative()})});d({sessionId:o(),projectId:o(),provider:o(),status:Cm,minProbeHits:m().int().positive(),anchorApplied:_(),semanticNoveltyApplied:_(),candidates:y(BB),stats:LB});const D0=j(["own","direct-competitor","ota-aggregator","editorial-media","other"]);D0.enum;const Nm=j(["7d","30d","90d","all"]),Dw=j(["improving","declining","stable"]),$B=j(["mentioned","cited"]);$B.enum;const Wf=d({citationRate:we(),cited:m().int(),total:m().int(),mentionRate:we(),mentionedCount:m().int()}),Wr=o().trim().min(1),VB=y(Wr).min(1).superRefine((e,n)=>{for(let i=1;i<e.length;i+=1)e[i-1]>=e[i]&&n.addIssue({code:"custom",message:"mixed model IDs must be sorted and unique",path:[i]})}),No=Le("status",[d({status:R("known"),model:Wr}),d({status:R("unknown")}),d({status:R("mixed"),models:VB,includesUnknown:_()})]),UB=d({observedAt:o(),bucketStartDate:o(),from:No,to:No,fromPreWindowAnchor:_().optional(),anchorObservedAt:o().optional()}),f3=d({latestObservation:d({observedAt:o(),state:No}),events:y(UB),eventTotal:m().int().nonnegative().optional(),anchorUnavailable:_().optional()}),GB=Qe(o(),f3),KB=f3.extend({latestServedModelIds:y(Wr).default([])}),HB=Qe(o(),KB),QB=d({observedAt:o(),configured:No,served:No}),FB=d({scope:j(["non-brand","pooled"]),rate:we().nullable(),projectMentionSnapshots:m().int().nonnegative(),competitorMentionSnapshots:m().int().nonnegative()}),ZB=d({startDate:o(),endDate:o(),dataStartDate:o(),dataEndDate:o(),sweepCount:m().int().nonnegative(),citationRate:we(),cited:m().int(),total:m().int(),queryCount:m().int(),mentionRate:we(),mentionedCount:m().int(),mentionShare:FB,byProvider:Qe(o(),Wf),modelEvidenceByProvider:Qe(o(),No).default({}),basketRevision:m().int().nullable().default(null)}),ff=d({first:we(m().min(0).max(1)),latest:we(m().min(0).max(1)),delta:we(m().min(-1).max(1))}),YB=d({citationRate:ff.nullable(),mentionRate:ff.nullable(),mentionShare:ff.nullable()}),XB=d({revision:m().int(),at:o(),added:y(o()),removed:y(o())}),JB=d({date:o(),delta:m().int(),label:o()}),WB=d({at:o(),identity:B2});d({window:Nm,mentionShareScope:j(["non-brand","pooled"]),buckets:y(ZB),overall:Wf,byProvider:Qe(o(),Wf),trend:Dw,mentionTrend:Dw,windowChange:YB.default(()=>({citationRate:null,mentionRate:null,mentionShare:null})),queryChanges:y(JB),basketChanges:y(XB).default([]),executionIdentityChanges:y(WB).default([]),referenceBasketRevision:m().int().nullable().default(null),modelAttribution:GB.default({}),servedModelAttribution:HB.default({}),modelServiceMismatch:Qe(o(),QB).default({}),modelPointerChanges:Qe(o(),rP).default({})});const zw=d({category:E0,label:o(),count:m().int(),percentage:we(),topDomains:y(d({domain:o(),count:m().int()}))}),eL=d({domain:o(),rank:m().int().positive().optional(),count:m().int(),percentage:we(),answerShare:we().optional(),category:E0,label:o(),surfaceClass:D0}),tL=d({surfaceClass:D0,label:o(),count:m().int(),percentage:we(),domainCount:m().int()}),Iw=d({totalCitedSlots:m().int(),answerTotal:m().int().optional(),answersWithSources:m().int().optional(),domainTotal:m().int(),entries:y(eL),truncatedDomainCount:m().int(),truncatedCitedSlots:m().int(),bySurfaceClass:y(tL)}),nL=d({answers:y(o()),distinctDomains:y(o()),answerDomainPairs:y(o()),runs:y(o())}),aL=j(["measurement-plan","query-text"]);d({runId:o().trim().min(1).optional(),queryClass:Zg.optional(),includeByQuery:j(["true","false","1","0"]).optional()});d({ranked:Iw,byProvider:Qe(o(),Iw),providersWithoutSources:y(o()).optional(),answerTotal:m().int().optional(),runCount:m().int().optional(),pooledAcrossRuns:_().optional(),unclassifiedAnswers:m().int().optional(),filters:d({runId:o().nullable(),queryClass:Zg,queryClassBasis:Ze([aL,de()]),includeByQuery:_()}).optional(),runId:o(),runIds:y(o()).optional(),countUnits:nL.optional(),window:Nm,limit:m().int().nullable(),overall:y(zw),byQuery:Qe(o(),y(zw)).optional()});const iL=j(["own","direct-competitor","ota-aggregator","editorial-media","other","unknown"]),sL=Le("kind",[d({kind:R("project")}).strict(),d({kind:R("group"),groupKey:o().trim().min(1)}).strict(),d({kind:R("all-markets")}).strict()]),g3=j(["all","branded","non-brand"]),y3=j(["project","all-markets"]);d({window:Nm.optional(),groupKey:o().trim().min(1).optional(),scope:y3.optional(),provider:o().trim().min(1).optional(),model:Wr.optional(),groupBy:R("model").optional(),queryClass:g3.optional(),location:o().trim().min(1).optional(),runId:o().trim().min(1).optional()}).strict().superRefine((e,n)=>{e.scope==="all-markets"&&e.groupKey!==void 0&&n.addIssue({code:"custom",path:["groupKey"],message:"groupKey cannot be combined with scope=all-markets"}),e.model!==void 0&&e.provider===void 0&&n.addIssue({code:"custom",path:["provider"],message:"provider is required when filtering by model"})});const As=d({domain:o().trim().min(1),label:o().trim().min(1),surfaceClass:iL,pinned:_(),mentionCount:m().int().nonnegative(),shareOfVoice:Oe(m().min(0).max(100)).nullable(),citationCount:m().int().nonnegative(),answeredResults:m().int().nonnegative(),firstSeenAt:o().datetime().nullable(),lastSeenAt:o().datetime().nullable(),sampleUrls:y(o().url()).max(3)}).strict(),b3=d({answeredResults:m().int().nonnegative(),sourceResults:m().int().nonnegative(),missingAnswerTextResults:m().int().nonnegative(),mentionCredits:m().int().nonnegative(),incompleteSourceResults:m().int().nonnegative(),excludedProbeResults:m().int().nonnegative(),excludedNonCompletedResults:m().int().nonnegative()}).strict(),oL=d({answers:y(o()),distinctNames:y(o()),runs:y(o())}).strict(),rL=50,lL=d({...T0,comparison:y(d({domain:o(),mentions:m().int().nonnegative()})).optional(),observedNames:y(d({name:o(),answerCount:m().int().nonnegative()})).optional(),observedNamesTotal:m().int().nonnegative().optional(),provider:o().trim().min(1),model:Wr.nullable(),servedModels:No,snapshotCount:m().int().positive(),project:As,pinned:y(As),observed:y(As),otherSources:y(As),evidence:b3,truncated:_()}).strict(),cL=d({basis:R("requested-model"),groups:y(lL).max(rL),totalGroups:m().int().nonnegative(),truncated:_()}).strict();d({...T0,comparison:y(d({domain:o(),mentions:m().int().nonnegative()})).optional(),observedNames:y(d({name:o(),answerCount:m().int().nonnegative()})).optional(),observedNamesTotal:m().int().nonnegative().optional(),window:Nm,scope:sL,project:As,pinned:y(As),observed:y(As),otherSources:y(As),evidence:b3,modelComparison:cL.optional(),marketState:d({activeRevision:m().int().positive(),draft:d({etag:o().trim().min(1),pendingCompetitorDomains:y(o().trim().min(1))}).strict().nullable()}).strict().nullable(),filters:d({scope:y3,groupKey:o().nullable(),provider:o().nullable(),model:Wr.optional(),groupBy:R("model").optional(),queryClass:g3,location:o().nullable(),runId:o().nullable()}).strict(),truncated:_(),runCount:m().int().nonnegative().optional(),runIds:y(o()).optional(),countUnits:oL.optional()}).strict();const z0=d({total:m().int(),checked:m().int(),mentioned:m().int(),cited:m().int(),mentionRate:we().nullable(),citedRate:we().nullable()}),v3=z0.extend({provider:o(),firstObserved:o(),lastObserved:o()}),uL=z0.extend({queryId:o().nullable(),query:o(),firstObserved:o(),lastObserved:o(),providers:y(v3).optional()}),dL=d({since:o().nullable(),until:o().nullable(),lastRuns:m().int().nullable(),runCount:m().int()}),mL=j(["provider"]),eg=d({domain:o(),mentions:m().int()}),x3=d({...T0,measurementScope:j(["project","all-markets"]).optional(),queryClass:j(["branded","non-brand","pooled"]),percent:Oe().nullable(),competitorCount:m().int().nonnegative(),projectMentions:m().int(),competitorMentions:m().int(),snapshotsWithAnswerText:m().int(),perCompetitor:y(eg)});d({project:o(),groupBy:mL.optional(),window:dL,totals:z0,byProvider:y(v3).optional(),queries:y(uL),shareOfVoice:x3.optional()});const pL=j(["within-noise","moved","insufficient-data","model-discontinuous","model-unknown"]),hL=j(["up","down","flat"]),Ow=d({availability:j(["available","no-observations","no-competitive-frame","classification-unavailable"]),point:we().nullable(),ciLow:we().nullable(),ciHigh:we().nullable(),numerator:m().int(),denominator:m().int(),excludedUnknown:m().int().nonnegative().optional()}),fL=j(["mention-share-of-voice","cited-share-of-voice","mention-rate","cited-rate","mention-rate-branded","cited-rate-branded","mention-rate-non-brand","cited-rate-non-brand"]),gL=d({key:fL,label:o(),queryClass:j(["all","branded","non-brand","pooled"]),driftRobust:_(),from:Ow,to:Ow,rateRatio:m().nullable(),direction:Ze([hL,de()]),verdict:pL}),Hd=d({month:o(),since:o(),until:o(),runCount:m().int(),lowRunCount:_()}),w3=d({queryCount:m().int(),excludedFromOnly:m().int(),excludedToOnly:m().int(),providers:y(o()),excludedProviders:y(o())}),S3=d({provider:o(),fromModels:y(o()),toModels:y(o())}),yL=j(["included","model-discontinuous","model-unknown"]),bL=d({provider:o(),status:yL,fromModels:y(o()),toModels:y(o())}),vL=j(["comparable","model-discontinuous","model-unknown","insufficient-data"]),k3=d({status:vL,comparedProviders:y(o()),providers:y(bL)}),xL=d({provider:o(),from:d({checked:m().int(),mentioned:m().int(),cited:m().int()}),to:d({checked:m().int(),mentioned:m().int(),cited:m().int()})}),wL=d({from:d({count:m().int(),of:m().int()}),to:d({count:m().int(),of:m().int()})}),SL=d({scope:j(["project","group","market","property"]).optional(),scopeKey:o().min(1).optional(),marketKey:o().min(1).optional(),provider:o().min(1).optional(),location:o().min(1).optional()}),kL=d({from:Hd,to:Hd,basket:w3,continuity:k3,modelChanges:y(S3)});d({project:o(),selection:SL.optional(),classComparison:kL.optional(),from:Hd,to:Hd,basket:w3,metrics:y(gL),queriesMentioned:wL,byProvider:y(xL),modelChanges:y(S3),continuity:k3,competitors:d({from:y(eg),to:y(eg)})});j(["json","csv"]);const jL=d({runId:o(),runKind:R("answer-visibility"),runStatus:ha,runTrigger:p0,runCreatedAt:o(),runStartedAt:o().nullable(),runFinishedAt:o().nullable(),snapshotId:o(),snapshotCreatedAt:o(),queryId:o().nullable(),query:o().nullable(),provider:o(),model:o().nullable(),location:o().nullable(),citationState:$i,cited:_(),answerMentioned:_().nullable(),mentionState:Ze([Cc,de()]),citedDomains:y(o()),citedUrls:y(o()).nullable(),captureStatus:Ze([hm,de()]),sourceCount:m().int().nonnegative().nullable(),resolvedCount:m().int().nonnegative().nullable(),captureVersion:m().int().positive().nullable(),competitorOverlap:y(o()),recommendedCompetitors:y(o()),answerText:o().nullable(),groundingSources:y(gm),searchQueries:y(o())}),AL=d({since:o().nullable(),until:o().nullable(),includeProbes:_()});d({schemaVersion:R("canonry.results-export/v1"),generatedAt:o(),project:d({id:o(),name:o(),displayName:o(),canonicalDomain:o(),country:o(),language:o()}),filters:AL,recordCount:m().int().nonnegative(),records:y(jL)});d({runIds:y(o().trim().min(1)).max(100).default([]),researchRunIds:y(o().trim().min(1)).max(100).default([]),confirm:_().default(!1)}).strict().superRefine((e,n)=>{e.runIds.length+e.researchRunIds.length===0&&n.addIssue({code:"custom",message:"Select at least one saved run."}),(new Set(e.runIds).size!==e.runIds.length||new Set(e.researchRunIds).size!==e.researchRunIds.length)&&n.addIssue({code:"custom",message:"Run IDs must be unique."})});d({dryRun:_(),runIds:y(o()),researchRunIds:y(o()),querySnapshots:m().int().nonnegative(),researchQueries:m().int().nonnegative(),insights:m().int().nonnegative(),healthSnapshots:m().int().nonnegative()});const _m=j(["organic","paid"]);_m.enum;d({id:o(),projectId:o(),propertyId:o(),clientEmail:o(),connected:_(),createdAt:o(),updatedAt:o()});d({date:o(),landingPage:o(),sessions:m(),organicSessions:m(),users:m()});const I0=j(["session","first_user","manual_utm"]),CL=d({source:o(),medium:o(),trafficClass:_m,sessions:m(),users:m().optional(),sourceDimension:I0,share:we()}),NL=d({source:o(),medium:o(),trafficClass:_m,sourceDimension:I0,landingPage:o(),sessions:m(),users:m().optional()}),_L=d({source:o(),medium:o(),sessions:m(),users:m().optional(),channelGroup:o(),share:we()}),rc=d({sessions:m(),sharePct:Oe(),sharePctDisplay:o()}),TL=d({organic:rc,social:rc,direct:rc,ai:rc,other:rc}),EL=d({totalSessions:m(),totalOrganicSessions:m(),totalDirectSessions:m(),totalUsers:m().nullable(),topPages:y(d({landingPage:o(),sessions:m(),organicSessions:m(),directSessions:m(),users:m(),organicShare:we().nullable()})),aiReferrals:y(CL),aiReferralLandingPages:y(NL),aiSessionsDeduped:m(),aiUsersDeduped:m().optional(),paidAiSessionsDeduped:m(),paidAiUsersDeduped:m().optional(),organicAiSessionsDeduped:m(),organicAiUsersDeduped:m().optional(),aiSessionsBySession:m(),aiUsersBySession:m().optional(),paidAiSessionsBySession:m(),paidAiUsersBySession:m().optional(),organicAiSessionsBySession:m(),organicAiUsersBySession:m().optional(),socialReferrals:y(_L),socialSessions:m(),socialUsers:m().optional(),channelBreakdown:TL,organicSharePct:Oe(),aiSharePct:Oe(),aiSharePctBySession:Oe(),paidAiSharePct:Oe(),paidAiSharePctBySession:Oe(),organicAiSharePct:Oe(),organicAiSharePctBySession:Oe(),directSharePct:Oe(),socialSharePct:Oe(),organicSharePctDisplay:o(),aiSharePctDisplay:o(),aiSharePctBySessionDisplay:o(),paidAiSharePctDisplay:o(),paidAiSharePctBySessionDisplay:o(),organicAiSharePctDisplay:o(),organicAiSharePctBySessionDisplay:o(),directSharePctDisplay:o(),socialSharePctDisplay:o(),otherSessions:m(),otherSharePct:Oe(),otherSharePctDisplay:o(),lastSyncedAt:o().nullable()});d({connected:_(),propertyId:o().nullable(),clientEmail:o().nullable(),authMethod:j(["service-account","oauth"]).nullable(),lastSyncedAt:o().nullable(),createdAt:o().nullable().optional(),updatedAt:o().nullable().optional()});const RL=d({propertyId:o(),displayName:o(),accountName:o()});d({properties:y(RL)});d({synced:_(),rowCount:m().int().nonnegative(),aiReferralCount:m().int().nonnegative(),socialReferralCount:m().int().nonnegative(),days:m().int().nonnegative(),requestedDays:m().int().nonnegative(),clamped:_(),syncedAt:o(),measurement:d({acquisition:d({days:m().int().nonnegative(),status:j(["ready","error"]),rowCount:m().int().nonnegative(),error:o().optional()}),leads:d({days:m().int().nonnegative(),status:j(["ready","error","not-configured"]),rowCount:m().int().nonnegative(),attributionScope:j(["landing-page","channel"]).optional(),error:o().optional()})}),syncedComponents:y(o()).optional()});const j3=j(["new","small-base","percent"]);j3.enum;const tg=d({source:o(),sessions7d:m(),sessionsPrev7d:m(),changeSessions:m(),changePct:Oe().nullable(),changeBasis:j3});d({socialSessions7d:m(),socialSessionsPrev7d:m(),trend7dPct:Oe().nullable(),socialSessions30d:m(),socialSessionsPrev30d:m(),trend30dPct:Oe().nullable(),biggestMover:tg.nullable()});const lc=d({sessions7d:m(),sessionsPrev7d:m(),trend7dPct:Oe().nullable(),sessions30d:m(),sessionsPrev30d:m(),trend30dPct:Oe().nullable()});d({organic:lc,ai:lc,social:lc,direct:lc,total:lc,aiBiggestMover:tg.nullable(),socialBiggestMover:tg.nullable()});EL.extend({windowStart:o().nullable(),windowEnd:o().nullable(),windowDays:m().nullable(),periodStart:o().nullable(),periodEnd:o().nullable()});d({date:o(),source:o(),medium:o(),trafficClass:_m,landingPage:o(),sessions:m(),users:m(),sourceDimension:I0});const DL=d({source:o(),sessions:m(),paidSessions:m(),organicSessions:m()}),zL=d({date:o(),sessions:m(),paidSessions:m(),organicSessions:m(),bySource:y(DL)});d({days:y(zL),sources:y(o()),totalSessions:m(),totalPaidSessions:m(),totalOrganicSessions:m()});d({date:o(),source:o(),medium:o(),sessions:m(),users:m(),channelGroup:o()});d({date:o(),sessions:m(),organicSessions:m(),users:m(),usersSource:j(["deduplicated","landing-page-sum"])});d({id:o(),projectId:o(),runId:o().nullable(),overallCitedRate:we(),overallMentionRate:we(),totalPairs:m().int().nonnegative(),citedPairs:m().int().nonnegative(),mentionedPairs:m().int().nonnegative(),providerBreakdown:Qe(o(),d({citedRate:we(),mentionRate:we(),cited:m().int().nonnegative(),mentioned:m().int().nonnegative(),total:m().int().nonnegative()})),createdAt:o(),status:j(["ready","no-data"]),reason:R("no-runs-yet").optional()});const IL=d({view:j(["project","visibility","property","queries","site-health"]),unavailableReason:o().trim().min(1).max(512).optional(),selection:Ld.optional(),page:d({runId:o().trim().min(1).max(256).optional(),nodeKey:o().trim().min(1).max(2048).optional()}).strict().optional()}).strict().superRefine((e,n)=>{e.page&&e.view!=="site-health"&&n.addIssue({code:"custom",message:"Page context requires Site Health."}),e.selection&&!["visibility","property","queries"].includes(e.view)&&n.addIssue({code:"custom",message:"Measurement selection requires a measurement view."})}),OL=d({maxToolCalls:m().int().min(1).max(100).default(30),timeoutMs:m().int().min(1e3).max(6e5).default(18e4)}).strict(),O0=j(["claude","openai","gemini","zai"]),qL=d({id:O0,label:o(),defaultModel:o(),configured:_(),keySource:j(["config","env"]).nullable()});d({providers:y(qL).default([]),defaultProvider:O0.nullable()});const PL=j(["aero","user","compaction"]);PL.enum;const A3=128;d({key:o().min(1).max(A3),value:o().min(1)});d({key:o().min(1).max(A3)});d({prompt:o().trim().min(1),conversationId:o().min(1).nullable().optional(),provider:O0.optional(),modelId:o().trim().min(1).optional(),scope:j(["all","read-only"]).optional(),profile:j(["default","ads-operator"]).optional(),context:IL.optional(),limits:OL.optional()});const ML=$D({role:o(),content:jn().optional()}),C3=d({id:o(),title:o(),active:_(),modelProvider:o(),modelId:o(),createdAt:o(),updatedAt:o()});C3.extend({messages:y(ML),isStreaming:_()});d({conversations:y(C3),currentConversationId:o().nullable(),nextOffset:m().int().nullable()});d({id:yD()}).strict();d({id:o(),status:R("deleted")});const BL=["status","changes","gaps","insights"],LL=j(BL),$L=d({text:o().optional(),tool:d({name:o(),label:o(),arguments:Qe(o(),jn()),result:jn(),durationMs:m().int().nonnegative()})}),VL=d({id:LL,steps:y($L),answer:o()});d({project:o(),seededAt:o(),starters:y(VL)});d({offset:Bi().int().min(0).default(0),limit:Bi().int().min(1).max(100).default(50)}).strict();const el=j(["commoncrawl","bing-webmaster"]);el.enum;const q0=j(["queued","downloading","querying","ready","failed"]);q0.enum;d({id:o(),release:o(),status:q0,phaseDetail:o().nullable().optional(),vertexPath:o().nullable().optional(),edgesPath:o().nullable().optional(),vertexSha256:o().nullable().optional(),edgesSha256:o().nullable().optional(),vertexBytes:m().int().nullable().optional(),edgesBytes:m().int().nullable().optional(),projectsProcessed:m().int().nullable().optional(),domainsDiscovered:m().int().nullable().optional(),downloadStartedAt:o().nullable().optional(),downloadFinishedAt:o().nullable().optional(),queryStartedAt:o().nullable().optional(),queryFinishedAt:o().nullable().optional(),error:o().nullable().optional(),createdAt:o(),updatedAt:o()});const UL=d({linkingDomain:o(),numHosts:m().int(),source:el}),GL=d({projectId:o(),release:o(),targetDomain:o(),totalLinkingDomains:m().int(),totalHosts:m().int(),top10HostsShare:o(),queriedAt:o(),source:el,excludedLinkingDomains:m().int().optional(),excludedHosts:m().int().optional()});d({source:el,summary:GL.nullable(),total:m().int(),rows:y(UL)});d({release:o(),totalLinkingDomains:m().int(),totalHosts:m().int(),top10HostsShare:o(),queriedAt:o(),source:el});const KL=d({source:el,connected:_(),hasData:_(),latestRelease:o().nullable(),totalLinkingDomains:m().int(),lastSyncedAt:o().nullable()});d({projectId:o(),targetDomain:o(),sources:y(KL),anyConnected:_(),anyData:_()});d({duckdbInstalled:_(),duckdbVersion:o().nullable().optional(),duckdbSpec:o(),pluginDir:o()});d({installed:_(),version:o(),path:o(),alreadyPresent:_()});d({release:o(),vertexUrl:o(),edgesUrl:o(),vertexBytes:m().int().nullable(),edgesBytes:m().int().nullable(),lastModified:o().nullable()});d({release:o(),syncStatus:q0.nullable(),bytes:m().int(),lastUsedAt:o().nullable()});const HL="jev-1.13.0",Ee=o().trim().min(1).max(256),_t=m().int().nonnegative(),N3=zs(e=>typeof e=="string"?[e]:e,y(Ee).min(1).max(100)),Cd=we(m().min(0).max(1)).nullable(),Lr=j(["favorable","mixed","unfavorable","factual","subject-not-mentioned","wrong-subject","ambiguous-subject","ambiguous-judgment","subject-not-applicable","unsupported-language","missing-source-text","input-too-large","invalid-conclusion-evidence","pending","running","waiting-to-retry","failed","canceled"]);Lr.enum;const P0=j(["disabled","not-measured","processing","partial","complete","failed","canceled","unsupported"]),M0=d({schemaVersion:Ze([R(1),R(2)]),requestedModel:R(HL),verdictVersion:Ee,identityVersion:Ee,evidenceVersion:Ee,segmentationVersion:Ee,preprocessingVersion:Ee,languagePolicy:R("en-only"),comparisonMethodVersion:R("wilson-independent-v1"),confidenceThreshold:m().min(0).max(1).nullable(),questions:d({identity:o(),judgment:o(),stance:o(),conclusion:o(),complaint:o()}).strict()}).strict();function _3(e){if(typeof e!="object"||e===null||!("schemaVersion"in e)||e.schemaVersion!==1)return e;const n=Object.fromEntries(Object.entries(e).filter(([i])=>i!=="themes"));return typeof n.questions=="object"&&n.questions!==null&&(n.questions=Object.fromEntries(Object.entries(n.questions).filter(([i])=>i!=="theme"))),n}zs(_3,M0);const T3=d({id:Ee,displayName:o(),aliases:y(o()),qualifiedAliases:y(o()).default([]),urls:y(o()),mentionNotApplicable:_()}).strict(),QL=d({queryId:Ee,executionNodeKey:Ee.nullable(),targetId:Ee,propertyId:Ee.nullable(),groupId:Ee.nullable(),marketId:Ee.nullable(),queryClass:j(["branded","non-brand"]),queryText:o().optional(),location:o().nullable()}).strict(),E3=d({queryId:Ee,queryText:o(),queryClass:j(["branded","non-brand"]),provider:Ee,requestedModel:o().nullable(),servedModel:o().nullable(),location:o().nullable(),revision:m().int().nullable(),usageEdges:y(QL),locationContext:dn.nullable().default(null)}).strict(),_c=d({id:Ee,text:o().min(1),start:_t,end:_t}).strict(),R3=d({kind:j(["reported","estimated","unknown"]),inputTokens:_t.nullable(),outputTokens:_t.nullable()}).strict(),FL=d({sourceSnapshotId:Ee,sourceText:o(),sourceTextHash:Ee,subject:T3,subjectHash:Ee,context:E3,language:o(),definition:M0,sentences:y(_c)}).strict();zs(e=>typeof e!="object"||e===null||!("definition"in e)?e:{...e,definition:_3(e.definition)},FL);const gf={returnedModel:o().nullable(),usage:R3},ZL=Le("kind",[d({kind:R("classified"),...gf,returnedModel:o(),outcome:Lr,conclusion:y(_c),complaint:y(_c).nullable(),confidence:m().min(0).max(1).nullable()}).strict(),d({kind:R("abstained"),...gf,outcome:Lr,reason:o()}).strict(),d({kind:R("failed"),...gf,outcome:R("failed"),error:d({code:Ee,message:o(),retryable:_(),retryAfterMs:m().nonnegative().nullable()}).strict()}).strict()]).superRefine((e,n)=>{e.kind==="classified"&&["favorable","mixed","unfavorable"].includes(e.outcome)&&e.conclusion.length===0&&n.addIssue({code:"custom",path:["conclusion"],message:"Judgments require conclusion evidence"})});zs(e=>typeof e=="object"&&e!==null?Object.fromEntries(Object.entries(e).filter(([n])=>n!=="themes")):e,ZL);const tl=d({runId:Ee.optional(),runIds:N3.optional(),revision:Bi().int().positive().optional(),mode:j(["auto","simple","advanced"]).default("auto"),queryClass:j(["branded","non-brand"]).default("branded"),scope:j(["project","property","group","market"]).default("project"),queryId:Ee.optional(),scopeKey:Ee.optional(),marketKey:Ee.optional(),provider:Ee.optional(),model:Ee.optional(),location:o().min(1).optional(),evaluationDefinitionId:Ee.optional(),executionNodeKey:Ee.optional()}).strict();function $c(e,n){e.runId&&e.runIds&&n.addIssue({code:"custom",path:["runIds"],message:"Choose runId or runIds, not both."}),e.runIds&&new Set(e.runIds).size!==e.runIds.length&&n.addIssue({code:"custom",path:["runIds"],message:"Run IDs must be unique."})}tl.superRefine($c);const YL=j(["assessments","locations"]),XL=25,D3=500;tl.extend({include:zs(e=>typeof e=="string"?e.split(",").map(n=>n.trim()).filter(Boolean):e,y(YL).max(2)).optional(),queryLimit:Bi().int().min(1).max(D3).default(XL),queryCursor:o().min(1).max(16384).optional()}).superRefine($c);tl.extend({assessmentId:Ee.optional(),cursor:o().min(1).max(16384).optional(),limit:Bi().int().min(1).max(100).default(50)}).superRefine($c);tl.extend({fromRunId:Ee,toRunId:Ee}).superRefine((e,n)=>{$c(e,n),e.runIds&&n.addIssue({code:"custom",path:["runIds"],message:"Comparison requires one explicit run per period."})});const B0=tl.extend({runId:Ee.nullable(),revision:m().int().nullable(),evaluationDefinitionId:Ee.nullable(),mode:j(["simple","advanced"])}),L0=d(Object.fromEntries(Lr.options.map(e=>[e,_t]))).strict(),JL=d({selected:_t,eligibleAssessments:_t,unadmittedAssessments:_t,judged:_t,distinctSourceAnswers:_t,eligibleAnswers:_t.optional(),ratedAnswers:_t.optional(),ratedAnswerRate:Cd.optional(),counts:L0,expectedProviderSlots:_t,completedProviderSlots:_t}).strict(),WL=d({favorableRate:Cd,mixedRate:Cd,unfavorableRate:Cd,favorableDisplay:o(),mixedDisplay:o(),unfavorableDisplay:o(),interval:d({low:m(),high:m()}).strict().nullable(),method:R("wilson-independent-v1"),limitation:o()}).strict(),$r={state:P0,reason:o().nullable(),provisional:_(),coverage:JL,score:WL},qw=d({...$r,selection:B0,runIds:y(Ee)}).strict(),e$=d({...$r,queryClass:R("all"),runIds:y(Ee)}).strict(),t$=d({configured:_(),branded:qw,nonBrand:qw,overall:e$.optional()}).strict(),n$=d({assessmentId:Ee.nullable(),sourceSnapshotId:Ee,runId:Ee,subjectId:Ee,subjectLabel:o(),executionNodeKey:Ee.nullable(),provider:Ee,requestedModel:o().nullable(),servedModel:o().nullable(),location:o().nullable(),evaluationDefinitionId:Ee.nullable(),state:P0,outcome:Ze([Lr,de()]),reason:o().nullable()}).strict(),a$=d({...$r,queryId:Ee,executionNodeKey:Ee.nullable().optional(),queryText:o(),queryClass:j(["branded","non-brand"]),sourceSnapshotIds:y(Ee),assessments:y(n$).default([]),locations:y(d({...$r,location:o().nullable(),sourceSnapshotIds:y(Ee)}).strict())}).strict(),i$=d({...$r,dimension:j(["provider","property","market","query"]),key:o(),label:o(),queryClass:j(["branded","non-brand"])}).strict(),ng=d({...$r,configured:_(),selection:B0,evaluationDefinition:M0.nullable(),breakdowns:y(i$),queries:y(a$),queryPage:d({total:_t,limit:_t,nextCursor:o().nullable()}).strict().optional()}).strict();d({enabled:_().optional()}).strict();const s$=d({installEnabled:_(),enabled:_(),ready:_(),readinessReasons:y(o()),model:o(),enablementEpoch:_t,completionBoundary:_t,evaluationDefinitionId:Ee.nullable(),actions:d({configure:_(),backfill:_()}).strict(),experimental:R(!0),disclosure:o()}).strict(),z3=tl.extend({runIds:N3.optional(),from:o().datetime().optional(),to:o().datetime().optional()}).superRefine($c);d({previewToken:o().min(1).max(65536),idempotencyKey:o().trim().min(1).max(128)}).strict();const o$=d({previewToken:o().nullable(),expiresAt:o().nullable(),selection:z3,evaluationDefinitionId:Ee.nullable(),eligibleAssessments:_t,alreadyClassified:_t,skipped:y(d({runId:Ee,reason:o(),count:_t}).strict()),estimatedInputTokens:_t,estimatedCostUsd:m().nonnegative().nullable(),estimateMethod:o()}).strict(),r$=j(["pending","running","waiting-to-retry","complete","partial","failed","canceled"]),l$=d({id:Ee,workItemId:Ee,dispatchedAt:o(),completedAt:o().nullable(),returnedModel:o().nullable(),usage:R3,errorCode:o().nullable()}).strict(),I3=d({id:Ee,projectId:Ee,origin:j(["automatic","backfill"]),state:r$,enablementEpoch:_t,evaluationDefinitionId:Ee,selection:z3,createdAt:o(),updatedAt:o(),counts:L0,selected:_t,cancellationReason:o().nullable(),attempts:y(l$),attemptCount:_t.optional(),nextAttemptCursor:o().nullable().optional()}).strict(),c$=I3.omit({attempts:!0,attemptCount:!0,nextAttemptCursor:!0}).extend({attemptCount:_t}).strict(),u$=d({jobs:y(c$)}).strict(),d$=50;d({attemptLimit:Bi().int().min(1).max(200).default(d$),attemptCursor:o().min(1).max(4096).optional()}).strict();const m$=d({assessmentId:Ee,runId:Ee,sourceSnapshotId:Ee,sourceText:o(),sourceTextHash:Ee,subject:T3,subjectHash:Ee,context:E3,evaluationDefinitionId:Ee,outcome:Lr,conclusion:y(_c),complaint:y(_c).nullable(),returnedModel:o().nullable(),reason:o().nullable()}).strict(),p$=d({state:P0,selection:B0.extend({assessmentId:Ee.optional()}),items:y(m$),nextCursor:o().nullable()}).strict(),h$=d({from:ng,to:ng,verdict:j(["improved","declined","no-clear-change"]).nullable(),favorableRateDelta:m().nullable(),refusalReasons:y(o()),commonUnits:_t,excludedFrom:_t,excludedTo:_t,changedScope:_(),method:R("wilson-independent-v1"),limitation:o()}).strict(),$0=j(["positive","caution","negative","neutral"]),js=d({label:o(),value:o(),delta:o(),tone:$0,description:o(),tooltip:o().optional(),trend:y(Oe()),progress:Oe().optional(),providerCoverage:o().optional()}),Pw=d({projectMentionSnapshots:m().int().nonnegative(),competitorMentionSnapshots:m().int().nonnegative(),combinedMentionSnapshots:m().int().nonnegative(),perCompetitor:y(d({domain:o(),mentionSnapshots:m().int().nonnegative(),shareOfCompetitiveTotal:Oe()})),ranking:y(d({kind:j(["project","competitor"]),domain:o().nullable(),mentionSnapshots:m().int().nonnegative(),share:we(m().min(0).max(1))})),snapshotsWithAnswerText:m().int().nonnegative(),snapshotsTotal:m().int().nonnegative(),score:Oe(m().min(0).max(100)).nullable()}),f$=js.extend({breakdown:Pw,scope:j(["non-brand","pooled"]),branded:Pw}),yf=d({gained:m().int().nonnegative(),lost:m().int().nonnegative(),tone:$0,hasPreviousRun:_(),gainedQueries:y(o()).optional(),lostQueries:y(o()).optional()}),g$=d({hasPreviousRun:_(),comparable:_(),querySetChanged:_(),previousRunAt:o().nullable(),currentQueryCount:m().int().nonnegative(),previousQueryCount:m().int().nonnegative(),comparableQueryCount:m().int().nonnegative(),addedQueryCount:m().int().nonnegative(),removedQueryCount:m().int().nonnegative(),addedQueries:y(o()),removedQueries:y(o())}),y$=d({id:o(),projectId:o(),runId:o().nullable(),type:j(["regression","gain","opportunity","first-citation","provider-pickup","persistent-gap","competitor-gained","competitor-lost","gbp-lodging-gap","gbp-listing-discrepancy","gbp-cta-gap","gbp-description-missing","gbp-metric-drop","gbp-keyword-drop"]),severity:j(["critical","high","medium","low"]),title:o(),query:o(),provider:o(),recommendation:d({action:o(),target:o().optional(),reason:o()}).optional(),cause:d({cause:o(),competitorDomain:o().optional(),details:o().optional()}).optional(),dismissed:_(),createdAt:o()}),b$=d({id:o(),projectId:o(),runId:o().nullable(),overallCitedRate:we(),overallMentionRate:we(),totalPairs:m().int().nonnegative(),citedPairs:m().int().nonnegative(),mentionedPairs:m().int().nonnegative(),providerBreakdown:Qe(o(),d({citedRate:we(),mentionRate:we(),cited:m().int().nonnegative(),mentioned:m().int().nonnegative(),total:m().int().nonnegative()})),createdAt:o(),status:j(["ready","no-data"]),reason:R("no-runs-yet").optional()});d({sentiment:t$.optional(),project:L9,latestRun:FO,health:b$.nullable(),topInsights:y(y$),queryClassScope:d({queryClass:R("all"),figures:y(o()),note:o()}).optional(),queryCounts:d({totalQueries:m().int().nonnegative(),citedQueries:m().int().nonnegative(),notCitedQueries:m().int().nonnegative(),citedRate:we(),mentionedQueries:m().int().nonnegative(),notMentionedQueries:m().int().nonnegative(),mentionRate:we()}),providers:y(d({provider:o(),citedRate:we(),cited:m().int().nonnegative(),total:m().int().nonnegative()})),transitions:d({since:o().nullable(),gained:m().int().nonnegative(),lost:m().int().nonnegative(),emerging:m().int().nonnegative()}),scores:d({mention:js,visibility:js,mentionShare:f$,gapQueries:js,mentionGaps:js,indexCoverage:js,competitorPressure:js,runStatus:js}),movementSummary:yf,citationMovement:yf,mentionMovement:yf,movementComparison:g$,competitors:y(d({id:o(),domain:o(),citationCount:m().int().nonnegative(),totalQueries:m().int().nonnegative(),pressureLabel:j(["None","Low","Moderate","High"]),citedQueries:y(o())})),providerScores:y(d({provider:o(),model:o().nullable(),score:Oe(),cited:m().int().nonnegative(),total:m().int().nonnegative(),trend:y(Oe()).optional()})),attentionItems:y(d({id:o(),tone:$0,title:o(),detail:o(),actionLabel:o(),href:o()})),runHistory:y(d({runId:o(),createdAt:o(),citedCount:m().int().nonnegative(),totalCount:m().int().nonnegative(),citationRate:Oe(),mentionedCount:m().int().nonnegative(),mentionRate:Oe(),status:o()})),suggestedQueries:d({rows:y(d({query:o(),impressions:m(),clicks:m(),avgPosition:m(),reason:o()})),totalCandidates:m().int().nonnegative(),skippedAlreadyTracked:m().int().nonnegative()}),dateRangeLabel:o(),contextLabel:o()});j(["snapshot","insight"]);const v$=d({kind:R("snapshot"),id:o(),runId:o(),query:o(),provider:o(),model:o().nullable(),citationState:$i,matchedField:j(["answerText","citedDomains","citedUrls","searchQueries","query"]),snippet:o(),createdAt:o()}),x$=d({kind:R("insight"),id:o(),runId:o().nullable(),type:j(["regression","gain","opportunity","first-citation","provider-pickup","persistent-gap","competitor-gained","competitor-lost","gbp-lodging-gap","gbp-listing-discrepancy","gbp-cta-gap","gbp-description-missing","gbp-metric-drop","gbp-keyword-drop"]),severity:j(["critical","high","medium","low"]),title:o(),query:o(),provider:o(),matchedField:j(["title","query","recommendation","cause"]),snippet:o(),dismissed:_(),createdAt:o()}),w$=Le("kind",[v$,x$]);d({query:o(),totalHits:m().int().nonnegative(),truncated:_(),hits:y(w$)});const O3=j(["create","expand","refresh","add-schema"]);O3.enum;function S$(e){switch(e){case"create":return"Create";case"expand":return"Expand";case"refresh":return"Refresh";case"add-schema":return"Add schema"}}const q3=j(["gsc","competitor-evidence","both"]);q3.enum;const P3=j(["high","medium","low"]);P3.enum;function k$(e){switch(e){case"high":return"High";case"medium":return"Medium";case"low":return"Low"}}const j$=j(["blog-post","comparison","listicle","how-to","guide","glossary"]);j$.enum;const M3=j(["proposed","briefed","payload-generated","draft-created","published","validated","dismissed"]);M3.enum;const V0=j(["ownable","ceded"]),Ree=V0.enum;function Dee(e){switch(e){case"ownable":return"Ownable";case"ceded":return"Ceded"}}const A$=d({url:o(),gscImpressions:m().nonnegative(),gscClicks:m().nonnegative(),gscAvgPosition:m().nonnegative().nullable(),organicSessions:m().nonnegative()}),C$=d({domain:o(),url:o(),title:o(),citationCount:m().int().nonnegative()}),N$=d({demand:m(),competitor:m(),absence:m(),gapSeverity:m()}),_$=d({actionId:o(),state:M3,lastUpdated:o()}),B3=d({targetRef:o(),query:o(),action:O3,ourBestPage:A$.nullable(),winningCompetitor:C$.nullable(),score:m(),scoreBreakdown:N$,drivers:y(o()),demandSource:q3,actionConfidence:P3,existingAction:_$.nullable(),winnabilityClass:V0,winnability:we(m().min(0).max(1)).nullable()});d({targets:y(B3),contextMetrics:d({totalAiReferralSessions:m().int().nonnegative(),latestRunId:o(),runTimestamp:o()})});const T$=d({targetRef:o(),addressedUrl:o().nullable(),note:o().nullable(),dismissedAt:o()});d({dismissals:y(T$)});d({targetRef:o().min(1),addressedUrl:o().url().optional(),note:o().max(500).optional()});d({targetRef:o(),promptVersion:o(),provider:o(),model:o(),responseText:o(),costMillicents:m().int().nonnegative(),generatedAt:o()});d({provider:o().optional(),model:o().optional(),forceRefresh:_().optional()});const E$=d({targetQuery:o().trim().min(1),winnabilityClass:V0,angle:o().trim().min(1),whyWinnable:o().trim().min(1),schemaHookup:o().trim().min(1),controllableSurfaceRationale:o().trim().min(1)});d({targetRef:o(),promptVersion:o(),provider:o(),model:o(),brief:E$,costMillicents:m().int().nonnegative(),generatedAt:o()});const R$=d({domain:o(),competitorType:Am,hits:m().int().nonnegative(),updatedAt:o()});d({classifications:y(R$)});const D$=d({uri:o(),title:o(),domain:o(),isOurDomain:_(),isCompetitor:_(),citationCount:m().int().nonnegative(),providers:y(kt)}),L3=d({query:o(),groundingSources:y(D$)});d({sources:y(L3),latestRunId:o()});const $3=d({query:o(),competitorDomains:y(o()),competitorCount:m().int().nonnegative(),missRate:we(m().min(0).max(1)),lastSeenInRunId:o()});d({gaps:y($3),latestRunId:o()});const V3=j(["ok","warn","fail","skipped"]);V3.enum;const U0=j(["global","project"]);U0.enum;const U3=j(["auth","config","providers","integrations","database","schedules","agent"]);U3.enum;const G3=j(["health","silent"]);G3.enum;const z$=o().regex(/^[1-9]\d{3}-(0[1-9]|1[0-2])$/,"Expected YYYY-MM"),I$=d({id:o(),category:U3,scope:U0,title:o(),status:V3,notificationPolicy:G3.optional().describe("Health checks page by default. Silent report advisories remain visible but never affect health alert state."),code:o().describe('Stable machine-readable code (e.g. "google.token.refresh-failed"). Use this for filtering and remediation logic.'),summary:o(),remediation:o().nullable().optional().describe('Operator-facing next step. Null when status is "ok" or no specific remediation applies.'),details:Qe(o(),jn()).optional().describe("Structured context — principal email, redirect URI, missing scopes, etc. Stable per check id."),durationMs:m().int().nonnegative().describe("How long the check took to execute.")});d({scope:U0,project:o().nullable().describe('Project name when scope is "project", null otherwise.'),reportMonths:y(z$).optional().describe("Calendar months evaluated by project report readiness checks."),generatedAt:o().describe("ISO-8601 timestamp when this doctor run started."),durationMs:m().int().nonnegative(),summary:d({total:m().int().nonnegative(),ok:m().int().nonnegative(),warn:m().int().nonnegative(),fail:m().int().nonnegative(),skipped:m().int().nonnegative()}),checks:y(I$)});function O$(e){return e.trim().toLowerCase()}const q$=d({provider:o(),citationState:$i,cited:_(),mentioned:_(),runId:o(),runCreatedAt:o()}),P$=d({queryId:o(),query:o(),providers:y(q$),citedCount:m().int().nonnegative(),mentionedCount:m().int().nonnegative(),totalProviders:m().int().nonnegative()}),M$=d({queryId:o(),query:o(),provider:o(),citingCompetitors:y(o()),runId:o(),runCreatedAt:o()}),B$=d({providersConfigured:m().int().nonnegative(),providersCiting:m().int().nonnegative(),providersMentioning:m().int().nonnegative(),totalQueries:m().int().nonnegative(),queriesCitedAndMentioned:m().int().nonnegative(),queriesCitedOnly:m().int().nonnegative(),queriesMentionedOnly:m().int().nonnegative(),queriesInvisible:m().int().nonnegative(),latestRunId:o().nullable(),latestRunAt:o().nullable()});d({summary:B$,byQuery:y(P$),competitorGaps:y(M$),status:j(["ready","no-data"]),reason:j(["no-runs-yet","no-queries"]).optional()});const L$=d({selection:tj,historyWindow:d({from:o().datetime(),to:o().datetime()}).optional(),populations:y(ej.pick({queryClass:!0,summary:!0,trend:!0}))}),Dn={title:"AI visibility",description:"Each answer is counted once for its assigned properties. Branded and non-brand queries are measured separately.",simpleDescription:"Each saved answer is counted once. Branded and non-brand queries are measured separately.",queryType:"Query type",queries:"Queries measured",answers:"Answers measured",mentioned:"Mentioned",cited:"Cited",history:"Measurement history",latestMeasurement:"Latest measurement",allLocations:"All measured locations",noLocation:"No provider location",location:"Location",previousOutsideWindow:"Previous measurement outside this period",date:"Date",comparison:"Comparison",notMeasured:"Not measured",incomplete:"Evidence incomplete",ambiguous:"Property identity unverified",noPopulation:"No measured answers",notApplicable:"Not applicable",comparable:"Comparable",baseline:"Baseline",changed:"Measurement changed",unknownHistory:"Comparison unavailable"};function zee(e){return{branded:"Branded","non-brand":"Non-brand",unknown:"Unclassified"}[e]}function Iee(e){return e.rate===null?Dn.notMeasured:sn(e.rate)}function Oee(e){if(e.numerator!==null&&e.denominator!==null)return`${e.numerator} of ${e.denominator} answers`;switch(e.reason){case"no-population":return Dn.noPopulation;case"not-applicable":return Dn.notApplicable;case"identity-ambiguous":return Dn.ambiguous;default:return Dn.incomplete}}const qee="No answer could be tied to one property";function Pee(e){return e.denominator===null||e.denominator===void 0||e.unattributed===void 0||e.unattributed<=0?null:`${e.unattributed} of ${e.denominator+e.unattributed} answers could not be tied to one property`}function Mee(e,n=!1){const i=e==="first"?Dn.baseline:e==="comparable"?Dn.comparable:e==="legacy-unknown"?Dn.unknownHistory:Dn.changed;return n?`${i} · ${Dn.previousOutsideWindow}`:i}function Bee(e){const n=e.selection.measurement.completedAt?.slice(0,10)??Dn.notMeasured;return`${Dn.latestMeasurement}: ${n}`}function Lee(e){const n=e.historyWindow;return n===void 0?Dn.history:`${Dn.history} (${n.from.slice(0,10)} – ${n.to.slice(0,10)})`}function $ee(e){const n=e.selection.location;return n.kind==="all"?Dn.allLocations:n.kind==="none"?Dn.noLocation:`${Dn.location}: ${n.value}`}const Vee=[7,14,30,90],Uee=30;Ze([R(7),R(14),R(30),R(90)]).describe("Report window in days (7, 14, 30, or 90). Defaults to 30 when omitted.");const $$=j(["prompt","request-param","browser-geo","ignored"]),V$=d({label:o(),city:o(),region:o(),country:o(),otherConfiguredLabels:y(o())}),U$=d({provider:o(),treatment:$$,description:o()}),G$=d({generatedAt:o(),project:d({id:o(),name:o(),displayName:o(),canonicalDomain:o(),country:o(),language:o()}),location:V$.nullable(),providerLocationHandling:y(U$),periodStart:o().nullable(),periodEnd:o().nullable(),periodDays:m().int().positive()}),K$=d({visibilityBasis:j(["legacy-project-queries","frozen-populations"]).optional(),citationRate:Oe().nullable(),citedQueryCount:m().nullable(),totalQueryCount:m().nullable(),mentionRate:Oe().nullable(),mentionedQueryCount:m().nullable(),trend:j(["up","down","flat","unknown"]),queryCount:m(),competitorCount:m(),providerCount:m(),gsc:d({clicks:m(),impressions:m(),ctr:we(),avgPosition:m(),periodStart:o(),periodEnd:o()}).nullable(),ga:d({sessions:m(),users:m(),periodStart:o(),periodEnd:o()}).nullable(),findings:y(d({title:o(),detail:o(),tone:j(["positive","caution","negative","neutral"])}))}),H$=d({citationState:j(["cited","not-cited","pending"]),answerMentioned:_().nullable(),model:o().nullable()}),Q$=d({queries:y(o()),providers:y(o()),matrix:y(y(H$.nullable())),providerRates:y(d({provider:o(),citedCount:m(),mentionedCount:m(),totalCount:m(),citationRate:Oe(),mentionRate:Oe()}))}),F$=d({domain:o(),citationCount:m(),totalCount:m(),pressureLabel:j(["High","Moderate","Low","None"]),citedQueries:y(o()),sharePct:Oe(),theirCitedPages:y(d({url:o(),citedFor:y(o())}))}),Z$=d({projectCitationCount:m(),competitors:y(F$)}),Y$=d({domain:o(),mentionCount:m(),totalCount:m(),pressureLabel:j(["High","Moderate","Low","None"]),mentionedQueries:y(o()),sharePct:Oe().nullable()}),bf=d({shareOfVoice:x3.optional(),projectMentionCount:m(),totalAnswerSnapshots:m(),competitors:y(Y$)}),X$=bf.extend({scope:j(["non-brand","pooled"]),nonBrand:bf,branded:bf}),J$=d({category:o(),label:o(),count:m(),sharePct:Oe()}),W$=d({categories:y(J$),topDomains:y(d({domain:o(),count:m(),isCompetitor:_()}))}),eV=d({query:o(),clicks:m(),impressions:m(),ctr:we(),avgPosition:m(),category:j(["brand","lead-gen","industry","other"])}),tV=d({periodStart:o(),periodEnd:o(),totalClicks:m(),totalImpressions:m(),ctr:we(),avgPosition:m(),topQueries:y(eV),categoryBreakdown:y(d({category:j(["brand","lead-gen","industry","other"]),clicks:m(),impressions:m(),sharePct:Oe()})),trend:y(d({date:o(),clicks:m(),impressions:m()})),trackedButNoGsc:y(o()),gscButNotTracked:y(o())}),nV=d({totalSessions:m(),totalUsers:m(),totalOrganicSessions:m(),periodStart:o(),periodEnd:o(),topLandingPages:y(d({page:o(),sessions:m(),users:m().optional(),organicSessions:m()})),channelBreakdown:y(d({channel:o(),sessions:m(),sharePct:Oe()}))}),aV=d({totalSessions:m(),organicSessions:m(),paidSessions:m(),channels:y(d({channelGroup:o(),sessions:m(),sharePct:Oe()})),topCampaigns:y(d({source:o(),medium:o(),sessions:m()}))}),iV=d({totalSessions:m(),paidSessions:m(),organicSessions:m(),totalUsers:m().optional(),paidUsers:m().optional(),organicUsers:m().optional(),bySource:y(d({source:o(),sessions:m(),users:m().optional(),paidSessions:m(),organicSessions:m(),sharePct:Oe()})),trend:y(d({date:o(),sessions:m()})),topLandingPages:y(d({page:o(),sessions:m(),users:m().optional()}))}),ho=d({current:m(),prior:m(),deltaPct:Oe().nullable()}),sV=d({windowStart:o(),windowEnd:o(),hasData:_(),verifiedCrawlerHits:ho,unverifiedCrawlerHits:ho,aiUserFetchHits:ho,referralArrivals:ho,referralRedirects:m().int().nonnegative(),referralArrivalsByClass:d({paid:ho,organic:ho,unclassified:ho}),referralArrivalsClassSummary:o(),byOperator:y(d({operator:o(),verifiedHits:m(),unverifiedHits:m(),userFetchHits:m(),referralArrivals:m(),deltaPct:Oe().nullable()})),topCrawledPaths:y(d({path:o(),verifiedHits:m(),unverifiedHits:m().default(0),distinctOperators:m()})),referralProducts:y(d({product:o(),arrivals:m(),distinctLandingPaths:m()})),dailyTrend:y(d({date:o(),verifiedCrawlerHits:m(),unverifiedCrawlerHits:m().default(0),userFetchHits:m(),referralArrivals:m()})),topReferralLandingPaths:y(d({path:o(),arrivals:m(),distinctProducts:m()}))}),oV=d({provider:j(["google","bing"]).nullable(),total:m(),indexed:m(),notIndexed:m(),deindexed:m(),unknown:m(),indexedPct:Oe()}),rV=d({runId:o(),date:o(),citationRate:Oe(),citedQueryCount:m(),totalQueryCount:m(),mentionRate:Oe(),mentionedQueryCount:m(),providerRates:y(d({provider:o(),citationRate:Oe(),mentionRate:Oe()}))}),K3=j(["regression","gain","opportunity"]),lV=K3.enum,ag=d({id:o(),type:K3,severity:j(["critical","high","medium","low"]),title:o(),query:o(),provider:o(),recommendation:o().nullable(),createdAt:o(),instanceCount:m()}),cV=d({horizon:j(["immediate","short-term","medium-term"]),title:o(),rationale:o()}),Cr=d({current:m(),prior:m(),deltaAbs:m(),deltaPct:Oe().nullable(),direction:j(["up","down","flat"]),window:m().optional()}),uV=d({provider:o(),current:Oe(),prior:Oe(),deltaAbs:Oe(),direction:j(["up","down","flat"])}),dV=d({enoughHistory:_(),headline:o(),citationRate:Cr.nullable(),mentionRate:Cr.nullable(),citedQueryCount:Cr.nullable(),mentionedQueryCount:Cr.nullable(),gscClicksDelta:Cr.nullable(),aiReferralsDelta:Cr.nullable(),comparisonWindowDays:m().int().positive(),providerMovements:y(uV),wins:y(ag),regressions:y(ag)}),mV=j(["agency","client"]),H3=j(["agency","client","both"]),pV=j(["immediate","short-term","medium-term"]),hV=j(["high","medium","low"]);j(["positive","caution","negative","neutral"]);const fV=j(["content","competitors","provider","search-demand","indexing","location","monitoring"]),G0=d({audience:H3,priority:m(),horizon:pV,category:fV,title:o(),action:o(),why:y(o()),evidence:y(o()),successMetric:o(),confidence:hV,targetRef:o().optional()}),gV=d({headline:o(),overview:o(),actionItems:y(G0),confidenceNotes:y(o())}),yV=d({title:o(),detail:o(),severity:j(["positive","caution","negative","neutral"]),evidence:y(o())}),bV=d({priorities:y(G0),diagnostics:y(yV)});function Gee(e){return e.horizon==="immediate"?"negative":e.confidence==="high"?"caution":e.confidence==="low"?"neutral":"caution"}function Kee(e){return e==="High"?"negative":e==="Moderate"?"caution":e==="Low"?"positive":"neutral"}function vV(e){switch(e){case"critical":return"negative";case"high":return"negative";case"medium":return"caution";case"low":return"neutral"}}function Hee(e){return e.type===lV.gain?"positive":vV(e.severity)}function Qee(e){switch(e){case Ad.competitor:return"negative";case Ad.directory:case Ad.forum:return"caution";default:return"neutral"}}function Fee(e){switch(e){case"critical":return"Critical";case"high":return"High";case"medium":return"Medium";case"low":return"Low"}}function xV(e){switch(e){case"immediate":return"Immediate";case"short-term":return"Short term";case"medium-term":return"Medium term"}}function Zee(e){switch(e){case"content":return"Content";case"competitors":return"Competitors";case"provider":return"Provider";case"search-demand":return"Search demand";case"indexing":return"Indexing";case"location":return"Location";case"monitoring":return"Monitoring"}}function wV(e){switch(e){case"high":return"High";case"medium":return"Medium";case"low":return"Low"}}d({visibility:L$.optional(),meta:G$,executiveSummary:K$,citationScorecard:Q$,competitorLandscape:Z$,mentionLandscape:X$,aiSourceOrigin:W$,gsc:tV.nullable(),ga:nV.nullable(),socialReferrals:aV.nullable(),aiReferrals:iV.nullable(),serverActivity:sV.nullable(),indexingHealth:oV.nullable(),citationsTrend:y(rV),whatsChanged:dV,insights:y(ag),recommendedNextSteps:y(cV),actionPlan:y(G0),clientSummary:gV,agencyDiagnostics:bV,contentOpportunities:y(B3),contentGaps:y($3),groundingSources:y(L3)});const SV=Ze([R(60),R(90)]),kV=j(["earliest","middle","prior","latest"]),Nr=d({clicks:m().int().nonnegative(),impressions:m().int().nonnegative()}),Q3=d({name:kV,startDate:o(),endDate:o()}),jV=Q3.extend({totals:Nr}),AV=Q3.extend({organicSessions:m().int().nonnegative()}),vf=d({startDate:o(),endDate:o(),observedDays:m().int().nonnegative()}),hd=d({verified:m().int().nonnegative(),claimedUnverified:m().int().nonnegative(),unknownAiLike:m().int().nonnegative()}),Mw=d({total:m().int().nonnegative(),paid:m().int().nonnegative(),organic:m().int().nonnegative(),unknown:m().int().nonnegative()});d({contractVersion:R("organic-evidence/v1"),periodDays:SV,asOfDate:o().nullable(),coverage:d({gsc:_(),ga4:_(),server:_(),visibility:_()}),sourceCoverage:d({gsc:vf.nullable(),ga4:vf.nullable(),server:vf.nullable(),visibility:d({completedAt:o(),ageDays:m().nonnegative()}).nullable()}),gsc:d({propertyTotals:Nr,namedBrand:Nr,namedNonBrand:Nr,suppressedOrUnreportedResidual:Nr,cohorts:y(jV)}).nullable(),ga4:d({organicSessions:m().int().nonnegative(),cohorts:y(AV)}).nullable(),gaAiReferrals:d({paidSessions:m().int().nonnegative(),organicSessions:m().int().nonnegative()}).nullable(),server:d({crawlerHits:hd,userFetchHits:hd,referralSessions:Mw}).nullable(),visibility:d({runId:o(),completedAt:o(),ageDays:m().nonnegative(),answerPairs:m().int().nonnegative(),mentionedPairs:m().int().nonnegative(),citedPairs:m().int().nonnegative()}).nullable(),measurement:_z,pages:y(d({path:o(),gsc:Nr,ga4OrganicSessions:m().int().nonnegative(),server:d({crawlerHits:hd,userFetchHits:hd,referralSessions:Mw})})),findings:y(d({tone:j(["positive","caution","neutral"]),title:o(),detail:o()})),limitations:y(d({code:o(),detail:o()}))});const CV=new Set(["a","an","and","for","from","in","near","of","on","or","the","to"]);function F3(e){return e.toLowerCase().match(/[a-z0-9]+/g)??[]}function Z3(e){return e.length>4&&e.endsWith("ies")?`${e.slice(0,-3)}y`:e.length>4&&e.endsWith("s")&&!e.endsWith("ss")?e.slice(0,-1):e}function Y3(e){const n=e.meta.location;return n?new Set([n.label,n.city,n.region,n.country].flatMap(F3).map(Z3).filter(Boolean)):new Set}function X3(e,n){const i=F3(e).map(Z3).filter(Boolean).filter(r=>!CV.has(r)).filter(r=>!n.has(r));return[...new Set(i)].sort().join(" ")}function NV(e){return e.title.match(/"([^"]+)"/)?.[1]??e.successMetric.match(/"([^"]+)"/)?.[1]??e.title}function J3(e,n){const i=Y3(e);if(n.length<=1||i.size===0)return[...n];const r=new Set,u=[];for(const h of n){if(h.category!=="content"){u.push(h);continue}const f=X3(NV(h),i);!f||r.has(f)||(r.add(f),u.push(h))}return u}function _V(e){const n=Y3(e),i=e.contentOpportunities;if(i.length<=1||n.size===0)return i;const r=new Set;return i.filter(u=>{const h=X3(u.query,n);return!h||r.has(h)?!1:(r.add(h),!0)})}const TV=j(["claude","codex"]);TV.enum;const EV=j(["claude","codex","all"]);EV.enum;const W3=d({content:m().int().nonnegative(),sitemap:m().int().nonnegative(),robots:m().int().nonnegative(),asset:m().int().nonnegative(),other:m().int().nonnegative()}),RV=j(["content","sitemap","robots","asset","other"]),K0=j(["cloud-run","wordpress","cloudflare","vercel","generic-log"]);K0.enum;const DV=j(["raw-request-events","aggregate-request-metrics","request-url","status-code","user-agent","remote-ip","referer","cursor-pull"]);DV.enum;const zV=j(["raw-request","aggregate-bucket"]),IV=zV.enum,OV=j(["observed","provider-aggregated","inferred"]),qV=OV.enum,PV=d({type:o().nullable(),labels:Qe(o(),o())}),MV=d({sourceType:K0,evidenceKind:R(IV["raw-request"]),confidence:R(qV.observed),eventId:o().min(1),observedAt:o().min(1),method:o().nullable(),requestUrl:o().nullable(),host:o().nullable(),path:o().min(1),queryString:o().nullable(),status:m().int().nullable(),userAgent:o().nullable(),remoteIp:o().nullable(),referer:o().nullable(),latencyMs:m().nullable(),requestSizeBytes:m().int().nullable(),responseSizeBytes:m().int().nullable(),providerResource:PV,providerLabels:Qe(o(),o())});d({events:y(MV),rawEntryCount:m().int().nonnegative(),skippedEntryCount:m().int().nonnegative(),nextPageToken:o().optional(),filter:o()});const eA=j(["connected","paused","error","archived"]),Yee=eA.enum,tA=j(["oauth","service-account"]);tA.enum;const BV=j(["verified","claimed_unverified","unknown_ai_like"]),Xee=BV.enum,LV=d({id:o().min(1),source:o().min(1),version:o().min(1)}),nA=d({manifestId:o().min(1),manifest:LV.nullable(),hits:m().int().nonnegative()});d({gcpProjectId:o().min(1),serviceName:o().nullable().optional(),location:o().nullable().optional(),authMode:tA});d({baseUrl:o().url(),username:o().min(1)});const H0=j(["production","preview"]);H0.enum;d({projectId:o().min(1),teamId:o().min(1),environment:H0});const aA=d({id:o(),projectId:o(),sourceType:K0,displayName:o(),status:eA,lastSyncedAt:o().nullable(),lastCursor:o().nullable(),lastError:o().nullable(),skippedThroughAt:o().nullable(),queueBacklogCount:m().int().nonnegative().nullable(),queueBacklogObservedAt:o().nullable(),archivedAt:o().nullable(),config:Qe(o(),jn()),createdAt:o(),updatedAt:o()});d({gcpProjectId:o().min(1),serviceName:o().min(1).optional(),location:o().min(1).optional(),displayName:o().min(1).optional(),keyJson:o().optional()});d({baseUrl:o().url(),username:o().min(1),applicationPassword:o().min(1),displayName:o().min(1).optional()});d({projectId:o().min(1),teamId:o().min(1),token:o().min(1),environment:H0.optional(),displayName:o().min(1).optional()});const $V=j(["direct-push","queue-pull"]),nl=$V.enum,Q0=o().regex(/^(?=.{1,63}$)[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,"Cloudflare Queue name must be 1-63 characters, use only letters, numbers, or dashes, and start and end with a letter or number"),iA=d({schemaVersion:R(1),workerVersion:o().min(1),expectedBotListVersion:o().min(1),zoneId:o().nullable()}),VV=iA.extend({deliveryMode:R(nl["direct-push"]),accountId:o().nullable()}),UV=iA.extend({deliveryMode:R(nl["queue-pull"]),accountId:o().min(1),queueId:o().min(1),queueName:Q0,retentionSeconds:m().int().min(60).max(1209600)});function sA(e){if(typeof e!="object"||e===null||Array.isArray(e))return e;const n=e;return"deliveryMode"in n?e:{...n,deliveryMode:"direct-push"}}zs(sA,Le("deliveryMode",[VV,UV]));const oA=d({displayName:o().min(1).optional(),zoneId:o().min(1).optional()}),GV=oA.extend({deliveryMode:R(nl["direct-push"]),accountId:o().min(1).optional()}),KV=oA.extend({deliveryMode:R(nl["queue-pull"]),accountId:o().min(1),queueId:o().min(1),queueName:Q0,retentionSeconds:m().int().min(60).max(1209600),apiToken:o().min(1)});zs(sA,Le("deliveryMode",[GV,KV]));const rA=d({sourceId:o().min(1),workerScript:o().min(1),wranglerToml:o().min(1),workerVersion:o().min(1),instructions:o().min(1)}),HV=rA.extend({deliveryMode:R(nl["direct-push"]),activationRequired:_().default(!1)}),QV=rA.extend({deliveryMode:R(nl["queue-pull"]),activationRequired:_().default(!1),accountId:o().min(1),queueId:o().min(1),queueName:Q0,retentionSeconds:m().int().min(60).max(1209600)});Le("deliveryMode",[HV,QV]);const FV=d({eventId:o().min(1),observedAt:o().datetime(),method:o().nullable(),host:o().nullable(),path:o().min(1),queryString:o().nullable(),status:m().int().nullable(),userAgent:o().nullable(),remoteIp:o().nullable(),referer:o().nullable(),cf:d({verifiedBot:_().nullable(),botScore:m().int().nullable(),country:o().nullable(),asn:m().int().nullable(),asOrganization:o().nullable()}).nullable()});d({schemaVersion:R(1),workerVersion:o().min(1),events:y(FV).min(1).max(100)});d({acceptedEvents:m().int(),droppedEvents:m().int(),workerVersionAck:o(),crawlerBucketRows:m().int(),aiUserFetchBucketRows:m().int(),aiReferralBucketRows:m().int(),sampleRows:m().int()});d({sourceId:o(),runId:o(),syncedAt:o(),pulledEvents:m().int().nonnegative(),selfTrafficExcluded:m().int().nonnegative(),crawlerHits:m().int().nonnegative(),aiUserFetchHits:m().int().nonnegative(),aiReferralHits:m().int().nonnegative(),unknownHits:m().int().nonnegative(),crawlerBucketRows:m().int().nonnegative(),aiUserFetchBucketRows:m().int().nonnegative(),aiReferralBucketRows:m().int().nonnegative(),sampleRows:m().int().nonnegative(),remainingBacklogCount:m().int().nonnegative().optional(),windowStart:o(),windowEnd:o()});d({days:m().int().positive().optional()});d({advanceToNow:R(!0)});d({sourceId:o(),runId:o(),status:ha,windowStart:o(),windowEnd:o(),daysRequested:m().int().positive(),daysApplied:m().int().positive()});const ZV=d({crawlerHits:m().int().nonnegative(),crawlerContentHits:m().int().nonnegative(),crawlerInfraHits:m().int().nonnegative(),crawlerSegments:W3,aiUserFetchHits:m().int().nonnegative(),aiReferralHits:m().int().nonnegative(),aiReferralLandedHits:m().int().nonnegative(),aiReferralRedirectedHits:m().int().nonnegative(),sampleCount:m().int().nonnegative()});d({sources:y(aA)});const YV=aA.extend({totals24h:ZV,latestRun:d({runId:o(),status:ha,startedAt:o().nullable(),finishedAt:o().nullable(),error:o().nullable()}).nullable()});d({sources:y(YV)});const XV=j(["crawler","ai-user-fetch","ai-referral"]),F0=XV.enum,lA=j(["hour","day"]);lA.enum;const JV=d({bucket:o(),crawlerHits:m().int().nonnegative(),aiUserFetchHits:m().int().nonnegative(),aiReferralHits:m().int().nonnegative(),aiReferralLandedHits:m().int().nonnegative(),crawlerContentHits:m().int().nonnegative(),measured:_()}),WV=d({kind:R(F0.crawler),sourceId:o(),tsHour:o(),botId:o(),operator:o(),verificationStatus:o(),verificationManifests:y(nA).optional(),verificationUnattributedHits:m().int().nonnegative().optional(),pathNormalized:o(),pathClass:RV,status:m().int(),hits:m().int().nonnegative()}),eU=d({kind:R(F0["ai-user-fetch"]),sourceId:o(),tsHour:o(),botId:o(),operator:o(),verificationStatus:o(),verificationManifests:y(nA).optional(),verificationUnattributedHits:m().int().nonnegative().optional(),pathNormalized:o(),status:m().int(),hits:m().int().nonnegative()}),tU=d({kind:R(F0["ai-referral"]),sourceId:o(),tsHour:o(),product:o(),operator:o(),sourceDomain:o(),evidenceType:o(),landingPathNormalized:o(),status:m().int(),hits:m().int().nonnegative(),paidHits:m().int().nonnegative(),organicHits:m().int().nonnegative(),unknownHits:m().int().nonnegative()}),nU=Le("kind",[WV,eU,tU]);d({windowStart:o(),windowEnd:o(),series:d({granularity:lA,points:y(JV),coverageStart:o().nullable(),trends:d({crawlerContentHits:ko.nullable(),aiUserFetchHits:ko.nullable(),aiReferralLandedHits:ko.nullable()})}),totals:d({crawlerHits:m().int().nonnegative(),crawlerContentHits:m().int().nonnegative(),crawlerInfraHits:m().int().nonnegative(),crawlerSegments:W3,aiUserFetchHits:m().int().nonnegative(),aiReferralHits:m().int().nonnegative(),aiReferralLandedHits:m().int().nonnegative(),aiReferralRedirectedHits:m().int().nonnegative(),aiReferralPaidHits:m().int().nonnegative(),aiReferralOrganicHits:m().int().nonnegative(),aiReferralUnknownHits:m().int().nonnegative()}),eventRows:d({total:m().int().nonnegative(),returned:m().int().nonnegative(),truncated:_()}),events:y(nU)});const Z0=j(["admin","viewer"]),aU=/^[a-z\d][\w.-]{0,63}$/i,iU=o().regex(aU,"A name may use letters, digits, dots, dashes and underscores, and must start with a letter or digit."),Bw=12,sU=o().min(Bw,`A password must be at least ${Bw} characters.`),cA=d({id:o(),name:o(),role:Z0,createdAt:o(),lastLoginAt:o().nullable()});d({users:y(cA)});d({name:iU,password:sU,role:Z0});d({name:o().min(1),password:o().min(1)});d({authRequired:_(),user:cA.pick({name:!0,role:!0}).nullable()});const uA=j(["queued","running","completed","partial","failed"]),Jee=uA.enum,dA=j(["queued","running","completed","failed"]),Wee=dA.enum,oU=20,rU=20,ig=50,mA=d({kind:j(["market","property"]),key:ge,expectedPlanRevision:m().int().positive().optional()}).strict(),lU=d({kind:j(["market","property"]),key:ge,label:o().trim().min(1),planRevision:m().int().positive()}).strict(),pA=o().min(1).max(4e3).refine(e=>e.trim().length>0,"Research queries cannot be blank.");function ete(e){const n=new Set;return e.filter(i=>{const r=O$(i);return!r||n.has(r)?!1:(n.add(r),!0)})}function cU(e,n){const i=e?e.kind==="market"?{market:e.label,submarket:e.label}:{property:e.label,propertyBrand:e.label}:{};return n?{...i,location:n.label}:i}function tte(e,n,i){const r=new Set(e.variables),u=[...e.pattern.matchAll(/\{([^{}]+)\}/g)].map(x=>x[1]),h=[...new Set(u.filter(x=>!r.has(x)))];if(h.length)throw Tx("The selected research template contains undeclared placeholders: "+h.join(", "));const f=cU(n,i),b=e.variables.filter(x=>f[x]===void 0);if(b.length)throw Tx("The selected research template requires unavailable bindings: "+b.join(", "));const v=Object.fromEntries(e.variables.map(x=>[x,f[x]]));return{bindings:v,output:oO(e.pattern,v)}}const hA=d({templateId:o().trim().min(1).max(256),templateVersion:o().trim().min(1).max(256),bindingLocation:dn.nullable().optional()}).strict();d({queries:y(pA).min(1).max(50),provider:o().trim().min(1).optional(),model:o().trim().min(1).max(200).optional(),location:dn.nullable().optional(),scope:mA.optional(),template:hA.optional(),idempotencyKey:o().trim().min(1).max(128).optional()}).superRefine((e,n)=>{e.model&&!e.provider&&n.addIssue({code:ye.custom,path:["provider"],message:"provider is required when model is supplied"})});const uU=mA.extend({expectedPlanRevision:m().int().positive()}).strict(),dU=d({queries:y(pA).min(1).max(ig),provider:o().trim().min(1),model:o().trim().min(1).max(200),location:dn.nullable(),scope:uU.optional(),template:hA.optional()}).strict();d({idempotencyKey:o().trim().min(1).max(128),runs:y(dU).min(1).max(rU)}).strict().superRefine((e,n)=>{e.runs.reduce((r,u)=>r+u.queries.length,0)>ig&&n.addIssue({code:ye.custom,path:["runs"],message:`A research batch may contain at most ${ig} concrete queries across all destinations`})});const mU=d({kind:j(["api-key","user"]),id:o(),name:o(),role:Z0.nullable(),limited:_().optional()}),fA=d({id:o(),projectId:o(),status:uA,provider:o(),requestedModel:o().nullable(),resolvedModel:o(),location:dn.nullable(),scope:lU.nullable().optional(),template:ij.nullable().optional(),totalQueries:m().int(),completedQueries:m().int(),failedQueries:m().int(),error:o().nullable(),initiatedBy:mU.nullable(),startedAt:o().nullable(),finishedAt:o().nullable(),createdAt:o()}),pU=d({id:o(),position:m().int(),query:o(),queryClass:Fr.nullable().optional(),status:dA,requestedModel:o().nullable(),resolvedModel:o(),servedModel:o().nullable(),answerText:o().nullable(),groundingSources:y(gm),citedDomains:y(o()),searchQueries:y(o()),namedCompetitors:y(o()).default([]),citedCompetitorDomains:y(o()).default([]),answerMentioned:_().nullable(),citationState:$i.nullable(),error:o().nullable(),startedAt:o().nullable(),finishedAt:o().nullable(),createdAt:o()}),hU=fA.extend({queries:y(pU)});d({runs:y(hU)});const fU=d({name:o(),displayName:o(),modelConfigurable:_(),defaultModel:o(),knownModels:y(d({id:o(),displayName:o()}))});d({runs:y(fA),nextCursor:o().nullable().optional(),providers:y(fU).optional(),access:d({canRun:_(),dailyRunLimit:m().int().positive().nullable()}).optional()});d({apiKey:o().min(1)});d({id:o(),name:o(),status:o(),currencyCode:o().nullable(),timezone:o().nullable(),url:o().nullable(),reviewStatus:o().nullable(),integrityReviewStatus:o().nullable(),integrityDecision:o().nullable()});d({q:o().trim().min(1).max(200),limit:m().int().min(1).max(100).default(20)});const gU=d({id:o(),type:o(),canonicalName:o(),countryCode:o(),name:o(),regionCode:o().nullable()});d({count:m().int().nonnegative(),query:o(),results:y(gU)});const yU=d({id:o(),clientType:o().optional(),name:o().optional(),pixelId:o().optional()});d({pixels:y(yU)});const bU=d({id:o(),name:o().optional()}),vU=d({id:o(),name:o().optional(),eventType:o().optional(),customEventName:o().nullable().optional(),attributionWindowDays:m().int().positive().optional(),adAccountId:o().optional(),sourceIds:y(o()).optional(),sources:y(bU).optional(),archived:_().optional(),version:m().int().nonnegative().optional()});d({eventSettings:y(vU)});d({connected:_(),adAccountId:o().nullable().optional(),displayName:o().nullable().optional(),currencyCode:o().nullable().optional(),timezone:o().nullable().optional(),status:o().nullable().optional(),reviewStatus:o().nullable().optional(),integrityReviewStatus:o().nullable().optional(),integrityDecision:o().nullable().optional(),lastSyncedAt:o().nullable().optional(),conversionTrackingConfigured:_().optional()});d({disconnected:_()});d({runId:o(),status:o()});const xU=["campaign_id","ad_group_id","ad_id","ad_account_id","oppref"],wU=/^[\w.-]+=[^&#\s]*$/,SU=/\{([^}]*)\}/g,Do=o().min(1).max(1e3).superRefine((e,n)=>{const i=u=>n.addIssue({code:"custom",message:u});if(e.startsWith("?")||e.startsWith("&")){i("Tracking template must not start with ? or &");return}const r=new Set;for(const u of e.split("&")){if(!wU.test(u)){i(`Tracking template pair '${u}' must be key=value without whitespace, # or &`);return}const h=u.slice(0,u.indexOf("="));if(r.has(h)){i(`Tracking template repeats the parameter '${h}'`);return}r.add(h)}for(const u of e.matchAll(SU)){const h=u[1];if(!xU.includes(h)){i(`Tracking template macro '{${h}}' is not supported`);return}}}),kU=d({type:o().nullable().optional(),title:o().nullable().optional(),body:o().nullable().optional(),targetUrl:o().nullable().optional(),fileId:o().nullable().optional()}),Vc=j(["impressions","clicks"]);Vc.enum;const Uc=j(["impression","click"]);Uc.enum;const jU=d({id:o(),adGroupId:o(),name:o(),status:o(),reviewStatus:o().nullable().optional(),creative:kU.nullable().optional(),landingPageQueryStringTemplate:o().nullable().optional(),upstreamUpdatedAt:m().int().nullable().optional(),syncedAt:o().optional()}),AU=d({id:o(),campaignId:o(),name:o(),description:o().nullable().optional(),status:o(),billingEventType:Ze([Uc,de()]).optional(),maxBidMicros:m().int().nullable().optional(),contextHints:y(o()).default([]),ads:y(jU).default([]),landingPageQueryStringTemplate:o().nullable().optional(),upstreamUpdatedAt:m().int().nullable().optional(),syncedAt:o().optional()}),CU=d({id:o(),name:o(),description:o().nullable().optional(),status:o(),startTime:m().int().nullable().optional(),endTime:m().int().nullable().optional(),biddingType:Ze([Vc,de()]).optional(),dailySpendLimitMicros:m().int().nullable().optional(),lifetimeSpendLimitMicros:m().int().nullable().optional(),conversionEventSettingIds:y(o()).default([]),locationIds:y(o()).optional(),adGroups:y(AU).default([]),landingPageQueryStringTemplate:o().nullable().optional(),upstreamUpdatedAt:m().int().nullable().optional(),syncedAt:o().optional()});d({campaigns:y(CU)});const gA=j(["campaign","ad_group"]);gA.enum;const NU=d({level:gA,entityId:o(),date:o(),impressions:m().int(),clicks:m().int(),spendMicros:m().int(),conversions:m().int(),ctr:we().nullable(),cpcMicros:m().int().nullable(),inProgress:_()});d({rows:y(NU),currencyCode:o().nullable().optional()});const yA=d({from:o().nullable(),to:o().nullable(),inProgressDate:o().nullable()}),bA=d({impressions:m().int(),clicks:m().int(),spendMicros:m().int(),conversions:m().int(),ctr:we().nullable(),cpcMicros:m().int().nullable()});d({connected:_(),displayName:o().nullable().optional(),currencyCode:o().nullable().optional(),lastSyncedAt:o().nullable().optional(),campaignCount:m().int(),adGroupCount:m().int(),adCount:m().int(),window:yA,totals:bA});const vA=j(["unavailable","partial","complete"]);vA.enum;const xA=j(["no_ads_connection","connection_not_synced","no_ads_sync","entity_rows_missing_sync_run_id","entity_rows_span_multiple_sync_runs","source_sync_missing","source_sync_not_ads_sync","source_sync_not_completed"]);xA.enum;const wA=j(["unavailable","reported"]);wA.enum;const _U={storedSnapshot:"stored_ads_snapshot"},SA=j(["unavailable","partial_snapshot","metrics_unavailable","observed_activity","no_observed_activity"]);SA.enum;const TU=d({id:o(),name:o(),status:o(),reviewStatus:o().nullable()}),EU=d({id:o(),name:o(),status:o(),billingEventType:Ze([Uc,de()]),maxBidMicros:m().int().nullable(),contextHints:y(o()),ads:y(TU)}),RU=d({id:o(),name:o(),status:o(),biddingType:Ze([Vc,de()]),dailySpendLimitMicros:m().int().nullable(),lifetimeSpendLimitMicros:m().int().nullable(),conversionEventSettingIds:y(o()),adGroups:y(EU)});d({snapshot:d({status:vA,issue:Ze([xA,de()]),lastSyncedAt:o().nullable(),campaignCount:m().int().nonnegative(),adGroupCount:m().int().nonnegative(),adCount:m().int().nonnegative(),sourceSync:d({runId:o(),status:ha}).nullable()}),historicalCampaignRollups:d({status:wA,window:yA,totals:bA.nullable()}),storedConfiguration:d({basis:R(_U.storedSnapshot),connection:d({status:o().nullable(),reviewStatus:o().nullable(),integrityReviewStatus:o().nullable(),integrityDecision:o().nullable(),conversionTrackingConfigured:_()}).nullable(),campaigns:y(RU)}),assessment:d({state:SA})});const di=o().min(8).max(128).regex(/^[\w.:-]+$/,"operationKey may contain letters, numbers, dot, underscore, colon, and hyphen"),Ut=o().min(1).max(200),zo=o().min(3).max(1e3).refine(e=>e.trim().length>0),Vr=m().int().min(946684800).max(4102444800),Ur=m().int().positive().max(Number.MAX_SAFE_INTEGER),Y0=o().regex(/^[a-f0-9]{64}$/),kA=y(Ut).max(100).refine(e=>new Set(e).size===e.length,"conversionEventSettingIds must be unique"),jA=o().url().refine(e=>new URL(e).protocol==="https:",{message:"URL must use https"}),AA=j(["image_upload","campaign_create","campaign_update","campaign_pause","campaign_archive","campaign_tree_activate","ad_group_create","ad_group_update","ad_group_pause","ad_group_archive","ad_create","ad_update","ad_pause","ad_archive"]);AA.enum;const CA=j(["pending","reconciling","succeeded","failed","unknown"]),Dr=CA.enum,NA=j(["known_entity","create_fingerprint","manual_only"]);NA.enum;const _A=j([Dr.pending,Dr.unknown,Dr.reconciling]);_A.enum;const TA=j(["active","paused","archived"]);TA.enum;const EA=j(["file","campaign","ad_group","ad"]);EA.enum;const RA=j(["campaign","ad_group","ad"]);RA.enum;const X0=d({id:Ut,expectedUpdatedAt:m().int().nonnegative()}).strict(),DU=X0,Qd=1e3;function zU(e){return 1+e.campaign.adGroups.reduce((n,i)=>n+1+i.ads.length,0)}const IU=X0.extend({ads:y(DU).min(1).max(Qd-1)}).strict(),OU=X0.extend({adGroups:y(IU).min(1).max(Qd-1)}).strict();function qU(e,n){return e<n?-1:e>n?1:0}function Lw(e,n,i){for(let r=1;r<e.length;r+=1)if(qU(e[r-1].id,e[r].id)>=0){i.addIssue({code:"custom",path:n,message:"Activation manifest entities must be uniquely sorted by id"});return}}const DA=d({campaign:OU}).strict().superRefine((e,n)=>{zU(e)>Qd&&n.addIssue({code:"custom",path:["campaign"],message:`Activation manifests may contain at most ${Qd} entities`}),Lw(e.campaign.adGroups,["campaign","adGroups"],n);const r=new Set;for(let u=0;u<e.campaign.adGroups.length;u+=1){const h=e.campaign.adGroups[u];Lw(h.ads,["campaign","adGroups",u,"ads"],n);for(let f=0;f<h.ads.length;f+=1){const b=h.ads[f];r.has(b.id)&&n.addIssue({code:"custom",path:["campaign","adGroups",u,"ads",f,"id"],message:"An ad may appear only once in an activation manifest"}),r.add(b.id)}}}),zA=Y0,PU=j(["approved","executing","consumed","revoked","expired","unknown"]),Mi=PU.enum,MU=j(["pending","executing","active","failed","rollback_executing","rolled_back","rollback_failed","unknown"]),Is=MU.enum,BU=d({name:zo.optional(),description:o().max(4e3).nullable().optional(),status:TA.optional(),startTime:Vr.nullable().optional(),endTime:Vr.nullable().optional(),lifetimeSpendLimitMicros:Ur.min(1e6).optional(),locationIds:y(Ut).max(100).optional(),biddingType:Vc.optional(),conversionEventSettingIds:kA.optional(),campaignId:Ut.optional(),contextHints:y(o().min(1).max(1e3)).max(100).optional(),maxBidMicros:Ur.max(1e8).optional(),billingEventType:Uc.optional(),adGroupId:Ut.optional(),creativeFingerprint:Y0.optional(),landingPageQueryStringTemplate:Do.nullable().optional()}).strict();d({operationKey:di,imageUrl:jA});d({operationKey:di,name:zo,description:o().max(4e3).optional(),startTime:Vr.optional(),endTime:Vr.optional(),lifetimeSpendLimitMicros:Ur.min(1e6),locationIds:y(Ut).min(1).max(100),biddingType:Vc.optional(),conversionEventSettingIds:kA.optional(),landingPageQueryStringTemplate:Do.optional()}).superRefine((e,n)=>{e.startTime!==void 0&&e.endTime!==void 0&&e.endTime<=e.startTime&&n.addIssue({code:"custom",path:["endTime"],message:"endTime must be after startTime"})});d({operationKey:di,campaignId:Ut,name:zo,description:o().max(4e3).optional(),contextHints:y(o().min(1).max(1e3)).min(1).max(100),maxBidMicros:Ur.max(1e8),billingEventType:Uc.optional(),landingPageQueryStringTemplate:Do.optional()});const IA=d({title:o().min(3).max(50),body:o().min(1).max(100),targetUrl:jA,fileId:Ut});d({operationKey:di,adGroupId:Ut,name:zo,creative:IA,landingPageQueryStringTemplate:Do.optional()});function J0(e){return Object.keys(e).some(n=>n!=="operationKey"&&n!=="expectedUpdatedAt")}d({operationKey:di,expectedUpdatedAt:m().int().nonnegative(),name:zo.optional(),description:o().max(4e3).nullable().optional(),startTime:Vr.nullable().optional(),endTime:Vr.nullable().optional(),lifetimeSpendLimitMicros:Ur.min(1e6).optional(),locationIds:y(Ut).min(1).max(100).optional(),landingPageQueryStringTemplate:Do.nullable().optional()}).refine(J0,{message:"At least one campaign field must be updated"});d({operationKey:di,expectedUpdatedAt:m().int().nonnegative(),name:zo.optional(),description:o().max(4e3).nullable().optional(),contextHints:y(o().min(1).max(1e3)).min(1).max(100).optional(),maxBidMicros:Ur.max(1e8).optional(),landingPageQueryStringTemplate:Do.nullable().optional()}).refine(J0,{message:"At least one ad group field must be updated"});d({operationKey:di,expectedUpdatedAt:m().int().nonnegative(),name:zo.optional(),creative:IA.optional(),landingPageQueryStringTemplate:Do.nullable().optional()}).refine(J0,{message:"At least one ad field must be updated"});d({operationKey:di});d({operationKey:di,expectedUpdatedAt:m().int().nonnegative()});const Tm=d({id:o(),adAccountId:o().nullable(),operationKey:o(),kind:AA,state:CA,entityType:Ze([EA,de()]),entityId:o().nullable(),upstreamUpdatedAt:m().int().nullable(),errorCode:o().nullable(),errorMessage:o().nullable(),reconcileStrategy:Ze([NA,de()]),reconcileParentId:Ut.nullable(),reconcileFingerprint:Y0.nullable(),reconcileFields:BU.nullable(),reconcileAttempts:m().int().nonnegative(),lastReconciledAt:o().nullable(),createdAt:o(),updatedAt:o()});d({operation:Tm,replayed:_()});const Ot=Yk({offset:!0}),al={id:Ut,projectId:Ut,adAccountId:Ut,manifestHash:zA,manifest:DA,executorApiKeyId:Ut,approverApiKeyId:Ut,expiresAt:Ot,approvedAt:Ot,createdAt:Ot,updatedAt:Ot,revocationRequestedAt:Ot.nullable()},LU=d({...al,state:R(Mi.approved),operationId:de(),executionStartedAt:de(),consumedAt:de(),revokedAt:de(),expiredAt:de()}).strict(),$U=d({...al,state:R(Mi.executing),operationId:Ut,executionStartedAt:Ot,consumedAt:de(),revokedAt:de(),expiredAt:de()}).strict(),VU=d({...al,state:R(Mi.consumed),operationId:Ut,executionStartedAt:Ot,consumedAt:Ot,revokedAt:de(),expiredAt:de()}).strict(),UU=d({...al,state:R(Mi.revoked),operationId:de(),executionStartedAt:de(),consumedAt:de(),revokedAt:Ot,expiredAt:de()}).strict(),GU=d({...al,state:R(Mi.expired),operationId:de(),executionStartedAt:de(),consumedAt:de(),revokedAt:de(),expiredAt:Ot}).strict(),KU=d({...al,state:R(Mi.unknown),operationId:Ut,executionStartedAt:Ot,consumedAt:de(),revokedAt:de(),expiredAt:de()}).strict(),OA=Le("state",[LU,$U,VU,UU,GU,KU]).superRefine((e,n)=>{e.executorApiKeyId===e.approverApiKeyId&&n.addIssue({code:"custom",path:["executorApiKeyId"],message:"The activation executor must use a different API key from the approver"}),e.revocationRequestedAt!==null&&e.state!==Mi.executing&&e.state!==Mi.unknown&&e.state!==Mi.consumed&&n.addIssue({code:"custom",path:["revocationRequestedAt"],message:"Only an executing, cancelled, or unresolved activation can carry a cancellation request"})}),Os={id:Ut,operationId:Ut,ordinal:m().int().nonnegative(),entityType:RA,entityId:Ut,expectedUpdatedAt:m().int().nonnegative(),createdAt:Ot,updatedAt:Ot},Gc={errorCode:de(),errorMessage:de()},W0={errorCode:o().min(1).max(100),errorMessage:o().min(1).max(500),remediation:o().min(1).max(500)},HU=d({...Os,...Gc,state:R(Is.pending),providerUpdatedAt:de(),remediation:de(),startedAt:de(),finishedAt:de()}).strict(),QU=d({...Os,...Gc,state:R(Is.executing),providerUpdatedAt:de(),remediation:de(),startedAt:Ot,finishedAt:de()}).strict(),FU=d({...Os,...Gc,state:R(Is.active),providerUpdatedAt:m().int().nonnegative(),remediation:de(),startedAt:Ot,finishedAt:Ot}).strict(),ZU=d({...Os,...W0,state:R(Is.failed),providerUpdatedAt:Ze([m().int().nonnegative(),de()]),startedAt:Ot,finishedAt:Ot}).strict(),YU=d({...Os,...Gc,state:R(Is.rollback_executing),providerUpdatedAt:m().int().nonnegative(),remediation:o().min(1).max(500),startedAt:Ot,finishedAt:de()}).strict(),XU=d({...Os,...Gc,state:R(Is.rolled_back),providerUpdatedAt:m().int().nonnegative(),remediation:o().min(1).max(500),startedAt:Ot,finishedAt:Ot}).strict(),JU=d({...Os,...W0,state:R(Is.rollback_failed),providerUpdatedAt:m().int().nonnegative(),startedAt:Ot,finishedAt:Ot}).strict(),WU=d({...Os,...W0,state:R(Is.unknown),providerUpdatedAt:Ze([m().int().nonnegative(),de()]),startedAt:Ot,finishedAt:Ot}).strict(),eG=Le("state",[HU,QU,FU,ZU,YU,XU,JU,WU]),sg={exact:"exact",refreshSemanticallyUnchanged:"refresh_semantically_unchanged"},tG=j([sg.exact,sg.refreshSemanticallyUnchanged]);d({manifest:DA,executorApiKeyId:Ut,expiresAt:Ot,versionPolicy:tG.default(sg.exact)}).strict();d({grant:OA}).strict();d({}).strict();d({operationKey:di,grantId:Ut,manifestHash:zA}).strict();d({grant:OA,operation:Tm,steps:y(eG)}).strict();const nG=[Dr.pending,Dr.unknown,Dr.reconciling];function aG(e){if(e===void 0||e==="")return nG;if(Array.isArray(e)){const n=[];for(const i of e)typeof i=="string"?n.push(...i.split(",")):n.push(i);return n}return typeof e=="string"?e.split(",").filter(Boolean):e}d({state:zs(aG,y(_A).min(1).max(3).refine(e=>new Set(e).size===e.length,"state values must be unique")),limit:Bi().int().min(1).max(200).default(100),cursor:o().min(1).max(1e3).optional()});d({operations:y(Tm),count:m().int().nonnegative(),nextCursor:o().nullable()});d({}).strict();d({operation:Tm,resolved:_()});d({campaignId:o().min(1).max(200).optional(),lookbackDays:Bi().int().min(1).max(30).default(7)});const qA=j(["campaign","ad_group","ad"]);qA.enum;const PA=j(["both","live-only","stored-only"]);PA.enum;const iG=R("live-provider-read"),sG=d({date:o().nullable(),startTime:m().nullable(),endTime:m().nullable(),impressions:m().nullable(),clicks:m().nullable(),spend:m().nullable(),conversions:m().nullable(),ctr:we().nullable(),cpc:m().nullable(),cpm:m().nullable()}),$w=d({impressions:m().int(),clicks:m().int(),spendMicros:m().int(),conversions:m().int()}),oG=d({date:o(),live:$w.nullable(),stored:$w.nullable(),drifted:_()}),rG=d({field:o(),live:o().nullable(),stored:o().nullable()}),lG=d({name:o().nullable(),status:o(),reviewStatus:o().nullable(),mode:o().nullable(),updatedAt:m().nullable()}),cG=d({name:o(),status:o(),reviewStatus:o().nullable(),upstreamUpdatedAt:m().nullable(),syncedAt:o()}),uG=d({entityType:qA,id:o(),parentId:o().nullable(),presence:PA,live:lG.nullable(),stored:cG.nullable(),fieldDeltas:y(rG),liveMetrics:y(sG).nullable(),metricDeltas:y(oG).nullable(),drifted:_()}),dG=d({surface:o(),entityId:o().nullable(),upstreamStatus:m().int().nullable()});d({basis:iG,fetchedAt:o(),adAccountId:o(),storedSnapshotSyncedAt:o().nullable(),metricsWindow:d({lookbackDays:m().int().positive()}),bounds:d({maxCampaigns:m().int().positive(),maxAdGroupsPerCampaign:m().int().positive(),maxAdsPerAdGroup:m().int().positive(),maxReaderCalls:m().int().positive(),readerCalls:m().int().nonnegative(),maxPagesPerReaderCall:m().int().positive(),maxUpstreamHttpRequests:m().int().positive(),truncated:_()}),entities:y(uG),drift:d({entitiesCompared:m().int().nonnegative(),driftedEntities:m().int().nonnegative(),statusDrifted:m().int().nonnegative(),metricsDrifted:m().int().nonnegative()}),errors:y(dG)});const mG=d({status:j(["available","unavailable","not-supported"])}),Vw="*",pG=j(["enabled","configured_disabled","CANONRY_TELEMETRY_DISABLED","DO_NOT_TRACK","CI","NO_CONFIG","CONFIG_UNAVAILABLE"]),hG=j(["server","local"]);d({enabled:_(),configuredEnabled:_(),reason:pG,anonymousId:o().regex(/^[0-9a-f]{8}\.\.\.$/i).optional(),target:hG.optional()}).strict();const ft=1,xf=j(["system","project","queries","competitors","run","finish"]),fG=j(["copy_agent_command","connect_server_traffic","connect_search_console","connect_analytics","connect_business_profile","set_schedule","add_notification","open_project","review_page_health"]),wf=j(["0","1","2-3","4-5","6-10","11+"]);function li(e){return!Number.isFinite(e)||e<=0?"0":e<2?"1":e<4?"2-3":e<6?"4-5":e<11?"6-10":"11+"}const Uw=j(["api_unavailable","database_unavailable","worker_unavailable","no_provider","no_queries","provider_save_failed","project_create_failed","query_save_failed","run_rejected","run_failed","run_cancelled","rate_limited","provider_auth","network","unknown"]),gG=j(["wizard","platform","site_health"]),fd=d({eventId:o().uuid(),flowVersion:R(ft),onboardingSessionId:o().uuid(),surface:gG.optional()});Le("event",[fd.extend({event:R("onboarding.started"),step:xf,resumed:_()}).strict(),fd.extend({event:R("onboarding.step_completed"),step:xf,method:j(["existing","inline","manual","generated","skipped","automatic"]),countBucket:wf.optional(),nextAction:fG.optional()}).strict(),fd.extend({event:R("onboarding.blocked"),step:xf,action:j(["continue","configure_provider","generate_queries","save","launch_run","retry_run"]),reasonCode:Uw}).strict(),fd.extend({event:R("run.requested"),origin:R("dashboard_setup"),result:j(["queued","rejected"]),kind:j(["answer_visibility","site_health"]).optional(),providerCountBucket:wf,queryCountBucket:wf,reasonCode:Uw.optional()}).strict()]);d({accepted:_()});j(["cli","mcp-stdio","mcp-http","aero","api","dashboard"]);const MA=4;function yG(e){return e.length<MA}const Kc=mV.enum.client,bG=H3.enum.both,vG=F2.enum.advanced;function Ia(e,n,i=`${n}s`){return e===1?n:i}const xG=j(["client-summary","executive-summary","share-of-voice","whats-changed","client-action-plan","agency-action-plan","agency-diagnostics","citation-scorecard","competitor-landscape","ai-source-origin","gsc","ga","social-referrals","ai-referrals","server-activity","indexing-health","citations-trend","insights","content-opportunities","content-gaps","recommended-next-steps","client-evidence-summary"]),zt=xG.enum;function nte(e,n){const i=e.visibility,r=i?.selection.mode===vG;return(n===Kc?[zt["client-summary"],r?null:zt["share-of-voice"],i?null:zt["whats-changed"],e.serverActivity?zt["server-activity"]:null,zt["client-action-plan"],zt["client-evidence-summary"]]:[i?zt["client-summary"]:zt["executive-summary"],r?null:zt["share-of-voice"],i?null:zt["whats-changed"],zt["agency-action-plan"],r?null:zt["agency-diagnostics"],r?null:zt["citation-scorecard"],r?null:zt["competitor-landscape"],zt["ai-source-origin"],zt.gsc,zt.ga,zt["social-referrals"],zt["ai-referrals"],zt["server-activity"],zt["indexing-health"],r?null:zt["citations-trend"],zt.insights,_V(e).length>0?zt["content-opportunities"]:null,e.contentGaps.length>0?zt["content-gaps"]:null,zt["recommended-next-steps"]]).filter(h=>h!==null)}const wG={gemini:"Gemini",openai:"ChatGPT",claude:"Claude",perplexity:"Perplexity",muse:"Muse",local:"Local model","cdp:chatgpt":"ChatGPT (browser)"};function SG(e){return wG[e]??e.charAt(0).toUpperCase()+e.slice(1)}function kG(e){switch(e){case"immediate":return"Do now";case"short-term":return"This month";case"medium-term":return"Next quarter"}}function jG(e){switch(e){case"high":return"Strong evidence";case"medium":return"Some evidence";case"low":return"Worth trying"}}function BA(e){if(!e)return"";const n=[e.city,e.region,e.country].filter(Boolean).join(", ");return n?`${e.label} (${n})`:e.label}const og={eyebrow:"AI Visibility Report",market:"Market",noMarket:"No market set",generated:"Generated"};function ate(e){return e?`${og.market}: ${BA(e)}`:og.noMarket}function ite(e){return`Last ${e} days`}function Gw(e,n=3){const i=e.slice(0,n),r=e.length-i.length;return`${i.join(", ")}${r>0?`, +${r} more`:""}`}function ste(e,n){return`${e.slice(0,n).join(", ")}${e.length>n?"…":""}`}function ote(e){return`+${e} more`}function rte(e){return`× ${e}`}function lte(e){return`${e} bar chart`}function cte(e){return`${e} line chart`}function LA(e){return e==="up"?"↑":e==="down"?"↓":"→"}function ute(e){return e==="up"?"positive":e==="down"?"negative":"neutral"}function Kw(e){return Dj(e,xt.percent).magnitude}function $A(e){return nP(e,xt.percent)}function dte(e,n){return n==="%"?sn(e.current,xt.percent):String(e.current)}function mte(e,n){return n==="%"?`${$A(e.deltaAbs)} vs ${sn(e.prior,xt.percent)}`:tP(e)}function pte(e){return`${$A(e.deltaAbs)} ${LA(e.direction)}`}function hte(e){return`vs prior ${e} days`}function fte(e){if(!e)return null;const n=e.window??1,i=sn(e.prior,xt.percent),r=n>=2?`vs prior ${n} checks (avg ${i})`:`since last check (was ${i})`,u=LA(e.direction);return e.direction==="up"?{text:`Up ${Kw(e.deltaAbs)} points ${r}`,tone:"positive",arrow:u}:e.direction==="down"?{text:`Down ${Kw(e.deltaAbs)} points ${r}`,tone:"negative",arrow:u}:{text:`Holding steady ${r}`,tone:"neutral",arrow:u}}const Em={"client-summary":{heroEyebrow:"Overview",heroEmpty:"No AI check has been run yet. Run a check to see how AI tools answer customer queries about your business.",tiles:{mentioned:"AI mentions your name",cited:"AI links to your website",providers:"AI tools tested"},noData:"No data yet",explainer:{lead:"Mentions and links are different.",mention:{article:"A",term:"mention",definition:"is when AI says your name out loud in its answer."},link:{article:"A",term:"link",definition:"is when AI lists your website as a source it used."},closing:"AI can do either, both, or neither — that's why we track both."},queriesHeading:"Customer queries we tested",providerBarsHeading:"How often each AI tool mentions you",providerBarsSubtitle:"Higher is better. Each bar shows the share of customer queries where the AI named you in the answer."},"whats-changed":{client:{eyebrow:"Since last check",title:"What's different since last check",empty:"No comparison yet — trends will appear after a few more checks.",tiles:{mentionRate:"AI mentions your name",citationRate:"AI links to your website",mentionedQueryCount:"Queries AI mentioned you in",gscClicks:"Visitors from Google",aiReferrals:"Visitors from AI tools"},gscCountLabel:"visits",aiReferralsCountLabel:"visits",movementsHeading:"How each AI tool changed",movementHeaders:["AI tool","Was","Now","Change"],winsHeading:"What got better",winsEmpty:"No new wins this period.",regressionsHeading:"What got worse",regressionsEmpty:"Nothing got worse this period.",insightHeaders:["What changed","Customer query","AI tool"]},agency:{eyebrow:"Section 2",title:"What's Changed",empty:"Trends will appear after a few more checks.",tiles:{citationRate:"Citation rate",mentionRate:"Mention rate",citedQueryCount:"Cited queries",gscClicks:"GSC clicks",aiReferrals:"AI referral sessions"},gscCountLabel:"clicks",aiReferralsCountLabel:"sessions",movementsHeading:"AI engine movements",movementHeaders:["Engine","Prior","Current","Change"],winsHeading:"Wins",winsEmpty:"No new gains in the latest check.",regressionsHeading:"Regressions",regressionsEmpty:"No new regressions in the latest check.",insightHeaders:["Severity","Title","Query","Provider"]},rateTileEmpty:"No prior data",trafficTileEmpty:"Not enough trend data"},"client-action-plan":{eyebrow:"Action plan",title:"What to do next",intro:"Approve these in order. They are sorted by what will move the needle fastest.",empty:"No recommendations yet — run an AI check to populate this.",rankTitle:"Priority — 1 will move the needle fastest",detailsSummary:"See the data behind this",whyLabel:"Why this matters",evidenceLabel:"What we saw",successLabel:"What success looks like:"},"agency-action-plan":{eyebrow:"Agency actions",title:"Agency Action Plan",intro:"The highest-leverage work, sorted by urgency and evidence strength.",empty:"No prioritized actions yet.",rankTitle:"Impact rank — 1 is the highest-leverage action",detailsSummary:"Evidence details",whyLabel:"Why",evidenceLabel:"Evidence",successLabel:"Win condition:"},"client-evidence-summary":{eyebrow:"What we based this on",title:"The signals behind this plan",intro:"The data behind the recommendations above. Switch to Agency for the full breakdowns.",empty:"No supporting evidence yet — this fills in after the first AI check.",sources:{heading:"Where AI gets its answers",subtitle:"The websites AI tools cited most often when answering customer queries about your industry.",competitorTag:"(competitor)"},indexing:{heading:"Pages Google can find on your site",subtitle:"Google indexing your site increases the chances of it appearing in AI search (especially Gemini)."},search:{heading:"What people search Google for",subtitleLead:"You appeared in",subtitleMiddle:"Google searches and got",subtitleTail:"this period."},opportunities:{heading:"Topics where you could improve",subtitle:"Customer queries where better content on your site would help AI cite you.",cededTag:"Ceded surface"}}};function gte(e,n){return e>0?`When customers asked AI ${e} ${Ia(e,"query","queries")} about your industry, AI mentioned you in ${n} of ${e===1?"them":"those queries"}.`:Em["client-summary"].heroEmpty}function yte(e,n){return n>0?`Says your name in ${e} of ${n} ${Ia(n,"query","queries")}`:Em["client-summary"].noData}function bte(e,n){return n>0?`Cites your site as a source in ${e} of ${n} ${Ia(n,"query","queries")}`:Em["client-summary"].noData}function vte(e,n){return e.length>0?e.map(i=>SG(i)).join(", "):`${Un(n)} ${Ia(n,"query","queries")} tested`}function xte(e){return`These are the ${e} ${Ia(e,"query we asked","queries we asked")} every AI tool. The numbers above measure how often you came up.`}function wte(e,n){const i=n===Kc?e.clientSummary.actionItems:e.agencyDiagnostics.priorities.length>0?e.agencyDiagnostics.priorities:e.actionPlan.filter(r=>r.audience===bG||r.audience===n);return J3(e,i)}function Ste(e,n){return e===Kc?kG(n):xV(n)}function kte(e,n){return e===Kc?jG(n):`${wV(n)} confidence`}function jte(e){return`${Un(e)}×`}function Ate(e,n){return`${Un(e)} of ${Un(n)} pages indexed`}function Cte(e){return`${Ia(e,"page is","pages are")} not indexed yet.`}function Nte(e){return Ia(e,"click")}function _te(e){return`${Un(e)} ${Ia(e,"search","searches")}`}function Tte(e){return e>=90?"positive":e>=70?"caution":"negative"}const e1={"executive-summary":{eyebrow:"Section 1",title:"Executive Summary",intro:"Citation = source list. Mention = answer text. They are independent signals.",heroKicker:"Latest AI visibility check",emptyTitle:"No AI citation data yet",emptySubtitle:"Run a check to populate the first citation and mention baseline.",noQueries:"no queries",proofTiles:{citationTrend:"Citation trend",mentionCoverage:"Mention coverage",prioritizedActions:"Prioritized actions"},prioritizedActionsCopy:"Sorted for agency follow-up.",tiles:{citationRate:"Citation rate",mentionRate:"Mention rate",queriesTracked:"Queries tracked",gscClicks:"GSC clicks",gaSessions:"GA sessions"},trendLabels:{up:"↑ Up",down:"↓ Down",flat:"→ Flat",unknown:"—"},marketScope:{heading:"Market Scope",currentLabel:"Current check",currentCopy:"All findings below are scoped to this run.",notIncludedLabel:"Not included",providerLabel:"Provider context",noOtherMarkets:"None",noProviders:"—",singleMarketCopy:"Single-market report; findings can be read as the current market view.",noMarketCopy:"No geographic hint was attached to this check; read findings as default-market or national results.",noProviderMetadataCopy:"No provider-level location metadata is available for this report.",warningTitle:"Location handling needs review",warningDetail:"used weak or indirect market handling. Treat provider-level differences cautiously."}},"agency-diagnostics":{eyebrow:"Agency diagnostics",title:"Technical Diagnostics",intro:"Fast-read operator flags behind the action plan.",empty:"No agency diagnostics available yet.",hiddenTitle:"Location caveat"},"recommended-next-steps":{eyebrow:"Section 16",title:"Recommended Next Steps",intro:"Action items bucketed by timing.",empty:"No outstanding actions."}};function Ete(e){const n=e1["executive-summary"],i=e.executiveSummary,r=i.trend,u=r==="up"?n.trendLabels.up:r==="down"?n.trendLabels.down:r==="flat"?n.trendLabels.flat:n.trendLabels.unknown,h=r==="up"?"positive":r==="down"?"negative":"neutral",f=(i.totalQueryCount??0)>0,b=i.totalQueryCount===1?"query":"queries",v=e.agencyDiagnostics.priorities.length>0?e.agencyDiagnostics.priorities:e.actionPlan,x=i.gsc?VA(e):"";return{trendLabel:u,trendTone:h,title:f?`${i.citedQueryCount} of ${i.totalQueryCount} tracked ${b} cite ${e.meta.project.displayName}`:n.emptyTitle,subtitle:f?`${sn(i.citationRate,xt.percent)} citation coverage and ${sn(i.mentionRate,xt.percent)} mention coverage across ${i.providerCount} ${Ia(i.providerCount,"provider")}.`:n.emptySubtitle,citedFragment:f?`${i.citedQueryCount}/${i.totalQueryCount} ${b} cited`:n.noQueries,mentionedFragment:f?`${i.mentionedQueryCount}/${i.totalQueryCount} ${b} mentioned`:n.noQueries,prioritizedActionCount:J3(e,v).length,providerCountLabel:`${i.providerCount} provider${i.providerCount===1?"":"s"}`,competitorCountLabel:`${i.competitorCount} competitor${i.competitorCount===1?"":"s"} tracked`,gscDelta:i.gsc?`${Un(i.gsc.impressions)} imp · ${sn(i.gsc.ctr)} CTR${x?` · ${x}`:""}`:null,gaDelta:i.ga?`${Un(i.ga.users)} users · ${jo(i.ga.periodStart)} → ${jo(i.ga.periodEnd)}`:null}}function Rte(e){const n=e1["executive-summary"].marketScope,i=e.meta.location,r=e.meta.providerLocationHandling;if(!i&&r.length===0)return null;const u=i?.otherConfiguredLabels??[],h=r.filter(f=>f.treatment==="ignored"||f.treatment==="browser-geo").map(f=>f.provider);return{currentValue:i?BA(i):og.noMarket,notIncludedValue:u.length>0?Gw(u,4):n.noOtherMarkets,notIncludedCopy:i?u.length>0?`${u.length} configured ${Ia(u.length,"market")} still ${u.length===1?"needs":"need"} a matching check before cross-market recommendations.`:n.singleMarketCopy:n.noMarketCopy,providerValue:r.length>0?Un(r.length):n.noProviders,providerCopy:r.length>0?h.length>0?`${h.length} ${Ia(h.length,"provider")} need a closer location check.`:`${r.length} ${Ia(r.length,"provider")} received the market context.`:n.noProviderMetadataCopy,weakProviders:h.length>0?Gw(h,4):null}}const AG={"citation-scorecard":{eyebrow:"Section 3",title:"Citation Scorecard",intro:"Per-engine citation and mention coverage from the latest check.",providerChartTitle:"Provider citation rate",empty:"Run a check to populate the citation matrix.",queryHeader:"Query",glyphs:{cited:"C",notCited:"c",mentioned:"M",notMentioned:"m",pending:"–",missingCell:"— —"},legend:{lead:"Legend:",citedMeaning:"= cited/not,",mentionedMeaning:"= mentioned/not,",pendingMeaning:"= no data."}},"competitor-landscape":{eyebrow:"Section 4",title:"Competitor Landscape",intro:"Who AI engines cite and mention instead of the client.",empty:"No competitor data yet. Add competitors and run a check.",noCompetitors:"No competitors configured.",citationsChartTitle:"Citations per domain",brandedChartTitle:"Mentions per domain · branded queries",headers:{domain:"Domain",pressure:"Pressure",citations:"Citations",citationShare:"Citation share",citedQueries:"Cited queries"},citationShareTooltip:"Citation share — % of cited-source slots that went to this competitor across tracked queries. Distinct from Mention Share."},"ai-source-origin":{eyebrow:"Section 5",title:"AI Citation Sources",intro:"External domains AI engines cited most in the latest check.",empty:"No source data yet. Run a check first.",topSourcesHeading:"Top sources",topSourceHeaders:["Domain","Citations","Tag"],trackedCompetitorTag:"Tracked competitor",externalTag:"External",categoriesHeading:"By source type"}};function Dte(e){return`${sn(e.citationRate,xt.percent)} (${e.citedCount}/${e.totalCount})`}const CG={"non-brand":"non-brand queries",pooled:"pooled queries · classification unavailable"};function NG(e){return CG[e]??"pooled queries · classification unavailable"}function zte(e){const n=NG(e.scope),i=e.branded;return{scopeLabel:n,mentionsHeader:`Mentions (${n})`,mentionsTooltip:e.scope==="non-brand"?`Mentions on ${n}. Branded queries are counted separately — the client is named on nearly all of them and a competitor cannot be, so pooling the two would rank the client on its own brand recall.`:`Mentions on ${n}. The project has no usable brand identity for a branded/non-brand split, so all tracked queries remain pooled and this is not a competitive category read.`,mentionsChartTitle:`Mentions per domain · ${n}`,mentionShareUnavailable:`Mention share unavailable for ${n}: no tracked brand was named, so the denominator is 0.`,brandedNote:`Branded queries contain the client's own name. The client is named on nearly all of them and a competitor structurally cannot be, so these are kept out of the competitive figure above. Read them as brand recall: ${i?.projectMentionCount??0} of ${i?.totalAnswerSnapshots??0} branded answers named the client.`}}function Ite(e){return`${e} cited URL${e>1?"s":""}`}function Ote(e){const n=e.find(r=>r.category===Ad.competitor);if(!n)return null;const i=e.reduce((r,u)=>r+u.count,0);return{share:sn(n.sharePct,xt.percent),detail:`of citations went to tracked competitors (${n.count} of ${i}).`}}function qte(e){return`(${sn(e,xt.percent)})`}const _G={gsc:{eyebrow:"Section 6",title:"GSC Performance",empty:"Connect Google Search Console to populate this section.",tiles:{clicks:"Total clicks",impressions:"Total impressions",ctr:"Avg CTR",position:"Avg position"},trendTitle:"Clicks over time",topQueriesHeading:"Top queries",topQueryHeaders:["Query","Clicks","Imp.","CTR","Pos.","Category"],intentHeading:"Search demand by intent",intentCountLabel:"clicks",untrackedDemand:{heading:"AEO queries without search demand",subtitle:"Review whether these still belong in the tracking set."},suggestedQueries:{heading:"Search queries you should track",subtitle:"High-impression candidates to add to AEO tracking."}},ga:{eyebrow:"Section 7",title:"GA4 Traffic",empty:"Connect Google Analytics 4 to populate this section.",tiles:{sessions:"Total sessions",users:"Total users",organicSessions:"Organic sessions"},topPagesHeading:"Top landing pages",topPageHeaders:["Page","Sessions","Organic"],channelsHeading:"Channel mix",channelsCountLabel:"sessions"},"social-referrals":{eyebrow:"Section 8",title:"Social Referrals",intro:"Social traffic split by channel and campaign.",empty:"No social referral data yet.",tiles:{sessions:"Total sessions",organic:"Organic social",paid:"Paid social"},channelsHeading:"Social channel mix",channelsCountLabel:"sessions",campaignsHeading:"Top campaigns",campaignHeaders:["Source","Medium","Sessions"]},"ai-referrals":{eyebrow:"Section 9",title:"AI Referral Traffic",intro:"Traffic arriving from AI answer engines.",empty:"No AI referral traffic detected yet.",tiles:{sessions:"Total sessions"},trendTitle:"AI referral sessions over time",sourcesHeading:"AI sessions by source",sourcesCountLabel:"sessions",topPagesHeading:"Top AI landing pages",topPageHeaders:["Page","Sessions"]}};function VA(e){const n=e.executiveSummary.gsc,i=e.gsc,r=n?.periodStart||i?.periodStart||i?.trend.at(0)?.date||"",u=n?.periodEnd||i?.periodEnd||i?.trend.at(-1)?.date||"";return Wq(r,u)}function Pte(e){const n=VA(e);return`Search demand signals to compare against AI visibility${n?` for ${n}`:""}.`}function Mte(e){return`Site traffic from ${jo(e.periodStart)} to ${jo(e.periodEnd)}.`}function Bte(e,n){return`${e} · ${sn(n,xt.percent)}`}const t1={"server-activity":{title:"AI Visibility — Server-Side",client:{eyebrow:"AI engine attention",introNoData:"Live telemetry from your server logs.",empty:"Your server-side traffic source is connected. Numbers will appear after the next sync.",tiles:{botRequests:"AI bot requests observed",userFetches:"AI user-fetch requests",referralSessions:"AI referral sessions"},userFetchFallback:"ChatGPT-User, Perplexity-User, MistralAI-User",operatorsHeading:"By AI tool",operatorsFootnote:"Bot requests are bulk crawl (GPTBot, PerplexityBot, …). User fetches are on-demand reads triggered by real users inside an AI surface (ChatGPT-User, Perplexity-User, …). Verified means the request came from an IP the operator publishes as its own; unverified means the user-agent matched but the IP is not in a published range. User-fetch totals count both, since many genuine user fetches come from outside any published range."},agency:{eyebrow:"Section 10",intro:"What AI engines actually do in your server logs — direct evidence, complementary to citations (which measure what they say).",emptyNotConnected:"Connect a server-side traffic source to surface what AI engines do directly in your server logs — distinct from GA4 click-throughs.",empty:"Source connected — collecting your first data. Numbers will appear after the next sync.",operatorsHeading:"Per AI operator",operatorsNote:"Verified means the request's source IP falls inside the operator's published range. Unverified bots claim the user-agent but the IP is not in a published range, so it could be the real bot or an imitator. User fetches are on-demand reads from an AI surface on behalf of a real user (ChatGPT-User, Perplexity-User, …), disjoint from bulk crawl and counted whether or not the IP can be verified.",noDelta:"—",crawledPathsHeading:"Top crawled paths",crawledPathHeaders:["Path","Hits","Verified","Distinct operators"],referralProductsHeading:"AI-referral sessions by product",referralProductsNote:"Where humans landed coming from each AI product (chatgpt.com, claude.ai, …).",referralProductHeaders:["Product","Sessions","Distinct landing paths"],referralLandingHeading:"Top AI-referral landing paths",referralLandingHeaders:["Path","Sessions","Distinct products"]},countNouns:{requests:"requests",hits:"hits",sessions:"sessions"}},"indexing-health":{eyebrow:"Section 11",title:"Indexing Health",empty:"Connect Google Search Console or Bing Webmaster Tools and run a sitemap inspection.",tiles:{indexed:"Indexed",total:"Total inspected",share:"Indexed share"},coverageHeading:"Coverage breakdown",coverageLabel:"Coverage stacked bar",segments:{indexed:"Indexed",notIndexed:"Not indexed",deindexed:"Deindexed",unknown:"Unknown"}},"citations-trend":{eyebrow:"Section 12",title:"Citations Over Time",intro:"Citation coverage across recent checks.",empty:"Run multiple checks to see a trend.",chartTitle:"Overall citation rate",breakdownHeading:"Check-by-check breakdown",breakdownHeaders:["Check","Cited queries","Per-engine rates"]}};function Lte(e,n,i){const r=t1["server-activity"],u=e===Kc;return{id:zt["server-activity"],eyebrow:u?r.client.eyebrow:r.agency.eyebrow,title:r.title,intro:u?n?`What AI engines actually do in your server logs over the last ${i} days — the other half of citations.`:r.client.introNoData:r.agency.intro}}function Rm(e){return`${e}d`}function $te(e){const n=Rm(e);return["AI tool",`Bot requests (${n})`,`User fetches (${n})`,"Referral sessions"]}function Vte(e){const n=Rm(e);return{verified:`Verified crawler hits (${n})`,unverified:`Unverified crawler hits (${n})`,userFetches:`AI user-fetch hits (${n})`,referralSessions:`AI-referral sessions (${n})`}}function Ute(e){return["Operator","Verified hits","Unverified","User fetches","Referral sessions",`${Rm(e)} delta`]}function Gte(e){return`Verified crawler hits over time (last ${e} days)`}function Kte(e){return`Pages AI bots fetched most often (verified only, last ${Rm(e)}).`}function Hte(e){return e===null?t1["server-activity"].agency.noDelta:v0(e,xt.percent)}function Qte(e){return e.verifiedHits+e.unverifiedHits}function Fte(e,n){return`${Un(e)} verified · ${Un(n)} unverified`}function Zte(e){return e>0?`${Un(e)} blocked by redirects`:""}function Yte(e){return`Pages absent from ${e==="google"?"Google":"Bing"} are harder for AI engines to retrieve.`}function Xte(e,n){return`${e}: ${n}`}function Jte(e){return`Building baseline (${e} of ${MA} checks completed). Trend will appear once more checks are recorded.`}function Wte(e){return e.map(n=>`${n.provider}: ${sn(n.citationRate,xt.percent)}`).join(" · ")}const TG={insights:{eyebrow:"Section 13",title:"Insights & Alerts",intro:"Regressions, gains, and recurring alerts ordered by severity.",empty:"No insights yet — run a check to generate alerts.",headers:["Severity","Title","Query","Provider","Recommendation"],noRecommendation:"—"},"content-opportunities":{eyebrow:"Section 14",title:"Content Opportunities",intro:"Queries where content work has the clearest path to more AI citations. Opportunity score is 0–100, higher = stronger. Winnability flags whether the cited surface is ownable or ceded to aggregators/editorial.",headers:["Query","Action","Winnability","Score","Why","Our page","Winning competitor","Confidence"],scoreSuffix:"/100",scoreCardTooltip:"Opportunity score (0–100, higher = stronger)",scoreHeaderTooltip:"Opportunity score (0–100)",noDriverSignal:"No driver signal yet",noPage:"No page yet",noWinningCompetitor:"—"},"content-gaps":{eyebrow:"Section 15",title:"Content Gaps",intro:"Tracked queries where competitors are cited and the client is missing.",headers:["Query","Competitors cited","Domains","Miss rate"]}};function ene(e){return`${S$(e.action)} · ${k$(e.actionConfidence)} confidence`}function tne(e){return sn(e)}const nne={...Em,...e1,...AG,..._G,...t1,...TG},UA=j(["trace","debug","info","warn","error","fatal"]),GA=d({runId:o().min(1).max(256).optional(),projectId:o().min(1).max(256).optional(),requestId:o().min(1).max(256).optional(),actor:o().min(1).max(512).optional(),credentialId:o().min(1).max(512).optional(),userAgent:o().min(1).max(512).optional(),actorSession:o().min(1).max(512).optional(),method:o().min(1).max(16).optional(),route:o().min(1).max(256).optional(),operationId:o().min(1).max(256).optional(),jobId:o().min(1).max(256).optional(),taskId:o().min(1).max(256).optional(),traceId:o().min(1).max(256).optional(),provider:o().min(1).max(256).optional(),errorCode:o().min(1).max(128).optional(),attempt:m().finite().optional(),count:m().finite().optional(),total:m().finite().optional(),progress:m().finite().optional(),httpStatus:m().finite().optional(),statusCode:m().finite().optional(),durationMs:m().finite().optional(),bytes:m().finite().optional(),retryAfterMs:m().finite().optional(),retriable:_().optional(),retrying:_().optional(),cancelled:_().optional(),success:_().optional()}).strict(),KA=d({cursor:o().min(1).max(512),ts:o().datetime(),level:UA,module:o().min(1).max(256),action:o().min(1).max(256),message:o().max(4096).optional(),runId:o().min(1).max(256).optional(),projectId:o().min(1).max(256).optional(),context:GA}).strict();d({level:UA.optional(),module:o().trim().min(1).max(256).optional(),runId:o().trim().min(1).max(256).optional(),projectId:o().trim().min(1).max(256).optional(),actor:o().trim().min(1).max(512).optional(),requestId:o().trim().min(1).max(256).optional(),since:o().datetime().optional(),until:o().datetime().optional(),limit:Bi().int().min(1).max(200).default(100),cursor:o().trim().min(1).max(512).optional()}).strict().superRefine((e,n)=>{e.since&&e.until&&Date.parse(e.since)>Date.parse(e.until)&&n.addIssue({code:ye.custom,path:["until"],message:'"until" must be on or after "since".'})});const HA=d({maxEntries:m().int().positive(),maxAgeSeconds:m().int().positive()}).strict(),EG=d({entries:y(KA),nextCursor:o().min(1).max(512).nullable(),truncated:m().int().nonnegative(),dropped:m().int().nonnegative(),retention:j(["process","durable"]),retentionPolicy:HA.optional(),captureErrors:m().int().nonnegative().optional(),observedAt:o().datetime()}).strict(),RG=d(GA.shape),DG=d({...KA.shape,context:RG});d({...EG.shape,entries:y(DG),retentionPolicy:d(HA.shape).optional()});function Sf(e){return e!==""&&/^[\w./:@%+=,-]+$/.test(e)?e:`'${e.replace(/'/g,"'\\''")}'`}d({startDate:ea,endDate:ea,sourceId:o().trim().min(1).optional(),burstThreshold:m().int().min(1).max(1e6).optional(),ratioThreshold:m().min(1).max(1e3).optional(),limit:m().int().min(1).max(500).optional()}).strict();const fo=d({total:m().int().nonnegative(),paid:m().int().nonnegative(),organic:m().int().nonnegative(),unknown:m().int().nonnegative()});d({scope:d({project:o(),sourceId:o().nullable(),attribution:R("project-source-only"),unavailableDimensions:y(j(["property","target","market"]))}),window:d({startDate:ea,endDate:ea,timeZone:R("UTC")}),rule:d({version:R("hourly-normalized-path-v1"),burstThreshold:m().int().positive(),ratioThreshold:m().positive(),calibration:j(["uncalibrated-default","request-override"]),grouping:y(o()),confirmsAutomation:R(!1)}),totals:d({raw:fo,redirects:fo,subresources:fo,countable:fo,suspected:fo,adjustedEstimate:fo}),bursts:y(d({sourceId:o(),product:o(),landingPathNormalized:o(),tsHour:o(),counts:fo})),evidence:d({total:m().int().nonnegative(),returned:m().int().nonnegative(),truncated:_()}),comparison:d({status:R("unavailable"),serverCountable:m().int().nonnegative(),serverObservation:j(["missing","observed-zero","observed-positive"]),gaSessions:m().int().nonnegative().nullable(),gaObservation:j(["missing","observed-zero","observed-positive"]),observedRatio:m().nonnegative().nullable(),observedRatioAboveThreshold:_().nullable(),ratio:de(),reasons:y(o()),gaScope:R("project")}),caveats:y(o())});const zG=new Set(["optional","nullable","default","prefault","readonly","catch","nonoptional"]),Hw=64;function Nd(e){return e._zod.def}function go(e,n){return e.clone({...Nd(e),...n})}function Qw(e){if(e.length!==0){if(e.every(n=>typeof n=="string"))return o();if(e.every(n=>typeof n=="number"))return m();if(e.every(n=>typeof n=="boolean"))return _()}}function QA(e,n,i,r){if(r>Hw)throw new Error(`tolerantReadSchema: schema nesting exceeds ${Hw} levels`);const u=i.get(e);if(u)return u;const h=v=>QA(v,n,i,r+1),f=Nd(e);let b=e;if(f.type==="object"){const v=Object.fromEntries(Object.entries(e.shape).map(([k,T])=>[k,h(T)])),x=f.catchall,S=n.get(e)??(x&&Nd(x).type!=="never"?h(x):void 0);b=S?d(v).catchall(S):d(v)}else if(zG.has(f.type)){const v=f.innerType,x=h(v);b=x===v?e:go(e,{innerType:x})}else if(f.type==="array"){const v=f.element,x=h(v);b=x===v?e:go(e,{element:x})}else if(f.type==="pipe"){const v=f.in,x=f.out,S=h(v),k=h(x);b=S===v&&k===x?e:go(e,{in:S,out:k})}else if(f.type==="union"){const v=f.options,x=v.map(h);b=x.some((k,T)=>k!==v[T])?f.discriminator?Ze(x):go(e,{options:x}):e}else if(f.type==="record"){const v=f.keyType,x=f.valueType,S=Nd(v).type==="enum"?o():v,k=h(x);b=S===v&&k===x?e:go(e,{keyType:S,valueType:k})}else if(f.type==="intersection"){const v=f.left,x=f.right,S=h(v),k=h(x);b=S===v&&k===x?e:go(e,{left:S,right:k})}else if(f.type==="tuple"){const v=f.items,x=f.rest,S=v.map(h),k=x&&h(x);b=k!==x||S.some((N,I)=>N!==v[I])?go(e,{items:S,rest:k}):e}else if(f.type==="lazy"){const v=f.getter;b=lz(()=>h(v()))}else f.type==="enum"?b=Qw(Object.values(f.entries))??e:f.type==="literal"&&(b=Qw(f.values)??e);return i.set(e,b),b}function Io(e,n={}){const i=new Map(n.openKeys??[]);return QA(e,i,new Map,0)}const Oo={openKeys:[[L0,m().int().nonnegative()]]};Io(s$,Oo);Io(ng,Oo);Io(p$,Oo);Io(h$,Oo);Io(o$,Oo);Io(I3,Oo);Io(u$,Oo);class Sn extends Error{code;statusCode;details;constructor(n,i,r,u){super(n),this.name="ApiError",this.code=r??"UNKNOWN",this.statusCode=i,this.details=u}}function ane(e){if(e instanceof Sn)return e.details;if(typeof e!="object"||e===null)return;const n=e.error,i=typeof n=="object"&&n!==null?n.details:e.details;return typeof i=="object"&&i!==null&&!Array.isArray(i)?i:void 0}function zr(){if(typeof window>"u")return!1;const e=window.__CANONRY_CONFIG__?.demo;return e?.enabled===!0&&e.readOnly===!0&&e.sampleData===!0}function IG(){if(typeof window>"u")return"legacy";const e=window.__CANONRY_CONFIG__?.dashboard?.onboardingMode??window.__CANONRY_CONFIG__?.onboardingMode;return e==="platform"||e==="auto"||e==="legacy"?e:"auto"}function OG(){if(typeof window>"u")return;const e=window.__CANONRY_CONFIG__?.embed?.renderToken;return typeof e=="string"&&e.length>0?e:void 0}function n1(e){const n=OG();if(!n)return e;let i;const r=typeof window<"u"&&window.location?window.location.href:"http://localhost/";try{i=new URL(e,r)}catch{return e}const u=new URL(r).origin;if(i.origin!==u)return e;const f=`${Dm().replace(/\/$/,"")}/api/v1`;return i.pathname!==f&&!i.pathname.startsWith(`${f}/`)?e:(i.searchParams.set("token",n),/^[a-z][a-z\d+.-]*:/i.test(e)?i.toString():`${i.pathname}${i.search}${i.hash}`)}function qG(e,n){const i={method:e.method,headers:e.headers,cache:e.cache,credentials:e.credentials,integrity:e.integrity,keepalive:e.keepalive,mode:e.mode,redirect:e.redirect,referrer:e.referrer,referrerPolicy:e.referrerPolicy,signal:e.signal};return e.body&&(i.body=e.body,i.duplex="half"),new Request(n,i)}function FA(){if(typeof window>"u")return null;const e=window.__CANONRY_CONFIG__?.embed;return e?.enabled?e:null}function PG(){return typeof window>"u"?!0:window.__CANONRY_CONFIG__?.dashboard?.showResourceLinks!==!1}function MG(){return typeof window>"u"?!0:window.__CANONRY_CONFIG__?.dashboard?.showAgentBar!==!1}function BG(){return typeof window>"u"?!1:window.__CANONRY_CONFIG__?.agent?.allowViewers===!0}function a1(){return zr()}function LG(){return typeof window>"u"?!0:window.__CANONRY_CONFIG__?.dashboard?.showUpdateNotification!==!1}function vo(){return $G(Re["answer-visibility"])}function $G(e){if(typeof window>"u")return!1;const n=window.__CANONRY_CONFIG__?.dashboard;return n?.managedRunKinds!==void 0?n.managedRunKinds.includes(e):e===Re["answer-visibility"]&&n?.managedSweeps===!0}function VG(){if(typeof window>"u")return null;const e=window.__CANONRY_CONFIG__?.research;if(e?.allowViewers!==!0)return null;const n=e.viewerDailyRunLimit;return{allowViewers:!0,viewerDailyRunLimit:Number.isInteger(n)&&(n??0)>0?n:oU}}function Fw(){return VG()?"Analyst":"View only"}function ZA(){return FA()!==null}function UG(){return typeof window<"u"&&window.__CANONRY_CONFIG__?.basePath?window.__CANONRY_CONFIG__.basePath.replace(/\/$/,"")+"/api/v1":"/api/v1"}const i1=UG();function GG(){const e=typeof window<"u"&&window.location?window.location.origin:"";return typeof window<"u"&&window.__CANONRY_CONFIG__?.basePath?e+window.__CANONRY_CONFIG__.basePath.replace(/\/$/,""):e}function Dm(){return typeof window<"u"&&window.__CANONRY_CONFIG__?.basePath?window.__CANONRY_CONFIG__.basePath.replace(/\/$/,""):""}function KG(e){const n=e.trim().toLowerCase().replace(/^\[|\]$/g,"");return n==="localhost"||n==="::1"?!0:/^127\.\d{1,3}\.\d{1,3}\.\d{1,3}$/.test(n)}function HG(e,n){if(e.protocol!=="http:"&&e.protocol!=="https:"||!KG(e.hostname))return;const i=e.port?`:${e.port}`:"",r=n?n.replace(/\/$/,""):"";return`${e.protocol}//localhost${i}${r}`}function ine(e){return`${e.replace(/\/$/,"")}/api/v1/google/callback`}function sne(e){return`${e.replace(/\/$/,"")}/api/v1/google-marketing/callback`}function QG(){if(!(typeof window>"u"))return HG(window.location,Dm())}function FG(e){return`${Dm()}${e}`}function ZG(e,n){if(n===404)return"Health endpoint returned 404. Check basePath or reverse-proxy configuration and make sure the dashboard reaches /health instead of an API-prefixed route."}function YG(){return""}function XG(){return!!YG()}let YA=null;function Zw(e){YA=e}function s1(){YA?.()}const W=k8({baseUrl:GG()});W.interceptors.response.use((e,n)=>(e.status===401&&!n.url.includes("/api/v1/session")&&s1(),e));W.interceptors.request.use(e=>{const n=n1(e.url);return n===e.url?e:qG(e,n)});async function he(e){const n=await e();if(n.error!==void 0&&n.error!==null){const i=n.response.status;let r=`API ${i}: ${n.response.statusText}`,u,h;if(typeof n.error=="object"&&n.error!==null){const f=n.error.error;if(typeof f=="string")r=f;else if(f&&typeof f=="object"){const b=f;b.message&&(r=b.message),b.code&&(u=b.code),b.details&&(h=b.details)}else{const b=n.error;b.message&&(r=b.message),b.code&&(u=b.code),b.details&&(h=b.details)}}else typeof n.error=="string"&&(r=n.error);throw new Sn(r,i,u,h)}if(n.response.status!==204)return n.data}async function qs(e,n){const i=n?.body!=null,r=await fetch(n1(`${i1}${e}`),{...n,credentials:n?.credentials??"same-origin",headers:{...i?{"Content-Type":"application/json"}:{},...n?.headers}});if(!r.ok){const u=await r.text();let h=`API ${r.status}: ${r.statusText}`,f,b;if(u)try{const v=JSON.parse(u);typeof v.error=="string"?h=v.error:v.error?.message?(h=v.error.message,f=v.error.code,b=v.error.details):v.message&&(h=v.message)}catch{h=u}throw r.status===401&&!e.startsWith("/session")&&!e.startsWith("/auth/")&&s1(),new Sn(h,r.status,f,b)}if(r.status!==204)return r.json()}function JG(e){return he(()=>hk({client:W,path:{name:e}}))}function one(e){return he(()=>yk({client:W,path:{name:e}}))}function rg(e){return he(()=>bk({client:W,path:{id:e}}))}function XA(e){return he(()=>gk({client:W,path:{name:e}}))}function WG(e,n,i){return he(()=>W6({client:W,path:{name:e},query:{location:n,limit:i}}))}function JA(e,n){return he(()=>IT({client:W,path:{name:e},query:{location:n?.location,since:n?.since}}))}function WA(e,n){return he(()=>d6({client:W,path:{name:e},body:n}))}function eK(e){return he(()=>c6({client:W,body:e}))}function tK(e,n){return he(()=>$6({client:W,path:{name:e},body:{queries:n}}))}function nK(e,n){return he(()=>L6({client:W,path:{name:e},body:{queries:n}}))}function rne(e,n){return he(()=>B6({client:W,path:{name:e},body:{queries:n}}))}function aK(e,n){return he(()=>zT({client:W,path:{name:e},body:n}))}function iK(e,n){return he(()=>G6({client:W,path:{name:e},body:{competitors:n}}))}function lne(e,n){return he(()=>U6({client:W,path:{name:e},body:{competitors:n}}))}function cne(e,n){return he(()=>K6({client:W,path:{name:e,id:n}}))}async function une(e,n){const i=await JG(e);return WA(e,{displayName:n.displayName??i.displayName??i.name,canonicalDomain:n.canonicalDomain??i.canonicalDomain,ownedDomains:n.ownedDomains??i.ownedDomains,aliases:n.aliases??i.aliases,country:n.country??i.country,language:n.language??i.language,tags:i.tags,labels:i.labels,providers:n.providers??i.providers,providerModels:n.providerModels??i.providerModels??{},locations:n.locations??i.locations,defaultLocation:n.defaultLocation!==void 0?n.defaultLocation:i.defaultLocation,autoExtractBacklinks:i.autoExtractBacklinks})}function sK(e,n){const i={};return n?.location&&(i.location=n.location),n?.allLocations&&(i.allLocations=!0),n?.noLocation&&(i.noLocation=!0),he(()=>Q6({client:W,path:{name:e},body:i}))}function dne(e,n){return he(()=>q6({client:W,path:{name:e},body:n}))}async function mne(e,n){await he(()=>P6({client:W,path:{name:e,label:n}}))}function pne(e,n){return he(()=>M6({client:W,path:{name:e},body:{label:n}}))}async function hne(e){await he(()=>u6({client:W,path:{name:e}}))}function fne(){return he(()=>vk({client:W}))}function Yw(){return qs("/session")}function oK(e){return qs("/session/setup",{method:"POST",body:JSON.stringify({password:e})})}function rK(e){return qs("/session",{method:"POST",body:JSON.stringify({password:e})})}function lK(e){return qs("/session",{method:"POST",body:JSON.stringify({apiKey:e})})}function cK(){return qs("/session",{method:"DELETE"})}function kf(){return he(()=>i_({client:W}))}function Xw(){return qs("/auth/session")}function uK(e,n){return qs("/auth/login",{method:"POST",body:JSON.stringify({name:e,password:n})})}function Jw(){return qs("/auth/logout",{method:"POST"})}function eC(e,n){return he(()=>n_({client:W,path:{name:e},body:n}))}async function o1(e){for(let n=0;n<2;n+=1)try{await he(()=>y_({client:W,body:e}));return}catch(i){if(!(!(i instanceof Sn)||i.statusCode>=500)||n===1)return}}function gne(e){return he(()=>a_({client:W,body:e}))}function yne(e,n){return he(()=>c_({client:W,path:{name:e},body:n}))}async function bne(e,n){await he(()=>r_({client:W,path:{name:e},query:n===void 0?void 0:{expectedUpdatedAt:n}}))}function vne(e){return he(()=>d_({client:W,path:{name:e}}))}function xne(e,n){return he(()=>m_({client:W,path:{name:e},body:n}))}async function wne(e,n){await he(()=>p_({client:W,path:{name:e,id:n}}))}function Sne(e,n){return he(()=>h_({client:W,path:{name:e,id:n}}))}function dK(e,n,i){return he(()=>V6({client:W,path:{name:e},body:{provider:n,count:i}}))}function mK(e){return he(()=>Y6({client:W,body:e}))}function pK(e){return he(()=>Z6({client:W,body:e??{}}))}function kne(e,n){const i=QG();return he(()=>L_({client:W,path:{name:e},body:{type:n,...i?{publicUrl:i}:{}}}))}function jne(e,n){return he(()=>$_({client:W,path:{name:e,type:n}}))}function Ane(e,n,i){return he(()=>U_({client:W,path:{name:e,type:n},body:{propertyId:i}}))}function Cne(e,n,i){return he(()=>G_({client:W,path:{name:e,type:n},body:{sitemapUrl:i}}))}function hK(e,n){return he(()=>K_({client:W,path:{name:e},body:n??{}}))}function Nne(e,n){const i={};return n&&n!=="all"&&(i.window=n),he(()=>e_({client:W,path:{name:e},query:i}))}function _ne(e,n){return he(()=>F_({client:W,path:{name:e},body:{url:n}}))}function fK(e,n){return he(()=>eT({client:W,path:{name:e},body:n??{}}))}function Tne(e,n){return he(()=>W_({client:W,path:{name:e},query:n?{sitemapIndex:n}:void 0}))}function Ene(e,n){return he(()=>r6({client:W,path:{name:e},body:{sitemapUrls:n}}))}function gK(e,n){return he(()=>f8({client:W,path:{name:e},body:n??{}}))}function Rne(e,n){return he(()=>n8({client:W,path:{name:e},body:n??{}}))}function Dne(){return he(()=>xk({client:W}))}function zne(e,n){return he(()=>o_({client:W,body:{host:e,port:n}}))}function Ine(e,n){return he(()=>tT({client:W,path:{name:e},body:n}))}function One(e,n){return he(()=>uT({client:W,path:{name:e},body:{apiKey:n}}))}function qne(e){return he(()=>dT({client:W,path:{name:e}}))}function Pne(e,n){return he(()=>hT({client:W,path:{name:e},body:{siteUrl:n}}))}function Mne(e,n){return he(()=>yT({client:W,path:{name:e},body:{url:n}}))}function Bne(e,n){return he(()=>bT({client:W,path:{name:e},body:{}}))}function Lne(e,n){return he(()=>vT({client:W,path:{name:e},body:n}))}function $ne(e){return he(()=>s_({client:W,body:{apiKey:e}}))}function tC(e){return e?/filename\s*=\s*"?([^";]+)"?/i.exec(e)?.[1]??null:null}async function Vne(e,n="agency",i){const r=new URLSearchParams({audience:n});i!==void 0&&r.set("period",String(i));const u=await fetch(n1(`${i1}/projects/${encodeURIComponent(e)}/report.html?${r.toString()}`),{credentials:"same-origin",headers:{}});if(!u.ok)throw new Sn(`Failed to download report: ${u.status}`,u.status);const h=await u.blob(),f=URL.createObjectURL(h),b=tC(u.headers.get("Content-Disposition"))??`canonry-report-${e}.html`,v=document.createElement("a");v.href=f,v.download=b,document.body.appendChild(v),v.click(),document.body.removeChild(v),URL.revokeObjectURL(f)}async function Une(e,n){const i=await fetch(`${i1}/projects/${encodeURIComponent(e)}/results/export?format=${n}`,{credentials:"same-origin",headers:{}});if(!i.ok)throw new Sn(`Failed to download results: ${i.status}`,i.status);const r=await i.blob(),u=URL.createObjectURL(r),h=tC(i.headers.get("Content-Disposition"))??`canonry-results-${e}.${n}`,f=document.createElement("a");f.href=u,f.download=h,document.body.appendChild(f),f.click(),document.body.removeChild(f),URL.revokeObjectURL(u)}function Gne(e,n){return he(()=>jT({client:W,path:{name:e},body:{}}))}function Kne(e,n){return he(()=>wT({client:W,path:{name:e},body:n}))}function Hne(e){return he(()=>ST({client:W,path:{name:e}}))}function Qne(e,n){return he(()=>QT({client:W,path:{name:e},body:n}))}function Fne(e,n){return he(()=>FT({client:W,path:{name:e},body:n}))}function Zne(e,n){return he(()=>ZT({client:W,path:{name:e},body:n}))}function Yne(e,n,i){return he(()=>YT({client:W,path:{name:e,id:n},body:i??{}}))}function Xne(e,n,i){return he(()=>XT({client:W,path:{name:e,id:n},body:{}}))}function Jne(e,n){return he(()=>TT({client:W,path:{name:e},query:{runId:n}}))}function yK(e){if(!e||typeof e!="object")return;const n=e;if(!(typeof n.current!="string"||typeof n.latest!="string"||typeof n.url!="string"||typeof n.upgradeCommand!="string"))return{current:n.current,latest:n.latest,url:n.url,upgradeCommand:n.upgradeCommand}}async function bK(e,n){const i=FG(e);try{const r=await fetch(i,{credentials:"same-origin"});if(!r.ok)return{label:n,state:"error",detail:`${n} ${r.status}: ${r.statusText}`,statusCode:r.status,hint:ZG(e,r.status)};const u=await r.json(),h=typeof u.version=="string"?u.version:"unknown",f=typeof u.databaseUrlConfigured=="boolean"?u.databaseUrlConfigured:void 0,b=typeof u.lastHeartbeatAt=="string"?u.lastHeartbeatAt:void 0,v=yK(u.updateAvailable),x=mG.safeParse(u.mcp),S=[h,f===!1?"database not configured":"database configured",b?`heartbeat ${b}`:void 0].filter(Boolean).join(" · ");return{label:n,state:"ok",detail:S,version:h,databaseConfigured:f,lastHeartbeatAt:b,...v?{updateAvailable:v}:{},...x.success?{mcp:x.data}:{}}}catch(r){return{label:n,state:"error",detail:r instanceof Error?r.message:"unreachable",hint:e==="/health"?`Request failed while checking ${i}. If this instance is served behind a sub-path, verify the dashboard basePath and reverse-proxy rewrites.`:void 0}}}function Wne(){return he(()=>OT({client:W}))}function eae(){return he(()=>qT({client:W}))}function tae(){return he(()=>BT({client:W}))}function nae(){return he(()=>PT({client:W}))}function aae(e){return he(()=>MT({client:W,body:e?{release:e}:{}}))}function iae(){return he(()=>LT({client:W}))}function sae(){return he(()=>$T({client:W}))}function oae(e){return he(()=>VT({client:W,path:{release:e}}))}function rae(e,n={}){return he(()=>GT({client:W,path:{name:e},query:{release:n.release,excludeCrawlers:n.excludeCrawlers?"1":void 0,source:n.source}}))}function lae(e,n={}){return he(()=>KT({client:W,path:{name:e},query:{limit:n.limit!==void 0?String(n.limit):void 0,offset:n.offset!==void 0?String(n.offset):void 0,release:n.release,excludeCrawlers:n.excludeCrawlers?"1":void 0,source:n.source}}))}function cae(e,n={}){return he(()=>HT({client:W,path:{name:e},query:{source:n.source}}))}function uae(e,n){return he(()=>UT({client:W,path:{name:e},body:{release:void 0}}))}async function Ww(e,n){return he(()=>b8({client:W,path:{name:e},query:n}))}async function vK(e,n){return he(()=>v8({client:W,path:{name:e},body:{id:n}}))}async function xK(e,n){return he(()=>w8({client:W,path:{name:e,id:n}}))}async function wK(e,n){return he(()=>x8({client:W,path:{name:e,id:n}}))}async function SK(e,n){const i=f=>he(()=>b6({client:W,path:{name:e},query:{...n,include:["assessments","locations"],queryLimit:D3,queryCursor:f}})),r=await i(),u=[...r.queries];let h=r.queryPage?.nextCursor??null;for(;h;){const f=await i(h);u.push(...f.queries),h=f.queryPage?.nextCursor??null}return{...r,queries:u,...r.queryPage?{queryPage:{...r.queryPage,nextCursor:null}}:{}}}function _d(e){return he(()=>g6({client:W,path:{name:e}}))}function kK(e,n){return he(()=>y6({client:W,path:{name:e},body:n}))}function jK(e,n,i){return he(()=>v6({client:W,path:{name:e},query:{...n,cursor:i,limit:50}}))}function AK(e,n){return he(()=>x6({client:W,path:{name:e},query:n}))}function CK(e,n,i){return he(()=>w6({client:W,path:{name:e},body:{previewToken:n,idempotencyKey:i}}))}function NK(e){return he(()=>S6({client:W,path:{name:e}}))}function _K(e,n,i){return he(()=>k6({client:W,path:{name:e,jobId:n},query:{attemptCursor:i}}))}const nC={account:null,canWrite:!0,isAdmin:!0},TK={account:null,canWrite:!1,isAdmin:!1};function EK(e){const n=e.scopes.includes(Vw);return{account:null,canWrite:!e.readOnly&&n,isAdmin:e.projectId===null&&e.scopes.includes(Vw)}}const aC=C.createContext(nC);function RK({account:e,apiKey:n,apiKeyPending:i=!1,children:r}){const u=i?TK:n?EK(n):e?{account:e,canWrite:e.role==="admin",isAdmin:e.role==="admin"}:nC;return l.jsx(aC.Provider,{value:u,children:r})}function fa(){return C.useContext(aC)}const iC="View only — your account cannot change this.";function hn(e){return(...n)=>{e(...n)}}const DK=6e3,zK=5,IK=180;let Mn=[],OK=0;const lg=new Set,cg=new Map,ug=new Map;function Fd(){const e=[...Mn];for(const n of lg)n(e)}function r1(e){const n=cg.get(e);n&&(clearTimeout(n),cg.delete(e));const i=ug.get(e);i&&(clearTimeout(i),ug.delete(e))}function sC(e){r1(e);const n=Mn.length;Mn=Mn.filter(i=>i.id!==e),Mn.length!==n&&Fd()}function eS(e){r1(e.id),cg.set(e.id,setTimeout(()=>{dg(e.id)},e.durationMs))}function qK(e,n,i){return typeof e=="string"?{title:e,tone:n,durationMs:i}:e}function kn(e,n="negative",i=DK){const r=qK(e,n,i),u={id:String(++OK),title:r.title,detail:r.detail,tone:r.tone??n,durationMs:r.durationMs??i,dedupeKey:r.dedupeKey,cta:r.cta,state:"open"};if(r.dedupeKey){const h=Mn.find(f=>f.dedupeKey===r.dedupeKey);if(h){if((r.dedupeMode??"drop")==="drop")return h.id;const f={...h,title:u.title,detail:u.detail,tone:u.tone,durationMs:u.durationMs,cta:u.cta,state:"open"};return Mn=Mn.map(b=>b.id===h.id?f:b),Fd(),eS(f),h.id}}return Mn.length>=zK&&sC(Mn[0].id),Mn=[...Mn,u],Fd(),eS(u),u.id}function dg(e){const n=Mn.find(i=>i.id===e);!n||n.state==="closing"||(r1(e),Mn=Mn.map(i=>i.id===e?{...i,state:"closing"}:i),Fd(),ug.set(e,setTimeout(()=>{sC(e)},IK)))}function PK(e){return lg.add(e),()=>{lg.delete(e)}}function tS(){return Mn}const MK=5*6e4,Td=30*6e4,dae=3e4,mae=6e4,Gr=3e4,BK=2e3,LK=3e4;function $K(){return new o5({defaultOptions:{queries:{staleTime:MK,retry:1,refetchOnWindowFocus:!1}},mutationCache:new r5({onError:(n,i,r,u)=>{u.meta?.skipGlobalErrorToast||kn({title:n instanceof Error?n.message:"An unexpected error occurred",tone:"negative"})}})})}const VK="modulepreload",UK=function(e,n){return new URL(e,n).href},nS={},Gi=function(n,i,r){let u=Promise.resolve();if(i&&i.length>0){let x=function(S){return Promise.all(S.map(k=>Promise.resolve(k).then(T=>({status:"fulfilled",value:T}),T=>({status:"rejected",reason:T}))))};const f=document.getElementsByTagName("link"),b=document.querySelector("meta[property=csp-nonce]"),v=b?.nonce||b?.getAttribute("nonce");u=x(i.map(S=>{if(S=UK(S,r),S in nS)return;nS[S]=!0;const k=S.endsWith(".css"),T=k?'[rel="stylesheet"]':"";if(r)for(let I=f.length-1;I>=0;I--){const P=f[I];if(P.href===S&&(!k||P.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${S}"]${T}`))return;const N=document.createElement("link");if(N.rel=k?"stylesheet":VK,k||(N.as="script"),N.crossOrigin="",N.href=S,v&&N.setAttribute("nonce",v),document.head.appendChild(N),k)return new Promise((I,P)=>{N.addEventListener("load",I),N.addEventListener("error",()=>P(new Error(`Unable to preload CSS for ${S}`)))})}))}function h(f){const b=new Event("vite:preloadError",{cancelable:!0});if(b.payload=f,window.dispatchEvent(b),!b.defaultPrevented)throw f}return u.then(f=>{for(const b of f||[])b.status==="rejected"&&h(b.reason);return n().catch(h)})},l1=C.createContext({view:null,publish:()=>()=>{}});function GK({children:e}){const[n,i]=C.useState(null),r=C.useCallback(u=>(i(u),()=>i(h=>h===u?null:h)),[]);return l.jsx(l1.Provider,{value:C.useMemo(()=>({view:n,publish:r}),[n,r]),children:e})}function pae(e,n){const{publish:i}=C.useContext(l1),r=JSON.stringify(n);C.useEffect(()=>i({project:e,context:JSON.parse(r)}),[i,e,r])}function KK(e,n){const{view:i}=C.useContext(l1);return i?.project===e&&i.context.view===n.view?i.context:n}var HK=(e=>(e.Clicks="clicks",e.Impressions="impressions",e.CTR="ctr",e.Position="position",e))(HK||{});const hae={clicks:"Clicks",impressions:"Impressions",ctr:"CTR",position:"Position"},fae={clicks:"Clicks",impressions:"Impr",ctr:"CTR",position:"Pos"},QK=h0;function gae(e){return e.endsWith("%")?{figure:e.slice(0,-1),sign:"%"}:{figure:e,sign:""}}function FK(e){const n=[];if(e.message&&n.push(e.message),e.providers)for(const[i,r]of Object.entries(e.providers)){const u=`[${i}] ${r.message}`;r.raw!==void 0?n.push(`${u}
|
|
53
|
+
|
|
54
|
+
${JSON.stringify(r.raw,null,2)}`):n.push(u)}return n.length>0?n.join(`
|
|
55
|
+
|
|
56
|
+
`):"Run failed."}function ZK(e){return e.split("-").map(n=>n.charAt(0).toUpperCase()+n.slice(1)).join(" ")}function YK(e,n,i=new Date){const r=new Date(e);if(Number.isNaN(r.getTime()))return e;const u=r.toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit"});return n&&new Date(n).toDateString()===r.toDateString()?u:`${XK(e,i)}, ${u}`}function XK(e,n=new Date){const i=new Date(e);return Number.isNaN(i.getTime())?e:i.getFullYear()===n.getFullYear()?JK(e):i.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}function JK(e){const n=new Date(e);return Number.isNaN(n.getTime())?e:n.toLocaleDateString("en-US",{month:"short",day:"numeric"})}function WK(e){if(!e)return"—";try{return new Date(e).toLocaleString()}catch{return e}}function yae(e){return e===null?"Unknown":e?"Pass":"Fail"}function aS(e){return e===0?"12:00 AM":e<12?`${e}:00 AM`:e===12?"12:00 PM":`${e-12}:00 PM`}function bae(e,n){return e==="twice-daily"?"twice-daily":e.startsWith("weekly@")?`${e}@${n}`:`daily@${n}`}function vae(e,n){if(!e)return{freq:"custom",hour:6,customCron:n};if(e==="twice-daily")return{freq:"twice-daily",hour:6,customCron:""};const i=e.match(/^daily(?:@(\d+))?$/);if(i)return{freq:"daily",hour:i[1]?parseInt(i[1]):6,customCron:""};const r=e.match(/^(weekly@(?:mon|tue|wed|thu|fri|sat|sun))(?:@(\d+))?$/);return r?{freq:r[1],hour:r[2]?parseInt(r[2]):6,customCron:""}:{freq:"custom",hour:6,customCron:n}}function xae(e,n,i){const r=i==="UTC"?"UTC":i.split("/").pop()?.replace(/_/g," ")??i;if(!e)return`Custom: ${n} · ${r}`;if(e==="twice-daily")return`Twice a day (6am & 6pm) · ${r}`;const u=e.match(/^daily(?:@(\d+))?$/);if(u){const f=u[1]?parseInt(u[1]):6;return`Every day at ${aS(f)} · ${r}`}const h=e.match(/^weekly@(mon|tue|wed|thu|fri|sat|sun)(?:@(\d+))?$/);if(h){const f={mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday",sun:"Sunday"},b=h[2]?parseInt(h[2]):6;return`Every ${f[h[1]]} at ${aS(b)} · ${r}`}return`${e} · ${r}`}function eH(e,n){return n&&n!==e?`${e} · ${n}`:e}function wae(){const e=Intl.DateTimeFormat().resolvedOptions().timeZone,n=new Intl.DateTimeFormat("en-US",{timeZoneName:"short"}).formatToParts().find(i=>i.type==="timeZoneName")?.value;return eH(e,n)}function tH(e){const n=e.replace(/\/+$/,"")||"/";return n==="/"?"overview":n==="/projects"?"projects":n.startsWith("/projects/")?"project":n==="/runs"?"runs":n==="/traffic"||n.startsWith("/traffic/")?"traffic":n==="/backlinks"?"backlinks":n==="/settings"?"settings":n==="/setup"?"setup":"other"}function nH(e,n){return!n||n.includes(e)}const oC=["overview","search-console","local","report","activity","backlinks","technical-aeo","history","settings"],aH=new Set(oC);function iH(e){const n=e??oC,i=[...new Set(n.filter(r=>aH.has(r)))];return i.length>0?i:["overview"]}function Sae(e){return e?iH(e.projectTabs):void 0}function kae(e,n){return nH(e,n)||!n?e:n.includes("overview")?"overview":n[0]??"overview"}const iS={bg:"--canonry-embed-bg",fg:"--canonry-embed-fg",accent:"--color-link"},sH=/^(?:#(?:[0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})|rgba?\([0-9.,%\s/]+\)|hsla?\([0-9.,%\s/a-z]+\))$/i;function oH(e){const n=e?.mode?.trim();return n==="light"||n==="dark"?n:void 0}function rH(e){if(!e)return{};const n={};for(const[i,r]of Object.entries(e)){const u=Object.hasOwn(iS,i)?iS[i]:void 0;if(!u||typeof r!="string")continue;const h=r.trim();sH.test(h)&&(n[u]=h)}return n}const fe=(e,n,i,r)=>{const u={_id:e,baseUrl:n?.baseUrl||(n?.client??z).getConfig().baseUrl};return i&&(u._infinite=i),n?.body&&(u.body=n.body),n?.headers&&(u.headers=n.headers),n?.path&&(u.path=n.path),n?.query&&(u.query=n.query),[u]},_s=e=>fe("getApiV1Projects",e),qo=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await l6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:_s(e)}),lH=e=>fe("getApiV1ProjectsByName",e),cH=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await hk({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:lH(e)}),uH=e=>fe("getApiV1ProjectsByNameMeasurementPlan",e),jae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await m6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:uH(e)}),dH=e=>fe("getApiV1ProjectsByNameMeasurementReport",e),Aae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await p6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:dH(e)}),mH=e=>fe("getApiV1ProjectsByNameMeasurementSetup",e),pH=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await h6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:mH(e)}),Hc=(e,n)=>{const i={...e[0]};return n.body&&(i.body={...e[0].body,...n.body}),n.headers&&(i.headers={...e[0].headers,...n.headers}),n.path&&(i.path={...e[0].path,...n.path}),n.query&&(i.query={...e[0].query,...n.query}),i},Cae=e=>({mutationFn:async i=>{const{data:r}=await f6({...e,...i,throwOnError:!0});return r}}),hH=e=>fe("getApiV1ProjectsByNameMeasurementOverview",e),Nae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await fk({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:hH(e)}),fH=e=>fe("getApiV1ProjectsByNameMeasurementOverview",e,!0),_ae=e=>Ec({queryFn:async({pageParam:n,queryKey:i,signal:r})=>{const h=Hc(i,typeof n=="object"?n:{query:{cursor:n}}),{data:f}=await fk({...e,...h,signal:r,throwOnError:!0});return f},queryKey:fH(e)}),gH=e=>fe("getApiV1ProjectsByNameVisibilityReport",e),Tae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await j6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:gH(e)}),yH=e=>fe("getApiV1ProjectsByNameMeasurementPropertyEvidence",e,!0),Eae=e=>Ec({queryFn:async({pageParam:n,queryKey:i,signal:r})=>{const h=Hc(i,typeof n=="object"?n:{query:{cursor:n}}),{data:f}=await A6({...e,...h,signal:r,throwOnError:!0});return f},queryKey:yH(e)}),bH=e=>fe("getApiV1ProjectsByNameMeasurementQuestionResult",e),Rae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await C6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:bH(e)}),vH=e=>fe("getApiV1ProjectsByNameMeasurementPropertyCompetitors",e),Dae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await N6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:vH(e)}),xH=e=>fe("getApiV1ProjectsByNameMeasurementQueryTemplates",e),zae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await _6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:xH(e)}),Iae=e=>({mutationFn:async i=>{const{data:r}=await T6({...e,...i,throwOnError:!0});return r}}),wH=e=>fe("getApiV1ProjectsByNameResearchRuns",e,!0),Oae=e=>Ec({queryFn:async({pageParam:n,queryKey:i,signal:r})=>{const h=Hc(i,typeof n=="object"?n:{query:{cursor:n}}),{data:f}=await E6({...e,...h,signal:r,throwOnError:!0});return f},queryKey:wH(e)}),qae=e=>({mutationFn:async i=>{const{data:r}=await R6({...e,...i,throwOnError:!0});return r}}),SH=e=>fe("getApiV1ProjectsByNameQueryTracking",e),Pae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await D6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:SH(e)}),Mae=e=>({mutationFn:async i=>{const{data:r}=await z6({...e,...i,throwOnError:!0});return r}}),Bae=e=>({mutationFn:async i=>{const{data:r}=await I6({...e,...i,throwOnError:!0});return r}}),kH=e=>fe("getApiV1ProjectsByNameResearchRunsByRunId",e),Lae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await O6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:kH(e)}),rC=e=>fe("getApiV1ProjectsByNameQueries",e),$ae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await gk({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:rC(e)}),jH=e=>fe("getApiV1ProjectsByNameAnalyticsCompetitors",e),Vae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await H6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:jH(e)}),AH=e=>fe("getApiV1ProjectsByNameRuns",e),lC=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await yk({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:AH(e)}),c1=e=>fe("getApiV1Runs",e),zm=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await F6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:c1(e)}),CH=e=>fe("getApiV1RunsById",e),u1=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await bk({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:CH(e)}),NH=e=>fe("getApiV1ProjectsByNameHistory",e),Uae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await X6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:NH(e)}),_H=e=>fe("getApiV1History",e),Gae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await J6({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:_H(e)}),TH=e=>fe("getApiV1ProjectsByNameSnapshotsDiff",e),Kae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await t_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:TH(e)}),EH=e=>fe("getApiV1Settings",e),RH=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await vk({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:EH(e)}),DH=e=>fe("getApiV1ProjectsByNameSchedule",e),zH=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await l_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:DH(e)}),IH=e=>fe("getApiV1ProjectsByNameSchedules",e),Hae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await u_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:IH(e)}),cC=e=>fe("getApiV1Telemetry",e),OH=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await f_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:cC(e)}),qH=e=>({mutationFn:async i=>{const{data:r}=await g_({...e,...i,throwOnError:!0});return r}}),PH=e=>fe("getApiV1CdpStatus",e),MH=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await xk({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:PH(e)}),BH=e=>fe("getApiV1ProjectsByNameGoogleAdsStatus",e),Qae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await b_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:BH(e)}),Fae=e=>({mutationFn:async i=>{const{data:r}=await v_({...e,...i,throwOnError:!0});return r}}),LH=e=>fe("getApiV1ProjectsByNameGoogleAdsCustomers",e),Zae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await x_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:LH(e)}),Yae=e=>({mutationFn:async i=>{const{data:r}=await w_({...e,...i,throwOnError:!0});return r}}),Xae=e=>({mutationFn:async i=>{const{data:r}=await S_({...e,...i,throwOnError:!0});return r}}),$H=e=>fe("getApiV1ProjectsByNameGoogleAdsPerformance",e),Jae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await k_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:$H(e)}),VH=e=>fe("getApiV1ProjectsByNameGoogleAdsSnapshots",e),Wae=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await j_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:VH(e)}),eie=e=>({mutationFn:async i=>{const{data:r}=await A_({...e,...i,throwOnError:!0});return r}}),UH=e=>fe("getApiV1ProjectsByNameGtmStatus",e),tie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await C_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:UH(e)}),nie=e=>({mutationFn:async i=>{const{data:r}=await N_({...e,...i,throwOnError:!0});return r}}),GH=e=>fe("getApiV1ProjectsByNameGtmAccounts",e),aie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await __({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:GH(e)}),KH=e=>fe("getApiV1ProjectsByNameGtmAccountsByAccountIdContainers",e),iie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await T_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:KH(e)}),HH=e=>fe("getApiV1ProjectsByNameGtmAccountsByAccountIdContainersByContainerIdWorkspaces",e),sie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await E_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:HH(e)}),oie=e=>({mutationFn:async i=>{const{data:r}=await R_({...e,...i,throwOnError:!0});return r}}),rie=e=>({mutationFn:async i=>{const{data:r}=await D_({...e,...i,throwOnError:!0});return r}}),QH=e=>fe("getApiV1ProjectsByNameGtmSnapshots",e),lie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await z_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:QH(e)}),cie=e=>({mutationFn:async i=>{const{data:r}=await I_({...e,...i,throwOnError:!0});return r}}),FH=e=>fe("getApiV1ProjectsByNameConversionTrackingOptions",e),uie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await O_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:FH(e)}),ZH=e=>fe("getApiV1ProjectsByNameConversionTrackingContracts",e),die=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await q_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:ZH(e)}),mie=e=>({mutationFn:async i=>{const{data:r}=await P_({...e,...i,throwOnError:!0});return r}}),YH=e=>fe("getApiV1ProjectsByNameConversionTrackingContractsByContractIdIntegrity",e),pie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await M_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:YH(e)}),XH=e=>fe("getApiV1ProjectsByNameGoogleConnections",e),hie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await B_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:XH(e)}),JH=e=>fe("getApiV1ProjectsByNameGoogleProperties",e),fie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await V_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:JH(e)}),WH=e=>fe("getApiV1ProjectsByNameGoogleGscPerformance",e),gie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await H_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:WH(e)}),eQ=e=>fe("getApiV1ProjectsByNameGoogleGscPerformanceDaily",e),yie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await Q_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:eQ(e)}),tQ=e=>fe("getApiV1ProjectsByNameGoogleGscInspections",e),bie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await Z_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:tQ(e)}),nQ=e=>fe("getApiV1ProjectsByNameGoogleGscDeindexed",e),vie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await Y_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:nQ(e)}),aQ=e=>fe("getApiV1ProjectsByNameGoogleGscCoverage",e),xie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await X_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:aQ(e)}),iQ=e=>fe("getApiV1ProjectsByNameGoogleGscCoverageHistory",e),wie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await J_({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:iQ(e)}),Sie=e=>fe("getApiV1ProjectsByNameGoogleGscSitemaps",e),sQ=e=>fe("getApiV1ProjectsByNameGbpLocations",e),kie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await nT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:sQ(e)}),jie=e=>({mutationFn:async i=>{const{data:r}=await aT({...e,...i,throwOnError:!0});return r}}),Aie=e=>({mutationFn:async i=>{const{data:r}=await iT({...e,...i,throwOnError:!0});return r}}),oQ=e=>fe("getApiV1ProjectsByNameGbpKeywords",e),Cie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await sT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:oQ(e)}),rQ=e=>fe("getApiV1ProjectsByNameGbpPlaceActions",e),Nie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await oT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:rQ(e)}),lQ=e=>fe("getApiV1ProjectsByNameGbpLodging",e),_ie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await rT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:lQ(e)}),cQ=e=>fe("getApiV1ProjectsByNameGbpPlaces",e),Tie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await lT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:cQ(e)}),uQ=e=>fe("getApiV1ProjectsByNameGbpSummary",e),Eie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await cT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:uQ(e)}),dQ=e=>fe("getApiV1ProjectsByNameBingStatus",e),Rie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await mT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:dQ(e)}),mQ=e=>fe("getApiV1ProjectsByNameBingSites",e),Die=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await pT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:mQ(e)}),pQ=e=>fe("getApiV1ProjectsByNameBingCoverage",e),zie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await fT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:pQ(e)}),hQ=e=>fe("getApiV1ProjectsByNameBingInspections",e),Iie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await gT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:hQ(e)}),fQ=e=>fe("getApiV1ProjectsByNameBingPerformance",e),Oie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await xT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:fQ(e)}),gQ=e=>fe("getApiV1ProjectsByNameGaStatus",e),qie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await kT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:gQ(e)}),yQ=e=>fe("getApiV1ProjectsByNameGaTraffic",e),Pie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await AT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:yQ(e)}),bQ=e=>fe("getApiV1ProjectsByNameGaAiReferralDaily",e),Mie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await CT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:bQ(e)}),vQ=e=>fe("getApiV1ProjectsByNameGaSocialReferralHistory",e),Bie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await NT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:vQ(e)}),xQ=e=>fe("getApiV1ProjectsByNameGaSessionHistory",e),Lie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await _T({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:xQ(e)}),wQ=e=>fe("getApiV1ProjectsByNameReport",e),$ie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await ET({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:wQ(e)}),SQ=e=>fe("getApiV1ProjectsByNameHealthHistory",e),Vie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await RT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:SQ(e)}),kQ=e=>fe("getApiV1ProjectsByNameCitationsVisibility",e),Uie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await DT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:kQ(e)}),jQ=e=>fe("getApiV1ProjectsByNameTrafficSources",e),Gie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await JT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:jQ(e)}),AQ=e=>fe("getApiV1ProjectsByNameTrafficStatus",e),Kie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await WT({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:AQ(e)}),CQ=e=>fe("getApiV1ProjectsByNameTrafficSourcesById",e),Hie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await e8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:CQ(e)}),NQ=e=>fe("getApiV1ProjectsByNameTrafficEvents",e),Qie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await t8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:NQ(e)}),_Q=e=>fe("getApiV1ProjectsByNameDiscoverSessions",e),Fie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await a8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:_Q(e)}),TQ=e=>fe("getApiV1ProjectsByNameDiscoverSessionsById",e),Zie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await i8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:TQ(e)}),EQ=e=>fe("getApiV1ProjectsByNameTechnicalAeo",e),RQ=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await s8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:EQ(e)}),DQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoPages",e),Yie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await o8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:DQ(e)}),zQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoTrend",e),Xie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await r8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:zQ(e)}),IQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoCrawl",e),Jie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await l8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:IQ(e)}),OQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoGraph",e),Wie=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await c8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:OQ(e)}),qQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoCrawlPagesAudit",e),ese=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await u8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:qQ(e)}),PQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoCrawlPages",e),tse=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await wk({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:PQ(e)}),MQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoCrawlPages",e,!0),nse=e=>Ec({queryFn:async({pageParam:n,queryKey:i,signal:r})=>{const h=Hc(i,typeof n=="object"?n:{query:{cursor:n}}),{data:f}=await wk({...e,...h,signal:r,throwOnError:!0});return f},queryKey:MQ(e)}),BQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoStructure",e,!0),ase=e=>Ec({queryFn:async({pageParam:n,queryKey:i,signal:r})=>{const h=Hc(i,typeof n=="object"?n:{query:{cursor:n}}),{data:f}=await d8({...e,...h,signal:r,throwOnError:!0});return f},queryKey:BQ(e)}),LQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoInternalLinksNeighbors",e),ise=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await m8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:LQ(e)}),$Q=e=>fe("getApiV1ProjectsByNameTechnicalAeoDeadLinks",e),sse=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await p8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:$Q(e)}),VQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoRuns",e),ose=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await h8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:VQ(e)}),UQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoRunsByRunIdProgress",e),rse=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await g8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:UQ(e)}),GQ=e=>fe("getApiV1ProjectsByNameTechnicalAeoRunsByRunIdPageHealthPreview",e),lse=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await y8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:GQ(e)}),KQ=e=>fe("getApiV1ProjectsByNameAgentProviders",e),HQ=e=>be({queryFn:async({queryKey:n,signal:i})=>{const{data:r}=await S8({...e,...n[0],signal:i,throwOnError:!0});return r},queryKey:KQ(e)});function sS(e){return e.state==="ok"?"positive":e.state==="checking"||e.state==="disabled"?"neutral":"negative"}function uC(e){switch(e){case"completed":return"positive";case"partial":return"caution";case"failed":return"negative";case"cancelled":return"caution";case"queued":case"running":return"neutral";default:return"neutral"}}function cse(e){switch(e){case"cited":return"positive";case"emerging":return"caution";case"not-cited":return"caution";case"lost":return"negative";case"pending":return"neutral";default:return"neutral"}}const use={positive:"text-positive-400",caution:"text-caution-400",negative:"text-negative-400",neutral:"text-secondary"};function dse(e){return e>=50?"positive":e>=25?"caution":"negative"}function QQ(e){return e.displayName??e.name.charAt(0).toUpperCase()+e.name.slice(1)}function Kr(e){const n=[e.detail,e.hint].filter(Boolean);return n.length>0?n.join(`
|
|
57
|
+
`):void 0}function FQ(e,n,i){const r=e.filter(f=>f.id!=="mcp").map(f=>{if(f.id==="api")return{...f,tone:sS(n.apiStatus),detail:n.apiStatus.state==="ok"?"Healthy":"Needs attention",meta:n.apiStatus.detail};if(f.id==="worker")return{...f,tone:sS(n.workerStatus),detail:n.workerStatus.state==="ok"?"Healthy":n.workerStatus.state==="disabled"?"Disabled":"Needs attention",meta:n.workerStatus.detail};const b=i.providerStatuses.filter(k=>k.state==="ready").length,v=i.providerStatuses.length,x=b>0,S=i.providerStatuses.filter(k=>k.state==="ready").map(k=>QQ(k)).join(" · ");return{...f,label:"Providers",tone:x?"positive":"caution",detail:`${b} of ${v} configured`,meta:S||"None configured"}}),u=n.apiStatus.mcp,h={id:"mcp",label:"MCP",tone:"neutral",detail:"Unknown",meta:"MCP status is not available from this server."};return n.apiStatus.state==="checking"?(h.detail="Checking",h.meta="Checking MCP availability."):n.apiStatus.state==="ok"&&u&&(u.status==="available"?(h.tone="positive",h.detail="Available",h.meta="MCP is available for agent connections. This checks the server transport, not an individual client connection."):u.status==="unavailable"?(h.tone="negative",h.detail="Unavailable",h.meta="The MCP transport is not fully available. Contact your Canonry team."):(h.detail="Not enabled",h.meta="This server does not provide an MCP endpoint.")),r.splice(Math.max(0,r.findIndex(f=>f.id==="api")+1),0,h),r}function ZQ(e,n){if(e.apiStatus.state!=="ok")return"Launch is blocked until the API responds cleanly.";if(e.apiStatus.databaseConfigured===!1)return"Launch is blocked until the API has a database connection configured.";if(e.workerStatus.state!=="ok")return"Launch is blocked until the worker is healthy and heartbeats are current.";if(!n.providerStatuses.some(i=>i.state==="ready"))return"Launch is blocked until at least one provider is configured."}function YQ(e,n,i){const r=ZQ(n,i),u=structuredClone(e);return u.healthChecks=u.healthChecks.map(h=>{if(h.id==="api")return{...h,detail:n.apiStatus.detail,state:n.apiStatus.state==="ok"?"ready":"attention"};if(h.id==="worker")return{...h,detail:n.workerStatus.detail,state:n.workerStatus.state==="ok"?"ready":"attention"};const f=i.providerStatuses.some(b=>b.state==="ready");return{...h,detail:f?"At least one provider configured.":"No providers configured.",state:f?"ready":"attention"}}),u.launchState.enabled=r===void 0,u.launchState.blockedReason=r,u.launchState.summary=r??"Queue a visibility sweep first, then follow with a site audit to explain movement.",u}const dC="canonry.run-tracker",mg=new Set;let oS=!1,XQ=0,Im={runs:{},batches:{}};function JQ(){const e=Vi();for(const n of mg)n(e)}function WQ(e){if(!e)return{runs:{},batches:{}};try{const n=JSON.parse(e);return{runs:n.runs??{},batches:n.batches??{}}}catch{return{runs:{},batches:{}}}}function eF(){typeof window>"u"||window.sessionStorage.setItem(dC,JSON.stringify(Im))}function mC(){oS||(oS=!0,!(typeof window>"u")&&(Im=WQ(window.sessionStorage.getItem(dC))))}function Om(e){Im=e,eF(),JQ()}function Vi(){return mC(),Im}function pC(e){return mC(),mg.add(e),()=>{mg.delete(e)}}function d1(e){const n=Vi();Om({...n,runs:{...n.runs,[e.id]:{runId:e.id,projectId:e.projectId,projectLabel:e.projectLabel,kind:e.kind,sourceAction:e.sourceAction,lastAnnouncedStatus:e.lastAnnouncedStatus??"queued",trackedAt:e.trackedAt??Date.now()}}})}function jf(e){const n=Vi();if(!n.runs[e])return;const{[e]:i,...r}=n.runs;Om({...n,runs:r})}function tF(e){const n=Vi(),i=`batch_${Date.now()}_${++XQ}`;return Om({...n,batches:{...n.batches,[i]:{batchId:i,runIds:e.runIds,queuedCount:e.queuedCount,skippedCount:e.skippedCount}}}),i}function nF(e){const n=Vi();if(!n.batches[e])return;const{[e]:i,...r}=n.batches;Om({...n,batches:r})}function aF(e){return e==="completed"||e==="partial"||e==="failed"||e==="cancelled"}const iF=10*6e4;function sF(e,n,i,r){return e.filter(u=>!n.has(u.runId)&&i-(u.trackedAt??0)>=r)}function oF(e,n){let i=0,r=0,u=0,h=0,f=0;for(const b of e){const v=n[b]?.status;v==="completed"?i+=1:v==="partial"?r+=1:v==="failed"?u+=1:v==="cancelled"?h+=1:f+=1}return{completed:i,partial:r,failed:u,cancelled:h,pending:f,finished:f===0}}const rS=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,lS=WS,hC=(e,n)=>i=>{var r;if(n?.variants==null)return lS(e,i?.class,i?.className);const{variants:u,defaultVariants:h}=n,f=Object.keys(u).map(x=>{const S=i?.[x],k=h?.[x];if(S===null)return null;const T=rS(S)||rS(k);return u[x][T]}),b=i&&Object.entries(i).reduce((x,S)=>{let[k,T]=S;return T===void 0||(x[k]=T),x},{}),v=n==null||(r=n.compoundVariants)===null||r===void 0?void 0:r.reduce((x,S)=>{let{class:k,className:T,...N}=S;return Object.entries(N).every(I=>{let[P,E]=I;return Array.isArray(E)?E.includes({...h,...b}[P]):{...h,...b}[P]===E})?[...x,k,T]:x},[]);return lS(e,f,v,i?.class,i?.className)},rF=(e,n)=>{const i=new Array(e.length+n.length);for(let r=0;r<e.length;r++)i[r]=e[r];for(let r=0;r<n.length;r++)i[e.length+r]=n[r];return i},lF=(e,n)=>({classGroupId:e,validator:n}),fC=(e=new Map,n=null,i)=>({nextPart:e,validators:n,classGroupId:i}),Zd="-",cS=[],cF="arbitrary..",uF=e=>{const n=mF(e),{conflictingClassGroups:i,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:f=>{if(f.startsWith("[")&&f.endsWith("]"))return dF(f);const b=f.split(Zd),v=b[0]===""&&b.length>1?1:0;return gC(b,v,n)},getConflictingClassGroupIds:(f,b)=>{if(b){const v=r[f],x=i[f];return v?x?rF(x,v):v:x||cS}return i[f]||cS}}},gC=(e,n,i)=>{if(e.length-n===0)return i.classGroupId;const u=e[n],h=i.nextPart.get(u);if(h){const x=gC(e,n+1,h);if(x)return x}const f=i.validators;if(f===null)return;const b=n===0?e.join(Zd):e.slice(n).join(Zd),v=f.length;for(let x=0;x<v;x++){const S=f[x];if(S.validator(b))return S.classGroupId}},dF=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const n=e.slice(1,-1),i=n.indexOf(":"),r=n.slice(0,i);return r?cF+r:void 0})(),mF=e=>{const{theme:n,classGroups:i}=e;return pF(i,n)},pF=(e,n)=>{const i=fC();for(const r in e){const u=e[r];m1(u,i,r,n)}return i},m1=(e,n,i,r)=>{const u=e.length;for(let h=0;h<u;h++){const f=e[h];hF(f,n,i,r)}},hF=(e,n,i,r)=>{if(typeof e=="string"){fF(e,n,i);return}if(typeof e=="function"){gF(e,n,i,r);return}yF(e,n,i,r)},fF=(e,n,i)=>{const r=e===""?n:yC(n,e);r.classGroupId=i},gF=(e,n,i,r)=>{if(bF(e)){m1(e(r),n,i,r);return}n.validators===null&&(n.validators=[]),n.validators.push(lF(i,e))},yF=(e,n,i,r)=>{const u=Object.entries(e),h=u.length;for(let f=0;f<h;f++){const[b,v]=u[f];m1(v,yC(n,b),i,r)}},yC=(e,n)=>{let i=e;const r=n.split(Zd),u=r.length;for(let h=0;h<u;h++){const f=r[h];let b=i.nextPart.get(f);b||(b=fC(),i.nextPart.set(f,b)),i=b}return i},bF=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,vF=e=>{if(e<1)return{get:()=>{},set:()=>{}};let n=0,i=Object.create(null),r=Object.create(null);const u=(h,f)=>{i[h]=f,n++,n>e&&(n=0,r=i,i=Object.create(null))};return{get(h){let f=i[h];if(f!==void 0)return f;if((f=r[h])!==void 0)return u(h,f),f},set(h,f){h in i?i[h]=f:u(h,f)}}},pg="!",uS=":",xF=[],dS=(e,n,i,r,u)=>({modifiers:e,hasImportantModifier:n,baseClassName:i,maybePostfixModifierPosition:r,isExternal:u}),wF=e=>{const{prefix:n,experimentalParseClassName:i}=e;let r=u=>{const h=[];let f=0,b=0,v=0,x;const S=u.length;for(let P=0;P<S;P++){const E=u[P];if(f===0&&b===0){if(E===uS){h.push(u.slice(v,P)),v=P+1;continue}if(E==="/"){x=P;continue}}E==="["?f++:E==="]"?f--:E==="("?b++:E===")"&&b--}const k=h.length===0?u:u.slice(v);let T=k,N=!1;k.endsWith(pg)?(T=k.slice(0,-1),N=!0):k.startsWith(pg)&&(T=k.slice(1),N=!0);const I=x&&x>v?x-v:void 0;return dS(h,N,T,I)};if(n){const u=n+uS,h=r;r=f=>f.startsWith(u)?h(f.slice(u.length)):dS(xF,!1,f,void 0,!0)}if(i){const u=r;r=h=>i({className:h,parseClassName:u})}return r},SF=e=>{const n=new Map;return e.orderSensitiveModifiers.forEach((i,r)=>{n.set(i,1e6+r)}),i=>{const r=[];let u=[];for(let h=0;h<i.length;h++){const f=i[h],b=f[0]==="[",v=n.has(f);b||v?(u.length>0&&(u.sort(),r.push(...u),u=[]),r.push(f)):u.push(f)}return u.length>0&&(u.sort(),r.push(...u)),r}},kF=e=>({cache:vF(e.cacheSize),parseClassName:wF(e),sortModifiers:SF(e),...uF(e)}),jF=/\s+/,AF=(e,n)=>{const{parseClassName:i,getClassGroupId:r,getConflictingClassGroupIds:u,sortModifiers:h}=n,f=[],b=e.trim().split(jF);let v="";for(let x=b.length-1;x>=0;x-=1){const S=b[x],{isExternal:k,modifiers:T,hasImportantModifier:N,baseClassName:I,maybePostfixModifierPosition:P}=i(S);if(k){v=S+(v.length>0?" "+v:v);continue}let E=!!P,$=r(E?I.substring(0,P):I);if(!$){if(!E){v=S+(v.length>0?" "+v:v);continue}if($=r(I),!$){v=S+(v.length>0?" "+v:v);continue}E=!1}const ee=T.length===0?"":T.length===1?T[0]:h(T).join(":"),L=N?ee+pg:ee,F=L+$;if(f.indexOf(F)>-1)continue;f.push(F);const Z=u($,E);for(let ae=0;ae<Z.length;++ae){const M=Z[ae];f.push(L+M)}v=S+(v.length>0?" "+v:v)}return v},CF=(...e)=>{let n=0,i,r,u="";for(;n<e.length;)(i=e[n++])&&(r=bC(i))&&(u&&(u+=" "),u+=r);return u},bC=e=>{if(typeof e=="string")return e;let n,i="";for(let r=0;r<e.length;r++)e[r]&&(n=bC(e[r]))&&(i&&(i+=" "),i+=n);return i},NF=(e,...n)=>{let i,r,u,h;const f=v=>{const x=n.reduce((S,k)=>k(S),e());return i=kF(x),r=i.cache.get,u=i.cache.set,h=b,b(v)},b=v=>{const x=r(v);if(x)return x;const S=AF(v,i);return u(v,S),S};return h=f,(...v)=>h(CF(...v))},_F=[],pn=e=>{const n=i=>i[e]||_F;return n.isThemeGetter=!0,n},vC=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,xC=/^\((?:(\w[\w-]*):)?(.+)\)$/i,TF=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,EF=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,RF=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,DF=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,zF=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,IF=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Ss=e=>TF.test(e),at=e=>!!e&&!Number.isNaN(Number(e)),ks=e=>!!e&&Number.isInteger(Number(e)),Af=e=>e.endsWith("%")&&at(e.slice(0,-1)),Ii=e=>EF.test(e),wC=()=>!0,OF=e=>RF.test(e)&&!DF.test(e),p1=()=>!1,qF=e=>zF.test(e),PF=e=>IF.test(e),MF=e=>!Ce(e)&&!_e(e),BF=e=>Ps(e,jC,p1),Ce=e=>vC.test(e),yo=e=>Ps(e,AC,OF),mS=e=>Ps(e,QF,at),LF=e=>Ps(e,NC,wC),$F=e=>Ps(e,CC,p1),pS=e=>Ps(e,SC,p1),VF=e=>Ps(e,kC,PF),gd=e=>Ps(e,_C,qF),_e=e=>xC.test(e),cc=e=>Po(e,AC),UF=e=>Po(e,CC),hS=e=>Po(e,SC),GF=e=>Po(e,jC),KF=e=>Po(e,kC),yd=e=>Po(e,_C,!0),HF=e=>Po(e,NC,!0),Ps=(e,n,i)=>{const r=vC.exec(e);return r?r[1]?n(r[1]):i(r[2]):!1},Po=(e,n,i=!1)=>{const r=xC.exec(e);return r?r[1]?n(r[1]):i:!1},SC=e=>e==="position"||e==="percentage",kC=e=>e==="image"||e==="url",jC=e=>e==="length"||e==="size"||e==="bg-size",AC=e=>e==="length",QF=e=>e==="number",CC=e=>e==="family-name",NC=e=>e==="number"||e==="weight",_C=e=>e==="shadow",FF=()=>{const e=pn("color"),n=pn("font"),i=pn("text"),r=pn("font-weight"),u=pn("tracking"),h=pn("leading"),f=pn("breakpoint"),b=pn("container"),v=pn("spacing"),x=pn("radius"),S=pn("shadow"),k=pn("inset-shadow"),T=pn("text-shadow"),N=pn("drop-shadow"),I=pn("blur"),P=pn("perspective"),E=pn("aspect"),$=pn("ease"),ee=pn("animate"),L=()=>["auto","avoid","all","avoid-page","page","left","right","column"],F=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],Z=()=>[...F(),_e,Ce],ae=()=>["auto","hidden","clip","visible","scroll"],M=()=>["auto","contain","none"],Y=()=>[_e,Ce,v],ue=()=>[Ss,"full","auto",...Y()],Xe=()=>[ks,"none","subgrid",_e,Ce],nt=()=>["auto",{span:["full",ks,_e,Ce]},ks,_e,Ce],Ge=()=>[ks,"auto",_e,Ce],Pe=()=>["auto","min","max","fr",_e,Ce],Se=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],Ve=()=>["start","end","center","stretch","center-safe","end-safe"],q=()=>["auto",...Y()],X=()=>[Ss,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...Y()],ve=()=>[Ss,"screen","full","dvw","lvw","svw","min","max","fit",...Y()],ke=()=>[Ss,"screen","full","lh","dvh","lvh","svh","min","max","fit",...Y()],J=()=>[e,_e,Ce],Ne=()=>[...F(),hS,pS,{position:[_e,Ce]}],Me=()=>["no-repeat",{repeat:["","x","y","space","round"]}],xe=()=>["auto","cover","contain",GF,BF,{size:[_e,Ce]}],le=()=>[Af,cc,yo],re=()=>["","none","full",x,_e,Ce],H=()=>["",at,cc,yo],pe=()=>["solid","dashed","dotted","double"],ze=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],je=()=>[at,Af,hS,pS],it=()=>["","none",I,_e,Ce],Ue=()=>["none",at,_e,Ce],jt=()=>["none",at,_e,Ce],He=()=>[at,_e,Ce],me=()=>[Ss,"full",...Y()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Ii],breakpoint:[Ii],color:[wC],container:[Ii],"drop-shadow":[Ii],ease:["in","out","in-out"],font:[MF],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Ii],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Ii],shadow:[Ii],spacing:["px",at],text:[Ii],"text-shadow":[Ii],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Ss,Ce,_e,E]}],container:["container"],columns:[{columns:[at,Ce,_e,b]}],"break-after":[{"break-after":L()}],"break-before":[{"break-before":L()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:Z()}],overflow:[{overflow:ae()}],"overflow-x":[{"overflow-x":ae()}],"overflow-y":[{"overflow-y":ae()}],overscroll:[{overscroll:M()}],"overscroll-x":[{"overscroll-x":M()}],"overscroll-y":[{"overscroll-y":M()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:ue()}],"inset-x":[{"inset-x":ue()}],"inset-y":[{"inset-y":ue()}],start:[{"inset-s":ue(),start:ue()}],end:[{"inset-e":ue(),end:ue()}],"inset-bs":[{"inset-bs":ue()}],"inset-be":[{"inset-be":ue()}],top:[{top:ue()}],right:[{right:ue()}],bottom:[{bottom:ue()}],left:[{left:ue()}],visibility:["visible","invisible","collapse"],z:[{z:[ks,"auto",_e,Ce]}],basis:[{basis:[Ss,"full","auto",b,...Y()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[at,Ss,"auto","initial","none",Ce]}],grow:[{grow:["",at,_e,Ce]}],shrink:[{shrink:["",at,_e,Ce]}],order:[{order:[ks,"first","last","none",_e,Ce]}],"grid-cols":[{"grid-cols":Xe()}],"col-start-end":[{col:nt()}],"col-start":[{"col-start":Ge()}],"col-end":[{"col-end":Ge()}],"grid-rows":[{"grid-rows":Xe()}],"row-start-end":[{row:nt()}],"row-start":[{"row-start":Ge()}],"row-end":[{"row-end":Ge()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":Pe()}],"auto-rows":[{"auto-rows":Pe()}],gap:[{gap:Y()}],"gap-x":[{"gap-x":Y()}],"gap-y":[{"gap-y":Y()}],"justify-content":[{justify:[...Se(),"normal"]}],"justify-items":[{"justify-items":[...Ve(),"normal"]}],"justify-self":[{"justify-self":["auto",...Ve()]}],"align-content":[{content:["normal",...Se()]}],"align-items":[{items:[...Ve(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...Ve(),{baseline:["","last"]}]}],"place-content":[{"place-content":Se()}],"place-items":[{"place-items":[...Ve(),"baseline"]}],"place-self":[{"place-self":["auto",...Ve()]}],p:[{p:Y()}],px:[{px:Y()}],py:[{py:Y()}],ps:[{ps:Y()}],pe:[{pe:Y()}],pbs:[{pbs:Y()}],pbe:[{pbe:Y()}],pt:[{pt:Y()}],pr:[{pr:Y()}],pb:[{pb:Y()}],pl:[{pl:Y()}],m:[{m:q()}],mx:[{mx:q()}],my:[{my:q()}],ms:[{ms:q()}],me:[{me:q()}],mbs:[{mbs:q()}],mbe:[{mbe:q()}],mt:[{mt:q()}],mr:[{mr:q()}],mb:[{mb:q()}],ml:[{ml:q()}],"space-x":[{"space-x":Y()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":Y()}],"space-y-reverse":["space-y-reverse"],size:[{size:X()}],"inline-size":[{inline:["auto",...ve()]}],"min-inline-size":[{"min-inline":["auto",...ve()]}],"max-inline-size":[{"max-inline":["none",...ve()]}],"block-size":[{block:["auto",...ke()]}],"min-block-size":[{"min-block":["auto",...ke()]}],"max-block-size":[{"max-block":["none",...ke()]}],w:[{w:[b,"screen",...X()]}],"min-w":[{"min-w":[b,"screen","none",...X()]}],"max-w":[{"max-w":[b,"screen","none","prose",{screen:[f]},...X()]}],h:[{h:["screen","lh",...X()]}],"min-h":[{"min-h":["screen","lh","none",...X()]}],"max-h":[{"max-h":["screen","lh",...X()]}],"font-size":[{text:["base",i,cc,yo]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,HF,LF]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Af,Ce]}],"font-family":[{font:[UF,$F,n]}],"font-features":[{"font-features":[Ce]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[u,_e,Ce]}],"line-clamp":[{"line-clamp":[at,"none",_e,mS]}],leading:[{leading:[h,...Y()]}],"list-image":[{"list-image":["none",_e,Ce]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",_e,Ce]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:J()}],"text-color":[{text:J()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...pe(),"wavy"]}],"text-decoration-thickness":[{decoration:[at,"from-font","auto",_e,yo]}],"text-decoration-color":[{decoration:J()}],"underline-offset":[{"underline-offset":[at,"auto",_e,Ce]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:Y()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",_e,Ce]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",_e,Ce]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:Ne()}],"bg-repeat":[{bg:Me()}],"bg-size":[{bg:xe()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},ks,_e,Ce],radial:["",_e,Ce],conic:[ks,_e,Ce]},KF,VF]}],"bg-color":[{bg:J()}],"gradient-from-pos":[{from:le()}],"gradient-via-pos":[{via:le()}],"gradient-to-pos":[{to:le()}],"gradient-from":[{from:J()}],"gradient-via":[{via:J()}],"gradient-to":[{to:J()}],rounded:[{rounded:re()}],"rounded-s":[{"rounded-s":re()}],"rounded-e":[{"rounded-e":re()}],"rounded-t":[{"rounded-t":re()}],"rounded-r":[{"rounded-r":re()}],"rounded-b":[{"rounded-b":re()}],"rounded-l":[{"rounded-l":re()}],"rounded-ss":[{"rounded-ss":re()}],"rounded-se":[{"rounded-se":re()}],"rounded-ee":[{"rounded-ee":re()}],"rounded-es":[{"rounded-es":re()}],"rounded-tl":[{"rounded-tl":re()}],"rounded-tr":[{"rounded-tr":re()}],"rounded-br":[{"rounded-br":re()}],"rounded-bl":[{"rounded-bl":re()}],"border-w":[{border:H()}],"border-w-x":[{"border-x":H()}],"border-w-y":[{"border-y":H()}],"border-w-s":[{"border-s":H()}],"border-w-e":[{"border-e":H()}],"border-w-bs":[{"border-bs":H()}],"border-w-be":[{"border-be":H()}],"border-w-t":[{"border-t":H()}],"border-w-r":[{"border-r":H()}],"border-w-b":[{"border-b":H()}],"border-w-l":[{"border-l":H()}],"divide-x":[{"divide-x":H()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":H()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...pe(),"hidden","none"]}],"divide-style":[{divide:[...pe(),"hidden","none"]}],"border-color":[{border:J()}],"border-color-x":[{"border-x":J()}],"border-color-y":[{"border-y":J()}],"border-color-s":[{"border-s":J()}],"border-color-e":[{"border-e":J()}],"border-color-bs":[{"border-bs":J()}],"border-color-be":[{"border-be":J()}],"border-color-t":[{"border-t":J()}],"border-color-r":[{"border-r":J()}],"border-color-b":[{"border-b":J()}],"border-color-l":[{"border-l":J()}],"divide-color":[{divide:J()}],"outline-style":[{outline:[...pe(),"none","hidden"]}],"outline-offset":[{"outline-offset":[at,_e,Ce]}],"outline-w":[{outline:["",at,cc,yo]}],"outline-color":[{outline:J()}],shadow:[{shadow:["","none",S,yd,gd]}],"shadow-color":[{shadow:J()}],"inset-shadow":[{"inset-shadow":["none",k,yd,gd]}],"inset-shadow-color":[{"inset-shadow":J()}],"ring-w":[{ring:H()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:J()}],"ring-offset-w":[{"ring-offset":[at,yo]}],"ring-offset-color":[{"ring-offset":J()}],"inset-ring-w":[{"inset-ring":H()}],"inset-ring-color":[{"inset-ring":J()}],"text-shadow":[{"text-shadow":["none",T,yd,gd]}],"text-shadow-color":[{"text-shadow":J()}],opacity:[{opacity:[at,_e,Ce]}],"mix-blend":[{"mix-blend":[...ze(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":ze()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[at]}],"mask-image-linear-from-pos":[{"mask-linear-from":je()}],"mask-image-linear-to-pos":[{"mask-linear-to":je()}],"mask-image-linear-from-color":[{"mask-linear-from":J()}],"mask-image-linear-to-color":[{"mask-linear-to":J()}],"mask-image-t-from-pos":[{"mask-t-from":je()}],"mask-image-t-to-pos":[{"mask-t-to":je()}],"mask-image-t-from-color":[{"mask-t-from":J()}],"mask-image-t-to-color":[{"mask-t-to":J()}],"mask-image-r-from-pos":[{"mask-r-from":je()}],"mask-image-r-to-pos":[{"mask-r-to":je()}],"mask-image-r-from-color":[{"mask-r-from":J()}],"mask-image-r-to-color":[{"mask-r-to":J()}],"mask-image-b-from-pos":[{"mask-b-from":je()}],"mask-image-b-to-pos":[{"mask-b-to":je()}],"mask-image-b-from-color":[{"mask-b-from":J()}],"mask-image-b-to-color":[{"mask-b-to":J()}],"mask-image-l-from-pos":[{"mask-l-from":je()}],"mask-image-l-to-pos":[{"mask-l-to":je()}],"mask-image-l-from-color":[{"mask-l-from":J()}],"mask-image-l-to-color":[{"mask-l-to":J()}],"mask-image-x-from-pos":[{"mask-x-from":je()}],"mask-image-x-to-pos":[{"mask-x-to":je()}],"mask-image-x-from-color":[{"mask-x-from":J()}],"mask-image-x-to-color":[{"mask-x-to":J()}],"mask-image-y-from-pos":[{"mask-y-from":je()}],"mask-image-y-to-pos":[{"mask-y-to":je()}],"mask-image-y-from-color":[{"mask-y-from":J()}],"mask-image-y-to-color":[{"mask-y-to":J()}],"mask-image-radial":[{"mask-radial":[_e,Ce]}],"mask-image-radial-from-pos":[{"mask-radial-from":je()}],"mask-image-radial-to-pos":[{"mask-radial-to":je()}],"mask-image-radial-from-color":[{"mask-radial-from":J()}],"mask-image-radial-to-color":[{"mask-radial-to":J()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":F()}],"mask-image-conic-pos":[{"mask-conic":[at]}],"mask-image-conic-from-pos":[{"mask-conic-from":je()}],"mask-image-conic-to-pos":[{"mask-conic-to":je()}],"mask-image-conic-from-color":[{"mask-conic-from":J()}],"mask-image-conic-to-color":[{"mask-conic-to":J()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:Ne()}],"mask-repeat":[{mask:Me()}],"mask-size":[{mask:xe()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",_e,Ce]}],filter:[{filter:["","none",_e,Ce]}],blur:[{blur:it()}],brightness:[{brightness:[at,_e,Ce]}],contrast:[{contrast:[at,_e,Ce]}],"drop-shadow":[{"drop-shadow":["","none",N,yd,gd]}],"drop-shadow-color":[{"drop-shadow":J()}],grayscale:[{grayscale:["",at,_e,Ce]}],"hue-rotate":[{"hue-rotate":[at,_e,Ce]}],invert:[{invert:["",at,_e,Ce]}],saturate:[{saturate:[at,_e,Ce]}],sepia:[{sepia:["",at,_e,Ce]}],"backdrop-filter":[{"backdrop-filter":["","none",_e,Ce]}],"backdrop-blur":[{"backdrop-blur":it()}],"backdrop-brightness":[{"backdrop-brightness":[at,_e,Ce]}],"backdrop-contrast":[{"backdrop-contrast":[at,_e,Ce]}],"backdrop-grayscale":[{"backdrop-grayscale":["",at,_e,Ce]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[at,_e,Ce]}],"backdrop-invert":[{"backdrop-invert":["",at,_e,Ce]}],"backdrop-opacity":[{"backdrop-opacity":[at,_e,Ce]}],"backdrop-saturate":[{"backdrop-saturate":[at,_e,Ce]}],"backdrop-sepia":[{"backdrop-sepia":["",at,_e,Ce]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":Y()}],"border-spacing-x":[{"border-spacing-x":Y()}],"border-spacing-y":[{"border-spacing-y":Y()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",_e,Ce]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[at,"initial",_e,Ce]}],ease:[{ease:["linear","initial",$,_e,Ce]}],delay:[{delay:[at,_e,Ce]}],animate:[{animate:["none",ee,_e,Ce]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[P,_e,Ce]}],"perspective-origin":[{"perspective-origin":Z()}],rotate:[{rotate:Ue()}],"rotate-x":[{"rotate-x":Ue()}],"rotate-y":[{"rotate-y":Ue()}],"rotate-z":[{"rotate-z":Ue()}],scale:[{scale:jt()}],"scale-x":[{"scale-x":jt()}],"scale-y":[{"scale-y":jt()}],"scale-z":[{"scale-z":jt()}],"scale-3d":["scale-3d"],skew:[{skew:He()}],"skew-x":[{"skew-x":He()}],"skew-y":[{"skew-y":He()}],transform:[{transform:[_e,Ce,"","none","gpu","cpu"]}],"transform-origin":[{origin:Z()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:me()}],"translate-x":[{"translate-x":me()}],"translate-y":[{"translate-y":me()}],"translate-z":[{"translate-z":me()}],"translate-none":["translate-none"],accent:[{accent:J()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:J()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",_e,Ce]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":Y()}],"scroll-mx":[{"scroll-mx":Y()}],"scroll-my":[{"scroll-my":Y()}],"scroll-ms":[{"scroll-ms":Y()}],"scroll-me":[{"scroll-me":Y()}],"scroll-mbs":[{"scroll-mbs":Y()}],"scroll-mbe":[{"scroll-mbe":Y()}],"scroll-mt":[{"scroll-mt":Y()}],"scroll-mr":[{"scroll-mr":Y()}],"scroll-mb":[{"scroll-mb":Y()}],"scroll-ml":[{"scroll-ml":Y()}],"scroll-p":[{"scroll-p":Y()}],"scroll-px":[{"scroll-px":Y()}],"scroll-py":[{"scroll-py":Y()}],"scroll-ps":[{"scroll-ps":Y()}],"scroll-pe":[{"scroll-pe":Y()}],"scroll-pbs":[{"scroll-pbs":Y()}],"scroll-pbe":[{"scroll-pbe":Y()}],"scroll-pt":[{"scroll-pt":Y()}],"scroll-pr":[{"scroll-pr":Y()}],"scroll-pb":[{"scroll-pb":Y()}],"scroll-pl":[{"scroll-pl":Y()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",_e,Ce]}],fill:[{fill:["none",...J()]}],"stroke-w":[{stroke:[at,cc,yo,mS]}],stroke:[{stroke:["none",...J()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},ZF=NF(FF);function Pa(...e){return ZF(WS(e))}const YF=hC("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-mono-400 focus-visible:ring-offset-2 focus-visible:ring-offset-overlay-scrim disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-accent text-on-inverse hover:bg-mono-200",secondary:"border border-base bg-bg text-heading hover:bg-bg-elevated",ghost:"text-secondary hover:bg-bg-elevated hover:text-primary",outline:"border border-base bg-transparent text-heading hover:bg-bg-elevated",destructive:"bg-negative-600 text-on-emphasis hover:bg-negative-700"},size:{default:"h-10 px-4 md:h-9",sm:"h-9 px-3 text-xs md:h-8",icon:"size-10 md:size-9"}},defaultVariants:{variant:"default",size:"default"}}),ce=C.forwardRef(({className:e,variant:n,size:i,asChild:r=!1,...u},h)=>{const f=r?f5:"button";return l.jsx(f,{ref:h,className:Pa(YF({variant:n,size:i,className:e})),...u})});ce.displayName="Button";const XF=hC("inline-flex items-center rounded-md border px-2 py-0.5 text-[11px] font-medium tracking-wide",{variants:{variant:{neutral:"border-base bg-bg text-neutral",success:"border-positive bg-positive-soft text-positive",warning:"border-caution-500/25 bg-caution-soft text-caution",destructive:"border-negative bg-negative-soft text-negative"}},defaultVariants:{variant:"neutral"}});function TC({className:e,variant:n,...i}){return l.jsx("div",{className:Pa(XF({variant:n}),e),...i})}const JF=220;function fS({compact:e=!1,version:n,updateAvailable:i,onDismissUpdate:r}){const u=!e&&n&&n!=="unknown",[h,f]=C.useState(!1),b=!e&&i&&r,v=()=>{f(!0),window.setTimeout(()=>{r?.(),f(!1)},JF)};return e?l.jsxs(We,{to:"/",className:"brand-lockup brand-lockup-compact","aria-label":"Canonry home",children:[l.jsx("img",{className:"brand-icon",src:"./favicon.svg",alt:"","aria-hidden":"true"}),l.jsx("span",{className:"brand-copy",children:l.jsx("span",{className:"brand-mark",children:"Canonry"})})]}):l.jsxs("div",{className:"brand-lockup brand-lockup-wrapper",children:[l.jsx(We,{to:"/",className:"brand-icon-link","aria-label":"Canonry home",tabIndex:-1,children:l.jsx("img",{className:"brand-icon",src:"./favicon.svg",alt:"","aria-hidden":"true"})}),l.jsxs("div",{className:"brand-copy",children:[l.jsx(We,{to:"/",className:"brand-mark",children:"Canonry"}),!b&&u?l.jsxs("span",{className:"brand-version",children:["v",n]}):null]}),b?l.jsxs("span",{className:`brand-update-bubble ${h?"brand-update-bubble-closing":""}`,role:"status","aria-live":"polite",children:[l.jsxs("a",{className:"brand-update-bubble-link",href:i.url,target:"_blank",rel:"noopener noreferrer",title:`Open release: ${i.upgradeCommand}`,"aria-label":`New version v${i.latest} available — open release page`,children:[l.jsxs("span",{className:"brand-update-bubble-from",children:["v",i.current]}),l.jsx(wc,{className:"brand-update-bubble-arrow size-3","aria-hidden":"true"}),l.jsxs("span",{className:"brand-update-bubble-to",children:["v",i.latest]})]}),l.jsx("button",{type:"button",className:"brand-update-bubble-dismiss",onClick:v,"aria-label":`Dismiss update notification for v${i.latest}`,children:l.jsx(Hr,{className:"size-3","aria-hidden":"true"})})]}):null]})}function WF({provider:e}){const n={gemini:"border-blue-800/50 bg-blue-950/40 text-blue-300",openai:"border-green-800/50 bg-green-950/40 text-green-300",claude:"border-amber-800/50 bg-amber-950/40 text-amber-300",perplexity:"border-teal-800/50 bg-teal-950/40 text-teal-300",muse:"border-indigo-800/50 bg-indigo-950/40 text-indigo-300",local:"border-purple-800/50 bg-purple-950/40 text-purple-300"},r=Object.hasOwn(n,e)?`provider-badge--${e} ${n[e]}`:"border-zinc-700 bg-zinc-800 text-zinc-300";return l.jsx("span",{className:`inline-flex items-center rounded-full border px-2 py-0.5 text-[10px] font-medium uppercase tracking-wide ${r}`,children:e})}function xn({tone:e,children:n,...i}){const r=e==="positive"?"success":e==="caution"?"warning":e==="negative"?"destructive":"neutral";return l.jsx(TC,{variant:r,...i,children:n})}function h1({status:e}){return l.jsx(xn,{tone:uC(e),children:ZK(e)})}const hg=JS,eZ=ZS,EC=C.forwardRef(({className:e,...n},i)=>l.jsx(Ag,{ref:i,className:Pa("fixed inset-0 z-50 bg-overlay-scrim/70 backdrop-blur-sm",e),...n}));EC.displayName=Ag.displayName;const tZ=400,nZ=1200,aZ=720,Yd=C.forwardRef(({className:e,children:n,...i},r)=>{const[u,h]=C.useState(aZ),f=C.useRef(!1),b=C.useRef(0),v=C.useRef(0),x=C.useCallback(T=>{f.current=!0,b.current=T.clientX,v.current=u,T.target.setPointerCapture(T.pointerId),T.preventDefault()},[u]),S=C.useCallback(T=>{if(!f.current)return;const N=b.current-T.clientX,I=Math.min(nZ,Math.max(tZ,v.current+N));h(I)},[]),k=C.useCallback(()=>{f.current=!1},[]);return l.jsxs(eZ,{children:[l.jsx(EC,{}),l.jsxs(Cg,{ref:r,className:Pa("fixed z-50 flex flex-col bg-bg px-5 py-4 shadow-2xl overflow-hidden","max-md:inset-x-0 max-md:bottom-0 max-md:top-auto max-md:max-h-[88vh] max-md:rounded-t-2xl max-md:border-t","md:inset-y-0 md:right-0 md:h-full md:border-l","border-base",e),style:{width:`min(${u}px, 100vw)`},...i,children:[l.jsx("div",{className:"absolute inset-y-0 left-0 w-1.5 cursor-col-resize hover:bg-mono-700/50 active:bg-mono-600/50 transition-colors max-md:hidden",onPointerDown:x,onPointerMove:S,onPointerUp:k}),n,l.jsxs(YS,{className:"absolute right-4 top-4 inline-flex size-8 items-center justify-center rounded-md text-muted transition hover:bg-bg-elevated hover:text-heading focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-mono-400",children:[l.jsx(Hr,{className:"size-4"}),l.jsx("span",{className:"sr-only",children:"Close"})]})]})]})});Yd.displayName=Cg.displayName;const fg=({className:e,...n})=>l.jsx("div",{className:Pa("flex flex-col gap-1.5 pr-10",e),...n}),Xd=C.forwardRef(({className:e,...n},i)=>l.jsx(Ng,{ref:i,className:Pa("text-lg font-medium text-primary",e),...n}));Xd.displayName=Ng.displayName;const Jd=C.forwardRef(({className:e,...n},i)=>l.jsx(XS,{ref:i,className:Pa("text-sm text-muted",e),...n}));Jd.displayName=XS.displayName;function bd({title:e,subtitle:n,children:i,open:r,onClose:u}){return l.jsx(hg,{open:r,onOpenChange:h=>h?void 0:u(),children:l.jsxs(Yd,{children:[l.jsxs(fg,{className:"drawer-head",children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:n}),l.jsx(Xd,{id:"drawer-title",children:e}),l.jsx(Jd,{className:"sr-only",children:n})]}),l.jsx("div",{className:"drawer-body",children:i})]})})}function Ea({text:e,placement:n="top"}){const[i,r]=C.useState(null),u=C.useRef(null),h=C.useRef(null),f=C.useRef(!1),b=C.useCallback(()=>{if(!u.current)return;const S=u.current.getBoundingClientRect(),k=S.left+S.width/2,T=Math.min(224,window.innerWidth-16)/2;r({top:n==="bottom"?S.bottom:S.top,left:n==="bottom"?Math.max(T+8,Math.min(k,window.innerWidth-T-8)):k})},[n]);C.useLayoutEffect(()=>{if(n!=="bottom"||!i||!h.current)return;const S=h.current.getBoundingClientRect().bottom-window.innerHeight+8;if(S<=0)return;const k=Math.max(0,i.top-S);k!==i.top&&r({...i,top:k})},[n,i]);const v=C.useCallback(()=>r(null),[]),x=C.useCallback(()=>{i===null?b():v()},[i,b,v]);return l.jsxs("span",{className:"info-tooltip-wrapper",onMouseEnter:b,onMouseLeave:v,children:[l.jsx("button",{ref:u,type:"button",className:"info-tooltip-trigger","aria-label":e,"aria-expanded":i!==null,onFocus:b,onBlur:v,onPointerDown:()=>{f.current=i!==null&&u.current?.ownerDocument.activeElement===u.current},onClick:S=>{S.detail===0?x():f.current?v():b()},onKeyDown:S=>{S.key==="Escape"&&v()},children:l.jsxs("svg",{className:"info-tooltip-icon",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[l.jsx("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"1.5"}),l.jsx("path",{d:"M8 7v4M8 5.5v0",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]})}),i!==null&&l5.createPortal(l.jsx("span",{ref:h,"aria-hidden":"true",style:{position:"fixed",top:i.top,left:i.left,transform:n==="bottom"?"translateX(-50%) translateY(8px)":"translateX(-50%) translateY(calc(-100% - 8px))",zIndex:9999,pointerEvents:"none",width:n==="bottom"?"min(14rem, calc(100vw - 1rem))":"14rem",padding:"0.5rem 0.75rem",fontSize:n==="bottom"?"13px":"11px",fontWeight:400,textTransform:"none",letterSpacing:"normal",lineHeight:n==="bottom"?"18px":"1rem",color:"var(--color-neutral-text)",backgroundColor:"var(--color-bg-elevated)",border:"1px solid color-mix(in oklab, var(--color-border-strong) 60%, transparent)",borderRadius:"0.5rem",boxShadow:"0 10px 15px -3px var(--color-shadow-tooltip), 0 4px 6px -4px var(--color-shadow-tooltip)"},children:e}),document.body)]})}function iZ(e){const n=(e??"").trim();return n&&(n.startsWith("/")||/^https?:\/\//i.test(n)||/^mailto:/i.test(n))?n:null}function gg({url:e,title:n}){const i=iZ(e),r=i&&/^https?:\/\//i.test(i)?i:null;return l.jsxs("span",{className:"block min-w-0 text-sm leading-6 [overflow-wrap:anywhere]",children:[n&&n!==e?l.jsxs(l.Fragment,{children:[l.jsx("span",{className:"mb-1 block font-medium text-heading",children:n})," "]}):null,r?l.jsx("a",{href:r,target:"_blank",rel:"noopener noreferrer",className:"text-link underline underline-offset-2 hover:text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-mono-400",children:e}):l.jsx("span",{className:"text-secondary",children:e})]})}const sZ=/[\s\-_]+/;function oZ(e){const n=e.split(sZ).filter(Boolean);return n.length===0?null:n.map(i=>i.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join("[\\s\\-_]*")}function gS(e,n){const i=rZ(n),r=e.split(/(\*\*[^*]+\*\*)/).filter(Boolean).map(x=>x.startsWith("**")&&x.endsWith("**")?{type:"bold",value:x.slice(2,-2)}:{type:"text",value:x}),u=i.flatMap(x=>x.terms).filter(x=>x.trim().length>1);if(u.length===0)return r.map((x,S)=>x.type==="bold"?jr.createElement("strong",{key:`b-${S}`,className:"text-strong font-semibold"},x.value):x.value).filter(Boolean);const f=[...u].sort((x,S)=>S.length-x.length).map(oZ).filter(x=>!!x);if(f.length===0)return r.map((x,S)=>x.type==="bold"?jr.createElement("strong",{key:`b-${S}`,className:"text-strong font-semibold"},x.value):x.value).filter(Boolean);const b=new RegExp(`(${f.join("|")})`,"gi"),v=new Map;for(const x of i)for(const S of x.terms){const k=Qa(S);k&&!v.has(k)&&v.set(k,x.className)}return r.flatMap((x,S)=>x.value.split(b).map((T,N)=>{if(!T)return null;if(N%2===1){const P=v.get(Qa(T))??"answer-highlight";return x.type==="bold"?jr.createElement("mark",{key:`hl-${S}-${N}`,className:P},jr.createElement("strong",{className:"text-strong font-semibold"},T)):jr.createElement("mark",{key:`hl-${S}-${N}`,className:P},T)}return x.type==="bold"?jr.createElement("strong",{key:`b-${S}-${N}`,className:"text-strong font-semibold"},T):T})).filter(Boolean)}function rZ(e){return e.length===0?[]:typeof e[0]=="string"?[{terms:e,className:"answer-highlight"}]:e}function Cf(e,n){return{citedCompetitorDomains:[...e.citedCompetitorDomains??n?.citedCompetitorDomains??[]],mentionedCompetitorDomains:[...e.mentionedCompetitorDomains??n?.mentionedCompetitorDomains??[]]}}function Nf(e,n){switch(e){case"new":return"First observation";case"emerging":return"First mention";case"lost":return"Lost since last run";default:return n==="mentioned"||n==="visible"?"Mentioned in latest run":n==="pending"?"Awaiting first run":"Not mentioned in latest run"}}function lZ({evidence:e,project:n,onClose:i}){const[r,u]=C.useState(!1),[h,f]=C.useState("mentions"),[b,v]=C.useState(-1),[x,S]=C.useState(null),[k,T]=C.useState(!1),[N,I]=C.useState({}),P=j2(n.project),E=new Set(P.map(Md)),$=e.runHistory,ee=$.length>1,[L,F]=C.useState(null),Z=C.useRef(!1);C.useEffect(()=>{if(Z.current||e.answerSnippet&&(e.visibilityState!=null||e.answerMentioned!=null))return;const le=$.at(-1);le&&(Z.current=!0,rg(le.runId).then(re=>{const H=re.snapshots?.find(pe=>pe.query===e.query&&pe.provider===e.provider);H&&F({citationState:H.citationState,answerMentioned:H.answerMentioned,visibilityState:H.visibilityState,visibilityTransition:le.visibilityTransition,provider:H.provider,model:H.model??e.model,answerSnippet:H.answerText??e.answerSnippet,citedDomains:H.citedDomains??e.citedDomains,...Cf(H,e),recommendedCompetitors:H.recommendedCompetitors??e.recommendedCompetitors??[],matchedTerms:H.matchedTerms??e.matchedTerms??[],groundingSources:H.groundingSources??e.groundingSources,searchQueries:H.searchQueries,evidenceUrls:H.citedUrls??[],changeLabel:e.visibilityChangeLabel??e.changeLabel,summary:e.summary})}).catch(()=>{}))},[e,$]);const ae=b>=0&&x!==null,M=ae?x:L||{citationState:e.citationState,answerMentioned:e.answerMentioned,visibilityState:e.visibilityState,visibilityTransition:$.at(-1)?.visibilityTransition,provider:e.provider,model:e.model,answerSnippet:e.answerSnippet,citedDomains:e.citedDomains,...Cf(e),recommendedCompetitors:e.recommendedCompetitors??[],matchedTerms:e.matchedTerms??[],groundingSources:e.groundingSources,searchQueries:e.searchQueries??[],evidenceUrls:e.evidenceUrls,changeLabel:e.visibilityChangeLabel??e.changeLabel,summary:e.summary},Y=M.visibilityState==="pending"||M.citationState==="pending",ue=Y?!1:M.visibilityState!=null?M.visibilityState==="visible":M.answerMentioned!=null?M.answerMentioned:M.citationState===fc.cited||M.citationState==="emerging",Xe=M.answerMentioned!=null||M.visibilityState!=null||M.mentionedCompetitorDomains.length>0||M.recommendedCompetitors.length>0,nt=M.citedDomains.length>0||M.citedCompetitorDomains.length>0||M.groundingSources.length>0||M.evidenceUrls.length>0,Ge=n.project.displayName||n.project.name,Pe=[...P.map(Md),Ge,Ge.split(" ").slice(0,2).join(" "),...M.matchedTerms].filter(le=>le.trim().length>2),Se=[...M.mentionedCompetitorDomains.flatMap(le=>{const re=Qg(le);return re.length>=4?[re]:[]}),...M.recommendedCompetitors].filter(le=>le.trim().length>2),Ve=[{terms:Pe,className:"answer-highlight-brand"},...Se.length>0?[{terms:Se,className:"answer-highlight-competitor"}]:[]],q=Y?"pending":M.visibilityTransition==="lost"?"lost":ue?"mentioned":"not-mentioned",X=C.useRef(0),ve=C.useCallback(async le=>{const re=++X.current;if(le===-1||le===$.length-1){v(-1),S(null),u(!1);return}v(le),u(!1);const H=$[le],pe=`${H.runId}::${e.query}::${e.provider}`;if(N[pe]){S(N[pe]);return}T(!0);try{const ze=await rg(H.runId);if(re!==X.current)return;const je=ze.snapshots?.find(Ue=>Ue.query===e.query&&Ue.provider===e.provider)??ze.snapshots?.find(Ue=>Ue.query===e.query),it=je?{citationState:je.citationState,answerMentioned:je.answerMentioned,visibilityState:je.visibilityState,visibilityTransition:H.visibilityTransition,provider:je.provider,model:je.model??null,answerSnippet:je.answerText??"",citedDomains:je.citedDomains,...Cf(je),recommendedCompetitors:je.recommendedCompetitors??[],matchedTerms:je.matchedTerms??[],groundingSources:je.groundingSources,searchQueries:je.searchQueries,evidenceUrls:je.citedUrls??[],changeLabel:Nf(H.mentionTransition??H.visibilityTransition,H.mentionState??H.visibilityState),summary:""}:{citationState:H.citationState,answerMentioned:H.answerMentioned,visibilityState:H.visibilityState,visibilityTransition:H.visibilityTransition,provider:e.provider,model:H.model??null,answerSnippet:"",citedDomains:[],citedCompetitorDomains:[],mentionedCompetitorDomains:[],recommendedCompetitors:[],matchedTerms:[],groundingSources:[],searchQueries:[],evidenceUrls:[],changeLabel:Nf(H.mentionTransition??H.visibilityTransition,H.mentionState??H.visibilityState),summary:"Snapshot data not available for this run."};I(Ue=>({...Ue,[pe]:it})),S(it)}catch{if(re!==X.current)return;S({citationState:H.citationState,answerMentioned:H.answerMentioned,visibilityState:H.visibilityState,visibilityTransition:H.visibilityTransition,provider:e.provider,model:H.model??null,answerSnippet:"",citedDomains:[],citedCompetitorDomains:[],mentionedCompetitorDomains:[],recommendedCompetitors:[],matchedTerms:[],groundingSources:[],searchQueries:[],evidenceUrls:[],changeLabel:Nf(H.mentionTransition??H.visibilityTransition,H.mentionState??H.visibilityState),summary:"Failed to load historical run data."})}finally{re===X.current&&T(!1)}},[$,e.query,e.provider,N]),J=(ae||e.historyScope!=="provider")&&M.model?`${M.provider} (${M.model}) · ${M.changeLabel.toLowerCase()}`:`${M.provider} · ${M.changeLabel.toLowerCase()}`,Ne=!ae&&e.historyScope==="provider"?[e.model?`Current model: ${e.model}`:null,e.modelsSeen&&e.modelsSeen.length>1?`History spans ${e.modelsSeen.length} models`:null].filter(Boolean).join(" · "):"",Me=ue?{label:"Mentioned in answer",title:"Your brand or domain is mentioned in this answer",meta:J}:M.visibilityTransition==="lost"?{label:"Mention lost",title:"Your brand no longer appears in this answer",meta:J}:Y?{label:"Pending",title:"Awaiting first run",meta:"No provider data yet"}:{label:"Not mentioned in answer",title:"Your brand or domain was not mentioned in this answer",meta:J},xe=()=>{if(!M.answerSnippet)return null;const le=M.answerSnippet.split(`
|
|
58
|
+
`),re=[];let H=[],pe=0;const ze=()=>{if(H.length===0)return;const je=H.join(" ").trim();je&&re.push(l.jsx("p",{className:re.length>0?"mt-2.5":"",children:gS(je,Ve)},pe++)),H=[]};for(const je of le){const it=je.trim();if(/^[-\u2013\u2014]{3,}$/.test(it)){ze(),re.push(l.jsx("hr",{className:"border-default my-3"},pe++));continue}const Ue=it.match(/^(#{1,3})\s+(\S.*)$/);if(Ue){ze();const jt=Ue[1].length,He=Ue[2].replace(/^[\p{Emoji}\p{Emoji_Component}\s]+/u,"").trim()||Ue[2],me=jt===1?"text-[13px] font-semibold text-heading mt-4 mb-1":jt===2?"text-xs font-semibold text-strong mt-3 mb-0.5":"text-xs font-medium text-neutral mt-2";re.push(l.jsx("p",{className:me,children:gS(He,Ve)},pe++));continue}if(it===""){ze();continue}H.push(it)}return ze(),re};return l.jsx(JS,{open:!0,onOpenChange:le=>{le||i()},children:l.jsxs(ZS,{children:[l.jsx(Ag,{className:"fixed inset-0 z-50 bg-overlay-scrim/80 backdrop-blur-sm"}),l.jsxs(Cg,{className:"evidence-modal","aria-describedby":void 0,children:[l.jsxs("div",{className:"evidence-modal-header",children:[l.jsxs("div",{className:"min-w-0 flex-1",children:[l.jsxs("p",{className:"eyebrow eyebrow-soft",children:[n.project.name," ","·"," ",M.provider||"All providers"]}),l.jsx(Ng,{className:"text-lg font-semibold text-primary truncate",children:e.query})]}),l.jsxs(YS,{className:"inline-flex size-8 items-center justify-center rounded-md text-muted transition hover:bg-mono-800 hover:text-heading focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-mono-400 shrink-0",children:[l.jsx(Hr,{className:"size-4"}),l.jsx("span",{className:"sr-only",children:"Close"})]})]}),ee&&l.jsxs("div",{className:"evidence-modal-timeline",children:[l.jsx("p",{className:"drawer-section-label mb-1.5",children:"Run history"}),l.jsx("div",{className:"flex items-center gap-1 overflow-x-auto pb-1",children:$.map((le,re)=>{const H=b===-1&&re===$.length-1||b===re,pe=le.visibilityState??(le.answerMentioned?"visible":"not-visible"),ze=le.visibilityTransition??pe,je=pe==="visible"?"bg-positive-400":ze==="emerging"?"bg-caution-400":ze==="lost"?"bg-negative-400":"bg-mono-600",Ue=new Date(le.createdAt).toLocaleDateString(void 0,{month:"short",day:"numeric"}),jt=!!(le.model&&re>0&&$[re-1]?.model&&$[re-1].model!==le.model);return l.jsxs("button",{type:"button",className:`evidence-run-dot ${H?"evidence-run-dot--selected":""}`,onClick:()=>{ve(re===$.length-1?-1:re)},"aria-label":[`Run ${Ue}: ${pe}`,le.model?`model ${le.model}`:null,jt?"model changed":null].filter(Boolean).join(" — "),"aria-pressed":H,children:[l.jsx("span",{className:`size-2 rounded-full ${je} ${jt?"ring-1 ring-caution-300/80 ring-offset-2 ring-offset-bg":""}`,"aria-hidden":"true"}),l.jsx("span",{className:"text-[10px] text-muted",children:Ue})]},re)})}),b>=0&&b<$.length&&l.jsxs("p",{className:"text-[11px] text-muted mt-1",children:["Viewing run from ",new Date($[b].createdAt).toLocaleString()," ","—"," ",l.jsx("span",{className:"capitalize",children:$[b].visibilityState??($[b].answerMentioned?"visible":"not-visible")}),l.jsxs("button",{type:"button",className:"text-secondary hover:text-strong ml-2",onClick:()=>{ve(-1)},children:["←"," Back to latest"]})]}),!ae&&(e.modelTransitions?.length??0)>0&&l.jsx("div",{className:"mt-2 flex flex-wrap gap-2",children:e.modelTransitions.map(le=>l.jsx("span",{className:"inline-flex items-center rounded-full border border-caution-400/30 bg-caution-400/10 px-2 py-1 text-[10px] text-caution-100",children:`${le.fromModel??"unknown"} -> ${le.toModel??"unknown"} on ${new Date(le.createdAt).toLocaleDateString()}`},`${le.runId}:${le.toModel??"unknown"}`))})]}),l.jsxs("div",{className:"evidence-modal-body",children:[k&&l.jsxs("div",{className:"md:col-span-2 flex items-center justify-center py-12 text-muted text-sm",children:["Loading historical run data","…"]}),!k&&l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"evidence-modal-main",children:[l.jsxs("div",{className:`evidence-position-hero evidence-position-hero--${q}`,children:[l.jsx("p",{className:`evidence-position-label evidence-position-label--${q}`,children:Me.label}),l.jsx("p",{className:`evidence-position-title evidence-position-title--${q}`,children:Me.title}),l.jsx("p",{className:"evidence-position-meta",children:Me.meta}),Ne&&l.jsx("p",{className:"mt-1 text-[11px] text-muted",children:Ne})]}),M.answerSnippet&&l.jsxs("div",{children:[l.jsx("p",{className:"drawer-section-label",children:"What the AI said"}),l.jsx("div",{className:`answer-snippet-block ${r?"evidence-answer-expanded":"evidence-answer-collapsed"}`,children:xe()}),M.answerSnippet.length>280&&l.jsx("button",{type:"button",className:"mt-1.5 text-xs text-muted hover:text-neutral transition-colors",onClick:()=>u(!r),children:r?"↑ Collapse":"↓ Show full answer"})]}),!M.answerSnippet&&!k&&l.jsx("div",{className:"rounded-lg border border-subtle bg-surface-subtle px-4 py-8 text-center text-faint text-sm",children:"No answer text recorded for this run"}),M.searchQueries.length>0&&l.jsxs("div",{children:[l.jsxs("div",{className:"drawer-section-label flex items-center",children:[l.jsx("span",{children:"Web searches the model ran"}),l.jsx(Ea,{text:"The search queries this AI model issued while researching your prompt. They reveal how the model reformulated your query — the phrasings worth optimizing your content for. Distinct from grounding sources (what it found) and citations (what it linked)."})]}),l.jsx("ul",{className:"grid gap-1",children:M.searchQueries.map((le,re)=>l.jsxs("li",{className:"flex items-start gap-2 text-sm text-neutral",children:[l.jsx(_g,{className:"size-3.5 mt-0.5 shrink-0 text-faint","aria-hidden":"true"}),l.jsx("span",{className:"break-words",children:le})]},`${re}-${le}`))})]}),!ae&&e.relatedTechnicalSignals.length>0&&l.jsxs("div",{children:[l.jsx("p",{className:"drawer-section-label",children:ue?"Why you're visible":"What to fix"}),l.jsx("div",{className:"action-items-list",children:e.relatedTechnicalSignals.map((le,re)=>l.jsxs("div",{className:"action-item",children:[l.jsx("svg",{className:`action-item-icon ${ue?"text-positive-400":"text-caution-400"}`,viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:ue?l.jsx("path",{d:"M3 8l3.5 3.5L13 4.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}):l.jsxs(l.Fragment,{children:[l.jsx("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"1.5"}),l.jsx("path",{d:"M8 5v3.5M8 10.5v0",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]})}),l.jsx("span",{className:"action-item-text",children:le})]},re))})]}),M.summary&&l.jsx("p",{className:"text-xs text-faint border-t border-subtle pt-3 mt-1",children:M.summary})]}),l.jsxs("div",{className:"evidence-modal-sidebar",children:[(Xe||nt)&&l.jsxs("div",{className:"sidebar-tabs",children:[l.jsx("button",{className:`sidebar-tab ${h==="mentions"?"sidebar-tab--active":""}`,onClick:()=>f("mentions"),type:"button",title:"Canonry's answer-level visibility assessment and any company names extracted from the answer text.",children:"Mentions"}),l.jsx("button",{className:`sidebar-tab ${h==="sources"?"sidebar-tab--active":""}`,onClick:()=>f("sources"),type:"button",title:"Grounding links the model used to build the answer. These are supporting sources, not the primary visibility signal.",children:"Sources"})]}),h==="mentions"&&l.jsxs(l.Fragment,{children:[l.jsxs("div",{children:[l.jsxs("div",{className:"drawer-section-label flex items-center",children:[l.jsx("span",{children:"Mention in answer"}),l.jsx(Ea,{text:"Canonry scans the AI answer for your owned domains and project name. This is independent from grounding or citation sources."})]}),l.jsxs("div",{className:`mention-status mention-status--${ue?"mentioned":"not-mentioned"}`,children:[l.jsx("span",{className:"mention-status-icon",children:Y?"…":ue?"✓":"—"}),l.jsx("span",{className:"mention-status-label",children:Y?"Pending":ue?"Mentioned":"Not mentioned"})]}),M.matchedTerms.length>0&&l.jsxs("div",{className:"mt-2",children:[l.jsx("p",{className:"text-[10px] uppercase tracking-wide text-muted mb-1.5",children:"Matched in answer"}),l.jsx("div",{className:"flex flex-wrap gap-1.5",children:M.matchedTerms.map(le=>l.jsx("span",{className:"mention-chip mention-chip--brand",children:le},le))})]}),!Y&&!ue&&M.matchedTerms.length===0&&l.jsxs("div",{className:"mt-2",children:[l.jsx("p",{className:"text-[10px] uppercase tracking-wide text-muted mb-1.5",children:"Searched for"}),l.jsx("div",{className:"flex flex-wrap gap-1.5",children:Pe.map(le=>l.jsx("span",{className:"mention-chip mention-chip--muted",children:le},le))}),l.jsx("p",{className:"text-[11px] text-faint mt-1.5",children:"None of these appear in the answer text."})]})]}),(M.recommendedCompetitors.length>0||M.mentionedCompetitorDomains.length>0)&&l.jsxs("div",{children:[l.jsxs("div",{className:"drawer-section-label flex items-center",children:[l.jsx("span",{children:"Competitors in answer"}),l.jsx(Ea,{text:"Competitors detected in the answer text. Includes tracked competitor brands and names extracted by Canonry; source-link competitors stay in the Sources tab."})]}),l.jsx("div",{className:"flex flex-wrap gap-1.5",children:(()=>{const le=M.mentionedCompetitorDomains.map(pe=>pe.replace(/^www\./,"")),re=new Set(le.map(pe=>Qa(pe.replace(/\.[^.]+$/,""))));return[...M.recommendedCompetitors.filter(pe=>!re.has(Qa(pe))),...le].map(pe=>l.jsx("span",{className:"mention-chip mention-chip--competitor",children:pe},pe))})()})]})]}),h==="sources"&&l.jsxs(l.Fragment,{children:[M.citedDomains.length>0&&l.jsxs("div",{children:[l.jsxs("div",{className:"drawer-section-label flex items-center",children:[l.jsx("span",{children:"Domains from source links"}),l.jsx(Ea,{text:"These domains were extracted from grounding or citation URLs. They are supporting-source metadata, not proof that the answer text mentioned them."})]}),l.jsx("div",{className:"citation-leaderboard",children:M.citedDomains.map((le,re)=>{const H=le.toLowerCase().replace(/^www\./,""),pe=E.has(H),ze=!pe&&M.citedCompetitorDomains.some(it=>it.toLowerCase().replace(/^www\./,"")===H),je=pe?"you":ze?"competitor":"other";return l.jsxs("div",{className:`citation-leaderboard-item citation-leaderboard-item--${je}`,children:[l.jsxs("span",{className:"citation-leaderboard-rank",children:["#",re+1]}),l.jsx("span",{className:"citation-leaderboard-domain",children:le}),pe&&l.jsx("span",{className:"citation-leaderboard-tag",children:"You"}),ze&&l.jsx("span",{className:"citation-leaderboard-tag",children:"Competitor"})]},le)})})]}),M.groundingSources.length>0&&l.jsxs("div",{children:[l.jsxs("div",{className:"drawer-section-label flex items-center",children:[l.jsxs("span",{children:["Grounding source links (",M.groundingSources.length,")"]}),l.jsx(Ea,{text:"Links the model used as grounding or supporting context while producing the answer. These are not the same thing as answer visibility."})]}),l.jsx("ul",{className:"grid min-w-0 gap-3",children:M.groundingSources.map((le,re)=>l.jsx("li",{className:"min-w-0",children:l.jsx(gg,{url:le.uri,title:le.title})},re))})]}),M.evidenceUrls.length>0&&l.jsxs("div",{children:[l.jsx("p",{className:"drawer-section-label",children:"Evidence URLs"}),l.jsx("ul",{className:"grid min-w-0 gap-3",children:M.evidenceUrls.map(le=>l.jsx("li",{className:"min-w-0",children:l.jsx(gg,{url:le})},le))})]}),M.citedDomains.length===0&&M.groundingSources.length===0&&M.evidenceUrls.length===0&&l.jsxs("div",{className:"flex items-center justify-center h-24 text-faint text-sm",children:["No source data ",ae?"for this run":"yet"]})]}),!Xe&&!nt&&l.jsxs("div",{className:"flex items-center justify-center h-24 text-faint text-sm",children:["No answer visibility data ",ae?"for this run":"yet"]})]})]})]})]})]})})}function cZ(e){const n=e.match(/^\/projects\/([^/]+)/);if(!n)return null;try{return decodeURIComponent(n[1])}catch{return n[1]}}function uZ(e,n){return e?n?.projects.find(r=>r.project.name===e||r.project.id===e)?.project.name??e:null}function dZ(e,n){return uZ(cZ(e),n)}function Ka(e){const n=new Date("2026-02-20");return e.map((i,r)=>({runId:`run_mock_${r+1}`,citationState:i,createdAt:new Date(n.getTime()+r*2*24*60*60*1e3).toISOString()}))}const _f=[{id:"project_citypoint",name:"Citypoint Dental NYC",canonicalDomain:"citypointdental.com",ownedDomains:[],aliases:[],qualifiedAliases:[],country:"US",language:"en",tags:["local intent","priority"],labels:{},providers:[],providerModels:{},providerDispatchModes:{},measurement:Wh,locations:[],defaultLocation:null,autoExtractBacklinks:!1,configSource:"cli",configRevision:1},{id:"project_harbor",name:"Harbor Legal Group",canonicalDomain:"harborlegal.com",ownedDomains:[],aliases:[],qualifiedAliases:[],country:"US",language:"en",tags:["lead gen"],labels:{},providers:[],providerModels:{},providerDispatchModes:{},measurement:Wh,locations:[],defaultLocation:null,autoExtractBacklinks:!1,configSource:"cli",configRevision:1},{id:"project_northstar",name:"Northstar Orthopedics",canonicalDomain:"northstarortho.com",ownedDomains:[],aliases:[],qualifiedAliases:[],country:"US",language:"en",tags:["multi-location"],labels:{},providers:[],providerModels:{},providerDispatchModes:{},measurement:Wh,locations:[],defaultLocation:null,autoExtractBacklinks:!1,configSource:"cli",configRevision:1}];function qm(e){return{id:e.id,projectId:e.projectId,projectName:e.projectName,kind:e.kind,kindLabel:e.kindLabel,status:e.status,trigger:e.trigger??"manual",createdAt:e.createdAt,startedAt:e.startedAt,duration:e.duration,statusDetail:e.statusDetail,summary:e.summary,triggerLabel:e.triggerLabel}}const yS=qm({id:"run_citypoint_visibility_20260308",projectId:"project_citypoint",projectName:"Citypoint Dental NYC",kind:"answer-visibility",kindLabel:"Answer visibility sweep",status:"completed",createdAt:"2026-03-08T12:15:00.000Z",startedAt:"Mar 8, 12:15 PM",duration:"6 minutes 12 seconds",statusDetail:"18 tracked queries checked; 3 citation losses detected on emergency-intent prompts.",summary:"Citation losses on emergency-intent prompts",triggerLabel:"Scheduled"}),mZ=qm({id:"run_citypoint_queued_20260309",projectId:"project_citypoint",projectName:"Citypoint Dental NYC",kind:"answer-visibility",kindLabel:"Answer visibility sweep",status:"queued",createdAt:"2026-03-09T08:05:00.000Z",startedAt:"Mar 9, 8:05 AM",duration:"Waiting",statusDetail:"Ready to enqueue after the next provider rate window clears.",summary:"Queued follow-up after local ranking movement",triggerLabel:"Manual"}),bS=qm({id:"run_harbor_visibility_20260308",projectId:"project_harbor",projectName:"Harbor Legal Group",kind:"answer-visibility",kindLabel:"Answer visibility sweep",status:"completed",createdAt:"2026-03-08T11:05:00.000Z",startedAt:"Mar 8, 11:05 AM",duration:"5 minutes 7 seconds",statusDetail:"12 tracked queries checked; local-intent visibility held steady across branded prompts.",summary:"Branded prompts remain stable",triggerLabel:"Scheduled"}),pZ=qm({id:"run_northstar_visibility_20260308",projectId:"project_northstar",projectName:"Northstar Orthopedics",kind:"answer-visibility",kindLabel:"Answer visibility sweep",status:"running",createdAt:"2026-03-08T13:40:00.000Z",startedAt:"Mar 8, 1:40 PM",duration:"Running",statusDetail:"Provider responses still in flight for 9 multi-location prompts.",summary:"Mid-run on treatment-location prompts",triggerLabel:"Manual"}),hZ=[{id:"evidence_citypoint_emergency_gemini",query:"emergency dentist brooklyn",provider:"gemini",model:"gemini-2.5-flash",location:null,citationState:"lost",changeLabel:"Lost since Mar 5",answerSnippet:"For urgent dental care in Brooklyn, Downtown Smiles and Harbor Dental are now cited first for emergency availability and same-day booking.",citedDomains:["downtownsmiles.com","harbordental.com"],evidenceUrls:["https://downtownsmiles.com/emergency-dentist-brooklyn","https://harbordental.com/same-day-emergency-care"],competitorDomains:["downtownsmiles.com","harbordental.com"],groundingSources:[],relatedTechnicalSignals:["FAQ schema missing on the emergency service page","llms.txt not found during latest site audit","Location pages link weakly into the emergency care hub"],summary:"AI answers now cite two competitors while your emergency page is no longer grounded.",runHistory:Ka(["cited","cited","cited","cited","cited","cited","cited","not-cited","not-cited"])},{id:"evidence_citypoint_emergency_openai",query:"emergency dentist brooklyn",provider:"openai",model:"gpt-5.4",location:null,citationState:"cited",changeLabel:"Cited for 6 runs",answerSnippet:"Citypoint Dental is listed as a top emergency dentist in Brooklyn for same-day appointments and walk-in availability.",citedDomains:["citypointdental.com","downtownsmiles.com"],evidenceUrls:["https://citypointdental.com/emergency-dentist-brooklyn"],competitorDomains:["downtownsmiles.com"],groundingSources:[],relatedTechnicalSignals:["Emergency page indexed with structured data"],summary:"OpenAI cites your emergency page consistently alongside one competitor.",runHistory:Ka(["not-cited","cited","cited","cited","cited","cited","cited"])},{id:"evidence_citypoint_emergency_claude",query:"emergency dentist brooklyn",provider:"claude",model:"claude-sonnet-4-6",location:null,citationState:"not-cited",changeLabel:"No citation across 12 runs",answerSnippet:"Based on the search results, top-rated emergency dental practices in Brooklyn include Downtown Smiles and Harbor Dental.",citedDomains:["downtownsmiles.com","harbordental.com"],evidenceUrls:[],competitorDomains:["downtownsmiles.com","harbordental.com"],groundingSources:[],relatedTechnicalSignals:["FAQ schema missing","llms.txt not found"],summary:"Claude does not cite your domain for this emergency query.",runHistory:Ka(["not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited"])},{id:"evidence_citypoint_invisalign_openai",query:"best invisalign dentist downtown brooklyn",provider:"openai",model:"gpt-5.4",location:null,citationState:"emerging",changeLabel:"First citation in 7 days",answerSnippet:"Citypoint Dental appears as an emerging recommendation for Invisalign in Downtown Brooklyn, supported by recent before-and-after case pages.",citedDomains:["citypointdental.com","clearlineortho.com"],evidenceUrls:["https://citypointdental.com/invisalign-downtown-brooklyn","https://citypointdental.com/case-studies/invisalign-open-bite"],competitorDomains:["clearlineortho.com"],groundingSources:[],relatedTechnicalSignals:["Structured data now present on two case-study pages","Internal links from service pages to case studies improved crawl depth"],summary:"Fresh case-study content is starting to earn citations on Invisalign prompts.",runHistory:Ka(["not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","cited"])},{id:"evidence_citypoint_invisalign_gemini",query:"best invisalign dentist downtown brooklyn",provider:"gemini",model:"gemini-2.5-flash",location:null,citationState:"cited",changeLabel:"Cited for 8 runs",answerSnippet:"Citypoint Dental in Downtown Brooklyn is highlighted for its Invisalign expertise and patient outcomes.",citedDomains:["citypointdental.com"],evidenceUrls:["https://citypointdental.com/invisalign-downtown-brooklyn"],competitorDomains:[],groundingSources:[],relatedTechnicalSignals:["Case study pages well-indexed"],summary:"Gemini consistently cites your Invisalign page with no competitor overlap.",runHistory:Ka(["cited","cited","cited","cited","cited","cited","cited","cited"])},{id:"evidence_citypoint_invisalign_claude",query:"best invisalign dentist downtown brooklyn",provider:"claude",model:"claude-sonnet-4-6",location:null,citationState:"not-cited",changeLabel:"No citation across 12 runs",answerSnippet:"For Invisalign in Downtown Brooklyn, Clear Line Ortho and Brooklyn Smiles are frequently recommended for their experienced orthodontists.",citedDomains:["clearlineortho.com","brooklynsmiles.com"],evidenceUrls:[],competitorDomains:["clearlineortho.com"],groundingSources:[],relatedTechnicalSignals:["No before/after schema on case study pages"],summary:"Claude does not surface your Invisalign content despite strong page quality.",runHistory:Ka(["not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited"])},{id:"evidence_citypoint_children_claude",query:"pediatric dentist brooklyn heights",provider:"claude",model:"claude-sonnet-4-6",location:null,citationState:"not-cited",changeLabel:"No citation across 4 runs",answerSnippet:"Answers cite neighborhood-specific pediatric practices with stronger family-focused FAQ content and clearer insurance details.",citedDomains:["brightkidsdental.com","parkpediatricdental.com"],evidenceUrls:["https://brightkidsdental.com/pediatric-dentist-brooklyn-heights","https://parkpediatricdental.com/insurance"],competitorDomains:["brightkidsdental.com","parkpediatricdental.com"],groundingSources:[],relatedTechnicalSignals:["No dedicated pediatric service page exists for Brooklyn Heights","Insurance content is buried three clicks deep"],summary:"Coverage gap is content-driven, not purely technical.",runHistory:Ka(["not-cited","not-cited","not-cited","not-cited"])},{id:"evidence_citypoint_children_gemini",query:"pediatric dentist brooklyn heights",provider:"gemini",model:"gemini-2.5-flash",location:null,citationState:"not-cited",changeLabel:"No citation across 12 runs",answerSnippet:"For pediatric dentistry in Brooklyn Heights, Bright Kids Dental and Park Pediatric Dental are cited for family-friendly care.",citedDomains:["brightkidsdental.com","parkpediatricdental.com"],evidenceUrls:[],competitorDomains:["brightkidsdental.com","parkpediatricdental.com"],groundingSources:[],relatedTechnicalSignals:["No dedicated pediatric page for Brooklyn Heights"],summary:"Gemini does not surface your domain for pediatric queries in this area.",runHistory:Ka(["not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited","not-cited"])},{id:"evidence_citypoint_children_openai",query:"pediatric dentist brooklyn heights",provider:"openai",model:"gpt-5.4",location:null,citationState:"cited",changeLabel:"First citation this month",answerSnippet:"Citypoint Dental is mentioned as offering pediatric services in Brooklyn, though specialized pediatric-only practices are also highlighted.",citedDomains:["citypointdental.com","brightkidsdental.com"],evidenceUrls:["https://citypointdental.com/family-dentistry"],competitorDomains:["brightkidsdental.com"],groundingSources:[],relatedTechnicalSignals:["Family dentistry page recently updated"],summary:"OpenAI recently started citing your family dentistry page for this query.",runHistory:Ka(["not-cited","not-cited","not-cited","not-cited","not-cited","cited"])}];_f[0],9/21,8/21,4/21,_f[1],11/17,6/17,Ka(["cited","cited","cited","cited","cited"]),_f[2],15/19,4/19,Ka(["not-cited","not-cited","not-cited","cited"]);function fZ(e,n){return e.runs.find(i=>i.id===n)}function gZ(e,n){for(const i of e.projects){const r=i.visibilityEvidence.find(u=>u.id===n);if(r)return{project:i,evidence:r}}}function yZ(e,n,i){if(e){const r=e.visibilityEvidence.find(u=>u.id===i);if(r)return{project:e,evidence:r}}if(n)return gZ(n,i)}const bZ={regression:"negative",gain:"positive",opportunity:"caution","first-citation":"positive","provider-pickup":"positive","persistent-gap":"caution","competitor-gained":"negative","competitor-lost":"neutral","gbp-lodging-gap":"negative","gbp-listing-discrepancy":"negative","gbp-cta-gap":"caution","gbp-description-missing":"caution","gbp-metric-drop":"negative","gbp-keyword-drop":"negative"},vZ={opportunity:"write","persistent-gap":"write","competitor-gained":"write","competitor-lost":"write",regression:"investigate",gain:"monitor","first-citation":"monitor","provider-pickup":"monitor","gbp-lodging-gap":"write","gbp-listing-discrepancy":"write","gbp-cta-gap":"write","gbp-description-missing":"write","gbp-metric-drop":"investigate","gbp-keyword-drop":"investigate"},xZ={regression:"lost",gain:"emerging",opportunity:"not-cited","first-citation":"emerging","provider-pickup":"emerging","persistent-gap":"not-cited","competitor-gained":"cited","competitor-lost":"not-cited","gbp-lodging-gap":"not-cited","gbp-listing-discrepancy":"not-cited","gbp-cta-gap":"not-cited","gbp-description-missing":"not-cited","gbp-metric-drop":"lost","gbp-keyword-drop":"lost"},wZ={regression:"Regression",gain:"Gain",opportunity:"Opportunity","first-citation":"First citation","provider-pickup":"Pickup","persistent-gap":"Gap","competitor-gained":"Competitor","competitor-lost":"Competitor","gbp-lodging-gap":"Lodging gap","gbp-listing-discrepancy":"Listing gap","gbp-cta-gap":"Booking CTA","gbp-description-missing":"Description gap","gbp-metric-drop":"Metric drop","gbp-keyword-drop":"Keyword drop"};function SZ(e){return{id:e.id,tone:bZ[e.type],title:e.title,detail:e.cause?.details??e.cause?.cause??"",actionLabel:e.recommendation?.action??wZ[e.type],actionGroup:vZ[e.type],affectedPhrases:[{query:e.query,evidenceId:"",provider:e.provider,citationState:xZ[e.type]}]}}function kZ(e){return e.filter(n=>!n.dismissed).map(SZ)}function RC(e){return{id:e.id,name:e.name,displayName:e.displayName,canonicalDomain:e.canonicalDomain,ownedDomains:e.ownedDomains??[],aliases:e.aliases??[],qualifiedAliases:e.qualifiedAliases,country:e.country,language:e.language,tags:e.tags,labels:e.labels,providers:e.providers??[],providerModels:e.providerModels??{},providerDispatchModes:e.providerDispatchModes??{},measurement:e.measurement,locations:e.locations??[],defaultLocation:e.defaultLocation??null,autoExtractBacklinks:e.autoExtractBacklinks??!1,configSource:e.configSource,configRevision:e.configRevision,createdAt:e.createdAt,updatedAt:e.updatedAt}}function bo(e,n){return`${e} ${n}${e===1?"":"s"}`}function jZ(e,n){if(!e)return"Waiting";if(!n)return"Running";const i=new Date(n).getTime()-new Date(e).getTime();if(i<1e3)return"under 1 second";const r=Math.floor(i/1e3),u=Math.floor(r/3600),h=Math.floor(r%3600/60),f=r%60;return u>0?h>0?`${bo(u,"hour")} ${bo(h,"minute")}`:bo(u,"hour"):h>0?f>0?`${bo(h,"minute")} ${bo(f,"second")}`:bo(h,"minute"):bo(f,"second")}function DC(e){switch(e){case Re["answer-visibility"]:return"Answer visibility sweep";case Re["gsc-sync"]:return"GSC sync";case Re["inspect-sitemap"]:return"Sitemap inspection";case Re["ga-sync"]:return"GA sync";case Re["traffic-sync"]:return"Traffic sync";case Re["bing-inspect"]:return"Bing URL inspection";case Re["bing-inspect-sitemap"]:return"Bing sitemap inspection";case Re["site-audit"]:return"Site audit";case Re["backlink-extract"]:return"Backlink extract";case Re["aeo-discover-seed"]:return"Discovery (seed phase)";case Re["aeo-discover-probe"]:return"Discovery (probe phase)";case Re["gbp-sync"]:return"Business Profile sync";case Re["ads-sync"]:return"ChatGPT ads sync";case Re["google-ads-sync"]:return"Google Ads sync";case Re["gtm-sync"]:return"Tag Manager sync"}}function AZ(e){switch(e){case ci.manual:return"Manual";case ci.scheduled:return"Scheduled";case ci["config-apply"]:return"Config apply";case ci.probe:return"Spot check";default:return e}}function Pm(e,n){return{id:e.id,projectId:e.projectId,projectName:n,kind:e.kind,kindLabel:DC(e.kind),status:e.status,trigger:e.trigger??"manual",location:e.location??null,createdAt:e.createdAt,startedAt:YK(e.startedAt||e.createdAt),duration:jZ(e.startedAt??null,e.finishedAt??null),statusDetail:e.error?zC(e.error):CZ(e),summary:NZ(e),triggerLabel:AZ(e.trigger)}}function zC(e){const n=h0(e);return n.length>200?n.slice(0,200)+"…":n}function CZ(e){switch(e.status){case Zt.queued:return"Waiting for execution slot.";case Zt.running:return"Provider queries in progress.";case Zt.completed:return"All queries checked.";case Zt.partial:return"Run completed with some queries skipped.";case Zt.failed:return e.error?zC(e.error):"Run failed.";case Zt.cancelled:return"Run was cancelled.";default:return""}}function NZ(e){const n=DC(e.kind);switch(e.status){case Zt.queued:return`${n} queued`;case Zt.running:return`${n} in progress`;case Zt.completed:return`${n} completed`;case Zt.partial:return`${n} partially completed`;case Zt.failed:return`${n} failed`;case Zt.cancelled:return`${n} cancelled`;default:return e.status}}function _Z(e,n,i,r,u){const h=[];let f=0;const b=new Set;if(i.length>0){const v=i.flatMap(E=>E.snapshots??[]),x=new Map;for(const E of v)if(E.query){const $=`${E.query}::${E.provider}::${E.location??""}`;x.set($,E)}const S=new Set(v.map(E=>E.location??null));S.size===0&&S.add(null);const k=new Set(v.map(E=>E.provider)),T=new Set(n.flatMap(E=>Object.keys(E.providerRuns??{}))),N=[...new Set([...k,...T])].sort(),I=N.length>0?N:["gemini"],P=new Set(v.flatMap(E=>E.query?[E.query]:[]));for(const E of n){if(E.runs.length===0&&!P.has(E.query))continue;b.add(E.query);const $=E.runs.at(-1),ee=$?.transition??"not-cited";for(const L of I){const F=[...S].filter(M=>x.has(`${E.query}::${L}::${M??""}`)),Z=(E.providerRuns?.[L]?.length??0)>0,ae=F.length>0?F:Z?[null]:[];for(const M of ae){const Y=M??"",ue=x.get(`${E.query}::${L}::${Y}`),Xe=ue?.model??null,nt=Xe?`${L}:${Xe}`:null,Ge=E.providerRuns?.[L],Pe=nt?E.modelRuns?.[nt]:void 0,Se=Kt=>Kt?.filter(Be=>(Be.location??null)===M),Ve=F.length>0?Se(Ge):Ge,q=F.length>0?Se(Pe):Pe,X=(Ve?.length?Ve:null)??(q?.length?q:null),ve=Ve?.length?"provider":q?.length?"model":"query",ke=ue&&X?X.findIndex(Kt=>Kt.runId===ue.runId):-1,J=ue?ke>=0?X.slice(0,ke+1):null:X,Ne=ue!==void 0&&J===null,Me=J?J.at(-1).transition:Ne?ue.citationState===fc.cited?"cited":"not-cited":ee,xe=J?J.at(-1).visibilityTransition??(J.at(-1).visibilityState==="visible"?"visible":"not-visible"):Ne?ue.visibilityState==="visible"?"visible":"not-visible":$?.visibilityTransition??($?.visibilityState==="visible"?"visible":"not-visible"),le=X?.at(-1)?.citationState,re=X?.at(-1)?.visibilityState,H=ue?Me==="lost"?"lost":Me==="emerging"?"emerging":ue.citationState===fc.cited?"cited":"not-cited":le===fc.cited?"cited":"not-cited",pe=ue?.visibilityState??(re==="visible"?"visible":re==="pending"?"pending":"not-visible"),ze=J?vS(J):Ne?1:vS(E.runs),je=J?xS(J):Ne?1:xS(E.runs),it=TZ(E,L),Ue=(X??E.runs).map(Kt=>({runId:Kt.runId,citationState:Kt.citationState,createdAt:Kt.createdAt,model:it.get(Kt.runId)??null,answerMentioned:Kt.answerMentioned,visibilityState:Kt.visibilityState,visibilityTransition:Kt.visibilityTransition,mentionState:Kt.mentionState,mentionTransition:Kt.mentionTransition})),jt=EZ(Ue),He=ve==="provider"&&jt.length<=1?"model":ve,me=RZ(Ue),ot=ue?.citedCompetitorDomains??[],It=ue?.mentionedCompetitorDomains??[],Bn=[...new Set([...ot,...It,...ue?.competitorOverlap??[]])];h.push({id:`evidence_${e}_${f++}`,query:E.query,queryId:ue?.queryId??null,sourceSnapshotId:ue?.id??null,sourceRunId:ue?.runId??null,queryClass:u?.classify(E.query)??null,provider:ue?.provider??L,model:ue?.model??null,location:ue?.location??M,citationState:H,answerMentioned:ue?.answerMentioned,visibilityState:pe,visibilityChangeLabel:wS(xe,je,{positive:"visible",negative:"not visible",first:"first visibility"}),changeLabel:wS(Me,ze),answerSnippet:ue?.answerText??"",citedDomains:ue?.citedDomains??[],evidenceUrls:ue?.citedUrls??[],citedCompetitorDomains:ot,mentionedCompetitorDomains:It,competitorDomains:Bn,recommendedCompetitors:ue?.recommendedCompetitors??[],matchedTerms:ue?.matchedTerms??[],relatedTechnicalSignals:[],groundingSources:ue?.groundingSources??[],searchQueries:ue?.searchQueries??[],summary:DZ(pe,xe,E.query),runHistory:Ue,historyScope:He,modelsSeen:jt,modelTransitions:me})}}}}for(const v of r)b.has(v.query)||h.push({id:`evidence_${e}_${f++}`,query:v.query,queryId:v.id,sourceSnapshotId:null,sourceRunId:null,queryClass:u?.classify(v.query)??null,provider:"",model:null,location:null,citationState:"pending",visibilityState:"pending",visibilityChangeLabel:"Awaiting first run",changeLabel:"Awaiting first run",answerSnippet:"",citedDomains:[],evidenceUrls:[],citedCompetitorDomains:[],mentionedCompetitorDomains:[],competitorDomains:[],recommendedCompetitors:[],matchedTerms:[],relatedTechnicalSignals:[],groundingSources:[],searchQueries:[],summary:`"${v.query}" has been added but no visibility run has been triggered yet.`,runHistory:[],historyScope:"query",modelsSeen:[],modelTransitions:[]});return h}function TZ(e,n){const i=new Map,r=`${n}:`;for(const[u,h]of Object.entries(e.modelRuns??{})){if(!u.startsWith(r))continue;const f=u.slice(r.length),b=f==="unknown"?null:f;for(const v of h)i.set(v.runId,b)}return i}function EZ(e){const n=new Set;for(const i of e)i.model&&n.add(i.model);return[...n]}function RZ(e){const n=[];let i=null;for(const r of e){const u=r.model??null;u!==i&&i!==null&&n.push({runId:r.runId,createdAt:r.createdAt,fromModel:i,toModel:u}),i=u}return n}function vS(e){if(e.length===0)return 0;const n=e[e.length-1].citationState;let i=0;for(let r=e.length-1;r>=0&&e[r].citationState===n;r--)i++;return i}function xS(e){if(e.length===0)return 0;const n=e[e.length-1].visibilityState??"not-visible";let i=0;for(let r=e.length-1;r>=0&&(e[r].visibilityState??"not-visible")===n;r--)i++;return i}function wS(e,n,i){const r={positive:i?.positive??"cited",negative:i?.negative??"not cited",first:i?.first??"first citation"};switch(e){case"new":return"First observation";case"cited":case"visible":return n<=1?`${uc(r.positive)} in latest run`:`${uc(r.positive)} for ${n} runs`;case"lost":return"Lost since last run";case"emerging":return uc(r.first);case"not-cited":case"not-visible":return n<=1?`${uc(r.negative)} in latest run`:`${uc(r.negative)} across ${n} runs`;default:return e}}function uc(e){return e.charAt(0).toUpperCase()+e.slice(1)}function DZ(e,n,i){switch(n){case"lost":return`Mention was lost for "${i}". Your brand no longer appeared in the latest answer.`;case"emerging":return`Your brand started appearing in AI answers for "${i}".`}switch(e){case"visible":return`Your brand or domain is mentioned in AI answers for "${i}".`;case"pending":return`"${i}" has been added but no run has been triggered yet.`;default:return`Your brand or domain was not mentioned in AI answers for "${i}".`}}function IC(e){const n=RC(e.project),i=Z9(V9(e.project)),r=_Z(n.name,e.timeline,e.latestRunDetails,e.queries,i),h=[...e.runs].sort((f,b)=>b.createdAt.localeCompare(f.createdAt)).map(f=>Pm(f,e.project.displayName||e.project.name));return e.overview?zZ(n,e.overview,r,h):IZ(n,r,h)}function OC(e){return e.filter(n=>n.kind===Re["answer-visibility"]&&n.trigger!==ci.probe&&(n.status===Zt.completed||n.status===Zt.partial))}function zZ(e,n,i,r){const u=kZ(n.topInsights);for(const h of n.attentionItems)h.id.startsWith("insight_")||u.push({id:h.id,tone:h.tone,title:h.title,detail:h.detail,actionLabel:h.actionLabel,actionGroup:"investigate",affectedPhrases:[]});return{project:e,contextLabel:n.contextLabel,mentionSummary:n.scores.mention,visibilitySummary:n.scores.visibility,mentionShareSummary:n.scores.mentionShare,queryCounts:{cited:n.queryCounts.citedQueries,total:n.queryCounts.totalQueries},gapQueries:n.scores.gapQueries,mentionGaps:n.scores.mentionGaps,indexCoverage:n.scores.indexCoverage,providerScores:n.providerScores,competitorPressure:n.scores.competitorPressure,runStatus:n.scores.runStatus,movementComparison:n.movementComparison,insights:u,visibilityEvidence:i,competitors:n.competitors.map(h=>({id:h.id,domain:h.domain,citationCount:h.citationCount,totalQueries:h.totalQueries,pressureLabel:h.pressureLabel,citedQueries:h.citedQueries,movement:"",notes:""})),recentRuns:r.slice(0,5),visibilitySweeps:OC(r),suggestedQueries:n.suggestedQueries}}function SS(){return{projectMentionSnapshots:0,competitorMentionSnapshots:0,combinedMentionSnapshots:0,perCompetitor:[],ranking:[],snapshotsWithAnswerText:0,snapshotsTotal:0,score:null}}function IZ(e,n,i){const r={label:"",value:"No data",delta:"Loading…",tone:"neutral",description:"",tooltip:"",trend:[]};return{project:e,contextLabel:`${e.country} / ${e.language.toUpperCase()}`,mentionSummary:{...r,label:"Mention Coverage"},visibilitySummary:{...r,label:"Citation Coverage"},mentionShareSummary:{...r,label:"Mention Share",scope:"non-brand",unavailable:!0,breakdown:SS(),branded:SS()},queryCounts:{cited:0,total:0},gapQueries:{...r,label:"Citation Gaps"},mentionGaps:{...r,label:"Mention Gaps"},indexCoverage:{...r,label:"Index Coverage"},providerScores:[],competitorPressure:{...r,label:"Competitor Pressure"},runStatus:{...r,label:"Run Status"},movementComparison:{hasPreviousRun:!1,comparable:!1,querySetChanged:!1,previousRunAt:null,currentQueryCount:0,previousQueryCount:0,comparableQueryCount:0,addedQueryCount:0,removedQueryCount:0,addedQueries:[],removedQueries:[]},insights:[],visibilityEvidence:n,competitors:[],recentRuns:i.slice(0,5),visibilitySweeps:OC(i),suggestedQueries:{rows:[],totalCandidates:0,skippedAlreadyTracked:0}}}function OZ(e){const n=RC(e.project),i=[...e.runs].sort((T,N)=>N.createdAt.localeCompare(T.createdAt)),r=i.find(T=>T.kind===Re["answer-visibility"])??i[0]??e.overview?.latestRun?.run??void 0,u=e.project.displayName||e.project.name,h=r?Pm(r,u):qZ(e.project.id,u),f=e.overview;if(!f)return{project:n,hasMeasurement:!1,mentionScore:0,mentionDelta:"No data",mentionTone:"neutral",lastRun:h,insight:"No runs completed yet.",trend:[],competitorPressureLabel:"None"};const b=f.scores.mention,v=b.progress??0,x=f.queryCounts.mentionedQueries,S=f.queryCounts.totalQueries,k=f.providers.length;return{project:n,hasMeasurement:S>0&&b.progress!=null,mentionScore:v,mentionDelta:S>0?`${x} of ${S} queries`:"No data",mentionTone:b.tone,providerCoverage:b.providerCoverage,lastRun:h,insight:S>0?`${x} of ${S} queries mentioned across ${k} provider${k===1?"":"s"}.`:"No runs completed yet.",trend:b.trend??[],competitorPressureLabel:f.scores.competitorPressure.value,sentiment:f.sentiment}}function qZ(e,n){return{id:"none",projectId:e,projectName:n,kind:Re["answer-visibility"],kindLabel:"No runs yet",status:Zt.queued,trigger:ci.manual,createdAt:"",startedAt:"",duration:"",statusDetail:"",summary:"No runs yet",triggerLabel:""}}function PZ(e,n){const i=[],r=[],u=[];for(const f of e){r.push(IC(f)),u.push(OZ(f));const b=[...f.runs].sort((v,x)=>x.createdAt.localeCompare(v.createdAt));for(const v of b)i.push(Pm(v,f.project.displayName||f.project.name))}i.sort((f,b)=>b.createdAt.localeCompare(f.createdAt));const h=e.length>0;return{portfolioOverview:{projects:u,attentionItems:h?MZ(r):[{id:"attention_setup",tone:"neutral",title:"No projects yet",detail:"Create your first project using the setup wizard, CLI, or API.",actionLabel:"Open setup",href:"/setup"}],recentRuns:i.slice(0,5),systemHealth:[{id:"api",label:"API",tone:"positive",detail:"Connected",meta:"Real-time data"},{id:"provider",label:"Gemini",tone:"positive",detail:"Configured",meta:"Provider active"}],...h?{}:{emptyState:{title:"No projects yet",detail:"Canonry becomes useful after one project, a small query set, and one competitor list are in place.",ctaLabel:"Launch setup",ctaHref:"/setup"}}},projects:r,runs:i,setup:{healthChecks:[{id:"api",label:"API reachable",detail:"API is responding.",state:"ready",guidance:"Required for project creation and run history."},{id:"provider",label:"Provider configured",detail:"Gemini key is configured.",state:"ready",guidance:"Required for answer-visibility sweeps."}],projectDraft:{name:"",canonicalDomain:"",country:"US",language:"en"},queryImportState:{mode:"paste",queryCount:0,preview:[]},competitorDraft:{domains:[],notes:"Use the CLI to add competitors."},launchState:{enabled:h,ctaLabel:h?"Trigger run":"Create a project first",summary:h?"Ready to run.":"Create a project first to launch a run."}},settings:{providerStatuses:(n?.providers??[]).map(f=>({name:f.name,displayName:f.displayName,keyUrl:f.keyUrl,modelHint:f.modelHint,model:f.model,defaultModel:f.defaultModel,state:f.configured?"ready":"needs-config",detail:f.configured?"Provider is configured.":f.name.toLowerCase()==="local"?"Base URL is missing.":"API key is missing.",quota:f.quota})),google:{state:n?.google?.configured?"ready":"needs-config",detail:n?.google?.configured?"Google OAuth app credentials are configured. Project-level GSC connections can be created from the dashboard.":"Google OAuth client ID and client secret are not configured yet."},bing:{state:n?.bing?.configured?"ready":"needs-config",detail:n?.bing?.configured?"Bing Webmaster Tools API key is configured. Project-level Bing connections can be created from the dashboard.":"Bing Webmaster Tools API key is not configured yet."},selfHostNotes:["Configuration is stored in ~/.canonry/config.yaml.","The local config file is the source of truth for authentication credentials.","Google OAuth app credentials and per-domain Google tokens are stored in local config, not the database.","Database is SQLite at ~/.canonry/data.db.","API key was auto-generated during canonry init."],bootstrapNote:"Use the UI, CLI, or ~/.canonry/config.yaml to manage settings. Authentication credentials persist to local config."}}}function MZ(e){const n=[];for(const i of e){const r=i.visibilityEvidence.filter(h=>h.citationState==="lost");r.length>0&&n.push({id:`attention_${i.project.id}_lost`,tone:"negative",title:`${i.project.displayName||i.project.name} lost citations`,detail:`${r.length} quer${r.length>1?"ies":"y"} lost citation.`,actionLabel:"Open project",href:`/projects/${encodeURIComponent(i.project.name)}`});const u=i.recentRuns.filter(h=>h.status===Zt.running||h.status===Zt.queued);u.length>0&&n.push({id:`attention_${i.project.id}_active`,tone:"neutral",title:`${i.project.displayName||i.project.name} has active runs`,detail:`${u.length} run${u.length>1?"s":""} in progress.`,actionLabel:"View runs",href:"/runs"})}return n.length===0&&n.push({id:"attention_stable",tone:"positive",title:"All projects stable",detail:"No citation losses or active runs to flag."}),n}const qC=C.createContext(null);qC.Provider;function Qc(){return C.useContext(qC)}function Mm(e,n={}){const r=Qc()?.dashboard??null,u=n.includeSettings??!0,h=n.includeOverviews??!0,f=n.pauseProjectPolling??!1,{isAdmin:b}=fa(),v=yt({...zm({client:W,query:{kind:"answer-visibility"}}),enabled:!r,staleTime:Gr,refetchInterval:L=>L.state.data?.some(ae=>ae.status==="running"||ae.status==="queued")?3e3:Gr}),x=yt({...qo({client:W}),enabled:!r,refetchInterval:f?!1:L=>{const F=L.state.data,Z=v.data?.some(M=>M.status==="running"||M.status==="queued");return(F?.length??0)===0||!!Z?BK:LK}}),S=yt({...RH({client:W}),enabled:!r&&u&&b}),k=x.data??[],T=v.data??[],N=c5({queries:k.map(L=>{const F=T.filter(M=>M.projectId===L.id),Z=F.filter(M=>(M.status==="completed"||M.status==="partial")&&M.kind==="answer-visibility"&&M.trigger!=="probe").sort((M,Y)=>Y.createdAt.localeCompare(M.createdAt)),ae=Z.length>0?Z[0].id:"no-run";return{queryKey:["project-overview-slim",L.id,ae],queryFn:async()=>{const M=await JA(L.name).catch(()=>null);return{project:L,runs:F,queries:[],competitors:[],timeline:[],latestRunDetails:[],previousRunDetails:[],gscCoverage:null,bingCoverage:null,dbInsights:null,overview:M}},enabled:!r&&h&&x.isSuccess&&v.isSuccess,staleTime:Td}})}),I=!h||N.every(L=>L.isSuccess),P=C.useMemo(()=>{if(r)return r;if(!x.data||!v.data||k.length>0&&!I)return null;const L=h?N.map(F=>F.data?{...F.data,runs:T.filter(Z=>Z.projectId===F.data.project.id)}:null).filter(F=>F!=null):k.map((F,Z)=>{const ae=N[Z]?.data;return{project:F,runs:T.filter(M=>M.projectId===F.id),queries:[],competitors:[],timeline:[],latestRunDetails:[],previousRunDetails:[],gscCoverage:null,bingCoverage:null,dbInsights:null,overview:ae?.overview??null}});return PZ(L,S.data??null)},[r,x.data,v.data,S.data,h,I,N,k,T]),E=!r&&(x.isError||v.isError),$=!r&&!P&&!E,ee=C.useCallback(async()=>{const L=[x.refetch(),v.refetch(),...h?N.map(F=>F.refetch()):[]];u&&L.push(S.refetch()),await Promise.all(L)},[u,h,N,x.refetch,v.refetch,S.refetch]);return{dashboard:P,isLoading:$,isError:E,refetch:ee}}function BZ(e){return JSON.stringify(e.filter(n=>n.kind==="answer-visibility"&&n.trigger!=="probe"&&(n.status==="completed"||n.status==="partial")).map(n=>[n.id,n.status]).sort(([n],[i])=>n.localeCompare(i)))}async function yg(e,n,i="active"){const r=u=>{const h=u.queryKey[0];return h?._id==="getApiV1ProjectsByNameAnalyticsCompetitors"&&h.path?.name===n};return i==="active"&&await e.cancelQueries({predicate:r}),e.invalidateQueries({predicate:r,refetchType:i})}function mse(e,n,i){const r=ta(),u=C.useRef({projectName:e,revision:n,enabled:i});C.useEffect(()=>{const h=u.current;u.current={projectName:e,revision:n,enabled:i},!(!i||!h.enabled||h.projectName!==e||h.revision===n)&&yg(r,e)},[i,e,r,n])}const LZ=20;function $Z(e,n={}){const i=ta(),r=Qc(),u=C.useMemo(()=>!r||!e?null:r.dashboard.projects.find(Z=>Z.project.name===e)??null,[r,e]),h=yt({...cH({client:W,path:{name:e??""}}),enabled:!!e&&!u,staleTime:Td,refetchOnWindowFocus:"always"}),f=yt({...lC({client:W,path:{name:e??""},query:{kind:"answer-visibility"}}),enabled:!!e,staleTime:Gr,refetchOnWindowFocus:"always",refetchInterval:Z=>Z.state.data?.some(Y=>Y.projectId===h.data?.id&&(Y.status==="running"||Y.status==="queued"))?3e3:Gr}),b=h.data??null,v=C.useMemo(()=>b?(f.data??[]).filter(Z=>Z.projectId===b.id):[],[b,f.data]),{latestRunIds:x,latestRunIdsKey:S,latestVisibilityRevision:k}=C.useMemo(()=>{const Z=v.filter(Y=>(Y.status==="completed"||Y.status==="partial")&&Y.kind==="answer-visibility"&&Y.trigger!=="probe").sort((Y,ue)=>ue.createdAt.localeCompare(Y.createdAt)),ae=Z[0]?.createdAt??null,M=ae?Z.filter(Y=>Y.createdAt===ae).map(Y=>Y.id):[];return{latestRunIds:M,latestRunIdsKey:[...M].sort().join(","),latestVisibilityRevision:ae?`${ae}:${[...M].sort().join(",")}`:"none"}},[v]),T=!!b&&!!e&&f.isSuccess,N=yt({queryKey:["project-dashboard-full",b?.id??null,S||"none","overview"],queryFn:async()=>({project:b,overview:await JA(e)}),enabled:T&&n.overview===!0,staleTime:Td,refetchOnWindowFocus:"always"}),I=yt({queryKey:["project-dashboard-full",b?.id??null,S||"none","evidence"],queryFn:async()=>{const[Z,ae,M]=await Promise.all([XA(e),WG(e,void 0,LZ),Promise.all(x.map(Y=>rg(Y)))]);return{project:b,queries:Z,timeline:ae,latestRunDetails:M}},enabled:T&&n.evidence===!0,staleTime:Td,refetchOnWindowFocus:"always"}),P=C.useMemo(()=>{if(!b||!f.data)return u;const Z=n.evidence?I.data:void 0,ae={project:b,runs:v,queries:Z?.queries??[],timeline:Z?.timeline??[],latestRunDetails:Z?.latestRunDetails??[],overview:n.overview?N.data?.overview??null:null},M=IC(ae);return u&&!(n.overview&&N.data)?{...u,project:M.project,recentRuns:M.recentRuns,visibilitySweeps:M.visibilitySweeps,visibilityEvidence:Z?M.visibilityEvidence:u.visibilityEvidence}:M},[b,v,I.data,N.data,u,n.evidence,n.overview,f.data]),E=C.useCallback(async()=>{await Promise.all([h.refetch(),f.refetch(),i.invalidateQueries({queryKey:["project-dashboard-full",b?.id??null]})])},[h.refetch,f.refetch,i,b?.id]),$=h.isError||f.isError,ee=!u&&(h.isLoading||f.isLoading),L=!!e&&n.overview===!0&&!u&&!$&&N.isPending,F=!!e&&n.evidence===!0&&!u&&!$&&I.isPending;return{commandCenter:P,project:b,isLoading:ee,isError:$,overviewLoading:L,overviewError:n.overview===!0&&N.isError&&!N.data,evidenceLoading:F,evidenceError:n.evidence===!0&&I.isError&&!I.data,latestVisibilityRevision:k,competitorHistoryRevision:BZ(v),refetch:E}}const VZ=["health"];async function UZ(){const e=await bK("/health","API"),n=zr()&&e.state==="ok"?{label:"Worker",state:"disabled",detail:"Background execution is disabled in this public demo."}:e.state==="ok"?{label:"Worker",state:"ok",detail:"In-process job runner"}:{label:"Worker",state:e.state,detail:`Depends on API health check · ${e.detail}`,statusCode:e.statusCode,hint:e.hint?`Worker status is inferred from API health in this deployment mode. ${e.hint}`:"Worker status is inferred from API health in this deployment mode."};return{apiStatus:e,workerStatus:n}}function f1(e,n){return yt({queryKey:VZ,queryFn:UZ,enabled:e,refetchInterval:15e3,initialData:n})}function GZ(e){return yt({...u1({client:W,path:{id:e??""}}),enabled:!!e,refetchInterval:n=>{const i=n.state.data?.status;return i==="running"||i==="queued"?3e3:!1}})}function g1(){const e=Ts(),n=HS({strict:!1}),i=u5({select:v=>v.location.pathname}),r=n.runId??null,u=n.evidenceId??null;return{runId:r,evidenceId:u,openRun:v=>{e({to:i,from:Gn.to,search:x=>({...x,runId:v,evidenceId:void 0})})},openEvidence:v=>{e({to:i,from:Gn.to,search:x=>({...x,evidenceId:v,runId:void 0})})},closeDrawer:()=>{e({to:i,from:Gn.to,search:v=>({...v,runId:void 0,evidenceId:void 0})})}}}const KZ={negative:"toast-card-negative",caution:"toast-card-caution",positive:"toast-card-positive",neutral:"toast-card-neutral"};function HZ(e){if(e.cta)return`${e.cta.label}: ${e.title}`}function QZ(){const e=C.useSyncExternalStore(PK,tS,tS),n=Ts(),{openRun:i}=g1(),r=C.useCallback(h=>{dg(h)},[]),u=C.useCallback(h=>{h.cta&&(h.cta.intent==="open-run-drawer"?i(h.cta.runId):n({to:"/runs"}),dg(h.id))},[n,i]);return e.length===0?null:l.jsx("div",{className:"toast-viewport","aria-label":"Notifications",children:e.map(h=>l.jsxs("section",{role:h.tone==="negative"?"alert":"status","aria-live":h.tone==="negative"?"assertive":"polite","data-state":h.state,className:`toast-card ${KZ[h.tone]}`,children:[l.jsxs("div",{className:"toast-copy",children:[l.jsx("p",{className:"toast-title",children:h.title}),h.detail?l.jsx("p",{className:"toast-detail",children:h.detail}):null,h.cta?l.jsx("button",{type:"button",className:"toast-action",onClick:()=>u(h),"aria-label":HZ(h),children:h.cta.label}):null]}),l.jsx("button",{type:"button",onClick:()=>r(h.id),className:"toast-dismiss","aria-label":"Dismiss",children:l.jsx(Hr,{className:"size-3.5"})})]},h.id))})}const FZ="https://github.com/Canonry/canonry",ZZ="https://canonry.ai",kS="Run it from your agent with the MCP server, API, CLI, and plugins for Claude Code and Codex.",YZ=[{title:"Visibility",links:[["AI visibility","/projects/summit-roofing"],["Search engines","/projects/summit-roofing/search-console"],["Traffic & conversions","/projects/summit-roofing/conversions"],["Reports","/projects/harbor-resorts/report"]]},{title:"Portfolio",links:[["Properties & markets","/projects/harbor-resorts"],["Queries & research","/projects/harbor-resorts/queries"],["Activity","/projects/harbor-resorts/activity"]]},{title:"Website",links:[["Site health","/projects/summit-roofing/technical-aeo"],["Local presence","/projects/summit-roofing/local"],["Backlinks","/projects/summit-roofing/backlinks"]]}];function XZ(){const e=C.useId();if(!zr())return null;const n=Dm(),i=`${e}-new-tab`,r={target:"_blank",rel:"noopener noreferrer","aria-describedby":i};return l.jsxs("aside",{className:"demo-banner","aria-label":"Public demo",children:[l.jsx("p",{className:"demo-banner-name",children:"Canonry demo"}),l.jsx("p",{className:"demo-banner-facts",children:"View only. Fictional data."}),l.jsx("p",{className:"demo-banner-agent",children:kS}),l.jsxs("div",{className:"demo-banner-actions",children:[l.jsxs("a",{className:"demo-banner-primary",href:ZZ,...r,children:["canonry.ai",l.jsx(ek,{"aria-hidden":"true",size:14})]}),l.jsxs("a",{className:"demo-banner-secondary",href:FZ,...r,children:[l.jsx(tk,{"aria-hidden":"true",size:15}),"GitHub"]}),l.jsxs("details",{onKeyDown:u=>{u.key==="Escape"&&(u.currentTarget.open=!1,u.currentTarget.querySelector("summary")?.focus())},children:[l.jsxs("summary",{children:["Explore ",l.jsx(Rc,{"aria-hidden":"true",size:14})]}),l.jsxs("div",{className:"demo-banner-panel",children:[l.jsx("p",{className:"demo-banner-panel-agent",children:kS}),l.jsxs("nav",{className:"demo-banner-examples","aria-label":"Demo examples",children:[l.jsx("a",{href:`${n}/projects/summit-roofing`,children:"Standard business"}),l.jsx("a",{href:`${n}/projects/harbor-resorts`,children:"Property portfolio"})]}),l.jsx("nav",{className:"demo-banner-features","aria-label":"Demo feature directory",children:YZ.map(({title:u,links:h})=>l.jsxs("section",{"aria-label":u,children:[l.jsx("h2",{children:u}),l.jsx("ul",{children:h.map(([f,b])=>l.jsx("li",{children:l.jsx("a",{href:`${n}${b}`,children:f})},b))})]},u))})]})]})]}),l.jsx("span",{id:i,hidden:!0,children:"Opens in a new tab"})]})}function bc(e){switch(e){case Re["answer-visibility"]:return"Visibility sweep";case Re["gsc-sync"]:return"GSC sync";case Re["inspect-sitemap"]:return"Sitemap inspection";case Re["ga-sync"]:return"GA sync";case Re["traffic-sync"]:return"Traffic sync";case Re["bing-inspect"]:return"Bing URL inspection";case Re["bing-inspect-sitemap"]:return"Bing sitemap inspection";case Re["site-audit"]:return"Technical audit";case Re["backlink-extract"]:return"Backlink extract";case Re["aeo-discover-seed"]:return"Discovery (seed phase)";case Re["aeo-discover-probe"]:return"Discovery (probe phase)";case Re["gbp-sync"]:return"Business Profile sync";case Re["ads-sync"]:return"ChatGPT ads sync";case Re["google-ads-sync"]:return"Google Ads sync";case Re["gtm-sync"]:return"Tag Manager sync"}}function jS(e){return e==="running"?"Running":e==="queued"?"Queued":e==="partial"?"Partial":e==="completed"?"Completed":e==="failed"?"Failed":e==="cancelled"?"Cancelled":"Starting"}function JZ(){const e=C.useSyncExternalStore(pC,Vi,Vi),n=C.useMemo(()=>Object.values(e.runs),[e.runs]),i=n.length>0,r=yt({...zm({client:W}),enabled:i,staleTime:Gr}),u=C.useMemo(()=>new Map((r.data??[]).map(b=>[b.id,b.status])),[r.data]);if(!i)return null;const h=n.map(b=>({...b,status:u.get(b.runId)??b.lastAnnouncedStatus})),f=h.length===1?bc(h[0].kind):`${h.length} active tasks`;return l.jsxs("div",{className:"task-center",children:[l.jsxs("p",{className:"sr-only",role:"status","aria-live":"polite",children:[h.length," active ",h.length===1?"task":"tasks","."," ",h.map(b=>`${bc(b.kind)} ${jS(b.status)}`).join(". "),"."]}),l.jsxs("details",{className:"task-center-details",children:[l.jsxs("summary",{className:"task-center-trigger",children:[l.jsx(Ir,{className:"size-3.5 shrink-0 motion-safe:animate-spin","aria-hidden":"true"}),l.jsx("span",{className:"task-center-summary",children:f}),l.jsx("span",{className:"task-center-count","aria-hidden":"true",children:h.length}),l.jsx(Rc,{className:"task-center-chevron size-3.5 shrink-0","aria-hidden":"true"})]}),l.jsxs("div",{className:"task-center-panel",children:[l.jsxs("div",{className:"task-center-heading",children:[l.jsx("span",{children:"Active tasks"}),l.jsx("span",{className:"tabular-nums text-faint",children:h.length})]}),l.jsx("ul",{className:"task-center-list",children:h.map(b=>l.jsxs("li",{className:"task-center-item",children:[l.jsxs("div",{className:"min-w-0",children:[l.jsx("p",{className:"truncate text-[13px] font-medium text-strong",children:bc(b.kind)}),l.jsx("p",{className:"mt-0.5 truncate text-xs text-muted",children:b.projectLabel??b.projectId})]}),l.jsx(xn,{tone:b.status==="failed"?"negative":b.status==="partial"?"caution":"neutral",children:jS(b.status)})]},b.runId))}),l.jsx(We,{to:"/runs",className:"task-center-footer-link",children:"View all runs"})]})]})]})}const y1={queryClass:"all"},WZ=["all","non-brand","branded"];function PC(e){return typeof e=="string"&&WZ.includes(e)}function eY(e){const n=PC(e.class)?e.class:y1.queryClass,i=e.scope;if(typeof i!="string"||i==="all"||i.length===0)return{scope:"all",queryClass:n};const r=i.startsWith("group:")?i.slice(6):"";return r?{scope:"group",groupKey:r,queryClass:n}:{scope:"all",queryClass:n}}function pse(e,n){return n===null||e===null?!1:e!==n}function hse(e){return{scope:e.scope==="group"&&e.groupKey?`group:${e.groupKey}`:void 0,class:e.queryClass===y1.queryClass?void 0:e.queryClass}}function tY(e,n){if(!(typeof e!="string"||e.length>16384||!n))try{const i=JSON.parse(e);if(typeof i!="object"||i===null||Array.isArray(i))return;const r=i,u=f=>typeof f=="string"&&f.trim().length>0,h=f=>f===null||u(f);return r.queryKey!==n||!u(r.provider)||r.queryClass!=="branded"&&r.queryClass!=="non-brand"&&r.queryClass!=="unknown"||!h(r.model)||!h(r.location)||!h(r.runId)||r.revision!==null&&(typeof r.revision!="number"||!Number.isSafeInteger(r.revision)||r.revision<=0)?void 0:{queryKey:n,queryClass:r.queryClass,provider:r.provider,model:r.model,location:r.location,runId:r.runId,revision:r.revision}}catch{return}}function nY(e){const n=x=>typeof e[x]=="string"&&e[x]!==""?e[x]:void 0,i=eY({scope:n("scope"),class:n("class")}),r=n("measurementScope")??(i.scope==="group"?"group":"project"),u=n("measurementScopeKey")??(n("measurementScope")?void 0:i.groupKey),h=n("queryClass")??n("class"),f={measurementScope:u&&(r==="group"||r==="market"||r==="property")?r:"project",queryClass:h==="unknown"||PC(h)?h:y1.queryClass};f.measurementScope!=="project"&&(f.measurementScopeKey=u);for(const[x,S]of[["measurementMarketKey","marketKey"],["measurementProvider","provider"],["measurementModel","model"],["measurementLocation","location"],["measurementFrom","from"],["measurementTo","to"],["measurementRunId","measurementRunId"],["measurementQueryKey","queryKey"]]){const k=n(x);k!==void 0&&(f[S]=k)}const b=Number(e.measurementRevision);Number.isSafeInteger(b)&&b>0&&(f.revision=b);const v=tY(e.measurementAnswer,f.queryKey);return v&&(f.answer=v),f}function aY(e){return{scope:e.measurementScope,scopeKey:e.measurementScopeKey,marketKey:e.marketKey,queryClass:e.queryClass,provider:e.provider,model:e.model,location:e.location,from:e.from,to:e.to,revision:e.revision,runId:e.measurementRunId,limit:25}}function fse(e,n){const i={...e,...n};return["measurementScope","measurementScopeKey","measurementMarketKey","queryClass","measurementProvider","measurementModel","measurementLocation","measurementFrom","measurementTo","measurementRevision","measurementRunId"].some(r=>r in n)?(i.measurementQueryKey=n.measurementQueryKey,i.measurementAnswer=n.measurementAnswer):"measurementQueryKey"in n&&!("measurementAnswer"in n)&&(i.measurementAnswer=void 0),"measurementScope"in n&&(i.scope=void 0,"measurementMarketKey"in n||(i.measurementMarketKey=void 0),i.measurementQueryKey=void 0,n.measurementScope==="project"&&(i.measurementScopeKey=void 0)),"queryClass"in n&&(i.class=void 0),i}function gse(e){return{...e,onboarding:void 0,manageQueries:void 0,siteHealthRunId:void 0,siteScan:void 0,setupProject:void 0}}function iY(e,n){const i=/\/properties\/([^/]+)/.exec(e),r=nY(n);if(i)return{view:"property",selection:Ld.parse({scope:"property",scopeKey:decodeURIComponent(i[1]),queryClass:r.queryClass,limit:10})};if(e.endsWith("/technical-aeo"))return{view:"site-health"};if(e.endsWith("/queries")&&n.queryWorkspace==="research")return{view:"project"};const u=/^\/projects\/[^/]+\/?$/.test(e);if(u||e.endsWith("/queries")){const h=Ld.safeParse(aY(e.endsWith("/queries")?{measurementScope:r.measurementScope,measurementScopeKey:r.measurementScopeKey,queryClass:r.queryClass}:r));return{view:u?"visibility":"queries",...h.success?{selection:h.data}:{unavailableReason:"The current measurement filters are invalid. Correct them before asking Aero about this view."}}}return{view:"project"}}function sY(e,n={}){const{threshold:i=80}=n,r=C.useRef(null),u=C.useRef({scrollHeight:0,wasAtEnd:!0});function h(v){return v.scrollHeight-v.scrollTop-v.clientHeight}function f(){const v=r.current;return v?h(v)<=i:!0}function b(){const v=r.current;v&&(v.scrollTop=v.scrollHeight,u.current.wasAtEnd=!0,u.current.scrollHeight=v.scrollHeight)}return C.useEffect(()=>{const v=r.current;if(!v)return;const x=()=>{u.current.wasAtEnd=h(v)<=i};return v.addEventListener("scroll",x,{passive:!0}),()=>v.removeEventListener("scroll",x)},[i]),C.useLayoutEffect(()=>{const v=r.current;if(!v)return;const x=v.scrollHeight;x>u.current.scrollHeight&&u.current.wasAtEnd&&(v.scrollTop=x),u.current.scrollHeight=x},e),C.useEffect(()=>{const v=r.current;if(!v||typeof ResizeObserver>"u")return;const x=new ResizeObserver(()=>{const S=v.scrollHeight;S>u.current.scrollHeight&&u.current.wasAtEnd&&(v.scrollTop=S),u.current.scrollHeight=S});return x.observe(v),v.firstElementChild&&x.observe(v.firstElementChild),()=>x.disconnect()},[]),{ref:r,scrollToEnd:b,isAtEnd:f}}const bg="Sweeps are run by your Canonry team",oY="Scans are run by your Canonry team",AS="Next sweep unavailable",rY="Sweep running…",lY="Next sweep:";function cY(e,n){try{return new Intl.DateTimeFormat("en-US",{month:"short",day:"numeric",timeZone:n??"UTC"}).format(new Date(e))}catch{return null}}function uY({projectName:e,kind:n=Re["answer-visibility"],running:i=!1,loadSchedule:r=!0}){const u=n===Re["site-audit"],h=yt({...zH({client:W,path:{name:e},query:{kind:n}}),enabled:r&&!!e,retry:!1,refetchInterval:6e4}),f=h.isError?void 0:h.data,b=f?.enabled&&f.nextRunAt?new Date(f.nextRunAt):null,v=b&&Number.isFinite(b.getTime())?u?b.toLocaleString("en-GB",{weekday:"long",day:"numeric",month:"short",hour:"2-digit",minute:"2-digit",timeZone:"UTC",hourCycle:"h23"}):cY(b.toISOString(),f?.timezone):null,S=(h.error instanceof Sn?h.error.code:h.error?.error?.code)==="NOT_FOUND",k=!v||S||!f?.enabled;return l.jsx("p",{className:"text-sm text-secondary",role:"status",children:u?l.jsxs(l.Fragment,{children:[i&&l.jsx("span",{className:"text-neutral",children:"Scan running… · "}),v&&b?l.jsxs(l.Fragment,{children:["Next scan ",l.jsxs("time",{dateTime:b.toISOString(),children:[v," UTC"]})," · managed by your Canonry team"]}):oY]}):i?rY:k?AS:v&&b?l.jsxs(l.Fragment,{children:[lY," ",l.jsx("time",{dateTime:b.toISOString(),children:v})]}):AS})}const dY=300,mY=400,pY=900,hY=32,CS=28;let fY=0;function gY(){return typeof window>"u"||typeof window.matchMedia!="function"?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches}function vg(){return new DOMException("Preview stopped","AbortError")}function yY(e,n){return n?.aborted?Promise.reject(vg()):new Promise((i,r)=>{const u=()=>{clearTimeout(h),r(vg())},h=setTimeout(()=>{n?.removeEventListener("abort",u),i()},e);n?.addEventListener("abort",u,{once:!0})})}function bY(e){const n=e.match(/\S+\s*|\s+/g)??[];if(n.length<2)return[];const i=Math.ceil(n.length/hY),r=[];for(let u=i;u<n.length;u+=i)r.push(n.slice(0,u).join(""));return r}function vY(e){return typeof e=="string"?e:JSON.stringify(e??null)}async function xY({starter:e,signal:n,onEvent:i,reducedMotion:r=!1}){const u=async b=>{if(n?.aborted)throw vg();r||await yY(b,n)},h=Date.now(),f=++fY;await u(dY);for(const[b,v]of e.steps.entries()){const{name:x,label:S,arguments:k,result:T,durationMs:N}=v.tool,I=`preview-${e.id}-${f}-${b}`,P={role:"assistant",timestamp:Date.now(),stopReason:"toolUse",content:[...v.text?[{type:"text",text:v.text}]:[],{type:"toolCall",id:I,name:x,arguments:k}]};i({type:"message_end",message:P}),i({type:"tool_execution_start",toolCallId:I,toolName:x,label:S,args:k}),await u(Math.min(pY,Math.max(mY,N))),i({type:"tool_execution_end",toolCallId:I,toolName:x,result:T,isError:!1});const E={role:"toolResult",toolCallId:I,timestamp:Date.now(),isError:!1,aeroToolLabel:S,aeroDurationMs:N,content:[{type:"text",text:vY(T)}]};i({type:"message_end",message:E})}if(!r){for(const b of bY(e.answer))await u(CS),i({type:"message_update",message:{role:"assistant",content:[{type:"text",text:b}]},assistantMessageEvent:{}});await u(CS)}i({type:"message_end",message:{role:"assistant",timestamp:Date.now(),stopReason:"stop",content:[{type:"text",text:e.answer}]}}),i({type:"aero_turn_status",status:{reason:"completed",toolCalls:e.steps.length,modelCalls:e.steps.length+1,durationMs:Date.now()-h}})}async function Bm(e){try{return await e.json()}catch{return{}}}function wY(){return typeof window<"u"&&window.__CANONRY_CONFIG__?.basePath?window.__CANONRY_CONFIG__.basePath.replace(/\/$/,"")+"/api/v1":"/api/v1"}const Lm=wY();function $m(e){e===401&&s1()}async function Tf(e){const n=await fetch(`${Lm}/projects/${encodeURIComponent(e)}/agent/transcript`,{credentials:"include"});if(!n.ok){$m(n.status);const i=await Bm(n);throw new Sn(i.error?.message??`transcript fetch failed: ${n.status}`,n.status,i.error?.code)}return await n.json()}async function SY(e){const n=await fetch(`${Lm}/projects/${encodeURIComponent(e)}/agent/preview`,{credentials:"include"});if(!n.ok){$m(n.status);const i=await Bm(n);throw new Sn(i.error?.message??`preview fetch failed: ${n.status}`,n.status,i.error?.code)}return await n.json()}async function kY(e){const n=await fetch(`${Lm}/projects/${encodeURIComponent(e)}/agent/transcript`,{method:"DELETE",credentials:"include"});if(!n.ok){$m(n.status);const i=await Bm(n);throw new Sn(i.error?.message??`reset failed: ${n.status}`,n.status,i.error?.code)}}async function jY({project:e,prompt:n,conversationId:i,provider:r,modelId:u,scope:h,profile:f,context:b,limits:v,signal:x,onEvent:S}){const k={prompt:n};i!==void 0&&(k.conversationId=i),r&&(k.provider=r),u&&(k.modelId=u),h&&(k.scope=h),f&&(k.profile=f),b&&(k.context=b),v&&(k.limits=v);const T=await fetch(`${Lm}/projects/${encodeURIComponent(e)}/agent/prompt`,{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify(k),signal:x});if(!T.ok||!T.body){$m(T.status);const ee=await Bm(T);throw new Sn(ee.error?.message??`prompt failed: ${T.status}`,T.status,ee.error?.code)}let N=!1;const I=T.body.getReader(),P=new TextDecoder;let E="";const $=()=>{I.cancel().catch(()=>{})};x?.addEventListener("abort",$,{once:!0}),x?.aborted&&$();try{for(;;){const{value:ee,done:L}=await I.read();if(L)break;E+=P.decode(ee,{stream:!0});let F=E.indexOf(`
|
|
59
|
+
|
|
60
|
+
`);for(;F!==-1;){const Z=E.slice(0,F);E=E.slice(F+2);for(const ae of Z.split(`
|
|
61
|
+
`)){if(!ae.startsWith("data:"))continue;const M=ae.slice(5).trim();if(!M)continue;let Y;try{Y=JSON.parse(M)}catch{continue}Y.type==="stream_close"&&(N=!0),S(Y)}F=E.indexOf(`
|
|
62
|
+
|
|
63
|
+
`)}}if(x?.aborted)throw new DOMException("Turn stopped","AbortError");if(!N)throw new Error("Connection ended before Aero finished. Review the partial answer before retrying.")}finally{x?.removeEventListener("abort",$);try{I.releaseLock()}catch{}}}function Ed(e){return!e||e.role!=="assistant"?"":e.content.filter(n=>n.type==="text").map(n=>n.text).join("")}const xg=[{id:"status",label:"Status",prompt:"Give me a quick status: the latest sweep, which engines answered, and anything that needs attention."},{id:"changes",label:"What changed",prompt:"Compare the latest complete sweep with the one before it. Lead with mentions, then citations. Keep branded and non-brand queries separate if the project splits them, and say which changes are bigger than normal run-to-run noise."},{id:"gaps",label:"Biggest gaps",prompt:"Which tracked queries does no engine mention us on, and who gets named instead? Group them by topic or market."},{id:"insights",label:"Top insights",prompt:"Walk me through the 3 most severe active insights and what to do about each."}],AY="https://canonry.ai",CY="This demo plays sample answers only. Pick a starting point, or type / to choose one.",NY="Stopped. The sample answer so far is kept.";function NS(e){return{queryKey:["aero-preview",e],queryFn:()=>SY(e),staleTime:1/0,gcTime:1/0}}const _S=[{command:"/status",label:"Status",prompt:"Give me a quick status: the latest sweep, which engines answered, and anything that needs attention."},{command:"/changes",label:"What changed",prompt:"Compare the latest complete sweep with the one before it. Lead with mentions, then citations. Keep branded and non-brand queries separate if the project splits them, and say which changes are bigger than normal run-to-run noise."},{command:"/gaps",label:"Biggest gaps",prompt:"Which tracked queries does no engine mention us on, and who gets named instead? Group them by topic or market."},{command:"/insights",label:"Top insights",prompt:"Walk me through the 3 most severe active insights and what to do about each."},{command:"/last-run",label:"Last run",prompt:"Summarize the latest run for this project: which engines answered, what moved in mentions and citations, and anything that failed."},{command:"/run-sweep",label:"Run sweep now",prompt:"Run a new answer-visibility sweep for this project now and tell me when it lands."},{command:"/queries",label:"Queries",prompt:"List the tracked queries for this project and flag any that are obvious duplicates or underperformers."},{command:"/competitors",label:"Competitors",prompt:"Which competitors do engines name most often on queries where we are not named, and on which engines?"},{command:"/new",label:"New conversation (save current)",action:"new"}],vd=e=>`canonry:aero:provider:${e}`,_Y=e=>`canonry:aero:scope:${e}`;function TS(e){if(typeof window>"u")return null;try{return window.localStorage.getItem(e)}catch{return null}}function TY(e,n){if(!(typeof window>"u"))try{window.localStorage.setItem(e,n)}catch{}}function ES(e){if(!(typeof window>"u"))try{window.localStorage.removeItem(e)}catch{}}function EY({projectName:e,context:n,preview:i=a1()}){const r=vo(),{canWrite:u,account:h}=fa(),f=ta(),b=h?.role==="viewer",[v,x]=C.useState(!1),[S,k]=C.useState(!1),[T,N]=C.useState([]),[I,P]=C.useState(void 0),E=C.useRef(!1),[$,ee]=C.useState(!1),[L,F]=C.useState(!1),[Z,ae]=C.useState(null),[M,Y]=C.useState(!1),[ue,Xe]=C.useState(!1),[nt,Ge]=C.useState(null),Pe=C.useRef(!1),[Se,Ve]=C.useState(""),[q,X]=C.useState(!1),[ve,ke]=C.useState([]),[J,Ne]=C.useState(""),[Me,xe]=C.useState(null),[le,re]=C.useState(null),[H,pe]=C.useState(null),ze=C.useRef(!0),[je,it]=C.useState(()=>TS(vd(e))??null),Ue=r||b||i?null:je,[jt]=C.useState(()=>TS(_Y(e))==="all"?"all":"read-only"),He=r||b||i?"read-only":jt,me=C.useRef(null),ot=C.useRef(null),It=C.useRef(null),Bn=C.useRef(null),{ref:Kt}=sY([T,J,ve]),Be=C.useRef(null);C.useLayoutEffect(()=>{const oe=Be.current;if(!oe)return;oe.style.height="auto";const Ie=S?zY:DY;oe.scrollHeight>0&&(oe.style.height=`${Math.min(oe.scrollHeight,Ie)}px`)},[Se,S,v]);const[ct,Ht]=C.useState(0),Qt=C.useMemo(()=>{const oe=Se.trimStart();if(!oe.startsWith("/"))return[];if(/\s/.test(oe))return[];const Ie=oe.toLowerCase();return _S.filter(Ye=>(!(r||b)||Ye.command!=="/run-sweep")&&(!b||Ye.action!=="new")&&(!i||xg.some(Ft=>Ft.prompt===Ye.prompt))&&(Ye.command.startsWith(Ie)||Ye.label.toLowerCase().includes(Ie.slice(1))))},[Se,r,b,i]);C.useEffect(()=>{Ht(oe=>Qt.length===0?0:Math.min(oe,Qt.length-1))},[Qt.length]);const zn=yt({...HQ({client:W,path:{name:e}}),enabled:!b&&!i,staleTime:6e4}),$t=C.useMemo(()=>{const oe=zn.data?.providers??[];if(Ue){const Ye=oe.find(Ft=>Ft.id===Ue&&Ft.configured);if(Ye)return Ye}const Ie=zn.data?.defaultProvider;return Ie?oe.find(Ye=>Ye.id===Ie)??null:null},[Ue,zn.data]),mi=b||i||$t!==null;yt({...NS(e),enabled:i&&v}),C.useEffect(()=>{if(!zn.data||!Ue)return;zn.data.providers.find(Ie=>Ie.id===Ue&&Ie.configured)||(it(null),ES(vd(e)))},[zn.data,Ue,e]);const Bs=C.useCallback(oe=>{it(oe),oe?TY(vd(e),oe):ES(vd(e))},[e]);C.useEffect(()=>{if(!v)return;const oe=Ie=>{Ie.key==="Escape"&&(L?F(!1):S?k(!1):x(!1))};return window.addEventListener("keydown",oe),()=>window.removeEventListener("keydown",oe)},[v,S,L]),C.useEffect(()=>{if(!v||!mi||i)return;let oe=!1;xe(null);const Ie=()=>{oe||q||Pe.current||Tf(e).then(st=>{oe||Pe.current||(Xe(st.isStreaming??!1),P(st.conversationId??null),!oe&&!st.isStreaming&&(ot.current===null||st.updatedAt&&st.updatedAt!==ot.current.previous)&&(N(st.messages),me.current=st.updatedAt,ot.current=null))}).catch(st=>{oe||xe(Oi(st))})};Ie();const Ft=window.setInterval(Ie,15e3);return()=>{oe=!0,window.clearInterval(Ft)}},[v,e,q,mi,M,i]),C.useEffect(()=>(ze.current=!0,()=>{ze.current=!1,Bn.current?.abort()}),[e]);async function Hn(oe,Ie=n){const Ye=oe.trim();if(!Ye||L||q||M||Pe.current||ue||!mi)return;if(i){await pi(Ye);return}if(r&&/^\/run-sweep(?:\s|$)/i.test(Ye)){xe(bg);return}xe(null),re(null),pe({prompt:Ye,context:Ie}),Ve(""),X(!0),Ne(""),It.current=null,ke([]),ot.current={previous:me.current};const Ft={role:"user",content:Ye,timestamp:Date.now(),aeroContext:Ie};N(et=>[...et,Ft]);const st=new AbortController;Bn.current=st;try{await jY({project:e,prompt:Ye,conversationId:I,provider:Ue??void 0,scope:He,context:Ie,signal:st.signal,onEvent:Ls});const et=await Tf(e);ze.current&&!et.isStreaming&&(P(et.conversationId??null),N(et.messages),me.current=et.updatedAt,ot.current=null)}catch(et){if(!ze.current)return;b&&(ot.current=null);const Wt=It.current;Wt&&Ed(Wt).trim()&&N(Xa=>[...Xa,Wt]),st.signal.aborted?re("Stopped. Partial response preserved. An action already dispatched may still finish."):xe(Oi(et))}finally{ze.current&&(X(!1),Ne(""),ke(et=>et.map(Wt=>Wt.endedAt===void 0?{...Wt,interrupted:!0}:Wt))),Bn.current=null}}async function pi(oe){const Ie=_S.find(st=>st.command===oe.toLowerCase())?.prompt??oe,Ye=xg.find(st=>st.prompt===Ie)?.id;if(!Ye){xe(null),pe(null),re(CY);return}xe(null),re(null),pe({prompt:Ie}),Ve(""),X(!0),Ne(""),It.current=null,ke([]),N(st=>[...st,{role:"user",content:Ie,timestamp:Date.now()}]);const Ft=new AbortController;Bn.current=Ft;try{const st=await f.ensureQueryData(NS(e));if(Ft.signal.aborted)throw new DOMException("Preview stopped","AbortError");const et=st.starters.find(Wt=>Wt.id===Ye);if(!et)throw new Error("This demo has no sample answer for that starting point.");await xY({starter:et,signal:Ft.signal,onEvent:Ls,reducedMotion:gY()})}catch(st){if(!ze.current)return;const et=It.current;et&&Ed(et).trim()&&N(Wt=>[...Wt,et]),Ft.signal.aborted?re(NY):xe(Oi(st))}finally{ze.current&&(X(!1),Ne(""),ke(st=>st.map(et=>et.endedAt===void 0?{...et,interrupted:!0}:et))),Bn.current=null}}function Ls(oe){if(ze.current)switch(oe.type){case"message_update":oe.message.role==="assistant"&&(It.current=oe.message),Ne(Ed(oe.message));break;case"message_end":if(oe.message.role!=="user"){const Ie=oe.message;N(Ye=>[...Ye,Ie])}oe.message.role==="assistant"&&(It.current=null,Ne(""),oe.message.errorMessage&&xe(oe.message.errorMessage));break;case"aero_turn_status":oe.status?.reason==="tool-limit"?re("Tool-call limit reached. Partial response preserved."):oe.status?.reason==="time-limit"?re("Time limit reached. Partial response preserved."):oe.status?.reason==="completed"&&pe(null);break;case"tool_execution_start":ke(Ie=>[...Ie,{id:oe.toolCallId,name:oe.toolName,label:oe.label,args:oe.args,startedAt:Date.now()}]);break;case"tool_execution_end":ke(Ie=>Ie.map(Ye=>Ye.id===oe.toolCallId?{...Ye,endedAt:Date.now(),isError:oe.isError,result:oe.result}:Ye));break;case"error":xe(oe.message);break}}async function Ki(oe,Ie=!1){if(!(q||ue||Pe.current)){Pe.current=!0,Y(!0),xe(null);try{await oe();const Ye=await Tf(e);if(!ze.current)return;ot.current=null,me.current=Ye.updatedAt,P(Ye.conversationId??null),N(Ye.messages),ke([]),Ne(""),re(null),pe(null),Ge(null),F(Ie),ae(Ie?await Ww(e):null),Be.current?.focus()}catch(Ye){ze.current&&xe(Oi(Ye))}finally{Pe.current=!1,ze.current&&Y(!1)}}}async function Hi(){if(i){if(q)return;N([]),ke([]),Ne(""),xe(null),re(null),pe(null),Be.current?.focus();return}await Ki(()=>b?kY(e):vK(e,crypto.randomUUID()))}async function $s(oe=!1){if(!(Pe.current||E.current)){E.current=!0,ee(!0),F(!0),xe(null);try{const Ie=await Ww(e,{offset:oe?Z?.nextOffset??0:0});ze.current&&ae(Ye=>oe&&Ye?{...Ie,conversations:[...Ye.conversations,...Ie.conversations]}:Ie)}catch(Ie){ze.current&&xe(Oi(Ie))}finally{E.current=!1,ze.current&&ee(!1)}}}const yn=T.length===0,At=!(b||i);if(At&&zn.isPending)return null;if(At&&zn.isError)return l.jsx("div",{className:"pointer-events-none fixed inset-x-0 bottom-0 z-40 flex justify-center p-3",children:l.jsxs("div",{role:"status",className:"flex w-full max-w-3xl flex-wrap items-center gap-x-2 gap-y-1 rounded-lg border border-base bg-bg/95 px-4 py-2 text-sm shadow-lg",children:[l.jsx(id,{className:"h-4 w-4 text-muted","aria-hidden":"true"}),l.jsx("span",{className:"font-medium text-strong",children:"Aero could not check provider availability."}),l.jsx(ce,{variant:"outline",size:"sm",className:"pointer-events-auto ml-auto",onClick:()=>{zn.refetch()},children:"Try again"})]})});const bn=$t&&!$t.configured?$t:null;if(At&&(!$t||bn))return l.jsx("div",{className:"pointer-events-none fixed inset-x-0 bottom-0 z-40 flex justify-center p-3",children:l.jsxs("div",{role:"status",className:"flex w-full max-w-3xl flex-wrap items-center gap-x-2 gap-y-1 rounded-lg border border-base bg-bg/95 px-4 py-2 text-sm shadow-lg",children:[l.jsx(id,{className:"h-4 w-4 text-muted","aria-hidden":"true"}),l.jsxs("span",{className:"flex items-center gap-1.5 font-medium text-strong",children:[bn?`Aero is set to ${bn.label.replace(/\s+\(.+\)$/,"")}, which has no API key.`:"Aero needs an answer-engine provider.",l.jsx(Ea,{text:bn?`Set ${MC(bn.id)} on the server, or providers.${bn.id}.apiKey in its config.yaml.`:"Aero is the built-in AEO analyst. It reads your Canonry data with you once a provider is connected."})]}),bn?null:u?l.jsx(ce,{asChild:!0,variant:"outline",size:"sm",className:"pointer-events-auto ml-auto",children:l.jsx(We,{to:"/settings",children:"Open Settings"})}):l.jsx("span",{className:"ml-auto text-secondary",children:"Ask an administrator to configure one."})]})});const An=v&&S?"pointer-events-auto fixed inset-0 z-40 flex items-stretch justify-center bg-bg/70 p-4 sm:p-8 backdrop-blur-sm":"pointer-events-none fixed inset-x-0 bottom-0 z-40 flex justify-center p-3",Vs=S?"pointer-events-auto flex h-full w-full max-w-5xl flex-col overflow-hidden rounded-2xl border border-mono-800/80 bg-bg/95 shadow-2xl":"pointer-events-auto w-full max-w-3xl",ya=S?"flex-1 overflow-y-auto px-6 py-5 text-sm text-strong":"max-h-[40vh] min-h-[120px] overflow-y-auto px-4 py-3 text-sm text-strong";return l.jsx("div",{className:An,onClick:oe=>{S&&oe.target===oe.currentTarget&&k(!1)},children:l.jsx("div",{className:Vs,children:v?l.jsxs("div",{"data-aero-panel":!0,className:S?"flex h-full flex-col":"flex flex-col overflow-hidden rounded-2xl border border-mono-800/80 bg-bg/95 shadow-xl backdrop-blur",children:[l.jsxs("div",{className:"flex items-center justify-between gap-2 border-b border-mono-800/70 px-4 py-2.5",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(id,{className:"h-4 w-4 text-positive-400","aria-hidden":"true"}),l.jsx("span",{className:"text-sm font-medium text-heading",children:"Aero"}),l.jsx("span",{className:"text-[10px] uppercase tracking-wider text-muted",children:q||ue?"working…":e})]}),l.jsxs("div",{className:"flex items-center gap-1",children:[!r&&!b&&!i&&l.jsx(RY,{providers:zn.data?.providers??[],active:$t,override:Ue,onPick:Bs,disabled:q}),l.jsx("button",{type:"button",onClick:()=>k(oe=>!oe),className:"rounded-md p-1.5 text-muted transition hover:bg-surface-inset hover:text-strong","aria-label":S?"Collapse":"Expand",title:S?"Collapse":"Expand",children:S?l.jsx(g5,{className:"h-3.5 w-3.5","aria-hidden":"true"}):l.jsx(y5,{className:"h-3.5 w-3.5","aria-hidden":"true"})}),l.jsx("button",{type:"button",onClick:()=>{k(!1),x(!1)},className:"rounded-md p-1.5 text-muted transition hover:bg-surface-inset hover:text-strong","aria-label":"Close Aero",children:l.jsx(Hr,{className:"h-4 w-4","aria-hidden":"true"})})]})]}),l.jsxs("div",{className:"flex flex-wrap items-center gap-2 border-b border-subtle px-4 py-2",children:[l.jsxs(ce,{variant:"outline",size:"sm",disabled:q||ue||M,onClick:hn(Hi),title:b||i?"Clear this conversation and start fresh.":"Save this conversation and start fresh. Shared project notes are kept.",children:[l.jsx(If,{className:"h-3.5 w-3.5","aria-hidden":"true"})," New conversation"]}),!b&&!i&&l.jsxs(ce,{variant:"ghost",size:"sm","aria-expanded":L,"aria-controls":"aero-history",disabled:M,onClick:()=>{L?F(!1):$s()},children:[l.jsx(nk,{className:"h-3.5 w-3.5","aria-hidden":"true"})," History"]})]}),L?l.jsxs("div",{id:"aero-history",className:ya,"aria-label":"Conversation history",children:[l.jsxs("h3",{className:"mb-2 text-sm font-medium text-heading",children:["Conversations in ",e]}),Z?Z.conversations.length===0?l.jsx("p",{className:"text-sm text-secondary",children:"No saved conversations yet. Your conversations will appear here."}):l.jsx("ul",{className:"divide-y divide-default",children:Z.conversations.map(oe=>l.jsxs("li",{className:"py-2",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsxs("button",{className:"min-w-0 flex-1 rounded-md px-2 py-1 text-left hover:bg-surface-hover focus-visible:ring-2 focus-visible:ring-positive-500",disabled:q||ue||M,onClick:()=>{oe.active?F(!1):Ki(()=>xK(e,oe.id))},children:[l.jsx("span",{className:"block truncate text-sm text-heading",children:oe.title}),l.jsxs("span",{className:"text-xs text-secondary",children:[oe.active?"Current · ":"",new Date(oe.updatedAt).toLocaleString()]})]}),l.jsx(ce,{variant:"ghost",size:"sm",disabled:q||ue||M,"aria-label":`Delete conversation: ${oe.title}`,onClick:()=>Ge(oe.id),children:"Delete"})]}),nt===oe.id&&l.jsxs("div",{role:"group","aria-label":"Confirm conversation deletion",className:"mt-2 rounded-md border border-default p-3 text-sm text-secondary",children:[l.jsx("p",{children:"Delete this conversation permanently? Shared project notes will be kept."}),l.jsxs("div",{className:"mt-2 flex gap-2",children:[l.jsx(ce,{variant:"destructive",size:"sm",disabled:M,onClick:()=>{Ki(async()=>{await wK(e,oe.id)},!0)},children:"Delete conversation"}),l.jsx(ce,{variant:"ghost",size:"sm",disabled:M,onClick:()=>Ge(null),children:"Cancel"})]})]})]},oe.id))}):l.jsx("p",{className:"text-sm text-secondary",children:$?"Loading history…":"History could not be loaded. Close and reopen History to retry."}),Z?.nextOffset!=null&&l.jsx(ce,{variant:"ghost",size:"sm",disabled:$,onClick:()=>{$s(!0)},children:$?"Loading…":"Load more"})]}):l.jsxs("div",{ref:Kt,className:ya,children:[yn&&!q&&l.jsxs("div",{className:"flex flex-col gap-3 py-2",children:[l.jsx("p",{className:"text-sm text-secondary",children:i?l.jsxs(l.Fragment,{children:["See how Aero answers about ",l.jsx("span",{className:"text-strong",children:e}),". Choose a starting point."]}):l.jsxs(l.Fragment,{children:["Ask about ",l.jsx("span",{className:"text-strong",children:e})," or choose a starting point."]})}),l.jsx(RS,{onPick:oe=>{Hn(oe)}})]}),PY(T,e,Ue,He,ve,q,!b&&!i),q&&J&&l.jsxs("div",{className:"mt-3",children:[l.jsx("div",{className:"mb-0.5 text-[10px] uppercase tracking-wider text-positive-400",children:"Aero"}),l.jsx(BC,{content:J})]}),q&&!J&&ve.every(oe=>oe.endedAt!==void 0)&&l.jsx(VY,{}),i&&!yn&&!q&&l.jsxs("div",{className:"mt-4 flex flex-col gap-2 border-t border-subtle pt-3",children:[l.jsx("p",{className:"text-xs text-secondary",children:"Try another starting point."}),l.jsx(RS,{onPick:oe=>{Hn(oe)}})]})]}),(Me||le)&&l.jsxs("div",{role:Me?"alert":"status",className:"mx-3 my-2 flex flex-wrap items-center gap-2 rounded-md border border-base bg-surface px-3 py-2 text-sm text-secondary",children:[l.jsx("span",{className:"flex-1",children:Me??le}),H&&!q&&l.jsx(ce,{variant:"outline",size:"sm",onClick:()=>{He==="all"?(Ve(H.prompt),Be.current?.focus()):Hn(H.prompt,H.context)},children:He==="all"?"Review prompt":"Retry"})]}),i&&l.jsxs("p",{className:"border-t border-subtle px-4 py-2 text-xs text-secondary",children:["Sample answers on demo data."," ",l.jsxs("a",{href:AY,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-0.5 text-positive-400 underline decoration-positive-700 hover:decoration-positive-400",children:["Aero answers from your own Canonry data.",l.jsx(ek,{className:"h-3 w-3","aria-hidden":"true"}),l.jsx("span",{className:"sr-only",children:" (opens in a new tab)"})]})]}),l.jsxs("div",{className:"relative",children:[!L&&Qt.length>0&&l.jsx(OY,{title:i?"Starting points":"Commands",matches:Qt,selectedIndex:ct,onHover:Ht,onPick:oe=>{Ve(""),Be.current?.focus(),oe.action==="new"?Hi():Hn(oe.prompt)}}),l.jsxs("form",{className:"flex items-end gap-2 border-t border-mono-800/70 bg-bg/80 px-3 py-2.5",onSubmit:oe=>{if(oe.preventDefault(),Qt.length>0){const Ie=Qt[ct];Ve(""),Ie.action==="new"?Hi():Hn(Ie.prompt);return}Hn(Se)},children:[l.jsx("textarea",{ref:Be,value:Se,onChange:oe=>Ve(oe.target.value),onKeyDown:oe=>{if(Qt.length>0){if(oe.key==="ArrowDown"){oe.preventDefault(),Ht(Ie=>(Ie+1)%Qt.length);return}if(oe.key==="ArrowUp"){oe.preventDefault(),Ht(Ie=>(Ie-1+Qt.length)%Qt.length);return}if(oe.key==="Tab"){oe.preventDefault();const Ie=Qt[ct];Ve(`${Ie.command} `);return}if(oe.key==="Escape"){oe.preventDefault(),Ve("");return}}if(oe.key==="Enter"&&!oe.shiftKey)if(oe.preventDefault(),Qt.length>0){const Ie=Qt[ct];Ve(""),Ie.action==="new"?Hi():Hn(Ie.prompt)}else Hn(Se)},disabled:L||M,placeholder:L?"Open a conversation to continue…":i?"Type / for a starting point":"Ask Aero, or / for commands…","aria-label":"Message Aero",rows:S?3:1,className:"flex-1 resize-none overflow-y-auto bg-transparent text-sm text-heading placeholder:text-mono-600 focus:outline-none disabled:opacity-60"}),q?l.jsxs(ce,{type:"button",variant:"outline",size:"sm",onClick:()=>Bn.current?.abort(),"aria-label":"Stop Aero",children:[l.jsx(b5,{className:"h-3.5 w-3.5","aria-hidden":"true"})," Stop"]}):l.jsx(ce,{type:"submit",size:"sm",disabled:!Se.trim()||L||M||ue,"aria-label":"Send",children:l.jsx(v5,{className:"h-4 w-4","aria-hidden":"true"})})]})]})]}):l.jsx("button",{type:"button",onClick:()=>x(!0),className:"flex w-full items-center justify-between rounded-lg border border-mono-800/80 bg-bg/95 px-4 py-2 text-left text-sm text-secondary shadow-lg transition hover:border-strong hover:bg-bg-elevated/90 hover:text-strong",children:l.jsxs("span",{className:"flex items-center gap-2",children:[l.jsx(id,{className:"h-4 w-4 text-positive-400","aria-hidden":"true"}),"Ask Aero about ",e,"…"]})})})})}function RY({providers:e,active:n,override:i,onPick:r,disabled:u}){const[h,f]=C.useState(!1),b=C.useRef(null);if(C.useEffect(()=>{if(!h)return;const x=k=>{b.current?.contains(k.target)||f(!1)},S=k=>{k.key==="Escape"&&f(!1)};return window.addEventListener("mousedown",x),window.addEventListener("keydown",S),()=>{window.removeEventListener("mousedown",x),window.removeEventListener("keydown",S)}},[h]),e.length===0)return null;const v=n?.label.replace(/\s+\(.+\)$/,"")??"No provider";return l.jsxs("div",{ref:b,className:"relative",children:[l.jsxs("button",{type:"button",onClick:()=>f(x=>!x),disabled:u,className:"flex items-center gap-1 rounded-md px-2 py-1 text-sm text-secondary transition hover:bg-surface-inset hover:text-strong disabled:opacity-50","aria-label":"Switch agent model","aria-haspopup":"listbox","aria-expanded":h,title:n?`${n.label} · ${n.defaultModel}`:"Pick a provider",children:[l.jsx("span",{className:"font-medium text-strong",children:v}),l.jsx(Rc,{className:"h-3 w-3","aria-hidden":"true"})]}),h&&l.jsxs("div",{role:"listbox",className:"absolute right-0 top-full z-50 mt-1 w-64 overflow-hidden rounded-lg border border-base bg-bg shadow-xl",children:[l.jsx("div",{className:"border-b border-default px-3 py-2 text-sm font-medium text-secondary",children:"Answer engine"}),l.jsx("ul",{className:"max-h-72 overflow-y-auto py-1",children:e.map(x=>{const S=n?.id===x.id,k=i===x.id;return l.jsx("li",{children:l.jsxs("button",{type:"button",role:"option","aria-selected":S,disabled:!x.configured,onClick:()=>{x.configured&&(r(k?null:x.id),f(!1))},className:"flex w-full items-center gap-2 px-3 py-2.5 text-left text-sm transition enabled:hover:bg-bg-elevated disabled:cursor-not-allowed disabled:opacity-60",title:x.configured?x.defaultModel:`Add ${MC(x.id)} in Settings or your environment`,children:[l.jsx("span",{className:"flex h-4 w-4 shrink-0 items-center justify-center",children:S?l.jsx(im,{className:"h-3 w-3 text-positive-400","aria-hidden":"true"}):null}),l.jsx("span",{className:"min-w-0 flex-1 truncate font-medium text-heading",children:x.label.replace(/\s+\(.+\)$/,"")}),k&&l.jsx("span",{className:"rounded-md border border-positive-800/60 bg-positive-950/60 px-2 py-0.5 text-[11px] text-positive",children:"Selected"}),!x.configured&&l.jsx("span",{className:"rounded-md border border-base px-2 py-0.5 text-[11px] text-secondary",children:"Needs setup"})]})},x.id)})}),i&&l.jsx("button",{type:"button",onClick:()=>{r(null),f(!1)},className:"w-full border-t border-default px-3 py-2 text-left text-[11px] text-secondary transition hover:bg-bg-elevated hover:text-heading",children:"Reset to default"})]})]})}const DY=144,zY=288,Ef=288,IY=8;function OY({title:e,matches:n,selectedIndex:i,onHover:r,onPick:u}){const h=C.useRef(null),f=C.useRef(null),b=C.useRef(null),[v,x]=C.useState(Ef);return C.useLayoutEffect(()=>{const S=h.current,k=S?.closest("[data-aero-panel]"),T=S?.parentElement;if(!S||!k||!T)return;const N=T.getBoundingClientRect().top-k.getBoundingClientRect().top-IY*2-(f.current?.getBoundingClientRect().height??0);x(N>0?Math.min(Ef,Math.floor(N)):Ef)},[n.length]),C.useEffect(()=>{b.current?.querySelector('[aria-selected="true"]')?.scrollIntoView?.({block:"nearest"})},[i]),l.jsxs("div",{ref:h,className:"absolute inset-x-3 bottom-full mb-2 overflow-hidden rounded-lg border border-base bg-bg/98 shadow-2xl",children:[l.jsx("div",{ref:f,className:"border-b border-default px-3 py-1.5 text-[10px] uppercase tracking-wider text-muted",children:e}),l.jsx("ul",{ref:b,role:"listbox",className:"overflow-y-auto py-1",style:{maxHeight:v},children:n.map((S,k)=>{const T=k===i;return l.jsx("li",{children:l.jsxs("button",{type:"button",role:"option","aria-selected":T,onMouseEnter:()=>r(k),onClick:()=>u(S),className:`flex w-full items-center gap-3 px-3 py-2 text-left text-sm transition ${T?"bg-bg-elevated text-heading":"text-neutral hover:bg-bg-elevated/60"}`,children:[l.jsx("span",{className:"font-medium",children:S.label}),l.jsx("span",{className:"ml-auto font-mono text-[11px] text-secondary",children:S.command})]})},S.command)})})]})}function RS({onPick:e}){return l.jsx("div",{className:"flex flex-wrap gap-1.5",children:xg.map(n=>l.jsx("button",{type:"button",onClick:()=>e(n.prompt),className:"rounded-md border border-base bg-bg-elevated/70 px-3 py-1.5 text-sm text-neutral transition hover:border-strong hover:bg-mono-800/70 hover:text-heading",children:n.label},n.label))})}function MC(e){switch(e){case"claude":return"ANTHROPIC_API_KEY";case"openai":return"OPENAI_API_KEY";case"gemini":return"GEMINI_API_KEY";case"zai":return"ZAI_API_KEY"}}function qY(e,n){const i=e.timestamp??0;return`${e.role}:${i}:${n}`}function PY(e,n,i,r,u,h,f=!0){const b=[];for(let v=0;v<e.length;v++){const x=e[v],S=qY(x,v);if(x.role==="user"){const k=typeof x.content=="string"?x.content:JSON.stringify(x.content);if(k.startsWith("[system]"))continue;b.push(l.jsx(MY,{text:k,projectName:n,providerOverride:i,scope:r,context:x.aeroContext,cliCopy:f},S));continue}if(x.role==="assistant"){const k=new Map;let T=v+1;for(;T<e.length&&e[T].role==="toolResult";){const P=e[T];k.set(P.toolCallId,P),T++}const N=LY(x,k).map(P=>{const E=u.find(ee=>ee.id===P.id),$={...P,...E};return{...$,interrupted:$.endedAt===void 0&&(!h||$.interrupted)}}),I=Ed(x);b.push(l.jsxs(C.Fragment,{children:[I.trim()&&l.jsxs("div",{className:"mt-3",children:[l.jsx("div",{className:"mb-0.5 text-[10px] uppercase tracking-wider text-positive-400",children:"Aero"}),l.jsx(BC,{content:I})]}),N.length>0&&l.jsx("div",{className:"mt-3 space-y-1.5",children:N.map(P=>l.jsx($Y,{trail:P},P.id))})]},S)),v=T-1;continue}}return b}function MY({text:e,projectName:n,providerOverride:i,scope:r,context:u,cliCopy:h=!0}){const[f,b]=C.useState(!1),v=C.useMemo(()=>BY(n,e,i,r,u),[n,e,i,r,u]);async function x(){try{await navigator.clipboard.writeText(v),b(!0),window.setTimeout(()=>b(!1),1500)}catch{}}return l.jsxs("div",{className:"group relative mt-3 rounded-md bg-bg-elevated/60 px-3 py-2 text-strong",children:[l.jsxs("div",{className:"flex items-center justify-between gap-2",children:[l.jsx("div",{className:"text-[10px] uppercase tracking-wider text-muted",children:"You"}),h&&l.jsx("button",{type:"button",onClick:hn(x),className:"inline-flex items-center gap-1 rounded border border-mono-800/70 bg-bg/60 px-1.5 py-0.5 text-[10px] text-secondary opacity-0 transition hover:border-strong hover:text-heading group-hover:opacity-100 focus:opacity-100","aria-label":"Copy as CLI command",title:v,children:f?l.jsxs(l.Fragment,{children:[l.jsx(im,{className:"h-2.5 w-2.5 text-positive-400","aria-hidden":"true"}),"Copied"]}):l.jsxs(l.Fragment,{children:[l.jsx(Tg,{className:"h-2.5 w-2.5","aria-hidden":"true"}),"Copy as CLI"]})})]}),l.jsx("div",{className:"whitespace-pre-wrap",children:e})]})}function BY(e,n,i,r,u){const h=["canonry","agent","ask",Sf(e),Sf(n)];return i&&h.push("--provider",i),r==="read-only"&&h.push("--scope","read-only"),u&&h.push("--context",Sf(JSON.stringify(u))),h.join(" ")}function LY(e,n){const i=[];for(const r of e.content){if(r.type!=="toolCall")continue;const u=r,h=n.get(u.id);i.push({id:u.id,name:u.name,args:u.arguments,label:h?.aeroToolLabel,durationMs:h?.aeroDurationMs,endedAt:h?.timestamp,isError:h?.isError,result:h?.content})}return i}function $Y({trail:e}){const[n,i]=C.useState(!1),r=e.endedAt===void 0&&!e.interrupted,u=!r&&e.isError===!0,h=e.durationMs??(e.endedAt!=null&&e.startedAt!=null?e.endedAt-e.startedAt:null),f=h==null||h<0?null:h<1e3?`${h}ms`:`${(h/1e3).toFixed(1)}s`,b=u?"border-negative-800/50":r?"border-positive-800/50":"border-mono-800/70",v=u?"bg-negative-950/20":r?"bg-positive-950/20":"bg-surface-hover";return l.jsxs("div",{className:`rounded-md border ${b} ${v}`,children:[l.jsxs("button",{type:"button",onClick:()=>i(x=>!x),className:"flex w-full items-center gap-2 px-2.5 py-1.5 text-left","aria-expanded":n,children:[l.jsx("span",{className:"flex h-3.5 w-3.5 shrink-0 items-center justify-center",children:r?l.jsx(Ir,{className:"h-3 w-3 animate-spin text-positive-400","aria-hidden":"true"}):u?l.jsx(ak,{className:"h-3 w-3 text-negative-400","aria-hidden":"true"}):l.jsx(x5,{className:"h-3 w-3 text-muted","aria-hidden":"true"})}),l.jsx("span",{className:"text-sm font-medium text-heading",children:e.label??e.name.replace(/^(?:canonry|aero)_/,"").replace(/_/g," ")}),l.jsxs("span",{className:"ml-auto flex items-center gap-2 text-[10px] text-muted",children:[r?l.jsx("span",{className:"text-positive-400",children:"running…"}):l.jsxs(l.Fragment,{children:[l.jsx("span",{children:e.interrupted?"interrupted":u?"failed":"done"}),f&&l.jsx("span",{children:f})]}),l.jsx(Eg,{className:`h-3 w-3 transition-transform ${n?"rotate-90":""}`,"aria-hidden":"true"})]})]}),n&&l.jsxs("div",{className:"border-t border-default px-2.5 py-2 text-[11px] text-secondary",children:[l.jsx("div",{className:"mb-2 text-xs text-secondary",children:e.name}),l.jsx("div",{className:"mb-1 text-xs text-secondary",children:"Inputs"}),l.jsx("pre",{className:"mb-2 overflow-x-auto whitespace-pre-wrap break-all text-xs text-neutral",children:DS(e.args)}),!r&&e.result!==void 0&&l.jsxs(l.Fragment,{children:[l.jsx("div",{className:"mb-1 text-[9px] uppercase tracking-wider text-faint",children:u?"Error":"Result"}),l.jsx("pre",{className:"overflow-x-auto whitespace-pre-wrap break-all text-xs text-neutral",children:DS(e.result)})]})]})]})}function DS(e){try{const n=typeof e=="string"?e:JSON.stringify(e,null,2);return n.length>2e3?`${n.slice(0,2e3)}
|
|
64
|
+
… (${n.length-2e3} more chars)`:n}catch{return String(e)}}function BC({content:e}){return l.jsx("div",{className:"text-heading",children:l.jsx(q5,{remarkPlugins:[P5],components:{h1:n=>l.jsx("h1",{...n,className:"mt-3 mb-2 text-base font-semibold text-primary"}),h2:n=>l.jsx("h2",{...n,className:"mt-3 mb-2 text-sm font-semibold text-primary"}),h3:n=>l.jsx("h3",{...n,className:"mt-3 mb-1.5 text-sm font-semibold text-heading"}),h4:n=>l.jsx("h4",{...n,className:"mt-2 mb-1 text-xs font-semibold uppercase tracking-wide text-neutral"}),p:n=>l.jsx("p",{...n,className:"mb-2 leading-relaxed"}),ul:n=>l.jsx("ul",{...n,className:"mb-2 ml-4 list-disc space-y-1"}),ol:n=>l.jsx("ol",{...n,className:"mb-2 ml-4 list-decimal space-y-1"}),li:n=>l.jsx("li",{...n,className:"marker:text-mono-600"}),strong:n=>l.jsx("strong",{...n,className:"font-semibold text-primary"}),em:n=>l.jsx("em",{...n,className:"text-strong"}),code:({children:n,...i})=>l.jsx("code",{...i,className:"rounded bg-mono-800/70 px-1 py-0.5 font-mono text-[12px] text-positive-200",children:n}),pre:n=>l.jsx("pre",{...n,className:"mb-2 overflow-x-auto rounded-md border border-base bg-bg-elevated/70 p-3 font-mono text-xs text-strong"}),a:n=>l.jsx("a",{...n,className:"text-positive-400 underline decoration-positive-700 hover:decoration-positive-400",target:"_blank",rel:"noopener noreferrer"}),table:n=>l.jsx("div",{className:"mb-2 overflow-x-auto",children:l.jsx("table",{...n,className:"w-full border-collapse text-xs"})}),thead:n=>l.jsx("thead",{...n,className:"border-b border-base"}),th:n=>l.jsx("th",{...n,className:"px-2 py-1 text-left font-semibold text-neutral"}),tr:n=>l.jsx("tr",{...n,className:"border-b border-mono-900"}),td:n=>l.jsx("td",{...n,className:"px-2 py-1 text-strong"}),blockquote:n=>l.jsx("blockquote",{...n,className:"mb-2 border-l-2 border-strong pl-3 italic text-secondary"}),hr:()=>l.jsx("hr",{className:"my-3 border-base"})},children:e})})}function VY(){return l.jsxs("div",{className:"mt-3 flex items-center gap-2",children:[l.jsx("div",{className:"text-[10px] uppercase tracking-wider text-positive-400",children:"Aero"}),l.jsxs("div",{className:"flex items-center gap-1","aria-label":"Aero is thinking",children:[l.jsx("span",{className:"aero-dot h-1.5 w-1.5 rounded-full bg-positive-400/80"}),l.jsx("span",{className:"aero-dot aero-dot-2 h-1.5 w-1.5 rounded-full bg-positive-400/60"}),l.jsx("span",{className:"aero-dot aero-dot-3 h-1.5 w-1.5 rounded-full bg-positive-400/40"})]})]})}function LC({isAdmin:e,account:n}){return e||n?.role==="viewer"&&BG()}function UY(){const{isAdmin:e,account:n}=fa(),i=QS(),r=/^\/projects\/([^/]+)/.exec(i.pathname),u=r?decodeURIComponent(r[1]):null,h=yt({...qo({client:W}),enabled:u!==null,staleTime:6e4}),f=iY(i.pathname,i.search),b=h.data??[],v=b.find(T=>T.id===u)??b.find(T=>T.name===u),x=KK(v?.name??u??"",f),S=a1(),k=S||LC({isAdmin:e,account:n});return!u||!k||!v?null:l.jsx(EY,{projectName:v.name,context:x,preview:S},v.name)}const wg={project:"getApiV1ProjectsByName",google:"getApiV1ProjectsByNameGoogle",gsc:"getApiV1ProjectsByNameGoogleGsc",bing:"getApiV1ProjectsByNameBing",ga:"getApiV1ProjectsByNameGa",gbp:"getApiV1ProjectsByNameGbp",ads:"getApiV1ProjectsByNameAds",googleAds:"getApiV1ProjectsByNameGoogleAds",gtm:"getApiV1ProjectsByNameGtm",conversionTracking:"getApiV1ProjectsByNameConversionTracking",traffic:"getApiV1ProjectsByNameTraffic",discovery:"getApiV1ProjectsByNameDiscover",researchRuns:"getApiV1ProjectsByNameResearchRuns",visibilityReport:"getApiV1ProjectsByNameVisibilityReport",queryTracking:"getApiV1ProjectsByNameQueryTracking",technicalAeo:"getApiV1ProjectsByNameTechnicalAeo",runs:"getApiV1ProjectsByNameRuns"};function Pn(e,n){const i=wg[n];return e.invalidateQueries({predicate:r=>{const u=r.queryKey[0];return typeof u?._id=="string"&&u._id.startsWith(i)}})}function yse(e,n){return e.invalidateQueries({predicate:i=>{const r=i.queryKey[0];return r?.path?.name!==n||typeof r._id!="string"?!1:r._id.startsWith("getApiV1ProjectsByNameMeasurement")||r._id===wg.queryTracking||r._id===wg.visibilityReport||r._id==="getApiV1ProjectsByNameQueries"||r._id==="getApiV1ProjectsByName"}})}function Tc(e,n,i){switch(e.invalidateQueries({queryKey:c1({client:W})}),e.invalidateQueries({queryKey:_s({client:W})}),Pn(e,"runs"),n){case Re["answer-visibility"]:yg(e,i,"none"),Pn(e,"visibilityReport"),Pn(e,"queryTracking");return;case Re["backlink-extract"]:return;case Re["site-audit"]:Pn(e,"technicalAeo");return;case Re["gsc-sync"]:case Re["inspect-sitemap"]:Pn(e,"gsc");return;case Re["ga-sync"]:Pn(e,"ga");return;case Re["traffic-sync"]:Pn(e,"ga"),Pn(e,"traffic");return;case Re["bing-inspect"]:case Re["bing-inspect-sitemap"]:Pn(e,"bing");return;case Re["aeo-discover-seed"]:case Re["aeo-discover-probe"]:yg(e,i);return;case Re["gbp-sync"]:Pn(e,"gbp");return;case Re["ads-sync"]:Pn(e,"ads");return;case Re["google-ads-sync"]:Pn(e,"googleAds"),Pn(e,"conversionTracking");return;case Re["gtm-sync"]:Pn(e,"gtm"),Pn(e,"conversionTracking");return;default:return n}}const zS=[{label:"GitHub",href:"https://github.com/Canonry/canonry",Icon:tk},{label:"Docs",href:"https://github.com/Canonry/canonry/tree/main/docs",Icon:_5},{label:"Changelog",href:"https://github.com/Canonry/canonry/releases",Icon:T5}],IS=e=>({label:e,state:"checking",detail:"Checking service health"}),GY={apiStatus:IS("API"),workerStatus:IS("Worker")};function KY(e){return e==="completed"?"positive":e==="partial"?"caution":"negative"}function HY(e){const n=bc(e.kind);return e.status==="completed"?`${n} completed`:e.status==="partial"?`${n} completed with partial results`:e.status==="cancelled"?`${n} cancelled`:`${n} failed`}function QY(e,n){return e.error?`${n}: ${h0(e.error)}`:e.location?`${n} · ${e.location}`:n}function OS(e,n,i){if(n)return n;const r=i.find(u=>u.id===e);return r?.displayName||r?.name||e}function FY(e,n){return[e.completed>0?`${e.completed} completed`:null,e.partial>0?`${e.partial} partial`:null,e.failed>0?`${e.failed} failed`:null,e.cancelled>0?`${e.cancelled} cancelled`:null,n>0?`${n} skipped at queue time`:null].filter(Boolean).join(", ")}function ZY(e){return e.failed>0||e.cancelled>0?"negative":e.partial>0?"caution":"positive"}function YY(){const e=ta(),n=C.useSyncExternalStore(pC,Vi,Vi),i=Object.keys(n.runs).length>0||Object.keys(n.batches).length>0,r=yt({...zm({client:W}),enabled:i,staleTime:Gr,refetchInterval:3e3}),u=yt({...qo({client:W}),enabled:i}),h=C.useRef({}),f=C.useCallback(()=>{r.refetch()},[r.refetch]);return C.useEffect(()=>{i&&f()},[i,f]),C.useEffect(()=>{if(!i||typeof window>"u")return;const b=()=>{document.visibilityState==="visible"&&f()};return window.addEventListener("focus",f),document.addEventListener("visibilitychange",b),()=>{window.removeEventListener("focus",f),document.removeEventListener("visibilitychange",b)}},[i,f]),C.useEffect(()=>{const b=r.data??[],v=u.data??[],x=Object.fromEntries(b.map(k=>[k.id,k])),S=Object.fromEntries(b.map(k=>[k.id,k.status]));for(const k of Object.values(n.runs)){const T=x[k.runId];if(!T||!aF(T.status)||(h.current[T.id]??k.lastAnnouncedStatus)===T.status)continue;const I=v.find(E=>E.id===T.projectId);if(I&&Tc(e,T.kind,I.name),k.sourceAction==="run-all"){jf(T.id);continue}const P=OS(T.projectId,k.projectLabel,v);kn({title:HY(T),detail:QY(T,P),tone:KY(T.status),dedupeKey:`run:${T.id}`,dedupeMode:"replace",cta:{label:"View run",intent:"open-run-drawer",runId:T.id}}),jf(T.id)}if(r.data!==void 0){const k=new Set(b.map(N=>N.id)),T=sF(Object.values(n.runs),k,Date.now(),iF);for(const N of T){const I=v.find(P=>P.id===N.projectId);I&&Tc(e,N.kind,I.name),N.sourceAction!=="run-all"&&kn({title:`${bc(N.kind)} status unavailable`,detail:OS(N.projectId,N.projectLabel,v),tone:"neutral",dedupeKey:`run-stale:${N.runId}`,dedupeMode:"replace"}),jf(N.runId)}}for(const k of Object.values(n.batches)){const T=oF(k.runIds,x);T.finished&&(kn({title:"Run-all batch finished",detail:FY(T,k.skippedCount),tone:ZY(T),dedupeKey:`batch:${k.batchId}`,dedupeMode:"replace",cta:{label:"View runs",intent:"go-to-runs"}}),nF(k.batchId))}h.current=S},[u.data,r.data,n,e]),null}function XY(){const{account:e,isAdmin:n}=fa(),i=Qc(),r=C.useMemo(()=>FA(),[]),u=C.useMemo(PG,[]),h=C.useMemo(MG,[]),f=a1()||h&&LC({isAdmin:n,account:e}),b=C.useMemo(LG,[]),v=QS(),{dashboard:x,isLoading:S,refetch:k}=Mm(void 0,{includeSettings:!r,includeOverviews:!1,pauseProjectPolling:v.pathname==="/setup"}),I=f1(!i,i?.health).data??i?.health??GY,{runId:P,evidenceId:E,closeDrawer:$}=g1(),[ee,L]=C.useState(!1),[F,Z]=C.useState(()=>{if(typeof window>"u")return!1;try{return window.localStorage.getItem("canonry:sidebarHidden")==="true"}catch{return!1}}),[ae,M]=C.useState(()=>{if(typeof window>"u")return null;try{return window.localStorage.getItem("canonry:dismissedUpdateVersion")}catch{return null}}),[Y]=C.useState(()=>typeof window>"u"?null:new URLSearchParams(window.location.search).get("force-update")),ue=Y?{current:I.apiStatus.version??"0.0.0",latest:Y,url:"https://www.npmjs.com/package/@canonry/canonry",upgradeCommand:"npm install -g @canonry/canonry"}:I.apiStatus.updateAvailable,Xe=b&&ue&&ue.latest!==ae,nt=()=>{if(ue){try{window.localStorage.setItem("canonry:dismissedUpdateVersion",ue.latest)}catch{}M(ue.latest)}},Ge=()=>{const me=!F;try{me?window.localStorage.setItem("canonry:sidebarHidden","true"):window.localStorage.removeItem("canonry:sidebarHidden")}catch{}Z(me)},Pe=GZ(P),Se=Pe.data??null,Ve=Pe.isLoading;C.useEffect(()=>{Se&&Se.status!=="running"&&Se.status!=="queued"&&k()},[Se?.status,k]),C.useEffect(()=>{L(!1)},[v.pathname]),C.useEffect(()=>{if(typeof window>"u"||!P&&!E)return;const me=ot=>{ot.key==="Escape"&&$()};return window.addEventListener("keydown",me),()=>{window.removeEventListener("keydown",me)}},[P,E,$]);const q=x??i?.dashboard??null,X=v.pathname==="/setup",ve=X&&q!==null&&q.portfolioOverview.projects.length===0,ke=X&&(v.search.onboarding==="site-health"||v.search.onboarding==="first-run"||v.search.onboarding==="complete"),[J,Ne]=C.useState(ve);C.useEffect(()=>{X?ve&&Ne(!0):Ne(!1)},[ve,X]);const xe=X&&(ke||ve||J||X&&q===null),le=xe?"app-shell-focus":F?"app-shell-sidebar-hidden":"",re=P?(q?fZ(q,P):void 0)??(Se?Pm(Se,q?.projects.find(me=>me.project.id===Se.projectId)?.project.displayName??q?.projects.find(me=>me.project.id===Se.projectId)?.project.name??"Unknown project"):void 0):void 0,H=C.useMemo(()=>dZ(v.pathname,q),[v.pathname,q]),{commandCenter:pe,evidenceLoading:ze,evidenceError:je,isError:it,refetch:Ue}=$Z(E?H:null,{evidence:!0}),jt=C.useMemo(()=>{if(E)return yZ(pe,q,E)},[E,pe,q]),He=(()=>{const me=v.pathname;if(me==="/")return"Portfolio";if(me==="/projects")return"Projects";if(me==="/runs")return"Runs";if(me==="/history")return"History";if(me==="/settings")return"Settings";if(me==="/setup")return"Setup";if(me==="/backlinks")return"Backlink data";if(me==="/traffic"||me.startsWith("/traffic/"))return"Traffic sources";if(me.startsWith("/projects/")){const ot=q?.projects.find(It=>It.project.name===H);return ot?.project.displayName||ot?.project.name||H||"Projects"}return"Not found"})();if(r){const me=!r.views||r.views.includes(tH(v.pathname));return l.jsxs("div",{className:"app-shell app-shell-embed","data-theme":oH(r.theme),style:rH(r.theme),children:[l.jsx("a",{className:"skip-link",href:"#content",children:"Skip to content"}),l.jsx("main",{id:"content",className:"page-shell",children:me?l.jsx(zf,{}):l.jsx("div",{className:"embed-view-unavailable",role:"status",children:"This view is not available in embed mode."})})]})}return l.jsxs(l.Fragment,{children:[l.jsx("a",{className:"skip-link",href:"#content",children:"Skip to content"}),l.jsx(XZ,{}),l.jsxs("div",{className:`app-shell ${le}${zr()?" app-shell-demo":""}`,children:[!xe&&!F&&l.jsxs("aside",{id:"desktop-sidebar",className:"sidebar","aria-label":"Primary navigation",children:[l.jsx("div",{className:"sidebar-brand",children:l.jsx(fS,{version:I.apiStatus.version,updateAvailable:Xe?ue:null,onDismissUpdate:nt})}),l.jsxs("nav",{className:"sidebar-nav",children:[l.jsxs(We,{to:"/",className:"sidebar-link",activeProps:{className:"sidebar-link sidebar-link-active"},activeOptions:{exact:!0},children:[l.jsx(w5,{className:"sidebar-icon"}),l.jsx("span",{children:"Portfolio"})]}),l.jsxs(We,{to:"/projects",className:"sidebar-link",activeProps:{className:"sidebar-link sidebar-link-active"},activeOptions:{exact:!1},children:[l.jsx(S5,{className:"sidebar-icon"}),l.jsx("span",{children:"Projects"})]}),l.jsxs(We,{to:"/runs",className:"sidebar-link",activeProps:{className:"sidebar-link sidebar-link-active"},activeOptions:{exact:!0},children:[l.jsx(k5,{className:"sidebar-icon"}),l.jsx("span",{children:"Runs"})]}),l.jsxs(We,{to:"/history",className:"sidebar-link",activeProps:{className:"sidebar-link sidebar-link-active"},activeOptions:{exact:!0},children:[l.jsx(nk,{className:"sidebar-icon"}),l.jsx("span",{children:"History"})]}),l.jsxs(We,{to:"/traffic",className:"sidebar-link",activeProps:{className:"sidebar-link sidebar-link-active"},activeOptions:{exact:!1},children:[l.jsx(j5,{className:"sidebar-icon"}),l.jsx("span",{children:"Traffic sources"})]}),!zr()&&l.jsxs(We,{to:"/backlinks",className:"sidebar-link",activeProps:{className:"sidebar-link sidebar-link-active"},activeOptions:{exact:!0},children:[l.jsx(A5,{className:"sidebar-icon"}),l.jsx("span",{children:"Backlink data"})]}),n&&l.jsxs(We,{to:"/settings",className:"sidebar-link",activeProps:{className:"sidebar-link sidebar-link-active"},activeOptions:{exact:!0},children:[l.jsx(C5,{className:"sidebar-icon"}),l.jsx("span",{children:"Settings"})]}),S?l.jsxs(l.Fragment,{children:[l.jsx("p",{className:"sidebar-section-title",children:"Tracked projects"}),[1,2,3].map(me=>l.jsxs("div",{className:"sidebar-skeleton-item",children:[l.jsx("span",{className:"skeleton-circle size-2"}),l.jsx("span",{className:"skeleton-text flex-1",style:{width:`${50+me*15}%`}})]},me))]}):q&&q.projects.length>0?l.jsxs(l.Fragment,{children:[l.jsx("p",{className:"sidebar-section-title",children:"Tracked projects"}),q.projects.map(me=>{const ot=me.visibilitySummary.tone;return l.jsxs(We,{to:"/projects/$projectName",params:{projectName:me.project.name},className:"sidebar-project",activeProps:{className:"sidebar-project sidebar-project-active"},children:[l.jsx("span",{className:`sidebar-dot sidebar-dot-${ot}`}),l.jsx("span",{children:me.project.displayName||me.project.name})]},me.project.id)})]}):S?null:l.jsxs(l.Fragment,{children:[l.jsx("p",{className:"sidebar-section-title",children:"Resources"}),n&&l.jsxs(We,{to:"/setup",className:"sidebar-link",activeProps:{className:"sidebar-link sidebar-link-active"},activeOptions:{exact:!0},children:[l.jsx(N5,{className:"sidebar-icon"}),l.jsx("span",{children:"Setup"})]})]})]}),e&&l.jsxs("div",{className:"sidebar-account",children:[l.jsxs("div",{className:"sidebar-account-identity",children:[l.jsx("span",{className:"sidebar-account-name",children:e.name}),e.role==="viewer"?l.jsx("span",{className:"sidebar-account-role",children:Fw()}):null]}),l.jsx(ce,{type:"button",variant:"ghost",size:"sm",onClick:hn(async()=>{await Jw(),window.location.reload()}),children:"Sign out"})]}),u?l.jsx("div",{className:"sidebar-footer",children:zS.map(({label:me,href:ot,Icon:It})=>l.jsx("a",{className:"sidebar-footer-icon",href:ot,target:"_blank",rel:"noopener noreferrer",title:me,"aria-label":me,children:l.jsx(It,{className:"size-4"})},ot))}):null]}),l.jsxs("div",{className:"main-area",children:[l.jsxs("header",{className:"topbar",children:[l.jsxs("div",{className:"topbar-left",children:[!xe&&l.jsx(ce,{className:"sidebar-privacy-toggle",variant:"ghost",size:"icon",type:"button","aria-label":F?"Show sidebar":"Hide sidebar","aria-controls":F?void 0:"desktop-sidebar","aria-expanded":!F,title:F?"Show sidebar":"Hide sidebar",onClick:Ge,children:F?l.jsx(E5,{className:"size-4"}):l.jsx(R5,{className:"size-4"})}),l.jsx("div",{className:"topbar-brand-mobile",children:l.jsx(fS,{compact:!0})}),l.jsxs("nav",{className:"breadcrumb","aria-label":"Breadcrumb",children:[l.jsx(We,{to:"/",children:"Home"}),l.jsx(Eg,{className:"breadcrumb-sep size-3"}),l.jsx("span",{className:"breadcrumb-current",children:He})]})]}),l.jsxs("div",{className:"topbar-actions",children:[l.jsx(JZ,{}),l.jsxs("div",{className:"health-pill-row",children:[l.jsxs("span",{className:`health-pill health-pill-${I.apiStatus.state}`,title:Kr(I.apiStatus),children:["API ",I.apiStatus.state==="ok"?"ok":I.apiStatus.state]}),l.jsx("span",{className:`health-pill health-pill-${I.workerStatus.state}`,title:Kr(I.workerStatus),children:`Worker ${I.workerStatus.state==="ok"?"ok":I.workerStatus.state}`})]}),xe?null:l.jsxs(ce,{className:"nav-toggle",variant:"secondary",size:"icon",type:"button","aria-expanded":ee,"aria-controls":"mobile-nav",onClick:()=>L(me=>!me),children:[l.jsx(D5,{className:"size-4"}),l.jsx("span",{className:"sr-only",children:"Open navigation"})]})]})]}),xe?null:l.jsxs("div",{id:"mobile-nav",className:`mobile-nav ${ee?"mobile-nav-open":""}`,children:[l.jsxs(ce,{className:"mobile-nav-close",variant:"ghost",size:"icon",type:"button",onClick:()=>L(!1),children:[l.jsx(Hr,{className:"size-5"}),l.jsx("span",{className:"sr-only",children:"Close navigation"})]}),l.jsx(We,{to:"/",className:"mobile-nav-link",activeProps:{className:"mobile-nav-link mobile-nav-link-active"},activeOptions:{exact:!0},children:"Portfolio"}),l.jsx(We,{to:"/projects",className:"mobile-nav-link",activeProps:{className:"mobile-nav-link mobile-nav-link-active"},activeOptions:{exact:!1},children:"Projects"}),l.jsx(We,{to:"/runs",className:"mobile-nav-link",activeProps:{className:"mobile-nav-link mobile-nav-link-active"},activeOptions:{exact:!0},children:"Runs"}),l.jsx(We,{to:"/history",className:"mobile-nav-link",activeProps:{className:"mobile-nav-link mobile-nav-link-active"},activeOptions:{exact:!0},children:"History"}),l.jsx(We,{to:"/traffic",className:"mobile-nav-link",activeProps:{className:"mobile-nav-link mobile-nav-link-active"},activeOptions:{exact:!1},children:"Traffic sources"}),!zr()&&l.jsx(We,{to:"/backlinks",className:"mobile-nav-link",activeProps:{className:"mobile-nav-link mobile-nav-link-active"},activeOptions:{exact:!0},children:"Backlink data"}),n&&l.jsx(We,{to:"/settings",className:"mobile-nav-link",activeProps:{className:"mobile-nav-link mobile-nav-link-active"},activeOptions:{exact:!0},children:"Settings"}),q&&q.projects.length>0?l.jsxs("div",{className:"mobile-nav-section",children:[l.jsx("p",{className:"mobile-nav-section-title",children:"Tracked projects"}),q.projects.map(me=>l.jsx(We,{to:"/projects/$projectName",params:{projectName:me.project.name},className:"mobile-nav-link",children:me.project.name},me.project.id))]}):null,e&&l.jsxs("div",{className:"mobile-nav-section",children:[l.jsx("p",{className:"mobile-nav-section-title",children:"Signed in"}),l.jsxs("div",{className:"sidebar-account",children:[l.jsxs("div",{className:"sidebar-account-identity",children:[l.jsx("span",{className:"sidebar-account-name",children:e.name}),e.role==="viewer"?l.jsx("span",{className:"sidebar-account-role",children:Fw()}):null]}),l.jsx(ce,{type:"button",variant:"ghost",size:"sm","data-testid":"mobile-sign-out",onClick:hn(async()=>{await Jw(),window.location.reload()}),children:"Sign out"})]})]})]}),l.jsx("main",{id:"content",className:`page-shell ${f&&H?"pb-20":""}`.trim(),children:S&&!i?l.jsxs("div",{className:"page-skeleton",children:[l.jsxs("div",{className:"page-skeleton-header",children:[l.jsx("div",{className:"skeleton-text h-6 w-40"}),l.jsx("div",{className:"skeleton-text-sm w-72"})]}),l.jsx("div",{className:"page-skeleton-grid",children:[1,2,3].map(me=>l.jsxs("div",{className:"page-skeleton-card",children:[l.jsx("div",{className:"skeleton-text w-24"}),l.jsx("div",{className:"skeleton-text w-full"}),l.jsx("div",{className:"skeleton-text-sm w-3/4"})]},me))}),l.jsx("div",{className:"page-skeleton-grid",style:{gridTemplateColumns:"1fr 1fr"},children:[1,2].map(me=>l.jsxs("div",{className:"page-skeleton-card",children:[l.jsx("div",{className:"skeleton-text w-20"}),l.jsx("div",{className:"space-y-2",children:[1,2,3].map(ot=>l.jsx("div",{className:"skeleton-text-sm w-full"},ot))})]},me))})]}):l.jsx(zf,{})}),l.jsxs("footer",{className:"footer",children:[l.jsxs("span",{className:"footer-brand",children:[l.jsx("span",{children:l.jsx("a",{href:"https://canonry.ai",children:"Canonry"})}),I.apiStatus.version&&I.apiStatus.version!=="unknown"?l.jsxs("span",{className:"footer-version",children:["v",I.apiStatus.version]}):null]}),u?l.jsx("div",{className:"footer-links",children:zS.map(({label:me,href:ot,Icon:It})=>l.jsx("a",{href:ot,target:"_blank",rel:"noopener noreferrer",title:me,"aria-label":me,className:"footer-icon",children:l.jsx(It,{className:"size-3.5"})},ot))}):null]})]}),P&&!re&&Ve?l.jsx(bd,{open:!0,title:"Loading run details",subtitle:"Fetching the durable run record",onClose:$,children:l.jsx("p",{className:"text-sm text-muted",role:"status",children:"Loading run details…"})}):null,P&&!re&&Pe.isError?l.jsx(bd,{open:!0,title:"Run unavailable",subtitle:"The run could not be loaded",onClose:$,children:l.jsx("p",{className:"text-sm text-negative",children:Pe.error instanceof Error?Pe.error.message:"Run details are unavailable."})}):null,re?l.jsxs(bd,{open:!0,title:re.summary,subtitle:`${re.projectName} · ${re.kindLabel}`,onClose:$,children:[l.jsxs("div",{className:"flex flex-wrap items-center gap-x-5 gap-y-1 text-sm",children:[l.jsx(h1,{status:re.status}),l.jsx("span",{className:"text-secondary",children:re.startedAt}),l.jsx("span",{className:"text-muted",children:re.duration}),l.jsx("span",{className:"text-faint",children:re.triggerLabel})]}),re.status==="failed"&&re.statusDetail&&l.jsx("p",{className:"mt-2 text-sm text-negative",children:re.statusDetail}),l.jsxs("div",{className:"mt-4",children:[l.jsx("p",{className:"text-[10px] font-semibold uppercase tracking-wider text-muted mb-2",children:"Activity Log"}),Ve?l.jsx("p",{className:"text-sm text-muted",children:"Loading run details..."}):Se?.snapshots&&Se.snapshots.length>0?l.jsxs("div",{className:"space-y-2",children:[Se.snapshots.map(me=>l.jsxs("div",{className:"rounded-lg border border-default bg-surface p-3",children:[l.jsxs("div",{className:"flex items-center justify-between gap-2 mb-1",children:[l.jsx("p",{className:"text-sm font-medium text-strong truncate",children:me.query??"Unknown query"}),l.jsxs("div",{className:"flex items-center gap-1.5",children:[l.jsx(WF,{provider:me.provider}),l.jsx(TC,{variant:me.citationState===fc.cited?"success":"neutral",children:me.citationState})]})]}),me.model&&l.jsx("p",{className:"text-[11px] text-muted font-mono",children:me.model}),me.citedDomains.length>0&&l.jsxs("p",{className:"text-xs text-muted mt-1",children:[l.jsx("span",{className:"text-secondary",children:"Sources:"})," ",me.citedDomains.join(", ")]}),me.citedCompetitorDomains.length>0&&l.jsxs("p",{className:"text-xs text-negative-400/80 mt-0.5",children:["Competitor cited: ",me.citedCompetitorDomains.join(", ")]}),me.mentionedCompetitorDomains.length>0&&l.jsxs("p",{className:"text-xs text-negative-400/80 mt-0.5",children:["Competitor mentioned: ",me.mentionedCompetitorDomains.join(", ")]}),me.groundingSources&&me.groundingSources.length>0&&l.jsxs("details",{className:"mt-2",children:[l.jsxs("summary",{className:"text-xs text-muted cursor-pointer hover:text-secondary",children:[me.groundingSources.length," grounding source",me.groundingSources.length!==1?"s":""]}),l.jsx("ul",{className:"mt-2 space-y-3",children:me.groundingSources.map((ot,It)=>l.jsx("li",{className:"min-w-0",children:l.jsx(gg,{url:ot.uri,title:ot.title})},It))})]}),me.answerText&&l.jsxs("details",{className:"mt-1",children:[l.jsx("summary",{className:"text-xs text-muted cursor-pointer hover:text-secondary",children:"Answer preview"}),l.jsx("p",{className:"mt-1 text-xs text-secondary leading-relaxed whitespace-pre-wrap",children:me.answerText})]})]},me.id)),Se.status==="running"&&l.jsxs("div",{className:"flex items-center gap-2 p-3 text-sm text-muted",children:[l.jsx("span",{className:"inline-block h-2 w-2 rounded-full bg-caution-500 animate-pulse"}),"Running remaining queries..."]})]}):Se&&Se.status==="running"?l.jsxs("div",{className:"flex items-center gap-2 p-3 text-sm text-muted",children:[l.jsx("span",{className:"inline-block h-2 w-2 rounded-full bg-caution-500 animate-pulse"}),"Waiting for first query result..."]}):Se&&Se.status==="queued"?l.jsxs("div",{className:"flex items-center gap-2 p-3 text-sm text-muted",children:[l.jsx("span",{className:"inline-block h-2 w-2 rounded-full bg-mono-500 animate-pulse"}),"Run queued, waiting for execution slot..."]}):Se&&Se.error?l.jsxs("div",{className:"rounded-lg border border-negative-800/40 bg-negative-950/20 p-3",children:[l.jsx("p",{className:"text-sm font-medium text-negative mb-2",children:"Run failed"}),l.jsx("pre",{className:"max-h-48 overflow-y-auto whitespace-pre-wrap break-words font-mono text-xs leading-5 text-negative",children:FK(Se.error)})]}):l.jsx("p",{className:"text-sm text-muted",children:"No snapshot data available."})]})]}):null,E&&!jt?l.jsx(bd,{open:!0,title:ze?"Loading answer":"Answer unavailable",subtitle:"Query evidence",onClose:$,children:ze?l.jsx("p",{role:"status",className:"text-sm text-secondary",children:"Loading answer…"}):l.jsxs(l.Fragment,{children:[l.jsx("p",{role:"alert",className:"text-sm text-secondary",children:je||it?"Could not load this answer.":"This answer is not in the available query evidence."}),l.jsx(ce,{type:"button",variant:"outline",onClick:()=>{Ue()},children:"Retry"})]})}):null,jt?l.jsx(lZ,{evidence:jt.evidence,project:jt.project,onClose:$}):null,l.jsx(YY,{}),l.jsx(QZ,{}),f?l.jsx(UY,{}):null]})]})}class JY extends C.Component{state={error:null};static getDerivedStateFromError(n){return{error:n}}componentDidCatch(n,i){console.error("[ErrorBoundary]",n,i.componentStack)}handleReset=()=>{this.setState({error:null})};render(){return this.state.error?l.jsx("div",{className:"page-container",children:l.jsxs("div",{className:"flex flex-col items-center justify-center gap-4 py-20 text-center",children:[l.jsx("div",{className:"rounded-full bg-negative-950/40 p-3",children:l.jsx(ak,{className:"size-6 text-negative-400"})}),l.jsx("h2",{className:"text-lg font-semibold text-heading",children:"Something went wrong"}),l.jsx("p",{className:"text-sm text-secondary max-w-md",children:this.state.error.message||"An unexpected error occurred while rendering this page."}),l.jsxs("div",{className:"flex gap-3 mt-2",children:[l.jsxs(ce,{variant:"secondary",size:"sm",onClick:this.handleReset,children:[l.jsx(z5,{className:"size-3.5 mr-1.5"}),"Try again"]}),l.jsx(ce,{variant:"secondary",size:"sm",onClick:()=>{const n=window.__CANONRY_CONFIG__?.basePath?.replace(/\/$/,"")??"";window.location.href=n||"/"},children:"Go home"})]})]})}):this.props.children}}const Ra=C.forwardRef(({className:e,...n},i)=>l.jsx("div",{ref:i,className:Pa("rounded-xl border border-base bg-bg/75 shadow-[0_0_0_1px_var(--color-shadow-hairline)]",e),...n}));Ra.displayName="Card";const Er=C.forwardRef(({className:e,...n},i)=>l.jsx("div",{ref:i,className:Pa("flex flex-col gap-1.5 p-5",e),...n}));Er.displayName="CardHeader";const $C=C.forwardRef(({className:e,...n},i)=>l.jsx("h3",{ref:i,className:Pa("font-medium tracking-tight text-primary",e),...n}));$C.displayName="CardTitle";const Wd=C.forwardRef(({className:e,...n},i)=>l.jsx("p",{ref:i,className:Pa("text-sm text-muted",e),...n}));Wd.displayName="CardDescription";const xo=C.forwardRef(({className:e,...n},i)=>l.jsx("div",{ref:i,className:Pa("p-5 pt-0",e),...n}));xo.displayName="CardContent";function Sg({disabled:e,title:n,...i}){const{canWrite:r}=fa();return r?l.jsx(ce,{disabled:e,title:n,...i}):l.jsx(ce,{...i,disabled:!0,title:iC})}function b1({title:e,children:n}){const{isAdmin:i}=fa();return i?l.jsx(l.Fragment,{children:n}):l.jsxs(Ra,{className:"surface-card mx-auto mt-8 max-w-lg",children:[l.jsxs(Er,{children:[l.jsxs($C,{children:[e," is for administrators"]}),l.jsx(Wd,{children:"Your account has view-only access. You can read everything this install has measured; changing how it is set up needs an administrator account."})]}),l.jsx(xo,{children:l.jsx("p",{className:"supporting-copy",children:"If you need to make a change here, ask an administrator on this install."})})]})}function bse(e,n,i){return{mode:n,scope:e.measurementScope,scopeKey:e.measurementScopeKey,marketKey:e.marketKey,queryClass:e.queryClass==="non-brand"?"non-brand":"branded",provider:e.provider,model:e.model,location:e.location,runId:e.measurementRunId,revision:e.revision,evaluationDefinitionId:i}}function vse(e,n,i){const r=[...new Set(n.filter(u=>!i||u.provider===i).map(u=>u.sourceRunId).filter(u=>!!u))].sort();return{...e,mode:"simple",scope:"project",scopeKey:void 0,marketKey:void 0,provider:i||void 0,model:void 0,revision:void 0,runId:r.length===1?r[0]:void 0,runIds:r.length>1?r:void 0}}function vc(e,n,i,r){return["sentiment",e,n,i??null,r??null]}const VC=5e3,WY=new Set(["pending","running","waiting-to-retry"]);function qS(e){return WY.has(e.state)}function eX(e){const n=e?.coverage.counts;return!!(n&&n.pending+n.running+n["waiting-to-retry"]>0)}function tX(e,n){return eX(e)||n?VC:!1}function nX(e,n,i=!0){const r=yt({queryKey:vc(e,"settings"),queryFn:()=>_d(e),retry:!1,staleTime:0,refetchOnWindowFocus:"always"}),u=yt({queryKey:vc(e,"jobs"),queryFn:()=>NK(e),enabled:!!r.data?.actions.configure,retry:!1,refetchOnWindowFocus:"always",refetchInterval:x=>x.state.data?.jobs.some(qS)?VC:!1}),h=!!u.data?.jobs.some(qS),f=x=>{const S={...n,queryClass:x};return{queryKey:vc(e,"summary",S),queryFn:()=>SK(e,S),enabled:i&&!!(r.data?.enabled&&r.data.installEnabled),retry:!1,staleTime:0,refetchOnWindowFocus:"always",refetchInterval:k=>tX(k.state.data,h)}},b=yt(f("branded")),v=yt(f("non-brand"));return{settings:r,branded:b,nonBrand:v,jobs:u}}const Pi={branded:"Branded","non-brand":"Non-brand"},v1=10;function x1(e){return e>=v1}const fn={states:{disabled:"Sentiment is off.","not-measured":"No ratings yet.",processing:"Analyzing sentiment…",canceled:"Analysis canceled.",partial:"Partial results.",failed:"Analysis failed.",complete:"Analysis complete.",unsupported:"Sentiment unavailable."},noJudgments:"No ratings available.",tooFew:"too few",minRated:`Shown from ${v1} ratings`,partial:"Partial results",columns:{favorable:"Favorable",rated:"Rated"},rated:"Share of answers rated favorable, mixed or unfavorable",noAnswers:"No answers yet",ratedUnavailable:"Unavailable",details:{ratedAnswers:"Rated answers",unadmitted:"Assessments not yet analyzed"},overall:"Overall sentiment is the share of favorable judgments across branded and non-brand queries. Each saved answer-subject assessment counts once. Factual, unmentioned, unsupported, and unclassified answers are excluded.",favorable:"The favorable share of favorable, mixed and unfavorable ratings. Each rating evaluates one subject in an answer. Branded and non-brand queries are measured separately."},Rd="—";function Ui(e){return e.replaceAll("-"," ").replace(/^./,n=>n.toUpperCase())}const em=["favorable","mixed","unfavorable"],aX=["branded","non-brand"];function UC(e){return e.interval?`${sn(e.interval.low,xt.fraction)} to ${sn(e.interval.high,xt.fraction)}`:null}const GC={favorable:"progress-fill-info",mixed:"progress-fill-caution",unfavorable:"progress-fill-negative"};function Rf(e){return`${e} ${e===1?"rating":"ratings"}`}function w1(e){return e.score.favorableRate!==null&&e.coverage.judged>0}function S1(e){return e?w1(e)&&x1(e.coverage.judged):!1}function iX({value:e,label:n}){const{counts:i,judged:r}=e.coverage;if(!w1(e))return l.jsx("div",{className:"sentiment-bar sentiment-bar-track","data-sentiment-bar":"empty","aria-hidden":"true"});const u=em.map(h=>`${i[h]} ${h}`).join(", ");return S1(e)?l.jsx("div",{role:"img","aria-label":`${n}: ${u}, ${e.score.favorableDisplay} favorable of ${Rf(r)}`,className:"sentiment-bar","data-sentiment-bar":"rated",children:em.filter(h=>i[h]>0).map(h=>l.jsx("span",{"data-outcome":h,className:`sentiment-bar-segment ${GC[h]}`,style:{flexGrow:i[h]},title:`${Ui(h)}: ${i[h]} of ${Rf(r)}`},h))}):l.jsx("div",{role:"img","aria-label":`${n}: ${u}, ${Rf(r)}, favorable share ${fn.minRated.toLowerCase()}`,className:"sentiment-bar sentiment-bar-track","data-sentiment-bar":"too-few"})}function sX({value:e,label:n}){return l.jsx("div",{role:"group","aria-label":`${n} favorable share`,className:"sentiment-class-favorable",children:S1(e)?l.jsx("span",{className:"sentiment-class-share",children:e.score.favorableDisplay}):l.jsxs(l.Fragment,{children:[l.jsx("span",{"aria-hidden":"true",className:"sentiment-class-empty",title:fn.minRated,children:Rd}),l.jsx("span",{className:"sr-only",children:fn.minRated})]})})}function oX({ratedAnswers:e=0,eligibleAnswers:n=0}){return`${e} of ${n} ${n===1?"answer":"answers"} rated`}function rX(e){const{eligibleAnswers:n}=e;return n===void 0?{display:Rd,detail:fn.ratedUnavailable,empty:!0}:n<=0?{display:Rd,detail:fn.noAnswers,empty:!0}:e.ratedAnswerRate===null||e.ratedAnswerRate===void 0?{display:Rd,detail:fn.states.disabled,empty:!0}:{display:sn(e.ratedAnswerRate,xt.fraction),detail:oX(e),empty:!1}}function lX({coverage:e,label:n}){const{display:i,detail:r,empty:u}=rX(e);return l.jsxs("div",{role:"group","aria-label":`${n} share rated`,className:"sentiment-class-ratings",children:[l.jsx("span",{"aria-hidden":"true",className:u?"sentiment-class-empty":void 0,title:r,children:i}),l.jsx("span",{className:"sr-only",children:u?r:`${i}, ${r}`})]})}function cX({value:e}){return w1(e)?e.provisional?l.jsx("p",{className:"sentiment-class-note text-caution",children:fn.partial}):null:l.jsx("p",{className:"sentiment-class-note",children:e.state==="complete"?fn.noJudgments:fn.states[e.state]})}function uX(e){return!!(e.coverage.selected||e.coverage.eligibleAssessments||e.reason)}function dX({value:e,queryClass:n,open:i,setOpenClass:r}){const u=C.useId(),h=C.useId(),f=C.useRef(null),b=C.useRef(null),v=C.useCallback(()=>r(N=>N===n?null:N),[r,n]);C.useEffect(()=>{if(!i)return;const N=$=>$ instanceof Node&&!!(f.current?.contains($)||b.current?.contains($)),I=$=>{N($.target)||v()},P=$=>{N($.target)||v()},E=$=>{$.key==="Escape"&&(v(),f.current?.focus())};return document.addEventListener("pointerdown",I),document.addEventListener("focusin",P),document.addEventListener("keydown",E),()=>{document.removeEventListener("pointerdown",I),document.removeEventListener("focusin",P),document.removeEventListener("keydown",E)}},[i,v]);const{coverage:x,score:S}=e,k=UC(S),T=x.judged>0&&!x1(x.judged);return uX(e)?l.jsxs(l.Fragment,{children:[l.jsx("button",{ref:f,type:"button",className:"sentiment-class-details-toggle","aria-label":`${Pi[n]} details`,"aria-expanded":i,"aria-controls":u,onClick:()=>r(N=>N===n?null:n),children:l.jsx(Rc,{className:"sentiment-class-details-chevron","aria-hidden":"true"})}),l.jsxs("div",{ref:b,id:u,role:"group","aria-labelledby":h,className:"sentiment-class-details",hidden:!i,children:[l.jsx("p",{id:h,className:"sentiment-class-details-title",children:Pi[n]}),l.jsxs("dl",{className:"sentiment-details-list",children:[(x.eligibleAnswers??0)>0&&l.jsxs("div",{children:[l.jsx("dt",{children:fn.details.ratedAnswers}),l.jsxs("dd",{children:[x.ratedAnswers??0," of ",x.eligibleAnswers]})]}),T&&em.filter(N=>x.counts[N]>0).map(N=>l.jsxs("div",{children:[l.jsx("dt",{children:Ui(N)}),l.jsx("dd",{children:x.counts[N]})]},N)),T&&l.jsxs("div",{children:[l.jsx("dt",{children:"Favorable share"}),l.jsx("dd",{children:fn.minRated})]}),x.unadmittedAssessments>0&&l.jsxs("div",{children:[l.jsx("dt",{children:fn.details.unadmitted}),l.jsx("dd",{children:x.unadmittedAssessments})]}),Object.entries(x.counts).filter(([N,I])=>I>0&&!["favorable","mixed","unfavorable"].includes(N)).map(([N,I])=>l.jsxs("div",{children:[l.jsx("dt",{children:Ui(N)}),l.jsx("dd",{children:I})]},N)),k&&l.jsxs("div",{children:[l.jsxs("dt",{children:["95% confidence range ",l.jsx(Ea,{text:S.limitation,placement:"bottom"})]}),l.jsx("dd",{children:k})]})]}),e.reason&&l.jsx("p",{className:"sentiment-class-details-reason",children:e.reason})]})]}):null}function k1(e){return!!(e?.configured&&e.overall&&e.overall.coverage.judged>0&&e.overall.score.favorableRate!==null)&&!ZA()}function mX({value:e}){if(!k1(e))return null;const n=e.overall,i=n.coverage.judged,r=UC(n.score),u=`${fn.overall} ${i} of ${n.coverage.selected} judged${r?`, 95% interval ${r}`:""}. ${n.provisional?"Provisional. ":""}${fn.states[n.state]}${n.reason?` ${n.reason}`:""}`;return l.jsx("div",{className:"project-row-stat","data-sentiment-score":!0,children:l.jsxs("div",{className:"metric-inline-block",children:[l.jsxs("div",{className:"flex items-center gap-1",children:[l.jsx("p",{className:"metric-inline-label",children:"Sentiment"}),l.jsx("span",{className:"relative z-10",children:l.jsx(Ea,{text:u,placement:"bottom"})})]}),x1(i)?l.jsxs("p",{className:"metric-inline-value",children:[n.score.favorableDisplay,l.jsx("span",{className:"sr-only",children:" favorable judgments, all query classes"})]}):l.jsxs("p",{className:"metric-inline-value text-secondary",children:[fn.tooFew,l.jsxs("span",{className:"sr-only",children:[" ratings for a favorable share, ",i," of ",v1," needed, all query classes"]})]}),l.jsx("p",{className:"metric-inline-caption","aria-hidden":"true"})]})})}const Ms=C.createContext(null);function xse(){return C.useContext(Ms)?.configured??!1}function wse({projectName:e,selection:n,runOptions:i=[],waitForResolvedRun:r=!1,evidenceReady:u=!0,hasSourceEvidence:h=!0,children:f}){return l.jsx(pX,{projectName:e,selection:n,runOptions:i,waitForResolvedRun:r,evidenceReady:u,hasSourceEvidence:h,children:f})}function pX({projectName:e,selection:n,runOptions:i,waitForResolvedRun:r,evidenceReady:u,hasSourceEvidence:h,children:f}){const b=JSON.stringify([e,n]),[v,x]=C.useState(null),S=C.useCallback(Pe=>x(Se=>Se?.key===b&&Se?.runId===Pe?.runId&&Se?.revision===Pe?.revision?Se:Pe?{...Pe,key:b}:null),[b]),k=u&&(!r||v?.key===b),T=r&&k&&v?{...n,runId:v.runId,revision:v.revision}:n,N=JSON.stringify([e,T]),{settings:I,branded:P,nonBrand:E,jobs:$}=nX(e,T,k&&h),[ee,L]=C.useState(!1),[F,Z]=C.useState(null),ae=C.useRef(null);C.useEffect(()=>{L(!1),Z(null)},[N]);const M=k&&!!(I.data?.enabled&&I.data.installEnabled),ue=(n.queryClass==="non-brand"?E.data:P.data)?.selection,Xe={...T,...ue?{...ue,runId:ue.runId??void 0,runIds:ue.runId?void 0:ue.runIds,revision:ue.revision??void 0,evaluationDefinitionId:ue.evaluationDefinitionId??void 0}:{}},nt=Xe.runId&&!i.some(Pe=>Pe.id===Xe.runId)?[{id:Xe.runId,label:"Displayed sweep"},...i]:i,Ge=Pe=>{Pe.preventDefault(),ae.current?.focus()};return l.jsxs(Ms.Provider,{value:{projectName:e,selection:T,resolveSource:S,settings:I,summaries:{branded:P,"non-brand":E},configured:M,hasSourceEvidence:h,openManage:Pe=>{ae.current=Pe,L(!0)},openEvidence:(Pe,Se,Ve)=>{ae.current=Ve,Z({selection:Pe,label:Se})}},children:[f,l.jsx(hg,{open:ee&&!!I.data?.actions.configure,onOpenChange:L,children:l.jsxs(Yd,{onCloseAutoFocus:Ge,className:"overflow-y-auto",children:[l.jsxs(fg,{children:[l.jsx(Xd,{children:"Manage sentiment"}),l.jsx(Jd,{children:"Classify saved answers and review the cost before submitting a backfill."})]}),I.data?.actions.configure&&l.jsx(AX,{projectName:e,settings:I.data,selection:Xe,runOptions:nt},JSON.stringify([I.data.evaluationDefinitionId,I.data.enabled,I.data.enablementEpoch])),$.data&&l.jsx(xX,{projectName:e,jobs:$.data.jobs})]})}),l.jsx(hg,{open:F!==null,onOpenChange:Pe=>{Pe||Z(null)},children:l.jsxs(Yd,{onCloseAutoFocus:Ge,className:"overflow-y-auto",children:[l.jsxs(fg,{children:[l.jsxs(Xd,{children:["Sentiment evidence",F?`: ${F.label}`:""]}),l.jsx(Jd,{children:"Stored judgments and exact quotations for the selected query and scope."})]}),F&&l.jsx(yX,{projectName:e,selection:F.selection},JSON.stringify(F.selection))]})})]})}function Sse(e,n){const i=C.useContext(Ms)?.resolveSource;C.useEffect(()=>{i?.(e?{runId:e,revision:n??void 0}:null)},[i,e,n])}function kse(){const e=C.useContext(Ms);return e?.settings.data?.actions.configure?l.jsx(Sg,{type:"button",variant:"outline",size:"sm",onClick:n=>e.openManage(n.currentTarget),children:e.settings.data.enabled?"Manage sentiment":"Enable sentiment"}):null}function KC(e,n){return!e?.configured||n==="unknown"||n==="unclassified"?null:n==="all"?aX:[n]}function hX({queryClass:e="all"}){const n=C.useContext(Ms),i=KC(n,e);return!n?.hasSourceEvidence||!i?.some(r=>S1(n.summaries[r].data))?null:l.jsx("ul",{className:"sentiment-legend","aria-hidden":"true",children:em.map(r=>l.jsxs("li",{children:[l.jsx("span",{className:`sentiment-legend-swatch ${GC[r]}`}),Ui(r)]},r))})}function jse({queryClass:e="all",legend:n=!0}){const i=C.useContext(Ms),r=KC(i,e),[u,h]=C.useState(null);if(!i||!r)return null;const f=i.hasSourceEvidence&&r.some(b=>i.summaries[b].data);return l.jsxs("div",{className:"sentiment-headlines",role:"group","aria-label":"Favorable answer scores",children:[f&&l.jsxs("div",{className:"sentiment-headlines-columns","aria-hidden":"true",children:[l.jsx("span",{className:"sentiment-headlines-favorable",children:fn.columns.favorable}),l.jsx("span",{className:"sentiment-headlines-ratings",title:fn.rated,children:fn.columns.rated})]}),r.map(b=>{const v=i.summaries[b];return l.jsxs("div",{className:"sentiment-class","data-query-class":b,children:[l.jsxs("div",{className:"sentiment-class-label",children:[l.jsx("span",{children:Pi[b]}),l.jsx(Ea,{text:fn.favorable})]}),i.hasSourceEvidence?v.data?l.jsxs(l.Fragment,{children:[l.jsx(iX,{value:v.data,label:Pi[b]}),l.jsx(sX,{value:v.data,label:Pi[b]}),l.jsx(lX,{coverage:v.data.coverage,label:Pi[b]}),l.jsx(cX,{value:v.data}),l.jsx(dX,{value:v.data,queryClass:b,open:u===b,setOpenClass:h})]}):v.isError?l.jsxs("p",{role:"alert",className:"sentiment-class-status",children:["Couldn’t load sentiment. ",l.jsx(ce,{variant:"ghost",onClick:()=>{v.refetch()},children:"Retry"})]}):l.jsx("p",{role:"status",className:"sentiment-class-status",children:"Loading sentiment…"}):l.jsx("p",{className:"sentiment-class-status",children:"No saved answers."})]},b)}),n&&l.jsx(hX,{queryClass:e})]})}function Ase({queryId:e,sourceSnapshotIds:n=[],queryClass:i,location:r,showLabel:u=!1}){const h=C.useContext(Ms);if(!h?.configured)return null;const f=i?h.summaries[i]:void 0,b=h.hasSourceEvidence?f?.data:void 0,v=b?.queries.filter(T=>T.queryClass===i&&(e?T.queryId===e:n.length>0)&&n.every(N=>T.sourceSnapshotIds.includes(N)))??[],x=v.length===1?v[0]:void 0,S=r===void 0?x:x?.locations.find(T=>T.location===r);if(!x||!S)return l.jsx("span",{className:"text-sm text-secondary",children:h.hasSourceEvidence&&f?.isPending&&(e||n.length)?"Loading…":"Unavailable"});const k={...h.selection,...b.selection,runId:b.selection.runId??void 0,runIds:b.selection.runId?void 0:b.selection.runIds,revision:b.selection.revision??void 0,evaluationDefinitionId:b.selection.evaluationDefinitionId??void 0,queryClass:x.queryClass,queryId:x.queryId,executionNodeKey:x.executionNodeKey??void 0,...r===void 0?{}:{location:r??"none"}};return l.jsxs(ce,{type:"button",variant:"ghost",className:"h-auto min-h-11 flex-col items-start gap-0 px-1","aria-label":`View ${Pi[x.queryClass]} sentiment evidence for ${x.queryText}`,onKeyDown:T=>T.stopPropagation(),onClick:T=>{T.stopPropagation(),h.openEvidence(k,x.queryText,T.currentTarget)},children:[u&&l.jsx("span",{className:"text-sm font-normal text-secondary",children:"Favorable"}),l.jsx("span",{className:"font-mono text-primary",children:S.score.favorableDisplay}),l.jsxs("span",{className:"text-sm font-normal text-secondary",children:[S.coverage.judged," judged"]}),S.provisional&&l.jsx("span",{className:"text-xs font-normal text-caution",children:"Provisional"})]})}function fX(e){return e.outcome==="subject-not-mentioned"?"Not mentioned":e.outcome==="running"?"Classifying":e.outcome==="waiting-to-retry"?"Retrying":e.outcome?Ui(e.outcome):e.state==="not-measured"?"Not classified":e.state==="processing"?"Classifying":e.state==="failed"?"Failed":e.state==="canceled"?"Canceled":"Unavailable"}function Cse({queryId:e,sourceSnapshotIds:n,queryClass:i,provider:r,model:u,location:h,showSubjects:f=!1,showLabel:b=!1}){const v=C.useContext(Ms);if(!v?.configured)return null;const x=i?v.summaries[i]:void 0,S=v.hasSourceEvidence?x?.data:void 0,k=S?.queries.filter(I=>I.queryClass===i&&(!e||I.queryId===e)&&n.length>0&&n.every(P=>I.sourceSnapshotIds.includes(P)))??[],T=k.length===1?k[0]:void 0,N=T?.assessments?.filter(I=>n.includes(I.sourceSnapshotId)&&I.provider===r&&I.location===h&&(u===void 0||I.servedModel===u))??[];return l.jsxs("div",{role:"group",className:"text-sm text-secondary","aria-label":`${r||"Saved answer"} sentiment`,children:[b&&l.jsx("span",{className:"block text-sm text-secondary",children:"Sentiment"}),N.length?N.map(I=>{const P=fX(I),E=I.outcome==="favorable"?"positive":I.outcome==="unfavorable"?"negative":I.outcome==="mixed"?"caution":"neutral",$=l.jsxs(l.Fragment,{children:[f&&l.jsxs("span",{children:[I.subjectLabel," · "]}),l.jsx(xn,{tone:E,className:"max-w-full shrink-0 rounded-none border-0 bg-transparent p-0 text-sm font-normal tracking-normal [overflow-wrap:normal]",children:P})]}),ee={...v.selection,...S.selection,runId:S.selection.runId??void 0,runIds:S.selection.runId?void 0:S.selection.runIds,revision:S.selection.revision??void 0,evaluationDefinitionId:S.selection.evaluationDefinitionId??void 0,queryClass:T.queryClass,queryId:T.queryId,executionNodeKey:T.executionNodeKey??void 0,assessmentId:I.assessmentId??void 0};return l.jsxs("div",{className:"flex items-center gap-1",children:[I.assessmentId?l.jsx(ce,{type:"button",variant:"ghost",className:"h-auto min-h-11 flex-wrap justify-start whitespace-normal px-1 text-left text-sm","aria-label":`View ${I.provider} sentiment evidence for ${I.subjectLabel}: ${P}`,onKeyDown:L=>L.stopPropagation(),onClick:L=>{L.stopPropagation(),v.openEvidence(ee,`${T.queryText} · ${I.provider} · ${I.subjectLabel}`,L.currentTarget)},children:$}):l.jsx("span",{children:$}),I.reason&&l.jsx(Ea,{text:I.reason})]},JSON.stringify([I.sourceSnapshotId,I.subjectId,I.assessmentId]))}):l.jsx("span",{children:v.hasSourceEvidence&&x?.isPending&&n.length?"Loading…":"Unavailable"})]})}function gX({item:e}){return l.jsxs("article",{className:"space-y-4 border-b border-default py-5 text-sm text-secondary",children:[l.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[l.jsx("strong",{className:"text-primary",children:e.subject.displayName}),l.jsx(xn,{tone:"neutral",children:Ui(e.outcome)}),l.jsx("span",{children:Pi[e.context.queryClass]}),l.jsx("span",{children:e.context.provider}),l.jsx("span",{children:e.context.servedModel??"Source model unavailable"}),l.jsx("span",{children:e.context.location??"No location"})]}),e.reason&&l.jsx("p",{children:e.reason}),l.jsxs("section",{children:[l.jsx("h3",{className:"mb-2 text-heading",children:"Conclusion evidence"}),e.conclusion.length?e.conclusion.map(n=>l.jsx("blockquote",{className:"mb-2 border-l border-strong pl-3 text-primary",children:n.text},`${n.id}:${n.start}`)):l.jsx("p",{children:"No valid conclusion evidence is available."})]}),l.jsxs("section",{children:[l.jsx("h3",{className:"mb-2 text-heading",children:"Complaint evidence"}),e.complaint?.length?e.complaint.map(n=>l.jsx("blockquote",{className:"mb-2 border-l border-strong pl-3 text-primary",children:n.text},`${n.id}:${n.start}`)):l.jsx("p",{children:"No complaint was identified."})]}),l.jsxs("details",{children:[l.jsx("summary",{className:"cursor-pointer",children:"Original source answer"}),l.jsx("p",{className:"mt-2 whitespace-pre-wrap break-words text-primary",children:e.sourceText})]}),l.jsxs("details",{children:[l.jsx("summary",{className:"cursor-pointer",children:"Assessment provenance"}),l.jsxs("dl",{className:"mt-3 space-y-2 break-all",children:[l.jsx("dt",{children:"Query"}),l.jsx("dd",{children:e.context.queryText}),l.jsx("dt",{children:"Subject"}),l.jsxs("dd",{children:[e.subject.displayName," (",e.subject.id,")"]}),l.jsx("dt",{children:"Run"}),l.jsx("dd",{children:e.runId}),l.jsx("dt",{children:"Revision"}),l.jsx("dd",{children:e.context.revision??"Unavailable"}),l.jsx("dt",{children:"Evaluator"}),l.jsx("dd",{children:e.returnedModel??"Unavailable"}),l.jsx("dt",{children:"Evaluation definition"}),l.jsx("dd",{children:e.evaluationDefinitionId}),l.jsx("dt",{children:"Source snapshot"}),l.jsx("dd",{children:e.sourceSnapshotId}),l.jsx("dt",{children:"Source hash"}),l.jsx("dd",{children:e.sourceTextHash}),e.context.usageEdges.map((n,i)=>l.jsxs("div",{children:[l.jsx("dt",{children:"Assignment"}),l.jsxs("dd",{children:["Target ",n.targetId,"; Property ",n.propertyId??"None","; market ",n.marketId??"None","; ",n.queryClass]})]},i))]})]})]})}function yX({projectName:e,selection:n}){const[i,r]=C.useState(),u=yt({queryKey:vc(e,"evidence",n,i),queryFn:()=>jK(e,n,i),retry:!1});return u.isPending?l.jsx("p",{role:"status",className:"mt-4 text-sm text-secondary",children:"Loading sentiment evidence…"}):u.isError?l.jsxs("p",{role:"alert",className:"mt-4 text-sm text-secondary",children:["Could not load sentiment evidence. ",l.jsx(ce,{variant:"outline",onClick:()=>{u.refetch()},children:"Retry evidence"})]}):l.jsxs(l.Fragment,{children:[u.data.items.length?u.data.items.map(h=>l.jsx(gX,{item:h},h.assessmentId)):l.jsx("p",{className:"mt-4 text-sm text-secondary",children:"No stored sentiment evidence for this query and scope."}),l.jsxs("div",{className:"mt-3 flex gap-2",children:[i&&l.jsx(ce,{variant:"outline",onClick:()=>r(void 0),children:"First evidence page"}),u.data.nextCursor&&l.jsx(ce,{variant:"outline",onClick:()=>r(u.data.nextCursor??void 0),children:"Next evidence page"})]})]})}function bX({projectName:e,jobId:n}){const[i,r]=C.useState(),u=yt({queryKey:vc(e,`job:${n}`,void 0,i),queryFn:()=>_K(e,n,i),retry:!1});return u.isPending?l.jsx("p",{role:"status",children:"Loading attempts…"}):u.isError?l.jsxs("p",{role:"alert",children:["Could not load attempts. ",l.jsx(ce,{variant:"outline",onClick:()=>{u.refetch()},children:"Retry attempts"})]}):l.jsxs(l.Fragment,{children:[u.data.attempts.map(h=>l.jsxs("p",{children:[h.errorCode??"Request complete","; ",h.usage.kind==="unknown"?"Usage unknown":`${h.usage.inputTokens??"Unknown"} input tokens (${h.usage.kind})`]},h.id)),l.jsxs("div",{className:"mt-2 flex gap-2",children:[i&&l.jsx(ce,{variant:"outline",onClick:()=>r(void 0),children:"Newest attempts"}),u.data.nextAttemptCursor&&l.jsx(ce,{variant:"outline",onClick:()=>r(u.data.nextAttemptCursor??void 0),children:"Older attempts"})]})]})}function vX({projectName:e,job:n}){const[i,r]=C.useState(!1);return l.jsxs("details",{onToggle:u=>r(u.currentTarget.open),children:[l.jsx("summary",{children:"Job details"}),n.cancellationReason&&l.jsx("p",{children:n.cancellationReason}),Object.entries(n.counts).filter(([,u])=>u>0).map(([u,h])=>l.jsxs("p",{children:[Ui(u),": ",h]},u)),l.jsxs("p",{children:["Attempts: ",n.attemptCount]}),i&&n.attemptCount>0&&l.jsx(bX,{projectName:e,jobId:n.id})]})}function xX({projectName:e,jobs:n}){return l.jsxs("details",{className:"mt-6 text-sm text-secondary",children:[l.jsx("summary",{className:"cursor-pointer",children:"Recent sentiment jobs"}),n.length===0?l.jsx("p",{className:"mt-2",children:"No sentiment jobs have been submitted."}):l.jsx("div",{className:"data-table-wrapper mt-3",children:l.jsxs("table",{className:"data-table","aria-label":"Sentiment jobs",children:[l.jsx("thead",{children:l.jsxs("tr",{children:[l.jsx("th",{children:"Submitted"}),l.jsx("th",{children:"State"}),l.jsx("th",{children:"Selected"}),l.jsx("th",{children:"Details"})]})}),l.jsx("tbody",{children:n.map(i=>l.jsxs("tr",{children:[l.jsx("td",{children:WK(i.createdAt)}),l.jsx("td",{children:Ui(i.state)}),l.jsx("td",{children:i.selected}),l.jsx("td",{children:l.jsx(vX,{projectName:e,job:i})})]},i.id))})]})})]})}const wX={probe:"Probe sweeps","unsupported-run-kind":"Not an answer sweep","failed-run":"Failed sweep","incomplete-run":"Incomplete sweep","legacy-missing-provenance":"Saved without its frozen query and subject record","legacy-missing-language":"Saved before the answer language was recorded","excluded-branded":"Branded answers (backfill that class separately)","excluded-non-brand":"Non-brand answers (backfill that class separately)"};function SX(e){return wX[e]??Ui(e)}function HC(e){return[e.provider&&`engine ${e.provider}`,e.model&&`model ${e.model}`,e.location&&(e.location==="none"?"no location":`location ${e.location}`),e.scope!=="project"&&e.scopeKey&&`${e.scope} ${e.scopeKey}`,e.marketKey&&`market ${e.marketKey}`,e.queryId&&`query ${e.queryId}`,e.revision!==void 0&&`revision ${e.revision}`].filter(n=>!!n)}function kX(e){const n=HC(e);return[`${Pi[e.queryClass]} queries`,...n.length?n:["whole sweep"]].join(" · ")}function jX(e,n,i,r){return r?{...e,queryClass:i,queryId:void 0,runIds:void 0,runId:n}:{mode:"auto",scope:"project",queryClass:i,runId:n}}function AX({projectName:e,settings:n,selection:i,runOptions:r}){const u=ta(),[h,f]=C.useState(n.enabled),[b,v]=C.useState(i.runId??""),[x,S]=C.useState(i.queryClass),[k,T]=C.useState(!1),[N,I]=C.useState(null),P=C.useRef(null),E=HC({...i,queryId:void 0}),$=()=>u.invalidateQueries({queryKey:["sentiment",e]}),ee=()=>{I(null),P.current=null},L=Ha({mutationFn:async()=>{if(!(await _d(e)).actions.configure)throw new Error("Administrator permission is required to configure sentiment.");return kK(e,{enabled:h})},onSuccess:async()=>{ee(),await $(),await u.invalidateQueries({queryKey:["project-overview-slim"]})},onError:$}),F=Ha({mutationFn:async()=>{if(!(await _d(e)).actions.backfill)throw new Error("Administrator permission is required to backfill sentiment.");return AK(e,jX(i,b,x,k&&E.length>0))},onSuccess:M=>{I(M),P.current=crypto.randomUUID()},onError:$}),Z=Ha({mutationFn:async()=>{if(!N?.previewToken||!P.current)throw new Error("Create and review a backfill preview first.");if(!(await _d(e)).actions.backfill)throw new Error("Administrator permission is required to backfill sentiment.");return CK(e,N.previewToken,P.current)},onSuccess:async()=>{ee(),await $()},onError:$}),ae=L.isPending||F.isPending||Z.isPending;return l.jsxs("div",{className:"mt-5 space-y-5 text-sm text-secondary",children:[l.jsx("p",{children:n.disclosure}),!n.ready&&l.jsx("p",{children:n.readinessReasons.join("; ")||"An operator must configure sentiment on this installation."}),l.jsxs("form",{className:"space-y-3",onSubmit:M=>{M.preventDefault(),L.mutate()},children:[l.jsxs("label",{className:"flex items-center gap-2",children:[l.jsx("input",{type:"checkbox",checked:h,disabled:ae,onChange:M=>{f(M.target.checked),ee()}}),"Enable project sentiment"]}),l.jsx("p",{children:"Enabling applies to future completed sweeps. Past sweeps require an explicit backfill."}),l.jsx(Sg,{type:"submit",disabled:ae,children:L.isPending?"Saving…":"Save sentiment settings"}),L.isError&&l.jsx("p",{role:"alert",children:Oi(L.error)}),L.isSuccess&&l.jsx("p",{role:"status",children:"Sentiment settings saved."})]}),n.actions.backfill&&l.jsxs("section",{className:"space-y-3",children:[l.jsx("h3",{children:"Backfill a saved sweep"}),l.jsxs("label",{className:"block",children:["Saved sweep",l.jsxs("select",{className:"mt-1 block w-full rounded-md border border-default bg-bg p-2 text-primary",value:b,disabled:ae,onChange:M=>{v(M.target.value),ee()},children:[l.jsx("option",{value:"",children:"Select a saved sweep"}),r.map(M=>l.jsx("option",{value:M.id,children:M.label},M.id))]})]}),l.jsxs("label",{className:"block",children:["Query class",l.jsxs("select",{className:"mt-1 block w-full rounded-md border border-default bg-bg p-2 text-primary",value:x,disabled:ae,onChange:M=>{S(M.target.value),ee()},children:[l.jsx("option",{value:"non-brand",children:"Non-brand"}),l.jsx("option",{value:"branded",children:"Branded"})]})]}),l.jsx("p",{children:"The backfill covers every engine, location and query of the chosen sweep for this query class."}),E.length>0&&l.jsxs("label",{className:"flex items-start gap-2",children:[l.jsx("input",{type:"checkbox",className:"mt-1",checked:k,disabled:ae,onChange:M=>{T(M.target.checked),ee()}}),l.jsxs("span",{children:["Limit to the current view",l.jsx("span",{className:"block",children:E.join(" · ")})]})]}),l.jsx(ce,{variant:"outline",disabled:ae||!b||!n.enabled||!n.ready,onClick:()=>{ee(),F.mutate()},children:F.isPending?"Preparing preview…":"Preview sentiment backfill"}),F.isError&&l.jsx("p",{role:"alert",children:Oi(F.error)}),N&&l.jsxs("div",{className:"space-y-3",children:[l.jsxs("dl",{className:"grid grid-cols-[1fr_auto] gap-2",children:[l.jsx("dt",{children:"Selection"}),l.jsx("dd",{className:"text-right",children:kX(N.selection)}),l.jsx("dt",{children:"Eligible assessments"}),l.jsx("dd",{children:N.eligibleAssessments}),l.jsx("dt",{children:"Already classified"}),l.jsx("dd",{children:N.alreadyClassified}),l.jsx("dt",{children:"Estimated input tokens"}),l.jsx("dd",{children:N.estimatedInputTokens}),l.jsx("dt",{children:"Estimated cost (USD)"}),l.jsx("dd",{children:N.estimatedCostUsd??"Unavailable"})]}),l.jsx(Ea,{text:N.estimateMethod}),N.eligibleAssessments===0&&l.jsx("p",{children:"No saved answers in this selection can be classified."}),N.skipped.length>0&&l.jsxs("div",{children:[l.jsx("p",{children:"Not included:"}),l.jsx("ul",{"aria-label":"Skipped assessments",className:"list-disc pl-5",children:N.skipped.map(M=>l.jsxs("li",{children:[SX(M.reason),": ",M.count]},`${M.runId}:${M.reason}`))})]}),l.jsx(Sg,{disabled:ae||!N.previewToken||N.eligibleAssessments===0,onClick:()=>Z.mutate(),children:Z.isPending?"Submitting…":"Confirm sentiment backfill"})]}),Z.isError&&l.jsxs("p",{role:"alert",children:[Oi(Z.error)," Retry uses the same request key."]}),Z.isSuccess&&l.jsx("p",{role:"status",children:"Backfill submitted. Progress is available in Recent jobs."})]})]})}const CX=20,NX=6;function _X({points:e,tone:n}){const i=C.useId();if(e.length===0)return null;const r=42,u=132,h=5,f=u-h*2,b=r-h*2,v=b-NX,x=E=>h+E/Math.max(e.length-1,1)*f,S=yG(e),k=Math.min(...e),T=Math.max(...e),N=Math.max(T-k,CX),I=(T+k)/2-N/2,P=e.map((E,$)=>({x:x($),y:h+(1-(E-I)/N)*v}));return l.jsxs("svg",{className:`sparkline sparkline-${n}${S?" sparkline-provisional":""}`,viewBox:`0 0 ${u} ${r}`,"aria-hidden":"true",children:[l.jsx("defs",{children:l.jsx("clipPath",{id:i,children:l.jsx("rect",{x:h,y:h,width:f,height:b,rx:"8"})})}),l.jsx("line",{className:"sparkline-guide",x1:h,x2:u-h,y1:r-h,y2:r-h}),P.length===1?l.jsx("circle",{className:"sparkline-point",cx:P[0].x,cy:P[0].y,r:"3"}):l.jsx("polyline",{clipPath:`url(#${i})`,points:P.map(E=>`${E.x},${E.y}`).join(" "),vectorEffect:"non-scaling-stroke"})]})}function TX({project:e,sentimentColumn:n}){return l.jsxs("div",{className:`project-row relative${n?" project-row-with-sentiment":""}`,children:[l.jsx("div",{className:"project-row-chart",children:l.jsx(_X,{points:e.trend,tone:uC(e.lastRun.status)})}),l.jsxs("div",{className:"project-row-primary",children:[l.jsxs(We,{to:"/projects/$projectName",params:{projectName:e.project.name},className:"after:absolute after:inset-0 after:rounded-xl focus-visible:outline-none focus-visible:after:ring-2 focus-visible:after:ring-mono-400",children:[l.jsx("p",{className:"project-name",children:e.project.name}),l.jsx("p",{className:"project-domain",children:e.project.canonicalDomain})]}),l.jsx("p",{className:"project-insight",children:e.insight})]}),l.jsx("div",{className:"project-row-stat",children:l.jsxs("div",{className:"metric-inline-block",children:[l.jsx("p",{className:"metric-inline-label",children:"Mentioned"}),l.jsx("p",{className:`metric-inline-value ${e.mentionTone==="caution"?"text-caution-400":""}`,children:e.hasMeasurement===!1?"Not measured":sn(e.mentionScore,xt.percent)}),l.jsx("p",{className:`metric-inline-caption${e.providerCoverage?" text-caution":""}`,title:e.providerCoverage,children:e.providerCoverage?l.jsxs(l.Fragment,{children:[l.jsx("span",{className:"sr-only",children:"Partial sweep: "}),e.providerCoverage]}):e.mentionDelta})]})}),l.jsx("div",{className:"project-row-stat",children:l.jsxs("div",{className:"metric-inline-block",children:[l.jsxs("p",{className:"metric-inline-label",children:[l.jsx("span",{"aria-hidden":"true",children:"Pressure"}),l.jsx("span",{className:"sr-only",children:"Competitor pressure"})]}),l.jsx("p",{className:"metric-inline-value",children:e.hasMeasurement===!1?"Not measured":e.competitorPressureLabel}),l.jsx("p",{className:"metric-inline-caption","aria-hidden":"true"})]})}),k1(e.sentiment)?l.jsx(mX,{value:e.sentiment}):n&&l.jsx("div",{className:"project-row-stat","aria-hidden":"true","data-sentiment-placeholder":!0}),l.jsx("span",{className:"project-row-link",children:l.jsx(Eg,{className:"h-4 w-4 text-muted"})})]})}function EX(){const{isAdmin:e}=fa(),n=Qc(),{dashboard:i,isLoading:r,isError:u,refetch:h}=Mm(),f=i??n?.dashboard,v=f1(!n,n?.health),{openRun:x}=g1();if(u&&!f)return l.jsxs("div",{className:"page-container",children:[l.jsx("div",{className:"page-header",children:l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Portfolio unavailable"}),l.jsx("p",{className:"page-subtitle",children:"Canonry could not load the project list."})]})}),l.jsxs("div",{className:"max-w-xl rounded-lg border border-negative bg-negative-soft p-4",role:"alert",children:[l.jsx("p",{className:"text-sm font-medium text-heading",children:"Your projects have not been changed."}),l.jsx("p",{className:"mt-1 text-sm text-secondary",children:"Check the connection or sign in again, then retry."}),l.jsx(ce,{type:"button",variant:"secondary",className:"mt-4",onClick:()=>{h()},children:"Retry loading portfolio"})]})]});if(!f||r)return l.jsxs("div",{className:"page-skeleton",children:[l.jsxs("div",{className:"page-skeleton-header",children:[l.jsx("div",{className:"skeleton-text h-6 w-32"}),l.jsx("div",{className:"skeleton-text-sm w-64"})]}),l.jsx("div",{className:"space-y-3",children:[1,2,3].map(E=>l.jsxs("div",{className:"rounded-xl border border-default bg-surface p-4 flex items-center gap-4",children:[l.jsxs("div",{className:"flex-1 space-y-2",children:[l.jsx("div",{className:"skeleton-text w-36"}),l.jsx("div",{className:"skeleton-text-sm w-48"})]}),l.jsx("div",{className:"skeleton-text w-16"}),l.jsx("div",{className:"skeleton-text w-16"}),l.jsx("div",{className:"skeleton h-8 w-20 rounded"})]},E))})]});const S=f.portfolioOverview,k=S.projects.length>0&&S.projects.every(E=>E.hasMeasurement===!1),T=S.projects.some(E=>k1(E.sentiment)),N=S.attentionItems.map(E=>k&&E.id==="attention_stable"?{...E,tone:"neutral",title:"Awaiting first measurement",detail:"Visibility results will appear after the first sweep."}:E),I=v.data??n?.health??{apiStatus:{label:"API",state:"checking",detail:"Checking service health"},workerStatus:{label:"Worker",state:"checking",detail:"Checking service health"}},P=FQ(S.systemHealth.filter(E=>e||E.id==="api"||E.id==="worker"),I,f.settings);return l.jsxs("div",{className:"page-container",children:[l.jsx("div",{className:"page-header",children:l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Portfolio"}),l.jsx("p",{className:"page-subtitle",children:"Visibility across all projects."})]})}),S.projects.length>0?l.jsx("div",{className:"project-list project-list-scrollable",children:S.projects.map(E=>l.jsx(TX,{project:E,sentimentColumn:T},E.project.id))}):l.jsxs(Ra,{className:"surface-card empty-card",children:[l.jsx("h3",{children:S.emptyState?.title??"No projects yet"}),l.jsx("p",{className:"supporting-copy",children:S.emptyState?.detail}),l.jsx(ce,{size:"sm",asChild:!0,children:l.jsx(We,{to:S.emptyState?.ctaHref==="/setup"||!S.emptyState?.ctaHref?"/setup":"/",children:S.emptyState?.ctaLabel??"Launch setup"})})]}),l.jsxs("div",{className:"overview-secondary-grid",children:[N.length>0&&l.jsxs("section",{className:"overview-secondary-section",children:[l.jsx("div",{className:"section-head section-head-inline",children:l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Needs attention"}),l.jsx("h2",{className:"section-title-sm",children:"What changed"})]})}),l.jsx("div",{className:"attention-list attention-list-scrollable",children:N.map(E=>E.href?l.jsxs(We,{to:E.href,className:`attention-item attention-item-${E.tone}`,children:[l.jsxs("div",{children:[l.jsx("p",{className:"attention-title",children:E.title}),l.jsx("p",{className:"attention-detail",children:E.detail})]}),E.actionLabel&&l.jsx("span",{className:"attention-action",children:E.actionLabel})]},E.id):l.jsxs("div",{className:`attention-item attention-item-static attention-item-${E.tone}`,children:[l.jsxs("div",{children:[l.jsx("p",{className:"attention-title",children:E.title}),l.jsx("p",{className:"attention-detail",children:E.detail})]}),E.actionLabel&&l.jsx("span",{className:"attention-action",children:E.actionLabel})]},E.id))})]}),l.jsxs("section",{className:"overview-secondary-section",children:[l.jsx("div",{className:"section-head section-head-inline",children:l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Recent runs"}),l.jsx("h2",{className:"section-title-sm",children:"Activity"})]})}),l.jsx("div",{className:"compact-stack compact-stack-scrollable",children:S.recentRuns.length>0?S.recentRuns.map(E=>l.jsxs("button",{className:"compact-run",type:"button",onClick:()=>x(E.id),children:[l.jsxs("div",{children:[l.jsx("p",{className:"compact-run-title",children:E.projectName}),l.jsx("p",{className:"compact-run-detail",children:E.summary})]}),l.jsx(h1,{status:E.status})]},E.id)):l.jsx("p",{className:"supporting-copy",children:"Run history appears here after the first launch."})})]})]}),l.jsxs("section",{className:"page-section",children:[l.jsx("div",{className:"section-head section-head-inline",children:l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"System health"}),l.jsx("h2",{className:"section-title-sm",children:"Infrastructure"})]})}),l.jsx("div",{className:"divide-y divide-default border-y border-default",children:P.map(E=>{const $=E.id==="api"?I.apiStatus:E.id==="worker"?I.workerStatus:void 0,ee=$?$.state==="ok"?void 0:Kr($):E.tone==="positive"?void 0:E.meta;return l.jsxs("div",{className:"flex items-start justify-between gap-4 py-3",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-medium text-heading",children:E.label}),ee&&l.jsx("p",{className:"mt-1 text-sm text-secondary",children:ee})]}),l.jsx(xn,{tone:E.tone,title:$?Kr($):E.meta,children:E.detail})]},E.id)})})]})]})}const RX='a, button, input, select, textarea, label, [role="button"], [role="link"], [role="checkbox"], [role="menuitem"]';function DX(e){if(e.defaultPrevented||e.button!==0||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey)return!1;const n=e.target;if(n&&typeof n.closest=="function"&&n.closest(RX))return!1;const i=typeof window<"u"?window.getSelection():null;return!(i&&!i.isCollapsed&&i.toString().trim()!=="")}function zX({onApplied:e}){const{canWrite:n}=fa(),[i,r]=C.useState(""),[u,h]=C.useState(!1),[f,b]=C.useState([]),[v,x]=C.useState([]);if(ZA()||!n)return null;const S=async()=>{if(!i.trim())return;h(!0),b([]),x([]);const k=M5(i),T=[],N=[];for(let I=0;I<k.length;I++){const P=k[I];if(P.errors.length>0){T.push(`Document ${I+1}: ${P.errors[0]?.message}`);continue}const E=P.toJSON();if(!(!E||typeof E!="object"))try{const $=await mK(E);N.push(`Applied "${$.displayName||$.name}" (revision ${$.configRevision})`)}catch($){T.push(`Document ${I+1}: ${Oi($)}`)}}b(N),x(T),h(!1),N.length>0&&(kn({title:"YAML applied",detail:`Applied ${N.length} document${N.length===1?"":"s"} successfully.`,tone:T.length>0?"caution":"positive",dedupeKey:"yaml:apply",dedupeMode:"replace"}),e())};return l.jsxs("section",{className:"mt-8",children:[l.jsx("div",{className:"page-section-divider"}),l.jsx("div",{className:"section-head mt-6",children:l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Config as code"}),l.jsx("h2",{className:"text-sm font-medium text-strong",children:"Apply YAML"})]})}),l.jsxs("p",{className:"text-muted text-sm mb-3",children:["Paste a ",l.jsx("code",{className:"text-secondary",children:"canonry.yaml"})," config (multi-document YAML with ",l.jsx("code",{className:"text-secondary",children:"---"})," separators supported)."]}),l.jsx("textarea",{className:"setup-input w-full font-mono text-xs",rows:10,placeholder:`apiVersion: canonry/v1
|
|
65
|
+
kind: Project
|
|
66
|
+
metadata:
|
|
67
|
+
name: my-project
|
|
68
|
+
spec:
|
|
69
|
+
canonicalDomain: example.com
|
|
70
|
+
country: US
|
|
71
|
+
language: en
|
|
72
|
+
queries: []`,value:i,onChange:k=>r(k.target.value)}),f.length>0&&l.jsx("ul",{className:"mt-2 space-y-1",children:f.map((k,T)=>l.jsx("li",{className:"text-positive-400 text-sm",children:k},T))}),v.length>0&&l.jsx("ul",{className:"mt-2 space-y-1",children:v.map((k,T)=>l.jsx("li",{className:"text-negative-400 text-sm",children:k},T))}),l.jsx("div",{className:"mt-3",children:l.jsx(ce,{type:"button",disabled:!i.trim()||u,onClick:hn(S),children:u?"Applying...":"Apply"})})]})}function IX(){const{dashboard:e,isLoading:n,refetch:i}=Mm(),{canWrite:r,isAdmin:u}=fa(),h=Ts();if(!e||n)return l.jsxs("div",{className:"page-skeleton",children:[l.jsxs("div",{className:"page-skeleton-header",children:[l.jsx("div",{className:"skeleton-text h-6 w-28"}),l.jsx("div",{className:"skeleton-text-sm w-40"})]}),l.jsxs("div",{className:"rounded-xl border border-default bg-surface overflow-hidden",children:[l.jsx("div",{className:"p-3 border-b border-default flex gap-8",children:["Name","Domain","Mentions","Last run","Country"].map(b=>l.jsx("div",{className:"skeleton-text-sm w-16"},b))}),[1,2,3].map(b=>l.jsxs("div",{className:"p-3 border-b border-subtle flex gap-8 items-center",children:[l.jsxs("div",{className:"flex-1 space-y-1",children:[l.jsx("div",{className:"skeleton-text w-28"}),l.jsx("div",{className:"skeleton-text-sm w-16"})]}),l.jsx("div",{className:"skeleton-text w-24"}),l.jsx("div",{className:"skeleton h-5 w-14 rounded-full"}),l.jsx("div",{className:"skeleton h-5 w-16 rounded-full"}),l.jsx("div",{className:"skeleton-text-sm w-8"})]},b))]})]});const f=e.projects;return l.jsxs("div",{className:"page-container",children:[l.jsxs("div",{className:"page-header",children:[l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Projects"}),l.jsxs("p",{className:"page-subtitle",children:[f.length," project",f.length!==1?"s":""," tracked"]})]}),u?l.jsx("div",{className:"page-header-right",children:l.jsxs(ce,{type:"button",onClick:()=>{h({to:"/setup",search:{experience:"platform"}})},children:[l.jsx(If,{className:"size-4 mr-1.5"}),f.length===0?"Map a site":"Add project"]})}):null]}),f.length>0?l.jsx("div",{className:"data-table-wrapper",children:l.jsxs("table",{className:"data-table",children:[l.jsx("thead",{children:l.jsxs("tr",{children:[l.jsx("th",{children:"Name"}),l.jsx("th",{children:"Domain"}),l.jsx("th",{children:"Mentions"}),l.jsx("th",{children:"Last run"}),l.jsx("th",{className:"text-right",children:"Country"})]})}),l.jsx("tbody",{children:f.map(b=>{const v=b.recentRuns[0];return l.jsxs("tr",{className:"cursor-pointer",onClick:x=>{DX(x)&&h({to:"/projects/$projectName",params:{projectName:b.project.name}})},children:[l.jsxs("td",{children:[l.jsx(We,{to:"/projects/$projectName",params:{projectName:b.project.name},className:"text-heading font-medium hover:underline",children:b.project.displayName||b.project.name}),l.jsx("p",{className:"text-[11px] text-muted",children:b.project.name})]}),l.jsx("td",{className:"text-secondary",children:b.project.canonicalDomain}),l.jsx("td",{children:l.jsx(xn,{tone:b.mentionSummary.tone,children:b.mentionSummary.value})}),l.jsx("td",{className:"text-muted text-sm",children:v?l.jsx(h1,{status:v.status}):l.jsx("span",{className:"text-faint",children:"No runs"})}),l.jsx("td",{className:"text-right text-muted",children:b.project.country})]},b.project.id)})})]})}):l.jsxs(Ra,{className:"surface-card empty-card",children:[l.jsx("h3",{children:"No projects yet"}),l.jsx("p",{className:"supporting-copy",children:"Map a public site to capture its Page Health baseline and exact fixes."}),u?l.jsxs(ce,{type:"button",onClick:()=>{h({to:"/setup",search:{experience:"platform"}})},children:[l.jsx(If,{className:"size-4 mr-1.5"}),"Map a site"]}):null]}),r?l.jsx(zX,{onApplied:()=>{i()}}):null]})}const PS="canonry.onboarding-session.v1",tm="canonry.onboarding-launched-run.v1",j1="canonry.onboarding-handoff.v1",OX=/^[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i,qX=["system","project","queries","competitors","run"];function PX(e){return qX[e]??"system"}function MX(e){if(!e.apiReady)return"api_unavailable";if(e.databaseConfigured===!1)return"database_unavailable";if(!e.workerReady)return"worker_unavailable";if(!e.providerReady)return"no_provider"}function BX(e){return e.apiStatus.state!=="checking"&&e.workerStatus.state!=="checking"}const LX={NO_PROVIDER:"no_provider",NO_QUERIES:"no_queries",RATE_LIMITED:"rate_limited",QUOTA_EXCEEDED:"rate_limited",PROVIDER_AUTH:"provider_auth",AUTH_INVALID:"provider_auth",FORBIDDEN:"provider_auth",NETWORK:"network",CONNECTION_ERROR:"network",RUN_IN_PROGRESS:"run_rejected",RUN_CANCELLED:"run_cancelled"};function xc(e,n){const i=e&&typeof e=="object"&&"code"in e?String(e.code):"";return LX[i]??n}function A1(){try{const e=typeof window<"u"?window.sessionStorage.getItem(PS):null;if(e&&OX.test(e))return e;const n=kg();return typeof window<"u"&&window.sessionStorage.setItem(PS,n),n}catch{return kg()}}function C1(){return kg()}function QC(e){if(!e||typeof e!="object")return!1;const n=e;return typeof n.projectName=="string"&&n.projectName.length>0&&typeof n.runId=="string"&&n.runId.length>0&&typeof n.handled=="boolean"}function FC(e,n){try{typeof window<"u"&&window.sessionStorage.setItem(tm,JSON.stringify({projectName:e,runId:n,handled:!1}))}catch{}}function ZC(e){if(!e)return null;try{if(typeof window>"u")return null;const n=window.sessionStorage.getItem(tm);if(!n)return null;const i=JSON.parse(n);return!QC(i)||i.projectName!==e||i.handled?null:i}catch{return null}}function nm(e){try{if(typeof window>"u")return;const n=window.sessionStorage.getItem(tm);if(!n)return;const i=JSON.parse(n);if(!QC(i)||i.runId!==e)return;window.sessionStorage.setItem(tm,JSON.stringify({...i,handled:!0}))}catch{}}function $X(e){try{typeof window<"u"&&window.sessionStorage.setItem(j1,e)}catch{}}function VX(e){if(!e)return!1;try{return typeof window<"u"&&window.sessionStorage.getItem(j1)===e}catch{return!1}}function UX(){try{typeof window<"u"&&window.sessionStorage.removeItem(j1)}catch{}}function kg(){const e=globalThis.crypto;if(e.randomUUID)return e.randomUUID();const n=new Uint8Array(16);if(e.getRandomValues)e.getRandomValues(n);else for(let r=0;r<n.length;r+=1)n[r]=Math.floor(Math.random()*256);n[6]=n[6]&15|64,n[8]=n[8]&63|128;const i=[...n].map(r=>r.toString(16).padStart(2,"0")).join("");return`${i.slice(0,8)}-${i.slice(8,12)}-${i.slice(12,16)}-${i.slice(16,20)}-${i.slice(20)}`}class GX extends Error{constructor(){super(iC),this.name="ViewOnlyError"}}function KX(e){if(!e.canWrite)throw new GX}function YC(e){e.invalidateQueries({queryKey:c1({client:W})}),e.invalidateQueries({queryKey:_s({client:W})})}function Mo(){const e=fa();return()=>{KX(e)}}function HX(e){return e==="gsc-sync"?"GSC sync queued":e==="inspect-sitemap"?"Sitemap inspection queued":"Visibility sweep queued"}function QX(e,n){const i=e??"Project";return n==="gsc-sync"?`${i} will refresh after the sync completes.`:n==="inspect-sitemap"?`${i} will notify you when sitemap inspection finishes.`:`${i} will notify you when the run finishes.`}function N1(e,n){d1({id:e.id,projectId:e.projectId,kind:e.kind,projectLabel:n.projectLabel,sourceAction:n.sourceAction,lastAnnouncedStatus:"queued"}),kn({title:HX(e.kind),detail:QX(n.projectLabel,e.kind),tone:"neutral",dedupeKey:`run:${e.id}`,dedupeMode:"replace"})}function FX(e){const n=e.filter(f=>f.status!=="conflict"&&f.status!=="error"),i=e.filter(f=>f.status==="conflict"),r=e.filter(f=>f.status==="error"),u=i.length+r.length;if(n.length===0){const f=[r.length>0?`${r.length} need provider or query setup`:null,i.length>0?`${i.length} already have an active run`:null].filter(b=>b!==null);kn({title:"No runs queued",detail:f.length>0?`${f.join("; ")}.`:"No projects were available to queue.",tone:"caution",durationMs:8e3,dedupeKey:"run-all:conflict",dedupeMode:"replace"});return}for(const f of n)d1({id:f.id,projectId:f.projectId,kind:f.kind,projectLabel:f.projectName,sourceAction:"run-all",lastAnnouncedStatus:"queued"});const h=tF({runIds:n.map(f=>f.id),queuedCount:n.length,skippedCount:u});kn({title:"Run-all batch queued",detail:u>0?`${n.length} project${n.length===1?"":"s"} queued; ${u} need attention or already have an active run.`:`${n.length} project${n.length===1?"":"s"} queued.`,tone:u>0?"caution":"neutral",dedupeKey:`batch:${h}`,dedupeMode:"replace"})}function Vm(e,n){if(e instanceof Sn&&e.code==="RUN_IN_PROGRESS"){kn({title:"Run already in progress",detail:n?.projectLabel?`${n.projectLabel} already has an active run. Wait for it to finish, then retry.`:"This project already has an active run. Wait for it to finish, then retry.",tone:"caution",durationMs:8e3,dedupeKey:`run-in-progress:${n?.projectKey??"project"}:${n?.sourceAction??"run"}`,dedupeMode:"replace"});return}kn({title:e instanceof Error?e.message:"Failed to queue run",tone:"negative"})}function ZX(){const e=Mo(),n=ta();return Ha({onMutate:e,meta:{skipGlobalErrorToast:!0},mutationFn:({projectName:i,opts:r})=>sK(i,r),onSuccess:(i,r)=>{YC(n),N1(i,{projectLabel:r.projectLabel??r.projectName,sourceAction:r.sourceAction})},onError:(i,r)=>{r.sourceAction!=="setup-launch"&&Vm(i,{projectKey:r.projectName,projectLabel:r.projectLabel??r.projectName,sourceAction:r.sourceAction})}})}function Nse(){const e=Mo(),n=ta();return Ha({onMutate:e,meta:{skipGlobalErrorToast:!0},mutationFn:i=>pK(i),onSuccess:i=>{YC(n),FX(i)},onError:i=>{kn({title:i instanceof Error?i.message:"Failed to queue runs",tone:"negative"})}})}function YX(){const e=Mo(),n=ta();return Ha({onMutate:e,meta:{skipGlobalErrorToast:!0},mutationFn:({projectName:i,body:r})=>gK(i,r),onSuccess:(i,r)=>{Tc(n,Re["site-audit"],r.projectName),d1({id:i.runId,projectId:r.projectId,kind:Re["site-audit"],projectLabel:r.projectLabel??r.projectName,sourceAction:"site-audit",lastAnnouncedStatus:i.status}),kn({title:i.status==="running"?"Site Health scan already running":"Site Health scan queued",detail:`${r.projectLabel??r.projectName} will refresh automatically when the scan finishes.`,tone:"neutral",dedupeKey:`run:${i.runId}`,dedupeMode:"replace"})},onError:(i,r)=>{r.suppressErrorToast||Vm(i,{projectKey:r.projectName,projectLabel:r.projectLabel??r.projectName,sourceAction:"site-audit"})}})}function _se(){const e=Mo(),n=ta();return Ha({onMutate:e,meta:{skipGlobalErrorToast:!0},mutationFn:({projectName:i,opts:r})=>hK(i,r),onSuccess:(i,r)=>{Tc(n,Re["gsc-sync"],r.projectName),N1(i,{projectLabel:r.projectLabel??r.projectName,sourceAction:"gsc-sync"})},onError:(i,r)=>{Vm(i,{projectKey:r.projectName,projectLabel:r.projectLabel??r.projectName,sourceAction:"gsc-sync"})}})}function Tse(){const e=Mo(),n=ta();return Ha({onMutate:e,meta:{skipGlobalErrorToast:!0},mutationFn:({projectName:i,opts:r})=>fK(i,r),onSuccess:(i,r)=>{Tc(n,Re["inspect-sitemap"],r.projectName),N1(i,{projectLabel:r.projectLabel??r.projectName,sourceAction:"inspect-sitemap"})},onError:(i,r)=>{Vm(i,{projectKey:r.projectName,projectLabel:r.projectLabel??r.projectName,sourceAction:"inspect-sitemap"})}})}function _1(e){if(!Array.isArray(e.queryKey)||e.queryKey.length<=1)return!1;const n=e.queryKey[0];return n==="projects"||n==="project-dashboard-full"}function Ese(){const e=Mo(),n=ta();return Ha({onMutate:e,mutationFn:({projectName:i,queries:r})=>nK(i,r),onSuccess:()=>{n.invalidateQueries({queryKey:_s({client:W})}),n.invalidateQueries({predicate:_1})}})}function Rse(){const e=Mo(),n=ta();return Ha({onMutate:e,mutationFn:({projectName:i,body:r})=>aK(i,r),onSuccess:()=>{Pn(n,"project"),n.invalidateQueries({predicate:_1})}})}const MS=[{id:"site",label:"Scan site",optional:!1},{id:"fixes",label:"Page health",optional:!1},{id:"visibility",label:"AI Visibility",optional:!0},{id:"done",label:"Next steps",optional:!1}],XX={skipped:"Skipped",pending:"In progress",incomplete:"Didn’t finish",unknown:null};function _o({current:e,outcomes:n={}}){const i=MS.findIndex(r=>r.id===e);return l.jsx("ol",{"aria-label":"Onboarding progress",className:"grid border-y border-default sm:grid-cols-4 sm:divide-x sm:divide-default",children:MS.map((r,u)=>{const h=u<i?n[r.id]:void 0,f=u<i&&h===void 0,b=u===i,v=h?XX[h]:null;return l.jsxs("li",{"aria-current":b?"step":void 0,className:"flex min-h-12 items-center gap-3 py-2 sm:px-3 sm:first:pl-0 sm:last:pr-0",children:[l.jsx("span",{"aria-hidden":"true",className:`flex size-6 shrink-0 items-center justify-center rounded-full border text-xs font-semibold tabular-nums ${b?"border-accent bg-accent text-on-inverse":f?"border-positive bg-positive-soft text-positive":"border-default bg-surface-subtle text-muted"}`,children:f?"✓":h==="skipped"||h==="incomplete"?"–":u+1}),l.jsxs("span",{className:"flex min-w-0 flex-wrap items-baseline gap-x-2",children:[l.jsx("span",{className:`text-sm font-medium ${b||f?"text-heading":"text-secondary"}`,children:r.label}),v?l.jsx("span",{className:"text-[13px] text-secondary",children:v}):r.optional&&!h?l.jsx("span",{className:"text-[13px] text-secondary",children:"Optional"}):null,f?l.jsx("span",{className:"sr-only",children:"Complete"}):null]})]},r.id)})})}function JX(){return[{id:"search-console",icon:_g,label:"Search Console",detail:"Compare answer engines with the queries you already rank for.",action:"Connect",to:"/projects/$projectName/search-console"},{id:"analytics",icon:ik,label:"Google Analytics",detail:"See the traffic answer engines actually send you.",action:"Connect",to:"/projects/$projectName/activity"},{id:"schedule",icon:sk,label:"Scheduled sweeps",detail:"Re-measure on a schedule instead of by hand.",action:"Set up",to:"/projects/$projectName/settings"},{id:"notifications",icon:Of,label:"Notifications",detail:"Send a webhook when a sweep finishes or a score moves.",action:"Set up",to:"/projects/$projectName/settings"},{id:"local",icon:ok,label:"Local presence",detail:"Track the Google Business Profile behind local answers.",action:"Open",to:"/projects/$projectName/local"},{id:"agent",icon:I5,label:"Your agent",detail:"Read this project from Claude Code, Codex, or any MCP client.",action:"Docs",href:"https://github.com/Canonry/canonry/blob/main/docs/mcp.md"}]}function WX({projectName:e}){const n=JX();return l.jsxs("section",{"aria-labelledby":"next-steps-heading",className:"mt-6 border-t border-default pt-5",children:[l.jsx("h2",{id:"next-steps-heading",className:"text-sm font-medium text-heading",children:"What else this project can do"}),l.jsx("ul",{className:"mt-3 divide-y divide-default",children:n.map(({id:i,icon:r,label:u,detail:h,action:f,to:b,href:v})=>l.jsxs("li",{className:"flex flex-wrap items-center gap-x-4 gap-y-1 py-3",children:[l.jsx(r,{className:"size-4 shrink-0 text-muted","aria-hidden":"true"}),l.jsx("span",{className:"min-w-36 text-sm font-medium text-heading",children:u}),l.jsx("span",{className:"min-w-0 flex-1 text-sm text-secondary",children:h}),b?l.jsxs(We,{to:b,params:{projectName:e},className:"text-sm font-medium text-link underline-offset-4 hover:underline",children:[f,l.jsxs("span",{className:"sr-only",children:[" ",u]})]}):l.jsxs("a",{href:v,target:"_blank",rel:"noreferrer",className:"text-sm font-medium text-link underline-offset-4 hover:underline",children:[f,l.jsxs("span",{className:"sr-only",children:[" ",u]})]})]},i))})]})}function eJ({providerName:e,keyUrl:n,modelHint:i,compact:r=!1,leadingField:u,secondaryActions:h,onSaved:f}){const b=e.toLowerCase()==="local",v=r&&e.toLowerCase()==="gemini"&&!!n,[x,S]=C.useState(""),[k,T]=C.useState(""),[N,I]=C.useState(""),[P,E]=C.useState(""),[$,ee]=C.useState(""),[L,F]=C.useState(""),[Z,ae]=C.useState(!1),[M,Y]=C.useState(null),[ue,Xe]=C.useState(!1),nt=b?k.trim().length>0:x.trim().length>0;async function Ge(){if(nt){ae(!0),Y(null),Xe(!1);try{const J=re=>{const H=parseInt(re.trim(),10);return Number.isFinite(H)&&H>0?H:void 0},Ne={},Me=J(P);Me!==void 0&&(Ne.maxConcurrency=Me);const xe=J($);xe!==void 0&&(Ne.maxRequestsPerMinute=xe);const le=J(L);le!==void 0&&(Ne.maxRequestsPerDay=le),await eC(e.toLowerCase(),{...x.trim()?{apiKey:x.trim()}:{},...k.trim()?{baseUrl:k.trim()}:{},...N.trim()?{model:N.trim()}:{},...Object.keys(Ne).length>0?{quota:Ne}:{}}),S(""),T(""),I(""),E(""),ee(""),F(""),Xe(!0),kn({title:"Provider updated",detail:`${e} configuration saved.`,tone:"positive",dedupeKey:`settings:provider:${e}`,dedupeMode:"replace"}),f()}catch(J){Y(J instanceof Error?J.message:"Failed to update provider")}finally{ae(!1)}}}const Pe=i??"Use default model",Se=r?"block text-sm font-medium text-secondary":"text-sm text-secondary",Ve=r?"setup-input min-h-11 w-full":"mt-0.5 w-full rounded border border-strong bg-transparent px-2 py-1.5 text-sm text-strong placeholder-mono-600 focus:border-mono-500 focus:outline-none",q=l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:r?"space-y-1.5":void 0,children:[l.jsx("label",{className:Se,htmlFor:`model-${e}`,children:"Model (optional)"}),l.jsx("input",{id:`model-${e}`,type:"text",className:Ve,placeholder:Pe,value:N,onChange:J=>I(J.target.value)})]}),l.jsxs("div",{children:[l.jsx("label",{className:Se,children:"Quota (optional)"}),l.jsxs("div",{className:"mt-0.5 grid grid-cols-3 gap-1.5",children:[l.jsxs("div",{children:[l.jsx("input",{type:"number",min:"1",className:r?"setup-input min-h-11 w-full":"w-full rounded border border-strong bg-transparent px-2 py-1.5 text-sm text-strong placeholder-mono-600 focus:border-mono-500 focus:outline-none",placeholder:"Concurrent",value:P,onChange:J=>E(J.target.value)}),l.jsx("p",{className:"mt-1 text-sm text-secondary",children:"Max concurrent"})]}),l.jsxs("div",{children:[l.jsx("input",{type:"number",min:"1",className:r?"setup-input min-h-11 w-full":"w-full rounded border border-strong bg-transparent px-2 py-1.5 text-sm text-strong placeholder-mono-600 focus:border-mono-500 focus:outline-none",placeholder:"/min",value:$,onChange:J=>ee(J.target.value)}),l.jsx("p",{className:"mt-1 text-sm text-secondary",children:"Per minute"})]}),l.jsxs("div",{children:[l.jsx("input",{type:"number",min:"1",className:r?"setup-input min-h-11 w-full":"w-full rounded border border-strong bg-transparent px-2 py-1.5 text-sm text-strong placeholder-mono-600 focus:border-mono-500 focus:outline-none",placeholder:"/day",value:L,onChange:J=>F(J.target.value)}),l.jsx("p",{className:"mt-1 text-sm text-secondary",children:"Per day"})]})]})]})]}),X=b?l.jsxs("div",{className:r?"space-y-1.5":void 0,children:[l.jsx("label",{className:Se,htmlFor:`base-url-${e}`,children:"Base URL"}),l.jsx("input",{id:`base-url-${e}`,type:"text",className:Ve,placeholder:"http://localhost:11434/v1",value:k,onChange:J=>T(J.target.value)}),l.jsx("p",{className:"mt-1 text-sm text-secondary",children:"Use any OpenAI-compatible endpoint, such as Ollama or vLLM."})]}):null,ve=l.jsxs("div",{className:r?"min-w-0 space-y-1.5":void 0,children:[l.jsxs("div",{className:r?"flex items-center justify-between gap-3":"flex items-center justify-between",children:[l.jsxs("label",{className:Se,htmlFor:`api-key-${e}`,children:["API key",b?" (optional)":""]}),n&&!v&&l.jsxs("a",{href:n,target:"_blank",rel:"noopener noreferrer",className:"text-sm text-secondary hover:text-neutral underline underline-offset-2",children:["Get API key ","↗"]})]}),l.jsx("input",{id:`api-key-${e}`,type:"password",autoComplete:"new-password",autoCapitalize:"none",spellCheck:!1,className:Ve,placeholder:b?"Optional. Most local servers do not need one.":`Enter ${e} API key`,value:x,onChange:J=>S(J.target.value)})]}),ke=l.jsx(ce,{type:"button",size:r?"default":"sm",className:r?"min-h-11":void 0,disabled:!nt||Z,onClick:hn(Ge),children:Z?"Saving...":r?"Save connection":"Save"});return l.jsxs("div",{className:r?"space-y-3":"mt-3 rounded-lg border border-base bg-bg-elevated/40 p-3 space-y-2",children:[v&&l.jsxs("div",{className:"flex flex-wrap items-start gap-x-6 gap-y-3 pb-2",children:[l.jsxs("div",{className:"min-w-0 flex-1 basis-72 space-y-1",children:[l.jsx("h3",{className:"text-base font-semibold text-heading",children:"Start with Gemini’s free tier"}),l.jsxs("p",{className:"max-w-prose text-sm text-secondary",children:["Get a key in Google AI Studio, then paste it below. Free usage has model and rate limits; paid usage is billed by Google."," ",l.jsx("a",{href:"https://ai.google.dev/gemini-api/docs/pricing",target:"_blank",rel:"noopener noreferrer",className:"text-link underline underline-offset-2 focus-visible:outline-2 focus-visible:outline-offset-2",children:"Pricing and limits"})]})]}),l.jsx(ce,{variant:"outline",className:"min-h-11",asChild:!0,children:l.jsxs("a",{href:n,target:"_blank",rel:"noopener noreferrer",children:["Get a free Gemini API key ","↗"]})})]}),r?l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:u?"grid items-start gap-3 sm:grid-cols-[minmax(0,0.7fr)_minmax(0,1.3fr)]":void 0,children:[u,ve]}),X]}):l.jsxs(l.Fragment,{children:[X,ve]}),r?l.jsxs("details",{children:[l.jsx("summary",{className:"min-h-11 cursor-pointer text-sm text-secondary py-3",children:"Advanced provider settings"}),l.jsx("div",{className:"space-y-3 pt-2",children:q})]}):q,M&&l.jsx("p",{role:"alert",className:"text-sm text-negative-400",children:M}),ue&&l.jsx("p",{className:"text-sm text-positive-400",children:"Provider updated."}),r?l.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[ke,h]}):ke]})}const am="cdp:chatgpt";function wo(e){return e.trim().toLowerCase()}function tJ({projectProviders:e,configuredApiProviders:n,cdpConfigured:i}){const r=e.map(wo),u=new Set(r),h=r.length===0||r.some(x=>x!==am),f=r.length===0||u.has(am);if(h&&n!==void 0&&n.map(wo).some(S=>r.length===0||u.has(S))||f&&i===!0)return!0;if(!(h&&n===void 0||f&&i===void 0))return!1}const nJ=[{label:"System check",description:"Verify your instance is ready"},{label:"Create project",description:"Name, domain, and locale"},{label:"Queries",description:"Add queries to track"},{label:"Competitors",description:"Add competitor domains"},{label:"Launch",description:"Start your first visibility sweep"}],aJ=[{label:"Queries"},{label:"First sweep"}];function BS(e,n){return(e==="completed"||e==="partial")&&n>0}function LS(e){return e.launchReady?e.hasProject?e.queryCount===0?2:e.competitorCount===0&&!e.hasRunAttempt?3:4:1:0}function XC(e){return e.queryCounts.total>0}function iJ(e,n){return n?e.find(i=>i.project.name===n)??null:e.find(i=>!XC(i))??e.at(0)??null}function sJ({current:e,labels:n}){return l.jsx("div",{className:"setup-steps",role:"list","aria-label":"Setup progress",children:n.map((i,r)=>{const u=r<e,h=r===e;return l.jsxs("div",{className:`setup-step ${u?"setup-step-done":""} ${h?"setup-step-active":""}`,role:"listitem","aria-current":h?"step":void 0,children:[l.jsx("span",{className:"setup-step-number",children:u?"✓":r+1}),l.jsx("span",{children:i.label})]},i.label)})})}function oJ({visibilityProjectName:e,siteHealthOnboarding:n=!1,onboardingFinish:i=n}={}){const{canWrite:r}=fa();return e&&r?l.jsx($S,{visibilityProjectName:e,siteHealthOnboarding:n,onboardingFinish:i}):l.jsx(b1,{title:e?"Set up AI Visibility":"Setup",children:l.jsx($S,{visibilityProjectName:e,siteHealthOnboarding:n,onboardingFinish:i})})}function $S({visibilityProjectName:e,siteHealthOnboarding:n,onboardingFinish:i}){const r=Qc(),{isAdmin:u}=fa(),{dashboard:h,isLoading:f,refetch:b}=Mm(void 0,{pauseProjectPolling:!0,includeSettings:u}),v=h??r?.dashboard,x=Ts(),S=C.useCallback(T=>{T&&e&&T.focus()},[e]),k=()=>{if(!e){x({to:"/",replace:!0});return}if(i){x({to:"/setup",search:{onboarding:"complete",setupProject:e,skipped:"visibility"},replace:!0});return}x({to:"/projects/$projectName",params:{projectName:e},replace:!0})};return!v||f?l.jsxs("div",{className:"page-skeleton",children:[l.jsxs("div",{className:"page-skeleton-header",children:[l.jsx("div",{className:"skeleton-text h-6 w-24"}),l.jsx("div",{className:"skeleton-text-sm w-80"})]}),l.jsxs("div",{className:"page-skeleton-card",children:[l.jsx("div",{className:"skeleton-text w-32"}),l.jsx("div",{className:"space-y-3 mt-3",children:[1,2,3].map(T=>l.jsxs("div",{className:"flex items-center justify-between",children:[l.jsxs("div",{className:"space-y-1 flex-1",children:[l.jsx("div",{className:"skeleton-text w-24"}),l.jsx("div",{className:"skeleton-text-sm w-48"})]}),l.jsx("div",{className:"skeleton h-6 w-16 rounded-full"})]},T))})]})]}):e&&!v.projects.some(T=>T.project.name===e)?l.jsxs("div",{className:"page-container",children:[n?l.jsx(_o,{current:"visibility"}):null,l.jsxs("div",{className:"page-header",children:[l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{ref:S,tabIndex:-1,className:"page-title",children:"Set up AI Visibility"}),l.jsx("p",{className:"page-subtitle",children:"Choose what to track, then run your first visibility sweep."})]}),n?l.jsx("div",{className:"page-header-right",children:l.jsx(ce,{type:"button",variant:"outline",onClick:k,children:"Skip AI Visibility"})}):null]}),l.jsxs(Ra,{role:"alert",className:"compact-stack",children:[l.jsx("h2",{children:"Project not found"}),l.jsx("p",{className:"text-secondary",children:"Canonry could not find the project handed off from Site Health. Refresh the project list or choose a project to continue."}),l.jsxs("div",{className:"flex flex-wrap gap-2",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:()=>{b()},children:"Retry"}),l.jsx(ce,{type:"button",asChild:!0,children:l.jsx(We,{to:"/projects",children:"View projects"})})]})]})]}):l.jsx(rJ,{dashboard:v,initialHealth:r?.health,enableLiveStatus:!r,refetch:b,visibilityProjectName:e,visibilityHeadingRef:S,siteHealthOnboarding:n,onboardingFinish:i})}function rJ({dashboard:e,initialHealth:n,enableLiveStatus:i,refetch:r,visibilityProjectName:u,visibilityHeadingRef:h,siteHealthOnboarding:f,onboardingFinish:b}){const v=e.settings,{isAdmin:x}=fa(),k=f1(i,n).data??n??{apiStatus:{label:"API",state:"checking",detail:"Checking service health"},workerStatus:{label:"Worker",state:"checking",detail:"Checking service health"}},T=YQ(e.setup,k,v),N=!!u,I=Ts(),P=ta(),E=C.useRef(A1()).current,$=C.useRef(new Set),ee=C.useCallback((G,Fe)=>{if(Fe){if($.current.has(Fe))return;$.current.add(Fe)}o1({surface:"wizard",...G,eventId:C1()})},[]),L=iJ(e.projects,u),F=L?e.runs.filter(G=>G.projectId===L.project.id).sort((G,Fe)=>Fe.createdAt.localeCompare(G.createdAt)):[],Z=L?.queryCounts.total??0,ae=L?.project.name,M=yt({queryKey:["setup","resume-queries",ae],queryFn:()=>ae?XA(ae):Promise.resolve([]),enabled:!!ae}),Y=M.data??[],ue=M.data?.length??Z,Xe=L?.competitors.map(G=>G.domain)??[],nt=F.at(0)??null,Ge=!!L&&XC(L),Pe=!!L&&M.isPending,Se=N?2:LS({launchReady:T.launchState.enabled,hasProject:!!L,queryCount:ue,competitorCount:Xe.length,hasRunAttempt:F.length>0||Ge}),Ve=LS({launchReady:!0,hasProject:!!L,queryCount:ue,competitorCount:Xe.length,hasRunAttempt:F.length>0||Ge}),[q,X]=C.useState(Se),[ve,ke]=C.useState(!Pe),J=N&&(Pe||!ve),[Ne,Me]=C.useState(L?.project.name??""),[xe,le]=C.useState(L?.project.displayName??""),[re,H]=C.useState(L?.project.canonicalDomain??""),[pe,ze]=C.useState(L?.project.country??"US"),[je,it]=C.useState(L?.project.language??"en"),[Ue,jt]=C.useState(L?.project.autoExtractBacklinks??!1),[He,me]=C.useState(L?.project.name??null),[ot,It]=C.useState(null),[Bn,Kt]=C.useState(!1),Be=()=>{if(!He){I({to:"/",replace:!!u});return}I({to:f?"/projects/$projectName/technical-aeo":"/projects/$projectName",params:{projectName:He},replace:!!u})},ct=(G=!1)=>{if(!b||!He){Be();return}I({to:"/setup",search:{onboarding:"complete",setupProject:He,...G?{skipped:"visibility"}:{}},replace:!0})},Ht=()=>ct(!0),[Qt,zn]=C.useState(Y.map(G=>G.query).join(`
|
|
73
|
+
`)),[$t,mi]=C.useState(ue>0),[Bs,Hn]=C.useState(null),[pi,Ls]=C.useState(!1),[Ki,Hi]=C.useState(!1),$s=v.providerStatuses.filter(G=>G.state==="ready"),yn=L?.project.providers.map(wo)??[],At=$s.filter(G=>yn.length===0||yn.includes(wo(G.name))),bn=$s.map(G=>wo(G.name)),An=At.length>0,Vs=yn.length===0||yn.includes(am),ya=N&&!x,oe=yt({...pH({client:W,path:{name:ae??""}}),enabled:ya&&!!ae,staleTime:0,refetchOnMount:"always",refetchOnWindowFocus:"always",retry:!1}),Ie=oe.data?.answerVisibilityProviderReady,Ye=ya&&(oe.isError||oe.isSuccess&&typeof Ie!="boolean"),Ft=yt({...MH({client:W}),enabled:!ya&&Vs&&!An,staleTime:6e4,retry:!1}),st=Vs?Ft.isSuccess?typeof Ft.data.browserVersion=="string":Ft.isError?!1:void 0:!1,et=ya?oe.isSuccess&&oe.isFetchedAfterMount&&!oe.isFetching?Ie:void 0:tJ({projectProviders:yn,configuredApiProviders:bn,cdpConfigured:st}),Wt=At.length+(st===!0?1:0),[Xa,Us]=C.useState(At[0]?.name??""),[Bo,Gs]=C.useState(5),[Fc,il]=C.useState(!1),[sl,ol]=C.useState(null),[rl,ll]=C.useState(""),Lo=C.useRef(!1),Zc=C.useCallback(G=>{!G||!Lo.current||(Lo.current=!1,G.focus({preventScroll:!0}))},[]),[ba,on]=C.useState(!1),[In,Qi]=C.useState(!1),[$o,Yc]=C.useState(!1),Vo=v.providerStatuses.filter(G=>wo(G.name)!==am&&(yn.length===0||yn.includes(wo(G.name)))),aa=Vo.find(G=>G.name===rl)??Vo.find(G=>G.state!=="ready")??Vo.at(0),Fi=`Help me choose AI Visibility queries for Canonry project ${JSON.stringify(He??Ne)} (${re}).
|
|
74
|
+
1. Read the project, its existing tracked queries, and Site Health findings. Ask about my customers, services, and locations if needed, then propose relevant customer queries.
|
|
75
|
+
2. Check the configured connection's capabilities, then use Canonry's Research flow to test a small approved batch. Retrieve saved answers and any available sources. Compare brand mentions separately from site citations; unavailable citation evidence is not a "not cited" result. Text-only routes can inform query research but cannot establish an AI Visibility baseline. Research does not add queries to tracking. If more candidates are needed, propose ICP Discovery separately.
|
|
76
|
+
3. Recommend a short list with reasons. Ask before provider usage. Once I approve, preserve existing queries and return the combined list, one query per line, for me to paste into setup. Do not change tracked queries or launch a visibility sweep.`,cl=async()=>{Yc(!1);try{await navigator.clipboard.writeText(Fi),Qi(!0)}catch{Yc(!0)}},[hi,Zi]=C.useState(Xe.join(`
|
|
77
|
+
`)),[Yi,Xi]=C.useState(Xe.length>0),[en,ul]=C.useState(null),[dl,Ja]=C.useState(!1),ml=C.useRef(ZC(ae)).current?.runId??null,pl=C.useRef(ml),[Wa,Km]=C.useState(!!ml||!!nt&&!Ge),[fi,Hs]=C.useState(!1),[Cn,On]=C.useState(null),[Ji,Hm]=C.useState(ml??(Ge?null:nt?.id??null)),hl=ZX(),ei=yt({...u1({client:W,path:{id:Ji??""}}),enabled:!!Ji,refetchInterval:({state:G})=>{const Fe=G.data?.status;return Fe==="completed"||Fe==="partial"||Fe==="failed"||Fe==="cancelled"?!1:2e3},refetchIntervalInBackground:!0}),[Wi,Xc]=C.useState(""),[qn,Uo]=C.useState(!1),[fl,Go]=C.useState(null),Qn=Ne.toLowerCase().replace(/[^a-z0-9-]/g,"-").replace(/-+/g,"-").replace(/^-|-$/g,""),ia=Qt.split(`
|
|
78
|
+
`).map(G=>G.trim()).filter(Boolean),gi=hi.split(`
|
|
79
|
+
`).map(G=>G.trim()).filter(Boolean),va=Math.max(ue,$t?ia.length:0),xa=MX({apiReady:k.apiStatus.state==="ok",databaseConfigured:k.apiStatus.databaseConfigured,workerReady:k.workerStatus.state==="ok",providerReady:et!==!1}),ti=(xa&&xa!=="no_provider"?T.launchState.blockedReason:Ye?"Provider readiness could not be checked. Try again.":et===void 0?"Checking provider readiness before launch.":xa==="no_provider"?"Launch is blocked until a provider allowed by this project is configured.":void 0)??(He?va===0?"Add at least one query before launching the first sweep.":void 0:"Create a project before launching the first sweep.");C.useEffect(()=>{ve||Pe||(N||X(Se),Y.length>0&&(zn(Y.map(G=>G.query).join(`
|
|
80
|
+
`)),mi(!0)),ke(!0))},[Y,Se,N,ve,Pe]),C.useEffect(()=>{if(At.length===0){Us("");return}At.some(G=>G.name===Xa)||Us(At[0].name)},[At,Xa]),C.useEffect(()=>{ve&&(ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.started",step:PX(Se),resumed:!!L},"onboarding.started"),!L&&Se>0&&ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"system",method:"automatic"},"onboarding.step_completed:system"))},[ee,Se,E,ve,L]),C.useEffect(()=>{N||!BX(k)||!xa||ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.blocked",step:"system",action:xa==="no_provider"?"configure_provider":"continue",reasonCode:xa},`onboarding.blocked:system:${xa}`)},[ee,k,N,E,xa]);const Ma=ei.data?.status,Ko=ei.data?.snapshots?.length??0;C.useEffect(()=>{if(!Wa||!Ma)return;const G=pl.current;if(!G||G!==Ji)return;if(BS(Ma,Ko)){ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"run",method:"automatic",countBucket:li(Ko)},"onboarding.step_completed:run"),nm(G);return}const Fe=Ma==="cancelled"?"run_cancelled":Ma==="failed"||(Ma==="completed"||Ma==="partial")&&Ko===0?"run_failed":void 0;Fe&&(ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.blocked",step:"run",action:"retry_run",reasonCode:Fe},`onboarding.blocked:run:${Fe}`),nm(G))},[ee,Ji,E,Ma,Ko,Wa]);const Fm=async()=>{if(!(!Qn||!re)){Kt(!0),It(null);try{const G=await WA(Qn,{displayName:xe||Ne,canonicalDomain:re,country:pe,language:je,autoExtractBacklinks:Ue});me(Qn),kn({title:"Project created",detail:`${G.displayName||G.name} is ready for setup.`,tone:"positive",dedupeKey:`project:create:${G.name}`,dedupeMode:"drop"}),await r(),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"project",method:"manual"},"onboarding.step_completed:project"),X(2)}catch(G){It(G instanceof Error?G.message:"Failed to create project"),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.blocked",step:"project",action:"save",reasonCode:"project_create_failed"},"onboarding.blocked:project:project_create_failed")}finally{Kt(!1)}}},Ho=async()=>{if(!He)return;const G=ia;if(G.length!==0){Ls(!0),Hn(null);try{await tK(He,G),mi(!0),N?await Promise.all([P.invalidateQueries({queryKey:rC({client:W,path:{name:He}})}),P.invalidateQueries({predicate:_1}),P.invalidateQueries({queryKey:["setup","resume-queries",He]})]):await r(),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"queries",method:Ki?"generated":"manual",countBucket:li(G.length)},"onboarding.step_completed:queries"),X(N?4:3)}catch(Fe){Hn(Fe instanceof Error?Fe.message:"Failed to save queries"),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.blocked",step:"queries",action:"save",reasonCode:"query_save_failed"},"onboarding.blocked:queries:query_save_failed")}finally{Ls(!1)}}},Ba=async()=>{if(!(!He||!Xa)){il(!0),ol(null);try{const G=await dK(He,Xa,Bo);if(G.queries.length>0){const Fe=Qt?Qt.trimEnd()+`
|
|
81
|
+
`+G.queries.join(`
|
|
82
|
+
`):G.queries.join(`
|
|
83
|
+
`);zn(Fe),Hi(!0)}}catch(G){ol(G instanceof Error?G.message:"Failed to generate queries"),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.blocked",step:"queries",action:"generate_queries",reasonCode:xc(G,"unknown")},"onboarding.blocked:queries:generate")}finally{il(!1)}}},gl=async()=>{if(!He)return;const G=gi;if(G.length!==0){Ja(!0),ul(null);try{await iK(He,G),Xi(!0),await r(),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"competitors",method:"manual",countBucket:li(G.length)},"onboarding.step_completed:competitors"),X(4)}catch(Fe){ul(Fe instanceof Error?Fe.message:"Failed to save competitors"),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.blocked",step:"competitors",action:"save",reasonCode:"unknown"},"onboarding.blocked:competitors:save")}finally{Ja(!1)}}},yl=async()=>{const G=Wi.trim();if(G){Uo(!0),Go(null);try{await eC("gemini",{apiKey:G}),kn({title:"Gemini configured",detail:"Provider is ready — continuing setup.",tone:"positive",dedupeKey:"setup:gemini:configured",dedupeMode:"drop"}),Xc(""),await r(),Us(v.providerStatuses.find(Fe=>Fe.name.toLowerCase()==="gemini")?.name??"gemini"),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"system",method:"inline"},"onboarding.step_completed:system")}catch(Fe){Go(Fe instanceof Error?Fe.message:"Failed to save Gemini key"),ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.blocked",step:"system",action:"configure_provider",reasonCode:"provider_save_failed"},"onboarding.blocked:system:provider_save_failed")}finally{Uo(!1)}}},yi=async()=>{if(!vo()){if(!He||ti){On(ti??"Complete setup before launching the first sweep.");const G=xa??(He?va===0?"no_queries":"run_rejected":"unknown");ya||ee({flowVersion:ft,onboardingSessionId:E,event:"run.requested",origin:"dashboard_setup",result:"rejected",providerCountBucket:li(Wt),queryCountBucket:li(va),reasonCode:G});return}Hs(!0),On(null);try{const G=await hl.mutateAsync({projectName:He,projectLabel:xe||Ne||He,sourceAction:"setup-launch"});Hm(G.id),Km(!0),FC(He,G.id),pl.current=G.id,ya||ee({flowVersion:ft,onboardingSessionId:E,event:"run.requested",origin:"dashboard_setup",result:"queued",providerCountBucket:li(Wt),queryCountBucket:li(va)}),await r()}catch(G){On(G instanceof Error?G.message:"Failed to queue the visibility sweep. Retry when the instance is ready."),ya||ee({flowVersion:ft,onboardingSessionId:E,event:"run.requested",origin:"dashboard_setup",result:"rejected",providerCountBucket:li(Wt),queryCountBucket:li(va),reasonCode:xc(G,"run_rejected")})}finally{Hs(!1)}}},Ln=()=>X(G=>N?2:Math.max(0,G-1)),Qo=(G,Fe,bi)=>{ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:G,method:"existing",...bi===void 0?{}:{countBucket:li(bi)}},`onboarding.step_completed:${G}`),X(Fe)},bl=()=>{if(ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"queries",method:"skipped",countBucket:"0"},"onboarding.step_completed:queries"),N){Ht();return}X(3)},Jc=()=>{ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"competitors",method:"skipped",countBucket:"0"},"onboarding.step_completed:competitors"),X(4)},Qs=N?"section":Ra,wa=et!==!0||st===!0?l.jsx(ce,{type:"button",variant:"ghost",size:"sm",className:"min-h-11",onClick:()=>{r(),Vs&&Ft.refetch()},children:"Check again"}):null,vl=(et===!1||ba)&&!!aa,Fs=N&&(q===2||q===4)?x?l.jsxs("section",{"aria-labelledby":"setup-provider-heading",className:"space-y-3 border-b border-default pb-6 mb-6",children:[l.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[l.jsx("h2",{id:"setup-provider-heading",className:"text-lg font-semibold text-heading",children:et===!1?"Connect a provider":"Answer engine provider"}),l.jsx(xn,{tone:et===!0?"positive":"neutral",children:et===!0?"Configured":et===!1?"Not connected":"Checking"})]}),l.jsx("p",{className:"max-w-prose text-sm text-secondary",children:et===!0?At.length>0?`${At.map(G=>G.displayName??G.name).join(", ")} available for this project. Research and sweeps use your provider account.`:"ChatGPT in Chrome is configured for sweeps. Query Research needs an API provider.":et===!1?"An answer engine is required for visibility sweeps. You can save queries now and connect later.":"Checking available providers. You can choose queries while this finishes."}),et===!1||ba?aa?l.jsx("div",{children:l.jsx(eJ,{compact:!0,leadingField:l.jsxs("div",{className:"min-w-0 space-y-1.5",children:[l.jsx("label",{className:"block text-sm font-medium text-secondary",htmlFor:"setup-provider",children:"Provider to connect"}),l.jsx("select",{ref:Zc,id:"setup-provider",className:"setup-input",value:aa.name,onChange:G=>{G.target.value!==aa.name&&(Lo.current=document.activeElement===G.currentTarget,ll(G.target.value))},children:Vo.map(G=>l.jsx("option",{value:G.name,children:G.displayName??G.name},G.name))})]}),secondaryActions:wa,providerName:aa.name,keyUrl:aa.keyUrl,modelHint:aa.modelHint,onSaved:()=>{on(!1),r()}},aa.name)}):l.jsx("p",{className:"max-w-prose text-sm text-secondary",children:yn.length>0?`This project's provider selection is ${yn.join(", ")}. Configure an allowed provider in Settings, or change the selection in project Settings.`:"Provider configuration is unavailable here. Open Settings to connect an answer engine, then check again."}):null,l.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[et===!0&&!ba&&aa?l.jsx(ce,{type:"button",variant:"outline",size:"sm",onClick:()=>on(!0),children:"Configure a provider"}):null,!aa||st===!0?l.jsx(ce,{type:"button",variant:"outline",size:"sm",asChild:!0,children:l.jsx(We,{to:"/settings",target:"_blank",rel:"noopener noreferrer",children:"Open provider settings"})}):null,vl?null:wa]})]}):l.jsxs("section",{"aria-labelledby":"setup-provider-heading",className:"space-y-2 border-b border-default pb-6 mb-6",children:[l.jsx("h2",{id:"setup-provider-heading",className:"text-lg font-semibold text-heading",children:"Answer engine provider"}),l.jsx("p",{className:"max-w-prose text-sm text-secondary",children:"Provider settings are managed by an administrator."}),Ye?l.jsx("p",{role:"alert",className:"text-sm text-negative",children:"Provider readiness could not be checked. Try again."}):l.jsx("p",{className:"max-w-prose text-sm text-secondary",role:"status",children:et===!0?"An answer engine is available for this project.":et===!1?"Ask an administrator to connect an answer engine for this project. You can save queries now.":"Checking provider readiness. You can save queries now."}),l.jsx(ce,{type:"button",variant:"ghost",size:"sm",className:"min-h-11",disabled:oe.isFetching,onClick:()=>{oe.refetch()},children:Ye?"Retry provider check":"Check again"})]}):null,ni=(()=>{switch(q){case 0:return l.jsxs(Ra,{className:"surface-card step-card",children:[l.jsx("div",{className:"section-head",children:l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Step 1 of 5"}),l.jsx("h2",{children:"System check"})]})}),l.jsx("p",{className:"supporting-copy",children:"Checking that your Canonry instance is configured and reachable."}),l.jsx("div",{className:"compact-stack",children:T.healthChecks.map(G=>l.jsxs("div",{className:"health-check-row",children:[l.jsxs("div",{children:[l.jsx("p",{className:"run-row-title",children:G.label}),l.jsx("p",{className:"supporting-copy",children:G.detail}),G.id==="provider"&&G.state!=="ready"&&l.jsxs("div",{className:"mt-3 rounded-md border border-default bg-bg-elevated/40 p-3 space-y-2",children:[l.jsxs("p",{className:"text-xs text-secondary",children:["Paste a Gemini key to enable visibility checks (free at"," ",l.jsx("a",{href:"https://aistudio.google.com/apikey",target:"_blank",rel:"noreferrer",className:"text-positive-400 hover:text-positive underline underline-offset-2",children:"aistudio.google.com"}),")."]}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx("input",{type:"password",value:Wi,onChange:Fe=>Xc(Fe.target.value),placeholder:"AI... (paste here)",className:"flex-1 rounded-md border border-base bg-bg px-2.5 py-1.5 text-sm text-heading placeholder:text-faint focus:border-mono-600 focus:outline-none font-mono",disabled:qn}),l.jsx(ce,{type:"button",size:"sm",disabled:qn||!Wi.trim(),onClick:hn(yl),children:qn?"Saving...":"Save"})]}),fl&&l.jsxs("div",{role:"alert",className:"space-y-1 text-xs text-negative",children:[l.jsx("p",{children:fl}),l.jsx("p",{children:"Check that the key is complete, then retry Save."})]}),l.jsxs("p",{className:"text-sm text-secondary",children:["Connect more answer engines later in"," ",l.jsx(We,{to:"/settings",className:"text-link hover:underline",children:"Settings"}),"."]})]})]}),l.jsx(xn,{tone:G.state==="ready"?"positive":"caution",title:G.id==="api"?Kr(k.apiStatus):G.id==="worker"?Kr(k.workerStatus):G.detail,children:G.state==="ready"?"Ready":"Attention"})]},G.id))}),l.jsxs("div",{className:"setup-nav",children:[T.launchState.blockedReason?l.jsx("p",{role:"status",className:"supporting-copy text-negative",children:T.launchState.blockedReason}):l.jsx("span",{}),l.jsx(ce,{type:"button",disabled:!T.launchState.enabled,title:T.launchState.blockedReason,onClick:()=>{ee({flowVersion:ft,onboardingSessionId:E,event:"onboarding.step_completed",step:"system",method:"automatic"},"onboarding.step_completed:system"),X(Ve)},children:"Continue"})]})]});case 1:return l.jsxs(Ra,{className:"surface-card step-card",children:[l.jsxs("div",{className:"section-head",children:[l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Step 2 of 5"}),l.jsx("h2",{children:"Create project"})]}),He?l.jsx(xn,{tone:"positive",children:"Created"}):null]}),He?l.jsxs("div",{className:"compact-stack",children:[l.jsxs("p",{className:"text-neutral",children:["Project ",l.jsx("span",{className:"text-heading font-medium",children:He})," created successfully."]}),l.jsxs("div",{className:"setup-nav",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:Ln,children:"Back"}),l.jsx(ce,{type:"button",onClick:()=>Qo("project",2),children:"Continue"})]})]}):l.jsxs("div",{className:"compact-stack",children:[l.jsxs("div",{className:"setup-field",children:[l.jsx("label",{className:"setup-label",htmlFor:"project-name",children:"Project name"}),l.jsx("input",{id:"project-name",className:"setup-input",type:"text",placeholder:"my-website",value:Ne,onChange:G=>Me(G.target.value)}),Qn&&Qn!==Ne?l.jsxs("p",{className:"supporting-copy",children:["Slug: ",Qn]}):null]}),l.jsxs("div",{className:"setup-field",children:[l.jsx("label",{className:"setup-label",htmlFor:"display-name",children:"Display name (optional)"}),l.jsx("input",{id:"display-name",className:"setup-input",type:"text",placeholder:"My Website",value:xe,onChange:G=>le(G.target.value)})]}),l.jsxs("div",{className:"setup-field",children:[l.jsx("label",{className:"setup-label",htmlFor:"domain",children:"Canonical domain"}),l.jsx("input",{id:"domain",className:"setup-input",type:"text",placeholder:"example.com",value:re,onChange:G=>H(G.target.value)})]}),l.jsxs("div",{className:"setup-field-row",children:[l.jsxs("div",{className:"setup-field",children:[l.jsx("label",{className:"setup-label",htmlFor:"country",children:"Country"}),l.jsx("input",{id:"country",className:"setup-input",type:"text",placeholder:"US",maxLength:2,value:pe,onChange:G=>ze(G.target.value.toUpperCase())})]}),l.jsxs("div",{className:"setup-field",children:[l.jsx("label",{className:"setup-label",htmlFor:"language",children:"Language"}),l.jsx("input",{id:"language",className:"setup-input",type:"text",placeholder:"en",maxLength:5,value:je,onChange:G=>it(G.target.value.toLowerCase())})]})]}),l.jsxs("label",{className:"flex items-start gap-3 rounded-md border border-default bg-surface p-3 cursor-pointer hover:border-strong",children:[l.jsx("input",{type:"checkbox",className:"mt-0.5 h-4 w-4 rounded border-strong bg-bg",checked:Ue,onChange:G=>jt(G.target.checked)}),l.jsxs("span",{className:"flex-1",children:[l.jsx("span",{className:"block text-sm text-heading",children:"Auto-extract backlinks"}),l.jsxs("span",{className:"block text-xs text-muted mt-0.5",children:["When a new Common Crawl release syncs, automatically extract backlinks for this project."," ",l.jsx(We,{to:"/backlinks",className:"text-positive-400 hover:text-positive underline underline-offset-2",children:"Manage backlinks"})]})]})]}),ot?l.jsx("p",{className:"text-negative-400 text-sm",children:ot}):null,l.jsxs("div",{className:"setup-nav",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:Ln,children:"Back"}),l.jsx(ce,{type:"button",disabled:!Qn||!re||Bn,onClick:hn(Fm),children:Bn?"Creating...":"Create project"})]})]})]});case 2:return l.jsxs(Qs,{className:N?"visibility-setup-section step-card":"surface-card step-card","aria-labelledby":"setup-queries-heading",children:[l.jsxs("div",{className:"section-head",children:[l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:N?"Step 1 of 2":"Step 3 of 5"}),l.jsx("h2",{id:"setup-queries-heading",children:"Add queries"})]}),J?l.jsx(xn,{tone:"neutral",children:"Loading"}):M.isError?l.jsx(xn,{tone:"negative",children:"Load failed"}):$t?l.jsxs(xn,{tone:"positive",children:[ia.length," saved"]}):l.jsxs(xn,{tone:"neutral",children:[ia.length," quer",ia.length!==1?"ies":"y"]})]}),l.jsx("p",{className:"supporting-copy",children:"Add the queries your customers use, one per line. You can refine your list later."}),l.jsxs("div",{className:"space-y-2 border-b border-default pb-4",children:[l.jsxs("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between",children:[l.jsxs("div",{className:"min-w-0 space-y-1",children:[l.jsx("h3",{className:"text-sm font-semibold text-heading",children:"Research queries with your agent"}),l.jsx("p",{className:"max-w-prose text-sm text-secondary",children:"Ask your agent to compare answers and available sources with Canonry Research, then recommend queries. Research does not change your tracked queries."})]}),l.jsx(ce,{type:"button",variant:"outline",size:"sm",className:"min-h-11 shrink-0 self-start",onClick:hn(cl),children:In?"Research prompt copied":"Copy research prompt"})]}),l.jsxs("details",{open:$o||void 0,className:"text-sm text-secondary",children:[l.jsx("summary",{className:"min-h-11 cursor-pointer py-3 text-link",children:"View agent prompt"}),l.jsx("textarea",{"aria-label":"Agent query research prompt",readOnly:!0,className:"setup-textarea mt-2 w-full",rows:8,value:Fi})]}),$o?l.jsx("p",{role:"alert",className:"text-sm text-negative",children:"Could not copy. Select and copy the prompt above."}):null]}),J?l.jsx("div",{className:"rounded-md border border-default bg-bg-elevated/40 p-4 text-sm text-secondary",role:"status",children:"Loading saved queries…"}):M.isError?l.jsxs("div",{className:"compact-stack",children:[l.jsx("div",{role:"alert",className:"rounded-md border border-negative bg-negative-soft p-3 text-sm text-negative",children:"Saved queries could not be loaded. Retry before changing the query basket."}),l.jsxs("div",{className:"setup-nav",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:N?Be:Ln,children:"Back"}),l.jsx(ce,{type:"button",onClick:()=>{M.refetch()},children:"Retry loading queries"})]})]}):$t?l.jsxs("div",{className:"compact-stack",children:[l.jsx("ul",{className:"detail-list",children:ia.map(G=>l.jsx("li",{children:G},G))}),l.jsxs("div",{className:"setup-nav",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:N?Be:Ln,children:"Back"}),l.jsx(ce,{type:"button",variant:"outline",onClick:()=>mi(!1),children:"Edit queries"}),l.jsx(ce,{type:"button",onClick:()=>Qo("queries",N?4:3,ia.length),children:"Continue"})]})]}):l.jsxs("div",{className:"compact-stack",children:[At.length>0?l.jsxs("div",{className:"compact-stack",children:[l.jsxs("div",{className:"flex items-center gap-2 text-muted text-xs uppercase tracking-wide",children:[l.jsx("span",{className:"flex-1 border-t border-base"}),"auto-generate",l.jsx("span",{className:"flex-1 border-t border-base"})]}),l.jsxs("div",{className:"flex items-end gap-2",children:[l.jsxs("div",{className:"setup-field flex-1",children:[l.jsx("label",{className:"setup-label",htmlFor:"gen-provider",children:"Provider"}),l.jsx("select",{id:"gen-provider",className:"setup-input",value:Xa,onChange:G=>Us(G.target.value),children:At.map(G=>l.jsxs("option",{value:G.name,children:[G.displayName??G.name,G.model?` (${G.model})`:""]},G.name))})]}),l.jsxs("div",{className:"setup-field",children:[l.jsx("label",{className:"setup-label",htmlFor:"gen-count",children:"Count"}),l.jsx("select",{id:"gen-count",className:"setup-input",value:Bo,onChange:G=>Gs(Number(G.target.value)),children:[3,5,10,15,20].map(G=>l.jsx("option",{value:G,children:G},G))})]}),l.jsx(ce,{type:"button",variant:"outline",disabled:Fc||!Xa,onClick:hn(Ba),children:Fc?"Analyzing site...":"Generate"})]}),sl?l.jsx("p",{className:"text-negative-400 text-sm",children:sl}):null]}):null,N?null:l.jsxs("div",{className:"flex items-center gap-2 text-muted text-xs uppercase tracking-wide",children:[l.jsx("span",{className:"flex-1 border-t border-base"}),"or type manually",l.jsx("span",{className:"flex-1 border-t border-base"})]}),l.jsxs("div",{className:"setup-field",children:[l.jsx("label",{className:"setup-label",htmlFor:"queries",children:"Queries (one per line)"}),l.jsx("textarea",{id:"queries",className:"setup-textarea",rows:6,placeholder:`emergency dentist brooklyn
|
|
84
|
+
best invisalign downtown brooklyn
|
|
85
|
+
pediatric dentist brooklyn heights`,value:Qt,onChange:G=>zn(G.target.value)})]}),Bs?l.jsx("p",{className:"text-negative-400 text-sm",children:Bs}):null,l.jsxs("div",{className:"setup-nav",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:N?Be:Ln,children:"Back"}),l.jsx(ce,{type:"button",variant:"ghost",onClick:bl,children:N?"Finish without AI Visibility":"Skip for now"}),l.jsx(ce,{type:"button",disabled:ia.length===0||pi,onClick:hn(Ho),children:pi?"Saving...":`Save ${ia.length} quer${ia.length!==1?"ies":"y"}`})]})]})]});case 3:return l.jsxs(Ra,{className:"surface-card step-card",children:[l.jsxs("div",{className:"section-head",children:[l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Step 4 of 5"}),l.jsx("h2",{children:"Add competitors"})]}),Yi?l.jsx(xn,{tone:"positive",children:"Saved"}):null]}),l.jsx("p",{className:"supporting-copy",children:"Domains that compete for the same queries. One per line."}),Yi?l.jsxs("div",{className:"compact-stack",children:[l.jsx("ul",{className:"detail-list",children:gi.map(G=>l.jsx("li",{children:G},G))}),l.jsxs("div",{className:"setup-nav",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:Ln,children:"Back"}),l.jsx(ce,{type:"button",onClick:()=>Qo("competitors",4,gi.length),children:"Continue"})]})]}):l.jsxs("div",{className:"compact-stack",children:[l.jsxs("div",{className:"setup-field",children:[l.jsx("label",{className:"setup-label",htmlFor:"competitors",children:"Competitor domains (one per line)"}),l.jsx("textarea",{id:"competitors",className:"setup-textarea",rows:4,placeholder:`competitor1.com
|
|
86
|
+
competitor2.com`,value:hi,onChange:G=>Zi(G.target.value)})]}),en?l.jsx("p",{className:"text-negative-400 text-sm",children:en}):null,l.jsxs("div",{className:"setup-nav",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:Ln,children:"Back"}),l.jsxs("div",{className:"flex gap-2",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:Jc,children:"Skip"}),l.jsx(ce,{type:"button",disabled:gi.length===0||dl,onClick:hn(gl),children:dl?"Saving...":`Save ${gi.length} competitor${gi.length!==1?"s":""}`})]})]})]})]});case 4:{const G=ei.data,Fe=G?.status??(Ji===nt?.id?nt.status:void 0),bi=Fe==="completed"||Fe==="partial"||Fe==="failed"||Fe==="cancelled",La=G?.snapshots??[],Fo=La.filter($a=>$a.citationState==="cited").length,Wc=La.filter($a=>$a.answerMentioned===!0).length,Nn=new Set(La.map($a=>$a.query).filter($a=>!!$a)).size,ai=Fe?BS(Fe,La.length):!1,Zs=Ge&&!Wa,Ys=Cn??(G?.error?QK(G.error):Fe==="cancelled"?"The sweep was cancelled before it produced a baseline.":(Fe==="completed"||Fe==="partial")&&La.length===0?"The sweep finished without producing any snapshots.":nt?.statusDetail||"The sweep did not produce a baseline.");let Xs=null;return Zs||ai?Xs=l.jsx(xn,{tone:"positive",children:"Complete"}):Cn&&!Wa?Xs=l.jsx(xn,{tone:"negative",children:"Failed"}):bi?Xs=l.jsx(xn,{tone:"negative",children:Fe==="cancelled"?"Cancelled":"Failed"}):Wa&&(Xs=l.jsx(xn,{tone:"caution",children:"Running"})),l.jsxs(Ra,{className:"surface-card step-card",children:[l.jsxs("div",{className:"section-head",children:[l.jsxs("div",{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:N?"Step 2 of 2":"Step 5 of 5"}),l.jsx("h2",{children:vo()?"AI Visibility":"Launch first run"})]}),Xs]}),Zs?l.jsxs("div",{className:"compact-stack",children:[l.jsxs("p",{className:"text-secondary",children:["Setup is complete. ",l.jsx("span",{className:"text-strong font-medium",children:He})," already has a successful answer-visibility baseline."]}),l.jsxs("div",{className:"setup-nav",children:[l.jsx("span",{}),l.jsx(ce,{type:"button",onClick:()=>ct(),children:f?"Finish setup":"Open project dashboard →"})]})]}):!Wa&&vo()?l.jsxs("div",{className:"compact-stack",children:[He?l.jsx(uY,{projectName:He}):l.jsx("p",{className:"text-sm text-secondary",children:bg}),Cn&&l.jsx("p",{role:"alert",className:"text-sm text-negative",children:Cn}),l.jsxs("div",{className:"setup-nav",children:[l.jsx("span",{}),l.jsx(ce,{type:"button",onClick:Be,children:"Open project dashboard →"})]})]}):Wa?bi?ai?l.jsxs("div",{className:"compact-stack",children:[l.jsxs("p",{className:"text-neutral",children:["Sweep complete. Your first answer-visibility snapshot for"," ",l.jsx("span",{className:"text-heading font-medium",children:He}),":"]}),l.jsxs("div",{className:"grid grid-cols-3 gap-2 mt-1",children:[l.jsxs("div",{className:"rounded-md border border-default bg-surface p-3",children:[l.jsx("p",{className:"text-xs font-medium text-secondary",children:"Mentioned"}),l.jsxs("p",{className:"text-2xl font-bold tabular-nums text-primary mt-1",children:[Wc,l.jsxs("span",{className:"text-faint text-lg",children:[" / ",Nn]})]}),l.jsx("p",{className:"mt-0.5 text-sm text-secondary",children:"queries naming your brand"})]}),l.jsxs("div",{className:"rounded-md border border-default bg-surface p-3",children:[l.jsx("p",{className:"text-xs font-medium text-secondary",children:"Cited"}),l.jsxs("p",{className:"text-2xl font-bold tabular-nums text-primary mt-1",children:[Fo,l.jsxs("span",{className:"text-faint text-lg",children:[" / ",Nn]})]}),l.jsx("p",{className:"mt-0.5 text-sm text-secondary",children:"queries citing your site"})]}),l.jsxs("div",{className:"rounded-md border border-default bg-surface p-3",children:[l.jsx("p",{className:"text-xs font-medium text-secondary",children:"Results"}),l.jsx("p",{className:"text-2xl font-bold tabular-nums text-primary mt-1",children:La.length}),l.jsx("p",{className:"mt-0.5 text-sm text-secondary",children:"completed engine checks"})]})]}),!b&&He?l.jsx(WX,{projectName:He}):null,l.jsxs("div",{className:"setup-nav",children:[l.jsx("span",{}),l.jsx(ce,{type:"button",onClick:()=>ct(),children:f?"Finish setup":"Open project dashboard →"})]})]}):l.jsxs("div",{className:"compact-stack",children:[l.jsxs("div",{role:"alert",className:"rounded-md border border-negative bg-negative-soft p-3 text-sm text-negative",children:[l.jsx("p",{children:Ys}),l.jsx("p",{className:"mt-1 text-xs text-secondary",children:vo()?bg:x?"Fix provider or query configuration if needed, then retry without leaving setup.":"Ask an administrator to review the provider and query configuration."})]}),l.jsxs("div",{className:"setup-nav",children:[x&&!vo()?l.jsx(ce,{type:"button",variant:"outline",asChild:!0,children:l.jsx(We,{to:"/settings",children:"Configure providers"})}):l.jsx("span",{}),vo()||!x?l.jsx(ce,{type:"button",onClick:Be,children:"Open project dashboard →"}):l.jsx(ce,{type:"button",disabled:fi||!!ti,onClick:hn(yi),children:fi?"Retrying...":"Retry visibility sweep"})]})]}):l.jsxs("div",{className:"compact-stack",children:[l.jsx("p",{className:"text-neutral",children:"Sweep running. This usually takes 30 to 60 seconds."}),l.jsx("div",{className:"rounded-md border border-default bg-surface p-3 text-xs text-muted",children:l.jsxs("p",{children:["Status: ",l.jsx("span",{className:"text-neutral",children:Fe??"queued"})]})}),ei.isError&&l.jsxs("div",{role:"alert",className:"rounded-md border border-negative bg-negative-soft p-3 text-sm text-negative",children:[l.jsx("p",{children:ei.error instanceof Error?ei.error.message:"Could not refresh the sweep status."}),l.jsx(ce,{type:"button",variant:"outline",size:"sm",className:"mt-2",onClick:()=>{ei.refetch()},children:"Retry status check"})]}),l.jsxs("div",{className:"setup-nav",children:[l.jsx("span",{}),l.jsx(ce,{type:"button",variant:"outline",onClick:f?()=>ct():Be,children:f?"Finish setup":"Watch on project page"})]})]}):l.jsxs("div",{className:"compact-stack",children:[l.jsxs("p",{className:"supporting-copy",children:["Your queries are saved. Run a first sweep to get a baseline for"," ",l.jsx("span",{className:"text-heading font-medium",children:He}),", or finish and run it later from the project. A sweep calls the answer engines, so it costs provider usage."]}),(ti||Cn)&&l.jsxs("div",{role:"alert",className:"rounded-md border border-negative bg-negative-soft p-3 text-sm text-negative",children:[l.jsx("p",{children:Cn??ti}),l.jsx("p",{className:"mt-1 text-xs text-secondary",children:"Resolve the blocker above, then retry the sweep here."})]}),l.jsxs("div",{className:"setup-nav",children:[l.jsx(ce,{type:"button",variant:"outline",onClick:Ln,children:"Back"}),l.jsx(ce,{type:"button",variant:"ghost",onClick:Ht,children:"Finish without running"}),xa==="no_provider"&&!N?l.jsx(ce,{type:"button",asChild:!0,children:l.jsx(We,{to:"/settings",children:"Configure a provider"})}):l.jsx(ce,{type:"button",disabled:fi||!!ti,title:ti,onClick:hn(yi),children:fi?"Launching...":Cn?"Retry visibility sweep":"Launch visibility sweep"})]})]})]})}default:return null}})();return l.jsxs("div",{className:N?"page-container visibility-setup":"page-container",children:[f?l.jsx(_o,{current:"visibility"}):null,l.jsxs("div",{className:"page-header",children:[l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{ref:u?h:void 0,tabIndex:u?-1:void 0,className:"page-title",children:u?"Set up AI Visibility":"Setup"}),l.jsx("p",{className:"page-subtitle",children:u?"Connect an answer engine, then choose queries for your first sweep.":"Create a project and run its first visibility check."})]}),f?l.jsx("div",{className:"page-header-right",children:l.jsx(ce,{type:"button",variant:"outline",className:"min-h-11",onClick:Ht,children:"Skip AI Visibility"})}):null]}),f?null:l.jsx(sJ,{current:N?q===4?1:0:q,labels:N?aJ:nJ}),l.jsxs("section",{className:"setup-wizard",children:[Fs,ni]})]})}const Df="canonry mcp install --client claude-code",lJ="https://github.com/Canonry/canonry/blob/main/docs/mcp.md";function cJ(){const e=C.useRef(A1()).current,n=C.useRef(new Set),i=C.useCallback((r,u)=>{n.current.has(r)||(n.current.add(r),o1({...u,flowVersion:ft,onboardingSessionId:e,surface:"platform",eventId:C1()}))},[e]);return C.useEffect(()=>{i("started",{event:"onboarding.started",step:"finish",resumed:!1})},[i]),C.useCallback(r=>{i(`action:${r}`,{event:"onboarding.step_completed",step:"finish",method:"manual",nextAction:r})},[i])}const Um=C.createContext(()=>{});function uJ({projectName:e,skippedVisibility:n=!1}){const i=yt({...RQ({client:W,path:{name:e}}),retry:!1}),r=i.data?.hasData?i.data:null,u=cJ(),h=VS(e,Re["site-audit"]),f=VS(e,Re["answer-visibility"]),b={...h?{site:h,fixes:h}:{},...dJ(f,n)};return l.jsx(Um.Provider,{value:u,children:l.jsxs("div",{className:"page-container max-w-6xl py-8 md:py-10",children:[l.jsx(_o,{current:"done",outcomes:b}),l.jsxs("header",{className:"relative mx-auto mt-12 max-w-2xl text-center md:mt-16",children:[l.jsx(mJ,{}),l.jsx("p",{className:"onb-reveal mt-6 text-sm font-medium text-positive",style:Da(250),children:"Setup complete"}),l.jsx("h1",{className:"onb-reveal mt-2 text-5xl font-semibold tracking-tight text-heading md:text-6xl",style:Da(350),children:"You’re set."}),l.jsxs("p",{className:"onb-reveal mx-auto mt-4 max-w-xl text-lg text-secondary",style:Da(450),children:["Canonry is tracking ",l.jsx("span",{className:"font-medium text-heading",children:e}),". Here’s how to get the most out of it from here."]})]}),l.jsxs("div",{className:"mt-14 grid gap-4 md:grid-cols-6",children:[l.jsx(xd,{className:"md:col-span-4 md:row-span-2",delayMs:600,labelledBy:"onb-agent-heading",children:l.jsx(fJ,{projectName:e})}),l.jsx(xd,{className:"md:col-span-2 md:row-span-2",delayMs:700,labelledBy:"onb-data-heading",children:l.jsx(bJ,{projectName:e})}),l.jsx(xd,{className:"md:col-span-3",delayMs:800,labelledBy:"onb-schedule-heading",children:l.jsx(wJ,{projectName:e})}),l.jsx(xd,{className:"md:col-span-3",delayMs:900,labelledBy:"onb-alerts-heading",children:l.jsx(SJ,{projectName:e,score:r?.aggregateScore??null})})]}),l.jsxs("div",{className:"onb-reveal mt-12 flex flex-col items-center gap-3 sm:flex-row sm:justify-center",style:Da(1e3),children:[l.jsx(ce,{asChild:!0,className:"h-11 rounded-full px-6 text-base md:h-11",children:l.jsxs(We,{to:"/projects/$projectName",params:{projectName:e},replace:!0,onClick:()=>u("open_project"),children:["Open ",e,l.jsx(wc,{className:"size-4","aria-hidden":"true"})]})}),l.jsx(ce,{asChild:!0,variant:"ghost",className:"h-11 rounded-full px-5 md:h-11",children:l.jsx(We,{to:"/projects/$projectName/technical-aeo",params:{projectName:e},replace:!0,onClick:()=>u("review_page_health"),children:"Review page health"})})]})]})})}function VS(e,n){const i=yt({...lC({client:W,path:{name:e},query:{kind:n,limit:20}}),retry:!1,refetchInterval:r=>US(r.state.status==="success"?{isSuccess:!0,data:r.state.data}:{isSuccess:!1})==="pending"?5e3:!1});return US(i)}function dJ(e,n){return e===void 0?{}:n?{visibility:"skipped"}:{visibility:e}}function US(e){if(!e.isSuccess||!e.data)return"unknown";const n=e.data.filter(i=>i.trigger!==ci.probe);if(!n.some(i=>i.status===Zt.completed||i.status===Zt.partial))return n.some(i=>i.status===Zt.queued||i.status===Zt.running)?"pending":n.length>0?"incomplete":"skipped"}function Da(e){return{"--onb-delay":`${e}ms`}}function mJ(){return l.jsx("div",{className:"onb-check relative mx-auto size-20","aria-hidden":"true",children:l.jsxs("svg",{viewBox:"0 0 80 80",className:"relative size-20",children:[l.jsx("circle",{className:"onb-check-ring",cx:"40",cy:"40",r:"36",fill:"none",strokeWidth:"3",pathLength:"1"}),l.jsx("path",{className:"onb-check-mark",d:"M25 41 L35 51 L56 30",fill:"none",strokeWidth:"4",strokeLinecap:"round",strokeLinejoin:"round",pathLength:"1"})]})})}function xd({className:e="",delayMs:n,labelledBy:i,children:r}){return l.jsx("section",{"aria-labelledby":i,className:`onb-reveal onb-tile flex flex-col overflow-hidden rounded-2xl border border-default bg-surface p-6 md:p-7 ${e}`,style:Da(n),children:r})}function Gm({id:e,eyebrow:n,title:i,children:r}){return l.jsxs("div",{children:[l.jsx("p",{className:"text-xs font-medium uppercase tracking-wide text-muted",children:n}),l.jsx("h2",{id:e,className:"mt-1.5 text-2xl font-semibold tracking-tight text-heading",children:i}),l.jsx("p",{className:"mt-2 text-sm text-secondary",children:r})]})}const wd=[{id:"diagnose",label:"Diagnose",prompt:"Why did we lose citations this week?",calls:["canonry_insights_list","canonry_competitor_landscape"],reply:"Two engines started citing a competitor’s comparison page instead of yours. Want me to draft one that answers the same query?"},{id:"fix",label:"Fix",prompt:"Fix the weakest pages on the site.",calls:["canonry_technical_aeo_pages","canonry_site_health_page_audit"],reply:"The lowest-scoring pages are missing structured data and answer-first intros. I’ve written the changes for you to review."},{id:"automate",label:"Automate",prompt:"Re-check everything every Monday and tell me in Slack.",calls:["canonry_schedule_set","canonry_agent_webhook_attach"],reply:"Done. A sweep runs every Monday, and I’ll post what changed to Slack."}],pJ=9e3;function hJ(){return typeof window<"u"&&typeof window.matchMedia=="function"&&window.matchMedia("(prefers-reduced-motion: reduce)").matches}function fJ({projectName:e}){const n=C.useContext(Um),[i,r]=C.useState(0),[u,h]=C.useState(!1),[f,b]=C.useState(!1);C.useEffect(()=>{if(u||hJ())return;const S=window.setTimeout(()=>r(k=>(k+1)%wd.length),pJ);return()=>window.clearTimeout(S)},[i,u]);const v=async()=>{try{await navigator.clipboard.writeText(Df),n("copy_agent_command"),b(!0),window.setTimeout(()=>b(!1),1800)}catch{kn({tone:"negative",title:"Could not copy the command",detail:`Run ${Df} in your terminal.`})}},x=wd[i]??wd[0];return l.jsxs(l.Fragment,{children:[l.jsxs(Gm,{id:"onb-agent-heading",eyebrow:"Your agent",title:"Let your agent run it.",children:["Your agent can do everything in Canonry: diagnose a drop, fix pages, run sweeps and scans, and write the client report. Use Claude Code, Codex, Cursor, or Aero, the analyst built into"," ",l.jsx("span",{className:"text-heading",children:e})," that reviews every sweep on its own."]}),l.jsxs("div",{className:"mt-6 flex flex-1 flex-col rounded-xl border border-default bg-bg",onMouseEnter:()=>h(!0),onMouseLeave:()=>h(!1),onFocus:()=>h(!0),children:[l.jsxs("div",{className:"flex items-center gap-1 border-b border-default px-3 py-2",role:"tablist","aria-label":"Example agent sessions",children:[wd.map((S,k)=>l.jsx("button",{type:"button",role:"tab","aria-selected":k===i,onClick:()=>{r(k),h(!0)},className:`rounded-md px-2.5 py-1 text-xs font-medium transition-colors ${k===i?"bg-surface-inset text-heading":"text-muted hover:text-secondary"}`,children:S.label},S.id)),l.jsx("span",{className:"ml-auto text-xs text-faint",children:"Example"})]}),l.jsxs("div",{role:"tabpanel","aria-label":`${x.label} example`,className:"flex-1 p-4 font-mono text-[13px] leading-relaxed",children:[l.jsxs("p",{className:"onb-type text-heading",style:Da(150),children:[l.jsx("span",{className:"text-muted",children:"> "}),x.prompt]}),x.calls.map((S,k)=>l.jsxs("p",{className:"onb-line mt-1 text-muted first:mt-3",style:Da(1300+k*450),children:[l.jsx("span",{className:"text-positive",children:"●"})," ",S]},S)),l.jsx("p",{className:"onb-line mt-3 text-secondary",style:Da(1500+x.calls.length*450),children:x.reply}),l.jsx("span",{className:"onb-caret mt-2 inline-block h-4 w-2 bg-current align-middle text-secondary",style:Da(1900+x.calls.length*450),"aria-hidden":"true"})]},x.id)]}),l.jsxs("div",{className:"mt-4 flex flex-wrap items-center gap-2",children:[l.jsx("code",{className:"min-w-0 flex-1 truncate rounded-lg border border-default bg-surface-inset px-3 py-2 font-mono text-[13px] text-heading",children:Df}),l.jsxs(ce,{type:"button",variant:"secondary",size:"sm",className:"h-9 md:h-9",onClick:()=>{v()},children:[f?l.jsx(im,{className:"size-4","aria-hidden":"true"}):l.jsx(Tg,{className:"size-4","aria-hidden":"true"}),f?"Copied":"Copy"]}),l.jsx("a",{href:lJ,target:"_blank",rel:"noreferrer",className:"text-sm font-medium text-link underline-offset-4 hover:underline",children:"Other clients"})]})]})}const gJ=[{icon:_g,label:"Search Console",action:"connect_search_console",to:"/projects/$projectName/search-console"},{icon:ik,label:"Google Analytics",action:"connect_analytics",to:"/projects/$projectName/activity"},{icon:ok,label:"Business Profile",action:"connect_business_profile",to:"/projects/$projectName/local"}],yJ=["GPTBot","ClaudeBot","PerplexityBot"];function bJ({projectName:e}){const n=C.useContext(Um);return l.jsxs(l.Fragment,{children:[l.jsx(Gm,{id:"onb-data-heading",eyebrow:"Server-side traffic",title:"See the AI bots.",children:"AI crawlers and answer-engine fetches never run JavaScript, so Google Analytics never sees them. Canonry reads them straight from your server."}),l.jsx(vJ,{}),l.jsxs(We,{to:"/traffic",onClick:()=>n("connect_server_traffic"),"aria-label":"Connect server-side traffic",className:"group flex items-center gap-3 rounded-xl border border-strong bg-surface-inset px-4 py-3 text-sm font-medium text-heading transition-colors hover:bg-surface-inset-hover",children:[l.jsx(rk,{className:"size-4 text-positive","aria-hidden":"true"}),l.jsxs("span",{className:"flex-1",children:["Connect your server",l.jsx("span",{className:"block text-xs font-normal text-secondary",children:"Cloudflare, Vercel, WordPress, or Cloud Run"})]}),l.jsx(wc,{className:"size-4 text-link transition-transform group-hover:translate-x-0.5","aria-hidden":"true"})]}),l.jsx("p",{className:"mt-5 text-xs font-medium uppercase tracking-wide text-muted",children:"Also connect"}),l.jsx("ul",{className:"mt-1 divide-y divide-default",children:gJ.map(({icon:i,label:r,action:u,to:h})=>l.jsx("li",{children:l.jsxs(We,{to:h,params:{projectName:e},"aria-label":`Connect ${r}`,onClick:()=>n(u),className:"group flex items-center gap-3 py-2.5 text-sm text-heading",children:[l.jsx(i,{className:"size-4 text-muted","aria-hidden":"true"}),l.jsx("span",{className:"flex-1",children:r}),l.jsx(wc,{className:"size-3.5 text-link transition-transform group-hover:translate-x-0.5","aria-hidden":"true"})]})},r))})]})}function vJ(){const e=[22,70,118];return l.jsxs("div",{className:"relative my-6 h-36","aria-hidden":"true",children:[l.jsx("svg",{viewBox:"0 0 200 140",preserveAspectRatio:"none",className:"absolute inset-0 size-full",children:e.map((n,i)=>l.jsx("path",{className:"onb-flow",style:Da(i*400),d:`M20 ${n} C 100 ${n}, 118 70, 170 70`,fill:"none",strokeWidth:"1.5"},n))}),yJ.map((n,i)=>l.jsx("span",{className:"onb-bot absolute left-0 -translate-y-1/2 rounded-md border border-default bg-bg-elevated px-2 py-1 font-mono text-[11px] text-secondary",style:{top:`${(e[i]??70)/140*100}%`,...Da(i*600)},children:n},n)),l.jsx("span",{className:"onb-hub absolute right-0 top-1/2 flex size-11 -translate-y-1/2 items-center justify-center rounded-2xl bg-accent text-on-inverse",children:l.jsx(rk,{className:"size-5"})})]})}const xJ=["M","T","W","T","F","S","S"];function wJ({projectName:e}){return l.jsxs(l.Fragment,{children:[l.jsx(Gm,{id:"onb-schedule-heading",eyebrow:"Scheduled sweeps",title:"Runs on its own.",children:"Re-measure every week without lifting a finger, so a drop shows up before a customer notices."}),l.jsx("ol",{className:"mt-6 grid grid-cols-7 gap-2","aria-hidden":"true",children:xJ.map((n,i)=>l.jsxs("li",{className:"flex flex-col items-center gap-2",children:[l.jsx("span",{className:"onb-day size-3 rounded-full bg-surface-inset",style:Da(i*500)}),l.jsx("span",{className:"text-xs text-muted",children:n})]},i))}),l.jsx(JC,{projectName:e,to:"/projects/$projectName/settings",icon:sk,label:"Set a schedule",action:"set_schedule"})]})}function SJ({projectName:e,score:n}){return l.jsxs(l.Fragment,{children:[l.jsx(Gm,{id:"onb-alerts-heading",eyebrow:"Notifications",title:"Hear about changes.",children:"Get a webhook in Slack or anywhere else when a sweep finishes or a score moves."}),l.jsxs("div",{className:"relative mt-6 flex h-14 items-center","aria-hidden":"true",children:[l.jsx("span",{className:"onb-bell flex size-10 items-center justify-center rounded-full border border-default bg-bg-elevated",children:l.jsx(Of,{className:"size-4 text-secondary"})}),l.jsxs("span",{className:"onb-toast ml-3 flex items-center gap-2 rounded-xl border border-default bg-bg-elevated px-3 py-2 text-sm shadow-[0_8px_24px_var(--color-shadow-panel)]",children:[l.jsx("span",{className:"size-2 rounded-full bg-positive-400"}),l.jsx("span",{className:"text-heading",children:e}),l.jsx("span",{className:"text-secondary",children:n===null?"sweep finished":`page health ${n}`})]})]}),l.jsx(JC,{projectName:e,to:"/projects/$projectName/settings",icon:Of,label:"Add a notification",action:"add_notification"})]})}function JC({projectName:e,to:n,icon:i,label:r,action:u}){const h=C.useContext(Um);return l.jsxs(We,{to:n,params:{projectName:e},onClick:()=>h(u),className:"group mt-6 inline-flex items-center gap-2 self-start text-sm font-medium text-link",children:[l.jsx(i,{className:"size-4","aria-hidden":"true"}),r,l.jsx(wc,{className:"size-3.5 transition-transform group-hover:translate-x-0.5","aria-hidden":"true"})]})}const kJ=C.lazy(async()=>({default:(await Gi(()=>import("./SiteHealthSection-CWEIYXut.js").then(n=>n.d),__vite__mapDeps([0,1,2,3,4]),import.meta.url)).SiteHealthSection})),jJ=`Public pages only, crawled from this computer and stored locally. The first scan reads up to ${p3} pages, then stops.`,AJ=1800,CJ="https://github.com/Canonry/canonry#or-use-any-shell-capable-coding-agent",NJ="Help me set up Canonry for my public site.\n\nUse the official Canonry docs:\n- Agent quickstart: https://github.com/Canonry/canonry#or-use-any-shell-capable-coding-agent\n- CLI reference: https://github.com/Canonry/canonry/blob/main/skills/canonry/references/canonry-cli.md\n- Plugin setup: https://github.com/Canonry/canonry/blob/main/docs/plugins.md\n- MCP setup: https://github.com/Canonry/canonry/blob/main/docs/mcp.md\n\nPick one path and stay on it. Use connected Canonry tools (plugin or MCP) only if you have them and I have not pointed you at a specific install. A connected tool runs in its own process and never sees `CANONRY_CONFIG_DIR`, `CANONRY_PORT`, or anything else you export in a shell, so it always acts on my default install. If I named a config directory, a port, or a sandbox, that is the shell path: use `cnry` and tell me which path you chose. Never mix the two in one run, and never create a duplicate project. The `cnry` and `canonry` commands are interchangeable.\n\n1. Ask for my public domain, country, and language. Do not create or scan anything yet. Country and language are only applied when a project is created, so if you reuse an existing project, report its country and language instead of changing them.\n2. Shell path only: confirm `cnry` is on PATH, then run `cnry --version`. If Canonry is missing, propose `npm install -g @canonry/canonry` and wait for approval. Then run `cnry doctor --format json`, which is the command that says whether config, database, and server are in place. `cnry --version` does not read config and succeeds on a completely unconfigured install, so it cannot answer this. If config is missing, run `cnry bootstrap` yourself: it is not interactive, takes about a second, and is safe to rerun. Do not hand it to me and wait. The interactive command is `cnry init`, which is optional provider and OAuth setup that Page Health does not need. Bootstrap prints an API key, so do not repeat its output back to me, and never ask me to paste passwords, API keys, OAuth credentials, or command output.\n3. Confirm the API is reachable. `cnry doctor --format json` reports it, and any project read exits non-zero with `CONNECTION_ERROR` when it is not. If it is unreachable, propose `cnry start` and wait for approval. Use `cnry start`, which is the background daemon, and not `cnry serve`, which runs in the foreground and will block you until I stop it, even though some error messages suggest it. Stop anything you started with `cnry stop`.\n4. List projects with the connected project tool or `cnry project list --format json`, and reuse one whose domain matches. Confirm the proposed name is not already assigned to a different domain. To find out whether a project has already been scanned, run `cnry technical-aeo score <project> --format json` with no `--run-id`, which reports the latest run. Read the `hasData` field, not the score: this command exits 0 and reports `aggregateScore: 0` for a project that has never been scanned, so reading the score alone would have you tell me my site scored zero. If `hasData` is true and `runStatus` is `completed` or `partial`, read that scan instead of starting a new one. If no project matches, show the exact create operation and wait for approval.\n5. Propose a bounded Site Health scan: `--max-pages 100` for a first look, plus whether dead-link checking is on (it is off unless you pass `--check-dead-links`). Show the connected operation or the exact `cnry technical-aeo run <project> --max-pages 100 --wait --format json` command with the project name filled in, and wait for separate approval before scanning. `--wait` polls for up to 15 minutes and returns only the run id and status. If the status it returns is still `queued` or `running`, the scan has not finished: do not rerun it or report results, poll `cnry technical-aeo progress <project> --run-id <run-id> --format json` until it is terminal. If `--wait` outruns your own tool timeout first, recover the run id with `cnry technical-aeo score <project> --format json` and poll the same way.\n6. When the run is `completed` or `partial`, read `cnry technical-aeo crawl <project> --run-id <run-id> --format json` first. It is the only one of these commands that carries `termination` and `complete`; the score and pages commands do not. Then read `cnry technical-aeo score <project> --run-id <run-id> --format json` and `cnry technical-aeo pages <project> --run-id <run-id> --sort score-asc --limit 10 --format jsonl`. Tell me the termination reason in plain words and whether the scan covered the whole site or stopped at a page, link, depth, or time limit. A `partial` run scored the pages it reached and not my site, so never present it as a full-site result. If it stopped early, the fix depends on the reason, so say which: a page or depth limit needs a larger budget, a time limit needs a smaller scan (a lower `--max-pages` or `--max-depth`). If the run failed or was cancelled, inspect the run error and stop.\n7. Summarize only completed evidence, then propose AI Visibility setup. Ask before you add queries, connect providers, start a provider-backed or quota-consuming run, edit files, or publish.";function _J(e,n){return e==="legacy"?"legacy":e==="platform"?"platform":n.state==="success"?n.projectCount===0?"platform":"legacy":n.state==="error"?"retry":"loading"}const TJ="2000-01-01T00:00:00.000Z",EJ=5e3;function RJ(e,n){const i=new Set,r=new Map;for(const f of n)f.trigger!==ci.probe&&(r.has(f.projectId)||r.set(f.projectId,f.id),(f.status===Zt.completed||f.status===Zt.partial)&&i.add(f.projectId));const h=(e.every(f=>f.createdAt)?[...e].sort((f,b)=>(f.createdAt??"").localeCompare(b.createdAt??"")||f.name.localeCompare(b.name)):e).find(f=>!i.has(f.id));return h?{projectName:h.name,runId:r.get(h.id)}:null}const WC=[{value:"US",label:"United States"},{value:"CA",label:"Canada"},{value:"GB",label:"United Kingdom"},{value:"AU",label:"Australia"},{value:"NZ",label:"New Zealand"},{value:"IE",label:"Ireland"},{value:"DE",label:"Germany"},{value:"FR",label:"France"},{value:"ES",label:"Spain"},{value:"IT",label:"Italy"},{value:"NL",label:"Netherlands"},{value:"BR",label:"Brazil"},{value:"MX",label:"Mexico"},{value:"IN",label:"India"},{value:"SG",label:"Singapore"},{value:"JP",label:"Japan"}],e4=[{value:"en",label:"English"},{value:"es",label:"Spanish"},{value:"fr",label:"French"},{value:"de",label:"German"},{value:"it",label:"Italian"},{value:"pt",label:"Portuguese"},{value:"nl",label:"Dutch"},{value:"ja",label:"Japanese"}];function DJ(e,n){try{const i=new Intl.DisplayNames(["en"],{type:"region"}),r=new Intl.DisplayNames(["en"],{type:"language"}),u=e.length===2?i.of(e.toUpperCase()):void 0,h=n?r.of(n.toLowerCase()):void 0;return`${u??(e||"Country")} · ${h??(n||"Language")}`}catch{return`${e||"Country"} · ${n||"Language"}`}}function zJ(e,n){const i=e.trim().toUpperCase(),r=n.trim().toLowerCase();return{countryValid:WC.some(u=>u.value===i),languageValid:e4.some(u=>u.value===r)}}function IJ(e){const n=e.replace(/^\[|\]$/g,"");return/^(?:\d{1,3}\.){3}\d{1,3}$/.test(n)||n.includes(":")}function OJ(e){const n=e.trim();if(!n)return null;const i=/^[a-z][a-z\d+.-]*:\/\//i.test(n)?n:`https://${n}`;let r;try{r=new URL(i)}catch{return null}if(r.protocol!=="http:"&&r.protocol!=="https:")return null;const u=r.hostname.toLowerCase().replace(/^www\./,"");if(!u||u==="localhost"||IJ(u)||!u.includes("."))return null;const h=u.replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"");return h?{canonicalDomain:u,projectName:h,displayName:u}:null}async function qJ(e,n=AJ){let i;const r=new Promise(h=>{i=setTimeout(()=>h({state:"timed-out"}),n)}),u=await Promise.race([e.then(h=>({state:"queued",run:h})),r]);return i&&clearTimeout(i),u}function PJ(e,n){e.catch(()=>{kn({title:"Site Health scan did not start",detail:"The project is safe. Choose Run scan in Site Health to retry.",tone:"negative",dedupeKey:`site-health-dispatch:${n}`})})}function t4(e){const n=C.useRef(A1()).current,i=C.useRef(new Set),r=C.useCallback((u,h)=>{if(h){if(i.current.has(h))return;i.current.add(h)}o1({...u,surface:e,eventId:C1()})},[e]);return{onboardingSessionId:n,emit:r}}function GS(e,n){return e instanceof Sn&&e.statusCode===409?"A project with this name already exists. Change the project name, or open the existing project.":e instanceof Error&&e.message?e.message:n}function jg(){return l.jsxs("div",{className:"page-container max-w-3xl","aria-busy":"true","aria-live":"polite",children:[l.jsx("div",{className:"page-header",children:l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Preparing setup"}),l.jsx("p",{className:"page-subtitle",children:"Checking the projects already on this install."})]})}),l.jsxs("div",{className:"flex items-center gap-3 rounded-lg border border-default bg-surface p-4 text-sm text-secondary",role:"status",children:[l.jsx(Ir,{className:"size-4 motion-safe:animate-spin","aria-hidden":"true"}),"Loading projects…"]})]})}function MJ({onRetry:e}){return l.jsxs("div",{className:"page-container max-w-3xl",children:[l.jsx("div",{className:"page-header",children:l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Can’t load projects"}),l.jsx("p",{className:"page-subtitle",children:"Canonry could not confirm whether this install already has a project."})]})}),l.jsxs("div",{className:"rounded-lg border border-negative bg-negative-soft p-4",role:"alert",tabIndex:-1,children:[l.jsx("p",{className:"text-sm font-medium text-heading",children:"Setup is paused to protect existing projects."}),l.jsx("p",{className:"mt-1 text-sm text-secondary",children:"Check the connection or sign in again, then retry."}),l.jsx(ce,{type:"button",className:"mt-4",variant:"secondary",onClick:e,children:"Retry project check"})]})]})}function BJ({projectName:e,initialRunId:n}){return l.jsx(b1,{title:"Site Health setup",children:l.jsx(LJ,{projectName:e,initialRunId:n})})}function LJ({projectName:e,initialRunId:n}){const i=Ts(),r=yt({...qo({client:W}),enabled:!!e,retry:!1,refetchOnMount:"always"}),{onboardingSessionId:u,emit:h}=t4("site_health"),[f]=C.useState(()=>VX(n));C.useEffect(()=>{f&&UX()},[f]),C.useEffect(()=>{e&&h({flowVersion:ft,onboardingSessionId:u,event:"onboarding.started",step:"run",resumed:!!n&&!f},"onboarding.started")},[h,f,n,u,e]),C.useEffect(()=>{!e||!n||ZC(e)?.runId!==n&&FC(e,n)},[n,e]);const v=yt({...u1({client:W,path:{id:n??""}}),enabled:!!n,refetchInterval:({state:N})=>{const I=N.data?.status;return I==="completed"||I==="partial"||I==="failed"||I==="cancelled"?!1:2e3},refetchIntervalInBackground:!0}).data?.status;if(C.useEffect(()=>{if(!e||!n||!v)return;if(v==="completed"||v==="partial"){h({flowVersion:ft,onboardingSessionId:u,event:"onboarding.step_completed",step:"run",method:"automatic"},"onboarding.step_completed:run"),nm(n);return}if(v!=="failed"&&v!=="cancelled")return;const N=v==="cancelled"?"run_cancelled":"run_failed";h({flowVersion:ft,onboardingSessionId:u,event:"onboarding.blocked",step:"run",action:"retry_run",reasonCode:N},`onboarding.blocked:run:${N}`),nm(n)},[h,n,u,e,v]),!e)return l.jsxs("div",{className:"page-container max-w-3xl",children:[l.jsx("div",{className:"page-header",children:l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Project not found"}),l.jsx("p",{className:"page-subtitle",children:"This setup link does not identify a project."})]})}),l.jsx(ce,{type:"button",variant:"secondary",onClick:()=>{i({to:"/projects"})},children:"View projects"})]});if(r.isPending)return l.jsxs("div",{className:"page-container max-w-3xl","aria-busy":"true","aria-live":"polite",children:[l.jsx(_o,{current:"site"}),l.jsxs("div",{className:"mt-8 flex items-center gap-3 text-sm text-secondary",role:"status",children:[l.jsx(Ir,{className:"size-4 motion-safe:animate-spin","aria-hidden":"true"}),"Loading Site Health setup…"]})]});if(r.isError)return l.jsxs("div",{className:"page-container max-w-3xl",children:[l.jsx("div",{className:"page-header",children:l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Can’t resume setup"}),l.jsx("p",{className:"page-subtitle",children:"Canonry could not load the project for this Site Health scan."})]})}),l.jsxs("div",{className:"rounded-lg border border-negative bg-negative-soft p-4",role:"alert",children:[l.jsx("p",{className:"text-sm text-secondary",children:"Check the connection or sign in again, then retry."}),l.jsx(ce,{type:"button",className:"mt-4",variant:"secondary",onClick:()=>{r.refetch()},children:"Retry project check"})]})]});const x=r.data.find(N=>N.name===e);if(!x)return l.jsxs("div",{className:"page-container max-w-3xl",children:[l.jsx("div",{className:"page-header",children:l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Project not found"}),l.jsxs("p",{className:"page-subtitle",children:["Canonry could not find ",e,". It will not open a different project."]})]})}),l.jsx(ce,{type:"button",variant:"secondary",onClick:()=>{i({to:"/projects"})},children:"View projects"})]});const S=()=>{i({to:"/setup",search:{onboarding:"site-health",setupProject:x.name},replace:!0})},k=()=>{i({to:"/setup",search:{experience:"legacy",onboarding:"site-health",setupProject:x.name},replace:!0})},T=()=>{h({flowVersion:ft,onboardingSessionId:u,event:"onboarding.step_completed",step:"run",method:"skipped"},"onboarding.step_completed:run"),i({to:"/setup",search:{onboarding:"complete",setupProject:x.name,skipped:"visibility"},replace:!0})};return l.jsxs("div",{className:"page-container max-w-7xl py-8 md:py-10",children:[l.jsx("h1",{className:"sr-only",children:"Set up Canonry"}),l.jsx(C.Suspense,{fallback:l.jsxs("div",{className:"space-y-5",children:[l.jsx(_o,{current:"site"}),l.jsxs("div",{className:"flex min-h-72 items-center justify-center gap-3 text-sm text-secondary",role:"status",children:[l.jsx(Ir,{className:"size-4 motion-safe:animate-spin","aria-hidden":"true"}),"Loading Site Health…"]})]}),children:l.jsx(kJ,{projectName:x.name,projectId:x.id,initialRunId:n,onReleaseInitialRun:S,showOnboardingActions:!0,onContinueOnboarding:k,onSkipOnboarding:T})})]})}function $J(){const e=HS({from:"/setup"}),n=e.onboarding==="site-health"&&!e.setupProject,i=e.onboarding==="site-health"&&e.experience!=="legacy",r=IG(),u=e.experience==="legacy"?"legacy":e.experience==="platform"?"platform":r,[h,f]=C.useState(!1),[b,v]=C.useState(void 0),x=yt({...qo({client:W}),enabled:u==="auto",retry:!1,refetchOnMount:"always"}),S=yt({...zm({client:W,query:{kind:Re["site-audit"],since:TJ,limit:EJ}}),enabled:u==="auto",retry:!1,refetchOnMount:"always"}),k=u==="auto"&&x.isSuccess&&x.isFetchedAfterMount&&x.data.length===0;C.useEffect(()=>{k&&f(!0)},[k]);const T=u!=="auto"?{state:"idle"}:x.isSuccess&&x.isFetchedAfterMount?{state:"success",projectCount:x.data.length}:x.isError?{state:"error"}:{state:"loading"},N=u==="legacy"?"legacy":h||k?"platform":_J(u,T);if(e.onboarding==="complete"&&e.setupProject)return l.jsx(uJ,{projectName:e.setupProject,skippedVisibility:e.skipped==="visibility"});if(n||i)return l.jsx(BJ,{projectName:e.setupProject,initialRunId:e.siteHealthRunId});const I=u==="auto"&&N==="legacy"&&!e.setupProject&&x.isSuccess;if(I&&b===void 0)return S.isError?v(null):S.isSuccess&&S.isFetchedAfterMount&&v(RJ(x.data,S.data)),l.jsx(jg,{});const P=I?b:null;return P?l.jsx(VJ,{projectName:P.projectName,runId:P.runId}):N==="legacy"?l.jsx(oJ,{visibilityProjectName:e.setupProject,siteHealthOnboarding:e.onboarding==="site-health",onboardingFinish:e.onboarding==="site-health"||e.onboarding==="first-run"}):N==="loading"?l.jsx(jg,{}):N==="retry"?l.jsx(MJ,{onRetry:()=>{x.refetch()}}):l.jsx(UJ,{onActivationStarted:()=>f(!0),skipSiteScan:e.siteScan==="skip"})}function VJ({projectName:e,runId:n}){const i=Ts();return C.useEffect(()=>{i({to:"/setup",search:{onboarding:"site-health",setupProject:e,...n?{siteHealthRunId:n}:{}},replace:!0})},[i,e,n]),l.jsx(jg,{})}function UJ({onActivationStarted:e,skipSiteScan:n}){return l.jsx(b1,{title:"Site Health setup",children:l.jsx(GJ,{onActivationStarted:e,skipSiteScan:n})})}function GJ({onActivationStarted:e,skipSiteScan:n}){const i=Ts(),r=ta(),u=YX(),h=yt({...OH({client:W}),retry:!1}),f=Ha(qH()),[b,v]=C.useState(""),[x,S]=C.useState(""),[k,T]=C.useState(""),[N,I]=C.useState("US"),[P,E]=C.useState("en"),[$,ee]=C.useState(!1),[L,F]=C.useState("idle"),[Z,ae]=C.useState(null),[M,Y]=C.useState(null),[ue,Xe]=C.useState(!1),[nt,Ge]=C.useState(null),[Pe,Se]=C.useState(!1),Ve=h.isError?void 0:h.data,q=typeof Ve?.enabled=="boolean"?Ve.enabled:null,X=f.isPending?f.variables.body.enabled:q,[ve,ke]=C.useState(null),J=C.useRef(null),{onboardingSessionId:Ne,emit:Me}=t4("platform");C.useEffect(()=>{Me({flowVersion:ft,onboardingSessionId:Ne,event:"onboarding.started",step:"project",resumed:!1},"onboarding.started")},[Me,Ne]);const xe=OJ(b),le=x||xe?.projectName||"",re=k||xe?.displayName||"",H=L==="creating"||L==="dispatching",pe=M??nt,ze=DJ(N,P),{countryValid:je,languageValid:it}=zJ(N,P),Ue=je&⁢C.useEffect(()=>{pe&&J.current?.focus()},[pe]);const jt=(Be,ct)=>i({to:"/setup",search:{...ct?{siteHealthRunId:ct}:{},onboarding:"site-health",setupProject:Be.name},replace:!0}),He=async Be=>{F("dispatching"),Ge(null);try{const ct=u.mutateAsync({projectName:Be.name,projectId:Be.id,projectLabel:Be.displayName||Be.name,suppressErrorToast:!0,body:{checkDeadLinks:!0,maxPages:p3}}),Ht=await qJ(ct);if(Ht.state==="queued"){Me({flowVersion:ft,onboardingSessionId:Ne,event:"run.requested",origin:"dashboard_setup",result:"queued",kind:"site_health",providerCountBucket:"0",queryCountBucket:"0"}),$X(Ht.run.runId),await jt(Be,Ht.run.runId);return}ct.then(()=>{Me({flowVersion:ft,onboardingSessionId:Ne,event:"run.requested",origin:"dashboard_setup",result:"queued",kind:"site_health",providerCountBucket:"0",queryCountBucket:"0"})},Qt=>{Me({flowVersion:ft,onboardingSessionId:Ne,event:"run.requested",origin:"dashboard_setup",result:"rejected",kind:"site_health",providerCountBucket:"0",queryCountBucket:"0",reasonCode:xc(Qt,"run_rejected")})}),PJ(ct,Be.id),await jt(Be)}catch(ct){F("recovery"),Ge(GS(ct,"The project was created, but the Site Health scan could not be started."));const Ht=xc(ct,"run_rejected");Me({flowVersion:ft,onboardingSessionId:Ne,event:"run.requested",origin:"dashboard_setup",result:"rejected",kind:"site_health",providerCountBucket:"0",queryCountBucket:"0",reasonCode:Ht}),Me({flowVersion:ft,onboardingSessionId:Ne,event:"onboarding.blocked",step:"run",action:"retry_run",reasonCode:Ht},`onboarding.blocked:run:${Ht}`)}},me=async Be=>{if(Be.preventDefault(),!(!xe||!n&&!$||!Ue||H)){F("creating"),Y(null),Xe(!1),Ge(null);try{const ct=await eK({name:le,displayName:re,canonicalDomain:xe.canonicalDomain,country:N,language:P});if(e(),ae(ct),Me({flowVersion:ft,onboardingSessionId:Ne,event:"onboarding.step_completed",step:"project",method:"manual"},"onboarding.step_completed:project"),await r.invalidateQueries({queryKey:_s({client:W})}),n){await i({to:"/setup",search:{experience:"legacy",onboarding:"first-run",setupProject:ct.name},replace:!0});return}await He(ct)}catch(ct){F("idle");const Ht=ct instanceof Sn&&ct.statusCode===409;Xe(Ht),Y(GS(ct,"Could not create the project. Try again.")),Me({flowVersion:ft,onboardingSessionId:Ne,event:"onboarding.blocked",step:"project",action:"save",reasonCode:xc(ct,"project_create_failed")},"onboarding.blocked:project"),Ht&&(e(),r.invalidateQueries({queryKey:_s({client:W})}))}}},ot=()=>{Z&&!H&&He(Z)},It=()=>{H||i({to:"/projects"})},Bn=async()=>{try{await navigator.clipboard.writeText(NJ),Se(!0)}catch{kn({tone:"negative",title:"Could not copy setup request",detail:"Open the agent quickstart to continue with the CLI instead."})}},Kt=async Be=>{ke(null);try{const ct=await f.mutateAsync({client:W,body:{enabled:Be}});r.setQueryData(cC({client:W}),ct),ct.enabled!==Be&&ke(`The server kept telemetry ${ct.enabled?"on":"off"}. Check its telemetry settings.`)}catch{ke("Could not update telemetry. Try again.")}};return Z&&L==="recovery"?l.jsxs("div",{className:"page-container max-w-3xl",children:[l.jsx(_o,{current:"site"}),l.jsx("div",{className:"page-header mt-8",children:l.jsxs("div",{className:"page-header-left",children:[l.jsx("h1",{className:"page-title",children:"Project created"}),l.jsxs("p",{className:"page-subtitle",children:[Z.displayName||Z.name," is ready. The Site Health scan needs another try."]})]})}),l.jsxs("div",{ref:J,className:"rounded-lg border border-negative bg-negative-soft p-4",role:"alert",tabIndex:-1,children:[l.jsx("p",{className:"text-sm font-medium text-heading",children:nt}),l.jsx("p",{className:"mt-1 text-sm text-secondary",children:"You can retry the scan or continue setup and retry from Site Health."}),l.jsxs("div",{className:"mt-4 flex flex-wrap gap-3",children:[l.jsx(ce,{type:"button",onClick:ot,children:"Retry Site Health scan"}),l.jsx(ce,{type:"button",variant:"secondary",onClick:()=>{jt(Z)},children:"Continue setup"})]})]})]}):l.jsxs("div",{className:"page-container max-w-xl py-8 md:py-12",children:[n?null:l.jsx(_o,{current:"site"}),l.jsxs("header",{className:`mb-8 ${n?"":"mt-8"}`,children:[l.jsx("h1",{id:"site-map-setup-title",className:"text-2xl font-semibold tracking-[-0.025em] text-heading",children:n?"Create a project":"Scan your site"}),l.jsx("p",{className:"mt-2 max-w-lg text-sm leading-6 text-secondary",children:n?"Add a public domain, then choose the queries you want to track. No site scan will run.":"Enter your public website to see its pages, structure, internal links, and technical SEO scores."})]}),l.jsxs("form",{"aria-labelledby":"site-map-setup-title",className:"space-y-6",onSubmit:hn(me),noValidate:!0,children:[l.jsxs("div",{className:"grid gap-2",children:[l.jsx("label",{className:"text-sm font-medium text-heading",htmlFor:"launchpad-domain",children:"Website URL"}),l.jsx("input",{id:"launchpad-domain",className:"h-11 w-full rounded-md border border-strong bg-bg-elevated/50 px-3 text-base text-heading outline-none transition placeholder:text-muted focus:border-mono-500 focus:ring-1 focus:ring-mono-500",type:"text",inputMode:"url",autoComplete:"url",autoCapitalize:"none",spellCheck:!1,required:!0,"aria-invalid":!!(b&&!xe),"aria-describedby":b&&!xe?"launchpad-domain-hint launchpad-domain-error":"launchpad-domain-hint",placeholder:"https://example.com",value:b,onChange:Be=>{v(Be.target.value),Y(null),Xe(!1)}}),l.jsx("p",{id:"launchpad-domain-hint",className:"text-sm text-secondary",children:n?l.jsxs(l.Fragment,{children:["A public domain is still required."," ",l.jsx(We,{to:"/setup",search:{experience:"platform"},className:"font-medium text-link underline-offset-4 hover:underline",children:"Map with Site Health instead"})]}):l.jsxs(l.Fragment,{children:["Only public pages are scanned."," ",l.jsx(We,{to:"/setup",search:{experience:"platform",onboarding:"first-run",siteScan:"skip"},className:"font-medium text-link underline-offset-4 hover:underline",children:"Set up without a site scan"})]})}),b&&!xe?l.jsx("p",{id:"launchpad-domain-error",className:"text-sm text-negative",role:"alert",children:"Enter a public domain, such as example.com."}):null]}),l.jsxs("details",{className:"group border-y border-default",children:[l.jsxs("summary",{className:"flex min-h-11 cursor-pointer list-none items-center justify-between gap-4 py-3 text-sm [&::-webkit-details-marker]:hidden",children:[l.jsx("span",{className:"font-medium text-heading",children:"Project name and locale"}),l.jsxs("span",{className:"flex items-center gap-2 text-secondary",children:[ze,l.jsx(Rc,{className:"size-4 transition-transform group-open:rotate-180 motion-reduce:transition-none","aria-hidden":"true"})]})]}),l.jsxs("div",{className:"space-y-5 border-t border-default py-4",children:[xe?l.jsxs("div",{children:[l.jsx("p",{className:"mb-3 text-sm font-medium text-heading",children:"Project"}),l.jsxs("div",{className:"grid gap-4 sm:grid-cols-2",children:[l.jsxs("div",{className:"grid gap-2",children:[l.jsx("label",{className:"text-sm text-secondary",htmlFor:"launchpad-project-name",children:"Project name"}),l.jsx("input",{id:"launchpad-project-name",className:"setup-input h-10",type:"text",value:le,onChange:Be=>S(Be.target.value)})]}),l.jsxs("div",{className:"grid gap-2",children:[l.jsx("label",{className:"text-sm text-secondary",htmlFor:"launchpad-display-name",children:"Display name"}),l.jsx("input",{id:"launchpad-display-name",className:"setup-input h-10",type:"text",value:re,onChange:Be=>T(Be.target.value)})]})]})]}):null,l.jsxs("div",{children:[l.jsx("p",{className:"mb-3 text-sm font-medium text-heading",children:"Locale"}),l.jsxs("div",{className:"grid gap-4 sm:grid-cols-2",children:[l.jsxs("div",{className:"grid gap-2",children:[l.jsx("label",{className:"text-sm text-secondary",htmlFor:"launchpad-country",children:"Country"}),l.jsx("select",{id:"launchpad-country",className:"setup-input h-10",value:N,onChange:Be=>I(Be.target.value),children:WC.map(Be=>l.jsx("option",{value:Be.value,children:Be.label},Be.value))})]}),l.jsxs("div",{className:"grid gap-2",children:[l.jsx("label",{className:"text-sm text-secondary",htmlFor:"launchpad-language",children:"Language"}),l.jsx("select",{id:"launchpad-language",className:"setup-input h-10",value:P,onChange:Be=>E(Be.target.value),children:e4.map(Be=>l.jsx("option",{value:Be.value,children:Be.label},Be.value))})]})]})]})]})]}),n?null:l.jsxs("label",{className:"flex min-h-11 cursor-pointer items-start gap-3 py-2",children:[l.jsx("input",{className:"mt-0.5 size-4 shrink-0 rounded border-strong bg-bg",type:"checkbox",checked:$,onChange:Be=>ee(Be.target.checked),"aria-label":"Allow Canonry to scan this public site."}),l.jsxs("span",{className:"flex items-center gap-1.5",children:[l.jsx("span",{className:"text-sm leading-5 text-heading",children:"Allow Canonry to scan this public site."}),l.jsx(Ea,{text:jJ})]})]}),pe?l.jsxs("div",{ref:J,className:"rounded-md border border-negative bg-negative-soft p-3",role:"alert",tabIndex:-1,children:[l.jsx("p",{className:"text-sm font-medium text-heading",children:pe}),ue?l.jsx(ce,{type:"button",variant:"secondary",size:"sm",className:"mt-3",onClick:It,children:"View projects"}):null]}):null,l.jsxs("div",{className:"grid gap-2",children:[l.jsx(ce,{className:"h-11 w-full",type:"submit",disabled:!xe||!n&&!$||!Ue||H,children:L==="creating"||L==="dispatching"?l.jsxs(l.Fragment,{children:[l.jsx(Ir,{className:"size-4 motion-safe:animate-spin","aria-hidden":"true"})," ",n?"Creating project…":"Mapping site…"]}):n?"Create project":"Scan site"}),L==="dispatching"?l.jsx("span",{className:"text-center text-sm text-secondary",role:"status",children:"Opening Site Health when the scan is ready."}):null]})]}),l.jsxs("section",{className:"mt-8 border-t border-default pt-6","aria-labelledby":"agent-setup-title",children:[l.jsx("p",{id:"agent-setup-title",className:"text-sm font-medium text-heading",children:"Use your agent instead"}),l.jsx("p",{className:"mt-1 text-sm leading-5 text-secondary",children:"Copy a complete CLI setup request into any agent."}),l.jsxs("div",{className:"mt-3 flex flex-wrap items-center gap-1",children:[l.jsxs(ce,{type:"button",variant:"ghost",size:"sm",className:"-ml-3",onClick:hn(Bn),children:[Pe?l.jsx(im,{className:"size-3.5","aria-hidden":"true"}):l.jsx(Tg,{className:"size-3.5","aria-hidden":"true"}),l.jsx("span",{"aria-live":"polite",children:Pe?"Copied setup request":"Copy setup request"})]}),l.jsx(ce,{asChild:!0,variant:"ghost",size:"sm",children:l.jsxs("a",{href:CJ,target:"_blank",rel:"noopener noreferrer",children:["Agent quickstart",l.jsx(O5,{className:"size-3.5","aria-hidden":"true"}),l.jsx("span",{className:"sr-only",children:" (opens in a new tab)"})]})})]})]}),q!==null?l.jsxs("section",{className:"mt-6 border-t border-default pt-5","aria-labelledby":"telemetry-title",children:[l.jsxs("label",{className:`flex min-h-11 items-start gap-3 py-2 ${f.isPending?"cursor-wait":"cursor-pointer"}`,children:[l.jsx("input",{className:"mt-0.5 size-4 shrink-0 rounded border-strong bg-bg accent-accent focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-mono-500 disabled:cursor-wait",type:"checkbox",checked:X??!1,disabled:f.isPending,onChange:Be=>{Kt(Be.target.checked)},"aria-describedby":"telemetry-detail"}),l.jsxs("span",{className:"grid gap-0.5",children:[l.jsx("span",{id:"telemetry-title",className:"text-sm leading-5 text-heading",children:"Share anonymous product telemetry"}),l.jsx("span",{id:"telemetry-detail",className:"max-w-[70ch] text-sm leading-5 text-secondary",children:"Helps prioritize improvements. Canonry does not send raw domains, URLs, queries, answer content, or credentials."})]})]}),f.isPending?l.jsx("p",{className:"mt-1 text-sm text-secondary",role:"status",children:"Saving preference…"}):null,ve?l.jsx("p",{className:"mt-1 text-sm text-negative",role:"alert",children:ve}):null]}):null]})}function KJ(){return l.jsx("div",{className:"page-container",children:l.jsx("section",{className:"page-section",children:l.jsxs(Ra,{className:"surface-card empty-card",children:[l.jsx("h1",{children:"Route not found"}),l.jsx("p",{children:"The current path does not map to a dashboard view."}),l.jsx(ce,{asChild:!0,children:l.jsx(We,{to:"/",children:"Return to overview"})})]})})})}const ga=Es(()=>Gi(()=>import("./ProjectPage-Dbbxf8yl.js"),__vite__mapDeps([5,1,0,2,3,4,6,7,8,9,10,11]),import.meta.url),"ProjectPage"),HJ=Es(()=>Gi(()=>import("./RunsPage-B6LqcDRg.js"),__vite__mapDeps([12,1,10,4,2,7,11]),import.meta.url),"RunsPage"),QJ=Es(()=>Gi(()=>import("./HistoryPage-70YWNYBU.js"),__vite__mapDeps([13,1,9,10,4,2,7,11]),import.meta.url),"HistoryPage"),FJ=Es(()=>Gi(()=>import("./SettingsPage-DNV6Is27.js"),__vite__mapDeps([14,1,10,4,2,7,11]),import.meta.url),"SettingsPage"),ZJ=Es(()=>Gi(()=>import("./BacklinksPage-h25kHk3u.js"),__vite__mapDeps([15,1,2,10,4,7,11]),import.meta.url),"BacklinksPage"),YJ=Es(()=>Gi(()=>import("./TrafficPage-ZZqGgMyL.js"),__vite__mapDeps([16,1,8,2,10,4,7,11]),import.meta.url),"TrafficPage"),XJ=Es(()=>Gi(()=>import("./TrafficSourceDetailPage-_RMyqM86.js"),__vite__mapDeps([17,1,8,3,4,2,10,7,11]),import.meta.url),"TrafficSourceDetailPage"),JJ=Es(()=>Gi(()=>import("./MeasurementPropertyPage-CBPQ3A99.js"),__vite__mapDeps([18,1,3,4,6,7,2,10,11]),import.meta.url),"MeasurementPropertyPage");function WJ(){return l.jsx(JY,{children:l.jsx(GK,{children:l.jsx(XY,{})})})}const Gn=d5()({component:WJ,validateSearch:e=>({manageQueries:e.manageQueries===!0||e.manageQueries==="true"?!0:void 0,runId:typeof e.runId=="string"?e.runId:void 0,siteHealthRunId:typeof e.siteHealthRunId=="string"?e.siteHealthRunId:void 0,evidenceId:typeof e.evidenceId=="string"?e.evidenceId:void 0,runStatus:typeof e.runStatus=="string"?e.runStatus:void 0,runKind:typeof e.runKind=="string"?e.runKind:void 0,runProject:typeof e.runProject=="string"?e.runProject:void 0,runWindow:typeof e.runWindow=="string"?e.runWindow:void 0,runQuery:typeof e.runQuery=="string"?e.runQuery:void 0,onboarding:e.onboarding==="site-health"||e.onboarding==="first-run"||e.onboarding==="complete"?e.onboarding:void 0,experience:e.experience==="legacy"||e.experience==="platform"?e.experience:void 0,siteScan:e.siteScan==="skip"?"skip":void 0,skipped:e.skipped==="visibility"?"visibility":void 0,setupProject:typeof e.setupProject=="string"?e.setupProject:void 0,scope:typeof e.scope=="string"?e.scope:void 0,class:typeof e.class=="string"?e.class:void 0,...Object.fromEntries(["queryWorkspace","researchMode","trackingQueryId","measurementScope","measurementScopeKey","measurementMarketKey","queryClass","measurementProvider","measurementModel","measurementLocation","measurementFrom","measurementTo","measurementRevision","measurementRunId","measurementQueryKey","measurementAnswer"].map(n=>[n,typeof e[n]=="string"?e[n]:void 0]))})}),eW=Mt({getParentRoute:()=>Gn,path:"/",component:EX,beforeLoad:async({context:e})=>{let n=e.queryClient.getQueryData(_s({client:W}));if(n===void 0)try{n=await e.queryClient.ensureQueryData(qo({client:W}))}catch{return}if(n.length===0)throw FS({to:"/setup"})}}),tW=Mt({getParentRoute:()=>Gn,path:"/projects",component:IX}),nW=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i,Kn=Mt({getParentRoute:()=>Gn,path:"/projects/$projectName",component:()=>l.jsx(zf,{}),beforeLoad:async({context:e,params:n,location:i})=>{const r=n.projectName;if(!nW.test(r))return;let u=e.queryClient.getQueryData(_s({client:W}));if(!u)try{u=await e.queryClient.ensureQueryData(qo({client:W}))}catch{return}const h=u.find(f=>f.id===r);if(h)throw FS({to:i.pathname.replace(`/projects/${r}`,`/projects/${encodeURIComponent(h.name)}`),replace:!0})}}),aW=Mt({getParentRoute:()=>Kn,path:"/",component:()=>l.jsx(ga,{tab:"overview"})}),iW=Mt({getParentRoute:()=>Kn,path:"/portfolio",component:()=>l.jsx(ga,{tab:"portfolio"})}),sW=Mt({getParentRoute:()=>Kn,path:"/search-console",component:()=>l.jsx(ga,{tab:"search-console"})}),oW=Mt({getParentRoute:()=>Kn,path:"/conversions",component:()=>l.jsx(ga,{tab:"conversions"})}),rW=Mt({getParentRoute:()=>Kn,path:"/local",component:()=>l.jsx(ga,{tab:"local"})}),lW=Mt({getParentRoute:()=>Kn,path:"/discovery",component:()=>l.jsx(ga,{tab:"discovery"})}),cW=Mt({getParentRoute:()=>Kn,path:"/queries",component:()=>l.jsx(ga,{tab:"queries"})}),uW=Mt({getParentRoute:()=>Kn,path:"/properties/$targetKey",component:()=>l.jsx(JJ,{})}),dW=Mt({getParentRoute:()=>Kn,path:"/report",component:()=>l.jsx(ga,{tab:"report"})}),mW=Mt({getParentRoute:()=>Kn,path:"/activity",component:()=>l.jsx(ga,{tab:"activity"})}),pW=Mt({getParentRoute:()=>Kn,path:"/backlinks",component:()=>l.jsx(ga,{tab:"backlinks"})}),hW=Mt({getParentRoute:()=>Kn,path:"/technical-aeo",component:()=>l.jsx(ga,{tab:"technical-aeo"})}),fW=Mt({getParentRoute:()=>Kn,path:"/history",component:()=>l.jsx(ga,{tab:"history"})}),gW=Mt({getParentRoute:()=>Kn,path:"/settings",component:()=>l.jsx(ga,{tab:"settings"})}),yW=Mt({getParentRoute:()=>Gn,path:"/runs",component:HJ}),bW=Mt({getParentRoute:()=>Gn,path:"/history",component:QJ}),vW=Mt({getParentRoute:()=>Gn,path:"/settings",component:FJ,beforeLoad:({context:e})=>{}}),xW=Mt({getParentRoute:()=>Gn,path:"/setup",component:$J}),wW=Mt({getParentRoute:()=>Gn,path:"/backlinks",component:ZJ}),SW=Mt({getParentRoute:()=>Gn,path:"/traffic",component:YJ}),kW=Mt({getParentRoute:()=>Gn,path:"/traffic/$projectName/$sourceId",component:XJ}),jW=Mt({getParentRoute:()=>Gn,path:"*",component:KJ}),AW=Gn.addChildren([eW,tW,Kn.addChildren([aW,iW,sW,oW,rW,lW,cW,uW,dW,mW,pW,hW,fW,gW]),yW,bW,vW,xW,wW,SW,kW,jW]);function CW(){return typeof window<"u"&&window.__CANONRY_CONFIG__?.basePath?window.__CANONRY_CONFIG__.basePath:"/"}const KS=CW(),NW=KS==="/"?"":KS.replace(/\/$/,"");function _W(e,n){return m5({routeTree:AW,basepath:NW||"/",context:{queryClient:e},...n?.initialEntries})}const TW=6e4;function EW(){const e=C.useRef(XG()).current,[n,i]=C.useState(e?"ready":"checking"),[r,u]=C.useState(null),[h,f]=C.useState(null),[b,v]=C.useState(e),[x,S]=C.useState(!1),[k,T]=C.useState(""),[N,I]=C.useState(""),[P,E]=C.useState(""),[$,ee]=C.useState(!1),[L,F]=C.useState("password"),[Z,ae]=C.useState(null),[M,Y]=C.useState(!1),[ue,Xe]=C.useState(!1),nt=C.useRef(null),Ge=C.useRef(null),Pe=C.useRef(null),Se=()=>{const H=r?`${r.name}:${r.role}`:e?"api-key:explicit":h?`api-key:${h.id}`:"no-accounts";if(!nt.current||Pe.current!==H){Ge.current?.clear();const pe=$K();Ge.current=pe,nt.current=_W(pe),Pe.current=H}return{queryClient:Ge.current,router:nt.current}},Ve=H=>H.authRequired?(S(!0),u(H.user),f(null),v(!1),i(H.user?"ready":"account-login"),!0):!1;C.useEffect(()=>{let H=!1;const pe=async(ze,je=!1)=>{try{const it=await kf();if(H)return;f(it),v(!1),i("ready")}catch(it){if(H)return;if(je&&it instanceof Sn&&it.statusCode===401)return cK().then(()=>{H||(ae(null),f(null),v(!1),Xe(!0),i("login"))}).catch(Ue=>{H||(ae(Ue instanceof Error?Ue.message:"Could not clear the invalid session"),i(ze))});ae(it instanceof Error?it.message:"Could not verify API key access"),i(ze)}};return e?(pe("api-key-error"),()=>{H=!0}):(Promise.allSettled([Xw(),Yw()]).then(([ze,je])=>{if(H||ze.status==="fulfilled"&&Ve(ze.value))return;if(je.status==="rejected"){const Ue=je.reason;ae(Ue instanceof Error?Ue.message:"Failed to reach the Canonry API"),i("login");return}const it=je.value;it.authenticated?(v(!0),pe("api-key-error",!0)):(f(null),v(!1),i(it.setupRequired?"setup":"login"))}),()=>{H=!0})},[]),C.useEffect(()=>{if(n!=="ready"||e)return;const H=setInterval(()=>{if(x){Xw().then(pe=>{pe.authRequired&&!pe.user&&(Xe(!0),u(null),f(null),i("account-login"))}).catch(()=>{});return}Yw().then(pe=>{pe.authenticated||(Xe(!0),f(null),i(pe.setupRequired?"setup":"login"))}).catch(()=>{})},TW);return Zw(()=>{Xe(!0),u(null),f(null),v(!1),i(x?"account-login":"login")}),()=>{clearInterval(H),Zw(null)}},[n,x,e]);const q=async H=>{if(H.preventDefault(),!N.trim()||N.trim().length<8){ae("Password must be at least 8 characters");return}if(N!==P){ae("Passwords do not match");return}Y(!0),ae(null);try{if(!(await oK(N.trim())).authenticated){ae("Setup failed");return}I(""),E(""),ee(!1),Xe(!1),f(null),v(!0),i("checking");try{const ze=await kf();f(ze),v(!1),i("ready")}catch(ze){ae(ze instanceof Error?ze.message:"Could not verify API key access"),i("api-key-error")}}catch(pe){ae(pe instanceof Sn||pe instanceof Error?pe.message:"Setup failed")}finally{Y(!1)}},X=H=>{I(H),ae(null)},ve=H=>{E(H),ae(null)},ke=async H=>{if(H.preventDefault(),!!N.trim()){Y(!0),ae(null);try{if(!(L==="api-key"?await lK(N.trim()):await rK(N.trim())).authenticated){ae(L==="api-key"?"Invalid API key":"Incorrect password");return}const ze=await kf();f(ze),v(!1),I(""),ee(!1),Xe(!1),i("ready")}catch(pe){ae(pe instanceof Sn||pe instanceof Error?pe.message:"Authentication failed")}finally{Y(!1)}}},J=H=>{F(H),I(""),ee(!1),ae(null)},Ne=async H=>{if(H.preventDefault(),!(!k.trim()||!N)){Y(!0),ae(null);try{const pe=await uK(k.trim(),N);if(!pe.user){ae("Incorrect name or password.");return}I(""),Xe(!1),u(pe.user),f(null),v(!1),i("ready")}catch(pe){ae(pe instanceof Sn?pe.message:"Incorrect name or password.")}finally{Y(!1)}}};if(n==="ready"){const{queryClient:H,router:pe}=Se();return l.jsx(RK,{account:r,apiKey:h,apiKeyPending:b,children:l.jsx(p5,{client:H,children:l.jsx(h5,{router:pe})})})}const Me=N.trim(),xe=N.length>0&&Me.length<8,le=P.length>0&&N!==P,re=Me.length>=8&&N===P;return l.jsx("div",{className:"min-h-screen bg-bg px-4 py-8",children:l.jsxs("div",{className:"mx-auto flex min-h-[calc(100vh-4rem)] max-w-md flex-col items-center justify-center gap-5",children:[l.jsxs("div",{"data-testid":"auth-brand",className:"flex items-center gap-2.5",children:[l.jsx("img",{className:"size-7",src:"./favicon.svg",alt:"","aria-hidden":"true"}),l.jsx("span",{className:"text-lg font-semibold tracking-tight text-heading",children:"Canonry"})]}),l.jsx(Ra,{className:"surface-card w-full",children:n==="checking"?l.jsx(xo,{className:"py-8",children:l.jsx("p",{className:"supporting-copy text-center",children:"Connecting to Canonry…"})}):n==="api-key-error"?l.jsxs(l.Fragment,{children:[l.jsxs(Er,{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Dashboard access"}),l.jsx("h1",{className:"font-medium tracking-tight text-primary",children:"Could not verify API key access"})]}),l.jsxs(xo,{className:"space-y-4",children:[l.jsx("p",{className:"supporting-copy",children:Z??"Canonry could not verify this session’s access, so the dashboard stayed locked."}),l.jsx(ce,{type:"button",className:"w-full",onClick:()=>{window.location.reload()},children:"Try again"})]})]}):n==="account-login"?l.jsxs(l.Fragment,{children:[l.jsxs(Er,{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Dashboard access"}),l.jsx("h1",{className:"font-medium tracking-tight text-primary",children:"Sign in to Canonry"})]}),l.jsxs(xo,{children:[ue?l.jsx("p",{className:"mb-4 rounded-md border border-caution bg-caution-soft px-3 py-2 text-sm text-caution",children:"You were signed out — please sign in again."}):null,l.jsxs("form",{className:"space-y-4",onSubmit:hn(Ne),children:[l.jsxs("label",{className:"block space-y-1.5",htmlFor:"account-name",children:[l.jsx("span",{className:"text-xs font-medium text-secondary",children:"Name"}),l.jsx("input",{autoFocus:!0,id:"account-name",className:"w-full rounded-md border border-base bg-bg px-3 py-2 text-sm text-heading outline-none transition focus:border-mono-600",type:"text",name:"username",autoComplete:"username",value:k,onChange:H=>{T(H.target.value),ae(null)},"aria-invalid":!!Z,"aria-describedby":Z?"account-login-error":void 0})]}),l.jsxs("label",{className:"block space-y-1.5",htmlFor:"account-password",children:[l.jsx("span",{className:"text-xs font-medium text-secondary",children:"Password"}),l.jsx("input",{id:"account-password",className:"w-full rounded-md border border-base bg-bg px-3 py-2 text-sm text-heading outline-none transition focus:border-mono-600",type:"password",name:"password",autoComplete:"current-password",value:N,onChange:H=>X(H.target.value),"aria-invalid":!!Z,"aria-describedby":Z?"account-login-error":void 0})]}),Z?l.jsx("p",{id:"account-login-error",role:"alert",className:"text-sm text-negative-400",children:Z}):null,l.jsx(ce,{type:"submit",disabled:M||!k.trim()||!N,children:M?"Signing in…":"Sign in"})]})]})]}):n==="setup"?l.jsxs(l.Fragment,{children:[l.jsxs(Er,{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"First-time setup"}),l.jsx("h1",{className:"font-medium tracking-tight text-primary",children:"Create a dashboard password"}),l.jsx(Wd,{children:"This password protects the dashboard on this computer."})]}),l.jsx(xo,{children:l.jsxs("form",{className:"space-y-4",onSubmit:hn(q),children:[l.jsxs("div",{className:"space-y-1.5",children:[l.jsx("label",{className:"block text-xs font-medium text-secondary",htmlFor:"dashboard-password-new",children:"Password"}),l.jsx("input",{autoFocus:!0,id:"dashboard-password-new",className:"w-full rounded-md border border-base bg-bg px-3 py-2 text-sm text-heading outline-none transition focus:border-mono-600",type:$?"text":"password",name:"new-password",autoComplete:"new-password",minLength:8,required:!0,value:N,onChange:H=>X(H.target.value),"aria-invalid":xe,"aria-describedby":"dashboard-password-new-help"}),l.jsx("span",{id:"dashboard-password-new-help","aria-live":"polite",className:xe?"block text-sm text-negative-400":"block text-sm text-secondary",children:xe?"Enter at least 8 characters.":"Use at least 8 characters."})]}),l.jsxs("div",{className:"space-y-1.5",children:[l.jsx("label",{className:"block text-xs font-medium text-secondary",htmlFor:"dashboard-password-confirm",children:"Confirm password"}),l.jsx("input",{id:"dashboard-password-confirm",className:"w-full rounded-md border border-base bg-bg px-3 py-2 text-sm text-heading outline-none transition focus:border-mono-600",type:$?"text":"password",name:"confirm-password",autoComplete:"new-password",minLength:8,required:!0,value:P,onChange:H=>ve(H.target.value),"aria-invalid":le,"aria-describedby":"dashboard-password-confirm-help"}),l.jsx("span",{id:"dashboard-password-confirm-help","aria-live":"polite",className:le?"block text-sm text-negative-400":"block text-sm text-secondary",children:le?"Passwords do not match.":"Enter the same password again."})]}),l.jsxs("label",{className:"flex min-h-10 cursor-pointer items-center gap-2 text-sm text-secondary",htmlFor:"dashboard-password-show",children:[l.jsx("input",{id:"dashboard-password-show",type:"checkbox",checked:$,onChange:H=>ee(H.target.checked)}),"Show passwords"]}),Z?l.jsx("p",{id:"dashboard-password-setup-error",role:"alert",className:"text-sm text-negative-400",children:Z}):null,l.jsx(ce,{type:"submit",disabled:M||!re,children:M?"Creating password…":"Create password and continue"})]})})]}):l.jsxs(l.Fragment,{children:[l.jsxs(Er,{children:[l.jsx("p",{className:"eyebrow eyebrow-soft",children:"Dashboard access"}),l.jsx("h1",{className:"font-medium tracking-tight text-primary",children:"Sign in to Canonry"}),l.jsx(Wd,{children:L==="api-key"?"Enter an API key from this Canonry install. This opens the dashboard with that key’s access and does not change the password.":"Enter your dashboard password to continue."})]}),l.jsxs(xo,{children:[ue?l.jsx("p",{className:"mb-4 rounded-md border border-caution bg-caution-soft px-3 py-2 text-sm text-caution",children:"Your session expired — please sign in again."}):null,l.jsxs("form",{className:"space-y-4",onSubmit:hn(ke),children:[l.jsxs("label",{className:"block space-y-1.5",htmlFor:"dashboard-password-current",children:[l.jsx("span",{className:"text-xs font-medium text-secondary",children:L==="api-key"?"Canonry API key":"Password"}),l.jsx("input",{autoFocus:!0,id:"dashboard-password-current",className:"w-full rounded-md border border-base bg-bg px-3 py-2 text-sm text-heading outline-none transition focus:border-mono-600",type:$?"text":"password",name:L==="api-key"?"apiKey":"password",autoComplete:L==="api-key"?"off":"current-password",spellCheck:!1,required:!0,value:N,onChange:H=>X(H.target.value),"aria-invalid":!!Z,"aria-describedby":Z?"dashboard-password-login-error":void 0})]}),l.jsxs("label",{className:"flex min-h-10 cursor-pointer items-center gap-2 text-sm text-secondary",htmlFor:"dashboard-login-password-show",children:[l.jsx("input",{id:"dashboard-login-password-show",type:"checkbox",checked:$,onChange:H=>ee(H.target.checked)}),L==="api-key"?"Show API key":"Show password"]}),Z?l.jsx("p",{id:"dashboard-password-login-error",role:"alert",className:"text-sm text-negative-400",children:Z}):null,l.jsx(ce,{type:"submit",disabled:M||!N.trim(),children:M?"Signing in…":"Open dashboard"}),l.jsx(ce,{type:"button",variant:"ghost",onClick:()=>J(L==="api-key"?"password":"api-key"),children:L==="api-key"?"Use dashboard password instead":"Forgot password? Use API key"})]})]})]})})]})})}const n4=document.getElementById("root");if(!n4)throw new Error("Expected #root element for web app bootstrap.");U5.createRoot(n4).render(l.jsx(C.StrictMode,{children:l.jsx(EW,{})}));export{gie as $,hn as A,ce as B,fc as C,Pie as D,Lie as E,Bie as F,Gne as G,Hne as H,Ea as I,Kne as J,fa as K,HK as L,use as M,_se as N,Tse as O,iZ as P,WK as Q,xt as R,hX as S,xn as T,pee as U,hae as V,yae as W,fne as X,mae as Y,hie as Z,yie as _,cse as a,Pee as a$,jne as a0,kne as a1,Ine as a2,kn as a3,xie as a4,wie as a5,Tne as a6,Sie as a7,Ene as a8,Cne as a9,Sn as aA,cae as aB,one as aC,QK as aD,aF as aE,rg as aF,uae as aG,Td as aH,Uie as aI,bg as aJ,vo as aK,YK as aL,Zt as aM,MK as aN,Tae as aO,aY as aP,Nne as aQ,vee as aR,Dj as aS,Oi as aT,Sse as aU,kse as aV,mee as aW,ane as aX,iO as aY,Dn as aZ,dee as a_,_ne as aa,bie as ab,vie as ac,fie as ad,Ane as ae,kie as af,Eie as ag,Cie as ah,_ie as ai,Nie as aj,Tie as ak,Jne as al,d1 as am,Re as an,Aie as ao,pC as ap,Vi as aq,jie as ar,Sg as as,I9 as at,O9 as au,cee as av,lee as aw,tae as ax,rae as ay,lae as az,JK as b,VW as b$,uee as b0,cH as b1,RH as b2,Oae as b3,Lae as b4,qae as b5,Jee as b6,ete as b7,rU as b8,tte as b9,Zae as bA,aie as bB,iie as bC,sie as bD,Fae as bE,nie as bF,Yae as bG,oie as bH,Xae as bI,rie as bJ,eie as bK,cie as bL,mie as bM,KX as bN,Jae as bO,he as bP,aee as bQ,nee as bR,tee as bS,eee as bT,XW as bU,YW as bV,WW as bW,JW as bX,ZW as bY,FW as bZ,$W as b_,xH as ba,Iae as bb,cU as bc,ig as bd,Wee as be,VG as bf,Pae as bg,zae as bh,SH as bi,Mae as bj,yse as bk,Bae as bl,Fie as bm,Zie as bn,Rne as bo,c1 as bp,Vie as bq,lC as br,Kae as bs,Qae as bt,tie as bu,die as bv,uie as bw,Wae as bx,lie as by,pie as bz,ree as c,Fte as c$,QW as c0,HW as c1,KW as c2,UW as c3,GW as c4,LW as c5,BW as c6,MW as c7,PW as c8,h6 as c9,_te as cA,S$ as cB,Ree as cC,Gw as cD,tne as cE,Fee as cF,Hee as cG,rte as cH,yG as cI,Jte as cJ,Wte as cK,Xte as cL,Yte as cM,Mte as cN,Pte as cO,Ote as cP,qte as cQ,Qee as cR,zte as cS,Dte as cT,wte as cU,Ste as cV,Gee as cW,Zee as cX,kte as cY,Lte as cZ,hee as c_,qee as ca,Bee as cb,zee as cc,Lee as cd,Mee as ce,Iee as cf,Oee as cg,Uee as ch,Rse as ci,$ie as cj,og as ck,$ee as cl,ate as cm,ite as cn,jo as co,nte as cp,Vee as cq,Vne as cr,zt as cs,_V as ct,Tte as cu,nne as cv,jte as cw,Ate as cx,Cte as cy,Nte as cz,XK as d,Sae as d$,Zte as d0,Gte as d1,Hte as d2,fee as d3,Qte as d4,Kte as d5,Eee as d6,Tee as d7,Ete as d8,fte as d9,yee as dA,pte as dB,Rte as dC,see as dD,Ite as dE,hte as dF,pne as dG,mne as dH,dne as dI,Une as dJ,IH as dK,Hae as dL,xae as dM,bee as dN,aS as dO,yne as dP,bne as dQ,bae as dR,vae as dS,vne as dT,xne as dU,Sne as dV,wne as dW,Qc as dX,qo as dY,FA as dZ,kae as d_,gte as da,yte as db,bte as dc,vte as dd,xte as de,SG as df,ene as dg,Dee as dh,iee as di,k$ as dj,cte as dk,Bte as dl,oee as dm,Kee as dn,ste as dp,lte as dq,ote as dr,gee as ds,$te as dt,Vte as du,Ute as dv,dte as dw,LA as dx,ute as dy,mte as dz,jse as e,Pm as e$,$Z as e0,hg as e1,Yd as e2,fg as e3,Xd as e4,Jd as e5,nY as e6,pH as e7,wo as e8,am as e9,gse as eA,bse as eB,vse as eC,wse as eD,une as eE,_s as eF,lH as eG,mH as eH,hne as eI,WF as eJ,Rie as eK,hK as eL,Bne as eM,zie as eN,Iie as eO,Oie as eP,Die as eQ,fae as eR,One as eS,qne as eT,Pne as eU,Lne as eV,Mne as eW,h1 as eX,Gr as eY,zm as eZ,Nse as e_,MH as ea,tJ as eb,Ese as ec,fse as ed,eY as ee,hse as ef,ZX as eg,$ae as eh,jae as ei,pse as ej,_ae as ek,Aae as el,Z9 as em,V9 as en,Vae as eo,mse as ep,Cae as eq,ose as er,cY as es,WG as et,nH as eu,uY as ev,lne as ew,cne as ex,rne as ey,nK as ez,sn as f,sse as f$,Uae as f0,Gae as f1,HG as f2,ine as f3,sne as f4,gne as f5,Dne as f6,zne as f7,b1 as f8,Mm as f9,Kie as fA,pae as fB,gI as fC,Eae as fD,Nae as fE,Dae as fF,Rae as fG,gS as fH,See as fI,Gi as fJ,Pa as fK,wee as fL,$G as fM,RQ as fN,Xie as fO,Yie as fP,YX as fQ,ese as fR,oY as fS,_ee as fT,kee as fU,rse as fV,lse as fW,Jie as fX,Wie as fY,xee as fZ,nse as f_,f1 as fa,eJ as fb,$ne as fc,Kr as fd,sS as fe,Wne as ff,nae as fg,iae as fh,sae as fi,eae as fj,aae as fk,oae as fl,Sf as fm,Xne as fn,Hie as fo,DX as fp,Xee as fq,F0 as fr,wae as fs,Gie as ft,Qie as fu,Yne as fv,Yee as fw,Fne as fx,Zne as fy,Qne as fz,xse as g,tse as g0,ise as g1,_o as g2,p3 as g3,jee as g4,Nee as g5,ase as g6,oB as g7,Cee as g8,Aee as g9,Ase as h,Cse as i,gg as j,Ic as k,Qg as l,dse as m,O$ as n,dae as o,qie as p,Mie as q,Ra as r,gae as s,ZK as t,g1 as u,Un as v,W as w,ZA as x,zr as y,Pn as z};
|