argus-review 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,169 @@
1
+ var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},l=(n,r,o)=>(o=n==null?{}:e(i(n)),c(r||!n||!n.__esModule||!a.call(n,`default`)?t(o,`default`,{value:n,enumerable:!0}):o,n));(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var u=o((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.for(`react.view_transition`),m=Symbol.iterator;function h(e){return typeof e!=`object`||!e?null:(e=m&&e[m]||e[`@@iterator`],typeof e==`function`?e:null)}var g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,v={};function y(e,t,n){this.props=e,this.context=t,this.refs=v,this.updater=n||g}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function b(){}b.prototype=y.prototype;function x(e,t,n){this.props=e,this.context=t,this.refs=v,this.updater=n||g}var ee=x.prototype=new b;ee.constructor=x,_(ee,y.prototype),ee.isPureReactComponent=!0;var te=Array.isArray;function ne(){}var S={H:null,A:null,T:null,S:null},re=Object.prototype.hasOwnProperty;function C(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function ie(e,t){return C(e.type,t,e.props)}function ae(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function oe(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var w=/\/+/g;function se(e,t){return typeof e==`object`&&e&&e.key!=null?oe(``+e.key):t.toString(36)}function ce(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(ne,ne):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function le(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,le(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+se(e,0):a,te(o)?(i=``,c!=null&&(i=c.replace(w,`$&/`)+`/`),le(o,r,i,``,function(e){return e})):o!=null&&(ae(o)&&(o=ie(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(w,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(te(e))for(var u=0;u<e.length;u++)a=e[u],s=l+se(a,u),c+=le(a,r,i,s,o);else if(u=h(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+se(a,u++),c+=le(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return le(ce(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function ue(e,t,n){if(e==null)return e;var r=[],i=0;return le(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function de(e){if(e._status===-1){var t=e._result,n=t();n.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t,n.status===void 0&&(n.status=`fulfilled`,n.value=t))},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t,n.status===void 0&&(n.status=`rejected`,n.reason=t))}),e._status===-1&&(e._status=0,e._result=n)}if(e._status===1)return e._result.default;throw e._result}var fe=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)};function pe(e){var t=S.T,n={};n.types=t===null?null:t.types,S.T=n;try{var r=e(),i=S.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(ne,fe)}catch(e){fe(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),S.T=t}}function me(e){var t=S.T;if(t!==null){var n=t.types;n===null?t.types=[e]:n.indexOf(e)===-1&&n.push(e)}else pe(me.bind(null,e))}var he={map:ue,forEach:function(e,t,n){ue(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return ue(e,function(){t++}),t},toArray:function(e){return ue(e,function(e){return e})||[]},only:function(e){if(!ae(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=he,e.Component=y,e.Fragment=r,e.Profiler=a,e.PureComponent=x,e.StrictMode=i,e.Suspense=l,e.ViewTransition=p,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=S,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return S.H.useMemoCache(e)}},e.addTransitionType=me,e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=_({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!re.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return C(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)re.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return C(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=ae,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:de}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=pe,e.unstable_useCacheRefresh=function(){return S.H.useCacheRefresh()},e.use=function(e){return S.H.use(e)},e.useActionState=function(e,t,n){return S.H.useActionState(e,t,n)},e.useCallback=function(e,t){return S.H.useCallback(e,t)},e.useContext=function(e){return S.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return S.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return S.H.useEffect(e,t)},e.useEffectEvent=function(e){return S.H.useEffectEvent(e)},e.useId=function(){return S.H.useId()},e.useImperativeHandle=function(e,t,n){return S.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return S.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return S.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return S.H.useMemo(e,t)},e.useOptimistic=function(e,t){return S.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return S.H.useReducer(e,t,n)},e.useRef=function(e){return S.H.useRef(e)},e.useState=function(e){return S.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return S.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return S.H.useTransition()},e.version=`19.3.0`})),d=o(((e,t)=>{t.exports=u()})),f=o((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,ee||(ee=!0,ie());else{var t=n(l);t!==null&&w(x,t.startTime-e)}}}var ee=!1,te=-1,ne=5,S=-1;function re(){return g?!0:!(e.unstable_now()-S<ne)}function C(){if(g=!1,ee){var t=e.unstable_now();S=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(te),te=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&re());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&w(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?ie():ee=!1}}}var ie;if(typeof y==`function`)ie=function(){y(C)};else if(typeof MessageChannel<`u`){var ae=new MessageChannel,oe=ae.port2;ae.port1.onmessage=C,ie=function(){oe.postMessage(null)}}else ie=function(){_(C,0)};function w(t,n){te=_(function(){t(e.unstable_now())},n)}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(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):ne=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(te),te=-1):h=!0,w(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,ee||(ee=!0,ie()))),r},e.unstable_shouldYield=re,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),p=o(((e,t)=>{t.exports=f()})),m=o((e=>{var t=d();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},a=Symbol.for(`react.portal`),o=Symbol.for(`react.recoverable`),s=Symbol.for(`react.optimistic_key`);function c(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:r==null?null:r===s?s:``+r,children:e,containerInfo:t,implementation:n}}var l=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function u(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.browser=function(e){return{$$typeof:o,_reason:e}},e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return c(e,t,null,r)},e.flushSync=function(e){var t=l.T,n=i.p;try{if(l.T=null,i.p=2,e)return e()}finally{l.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=u(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`){if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=u(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0})}}else t??i.d.M(e)}},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=u(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`){if(t){var n=u(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0})}else i.d.m(e)}},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return l.H.useFormState(e,t,n)},e.useFormStatus=function(){return l.H.useHostTransitionStatus()},e.version=`19.3.0`})),h=o(((e,t)=>{function n(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE==`function`)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=m()})),g=o((e=>{var t=p(),n=d(),r=h();function i(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function a(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function o(e){for(var t=e,n=t;n&&!n.alternate;)t=n,t.flags&4098&&(e=t.return),n=t.return;for(;t.return;)t=t.return;return t.tag===3?e:null}function s(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function c(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(o(e)!==e)throw Error(i(188))}function u(e){var t=e.alternate;if(!t){if(t=o(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var s=a.alternate;if(s===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===s.child){for(s=a.child;s;){if(s===n)return l(a),e;if(s===r)return l(a),t;s=s.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=s;else{for(var c=!1,u=a.child;u;){if(u===n){c=!0,n=a,r=s;break}if(u===r){c=!0,r=a,n=s;break}u=u.sibling}if(!c){for(u=s.child;u;){if(u===n){c=!0,n=s,r=a;break}if(u===r){c=!0,r=s,n=a;break}u=u.sibling}if(!c)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function f(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=f(e),t!==null)return t;e=e.sibling}return null}function m(e,t,n,r,i,a){for(;e!==null;){if((e.tag===5||e.tag===27||e.tag===6)&&n(e,r,i,a)||(e.tag!==22||e.memoizedState===null)&&(t||e.tag!==5&&e.tag!==27)&&m(e.child,t,n,r,i,a))return!0;e=e.sibling}return!1}function g(e){for(e=e.return;e!==null;){if(e.tag===3||e.tag===5||e.tag===27)return e;e=e.return}return null}function _(e){var t=!1;for(e=e.return;e!==null&&(e.tag===4&&(t=!0),e.tag!==3&&e.tag!==5&&e.tag!==27);)e=e.return;return t}function v(e){var t=[null,null],n=g(e);return n===null||y(t,e,n.child,{foundSelf:!1}),t}function y(e,t,n,r){for(;n!==null;){if(n===t)r.foundSelf=!0;else if(n.tag===5||n.tag===27||n.tag===6){if(r.foundSelf)return e[1]=n,!0;e[0]=n}else if((n.tag!==22||n.memoizedState===null)&&y(e,t,n.child,r))return!0;n=n.sibling}return!1}function b(e){switch(e.tag){case 5:case 27:case 6:return e.stateNode;case 3:return e.stateNode.containerInfo;default:throw Error(i(559))}}var x=null,ee=null;function te(e,t,n){return e===n||e===t&&(x=e,!0)}function ne(e,t,n){return e===n?(ee=e,!1):e===t&&(ee!==null&&(x=e),!0)}function S(e){if(e===null)return null;do e=e===null?null:e.return;while(e&&e.tag!==5&&e.tag!==27&&e.tag!==3);return e||null}function re(e,t,n){for(var r=0,i=e;i;i=n(i))r++;i=0;for(var a=t;a;a=n(a))i++;for(;0<r-i;)e=n(e),r--;for(;0<i-r;)t=n(t),i--;for(;r--;){if(e===t||t!==null&&e===t.alternate)return e;e=n(e),t=n(t)}return null}var C=Object.assign,ie=Symbol.for(`react.element`),ae=Symbol.for(`react.transitional.element`),oe=Symbol.for(`react.portal`),w=Symbol.for(`react.fragment`),se=Symbol.for(`react.strict_mode`),ce=Symbol.for(`react.profiler`),le=Symbol.for(`react.consumer`),ue=Symbol.for(`react.context`),de=Symbol.for(`react.forward_ref`),fe=Symbol.for(`react.suspense`),pe=Symbol.for(`react.suspense_list`),me=Symbol.for(`react.memo`),he=Symbol.for(`react.lazy`),ge=Symbol.for(`react.activity`),_e=Symbol.for(`react.legacy_hidden`),ve=Symbol.for(`react.memo_cache_sentinel`),ye=Symbol.for(`react.view_transition`),be=Symbol.for(`react.recoverable`),xe=Symbol.iterator;function Se(e){return typeof e!=`object`||!e?null:(e=xe&&e[xe]||e[`@@iterator`],typeof e==`function`?e:null)}var Ce=Symbol.for(`react.client.reference`);function we(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===Ce?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case w:return`Fragment`;case ce:return`Profiler`;case se:return`StrictMode`;case fe:return`Suspense`;case pe:return`SuspenseList`;case ge:return`Activity`;case ye:return`ViewTransition`}if(typeof e==`object`)switch(e.$$typeof){case oe:return`Portal`;case ue:return e.displayName||`Context`;case le:return(e._context.displayName||`Context`)+`.Consumer`;case de:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case me:return t=e.displayName||null,t===null?we(e.type)||`Memo`:t;case he:t=e._payload,e=e._init;try{return we(e(t))}catch{}}return null}var Te=Array.isArray,T=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,E=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Ee={pending:!1,data:null,method:null,action:null},De=[],Oe=-1;function ke(e){return{current:e}}function Ae(e){0>Oe||(e.current=De[Oe],De[Oe]=null,Oe--)}function D(e,t){Oe++,De[Oe]=e.current,e.current=t}var je=ke(null),Me=ke(null),Ne=ke(null),Pe=ke(null);function Fe(e,t){switch(D(Ne,t),D(Me,e),D(je,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?up(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=up(t),e=dp(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}Ae(je),D(je,e)}function Ie(){Ae(je),Ae(Me),Ae(Ne)}function Le(e){var t=e.memoizedState;t!==null&&(sh._currentValue=t.memoizedState,D(Pe,e)),t=je.current;var n=dp(t,e.type);t!==n&&(D(Me,e),D(je,n))}function Re(e){Me.current===e&&(Ae(je),Ae(Me)),Pe.current===e&&(Ae(Pe),sh._currentValue=Ee)}var ze,Be;function Ve(e){if(ze===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);ze=t&&t[1]||``,Be=-1<e.stack.indexOf(`
2
+ at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
3
+ `+ze+e+Be}var He=!1;function Ue(e,t){if(!e||He)return``;He=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}n=!1;try{var i=Object.getOwnPropertyDescriptor(e.prototype,`props`);Object.defineProperty(e.prototype,"props",{configurable:!0,set:function(){throw Error()}}),n=!0,new e}finally{n&&(i===void 0?delete e.prototype.props:Object.defineProperty(e.prototype,"props",i))}}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
4
+ `),l=s.split(`
5
+ `);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
6
+ `+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{He=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?Ve(n):``}function We(e,t){switch(e.tag){case 26:case 27:case 5:return Ve(e.type);case 16:return Ve(`Lazy`);case 13:return e.child!==t&&t!==null?Ve(`Suspense Fallback`):Ve(`Suspense`);case 19:return Ve(`SuspenseList`);case 0:case 15:return Ue(e.type,!1);case 11:return Ue(e.type.render,!1);case 1:return Ue(e.type,!0);case 31:return Ve(`Activity`);case 30:return Ve(`ViewTransition`);default:return``}}function Ge(e){try{var t=``,n=null;do t+=We(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
7
+ Error generating stack: `+e.message+`
8
+ `+e.stack}}var Ke=Object.prototype.hasOwnProperty,qe=t.unstable_scheduleCallback,Je=t.unstable_cancelCallback,Ye=t.unstable_shouldYield,Xe=t.unstable_requestPaint,Ze=t.unstable_now,Qe=t.unstable_getCurrentPriorityLevel,$e=t.unstable_ImmediatePriority,et=t.unstable_UserBlockingPriority,tt=t.unstable_NormalPriority,nt=t.unstable_LowPriority,rt=t.unstable_IdlePriority,it=t.log,at=t.unstable_setDisableYieldValue,ot=null,st=null;function ct(e){if(typeof it==`function`&&at(e),st&&typeof st.setStrictMode==`function`)try{st.setStrictMode(ot,e)}catch{}}var lt=Math.clz32?Math.clz32:ft,ut=Math.log,dt=Math.LN2;function ft(e){return e>>>=0,e===0?32:31-(ut(e)/dt|0)|0}var pt=256,mt=262144,ht=4194304;function gt(e){var t=e&42;if(t!==0)return t;switch(e&-e){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 e&-e;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function _t(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=gt(n))):i=gt(o):i=gt(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=gt(n))):i=gt(o)):i=gt(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function vt(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function yt(e,t){t&8&&(t|=t&32);var n=e.entangledLanes;if(n!==0)for(e=e.entanglements,n&=t;0<n;){var r=31-lt(n),i=1<<r;t|=e[r],n&=~i}return t}function bt(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+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 t+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 xt(){var e=ht;return ht<<=1,!(ht&62914560)&&(ht=4194304),e}function St(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ct(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function wt(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-lt(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&Tt(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function Tt(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-lt(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Et(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-lt(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function Dt(e,t){var n=t&-t;return n=n&42?1:Ot(n),(n&(e.suspendedLanes|t))===0?n:0}function Ot(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=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:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function kt(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function At(){var e=E.p;return e===0?(e=window.event,e===void 0?32:Ch(e.type)):e}function jt(e,t){var n=E.p;try{return E.p=e,t()}finally{E.p=n}}var Mt=Math.random().toString(36).slice(2),Nt=`__reactFiber$`+Mt,Pt=`__reactProps$`+Mt,Ft=`__reactContainer$`+Mt,It=`__reactEvents$`+Mt,Lt=`__reactListeners$`+Mt,Rt=`__reactHandles$`+Mt,zt=`__reactResources$`+Mt,Bt=`__reactMarker$`+Mt,Vt=`__reactLoad$`+Mt;function Ht(e){delete e[Nt],delete e[Pt],delete e[Lt],delete e[Rt]}function Ut(e){var t;if(t=e[Nt])return t;for(var n=e.parentNode;n;){if(t=n[Ft]||n[Nt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=fm(e);e!==null;){if(n=e[Nt])return n;e=fm(e)}return t}e=n,n=e.parentNode}return null}function Wt(e){if(e=e[Nt]||e[Ft]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function Gt(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function Kt(e){var t=e[zt];return t||=e[zt]={hoistableStyles:new Map,hoistableScripts:new Map},t}function qt(e){e[Bt]=!0}function Jt(e){e[Vt]=void 0}var Yt=new Set,Xt={};function Zt(e,t){Qt(e,t),Qt(e+`Capture`,t)}function Qt(e,t){for(Xt[e]=t,e=0;e<t.length;e++)Yt.add(t[e])}var $t=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]*$`),en={},tn={};function nn(e){return Ke.call(tn,e)?!0:Ke.call(en,e)?!1:$t.test(e)?tn[e]=!0:(en[e]=!0,!1)}var O=!1;function rn(){var e=O;return O=!1,e}function an(e,t,n){if(nn(t)){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,n)}}}function on(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,n)}}function sn(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,r)}}function cn(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function ln(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function un(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function dn(e){if(!e._valueTracker){var t=ln(e)?`checked`:`value`;e._valueTracker=un(e,t,``+e[t])}}function fn(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=ln(e)?e.checked?`true`:`false`:e.value),e=r,e!==n&&(t.setValue(e),!0)}var pn=/[\n"\\]/g;function mn(e){return e.replace(pn,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function hn(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+cn(t)):e.value!==``+cn(t)&&(e.value=``+cn(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):_n(e,cn(n)):o===`number`&&e.value==t?_n(e,cn(e.value)):_n(e,cn(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+cn(s):e.removeAttribute(`name`)}function gn(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){dn(e);return}n=n==null?``:``+cn(n),t=t==null?n:``+cn(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),dn(e)}function _n(e,t){e.defaultValue!==``+t&&(e.defaultValue=``+t)}function vn(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+cn(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function yn(e,t,n){if(t!=null&&(t=``+cn(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+cn(n)}function bn(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(i(92));if(Te(r)){if(1<r.length)throw Error(i(93));r=r[0]}n=r}n??=``,t=n}n=cn(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),dn(e)}function xn(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Sn=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 Cn(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Sn.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function wn(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(i(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``,O=!0);for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&(Cn(e,a,r),O=!0)}else for(var o in t)t.hasOwnProperty(o)&&Cn(e,o,t[o])}function Tn(e){if(e.indexOf(`-`)===-1)return!1;switch(e){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 En=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`],[`maskType`,`mask-type`],[`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`]]),Dn=/^[\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 On(e){return Dn.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function kn(){}var An=null;function jn(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Mn=null,Nn=null;function Pn(e){var t=Wt(e);if(t&&(e=t.stateNode)){var n=e[Pt]||null;a:switch(e=t.stateNode,t.type){case`input`:if(hn(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+mn(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[Pt]||null;if(!a)throw Error(i(90));hn(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&fn(r)}break a;case`textarea`:yn(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&vn(e,!!n.multiple,t,!1)}}}var Fn=!1;function In(e,t,n){if(Fn)return e(t,n);Fn=!0;try{return e(t)}finally{if(Fn=!1,(Mn!==null||Nn!==null)&&(zd(),Mn&&(t=Mn,e=Nn,Nn=Mn=null,Pn(t),e)))for(t=0;t<e.length;t++)Pn(e[t])}}function Ln(e,t){var n=e.stateNode;if(n===null)return null;var r=n[Pt]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=e!==`button`&&e!==`input`&&e!==`select`&&e!==`textarea`),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(i(231,t,typeof n));return n}var Rn=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0,zn=!1;if(Rn)try{var Bn={};Object.defineProperty(Bn,"passive",{get:function(){zn=!0}}),window.addEventListener(`test`,Bn,Bn),window.removeEventListener(`test`,Bn,Bn)}catch{zn=!1}var Vn=null,Hn=null,Un=null;function Wn(){if(Un)return Un;var e,t=Hn,n=t.length,r,i=`value`in Vn?Vn.value:Vn.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return Un=i.slice(e,1<r?1-r:void 0)}function Gn(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Kn(){return!0}function qn(){return!1}function Jn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?Kn:qn,this.isPropagationStopped=qn,this}return C(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=Kn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=Kn)},persist:function(){},isPersistent:Kn}),t}var Yn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Xn=Jn(Yn),Zn=C({},Yn,{view:0,detail:0}),Qn=Jn(Zn),$n,er,tr,nr=C({},Zn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:N,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==tr&&(tr&&e.type===`mousemove`?($n=e.screenX-tr.screenX,er=e.screenY-tr.screenY):er=$n=0,tr=e),$n)},movementY:function(e){return`movementY`in e?e.movementY:er}}),k=Jn(nr),A=Jn(C({},nr,{dataTransfer:0})),rr=Jn(C({},Zn,{relatedTarget:0})),j=Jn(C({},Yn,{animationName:0,elapsedTime:0,pseudoElement:0})),ir=Jn(C({},Yn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),ar=Jn(C({},Yn,{data:0})),M={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},or={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`},sr={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function cr(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=sr[e])?!!t[e]:!1}function N(){return cr}var lr=Jn(C({},Zn,{key:function(e){if(e.key){var t=M[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=Gn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?or[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:N,charCode:function(e){return e.type===`keypress`?Gn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?Gn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),P=Jn(C({},nr,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),ur=Jn(C({},Yn,{submitter:0})),dr=Jn(C({},Zn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:N})),fr=Jn(C({},Yn,{propertyName:0,elapsedTime:0,pseudoElement:0})),F=Jn(C({},nr,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),pr=Jn(C({},Yn,{newState:0,oldState:0,source:0})),mr=[9,13,27,32],hr=Rn&&`CompositionEvent`in window,gr=null;Rn&&`documentMode`in document&&(gr=document.documentMode);var _r=Rn&&`TextEvent`in window&&!gr,vr=Rn&&(!hr||gr&&8<gr&&11>=gr),yr=` `,br=!1;function xr(e,t){switch(e){case`keyup`:return mr.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Sr(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Cr=!1;function wr(e,t){switch(e){case`compositionend`:return Sr(t);case`keypress`:return t.which===32?(br=!0,yr):null;case`textInput`:return e=t.data,e===yr&&br?null:e;default:return null}}function Tr(e,t){if(Cr)return e===`compositionend`||!hr&&xr(e,t)?(e=Wn(),Un=Hn=Vn=null,Cr=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return vr&&t.locale!==`ko`?null:t.data;default:return null}}var Er={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 Dr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!Er[e.type]:t===`textarea`}function Or(e,t,n,r){Mn?Nn?Nn.push(r):Nn=[r]:Mn=r,t=Jf(t,`onChange`),0<t.length&&(n=new Xn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var kr=null,Ar=null;function jr(e){Vf(e,0)}function Mr(e){if(fn(Gt(e)))return e}function I(e,t){if(e===`change`)return t}var Nr=!1;if(Rn){var Pr;if(Rn){var Fr=`oninput`in document;if(!Fr){var Ir=document.createElement(`div`);Ir.setAttribute(`oninput`,`return;`),Fr=typeof Ir.oninput==`function`}Pr=Fr}else Pr=!1;Nr=Pr&&(!document.documentMode||9<document.documentMode)}function Lr(){kr&&(kr.detachEvent(`onpropertychange`,Rr),Ar=kr=null)}function Rr(e){if(e.propertyName===`value`&&Mr(Ar)){var t=[];Or(t,Ar,e,jn(e)),In(jr,t)}}function zr(e,t,n){e===`focusin`?(Lr(),kr=t,Ar=n,kr.attachEvent(`onpropertychange`,Rr)):e===`focusout`&&Lr()}function Br(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return Mr(Ar)}function Vr(e,t){if(e===`click`)return Mr(t)}function Hr(e,t){if(e===`input`||e===`change`)return Mr(t)}function Ur(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var Wr=typeof Object.is==`function`?Object.is:Ur;function Gr(e,t){if(Wr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!Ke.call(t,i)||!Wr(e[i],t[i]))return!1}return!0}function Kr(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}function qr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Jr(e,t){var n=qr(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=qr(n)}}function Yr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Yr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Xr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Kr(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Kr(e.document)}return t}function Zr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Qr=Rn&&`documentMode`in document&&11>=document.documentMode,$r=null,ei=null,ti=null,ni=!1;function ri(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;ni||$r==null||$r!==Kr(r)||(r=$r,`selectionStart`in r&&Zr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),ti&&Gr(ti,r)||(ti=r,r=Jf(ei,`onSelect`),0<r.length&&(t=new Xn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=$r)))}function ii(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var ai={animationend:ii(`Animation`,`AnimationEnd`),animationiteration:ii(`Animation`,`AnimationIteration`),animationstart:ii(`Animation`,`AnimationStart`),transitionrun:ii(`Transition`,`TransitionRun`),transitionstart:ii(`Transition`,`TransitionStart`),transitioncancel:ii(`Transition`,`TransitionCancel`),transitionend:ii(`Transition`,`TransitionEnd`)},oi={},si={};Rn&&(si=document.createElement(`div`).style,`AnimationEvent`in window||(delete ai.animationend.animation,delete ai.animationiteration.animation,delete ai.animationstart.animation),`TransitionEvent`in window||delete ai.transitionend.transition);function ci(e){if(oi[e])return oi[e];if(!ai[e])return e;var t=ai[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in si)return oi[e]=t[n];return e}var L=ci(`animationend`),li=ci(`animationiteration`),ui=ci(`animationstart`),di=ci(`transitionrun`),fi=ci(`transitionstart`),pi=ci(`transitioncancel`),mi=ci(`transitionend`),hi=new Map,gi=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error fullscreenChange fullscreenError 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(` `);gi.push(`scrollEnd`);function _i(e,t){hi.set(e,t),Zt(t,[e])}var vi=0;function yi(e,t){if(e.name!=null&&e.name!==`auto`)return e.name;if(t.autoName!==null)return t.autoName;e=bd.identifierPrefix;var n=vi++;return e=`_`+e+`t_`+n.toString(32)+`_`,t.autoName=e}function bi(e){if(e==null||typeof e==`string`)return e;var t=null,n=Od;if(n!==null)for(var r=0;r<n.length;r++){var i=e[n[r]];if(i!=null){if(i===`none`)return`none`;t=t==null?i:t+(` `+i)}}return t??e.default}function xi(e,t){return e=bi(e),t=bi(t),t==null?e===`auto`?null:e:t===`auto`?null:t}var Si=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},Ci=[],wi=0,Ti=0;function Ei(){for(var e=wi,t=Ti=wi=0;t<e;){var n=Ci[t];Ci[t++]=null;var r=Ci[t];Ci[t++]=null;var i=Ci[t];Ci[t++]=null;var a=Ci[t];if(Ci[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&Ai(n,i,a)}}function Di(e,t,n,r){Ci[wi++]=e,Ci[wi++]=t,Ci[wi++]=n,Ci[wi++]=r,Ti|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function Oi(e,t,n,r){return Di(e,t,n,r),ji(e)}function ki(e,t){return Di(e,null,null,t),ji(e)}function Ai(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-lt(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function ji(e){if(50<kd)throw kd=0,Ad=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var Mi={};function Ni(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Pi(e,t,n,r){return new Ni(e,t,n,r)}function Fi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function R(e,t){var n=e.alternate;return n===null?(n=Pi(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&1206910976,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function Ii(e,t){e.flags&=1206910978;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function Li(e,t,n,r,a,o){var s=0;if(r=e,typeof r==`function`)Fi(r)&&(s=1);else if(typeof r==`string`)s=qm(e,n,je.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(r){case ge:return e=Pi(31,n,t,a),e.elementType=ge,e.lanes=o,e;case w:return Ri(n.children,a,o,t);case se:s=8,a|=24;break;case ce:return e=Pi(12,n,t,a|2),e.elementType=ce,e.lanes=o,e;case fe:return e=Pi(13,n,t,a),e.elementType=fe,e.lanes=o,e;case pe:return e=Pi(19,n,t,a),e.elementType=pe,e.lanes=o,e;case _e:case ye:return e=a|32,e=Pi(30,n,t,e),e.elementType=ye,e.lanes=o,e.stateNode={autoName:null,paired:null,clones:null,ref:null},e;default:if(typeof r==`object`&&r)switch(r.$$typeof){case ue:s=10;break a;case le:s=9;break a;case de:s=11;break a;case me:s=14;break a;case he:s=16,r=null;break a}s=29,n=Error(i(130,e===null?`null`:typeof e,``)),r=null}return t=Pi(s,n,t,a),t.elementType=e,t.type=r,t.lanes=o,t}function Ri(e,t,n,r){return e=Pi(7,e,r,t),e.lanes=n,e}function zi(e,t,n){return e=Pi(6,e,null,t),e.lanes=n,e}function Bi(e){var t=Pi(18,null,null,0);return t.stateNode=e,t}function Vi(e,t,n){return t=Pi(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var Hi=new WeakMap;function Ui(e,t){if(typeof e==`object`&&e){var n=Hi.get(e);return n===void 0?(t={value:e,source:t,stack:Ge(t)},Hi.set(e,t),t):n}return{value:e,source:t,stack:Ge(t)}}var Wi=[],Gi=0,Ki=null,qi=0,Ji=[],Yi=0,Xi=null,Zi=1,Qi=``;function $i(e,t){Wi[Gi++]=qi,Wi[Gi++]=Ki,Ki=e,qi=t}function ea(e,t,n){Ji[Yi++]=Zi,Ji[Yi++]=Qi,Ji[Yi++]=Xi,Xi=e;var r=Zi;e=Qi;var i=32-lt(r)-1;r&=~(1<<i),n+=1;var a=32-lt(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,Zi=1<<32-lt(t)+i|n<<i|r,Qi=a+e}else Zi=1<<a|n<<i|r,Qi=e}function ta(e){e.return!==null&&($i(e,1),ea(e,1,0))}function na(e){for(;e===Ki;)Ki=Wi[--Gi],Wi[Gi]=null,qi=Wi[--Gi],Wi[Gi]=null;for(;e===Xi;)Xi=Ji[--Yi],Ji[Yi]=null,Qi=Ji[--Yi],Ji[Yi]=null,Zi=Ji[--Yi],Ji[Yi]=null}function ra(e,t){Ji[Yi++]=Zi,Ji[Yi++]=Qi,Ji[Yi++]=Xi,Zi=t.id,Qi=t.overflow,Xi=e}var z=null,B=null,V=!1,ia=null,aa=!1,oa=Error(i(519));function sa(e){throw pa(Ui(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),oa}function ca(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[Nt]=e,t[Pt]=r,n){case`dialog`:Q(`cancel`,t),Q(`close`,t);break;case`iframe`:case`object`:case`embed`:Q(`load`,t);break;case`video`:case`audio`:for(n=0;n<zf.length;n++)Q(zf[n],t);break;case`source`:Q(`error`,t);break;case`img`:case`image`:case`link`:Q(`error`,t),Q(`load`,t);break;case`details`:Q(`toggle`,t);break;case`input`:Q(`invalid`,t),gn(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:Q(`invalid`,t);break;case`textarea`:Q(`invalid`,t),bn(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||ep(t.textContent,n)?(r.popover!=null&&(Q(`beforetoggle`,t),Q(`toggle`,t)),r.onScroll!=null&&Q(`scroll`,t),r.onScrollEnd!=null&&Q(`scrollend`,t),r.onClick!=null&&(t.onclick=kn),t=!0):t=!1,t||sa(e,!0)}function la(e){for(z=e.return;z;)switch(z.tag){case 5:case 31:case 13:aa=!1;return;case 27:case 3:aa=!0;return;default:z=z.return}}function ua(e){if(e!==z)return!1;if(!V)return la(e),V=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=n===`form`||n===`button`||pp(e.type,e.memoizedProps)),n=!n),n&&B&&sa(e),la(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));B=dm(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));B=dm(e)}else t===27?(t=B,Sp(e.type)?(e=um,um=null,B=e):B=t):B=z?lm(e.stateNode.nextSibling):null;return!0}function da(){B=z=null,V=!1}function fa(){var e=ia;return e!==null&&(fd===null?fd=e:fd.push.apply(fd,e),ia=null),e}function pa(e){ia===null?ia=[e]:ia.push(e)}var ma=ke(null),ha=null,ga=null;function _a(e,t,n){D(ma,t._currentValue),t._currentValue=n}function va(e){e._currentValue=ma.current,Ae(ma)}function ya(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function ba(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),ya(o.return,n,e),r||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(i(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),ya(s,n,e),s=null}else a.tag===13&&a.memoizedState!==null&&a.memoizedState.dehydrated===null?(a.lanes|=n,s=a.alternate,s!==null&&(s.lanes|=n),ya(a.return,n,e),s=a.child,s=s===null?null:s.sibling):s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function xa(e,t,n,r){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(i(387));if(s=s.memoizedProps,s!==null){var c=a.type;Wr(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===Pe.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[sh]:e.push(sh))}a=a.return}return e!==null&&ba(t,e,n,r),t.flags|=262144,e!==null}function Sa(e){for(e=e.firstContext;e!==null;){if(!Wr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Ca(e){ha=e,ga=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function wa(e){return Ea(ha,e)}function Ta(e,t){return ha===null&&Ca(e),Ea(e,t)}function Ea(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},ga===null){if(e===null)throw Error(i(308));ga=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else ga=ga.next=t;return n}var Da=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},Oa=t.unstable_scheduleCallback,ka=t.unstable_NormalPriority,Aa={$$typeof:ue,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ja(){return{controller:new Da,data:new Map,refCount:0}}function Ma(e){e.refCount--,e.refCount===0&&Oa(ka,function(){e.controller.abort()})}function Na(e,t){if(e.pendingLanes&4194048){var n=e.transitionTypes;for(n===null&&(n=e.transitionTypes=[]),e=0;e<t.length;e++){var r=t[e];n.indexOf(r)===-1&&n.push(r)}}}var Pa=null;function Fa(e){var t=e.transitionTypes;return e.transitionTypes=null,t}var Ia=null,La=0,Ra=0,za=null;function Ba(e,t){if(Ia===null){var n=Ia=[];La=0,Ra=Pf(),za={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return La++,t.then(Va,Va),t}function Va(){if(--La===0&&(Pa=null,Ia!==null)){za!==null&&(za.status=`fulfilled`);var e=Ia;Ia=null,Ra=0,za=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function Ha(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var Ua=T.S;T.S=function(e,t){if(hd=Ze(),typeof t==`object`&&t&&typeof t.then==`function`&&Ba(e,t),Pa!==null)for(var n=bf;n!==null;)Na(n,Pa),n=n.next;if(n=e.types,n!==null){for(var r=bf;r!==null;)Na(r,n),r=r.next;if(Ra!==0){r=Pa,r===null&&(r=Pa=[]);for(var i=0;i<n.length;i++){var a=n[i];r.indexOf(a)===-1&&r.push(a)}}}Ua!==null&&Ua(e,t)};var Wa=ke(null);function Ga(){var e=Wa.current;return e===null?q.pooledCache:e}function Ka(e,t){t===null?D(Wa,Wa.current):D(Wa,t.pool)}function qa(){var e=Ga();return e===null?null:{parent:Aa._currentValue,pool:e}}var Ja=Error(i(460)),Ya=Error(i(474)),Xa=Error(i(542)),Za={then:function(){}};function Qa(e){return e=e.status,e===`fulfilled`||e===`rejected`}function $a(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(kn,kn),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,ro(e),e===void 0&&!(`reason`in t)?Error(i(600)):e;default:if(typeof t.status==`string`)t.then(kn,kn);else{if(e=q,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,ro(e),e}throw to=t,Ja}}function eo(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(to=e,Ja):e}}var to=null;function no(){if(to===null)throw Error(i(459));var e=to;return to=null,e}function ro(e){if(e===Ja||e===Xa)throw Error(i(483))}var io=null,ao=0;function oo(e){var t=ao;return ao+=1,io===null&&(io=[]),$a(io,e,t)}function so(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function co(e,t){throw t.$$typeof===ie?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function lo(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function a(e,t){return e=R(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=134217730,n):(r=r.index,r<n?(t.flags|=2,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=134217730),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=zi(n,e.mode,r),t.return=e,t):(t=a(t,n),t.return=e,t)}function l(e,t,n,r){var i=n.type;return i===w?(e=d(e,t,n.props.children,r,n.key),so(e,n),e):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===he&&eo(i)===t.type)?(t=a(t,n.props),so(t,n),t.return=e,t):(t=Li(n.type,n.key,n.props,null,e.mode,r),so(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=Vi(n,e.mode,r),t.return=e,t):(t=a(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,i){return t===null||t.tag!==7?(t=Ri(n,e.mode,r,i),t.return=e,t):(t=a(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=zi(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case ae:return n=Li(t.type,t.key,t.props,null,e.mode,n),so(n,t),n.return=e,n;case oe:return t=Vi(t,e.mode,n),t.return=e,t;case he:return t=eo(t),f(e,t,n)}if(Te(t)||Se(t))return t=Ri(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,oo(t),n);if(t.$$typeof===ue)return f(e,Ta(e,t),n);co(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case ae:return n.key===i?l(e,t,n,r):null;case oe:return n.key===i?u(e,t,n,r):null;case he:return n=eo(n),p(e,t,n,r)}if(Te(n)||Se(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,oo(n),r);if(n.$$typeof===ue)return p(e,t,Ta(e,n),r);co(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case ae:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case oe:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case he:return r=eo(r),m(e,t,n,r,i)}if(Te(r)||Se(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,oo(r),i);if(r.$$typeof===ue)return m(e,t,n,Ta(t,r),i);co(t,r)}return null}function h(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),V&&$i(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return V&&$i(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&(_=g.alternate,_!==null&&d.delete(_.key===null?h:_.key)),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),V&&$i(i,h),l}function g(a,s,c,l){if(c==null)throw Error(i(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(a,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(a,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(a,h),V&&$i(a,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return V&&$i(a,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,a,g,v.value,l),v!==null&&(e&&(_=v.alternate,_!==null&&h.delete(_.key===null?g:_.key)),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(a,e)}),V&&$i(a,g),u}function _(e,r,o,c){if(typeof o==`object`&&o&&o.type===w&&o.key===null&&o.props.ref===void 0&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case ae:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===w){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),so(c,o),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===he&&eo(l)===r.type){n(e,r.sibling),c=a(r,o.props),so(c,o),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}o.type===w?(c=Ri(o.props.children,e.mode,c,o.key),so(c,o),c.return=e,e=c):(c=Li(o.type,o.key,o.props,null,e.mode,c),so(c,o),c.return=e,e=c)}return s(e);case oe:a:{for(l=o.key;r!==null;){if(r.key===l){if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}c=Vi(o,e.mode,c),c.return=e,e=c}return s(e);case he:return o=eo(o),_(e,r,o,c)}if(Te(o))return h(e,r,o,c);if(Se(o)){if(l=Se(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),g(e,r,o,c)}if(typeof o.then==`function`)return _(e,r,oo(o),c);if(o.$$typeof===ue)return _(e,r,Ta(e,o),c);co(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=zi(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{ao=0;var i=_(e,t,n,r);return io=null,i}catch(t){if(t===Ja||t===Xa)throw t;var a=Pi(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var uo=lo(!0),fo=lo(!1),po=!1;function mo(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function ho(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function go(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function _o(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,K&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=ji(e),Ai(e,null,n),t}return Di(e,r,t,n),ji(e)}function vo(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Et(e,n)}}function yo(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var bo=!1;function xo(){if(bo){var e=za;if(e!==null)throw e}}function So(e,t,n,r){bo=!1;var i=e.updateQueue;po=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(Y&f)===f:(r&f)===f){f!==0&&f===Ra&&(bo=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,h=s;f=t;var g=n;switch(h.tag){case 1:if(m=h.payload,typeof m==`function`){d=m.call(g,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=h.payload,f=typeof m==`function`?m.call(g,d,f):m,f==null)break a;d=C({},d,f);break a;case 2:po=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),od|=o,e.lanes=o,e.memoizedState=d}}function Co(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function wo(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Co(n[e],t)}var To=ke(null),Eo=ke(0);function Do(e,t){e=id,D(Eo,e),D(To,t),id=e|t.baseLanes}function Oo(){D(Eo,id),D(To,To.current)}function ko(){id=Eo.current,Ae(To),Ae(Eo)}var Ao=ke(null),jo=null;function Mo(e){var t=e.alternate;D(Lo,Lo.current&1),D(Ao,e),jo===null&&(t===null||To.current!==null||t.memoizedState!==null)&&(jo=e)}function No(e){D(Lo,Lo.current),D(Ao,e),jo===null&&(jo=e)}function Po(e){e.tag===22?(D(Lo,Lo.current),D(Ao,e),jo===null&&(jo=e)):Fo()}function Fo(){D(Lo,Lo.current),D(Ao,Ao.current)}function Io(e){Ae(Ao),jo===e&&(jo=null),Ae(Lo)}var Lo=ke(0);function Ro(e,t){D(Ao,Ao.current),D(Lo,t)}function zo(e){Ae(Lo),Ae(Ao),jo===e&&(jo=null)}function Bo(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||om(n)||sm(n)))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==`independent`){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Vo=0,H=null,U=null,Ho=null,Uo=!1,Wo=!1,Go=!1,Ko=0,qo=0,Jo=null,Yo=0;function W(){throw Error(i(321))}function Xo(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Wr(e[n],t[n]))return!1;return!0}function Zo(e,t,n,r,i,a){return Vo=a,H=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,T.H=e===null||e.memoizedState===null?mc:hc,Go=!1,a=n(r,i),Go=!1,Wo&&(a=$o(t,n,r,i)),Qo(e),a}function Qo(e){T.H=pc;var t=U!==null&&U.next!==null;if(Vo=0,Ho=U=H=null,Uo=!1,qo=0,Jo=null,t)throw Error(i(300));e===null||Mc||(e=e.dependencies,e!==null&&Sa(e)&&(Mc=!0))}function $o(e,t,n,r){H=e;var a=0;do{if(Wo&&(Jo=null),qo=0,Wo=!1,25<=a)throw Error(i(301));if(a+=1,Ho=U=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}T.H=gc,o=t(n,r)}while(Wo);return o}function es(){var e=T.H,t=e.useState()[0];return t=typeof t.then==`function`?ss(t):t,e=e.useState()[0],(U===null?null:U.memoizedState)!==e&&(H.flags|=1024),t}function ts(){var e=Ko!==0;return Ko=0,e}function ns(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function rs(e){if(Uo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Uo=!1}Vo=0,Ho=U=H=null,Wo=!1,qo=Ko=0,Jo=null}function is(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ho===null?H.memoizedState=Ho=e:Ho=Ho.next=e,Ho}function as(){if(U===null){var e=H.alternate;e=e===null?null:e.memoizedState}else e=U.next;var t=Ho===null?H.memoizedState:Ho.next;if(t!==null)Ho=t,U=e;else{if(e===null)throw H.alternate===null?Error(i(467)):Error(i(310));U=e,e={memoizedState:U.memoizedState,baseState:U.baseState,baseQueue:U.baseQueue,queue:U.queue,next:null},Ho===null?H.memoizedState=Ho=e:Ho=Ho.next=e}return Ho}function os(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function ss(e){var t=qo;return qo+=1,Jo===null&&(Jo=[]),e=$a(Jo,e,t),t=H,(Ho===null?t.memoizedState:Ho.next)===null&&(t=t.alternate,T.H=t===null||t.memoizedState===null?mc:hc),e}function cs(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return ss(e);if(e.$$typeof===be)return;if(e.$$typeof===ue)return wa(e)}throw Error(i(438,String(e)))}function ls(e){var t=null,n=H.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=H.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=os(),H.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=ve;return t.index++,n}function us(e,t){return typeof t==`function`?t(e):t}function ds(e){return fs(as(),U,e)}function fs(e,t,n){var r=e.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=n;var a=e.baseQueue,o=r.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,r.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(Vo&f)===f:(Y&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===Ra&&(d=!0);else if((Vo&p)===p){u=u.next,p===Ra&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,H.lanes|=p,od|=p;f=u.action,Go&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,H.lanes|=f,od|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!Wr(o,e.memoizedState)&&(Mc=!0,d&&(n=za,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function ps(e){var t=as(),n=t.queue;if(n===null)throw Error(i(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);Wr(o,t.memoizedState)||(Mc=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function ms(e,t,n){var r=H,a=as(),o=V;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!Wr((U||a).memoizedState,n);if(s&&(a.memoizedState=n,Mc=!0),a=a.queue,zs(_s.bind(null,r,a,e),[e]),e=a.getSnapshot!==t||s||Ho!==null&&!!(Ho.memoizedState.tag&1),Ps(e?9:8,{destroy:void 0},gs.bind(null,r,a,n,t),null),e){if(r.flags|=2048,q===null)throw Error(i(349));o||Vo&127||hs(r,t,n)}return n}function hs(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=H.updateQueue,t===null?(t=os(),H.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function gs(e,t,n,r){t.value=n,t.getSnapshot=r,vs(t)&&ys(e)}function _s(e,t,n){return n(function(){vs(t)&&ys(e)})}function vs(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Wr(e,n)}catch{return!0}}function ys(e){var t=ki(e,2);t!==null&&Pd(t,e,2)}function bs(e){var t=is();if(typeof e==`function`){var n=e;if(e=n(),Go){ct(!0);try{n()}finally{ct(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:us,lastRenderedState:e},t}function xs(e,t,n,r){return e.baseState=n,fs(e,U,typeof r==`function`?r:us)}function Ss(e,t,n,r,a){if(uc(e))throw Error(i(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};T.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,Cs(t,o)):(o.next=n.next,t.pending=n.next=o)}}function Cs(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=T.T,o={};o.types=a===null?null:a.types,T.T=o;try{var s=n(i,r),c=T.S;c!==null&&c(o,s),ws(e,t,s)}catch(n){Es(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),T.T=a}}else try{a=n(i,r),ws(e,t,a)}catch(n){Es(e,t,n)}}function ws(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Ts(e,t,n)},function(n){return Es(e,t,n)}):Ts(e,t,n)}function Ts(e,t,n){t.status=`fulfilled`,t.value=n,Ds(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Cs(e,n)))}function Es(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,Ds(t),t=t.next;while(t!==r)}e.action=null}function Ds(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Os(e,t){return t}function ks(e,t){if(V){var n=q.formState;if(n!==null){a:{var r=H;if(V){if(B){b:{for(var i=B,a=aa;i.nodeType!==8;){if(!a){i=null;break b}if(i=lm(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){B=lm(i.nextSibling),r=i.data===`F!`;break a}}sa(r)}r=!1}r&&(t=n[0])}}return n=is(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Os,lastRenderedState:t},n.queue=r,n=sc.bind(null,H,r),r.dispatch=n,r=bs(!1),a=lc.bind(null,H,!1,r.queue),r=is(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Ss.bind(null,H,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function As(e){return js(as(),U,e)}function js(e,t,n){if(t=fs(e,t,Os)[0],e=ds(us)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=ss(t)}catch(e){throw e===Ja?Xa:e}else r=t;t=as();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(H.flags|=2048,Ps(9,{destroy:void 0},Ms.bind(null,i,n),null)),[r,a,e]}function Ms(e,t){e.action=t}function Ns(e){var t=as(),n=U;if(n!==null)return js(t,n,e);as(),t=t.memoizedState,n=as();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function Ps(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=H.updateQueue,t===null&&(t=os(),H.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function Fs(){return as().memoizedState}function Is(e,t,n,r){var i=is();H.flags|=e,i.memoizedState=Ps(1|t,{destroy:void 0},n,r===void 0?null:r)}function Ls(e,t,n,r){var i=as();r=r===void 0?null:r;var a=i.memoizedState.inst;U!==null&&r!==null&&Xo(r,U.memoizedState.deps)?i.memoizedState=Ps(t,a,n,r):(H.flags|=e,i.memoizedState=Ps(1|t,a,n,r))}function Rs(e,t){Is(8390656,8,e,t)}function zs(e,t){Ls(2048,8,e,t)}function Bs(e){H.flags|=4;var t=H.updateQueue;if(t===null)t=os(),H.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function Vs(e){var t=as().memoizedState;return Bs({ref:t,nextImpl:e}),function(){if(K&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function Hs(e,t){return Ls(4,2,e,t)}function Us(e,t){return Ls(4,4,e,t)}function Ws(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function Gs(e,t,n){n=n==null?null:n.concat([e]),Ls(4,4,Ws.bind(null,t,e),n)}function Ks(){}function qs(e,t){var n=as();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&Xo(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Js(e,t){var n=as();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&Xo(t,r[1]))return r[0];if(r=e(),Go){ct(!0);try{e()}finally{ct(!1)}}return n.memoizedState=[r,t],r}function Ys(e,t,n){return n===void 0||Vo&1073741824&&!(Y&261930)?e.memoizedState=t:(e.memoizedState=n,e=Md(),H.lanes|=e,od|=e,n)}function Xs(e,t,n,r){return Wr(n,t)?n:To.current===null?!(Vo&106)||Vo&1073741824&&!(Y&261930)?(Mc=!0,e.memoizedState=n):(e=Md(),H.lanes|=e,od|=e,t):(e=Ys(e,n,r),Wr(e,t)||(Mc=!0),e)}function Zs(e,t,n,r,i){var a=E.p;E.p=a!==0&&8>a?a:8;var o=T.T,s={};s.types=o===null?null:o.types,T.T=s,lc(e,!1,t,n);try{var c=i(),l=T.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?cc(e,t,Ha(c,r),jd(e)):cc(e,t,r,jd(e))}catch(n){cc(e,t,{then:function(){},status:`rejected`,reason:n},jd())}finally{E.p=a,o!==null&&s.types!==null&&(o.types=s.types),T.T=o}}function Qs(){}function $s(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=ec(e).queue;Zs(e,a,t,Ee,n===null?Qs:function(){return tc(e),n(r)})}function ec(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:Ee,baseState:Ee,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:us,lastRenderedState:Ee},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:us,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function tc(e){var t=ec(e);t.next===null&&(t=e.alternate.memoizedState),cc(e,t.next.queue,{},jd())}function nc(){return wa(sh)}function rc(){return as().memoizedState}function ic(){return as().memoizedState}function ac(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=jd();e=go(n);var r=_o(t,e,n);r!==null&&(Pd(r,t,n),vo(r,t,n)),t={cache:ja()},e.payload=t;return}t=t.return}}function oc(e,t,n){var r=jd();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},uc(e)?dc(t,n):(n=Oi(e,t,n,r),n!==null&&(Pd(n,e,r),fc(n,t,r)))}function sc(e,t,n){cc(e,t,n,jd())}function cc(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(uc(e))dc(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,Wr(s,o))return Di(e,t,i,0),q===null&&Ei(),!1}catch{}if(n=Oi(e,t,i,r),n!==null)return Pd(n,e,r),fc(n,t,r),!0}return!1}function lc(e,t,n,r){if(r={lane:2,revertLane:Pf(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},uc(e)){if(t)throw Error(i(479))}else t=Oi(e,n,r,2),t!==null&&Pd(t,e,2)}function uc(e){var t=e.alternate;return e===H||t!==null&&t===H}function dc(e,t){Wo=Uo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function fc(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Et(e,n)}}var pc={readContext:wa,use:cs,useCallback:W,useContext:W,useEffect:W,useImperativeHandle:W,useLayoutEffect:W,useInsertionEffect:W,useMemo:W,useReducer:W,useRef:W,useState:W,useDebugValue:W,useDeferredValue:W,useTransition:W,useSyncExternalStore:W,useId:W,useHostTransitionStatus:W,useFormState:W,useActionState:W,useOptimistic:W,useMemoCache:W,useCacheRefresh:W,useEffectEvent:W},mc={readContext:wa,use:cs,useCallback:function(e,t){return is().memoizedState=[e,t===void 0?null:t],e},useContext:wa,useEffect:Rs,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),Is(4194308,4,Ws.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Is(4194308,4,e,t)},useInsertionEffect:function(e,t){Is(4,2,e,t)},useMemo:function(e,t){var n=is();t=t===void 0?null:t;var r=e();if(Go){ct(!0);try{e()}finally{ct(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=is();if(n!==void 0){var i=n(t);if(Go){ct(!0);try{n(t)}finally{ct(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=oc.bind(null,H,e),[r.memoizedState,e]},useRef:function(e){var t=is();return e={current:e},t.memoizedState=e},useState:function(e){e=bs(e);var t=e.queue,n=sc.bind(null,H,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:Ks,useDeferredValue:function(e,t){return Ys(is(),e,t)},useTransition:function(){var e=bs(!1);return e=Zs.bind(null,H,e.queue,!0,!1),is().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=H,a=is();if(V){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),q===null)throw Error(i(349));Y&127||hs(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,Rs(_s.bind(null,r,o,e),[e]),r.flags|=2048,Ps(9,{destroy:void 0},gs.bind(null,r,o,n,t),null),n},useId:function(){var e=is(),t=q.identifierPrefix;if(V){var n=Qi,r=Zi;n=(r&~(1<<32-lt(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=Ko++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=Yo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:nc,useFormState:ks,useActionState:ks,useOptimistic:function(e){var t=is();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=lc.bind(null,H,!0,n),n.dispatch=t,[e,t]},useMemoCache:ls,useCacheRefresh:function(){return is().memoizedState=ac.bind(null,H)},useEffectEvent:function(e){var t=is(),n={impl:e};return t.memoizedState=n,function(){if(K&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},hc={readContext:wa,use:cs,useCallback:qs,useContext:wa,useEffect:zs,useImperativeHandle:Gs,useInsertionEffect:Hs,useLayoutEffect:Us,useMemo:Js,useReducer:ds,useRef:Fs,useState:function(){return ds(us)},useDebugValue:Ks,useDeferredValue:function(e,t){return Xs(as(),U.memoizedState,e,t)},useTransition:function(){var e=ds(us)[0],t=as().memoizedState;return[typeof e==`boolean`?e:ss(e),t]},useSyncExternalStore:ms,useId:rc,useHostTransitionStatus:nc,useFormState:As,useActionState:As,useOptimistic:function(e,t){return xs(as(),U,e,t)},useMemoCache:ls,useCacheRefresh:ic,useEffectEvent:Vs},gc={readContext:wa,use:cs,useCallback:qs,useContext:wa,useEffect:zs,useImperativeHandle:Gs,useInsertionEffect:Hs,useLayoutEffect:Us,useMemo:Js,useReducer:ps,useRef:Fs,useState:function(){return ps(us)},useDebugValue:Ks,useDeferredValue:function(e,t){var n=as();return U===null?Ys(n,e,t):Xs(n,U.memoizedState,e,t)},useTransition:function(){var e=ps(us)[0],t=as().memoizedState;return[typeof e==`boolean`?e:ss(e),t]},useSyncExternalStore:ms,useId:rc,useHostTransitionStatus:nc,useFormState:Ns,useActionState:Ns,useOptimistic:function(e,t){var n=as();return U===null?(n.baseState=e,[e,n.queue.dispatch]):xs(n,U,e,t)},useMemoCache:ls,useCacheRefresh:ic,useEffectEvent:Vs};function _c(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:C({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var vc={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=jd(),i=go(r);i.payload=t,n!=null&&(i.callback=n),t=_o(e,i,r),t!==null&&(Pd(t,e,r),vo(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=jd(),i=go(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=_o(e,i,r),t!==null&&(Pd(t,e,r),vo(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=jd(),r=go(n);r.tag=2,t!=null&&(r.callback=t),t=_o(e,r,n),t!==null&&(Pd(t,e,n),vo(t,e,n))}};function yc(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!Gr(n,r)||!Gr(i,a):!0}function bc(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&vc.enqueueReplaceState(t,t.state,null)}function xc(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=C({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Sc(e){Si(e)}function Cc(e){console.error(e)}function wc(e){Si(e)}function Tc(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Ec(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Dc(e,t,n){return n=go(n),n.tag=3,n.payload={element:null},n.callback=function(){Tc(e,t)},n}function Oc(e){return e=go(e),e.tag=3,e}function kc(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Ec(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Ec(t,n,r),typeof i!=`function`&&(vd===null?vd=new Set([this]):vd.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function Ac(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&xa(t,n,a,!0),n=Ao.current,n!==null){switch(n.tag){case 31:case 13:case 19:return jo===null?Kd():n.alternate===null&&ad===0&&(ad=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===Za?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),mf(e,r,a)),!1;case 22:return n.flags|=65536,r===Za?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),mf(e,r,a)),!1}throw Error(i(435,n.tag))}return mf(e,r,a),Kd(),!1}if(V)return t=Ao.current,t===null?(r!==oa&&(t=Error(i(423),{cause:r}),pa(Ui(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=Ui(r,n),a=Dc(e.stateNode,r,a),yo(e,a),ad!==4&&(ad=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==oa&&(e=Error(i(422),{cause:r}),pa(Ui(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=Ui(o,n),dd===null?dd=[o]:dd.push(o),ad!==4&&(ad=2),t===null)return!0;r=Ui(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=Dc(n.stateNode,r,e),yo(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(vd===null||!vd.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=Oc(a),kc(a,e,n,r),yo(n,a),!1;break;case 22:if(n.memoizedState!==null)return n.flags|=65536,!1}n=n.return}while(n!==null);return!1}var jc=Error(i(461)),Mc=!1;function Nc(e,t,n,r){t.child=e===null?fo(t,null,n,r):uo(t,e.child,n,r)}function Pc(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return Ca(t),r=Zo(e,t,n,o,a,i),s=ts(),e!==null&&!Mc?(ns(e,t,i),cl(e,t,i)):(V&&s&&ta(t),t.flags|=1,Nc(e,t,r,i),t.child)}function Fc(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!Fi(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,Ic(e,t,a,r,i)):(e=Li(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!ll(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?Gr:n,n(o,r)&&e.ref===t.ref)return cl(e,t,i)}return t.flags|=1,e=R(a,r),e.ref=t.ref,e.return=t,t.child=e}function Ic(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(Gr(a,r)&&e.ref===t.ref){if(Mc=!1,t.pendingProps=r=a,ll(e,i))e.flags&131072&&(Mc=!0);else return t.lanes=e.lanes,cl(e,t,i)}}return Wc(e,t,n,r,i)}function Lc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return zc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Ka(t,a===null?null:a.cachePool),a===null?Oo():Do(t,a),Po(t);else return r=t.lanes=536870912,zc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&Ka(t,null),Oo(),Fo()):(Ka(t,a.cachePool),Do(t,a),Fo(),t.memoizedState=null);return Nc(e,t,i,n),t.child}function Rc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function zc(e,t,n,r,i){var a=Ga();return a=a===null?null:{parent:Aa._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&Ka(t,null),Oo(),Po(t),e!==null&&xa(e,t,r,!0),t.childLanes=i,null}function Bc(e,t){return t=$c({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function Vc(e,t,n){return uo(t,e.child,null,n),e=Bc(t,t.pendingProps),e.flags|=2,Io(t),t.memoizedState=null,e}function Hc(e,t,n){var r=t.pendingProps,a=!!(t.flags&128);if(t.flags&=-129,e===null){if(V){if(r.mode===`hidden`)return e=Bc(t,r),t.lanes=536870912,e.memoizedState={baseLanes:0,cachePool:null},Rc(null,e);if(No(t),(e=B)?(e=am(e,aa),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Xi===null?null:{id:Zi,overflow:Qi},retryLane:536870912,hydrationErrors:null},n=Bi(e),n.return=t,t.child=n,z=t,B=null)):e=null,e===null)throw sa(t);return t.lanes=536870912,null}return Bc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(No(t),a){if(t.flags&256)t.flags&=-257,t=Vc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558))}else if(Mc||xa(e,t,n,!1),a=(n&e.childLanes)!==0,Mc||a){if(To.current===null){if(r=q,r!==null&&(s=Dt(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,ki(e,s),Pd(r,e,s),jc;Kd()}t=Vc(e,t,n)}else e=o.treeContext,B=lm(s.nextSibling),z=t,V=!0,ia=null,aa=!1,e!==null&&ra(t,e),t=Bc(t,r),t.flags|=134221824;return t}return e=R(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function Uc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(i(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function Wc(e,t,n,r,i){return Ca(t),n=Zo(e,t,n,r,void 0,i),r=ts(),e!==null&&!Mc?(ns(e,t,i),cl(e,t,i)):(V&&r&&ta(t),t.flags|=1,Nc(e,t,n,i),t.child)}function Gc(e,t,n,r,i,a){return Ca(t),t.updateQueue=null,n=$o(t,r,n,i),Qo(e),r=ts(),e!==null&&!Mc?(ns(e,t,a),cl(e,t,a)):(V&&r&&ta(t),t.flags|=1,Nc(e,t,n,a),t.child)}function Kc(e,t,n,r,i){if(Ca(t),t.stateNode===null){var a=Mi,o=n.contextType;typeof o==`object`&&o&&(a=wa(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=vc,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},mo(t),o=n.contextType,a.context=typeof o==`object`&&o?wa(o):Mi,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(_c(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&vc.enqueueReplaceState(a,a.state,null),So(t,r,a,i),xo(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=xc(n,s);a.props=c;var l=a.context,u=n.contextType;o=Mi,typeof u==`object`&&u&&(o=wa(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&bc(t,a,r,o),po=!1;var f=t.memoizedState;a.state=f,So(t,r,a,i),xo(),l=t.memoizedState,s||f!==l||po?(typeof d==`function`&&(_c(t,n,d,r),l=t.memoizedState),(c=po||yc(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,ho(e,t),o=t.memoizedProps,u=xc(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=Mi,typeof l==`object`&&l&&(c=wa(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&bc(t,a,r,c),po=!1,f=t.memoizedState,a.state=f,So(t,r,a,i),xo();var p=t.memoizedState;o!==d||f!==p||po||e!==null&&e.dependencies!==null&&Sa(e.dependencies)?(typeof s==`function`&&(_c(t,n,s,r),p=t.memoizedState),(u=po||yc(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Sa(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,Uc(e,t),r=!!(t.flags&128),a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=uo(t,e.child,null,i),t.child=uo(t,null,n,i)):Nc(e,t,n,i),t.memoizedState=a.state,e=t.child):e=cl(e,t,i),e}function qc(e,t,n,r){return da(),t.flags|=256,Nc(e,t,n,r),t.child}var Jc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Yc(e){return{baseLanes:e,cachePool:qa()}}function Xc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=ld),e}function Zc(e,t,n){var r=t.pendingProps,i=!1,a=!!(t.flags&128),o;if((o=a)||(o=e!==null&&e.memoizedState===null?!1:!!(Lo.current&2)),o&&(i=!0,t.flags&=-129),o=!!(t.flags&32),t.flags&=-33,e===null){if(V){if(i?Mo(t):Fo(),(e=B)?(e=am(e,aa),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Xi===null?null:{id:Zi,overflow:Qi},retryLane:536870912,hydrationErrors:null},n=Bi(e),n.return=t,t.child=n,z=t,B=null)):e=null,e===null)throw sa(t);return t.lanes=sm(e)?32:536870912,null}return a=r.children,r=r.fallback,i?(Fo(),i=t.mode,a=$c({mode:`hidden`,children:a},i),r=Ri(r,i,n,null),a.return=t,r.return=t,a.sibling=r,t.child=a,r=t.child,r.memoizedState=Yc(n),r.childLanes=Xc(e,o,n),t.memoizedState=Jc,Rc(null,r)):(Mo(t),Qc(t,a))}var s=e.memoizedState;if(s!==null){var c=s.dehydrated;if(c!==null)return tl(e,t,a,o,r,c,s,n)}return i?(Fo(),i=r.fallback,a=t.mode,s=e.child,c=s.sibling,r=R(s,{mode:`hidden`,children:r.children}),r.subtreeFlags=s.subtreeFlags&1206910976,c===null?(i=Ri(i,a,n,null),i.flags|=2):i=R(c,i),i.return=t,r.return=t,r.sibling=i,t.child=r,Rc(null,r),r=t.child,i=e.child.memoizedState,i===null?i=Yc(n):(a=i.cachePool,a===null?a=qa():(s=Aa._currentValue,a=a.parent===s?a:{parent:s,pool:s}),i={baseLanes:i.baseLanes|n,cachePool:a}),r.memoizedState=i,r.childLanes=Xc(e,o,n),t.memoizedState=Jc,Rc(e.child,r)):(Mo(t),n=e.child,e=n.sibling,n=R(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(o=t.deletions,o===null?(t.deletions=[e],t.flags|=16):o.push(e)),t.child=n,t.memoizedState=null,n)}function Qc(e,t){return t=$c({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function $c(e,t){return e=Pi(22,e,null,t),e.lanes=0,e}function el(e,t,n){return uo(t,e.child,null,n),e=Qc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function tl(e,t,n,r,a,o,s,c){if(n)return t.flags&256?(Mo(t),t.flags&=-257,el(e,t,c)):t.memoizedState===null?(Fo(),o=a.fallback,s=t.mode,a=$c({mode:`visible`,children:a.children},s),o=Ri(o,s,c,null),o.flags|=2,a.return=t,o.return=t,a.sibling=o,t.child=a,uo(t,e.child,null,c),a=t.child,a.memoizedState=Yc(c),a.childLanes=Xc(e,r,c),t.memoizedState=Jc,Rc(null,a)):(Fo(),t.child=e.child,t.flags|=128,null);if(Mo(t),sm(o)){if(r=o.nextSibling&&o.nextSibling.dataset,r)var l=r.dgst;return r=l,r!==``&&(a=Error(i(419)),a.stack=``,a.digest=r,pa({value:a,source:null,stack:null})),el(e,t,c)}if(Mc||xa(e,t,c,!1),r=(c&e.childLanes)!==0,Mc||r){if(To.current!==null)return el(e,t,c);if(r=q,r!==null&&(a=Dt(r,c),a!==0&&a!==s.retryLane))throw s.retryLane=a,ki(e,a),Pd(r,e,a),jc;return om(o)||Kd(),el(e,t,c)}return om(o)?(t.flags|=192,t.child=e.child,null):(e=s.treeContext,B=lm(o.nextSibling),z=t,V=!0,ia=null,aa=!1,e!==null&&ra(t,e),t=Qc(t,a.children),t.flags|=134221824,t)}function nl(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),ya(e.return,t,n)}function rl(e){for(var t=null;e!==null;){var n=e.alternate;n!==null&&Bo(n)===null&&(t=e),e=e.sibling}return t}function il(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function al(e){var t=e.child;for(e.child=null;t!==null;){var n=t.sibling;t.sibling=e.child,e.child=t,t=n}}function ol(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=Lo.current;if(t.flags&128)return Ro(t,o),null;var s=!!(o&2);if(s?(o=o&1|2,t.flags|=128):o&=1,Ro(t,o),i===`backwards`&&e!==null?(al(e),Nc(e,t,r,n),al(e)):Nc(e,t,r,n),r=V?qi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&nl(e,n,t);else if(e.tag===19)nl(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`backwards`:n=rl(t.child),n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null,al(t)),il(t,!0,i,null,a,r);break;case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&Bo(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}il(t,!0,n,null,a,r);break;case`together`:il(t,!1,null,null,void 0,r);break;case`independent`:t.memoizedState=null;break;default:n=rl(t.child),n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),il(t,!1,i,n,a,r)}return t.child}function sl(e,t,n){var r=t.pendingProps;return _a(t,t.type,r.value),Nc(e,t,r.children,n),t.child}function cl(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),od|=t.lanes,(n&t.childLanes)===0){if(e!==null){if(xa(e,t,n,!1),(n&t.childLanes)===0)return null}else return null}if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,n=R(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=R(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function ll(e,t){return(e.lanes&t)!==0||(e=e.dependencies,!!(e!==null&&Sa(e)))}function ul(e,t,n){switch(t.tag){case 3:Fe(t,t.stateNode.containerInfo),_a(t,Aa,e.memoizedState.cache),da();break;case 27:case 5:Le(t);break;case 4:Fe(t,t.stateNode.containerInfo);break;case 10:_a(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,No(t),null;break;case 13:var r=t.memoizedState;if(r!==null){if(r.dehydrated!==null)return Mo(t),t.flags|=128,null;r=xa(e,t,n,!1);var i=t.child.childLanes;return r||(n&i)!==0?Zc(e,t,n):(Mo(t),e=cl(e,t,n),e===null?null:e.sibling)}Mo(t);break;case 19:if(t.flags&128)return ol(e,t,n);if(i=!!(e.flags&128),r=(n&t.childLanes)!==0,r||=(xa(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return ol(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),Ro(t,Lo.current),r)break;return null;case 22:return t.lanes=0,Lc(e,t,n,t.pendingProps);case 24:_a(t,Aa,e.memoizedState.cache)}return cl(e,t,n)}function dl(e,t,n){if(e!==null){if(e.memoizedProps!==t.pendingProps)Mc=!0;else{if(!ll(e,n)&&!(t.flags&128))return Mc=!1,ul(e,t,n);Mc=!!(e.flags&131072)}}else Mc=!1,V&&t.flags&1048576&&ea(t,qi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=eo(t.elementType),t.type=e,typeof e==`function`)Fi(e)?(r=xc(e,r),t.tag=1,t=Kc(null,t,e,r,n)):(t.tag=0,t=Wc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===de){t.tag=11,t=Pc(null,t,e,r,n);break a}if(a===me){t.tag=14,t=Fc(null,t,e,r,n);break a}if(a===ue){t.tag=10,t.type=e,t=sl(null,t,n);break a}}throw t=we(e)||e,Error(i(306,t,``))}}return t;case 0:return Wc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=xc(r,t.pendingProps),Kc(e,t,r,a,n);case 3:a:{if(Fe(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,ho(e,t),So(t,r,null,n);var s=t.memoizedState;if(r=s.cache,_a(t,Aa,r),r!==o.cache&&ba(t,[Aa],n,!0),xo(),r=s.element,o.isDehydrated){if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=qc(e,t,r,n);break a}if(r!==a){a=Ui(Error(i(424)),t),pa(a),t=qc(e,t,r,n);break a}switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(B=lm(e.firstChild),z=t,V=!0,ia=null,aa=!0,n=fo(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|134221824,n=n.sibling}else{if(da(),r===a){t=cl(e,t,n);break a}Nc(e,t,r,n)}t=t.child}return t;case 26:return Uc(e,t),e===null?(n=Nm(t.type,null,t.pendingProps,null))?t.memoizedState=n:V||(t.stateNode=fp(t.type,t.pendingProps,Ne.current,t)):t.memoizedState=Nm(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return Le(t),e===null&&V&&(r=t.stateNode=hm(t.type,t.pendingProps,Ne.current),z=t,aa=!0,a=B,Sp(t.type)?(um=a,B=lm(r.firstChild)):B=a),Nc(e,t,t.pendingProps.children,n),Uc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&V&&((a=r=B)&&(r=rm(r,t.type,t.pendingProps,aa),r===null?a=!1:(t.stateNode=r,z=t,B=lm(r.firstChild),aa=!1,a=!0)),a||sa(t)),Le(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,pp(a,o)?r=null:s!==null&&pp(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=Zo(e,t,es,null,null,n),sh._currentValue=a),Uc(e,t),Nc(e,t,r,n),t.child;case 6:return e===null&&V&&((e=n=B)&&(n=im(n,t.pendingProps,aa),n===null?e=!1:(t.stateNode=n,z=t,B=null,e=!0)),e||sa(t)),null;case 13:return Zc(e,t,n);case 4:return Fe(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=uo(t,null,r,n):Nc(e,t,r,n),t.child;case 11:return Pc(e,t,t.type,t.pendingProps,n);case 7:return r=t.pendingProps,Uc(e,t),Nc(e,t,r,n),t.child;case 8:return Nc(e,t,t.pendingProps.children,n),t.child;case 12:return Nc(e,t,t.pendingProps.children,n),t.child;case 10:return sl(e,t,n);case 9:return a=t.type._context,r=t.pendingProps.children,Ca(t),a=wa(a),r=r(a),t.flags|=1,Nc(e,t,r,n),t.child;case 14:return Fc(e,t,t.type,t.pendingProps,n);case 15:return Ic(e,t,t.type,t.pendingProps,n);case 19:return ol(e,t,n);case 31:return Hc(e,t,n);case 22:return Lc(e,t,n,t.pendingProps);case 24:return Ca(t),r=wa(Aa),e===null?(a=Ga(),a===null&&(a=q,o=ja(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},mo(t),_a(t,Aa,a)):((e.lanes&n)!==0&&(ho(e,t),So(t,null,null,n),xo()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,_a(t,Aa,r),r!==a.cache&&ba(t,[Aa],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),_a(t,Aa,r))),Nc(e,t,t.pendingProps.children,n),t.child;case 30:return t.stateNode===null&&(t.stateNode={autoName:null,paired:null,clones:null,ref:null}),r=t.pendingProps,r.name!=null&&r.name!==`auto`?t.flags|=e===null?18882560:18874368:V&&ta(t),e!==null&&e.memoizedProps.name!==r.name?t.flags|=4194816:Uc(e,t),Nc(e,t,r.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function fl(e){e.flags|=4}function pl(e,t,n,r,i){var a;if((a=!!(e.mode&32))&&(a=n===null?Jm(t,r):Jm(t,r)&&(r.src!==n.src||r.srcSet!==n.srcSet)),a){if(e.flags|=16777216,(i&335544128)===i){if(e.stateNode.complete)e.flags|=8192;else if(Ud())e.flags|=8192;else throw to=Za,Ya}}else e.flags&=-16777217}function ml(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Ym(t)){if(Ud())e.flags|=8192;else throw to=Za,Ya}}function hl(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:xt(),e.lanes|=t,ud|=t)}function gl(e,t){if(!V)switch(e.tailMode){case`visible`:break;case`collapsed`:for(var n=e.tail,r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null;break;default:for(t=e.tail,n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null}}function _l(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&1206910976,r|=i.flags&1206910976,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function vl(e,t,n){var r=t.pendingProps;switch(na(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return _l(t),null;case 1:return _l(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),va(Aa),Ie(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(ua(t)?fl(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,fa())),_l(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(fl(t),o===null?(_l(t),pl(t,a,null,r,n)):(_l(t),ml(t,o))):o?o===e.memoizedState?(_l(t),t.flags&=-16777217):(fl(t),_l(t),ml(t,o)):(e=e.memoizedProps,e!==r&&fl(t),_l(t),pl(t,a,e,r,n)),null;case 27:if(Re(t),n=Ne.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&fl(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return _l(t),t.subtreeFlags&=-33554433,null}e=je.current,ua(t)?ca(t,e):(e=hm(a,r,n),t.stateNode=e,fl(t))}return _l(t),t.subtreeFlags&=-33554433,null;case 5:if(Re(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&fl(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return _l(t),t.subtreeFlags&=-33554433,null}if(o=je.current,ua(t))ca(t,o);else{var s=lp(Ne.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;default:switch(a){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[Nt]=t,o[Pt]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(np(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&fl(t)}}return _l(t),t.subtreeFlags&=-33554433,pl(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&fl(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=Ne.current,ua(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=z,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[Nt]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||ep(e.nodeValue,n)),e||sa(t,!0)}else e=lp(e).createTextNode(r),e[Nt]=t,t.stateNode=e}return _l(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=ua(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[Nt]=t}else da(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;_l(t),e=!1}else n=fa(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(Io(t),t):(Io(t),null);if(t.flags&128)throw Error(i(558))}return _l(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=ua(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[Nt]=t}else da(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;_l(t),a=!1}else a=fa(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(Io(t),t):(Io(t),null)}return Io(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),hl(t,t.updateQueue),_l(t),null);case 4:return Ie(),e===null&&Wf(t.stateNode.containerInfo),t.flags|=67108864,_l(t),null;case 10:return va(t.type),_l(t),null;case 19:if(zo(t),r=t.memoizedState,r===null)return _l(t),null;if(a=!!(t.flags&128),o=r.rendering,o===null){if(a)gl(r,!1);else{if(ad!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=Bo(e),o!==null){for(t.flags|=128,gl(r,!1),e=o.updateQueue,t.updateQueue=e,hl(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)Ii(n,e),n=n.sibling;return Ro(t,Lo.current&1|2),V&&$i(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Ze()>gd&&(t.flags|=128,a=!0,gl(r,!1),t.lanes=4194304)}}else{if(!a){if(e=Bo(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,hl(t,e),gl(r,!0),r.tail===null&&r.tailMode!==`collapsed`&&r.tailMode!==`visible`&&!o.alternate&&!V)return _l(t),null}else 2*Ze()-r.renderingStartTime>gd&&n!==536870912&&(t.flags|=128,a=!0,gl(r,!1),t.lanes=4194304)}r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}if(r.tail!==null){e=r.tail;a:{for(n=e;n!==null;){if(n.alternate!==null){n=!1;break a}n=n.sibling}n=!0}return r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Ze(),e.sibling=null,o=Lo.current,o=a?o&1|2:o&1,r.tailMode===`visible`||r.tailMode===`collapsed`||!n||V?Ro(t,o):(n=o,D(Ao,t),D(Lo,n),jo===null&&(jo=t)),V&&$i(t,r.treeForkCount),e}return _l(t),null;case 22:case 23:return Io(t),ko(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(_l(t),t.subtreeFlags&6&&(t.flags|=8192)):_l(t),n=t.updateQueue,n!==null&&hl(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&Ae(Wa),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),va(Aa),_l(t),null;case 25:return null;case 30:return t.flags|=33554432,_l(t),null}throw Error(i(156,t.tag))}function yl(e,t){switch(na(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return va(Aa),Ie(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return Re(t),null;case 31:if(t.memoizedState!==null){if(Io(t),t.alternate===null)throw Error(i(340));da()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(Io(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));da()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return zo(t),e=t.flags,e&65536?(t.flags=e&-65537|128,e=t.memoizedState,e!==null&&(e.rendering=null,e.tail=null),t.flags|=4,t):null;case 4:return Ie(),null;case 10:return va(t.type),null;case 22:case 23:return Io(t),ko(),e!==null&&Ae(Wa),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return va(Aa),null;case 25:return null;default:return null}}function bl(e,t){switch(na(t),t.tag){case 3:va(Aa),Ie();break;case 26:case 27:case 5:Re(t);break;case 4:Ie();break;case 31:t.memoizedState!==null&&Io(t);break;case 13:Io(t);break;case 19:zo(t);break;case 10:va(t.type);break;case 22:case 23:Io(t),ko(),e!==null&&Ae(Wa);break;case 24:va(Aa)}}function xl(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Z(t,t.return,e)}}function Sl(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Z(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Z(t,t.return,e)}}function Cl(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{wo(t,n)}catch(t){Z(e,e.return,t)}}}function wl(e,t,n){n.props=xc(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Z(e,t,n)}}function Tl(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:var i=e.stateNode,a=yi(e.memoizedProps,i);(i.ref===null||i.ref.name!==a)&&(i.ref=Pp(a)),r=i.ref;break;case 7:if(e.stateNode===null){var o=new Fp(e);m(e.child,!1,Qp,o,void 0,void 0),e.stateNode=o}r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Z(e,t,n)}}function El(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){Z(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Z(e,t,n)}else n.current=null}}function Dl(e,t){if((e.tag===5||e.tag===27||e.tag===6)&&e.alternate===null&&t!==null)for(var n=0;n<t.length;n++)em(e.stateNode,t[n])}function Ol(e){for(var t=e.return;t!==null&&(jl(t)&&em(e.stateNode,t.stateNode),!Al(t));)t=t.return}function kl(e){for(var t=e.return;t!==null&&(jl(t)&&tm(e.stateNode,t.stateNode),!Al(t));)t=t.return}function Al(e){return e.tag===5||e.tag===3||e.tag===27}function jl(e){return e&&e.tag===7&&e.stateNode!==null}function Ml(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Z(e,e.return,t)}}function Nl(e,t,n){try{var r=e.stateNode;ip(r,e.type,n,t),r[Pt]=t}catch(t){Z(e,e.return,t)}}function Pl(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Sp(e.type)||e.tag===4}function Fl(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Pl(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Sp(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Il(e,t,n,r){var i=e.tag;if(i===5||i===6)i=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(i,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(i),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=kn)),Dl(e,r),O=!0;else if(i!==4&&(i===27&&(Dl(e,r),r=null,Sp(e.type)&&(n=e.stateNode,t=null)),e=e.child,e!==null))for(Il(e,t,n,r),e=e.sibling;e!==null;)Il(e,t,n,r),e=e.sibling}function Ll(e,t,n,r){var i=e.tag;if(i===5||i===6)i=e.stateNode,t?n.insertBefore(i,t):n.appendChild(i),Dl(e,r),O=!0;else if(i!==4&&(i===27&&(Dl(e,r),r=null,Sp(e.type)&&(n=e.stateNode)),e=e.child,e!==null))for(Ll(e,t,n,r),e=e.sibling;e!==null;)Ll(e,t,n,r),e=e.sibling}function Rl(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);np(t,r,n),t[Nt]=e,t[Pt]=n}catch(t){Z(e,e.return,t)}}var zl=!1,Bl=null;function Vl(e){(e.tag===30||e.subtreeFlags&33554432)&&(zl=!0)}var Hl=null;function Ul(){var e=Hl;return Hl=null,e}var Wl=0;function Gl(e,t,n,r,i){return Wl=0,Kl(e.child,t,n,r,i)}function Kl(e,t,n,r,i){for(var a=!1;e!==null;){if(e.tag===5){var o=e.stateNode;if(r!==null){var s=Op(o);r.push(s),s.view&&(a=!0)}else a||Op(o).view&&(a=!0);zl=!0,Tp(o,Wl===0?t:t+`_`+Wl,n),Wl++}else(e.tag!==22||e.memoizedState===null)&&(e.tag===30&&i||Kl(e.child,t,n,r,i)&&(a=!0));e=e.sibling}return a}function ql(e,t){for(;e!==null;)e.tag===5?Ep(e.stateNode,e.memoizedProps):(e.tag!==22||e.memoizedState===null)&&(e.tag===30&&t||ql(e.child,t)),e=e.sibling}function Jl(e){if(e.subtreeFlags&18874368)for(e=e.child;e!==null;){if((e.tag!==22||e.memoizedState===null)&&(Jl(e),e.tag===30&&e.flags&18874368&&e.stateNode.paired)){var t=e.memoizedProps;if(t.name==null||t.name===`auto`)throw Error(i(544));var n=t.name;t=xi(t.default,t.share),t!==`none`&&(Gl(e,n,t,null,!1)||ql(e.child,!1))}e=e.sibling}}function Yl(e,t){if(e.tag===30){var n=e.stateNode,r=e.memoizedProps,i=yi(r,n),a=xi(r.default,n.paired?r.share:r.enter);a===`none`?Jl(e):Gl(e,i,a,null,!1)?(Jl(e),n.paired||t||Nd(e,r.onEnter)):ql(e.child,!1)}else if(e.subtreeFlags&33554432)for(e=e.child;e!==null;)Yl(e,t),e=e.sibling;else Jl(e)}function Xl(e){if(Bl!==null&&Bl.size!==0){var t=Bl;if(e.subtreeFlags&18874368)for(e=e.child;e!==null;){if(e.tag!==22||e.memoizedState===null){if(e.tag===30&&e.flags&18874368){var n=e.memoizedProps,r=n.name;if(r!=null&&r!==`auto`){var i=t.get(r);if(i!==void 0){var a=xi(n.default,n.share);if(a!==`none`&&(Gl(e,r,a,null,!1)?(a=e.stateNode,i.paired=a,a.paired=i,Nd(e,n.onShare)):ql(e.child,!1)),t.delete(r),t.size===0)break}}}Xl(e)}e=e.sibling}}}function Zl(e){if(e.tag===30){var t=e.memoizedProps,n=yi(t,e.stateNode),r=Bl===null?void 0:Bl.get(n),i=xi(t.default,r===void 0?t.exit:t.share);i!==`none`&&(Gl(e,n,i,null,!1)?r===void 0?Nd(e,t.onExit):(i=e.stateNode,r.paired=i,i.paired=r,Bl.delete(n),Nd(e,t.onShare)):ql(e.child,!1)),Bl!==null&&Xl(e)}else if(e.subtreeFlags&33554432)for(e=e.child;e!==null;)Zl(e),e=e.sibling;else Bl!==null&&Xl(e)}function Ql(e){for(e=e.child;e!==null;){if(e.tag===30){var t=e.memoizedProps,n=yi(t,e.stateNode);t=xi(t.default,t.update),e.flags&=-5,t!==`none`&&Gl(e,n,t,e.memoizedState=[],!1)}else e.subtreeFlags&33554432&&Ql(e);e=e.sibling}}function $l(e){if(e.subtreeFlags&18874368)for(e=e.child;e!==null;){if(e.tag!==22||e.memoizedState===null){if(e.tag===30&&e.flags&18874368){var t=e.stateNode;t.paired!==null&&(t.paired=null,ql(e.child,!1))}$l(e)}e=e.sibling}}function eu(e){if(e.tag===30)e.stateNode.paired=null,ql(e.child,!1),$l(e);else if(e.subtreeFlags&33554432)for(e=e.child;e!==null;)eu(e),e=e.sibling;else $l(e)}function tu(e){for(e=e.child;e!==null;)e.tag===30?ql(e.child,!1):e.subtreeFlags&33554432&&tu(e),e=e.sibling}function nu(e,t,n,r,i,a,o){for(var s=!1;t!==null;){if(t.tag===5){var c=t.stateNode;if(a!==null&&Wl<a.length){var l=a[Wl],u=Op(c);(l.view||u.view)&&(s=!0);var d;if(d=!(e.flags&4)){if(u.clip)d=!0;else{d=l.rect;var f=u.rect;d=d.y!==f.y||d.x!==f.x||d.height!==f.height||d.width!==f.width}}d&&(e.flags|=4),u.abs?u=!l.abs:(l=l.rect,u=u.rect,u=l.height!==u.height||l.width!==u.width),u&&(e.flags|=32)}else e.flags|=32;e.flags&4&&Tp(c,Wl===0?n:n+`_`+Wl,i),s&&e.flags&4||(Hl===null&&(Hl=[]),Hl.push(c,Wl===0?r:r+`_`+Wl,t.memoizedProps)),Wl++}else(t.tag!==22||t.memoizedState===null)&&(t.tag===30&&o?e.flags|=t.flags&32:nu(e,t.child,n,r,i,a,o)&&(s=!0));t=t.sibling}return s}function ru(e,t){for(e=e.child;e!==null;){if(e.tag===30){var n=e.memoizedProps,r=e.stateNode,i=yi(n,r),a=xi(n.default,n.update);if(t){r=r.clones;var o=r===null?null:r.map(kp)}else o=e.memoizedState,e.memoizedState=null;r=e;var s=e.child;Wl=0,i=nu(r,s,i,i,a,o,!1),e.flags&4&&i&&(t||Nd(e,n.onUpdate))}else e.subtreeFlags&33554432&&ru(e,t);e=e.sibling}}var iu=!1,G=!1,au=!1,ou=!1,su=typeof WeakSet==`function`?WeakSet:Set,cu=null,lu=!1,uu=!1,du=!1,fu=!1;function pu(e,t,n){if(e=e.containerInfo,sp=gh,e=Xr(e),Zr(e)){if(`selectionStart`in e)var r={start:e.selectionStart,end:e.selectionEnd};else a:{r=(r=e.ownerDocument)&&r.defaultView||window;var i=r.getSelection&&r.getSelection();if(i&&i.rangeCount!==0){r=i.anchorNode;var a=i.anchorOffset,o=i.focusNode;i=i.focusOffset;try{r.nodeType,o.nodeType}catch{r=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==r||a!==0&&f.nodeType!==3||(c=s+a),f!==o||i!==0&&f.nodeType!==3||(l=s+i),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===r&&++u===a&&(c=s),p===o&&++d===i&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}r=c===-1||l===-1?null:{start:c,end:l}}else r=null}r||={start:0,end:0}}else r=null;for(cp={focusedElem:e,selectionRange:r},gh=!1,n=(n&335544064)===n,cu=t,t=n?9270:1024;cu!==null;){if(e=cu,n&&(r=e.deletions,r!==null))for(a=0;a<r.length;a++)n&&Zl(r[a]);if(e.alternate===null&&e.flags&2)n&&Vl(e),mu(n);else{if(e.tag===22){if(r=e.alternate,e.memoizedState!==null){r!==null&&r.memoizedState===null&&n&&Zl(r),mu(n);continue}if(r!==null&&r.memoizedState!==null){n&&Vl(e),mu(n);continue}}r=e.child,(e.subtreeFlags&t)!==0&&r!==null?(r.return=e,cu=r):(n&&Ql(e),mu(n))}}Bl=null}function mu(e){for(;cu!==null;){var t=cu,n=e,r=t.alternate,a=t.flags;switch(t.tag){case 0:case 11:case 15:break;case 1:if(a&1024&&r!==null){n=void 0,a=r.memoizedProps,r=r.memoizedState;var o=t.stateNode;try{var s=xc(t.type,a);n=o.getSnapshotBeforeUpdate(s,r),o.__reactInternalSnapshotBeforeUpdate=n}catch(e){Z(t,t.return,e)}}break;case 3:if(a&1024){if(r=t.stateNode.containerInfo,n=r.nodeType,n===9)nm(r);else if(n===1)switch(r.nodeName){case`HEAD`:case`HTML`:case`BODY`:nm(r);break;default:r.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;case 30:n&&r!==null&&(n=yi(r.memoizedProps,r.stateNode),a=t.memoizedProps,a=xi(a.default,a.update),a!==`none`&&Gl(r,n,a,r.memoizedState=[],!0));break;default:if(a&1024)throw Error(i(163))}if(r=t.sibling,r!==null){r.return=t.return,cu=r;break}cu=t.return}}function hu(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:Fu(e,n),r&4&&xl(5,n);break;case 1:if(Fu(e,n),r&4){if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){Z(n,n.return,e)}else{var i=xc(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Z(n,n.return,e)}}}r&64&&Cl(n),r&512&&Tl(n,n.return);break;case 3:if(Fu(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{wo(e,t)}catch(e){Z(n,n.return,e)}}break;case 27:t===null&&r&4&&Rl(n);case 26:case 5:Fu(e,n),t===null&&r&4&&Ml(n),r&512&&Tl(n,n.return);break;case 12:Fu(e,n);break;case 31:Fu(e,n),r&4&&wu(e,n);break;case 13:Fu(e,n),r&4&&Tu(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=_f.bind(null,n),cm(e,n))));break;case 22:if(r=n.memoizedState!==null||iu,!r){var a=t!==null&&t.memoizedState!==null||G;t=iu,i=G,iu=r,(G=a)&&!i?(r=2,n.subtreeFlags&8772&&(r|=1),Lu(e,n,r)):Fu(e,n),iu=t,G=i}break;case 30:Fu(e,n),r&512&&Tl(n,n.return);break;case 7:r&512&&Tl(n,n.return);default:Fu(e,n)}}function gu(e,t){for(e=e.child;e!==null;)_u(e,t),e=e.sibling}function _u(e,t){switch(e.tag){case 5:case 26:try{var n=e.stateNode;if(t){var r=n.style;typeof r.setProperty==`function`?r.setProperty(`display`,`none`,`important`):r.display=`none`}else{var i=e.stateNode,a=e.memoizedProps.style,o=a!=null&&a.hasOwnProperty(`display`)?a.display:null;i.style.display=o==null||typeof o==`boolean`?``:(``+o).trim()}}catch(t){Z(e,e.return,t)}vu(e,t);break;case 6:try{e.stateNode.nodeValue=t?``:e.memoizedProps,O=!0}catch(t){Z(e,e.return,t)}break;case 18:try{var s=e.stateNode;t?wp(s,!0):wp(e.stateNode,!1)}catch(t){Z(e,e.return,t)}break;case 22:case 23:e.memoizedState===null&&gu(e,t);break;default:gu(e,t)}}function vu(e,t){if(e.subtreeFlags&67108864)for(e=e.child;e!==null;){a:{var n=e,r=t;switch(n.tag){case 4:_u(n,r);break a;case 22:n.memoizedState===null&&vu(n,r);break a;default:vu(n,r)}}e=e.sibling}}function yu(e){var t=e.alternate;t!==null&&(e.alternate=null,yu(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&Ht(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var bu=null,xu=!1;function Su(e,t,n){for(n=n.child;n!==null;)Cu(e,t,n),n=n.sibling}function Cu(e,t,n){if(st&&typeof st.onCommitFiberUnmount==`function`)try{st.onCommitFiberUnmount(ot,n)}catch{}switch(n.tag){case 26:G||El(n,t),Su(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&!G&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:G||El(n,t),kl(n);var r=bu,i=xu;Sp(n.type)&&(bu=n.stateNode,xu=!1),Su(e,t,n),gm(n.stateNode,n.type,n.memoizedProps),bu=r,xu=i;break;case 5:G||El(n,t),kl(n);case 6:if(n.tag===6&&kl(n),r=bu,i=xu,bu=null,Su(e,t,n),bu=r,xu=i,bu!==null){if(xu)try{(bu.nodeType===9?bu.body:bu.nodeName===`HTML`?bu.ownerDocument.body:bu).removeChild(n.stateNode),O=!0}catch(e){Z(n,t,e)}else try{bu.removeChild(n.stateNode),O=!0}catch(e){Z(n,t,e)}}break;case 18:bu!==null&&(xu?(e=bu,Cp(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Hh(e)):Cp(bu,n.stateNode));break;case 4:r=bu,i=xu,bu=n.stateNode.containerInfo,xu=!0,Su(e,t,n),bu=r,xu=i;break;case 0:case 11:case 14:case 15:Sl(2,n,t),G||Sl(4,n,t),Su(e,t,n);break;case 1:G||(El(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&wl(n,t,r)),Su(e,t,n);break;case 21:Su(e,t,n);break;case 22:G=(r=G)||n.memoizedState!==null,Su(e,t,n),G=r;break;case 30:El(n,t),Su(e,t,n);break;case 7:G||El(n,t),Su(e,t,n);break;default:Su(e,t,n)}}function wu(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Hh(e)}catch(e){Z(t,t.return,e)}}}function Tu(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Hh(e)}catch(e){Z(t,t.return,e)}}function Eu(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new su),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new su),t;default:throw Error(i(435,e.tag))}}function Du(e,t){var n=Eu(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=vf.bind(null,e,t);t.then(r,r)}})}function Ou(e,t,n){var r=t.deletions;if(r!==null)for(var a=0;a<r.length;a++){var o=r[a],s=e,c=t,l=c;a:for(;l!==null;){switch(l.tag){case 27:if(Sp(l.type)){bu=l.stateNode,xu=!1;break a}break;case 5:bu=l.stateNode,xu=!1;break a;case 3:case 4:bu=l.stateNode.containerInfo,xu=!0;break a}l=l.return}if(bu===null)throw Error(i(160));Cu(s,c,o),bu=null,xu=!1,s=o.alternate,s!==null&&(s.return=null),o.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)Au(t,e,n),t=t.sibling}var ku=null;function Au(e,t,n){var r=e.alternate,a=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(a&4&&(r=e.updateQueue,r=r===null?null:r.events,r!==null))for(var o=0;o<r.length;o++){var s=r[o];s.ref.impl=s.nextImpl}Ou(t,e,n),ju(e),a&4&&(Sl(3,e,e.return),xl(3,e),Sl(5,e,e.return));break;case 1:Ou(t,e,n),ju(e),a&512&&(G||r===null||El(r,r.return)),a&64&&iu&&(e=e.updateQueue,e!==null&&(t=e.callbacks,t!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?t:n.concat(t))));break;case 26:if(o=ku,Ou(t,e,n),ju(e),a&512&&(G||r===null||El(r,r.return)),a&4){if(a=r===null?null:r.memoizedState,n=e.memoizedState,r===null){if(n===null){if(e.stateNode===null){if(iu)e.stateNode=fp(e.type,e.memoizedProps,t.containerInfo,e);else{a:{t=e.type,n=e.memoizedProps,a=o.ownerDocument||o;b:switch(t){case`title`:r=a.getElementsByTagName(`title`)[0],(!r||r[Bt]||r[Nt]||r.namespaceURI===`http://www.w3.org/2000/svg`||r.hasAttribute(`itemprop`))&&(r=a.createElement(t),a.head.insertBefore(r,a.querySelector(`head > title`))),np(r,t,n),r[Nt]=e,qt(r),t=r;break a;case`link`:if(o=Gm(`link`,`href`,a).get(t+(n.href||``))){for(s=0;s<o.length;s++)if(r=o[s],r.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&r.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&r.getAttribute(`title`)===(n.title==null?null:n.title)&&r.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){o.splice(s,1);break b}}r=a.createElement(t),np(r,t,n),a.head.appendChild(r);break;case`meta`:if(o=Gm(`meta`,`content`,a).get(t+(n.content||``))){for(s=0;s<o.length;s++)if(r=o[s],r.getAttribute(`content`)===(n.content==null?null:``+n.content)&&r.getAttribute(`name`)===(n.name==null?null:n.name)&&r.getAttribute(`property`)===(n.property==null?null:n.property)&&r.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&r.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){o.splice(s,1);break b}}r=a.createElement(t),np(r,t,n),a.head.appendChild(r);break;default:throw Error(i(468,t))}r[Nt]=e,qt(r),t=r}e.stateNode=t}}else iu||Km(o,e.type,e.stateNode)}else e.stateNode=Bm(o,n,e.memoizedProps)}else a===n?n===null&&e.stateNode!==null&&Nl(e,e.memoizedProps,r.memoizedProps):(a===null?(t=r.stateNode,t===null||G||t.parentNode.removeChild(t)):a.count--,n===null?iu||Km(o,e.type,e.stateNode):Bm(o,n,e.memoizedProps))}break;case 27:Ou(t,e,n),ju(e),a&512&&(G||r===null||El(r,r.return)),r!==null&&a&4&&Nl(e,e.memoizedProps,r.memoizedProps);break;case 5:if(o=au,au=!1,Ou(t,e,n),au=o,ju(e),a&512&&(G||r===null||El(r,r.return)),e.flags&32){t=e.stateNode;try{xn(t,``),O=!0}catch(t){Z(e,e.return,t)}}a&4&&e.stateNode!=null&&(t=e.memoizedProps,Nl(e,t,r===null?t:r.memoizedProps)),a&1024&&(ou=!0);break;case 6:if(Ou(t,e,n),ju(e),a&4){if(e.stateNode===null)throw Error(i(162));t=e.memoizedProps,n=e.stateNode;try{n.nodeValue=t,O=!0}catch(t){Z(e,e.return,t)}}break;case 3:if(O=!1,Wm=null,o=ku,ku=bm(t.containerInfo),Ou(t,e,n),ku=o,ju(e),a&4&&r!==null&&r.memoizedState.isDehydrated)try{Hh(t.containerInfo)}catch(t){Z(e,e.return,t)}ou&&(ou=!1,Mu(e)),O=!1;break;case 4:a=au,au=iu,r=rn(),o=ku,ku=bm(e.stateNode.containerInfo),Ou(t,e,n),ju(e),ku=o,O&&uu&&(du=!0),O=r,au=a;break;case 12:Ou(t,e,n),ju(e);break;case 31:Ou(t,e,n),ju(e),a&4&&(t=e.updateQueue,t!==null&&(e.updateQueue=null,Du(e,t)));break;case 13:Ou(t,e,n),ju(e),e.child.flags&8192&&e.memoizedState!==null!=(r!==null&&r.memoizedState!==null)&&(md=Ze()),a&4&&(t=e.updateQueue,t!==null&&(e.updateQueue=null,Du(e,t)));break;case 22:o=e.memoizedState!==null,s=r!==null&&r.memoizedState!==null;var c=iu,l=G,u=au;iu=c||o,au=u||o,G=l||s,Ou(t,e,n),G=l,au=u,iu=c,ju(e),a&8192&&(t=e.stateNode,t._visibility=o?t._visibility&-2:t._visibility|1,!o||r===null||s||iu||G||(t=s||G,n=iu,r=G,iu=o||iu,G=t,Iu(e,2),iu=n,G=r),!o&&au||gu(e,o)),a&4&&(t=e.updateQueue,t!==null&&(n=t.retryQueue,n!==null&&(t.retryQueue=null,Du(e,n))));break;case 19:Ou(t,e,n),ju(e),a&4&&(t=e.updateQueue,t!==null&&(e.updateQueue=null,Du(e,t)));break;case 30:a&512&&(G||r===null||El(r,r.return)),a=rn(),o=uu,s=(n&335544064)===n,c=e.memoizedProps,uu=s&&xi(c.default,c.update)!==`none`,Ou(t,e,n),ju(e),s&&r!==null&&O&&(e.flags|=4),uu=o,O=a;break;case 21:break;case 7:a&512&&(G||r===null||El(r,r.return)),r&&r.stateNode!==null&&(r.stateNode._fragmentFiber=e);default:Ou(t,e,n),ju(e)}}function ju(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(Pl(r)){n=r;break}r=r.return}r=null;for(var a=e.return;a!==null;){if(jl(a)){var o=a.stateNode;r===null?r=[o]:r.push(o)}if(Al(a))break;a=a.return}var s=r;if(n==null)throw Error(i(160));switch(n.tag){case 27:var c=n.stateNode;Ll(e,Fl(e),c,s);break;case 5:var l=n.stateNode;n.flags&32&&(xn(l,``),n.flags&=-33),Ll(e,Fl(e),l,s);break;case 3:case 4:var u=n.stateNode.containerInfo;Il(e,Fl(e),u,s);break;default:throw Error(i(161))}}catch(t){Z(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Mu(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Mu(t),t.tag===5&&t.flags&1024&&(t=t.stateNode,gh=!0,t.reset(),gh=!1),e=e.sibling}}function Nu(e,t){if(t.subtreeFlags&9270)for(t=t.child;t!==null;)Pu(t,e),t=t.sibling;else ru(t,!1)}function Pu(e,t){var n=e.alternate;if(n===null)Yl(e,!1);else switch(e.tag){case 3:if(fu=lu=!1,Ul(),Nu(t,e),!lu&&!du){if(e=Hl,e!==null)for(var r=0;r<e.length;r+=3){n=e[r];var i=e[r+1];Ep(n,e[r+2]),n=n.ownerDocument.documentElement,n!==null&&n.animate({opacity:[0,0],pointerEvents:[`none`,`none`]},{duration:0,fill:`forwards`,pseudoElement:`::view-transition-group(`+i+`)`})}e=t.containerInfo,e=e.nodeType===9?e.documentElement:e.ownerDocument.documentElement,e!==null&&e.style.viewTransitionName===``&&(e.style.viewTransitionName=`none`,e.animate({opacity:[0,0],pointerEvents:[`none`,`none`]},{duration:0,fill:`forwards`,pseudoElement:`::view-transition-group(root)`}),e.animate({width:[0,0],height:[0,0]},{duration:0,fill:`forwards`,pseudoElement:`::view-transition`})),fu=!0}Hl=null;break;case 5:Nu(t,e);break;case 4:r=lu,lu=!1,Nu(t,e),lu&&(du=!0),lu=r;break;case 22:e.memoizedState===null&&(n.memoizedState===null?Nu(t,e):Yl(e,!1));break;case 30:r=lu,i=Ul(),lu=!1,Nu(t,e),lu&&(e.flags|=4);var a=e.memoizedProps,o=e.stateNode;t=yi(a,o),o=yi(n.memoizedProps,o);var s=xi(a.default,a.update);s===`none`?t=!1:(a=n.memoizedState,n.memoizedState=null,n=e.child,Wl=0,t=nu(e,n,t,o,s,a,!0),Wl!==(a===null?0:a.length)&&(e.flags|=32)),e.flags&4&&t?(Nd(e,e.memoizedProps.onUpdate),Hl=i):i!==null&&(i.push.apply(i,Hl),Hl=i),lu=e.flags&32?!0:r;break;default:Nu(t,e)}}function Fu(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)hu(e,t.alternate,t),t=t.sibling}function Iu(e,t){for(e=e.child;e!==null;){var n=e,r=t;switch(n.tag){case 0:case 11:case 14:case 15:Sl(4,n,n.return),Iu(n,r);break;case 1:El(n,n.return);var i=n.stateNode;typeof i.componentWillUnmount==`function`&&wl(n,n.return,i),Iu(n,r);break;case 27:r&2&&gm(n.stateNode,n.type,n.memoizedProps);case 5:El(n,n.return),n.tag!==5&&n.tag!==27||kl(n),Iu(n,r);break;case 6:kl(n);break;case 26:El(n,n.return),i=n.stateNode,n.memoizedState!==null||i===null||G||i.parentNode.removeChild(i),Iu(n,r);break;case 22:n.memoizedState===null&&Iu(n,r);break;case 30:El(n,n.return),Iu(n,r);break;case 7:El(n,n.return);default:Iu(n,r)}e=e.sibling}}function Lu(e,t,n){for(n=t.subtreeFlags&8772?n:n&-2,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags,s=!!(n&1);switch(a.tag){case 0:case 11:case 15:Lu(i,a,n),xl(4,a);break;case 1:if(Lu(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){Z(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var c=r.stateNode;try{var l=i.shared.hiddenCallbacks;if(l!==null)for(i.shared.hiddenCallbacks=null,i=0;i<l.length;i++)Co(l[i],c)}catch(e){Z(r,r.return,e)}}s&&o&64&&Cl(a),Tl(a,a.return);break;case 27:n&2&&Rl(a);case 5:a.tag!==5&&a.tag!==27||Ol(a),Lu(i,a,n),s&&r===null&&o&4&&Ml(a),Tl(a,a.return);break;case 6:Ol(a);break;case 26:c=a.stateNode,a.memoizedState!==null||c===null||iu||Km(bm(c.ownerDocument),a.type,c),Lu(i,a,n),s&&r===null&&o&4&&Ml(a),Tl(a,a.return);break;case 12:Lu(i,a,n);break;case 31:Lu(i,a,n),s&&o&4&&wu(i,a);break;case 13:Lu(i,a,n),s&&o&4&&Tu(i,a);break;case 22:a.memoizedState===null&&Lu(i,a,n),Tl(a,a.return);break;case 30:Lu(i,a,n),Tl(a,a.return);break;case 7:Tl(a,a.return);default:Lu(i,a,n)}t=t.sibling}}function Ru(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&Ma(n))}function zu(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Ma(e))}function Bu(e,t,n,r){var i=(n&335544064)===n;if(t.subtreeFlags&(i?10262:10256))for(t=t.child;t!==null;)Vu(e,t,n,r),t=t.sibling;else i&&tu(t)}function Vu(e,t,n,r){var i=(n&335544064)===n;i&&t.alternate===null&&t.return!==null&&t.return.alternate!==null&&eu(t);var a=t.flags;switch(t.tag){case 0:case 11:case 15:Bu(e,t,n,r),a&2048&&xl(9,t);break;case 1:Bu(e,t,n,r);break;case 3:Bu(e,t,n,r),i&&fu&&(e=e.containerInfo,e=e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,e.style.viewTransitionName===`root`&&(e.style.viewTransitionName=``),e=e.ownerDocument.documentElement,e!==null&&e.style.viewTransitionName===`none`&&(e.style.viewTransitionName=``)),a&2048&&(a=null,t.alternate!==null&&(a=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==a&&(t.refCount++,a!=null&&Ma(a)));break;case 12:if(a&2048){Bu(e,t,n,r),a=t.stateNode;try{var o=t.memoizedProps,s=o.id,c=o.onPostCommit;typeof c==`function`&&c(s,t.alternate===null?`mount`:`update`,a.passiveEffectDuration,-0)}catch(e){Z(t,t.return,e)}}else Bu(e,t,n,r);break;case 31:Bu(e,t,n,r);break;case 13:Bu(e,t,n,r);break;case 23:break;case 22:o=t.stateNode,s=t.alternate,t.memoizedState===null?(i&&s!==null&&s.memoizedState!==null&&eu(t),o._visibility&2?Bu(e,t,n,r):(o._visibility|=2,Hu(e,t,n,r,!!(t.subtreeFlags&10256)||!1))):(i&&s!==null&&s.memoizedState===null&&eu(s),o._visibility&2?Bu(e,t,n,r):Uu(e,t)),a&2048&&Ru(s,t);break;case 24:Bu(e,t,n,r),a&2048&&zu(t.alternate,t);break;case 30:i&&(a=t.alternate,a!==null&&(ql(a.child,!0),ql(t.child,!0))),Bu(e,t,n,r);break;default:Bu(e,t,n,r)}}function Hu(e,t,n,r,i){for(i&&=!!(t.subtreeFlags&10256)||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Hu(a,o,s,c,i),xl(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Hu(a,o,s,c,i)):u._visibility&2?Hu(a,o,s,c,i):Uu(a,o),i&&l&2048&&Ru(o.alternate,o);break;case 24:Hu(a,o,s,c,i),i&&l&2048&&zu(o.alternate,o);break;default:Hu(a,o,s,c,i)}t=t.sibling}}function Uu(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:Uu(n,r),i&2048&&Ru(r.alternate,r);break;case 24:Uu(n,r),i&2048&&zu(r.alternate,r);break;default:Uu(n,r)}t=t.sibling}}var Wu=8192;function Gu(e,t,n){if(e.subtreeFlags&Wu)for(e=e.child;e!==null;)Ku(e,t,n),e=e.sibling}function Ku(e,t,n){switch(e.tag){case 26:Gu(e,t,n),e.flags&Wu&&(e.memoizedState===null?(e=e.stateNode,(t&335544128)===t&&Zm(n,e)):Qm(n,ku,e.memoizedState,e.memoizedProps));break;case 5:Gu(e,t,n),e.flags&Wu&&(e=e.stateNode,(t&335544128)===t&&Zm(n,e));break;case 3:case 4:var r=ku;ku=bm(e.stateNode.containerInfo),Gu(e,t,n),ku=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Wu,Wu=16777216,Gu(e,t,n),Wu=r):Gu(e,t,n));break;case 30:if((e.flags&Wu)!==0&&(r=e.memoizedProps.name,r!=null&&r!==`auto`)){var i=e.stateNode;i.paired=null,Bl===null&&(Bl=new Map),Bl.set(r,i)}Gu(e,t,n);break;default:Gu(e,t,n)}}function qu(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Ju(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];cu=r,Zu(r,e)}qu(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Yu(e),e=e.sibling}function Yu(e){switch(e.tag){case 0:case 11:case 15:Ju(e),e.flags&2048&&Sl(9,e,e.return);break;case 3:Ju(e);break;case 12:Ju(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Xu(e)):Ju(e);break;default:Ju(e)}}function Xu(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];cu=r,Zu(r,e)}qu(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Sl(8,t,t.return),Xu(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Xu(t));break;default:Xu(t)}e=e.sibling}}function Zu(e,t){for(;cu!==null;){var n=cu;switch(n.tag){case 0:case 11:case 15:Sl(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:Ma(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,cu=r;else a:for(n=e;cu!==null;){r=cu;var i=r.sibling,a=r.return;if(yu(r),r===n){cu=null;break a}if(i!==null){i.return=a,cu=i;break a}cu=a}}}var Qu={getCacheForType:function(e){var t=wa(Aa),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return wa(Aa).controller.signal}},$u=typeof WeakMap==`function`?WeakMap:Map,K=0,q=null,J=null,Y=0,X=0,ed=null,td=!1,nd=!1,rd=!1,id=0,ad=0,od=0,sd=0,cd=0,ld=0,ud=0,dd=null,fd=null,pd=!1,md=0,hd=0,gd=1/0,_d=null,vd=null,yd=0,bd=null,xd=null,Sd=0,Cd=0,wd=null,Td=null,Ed=null,Dd=null,Od=null,kd=0,Ad=null;function jd(){return K&2&&Y!==0?Y&-Y:T.T===null?At():Pf()}function Md(){if(ld===0){if(!(Y&536870912)||V){var e=mt;mt<<=1,!(mt&3932160)&&(mt=262144),ld=e}else ld=536870912}return e=Ao.current,e!==null&&(e.flags|=32),ld}function Nd(e,t){if(t!=null){var n=e.stateNode,r=n.ref;r===null&&(r=n.ref=Pp(yi(e.memoizedProps,n))),Dd===null&&(Dd=[]),Dd.push(t.bind(null,r))}}function Pd(e,t,n){(e===q&&(X===2||X===9)||e.cancelPendingCommit!==null)&&(Vd(e,0),Rd(e,Y,ld,!1)),Ct(e,n),(!(K&2)||e!==q)&&(e===q&&(!(K&2)&&(sd|=n),ad===4&&Rd(e,Y,ld,!1)),Ef(e))}function Fd(e,t,n){if(K&6)throw Error(i(327));var r=!n&&!(t&127)&&(t&e.expiredLanes)===0||vt(e,t),a=r?Yd(e,t):qd(e,t,!0),o=r;do{if(a===0){nd&&!r&&Rd(e,t,0,!1);break}if(n=e.current.alternate,o&&!Ld(n)){a=qd(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=dd;var l=c.current.memoizedState.isDehydrated;if(l&&(Vd(c,s).flags|=256),s=qd(c,s,!1),s!==2&&s!==6){if(rd&&!l){c.errorRecoveryDisabledLanes|=o,sd|=o,a=4;break a}o=fd,fd=a,o!==null&&(fd===null?fd=o:fd.push.apply(fd,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){Vd(e,0),Rd(e,t,0,!0);break}a:{switch(r=e,o=a,o){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t&&(t&62914560)!==t)break;case 6:Rd(r,t,ld,!td);break a;case 2:fd=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=md+300-Ze(),10<a)){if(Rd(r,t,ld,!td),_t(r,0,!0)!==0)break a;Sd=t,r.timeoutHandle=gp(Id.bind(null,r,n,fd,_d,pd,t,ld,sd,ud,td,o,`Throttled`,-0,0),a);break a}Id(r,n,fd,_d,pd,t,ld,sd,ud,td,o,null,-0,0)}break}while(1);Ef(e)}function Id(e,t,n,r,i,a,o,s,c,l,u,d,f,p){e.timeoutHandle=-1;var m=t.subtreeFlags,h=(a&335544064)===a;if(d=null,(h||m&8192||(m&16785408)==16785408)&&(d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:kn},Bl=null,Ku(t,a,d),h&&(m=d,h=e.containerInfo,h=(h.nodeType===9?h:h.ownerDocument).__reactViewTransition,h!=null&&(m.count++,m.waitingForViewTransition=!0,m=nh.bind(m),h.finished.then(m,m))),m=(a&62914560)===a?md-Ze():(a&4194048)===a?hd-Ze():0,m=eh(d,m),m!==null)){Sd=a,e.cancelPendingCommit=m(nf.bind(null,e,t,a,n,r,i,o,s,c,l,u,d,null,f,p)),Rd(e,a,o,!l);return}nf(e,t,a,n,r,i,o,s,c,l,u,d)}function Ld(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!Wr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Rd(e,t,n,r){t=yt(e,t),t&=~cd,t&=~sd,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-lt(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&Tt(e,n,t)}function zd(){return K&6?!0:(Df(0,!1),!1)}function Bd(){if(J!==null){if(X===0)var e=J.return;else e=J,ga=ha=null,rs(e),io=null,ao=0,e=J;for(;e!==null;)bl(e.alternate,e),e=e.return;J=null}}function Vd(e,t){var n=e.timeoutHandle;return n!==-1&&(e.timeoutHandle=-1,_p(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),Sd=0,Bd(),q=e,J=n=R(e.current,null),Y=t,X=0,ed=null,td=!1,nd=vt(e,t),rd=!1,ud=ld=cd=sd=od=ad=0,fd=dd=null,pd=!1,id=yt(e,t),Ei(),n}function Hd(e,t){H=null,T.H=pc,t===Ja||t===Xa?(t=no(),X=3):t===Ya?(t=no(),X=4):X=t===jc?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,ed=t,J===null&&(ad=1,Tc(e,Ui(t,e.current)))}function Ud(){var e=Ao.current;return e===null?!0:(Y&4194048)===Y?jo===null:(Y&62914560)===Y||Y&536870912?e===jo:!1}function Wd(){var e=T.H;return T.H=pc,e===null?pc:e}function Gd(){var e=T.A;return T.A=Qu,e}function Kd(){ad=4,td||(Y&4194048)!==Y&&Ao.current!==null||(nd=!0),!(od&134217727)&&!(sd&134217727)||q===null||Rd(q,Y,ld,!1)}function qd(e,t,n){var r=K;K|=2;var i=Wd(),a=Gd();(q!==e||Y!==t)&&(_d=null,Vd(e,t)),t=!1;var o=ad;a:do try{if(X!==0&&J!==null){var s=J,c=ed;switch(X){case 8:Bd(),o=6;break a;case 3:case 2:case 9:case 6:Ao.current===null&&(t=!0);var l=X;if(X=0,ed=null,$d(e,s,c,l),n&&nd){o=0;break a}break;default:l=X,X=0,ed=null,$d(e,s,c,l)}}Jd(),o=ad;break}catch(t){Hd(e,t)}while(1);return t&&e.shellSuspendCounter++,ga=ha=null,K=r,T.H=i,T.A=a,J===null&&(q=null,Y=0,Ei()),o}function Jd(){for(;J!==null;)Zd(J)}function Yd(e,t){var n=K;K|=2;var r=Wd(),a=Gd();q!==e||Y!==t?(_d=null,gd=Ze()+500,Vd(e,t)):nd=vt(e,t);a:do try{if(X!==0&&J!==null){t=J;var o=ed;b:switch(X){case 1:X=0,ed=null,$d(e,t,o,1);break;case 2:case 9:if(Qa(o)){X=0,ed=null,Qd(t);break}t=function(){X!==2&&X!==9||q!==e||(X=7),Ef(e)},o.then(t,t);break a;case 3:X=7;break a;case 4:X=5;break a;case 7:Qa(o)?(X=0,ed=null,Qd(t)):(X=0,ed=null,$d(e,t,o,7));break;case 5:var s=null;switch(J.tag){case 26:s=J.memoizedState;case 5:case 27:var c=J;if(s?Ym(s):c.stateNode.complete){X=0,ed=null;var l=c.sibling;if(l!==null)J=l;else{var u=c.return;u===null?J=null:(J=u,ef(u))}break b}}X=0,ed=null,$d(e,t,o,5);break;case 6:X=0,ed=null,$d(e,t,o,6);break;case 8:Bd(),ad=6;break a;default:throw Error(i(462))}}Xd();break}catch(t){Hd(e,t)}while(1);return ga=ha=null,T.H=r,T.A=a,K=n,J===null?(q=null,Y=0,Ei(),ad):0}function Xd(){for(;J!==null&&!Ye();)Zd(J)}function Zd(e){var t=dl(e.alternate,e,id);e.memoizedProps=e.pendingProps,t===null?ef(e):J=t}function Qd(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=Gc(n,t,t.pendingProps,t.type,void 0,Y);break;case 11:t=Gc(n,t,t.pendingProps,t.type.render,t.ref,Y);break;case 5:rs(t);var r=t;r===z&&(V?(la(r),r.tag===5&&r.stateNode!=null&&(B=r.stateNode)):(la(r),V=!0));default:bl(n,t),t=J=Ii(t,id),t=dl(n,t,id)}e.memoizedProps=e.pendingProps,t===null?ef(e):J=t}function $d(e,t,n,r){ga=ha=null,rs(t),io=null,ao=0;var i=t.return;try{if(Ac(e,i,t,n,Y)){ad=1,Tc(e,Ui(n,e.current)),J=null;return}}catch(t){if(i!==null)throw J=i,t;ad=1,Tc(e,Ui(n,e.current)),J=null;return}t.flags&32768?(V||r===1?e=!0:nd||Y&536870912?e=!1:(td=e=!0,(r===2||r===9||r===3||r===6)&&(r=Ao.current,r!==null&&r.tag===13&&(r.flags|=16384))),tf(t,e)):ef(t)}function ef(e){var t=e;do{if(t.flags&32768){tf(t,td);return}e=t.return;var n=vl(t.alternate,t,id);if(n!==null){J=n;return}if(t=t.sibling,t!==null){J=t;return}J=t=e}while(t!==null);ad===0&&(ad=5)}function tf(e,t){do{var n=yl(e.alternate,e);if(n!==null){n.flags&=32767,J=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){J=e;return}J=e=n}while(e!==null);ad=6,J=null}function nf(e,t,n,r,a,o,s,c,l,u,d,f){e.cancelPendingCommit=null;do df();while(yd!==0);if(K&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));e===q&&(J=q=null,Y=0),xd=t,bd=e,Sd=n,wd=a,Td=r,rf(e,t,n,s,c,l,f)}}function rf(e,t,n,r,i,a,o){var s=t.lanes|t.childLanes;if(Cd=s,s|=Ti,wt(e,n,s,r,i,a),Dd=null,(n&335544064)===n?(Od=Fa(e),r=10262):(Od=null,r=10256),(t.subtreeFlags&r)!==0||(t.flags&r)!==0?(e.callbackNode=null,e.callbackPriority=0,yf(tt,function(){return ff(),null})):(e.callbackNode=null,e.callbackPriority=0),zl=!1,r=!!(t.flags&13878),t.subtreeFlags&13878||r){r=T.T,T.T=null,i=E.p,E.p=2,a=K,K|=4;try{pu(e,t,n)}finally{K=a,E.p=i,T.T=r}}yd=1,zl?Ed=Mp(o,e.containerInfo,Od,sf,cf,of,lf,ff,af,null,null):(sf(),cf(),lf())}function af(e){if(yd!==0){var t=bd.onRecoverableError;t(e,{componentStack:null})}}function of(){yd===3&&(yd=0,Pu(xd,bd),yd=4)}function sf(){if(yd===1){yd=0;var e=bd,t=xd,n=Sd,r=!!(t.flags&13878);if(t.subtreeFlags&13878||r){r=T.T,T.T=null;var i=E.p;E.p=2;var a=K;K|=4;try{uu=du=!1,Au(t,e,n),n=cp;var o=Xr(e.containerInfo),s=n.focusedElem,c=n.selectionRange;if(o!==s&&s&&s.ownerDocument&&Yr(s.ownerDocument.documentElement,s)){if(c!==null&&Zr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=Jr(s,h),v=Jr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}gh=!!sp,cp=sp=null}finally{K=a,E.p=i,T.T=r}}e.current=t,yd=2}}function cf(){if(yd===2){yd=0;var e=bd,t=xd,n=!!(t.flags&8772);if(t.subtreeFlags&8772||n){n=T.T,T.T=null;var r=E.p;E.p=2;var i=K;K|=4;try{hu(e,t.alternate,t)}finally{K=i,E.p=r,T.T=n}}yd=3}}function lf(){if(yd===4||yd===3){yd=0;var e=Ed;Ed=null,Xe();var t=bd,n=xd,r=Sd,i=Td,a=(r&335544064)===r?10262:10256;if((n.subtreeFlags&a)!==0||(n.flags&a)!==0?yd=5:(yd=0,xd=bd=null,uf(t,t.pendingLanes)),a=t.pendingLanes,a===0&&(vd=null),kt(r),n=n.stateNode,st&&typeof st.onCommitFiberRoot==`function`)try{st.onCommitFiberRoot(ot,n,void 0,(n.current.flags&128)==128)}catch{}if(i!==null){n=T.T,a=E.p,E.p=2,T.T=null;try{for(var o=t.onRecoverableError,s=0;s<i.length;s++){var c=i[s];o(c.value,{componentStack:c.stack})}}finally{T.T=n,E.p=a}}if(i=Dd,o=Od,Od=null,i!==null&&(Dd=null,o===null&&(o=[]),e!==null))for(c=0;c<i.length;c++)n=(0,i[c])(o),n!==void 0&&e.finished.finally(n);Sd&3&&df(),Ef(t),a=t.pendingLanes,r&261930&&a&42?t===Ad?kd++:(kd=0,Ad=t):(kd=0,Ad=null),Df(0,!1)}}function uf(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,Ma(t)))}function df(){return Ed!==null&&(Ed.skipTransition(),Ed=null),sf(),cf(),lf(),ff()}function ff(){if(yd!==5)return!1;var e=bd,t=Cd;Cd=0;var n=kt(Sd),r=T.T,a=E.p;try{E.p=32>n?32:n,T.T=null,n=wd,wd=null;var o=bd,s=Sd;if(yd=0,xd=bd=null,Sd=0,K&6)throw Error(i(331));var c=K;if(K|=4,Yu(o.current),Vu(o,o.current,s,n),K=c,Df(0,!1),st&&typeof st.onPostCommitFiberRoot==`function`)try{st.onPostCommitFiberRoot(ot,o)}catch{}return!0}finally{E.p=a,T.T=r,uf(e,t)}}function pf(e,t,n){t=Ui(n,t),t=Dc(e.stateNode,t,2),e=_o(e,t,2),e!==null&&(Ct(e,2),Ef(e))}function Z(e,t,n){if(e.tag===3)pf(e,e,n);else for(;t!==null;){if(t.tag===3){pf(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(vd===null||!vd.has(r))){e=Ui(n,e),n=Oc(2),r=_o(t,n,2),r!==null&&(kc(n,r,t,e),Ct(r,2),Ef(r));break}}t=t.return}}function mf(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new $u;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(rd=!0,i.add(n),e=hf.bind(null,e,t,n),t.then(e,e))}function hf(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,q===e&&(Y&n)===n&&(ad===4||ad===3&&(Y&62914560)===Y&&300>Ze()-md?K&2?cd|=n:Vd(e,0):cd|=n,ud===Y&&(ud=0)),Ef(e)}function gf(e,t){t===0&&(t=xt()),e=ki(e,t),e!==null&&(Ct(e,t),Ef(e))}function _f(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),gf(e,n)}function vf(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),gf(e,n)}function yf(e,t){return qe(e,t)}var bf=null,xf=null,Sf=!1,Cf=!1,wf=!1,Tf=0;function Ef(e){e!==xf&&e.next===null&&(xf===null?bf=xf=e:xf=xf.next=e),Cf=!0,Sf||(Sf=!0,Nf())}function Df(e,t){if(!wf&&Cf){wf=!0;do for(var n=!1,r=bf;r!==null;){if(!t){if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-lt(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,Mf(r,a))}else a=Y,a=_t(r,r===q?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||vt(r,a)||(n=!0,Mf(r,a))}r=r.next}while(n);wf=!1}}function Of(){kf()}function kf(){Cf=Sf=!1;var e=0;Tf!==0&&hp()&&(e=Tf);for(var t=Ze(),n=null,r=bf;r!==null;){var i=r.next,a=Af(r,t);a===0?(r.next=null,n===null?bf=i:n.next=i,i===null&&(xf=n)):(n=r,(e!==0||a&3)&&(Cf=!0)),r=i}yd!==0&&yd!==5||Df(e,!1),Tf!==0&&(Tf=0)}function Af(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-lt(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=bt(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=q,n=Y,n=_t(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(X===2||X===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&Je(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||vt(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&Je(r),kt(n)){case 2:case 8:n=et;break;case 32:n=tt;break;case 268435456:n=rt;break;default:n=tt}return r=jf.bind(null,e),n=qe(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&Je(r),e.callbackPriority=2,e.callbackNode=null,2}function jf(e,t){if(yd!==0&&yd!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(df()&&e.callbackNode!==n)return null;var r=Y;return r=_t(e,e===q?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(Fd(e,r,t),Af(e,Ze()),e.callbackNode!=null&&e.callbackNode===n?jf.bind(null,e):null)}function Mf(e,t){if(df())return null;Fd(e,t,!0)}function Nf(){bp(function(){K&6?qe($e,Of):kf()})}function Pf(){if(Tf===0){var e=Ra;e===0&&(e=pt,pt<<=1,!(pt&261888)&&(pt=256)),Tf=e}return Tf}function Ff(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:On(e)}function If(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=Ff((i[Pt]||null).action),o=r.submitter;o&&(t=(t=o[Pt]||null)?Ff(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new Xn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(Tf!==0){var e=new FormData(i,o);$s(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=new FormData(i,o),$s(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var Lf=0;Lf<gi.length;Lf++){var Rf=gi[Lf];_i(Rf.toLowerCase(),`on`+(Rf[0].toUpperCase()+Rf.slice(1)))}_i(L,`onAnimationEnd`),_i(li,`onAnimationIteration`),_i(ui,`onAnimationStart`),_i(`dblclick`,`onDoubleClick`),_i(`focusin`,`onFocus`),_i(`focusout`,`onBlur`),_i(di,`onTransitionRun`),_i(fi,`onTransitionStart`),_i(pi,`onTransitionCancel`),_i(mi,`onTransitionEnd`),Qt(`onMouseEnter`,[`mouseout`,`mouseover`]),Qt(`onMouseLeave`,[`mouseout`,`mouseover`]),Qt(`onPointerEnter`,[`pointerout`,`pointerover`]),Qt(`onPointerLeave`,[`pointerout`,`pointerover`]),Zt(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),Zt(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),Zt(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),Zt(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),Zt(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),Zt(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var zf=`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(` `),Bf=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(zf));function Vf(e,t){t=!!(t&4);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Si(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Si(e)}i.currentTarget=null,a=c}}}}function Q(e,t){var n=t[It];n===void 0&&(n=t[It]=new Set);var r=e+`__bubble`;n.has(r)||(Gf(t,e,2,!1),n.add(r))}function Hf(e,t,n){var r=0;t&&(r|=4),Gf(n,e,r,t)}var Uf=`_reactListening`+Math.random().toString(36).slice(2);function Wf(e){if(!e[Uf]){e[Uf]=!0,Yt.forEach(function(t){t!==`selectionchange`&&(Bf.has(t)||Hf(t,!1,e),Hf(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Uf]||(t[Uf]=!0,Hf(`selectionchange`,!1,t))}}function Gf(e,t,n,r){switch(Ch(t)){case 2:var i=_h;break;case 8:i=vh;break;default:i=yh}n=i.bind(null,t,n,e),i=void 0,!zn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Kf(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var c=r.stateNode.containerInfo;if(c===i)break;if(s===4)for(s=r.return;s!==null;){var l=s.tag;if((l===3||l===4)&&s.stateNode.containerInfo===i)return;s=s.return}for(;c!==null;){if(s=Ut(c),s===null)return;if(l=s.tag,l===5||l===6||l===26||l===27){r=a=s;continue a}c=c.parentNode}}r=r.return}In(function(){var r=a,i=jn(n),s=[];a:{var c=hi.get(e);if(c!==void 0){var l=Xn,u=e;switch(e){case`keypress`:if(Gn(n)===0)break a;case`keydown`:case`keyup`:l=lr;break;case`focusin`:u=`focus`,l=rr;break;case`focusout`:u=`blur`,l=rr;break;case`beforeblur`:case`afterblur`:l=rr;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=k;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=A;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=dr;break;case L:case li:case ui:l=j;break;case mi:l=fr;break;case`scroll`:case`scrollend`:l=Qn;break;case`wheel`:l=F;break;case`copy`:case`cut`:case`paste`:l=ir;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=P;break;case`submit`:l=ur;break;case`toggle`:case`beforetoggle`:l=pr}var d=!!(t&4),f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=Ln(m,p),g!=null&&d.push(qf(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),s.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(l=e===`mouseover`||e===`pointerover`,c=e===`mouseout`||e===`pointerout`,l&&n!==An&&(u=n.relatedTarget||n.fromElement)&&(Ut(u)||u[Ft]))break a;(c||l)&&(u=i.window===i?i:(l=i.ownerDocument)?l.defaultView||l.parentWindow:window,c?(l=n.relatedTarget||n.toElement,c=r,l=l?Ut(l):null,l!==null&&(f=o(l),d=l.tag,l!==f||d!==5&&d!==27&&d!==6)&&(l=null)):(c=null,l=r),c!==l&&(d=k,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=P,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=c==null?u:Gt(c),h=l==null?u:Gt(l),u=new d(g,m+`leave`,c,n,i),u.target=f,u.relatedTarget=h,g=null,Ut(i)===r&&(d=new d(p,m+`enter`,l,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,d=c&&l?re(c,l,Yf):null,c!==null&&Xf(s,u,c,d,!1),l!==null&&f!==null&&Xf(s,f,l,d,!0)))}a:{if(c=r?Gt(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var _=I;else if(Dr(c)){if(Nr)_=Hr;else{_=Br;var v=zr}}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&Tn(r.elementType)&&(_=I):_=Vr;if(_&&=_(e,r)){Or(s,_,n,i);break a}v&&v(e,c,r)}switch(v=r?Gt(r):window,e){case`focusin`:(Dr(v)||v.contentEditable===`true`)&&($r=v,ei=r,ti=null);break;case`focusout`:ti=ei=$r=null;break;case`mousedown`:ni=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:ni=!1,ri(s,n,i);break;case`selectionchange`:if(Qr)break;case`keydown`:case`keyup`:ri(s,n,i)}var y;if(hr)b:{switch(e){case`compositionstart`:var b=`onCompositionStart`;break b;case`compositionend`:b=`onCompositionEnd`;break b;case`compositionupdate`:b=`onCompositionUpdate`;break b}b=void 0}else Cr?xr(e,n)&&(b=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(b=`onCompositionStart`);b&&(vr&&n.locale!==`ko`&&(Cr||b!==`onCompositionStart`?b===`onCompositionEnd`&&Cr&&(y=Wn()):(Vn=i,Hn=`value`in Vn?Vn.value:Vn.textContent,Cr=!0)),v=Jf(r,b),0<v.length&&(b=new ar(b,e,null,n,i),s.push({event:b,listeners:v}),y?b.data=y:(y=Sr(n),y!==null&&(b.data=y)))),(y=_r?wr(e,n):Tr(e,n))&&(b=Jf(r,`onBeforeInput`),0<b.length&&(v=new ar(`onBeforeInput`,`beforeinput`,null,n,i),s.push({event:v,listeners:b}),v.data=y)),If(s,e,r,n,i)}Vf(s,t)})}function qf(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Jf(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=Ln(e,n),i!=null&&r.unshift(qf(e,i,a)),i=Ln(e,t),i!=null&&r.push(qf(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Yf(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Xf(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=Ln(n,a),l!=null&&o.unshift(qf(n,l,c))):i||(l=Ln(n,a),l!=null&&o.push(qf(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Zf=/\r\n?/g,Qf=/\u0000|\uFFFD/g;function $f(e){return(typeof e==`string`?e:``+e).replace(Zf,`
9
+ `).replace(Qf,``)}function ep(e,t){return t=$f(t),$f(e)===t}function $(e,t,n,r,a,o){switch(n){case`children`:if(typeof r==`string`)t===`body`||t===`textarea`&&r===``||xn(e,r);else if(typeof r==`number`||typeof r==`bigint`)t!==`body`&&xn(e,``+r);else return;break;case`className`:on(e,`class`,r);break;case`tabIndex`:on(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:on(e,n,r);break;case`style`:wn(e,r,o);return;case`data`:if(t!==`object`){on(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=On(r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`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}if(typeof o==`function`&&(n===`formAction`?(t!==`input`&&$(e,t,`name`,a.name,a,null),$(e,t,`formEncType`,a.formEncType,a,null),$(e,t,`formMethod`,a.formMethod,a,null),$(e,t,`formTarget`,a.formTarget,a,null)):($(e,t,`encType`,a.encType,a,null),$(e,t,`method`,a.method,a,null),$(e,t,`target`,a.target,a,null))),r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=On(r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=kn);return;case`onScroll`:r!=null&&Q(`scroll`,e);return;case`onScrollEnd`:r!=null&&Q(`scrollend`,e);return;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));o?.__html!==n&&(e.innerHTML=n)}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=On(r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`credentialless`: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`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:Q(`beforetoggle`,e),Q(`toggle`,e),an(e,`popover`,r);break;case`xlinkActuate`:sn(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:sn(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:sn(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:sn(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:sn(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:sn(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:sn(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:sn(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:sn(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:an(e,`is`,r);break;case`innerText`:case`textContent`:return;default:if(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)n=En.get(n)||n,an(e,n,r);else return}O=!0}function tp(e,t,n,r,a,o){switch(n){case`style`:wn(e,r,o);return;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));o?.__html!==n&&(e.innerHTML=n)}}break;case`children`:if(typeof r==`string`)xn(e,r);else if(typeof r==`number`||typeof r==`bigint`)xn(e,``+r);else return;break;case`onScroll`:r!=null&&Q(`scroll`,e);return;case`onScrollEnd`:r!=null&&Q(`scrollend`,e);return;case`onClick`:r!=null&&(e.onclick=kn);return;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:return;case`innerText`:case`textContent`:return;default:if(!Xt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),o=n.slice(2,a?n.length-7:void 0),t=e[Pt]||null,t=t==null?null:t[n],typeof t==`function`&&e.removeEventListener(o,t,a),typeof r==`function`)){typeof t!=`function`&&t!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(o,r,a);break a}O=!0,n in e?e[n]=r:!0===r?e.setAttribute(n,``):an(e,n,r)}return}O=!0}function np(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:Q(`error`,e),Q(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:$(e,t,o,s,n,null)}}a&&$(e,t,`srcSet`,n.srcSet,n,null),r&&$(e,t,`src`,n.src,n,null);return;case`input`:Q(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:$(e,t,r,d,n,null)}}gn(e,o,c,l,u,s,a,!1);return;case`select`:for(a in Q(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:$(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&vn(e,!!r,n,!0):vn(e,!!r,t,!1);return;case`textarea`:for(s in Q(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:$(e,t,s,c,n,null)}bn(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:$(e,t,l,r,n,null)}return;case`dialog`:Q(`beforetoggle`,e),Q(`toggle`,e),Q(`cancel`,e),Q(`close`,e);break;case`iframe`:case`object`:Q(`load`,e);break;case`video`:case`audio`:for(r=0;r<zf.length;r++)Q(zf[r],e);break;case`image`:Q(`error`,e),Q(`load`,e);break;case`details`:Q(`toggle`,e);break;case`embed`:case`source`:case`link`:Q(`error`,e),Q(`load`,e);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 n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:$(e,t,u,r,n,null)}return;default:if(Tn(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&tp(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&$(e,t,c,r,n,null))}var rp={};function ip(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||$(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:m!==f&&(O=!0),o=m;break;case`name`:m!==f&&(O=!0),a=m;break;case`checked`:m!==f&&(O=!0),u=m;break;case`defaultChecked`:m!==f&&(O=!0),d=m;break;case`value`:m!==f&&(O=!0),s=m;break;case`defaultValue`:m!==f&&(O=!0),c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&$(e,t,p,m,r,f)}}hn(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||$(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:o!==l&&(O=!0),p=o;break;case`defaultValue`:o!==l&&(O=!0),c=o;break;case`multiple`:o!==l&&(O=!0),s=o;default:o!==l&&$(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?vn(e,!!n,n?[]:``,!1):vn(e,!!n,t,!0)):vn(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:$(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:a!==o&&(O=!0),p=a;break;case`defaultValue`:a!==o&&(O=!0),m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&$(e,t,s,a,r,o)}yn(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:$(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:p!==m&&(O=!0),e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:$(e,t,l,p,r,m)}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 g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&$(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:$(e,t,u,p,r,m)}return;default:if(Tn(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&tp(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||tp(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&$(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||$(e,t,f,p,r,m)}function ap(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function op(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&ap(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&ap(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var sp=null,cp=null;function lp(e){return e.nodeType===9?e:e.ownerDocument}function up(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function dp(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function fp(e,t,n,r){return n=lp(n).createElement(e),n[Nt]=r,n[Pt]=t,np(n,e,t),qt(n),n}function pp(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var mp=null;function hp(){var e=window.event;return e&&e.type===`popstate`?e!==mp&&(mp=e,!0):(mp=null,!1)}var gp=typeof setTimeout==`function`?setTimeout:void 0,_p=typeof clearTimeout==`function`?clearTimeout:void 0,vp=typeof Promise==`function`?Promise:void 0,yp=typeof requestAnimationFrame==`function`?requestAnimationFrame:gp,bp=typeof queueMicrotask==`function`?queueMicrotask:vp===void 0?gp:function(e){return vp.resolve(null).then(e).catch(xp)};function xp(e){setTimeout(function(){throw e})}function Sp(e){return e===`head`}function Cp(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8){if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Hh(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)_m(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,_m(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[Bt]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&_m(e.ownerDocument.body)}n=i}while(n);Hh(t)}function wp(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8){if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++}n=r}while(n)}function Tp(e,t,n){if(t=CSS.escape(t)===t?t:`r-`+btoa(t).replace(/=/g,``),e.style.viewTransitionName=t,n!=null&&(e.style.viewTransitionClass=n),n=getComputedStyle(e),n.display===`inline`){if(t=e.getClientRects(),t.length===1)var r=1;else for(var i=r=0;i<t.length;i++){var a=t[i];0<a.width&&0<a.height&&r++}r===1&&(e=e.style,e.display=t.length===1?`inline-block`:`block`,e.marginTop=`-`+n.paddingTop,e.marginBottom=`-`+n.paddingBottom)}}function Ep(e,t){e=e.style,t=t.style;var n=t==null?null:t.hasOwnProperty(`viewTransitionName`)?t.viewTransitionName:t.hasOwnProperty(`view-transition-name`)?t[`view-transition-name`]:null;e.viewTransitionName=n==null||typeof n==`boolean`?``:(``+n).trim(),n=t==null?null:t.hasOwnProperty(`viewTransitionClass`)?t.viewTransitionClass:t.hasOwnProperty(`view-transition-class`)?t[`view-transition-class`]:null,e.viewTransitionClass=n==null||typeof n==`boolean`?``:(``+n).trim(),e.display===`inline-block`&&(t==null?e.display=e.margin=``:(n=t.display,e.display=n==null||typeof n==`boolean`?``:n,n=t.margin,n==null?(n=t.hasOwnProperty(`marginTop`)?t.marginTop:t[`margin-top`],e.marginTop=n==null||typeof n==`boolean`?``:n,t=t.hasOwnProperty(`marginBottom`)?t.marginBottom:t[`margin-bottom`],e.marginBottom=t==null||typeof t==`boolean`?``:t):e.margin=n))}function Dp(e,t,n){return n=n.ownerDocument.defaultView,{rect:e,abs:t.position===`absolute`||t.position===`fixed`,clip:t.clipPath!==`none`||t.overflow!==`visible`||t.filter!==`none`||t.mask!==`none`||t.mask!==`none`||t.borderRadius!==`0px`,view:0<=e.bottom&&0<=e.right&&e.top<=n.innerHeight&&e.left<=n.innerWidth}}function Op(e){return Dp(e.getBoundingClientRect(),getComputedStyle(e),e)}function kp(e){var t=e.getBoundingClientRect();t=new DOMRect(t.x+2e4,t.y+2e4,t.width,t.height);var n=getComputedStyle(e);return Dp(t,n,e)}function Ap(e){return e.documentElement.clientHeight}function jp(e){this.addEventListener(`load`,e),this.addEventListener(`error`,e)}function Mp(e,t,n,r,i,a,o,s,c){var l=t.nodeType===9?t:t.ownerDocument;try{var u=l.startViewTransition({update:function(){var t=l.defaultView,n=t.navigation&&t.navigation.transition,o=l.fonts.status;r();var s=[];if(o===`loaded`&&(Ap(l),l.fonts.status===`loading`&&s.push(l.fonts.ready)),o=s.length,e!==null)for(var c=e.suspenseyImages,u=0,d=0;d<c.length;d++){var f=c[d];if(!f.complete){var p=f.getBoundingClientRect();if(0<p.bottom&&0<p.right&&p.top<t.innerHeight&&p.left<t.innerWidth){if(u+=Xm(f),u>$m){s.length=o;break}f=new Promise(jp.bind(f)),s.push(f)}}}if(0<s.length)return t=Promise.race([Promise.all(s),new Promise(function(e){return setTimeout(e,500)})]).then(i,i),(n?Promise.allSettled([n.finished,t]):t).then(a,a);if(i(),n)return n.finished.then(a,a);a()},types:n});l.__reactViewTransition=u;var d=[];return u.ready.then(function(){for(var e=l.documentElement.getAnimations({subtree:!0}),t=0;t<e.length;t++){var n=e[t],r=n.effect,i=r.pseudoElement;if(i!=null&&i.startsWith(`::view-transition`)){d.push(n),n=r.getKeyframes();for(var a=i=void 0,s=!0,c=0;c<n.length;c++){var u=n[c],f=u.width;if(i===void 0)i=f;else if(i!==f){s=!1;break}if(f=u.height,a===void 0)a=f;else if(a!==f){s=!1;break}delete u.width,delete u.height,u.transform===`none`&&delete u.transform}s&&i!==void 0&&a!==void 0&&(r.setKeyframes(n),s=getComputedStyle(r.target,r.pseudoElement),s.width!==i||s.height!==a)&&(s=n[0],s.width=i,s.height=a,s=n[n.length-1],s.width=i,s.height=a,r.setKeyframes(n))}}o()},function(e){l.__reactViewTransition===u&&(l.__reactViewTransition=null);try{if(typeof e==`object`&&e)switch(e.name){case`InvalidStateError`:(e.message===`View transition was skipped because document visibility state is hidden.`||e.message===`Skipping view transition because document visibility state has become hidden.`||e.message===`Skipping view transition because viewport size changed.`||e.message===`Transition was aborted because of invalid state`)&&(e=null)}e!==null&&c(e)}finally{r(),i(),o()}}),u.finished.finally(function(){for(var e=0;e<d.length;e++)d[e].cancel();l.__reactViewTransition===u&&(l.__reactViewTransition=null),s()}),u}catch{return r(),i(),o(),null}}function Np(e,t){this._scope=document.documentElement,this._selector=`::view-transition-`+e+`(`+t+`)`}Np.prototype.animate=function(e,t){return t=typeof t==`number`?{duration:t}:C({},t),t.pseudoElement=this._selector,this._scope.animate(e,t)},Np.prototype.getAnimations=function(){for(var e=this._scope,t=this._selector,n=e.getAnimations({subtree:!0}),r=[],i=0;i<n.length;i++){var a=n[i].effect;a!==null&&a.target===e&&a.pseudoElement===t&&r.push(n[i])}return r},Np.prototype.getComputedStyle=function(){return getComputedStyle(this._scope,this._selector)};function Pp(e){return{name:e,group:new Np(`group`,e),imagePair:new Np(`image-pair`,e),old:new Np(`old`,e),new:new Np(`new`,e)}}function Fp(e){this._fragmentFiber=e,this._observers=this._eventListeners=null}Fp.prototype.addEventListener=function(e,t,n){var r=null,i=null;if(!(n!=null&&typeof n!=`boolean`&&(r=n.signal||null,r!==null&&r.aborted))){this._eventListeners===null&&(this._eventListeners=[]);var a=this._eventListeners;if(Bp(a,e,t,n)===-1){var o=this,s=t;n!=null&&typeof n!=`boolean`&&!0===n.once&&(s=function(r){o.removeEventListener(e,t,n),typeof t==`function`?t.call(this,r):t.handleEvent(r)}),r!==null&&(i=o.removeEventListener.bind(o,e,t,n),r.addEventListener(`abort`,i,{once:!0}),i=r.removeEventListener.bind(r,`abort`,i)),r=Rp(n),a.push({type:e,listener:t,optionsOrUseCapture:n,attachedListener:s,cleanup:i}),m(this._fragmentFiber.child,!1,Ip,e,s,r)}this._eventListeners=a}};function Ip(e,t,n,r){return b(e).addEventListener(t,n,r),!1}Fp.prototype.removeEventListener=function(e,t,n){var r=this._eventListeners;if(r!==null&&(t=Bp(r,e,t,n),t!==-1)){var i=r[t];n=i.attachedListener;var a=i.cleanup;i=Rp(i.optionsOrUseCapture),m(this._fragmentFiber.child,!1,Lp,e,n,i),r.splice(t,1),a!==null&&a()}};function Lp(e,t,n,r){return b(e).removeEventListener(t,n,r),!1}function Rp(e){return e!=null&&typeof e!=`boolean`&&(!0===e.once||e.signal instanceof AbortSignal)?{capture:e.capture,passive:e.passive}:e}function zp(e){return e==null?`c=0`:typeof e==`boolean`?`c=`+(e?`1`:`0`):`c=`+(e.capture?`1`:`0`)}function Bp(e,t,n,r){if(e.length===0)return-1;r=zp(r);for(var i=0;i<e.length;i++){var a=e[i];if(a.type===t&&a.listener===n&&zp(a.optionsOrUseCapture)===r)return i}return-1}Fp.prototype.dispatchEvent=function(e){var t=g(this._fragmentFiber);if(t===null)return!0;t=b(t);var n=this._eventListeners;if(n!==null&&0<n.length||!e.bubbles){var r=t.nodeType===9?t.createComment(``):document.createTextNode(``);if(n)for(var i=0;i<n.length;i++){var a=n[i];r.addEventListener(a.type,a.attachedListener,Rp(a.optionsOrUseCapture))}if(t.appendChild(r),e=r.dispatchEvent(e),n)for(i=0;i<n.length;i++)a=n[i],r.removeEventListener(a.type,a.attachedListener,Rp(a.optionsOrUseCapture));return t.removeChild(r),e}return t.dispatchEvent(e)},Fp.prototype.focus=function(e){m(this._fragmentFiber.child,!0,Vp,e,void 0,void 0)};function Vp(e,t){return e.tag!==6&&(e=b(e),pm(e,t))}Fp.prototype.focusLast=function(e){var t=[];m(this._fragmentFiber.child,!0,Hp,t,void 0,void 0);for(var n=t.length-1;0<=n&&!Vp(t[n],e);n--);};function Hp(e,t){return t.push(e),!1}Fp.prototype.blur=function(){var e=g(this._fragmentFiber);e!==null&&(e=b(e),e=lp(e).activeElement,e!==null&&m(this._fragmentFiber.child,!1,Up,e,void 0,void 0))};function Up(e,t){return e.tag!==6&&(e=b(e),e===t||e.contains(t)?(t.blur(),!0):!1)}Fp.prototype.observeUsing=function(e){this._observers===null&&(this._observers=new Set),this._observers.add(e),m(this._fragmentFiber.child,!1,Wp,e,void 0,void 0)};function Wp(e,t){return e.tag!==6&&(e=b(e),t.observe(e),!1)}Fp.prototype.unobserveUsing=function(e){var t=this._observers;if(t!==null&&t.has(e)){t.delete(e),m(this._fragmentFiber.child,!1,Gp,e,void 0,void 0);for(var n=t=0;n<Kp.length;n++){var r=Kp[n];r.fragmentInstance===this&&r.observer===e?e.unobserve(r.instance):Kp[t++]=r}Kp.length=t}};function Gp(e,t){return e.tag!==6&&(e=b(e),t.unobserve(e),!1)}var Kp=[],qp=!1;function Jp(e,t,n){Kp.push({fragmentInstance:e,observer:t,instance:n}),qp||(qp=!0,mm(function(){qp=!1;var e=Kp;Kp=[];for(var t=0;t<e.length;t++){var n=e[t];n.observer.unobserve(n.instance)}}))}Fp.prototype.getClientRects=function(){var e=[];return m(this._fragmentFiber.child,!1,Yp,e,void 0,void 0),e};function Yp(e,t){if(e.tag===6){e=e.stateNode;var n=e.ownerDocument.createRange();n.selectNodeContents(e),t.push.apply(t,n.getClientRects())}else e=b(e),t.push.apply(t,e.getClientRects());return!1}Fp.prototype.getRootNode=function(e){var t=g(this._fragmentFiber);return t===null?this:b(t).getRootNode(e)},Fp.prototype.compareDocumentPosition=function(e){var t=g(this._fragmentFiber);if(t===null)return Node.DOCUMENT_POSITION_DISCONNECTED;var n=[];m(this._fragmentFiber.child,!1,Hp,n,void 0,void 0);var r=b(t);if(n.length===0){if(n=r,_(this._fragmentFiber)){a:{for(t=this._fragmentFiber.return;t!==null;){if(t.tag===4){t=t.stateNode.containerInfo;break a}if(t.tag===3||t.tag===5||t.tag===27)break;t=t.return}t=null}t!=null&&(n=t)}t=this._fragmentFiber;var i=r=n.compareDocumentPosition(e);return n===e?i=Node.DOCUMENT_POSITION_CONTAINS:r&Node.DOCUMENT_POSITION_CONTAINED_BY&&(n=v(t)[1],n===null?i=Node.DOCUMENT_POSITION_PRECEDING:(e=b(n).compareDocumentPosition(e),i=e===0||e&Node.DOCUMENT_POSITION_FOLLOWING?Node.DOCUMENT_POSITION_FOLLOWING:Node.DOCUMENT_POSITION_PRECEDING)),i|=Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC}t=b(n[0]),i=b(n[n.length-1]);var a=_(this._fragmentFiber)?t.parentElement:r;if(a==null)return Node.DOCUMENT_POSITION_DISCONNECTED;r=a.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY,a=a.compareDocumentPosition(i)&Node.DOCUMENT_POSITION_CONTAINED_BY;var o=t.compareDocumentPosition(e),s=i.compareDocumentPosition(e),c=o&Node.DOCUMENT_POSITION_CONTAINED_BY||s&Node.DOCUMENT_POSITION_CONTAINED_BY;return s=r&&a&&o&Node.DOCUMENT_POSITION_FOLLOWING&&s&Node.DOCUMENT_POSITION_PRECEDING,t=r&&t===e||a&&i===e||c||s?Node.DOCUMENT_POSITION_CONTAINED_BY:!r&&t===e||!a&&i===e?Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:o,t&Node.DOCUMENT_POSITION_DISCONNECTED||t&Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC||Xp(t,this._fragmentFiber,n[0],n[n.length-1],e)?t:Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC};function Xp(e,t,n,r,i){var a=Ut(i);if(e&Node.DOCUMENT_POSITION_CONTAINED_BY){if(n=!!a)a:{for(;a!==null;){if(a.tag===7&&(a===t||a.alternate===t)){n=!0;break a}a=a.return}n=!1}return n}if(e&Node.DOCUMENT_POSITION_CONTAINS){if(a===null)return a=i.ownerDocument,i===a||i===a.documentElement||i===a.body;a:{for(a=t,t=g(t);a!==null;){if(!(a.tag!==5&&a.tag!==3&&a.tag!==27||a!==t&&a.alternate!==t)){a=!0;break a}a=a.return}a=!1}return a}return e&Node.DOCUMENT_POSITION_PRECEDING?((t=!!a)&&!(t=a===n)&&(t=re(n,a,S),t===null?t=!1:(m(t,!0,te,a,n),a=x,x=null,t=a!==null)),t):e&Node.DOCUMENT_POSITION_FOLLOWING?((t=!!a)&&!(t=a===r)&&(t=re(r,a,S),t===null?t=!1:(m(t,!0,ne,a,r),a=x,ee=x=null,t=a!==null)),t):!1}function Zp(e,t){var n=e.ownerDocument.createRange();n.selectNodeContents(e),e=n.getBoundingClientRect(),window.scrollTo(window.scrollX+e.left,t?window.scrollY+e.top:window.scrollY+e.bottom-window.innerHeight)}Fp.prototype.scrollIntoView=function(e){if(typeof e==`object`)throw Error(i(566));var t=[];m(this._fragmentFiber.child,!1,Hp,t,void 0,void 0);var n=!1!==e;if(t.length===0){var r=v(this._fragmentFiber);if(r=n?r[1]||r[0]||g(this._fragmentFiber):r[0]||r[1],r===null)return;if(r.tag===6){e=b(r),Zp(e,n);return}if(r=b(r),r.nodeType!==9){if(r.nodeType===11){n=`host`in r?r.host:null,n!==null&&n.scrollIntoView(e);return}r.scrollIntoView(e)}}for(r=n?t.length-1:0;r!==(n?-1:t.length);){var a=t[r];a.tag===6?(a=b(a),Zp(a,n)):b(a).scrollIntoView(e),r+=n?-1:1}};function Qp(e,t){return e=b(e),$p(e,t),!1}function $p(e,t){e.reactFragments??=new Set,e.reactFragments.add(t)}function em(e,t){var n=t._eventListeners;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];e.addEventListener(i.type,i.attachedListener,Rp(i.optionsOrUseCapture))}e.nodeType!==3&&(n=t._observers,n!==null&&n.forEach(function(n){for(var r=0,i=0;i<Kp.length;i++){var a=Kp[i];(a.fragmentInstance!==t||a.observer!==n||a.instance!==e)&&(Kp[r++]=a)}Kp.length=r,n.observe(e)}),$p(e,t))}function tm(e,t){var n=t._eventListeners;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];e.removeEventListener(i.type,i.attachedListener,Rp(i.optionsOrUseCapture))}e.nodeType!==3&&(n=t._observers,n!==null&&n.forEach(function(n){typeof n.rootMargin==`string`?Jp(t,n,e):n.unobserve(e)}),e.reactFragments!=null&&e.reactFragments.delete(t))}function nm(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:nm(n),Ht(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function rm(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r){if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e}else if(!e[Bt])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=lm(e.nextSibling),e===null)break}return null}function im(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=lm(e.nextSibling),e===null))return null;return e}function am(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=lm(e.nextSibling),e===null))return null;return e}function om(e){return e.data===`$?`||e.data===`$~`}function sm(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function cm(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function lm(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var um=null;function dm(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return lm(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function fm(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function pm(e,t){function n(){r=!0}if(e.ownerDocument.activeElement===e)return!0;var r=!1;try{e.ownerDocument.addEventListener(`focus`,n,!0),(e.focus||HTMLElement.prototype.focus).call(e,t)}finally{e.ownerDocument.removeEventListener(`focus`,n,!0)}return r}function mm(e){yp(function(){yp(function(t){return e(t)})})}function hm(e,t,n){switch(t=lp(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function gm(e,t,n){for(var r in n){var i=n[r];n.hasOwnProperty(r)&&i!=null&&$(e,t,r,null,rp,i)}n.dangerouslySetInnerHTML!=null&&(e.textContent=``),e.onclick===kn&&(e.onclick=null),Ht(e)}function _m(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);Ht(e)}var vm=new Map,ym=new Set;function bm(e){if(typeof e.getRootNode==`function`){var t=e.getRootNode();if(t.nodeType===9||t.nodeType===11)return t}return e.nodeType===9?e:e.ownerDocument}var xm=E.d;E.d={f:Sm,r:Cm,D:Em,C:Dm,L:Om,m:km,X:jm,S:Am,M:Mm};function Sm(){var e=xm.f(),t=zd();return e||t}function Cm(e){var t=Wt(e);t!==null&&t.tag===5&&t.type===`form`?tc(t):xm.r(e)}var wm=typeof document>`u`?null:document;function Tm(e,t,n){var r=wm;if(r&&typeof t==`string`&&t){var i=mn(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),ym.has(i)||(ym.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),np(t,`link`,e),qt(t),r.head.appendChild(t)))}}function Em(e){xm.D(e),Tm(`dns-prefetch`,e,null)}function Dm(e,t){xm.C(e,t),Tm(`preconnect`,e,t)}function Om(e,t,n){xm.L(e,t,n);var r=wm;if(r&&e&&t){var i=`link[rel="preload"][as="`+mn(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+mn(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+mn(n.imageSizes)+`"]`)):i+=`[href="`+mn(e)+`"]`;var a=i;switch(t){case`style`:a=Pm(e);break;case`script`:a=Rm(e)}if(!(vm.has(a)||(e=C({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),vm.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Fm(a))||t===`script`&&r.querySelector(zm(a))))){var o=r.createElement(`link`);np(o,`link`,e),t===`style`&&(o[Vt]=!0,o.onload=o.onerror=function(){Jt(o)}),qt(o),r.head.appendChild(o)}}}function km(e,t){xm.m(e,t);var n=wm;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+mn(r)+`"][href="`+mn(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Rm(e)}if(!vm.has(a)&&(e=C({rel:`modulepreload`,href:e},t),vm.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(zm(a)))return}r=n.createElement(`link`),np(r,`link`,e),qt(r),n.head.appendChild(r)}}}function Am(e,t,n){xm.S(e,t,n);var r=wm;if(r&&e){var i=Kt(r).hoistableStyles,a=Pm(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Fm(a)))s.loading=5;else{e=C({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=vm.get(a))&&Hm(e,n);var c=o=r.createElement(`link`);qt(c),np(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Vm(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function jm(e,t){xm.X(e,t);var n=wm;if(n&&e){var r=Kt(n).hoistableScripts,i=Rm(e),a=r.get(i);a||(a=n.querySelector(zm(i)),a||(e=C({src:e,async:!0},t),(t=vm.get(i))&&Um(e,t),a=n.createElement(`script`),qt(a),np(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Mm(e,t){xm.M(e,t);var n=wm;if(n&&e){var r=Kt(n).hoistableScripts,i=Rm(e),a=r.get(i);a||(a=n.querySelector(zm(i)),a||(e=C({src:e,async:!0,type:`module`},t),(t=vm.get(i))&&Um(e,t),a=n.createElement(`script`),qt(a),np(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Nm(e,t,n,r){var a=(a=Ne.current)?bm(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(n=Pm(n.href),t=Kt(a).hoistableStyles,r=t.get(n),r||(r={type:`style`,instance:null,count:0,state:null},t.set(n,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Pm(n.href);var o=Kt(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Fm(e)))?o._p||(s.instance=o,s.state.loading=5):(o=vm.get(e),o||(o={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},vm.set(e,o)),Lm(a,e,o,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(n=Rm(n),t=Kt(a).hoistableScripts,r=t.get(n),r||(r={type:`script`,instance:null,count:0,state:null},t.set(n,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Pm(e){return`href="`+mn(e)+`"`}function Fm(e){return`link[rel="stylesheet"][`+e+`]`}function Im(e){return C({},e,{"data-precedence":e.precedence,precedence:null})}function Lm(e,t,n,r){if(t=e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)){if(!0!==t[Vt]){r.loading=1;return}}else t=e.createElement(`link`),t[Vt]=!0,t.onload=t.onerror=Jt.bind(null,t),np(t,`link`,n),qt(t),e.head.appendChild(t);r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2})}function Rm(e){return`[src="`+mn(e)+`"]`}function zm(e){return`script[async]`+e}function Bm(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+mn(n.href)+`"]`);if(r)return t.instance=r,qt(r),r;var a=C({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),qt(r),np(r,`style`,a),Vm(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Pm(n.href);var o=e.querySelector(Fm(a));if(o)return t.state.loading|=4,t.instance=o,qt(o),o;r=Im(n),(a=vm.get(a))&&Hm(r,a),o=(e.ownerDocument||e).createElement(`link`),qt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),np(o,`link`,r),t.state.loading|=4,Vm(o,n.precedence,e),t.instance=o;case`script`:return o=Rm(n.src),(a=e.querySelector(zm(o)))?(t.instance=a,qt(a),a):(r=n,(a=vm.get(o))&&(r=C({},n),Um(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),qt(a),np(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Vm(r,n.precedence,e));return t.instance}function Vm(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Hm(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Um(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Wm=null;function Gm(e,t,n){if(Wm===null){var r=new Map,i=Wm=new Map;i.set(n,r)}else i=Wm,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[Bt]||a[Nt]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Km(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function qm(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Jm(e,t){return e===`img`&&t.src!=null&&t.src!==``&&t.onLoad==null&&t.loading!==`lazy`}function Ym(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Xm(e){return(e.width||100)*(e.height||100)*(typeof devicePixelRatio==`number`?devicePixelRatio:1)*.25}function Zm(e,t){typeof t.decode==`function`&&(e.imgCount++,t.complete||(e.imgBytes+=Xm(t),e.suspenseyImages.push(t)),e=rh.bind(e),t.decode().then(e,e))}function Qm(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Pm(r.href),a=t.querySelector(Fm(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=nh.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,qt(a);return}a=t.ownerDocument||t,r=Im(r),(i=vm.get(i))&&Hm(r,i),a=a.createElement(`link`),qt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),np(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=nh.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var $m=0;function eh(e,t){return e.stylesheets&&e.count===0&&ah(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&ah(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&$m===0&&($m=62500*op());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&ah(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>$m?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function th(e){if(e.count===0&&(e.imgCount===0||!e.waitingForImages)){if(e.stylesheets)ah(e,e.stylesheets);else if(e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}}}function nh(){this.count--,th(this)}function rh(){this.imgCount--,th(this)}var ih=null;function ah(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,ih=new Map,t.forEach(oh,e),ih=null,nh.call(e))}function oh(e,t){if(!(t.state.loading&4)){var n=ih.get(e);if(n)var r=n.get(null);else{n=new Map,ih.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=nh.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var sh={$$typeof:ue,Provider:null,Consumer:null,_currentValue:Ee,_currentValue2:Ee,_threadCount:0};function ch(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,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=St(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=St(0),this.hiddenUpdates=St(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.transitionTypes=null,this.incompleteTransitions=new Map}function lh(e,t,n,r,i,a,o,s,c,l,u,d){return e=new ch(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=Pi(3,null,null,t),e.current=a,a.stateNode=e,t=ja(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},mo(a),e}function uh(e){return e?(e=Mi,e):Mi}function dh(e,t,n,r,i,a){i=uh(i),r.context===null?r.context=i:r.pendingContext=i,r=go(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=_o(e,r,t),n!==null&&(Pd(n,e,t),vo(n,e,t))}function fh(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function ph(e,t){fh(e,t),(e=e.alternate)&&fh(e,t)}function mh(e){if(e.tag===13||e.tag===31){var t=ki(e,67108864);t!==null&&Pd(t,e,67108864),ph(e,67108864)}}function hh(e){if(e.tag===13||e.tag===31){var t=jd();t=Ot(t);var n=ki(e,t);n!==null&&Pd(n,e,t),ph(e,t)}}var gh=!0;function _h(e,t,n,r){var i=T.T;T.T=null;var a=E.p;try{E.p=2,yh(e,t,n,r)}finally{E.p=a,T.T=i}}function vh(e,t,n,r){var i=T.T;T.T=null;var a=E.p;try{E.p=8,yh(e,t,n,r)}finally{E.p=a,T.T=i}}function yh(e,t,n,r){if(gh){var i=bh(r);if(i===null)Kf(e,t,r,xh,n),Mh(e,r);else if(Ph(i,e,t,n,r))r.stopPropagation();else if(Mh(e,r),t&4&&-1<jh.indexOf(e)){for(;i!==null;){var a=Wt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=gt(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-lt(o);s.entanglements[1]|=c,o&=~c}Ef(a),!(K&6)&&(gd=Ze()+500,Df(0,!1))}}break;case 31:case 13:s=ki(a,2),s!==null&&Pd(s,a,2),zd(),ph(a,2)}if(a=bh(r),a===null&&Kf(e,t,r,xh,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Kf(e,t,r,null,n)}}function bh(e){return e=jn(e),Sh(e)}var xh=null;function Sh(e){if(xh=null,e=Ut(e),e!==null){var t=o(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=s(t),e!==null)return e;e=null}else if(n===31){if(e=c(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return xh=e,null}function Ch(e){switch(e){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`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`fullscreenerror`: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`resize`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(Qe()){case $e:return 2;case et:return 8;case tt:case nt:return 32;case rt:return 268435456;default:return 32}default:return 32}}var wh=!1,Th=null,Eh=null,Dh=null,Oh=new Map,kh=new Map,Ah=[],jh=`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 Mh(e,t){switch(e){case`focusin`:case`focusout`:Th=null;break;case`dragenter`:case`dragleave`:Eh=null;break;case`mouseover`:case`mouseout`:Dh=null;break;case`pointerover`:case`pointerout`:Oh.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:kh.delete(t.pointerId)}}function Nh(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=Wt(t),t!==null&&mh(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Ph(e,t,n,r,i){switch(t){case`focusin`:return Th=Nh(Th,e,t,n,r,i),!0;case`dragenter`:return Eh=Nh(Eh,e,t,n,r,i),!0;case`mouseover`:return Dh=Nh(Dh,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Oh.set(a,Nh(Oh.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,kh.set(a,Nh(kh.get(a)||null,e,t,n,r,i)),!0}return!1}function Fh(e){var t=Ut(e.target);if(t!==null){var n=o(t);if(n!==null){if(t=n.tag,t===13){if(t=s(n),t!==null){e.blockedOn=t,jt(e.priority,function(){hh(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,jt(e.priority,function(){hh(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Ih(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=bh(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);An=r,n.target.dispatchEvent(r),An=null}else return t=Wt(n),t!==null&&mh(t),e.blockedOn=n,!1;t.shift()}return!0}function Lh(e,t,n){Ih(e)&&n.delete(t)}function Rh(){wh=!1,Th!==null&&Ih(Th)&&(Th=null),Eh!==null&&Ih(Eh)&&(Eh=null),Dh!==null&&Ih(Dh)&&(Dh=null),Oh.forEach(Lh),kh.forEach(Lh)}function zh(e,n){e.blockedOn===n&&(e.blockedOn=null,wh||(wh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Rh)))}var Bh=null;function Vh(e){Bh!==e&&(Bh=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Bh===e&&(Bh=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(Sh(r||n)===null)continue;break}var a=Wt(n);a!==null&&(e.splice(t,3),t-=3,$s(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Hh(e){function t(t){return zh(t,e)}Th!==null&&zh(Th,e),Eh!==null&&zh(Eh,e),Dh!==null&&zh(Dh,e),Oh.forEach(t),kh.forEach(t);for(var n=0;n<Ah.length;n++){var r=Ah[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Ah.length&&(n=Ah[0],n.blockedOn===null);)Fh(n),n.blockedOn===null&&Ah.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[Pt]||null;if(typeof a==`function`)o||Vh(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[Pt]||null)s=o.formAction;else if(Sh(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Vh(n)}}}function Uh(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Wh(e){this._internalRoot=e}Gh.prototype.render=Wh.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;dh(n,jd(),e,t,null,null)},Gh.prototype.unmount=Wh.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;dh(e.current,2,null,e,null,null),zd(),t[Ft]=null}};function Gh(e){this._internalRoot=e}Gh.prototype.unstable_scheduleHydration=function(e){if(e){var t=At();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Ah.length&&t!==0&&t<Ah[n].priority;n++);Ah.splice(n,0,e),n===0&&Fh(e)}};var Kh=n.version;if(Kh!==`19.3.0`)throw Error(i(527,Kh,`19.3.0`));E.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=u(t),e=e===null?null:f(e),e=e===null?null:e.stateNode,e};var qh={bundleType:0,version:`19.3.0`,rendererPackageName:`react-dom`,currentDispatcherRef:T,reconcilerVersion:`19.3.0`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Jh=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Jh.isDisabled&&Jh.supportsFiber)try{ot=Jh.inject(qh),st=Jh}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=Sc,s=Cc,c=wc;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=lh(e,1,!1,null,null,n,r,null,o,s,c,Uh),e[Ft]=t.current,Wf(e),new Wh(t)}})),_=o(((e,t)=>{function n(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE==`function`)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=g()})),v=l(d(),1),y=_(),b=`modulepreload`,x=function(e){return`/`+e},ee={},te=function(e){return e.pathname.endsWith(`.css`)},ne=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e,i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?new URL(import.meta.resolve(e)):new URL(e,import.meta.url)}r=o(t.map(t=>{t=x(t,n);let r=s(t);if(r.href in ee)return;ee[r.href]=!0;let i=te(r);if(e===void 0){e={all:new Set,styles:new Set};let t=document.getElementsByTagName(`link`);for(let n=t.length-1;n>=0;n--){let r=t[n];e.all.add(r.href),r.rel===`stylesheet`&&e.styles.add(r.href)}}if((i?e.styles:e.all).has(r.href))return;let o=document.createElement(`link`);if(o.rel=i?`stylesheet`:b,i||(o.as=`script`),o.crossOrigin=``,o.href=r.href,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),i)return new Promise((e,t)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>t(Error(`Unable to preload CSS for ${r}`)))})}).filter(e=>e!==void 0))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},S=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,re=/^[\\/]{2}/;function C(e,t){return t+e.replace(/\\/g,`/`)}var ie=`popstate`;function ae(e){return typeof e==`object`&&!!e&&`pathname`in e&&`search`in e&&`hash`in e&&`state`in e&&`key`in e}function oe(e={}){function t(e,t){let n=t.state?.masked,{pathname:r,search:i,hash:a}=n||e.location;return ue(``,{pathname:r,search:i,hash:a},t.state&&t.state.usr||null,t.state&&t.state.key||`default`,n?{pathname:e.location.pathname,search:e.location.search,hash:e.location.hash}:void 0)}function n(e,t){return typeof t==`string`?t:de(t)}return pe(t,n,null,e)}function w(e,t){if(e===!1||e==null)throw Error(t)}function se(e,t){if(!e){typeof console<`u`&&console.warn(t);try{throw Error(t)}catch{}}}function ce(){return Math.random().toString(36).substring(2,10)}function le(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function ue(e,t,n=null,r,i){return{pathname:typeof e==`string`?e:e.pathname,search:``,hash:``,...typeof t==`string`?fe(t):t,state:n,key:t&&t.key||r||ce(),mask:i}}function de({pathname:e=`/`,search:t=``,hash:n=``}){return t&&t!==`?`&&(e+=t.charAt(0)===`?`?t:`?`+t),n&&n!==`#`&&(e+=n.charAt(0)===`#`?n:`#`+n),e}function fe(e){let t={};if(e){let n=e.indexOf(`#`);n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf(`?`);r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function pe(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,s=`POP`,c=null,l=u();l??(l=0,o.replaceState({...o.state,idx:l},``));function u(){return(o.state||{idx:null}).idx}function d(){s=`POP`;let e=u(),t=e==null?null:e-l;l=e,c&&c({action:s,location:h.location,delta:t})}function f(e,t){s=`PUSH`;let r=ae(e)?e:ue(h.location,e,t);n&&n(r,e),l=u()+1;let d=le(r,l),f=h.createHref(r.mask||r);try{o.pushState(d,``,f)}catch(e){if(e instanceof DOMException&&e.name===`DataCloneError`)throw e;i.location.assign(f)}a&&c&&c({action:s,location:h.location,delta:1})}function p(e,t){s=`REPLACE`;let r=ae(e)?e:ue(h.location,e,t);n&&n(r,e),l=u();let i=le(r,l),d=h.createHref(r.mask||r);o.replaceState(i,``,d),a&&c&&c({action:s,location:h.location,delta:0})}function m(e){return me(i,e)}let h={get action(){return s},get location(){return e(i,o)},listen(e){if(c)throw Error(`A history only accepts one active listener`);return i.addEventListener(ie,d),c=e,()=>{i.removeEventListener(ie,d),c=null}},createHref(e){return t(i,e)},createURL:m,encodeLocation(e){let t=m(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:f,replace:p,go(e){return o.go(e)}};return h}function me(e,t,n=!1){let r=`http://localhost`;e&&(r=e.location.origin===`null`?e.location.href:e.location.origin),w(r,`No window.location.(origin|href) available to create URL`);let i=typeof t==`string`?t:de(t);return i=i.replace(/ $/,`%20`),!n&&re.test(i)&&(i=r+i),new URL(i,r)}function he(e,t,n=`/`){return ge(e,t,n,!1)}function ge(e,t,n,r,i){let a=Me((typeof t==`string`?fe(t):t).pathname||`/`,n);if(a==null)return null;let o=i??_e(e),s=null,c=je(a);for(let e=0;s==null&&e<o.length;++e)s=Oe(o[e],c,r);return s}function _e(e){let t=ve(e);return be(t),t}function ve(e,t=[],n=[],r=``,i=!1){let a=(e,a,o=i,s)=>{let c={relativePath:s===void 0?e.path||``:s,caseSensitive:e.caseSensitive===!0,childrenIndex:a,route:e};if(c.relativePath.startsWith(`/`)){if(!c.relativePath.startsWith(r)&&o)return;w(c.relativePath.startsWith(r),`Absolute route path "${c.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),c.relativePath=c.relativePath.slice(r.length)}let l=Be([r,c.relativePath]),u=n.concat(c);e.children&&e.children.length>0&&(w(e.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${l}".`),ve(e.children,t,u,l,o)),(e.path!=null||e.index)&&t.push({path:l,score:Ee(l,e.index),routesMeta:u.map((e,t)=>{let[n,r]=D(e.relativePath,e.caseSensitive,t===u.length-1);return{...e,matcher:n,compiledParams:r}})})};return e.forEach((e,t)=>{if(e.path===``||!e.path?.includes(`?`))a(e,t);else for(let n of ye(e.path))a(e,t,!0,n)}),t}function ye(e){let t=e.split(`/`);if(t.length===0)return[];let[n,...r]=t,i=n.endsWith(`?`),a=n.replace(/\?$/,``);if(r.length===0)return i?[a,``]:[a];let o=ye(r.join(`/`)),s=[];return s.push(...o.map(e=>e===``?a:[a,e].join(`/`))),i&&s.push(...o),s.map(t=>e.startsWith(`/`)&&t===``?`/`:t)}function be(e){e.sort((e,t)=>e.score===t.score?De(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)):t.score-e.score)}var xe=/^:[\w-]+$/,Se=3,Ce=2,we=1,Te=10,T=-2,E=e=>e===`*`;function Ee(e,t){let n=e.split(`/`),r=n.length;return n.some(E)&&(r+=T),t&&(r+=Ce),n.filter(e=>!E(e)).reduce((e,t)=>e+(xe.test(t)?Se:t===``?we:Te),r)}function De(e,t){return e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n])?e[e.length-1]-t[t.length-1]:0}function Oe(e,t,n=!1){let{routesMeta:r}=e,i={},a=`/`,o=[];for(let e=0;e<r.length;++e){let s=r[e],c=e===r.length-1,l=a===`/`?t:t.slice(a.length)||`/`,u={path:s.relativePath,caseSensitive:s.caseSensitive,end:c},d=s.matcher&&s.compiledParams?Ae(u,l,s.matcher,s.compiledParams):ke(u,l),f=s.route;if(!d&&c&&n&&!r[r.length-1].route.index&&(d=ke({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},l)),!d)return null;Object.assign(i,d.params),o.push({params:i,pathname:Be([a,d.pathname]),pathnameBase:He(Be([a,d.pathnameBase])),route:f}),d.pathnameBase!==`/`&&(a=Be([a,d.pathnameBase]))}return o}function ke(e,t){typeof e==`string`&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=D(e.path,e.caseSensitive,e.end);return Ae(e,t,n,r)}function Ae(e,t,n,r){let i=t.match(n);if(!i)return null;let a=i[0],o=Ve(a,1),s=i.slice(1);return{params:r.reduce((e,{paramName:t,isOptional:n},r)=>{if(t===`*`){let e=s[r]||``;o=Ve(a.slice(0,a.length-e.length),1)}let i=s[r];return e[t]=n&&!i?void 0:(i||``).replace(/%2F/g,`/`),e},{}),pathname:a,pathnameBase:o,pattern:e}}function D(e,t=!1,n=!0){se(e===`*`||!e.endsWith(`*`)||e.endsWith(`/*`),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,`/*`)}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,`/*`)}".`);let r=[],i=`^`+e.replace(/\/*\*?$/,``).replace(/^\/*/,`/`).replace(/[\\.*+^${}|()[\]]/g,`\\$&`).replace(/\/:([\w-]+)(\?)?/g,(e,t,n,i,a)=>{if(r.push({paramName:t,isOptional:n!=null}),n){let t=a.charAt(i+e.length);return t&&t!==`/`?`/([^\\/]*)`:`(?:/([^\\/]*))?`}return`/([^\\/]+)`}).replace(/\/([\w-]+)\?(\/|$)/g,`(/$1)?$2`);return e.endsWith(`*`)?(r.push({paramName:`*`}),i+=e===`*`||e===`/*`?`(.*)$`:`(?:\\/(.+)|\\/*)$`):n?i+=`\\/*$`:e!==``&&e!==`/`&&(i+=`(?:(?=\\/|$))`),[new RegExp(i,t?void 0:`i`),r]}function je(e){try{return e.split(`/`).map(e=>decodeURIComponent(e).replace(/\//g,`%2F`)).join(`/`)}catch(t){return se(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function Me(e,t){if(t===`/`)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith(`/`)?t.length-1:t.length,r=e.charAt(n);return r&&r!==`/`?null:e.slice(n)||`/`}function Ne(e,t=`/`){let{pathname:n,search:r=``,hash:i=``}=typeof e==`string`?fe(e):e,a;return n?(n=ze(n),a=n.startsWith(`/`)||n.startsWith(`\\`)?Pe(n.substring(1),`/`):Pe(n,t)):a=t,{pathname:a,search:Ue(r),hash:We(i)}}function Pe(e,t){let n=Ve(t).split(`/`);return e.split(`/`).forEach(e=>{e===`..`?n.length>1&&n.pop():e!==`.`&&n.push(e)}),n.length>1?n.join(`/`):`/`}function Fe(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Ie(e){return e.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function Le(e){let t=Ie(e);return t.map((e,n)=>n===t.length-1?e.pathname:e.pathnameBase)}function Re(e,t,n,r=!1){let i;typeof e==`string`?i=fe(e):(i={...e},w(!i.pathname||!i.pathname.includes(`?`),Fe(`?`,`pathname`,`search`,i)),w(!i.pathname||!i.pathname.includes(`#`),Fe(`#`,`pathname`,`hash`,i)),w(!i.search||!i.search.includes(`#`),Fe(`#`,`search`,`hash`,i)));let a=e===``||i.pathname===``,o=a?`/`:i.pathname,s;if(o==null)s=n;else{let e=t.length-1;if(!r&&o.startsWith(`..`)){let t=o.split(`/`);for(;t[0]===`..`;)t.shift(),--e;i.pathname=t.join(`/`)}s=e>=0?t[e]:`/`}let c=Ne(i,s),l=o&&o!==`/`&&o.endsWith(`/`),u=(a||o===`.`)&&n.endsWith(`/`);return!c.pathname.endsWith(`/`)&&(l||u)&&(c.pathname+=`/`),c}var ze=e=>e.replace(/[\\/]{2,}/g,`/`),Be=e=>ze(e.join(`/`));function Ve(e,t=0){let n=e.length;for(;n>t&&e.charCodeAt(n-1)===47;)n--;return n===e.length?e:e.slice(0,n)}var He=e=>Ve(e).replace(/^\/*/,`/`),Ue=e=>!e||e===`?`?``:e.startsWith(`?`)?e:`?`+e,We=e=>!e||e===`#`?``:e.startsWith(`#`)?e:`#`+e,Ge=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||``,this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function Ke(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.internal==`boolean`&&`data`in e}function qe(e){return Be(e.map(e=>e.route.path).filter(Boolean))||`/`}var Je=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;function Ye(e,t){let n=e;if(typeof n!=`string`||!S.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(Je)try{let e=new URL(window.location.href),r=re.test(n)?new URL(C(n,e.protocol)):new URL(n),a=Me(r.pathname,t);r.origin===e.origin&&a!=null?n=a+r.search+r.hash:i=!0}catch{se(!1,`<Link to="${n}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join(`\0`);var Xe=new URL(`http://localhost`);function Ze(e){if(e.createURL)return e.createURL(`/`);try{return new URL(e.createHref(`/`),Xe)}catch{return Xe}}function Qe(e,t){return e.origin===t.origin&&(e.origin!==`null`||e.protocol===t.protocol&&e.host===t.host)}function $e(e,t){if(e.startsWith(`//`))return!0;let n=t.protocol.toLowerCase();return e.toLowerCase().startsWith(n)?t.host===``||e.slice(n.length).startsWith(`//`):!1}function et(e,t,n,r){let i=null;try{i=e==null?null:new URL(e,n)}catch{}let a=new URL(t,n),o=i!=null&&!Qe(i,n),s=!Qe(a,n);if(r===`reject`){if(o||s)throw Error(`External navigation is not allowed`)}else if(s&&(i==null||!$e(e,i)||!Qe(i,a)))throw Error(`External navigation is not allowed`)}var tt=[`POST`,`PUT`,`PATCH`,`DELETE`];new Set(tt);var nt=[`GET`,...tt];new Set(nt);var rt=[`about:`,`blob:`,`chrome:`,`chrome-untrusted:`,`content:`,`data:`,`devtools:`,`file:`,`filesystem:`,`javascript:`];function it(e){try{return rt.includes(new URL(e).protocol)}catch{return!1}}var at=v.createContext(null);at.displayName=`DataRouter`;var ot=v.createContext(null);ot.displayName=`DataRouterState`;var st=v.createContext(!1);function ct(){return v.useContext(st)}var lt=v.createContext({isTransitioning:!1});lt.displayName=`ViewTransition`;var ut=v.createContext(new Map);ut.displayName=`Fetchers`;var dt=v.createContext(null);dt.displayName=`Await`;var ft=v.createContext(null);ft.displayName=`Navigation`;var pt=v.createContext(null);pt.displayName=`Location`;var mt=v.createContext({outlet:null,matches:[],isDataRoute:!1});mt.displayName=`Route`;var ht=v.createContext(null);ht.displayName=`RouteError`;var gt=`REACT_ROUTER_ERROR`,_t=`REDIRECT`,vt=`ROUTE_ERROR_RESPONSE`;function yt(e){if(e.startsWith(`${gt}:${_t}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`&&typeof t.location==`string`&&typeof t.reloadDocument==`boolean`&&typeof t.replace==`boolean`)return t}catch{}}function bt(e){if(e.startsWith(`${gt}:${vt}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`)return new Ge(t.status,t.statusText,t.data)}catch{}}function xt(e,{relative:t}={}){w(St(),`useHref() may be used only in the context of a <Router> component.`);let{basename:n,navigator:r}=v.useContext(ft),{hash:i,pathname:a,search:o}=jt(e,{relative:t}),s=a;return n!==`/`&&(s=a===`/`?n:Be([n,a])),r.createHref({pathname:s,search:o,hash:i})}function St(){return v.useContext(pt)!=null}function Ct(){return w(St(),`useLocation() may be used only in the context of a <Router> component.`),v.useContext(pt).location}var wt=`You should call navigate() in a React.useEffect(), not when your component is first rendered.`;function Tt(e){v.useContext(ft).static||v.useLayoutEffect(e)}function Et(){let{isDataRoute:e}=v.useContext(mt);return e?Jt():Dt()}function Dt(){w(St(),`useNavigate() may be used only in the context of a <Router> component.`);let e=v.useContext(at),{basename:t,navigator:n}=v.useContext(ft),{matches:r}=v.useContext(mt),{pathname:i}=Ct(),a=JSON.stringify(Le(r)),o=v.useRef(!1);return Tt(()=>{o.current=!0}),v.useCallback((r,s={})=>{if(se(o.current,wt),!o.current)return;if(typeof r==`number`){n.go(r);return}let c=Re(r,JSON.parse(a),i,s.relative===`path`);e==null&&t!==`/`&&(c.pathname=c.pathname===`/`?t:Be([t,c.pathname])),et(typeof r==`string`?r:de(r),n.createHref(c),Ze(n),`reject`),(s.replace?n.replace:n.push)(c,s.state,s)},[t,n,a,i,e])}var Ot=v.createContext(null);function kt(e){let t=v.useContext(mt).outlet;return v.useMemo(()=>t&&v.createElement(Ot.Provider,{value:e},t),[t,e])}function At(){let{matches:e}=v.useContext(mt);return e[e.length-1]?.params??{}}function jt(e,{relative:t}={}){let{matches:n}=v.useContext(mt),{pathname:r}=Ct(),i=JSON.stringify(Le(n));return v.useMemo(()=>Re(e,JSON.parse(i),r,t===`path`),[e,i,r,t])}function Mt(e,t){return Nt(e,t)}function Nt(e,t,n){w(St(),`useRoutes() may be used only in the context of a <Router> component.`);let{navigator:r}=v.useContext(ft),{matches:i}=v.useContext(mt),a=i[i.length-1],o=a?a.params:{},s=a?a.pathname:`/`,c=a?a.pathnameBase:`/`,l=a&&a.route;{let e=l&&l.path||``;Xt(s,!l||e.endsWith(`*`)||e.endsWith(`*?`),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${s}" (under <Route path="${e}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
10
+
11
+ Please change the parent <Route path="${e}"> to <Route path="${e===`/`?`*`:`${e}/*`}">.`)}let u=Ct(),d;if(t){let e=typeof t==`string`?fe(t):t;w(c===`/`||e.pathname?.startsWith(c),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${c}" but pathname "${e.pathname}" was given in the \`location\` prop.`),d=e}else d=u;let f=d.pathname||`/`,p=f;if(c!==`/`){let e=c.replace(/^\//,``).split(`/`);p=`/`+f.replace(/^\//,``).split(`/`).slice(e.length).join(`/`)}let m=n&&n.state.matches.length?n.state.matches.map(e=>Object.assign(e,{route:n.manifest[e.route.id]||e.route})):he(e,{pathname:p});se(l||m!=null,`No routes matched location "${d.pathname}${d.search}${d.hash}" `),se(m==null||m[m.length-1].route.element!==void 0||m[m.length-1].route.Component!==void 0||m[m.length-1].route.lazy!==void 0,`Matched leaf route at location "${d.pathname}${d.search}${d.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let h=Bt(m&&m.map(e=>Object.assign({},e,{params:Object.assign({},o,e.params),pathname:Be([c,r.encodeLocation?r.encodeLocation(e.pathname.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathname]),pathnameBase:e.pathnameBase===`/`?c:Be([c,r.encodeLocation?r.encodeLocation(e.pathnameBase.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathnameBase])})),i,n);return t&&h?v.createElement(pt.Provider,{value:{location:{pathname:`/`,search:``,hash:``,state:null,key:`default`,mask:void 0,...d},navigationType:`POP`}},h):h}function Pt(){let e=qt(),t=Ke(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r=`rgba(200,200,200, 0.5)`,i={padding:`0.5rem`,backgroundColor:r},a={padding:`2px 4px`,backgroundColor:r},o=null;return console.error(`Error handled by React Router default ErrorBoundary:`,e),o=v.createElement(v.Fragment,null,v.createElement(`p`,null,`💿 Hey developer 👋`),v.createElement(`p`,null,`You can provide a way better UX than this when your app throws errors by providing your own `,v.createElement(`code`,{style:a},`ErrorBoundary`),` or`,` `,v.createElement(`code`,{style:a},`errorElement`),` prop on your route.`)),v.createElement(v.Fragment,null,v.createElement(`h2`,null,`Unexpected Application Error!`),v.createElement(`h3`,{style:{fontStyle:`italic`}},t),n?v.createElement(`pre`,{style:i},n):null,o)}var Ft=v.createElement(Pt,null),It=class extends v.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!==`idle`&&e.revalidation===`idle`?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error===void 0?t.error:e.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error(`React Router caught the following error during render`,e)}render(){let e=this.state.error;if(this.context&&typeof e==`object`&&e&&`digest`in e&&typeof e.digest==`string`){let t=bt(e.digest);t&&(e=t)}let t=e===void 0?this.props.children:v.createElement(mt.Provider,{value:this.props.routeContext},v.createElement(ht.Provider,{value:e,children:this.props.component}));return this.context?v.createElement(Rt,{error:e},t):t}};It.contextType=st;var Lt=new WeakMap;function Rt({children:e,error:t}){let{basename:n,navigator:r}=v.useContext(ft);if(typeof t==`object`&&t&&`digest`in t&&typeof t.digest==`string`){let e=yt(t.digest);if(e){let i=Lt.get(t);if(i)throw i;let a=Ye(e.location,n),o=a.absoluteURL||a.to;if(et(e.location,o,Ze(r),`allow-explicit`),it(o))throw Error(`Invalid redirect location`);if(Je&&!Lt.get(t)){if(a.isExternal||e.reloadDocument)window.location.href=o;else{let n=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(a.to,{replace:e.replace}));throw Lt.set(t,n),n}}return v.createElement(`meta`,{httpEquiv:`refresh`,content:`0;url=${o}`})}}return e}function zt({routeContext:e,match:t,children:n}){let r=v.useContext(at);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),v.createElement(mt.Provider,{value:e},n)}function Bt(e,t=[],n){let r=n?.state;if(e==null){if(!r)return null;if(r.errors)e=r.matches;else if(t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let i=e,a=r?.errors;if(a!=null){let e=i.findIndex(e=>e.route.id&&a?.[e.route.id]!==void 0);w(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(a).join(`,`)}`),i=i.slice(0,Math.min(i.length,e+1))}let o=!1,s=-1;if(n&&r){o=r.renderFallback;for(let e=0;e<i.length;e++){let t=i[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(s=e),t.route.id){let{loaderData:e,errors:a}=r,c=t.route.loader&&!e.hasOwnProperty(t.route.id)&&(!a||a[t.route.id]===void 0);if(t.route.lazy||c){n.isStatic&&(o=!0),i=s>=0?i.slice(0,s+1):[i[0]];break}}}}let c=n?.onError,l=r&&c?(e,t)=>{c(e,{location:r.location,params:r.matches?.[0]?.params??{},pattern:qe(r.matches),errorInfo:t})}:void 0;return i.reduceRight((e,n,c)=>{let u,d=!1,f=null,p=null;r&&(u=a&&n.route.id?a[n.route.id]:void 0,f=n.route.errorElement||Ft,o&&(s<0&&c===0?(Xt(`route-fallback`,!1,"No `HydrateFallback` element provided to render during initial hydration"),d=!0,p=null):s===c&&(d=!0,p=n.route.hydrateFallbackElement||null)));let m=t.concat(i.slice(0,c+1)),h=()=>{let t;return t=u?f:d?p:n.route.Component?v.createElement(n.route.Component,null):n.route.element?n.route.element:e,v.createElement(zt,{match:n,routeContext:{outlet:e,matches:m,isDataRoute:r!=null},children:t})};return r&&(n.route.ErrorBoundary||n.route.errorElement||c===0)?v.createElement(It,{location:r.location,revalidation:r.revalidation,component:f,error:u,children:h(),routeContext:{outlet:null,matches:m,isDataRoute:!0},onError:l}):h()},null)}function Vt(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Ht(e){let t=v.useContext(at);return w(t,Vt(e)),t}function Ut(e){let t=v.useContext(ot);return w(t,Vt(e)),t}function Wt(e){let t=v.useContext(mt);return w(t,Vt(e)),t}function Gt(e){let t=Wt(e),n=t.matches[t.matches.length-1];return w(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function Kt(){return Gt(`useRouteId`)}function qt(){let e=v.useContext(ht),t=Ut(`useRouteError`),n=Gt(`useRouteError`);return e===void 0?t.errors?.[n]:e}function Jt(){let{router:e}=Ht(`useNavigate`),t=Gt(`useNavigate`),n=v.useRef(!1);return Tt(()=>{n.current=!0}),v.useCallback(async(r,i={})=>{se(n.current,wt),n.current&&(typeof r==`number`?await e.navigate(r):await e.navigate(r,{fromRouteId:t,...i}))},[e,t])}var Yt={};function Xt(e,t,n){!t&&!Yt[e]&&(Yt[e]=!0,se(!1,n))}v.memo(Zt);function Zt({routes:e,manifest:t,future:n,state:r,isStatic:i,onError:a}){return Nt(e,void 0,{manifest:t,state:r,isStatic:i,onError:a,future:n})}function Qt({to:e,replace:t,state:n,relative:r}){w(St(),`<Navigate> may be used only in the context of a <Router> component.`);let{static:i,navigator:a}=v.useContext(ft);se(!i,`<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.`);let{matches:o}=v.useContext(mt),{pathname:s}=Ct(),c=Et(),l=Re(e,Le(o),s,r===`path`);et(typeof e==`string`?e:de(e),a.createHref(l),Ze(a),`reject`);let u=JSON.stringify(l);return v.useEffect(()=>{c(JSON.parse(u),{replace:t,state:n,relative:r})},[c,u,r,t,n]),null}function $t(e){return kt(e.context)}function en(e){w(!1,`A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.`)}function tn({basename:e=`/`,children:t=null,location:n,navigationType:r=`POP`,navigator:i,static:a=!1,useTransitions:o}){w(!St(),`You cannot render a <Router> inside another <Router>. You should never have more than one in your app.`);let s=e.replace(/^\/*/,`/`),c=v.useMemo(()=>({basename:s,navigator:i,static:a,useTransitions:o,future:{}}),[s,i,a,o]);typeof n==`string`&&(n=fe(n));let{pathname:l=`/`,search:u=``,hash:d=``,state:f=null,key:p=`default`,mask:m}=n,h=v.useMemo(()=>{let e=Me(l,s);return e==null?null:{location:{pathname:e,search:u,hash:d,state:f,key:p,mask:m},navigationType:r}},[s,l,u,d,f,p,r,m]);return se(h!=null,`<Router basename="${s}"> is not able to match the URL "${l}${u}${d}" because it does not start with the basename, so the <Router> won't render anything.`),h==null?null:v.createElement(ft.Provider,{value:c},v.createElement(pt.Provider,{children:t,value:h}))}function nn({children:e,location:t}){return Mt(O(e),t)}v.Component;function O(e,t=[]){let n=[];return v.Children.forEach(e,(e,r)=>{if(!v.isValidElement(e))return;let i=[...t,r];if(e.type===v.Fragment){n.push.apply(n,O(e.props.children,i));return}w(e.type===en,`[${typeof e.type==`string`?e.type:e.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),w(!e.props.index||!e.props.children,`An index route cannot have child routes.`);let a={id:e.props.id||i.join(`-`),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,middleware:e.props.middleware,loader:e.props.loader,action:e.props.action,hydrateFallbackElement:e.props.hydrateFallbackElement,HydrateFallback:e.props.HydrateFallback,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:e.props.hasErrorBoundary===!0||e.props.ErrorBoundary!=null||e.props.errorElement!=null,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(a.children=O(e.props.children,i)),n.push(a)}),n}var rn=`get`,an=`application/x-www-form-urlencoded`;function on(e){return typeof HTMLElement<`u`&&e instanceof HTMLElement}function sn(e){return on(e)&&e.tagName.toLowerCase()===`button`}function cn(e){return on(e)&&e.tagName.toLowerCase()===`form`}function ln(e){return on(e)&&e.tagName.toLowerCase()===`input`}function un(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function dn(e,t){return e.button===0&&(!t||t===`_self`)&&!un(e)}var fn=null;function pn(){if(fn===null)try{new FormData(document.createElement(`form`),0),fn=!1}catch{fn=!0}return fn}var mn=new Set([`application/x-www-form-urlencoded`,`multipart/form-data`,`text/plain`]);function hn(e){return e!=null&&!mn.has(e)?(se(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${an}"`),null):e}function gn(e,t){let n,r,i,a,o;if(cn(e)){let o=e.getAttribute(`action`);r=o?Me(o,t):null,n=e.getAttribute(`method`)||rn,i=hn(e.getAttribute(`enctype`))||an,a=new FormData(e)}else if(sn(e)||ln(e)&&(e.type===`submit`||e.type===`image`)){let o=e.form;if(o==null)throw Error(`Cannot submit a <button> or <input type="submit"> without a <form>`);let s=e.getAttribute(`formaction`)||o.getAttribute(`action`);if(r=s?Me(s,t):null,n=e.getAttribute(`formmethod`)||o.getAttribute(`method`)||rn,i=hn(e.getAttribute(`formenctype`))||hn(o.getAttribute(`enctype`))||an,a=new FormData(o,e),!pn()){let{name:t,type:n,value:r}=e;if(n===`image`){let e=t?`${t}.`:``;a.append(`${e}x`,`0`),a.append(`${e}y`,`0`)}else t&&a.append(t,r)}}else if(on(e))throw Error(`Cannot submit element that is not <form>, <button>, or <input type="submit|image">`);else n=rn,r=null,i=an,o=e;return a&&i===`text/plain`&&(o=a,a=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:a,body:o}}Object.getOwnPropertyNames(Object.prototype).sort().join(`\0`);function _n(e,t){if(e===!1||e==null)throw Error(t)}function vn(e,t,n,r){let i=typeof e==`string`?new URL(e,typeof window>`u`?`server://singlefetch/`:window.location.origin):e;return i.pathname=n?i.pathname.endsWith(`/`)?`${i.pathname}_.${r}`:`${i.pathname}.${r}`:i.pathname===`/`?`_root.${r}`:t&&Me(i.pathname,t)===`/`?`${Ve(t)}/_root.${r}`:`${Ve(i.pathname)}.${r}`,i}async function yn(e,t){if(e.id in t)return t[e.id];try{let n=await ne(()=>import(e.module),[]);return t[e.id]=n,n}catch(t){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(t),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function bn(e){return e!=null&&typeof e.page==`string`}function xn(e){return e==null?!1:e.href==null?e.rel===`preload`&&typeof e.imageSrcSet==`string`&&typeof e.imageSizes==`string`:typeof e.rel==`string`&&typeof e.href==`string`}async function Sn(e,t,n){return Dn((await Promise.all(e.map(async e=>{let r=t.routes[e.route.id];if(r){let e=await yn(r,n);return e.links?e.links():[]}return[]}))).flat(1).filter(xn).filter(e=>e.rel===`stylesheet`||e.rel===`preload`).map(e=>e.rel===`stylesheet`?{...e,rel:`prefetch`,as:`style`}:{...e,rel:`prefetch`}))}function Cn(e,t,n,r,i,a){let o=(e,t)=>!n[t]||e.route.id!==n[t].route.id,s=(e,t)=>n[t].pathname!==e.pathname||n[t].route.path?.endsWith(`*`)&&n[t].params[`*`]!==e.params[`*`];return a===`assets`?t.filter((e,t)=>o(e,t)||s(e,t)):a===`data`?t.filter((t,a)=>{let c=r.routes[t.route.id];if(!c||!c.hasLoader)return!1;if(o(t,a)||s(t,a))return!0;if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:t.params,defaultShouldRevalidate:!0});if(typeof r==`boolean`)return r}return!0}):[]}function wn(e,t,{includeHydrateFallback:n}={}){return Tn(e.map(e=>{let r=t.routes[e.route.id];if(!r)return[];let i=[r.module];return r.clientActionModule&&(i=i.concat(r.clientActionModule)),r.clientLoaderModule&&(i=i.concat(r.clientLoaderModule)),n&&r.hydrateFallbackModule&&(i=i.concat(r.hydrateFallbackModule)),r.imports&&(i=i.concat(r.imports)),i}).flat(1))}function Tn(e){return[...new Set(e)]}function En(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function Dn(e,t){let n=new Set,r=new Set(t);return e.reduce((e,i)=>{if(t&&!bn(i)&&i.as===`script`&&i.href&&r.has(i.href))return e;let a=JSON.stringify(En(i));return n.has(a)||(n.add(a),e.push({key:a,link:i})),e},[])}function On(){let e=v.useContext(at);return _n(e,`You must render this element inside a <DataRouterContext.Provider> element`),e}function kn(){let e=v.useContext(ot);return _n(e,`You must render this element inside a <DataRouterStateContext.Provider> element`),e}var An=v.createContext(void 0);An.displayName=`FrameworkContext`;function jn(){let e=v.useContext(An);return _n(e,`You must render this element inside a <HydratedRouter> element`),e}function Mn(e,t){let n=v.useContext(An),[r,i]=v.useState(!1),[a,o]=v.useState(!1),{onFocus:s,onBlur:c,onMouseEnter:l,onMouseLeave:u,onTouchStart:d}=t,f=v.useRef(null);v.useEffect(()=>{if(e===`render`&&o(!0),e===`viewport`){let e=new IntersectionObserver(e=>{e.forEach(e=>{o(e.isIntersecting)})},{threshold:.5});return f.current&&e.observe(f.current),()=>{e.disconnect()}}},[e]),v.useEffect(()=>{if(r){let e=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(e)}}},[r]);let p=()=>{i(!0)},m=()=>{i(!1),o(!1)};return n?e===`intent`?[a,f,{onFocus:Nn(s,p),onBlur:Nn(c,m),onMouseEnter:Nn(l,p),onMouseLeave:Nn(u,m),onTouchStart:Nn(d,p)}]:[a,f,{}]:[!1,f,{}]}function Nn(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function Pn({page:e,...t}){let n=ct(),{nonce:r}=jn(),{router:i}=On(),a=v.useMemo(()=>he(i.routes,e,i.basename),[i.routes,e,i.basename]);return a?(t.nonce==null&&r&&(t={...t,nonce:r}),n?v.createElement(In,{page:e,matches:a,...t}):v.createElement(Ln,{page:e,matches:a,...t})):null}function Fn(e){let{manifest:t,routeModules:n}=jn(),[r,i]=v.useState([]);return v.useEffect(()=>{let r=!1;return Sn(e,t,n).then(e=>{r||i(e)}),()=>{r=!0}},[e,t,n]),r}function In({page:e,matches:t,...n}){let r=Ct(),{future:i}=jn(),{basename:a}=On(),o=v.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=vn(e,a,i.v8_trailingSlashAwareDataRequests,`rsc`),o=!1,s=[];for(let e of t)typeof e.route.shouldRevalidate==`function`?o=!0:s.push(e.route.id);return o&&s.length>0&&n.searchParams.set(`_routes`,s.join(`,`)),[n.pathname+n.search]},[a,i.v8_trailingSlashAwareDataRequests,e,r,t]);return v.createElement(v.Fragment,null,o.map(e=>v.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})))}function Ln({page:e,matches:t,...n}){let r=Ct(),{future:i,manifest:a,routeModules:o}=jn(),{basename:s}=On(),{loaderData:c,matches:l}=kn(),u=v.useMemo(()=>Cn(e,t,l,a,r,`data`),[e,t,l,a,r]),d=v.useMemo(()=>Cn(e,t,l,a,r,`assets`),[e,t,l,a,r]),f=v.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=new Set,l=!1;if(t.forEach(e=>{let t=a.routes[e.route.id];t&&t.hasLoader&&(!u.some(t=>t.route.id===e.route.id)&&e.route.id in c&&o[e.route.id]?.shouldRevalidate||t.hasClientLoader?l=!0:n.add(e.route.id))}),n.size===0)return[];let d=vn(e,s,i.v8_trailingSlashAwareDataRequests,`data`);return l&&n.size>0&&d.searchParams.set(`_routes`,t.filter(e=>n.has(e.route.id)).map(e=>e.route.id).join(`,`)),[d.pathname+d.search]},[s,i.v8_trailingSlashAwareDataRequests,c,r,a,u,t,e,o]),p=v.useMemo(()=>wn(d,a),[d,a]),m=Fn(d);return v.createElement(v.Fragment,null,f.map(e=>v.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})),p.map(e=>v.createElement(`link`,{key:e,rel:`modulepreload`,href:e,...n})),m.map(({key:e,link:t})=>v.createElement(`link`,{key:e,nonce:n.nonce,...t,crossOrigin:t.crossOrigin??n.crossOrigin})))}function Rn(...e){return t=>{e.forEach(e=>{typeof e==`function`?e(t):e!=null&&(e.current=t)})}}v.Component;var zn=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;try{zn&&(window.__reactRouterVersion=`7.18.4`)}catch{}function Bn({basename:e,children:t,useTransitions:n,window:r}){let i=v.useRef();i.current??=oe({window:r,v5Compat:!0});let a=i.current,[o,s]=v.useState({action:a.action,location:a.location}),c=v.useCallback(e=>{n===!1?s(e):v.startTransition(()=>s(e))},[n]);return v.useLayoutEffect(()=>a.listen(c),[a,c]),v.createElement(tn,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:a,useTransitions:n})}var Vn=v.forwardRef(function({onClick:e,discover:t=`render`,prefetch:n=`none`,relative:r,reloadDocument:i,replace:a,mask:o,state:s,target:c,to:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f,...p},m){let{basename:h,navigator:g,useTransitions:_}=v.useContext(ft),y=typeof l==`string`&&S.test(l),b=Ye(l,h);l=b.to;let x=xt(l,{relative:r}),ee=Ct(),te=null;if(o){let e=Re(o,[],ee.mask?ee.mask.pathname:`/`,!0);h!==`/`&&(e.pathname=e.pathname===`/`?h:Be([h,e.pathname])),te=g.createHref(e)}let[ne,re,C]=Mn(n,p),ie=Kn(l,{replace:a,mask:o,state:s,target:c,preventScrollReset:u,relative:r,viewTransition:d,defaultShouldRevalidate:f,useTransitions:_});function ae(t){e&&e(t),t.defaultPrevented||ie(t)}let oe=!(b.isExternal||i),w=v.createElement(`a`,{...p,...C,href:(oe?te:void 0)||b.absoluteURL||x,onClick:oe?ae:e,ref:Rn(m,re),target:c,"data-discover":!y&&t===`render`?`true`:void 0});return ne&&!y?v.createElement(v.Fragment,null,w,v.createElement(Pn,{page:x})):w});Vn.displayName=`Link`;var Hn=v.forwardRef(function({"aria-current":e=`page`,caseSensitive:t=!1,className:n=``,end:r=!1,style:i,to:a,viewTransition:o,children:s,...c},l){let u=jt(a,{relative:c.relative}),d=Ct(),f=v.useContext(ot),{navigator:p,basename:m}=v.useContext(ft),h=f!=null&&Zn(u)&&o===!0,g=p.encodeLocation?p.encodeLocation(u).pathname:u.pathname,_=d.pathname,y=f&&f.navigation&&f.navigation.location?f.navigation.location.pathname:null;t||(_=_.toLowerCase(),y=y?y.toLowerCase():null,g=g.toLowerCase()),y&&m&&(y=Me(y,m)||y);let b=g!==`/`&&g.endsWith(`/`)?g.length-1:g.length,x=_===g||!r&&_.startsWith(g)&&_.charAt(b)===`/`,ee=y!=null&&(y===g||!r&&y.startsWith(g)&&y.charAt(g.length)===`/`),te={isActive:x,isPending:ee,isTransitioning:h},ne=x?e:void 0,S;S=typeof n==`function`?n(te):[n,x?`active`:null,ee?`pending`:null,h?`transitioning`:null].filter(Boolean).join(` `);let re=typeof i==`function`?i(te):i;return v.createElement(Vn,{...c,"aria-current":ne,className:S,ref:l,style:re,to:a,viewTransition:o},typeof s==`function`?s(te):s)});Hn.displayName=`NavLink`;var Un=v.forwardRef(({discover:e=`render`,fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:a,method:o=rn,action:s,onSubmit:c,relative:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f,...p},m)=>{let{useTransitions:h}=v.useContext(ft),g=Yn(),_=Xn(s,{relative:l}),y=o.toLowerCase()===`get`?`get`:`post`,b=typeof s==`string`&&S.test(s);return v.createElement(`form`,{ref:m,method:y,action:_,onSubmit:r?c:e=>{if(c&&c(e),e.defaultPrevented)return;e.preventDefault();let r=e.nativeEvent.submitter,s=r?.getAttribute(`formmethod`)||o,p=()=>g(r||e.currentTarget,{fetcherKey:t,method:s,navigate:n,replace:i,state:a,relative:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f});h&&n!==!1?v.startTransition(()=>p()):p()},...p,"data-discover":!b&&e===`render`?`true`:void 0})});Un.displayName=`Form`;function Wn(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Gn(e){let t=v.useContext(at);return w(t,Wn(e)),t}function Kn(e,{target:t,replace:n,mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,defaultShouldRevalidate:c,useTransitions:l}={}){let u=Et(),d=Ct(),f=jt(e,{relative:o});return v.useCallback(p=>{if(dn(p,t)){p.preventDefault();let t=n===void 0?de(d)===de(f):n,m=()=>u(e,{replace:t,mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,defaultShouldRevalidate:c});l?v.startTransition(()=>m()):m()}},[d,u,f,n,r,i,t,e,a,o,s,c,l])}var qn=0,Jn=()=>`__${String(++qn)}__`;function Yn(){let{router:e}=Gn(`useSubmit`),{basename:t}=v.useContext(ft),n=Kt(),r=e.fetch,i=e.navigate;return v.useCallback(async(e,a={})=>{let{action:o,method:s,encType:c,formData:l,body:u}=gn(e,t);if(a.navigate===!1){let e=a.fetcherKey||Jn();await r(e,n,a.action||o,{defaultShouldRevalidate:a.defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,flushSync:a.flushSync})}else await i(a.action||o,{defaultShouldRevalidate:a.defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,replace:a.replace,state:a.state,fromRouteId:n,flushSync:a.flushSync,viewTransition:a.viewTransition})},[r,i,t,n])}function Xn(e,{relative:t}={}){let{basename:n}=v.useContext(ft),r=v.useContext(mt);w(r,`useFormAction must be used inside a RouteContext`);let[i]=r.matches.slice(-1),a={...jt(e||`.`,{relative:t})},o=Ct();if(e==null){a.search=o.search;let e=new URLSearchParams(a.search),t=e.getAll(`index`);if(t.some(e=>e===``)){e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();a.search=n?`?${n}`:``}}return(!e||e===`.`)&&i.route.index&&(a.search=a.search?a.search.replace(/^\?/,`?index&`):`?index`),n!==`/`&&(a.pathname=a.pathname===`/`?n:Be([n,a.pathname])),de(a)}function Zn(e,{relative:t}={}){let n=v.useContext(lt);w(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=Gn(`useViewTransitionState`),i=jt(e,{relative:t});if(!n.isTransitioning)return!1;let a=Me(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=Me(n.nextLocation.pathname,r)||n.nextLocation.pathname;return ke(i.pathname,o)!=null||ke(i.pathname,a)!=null}var Qn=[{group:`Overview`,to:`/`,label:`Dashboard`},{group:`Overview`,to:`/reviews`,label:`Reviews`},{group:`Code hosts`,to:`/repositories`,label:`Repositories`},{group:`Review brain`,to:`/rules`,label:`Rules`},{group:`Review brain`,to:`/guidelines`,label:`Guidelines`},{group:`Review brain`,to:`/learnings`,label:`Learnings`},{group:`Settings`,to:`/settings/models`,label:`Models & providers`},{group:`Settings`,to:`/settings/review`,label:`Review behaviour`},{group:`Settings`,to:`/settings/depth`,label:`Depth & analysis`},{group:`Settings`,to:`/settings/summary`,label:`Summary`},{group:`Settings`,to:`/settings/automation`,label:`Triggers & chat`},{group:`Settings`,to:`/settings/files`,label:`Files & context`},{group:`Settings`,to:`/settings/users`,label:`Team & access`,visible:e=>e===`admin`},{group:`Settings`,to:`/settings/server`,label:`Server & CI`}];function $n(e){return Qn.filter(t=>!t.visible||t.visible(e)).map(({to:e,label:t,group:n})=>({to:e,label:t,group:n}))}function er(e,t){return $n(t).some(t=>t.to===e)}var tr=o((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),nr=o(((e,t)=>{t.exports=tr()})),k=nr();function A(...e){return e.filter(Boolean).join(` `)}function rr({size:e=28,spin:t=!1}){return(0,k.jsxs)(`svg`,{width:e,height:e,viewBox:`0 0 64 64`,"aria-hidden":!0,className:t?`animate-[spin_6s_linear_infinite]`:``,children:[(0,k.jsx)(`circle`,{cx:`32`,cy:`32`,r:`27`,fill:`none`,stroke:`var(--iris)`,strokeWidth:`2.5`,opacity:`.28`,strokeDasharray:`3 5`}),(0,k.jsx)(`circle`,{cx:`32`,cy:`32`,r:`18`,fill:`none`,stroke:`var(--iris)`,strokeWidth:`3.5`}),(0,k.jsx)(`circle`,{cx:`32`,cy:`32`,r:`7`,fill:`var(--iris)`}),(0,k.jsx)(`circle`,{cx:`35`,cy:`29`,r:`2`,fill:`var(--bg)`})]})}function j({variant:e=`secondary`,size:t=`md`,loading:n,className:r,children:i,...a}){return(0,k.jsxs)(`button`,{...a,disabled:a.disabled||n,className:A(`inline-flex items-center justify-center gap-2 rounded-lg font-medium transition-all select-none`,`disabled:cursor-not-allowed disabled:opacity-50 focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-iris`,t===`sm`?`h-8 px-3 text-[13px]`:`h-9 px-4 text-sm`,e===`primary`&&`bg-iris text-iris-ink hover:brightness-110 active:translate-y-px shadow-[0_1px_0_rgba(255,255,255,.25)_inset]`,e===`secondary`&&`border border-line-strong bg-panel text-ink hover:bg-panel-2`,e===`ghost`&&`text-ink-2 hover:bg-panel-2 hover:text-ink`,e===`danger`&&`border border-critical/40 text-critical hover:bg-critical/10`,r),children:[n&&(0,k.jsx)(ir,{size:14}),i]})}function ir({size:e=16}){return(0,k.jsx)(`span`,{className:`inline-block animate-spin rounded-full border-2 border-current border-r-transparent opacity-70`,style:{width:e,height:e},"aria-label":`Loading`})}var ar=`w-full rounded-lg border border-line-strong bg-panel px-3 text-ink placeholder:text-ink-3 transition-colors focus:border-iris focus:outline-none focus:ring-2 focus:ring-iris/25 disabled:opacity-60`;function M({className:e,...t}){return(0,k.jsx)(`input`,{...t,className:A(ar,`h-9`,t.type===`number`&&`font-mono`,e)})}function or({className:e,...t}){return(0,k.jsx)(`textarea`,{...t,className:A(ar,`min-h-24 py-2 leading-relaxed scrollbar-thin`,e)})}function sr({className:e,children:t,...n}){return(0,k.jsx)(`select`,{...n,className:A(ar,`h-9 cursor-pointer pr-8`,e),children:t})}function cr({checked:e,onChange:t,label:n,disabled:r}){return(0,k.jsx)(`button`,{type:`button`,role:`switch`,"aria-checked":e,"aria-label":n,disabled:r,onClick:()=>t(!e),className:A(`relative inline-flex h-[22px] w-[38px] shrink-0 items-center rounded-full border transition-colors focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-iris disabled:opacity-50`,e?`border-iris bg-iris`:`border-line-strong bg-panel-2`),children:(0,k.jsx)(`span`,{className:A(`inline-block h-4 w-4 rounded-full shadow transition-transform`,e?`translate-x-[18px] bg-iris-ink`:`translate-x-[2px] bg-ink-3`)})})}function N({label:e,hint:t,children:n,htmlFor:r}){return(0,k.jsxs)(`div`,{className:`space-y-1.5`,children:[(0,k.jsx)(`label`,{htmlFor:r,className:`block text-[13px] font-medium text-ink`,children:e}),n,t&&(0,k.jsx)(`p`,{className:`text-[12.5px] leading-snug text-ink-3`,children:t})]})}function lr({label:e,hint:t,checked:n,onChange:r,disabled:i}){return(0,k.jsxs)(`div`,{className:`flex items-start justify-between gap-6 py-3`,children:[(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`text-[13.5px] font-medium text-ink`,children:e}),t&&(0,k.jsx)(`div`,{className:`mt-0.5 text-[12.5px] leading-snug text-ink-3`,children:t})]}),(0,k.jsx)(cr,{checked:n,onChange:r,label:typeof e==`string`?e:void 0,disabled:i})]})}function P({children:e,className:t,title:n,eyebrow:r,actions:i,padded:a=!0}){return(0,k.jsxs)(`section`,{className:A(`rounded-2xl border border-line bg-panel shadow-[0_1px_0_rgba(0,0,0,.02)]`,t),children:[(n||i||r)&&(0,k.jsxs)(`header`,{className:`flex items-start justify-between gap-4 border-b border-line px-5 py-4`,children:[(0,k.jsxs)(`div`,{children:[r&&(0,k.jsx)(`div`,{className:`eyebrow mb-1`,children:r}),n&&(0,k.jsx)(`h2`,{className:`font-display text-[19px] font-medium text-ink`,children:n})]}),i&&(0,k.jsx)(`div`,{className:`flex shrink-0 items-center gap-2`,children:i})]}),(0,k.jsx)(`div`,{className:a?`px-5 py-4`:``,children:e})]})}function ur({eyebrow:e,title:t,description:n,actions:r}){return(0,k.jsxs)(`div`,{className:`rings -mx-8 -mt-8 mb-8 flex flex-wrap items-end justify-between gap-6 border-b border-line px-8 pt-10 pb-7`,children:[(0,k.jsxs)(`div`,{className:`max-w-2xl animate-rise`,children:[(0,k.jsx)(`div`,{className:`eyebrow mb-2`,children:e}),(0,k.jsx)(`h1`,{className:`font-display text-[34px] leading-[1.1] font-medium text-ink`,children:t}),n&&(0,k.jsx)(`p`,{className:`mt-3 text-[14.5px] leading-relaxed text-ink-2`,children:n})]}),r&&(0,k.jsx)(`div`,{className:`flex items-center gap-2`,children:r})]})}var dr={critical:`text-critical bg-critical/10 border-critical/30`,major:`text-major bg-major/10 border-major/30`,minor:`text-minor bg-minor/10 border-minor/30`,nitpick:`text-nit bg-nit/10 border-nit/30`};function fr({severity:e}){return(0,k.jsxs)(`span`,{className:A(`inline-flex items-center gap-1.5 rounded-md border px-1.5 py-0.5 font-mono text-[10.5px] font-medium tracking-wider uppercase`,dr[e]),children:[(0,k.jsx)(`span`,{className:`h-1.5 w-1.5 rounded-full bg-current`}),e]})}function F({children:e,tone:t=`neutral`,className:n}){return(0,k.jsx)(`span`,{className:A(`inline-flex items-center gap-1 rounded-md border px-1.5 py-0.5 text-[11.5px] font-medium`,t===`neutral`&&`border-line-strong bg-panel-2 text-ink-2`,t===`iris`&&`border-iris/40 bg-iris-soft text-iris`,t===`ok`&&`border-ok/30 bg-ok/10 text-ok`,t===`bad`&&`border-critical/30 bg-critical/10 text-critical`,t===`warn`&&`border-minor/30 bg-minor/10 text-minor`,n),children:e})}var pr={queued:{tone:`neutral`,label:`Queued`},running:{tone:`iris`,label:`Reviewing`},cancelling:{tone:`warn`,label:`Cancelling`},done:{tone:`ok`,label:`Done`},failed:{tone:`bad`,label:`Failed`},skipped:{tone:`warn`,label:`Skipped`},cancelled:{tone:`neutral`,label:`Cancelled`}};function mr({status:e}){let t=pr[e];return(0,k.jsxs)(F,{tone:t.tone,children:[(0,k.jsx)(`span`,{className:A(`h-1.5 w-1.5 rounded-full bg-current`,e===`running`&&`animate-pulse-ring`)}),t.label]})}function hr({value:e,onChange:t,placeholder:n,mono:r=!0}){let[i,a]=(0,v.useState)(``),o=n=>{let r=n.split(/[\n,]/).map(e=>e.trim()).filter(Boolean).filter(t=>!e.includes(t));r.length&&t([...e,...r]),a(``)};return(0,k.jsxs)(`div`,{className:`flex min-h-9 flex-wrap items-center gap-1.5 rounded-lg border border-line-strong bg-panel px-2 py-1.5 focus-within:border-iris focus-within:ring-2 focus-within:ring-iris/25`,children:[e.map(n=>(0,k.jsxs)(`span`,{className:A(`inline-flex items-center gap-1 rounded-md border border-line bg-panel-2 py-0.5 pr-1 pl-2 text-[12px] text-ink`,r&&`font-mono`),children:[n,(0,k.jsx)(`button`,{type:`button`,"aria-label":`Remove ${n}`,onClick:()=>t(e.filter(e=>e!==n)),className:`rounded px-1 text-ink-3 hover:bg-line hover:text-ink`,children:`×`})]},n)),(0,k.jsx)(`input`,{value:i,onChange:e=>a(e.target.value),onKeyDown:n=>{n.key===`Enter`||n.key===`,`?(n.preventDefault(),o(i)):n.key===`Backspace`&&!i&&e.length&&t(e.slice(0,-1))},onBlur:()=>i&&o(i),onPaste:e=>{let t=e.clipboardData.getData(`text`);/[\n,]/.test(t)&&(e.preventDefault(),o(t))},placeholder:e.length?``:n,className:A(`min-w-32 flex-1 bg-transparent px-1 text-[13px] text-ink placeholder:text-ink-3 focus:outline-none`,r&&`font-mono`)})]})}function gr({value:e,options:t,onChange:n}){return(0,k.jsx)(`div`,{className:`inline-flex rounded-lg border border-line-strong bg-panel-2 p-0.5`,children:t.map(t=>(0,k.jsx)(`button`,{type:`button`,title:t.hint,onClick:()=>n(t.value),className:A(`rounded-md px-3 py-1.5 text-[13px] font-medium transition-colors`,e===t.value?`bg-panel text-ink shadow-sm ring-1 ring-line-strong`:`text-ink-3 hover:text-ink`),children:t.label},t.value))})}function _r({open:e,onClose:t,title:n,children:r,footer:i,wide:a}){let o=(0,v.useRef)(null);return(0,v.useEffect)(()=>{if(!e)return;let n=e=>e.key===`Escape`&&t();return window.addEventListener(`keydown`,n),o.current?.querySelector(`input, textarea, select, button`)?.focus(),()=>window.removeEventListener(`keydown`,n)},[e,t]),e?(0,k.jsx)(`div`,{className:`fixed inset-0 z-50 flex items-start justify-center overflow-y-auto bg-black/45 p-6 pt-[8vh] backdrop-blur-[2px]`,onMouseDown:e=>e.target===e.currentTarget&&t(),children:(0,k.jsxs)(`div`,{ref:o,role:`dialog`,"aria-modal":!0,className:A(`w-full animate-rise rounded-2xl border border-line-strong bg-panel shadow-2xl`,a?`max-w-3xl`:`max-w-lg`),children:[(0,k.jsxs)(`div`,{className:`flex items-center justify-between border-b border-line px-5 py-4`,children:[(0,k.jsx)(`h3`,{className:`font-display text-[19px] font-medium`,children:n}),(0,k.jsx)(`button`,{onClick:t,"aria-label":`Close`,className:`rounded-md px-2 py-1 text-ink-3 hover:bg-panel-2 hover:text-ink`,children:`✕`})]}),(0,k.jsx)(`div`,{className:`max-h-[70vh] overflow-y-auto px-5 py-4 scrollbar-thin`,children:r}),i&&(0,k.jsx)(`div`,{className:`flex justify-end gap-2 border-t border-line px-5 py-3`,children:i})]})}):null}function vr({title:e,children:t,action:n}){return(0,k.jsxs)(`div`,{className:`flex flex-col items-center px-6 py-12 text-center`,children:[(0,k.jsx)(`div`,{className:`mb-4 opacity-60`,children:(0,k.jsx)(rr,{size:40})}),(0,k.jsx)(`div`,{className:`font-display text-lg text-ink`,children:e}),t&&(0,k.jsx)(`div`,{className:`mt-1.5 max-w-md text-[13.5px] text-ink-3`,children:t}),n&&(0,k.jsx)(`div`,{className:`mt-5`,children:n})]})}function yr({children:e,className:t}){return(0,k.jsx)(`pre`,{className:A(`overflow-x-auto rounded-xl border border-line bg-panel-2 px-4 py-3 font-mono text-[12.5px] leading-relaxed text-ink scrollbar-thin`,t),children:(0,k.jsx)(`code`,{children:e})})}function br({text:e,label:t=`Copy`}){let[n,r]=(0,v.useState)(!1);return(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:async()=>{await navigator.clipboard.writeText(e),r(!0),setTimeout(()=>r(!1),1500)},children:n?`Copied`:t})}var xr=(0,v.createContext)(()=>{});function Sr({children:e}){let[t,n]=(0,v.useState)([]),r=(0,v.useCallback)((e,t)=>{let r=Date.now()+Math.random();n(n=>[...n,{id:r,tone:e,text:t}]),setTimeout(()=>n(e=>e.filter(e=>e.id!==r)),e===`bad`?7e3:3500)},[]);return(0,k.jsxs)(xr.Provider,{value:r,children:[e,(0,k.jsx)(`div`,{className:`fixed right-5 bottom-5 z-[60] flex w-[380px] flex-col gap-2`,"aria-live":`polite`,children:t.map(e=>(0,k.jsx)(`div`,{className:A(`animate-rise rounded-xl border bg-panel px-4 py-3 text-[13.5px] shadow-xl`,e.tone===`ok`&&`border-ok/40`,e.tone===`bad`&&`border-critical/40 text-critical`,e.tone===`info`&&`border-line-strong`),children:e.text},e.id))})]})}function Cr(){return(0,v.useContext)(xr)}function wr(e){if(!e)return``;let t=new Date(e.includes(`T`)?e:`${e.replace(` `,`T`)}Z`),n=Math.round((Date.now()-t.getTime())/1e3);if(n<45)return`just now`;let r=Math.round(n/60);if(r<60)return`${r}m ago`;let i=Math.round(r/60);if(i<24)return`${i}h ago`;let a=Math.round(i/24);return a<30?`${a}d ago`:t.toLocaleDateString()}function Tr({platform:e,size:t=16}){return e===`github`?(0,k.jsx)(`svg`,{width:t,height:t,viewBox:`0 0 24 24`,fill:`currentColor`,"aria-label":`GitHub`,children:(0,k.jsx)(`path`,{d:`M12 .5A11.5 11.5 0 0 0 .5 12a11.5 11.5 0 0 0 7.86 10.92c.58.1.79-.25.79-.56v-2c-3.2.7-3.88-1.37-3.88-1.37-.52-1.33-1.28-1.69-1.28-1.69-1.05-.71.08-.7.08-.7 1.16.08 1.77 1.19 1.77 1.19 1.03 1.77 2.7 1.26 3.36.96.1-.75.4-1.26.73-1.55-2.55-.29-5.24-1.28-5.24-5.69 0-1.26.45-2.29 1.19-3.1-.12-.29-.52-1.46.11-3.05 0 0 .97-.31 3.17 1.18a11 11 0 0 1 5.77 0c2.2-1.49 3.17-1.18 3.17-1.18.63 1.59.23 2.76.11 3.05.74.81 1.19 1.84 1.19 3.1 0 4.42-2.7 5.39-5.26 5.68.41.36.78 1.06.78 2.14v3.17c0 .31.21.67.8.56A11.5 11.5 0 0 0 23.5 12 11.5 11.5 0 0 0 12 .5Z`})}):e===`gitlab`?(0,k.jsx)(`svg`,{width:t,height:t,viewBox:`0 0 24 24`,fill:`currentColor`,"aria-label":`GitLab`,children:(0,k.jsx)(`path`,{d:`m23.6 9.6-.03-.09L20.3.97a.85.85 0 0 0-1.62.06l-2.2 6.75H7.53L5.32 1.03a.85.85 0 0 0-1.62-.06L.43 9.5l-.03.09a6.05 6.05 0 0 0 2 7l.01.01.03.02 4.98 3.73 2.47 1.86 1.5 1.14a1.01 1.01 0 0 0 1.22 0l1.5-1.14 2.47-1.86 5.01-3.75h.01a6.05 6.05 0 0 0 2-7Z`})}):e===`azure`?(0,k.jsx)(`svg`,{width:t,height:t,viewBox:`0 0 24 24`,fill:`currentColor`,"aria-label":`Azure DevOps`,children:(0,k.jsx)(`path`,{d:`M22 4.5v14.6L16 24l-9.3-3.4v3.4l-5.3-6.9 15.6 1.2V4.9L22 4.5ZM16.8 5.3 8 0v3.6L.1 5.9 0 7.4v9l3.3 1.4V8.6l13.5-3.3Z`})}):(0,k.jsx)(`svg`,{width:t,height:t,viewBox:`0 0 24 24`,fill:`currentColor`,"aria-label":`Bitbucket`,children:(0,k.jsx)(`path`,{d:`M.78 1.21a.77.77 0 0 0-.77.89l3.26 19.8c.08.5.51.87 1.02.87h15.6a.77.77 0 0 0 .77-.65l3.26-20.01a.77.77 0 0 0-.77-.89Zm13.7 14.3H9.5L8.15 8.47h7.53Z`})})}var Er={"/":(0,k.jsx)(Dr,{d:`M3 13h8V3H3v10Zm0 8h8v-6H3v6Zm10 0h8V11h-8v10Zm0-18v6h8V3h-8Z`}),"/reviews":(0,k.jsx)(Dr,{d:`M4 5h16M4 12h10M4 19h7m9-5-4 4-2-2`,stroke:!0}),"/repositories":(0,k.jsx)(Dr,{d:`M6 3v12m0 0a3 3 0 1 0 0 6 3 3 0 0 0 0-6Zm12-6a3 3 0 1 0 0-6 3 3 0 0 0 0 6Zm0 0c0 6-12 3-12 9`,stroke:!0}),"/rules":(0,k.jsx)(Dr,{d:`M9 6h11M9 12h11M9 18h11M4 6l1 1 2-2M4 12l1 1 2-2M4 18l1 1 2-2`,stroke:!0}),"/guidelines":(0,k.jsx)(Dr,{d:`M5 4h11l3 3v13H5V4Zm4 6h7m-7 4h7m-7 4h4`,stroke:!0}),"/learnings":(0,k.jsx)(Dr,{d:`M12 3a6 6 0 0 0-3.5 10.9V17h7v-3.1A6 6 0 0 0 12 3Zm-2 17h4`,stroke:!0}),"/settings/models":(0,k.jsx)(Dr,{d:`M12 2 3 7v10l9 5 9-5V7l-9-5Zm0 0v20M3 7l9 5 9-5`,stroke:!0}),"/settings/review":(0,k.jsx)(Dr,{d:`M3 12s3.5-7 9-7 9 7 9 7-3.5 7-9 7-9-7-9-7Zm9 3a3 3 0 1 0 0-6 3 3 0 0 0 0 6Z`,stroke:!0}),"/settings/depth":(0,k.jsx)(Dr,{d:`M12 3v18M5 8l7-5 7 5M5 16l7 5 7-5M3 12h18`,stroke:!0}),"/settings/summary":(0,k.jsx)(Dr,{d:`M4 6h16M4 10h16M4 14h10M4 18h7`,stroke:!0}),"/settings/automation":(0,k.jsx)(Dr,{d:`M13 2 4 14h7l-1 8 9-12h-7l1-8Z`,stroke:!0}),"/settings/files":(0,k.jsx)(Dr,{d:`M3 7h6l2 2h10v10H3V7Zm0 0V5h6`,stroke:!0}),"/settings/users":(0,k.jsx)(Dr,{d:`M16 19v-1a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v1m7-9a3 3 0 1 0 0-6 3 3 0 0 0 0 6Zm13 9v-1a4 4 0 0 0-3-3.9M16 4.1a3 3 0 0 1 0 5.8`,stroke:!0}),"/settings/server":(0,k.jsx)(Dr,{d:`M4 5h16v6H4V5Zm0 8h16v6H4v-6Zm3-5h.01M7 16h.01`,stroke:!0})};function Dr({d:e,stroke:t}){return(0,k.jsx)(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,"aria-hidden":!0,fill:t?`none`:`currentColor`,stroke:t?`currentColor`:`none`,strokeWidth:`1.7`,strokeLinecap:`round`,strokeLinejoin:`round`,children:(0,k.jsx)(`path`,{d:e})})}function Or(){let[e,t]=(0,v.useState)(()=>document.documentElement.dataset.theme??`system`);(0,v.useEffect)(()=>{if(e===`system`){delete document.documentElement.dataset.theme;try{localStorage.removeItem(`argus-theme`)}catch{}}else{document.documentElement.dataset.theme=e;try{localStorage.setItem(`argus-theme`,e)}catch{}}},[e]);let n=e===`system`?`dark`:e===`dark`?`light`:`system`;return(0,k.jsxs)(`button`,{onClick:()=>t(n),className:`flex w-full items-center justify-between rounded-lg px-2.5 py-1.5 text-[12.5px] text-ink-3 hover:bg-panel-2 hover:text-ink`,title:`Switch theme`,children:[(0,k.jsx)(`span`,{children:`Theme`}),(0,k.jsx)(`span`,{className:`font-mono text-[11px] uppercase`,children:e})]})}function kr({onLogout:e,auth:t}){let n=$n(t.role??`admin`),r=[...new Set(n.map(e=>e.group))].map(e=>({group:e,items:n.filter(t=>t.group===e)}));return(0,k.jsxs)(`div`,{className:`flex min-h-screen`,children:[(0,k.jsxs)(`aside`,{className:`sticky top-0 flex h-screen w-[244px] shrink-0 flex-col border-r border-line bg-panel/60`,children:[(0,k.jsxs)(`div`,{className:`flex items-center gap-2.5 px-5 pt-6 pb-5`,children:[(0,k.jsx)(rr,{size:30}),(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`font-display text-[21px] leading-none font-semibold tracking-tight`,children:`Argus`}),(0,k.jsx)(`div`,{className:`eyebrow mt-1 !text-[9.5px]`,children:`sees every diff`})]})]}),(0,k.jsx)(`nav`,{className:`flex-1 space-y-5 overflow-y-auto px-3 pb-4 scrollbar-thin`,children:r.map(e=>(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`eyebrow px-2.5 pb-1.5`,children:e.group}),(0,k.jsx)(`ul`,{className:`space-y-0.5`,children:e.items.map(e=>(0,k.jsx)(`li`,{children:(0,k.jsx)(Hn,{to:e.to,end:e.to===`/`,className:({isActive:e})=>A(`group relative flex items-center gap-2.5 rounded-lg px-2.5 py-[7px] text-[13.5px] transition-colors`,e?`bg-iris-soft font-medium text-ink`:`text-ink-2 hover:bg-panel-2 hover:text-ink`),children:({isActive:t})=>(0,k.jsxs)(k.Fragment,{children:[t&&(0,k.jsx)(`span`,{className:`absolute top-1.5 bottom-1.5 -left-3 w-[3px] rounded-r bg-iris`}),(0,k.jsx)(`span`,{className:t?`text-iris`:`text-ink-3 group-hover:text-ink-2`,children:Er[e.to]}),e.label]})})},e.to))})]},e.group))}),(0,k.jsxs)(`div`,{className:`space-y-0.5 border-t border-line p-3`,children:[t.user&&(0,k.jsxs)(`div`,{className:`mb-1 flex items-center justify-between gap-2 px-2.5 py-1`,children:[(0,k.jsx)(`span`,{className:`truncate text-[12.5px] text-ink-2`,title:t.user.email,children:t.user.name||t.user.email}),(0,k.jsx)(F,{tone:t.role===`admin`?`iris`:`neutral`,children:t.role})]}),(0,k.jsx)(Or,{}),t.passwordRequired&&(0,k.jsx)(`button`,{onClick:e,className:`w-full rounded-lg px-2.5 py-1.5 text-left text-[12.5px] text-ink-3 hover:bg-panel-2 hover:text-ink`,children:`Sign out`})]})]}),(0,k.jsx)(`main`,{className:`min-w-0 flex-1 px-8 pt-8 pb-28`,children:(0,k.jsx)(`div`,{className:`mx-auto max-w-[1080px]`,children:(0,k.jsx)($t,{})})})]})}var Ar=class extends Error{status;data;constructor(e,t,n){super(t),this.status=e,this.data=n}};function jr(e){if(e)try{return JSON.parse(e)}catch{return}}function Mr(e,t,n){let r=n&&typeof n==`object`?n.error:void 0;return typeof r==`string`&&r?r:e===403?`You do not have permission to do this.`:t||`Request failed (HTTP ${e})`}async function I(e,t={}){let{json:n,...r}=t,i=(r.method??`GET`).toUpperCase(),a=n===void 0?r.body===void 0&&i!==`GET`&&i!==`HEAD`?`{}`:void 0:JSON.stringify(n),o=await fetch(`/api${e}`,{...r,credentials:`same-origin`,headers:{...a===void 0?{}:{"Content-Type":`application/json`},...r.headers??{}},...a===void 0?{}:{body:a}}),s=await o.text(),c=jr(s);if(!o.ok)throw o.status===401&&!e.startsWith(`/auth/`)&&window.dispatchEvent(new Event(`argus:unauthorized`)),new Ar(o.status,Mr(o.status,o.statusText,c),c);if(s&&c===void 0)throw new Ar(o.status,`Unexpected non-JSON response from ${e}`);return c}function Nr(e,t=[]){let[n,r]=(0,v.useState)(void 0),[i,a]=(0,v.useState)(void 0),[o,s]=(0,v.useState)(!!e),c=(0,v.useRef)(0),l=(0,v.useCallback)(async()=>{if(!e)return;let t=++c.current;s(!0);try{let n=await I(e);t===c.current&&(r(n),a(void 0))}catch(e){t===c.current&&a(e.message)}finally{t===c.current&&s(!1)}},[e]);return(0,v.useEffect)(()=>{l()},[l,...t]),{data:n,error:i,loading:o,reload:l,setData:r}}function Pr(e,t){let n=(0,v.useRef)(e);n.current=e;let r=(0,v.useRef)(t);r.current=t,(0,v.useEffect)(()=>{let e,t,i=!1,a=()=>{e=new EventSource(`/api/reviews/stream`),e.onopen=()=>{i&&r.current?.(),i=!1},e.addEventListener(`review`,e=>{try{n.current(JSON.parse(e.data))}catch{}}),e.onerror=()=>{i=!0,e?.close(),t=setTimeout(a,4e3)}};return a(),()=>{e?.close(),t&&clearTimeout(t)}},[])}var Fr=[`viewer`,`maintainer`,`admin`],Ir=[`models`,`execution.sandbox`,`execution.isolation`,`execution.runtime`,`execution.image`,`execution.installCommand`,`execution.testCommand`,`execution.cpus`,`execution.memory`,`execution.timeoutSec`,`execution.testTimeoutSec`,`execution.proofTimeoutSec`,`analyzers.semgrepConfig`,`analyzers.timeoutSec`,`tickets.allowedRepos`,`tickets.projectKeys`,`review.approveWhenClean`,`review.requestChangesOn`,`review.maxCostUsd`,`review.timeoutMinutes`,`review.status`],Lr=(0,v.createContext)(void 0);function Rr(){return(0,v.useContext)(Lr)?.role??`admin`}function zr(e){return Fr.indexOf(Rr())>=Fr.indexOf(e)}function Br(){return(0,v.useContext)(Lr)?.adminOnlyRepoPaths??Ir}function Vr(e,t){return t.split(`.`).reduce((e,t)=>e&&typeof e==`object`?e[t]:void 0,e)}function Hr(e,t,n){let r=t.split(`.`),i=structuredClone(e),a=i;r.slice(0,-1).forEach(e=>{let t=a[e];a[e]=t&&typeof t==`object`&&!Array.isArray(t)?{...t}:{},a=a[e]});let o=r[r.length-1];return n===void 0?delete a[o]:a[o]=n,i}function Ur(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function Wr(e,t){if(Ur(e)&&Ur(t)){let n={};for(let r of Object.keys(e)){let i=Wr(e[r],t[r]);i!==void 0&&(n[r]=i)}return Object.keys(n).length?n:void 0}return Ur(e)&&t===void 0?e:JSON.stringify(e)===JSON.stringify(t)?void 0:e}function Gr(e,t){let n=structuredClone(e);for(let e of t){let t=e.split(`.`),r=n;for(let e of t.slice(0,-1))r=Ur(r)?r[e]:void 0;Ur(r)&&delete r[t[t.length-1]]}return n}function Kr(e,t){if(!Ur(e)||!Ur(t))return t===void 0?e:t;let n={...e};for(let[r,i]of Object.entries(t))i!==void 0&&(n[r]=r in e?Kr(e[r],i):i);return n}var qr=(e,t=Ir)=>t.some(t=>e===t||e.startsWith(`${t}.`)),Jr=(0,v.createContext)(null);function Yr(){let e=(0,v.useContext)(Jr);if(!e)throw Error(`useEditor must be used inside a ConfigEditor`);return e}function Xr({base:e,meta:t,stored:n,onSave:r,scope:i,stayOn:a,children:o}){let s=(0,v.useMemo)(()=>Kr(e,n),[e,n]),[c,l]=(0,v.useState)(s),[u,d]=(0,v.useState)(!1),f=Cr(),p=zr(`admin`),m=Br(),h=i===`repository`&&!p;(0,v.useEffect)(()=>l(s),[s]);let g=JSON.stringify(c)!==JSON.stringify(s);(0,v.useEffect)(()=>{if(!g)return;let e=e=>{e.preventDefault()};return window.addEventListener(`beforeunload`,e),()=>window.removeEventListener(`beforeunload`,e)},[g]);let _=(a??[]).join(`|`);(0,v.useEffect)(()=>{if(!g)return;let e=_?_.split(`|`):[window.location.pathname],t=t=>{if(t.defaultPrevented||t.button!==0||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey)return;let n=t.target?.closest?.(`a[href]`);if(!n||n.target&&n.target!==`_self`||n.hasAttribute(`download`))return;let r=new URL(n.href,window.location.href);r.origin===window.location.origin&&(e.some(e=>r.pathname===e||r.pathname.startsWith(`${e}/`))||window.confirm(`You have unsaved settings. Leave this page and discard them?`)||(t.preventDefault(),t.stopPropagation()))};return document.addEventListener(`click`,t,!0),()=>document.removeEventListener(`click`,t,!0)},[g,_]);let y=(0,v.useCallback)(async()=>{d(!0);try{let t=Wr({...c,pathInstructions:(c.pathInstructions??[]).filter(e=>e.path.trim()&&e.instructions.trim())},e)??{};await r(h?Gr(t,m):t),f(`ok`,`Settings saved`)}catch(e){f(`bad`,e.message)}finally{d(!1)}},[c,e,r,f,h,m]),b={value:c,base:e,meta:t,dirty:g,saving:u,scope:i,get:e=>Vr(c,e),set:(e,t)=>l(n=>Hr(n,e,t)),isLocked:e=>h&&qr(e,m),lockNote:`Only admins can change this for a repository`,isOverridden:t=>JSON.stringify(Vr(c,t))!==JSON.stringify(Vr(e,t)),resetPath:t=>l(n=>Hr(n,t,structuredClone(Vr(e,t)))),save:y,discard:()=>l(s)};return(0,k.jsxs)(Jr.Provider,{value:b,children:[o,g&&(0,k.jsxs)(`div`,{className:`fixed bottom-5 left-1/2 z-40 flex -translate-x-1/2 animate-rise items-center gap-4 rounded-2xl border border-line-strong bg-panel/95 py-2.5 pr-2.5 pl-5 shadow-2xl backdrop-blur`,children:[(0,k.jsx)(`span`,{className:`text-[13.5px] text-ink-2`,children:`Unsaved changes`}),(0,k.jsx)(j,{variant:`ghost`,size:`sm`,onClick:b.discard,children:`Discard`}),(0,k.jsx)(j,{variant:`primary`,size:`sm`,loading:u,onClick:()=>void y(),children:`Save changes`})]})]})}function Zr(){let[e,t]=(0,v.useState)(),[n,r]=(0,v.useState)(),[i,a]=(0,v.useState)(),o=(0,v.useCallback)(async()=>{try{let[e,n]=await Promise.all([I(`/meta`),I(`/config`)]);t(e),r(n.config)}catch(e){a(e.message)}},[]);return(0,v.useEffect)(()=>{o()},[o]),{meta:e,stored:n,error:i,save:(0,v.useCallback)(async e=>{let t=await I(`/config`,{method:`PUT`,json:e});r(t.config)},[])}}function Qr(){let[e,t]=(0,v.useState)(``),[n,r]=(0,v.useState)(!1),[i,a]=(0,v.useState)(!1),[o,s]=(0,v.useState)(``),[c,l]=(0,v.useState)(!1),u=Cr(),d=Et();return zr(`maintainer`)?(0,k.jsxs)(`form`,{className:`space-y-3`,onSubmit:async t=>{t.preventDefault(),l(!0);try{let t={url:e.trim(),full:n,dryRun:i};o.trim()&&(t.focus=o.trim());let{review:r}=await I(`/reviews`,{method:`POST`,json:t});d(`/reviews/${r.id}`)}catch(e){u(`bad`,e.message)}finally{l(!1)}},children:[(0,k.jsxs)(`div`,{className:`flex gap-2`,children:[(0,k.jsx)(M,{value:e,onChange:e=>t(e.target.value),placeholder:`https://github.com/owner/repo/pull/42`,className:`font-mono`}),(0,k.jsx)(j,{variant:`primary`,type:`submit`,loading:c,disabled:!/^https?:\/\//.test(e.trim()),children:`Review`})]}),(0,k.jsxs)(`div`,{className:`flex flex-wrap items-center gap-x-6 gap-y-2 text-[12.5px] text-ink-2`,children:[(0,k.jsxs)(`label`,{className:`flex items-center gap-2`,children:[(0,k.jsx)(cr,{checked:n,onChange:r,label:`Full review`}),` Full review (ignore earlier reviews)`]}),(0,k.jsxs)(`label`,{className:`flex items-center gap-2`,children:[(0,k.jsx)(cr,{checked:i,onChange:a,label:`Dry run`}),` Dry run (don't post)`]}),(0,k.jsx)(`input`,{value:o,onChange:e=>s(e.target.value),placeholder:`Optional focus, e.g. auth and sessions`,className:`h-8 min-w-60 flex-1 rounded-lg border border-line bg-transparent px-2.5 focus:border-iris focus:outline-none`})]})]}):(0,k.jsx)(`p`,{className:`text-[13px] text-ink-3`,children:`Starting reviews needs the maintainer role.`})}function $r(e){if(!e.usage)return``;if(e.usage.costUsd!==void 0)return`$${e.usage.costUsd.toFixed(e.usage.costUsd<.1?3:2)}`;let t=e.usage.inputTokens+e.usage.outputTokens;return t?`${(t/1e3).toFixed(1)}k tok`:``}function ei({reviews:e,loading:t,onChange:n,hideRepo:r}){let i=Et(),a=Cr(),o=zr(`maintainer`);return t&&!e?(0,k.jsx)(`div`,{className:`flex justify-center p-10 text-ink-3`,children:(0,k.jsx)(ir,{})}):e?.length?(0,k.jsxs)(`table`,{className:`w-full text-[13px]`,children:[(0,k.jsx)(`thead`,{children:(0,k.jsx)(`tr`,{className:`border-b border-line text-left`,children:[`Pull request`,`Status`,`Findings`,`Cost`,`When`,``].map(e=>(0,k.jsx)(`th`,{className:`eyebrow px-5 py-2.5 font-normal`,children:e},e))})}),(0,k.jsx)(`tbody`,{className:`divide-y divide-line`,children:e.map(e=>(0,k.jsxs)(`tr`,{onClick:()=>i(`/reviews/${e.id}`),className:`cursor-pointer transition-colors hover:bg-panel-2/60`,children:[(0,k.jsxs)(`td`,{className:`max-w-[420px] px-5 py-3`,children:[(0,k.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,k.jsx)(`span`,{className:`text-ink-3`,children:(0,k.jsx)(Tr,{platform:e.platform,size:14})}),(0,k.jsx)(`span`,{className:`truncate font-medium text-ink`,children:e.prTitle??`#${e.prNumber}`}),e.source===`ci`&&(0,k.jsx)(`span`,{title:`Ran in CI`,children:(0,k.jsx)(F,{className:`shrink-0`,children:`CI`})})]}),(0,k.jsxs)(`div`,{className:`mt-0.5 truncate pl-[22px] font-mono text-[11.5px] text-ink-3`,children:[!r&&`${e.owner}/${e.name} `,`#`,e.prNumber,e.trigger!==`auto`&&` · ${e.trigger}`,e.options.full&&` · full`,e.options.dryRun&&` · dry run`]})]}),(0,k.jsxs)(`td`,{className:`px-5 py-3`,children:[(0,k.jsx)(mr,{status:e.status}),e.status===`running`&&e.progress&&(0,k.jsx)(`div`,{className:`mt-1 max-w-[220px] truncate text-[11.5px] text-ink-3`,title:e.progress.message,children:e.progress.message}),(e.status===`skipped`||e.status===`failed`)&&(e.reason||e.error)&&(0,k.jsx)(`div`,{className:`mt-1 max-w-[220px] truncate text-[11.5px] text-ink-3`,title:e.reason??e.error??``,children:e.reason??e.error})]}),(0,k.jsx)(`td`,{className:A(`px-5 py-3 font-mono`,e.findingsCount?`text-ink`:`text-ink-3`),children:e.status===`done`?e.findingsCount:`—`}),(0,k.jsx)(`td`,{className:`px-5 py-3 font-mono text-ink-3`,children:$r(e)}),(0,k.jsx)(`td`,{className:`px-5 py-3 whitespace-nowrap text-ink-3`,children:wr(e.createdAt)}),(0,k.jsxs)(`td`,{className:`px-5 py-3 text-right`,onClick:e=>e.stopPropagation(),children:[o&&e.source!==`ci`&&(e.status===`queued`||e.status===`running`)&&(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:async()=>{try{await I(`/reviews/${e.id}/cancel`,{method:`POST`}),n?.()}catch(e){a(`bad`,e.message)}},children:`Cancel`}),o&&e.source!==`ci`&&(e.status===`failed`||e.status===`cancelled`)&&(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:async()=>{try{await I(`/reviews/${e.id}/retry`,{method:`POST`}),n?.()}catch(e){a(`bad`,e.message)}},children:`Retry`}),e.prUrl&&(0,k.jsx)(`a`,{href:e.prUrl,target:`_blank`,rel:`noreferrer`,className:`ml-1 text-[12px] text-ink-3 hover:text-iris`,onClick:e=>e.stopPropagation(),children:`Open ↗`})]})]},e.id))})]}):(0,k.jsx)(vr,{title:`No reviews yet`,children:`Reviews appear here as soon as a pull request is opened or you start one manually.`})}var ti=[{key:`fixed`,label:`Fixed`,className:`bg-ok`},{key:`accepted`,label:`Accepted`,className:`bg-ok/60`},{key:`resolved`,label:`Resolved`,className:`bg-iris/70`},{key:`dismissed`,label:`Dismissed`,className:`bg-critical/70`},{key:`open`,label:`Open`,className:`bg-line-strong`}],ni=e=>`${Math.round(e*100)}%`;function ri({repositoryId:e}){let t=Nr(e===void 0?`/feedback`:`/feedback?repositoryId=${e}`).data;return(0,k.jsx)(P,{eyebrow:`Learning`,title:`How developers respond to comments`,children:t?t.posted===0?(0,k.jsx)(`p`,{className:`text-[13px] text-ink-3`,children:`No posted findings yet. Argus tracks every inline comment: fixed in a later push, thumbs up or down, replies like “good catch” or “false positive”, and resolved threads. Categories the team keeps dismissing automatically need more confidence.`}):(0,k.jsxs)(`div`,{className:`space-y-5`,children:[(0,k.jsxs)(`div`,{className:`flex flex-wrap items-end gap-6`,children:[(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`font-display text-[40px] leading-none tabular-nums`,children:t.decided?ni(t.acceptance):`—`}),(0,k.jsxs)(`div`,{className:`mt-1 text-[12px] text-ink-3`,children:[`accepted of `,t.decided,` decided · `,t.posted,` posted`]})]}),(0,k.jsxs)(`div`,{className:`min-w-[240px] flex-1`,children:[(0,k.jsx)(`div`,{className:`flex h-2.5 overflow-hidden rounded-full bg-panel-2`,children:ti.map(e=>{let n=t.outcomes[e.key];return n?(0,k.jsx)(`span`,{className:e.className,style:{width:`${n/t.posted*100}%`},title:`${e.label}: ${n}`},e.key):null})}),(0,k.jsx)(`div`,{className:`mt-2 flex flex-wrap gap-x-4 gap-y-1 text-[12px] text-ink-3`,children:ti.map(e=>(0,k.jsxs)(`span`,{className:`flex items-center gap-1.5`,children:[(0,k.jsx)(`span`,{className:A(`h-2 w-2 rounded-full`,e.className)}),e.label,` `,(0,k.jsx)(`span`,{className:`font-mono text-ink-2`,children:t.outcomes[e.key]})]},e.key))})]})]}),t.byCategory.length>0&&(0,k.jsxs)(`div`,{className:`space-y-1.5`,children:[(0,k.jsx)(`div`,{className:`eyebrow`,children:`By category`}),t.byCategory.map(e=>(0,k.jsxs)(`div`,{className:`grid grid-cols-[130px_1fr_70px_110px] items-center gap-3 text-[12.5px]`,children:[(0,k.jsx)(`span`,{className:`font-mono text-ink`,children:e.category}),(0,k.jsx)(`span`,{className:`h-1.5 overflow-hidden rounded-full bg-panel-2`,children:(0,k.jsx)(`span`,{className:A(`block h-full`,e.acceptance>=.5?`bg-ok`:`bg-critical/70`),style:{width:e.decided?ni(e.acceptance):`0%`}})}),(0,k.jsx)(`span`,{className:`text-right font-mono text-ink-2`,children:e.decided?ni(e.acceptance):`—`}),(0,k.jsxs)(`span`,{className:`text-right`,children:[e.adjustment>0&&(0,k.jsxs)(F,{tone:`warn`,children:[`+`,e.adjustment,` stricter`]}),e.adjustment<0&&(0,k.jsxs)(F,{tone:`ok`,children:[e.adjustment,` looser`]}),e.adjustment===0&&(0,k.jsxs)(`span`,{className:`text-[11.5px] text-ink-3`,children:[e.decided,` decided`]})]})]},e.category))]}),t.recent.some(e=>e.outcome===`dismissed`)&&(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`eyebrow mb-1.5`,children:`Recently dismissed`}),(0,k.jsx)(`ul`,{className:`space-y-1 text-[12.5px]`,children:t.recent.filter(e=>e.outcome===`dismissed`).slice(0,5).map(e=>(0,k.jsxs)(`li`,{className:`flex flex-wrap gap-x-2`,children:[(0,k.jsx)(`span`,{className:`text-ink`,children:e.title}),(0,k.jsxs)(`span`,{className:`font-mono text-ink-3`,children:[e.path,` · #`,e.prNumber]}),e.signals[0]&&(0,k.jsx)(`span`,{className:`text-ink-3 italic`,children:e.signals.join(`, `)})]},`${e.repositoryId}-${e.prNumber}-${e.fingerprint}`))})]})]}):(0,k.jsxs)(`div`,{className:`flex items-center gap-2 text-[13px] text-ink-3`,children:[(0,k.jsx)(ir,{size:13}),` Loading…`]})})}function ii({label:e,value:t,sub:n,delay:r}){return(0,k.jsxs)(`div`,{className:`animate-rise rounded-2xl border border-line bg-panel px-5 py-4`,style:{animationDelay:`${r}ms`},children:[(0,k.jsx)(`div`,{className:`eyebrow`,children:e}),(0,k.jsx)(`div`,{className:`mt-2 font-display text-[34px] leading-none font-medium tabular-nums`,children:t}),n&&(0,k.jsx)(`div`,{className:`mt-1.5 text-[12px] text-ink-3`,children:n})]})}function ai({done:e,title:t,text:n,to:r}){return(0,k.jsxs)(Vn,{to:r,className:A(`group flex items-start gap-3 rounded-xl border px-4 py-3 transition-colors`,e?`border-line`:`border-iris/40 hover:bg-iris-soft/50`),children:[(0,k.jsx)(`span`,{className:A(`mt-0.5 flex h-5 w-5 shrink-0 items-center justify-center rounded-full border text-[11px]`,e?`border-ok bg-ok text-white`:`border-iris text-iris`),children:e?`✓`:``}),(0,k.jsxs)(`span`,{children:[(0,k.jsx)(`span`,{className:A(`block font-medium`,e&&`text-ink-3 line-through decoration-ink-3/40`),children:t}),(0,k.jsx)(`span`,{className:`text-[12.5px] text-ink-3`,children:n})]})]})}function oi(){let e=Nr(`/status`),t=Nr(`/reviews?limit=12`);Pr(n=>{t.setData(e=>e&&{reviews:e.reviews.some(e=>e.id===n.id)?e.reviews.map(e=>e.id===n.id?{...e,...n}:e):[n,...e.reviews].slice(0,12)}),(n.status===`done`||n.status===`failed`)&&e.reload()},()=>{t.reload(),e.reload()});let n=e.data,r=n&&n.integrations>0&&n.repositories>0&&n.providerConfigured,i=t.data?.reviews.filter(e=>e.status===`running`||e.status===`queued`).length??0;return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Overview`,title:(0,k.jsxs)(`span`,{className:`flex items-center gap-4`,children:[`Every diff, seen.`,i>0&&(0,k.jsxs)(F,{tone:`iris`,children:[i,` in progress`]})]}),description:n?(0,k.jsxs)(k.Fragment,{children:[`Reviewing with `,(0,k.jsx)(`span`,{className:`font-mono text-ink`,children:n.reviewModel}),`.`]}):`Self-hosted AI code review for GitHub, GitLab, Bitbucket and Azure DevOps.`}),(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-4`,children:[(0,k.jsx)(ii,{delay:0,label:`Reviews`,value:String(n?.stats.total??`–`),sub:n?`${n.stats.last7} in the last 7 days`:void 0}),(0,k.jsx)(ii,{delay:60,label:`Findings`,value:String(n?.stats.findings??`–`),sub:`posted or summarized`}),(0,k.jsx)(ii,{delay:120,label:`Failures`,value:String(n?.stats.failed??`–`),sub:`reviews that errored`}),(0,k.jsx)(ii,{delay:180,label:`Spend`,value:n?`$${n.stats.costUsd.toFixed(2)}`:`–`,sub:`API cost where reported`})]}),n&&!r&&(0,k.jsx)(P,{eyebrow:`Getting started`,title:`Three steps to the first review`,children:(0,k.jsxs)(`div`,{className:`grid gap-3 md:grid-cols-3`,children:[(0,k.jsx)(ai,{done:n.providerConfigured,title:`Choose a model`,text:`Add an API key or use your Claude / ChatGPT / Copilot plan.`,to:`/settings/models`}),(0,k.jsx)(ai,{done:n.integrations>0,title:`Connect a code host`,text:`GitHub, GitLab, Bitbucket or Azure DevOps.`,to:`/repositories`}),(0,k.jsx)(ai,{done:n.repositories>0,title:`Add a repository`,text:`Then open a pull request, or review one below.`,to:`/repositories`})]})}),(0,k.jsx)(P,{eyebrow:`Manual`,title:`Review a pull request`,children:(0,k.jsx)(Qr,{})}),r&&(0,k.jsx)(ri,{}),(0,k.jsx)(P,{eyebrow:`Live`,title:`Recent reviews`,actions:(0,k.jsx)(Vn,{to:`/reviews`,className:`text-[13px] text-ink-3 hover:text-iris`,children:`All reviews →`}),padded:!1,children:(0,k.jsx)(ei,{reviews:t.data?.reviews,loading:t.loading,onChange:()=>void t.reload()})}),n&&!n.server.publicUrl&&r&&(0,k.jsxs)(`div`,{className:`flex items-center gap-4 rounded-2xl border border-dashed border-line-strong px-5 py-4 text-[13.5px] text-ink-2`,children:[(0,k.jsx)(rr,{size:26}),(0,k.jsxs)(`span`,{children:[`Automatic reviews need webhooks. Set a public URL in`,` `,(0,k.jsx)(Vn,{to:`/settings/server`,className:`text-iris underline underline-offset-4`,children:`Server & CI`}),`, or run Argus from CI instead.`]})]})]})]})}function si({path:e}){let t=Yr();return t.scope!==`repository`||!t.isOverridden(e)?null:(0,k.jsx)(`button`,{type:`button`,onClick:()=>t.resetPath(e),className:`ml-2 rounded-md border border-iris/40 bg-iris-soft px-1.5 py-px font-mono text-[10px] tracking-wider text-iris uppercase hover:brightness-110`,title:`This repository overrides the global value. Click to inherit it again.`,children:`overridden · reset`})}function ci({path:e}){let t=Yr();return t.isLocked(e)?(0,k.jsx)(`span`,{className:`ml-2 rounded-md border border-line-strong px-1.5 py-px font-mono text-[10px] tracking-wider text-ink-3 uppercase`,title:t.lockNote,children:`admin only`}):null}function L({path:e,label:t,hint:n}){let r=Yr();return(0,k.jsx)(lr,{label:(0,k.jsxs)(k.Fragment,{children:[t,(0,k.jsx)(si,{path:e}),(0,k.jsx)(ci,{path:e})]}),hint:n,checked:!!r.get(e),onChange:t=>r.set(e,t),disabled:r.isLocked(e)})}function li({path:e,label:t,hint:n,min:r,max:i,step:a=1}){let o=Yr(),s=o.get(e);return(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[t,(0,k.jsx)(si,{path:e}),(0,k.jsx)(ci,{path:e})]}),hint:n,children:(0,k.jsx)(M,{type:`number`,min:r,max:i,step:a,disabled:o.isLocked(e),value:Number.isFinite(s)?s:``,onChange:t=>{let n=t.target.value===``?NaN:Number(t.target.value);Number.isFinite(n)&&o.set(e,n)},className:`max-w-48`})})}function ui({path:e,label:t,hint:n,options:r}){let i=Yr();return(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[t,(0,k.jsx)(si,{path:e}),(0,k.jsx)(ci,{path:e})]}),hint:n,children:(0,k.jsx)(sr,{disabled:i.isLocked(e),value:i.get(e)??``,onChange:t=>i.set(e,t.target.value),className:`max-w-sm`,children:r.map(e=>(0,k.jsx)(`option`,{value:e.value,children:e.label},e.value))})})}function di({path:e,label:t,hint:n,placeholder:r,mono:i}){let a=Yr();return(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[t,(0,k.jsx)(si,{path:e}),(0,k.jsx)(ci,{path:e})]}),hint:n,children:(0,k.jsx)(`div`,{className:A(a.isLocked(e)&&`pointer-events-none opacity-60`),"aria-disabled":a.isLocked(e)||void 0,children:(0,k.jsx)(hr,{value:a.get(e)??[],onChange:t=>a.set(e,t),placeholder:r,...i===void 0?{}:{mono:i}})})})}function fi({path:e,label:t,hint:n,placeholder:r,mono:i}){let a=Yr();return(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[t,(0,k.jsx)(si,{path:e}),(0,k.jsx)(ci,{path:e})]}),hint:n,children:(0,k.jsx)(M,{disabled:a.isLocked(e),value:a.get(e)??``,placeholder:r,onChange:t=>a.set(e,t.target.value),className:A(`max-w-md`,i&&`font-mono`)})})}function pi({children:e}){return(0,k.jsx)(`div`,{className:`divide-y divide-line`,children:e})}var mi=`Examples:
12
+ - Prefer early returns over nested conditionals.
13
+ - All public API handlers validate input with zod before using it.
14
+ - Never call the payments provider directly; go through PaymentsService.
15
+ - Database access only happens in repositories under src/db/.`;function hi(){let e=Yr(),t=e.get(`pathInstructions`)??[],n=t=>e.set(`pathInstructions`,t);return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(P,{eyebrow:`Free form`,title:(0,k.jsxs)(k.Fragment,{children:[`Team guidelines`,(0,k.jsx)(si,{path:`guidelines`})]}),children:[(0,k.jsx)(`p`,{className:`mb-3 text-[13.5px] text-ink-2`,children:`Written the way you would brief a new senior engineer. Argus treats violations in changed code as findings. Repository files like AGENTS.md and CLAUDE.md are read automatically on top of this.`}),(0,k.jsx)(or,{rows:12,value:e.get(`guidelines`)??``,onChange:t=>e.set(`guidelines`,t.target.value),placeholder:mi})]}),(0,k.jsx)(P,{eyebrow:`Scoped`,title:(0,k.jsxs)(k.Fragment,{children:[`Path instructions`,(0,k.jsx)(si,{path:`pathInstructions`})]}),actions:(0,k.jsx)(j,{size:`sm`,variant:`primary`,onClick:()=>n([...t,{path:``,instructions:``}]),children:`Add instruction`}),padded:t.length>0,children:t.length===0?(0,k.jsx)(vr,{title:`No path instructions`,children:`Give Argus extra context for parts of the codebase, e.g. "src/api/** — every handler must check tenant ownership".`}):(0,k.jsxs)(`div`,{className:`space-y-3`,children:[t.map((e,r)=>(0,k.jsxs)(`div`,{className:`grid gap-3 rounded-xl border border-line p-3 md:grid-cols-[240px_1fr_auto]`,children:[(0,k.jsx)(M,{className:`font-mono`,placeholder:`src/api/**`,value:e.path,onChange:e=>n(t.map((t,n)=>n===r?{...t,path:e.target.value}:t))}),(0,k.jsx)(or,{rows:2,className:`min-h-9`,placeholder:`What reviewers must check in these files`,value:e.instructions,onChange:e=>n(t.map((t,n)=>n===r?{...t,instructions:e.target.value}:t))}),(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:()=>n(t.filter((e,t)=>t!==r)),children:`Remove`})]},r)),t.some(e=>!e.path.trim()||!e.instructions.trim())&&(0,k.jsx)(`p`,{className:`text-[12.5px] text-minor`,children:`Empty rows are not saved; fill in both the path and the instructions.`})]})})]})}function gi(){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Review brain`,title:`Guidelines`,description:`Tell Argus how your team writes code, globally and for specific paths.`}),(0,k.jsx)(hi,{})]})}var _i=` (pending approval)`,vi=e=>!e.enabled&&!!e.source?.endsWith(_i),yi=e=>e.source?.endsWith(_i)?e.source.slice(0,-19):e.source;function bi({repositoryId:e,ci:t}){let n=Nr(e?`/learnings?repository=${e}`:`/learnings`),r=Nr(e?null:`/repositories`),[i,a]=(0,v.useState)(null),[o,s]=(0,v.useState)(!1),[c,l]=(0,v.useState)(!1),u=Cr(),d=zr(`maintainer`),f=!t,p=async(e,t)=>{try{await I(`/learnings/${e.id}`,{method:`PUT`,json:{enabled:t}}),n.reload()}catch(e){u(`bad`,e.message)}},m=async()=>{if(e){l(!0);try{let t=await I(`/repositories/${e}/learn`,{method:`POST`,json:{}});u(`ok`,t.created.length?`${t.created.length} suggestion(s) from ${t.usable} review comments; enable the ones you agree with`:`No recurring conventions in ${t.usable} usable review comments`),n.reload()}catch(e){u(`bad`,e.message)}finally{l(!1)}}},h=e=>{if(e===null)return`All repositories`;let t=r.data?.repositories.find(t=>t.id===e);return t?`${t.owner}/${t.name}`:`Repository #${e}`},g=async()=>{if(i?.text?.trim()){s(!0);try{let t={text:i.text,paths:i.paths??[],repositoryId:e??i.repositoryId??null};i.id?await I(`/learnings/${i.id}`,{method:`PUT`,json:t}):await I(`/learnings`,{method:`POST`,json:t}),a(null),n.reload()}catch(e){u(`bad`,e.message)}finally{s(!1)}}},_=n.data?.learnings??[];return(0,k.jsxs)(P,{eyebrow:`${_.filter(e=>e.enabled).length} active`,title:`Learnings`,actions:(0,k.jsxs)(`div`,{className:`flex gap-2`,children:[e!==void 0&&d&&f&&(0,k.jsx)(j,{size:`sm`,loading:c,onClick:()=>void m(),title:`Reads the repository's recent human review comments and suggests the conventions reviewers keep asking for`,children:`Learn from past reviews`}),d&&(0,k.jsx)(j,{size:`sm`,variant:`primary`,onClick:()=>a({text:``,paths:[],repositoryId:e??null}),children:`Add learning`})]}),padded:!1,children:[n.loading&&!n.data?(0,k.jsx)(`div`,{className:`flex justify-center p-10 text-ink-3`,children:(0,k.jsx)(ir,{})}):_.length===0?(0,k.jsxs)(vr,{title:`Nothing learned yet`,children:[`Reply to an Argus comment with a correction, or comment `,(0,k.jsx)(`code`,{className:`font-mono`,children:`@argus remember …`}),`, and the lesson shows up here. You can also add learnings by hand.`]}):(0,k.jsx)(`ul`,{className:`divide-y divide-line`,children:_.map(t=>(0,k.jsxs)(`li`,{className:A(`flex items-start gap-4 px-5 py-4`,!t.enabled&&`opacity-55`),children:[(0,k.jsx)(cr,{checked:t.enabled,label:`Enable learning`,disabled:!d,onChange:e=>void p(t,e)}),(0,k.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,k.jsx)(`p`,{className:`text-[14px] text-ink`,children:t.text}),(0,k.jsxs)(`div`,{className:`mt-1.5 flex flex-wrap items-center gap-1.5 text-[12px] text-ink-3`,children:[!e&&(0,k.jsx)(F,{tone:t.repositoryId===null?`iris`:`neutral`,children:h(t.repositoryId)}),t.paths.map(e=>(0,k.jsx)(F,{className:`font-mono`,children:e},e)),!t.enabled&&t.source?.startsWith(`Suggested from`)&&(0,k.jsx)(F,{tone:`warn`,children:`suggested · enable to apply`}),vi(t)&&(0,k.jsx)(F,{tone:`warn`,children:`Pending approval`}),(0,k.jsx)(`span`,{children:yi(t)??`manual`}),(0,k.jsxs)(`span`,{children:[`· `,wr(t.createdAt)]})]})]}),d&&(0,k.jsxs)(`div`,{className:`flex shrink-0 gap-1`,children:[vi(t)&&(0,k.jsx)(j,{size:`sm`,variant:`primary`,onClick:()=>void p(t,!0),title:`Proposed in a pull request comment; enable it so future reviews apply it`,children:`Approve`}),(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:()=>a(t),children:`Edit`}),(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:async()=>{await I(`/learnings/${t.id}`,{method:`DELETE`}),n.reload()},children:`Delete`})]})]},t.id))}),i&&(0,k.jsx)(_r,{open:!0,onClose:()=>a(null),title:i.id?`Edit learning`:`New learning`,footer:(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(j,{variant:`ghost`,onClick:()=>a(null),children:`Cancel`}),(0,k.jsx)(j,{variant:`primary`,loading:o,disabled:(i.text?.trim().length??0)<3,onClick:()=>void g(),children:`Save`})]}),children:(0,k.jsxs)(`div`,{className:`space-y-4`,children:[(0,k.jsx)(N,{label:`Lesson`,hint:`One self-contained sentence a reviewer can apply.`,children:(0,k.jsx)(or,{rows:3,value:i.text??``,onChange:e=>a({...i,text:e.target.value}),placeholder:`Amounts in this repository are integer cents; don't flag integer math on prices.`})}),(0,k.jsx)(N,{label:`Applies to`,hint:`Glob patterns. Empty means everywhere.`,children:(0,k.jsx)(hr,{value:i.paths??[],onChange:e=>a({...i,paths:e})})}),!e&&(0,k.jsx)(N,{label:`Scope`,children:(0,k.jsxs)(sr,{value:i.repositoryId===null||i.repositoryId===void 0?``:String(i.repositoryId),onChange:e=>a({...i,repositoryId:e.target.value?Number(e.target.value):null}),children:[(0,k.jsx)(`option`,{value:``,children:`All repositories`}),r.data?.repositories.map(e=>(0,k.jsxs)(`option`,{value:e.id,children:[e.owner,`/`,e.name]},e.id))]})})]})})]})}function xi(){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Review brain`,title:`Learnings`,description:`Lessons Argus picked up from your team's feedback in pull requests. They are applied to every future review in their scope.`}),(0,k.jsx)(bi,{})]})}var Si=Symbol.for(`yaml.alias`),Ci=Symbol.for(`yaml.document`),wi=Symbol.for(`yaml.map`),Ti=Symbol.for(`yaml.pair`),Ei=Symbol.for(`yaml.scalar`),Di=Symbol.for(`yaml.seq`),Oi=Symbol.for(`yaml.node.type`),ki=e=>!!e&&typeof e==`object`&&e[Oi]===Si,Ai=e=>!!e&&typeof e==`object`&&e[Oi]===Ci,ji=e=>!!e&&typeof e==`object`&&e[Oi]===wi,Mi=e=>!!e&&typeof e==`object`&&e[Oi]===Ti,Ni=e=>!!e&&typeof e==`object`&&e[Oi]===Ei,Pi=e=>!!e&&typeof e==`object`&&e[Oi]===Di;function Fi(e){if(e&&typeof e==`object`)switch(e[Oi]){case wi:case Di:return!0}return!1}function R(e){if(e&&typeof e==`object`)switch(e[Oi]){case Si:case wi:case Ei:case Di:return!0}return!1}var Ii=e=>(Ni(e)||Fi(e))&&!!e.anchor,Li=Symbol(`break visit`),Ri=Symbol(`skip children`),zi=Symbol(`remove node`);function Bi(e,t){let n=Hi(t);Ai(e)?Vi(null,e.contents,n,Object.freeze([e]))===zi&&(e.contents=null):Vi(null,e,n,Object.freeze([]))}Bi.BREAK=Li,Bi.SKIP=Ri,Bi.REMOVE=zi;function Vi(e,t,n,r){let i=Ui(e,t,n,r);if(R(i)||Mi(i))return Wi(e,r,i),Vi(e,i,n,r);if(typeof i!=`symbol`){if(Fi(t)){r=Object.freeze(r.concat(t));for(let e=0;e<t.items.length;++e){let i=Vi(e,t.items[e],n,r);if(typeof i==`number`)e=i-1;else if(i===Li)return Li;else i===zi&&(t.items.splice(e,1),--e)}}else if(Mi(t)){r=Object.freeze(r.concat(t));let e=Vi(`key`,t.key,n,r);if(e===Li)return Li;e===zi&&(t.key=null);let i=Vi(`value`,t.value,n,r);if(i===Li)return Li;i===zi&&(t.value=null)}}return i}function Hi(e){return typeof e==`object`&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function Ui(e,t,n,r){if(typeof n==`function`)return n(e,t,r);if(ji(t))return n.Map?.(e,t,r);if(Pi(t))return n.Seq?.(e,t,r);if(Mi(t))return n.Pair?.(e,t,r);if(Ni(t))return n.Scalar?.(e,t,r);if(ki(t))return n.Alias?.(e,t,r)}function Wi(e,t,n){let r=t[t.length-1];if(Fi(r))r.items[e]=n;else if(Mi(r))e===`key`?r.key=n:r.value=n;else if(Ai(r))r.contents=n;else{let e=ki(r)?`alias`:`scalar`;throw Error(`Cannot replace node with ${e} parent`)}}var Gi={"!":`%21`,",":`%2C`,"[":`%5B`,"]":`%5D`,"{":`%7B`,"}":`%7D`},Ki=e=>e.replace(/[!,[\]{}]/g,e=>Gi[e]),qi=class e{constructor(t,n){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},e.defaultYaml,t),this.tags=Object.assign({},e.defaultTags,n)}clone(){let t=new e(this.yaml,this.tags);return t.docStart=this.docStart,t}atDocument(){let t=new e(this.yaml,this.tags);switch(this.yaml.version){case`1.1`:this.atNextDocument=!0;break;case`1.2`:this.atNextDocument=!1,this.yaml={explicit:e.defaultYaml.explicit,version:`1.2`},this.tags=Object.assign({},e.defaultTags)}return t}add(t,n){this.atNextDocument&&=(this.yaml={explicit:e.defaultYaml.explicit,version:`1.1`},this.tags=Object.assign({},e.defaultTags),!1);let r=t.trim().split(/[ \t]+/),i=r.shift();switch(i){case`%TAG`:{if(r.length!==2&&(n(0,`%TAG directive should contain exactly two parts`),r.length<2))return!1;let[e,t]=r;return this.tags[e]=t,!0}case`%YAML`:{if(this.yaml.explicit=!0,r.length!==1)return n(0,`%YAML directive should contain exactly one part`),!1;let[e]=r;if(e===`1.1`||e===`1.2`)return this.yaml.version=e,!0;{let t=/^\d+\.\d+$/.test(e);return n(6,`Unsupported YAML version ${e}`,t),!1}}default:return n(0,`Unknown directive ${i}`,!0),!1}}tagName(e,t){if(e===`!`)return`!`;if(e[0]!==`!`)return t(`Not a valid tag: ${e}`),null;if(e[1]===`<`){let n=e.slice(2,-1);return n===`!`||n===`!!`?(t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(e[e.length-1]!==`>`&&t(`Verbatim tags must end with a >`),n)}let[,n,r]=e.match(/^(.*!)([^!]*)$/s);r||t(`The ${e} tag has no suffix`);let i=this.tags[n];if(i)try{return i+decodeURIComponent(r)}catch(e){return t(String(e)),null}return n===`!`?e:(t(`Could not resolve tag: ${e}`),null)}tagString(e){for(let[t,n]of Object.entries(this.tags))if(e.startsWith(n))return t+Ki(e.substring(n.length));return e[0]===`!`?e:`!<${e}>`}toString(e){let t=this.yaml.explicit?[`%YAML ${this.yaml.version||`1.2`}`]:[],n=Object.entries(this.tags),r;if(e&&n.length>0&&R(e.contents)){let t={};Bi(e.contents,(e,n)=>{R(n)&&n.tag&&(t[n.tag]=!0)}),r=Object.keys(t)}else r=[];for(let[i,a]of n)(i!==`!!`||a!==`tag:yaml.org,2002:`)&&(!e||r.some(e=>e.startsWith(a)))&&t.push(`%TAG ${i} ${a}`);return t.join(`
16
+ `)}};qi.defaultYaml={explicit:!1,version:`1.2`},qi.defaultTags={"!!":`tag:yaml.org,2002:`};function Ji(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){let t=`Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`;throw Error(t)}return!0}function Yi(e){let t=new Set;return Bi(e,{Value(e,n){n.anchor&&t.add(n.anchor)}}),t}function Xi(e,t){for(let n=1;;++n){let r=`${e}${n}`;if(!t.has(r))return r}}function Zi(e,t){let n=[],r=new Map,i=null;return{onAnchor:r=>{n.push(r),i??=Yi(e);let a=Xi(t,i);return i.add(a),a},setAnchors:()=>{for(let e of n){let t=r.get(e);if(typeof t==`object`&&t.anchor&&(Ni(t.node)||Fi(t.node)))t.node.anchor=t.anchor;else{let t=Error(`Failed to resolve repeated object (this should not happen)`);throw t.source=e,t}}},sourceObjects:r}}function Qi(e,t,n,r){if(r&&typeof r==`object`){if(Array.isArray(r))for(let t=0,n=r.length;t<n;++t){let n=r[t],i=Qi(e,r,String(t),n);i===void 0?delete r[t]:i!==n&&(r[t]=i)}else if(r instanceof Map)for(let t of Array.from(r.keys())){let n=r.get(t),i=Qi(e,r,t,n);i===void 0?r.delete(t):i!==n&&r.set(t,i)}else if(r instanceof Set)for(let t of Array.from(r)){let n=Qi(e,r,t,t);n===void 0?r.delete(t):n!==t&&(r.delete(t),r.add(n))}else for(let[t,n]of Object.entries(r)){let i=Qi(e,r,t,n);i===void 0?delete r[t]:i!==n&&(r[t]=i)}}return e.call(t,n,r)}function $i(e,t,n){if(Array.isArray(e))return e.map((e,t)=>$i(e,String(t),n));if(e&&typeof e.toJSON==`function`){if(!n||!Ii(e))return e.toJSON(t,n);let r={aliasCount:0,count:1,res:void 0};n.anchors.set(e,r),n.onCreate=e=>{r.res=e,delete n.onCreate};let i=e.toJSON(t,n);return n.onCreate&&n.onCreate(i),i}return typeof e==`bigint`&&!n?.keep?Number(e):e}var ea=class{constructor(e){Object.defineProperty(this,Oi,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:t,maxAliasCount:n,onAnchor:r,reviver:i}={}){if(!Ai(e))throw TypeError(`A document argument is required`);let a={anchors:new Map,doc:e,keep:!0,mapAsMap:t===!0,mapKeyWarned:!1,maxAliasCount:typeof n==`number`?n:100},o=$i(this,``,a);if(typeof r==`function`)for(let{count:e,res:t}of a.anchors.values())r(t,e);return typeof i==`function`?Qi(i,{"":o},``,o):o}},ta=class extends ea{constructor(e){super(Si),this.source=e,Object.defineProperty(this,"tag",{set(){throw Error(`Alias nodes cannot have tags`)}})}resolve(e,t){if(t?.maxAliasCount===0)throw ReferenceError(`Alias resolution is disabled`);let n;t?.aliasResolveCache?n=t.aliasResolveCache:(n=[],Bi(e,{Node:(e,t)=>{(ki(t)||Ii(t))&&n.push(t)}}),t&&(t.aliasResolveCache=n));let r;for(let e of n){if(e===this)break;e.anchor===this.source&&(r=e)}if(r&&t){let{anchors:e,doc:n,maxAliasCount:i}=t,a=e.get(r);if(a||=($i(r,null,t),e.get(r)),a?.res===void 0)throw ReferenceError(`This should not happen: Alias anchor was not resolved?`);if(i>=0&&(a.count+=1,a.aliasCount===0&&(a.aliasCount=na(n,r,e)),a.count*a.aliasCount>i))throw ReferenceError(`Excessive alias count indicates a resource exhaustion attack`)}return r}toJSON(e,t){if(!t)return{source:this.source};let n=this.resolve(t.doc,t);if(!n){let e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(e)}return t.anchors.get(n).res}toString(e,t,n){let r=`*${this.source}`;if(e){if(Ji(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){let e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(e)}if(e.implicitKey)return`${r} `}return r}};function na(e,t,n){if(ki(t)){let r=t.resolve(e),i=n&&r&&n.get(r);return i?i.count*i.aliasCount:0}if(Fi(t)){let r=0;for(let i of t.items){let t=na(e,i,n);t>r&&(r=t)}return r}if(Mi(t)){let r=na(e,t.key,n),i=na(e,t.value,n);return Math.max(r,i)}return 1}var ra=e=>!e||typeof e!=`function`&&typeof e!=`object`,z=class extends ea{constructor(e){super(Ei),this.value=e}toJSON(e,t){return t?.keep?this.value:$i(this.value,e,t)}toString(){return String(this.value)}};z.BLOCK_FOLDED=`BLOCK_FOLDED`,z.BLOCK_LITERAL=`BLOCK_LITERAL`,z.PLAIN=`PLAIN`,z.QUOTE_DOUBLE=`QUOTE_DOUBLE`,z.QUOTE_SINGLE=`QUOTE_SINGLE`;var B=`tag:yaml.org,2002:`;function V(e,t,n){if(t){let e=n.filter(e=>e.tag===t),r=e.find(e=>!e.format)??e[0];if(!r)throw Error(`Tag ${t} not found`);return r}return n.find(t=>t.identify?.(e)&&!t.format)}function ia(e,t,n){if(Ai(e)&&(e=e.contents),R(e))return e;if(Mi(e)){let t=n.schema[wi].createNode?.(n.schema,null,n);return t.items.push(e),t}(e instanceof String||e instanceof Number||e instanceof Boolean||typeof BigInt<`u`&&e instanceof BigInt)&&(e=e.valueOf());let{aliasDuplicateObjects:r,onAnchor:i,onTagObj:a,schema:o,sourceObjects:s}=n,c;if(r&&e&&typeof e==`object`){if(c=s.get(e),c)return c.anchor??(c.anchor=i(e)),new ta(c.anchor);c={anchor:null,node:null},s.set(e,c)}t?.startsWith(`!!`)&&(t=B+t.slice(2));let l=V(e,t,o.tags);if(!l){if(e&&typeof e.toJSON==`function`&&(e=e.toJSON()),!e||typeof e!=`object`){let t=new z(e);return c&&(c.node=t),t}l=e instanceof Map?o[wi]:Symbol.iterator in Object(e)?o[Di]:o[wi]}a&&(a(l),delete n.onTagObj);let u=l?.createNode?l.createNode(n.schema,e,n):typeof l?.nodeClass?.from==`function`?l.nodeClass.from(n.schema,e,n):new z(e);return t?u.tag=t:l.default||(u.tag=l.tag),c&&(c.node=u),u}function aa(e,t,n){let r=n;for(let e=t.length-1;e>=0;--e){let n=t[e];if(typeof n==`number`&&Number.isInteger(n)&&n>=0){let e=[];e[n]=r,r=e}else r=new Map([[n,r]])}return ia(r,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error(`This should not happen, please report a bug.`)},schema:e,sourceObjects:new Map})}var oa=e=>e==null||typeof e==`object`&&!!e[Symbol.iterator]().next().done,sa=class extends ea{constructor(e,t){super(e),Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){let t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(t.schema=e),t.items=t.items.map(t=>R(t)||Mi(t)?t.clone(e):t),this.range&&(t.range=this.range.slice()),t}addIn(e,t){if(oa(e))this.add(t);else{let[n,...r]=e,i=this.get(n,!0);if(Fi(i))i.addIn(r,t);else if(i===void 0&&this.schema)this.set(n,aa(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}deleteIn(e){let[t,...n]=e;if(n.length===0)return this.delete(t);let r=this.get(t,!0);if(Fi(r))return r.deleteIn(n);throw Error(`Expected YAML collection at ${t}. Remaining path: ${n}`)}getIn(e,t){let[n,...r]=e,i=this.get(n,!0);return r.length===0?!t&&Ni(i)?i.value:i:Fi(i)?i.getIn(r,t):void 0}hasAllNullValues(e){return this.items.every(t=>{if(!Mi(t))return!1;let n=t.value;return n==null||e&&Ni(n)&&n.value==null&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(e){let[t,...n]=e;if(n.length===0)return this.has(t);let r=this.get(t,!0);return Fi(r)?r.hasIn(n):!1}setIn(e,t){let[n,...r]=e;if(r.length===0)this.set(n,t);else{let e=this.get(n,!0);if(Fi(e))e.setIn(r,t);else if(e===void 0&&this.schema)this.set(n,aa(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}},ca=e=>e.replace(/^(?!$)(?: $)?/gm,`#`);function la(e,t){return/^\n+$/.test(e)?e.substring(1):t?e.replace(/^(?! *$)/gm,t):e}var ua=(e,t,n)=>e.endsWith(`
17
+ `)?la(n,t):n.includes(`
18
+ `)?`
19
+ `+la(n,t):(e.endsWith(` `)?``:` `)+n,da=`flow`,fa=`block`,pa=`quoted`;function ma(e,t,n=`flow`,{indentAtStart:r,lineWidth:i=80,minContentWidth:a=20,onFold:o,onOverflow:s}={}){if(!i||i<0)return e;i<a&&(a=0);let c=Math.max(1+a,1+i-t.length);if(e.length<=c)return e;let l=[],u={},d=i-t.length;typeof r==`number`&&(r>i-Math.max(2,a)?l.push(0):d=i-r);let f,p,m=!1,h=-1,g=-1,_=-1;n===`block`&&(h=ha(e,h,t.length),h!==-1&&(d=h+c));for(let r;r=e[h+=1];){if(n===`quoted`&&r===`\\`){switch(g=h,e[h+1]){case`x`:h+=3;break;case`u`:h+=5;break;case`U`:h+=9;break;default:h+=1}_=h}if(r===`
20
+ `)n===`block`&&(h=ha(e,h,t.length)),d=h+t.length+c,f=void 0;else{if(r===` `&&p&&p!==` `&&p!==`
21
+ `&&p!==` `){let t=e[h+1];t&&t!==` `&&t!==`
22
+ `&&t!==` `&&(f=h)}if(h>=d){if(f)l.push(f),d=f+c,f=void 0;else if(n===`quoted`){for(;p===` `||p===` `;)p=r,r=e[h+=1],m=!0;let t=h>_+1?h-2:g-1;if(u[t])return e;l.push(t),u[t]=!0,d=t+c,f=void 0}else m=!0}}p=r}if(m&&s&&s(),l.length===0)return e;o&&o();let v=e.slice(0,l[0]);for(let r=0;r<l.length;++r){let i=l[r],a=l[r+1]||e.length;i===0?v=`\n${t}${e.slice(0,a)}`:(n===`quoted`&&u[i]&&(v+=`${e[i]}\\`),v+=`\n${t}${e.slice(i+1,a)}`)}return v}function ha(e,t,n){let r=t,i=t+1,a=e[i];for(;a===` `||a===` `;)if(t<i+n)a=e[++t];else{do a=e[++t];while(a&&a!==`
23
+ `);r=t,i=t+1,a=e[i]}return r}var ga=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),_a=e=>/^(%|---|\.\.\.)/m.test(e);function va(e,t,n){if(!t||t<0)return!1;let r=t-n,i=e.length;if(i<=r)return!1;for(let t=0,n=0;t<i;++t)if(e[t]===`
24
+ `){if(t-n>r)return!0;if(n=t+1,i-n<=r)return!1}return!0}function ya(e,t){let n=JSON.stringify(e);if(t.options.doubleQuotedAsJSON)return n;let{implicitKey:r}=t,i=t.options.doubleQuotedMinMultiLineLength,a=t.indent||(_a(e)?` `:``),o=``,s=0;for(let e=0,t=n[e];t;t=n[++e])if(t===` `&&n[e+1]===`\\`&&n[e+2]===`n`&&(o+=n.slice(s,e)+`\\ `,e+=1,s=e,t=`\\`),t===`\\`)switch(n[e+1]){case`u`:{o+=n.slice(s,e);let t=n.substr(e+2,4);switch(t){case`0000`:o+=`\\0`;break;case`0007`:o+=`\\a`;break;case`000b`:o+=`\\v`;break;case`001b`:o+=`\\e`;break;case`0085`:o+=`\\N`;break;case`00a0`:o+=`\\_`;break;case`2028`:o+=`\\L`;break;case`2029`:o+=`\\P`;break;default:t.substr(0,2)===`00`?o+=`\\x`+t.substr(2):o+=n.substr(e,6)}e+=5,s=e+1}break;case`n`:if(r||n[e+2]===`"`||n.length<i)e+=1;else{for(o+=n.slice(s,e)+`
25
+
26
+ `;n[e+2]===`\\`&&n[e+3]===`n`&&n[e+4]!==`"`;)o+=`
27
+ `,e+=2;o+=a,n[e+2]===` `&&(o+=`\\`),e+=1,s=e+1}break;default:e+=1}return o=s?o+n.slice(s):n,r?o:ma(o,a,pa,ga(t,!1))}function ba(e,t){if(t.options.singleQuote===!1||t.implicitKey&&e.includes(`
28
+ `)||/[ \t]\n|\n[ \t]/.test(e))return ya(e,t);let n=t.indent||(_a(e)?` `:``),r=`'`+e.replace(/'/g,`''`).replace(/\n+/g,`$&\n${n}`)+`'`;return t.implicitKey?r:ma(r,n,da,ga(t,!1))}function xa(e,t){let{singleQuote:n}=t.options,r;if(n===!1)r=ya;else{let t=e.includes(`"`),i=e.includes(`'`);r=t&&!i?ba:i&&!t?ya:n?ba:ya}return r(e,t)}var Sa;try{Sa=RegExp(`(^|(?<!
29
+ ))
30
+ +(?!
31
+ |$)`,`g`)}catch{Sa=/\n+(?!\n|$)/g}function Ca({comment:e,type:t,value:n},r,i,a){let{blockQuote:o,commentString:s,lineWidth:c}=r.options;if(!o||/\n[\t ]+$/.test(n))return xa(n,r);let l=r.indent||(r.forceBlockIndent||_a(n)?` `:``),u=o===`literal`?!0:o===`folded`||t===z.BLOCK_FOLDED?!1:t===z.BLOCK_LITERAL||!va(n,c,l.length);if(!n)return u?`|
32
+ `:`>
33
+ `;let d,f;for(f=n.length;f>0;--f){let e=n[f-1];if(e!==`
34
+ `&&e!==` `&&e!==` `)break}let p=n.substring(f),m=p.indexOf(`
35
+ `);m===-1?d=`-`:n===p||m!==p.length-1?(d=`+`,a&&a()):d=``,p&&=(n=n.slice(0,-p.length),p[p.length-1]===`
36
+ `&&(p=p.slice(0,-1)),p.replace(Sa,`$&${l}`));let h=!1,g,_=-1;for(g=0;g<n.length;++g){let e=n[g];if(e===` `)h=!0;else if(e===`
37
+ `)_=g;else break}let v=n.substring(0,_<g?_+1:g);v&&=(n=n.substring(v.length),v.replace(/\n+/g,`$&${l}`));let y=(h?l?`2`:`1`:``)+d;if(e&&(y+=` `+s(e.replace(/ ?[\r\n]+/g,` `)),i&&i()),!u){let e=n.replace(/\n+/g,`
38
+ $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,`$1$2`).replace(/\n+/g,`$&${l}`),i=!1,a=ga(r,!0);o!==`folded`&&t!==z.BLOCK_FOLDED&&(a.onOverflow=()=>{i=!0});let s=ma(`${v}${e}${p}`,l,fa,a);if(!i)return`>${y}\n${l}${s}`}return n=n.replace(/\n+/g,`$&${l}`),`|${y}\n${l}${v}${n}${p}`}function wa(e,t,n,r){let{type:i,value:a}=e,{actualString:o,implicitKey:s,indent:c,indentStep:l,inFlow:u}=t;if(s&&a.includes(`
39
+ `)||u&&/[[\]{},]/.test(a))return xa(a,t);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(a))return s||u||!a.includes(`
40
+ `)?xa(a,t):Ca(e,t,n,r);if(!s&&!u&&i!==z.PLAIN&&a.includes(`
41
+ `))return Ca(e,t,n,r);if(_a(a)){if(c===``)return t.forceBlockIndent=!0,Ca(e,t,n,r);if(s&&c===l)return xa(a,t)}let d=a.replace(/\n+/g,`$&\n${c}`);if(o){let e=e=>e.default&&e.tag!==`tag:yaml.org,2002:str`&&e.test?.test(d),{compat:n,tags:r}=t.doc.schema;if(r.some(e)||n?.some(e))return xa(a,t)}return s?d:ma(d,c,da,ga(t,!1))}function Ta(e,t,n,r){let{implicitKey:i,inFlow:a}=t,o=typeof e.value==`string`?e:Object.assign({},e,{value:String(e.value)}),{type:s}=e;s!==z.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(s=z.QUOTE_DOUBLE);let c=e=>{switch(e){case z.BLOCK_FOLDED:case z.BLOCK_LITERAL:return i||a?xa(o.value,t):Ca(o,t,n,r);case z.QUOTE_DOUBLE:return ya(o.value,t);case z.QUOTE_SINGLE:return ba(o.value,t);case z.PLAIN:return wa(o,t,n,r);default:return null}},l=c(s);if(l===null){let{defaultKeyType:e,defaultStringType:n}=t.options,r=i&&e||n;if(l=c(r),l===null)throw Error(`Unsupported default string type ${r}`)}return l}function Ea(e,t){let n=Object.assign({blockQuote:!0,commentString:ca,defaultKeyType:null,defaultStringType:`PLAIN`,directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:`false`,flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:`null`,simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:`true`,verifyAliasOrder:!0},e.schema.toStringOptions,t),r;switch(n.collectionStyle){case`block`:r=!1;break;case`flow`:r=!0;break;default:r=null}return{anchors:new Set,doc:e,flowCollectionPadding:n.flowCollectionPadding?` `:``,indent:``,indentStep:typeof n.indent==`number`?` `.repeat(n.indent):` `,inFlow:r,options:n}}function Da(e,t){if(t.tag){let n=e.filter(e=>e.tag===t.tag);if(n.length>0)return n.find(e=>e.format===t.format)??n[0]}let n,r;if(Ni(t)){r=t.value;let i=e.filter(e=>e.identify?.(r));if(i.length>1){let e=i.filter(e=>e.test);e.length>0&&(i=e)}n=i.find(e=>e.format===t.format)??i.find(e=>!e.format)}else r=t,n=e.find(e=>e.nodeClass&&r instanceof e.nodeClass);if(!n){let e=r?.constructor?.name??(r===null?`null`:typeof r);throw Error(`Tag not resolved for ${e} value`)}return n}function Oa(e,t,{anchors:n,doc:r}){if(!r.directives)return``;let i=[],a=(Ni(e)||Fi(e))&&e.anchor;a&&Ji(a)&&(n.add(a),i.push(`&${a}`));let o=e.tag??(t.default?null:t.tag);return o&&i.push(r.directives.tagString(o)),i.join(` `)}function ka(e,t,n,r){if(Mi(e))return e.toString(t,n,r);if(ki(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw TypeError(`Cannot stringify circular structure without alias nodes`);t.resolvedAliases?t.resolvedAliases.add(e):t.resolvedAliases=new Set([e]),e=e.resolve(t.doc)}let i,a=R(e)?e:t.doc.createNode(e,{onTagObj:e=>i=e});i??=Da(t.doc.schema.tags,a);let o=Oa(a,i,t);o.length>0&&(t.indentAtStart=(t.indentAtStart??0)+o.length+1);let s=typeof i.stringify==`function`?i.stringify(a,t,n,r):Ni(a)?Ta(a,t,n,r):a.toString(t,n,r);return o?Ni(a)||s[0]===`{`||s[0]===`[`?`${o} ${s}`:`${o}\n${t.indent}${s}`:s}function Aa({key:e,value:t},n,r,i){let{allNullValues:a,doc:o,indent:s,indentStep:c,options:{commentString:l,indentSeq:u,simpleKeys:d}}=n,f=R(e)&&e.comment||null;if(d){if(f)throw Error(`With simple keys, key nodes cannot have comments`);if(Fi(e)||!R(e)&&typeof e==`object`)throw Error(`With simple keys, collection cannot be used as a key value`)}let p=!d&&(!e||f&&t==null&&!n.inFlow||Fi(e)||(Ni(e)?e.type===z.BLOCK_FOLDED||e.type===z.BLOCK_LITERAL:typeof e==`object`));n=Object.assign({},n,{allNullValues:!1,implicitKey:!p&&(d||!a),indent:s+c});let m=!1,h=!1,g=ka(e,n,()=>m=!0,()=>h=!0);if(!p&&!n.inFlow&&g.length>1024){if(d)throw Error(`With simple keys, single line scalar must not span more than 1024 characters`);p=!0}if(n.inFlow){if(a||t==null)return m&&r&&r(),g===``?`?`:p?`? ${g}`:g}else if(a&&!d||t==null&&p)return g=`? ${g}`,f&&!m?g+=ua(g,n.indent,l(f)):h&&i&&i(),g;m&&(f=null),p?(f&&(g+=ua(g,n.indent,l(f))),g=`? ${g}\n${s}:`):(g=`${g}:`,f&&(g+=ua(g,n.indent,l(f))));let _,v,y;R(t)?(_=!!t.spaceBefore,v=t.commentBefore,y=t.comment):(_=!1,v=null,y=null,t&&typeof t==`object`&&(t=o.createNode(t))),n.implicitKey=!1,!p&&!f&&Ni(t)&&(n.indentAtStart=g.length+1),h=!1,!u&&c.length>=2&&!n.inFlow&&!p&&Pi(t)&&!t.flow&&!t.tag&&!t.anchor&&(n.indent=n.indent.substring(2));let b=!1,x=ka(t,n,()=>b=!0,()=>h=!0),ee=` `;if(f||_||v){if(ee=_?`
42
+ `:``,v){let e=l(v);ee+=`\n${la(e,n.indent)}`}x===``&&!n.inFlow?ee===`
43
+ `&&y&&(ee=`
44
+
45
+ `):ee+=`\n${n.indent}`}else if(!p&&Fi(t)){let e=x[0],r=x.indexOf(`
46
+ `),i=r!==-1,a=n.inFlow??t.flow??t.items.length===0;if(i||!a){let t=!1;if(i&&(e===`&`||e===`!`)){let n=x.indexOf(` `);e===`&`&&n!==-1&&n<r&&x[n+1]===`!`&&(n=x.indexOf(` `,n+1)),(n===-1||r<n)&&(t=!0)}t||(ee=`\n${n.indent}`)}}else(x===``||x[0]===`
47
+ `)&&(ee=``);return g+=ee+x,n.inFlow?b&&r&&r():y&&!b?g+=ua(g,n.indent,l(y)):h&&i&&i(),g}function ja(e,t){(e===`debug`||e===`warn`)&&console.warn(t)}var Ma=`<<`,Na={identify:e=>e===Ma||typeof e==`symbol`&&e.description===Ma,default:`key`,tag:`tag:yaml.org,2002:merge`,test:/^<<$/,resolve:()=>Object.assign(new z(Symbol(Ma)),{addToJSMap:Fa}),stringify:()=>Ma},Pa=(e,t)=>(Na.identify(t)||Ni(t)&&(!t.type||t.type===z.PLAIN)&&Na.identify(t.value))&&e?.doc.schema.tags.some(e=>e.tag===Na.tag&&e.default);function Fa(e,t,n){let r=La(e,n);if(Pi(r))for(let n of r.items)Ia(e,t,n);else if(Array.isArray(r))for(let n of r)Ia(e,t,n);else Ia(e,t,r)}function Ia(e,t,n){let r=La(e,n);if(!ji(r))throw Error(`Merge sources must be maps or map aliases`);let i=r.toJSON(null,e,Map);for(let[e,n]of i)t instanceof Map?t.has(e)||t.set(e,n):t instanceof Set?t.add(e):Object.prototype.hasOwnProperty.call(t,e)||Object.defineProperty(t,e,{value:n,writable:!0,enumerable:!0,configurable:!0});return t}function La(e,t){return e&&ki(t)?t.resolve(e.doc,e):t}function Ra(e,t,{key:n,value:r}){if(R(n)&&n.addToJSMap)n.addToJSMap(e,t,r);else if(Pa(e,n))Fa(e,t,r);else{let i=$i(n,``,e);if(t instanceof Map)t.set(i,$i(r,i,e));else if(t instanceof Set)t.add(i);else{let a=za(n,i,e),o=$i(r,a,e);a in t?Object.defineProperty(t,a,{value:o,writable:!0,enumerable:!0,configurable:!0}):t[a]=o}}return t}function za(e,t,n){if(t===null)return``;if(typeof t!=`object`)return String(t);if(R(e)&&n?.doc){let t=Ea(n.doc,{});t.anchors=new Set;for(let e of n.anchors.keys())t.anchors.add(e.anchor);t.inFlow=!0,t.inStringifyKey=!0;let r=e.toString(t);if(!n.mapKeyWarned){let e=JSON.stringify(r);e.length>40&&(e=e.substring(0,36)+`..."`),ja(n.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${e}. Set mapAsMap: true to use object keys.`),n.mapKeyWarned=!0}return r}return JSON.stringify(t)}function Ba(e,t,n){return new Va(ia(e,void 0,n),ia(t,void 0,n))}var Va=class e{constructor(e,t=null){Object.defineProperty(this,Oi,{value:Ti}),this.key=e,this.value=t}clone(t){let{key:n,value:r}=this;return R(n)&&(n=n.clone(t)),R(r)&&(r=r.clone(t)),new e(n,r)}toJSON(e,t){return Ra(t,t?.mapAsMap?new Map:{},this)}toString(e,t,n){return e?.doc?Aa(this,e,t,n):JSON.stringify(this)}};function Ha(e,t,n){return(t.inFlow??e.flow?Wa:Ua)(e,t,n)}function Ua({comment:e,items:t},n,{blockItemPrefix:r,flowChars:i,itemIndent:a,onChompKeep:o,onComment:s}){let{indent:c,options:{commentString:l}}=n,u=Object.assign({},n,{indent:a,type:null}),d=!1,f=[];for(let e=0;e<t.length;++e){let i=t[e],o=null;if(R(i))!d&&i.spaceBefore&&f.push(``),Ga(n,f,i.commentBefore,d),i.comment&&(o=i.comment);else if(Mi(i)){let e=R(i.key)?i.key:null;e&&(!d&&e.spaceBefore&&f.push(``),Ga(n,f,e.commentBefore,d))}d=!1;let s=ka(i,u,()=>o=null,()=>d=!0);o&&(s+=ua(s,a,l(o))),d&&o&&(d=!1),f.push(r+s)}let p;if(f.length===0)p=i.start+i.end;else{p=f[0];for(let e=1;e<f.length;++e){let t=f[e];p+=t?`\n${c}${t}`:`
48
+ `}}return e?(p+=`
49
+ `+la(l(e),c),s&&s()):d&&o&&o(),p}function Wa({items:e},t,{flowChars:n,itemIndent:r}){let{indent:i,indentStep:a,flowCollectionPadding:o,options:{commentString:s}}=t;r+=a;let c=Object.assign({},t,{indent:r,inFlow:!0,type:null}),l=!1,u=0,d=[];for(let n=0;n<e.length;++n){let i=e[n],a=null;if(R(i))i.spaceBefore&&d.push(``),Ga(t,d,i.commentBefore,!1),i.comment&&(a=i.comment);else if(Mi(i)){let e=R(i.key)?i.key:null;e&&(e.spaceBefore&&d.push(``),Ga(t,d,e.commentBefore,!1),e.comment&&(l=!0));let n=R(i.value)?i.value:null;n?(n.comment&&(a=n.comment),n.commentBefore&&(l=!0)):i.value==null&&e?.comment&&(a=e.comment)}a&&(l=!0);let o=ka(i,c,()=>a=null);l||=d.length>u||o.includes(`
50
+ `),n<e.length-1?o+=`,`:t.options.trailingComma&&(t.options.lineWidth>0&&(l||=d.reduce((e,t)=>e+t.length+2,2)+(o.length+2)>t.options.lineWidth),l&&(o+=`,`)),a&&(o+=ua(o,r,s(a))),d.push(o),u=d.length}let{start:f,end:p}=n;if(d.length===0)return f+p;if(!l){let e=d.reduce((e,t)=>e+t.length+2,2);l=t.options.lineWidth>0&&e>t.options.lineWidth}if(l){let e=f;for(let t of d)e+=t?`\n${a}${i}${t}`:`
51
+ `;return`${e}\n${i}${p}`}return`${f}${o}${d.join(` `)}${o}${p}`}function Ga({indent:e,options:{commentString:t}},n,r,i){if(r&&i&&(r=r.replace(/^\n+/,``)),r){let i=la(t(r),e);n.push(i.trimStart())}}function Ka(e,t){let n=Ni(t)?t.value:t;for(let r of e)if(Mi(r)&&(r.key===t||r.key===n||Ni(r.key)&&r.key.value===n))return r}var qa=class extends sa{static get tagName(){return`tag:yaml.org,2002:map`}constructor(e){super(wi,e),this.items=[]}static from(e,t,n){let{keepUndefined:r,replacer:i}=n,a=new this(e),o=(e,o)=>{if(typeof i==`function`)o=i.call(t,e,o);else if(Array.isArray(i)&&!i.includes(e))return;(o!==void 0||r)&&a.items.push(Ba(e,o,n))};if(t instanceof Map)for(let[e,n]of t)o(e,n);else if(t&&typeof t==`object`)for(let e of Object.keys(t))o(e,t[e]);return typeof e.sortMapEntries==`function`&&a.items.sort(e.sortMapEntries),a}add(e,t){let n;n=Mi(e)?e:!e||typeof e!=`object`||!(`key`in e)?new Va(e,e?.value):new Va(e.key,e.value);let r=Ka(this.items,n.key),i=this.schema?.sortMapEntries;if(r){if(!t)throw Error(`Key ${n.key} already set`);Ni(r.value)&&ra(n.value)?r.value.value=n.value:r.value=n.value}else if(i){let e=this.items.findIndex(e=>i(n,e)<0);e===-1?this.items.push(n):this.items.splice(e,0,n)}else this.items.push(n)}delete(e){let t=Ka(this.items,e);return t?this.items.splice(this.items.indexOf(t),1).length>0:!1}get(e,t){let n=Ka(this.items,e)?.value;return(!t&&Ni(n)?n.value:n)??void 0}has(e){return!!Ka(this.items,e)}set(e,t){this.add(new Va(e,t),!0)}toJSON(e,t,n){let r=n?new n:t?.mapAsMap?new Map:{};t?.onCreate&&t.onCreate(r);for(let e of this.items)Ra(t,r,e);return r}toString(e,t,n){if(!e)return JSON.stringify(this);for(let e of this.items)if(!Mi(e))throw Error(`Map items must all be pairs; found ${JSON.stringify(e)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),Ha(this,e,{blockItemPrefix:``,flowChars:{start:`{`,end:`}`},itemIndent:e.indent||``,onChompKeep:n,onComment:t})}},Ja={collection:`map`,default:!0,nodeClass:qa,tag:`tag:yaml.org,2002:map`,resolve(e,t){return ji(e)||t(`Expected a mapping for this tag`),e},createNode:(e,t,n)=>qa.from(e,t,n)},Ya=class extends sa{static get tagName(){return`tag:yaml.org,2002:seq`}constructor(e){super(Di,e),this.items=[]}add(e){this.items.push(e)}delete(e){let t=Xa(e);return typeof t==`number`&&this.items.splice(t,1).length>0}get(e,t){let n=Xa(e);if(typeof n!=`number`)return;let r=this.items[n];return!t&&Ni(r)?r.value:r}has(e){let t=Xa(e);return typeof t==`number`&&t<this.items.length}set(e,t){let n=Xa(e);if(typeof n!=`number`)throw Error(`Expected a valid index, not ${e}.`);let r=this.items[n];Ni(r)&&ra(t)?r.value=t:this.items[n]=t}toJSON(e,t){let n=[];t?.onCreate&&t.onCreate(n);let r=0;for(let e of this.items)n.push($i(e,String(r++),t));return n}toString(e,t,n){return e?Ha(this,e,{blockItemPrefix:`- `,flowChars:{start:`[`,end:`]`},itemIndent:(e.indent||``)+` `,onChompKeep:n,onComment:t}):JSON.stringify(this)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t)){let e=0;for(let a of t){if(typeof r==`function`){let n=t instanceof Set?a:String(e++);a=r.call(t,n,a)}i.items.push(ia(a,void 0,n))}}return i}};function Xa(e){let t=Ni(e)?e.value:e;return t&&typeof t==`string`&&(t=Number(t)),typeof t==`number`&&Number.isInteger(t)&&t>=0?t:null}var Za={collection:`seq`,default:!0,nodeClass:Ya,tag:`tag:yaml.org,2002:seq`,resolve(e,t){return Pi(e)||t(`Expected a sequence for this tag`),e},createNode:(e,t,n)=>Ya.from(e,t,n)},Qa={identify:e=>typeof e==`string`,default:!0,tag:`tag:yaml.org,2002:str`,resolve:e=>e,stringify(e,t,n,r){return t=Object.assign({actualString:!0},t),Ta(e,t,n,r)}},$a={identify:e=>e==null,createNode:()=>new z(null),default:!0,tag:`tag:yaml.org,2002:null`,test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new z(null),stringify:({source:e},t)=>typeof e==`string`&&$a.test.test(e)?e:t.options.nullStr},eo={identify:e=>typeof e==`boolean`,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:e=>new z(e[0]===`t`||e[0]===`T`),stringify({source:e,value:t},n){return e&&eo.test.test(e)&&t===(e[0]===`t`||e[0]===`T`)?e:t?n.options.trueStr:n.options.falseStr}};function to({format:e,minFractionDigits:t,tag:n,value:r}){if(typeof r==`bigint`)return String(r);let i=typeof r==`number`?r:Number(r);if(!isFinite(i))return isNaN(i)?`.nan`:i<0?`-.inf`:`.inf`;let a=Object.is(r,-0)?`-0`:JSON.stringify(r);if(!e&&t&&(!n||n===`tag:yaml.org,2002:float`)&&/^-?\d/.test(a)&&!a.includes(`e`)){let e=a.indexOf(`.`);e<0&&(e=a.length,a+=`.`);let n=t-(a.length-e-1);for(;n-->0;)a+=`0`}return a}var no={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>e.slice(-3).toLowerCase()===`nan`?NaN:e[0]===`-`?-1/0:1/0,stringify:to},ro={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`EXP`,test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():to(e)}},io={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){let t=new z(parseFloat(e)),n=e.indexOf(`.`);return n!==-1&&e[e.length-1]===`0`&&(t.minFractionDigits=e.length-n-1),t},stringify:to},ao=e=>typeof e==`bigint`||Number.isInteger(e),oo=(e,t,n,{intAsBigInt:r})=>r?BigInt(e):parseInt(e.substring(t),n);function so(e,t,n){let{value:r}=e;return ao(r)&&r>=0?n+r.toString(t):to(e)}var co={identify:e=>ao(e)&&e>=0,default:!0,tag:`tag:yaml.org,2002:int`,format:`OCT`,test:/^0o[0-7]+$/,resolve:(e,t,n)=>oo(e,2,8,n),stringify:e=>so(e,8,`0o`)},lo={identify:ao,default:!0,tag:`tag:yaml.org,2002:int`,test:/^[-+]?[0-9]+$/,resolve:(e,t,n)=>oo(e,0,10,n),stringify:to},uo={identify:e=>ao(e)&&e>=0,default:!0,tag:`tag:yaml.org,2002:int`,format:`HEX`,test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,n)=>oo(e,2,16,n),stringify:e=>so(e,16,`0x`)},fo=[Ja,Za,Qa,$a,eo,co,lo,uo,no,ro,io];function po(e){return typeof e==`bigint`||Number.isInteger(e)}var mo=({value:e})=>JSON.stringify(e),ho=[{identify:e=>typeof e==`string`,default:!0,tag:`tag:yaml.org,2002:str`,resolve:e=>e,stringify:mo},{identify:e=>e==null,createNode:()=>new z(null),default:!0,tag:`tag:yaml.org,2002:null`,test:/^null$/,resolve:()=>null,stringify:mo},{identify:e=>typeof e==`boolean`,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^true$|^false$/,resolve:e=>e===`true`,stringify:mo},{identify:po,default:!0,tag:`tag:yaml.org,2002:int`,test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:n})=>n?BigInt(e):parseInt(e,10),stringify:({value:e})=>po(e)?e.toString():JSON.stringify(e)},{identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:e=>parseFloat(e),stringify:mo}],go=[Ja,Za].concat(ho,{default:!0,tag:``,test:/^/,resolve(e,t){return t(`Unresolved plain scalar ${JSON.stringify(e)}`),e}}),_o={identify:e=>e instanceof Uint8Array,default:!1,tag:`tag:yaml.org,2002:binary`,resolve(e,t){if(typeof atob==`function`){let t=atob(e.replace(/[\n\r]/g,``)),n=new Uint8Array(t.length);for(let e=0;e<t.length;++e)n[e]=t.charCodeAt(e);return n}return t(`This environment does not support reading binary tags; either Buffer or atob is required`),e},stringify({comment:e,type:t,value:n},r,i,a){if(!n)return``;let o=n,s;if(typeof btoa==`function`){let e=``;for(let t=0;t<o.length;++t)e+=String.fromCharCode(o[t]);s=btoa(e)}else throw Error(`This environment does not support writing binary tags; either Buffer or btoa is required`);if(t??=z.BLOCK_LITERAL,t!==z.QUOTE_DOUBLE){let e=Math.max(r.options.lineWidth-r.indent.length,r.options.minContentWidth),n=Math.ceil(s.length/e),i=Array(n);for(let t=0,r=0;t<n;++t,r+=e)i[t]=s.substr(r,e);s=i.join(t===z.BLOCK_LITERAL?`
52
+ `:` `)}return Ta({comment:e,type:t,value:s},r,i,a)}};function vo(e,t){if(Pi(e))for(let n=0;n<e.items.length;++n){let r=e.items[n];if(!Mi(r)){if(ji(r)){r.items.length>1&&t(`Each pair must have its own sequence indicator`);let e=r.items[0]||new Va(new z(null));if(r.commentBefore&&(e.key.commentBefore=e.key.commentBefore?`${r.commentBefore}\n${e.key.commentBefore}`:r.commentBefore),r.comment){let t=e.value??e.key;t.comment=t.comment?`${r.comment}\n${t.comment}`:r.comment}r=e}e.items[n]=Mi(r)?r:new Va(r)}}else t(`Expected a sequence for this tag`);return e}function yo(e,t,n){let{replacer:r}=n,i=new Ya(e);i.tag=`tag:yaml.org,2002:pairs`;let a=0;if(t&&Symbol.iterator in Object(t))for(let e of t){typeof r==`function`&&(e=r.call(t,String(a++),e));let o,s;if(Array.isArray(e)){if(e.length===2)o=e[0],s=e[1];else throw TypeError(`Expected [key, value] tuple: ${e}`)}else if(e&&e instanceof Object){let t=Object.keys(e);if(t.length===1)o=t[0],s=e[o];else throw TypeError(`Expected tuple with one key, not ${t.length} keys`)}else o=e;i.items.push(Ba(o,s,n))}return i}var bo={collection:`seq`,default:!1,tag:`tag:yaml.org,2002:pairs`,resolve:vo,createNode:yo},xo=class e extends Ya{constructor(){super(),this.add=qa.prototype.add.bind(this),this.delete=qa.prototype.delete.bind(this),this.get=qa.prototype.get.bind(this),this.has=qa.prototype.has.bind(this),this.set=qa.prototype.set.bind(this),this.tag=e.tag}toJSON(e,t){if(!t)return super.toJSON(e);let n=new Map;t?.onCreate&&t.onCreate(n);for(let e of this.items){let r,i;if(Mi(e)?(r=$i(e.key,``,t),i=$i(e.value,r,t)):r=$i(e,``,t),n.has(r))throw Error(`Ordered maps must not include duplicate keys`);n.set(r,i)}return n}static from(e,t,n){let r=yo(e,t,n),i=new this;return i.items=r.items,i}};xo.tag=`tag:yaml.org,2002:omap`;var So={collection:`seq`,identify:e=>e instanceof Map,nodeClass:xo,default:!1,tag:`tag:yaml.org,2002:omap`,resolve(e,t){let n=vo(e,t),r=[];for(let{key:e}of n.items)Ni(e)&&(r.includes(e.value)?t(`Ordered maps must not include duplicate keys: ${e.value}`):r.push(e.value));return Object.assign(new xo,n)},createNode:(e,t,n)=>xo.from(e,t,n)};function Co({value:e,source:t},n){return t&&(e?wo:To).test.test(t)?t:e?n.options.trueStr:n.options.falseStr}var wo={identify:e=>e===!0,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new z(!0),stringify:Co},To={identify:e=>e===!1,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new z(!1),stringify:Co},Eo={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>e.slice(-3).toLowerCase()===`nan`?NaN:e[0]===`-`?-1/0:1/0,stringify:to},Do={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`EXP`,test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e.replace(/_/g,``)),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():to(e)}},Oo={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){let t=new z(parseFloat(e.replace(/_/g,``))),n=e.indexOf(`.`);if(n!==-1){let r=e.substring(n+1).replace(/_/g,``);r[r.length-1]===`0`&&(t.minFractionDigits=r.length)}return t},stringify:to},ko=e=>typeof e==`bigint`||Number.isInteger(e);function Ao(e,t,n,{intAsBigInt:r}){let i=e[0];if((i===`-`||i===`+`)&&(t+=1),e=e.substring(t).replace(/_/g,``),r){switch(n){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`}let t=BigInt(e);return i===`-`?BigInt(-1)*t:t}let a=parseInt(e,n);return i===`-`?-1*a:a}function jo(e,t,n){let{value:r}=e;if(ko(r)){let e=r.toString(t);return r<0?`-`+n+e.substr(1):n+e}return to(e)}var Mo={identify:ko,default:!0,tag:`tag:yaml.org,2002:int`,format:`BIN`,test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,n)=>Ao(e,2,2,n),stringify:e=>jo(e,2,`0b`)},No={identify:ko,default:!0,tag:`tag:yaml.org,2002:int`,format:`OCT`,test:/^[-+]?0[0-7_]+$/,resolve:(e,t,n)=>Ao(e,1,8,n),stringify:e=>jo(e,8,`0`)},Po={identify:ko,default:!0,tag:`tag:yaml.org,2002:int`,test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,n)=>Ao(e,0,10,n),stringify:to},Fo={identify:ko,default:!0,tag:`tag:yaml.org,2002:int`,format:`HEX`,test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,n)=>Ao(e,2,16,n),stringify:e=>jo(e,16,`0x`)},Io=class e extends qa{constructor(t){super(t),this.tag=e.tag}add(e){let t;t=Mi(e)?e:e&&typeof e==`object`&&`key`in e&&`value`in e&&e.value===null?new Va(e.key,null):new Va(e,null),Ka(this.items,t.key)||this.items.push(t)}get(e,t){let n=Ka(this.items,e);return!t&&Mi(n)?Ni(n.key)?n.key.value:n.key:n}set(e,t){if(typeof t!=`boolean`)throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof t}`);let n=Ka(this.items,e);n&&!t?this.items.splice(this.items.indexOf(n),1):!n&&t&&this.items.push(new Va(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,n);throw Error(`Set items must all have null values`)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t))for(let e of t)typeof r==`function`&&(e=r.call(t,e,e)),i.items.push(Ba(e,null,n));return i}};Io.tag=`tag:yaml.org,2002:set`;var Lo={collection:`map`,identify:e=>e instanceof Set,nodeClass:Io,default:!1,tag:`tag:yaml.org,2002:set`,createNode:(e,t,n)=>Io.from(e,t,n),resolve(e,t){if(ji(e)){if(e.hasAllNullValues(!0))return Object.assign(new Io,e);t(`Set items must all have null values`)}else t(`Expected a mapping for this tag`);return e}};function Ro(e,t){let n=e[0],r=n===`-`||n===`+`?e.substring(1):e,i=e=>t?BigInt(e):Number(e),a=r.replace(/_/g,``).split(`:`).reduce((e,t)=>e*i(60)+i(t),i(0));return n===`-`?i(-1)*a:a}function zo(e){let{value:t}=e,n=e=>e;if(typeof t==`bigint`)n=e=>BigInt(e);else if(isNaN(t)||!isFinite(t))return to(e);let r=``;t<0&&(r=`-`,t*=n(-1));let i=n(60),a=[t%i];return t<60?a.unshift(0):(t=(t-a[0])/i,a.unshift(t%i),t>=60&&(t=(t-a[0])/i,a.unshift(t))),r+a.map(e=>String(e).padStart(2,`0`)).join(`:`).replace(/000000\d*$/,``)}var Bo={identify:e=>typeof e==`bigint`||Number.isInteger(e),default:!0,tag:`tag:yaml.org,2002:int`,format:`TIME`,test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:n})=>Ro(e,n),stringify:zo},Vo={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`TIME`,test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:e=>Ro(e,!1),stringify:zo},H={identify:e=>e instanceof Date,default:!0,tag:`tag:yaml.org,2002:timestamp`,test:RegExp(`^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$`),resolve(e){let t=e.match(H.test);if(!t)throw Error(`!!timestamp expects a date, starting with yyyy-mm-dd`);let[,n,r,i,a,o,s]=t.map(Number),c=t[7]?Number((t[7]+`00`).substr(1,3)):0,l=Date.UTC(n,r-1,i,a||0,o||0,s||0,c),u=t[8];if(u&&u!==`Z`){let e=Ro(u,!1);Math.abs(e)<30&&(e*=60),l-=6e4*e}return new Date(l)},stringify:({value:e})=>e?.toISOString().replace(/(T00:00:00)?\.000Z$/,``)??``},U=[Ja,Za,Qa,$a,wo,To,Mo,No,Po,Fo,Eo,Do,Oo,_o,Na,So,bo,Lo,Bo,Vo,H],Ho=new Map([[`core`,fo],[`failsafe`,[Ja,Za,Qa]],[`json`,go],[`yaml11`,U],[`yaml-1.1`,U]]),Uo={binary:_o,bool:eo,float:io,floatExp:ro,floatNaN:no,floatTime:Vo,int:lo,intHex:uo,intOct:co,intTime:Bo,map:Ja,merge:Na,null:$a,omap:So,pairs:bo,seq:Za,set:Lo,timestamp:H},Wo={"tag:yaml.org,2002:binary":_o,"tag:yaml.org,2002:merge":Na,"tag:yaml.org,2002:omap":So,"tag:yaml.org,2002:pairs":bo,"tag:yaml.org,2002:set":Lo,"tag:yaml.org,2002:timestamp":H};function Go(e,t,n){let r=Ho.get(t);if(r&&!e)return n&&!r.includes(Na)?r.concat(Na):r.slice();let i=r;if(!i){if(Array.isArray(e))i=[];else{let e=Array.from(Ho.keys()).filter(e=>e!==`yaml11`).map(e=>JSON.stringify(e)).join(`, `);throw Error(`Unknown schema "${t}"; use one of ${e} or define customTags array`)}}if(Array.isArray(e))for(let t of e)i=i.concat(t);else typeof e==`function`&&(i=e(i.slice()));return n&&(i=i.concat(Na)),i.reduce((e,t)=>{let n=typeof t==`string`?Uo[t]:t;if(!n){let e=JSON.stringify(t),n=Object.keys(Uo).map(e=>JSON.stringify(e)).join(`, `);throw Error(`Unknown custom tag ${e}; use one of ${n}`)}return e.includes(n)||e.push(n),e},[])}var Ko=(e,t)=>e.key<t.key?-1:+(e.key>t.key),qo=class e{constructor({compat:e,customTags:t,merge:n,resolveKnownTags:r,schema:i,sortMapEntries:a,toStringDefaults:o}){this.compat=Array.isArray(e)?Go(e,`compat`):e?Go(null,e):null,this.name=typeof i==`string`&&i||`core`,this.knownTags=r?Wo:{},this.tags=Go(t,this.name,n),this.toStringOptions=o??null,Object.defineProperty(this,wi,{value:Ja}),Object.defineProperty(this,Ei,{value:Qa}),Object.defineProperty(this,Di,{value:Za}),this.sortMapEntries=typeof a==`function`?a:a===!0?Ko:null}clone(){let t=Object.create(e.prototype,Object.getOwnPropertyDescriptors(this));return t.tags=this.tags.slice(),t}};function Jo(e,t){let n=[],r=t.directives===!0;if(t.directives!==!1&&e.directives){let t=e.directives.toString(e);t?(n.push(t),r=!0):e.directives.docStart&&(r=!0)}r&&n.push(`---`);let i=Ea(e,t),{commentString:a}=i.options;if(e.commentBefore){n.length!==1&&n.unshift(``);let t=a(e.commentBefore);n.unshift(la(t,``))}let o=!1,s=null;if(e.contents){if(R(e.contents)){if(e.contents.spaceBefore&&r&&n.push(``),e.contents.commentBefore){let t=a(e.contents.commentBefore);n.push(la(t,``))}i.forceBlockIndent=!!e.comment,s=e.contents.comment}let t=s?void 0:()=>o=!0,c=ka(e.contents,i,()=>s=null,t);s&&(c+=ua(c,``,a(s))),(c[0]===`|`||c[0]===`>`)&&n[n.length-1]===`---`?n[n.length-1]=`--- ${c}`:n.push(c)}else n.push(ka(e.contents,i));if(e.directives?.docEnd){if(e.comment){let t=a(e.comment);t.includes(`
53
+ `)?(n.push(`...`),n.push(la(t,``))):n.push(`... ${t}`)}else n.push(`...`)}else{let t=e.comment;t&&o&&(t=t.replace(/^\n+/,``)),t&&((!o||s)&&n[n.length-1]!==``&&n.push(``),n.push(la(a(t),``)))}return n.join(`
54
+ `)+`
55
+ `}var Yo=class e{constructor(e,t,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,Oi,{value:Ci});let r=null;typeof t==`function`||Array.isArray(t)?r=t:n===void 0&&t&&(n=t,t=void 0);let i=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:`warn`,prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:`1.2`},n);this.options=i;let{version:a}=i;n?._directives?(this.directives=n._directives.atDocument(),this.directives.yaml.explicit&&(a=this.directives.yaml.version)):this.directives=new qi({version:a}),this.setSchema(a,n),this.contents=e===void 0?null:this.createNode(e,r,n)}clone(){let t=Object.create(e.prototype,{[Oi]:{value:Ci}});return t.commentBefore=this.commentBefore,t.comment=this.comment,t.errors=this.errors.slice(),t.warnings=this.warnings.slice(),t.options=Object.assign({},this.options),this.directives&&(t.directives=this.directives.clone()),t.schema=this.schema.clone(),t.contents=R(this.contents)?this.contents.clone(t.schema):this.contents,this.range&&(t.range=this.range.slice()),t}add(e){W(this.contents)&&this.contents.add(e)}addIn(e,t){W(this.contents)&&this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){let n=Yi(this);e.anchor=!t||n.has(t)?Xi(t||`a`,n):t}return new ta(e.anchor)}createNode(e,t,n){let r;if(typeof t==`function`)e=t.call({"":e},``,e),r=t;else if(Array.isArray(t)){let e=t.filter(e=>typeof e==`number`||e instanceof String||e instanceof Number).map(String);e.length>0&&(t=t.concat(e)),r=t}else n===void 0&&t&&(n=t,t=void 0);let{aliasDuplicateObjects:i,anchorPrefix:a,flow:o,keepUndefined:s,onTagObj:c,tag:l}=n??{},{onAnchor:u,setAnchors:d,sourceObjects:f}=Zi(this,a||`a`),p={aliasDuplicateObjects:i??!0,keepUndefined:s??!1,onAnchor:u,onTagObj:c,replacer:r,schema:this.schema,sourceObjects:f},m=ia(e,l,p);return o&&Fi(m)&&(m.flow=!0),d(),m}createPair(e,t,n={}){return new Va(this.createNode(e,null,n),this.createNode(t,null,n))}delete(e){return W(this.contents)?this.contents.delete(e):!1}deleteIn(e){return oa(e)?this.contents!=null&&(this.contents=null,!0):W(this.contents)?this.contents.deleteIn(e):!1}get(e,t){return Fi(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){return oa(e)?!t&&Ni(this.contents)?this.contents.value:this.contents:Fi(this.contents)?this.contents.getIn(e,t):void 0}has(e){return Fi(this.contents)?this.contents.has(e):!1}hasIn(e){return oa(e)?this.contents!==void 0:Fi(this.contents)?this.contents.hasIn(e):!1}set(e,t){this.contents==null?this.contents=aa(this.schema,[e],t):W(this.contents)&&this.contents.set(e,t)}setIn(e,t){oa(e)?this.contents=t:this.contents==null?this.contents=aa(this.schema,Array.from(e),t):W(this.contents)&&this.contents.setIn(e,t)}setSchema(e,t={}){typeof e==`number`&&(e=String(e));let n;switch(e){case`1.1`:this.directives?this.directives.yaml.version=`1.1`:this.directives=new qi({version:`1.1`}),n={resolveKnownTags:!1,schema:`yaml-1.1`};break;case`1.2`:case`next`:this.directives?this.directives.yaml.version=e:this.directives=new qi({version:e}),n={resolveKnownTags:!0,schema:`core`};break;case null:this.directives&&delete this.directives,n=null;break;default:{let t=JSON.stringify(e);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${t}`)}}if(t.schema instanceof Object)this.schema=t.schema;else if(n)this.schema=new qo(Object.assign(n,t));else throw Error(`With a null YAML version, the { schema: Schema } option is required`)}toJS({json:e,jsonArg:t,mapAsMap:n,maxAliasCount:r,onAnchor:i,reviver:a}={}){let o={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof r==`number`?r:100},s=$i(this.contents,t??``,o);if(typeof i==`function`)for(let{count:e,res:t}of o.anchors.values())i(t,e);return typeof a==`function`?Qi(a,{"":s},``,s):s}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw Error(`Document with errors cannot be stringified`);if(`indent`in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){let t=JSON.stringify(e.indent);throw Error(`"indent" option must be a positive integer, not ${t}`)}return Jo(this,e)}};function W(e){if(Fi(e))return!0;throw Error(`Expected a YAML collection as document contents`)}var Xo=Symbol(`break visit`),Zo=Symbol(`skip children`),Qo=Symbol(`remove item`);function $o(e,t){`type`in e&&e.type===`document`&&(e={start:e.start,value:e.value}),es(Object.freeze([]),e,t)}$o.BREAK=Xo,$o.SKIP=Zo,$o.REMOVE=Qo,$o.itemAtPath=(e,t)=>{let n=e;for(let[e,r]of t){let t=n?.[e];if(t&&`items`in t)n=t.items[r];else return}return n},$o.parentCollection=(e,t)=>{let n=$o.itemAtPath(e,t.slice(0,-1)),r=t[t.length-1][0],i=n?.[r];if(i&&`items`in i)return i;throw Error(`Parent collection not found`)};function es(e,t,n){let r=n(t,e);if(typeof r==`symbol`)return r;for(let i of[`key`,`value`]){let a=t[i];if(a&&`items`in a){for(let t=0;t<a.items.length;++t){let r=es(Object.freeze(e.concat([[i,t]])),a.items[t],n);if(typeof r==`number`)t=r-1;else if(r===Xo)return Xo;else r===Qo&&(a.items.splice(t,1),--t)}typeof r==`function`&&i===`key`&&(r=r(t,e))}}return typeof r==`function`?r(t,e):r}function ts(e,t,n){let r=null;if(typeof t==`function`||Array.isArray(t)?r=t:n===void 0&&t&&(n=t),typeof n==`string`&&(n=n.length),typeof n==`number`){let e=Math.round(n);n=e<1?void 0:e>8?{indent:8}:{indent:e}}if(e===void 0){let{keepUndefined:e}=n??t??{};if(!e)return}return Ai(e)&&!r?e.toString(n):new Yo(e,r,n).toString(n)}var ns=[{group:`Correctness`,id:`money-integer-cents`,title:`Money uses integer minor units`,description:`Amounts of money must be stored and computed as integers in the smallest unit (cents) or with a decimal type. Floating-point math on money is a defect, and every conversion must round explicitly.`,paths:[],severity:`major`,badExample:`const total = price * 1.18`,goodExample:`const total = Math.round(priceCents * 118 / 100)`},{group:`Correctness`,id:`await-promises`,title:`Every promise is awaited or handled`,description:`Async calls must be awaited, returned, or explicitly handled with .catch(). Fire-and-forget promises that can reject are defects unless clearly intentional and commented.`,paths:[`**/*.ts`,`**/*.tsx`,`**/*.js`],severity:`major`},{group:`Correctness`,id:`utc-dates`,title:`Dates are stored and compared in UTC`,description:`Timestamps must be created, stored and compared in UTC. Local-time arithmetic, naive datetime objects and string comparison of dates are defects.`,paths:[],severity:`major`},{group:`Security`,id:`no-sql-concatenation`,title:`No SQL built from strings`,description:`SQL must use parameterized queries or the query builder. Interpolating or concatenating request data into SQL text is a critical security defect.`,paths:[],severity:`critical`,badExample:"db.query(`SELECT * FROM users WHERE id = ${req.params.id}`)",goodExample:`db.query('SELECT * FROM users WHERE id = $1', [req.params.id])`},{group:`Security`,id:`authz-on-endpoints`,title:`Every endpoint checks authorization`,description:`New or changed HTTP handlers must verify that the caller may access the specific resource (not only that they are logged in). Missing ownership checks on ids from the request are IDOR defects.`,paths:[`**/routes/**`,`**/controllers/**`,`**/api/**`,`**/handlers/**`],severity:`critical`},{group:`Security`,id:`no-secrets-in-logs`,title:`No secrets or personal data in logs`,description:`Logs and error messages must not include tokens, passwords, API keys, full card numbers or personal data such as emails and addresses.`,paths:[],severity:`major`},{group:`Security`,id:`validate-input`,title:`External input is validated at the boundary`,description:`Request bodies, query parameters, webhook payloads and file uploads must be validated with a schema before use. Trusting their shape or size is a defect.`,paths:[],severity:`major`},{group:`Reliability`,id:`timeouts-on-network`,title:`Network calls have timeouts`,description:`HTTP clients, database drivers and queue consumers must set explicit timeouts. Calls that can hang forever are defects.`,paths:[],severity:`minor`},{group:`Reliability`,id:`transactions-for-multi-writes`,title:`Related writes happen in one transaction`,description:`When a change performs several dependent database writes, they must run in a transaction so a failure cannot leave partial state.`,paths:[],severity:`major`},{group:`Reliability`,id:`no-swallowed-errors`,title:`Errors are never swallowed silently`,description:`catch blocks must handle, rethrow or log with context. Empty catch blocks and catch-and-return-null without a comment are defects.`,paths:[],severity:`major`},{group:`Frontend`,id:`react-effect-deps`,title:`React effects declare their dependencies`,description:`useEffect, useMemo and useCallback must list every reactive value they read. Missing or stale dependencies are defects; disable comments need a justification.`,paths:[`**/*.tsx`,`**/*.jsx`],severity:`minor`},{group:`Frontend`,id:`accessible-controls`,title:`Interactive elements are accessible`,description:`Clickable elements must be buttons or links with accessible names. Icon-only buttons need aria-label, images need alt text, and form inputs need labels.`,paths:[`**/*.tsx`,`**/*.jsx`,`**/*.vue`,`**/*.svelte`],severity:`minor`},{group:`Data`,id:`safe-migrations`,title:`Migrations are safe on large tables`,description:`Schema migrations must be backwards compatible with the running code and must not lock large tables (for example adding a NOT NULL column without a default, or building an index without CONCURRENTLY on Postgres).`,paths:[`**/migrations/**`,`**/*.sql`],severity:`critical`},{group:`Data`,id:`paginate-queries`,title:`List queries are bounded`,description:`Queries and API endpoints that return lists must paginate or limit results. Loading unbounded collections into memory is a defect.`,paths:[],severity:`major`}],rs={id:``,title:``,description:``,paths:[],severity:`major`,enabled:!0};function is(e){return e.toLowerCase().replace(/[^a-z0-9]+/g,`-`).replace(/^-|-$/g,``).slice(0,48)||`rule-${Date.now().toString(36)}`}function as({rule:e,onClose:t,onSave:n,existingIds:r}){let[i,a]=(0,v.useState)(e??rs),o=!e?.id,s=i.id||is(i.title),c=o&&r.includes(s),l=i.title.trim().length>2&&i.description.trim().length>5&&!c;return(0,k.jsx)(_r,{open:!0,wide:!0,onClose:t,title:o?`New rule`:`Edit rule`,footer:(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(j,{variant:`ghost`,onClick:t,children:`Cancel`}),(0,k.jsx)(j,{variant:`primary`,disabled:!l,onClick:()=>n({...i,id:s,title:i.title.trim(),description:i.description.trim()}),children:o?`Add rule`:`Save rule`})]}),children:(0,k.jsxs)(`div`,{className:`space-y-4`,children:[(0,k.jsx)(N,{label:`Title`,hint:`Phrase it as the expected behaviour.`,children:(0,k.jsx)(M,{value:i.title,onChange:e=>a({...i,title:e.target.value}),placeholder:`Money uses integer cents`})}),(0,k.jsx)(N,{label:`Rule`,hint:`Explain what is a violation and why. Argus reports every violation in changed code as a finding.`,children:(0,k.jsx)(or,{rows:4,value:i.description,onChange:e=>a({...i,description:e.target.value})})}),(0,k.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-[1fr_200px]`,children:[(0,k.jsx)(N,{label:`Applies to`,hint:`Glob patterns. Empty means the whole repository.`,children:(0,k.jsx)(hr,{value:i.paths,onChange:e=>a({...i,paths:e}),placeholder:`src/billing/**`})}),(0,k.jsx)(N,{label:`Severity`,children:(0,k.jsx)(sr,{value:i.severity,onChange:e=>a({...i,severity:e.target.value}),children:[`critical`,`major`,`minor`,`nitpick`].map(e=>(0,k.jsx)(`option`,{value:e,children:e},e))})})]}),(0,k.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-2`,children:[(0,k.jsx)(N,{label:`Bad example (optional)`,children:(0,k.jsx)(or,{rows:4,className:`font-mono text-[12.5px]`,value:i.badExample??``,onChange:e=>a({...i,badExample:e.target.value||void 0})})}),(0,k.jsx)(N,{label:`Good example (optional)`,children:(0,k.jsx)(or,{rows:4,className:`font-mono text-[12.5px]`,value:i.goodExample??``,onChange:e=>a({...i,goodExample:e.target.value||void 0})})})]}),(0,k.jsxs)(`p`,{className:`font-mono text-[12px] text-ink-3`,children:[`id: `,s,c&&(0,k.jsx)(`span`,{className:`ml-2 text-critical`,children:`already used`})]})]})})}function os(){let e=Yr(),t=e.get(`rules`)??[],[n,r]=(0,v.useState)(void 0),[i,a]=(0,v.useState)(!1),[o,s]=(0,v.useState)(``),c=t.map(e=>e.id),l=(0,v.useMemo)(()=>t.filter(e=>!o||`${e.title} ${e.description} ${e.paths.join(` `)}`.toLowerCase().includes(o.toLowerCase())),[t,o]);return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{eyebrow:`${t.filter(e=>e.enabled).length} active`,title:(0,k.jsxs)(k.Fragment,{children:[`Custom rules`,(0,k.jsx)(si,{path:`rules`})]}),actions:(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(j,{size:`sm`,onClick:()=>a(!0),children:`Browse templates`}),(0,k.jsx)(j,{size:`sm`,variant:`primary`,onClick:()=>r(null),children:`New rule`})]}),padded:!1,children:t.length===0?(0,k.jsx)(vr,{title:`No rules yet`,action:(0,k.jsx)(j,{onClick:()=>a(!0),children:`Start from a template`}),children:`Rules turn your team's conventions into checks. Argus reports every violation in changed code, with the rule's severity.`}):(0,k.jsxs)(k.Fragment,{children:[t.length>6&&(0,k.jsx)(`div`,{className:`border-b border-line px-5 py-3`,children:(0,k.jsx)(M,{placeholder:`Filter rules`,value:o,onChange:e=>s(e.target.value)})}),(0,k.jsx)(`ul`,{className:`divide-y divide-line`,children:l.map(n=>(0,k.jsxs)(`li`,{className:A(`flex items-start gap-4 px-5 py-4`,!n.enabled&&`opacity-55`),children:[(0,k.jsx)(cr,{checked:n.enabled,label:`Enable ${n.title}`,onChange:r=>e.set(`rules`,t.map(e=>e.id===n.id?{...e,enabled:r}:e))}),(0,k.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,k.jsxs)(`div`,{className:`flex flex-wrap items-center gap-2`,children:[(0,k.jsx)(`span`,{className:`font-medium text-ink`,children:n.title}),(0,k.jsx)(fr,{severity:n.severity}),n.paths.map(e=>(0,k.jsx)(F,{className:`font-mono`,children:e},e))]}),(0,k.jsx)(`p`,{className:`mt-1 line-clamp-2 text-[13px] text-ink-2`,children:n.description})]}),(0,k.jsxs)(`div`,{className:`flex shrink-0 gap-1`,children:[(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:()=>r(n),children:`Edit`}),(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:()=>e.set(`rules`,t.filter(e=>e.id!==n.id)),children:`Delete`})]})]},n.id))})]})}),n!==void 0&&(0,k.jsx)(as,{rule:n,existingIds:c,onClose:()=>r(void 0),onSave:i=>{let a=t.findIndex(e=>e.id===(n?.id||i.id)),o=[...t];a>=0?o[a]=i:o.push(i),e.set(`rules`,o),r(void 0)}}),(0,k.jsx)(_r,{open:i,onClose:()=>a(!1),title:`Rule templates`,wide:!0,children:(0,k.jsx)(`div`,{className:`space-y-6`,children:[...new Set(ns.map(e=>e.group))].map(n=>(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`eyebrow mb-2`,children:n}),(0,k.jsx)(`div`,{className:`grid gap-2 md:grid-cols-2`,children:ns.filter(e=>e.group===n).map(n=>{let r=c.includes(n.id);return(0,k.jsxs)(`div`,{className:`flex flex-col rounded-xl border border-line-strong p-3.5`,children:[(0,k.jsxs)(`div`,{className:`flex items-start justify-between gap-2`,children:[(0,k.jsx)(`span`,{className:`font-medium`,children:n.title}),(0,k.jsx)(fr,{severity:n.severity})]}),(0,k.jsx)(`p`,{className:`mt-1 flex-1 text-[12.5px] text-ink-2`,children:n.description}),(0,k.jsx)(`div`,{className:`mt-3`,children:(0,k.jsx)(j,{size:`sm`,variant:r?`ghost`:`secondary`,disabled:r,onClick:()=>{let{group:r,...i}=n;e.set(`rules`,[...t,{...i,enabled:!0}])},children:r?`Added`:`Add rule`})})]},n.id)})})]},n))})})]})}var ss={openrouter:[`anthropic/claude-sonnet-5.5`,`openai/gpt-6-luna`,`google/gemini-3.8-flash`],"claude-code":[`claude-sonnet-5-5`,`claude-opus-5-5`,`claude-haiku-4-5`],copilot:[`auto`,`claude-sonnet-5.5`,`gpt-6-luna`,`gemini-3.8-flash`],codex:[`gpt-6-luna`]},cs={openrouter:void 0,"claude-code":`@anthropic-ai/claude-code@2.1.296`,copilot:`@github/copilot@1.0.95`,codex:`@openai/codex@0.162.1`},ls=`https://github.com/anevski-stefan/argus`,us=`$HOME/argus-src`,ds=e=>[`git clone --depth 1 --branch v${e} ${ls}.git "${us}"`,`(cd "${us}" && npm ci)`],fs=e=>JSON.stringify(e),ps=e=>`'${e.replace(/'/g,`'\\''`)}'`,ms=e=>"${{ "+e+` }}`,hs=e=>/^[\w.:/@+-]+$/.test(e)?`export ARGUS_MODEL="\${ARGUS_MODEL:-${e}}"`:`[ -n "$ARGUS_MODEL" ] || ARGUS_MODEL=${ps(e)}; export ARGUS_MODEL`,gs={name:`ARGUS_TOKEN`,how:`Copy the token shown when you added this repository in the Argus dashboard.`},_s=/^https?:\/\/[^\s"'`\\$<>{}|^]+$/;function vs(e){if(e===void 0)return;let t=e.trim().replace(/\/+$/,``),n=_s.test(t);try{new URL(t)}catch{n=!1}if(!n)throw Error(`The dashboard URL must be a plain http(s) URL`);return t}var ys={github:`A fine-grained personal access token with "Secrets: write" on this repository. Argus uses it to store the refreshed Codex login after each run.`,gitlab:`A project access token with the api scope (Maintainer role). Argus uses it to store the refreshed Codex login after each run. Do not mark the variable Protected.`,bitbucket:`A repository access token with "Pipelines: Edit variables". Argus uses it to store the refreshed Codex login after each run.`,azure:`A personal access token with "Variable Groups (Read, create, & manage)". Argus uses it to store the refreshed Codex login after each run.`},bs={gitlab:{name:`GITLAB_TOKEN`,how:`A project access token with the api scope (the built-in job token cannot post comments). Add it as a masked CI/CD variable.`},bitbucket:{name:`BITBUCKET_TOKEN`,how:`A repository access token with pull request write. Add it as a secured repository variable.`}},xs={github:`a repository secret (not an organization secret: Argus can only update the repository one)`,gitlab:`a masked project-level CI/CD variable (not a group variable: Argus can only update the project one)`,bitbucket:`a secured repository variable (not a workspace variable: Argus can only update the repository one)`,azure:`a secret variable in a variable group used only by this pipeline, holding only this variable`};function Ss(e,t){let n={github:`a repository secret`,gitlab:`a masked CI/CD variable`,bitbucket:`a secured repository variable`,azure:`a secret pipeline variable`}[e];switch(t){case`openrouter`:return[{name:`OPENROUTER_API_KEY`,how:`Your OpenRouter API key, stored as ${n}.`}];case`claude-code`:return[{name:`CLAUDE_CODE_OAUTH_TOKEN`,how:`Run "claude setup-token" on a machine with your Claude Pro or Max login and store the token as ${n}.`}];case`copilot`:return[{name:`COPILOT_GITHUB_TOKEN`,how:`A fine-grained personal access token owned by a personal account (not an organisation) with the "Copilot Requests" permission, stored as ${n}.`}];case`codex`:{let t=[{name:`ARGUS_CODEX_AUTH`,how:`Run "codex login", then "argus codex-secret", and store the printed value as ${xs[e]}. Argus rewrites it after each run because the login refreshes. Do this separately for each repository: one login shared by several repositories stops working once another repository refreshes it.`},{name:`ARGUS_SECRET_WRITE_TOKEN`,how:ys[e]}];return e===`azure`&&t.push({name:`ARGUS_AZURE_VARIABLE_GROUP_ID`,how:`The numeric id of that variable group (visible in the URL as variableGroupId). Set it as a normal pipeline variable.`}),t}}}function Cs(e,t){let n=!!e.fromSource,r=cs[e.provider];return{provider:e.provider,model:e.model.trim(),version:e.version,fromSource:n,codex:e.provider===`codex`,secretNames:t.map(e=>e.name),dashboardUrl:vs(e.dashboardUrl),prelude:[...r?[`npm install -g ${r}`]:[],...n?ds(e.version):[]],run:n?`${us}/bin/argus ci`:`npx -y argus-review@${e.version} ci`}}var ws=(e,t)=>t.map(t=>` `.repeat(e)+t).join(`
56
+ `);function Ts(e){let t=[`GITHUB_TOKEN: ${ms(`secrets.GITHUB_TOKEN`)}`,`ARGUS_PROVIDER: ${fs(e.provider)}`,`ARGUS_MODEL: ${fs(ms(e.model?`vars.ARGUS_MODEL || '${e.model.replace(/'/g,`''`)}'`:`vars.ARGUS_MODEL`))}`,...e.dashboardUrl?[`ARGUS_URL: ${fs(e.dashboardUrl)}`]:[],...e.secretNames.map(e=>`${e}: ${ms(`secrets.${e}`)}`)];return`name: Argus review
57
+ on:
58
+ pull_request:
59
+ types: [opened, synchronize, reopened, ready_for_review]
60
+ issue_comment:
61
+ types: [created]
62
+ pull_request_review_comment:
63
+ types: [created]
64
+
65
+ permissions:
66
+ contents: read
67
+ pull-requests: write
68
+ issues: write
69
+ statuses: write
70
+ ${e.codex?`
71
+ concurrency:
72
+ group: argus-codex
73
+ cancel-in-progress: false
74
+ queue: max
75
+ `:``}
76
+ jobs:
77
+ review:
78
+ if: >-
79
+ github.event_name == 'pull_request' ||
80
+ ((contains(github.event.comment.body, '@argus') || github.event.comment.in_reply_to_id) &&
81
+ contains(fromJSON('["OWNER","MEMBER","COLLABORATOR"]'), github.event.comment.author_association))
82
+ runs-on: ubuntu-latest
83
+ steps:
84
+ - uses: actions/checkout@v4
85
+ with:
86
+ fetch-depth: 0
87
+ - uses: actions/setup-node@v4
88
+ with:
89
+ node-version: 22
90
+ ${e.prelude.map(e=>` - run: ${e}`).join(`
91
+ `)}${e.prelude.length?`
92
+ `:``} - run: ${e.run}
93
+ env:
94
+ ${ws(10,t)}`}function Es(e){let t=[`GIT_DEPTH: "0"`,`DOCKER_HOST: tcp://docker:2375`,`DOCKER_TLS_CERTDIR: ""`,`ARGUS_EXEC_DIR: $CI_PROJECT_DIR/.argus-exec`,`ARGUS_PROVIDER: ${fs(e.provider)}`,...e.model?[`ARGUS_MODEL: ${fs(e.model)}`]:[],...e.dashboardUrl?[`ARGUS_URL: ${fs(e.dashboardUrl)}`]:[]],n=[`curl -fsSL https://download.docker.com/linux/static/stable/x86_64/docker-27.3.1.tgz | tar -xz --strip-components=1 -C /usr/local/bin docker/docker`,...e.prelude,e.run];return`argus-review:
95
+ stage: test
96
+ image: node:22
97
+ services:
98
+ - docker:27-dind
99
+ ${e.codex?` resource_group: argus-codex
100
+ `:``} rules:
101
+ - if: $CI_PIPELINE_SOURCE == "merge_request_event" && $CI_MERGE_REQUEST_SOURCE_PROJECT_ID == $CI_PROJECT_ID
102
+ variables:
103
+ ${ws(4,t)}
104
+ script:
105
+ ${ws(4,n.map(e=>`- ${e}`))}
106
+ allow_failure: true`}function Ds(e){let t=[...e.dashboardUrl?[`export ARGUS_URL=${ps(e.dashboardUrl)}`]:[],`export ARGUS_PROVIDER=${ps(e.provider)}`,...e.model?[hs(e.model)]:[],`export ARGUS_EXEC_DIR=$BITBUCKET_CLONE_DIR/.argus-exec`,...e.prelude,e.run];return`options:
107
+ runtime:
108
+ cloud:
109
+ version: 3
110
+
111
+ pipelines:
112
+ pull-requests:
113
+ '**':
114
+ - step:
115
+ name: Argus review
116
+ image: node:22
117
+ ${e.codex?` concurrency-group: argus-codex
118
+ `:``} services: [docker]
119
+ clone:
120
+ depth: full
121
+ script:
122
+ ${ws(12,t.map(e=>`- ${fs(e)}`))}`}function Os(e){let t=[`SYSTEM_ACCESSTOKEN: $(System.AccessToken)`,`ARGUS_PROVIDER: ${fs(e.provider)}`,...e.dashboardUrl?[`ARGUS_URL: ${fs(e.dashboardUrl)}`]:[],...e.secretNames.map(e=>`${e}: $(${e})`)],n=e.model?`|\n${ws(4,[hs(e.model),e.run])}`:e.run,r=`- checkout: self
123
+ fetchDepth: 0
124
+ - task: NodeTool@0
125
+ inputs:
126
+ versionSpec: '22.x'
127
+ ${e.prelude.map(e=>`- script: ${e}`).join(`
128
+ `)}${e.prelude.length?`
129
+ `:``}- script: ${n}
130
+ env:
131
+ ${ws(4,t)}`.split(`
132
+ `);return e.codex?`trigger: none
133
+ pr:
134
+ branches:
135
+ include: ['*']
136
+
137
+ lockBehavior: sequential
138
+
139
+ variables:
140
+ - group: argus-codex-auth
141
+
142
+ pool:
143
+ vmImage: ubuntu-latest
144
+
145
+ stages:
146
+ - stage: review
147
+ jobs:
148
+ - deployment: argus
149
+ environment: argus-codex
150
+ strategy:
151
+ runOnce:
152
+ deploy:
153
+ steps:
154
+ ${ws(16,r)}`:`trigger: none
155
+ pr:
156
+ branches:
157
+ include: ['*']
158
+
159
+ pool:
160
+ vmImage: ubuntu-latest
161
+
162
+ steps:
163
+ ${ws(2,r)}`}var ks={github:`.github/workflows/argus.yml`,gitlab:`.gitlab-ci.yml`,bitbucket:`bitbucket-pipelines.yml`,azure:`azure-pipelines.yml`},As={github:Ts,gitlab:Es,bitbucket:Ds,azure:Os},js={github:`Reviews every pull request and answers @argus comments from owners, members and collaborators only (anyone can comment on a public repository).`,gitlab:`Runs in merge request pipelines. Do not mark any Argus variable Protected: protected variables do not reach merge request pipelines on unprotected branches. Merge requests from forks run in the fork without these variables; don't run fork pipelines in the parent project for untrusted contributors.`,bitbucket:`Pull requests from forks don't receive secured variables, so only same-repository branches are reviewed.`,azure:`Runs as a build validation policy on pull requests. Allow the build service to contribute to pull requests. Keep "Make secrets available to builds of forks" off.`},Ms={github:`To change the model without editing this file, set a repository variable ARGUS_MODEL (Settings > Secrets and variables > Actions > Variables).`,gitlab:`To change the model without editing this file, set a CI/CD variable ARGUS_MODEL (Settings > CI/CD > Variables): project variables take precedence over the variables in this file.`,bitbucket:`To change the model without editing this file, set a repository variable ARGUS_MODEL; the script uses the model above only when it is unset.`,azure:`To change the model without editing this file, set a pipeline variable ARGUS_MODEL (Edit > Variables) or add it to a linked variable group; the script uses the model above only when it is unset.`};function Ns(e){let t=[js[e.platform],Ms[e.platform]];return e.platform===`gitlab`&&t.push(`The job uses a Docker-in-Docker service for the sandbox (gitlab.com saas-linux runners are privileged; a self-managed runner must be too; the Docker CLI download is x86_64 only, so runners must be x86_64) and keeps Argus scratch files in the project directory because dind cannot see /tmp.`),e.platform===`bitbucket`&&t.push(`Runtime v3 is required for the sandbox: without it Bitbucket rejects the Docker flags Argus uses, so the sandbox is skipped and the AI review still runs. Runtime v3 availability depends on your plan and is not verified here.`),e.provider===`codex`&&(t.push(`Codex refuses public repositories (a login could be used from a fork), so use it on private repositories only. Runs are serialised because every run refreshes and rewrites the same login. Use one ChatGPT login per repository: run "codex login" and "argus codex-secret" again for each repository and store the value at repository (project) level, because Argus can only write the refreshed login back to this repository's own secret.`),e.platform===`github`&&t.push(`"queue: max" keeps pending runs in order instead of replacing them.`),e.platform===`bitbucket`&&t.push(`"concurrency-group" availability on the free plan is not verified.`),e.platform===`azure`&&t.push(`Serialisation needs two steps: lockBehavior: sequential is in the file, and you must add an Exclusive lock check in the UI (Pipelines > Environments > argus-codex > Approvals and checks > Add check > Exclusive lock). The variable group argus-codex-auth must hold only ARGUS_CODEX_AUTH; authorise the pipeline to use it.`),e.platform===`gitlab`&&t.push(`"resource_group" runs one job at a time. The job has allow_failure: true so a failed review never blocks a merge request; a failed write-back of the refreshed login then only shows as a warning (orange job), so check the job log when that happens.`)),e.fromSource&&t.push(`Builds Argus from ${ls} at tag v${e.version} with npm ci and runs bin/argus, for runners that cannot reach the npm registry.`),t.join(` `)}function Ps(e){let t=Ss(e.platform,e.provider),n=bs[e.platform],r=[...n?[n]:[],...t,...e.dashboardUrl===void 0?[]:[gs]];return{file:ks[e.platform],text:As[e.platform](Cs(e,[...t,...e.dashboardUrl===void 0?[]:[gs]])),secrets:r,note:Ns(e)}}function Fs(){return{file:`pre-commit hook`,note:`Reviews staged changes before every commit on your machine. Set ARGUS_FAIL_ON=major to block commits with major findings.`,text:`# inside any repository
164
+ argus hook install
165
+
166
+ # or review on demand
167
+ argus local # staged changes
168
+ argus local --working # everything uncommitted
169
+ argus local --base main`}}var Is={github:{name:`GitHub`,pipeline:`GitHub Actions`,host:`github.com`,fixedHost:!1,example:`acme/shop`},gitlab:{name:`GitLab`,pipeline:`GitLab CI`,host:`gitlab.com`,fixedHost:!1,example:`group/subgroup/project`},bitbucket:{name:`Bitbucket`,pipeline:`Bitbucket`,host:`bitbucket.org`,fixedHost:!0,example:`workspace/repo`},azure:{name:`Azure DevOps`,pipeline:`Azure Pipelines`,host:`dev.azure.com`,fixedHost:!0,example:`organization/project/_git/repo`}},Ls=e=>e in Is,Rs=new Set([`pull`,`pulls`,`pull-requests`,`tree`,`blob`,`commit`,`commits`,`issues`,`src`,`actions`]),zs=/^[^\s\p{Cc}]+$/u;function Bs(e){let t=e.trim();if(!t)return null;let n=``,r;if(/^[a-z][a-z\d+.-]*:/i.test(t)){let e;try{e=new URL(t)}catch{return null}if(e.protocol!==`https:`&&e.protocol!==`http:`)return null;n=e.hostname.toLowerCase();try{r=e.pathname.split(`/`).filter(Boolean).map(decodeURIComponent)}catch{return null}}else if(r=t.replace(/\/+$/,``).split(`/`),r.some(e=>!e))return null;let i,a,o=r.indexOf(`_git`);if(o>=0){if(i=n.endsWith(`.visualstudio.com`)&&o===1?[n.split(`.`)[0],r[0]]:r.slice(0,o),a=r[o+1],i.length!==2)return null}else if(n===`github.com`||n===`bitbucket.org`)i=r.slice(0,1),a=r[1];else{let e=r.indexOf(`-`),t=e>=0?r.slice(0,e):r;n&&t.length>2&&Rs.has(t[2])&&(t=t.slice(0,2)),i=t.slice(0,-1),a=t[t.length-1]}return a=a?.replace(/\.git$/i,``),!a||!i.length||![...i,a].every(e=>zs.test(e))?null:{owner:i.join(`/`),name:a}}function Vs(e,t){return e?{url:e,fromPage:!1}:{url:t,fromPage:!0}}function Hs(){let e=Nr(`/server`);return{...Vs(e.data?.effectivePublicUrl,window.location.origin),loading:e.loading&&!e.data}}function Us({version:e,dashboardUrl:t,initialPlatform:n=`github`,withHook:r}){let[i,a]=(0,v.useState)(n),[o,s]=(0,v.useState)(`openrouter`),[c,l]=(0,v.useState)(ss.openrouter[0]),[u,d]=(0,v.useState)(!1),f=(0,v.useMemo)(()=>{if(i!==`hook`)try{return{template:Ps({platform:i,provider:o,model:c,version:e,fromSource:u,dashboardUrl:t})}}catch(e){return{error:e.message}}},[i,o,c,e,u,t]),p=f?.template,m=p??(i===`hook`?Fs():void 0),h=e=>{s(e),l(ss[e][0])};return(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`mb-4 overflow-x-auto scrollbar-thin`,children:(0,k.jsx)(gr,{value:i,onChange:a,options:[...Object.keys(Is).map(e=>({value:e,label:Is[e].pipeline})),...r?[{value:`hook`,label:`Pre-commit`}]:[]]})}),i!==`hook`&&(0,k.jsxs)(`div`,{className:`mb-4 grid gap-3 md:grid-cols-[1fr_1fr_auto]`,children:[(0,k.jsx)(N,{label:`Provider`,children:(0,k.jsxs)(sr,{value:o,onChange:e=>h(e.target.value),children:[(0,k.jsx)(`option`,{value:`openrouter`,children:`OpenRouter (API key)`}),(0,k.jsx)(`option`,{value:`claude-code`,children:`Claude subscription (Claude Code)`}),(0,k.jsx)(`option`,{value:`copilot`,children:`GitHub Copilot`}),(0,k.jsx)(`option`,{value:`codex`,children:`ChatGPT subscription (Codex)`})]})}),(0,k.jsxs)(N,{label:`Model`,hint:`Free text; the list only holds suggestions.`,children:[(0,k.jsx)(M,{value:c,onChange:e=>l(e.target.value),list:`ci-models`,className:`font-mono`}),(0,k.jsx)(`datalist`,{id:`ci-models`,children:ss[o].map(e=>(0,k.jsx)(`option`,{value:e},e))})]}),(0,k.jsx)(N,{label:`Build Argus from source`,children:(0,k.jsx)(cr,{checked:u,onChange:d,label:`Build Argus from source`})})]}),f?.error&&(0,k.jsxs)(`p`,{className:`rounded-lg border border-critical/40 bg-critical/5 px-3 py-2 text-[13px] text-critical`,children:[f.error,`. Set the public URL of this dashboard first (Settings → Server & CI).`]}),m&&(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(`p`,{className:`mb-3 text-[13.5px] text-ink-2`,children:m.note}),p&&(0,k.jsxs)(`div`,{className:`mb-4`,children:[(0,k.jsx)(`div`,{className:`mb-1.5 text-[12px] font-medium tracking-wide text-ink-3 uppercase`,children:`Secrets to add`}),(0,k.jsx)(`ul`,{className:`space-y-1.5`,children:p.secrets.map(e=>(0,k.jsxs)(`li`,{className:`text-[13px] text-ink-2`,children:[(0,k.jsx)(`code`,{className:`font-mono text-ink`,children:e.name}),`: `,e.how]},e.name))})]}),(0,k.jsxs)(`div`,{className:`mb-1.5 flex items-center justify-between`,children:[(0,k.jsx)(`span`,{className:`font-mono text-[12px] text-ink-3`,children:m.file}),(0,k.jsx)(br,{text:m.text})]}),(0,k.jsx)(yr,{children:m.text})]})]})}function Ws({token:e}){return(0,k.jsxs)(`div`,{className:`rounded-xl border border-minor/40 bg-minor/5 px-4 py-3`,children:[(0,k.jsxs)(`div`,{className:`flex items-center justify-between gap-2`,children:[(0,k.jsx)(`span`,{className:`text-[13.5px] font-medium text-ink`,children:`Repository token`}),(0,k.jsx)(br,{text:e,label:`Copy token`})]}),(0,k.jsx)(`code`,{className:`mt-2 block font-mono text-[12.5px] break-all text-ink`,children:e}),(0,k.jsxs)(`p`,{className:`mt-2 text-[12.5px] text-ink-2`,children:[`Copy it now: you won't see it again. Add it to the repository's CI secrets as `,(0,k.jsx)(`code`,{className:`font-mono`,children:`ARGUS_TOKEN`}),`. Lost it? Regenerate it from the repository page.`]})]})}function Gs({repo:e,token:t}){let n=Hs(),r=Nr(`/status`);return(0,k.jsxs)(`div`,{className:`space-y-5`,children:[(0,k.jsx)(Ws,{token:t}),(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`mb-2 font-display text-[16px]`,children:`Pipeline`}),n.fromPage&&!n.loading&&(0,k.jsxs)(`p`,{className:`mb-3 text-[12.5px] text-ink-3`,children:[`No public URL is set, so the pipeline sends results to this page's address, `,(0,k.jsx)(`span`,{className:`font-mono`,children:n.url}),`. Set the public URL under Server & CI if your CI reaches the dashboard at another address.`]}),n.loading||r.loading&&!r.data?(0,k.jsx)(ir,{}):(0,k.jsx)(Us,{version:r.data?.version??`0.2.0`,dashboardUrl:n.url,initialPlatform:Ls(e.platform)?e.platform:`github`})]})]})}function Ks({onAdded:e}){let[t,n]=(0,v.useState)(`github`),[r,i]=(0,v.useState)(Is.github.host),[a,o]=(0,v.useState)(``),[s,c]=(0,v.useState)(!1),[l,u]=(0,v.useState)(),d=Is[t],f=Bs(a),p=e=>{n(e),i(Is[e].host)},m=async()=>{if(f){c(!0),u(void 0);try{let n=await I(`/repositories`,{method:`POST`,json:{platform:t,host:r.trim()||d.host,...f}});e(n.repository,n.token)}catch(e){u(e.message)}finally{c(!1)}}};return(0,k.jsxs)(`form`,{className:`space-y-4`,onSubmit:e=>{e.preventDefault(),m()},children:[(0,k.jsx)(`p`,{className:`text-[13.5px] text-ink-2`,children:`The review runs in the repository's own pipeline, with your model provider. Argus gives the repository a token: with it the pipeline pulls this dashboard's settings and sends each review back here.`}),(0,k.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-2`,children:[(0,k.jsx)(N,{label:`Platform`,children:(0,k.jsx)(sr,{value:t,onChange:e=>p(e.target.value),children:Object.keys(Is).map(e=>(0,k.jsx)(`option`,{value:e,children:Is[e].name},e))})}),(0,k.jsx)(N,{label:`Host`,hint:d.fixedHost?void 0:`Change for self-hosted instances.`,children:(0,k.jsx)(M,{value:r,onChange:e=>i(e.target.value),disabled:d.fixedHost,className:`font-mono`})})]}),(0,k.jsx)(N,{label:`Repository`,hint:a.trim()&&!f?`Enter owner/name or the repository URL.`:f?`Owner ${f.owner}, repository ${f.name}`:`For example ${d.example}, or the repository URL.`,children:(0,k.jsx)(M,{value:a,onChange:e=>o(e.target.value),placeholder:`${d.example} or https://${d.host}/…`,className:`font-mono`})}),l&&(0,k.jsx)(`p`,{className:`rounded-lg border border-critical/40 bg-critical/5 px-3 py-2 text-[13px] text-critical`,children:l}),(0,k.jsx)(`div`,{className:`flex justify-end`,children:(0,k.jsx)(j,{type:`submit`,variant:`primary`,loading:s,disabled:!f,children:`Add repository`})})]})}function qs({repo:e,onChange:t}){let n=Nr(`/repositories/${e.id}/token`),[r,i]=(0,v.useState)(),[a,o]=(0,v.useState)(),s=zr(`admin`),c=Cr(),l=`${e.owner}/${e.name}`,u=n.data??void 0,d=async(e,t)=>{o(e);try{await t()}catch(e){c(`bad`,e.message)}finally{o(void 0)}},f=()=>d(`token`,async()=>{if(u&&!window.confirm(`Regenerate the token for ${l}? The current token stops working right away; update ARGUS_TOKEN in CI with the new one.`))return;let t=await I(`/repositories/${e.id}/token`,{method:`POST`});i(t.token),n.setData({prefix:t.prefix,createdAt:t.createdAt,lastUsedAt:null})}),p=()=>d(`revoke`,async()=>{window.confirm(`Revoke the token for ${l}? CI runs can no longer pull settings or send reviews until you create a new token.`)&&(await I(`/repositories/${e.id}/token`,{method:`DELETE`}),i(void 0),n.setData(null),c(`ok`,`Token revoked`))}),m=n=>d(`summary`,async()=>{let r=await I(`/repositories/${e.id}`,{method:`PUT`,json:{summaryOnly:n}});t({...e,summaryOnly:r.repository.summaryOnly})});return(0,k.jsxs)(P,{eyebrow:`Reviewed in CI`,title:`CI connection`,actions:s&&(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(j,{size:`sm`,loading:a===`token`,onClick:()=>void f(),children:u?`Regenerate token`:`Create token`}),u&&(0,k.jsx)(j,{size:`sm`,variant:`danger`,loading:a===`revoke`,onClick:()=>void p(),children:`Revoke`})]}),children:[n.loading&&!n.data&&n.data!==null?(0,k.jsx)(ir,{}):n.error?(0,k.jsx)(`p`,{className:`text-[13px] text-critical`,children:n.error}):u?(0,k.jsxs)(`dl`,{className:`grid gap-x-8 gap-y-2 text-[13px] md:grid-cols-3`,children:[(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`dt`,{className:`eyebrow`,children:`Token`}),(0,k.jsxs)(`dd`,{className:`mt-1 font-mono text-ink`,children:[`argus_`,u.prefix,`…`]})]}),(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`dt`,{className:`eyebrow`,children:`Created`}),(0,k.jsx)(`dd`,{className:`mt-1 text-ink-2`,children:wr(u.createdAt)})]}),(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`dt`,{className:`eyebrow`,children:`Last used`}),(0,k.jsx)(`dd`,{className:`mt-1 text-ink-2`,children:u.lastUsedAt?wr(u.lastUsedAt):`Never`})]})]}):(0,k.jsxs)(`p`,{className:`text-[13.5px] text-ink-2`,children:[(0,k.jsx)(F,{tone:`warn`,children:`No active token`}),` CI runs of this repository cannot pull settings or send reviews until `,s?`you create`:`an admin creates`,` a token.`]}),r&&(0,k.jsx)(`div`,{className:`mt-5 border-t border-line pt-5`,children:(0,k.jsx)(Gs,{repo:e,token:r})}),(0,k.jsx)(`div`,{className:`mt-4 border-t border-line`,children:(0,k.jsx)(lr,{label:`Send summary only`,hint:(0,k.jsxs)(k.Fragment,{children:[`CI sends this dashboard only the outline of each review: counts, titles and locations of findings, timings and usage. Explanations, suggested fixes, code and the summary text stay on the pull request. Results stored before you turn this on stay as they were stored.`,!s&&` Only admins can change this.`]}),checked:e.summaryOnly,disabled:!s||a===`summary`,onChange:e=>void m(e)})})]})}var Js=[{value:`quiet`,title:`Quiet`,text:`Only critical and major defects. Silent otherwise.`},{value:`chill`,title:`Chill`,text:`Real defects of every severity, no nitpicks or style.`},{value:`assertive`,title:`Assertive`,text:`Everything a strict senior reviewer would say, including nitpicks.`}],Ys={bug:`Logic errors, wrong conditions, off-by-one, code vs comment mismatch`,security:`Injection, XSS, SSRF, authz, secrets, unsafe crypto`,performance:`N+1, quadratic loops, blocking I/O, memory growth`,concurrency:`Races, missing await, unhandled promises`,"error-handling":`Swallowed errors, missing null checks, cleanup`,"data-integrity":`Validation, rounding, money, time zones, units`,"api-contract":`Breaking signature or schema changes across files`,maintainability:`Duplication that will drift, hidden coupling`,readability:`Confusing flow likely to cause misuse`,testing:`Tests that cannot fail or test the wrong thing`,documentation:`Docs and comments made wrong by the change`,style:`Formatting and idiom (assertive profile only)`};function Xs(){let e=Yr(),t=e.get(`review.profile`),n=e.get(`review.categories`)??[],r=e.meta.severities;return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(P,{eyebrow:`Tone`,title:`Review profile`,children:[(0,k.jsx)(`div`,{className:`mb-2 flex items-center`,children:(0,k.jsx)(si,{path:`review.profile`})}),(0,k.jsx)(`div`,{className:`grid gap-3 md:grid-cols-3`,children:Js.map(n=>(0,k.jsxs)(`button`,{type:`button`,onClick:()=>e.set(`review.profile`,n.value),className:A(`rounded-xl border p-4 text-left transition-all`,t===n.value?`border-iris bg-iris-soft shadow-[0_0_0_3px_color-mix(in_oklab,var(--iris)_18%,transparent)]`:`border-line-strong hover:border-ink-3`),children:[(0,k.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,k.jsx)(`span`,{className:`font-display text-[17px] font-medium`,children:n.title}),(0,k.jsx)(`span`,{className:A(`h-3.5 w-3.5 rounded-full border-2`,t===n.value?`border-iris bg-iris`:`border-line-strong`)})]}),(0,k.jsx)(`p`,{className:`mt-1.5 text-[12.5px] leading-snug text-ink-2`,children:n.text})]},n.value))})]}),(0,k.jsx)(P,{eyebrow:`Precision`,title:`What gets reported`,children:(0,k.jsxs)(`div`,{className:`grid gap-5 md:grid-cols-2`,children:[(0,k.jsx)(ui,{path:`review.minSeverity`,label:`Severity floor`,hint:`Findings below this severity are dropped. Profiles can raise it further (quiet ⇒ major).`,options:r.map(e=>({value:e,label:e[0].toUpperCase()+e.slice(1)}))}),(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[`Confidence threshold: `,(0,k.jsxs)(`span`,{className:`font-mono`,children:[Math.round((e.get(`review.minConfidence`)??.6)*10),`/10`]}),(0,k.jsx)(si,{path:`review.minConfidence`})]}),hint:`Verified score a finding needs to be posted. Higher means fewer, surer comments.`,children:(0,k.jsx)(`input`,{type:`range`,min:1,max:10,value:Math.round((e.get(`review.minConfidence`)??.6)*10),onChange:t=>e.set(`review.minConfidence`,Number(t.target.value)/10),className:`w-full max-w-sm accent-[var(--iris)]`})}),(0,k.jsx)(li,{path:`review.maxComments`,label:`Max inline comments per review`,min:1,max:200,hint:`Extra findings go into the summary.`}),(0,k.jsx)(fi,{path:`review.language`,label:`Review language`,hint:`Language for comments, e.g. English, German, Macedonian.`})]})}),(0,k.jsx)(P,{eyebrow:`Focus`,title:`Categories`,actions:(0,k.jsx)(si,{path:`review.categories`}),children:(0,k.jsx)(`div`,{className:`grid gap-2 sm:grid-cols-2`,children:e.meta.categories.map(t=>{let r=n.includes(t);return(0,k.jsxs)(`button`,{type:`button`,onClick:()=>e.set(`review.categories`,r?n.filter(e=>e!==t):[...n,t]),className:A(`flex items-start gap-3 rounded-xl border px-3.5 py-2.5 text-left transition-colors`,r?`border-iris/50 bg-iris-soft/60`:`border-line hover:border-line-strong`),children:[(0,k.jsx)(`span`,{className:A(`mt-0.5 flex h-4 w-4 shrink-0 items-center justify-center rounded border text-[10px]`,r?`border-iris bg-iris text-iris-ink`:`border-line-strong`),children:r?`✓`:``}),(0,k.jsxs)(`span`,{children:[(0,k.jsx)(`span`,{className:`font-mono text-[12.5px] text-ink`,children:t}),(0,k.jsx)(`span`,{className:`block text-[12px] text-ink-3`,children:Ys[t]})]})]},t)})})}),(0,k.jsx)(P,{eyebrow:`Pipeline`,title:`Quality passes`,children:(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`review.verifyFindings`,label:`Verify every finding`,hint:`A second model pass re-derives each finding from the code and discards speculation. Biggest precision gain; costs one extra call per batch.`}),(0,k.jsx)(L,{path:`review.crossFileAnalysis`,label:`Cross-file analysis`,hint:`Looks at all changed files together for broken contracts, missed callers and inconsistent changes.`}),(0,k.jsx)(L,{path:`review.secretScan`,label:`Secret scanning`,hint:`Deterministic detection of keys, tokens and passwords in added lines.`}),(0,k.jsx)(L,{path:`review.incremental`,label:`Incremental re-reviews`,hint:`On new pushes, review only what changed since the last reviewed commit.`}),(0,k.jsx)(L,{path:`review.adaptive`,label:`Learn from developer reactions`,hint:`Categories the team keeps dismissing (👎, “false positive”, “intended”) need more confidence in that repository; categories that are almost always fixed get a little more room. Kicks in after 8 decided comments per category.`}),(0,k.jsx)(L,{path:`review.cache.enabled`,label:`Reuse identical model answers`,hint:`Requests with exactly the same prompt (same code, context and settings) are answered from a local cache for a week: re-running a review on an unchanged commit is instant and free.`}),(0,k.jsx)(L,{path:`review.autoResolve`,label:`Resolve threads when the issue is fixed`,hint:`On each new push, findings whose code changed are re-checked; fixed ones get a “✅ Fixed in abc123” reply and their thread is resolved.`})]})}),(0,k.jsxs)(P,{eyebrow:`Merge gate`,title:`Commit status`,children:[(0,k.jsx)(pi,{children:(0,k.jsx)(L,{path:`review.status.enabled`,label:`Report an argus commit status`,hint:`Pending while the review runs, then failure, error (the review did not complete) or success. Require the argus check in branch protection to block merges until it passes.`})}),(0,k.jsx)(`div`,{className:A(`mt-4 grid gap-5 md:grid-cols-2`,!e.get(`review.status.enabled`)&&`pointer-events-none opacity-50`),children:(0,k.jsx)(ui,{path:`review.status.failOn`,label:`Fail when a finding is at least`,options:[{value:`critical`,label:`Critical`},{value:`major`,label:`Major`},{value:`minor`,label:`Minor`}]})})]}),(0,k.jsxs)(P,{eyebrow:`Output`,title:`Comments and approval`,children:[(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`review.suggestions`,label:`Committable suggestions`,hint:`Include one-click fix suggestions (GitHub and GitLab; shown as code on Bitbucket).`}),(0,k.jsx)(L,{path:`review.agentPrompts`,label:`Prompt for AI agents`,hint:`Add a collapsible prompt to each comment for Claude Code, Codex or Cursor.`}),(0,k.jsx)(L,{path:`review.approveWhenClean`,label:`Approve when no issues are found`})]}),(0,k.jsx)(`div`,{className:`mt-4 grid gap-5 md:grid-cols-2`,children:(0,k.jsx)(ui,{path:`review.requestChangesOn`,label:`Request changes when a finding is at least`,options:[{value:`never`,label:`Never (comment only)`},{value:`critical`,label:`Critical`},{value:`major`,label:`Major`}]})})]}),(0,k.jsx)(P,{eyebrow:`Limits`,title:`Size and throughput`,children:(0,k.jsxs)(`div`,{className:`grid gap-5 md:grid-cols-3`,children:[(0,k.jsx)(li,{path:`review.maxFiles`,label:`Max files per review`,min:1}),(0,k.jsx)(li,{path:`review.maxPatchLines`,label:`Max changed lines`,min:100,hint:`Larger PRs are reviewed up to this budget.`}),(0,k.jsx)(li,{path:`review.concurrency`,label:`Parallel model calls`,min:1,max:16})]})})]})}function Zs(){return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsx)(P,{eyebrow:`Walkthrough`,title:`Summary comment`,children:(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`summary.enabled`,label:`Generate a summary`,hint:`One persistent comment on the PR, edited in place on every review.`}),(0,k.jsx)(L,{path:`summary.walkthrough`,label:`Walkthrough paragraph`}),(0,k.jsx)(L,{path:`summary.changesTable`,label:`Changed files table`}),(0,k.jsx)(L,{path:`summary.sequenceDiagram`,label:`Sequence diagram`,hint:`Mermaid diagram of the main runtime flow (GitHub and GitLab render it).`}),(0,k.jsx)(L,{path:`summary.effortEstimate`,label:`Review effort estimate`}),(0,k.jsx)(L,{path:`summary.collapseWalkthrough`,label:`Collapse the walkthrough`})]})}),(0,k.jsxs)(P,{eyebrow:`Pull request`,title:`Description and labels`,children:[(0,k.jsx)(`div`,{className:`grid gap-5 md:grid-cols-2`,children:(0,k.jsx)(ui,{path:`summary.updateDescription`,label:`Write the PR description`,options:[{value:`never`,label:`Never`},{value:`when-empty`,label:`Only when the description is empty`},{value:`append`,label:`Append a summary section`}]})}),(0,k.jsx)(pi,{children:(0,k.jsx)(L,{path:`summary.applyLabels`,label:`Apply suggested labels`,hint:`Adds up to 4 labels such as bug, feature or security (GitHub and GitLab).`})})]}),(0,k.jsx)(P,{eyebrow:`Intent`,title:`Linked issues`,children:(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`tickets.enabled`,label:`Read linked issues`,hint:`Finds #123, owner/repo#123, issue URLs and Jira or Linear keys (PROJ-42) in the title, branch, description and commits, and gives the reviewer the issue text so the code is held to it. Jira and Linear need credentials under Server & CI.`}),(0,k.jsx)(L,{path:`tickets.checkRequirements`,label:`Check requirement coverage`,hint:`Extracts the acceptance criteria from each issue and marks every one as met, partial, missing or unclear in the summary comment.`}),(0,k.jsx)(di,{path:`tickets.allowedRepos`,label:`Other repositories`,hint:`Issues of the pull request's own owner are always read. Add owner/name (globs allowed) for other repositories Argus may read issues from.`,placeholder:`acme/*, partner/api`}),(0,k.jsx)(di,{path:`tickets.projectKeys`,label:`Jira and Linear projects`,hint:`Only tickets from these project keys are read. Empty means Jira and Linear tickets are never fetched.`,placeholder:`PAY, ENG`})]})})]})}function Qs(){let e=Yr().get(`chat.mention`);return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(P,{eyebrow:`Triggers`,title:`Automatic reviews`,children:[(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`autoReview.enabled`,label:`Review pull requests automatically`,hint:`On open, reopen, ready-for-review and every new push.`}),(0,k.jsx)(L,{path:`autoReview.drafts`,label:`Review draft pull requests`})]}),(0,k.jsxs)(`div`,{className:`mt-4 grid gap-5 md:grid-cols-2`,children:[(0,k.jsx)(di,{path:`autoReview.baseBranches`,label:`Only target branches`,hint:`Glob or /regex/. Empty means all branches.`,placeholder:`main, release/*`}),(0,k.jsx)(di,{path:`autoReview.labels`,label:`Only with labels`,hint:`Empty means no label is required.`,mono:!1,placeholder:`ai-review`}),(0,k.jsx)(di,{path:`autoReview.ignoreTitleKeywords`,label:`Skip titles containing`,mono:!1}),(0,k.jsx)(di,{path:`autoReview.ignoreAuthors`,label:`Skip authors`,placeholder:`dependabot[bot]`})]})]}),(0,k.jsxs)(P,{eyebrow:`Conversation`,title:`Chat and commands`,children:[(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`chat.enabled`,label:`Reply to mentions and review threads`}),(0,k.jsx)(L,{path:`chat.learnFromFeedback`,label:`Learn from feedback`,hint:`When someone corrects Argus, store the lesson as a learning for future reviews.`})]}),(0,k.jsx)(`div`,{className:`mt-4 grid gap-5 md:grid-cols-2`,children:(0,k.jsx)(fi,{path:`chat.mention`,label:`Mention`,mono:!0,hint:`Commands: ${e} review · full review · review focus <topic> · pause · resume · resolve · remember <rule> · help`})})]})]})}function $s(){let e=Yr();return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(P,{eyebrow:`Scope`,title:`Path filters`,children:[(0,k.jsxs)(`div`,{className:`grid gap-5`,children:[(0,k.jsx)(di,{path:`files.include`,label:`Only review`,hint:`Glob patterns. Empty means everything. A leading ! excludes.`,placeholder:`src/**, !src/generated/**`}),(0,k.jsx)(di,{path:`files.exclude`,label:`Never review`,placeholder:`**/*.test.ts, docs/**`})]}),(0,k.jsx)(pi,{children:(0,k.jsx)(L,{path:`files.useDefaultExcludes`,label:`Skip lock files, build output, minified, vendored and binary files`})})]}),(0,k.jsxs)(P,{eyebrow:`Context`,title:`What the reviewer can see`,children:[(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[`Context depth`,(0,k.jsx)(si,{path:`files.contextDepth`})]}),hint:`Related context adds imported files and other usages of changed symbols, which is how cross-file bugs are caught.`,children:(0,k.jsx)(`div`,{className:`grid gap-2 md:grid-cols-3`,children:[[`diff`,`Diff only`,`Fastest and cheapest`],[`files`,`Full files`,`Whole changed files`],[`related`,`Related code`,`Files + imports + usages`]].map(([t,n,r])=>(0,k.jsxs)(`button`,{type:`button`,onClick:()=>e.set(`files.contextDepth`,t),className:A(`rounded-xl border px-4 py-3 text-left`,e.get(`files.contextDepth`)===t?`border-iris bg-iris-soft`:`border-line-strong hover:border-ink-3`),children:[(0,k.jsx)(`div`,{className:`font-medium`,children:n}),(0,k.jsx)(`div`,{className:`text-[12.5px] text-ink-3`,children:r})]},t))})}),(0,k.jsx)(`div`,{className:`mt-2`,children:(0,k.jsx)(L,{path:`files.codeGraph`,label:`Syntax-tree code graph`,hint:`Parses TypeScript, JavaScript, Python, Go, Java, Rust, Ruby, PHP, C# and C++ with tree-sitter to find real callers (with the function they sit in), definitions, implementations and the transitive impact of a change. Feeds related context, the reviewer's tools and risk scoring. Other languages fall back to text search.`})}),(0,k.jsx)(`div`,{className:`mt-3 grid gap-5 md:grid-cols-2`,children:(0,k.jsx)(li,{path:`files.maxContextChars`,label:`Context budget (characters)`,min:2e4,step:1e4})})]}),(0,k.jsx)(P,{eyebrow:`Conventions`,title:`Guideline files`,children:(0,k.jsx)(di,{path:`files.guidelineFiles`,label:`Read these files from the repository`,hint:`Nested files apply only to their directory, e.g. services/billing/CLAUDE.md covers services/billing/**.`})})]})}var ec={types:`types`,lint:`lint`,security:`security`,secret:`secrets`,dependency:`dependencies`};function tc(){let e=Yr(),t=e.get(`review.agent.enabled`),n=e.get(`review.voting.enabled`),r=e.get(`review.voting.passes`)??3,i=e.get(`analyzers.enabled`),a=e.get(`review.verifyFindings`),o=n&&e.get(`review.voting.doubleCheckCritical`),s=[{label:`Analyze`,detail:`linters · scanners`,on:!!i},{label:`Route`,detail:`light · standard · deep`,on:!!e.get(`review.routing.enabled`)},{label:`Review`,detail:n?`${r} lenses on risky files`:`one pass`,on:!0},{label:`Explore`,detail:`read · grep · references`,on:!!t},{label:`Verify`,detail:`every finding`,on:!!a},{label:`Second check`,detail:`critical findings`,on:!!(o&&a)},{label:`Prove`,detail:`tests reproduce bugs`,on:!!(e.get(`execution.enabled`)&&e.get(`execution.proveFindings`))}];return(0,k.jsx)(`div`,{className:`flex flex-wrap items-stretch gap-2`,children:s.map((e,t)=>(0,k.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,k.jsxs)(`div`,{className:A(`rounded-xl border px-3.5 py-2 transition-colors`,e.on?`border-iris/45 bg-iris-soft/60`:`border-dashed border-line-strong opacity-55`),children:[(0,k.jsx)(`div`,{className:A(`font-display text-[14.5px] leading-tight`,e.on?`text-ink`:`text-ink-3 line-through decoration-ink-3/50`),children:e.label}),(0,k.jsx)(`div`,{className:`font-mono text-[10.5px] tracking-wide text-ink-3`,children:e.detail})]}),t<s.length-1&&(0,k.jsx)(`span`,{className:`font-mono text-ink-3`,children:`→`})]},e.label))})}function nc(){let e=Yr(),t=Nr(`/analyzers`),n=e.get(`analyzers.disabled`)??[],r=e.get(`analyzers.enabled`);return t.error?(0,k.jsx)(`p`,{className:`text-[13px] text-critical`,children:t.error}):t.data?(0,k.jsx)(`div`,{className:A(`divide-y divide-line`,!r&&`pointer-events-none opacity-50`),children:t.data.analyzers.map(t=>{let r=!n.includes(t.name);return(0,k.jsxs)(`div`,{className:`flex items-start gap-4 py-3`,children:[(0,k.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,k.jsxs)(`div`,{className:`flex flex-wrap items-center gap-2`,children:[(0,k.jsx)(`span`,{className:`text-[13.5px] font-medium text-ink`,children:t.label}),(0,k.jsx)(F,{children:ec[t.kind]}),t.installed===!0&&(0,k.jsx)(F,{tone:`ok`,children:`installed`}),t.installed===!1&&(0,k.jsx)(F,{tone:`warn`,children:`not installed`}),t.installed===null&&(0,k.jsx)(F,{tone:`iris`,children:`uses repo dependencies`})]}),(0,k.jsx)(`p`,{className:`mt-0.5 text-[12.5px] leading-snug text-ink-3`,children:t.description}),t.installed!==!0&&(0,k.jsx)(`p`,{className:`mt-0.5 text-[12px] leading-snug text-ink-3/80 italic`,children:t.note})]}),(0,k.jsx)(cr,{checked:r,label:`Run ${t.label}`,onChange:r=>e.set(`analyzers.disabled`,r?n.filter(e=>e!==t.name):[...n,t.name])})]},t.name)})}):(0,k.jsxs)(`div`,{className:`flex items-center gap-2 py-3 text-[13px] text-ink-3`,children:[(0,k.jsx)(ir,{size:13}),` Checking which tools are installed…`]})}function rc(){let e=Yr(),t=Nr(`/execution`),n=e.get(`execution.enabled`),r=e.get(`execution.sandbox`)??`auto`,i=e.meta.severities;return(0,k.jsxs)(P,{eyebrow:`Proof`,title:`Run the tests and prove findings`,actions:t.data?t.data.docker?(0,k.jsx)(F,{tone:`ok`,children:`Docker ready`}):(0,k.jsx)(F,{tone:`warn`,children:`Docker not found`}):(0,k.jsx)(ir,{size:13}),children:[e.isLocked(`execution.sandbox`)&&(0,k.jsxs)(`p`,{className:`mb-3 rounded-lg border border-line px-3 py-2 text-[12.5px] text-ink-3`,children:[`Settings marked `,(0,k.jsx)(`span`,{className:`font-mono text-[10px] uppercase`,children:`admin only`}),` decide what code runs and where. `,e.lockNote,`.`]}),(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`execution.enabled`,label:`Install dependencies and run code`,hint:`A private copy of the pull request is installed in a container (vitest, jest, npm test, pytest or go test are detected). Installs get network access; tests run with networking disabled, CPU and memory limits, and no access to your files. tsc and ESLint also run against the installed copy.`}),(0,k.jsx)(L,{path:`execution.runTests`,label:`Run the test suite`,hint:`Failing tests are re-run against the base branch: ones that passed before are reported as regressions caused by this change, ones that already failed are ignored.`}),(0,k.jsx)(L,{path:`execution.proveFindings`,label:`Write a test for each serious finding`,hint:`The model writes a focused test that should fail because of the bug. If it fails, and passes once the suggested fix is applied, the finding is marked as reproduced and shown with the test. If it passes, the finding loses confidence.`})]}),(0,k.jsxs)(`div`,{className:A(`mt-4 grid gap-5 md:grid-cols-3`,!n&&`pointer-events-none opacity-50`),children:[(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[`Where code runs`,(0,k.jsx)(si,{path:`execution.sandbox`}),(0,k.jsx)(ci,{path:`execution.sandbox`})]}),hint:r===`host`?`Runs directly on this machine. Only for your own repositories.`:`Docker isolates untrusted pull requests.`,children:(0,k.jsx)(`div`,{className:A(e.isLocked(`execution.sandbox`)&&`pointer-events-none opacity-60`),children:(0,k.jsx)(gr,{value:r,options:[{value:`auto`,label:`Auto`,hint:`Use Docker when available, otherwise skip`},{value:`docker`,label:`Docker`,hint:`Always in Docker; skipped when Docker is unavailable`},{value:`host`,label:`This machine`,hint:`No isolation; for trusted code only`}],onChange:t=>e.set(`execution.sandbox`,t)})})}),(0,k.jsx)(ui,{path:`execution.isolation`,label:`Isolation`,hint:`Strict drops every Linux capability and makes the container filesystem read-only while tests run.`,options:[{value:`strict`,label:`Strict (recommended)`},{value:`standard`,label:`Standard`}]}),(0,k.jsx)(ui,{path:`execution.runtime`,label:`Container runtime`,hint:`gVisor (runsc) or Kata Containers add a kernel boundary for untrusted pull requests; auto uses them when Docker has them.`,options:[{value:`auto`,label:`Auto (gVisor or Kata when installed)`},{value:`runsc`,label:`gVisor (runsc)`},{value:`kata`,label:`Kata Containers`},{value:`runc`,label:`Default (runc)`}]}),(0,k.jsx)(li,{path:`execution.maxProofs`,label:`Findings to prove per review`,min:0,max:20}),(0,k.jsx)(ui,{path:`execution.proofMinSeverity`,label:`Prove findings of at least`,options:i.map(e=>({value:e,label:e[0].toUpperCase()+e.slice(1)}))}),(0,k.jsx)(fi,{path:`execution.installCommand`,label:`Install command`,placeholder:`Detected automatically`,mono:!0}),(0,k.jsx)(fi,{path:`execution.testCommand`,label:`Test command`,placeholder:`Detected automatically`,mono:!0}),(0,k.jsx)(fi,{path:`execution.image`,label:`Container image`,placeholder:`node:22-bookworm, python:3.12-bookworm…`,mono:!0}),(0,k.jsx)(li,{path:`execution.timeoutSec`,label:`Install timeout (s)`,min:30,max:3600}),(0,k.jsx)(li,{path:`execution.testTimeoutSec`,label:`Test-suite timeout (s)`,min:30,max:3600,hint:`Tests run without network; ones that need it fail or time out and are ignored unless they passed on the base branch.`}),(0,k.jsx)(li,{path:`execution.proofTimeoutSec`,label:`Timeout per proof test (s)`,min:10,max:1800})]})]})}function ic(){let e=Yr(),t=e.get(`review.agent.enabled`),n=e.get(`review.voting.enabled`),r=String(e.get(`review.voting.passes`)??3),i=e.get(`review.voting.scope`)??`risky`;return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(P,{eyebrow:`Pipeline`,title:`How deep each review goes`,children:[(0,k.jsx)(tc,{}),(0,k.jsx)(`p`,{className:`mt-3 text-[12.5px] leading-snug text-ink-3`,children:`Every stage trades time and tokens for precision. Disabled stages are skipped; the rest run in this order for each pull request.`})]}),(0,k.jsxs)(P,{eyebrow:`Exploration`,title:`Agentic codebase exploration`,children:[(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`review.agent.enabled`,label:`Let the reviewer explore the repository`,hint:`The model can read files, search the code, look up definitions, callers, implementations and the transitive impact of a change, and check history before it reports anything. API models use Argus tools; Claude Code and Codex explore a read-only checkout with their own tools.`}),(0,k.jsx)(L,{path:`review.agent.verify`,label:`Explore during verification`,hint:`The verifier checks each finding against the code it points at: guards elsewhere, broken callers, existing validation. The biggest single cut in false positives.`})]}),(0,k.jsx)(`div`,{className:A(`mt-4 grid gap-5 md:grid-cols-2`,!t&&`pointer-events-none opacity-50`),children:(0,k.jsx)(li,{path:`review.agent.maxSteps`,label:`Tool rounds per call`,min:1,max:40,hint:`Upper bound on exploration per review batch. 6–10 covers most pull requests.`})})]}),(0,k.jsxs)(P,{eyebrow:`Consensus`,title:`Multi-pass voting`,children:[(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`review.voting.enabled`,label:`Review high-risk files several times`,hint:`Auth, payments, migrations, security-sensitive and large changes get extra independent passes, each with a different lens (adversarial, edge cases, contracts). Findings are clustered across passes; the ones most passes agree on gain confidence, lone findings need a stronger verification score.`}),(0,k.jsx)(L,{path:`review.voting.doubleCheckCritical`,label:`Second, independent check for critical findings`,hint:`A skeptical verifier must also confirm every critical finding before it is posted, so a false critical never blocks a merge.`})]}),(0,k.jsxs)(`div`,{className:A(`mt-4 grid gap-5 md:grid-cols-3`,!n&&`pointer-events-none opacity-50`),children:[(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[`Passes per high-risk file`,(0,k.jsx)(si,{path:`review.voting.passes`})]}),children:(0,k.jsx)(gr,{value:r,options:[`2`,`3`,`4`,`5`].map(e=>({value:e,label:e})),onChange:t=>e.set(`review.voting.passes`,Number(t))})}),(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[`Which files`,(0,k.jsx)(si,{path:`review.voting.scope`})]}),children:(0,k.jsx)(gr,{value:i,options:[{value:`risky`,label:`High-risk`,hint:`Files scored as risky by path, change size, summary and analyzers`},{value:`all`,label:`All files`,hint:`Every reviewed file except tests and docs; costs more`}],onChange:t=>e.set(`review.voting.scope`,t)})}),i===`risky`&&(0,k.jsx)(li,{path:`review.voting.maxFiles`,label:`Max high-risk files`,min:1,max:50})]})]}),(0,k.jsx)(rc,{}),(0,k.jsxs)(P,{eyebrow:`Cost`,title:`Model routing and spending`,children:[(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`review.routing.enabled`,label:`Route files by risk`,hint:`Formatting- and comment-only changes get a light review without exploration; high-risk files go to the high-risk model and get voting. Set the light and high-risk models under Models & providers.`}),(0,k.jsx)(L,{path:`review.routing.triage`,label:`Triage small changes with the light model`,hint:`A cheap model decides which small files have no behavioural impact (copy text, version bumps). Only runs when a light model is set. When unsure it keeps the full review.`})]}),(0,k.jsx)(`div`,{className:A(`mt-4 grid gap-5 md:grid-cols-2`,!e.get(`review.routing.enabled`)&&`pointer-events-none opacity-50`),children:(0,k.jsx)(li,{path:`review.routing.maxTrivialLines`,label:`Largest change triage may call trivial`,min:1,max:500,hint:`Changed lines. Bigger files always get the full review.`})}),(0,k.jsxs)(`div`,{className:`mt-4 grid gap-5 md:grid-cols-2`,children:[(0,k.jsx)(N,{label:(0,k.jsxs)(k.Fragment,{children:[`Spending limit per review (USD)`,(0,k.jsx)(si,{path:`review.maxCostUsd`}),(0,k.jsx)(ci,{path:`review.maxCostUsd`})]}),hint:`Stops calling paid APIs once a single review reaches this amount (default $5). Subscriptions (Claude Code, Codex, Copilot) report no cost and are not limited.`,children:(0,k.jsx)(`input`,{type:`number`,min:.01,step:.05,value:e.get(`review.maxCostUsd`)??``,disabled:e.isLocked(`review.maxCostUsd`),placeholder:`5`,onChange:t=>e.set(`review.maxCostUsd`,t.target.value===``?void 0:Math.max(.01,Number(t.target.value))),className:`h-9 w-full max-w-48 rounded-lg border border-line-strong bg-panel-2 px-3 font-mono text-[13px] text-ink outline-none focus:border-iris`})}),(0,k.jsx)(li,{path:`review.timeoutMinutes`,label:`Time limit per review (minutes)`,min:1,max:240,hint:`A review still running after this is stopped and its commit status set to error.`})]})]}),(0,k.jsxs)(P,{eyebrow:`Evidence`,title:`Linters and security scanners`,children:[(0,k.jsxs)(pi,{children:[(0,k.jsx)(L,{path:`analyzers.enabled`,label:`Run static analysis on changed files`,hint:`Results on changed lines are handed to the model as evidence to confirm, explain or dismiss, never posted raw. Type errors elsewhere that mention a changed symbol are included, so broken callers surface.`}),(0,k.jsx)(L,{path:`analyzers.promoteSecurity`,label:`Post leaked secrets and vulnerable dependencies directly`,hint:`Gitleaks matches and high-severity OSV advisories on added lines become findings without waiting for the model.`})]}),(0,k.jsx)(`div`,{className:`mt-2`,children:(0,k.jsx)(nc,{})}),(0,k.jsxs)(`div`,{className:A(`mt-4 grid gap-5 md:grid-cols-2`,!e.get(`analyzers.enabled`)&&`pointer-events-none opacity-50`),children:[(0,k.jsx)(di,{path:`analyzers.semgrepConfig`,label:`Semgrep rulesets`,placeholder:`p/default`,hint:`Registry packs (p/owasp-top-ten, p/typescript) or paths to rule files in the repository.`}),(0,k.jsx)(li,{path:`analyzers.timeoutSec`,label:`Timeout per tool (seconds)`,min:10,max:1800})]})]})]})}var ac=[`review`,`depth`,`summary`,`triggers`,`files`,`rules`,`guidelines`];function oc(){let{id:e}=At(),t=Number(e),[n,r]=(0,v.useState)(),[i,a]=(0,v.useState)(),[o,s]=(0,v.useState)(),[c,l]=(0,v.useState)(),[u,d]=(0,v.useState)(`overview`),f=Cr(),p=(0,v.useCallback)(async()=>{try{let[e,n,i]=await Promise.all([I(`/repositories`),I(`/meta`),I(`/config`)]),o=e.repositories.find(e=>e.id===t);if(!o)throw Error(`Repository not found`);r(o),a(n),s(i.config)}catch(e){l(e.message)}},[t]);(0,v.useEffect)(()=>{p()},[p]);let m=(0,v.useMemo)(()=>i&&o?Kr(i.defaults,o):void 0,[i,o]),h=(0,v.useCallback)(async e=>{let n=await I(`/repositories/${t}`,{method:`PUT`,json:{config:e}});r(e=>e&&{...e,config:n.repository.config}),n.ignoredKeys?.length&&f(`info`,`Not saved, only an admin can set: ${n.ignoredKeys.join(`, `)}`)},[t,f]);if(c)return(0,k.jsx)(`div`,{className:`rounded-xl border border-critical/40 p-6 text-critical`,children:c});if(!n||!i||!m)return(0,k.jsxs)(`div`,{className:`flex items-center gap-3 p-10 text-ink-3`,children:[(0,k.jsx)(ir,{}),` Loading repository…`]});let g=Object.keys(n.config??{}).length;return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:(0,k.jsxs)(`span`,{className:`flex items-center gap-2`,children:[(0,k.jsx)(Vn,{to:`/repositories`,className:`hover:text-ink`,children:`Repositories`}),`/ `,n.integrationId===null?`Reviewed in CI`:n.integrationName]}),title:(0,k.jsxs)(`span`,{className:`flex items-center gap-3`,children:[(0,k.jsx)(Tr,{platform:n.platform,size:26}),(0,k.jsxs)(`span`,{className:`font-mono text-[28px]`,children:[n.owner,`/`,(0,k.jsx)(`b`,{children:n.name})]})]}),description:g?`${g} setting group${g>1?`s`:``} override the global configuration.`:`Inherits every global setting. Override anything below for this repository only.`,actions:(0,k.jsxs)(`label`,{className:`flex items-center gap-2.5 rounded-xl border border-line-strong bg-panel px-3.5 py-2 text-[13px]`,children:[(0,k.jsx)(cr,{checked:n.enabled,label:`Reviews enabled`,onChange:async e=>{try{await I(`/repositories/${n.id}`,{method:`PUT`,json:{enabled:e}}),r({...n,enabled:e})}catch(e){f(`bad`,e.message)}}}),n.enabled?`Reviews on`:`Reviews off`]})}),(0,k.jsx)(`div`,{className:`mb-6 overflow-x-auto scrollbar-thin`,children:(0,k.jsx)(gr,{value:u,onChange:d,options:[{value:`overview`,label:`Overview`},{value:`review`,label:`Review`},{value:`depth`,label:`Depth`},{value:`summary`,label:`Summary`},{value:`triggers`,label:`Triggers`},{value:`files`,label:`Files`},{value:`rules`,label:`Rules`},{value:`guidelines`,label:`Guidelines`},{value:`learnings`,label:`Learnings`},{value:`file`,label:`.argus.yml`}]})}),u===`overview`&&(0,k.jsx)(sc,{repo:n,onChange:r}),ac.includes(u)&&(0,k.jsxs)(Xr,{base:m,meta:i,stored:n.config,onSave:h,scope:`repository`,children:[(0,k.jsxs)(`p`,{className:`mb-4 rounded-xl border border-iris/30 bg-iris-soft/50 px-4 py-2.5 text-[13px] text-ink-2`,children:[`Changes here apply to `,(0,k.jsxs)(`b`,{className:`text-ink`,children:[n.owner,`/`,n.name]}),` only. Values that differ from the global settings are marked `,(0,k.jsx)(`span`,{className:`font-mono text-[11px] text-iris uppercase`,children:`overridden`}),`.`]}),u===`review`&&(0,k.jsx)(Xs,{}),u===`depth`&&(0,k.jsx)(ic,{}),u===`summary`&&(0,k.jsx)(Zs,{}),u===`triggers`&&(0,k.jsx)(Qs,{}),u===`files`&&(0,k.jsx)($s,{}),u===`rules`&&(0,k.jsx)(os,{}),u===`guidelines`&&(0,k.jsx)(hi,{})]}),u===`learnings`&&(0,k.jsx)(bi,{repositoryId:n.id,ci:n.integrationId===null}),u===`file`&&(0,k.jsx)(cc,{repo:n})]})}function sc({repo:e,onChange:t}){let n=Nr(`/reviews?repository=${e.id}&limit=20`),[r,i]=(0,v.useState)(``),[a,o]=(0,v.useState)(!1),s=Cr(),c=e.platform===`github`?`pull`:e.platform===`gitlab`?`-/merge_requests`:`pull-requests`,l=e.integrationId===null;return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[l&&(0,k.jsx)(qs,{repo:e,onChange:t}),(0,k.jsx)(ri,{repositoryId:e.id}),!l&&(0,k.jsx)(P,{eyebrow:`Manual`,title:`Review a pull request`,children:(0,k.jsxs)(`form`,{className:`flex gap-2`,onSubmit:async t=>{t.preventDefault(),o(!0);try{let t=/^\d+$/.test(r.trim())?r.trim():void 0;await I(`/reviews`,{method:`POST`,json:{url:t?`https://${e.host}/${e.owner}/${e.name}/${c}/${t}`:r.trim()}}),s(`ok`,`Review queued`),i(``),n.reload()}catch(e){s(`bad`,e.message)}finally{o(!1)}},children:[(0,k.jsx)(`input`,{value:r,onChange:e=>i(e.target.value),placeholder:`Pull request number or URL, e.g. 42`,className:`h-9 flex-1 rounded-lg border border-line-strong bg-panel px-3 font-mono text-[13px] focus:border-iris focus:ring-2 focus:ring-iris/25 focus:outline-none`}),(0,k.jsx)(j,{variant:`primary`,loading:a,disabled:!r.trim(),type:`submit`,children:`Review`})]})}),(0,k.jsx)(P,{eyebrow:`History`,title:`Recent reviews`,padded:!1,children:(0,k.jsx)(ei,{reviews:n.data?.reviews,loading:n.loading,onChange:()=>void n.reload(),hideRepo:!0})})]})}function cc({repo:e}){let t=e.integrationId!==null,n=Nr(t?`/repositories/${e.id}/repo-config`:null),r=Nr(`/repositories/${e.id}/effective-config`),i=(0,v.useMemo)(()=>{if(!r.data)return``;let{learnings:t,...n}=r.data.config;return`# Generated by Argus for ${e.owner}/${e.name}\n${ts(n)}`},[r.data,e]);return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[t&&(0,k.jsx)(P,{eyebrow:`In the repository`,title:n.data?.file??`.argus.yml`,actions:n.data?.file?(0,k.jsx)(F,{tone:`ok`,children:`Found on the default branch`}):(0,k.jsx)(F,{children:`Not present`}),children:n.loading?(0,k.jsx)(ir,{}):n.data?.text?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(`p`,{className:`mb-3 text-[13px] text-ink-2`,children:`Settings in this file are applied on top of everything configured here, per pull request (the file is read from the PR's head commit).`}),(0,k.jsx)(yr,{children:n.data.text})]}):(0,k.jsx)(`p`,{className:`text-[13.5px] text-ink-2`,children:`The repository has no Argus config file. That's fine: the settings configured in this dashboard apply. Add one to keep review settings in code, or to use Argus from CI.`})}),(0,k.jsxs)(P,{eyebrow:`Export`,title:`Effective settings as .argus.yml`,actions:i&&(0,k.jsx)(br,{text:i,label:`Copy YAML`}),children:[(0,k.jsx)(`p`,{className:`mb-3 text-[13px] text-ink-2`,children:`Everything this repository uses today (global settings plus overrides). Commit it to run the same review from GitHub Actions, GitLab CI, Bitbucket Pipelines or Azure Pipelines.`}),r.loading?(0,k.jsx)(ir,{}):(0,k.jsx)(yr,{className:`max-h-[480px]`,children:i})]})]})}var lc={github:{name:`GitHub`,host:`github.com`,token:`Personal access token`,steps:[`Create a fine-grained token (Settings → Developer settings → Fine-grained tokens) for the repositories Argus should review.`,`Repository permissions: Pull requests — Read and write, Contents — Read, Issues — Read and write, Webhooks — Read and write (only for automatic webhook setup), Metadata — Read.`,`A classic token with the repo scope also works.`],link:`https://github.com/settings/personal-access-tokens/new`},gitlab:{name:`GitLab`,host:`gitlab.com`,token:`Access token`,steps:[`Create a personal access token with the api scope (User settings → Access tokens). Use a dedicated bot user if you can.`,`On self-managed GitLab (or GitLab.com Premium) a project or group access token with the api scope and Developer role also works.`,`For self-managed GitLab, set the host below to your instance, e.g. gitlab.example.com.`],link:`https://gitlab.com/-/user_settings/personal_access_tokens`},bitbucket:{name:`Bitbucket`,host:`bitbucket.org`,token:`Access token or API token`,steps:[`Recommended: a repository access token (Repository settings → Access tokens) with Pull requests: Write, Repositories: Read and Webhooks: Read and write. Leave the username empty.`,`Alternatively an Atlassian API token with Bitbucket scopes: enter your Atlassian email as the username.`,`Repository tokens cannot list repositories, so add repositories by URL.`],link:`https://support.atlassian.com/bitbucket-cloud/docs/create-a-repository-access-token/`},azure:{name:`Azure DevOps`,host:`dev.azure.com`,token:`Personal access token`,steps:[`Create a personal access token (User settings → Personal access tokens) with Code: Read & write, Pull Request Threads: Read & write and Service Hooks: Read, write & manage (so Argus can install the service hooks). Use a dedicated account if you can.`,`Enter your organization name (the part after dev.azure.com/).`,`Argus installs the Service Hooks (Pull request created, updated, commented on) for automatic reviews. Without the Service Hooks scope, add them by hand: they post to the webhook URL with basic authentication, any username and the webhook secret as the password.`],link:`https://learn.microsoft.com/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate`},"bitbucket-server":{name:`Bitbucket Server`,host:``,token:`HTTP access token`,steps:[`Create an HTTP access token for a project or repository (Settings → HTTP access tokens), or a personal one on a service account. Repository admin lets Argus install the webhook and check who may use chat commands; with write only, add the webhook by hand and only pull request authors can use chat commands.`,`Enter the server host, for example bitbucket.acme.com.`,`Argus installs the repository webhook (Pull request opened, Source branch updated, Comment added) for automatic reviews when the token allows it.`],link:`https://confluence.atlassian.com/bitbucketserver/http-access-tokens-939515499.html`}},uc={azure:{where:`Project settings → Service hooks → Create subscription → Web Hooks`,events:`One subscription each for: Pull request created, Pull request updated, Pull request commented on`,auth:`Basic authentication: any username, and the webhook secret as the password`},"bitbucket-server":{where:`Repository settings → Webhooks → Create webhook`,events:`Pull request: Opened, Source branch updated, Modified; Comment: Added`,auth:`Paste the webhook secret into the Secret field`}};function dc({repo:e,integration:t,reason:n,onClose:r}){let i=uc[e.platform],a=zr(`admin`),[o,s]=(0,v.useState)(),c=Cr();return(0,k.jsx)(_r,{open:!0,onClose:r,title:`Set up the webhook for ${e.owner}/${e.name}`,children:(0,k.jsxs)(`div`,{className:`space-y-4 text-[13.5px] text-ink-2`,children:[n&&(0,k.jsx)(`p`,{className:`rounded-lg border border-minor/40 bg-minor/5 px-3 py-2 text-[12.5px]`,children:n}),(0,k.jsxs)(`p`,{children:[`Argus can't install this webhook automatically. Add it in `,lc[e.platform].name,`:`]}),i&&(0,k.jsxs)(`ol`,{className:`list-decimal space-y-1 pl-5`,children:[(0,k.jsx)(`li`,{children:i.where}),(0,k.jsx)(`li`,{children:i.events}),(0,k.jsx)(`li`,{children:i.auth})]}),(0,k.jsx)(N,{label:`Webhook URL`,children:t?.webhookUrl?(0,k.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,k.jsx)(yr,{className:`flex-1`,children:t.webhookUrl}),(0,k.jsx)(br,{text:t.webhookUrl})]}):(0,k.jsx)(F,{tone:`warn`,children:`Set the public URL under Server & CI first`})}),(0,k.jsx)(N,{label:`Webhook secret`,children:o?(0,k.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,k.jsx)(yr,{className:`flex-1`,children:o}),(0,k.jsx)(br,{text:o})]}):a&&t?(0,k.jsx)(j,{size:`sm`,onClick:async()=>{try{s((await I(`/integrations/${t.id}/webhook-secret`)).secret)}catch(e){c(`bad`,e.message)}},children:`Reveal secret`}):(0,k.jsx)(`span`,{className:`text-[12.5px] text-ink-3`,children:`Ask an admin for this connection's webhook secret.`})})]})})}function fc({onDone:e}){let[t,n]=(0,v.useState)(``),[r,i]=(0,v.useState)(``),[a,o]=(0,v.useState)(``),[s,c]=(0,v.useState)(``),[l,u]=(0,v.useState)(``),[d,f]=(0,v.useState)(),[p,m]=(0,v.useState)(),h=Cr(),g=async()=>{f(`create`),m(void 0);try{let e=new URLSearchParams;t.trim()&&e.set(`org`,t.trim()),r.trim()&&e.set(`name`,r.trim());let{action:n,manifest:i,webhooks:a}=await I(`/github-app/manifest?${e}`);a||h(`info`,`No public URL is set, so the app is created without webhooks; set one under Server & CI for automatic reviews`);let o=document.createElement(`form`);o.method=`post`,o.action=n;let s=document.createElement(`input`);s.type=`hidden`,s.name=`manifest`,s.value=JSON.stringify(i),o.appendChild(s),document.body.appendChild(o),o.submit()}catch(e){m(e.message),f(void 0)}},_=async()=>{f(`existing`),m(void 0);try{await I(`/integrations/github-app`,{method:`POST`,json:{appId:a.trim(),privateKey:s,...l.trim()?{installationId:l.trim()}:{}}}),h(`ok`,`GitHub App connected`),e()}catch(e){m(e.message)}finally{f(void 0)}};return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`font-display text-[16px]`,children:`Create a new GitHub App`}),(0,k.jsx)(`p`,{className:`mt-1 text-[13px] text-ink-2`,children:`One click on GitHub creates a private app with exactly the permissions Argus needs (pull requests and issues: write, contents: read). Argus receives its key automatically, then you pick the repositories to install it on. Comments appear as the app’s bot and tokens rotate every hour.`}),(0,k.jsxs)(`div`,{className:`mt-3 grid gap-3 md:grid-cols-2`,children:[(0,k.jsx)(N,{label:`Organization (optional)`,hint:`Leave empty to create it under your personal account.`,children:(0,k.jsx)(M,{value:t,onChange:e=>n(e.target.value),placeholder:`acme`,className:`font-mono`})}),(0,k.jsx)(N,{label:`App name (optional)`,hint:`Must be unique on GitHub.`,children:(0,k.jsx)(M,{value:r,onChange:e=>i(e.target.value),placeholder:`Argus for acme`})})]}),(0,k.jsx)(j,{className:`mt-3`,variant:`primary`,loading:d===`create`,onClick:()=>void g(),children:`Create on GitHub ↗`})]}),(0,k.jsxs)(`details`,{className:`rounded-xl border border-line px-4 py-3`,children:[(0,k.jsx)(`summary`,{className:`cursor-pointer text-[13.5px] font-medium text-ink`,children:`Use an existing GitHub App`}),(0,k.jsxs)(`div`,{className:`mt-3 space-y-3`,children:[(0,k.jsxs)(`div`,{className:`grid gap-3 md:grid-cols-2`,children:[(0,k.jsx)(N,{label:`App ID`,children:(0,k.jsx)(M,{value:a,onChange:e=>o(e.target.value),className:`font-mono`})}),(0,k.jsx)(N,{label:`Installation ID (optional)`,hint:`Found automatically from each repository when empty.`,children:(0,k.jsx)(M,{value:l,onChange:e=>u(e.target.value),className:`font-mono`})})]}),(0,k.jsx)(N,{label:`Private key (.pem)`,children:(0,k.jsx)(or,{rows:5,value:s,onChange:e=>c(e.target.value),className:`font-mono text-[11.5px]`,placeholder:`-----BEGIN RSA PRIVATE KEY-----`})}),(0,k.jsx)(j,{loading:d===`existing`,disabled:!a.trim()||!s.includes(`PRIVATE KEY`),onClick:()=>void _(),children:`Connect app`})]})]}),p&&(0,k.jsx)(`p`,{className:`rounded-lg border border-critical/40 bg-critical/5 px-3 py-2 text-[13px] text-critical`,children:p})]})}function pc({platform:e,onClose:t,onDone:n}){let r=lc[e],[i,a]=(0,v.useState)(e===`github`?`app`:`token`),[o,s]=(0,v.useState)(``),[c,l]=(0,v.useState)(``),[u,d]=(0,v.useState)(r.host),[f,p]=(0,v.useState)(``),[m,h]=(0,v.useState)(!1),[g,_]=(0,v.useState)(),y=Cr(),b=async()=>{h(!0),_(void 0);try{let t={platform:e,token:o.trim(),host:u.trim()||r.host};f.trim()&&(t.name=f.trim()),c.trim()&&(t.username=c.trim());let i=await I(`/integrations`,{method:`POST`,json:t});y(`ok`,i.message),n()}catch(e){_(e.message)}finally{h(!1)}};return(0,k.jsxs)(_r,{open:!0,onClose:t,title:`Connect ${r.name}`,footer:(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(j,{variant:`ghost`,onClick:t,children:`Cancel`}),i===`token`&&(0,k.jsx)(j,{variant:`primary`,loading:m,disabled:o.trim().length<8,onClick:()=>void b(),children:`Connect`})]}),children:[e===`github`&&(0,k.jsx)(`div`,{className:`mb-5`,children:(0,k.jsx)(gr,{value:i,onChange:a,options:[{value:`app`,label:`GitHub App (recommended)`},{value:`token`,label:`Personal access token`}]})}),i===`app`?(0,k.jsx)(fc,{onDone:n}):(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(`ol`,{className:`mb-5 list-decimal space-y-1.5 pl-5 text-[13px] text-ink-2`,children:r.steps.map(e=>(0,k.jsx)(`li`,{children:e},e))}),(0,k.jsxs)(`a`,{href:r.link,target:`_blank`,rel:`noreferrer`,className:`mb-5 inline-block text-[13px] text-iris underline underline-offset-4`,children:[`Open `,r.name,` token settings ↗`]}),(0,k.jsxs)(`div`,{className:`space-y-4`,children:[(0,k.jsx)(N,{label:r.token,children:(0,k.jsx)(M,{type:`password`,autoComplete:`off`,value:o,onChange:e=>s(e.target.value),className:`font-mono`})}),e===`azure`&&(0,k.jsx)(N,{label:`Organization`,hint:`dev.azure.com/<organization>`,children:(0,k.jsx)(M,{value:c,onChange:e=>l(e.target.value),placeholder:`acme`,className:`font-mono`})}),(e===`bitbucket`||e===`bitbucket-server`)&&(0,k.jsx)(N,{label:`Username or email (optional)`,hint:`Only for Atlassian API tokens. Leave empty for access tokens.`,children:(0,k.jsx)(M,{value:c,onChange:e=>l(e.target.value)})}),(0,k.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-2`,children:[(0,k.jsx)(N,{label:`Host`,hint:e===`bitbucket`?`Use Bitbucket Server for self-hosted instances.`:e===`bitbucket-server`?`Your Bitbucket Server or Data Center host.`:`Change for self-hosted instances.`,children:(0,k.jsx)(M,{value:u,onChange:e=>d(e.target.value),disabled:e===`bitbucket`||e===`azure`,placeholder:e===`bitbucket-server`?`bitbucket.acme.com`:``,className:`font-mono`})}),(0,k.jsx)(N,{label:`Display name (optional)`,children:(0,k.jsx)(M,{value:f,onChange:e=>p(e.target.value),placeholder:`${r.name} (${u})`})})]}),g&&(0,k.jsx)(`p`,{className:`rounded-lg border border-critical/40 bg-critical/5 px-3 py-2 text-[13px] text-critical`,children:g})]})]})]})}function mc(e){return e>0?[`connection`,`ci`]:[`ci`,`connection`]}function hc({integrations:e,onClose:t,onDone:n}){let r=mc(e.length),[i,a]=(0,v.useState)(r[0]),[o,s]=(0,v.useState)();return o?(0,k.jsx)(_r,{open:!0,onClose:n,title:`Connect ${o.repository.owner}/${o.repository.name} to CI`,wide:!0,footer:(0,k.jsx)(j,{variant:`primary`,onClick:n,children:`Done`}),children:(0,k.jsx)(Gs,{repo:o.repository,token:o.token})}):(0,k.jsxs)(_r,{open:!0,onClose:t,title:`Add a repository`,wide:!0,children:[r.length>1&&(0,k.jsx)(`div`,{className:`mb-5`,children:(0,k.jsx)(gr,{value:i,onChange:a,options:[{value:`connection`,label:`From a connection`},{value:`ci`,label:`Reviewed in CI`}]})}),i===`ci`?(0,k.jsx)(Ks,{onAdded:(e,t)=>s({repository:e,token:t})}):e.length===0?(0,k.jsx)(vr,{title:`No code host connected`,children:`Connect a code host first, or add the repository as reviewed in CI.`}):(0,k.jsx)(gc,{integrations:e,onDone:n})]})}function gc({integrations:e,onDone:t}){let[n,r]=(0,v.useState)(e[0]?.id??0),i=e.find(e=>e.id===n),a=Nr(i?`/integrations/${i.id}/remote-repositories`:null,[n]),[o,s]=(0,v.useState)(``),[c,l]=(0,v.useState)(``),[u,d]=(0,v.useState)(!0),[f,p]=(0,v.useState)(),m=Cr(),h=(0,v.useMemo)(()=>(a.data?.repositories??[]).filter(e=>e.fullName.toLowerCase().includes(o.toLowerCase())).slice(0,60),[a.data,o]),g=async(e,r)=>{p(r);try{let r=await I(`/repositories`,{method:`POST`,json:{integrationId:n,installWebhook:u,...e}});m(r.webhook&&!r.webhook.ok?`bad`:`ok`,r.webhook?.message??`Repository added`),t()}catch(e){m(`bad`,e.message)}finally{p(void 0)}};return(0,k.jsxs)(`div`,{className:`space-y-4`,children:[(0,k.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-2`,children:[(0,k.jsx)(N,{label:`Connection`,children:(0,k.jsx)(sr,{value:n,onChange:e=>r(Number(e.target.value)),children:e.map(e=>(0,k.jsx)(`option`,{value:e.id,children:e.name},e.id))})}),(0,k.jsx)(`div`,{className:`flex items-end pb-1.5`,children:(0,k.jsxs)(`label`,{className:`flex items-center gap-2.5 text-[13px] text-ink-2`,children:[(0,k.jsx)(cr,{checked:u,onChange:d,label:`Install webhook`}),`Install the webhook automatically`]})})]}),(0,k.jsx)(N,{label:`Repository URL`,hint:`Works for every platform, including repositories the token cannot list.`,children:(0,k.jsxs)(`div`,{className:`flex gap-2`,children:[(0,k.jsx)(M,{value:c,onChange:e=>l(e.target.value),placeholder:`https://${i?.host??`github.com`}/owner/repo`,className:`font-mono`}),(0,k.jsx)(j,{variant:`primary`,disabled:!c.trim(),loading:f===`url`,onClick:()=>void g({url:c.trim()},`url`),children:`Add`})]})}),(0,k.jsx)(`div`,{className:`eyebrow pt-2`,children:`or pick from your repositories`}),(0,k.jsx)(M,{placeholder:`Search`,value:o,onChange:e=>s(e.target.value)}),(0,k.jsx)(`div`,{className:`max-h-80 overflow-y-auto rounded-xl border border-line scrollbar-thin`,children:a.loading?(0,k.jsx)(`div`,{className:`flex justify-center p-6 text-ink-3`,children:(0,k.jsx)(ir,{})}):a.error?(0,k.jsx)(`p`,{className:`p-4 text-[13px] text-ink-3`,children:a.error}):h.length===0?(0,k.jsx)(`p`,{className:`p-4 text-[13px] text-ink-3`,children:`No repositories found.`}):(0,k.jsx)(`ul`,{className:`divide-y divide-line`,children:h.map(e=>(0,k.jsxs)(`li`,{className:`flex items-center justify-between gap-3 px-4 py-2.5`,children:[(0,k.jsxs)(`span`,{className:`font-mono text-[13px]`,children:[e.fullName,` `,e.private&&(0,k.jsx)(F,{children:`private`})]}),(0,k.jsx)(j,{size:`sm`,loading:f===e.fullName,onClick:()=>void g({owner:e.owner,name:e.name},e.fullName),children:`Add`})]},e.fullName))})})]})}function _c(){let e=Nr(`/integrations`),t=Cr();(0,v.useEffect)(()=>{let e=new URLSearchParams(window.location.search).get(`installed`);e!==null&&(t(`ok`,`GitHub App installed; ${e} repositor${e===`1`?`y`:`ies`} added`),window.history.replaceState(null,``,window.location.pathname))},[t]);let n=Nr(`/repositories`),[r,i]=(0,v.useState)(),[a,o]=(0,v.useState)(!1),[s,c]=(0,v.useState)(),[l,u]=(0,v.useState)(),d=Cr(),f=zr(`admin`),p=zr(`maintainer`),m=e.data?.integrations??[],h=async e=>{let t=!!uc[e.platform];c(`hook-${e.id}`);try{let n=await I(`/repositories/${e.id}/webhook`,{method:`POST`});!n.ok&&t?u({repo:e,reason:n.message}):d(n.ok?`ok`:`bad`,n.message)}catch(n){t?u({repo:e,reason:n.message}):d(`bad`,n.message)}finally{c(void 0)}},g=async(e,t)=>{c(e);try{await t()}catch(e){d(`bad`,e.message)}finally{c(void 0)}};return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Code hosts`,title:`Repositories`,description:`Connect GitHub, GitLab, Bitbucket or Azure DevOps and choose which repositories Argus watches, or add repositories reviewed in their own CI. Each repository can override any setting.`}),(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(P,{eyebrow:`Connections`,title:`Code hosts`,padded:!1,children:[(0,k.jsx)(`div`,{className:`grid gap-3 p-5 md:grid-cols-3`,children:[`github`,`gitlab`,`bitbucket`,`azure`,`bitbucket-server`].map(e=>(0,k.jsxs)(`button`,{onClick:()=>i(e),disabled:!f,title:f?void 0:`Only admins can connect code hosts`,className:`group flex items-center gap-3 rounded-xl border border-dashed border-line-strong px-4 py-3.5 text-left transition-colors hover:border-iris hover:bg-iris-soft/40 disabled:pointer-events-none disabled:opacity-60`,children:[(0,k.jsx)(`span`,{className:`text-ink-2 group-hover:text-ink`,children:(0,k.jsx)(Tr,{platform:e,size:22})}),(0,k.jsxs)(`span`,{children:[(0,k.jsxs)(`span`,{className:`block font-medium`,children:[`Connect `,lc[e].name]}),(0,k.jsxs)(`span`,{className:`text-[12px] text-ink-3`,children:[m.filter(t=>t.platform===e).length,` connected`]})]})]},e))}),m.length>0&&(0,k.jsx)(`ul`,{className:`divide-y divide-line border-t border-line`,children:m.map(t=>(0,k.jsxs)(`li`,{className:`flex flex-wrap items-center gap-4 px-5 py-3.5`,children:[(0,k.jsx)(Tr,{platform:t.platform,size:18}),(0,k.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,k.jsx)(`div`,{className:`font-medium`,children:t.name}),(0,k.jsxs)(`div`,{className:`font-mono text-[12px] text-ink-3`,children:[t.host,t.username?` · ${t.username}`:``,` · added `,wr(t.createdAt)]})]}),f&&(0,k.jsxs)(k.Fragment,{children:[t.auth===`app`&&t.appSlug&&(0,k.jsx)(`a`,{href:`/api/github-app/install?integration=${t.id}`,className:`text-[13px] text-ink-2 underline-offset-2 hover:underline`,children:`Install on another account`}),(0,k.jsx)(j,{size:`sm`,variant:`ghost`,loading:s===`test-${t.id}`,onClick:()=>void g(`test-${t.id}`,async()=>{let e=await I(`/integrations/${t.id}/test`,{method:`POST`});d(e.ok?`ok`:`bad`,e.message)}),children:`Test`}),(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:()=>void g(`del-${t.id}`,async()=>{window.confirm(`Remove ${t.name} and its ${n.data?.repositories.filter(e=>e.integrationId===t.id).length??0} repositories from Argus?`)&&(await I(`/integrations/${t.id}`,{method:`DELETE`}),await Promise.all([e.reload(),n.reload()]))}),children:`Remove`})]})]},t.id))})]}),(0,k.jsx)(P,{eyebrow:`${n.data?.repositories.filter(e=>e.enabled).length??0} active`,title:`Watched repositories`,actions:f&&(0,k.jsx)(j,{size:`sm`,variant:`primary`,disabled:e.loading&&!e.data,onClick:()=>o(!0),children:`Add repository`}),padded:!1,children:n.loading&&!n.data?(0,k.jsx)(`div`,{className:`flex justify-center p-10 text-ink-3`,children:(0,k.jsx)(ir,{})}):(n.data?.repositories.length??0)===0?(0,k.jsx)(vr,{title:`No repositories yet`,children:m.length?`Add a repository to start reviewing its pull requests.`:`Connect a code host, or add a repository reviewed in its own CI.`}):(0,k.jsx)(`ul`,{className:`divide-y divide-line`,children:n.data.repositories.map(e=>{let t=Object.keys(e.config??{}).length;return(0,k.jsxs)(`li`,{className:A(`flex flex-wrap items-center gap-4 px-5 py-3.5`,!e.enabled&&`opacity-60`),children:[(0,k.jsx)(cr,{checked:e.enabled,disabled:!p,label:`Enable ${e.owner}/${e.name}`,onChange:t=>void g(`toggle-${e.id}`,async()=>{await I(`/repositories/${e.id}`,{method:`PUT`,json:{enabled:t}}),await n.reload()})}),(0,k.jsx)(Tr,{platform:e.platform}),(0,k.jsxs)(Vn,{to:`/repositories/${e.id}`,className:`min-w-0 flex-1 hover:text-iris`,children:[(0,k.jsxs)(`span`,{className:`font-mono text-[13.5px]`,children:[e.owner,`/`,(0,k.jsx)(`span`,{className:`font-semibold`,children:e.name})]}),e.integrationId===null?(0,k.jsx)(F,{className:`ml-2`,children:`CI`}):(0,k.jsx)(`span`,{className:`ml-2 text-[12px] text-ink-3`,children:e.integrationName})]}),t>0&&(0,k.jsxs)(F,{tone:`iris`,children:[t,` override`,t>1?`s`:``]}),p&&e.integrationId!==null&&(0,k.jsx)(j,{size:`sm`,variant:`ghost`,loading:s===`hook-${e.id}`,onClick:()=>void h(e),children:`Install webhook`}),(0,k.jsx)(Vn,{to:`/repositories/${e.id}`,children:(0,k.jsx)(j,{size:`sm`,children:`Configure`})})]},e.id)})})})]}),r&&(0,k.jsx)(pc,{platform:r,onClose:()=>i(void 0),onDone:()=>{i(void 0),e.reload()}}),l&&(0,k.jsx)(dc,{repo:l.repo,integration:m.find(e=>e.id===l.repo.integrationId),reason:l.reason,onClose:()=>u(void 0)}),a&&(0,k.jsx)(hc,{integrations:m,onClose:()=>o(!1),onDone:()=>{o(!1),n.reload()}})]})}function vc(){let[e,t]=(0,v.useState)(``),n=zr(`maintainer`),r=Nr(`/reviews?limit=100${e?`&status=${e}`:``}`,[e]);return Pr(t=>{r.setData(n=>{if(!n)return n;let r=!e||t.status===e;return n.reviews.some(e=>e.id===t.id)?r?{reviews:n.reviews.map(e=>e.id===t.id?{...e,...t}:e)}:{reviews:n.reviews.filter(e=>e.id!==t.id)}:r?{reviews:[t,...n.reviews]}:n})},()=>void r.reload()),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Overview`,title:`Reviews`,description:`Every review Argus has run, live.`}),(0,k.jsxs)(`div`,{className:`space-y-6`,children:[n&&(0,k.jsx)(P,{eyebrow:`Manual`,title:`Review a pull request`,children:(0,k.jsx)(Qr,{})}),(0,k.jsx)(P,{title:`History`,actions:(0,k.jsx)(gr,{value:e,onChange:t,options:[{value:``,label:`All`},{value:`running`,label:`Running`},{value:`done`,label:`Done`},{value:`failed`,label:`Failed`},{value:`skipped`,label:`Skipped`}]}),padded:!1,children:(0,k.jsx)(ei,{reviews:r.data?.reviews,loading:r.loading,onChange:()=>void r.reload()})})]})]})}function yc(){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Review brain`,title:`Rules`,description:`Your team's conventions as enforceable checks. Each rule can target paths and carries its own severity. Repositories can add or override rules.`}),(0,k.jsx)(os,{})]})}function bc(){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Settings`,title:`Triggers & chat`,description:`When Argus reviews on its own, and how it talks with your team in pull requests.`}),(0,k.jsx)(Qs,{})]})}function xc(){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Settings`,title:`Depth & analysis`,description:`Codebase exploration, multi-pass voting and static analysis: the stages that make findings precise. Repositories can override any of this.`}),(0,k.jsx)(ic,{})]})}function Sc(){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Settings`,title:`Files & context`,description:`Which files get reviewed and how much surrounding code the reviewer reads.`}),(0,k.jsx)($s,{})]})}var Cc={openrouter:`OpenRouter`,anthropic:`Anthropic API`,openai:`OpenAI API`,"openai-compatible":`OpenAI-compatible`,"claude-code":`Claude subscription (Claude Code)`,codex:`ChatGPT subscription (Codex)`,copilot:`GitHub Copilot`},wc={openrouter:`One key for hundreds of models. Model ids look like anthropic/claude-sonnet-5.5.`,anthropic:`Direct Anthropic API with prompt caching. Model ids look like claude-sonnet-5-5.`,openai:`Direct OpenAI API.`,"openai-compatible":`Any endpoint that speaks the OpenAI chat API: Ollama, vLLM, LM Studio, Azure, a company gateway.`,"claude-code":`Uses the Claude Code CLI logged in with your Claude Pro or Max plan. No API key needed.`,codex:`Uses the Codex CLI logged in with your ChatGPT plan. No API key needed.`,copilot:`Uses your Copilot subscription through the Copilot CLI`},Tc=[{key:`review`,title:`Review`,text:`Finds defects. Use your strongest model here.`,inherit:``},{key:`light`,title:`Triage & trivial files`,text:`Classifies small changes and reviews the ones with no behavioural impact (copy, formatting, version bumps). A fast, cheap model such as Haiku.`,inherit:`Off (same as review)`},{key:`verify`,title:`Verification`,text:`Re-checks every finding. A strong model keeps precision high.`,inherit:`Same as review`},{key:`summary`,title:`Summary`,text:`Writes the walkthrough. A faster model is fine.`,inherit:`Same as review`},{key:`chat`,title:`Chat`,text:`Answers questions and learns from feedback in PR threads.`,inherit:`Same as review`}];function Ec({provider:e,state:t,onChange:n}){let[r,i]=(0,v.useState)(``),[a,o]=(0,v.useState)(!1),s=Cr(),c=async t=>{o(!0);try{await I(`/providers/${e}/key`,{method:`PUT`,json:{key:t}}),i(``),s(`ok`,t?`${Cc[e]} key saved`:`${Cc[e]} key removed`),n()}catch(e){s(`bad`,e.message)}finally{o(!1)}};return(0,k.jsxs)(`div`,{className:`grid items-center gap-3 py-3.5 md:grid-cols-[220px_1fr_auto]`,children:[(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`text-[13.5px] font-medium`,children:Cc[e]}),(0,k.jsx)(`div`,{className:`mt-0.5 flex gap-1.5`,children:t?.hasKey?(0,k.jsxs)(F,{tone:`ok`,children:[`Key `,t.hint]}):t?.fromEnv?(0,k.jsx)(F,{tone:`iris`,children:`From environment`}):(0,k.jsx)(F,{children:`Not set`})})]}),(0,k.jsx)(M,{type:`password`,autoComplete:`off`,placeholder:t?.hasKey?`Paste a new key to replace it`:`Paste API key`,value:r,onChange:e=>i(e.target.value),onKeyDown:e=>e.key===`Enter`&&r.trim()&&void c(r.trim())}),(0,k.jsxs)(`div`,{className:`flex gap-2`,children:[(0,k.jsx)(j,{size:`sm`,variant:`primary`,disabled:!r.trim(),loading:a,onClick:()=>void c(r.trim()),children:`Save`}),t?.hasKey&&(0,k.jsx)(j,{size:`sm`,variant:`ghost`,onClick:()=>void c(null),children:`Remove`})]})]})}function Dc(e,t){let[n,r]=(0,v.useState)([]),[i,a]=(0,v.useState)(),[o,s]=(0,v.useState)(!1),c=zr(`admin`);return(0,v.useEffect)(()=>{if(!c)return;let n=!1;s(!0),a(void 0);let i=new URLSearchParams({provider:e});return t&&i.set(`baseUrl`,t),I(`/models?${i}`).then(e=>!n&&r(e.models)).catch(e=>!n&&(r([]),a(e.message))).finally(()=>!n&&s(!1)),()=>{n=!0}},[e,t,c]),{models:n,error:i,loading:o}}function Oc(e){return e===void 0?``:e===0?`free`:`$${e<1?e.toFixed(2):e.toFixed(+(e<10))}`}function kc({provider:e,value:t,onChange:n,baseUrl:r}){let{models:i,error:a,loading:o}=Dc(e,r),s=(0,v.useId)(),c=i.find(e=>e.id===t);return(0,k.jsxs)(`div`,{children:[(0,k.jsxs)(`div`,{className:`relative`,children:[(0,k.jsx)(M,{list:s,value:t,onChange:e=>n(e.target.value),className:`font-mono`,placeholder:`model id`}),o&&(0,k.jsx)(`span`,{className:`absolute top-2.5 right-3 text-ink-3`,children:(0,k.jsx)(ir,{size:14})})]}),(0,k.jsx)(`datalist`,{id:s,children:i.slice(0,600).map(e=>(0,k.jsx)(`option`,{value:e.id,children:[e.name,e.inputPrice===void 0?``:`${Oc(e.inputPrice)} / ${Oc(e.outputPrice)} per M`,e.description].filter(Boolean).join(` · `)},e.id))}),(0,k.jsx)(`p`,{className:`mt-1.5 text-[12px] text-ink-3`,children:a?`Could not load models: ${a}`:c?[c.name,c.contextLength?`${Math.round(c.contextLength/1e3)}k context`:``,c.inputPrice===void 0?``:`${Oc(c.inputPrice)} in / ${Oc(c.outputPrice)} out per million tokens`,c.description].filter(Boolean).join(` · `):i.length?`${i.length} models available — start typing to search`:``})]})}function Ac({stage:e}){let t=Yr(),n=Cr(),r=`models.${e.key}`,i=t.get(r),a=t.get(`models.review`),o=e.key!==`review`&&!i,s=i??a,[c,l]=(0,v.useState)(!1),[u,d]=(0,v.useState)(),[f,p]=(0,v.useState)(``),m=zr(`admin`),h=t.isLocked(r),g=!!(u&&!u.ok&&u.keyRequired),_=e=>{let n={...s,...e};n.provider!==`openai-compatible`&&delete n.baseUrl,t.set(r,n),d(void 0)},y=async()=>{l(!0),d(void 0);try{let e={provider:s.provider,model:s.model};s.baseUrl&&(e.baseUrl=s.baseUrl),s.effort&&(e.effort=s.effort),f.trim()&&(e.apiKey=f.trim()),d(await I(`/models/test`,{method:`POST`,json:e}))}catch(e){n(`bad`,e.message)}finally{l(!1)}};return(0,k.jsxs)(`div`,{className:A(`rounded-xl border p-4`,o?`border-dashed border-line-strong`:`border-line-strong`),children:[(0,k.jsxs)(`div`,{className:`flex items-start justify-between gap-4`,children:[(0,k.jsxs)(`div`,{children:[(0,k.jsxs)(`div`,{className:`font-display text-[17px] font-medium`,children:[e.title,(0,k.jsx)(si,{path:r}),(0,k.jsx)(ci,{path:r})]}),(0,k.jsx)(`div`,{className:`text-[12.5px] text-ink-3`,children:e.text})]}),e.key!==`review`&&!h&&(0,k.jsx)(lr,{label:(0,k.jsx)(`span`,{className:`text-[12.5px] font-normal text-ink-2`,children:e.inherit}),checked:o,onChange:e=>t.set(r,e?void 0:structuredClone(a))})]}),o?(0,k.jsxs)(`p`,{className:`mt-1 font-mono text-[12.5px] text-ink-2`,children:[Cc[a.provider],` · `,a.model]}):(0,k.jsxs)(`div`,{className:A(`mt-3 space-y-4`,h&&`pointer-events-none opacity-60`),"aria-disabled":h||void 0,children:[(0,k.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-[260px_1fr]`,children:[(0,k.jsx)(N,{label:`Provider`,children:(0,k.jsx)(sr,{value:s.provider,onChange:e=>_({provider:e.target.value,model:``}),children:t.meta.providers.map(e=>(0,k.jsx)(`option`,{value:e,children:Cc[e]},e))})}),(0,k.jsx)(N,{label:`Model`,children:(0,k.jsx)(kc,{provider:s.provider,value:s.model,onChange:e=>_({model:e}),...s.baseUrl?{baseUrl:s.baseUrl}:{}})})]}),(0,k.jsx)(`p`,{className:`-mt-1 text-[12.5px] text-ink-3`,children:wc[s.provider]}),s.provider===`openrouter`&&(0,k.jsx)(N,{label:`Preferred upstream providers`,hint:`OpenRouter routes in this order (e.g. anthropic, google-vertex). Pinning one provider keeps prompt caching warm. Anthropic models default to anthropic.`,children:(0,k.jsx)(hr,{value:s.providerOrder??[],onChange:e=>_({providerOrder:e.length?e:void 0}),placeholder:`anthropic`})}),s.provider===`openai-compatible`&&(0,k.jsx)(N,{label:`Base URL`,hint:`For example http://localhost:11434/v1 for Ollama.`,children:(0,k.jsx)(M,{value:s.baseUrl??``,onChange:e=>_({baseUrl:e.target.value||void 0}),className:`font-mono`,placeholder:`https://…/v1`})}),(0,k.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-3`,children:[(0,k.jsx)(N,{label:`Reasoning effort`,hint:`Higher thinks longer. Leave empty for the model default.`,children:(0,k.jsxs)(sr,{value:s.effort??``,onChange:e=>_({effort:e.target.value||void 0}),children:[(0,k.jsx)(`option`,{value:``,children:`Model default`}),t.meta.efforts.map(e=>(0,k.jsx)(`option`,{value:e,children:e},e))]})}),(0,k.jsx)(N,{label:`Max output tokens`,children:(0,k.jsx)(M,{type:`number`,min:1e3,max:128e3,step:1e3,value:s.maxOutputTokens,onChange:e=>_({maxOutputTokens:Number(e.target.value)||16e3})})}),(0,k.jsx)(N,{label:`Timeout (seconds)`,children:(0,k.jsx)(M,{type:`number`,min:30,step:30,value:Math.round(s.timeoutMs/1e3),onChange:e=>_({timeoutMs:(Number(e.target.value)||600)*1e3})})})]}),m&&!h&&(0,k.jsxs)(`div`,{className:`flex flex-wrap items-center gap-3`,children:[(0,k.jsx)(j,{size:`sm`,onClick:()=>void y(),loading:c,disabled:!s.model,children:`Test connection`}),u&&(0,k.jsxs)(`span`,{className:A(`text-[13px]`,u.ok?`text-ok`:`text-critical`),children:[u.ok?`✓`:`✕`,` `,u.message,` `,(0,k.jsxs)(`span`,{className:`text-ink-3`,children:[`(`,(u.latencyMs/1e3).toFixed(1),`s)`]})]}),(g||f)&&(0,k.jsxs)(`div`,{className:`flex w-full items-center gap-2`,children:[(0,k.jsx)(M,{type:`password`,autoComplete:`off`,value:f,onChange:e=>p(e.target.value),placeholder:`API key for this base URL (used for this test only)`,className:`max-w-sm`}),(0,k.jsx)(`span`,{className:`text-[12px] text-ink-3`,children:`Or save the settings first so the stored key may be used.`})]})]})]})]})}function jc({title:e,status:t,login:n}){return(0,k.jsxs)(`div`,{className:`rounded-xl border border-line-strong p-4`,children:[(0,k.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,k.jsx)(`div`,{className:`font-medium`,children:e}),t?t.installed?t.loggedIn===void 0?(0,k.jsx)(F,{tone:`neutral`,children:`Login unknown`}):t.loggedIn?(0,k.jsx)(F,{tone:`ok`,children:`Logged in`}):(0,k.jsx)(F,{tone:`warn`,children:`Not logged in`}):(0,k.jsx)(F,{tone:`bad`,children:`Not installed`}):(0,k.jsx)(ir,{size:14})]}),(0,k.jsx)(`p`,{className:`mt-1.5 text-[12.5px] text-ink-3`,children:t?.detail}),t?.version&&(0,k.jsx)(`p`,{className:`mt-1 font-mono text-[11.5px] text-ink-3`,children:t.version}),t&&t.loggedIn!==!0&&(0,k.jsx)(`p`,{className:`mt-2 font-mono text-[12px] text-ink-2`,children:n})]})}function Mc(){let e=Yr(),t=Nr(`/providers`);return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Settings`,title:`Models & providers`,description:`Connect an API, or use your Claude, ChatGPT or GitHub Copilot subscription through their official command-line tools. Pick a model for each stage of the review.`}),(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(P,{eyebrow:`Pipeline`,title:`Models per stage`,children:[e.isLocked(`models`)&&(0,k.jsxs)(`p`,{className:`mb-3 rounded-lg border border-line px-3 py-2 text-[12.5px] text-ink-3`,children:[`The models decide what runs on this server. `,e.lockNote,`.`]}),(0,k.jsx)(`div`,{className:`space-y-3`,children:Tc.map(e=>(0,k.jsx)(Ac,{stage:e},e.key))})]}),(0,k.jsx)(P,{eyebrow:`Credentials`,title:`API keys`,actions:(0,k.jsx)(`span`,{className:`text-[12px] text-ink-3`,children:`Encrypted at rest. Never shown again.`}),children:(0,k.jsx)(`div`,{className:`divide-y divide-line`,children:[`openrouter`,`anthropic`,`openai`,`openai-compatible`].map(e=>(0,k.jsx)(Ec,{provider:e,state:t.data?.keys[e],onChange:()=>void t.reload()},e))})}),(0,k.jsxs)(P,{eyebrow:`Subscriptions`,title:`Claude, ChatGPT and Copilot plans`,children:[(0,k.jsx)(`p`,{className:`mb-4 text-[13.5px] text-ink-2`,children:`Argus runs the official CLIs on this machine, so reviews use your plan's limits instead of API billing. Log in once in a terminal; the server picks it up.`}),(0,k.jsxs)(`div`,{className:`grid gap-3 md:grid-cols-2`,children:[(0,k.jsx)(jc,{title:`Claude Code`,status:t.data?.cli[`claude-code`],login:`claude # then /login with your Claude account`}),(0,k.jsx)(jc,{title:`Codex`,status:t.data?.cli.codex,login:`codex login`}),(0,k.jsx)(jc,{title:`GitHub Copilot`,status:t.data?.cli.copilot,login:`copilot login`})]})]})]})]})}function Nc(){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Settings`,title:`Review behaviour`,description:`How strict Argus is, what it looks for, and how it reports. Repositories can override any of this.`}),(0,k.jsx)(Xs,{})]})}function Pc(){let e=Nr(`/trackers`),t=Cr(),[n,r]=(0,v.useState)(``),[i,a]=(0,v.useState)(``),[o,s]=(0,v.useState)(``),[c,l]=(0,v.useState)(``),[u,d]=(0,v.useState)();(0,v.useEffect)(()=>{e.data?.jira&&(r(e.data.jira.baseUrl),a(e.data.jira.email))},[e.data]);let f=async(n,r,i)=>{d(r);try{await I(`/trackers`,{method:`PUT`,json:n}),t(`ok`,i),s(``),l(``),await e.reload()}catch(e){t(`bad`,e.message)}finally{d(void 0)}},p=e.data?.jira,m=e.data?.linear;return(0,k.jsxs)(P,{eyebrow:`Issue trackers`,title:`Jira and Linear`,children:[(0,k.jsxs)(`p`,{className:`mb-4 text-[13.5px] text-ink-2`,children:[`GitHub, GitLab and Bitbucket issues are read with the code-host token. Add Jira or Linear so keys like `,(0,k.jsx)(`span`,{className:`font-mono`,children:`PROJ-42`}),` in a pull request pull in the issue text and acceptance criteria. Tokens are encrypted at rest. CLI and CI runs read `,(0,k.jsx)(`span`,{className:`font-mono`,children:`JIRA_BASE_URL`}),`,`,` `,(0,k.jsx)(`span`,{className:`font-mono`,children:`JIRA_EMAIL`}),`, `,(0,k.jsx)(`span`,{className:`font-mono`,children:`JIRA_API_TOKEN`}),` and `,(0,k.jsx)(`span`,{className:`font-mono`,children:`LINEAR_API_KEY`}),`.`]}),(0,k.jsxs)(`div`,{className:`space-y-5`,children:[(0,k.jsxs)(`div`,{children:[(0,k.jsxs)(`div`,{className:`mb-2 flex items-center gap-2`,children:[(0,k.jsx)(`span`,{className:`font-display text-[16px]`,children:`Jira Cloud`}),p?(0,k.jsx)(F,{tone:`ok`,children:`Connected`}):(0,k.jsx)(F,{children:`Not set`})]}),(0,k.jsxs)(`div`,{className:`grid gap-3 md:grid-cols-3`,children:[(0,k.jsx)(N,{label:`Site URL`,children:(0,k.jsx)(M,{value:n,onChange:e=>r(e.target.value),placeholder:`https://acme.atlassian.net`,className:`font-mono`})}),(0,k.jsx)(N,{label:`Account email`,children:(0,k.jsx)(M,{value:i,onChange:e=>a(e.target.value),placeholder:`you@acme.com`})}),(0,k.jsx)(N,{label:`API token`,children:(0,k.jsx)(M,{type:`password`,autoComplete:`off`,value:o,onChange:e=>s(e.target.value),placeholder:p?.tokenSet?`•••••• saved`:`id.atlassian.com → API tokens`})})]}),(0,k.jsxs)(`div`,{className:`mt-3 flex gap-2`,children:[(0,k.jsx)(j,{size:`sm`,variant:`primary`,disabled:!n||!i||!o&&!p?.tokenSet,loading:u===`jira`,onClick:()=>void f({jira:{baseUrl:n,email:i,...o?{token:o}:{}}},`jira`,`Jira saved`),children:`Save Jira`}),p&&(0,k.jsx)(j,{size:`sm`,variant:`danger`,loading:u===`jira-rm`,onClick:()=>void f({jira:null},`jira-rm`,`Jira removed`),children:`Remove`})]})]}),(0,k.jsxs)(`div`,{className:`border-t border-line pt-5`,children:[(0,k.jsxs)(`div`,{className:`mb-2 flex items-center gap-2`,children:[(0,k.jsx)(`span`,{className:`font-display text-[16px]`,children:`Linear`}),m?(0,k.jsx)(F,{tone:`ok`,children:`Connected`}):(0,k.jsx)(F,{children:`Not set`})]}),(0,k.jsxs)(`div`,{className:`flex max-w-xl gap-2`,children:[(0,k.jsx)(M,{type:`password`,autoComplete:`off`,value:c,onChange:e=>l(e.target.value),placeholder:m?`•••••• saved`:`Personal API key (lin_api_…)`}),(0,k.jsx)(j,{size:`sm`,variant:`primary`,disabled:!c,loading:u===`linear`,onClick:()=>void f({linear:{apiKey:c}},`linear`,`Linear saved`),children:`Save`}),m&&(0,k.jsx)(j,{size:`sm`,variant:`danger`,loading:u===`linear-rm`,onClick:()=>void f({linear:null},`linear-rm`,`Linear removed`),children:`Remove`})]})]})]})]})}function Fc(){let e=Nr(`/server`),t=Nr(`/integrations`),[n,r]=(0,v.useState)(``),[i,a]=(0,v.useState)(),o=Cr(),s=Nr(`/status`).data?.version??`0.2.0`;(0,v.useEffect)(()=>{e.data&&r(e.data.publicUrl)},[e.data]);let c=async(n,r)=>{a(r);try{let r=await I(`/server`,{method:`PUT`,json:n});e.setData(r),t.reload(),o(`ok`,`Saved`)}catch(e){o(`bad`,e.message)}finally{a(void 0)}};return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Settings`,title:`Server & CI`,description:`Make Argus reachable for webhooks, or run reviews inside your CI instead.`}),(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsxs)(P,{eyebrow:`Webhooks`,title:`Public URL`,children:[(0,k.jsx)(N,{label:`Address where GitHub, GitLab, Bitbucket and Azure DevOps can reach this server`,hint:`For example https://argus.example.com, or a tunnel such as an ngrok static domain. Webhooks go to <url>/webhooks/<platform>.`,children:(0,k.jsxs)(`div`,{className:`flex max-w-xl gap-2`,children:[(0,k.jsx)(M,{value:n,onChange:e=>r(e.target.value),placeholder:`https://argus.example.com`,className:`font-mono`}),(0,k.jsx)(j,{variant:`primary`,loading:i===`url`,onClick:()=>void c({publicUrl:n},`url`),disabled:n===e.data?.publicUrl,children:`Save`})]})}),t.data&&t.data.integrations.length>0&&(0,k.jsx)(`div`,{className:`mt-5 space-y-2`,children:t.data.integrations.map(e=>(0,k.jsxs)(`div`,{className:`flex items-center justify-between gap-4 rounded-lg border border-line px-3 py-2`,children:[(0,k.jsx)(`span`,{className:`text-[13px]`,children:e.name}),e.webhookUrl?(0,k.jsxs)(`span`,{className:`flex items-center gap-1`,children:[(0,k.jsx)(`code`,{className:`font-mono text-[12px] text-ink-2`,children:e.webhookUrl}),(0,k.jsx)(br,{text:e.webhookUrl})]}):(0,k.jsx)(F,{tone:`warn`,children:`Set the public URL first`})]},e.id))})]}),(0,k.jsx)(Pc,{}),(0,k.jsxs)(P,{eyebrow:`Without a server`,title:`Run Argus in CI or before commits`,children:[(0,k.jsx)(Us,{version:s,withHook:!0}),(0,k.jsxs)(`p`,{className:`mt-3 text-[12.5px] text-ink-3`,children:[`CI runs read settings from a `,(0,k.jsx)(`code`,{className:`font-mono`,children:`.argus.yml`}),` file in the repository; export it from any repository page here. The files install Argus with`,` `,(0,k.jsx)(`code`,{className:`font-mono`,children:`npx argus-review`}),`, which needs the package published to npm or your private registry (see the README); until then, switch on `,(0,k.jsx)(`em`,{children:`Build Argus from source`}),`.`]})]})]})]})}function Ic(){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ur,{eyebrow:`Settings`,title:`Summary`,description:`The walkthrough comment Argus keeps up to date on every pull request.`}),(0,k.jsx)(Zs,{})]})}var Lc={viewer:`Sees reviews, findings, repositories and settings`,maintainer:`Also starts, cancels and retries reviews, edits learnings and per-repository settings`,admin:`Also manages integrations, models, keys, global settings and users`};function Rc({me:e,onChanged:t}){let n=Nr(`/users`),r=Cr(),[i,a]=(0,v.useState)(``),[o,s]=(0,v.useState)(``),[c,l]=(0,v.useState)(``),[u,d]=(0,v.useState)(`maintainer`),[f,p]=(0,v.useState)(),m=n.data?.users??[],h=n.data!==void 0&&m.length===0,g=async(e,i,a)=>{p(e);try{await i(),r(`ok`,a),await n.reload(),t()}catch(e){r(`bad`,e.message)}finally{p(void 0)}};return(0,k.jsxs)(`div`,{className:`space-y-6`,children:[(0,k.jsx)(ur,{eyebrow:`Settings`,title:`Team & access`,description:`Give each person their own sign-in and a role. Once the first admin exists, Argus asks everyone for an email and password; the shared server password stops working.`}),(0,k.jsxs)(P,{eyebrow:h?`Step 1`:`Invite`,title:h?`Create the first admin`:`Add a person`,children:[(0,k.jsxs)(`div`,{className:`grid gap-3 md:grid-cols-2`,children:[(0,k.jsx)(N,{label:`Email`,children:(0,k.jsx)(M,{type:`email`,value:i,onChange:e=>a(e.target.value),placeholder:`dev@acme.com`})}),(0,k.jsx)(N,{label:`Name`,hint:`Optional`,children:(0,k.jsx)(M,{value:o,onChange:e=>s(e.target.value)})}),(0,k.jsx)(N,{label:`Password`,hint:`At least 8 characters; they can be changed later by an admin`,children:(0,k.jsx)(M,{type:`password`,autoComplete:`new-password`,value:c,onChange:e=>l(e.target.value)})}),(0,k.jsx)(N,{label:`Role`,hint:Lc[h?`admin`:u],children:(0,k.jsx)(gr,{value:h?`admin`:u,onChange:e=>!h&&d(e),options:[{value:`viewer`,label:`Viewer`},{value:`maintainer`,label:`Maintainer`},{value:`admin`,label:`Admin`}]})})]}),(0,k.jsx)(`div`,{className:`mt-4`,children:(0,k.jsx)(j,{variant:`primary`,disabled:!i.includes(`@`)||c.length<8,loading:f===`add`,onClick:()=>void g(`add`,async()=>{await I(`/users`,{method:`POST`,json:{email:i,name:o||null,role:h?`admin`:u,password:c}}),a(``),s(``),l(``)},h?`Admin created; you are signed in as them`:`${i} can now sign in`),children:h?`Create admin and require sign-in`:`Add person`})})]}),(0,k.jsx)(P,{eyebrow:`People`,title:`${m.length} ${m.length===1?`person`:`people`}`,padded:!1,children:m.length===0?(0,k.jsx)(`div`,{className:`p-6`,children:(0,k.jsx)(vr,{title:`No users yet`,children:`Anyone who can reach this server can change everything until the first admin is created.`})}):(0,k.jsxs)(`table`,{className:`w-full text-[13.5px]`,children:[(0,k.jsx)(`thead`,{children:(0,k.jsxs)(`tr`,{className:`eyebrow border-b border-line text-left`,children:[(0,k.jsx)(`th`,{className:`px-5 py-2.5 font-normal`,children:`Person`}),(0,k.jsx)(`th`,{className:`px-3 py-2.5 font-normal`,children:`Role`}),(0,k.jsx)(`th`,{className:`px-3 py-2.5 font-normal`,children:`Last sign-in`}),(0,k.jsx)(`th`,{className:`px-5 py-2.5`})]})}),(0,k.jsx)(`tbody`,{children:m.map(t=>(0,k.jsxs)(`tr`,{className:`border-b border-line/60 last:border-0`,children:[(0,k.jsxs)(`td`,{className:`px-5 py-3`,children:[(0,k.jsx)(`div`,{className:`font-medium`,children:t.name||t.email}),t.name&&(0,k.jsx)(`div`,{className:`text-[12px] text-ink-3`,children:t.email}),e?.id===t.id&&(0,k.jsx)(F,{tone:`iris`,className:`mt-1`,children:`You`})]}),(0,k.jsx)(`td`,{className:`px-3 py-3`,children:(0,k.jsxs)(sr,{value:t.role,disabled:f===`role-${t.id}`,onChange:e=>void g(`role-${t.id}`,()=>I(`/users/${t.id}`,{method:`PUT`,json:{role:e.target.value}}),`Role changed`),children:[(0,k.jsx)(`option`,{value:`viewer`,children:`Viewer`}),(0,k.jsx)(`option`,{value:`maintainer`,children:`Maintainer`}),(0,k.jsx)(`option`,{value:`admin`,children:`Admin`})]})}),(0,k.jsx)(`td`,{className:`px-3 py-3 text-ink-3`,children:t.lastLoginAt?wr(t.lastLoginAt.replace(` `,`T`)+`Z`):`never`}),(0,k.jsx)(`td`,{className:`px-5 py-3 text-right`,children:e?.id!==t.id&&(0,k.jsx)(j,{size:`sm`,variant:`danger`,loading:f===`rm-${t.id}`,onClick:()=>void g(`rm-${t.id}`,()=>I(`/users/${t.id}`,{method:`DELETE`}),`${t.email} removed`),children:`Remove`})})]},t.id))})]})}),(0,k.jsx)(P,{eyebrow:`Automation`,title:`Create the admin from the environment`,children:(0,k.jsxs)(`p`,{className:`text-[13.5px] text-ink-2`,children:[`For Docker and Kubernetes, set `,(0,k.jsx)(`span`,{className:`font-mono`,children:`ARGUS_ADMIN_EMAIL`}),` and `,(0,k.jsx)(`span`,{className:`font-mono`,children:`ARGUS_ADMIN_PASSWORD`}),`; Argus creates that admin at start-up if it does not exist yet.`]})})]})}var zc=(0,v.lazy)(()=>ne(()=>import(`./ReviewDetail-BUhtF94a.js`).then(e=>({default:e.ReviewDetail})),[])),Bc=[`/rules`,`/guidelines`,`/settings/models`,`/settings/review`,`/settings/depth`,`/settings/summary`,`/settings/automation`,`/settings/files`];function Vc(){let{meta:e,stored:t,error:n,save:r}=Zr();return n?(0,k.jsxs)(`div`,{className:`rounded-xl border border-critical/40 p-6 text-critical`,children:[`Could not load settings: `,n]}):!e||!t?(0,k.jsxs)(`div`,{className:`flex items-center gap-3 p-10 text-ink-3`,children:[(0,k.jsx)(ir,{}),` Loading settings…`]}):(0,k.jsx)(Xr,{base:e.defaults,meta:e,stored:t,onSave:r,scope:`global`,stayOn:Bc,children:(0,k.jsx)($t,{})})}function Hc({onDone:e}){return(0,k.jsx)(`div`,{className:`rings flex min-h-screen items-center justify-center p-6`,children:(0,k.jsxs)(`div`,{className:`w-full max-w-sm animate-rise rounded-2xl border border-line bg-panel p-8 shadow-xl`,children:[(0,k.jsxs)(`div`,{className:`mb-6 flex items-center gap-3`,children:[(0,k.jsx)(rr,{size:36}),(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`font-display text-2xl font-semibold`,children:`Argus`}),(0,k.jsx)(`div`,{className:`text-[13px] text-ink-3`,children:`Sign in to manage reviews`})]})]}),(0,k.jsx)(Uc,{onDone:e})]})})}function Uc({onDone:e}){let[t,n]=(0,v.useState)(``),[r,i]=(0,v.useState)(``),[a,o]=(0,v.useState)(),[s,c]=(0,v.useState)(!1);return(0,k.jsxs)(`form`,{onSubmit:async n=>{n.preventDefault(),c(!0),o(void 0);try{await I(`/auth/login`,{method:`POST`,json:{email:t,password:r}}),e()}catch(e){o(e.message)}finally{c(!1)}},children:[(0,k.jsx)(`label`,{htmlFor:`email`,className:`mb-1.5 block text-[13px] font-medium`,children:`Email`}),(0,k.jsx)(M,{id:`email`,type:`email`,autoComplete:`username`,autoFocus:!0,value:t,onChange:e=>n(e.target.value),className:`mb-4`}),(0,k.jsx)(`label`,{htmlFor:`password`,className:`mb-1.5 block text-[13px] font-medium`,children:`Password`}),(0,k.jsx)(M,{id:`password`,type:`password`,autoComplete:`current-password`,value:r,onChange:e=>i(e.target.value)}),a&&(0,k.jsx)(`p`,{className:`mt-2 text-[13px] text-critical`,children:a}),(0,k.jsx)(j,{variant:`primary`,className:`mt-5 w-full`,loading:s,type:`submit`,children:`Sign in`})]})}function Wc({onDone:e}){let[t,n]=(0,v.useState)(``),[r,i]=(0,v.useState)(``),[a,o]=(0,v.useState)(``),[s,c]=(0,v.useState)(``),[l,u]=(0,v.useState)(),[d,f]=(0,v.useState)(!1);return(0,k.jsx)(`div`,{className:`rings flex min-h-screen items-center justify-center p-6`,children:(0,k.jsxs)(`form`,{className:`w-full max-w-sm animate-rise rounded-2xl border border-line bg-panel p-8 shadow-xl`,onSubmit:async n=>{n.preventDefault(),f(!0),u(void 0);try{await I(`/users`,{method:`POST`,headers:{"X-Argus-Setup-Token":t.trim()},json:{email:r.trim(),name:a.trim()||null,role:`admin`,password:s}}),e()}catch(e){u(e instanceof Ar&&e.status===401?`The setup token is wrong or was already used. Check the server log.`:e.message)}finally{f(!1)}},children:[(0,k.jsxs)(`div`,{className:`mb-6 flex items-center gap-3`,children:[(0,k.jsx)(rr,{size:36}),(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`font-display text-2xl font-semibold`,children:`Set up Argus`}),(0,k.jsx)(`div`,{className:`text-[13px] text-ink-3`,children:`Create the first admin`})]})]}),(0,k.jsxs)(`p`,{className:`mb-4 text-[13px] text-ink-2`,children:[`Argus has no users yet. Paste the one-time setup token printed in the server log, or restart Argus with`,` `,(0,k.jsx)(`code`,{className:`font-mono text-[12px]`,children:`ARGUS_ADMIN_EMAIL`}),` and `,(0,k.jsx)(`code`,{className:`font-mono text-[12px]`,children:`ARGUS_ADMIN_PASSWORD`}),`.`]}),(0,k.jsx)(`label`,{htmlFor:`setup-token`,className:`mb-1.5 block text-[13px] font-medium`,children:`Setup token`}),(0,k.jsx)(M,{id:`setup-token`,autoComplete:`off`,autoFocus:!0,value:t,onChange:e=>n(e.target.value),className:`mb-4 font-mono`}),(0,k.jsx)(`label`,{htmlFor:`setup-email`,className:`mb-1.5 block text-[13px] font-medium`,children:`Email`}),(0,k.jsx)(M,{id:`setup-email`,type:`email`,autoComplete:`username`,value:r,onChange:e=>i(e.target.value),className:`mb-4`}),(0,k.jsxs)(`label`,{htmlFor:`setup-name`,className:`mb-1.5 block text-[13px] font-medium`,children:[`Name `,(0,k.jsx)(`span`,{className:`font-normal text-ink-3`,children:`(optional)`})]}),(0,k.jsx)(M,{id:`setup-name`,autoComplete:`name`,value:a,onChange:e=>o(e.target.value),className:`mb-4`}),(0,k.jsx)(`label`,{htmlFor:`setup-password`,className:`mb-1.5 block text-[13px] font-medium`,children:`Password`}),(0,k.jsx)(M,{id:`setup-password`,type:`password`,autoComplete:`new-password`,minLength:8,value:s,onChange:e=>c(e.target.value)}),(0,k.jsx)(`p`,{className:`mt-1.5 text-[12px] text-ink-3`,children:`At least 8 characters.`}),l&&(0,k.jsx)(`p`,{className:`mt-2 text-[13px] text-critical`,children:l}),(0,k.jsx)(j,{variant:`primary`,className:`mt-5 w-full`,loading:d,type:`submit`,disabled:!t.trim()||!r.trim()||s.length<8,children:`Create admin`})]})})}function Gc({path:e,children:t}){let n=(0,v.useContext)(Lr);return!n||!er(e,n.role??`admin`)?(0,k.jsx)(Qt,{to:`/`,replace:!0}):t}function Kc(){let[e,t]=(0,v.useState)(),[n,r]=(0,v.useState)(),[i,a]=(0,v.useState)(!1),o=(0,v.useCallback)(async()=>{a(!0);try{t(await I(`/auth/me`)),r(void 0)}catch(e){if(e instanceof Ar&&e.status===401){let n=!!e.data?.setupRequired;t(n?{authenticated:!1,passwordRequired:!0,mode:`locked`,setupTokenRequired:!0}:{authenticated:!1,passwordRequired:!0}),r(void 0)}else r(e instanceof Ar?e.message:`The Argus server could not be reached.`)}finally{a(!1)}},[]);if((0,v.useEffect)(()=>{o();let e=()=>{t(e=>e&&{...e,authenticated:!1}),o()};return window.addEventListener(`argus:unauthorized`,e),()=>window.removeEventListener(`argus:unauthorized`,e)},[o]),n&&!e)return(0,k.jsxs)(`div`,{className:`flex min-h-screen flex-col items-center justify-center gap-4 p-6 text-center`,children:[(0,k.jsx)(rr,{size:44}),(0,k.jsxs)(`div`,{children:[(0,k.jsx)(`div`,{className:`font-medium`,children:`Could not reach Argus`}),(0,k.jsx)(`div`,{className:`mt-1 text-[13px] text-ink-3`,children:n})]}),(0,k.jsx)(j,{variant:`primary`,loading:i,onClick:()=>void o(),children:`Retry`})]});if(!e)return(0,k.jsx)(`div`,{className:`flex min-h-screen items-center justify-center`,children:(0,k.jsx)(rr,{size:44,spin:!0})});let s=async()=>{await I(`/auth/logout`,{method:`POST`}),o()};return(0,k.jsx)(Lr.Provider,{value:e,children:(0,k.jsx)(Sr,{children:!e.authenticated&&(e.mode===`locked`||e.setupTokenRequired)?(0,k.jsx)(Wc,{onDone:()=>void o()}):(0,k.jsx)(Bn,{children:(0,k.jsx)(nn,{children:e.authenticated?(0,k.jsxs)(en,{element:(0,k.jsx)(kr,{auth:e,onLogout:()=>void s()}),children:[(0,k.jsx)(en,{index:!0,element:(0,k.jsx)(oi,{})}),(0,k.jsx)(en,{path:`reviews`,element:(0,k.jsx)(vc,{})}),(0,k.jsx)(en,{path:`reviews/:id`,element:(0,k.jsx)(v.Suspense,{fallback:(0,k.jsxs)(`div`,{className:`flex items-center gap-3 p-10 text-ink-3`,children:[(0,k.jsx)(ir,{}),` Loading review…`]}),children:(0,k.jsx)(zc,{})})}),(0,k.jsx)(en,{path:`repositories`,element:(0,k.jsx)(_c,{})}),(0,k.jsx)(en,{path:`repositories/:id`,element:(0,k.jsx)(oc,{})}),(0,k.jsx)(en,{path:`learnings`,element:(0,k.jsx)(xi,{})}),(0,k.jsxs)(en,{element:(0,k.jsx)(Vc,{}),children:[(0,k.jsx)(en,{path:`rules`,element:(0,k.jsx)(yc,{})}),(0,k.jsx)(en,{path:`guidelines`,element:(0,k.jsx)(gi,{})}),(0,k.jsx)(en,{path:`settings/models`,element:(0,k.jsx)(Mc,{})}),(0,k.jsx)(en,{path:`settings/review`,element:(0,k.jsx)(Nc,{})}),(0,k.jsx)(en,{path:`settings/depth`,element:(0,k.jsx)(xc,{})}),(0,k.jsx)(en,{path:`settings/summary`,element:(0,k.jsx)(Ic,{})}),(0,k.jsx)(en,{path:`settings/automation`,element:(0,k.jsx)(bc,{})}),(0,k.jsx)(en,{path:`settings/files`,element:(0,k.jsx)(Sc,{})})]}),(0,k.jsx)(en,{path:`settings/server`,element:(0,k.jsx)(Gc,{path:`/settings/server`,children:(0,k.jsx)(Fc,{})})}),(0,k.jsx)(en,{path:`settings/users`,element:(0,k.jsx)(Gc,{path:`/settings/users`,children:(0,k.jsx)(Rc,{me:e.user??null,onChanged:()=>void o()})})}),(0,k.jsx)(en,{path:`settings`,element:(0,k.jsx)(Qt,{to:`/settings/models`,replace:!0})}),(0,k.jsx)(en,{path:`*`,element:(0,k.jsx)(Qt,{to:`/`,replace:!0})})]}):(0,k.jsx)(en,{path:`*`,element:(0,k.jsx)(Hc,{onDone:()=>void o()})})})})})})}(0,y.createRoot)(document.getElementById(`root`)).render((0,k.jsx)(v.StrictMode,{children:(0,k.jsx)(Kc,{})}));export{o as C,d as S,l as T,wr as _,Pr as a,Vn as b,P as c,ur as d,Tr as f,A as g,mr as h,Nr as i,yr as l,ir as m,zr as n,F as o,fr as p,I as r,j as s,$r as t,vr as u,Cr as v,s as w,At as x,nr as y};