difit 3.1.15 → 3.1.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.ja.md +1 -1
- package/README.ko.md +1 -1
- package/README.md +1 -1
- package/README.zh.md +1 -1
- package/dist/client/assets/_basePickBy-BVuA6jQc.js +1 -0
- package/dist/client/assets/_baseUniq-djtzwinw.js +1 -0
- package/dist/client/assets/arc-BAMbYY65.js +1 -0
- package/dist/client/assets/architectureDiagram-2XIMDMQ5-DE9HunZw.js +36 -0
- package/dist/client/assets/blockDiagram-WCTKOSBZ-BafuvztL.js +132 -0
- package/dist/client/assets/c4Diagram-IC4MRINW-CwBpt4a3.js +10 -0
- package/dist/client/assets/channel-L7OljX7o.js +1 -0
- package/dist/client/assets/chunk-4BX2VUAB-CtCgAIjS.js +1 -0
- package/dist/client/assets/chunk-55IACEB6-D0rr4GYZ.js +1 -0
- package/dist/client/assets/chunk-FMBD7UC4-CFoYhYp3.js +15 -0
- package/dist/client/assets/chunk-JSJVCQXG-D4fFW7sB.js +1 -0
- package/dist/client/assets/chunk-KX2RTZJC-Kr8tlPNp.js +1 -0
- package/dist/client/assets/chunk-NQ4KR5QH-u5zKOXPF.js +220 -0
- package/dist/client/assets/chunk-QZHKN3VN-B6x9J7Ds.js +1 -0
- package/dist/client/assets/chunk-WL4C6EOR-kFVzh4L0.js +189 -0
- package/dist/client/assets/classDiagram-VBA2DB6C-CRDpCvk5.js +1 -0
- package/dist/client/assets/classDiagram-v2-RAHNMMFH-CRDpCvk5.js +1 -0
- package/dist/client/assets/clone-BGci2Dx0.js +1 -0
- package/dist/client/assets/cose-bilkent-S5V4N54A-Dy_rnI7s.js +1 -0
- package/dist/client/assets/cytoscape.esm-5J0xJHOV.js +321 -0
- package/dist/client/assets/dagre-KLK3FWXG-B8WseILQ.js +4 -0
- package/dist/client/assets/defaultLocale-DX6XiGOO.js +1 -0
- package/dist/client/assets/diagram-E7M64L7V-DkfE3QV8.js +24 -0
- package/dist/client/assets/diagram-IFDJBPK2-LLybCWfU.js +43 -0
- package/dist/client/assets/diagram-P4PSJMXO-Th2qIrB0.js +24 -0
- package/dist/client/assets/erDiagram-INFDFZHY-D7LPBy7z.js +70 -0
- package/dist/client/assets/flowDiagram-PKNHOUZH-pyYTtj2D.js +162 -0
- package/dist/client/assets/ganttDiagram-A5KZAMGK-Dv5h9Bsw.js +292 -0
- package/dist/client/assets/gitGraphDiagram-K3NZZRJ6-BDSFQbS9.js +65 -0
- package/dist/client/assets/graph-c8t45xc7.js +1 -0
- package/dist/client/assets/index-C-kmUuqG.js +92 -0
- package/dist/client/assets/{index-BLLDOT1h.css → index-CBGXonij.css} +1 -1
- package/dist/client/assets/infoDiagram-LFFYTUFH-ClzVHwdc.js +2 -0
- package/dist/client/assets/init-Gi6I4Gst.js +1 -0
- package/dist/client/assets/ishikawaDiagram-PHBUUO56-CLuxvi5h.js +70 -0
- package/dist/client/assets/journeyDiagram-4ABVD52K-Ca3qpNBP.js +139 -0
- package/dist/client/assets/kanban-definition-K7BYSVSG-rjz6-vZO.js +89 -0
- package/dist/client/assets/katex-C-M49wc6.js +261 -0
- package/dist/client/assets/layout-C2jzj6qY.js +1 -0
- package/dist/client/assets/linear-BmSVk2NP.js +1 -0
- package/dist/client/assets/mermaid.core-BA0DCisQ.js +249 -0
- package/dist/client/assets/mindmap-definition-YRQLILUH-DvmsmPiL.js +68 -0
- package/dist/client/assets/ordinal-Cboi1Yqb.js +1 -0
- package/dist/client/assets/pieDiagram-SKSYHLDU-CQFtEcCx.js +30 -0
- package/dist/client/assets/{prism-csharp-CZZji5hr.js → prism-csharp-DEYqpNec.js} +1 -1
- package/dist/client/assets/prism-elixir-CM3yUAD8.js +1 -0
- package/dist/client/assets/{prism-hcl-C4BeI84H.js → prism-hcl-BmbK7K1f.js} +1 -1
- package/dist/client/assets/{prism-java-D7yNBm6C.js → prism-java-C_WzYmYM.js} +1 -1
- package/dist/client/assets/{prism-perl-CZI64w6i.js → prism-perl-Dlepj16W.js} +1 -1
- package/dist/client/assets/{prism-php-dNesT8V5.js → prism-php-C5Gn3FAI.js} +1 -1
- package/dist/client/assets/{prism-ruby-D15pg_tm.js → prism-ruby-Bd_tu_g8.js} +1 -1
- package/dist/client/assets/{prism-solidity-BC_GfpO6.js → prism-solidity-DsMBj3dc.js} +1 -1
- package/dist/client/assets/quadrantDiagram-337W2JSQ-D9imLHUm.js +7 -0
- package/dist/client/assets/requirementDiagram-Z7DCOOCP-D7q6ex20.js +73 -0
- package/dist/client/assets/sankeyDiagram-WA2Y5GQK-D_kdhn-o.js +10 -0
- package/dist/client/assets/sequenceDiagram-2WXFIKYE-D4x1rGPT.js +145 -0
- package/dist/client/assets/stateDiagram-RAJIS63D-DteWedWq.js +1 -0
- package/dist/client/assets/stateDiagram-v2-FVOUBMTO-WbkhZc-F.js +1 -0
- package/dist/client/assets/timeline-definition-YZTLITO2-BzTaoSaG.js +61 -0
- package/dist/client/assets/treemap-KZPCXAKY-B9sCJrf0.js +162 -0
- package/dist/client/assets/vennDiagram-LZ73GAT5-9h7-tugo.js +34 -0
- package/dist/client/assets/xychartDiagram-JWTSCODW-DiksRFCI.js +7 -0
- package/dist/client/index.html +2 -2
- package/dist/server/git-diff.js +2 -2
- package/dist/server/git-diff.test.js +14 -0
- package/package.json +6 -5
- package/dist/client/assets/index-jDO2gvEC.js +0 -92
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
function IS(e,r){for(var i=0;i<r.length;i++){const l=r[i];if(typeof l!="string"&&!Array.isArray(l)){for(const o in l)if(o!=="default"&&!(o in e)){const u=Object.getOwnPropertyDescriptor(l,o);u&&Object.defineProperty(e,o,u.get?u:{enumerable:!0,get:()=>l[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))l(o);new MutationObserver(o=>{for(const u of o)if(u.type==="childList")for(const c of u.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&l(c)}).observe(document,{childList:!0,subtree:!0});function i(o){const u={};return o.integrity&&(u.integrity=o.integrity),o.referrerPolicy&&(u.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?u.credentials="include":o.crossOrigin==="anonymous"?u.credentials="omit":u.credentials="same-origin",u}function l(o){if(o.ep)return;o.ep=!0;const u=i(o);fetch(o.href,u)}})();const Xx="data-theme",US={"--color-github-bg-primary":"#0d1117","--color-github-bg-secondary":"#161b22","--color-github-bg-tertiary":"#21262d","--color-github-border":"#30363d","--color-github-text-primary":"#f0f6fc","--color-github-text-secondary":"#8b949e","--color-github-text-muted":"#6e7681","--color-github-accent":"#238636","--color-github-danger":"#da3633","--color-github-warning":"#d29922","--color-diff-addition-bg":"#0d4429","--color-diff-addition-border":"#1b7c3d","--color-diff-deletion-bg":"#67060c","--color-diff-deletion-border":"#da3633","--color-diff-neutral-bg":"#21262d","--color-comment-bg":"#1c2128","--color-comment-border":"#373e47","--color-comment-text":"#e6edf3","--color-yellow-btn-bg":"rgba(180, 83, 9, 0.2)","--color-yellow-btn-border":"rgba(217, 119, 6, 0.5)","--color-yellow-btn-text":"#fbbf24","--color-yellow-btn-hover-bg":"rgba(180, 83, 9, 0.3)","--color-yellow-btn-hover-border":"#d97706","--color-yellow-path-bg":"rgba(180, 83, 9, 0.3)","--color-yellow-path-text":"#fbbf24","--color-editor-btn-bg":"rgba(248, 250, 252, 0.1)","--color-editor-btn-border":"rgba(248, 250, 252, 0.3)","--color-editor-btn-text":"#f0f6fc","--color-editor-btn-hover-bg":"rgba(248, 250, 252, 0.2)","--color-editor-btn-hover-border":"rgba(248, 250, 252, 0.45)"},HS={"--color-github-bg-primary":"#ffffff","--color-github-bg-secondary":"#f6f8fa","--color-github-bg-tertiary":"#f1f3f4","--color-github-border":"#d1d9e0","--color-github-text-primary":"#24292f","--color-github-text-secondary":"#656d76","--color-github-text-muted":"#8c959f","--color-github-accent":"#1f883d","--color-github-danger":"#cf222e","--color-github-warning":"#bf8700","--color-diff-addition-bg":"#d1f4cd","--color-diff-addition-border":"#1f883d","--color-diff-deletion-bg":"#ffd8d3","--color-diff-deletion-border":"#cf222e","--color-diff-neutral-bg":"#f1f3f4","--color-comment-bg":"#fff8e1","--color-comment-border":"#ffd54f","--color-comment-text":"#5d4037","--color-yellow-btn-bg":"#fef3c7","--color-yellow-btn-border":"#f59e0b","--color-yellow-btn-text":"#92400e","--color-yellow-btn-hover-bg":"#fde68a","--color-yellow-btn-hover-border":"#d97706","--color-yellow-path-bg":"#fde68a","--color-yellow-path-text":"#92400e","--color-editor-btn-bg":"rgba(248, 250, 252, 0.1)","--color-editor-btn-border":"rgba(31, 41, 55, 0.35)","--color-editor-btn-text":"#1f2937","--color-editor-btn-hover-bg":"rgba(248, 250, 252, 0.2)","--color-editor-btn-hover-border":"rgba(31, 41, 55, 0.5)"},qS={dark:US,light:HS},Nd="reviewit-appearance-settings",$S=e=>e==="light"||e==="dark"||e==="auto",PS=e=>e==="light"||e==="dark",dh=()=>{if(!(typeof window>"u"))try{return window.localStorage}catch{return}},hh=()=>{if(!(typeof window>"u"))return window};function Zx(e=dh()){if(!e)return null;try{const r=e.getItem(Nd);if(!r)return null;const i=JSON.parse(r);if(i&&typeof i=="object"&&"theme"in i&&$S(i.theme))return i.theme}catch{return null}return null}function ph(e=hh()){return e?.matchMedia("(prefers-color-scheme: dark)").matches??!0?"dark":"light"}function Ms(e,r=ph()){return e==="light"||e==="dark"?e:r}function Fb(e=typeof document>"u"?void 0:document,r=dh(),i=hh()){const l=e?.documentElement.getAttribute(Xx)??null;return PS(l)?l:Ms(Zx(r),ph(i))}function Kx(e,r=document){const i=r.documentElement;i.setAttribute(Xx,e);const l=qS[e];Object.entries(l).forEach(([o,u])=>{i.style.setProperty(o,u)}),r.body&&(r.body.style.backgroundColor="var(--color-github-bg-primary)",r.body.style.color="var(--color-github-text-primary)")}function VS(e=typeof document>"u"?void 0:document,r=dh(),i=hh()){if(!e)return null;const l=Ms(Zx(r),ph(i));return Kx(l,e),l}VS();function lu(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function NR(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var r=e.default;if(typeof r=="function"){var i=function l(){var o=!1;try{o=this instanceof l}catch{}return o?Reflect.construct(r,arguments,this.constructor):r.apply(this,arguments)};i.prototype=r.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(e).forEach(function(l){var o=Object.getOwnPropertyDescriptor(e,l);Object.defineProperty(i,l,o.get?o:{enumerable:!0,get:function(){return e[l]}})}),i}var Of={exports:{}},ja={};var Bb;function GS(){if(Bb)return ja;Bb=1;var e=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function i(l,o,u){var c=null;if(u!==void 0&&(c=""+u),o.key!==void 0&&(c=""+o.key),"key"in o){u={};for(var f in o)f!=="key"&&(u[f]=o[f])}else u=o;return o=u.ref,{$$typeof:e,type:l,key:c,ref:o!==void 0?o:null,props:u}}return ja.Fragment=r,ja.jsx=i,ja.jsxs=i,ja}var Ib;function YS(){return Ib||(Ib=1,Of.exports=GS()),Of.exports}var y=YS(),Mf={exports:{}},Re={};var Ub;function XS(){if(Ub)return Re;Ub=1;var e=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),l=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),u=Symbol.for("react.consumer"),c=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),g=Symbol.for("react.lazy"),b=Symbol.for("react.activity"),v=Symbol.iterator;function x(D){return D===null||typeof D!="object"?null:(D=v&&D[v]||D["@@iterator"],typeof D=="function"?D:null)}var S={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},w=Object.assign,N={};function E(D,q,T){this.props=D,this.context=q,this.refs=N,this.updater=T||S}E.prototype.isReactComponent={},E.prototype.setState=function(D,q){if(typeof D!="object"&&typeof D!="function"&&D!=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,D,q,"setState")},E.prototype.forceUpdate=function(D){this.updater.enqueueForceUpdate(this,D,"forceUpdate")};function C(){}C.prototype=E.prototype;function j(D,q,T){this.props=D,this.context=q,this.refs=N,this.updater=T||S}var z=j.prototype=new C;z.constructor=j,w(z,E.prototype),z.isPureReactComponent=!0;var I=Array.isArray;function L(){}var O={H:null,A:null,T:null,S:null},Z=Object.prototype.hasOwnProperty;function $(D,q,T){var te=T.ref;return{$$typeof:e,type:D,key:q,ref:te!==void 0?te:null,props:T}}function F(D,q){return $(D.type,q,D.props)}function H(D){return typeof D=="object"&&D!==null&&D.$$typeof===e}function G(D){var q={"=":"=0",":":"=2"};return"$"+D.replace(/[=:]/g,function(T){return q[T]})}var Q=/\/+/g;function U(D,q){return typeof D=="object"&&D!==null&&D.key!=null?G(""+D.key):q.toString(36)}function Y(D){switch(D.status){case"fulfilled":return D.value;case"rejected":throw D.reason;default:switch(typeof D.status=="string"?D.then(L,L):(D.status="pending",D.then(function(q){D.status==="pending"&&(D.status="fulfilled",D.value=q)},function(q){D.status==="pending"&&(D.status="rejected",D.reason=q)})),D.status){case"fulfilled":return D.value;case"rejected":throw D.reason}}throw D}function B(D,q,T,te,ie){var fe=typeof D;(fe==="undefined"||fe==="boolean")&&(D=null);var ge=!1;if(D===null)ge=!0;else switch(fe){case"bigint":case"string":case"number":ge=!0;break;case"object":switch(D.$$typeof){case e:case r:ge=!0;break;case g:return ge=D._init,B(ge(D._payload),q,T,te,ie)}}if(ge)return ie=ie(D),ge=te===""?"."+U(D,0):te,I(ie)?(T="",ge!=null&&(T=ge.replace(Q,"$&/")+"/"),B(ie,q,T,"",function(me){return me})):ie!=null&&(H(ie)&&(ie=F(ie,T+(ie.key==null||D&&D.key===ie.key?"":(""+ie.key).replace(Q,"$&/")+"/")+ge)),q.push(ie)),1;ge=0;var ye=te===""?".":te+":";if(I(D))for(var pe=0;pe<D.length;pe++)te=D[pe],fe=ye+U(te,pe),ge+=B(te,q,T,fe,ie);else if(pe=x(D),typeof pe=="function")for(D=pe.call(D),pe=0;!(te=D.next()).done;)te=te.value,fe=ye+U(te,pe++),ge+=B(te,q,T,fe,ie);else if(fe==="object"){if(typeof D.then=="function")return B(Y(D),q,T,te,ie);throw q=String(D),Error("Objects are not valid as a React child (found: "+(q==="[object Object]"?"object with keys {"+Object.keys(D).join(", ")+"}":q)+"). If you meant to render a collection of children, use an array instead.")}return ge}function X(D,q,T){if(D==null)return D;var te=[],ie=0;return B(D,te,"","",function(fe){return q.call(T,fe,ie++)}),te}function M(D){if(D._status===-1){var q=D._result;q=q(),q.then(function(T){(D._status===0||D._status===-1)&&(D._status=1,D._result=T)},function(T){(D._status===0||D._status===-1)&&(D._status=2,D._result=T)}),D._status===-1&&(D._status=0,D._result=q)}if(D._status===1)return D._result.default;throw D._result}var V=typeof reportError=="function"?reportError:function(D){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var q=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof D=="object"&&D!==null&&typeof D.message=="string"?String(D.message):String(D),error:D});if(!window.dispatchEvent(q))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",D);return}console.error(D)},R={map:X,forEach:function(D,q,T){X(D,function(){q.apply(this,arguments)},T)},count:function(D){var q=0;return X(D,function(){q++}),q},toArray:function(D){return X(D,function(q){return q})||[]},only:function(D){if(!H(D))throw Error("React.Children.only expected to receive a single React element child.");return D}};return Re.Activity=b,Re.Children=R,Re.Component=E,Re.Fragment=i,Re.Profiler=o,Re.PureComponent=j,Re.StrictMode=l,Re.Suspense=h,Re.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=O,Re.__COMPILER_RUNTIME={__proto__:null,c:function(D){return O.H.useMemoCache(D)}},Re.cache=function(D){return function(){return D.apply(null,arguments)}},Re.cacheSignal=function(){return null},Re.cloneElement=function(D,q,T){if(D==null)throw Error("The argument must be a React element, but you passed "+D+".");var te=w({},D.props),ie=D.key;if(q!=null)for(fe in q.key!==void 0&&(ie=""+q.key),q)!Z.call(q,fe)||fe==="key"||fe==="__self"||fe==="__source"||fe==="ref"&&q.ref===void 0||(te[fe]=q[fe]);var fe=arguments.length-2;if(fe===1)te.children=T;else if(1<fe){for(var ge=Array(fe),ye=0;ye<fe;ye++)ge[ye]=arguments[ye+2];te.children=ge}return $(D.type,ie,te)},Re.createContext=function(D){return D={$$typeof:c,_currentValue:D,_currentValue2:D,_threadCount:0,Provider:null,Consumer:null},D.Provider=D,D.Consumer={$$typeof:u,_context:D},D},Re.createElement=function(D,q,T){var te,ie={},fe=null;if(q!=null)for(te in q.key!==void 0&&(fe=""+q.key),q)Z.call(q,te)&&te!=="key"&&te!=="__self"&&te!=="__source"&&(ie[te]=q[te]);var ge=arguments.length-2;if(ge===1)ie.children=T;else if(1<ge){for(var ye=Array(ge),pe=0;pe<ge;pe++)ye[pe]=arguments[pe+2];ie.children=ye}if(D&&D.defaultProps)for(te in ge=D.defaultProps,ge)ie[te]===void 0&&(ie[te]=ge[te]);return $(D,fe,ie)},Re.createRef=function(){return{current:null}},Re.forwardRef=function(D){return{$$typeof:f,render:D}},Re.isValidElement=H,Re.lazy=function(D){return{$$typeof:g,_payload:{_status:-1,_result:D},_init:M}},Re.memo=function(D,q){return{$$typeof:p,type:D,compare:q===void 0?null:q}},Re.startTransition=function(D){var q=O.T,T={};O.T=T;try{var te=D(),ie=O.S;ie!==null&&ie(T,te),typeof te=="object"&&te!==null&&typeof te.then=="function"&&te.then(L,V)}catch(fe){V(fe)}finally{q!==null&&T.types!==null&&(q.types=T.types),O.T=q}},Re.unstable_useCacheRefresh=function(){return O.H.useCacheRefresh()},Re.use=function(D){return O.H.use(D)},Re.useActionState=function(D,q,T){return O.H.useActionState(D,q,T)},Re.useCallback=function(D,q){return O.H.useCallback(D,q)},Re.useContext=function(D){return O.H.useContext(D)},Re.useDebugValue=function(){},Re.useDeferredValue=function(D,q){return O.H.useDeferredValue(D,q)},Re.useEffect=function(D,q){return O.H.useEffect(D,q)},Re.useEffectEvent=function(D){return O.H.useEffectEvent(D)},Re.useId=function(){return O.H.useId()},Re.useImperativeHandle=function(D,q,T){return O.H.useImperativeHandle(D,q,T)},Re.useInsertionEffect=function(D,q){return O.H.useInsertionEffect(D,q)},Re.useLayoutEffect=function(D,q){return O.H.useLayoutEffect(D,q)},Re.useMemo=function(D,q){return O.H.useMemo(D,q)},Re.useOptimistic=function(D,q){return O.H.useOptimistic(D,q)},Re.useReducer=function(D,q,T){return O.H.useReducer(D,q,T)},Re.useRef=function(D){return O.H.useRef(D)},Re.useState=function(D){return O.H.useState(D)},Re.useSyncExternalStore=function(D,q,T){return O.H.useSyncExternalStore(D,q,T)},Re.useTransition=function(){return O.H.useTransition()},Re.version="19.2.4",Re}var Hb;function mh(){return Hb||(Hb=1,Mf.exports=XS()),Mf.exports}var A=mh();const Qt=lu(A),Qx=IS({__proto__:null,default:Qt},[A]);var zf={exports:{}},Ra={},Ff={exports:{}},Bf={};var qb;function ZS(){return qb||(qb=1,(function(e){function r(B,X){var M=B.length;B.push(X);e:for(;0<M;){var V=M-1>>>1,R=B[V];if(0<o(R,X))B[V]=X,B[M]=R,M=V;else break e}}function i(B){return B.length===0?null:B[0]}function l(B){if(B.length===0)return null;var X=B[0],M=B.pop();if(M!==X){B[0]=M;e:for(var V=0,R=B.length,D=R>>>1;V<D;){var q=2*(V+1)-1,T=B[q],te=q+1,ie=B[te];if(0>o(T,M))te<R&&0>o(ie,T)?(B[V]=ie,B[te]=M,V=te):(B[V]=T,B[q]=M,V=q);else if(te<R&&0>o(ie,M))B[V]=ie,B[te]=M,V=te;else break e}}return X}function o(B,X){var M=B.sortIndex-X.sortIndex;return M!==0?M:B.id-X.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var u=performance;e.unstable_now=function(){return u.now()}}else{var c=Date,f=c.now();e.unstable_now=function(){return c.now()-f}}var h=[],p=[],g=1,b=null,v=3,x=!1,S=!1,w=!1,N=!1,E=typeof setTimeout=="function"?setTimeout:null,C=typeof clearTimeout=="function"?clearTimeout:null,j=typeof setImmediate<"u"?setImmediate:null;function z(B){for(var X=i(p);X!==null;){if(X.callback===null)l(p);else if(X.startTime<=B)l(p),X.sortIndex=X.expirationTime,r(h,X);else break;X=i(p)}}function I(B){if(w=!1,z(B),!S)if(i(h)!==null)S=!0,L||(L=!0,G());else{var X=i(p);X!==null&&Y(I,X.startTime-B)}}var L=!1,O=-1,Z=5,$=-1;function F(){return N?!0:!(e.unstable_now()-$<Z)}function H(){if(N=!1,L){var B=e.unstable_now();$=B;var X=!0;try{e:{S=!1,w&&(w=!1,C(O),O=-1),x=!0;var M=v;try{t:{for(z(B),b=i(h);b!==null&&!(b.expirationTime>B&&F());){var V=b.callback;if(typeof V=="function"){b.callback=null,v=b.priorityLevel;var R=V(b.expirationTime<=B);if(B=e.unstable_now(),typeof R=="function"){b.callback=R,z(B),X=!0;break t}b===i(h)&&l(h),z(B)}else l(h);b=i(h)}if(b!==null)X=!0;else{var D=i(p);D!==null&&Y(I,D.startTime-B),X=!1}}break e}finally{b=null,v=M,x=!1}X=void 0}}finally{X?G():L=!1}}}var G;if(typeof j=="function")G=function(){j(H)};else if(typeof MessageChannel<"u"){var Q=new MessageChannel,U=Q.port2;Q.port1.onmessage=H,G=function(){U.postMessage(null)}}else G=function(){E(H,0)};function Y(B,X){O=E(function(){B(e.unstable_now())},X)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(B){B.callback=null},e.unstable_forceFrameRate=function(B){0>B||125<B?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Z=0<B?Math.floor(1e3/B):5},e.unstable_getCurrentPriorityLevel=function(){return v},e.unstable_next=function(B){switch(v){case 1:case 2:case 3:var X=3;break;default:X=v}var M=v;v=X;try{return B()}finally{v=M}},e.unstable_requestPaint=function(){N=!0},e.unstable_runWithPriority=function(B,X){switch(B){case 1:case 2:case 3:case 4:case 5:break;default:B=3}var M=v;v=B;try{return X()}finally{v=M}},e.unstable_scheduleCallback=function(B,X,M){var V=e.unstable_now();switch(typeof M=="object"&&M!==null?(M=M.delay,M=typeof M=="number"&&0<M?V+M:V):M=V,B){case 1:var R=-1;break;case 2:R=250;break;case 5:R=1073741823;break;case 4:R=1e4;break;default:R=5e3}return R=M+R,B={id:g++,callback:X,priorityLevel:B,startTime:M,expirationTime:R,sortIndex:-1},M>V?(B.sortIndex=M,r(p,B),i(h)===null&&B===i(p)&&(w?(C(O),O=-1):w=!0,Y(I,M-V))):(B.sortIndex=R,r(h,B),S||x||(S=!0,L||(L=!0,G()))),B},e.unstable_shouldYield=F,e.unstable_wrapCallback=function(B){var X=v;return function(){var M=v;v=X;try{return B.apply(this,arguments)}finally{v=M}}}})(Bf)),Bf}var $b;function KS(){return $b||($b=1,Ff.exports=ZS()),Ff.exports}var If={exports:{}},Ht={};var Pb;function QS(){if(Pb)return Ht;Pb=1;var e=mh();function r(h){var p="https://react.dev/errors/"+h;if(1<arguments.length){p+="?args[]="+encodeURIComponent(arguments[1]);for(var g=2;g<arguments.length;g++)p+="&args[]="+encodeURIComponent(arguments[g])}return"Minified React error #"+h+"; visit "+p+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(){}var l={d:{f:i,r:function(){throw Error(r(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},o=Symbol.for("react.portal");function u(h,p,g){var b=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:o,key:b==null?null:""+b,children:h,containerInfo:p,implementation:g}}var c=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function f(h,p){if(h==="font")return"";if(typeof p=="string")return p==="use-credentials"?p:""}return Ht.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=l,Ht.createPortal=function(h,p){var g=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!p||p.nodeType!==1&&p.nodeType!==9&&p.nodeType!==11)throw Error(r(299));return u(h,p,null,g)},Ht.flushSync=function(h){var p=c.T,g=l.p;try{if(c.T=null,l.p=2,h)return h()}finally{c.T=p,l.p=g,l.d.f()}},Ht.preconnect=function(h,p){typeof h=="string"&&(p?(p=p.crossOrigin,p=typeof p=="string"?p==="use-credentials"?p:"":void 0):p=null,l.d.C(h,p))},Ht.prefetchDNS=function(h){typeof h=="string"&&l.d.D(h)},Ht.preinit=function(h,p){if(typeof h=="string"&&p&&typeof p.as=="string"){var g=p.as,b=f(g,p.crossOrigin),v=typeof p.integrity=="string"?p.integrity:void 0,x=typeof p.fetchPriority=="string"?p.fetchPriority:void 0;g==="style"?l.d.S(h,typeof p.precedence=="string"?p.precedence:void 0,{crossOrigin:b,integrity:v,fetchPriority:x}):g==="script"&&l.d.X(h,{crossOrigin:b,integrity:v,fetchPriority:x,nonce:typeof p.nonce=="string"?p.nonce:void 0})}},Ht.preinitModule=function(h,p){if(typeof h=="string")if(typeof p=="object"&&p!==null){if(p.as==null||p.as==="script"){var g=f(p.as,p.crossOrigin);l.d.M(h,{crossOrigin:g,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0})}}else p==null&&l.d.M(h)},Ht.preload=function(h,p){if(typeof h=="string"&&typeof p=="object"&&p!==null&&typeof p.as=="string"){var g=p.as,b=f(g,p.crossOrigin);l.d.L(h,g,{crossOrigin:b,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0,type:typeof p.type=="string"?p.type:void 0,fetchPriority:typeof p.fetchPriority=="string"?p.fetchPriority:void 0,referrerPolicy:typeof p.referrerPolicy=="string"?p.referrerPolicy:void 0,imageSrcSet:typeof p.imageSrcSet=="string"?p.imageSrcSet:void 0,imageSizes:typeof p.imageSizes=="string"?p.imageSizes:void 0,media:typeof p.media=="string"?p.media:void 0})}},Ht.preloadModule=function(h,p){if(typeof h=="string")if(p){var g=f(p.as,p.crossOrigin);l.d.m(h,{as:typeof p.as=="string"&&p.as!=="script"?p.as:void 0,crossOrigin:g,integrity:typeof p.integrity=="string"?p.integrity:void 0})}else l.d.m(h)},Ht.requestFormReset=function(h){l.d.r(h)},Ht.unstable_batchedUpdates=function(h,p){return h(p)},Ht.useFormState=function(h,p,g){return c.H.useFormState(h,p,g)},Ht.useFormStatus=function(){return c.H.useHostTransitionStatus()},Ht.version="19.2.4",Ht}var Vb;function Jx(){if(Vb)return If.exports;Vb=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(r){console.error(r)}}return e(),If.exports=QS(),If.exports}var Gb;function JS(){if(Gb)return Ra;Gb=1;var e=KS(),r=mh(),i=Jx();function l(t){var n="https://react.dev/errors/"+t;if(1<arguments.length){n+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)n+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+t+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function u(t){var n=t,a=t;if(t.alternate)for(;n.return;)n=n.return;else{t=n;do n=t,(n.flags&4098)!==0&&(a=n.return),t=n.return;while(t)}return n.tag===3?a:null}function c(t){if(t.tag===13){var n=t.memoizedState;if(n===null&&(t=t.alternate,t!==null&&(n=t.memoizedState)),n!==null)return n.dehydrated}return null}function f(t){if(t.tag===31){var n=t.memoizedState;if(n===null&&(t=t.alternate,t!==null&&(n=t.memoizedState)),n!==null)return n.dehydrated}return null}function h(t){if(u(t)!==t)throw Error(l(188))}function p(t){var n=t.alternate;if(!n){if(n=u(t),n===null)throw Error(l(188));return n!==t?null:t}for(var a=t,s=n;;){var d=a.return;if(d===null)break;var m=d.alternate;if(m===null){if(s=d.return,s!==null){a=s;continue}break}if(d.child===m.child){for(m=d.child;m;){if(m===a)return h(d),t;if(m===s)return h(d),n;m=m.sibling}throw Error(l(188))}if(a.return!==s.return)a=d,s=m;else{for(var k=!1,_=d.child;_;){if(_===a){k=!0,a=d,s=m;break}if(_===s){k=!0,s=d,a=m;break}_=_.sibling}if(!k){for(_=m.child;_;){if(_===a){k=!0,a=m,s=d;break}if(_===s){k=!0,s=m,a=d;break}_=_.sibling}if(!k)throw Error(l(189))}}if(a.alternate!==s)throw Error(l(190))}if(a.tag!==3)throw Error(l(188));return a.stateNode.current===a?t:n}function g(t){var n=t.tag;if(n===5||n===26||n===27||n===6)return t;for(t=t.child;t!==null;){if(n=g(t),n!==null)return n;t=t.sibling}return null}var b=Object.assign,v=Symbol.for("react.element"),x=Symbol.for("react.transitional.element"),S=Symbol.for("react.portal"),w=Symbol.for("react.fragment"),N=Symbol.for("react.strict_mode"),E=Symbol.for("react.profiler"),C=Symbol.for("react.consumer"),j=Symbol.for("react.context"),z=Symbol.for("react.forward_ref"),I=Symbol.for("react.suspense"),L=Symbol.for("react.suspense_list"),O=Symbol.for("react.memo"),Z=Symbol.for("react.lazy"),$=Symbol.for("react.activity"),F=Symbol.for("react.memo_cache_sentinel"),H=Symbol.iterator;function G(t){return t===null||typeof t!="object"?null:(t=H&&t[H]||t["@@iterator"],typeof t=="function"?t:null)}var Q=Symbol.for("react.client.reference");function U(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===Q?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case w:return"Fragment";case E:return"Profiler";case N:return"StrictMode";case I:return"Suspense";case L:return"SuspenseList";case $:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case S:return"Portal";case j:return t.displayName||"Context";case C:return(t._context.displayName||"Context")+".Consumer";case z:var n=t.render;return t=t.displayName,t||(t=n.displayName||n.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case O:return n=t.displayName||null,n!==null?n:U(t.type)||"Memo";case Z:n=t._payload,t=t._init;try{return U(t(n))}catch{}}return null}var Y=Array.isArray,B=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,X=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,M={pending:!1,data:null,method:null,action:null},V=[],R=-1;function D(t){return{current:t}}function q(t){0>R||(t.current=V[R],V[R]=null,R--)}function T(t,n){R++,V[R]=t.current,t.current=n}var te=D(null),ie=D(null),fe=D(null),ge=D(null);function ye(t,n){switch(T(fe,n),T(ie,t),T(te,null),n.nodeType){case 9:case 11:t=(t=n.documentElement)&&(t=t.namespaceURI)?ab(t):0;break;default:if(t=n.tagName,n=n.namespaceURI)n=ab(n),t=ob(n,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}q(te),T(te,t)}function pe(){q(te),q(ie),q(fe)}function me(t){t.memoizedState!==null&&T(ge,t);var n=te.current,a=ob(n,t.type);n!==a&&(T(ie,t),T(te,a))}function xe(t){ie.current===t&&(q(te),q(ie)),ge.current===t&&(q(ge),Ca._currentValue=M)}var de,we;function Ee(t){if(de===void 0)try{throw Error()}catch(a){var n=a.stack.trim().match(/\n( *(at )?)/);de=n&&n[1]||"",we=-1<a.stack.indexOf(`
|
|
2
|
+
at`)?" (<anonymous>)":-1<a.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
3
|
+
`+de+t+we}var Pe=!1;function Ke(t,n){if(!t||Pe)return"";Pe=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var s={DetermineComponentFrameRoot:function(){try{if(n){var ce=function(){throw Error()};if(Object.defineProperty(ce.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(ce,[])}catch(le){var ne=le}Reflect.construct(t,[],ce)}else{try{ce.call()}catch(le){ne=le}t.call(ce.prototype)}}else{try{throw Error()}catch(le){ne=le}(ce=t())&&typeof ce.catch=="function"&&ce.catch(function(){})}}catch(le){if(le&&ne&&typeof le.stack=="string")return[le.stack,ne.stack]}return[null,null]}};s.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var d=Object.getOwnPropertyDescriptor(s.DetermineComponentFrameRoot,"name");d&&d.configurable&&Object.defineProperty(s.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var m=s.DetermineComponentFrameRoot(),k=m[0],_=m[1];if(k&&_){var P=k.split(`
|
|
4
|
+
`),ee=_.split(`
|
|
5
|
+
`);for(d=s=0;s<P.length&&!P[s].includes("DetermineComponentFrameRoot");)s++;for(;d<ee.length&&!ee[d].includes("DetermineComponentFrameRoot");)d++;if(s===P.length||d===ee.length)for(s=P.length-1,d=ee.length-1;1<=s&&0<=d&&P[s]!==ee[d];)d--;for(;1<=s&&0<=d;s--,d--)if(P[s]!==ee[d]){if(s!==1||d!==1)do if(s--,d--,0>d||P[s]!==ee[d]){var oe=`
|
|
6
|
+
`+P[s].replace(" at new "," at ");return t.displayName&&oe.includes("<anonymous>")&&(oe=oe.replace("<anonymous>",t.displayName)),oe}while(1<=s&&0<=d);break}}}finally{Pe=!1,Error.prepareStackTrace=a}return(a=t?t.displayName||t.name:"")?Ee(a):""}function Me(t,n){switch(t.tag){case 26:case 27:case 5:return Ee(t.type);case 16:return Ee("Lazy");case 13:return t.child!==n&&n!==null?Ee("Suspense Fallback"):Ee("Suspense");case 19:return Ee("SuspenseList");case 0:case 15:return Ke(t.type,!1);case 11:return Ke(t.type.render,!1);case 1:return Ke(t.type,!0);case 31:return Ee("Activity");default:return""}}function It(t){try{var n="",a=null;do n+=Me(t,a),a=t,t=t.return;while(t);return n}catch(s){return`
|
|
7
|
+
Error generating stack: `+s.message+`
|
|
8
|
+
`+s.stack}}var pt=Object.prototype.hasOwnProperty,mt=e.unstable_scheduleCallback,Gt=e.unstable_cancelCallback,Yt=e.unstable_shouldYield,tt=e.unstable_requestPaint,at=e.unstable_now,nr=e.unstable_getCurrentPriorityLevel,ae=e.unstable_ImmediatePriority,be=e.unstable_UserBlockingPriority,Te=e.unstable_NormalPriority,Oe=e.unstable_LowPriority,Ve=e.unstable_IdlePriority,Dt=e.log,zn=e.unstable_setDisableYieldValue,Ot=null,gt=null;function Ut(t){if(typeof Dt=="function"&&zn(t),gt&&typeof gt.setStrictMode=="function")try{gt.setStrictMode(Ot,t)}catch{}}var Je=Math.clz32?Math.clz32:Fl,$n=Math.log,fn=Math.LN2;function Fl(t){return t>>>=0,t===0?32:31-($n(t)/fn|0)|0}var Ar=256,Ii=262144,Tr=4194304;function Fn(t){var n=t&42;if(n!==0)return n;switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function jr(t,n,a){var s=t.pendingLanes;if(s===0)return 0;var d=0,m=t.suspendedLanes,k=t.pingedLanes;t=t.warmLanes;var _=s&134217727;return _!==0?(s=_&~m,s!==0?d=Fn(s):(k&=_,k!==0?d=Fn(k):a||(a=_&~t,a!==0&&(d=Fn(a))))):(_=s&~m,_!==0?d=Fn(_):k!==0?d=Fn(k):a||(a=s&~t,a!==0&&(d=Fn(a)))),d===0?0:n!==0&&n!==d&&(n&m)===0&&(m=d&-d,a=n&-n,m>=a||m===32&&(a&4194048)!==0)?n:d}function Pn(t,n){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&n)===0}function Eu(t,n){switch(t){case 1:case 2:case 4:case 8:case 64:return n+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 n+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 Bl(){var t=Tr;return Tr<<=1,(Tr&62914560)===0&&(Tr=4194304),t}function fi(t){for(var n=[],a=0;31>a;a++)n.push(t);return n}function di(t,n){t.pendingLanes|=n,n!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function ro(t,n,a,s,d,m){var k=t.pendingLanes;t.pendingLanes=a,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=a,t.entangledLanes&=a,t.errorRecoveryDisabledLanes&=a,t.shellSuspendCounter=0;var _=t.entanglements,P=t.expirationTimes,ee=t.hiddenUpdates;for(a=k&~a;0<a;){var oe=31-Je(a),ce=1<<oe;_[oe]=0,P[oe]=-1;var ne=ee[oe];if(ne!==null)for(ee[oe]=null,oe=0;oe<ne.length;oe++){var le=ne[oe];le!==null&&(le.lane&=-536870913)}a&=~ce}s!==0&&Il(t,s,0),m!==0&&d===0&&t.tag!==0&&(t.suspendedLanes|=m&~(k&~n))}function Il(t,n,a){t.pendingLanes|=n,t.suspendedLanes&=~n;var s=31-Je(n);t.entangledLanes|=n,t.entanglements[s]=t.entanglements[s]|1073741824|a&261930}function Jt(t,n){var a=t.entangledLanes|=n;for(t=t.entanglements;a;){var s=31-Je(a),d=1<<s;d&n|t[s]&n&&(t[s]|=n),a&=~d}}function io(t,n){var a=n&-n;return a=(a&42)!==0?1:Ui(a),(a&(t.suspendedLanes|n))!==0?0:a}function Ui(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function Vn(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function lo(){var t=X.p;return t!==0?t:(t=window.event,t===void 0?32:Rb(t.type))}function ao(t,n){var a=X.p;try{return X.p=t,n()}finally{X.p=a}}var Gn=Math.random().toString(36).slice(2),Tt="__reactFiber$"+Gn,wt="__reactProps$"+Gn,rr="__reactContainer$"+Gn,Hi="__reactEvents$"+Gn,Cu="__reactListeners$"+Gn,Ul="__reactHandles$"+Gn,oo="__reactResources$"+Gn,hi="__reactMarker$"+Gn;function Hl(t){delete t[Tt],delete t[wt],delete t[Hi],delete t[Cu],delete t[Ul]}function Rr(t){var n=t[Tt];if(n)return n;for(var a=t.parentNode;a;){if(n=a[rr]||a[Tt]){if(a=n.alternate,n.child!==null||a!==null&&a.child!==null)for(t=pb(t);t!==null;){if(a=t[Tt])return a;t=pb(t)}return n}t=a,a=t.parentNode}return null}function _r(t){if(t=t[Tt]||t[rr]){var n=t.tag;if(n===5||n===6||n===13||n===31||n===26||n===27||n===3)return t}return null}function re(t){var n=t.tag;if(n===5||n===26||n===27||n===6)return t.stateNode;throw Error(l(33))}function ve(t){var n=t[oo];return n||(n=t[oo]={hoistableStyles:new Map,hoistableScripts:new Map}),n}function Se(t){t[hi]=!0}var Qe=new Set,Ie={};function St(t,n){Bn(t,n),Bn(t+"Capture",n)}function Bn(t,n){for(Ie[t]=n,t=0;t<n.length;t++)Qe.add(n[t])}var Rv=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]*$"),Kh={},Qh={};function _v(t){return pt.call(Qh,t)?!0:pt.call(Kh,t)?!1:Rv.test(t)?Qh[t]=!0:(Kh[t]=!0,!1)}function so(t,n,a){if(_v(n))if(a===null)t.removeAttribute(n);else{switch(typeof a){case"undefined":case"function":case"symbol":t.removeAttribute(n);return;case"boolean":var s=n.toLowerCase().slice(0,5);if(s!=="data-"&&s!=="aria-"){t.removeAttribute(n);return}}t.setAttribute(n,""+a)}}function uo(t,n,a){if(a===null)t.removeAttribute(n);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(n);return}t.setAttribute(n,""+a)}}function ir(t,n,a,s){if(s===null)t.removeAttribute(a);else{switch(typeof s){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(a);return}t.setAttributeNS(n,a,""+s)}}function En(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function Jh(t){var n=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function Lv(t,n,a){var s=Object.getOwnPropertyDescriptor(t.constructor.prototype,n);if(!t.hasOwnProperty(n)&&typeof s<"u"&&typeof s.get=="function"&&typeof s.set=="function"){var d=s.get,m=s.set;return Object.defineProperty(t,n,{configurable:!0,get:function(){return d.call(this)},set:function(k){a=""+k,m.call(this,k)}}),Object.defineProperty(t,n,{enumerable:s.enumerable}),{getValue:function(){return a},setValue:function(k){a=""+k},stopTracking:function(){t._valueTracker=null,delete t[n]}}}}function Nu(t){if(!t._valueTracker){var n=Jh(t)?"checked":"value";t._valueTracker=Lv(t,n,""+t[n])}}function Wh(t){if(!t)return!1;var n=t._valueTracker;if(!n)return!0;var a=n.getValue(),s="";return t&&(s=Jh(t)?t.checked?"true":"false":t.value),t=s,t!==a?(n.setValue(t),!0):!1}function co(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var Dv=/[\n"\\]/g;function Cn(t){return t.replace(Dv,function(n){return"\\"+n.charCodeAt(0).toString(16)+" "})}function Au(t,n,a,s,d,m,k,_){t.name="",k!=null&&typeof k!="function"&&typeof k!="symbol"&&typeof k!="boolean"?t.type=k:t.removeAttribute("type"),n!=null?k==="number"?(n===0&&t.value===""||t.value!=n)&&(t.value=""+En(n)):t.value!==""+En(n)&&(t.value=""+En(n)):k!=="submit"&&k!=="reset"||t.removeAttribute("value"),n!=null?Tu(t,k,En(n)):a!=null?Tu(t,k,En(a)):s!=null&&t.removeAttribute("value"),d==null&&m!=null&&(t.defaultChecked=!!m),d!=null&&(t.checked=d&&typeof d!="function"&&typeof d!="symbol"),_!=null&&typeof _!="function"&&typeof _!="symbol"&&typeof _!="boolean"?t.name=""+En(_):t.removeAttribute("name")}function ep(t,n,a,s,d,m,k,_){if(m!=null&&typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"&&(t.type=m),n!=null||a!=null){if(!(m!=="submit"&&m!=="reset"||n!=null)){Nu(t);return}a=a!=null?""+En(a):"",n=n!=null?""+En(n):a,_||n===t.value||(t.value=n),t.defaultValue=n}s=s??d,s=typeof s!="function"&&typeof s!="symbol"&&!!s,t.checked=_?t.checked:!!s,t.defaultChecked=!!s,k!=null&&typeof k!="function"&&typeof k!="symbol"&&typeof k!="boolean"&&(t.name=k),Nu(t)}function Tu(t,n,a){n==="number"&&co(t.ownerDocument)===t||t.defaultValue===""+a||(t.defaultValue=""+a)}function qi(t,n,a,s){if(t=t.options,n){n={};for(var d=0;d<a.length;d++)n["$"+a[d]]=!0;for(a=0;a<t.length;a++)d=n.hasOwnProperty("$"+t[a].value),t[a].selected!==d&&(t[a].selected=d),d&&s&&(t[a].defaultSelected=!0)}else{for(a=""+En(a),n=null,d=0;d<t.length;d++){if(t[d].value===a){t[d].selected=!0,s&&(t[d].defaultSelected=!0);return}n!==null||t[d].disabled||(n=t[d])}n!==null&&(n.selected=!0)}}function tp(t,n,a){if(n!=null&&(n=""+En(n),n!==t.value&&(t.value=n),a==null)){t.defaultValue!==n&&(t.defaultValue=n);return}t.defaultValue=a!=null?""+En(a):""}function np(t,n,a,s){if(n==null){if(s!=null){if(a!=null)throw Error(l(92));if(Y(s)){if(1<s.length)throw Error(l(93));s=s[0]}a=s}a==null&&(a=""),n=a}a=En(n),t.defaultValue=a,s=t.textContent,s===a&&s!==""&&s!==null&&(t.value=s),Nu(t)}function $i(t,n){if(n){var a=t.firstChild;if(a&&a===t.lastChild&&a.nodeType===3){a.nodeValue=n;return}}t.textContent=n}var Ov=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 rp(t,n,a){var s=n.indexOf("--")===0;a==null||typeof a=="boolean"||a===""?s?t.setProperty(n,""):n==="float"?t.cssFloat="":t[n]="":s?t.setProperty(n,a):typeof a!="number"||a===0||Ov.has(n)?n==="float"?t.cssFloat=a:t[n]=(""+a).trim():t[n]=a+"px"}function ip(t,n,a){if(n!=null&&typeof n!="object")throw Error(l(62));if(t=t.style,a!=null){for(var s in a)!a.hasOwnProperty(s)||n!=null&&n.hasOwnProperty(s)||(s.indexOf("--")===0?t.setProperty(s,""):s==="float"?t.cssFloat="":t[s]="");for(var d in n)s=n[d],n.hasOwnProperty(d)&&a[d]!==s&&rp(t,d,s)}else for(var m in n)n.hasOwnProperty(m)&&rp(t,m,n[m])}function ju(t){if(t.indexOf("-")===-1)return!1;switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Mv=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),zv=/^[\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 fo(t){return zv.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function lr(){}var Ru=null;function _u(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var Pi=null,Vi=null;function lp(t){var n=_r(t);if(n&&(t=n.stateNode)){var a=t[wt]||null;e:switch(t=n.stateNode,n.type){case"input":if(Au(t,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name),n=a.name,a.type==="radio"&&n!=null){for(a=t;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll('input[name="'+Cn(""+n)+'"][type="radio"]'),n=0;n<a.length;n++){var s=a[n];if(s!==t&&s.form===t.form){var d=s[wt]||null;if(!d)throw Error(l(90));Au(s,d.value,d.defaultValue,d.defaultValue,d.checked,d.defaultChecked,d.type,d.name)}}for(n=0;n<a.length;n++)s=a[n],s.form===t.form&&Wh(s)}break e;case"textarea":tp(t,a.value,a.defaultValue);break e;case"select":n=a.value,n!=null&&qi(t,!!a.multiple,n,!1)}}}var Lu=!1;function ap(t,n,a){if(Lu)return t(n,a);Lu=!0;try{var s=t(n);return s}finally{if(Lu=!1,(Pi!==null||Vi!==null)&&(Wo(),Pi&&(n=Pi,t=Vi,Vi=Pi=null,lp(n),t)))for(n=0;n<t.length;n++)lp(t[n])}}function ql(t,n){var a=t.stateNode;if(a===null)return null;var s=a[wt]||null;if(s===null)return null;a=s[n];e:switch(n){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(s=!s.disabled)||(t=t.type,s=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!s;break e;default:t=!1}if(t)return null;if(a&&typeof a!="function")throw Error(l(231,n,typeof a));return a}var ar=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Du=!1;if(ar)try{var $l={};Object.defineProperty($l,"passive",{get:function(){Du=!0}}),window.addEventListener("test",$l,$l),window.removeEventListener("test",$l,$l)}catch{Du=!1}var Lr=null,Ou=null,ho=null;function op(){if(ho)return ho;var t,n=Ou,a=n.length,s,d="value"in Lr?Lr.value:Lr.textContent,m=d.length;for(t=0;t<a&&n[t]===d[t];t++);var k=a-t;for(s=1;s<=k&&n[a-s]===d[m-s];s++);return ho=d.slice(t,1<s?1-s:void 0)}function po(t){var n=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&n===13&&(t=13)):t=n,t===10&&(t=13),32<=t||t===13?t:0}function mo(){return!0}function sp(){return!1}function Wt(t){function n(a,s,d,m,k){this._reactName=a,this._targetInst=d,this.type=s,this.nativeEvent=m,this.target=k,this.currentTarget=null;for(var _ in t)t.hasOwnProperty(_)&&(a=t[_],this[_]=a?a(m):m[_]);return this.isDefaultPrevented=(m.defaultPrevented!=null?m.defaultPrevented:m.returnValue===!1)?mo:sp,this.isPropagationStopped=sp,this}return b(n.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():typeof a.returnValue!="unknown"&&(a.returnValue=!1),this.isDefaultPrevented=mo)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=mo)},persist:function(){},isPersistent:mo}),n}var pi={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},go=Wt(pi),Pl=b({},pi,{view:0,detail:0}),Fv=Wt(Pl),Mu,zu,Vl,bo=b({},Pl,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Bu,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Vl&&(Vl&&t.type==="mousemove"?(Mu=t.screenX-Vl.screenX,zu=t.screenY-Vl.screenY):zu=Mu=0,Vl=t),Mu)},movementY:function(t){return"movementY"in t?t.movementY:zu}}),up=Wt(bo),Bv=b({},bo,{dataTransfer:0}),Iv=Wt(Bv),Uv=b({},Pl,{relatedTarget:0}),Fu=Wt(Uv),Hv=b({},pi,{animationName:0,elapsedTime:0,pseudoElement:0}),qv=Wt(Hv),$v=b({},pi,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),Pv=Wt($v),Vv=b({},pi,{data:0}),cp=Wt(Vv),Gv={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Yv={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"},Xv={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Zv(t){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(t):(t=Xv[t])?!!n[t]:!1}function Bu(){return Zv}var Kv=b({},Pl,{key:function(t){if(t.key){var n=Gv[t.key]||t.key;if(n!=="Unidentified")return n}return t.type==="keypress"?(t=po(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?Yv[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Bu,charCode:function(t){return t.type==="keypress"?po(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?po(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),Qv=Wt(Kv),Jv=b({},bo,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),fp=Wt(Jv),Wv=b({},Pl,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Bu}),ew=Wt(Wv),tw=b({},pi,{propertyName:0,elapsedTime:0,pseudoElement:0}),nw=Wt(tw),rw=b({},bo,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),iw=Wt(rw),lw=b({},pi,{newState:0,oldState:0}),aw=Wt(lw),ow=[9,13,27,32],Iu=ar&&"CompositionEvent"in window,Gl=null;ar&&"documentMode"in document&&(Gl=document.documentMode);var sw=ar&&"TextEvent"in window&&!Gl,dp=ar&&(!Iu||Gl&&8<Gl&&11>=Gl),hp=" ",pp=!1;function mp(t,n){switch(t){case"keyup":return ow.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function gp(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Gi=!1;function uw(t,n){switch(t){case"compositionend":return gp(n);case"keypress":return n.which!==32?null:(pp=!0,hp);case"textInput":return t=n.data,t===hp&&pp?null:t;default:return null}}function cw(t,n){if(Gi)return t==="compositionend"||!Iu&&mp(t,n)?(t=op(),ho=Ou=Lr=null,Gi=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(n.ctrlKey||n.altKey||n.metaKey)||n.ctrlKey&&n.altKey){if(n.char&&1<n.char.length)return n.char;if(n.which)return String.fromCharCode(n.which)}return null;case"compositionend":return dp&&n.locale!=="ko"?null:n.data;default:return null}}var fw={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 bp(t){var n=t&&t.nodeName&&t.nodeName.toLowerCase();return n==="input"?!!fw[t.type]:n==="textarea"}function yp(t,n,a,s){Pi?Vi?Vi.push(s):Vi=[s]:Pi=s,n=as(n,"onChange"),0<n.length&&(a=new go("onChange","change",null,a,s),t.push({event:a,listeners:n}))}var Yl=null,Xl=null;function dw(t){eb(t,0)}function yo(t){var n=re(t);if(Wh(n))return t}function xp(t,n){if(t==="change")return n}var vp=!1;if(ar){var Uu;if(ar){var Hu="oninput"in document;if(!Hu){var wp=document.createElement("div");wp.setAttribute("oninput","return;"),Hu=typeof wp.oninput=="function"}Uu=Hu}else Uu=!1;vp=Uu&&(!document.documentMode||9<document.documentMode)}function Sp(){Yl&&(Yl.detachEvent("onpropertychange",kp),Xl=Yl=null)}function kp(t){if(t.propertyName==="value"&&yo(Xl)){var n=[];yp(n,Xl,t,_u(t)),ap(dw,n)}}function hw(t,n,a){t==="focusin"?(Sp(),Yl=n,Xl=a,Yl.attachEvent("onpropertychange",kp)):t==="focusout"&&Sp()}function pw(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return yo(Xl)}function mw(t,n){if(t==="click")return yo(n)}function gw(t,n){if(t==="input"||t==="change")return yo(n)}function bw(t,n){return t===n&&(t!==0||1/t===1/n)||t!==t&&n!==n}var dn=typeof Object.is=="function"?Object.is:bw;function Zl(t,n){if(dn(t,n))return!0;if(typeof t!="object"||t===null||typeof n!="object"||n===null)return!1;var a=Object.keys(t),s=Object.keys(n);if(a.length!==s.length)return!1;for(s=0;s<a.length;s++){var d=a[s];if(!pt.call(n,d)||!dn(t[d],n[d]))return!1}return!0}function Ep(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Cp(t,n){var a=Ep(t);t=0;for(var s;a;){if(a.nodeType===3){if(s=t+a.textContent.length,t<=n&&s>=n)return{node:a,offset:n-t};t=s}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=Ep(a)}}function Np(t,n){return t&&n?t===n?!0:t&&t.nodeType===3?!1:n&&n.nodeType===3?Np(t,n.parentNode):"contains"in t?t.contains(n):t.compareDocumentPosition?!!(t.compareDocumentPosition(n)&16):!1:!1}function Ap(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var n=co(t.document);n instanceof t.HTMLIFrameElement;){try{var a=typeof n.contentWindow.location.href=="string"}catch{a=!1}if(a)t=n.contentWindow;else break;n=co(t.document)}return n}function qu(t){var n=t&&t.nodeName&&t.nodeName.toLowerCase();return n&&(n==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||n==="textarea"||t.contentEditable==="true")}var yw=ar&&"documentMode"in document&&11>=document.documentMode,Yi=null,$u=null,Kl=null,Pu=!1;function Tp(t,n,a){var s=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;Pu||Yi==null||Yi!==co(s)||(s=Yi,"selectionStart"in s&&qu(s)?s={start:s.selectionStart,end:s.selectionEnd}:(s=(s.ownerDocument&&s.ownerDocument.defaultView||window).getSelection(),s={anchorNode:s.anchorNode,anchorOffset:s.anchorOffset,focusNode:s.focusNode,focusOffset:s.focusOffset}),Kl&&Zl(Kl,s)||(Kl=s,s=as($u,"onSelect"),0<s.length&&(n=new go("onSelect","select",null,n,a),t.push({event:n,listeners:s}),n.target=Yi)))}function mi(t,n){var a={};return a[t.toLowerCase()]=n.toLowerCase(),a["Webkit"+t]="webkit"+n,a["Moz"+t]="moz"+n,a}var Xi={animationend:mi("Animation","AnimationEnd"),animationiteration:mi("Animation","AnimationIteration"),animationstart:mi("Animation","AnimationStart"),transitionrun:mi("Transition","TransitionRun"),transitionstart:mi("Transition","TransitionStart"),transitioncancel:mi("Transition","TransitionCancel"),transitionend:mi("Transition","TransitionEnd")},Vu={},jp={};ar&&(jp=document.createElement("div").style,"AnimationEvent"in window||(delete Xi.animationend.animation,delete Xi.animationiteration.animation,delete Xi.animationstart.animation),"TransitionEvent"in window||delete Xi.transitionend.transition);function gi(t){if(Vu[t])return Vu[t];if(!Xi[t])return t;var n=Xi[t],a;for(a in n)if(n.hasOwnProperty(a)&&a in jp)return Vu[t]=n[a];return t}var Rp=gi("animationend"),_p=gi("animationiteration"),Lp=gi("animationstart"),xw=gi("transitionrun"),vw=gi("transitionstart"),ww=gi("transitioncancel"),Dp=gi("transitionend"),Op=new Map,Gu="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");Gu.push("scrollEnd");function In(t,n){Op.set(t,n),St(n,[t])}var xo=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var n=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(n))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},Nn=[],Zi=0,Yu=0;function vo(){for(var t=Zi,n=Yu=Zi=0;n<t;){var a=Nn[n];Nn[n++]=null;var s=Nn[n];Nn[n++]=null;var d=Nn[n];Nn[n++]=null;var m=Nn[n];if(Nn[n++]=null,s!==null&&d!==null){var k=s.pending;k===null?d.next=d:(d.next=k.next,k.next=d),s.pending=d}m!==0&&Mp(a,d,m)}}function wo(t,n,a,s){Nn[Zi++]=t,Nn[Zi++]=n,Nn[Zi++]=a,Nn[Zi++]=s,Yu|=s,t.lanes|=s,t=t.alternate,t!==null&&(t.lanes|=s)}function Xu(t,n,a,s){return wo(t,n,a,s),So(t)}function bi(t,n){return wo(t,null,null,n),So(t)}function Mp(t,n,a){t.lanes|=a;var s=t.alternate;s!==null&&(s.lanes|=a);for(var d=!1,m=t.return;m!==null;)m.childLanes|=a,s=m.alternate,s!==null&&(s.childLanes|=a),m.tag===22&&(t=m.stateNode,t===null||t._visibility&1||(d=!0)),t=m,m=m.return;return t.tag===3?(m=t.stateNode,d&&n!==null&&(d=31-Je(a),t=m.hiddenUpdates,s=t[d],s===null?t[d]=[n]:s.push(n),n.lane=a|536870912),m):null}function So(t){if(50<ya)throw ya=0,rf=null,Error(l(185));for(var n=t.return;n!==null;)t=n,n=t.return;return t.tag===3?t.stateNode:null}var Ki={};function Sw(t,n,a,s){this.tag=t,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=n,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=s,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function hn(t,n,a,s){return new Sw(t,n,a,s)}function Zu(t){return t=t.prototype,!(!t||!t.isReactComponent)}function or(t,n){var a=t.alternate;return a===null?(a=hn(t.tag,n,t.key,t.mode),a.elementType=t.elementType,a.type=t.type,a.stateNode=t.stateNode,a.alternate=t,t.alternate=a):(a.pendingProps=n,a.type=t.type,a.flags=0,a.subtreeFlags=0,a.deletions=null),a.flags=t.flags&65011712,a.childLanes=t.childLanes,a.lanes=t.lanes,a.child=t.child,a.memoizedProps=t.memoizedProps,a.memoizedState=t.memoizedState,a.updateQueue=t.updateQueue,n=t.dependencies,a.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},a.sibling=t.sibling,a.index=t.index,a.ref=t.ref,a.refCleanup=t.refCleanup,a}function zp(t,n){t.flags&=65011714;var a=t.alternate;return a===null?(t.childLanes=0,t.lanes=n,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=a.childLanes,t.lanes=a.lanes,t.child=a.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=a.memoizedProps,t.memoizedState=a.memoizedState,t.updateQueue=a.updateQueue,t.type=a.type,n=a.dependencies,t.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext}),t}function ko(t,n,a,s,d,m){var k=0;if(s=t,typeof t=="function")Zu(t)&&(k=1);else if(typeof t=="string")k=AS(t,a,te.current)?26:t==="html"||t==="head"||t==="body"?27:5;else e:switch(t){case $:return t=hn(31,a,n,d),t.elementType=$,t.lanes=m,t;case w:return yi(a.children,d,m,n);case N:k=8,d|=24;break;case E:return t=hn(12,a,n,d|2),t.elementType=E,t.lanes=m,t;case I:return t=hn(13,a,n,d),t.elementType=I,t.lanes=m,t;case L:return t=hn(19,a,n,d),t.elementType=L,t.lanes=m,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case j:k=10;break e;case C:k=9;break e;case z:k=11;break e;case O:k=14;break e;case Z:k=16,s=null;break e}k=29,a=Error(l(130,t===null?"null":typeof t,"")),s=null}return n=hn(k,a,n,d),n.elementType=t,n.type=s,n.lanes=m,n}function yi(t,n,a,s){return t=hn(7,t,s,n),t.lanes=a,t}function Ku(t,n,a){return t=hn(6,t,null,n),t.lanes=a,t}function Fp(t){var n=hn(18,null,null,0);return n.stateNode=t,n}function Qu(t,n,a){return n=hn(4,t.children!==null?t.children:[],t.key,n),n.lanes=a,n.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},n}var Bp=new WeakMap;function An(t,n){if(typeof t=="object"&&t!==null){var a=Bp.get(t);return a!==void 0?a:(n={value:t,source:n,stack:It(n)},Bp.set(t,n),n)}return{value:t,source:n,stack:It(n)}}var Qi=[],Ji=0,Eo=null,Ql=0,Tn=[],jn=0,Dr=null,Yn=1,Xn="";function sr(t,n){Qi[Ji++]=Ql,Qi[Ji++]=Eo,Eo=t,Ql=n}function Ip(t,n,a){Tn[jn++]=Yn,Tn[jn++]=Xn,Tn[jn++]=Dr,Dr=t;var s=Yn;t=Xn;var d=32-Je(s)-1;s&=~(1<<d),a+=1;var m=32-Je(n)+d;if(30<m){var k=d-d%5;m=(s&(1<<k)-1).toString(32),s>>=k,d-=k,Yn=1<<32-Je(n)+d|a<<d|s,Xn=m+t}else Yn=1<<m|a<<d|s,Xn=t}function Ju(t){t.return!==null&&(sr(t,1),Ip(t,1,0))}function Wu(t){for(;t===Eo;)Eo=Qi[--Ji],Qi[Ji]=null,Ql=Qi[--Ji],Qi[Ji]=null;for(;t===Dr;)Dr=Tn[--jn],Tn[jn]=null,Xn=Tn[--jn],Tn[jn]=null,Yn=Tn[--jn],Tn[jn]=null}function Up(t,n){Tn[jn++]=Yn,Tn[jn++]=Xn,Tn[jn++]=Dr,Yn=n.id,Xn=n.overflow,Dr=t}var Mt=null,ft=null,qe=!1,Or=null,Rn=!1,ec=Error(l(519));function Mr(t){var n=Error(l(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Jl(An(n,t)),ec}function Hp(t){var n=t.stateNode,a=t.type,s=t.memoizedProps;switch(n[Tt]=t,n[wt]=s,a){case"dialog":Fe("cancel",n),Fe("close",n);break;case"iframe":case"object":case"embed":Fe("load",n);break;case"video":case"audio":for(a=0;a<va.length;a++)Fe(va[a],n);break;case"source":Fe("error",n);break;case"img":case"image":case"link":Fe("error",n),Fe("load",n);break;case"details":Fe("toggle",n);break;case"input":Fe("invalid",n),ep(n,s.value,s.defaultValue,s.checked,s.defaultChecked,s.type,s.name,!0);break;case"select":Fe("invalid",n);break;case"textarea":Fe("invalid",n),np(n,s.value,s.defaultValue,s.children)}a=s.children,typeof a!="string"&&typeof a!="number"&&typeof a!="bigint"||n.textContent===""+a||s.suppressHydrationWarning===!0||ib(n.textContent,a)?(s.popover!=null&&(Fe("beforetoggle",n),Fe("toggle",n)),s.onScroll!=null&&Fe("scroll",n),s.onScrollEnd!=null&&Fe("scrollend",n),s.onClick!=null&&(n.onclick=lr),n=!0):n=!1,n||Mr(t,!0)}function qp(t){for(Mt=t.return;Mt;)switch(Mt.tag){case 5:case 31:case 13:Rn=!1;return;case 27:case 3:Rn=!0;return;default:Mt=Mt.return}}function Wi(t){if(t!==Mt)return!1;if(!qe)return qp(t),qe=!0,!1;var n=t.tag,a;if((a=n!==3&&n!==27)&&((a=n===5)&&(a=t.type,a=!(a!=="form"&&a!=="button")||xf(t.type,t.memoizedProps)),a=!a),a&&ft&&Mr(t),qp(t),n===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(l(317));ft=hb(t)}else if(n===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(l(317));ft=hb(t)}else n===27?(n=ft,Zr(t.type)?(t=Ef,Ef=null,ft=t):ft=n):ft=Mt?Ln(t.stateNode.nextSibling):null;return!0}function xi(){ft=Mt=null,qe=!1}function tc(){var t=Or;return t!==null&&(rn===null?rn=t:rn.push.apply(rn,t),Or=null),t}function Jl(t){Or===null?Or=[t]:Or.push(t)}var nc=D(null),vi=null,ur=null;function zr(t,n,a){T(nc,n._currentValue),n._currentValue=a}function cr(t){t._currentValue=nc.current,q(nc)}function rc(t,n,a){for(;t!==null;){var s=t.alternate;if((t.childLanes&n)!==n?(t.childLanes|=n,s!==null&&(s.childLanes|=n)):s!==null&&(s.childLanes&n)!==n&&(s.childLanes|=n),t===a)break;t=t.return}}function ic(t,n,a,s){var d=t.child;for(d!==null&&(d.return=t);d!==null;){var m=d.dependencies;if(m!==null){var k=d.child;m=m.firstContext;e:for(;m!==null;){var _=m;m=d;for(var P=0;P<n.length;P++)if(_.context===n[P]){m.lanes|=a,_=m.alternate,_!==null&&(_.lanes|=a),rc(m.return,a,t),s||(k=null);break e}m=_.next}}else if(d.tag===18){if(k=d.return,k===null)throw Error(l(341));k.lanes|=a,m=k.alternate,m!==null&&(m.lanes|=a),rc(k,a,t),k=null}else k=d.child;if(k!==null)k.return=d;else for(k=d;k!==null;){if(k===t){k=null;break}if(d=k.sibling,d!==null){d.return=k.return,k=d;break}k=k.return}d=k}}function el(t,n,a,s){t=null;for(var d=n,m=!1;d!==null;){if(!m){if((d.flags&524288)!==0)m=!0;else if((d.flags&262144)!==0)break}if(d.tag===10){var k=d.alternate;if(k===null)throw Error(l(387));if(k=k.memoizedProps,k!==null){var _=d.type;dn(d.pendingProps.value,k.value)||(t!==null?t.push(_):t=[_])}}else if(d===ge.current){if(k=d.alternate,k===null)throw Error(l(387));k.memoizedState.memoizedState!==d.memoizedState.memoizedState&&(t!==null?t.push(Ca):t=[Ca])}d=d.return}t!==null&&ic(n,t,a,s),n.flags|=262144}function Co(t){for(t=t.firstContext;t!==null;){if(!dn(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function wi(t){vi=t,ur=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function zt(t){return $p(vi,t)}function No(t,n){return vi===null&&wi(t),$p(t,n)}function $p(t,n){var a=n._currentValue;if(n={context:n,memoizedValue:a,next:null},ur===null){if(t===null)throw Error(l(308));ur=n,t.dependencies={lanes:0,firstContext:n},t.flags|=524288}else ur=ur.next=n;return a}var kw=typeof AbortController<"u"?AbortController:function(){var t=[],n=this.signal={aborted:!1,addEventListener:function(a,s){t.push(s)}};this.abort=function(){n.aborted=!0,t.forEach(function(a){return a()})}},Ew=e.unstable_scheduleCallback,Cw=e.unstable_NormalPriority,kt={$$typeof:j,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function lc(){return{controller:new kw,data:new Map,refCount:0}}function Wl(t){t.refCount--,t.refCount===0&&Ew(Cw,function(){t.controller.abort()})}var ea=null,ac=0,tl=0,nl=null;function Nw(t,n){if(ea===null){var a=ea=[];ac=0,tl=cf(),nl={status:"pending",value:void 0,then:function(s){a.push(s)}}}return ac++,n.then(Pp,Pp),n}function Pp(){if(--ac===0&&ea!==null){nl!==null&&(nl.status="fulfilled");var t=ea;ea=null,tl=0,nl=null;for(var n=0;n<t.length;n++)(0,t[n])()}}function Aw(t,n){var a=[],s={status:"pending",value:null,reason:null,then:function(d){a.push(d)}};return t.then(function(){s.status="fulfilled",s.value=n;for(var d=0;d<a.length;d++)(0,a[d])(n)},function(d){for(s.status="rejected",s.reason=d,d=0;d<a.length;d++)(0,a[d])(void 0)}),s}var Vp=B.S;B.S=function(t,n){Tg=at(),typeof n=="object"&&n!==null&&typeof n.then=="function"&&Nw(t,n),Vp!==null&&Vp(t,n)};var Si=D(null);function oc(){var t=Si.current;return t!==null?t:ot.pooledCache}function Ao(t,n){n===null?T(Si,Si.current):T(Si,n.pool)}function Gp(){var t=oc();return t===null?null:{parent:kt._currentValue,pool:t}}var rl=Error(l(460)),sc=Error(l(474)),To=Error(l(542)),jo={then:function(){}};function Yp(t){return t=t.status,t==="fulfilled"||t==="rejected"}function Xp(t,n,a){switch(a=t[a],a===void 0?t.push(n):a!==n&&(n.then(lr,lr),n=a),n.status){case"fulfilled":return n.value;case"rejected":throw t=n.reason,Kp(t),t;default:if(typeof n.status=="string")n.then(lr,lr);else{if(t=ot,t!==null&&100<t.shellSuspendCounter)throw Error(l(482));t=n,t.status="pending",t.then(function(s){if(n.status==="pending"){var d=n;d.status="fulfilled",d.value=s}},function(s){if(n.status==="pending"){var d=n;d.status="rejected",d.reason=s}})}switch(n.status){case"fulfilled":return n.value;case"rejected":throw t=n.reason,Kp(t),t}throw Ei=n,rl}}function ki(t){try{var n=t._init;return n(t._payload)}catch(a){throw a!==null&&typeof a=="object"&&typeof a.then=="function"?(Ei=a,rl):a}}var Ei=null;function Zp(){if(Ei===null)throw Error(l(459));var t=Ei;return Ei=null,t}function Kp(t){if(t===rl||t===To)throw Error(l(483))}var il=null,ta=0;function Ro(t){var n=ta;return ta+=1,il===null&&(il=[]),Xp(il,t,n)}function na(t,n){n=n.props.ref,t.ref=n!==void 0?n:null}function _o(t,n){throw n.$$typeof===v?Error(l(525)):(t=Object.prototype.toString.call(n),Error(l(31,t==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":t)))}function Qp(t){function n(J,K){if(t){var W=J.deletions;W===null?(J.deletions=[K],J.flags|=16):W.push(K)}}function a(J,K){if(!t)return null;for(;K!==null;)n(J,K),K=K.sibling;return null}function s(J){for(var K=new Map;J!==null;)J.key!==null?K.set(J.key,J):K.set(J.index,J),J=J.sibling;return K}function d(J,K){return J=or(J,K),J.index=0,J.sibling=null,J}function m(J,K,W){return J.index=W,t?(W=J.alternate,W!==null?(W=W.index,W<K?(J.flags|=67108866,K):W):(J.flags|=67108866,K)):(J.flags|=1048576,K)}function k(J){return t&&J.alternate===null&&(J.flags|=67108866),J}function _(J,K,W,se){return K===null||K.tag!==6?(K=Ku(W,J.mode,se),K.return=J,K):(K=d(K,W),K.return=J,K)}function P(J,K,W,se){var Ne=W.type;return Ne===w?oe(J,K,W.props.children,se,W.key):K!==null&&(K.elementType===Ne||typeof Ne=="object"&&Ne!==null&&Ne.$$typeof===Z&&ki(Ne)===K.type)?(K=d(K,W.props),na(K,W),K.return=J,K):(K=ko(W.type,W.key,W.props,null,J.mode,se),na(K,W),K.return=J,K)}function ee(J,K,W,se){return K===null||K.tag!==4||K.stateNode.containerInfo!==W.containerInfo||K.stateNode.implementation!==W.implementation?(K=Qu(W,J.mode,se),K.return=J,K):(K=d(K,W.children||[]),K.return=J,K)}function oe(J,K,W,se,Ne){return K===null||K.tag!==7?(K=yi(W,J.mode,se,Ne),K.return=J,K):(K=d(K,W),K.return=J,K)}function ce(J,K,W){if(typeof K=="string"&&K!==""||typeof K=="number"||typeof K=="bigint")return K=Ku(""+K,J.mode,W),K.return=J,K;if(typeof K=="object"&&K!==null){switch(K.$$typeof){case x:return W=ko(K.type,K.key,K.props,null,J.mode,W),na(W,K),W.return=J,W;case S:return K=Qu(K,J.mode,W),K.return=J,K;case Z:return K=ki(K),ce(J,K,W)}if(Y(K)||G(K))return K=yi(K,J.mode,W,null),K.return=J,K;if(typeof K.then=="function")return ce(J,Ro(K),W);if(K.$$typeof===j)return ce(J,No(J,K),W);_o(J,K)}return null}function ne(J,K,W,se){var Ne=K!==null?K.key:null;if(typeof W=="string"&&W!==""||typeof W=="number"||typeof W=="bigint")return Ne!==null?null:_(J,K,""+W,se);if(typeof W=="object"&&W!==null){switch(W.$$typeof){case x:return W.key===Ne?P(J,K,W,se):null;case S:return W.key===Ne?ee(J,K,W,se):null;case Z:return W=ki(W),ne(J,K,W,se)}if(Y(W)||G(W))return Ne!==null?null:oe(J,K,W,se,null);if(typeof W.then=="function")return ne(J,K,Ro(W),se);if(W.$$typeof===j)return ne(J,K,No(J,W),se);_o(J,W)}return null}function le(J,K,W,se,Ne){if(typeof se=="string"&&se!==""||typeof se=="number"||typeof se=="bigint")return J=J.get(W)||null,_(K,J,""+se,Ne);if(typeof se=="object"&&se!==null){switch(se.$$typeof){case x:return J=J.get(se.key===null?W:se.key)||null,P(K,J,se,Ne);case S:return J=J.get(se.key===null?W:se.key)||null,ee(K,J,se,Ne);case Z:return se=ki(se),le(J,K,W,se,Ne)}if(Y(se)||G(se))return J=J.get(W)||null,oe(K,J,se,Ne,null);if(typeof se.then=="function")return le(J,K,W,Ro(se),Ne);if(se.$$typeof===j)return le(J,K,W,No(K,se),Ne);_o(K,se)}return null}function ke(J,K,W,se){for(var Ne=null,Ye=null,Ce=K,Le=K=0,He=null;Ce!==null&&Le<W.length;Le++){Ce.index>Le?(He=Ce,Ce=null):He=Ce.sibling;var Xe=ne(J,Ce,W[Le],se);if(Xe===null){Ce===null&&(Ce=He);break}t&&Ce&&Xe.alternate===null&&n(J,Ce),K=m(Xe,K,Le),Ye===null?Ne=Xe:Ye.sibling=Xe,Ye=Xe,Ce=He}if(Le===W.length)return a(J,Ce),qe&&sr(J,Le),Ne;if(Ce===null){for(;Le<W.length;Le++)Ce=ce(J,W[Le],se),Ce!==null&&(K=m(Ce,K,Le),Ye===null?Ne=Ce:Ye.sibling=Ce,Ye=Ce);return qe&&sr(J,Le),Ne}for(Ce=s(Ce);Le<W.length;Le++)He=le(Ce,J,Le,W[Le],se),He!==null&&(t&&He.alternate!==null&&Ce.delete(He.key===null?Le:He.key),K=m(He,K,Le),Ye===null?Ne=He:Ye.sibling=He,Ye=He);return t&&Ce.forEach(function(ei){return n(J,ei)}),qe&&sr(J,Le),Ne}function je(J,K,W,se){if(W==null)throw Error(l(151));for(var Ne=null,Ye=null,Ce=K,Le=K=0,He=null,Xe=W.next();Ce!==null&&!Xe.done;Le++,Xe=W.next()){Ce.index>Le?(He=Ce,Ce=null):He=Ce.sibling;var ei=ne(J,Ce,Xe.value,se);if(ei===null){Ce===null&&(Ce=He);break}t&&Ce&&ei.alternate===null&&n(J,Ce),K=m(ei,K,Le),Ye===null?Ne=ei:Ye.sibling=ei,Ye=ei,Ce=He}if(Xe.done)return a(J,Ce),qe&&sr(J,Le),Ne;if(Ce===null){for(;!Xe.done;Le++,Xe=W.next())Xe=ce(J,Xe.value,se),Xe!==null&&(K=m(Xe,K,Le),Ye===null?Ne=Xe:Ye.sibling=Xe,Ye=Xe);return qe&&sr(J,Le),Ne}for(Ce=s(Ce);!Xe.done;Le++,Xe=W.next())Xe=le(Ce,J,Le,Xe.value,se),Xe!==null&&(t&&Xe.alternate!==null&&Ce.delete(Xe.key===null?Le:Xe.key),K=m(Xe,K,Le),Ye===null?Ne=Xe:Ye.sibling=Xe,Ye=Xe);return t&&Ce.forEach(function(BS){return n(J,BS)}),qe&&sr(J,Le),Ne}function it(J,K,W,se){if(typeof W=="object"&&W!==null&&W.type===w&&W.key===null&&(W=W.props.children),typeof W=="object"&&W!==null){switch(W.$$typeof){case x:e:{for(var Ne=W.key;K!==null;){if(K.key===Ne){if(Ne=W.type,Ne===w){if(K.tag===7){a(J,K.sibling),se=d(K,W.props.children),se.return=J,J=se;break e}}else if(K.elementType===Ne||typeof Ne=="object"&&Ne!==null&&Ne.$$typeof===Z&&ki(Ne)===K.type){a(J,K.sibling),se=d(K,W.props),na(se,W),se.return=J,J=se;break e}a(J,K);break}else n(J,K);K=K.sibling}W.type===w?(se=yi(W.props.children,J.mode,se,W.key),se.return=J,J=se):(se=ko(W.type,W.key,W.props,null,J.mode,se),na(se,W),se.return=J,J=se)}return k(J);case S:e:{for(Ne=W.key;K!==null;){if(K.key===Ne)if(K.tag===4&&K.stateNode.containerInfo===W.containerInfo&&K.stateNode.implementation===W.implementation){a(J,K.sibling),se=d(K,W.children||[]),se.return=J,J=se;break e}else{a(J,K);break}else n(J,K);K=K.sibling}se=Qu(W,J.mode,se),se.return=J,J=se}return k(J);case Z:return W=ki(W),it(J,K,W,se)}if(Y(W))return ke(J,K,W,se);if(G(W)){if(Ne=G(W),typeof Ne!="function")throw Error(l(150));return W=Ne.call(W),je(J,K,W,se)}if(typeof W.then=="function")return it(J,K,Ro(W),se);if(W.$$typeof===j)return it(J,K,No(J,W),se);_o(J,W)}return typeof W=="string"&&W!==""||typeof W=="number"||typeof W=="bigint"?(W=""+W,K!==null&&K.tag===6?(a(J,K.sibling),se=d(K,W),se.return=J,J=se):(a(J,K),se=Ku(W,J.mode,se),se.return=J,J=se),k(J)):a(J,K)}return function(J,K,W,se){try{ta=0;var Ne=it(J,K,W,se);return il=null,Ne}catch(Ce){if(Ce===rl||Ce===To)throw Ce;var Ye=hn(29,Ce,null,J.mode);return Ye.lanes=se,Ye.return=J,Ye}}}var Ci=Qp(!0),Jp=Qp(!1),Fr=!1;function uc(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function cc(t,n){t=t.updateQueue,n.updateQueue===t&&(n.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function Br(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function Ir(t,n,a){var s=t.updateQueue;if(s===null)return null;if(s=s.shared,(Ze&2)!==0){var d=s.pending;return d===null?n.next=n:(n.next=d.next,d.next=n),s.pending=n,n=So(t),Mp(t,null,a),n}return wo(t,s,n,a),So(t)}function ra(t,n,a){if(n=n.updateQueue,n!==null&&(n=n.shared,(a&4194048)!==0)){var s=n.lanes;s&=t.pendingLanes,a|=s,n.lanes=a,Jt(t,a)}}function fc(t,n){var a=t.updateQueue,s=t.alternate;if(s!==null&&(s=s.updateQueue,a===s)){var d=null,m=null;if(a=a.firstBaseUpdate,a!==null){do{var k={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};m===null?d=m=k:m=m.next=k,a=a.next}while(a!==null);m===null?d=m=n:m=m.next=n}else d=m=n;a={baseState:s.baseState,firstBaseUpdate:d,lastBaseUpdate:m,shared:s.shared,callbacks:s.callbacks},t.updateQueue=a;return}t=a.lastBaseUpdate,t===null?a.firstBaseUpdate=n:t.next=n,a.lastBaseUpdate=n}var dc=!1;function ia(){if(dc){var t=nl;if(t!==null)throw t}}function la(t,n,a,s){dc=!1;var d=t.updateQueue;Fr=!1;var m=d.firstBaseUpdate,k=d.lastBaseUpdate,_=d.shared.pending;if(_!==null){d.shared.pending=null;var P=_,ee=P.next;P.next=null,k===null?m=ee:k.next=ee,k=P;var oe=t.alternate;oe!==null&&(oe=oe.updateQueue,_=oe.lastBaseUpdate,_!==k&&(_===null?oe.firstBaseUpdate=ee:_.next=ee,oe.lastBaseUpdate=P))}if(m!==null){var ce=d.baseState;k=0,oe=ee=P=null,_=m;do{var ne=_.lane&-536870913,le=ne!==_.lane;if(le?(Ue&ne)===ne:(s&ne)===ne){ne!==0&&ne===tl&&(dc=!0),oe!==null&&(oe=oe.next={lane:0,tag:_.tag,payload:_.payload,callback:null,next:null});e:{var ke=t,je=_;ne=n;var it=a;switch(je.tag){case 1:if(ke=je.payload,typeof ke=="function"){ce=ke.call(it,ce,ne);break e}ce=ke;break e;case 3:ke.flags=ke.flags&-65537|128;case 0:if(ke=je.payload,ne=typeof ke=="function"?ke.call(it,ce,ne):ke,ne==null)break e;ce=b({},ce,ne);break e;case 2:Fr=!0}}ne=_.callback,ne!==null&&(t.flags|=64,le&&(t.flags|=8192),le=d.callbacks,le===null?d.callbacks=[ne]:le.push(ne))}else le={lane:ne,tag:_.tag,payload:_.payload,callback:_.callback,next:null},oe===null?(ee=oe=le,P=ce):oe=oe.next=le,k|=ne;if(_=_.next,_===null){if(_=d.shared.pending,_===null)break;le=_,_=le.next,le.next=null,d.lastBaseUpdate=le,d.shared.pending=null}}while(!0);oe===null&&(P=ce),d.baseState=P,d.firstBaseUpdate=ee,d.lastBaseUpdate=oe,m===null&&(d.shared.lanes=0),Pr|=k,t.lanes=k,t.memoizedState=ce}}function Wp(t,n){if(typeof t!="function")throw Error(l(191,t));t.call(n)}function em(t,n){var a=t.callbacks;if(a!==null)for(t.callbacks=null,t=0;t<a.length;t++)Wp(a[t],n)}var ll=D(null),Lo=D(0);function tm(t,n){t=xr,T(Lo,t),T(ll,n),xr=t|n.baseLanes}function hc(){T(Lo,xr),T(ll,ll.current)}function pc(){xr=Lo.current,q(ll),q(Lo)}var pn=D(null),_n=null;function Ur(t){var n=t.alternate;T(xt,xt.current&1),T(pn,t),_n===null&&(n===null||ll.current!==null||n.memoizedState!==null)&&(_n=t)}function mc(t){T(xt,xt.current),T(pn,t),_n===null&&(_n=t)}function nm(t){t.tag===22?(T(xt,xt.current),T(pn,t),_n===null&&(_n=t)):Hr()}function Hr(){T(xt,xt.current),T(pn,pn.current)}function mn(t){q(pn),_n===t&&(_n=null),q(xt)}var xt=D(0);function Do(t){for(var n=t;n!==null;){if(n.tag===13){var a=n.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||Sf(a)||kf(a)))return n}else if(n.tag===19&&(n.memoizedProps.revealOrder==="forwards"||n.memoizedProps.revealOrder==="backwards"||n.memoizedProps.revealOrder==="unstable_legacy-backwards"||n.memoizedProps.revealOrder==="together")){if((n.flags&128)!==0)return n}else if(n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}return null}var fr=0,_e=null,nt=null,Et=null,Oo=!1,al=!1,Ni=!1,Mo=0,aa=0,ol=null,Tw=0;function bt(){throw Error(l(321))}function gc(t,n){if(n===null)return!1;for(var a=0;a<n.length&&a<t.length;a++)if(!dn(t[a],n[a]))return!1;return!0}function bc(t,n,a,s,d,m){return fr=m,_e=n,n.memoizedState=null,n.updateQueue=null,n.lanes=0,B.H=t===null||t.memoizedState===null?Im:Lc,Ni=!1,m=a(s,d),Ni=!1,al&&(m=im(n,a,s,d)),rm(t),m}function rm(t){B.H=ua;var n=nt!==null&&nt.next!==null;if(fr=0,Et=nt=_e=null,Oo=!1,aa=0,ol=null,n)throw Error(l(300));t===null||Ct||(t=t.dependencies,t!==null&&Co(t)&&(Ct=!0))}function im(t,n,a,s){_e=t;var d=0;do{if(al&&(ol=null),aa=0,al=!1,25<=d)throw Error(l(301));if(d+=1,Et=nt=null,t.updateQueue!=null){var m=t.updateQueue;m.lastEffect=null,m.events=null,m.stores=null,m.memoCache!=null&&(m.memoCache.index=0)}B.H=Um,m=n(a,s)}while(al);return m}function jw(){var t=B.H,n=t.useState()[0];return n=typeof n.then=="function"?oa(n):n,t=t.useState()[0],(nt!==null?nt.memoizedState:null)!==t&&(_e.flags|=1024),n}function yc(){var t=Mo!==0;return Mo=0,t}function xc(t,n,a){n.updateQueue=t.updateQueue,n.flags&=-2053,t.lanes&=~a}function vc(t){if(Oo){for(t=t.memoizedState;t!==null;){var n=t.queue;n!==null&&(n.pending=null),t=t.next}Oo=!1}fr=0,Et=nt=_e=null,al=!1,aa=Mo=0,ol=null}function Xt(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Et===null?_e.memoizedState=Et=t:Et=Et.next=t,Et}function vt(){if(nt===null){var t=_e.alternate;t=t!==null?t.memoizedState:null}else t=nt.next;var n=Et===null?_e.memoizedState:Et.next;if(n!==null)Et=n,nt=t;else{if(t===null)throw _e.alternate===null?Error(l(467)):Error(l(310));nt=t,t={memoizedState:nt.memoizedState,baseState:nt.baseState,baseQueue:nt.baseQueue,queue:nt.queue,next:null},Et===null?_e.memoizedState=Et=t:Et=Et.next=t}return Et}function zo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function oa(t){var n=aa;return aa+=1,ol===null&&(ol=[]),t=Xp(ol,t,n),n=_e,(Et===null?n.memoizedState:Et.next)===null&&(n=n.alternate,B.H=n===null||n.memoizedState===null?Im:Lc),t}function Fo(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return oa(t);if(t.$$typeof===j)return zt(t)}throw Error(l(438,String(t)))}function wc(t){var n=null,a=_e.updateQueue;if(a!==null&&(n=a.memoCache),n==null){var s=_e.alternate;s!==null&&(s=s.updateQueue,s!==null&&(s=s.memoCache,s!=null&&(n={data:s.data.map(function(d){return d.slice()}),index:0})))}if(n==null&&(n={data:[],index:0}),a===null&&(a=zo(),_e.updateQueue=a),a.memoCache=n,a=n.data[n.index],a===void 0)for(a=n.data[n.index]=Array(t),s=0;s<t;s++)a[s]=F;return n.index++,a}function dr(t,n){return typeof n=="function"?n(t):n}function Bo(t){var n=vt();return Sc(n,nt,t)}function Sc(t,n,a){var s=t.queue;if(s===null)throw Error(l(311));s.lastRenderedReducer=a;var d=t.baseQueue,m=s.pending;if(m!==null){if(d!==null){var k=d.next;d.next=m.next,m.next=k}n.baseQueue=d=m,s.pending=null}if(m=t.baseState,d===null)t.memoizedState=m;else{n=d.next;var _=k=null,P=null,ee=n,oe=!1;do{var ce=ee.lane&-536870913;if(ce!==ee.lane?(Ue&ce)===ce:(fr&ce)===ce){var ne=ee.revertLane;if(ne===0)P!==null&&(P=P.next={lane:0,revertLane:0,gesture:null,action:ee.action,hasEagerState:ee.hasEagerState,eagerState:ee.eagerState,next:null}),ce===tl&&(oe=!0);else if((fr&ne)===ne){ee=ee.next,ne===tl&&(oe=!0);continue}else ce={lane:0,revertLane:ee.revertLane,gesture:null,action:ee.action,hasEagerState:ee.hasEagerState,eagerState:ee.eagerState,next:null},P===null?(_=P=ce,k=m):P=P.next=ce,_e.lanes|=ne,Pr|=ne;ce=ee.action,Ni&&a(m,ce),m=ee.hasEagerState?ee.eagerState:a(m,ce)}else ne={lane:ce,revertLane:ee.revertLane,gesture:ee.gesture,action:ee.action,hasEagerState:ee.hasEagerState,eagerState:ee.eagerState,next:null},P===null?(_=P=ne,k=m):P=P.next=ne,_e.lanes|=ce,Pr|=ce;ee=ee.next}while(ee!==null&&ee!==n);if(P===null?k=m:P.next=_,!dn(m,t.memoizedState)&&(Ct=!0,oe&&(a=nl,a!==null)))throw a;t.memoizedState=m,t.baseState=k,t.baseQueue=P,s.lastRenderedState=m}return d===null&&(s.lanes=0),[t.memoizedState,s.dispatch]}function kc(t){var n=vt(),a=n.queue;if(a===null)throw Error(l(311));a.lastRenderedReducer=t;var s=a.dispatch,d=a.pending,m=n.memoizedState;if(d!==null){a.pending=null;var k=d=d.next;do m=t(m,k.action),k=k.next;while(k!==d);dn(m,n.memoizedState)||(Ct=!0),n.memoizedState=m,n.baseQueue===null&&(n.baseState=m),a.lastRenderedState=m}return[m,s]}function lm(t,n,a){var s=_e,d=vt(),m=qe;if(m){if(a===void 0)throw Error(l(407));a=a()}else a=n();var k=!dn((nt||d).memoizedState,a);if(k&&(d.memoizedState=a,Ct=!0),d=d.queue,Nc(sm.bind(null,s,d,t),[t]),d.getSnapshot!==n||k||Et!==null&&Et.memoizedState.tag&1){if(s.flags|=2048,sl(9,{destroy:void 0},om.bind(null,s,d,a,n),null),ot===null)throw Error(l(349));m||(fr&127)!==0||am(s,n,a)}return a}function am(t,n,a){t.flags|=16384,t={getSnapshot:n,value:a},n=_e.updateQueue,n===null?(n=zo(),_e.updateQueue=n,n.stores=[t]):(a=n.stores,a===null?n.stores=[t]:a.push(t))}function om(t,n,a,s){n.value=a,n.getSnapshot=s,um(n)&&cm(t)}function sm(t,n,a){return a(function(){um(n)&&cm(t)})}function um(t){var n=t.getSnapshot;t=t.value;try{var a=n();return!dn(t,a)}catch{return!0}}function cm(t){var n=bi(t,2);n!==null&&ln(n,t,2)}function Ec(t){var n=Xt();if(typeof t=="function"){var a=t;if(t=a(),Ni){Ut(!0);try{a()}finally{Ut(!1)}}}return n.memoizedState=n.baseState=t,n.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:dr,lastRenderedState:t},n}function fm(t,n,a,s){return t.baseState=a,Sc(t,nt,typeof s=="function"?s:dr)}function Rw(t,n,a,s,d){if(Ho(t))throw Error(l(485));if(t=n.action,t!==null){var m={payload:d,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(k){m.listeners.push(k)}};B.T!==null?a(!0):m.isTransition=!1,s(m),a=n.pending,a===null?(m.next=n.pending=m,dm(n,m)):(m.next=a.next,n.pending=a.next=m)}}function dm(t,n){var a=n.action,s=n.payload,d=t.state;if(n.isTransition){var m=B.T,k={};B.T=k;try{var _=a(d,s),P=B.S;P!==null&&P(k,_),hm(t,n,_)}catch(ee){Cc(t,n,ee)}finally{m!==null&&k.types!==null&&(m.types=k.types),B.T=m}}else try{m=a(d,s),hm(t,n,m)}catch(ee){Cc(t,n,ee)}}function hm(t,n,a){a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(function(s){pm(t,n,s)},function(s){return Cc(t,n,s)}):pm(t,n,a)}function pm(t,n,a){n.status="fulfilled",n.value=a,mm(n),t.state=a,n=t.pending,n!==null&&(a=n.next,a===n?t.pending=null:(a=a.next,n.next=a,dm(t,a)))}function Cc(t,n,a){var s=t.pending;if(t.pending=null,s!==null){s=s.next;do n.status="rejected",n.reason=a,mm(n),n=n.next;while(n!==s)}t.action=null}function mm(t){t=t.listeners;for(var n=0;n<t.length;n++)(0,t[n])()}function gm(t,n){return n}function bm(t,n){if(qe){var a=ot.formState;if(a!==null){e:{var s=_e;if(qe){if(ft){t:{for(var d=ft,m=Rn;d.nodeType!==8;){if(!m){d=null;break t}if(d=Ln(d.nextSibling),d===null){d=null;break t}}m=d.data,d=m==="F!"||m==="F"?d:null}if(d){ft=Ln(d.nextSibling),s=d.data==="F!";break e}}Mr(s)}s=!1}s&&(n=a[0])}}return a=Xt(),a.memoizedState=a.baseState=n,s={pending:null,lanes:0,dispatch:null,lastRenderedReducer:gm,lastRenderedState:n},a.queue=s,a=zm.bind(null,_e,s),s.dispatch=a,s=Ec(!1),m=_c.bind(null,_e,!1,s.queue),s=Xt(),d={state:n,dispatch:null,action:t,pending:null},s.queue=d,a=Rw.bind(null,_e,d,m,a),d.dispatch=a,s.memoizedState=t,[n,a,!1]}function ym(t){var n=vt();return xm(n,nt,t)}function xm(t,n,a){if(n=Sc(t,n,gm)[0],t=Bo(dr)[0],typeof n=="object"&&n!==null&&typeof n.then=="function")try{var s=oa(n)}catch(k){throw k===rl?To:k}else s=n;n=vt();var d=n.queue,m=d.dispatch;return a!==n.memoizedState&&(_e.flags|=2048,sl(9,{destroy:void 0},_w.bind(null,d,a),null)),[s,m,t]}function _w(t,n){t.action=n}function vm(t){var n=vt(),a=nt;if(a!==null)return xm(n,a,t);vt(),n=n.memoizedState,a=vt();var s=a.queue.dispatch;return a.memoizedState=t,[n,s,!1]}function sl(t,n,a,s){return t={tag:t,create:a,deps:s,inst:n,next:null},n=_e.updateQueue,n===null&&(n=zo(),_e.updateQueue=n),a=n.lastEffect,a===null?n.lastEffect=t.next=t:(s=a.next,a.next=t,t.next=s,n.lastEffect=t),t}function wm(){return vt().memoizedState}function Io(t,n,a,s){var d=Xt();_e.flags|=t,d.memoizedState=sl(1|n,{destroy:void 0},a,s===void 0?null:s)}function Uo(t,n,a,s){var d=vt();s=s===void 0?null:s;var m=d.memoizedState.inst;nt!==null&&s!==null&&gc(s,nt.memoizedState.deps)?d.memoizedState=sl(n,m,a,s):(_e.flags|=t,d.memoizedState=sl(1|n,m,a,s))}function Sm(t,n){Io(8390656,8,t,n)}function Nc(t,n){Uo(2048,8,t,n)}function Lw(t){_e.flags|=4;var n=_e.updateQueue;if(n===null)n=zo(),_e.updateQueue=n,n.events=[t];else{var a=n.events;a===null?n.events=[t]:a.push(t)}}function km(t){var n=vt().memoizedState;return Lw({ref:n,nextImpl:t}),function(){if((Ze&2)!==0)throw Error(l(440));return n.impl.apply(void 0,arguments)}}function Em(t,n){return Uo(4,2,t,n)}function Cm(t,n){return Uo(4,4,t,n)}function Nm(t,n){if(typeof n=="function"){t=t();var a=n(t);return function(){typeof a=="function"?a():n(null)}}if(n!=null)return t=t(),n.current=t,function(){n.current=null}}function Am(t,n,a){a=a!=null?a.concat([t]):null,Uo(4,4,Nm.bind(null,n,t),a)}function Ac(){}function Tm(t,n){var a=vt();n=n===void 0?null:n;var s=a.memoizedState;return n!==null&&gc(n,s[1])?s[0]:(a.memoizedState=[t,n],t)}function jm(t,n){var a=vt();n=n===void 0?null:n;var s=a.memoizedState;if(n!==null&&gc(n,s[1]))return s[0];if(s=t(),Ni){Ut(!0);try{t()}finally{Ut(!1)}}return a.memoizedState=[s,n],s}function Tc(t,n,a){return a===void 0||(fr&1073741824)!==0&&(Ue&261930)===0?t.memoizedState=n:(t.memoizedState=a,t=Rg(),_e.lanes|=t,Pr|=t,a)}function Rm(t,n,a,s){return dn(a,n)?a:ll.current!==null?(t=Tc(t,a,s),dn(t,n)||(Ct=!0),t):(fr&42)===0||(fr&1073741824)!==0&&(Ue&261930)===0?(Ct=!0,t.memoizedState=a):(t=Rg(),_e.lanes|=t,Pr|=t,n)}function _m(t,n,a,s,d){var m=X.p;X.p=m!==0&&8>m?m:8;var k=B.T,_={};B.T=_,_c(t,!1,n,a);try{var P=d(),ee=B.S;if(ee!==null&&ee(_,P),P!==null&&typeof P=="object"&&typeof P.then=="function"){var oe=Aw(P,s);sa(t,n,oe,yn(t))}else sa(t,n,s,yn(t))}catch(ce){sa(t,n,{then:function(){},status:"rejected",reason:ce},yn())}finally{X.p=m,k!==null&&_.types!==null&&(k.types=_.types),B.T=k}}function Dw(){}function jc(t,n,a,s){if(t.tag!==5)throw Error(l(476));var d=Lm(t).queue;_m(t,d,n,M,a===null?Dw:function(){return Dm(t),a(s)})}function Lm(t){var n=t.memoizedState;if(n!==null)return n;n={memoizedState:M,baseState:M,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:dr,lastRenderedState:M},next:null};var a={};return n.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:dr,lastRenderedState:a},next:null},t.memoizedState=n,t=t.alternate,t!==null&&(t.memoizedState=n),n}function Dm(t){var n=Lm(t);n.next===null&&(n=t.alternate.memoizedState),sa(t,n.next.queue,{},yn())}function Rc(){return zt(Ca)}function Om(){return vt().memoizedState}function Mm(){return vt().memoizedState}function Ow(t){for(var n=t.return;n!==null;){switch(n.tag){case 24:case 3:var a=yn();t=Br(a);var s=Ir(n,t,a);s!==null&&(ln(s,n,a),ra(s,n,a)),n={cache:lc()},t.payload=n;return}n=n.return}}function Mw(t,n,a){var s=yn();a={lane:s,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},Ho(t)?Fm(n,a):(a=Xu(t,n,a,s),a!==null&&(ln(a,t,s),Bm(a,n,s)))}function zm(t,n,a){var s=yn();sa(t,n,a,s)}function sa(t,n,a,s){var d={lane:s,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null};if(Ho(t))Fm(n,d);else{var m=t.alternate;if(t.lanes===0&&(m===null||m.lanes===0)&&(m=n.lastRenderedReducer,m!==null))try{var k=n.lastRenderedState,_=m(k,a);if(d.hasEagerState=!0,d.eagerState=_,dn(_,k))return wo(t,n,d,0),ot===null&&vo(),!1}catch{}if(a=Xu(t,n,d,s),a!==null)return ln(a,t,s),Bm(a,n,s),!0}return!1}function _c(t,n,a,s){if(s={lane:2,revertLane:cf(),gesture:null,action:s,hasEagerState:!1,eagerState:null,next:null},Ho(t)){if(n)throw Error(l(479))}else n=Xu(t,a,s,2),n!==null&&ln(n,t,2)}function Ho(t){var n=t.alternate;return t===_e||n!==null&&n===_e}function Fm(t,n){al=Oo=!0;var a=t.pending;a===null?n.next=n:(n.next=a.next,a.next=n),t.pending=n}function Bm(t,n,a){if((a&4194048)!==0){var s=n.lanes;s&=t.pendingLanes,a|=s,n.lanes=a,Jt(t,a)}}var ua={readContext:zt,use:Fo,useCallback:bt,useContext:bt,useEffect:bt,useImperativeHandle:bt,useLayoutEffect:bt,useInsertionEffect:bt,useMemo:bt,useReducer:bt,useRef:bt,useState:bt,useDebugValue:bt,useDeferredValue:bt,useTransition:bt,useSyncExternalStore:bt,useId:bt,useHostTransitionStatus:bt,useFormState:bt,useActionState:bt,useOptimistic:bt,useMemoCache:bt,useCacheRefresh:bt};ua.useEffectEvent=bt;var Im={readContext:zt,use:Fo,useCallback:function(t,n){return Xt().memoizedState=[t,n===void 0?null:n],t},useContext:zt,useEffect:Sm,useImperativeHandle:function(t,n,a){a=a!=null?a.concat([t]):null,Io(4194308,4,Nm.bind(null,n,t),a)},useLayoutEffect:function(t,n){return Io(4194308,4,t,n)},useInsertionEffect:function(t,n){Io(4,2,t,n)},useMemo:function(t,n){var a=Xt();n=n===void 0?null:n;var s=t();if(Ni){Ut(!0);try{t()}finally{Ut(!1)}}return a.memoizedState=[s,n],s},useReducer:function(t,n,a){var s=Xt();if(a!==void 0){var d=a(n);if(Ni){Ut(!0);try{a(n)}finally{Ut(!1)}}}else d=n;return s.memoizedState=s.baseState=d,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:d},s.queue=t,t=t.dispatch=Mw.bind(null,_e,t),[s.memoizedState,t]},useRef:function(t){var n=Xt();return t={current:t},n.memoizedState=t},useState:function(t){t=Ec(t);var n=t.queue,a=zm.bind(null,_e,n);return n.dispatch=a,[t.memoizedState,a]},useDebugValue:Ac,useDeferredValue:function(t,n){var a=Xt();return Tc(a,t,n)},useTransition:function(){var t=Ec(!1);return t=_m.bind(null,_e,t.queue,!0,!1),Xt().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,n,a){var s=_e,d=Xt();if(qe){if(a===void 0)throw Error(l(407));a=a()}else{if(a=n(),ot===null)throw Error(l(349));(Ue&127)!==0||am(s,n,a)}d.memoizedState=a;var m={value:a,getSnapshot:n};return d.queue=m,Sm(sm.bind(null,s,m,t),[t]),s.flags|=2048,sl(9,{destroy:void 0},om.bind(null,s,m,a,n),null),a},useId:function(){var t=Xt(),n=ot.identifierPrefix;if(qe){var a=Xn,s=Yn;a=(s&~(1<<32-Je(s)-1)).toString(32)+a,n="_"+n+"R_"+a,a=Mo++,0<a&&(n+="H"+a.toString(32)),n+="_"}else a=Tw++,n="_"+n+"r_"+a.toString(32)+"_";return t.memoizedState=n},useHostTransitionStatus:Rc,useFormState:bm,useActionState:bm,useOptimistic:function(t){var n=Xt();n.memoizedState=n.baseState=t;var a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return n.queue=a,n=_c.bind(null,_e,!0,a),a.dispatch=n,[t,n]},useMemoCache:wc,useCacheRefresh:function(){return Xt().memoizedState=Ow.bind(null,_e)},useEffectEvent:function(t){var n=Xt(),a={impl:t};return n.memoizedState=a,function(){if((Ze&2)!==0)throw Error(l(440));return a.impl.apply(void 0,arguments)}}},Lc={readContext:zt,use:Fo,useCallback:Tm,useContext:zt,useEffect:Nc,useImperativeHandle:Am,useInsertionEffect:Em,useLayoutEffect:Cm,useMemo:jm,useReducer:Bo,useRef:wm,useState:function(){return Bo(dr)},useDebugValue:Ac,useDeferredValue:function(t,n){var a=vt();return Rm(a,nt.memoizedState,t,n)},useTransition:function(){var t=Bo(dr)[0],n=vt().memoizedState;return[typeof t=="boolean"?t:oa(t),n]},useSyncExternalStore:lm,useId:Om,useHostTransitionStatus:Rc,useFormState:ym,useActionState:ym,useOptimistic:function(t,n){var a=vt();return fm(a,nt,t,n)},useMemoCache:wc,useCacheRefresh:Mm};Lc.useEffectEvent=km;var Um={readContext:zt,use:Fo,useCallback:Tm,useContext:zt,useEffect:Nc,useImperativeHandle:Am,useInsertionEffect:Em,useLayoutEffect:Cm,useMemo:jm,useReducer:kc,useRef:wm,useState:function(){return kc(dr)},useDebugValue:Ac,useDeferredValue:function(t,n){var a=vt();return nt===null?Tc(a,t,n):Rm(a,nt.memoizedState,t,n)},useTransition:function(){var t=kc(dr)[0],n=vt().memoizedState;return[typeof t=="boolean"?t:oa(t),n]},useSyncExternalStore:lm,useId:Om,useHostTransitionStatus:Rc,useFormState:vm,useActionState:vm,useOptimistic:function(t,n){var a=vt();return nt!==null?fm(a,nt,t,n):(a.baseState=t,[t,a.queue.dispatch])},useMemoCache:wc,useCacheRefresh:Mm};Um.useEffectEvent=km;function Dc(t,n,a,s){n=t.memoizedState,a=a(s,n),a=a==null?n:b({},n,a),t.memoizedState=a,t.lanes===0&&(t.updateQueue.baseState=a)}var Oc={enqueueSetState:function(t,n,a){t=t._reactInternals;var s=yn(),d=Br(s);d.payload=n,a!=null&&(d.callback=a),n=Ir(t,d,s),n!==null&&(ln(n,t,s),ra(n,t,s))},enqueueReplaceState:function(t,n,a){t=t._reactInternals;var s=yn(),d=Br(s);d.tag=1,d.payload=n,a!=null&&(d.callback=a),n=Ir(t,d,s),n!==null&&(ln(n,t,s),ra(n,t,s))},enqueueForceUpdate:function(t,n){t=t._reactInternals;var a=yn(),s=Br(a);s.tag=2,n!=null&&(s.callback=n),n=Ir(t,s,a),n!==null&&(ln(n,t,a),ra(n,t,a))}};function Hm(t,n,a,s,d,m,k){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(s,m,k):n.prototype&&n.prototype.isPureReactComponent?!Zl(a,s)||!Zl(d,m):!0}function qm(t,n,a,s){t=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(a,s),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(a,s),n.state!==t&&Oc.enqueueReplaceState(n,n.state,null)}function Ai(t,n){var a=n;if("ref"in n){a={};for(var s in n)s!=="ref"&&(a[s]=n[s])}if(t=t.defaultProps){a===n&&(a=b({},a));for(var d in t)a[d]===void 0&&(a[d]=t[d])}return a}function $m(t){xo(t)}function Pm(t){console.error(t)}function Vm(t){xo(t)}function qo(t,n){try{var a=t.onUncaughtError;a(n.value,{componentStack:n.stack})}catch(s){setTimeout(function(){throw s})}}function Gm(t,n,a){try{var s=t.onCaughtError;s(a.value,{componentStack:a.stack,errorBoundary:n.tag===1?n.stateNode:null})}catch(d){setTimeout(function(){throw d})}}function Mc(t,n,a){return a=Br(a),a.tag=3,a.payload={element:null},a.callback=function(){qo(t,n)},a}function Ym(t){return t=Br(t),t.tag=3,t}function Xm(t,n,a,s){var d=a.type.getDerivedStateFromError;if(typeof d=="function"){var m=s.value;t.payload=function(){return d(m)},t.callback=function(){Gm(n,a,s)}}var k=a.stateNode;k!==null&&typeof k.componentDidCatch=="function"&&(t.callback=function(){Gm(n,a,s),typeof d!="function"&&(Vr===null?Vr=new Set([this]):Vr.add(this));var _=s.stack;this.componentDidCatch(s.value,{componentStack:_!==null?_:""})})}function zw(t,n,a,s,d){if(a.flags|=32768,s!==null&&typeof s=="object"&&typeof s.then=="function"){if(n=a.alternate,n!==null&&el(n,a,d,!0),a=pn.current,a!==null){switch(a.tag){case 31:case 13:return _n===null?es():a.alternate===null&&yt===0&&(yt=3),a.flags&=-257,a.flags|=65536,a.lanes=d,s===jo?a.flags|=16384:(n=a.updateQueue,n===null?a.updateQueue=new Set([s]):n.add(s),of(t,s,d)),!1;case 22:return a.flags|=65536,s===jo?a.flags|=16384:(n=a.updateQueue,n===null?(n={transitions:null,markerInstances:null,retryQueue:new Set([s])},a.updateQueue=n):(a=n.retryQueue,a===null?n.retryQueue=new Set([s]):a.add(s)),of(t,s,d)),!1}throw Error(l(435,a.tag))}return of(t,s,d),es(),!1}if(qe)return n=pn.current,n!==null?((n.flags&65536)===0&&(n.flags|=256),n.flags|=65536,n.lanes=d,s!==ec&&(t=Error(l(422),{cause:s}),Jl(An(t,a)))):(s!==ec&&(n=Error(l(423),{cause:s}),Jl(An(n,a))),t=t.current.alternate,t.flags|=65536,d&=-d,t.lanes|=d,s=An(s,a),d=Mc(t.stateNode,s,d),fc(t,d),yt!==4&&(yt=2)),!1;var m=Error(l(520),{cause:s});if(m=An(m,a),ba===null?ba=[m]:ba.push(m),yt!==4&&(yt=2),n===null)return!0;s=An(s,a),a=n;do{switch(a.tag){case 3:return a.flags|=65536,t=d&-d,a.lanes|=t,t=Mc(a.stateNode,s,t),fc(a,t),!1;case 1:if(n=a.type,m=a.stateNode,(a.flags&128)===0&&(typeof n.getDerivedStateFromError=="function"||m!==null&&typeof m.componentDidCatch=="function"&&(Vr===null||!Vr.has(m))))return a.flags|=65536,d&=-d,a.lanes|=d,d=Ym(d),Xm(d,t,a,s),fc(a,d),!1}a=a.return}while(a!==null);return!1}var zc=Error(l(461)),Ct=!1;function Ft(t,n,a,s){n.child=t===null?Jp(n,null,a,s):Ci(n,t.child,a,s)}function Zm(t,n,a,s,d){a=a.render;var m=n.ref;if("ref"in s){var k={};for(var _ in s)_!=="ref"&&(k[_]=s[_])}else k=s;return wi(n),s=bc(t,n,a,k,m,d),_=yc(),t!==null&&!Ct?(xc(t,n,d),hr(t,n,d)):(qe&&_&&Ju(n),n.flags|=1,Ft(t,n,s,d),n.child)}function Km(t,n,a,s,d){if(t===null){var m=a.type;return typeof m=="function"&&!Zu(m)&&m.defaultProps===void 0&&a.compare===null?(n.tag=15,n.type=m,Qm(t,n,m,s,d)):(t=ko(a.type,null,s,n,n.mode,d),t.ref=n.ref,t.return=n,n.child=t)}if(m=t.child,!Pc(t,d)){var k=m.memoizedProps;if(a=a.compare,a=a!==null?a:Zl,a(k,s)&&t.ref===n.ref)return hr(t,n,d)}return n.flags|=1,t=or(m,s),t.ref=n.ref,t.return=n,n.child=t}function Qm(t,n,a,s,d){if(t!==null){var m=t.memoizedProps;if(Zl(m,s)&&t.ref===n.ref)if(Ct=!1,n.pendingProps=s=m,Pc(t,d))(t.flags&131072)!==0&&(Ct=!0);else return n.lanes=t.lanes,hr(t,n,d)}return Fc(t,n,a,s,d)}function Jm(t,n,a,s){var d=s.children,m=t!==null?t.memoizedState:null;if(t===null&&n.stateNode===null&&(n.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),s.mode==="hidden"){if((n.flags&128)!==0){if(m=m!==null?m.baseLanes|a:a,t!==null){for(s=n.child=t.child,d=0;s!==null;)d=d|s.lanes|s.childLanes,s=s.sibling;s=d&~m}else s=0,n.child=null;return Wm(t,n,m,a,s)}if((a&536870912)!==0)n.memoizedState={baseLanes:0,cachePool:null},t!==null&&Ao(n,m!==null?m.cachePool:null),m!==null?tm(n,m):hc(),nm(n);else return s=n.lanes=536870912,Wm(t,n,m!==null?m.baseLanes|a:a,a,s)}else m!==null?(Ao(n,m.cachePool),tm(n,m),Hr(),n.memoizedState=null):(t!==null&&Ao(n,null),hc(),Hr());return Ft(t,n,d,a),n.child}function ca(t,n){return t!==null&&t.tag===22||n.stateNode!==null||(n.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.sibling}function Wm(t,n,a,s,d){var m=oc();return m=m===null?null:{parent:kt._currentValue,pool:m},n.memoizedState={baseLanes:a,cachePool:m},t!==null&&Ao(n,null),hc(),nm(n),t!==null&&el(t,n,s,!0),n.childLanes=d,null}function $o(t,n){return n=Vo({mode:n.mode,children:n.children},t.mode),n.ref=t.ref,t.child=n,n.return=t,n}function eg(t,n,a){return Ci(n,t.child,null,a),t=$o(n,n.pendingProps),t.flags|=2,mn(n),n.memoizedState=null,t}function Fw(t,n,a){var s=n.pendingProps,d=(n.flags&128)!==0;if(n.flags&=-129,t===null){if(qe){if(s.mode==="hidden")return t=$o(n,s),n.lanes=536870912,ca(null,t);if(mc(n),(t=ft)?(t=db(t,Rn),t=t!==null&&t.data==="&"?t:null,t!==null&&(n.memoizedState={dehydrated:t,treeContext:Dr!==null?{id:Yn,overflow:Xn}:null,retryLane:536870912,hydrationErrors:null},a=Fp(t),a.return=n,n.child=a,Mt=n,ft=null)):t=null,t===null)throw Mr(n);return n.lanes=536870912,null}return $o(n,s)}var m=t.memoizedState;if(m!==null){var k=m.dehydrated;if(mc(n),d)if(n.flags&256)n.flags&=-257,n=eg(t,n,a);else if(n.memoizedState!==null)n.child=t.child,n.flags|=128,n=null;else throw Error(l(558));else if(Ct||el(t,n,a,!1),d=(a&t.childLanes)!==0,Ct||d){if(s=ot,s!==null&&(k=io(s,a),k!==0&&k!==m.retryLane))throw m.retryLane=k,bi(t,k),ln(s,t,k),zc;es(),n=eg(t,n,a)}else t=m.treeContext,ft=Ln(k.nextSibling),Mt=n,qe=!0,Or=null,Rn=!1,t!==null&&Up(n,t),n=$o(n,s),n.flags|=4096;return n}return t=or(t.child,{mode:s.mode,children:s.children}),t.ref=n.ref,n.child=t,t.return=n,t}function Po(t,n){var a=n.ref;if(a===null)t!==null&&t.ref!==null&&(n.flags|=4194816);else{if(typeof a!="function"&&typeof a!="object")throw Error(l(284));(t===null||t.ref!==a)&&(n.flags|=4194816)}}function Fc(t,n,a,s,d){return wi(n),a=bc(t,n,a,s,void 0,d),s=yc(),t!==null&&!Ct?(xc(t,n,d),hr(t,n,d)):(qe&&s&&Ju(n),n.flags|=1,Ft(t,n,a,d),n.child)}function tg(t,n,a,s,d,m){return wi(n),n.updateQueue=null,a=im(n,s,a,d),rm(t),s=yc(),t!==null&&!Ct?(xc(t,n,m),hr(t,n,m)):(qe&&s&&Ju(n),n.flags|=1,Ft(t,n,a,m),n.child)}function ng(t,n,a,s,d){if(wi(n),n.stateNode===null){var m=Ki,k=a.contextType;typeof k=="object"&&k!==null&&(m=zt(k)),m=new a(s,m),n.memoizedState=m.state!==null&&m.state!==void 0?m.state:null,m.updater=Oc,n.stateNode=m,m._reactInternals=n,m=n.stateNode,m.props=s,m.state=n.memoizedState,m.refs={},uc(n),k=a.contextType,m.context=typeof k=="object"&&k!==null?zt(k):Ki,m.state=n.memoizedState,k=a.getDerivedStateFromProps,typeof k=="function"&&(Dc(n,a,k,s),m.state=n.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof m.getSnapshotBeforeUpdate=="function"||typeof m.UNSAFE_componentWillMount!="function"&&typeof m.componentWillMount!="function"||(k=m.state,typeof m.componentWillMount=="function"&&m.componentWillMount(),typeof m.UNSAFE_componentWillMount=="function"&&m.UNSAFE_componentWillMount(),k!==m.state&&Oc.enqueueReplaceState(m,m.state,null),la(n,s,m,d),ia(),m.state=n.memoizedState),typeof m.componentDidMount=="function"&&(n.flags|=4194308),s=!0}else if(t===null){m=n.stateNode;var _=n.memoizedProps,P=Ai(a,_);m.props=P;var ee=m.context,oe=a.contextType;k=Ki,typeof oe=="object"&&oe!==null&&(k=zt(oe));var ce=a.getDerivedStateFromProps;oe=typeof ce=="function"||typeof m.getSnapshotBeforeUpdate=="function",_=n.pendingProps!==_,oe||typeof m.UNSAFE_componentWillReceiveProps!="function"&&typeof m.componentWillReceiveProps!="function"||(_||ee!==k)&&qm(n,m,s,k),Fr=!1;var ne=n.memoizedState;m.state=ne,la(n,s,m,d),ia(),ee=n.memoizedState,_||ne!==ee||Fr?(typeof ce=="function"&&(Dc(n,a,ce,s),ee=n.memoizedState),(P=Fr||Hm(n,a,P,s,ne,ee,k))?(oe||typeof m.UNSAFE_componentWillMount!="function"&&typeof m.componentWillMount!="function"||(typeof m.componentWillMount=="function"&&m.componentWillMount(),typeof m.UNSAFE_componentWillMount=="function"&&m.UNSAFE_componentWillMount()),typeof m.componentDidMount=="function"&&(n.flags|=4194308)):(typeof m.componentDidMount=="function"&&(n.flags|=4194308),n.memoizedProps=s,n.memoizedState=ee),m.props=s,m.state=ee,m.context=k,s=P):(typeof m.componentDidMount=="function"&&(n.flags|=4194308),s=!1)}else{m=n.stateNode,cc(t,n),k=n.memoizedProps,oe=Ai(a,k),m.props=oe,ce=n.pendingProps,ne=m.context,ee=a.contextType,P=Ki,typeof ee=="object"&&ee!==null&&(P=zt(ee)),_=a.getDerivedStateFromProps,(ee=typeof _=="function"||typeof m.getSnapshotBeforeUpdate=="function")||typeof m.UNSAFE_componentWillReceiveProps!="function"&&typeof m.componentWillReceiveProps!="function"||(k!==ce||ne!==P)&&qm(n,m,s,P),Fr=!1,ne=n.memoizedState,m.state=ne,la(n,s,m,d),ia();var le=n.memoizedState;k!==ce||ne!==le||Fr||t!==null&&t.dependencies!==null&&Co(t.dependencies)?(typeof _=="function"&&(Dc(n,a,_,s),le=n.memoizedState),(oe=Fr||Hm(n,a,oe,s,ne,le,P)||t!==null&&t.dependencies!==null&&Co(t.dependencies))?(ee||typeof m.UNSAFE_componentWillUpdate!="function"&&typeof m.componentWillUpdate!="function"||(typeof m.componentWillUpdate=="function"&&m.componentWillUpdate(s,le,P),typeof m.UNSAFE_componentWillUpdate=="function"&&m.UNSAFE_componentWillUpdate(s,le,P)),typeof m.componentDidUpdate=="function"&&(n.flags|=4),typeof m.getSnapshotBeforeUpdate=="function"&&(n.flags|=1024)):(typeof m.componentDidUpdate!="function"||k===t.memoizedProps&&ne===t.memoizedState||(n.flags|=4),typeof m.getSnapshotBeforeUpdate!="function"||k===t.memoizedProps&&ne===t.memoizedState||(n.flags|=1024),n.memoizedProps=s,n.memoizedState=le),m.props=s,m.state=le,m.context=P,s=oe):(typeof m.componentDidUpdate!="function"||k===t.memoizedProps&&ne===t.memoizedState||(n.flags|=4),typeof m.getSnapshotBeforeUpdate!="function"||k===t.memoizedProps&&ne===t.memoizedState||(n.flags|=1024),s=!1)}return m=s,Po(t,n),s=(n.flags&128)!==0,m||s?(m=n.stateNode,a=s&&typeof a.getDerivedStateFromError!="function"?null:m.render(),n.flags|=1,t!==null&&s?(n.child=Ci(n,t.child,null,d),n.child=Ci(n,null,a,d)):Ft(t,n,a,d),n.memoizedState=m.state,t=n.child):t=hr(t,n,d),t}function rg(t,n,a,s){return xi(),n.flags|=256,Ft(t,n,a,s),n.child}var Bc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Ic(t){return{baseLanes:t,cachePool:Gp()}}function Uc(t,n,a){return t=t!==null?t.childLanes&~a:0,n&&(t|=bn),t}function ig(t,n,a){var s=n.pendingProps,d=!1,m=(n.flags&128)!==0,k;if((k=m)||(k=t!==null&&t.memoizedState===null?!1:(xt.current&2)!==0),k&&(d=!0,n.flags&=-129),k=(n.flags&32)!==0,n.flags&=-33,t===null){if(qe){if(d?Ur(n):Hr(),(t=ft)?(t=db(t,Rn),t=t!==null&&t.data!=="&"?t:null,t!==null&&(n.memoizedState={dehydrated:t,treeContext:Dr!==null?{id:Yn,overflow:Xn}:null,retryLane:536870912,hydrationErrors:null},a=Fp(t),a.return=n,n.child=a,Mt=n,ft=null)):t=null,t===null)throw Mr(n);return kf(t)?n.lanes=32:n.lanes=536870912,null}var _=s.children;return s=s.fallback,d?(Hr(),d=n.mode,_=Vo({mode:"hidden",children:_},d),s=yi(s,d,a,null),_.return=n,s.return=n,_.sibling=s,n.child=_,s=n.child,s.memoizedState=Ic(a),s.childLanes=Uc(t,k,a),n.memoizedState=Bc,ca(null,s)):(Ur(n),Hc(n,_))}var P=t.memoizedState;if(P!==null&&(_=P.dehydrated,_!==null)){if(m)n.flags&256?(Ur(n),n.flags&=-257,n=qc(t,n,a)):n.memoizedState!==null?(Hr(),n.child=t.child,n.flags|=128,n=null):(Hr(),_=s.fallback,d=n.mode,s=Vo({mode:"visible",children:s.children},d),_=yi(_,d,a,null),_.flags|=2,s.return=n,_.return=n,s.sibling=_,n.child=s,Ci(n,t.child,null,a),s=n.child,s.memoizedState=Ic(a),s.childLanes=Uc(t,k,a),n.memoizedState=Bc,n=ca(null,s));else if(Ur(n),kf(_)){if(k=_.nextSibling&&_.nextSibling.dataset,k)var ee=k.dgst;k=ee,s=Error(l(419)),s.stack="",s.digest=k,Jl({value:s,source:null,stack:null}),n=qc(t,n,a)}else if(Ct||el(t,n,a,!1),k=(a&t.childLanes)!==0,Ct||k){if(k=ot,k!==null&&(s=io(k,a),s!==0&&s!==P.retryLane))throw P.retryLane=s,bi(t,s),ln(k,t,s),zc;Sf(_)||es(),n=qc(t,n,a)}else Sf(_)?(n.flags|=192,n.child=t.child,n=null):(t=P.treeContext,ft=Ln(_.nextSibling),Mt=n,qe=!0,Or=null,Rn=!1,t!==null&&Up(n,t),n=Hc(n,s.children),n.flags|=4096);return n}return d?(Hr(),_=s.fallback,d=n.mode,P=t.child,ee=P.sibling,s=or(P,{mode:"hidden",children:s.children}),s.subtreeFlags=P.subtreeFlags&65011712,ee!==null?_=or(ee,_):(_=yi(_,d,a,null),_.flags|=2),_.return=n,s.return=n,s.sibling=_,n.child=s,ca(null,s),s=n.child,_=t.child.memoizedState,_===null?_=Ic(a):(d=_.cachePool,d!==null?(P=kt._currentValue,d=d.parent!==P?{parent:P,pool:P}:d):d=Gp(),_={baseLanes:_.baseLanes|a,cachePool:d}),s.memoizedState=_,s.childLanes=Uc(t,k,a),n.memoizedState=Bc,ca(t.child,s)):(Ur(n),a=t.child,t=a.sibling,a=or(a,{mode:"visible",children:s.children}),a.return=n,a.sibling=null,t!==null&&(k=n.deletions,k===null?(n.deletions=[t],n.flags|=16):k.push(t)),n.child=a,n.memoizedState=null,a)}function Hc(t,n){return n=Vo({mode:"visible",children:n},t.mode),n.return=t,t.child=n}function Vo(t,n){return t=hn(22,t,null,n),t.lanes=0,t}function qc(t,n,a){return Ci(n,t.child,null,a),t=Hc(n,n.pendingProps.children),t.flags|=2,n.memoizedState=null,t}function lg(t,n,a){t.lanes|=n;var s=t.alternate;s!==null&&(s.lanes|=n),rc(t.return,n,a)}function $c(t,n,a,s,d,m){var k=t.memoizedState;k===null?t.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:s,tail:a,tailMode:d,treeForkCount:m}:(k.isBackwards=n,k.rendering=null,k.renderingStartTime=0,k.last=s,k.tail=a,k.tailMode=d,k.treeForkCount=m)}function ag(t,n,a){var s=n.pendingProps,d=s.revealOrder,m=s.tail;s=s.children;var k=xt.current,_=(k&2)!==0;if(_?(k=k&1|2,n.flags|=128):k&=1,T(xt,k),Ft(t,n,s,a),s=qe?Ql:0,!_&&t!==null&&(t.flags&128)!==0)e:for(t=n.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&lg(t,a,n);else if(t.tag===19)lg(t,a,n);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===n)break e;for(;t.sibling===null;){if(t.return===null||t.return===n)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(d){case"forwards":for(a=n.child,d=null;a!==null;)t=a.alternate,t!==null&&Do(t)===null&&(d=a),a=a.sibling;a=d,a===null?(d=n.child,n.child=null):(d=a.sibling,a.sibling=null),$c(n,!1,d,a,m,s);break;case"backwards":case"unstable_legacy-backwards":for(a=null,d=n.child,n.child=null;d!==null;){if(t=d.alternate,t!==null&&Do(t)===null){n.child=d;break}t=d.sibling,d.sibling=a,a=d,d=t}$c(n,!0,a,null,m,s);break;case"together":$c(n,!1,null,null,void 0,s);break;default:n.memoizedState=null}return n.child}function hr(t,n,a){if(t!==null&&(n.dependencies=t.dependencies),Pr|=n.lanes,(a&n.childLanes)===0)if(t!==null){if(el(t,n,a,!1),(a&n.childLanes)===0)return null}else return null;if(t!==null&&n.child!==t.child)throw Error(l(153));if(n.child!==null){for(t=n.child,a=or(t,t.pendingProps),n.child=a,a.return=n;t.sibling!==null;)t=t.sibling,a=a.sibling=or(t,t.pendingProps),a.return=n;a.sibling=null}return n.child}function Pc(t,n){return(t.lanes&n)!==0?!0:(t=t.dependencies,!!(t!==null&&Co(t)))}function Bw(t,n,a){switch(n.tag){case 3:ye(n,n.stateNode.containerInfo),zr(n,kt,t.memoizedState.cache),xi();break;case 27:case 5:me(n);break;case 4:ye(n,n.stateNode.containerInfo);break;case 10:zr(n,n.type,n.memoizedProps.value);break;case 31:if(n.memoizedState!==null)return n.flags|=128,mc(n),null;break;case 13:var s=n.memoizedState;if(s!==null)return s.dehydrated!==null?(Ur(n),n.flags|=128,null):(a&n.child.childLanes)!==0?ig(t,n,a):(Ur(n),t=hr(t,n,a),t!==null?t.sibling:null);Ur(n);break;case 19:var d=(t.flags&128)!==0;if(s=(a&n.childLanes)!==0,s||(el(t,n,a,!1),s=(a&n.childLanes)!==0),d){if(s)return ag(t,n,a);n.flags|=128}if(d=n.memoizedState,d!==null&&(d.rendering=null,d.tail=null,d.lastEffect=null),T(xt,xt.current),s)break;return null;case 22:return n.lanes=0,Jm(t,n,a,n.pendingProps);case 24:zr(n,kt,t.memoizedState.cache)}return hr(t,n,a)}function og(t,n,a){if(t!==null)if(t.memoizedProps!==n.pendingProps)Ct=!0;else{if(!Pc(t,a)&&(n.flags&128)===0)return Ct=!1,Bw(t,n,a);Ct=(t.flags&131072)!==0}else Ct=!1,qe&&(n.flags&1048576)!==0&&Ip(n,Ql,n.index);switch(n.lanes=0,n.tag){case 16:e:{var s=n.pendingProps;if(t=ki(n.elementType),n.type=t,typeof t=="function")Zu(t)?(s=Ai(t,s),n.tag=1,n=ng(null,n,t,s,a)):(n.tag=0,n=Fc(null,n,t,s,a));else{if(t!=null){var d=t.$$typeof;if(d===z){n.tag=11,n=Zm(null,n,t,s,a);break e}else if(d===O){n.tag=14,n=Km(null,n,t,s,a);break e}}throw n=U(t)||t,Error(l(306,n,""))}}return n;case 0:return Fc(t,n,n.type,n.pendingProps,a);case 1:return s=n.type,d=Ai(s,n.pendingProps),ng(t,n,s,d,a);case 3:e:{if(ye(n,n.stateNode.containerInfo),t===null)throw Error(l(387));s=n.pendingProps;var m=n.memoizedState;d=m.element,cc(t,n),la(n,s,null,a);var k=n.memoizedState;if(s=k.cache,zr(n,kt,s),s!==m.cache&&ic(n,[kt],a,!0),ia(),s=k.element,m.isDehydrated)if(m={element:s,isDehydrated:!1,cache:k.cache},n.updateQueue.baseState=m,n.memoizedState=m,n.flags&256){n=rg(t,n,s,a);break e}else if(s!==d){d=An(Error(l(424)),n),Jl(d),n=rg(t,n,s,a);break e}else for(t=n.stateNode.containerInfo,t.nodeType===9?t=t.body:t=t.nodeName==="HTML"?t.ownerDocument.body:t,ft=Ln(t.firstChild),Mt=n,qe=!0,Or=null,Rn=!0,a=Jp(n,null,s,a),n.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling;else{if(xi(),s===d){n=hr(t,n,a);break e}Ft(t,n,s,a)}n=n.child}return n;case 26:return Po(t,n),t===null?(a=yb(n.type,null,n.pendingProps,null))?n.memoizedState=a:qe||(a=n.type,t=n.pendingProps,s=os(fe.current).createElement(a),s[Tt]=n,s[wt]=t,Bt(s,a,t),Se(s),n.stateNode=s):n.memoizedState=yb(n.type,t.memoizedProps,n.pendingProps,t.memoizedState),null;case 27:return me(n),t===null&&qe&&(s=n.stateNode=mb(n.type,n.pendingProps,fe.current),Mt=n,Rn=!0,d=ft,Zr(n.type)?(Ef=d,ft=Ln(s.firstChild)):ft=d),Ft(t,n,n.pendingProps.children,a),Po(t,n),t===null&&(n.flags|=4194304),n.child;case 5:return t===null&&qe&&((d=s=ft)&&(s=pS(s,n.type,n.pendingProps,Rn),s!==null?(n.stateNode=s,Mt=n,ft=Ln(s.firstChild),Rn=!1,d=!0):d=!1),d||Mr(n)),me(n),d=n.type,m=n.pendingProps,k=t!==null?t.memoizedProps:null,s=m.children,xf(d,m)?s=null:k!==null&&xf(d,k)&&(n.flags|=32),n.memoizedState!==null&&(d=bc(t,n,jw,null,null,a),Ca._currentValue=d),Po(t,n),Ft(t,n,s,a),n.child;case 6:return t===null&&qe&&((t=a=ft)&&(a=mS(a,n.pendingProps,Rn),a!==null?(n.stateNode=a,Mt=n,ft=null,t=!0):t=!1),t||Mr(n)),null;case 13:return ig(t,n,a);case 4:return ye(n,n.stateNode.containerInfo),s=n.pendingProps,t===null?n.child=Ci(n,null,s,a):Ft(t,n,s,a),n.child;case 11:return Zm(t,n,n.type,n.pendingProps,a);case 7:return Ft(t,n,n.pendingProps,a),n.child;case 8:return Ft(t,n,n.pendingProps.children,a),n.child;case 12:return Ft(t,n,n.pendingProps.children,a),n.child;case 10:return s=n.pendingProps,zr(n,n.type,s.value),Ft(t,n,s.children,a),n.child;case 9:return d=n.type._context,s=n.pendingProps.children,wi(n),d=zt(d),s=s(d),n.flags|=1,Ft(t,n,s,a),n.child;case 14:return Km(t,n,n.type,n.pendingProps,a);case 15:return Qm(t,n,n.type,n.pendingProps,a);case 19:return ag(t,n,a);case 31:return Fw(t,n,a);case 22:return Jm(t,n,a,n.pendingProps);case 24:return wi(n),s=zt(kt),t===null?(d=oc(),d===null&&(d=ot,m=lc(),d.pooledCache=m,m.refCount++,m!==null&&(d.pooledCacheLanes|=a),d=m),n.memoizedState={parent:s,cache:d},uc(n),zr(n,kt,d)):((t.lanes&a)!==0&&(cc(t,n),la(n,null,null,a),ia()),d=t.memoizedState,m=n.memoizedState,d.parent!==s?(d={parent:s,cache:s},n.memoizedState=d,n.lanes===0&&(n.memoizedState=n.updateQueue.baseState=d),zr(n,kt,s)):(s=m.cache,zr(n,kt,s),s!==d.cache&&ic(n,[kt],a,!0))),Ft(t,n,n.pendingProps.children,a),n.child;case 29:throw n.pendingProps}throw Error(l(156,n.tag))}function pr(t){t.flags|=4}function Vc(t,n,a,s,d){if((n=(t.mode&32)!==0)&&(n=!1),n){if(t.flags|=16777216,(d&335544128)===d)if(t.stateNode.complete)t.flags|=8192;else if(Og())t.flags|=8192;else throw Ei=jo,sc}else t.flags&=-16777217}function sg(t,n){if(n.type!=="stylesheet"||(n.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!kb(n))if(Og())t.flags|=8192;else throw Ei=jo,sc}function Go(t,n){n!==null&&(t.flags|=4),t.flags&16384&&(n=t.tag!==22?Bl():536870912,t.lanes|=n,dl|=n)}function fa(t,n){if(!qe)switch(t.tailMode){case"hidden":n=t.tail;for(var a=null;n!==null;)n.alternate!==null&&(a=n),n=n.sibling;a===null?t.tail=null:a.sibling=null;break;case"collapsed":a=t.tail;for(var s=null;a!==null;)a.alternate!==null&&(s=a),a=a.sibling;s===null?n||t.tail===null?t.tail=null:t.tail.sibling=null:s.sibling=null}}function dt(t){var n=t.alternate!==null&&t.alternate.child===t.child,a=0,s=0;if(n)for(var d=t.child;d!==null;)a|=d.lanes|d.childLanes,s|=d.subtreeFlags&65011712,s|=d.flags&65011712,d.return=t,d=d.sibling;else for(d=t.child;d!==null;)a|=d.lanes|d.childLanes,s|=d.subtreeFlags,s|=d.flags,d.return=t,d=d.sibling;return t.subtreeFlags|=s,t.childLanes=a,n}function Iw(t,n,a){var s=n.pendingProps;switch(Wu(n),n.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return dt(n),null;case 1:return dt(n),null;case 3:return a=n.stateNode,s=null,t!==null&&(s=t.memoizedState.cache),n.memoizedState.cache!==s&&(n.flags|=2048),cr(kt),pe(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(t===null||t.child===null)&&(Wi(n)?pr(n):t===null||t.memoizedState.isDehydrated&&(n.flags&256)===0||(n.flags|=1024,tc())),dt(n),null;case 26:var d=n.type,m=n.memoizedState;return t===null?(pr(n),m!==null?(dt(n),sg(n,m)):(dt(n),Vc(n,d,null,s,a))):m?m!==t.memoizedState?(pr(n),dt(n),sg(n,m)):(dt(n),n.flags&=-16777217):(t=t.memoizedProps,t!==s&&pr(n),dt(n),Vc(n,d,t,s,a)),null;case 27:if(xe(n),a=fe.current,d=n.type,t!==null&&n.stateNode!=null)t.memoizedProps!==s&&pr(n);else{if(!s){if(n.stateNode===null)throw Error(l(166));return dt(n),null}t=te.current,Wi(n)?Hp(n):(t=mb(d,s,a),n.stateNode=t,pr(n))}return dt(n),null;case 5:if(xe(n),d=n.type,t!==null&&n.stateNode!=null)t.memoizedProps!==s&&pr(n);else{if(!s){if(n.stateNode===null)throw Error(l(166));return dt(n),null}if(m=te.current,Wi(n))Hp(n);else{var k=os(fe.current);switch(m){case 1:m=k.createElementNS("http://www.w3.org/2000/svg",d);break;case 2:m=k.createElementNS("http://www.w3.org/1998/Math/MathML",d);break;default:switch(d){case"svg":m=k.createElementNS("http://www.w3.org/2000/svg",d);break;case"math":m=k.createElementNS("http://www.w3.org/1998/Math/MathML",d);break;case"script":m=k.createElement("div"),m.innerHTML="<script><\/script>",m=m.removeChild(m.firstChild);break;case"select":m=typeof s.is=="string"?k.createElement("select",{is:s.is}):k.createElement("select"),s.multiple?m.multiple=!0:s.size&&(m.size=s.size);break;default:m=typeof s.is=="string"?k.createElement(d,{is:s.is}):k.createElement(d)}}m[Tt]=n,m[wt]=s;e:for(k=n.child;k!==null;){if(k.tag===5||k.tag===6)m.appendChild(k.stateNode);else if(k.tag!==4&&k.tag!==27&&k.child!==null){k.child.return=k,k=k.child;continue}if(k===n)break e;for(;k.sibling===null;){if(k.return===null||k.return===n)break e;k=k.return}k.sibling.return=k.return,k=k.sibling}n.stateNode=m;e:switch(Bt(m,d,s),d){case"button":case"input":case"select":case"textarea":s=!!s.autoFocus;break e;case"img":s=!0;break e;default:s=!1}s&&pr(n)}}return dt(n),Vc(n,n.type,t===null?null:t.memoizedProps,n.pendingProps,a),null;case 6:if(t&&n.stateNode!=null)t.memoizedProps!==s&&pr(n);else{if(typeof s!="string"&&n.stateNode===null)throw Error(l(166));if(t=fe.current,Wi(n)){if(t=n.stateNode,a=n.memoizedProps,s=null,d=Mt,d!==null)switch(d.tag){case 27:case 5:s=d.memoizedProps}t[Tt]=n,t=!!(t.nodeValue===a||s!==null&&s.suppressHydrationWarning===!0||ib(t.nodeValue,a)),t||Mr(n,!0)}else t=os(t).createTextNode(s),t[Tt]=n,n.stateNode=t}return dt(n),null;case 31:if(a=n.memoizedState,t===null||t.memoizedState!==null){if(s=Wi(n),a!==null){if(t===null){if(!s)throw Error(l(318));if(t=n.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(l(557));t[Tt]=n}else xi(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;dt(n),t=!1}else a=tc(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=a),t=!0;if(!t)return n.flags&256?(mn(n),n):(mn(n),null);if((n.flags&128)!==0)throw Error(l(558))}return dt(n),null;case 13:if(s=n.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(d=Wi(n),s!==null&&s.dehydrated!==null){if(t===null){if(!d)throw Error(l(318));if(d=n.memoizedState,d=d!==null?d.dehydrated:null,!d)throw Error(l(317));d[Tt]=n}else xi(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;dt(n),d=!1}else d=tc(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=d),d=!0;if(!d)return n.flags&256?(mn(n),n):(mn(n),null)}return mn(n),(n.flags&128)!==0?(n.lanes=a,n):(a=s!==null,t=t!==null&&t.memoizedState!==null,a&&(s=n.child,d=null,s.alternate!==null&&s.alternate.memoizedState!==null&&s.alternate.memoizedState.cachePool!==null&&(d=s.alternate.memoizedState.cachePool.pool),m=null,s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(m=s.memoizedState.cachePool.pool),m!==d&&(s.flags|=2048)),a!==t&&a&&(n.child.flags|=8192),Go(n,n.updateQueue),dt(n),null);case 4:return pe(),t===null&&pf(n.stateNode.containerInfo),dt(n),null;case 10:return cr(n.type),dt(n),null;case 19:if(q(xt),s=n.memoizedState,s===null)return dt(n),null;if(d=(n.flags&128)!==0,m=s.rendering,m===null)if(d)fa(s,!1);else{if(yt!==0||t!==null&&(t.flags&128)!==0)for(t=n.child;t!==null;){if(m=Do(t),m!==null){for(n.flags|=128,fa(s,!1),t=m.updateQueue,n.updateQueue=t,Go(n,t),n.subtreeFlags=0,t=a,a=n.child;a!==null;)zp(a,t),a=a.sibling;return T(xt,xt.current&1|2),qe&&sr(n,s.treeForkCount),n.child}t=t.sibling}s.tail!==null&&at()>Qo&&(n.flags|=128,d=!0,fa(s,!1),n.lanes=4194304)}else{if(!d)if(t=Do(m),t!==null){if(n.flags|=128,d=!0,t=t.updateQueue,n.updateQueue=t,Go(n,t),fa(s,!0),s.tail===null&&s.tailMode==="hidden"&&!m.alternate&&!qe)return dt(n),null}else 2*at()-s.renderingStartTime>Qo&&a!==536870912&&(n.flags|=128,d=!0,fa(s,!1),n.lanes=4194304);s.isBackwards?(m.sibling=n.child,n.child=m):(t=s.last,t!==null?t.sibling=m:n.child=m,s.last=m)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=at(),t.sibling=null,a=xt.current,T(xt,d?a&1|2:a&1),qe&&sr(n,s.treeForkCount),t):(dt(n),null);case 22:case 23:return mn(n),pc(),s=n.memoizedState!==null,t!==null?t.memoizedState!==null!==s&&(n.flags|=8192):s&&(n.flags|=8192),s?(a&536870912)!==0&&(n.flags&128)===0&&(dt(n),n.subtreeFlags&6&&(n.flags|=8192)):dt(n),a=n.updateQueue,a!==null&&Go(n,a.retryQueue),a=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(a=t.memoizedState.cachePool.pool),s=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(s=n.memoizedState.cachePool.pool),s!==a&&(n.flags|=2048),t!==null&&q(Si),null;case 24:return a=null,t!==null&&(a=t.memoizedState.cache),n.memoizedState.cache!==a&&(n.flags|=2048),cr(kt),dt(n),null;case 25:return null;case 30:return null}throw Error(l(156,n.tag))}function Uw(t,n){switch(Wu(n),n.tag){case 1:return t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 3:return cr(kt),pe(),t=n.flags,(t&65536)!==0&&(t&128)===0?(n.flags=t&-65537|128,n):null;case 26:case 27:case 5:return xe(n),null;case 31:if(n.memoizedState!==null){if(mn(n),n.alternate===null)throw Error(l(340));xi()}return t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 13:if(mn(n),t=n.memoizedState,t!==null&&t.dehydrated!==null){if(n.alternate===null)throw Error(l(340));xi()}return t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 19:return q(xt),null;case 4:return pe(),null;case 10:return cr(n.type),null;case 22:case 23:return mn(n),pc(),t!==null&&q(Si),t=n.flags,t&65536?(n.flags=t&-65537|128,n):null;case 24:return cr(kt),null;case 25:return null;default:return null}}function ug(t,n){switch(Wu(n),n.tag){case 3:cr(kt),pe();break;case 26:case 27:case 5:xe(n);break;case 4:pe();break;case 31:n.memoizedState!==null&&mn(n);break;case 13:mn(n);break;case 19:q(xt);break;case 10:cr(n.type);break;case 22:case 23:mn(n),pc(),t!==null&&q(Si);break;case 24:cr(kt)}}function da(t,n){try{var a=n.updateQueue,s=a!==null?a.lastEffect:null;if(s!==null){var d=s.next;a=d;do{if((a.tag&t)===t){s=void 0;var m=a.create,k=a.inst;s=m(),k.destroy=s}a=a.next}while(a!==d)}}catch(_){et(n,n.return,_)}}function qr(t,n,a){try{var s=n.updateQueue,d=s!==null?s.lastEffect:null;if(d!==null){var m=d.next;s=m;do{if((s.tag&t)===t){var k=s.inst,_=k.destroy;if(_!==void 0){k.destroy=void 0,d=n;var P=a,ee=_;try{ee()}catch(oe){et(d,P,oe)}}}s=s.next}while(s!==m)}}catch(oe){et(n,n.return,oe)}}function cg(t){var n=t.updateQueue;if(n!==null){var a=t.stateNode;try{em(n,a)}catch(s){et(t,t.return,s)}}}function fg(t,n,a){a.props=Ai(t.type,t.memoizedProps),a.state=t.memoizedState;try{a.componentWillUnmount()}catch(s){et(t,n,s)}}function ha(t,n){try{var a=t.ref;if(a!==null){switch(t.tag){case 26:case 27:case 5:var s=t.stateNode;break;case 30:s=t.stateNode;break;default:s=t.stateNode}typeof a=="function"?t.refCleanup=a(s):a.current=s}}catch(d){et(t,n,d)}}function Zn(t,n){var a=t.ref,s=t.refCleanup;if(a!==null)if(typeof s=="function")try{s()}catch(d){et(t,n,d)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(d){et(t,n,d)}else a.current=null}function dg(t){var n=t.type,a=t.memoizedProps,s=t.stateNode;try{e:switch(n){case"button":case"input":case"select":case"textarea":a.autoFocus&&s.focus();break e;case"img":a.src?s.src=a.src:a.srcSet&&(s.srcset=a.srcSet)}}catch(d){et(t,t.return,d)}}function Gc(t,n,a){try{var s=t.stateNode;sS(s,t.type,a,n),s[wt]=n}catch(d){et(t,t.return,d)}}function hg(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&Zr(t.type)||t.tag===4}function Yc(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||hg(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&Zr(t.type)||t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Xc(t,n,a){var s=t.tag;if(s===5||s===6)t=t.stateNode,n?(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a).insertBefore(t,n):(n=a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,n.appendChild(t),a=a._reactRootContainer,a!=null||n.onclick!==null||(n.onclick=lr));else if(s!==4&&(s===27&&Zr(t.type)&&(a=t.stateNode,n=null),t=t.child,t!==null))for(Xc(t,n,a),t=t.sibling;t!==null;)Xc(t,n,a),t=t.sibling}function Yo(t,n,a){var s=t.tag;if(s===5||s===6)t=t.stateNode,n?a.insertBefore(t,n):a.appendChild(t);else if(s!==4&&(s===27&&Zr(t.type)&&(a=t.stateNode),t=t.child,t!==null))for(Yo(t,n,a),t=t.sibling;t!==null;)Yo(t,n,a),t=t.sibling}function pg(t){var n=t.stateNode,a=t.memoizedProps;try{for(var s=t.type,d=n.attributes;d.length;)n.removeAttributeNode(d[0]);Bt(n,s,a),n[Tt]=t,n[wt]=a}catch(m){et(t,t.return,m)}}var mr=!1,Nt=!1,Zc=!1,mg=typeof WeakSet=="function"?WeakSet:Set,_t=null;function Hw(t,n){if(t=t.containerInfo,bf=ps,t=Ap(t),qu(t)){if("selectionStart"in t)var a={start:t.selectionStart,end:t.selectionEnd};else e:{a=(a=t.ownerDocument)&&a.defaultView||window;var s=a.getSelection&&a.getSelection();if(s&&s.rangeCount!==0){a=s.anchorNode;var d=s.anchorOffset,m=s.focusNode;s=s.focusOffset;try{a.nodeType,m.nodeType}catch{a=null;break e}var k=0,_=-1,P=-1,ee=0,oe=0,ce=t,ne=null;t:for(;;){for(var le;ce!==a||d!==0&&ce.nodeType!==3||(_=k+d),ce!==m||s!==0&&ce.nodeType!==3||(P=k+s),ce.nodeType===3&&(k+=ce.nodeValue.length),(le=ce.firstChild)!==null;)ne=ce,ce=le;for(;;){if(ce===t)break t;if(ne===a&&++ee===d&&(_=k),ne===m&&++oe===s&&(P=k),(le=ce.nextSibling)!==null)break;ce=ne,ne=ce.parentNode}ce=le}a=_===-1||P===-1?null:{start:_,end:P}}else a=null}a=a||{start:0,end:0}}else a=null;for(yf={focusedElem:t,selectionRange:a},ps=!1,_t=n;_t!==null;)if(n=_t,t=n.child,(n.subtreeFlags&1028)!==0&&t!==null)t.return=n,_t=t;else for(;_t!==null;){switch(n=_t,m=n.alternate,t=n.flags,n.tag){case 0:if((t&4)!==0&&(t=n.updateQueue,t=t!==null?t.events:null,t!==null))for(a=0;a<t.length;a++)d=t[a],d.ref.impl=d.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&m!==null){t=void 0,a=n,d=m.memoizedProps,m=m.memoizedState,s=a.stateNode;try{var ke=Ai(a.type,d);t=s.getSnapshotBeforeUpdate(ke,m),s.__reactInternalSnapshotBeforeUpdate=t}catch(je){et(a,a.return,je)}}break;case 3:if((t&1024)!==0){if(t=n.stateNode.containerInfo,a=t.nodeType,a===9)wf(t);else if(a===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":wf(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(l(163))}if(t=n.sibling,t!==null){t.return=n.return,_t=t;break}_t=n.return}}function gg(t,n,a){var s=a.flags;switch(a.tag){case 0:case 11:case 15:br(t,a),s&4&&da(5,a);break;case 1:if(br(t,a),s&4)if(t=a.stateNode,n===null)try{t.componentDidMount()}catch(k){et(a,a.return,k)}else{var d=Ai(a.type,n.memoizedProps);n=n.memoizedState;try{t.componentDidUpdate(d,n,t.__reactInternalSnapshotBeforeUpdate)}catch(k){et(a,a.return,k)}}s&64&&cg(a),s&512&&ha(a,a.return);break;case 3:if(br(t,a),s&64&&(t=a.updateQueue,t!==null)){if(n=null,a.child!==null)switch(a.child.tag){case 27:case 5:n=a.child.stateNode;break;case 1:n=a.child.stateNode}try{em(t,n)}catch(k){et(a,a.return,k)}}break;case 27:n===null&&s&4&&pg(a);case 26:case 5:br(t,a),n===null&&s&4&&dg(a),s&512&&ha(a,a.return);break;case 12:br(t,a);break;case 31:br(t,a),s&4&&xg(t,a);break;case 13:br(t,a),s&4&&vg(t,a),s&64&&(t=a.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(a=Kw.bind(null,a),gS(t,a))));break;case 22:if(s=a.memoizedState!==null||mr,!s){n=n!==null&&n.memoizedState!==null||Nt,d=mr;var m=Nt;mr=s,(Nt=n)&&!m?yr(t,a,(a.subtreeFlags&8772)!==0):br(t,a),mr=d,Nt=m}break;case 30:break;default:br(t,a)}}function bg(t){var n=t.alternate;n!==null&&(t.alternate=null,bg(n)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(n=t.stateNode,n!==null&&Hl(n)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var ht=null,en=!1;function gr(t,n,a){for(a=a.child;a!==null;)yg(t,n,a),a=a.sibling}function yg(t,n,a){if(gt&&typeof gt.onCommitFiberUnmount=="function")try{gt.onCommitFiberUnmount(Ot,a)}catch{}switch(a.tag){case 26:Nt||Zn(a,n),gr(t,n,a),a.memoizedState?a.memoizedState.count--:a.stateNode&&(a=a.stateNode,a.parentNode.removeChild(a));break;case 27:Nt||Zn(a,n);var s=ht,d=en;Zr(a.type)&&(ht=a.stateNode,en=!1),gr(t,n,a),Sa(a.stateNode),ht=s,en=d;break;case 5:Nt||Zn(a,n);case 6:if(s=ht,d=en,ht=null,gr(t,n,a),ht=s,en=d,ht!==null)if(en)try{(ht.nodeType===9?ht.body:ht.nodeName==="HTML"?ht.ownerDocument.body:ht).removeChild(a.stateNode)}catch(m){et(a,n,m)}else try{ht.removeChild(a.stateNode)}catch(m){et(a,n,m)}break;case 18:ht!==null&&(en?(t=ht,cb(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,a.stateNode),vl(t)):cb(ht,a.stateNode));break;case 4:s=ht,d=en,ht=a.stateNode.containerInfo,en=!0,gr(t,n,a),ht=s,en=d;break;case 0:case 11:case 14:case 15:qr(2,a,n),Nt||qr(4,a,n),gr(t,n,a);break;case 1:Nt||(Zn(a,n),s=a.stateNode,typeof s.componentWillUnmount=="function"&&fg(a,n,s)),gr(t,n,a);break;case 21:gr(t,n,a);break;case 22:Nt=(s=Nt)||a.memoizedState!==null,gr(t,n,a),Nt=s;break;default:gr(t,n,a)}}function xg(t,n){if(n.memoizedState===null&&(t=n.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{vl(t)}catch(a){et(n,n.return,a)}}}function vg(t,n){if(n.memoizedState===null&&(t=n.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{vl(t)}catch(a){et(n,n.return,a)}}function qw(t){switch(t.tag){case 31:case 13:case 19:var n=t.stateNode;return n===null&&(n=t.stateNode=new mg),n;case 22:return t=t.stateNode,n=t._retryCache,n===null&&(n=t._retryCache=new mg),n;default:throw Error(l(435,t.tag))}}function Xo(t,n){var a=qw(t);n.forEach(function(s){if(!a.has(s)){a.add(s);var d=Qw.bind(null,t,s);s.then(d,d)}})}function tn(t,n){var a=n.deletions;if(a!==null)for(var s=0;s<a.length;s++){var d=a[s],m=t,k=n,_=k;e:for(;_!==null;){switch(_.tag){case 27:if(Zr(_.type)){ht=_.stateNode,en=!1;break e}break;case 5:ht=_.stateNode,en=!1;break e;case 3:case 4:ht=_.stateNode.containerInfo,en=!0;break e}_=_.return}if(ht===null)throw Error(l(160));yg(m,k,d),ht=null,en=!1,m=d.alternate,m!==null&&(m.return=null),d.return=null}if(n.subtreeFlags&13886)for(n=n.child;n!==null;)wg(n,t),n=n.sibling}var Un=null;function wg(t,n){var a=t.alternate,s=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:tn(n,t),nn(t),s&4&&(qr(3,t,t.return),da(3,t),qr(5,t,t.return));break;case 1:tn(n,t),nn(t),s&512&&(Nt||a===null||Zn(a,a.return)),s&64&&mr&&(t=t.updateQueue,t!==null&&(s=t.callbacks,s!==null&&(a=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=a===null?s:a.concat(s))));break;case 26:var d=Un;if(tn(n,t),nn(t),s&512&&(Nt||a===null||Zn(a,a.return)),s&4){var m=a!==null?a.memoizedState:null;if(s=t.memoizedState,a===null)if(s===null)if(t.stateNode===null){e:{s=t.type,a=t.memoizedProps,d=d.ownerDocument||d;t:switch(s){case"title":m=d.getElementsByTagName("title")[0],(!m||m[hi]||m[Tt]||m.namespaceURI==="http://www.w3.org/2000/svg"||m.hasAttribute("itemprop"))&&(m=d.createElement(s),d.head.insertBefore(m,d.querySelector("head > title"))),Bt(m,s,a),m[Tt]=t,Se(m),s=m;break e;case"link":var k=wb("link","href",d).get(s+(a.href||""));if(k){for(var _=0;_<k.length;_++)if(m=k[_],m.getAttribute("href")===(a.href==null||a.href===""?null:a.href)&&m.getAttribute("rel")===(a.rel==null?null:a.rel)&&m.getAttribute("title")===(a.title==null?null:a.title)&&m.getAttribute("crossorigin")===(a.crossOrigin==null?null:a.crossOrigin)){k.splice(_,1);break t}}m=d.createElement(s),Bt(m,s,a),d.head.appendChild(m);break;case"meta":if(k=wb("meta","content",d).get(s+(a.content||""))){for(_=0;_<k.length;_++)if(m=k[_],m.getAttribute("content")===(a.content==null?null:""+a.content)&&m.getAttribute("name")===(a.name==null?null:a.name)&&m.getAttribute("property")===(a.property==null?null:a.property)&&m.getAttribute("http-equiv")===(a.httpEquiv==null?null:a.httpEquiv)&&m.getAttribute("charset")===(a.charSet==null?null:a.charSet)){k.splice(_,1);break t}}m=d.createElement(s),Bt(m,s,a),d.head.appendChild(m);break;default:throw Error(l(468,s))}m[Tt]=t,Se(m),s=m}t.stateNode=s}else Sb(d,t.type,t.stateNode);else t.stateNode=vb(d,s,t.memoizedProps);else m!==s?(m===null?a.stateNode!==null&&(a=a.stateNode,a.parentNode.removeChild(a)):m.count--,s===null?Sb(d,t.type,t.stateNode):vb(d,s,t.memoizedProps)):s===null&&t.stateNode!==null&&Gc(t,t.memoizedProps,a.memoizedProps)}break;case 27:tn(n,t),nn(t),s&512&&(Nt||a===null||Zn(a,a.return)),a!==null&&s&4&&Gc(t,t.memoizedProps,a.memoizedProps);break;case 5:if(tn(n,t),nn(t),s&512&&(Nt||a===null||Zn(a,a.return)),t.flags&32){d=t.stateNode;try{$i(d,"")}catch(ke){et(t,t.return,ke)}}s&4&&t.stateNode!=null&&(d=t.memoizedProps,Gc(t,d,a!==null?a.memoizedProps:d)),s&1024&&(Zc=!0);break;case 6:if(tn(n,t),nn(t),s&4){if(t.stateNode===null)throw Error(l(162));s=t.memoizedProps,a=t.stateNode;try{a.nodeValue=s}catch(ke){et(t,t.return,ke)}}break;case 3:if(cs=null,d=Un,Un=ss(n.containerInfo),tn(n,t),Un=d,nn(t),s&4&&a!==null&&a.memoizedState.isDehydrated)try{vl(n.containerInfo)}catch(ke){et(t,t.return,ke)}Zc&&(Zc=!1,Sg(t));break;case 4:s=Un,Un=ss(t.stateNode.containerInfo),tn(n,t),nn(t),Un=s;break;case 12:tn(n,t),nn(t);break;case 31:tn(n,t),nn(t),s&4&&(s=t.updateQueue,s!==null&&(t.updateQueue=null,Xo(t,s)));break;case 13:tn(n,t),nn(t),t.child.flags&8192&&t.memoizedState!==null!=(a!==null&&a.memoizedState!==null)&&(Ko=at()),s&4&&(s=t.updateQueue,s!==null&&(t.updateQueue=null,Xo(t,s)));break;case 22:d=t.memoizedState!==null;var P=a!==null&&a.memoizedState!==null,ee=mr,oe=Nt;if(mr=ee||d,Nt=oe||P,tn(n,t),Nt=oe,mr=ee,nn(t),s&8192)e:for(n=t.stateNode,n._visibility=d?n._visibility&-2:n._visibility|1,d&&(a===null||P||mr||Nt||Ti(t)),a=null,n=t;;){if(n.tag===5||n.tag===26){if(a===null){P=a=n;try{if(m=P.stateNode,d)k=m.style,typeof k.setProperty=="function"?k.setProperty("display","none","important"):k.display="none";else{_=P.stateNode;var ce=P.memoizedProps.style,ne=ce!=null&&ce.hasOwnProperty("display")?ce.display:null;_.style.display=ne==null||typeof ne=="boolean"?"":(""+ne).trim()}}catch(ke){et(P,P.return,ke)}}}else if(n.tag===6){if(a===null){P=n;try{P.stateNode.nodeValue=d?"":P.memoizedProps}catch(ke){et(P,P.return,ke)}}}else if(n.tag===18){if(a===null){P=n;try{var le=P.stateNode;d?fb(le,!0):fb(P.stateNode,!1)}catch(ke){et(P,P.return,ke)}}}else if((n.tag!==22&&n.tag!==23||n.memoizedState===null||n===t)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break e;for(;n.sibling===null;){if(n.return===null||n.return===t)break e;a===n&&(a=null),n=n.return}a===n&&(a=null),n.sibling.return=n.return,n=n.sibling}s&4&&(s=t.updateQueue,s!==null&&(a=s.retryQueue,a!==null&&(s.retryQueue=null,Xo(t,a))));break;case 19:tn(n,t),nn(t),s&4&&(s=t.updateQueue,s!==null&&(t.updateQueue=null,Xo(t,s)));break;case 30:break;case 21:break;default:tn(n,t),nn(t)}}function nn(t){var n=t.flags;if(n&2){try{for(var a,s=t.return;s!==null;){if(hg(s)){a=s;break}s=s.return}if(a==null)throw Error(l(160));switch(a.tag){case 27:var d=a.stateNode,m=Yc(t);Yo(t,m,d);break;case 5:var k=a.stateNode;a.flags&32&&($i(k,""),a.flags&=-33);var _=Yc(t);Yo(t,_,k);break;case 3:case 4:var P=a.stateNode.containerInfo,ee=Yc(t);Xc(t,ee,P);break;default:throw Error(l(161))}}catch(oe){et(t,t.return,oe)}t.flags&=-3}n&4096&&(t.flags&=-4097)}function Sg(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var n=t;Sg(n),n.tag===5&&n.flags&1024&&n.stateNode.reset(),t=t.sibling}}function br(t,n){if(n.subtreeFlags&8772)for(n=n.child;n!==null;)gg(t,n.alternate,n),n=n.sibling}function Ti(t){for(t=t.child;t!==null;){var n=t;switch(n.tag){case 0:case 11:case 14:case 15:qr(4,n,n.return),Ti(n);break;case 1:Zn(n,n.return);var a=n.stateNode;typeof a.componentWillUnmount=="function"&&fg(n,n.return,a),Ti(n);break;case 27:Sa(n.stateNode);case 26:case 5:Zn(n,n.return),Ti(n);break;case 22:n.memoizedState===null&&Ti(n);break;case 30:Ti(n);break;default:Ti(n)}t=t.sibling}}function yr(t,n,a){for(a=a&&(n.subtreeFlags&8772)!==0,n=n.child;n!==null;){var s=n.alternate,d=t,m=n,k=m.flags;switch(m.tag){case 0:case 11:case 15:yr(d,m,a),da(4,m);break;case 1:if(yr(d,m,a),s=m,d=s.stateNode,typeof d.componentDidMount=="function")try{d.componentDidMount()}catch(ee){et(s,s.return,ee)}if(s=m,d=s.updateQueue,d!==null){var _=s.stateNode;try{var P=d.shared.hiddenCallbacks;if(P!==null)for(d.shared.hiddenCallbacks=null,d=0;d<P.length;d++)Wp(P[d],_)}catch(ee){et(s,s.return,ee)}}a&&k&64&&cg(m),ha(m,m.return);break;case 27:pg(m);case 26:case 5:yr(d,m,a),a&&s===null&&k&4&&dg(m),ha(m,m.return);break;case 12:yr(d,m,a);break;case 31:yr(d,m,a),a&&k&4&&xg(d,m);break;case 13:yr(d,m,a),a&&k&4&&vg(d,m);break;case 22:m.memoizedState===null&&yr(d,m,a),ha(m,m.return);break;case 30:break;default:yr(d,m,a)}n=n.sibling}}function Kc(t,n){var a=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(a=t.memoizedState.cachePool.pool),t=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(t=n.memoizedState.cachePool.pool),t!==a&&(t!=null&&t.refCount++,a!=null&&Wl(a))}function Qc(t,n){t=null,n.alternate!==null&&(t=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==t&&(n.refCount++,t!=null&&Wl(t))}function Hn(t,n,a,s){if(n.subtreeFlags&10256)for(n=n.child;n!==null;)kg(t,n,a,s),n=n.sibling}function kg(t,n,a,s){var d=n.flags;switch(n.tag){case 0:case 11:case 15:Hn(t,n,a,s),d&2048&&da(9,n);break;case 1:Hn(t,n,a,s);break;case 3:Hn(t,n,a,s),d&2048&&(t=null,n.alternate!==null&&(t=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==t&&(n.refCount++,t!=null&&Wl(t)));break;case 12:if(d&2048){Hn(t,n,a,s),t=n.stateNode;try{var m=n.memoizedProps,k=m.id,_=m.onPostCommit;typeof _=="function"&&_(k,n.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(P){et(n,n.return,P)}}else Hn(t,n,a,s);break;case 31:Hn(t,n,a,s);break;case 13:Hn(t,n,a,s);break;case 23:break;case 22:m=n.stateNode,k=n.alternate,n.memoizedState!==null?m._visibility&2?Hn(t,n,a,s):pa(t,n):m._visibility&2?Hn(t,n,a,s):(m._visibility|=2,ul(t,n,a,s,(n.subtreeFlags&10256)!==0||!1)),d&2048&&Kc(k,n);break;case 24:Hn(t,n,a,s),d&2048&&Qc(n.alternate,n);break;default:Hn(t,n,a,s)}}function ul(t,n,a,s,d){for(d=d&&((n.subtreeFlags&10256)!==0||!1),n=n.child;n!==null;){var m=t,k=n,_=a,P=s,ee=k.flags;switch(k.tag){case 0:case 11:case 15:ul(m,k,_,P,d),da(8,k);break;case 23:break;case 22:var oe=k.stateNode;k.memoizedState!==null?oe._visibility&2?ul(m,k,_,P,d):pa(m,k):(oe._visibility|=2,ul(m,k,_,P,d)),d&&ee&2048&&Kc(k.alternate,k);break;case 24:ul(m,k,_,P,d),d&&ee&2048&&Qc(k.alternate,k);break;default:ul(m,k,_,P,d)}n=n.sibling}}function pa(t,n){if(n.subtreeFlags&10256)for(n=n.child;n!==null;){var a=t,s=n,d=s.flags;switch(s.tag){case 22:pa(a,s),d&2048&&Kc(s.alternate,s);break;case 24:pa(a,s),d&2048&&Qc(s.alternate,s);break;default:pa(a,s)}n=n.sibling}}var ma=8192;function cl(t,n,a){if(t.subtreeFlags&ma)for(t=t.child;t!==null;)Eg(t,n,a),t=t.sibling}function Eg(t,n,a){switch(t.tag){case 26:cl(t,n,a),t.flags&ma&&t.memoizedState!==null&&TS(a,Un,t.memoizedState,t.memoizedProps);break;case 5:cl(t,n,a);break;case 3:case 4:var s=Un;Un=ss(t.stateNode.containerInfo),cl(t,n,a),Un=s;break;case 22:t.memoizedState===null&&(s=t.alternate,s!==null&&s.memoizedState!==null?(s=ma,ma=16777216,cl(t,n,a),ma=s):cl(t,n,a));break;default:cl(t,n,a)}}function Cg(t){var n=t.alternate;if(n!==null&&(t=n.child,t!==null)){n.child=null;do n=t.sibling,t.sibling=null,t=n;while(t!==null)}}function ga(t){var n=t.deletions;if((t.flags&16)!==0){if(n!==null)for(var a=0;a<n.length;a++){var s=n[a];_t=s,Ag(s,t)}Cg(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Ng(t),t=t.sibling}function Ng(t){switch(t.tag){case 0:case 11:case 15:ga(t),t.flags&2048&&qr(9,t,t.return);break;case 3:ga(t);break;case 12:ga(t);break;case 22:var n=t.stateNode;t.memoizedState!==null&&n._visibility&2&&(t.return===null||t.return.tag!==13)?(n._visibility&=-3,Zo(t)):ga(t);break;default:ga(t)}}function Zo(t){var n=t.deletions;if((t.flags&16)!==0){if(n!==null)for(var a=0;a<n.length;a++){var s=n[a];_t=s,Ag(s,t)}Cg(t)}for(t=t.child;t!==null;){switch(n=t,n.tag){case 0:case 11:case 15:qr(8,n,n.return),Zo(n);break;case 22:a=n.stateNode,a._visibility&2&&(a._visibility&=-3,Zo(n));break;default:Zo(n)}t=t.sibling}}function Ag(t,n){for(;_t!==null;){var a=_t;switch(a.tag){case 0:case 11:case 15:qr(8,a,n);break;case 23:case 22:if(a.memoizedState!==null&&a.memoizedState.cachePool!==null){var s=a.memoizedState.cachePool.pool;s!=null&&s.refCount++}break;case 24:Wl(a.memoizedState.cache)}if(s=a.child,s!==null)s.return=a,_t=s;else e:for(a=t;_t!==null;){s=_t;var d=s.sibling,m=s.return;if(bg(s),s===a){_t=null;break e}if(d!==null){d.return=m,_t=d;break e}_t=m}}}var $w={getCacheForType:function(t){var n=zt(kt),a=n.data.get(t);return a===void 0&&(a=t(),n.data.set(t,a)),a},cacheSignal:function(){return zt(kt).controller.signal}},Pw=typeof WeakMap=="function"?WeakMap:Map,Ze=0,ot=null,ze=null,Ue=0,We=0,gn=null,$r=!1,fl=!1,Jc=!1,xr=0,yt=0,Pr=0,ji=0,Wc=0,bn=0,dl=0,ba=null,rn=null,ef=!1,Ko=0,Tg=0,Qo=1/0,Jo=null,Vr=null,jt=0,Gr=null,hl=null,vr=0,tf=0,nf=null,jg=null,ya=0,rf=null;function yn(){return(Ze&2)!==0&&Ue!==0?Ue&-Ue:B.T!==null?cf():lo()}function Rg(){if(bn===0)if((Ue&536870912)===0||qe){var t=Ii;Ii<<=1,(Ii&3932160)===0&&(Ii=262144),bn=t}else bn=536870912;return t=pn.current,t!==null&&(t.flags|=32),bn}function ln(t,n,a){(t===ot&&(We===2||We===9)||t.cancelPendingCommit!==null)&&(pl(t,0),Yr(t,Ue,bn,!1)),di(t,a),((Ze&2)===0||t!==ot)&&(t===ot&&((Ze&2)===0&&(ji|=a),yt===4&&Yr(t,Ue,bn,!1)),Kn(t))}function _g(t,n,a){if((Ze&6)!==0)throw Error(l(327));var s=!a&&(n&127)===0&&(n&t.expiredLanes)===0||Pn(t,n),d=s?Yw(t,n):af(t,n,!0),m=s;do{if(d===0){fl&&!s&&Yr(t,n,0,!1);break}else{if(a=t.current.alternate,m&&!Vw(a)){d=af(t,n,!1),m=!1;continue}if(d===2){if(m=n,t.errorRecoveryDisabledLanes&m)var k=0;else k=t.pendingLanes&-536870913,k=k!==0?k:k&536870912?536870912:0;if(k!==0){n=k;e:{var _=t;d=ba;var P=_.current.memoizedState.isDehydrated;if(P&&(pl(_,k).flags|=256),k=af(_,k,!1),k!==2){if(Jc&&!P){_.errorRecoveryDisabledLanes|=m,ji|=m,d=4;break e}m=rn,rn=d,m!==null&&(rn===null?rn=m:rn.push.apply(rn,m))}d=k}if(m=!1,d!==2)continue}}if(d===1){pl(t,0),Yr(t,n,0,!0);break}e:{switch(s=t,m=d,m){case 0:case 1:throw Error(l(345));case 4:if((n&4194048)!==n)break;case 6:Yr(s,n,bn,!$r);break e;case 2:rn=null;break;case 3:case 5:break;default:throw Error(l(329))}if((n&62914560)===n&&(d=Ko+300-at(),10<d)){if(Yr(s,n,bn,!$r),jr(s,0,!0)!==0)break e;vr=n,s.timeoutHandle=sb(Lg.bind(null,s,a,rn,Jo,ef,n,bn,ji,dl,$r,m,"Throttled",-0,0),d);break e}Lg(s,a,rn,Jo,ef,n,bn,ji,dl,$r,m,null,-0,0)}}break}while(!0);Kn(t)}function Lg(t,n,a,s,d,m,k,_,P,ee,oe,ce,ne,le){if(t.timeoutHandle=-1,ce=n.subtreeFlags,ce&8192||(ce&16785408)===16785408){ce={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:lr},Eg(n,m,ce);var ke=(m&62914560)===m?Ko-at():(m&4194048)===m?Tg-at():0;if(ke=jS(ce,ke),ke!==null){vr=m,t.cancelPendingCommit=ke(Ug.bind(null,t,n,m,a,s,d,k,_,P,oe,ce,null,ne,le)),Yr(t,m,k,!ee);return}}Ug(t,n,m,a,s,d,k,_,P)}function Vw(t){for(var n=t;;){var a=n.tag;if((a===0||a===11||a===15)&&n.flags&16384&&(a=n.updateQueue,a!==null&&(a=a.stores,a!==null)))for(var s=0;s<a.length;s++){var d=a[s],m=d.getSnapshot;d=d.value;try{if(!dn(m(),d))return!1}catch{return!1}}if(a=n.child,n.subtreeFlags&16384&&a!==null)a.return=n,n=a;else{if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return!0;n=n.return}n.sibling.return=n.return,n=n.sibling}}return!0}function Yr(t,n,a,s){n&=~Wc,n&=~ji,t.suspendedLanes|=n,t.pingedLanes&=~n,s&&(t.warmLanes|=n),s=t.expirationTimes;for(var d=n;0<d;){var m=31-Je(d),k=1<<m;s[m]=-1,d&=~k}a!==0&&Il(t,a,n)}function Wo(){return(Ze&6)===0?(xa(0),!1):!0}function lf(){if(ze!==null){if(We===0)var t=ze.return;else t=ze,ur=vi=null,vc(t),il=null,ta=0,t=ze;for(;t!==null;)ug(t.alternate,t),t=t.return;ze=null}}function pl(t,n){var a=t.timeoutHandle;a!==-1&&(t.timeoutHandle=-1,fS(a)),a=t.cancelPendingCommit,a!==null&&(t.cancelPendingCommit=null,a()),vr=0,lf(),ot=t,ze=a=or(t.current,null),Ue=n,We=0,gn=null,$r=!1,fl=Pn(t,n),Jc=!1,dl=bn=Wc=ji=Pr=yt=0,rn=ba=null,ef=!1,(n&8)!==0&&(n|=n&32);var s=t.entangledLanes;if(s!==0)for(t=t.entanglements,s&=n;0<s;){var d=31-Je(s),m=1<<d;n|=t[d],s&=~m}return xr=n,vo(),a}function Dg(t,n){_e=null,B.H=ua,n===rl||n===To?(n=Zp(),We=3):n===sc?(n=Zp(),We=4):We=n===zc?8:n!==null&&typeof n=="object"&&typeof n.then=="function"?6:1,gn=n,ze===null&&(yt=1,qo(t,An(n,t.current)))}function Og(){var t=pn.current;return t===null?!0:(Ue&4194048)===Ue?_n===null:(Ue&62914560)===Ue||(Ue&536870912)!==0?t===_n:!1}function Mg(){var t=B.H;return B.H=ua,t===null?ua:t}function zg(){var t=B.A;return B.A=$w,t}function es(){yt=4,$r||(Ue&4194048)!==Ue&&pn.current!==null||(fl=!0),(Pr&134217727)===0&&(ji&134217727)===0||ot===null||Yr(ot,Ue,bn,!1)}function af(t,n,a){var s=Ze;Ze|=2;var d=Mg(),m=zg();(ot!==t||Ue!==n)&&(Jo=null,pl(t,n)),n=!1;var k=yt;e:do try{if(We!==0&&ze!==null){var _=ze,P=gn;switch(We){case 8:lf(),k=6;break e;case 3:case 2:case 9:case 6:pn.current===null&&(n=!0);var ee=We;if(We=0,gn=null,ml(t,_,P,ee),a&&fl){k=0;break e}break;default:ee=We,We=0,gn=null,ml(t,_,P,ee)}}Gw(),k=yt;break}catch(oe){Dg(t,oe)}while(!0);return n&&t.shellSuspendCounter++,ur=vi=null,Ze=s,B.H=d,B.A=m,ze===null&&(ot=null,Ue=0,vo()),k}function Gw(){for(;ze!==null;)Fg(ze)}function Yw(t,n){var a=Ze;Ze|=2;var s=Mg(),d=zg();ot!==t||Ue!==n?(Jo=null,Qo=at()+500,pl(t,n)):fl=Pn(t,n);e:do try{if(We!==0&&ze!==null){n=ze;var m=gn;t:switch(We){case 1:We=0,gn=null,ml(t,n,m,1);break;case 2:case 9:if(Yp(m)){We=0,gn=null,Bg(n);break}n=function(){We!==2&&We!==9||ot!==t||(We=7),Kn(t)},m.then(n,n);break e;case 3:We=7;break e;case 4:We=5;break e;case 7:Yp(m)?(We=0,gn=null,Bg(n)):(We=0,gn=null,ml(t,n,m,7));break;case 5:var k=null;switch(ze.tag){case 26:k=ze.memoizedState;case 5:case 27:var _=ze;if(k?kb(k):_.stateNode.complete){We=0,gn=null;var P=_.sibling;if(P!==null)ze=P;else{var ee=_.return;ee!==null?(ze=ee,ts(ee)):ze=null}break t}}We=0,gn=null,ml(t,n,m,5);break;case 6:We=0,gn=null,ml(t,n,m,6);break;case 8:lf(),yt=6;break e;default:throw Error(l(462))}}Xw();break}catch(oe){Dg(t,oe)}while(!0);return ur=vi=null,B.H=s,B.A=d,Ze=a,ze!==null?0:(ot=null,Ue=0,vo(),yt)}function Xw(){for(;ze!==null&&!Yt();)Fg(ze)}function Fg(t){var n=og(t.alternate,t,xr);t.memoizedProps=t.pendingProps,n===null?ts(t):ze=n}function Bg(t){var n=t,a=n.alternate;switch(n.tag){case 15:case 0:n=tg(a,n,n.pendingProps,n.type,void 0,Ue);break;case 11:n=tg(a,n,n.pendingProps,n.type.render,n.ref,Ue);break;case 5:vc(n);default:ug(a,n),n=ze=zp(n,xr),n=og(a,n,xr)}t.memoizedProps=t.pendingProps,n===null?ts(t):ze=n}function ml(t,n,a,s){ur=vi=null,vc(n),il=null,ta=0;var d=n.return;try{if(zw(t,d,n,a,Ue)){yt=1,qo(t,An(a,t.current)),ze=null;return}}catch(m){if(d!==null)throw ze=d,m;yt=1,qo(t,An(a,t.current)),ze=null;return}n.flags&32768?(qe||s===1?t=!0:fl||(Ue&536870912)!==0?t=!1:($r=t=!0,(s===2||s===9||s===3||s===6)&&(s=pn.current,s!==null&&s.tag===13&&(s.flags|=16384))),Ig(n,t)):ts(n)}function ts(t){var n=t;do{if((n.flags&32768)!==0){Ig(n,$r);return}t=n.return;var a=Iw(n.alternate,n,xr);if(a!==null){ze=a;return}if(n=n.sibling,n!==null){ze=n;return}ze=n=t}while(n!==null);yt===0&&(yt=5)}function Ig(t,n){do{var a=Uw(t.alternate,t);if(a!==null){a.flags&=32767,ze=a;return}if(a=t.return,a!==null&&(a.flags|=32768,a.subtreeFlags=0,a.deletions=null),!n&&(t=t.sibling,t!==null)){ze=t;return}ze=t=a}while(t!==null);yt=6,ze=null}function Ug(t,n,a,s,d,m,k,_,P){t.cancelPendingCommit=null;do ns();while(jt!==0);if((Ze&6)!==0)throw Error(l(327));if(n!==null){if(n===t.current)throw Error(l(177));if(m=n.lanes|n.childLanes,m|=Yu,ro(t,a,m,k,_,P),t===ot&&(ze=ot=null,Ue=0),hl=n,Gr=t,vr=a,tf=m,nf=d,jg=s,(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,Jw(Te,function(){return Vg(),null})):(t.callbackNode=null,t.callbackPriority=0),s=(n.flags&13878)!==0,(n.subtreeFlags&13878)!==0||s){s=B.T,B.T=null,d=X.p,X.p=2,k=Ze,Ze|=4;try{Hw(t,n,a)}finally{Ze=k,X.p=d,B.T=s}}jt=1,Hg(),qg(),$g()}}function Hg(){if(jt===1){jt=0;var t=Gr,n=hl,a=(n.flags&13878)!==0;if((n.subtreeFlags&13878)!==0||a){a=B.T,B.T=null;var s=X.p;X.p=2;var d=Ze;Ze|=4;try{wg(n,t);var m=yf,k=Ap(t.containerInfo),_=m.focusedElem,P=m.selectionRange;if(k!==_&&_&&_.ownerDocument&&Np(_.ownerDocument.documentElement,_)){if(P!==null&&qu(_)){var ee=P.start,oe=P.end;if(oe===void 0&&(oe=ee),"selectionStart"in _)_.selectionStart=ee,_.selectionEnd=Math.min(oe,_.value.length);else{var ce=_.ownerDocument||document,ne=ce&&ce.defaultView||window;if(ne.getSelection){var le=ne.getSelection(),ke=_.textContent.length,je=Math.min(P.start,ke),it=P.end===void 0?je:Math.min(P.end,ke);!le.extend&&je>it&&(k=it,it=je,je=k);var J=Cp(_,je),K=Cp(_,it);if(J&&K&&(le.rangeCount!==1||le.anchorNode!==J.node||le.anchorOffset!==J.offset||le.focusNode!==K.node||le.focusOffset!==K.offset)){var W=ce.createRange();W.setStart(J.node,J.offset),le.removeAllRanges(),je>it?(le.addRange(W),le.extend(K.node,K.offset)):(W.setEnd(K.node,K.offset),le.addRange(W))}}}}for(ce=[],le=_;le=le.parentNode;)le.nodeType===1&&ce.push({element:le,left:le.scrollLeft,top:le.scrollTop});for(typeof _.focus=="function"&&_.focus(),_=0;_<ce.length;_++){var se=ce[_];se.element.scrollLeft=se.left,se.element.scrollTop=se.top}}ps=!!bf,yf=bf=null}finally{Ze=d,X.p=s,B.T=a}}t.current=n,jt=2}}function qg(){if(jt===2){jt=0;var t=Gr,n=hl,a=(n.flags&8772)!==0;if((n.subtreeFlags&8772)!==0||a){a=B.T,B.T=null;var s=X.p;X.p=2;var d=Ze;Ze|=4;try{gg(t,n.alternate,n)}finally{Ze=d,X.p=s,B.T=a}}jt=3}}function $g(){if(jt===4||jt===3){jt=0,tt();var t=Gr,n=hl,a=vr,s=jg;(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?jt=5:(jt=0,hl=Gr=null,Pg(t,t.pendingLanes));var d=t.pendingLanes;if(d===0&&(Vr=null),Vn(a),n=n.stateNode,gt&&typeof gt.onCommitFiberRoot=="function")try{gt.onCommitFiberRoot(Ot,n,void 0,(n.current.flags&128)===128)}catch{}if(s!==null){n=B.T,d=X.p,X.p=2,B.T=null;try{for(var m=t.onRecoverableError,k=0;k<s.length;k++){var _=s[k];m(_.value,{componentStack:_.stack})}}finally{B.T=n,X.p=d}}(vr&3)!==0&&ns(),Kn(t),d=t.pendingLanes,(a&261930)!==0&&(d&42)!==0?t===rf?ya++:(ya=0,rf=t):ya=0,xa(0)}}function Pg(t,n){(t.pooledCacheLanes&=n)===0&&(n=t.pooledCache,n!=null&&(t.pooledCache=null,Wl(n)))}function ns(){return Hg(),qg(),$g(),Vg()}function Vg(){if(jt!==5)return!1;var t=Gr,n=tf;tf=0;var a=Vn(vr),s=B.T,d=X.p;try{X.p=32>a?32:a,B.T=null,a=nf,nf=null;var m=Gr,k=vr;if(jt=0,hl=Gr=null,vr=0,(Ze&6)!==0)throw Error(l(331));var _=Ze;if(Ze|=4,Ng(m.current),kg(m,m.current,k,a),Ze=_,xa(0,!1),gt&&typeof gt.onPostCommitFiberRoot=="function")try{gt.onPostCommitFiberRoot(Ot,m)}catch{}return!0}finally{X.p=d,B.T=s,Pg(t,n)}}function Gg(t,n,a){n=An(a,n),n=Mc(t.stateNode,n,2),t=Ir(t,n,2),t!==null&&(di(t,2),Kn(t))}function et(t,n,a){if(t.tag===3)Gg(t,t,a);else for(;n!==null;){if(n.tag===3){Gg(n,t,a);break}else if(n.tag===1){var s=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof s.componentDidCatch=="function"&&(Vr===null||!Vr.has(s))){t=An(a,t),a=Ym(2),s=Ir(n,a,2),s!==null&&(Xm(a,s,n,t),di(s,2),Kn(s));break}}n=n.return}}function of(t,n,a){var s=t.pingCache;if(s===null){s=t.pingCache=new Pw;var d=new Set;s.set(n,d)}else d=s.get(n),d===void 0&&(d=new Set,s.set(n,d));d.has(a)||(Jc=!0,d.add(a),t=Zw.bind(null,t,n,a),n.then(t,t))}function Zw(t,n,a){var s=t.pingCache;s!==null&&s.delete(n),t.pingedLanes|=t.suspendedLanes&a,t.warmLanes&=~a,ot===t&&(Ue&a)===a&&(yt===4||yt===3&&(Ue&62914560)===Ue&&300>at()-Ko?(Ze&2)===0&&pl(t,0):Wc|=a,dl===Ue&&(dl=0)),Kn(t)}function Yg(t,n){n===0&&(n=Bl()),t=bi(t,n),t!==null&&(di(t,n),Kn(t))}function Kw(t){var n=t.memoizedState,a=0;n!==null&&(a=n.retryLane),Yg(t,a)}function Qw(t,n){var a=0;switch(t.tag){case 31:case 13:var s=t.stateNode,d=t.memoizedState;d!==null&&(a=d.retryLane);break;case 19:s=t.stateNode;break;case 22:s=t.stateNode._retryCache;break;default:throw Error(l(314))}s!==null&&s.delete(n),Yg(t,a)}function Jw(t,n){return mt(t,n)}var rs=null,gl=null,sf=!1,is=!1,uf=!1,Xr=0;function Kn(t){t!==gl&&t.next===null&&(gl===null?rs=gl=t:gl=gl.next=t),is=!0,sf||(sf=!0,eS())}function xa(t,n){if(!uf&&is){uf=!0;do for(var a=!1,s=rs;s!==null;){if(t!==0){var d=s.pendingLanes;if(d===0)var m=0;else{var k=s.suspendedLanes,_=s.pingedLanes;m=(1<<31-Je(42|t)+1)-1,m&=d&~(k&~_),m=m&201326741?m&201326741|1:m?m|2:0}m!==0&&(a=!0,Qg(s,m))}else m=Ue,m=jr(s,s===ot?m:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),(m&3)===0||Pn(s,m)||(a=!0,Qg(s,m));s=s.next}while(a);uf=!1}}function Ww(){Xg()}function Xg(){is=sf=!1;var t=0;Xr!==0&&cS()&&(t=Xr);for(var n=at(),a=null,s=rs;s!==null;){var d=s.next,m=Zg(s,n);m===0?(s.next=null,a===null?rs=d:a.next=d,d===null&&(gl=a)):(a=s,(t!==0||(m&3)!==0)&&(is=!0)),s=d}jt!==0&&jt!==5||xa(t),Xr!==0&&(Xr=0)}function Zg(t,n){for(var a=t.suspendedLanes,s=t.pingedLanes,d=t.expirationTimes,m=t.pendingLanes&-62914561;0<m;){var k=31-Je(m),_=1<<k,P=d[k];P===-1?((_&a)===0||(_&s)!==0)&&(d[k]=Eu(_,n)):P<=n&&(t.expiredLanes|=_),m&=~_}if(n=ot,a=Ue,a=jr(t,t===n?a:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),s=t.callbackNode,a===0||t===n&&(We===2||We===9)||t.cancelPendingCommit!==null)return s!==null&&s!==null&&Gt(s),t.callbackNode=null,t.callbackPriority=0;if((a&3)===0||Pn(t,a)){if(n=a&-a,n===t.callbackPriority)return n;switch(s!==null&&Gt(s),Vn(a)){case 2:case 8:a=be;break;case 32:a=Te;break;case 268435456:a=Ve;break;default:a=Te}return s=Kg.bind(null,t),a=mt(a,s),t.callbackPriority=n,t.callbackNode=a,n}return s!==null&&s!==null&&Gt(s),t.callbackPriority=2,t.callbackNode=null,2}function Kg(t,n){if(jt!==0&&jt!==5)return t.callbackNode=null,t.callbackPriority=0,null;var a=t.callbackNode;if(ns()&&t.callbackNode!==a)return null;var s=Ue;return s=jr(t,t===ot?s:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),s===0?null:(_g(t,s,n),Zg(t,at()),t.callbackNode!=null&&t.callbackNode===a?Kg.bind(null,t):null)}function Qg(t,n){if(ns())return null;_g(t,n,!0)}function eS(){dS(function(){(Ze&6)!==0?mt(ae,Ww):Xg()})}function cf(){if(Xr===0){var t=tl;t===0&&(t=Ar,Ar<<=1,(Ar&261888)===0&&(Ar=256)),Xr=t}return Xr}function Jg(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:fo(""+t)}function Wg(t,n){var a=n.ownerDocument.createElement("input");return a.name=n.name,a.value=n.value,t.id&&a.setAttribute("form",t.id),n.parentNode.insertBefore(a,n),t=new FormData(t),a.parentNode.removeChild(a),t}function tS(t,n,a,s,d){if(n==="submit"&&a&&a.stateNode===d){var m=Jg((d[wt]||null).action),k=s.submitter;k&&(n=(n=k[wt]||null)?Jg(n.formAction):k.getAttribute("formAction"),n!==null&&(m=n,k=null));var _=new go("action","action",null,s,d);t.push({event:_,listeners:[{instance:null,listener:function(){if(s.defaultPrevented){if(Xr!==0){var P=k?Wg(d,k):new FormData(d);jc(a,{pending:!0,data:P,method:d.method,action:m},null,P)}}else typeof m=="function"&&(_.preventDefault(),P=k?Wg(d,k):new FormData(d),jc(a,{pending:!0,data:P,method:d.method,action:m},m,P))},currentTarget:d}]})}}for(var ff=0;ff<Gu.length;ff++){var df=Gu[ff],nS=df.toLowerCase(),rS=df[0].toUpperCase()+df.slice(1);In(nS,"on"+rS)}In(Rp,"onAnimationEnd"),In(_p,"onAnimationIteration"),In(Lp,"onAnimationStart"),In("dblclick","onDoubleClick"),In("focusin","onFocus"),In("focusout","onBlur"),In(xw,"onTransitionRun"),In(vw,"onTransitionStart"),In(ww,"onTransitionCancel"),In(Dp,"onTransitionEnd"),Bn("onMouseEnter",["mouseout","mouseover"]),Bn("onMouseLeave",["mouseout","mouseover"]),Bn("onPointerEnter",["pointerout","pointerover"]),Bn("onPointerLeave",["pointerout","pointerover"]),St("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),St("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),St("onBeforeInput",["compositionend","keypress","textInput","paste"]),St("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),St("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),St("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var va="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(" "),iS=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(va));function eb(t,n){n=(n&4)!==0;for(var a=0;a<t.length;a++){var s=t[a],d=s.event;s=s.listeners;e:{var m=void 0;if(n)for(var k=s.length-1;0<=k;k--){var _=s[k],P=_.instance,ee=_.currentTarget;if(_=_.listener,P!==m&&d.isPropagationStopped())break e;m=_,d.currentTarget=ee;try{m(d)}catch(oe){xo(oe)}d.currentTarget=null,m=P}else for(k=0;k<s.length;k++){if(_=s[k],P=_.instance,ee=_.currentTarget,_=_.listener,P!==m&&d.isPropagationStopped())break e;m=_,d.currentTarget=ee;try{m(d)}catch(oe){xo(oe)}d.currentTarget=null,m=P}}}}function Fe(t,n){var a=n[Hi];a===void 0&&(a=n[Hi]=new Set);var s=t+"__bubble";a.has(s)||(tb(n,t,2,!1),a.add(s))}function hf(t,n,a){var s=0;n&&(s|=4),tb(a,t,s,n)}var ls="_reactListening"+Math.random().toString(36).slice(2);function pf(t){if(!t[ls]){t[ls]=!0,Qe.forEach(function(a){a!=="selectionchange"&&(iS.has(a)||hf(a,!1,t),hf(a,!0,t))});var n=t.nodeType===9?t:t.ownerDocument;n===null||n[ls]||(n[ls]=!0,hf("selectionchange",!1,n))}}function tb(t,n,a,s){switch(Rb(n)){case 2:var d=LS;break;case 8:d=DS;break;default:d=jf}a=d.bind(null,n,a,t),d=void 0,!Du||n!=="touchstart"&&n!=="touchmove"&&n!=="wheel"||(d=!0),s?d!==void 0?t.addEventListener(n,a,{capture:!0,passive:d}):t.addEventListener(n,a,!0):d!==void 0?t.addEventListener(n,a,{passive:d}):t.addEventListener(n,a,!1)}function mf(t,n,a,s,d){var m=s;if((n&1)===0&&(n&2)===0&&s!==null)e:for(;;){if(s===null)return;var k=s.tag;if(k===3||k===4){var _=s.stateNode.containerInfo;if(_===d)break;if(k===4)for(k=s.return;k!==null;){var P=k.tag;if((P===3||P===4)&&k.stateNode.containerInfo===d)return;k=k.return}for(;_!==null;){if(k=Rr(_),k===null)return;if(P=k.tag,P===5||P===6||P===26||P===27){s=m=k;continue e}_=_.parentNode}}s=s.return}ap(function(){var ee=m,oe=_u(a),ce=[];e:{var ne=Op.get(t);if(ne!==void 0){var le=go,ke=t;switch(t){case"keypress":if(po(a)===0)break e;case"keydown":case"keyup":le=Qv;break;case"focusin":ke="focus",le=Fu;break;case"focusout":ke="blur",le=Fu;break;case"beforeblur":case"afterblur":le=Fu;break;case"click":if(a.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":le=up;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":le=Iv;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":le=ew;break;case Rp:case _p:case Lp:le=qv;break;case Dp:le=nw;break;case"scroll":case"scrollend":le=Fv;break;case"wheel":le=iw;break;case"copy":case"cut":case"paste":le=Pv;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":le=fp;break;case"toggle":case"beforetoggle":le=aw}var je=(n&4)!==0,it=!je&&(t==="scroll"||t==="scrollend"),J=je?ne!==null?ne+"Capture":null:ne;je=[];for(var K=ee,W;K!==null;){var se=K;if(W=se.stateNode,se=se.tag,se!==5&&se!==26&&se!==27||W===null||J===null||(se=ql(K,J),se!=null&&je.push(wa(K,se,W))),it)break;K=K.return}0<je.length&&(ne=new le(ne,ke,null,a,oe),ce.push({event:ne,listeners:je}))}}if((n&7)===0){e:{if(ne=t==="mouseover"||t==="pointerover",le=t==="mouseout"||t==="pointerout",ne&&a!==Ru&&(ke=a.relatedTarget||a.fromElement)&&(Rr(ke)||ke[rr]))break e;if((le||ne)&&(ne=oe.window===oe?oe:(ne=oe.ownerDocument)?ne.defaultView||ne.parentWindow:window,le?(ke=a.relatedTarget||a.toElement,le=ee,ke=ke?Rr(ke):null,ke!==null&&(it=u(ke),je=ke.tag,ke!==it||je!==5&&je!==27&&je!==6)&&(ke=null)):(le=null,ke=ee),le!==ke)){if(je=up,se="onMouseLeave",J="onMouseEnter",K="mouse",(t==="pointerout"||t==="pointerover")&&(je=fp,se="onPointerLeave",J="onPointerEnter",K="pointer"),it=le==null?ne:re(le),W=ke==null?ne:re(ke),ne=new je(se,K+"leave",le,a,oe),ne.target=it,ne.relatedTarget=W,se=null,Rr(oe)===ee&&(je=new je(J,K+"enter",ke,a,oe),je.target=W,je.relatedTarget=it,se=je),it=se,le&&ke)t:{for(je=lS,J=le,K=ke,W=0,se=J;se;se=je(se))W++;se=0;for(var Ne=K;Ne;Ne=je(Ne))se++;for(;0<W-se;)J=je(J),W--;for(;0<se-W;)K=je(K),se--;for(;W--;){if(J===K||K!==null&&J===K.alternate){je=J;break t}J=je(J),K=je(K)}je=null}else je=null;le!==null&&nb(ce,ne,le,je,!1),ke!==null&&it!==null&&nb(ce,it,ke,je,!0)}}e:{if(ne=ee?re(ee):window,le=ne.nodeName&&ne.nodeName.toLowerCase(),le==="select"||le==="input"&&ne.type==="file")var Ye=xp;else if(bp(ne))if(vp)Ye=gw;else{Ye=pw;var Ce=hw}else le=ne.nodeName,!le||le.toLowerCase()!=="input"||ne.type!=="checkbox"&&ne.type!=="radio"?ee&&ju(ee.elementType)&&(Ye=xp):Ye=mw;if(Ye&&(Ye=Ye(t,ee))){yp(ce,Ye,a,oe);break e}Ce&&Ce(t,ne,ee),t==="focusout"&&ee&&ne.type==="number"&&ee.memoizedProps.value!=null&&Tu(ne,"number",ne.value)}switch(Ce=ee?re(ee):window,t){case"focusin":(bp(Ce)||Ce.contentEditable==="true")&&(Yi=Ce,$u=ee,Kl=null);break;case"focusout":Kl=$u=Yi=null;break;case"mousedown":Pu=!0;break;case"contextmenu":case"mouseup":case"dragend":Pu=!1,Tp(ce,a,oe);break;case"selectionchange":if(yw)break;case"keydown":case"keyup":Tp(ce,a,oe)}var Le;if(Iu)e:{switch(t){case"compositionstart":var He="onCompositionStart";break e;case"compositionend":He="onCompositionEnd";break e;case"compositionupdate":He="onCompositionUpdate";break e}He=void 0}else Gi?mp(t,a)&&(He="onCompositionEnd"):t==="keydown"&&a.keyCode===229&&(He="onCompositionStart");He&&(dp&&a.locale!=="ko"&&(Gi||He!=="onCompositionStart"?He==="onCompositionEnd"&&Gi&&(Le=op()):(Lr=oe,Ou="value"in Lr?Lr.value:Lr.textContent,Gi=!0)),Ce=as(ee,He),0<Ce.length&&(He=new cp(He,t,null,a,oe),ce.push({event:He,listeners:Ce}),Le?He.data=Le:(Le=gp(a),Le!==null&&(He.data=Le)))),(Le=sw?uw(t,a):cw(t,a))&&(He=as(ee,"onBeforeInput"),0<He.length&&(Ce=new cp("onBeforeInput","beforeinput",null,a,oe),ce.push({event:Ce,listeners:He}),Ce.data=Le)),tS(ce,t,ee,a,oe)}eb(ce,n)})}function wa(t,n,a){return{instance:t,listener:n,currentTarget:a}}function as(t,n){for(var a=n+"Capture",s=[];t!==null;){var d=t,m=d.stateNode;if(d=d.tag,d!==5&&d!==26&&d!==27||m===null||(d=ql(t,a),d!=null&&s.unshift(wa(t,d,m)),d=ql(t,n),d!=null&&s.push(wa(t,d,m))),t.tag===3)return s;t=t.return}return[]}function lS(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function nb(t,n,a,s,d){for(var m=n._reactName,k=[];a!==null&&a!==s;){var _=a,P=_.alternate,ee=_.stateNode;if(_=_.tag,P!==null&&P===s)break;_!==5&&_!==26&&_!==27||ee===null||(P=ee,d?(ee=ql(a,m),ee!=null&&k.unshift(wa(a,ee,P))):d||(ee=ql(a,m),ee!=null&&k.push(wa(a,ee,P)))),a=a.return}k.length!==0&&t.push({event:n,listeners:k})}var aS=/\r\n?/g,oS=/\u0000|\uFFFD/g;function rb(t){return(typeof t=="string"?t:""+t).replace(aS,`
|
|
9
|
+
`).replace(oS,"")}function ib(t,n){return n=rb(n),rb(t)===n}function rt(t,n,a,s,d,m){switch(a){case"children":typeof s=="string"?n==="body"||n==="textarea"&&s===""||$i(t,s):(typeof s=="number"||typeof s=="bigint")&&n!=="body"&&$i(t,""+s);break;case"className":uo(t,"class",s);break;case"tabIndex":uo(t,"tabindex",s);break;case"dir":case"role":case"viewBox":case"width":case"height":uo(t,a,s);break;case"style":ip(t,s,m);break;case"data":if(n!=="object"){uo(t,"data",s);break}case"src":case"href":if(s===""&&(n!=="a"||a!=="href")){t.removeAttribute(a);break}if(s==null||typeof s=="function"||typeof s=="symbol"||typeof s=="boolean"){t.removeAttribute(a);break}s=fo(""+s),t.setAttribute(a,s);break;case"action":case"formAction":if(typeof s=="function"){t.setAttribute(a,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof m=="function"&&(a==="formAction"?(n!=="input"&&rt(t,n,"name",d.name,d,null),rt(t,n,"formEncType",d.formEncType,d,null),rt(t,n,"formMethod",d.formMethod,d,null),rt(t,n,"formTarget",d.formTarget,d,null)):(rt(t,n,"encType",d.encType,d,null),rt(t,n,"method",d.method,d,null),rt(t,n,"target",d.target,d,null)));if(s==null||typeof s=="symbol"||typeof s=="boolean"){t.removeAttribute(a);break}s=fo(""+s),t.setAttribute(a,s);break;case"onClick":s!=null&&(t.onclick=lr);break;case"onScroll":s!=null&&Fe("scroll",t);break;case"onScrollEnd":s!=null&&Fe("scrollend",t);break;case"dangerouslySetInnerHTML":if(s!=null){if(typeof s!="object"||!("__html"in s))throw Error(l(61));if(a=s.__html,a!=null){if(d.children!=null)throw Error(l(60));t.innerHTML=a}}break;case"multiple":t.multiple=s&&typeof s!="function"&&typeof s!="symbol";break;case"muted":t.muted=s&&typeof s!="function"&&typeof s!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(s==null||typeof s=="function"||typeof s=="boolean"||typeof s=="symbol"){t.removeAttribute("xlink:href");break}a=fo(""+s),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",a);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":s!=null&&typeof s!="function"&&typeof s!="symbol"?t.setAttribute(a,""+s):t.removeAttribute(a);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":s&&typeof s!="function"&&typeof s!="symbol"?t.setAttribute(a,""):t.removeAttribute(a);break;case"capture":case"download":s===!0?t.setAttribute(a,""):s!==!1&&s!=null&&typeof s!="function"&&typeof s!="symbol"?t.setAttribute(a,s):t.removeAttribute(a);break;case"cols":case"rows":case"size":case"span":s!=null&&typeof s!="function"&&typeof s!="symbol"&&!isNaN(s)&&1<=s?t.setAttribute(a,s):t.removeAttribute(a);break;case"rowSpan":case"start":s==null||typeof s=="function"||typeof s=="symbol"||isNaN(s)?t.removeAttribute(a):t.setAttribute(a,s);break;case"popover":Fe("beforetoggle",t),Fe("toggle",t),so(t,"popover",s);break;case"xlinkActuate":ir(t,"http://www.w3.org/1999/xlink","xlink:actuate",s);break;case"xlinkArcrole":ir(t,"http://www.w3.org/1999/xlink","xlink:arcrole",s);break;case"xlinkRole":ir(t,"http://www.w3.org/1999/xlink","xlink:role",s);break;case"xlinkShow":ir(t,"http://www.w3.org/1999/xlink","xlink:show",s);break;case"xlinkTitle":ir(t,"http://www.w3.org/1999/xlink","xlink:title",s);break;case"xlinkType":ir(t,"http://www.w3.org/1999/xlink","xlink:type",s);break;case"xmlBase":ir(t,"http://www.w3.org/XML/1998/namespace","xml:base",s);break;case"xmlLang":ir(t,"http://www.w3.org/XML/1998/namespace","xml:lang",s);break;case"xmlSpace":ir(t,"http://www.w3.org/XML/1998/namespace","xml:space",s);break;case"is":so(t,"is",s);break;case"innerText":case"textContent":break;default:(!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")&&(a=Mv.get(a)||a,so(t,a,s))}}function gf(t,n,a,s,d,m){switch(a){case"style":ip(t,s,m);break;case"dangerouslySetInnerHTML":if(s!=null){if(typeof s!="object"||!("__html"in s))throw Error(l(61));if(a=s.__html,a!=null){if(d.children!=null)throw Error(l(60));t.innerHTML=a}}break;case"children":typeof s=="string"?$i(t,s):(typeof s=="number"||typeof s=="bigint")&&$i(t,""+s);break;case"onScroll":s!=null&&Fe("scroll",t);break;case"onScrollEnd":s!=null&&Fe("scrollend",t);break;case"onClick":s!=null&&(t.onclick=lr);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Ie.hasOwnProperty(a))e:{if(a[0]==="o"&&a[1]==="n"&&(d=a.endsWith("Capture"),n=a.slice(2,d?a.length-7:void 0),m=t[wt]||null,m=m!=null?m[a]:null,typeof m=="function"&&t.removeEventListener(n,m,d),typeof s=="function")){typeof m!="function"&&m!==null&&(a in t?t[a]=null:t.hasAttribute(a)&&t.removeAttribute(a)),t.addEventListener(n,s,d);break e}a in t?t[a]=s:s===!0?t.setAttribute(a,""):so(t,a,s)}}}function Bt(t,n,a){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Fe("error",t),Fe("load",t);var s=!1,d=!1,m;for(m in a)if(a.hasOwnProperty(m)){var k=a[m];if(k!=null)switch(m){case"src":s=!0;break;case"srcSet":d=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(l(137,n));default:rt(t,n,m,k,a,null)}}d&&rt(t,n,"srcSet",a.srcSet,a,null),s&&rt(t,n,"src",a.src,a,null);return;case"input":Fe("invalid",t);var _=m=k=d=null,P=null,ee=null;for(s in a)if(a.hasOwnProperty(s)){var oe=a[s];if(oe!=null)switch(s){case"name":d=oe;break;case"type":k=oe;break;case"checked":P=oe;break;case"defaultChecked":ee=oe;break;case"value":m=oe;break;case"defaultValue":_=oe;break;case"children":case"dangerouslySetInnerHTML":if(oe!=null)throw Error(l(137,n));break;default:rt(t,n,s,oe,a,null)}}ep(t,m,_,P,ee,k,d,!1);return;case"select":Fe("invalid",t),s=k=m=null;for(d in a)if(a.hasOwnProperty(d)&&(_=a[d],_!=null))switch(d){case"value":m=_;break;case"defaultValue":k=_;break;case"multiple":s=_;default:rt(t,n,d,_,a,null)}n=m,a=k,t.multiple=!!s,n!=null?qi(t,!!s,n,!1):a!=null&&qi(t,!!s,a,!0);return;case"textarea":Fe("invalid",t),m=d=s=null;for(k in a)if(a.hasOwnProperty(k)&&(_=a[k],_!=null))switch(k){case"value":s=_;break;case"defaultValue":d=_;break;case"children":m=_;break;case"dangerouslySetInnerHTML":if(_!=null)throw Error(l(91));break;default:rt(t,n,k,_,a,null)}np(t,s,d,m);return;case"option":for(P in a)a.hasOwnProperty(P)&&(s=a[P],s!=null)&&(P==="selected"?t.selected=s&&typeof s!="function"&&typeof s!="symbol":rt(t,n,P,s,a,null));return;case"dialog":Fe("beforetoggle",t),Fe("toggle",t),Fe("cancel",t),Fe("close",t);break;case"iframe":case"object":Fe("load",t);break;case"video":case"audio":for(s=0;s<va.length;s++)Fe(va[s],t);break;case"image":Fe("error",t),Fe("load",t);break;case"details":Fe("toggle",t);break;case"embed":case"source":case"link":Fe("error",t),Fe("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(ee in a)if(a.hasOwnProperty(ee)&&(s=a[ee],s!=null))switch(ee){case"children":case"dangerouslySetInnerHTML":throw Error(l(137,n));default:rt(t,n,ee,s,a,null)}return;default:if(ju(n)){for(oe in a)a.hasOwnProperty(oe)&&(s=a[oe],s!==void 0&&gf(t,n,oe,s,a,void 0));return}}for(_ in a)a.hasOwnProperty(_)&&(s=a[_],s!=null&&rt(t,n,_,s,a,null))}function sS(t,n,a,s){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var d=null,m=null,k=null,_=null,P=null,ee=null,oe=null;for(le in a){var ce=a[le];if(a.hasOwnProperty(le)&&ce!=null)switch(le){case"checked":break;case"value":break;case"defaultValue":P=ce;default:s.hasOwnProperty(le)||rt(t,n,le,null,s,ce)}}for(var ne in s){var le=s[ne];if(ce=a[ne],s.hasOwnProperty(ne)&&(le!=null||ce!=null))switch(ne){case"type":m=le;break;case"name":d=le;break;case"checked":ee=le;break;case"defaultChecked":oe=le;break;case"value":k=le;break;case"defaultValue":_=le;break;case"children":case"dangerouslySetInnerHTML":if(le!=null)throw Error(l(137,n));break;default:le!==ce&&rt(t,n,ne,le,s,ce)}}Au(t,k,_,P,ee,oe,m,d);return;case"select":le=k=_=ne=null;for(m in a)if(P=a[m],a.hasOwnProperty(m)&&P!=null)switch(m){case"value":break;case"multiple":le=P;default:s.hasOwnProperty(m)||rt(t,n,m,null,s,P)}for(d in s)if(m=s[d],P=a[d],s.hasOwnProperty(d)&&(m!=null||P!=null))switch(d){case"value":ne=m;break;case"defaultValue":_=m;break;case"multiple":k=m;default:m!==P&&rt(t,n,d,m,s,P)}n=_,a=k,s=le,ne!=null?qi(t,!!a,ne,!1):!!s!=!!a&&(n!=null?qi(t,!!a,n,!0):qi(t,!!a,a?[]:"",!1));return;case"textarea":le=ne=null;for(_ in a)if(d=a[_],a.hasOwnProperty(_)&&d!=null&&!s.hasOwnProperty(_))switch(_){case"value":break;case"children":break;default:rt(t,n,_,null,s,d)}for(k in s)if(d=s[k],m=a[k],s.hasOwnProperty(k)&&(d!=null||m!=null))switch(k){case"value":ne=d;break;case"defaultValue":le=d;break;case"children":break;case"dangerouslySetInnerHTML":if(d!=null)throw Error(l(91));break;default:d!==m&&rt(t,n,k,d,s,m)}tp(t,ne,le);return;case"option":for(var ke in a)ne=a[ke],a.hasOwnProperty(ke)&&ne!=null&&!s.hasOwnProperty(ke)&&(ke==="selected"?t.selected=!1:rt(t,n,ke,null,s,ne));for(P in s)ne=s[P],le=a[P],s.hasOwnProperty(P)&&ne!==le&&(ne!=null||le!=null)&&(P==="selected"?t.selected=ne&&typeof ne!="function"&&typeof ne!="symbol":rt(t,n,P,ne,s,le));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 je in a)ne=a[je],a.hasOwnProperty(je)&&ne!=null&&!s.hasOwnProperty(je)&&rt(t,n,je,null,s,ne);for(ee in s)if(ne=s[ee],le=a[ee],s.hasOwnProperty(ee)&&ne!==le&&(ne!=null||le!=null))switch(ee){case"children":case"dangerouslySetInnerHTML":if(ne!=null)throw Error(l(137,n));break;default:rt(t,n,ee,ne,s,le)}return;default:if(ju(n)){for(var it in a)ne=a[it],a.hasOwnProperty(it)&&ne!==void 0&&!s.hasOwnProperty(it)&&gf(t,n,it,void 0,s,ne);for(oe in s)ne=s[oe],le=a[oe],!s.hasOwnProperty(oe)||ne===le||ne===void 0&&le===void 0||gf(t,n,oe,ne,s,le);return}}for(var J in a)ne=a[J],a.hasOwnProperty(J)&&ne!=null&&!s.hasOwnProperty(J)&&rt(t,n,J,null,s,ne);for(ce in s)ne=s[ce],le=a[ce],!s.hasOwnProperty(ce)||ne===le||ne==null&&le==null||rt(t,n,ce,ne,s,le)}function lb(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function uS(){if(typeof performance.getEntriesByType=="function"){for(var t=0,n=0,a=performance.getEntriesByType("resource"),s=0;s<a.length;s++){var d=a[s],m=d.transferSize,k=d.initiatorType,_=d.duration;if(m&&_&&lb(k)){for(k=0,_=d.responseEnd,s+=1;s<a.length;s++){var P=a[s],ee=P.startTime;if(ee>_)break;var oe=P.transferSize,ce=P.initiatorType;oe&&lb(ce)&&(P=P.responseEnd,k+=oe*(P<_?1:(_-ee)/(P-ee)))}if(--s,n+=8*(m+k)/(d.duration/1e3),t++,10<t)break}}if(0<t)return n/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t=="number")?t:5}var bf=null,yf=null;function os(t){return t.nodeType===9?t:t.ownerDocument}function ab(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function ob(t,n){if(t===0)switch(n){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&n==="foreignObject"?0:t}function xf(t,n){return t==="textarea"||t==="noscript"||typeof n.children=="string"||typeof n.children=="number"||typeof n.children=="bigint"||typeof n.dangerouslySetInnerHTML=="object"&&n.dangerouslySetInnerHTML!==null&&n.dangerouslySetInnerHTML.__html!=null}var vf=null;function cS(){var t=window.event;return t&&t.type==="popstate"?t===vf?!1:(vf=t,!0):(vf=null,!1)}var sb=typeof setTimeout=="function"?setTimeout:void 0,fS=typeof clearTimeout=="function"?clearTimeout:void 0,ub=typeof Promise=="function"?Promise:void 0,dS=typeof queueMicrotask=="function"?queueMicrotask:typeof ub<"u"?function(t){return ub.resolve(null).then(t).catch(hS)}:sb;function hS(t){setTimeout(function(){throw t})}function Zr(t){return t==="head"}function cb(t,n){var a=n,s=0;do{var d=a.nextSibling;if(t.removeChild(a),d&&d.nodeType===8)if(a=d.data,a==="/$"||a==="/&"){if(s===0){t.removeChild(d),vl(n);return}s--}else if(a==="$"||a==="$?"||a==="$~"||a==="$!"||a==="&")s++;else if(a==="html")Sa(t.ownerDocument.documentElement);else if(a==="head"){a=t.ownerDocument.head,Sa(a);for(var m=a.firstChild;m;){var k=m.nextSibling,_=m.nodeName;m[hi]||_==="SCRIPT"||_==="STYLE"||_==="LINK"&&m.rel.toLowerCase()==="stylesheet"||a.removeChild(m),m=k}}else a==="body"&&Sa(t.ownerDocument.body);a=d}while(a);vl(n)}function fb(t,n){var a=t;t=0;do{var s=a.nextSibling;if(a.nodeType===1?n?(a._stashedDisplay=a.style.display,a.style.display="none"):(a.style.display=a._stashedDisplay||"",a.getAttribute("style")===""&&a.removeAttribute("style")):a.nodeType===3&&(n?(a._stashedText=a.nodeValue,a.nodeValue=""):a.nodeValue=a._stashedText||""),s&&s.nodeType===8)if(a=s.data,a==="/$"){if(t===0)break;t--}else a!=="$"&&a!=="$?"&&a!=="$~"&&a!=="$!"||t++;a=s}while(a)}function wf(t){var n=t.firstChild;for(n&&n.nodeType===10&&(n=n.nextSibling);n;){var a=n;switch(n=n.nextSibling,a.nodeName){case"HTML":case"HEAD":case"BODY":wf(a),Hl(a);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(a.rel.toLowerCase()==="stylesheet")continue}t.removeChild(a)}}function pS(t,n,a,s){for(;t.nodeType===1;){var d=a;if(t.nodeName.toLowerCase()!==n.toLowerCase()){if(!s&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(s){if(!t[hi])switch(n){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(m=t.getAttribute("rel"),m==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(m!==d.rel||t.getAttribute("href")!==(d.href==null||d.href===""?null:d.href)||t.getAttribute("crossorigin")!==(d.crossOrigin==null?null:d.crossOrigin)||t.getAttribute("title")!==(d.title==null?null:d.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(m=t.getAttribute("src"),(m!==(d.src==null?null:d.src)||t.getAttribute("type")!==(d.type==null?null:d.type)||t.getAttribute("crossorigin")!==(d.crossOrigin==null?null:d.crossOrigin))&&m&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(n==="input"&&t.type==="hidden"){var m=d.name==null?null:""+d.name;if(d.type==="hidden"&&t.getAttribute("name")===m)return t}else return t;if(t=Ln(t.nextSibling),t===null)break}return null}function mS(t,n,a){if(n==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!a||(t=Ln(t.nextSibling),t===null))return null;return t}function db(t,n){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!n||(t=Ln(t.nextSibling),t===null))return null;return t}function Sf(t){return t.data==="$?"||t.data==="$~"}function kf(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function gS(t,n){var a=t.ownerDocument;if(t.data==="$~")t._reactRetry=n;else if(t.data!=="$?"||a.readyState!=="loading")n();else{var s=function(){n(),a.removeEventListener("DOMContentLoaded",s)};a.addEventListener("DOMContentLoaded",s),t._reactRetry=s}}function Ln(t){for(;t!=null;t=t.nextSibling){var n=t.nodeType;if(n===1||n===3)break;if(n===8){if(n=t.data,n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"||n==="F!"||n==="F")break;if(n==="/$"||n==="/&")return null}}return t}var Ef=null;function hb(t){t=t.nextSibling;for(var n=0;t;){if(t.nodeType===8){var a=t.data;if(a==="/$"||a==="/&"){if(n===0)return Ln(t.nextSibling);n--}else a!=="$"&&a!=="$!"&&a!=="$?"&&a!=="$~"&&a!=="&"||n++}t=t.nextSibling}return null}function pb(t){t=t.previousSibling;for(var n=0;t;){if(t.nodeType===8){var a=t.data;if(a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"){if(n===0)return t;n--}else a!=="/$"&&a!=="/&"||n++}t=t.previousSibling}return null}function mb(t,n,a){switch(n=os(a),t){case"html":if(t=n.documentElement,!t)throw Error(l(452));return t;case"head":if(t=n.head,!t)throw Error(l(453));return t;case"body":if(t=n.body,!t)throw Error(l(454));return t;default:throw Error(l(451))}}function Sa(t){for(var n=t.attributes;n.length;)t.removeAttributeNode(n[0]);Hl(t)}var Dn=new Map,gb=new Set;function ss(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var wr=X.d;X.d={f:bS,r:yS,D:xS,C:vS,L:wS,m:SS,X:ES,S:kS,M:CS};function bS(){var t=wr.f(),n=Wo();return t||n}function yS(t){var n=_r(t);n!==null&&n.tag===5&&n.type==="form"?Dm(n):wr.r(t)}var bl=typeof document>"u"?null:document;function bb(t,n,a){var s=bl;if(s&&typeof n=="string"&&n){var d=Cn(n);d='link[rel="'+t+'"][href="'+d+'"]',typeof a=="string"&&(d+='[crossorigin="'+a+'"]'),gb.has(d)||(gb.add(d),t={rel:t,crossOrigin:a,href:n},s.querySelector(d)===null&&(n=s.createElement("link"),Bt(n,"link",t),Se(n),s.head.appendChild(n)))}}function xS(t){wr.D(t),bb("dns-prefetch",t,null)}function vS(t,n){wr.C(t,n),bb("preconnect",t,n)}function wS(t,n,a){wr.L(t,n,a);var s=bl;if(s&&t&&n){var d='link[rel="preload"][as="'+Cn(n)+'"]';n==="image"&&a&&a.imageSrcSet?(d+='[imagesrcset="'+Cn(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(d+='[imagesizes="'+Cn(a.imageSizes)+'"]')):d+='[href="'+Cn(t)+'"]';var m=d;switch(n){case"style":m=yl(t);break;case"script":m=xl(t)}Dn.has(m)||(t=b({rel:"preload",href:n==="image"&&a&&a.imageSrcSet?void 0:t,as:n},a),Dn.set(m,t),s.querySelector(d)!==null||n==="style"&&s.querySelector(ka(m))||n==="script"&&s.querySelector(Ea(m))||(n=s.createElement("link"),Bt(n,"link",t),Se(n),s.head.appendChild(n)))}}function SS(t,n){wr.m(t,n);var a=bl;if(a&&t){var s=n&&typeof n.as=="string"?n.as:"script",d='link[rel="modulepreload"][as="'+Cn(s)+'"][href="'+Cn(t)+'"]',m=d;switch(s){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":m=xl(t)}if(!Dn.has(m)&&(t=b({rel:"modulepreload",href:t},n),Dn.set(m,t),a.querySelector(d)===null)){switch(s){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(Ea(m)))return}s=a.createElement("link"),Bt(s,"link",t),Se(s),a.head.appendChild(s)}}}function kS(t,n,a){wr.S(t,n,a);var s=bl;if(s&&t){var d=ve(s).hoistableStyles,m=yl(t);n=n||"default";var k=d.get(m);if(!k){var _={loading:0,preload:null};if(k=s.querySelector(ka(m)))_.loading=5;else{t=b({rel:"stylesheet",href:t,"data-precedence":n},a),(a=Dn.get(m))&&Cf(t,a);var P=k=s.createElement("link");Se(P),Bt(P,"link",t),P._p=new Promise(function(ee,oe){P.onload=ee,P.onerror=oe}),P.addEventListener("load",function(){_.loading|=1}),P.addEventListener("error",function(){_.loading|=2}),_.loading|=4,us(k,n,s)}k={type:"stylesheet",instance:k,count:1,state:_},d.set(m,k)}}}function ES(t,n){wr.X(t,n);var a=bl;if(a&&t){var s=ve(a).hoistableScripts,d=xl(t),m=s.get(d);m||(m=a.querySelector(Ea(d)),m||(t=b({src:t,async:!0},n),(n=Dn.get(d))&&Nf(t,n),m=a.createElement("script"),Se(m),Bt(m,"link",t),a.head.appendChild(m)),m={type:"script",instance:m,count:1,state:null},s.set(d,m))}}function CS(t,n){wr.M(t,n);var a=bl;if(a&&t){var s=ve(a).hoistableScripts,d=xl(t),m=s.get(d);m||(m=a.querySelector(Ea(d)),m||(t=b({src:t,async:!0,type:"module"},n),(n=Dn.get(d))&&Nf(t,n),m=a.createElement("script"),Se(m),Bt(m,"link",t),a.head.appendChild(m)),m={type:"script",instance:m,count:1,state:null},s.set(d,m))}}function yb(t,n,a,s){var d=(d=fe.current)?ss(d):null;if(!d)throw Error(l(446));switch(t){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(n=yl(a.href),a=ve(d).hoistableStyles,s=a.get(n),s||(s={type:"style",instance:null,count:0,state:null},a.set(n,s)),s):{type:"void",instance:null,count:0,state:null};case"link":if(a.rel==="stylesheet"&&typeof a.href=="string"&&typeof a.precedence=="string"){t=yl(a.href);var m=ve(d).hoistableStyles,k=m.get(t);if(k||(d=d.ownerDocument||d,k={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},m.set(t,k),(m=d.querySelector(ka(t)))&&!m._p&&(k.instance=m,k.state.loading=5),Dn.has(t)||(a={rel:"preload",as:"style",href:a.href,crossOrigin:a.crossOrigin,integrity:a.integrity,media:a.media,hrefLang:a.hrefLang,referrerPolicy:a.referrerPolicy},Dn.set(t,a),m||NS(d,t,a,k.state))),n&&s===null)throw Error(l(528,""));return k}if(n&&s!==null)throw Error(l(529,""));return null;case"script":return n=a.async,a=a.src,typeof a=="string"&&n&&typeof n!="function"&&typeof n!="symbol"?(n=xl(a),a=ve(d).hoistableScripts,s=a.get(n),s||(s={type:"script",instance:null,count:0,state:null},a.set(n,s)),s):{type:"void",instance:null,count:0,state:null};default:throw Error(l(444,t))}}function yl(t){return'href="'+Cn(t)+'"'}function ka(t){return'link[rel="stylesheet"]['+t+"]"}function xb(t){return b({},t,{"data-precedence":t.precedence,precedence:null})}function NS(t,n,a,s){t.querySelector('link[rel="preload"][as="style"]['+n+"]")?s.loading=1:(n=t.createElement("link"),s.preload=n,n.addEventListener("load",function(){return s.loading|=1}),n.addEventListener("error",function(){return s.loading|=2}),Bt(n,"link",a),Se(n),t.head.appendChild(n))}function xl(t){return'[src="'+Cn(t)+'"]'}function Ea(t){return"script[async]"+t}function vb(t,n,a){if(n.count++,n.instance===null)switch(n.type){case"style":var s=t.querySelector('style[data-href~="'+Cn(a.href)+'"]');if(s)return n.instance=s,Se(s),s;var d=b({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return s=(t.ownerDocument||t).createElement("style"),Se(s),Bt(s,"style",d),us(s,a.precedence,t),n.instance=s;case"stylesheet":d=yl(a.href);var m=t.querySelector(ka(d));if(m)return n.state.loading|=4,n.instance=m,Se(m),m;s=xb(a),(d=Dn.get(d))&&Cf(s,d),m=(t.ownerDocument||t).createElement("link"),Se(m);var k=m;return k._p=new Promise(function(_,P){k.onload=_,k.onerror=P}),Bt(m,"link",s),n.state.loading|=4,us(m,a.precedence,t),n.instance=m;case"script":return m=xl(a.src),(d=t.querySelector(Ea(m)))?(n.instance=d,Se(d),d):(s=a,(d=Dn.get(m))&&(s=b({},a),Nf(s,d)),t=t.ownerDocument||t,d=t.createElement("script"),Se(d),Bt(d,"link",s),t.head.appendChild(d),n.instance=d);case"void":return null;default:throw Error(l(443,n.type))}else n.type==="stylesheet"&&(n.state.loading&4)===0&&(s=n.instance,n.state.loading|=4,us(s,a.precedence,t));return n.instance}function us(t,n,a){for(var s=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),d=s.length?s[s.length-1]:null,m=d,k=0;k<s.length;k++){var _=s[k];if(_.dataset.precedence===n)m=_;else if(m!==d)break}m?m.parentNode.insertBefore(t,m.nextSibling):(n=a.nodeType===9?a.head:a,n.insertBefore(t,n.firstChild))}function Cf(t,n){t.crossOrigin==null&&(t.crossOrigin=n.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=n.referrerPolicy),t.title==null&&(t.title=n.title)}function Nf(t,n){t.crossOrigin==null&&(t.crossOrigin=n.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=n.referrerPolicy),t.integrity==null&&(t.integrity=n.integrity)}var cs=null;function wb(t,n,a){if(cs===null){var s=new Map,d=cs=new Map;d.set(a,s)}else d=cs,s=d.get(a),s||(s=new Map,d.set(a,s));if(s.has(t))return s;for(s.set(t,null),a=a.getElementsByTagName(t),d=0;d<a.length;d++){var m=a[d];if(!(m[hi]||m[Tt]||t==="link"&&m.getAttribute("rel")==="stylesheet")&&m.namespaceURI!=="http://www.w3.org/2000/svg"){var k=m.getAttribute(n)||"";k=t+k;var _=s.get(k);_?_.push(m):s.set(k,[m])}}return s}function Sb(t,n,a){t=t.ownerDocument||t,t.head.insertBefore(a,n==="title"?t.querySelector("head > title"):null)}function AS(t,n,a){if(a===1||n.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof n.precedence!="string"||typeof n.href!="string"||n.href==="")break;return!0;case"link":if(typeof n.rel!="string"||typeof n.href!="string"||n.href===""||n.onLoad||n.onError)break;return n.rel==="stylesheet"?(t=n.disabled,typeof n.precedence=="string"&&t==null):!0;case"script":if(n.async&&typeof n.async!="function"&&typeof n.async!="symbol"&&!n.onLoad&&!n.onError&&n.src&&typeof n.src=="string")return!0}return!1}function kb(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function TS(t,n,a,s){if(a.type==="stylesheet"&&(typeof s.media!="string"||matchMedia(s.media).matches!==!1)&&(a.state.loading&4)===0){if(a.instance===null){var d=yl(s.href),m=n.querySelector(ka(d));if(m){n=m._p,n!==null&&typeof n=="object"&&typeof n.then=="function"&&(t.count++,t=fs.bind(t),n.then(t,t)),a.state.loading|=4,a.instance=m,Se(m);return}m=n.ownerDocument||n,s=xb(s),(d=Dn.get(d))&&Cf(s,d),m=m.createElement("link"),Se(m);var k=m;k._p=new Promise(function(_,P){k.onload=_,k.onerror=P}),Bt(m,"link",s),a.instance=m}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(a,n),(n=a.state.preload)&&(a.state.loading&3)===0&&(t.count++,a=fs.bind(t),n.addEventListener("load",a),n.addEventListener("error",a))}}var Af=0;function jS(t,n){return t.stylesheets&&t.count===0&&hs(t,t.stylesheets),0<t.count||0<t.imgCount?function(a){var s=setTimeout(function(){if(t.stylesheets&&hs(t,t.stylesheets),t.unsuspend){var m=t.unsuspend;t.unsuspend=null,m()}},6e4+n);0<t.imgBytes&&Af===0&&(Af=62500*uS());var d=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&hs(t,t.stylesheets),t.unsuspend)){var m=t.unsuspend;t.unsuspend=null,m()}},(t.imgBytes>Af?50:800)+n);return t.unsuspend=a,function(){t.unsuspend=null,clearTimeout(s),clearTimeout(d)}}:null}function fs(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)hs(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var ds=null;function hs(t,n){t.stylesheets=null,t.unsuspend!==null&&(t.count++,ds=new Map,n.forEach(RS,t),ds=null,fs.call(t))}function RS(t,n){if(!(n.state.loading&4)){var a=ds.get(t);if(a)var s=a.get(null);else{a=new Map,ds.set(t,a);for(var d=t.querySelectorAll("link[data-precedence],style[data-precedence]"),m=0;m<d.length;m++){var k=d[m];(k.nodeName==="LINK"||k.getAttribute("media")!=="not all")&&(a.set(k.dataset.precedence,k),s=k)}s&&a.set(null,s)}d=n.instance,k=d.getAttribute("data-precedence"),m=a.get(k)||s,m===s&&a.set(null,d),a.set(k,d),this.count++,s=fs.bind(this),d.addEventListener("load",s),d.addEventListener("error",s),m?m.parentNode.insertBefore(d,m.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(d,t.firstChild)),n.state.loading|=4}}var Ca={$$typeof:j,Provider:null,Consumer:null,_currentValue:M,_currentValue2:M,_threadCount:0};function _S(t,n,a,s,d,m,k,_,P){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=fi(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=fi(0),this.hiddenUpdates=fi(null),this.identifierPrefix=s,this.onUncaughtError=d,this.onCaughtError=m,this.onRecoverableError=k,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=P,this.incompleteTransitions=new Map}function Eb(t,n,a,s,d,m,k,_,P,ee,oe,ce){return t=new _S(t,n,a,k,P,ee,oe,ce,_),n=1,m===!0&&(n|=24),m=hn(3,null,null,n),t.current=m,m.stateNode=t,n=lc(),n.refCount++,t.pooledCache=n,n.refCount++,m.memoizedState={element:s,isDehydrated:a,cache:n},uc(m),t}function Cb(t){return t?(t=Ki,t):Ki}function Nb(t,n,a,s,d,m){d=Cb(d),s.context===null?s.context=d:s.pendingContext=d,s=Br(n),s.payload={element:a},m=m===void 0?null:m,m!==null&&(s.callback=m),a=Ir(t,s,n),a!==null&&(ln(a,t,n),ra(a,t,n))}function Ab(t,n){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var a=t.retryLane;t.retryLane=a!==0&&a<n?a:n}}function Tf(t,n){Ab(t,n),(t=t.alternate)&&Ab(t,n)}function Tb(t){if(t.tag===13||t.tag===31){var n=bi(t,67108864);n!==null&&ln(n,t,67108864),Tf(t,67108864)}}function jb(t){if(t.tag===13||t.tag===31){var n=yn();n=Ui(n);var a=bi(t,n);a!==null&&ln(a,t,n),Tf(t,n)}}var ps=!0;function LS(t,n,a,s){var d=B.T;B.T=null;var m=X.p;try{X.p=2,jf(t,n,a,s)}finally{X.p=m,B.T=d}}function DS(t,n,a,s){var d=B.T;B.T=null;var m=X.p;try{X.p=8,jf(t,n,a,s)}finally{X.p=m,B.T=d}}function jf(t,n,a,s){if(ps){var d=Rf(s);if(d===null)mf(t,n,s,ms,a),_b(t,s);else if(MS(d,t,n,a,s))s.stopPropagation();else if(_b(t,s),n&4&&-1<OS.indexOf(t)){for(;d!==null;){var m=_r(d);if(m!==null)switch(m.tag){case 3:if(m=m.stateNode,m.current.memoizedState.isDehydrated){var k=Fn(m.pendingLanes);if(k!==0){var _=m;for(_.pendingLanes|=2,_.entangledLanes|=2;k;){var P=1<<31-Je(k);_.entanglements[1]|=P,k&=~P}Kn(m),(Ze&6)===0&&(Qo=at()+500,xa(0))}}break;case 31:case 13:_=bi(m,2),_!==null&&ln(_,m,2),Wo(),Tf(m,2)}if(m=Rf(s),m===null&&mf(t,n,s,ms,a),m===d)break;d=m}d!==null&&s.stopPropagation()}else mf(t,n,s,null,a)}}function Rf(t){return t=_u(t),_f(t)}var ms=null;function _f(t){if(ms=null,t=Rr(t),t!==null){var n=u(t);if(n===null)t=null;else{var a=n.tag;if(a===13){if(t=c(n),t!==null)return t;t=null}else if(a===31){if(t=f(n),t!==null)return t;t=null}else if(a===3){if(n.stateNode.current.memoizedState.isDehydrated)return n.tag===3?n.stateNode.containerInfo:null;t=null}else n!==t&&(t=null)}}return ms=t,null}function Rb(t){switch(t){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(nr()){case ae:return 2;case be:return 8;case Te:case Oe:return 32;case Ve:return 268435456;default:return 32}default:return 32}}var Lf=!1,Kr=null,Qr=null,Jr=null,Na=new Map,Aa=new Map,Wr=[],OS="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 _b(t,n){switch(t){case"focusin":case"focusout":Kr=null;break;case"dragenter":case"dragleave":Qr=null;break;case"mouseover":case"mouseout":Jr=null;break;case"pointerover":case"pointerout":Na.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":Aa.delete(n.pointerId)}}function Ta(t,n,a,s,d,m){return t===null||t.nativeEvent!==m?(t={blockedOn:n,domEventName:a,eventSystemFlags:s,nativeEvent:m,targetContainers:[d]},n!==null&&(n=_r(n),n!==null&&Tb(n)),t):(t.eventSystemFlags|=s,n=t.targetContainers,d!==null&&n.indexOf(d)===-1&&n.push(d),t)}function MS(t,n,a,s,d){switch(n){case"focusin":return Kr=Ta(Kr,t,n,a,s,d),!0;case"dragenter":return Qr=Ta(Qr,t,n,a,s,d),!0;case"mouseover":return Jr=Ta(Jr,t,n,a,s,d),!0;case"pointerover":var m=d.pointerId;return Na.set(m,Ta(Na.get(m)||null,t,n,a,s,d)),!0;case"gotpointercapture":return m=d.pointerId,Aa.set(m,Ta(Aa.get(m)||null,t,n,a,s,d)),!0}return!1}function Lb(t){var n=Rr(t.target);if(n!==null){var a=u(n);if(a!==null){if(n=a.tag,n===13){if(n=c(a),n!==null){t.blockedOn=n,ao(t.priority,function(){jb(a)});return}}else if(n===31){if(n=f(a),n!==null){t.blockedOn=n,ao(t.priority,function(){jb(a)});return}}else if(n===3&&a.stateNode.current.memoizedState.isDehydrated){t.blockedOn=a.tag===3?a.stateNode.containerInfo:null;return}}}t.blockedOn=null}function gs(t){if(t.blockedOn!==null)return!1;for(var n=t.targetContainers;0<n.length;){var a=Rf(t.nativeEvent);if(a===null){a=t.nativeEvent;var s=new a.constructor(a.type,a);Ru=s,a.target.dispatchEvent(s),Ru=null}else return n=_r(a),n!==null&&Tb(n),t.blockedOn=a,!1;n.shift()}return!0}function Db(t,n,a){gs(t)&&a.delete(n)}function zS(){Lf=!1,Kr!==null&&gs(Kr)&&(Kr=null),Qr!==null&&gs(Qr)&&(Qr=null),Jr!==null&&gs(Jr)&&(Jr=null),Na.forEach(Db),Aa.forEach(Db)}function bs(t,n){t.blockedOn===n&&(t.blockedOn=null,Lf||(Lf=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,zS)))}var ys=null;function Ob(t){ys!==t&&(ys=t,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){ys===t&&(ys=null);for(var n=0;n<t.length;n+=3){var a=t[n],s=t[n+1],d=t[n+2];if(typeof s!="function"){if(_f(s||a)===null)continue;break}var m=_r(a);m!==null&&(t.splice(n,3),n-=3,jc(m,{pending:!0,data:d,method:a.method,action:s},s,d))}}))}function vl(t){function n(P){return bs(P,t)}Kr!==null&&bs(Kr,t),Qr!==null&&bs(Qr,t),Jr!==null&&bs(Jr,t),Na.forEach(n),Aa.forEach(n);for(var a=0;a<Wr.length;a++){var s=Wr[a];s.blockedOn===t&&(s.blockedOn=null)}for(;0<Wr.length&&(a=Wr[0],a.blockedOn===null);)Lb(a),a.blockedOn===null&&Wr.shift();if(a=(t.ownerDocument||t).$$reactFormReplay,a!=null)for(s=0;s<a.length;s+=3){var d=a[s],m=a[s+1],k=d[wt]||null;if(typeof m=="function")k||Ob(a);else if(k){var _=null;if(m&&m.hasAttribute("formAction")){if(d=m,k=m[wt]||null)_=k.formAction;else if(_f(d)!==null)continue}else _=k.action;typeof _=="function"?a[s+1]=_:(a.splice(s,3),s-=3),Ob(a)}}}function Mb(){function t(m){m.canIntercept&&m.info==="react-transition"&&m.intercept({handler:function(){return new Promise(function(k){return d=k})},focusReset:"manual",scroll:"manual"})}function n(){d!==null&&(d(),d=null),s||setTimeout(a,20)}function a(){if(!s&&!navigation.transition){var m=navigation.currentEntry;m&&m.url!=null&&navigation.navigate(m.url,{state:m.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var s=!1,d=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",n),navigation.addEventListener("navigateerror",n),setTimeout(a,100),function(){s=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",n),navigation.removeEventListener("navigateerror",n),d!==null&&(d(),d=null)}}}function Df(t){this._internalRoot=t}xs.prototype.render=Df.prototype.render=function(t){var n=this._internalRoot;if(n===null)throw Error(l(409));var a=n.current,s=yn();Nb(a,s,t,n,null,null)},xs.prototype.unmount=Df.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var n=t.containerInfo;Nb(t.current,2,null,t,null,null),Wo(),n[rr]=null}};function xs(t){this._internalRoot=t}xs.prototype.unstable_scheduleHydration=function(t){if(t){var n=lo();t={blockedOn:null,target:t,priority:n};for(var a=0;a<Wr.length&&n!==0&&n<Wr[a].priority;a++);Wr.splice(a,0,t),a===0&&Lb(t)}};var zb=r.version;if(zb!=="19.2.4")throw Error(l(527,zb,"19.2.4"));X.findDOMNode=function(t){var n=t._reactInternals;if(n===void 0)throw typeof t.render=="function"?Error(l(188)):(t=Object.keys(t).join(","),Error(l(268,t)));return t=p(n),t=t!==null?g(t):null,t=t===null?null:t.stateNode,t};var FS={bundleType:0,version:"19.2.4",rendererPackageName:"react-dom",currentDispatcherRef:B,reconcilerVersion:"19.2.4"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var vs=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!vs.isDisabled&&vs.supportsFiber)try{Ot=vs.inject(FS),gt=vs}catch{}}return Ra.createRoot=function(t,n){if(!o(t))throw Error(l(299));var a=!1,s="",d=$m,m=Pm,k=Vm;return n!=null&&(n.unstable_strictMode===!0&&(a=!0),n.identifierPrefix!==void 0&&(s=n.identifierPrefix),n.onUncaughtError!==void 0&&(d=n.onUncaughtError),n.onCaughtError!==void 0&&(m=n.onCaughtError),n.onRecoverableError!==void 0&&(k=n.onRecoverableError)),n=Eb(t,1,!1,null,null,a,s,null,d,m,k,Mb),t[rr]=n.current,pf(t),new Df(n)},Ra.hydrateRoot=function(t,n,a){if(!o(t))throw Error(l(299));var s=!1,d="",m=$m,k=Pm,_=Vm,P=null;return a!=null&&(a.unstable_strictMode===!0&&(s=!0),a.identifierPrefix!==void 0&&(d=a.identifierPrefix),a.onUncaughtError!==void 0&&(m=a.onUncaughtError),a.onCaughtError!==void 0&&(k=a.onCaughtError),a.onRecoverableError!==void 0&&(_=a.onRecoverableError),a.formState!==void 0&&(P=a.formState)),n=Eb(t,1,!0,n,a??null,s,d,P,m,k,_,Mb),n.context=Cb(null),a=n.current,s=yn(),s=Ui(s),d=Br(s),d.callback=null,Ir(a,d,s),a=s,n.current.lanes=a,di(n,a),Kn(n),t[rr]=n.current,pf(t),new xs(n)},Ra.version="19.2.4",Ra}var Yb;function WS(){if(Yb)return zf.exports;Yb=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(r){console.error(r)}}return e(),zf.exports=JS(),zf.exports}var e2=WS();const t2=lu(e2),Wx=["shift","alt","meta","mod","ctrl","control"],n2={esc:"escape",return:"enter",left:"arrowleft",right:"arrowright",up:"arrowup",down:"arrowdown",ShiftLeft:"shift",ShiftRight:"shift",AltLeft:"alt",AltRight:"alt",MetaLeft:"meta",MetaRight:"meta",OSLeft:"meta",OSRight:"meta",ControlLeft:"ctrl",ControlRight:"ctrl"};function oi(e){return(n2[e.trim()]||e.trim()).toLowerCase().replace(/key|digit|numpad/,"")}function e1(e){return Wx.includes(e)}function Uf(e,r=","){return e.toLowerCase().split(r)}function Hf(e,r="+",i=">",l=!1,o,u){let c=[],f=!1;e=e.trim(),e.includes(i)?(f=!0,c=e.toLocaleLowerCase().split(i).map(g=>oi(g))):c=e.toLocaleLowerCase().split(r).map(g=>oi(g));const h={alt:c.includes("alt"),ctrl:c.includes("ctrl")||c.includes("control"),shift:c.includes("shift"),meta:c.includes("meta"),mod:c.includes("mod"),useKey:l},p=c.filter(g=>!Wx.includes(g));return{...h,keys:p,description:o,isSequence:f,hotkey:e,metadata:u}}typeof document<"u"&&(document.addEventListener("keydown",e=>{e.code!==void 0&&t1([oi(e.code)])}),document.addEventListener("keyup",e=>{e.code!==void 0&&n1([oi(e.code)])})),typeof window<"u"&&(window.addEventListener("blur",()=>{kr.clear()}),window.addEventListener("contextmenu",()=>{setTimeout(()=>{kr.clear()},0)}));const kr=new Set;function gh(e){return Array.isArray(e)}function r2(e,r=","){return(gh(e)?e:e.split(r)).every(i=>kr.has(i.trim().toLowerCase()))}function t1(e){const r=Array.isArray(e)?e:[e];kr.has("meta")&&kr.forEach(i=>{e1(i)||kr.delete(i.toLowerCase())}),r.forEach(i=>{kr.add(i.toLowerCase())})}function n1(e){const r=Array.isArray(e)?e:[e];e==="meta"?kr.clear():r.forEach(i=>{kr.delete(i.toLowerCase())})}function i2(e,r,i){(typeof i=="function"&&i(e,r)||i===!0)&&e.preventDefault()}function l2(e,r,i){return typeof i=="function"?i(e,r):i===!0||i===void 0}const a2=["input","textarea","select","searchbox","slider","spinbutton","menuitem","menuitemcheckbox","menuitemradio","option","radio","textbox"];function o2(e){return r1(e,a2)}function r1(e,r=!1){const{target:i,composed:l}=e;let o,u;return s2(i)&&l?(o=e.composedPath()[0]&&e.composedPath()[0].tagName,u=e.composedPath()[0]&&e.composedPath()[0].role):(o=i&&i.tagName,u=i&&i.role),gh(r)?!!(o&&r&&r.some(c=>c.toLowerCase()===o.toLowerCase()||c===u)):!!(o&&r&&r)}function s2(e){return!!e.tagName&&!e.tagName.startsWith("-")&&e.tagName.includes("-")}function u2(e,r){return e.length===0&&r?!1:r?e.some(i=>r.includes(i))||e.includes("*"):!0}const c2=(e,r,i=!1)=>{const{alt:l,meta:o,mod:u,shift:c,ctrl:f,keys:h,useKey:p}=r,{code:g,key:b,ctrlKey:v,metaKey:x,shiftKey:S,altKey:w}=e,N=oi(g);if(p&&h?.length===1&&h.includes(b.toLowerCase()))return!0;if(!h?.includes(N)&&!["ctrl","control","unknown","meta","alt","shift","os"].includes(N))return!1;if(!i){if(l!==w&&N!=="alt"||c!==S&&N!=="shift")return!1;if(u){if(!x&&!v)return!1}else if(o!==x&&N!=="meta"&&N!=="os"||f!==v&&N!=="ctrl"&&N!=="control")return!1}return h&&h.length===1&&h.includes(N)?!0:h&&h.length>0?h.includes(N)?r2(h):!1:!h||h.length===0},i1=A.createContext(void 0),f2=()=>A.useContext(i1);function d2({addHotkey:e,removeHotkey:r,children:i}){return y.jsx(i1.Provider,{value:{addHotkey:e,removeHotkey:r},children:i})}function bh(e,r){return e&&r&&typeof e=="object"&&typeof r=="object"?Object.keys(e).length===Object.keys(r).length&&Object.keys(e).reduce((i,l)=>i&&bh(e[l],r[l]),!0):e===r}const l1=A.createContext({hotkeys:[],activeScopes:[],toggleScope:()=>{},enableScope:()=>{},disableScope:()=>{}}),Za=()=>A.useContext(l1),h2=({initiallyActiveScopes:e=["*"],children:r})=>{const[i,l]=A.useState(e),[o,u]=A.useState([]),c=A.useCallback(b=>{l(v=>v.includes("*")?[b]:Array.from(new Set([...v,b])))},[]),f=A.useCallback(b=>{l(v=>v.filter(x=>x!==b))},[]),h=A.useCallback(b=>{l(v=>v.includes(b)?v.filter(x=>x!==b):v.includes("*")?[b]:Array.from(new Set([...v,b])))},[]),p=A.useCallback(b=>{u(v=>[...v,b])},[]),g=A.useCallback(b=>{u(v=>v.filter(x=>!bh(x,b)))},[]);return y.jsx(l1.Provider,{value:{activeScopes:i,hotkeys:o,enableScope:c,disableScope:f,toggleScope:h},children:y.jsx(d2,{addHotkey:p,removeHotkey:g,children:r})})};function p2(e){const r=A.useRef(void 0);return bh(r.current,e)||(r.current=e),r.current}const Xb=e=>{e.stopPropagation(),e.preventDefault(),e.stopImmediatePropagation()},m2=typeof window<"u"?A.useLayoutEffect:A.useEffect;function lt(e,r,i,l){const o=A.useRef(null),u=A.useRef(!1),c=Array.isArray(i)?Array.isArray(l)?void 0:l:i,f=gh(e)?e.join(c?.delimiter):e,h=Array.isArray(i)?i:Array.isArray(l)?l:void 0,p=A.useCallback(r,h??[]),g=A.useRef(p);h?g.current=p:g.current=r;const b=p2(c),{activeScopes:v}=Za(),x=f2();return m2(()=>{if(b?.enabled===!1||!u2(v,b?.scopes))return;let S=[],w;const N=(z,I=!1)=>{if(!(o2(z)&&!r1(z,b?.enableOnFormTags))){if(o.current!==null){const L=o.current.getRootNode();if((L instanceof Document||L instanceof ShadowRoot)&&L.activeElement!==o.current&&!o.current.contains(L.activeElement)){Xb(z);return}}z.target?.isContentEditable&&!b?.enableOnContentEditable||Uf(f,b?.delimiter).forEach(L=>{if(L.includes(b?.splitKey??"+")&&L.includes(b?.sequenceSplitKey??">")){console.warn(`Hotkey ${L} contains both ${b?.splitKey??"+"} and ${b?.sequenceSplitKey??">"} which is not supported.`);return}const O=Hf(L,b?.splitKey,b?.sequenceSplitKey,b?.useKey,b?.description,b?.metadata);if(O.isSequence){w=setTimeout(()=>{S=[]},b?.sequenceTimeoutMs??1e3);const Z=O.useKey?z.key:oi(z.code);if(e1(Z.toLowerCase()))return;S.push(Z);const $=O.keys?.[S.length-1];if(Z!==$){S=[],w&&clearTimeout(w);return}S.length===O.keys?.length&&(g.current(z,O),w&&clearTimeout(w),S=[])}else if(c2(z,O,b?.ignoreModifiers)||O.keys?.includes("*")){if(b?.ignoreEventWhen?.(z)||I&&u.current)return;if(i2(z,O,b?.preventDefault),!l2(z,O,b?.enabled)){Xb(z);return}g.current(z,O),I||(u.current=!0)}})}},E=z=>{z.code!==void 0&&(t1(oi(z.code)),(b?.keydown===void 0&&b?.keyup!==!0||b?.keydown)&&N(z))},C=z=>{z.code!==void 0&&(n1(oi(z.code)),u.current=!1,b?.keyup&&N(z,!0))},j=o.current||c?.document||document;return j.addEventListener("keyup",C,c?.eventListenerOptions),j.addEventListener("keydown",E,c?.eventListenerOptions),x&&Uf(f,b?.delimiter).forEach(z=>{x.addHotkey(Hf(z,b?.splitKey,b?.sequenceSplitKey,b?.useKey,b?.description,b?.metadata))}),()=>{j.removeEventListener("keyup",C,c?.eventListenerOptions),j.removeEventListener("keydown",E,c?.eventListenerOptions),x&&Uf(f,b?.delimiter).forEach(z=>{x.removeHotkey(Hf(z,b?.splitKey,b?.sequenceSplitKey,b?.useKey,b?.description,b?.metadata))}),S=[],w&&clearTimeout(w)}},[f,b,v]),o}const a1=(...e)=>e.filter((r,i,l)=>!!r&&r.trim()!==""&&l.indexOf(r)===i).join(" ").trim();const g2=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();const b2=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(r,i,l)=>l?l.toUpperCase():i.toLowerCase());const Zb=e=>{const r=b2(e);return r.charAt(0).toUpperCase()+r.slice(1)};var y2={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const x2=e=>{for(const r in e)if(r.startsWith("aria-")||r==="role"||r==="title")return!0;return!1};const v2=A.forwardRef(({color:e="currentColor",size:r=24,strokeWidth:i=2,absoluteStrokeWidth:l,className:o="",children:u,iconNode:c,...f},h)=>A.createElement("svg",{ref:h,...y2,width:r,height:r,stroke:e,strokeWidth:l?Number(i)*24/Number(r):i,className:a1("lucide",o),...!u&&!x2(f)&&{"aria-hidden":"true"},...f},[...c.map(([p,g])=>A.createElement(p,g)),...Array.isArray(u)?u:[u]]));const $e=(e,r)=>{const i=A.forwardRef(({className:l,...o},u)=>A.createElement(v2,{ref:u,iconNode:r,className:a1(`lucide-${g2(Zb(e))}`,`lucide-${e}`,l),...o}));return i.displayName=Zb(e),i};const w2=[["path",{d:"M19 3H5",key:"1236rx"}],["path",{d:"M12 21V7",key:"gj6g52"}],["path",{d:"m6 15 6 6 6-6",key:"h15q88"}]],S2=$e("arrow-down-from-line",w2);const k2=[["path",{d:"m18 9-6-6-6 6",key:"kcunyi"}],["path",{d:"M12 3v14",key:"7cf3v8"}],["path",{d:"M5 21h14",key:"11awu3"}]],E2=$e("arrow-up-from-line",k2);const C2=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],Pa=$e("check",C2);const N2=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],_l=$e("chevron-down",N2);const A2=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],T2=$e("chevron-left",A2);const j2=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],o1=$e("chevron-right",j2);const R2=[["path",{d:"m7 20 5-5 5 5",key:"13a0gw"}],["path",{d:"m7 4 5 5 5-5",key:"1kwcof"}]],_2=$e("chevrons-down-up",R2);const L2=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],D2=$e("chevrons-up-down",L2);const O2=[["path",{d:"m16 18 6-6-6-6",key:"eg8j8"}],["path",{d:"m8 6-6 6 6 6",key:"ppft3o"}]],M2=$e("code",O2);const z2=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M12 3v18",key:"108xh3"}]],F2=$e("columns-2",z2);const B2=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],s1=$e("copy",B2);const I2=[["path",{d:"M21 21H8a2 2 0 0 1-1.42-.587l-3.994-3.999a2 2 0 0 1 0-2.828l10-10a2 2 0 0 1 2.829 0l5.999 6a2 2 0 0 1 0 2.828L12.834 21",key:"g5wo59"}],["path",{d:"m5.082 11.09 8.828 8.828",key:"1wx5vj"}]],U2=$e("eraser",I2);const H2=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],q2=$e("external-link",H2);const $2=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],zs=$e("eye",$2);const P2=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M9 10h6",key:"9gxzsh"}],["path",{d:"M12 13V7",key:"h0r20n"}],["path",{d:"M9 17h6",key:"r8uit2"}]],au=$e("file-diff",P2);const V2=[["path",{d:"M12.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v9.34",key:"o6klzx"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10.378 12.622a1 1 0 0 1 3 3.003L8.36 20.637a2 2 0 0 1-.854.506l-2.867.837a.5.5 0 0 1-.62-.62l.836-2.869a2 2 0 0 1 .506-.853z",key:"zhnas1"}]],u1=$e("file-pen",V2);const G2=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M9 15h6",key:"cctwl0"}],["path",{d:"M12 18v-6",key:"17g6i2"}]],c1=$e("file-plus",G2);const Y2=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"m14.5 12.5-5 5",key:"b62r18"}],["path",{d:"m9.5 12.5 5 5",key:"1rk7el"}]],f1=$e("file-x",Y2);const X2=[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]],Z2=$e("folder-open",X2);const K2=[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]],Q2=$e("folder",K2);const J2=[["path",{d:"M15 6a9 9 0 0 0-9 9V3",key:"1cii5b"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}]],W2=$e("git-branch",J2);const ek=[["path",{d:"M10 8h.01",key:"1r9ogq"}],["path",{d:"M12 12h.01",key:"1mp3jc"}],["path",{d:"M14 8h.01",key:"1primd"}],["path",{d:"M16 12h.01",key:"1l6xoz"}],["path",{d:"M18 8h.01",key:"emo2bl"}],["path",{d:"M6 8h.01",key:"x9i8wu"}],["path",{d:"M7 16h10",key:"wp8him"}],["path",{d:"M8 12h.01",key:"czm47f"}],["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}]],tk=$e("keyboard",ek);const nk=[["path",{d:"M3 5h.01",key:"18ugdj"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 19h.01",key:"noohij"}],["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 19h13",key:"m83p4d"}]],rk=$e("list",nk);const ik=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],lk=$e("loader-circle",ik);const ak=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]],d1=$e("message-square",ak);const ok=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"m16 15-3-3 3-3",key:"14y99z"}]],sk=$e("panel-left-close",ok);const uk=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]],ck=$e("panel-left",uk);const fk=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]],dk=$e("pen",fk);const hk=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],pk=$e("refresh-cw",hk);const mk=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],gk=$e("search",mk);const bk=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],h1=$e("settings",bk);const yk=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]],xk=$e("square",yk);const vk=[["path",{d:"M21 5H3",key:"1fi0y6"}],["path",{d:"M15 12H3",key:"6jk70r"}],["path",{d:"M17 19H3",key:"z6ezky"}]],wk=$e("text-align-start",vk);const Sk=[["path",{d:"M12 22v-6",key:"6o8u61"}],["path",{d:"M12 8V2",key:"1wkif3"}],["path",{d:"M4 12H2",key:"rhcxmi"}],["path",{d:"M10 12H8",key:"s88cx1"}],["path",{d:"M16 12h-2",key:"10asgb"}],["path",{d:"M22 12h-2",key:"14jgyd"}],["path",{d:"m15 19-3 3-3-3",key:"11eu04"}],["path",{d:"m15 5-3-3-3 3",key:"itvq4r"}]],kk=$e("unfold-vertical",Sk);const Ek=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],ou=$e("x",Ek),Ka="split";function Ck(e){switch(e){case"split":case"side-by-side":return"split";case"unified":case"inline":return"unified";default:return Ka}}function p1({checked:e,onChange:r,label:i,className:l="",title:o}){const u=f=>{f.stopPropagation(),r(!e)},c=f=>{(f.key==="Enter"||f.key===" ")&&(f.preventDefault(),f.stopPropagation(),r(!e))};return y.jsxs("div",{className:`flex items-center gap-2 text-xs text-github-text-primary cursor-pointer ${l}`,title:o,onClick:u,onKeyDown:c,role:"checkbox","aria-checked":e,tabIndex:0,children:[y.jsx("div",{className:`w-4 h-4 rounded border flex items-center justify-center transition-all duration-200 cursor-pointer ${e?"bg-github-accent border-github-accent":"bg-github-bg-tertiary border-github-text-muted hover:border-github-accent/50"}`,children:e&&y.jsx(Pa,{size:10,className:"text-white"})}),i&&y.jsx("span",{className:"select-none",children:i})]})}function Kb({commentsCount:e,isCopiedAll:r,onCopyAll:i,onDeleteAll:l,onViewAll:o,direction:u="down",compact:c=!1}){const[f,h]=A.useState(!1),p=A.useRef(null),g=c,b=u==="up";A.useEffect(()=>{const N=E=>{p.current&&!p.current.contains(E.target)&&h(!1)};return document.addEventListener("mousedown",N),()=>document.removeEventListener("mousedown",N)},[]);const v=()=>{i(),h(!1)},x=()=>{l(),h(!1)},S=()=>{o?.(),h(!1)},w=g?r?"Copied":`Copy All (${e})`:r?"Copied All!":`Copy All Prompt (${e})`;return y.jsxs("div",{className:"relative",ref:p,children:[y.jsxs("div",{className:"flex",children:[y.jsxs("button",{onClick:v,className:`text-xs px-3 py-1.5 pr-2 rounded-l transition-all flex items-center gap-1.5 ${g?"whitespace-normal":"whitespace-nowrap"}`,style:{backgroundColor:"var(--color-yellow-btn-bg)",color:"var(--color-yellow-btn-text)",border:"1px solid var(--color-yellow-btn-border)",borderRight:"none"},onMouseEnter:N=>{N.currentTarget.style.backgroundColor="var(--color-yellow-btn-hover-bg)",N.currentTarget.style.borderColor="var(--color-yellow-btn-hover-border)"},onMouseLeave:N=>{N.currentTarget.style.backgroundColor="var(--color-yellow-btn-bg)",N.currentTarget.style.borderColor="var(--color-yellow-btn-border)"},title:`Copy all ${e} comments to AI coding agent`,children:[r?y.jsx(Pa,{size:12}):y.jsx(s1,{size:12}),w]}),y.jsx("button",{onClick:()=>h(!f),className:"text-xs px-2 py-1.5 rounded-r transition-all flex items-center border-l",style:{backgroundColor:"var(--color-yellow-btn-bg)",color:"var(--color-yellow-btn-text)",borderTop:"1px solid var(--color-yellow-btn-border)",borderRight:"1px solid var(--color-yellow-btn-border)",borderBottom:"1px solid var(--color-yellow-btn-border)",borderLeft:"1px solid var(--color-yellow-btn-border)"},onMouseEnter:N=>{N.currentTarget.style.backgroundColor="var(--color-yellow-btn-hover-bg)",N.currentTarget.style.borderColor="var(--color-yellow-btn-hover-border)"},onMouseLeave:N=>{N.currentTarget.style.backgroundColor="var(--color-yellow-btn-bg)",N.currentTarget.style.borderColor="var(--color-yellow-btn-border)"},title:"More options",children:y.jsx(_l,{size:12,className:`transition-transform duration-200 ${f?"rotate-180":""}`})})]}),f&&y.jsxs("div",{className:`absolute left-0 right-0 bg-github-bg-primary border border-github-border z-50 pb-px ${b?"bottom-full rounded-t":"top-full rounded-b"}`,style:{borderTop:b?void 0:"none",borderBottom:b?"none":void 0},children:[o&&y.jsxs("button",{onClick:S,className:"w-full text-left px-3 py-2 text-xs flex items-center gap-2 text-github-text-primary hover:bg-github-bg-tertiary transition-colors",disabled:e===0,children:[y.jsx(rk,{size:12}),"View All Comments"]}),y.jsxs("button",{onClick:x,className:"w-full text-left px-3 py-2 text-xs flex items-center gap-2 text-github-text-primary hover:bg-github-bg-tertiary transition-colors",children:[y.jsx(U2,{size:12}),"Cleanup All Prompt"]})]})]})}function m1(e){return/```suggestion\n([\s\S]*?)```/.test(e)}function g1(e){const r=[],i=/```suggestion\n([\s\S]*?)```/g;let l;for(;(l=i.exec(e))!==null;)r.push({suggestedCode:l[1].replace(/\n$/,""),startIndex:l.index,endIndex:l.index+l[0].length});return r}function Nk(e){return`\`\`\`suggestion
|
|
10
|
+
${e.endsWith(`
|
|
11
|
+
`)?e:e+`
|
|
12
|
+
`}\`\`\``}const Ak=2,Tk=100;function jk(e){return!(e.length<Ak||e.length>Tk)}function Qb(e){return e.toLowerCase()}function Jb(e){const r=e.trim();return r?r.match(/^\w+$/)!==null&&jk(r):!1}const Rk=200,b1=A.createContext(void 0);function _k({children:e}){const[r,i]=A.useState(null),l=A.useRef(null),o=A.useCallback(()=>{l.current&&(clearTimeout(l.current),l.current=null)},[]),u=A.useCallback(p=>{const g=p.target;if(!g.classList.contains("word-token"))return;o();const b=g.getAttribute("data-word");b&&(l.current=setTimeout(()=>{i(b)},Rk))},[o]),c=A.useCallback(()=>{o(),i(null)},[o]),f=A.useCallback(p=>r?Qb(p)===Qb(r):!1,[r]);A.useEffect(()=>()=>{l.current&&clearTimeout(l.current)},[]);const h=A.useMemo(()=>({highlightedWord:r,handleMouseOver:u,handleMouseOut:c,isWordHighlighted:f}),[r,u,c,f]);return y.jsx(b1.Provider,{value:h,children:e})}function Lk(){const e=A.useContext(b1);if(!e)throw new Error("useWordHighlight must be used within a WordHighlightProvider");return e}function y1(e){var r,i,l="";if(typeof e=="string"||typeof e=="number")l+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(r=0;r<o;r++)e[r]&&(i=y1(e[r]))&&(l&&(l+=" "),l+=i)}else for(i in e)e[i]&&(l&&(l+=" "),l+=i);return l}function x1(){for(var e,r,i=0,l="",o=arguments.length;i<o;i++)(e=arguments[i])&&(r=y1(e))&&(l&&(l+=" "),l+=r);return l}var Dk=Object.create,su=Object.defineProperty,Ok=Object.defineProperties,Mk=Object.getOwnPropertyDescriptor,zk=Object.getOwnPropertyDescriptors,v1=Object.getOwnPropertyNames,Fs=Object.getOwnPropertySymbols,Fk=Object.getPrototypeOf,yh=Object.prototype.hasOwnProperty,w1=Object.prototype.propertyIsEnumerable,Wb=(e,r,i)=>r in e?su(e,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[r]=i,Jn=(e,r)=>{for(var i in r||(r={}))yh.call(r,i)&&Wb(e,i,r[i]);if(Fs)for(var i of Fs(r))w1.call(r,i)&&Wb(e,i,r[i]);return e},uu=(e,r)=>Ok(e,zk(r)),S1=(e,r)=>{var i={};for(var l in e)yh.call(e,l)&&r.indexOf(l)<0&&(i[l]=e[l]);if(e!=null&&Fs)for(var l of Fs(e))r.indexOf(l)<0&&w1.call(e,l)&&(i[l]=e[l]);return i},Bk=(e,r)=>function(){return r||(0,e[v1(e)[0]])((r={exports:{}}).exports,r),r.exports},Ik=(e,r)=>{for(var i in r)su(e,i,{get:r[i],enumerable:!0})},Uk=(e,r,i,l)=>{if(r&&typeof r=="object"||typeof r=="function")for(let o of v1(r))!yh.call(e,o)&&o!==i&&su(e,o,{get:()=>r[o],enumerable:!(l=Mk(r,o))||l.enumerable});return e},Hk=(e,r,i)=>(i=e!=null?Dk(Fk(e)):{},Uk(!e||!e.__esModule?su(i,"default",{value:e,enumerable:!0}):i,e)),qk=Bk({"../../node_modules/.pnpm/prismjs@1.29.0_patch_hash=vrxx3pzkik6jpmgpayxfjunetu/node_modules/prismjs/prism.js"(e,r){var i=(function(){var l=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,o=0,u={},c={util:{encode:function S(w){return w instanceof f?new f(w.type,S(w.content),w.alias):Array.isArray(w)?w.map(S):w.replace(/&/g,"&").replace(/</g,"<").replace(/\u00a0/g," ")},type:function(S){return Object.prototype.toString.call(S).slice(8,-1)},objId:function(S){return S.__id||Object.defineProperty(S,"__id",{value:++o}),S.__id},clone:function S(w,N){N=N||{};var E,C;switch(c.util.type(w)){case"Object":if(C=c.util.objId(w),N[C])return N[C];E={},N[C]=E;for(var j in w)w.hasOwnProperty(j)&&(E[j]=S(w[j],N));return E;case"Array":return C=c.util.objId(w),N[C]?N[C]:(E=[],N[C]=E,w.forEach(function(z,I){E[I]=S(z,N)}),E);default:return w}},getLanguage:function(S){for(;S;){var w=l.exec(S.className);if(w)return w[1].toLowerCase();S=S.parentElement}return"none"},setLanguage:function(S,w){S.className=S.className.replace(RegExp(l,"gi"),""),S.classList.add("language-"+w)},isActive:function(S,w,N){for(var E="no-"+w;S;){var C=S.classList;if(C.contains(w))return!0;if(C.contains(E))return!1;S=S.parentElement}return!!N}},languages:{plain:u,plaintext:u,text:u,txt:u,extend:function(S,w){var N=c.util.clone(c.languages[S]);for(var E in w)N[E]=w[E];return N},insertBefore:function(S,w,N,E){E=E||c.languages;var C=E[S],j={};for(var z in C)if(C.hasOwnProperty(z)){if(z==w)for(var I in N)N.hasOwnProperty(I)&&(j[I]=N[I]);N.hasOwnProperty(z)||(j[z]=C[z])}var L=E[S];return E[S]=j,c.languages.DFS(c.languages,function(O,Z){Z===L&&O!=S&&(this[O]=j)}),j},DFS:function S(w,N,E,C){C=C||{};var j=c.util.objId;for(var z in w)if(w.hasOwnProperty(z)){N.call(w,z,w[z],E||z);var I=w[z],L=c.util.type(I);L==="Object"&&!C[j(I)]?(C[j(I)]=!0,S(I,N,null,C)):L==="Array"&&!C[j(I)]&&(C[j(I)]=!0,S(I,N,z,C))}}},plugins:{},highlight:function(S,w,N){var E={code:S,grammar:w,language:N};if(c.hooks.run("before-tokenize",E),!E.grammar)throw new Error('The language "'+E.language+'" has no grammar.');return E.tokens=c.tokenize(E.code,E.grammar),c.hooks.run("after-tokenize",E),f.stringify(c.util.encode(E.tokens),E.language)},tokenize:function(S,w){var N=w.rest;if(N){for(var E in N)w[E]=N[E];delete w.rest}var C=new g;return b(C,C.head,S),p(S,C,w,C.head,0),x(C)},hooks:{all:{},add:function(S,w){var N=c.hooks.all;N[S]=N[S]||[],N[S].push(w)},run:function(S,w){var N=c.hooks.all[S];if(!(!N||!N.length))for(var E=0,C;C=N[E++];)C(w)}},Token:f};function f(S,w,N,E){this.type=S,this.content=w,this.alias=N,this.length=(E||"").length|0}f.stringify=function S(w,N){if(typeof w=="string")return w;if(Array.isArray(w)){var E="";return w.forEach(function(L){E+=S(L,N)}),E}var C={type:w.type,content:S(w.content,N),tag:"span",classes:["token",w.type],attributes:{},language:N},j=w.alias;j&&(Array.isArray(j)?Array.prototype.push.apply(C.classes,j):C.classes.push(j)),c.hooks.run("wrap",C);var z="";for(var I in C.attributes)z+=" "+I+'="'+(C.attributes[I]||"").replace(/"/g,""")+'"';return"<"+C.tag+' class="'+C.classes.join(" ")+'"'+z+">"+C.content+"</"+C.tag+">"};function h(S,w,N,E){S.lastIndex=w;var C=S.exec(N);if(C&&E&&C[1]){var j=C[1].length;C.index+=j,C[0]=C[0].slice(j)}return C}function p(S,w,N,E,C,j){for(var z in N)if(!(!N.hasOwnProperty(z)||!N[z])){var I=N[z];I=Array.isArray(I)?I:[I];for(var L=0;L<I.length;++L){if(j&&j.cause==z+","+L)return;var O=I[L],Z=O.inside,$=!!O.lookbehind,F=!!O.greedy,H=O.alias;if(F&&!O.pattern.global){var G=O.pattern.toString().match(/[imsuy]*$/)[0];O.pattern=RegExp(O.pattern.source,G+"g")}for(var Q=O.pattern||O,U=E.next,Y=C;U!==w.tail&&!(j&&Y>=j.reach);Y+=U.value.length,U=U.next){var B=U.value;if(w.length>S.length)return;if(!(B instanceof f)){var X=1,M;if(F){if(M=h(Q,Y,S,$),!M||M.index>=S.length)break;var q=M.index,V=M.index+M[0].length,R=Y;for(R+=U.value.length;q>=R;)U=U.next,R+=U.value.length;if(R-=U.value.length,Y=R,U.value instanceof f)continue;for(var D=U;D!==w.tail&&(R<V||typeof D.value=="string");D=D.next)X++,R+=D.value.length;X--,B=S.slice(Y,R),M.index-=Y}else if(M=h(Q,0,B,$),!M)continue;var q=M.index,T=M[0],te=B.slice(0,q),ie=B.slice(q+T.length),fe=Y+B.length;j&&fe>j.reach&&(j.reach=fe);var ge=U.prev;te&&(ge=b(w,ge,te),Y+=te.length),v(w,ge,X);var ye=new f(z,Z?c.tokenize(T,Z):T,H,T);if(U=b(w,ge,ye),ie&&b(w,U,ie),X>1){var pe={cause:z+","+L,reach:fe};p(S,w,N,U.prev,Y,pe),j&&pe.reach>j.reach&&(j.reach=pe.reach)}}}}}}function g(){var S={value:null,prev:null,next:null},w={value:null,prev:S,next:null};S.next=w,this.head=S,this.tail=w,this.length=0}function b(S,w,N){var E=w.next,C={value:N,prev:w,next:E};return w.next=C,E.prev=C,S.length++,C}function v(S,w,N){for(var E=w.next,C=0;C<N&&E!==S.tail;C++)E=E.next;w.next=E,E.prev=w,S.length-=C}function x(S){for(var w=[],N=S.head.next;N!==S.tail;)w.push(N.value),N=N.next;return w}return c})();r.exports=i,i.default=i}}),ue=Hk(qk());ue.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},ue.languages.markup.tag.inside["attr-value"].inside.entity=ue.languages.markup.entity,ue.languages.markup.doctype.inside["internal-subset"].inside=ue.languages.markup,ue.hooks.add("wrap",function(e){e.type==="entity"&&(e.attributes.title=e.content.replace(/&/,"&"))}),Object.defineProperty(ue.languages.markup.tag,"addInlined",{value:function(e,l){var i={},i=(i["language-"+l]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:ue.languages[l]},i.cdata=/^<!\[CDATA\[|\]\]>$/i,{"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:i}}),l=(i["language-"+l]={pattern:/[\s\S]+/,inside:ue.languages[l]},{});l[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:i},ue.languages.insertBefore("markup","cdata",l)}}),Object.defineProperty(ue.languages.markup.tag,"addAttribute",{value:function(e,r){ue.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[r,"language-"+r],inside:ue.languages[r]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),ue.languages.html=ue.languages.markup,ue.languages.mathml=ue.languages.markup,ue.languages.svg=ue.languages.markup,ue.languages.xml=ue.languages.extend("markup",{}),ue.languages.ssml=ue.languages.xml,ue.languages.atom=ue.languages.xml,ue.languages.rss=ue.languages.xml,(function(e){var r={pattern:/\\[\\(){}[\]^$+*?|.]/,alias:"escape"},i=/\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,l="(?:[^\\\\-]|"+i.source+")",l=RegExp(l+"-"+l),o={pattern:/(<|')[^<>']+(?=[>']$)/,lookbehind:!0,alias:"variable"};e.languages.regex={"char-class":{pattern:/((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/,lookbehind:!0,inside:{"char-class-negation":{pattern:/(^\[)\^/,lookbehind:!0,alias:"operator"},"char-class-punctuation":{pattern:/^\[|\]$/,alias:"punctuation"},range:{pattern:l,inside:{escape:i,"range-punctuation":{pattern:/-/,alias:"operator"}}},"special-escape":r,"char-set":{pattern:/\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},escape:i}},"special-escape":r,"char-set":{pattern:/\.|\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},backreference:[{pattern:/\\(?![123][0-7]{2})[1-9]/,alias:"keyword"},{pattern:/\\k<[^<>']+>/,alias:"keyword",inside:{"group-name":o}}],anchor:{pattern:/[$^]|\\[ABbGZz]/,alias:"function"},escape:i,group:[{pattern:/\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|<?[=!]|[idmnsuxU]+(?:-[idmnsuxU]+)?:?))?/,alias:"punctuation",inside:{"group-name":o}},{pattern:/\)/,alias:"punctuation"}],quantifier:{pattern:/(?:[+*?]|\{\d+(?:,\d*)?\})[?+]?/,alias:"number"},alternation:{pattern:/\|/,alias:"keyword"}}})(ue),ue.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},ue.languages.javascript=ue.languages.extend("clike",{"class-name":[ue.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),ue.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,ue.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:ue.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:ue.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:ue.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:ue.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:ue.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),ue.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:ue.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),ue.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),ue.languages.markup&&(ue.languages.markup.tag.addInlined("script","javascript"),ue.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),ue.languages.js=ue.languages.javascript,ue.languages.actionscript=ue.languages.extend("javascript",{keyword:/\b(?:as|break|case|catch|class|const|default|delete|do|dynamic|each|else|extends|final|finally|for|function|get|if|implements|import|in|include|instanceof|interface|internal|is|namespace|native|new|null|override|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|use|var|void|while|with)\b/,operator:/\+\+|--|(?:[+\-*\/%^]|&&?|\|\|?|<<?|>>?>?|[!=]=?)=?|[~?@]/}),ue.languages.actionscript["class-name"].alias="function",delete ue.languages.actionscript.parameter,delete ue.languages.actionscript["literal-property"],ue.languages.markup&&ue.languages.insertBefore("actionscript","string",{xml:{pattern:/(^|[^.])<\/?\w+(?:\s+[^\s>\/=]+=("|')(?:\\[\s\S]|(?!\2)[^\\])*\2)*\s*\/?>/,lookbehind:!0,inside:ue.languages.markup}}),(function(e){var r=/#(?!\{).+/,i={pattern:/#\{[^}]+\}/,alias:"variable"};e.languages.coffeescript=e.languages.extend("javascript",{comment:r,string:[{pattern:/'(?:\\[\s\S]|[^\\'])*'/,greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,greedy:!0,inside:{interpolation:i}}],keyword:/\b(?:and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/,"class-member":{pattern:/@(?!\d)\w+/,alias:"variable"}}),e.languages.insertBefore("coffeescript","comment",{"multiline-comment":{pattern:/###[\s\S]+?###/,alias:"comment"},"block-regex":{pattern:/\/{3}[\s\S]*?\/{3}/,alias:"regex",inside:{comment:r,interpolation:i}}}),e.languages.insertBefore("coffeescript","string",{"inline-javascript":{pattern:/`(?:\\[\s\S]|[^\\`])*`/,inside:{delimiter:{pattern:/^`|`$/,alias:"punctuation"},script:{pattern:/[\s\S]+/,alias:"language-javascript",inside:e.languages.javascript}}},"multiline-string":[{pattern:/'''[\s\S]*?'''/,greedy:!0,alias:"string"},{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:"string",inside:{interpolation:i}}]}),e.languages.insertBefore("coffeescript","keyword",{property:/(?!\d)\w+(?=\s*:(?!:))/}),delete e.languages.coffeescript["template-string"],e.languages.coffee=e.languages.coffeescript})(ue),(function(e){var r=e.languages.javadoclike={parameter:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*@(?:arg|arguments|param)\s+)\w+/m,lookbehind:!0},keyword:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*|\{)@[a-z][a-zA-Z-]+\b/m,lookbehind:!0},punctuation:/[{}]/};Object.defineProperty(r,"addSupport",{value:function(i,l){(i=typeof i=="string"?[i]:i).forEach(function(o){var u=function(b){b.inside||(b.inside={}),b.inside.rest=l},c="doc-comment";if(f=e.languages[o]){var f,h=f[c];if((h=h||(f=e.languages.insertBefore(o,"comment",{"doc-comment":{pattern:/(^|[^\\])\/\*\*[^/][\s\S]*?(?:\*\/|$)/,lookbehind:!0,alias:"comment"}}))[c])instanceof RegExp&&(h=f[c]={pattern:h}),Array.isArray(h))for(var p=0,g=h.length;p<g;p++)h[p]instanceof RegExp&&(h[p]={pattern:h[p]}),u(h[p]);else u(h)}})}}),r.addSupport(["java","javascript","php"],r)})(ue),(function(e){var r=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/,r=(e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+r.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+r.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+r.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+r.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:r,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css,e.languages.markup);r&&(r.tag.addInlined("style","css"),r.tag.addAttribute("style","css"))})(ue),(function(e){var r=/("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,r=(e.languages.css.selector={pattern:e.languages.css.selector.pattern,lookbehind:!0,inside:r={"pseudo-element":/:(?:after|before|first-letter|first-line|selection)|::[-\w]+/,"pseudo-class":/:[-\w]+/,class:/\.[-\w]+/,id:/#[-\w]+/,attribute:{pattern:RegExp(`\\[(?:[^[\\]"']|`+r.source+")*\\]"),greedy:!0,inside:{punctuation:/^\[|\]$/,"case-sensitivity":{pattern:/(\s)[si]$/i,lookbehind:!0,alias:"keyword"},namespace:{pattern:/^(\s*)(?:(?!\s)[-*\w\xA0-\uFFFF])*\|(?!=)/,lookbehind:!0,inside:{punctuation:/\|$/}},"attr-name":{pattern:/^(\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+/,lookbehind:!0},"attr-value":[r,{pattern:/(=\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+(?=\s*$)/,lookbehind:!0}],operator:/[|~*^$]?=/}},"n-th":[{pattern:/(\(\s*)[+-]?\d*[\dn](?:\s*[+-]\s*\d+)?(?=\s*\))/,lookbehind:!0,inside:{number:/[\dn]+/,operator:/[+-]/}},{pattern:/(\(\s*)(?:even|odd)(?=\s*\))/i,lookbehind:!0}],combinator:/>|\+|~|\|\|/,punctuation:/[(),]/}},e.languages.css.atrule.inside["selector-function-argument"].inside=r,e.languages.insertBefore("css","property",{variable:{pattern:/(^|[^-\w\xA0-\uFFFF])--(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*/i,lookbehind:!0}}),{pattern:/(\b\d+)(?:%|[a-z]+(?![\w-]))/,lookbehind:!0}),i={pattern:/(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/,lookbehind:!0};e.languages.insertBefore("css","function",{operator:{pattern:/(\s)[+\-*\/](?=\s)/,lookbehind:!0},hexcode:{pattern:/\B#[\da-f]{3,8}\b/i,alias:"color"},color:[{pattern:/(^|[^\w-])(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|RebeccaPurple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)(?![\w-])/i,lookbehind:!0},{pattern:/\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i,inside:{unit:r,number:i,function:/[\w-]+(?=\()/,punctuation:/[(),]/}}],entity:/\\[\da-f]{1,8}/i,unit:r,number:i})})(ue),(function(e){var r=/[*&][^\s[\]{},]+/,i=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,l="(?:"+i.source+"(?:[ ]+"+r.source+")?|"+r.source+"(?:[ ]+"+i.source+")?)",o=/(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g,function(){return/[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source}),u=/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;function c(f,h){h=(h||"").replace(/m/g,"")+"m";var p=/([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g,function(){return l}).replace(/<<value>>/g,function(){return f});return RegExp(p,h)}e.languages.yaml={scalar:{pattern:RegExp(/([\-:]\s*(?:\s<<prop>>[ \t]+)?[|>])[ \t]*(?:((?:\r?\n|\r)[ \t]+)\S[^\r\n]*(?:\2[^\r\n]+)*)/.source.replace(/<<prop>>/g,function(){return l})),lookbehind:!0,alias:"string"},comment:/#.*/,key:{pattern:RegExp(/((?:^|[:\-,[{\r\n?])[ \t]*(?:<<prop>>[ \t]+)?)<<key>>(?=\s*:\s)/.source.replace(/<<prop>>/g,function(){return l}).replace(/<<key>>/g,function(){return"(?:"+o+"|"+u+")"})),lookbehind:!0,greedy:!0,alias:"atrule"},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:"important"},datetime:{pattern:c(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source),lookbehind:!0,alias:"number"},boolean:{pattern:c(/false|true/.source,"i"),lookbehind:!0,alias:"important"},null:{pattern:c(/null|~/.source,"i"),lookbehind:!0,alias:"important"},string:{pattern:c(u),lookbehind:!0,greedy:!0},number:{pattern:c(/[+-]?(?:0x[\da-f]+|0o[0-7]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|\.inf|\.nan)/.source,"i"),lookbehind:!0},tag:i,important:r,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},e.languages.yml=e.languages.yaml})(ue),(function(e){var r=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function i(p){return p=p.replace(/<inner>/g,function(){return r}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+p+")")}var l=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,o=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return l}),u=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source,c=(e.languages.markdown=e.languages.extend("markup",{}),e.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:e.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+o+u+"(?:"+o+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+o+u+")(?:"+o+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(l),inside:e.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+o+")"+u+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+o+"$"),inside:{"table-header":{pattern:RegExp(l),alias:"important",inside:e.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:i(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:i(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:i(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:i(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(p){["url","bold","italic","strike","code-snippet"].forEach(function(g){p!==g&&(e.languages.markdown[p].inside.content.inside[g]=e.languages.markdown[g])})}),e.hooks.add("after-tokenize",function(p){p.language!=="markdown"&&p.language!=="md"||(function g(b){if(b&&typeof b!="string")for(var v=0,x=b.length;v<x;v++){var S,w=b[v];w.type!=="code"?g(w.content):(S=w.content[1],w=w.content[3],S&&w&&S.type==="code-language"&&w.type==="code-block"&&typeof S.content=="string"&&(S=S.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp"),S="language-"+(S=(/[a-z][\w-]*/i.exec(S)||[""])[0].toLowerCase()),w.alias?typeof w.alias=="string"?w.alias=[w.alias,S]:w.alias.push(S):w.alias=[S]))}})(p.tokens)}),e.hooks.add("wrap",function(p){if(p.type==="code-block"){for(var g="",b=0,v=p.classes.length;b<v;b++){var x=p.classes[b],x=/language-(.+)/.exec(x);if(x){g=x[1];break}}var S,w=e.languages[g];w?p.content=e.highlight((function(N){return N=N.replace(c,""),N=N.replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi,function(E,C){var j;return(C=C.toLowerCase())[0]==="#"?(j=C[1]==="x"?parseInt(C.slice(2),16):Number(C.slice(1)),h(j)):f[C]||E})})(p.content),w,g):g&&g!=="none"&&e.plugins.autoloader&&(S="md-"+new Date().valueOf()+"-"+Math.floor(1e16*Math.random()),p.attributes.id=S,e.plugins.autoloader.loadLanguages(g,function(){var N=document.getElementById(S);N&&(N.innerHTML=e.highlight(N.textContent,e.languages[g],g))}))}}),RegExp(e.languages.markup.tag.pattern.source,"gi")),f={amp:"&",lt:"<",gt:">",quot:'"'},h=String.fromCodePoint||String.fromCharCode;e.languages.md=e.languages.markdown})(ue),ue.languages.graphql={comment:/#.*/,description:{pattern:/(?:"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*")(?=\s*[a-z_])/i,greedy:!0,alias:"string",inside:{"language-markdown":{pattern:/(^"(?:"")?)(?!\1)[\s\S]+(?=\1$)/,lookbehind:!0,inside:ue.languages.markdown}}},string:{pattern:/"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*"/,greedy:!0},number:/(?:\B-|\b)\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,boolean:/\b(?:false|true)\b/,variable:/\$[a-z_]\w*/i,directive:{pattern:/@[a-z_]\w*/i,alias:"function"},"attr-name":{pattern:/\b[a-z_]\w*(?=\s*(?:\((?:[^()"]|"(?:\\.|[^\\"\r\n])*")*\))?:)/i,greedy:!0},"atom-input":{pattern:/\b[A-Z]\w*Input\b/,alias:"class-name"},scalar:/\b(?:Boolean|Float|ID|Int|String)\b/,constant:/\b[A-Z][A-Z_\d]*\b/,"class-name":{pattern:/(\b(?:enum|implements|interface|on|scalar|type|union)\s+|&\s*|:\s*|\[)[A-Z_]\w*/,lookbehind:!0},fragment:{pattern:/(\bfragment\s+|\.{3}\s*(?!on\b))[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},"definition-mutation":{pattern:/(\bmutation\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},"definition-query":{pattern:/(\bquery\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},keyword:/\b(?:directive|enum|extend|fragment|implements|input|interface|mutation|on|query|repeatable|scalar|schema|subscription|type|union)\b/,operator:/[!=|&]|\.{3}/,"property-query":/\w+(?=\s*\()/,object:/\w+(?=\s*\{)/,punctuation:/[!(){}\[\]:=,]/,property:/\w+/},ue.hooks.add("after-tokenize",function(e){if(e.language==="graphql")for(var r=e.tokens.filter(function(S){return typeof S!="string"&&S.type!=="comment"&&S.type!=="scalar"}),i=0;i<r.length;){var l=r[i++];if(l.type==="keyword"&&l.content==="mutation"){var o=[];if(b(["definition-mutation","punctuation"])&&g(1).content==="("){i+=2;var u=v(/^\($/,/^\)$/);if(u===-1)continue;for(;i<u;i++){var c=g(0);c.type==="variable"&&(x(c,"variable-input"),o.push(c.content))}i=u+1}if(b(["punctuation","property-query"])&&g(0).content==="{"&&(i++,x(g(0),"property-mutation"),0<o.length)){var f=v(/^\{$/,/^\}$/);if(f!==-1)for(var h=i;h<f;h++){var p=r[h];p.type==="variable"&&0<=o.indexOf(p.content)&&x(p,"variable-input")}}}}function g(S){return r[i+S]}function b(S,w){w=w||0;for(var N=0;N<S.length;N++){var E=g(N+w);if(!E||E.type!==S[N])return}return 1}function v(S,w){for(var N=1,E=i;E<r.length;E++){var C=r[E],j=C.content;if(C.type==="punctuation"&&typeof j=="string"){if(S.test(j))N++;else if(w.test(j)&&--N===0)return E}}return-1}function x(S,w){var N=S.alias;N?Array.isArray(N)||(S.alias=N=[N]):S.alias=N=[],N.push(w)}}),ue.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/},(function(e){var r=e.languages.javascript["template-string"],i=r.pattern.source,l=r.inside.interpolation,o=l.inside["interpolation-punctuation"],u=l.pattern.source;function c(b,v){if(e.languages[b])return{pattern:RegExp("((?:"+v+")\\s*)"+i),lookbehind:!0,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},"embedded-code":{pattern:/[\s\S]+/,alias:b}}}}function f(b,v,x){return b={code:b,grammar:v,language:x},e.hooks.run("before-tokenize",b),b.tokens=e.tokenize(b.code,b.grammar),e.hooks.run("after-tokenize",b),b.tokens}function h(b,v,x){var N=e.tokenize(b,{interpolation:{pattern:RegExp(u),lookbehind:!0}}),S=0,w={},N=f(N.map(function(C){if(typeof C=="string")return C;for(var j,z,C=C.content;b.indexOf((z=S++,j="___"+x.toUpperCase()+"_"+z+"___"))!==-1;);return w[j]=C,j}).join(""),v,x),E=Object.keys(w);return S=0,(function C(j){for(var z=0;z<j.length;z++){if(S>=E.length)return;var I,L,O,Z,$,F,H,G=j[z];typeof G=="string"||typeof G.content=="string"?(I=E[S],(H=(F=typeof G=="string"?G:G.content).indexOf(I))!==-1&&(++S,L=F.substring(0,H),$=w[I],O=void 0,(Z={})["interpolation-punctuation"]=o,(Z=e.tokenize($,Z)).length===3&&((O=[1,1]).push.apply(O,f(Z[1],e.languages.javascript,"javascript")),Z.splice.apply(Z,O)),O=new e.Token("interpolation",Z,l.alias,$),Z=F.substring(H+I.length),$=[],L&&$.push(L),$.push(O),Z&&(C(F=[Z]),$.push.apply($,F)),typeof G=="string"?(j.splice.apply(j,[z,1].concat($)),z+=$.length-1):G.content=$)):(H=G.content,Array.isArray(H)?C(H):C([H]))}})(N),new e.Token(x,N,"language-"+x,b)}e.languages.javascript["template-string"]=[c("css",/\b(?:styled(?:\([^)]*\))?(?:\s*\.\s*\w+(?:\([^)]*\))*)*|css(?:\s*\.\s*(?:global|resolve))?|createGlobalStyle|keyframes)/.source),c("html",/\bhtml|\.\s*(?:inner|outer)HTML\s*\+?=/.source),c("svg",/\bsvg/.source),c("markdown",/\b(?:markdown|md)/.source),c("graphql",/\b(?:gql|graphql(?:\s*\.\s*experimental)?)/.source),c("sql",/\bsql/.source),r].filter(Boolean);var p={javascript:!0,js:!0,typescript:!0,ts:!0,jsx:!0,tsx:!0};function g(b){return typeof b=="string"?b:Array.isArray(b)?b.map(g).join(""):g(b.content)}e.hooks.add("after-tokenize",function(b){b.language in p&&(function v(x){for(var S=0,w=x.length;S<w;S++){var N,E,C,j=x[S];typeof j!="string"&&(N=j.content,Array.isArray(N)?j.type==="template-string"?(j=N[1],N.length===3&&typeof j!="string"&&j.type==="embedded-code"&&(E=g(j),j=j.alias,j=Array.isArray(j)?j[0]:j,C=e.languages[j])&&(N[1]=h(E,C,j))):v(N):typeof N!="string"&&v([N]))}})(b.tokens)})})(ue),(function(e){e.languages.typescript=e.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript["literal-property"];var r=e.languages.extend("typescript",{});delete r["class-name"],e.languages.typescript["class-name"].inside=r,e.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:r}}}}),e.languages.ts=e.languages.typescript})(ue),(function(e){var r=e.languages.javascript,i=/\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})+\}/.source,l="(@(?:arg|argument|param|property)\\s+(?:"+i+"\\s+)?)";e.languages.jsdoc=e.languages.extend("javadoclike",{parameter:{pattern:RegExp(l+/(?:(?!\s)[$\w\xA0-\uFFFF.])+(?=\s|$)/.source),lookbehind:!0,inside:{punctuation:/\./}}}),e.languages.insertBefore("jsdoc","keyword",{"optional-parameter":{pattern:RegExp(l+/\[(?:(?!\s)[$\w\xA0-\uFFFF.])+(?:=[^[\]]+)?\](?=\s|$)/.source),lookbehind:!0,inside:{parameter:{pattern:/(^\[)[$\w\xA0-\uFFFF\.]+/,lookbehind:!0,inside:{punctuation:/\./}},code:{pattern:/(=)[\s\S]*(?=\]$)/,lookbehind:!0,inside:r,alias:"language-javascript"},punctuation:/[=[\]]/}},"class-name":[{pattern:RegExp(/(@(?:augments|class|extends|interface|memberof!?|template|this|typedef)\s+(?:<TYPE>\s+)?)[A-Z]\w*(?:\.[A-Z]\w*)*/.source.replace(/<TYPE>/g,function(){return i})),lookbehind:!0,inside:{punctuation:/\./}},{pattern:RegExp("(@[a-z]+\\s+)"+i),lookbehind:!0,inside:{string:r.string,number:r.number,boolean:r.boolean,keyword:e.languages.typescript.keyword,operator:/=>|\.\.\.|[&|?:*]/,punctuation:/[.,;=<>{}()[\]]/}}],example:{pattern:/(@example\s+(?!\s))(?:[^@\s]|\s+(?!\s))+?(?=\s*(?:\*\s*)?(?:@\w|\*\/))/,lookbehind:!0,inside:{code:{pattern:/^([\t ]*(?:\*\s*)?)\S.*$/m,lookbehind:!0,inside:r,alias:"language-javascript"}}}}),e.languages.javadoclike.addSupport("javascript",e.languages.jsdoc)})(ue),(function(e){e.languages.flow=e.languages.extend("javascript",{}),e.languages.insertBefore("flow","keyword",{type:[{pattern:/\b(?:[Bb]oolean|Function|[Nn]umber|[Ss]tring|[Ss]ymbol|any|mixed|null|void)\b/,alias:"class-name"}]}),e.languages.flow["function-variable"].pattern=/(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=\s*(?:function\b|(?:\([^()]*\)(?:\s*:\s*\w+)?|(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/i,delete e.languages.flow.parameter,e.languages.insertBefore("flow","operator",{"flow-punctuation":{pattern:/\{\||\|\}/,alias:"punctuation"}}),Array.isArray(e.languages.flow.keyword)||(e.languages.flow.keyword=[e.languages.flow.keyword]),e.languages.flow.keyword.unshift({pattern:/(^|[^$]\b)(?:Class|declare|opaque|type)\b(?!\$)/,lookbehind:!0},{pattern:/(^|[^$]\B)\$(?:Diff|Enum|Exact|Keys|ObjMap|PropertyType|Record|Shape|Subtype|Supertype|await)\b(?!\$)/,lookbehind:!0})})(ue),ue.languages.n4js=ue.languages.extend("javascript",{keyword:/\b(?:Array|any|boolean|break|case|catch|class|const|constructor|continue|debugger|declare|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|module|new|null|number|package|private|protected|public|return|set|static|string|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/}),ue.languages.insertBefore("n4js","constant",{annotation:{pattern:/@+\w+/,alias:"operator"}}),ue.languages.n4jsd=ue.languages.n4js,(function(e){function r(c,f){return RegExp(c.replace(/<ID>/g,function(){return/(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/.source}),f)}e.languages.insertBefore("javascript","function-variable",{"method-variable":{pattern:RegExp("(\\.\\s*)"+e.languages.javascript["function-variable"].pattern.source),lookbehind:!0,alias:["function-variable","method","function","property-access"]}}),e.languages.insertBefore("javascript","function",{method:{pattern:RegExp("(\\.\\s*)"+e.languages.javascript.function.source),lookbehind:!0,alias:["function","property-access"]}}),e.languages.insertBefore("javascript","constant",{"known-class-name":[{pattern:/\b(?:(?:Float(?:32|64)|(?:Int|Uint)(?:8|16|32)|Uint8Clamped)?Array|ArrayBuffer|BigInt|Boolean|DataView|Date|Error|Function|Intl|JSON|(?:Weak)?(?:Map|Set)|Math|Number|Object|Promise|Proxy|Reflect|RegExp|String|Symbol|WebAssembly)\b/,alias:"class-name"},{pattern:/\b(?:[A-Z]\w*)Error\b/,alias:"class-name"}]}),e.languages.insertBefore("javascript","keyword",{imports:{pattern:r(/(\bimport\b\s*)(?:<ID>(?:\s*,\s*(?:\*\s*as\s+<ID>|\{[^{}]*\}))?|\*\s*as\s+<ID>|\{[^{}]*\})(?=\s*\bfrom\b)/.source),lookbehind:!0,inside:e.languages.javascript},exports:{pattern:r(/(\bexport\b\s*)(?:\*(?:\s*as\s+<ID>)?(?=\s*\bfrom\b)|\{[^{}]*\})/.source),lookbehind:!0,inside:e.languages.javascript}}),e.languages.javascript.keyword.unshift({pattern:/\b(?:as|default|export|from|import)\b/,alias:"module"},{pattern:/\b(?:await|break|catch|continue|do|else|finally|for|if|return|switch|throw|try|while|yield)\b/,alias:"control-flow"},{pattern:/\bnull\b/,alias:["null","nil"]},{pattern:/\bundefined\b/,alias:"nil"}),e.languages.insertBefore("javascript","operator",{spread:{pattern:/\.{3}/,alias:"operator"},arrow:{pattern:/=>/,alias:"operator"}}),e.languages.insertBefore("javascript","punctuation",{"property-access":{pattern:r(/(\.\s*)#?<ID>/.source),lookbehind:!0},"maybe-class-name":{pattern:/(^|[^$\w\xA0-\uFFFF])[A-Z][$\w\xA0-\uFFFF]+/,lookbehind:!0},dom:{pattern:/\b(?:document|(?:local|session)Storage|location|navigator|performance|window)\b/,alias:"variable"},console:{pattern:/\bconsole(?=\s*\.)/,alias:"class-name"}});for(var i=["function","function-variable","method","method-variable","property-access"],l=0;l<i.length;l++){var u=i[l],o=e.languages.javascript[u],u=(o=e.util.type(o)==="RegExp"?e.languages.javascript[u]={pattern:o}:o).inside||{};(o.inside=u)["maybe-class-name"]=/^[A-Z][\s\S]*/}})(ue),(function(e){var r=e.util.clone(e.languages.javascript),i=/(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source,l=/(?:\{(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])*\})/.source,o=/(?:\{<S>*\.{3}(?:[^{}]|<BRACES>)*\})/.source;function u(h,p){return h=h.replace(/<S>/g,function(){return i}).replace(/<BRACES>/g,function(){return l}).replace(/<SPREAD>/g,function(){return o}),RegExp(h,p)}o=u(o).source,e.languages.jsx=e.languages.extend("markup",r),e.languages.jsx.tag.pattern=u(/<\/?(?:[\w.:-]+(?:<S>+(?:[\w.:$-]+(?:=(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s{'"/>=]+|<BRACES>))?|<SPREAD>))*<S>*\/?)?>/.source),e.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,e.languages.jsx.tag.inside["attr-value"].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,e.languages.jsx.tag.inside.tag.inside["class-name"]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,e.languages.jsx.tag.inside.comment=r.comment,e.languages.insertBefore("inside","attr-name",{spread:{pattern:u(/<SPREAD>/.source),inside:e.languages.jsx}},e.languages.jsx.tag),e.languages.insertBefore("inside","special-attr",{script:{pattern:u(/=<BRACES>/.source),alias:"language-javascript",inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:"punctuation"},rest:e.languages.jsx}}},e.languages.jsx.tag);function c(h){for(var p=[],g=0;g<h.length;g++){var b=h[g],v=!1;typeof b!="string"&&(b.type==="tag"&&b.content[0]&&b.content[0].type==="tag"?b.content[0].content[0].content==="</"?0<p.length&&p[p.length-1].tagName===f(b.content[0].content[1])&&p.pop():b.content[b.content.length-1].content!=="/>"&&p.push({tagName:f(b.content[0].content[1]),openedBraces:0}):0<p.length&&b.type==="punctuation"&&b.content==="{"?p[p.length-1].openedBraces++:0<p.length&&0<p[p.length-1].openedBraces&&b.type==="punctuation"&&b.content==="}"?p[p.length-1].openedBraces--:v=!0),(v||typeof b=="string")&&0<p.length&&p[p.length-1].openedBraces===0&&(v=f(b),g<h.length-1&&(typeof h[g+1]=="string"||h[g+1].type==="plain-text")&&(v+=f(h[g+1]),h.splice(g+1,1)),0<g&&(typeof h[g-1]=="string"||h[g-1].type==="plain-text")&&(v=f(h[g-1])+v,h.splice(g-1,1),g--),h[g]=new e.Token("plain-text",v,null,v)),b.content&&typeof b.content!="string"&&c(b.content)}}var f=function(h){return h?typeof h=="string"?h:typeof h.content=="string"?h.content:h.content.map(f).join(""):""};e.hooks.add("after-tokenize",function(h){h.language!=="jsx"&&h.language!=="tsx"||c(h.tokens)})})(ue),(function(e){var r=e.util.clone(e.languages.typescript),r=(e.languages.tsx=e.languages.extend("jsx",r),delete e.languages.tsx.parameter,delete e.languages.tsx["literal-property"],e.languages.tsx.tag);r.pattern=RegExp(/(^|[^\w$]|(?=<\/))/.source+"(?:"+r.pattern.source+")",r.pattern.flags),r.lookbehind=!0})(ue),ue.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+/(?:elseif|if)\b/.source+"(?:[ ]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},ue.languages.swift["string-literal"].forEach(function(e){e.inside.interpolation.inside=ue.languages.swift}),(function(e){e.languages.kotlin=e.languages.extend("clike",{keyword:{pattern:/(^|[^.])\b(?:abstract|actual|annotation|as|break|by|catch|class|companion|const|constructor|continue|crossinline|data|do|dynamic|else|enum|expect|external|final|finally|for|fun|get|if|import|in|infix|init|inline|inner|interface|internal|is|lateinit|noinline|null|object|open|operator|out|override|package|private|protected|public|reified|return|sealed|set|super|suspend|tailrec|this|throw|to|try|typealias|val|var|vararg|when|where|while)\b/,lookbehind:!0},function:[{pattern:/(?:`[^\r\n`]+`|\b\w+)(?=\s*\()/,greedy:!0},{pattern:/(\.)(?:`[^\r\n`]+`|\w+)(?=\s*\{)/,lookbehind:!0,greedy:!0}],number:/\b(?:0[xX][\da-fA-F]+(?:_[\da-fA-F]+)*|0[bB][01]+(?:_[01]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?[fFL]?)\b/,operator:/\+[+=]?|-[-=>]?|==?=?|!(?:!|==?)?|[\/*%<>]=?|[?:]:?|\.\.|&&|\|\||\b(?:and|inv|or|shl|shr|ushr|xor)\b/}),delete e.languages.kotlin["class-name"];var r={"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:e.languages.kotlin}};e.languages.insertBefore("kotlin","string",{"string-literal":[{pattern:/"""(?:[^$]|\$(?:(?!\{)|\{[^{}]*\}))*?"""/,alias:"multiline",inside:{interpolation:{pattern:/\$(?:[a-z_]\w*|\{[^{}]*\})/i,inside:r},string:/[\s\S]+/}},{pattern:/"(?:[^"\\\r\n$]|\\.|\$(?:(?!\{)|\{[^{}]*\}))*"/,alias:"singleline",inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:[a-z_]\w*|\{[^{}]*\})/i,lookbehind:!0,inside:r},string:/[\s\S]+/}}],char:{pattern:/'(?:[^'\\\r\n]|\\(?:.|u[a-fA-F0-9]{0,4}))'/,greedy:!0}}),delete e.languages.kotlin.string,e.languages.insertBefore("kotlin","keyword",{annotation:{pattern:/\B@(?:\w+:)?(?:[A-Z]\w*|\[[^\]]+\])/,alias:"builtin"}}),e.languages.insertBefore("kotlin","function",{label:{pattern:/\b\w+@|@\w+\b/,alias:"symbol"}}),e.languages.kt=e.languages.kotlin,e.languages.kts=e.languages.kotlin})(ue),ue.languages.c=ue.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),ue.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),ue.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},ue.languages.c.string],char:ue.languages.c.char,comment:ue.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:ue.languages.c}}}}),ue.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete ue.languages.c.boolean,ue.languages.objectivec=ue.languages.extend("c",{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete ue.languages.objectivec["class-name"],ue.languages.objc=ue.languages.objectivec,ue.languages.reason=ue.languages.extend("clike",{string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^\\\r\n"])*"/,greedy:!0},"class-name":/\b[A-Z]\w*/,keyword:/\b(?:and|as|assert|begin|class|constraint|do|done|downto|else|end|exception|external|for|fun|function|functor|if|in|include|inherit|initializer|lazy|let|method|module|mutable|new|nonrec|object|of|open|or|private|rec|sig|struct|switch|then|to|try|type|val|virtual|when|while|with)\b/,operator:/\.{3}|:[:=]|\|>|->|=(?:==?|>)?|<=?|>=?|[|^?'#!~`]|[+\-*\/]\.?|\b(?:asr|land|lor|lsl|lsr|lxor|mod)\b/}),ue.languages.insertBefore("reason","class-name",{char:{pattern:/'(?:\\x[\da-f]{2}|\\o[0-3][0-7][0-7]|\\\d{3}|\\.|[^'\\\r\n])'/,greedy:!0},constructor:/\b[A-Z]\w*\b(?!\s*\.)/,label:{pattern:/\b[a-z]\w*(?=::)/,alias:"symbol"}}),delete ue.languages.reason.function,(function(e){for(var r=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,i=0;i<2;i++)r=r.replace(/<self>/g,function(){return r});r=r.replace(/<self>/g,function(){return/[^\s\S]/.source}),e.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+r),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},e.languages.rust["closure-params"].inside.rest=e.languages.rust,e.languages.rust.attribute.inside.string=e.languages.rust.string})(ue),ue.languages.go=ue.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),ue.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete ue.languages.go["class-name"],(function(e){var r=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,i=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return r.source});e.languages.cpp=e.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return r.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:r,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return i})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),e.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:e.languages.cpp}}}}),e.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),e.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend("cpp",{})}}),e.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp["base-clause"])})(ue),ue.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern://,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},ue.languages.python["string-interpolation"].inside.interpolation.inside.rest=ue.languages.python,ue.languages.py=ue.languages.python,ue.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},ue.languages.webmanifest=ue.languages.json;var vn={};Ik(vn,{dracula:()=>Pk,duotoneDark:()=>Gk,duotoneLight:()=>Xk,github:()=>Kk,gruvboxMaterialDark:()=>CE,gruvboxMaterialLight:()=>AE,jettwaveDark:()=>bE,jettwaveLight:()=>xE,nightOwl:()=>Jk,nightOwlLight:()=>eE,oceanicNext:()=>nE,okaidia:()=>iE,oneDark:()=>wE,oneLight:()=>kE,palenight:()=>aE,shadesOfPurple:()=>sE,synthwave84:()=>cE,ultramin:()=>dE,vsDark:()=>k1,vsLight:()=>mE});var $k={plain:{color:"#F8F8F2",backgroundColor:"#282A36"},styles:[{types:["prolog","constant","builtin"],style:{color:"rgb(189, 147, 249)"}},{types:["inserted","function"],style:{color:"rgb(80, 250, 123)"}},{types:["deleted"],style:{color:"rgb(255, 85, 85)"}},{types:["changed"],style:{color:"rgb(255, 184, 108)"}},{types:["punctuation","symbol"],style:{color:"rgb(248, 248, 242)"}},{types:["string","char","tag","selector"],style:{color:"rgb(255, 121, 198)"}},{types:["keyword","variable"],style:{color:"rgb(189, 147, 249)",fontStyle:"italic"}},{types:["comment"],style:{color:"rgb(98, 114, 164)"}},{types:["attr-name"],style:{color:"rgb(241, 250, 140)"}}]},Pk=$k,Vk={plain:{backgroundColor:"#2a2734",color:"#9a86fd"},styles:[{types:["comment","prolog","doctype","cdata","punctuation"],style:{color:"#6c6783"}},{types:["namespace"],style:{opacity:.7}},{types:["tag","operator","number"],style:{color:"#e09142"}},{types:["property","function"],style:{color:"#9a86fd"}},{types:["tag-id","selector","atrule-id"],style:{color:"#eeebff"}},{types:["attr-name"],style:{color:"#c4b9fe"}},{types:["boolean","string","entity","url","attr-value","keyword","control","directive","unit","statement","regex","atrule","placeholder","variable"],style:{color:"#ffcc99"}},{types:["deleted"],style:{textDecorationLine:"line-through"}},{types:["inserted"],style:{textDecorationLine:"underline"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["important"],style:{color:"#c4b9fe"}}]},Gk=Vk,Yk={plain:{backgroundColor:"#faf8f5",color:"#728fcb"},styles:[{types:["comment","prolog","doctype","cdata","punctuation"],style:{color:"#b6ad9a"}},{types:["namespace"],style:{opacity:.7}},{types:["tag","operator","number"],style:{color:"#063289"}},{types:["property","function"],style:{color:"#b29762"}},{types:["tag-id","selector","atrule-id"],style:{color:"#2d2006"}},{types:["attr-name"],style:{color:"#896724"}},{types:["boolean","string","entity","url","attr-value","keyword","control","directive","unit","statement","regex","atrule"],style:{color:"#728fcb"}},{types:["placeholder","variable"],style:{color:"#93abdc"}},{types:["deleted"],style:{textDecorationLine:"line-through"}},{types:["inserted"],style:{textDecorationLine:"underline"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["important"],style:{color:"#896724"}}]},Xk=Yk,Zk={plain:{color:"#393A34",backgroundColor:"#f6f8fa"},styles:[{types:["comment","prolog","doctype","cdata"],style:{color:"#999988",fontStyle:"italic"}},{types:["namespace"],style:{opacity:.7}},{types:["string","attr-value"],style:{color:"#e3116c"}},{types:["punctuation","operator"],style:{color:"#393A34"}},{types:["entity","url","symbol","number","boolean","variable","constant","property","regex","inserted"],style:{color:"#36acaa"}},{types:["atrule","keyword","attr-name","selector"],style:{color:"#00a4db"}},{types:["function","deleted","tag"],style:{color:"#d73a49"}},{types:["function-variable"],style:{color:"#6f42c1"}},{types:["tag","selector","keyword"],style:{color:"#00009f"}}]},Kk=Zk,Qk={plain:{color:"#d6deeb",backgroundColor:"#011627"},styles:[{types:["changed"],style:{color:"rgb(162, 191, 252)",fontStyle:"italic"}},{types:["deleted"],style:{color:"rgba(239, 83, 80, 0.56)",fontStyle:"italic"}},{types:["inserted","attr-name"],style:{color:"rgb(173, 219, 103)",fontStyle:"italic"}},{types:["comment"],style:{color:"rgb(99, 119, 119)",fontStyle:"italic"}},{types:["string","url"],style:{color:"rgb(173, 219, 103)"}},{types:["variable"],style:{color:"rgb(214, 222, 235)"}},{types:["number"],style:{color:"rgb(247, 140, 108)"}},{types:["builtin","char","constant","function"],style:{color:"rgb(130, 170, 255)"}},{types:["punctuation"],style:{color:"rgb(199, 146, 234)"}},{types:["selector","doctype"],style:{color:"rgb(199, 146, 234)",fontStyle:"italic"}},{types:["class-name"],style:{color:"rgb(255, 203, 139)"}},{types:["tag","operator","keyword"],style:{color:"rgb(127, 219, 202)"}},{types:["boolean"],style:{color:"rgb(255, 88, 116)"}},{types:["property"],style:{color:"rgb(128, 203, 196)"}},{types:["namespace"],style:{color:"rgb(178, 204, 214)"}}]},Jk=Qk,Wk={plain:{color:"#403f53",backgroundColor:"#FBFBFB"},styles:[{types:["changed"],style:{color:"rgb(162, 191, 252)",fontStyle:"italic"}},{types:["deleted"],style:{color:"rgba(239, 83, 80, 0.56)",fontStyle:"italic"}},{types:["inserted","attr-name"],style:{color:"rgb(72, 118, 214)",fontStyle:"italic"}},{types:["comment"],style:{color:"rgb(152, 159, 177)",fontStyle:"italic"}},{types:["string","builtin","char","constant","url"],style:{color:"rgb(72, 118, 214)"}},{types:["variable"],style:{color:"rgb(201, 103, 101)"}},{types:["number"],style:{color:"rgb(170, 9, 130)"}},{types:["punctuation"],style:{color:"rgb(153, 76, 195)"}},{types:["function","selector","doctype"],style:{color:"rgb(153, 76, 195)",fontStyle:"italic"}},{types:["class-name"],style:{color:"rgb(17, 17, 17)"}},{types:["tag"],style:{color:"rgb(153, 76, 195)"}},{types:["operator","property","keyword","namespace"],style:{color:"rgb(12, 150, 155)"}},{types:["boolean"],style:{color:"rgb(188, 84, 84)"}}]},eE=Wk,xn={char:"#D8DEE9",comment:"#999999",keyword:"#c5a5c5",primitive:"#5a9bcf",string:"#8dc891",variable:"#d7deea",boolean:"#ff8b50",tag:"#fc929e",function:"#79b6f2",className:"#FAC863"},tE={plain:{backgroundColor:"#282c34",color:"#ffffff"},styles:[{types:["attr-name"],style:{color:xn.keyword}},{types:["attr-value"],style:{color:xn.string}},{types:["comment","block-comment","prolog","doctype","cdata","shebang"],style:{color:xn.comment}},{types:["property","number","function-name","constant","symbol","deleted"],style:{color:xn.primitive}},{types:["boolean"],style:{color:xn.boolean}},{types:["tag"],style:{color:xn.tag}},{types:["string"],style:{color:xn.string}},{types:["punctuation"],style:{color:xn.string}},{types:["selector","char","builtin","inserted"],style:{color:xn.char}},{types:["function"],style:{color:xn.function}},{types:["operator","entity","url","variable"],style:{color:xn.variable}},{types:["keyword"],style:{color:xn.keyword}},{types:["atrule","class-name"],style:{color:xn.className}},{types:["important"],style:{fontWeight:"400"}},{types:["bold"],style:{fontWeight:"bold"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["namespace"],style:{opacity:.7}}]},nE=tE,rE={plain:{color:"#f8f8f2",backgroundColor:"#272822"},styles:[{types:["changed"],style:{color:"rgb(162, 191, 252)",fontStyle:"italic"}},{types:["deleted"],style:{color:"#f92672",fontStyle:"italic"}},{types:["inserted"],style:{color:"rgb(173, 219, 103)",fontStyle:"italic"}},{types:["comment"],style:{color:"#8292a2",fontStyle:"italic"}},{types:["string","url"],style:{color:"#a6e22e"}},{types:["variable"],style:{color:"#f8f8f2"}},{types:["number"],style:{color:"#ae81ff"}},{types:["builtin","char","constant","function","class-name"],style:{color:"#e6db74"}},{types:["punctuation"],style:{color:"#f8f8f2"}},{types:["selector","doctype"],style:{color:"#a6e22e",fontStyle:"italic"}},{types:["tag","operator","keyword"],style:{color:"#66d9ef"}},{types:["boolean"],style:{color:"#ae81ff"}},{types:["namespace"],style:{color:"rgb(178, 204, 214)",opacity:.7}},{types:["tag","property"],style:{color:"#f92672"}},{types:["attr-name"],style:{color:"#a6e22e !important"}},{types:["doctype"],style:{color:"#8292a2"}},{types:["rule"],style:{color:"#e6db74"}}]},iE=rE,lE={plain:{color:"#bfc7d5",backgroundColor:"#292d3e"},styles:[{types:["comment"],style:{color:"rgb(105, 112, 152)",fontStyle:"italic"}},{types:["string","inserted"],style:{color:"rgb(195, 232, 141)"}},{types:["number"],style:{color:"rgb(247, 140, 108)"}},{types:["builtin","char","constant","function"],style:{color:"rgb(130, 170, 255)"}},{types:["punctuation","selector"],style:{color:"rgb(199, 146, 234)"}},{types:["variable"],style:{color:"rgb(191, 199, 213)"}},{types:["class-name","attr-name"],style:{color:"rgb(255, 203, 107)"}},{types:["tag","deleted"],style:{color:"rgb(255, 85, 114)"}},{types:["operator"],style:{color:"rgb(137, 221, 255)"}},{types:["boolean"],style:{color:"rgb(255, 88, 116)"}},{types:["keyword"],style:{fontStyle:"italic"}},{types:["doctype"],style:{color:"rgb(199, 146, 234)",fontStyle:"italic"}},{types:["namespace"],style:{color:"rgb(178, 204, 214)"}},{types:["url"],style:{color:"rgb(221, 221, 221)"}}]},aE=lE,oE={plain:{color:"#9EFEFF",backgroundColor:"#2D2A55"},styles:[{types:["changed"],style:{color:"rgb(255, 238, 128)"}},{types:["deleted"],style:{color:"rgba(239, 83, 80, 0.56)"}},{types:["inserted"],style:{color:"rgb(173, 219, 103)"}},{types:["comment"],style:{color:"rgb(179, 98, 255)",fontStyle:"italic"}},{types:["punctuation"],style:{color:"rgb(255, 255, 255)"}},{types:["constant"],style:{color:"rgb(255, 98, 140)"}},{types:["string","url"],style:{color:"rgb(165, 255, 144)"}},{types:["variable"],style:{color:"rgb(255, 238, 128)"}},{types:["number","boolean"],style:{color:"rgb(255, 98, 140)"}},{types:["attr-name"],style:{color:"rgb(255, 180, 84)"}},{types:["keyword","operator","property","namespace","tag","selector","doctype"],style:{color:"rgb(255, 157, 0)"}},{types:["builtin","char","constant","function","class-name"],style:{color:"rgb(250, 208, 0)"}}]},sE=oE,uE={plain:{backgroundColor:"linear-gradient(to bottom, #2a2139 75%, #34294f)",backgroundImage:"#34294f",color:"#f92aad",textShadow:"0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3"},styles:[{types:["comment","block-comment","prolog","doctype","cdata"],style:{color:"#495495",fontStyle:"italic"}},{types:["punctuation"],style:{color:"#ccc"}},{types:["tag","attr-name","namespace","number","unit","hexcode","deleted"],style:{color:"#e2777a"}},{types:["property","selector"],style:{color:"#72f1b8",textShadow:"0 0 2px #100c0f, 0 0 10px #257c5575, 0 0 35px #21272475"}},{types:["function-name"],style:{color:"#6196cc"}},{types:["boolean","selector-id","function"],style:{color:"#fdfdfd",textShadow:"0 0 2px #001716, 0 0 3px #03edf975, 0 0 5px #03edf975, 0 0 8px #03edf975"}},{types:["class-name","maybe-class-name","builtin"],style:{color:"#fff5f6",textShadow:"0 0 2px #000, 0 0 10px #fc1f2c75, 0 0 5px #fc1f2c75, 0 0 25px #fc1f2c75"}},{types:["constant","symbol"],style:{color:"#f92aad",textShadow:"0 0 2px #100c0f, 0 0 5px #dc078e33, 0 0 10px #fff3"}},{types:["important","atrule","keyword","selector-class"],style:{color:"#f4eee4",textShadow:"0 0 2px #393a33, 0 0 8px #f39f0575, 0 0 2px #f39f0575"}},{types:["string","char","attr-value","regex","variable"],style:{color:"#f87c32"}},{types:["parameter"],style:{fontStyle:"italic"}},{types:["entity","url"],style:{color:"#67cdcc"}},{types:["operator"],style:{color:"ffffffee"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["entity"],style:{cursor:"help"}},{types:["inserted"],style:{color:"green"}}]},cE=uE,fE={plain:{color:"#282a2e",backgroundColor:"#ffffff"},styles:[{types:["comment"],style:{color:"rgb(197, 200, 198)"}},{types:["string","number","builtin","variable"],style:{color:"rgb(150, 152, 150)"}},{types:["class-name","function","tag","attr-name"],style:{color:"rgb(40, 42, 46)"}}]},dE=fE,hE={plain:{color:"#9CDCFE",backgroundColor:"#1E1E1E"},styles:[{types:["prolog"],style:{color:"rgb(0, 0, 128)"}},{types:["comment"],style:{color:"rgb(106, 153, 85)"}},{types:["builtin","changed","keyword","interpolation-punctuation"],style:{color:"rgb(86, 156, 214)"}},{types:["number","inserted"],style:{color:"rgb(181, 206, 168)"}},{types:["constant"],style:{color:"rgb(100, 102, 149)"}},{types:["attr-name","variable"],style:{color:"rgb(156, 220, 254)"}},{types:["deleted","string","attr-value","template-punctuation"],style:{color:"rgb(206, 145, 120)"}},{types:["selector"],style:{color:"rgb(215, 186, 125)"}},{types:["tag"],style:{color:"rgb(78, 201, 176)"}},{types:["tag"],languages:["markup"],style:{color:"rgb(86, 156, 214)"}},{types:["punctuation","operator"],style:{color:"rgb(212, 212, 212)"}},{types:["punctuation"],languages:["markup"],style:{color:"#808080"}},{types:["function"],style:{color:"rgb(220, 220, 170)"}},{types:["class-name"],style:{color:"rgb(78, 201, 176)"}},{types:["char"],style:{color:"rgb(209, 105, 105)"}}]},k1=hE,pE={plain:{color:"#000000",backgroundColor:"#ffffff"},styles:[{types:["comment"],style:{color:"rgb(0, 128, 0)"}},{types:["builtin"],style:{color:"rgb(0, 112, 193)"}},{types:["number","variable","inserted"],style:{color:"rgb(9, 134, 88)"}},{types:["operator"],style:{color:"rgb(0, 0, 0)"}},{types:["constant","char"],style:{color:"rgb(129, 31, 63)"}},{types:["tag"],style:{color:"rgb(128, 0, 0)"}},{types:["attr-name"],style:{color:"rgb(255, 0, 0)"}},{types:["deleted","string"],style:{color:"rgb(163, 21, 21)"}},{types:["changed","punctuation"],style:{color:"rgb(4, 81, 165)"}},{types:["function","keyword"],style:{color:"rgb(0, 0, 255)"}},{types:["class-name"],style:{color:"rgb(38, 127, 153)"}}]},mE=pE,gE={plain:{color:"#f8fafc",backgroundColor:"#011627"},styles:[{types:["prolog"],style:{color:"#000080"}},{types:["comment"],style:{color:"#6A9955"}},{types:["builtin","changed","keyword","interpolation-punctuation"],style:{color:"#569CD6"}},{types:["number","inserted"],style:{color:"#B5CEA8"}},{types:["constant"],style:{color:"#f8fafc"}},{types:["attr-name","variable"],style:{color:"#9CDCFE"}},{types:["deleted","string","attr-value","template-punctuation"],style:{color:"#cbd5e1"}},{types:["selector"],style:{color:"#D7BA7D"}},{types:["tag"],style:{color:"#0ea5e9"}},{types:["tag"],languages:["markup"],style:{color:"#0ea5e9"}},{types:["punctuation","operator"],style:{color:"#D4D4D4"}},{types:["punctuation"],languages:["markup"],style:{color:"#808080"}},{types:["function"],style:{color:"#7dd3fc"}},{types:["class-name"],style:{color:"#0ea5e9"}},{types:["char"],style:{color:"#D16969"}}]},bE=gE,yE={plain:{color:"#0f172a",backgroundColor:"#f1f5f9"},styles:[{types:["prolog"],style:{color:"#000080"}},{types:["comment"],style:{color:"#6A9955"}},{types:["builtin","changed","keyword","interpolation-punctuation"],style:{color:"#0c4a6e"}},{types:["number","inserted"],style:{color:"#B5CEA8"}},{types:["constant"],style:{color:"#0f172a"}},{types:["attr-name","variable"],style:{color:"#0c4a6e"}},{types:["deleted","string","attr-value","template-punctuation"],style:{color:"#64748b"}},{types:["selector"],style:{color:"#D7BA7D"}},{types:["tag"],style:{color:"#0ea5e9"}},{types:["tag"],languages:["markup"],style:{color:"#0ea5e9"}},{types:["punctuation","operator"],style:{color:"#475569"}},{types:["punctuation"],languages:["markup"],style:{color:"#808080"}},{types:["function"],style:{color:"#0e7490"}},{types:["class-name"],style:{color:"#0ea5e9"}},{types:["char"],style:{color:"#D16969"}}]},xE=yE,vE={plain:{backgroundColor:"hsl(220, 13%, 18%)",color:"hsl(220, 14%, 71%)",textShadow:"0 1px rgba(0, 0, 0, 0.3)"},styles:[{types:["comment","prolog","cdata"],style:{color:"hsl(220, 10%, 40%)"}},{types:["doctype","punctuation","entity"],style:{color:"hsl(220, 14%, 71%)"}},{types:["attr-name","class-name","maybe-class-name","boolean","constant","number","atrule"],style:{color:"hsl(29, 54%, 61%)"}},{types:["keyword"],style:{color:"hsl(286, 60%, 67%)"}},{types:["property","tag","symbol","deleted","important"],style:{color:"hsl(355, 65%, 65%)"}},{types:["selector","string","char","builtin","inserted","regex","attr-value"],style:{color:"hsl(95, 38%, 62%)"}},{types:["variable","operator","function"],style:{color:"hsl(207, 82%, 66%)"}},{types:["url"],style:{color:"hsl(187, 47%, 55%)"}},{types:["deleted"],style:{textDecorationLine:"line-through"}},{types:["inserted"],style:{textDecorationLine:"underline"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["important"],style:{color:"hsl(220, 14%, 71%)"}}]},wE=vE,SE={plain:{backgroundColor:"hsl(230, 1%, 98%)",color:"hsl(230, 8%, 24%)"},styles:[{types:["comment","prolog","cdata"],style:{color:"hsl(230, 4%, 64%)"}},{types:["doctype","punctuation","entity"],style:{color:"hsl(230, 8%, 24%)"}},{types:["attr-name","class-name","boolean","constant","number","atrule"],style:{color:"hsl(35, 99%, 36%)"}},{types:["keyword"],style:{color:"hsl(301, 63%, 40%)"}},{types:["property","tag","symbol","deleted","important"],style:{color:"hsl(5, 74%, 59%)"}},{types:["selector","string","char","builtin","inserted","regex","attr-value","punctuation"],style:{color:"hsl(119, 34%, 47%)"}},{types:["variable","operator","function"],style:{color:"hsl(221, 87%, 60%)"}},{types:["url"],style:{color:"hsl(198, 99%, 37%)"}},{types:["deleted"],style:{textDecorationLine:"line-through"}},{types:["inserted"],style:{textDecorationLine:"underline"}},{types:["italic"],style:{fontStyle:"italic"}},{types:["important","bold"],style:{fontWeight:"bold"}},{types:["important"],style:{color:"hsl(230, 8%, 24%)"}}]},kE=SE,EE={plain:{color:"#ebdbb2",backgroundColor:"#292828"},styles:[{types:["imports","class-name","maybe-class-name","constant","doctype","builtin","function"],style:{color:"#d8a657"}},{types:["property-access"],style:{color:"#7daea3"}},{types:["tag"],style:{color:"#e78a4e"}},{types:["attr-name","char","url","regex"],style:{color:"#a9b665"}},{types:["attr-value","string"],style:{color:"#89b482"}},{types:["comment","prolog","cdata","operator","inserted"],style:{color:"#a89984"}},{types:["delimiter","boolean","keyword","selector","important","atrule","property","variable","deleted"],style:{color:"#ea6962"}},{types:["entity","number","symbol"],style:{color:"#d3869b"}}]},CE=EE,NE={plain:{color:"#654735",backgroundColor:"#f9f5d7"},styles:[{types:["delimiter","boolean","keyword","selector","important","atrule","property","variable","deleted"],style:{color:"#af2528"}},{types:["imports","class-name","maybe-class-name","constant","doctype","builtin"],style:{color:"#b4730e"}},{types:["string","attr-value"],style:{color:"#477a5b"}},{types:["property-access"],style:{color:"#266b79"}},{types:["function","attr-name","char","url"],style:{color:"#72761e"}},{types:["tag"],style:{color:"#b94c07"}},{types:["comment","prolog","cdata","operator","inserted"],style:{color:"#a89984"}},{types:["entity","number","symbol"],style:{color:"#924f79"}}]},AE=NE,TE=e=>A.useCallback(r=>{var i=r,{className:l,style:o,line:u}=i,c=S1(i,["className","style","line"]);const f=uu(Jn({},c),{className:x1("token-line",l)});return typeof e=="object"&&"plain"in e&&(f.style=e.plain),typeof o=="object"&&(f.style=Jn(Jn({},f.style||{}),o)),f},[e]),jE=e=>{const r=A.useCallback(({types:i,empty:l})=>{if(e!=null){{if(i.length===1&&i[0]==="plain")return l!=null?{display:"inline-block"}:void 0;if(i.length===1&&l!=null)return e[i[0]]}return Object.assign(l!=null?{display:"inline-block"}:{},...i.map(o=>e[o]))}},[e]);return A.useCallback(i=>{var l=i,{token:o,className:u,style:c}=l,f=S1(l,["token","className","style"]);const h=uu(Jn({},f),{className:x1("token",...o.types,u),children:o.content,style:r(o)});return c!=null&&(h.style=Jn(Jn({},h.style||{}),c)),h},[r])},RE=/\r\n|\r|\n/,ey=e=>{e.length===0?e.push({types:["plain"],content:`
|
|
13
|
+
`,empty:!0}):e.length===1&&e[0].content===""&&(e[0].content=`
|
|
14
|
+
`,e[0].empty=!0)},ty=(e,r)=>{const i=e.length;return i>0&&e[i-1]===r?e:e.concat(r)},_E=e=>{const r=[[]],i=[e],l=[0],o=[e.length];let u=0,c=0,f=[];const h=[f];for(;c>-1;){for(;(u=l[c]++)<o[c];){let p,g=r[c];const v=i[c][u];if(typeof v=="string"?(g=c>0?g:["plain"],p=v):(g=ty(g,v.type),v.alias&&(g=ty(g,v.alias)),p=v.content),typeof p!="string"){c++,r.push(g),i.push(p),l.push(0),o.push(p.length);continue}const x=p.split(RE),S=x.length;f.push({types:g,content:x[0]});for(let w=1;w<S;w++)ey(f),h.push(f=[]),f.push({types:g,content:x[w]})}c--,r.pop(),i.pop(),l.pop(),o.pop()}return ey(f),h},ny=_E,LE=({prism:e,code:r,grammar:i,language:l})=>A.useMemo(()=>{if(i==null)return ny([r]);const o={code:r,grammar:i,language:l,tokens:[]};return e.hooks.run("before-tokenize",o),o.tokens=e.tokenize(r,i),e.hooks.run("after-tokenize",o),ny(o.tokens)},[r,i,l,e]),DE=(e,r)=>{const{plain:i}=e,l=e.styles.reduce((o,u)=>{const{languages:c,style:f}=u;return c&&!c.includes(r)||u.types.forEach(h=>{const p=Jn(Jn({},o[h]),f);o[h]=p}),o},{});return l.root=i,l.plain=uu(Jn({},i),{backgroundColor:void 0}),l},OE=DE,ME=({children:e,language:r,code:i,theme:l,prism:o})=>{const u=r.toLowerCase(),c=OE(l,u),f=TE(c),h=jE(c),p=o.languages[u],g=LE({prism:o,language:u,code:i,grammar:p});return e({tokens:g,className:`prism-code language-${u}`,style:c!=null?c.root:{},getLineProps:f,getTokenProps:h})},zE=e=>A.createElement(ME,uu(Jn({},e),{prism:e.prism||ue,theme:e.theme||k1,code:e.code,language:e.language}));const FE="modulepreload",BE=function(e){return"/"+e},ry={},Lt=function(r,i,l){let o=Promise.resolve();if(i&&i.length>0){let h=function(p){return Promise.all(p.map(g=>Promise.resolve(g).then(b=>({status:"fulfilled",value:b}),b=>({status:"rejected",reason:b}))))};document.getElementsByTagName("link");const c=document.querySelector("meta[property=csp-nonce]"),f=c?.nonce||c?.getAttribute("nonce");o=h(i.map(p=>{if(p=BE(p),p in ry)return;ry[p]=!0;const g=p.endsWith(".css"),b=g?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${p}"]${b}`))return;const v=document.createElement("link");if(v.rel=g?"stylesheet":FE,g||(v.as="script"),v.crossOrigin="",v.href=p,f&&v.setAttribute("nonce",f),document.head.appendChild(v),g)return new Promise((x,S)=>{v.addEventListener("load",x),v.addEventListener("error",()=>S(new Error(`Unable to preload CSS for ${p}`)))})}))}function u(c){const f=new Event("vite:preloadError",{cancelable:!0});if(f.payload=c,window.dispatchEvent(f),!f.defaultPrevented)throw c}return o.then(c=>{for(const f of c||[])f.status==="rejected"&&u(f.reason);return r().catch(u)})},ws={};function E1(e){if(!ws[e]){const i={bash:()=>Lt(()=>import("./prism-bash-DTkDXsAh.js"),[]),sh:()=>Lt(()=>import("./prism-bash-DTkDXsAh.js"),[]),shell:()=>Lt(()=>import("./prism-bash-DTkDXsAh.js"),[]),php:async()=>(await Lt(()=>import("./prism-markup-templating-Ct1xsyfA.js"),[]),Lt(()=>import("./prism-php-C5Gn3FAI.js").then(l=>l.p),[])),sql:()=>Lt(()=>import("./prism-sql-AgAyy5H_.js"),[]),ruby:()=>Lt(()=>import("./prism-ruby-Bd_tu_g8.js").then(l=>l.p),[]),java:()=>Lt(()=>import("./prism-java-C_WzYmYM.js").then(l=>l.p),[]),scala:async()=>(await E1("java"),Lt(()=>import("./prism-scala-BjNo2HkN.js"),[])),solidity:()=>Lt(()=>import("./prism-solidity-DsMBj3dc.js").then(l=>l.p),[]),vim:()=>Lt(()=>import("./prism-vim-uciLQ2PQ.js"),[]),dart:()=>Lt(()=>import("./prism-dart-MjriiaMt.js"),[]),csharp:()=>Lt(()=>import("./prism-csharp-DEYqpNec.js").then(l=>l.p),[]),protobuf:()=>Lt(()=>import("./prism-protobuf-DiQ_z8B5.js"),[]),hcl:()=>Lt(()=>import("./prism-hcl-BmbK7K1f.js").then(l=>l.p),[]),perl:()=>Lt(()=>import("./prism-perl-Dlepj16W.js").then(l=>l.p),[]),elixir:()=>Lt(()=>import("./prism-elixir-CM3yUAD8.js").then(l=>l.p),[])}[e];if(!i)return console.warn(`No loader available for language: ${e}`),Promise.reject(new Error(`Unsupported language: ${e}`));ws[e]=i().then(()=>{}).catch(l=>{throw delete ws[e],console.warn(`Failed to load language: ${e}`,l),l})}return ws[e]}typeof global<"u"?global.Prism=ue:typeof window<"u"&&(window.Prism=ue);const iy=["markup","html","xml","svg","javascript","js","typescript","ts","jsx","tsx","css","c","cpp","swift","kotlin","objectivec","reason","rust","go","graphql","yaml","yml","json","markdown","md","python","py"];function IE(e,r){const[i,l]=A.useState(()=>iy.includes(r)||!!ue.languages[r]);return A.useEffect(()=>{if(!i){if(iy.includes(r)){l(!0);return}E1(r).then(()=>{l(!0)}).catch(()=>{l(!1)})}},[r,i]),{ready:i,actualLang:i?r:"text"}}function Qa(e){return e&&e.split(".").pop()?.toLowerCase()||null}function UE(e){return e&&e.split("/").pop()||""}const HE={js:"javascript",mjs:"javascript",cjs:"javascript",jsx:"javascript",ts:"typescript",mts:"typescript",cts:"typescript",tsx:"typescript",py:"python",rb:"ruby",go:"go",rs:"rust",java:"java",cpp:"cpp",c:"c",cs:"csharp",php:"php",swift:"swift",kt:"kotlin",scala:"scala",r:"r",sql:"sql",sh:"bash",bash:"bash",zsh:"bash",fish:"bash",yml:"yaml",yaml:"yaml",json:"json",xml:"xml",html:"html",css:"css",scss:"scss",sass:"sass",less:"less",md:"markdown",markdown:"markdown",tex:"latex",vim:"vim",ex:"elixir",exs:"elixir",heex:"elixir"},qE={ts:"typescript",tsx:"tsx",mts:"typescript",cts:"typescript",js:"javascript",jsx:"jsx",mjs:"javascript",cjs:"javascript",json:"json",css:"css",scss:"css",html:"html",sh:"bash",bash:"bash",zsh:"bash",fish:"bash",yml:"yaml",yaml:"yaml",md:"markdown",py:"python",rb:"ruby",go:"go",rs:"rust",java:"java",cpp:"cpp",c:"c",php:"php",sql:"sql",xml:"xml",swift:"swift",kt:"kotlin",scala:"scala",svelte:"svelte",r:"r",lua:"lua",perl:"perl",pl:"perl",pm:"perl",dockerfile:"docker",makefile:"makefile",gitignore:"git",env:"bash",conf:"nginx",ini:"ini",toml:"toml",sol:"solidity",vim:"vim",dart:"dart",cs:"csharp",proto:"protobuf",tf:"hcl",tfvars:"hcl",hcl:"hcl",ex:"elixir",exs:"elixir",heex:"elixir"},$E={dockerfile:"docker",makefile:"makefile",".gitignore":"git",".env":"bash",".bashrc":"bash",".zshrc":"bash",".bash_profile":"bash",".profile":"bash"};function C1(e,r){if(e)return r[e.toLowerCase()]}function PE(e){return C1(Qa(e),HE)}function VE(e){const r=UE(e).toLowerCase(),i=$E[r];return i||C1(Qa(e),qE)||"text"}function GE(e){return{...e,styles:e.styles.map(r=>({...r,style:{...r.style,background:void 0,backgroundColor:void 0}}))}}function YE(e){let r;switch(e){case"github":r=vn.github;break;case"vsLight":r=vn.vsLight;break;case"oneLight":r=vn.oneLight;break;case"gruvboxMaterialLight":r=vn.gruvboxMaterialLight;break;case"nightOwlLight":r=vn.nightOwlLight;break;case"vsDark":r=vn.vsDark;break;case"oneDark":r=vn.oneDark;break;case"gruvboxMaterialDark":r=vn.gruvboxMaterialDark;break;case"nightOwl":r=vn.nightOwl;break;case"dracula":r=vn.dracula;break;case"okaidia":r=vn.okaidia;break;default:r=vn.vsDark}return GE(r)}const xh=Qt.memo(function({code:r,language:i,className:l,syntaxTheme:o="vsDark",filename:u="",renderToken:c,onMouseOver:f,onMouseOut:h}){const p=i||(u?VE(u):"text"),{actualLang:g}=IE(r,p),b=YE(o),v=A.useCallback(({style:x,tokens:S,getLineProps:w,getTokenProps:N})=>y.jsx("span",{className:l,style:{...x,background:"transparent",backgroundColor:"transparent"},onMouseOver:f,onMouseOut:h,children:S.map((E,C)=>y.jsx("span",{...w({line:E}),children:E.map((j,z)=>c?c(j,z,N):y.jsx("span",{...N({token:j})},z))},C))}),[l,f,h,c]);return y.jsx(zE,{code:r,language:g,theme:b,prism:ue,children:v})}),Va=Qt.memo(function(r){const{handleMouseOver:i,handleMouseOut:l,isWordHighlighted:o}=Lk(),u=A.useCallback((c,f,h)=>{const p=h({token:c}),g=c.content.split(/( +)/);if(g.length===1&&g[0]&&!Jb(g[0]))return y.jsx("span",{...p},f);const b=g.map((v,x)=>{if(!v)return null;if(Jb(v)){const S=v.trim(),w=o(S);return y.jsx("span",{className:`word-token ${w?"word-highlight":""}`,"data-word":S,children:v},`${f}-${x}`)}return y.jsx("span",{children:v},`${f}-${x}`)});return y.jsx("span",{...p,children:b},f)},[o]);return y.jsx(xh,{...r,renderToken:u,onMouseOver:i,onMouseOut:l})}),Ad=Qt.memo(function({segments:r,className:i=""}){const l=A.useMemo(()=>r.map((o,u)=>{const c=o.type==="added"?"word-diff-added":o.type==="removed"?"word-diff-removed":"";return y.jsx("span",{className:c,children:o.value},u)}),[r]);return y.jsx("span",{className:i,children:l})}),XE=e=>{switch(e){case"add":return"+";case"delete":return"-";default:return" "}},ZE=e=>{switch(e){case"add":return"text-github-accent bg-diff-addition-bg";case"delete":return"text-github-danger bg-diff-deletion-bg";default:return"text-github-text-muted bg-github-bg-secondary"}};function N1({line:e,syntaxTheme:r,filename:i,diffSegments:l,showPrefixBorder:o=!0}){return y.jsxs("div",{className:"flex items-center relative min-h-[16px]",children:[y.jsx("span",{className:`w-5 text-center flex-shrink-0 ${o?"border-r border-github-border":""} ${ZE(e.type)}`,children:XE(e.type)}),l?y.jsx(Ad,{segments:l,className:"flex-1 px-3 text-github-text-primary whitespace-pre-wrap break-all overflow-wrap-break-word select-text"}):y.jsx(Va,{code:e.content,className:"flex-1 px-3 text-github-text-primary whitespace-pre-wrap break-all overflow-wrap-break-word select-text [&_pre]:m-0 [&_pre]:p-0 [&_pre]:!bg-transparent [&_pre]:font-inherit [&_pre]:text-inherit [&_pre]:leading-inherit [&_code]:!bg-transparent [&_code]:font-inherit [&_code]:text-inherit [&_code]:leading-inherit",syntaxTheme:r,filename:i})]})}const KE=e=>e==="add"?"bg-diff-addition-bg":"bg-diff-deletion-bg",QE=(e,r)=>({type:e,content:r});function ly({code:e,type:r,filename:i,keyPrefix:l,syntaxTheme:o}){return y.jsx(y.Fragment,{children:e.split(`
|
|
15
|
+
`).map((u,c)=>y.jsx("div",{className:KE(r),children:y.jsx(N1,{line:QE(r,u),filename:i,syntaxTheme:o,showPrefixBorder:!1})},`${l}-${c}`))})}function A1(e){return m1(e)}function Td({body:e,originalCode:r,filename:i,syntaxTheme:l}){const o=A.useMemo(()=>{const u=g1(e);if(u.length===0)return[{type:"text",content:e}];const c=[];let f=0;for(const h of u)h.startIndex>f&&c.push({type:"text",content:e.slice(f,h.startIndex)}),c.push({type:"suggestion",code:h.suggestedCode,original:r||""}),f=h.endIndex;return f<e.length&&c.push({type:"text",content:e.slice(f)}),c},[e,r]);return y.jsx("div",{className:"text-github-text-primary text-sm leading-6",children:o.map((u,c)=>u.type==="text"?y.jsx("span",{className:"whitespace-pre-wrap",children:u.content},c):y.jsx("div",{className:"my-2 border border-github-border rounded-md overflow-hidden",children:y.jsxs("div",{className:"font-mono text-sm",children:[u.original&&y.jsx(ly,{code:u.original,type:"delete",filename:i,keyPrefix:`orig-${c}`,syntaxTheme:l}),y.jsx(ly,{code:u.code,type:"add",filename:i,keyPrefix:`sugg-${c}`,syntaxTheme:l})]})},c))})}const JE="text-xs px-3 py-1.5 bg-github-bg-tertiary text-github-text-primary border border-github-border rounded hover:opacity-80 transition-all flex items-center gap-1";function T1({selectedCode:e,value:r,onChange:i,textareaRef:l,className:o=JE}){if(!e)return null;const u=()=>{const c=Nk(e),f=l?.current;if(!f){i(`${r}${r?`
|
|
16
|
+
|
|
17
|
+
`:""}${c}
|
|
18
|
+
|
|
19
|
+
`);return}const h=f.selectionStart,p=f.selectionEnd,g=r.slice(0,h),b=r.slice(p),x=`${g?`
|
|
20
|
+
|
|
21
|
+
`:""}${c}
|
|
22
|
+
|
|
23
|
+
`,S=g+x+b;i(S);const w=g.length+x.length;requestAnimationFrame(()=>{f.focus(),f.setSelectionRange(w,w)})};return y.jsxs("button",{type:"button",onClick:u,className:o,title:"Add code suggestion",children:[y.jsx(M2,{size:12}),"Add suggestion"]})}function vh({comment:e,onGeneratePrompt:r,onRemoveComment:i,onUpdateComment:l,onClick:o,syntaxTheme:u}){const[c,f]=A.useState(!1),[h,p]=A.useState(!1),[g,b]=A.useState(e.body),[v,x]=A.useState("edit"),S=A.useRef(null),w=A1(g),N=w?v:"edit",E=async O=>{O.stopPropagation();try{const Z=r(e);await navigator.clipboard.writeText(Z),f(!0),setTimeout(()=>f(!1),2e3)}catch(Z){console.error("Failed to copy prompt:",Z)}},C=O=>{O.stopPropagation(),p(!0),x("edit"),b(e.body)},j=()=>{p(!1),x("edit"),b(e.body)},z=O=>{O?.stopPropagation(),g.trim()!==e.body&&l(e.id,g.trim()),p(!1),x("edit")},I=O=>{O.stopPropagation(),i(e.id)},L=O=>{O.key==="Enter"&&(O.metaKey||O.ctrlKey)?(O.preventDefault(),z()):O.key==="Escape"&&(O.preventDefault(),j())};return lt("escape",()=>{h&&j()},{enableOnFormTags:["textarea"],enabled:h},[h]),lt("mod+enter",()=>{h&&z()},{enableOnFormTags:["textarea"],enabled:h},[h,g,e.body]),y.jsxs("div",{id:`comment-${e.id}`,className:`p-3 bg-github-bg-tertiary border border-yellow-600/50 rounded-md border-l-4 border-l-yellow-400 shadow-sm transition-all ${o?"hover:shadow-md cursor-pointer":""}`,onClick:o,children:[y.jsxs("div",{className:"flex items-center justify-between mb-2 gap-3",children:[y.jsx("div",{className:"flex items-center gap-2 text-xs text-github-text-secondary flex-1 min-w-0",children:y.jsxs("span",{className:"font-mono px-1 py-0.5 rounded overflow-hidden text-ellipsis whitespace-nowrap",style:{backgroundColor:"var(--color-yellow-path-bg)",color:"var(--color-yellow-path-text)"},children:[e.file,":",Array.isArray(e.line)?`${e.line[0]}-${e.line[1]}`:e.line]})}),y.jsx("div",{className:"flex items-center gap-2",children:h?w?y.jsxs("div",{className:"flex items-center bg-github-bg-tertiary border border-github-border rounded p-0.5",onClick:O=>O.stopPropagation(),children:[y.jsx("button",{type:"button",onClick:()=>x("edit"),className:`px-3 py-1.5 text-xs font-medium rounded transition-all duration-200 flex items-center gap-1.5 cursor-pointer ${N==="edit"?"bg-github-bg-primary text-github-text-primary shadow-sm":"text-github-text-secondary hover:text-github-text-primary"}`,children:"Edit"}),y.jsx("button",{type:"button",onClick:()=>x("preview"),className:`px-3 py-1.5 text-xs font-medium rounded transition-all duration-200 flex items-center gap-1.5 cursor-pointer ${N==="preview"?"bg-github-bg-primary text-github-text-primary shadow-sm":"text-github-text-secondary hover:text-github-text-primary"}`,children:"Preview"})]}):y.jsx("div",{onClick:O=>O.stopPropagation(),children:y.jsx(T1,{selectedCode:e.codeContent,value:g,onChange:b,textareaRef:S})}):y.jsxs(y.Fragment,{children:[y.jsx("button",{onClick:E,className:"text-xs px-2 py-1 rounded transition-all whitespace-nowrap",style:{backgroundColor:"var(--color-yellow-btn-bg)",color:"var(--color-yellow-btn-text)",border:"1px solid var(--color-yellow-btn-border)"},onMouseEnter:O=>{O.currentTarget.style.backgroundColor="var(--color-yellow-btn-hover-bg)",O.currentTarget.style.borderColor="var(--color-yellow-btn-hover-border)"},onMouseLeave:O=>{O.currentTarget.style.backgroundColor="var(--color-yellow-btn-bg)",O.currentTarget.style.borderColor="var(--color-yellow-btn-border)"},title:"Copy prompt for AI coding agent",children:c?"Copied!":"Copy Prompt"}),y.jsx("button",{onClick:C,className:"text-xs p-1.5 bg-github-bg-tertiary text-github-text-secondary border border-github-border rounded hover:text-github-text-primary hover:bg-github-bg-primary transition-all",title:"Edit",children:y.jsx(dk,{size:12})}),y.jsx("button",{onClick:I,className:"text-xs p-1.5 bg-github-bg-tertiary text-green-600 border border-github-border rounded hover:bg-green-500/10 hover:border-green-600 transition-all",title:"Resolve",children:y.jsx(Pa,{size:12})})]})})]}),h?y.jsxs("div",{children:[w&&N==="preview"?y.jsx(Td,{body:g,originalCode:e.codeContent,filename:e.file,syntaxTheme:u}):y.jsx(y.Fragment,{children:y.jsx("textarea",{ref:S,value:g,onChange:O=>b(O.target.value),className:"w-full text-github-text-primary text-sm leading-6 bg-github-bg-secondary border border-github-border rounded px-2 py-1 resize-none focus:outline-none focus:border-blue-600 focus:ring-1 focus:ring-blue-600/30",rows:Math.max(2,g.split(`
|
|
24
|
+
`).length),placeholder:"Edit your comment...",autoFocus:!0,onClick:O=>O.stopPropagation(),onKeyDown:O=>{O.stopPropagation(),L(O)}})}),y.jsxs("div",{className:"flex gap-2 justify-end mt-2",children:[y.jsx("button",{type:"button",onClick:j,className:"text-xs px-3 py-1.5 bg-github-bg-tertiary text-github-text-primary border border-github-border rounded hover:opacity-80 transition-all",children:"Cancel"}),y.jsx("button",{type:"button",onClick:z,className:"text-xs px-3 py-1.5 rounded transition-all disabled:opacity-50",style:{backgroundColor:"var(--color-yellow-btn-bg)",color:"var(--color-yellow-btn-text)",border:"1px solid var(--color-yellow-btn-border)"},onMouseEnter:O=>{O.currentTarget.style.backgroundColor="var(--color-yellow-btn-hover-bg)",O.currentTarget.style.borderColor="var(--color-yellow-btn-hover-border)"},onMouseLeave:O=>{O.currentTarget.style.backgroundColor="var(--color-yellow-btn-bg)",O.currentTarget.style.borderColor="var(--color-yellow-btn-border)"},disabled:!g.trim(),children:"Submit"})]})]}):y.jsx(Td,{body:e.body,originalCode:e.codeContent,filename:e.file,syntaxTheme:u})]})}function WE({isOpen:e,onClose:r,onNavigate:i,comments:l,onRemoveComment:o,onGeneratePrompt:u,onUpdateComment:c,syntaxTheme:f}){const[h,p]=A.useState(0),g=A.useRef([]),{enableScope:b,disableScope:v}=Za(),x=[...l].sort((E,C)=>{const j=E.file.localeCompare(C.file);if(j!==0)return j;const z=Array.isArray(E.line)?E.line[0]:E.line,I=Array.isArray(C.line)?C.line[0]:C.line;return z-I}),S=A.useCallback(E=>{i(E),r()},[i,r]),w=A.useCallback(E=>{confirm(`Delete this comment?
|
|
25
|
+
|
|
26
|
+
"${E.body}"`)&&(o(E.id),h>=x.length-1&&h>0&&p(h-1))},[o,h,x.length]);A.useEffect(()=>(e?(b("comments-list"),v("navigation")):(b("navigation"),v("comments-list"),p(0)),()=>{b("navigation"),v("comments-list")}),[e,b,v]);const N={scopes:"comments-list",enableOnFormTags:!1};return lt("escape",()=>r(),N,[r]),lt("j, down",()=>p(E=>Math.min(E+1,x.length-1)),N,[x.length]),lt("k, up",()=>p(E=>Math.max(E-1,0)),N,[]),lt("enter",()=>{x[h]&&S(x[h])},N,[h,x,S]),lt("d",()=>{x[h]&&w(x[h])},N,[h,x,w]),A.useEffect(()=>{g.current[h]&&g.current[h]?.scrollIntoView({behavior:"smooth",block:"nearest"})},[h]),e?y.jsxs("div",{className:"fixed inset-0 z-50 flex items-center justify-center",children:[y.jsx("div",{className:"absolute inset-0 bg-black/50",onClick:r}),y.jsxs("div",{className:"relative bg-github-bg-primary border border-github-border rounded-lg shadow-lg max-w-4xl w-full max-h-[80vh] overflow-hidden",children:[y.jsxs("div",{className:"sticky top-0 bg-github-bg-primary border-b border-github-border px-6 py-4",children:[y.jsxs("div",{className:"flex items-center justify-between mb-2",children:[y.jsx("h2",{className:"text-lg font-semibold text-github-text-primary",children:"All Comments"}),y.jsx("button",{onClick:r,className:"text-github-text-secondary hover:text-github-text-primary transition-colors","aria-label":"Close comments list",children:y.jsx(ou,{size:20})})]}),y.jsxs("div",{className:"text-xs text-github-text-secondary",children:[y.jsx("span",{className:"font-mono",children:"j/k"})," or ",y.jsx("span",{className:"font-mono",children:"↑/↓"})," to navigate • ",y.jsx("span",{className:"font-mono",children:"Enter"})," to jump •"," ",y.jsx("span",{className:"font-mono",children:"d"})," to delete • ",y.jsx("span",{className:"font-mono",children:"Esc"})," ","to close"]})]}),y.jsx("div",{className:"overflow-y-auto max-h-[calc(80vh-120px)]",children:y.jsx("div",{className:"p-6",children:x.length===0?y.jsx("p",{className:"text-github-text-secondary text-center",children:"No comments yet"}):y.jsxs(y.Fragment,{children:[y.jsx("div",{className:"space-y-2",children:x.map((E,C)=>y.jsx("div",{ref:j=>{g.current[C]=j},className:`${h===C?"ring-2 ring-blue-500 rounded":""}`,children:y.jsx(vh,{comment:E,onGeneratePrompt:u,onRemoveComment:o,onUpdateComment:c,syntaxTheme:f,onClick:j=>{j.stopPropagation(),p(C),S(E)}})},E.id))}),x.length>0&&y.jsxs("div",{className:"mt-4 pt-4 border-t border-github-border text-xs text-github-text-secondary text-center",children:[h+1," of ",x.length," comments"]})]})})})]})]}):null}function cu(){return typeof window<"u"}function ui(e){return wh(e)?(e.nodeName||"").toLowerCase():"#document"}function un(e){var r;return(e==null||(r=e.ownerDocument)==null?void 0:r.defaultView)||window}function er(e){var r;return(r=(wh(e)?e.ownerDocument:e.document)||window.document)==null?void 0:r.documentElement}function wh(e){return cu()?e instanceof Node||e instanceof un(e).Node:!1}function ct(e){return cu()?e instanceof Element||e instanceof un(e).Element:!1}function Rt(e){return cu()?e instanceof HTMLElement||e instanceof un(e).HTMLElement:!1}function Bs(e){return!cu()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof un(e).ShadowRoot}function Ja(e){const{overflow:r,overflowX:i,overflowY:l,display:o}=Mn(e);return/auto|scroll|overlay|hidden|clip/.test(r+l+i)&&o!=="inline"&&o!=="contents"}function eC(e){return/^(table|td|th)$/.test(ui(e))}function fu(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}const tC=/transform|translate|scale|rotate|perspective|filter/,nC=/paint|layout|strict|content/,Ri=e=>!!e&&e!=="none";let qf;function Sh(e){const r=ct(e)?Mn(e):e;return Ri(r.transform)||Ri(r.translate)||Ri(r.scale)||Ri(r.rotate)||Ri(r.perspective)||!du()&&(Ri(r.backdropFilter)||Ri(r.filter))||tC.test(r.willChange||"")||nC.test(r.contain||"")}function rC(e){let r=Cr(e);for(;Rt(r)&&!Er(r);){if(Sh(r))return r;if(fu(r))return null;r=Cr(r)}return null}function du(){return qf==null&&(qf=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),qf}function Er(e){return/^(html|body|#document)$/.test(ui(e))}function Mn(e){return un(e).getComputedStyle(e)}function hu(e){return ct(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Cr(e){if(ui(e)==="html")return e;const r=e.assignedSlot||e.parentNode||Bs(e)&&e.host||er(e);return Bs(r)?r.host:r}function j1(e){const r=Cr(e);return Er(r)?e.ownerDocument?e.ownerDocument.body:e.body:Rt(r)&&Ja(r)?r:j1(r)}function si(e,r,i){var l;r===void 0&&(r=[]),i===void 0&&(i=!0);const o=j1(e),u=o===((l=e.ownerDocument)==null?void 0:l.body),c=un(o);if(u){const f=jd(c);return r.concat(c,c.visualViewport||[],Ja(o)?o:[],f&&i?si(f):[])}else return r.concat(o,si(o,[],i))}function jd(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}const Is=Math.min,Di=Math.max,Us=Math.round,Ss=Math.floor,Wn=e=>({x:e,y:e}),iC={left:"right",right:"left",bottom:"top",top:"bottom"};function ay(e,r,i){return Di(e,Is(r,i))}function pu(e,r){return typeof e=="function"?e(r):e}function Oi(e){return e.split("-")[0]}function mu(e){return e.split("-")[1]}function R1(e){return e==="x"?"y":"x"}function _1(e){return e==="y"?"height":"width"}function li(e){const r=e[0];return r==="t"||r==="b"?"y":"x"}function L1(e){return R1(li(e))}function lC(e,r,i){i===void 0&&(i=!1);const l=mu(e),o=L1(e),u=_1(o);let c=o==="x"?l===(i?"end":"start")?"right":"left":l==="start"?"bottom":"top";return r.reference[u]>r.floating[u]&&(c=Hs(c)),[c,Hs(c)]}function aC(e){const r=Hs(e);return[Rd(e),r,Rd(r)]}function Rd(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const oy=["left","right"],sy=["right","left"],oC=["top","bottom"],sC=["bottom","top"];function uC(e,r,i){switch(e){case"top":case"bottom":return i?r?sy:oy:r?oy:sy;case"left":case"right":return r?oC:sC;default:return[]}}function cC(e,r,i,l){const o=mu(e);let u=uC(Oi(e),i==="start",l);return o&&(u=u.map(c=>c+"-"+o),r&&(u=u.concat(u.map(Rd)))),u}function Hs(e){const r=Oi(e);return iC[r]+e.slice(r.length)}function fC(e){return{top:0,right:0,bottom:0,left:0,...e}}function dC(e){return typeof e!="number"?fC(e):{top:e,right:e,bottom:e,left:e}}function qs(e){const{x:r,y:i,width:l,height:o}=e;return{width:l,height:o,top:i,left:r,right:r+l,bottom:i+o,x:r,y:i}}var hC=["input:not([inert]):not([inert] *)","select:not([inert]):not([inert] *)","textarea:not([inert]):not([inert] *)","a[href]:not([inert]):not([inert] *)","button:not([inert]):not([inert] *)","[tabindex]:not(slot):not([inert]):not([inert] *)","audio[controls]:not([inert]):not([inert] *)","video[controls]:not([inert]):not([inert] *)",'[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)',"details>summary:first-of-type:not([inert]):not([inert] *)","details:not([inert]):not([inert] *)"],$s=hC.join(","),D1=typeof Element>"u",Ll=D1?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Ps=!D1&&Element.prototype.getRootNode?function(e){var r;return e==null||(r=e.getRootNode)===null||r===void 0?void 0:r.call(e)}:function(e){return e?.ownerDocument},Vs=function(r,i){var l;i===void 0&&(i=!0);var o=r==null||(l=r.getAttribute)===null||l===void 0?void 0:l.call(r,"inert"),u=o===""||o==="true",c=u||i&&r&&(typeof r.closest=="function"?r.closest("[inert]"):Vs(r.parentNode));return c},pC=function(r){var i,l=r==null||(i=r.getAttribute)===null||i===void 0?void 0:i.call(r,"contenteditable");return l===""||l==="true"},O1=function(r,i,l){if(Vs(r))return[];var o=Array.prototype.slice.apply(r.querySelectorAll($s));return i&&Ll.call(r,$s)&&o.unshift(r),o=o.filter(l),o},Gs=function(r,i,l){for(var o=[],u=Array.from(r);u.length;){var c=u.shift();if(!Vs(c,!1))if(c.tagName==="SLOT"){var f=c.assignedElements(),h=f.length?f:c.children,p=Gs(h,!0,l);l.flatten?o.push.apply(o,p):o.push({scopeParent:c,candidates:p})}else{var g=Ll.call(c,$s);g&&l.filter(c)&&(i||!r.includes(c))&&o.push(c);var b=c.shadowRoot||typeof l.getShadowRoot=="function"&&l.getShadowRoot(c),v=!Vs(b,!1)&&(!l.shadowRootFilter||l.shadowRootFilter(c));if(b&&v){var x=Gs(b===!0?c.children:b.children,!0,l);l.flatten?o.push.apply(o,x):o.push({scopeParent:c,candidates:x})}else u.unshift.apply(u,c.children)}}return o},M1=function(r){return!isNaN(parseInt(r.getAttribute("tabindex"),10))},z1=function(r){if(!r)throw new Error("No node provided");return r.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(r.tagName)||pC(r))&&!M1(r)?0:r.tabIndex},mC=function(r,i){var l=z1(r);return l<0&&i&&!M1(r)?0:l},gC=function(r,i){return r.tabIndex===i.tabIndex?r.documentOrder-i.documentOrder:r.tabIndex-i.tabIndex},F1=function(r){return r.tagName==="INPUT"},bC=function(r){return F1(r)&&r.type==="hidden"},yC=function(r){var i=r.tagName==="DETAILS"&&Array.prototype.slice.apply(r.children).some(function(l){return l.tagName==="SUMMARY"});return i},xC=function(r,i){for(var l=0;l<r.length;l++)if(r[l].checked&&r[l].form===i)return r[l]},vC=function(r){if(!r.name)return!0;var i=r.form||Ps(r),l=function(f){return i.querySelectorAll('input[type="radio"][name="'+f+'"]')},o;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")o=l(window.CSS.escape(r.name));else try{o=l(r.name)}catch(c){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",c.message),!1}var u=xC(o,r.form);return!u||u===r},wC=function(r){return F1(r)&&r.type==="radio"},SC=function(r){return wC(r)&&!vC(r)},kC=function(r){var i,l=r&&Ps(r),o=(i=l)===null||i===void 0?void 0:i.host,u=!1;if(l&&l!==r){var c,f,h;for(u=!!((c=o)!==null&&c!==void 0&&(f=c.ownerDocument)!==null&&f!==void 0&&f.contains(o)||r!=null&&(h=r.ownerDocument)!==null&&h!==void 0&&h.contains(r));!u&&o;){var p,g,b;l=Ps(o),o=(p=l)===null||p===void 0?void 0:p.host,u=!!((g=o)!==null&&g!==void 0&&(b=g.ownerDocument)!==null&&b!==void 0&&b.contains(o))}}return u},uy=function(r){var i=r.getBoundingClientRect(),l=i.width,o=i.height;return l===0&&o===0},EC=function(r,i){var l=i.displayCheck,o=i.getShadowRoot;if(l==="full-native"&&"checkVisibility"in r){var u=r.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!u}if(getComputedStyle(r).visibility==="hidden")return!0;var c=Ll.call(r,"details>summary:first-of-type"),f=c?r.parentElement:r;if(Ll.call(f,"details:not([open]) *"))return!0;if(!l||l==="full"||l==="full-native"||l==="legacy-full"){if(typeof o=="function"){for(var h=r;r;){var p=r.parentElement,g=Ps(r);if(p&&!p.shadowRoot&&o(p)===!0)return uy(r);r.assignedSlot?r=r.assignedSlot:!p&&g!==r.ownerDocument?r=g.host:r=p}r=h}if(kC(r))return!r.getClientRects().length;if(l!=="legacy-full")return!0}else if(l==="non-zero-area")return uy(r);return!1},CC=function(r){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(r.tagName))for(var i=r.parentElement;i;){if(i.tagName==="FIELDSET"&&i.disabled){for(var l=0;l<i.children.length;l++){var o=i.children.item(l);if(o.tagName==="LEGEND")return Ll.call(i,"fieldset[disabled] *")?!0:!o.contains(r)}return!0}i=i.parentElement}return!1},_d=function(r,i){return!(i.disabled||bC(i)||EC(i,r)||yC(i)||CC(i))},Ld=function(r,i){return!(SC(i)||z1(i)<0||!_d(r,i))},NC=function(r){var i=parseInt(r.getAttribute("tabindex"),10);return!!(isNaN(i)||i>=0)},B1=function(r){var i=[],l=[];return r.forEach(function(o,u){var c=!!o.scopeParent,f=c?o.scopeParent:o,h=mC(f,c),p=c?B1(o.candidates):f;h===0?c?i.push.apply(i,p):i.push(f):l.push({documentOrder:u,tabIndex:h,item:o,isScope:c,content:p})}),l.sort(gC).reduce(function(o,u){return u.isScope?o.push.apply(o,u.content):o.push(u.content),o},[]).concat(i)},gu=function(r,i){i=i||{};var l;return i.getShadowRoot?l=Gs([r],i.includeContainer,{filter:Ld.bind(null,i),flatten:!1,getShadowRoot:i.getShadowRoot,shadowRootFilter:NC}):l=O1(r,i.includeContainer,Ld.bind(null,i)),B1(l)},AC=function(r,i){i=i||{};var l;return i.getShadowRoot?l=Gs([r],i.includeContainer,{filter:_d.bind(null,i),flatten:!0,getShadowRoot:i.getShadowRoot}):l=O1(r,i.includeContainer,_d.bind(null,i)),l},I1=function(r,i){if(i=i||{},!r)throw new Error("No node provided");return Ll.call(r,$s)===!1?!1:Ld(i,r)};function U1(){const e=navigator.userAgentData;return e!=null&&e.platform?e.platform:navigator.platform}function H1(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(r=>{let{brand:i,version:l}=r;return i+"/"+l}).join(" "):navigator.userAgent}function q1(){return/apple/i.test(navigator.vendor)}function Dd(){const e=/android/i;return e.test(U1())||e.test(H1())}function TC(){return U1().toLowerCase().startsWith("mac")&&!navigator.maxTouchPoints}function $1(){return H1().includes("jsdom/")}const cy="data-floating-ui-focusable",jC="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function ii(e){let r=e.activeElement;for(;((i=r)==null||(i=i.shadowRoot)==null?void 0:i.activeElement)!=null;){var i;r=r.shadowRoot.activeElement}return r}function qt(e,r){if(!e||!r)return!1;const i=r.getRootNode==null?void 0:r.getRootNode();if(e.contains(r))return!0;if(i&&Bs(i)){let l=r;for(;l;){if(e===l)return!0;l=l.parentNode||l.host}}return!1}function Sr(e){return"composedPath"in e?e.composedPath()[0]:e.target}function $f(e,r){if(r==null)return!1;if("composedPath"in e)return e.composedPath().includes(r);const i=e;return i.target!=null&&r.contains(i.target)}function RC(e){return e.matches("html,body")}function $t(e){return e?.ownerDocument||document}function kh(e){return Rt(e)&&e.matches(jC)}function fy(e){return e?e.getAttribute("role")==="combobox"&&kh(e):!1}function _C(e){if(!e||$1())return!0;try{return e.matches(":focus-visible")}catch{return!0}}function Od(e){return e?e.hasAttribute(cy)?e:e.querySelector("["+cy+"]")||e:null}function Al(e,r,i){return i===void 0&&(i=!0),e.filter(o=>{var u;return o.parentId===r&&(!i||((u=o.context)==null?void 0:u.open))}).flatMap(o=>[o,...Al(e,o.id,i)])}function dy(e,r){var i;let l=[],o=(i=e.find(u=>u.id===r))==null?void 0:i.parentId;for(;o;){const u=e.find(c=>c.id===o);o=u?.parentId,u&&(l=l.concat(u))}return l}function Pf(e){e.preventDefault(),e.stopPropagation()}function LC(e){return"nativeEvent"in e}function DC(e){return e.mozInputSource===0&&e.isTrusted?!0:Dd()&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function OC(e){return $1()?!1:!Dd()&&e.width===0&&e.height===0||Dd()&&e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType==="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0&&e.pointerType==="touch"}function Ga(e,r){const i=["mouse","pen"];return r||i.push("",void 0),i.includes(e)}var MC=typeof document<"u",zC=function(){},sn=MC?A.useLayoutEffect:zC;const FC={...Qx};function Li(e){const r=A.useRef(e);return sn(()=>{r.current=e}),r}const BC=FC.useInsertionEffect,IC=BC||(e=>e());function on(e){const r=A.useRef(()=>{});return IC(()=>{r.current=e}),A.useCallback(function(){for(var i=arguments.length,l=new Array(i),o=0;o<i;o++)l[o]=arguments[o];return r.current==null?void 0:r.current(...l)},[])}const Wa=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function P1(e,r){const i=gu(e,Wa()),l=i.length;if(l===0)return;const o=ii($t(e)),u=i.indexOf(o),c=u===-1?r===1?0:l-1:u+r;return i[c]}function V1(e){return P1($t(e).body,1)||e}function G1(e){return P1($t(e).body,-1)||e}function Ba(e,r){const i=r||e.currentTarget,l=e.relatedTarget;return!l||!qt(i,l)}function UC(e){gu(e,Wa()).forEach(i=>{i.dataset.tabindex=i.getAttribute("tabindex")||"",i.setAttribute("tabindex","-1")})}function hy(e){e.querySelectorAll("[data-tabindex]").forEach(i=>{const l=i.dataset.tabindex;delete i.dataset.tabindex,l?i.setAttribute("tabindex",l):i.removeAttribute("tabindex")})}var Y1=Jx();function py(e,r,i){let{reference:l,floating:o}=e;const u=li(r),c=L1(r),f=_1(c),h=Oi(r),p=u==="y",g=l.x+l.width/2-o.width/2,b=l.y+l.height/2-o.height/2,v=l[f]/2-o[f]/2;let x;switch(h){case"top":x={x:g,y:l.y-o.height};break;case"bottom":x={x:g,y:l.y+l.height};break;case"right":x={x:l.x+l.width,y:b};break;case"left":x={x:l.x-o.width,y:b};break;default:x={x:l.x,y:l.y}}switch(mu(r)){case"start":x[c]-=v*(i&&p?-1:1);break;case"end":x[c]+=v*(i&&p?-1:1);break}return x}async function HC(e,r){var i;r===void 0&&(r={});const{x:l,y:o,platform:u,rects:c,elements:f,strategy:h}=e,{boundary:p="clippingAncestors",rootBoundary:g="viewport",elementContext:b="floating",altBoundary:v=!1,padding:x=0}=pu(r,e),S=dC(x),N=f[v?b==="floating"?"reference":"floating":b],E=qs(await u.getClippingRect({element:(i=await(u.isElement==null?void 0:u.isElement(N)))==null||i?N:N.contextElement||await(u.getDocumentElement==null?void 0:u.getDocumentElement(f.floating)),boundary:p,rootBoundary:g,strategy:h})),C=b==="floating"?{x:l,y:o,width:c.floating.width,height:c.floating.height}:c.reference,j=await(u.getOffsetParent==null?void 0:u.getOffsetParent(f.floating)),z=await(u.isElement==null?void 0:u.isElement(j))?await(u.getScale==null?void 0:u.getScale(j))||{x:1,y:1}:{x:1,y:1},I=qs(u.convertOffsetParentRelativeRectToViewportRelativeRect?await u.convertOffsetParentRelativeRectToViewportRelativeRect({elements:f,rect:C,offsetParent:j,strategy:h}):C);return{top:(E.top-I.top+S.top)/z.y,bottom:(I.bottom-E.bottom+S.bottom)/z.y,left:(E.left-I.left+S.left)/z.x,right:(I.right-E.right+S.right)/z.x}}const qC=50,$C=async(e,r,i)=>{const{placement:l="bottom",strategy:o="absolute",middleware:u=[],platform:c}=i,f=c.detectOverflow?c:{...c,detectOverflow:HC},h=await(c.isRTL==null?void 0:c.isRTL(r));let p=await c.getElementRects({reference:e,floating:r,strategy:o}),{x:g,y:b}=py(p,l,h),v=l,x=0;const S={};for(let w=0;w<u.length;w++){const N=u[w];if(!N)continue;const{name:E,fn:C}=N,{x:j,y:z,data:I,reset:L}=await C({x:g,y:b,initialPlacement:l,placement:v,strategy:o,middlewareData:S,rects:p,platform:f,elements:{reference:e,floating:r}});g=j??g,b=z??b,S[E]={...S[E],...I},L&&x<qC&&(x++,typeof L=="object"&&(L.placement&&(v=L.placement),L.rects&&(p=L.rects===!0?await c.getElementRects({reference:e,floating:r,strategy:o}):L.rects),{x:g,y:b}=py(p,v,h)),w=-1)}return{x:g,y:b,placement:v,strategy:o,middlewareData:S}},PC=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(r){var i,l;const{placement:o,middlewareData:u,rects:c,initialPlacement:f,platform:h,elements:p}=r,{mainAxis:g=!0,crossAxis:b=!0,fallbackPlacements:v,fallbackStrategy:x="bestFit",fallbackAxisSideDirection:S="none",flipAlignment:w=!0,...N}=pu(e,r);if((i=u.arrow)!=null&&i.alignmentOffset)return{};const E=Oi(o),C=li(f),j=Oi(f)===f,z=await(h.isRTL==null?void 0:h.isRTL(p.floating)),I=v||(j||!w?[Hs(f)]:aC(f)),L=S!=="none";!v&&L&&I.push(...cC(f,w,S,z));const O=[f,...I],Z=await h.detectOverflow(r,N),$=[];let F=((l=u.flip)==null?void 0:l.overflows)||[];if(g&&$.push(Z[E]),b){const U=lC(o,c,z);$.push(Z[U[0]],Z[U[1]])}if(F=[...F,{placement:o,overflows:$}],!$.every(U=>U<=0)){var H,G;const U=(((H=u.flip)==null?void 0:H.index)||0)+1,Y=O[U];if(Y&&(!(b==="alignment"?C!==li(Y):!1)||F.every(M=>li(M.placement)===C?M.overflows[0]>0:!0)))return{data:{index:U,overflows:F},reset:{placement:Y}};let B=(G=F.filter(X=>X.overflows[0]<=0).sort((X,M)=>X.overflows[1]-M.overflows[1])[0])==null?void 0:G.placement;if(!B)switch(x){case"bestFit":{var Q;const X=(Q=F.filter(M=>{if(L){const V=li(M.placement);return V===C||V==="y"}return!0}).map(M=>[M.placement,M.overflows.filter(V=>V>0).reduce((V,R)=>V+R,0)]).sort((M,V)=>M[1]-V[1])[0])==null?void 0:Q[0];X&&(B=X);break}case"initialPlacement":B=f;break}if(o!==B)return{reset:{placement:B}}}return{}}}},VC=new Set(["left","top"]);async function GC(e,r){const{placement:i,platform:l,elements:o}=e,u=await(l.isRTL==null?void 0:l.isRTL(o.floating)),c=Oi(i),f=mu(i),h=li(i)==="y",p=VC.has(c)?-1:1,g=u&&h?-1:1,b=pu(r,e);let{mainAxis:v,crossAxis:x,alignmentAxis:S}=typeof b=="number"?{mainAxis:b,crossAxis:0,alignmentAxis:null}:{mainAxis:b.mainAxis||0,crossAxis:b.crossAxis||0,alignmentAxis:b.alignmentAxis};return f&&typeof S=="number"&&(x=f==="end"?S*-1:S),h?{x:x*g,y:v*p}:{x:v*p,y:x*g}}const YC=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(r){var i,l;const{x:o,y:u,placement:c,middlewareData:f}=r,h=await GC(r,e);return c===((i=f.offset)==null?void 0:i.placement)&&(l=f.arrow)!=null&&l.alignmentOffset?{}:{x:o+h.x,y:u+h.y,data:{...h,placement:c}}}}},XC=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(r){const{x:i,y:l,placement:o,platform:u}=r,{mainAxis:c=!0,crossAxis:f=!1,limiter:h={fn:E=>{let{x:C,y:j}=E;return{x:C,y:j}}},...p}=pu(e,r),g={x:i,y:l},b=await u.detectOverflow(r,p),v=li(Oi(o)),x=R1(v);let S=g[x],w=g[v];if(c){const E=x==="y"?"top":"left",C=x==="y"?"bottom":"right",j=S+b[E],z=S-b[C];S=ay(j,S,z)}if(f){const E=v==="y"?"top":"left",C=v==="y"?"bottom":"right",j=w+b[E],z=w-b[C];w=ay(j,w,z)}const N=h.fn({...r,[x]:S,[v]:w});return{...N,data:{x:N.x-i,y:N.y-l,enabled:{[x]:c,[v]:f}}}}}};function X1(e){const r=Mn(e);let i=parseFloat(r.width)||0,l=parseFloat(r.height)||0;const o=Rt(e),u=o?e.offsetWidth:i,c=o?e.offsetHeight:l,f=Us(i)!==u||Us(l)!==c;return f&&(i=u,l=c),{width:i,height:l,$:f}}function Eh(e){return ct(e)?e:e.contextElement}function Tl(e){const r=Eh(e);if(!Rt(r))return Wn(1);const i=r.getBoundingClientRect(),{width:l,height:o,$:u}=X1(r);let c=(u?Us(i.width):i.width)/l,f=(u?Us(i.height):i.height)/o;return(!c||!Number.isFinite(c))&&(c=1),(!f||!Number.isFinite(f))&&(f=1),{x:c,y:f}}const ZC=Wn(0);function Z1(e){const r=un(e);return!du()||!r.visualViewport?ZC:{x:r.visualViewport.offsetLeft,y:r.visualViewport.offsetTop}}function KC(e,r,i){return r===void 0&&(r=!1),!i||r&&i!==un(e)?!1:r}function Mi(e,r,i,l){r===void 0&&(r=!1),i===void 0&&(i=!1);const o=e.getBoundingClientRect(),u=Eh(e);let c=Wn(1);r&&(l?ct(l)&&(c=Tl(l)):c=Tl(e));const f=KC(u,i,l)?Z1(u):Wn(0);let h=(o.left+f.x)/c.x,p=(o.top+f.y)/c.y,g=o.width/c.x,b=o.height/c.y;if(u){const v=un(u),x=l&&ct(l)?un(l):l;let S=v,w=jd(S);for(;w&&l&&x!==S;){const N=Tl(w),E=w.getBoundingClientRect(),C=Mn(w),j=E.left+(w.clientLeft+parseFloat(C.paddingLeft))*N.x,z=E.top+(w.clientTop+parseFloat(C.paddingTop))*N.y;h*=N.x,p*=N.y,g*=N.x,b*=N.y,h+=j,p+=z,S=un(w),w=jd(S)}}return qs({width:g,height:b,x:h,y:p})}function bu(e,r){const i=hu(e).scrollLeft;return r?r.left+i:Mi(er(e)).left+i}function K1(e,r){const i=e.getBoundingClientRect(),l=i.left+r.scrollLeft-bu(e,i),o=i.top+r.scrollTop;return{x:l,y:o}}function QC(e){let{elements:r,rect:i,offsetParent:l,strategy:o}=e;const u=o==="fixed",c=er(l),f=r?fu(r.floating):!1;if(l===c||f&&u)return i;let h={scrollLeft:0,scrollTop:0},p=Wn(1);const g=Wn(0),b=Rt(l);if((b||!b&&!u)&&((ui(l)!=="body"||Ja(c))&&(h=hu(l)),b)){const x=Mi(l);p=Tl(l),g.x=x.x+l.clientLeft,g.y=x.y+l.clientTop}const v=c&&!b&&!u?K1(c,h):Wn(0);return{width:i.width*p.x,height:i.height*p.y,x:i.x*p.x-h.scrollLeft*p.x+g.x+v.x,y:i.y*p.y-h.scrollTop*p.y+g.y+v.y}}function JC(e){return Array.from(e.getClientRects())}function WC(e){const r=er(e),i=hu(e),l=e.ownerDocument.body,o=Di(r.scrollWidth,r.clientWidth,l.scrollWidth,l.clientWidth),u=Di(r.scrollHeight,r.clientHeight,l.scrollHeight,l.clientHeight);let c=-i.scrollLeft+bu(e);const f=-i.scrollTop;return Mn(l).direction==="rtl"&&(c+=Di(r.clientWidth,l.clientWidth)-o),{width:o,height:u,x:c,y:f}}const my=25;function e3(e,r){const i=un(e),l=er(e),o=i.visualViewport;let u=l.clientWidth,c=l.clientHeight,f=0,h=0;if(o){u=o.width,c=o.height;const g=du();(!g||g&&r==="fixed")&&(f=o.offsetLeft,h=o.offsetTop)}const p=bu(l);if(p<=0){const g=l.ownerDocument,b=g.body,v=getComputedStyle(b),x=g.compatMode==="CSS1Compat"&&parseFloat(v.marginLeft)+parseFloat(v.marginRight)||0,S=Math.abs(l.clientWidth-b.clientWidth-x);S<=my&&(u-=S)}else p<=my&&(u+=p);return{width:u,height:c,x:f,y:h}}function t3(e,r){const i=Mi(e,!0,r==="fixed"),l=i.top+e.clientTop,o=i.left+e.clientLeft,u=Rt(e)?Tl(e):Wn(1),c=e.clientWidth*u.x,f=e.clientHeight*u.y,h=o*u.x,p=l*u.y;return{width:c,height:f,x:h,y:p}}function gy(e,r,i){let l;if(r==="viewport")l=e3(e,i);else if(r==="document")l=WC(er(e));else if(ct(r))l=t3(r,i);else{const o=Z1(e);l={x:r.x-o.x,y:r.y-o.y,width:r.width,height:r.height}}return qs(l)}function Q1(e,r){const i=Cr(e);return i===r||!ct(i)||Er(i)?!1:Mn(i).position==="fixed"||Q1(i,r)}function n3(e,r){const i=r.get(e);if(i)return i;let l=si(e,[],!1).filter(f=>ct(f)&&ui(f)!=="body"),o=null;const u=Mn(e).position==="fixed";let c=u?Cr(e):e;for(;ct(c)&&!Er(c);){const f=Mn(c),h=Sh(c);!h&&f.position==="fixed"&&(o=null),(u?!h&&!o:!h&&f.position==="static"&&!!o&&(o.position==="absolute"||o.position==="fixed")||Ja(c)&&!h&&Q1(e,c))?l=l.filter(g=>g!==c):o=f,c=Cr(c)}return r.set(e,l),l}function r3(e){let{element:r,boundary:i,rootBoundary:l,strategy:o}=e;const c=[...i==="clippingAncestors"?fu(r)?[]:n3(r,this._c):[].concat(i),l],f=gy(r,c[0],o);let h=f.top,p=f.right,g=f.bottom,b=f.left;for(let v=1;v<c.length;v++){const x=gy(r,c[v],o);h=Di(x.top,h),p=Is(x.right,p),g=Is(x.bottom,g),b=Di(x.left,b)}return{width:p-b,height:g-h,x:b,y:h}}function i3(e){const{width:r,height:i}=X1(e);return{width:r,height:i}}function l3(e,r,i){const l=Rt(r),o=er(r),u=i==="fixed",c=Mi(e,!0,u,r);let f={scrollLeft:0,scrollTop:0};const h=Wn(0);function p(){h.x=bu(o)}if(l||!l&&!u)if((ui(r)!=="body"||Ja(o))&&(f=hu(r)),l){const x=Mi(r,!0,u,r);h.x=x.x+r.clientLeft,h.y=x.y+r.clientTop}else o&&p();u&&!l&&o&&p();const g=o&&!l&&!u?K1(o,f):Wn(0),b=c.left+f.scrollLeft-h.x-g.x,v=c.top+f.scrollTop-h.y-g.y;return{x:b,y:v,width:c.width,height:c.height}}function Vf(e){return Mn(e).position==="static"}function by(e,r){if(!Rt(e)||Mn(e).position==="fixed")return null;if(r)return r(e);let i=e.offsetParent;return er(e)===i&&(i=i.ownerDocument.body),i}function J1(e,r){const i=un(e);if(fu(e))return i;if(!Rt(e)){let o=Cr(e);for(;o&&!Er(o);){if(ct(o)&&!Vf(o))return o;o=Cr(o)}return i}let l=by(e,r);for(;l&&eC(l)&&Vf(l);)l=by(l,r);return l&&Er(l)&&Vf(l)&&!Sh(l)?i:l||rC(e)||i}const a3=async function(e){const r=this.getOffsetParent||J1,i=this.getDimensions,l=await i(e.floating);return{reference:l3(e.reference,await r(e.floating),e.strategy),floating:{x:0,y:0,width:l.width,height:l.height}}};function o3(e){return Mn(e).direction==="rtl"}const s3={convertOffsetParentRelativeRectToViewportRelativeRect:QC,getDocumentElement:er,getClippingRect:r3,getOffsetParent:J1,getElementRects:a3,getClientRects:JC,getDimensions:i3,getScale:Tl,isElement:ct,isRTL:o3};function W1(e,r){return e.x===r.x&&e.y===r.y&&e.width===r.width&&e.height===r.height}function u3(e,r){let i=null,l;const o=er(e);function u(){var f;clearTimeout(l),(f=i)==null||f.disconnect(),i=null}function c(f,h){f===void 0&&(f=!1),h===void 0&&(h=1),u();const p=e.getBoundingClientRect(),{left:g,top:b,width:v,height:x}=p;if(f||r(),!v||!x)return;const S=Ss(b),w=Ss(o.clientWidth-(g+v)),N=Ss(o.clientHeight-(b+x)),E=Ss(g),j={rootMargin:-S+"px "+-w+"px "+-N+"px "+-E+"px",threshold:Di(0,Is(1,h))||1};let z=!0;function I(L){const O=L[0].intersectionRatio;if(O!==h){if(!z)return c();O?c(!1,O):l=setTimeout(()=>{c(!1,1e-7)},1e3)}O===1&&!W1(p,e.getBoundingClientRect())&&c(),z=!1}try{i=new IntersectionObserver(I,{...j,root:o.ownerDocument})}catch{i=new IntersectionObserver(I,j)}i.observe(e)}return c(!0),u}function Md(e,r,i,l){l===void 0&&(l={});const{ancestorScroll:o=!0,ancestorResize:u=!0,elementResize:c=typeof ResizeObserver=="function",layoutShift:f=typeof IntersectionObserver=="function",animationFrame:h=!1}=l,p=Eh(e),g=o||u?[...p?si(p):[],...r?si(r):[]]:[];g.forEach(E=>{o&&E.addEventListener("scroll",i,{passive:!0}),u&&E.addEventListener("resize",i)});const b=p&&f?u3(p,i):null;let v=-1,x=null;c&&(x=new ResizeObserver(E=>{let[C]=E;C&&C.target===p&&x&&r&&(x.unobserve(r),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var j;(j=x)==null||j.observe(r)})),i()}),p&&!h&&x.observe(p),r&&x.observe(r));let S,w=h?Mi(e):null;h&&N();function N(){const E=Mi(e);w&&!W1(w,E)&&i(),w=E,S=requestAnimationFrame(N)}return i(),()=>{var E;g.forEach(C=>{o&&C.removeEventListener("scroll",i),u&&C.removeEventListener("resize",i)}),b?.(),(E=x)==null||E.disconnect(),x=null,h&&cancelAnimationFrame(S)}}const c3=YC,f3=XC,d3=PC,h3=(e,r,i)=>{const l=new Map,o={platform:s3,...i},u={...o.platform,_c:l};return $C(e,r,{...o,platform:u})};var p3=typeof document<"u",m3=function(){},Ls=p3?A.useLayoutEffect:m3;function Ys(e,r){if(e===r)return!0;if(typeof e!=typeof r)return!1;if(typeof e=="function"&&e.toString()===r.toString())return!0;let i,l,o;if(e&&r&&typeof e=="object"){if(Array.isArray(e)){if(i=e.length,i!==r.length)return!1;for(l=i;l--!==0;)if(!Ys(e[l],r[l]))return!1;return!0}if(o=Object.keys(e),i=o.length,i!==Object.keys(r).length)return!1;for(l=i;l--!==0;)if(!{}.hasOwnProperty.call(r,o[l]))return!1;for(l=i;l--!==0;){const u=o[l];if(!(u==="_owner"&&e.$$typeof)&&!Ys(e[u],r[u]))return!1}return!0}return e!==e&&r!==r}function e0(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function yy(e,r){const i=e0(e);return Math.round(r*i)/i}function Gf(e){const r=A.useRef(e);return Ls(()=>{r.current=e}),r}function g3(e){e===void 0&&(e={});const{placement:r="bottom",strategy:i="absolute",middleware:l=[],platform:o,elements:{reference:u,floating:c}={},transform:f=!0,whileElementsMounted:h,open:p}=e,[g,b]=A.useState({x:0,y:0,strategy:i,placement:r,middlewareData:{},isPositioned:!1}),[v,x]=A.useState(l);Ys(v,l)||x(l);const[S,w]=A.useState(null),[N,E]=A.useState(null),C=A.useCallback(M=>{M!==L.current&&(L.current=M,w(M))},[]),j=A.useCallback(M=>{M!==O.current&&(O.current=M,E(M))},[]),z=u||S,I=c||N,L=A.useRef(null),O=A.useRef(null),Z=A.useRef(g),$=h!=null,F=Gf(h),H=Gf(o),G=Gf(p),Q=A.useCallback(()=>{if(!L.current||!O.current)return;const M={placement:r,strategy:i,middleware:v};H.current&&(M.platform=H.current),h3(L.current,O.current,M).then(V=>{const R={...V,isPositioned:G.current!==!1};U.current&&!Ys(Z.current,R)&&(Z.current=R,Y1.flushSync(()=>{b(R)}))})},[v,r,i,H,G]);Ls(()=>{p===!1&&Z.current.isPositioned&&(Z.current.isPositioned=!1,b(M=>({...M,isPositioned:!1})))},[p]);const U=A.useRef(!1);Ls(()=>(U.current=!0,()=>{U.current=!1}),[]),Ls(()=>{if(z&&(L.current=z),I&&(O.current=I),z&&I){if(F.current)return F.current(z,I,Q);Q()}},[z,I,Q,F,$]);const Y=A.useMemo(()=>({reference:L,floating:O,setReference:C,setFloating:j}),[C,j]),B=A.useMemo(()=>({reference:z,floating:I}),[z,I]),X=A.useMemo(()=>{const M={position:i,left:0,top:0};if(!B.floating)return M;const V=yy(B.floating,g.x),R=yy(B.floating,g.y);return f?{...M,transform:"translate("+V+"px, "+R+"px)",...e0(B.floating)>=1.5&&{willChange:"transform"}}:{position:i,left:V,top:R}},[i,f,B.floating,g.x,g.y]);return A.useMemo(()=>({...g,update:Q,refs:Y,elements:B,floatingStyles:X}),[g,Q,Y,B,X])}const zd=(e,r)=>{const i=c3(e);return{name:i.name,fn:i.fn,options:[e,r]}},Fd=(e,r)=>{const i=f3(e);return{name:i.name,fn:i.fn,options:[e,r]}},Bd=(e,r)=>{const i=d3(e);return{name:i.name,fn:i.fn,options:[e,r]}},b3="data-floating-ui-focusable",xy="active",vy="selected",y3={...Qx};let wy=!1,x3=0;const Sy=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+x3++;function v3(){const[e,r]=A.useState(()=>wy?Sy():void 0);return sn(()=>{e==null&&r(Sy())},[]),A.useEffect(()=>{wy=!0},[]),e}const w3=y3.useId,Ch=w3||v3;function S3(){const e=new Map;return{emit(r,i){var l;(l=e.get(r))==null||l.forEach(o=>o(i))},on(r,i){e.has(r)||e.set(r,new Set),e.get(r).add(i)},off(r,i){var l;(l=e.get(r))==null||l.delete(i)}}}const k3=A.createContext(null),E3=A.createContext(null),Nh=()=>{var e;return((e=A.useContext(k3))==null?void 0:e.id)||null},yu=()=>A.useContext(E3);function zi(e){return"data-floating-ui-"+e}function Zt(e){e.current!==-1&&(clearTimeout(e.current),e.current=-1)}const ky=zi("safe-polygon");function Yf(e,r,i){if(i&&!Ga(i))return 0;if(typeof e=="number")return e;if(typeof e=="function"){const l=e();return typeof l=="number"?l:l?.[r]}return e?.[r]}function Xf(e){return typeof e=="function"?e():e}function Id(e,r){r===void 0&&(r={});const{open:i,onOpenChange:l,dataRef:o,events:u,elements:c}=e,{enabled:f=!0,delay:h=0,handleClose:p=null,mouseOnly:g=!1,restMs:b=0,move:v=!0}=r,x=yu(),S=Nh(),w=Li(p),N=Li(h),E=Li(i),C=Li(b),j=A.useRef(),z=A.useRef(-1),I=A.useRef(),L=A.useRef(-1),O=A.useRef(!0),Z=A.useRef(!1),$=A.useRef(()=>{}),F=A.useRef(!1),H=on(()=>{var X;const M=(X=o.current.openEvent)==null?void 0:X.type;return M?.includes("mouse")&&M!=="mousedown"});A.useEffect(()=>{if(!f)return;function X(M){let{open:V}=M;V||(Zt(z),Zt(L),O.current=!0,F.current=!1)}return u.on("openchange",X),()=>{u.off("openchange",X)}},[f,u]),A.useEffect(()=>{if(!f||!w.current||!i)return;function X(V){H()&&l(!1,V,"hover")}const M=$t(c.floating).documentElement;return M.addEventListener("mouseleave",X),()=>{M.removeEventListener("mouseleave",X)}},[c.floating,i,l,f,w,H]);const G=A.useCallback(function(X,M,V){M===void 0&&(M=!0),V===void 0&&(V="hover");const R=Yf(N.current,"close",j.current);R&&!I.current?(Zt(z),z.current=window.setTimeout(()=>l(!1,X,V),R)):M&&(Zt(z),l(!1,X,V))},[N,l]),Q=on(()=>{$.current(),I.current=void 0}),U=on(()=>{if(Z.current){const X=$t(c.floating).body;X.style.pointerEvents="",X.removeAttribute(ky),Z.current=!1}}),Y=on(()=>o.current.openEvent?["click","mousedown"].includes(o.current.openEvent.type):!1);A.useEffect(()=>{if(!f)return;function X(q){if(Zt(z),O.current=!1,g&&!Ga(j.current)||Xf(C.current)>0&&!Yf(N.current,"open"))return;const T=Yf(N.current,"open",j.current);T?z.current=window.setTimeout(()=>{E.current||l(!0,q,"hover")},T):i||l(!0,q,"hover")}function M(q){if(Y()){U();return}$.current();const T=$t(c.floating);if(Zt(L),F.current=!1,w.current&&o.current.floatingContext){i||Zt(z),I.current=w.current({...o.current.floatingContext,tree:x,x:q.clientX,y:q.clientY,onClose(){U(),Q(),Y()||G(q,!0,"safe-polygon")}});const ie=I.current;T.addEventListener("mousemove",ie),$.current=()=>{T.removeEventListener("mousemove",ie)};return}(j.current!=="touch"||!qt(c.floating,q.relatedTarget))&&G(q)}function V(q){Y()||o.current.floatingContext&&(w.current==null||w.current({...o.current.floatingContext,tree:x,x:q.clientX,y:q.clientY,onClose(){U(),Q(),Y()||G(q)}})(q))}function R(){Zt(z)}function D(q){Y()||G(q,!1)}if(ct(c.domReference)){const q=c.domReference,T=c.floating;return i&&q.addEventListener("mouseleave",V),v&&q.addEventListener("mousemove",X,{once:!0}),q.addEventListener("mouseenter",X),q.addEventListener("mouseleave",M),T&&(T.addEventListener("mouseleave",V),T.addEventListener("mouseenter",R),T.addEventListener("mouseleave",D)),()=>{i&&q.removeEventListener("mouseleave",V),v&&q.removeEventListener("mousemove",X),q.removeEventListener("mouseenter",X),q.removeEventListener("mouseleave",M),T&&(T.removeEventListener("mouseleave",V),T.removeEventListener("mouseenter",R),T.removeEventListener("mouseleave",D))}}},[c,f,e,g,v,G,Q,U,l,i,E,x,N,w,o,Y,C]),sn(()=>{var X;if(f&&i&&(X=w.current)!=null&&(X=X.__options)!=null&&X.blockPointerEvents&&H()){Z.current=!0;const V=c.floating;if(ct(c.domReference)&&V){var M;const R=$t(c.floating).body;R.setAttribute(ky,"");const D=c.domReference,q=x==null||(M=x.nodesRef.current.find(T=>T.id===S))==null||(M=M.context)==null?void 0:M.elements.floating;return q&&(q.style.pointerEvents=""),R.style.pointerEvents="none",D.style.pointerEvents="auto",V.style.pointerEvents="auto",()=>{R.style.pointerEvents="",D.style.pointerEvents="",V.style.pointerEvents=""}}}},[f,i,S,c,x,w,H]),sn(()=>{i||(j.current=void 0,F.current=!1,Q(),U())},[i,Q,U]),A.useEffect(()=>()=>{Q(),Zt(z),Zt(L),U()},[f,c.domReference,Q,U]);const B=A.useMemo(()=>{function X(M){j.current=M.pointerType}return{onPointerDown:X,onPointerEnter:X,onMouseMove(M){const{nativeEvent:V}=M;function R(){!O.current&&!E.current&&l(!0,V,"hover")}g&&!Ga(j.current)||i||Xf(C.current)===0||F.current&&M.movementX**2+M.movementY**2<2||(Zt(L),j.current==="touch"?R():(F.current=!0,L.current=window.setTimeout(R,Xf(C.current))))}}},[g,l,i,E,C]);return A.useMemo(()=>f?{reference:B}:{},[f,B])}let Ey=0;function wl(e,r){r===void 0&&(r={});const{preventScroll:i=!1,cancelPrevious:l=!0,sync:o=!1}=r;l&&cancelAnimationFrame(Ey);const u=()=>e?.focus({preventScroll:i});o?u():Ey=requestAnimationFrame(u)}function Zf(e,r){if(!e||!r)return!1;const i=r.getRootNode==null?void 0:r.getRootNode();if(e.contains(r))return!0;if(i&&Bs(i)){let l=r;for(;l;){if(e===l)return!0;l=l.parentNode||l.host}}return!1}function C3(e){return"composedPath"in e?e.composedPath()[0]:e.target}function N3(e){return e?.ownerDocument||document}const jl={inert:new WeakMap,"aria-hidden":new WeakMap,none:new WeakMap};function Cy(e){return e==="inert"?jl.inert:e==="aria-hidden"?jl["aria-hidden"]:jl.none}let ks=new WeakSet,Es={},Kf=0;const A3=()=>typeof HTMLElement<"u"&&"inert"in HTMLElement.prototype,t0=e=>e&&(e.host||t0(e.parentNode)),T3=(e,r)=>r.map(i=>{if(e.contains(i))return i;const l=t0(i);return e.contains(l)?l:null}).filter(i=>i!=null);function j3(e,r,i,l){const o="data-floating-ui-inert",u=l?"inert":i?"aria-hidden":null,c=T3(r,e),f=new Set,h=new Set(c),p=[];Es[o]||(Es[o]=new WeakMap);const g=Es[o];c.forEach(b),v(r),f.clear();function b(x){!x||f.has(x)||(f.add(x),x.parentNode&&b(x.parentNode))}function v(x){!x||h.has(x)||[].forEach.call(x.children,S=>{if(ui(S)!=="script")if(f.has(S))v(S);else{const w=u?S.getAttribute(u):null,N=w!==null&&w!=="false",E=Cy(u),C=(E.get(S)||0)+1,j=(g.get(S)||0)+1;E.set(S,C),g.set(S,j),p.push(S),C===1&&N&&ks.add(S),j===1&&S.setAttribute(o,""),!N&&u&&S.setAttribute(u,u==="inert"?"":"true")}})}return Kf++,()=>{p.forEach(x=>{const S=Cy(u),N=(S.get(x)||0)-1,E=(g.get(x)||0)-1;S.set(x,N),g.set(x,E),N||(!ks.has(x)&&u&&x.removeAttribute(u),ks.delete(x)),E||x.removeAttribute(o)}),Kf--,Kf||(jl.inert=new WeakMap,jl["aria-hidden"]=new WeakMap,jl.none=new WeakMap,ks=new WeakSet,Es={})}}function Ny(e,r,i){r===void 0&&(r=!1),i===void 0&&(i=!1);const l=N3(e[0]).body;return j3(e.concat(Array.from(l.querySelectorAll('[aria-live],[role="status"],output'))),l,r,i)}const Ah={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0},Xs=A.forwardRef(function(r,i){const[l,o]=A.useState();sn(()=>{q1()&&o("button")},[]);const u={ref:i,tabIndex:0,role:l,"aria-hidden":l?void 0:!0,[zi("focus-guard")]:"",style:Ah};return y.jsx("span",{...r,...u})}),R3={clipPath:"inset(50%)",position:"fixed",top:0,left:0},n0=A.createContext(null),Ay=zi("portal");function _3(e){e===void 0&&(e={});const{id:r,root:i}=e,l=Ch(),o=r0(),[u,c]=A.useState(null),f=A.useRef(null);return sn(()=>()=>{u?.remove(),queueMicrotask(()=>{f.current=null})},[u]),sn(()=>{if(!l||f.current)return;const h=r?document.getElementById(r):null;if(!h)return;const p=document.createElement("div");p.id=l,p.setAttribute(Ay,""),h.appendChild(p),f.current=p,c(p)},[r,l]),sn(()=>{if(i===null||!l||f.current)return;let h=i||o?.portalNode;h&&!wh(h)&&(h=h.current),h=h||document.body;let p=null;r&&(p=document.createElement("div"),p.id=r,h.appendChild(p));const g=document.createElement("div");g.id=l,g.setAttribute(Ay,""),h=p||h,h.appendChild(g),f.current=g,c(g)},[r,i,l,o]),u}function Ud(e){const{children:r,id:i,root:l,preserveTabOrder:o=!0}=e,u=_3({id:i,root:l}),[c,f]=A.useState(null),h=A.useRef(null),p=A.useRef(null),g=A.useRef(null),b=A.useRef(null),v=c?.modal,x=c?.open,S=!!c&&!c.modal&&c.open&&o&&!!(l||u);return A.useEffect(()=>{if(!u||!o||v)return;function w(N){u&&Ba(N)&&(N.type==="focusin"?hy:UC)(u)}return u.addEventListener("focusin",w,!0),u.addEventListener("focusout",w,!0),()=>{u.removeEventListener("focusin",w,!0),u.removeEventListener("focusout",w,!0)}},[u,o,v]),A.useEffect(()=>{u&&(x||hy(u))},[x,u]),y.jsxs(n0.Provider,{value:A.useMemo(()=>({preserveTabOrder:o,beforeOutsideRef:h,afterOutsideRef:p,beforeInsideRef:g,afterInsideRef:b,portalNode:u,setFocusManagerState:f}),[o,u]),children:[S&&u&&y.jsx(Xs,{"data-type":"outside",ref:h,onFocus:w=>{if(Ba(w,u)){var N;(N=g.current)==null||N.focus()}else{const E=c?c.domReference:null,C=G1(E);C?.focus()}}}),S&&u&&y.jsx("span",{"aria-owns":u.id,style:R3}),u&&Y1.createPortal(r,u),S&&u&&y.jsx(Xs,{"data-type":"outside",ref:p,onFocus:w=>{if(Ba(w,u)){var N;(N=b.current)==null||N.focus()}else{const E=c?c.domReference:null,C=V1(E);C?.focus(),c?.closeOnFocusOut&&c?.onOpenChange(!1,w.nativeEvent,"focus-out")}}})]})}const r0=()=>A.useContext(n0);function Ty(e){return A.useMemo(()=>r=>{e.forEach(i=>{i&&(i.current=r)})},e)}const L3=20;let ai=[];function Th(){ai=ai.filter(e=>{var r;return(r=e.deref())==null?void 0:r.isConnected})}function D3(e){Th(),e&&ui(e)!=="body"&&(ai.push(new WeakRef(e)),ai.length>L3&&(ai=ai.slice(-20)))}function jy(){Th();const e=ai[ai.length-1];return e?.deref()}function O3(e){const r=Wa();return I1(e,r)?e:gu(e,r)[0]||e}function Ry(e,r){var i;if(!r.current.includes("floating")&&!((i=e.getAttribute("role"))!=null&&i.includes("dialog")))return;const l=Wa(),u=AC(e,l).filter(f=>{const h=f.getAttribute("data-tabindex")||"";return I1(f,l)||f.hasAttribute("data-tabindex")&&!h.startsWith("-")}),c=e.getAttribute("tabindex");r.current.includes("floating")||u.length===0?c!=="0"&&e.setAttribute("tabindex","0"):(c!=="-1"||e.hasAttribute("data-tabindex")&&e.getAttribute("data-tabindex")!=="-1")&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}const M3=A.forwardRef(function(r,i){return y.jsx("button",{...r,type:"button",ref:i,tabIndex:-1,style:Ah})});function z3(e){const{context:r,children:i,disabled:l=!1,order:o=["content"],guards:u=!0,initialFocus:c=0,returnFocus:f=!0,restoreFocus:h=!1,modal:p=!0,visuallyHiddenDismiss:g=!1,closeOnFocusOut:b=!0,outsideElementsInert:v=!1,getInsideElements:x=()=>[]}=e,{open:S,onOpenChange:w,events:N,dataRef:E,elements:{domReference:C,floating:j}}=r,z=on(()=>{var de;return(de=E.current.floatingContext)==null?void 0:de.nodeId}),I=on(x),L=typeof c=="number"&&c<0,O=fy(C)&&L,Z=A3(),$=Z?u:!0,F=!$||Z&&v,H=Li(o),G=Li(c),Q=Li(f),U=yu(),Y=r0(),B=A.useRef(null),X=A.useRef(null),M=A.useRef(!1),V=A.useRef(!1),R=A.useRef(-1),D=A.useRef(-1),q=Y!=null,T=Od(j),te=on(function(de){return de===void 0&&(de=T),de?gu(de,Wa()):[]}),ie=on(de=>{const we=te(de);return H.current.map(Ee=>C&&Ee==="reference"?C:T&&Ee==="floating"?T:we).filter(Boolean).flat()});A.useEffect(()=>{if(l||!p)return;function de(Ee){if(Ee.key==="Tab"){qt(T,ii($t(T)))&&te().length===0&&!O&&Pf(Ee);const Pe=ie(),Ke=Sr(Ee);H.current[0]==="reference"&&Ke===C&&(Pf(Ee),Ee.shiftKey?wl(Pe[Pe.length-1]):wl(Pe[1])),H.current[1]==="floating"&&Ke===T&&Ee.shiftKey&&(Pf(Ee),wl(Pe[0]))}}const we=$t(T);return we.addEventListener("keydown",de),()=>{we.removeEventListener("keydown",de)}},[l,C,T,p,H,O,te,ie]),A.useEffect(()=>{if(l||!j)return;function de(we){const Ee=Sr(we),Ke=te().indexOf(Ee);Ke!==-1&&(R.current=Ke)}return j.addEventListener("focusin",de),()=>{j.removeEventListener("focusin",de)}},[l,j,te]),A.useEffect(()=>{if(l||!b)return;function de(){V.current=!0,setTimeout(()=>{V.current=!1})}function we(Ke){const Me=Ke.relatedTarget,It=Ke.currentTarget,pt=Sr(Ke);queueMicrotask(()=>{const mt=z(),Gt=!(qt(C,Me)||qt(j,Me)||qt(Me,j)||qt(Y?.portalNode,Me)||Me!=null&&Me.hasAttribute(zi("focus-guard"))||U&&(Al(U.nodesRef.current,mt).find(Yt=>{var tt,at;return qt((tt=Yt.context)==null?void 0:tt.elements.floating,Me)||qt((at=Yt.context)==null?void 0:at.elements.domReference,Me)})||dy(U.nodesRef.current,mt).find(Yt=>{var tt,at,nr;return[(tt=Yt.context)==null?void 0:tt.elements.floating,Od((at=Yt.context)==null?void 0:at.elements.floating)].includes(Me)||((nr=Yt.context)==null?void 0:nr.elements.domReference)===Me})));if(It===C&&T&&Ry(T,H),h&&It!==C&&!(pt!=null&&pt.isConnected)&&ii($t(T))===$t(T).body){Rt(T)&&T.focus();const Yt=R.current,tt=te(),at=tt[Yt]||tt[tt.length-1]||T;Rt(at)&&at.focus()}if(E.current.insideReactTree){E.current.insideReactTree=!1;return}(O||!p)&&Me&&Gt&&!V.current&&Me!==jy()&&(M.current=!0,w(!1,Ke,"focus-out"))})}const Ee=!!(!U&&Y);function Pe(){Zt(D),E.current.insideReactTree=!0,D.current=window.setTimeout(()=>{E.current.insideReactTree=!1})}if(j&&Rt(C))return C.addEventListener("focusout",we),C.addEventListener("pointerdown",de),j.addEventListener("focusout",we),Ee&&j.addEventListener("focusout",Pe,!0),()=>{C.removeEventListener("focusout",we),C.removeEventListener("pointerdown",de),j.removeEventListener("focusout",we),Ee&&j.removeEventListener("focusout",Pe,!0)}},[l,C,j,T,p,U,Y,w,b,h,te,O,z,H,E]);const fe=A.useRef(null),ge=A.useRef(null),ye=Ty([fe,Y?.beforeInsideRef]),pe=Ty([ge,Y?.afterInsideRef]);A.useEffect(()=>{var de,we;if(l||!j)return;const Ee=Array.from((Y==null||(de=Y.portalNode)==null?void 0:de.querySelectorAll("["+zi("portal")+"]"))||[]),Ke=(we=(U?dy(U.nodesRef.current,z()):[]).find(pt=>{var mt;return fy(((mt=pt.context)==null?void 0:mt.elements.domReference)||null)}))==null||(we=we.context)==null?void 0:we.elements.domReference,Me=[j,Ke,...Ee,...I(),B.current,X.current,fe.current,ge.current,Y?.beforeOutsideRef.current,Y?.afterOutsideRef.current,H.current.includes("reference")||O?C:null].filter(pt=>pt!=null),It=p||O?Ny(Me,!F,F):Ny(Me);return()=>{It()}},[l,C,j,p,H,Y,O,$,F,U,z,I]),sn(()=>{if(l||!Rt(T))return;const de=$t(T),we=ii(de);queueMicrotask(()=>{const Ee=ie(T),Pe=G.current,Ke=(typeof Pe=="number"?Ee[Pe]:Pe.current)||T,Me=qt(T,we);!L&&!Me&&S&&wl(Ke,{preventScroll:Ke===T})})},[l,S,T,L,ie,G]),sn(()=>{if(l||!T)return;const de=$t(T),we=ii(de);D3(we);function Ee(Me){let{reason:It,event:pt,nested:mt}=Me;if(["hover","safe-polygon"].includes(It)&&pt.type==="mouseleave"&&(M.current=!0),It==="outside-press")if(mt)M.current=!1;else if(DC(pt)||OC(pt))M.current=!1;else{let Gt=!1;document.createElement("div").focus({get preventScroll(){return Gt=!0,!1}}),Gt?M.current=!1:M.current=!0}}N.on("openchange",Ee);const Pe=de.createElement("span");Pe.setAttribute("tabindex","-1"),Pe.setAttribute("aria-hidden","true"),Object.assign(Pe.style,Ah),q&&C&&C.insertAdjacentElement("afterend",Pe);function Ke(){if(typeof Q.current=="boolean"){const Me=C||jy();return Me&&Me.isConnected?Me:Pe}return Q.current.current||Pe}return()=>{N.off("openchange",Ee);const Me=ii(de),It=qt(j,Me)||U&&Al(U.nodesRef.current,z(),!1).some(mt=>{var Gt;return qt((Gt=mt.context)==null?void 0:Gt.elements.floating,Me)}),pt=Ke();queueMicrotask(()=>{const mt=O3(pt);Q.current&&!M.current&&Rt(mt)&&(!(mt!==Me&&Me!==de.body)||It)&&mt.focus({preventScroll:!0}),Pe.remove()})}},[l,j,T,Q,E,N,U,q,C,z]),A.useEffect(()=>(queueMicrotask(()=>{M.current=!1}),()=>{queueMicrotask(Th)}),[l]),sn(()=>{if(!l&&Y)return Y.setFocusManagerState({modal:p,closeOnFocusOut:b,open:S,onOpenChange:w,domReference:C}),()=>{Y.setFocusManagerState(null)}},[l,Y,p,S,w,b,C]),sn(()=>{l||T&&Ry(T,H)},[l,T,H]);function me(de){return l||!g||!p?null:y.jsx(M3,{ref:de==="start"?B:X,onClick:we=>w(!1,we.nativeEvent),children:typeof g=="string"?g:"Dismiss"})}const xe=!l&&$&&(p?!O:!0)&&(q||p);return y.jsxs(y.Fragment,{children:[xe&&y.jsx(Xs,{"data-type":"inside",ref:ye,onFocus:de=>{if(p){const Ee=ie();wl(o[0]==="reference"?Ee[0]:Ee[Ee.length-1])}else if(Y!=null&&Y.preserveTabOrder&&Y.portalNode)if(M.current=!1,Ba(de,Y.portalNode)){const Ee=V1(C);Ee?.focus()}else{var we;(we=Y.beforeOutsideRef.current)==null||we.focus()}}}),!O&&me("start"),i,me("end"),xe&&y.jsx(Xs,{"data-type":"inside",ref:pe,onFocus:de=>{if(p)wl(ie()[0]);else if(Y!=null&&Y.preserveTabOrder&&Y.portalNode)if(b&&(M.current=!0),Ba(de,Y.portalNode)){const Ee=G1(C);Ee?.focus()}else{var we;(we=Y.afterOutsideRef.current)==null||we.focus()}}})]})}function _y(e){return Rt(e.target)&&e.target.tagName==="BUTTON"}function F3(e){return Rt(e.target)&&e.target.tagName==="A"}function Ly(e){return kh(e)}function Hd(e,r){r===void 0&&(r={});const{open:i,onOpenChange:l,dataRef:o,elements:{domReference:u}}=e,{enabled:c=!0,event:f="click",toggle:h=!0,ignoreMouse:p=!1,keyboardHandlers:g=!0,stickIfOpen:b=!0}=r,v=A.useRef(),x=A.useRef(!1),S=A.useMemo(()=>({onPointerDown(w){v.current=w.pointerType},onMouseDown(w){const N=v.current;w.button===0&&f!=="click"&&(Ga(N,!0)&&p||(i&&h&&(!(o.current.openEvent&&b)||o.current.openEvent.type==="mousedown")?l(!1,w.nativeEvent,"click"):(w.preventDefault(),l(!0,w.nativeEvent,"click"))))},onClick(w){const N=v.current;if(f==="mousedown"&&v.current){v.current=void 0;return}Ga(N,!0)&&p||(i&&h&&(!(o.current.openEvent&&b)||o.current.openEvent.type==="click")?l(!1,w.nativeEvent,"click"):l(!0,w.nativeEvent,"click"))},onKeyDown(w){v.current=void 0,!(w.defaultPrevented||!g||_y(w))&&(w.key===" "&&!Ly(u)&&(w.preventDefault(),x.current=!0),!F3(w)&&w.key==="Enter"&&l(!(i&&h),w.nativeEvent,"click"))},onKeyUp(w){w.defaultPrevented||!g||_y(w)||Ly(u)||w.key===" "&&x.current&&(x.current=!1,l(!(i&&h),w.nativeEvent,"click"))}}),[o,u,f,p,g,l,i,b,h]);return A.useMemo(()=>c?{reference:S}:{},[c,S])}const B3={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},I3={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},Dy=e=>{var r,i;return{escapeKey:typeof e=="boolean"?e:(r=e?.escapeKey)!=null?r:!1,outsidePress:typeof e=="boolean"?e:(i=e?.outsidePress)!=null?i:!0}};function qd(e,r){r===void 0&&(r={});const{open:i,onOpenChange:l,elements:o,dataRef:u}=e,{enabled:c=!0,escapeKey:f=!0,outsidePress:h=!0,outsidePressEvent:p="pointerdown",referencePress:g=!1,referencePressEvent:b="pointerdown",ancestorScroll:v=!1,bubbles:x,capture:S}=r,w=yu(),N=on(typeof h=="function"?h:()=>!1),E=typeof h=="function"?N:h,C=A.useRef(!1),{escapeKey:j,outsidePress:z}=Dy(x),{escapeKey:I,outsidePress:L}=Dy(S),O=A.useRef(!1),Z=on(U=>{var Y;if(!i||!c||!f||U.key!=="Escape"||O.current)return;const B=(Y=u.current.floatingContext)==null?void 0:Y.nodeId,X=w?Al(w.nodesRef.current,B):[];if(!j&&(U.stopPropagation(),X.length>0)){let M=!0;if(X.forEach(V=>{var R;if((R=V.context)!=null&&R.open&&!V.context.dataRef.current.__escapeKeyBubbles){M=!1;return}}),!M)return}l(!1,LC(U)?U.nativeEvent:U,"escape-key")}),$=on(U=>{var Y;const B=()=>{var X;Z(U),(X=Sr(U))==null||X.removeEventListener("keydown",B)};(Y=Sr(U))==null||Y.addEventListener("keydown",B)}),F=on(U=>{var Y;const B=u.current.insideReactTree;u.current.insideReactTree=!1;const X=C.current;if(C.current=!1,p==="click"&&X||B||typeof E=="function"&&!E(U))return;const M=Sr(U),V="["+zi("inert")+"]",R=$t(o.floating).querySelectorAll(V);let D=ct(M)?M:null;for(;D&&!Er(D);){const ie=Cr(D);if(Er(ie)||!ct(ie))break;D=ie}if(R.length&&ct(M)&&!RC(M)&&!qt(M,o.floating)&&Array.from(R).every(ie=>!qt(D,ie)))return;if(Rt(M)&&Q){const ie=Er(M),fe=Mn(M),ge=/auto|scroll/,ye=ie||ge.test(fe.overflowX),pe=ie||ge.test(fe.overflowY),me=ye&&M.clientWidth>0&&M.scrollWidth>M.clientWidth,xe=pe&&M.clientHeight>0&&M.scrollHeight>M.clientHeight,de=fe.direction==="rtl",we=xe&&(de?U.offsetX<=M.offsetWidth-M.clientWidth:U.offsetX>M.clientWidth),Ee=me&&U.offsetY>M.clientHeight;if(we||Ee)return}const q=(Y=u.current.floatingContext)==null?void 0:Y.nodeId,T=w&&Al(w.nodesRef.current,q).some(ie=>{var fe;return $f(U,(fe=ie.context)==null?void 0:fe.elements.floating)});if($f(U,o.floating)||$f(U,o.domReference)||T)return;const te=w?Al(w.nodesRef.current,q):[];if(te.length>0){let ie=!0;if(te.forEach(fe=>{var ge;if((ge=fe.context)!=null&&ge.open&&!fe.context.dataRef.current.__outsidePressBubbles){ie=!1;return}}),!ie)return}l(!1,U,"outside-press")}),H=on(U=>{var Y;const B=()=>{var X;F(U),(X=Sr(U))==null||X.removeEventListener(p,B)};(Y=Sr(U))==null||Y.addEventListener(p,B)});A.useEffect(()=>{if(!i||!c)return;u.current.__escapeKeyBubbles=j,u.current.__outsidePressBubbles=z;let U=-1;function Y(R){l(!1,R,"ancestor-scroll")}function B(){window.clearTimeout(U),O.current=!0}function X(){U=window.setTimeout(()=>{O.current=!1},du()?5:0)}const M=$t(o.floating);f&&(M.addEventListener("keydown",I?$:Z,I),M.addEventListener("compositionstart",B),M.addEventListener("compositionend",X)),E&&M.addEventListener(p,L?H:F,L);let V=[];return v&&(ct(o.domReference)&&(V=si(o.domReference)),ct(o.floating)&&(V=V.concat(si(o.floating))),!ct(o.reference)&&o.reference&&o.reference.contextElement&&(V=V.concat(si(o.reference.contextElement)))),V=V.filter(R=>{var D;return R!==((D=M.defaultView)==null?void 0:D.visualViewport)}),V.forEach(R=>{R.addEventListener("scroll",Y,{passive:!0})}),()=>{f&&(M.removeEventListener("keydown",I?$:Z,I),M.removeEventListener("compositionstart",B),M.removeEventListener("compositionend",X)),E&&M.removeEventListener(p,L?H:F,L),V.forEach(R=>{R.removeEventListener("scroll",Y)}),window.clearTimeout(U)}},[u,o,f,E,p,i,l,v,c,j,z,Z,I,$,F,L,H]),A.useEffect(()=>{u.current.insideReactTree=!1},[u,E,p]);const G=A.useMemo(()=>({onKeyDown:Z,...g&&{[B3[b]]:U=>{l(!1,U.nativeEvent,"reference-press")},...b!=="click"&&{onClick(U){l(!1,U.nativeEvent,"reference-press")}}}}),[Z,l,g,b]),Q=A.useMemo(()=>({onKeyDown:Z,onMouseDown(){C.current=!0},onMouseUp(){C.current=!0},[I3[p]]:()=>{u.current.insideReactTree=!0}}),[Z,p,u]);return A.useMemo(()=>c?{reference:G,floating:Q}:{},[c,G,Q])}function U3(e){const{open:r=!1,onOpenChange:i,elements:l}=e,o=Ch(),u=A.useRef({}),[c]=A.useState(()=>S3()),f=Nh()!=null,[h,p]=A.useState(l.reference),g=on((x,S,w)=>{u.current.openEvent=x?S:void 0,c.emit("openchange",{open:x,event:S,reason:w,nested:f}),i?.(x,S,w)}),b=A.useMemo(()=>({setPositionReference:p}),[]),v=A.useMemo(()=>({reference:h||l.reference||null,floating:l.floating||null,domReference:l.reference}),[h,l.reference,l.floating]);return A.useMemo(()=>({dataRef:u,open:r,onOpenChange:g,elements:v,events:c,floatingId:o,refs:b}),[r,g,v,c,o,b])}function $d(e){e===void 0&&(e={});const{nodeId:r}=e,i=U3({...e,elements:{reference:null,floating:null,...e.elements}}),l=e.rootContext||i,o=l.elements,[u,c]=A.useState(null),[f,h]=A.useState(null),g=o?.domReference||u,b=A.useRef(null),v=yu();sn(()=>{g&&(b.current=g)},[g]);const x=g3({...e,elements:{...o,...f&&{reference:f}}}),S=A.useCallback(j=>{const z=ct(j)?{getBoundingClientRect:()=>j.getBoundingClientRect(),getClientRects:()=>j.getClientRects(),contextElement:j}:j;h(z),x.refs.setReference(z)},[x.refs]),w=A.useCallback(j=>{(ct(j)||j===null)&&(b.current=j,c(j)),(ct(x.refs.reference.current)||x.refs.reference.current===null||j!==null&&!ct(j))&&x.refs.setReference(j)},[x.refs]),N=A.useMemo(()=>({...x.refs,setReference:w,setPositionReference:S,domReference:b}),[x.refs,w,S]),E=A.useMemo(()=>({...x.elements,domReference:g}),[x.elements,g]),C=A.useMemo(()=>({...x,...l,refs:N,elements:E,nodeId:r}),[x,N,E,r,l]);return sn(()=>{l.dataRef.current.floatingContext=C;const j=v?.nodesRef.current.find(z=>z.id===r);j&&(j.context=C)}),A.useMemo(()=>({...x,context:C,refs:N,elements:E}),[x,N,E,C])}function Qf(){return TC()&&q1()}function H3(e,r){r===void 0&&(r={});const{open:i,onOpenChange:l,events:o,dataRef:u,elements:c}=e,{enabled:f=!0,visibleOnly:h=!0}=r,p=A.useRef(!1),g=A.useRef(-1),b=A.useRef(!0);A.useEffect(()=>{if(!f)return;const x=un(c.domReference);function S(){!i&&Rt(c.domReference)&&c.domReference===ii($t(c.domReference))&&(p.current=!0)}function w(){b.current=!0}function N(){b.current=!1}return x.addEventListener("blur",S),Qf()&&(x.addEventListener("keydown",w,!0),x.addEventListener("pointerdown",N,!0)),()=>{x.removeEventListener("blur",S),Qf()&&(x.removeEventListener("keydown",w,!0),x.removeEventListener("pointerdown",N,!0))}},[c.domReference,i,f]),A.useEffect(()=>{if(!f)return;function x(S){let{reason:w}=S;(w==="reference-press"||w==="escape-key")&&(p.current=!0)}return o.on("openchange",x),()=>{o.off("openchange",x)}},[o,f]),A.useEffect(()=>()=>{Zt(g)},[]);const v=A.useMemo(()=>({onMouseLeave(){p.current=!1},onFocus(x){if(p.current)return;const S=Sr(x.nativeEvent);if(h&&ct(S)){if(Qf()&&!x.relatedTarget){if(!b.current&&!kh(S))return}else if(!_C(S))return}l(!0,x.nativeEvent,"focus")},onBlur(x){p.current=!1;const S=x.relatedTarget,w=x.nativeEvent,N=ct(S)&&S.hasAttribute(zi("focus-guard"))&&S.getAttribute("data-type")==="outside";g.current=window.setTimeout(()=>{var E;const C=ii(c.domReference?c.domReference.ownerDocument:document);!S&&C===c.domReference||qt((E=u.current.floatingContext)==null?void 0:E.refs.floating.current,C)||qt(c.domReference,C)||N||l(!1,w,"focus")})}}),[u,c.domReference,l,h]);return A.useMemo(()=>f?{reference:v}:{},[f,v])}function Jf(e,r,i){const l=new Map,o=i==="item";let u=e;if(o&&e){const{[xy]:c,[vy]:f,...h}=e;u=h}return{...i==="floating"&&{tabIndex:-1,[b3]:""},...u,...r.map(c=>{const f=c?c[i]:null;return typeof f=="function"?e?f(e):null:f}).concat(e).reduce((c,f)=>(f&&Object.entries(f).forEach(h=>{let[p,g]=h;if(!(o&&[xy,vy].includes(p)))if(p.indexOf("on")===0){if(l.has(p)||l.set(p,[]),typeof g=="function"){var b;(b=l.get(p))==null||b.push(g),c[p]=function(){for(var v,x=arguments.length,S=new Array(x),w=0;w<x;w++)S[w]=arguments[w];return(v=l.get(p))==null?void 0:v.map(N=>N(...S)).find(N=>N!==void 0)}}}else c[p]=g}),c),{})}}function Pd(e){e===void 0&&(e=[]);const r=e.map(f=>f?.reference),i=e.map(f=>f?.floating),l=e.map(f=>f?.item),o=A.useCallback(f=>Jf(f,e,"reference"),r),u=A.useCallback(f=>Jf(f,e,"floating"),i),c=A.useCallback(f=>Jf(f,e,"item"),l);return A.useMemo(()=>({getReferenceProps:o,getFloatingProps:u,getItemProps:c}),[o,u,c])}const q3=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function Vd(e,r){var i,l;r===void 0&&(r={});const{open:o,elements:u,floatingId:c}=e,{enabled:f=!0,role:h="dialog"}=r,p=Ch(),g=((i=u.domReference)==null?void 0:i.id)||p,b=A.useMemo(()=>{var C;return((C=Od(u.floating))==null?void 0:C.id)||c},[u.floating,c]),v=(l=q3.get(h))!=null?l:h,S=Nh()!=null,w=A.useMemo(()=>v==="tooltip"||h==="label"?{["aria-"+(h==="label"?"labelledby":"describedby")]:o?b:void 0}:{"aria-expanded":o?"true":"false","aria-haspopup":v==="alertdialog"?"dialog":v,"aria-controls":o?b:void 0,...v==="listbox"&&{role:"combobox"},...v==="menu"&&{id:g},...v==="menu"&&S&&{role:"menuitem"},...h==="select"&&{"aria-autocomplete":"none"},...h==="combobox"&&{"aria-autocomplete":"list"}},[v,b,S,o,g,h]),N=A.useMemo(()=>{const C={id:b,...v&&{role:v}};return v==="tooltip"||h==="label"?C:{...C,...v==="menu"&&{"aria-labelledby":g}}},[v,b,g,h]),E=A.useCallback(C=>{let{active:j,selected:z}=C;const I={role:"option",...j&&{id:b+"-fui-option"}};switch(h){case"select":case"combobox":return{...I,"aria-selected":z}}return{}},[b,h]);return A.useMemo(()=>f?{reference:w,floating:N,item:E}:{},[f,w,N,E])}function i0(e,r,i){return i===void 0&&(i=!0),e.filter(o=>{var u;return o.parentId===r&&(!i||((u=o.context)==null?void 0:u.open))}).flatMap(o=>[o,...i0(e,o.id,i)])}function Oy(e,r){const[i,l]=e;let o=!1;const u=r.length;for(let c=0,f=u-1;c<u;f=c++){const[h,p]=r[c]||[0,0],[g,b]=r[f]||[0,0];p>=l!=b>=l&&i<=(g-h)*(l-p)/(b-p)+h&&(o=!o)}return o}function $3(e,r){return e[0]>=r.x&&e[0]<=r.x+r.width&&e[1]>=r.y&&e[1]<=r.y+r.height}function Gd(e){e===void 0&&(e={});const{buffer:r=.5,blockPointerEvents:i=!1,requireIntent:l=!0}=e,o={current:-1};let u=!1,c=null,f=null,h=typeof performance<"u"?performance.now():0;function p(b,v){const x=performance.now(),S=x-h;if(c===null||f===null||S===0)return c=b,f=v,h=x,null;const w=b-c,N=v-f,C=Math.sqrt(w*w+N*N)/S;return c=b,f=v,h=x,C}const g=b=>{let{x:v,y:x,placement:S,elements:w,onClose:N,nodeId:E,tree:C}=b;return function(z){function I(){Zt(o),N()}if(Zt(o),!w.domReference||!w.floating||S==null||v==null||x==null)return;const{clientX:L,clientY:O}=z,Z=[L,O],$=C3(z),F=z.type==="mouseleave",H=Zf(w.floating,$),G=Zf(w.domReference,$),Q=w.domReference.getBoundingClientRect(),U=w.floating.getBoundingClientRect(),Y=S.split("-")[0],B=v>U.right-U.width/2,X=x>U.bottom-U.height/2,M=$3(Z,Q),V=U.width>Q.width,R=U.height>Q.height,D=(V?Q:U).left,q=(V?Q:U).right,T=(R?Q:U).top,te=(R?Q:U).bottom;if(H&&(u=!0,!F))return;if(G&&(u=!1),G&&!F){u=!0;return}if(F&&ct(z.relatedTarget)&&Zf(w.floating,z.relatedTarget)||C&&i0(C.nodesRef.current,E).length)return;if(Y==="top"&&x>=Q.bottom-1||Y==="bottom"&&x<=Q.top+1||Y==="left"&&v>=Q.right-1||Y==="right"&&v<=Q.left+1)return I();let ie=[];switch(Y){case"top":ie=[[D,Q.top+1],[D,U.bottom-1],[q,U.bottom-1],[q,Q.top+1]];break;case"bottom":ie=[[D,U.top+1],[D,Q.bottom-1],[q,Q.bottom-1],[q,U.top+1]];break;case"left":ie=[[U.right-1,te],[U.right-1,T],[Q.left+1,T],[Q.left+1,te]];break;case"right":ie=[[Q.right-1,te],[Q.right-1,T],[U.left+1,T],[U.left+1,te]];break}function fe(ge){let[ye,pe]=ge;switch(Y){case"top":{const me=[V?ye+r/2:B?ye+r*4:ye-r*4,pe+r+1],xe=[V?ye-r/2:B?ye+r*4:ye-r*4,pe+r+1],de=[[U.left,B||V?U.bottom-r:U.top],[U.right,B?V?U.bottom-r:U.top:U.bottom-r]];return[me,xe,...de]}case"bottom":{const me=[V?ye+r/2:B?ye+r*4:ye-r*4,pe-r],xe=[V?ye-r/2:B?ye+r*4:ye-r*4,pe-r],de=[[U.left,B||V?U.top+r:U.bottom],[U.right,B?V?U.top+r:U.bottom:U.top+r]];return[me,xe,...de]}case"left":{const me=[ye+r+1,R?pe+r/2:X?pe+r*4:pe-r*4],xe=[ye+r+1,R?pe-r/2:X?pe+r*4:pe-r*4];return[...[[X||R?U.right-r:U.left,U.top],[X?R?U.right-r:U.left:U.right-r,U.bottom]],me,xe]}case"right":{const me=[ye-r,R?pe+r/2:X?pe+r*4:pe-r*4],xe=[ye-r,R?pe-r/2:X?pe+r*4:pe-r*4],de=[[X||R?U.left+r:U.right,U.top],[X?R?U.left+r:U.right:U.left+r,U.bottom]];return[me,xe,...de]}}}if(!Oy([L,O],ie)){if(u&&!M)return I();if(!F&&l){const ge=p(z.clientX,z.clientY);if(ge!==null&&ge<.1)return I()}Oy([L,O],fe([v,x]))?!u&&l&&(o.current=window.setTimeout(I,40)):I()}}};return g.__options={blockPointerEvents:i},g}const P3={".":"Uncommitted Changes",staged:"Staging Area",working:"Working Directory"},V3=new Set([".","staged","working"]),G3=e=>{const r=!e||V3.has(e)?"HEAD":`${e}^`;return{base:`${r}^`,target:r}},My=(e,r)=>!!r&&e===`${r}^`,Cs=(e,r)=>e?e===r.shortHash||e===r.hash:!1,zy=(e,r)=>r?`${e.shortHash}^`:e.shortHash,Fy=(e,r,i)=>{if(!r)return"Select...";const l=r.endsWith("^"),o=l?r.slice(0,-1):r;if(o.startsWith("HEAD"))return r;const u=P3[r];if(u)return u;const c=e.specialOptions.find(p=>p.value===r);if(c)return c.label;const f=e.branches.find(p=>p.name===o);if(f)return l?`${f.name}^`:f.name;const h=e.commits.find(p=>p.shortHash===o||p.hash===o);if(h)return zy(h,l);if(i){const p=e.commits.find(g=>g.shortHash===i||g.hash===i);if(p)return zy(p,!1)}return r};function Y3({options:e,baseRevision:r,targetRevision:i,resolvedBaseRevision:l,resolvedTargetRevision:o,onSelectDiff:u,onOpenAdvanced:c,compact:f=!1}){const[h,p]=A.useState(!1),[g,b]=A.useState(!1),v=f,{refs:x,floatingStyles:S,context:w}=$d({open:h||g,onOpenChange:ie=>{!ie&&g||p(ie)},placement:"bottom-end",middleware:[zd(6),Bd(),Fd({padding:8})],whileElementsMounted:Md}),N=Id(w,{handleClose:Gd()}),E=Hd(w),C=qd(w),j=Vd(w,{role:"menu"}),{getReferenceProps:z,getFloatingProps:I}=Pd([N,E,C,j]),{refs:L,floatingStyles:O,context:Z}=$d({open:g,onOpenChange:ie=>{ie&&p(!0),b(ie)},placement:"left-start",middleware:[zd(0),Bd(),Fd({padding:8})],whileElementsMounted:Md}),$=Id(Z,{handleClose:Gd()}),F=Hd(Z),H=qd(Z),G=Vd(Z,{role:"menu"}),{getReferenceProps:Q,getFloatingProps:U}=Pd([$,F,H,G]);A.useEffect(()=>{h||b(!1)},[h]);const Y=A.useMemo(()=>{const ie=My(r,i),fe=e.commits.find(pe=>ie?Cs(i,pe)||Cs(o,pe):!1);if(fe)return`${fe.shortHash} ${fe.message}`;const ge=Fy(e,r,l),ye=Fy(e,i,o);return`${ge}...${ye}`},[e,r,i,l,o]),B=A.useMemo(()=>e.branches.find(ie=>ie.name==="main")||e.branches.find(ie=>ie.name==="master"),[e.branches]),X=!!B,M=A.useMemo(()=>({base:"HEAD^",target:"HEAD"}),[]),V=A.useMemo(()=>G3(i),[i]),R=(ie,fe)=>{u(ie,fe),b(!1),p(!1)},D=()=>{b(!1),p(!1),c()},q=(ie,fe)=>["w-full text-left px-3 py-2 text-xs focus:outline-none transition-colors",ie?"hover:bg-diff-selected-bg focus:bg-diff-selected-bg":"hover:bg-github-bg-tertiary focus:bg-github-bg-tertiary",ie?"bg-diff-selected-bg border-l-4 border-l-diff-selected-border font-semibold pl-2":"",fe?"opacity-50 cursor-not-allowed":"cursor-pointer"].join(" "),T=(ie,fe)=>r===ie&&i===fe,te=ie=>My(r,i)?Cs(i,ie)||Cs(o,ie):!1;return y.jsxs("div",{className:"relative",children:[y.jsx("button",{ref:x.setReference,type:"button",className:"flex items-center gap-1.5 cursor-pointer group","aria-haspopup":"menu","aria-expanded":h,"aria-label":`Revision menu: ${Y}`,title:Y,...z(),children:v?y.jsxs("div",{className:"flex items-center gap-1.5 px-2 py-1 bg-github-bg-tertiary border border-github-border rounded hover:border-github-text-secondary transition-colors",children:[y.jsx(W2,{size:14,className:"text-github-text-secondary"}),y.jsx(_l,{size:12,className:"text-github-text-secondary group-hover:text-github-text-primary transition-colors"})]}):y.jsxs("div",{className:"flex items-center gap-1 px-2 py-1 bg-github-bg-tertiary border border-github-border rounded hover:border-github-text-secondary transition-colors",children:[y.jsx("code",{className:"text-xs text-github-text-primary",children:Y}),y.jsx(_l,{size:12,className:"text-github-text-secondary group-hover:text-github-text-primary transition-colors"})]})}),h&&y.jsx(Ud,{children:y.jsxs("div",{ref:x.setFloating,style:S,className:"bg-github-bg-secondary border border-github-border rounded shadow-lg z-50 w-[260px] max-h-[360px] overflow-y-auto",...I(),children:[y.jsxs("div",{className:"border-b border-github-border",children:[y.jsx("div",{className:"px-3 py-2 text-xs font-semibold text-github-text-secondary bg-github-bg-tertiary",children:"Quick Diffs"}),y.jsx("button",{onClick:()=>R("HEAD","."),className:q(T("HEAD","."),!1),children:"HEAD...Uncommitted"}),X&&B&&y.jsx(y.Fragment,{children:y.jsxs("button",{onClick:()=>R(B.name,"."),className:q(T(B.name,"."),!1),children:[B.name,"...Uncommitted"]})}),y.jsx("button",{onClick:()=>R(M.base,M.target),className:q(T(M.base,M.target),!1),children:"HEAD"})]}),y.jsx("div",{className:"border-b border-github-border",children:y.jsx("button",{onClick:()=>R(V.base,V.target),className:q(T(V.base,V.target),!1),type:"button",children:"Previous commit"})}),y.jsx("div",{className:"border-b border-github-border",children:y.jsx("button",{ref:e.commits.length>0?L.setReference:void 0,className:q(!1,e.commits.length===0),...e.commits.length>0?Q():{},disabled:e.commits.length===0,type:"button",children:y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx(T2,{size:12,className:"text-github-text-secondary"}),y.jsx("span",{children:"Pick Commit..."})]})})}),y.jsx("div",{children:y.jsx("button",{onClick:D,className:q(!1,!1),type:"button",children:"Detailed..."})})]})}),g&&e.commits.length>0&&y.jsx(Ud,{children:y.jsxs("div",{ref:L.setFloating,style:O,className:"bg-github-bg-secondary border border-github-border rounded shadow-lg z-50 w-[360px] max-h-[360px] overflow-y-auto",...U(),children:[y.jsx("div",{className:"px-3 py-2 text-xs font-semibold text-github-text-secondary bg-github-bg-tertiary",children:"Recent Commits"}),e.commits.map(ie=>y.jsx("button",{onClick:()=>R(`${ie.shortHash}^`,ie.shortHash),className:q(te(ie),!1),type:"button",children:y.jsxs("div",{className:"flex items-start gap-2",children:[y.jsx("code",{className:"text-xs text-github-text-primary font-mono whitespace-nowrap",children:ie.shortHash}),y.jsx("span",{className:"text-xs text-github-text-secondary flex-1 break-words",children:ie.message})]})},ie.hash))]})})]})}const X3=["jpg","jpeg","png","gif","bmp","svg","webp","ico","tiff","tif","avif","heic","heif"];function Z3(e){if(!e)return!1;const r=Qa(e);return r?X3.includes(r):!1}const K3=["md","markdown"];function Q3(e){if(!e)return!1;const r=Qa(e);return r?K3.includes(r):!1}const J3=["ipynb"];function W3(e){if(!e)return!1;const r=Qa(e);return r?J3.includes(r):!1}function e4({file:e,diffMode:r,baseCommitish:i,targetCommitish:l}){const o=r??Ka,u=e.status==="deleted",c=e.status==="added",f=e.status==="modified"||e.status==="renamed",h=i||"HEAD~1",p=l||"HEAD",[g,b]=A.useState({}),[v,x]=A.useState({}),S=async(C,j)=>{try{const z=C.naturalWidth,I=C.naturalHeight,Z=(await(await fetch(C.src)).blob()).size;j({width:z,height:I,size:Z})}catch(z){console.error("Failed to get image info:",z)}},w=C=>C?C<1024?`${C} B`:C<1024*1024?`${(C/1024).toFixed(1)} KB`:`${(C/(1024*1024)).toFixed(1)} MB`:"",N=C=>!C.width||!C.height?"":`W: ${C.width}px | H: ${C.height}px`,E={backgroundImage:`
|
|
27
|
+
linear-gradient(45deg, #ccc 25%, transparent 25%, transparent 75%, #ccc 75%),
|
|
28
|
+
linear-gradient(45deg, #ccc 25%, transparent 25%, transparent 75%, #ccc 75%)
|
|
29
|
+
`,backgroundSize:"20px 20px",backgroundPosition:"0 0, 10px 10px",backgroundColor:"white"};return u?y.jsx("div",{className:"bg-github-bg-primary p-4",children:y.jsxs("div",{className:"text-center",children:[y.jsx("div",{className:"mb-2",children:y.jsx("span",{className:"text-github-danger font-medium",children:"Deleted Image"})}),y.jsxs("div",{className:"inline-block border border-github-border rounded-md p-4 bg-github-bg-secondary",children:[y.jsx("div",{className:"text-github-text-muted mb-2",style:{fontSize:"14px"},children:"Previous version:"}),y.jsx("img",{src:`/api/blob/${e.oldPath||e.path}?ref=${h}`,alt:`Previous version of ${e.oldPath||e.path}`,className:"max-w-full max-h-96 border border-github-border rounded mx-auto",style:E,onLoad:C=>S(C.currentTarget,b),onError:C=>{const j=C.target;j.style.display="none",j.nextElementSibling?.classList.remove("hidden")}}),y.jsx("div",{className:"hidden text-github-text-muted text-sm mt-2",children:"Image could not be loaded"}),(g.width||g.size)&&y.jsxs("div",{className:"text-github-text-muted mt-2",style:{fontSize:"14px"},children:[N(g),N(g)&&w(g.size)&&" | ",w(g.size)]})]})]})}):c?y.jsx("div",{className:"bg-github-bg-primary p-4",children:y.jsxs("div",{className:"text-center",children:[y.jsx("div",{className:"mb-2",children:y.jsx("span",{className:"text-github-accent font-medium",children:"Added Image"})}),y.jsxs("div",{className:"inline-block border border-github-border rounded-md p-4 bg-github-bg-secondary",children:[y.jsx("div",{className:"text-github-text-muted mb-2",style:{fontSize:"14px"},children:"New file:"}),y.jsx("img",{src:`/api/blob/${e.path}?ref=${p}`,alt:`New image ${e.path}`,className:"max-w-full max-h-96 border border-github-border rounded mx-auto",style:E,onLoad:C=>S(C.currentTarget,x),onError:C=>{const j=C.target;j.style.display="none",j.nextElementSibling?.classList.remove("hidden")}}),y.jsx("div",{className:"hidden text-github-text-muted text-sm mt-2",children:"Image could not be loaded"}),(v.width||v.size)&&y.jsxs("div",{className:"text-github-text-muted mt-2",style:{fontSize:"14px"},children:[N(v),N(v)&&w(v.size)&&" | ",w(v.size)]})]})]})}):f?o==="split"?y.jsxs("div",{className:"bg-github-bg-primary p-4",children:[y.jsx("div",{className:"text-center mb-4",children:y.jsx("span",{className:"text-github-text-primary font-medium",children:"Modified Image"})}),y.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[y.jsx("div",{className:"text-center",children:y.jsxs("div",{className:"border border-github-border rounded-md p-4 bg-github-bg-secondary",children:[y.jsx("div",{className:"text-github-text-muted mb-2",style:{fontSize:"14px"},children:"Previous version:"}),y.jsx("img",{src:`/api/blob/${e.oldPath||e.path}?ref=${h}`,alt:`Previous version of ${e.oldPath||e.path}`,className:"max-w-full max-h-96 border border-github-border rounded mx-auto",style:E,onLoad:C=>S(C.currentTarget,b),onError:C=>{const j=C.target;j.style.display="none",j.nextElementSibling?.classList.remove("hidden")}}),y.jsx("div",{className:"hidden text-github-text-muted text-sm mt-2",children:"Image could not be loaded"}),(g.width||g.size)&&y.jsxs("div",{className:"text-github-text-muted mt-2",style:{fontSize:"14px"},children:[N(g),N(g)&&w(g.size)&&" | ",w(g.size)]})]})}),y.jsx("div",{className:"text-center",children:y.jsxs("div",{className:"border border-github-border rounded-md p-4 bg-github-bg-secondary",children:[y.jsx("div",{className:"text-github-text-muted mb-2",style:{fontSize:"14px"},children:"Current version:"}),y.jsx("img",{src:`/api/blob/${e.path}?ref=${p}`,alt:`Current version of ${e.path}`,className:"max-w-full max-h-96 border border-github-border rounded mx-auto",style:E,onLoad:C=>S(C.currentTarget,x),onError:C=>{const j=C.target;j.style.display="none",j.nextElementSibling?.classList.remove("hidden")}}),y.jsx("div",{className:"hidden text-github-text-muted text-sm mt-2",children:"Image could not be loaded"}),(v.width||v.size)&&y.jsxs("div",{className:"text-github-text-muted mt-2",style:{fontSize:"14px"},children:[N(v),N(v)&&w(v.size)&&" | ",w(v.size)]})]})})]})]}):y.jsxs("div",{className:"bg-github-bg-primary p-4",children:[y.jsx("div",{className:"text-center mb-4",children:y.jsx("span",{className:"text-github-text-primary font-medium",children:"Modified Image"})}),y.jsxs("div",{className:"space-y-6",children:[y.jsx("div",{className:"text-center",children:y.jsxs("div",{className:"border border-github-border rounded-md p-4 bg-github-bg-secondary inline-block",children:[y.jsx("div",{className:"text-github-text-muted mb-2",style:{fontSize:"14px"},children:"Previous version:"}),y.jsx("img",{src:`/api/blob/${e.oldPath||e.path}?ref=${h}`,alt:`Previous version of ${e.oldPath||e.path}`,className:"max-w-full max-h-96 border border-github-border rounded mx-auto",style:E,onLoad:C=>S(C.currentTarget,b),onError:C=>{const j=C.target;j.style.display="none",j.nextElementSibling?.classList.remove("hidden")}}),y.jsx("div",{className:"hidden text-github-text-muted text-sm mt-2",children:"Image could not be loaded"}),(g.width||g.size)&&y.jsxs("div",{className:"text-github-text-muted mt-2",style:{fontSize:"14px"},children:[N(g),N(g)&&w(g.size)&&" | ",w(g.size)]})]})}),y.jsx("div",{className:"text-center",children:y.jsxs("div",{className:"border border-github-border rounded-md p-4 bg-github-bg-secondary inline-block",children:[y.jsx("div",{className:"text-github-text-muted mb-2",style:{fontSize:"14px"},children:"Current version:"}),y.jsx("img",{src:`/api/blob/${e.path}?ref=${p}`,alt:`Current version of ${e.path}`,className:"max-w-full max-h-96 border border-github-border rounded mx-auto",style:E,onLoad:C=>S(C.currentTarget,x),onError:C=>{const j=C.target;j.style.display="none",j.nextElementSibling?.classList.remove("hidden")}}),y.jsx("div",{className:"hidden text-github-text-muted text-sm mt-2",children:"Image could not be loaded"}),(v.width||v.size)&&y.jsxs("div",{className:"text-github-text-muted mt-2",style:{fontSize:"14px"},children:[N(v),N(v)&&w(v.size)&&" | ",w(v.size)]})]})})]})]}):null}function t4(e,r){const i={};return(e[e.length-1]===""?[...e,""]:e).join((i.padRight?" ":"")+","+(i.padLeft===!1?"":" ")).trim()}const n4=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,r4=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,i4={};function By(e,r){return(i4.jsx?r4:n4).test(e)}const l4=/[ \t\n\f\r]/g;function a4(e){return typeof e=="object"?e.type==="text"?Iy(e.value):!1:Iy(e)}function Iy(e){return e.replace(l4,"")===""}class eo{constructor(r,i,l){this.normal=i,this.property=r,l&&(this.space=l)}}eo.prototype.normal={};eo.prototype.property={};eo.prototype.space=void 0;function l0(e,r){const i={},l={};for(const o of e)Object.assign(i,o.property),Object.assign(l,o.normal);return new eo(i,l,r)}function Yd(e){return e.toLowerCase()}class cn{constructor(r,i){this.attribute=i,this.property=r}}cn.prototype.attribute="";cn.prototype.booleanish=!1;cn.prototype.boolean=!1;cn.prototype.commaOrSpaceSeparated=!1;cn.prototype.commaSeparated=!1;cn.prototype.defined=!1;cn.prototype.mustUseProperty=!1;cn.prototype.number=!1;cn.prototype.overloadedBoolean=!1;cn.prototype.property="";cn.prototype.spaceSeparated=!1;cn.prototype.space=void 0;let o4=0;const De=Bi(),At=Bi(),Xd=Bi(),he=Bi(),ut=Bi(),Rl=Bi(),wn=Bi();function Bi(){return 2**++o4}const Zd=Object.freeze(Object.defineProperty({__proto__:null,boolean:De,booleanish:At,commaOrSpaceSeparated:wn,commaSeparated:Rl,number:he,overloadedBoolean:Xd,spaceSeparated:ut},Symbol.toStringTag,{value:"Module"})),Wf=Object.keys(Zd);class jh extends cn{constructor(r,i,l,o){let u=-1;if(super(r,i),Uy(this,"space",o),typeof l=="number")for(;++u<Wf.length;){const c=Wf[u];Uy(this,Wf[u],(l&Zd[c])===Zd[c])}}}jh.prototype.defined=!0;function Uy(e,r,i){i&&(e[r]=i)}function Ml(e){const r={},i={};for(const[l,o]of Object.entries(e.properties)){const u=new jh(l,e.transform(e.attributes||{},l),o,e.space);e.mustUseProperty&&e.mustUseProperty.includes(l)&&(u.mustUseProperty=!0),r[l]=u,i[Yd(l)]=l,i[Yd(u.attribute)]=l}return new eo(r,i,e.space)}const a0=Ml({properties:{ariaActiveDescendant:null,ariaAtomic:At,ariaAutoComplete:null,ariaBusy:At,ariaChecked:At,ariaColCount:he,ariaColIndex:he,ariaColSpan:he,ariaControls:ut,ariaCurrent:null,ariaDescribedBy:ut,ariaDetails:null,ariaDisabled:At,ariaDropEffect:ut,ariaErrorMessage:null,ariaExpanded:At,ariaFlowTo:ut,ariaGrabbed:At,ariaHasPopup:null,ariaHidden:At,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ut,ariaLevel:he,ariaLive:null,ariaModal:At,ariaMultiLine:At,ariaMultiSelectable:At,ariaOrientation:null,ariaOwns:ut,ariaPlaceholder:null,ariaPosInSet:he,ariaPressed:At,ariaReadOnly:At,ariaRelevant:null,ariaRequired:At,ariaRoleDescription:ut,ariaRowCount:he,ariaRowIndex:he,ariaRowSpan:he,ariaSelected:At,ariaSetSize:he,ariaSort:null,ariaValueMax:he,ariaValueMin:he,ariaValueNow:he,ariaValueText:null,role:null},transform(e,r){return r==="role"?r:"aria-"+r.slice(4).toLowerCase()}});function o0(e,r){return r in e?e[r]:r}function s0(e,r){return o0(e,r.toLowerCase())}const s4=Ml({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Rl,acceptCharset:ut,accessKey:ut,action:null,allow:null,allowFullScreen:De,allowPaymentRequest:De,allowUserMedia:De,alt:null,as:null,async:De,autoCapitalize:null,autoComplete:ut,autoFocus:De,autoPlay:De,blocking:ut,capture:null,charSet:null,checked:De,cite:null,className:ut,cols:he,colSpan:null,content:null,contentEditable:At,controls:De,controlsList:ut,coords:he|Rl,crossOrigin:null,data:null,dateTime:null,decoding:null,default:De,defer:De,dir:null,dirName:null,disabled:De,download:Xd,draggable:At,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:De,formTarget:null,headers:ut,height:he,hidden:Xd,high:he,href:null,hrefLang:null,htmlFor:ut,httpEquiv:ut,id:null,imageSizes:null,imageSrcSet:null,inert:De,inputMode:null,integrity:null,is:null,isMap:De,itemId:null,itemProp:ut,itemRef:ut,itemScope:De,itemType:ut,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:De,low:he,manifest:null,max:null,maxLength:he,media:null,method:null,min:null,minLength:he,multiple:De,muted:De,name:null,nonce:null,noModule:De,noValidate:De,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:De,optimum:he,pattern:null,ping:ut,placeholder:null,playsInline:De,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:De,referrerPolicy:null,rel:ut,required:De,reversed:De,rows:he,rowSpan:he,sandbox:ut,scope:null,scoped:De,seamless:De,selected:De,shadowRootClonable:De,shadowRootDelegatesFocus:De,shadowRootMode:null,shape:null,size:he,sizes:null,slot:null,span:he,spellCheck:At,src:null,srcDoc:null,srcLang:null,srcSet:null,start:he,step:null,style:null,tabIndex:he,target:null,title:null,translate:null,type:null,typeMustMatch:De,useMap:null,value:At,width:he,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ut,axis:null,background:null,bgColor:null,border:he,borderColor:null,bottomMargin:he,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:De,declare:De,event:null,face:null,frame:null,frameBorder:null,hSpace:he,leftMargin:he,link:null,longDesc:null,lowSrc:null,marginHeight:he,marginWidth:he,noResize:De,noHref:De,noShade:De,noWrap:De,object:null,profile:null,prompt:null,rev:null,rightMargin:he,rules:null,scheme:null,scrolling:At,standby:null,summary:null,text:null,topMargin:he,valueType:null,version:null,vAlign:null,vLink:null,vSpace:he,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:De,disableRemotePlayback:De,prefix:null,property:null,results:he,security:null,unselectable:null},space:"html",transform:s0}),u4=Ml({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",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",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",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",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",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",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:wn,accentHeight:he,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:he,amplitude:he,arabicForm:null,ascent:he,attributeName:null,attributeType:null,azimuth:he,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:he,by:null,calcMode:null,capHeight:he,className:ut,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:he,diffuseConstant:he,direction:null,display:null,dur:null,divisor:he,dominantBaseline:null,download:De,dx:null,dy:null,edgeMode:null,editable:null,elevation:he,enableBackground:null,end:null,event:null,exponent:he,externalResourcesRequired:null,fill:null,fillOpacity:he,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Rl,g2:Rl,glyphName:Rl,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:he,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:he,horizOriginX:he,horizOriginY:he,id:null,ideographic:he,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:he,k:he,k1:he,k2:he,k3:he,k4:he,kernelMatrix:wn,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:he,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:he,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:he,overlineThickness:he,paintOrder:null,panose1:null,path:null,pathLength:he,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ut,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:he,pointsAtY:he,pointsAtZ:he,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:wn,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:wn,rev:wn,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:wn,requiredFeatures:wn,requiredFonts:wn,requiredFormats:wn,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:he,specularExponent:he,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:he,strikethroughThickness:he,string:null,stroke:null,strokeDashArray:wn,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:he,strokeOpacity:he,strokeWidth:null,style:null,surfaceScale:he,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:wn,tabIndex:he,tableValues:null,target:null,targetX:he,targetY:he,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:wn,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:he,underlineThickness:he,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:he,values:null,vAlphabetic:he,vMathematical:he,vectorEffect:null,vHanging:he,vIdeographic:he,version:null,vertAdvY:he,vertOriginX:he,vertOriginY:he,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:he,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:o0}),u0=Ml({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,r){return"xlink:"+r.slice(5).toLowerCase()}}),c0=Ml({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:s0}),f0=Ml({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,r){return"xml:"+r.slice(3).toLowerCase()}}),c4={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},f4=/[A-Z]/g,Hy=/-[a-z]/g,d4=/^data[-\w.:]+$/i;function h4(e,r){const i=Yd(r);let l=r,o=cn;if(i in e.normal)return e.property[e.normal[i]];if(i.length>4&&i.slice(0,4)==="data"&&d4.test(r)){if(r.charAt(4)==="-"){const u=r.slice(5).replace(Hy,m4);l="data"+u.charAt(0).toUpperCase()+u.slice(1)}else{const u=r.slice(4);if(!Hy.test(u)){let c=u.replace(f4,p4);c.charAt(0)!=="-"&&(c="-"+c),r="data"+c}}o=jh}return new o(l,r)}function p4(e){return"-"+e.toLowerCase()}function m4(e){return e.charAt(1).toUpperCase()}const g4=l0([a0,s4,u0,c0,f0],"html"),Rh=l0([a0,u4,u0,c0,f0],"svg");function b4(e){return e.join(" ").trim()}var Sl={},ed,qy;function y4(){if(qy)return ed;qy=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,r=/\n/g,i=/^\s*/,l=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,u=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,f=/^\s+|\s+$/g,h=`
|
|
30
|
+
`,p="/",g="*",b="",v="comment",x="declaration";function S(N,E){if(typeof N!="string")throw new TypeError("First argument must be a string");if(!N)return[];E=E||{};var C=1,j=1;function z(U){var Y=U.match(r);Y&&(C+=Y.length);var B=U.lastIndexOf(h);j=~B?U.length-B:j+U.length}function I(){var U={line:C,column:j};return function(Y){return Y.position=new L(U),$(),Y}}function L(U){this.start=U,this.end={line:C,column:j},this.source=E.source}L.prototype.content=N;function O(U){var Y=new Error(E.source+":"+C+":"+j+": "+U);if(Y.reason=U,Y.filename=E.source,Y.line=C,Y.column=j,Y.source=N,!E.silent)throw Y}function Z(U){var Y=U.exec(N);if(Y){var B=Y[0];return z(B),N=N.slice(B.length),Y}}function $(){Z(i)}function F(U){var Y;for(U=U||[];Y=H();)Y!==!1&&U.push(Y);return U}function H(){var U=I();if(!(p!=N.charAt(0)||g!=N.charAt(1))){for(var Y=2;b!=N.charAt(Y)&&(g!=N.charAt(Y)||p!=N.charAt(Y+1));)++Y;if(Y+=2,b===N.charAt(Y-1))return O("End of comment missing");var B=N.slice(2,Y-2);return j+=2,z(B),N=N.slice(Y),j+=2,U({type:v,comment:B})}}function G(){var U=I(),Y=Z(l);if(Y){if(H(),!Z(o))return O("property missing ':'");var B=Z(u),X=U({type:x,property:w(Y[0].replace(e,b)),value:B?w(B[0].replace(e,b)):b});return Z(c),X}}function Q(){var U=[];F(U);for(var Y;Y=G();)Y!==!1&&(U.push(Y),F(U));return U}return $(),Q()}function w(N){return N?N.replace(f,b):b}return ed=S,ed}var $y;function x4(){if($y)return Sl;$y=1;var e=Sl&&Sl.__importDefault||function(l){return l&&l.__esModule?l:{default:l}};Object.defineProperty(Sl,"__esModule",{value:!0}),Sl.default=i;const r=e(y4());function i(l,o){let u=null;if(!l||typeof l!="string")return u;const c=(0,r.default)(l),f=typeof o=="function";return c.forEach(h=>{if(h.type!=="declaration")return;const{property:p,value:g}=h;f?o(p,g,h):g&&(u=u||{},u[p]=g)}),u}return Sl}var _a={},Py;function v4(){if(Py)return _a;Py=1,Object.defineProperty(_a,"__esModule",{value:!0}),_a.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,r=/-([a-z])/g,i=/^[^-]+$/,l=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,u=function(p){return!p||i.test(p)||e.test(p)},c=function(p,g){return g.toUpperCase()},f=function(p,g){return"".concat(g,"-")},h=function(p,g){return g===void 0&&(g={}),u(p)?p:(p=p.toLowerCase(),g.reactCompat?p=p.replace(o,f):p=p.replace(l,f),p.replace(r,c))};return _a.camelCase=h,_a}var La,Vy;function w4(){if(Vy)return La;Vy=1;var e=La&&La.__importDefault||function(o){return o&&o.__esModule?o:{default:o}},r=e(x4()),i=v4();function l(o,u){var c={};return!o||typeof o!="string"||(0,r.default)(o,function(f,h){f&&h&&(c[(0,i.camelCase)(f,u)]=h)}),c}return l.default=l,La=l,La}var S4=w4();const k4=lu(S4),d0=h0("end"),_h=h0("start");function h0(e){return r;function r(i){const l=i&&i.position&&i.position[e]||{};if(typeof l.line=="number"&&l.line>0&&typeof l.column=="number"&&l.column>0)return{line:l.line,column:l.column,offset:typeof l.offset=="number"&&l.offset>-1?l.offset:void 0}}}function E4(e){const r=_h(e),i=d0(e);if(r&&i)return{start:r,end:i}}function Ia(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?Gy(e.position):"start"in e||"end"in e?Gy(e):"line"in e||"column"in e?Kd(e):""}function Kd(e){return Yy(e&&e.line)+":"+Yy(e&&e.column)}function Gy(e){return Kd(e&&e.start)+"-"+Kd(e&&e.end)}function Yy(e){return e&&typeof e=="number"?e:1}class Vt extends Error{constructor(r,i,l){super(),typeof i=="string"&&(l=i,i=void 0);let o="",u={},c=!1;if(i&&("line"in i&&"column"in i?u={place:i}:"start"in i&&"end"in i?u={place:i}:"type"in i?u={ancestors:[i],place:i.position}:u={...i}),typeof r=="string"?o=r:!u.cause&&r&&(c=!0,o=r.message,u.cause=r),!u.ruleId&&!u.source&&typeof l=="string"){const h=l.indexOf(":");h===-1?u.ruleId=l:(u.source=l.slice(0,h),u.ruleId=l.slice(h+1))}if(!u.place&&u.ancestors&&u.ancestors){const h=u.ancestors[u.ancestors.length-1];h&&(u.place=h.position)}const f=u.place&&"start"in u.place?u.place.start:u.place;this.ancestors=u.ancestors||void 0,this.cause=u.cause||void 0,this.column=f?f.column:void 0,this.fatal=void 0,this.file="",this.message=o,this.line=f?f.line:void 0,this.name=Ia(u.place)||"1:1",this.place=u.place||void 0,this.reason=this.message,this.ruleId=u.ruleId||void 0,this.source=u.source||void 0,this.stack=c&&u.cause&&typeof u.cause.stack=="string"?u.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}Vt.prototype.file="";Vt.prototype.name="";Vt.prototype.reason="";Vt.prototype.message="";Vt.prototype.stack="";Vt.prototype.column=void 0;Vt.prototype.line=void 0;Vt.prototype.ancestors=void 0;Vt.prototype.cause=void 0;Vt.prototype.fatal=void 0;Vt.prototype.place=void 0;Vt.prototype.ruleId=void 0;Vt.prototype.source=void 0;const Lh={}.hasOwnProperty,C4=new Map,N4=/[A-Z]/g,A4=new Set(["table","tbody","thead","tfoot","tr"]),T4=new Set(["td","th"]),p0="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function j4(e,r){if(!r||r.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const i=r.filePath||void 0;let l;if(r.development){if(typeof r.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");l=F4(i,r.jsxDEV)}else{if(typeof r.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof r.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");l=z4(i,r.jsx,r.jsxs)}const o={Fragment:r.Fragment,ancestors:[],components:r.components||{},create:l,elementAttributeNameCase:r.elementAttributeNameCase||"react",evaluater:r.createEvaluater?r.createEvaluater():void 0,filePath:i,ignoreInvalidStyle:r.ignoreInvalidStyle||!1,passKeys:r.passKeys!==!1,passNode:r.passNode||!1,schema:r.space==="svg"?Rh:g4,stylePropertyNameCase:r.stylePropertyNameCase||"dom",tableCellAlignToStyle:r.tableCellAlignToStyle!==!1},u=m0(o,e,void 0);return u&&typeof u!="string"?u:o.create(e,o.Fragment,{children:u||void 0},void 0)}function m0(e,r,i){if(r.type==="element")return R4(e,r,i);if(r.type==="mdxFlowExpression"||r.type==="mdxTextExpression")return _4(e,r);if(r.type==="mdxJsxFlowElement"||r.type==="mdxJsxTextElement")return D4(e,r,i);if(r.type==="mdxjsEsm")return L4(e,r);if(r.type==="root")return O4(e,r,i);if(r.type==="text")return M4(e,r)}function R4(e,r,i){const l=e.schema;let o=l;r.tagName.toLowerCase()==="svg"&&l.space==="html"&&(o=Rh,e.schema=o),e.ancestors.push(r);const u=b0(e,r.tagName,!1),c=B4(e,r);let f=Oh(e,r);return A4.has(r.tagName)&&(f=f.filter(function(h){return typeof h=="string"?!a4(h):!0})),g0(e,c,u,r),Dh(c,f),e.ancestors.pop(),e.schema=l,e.create(r,u,c,i)}function _4(e,r){if(r.data&&r.data.estree&&e.evaluater){const l=r.data.estree.body[0];return l.type,e.evaluater.evaluateExpression(l.expression)}Ya(e,r.position)}function L4(e,r){if(r.data&&r.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(r.data.estree);Ya(e,r.position)}function D4(e,r,i){const l=e.schema;let o=l;r.name==="svg"&&l.space==="html"&&(o=Rh,e.schema=o),e.ancestors.push(r);const u=r.name===null?e.Fragment:b0(e,r.name,!0),c=I4(e,r),f=Oh(e,r);return g0(e,c,u,r),Dh(c,f),e.ancestors.pop(),e.schema=l,e.create(r,u,c,i)}function O4(e,r,i){const l={};return Dh(l,Oh(e,r)),e.create(r,e.Fragment,l,i)}function M4(e,r){return r.value}function g0(e,r,i,l){typeof i!="string"&&i!==e.Fragment&&e.passNode&&(r.node=l)}function Dh(e,r){if(r.length>0){const i=r.length>1?r:r[0];i&&(e.children=i)}}function z4(e,r,i){return l;function l(o,u,c,f){const p=Array.isArray(c.children)?i:r;return f?p(u,c,f):p(u,c)}}function F4(e,r){return i;function i(l,o,u,c){const f=Array.isArray(u.children),h=_h(l);return r(o,u,c,f,{columnNumber:h?h.column-1:void 0,fileName:e,lineNumber:h?h.line:void 0},void 0)}}function B4(e,r){const i={};let l,o;for(o in r.properties)if(o!=="children"&&Lh.call(r.properties,o)){const u=U4(e,o,r.properties[o]);if(u){const[c,f]=u;e.tableCellAlignToStyle&&c==="align"&&typeof f=="string"&&T4.has(r.tagName)?l=f:i[c]=f}}if(l){const u=i.style||(i.style={});u[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=l}return i}function I4(e,r){const i={};for(const l of r.attributes)if(l.type==="mdxJsxExpressionAttribute")if(l.data&&l.data.estree&&e.evaluater){const u=l.data.estree.body[0];u.type;const c=u.expression;c.type;const f=c.properties[0];f.type,Object.assign(i,e.evaluater.evaluateExpression(f.argument))}else Ya(e,r.position);else{const o=l.name;let u;if(l.value&&typeof l.value=="object")if(l.value.data&&l.value.data.estree&&e.evaluater){const f=l.value.data.estree.body[0];f.type,u=e.evaluater.evaluateExpression(f.expression)}else Ya(e,r.position);else u=l.value===null?!0:l.value;i[o]=u}return i}function Oh(e,r){const i=[];let l=-1;const o=e.passKeys?new Map:C4;for(;++l<r.children.length;){const u=r.children[l];let c;if(e.passKeys){const h=u.type==="element"?u.tagName:u.type==="mdxJsxFlowElement"||u.type==="mdxJsxTextElement"?u.name:void 0;if(h){const p=o.get(h)||0;c=h+"-"+p,o.set(h,p+1)}}const f=m0(e,u,c);f!==void 0&&i.push(f)}return i}function U4(e,r,i){const l=h4(e.schema,r);if(!(i==null||typeof i=="number"&&Number.isNaN(i))){if(Array.isArray(i)&&(i=l.commaSeparated?t4(i):b4(i)),l.property==="style"){let o=typeof i=="object"?i:H4(e,String(i));return e.stylePropertyNameCase==="css"&&(o=q4(o)),["style",o]}return[e.elementAttributeNameCase==="react"&&l.space?c4[l.property]||l.property:l.attribute,i]}}function H4(e,r){try{return k4(r,{reactCompat:!0})}catch(i){if(e.ignoreInvalidStyle)return{};const l=i,o=new Vt("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:l,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw o.file=e.filePath||void 0,o.url=p0+"#cannot-parse-style-attribute",o}}function b0(e,r,i){let l;if(!i)l={type:"Literal",value:r};else if(r.includes(".")){const o=r.split(".");let u=-1,c;for(;++u<o.length;){const f=By(o[u])?{type:"Identifier",name:o[u]}:{type:"Literal",value:o[u]};c=c?{type:"MemberExpression",object:c,property:f,computed:!!(u&&f.type==="Literal"),optional:!1}:f}l=c}else l=By(r)&&!/^[a-z]/.test(r)?{type:"Identifier",name:r}:{type:"Literal",value:r};if(l.type==="Literal"){const o=l.value;return Lh.call(e.components,o)?e.components[o]:o}if(e.evaluater)return e.evaluater.evaluateExpression(l);Ya(e)}function Ya(e,r){const i=new Vt("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:r,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw i.file=e.filePath||void 0,i.url=p0+"#cannot-handle-mdx-estrees-without-createevaluater",i}function q4(e){const r={};let i;for(i in e)Lh.call(e,i)&&(r[$4(i)]=e[i]);return r}function $4(e){let r=e.replace(N4,P4);return r.slice(0,3)==="ms-"&&(r="-"+r),r}function P4(e){return"-"+e.toLowerCase()}const td={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},V4={};function Mh(e,r){const i=V4,l=typeof i.includeImageAlt=="boolean"?i.includeImageAlt:!0,o=typeof i.includeHtml=="boolean"?i.includeHtml:!0;return y0(e,l,o)}function y0(e,r,i){if(G4(e)){if("value"in e)return e.type==="html"&&!i?"":e.value;if(r&&"alt"in e&&e.alt)return e.alt;if("children"in e)return Xy(e.children,r,i)}return Array.isArray(e)?Xy(e,r,i):""}function Xy(e,r,i){const l=[];let o=-1;for(;++o<e.length;)l[o]=y0(e[o],r,i);return l.join("")}function G4(e){return!!(e&&typeof e=="object")}const Zy=document.createElement("i");function zh(e){const r="&"+e+";";Zy.innerHTML=r;const i=Zy.textContent;return i.charCodeAt(i.length-1)===59&&e!=="semi"||i===r?!1:i}function kn(e,r,i,l){const o=e.length;let u=0,c;if(r<0?r=-r>o?0:o+r:r=r>o?o:r,i=i>0?i:0,l.length<1e4)c=Array.from(l),c.unshift(r,i),e.splice(...c);else for(i&&e.splice(r,i);u<l.length;)c=l.slice(u,u+1e4),c.unshift(r,0),e.splice(...c),u+=1e4,r+=1e4}function On(e,r){return e.length>0?(kn(e,e.length,0,r),e):r}const Ky={}.hasOwnProperty;function x0(e){const r={};let i=-1;for(;++i<e.length;)Y4(r,e[i]);return r}function Y4(e,r){let i;for(i in r){const o=(Ky.call(e,i)?e[i]:void 0)||(e[i]={}),u=r[i];let c;if(u)for(c in u){Ky.call(o,c)||(o[c]=[]);const f=u[c];X4(o[c],Array.isArray(f)?f:f?[f]:[])}}}function X4(e,r){let i=-1;const l=[];for(;++i<r.length;)(r[i].add==="after"?e:l).push(r[i]);kn(e,0,0,l)}function v0(e,r){const i=Number.parseInt(e,r);return i<9||i===11||i>13&&i<32||i>126&&i<160||i>55295&&i<57344||i>64975&&i<65008||(i&65535)===65535||(i&65535)===65534||i>1114111?"�":String.fromCodePoint(i)}function qn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Kt=ci(/[A-Za-z]/),Pt=ci(/[\dA-Za-z]/),Z4=ci(/[#-'*+\--9=?A-Z^-~]/);function Zs(e){return e!==null&&(e<32||e===127)}const Qd=ci(/\d/),K4=ci(/[\dA-Fa-f]/),Q4=ci(/[!-/:-@[-`{-~]/);function Ae(e){return e!==null&&e<-2}function st(e){return e!==null&&(e<0||e===32)}function Be(e){return e===-2||e===-1||e===32}const xu=ci(new RegExp("\\p{P}|\\p{S}","u")),Fi=ci(/\s/);function ci(e){return r;function r(i){return i!==null&&i>-1&&e.test(String.fromCharCode(i))}}function zl(e){const r=[];let i=-1,l=0,o=0;for(;++i<e.length;){const u=e.charCodeAt(i);let c="";if(u===37&&Pt(e.charCodeAt(i+1))&&Pt(e.charCodeAt(i+2)))o=2;else if(u<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(u))||(c=String.fromCharCode(u));else if(u>55295&&u<57344){const f=e.charCodeAt(i+1);u<56320&&f>56319&&f<57344?(c=String.fromCharCode(u,f),o=1):c="�"}else c=String.fromCharCode(u);c&&(r.push(e.slice(l,i),encodeURIComponent(c)),l=i+o+1,c=""),o&&(i+=o,o=0)}return r.join("")+e.slice(l)}function Ge(e,r,i,l){const o=l?l-1:Number.POSITIVE_INFINITY;let u=0;return c;function c(h){return Be(h)?(e.enter(i),f(h)):r(h)}function f(h){return Be(h)&&u++<o?(e.consume(h),f):(e.exit(i),r(h))}}const J4={tokenize:W4};function W4(e){const r=e.attempt(this.parser.constructs.contentInitial,l,o);let i;return r;function l(f){if(f===null){e.consume(f);return}return e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),Ge(e,r,"linePrefix")}function o(f){return e.enter("paragraph"),u(f)}function u(f){const h=e.enter("chunkText",{contentType:"text",previous:i});return i&&(i.next=h),i=h,c(f)}function c(f){if(f===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(f);return}return Ae(f)?(e.consume(f),e.exit("chunkText"),u):(e.consume(f),c)}}const eN={tokenize:tN},Qy={tokenize:nN};function tN(e){const r=this,i=[];let l=0,o,u,c;return f;function f(j){if(l<i.length){const z=i[l];return r.containerState=z[1],e.attempt(z[0].continuation,h,p)(j)}return p(j)}function h(j){if(l++,r.containerState._closeFlow){r.containerState._closeFlow=void 0,o&&C();const z=r.events.length;let I=z,L;for(;I--;)if(r.events[I][0]==="exit"&&r.events[I][1].type==="chunkFlow"){L=r.events[I][1].end;break}E(l);let O=z;for(;O<r.events.length;)r.events[O][1].end={...L},O++;return kn(r.events,I+1,0,r.events.slice(z)),r.events.length=O,p(j)}return f(j)}function p(j){if(l===i.length){if(!o)return v(j);if(o.currentConstruct&&o.currentConstruct.concrete)return S(j);r.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return r.containerState={},e.check(Qy,g,b)(j)}function g(j){return o&&C(),E(l),v(j)}function b(j){return r.parser.lazy[r.now().line]=l!==i.length,c=r.now().offset,S(j)}function v(j){return r.containerState={},e.attempt(Qy,x,S)(j)}function x(j){return l++,i.push([r.currentConstruct,r.containerState]),v(j)}function S(j){if(j===null){o&&C(),E(0),e.consume(j);return}return o=o||r.parser.flow(r.now()),e.enter("chunkFlow",{_tokenizer:o,contentType:"flow",previous:u}),w(j)}function w(j){if(j===null){N(e.exit("chunkFlow"),!0),E(0),e.consume(j);return}return Ae(j)?(e.consume(j),N(e.exit("chunkFlow")),l=0,r.interrupt=void 0,f):(e.consume(j),w)}function N(j,z){const I=r.sliceStream(j);if(z&&I.push(null),j.previous=u,u&&(u.next=j),u=j,o.defineSkip(j.start),o.write(I),r.parser.lazy[j.start.line]){let L=o.events.length;for(;L--;)if(o.events[L][1].start.offset<c&&(!o.events[L][1].end||o.events[L][1].end.offset>c))return;const O=r.events.length;let Z=O,$,F;for(;Z--;)if(r.events[Z][0]==="exit"&&r.events[Z][1].type==="chunkFlow"){if($){F=r.events[Z][1].end;break}$=!0}for(E(l),L=O;L<r.events.length;)r.events[L][1].end={...F},L++;kn(r.events,Z+1,0,r.events.slice(O)),r.events.length=L}}function E(j){let z=i.length;for(;z-- >j;){const I=i[z];r.containerState=I[1],I[0].exit.call(r,e)}i.length=j}function C(){o.write([null]),u=void 0,o=void 0,r.containerState._closeFlow=void 0}}function nN(e,r,i){return Ge(e,e.attempt(this.parser.constructs.document,r,i),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Dl(e){if(e===null||st(e)||Fi(e))return 1;if(xu(e))return 2}function vu(e,r,i){const l=[];let o=-1;for(;++o<e.length;){const u=e[o].resolveAll;u&&!l.includes(u)&&(r=u(r,i),l.push(u))}return r}const Jd={name:"attention",resolveAll:rN,tokenize:iN};function rN(e,r){let i=-1,l,o,u,c,f,h,p,g;for(;++i<e.length;)if(e[i][0]==="enter"&&e[i][1].type==="attentionSequence"&&e[i][1]._close){for(l=i;l--;)if(e[l][0]==="exit"&&e[l][1].type==="attentionSequence"&&e[l][1]._open&&r.sliceSerialize(e[l][1]).charCodeAt(0)===r.sliceSerialize(e[i][1]).charCodeAt(0)){if((e[l][1]._close||e[i][1]._open)&&(e[i][1].end.offset-e[i][1].start.offset)%3&&!((e[l][1].end.offset-e[l][1].start.offset+e[i][1].end.offset-e[i][1].start.offset)%3))continue;h=e[l][1].end.offset-e[l][1].start.offset>1&&e[i][1].end.offset-e[i][1].start.offset>1?2:1;const b={...e[l][1].end},v={...e[i][1].start};Jy(b,-h),Jy(v,h),c={type:h>1?"strongSequence":"emphasisSequence",start:b,end:{...e[l][1].end}},f={type:h>1?"strongSequence":"emphasisSequence",start:{...e[i][1].start},end:v},u={type:h>1?"strongText":"emphasisText",start:{...e[l][1].end},end:{...e[i][1].start}},o={type:h>1?"strong":"emphasis",start:{...c.start},end:{...f.end}},e[l][1].end={...c.start},e[i][1].start={...f.end},p=[],e[l][1].end.offset-e[l][1].start.offset&&(p=On(p,[["enter",e[l][1],r],["exit",e[l][1],r]])),p=On(p,[["enter",o,r],["enter",c,r],["exit",c,r],["enter",u,r]]),p=On(p,vu(r.parser.constructs.insideSpan.null,e.slice(l+1,i),r)),p=On(p,[["exit",u,r],["enter",f,r],["exit",f,r],["exit",o,r]]),e[i][1].end.offset-e[i][1].start.offset?(g=2,p=On(p,[["enter",e[i][1],r],["exit",e[i][1],r]])):g=0,kn(e,l-1,i-l+3,p),i=l+p.length-g-2;break}}for(i=-1;++i<e.length;)e[i][1].type==="attentionSequence"&&(e[i][1].type="data");return e}function iN(e,r){const i=this.parser.constructs.attentionMarkers.null,l=this.previous,o=Dl(l);let u;return c;function c(h){return u=h,e.enter("attentionSequence"),f(h)}function f(h){if(h===u)return e.consume(h),f;const p=e.exit("attentionSequence"),g=Dl(h),b=!g||g===2&&o||i.includes(h),v=!o||o===2&&g||i.includes(l);return p._open=!!(u===42?b:b&&(o||!v)),p._close=!!(u===42?v:v&&(g||!b)),r(h)}}function Jy(e,r){e.column+=r,e.offset+=r,e._bufferIndex+=r}const lN={name:"autolink",tokenize:aN};function aN(e,r,i){let l=0;return o;function o(x){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),u}function u(x){return Kt(x)?(e.consume(x),c):x===64?i(x):p(x)}function c(x){return x===43||x===45||x===46||Pt(x)?(l=1,f(x)):p(x)}function f(x){return x===58?(e.consume(x),l=0,h):(x===43||x===45||x===46||Pt(x))&&l++<32?(e.consume(x),f):(l=0,p(x))}function h(x){return x===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.exit("autolink"),r):x===null||x===32||x===60||Zs(x)?i(x):(e.consume(x),h)}function p(x){return x===64?(e.consume(x),g):Z4(x)?(e.consume(x),p):i(x)}function g(x){return Pt(x)?b(x):i(x)}function b(x){return x===46?(e.consume(x),l=0,g):x===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(x),e.exit("autolinkMarker"),e.exit("autolink"),r):v(x)}function v(x){if((x===45||Pt(x))&&l++<63){const S=x===45?v:b;return e.consume(x),S}return i(x)}}const to={partial:!0,tokenize:oN};function oN(e,r,i){return l;function l(u){return Be(u)?Ge(e,o,"linePrefix")(u):o(u)}function o(u){return u===null||Ae(u)?r(u):i(u)}}const w0={continuation:{tokenize:uN},exit:cN,name:"blockQuote",tokenize:sN};function sN(e,r,i){const l=this;return o;function o(c){if(c===62){const f=l.containerState;return f.open||(e.enter("blockQuote",{_container:!0}),f.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(c),e.exit("blockQuoteMarker"),u}return i(c)}function u(c){return Be(c)?(e.enter("blockQuotePrefixWhitespace"),e.consume(c),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),r):(e.exit("blockQuotePrefix"),r(c))}}function uN(e,r,i){const l=this;return o;function o(c){return Be(c)?Ge(e,u,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(c):u(c)}function u(c){return e.attempt(w0,r,i)(c)}}function cN(e){e.exit("blockQuote")}const S0={name:"characterEscape",tokenize:fN};function fN(e,r,i){return l;function l(u){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(u),e.exit("escapeMarker"),o}function o(u){return Q4(u)?(e.enter("characterEscapeValue"),e.consume(u),e.exit("characterEscapeValue"),e.exit("characterEscape"),r):i(u)}}const k0={name:"characterReference",tokenize:dN};function dN(e,r,i){const l=this;let o=0,u,c;return f;function f(b){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(b),e.exit("characterReferenceMarker"),h}function h(b){return b===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(b),e.exit("characterReferenceMarkerNumeric"),p):(e.enter("characterReferenceValue"),u=31,c=Pt,g(b))}function p(b){return b===88||b===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(b),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),u=6,c=K4,g):(e.enter("characterReferenceValue"),u=7,c=Qd,g(b))}function g(b){if(b===59&&o){const v=e.exit("characterReferenceValue");return c===Pt&&!zh(l.sliceSerialize(v))?i(b):(e.enter("characterReferenceMarker"),e.consume(b),e.exit("characterReferenceMarker"),e.exit("characterReference"),r)}return c(b)&&o++<u?(e.consume(b),g):i(b)}}const Wy={partial:!0,tokenize:pN},ex={concrete:!0,name:"codeFenced",tokenize:hN};function hN(e,r,i){const l=this,o={partial:!0,tokenize:I};let u=0,c=0,f;return h;function h(L){return p(L)}function p(L){const O=l.events[l.events.length-1];return u=O&&O[1].type==="linePrefix"?O[2].sliceSerialize(O[1],!0).length:0,f=L,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),g(L)}function g(L){return L===f?(c++,e.consume(L),g):c<3?i(L):(e.exit("codeFencedFenceSequence"),Be(L)?Ge(e,b,"whitespace")(L):b(L))}function b(L){return L===null||Ae(L)?(e.exit("codeFencedFence"),l.interrupt?r(L):e.check(Wy,w,z)(L)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),v(L))}function v(L){return L===null||Ae(L)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),b(L)):Be(L)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Ge(e,x,"whitespace")(L)):L===96&&L===f?i(L):(e.consume(L),v)}function x(L){return L===null||Ae(L)?b(L):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),S(L))}function S(L){return L===null||Ae(L)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),b(L)):L===96&&L===f?i(L):(e.consume(L),S)}function w(L){return e.attempt(o,z,N)(L)}function N(L){return e.enter("lineEnding"),e.consume(L),e.exit("lineEnding"),E}function E(L){return u>0&&Be(L)?Ge(e,C,"linePrefix",u+1)(L):C(L)}function C(L){return L===null||Ae(L)?e.check(Wy,w,z)(L):(e.enter("codeFlowValue"),j(L))}function j(L){return L===null||Ae(L)?(e.exit("codeFlowValue"),C(L)):(e.consume(L),j)}function z(L){return e.exit("codeFenced"),r(L)}function I(L,O,Z){let $=0;return F;function F(Y){return L.enter("lineEnding"),L.consume(Y),L.exit("lineEnding"),H}function H(Y){return L.enter("codeFencedFence"),Be(Y)?Ge(L,G,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(Y):G(Y)}function G(Y){return Y===f?(L.enter("codeFencedFenceSequence"),Q(Y)):Z(Y)}function Q(Y){return Y===f?($++,L.consume(Y),Q):$>=c?(L.exit("codeFencedFenceSequence"),Be(Y)?Ge(L,U,"whitespace")(Y):U(Y)):Z(Y)}function U(Y){return Y===null||Ae(Y)?(L.exit("codeFencedFence"),O(Y)):Z(Y)}}}function pN(e,r,i){const l=this;return o;function o(c){return c===null?i(c):(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),u)}function u(c){return l.parser.lazy[l.now().line]?i(c):r(c)}}const nd={name:"codeIndented",tokenize:gN},mN={partial:!0,tokenize:bN};function gN(e,r,i){const l=this;return o;function o(p){return e.enter("codeIndented"),Ge(e,u,"linePrefix",5)(p)}function u(p){const g=l.events[l.events.length-1];return g&&g[1].type==="linePrefix"&&g[2].sliceSerialize(g[1],!0).length>=4?c(p):i(p)}function c(p){return p===null?h(p):Ae(p)?e.attempt(mN,c,h)(p):(e.enter("codeFlowValue"),f(p))}function f(p){return p===null||Ae(p)?(e.exit("codeFlowValue"),c(p)):(e.consume(p),f)}function h(p){return e.exit("codeIndented"),r(p)}}function bN(e,r,i){const l=this;return o;function o(c){return l.parser.lazy[l.now().line]?i(c):Ae(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),o):Ge(e,u,"linePrefix",5)(c)}function u(c){const f=l.events[l.events.length-1];return f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?r(c):Ae(c)?o(c):i(c)}}const yN={name:"codeText",previous:vN,resolve:xN,tokenize:wN};function xN(e){let r=e.length-4,i=3,l,o;if((e[i][1].type==="lineEnding"||e[i][1].type==="space")&&(e[r][1].type==="lineEnding"||e[r][1].type==="space")){for(l=i;++l<r;)if(e[l][1].type==="codeTextData"){e[i][1].type="codeTextPadding",e[r][1].type="codeTextPadding",i+=2,r-=2;break}}for(l=i-1,r++;++l<=r;)o===void 0?l!==r&&e[l][1].type!=="lineEnding"&&(o=l):(l===r||e[l][1].type==="lineEnding")&&(e[o][1].type="codeTextData",l!==o+2&&(e[o][1].end=e[l-1][1].end,e.splice(o+2,l-o-2),r-=l-o-2,l=o+2),o=void 0);return e}function vN(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function wN(e,r,i){let l=0,o,u;return c;function c(b){return e.enter("codeText"),e.enter("codeTextSequence"),f(b)}function f(b){return b===96?(e.consume(b),l++,f):(e.exit("codeTextSequence"),h(b))}function h(b){return b===null?i(b):b===32?(e.enter("space"),e.consume(b),e.exit("space"),h):b===96?(u=e.enter("codeTextSequence"),o=0,g(b)):Ae(b)?(e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),h):(e.enter("codeTextData"),p(b))}function p(b){return b===null||b===32||b===96||Ae(b)?(e.exit("codeTextData"),h(b)):(e.consume(b),p)}function g(b){return b===96?(e.consume(b),o++,g):o===l?(e.exit("codeTextSequence"),e.exit("codeText"),r(b)):(u.type="codeTextData",p(b))}}class SN{constructor(r){this.left=r?[...r]:[],this.right=[]}get(r){if(r<0||r>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+r+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return r<this.left.length?this.left[r]:this.right[this.right.length-r+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(r,i){const l=i??Number.POSITIVE_INFINITY;return l<this.left.length?this.left.slice(r,l):r>this.left.length?this.right.slice(this.right.length-l+this.left.length,this.right.length-r+this.left.length).reverse():this.left.slice(r).concat(this.right.slice(this.right.length-l+this.left.length).reverse())}splice(r,i,l){const o=i||0;this.setCursor(Math.trunc(r));const u=this.right.splice(this.right.length-o,Number.POSITIVE_INFINITY);return l&&Da(this.left,l),u.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(r){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(r)}pushMany(r){this.setCursor(Number.POSITIVE_INFINITY),Da(this.left,r)}unshift(r){this.setCursor(0),this.right.push(r)}unshiftMany(r){this.setCursor(0),Da(this.right,r.reverse())}setCursor(r){if(!(r===this.left.length||r>this.left.length&&this.right.length===0||r<0&&this.left.length===0))if(r<this.left.length){const i=this.left.splice(r,Number.POSITIVE_INFINITY);Da(this.right,i.reverse())}else{const i=this.right.splice(this.left.length+this.right.length-r,Number.POSITIVE_INFINITY);Da(this.left,i.reverse())}}}function Da(e,r){let i=0;if(r.length<1e4)e.push(...r);else for(;i<r.length;)e.push(...r.slice(i,i+1e4)),i+=1e4}function E0(e){const r={};let i=-1,l,o,u,c,f,h,p;const g=new SN(e);for(;++i<g.length;){for(;i in r;)i=r[i];if(l=g.get(i),i&&l[1].type==="chunkFlow"&&g.get(i-1)[1].type==="listItemPrefix"&&(h=l[1]._tokenizer.events,u=0,u<h.length&&h[u][1].type==="lineEndingBlank"&&(u+=2),u<h.length&&h[u][1].type==="content"))for(;++u<h.length&&h[u][1].type!=="content";)h[u][1].type==="chunkText"&&(h[u][1]._isInFirstContentOfListItem=!0,u++);if(l[0]==="enter")l[1].contentType&&(Object.assign(r,kN(g,i)),i=r[i],p=!0);else if(l[1]._container){for(u=i,o=void 0;u--;)if(c=g.get(u),c[1].type==="lineEnding"||c[1].type==="lineEndingBlank")c[0]==="enter"&&(o&&(g.get(o)[1].type="lineEndingBlank"),c[1].type="lineEnding",o=u);else if(!(c[1].type==="linePrefix"||c[1].type==="listItemIndent"))break;o&&(l[1].end={...g.get(o)[1].start},f=g.slice(o,i),f.unshift(l),g.splice(o,i-o+1,f))}}return kn(e,0,Number.POSITIVE_INFINITY,g.slice(0)),!p}function kN(e,r){const i=e.get(r)[1],l=e.get(r)[2];let o=r-1;const u=[];let c=i._tokenizer;c||(c=l.parser[i.contentType](i.start),i._contentTypeTextTrailing&&(c._contentTypeTextTrailing=!0));const f=c.events,h=[],p={};let g,b,v=-1,x=i,S=0,w=0;const N=[w];for(;x;){for(;e.get(++o)[1]!==x;);u.push(o),x._tokenizer||(g=l.sliceStream(x),x.next||g.push(null),b&&c.defineSkip(x.start),x._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=!0),c.write(g),x._isInFirstContentOfListItem&&(c._gfmTasklistFirstContentOfListItem=void 0)),b=x,x=x.next}for(x=i;++v<f.length;)f[v][0]==="exit"&&f[v-1][0]==="enter"&&f[v][1].type===f[v-1][1].type&&f[v][1].start.line!==f[v][1].end.line&&(w=v+1,N.push(w),x._tokenizer=void 0,x.previous=void 0,x=x.next);for(c.events=[],x?(x._tokenizer=void 0,x.previous=void 0):N.pop(),v=N.length;v--;){const E=f.slice(N[v],N[v+1]),C=u.pop();h.push([C,C+E.length-1]),e.splice(C,2,E)}for(h.reverse(),v=-1;++v<h.length;)p[S+h[v][0]]=S+h[v][1],S+=h[v][1]-h[v][0]-1;return p}const EN={resolve:NN,tokenize:AN},CN={partial:!0,tokenize:TN};function NN(e){return E0(e),e}function AN(e,r){let i;return l;function l(f){return e.enter("content"),i=e.enter("chunkContent",{contentType:"content"}),o(f)}function o(f){return f===null?u(f):Ae(f)?e.check(CN,c,u)(f):(e.consume(f),o)}function u(f){return e.exit("chunkContent"),e.exit("content"),r(f)}function c(f){return e.consume(f),e.exit("chunkContent"),i.next=e.enter("chunkContent",{contentType:"content",previous:i}),i=i.next,o}}function TN(e,r,i){const l=this;return o;function o(c){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),Ge(e,u,"linePrefix")}function u(c){if(c===null||Ae(c))return i(c);const f=l.events[l.events.length-1];return!l.parser.constructs.disable.null.includes("codeIndented")&&f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?r(c):e.interrupt(l.parser.constructs.flow,i,r)(c)}}function C0(e,r,i,l,o,u,c,f,h){const p=h||Number.POSITIVE_INFINITY;let g=0;return b;function b(E){return E===60?(e.enter(l),e.enter(o),e.enter(u),e.consume(E),e.exit(u),v):E===null||E===32||E===41||Zs(E)?i(E):(e.enter(l),e.enter(c),e.enter(f),e.enter("chunkString",{contentType:"string"}),w(E))}function v(E){return E===62?(e.enter(u),e.consume(E),e.exit(u),e.exit(o),e.exit(l),r):(e.enter(f),e.enter("chunkString",{contentType:"string"}),x(E))}function x(E){return E===62?(e.exit("chunkString"),e.exit(f),v(E)):E===null||E===60||Ae(E)?i(E):(e.consume(E),E===92?S:x)}function S(E){return E===60||E===62||E===92?(e.consume(E),x):x(E)}function w(E){return!g&&(E===null||E===41||st(E))?(e.exit("chunkString"),e.exit(f),e.exit(c),e.exit(l),r(E)):g<p&&E===40?(e.consume(E),g++,w):E===41?(e.consume(E),g--,w):E===null||E===32||E===40||Zs(E)?i(E):(e.consume(E),E===92?N:w)}function N(E){return E===40||E===41||E===92?(e.consume(E),w):w(E)}}function N0(e,r,i,l,o,u){const c=this;let f=0,h;return p;function p(x){return e.enter(l),e.enter(o),e.consume(x),e.exit(o),e.enter(u),g}function g(x){return f>999||x===null||x===91||x===93&&!h||x===94&&!f&&"_hiddenFootnoteSupport"in c.parser.constructs?i(x):x===93?(e.exit(u),e.enter(o),e.consume(x),e.exit(o),e.exit(l),r):Ae(x)?(e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),g):(e.enter("chunkString",{contentType:"string"}),b(x))}function b(x){return x===null||x===91||x===93||Ae(x)||f++>999?(e.exit("chunkString"),g(x)):(e.consume(x),h||(h=!Be(x)),x===92?v:b)}function v(x){return x===91||x===92||x===93?(e.consume(x),f++,b):b(x)}}function A0(e,r,i,l,o,u){let c;return f;function f(v){return v===34||v===39||v===40?(e.enter(l),e.enter(o),e.consume(v),e.exit(o),c=v===40?41:v,h):i(v)}function h(v){return v===c?(e.enter(o),e.consume(v),e.exit(o),e.exit(l),r):(e.enter(u),p(v))}function p(v){return v===c?(e.exit(u),h(c)):v===null?i(v):Ae(v)?(e.enter("lineEnding"),e.consume(v),e.exit("lineEnding"),Ge(e,p,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),g(v))}function g(v){return v===c||v===null||Ae(v)?(e.exit("chunkString"),p(v)):(e.consume(v),v===92?b:g)}function b(v){return v===c||v===92?(e.consume(v),g):g(v)}}function Ua(e,r){let i;return l;function l(o){return Ae(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),i=!0,l):Be(o)?Ge(e,l,i?"linePrefix":"lineSuffix")(o):r(o)}}const jN={name:"definition",tokenize:_N},RN={partial:!0,tokenize:LN};function _N(e,r,i){const l=this;let o;return u;function u(x){return e.enter("definition"),c(x)}function c(x){return N0.call(l,e,f,i,"definitionLabel","definitionLabelMarker","definitionLabelString")(x)}function f(x){return o=qn(l.sliceSerialize(l.events[l.events.length-1][1]).slice(1,-1)),x===58?(e.enter("definitionMarker"),e.consume(x),e.exit("definitionMarker"),h):i(x)}function h(x){return st(x)?Ua(e,p)(x):p(x)}function p(x){return C0(e,g,i,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(x)}function g(x){return e.attempt(RN,b,b)(x)}function b(x){return Be(x)?Ge(e,v,"whitespace")(x):v(x)}function v(x){return x===null||Ae(x)?(e.exit("definition"),l.parser.defined.push(o),r(x)):i(x)}}function LN(e,r,i){return l;function l(f){return st(f)?Ua(e,o)(f):i(f)}function o(f){return A0(e,u,i,"definitionTitle","definitionTitleMarker","definitionTitleString")(f)}function u(f){return Be(f)?Ge(e,c,"whitespace")(f):c(f)}function c(f){return f===null||Ae(f)?r(f):i(f)}}const DN={name:"hardBreakEscape",tokenize:ON};function ON(e,r,i){return l;function l(u){return e.enter("hardBreakEscape"),e.consume(u),o}function o(u){return Ae(u)?(e.exit("hardBreakEscape"),r(u)):i(u)}}const MN={name:"headingAtx",resolve:zN,tokenize:FN};function zN(e,r){let i=e.length-2,l=3,o,u;return e[l][1].type==="whitespace"&&(l+=2),i-2>l&&e[i][1].type==="whitespace"&&(i-=2),e[i][1].type==="atxHeadingSequence"&&(l===i-1||i-4>l&&e[i-2][1].type==="whitespace")&&(i-=l+1===i?2:4),i>l&&(o={type:"atxHeadingText",start:e[l][1].start,end:e[i][1].end},u={type:"chunkText",start:e[l][1].start,end:e[i][1].end,contentType:"text"},kn(e,l,i-l+1,[["enter",o,r],["enter",u,r],["exit",u,r],["exit",o,r]])),e}function FN(e,r,i){let l=0;return o;function o(g){return e.enter("atxHeading"),u(g)}function u(g){return e.enter("atxHeadingSequence"),c(g)}function c(g){return g===35&&l++<6?(e.consume(g),c):g===null||st(g)?(e.exit("atxHeadingSequence"),f(g)):i(g)}function f(g){return g===35?(e.enter("atxHeadingSequence"),h(g)):g===null||Ae(g)?(e.exit("atxHeading"),r(g)):Be(g)?Ge(e,f,"whitespace")(g):(e.enter("atxHeadingText"),p(g))}function h(g){return g===35?(e.consume(g),h):(e.exit("atxHeadingSequence"),f(g))}function p(g){return g===null||g===35||st(g)?(e.exit("atxHeadingText"),f(g)):(e.consume(g),p)}}const BN=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],tx=["pre","script","style","textarea"],IN={concrete:!0,name:"htmlFlow",resolveTo:qN,tokenize:$N},UN={partial:!0,tokenize:VN},HN={partial:!0,tokenize:PN};function qN(e){let r=e.length;for(;r--&&!(e[r][0]==="enter"&&e[r][1].type==="htmlFlow"););return r>1&&e[r-2][1].type==="linePrefix"&&(e[r][1].start=e[r-2][1].start,e[r+1][1].start=e[r-2][1].start,e.splice(r-2,2)),e}function $N(e,r,i){const l=this;let o,u,c,f,h;return p;function p(T){return g(T)}function g(T){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(T),b}function b(T){return T===33?(e.consume(T),v):T===47?(e.consume(T),u=!0,w):T===63?(e.consume(T),o=3,l.interrupt?r:R):Kt(T)?(e.consume(T),c=String.fromCharCode(T),N):i(T)}function v(T){return T===45?(e.consume(T),o=2,x):T===91?(e.consume(T),o=5,f=0,S):Kt(T)?(e.consume(T),o=4,l.interrupt?r:R):i(T)}function x(T){return T===45?(e.consume(T),l.interrupt?r:R):i(T)}function S(T){const te="CDATA[";return T===te.charCodeAt(f++)?(e.consume(T),f===te.length?l.interrupt?r:G:S):i(T)}function w(T){return Kt(T)?(e.consume(T),c=String.fromCharCode(T),N):i(T)}function N(T){if(T===null||T===47||T===62||st(T)){const te=T===47,ie=c.toLowerCase();return!te&&!u&&tx.includes(ie)?(o=1,l.interrupt?r(T):G(T)):BN.includes(c.toLowerCase())?(o=6,te?(e.consume(T),E):l.interrupt?r(T):G(T)):(o=7,l.interrupt&&!l.parser.lazy[l.now().line]?i(T):u?C(T):j(T))}return T===45||Pt(T)?(e.consume(T),c+=String.fromCharCode(T),N):i(T)}function E(T){return T===62?(e.consume(T),l.interrupt?r:G):i(T)}function C(T){return Be(T)?(e.consume(T),C):F(T)}function j(T){return T===47?(e.consume(T),F):T===58||T===95||Kt(T)?(e.consume(T),z):Be(T)?(e.consume(T),j):F(T)}function z(T){return T===45||T===46||T===58||T===95||Pt(T)?(e.consume(T),z):I(T)}function I(T){return T===61?(e.consume(T),L):Be(T)?(e.consume(T),I):j(T)}function L(T){return T===null||T===60||T===61||T===62||T===96?i(T):T===34||T===39?(e.consume(T),h=T,O):Be(T)?(e.consume(T),L):Z(T)}function O(T){return T===h?(e.consume(T),h=null,$):T===null||Ae(T)?i(T):(e.consume(T),O)}function Z(T){return T===null||T===34||T===39||T===47||T===60||T===61||T===62||T===96||st(T)?I(T):(e.consume(T),Z)}function $(T){return T===47||T===62||Be(T)?j(T):i(T)}function F(T){return T===62?(e.consume(T),H):i(T)}function H(T){return T===null||Ae(T)?G(T):Be(T)?(e.consume(T),H):i(T)}function G(T){return T===45&&o===2?(e.consume(T),B):T===60&&o===1?(e.consume(T),X):T===62&&o===4?(e.consume(T),D):T===63&&o===3?(e.consume(T),R):T===93&&o===5?(e.consume(T),V):Ae(T)&&(o===6||o===7)?(e.exit("htmlFlowData"),e.check(UN,q,Q)(T)):T===null||Ae(T)?(e.exit("htmlFlowData"),Q(T)):(e.consume(T),G)}function Q(T){return e.check(HN,U,q)(T)}function U(T){return e.enter("lineEnding"),e.consume(T),e.exit("lineEnding"),Y}function Y(T){return T===null||Ae(T)?Q(T):(e.enter("htmlFlowData"),G(T))}function B(T){return T===45?(e.consume(T),R):G(T)}function X(T){return T===47?(e.consume(T),c="",M):G(T)}function M(T){if(T===62){const te=c.toLowerCase();return tx.includes(te)?(e.consume(T),D):G(T)}return Kt(T)&&c.length<8?(e.consume(T),c+=String.fromCharCode(T),M):G(T)}function V(T){return T===93?(e.consume(T),R):G(T)}function R(T){return T===62?(e.consume(T),D):T===45&&o===2?(e.consume(T),R):G(T)}function D(T){return T===null||Ae(T)?(e.exit("htmlFlowData"),q(T)):(e.consume(T),D)}function q(T){return e.exit("htmlFlow"),r(T)}}function PN(e,r,i){const l=this;return o;function o(c){return Ae(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),u):i(c)}function u(c){return l.parser.lazy[l.now().line]?i(c):r(c)}}function VN(e,r,i){return l;function l(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),e.attempt(to,r,i)}}const GN={name:"htmlText",tokenize:YN};function YN(e,r,i){const l=this;let o,u,c;return f;function f(R){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(R),h}function h(R){return R===33?(e.consume(R),p):R===47?(e.consume(R),I):R===63?(e.consume(R),j):Kt(R)?(e.consume(R),Z):i(R)}function p(R){return R===45?(e.consume(R),g):R===91?(e.consume(R),u=0,S):Kt(R)?(e.consume(R),C):i(R)}function g(R){return R===45?(e.consume(R),x):i(R)}function b(R){return R===null?i(R):R===45?(e.consume(R),v):Ae(R)?(c=b,X(R)):(e.consume(R),b)}function v(R){return R===45?(e.consume(R),x):b(R)}function x(R){return R===62?B(R):R===45?v(R):b(R)}function S(R){const D="CDATA[";return R===D.charCodeAt(u++)?(e.consume(R),u===D.length?w:S):i(R)}function w(R){return R===null?i(R):R===93?(e.consume(R),N):Ae(R)?(c=w,X(R)):(e.consume(R),w)}function N(R){return R===93?(e.consume(R),E):w(R)}function E(R){return R===62?B(R):R===93?(e.consume(R),E):w(R)}function C(R){return R===null||R===62?B(R):Ae(R)?(c=C,X(R)):(e.consume(R),C)}function j(R){return R===null?i(R):R===63?(e.consume(R),z):Ae(R)?(c=j,X(R)):(e.consume(R),j)}function z(R){return R===62?B(R):j(R)}function I(R){return Kt(R)?(e.consume(R),L):i(R)}function L(R){return R===45||Pt(R)?(e.consume(R),L):O(R)}function O(R){return Ae(R)?(c=O,X(R)):Be(R)?(e.consume(R),O):B(R)}function Z(R){return R===45||Pt(R)?(e.consume(R),Z):R===47||R===62||st(R)?$(R):i(R)}function $(R){return R===47?(e.consume(R),B):R===58||R===95||Kt(R)?(e.consume(R),F):Ae(R)?(c=$,X(R)):Be(R)?(e.consume(R),$):B(R)}function F(R){return R===45||R===46||R===58||R===95||Pt(R)?(e.consume(R),F):H(R)}function H(R){return R===61?(e.consume(R),G):Ae(R)?(c=H,X(R)):Be(R)?(e.consume(R),H):$(R)}function G(R){return R===null||R===60||R===61||R===62||R===96?i(R):R===34||R===39?(e.consume(R),o=R,Q):Ae(R)?(c=G,X(R)):Be(R)?(e.consume(R),G):(e.consume(R),U)}function Q(R){return R===o?(e.consume(R),o=void 0,Y):R===null?i(R):Ae(R)?(c=Q,X(R)):(e.consume(R),Q)}function U(R){return R===null||R===34||R===39||R===60||R===61||R===96?i(R):R===47||R===62||st(R)?$(R):(e.consume(R),U)}function Y(R){return R===47||R===62||st(R)?$(R):i(R)}function B(R){return R===62?(e.consume(R),e.exit("htmlTextData"),e.exit("htmlText"),r):i(R)}function X(R){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(R),e.exit("lineEnding"),M}function M(R){return Be(R)?Ge(e,V,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(R):V(R)}function V(R){return e.enter("htmlTextData"),c(R)}}const Fh={name:"labelEnd",resolveAll:QN,resolveTo:JN,tokenize:WN},XN={tokenize:eA},ZN={tokenize:tA},KN={tokenize:nA};function QN(e){let r=-1;const i=[];for(;++r<e.length;){const l=e[r][1];if(i.push(e[r]),l.type==="labelImage"||l.type==="labelLink"||l.type==="labelEnd"){const o=l.type==="labelImage"?4:2;l.type="data",r+=o}}return e.length!==i.length&&kn(e,0,e.length,i),e}function JN(e,r){let i=e.length,l=0,o,u,c,f;for(;i--;)if(o=e[i][1],u){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[i][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(c){if(e[i][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(u=i,o.type!=="labelLink")){l=2;break}}else o.type==="labelEnd"&&(c=i);const h={type:e[u][1].type==="labelLink"?"link":"image",start:{...e[u][1].start},end:{...e[e.length-1][1].end}},p={type:"label",start:{...e[u][1].start},end:{...e[c][1].end}},g={type:"labelText",start:{...e[u+l+2][1].end},end:{...e[c-2][1].start}};return f=[["enter",h,r],["enter",p,r]],f=On(f,e.slice(u+1,u+l+3)),f=On(f,[["enter",g,r]]),f=On(f,vu(r.parser.constructs.insideSpan.null,e.slice(u+l+4,c-3),r)),f=On(f,[["exit",g,r],e[c-2],e[c-1],["exit",p,r]]),f=On(f,e.slice(c+1)),f=On(f,[["exit",h,r]]),kn(e,u,e.length,f),e}function WN(e,r,i){const l=this;let o=l.events.length,u,c;for(;o--;)if((l.events[o][1].type==="labelImage"||l.events[o][1].type==="labelLink")&&!l.events[o][1]._balanced){u=l.events[o][1];break}return f;function f(v){return u?u._inactive?b(v):(c=l.parser.defined.includes(qn(l.sliceSerialize({start:u.end,end:l.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(v),e.exit("labelMarker"),e.exit("labelEnd"),h):i(v)}function h(v){return v===40?e.attempt(XN,g,c?g:b)(v):v===91?e.attempt(ZN,g,c?p:b)(v):c?g(v):b(v)}function p(v){return e.attempt(KN,g,b)(v)}function g(v){return r(v)}function b(v){return u._balanced=!0,i(v)}}function eA(e,r,i){return l;function l(b){return e.enter("resource"),e.enter("resourceMarker"),e.consume(b),e.exit("resourceMarker"),o}function o(b){return st(b)?Ua(e,u)(b):u(b)}function u(b){return b===41?g(b):C0(e,c,f,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(b)}function c(b){return st(b)?Ua(e,h)(b):g(b)}function f(b){return i(b)}function h(b){return b===34||b===39||b===40?A0(e,p,i,"resourceTitle","resourceTitleMarker","resourceTitleString")(b):g(b)}function p(b){return st(b)?Ua(e,g)(b):g(b)}function g(b){return b===41?(e.enter("resourceMarker"),e.consume(b),e.exit("resourceMarker"),e.exit("resource"),r):i(b)}}function tA(e,r,i){const l=this;return o;function o(f){return N0.call(l,e,u,c,"reference","referenceMarker","referenceString")(f)}function u(f){return l.parser.defined.includes(qn(l.sliceSerialize(l.events[l.events.length-1][1]).slice(1,-1)))?r(f):i(f)}function c(f){return i(f)}}function nA(e,r,i){return l;function l(u){return e.enter("reference"),e.enter("referenceMarker"),e.consume(u),e.exit("referenceMarker"),o}function o(u){return u===93?(e.enter("referenceMarker"),e.consume(u),e.exit("referenceMarker"),e.exit("reference"),r):i(u)}}const rA={name:"labelStartImage",resolveAll:Fh.resolveAll,tokenize:iA};function iA(e,r,i){const l=this;return o;function o(f){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(f),e.exit("labelImageMarker"),u}function u(f){return f===91?(e.enter("labelMarker"),e.consume(f),e.exit("labelMarker"),e.exit("labelImage"),c):i(f)}function c(f){return f===94&&"_hiddenFootnoteSupport"in l.parser.constructs?i(f):r(f)}}const lA={name:"labelStartLink",resolveAll:Fh.resolveAll,tokenize:aA};function aA(e,r,i){const l=this;return o;function o(c){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(c),e.exit("labelMarker"),e.exit("labelLink"),u}function u(c){return c===94&&"_hiddenFootnoteSupport"in l.parser.constructs?i(c):r(c)}}const rd={name:"lineEnding",tokenize:oA};function oA(e,r){return i;function i(l){return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),Ge(e,r,"linePrefix")}}const Ds={name:"thematicBreak",tokenize:sA};function sA(e,r,i){let l=0,o;return u;function u(p){return e.enter("thematicBreak"),c(p)}function c(p){return o=p,f(p)}function f(p){return p===o?(e.enter("thematicBreakSequence"),h(p)):l>=3&&(p===null||Ae(p))?(e.exit("thematicBreak"),r(p)):i(p)}function h(p){return p===o?(e.consume(p),l++,h):(e.exit("thematicBreakSequence"),Be(p)?Ge(e,f,"whitespace")(p):f(p))}}const an={continuation:{tokenize:dA},exit:pA,name:"list",tokenize:fA},uA={partial:!0,tokenize:mA},cA={partial:!0,tokenize:hA};function fA(e,r,i){const l=this,o=l.events[l.events.length-1];let u=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,c=0;return f;function f(x){const S=l.containerState.type||(x===42||x===43||x===45?"listUnordered":"listOrdered");if(S==="listUnordered"?!l.containerState.marker||x===l.containerState.marker:Qd(x)){if(l.containerState.type||(l.containerState.type=S,e.enter(S,{_container:!0})),S==="listUnordered")return e.enter("listItemPrefix"),x===42||x===45?e.check(Ds,i,p)(x):p(x);if(!l.interrupt||x===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),h(x)}return i(x)}function h(x){return Qd(x)&&++c<10?(e.consume(x),h):(!l.interrupt||c<2)&&(l.containerState.marker?x===l.containerState.marker:x===41||x===46)?(e.exit("listItemValue"),p(x)):i(x)}function p(x){return e.enter("listItemMarker"),e.consume(x),e.exit("listItemMarker"),l.containerState.marker=l.containerState.marker||x,e.check(to,l.interrupt?i:g,e.attempt(uA,v,b))}function g(x){return l.containerState.initialBlankLine=!0,u++,v(x)}function b(x){return Be(x)?(e.enter("listItemPrefixWhitespace"),e.consume(x),e.exit("listItemPrefixWhitespace"),v):i(x)}function v(x){return l.containerState.size=u+l.sliceSerialize(e.exit("listItemPrefix"),!0).length,r(x)}}function dA(e,r,i){const l=this;return l.containerState._closeFlow=void 0,e.check(to,o,u);function o(f){return l.containerState.furtherBlankLines=l.containerState.furtherBlankLines||l.containerState.initialBlankLine,Ge(e,r,"listItemIndent",l.containerState.size+1)(f)}function u(f){return l.containerState.furtherBlankLines||!Be(f)?(l.containerState.furtherBlankLines=void 0,l.containerState.initialBlankLine=void 0,c(f)):(l.containerState.furtherBlankLines=void 0,l.containerState.initialBlankLine=void 0,e.attempt(cA,r,c)(f))}function c(f){return l.containerState._closeFlow=!0,l.interrupt=void 0,Ge(e,e.attempt(an,r,i),"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(f)}}function hA(e,r,i){const l=this;return Ge(e,o,"listItemIndent",l.containerState.size+1);function o(u){const c=l.events[l.events.length-1];return c&&c[1].type==="listItemIndent"&&c[2].sliceSerialize(c[1],!0).length===l.containerState.size?r(u):i(u)}}function pA(e){e.exit(this.containerState.type)}function mA(e,r,i){const l=this;return Ge(e,o,"listItemPrefixWhitespace",l.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function o(u){const c=l.events[l.events.length-1];return!Be(u)&&c&&c[1].type==="listItemPrefixWhitespace"?r(u):i(u)}}const nx={name:"setextUnderline",resolveTo:gA,tokenize:bA};function gA(e,r){let i=e.length,l,o,u;for(;i--;)if(e[i][0]==="enter"){if(e[i][1].type==="content"){l=i;break}e[i][1].type==="paragraph"&&(o=i)}else e[i][1].type==="content"&&e.splice(i,1),!u&&e[i][1].type==="definition"&&(u=i);const c={type:"setextHeading",start:{...e[l][1].start},end:{...e[e.length-1][1].end}};return e[o][1].type="setextHeadingText",u?(e.splice(o,0,["enter",c,r]),e.splice(u+1,0,["exit",e[l][1],r]),e[l][1].end={...e[u][1].end}):e[l][1]=c,e.push(["exit",c,r]),e}function bA(e,r,i){const l=this;let o;return u;function u(p){let g=l.events.length,b;for(;g--;)if(l.events[g][1].type!=="lineEnding"&&l.events[g][1].type!=="linePrefix"&&l.events[g][1].type!=="content"){b=l.events[g][1].type==="paragraph";break}return!l.parser.lazy[l.now().line]&&(l.interrupt||b)?(e.enter("setextHeadingLine"),o=p,c(p)):i(p)}function c(p){return e.enter("setextHeadingLineSequence"),f(p)}function f(p){return p===o?(e.consume(p),f):(e.exit("setextHeadingLineSequence"),Be(p)?Ge(e,h,"lineSuffix")(p):h(p))}function h(p){return p===null||Ae(p)?(e.exit("setextHeadingLine"),r(p)):i(p)}}const yA={tokenize:xA};function xA(e){const r=this,i=e.attempt(to,l,e.attempt(this.parser.constructs.flowInitial,o,Ge(e,e.attempt(this.parser.constructs.flow,o,e.attempt(EN,o)),"linePrefix")));return i;function l(u){if(u===null){e.consume(u);return}return e.enter("lineEndingBlank"),e.consume(u),e.exit("lineEndingBlank"),r.currentConstruct=void 0,i}function o(u){if(u===null){e.consume(u);return}return e.enter("lineEnding"),e.consume(u),e.exit("lineEnding"),r.currentConstruct=void 0,i}}const vA={resolveAll:j0()},wA=T0("string"),SA=T0("text");function T0(e){return{resolveAll:j0(e==="text"?kA:void 0),tokenize:r};function r(i){const l=this,o=this.parser.constructs[e],u=i.attempt(o,c,f);return c;function c(g){return p(g)?u(g):f(g)}function f(g){if(g===null){i.consume(g);return}return i.enter("data"),i.consume(g),h}function h(g){return p(g)?(i.exit("data"),u(g)):(i.consume(g),h)}function p(g){if(g===null)return!0;const b=o[g];let v=-1;if(b)for(;++v<b.length;){const x=b[v];if(!x.previous||x.previous.call(l,l.previous))return!0}return!1}}}function j0(e){return r;function r(i,l){let o=-1,u;for(;++o<=i.length;)u===void 0?i[o]&&i[o][1].type==="data"&&(u=o,o++):(!i[o]||i[o][1].type!=="data")&&(o!==u+2&&(i[u][1].end=i[o-1][1].end,i.splice(u+2,o-u-2),o=u+2),u=void 0);return e?e(i,l):i}}function kA(e,r){let i=0;for(;++i<=e.length;)if((i===e.length||e[i][1].type==="lineEnding")&&e[i-1][1].type==="data"){const l=e[i-1][1],o=r.sliceStream(l);let u=o.length,c=-1,f=0,h;for(;u--;){const p=o[u];if(typeof p=="string"){for(c=p.length;p.charCodeAt(c-1)===32;)f++,c--;if(c)break;c=-1}else if(p===-2)h=!0,f++;else if(p!==-1){u++;break}}if(r._contentTypeTextTrailing&&i===e.length&&(f=0),f){const p={type:i===e.length||h||f<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:u?c:l.start._bufferIndex+c,_index:l.start._index+u,line:l.end.line,column:l.end.column-f,offset:l.end.offset-f},end:{...l.end}};l.end={...p.start},l.start.offset===l.end.offset?Object.assign(l,p):(e.splice(i,0,["enter",p,r],["exit",p,r]),i+=2)}i++}return e}const EA={42:an,43:an,45:an,48:an,49:an,50:an,51:an,52:an,53:an,54:an,55:an,56:an,57:an,62:w0},CA={91:jN},NA={[-2]:nd,[-1]:nd,32:nd},AA={35:MN,42:Ds,45:[nx,Ds],60:IN,61:nx,95:Ds,96:ex,126:ex},TA={38:k0,92:S0},jA={[-5]:rd,[-4]:rd,[-3]:rd,33:rA,38:k0,42:Jd,60:[lN,GN],91:lA,92:[DN,S0],93:Fh,95:Jd,96:yN},RA={null:[Jd,vA]},_A={null:[42,95]},LA={null:[]},DA=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:_A,contentInitial:CA,disable:LA,document:EA,flow:AA,flowInitial:NA,insideSpan:RA,string:TA,text:jA},Symbol.toStringTag,{value:"Module"}));function OA(e,r,i){let l={_bufferIndex:-1,_index:0,line:i&&i.line||1,column:i&&i.column||1,offset:i&&i.offset||0};const o={},u=[];let c=[],f=[];const h={attempt:O(I),check:O(L),consume:C,enter:j,exit:z,interrupt:O(L,{interrupt:!0})},p={code:null,containerState:{},defineSkip:w,events:[],now:S,parser:e,previous:null,sliceSerialize:v,sliceStream:x,write:b};let g=r.tokenize.call(p,h);return r.resolveAll&&u.push(r),p;function b(H){return c=On(c,H),N(),c[c.length-1]!==null?[]:(Z(r,0),p.events=vu(u,p.events,p),p.events)}function v(H,G){return zA(x(H),G)}function x(H){return MA(c,H)}function S(){const{_bufferIndex:H,_index:G,line:Q,column:U,offset:Y}=l;return{_bufferIndex:H,_index:G,line:Q,column:U,offset:Y}}function w(H){o[H.line]=H.column,F()}function N(){let H;for(;l._index<c.length;){const G=c[l._index];if(typeof G=="string")for(H=l._index,l._bufferIndex<0&&(l._bufferIndex=0);l._index===H&&l._bufferIndex<G.length;)E(G.charCodeAt(l._bufferIndex));else E(G)}}function E(H){g=g(H)}function C(H){Ae(H)?(l.line++,l.column=1,l.offset+=H===-3?2:1,F()):H!==-1&&(l.column++,l.offset++),l._bufferIndex<0?l._index++:(l._bufferIndex++,l._bufferIndex===c[l._index].length&&(l._bufferIndex=-1,l._index++)),p.previous=H}function j(H,G){const Q=G||{};return Q.type=H,Q.start=S(),p.events.push(["enter",Q,p]),f.push(Q),Q}function z(H){const G=f.pop();return G.end=S(),p.events.push(["exit",G,p]),G}function I(H,G){Z(H,G.from)}function L(H,G){G.restore()}function O(H,G){return Q;function Q(U,Y,B){let X,M,V,R;return Array.isArray(U)?q(U):"tokenize"in U?q([U]):D(U);function D(fe){return ge;function ge(ye){const pe=ye!==null&&fe[ye],me=ye!==null&&fe.null,xe=[...Array.isArray(pe)?pe:pe?[pe]:[],...Array.isArray(me)?me:me?[me]:[]];return q(xe)(ye)}}function q(fe){return X=fe,M=0,fe.length===0?B:T(fe[M])}function T(fe){return ge;function ge(ye){return R=$(),V=fe,fe.partial||(p.currentConstruct=fe),fe.name&&p.parser.constructs.disable.null.includes(fe.name)?ie():fe.tokenize.call(G?Object.assign(Object.create(p),G):p,h,te,ie)(ye)}}function te(fe){return H(V,R),Y}function ie(fe){return R.restore(),++M<X.length?T(X[M]):B}}}function Z(H,G){H.resolveAll&&!u.includes(H)&&u.push(H),H.resolve&&kn(p.events,G,p.events.length-G,H.resolve(p.events.slice(G),p)),H.resolveTo&&(p.events=H.resolveTo(p.events,p))}function $(){const H=S(),G=p.previous,Q=p.currentConstruct,U=p.events.length,Y=Array.from(f);return{from:U,restore:B};function B(){l=H,p.previous=G,p.currentConstruct=Q,p.events.length=U,f=Y,F()}}function F(){l.line in o&&l.column<2&&(l.column=o[l.line],l.offset+=o[l.line]-1)}}function MA(e,r){const i=r.start._index,l=r.start._bufferIndex,o=r.end._index,u=r.end._bufferIndex;let c;if(i===o)c=[e[i].slice(l,u)];else{if(c=e.slice(i,o),l>-1){const f=c[0];typeof f=="string"?c[0]=f.slice(l):c.shift()}u>0&&c.push(e[o].slice(0,u))}return c}function zA(e,r){let i=-1;const l=[];let o;for(;++i<e.length;){const u=e[i];let c;if(typeof u=="string")c=u;else switch(u){case-5:{c="\r";break}case-4:{c=`
|
|
31
|
+
`;break}case-3:{c=`\r
|
|
32
|
+
`;break}case-2:{c=r?" ":" ";break}case-1:{if(!r&&o)continue;c=" ";break}default:c=String.fromCharCode(u)}o=u===-2,l.push(c)}return l.join("")}function FA(e){const l={constructs:x0([DA,...(e||{}).extensions||[]]),content:o(J4),defined:[],document:o(eN),flow:o(yA),lazy:{},string:o(wA),text:o(SA)};return l;function o(u){return c;function c(f){return OA(l,u,f)}}}function BA(e){for(;!E0(e););return e}const rx=/[\0\t\n\r]/g;function IA(){let e=1,r="",i=!0,l;return o;function o(u,c,f){const h=[];let p,g,b,v,x;for(u=r+(typeof u=="string"?u.toString():new TextDecoder(c||void 0).decode(u)),b=0,r="",i&&(u.charCodeAt(0)===65279&&b++,i=void 0);b<u.length;){if(rx.lastIndex=b,p=rx.exec(u),v=p&&p.index!==void 0?p.index:u.length,x=u.charCodeAt(v),!p){r=u.slice(b);break}if(x===10&&b===v&&l)h.push(-3),l=void 0;else switch(l&&(h.push(-5),l=void 0),b<v&&(h.push(u.slice(b,v)),e+=v-b),x){case 0:{h.push(65533),e++;break}case 9:{for(g=Math.ceil(e/4)*4,h.push(-2);e++<g;)h.push(-1);break}case 10:{h.push(-4),e=1;break}default:l=!0,e=1}b=v+1}return f&&(l&&h.push(-5),r&&h.push(r),h.push(null)),h}}const UA=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function HA(e){return e.replace(UA,qA)}function qA(e,r,i){if(r)return r;if(i.charCodeAt(0)===35){const o=i.charCodeAt(1),u=o===120||o===88;return v0(i.slice(u?2:1),u?16:10)}return zh(i)||e}const R0={}.hasOwnProperty;function $A(e,r,i){return typeof r!="string"&&(i=r,r=void 0),PA(i)(BA(FA(i).document().write(IA()(e,r,!0))))}function PA(e){const r={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:u(pt),autolinkProtocol:$,autolinkEmail:$,atxHeading:u(Pe),blockQuote:u(me),characterEscape:$,characterReference:$,codeFenced:u(xe),codeFencedFenceInfo:c,codeFencedFenceMeta:c,codeIndented:u(xe,c),codeText:u(de,c),codeTextData:$,data:$,codeFlowValue:$,definition:u(we),definitionDestinationString:c,definitionLabelString:c,definitionTitleString:c,emphasis:u(Ee),hardBreakEscape:u(Ke),hardBreakTrailing:u(Ke),htmlFlow:u(Me,c),htmlFlowData:$,htmlText:u(Me,c),htmlTextData:$,image:u(It),label:c,link:u(pt),listItem:u(Gt),listItemValue:v,listOrdered:u(mt,b),listUnordered:u(mt),paragraph:u(Yt),reference:T,referenceString:c,resourceDestinationString:c,resourceTitleString:c,setextHeading:u(Pe),strong:u(tt),thematicBreak:u(nr)},exit:{atxHeading:h(),atxHeadingSequence:I,autolink:h(),autolinkEmail:pe,autolinkProtocol:ye,blockQuote:h(),characterEscapeValue:F,characterReferenceMarkerHexadecimal:ie,characterReferenceMarkerNumeric:ie,characterReferenceValue:fe,characterReference:ge,codeFenced:h(N),codeFencedFence:w,codeFencedFenceInfo:x,codeFencedFenceMeta:S,codeFlowValue:F,codeIndented:h(E),codeText:h(Y),codeTextData:F,data:F,definition:h(),definitionDestinationString:z,definitionLabelString:C,definitionTitleString:j,emphasis:h(),hardBreakEscape:h(G),hardBreakTrailing:h(G),htmlFlow:h(Q),htmlFlowData:F,htmlText:h(U),htmlTextData:F,image:h(X),label:V,labelText:M,lineEnding:H,link:h(B),listItem:h(),listOrdered:h(),listUnordered:h(),paragraph:h(),referenceString:te,resourceDestinationString:R,resourceTitleString:D,resource:q,setextHeading:h(Z),setextHeadingLineSequence:O,setextHeadingText:L,strong:h(),thematicBreak:h()}};_0(r,(e||{}).mdastExtensions||[]);const i={};return l;function l(ae){let be={type:"root",children:[]};const Te={stack:[be],tokenStack:[],config:r,enter:f,exit:p,buffer:c,resume:g,data:i},Oe=[];let Ve=-1;for(;++Ve<ae.length;)if(ae[Ve][1].type==="listOrdered"||ae[Ve][1].type==="listUnordered")if(ae[Ve][0]==="enter")Oe.push(Ve);else{const Dt=Oe.pop();Ve=o(ae,Dt,Ve)}for(Ve=-1;++Ve<ae.length;){const Dt=r[ae[Ve][0]];R0.call(Dt,ae[Ve][1].type)&&Dt[ae[Ve][1].type].call(Object.assign({sliceSerialize:ae[Ve][2].sliceSerialize},Te),ae[Ve][1])}if(Te.tokenStack.length>0){const Dt=Te.tokenStack[Te.tokenStack.length-1];(Dt[1]||ix).call(Te,void 0,Dt[0])}for(be.position={start:ti(ae.length>0?ae[0][1].start:{line:1,column:1,offset:0}),end:ti(ae.length>0?ae[ae.length-2][1].end:{line:1,column:1,offset:0})},Ve=-1;++Ve<r.transforms.length;)be=r.transforms[Ve](be)||be;return be}function o(ae,be,Te){let Oe=be-1,Ve=-1,Dt=!1,zn,Ot,gt,Ut;for(;++Oe<=Te;){const Je=ae[Oe];switch(Je[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Je[0]==="enter"?Ve++:Ve--,Ut=void 0;break}case"lineEndingBlank":{Je[0]==="enter"&&(zn&&!Ut&&!Ve&&!gt&&(gt=Oe),Ut=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Ut=void 0}if(!Ve&&Je[0]==="enter"&&Je[1].type==="listItemPrefix"||Ve===-1&&Je[0]==="exit"&&(Je[1].type==="listUnordered"||Je[1].type==="listOrdered")){if(zn){let $n=Oe;for(Ot=void 0;$n--;){const fn=ae[$n];if(fn[1].type==="lineEnding"||fn[1].type==="lineEndingBlank"){if(fn[0]==="exit")continue;Ot&&(ae[Ot][1].type="lineEndingBlank",Dt=!0),fn[1].type="lineEnding",Ot=$n}else if(!(fn[1].type==="linePrefix"||fn[1].type==="blockQuotePrefix"||fn[1].type==="blockQuotePrefixWhitespace"||fn[1].type==="blockQuoteMarker"||fn[1].type==="listItemIndent"))break}gt&&(!Ot||gt<Ot)&&(zn._spread=!0),zn.end=Object.assign({},Ot?ae[Ot][1].start:Je[1].end),ae.splice(Ot||Oe,0,["exit",zn,Je[2]]),Oe++,Te++}if(Je[1].type==="listItemPrefix"){const $n={type:"listItem",_spread:!1,start:Object.assign({},Je[1].start),end:void 0};zn=$n,ae.splice(Oe,0,["enter",$n,Je[2]]),Oe++,Te++,gt=void 0,Ut=!0}}}return ae[be][1]._spread=Dt,Te}function u(ae,be){return Te;function Te(Oe){f.call(this,ae(Oe),Oe),be&&be.call(this,Oe)}}function c(){this.stack.push({type:"fragment",children:[]})}function f(ae,be,Te){this.stack[this.stack.length-1].children.push(ae),this.stack.push(ae),this.tokenStack.push([be,Te||void 0]),ae.position={start:ti(be.start),end:void 0}}function h(ae){return be;function be(Te){ae&&ae.call(this,Te),p.call(this,Te)}}function p(ae,be){const Te=this.stack.pop(),Oe=this.tokenStack.pop();if(Oe)Oe[0].type!==ae.type&&(be?be.call(this,ae,Oe[0]):(Oe[1]||ix).call(this,ae,Oe[0]));else throw new Error("Cannot close `"+ae.type+"` ("+Ia({start:ae.start,end:ae.end})+"): it’s not open");Te.position.end=ti(ae.end)}function g(){return Mh(this.stack.pop())}function b(){this.data.expectingFirstListItemValue=!0}function v(ae){if(this.data.expectingFirstListItemValue){const be=this.stack[this.stack.length-2];be.start=Number.parseInt(this.sliceSerialize(ae),10),this.data.expectingFirstListItemValue=void 0}}function x(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.lang=ae}function S(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.meta=ae}function w(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function N(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.value=ae.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function E(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.value=ae.replace(/(\r?\n|\r)$/g,"")}function C(ae){const be=this.resume(),Te=this.stack[this.stack.length-1];Te.label=be,Te.identifier=qn(this.sliceSerialize(ae)).toLowerCase()}function j(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.title=ae}function z(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.url=ae}function I(ae){const be=this.stack[this.stack.length-1];if(!be.depth){const Te=this.sliceSerialize(ae).length;be.depth=Te}}function L(){this.data.setextHeadingSlurpLineEnding=!0}function O(ae){const be=this.stack[this.stack.length-1];be.depth=this.sliceSerialize(ae).codePointAt(0)===61?1:2}function Z(){this.data.setextHeadingSlurpLineEnding=void 0}function $(ae){const Te=this.stack[this.stack.length-1].children;let Oe=Te[Te.length-1];(!Oe||Oe.type!=="text")&&(Oe=at(),Oe.position={start:ti(ae.start),end:void 0},Te.push(Oe)),this.stack.push(Oe)}function F(ae){const be=this.stack.pop();be.value+=this.sliceSerialize(ae),be.position.end=ti(ae.end)}function H(ae){const be=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Te=be.children[be.children.length-1];Te.position.end=ti(ae.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&r.canContainEols.includes(be.type)&&($.call(this,ae),F.call(this,ae))}function G(){this.data.atHardBreak=!0}function Q(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.value=ae}function U(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.value=ae}function Y(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.value=ae}function B(){const ae=this.stack[this.stack.length-1];if(this.data.inReference){const be=this.data.referenceType||"shortcut";ae.type+="Reference",ae.referenceType=be,delete ae.url,delete ae.title}else delete ae.identifier,delete ae.label;this.data.referenceType=void 0}function X(){const ae=this.stack[this.stack.length-1];if(this.data.inReference){const be=this.data.referenceType||"shortcut";ae.type+="Reference",ae.referenceType=be,delete ae.url,delete ae.title}else delete ae.identifier,delete ae.label;this.data.referenceType=void 0}function M(ae){const be=this.sliceSerialize(ae),Te=this.stack[this.stack.length-2];Te.label=HA(be),Te.identifier=qn(be).toLowerCase()}function V(){const ae=this.stack[this.stack.length-1],be=this.resume(),Te=this.stack[this.stack.length-1];if(this.data.inReference=!0,Te.type==="link"){const Oe=ae.children;Te.children=Oe}else Te.alt=be}function R(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.url=ae}function D(){const ae=this.resume(),be=this.stack[this.stack.length-1];be.title=ae}function q(){this.data.inReference=void 0}function T(){this.data.referenceType="collapsed"}function te(ae){const be=this.resume(),Te=this.stack[this.stack.length-1];Te.label=be,Te.identifier=qn(this.sliceSerialize(ae)).toLowerCase(),this.data.referenceType="full"}function ie(ae){this.data.characterReferenceType=ae.type}function fe(ae){const be=this.sliceSerialize(ae),Te=this.data.characterReferenceType;let Oe;Te?(Oe=v0(be,Te==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Oe=zh(be);const Ve=this.stack[this.stack.length-1];Ve.value+=Oe}function ge(ae){const be=this.stack.pop();be.position.end=ti(ae.end)}function ye(ae){F.call(this,ae);const be=this.stack[this.stack.length-1];be.url=this.sliceSerialize(ae)}function pe(ae){F.call(this,ae);const be=this.stack[this.stack.length-1];be.url="mailto:"+this.sliceSerialize(ae)}function me(){return{type:"blockquote",children:[]}}function xe(){return{type:"code",lang:null,meta:null,value:""}}function de(){return{type:"inlineCode",value:""}}function we(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Ee(){return{type:"emphasis",children:[]}}function Pe(){return{type:"heading",depth:0,children:[]}}function Ke(){return{type:"break"}}function Me(){return{type:"html",value:""}}function It(){return{type:"image",title:null,url:"",alt:null}}function pt(){return{type:"link",title:null,url:"",children:[]}}function mt(ae){return{type:"list",ordered:ae.type==="listOrdered",start:null,spread:ae._spread,children:[]}}function Gt(ae){return{type:"listItem",spread:ae._spread,checked:null,children:[]}}function Yt(){return{type:"paragraph",children:[]}}function tt(){return{type:"strong",children:[]}}function at(){return{type:"text",value:""}}function nr(){return{type:"thematicBreak"}}}function ti(e){return{line:e.line,column:e.column,offset:e.offset}}function _0(e,r){let i=-1;for(;++i<r.length;){const l=r[i];Array.isArray(l)?_0(e,l):VA(e,l)}}function VA(e,r){let i;for(i in r)if(R0.call(r,i))switch(i){case"canContainEols":{const l=r[i];l&&e[i].push(...l);break}case"transforms":{const l=r[i];l&&e[i].push(...l);break}case"enter":case"exit":{const l=r[i];l&&Object.assign(e[i],l);break}}}function ix(e,r){throw e?new Error("Cannot close `"+e.type+"` ("+Ia({start:e.start,end:e.end})+"): a different token (`"+r.type+"`, "+Ia({start:r.start,end:r.end})+") is open"):new Error("Cannot close document, a token (`"+r.type+"`, "+Ia({start:r.start,end:r.end})+") is still open")}function GA(e){const r=this;r.parser=i;function i(l){return $A(l,{...r.data("settings"),...e,extensions:r.data("micromarkExtensions")||[],mdastExtensions:r.data("fromMarkdownExtensions")||[]})}}function YA(e,r){const i={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(r),!0)};return e.patch(r,i),e.applyData(r,i)}function XA(e,r){const i={type:"element",tagName:"br",properties:{},children:[]};return e.patch(r,i),[e.applyData(r,i),{type:"text",value:`
|
|
33
|
+
`}]}function ZA(e,r){const i=r.value?r.value+`
|
|
34
|
+
`:"",l={},o=r.lang?r.lang.split(/\s+/):[];o.length>0&&(l.className=["language-"+o[0]]);let u={type:"element",tagName:"code",properties:l,children:[{type:"text",value:i}]};return r.meta&&(u.data={meta:r.meta}),e.patch(r,u),u=e.applyData(r,u),u={type:"element",tagName:"pre",properties:{},children:[u]},e.patch(r,u),u}function KA(e,r){const i={type:"element",tagName:"del",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function QA(e,r){const i={type:"element",tagName:"em",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function JA(e,r){const i=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",l=String(r.identifier).toUpperCase(),o=zl(l.toLowerCase()),u=e.footnoteOrder.indexOf(l);let c,f=e.footnoteCounts.get(l);f===void 0?(f=0,e.footnoteOrder.push(l),c=e.footnoteOrder.length):c=u+1,f+=1,e.footnoteCounts.set(l,f);const h={type:"element",tagName:"a",properties:{href:"#"+i+"fn-"+o,id:i+"fnref-"+o+(f>1?"-"+f:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(c)}]};e.patch(r,h);const p={type:"element",tagName:"sup",properties:{},children:[h]};return e.patch(r,p),e.applyData(r,p)}function WA(e,r){const i={type:"element",tagName:"h"+r.depth,properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function eT(e,r){if(e.options.allowDangerousHtml){const i={type:"raw",value:r.value};return e.patch(r,i),e.applyData(r,i)}}function L0(e,r){const i=r.referenceType;let l="]";if(i==="collapsed"?l+="[]":i==="full"&&(l+="["+(r.label||r.identifier)+"]"),r.type==="imageReference")return[{type:"text",value:"!["+r.alt+l}];const o=e.all(r),u=o[0];u&&u.type==="text"?u.value="["+u.value:o.unshift({type:"text",value:"["});const c=o[o.length-1];return c&&c.type==="text"?c.value+=l:o.push({type:"text",value:l}),o}function tT(e,r){const i=String(r.identifier).toUpperCase(),l=e.definitionById.get(i);if(!l)return L0(e,r);const o={src:zl(l.url||""),alt:r.alt};l.title!==null&&l.title!==void 0&&(o.title=l.title);const u={type:"element",tagName:"img",properties:o,children:[]};return e.patch(r,u),e.applyData(r,u)}function nT(e,r){const i={src:zl(r.url)};r.alt!==null&&r.alt!==void 0&&(i.alt=r.alt),r.title!==null&&r.title!==void 0&&(i.title=r.title);const l={type:"element",tagName:"img",properties:i,children:[]};return e.patch(r,l),e.applyData(r,l)}function rT(e,r){const i={type:"text",value:r.value.replace(/\r?\n|\r/g," ")};e.patch(r,i);const l={type:"element",tagName:"code",properties:{},children:[i]};return e.patch(r,l),e.applyData(r,l)}function iT(e,r){const i=String(r.identifier).toUpperCase(),l=e.definitionById.get(i);if(!l)return L0(e,r);const o={href:zl(l.url||"")};l.title!==null&&l.title!==void 0&&(o.title=l.title);const u={type:"element",tagName:"a",properties:o,children:e.all(r)};return e.patch(r,u),e.applyData(r,u)}function lT(e,r){const i={href:zl(r.url)};r.title!==null&&r.title!==void 0&&(i.title=r.title);const l={type:"element",tagName:"a",properties:i,children:e.all(r)};return e.patch(r,l),e.applyData(r,l)}function aT(e,r,i){const l=e.all(r),o=i?oT(i):D0(r),u={},c=[];if(typeof r.checked=="boolean"){const g=l[0];let b;g&&g.type==="element"&&g.tagName==="p"?b=g:(b={type:"element",tagName:"p",properties:{},children:[]},l.unshift(b)),b.children.length>0&&b.children.unshift({type:"text",value:" "}),b.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:r.checked,disabled:!0},children:[]}),u.className=["task-list-item"]}let f=-1;for(;++f<l.length;){const g=l[f];(o||f!==0||g.type!=="element"||g.tagName!=="p")&&c.push({type:"text",value:`
|
|
35
|
+
`}),g.type==="element"&&g.tagName==="p"&&!o?c.push(...g.children):c.push(g)}const h=l[l.length-1];h&&(o||h.type!=="element"||h.tagName!=="p")&&c.push({type:"text",value:`
|
|
36
|
+
`});const p={type:"element",tagName:"li",properties:u,children:c};return e.patch(r,p),e.applyData(r,p)}function oT(e){let r=!1;if(e.type==="list"){r=e.spread||!1;const i=e.children;let l=-1;for(;!r&&++l<i.length;)r=D0(i[l])}return r}function D0(e){const r=e.spread;return r??e.children.length>1}function sT(e,r){const i={},l=e.all(r);let o=-1;for(typeof r.start=="number"&&r.start!==1&&(i.start=r.start);++o<l.length;){const c=l[o];if(c.type==="element"&&c.tagName==="li"&&c.properties&&Array.isArray(c.properties.className)&&c.properties.className.includes("task-list-item")){i.className=["contains-task-list"];break}}const u={type:"element",tagName:r.ordered?"ol":"ul",properties:i,children:e.wrap(l,!0)};return e.patch(r,u),e.applyData(r,u)}function uT(e,r){const i={type:"element",tagName:"p",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function cT(e,r){const i={type:"root",children:e.wrap(e.all(r))};return e.patch(r,i),e.applyData(r,i)}function fT(e,r){const i={type:"element",tagName:"strong",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}function dT(e,r){const i=e.all(r),l=i.shift(),o=[];if(l){const c={type:"element",tagName:"thead",properties:{},children:e.wrap([l],!0)};e.patch(r.children[0],c),o.push(c)}if(i.length>0){const c={type:"element",tagName:"tbody",properties:{},children:e.wrap(i,!0)},f=_h(r.children[1]),h=d0(r.children[r.children.length-1]);f&&h&&(c.position={start:f,end:h}),o.push(c)}const u={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(r,u),e.applyData(r,u)}function hT(e,r,i){const l=i?i.children:void 0,u=(l?l.indexOf(r):1)===0?"th":"td",c=i&&i.type==="table"?i.align:void 0,f=c?c.length:r.children.length;let h=-1;const p=[];for(;++h<f;){const b=r.children[h],v={},x=c?c[h]:void 0;x&&(v.align=x);let S={type:"element",tagName:u,properties:v,children:[]};b&&(S.children=e.all(b),e.patch(b,S),S=e.applyData(b,S)),p.push(S)}const g={type:"element",tagName:"tr",properties:{},children:e.wrap(p,!0)};return e.patch(r,g),e.applyData(r,g)}function pT(e,r){const i={type:"element",tagName:"td",properties:{},children:e.all(r)};return e.patch(r,i),e.applyData(r,i)}const lx=9,ax=32;function mT(e){const r=String(e),i=/\r?\n|\r/g;let l=i.exec(r),o=0;const u=[];for(;l;)u.push(ox(r.slice(o,l.index),o>0,!0),l[0]),o=l.index+l[0].length,l=i.exec(r);return u.push(ox(r.slice(o),o>0,!1)),u.join("")}function ox(e,r,i){let l=0,o=e.length;if(r){let u=e.codePointAt(l);for(;u===lx||u===ax;)l++,u=e.codePointAt(l)}if(i){let u=e.codePointAt(o-1);for(;u===lx||u===ax;)o--,u=e.codePointAt(o-1)}return o>l?e.slice(l,o):""}function gT(e,r){const i={type:"text",value:mT(String(r.value))};return e.patch(r,i),e.applyData(r,i)}function bT(e,r){const i={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(r,i),e.applyData(r,i)}const yT={blockquote:YA,break:XA,code:ZA,delete:KA,emphasis:QA,footnoteReference:JA,heading:WA,html:eT,imageReference:tT,image:nT,inlineCode:rT,linkReference:iT,link:lT,listItem:aT,list:sT,paragraph:uT,root:cT,strong:fT,table:dT,tableCell:pT,tableRow:hT,text:gT,thematicBreak:bT,toml:Ns,yaml:Ns,definition:Ns,footnoteDefinition:Ns};function Ns(){}const O0=-1,wu=0,Ha=1,Ks=2,Bh=3,Ih=4,Uh=5,Hh=6,M0=7,z0=8,sx=typeof self=="object"?self:globalThis,xT=(e,r)=>{const i=(o,u)=>(e.set(u,o),o),l=o=>{if(e.has(o))return e.get(o);const[u,c]=r[o];switch(u){case wu:case O0:return i(c,o);case Ha:{const f=i([],o);for(const h of c)f.push(l(h));return f}case Ks:{const f=i({},o);for(const[h,p]of c)f[l(h)]=l(p);return f}case Bh:return i(new Date(c),o);case Ih:{const{source:f,flags:h}=c;return i(new RegExp(f,h),o)}case Uh:{const f=i(new Map,o);for(const[h,p]of c)f.set(l(h),l(p));return f}case Hh:{const f=i(new Set,o);for(const h of c)f.add(l(h));return f}case M0:{const{name:f,message:h}=c;return i(new sx[f](h),o)}case z0:return i(BigInt(c),o);case"BigInt":return i(Object(BigInt(c)),o);case"ArrayBuffer":return i(new Uint8Array(c).buffer,c);case"DataView":{const{buffer:f}=new Uint8Array(c);return i(new DataView(f),c)}}return i(new sx[u](c),o)};return l},ux=e=>xT(new Map,e)(0),kl="",{toString:vT}={},{keys:wT}=Object,Oa=e=>{const r=typeof e;if(r!=="object"||!e)return[wu,r];const i=vT.call(e).slice(8,-1);switch(i){case"Array":return[Ha,kl];case"Object":return[Ks,kl];case"Date":return[Bh,kl];case"RegExp":return[Ih,kl];case"Map":return[Uh,kl];case"Set":return[Hh,kl];case"DataView":return[Ha,i]}return i.includes("Array")?[Ha,i]:i.includes("Error")?[M0,i]:[Ks,i]},As=([e,r])=>e===wu&&(r==="function"||r==="symbol"),ST=(e,r,i,l)=>{const o=(c,f)=>{const h=l.push(c)-1;return i.set(f,h),h},u=c=>{if(i.has(c))return i.get(c);let[f,h]=Oa(c);switch(f){case wu:{let g=c;switch(h){case"bigint":f=z0,g=c.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+h);g=null;break;case"undefined":return o([O0],c)}return o([f,g],c)}case Ha:{if(h){let v=c;return h==="DataView"?v=new Uint8Array(c.buffer):h==="ArrayBuffer"&&(v=new Uint8Array(c)),o([h,[...v]],c)}const g=[],b=o([f,g],c);for(const v of c)g.push(u(v));return b}case Ks:{if(h)switch(h){case"BigInt":return o([h,c.toString()],c);case"Boolean":case"Number":case"String":return o([h,c.valueOf()],c)}if(r&&"toJSON"in c)return u(c.toJSON());const g=[],b=o([f,g],c);for(const v of wT(c))(e||!As(Oa(c[v])))&&g.push([u(v),u(c[v])]);return b}case Bh:return o([f,c.toISOString()],c);case Ih:{const{source:g,flags:b}=c;return o([f,{source:g,flags:b}],c)}case Uh:{const g=[],b=o([f,g],c);for(const[v,x]of c)(e||!(As(Oa(v))||As(Oa(x))))&&g.push([u(v),u(x)]);return b}case Hh:{const g=[],b=o([f,g],c);for(const v of c)(e||!As(Oa(v)))&&g.push(u(v));return b}}const{message:p}=c;return o([f,{name:h,message:p}],c)};return u},cx=(e,{json:r,lossy:i}={})=>{const l=[];return ST(!(r||i),!!r,new Map,l)(e),l},Qs=typeof structuredClone=="function"?(e,r)=>r&&("json"in r||"lossy"in r)?ux(cx(e,r)):structuredClone(e):(e,r)=>ux(cx(e,r));function kT(e,r){const i=[{type:"text",value:"↩"}];return r>1&&i.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(r)}]}),i}function ET(e,r){return"Back to reference "+(e+1)+(r>1?"-"+r:"")}function CT(e){const r=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",i=e.options.footnoteBackContent||kT,l=e.options.footnoteBackLabel||ET,o=e.options.footnoteLabel||"Footnotes",u=e.options.footnoteLabelTagName||"h2",c=e.options.footnoteLabelProperties||{className:["sr-only"]},f=[];let h=-1;for(;++h<e.footnoteOrder.length;){const p=e.footnoteById.get(e.footnoteOrder[h]);if(!p)continue;const g=e.all(p),b=String(p.identifier).toUpperCase(),v=zl(b.toLowerCase());let x=0;const S=[],w=e.footnoteCounts.get(b);for(;w!==void 0&&++x<=w;){S.length>0&&S.push({type:"text",value:" "});let C=typeof i=="string"?i:i(h,x);typeof C=="string"&&(C={type:"text",value:C}),S.push({type:"element",tagName:"a",properties:{href:"#"+r+"fnref-"+v+(x>1?"-"+x:""),dataFootnoteBackref:"",ariaLabel:typeof l=="string"?l:l(h,x),className:["data-footnote-backref"]},children:Array.isArray(C)?C:[C]})}const N=g[g.length-1];if(N&&N.type==="element"&&N.tagName==="p"){const C=N.children[N.children.length-1];C&&C.type==="text"?C.value+=" ":N.children.push({type:"text",value:" "}),N.children.push(...S)}else g.push(...S);const E={type:"element",tagName:"li",properties:{id:r+"fn-"+v},children:e.wrap(g,!0)};e.patch(p,E),f.push(E)}if(f.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:u,properties:{...Qs(c),id:"footnote-label"},children:[{type:"text",value:o}]},{type:"text",value:`
|
|
37
|
+
`},{type:"element",tagName:"ol",properties:{},children:e.wrap(f,!0)},{type:"text",value:`
|
|
38
|
+
`}]}}const Su=(function(e){if(e==null)return jT;if(typeof e=="function")return ku(e);if(typeof e=="object")return Array.isArray(e)?NT(e):AT(e);if(typeof e=="string")return TT(e);throw new Error("Expected function, string, or object as test")});function NT(e){const r=[];let i=-1;for(;++i<e.length;)r[i]=Su(e[i]);return ku(l);function l(...o){let u=-1;for(;++u<r.length;)if(r[u].apply(this,o))return!0;return!1}}function AT(e){const r=e;return ku(i);function i(l){const o=l;let u;for(u in e)if(o[u]!==r[u])return!1;return!0}}function TT(e){return ku(r);function r(i){return i&&i.type===e}}function ku(e){return r;function r(i,l,o){return!!(RT(i)&&e.call(this,i,typeof l=="number"?l:void 0,o||void 0))}}function jT(){return!0}function RT(e){return e!==null&&typeof e=="object"&&"type"in e}const F0=[],_T=!0,Wd=!1,LT="skip";function B0(e,r,i,l){let o;typeof r=="function"&&typeof i!="function"?(l=i,i=r):o=r;const u=Su(o),c=l?-1:1;f(e,void 0,[])();function f(h,p,g){const b=h&&typeof h=="object"?h:{};if(typeof b.type=="string"){const x=typeof b.tagName=="string"?b.tagName:typeof b.name=="string"?b.name:void 0;Object.defineProperty(v,"name",{value:"node ("+(h.type+(x?"<"+x+">":""))+")"})}return v;function v(){let x=F0,S,w,N;if((!r||u(h,p,g[g.length-1]||void 0))&&(x=DT(i(h,g)),x[0]===Wd))return x;if("children"in h&&h.children){const E=h;if(E.children&&x[0]!==LT)for(w=(l?E.children.length:-1)+c,N=g.concat(E);w>-1&&w<E.children.length;){const C=E.children[w];if(S=f(C,w,N)(),S[0]===Wd)return S;w=typeof S[1]=="number"?S[1]:w+c}}return x}}}function DT(e){return Array.isArray(e)?e:typeof e=="number"?[_T,e]:e==null?F0:[e]}function qh(e,r,i,l){let o,u,c;typeof r=="function"&&typeof i!="function"?(u=void 0,c=r,o=i):(u=r,c=i,o=l),B0(e,u,f,o);function f(h,p){const g=p[p.length-1],b=g?g.children.indexOf(h):void 0;return c(h,b,g)}}const eh={}.hasOwnProperty,OT={};function MT(e,r){const i=r||OT,l=new Map,o=new Map,u=new Map,c={...yT,...i.handlers},f={all:p,applyData:FT,definitionById:l,footnoteById:o,footnoteCounts:u,footnoteOrder:[],handlers:c,one:h,options:i,patch:zT,wrap:IT};return qh(e,function(g){if(g.type==="definition"||g.type==="footnoteDefinition"){const b=g.type==="definition"?l:o,v=String(g.identifier).toUpperCase();b.has(v)||b.set(v,g)}}),f;function h(g,b){const v=g.type,x=f.handlers[v];if(eh.call(f.handlers,v)&&x)return x(f,g,b);if(f.options.passThrough&&f.options.passThrough.includes(v)){if("children"in g){const{children:w,...N}=g,E=Qs(N);return E.children=f.all(g),E}return Qs(g)}return(f.options.unknownHandler||BT)(f,g,b)}function p(g){const b=[];if("children"in g){const v=g.children;let x=-1;for(;++x<v.length;){const S=f.one(v[x],g);if(S){if(x&&v[x-1].type==="break"&&(!Array.isArray(S)&&S.type==="text"&&(S.value=fx(S.value)),!Array.isArray(S)&&S.type==="element")){const w=S.children[0];w&&w.type==="text"&&(w.value=fx(w.value))}Array.isArray(S)?b.push(...S):b.push(S)}}}return b}}function zT(e,r){e.position&&(r.position=E4(e))}function FT(e,r){let i=r;if(e&&e.data){const l=e.data.hName,o=e.data.hChildren,u=e.data.hProperties;if(typeof l=="string")if(i.type==="element")i.tagName=l;else{const c="children"in i?i.children:[i];i={type:"element",tagName:l,properties:{},children:c}}i.type==="element"&&u&&Object.assign(i.properties,Qs(u)),"children"in i&&i.children&&o!==null&&o!==void 0&&(i.children=o)}return i}function BT(e,r){const i=r.data||{},l="value"in r&&!(eh.call(i,"hProperties")||eh.call(i,"hChildren"))?{type:"text",value:r.value}:{type:"element",tagName:"div",properties:{},children:e.all(r)};return e.patch(r,l),e.applyData(r,l)}function IT(e,r){const i=[];let l=-1;for(r&&i.push({type:"text",value:`
|
|
39
|
+
`});++l<e.length;)l&&i.push({type:"text",value:`
|
|
40
|
+
`}),i.push(e[l]);return r&&e.length>0&&i.push({type:"text",value:`
|
|
41
|
+
`}),i}function fx(e){let r=0,i=e.charCodeAt(r);for(;i===9||i===32;)r++,i=e.charCodeAt(r);return e.slice(r)}function dx(e,r){const i=MT(e,r),l=i.one(e,void 0),o=CT(i),u=Array.isArray(l)?{type:"root",children:l}:l||{type:"root",children:[]};return o&&u.children.push({type:"text",value:`
|
|
42
|
+
`},o),u}function UT(e,r){return e&&"run"in e?async function(i,l){const o=dx(i,{file:l,...r});await e.run(o,l)}:function(i,l){return dx(i,{file:l,...e||r})}}function hx(e){if(e)throw e}var id,px;function HT(){if(px)return id;px=1;var e=Object.prototype.hasOwnProperty,r=Object.prototype.toString,i=Object.defineProperty,l=Object.getOwnPropertyDescriptor,o=function(p){return typeof Array.isArray=="function"?Array.isArray(p):r.call(p)==="[object Array]"},u=function(p){if(!p||r.call(p)!=="[object Object]")return!1;var g=e.call(p,"constructor"),b=p.constructor&&p.constructor.prototype&&e.call(p.constructor.prototype,"isPrototypeOf");if(p.constructor&&!g&&!b)return!1;var v;for(v in p);return typeof v>"u"||e.call(p,v)},c=function(p,g){i&&g.name==="__proto__"?i(p,g.name,{enumerable:!0,configurable:!0,value:g.newValue,writable:!0}):p[g.name]=g.newValue},f=function(p,g){if(g==="__proto__")if(e.call(p,g)){if(l)return l(p,g).value}else return;return p[g]};return id=function h(){var p,g,b,v,x,S,w=arguments[0],N=1,E=arguments.length,C=!1;for(typeof w=="boolean"&&(C=w,w=arguments[1]||{},N=2),(w==null||typeof w!="object"&&typeof w!="function")&&(w={});N<E;++N)if(p=arguments[N],p!=null)for(g in p)b=f(w,g),v=f(p,g),w!==v&&(C&&v&&(u(v)||(x=o(v)))?(x?(x=!1,S=b&&o(b)?b:[]):S=b&&u(b)?b:{},c(w,{name:g,newValue:h(C,S,v)})):typeof v<"u"&&c(w,{name:g,newValue:v}));return w},id}var qT=HT();const ld=lu(qT);function th(e){if(typeof e!="object"||e===null)return!1;const r=Object.getPrototypeOf(e);return(r===null||r===Object.prototype||Object.getPrototypeOf(r)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function $T(){const e=[],r={run:i,use:l};return r;function i(...o){let u=-1;const c=o.pop();if(typeof c!="function")throw new TypeError("Expected function as last argument, not "+c);f(null,...o);function f(h,...p){const g=e[++u];let b=-1;if(h){c(h);return}for(;++b<o.length;)(p[b]===null||p[b]===void 0)&&(p[b]=o[b]);o=p,g?PT(g,f)(...p):c(null,...p)}}function l(o){if(typeof o!="function")throw new TypeError("Expected `middelware` to be a function, not "+o);return e.push(o),r}}function PT(e,r){let i;return l;function l(...c){const f=e.length>c.length;let h;f&&c.push(o);try{h=e.apply(this,c)}catch(p){const g=p;if(f&&i)throw g;return o(g)}f||(h&&h.then&&typeof h.then=="function"?h.then(u,o):h instanceof Error?o(h):u(h))}function o(c,...f){i||(i=!0,r(c,...f))}function u(c){o(null,c)}}const Qn={basename:VT,dirname:GT,extname:YT,join:XT,sep:"/"};function VT(e,r){if(r!==void 0&&typeof r!="string")throw new TypeError('"ext" argument must be a string');no(e);let i=0,l=-1,o=e.length,u;if(r===void 0||r.length===0||r.length>e.length){for(;o--;)if(e.codePointAt(o)===47){if(u){i=o+1;break}}else l<0&&(u=!0,l=o+1);return l<0?"":e.slice(i,l)}if(r===e)return"";let c=-1,f=r.length-1;for(;o--;)if(e.codePointAt(o)===47){if(u){i=o+1;break}}else c<0&&(u=!0,c=o+1),f>-1&&(e.codePointAt(o)===r.codePointAt(f--)?f<0&&(l=o):(f=-1,l=c));return i===l?l=c:l<0&&(l=e.length),e.slice(i,l)}function GT(e){if(no(e),e.length===0)return".";let r=-1,i=e.length,l;for(;--i;)if(e.codePointAt(i)===47){if(l){r=i;break}}else l||(l=!0);return r<0?e.codePointAt(0)===47?"/":".":r===1&&e.codePointAt(0)===47?"//":e.slice(0,r)}function YT(e){no(e);let r=e.length,i=-1,l=0,o=-1,u=0,c;for(;r--;){const f=e.codePointAt(r);if(f===47){if(c){l=r+1;break}continue}i<0&&(c=!0,i=r+1),f===46?o<0?o=r:u!==1&&(u=1):o>-1&&(u=-1)}return o<0||i<0||u===0||u===1&&o===i-1&&o===l+1?"":e.slice(o,i)}function XT(...e){let r=-1,i;for(;++r<e.length;)no(e[r]),e[r]&&(i=i===void 0?e[r]:i+"/"+e[r]);return i===void 0?".":ZT(i)}function ZT(e){no(e);const r=e.codePointAt(0)===47;let i=KT(e,!r);return i.length===0&&!r&&(i="."),i.length>0&&e.codePointAt(e.length-1)===47&&(i+="/"),r?"/"+i:i}function KT(e,r){let i="",l=0,o=-1,u=0,c=-1,f,h;for(;++c<=e.length;){if(c<e.length)f=e.codePointAt(c);else{if(f===47)break;f=47}if(f===47){if(!(o===c-1||u===1))if(o!==c-1&&u===2){if(i.length<2||l!==2||i.codePointAt(i.length-1)!==46||i.codePointAt(i.length-2)!==46){if(i.length>2){if(h=i.lastIndexOf("/"),h!==i.length-1){h<0?(i="",l=0):(i=i.slice(0,h),l=i.length-1-i.lastIndexOf("/")),o=c,u=0;continue}}else if(i.length>0){i="",l=0,o=c,u=0;continue}}r&&(i=i.length>0?i+"/..":"..",l=2)}else i.length>0?i+="/"+e.slice(o+1,c):i=e.slice(o+1,c),l=c-o-1;o=c,u=0}else f===46&&u>-1?u++:u=-1}return i}function no(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const QT={cwd:JT};function JT(){return"/"}function nh(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function WT(e){if(typeof e=="string")e=new URL(e);else if(!nh(e)){const r=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw r.code="ERR_INVALID_ARG_TYPE",r}if(e.protocol!=="file:"){const r=new TypeError("The URL must be of scheme file");throw r.code="ERR_INVALID_URL_SCHEME",r}return e6(e)}function e6(e){if(e.hostname!==""){const l=new TypeError('File URL host must be "localhost" or empty on darwin');throw l.code="ERR_INVALID_FILE_URL_HOST",l}const r=e.pathname;let i=-1;for(;++i<r.length;)if(r.codePointAt(i)===37&&r.codePointAt(i+1)===50){const l=r.codePointAt(i+2);if(l===70||l===102){const o=new TypeError("File URL path must not include encoded / characters");throw o.code="ERR_INVALID_FILE_URL_PATH",o}}return decodeURIComponent(r)}const ad=["history","path","basename","stem","extname","dirname"];class I0{constructor(r){let i;r?nh(r)?i={path:r}:typeof r=="string"||t6(r)?i={value:r}:i=r:i={},this.cwd="cwd"in i?"":QT.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let l=-1;for(;++l<ad.length;){const u=ad[l];u in i&&i[u]!==void 0&&i[u]!==null&&(this[u]=u==="history"?[...i[u]]:i[u])}let o;for(o in i)ad.includes(o)||(this[o]=i[o])}get basename(){return typeof this.path=="string"?Qn.basename(this.path):void 0}set basename(r){sd(r,"basename"),od(r,"basename"),this.path=Qn.join(this.dirname||"",r)}get dirname(){return typeof this.path=="string"?Qn.dirname(this.path):void 0}set dirname(r){mx(this.basename,"dirname"),this.path=Qn.join(r||"",this.basename)}get extname(){return typeof this.path=="string"?Qn.extname(this.path):void 0}set extname(r){if(od(r,"extname"),mx(this.dirname,"extname"),r){if(r.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(r.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Qn.join(this.dirname,this.stem+(r||""))}get path(){return this.history[this.history.length-1]}set path(r){nh(r)&&(r=WT(r)),sd(r,"path"),this.path!==r&&this.history.push(r)}get stem(){return typeof this.path=="string"?Qn.basename(this.path,this.extname):void 0}set stem(r){sd(r,"stem"),od(r,"stem"),this.path=Qn.join(this.dirname||"",r+(this.extname||""))}fail(r,i,l){const o=this.message(r,i,l);throw o.fatal=!0,o}info(r,i,l){const o=this.message(r,i,l);return o.fatal=void 0,o}message(r,i,l){const o=new Vt(r,i,l);return this.path&&(o.name=this.path+":"+o.name,o.file=this.path),o.fatal=!1,this.messages.push(o),o}toString(r){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(r||void 0).decode(this.value)}}function od(e,r){if(e&&e.includes(Qn.sep))throw new Error("`"+r+"` cannot be a path: did not expect `"+Qn.sep+"`")}function sd(e,r){if(!e)throw new Error("`"+r+"` cannot be empty")}function mx(e,r){if(!e)throw new Error("Setting `"+r+"` requires `path` to be set too")}function t6(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const n6=(function(e){const l=this.constructor.prototype,o=l[e],u=function(){return o.apply(u,arguments)};return Object.setPrototypeOf(u,l),u}),r6={}.hasOwnProperty;class $h extends n6{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=$T()}copy(){const r=new $h;let i=-1;for(;++i<this.attachers.length;){const l=this.attachers[i];r.use(...l)}return r.data(ld(!0,{},this.namespace)),r}data(r,i){return typeof r=="string"?arguments.length===2?(fd("data",this.frozen),this.namespace[r]=i,this):r6.call(this.namespace,r)&&this.namespace[r]||void 0:r?(fd("data",this.frozen),this.namespace=r,this):this.namespace}freeze(){if(this.frozen)return this;const r=this;for(;++this.freezeIndex<this.attachers.length;){const[i,...l]=this.attachers[this.freezeIndex];if(l[0]===!1)continue;l[0]===!0&&(l[0]=void 0);const o=i.call(r,...l);typeof o=="function"&&this.transformers.use(o)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(r){this.freeze();const i=Ts(r),l=this.parser||this.Parser;return ud("parse",l),l(String(i),i)}process(r,i){const l=this;return this.freeze(),ud("process",this.parser||this.Parser),cd("process",this.compiler||this.Compiler),i?o(void 0,i):new Promise(o);function o(u,c){const f=Ts(r),h=l.parse(f);l.run(h,f,function(g,b,v){if(g||!b||!v)return p(g);const x=b,S=l.stringify(x,v);a6(S)?v.value=S:v.result=S,p(g,v)});function p(g,b){g||!b?c(g):u?u(b):i(void 0,b)}}}processSync(r){let i=!1,l;return this.freeze(),ud("processSync",this.parser||this.Parser),cd("processSync",this.compiler||this.Compiler),this.process(r,o),bx("processSync","process",i),l;function o(u,c){i=!0,hx(u),l=c}}run(r,i,l){gx(r),this.freeze();const o=this.transformers;return!l&&typeof i=="function"&&(l=i,i=void 0),l?u(void 0,l):new Promise(u);function u(c,f){const h=Ts(i);o.run(r,h,p);function p(g,b,v){const x=b||r;g?f(g):c?c(x):l(void 0,x,v)}}}runSync(r,i){let l=!1,o;return this.run(r,i,u),bx("runSync","run",l),o;function u(c,f){hx(c),o=f,l=!0}}stringify(r,i){this.freeze();const l=Ts(i),o=this.compiler||this.Compiler;return cd("stringify",o),gx(r),o(r,l)}use(r,...i){const l=this.attachers,o=this.namespace;if(fd("use",this.frozen),r!=null)if(typeof r=="function")h(r,i);else if(typeof r=="object")Array.isArray(r)?f(r):c(r);else throw new TypeError("Expected usable value, not `"+r+"`");return this;function u(p){if(typeof p=="function")h(p,[]);else if(typeof p=="object")if(Array.isArray(p)){const[g,...b]=p;h(g,b)}else c(p);else throw new TypeError("Expected usable value, not `"+p+"`")}function c(p){if(!("plugins"in p)&&!("settings"in p))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");f(p.plugins),p.settings&&(o.settings=ld(!0,o.settings,p.settings))}function f(p){let g=-1;if(p!=null)if(Array.isArray(p))for(;++g<p.length;){const b=p[g];u(b)}else throw new TypeError("Expected a list of plugins, not `"+p+"`")}function h(p,g){let b=-1,v=-1;for(;++b<l.length;)if(l[b][0]===p){v=b;break}if(v===-1)l.push([p,...g]);else if(g.length>0){let[x,...S]=g;const w=l[v][1];th(w)&&th(x)&&(x=ld(!0,w,x)),l[v]=[p,x,...S]}}}}const i6=new $h().freeze();function ud(e,r){if(typeof r!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function cd(e,r){if(typeof r!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function fd(e,r){if(r)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function gx(e){if(!th(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function bx(e,r,i){if(!i)throw new Error("`"+e+"` finished async. Use `"+r+"` instead")}function Ts(e){return l6(e)?e:new I0(e)}function l6(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function a6(e){return typeof e=="string"||o6(e)}function o6(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const s6="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",yx=[],xx={allowDangerousHtml:!0},u6=/^(https?|ircs?|mailto|xmpp)$/i,c6=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function Ph(e){const r=f6(e),i=d6(e);return h6(r.runSync(r.parse(i),i),e)}function f6(e){const r=e.rehypePlugins||yx,i=e.remarkPlugins||yx,l=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...xx}:xx;return i6().use(GA).use(i).use(UT,l).use(r)}function d6(e){const r=e.children||"",i=new I0;return typeof r=="string"&&(i.value=r),i}function h6(e,r){const i=r.allowedElements,l=r.allowElement,o=r.components,u=r.disallowedElements,c=r.skipHtml,f=r.unwrapDisallowed,h=r.urlTransform||p6;for(const g of c6)Object.hasOwn(r,g.from)&&(""+g.from+(g.to?"use `"+g.to+"` instead":"remove it")+s6+g.id,void 0);return qh(e,p),j4(e,{Fragment:y.Fragment,components:o,ignoreInvalidStyle:!0,jsx:y.jsx,jsxs:y.jsxs,passKeys:!0,passNode:!0});function p(g,b,v){if(g.type==="raw"&&v&&typeof b=="number")return c?v.children.splice(b,1):v.children[b]={type:"text",value:g.value},b;if(g.type==="element"){let x;for(x in td)if(Object.hasOwn(td,x)&&Object.hasOwn(g.properties,x)){const S=g.properties[x],w=td[x];(w===null||w.includes(g.tagName))&&(g.properties[x]=h(String(S||""),x,g))}}if(g.type==="element"){let x=i?!i.includes(g.tagName):u?u.includes(g.tagName):!1;if(!x&&l&&typeof b=="number"&&(x=!l(g,b,v)),x&&v&&typeof b=="number")return f&&g.children?v.children.splice(b,1,...g.children):v.children.splice(b,1),b}}}function p6(e){const r=e.indexOf(":"),i=e.indexOf("?"),l=e.indexOf("#"),o=e.indexOf("/");return r===-1||o!==-1&&r>o||i!==-1&&r>i||l!==-1&&r>l||u6.test(e.slice(0,r))?e:""}function vx(e,r){const i=String(e);if(typeof r!="string")throw new TypeError("Expected character");let l=0,o=i.indexOf(r);for(;o!==-1;)l++,o=i.indexOf(r,o+r.length);return l}function m6(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function g6(e,r,i){const o=Su((i||{}).ignore||[]),u=b6(r);let c=-1;for(;++c<u.length;)B0(e,"text",f);function f(p,g){let b=-1,v;for(;++b<g.length;){const x=g[b],S=v?v.children:void 0;if(o(x,S?S.indexOf(x):void 0,v))return;v=x}if(v)return h(p,g)}function h(p,g){const b=g[g.length-1],v=u[c][0],x=u[c][1];let S=0;const N=b.children.indexOf(p);let E=!1,C=[];v.lastIndex=0;let j=v.exec(p.value);for(;j;){const z=j.index,I={index:j.index,input:j.input,stack:[...g,p]};let L=x(...j,I);if(typeof L=="string"&&(L=L.length>0?{type:"text",value:L}:void 0),L===!1?v.lastIndex=z+1:(S!==z&&C.push({type:"text",value:p.value.slice(S,z)}),Array.isArray(L)?C.push(...L):L&&C.push(L),S=z+j[0].length,E=!0),!v.global)break;j=v.exec(p.value)}return E?(S<p.value.length&&C.push({type:"text",value:p.value.slice(S)}),b.children.splice(N,1,...C)):C=[p],N+C.length}}function b6(e){const r=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const i=!e[0]||Array.isArray(e[0])?e:[e];let l=-1;for(;++l<i.length;){const o=i[l];r.push([y6(o[0]),x6(o[1])])}return r}function y6(e){return typeof e=="string"?new RegExp(m6(e),"g"):e}function x6(e){return typeof e=="function"?e:function(){return e}}const dd="phrasing",hd=["autolink","link","image","label"];function v6(){return{transforms:[A6],enter:{literalAutolink:S6,literalAutolinkEmail:pd,literalAutolinkHttp:pd,literalAutolinkWww:pd},exit:{literalAutolink:N6,literalAutolinkEmail:C6,literalAutolinkHttp:k6,literalAutolinkWww:E6}}}function w6(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:dd,notInConstruct:hd},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:dd,notInConstruct:hd},{character:":",before:"[ps]",after:"\\/",inConstruct:dd,notInConstruct:hd}]}}function S6(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function pd(e){this.config.enter.autolinkProtocol.call(this,e)}function k6(e){this.config.exit.autolinkProtocol.call(this,e)}function E6(e){this.config.exit.data.call(this,e);const r=this.stack[this.stack.length-1];r.type,r.url="http://"+this.sliceSerialize(e)}function C6(e){this.config.exit.autolinkEmail.call(this,e)}function N6(e){this.exit(e)}function A6(e){g6(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,T6],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),j6]],{ignore:["link","linkReference"]})}function T6(e,r,i,l,o){let u="";if(!U0(o)||(/^w/i.test(r)&&(i=r+i,r="",u="http://"),!R6(i)))return!1;const c=_6(i+l);if(!c[0])return!1;const f={type:"link",title:null,url:u+r+c[0],children:[{type:"text",value:r+c[0]}]};return c[1]?[f,{type:"text",value:c[1]}]:f}function j6(e,r,i,l){return!U0(l,!0)||/[-\d_]$/.test(i)?!1:{type:"link",title:null,url:"mailto:"+r+"@"+i,children:[{type:"text",value:r+"@"+i}]}}function R6(e){const r=e.split(".");return!(r.length<2||r[r.length-1]&&(/_/.test(r[r.length-1])||!/[a-zA-Z\d]/.test(r[r.length-1]))||r[r.length-2]&&(/_/.test(r[r.length-2])||!/[a-zA-Z\d]/.test(r[r.length-2])))}function _6(e){const r=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!r)return[e,void 0];e=e.slice(0,r.index);let i=r[0],l=i.indexOf(")");const o=vx(e,"(");let u=vx(e,")");for(;l!==-1&&o>u;)e+=i.slice(0,l+1),i=i.slice(l+1),l=i.indexOf(")"),u++;return[e,i]}function U0(e,r){const i=e.input.charCodeAt(e.index-1);return(e.index===0||Fi(i)||xu(i))&&(!r||i!==47)}H0.peek=U6;function L6(){this.buffer()}function D6(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function O6(){this.buffer()}function M6(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function z6(e){const r=this.resume(),i=this.stack[this.stack.length-1];i.type,i.identifier=qn(this.sliceSerialize(e)).toLowerCase(),i.label=r}function F6(e){this.exit(e)}function B6(e){const r=this.resume(),i=this.stack[this.stack.length-1];i.type,i.identifier=qn(this.sliceSerialize(e)).toLowerCase(),i.label=r}function I6(e){this.exit(e)}function U6(){return"["}function H0(e,r,i,l){const o=i.createTracker(l);let u=o.move("[^");const c=i.enter("footnoteReference"),f=i.enter("reference");return u+=o.move(i.safe(i.associationId(e),{after:"]",before:u})),f(),c(),u+=o.move("]"),u}function H6(){return{enter:{gfmFootnoteCallString:L6,gfmFootnoteCall:D6,gfmFootnoteDefinitionLabelString:O6,gfmFootnoteDefinition:M6},exit:{gfmFootnoteCallString:z6,gfmFootnoteCall:F6,gfmFootnoteDefinitionLabelString:B6,gfmFootnoteDefinition:I6}}}function q6(e){let r=!1;return e&&e.firstLineBlank&&(r=!0),{handlers:{footnoteDefinition:i,footnoteReference:H0},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function i(l,o,u,c){const f=u.createTracker(c);let h=f.move("[^");const p=u.enter("footnoteDefinition"),g=u.enter("label");return h+=f.move(u.safe(u.associationId(l),{before:h,after:"]"})),g(),h+=f.move("]:"),l.children&&l.children.length>0&&(f.shift(4),h+=f.move((r?`
|
|
43
|
+
`:" ")+u.indentLines(u.containerFlow(l,f.current()),r?q0:$6))),p(),h}}function $6(e,r,i){return r===0?e:q0(e,r,i)}function q0(e,r,i){return(i?"":" ")+e}const P6=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];$0.peek=Z6;function V6(){return{canContainEols:["delete"],enter:{strikethrough:Y6},exit:{strikethrough:X6}}}function G6(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:P6}],handlers:{delete:$0}}}function Y6(e){this.enter({type:"delete",children:[]},e)}function X6(e){this.exit(e)}function $0(e,r,i,l){const o=i.createTracker(l),u=i.enter("strikethrough");let c=o.move("~~");return c+=i.containerPhrasing(e,{...o.current(),before:c,after:"~"}),c+=o.move("~~"),u(),c}function Z6(){return"~"}function K6(e){return e.length}function Q6(e,r){const i=r||{},l=(i.align||[]).concat(),o=i.stringLength||K6,u=[],c=[],f=[],h=[];let p=0,g=-1;for(;++g<e.length;){const w=[],N=[];let E=-1;for(e[g].length>p&&(p=e[g].length);++E<e[g].length;){const C=J6(e[g][E]);if(i.alignDelimiters!==!1){const j=o(C);N[E]=j,(h[E]===void 0||j>h[E])&&(h[E]=j)}w.push(C)}c[g]=w,f[g]=N}let b=-1;if(typeof l=="object"&&"length"in l)for(;++b<p;)u[b]=wx(l[b]);else{const w=wx(l);for(;++b<p;)u[b]=w}b=-1;const v=[],x=[];for(;++b<p;){const w=u[b];let N="",E="";w===99?(N=":",E=":"):w===108?N=":":w===114&&(E=":");let C=i.alignDelimiters===!1?1:Math.max(1,h[b]-N.length-E.length);const j=N+"-".repeat(C)+E;i.alignDelimiters!==!1&&(C=N.length+C+E.length,C>h[b]&&(h[b]=C),x[b]=C),v[b]=j}c.splice(1,0,v),f.splice(1,0,x),g=-1;const S=[];for(;++g<c.length;){const w=c[g],N=f[g];b=-1;const E=[];for(;++b<p;){const C=w[b]||"";let j="",z="";if(i.alignDelimiters!==!1){const I=h[b]-(N[b]||0),L=u[b];L===114?j=" ".repeat(I):L===99?I%2?(j=" ".repeat(I/2+.5),z=" ".repeat(I/2-.5)):(j=" ".repeat(I/2),z=j):z=" ".repeat(I)}i.delimiterStart!==!1&&!b&&E.push("|"),i.padding!==!1&&!(i.alignDelimiters===!1&&C==="")&&(i.delimiterStart!==!1||b)&&E.push(" "),i.alignDelimiters!==!1&&E.push(j),E.push(C),i.alignDelimiters!==!1&&E.push(z),i.padding!==!1&&E.push(" "),(i.delimiterEnd!==!1||b!==p-1)&&E.push("|")}S.push(i.delimiterEnd===!1?E.join("").replace(/ +$/,""):E.join(""))}return S.join(`
|
|
44
|
+
`)}function J6(e){return e==null?"":String(e)}function wx(e){const r=typeof e=="string"?e.codePointAt(0):0;return r===67||r===99?99:r===76||r===108?108:r===82||r===114?114:0}function W6(e,r,i,l){const o=i.enter("blockquote"),u=i.createTracker(l);u.move("> "),u.shift(2);const c=i.indentLines(i.containerFlow(e,u.current()),e5);return o(),c}function e5(e,r,i){return">"+(i?"":" ")+e}function t5(e,r){return Sx(e,r.inConstruct,!0)&&!Sx(e,r.notInConstruct,!1)}function Sx(e,r,i){if(typeof r=="string"&&(r=[r]),!r||r.length===0)return i;let l=-1;for(;++l<r.length;)if(e.includes(r[l]))return!0;return!1}function kx(e,r,i,l){let o=-1;for(;++o<i.unsafe.length;)if(i.unsafe[o].character===`
|
|
45
|
+
`&&t5(i.stack,i.unsafe[o]))return/[ \t]/.test(l.before)?"":" ";return`\\
|
|
46
|
+
`}function n5(e,r){const i=String(e);let l=i.indexOf(r),o=l,u=0,c=0;if(typeof r!="string")throw new TypeError("Expected substring");for(;l!==-1;)l===o?++u>c&&(c=u):u=1,o=l+r.length,l=i.indexOf(r,o);return c}function r5(e,r){return!!(r.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function i5(e){const r=e.options.fence||"`";if(r!=="`"&&r!=="~")throw new Error("Cannot serialize code with `"+r+"` for `options.fence`, expected `` ` `` or `~`");return r}function l5(e,r,i,l){const o=i5(i),u=e.value||"",c=o==="`"?"GraveAccent":"Tilde";if(r5(e,i)){const b=i.enter("codeIndented"),v=i.indentLines(u,a5);return b(),v}const f=i.createTracker(l),h=o.repeat(Math.max(n5(u,o)+1,3)),p=i.enter("codeFenced");let g=f.move(h);if(e.lang){const b=i.enter(`codeFencedLang${c}`);g+=f.move(i.safe(e.lang,{before:g,after:" ",encode:["`"],...f.current()})),b()}if(e.lang&&e.meta){const b=i.enter(`codeFencedMeta${c}`);g+=f.move(" "),g+=f.move(i.safe(e.meta,{before:g,after:`
|
|
47
|
+
`,encode:["`"],...f.current()})),b()}return g+=f.move(`
|
|
48
|
+
`),u&&(g+=f.move(u+`
|
|
49
|
+
`)),g+=f.move(h),p(),g}function a5(e,r,i){return(i?"":" ")+e}function Vh(e){const r=e.options.quote||'"';if(r!=='"'&&r!=="'")throw new Error("Cannot serialize title with `"+r+"` for `options.quote`, expected `\"`, or `'`");return r}function o5(e,r,i,l){const o=Vh(i),u=o==='"'?"Quote":"Apostrophe",c=i.enter("definition");let f=i.enter("label");const h=i.createTracker(l);let p=h.move("[");return p+=h.move(i.safe(i.associationId(e),{before:p,after:"]",...h.current()})),p+=h.move("]: "),f(),!e.url||/[\0- \u007F]/.test(e.url)?(f=i.enter("destinationLiteral"),p+=h.move("<"),p+=h.move(i.safe(e.url,{before:p,after:">",...h.current()})),p+=h.move(">")):(f=i.enter("destinationRaw"),p+=h.move(i.safe(e.url,{before:p,after:e.title?" ":`
|
|
50
|
+
`,...h.current()}))),f(),e.title&&(f=i.enter(`title${u}`),p+=h.move(" "+o),p+=h.move(i.safe(e.title,{before:p,after:o,...h.current()})),p+=h.move(o),f()),c(),p}function s5(e){const r=e.options.emphasis||"*";if(r!=="*"&&r!=="_")throw new Error("Cannot serialize emphasis with `"+r+"` for `options.emphasis`, expected `*`, or `_`");return r}function Xa(e){return"&#x"+e.toString(16).toUpperCase()+";"}function Js(e,r,i){const l=Dl(e),o=Dl(r);return l===void 0?o===void 0?i==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:l===1?o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:o===void 0?{inside:!1,outside:!1}:o===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}P0.peek=u5;function P0(e,r,i,l){const o=s5(i),u=i.enter("emphasis"),c=i.createTracker(l),f=c.move(o);let h=c.move(i.containerPhrasing(e,{after:o,before:f,...c.current()}));const p=h.charCodeAt(0),g=Js(l.before.charCodeAt(l.before.length-1),p,o);g.inside&&(h=Xa(p)+h.slice(1));const b=h.charCodeAt(h.length-1),v=Js(l.after.charCodeAt(0),b,o);v.inside&&(h=h.slice(0,-1)+Xa(b));const x=c.move(o);return u(),i.attentionEncodeSurroundingInfo={after:v.outside,before:g.outside},f+h+x}function u5(e,r,i){return i.options.emphasis||"*"}function c5(e,r){let i=!1;return qh(e,function(l){if("value"in l&&/\r?\n|\r/.test(l.value)||l.type==="break")return i=!0,Wd}),!!((!e.depth||e.depth<3)&&Mh(e)&&(r.options.setext||i))}function f5(e,r,i,l){const o=Math.max(Math.min(6,e.depth||1),1),u=i.createTracker(l);if(c5(e,i)){const g=i.enter("headingSetext"),b=i.enter("phrasing"),v=i.containerPhrasing(e,{...u.current(),before:`
|
|
51
|
+
`,after:`
|
|
52
|
+
`});return b(),g(),v+`
|
|
53
|
+
`+(o===1?"=":"-").repeat(v.length-(Math.max(v.lastIndexOf("\r"),v.lastIndexOf(`
|
|
54
|
+
`))+1))}const c="#".repeat(o),f=i.enter("headingAtx"),h=i.enter("phrasing");u.move(c+" ");let p=i.containerPhrasing(e,{before:"# ",after:`
|
|
55
|
+
`,...u.current()});return/^[\t ]/.test(p)&&(p=Xa(p.charCodeAt(0))+p.slice(1)),p=p?c+" "+p:c,i.options.closeAtx&&(p+=" "+c),h(),f(),p}V0.peek=d5;function V0(e){return e.value||""}function d5(){return"<"}G0.peek=h5;function G0(e,r,i,l){const o=Vh(i),u=o==='"'?"Quote":"Apostrophe",c=i.enter("image");let f=i.enter("label");const h=i.createTracker(l);let p=h.move("![");return p+=h.move(i.safe(e.alt,{before:p,after:"]",...h.current()})),p+=h.move("]("),f(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(f=i.enter("destinationLiteral"),p+=h.move("<"),p+=h.move(i.safe(e.url,{before:p,after:">",...h.current()})),p+=h.move(">")):(f=i.enter("destinationRaw"),p+=h.move(i.safe(e.url,{before:p,after:e.title?" ":")",...h.current()}))),f(),e.title&&(f=i.enter(`title${u}`),p+=h.move(" "+o),p+=h.move(i.safe(e.title,{before:p,after:o,...h.current()})),p+=h.move(o),f()),p+=h.move(")"),c(),p}function h5(){return"!"}Y0.peek=p5;function Y0(e,r,i,l){const o=e.referenceType,u=i.enter("imageReference");let c=i.enter("label");const f=i.createTracker(l);let h=f.move("![");const p=i.safe(e.alt,{before:h,after:"]",...f.current()});h+=f.move(p+"]["),c();const g=i.stack;i.stack=[],c=i.enter("reference");const b=i.safe(i.associationId(e),{before:h,after:"]",...f.current()});return c(),i.stack=g,u(),o==="full"||!p||p!==b?h+=f.move(b+"]"):o==="shortcut"?h=h.slice(0,-1):h+=f.move("]"),h}function p5(){return"!"}X0.peek=m5;function X0(e,r,i){let l=e.value||"",o="`",u=-1;for(;new RegExp("(^|[^`])"+o+"([^`]|$)").test(l);)o+="`";for(/[^ \r\n]/.test(l)&&(/^[ \r\n]/.test(l)&&/[ \r\n]$/.test(l)||/^`|`$/.test(l))&&(l=" "+l+" ");++u<i.unsafe.length;){const c=i.unsafe[u],f=i.compilePattern(c);let h;if(c.atBreak)for(;h=f.exec(l);){let p=h.index;l.charCodeAt(p)===10&&l.charCodeAt(p-1)===13&&p--,l=l.slice(0,p)+" "+l.slice(h.index+1)}}return o+l+o}function m5(){return"`"}function Z0(e,r){const i=Mh(e);return!!(!r.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(i===e.url||"mailto:"+i===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}K0.peek=g5;function K0(e,r,i,l){const o=Vh(i),u=o==='"'?"Quote":"Apostrophe",c=i.createTracker(l);let f,h;if(Z0(e,i)){const g=i.stack;i.stack=[],f=i.enter("autolink");let b=c.move("<");return b+=c.move(i.containerPhrasing(e,{before:b,after:">",...c.current()})),b+=c.move(">"),f(),i.stack=g,b}f=i.enter("link"),h=i.enter("label");let p=c.move("[");return p+=c.move(i.containerPhrasing(e,{before:p,after:"](",...c.current()})),p+=c.move("]("),h(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(h=i.enter("destinationLiteral"),p+=c.move("<"),p+=c.move(i.safe(e.url,{before:p,after:">",...c.current()})),p+=c.move(">")):(h=i.enter("destinationRaw"),p+=c.move(i.safe(e.url,{before:p,after:e.title?" ":")",...c.current()}))),h(),e.title&&(h=i.enter(`title${u}`),p+=c.move(" "+o),p+=c.move(i.safe(e.title,{before:p,after:o,...c.current()})),p+=c.move(o),h()),p+=c.move(")"),f(),p}function g5(e,r,i){return Z0(e,i)?"<":"["}Q0.peek=b5;function Q0(e,r,i,l){const o=e.referenceType,u=i.enter("linkReference");let c=i.enter("label");const f=i.createTracker(l);let h=f.move("[");const p=i.containerPhrasing(e,{before:h,after:"]",...f.current()});h+=f.move(p+"]["),c();const g=i.stack;i.stack=[],c=i.enter("reference");const b=i.safe(i.associationId(e),{before:h,after:"]",...f.current()});return c(),i.stack=g,u(),o==="full"||!p||p!==b?h+=f.move(b+"]"):o==="shortcut"?h=h.slice(0,-1):h+=f.move("]"),h}function b5(){return"["}function Gh(e){const r=e.options.bullet||"*";if(r!=="*"&&r!=="+"&&r!=="-")throw new Error("Cannot serialize items with `"+r+"` for `options.bullet`, expected `*`, `+`, or `-`");return r}function y5(e){const r=Gh(e),i=e.options.bulletOther;if(!i)return r==="*"?"-":"*";if(i!=="*"&&i!=="+"&&i!=="-")throw new Error("Cannot serialize items with `"+i+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(i===r)throw new Error("Expected `bullet` (`"+r+"`) and `bulletOther` (`"+i+"`) to be different");return i}function x5(e){const r=e.options.bulletOrdered||".";if(r!=="."&&r!==")")throw new Error("Cannot serialize items with `"+r+"` for `options.bulletOrdered`, expected `.` or `)`");return r}function J0(e){const r=e.options.rule||"*";if(r!=="*"&&r!=="-"&&r!=="_")throw new Error("Cannot serialize rules with `"+r+"` for `options.rule`, expected `*`, `-`, or `_`");return r}function v5(e,r,i,l){const o=i.enter("list"),u=i.bulletCurrent;let c=e.ordered?x5(i):Gh(i);const f=e.ordered?c==="."?")":".":y5(i);let h=r&&i.bulletLastUsed?c===i.bulletLastUsed:!1;if(!e.ordered){const g=e.children?e.children[0]:void 0;if((c==="*"||c==="-")&&g&&(!g.children||!g.children[0])&&i.stack[i.stack.length-1]==="list"&&i.stack[i.stack.length-2]==="listItem"&&i.stack[i.stack.length-3]==="list"&&i.stack[i.stack.length-4]==="listItem"&&i.indexStack[i.indexStack.length-1]===0&&i.indexStack[i.indexStack.length-2]===0&&i.indexStack[i.indexStack.length-3]===0&&(h=!0),J0(i)===c&&g){let b=-1;for(;++b<e.children.length;){const v=e.children[b];if(v&&v.type==="listItem"&&v.children&&v.children[0]&&v.children[0].type==="thematicBreak"){h=!0;break}}}}h&&(c=f),i.bulletCurrent=c;const p=i.containerFlow(e,l);return i.bulletLastUsed=c,i.bulletCurrent=u,o(),p}function w5(e){const r=e.options.listItemIndent||"one";if(r!=="tab"&&r!=="one"&&r!=="mixed")throw new Error("Cannot serialize items with `"+r+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return r}function S5(e,r,i,l){const o=w5(i);let u=i.bulletCurrent||Gh(i);r&&r.type==="list"&&r.ordered&&(u=(typeof r.start=="number"&&r.start>-1?r.start:1)+(i.options.incrementListMarker===!1?0:r.children.indexOf(e))+u);let c=u.length+1;(o==="tab"||o==="mixed"&&(r&&r.type==="list"&&r.spread||e.spread))&&(c=Math.ceil(c/4)*4);const f=i.createTracker(l);f.move(u+" ".repeat(c-u.length)),f.shift(c);const h=i.enter("listItem"),p=i.indentLines(i.containerFlow(e,f.current()),g);return h(),p;function g(b,v,x){return v?(x?"":" ".repeat(c))+b:(x?u:u+" ".repeat(c-u.length))+b}}function k5(e,r,i,l){const o=i.enter("paragraph"),u=i.enter("phrasing"),c=i.containerPhrasing(e,l);return u(),o(),c}const E5=Su(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function C5(e,r,i,l){return(e.children.some(function(c){return E5(c)})?i.containerPhrasing:i.containerFlow).call(i,e,l)}function N5(e){const r=e.options.strong||"*";if(r!=="*"&&r!=="_")throw new Error("Cannot serialize strong with `"+r+"` for `options.strong`, expected `*`, or `_`");return r}W0.peek=A5;function W0(e,r,i,l){const o=N5(i),u=i.enter("strong"),c=i.createTracker(l),f=c.move(o+o);let h=c.move(i.containerPhrasing(e,{after:o,before:f,...c.current()}));const p=h.charCodeAt(0),g=Js(l.before.charCodeAt(l.before.length-1),p,o);g.inside&&(h=Xa(p)+h.slice(1));const b=h.charCodeAt(h.length-1),v=Js(l.after.charCodeAt(0),b,o);v.inside&&(h=h.slice(0,-1)+Xa(b));const x=c.move(o+o);return u(),i.attentionEncodeSurroundingInfo={after:v.outside,before:g.outside},f+h+x}function A5(e,r,i){return i.options.strong||"*"}function T5(e,r,i,l){return i.safe(e.value,l)}function j5(e){const r=e.options.ruleRepetition||3;if(r<3)throw new Error("Cannot serialize rules with repetition `"+r+"` for `options.ruleRepetition`, expected `3` or more");return r}function R5(e,r,i){const l=(J0(i)+(i.options.ruleSpaces?" ":"")).repeat(j5(i));return i.options.ruleSpaces?l.slice(0,-1):l}const ev={blockquote:W6,break:kx,code:l5,definition:o5,emphasis:P0,hardBreak:kx,heading:f5,html:V0,image:G0,imageReference:Y0,inlineCode:X0,link:K0,linkReference:Q0,list:v5,listItem:S5,paragraph:k5,root:C5,strong:W0,text:T5,thematicBreak:R5};function _5(){return{enter:{table:L5,tableData:Ex,tableHeader:Ex,tableRow:O5},exit:{codeText:M5,table:D5,tableData:md,tableHeader:md,tableRow:md}}}function L5(e){const r=e._align;this.enter({type:"table",align:r.map(function(i){return i==="none"?null:i}),children:[]},e),this.data.inTable=!0}function D5(e){this.exit(e),this.data.inTable=void 0}function O5(e){this.enter({type:"tableRow",children:[]},e)}function md(e){this.exit(e)}function Ex(e){this.enter({type:"tableCell",children:[]},e)}function M5(e){let r=this.resume();this.data.inTable&&(r=r.replace(/\\([\\|])/g,z5));const i=this.stack[this.stack.length-1];i.type,i.value=r,this.exit(e)}function z5(e,r){return r==="|"?r:e}function F5(e){const r=e||{},i=r.tableCellPadding,l=r.tablePipeAlign,o=r.stringLength,u=i?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
|
|
56
|
+
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:v,table:c,tableCell:h,tableRow:f}};function c(x,S,w,N){return p(g(x,w,N),x.align)}function f(x,S,w,N){const E=b(x,w,N),C=p([E]);return C.slice(0,C.indexOf(`
|
|
57
|
+
`))}function h(x,S,w,N){const E=w.enter("tableCell"),C=w.enter("phrasing"),j=w.containerPhrasing(x,{...N,before:u,after:u});return C(),E(),j}function p(x,S){return Q6(x,{align:S,alignDelimiters:l,padding:i,stringLength:o})}function g(x,S,w){const N=x.children;let E=-1;const C=[],j=S.enter("table");for(;++E<N.length;)C[E]=b(N[E],S,w);return j(),C}function b(x,S,w){const N=x.children;let E=-1;const C=[],j=S.enter("tableRow");for(;++E<N.length;)C[E]=h(N[E],x,S,w);return j(),C}function v(x,S,w){let N=ev.inlineCode(x,S,w);return w.stack.includes("tableCell")&&(N=N.replace(/\|/g,"\\$&")),N}}function B5(){return{exit:{taskListCheckValueChecked:Cx,taskListCheckValueUnchecked:Cx,paragraph:U5}}}function I5(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:H5}}}function Cx(e){const r=this.stack[this.stack.length-2];r.type,r.checked=e.type==="taskListCheckValueChecked"}function U5(e){const r=this.stack[this.stack.length-2];if(r&&r.type==="listItem"&&typeof r.checked=="boolean"){const i=this.stack[this.stack.length-1];i.type;const l=i.children[0];if(l&&l.type==="text"){const o=r.children;let u=-1,c;for(;++u<o.length;){const f=o[u];if(f.type==="paragraph"){c=f;break}}c===i&&(l.value=l.value.slice(1),l.value.length===0?i.children.shift():i.position&&l.position&&typeof l.position.start.offset=="number"&&(l.position.start.column++,l.position.start.offset++,i.position.start=Object.assign({},l.position.start)))}}this.exit(e)}function H5(e,r,i,l){const o=e.children[0],u=typeof e.checked=="boolean"&&o&&o.type==="paragraph",c="["+(e.checked?"x":" ")+"] ",f=i.createTracker(l);u&&f.move(c);let h=ev.listItem(e,r,i,{...l,...f.current()});return u&&(h=h.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,p)),h;function p(g){return g+c}}function q5(){return[v6(),H6(),V6(),_5(),B5()]}function $5(e){return{extensions:[w6(),q6(e),G6(),F5(e),I5()]}}const P5={tokenize:K5,partial:!0},tv={tokenize:Q5,partial:!0},nv={tokenize:J5,partial:!0},rv={tokenize:W5,partial:!0},V5={tokenize:e8,partial:!0},iv={name:"wwwAutolink",tokenize:X5,previous:av},lv={name:"protocolAutolink",tokenize:Z5,previous:ov},Nr={name:"emailAutolink",tokenize:Y5,previous:sv},tr={};function G5(){return{text:tr}}let _i=48;for(;_i<123;)tr[_i]=Nr,_i++,_i===58?_i=65:_i===91&&(_i=97);tr[43]=Nr;tr[45]=Nr;tr[46]=Nr;tr[95]=Nr;tr[72]=[Nr,lv];tr[104]=[Nr,lv];tr[87]=[Nr,iv];tr[119]=[Nr,iv];function Y5(e,r,i){const l=this;let o,u;return c;function c(b){return!rh(b)||!sv.call(l,l.previous)||Yh(l.events)?i(b):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),f(b))}function f(b){return rh(b)?(e.consume(b),f):b===64?(e.consume(b),h):i(b)}function h(b){return b===46?e.check(V5,g,p)(b):b===45||b===95||Pt(b)?(u=!0,e.consume(b),h):g(b)}function p(b){return e.consume(b),o=!0,h}function g(b){return u&&o&&Kt(l.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),r(b)):i(b)}}function X5(e,r,i){const l=this;return o;function o(c){return c!==87&&c!==119||!av.call(l,l.previous)||Yh(l.events)?i(c):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(P5,e.attempt(tv,e.attempt(nv,u),i),i)(c))}function u(c){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),r(c)}}function Z5(e,r,i){const l=this;let o="",u=!1;return c;function c(b){return(b===72||b===104)&&ov.call(l,l.previous)&&!Yh(l.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),o+=String.fromCodePoint(b),e.consume(b),f):i(b)}function f(b){if(Kt(b)&&o.length<5)return o+=String.fromCodePoint(b),e.consume(b),f;if(b===58){const v=o.toLowerCase();if(v==="http"||v==="https")return e.consume(b),h}return i(b)}function h(b){return b===47?(e.consume(b),u?p:(u=!0,h)):i(b)}function p(b){return b===null||Zs(b)||st(b)||Fi(b)||xu(b)?i(b):e.attempt(tv,e.attempt(nv,g),i)(b)}function g(b){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),r(b)}}function K5(e,r,i){let l=0;return o;function o(c){return(c===87||c===119)&&l<3?(l++,e.consume(c),o):c===46&&l===3?(e.consume(c),u):i(c)}function u(c){return c===null?i(c):r(c)}}function Q5(e,r,i){let l,o,u;return c;function c(p){return p===46||p===95?e.check(rv,h,f)(p):p===null||st(p)||Fi(p)||p!==45&&xu(p)?h(p):(u=!0,e.consume(p),c)}function f(p){return p===95?l=!0:(o=l,l=void 0),e.consume(p),c}function h(p){return o||l||!u?i(p):r(p)}}function J5(e,r){let i=0,l=0;return o;function o(c){return c===40?(i++,e.consume(c),o):c===41&&l<i?u(c):c===33||c===34||c===38||c===39||c===41||c===42||c===44||c===46||c===58||c===59||c===60||c===63||c===93||c===95||c===126?e.check(rv,r,u)(c):c===null||st(c)||Fi(c)?r(c):(e.consume(c),o)}function u(c){return c===41&&l++,e.consume(c),o}}function W5(e,r,i){return l;function l(f){return f===33||f===34||f===39||f===41||f===42||f===44||f===46||f===58||f===59||f===63||f===95||f===126?(e.consume(f),l):f===38?(e.consume(f),u):f===93?(e.consume(f),o):f===60||f===null||st(f)||Fi(f)?r(f):i(f)}function o(f){return f===null||f===40||f===91||st(f)||Fi(f)?r(f):l(f)}function u(f){return Kt(f)?c(f):i(f)}function c(f){return f===59?(e.consume(f),l):Kt(f)?(e.consume(f),c):i(f)}}function e8(e,r,i){return l;function l(u){return e.consume(u),o}function o(u){return Pt(u)?i(u):r(u)}}function av(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||st(e)}function ov(e){return!Kt(e)}function sv(e){return!(e===47||rh(e))}function rh(e){return e===43||e===45||e===46||e===95||Pt(e)}function Yh(e){let r=e.length,i=!1;for(;r--;){const l=e[r][1];if((l.type==="labelLink"||l.type==="labelImage")&&!l._balanced){i=!0;break}if(l._gfmAutolinkLiteralWalkedInto){i=!1;break}}return e.length>0&&!i&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),i}const t8={tokenize:u8,partial:!0};function n8(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:a8,continuation:{tokenize:o8},exit:s8}},text:{91:{name:"gfmFootnoteCall",tokenize:l8},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:r8,resolveTo:i8}}}}function r8(e,r,i){const l=this;let o=l.events.length;const u=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let c;for(;o--;){const h=l.events[o][1];if(h.type==="labelImage"){c=h;break}if(h.type==="gfmFootnoteCall"||h.type==="labelLink"||h.type==="label"||h.type==="image"||h.type==="link")break}return f;function f(h){if(!c||!c._balanced)return i(h);const p=qn(l.sliceSerialize({start:c.end,end:l.now()}));return p.codePointAt(0)!==94||!u.includes(p.slice(1))?i(h):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(h),e.exit("gfmFootnoteCallLabelMarker"),r(h))}}function i8(e,r){let i=e.length;for(;i--;)if(e[i][1].type==="labelImage"&&e[i][0]==="enter"){e[i][1];break}e[i+1][1].type="data",e[i+3][1].type="gfmFootnoteCallLabelMarker";const l={type:"gfmFootnoteCall",start:Object.assign({},e[i+3][1].start),end:Object.assign({},e[e.length-1][1].end)},o={type:"gfmFootnoteCallMarker",start:Object.assign({},e[i+3][1].end),end:Object.assign({},e[i+3][1].end)};o.end.column++,o.end.offset++,o.end._bufferIndex++;const u={type:"gfmFootnoteCallString",start:Object.assign({},o.end),end:Object.assign({},e[e.length-1][1].start)},c={type:"chunkString",contentType:"string",start:Object.assign({},u.start),end:Object.assign({},u.end)},f=[e[i+1],e[i+2],["enter",l,r],e[i+3],e[i+4],["enter",o,r],["exit",o,r],["enter",u,r],["enter",c,r],["exit",c,r],["exit",u,r],e[e.length-2],e[e.length-1],["exit",l,r]];return e.splice(i,e.length-i+1,...f),e}function l8(e,r,i){const l=this,o=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let u=0,c;return f;function f(b){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(b),e.exit("gfmFootnoteCallLabelMarker"),h}function h(b){return b!==94?i(b):(e.enter("gfmFootnoteCallMarker"),e.consume(b),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",p)}function p(b){if(u>999||b===93&&!c||b===null||b===91||st(b))return i(b);if(b===93){e.exit("chunkString");const v=e.exit("gfmFootnoteCallString");return o.includes(qn(l.sliceSerialize(v)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(b),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),r):i(b)}return st(b)||(c=!0),u++,e.consume(b),b===92?g:p}function g(b){return b===91||b===92||b===93?(e.consume(b),u++,p):p(b)}}function a8(e,r,i){const l=this,o=l.parser.gfmFootnotes||(l.parser.gfmFootnotes=[]);let u,c=0,f;return h;function h(S){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(S),e.exit("gfmFootnoteDefinitionLabelMarker"),p}function p(S){return S===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(S),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",g):i(S)}function g(S){if(c>999||S===93&&!f||S===null||S===91||st(S))return i(S);if(S===93){e.exit("chunkString");const w=e.exit("gfmFootnoteDefinitionLabelString");return u=qn(l.sliceSerialize(w)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(S),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),v}return st(S)||(f=!0),c++,e.consume(S),S===92?b:g}function b(S){return S===91||S===92||S===93?(e.consume(S),c++,g):g(S)}function v(S){return S===58?(e.enter("definitionMarker"),e.consume(S),e.exit("definitionMarker"),o.includes(u)||o.push(u),Ge(e,x,"gfmFootnoteDefinitionWhitespace")):i(S)}function x(S){return r(S)}}function o8(e,r,i){return e.check(to,r,e.attempt(t8,r,i))}function s8(e){e.exit("gfmFootnoteDefinition")}function u8(e,r,i){const l=this;return Ge(e,o,"gfmFootnoteDefinitionIndent",5);function o(u){const c=l.events[l.events.length-1];return c&&c[1].type==="gfmFootnoteDefinitionIndent"&&c[2].sliceSerialize(c[1],!0).length===4?r(u):i(u)}}function c8(e){let i=(e||{}).singleTilde;const l={name:"strikethrough",tokenize:u,resolveAll:o};return i==null&&(i=!0),{text:{126:l},insideSpan:{null:[l]},attentionMarkers:{null:[126]}};function o(c,f){let h=-1;for(;++h<c.length;)if(c[h][0]==="enter"&&c[h][1].type==="strikethroughSequenceTemporary"&&c[h][1]._close){let p=h;for(;p--;)if(c[p][0]==="exit"&&c[p][1].type==="strikethroughSequenceTemporary"&&c[p][1]._open&&c[h][1].end.offset-c[h][1].start.offset===c[p][1].end.offset-c[p][1].start.offset){c[h][1].type="strikethroughSequence",c[p][1].type="strikethroughSequence";const g={type:"strikethrough",start:Object.assign({},c[p][1].start),end:Object.assign({},c[h][1].end)},b={type:"strikethroughText",start:Object.assign({},c[p][1].end),end:Object.assign({},c[h][1].start)},v=[["enter",g,f],["enter",c[p][1],f],["exit",c[p][1],f],["enter",b,f]],x=f.parser.constructs.insideSpan.null;x&&kn(v,v.length,0,vu(x,c.slice(p+1,h),f)),kn(v,v.length,0,[["exit",b,f],["enter",c[h][1],f],["exit",c[h][1],f],["exit",g,f]]),kn(c,p-1,h-p+3,v),h=p+v.length-2;break}}for(h=-1;++h<c.length;)c[h][1].type==="strikethroughSequenceTemporary"&&(c[h][1].type="data");return c}function u(c,f,h){const p=this.previous,g=this.events;let b=0;return v;function v(S){return p===126&&g[g.length-1][1].type!=="characterEscape"?h(S):(c.enter("strikethroughSequenceTemporary"),x(S))}function x(S){const w=Dl(p);if(S===126)return b>1?h(S):(c.consume(S),b++,x);if(b<2&&!i)return h(S);const N=c.exit("strikethroughSequenceTemporary"),E=Dl(S);return N._open=!E||E===2&&!!w,N._close=!w||w===2&&!!E,f(S)}}}class f8{constructor(){this.map=[]}add(r,i,l){d8(this,r,i,l)}consume(r){if(this.map.sort(function(u,c){return u[0]-c[0]}),this.map.length===0)return;let i=this.map.length;const l=[];for(;i>0;)i-=1,l.push(r.slice(this.map[i][0]+this.map[i][1]),this.map[i][2]),r.length=this.map[i][0];l.push(r.slice()),r.length=0;let o=l.pop();for(;o;){for(const u of o)r.push(u);o=l.pop()}this.map.length=0}}function d8(e,r,i,l){let o=0;if(!(i===0&&l.length===0)){for(;o<e.map.length;){if(e.map[o][0]===r){e.map[o][1]+=i,e.map[o][2].push(...l);return}o+=1}e.map.push([r,i,l])}}function h8(e,r){let i=!1;const l=[];for(;r<e.length;){const o=e[r];if(i){if(o[0]==="enter")o[1].type==="tableContent"&&l.push(e[r+1][1].type==="tableDelimiterMarker"?"left":"none");else if(o[1].type==="tableContent"){if(e[r-1][1].type==="tableDelimiterMarker"){const u=l.length-1;l[u]=l[u]==="left"?"center":"right"}}else if(o[1].type==="tableDelimiterRow")break}else o[0]==="enter"&&o[1].type==="tableDelimiterRow"&&(i=!0);r+=1}return l}function p8(){return{flow:{null:{name:"table",tokenize:m8,resolveAll:g8}}}}function m8(e,r,i){const l=this;let o=0,u=0,c;return f;function f(F){let H=l.events.length-1;for(;H>-1;){const U=l.events[H][1].type;if(U==="lineEnding"||U==="linePrefix")H--;else break}const G=H>-1?l.events[H][1].type:null,Q=G==="tableHead"||G==="tableRow"?L:h;return Q===L&&l.parser.lazy[l.now().line]?i(F):Q(F)}function h(F){return e.enter("tableHead"),e.enter("tableRow"),p(F)}function p(F){return F===124||(c=!0,u+=1),g(F)}function g(F){return F===null?i(F):Ae(F)?u>1?(u=0,l.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(F),e.exit("lineEnding"),x):i(F):Be(F)?Ge(e,g,"whitespace")(F):(u+=1,c&&(c=!1,o+=1),F===124?(e.enter("tableCellDivider"),e.consume(F),e.exit("tableCellDivider"),c=!0,g):(e.enter("data"),b(F)))}function b(F){return F===null||F===124||st(F)?(e.exit("data"),g(F)):(e.consume(F),F===92?v:b)}function v(F){return F===92||F===124?(e.consume(F),b):b(F)}function x(F){return l.interrupt=!1,l.parser.lazy[l.now().line]?i(F):(e.enter("tableDelimiterRow"),c=!1,Be(F)?Ge(e,S,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(F):S(F))}function S(F){return F===45||F===58?N(F):F===124?(c=!0,e.enter("tableCellDivider"),e.consume(F),e.exit("tableCellDivider"),w):I(F)}function w(F){return Be(F)?Ge(e,N,"whitespace")(F):N(F)}function N(F){return F===58?(u+=1,c=!0,e.enter("tableDelimiterMarker"),e.consume(F),e.exit("tableDelimiterMarker"),E):F===45?(u+=1,E(F)):F===null||Ae(F)?z(F):I(F)}function E(F){return F===45?(e.enter("tableDelimiterFiller"),C(F)):I(F)}function C(F){return F===45?(e.consume(F),C):F===58?(c=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(F),e.exit("tableDelimiterMarker"),j):(e.exit("tableDelimiterFiller"),j(F))}function j(F){return Be(F)?Ge(e,z,"whitespace")(F):z(F)}function z(F){return F===124?S(F):F===null||Ae(F)?!c||o!==u?I(F):(e.exit("tableDelimiterRow"),e.exit("tableHead"),r(F)):I(F)}function I(F){return i(F)}function L(F){return e.enter("tableRow"),O(F)}function O(F){return F===124?(e.enter("tableCellDivider"),e.consume(F),e.exit("tableCellDivider"),O):F===null||Ae(F)?(e.exit("tableRow"),r(F)):Be(F)?Ge(e,O,"whitespace")(F):(e.enter("data"),Z(F))}function Z(F){return F===null||F===124||st(F)?(e.exit("data"),O(F)):(e.consume(F),F===92?$:Z)}function $(F){return F===92||F===124?(e.consume(F),Z):Z(F)}}function g8(e,r){let i=-1,l=!0,o=0,u=[0,0,0,0],c=[0,0,0,0],f=!1,h=0,p,g,b;const v=new f8;for(;++i<e.length;){const x=e[i],S=x[1];x[0]==="enter"?S.type==="tableHead"?(f=!1,h!==0&&(Nx(v,r,h,p,g),g=void 0,h=0),p={type:"table",start:Object.assign({},S.start),end:Object.assign({},S.end)},v.add(i,0,[["enter",p,r]])):S.type==="tableRow"||S.type==="tableDelimiterRow"?(l=!0,b=void 0,u=[0,0,0,0],c=[0,i+1,0,0],f&&(f=!1,g={type:"tableBody",start:Object.assign({},S.start),end:Object.assign({},S.end)},v.add(i,0,[["enter",g,r]])),o=S.type==="tableDelimiterRow"?2:g?3:1):o&&(S.type==="data"||S.type==="tableDelimiterMarker"||S.type==="tableDelimiterFiller")?(l=!1,c[2]===0&&(u[1]!==0&&(c[0]=c[1],b=js(v,r,u,o,void 0,b),u=[0,0,0,0]),c[2]=i)):S.type==="tableCellDivider"&&(l?l=!1:(u[1]!==0&&(c[0]=c[1],b=js(v,r,u,o,void 0,b)),u=c,c=[u[1],i,0,0])):S.type==="tableHead"?(f=!0,h=i):S.type==="tableRow"||S.type==="tableDelimiterRow"?(h=i,u[1]!==0?(c[0]=c[1],b=js(v,r,u,o,i,b)):c[1]!==0&&(b=js(v,r,c,o,i,b)),o=0):o&&(S.type==="data"||S.type==="tableDelimiterMarker"||S.type==="tableDelimiterFiller")&&(c[3]=i)}for(h!==0&&Nx(v,r,h,p,g),v.consume(r.events),i=-1;++i<r.events.length;){const x=r.events[i];x[0]==="enter"&&x[1].type==="table"&&(x[1]._align=h8(r.events,i))}return e}function js(e,r,i,l,o,u){const c=l===1?"tableHeader":l===2?"tableDelimiter":"tableData",f="tableContent";i[0]!==0&&(u.end=Object.assign({},Nl(r.events,i[0])),e.add(i[0],0,[["exit",u,r]]));const h=Nl(r.events,i[1]);if(u={type:c,start:Object.assign({},h),end:Object.assign({},h)},e.add(i[1],0,[["enter",u,r]]),i[2]!==0){const p=Nl(r.events,i[2]),g=Nl(r.events,i[3]),b={type:f,start:Object.assign({},p),end:Object.assign({},g)};if(e.add(i[2],0,[["enter",b,r]]),l!==2){const v=r.events[i[2]],x=r.events[i[3]];if(v[1].end=Object.assign({},x[1].end),v[1].type="chunkText",v[1].contentType="text",i[3]>i[2]+1){const S=i[2]+1,w=i[3]-i[2]-1;e.add(S,w,[])}}e.add(i[3]+1,0,[["exit",b,r]])}return o!==void 0&&(u.end=Object.assign({},Nl(r.events,o)),e.add(o,0,[["exit",u,r]]),u=void 0),u}function Nx(e,r,i,l,o){const u=[],c=Nl(r.events,i);o&&(o.end=Object.assign({},c),u.push(["exit",o,r])),l.end=Object.assign({},c),u.push(["exit",l,r]),e.add(i+1,0,u)}function Nl(e,r){const i=e[r],l=i[0]==="enter"?"start":"end";return i[1][l]}const b8={name:"tasklistCheck",tokenize:x8};function y8(){return{text:{91:b8}}}function x8(e,r,i){const l=this;return o;function o(h){return l.previous!==null||!l._gfmTasklistFirstContentOfListItem?i(h):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(h),e.exit("taskListCheckMarker"),u)}function u(h){return st(h)?(e.enter("taskListCheckValueUnchecked"),e.consume(h),e.exit("taskListCheckValueUnchecked"),c):h===88||h===120?(e.enter("taskListCheckValueChecked"),e.consume(h),e.exit("taskListCheckValueChecked"),c):i(h)}function c(h){return h===93?(e.enter("taskListCheckMarker"),e.consume(h),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),f):i(h)}function f(h){return Ae(h)?r(h):Be(h)?e.check({tokenize:v8},r,i)(h):i(h)}}function v8(e,r,i){return Ge(e,l,"whitespace");function l(o){return o===null?i(o):r(o)}}function w8(e){return x0([G5(),n8(),c8(e),p8(),y8()])}const S8={};function Xh(e){const r=this,i=e||S8,l=r.data(),o=l.micromarkExtensions||(l.micromarkExtensions=[]),u=l.fromMarkdownExtensions||(l.fromMarkdownExtensions=[]),c=l.toMarkdownExtensions||(l.toMarkdownExtensions=[]);o.push(w8(i)),u.push(q5()),c.push($5(i))}let Ax=null;const k8=()=>(Ax??=Lt(()=>import("./mermaid.core-BA0DCisQ.js").then(e=>e.bF),[]),Ax),E8=e=>e==="light"?"default":"dark";function C8({chart:e}){const r=A.useRef(null),i=A.useId().replace(/:/g,"-"),[l,o]=A.useState(()=>Fb()),[u,c]=A.useState(null),f=E8(l);return A.useEffect(()=>{const h=document.documentElement,p=()=>{const b=Fb();o(v=>v===b?v:b)};p();const g=new MutationObserver(b=>{b.some(v=>v.attributeName==="data-theme")&&p()});return g.observe(h,{attributes:!0,attributeFilter:["data-theme"]}),()=>{g.disconnect()}},[]),A.useEffect(()=>{let h=!1;const p=r.current;return(async()=>{if(p){p.innerHTML="",c(null);try{const{default:b}=await k8();b.initialize({startOnLoad:!1,securityLevel:"strict",theme:f});const{svg:v,bindFunctions:x}=await b.render(`mermaid-diagram-${i}`,e);if(h)return;p.innerHTML=v,x?.(p)}catch(b){if(h)return;p.innerHTML="",c(b instanceof Error?b.message:"Failed to render Mermaid diagram")}}})(),()=>{h=!0,p&&(p.innerHTML="")}},[e,i,f]),u?y.jsxs("div",{className:"space-y-2",children:[y.jsx("div",{className:"text-sm text-github-danger",title:u,children:"Unable to render Mermaid diagram."}),y.jsx("pre",{className:"markdown-preview-code whitespace-pre-wrap border border-github-border bg-github-bg-secondary p-3 overflow-x-auto text-sm font-mono text-github-text-primary",children:e})]}):y.jsx("div",{ref:r,"aria-label":"Mermaid diagram",className:"mermaid-diagram overflow-x-auto rounded border border-github-border bg-github-bg-secondary p-3"})}class Zh{diff(r,i,l={}){let o;typeof l=="function"?(o=l,l={}):"callback"in l&&(o=l.callback);const u=this.castInput(r,l),c=this.castInput(i,l),f=this.removeEmpty(this.tokenize(u,l)),h=this.removeEmpty(this.tokenize(c,l));return this.diffWithOptionsObj(f,h,l,o)}diffWithOptionsObj(r,i,l,o){var u;const c=C=>{if(C=this.postProcess(C,l),o){setTimeout(function(){o(C)},0);return}else return C},f=i.length,h=r.length;let p=1,g=f+h;l.maxEditLength!=null&&(g=Math.min(g,l.maxEditLength));const b=(u=l.timeout)!==null&&u!==void 0?u:1/0,v=Date.now()+b,x=[{oldPos:-1,lastComponent:void 0}];let S=this.extractCommon(x[0],i,r,0,l);if(x[0].oldPos+1>=h&&S+1>=f)return c(this.buildValues(x[0].lastComponent,i,r));let w=-1/0,N=1/0;const E=()=>{for(let C=Math.max(w,-p);C<=Math.min(N,p);C+=2){let j;const z=x[C-1],I=x[C+1];z&&(x[C-1]=void 0);let L=!1;if(I){const Z=I.oldPos-C;L=I&&0<=Z&&Z<f}const O=z&&z.oldPos+1<h;if(!L&&!O){x[C]=void 0;continue}if(!O||L&&z.oldPos<I.oldPos?j=this.addToPath(I,!0,!1,0,l):j=this.addToPath(z,!1,!0,1,l),S=this.extractCommon(j,i,r,C,l),j.oldPos+1>=h&&S+1>=f)return c(this.buildValues(j.lastComponent,i,r))||!0;x[C]=j,j.oldPos+1>=h&&(N=Math.min(N,C-1)),S+1>=f&&(w=Math.max(w,C+1))}p++};if(o)(function C(){setTimeout(function(){if(p>g||Date.now()>v)return o(void 0);E()||C()},0)})();else for(;p<=g&&Date.now()<=v;){const C=E();if(C)return C}}addToPath(r,i,l,o,u){const c=r.lastComponent;return c&&!u.oneChangePerToken&&c.added===i&&c.removed===l?{oldPos:r.oldPos+o,lastComponent:{count:c.count+1,added:i,removed:l,previousComponent:c.previousComponent}}:{oldPos:r.oldPos+o,lastComponent:{count:1,added:i,removed:l,previousComponent:c}}}extractCommon(r,i,l,o,u){const c=i.length,f=l.length;let h=r.oldPos,p=h-o,g=0;for(;p+1<c&&h+1<f&&this.equals(l[h+1],i[p+1],u);)p++,h++,g++,u.oneChangePerToken&&(r.lastComponent={count:1,previousComponent:r.lastComponent,added:!1,removed:!1});return g&&!u.oneChangePerToken&&(r.lastComponent={count:g,previousComponent:r.lastComponent,added:!1,removed:!1}),r.oldPos=h,p}equals(r,i,l){return l.comparator?l.comparator(r,i):r===i||!!l.ignoreCase&&r.toLowerCase()===i.toLowerCase()}removeEmpty(r){const i=[];for(let l=0;l<r.length;l++)r[l]&&i.push(r[l]);return i}castInput(r,i){return r}tokenize(r,i){return Array.from(r)}join(r){return r.join("")}postProcess(r,i){return r}get useLongestToken(){return!1}buildValues(r,i,l){const o=[];let u;for(;r;)o.push(r),u=r.previousComponent,delete r.previousComponent,r=u;o.reverse();const c=o.length;let f=0,h=0,p=0;for(;f<c;f++){const g=o[f];if(g.removed)g.value=this.join(l.slice(p,p+g.count)),p+=g.count;else{if(!g.added&&this.useLongestToken){let b=i.slice(h,h+g.count);b=b.map(function(v,x){const S=l[p+x];return S.length>v.length?S:v}),g.value=this.join(b)}else g.value=this.join(i.slice(h,h+g.count));h+=g.count,g.added||(p+=g.count)}}return o}}function Tx(e,r){let i;for(i=0;i<e.length&&i<r.length;i++)if(e[i]!=r[i])return e.slice(0,i);return e.slice(0,i)}function jx(e,r){let i;if(!e||!r||e[e.length-1]!=r[r.length-1])return"";for(i=0;i<e.length&&i<r.length;i++)if(e[e.length-(i+1)]!=r[r.length-(i+1)])return e.slice(-i);return e.slice(-i)}function ih(e,r,i){if(e.slice(0,r.length)!=r)throw Error(`string ${JSON.stringify(e)} doesn't start with prefix ${JSON.stringify(r)}; this is a bug`);return i+e.slice(r.length)}function lh(e,r,i){if(!r)return e+i;if(e.slice(-r.length)!=r)throw Error(`string ${JSON.stringify(e)} doesn't end with suffix ${JSON.stringify(r)}; this is a bug`);return e.slice(0,-r.length)+i}function Ma(e,r){return ih(e,r,"")}function Rs(e,r){return lh(e,r,"")}function Rx(e,r){return r.slice(0,N8(e,r))}function N8(e,r){let i=0;e.length>r.length&&(i=e.length-r.length);let l=r.length;e.length<r.length&&(l=e.length);const o=Array(l);let u=0;o[0]=0;for(let c=1;c<l;c++){for(r[c]==r[u]?o[c]=o[u]:o[c]=u;u>0&&r[c]!=r[u];)u=o[u];r[c]==r[u]&&u++}u=0;for(let c=i;c<e.length;c++){for(;u>0&&e[c]!=r[u];)u=o[u];e[c]==r[u]&&u++}return u}function za(e){let r;for(r=e.length-1;r>=0&&e[r].match(/\s/);r--);return e.substring(r+1)}function ni(e){const r=e.match(/^\s*/);return r?r[0]:""}const Ws="a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}",A8=new RegExp(`[${Ws}]+|\\s+|[^${Ws}]`,"ug");class T8 extends Zh{equals(r,i,l){return l.ignoreCase&&(r=r.toLowerCase(),i=i.toLowerCase()),r.trim()===i.trim()}tokenize(r,i={}){let l;if(i.intlSegmenter){const c=i.intlSegmenter;if(c.resolvedOptions().granularity!="word")throw new Error('The segmenter passed must have a granularity of "word"');l=[];for(const f of Array.from(c.segment(r))){const h=f.segment;l.length&&/\s/.test(l[l.length-1])&&/\s/.test(h)?l[l.length-1]+=h:l.push(h)}}else l=r.match(A8)||[];const o=[];let u=null;return l.forEach(c=>{/\s/.test(c)?u==null?o.push(c):o.push(o.pop()+c):u!=null&&/\s/.test(u)?o[o.length-1]==u?o.push(o.pop()+c):o.push(u+c):o.push(c),u=c}),o}join(r){return r.map((i,l)=>l==0?i:i.replace(/^\s+/,"")).join("")}postProcess(r,i){if(!r||i.oneChangePerToken)return r;let l=null,o=null,u=null;return r.forEach(c=>{c.added?o=c:c.removed?u=c:((o||u)&&_x(l,u,o,c),l=c,o=null,u=null)}),(o||u)&&_x(l,u,o,null),r}}const j8=new T8;function R8(e,r,i){return j8.diff(e,r,i)}function _x(e,r,i,l){if(r&&i){const o=ni(r.value),u=za(r.value),c=ni(i.value),f=za(i.value);if(e){const h=Tx(o,c);e.value=lh(e.value,c,h),r.value=Ma(r.value,h),i.value=Ma(i.value,h)}if(l){const h=jx(u,f);l.value=ih(l.value,f,h),r.value=Rs(r.value,h),i.value=Rs(i.value,h)}}else if(i){if(e){const o=ni(i.value);i.value=i.value.substring(o.length)}if(l){const o=ni(l.value);l.value=l.value.substring(o.length)}}else if(e&&l){const o=ni(l.value),u=ni(r.value),c=za(r.value),f=Tx(o,u);r.value=Ma(r.value,f);const h=jx(Ma(o,f),c);r.value=Rs(r.value,h),l.value=ih(l.value,o,h),e.value=lh(e.value,o,o.slice(0,o.length-h.length))}else if(l){const o=ni(l.value),u=za(r.value),c=Rx(u,o);r.value=Rs(r.value,c)}else if(e){const o=za(e.value),u=ni(r.value),c=Rx(o,u);r.value=Ma(r.value,c)}}class _8 extends Zh{tokenize(r){const i=new RegExp(`(\\r?\\n)|[${Ws}]+|[^\\S\\n\\r]+|[^${Ws}]`,"ug");return r.match(i)||[]}}const L8=new _8;function D8(e,r,i){return L8.diff(e,r,i)}class O8 extends Zh{constructor(){super(...arguments),this.tokenize=F8}equals(r,i,l){return l.ignoreWhitespace?((!l.newlineIsToken||!r.includes(`
|
|
58
|
+
`))&&(r=r.trim()),(!l.newlineIsToken||!i.includes(`
|
|
59
|
+
`))&&(i=i.trim())):l.ignoreNewlineAtEof&&!l.newlineIsToken&&(r.endsWith(`
|
|
60
|
+
`)&&(r=r.slice(0,-1)),i.endsWith(`
|
|
61
|
+
`)&&(i=i.slice(0,-1))),super.equals(r,i,l)}}const M8=new O8;function z8(e,r,i){return M8.diff(e,r,i)}function F8(e,r){r.stripTrailingCr&&(e=e.replace(/\r\n/g,`
|
|
62
|
+
`));const i=[],l=e.split(/(\n|\r\n)/);l[l.length-1]||l.pop();for(let o=0;o<l.length;o++){const u=l[o];o%2&&!r.newlineIsToken?i[i.length-1]+=u:i.push(u)}return i}function uv(e,r){const i=D8(e,r),l=[],o=[];for(const u of i)u.added?o.push({value:u.value,type:"added"}):u.removed?l.push({value:u.value,type:"removed"}):(l.push({value:u.value,type:"unchanged"}),o.push({value:u.value,type:"unchanged"}));return{oldSegments:l,newSegments:o}}function cv(e,r){if(!e.trim()||!r.trim()||e===r)return!1;const i=R8(e,r);let l=0,o=0;for(const c of i)o+=c.value.length,!c.added&&!c.removed&&(l+=c.value.length);return l/o>=.2}function fv({onSubmit:e,onCancel:r,selectedCode:i,syntaxTheme:l,filename:o}){const[u,c]=A.useState(""),[f,h]=A.useState(!1),[p,g]=A.useState("edit"),b=A.useRef(null),v=A1(u),x=v?p:"edit",S=async N=>{if(N.preventDefault(),!!u.trim()){h(!0);try{await e(u.trim()),c(""),g("edit")}catch(E){console.error("Failed to submit comment:",E)}finally{h(!1)}}},w=N=>{N.key==="Enter"&&(N.metaKey||N.ctrlKey)?S(N):N.key==="Escape"&&r()};return y.jsxs("form",{className:"m-2 mx-3 p-3 bg-github-bg-tertiary border border-yellow-600/50 rounded-md border-l-4 border-l-yellow-400",onSubmit:S,"data-empty":!u.trim(),children:[y.jsxs("div",{className:"flex items-center justify-between mb-2",children:[y.jsx("span",{className:"text-sm font-medium",style:{color:"var(--color-yellow-path-text)"},children:"Add a comment"}),v?y.jsxs("div",{className:"flex items-center border border-github-border rounded-md overflow-hidden",children:[y.jsx("button",{type:"button",onClick:()=>g("edit"),className:`text-xs px-2.5 py-1.5 ${x==="edit"?"bg-github-bg-tertiary text-github-text-primary":"bg-github-bg-secondary text-github-text-secondary"} transition-colors`,children:"Edit"}),y.jsx("button",{type:"button",onClick:()=>g("preview"),className:`text-xs px-2.5 py-1.5 border-l border-github-border ${x==="preview"?"bg-github-bg-tertiary text-github-text-primary":"bg-github-bg-secondary text-github-text-secondary"} transition-colors`,children:"Preview"})]}):y.jsx(T1,{selectedCode:i,value:u,onChange:c,textareaRef:b})]}),v&&x==="preview"?y.jsx("div",{className:"min-h-[60px] mb-2 bg-github-bg-secondary border border-github-border rounded px-3 py-2",children:y.jsx(Td,{body:u,originalCode:i,filename:o,syntaxTheme:l})}):y.jsx("textarea",{ref:b,className:"w-full min-h-[60px] mb-2 resize-y bg-github-bg-secondary border border-github-border rounded px-3 py-2 text-github-text-primary text-sm leading-6 focus:outline-none focus:border-blue-600 focus:ring-2 focus:ring-blue-600/30 focus:min-h-[80px] disabled:opacity-50",value:u,onChange:N=>c(N.target.value),onKeyDown:w,placeholder:"Leave a comment...",rows:Math.max(3,u.split(`
|
|
63
|
+
`).length),autoFocus:!0,disabled:f}),y.jsxs("div",{className:"flex gap-2 justify-end",children:[y.jsx("button",{type:"button",onClick:r,className:"text-xs px-3 py-1.5 bg-github-bg-tertiary text-github-text-primary border border-github-border rounded hover:opacity-80 transition-all disabled:opacity-50",disabled:f,children:"Cancel"}),y.jsx("button",{type:"submit",className:"text-xs px-3 py-1.5 rounded transition-all disabled:opacity-50",style:{backgroundColor:"var(--color-yellow-btn-bg)",color:"var(--color-yellow-btn-text)",border:"1px solid var(--color-yellow-btn-border)"},onMouseEnter:N=>{N.currentTarget.style.backgroundColor="var(--color-yellow-btn-hover-bg)",N.currentTarget.style.borderColor="var(--color-yellow-btn-hover-border)"},onMouseLeave:N=>{N.currentTarget.style.backgroundColor="var(--color-yellow-btn-bg)",N.currentTarget.style.borderColor="var(--color-yellow-btn-border)"},disabled:!u.trim()||f,children:f?"Submitting...":"Submit"})]})]})}const eu=Qt.memo(({onMouseDown:e,onMouseUp:r,title:i="Add a comment"})=>y.jsx("button",{className:"absolute -right-2 top-1/2 -translate-y-1/2 w-7 h-7 flex items-center justify-center rounded transition-all duration-150 hover:scale-110 z-10","data-comment-button":"true",style:{backgroundColor:"var(--color-yellow-btn-bg)",color:"var(--color-yellow-btn-text)",border:"1px solid var(--color-yellow-btn-border)"},onMouseEnter:l=>{l.currentTarget.style.backgroundColor="var(--color-yellow-btn-hover-bg)",l.currentTarget.style.borderColor="var(--color-yellow-btn-hover-border)"},onMouseLeave:l=>{l.currentTarget.style.backgroundColor="var(--color-yellow-btn-bg)",l.currentTarget.style.borderColor="var(--color-yellow-btn-border)"},onMouseDown:e,onMouseUp:r,title:i,children:y.jsx(d1,{className:"w-4 h-4"})}));eu.displayName="CommentButton";const tu=Qt.memo(({onClick:e,title:r="Open in editor",className:i})=>y.jsx("button",{className:`absolute -right-10 top-1/2 -translate-y-1/2 w-7 h-7 flex items-center justify-center rounded transition-all duration-150 hover:scale-110 z-10 ${i||""}`,"data-open-in-editor-button":"true",style:{backgroundColor:"var(--color-editor-btn-bg)",color:"var(--color-editor-btn-text)",border:"1px solid var(--color-editor-btn-border)"},onMouseEnter:l=>{l.currentTarget.style.backgroundColor="var(--color-editor-btn-hover-bg)",l.currentTarget.style.borderColor="var(--color-editor-btn-hover-border)"},onMouseLeave:l=>{l.currentTarget.style.backgroundColor="var(--color-editor-btn-bg)",l.currentTarget.style.borderColor="var(--color-editor-btn-border)"},onMouseDown:l=>{l.stopPropagation()},onClick:l=>{l.stopPropagation(),e(l)},title:r,children:y.jsx(q2,{className:"w-4 h-4 opacity-80"})}));tu.displayName="OpenInEditorButton";const B8=e=>{if("isExpanded"in e&&e.isExpanded)return"bg-github-bg-tertiary/80";switch(e.type){case"add":return"bg-diff-addition-bg";case"delete":return"bg-diff-deletion-bg";default:return"bg-transparent"}},dv=Qt.memo(({line:e,index:r,lineId:i,isCurrentLine:l=!1,hoveredLineIndex:o,selectedLineStyle:u,onMouseEnter:c,onMouseLeave:f,onMouseMove:h,onCommentButtonMouseDown:p,onCommentButtonMouseUp:g,onOpenInEditor:b,syntaxTheme:v,onClick:x,filename:S,diffSegments:w})=>{const N=e.newLineNumber||e.oldLineNumber,E=o===r&&N,C=l?"keyboard-cursor":"";return y.jsxs("tr",{id:i,className:`group ${B8(e)} relative ${u} ${C} cursor-pointer`,onMouseEnter:c,onMouseLeave:f,onMouseMove:h,onClick:x,children:[y.jsx("td",{className:"w-[var(--line-number-width)] min-w-[var(--line-number-width)] max-w-[var(--line-number-width)] px-2 text-right text-github-text-muted bg-github-bg-secondary border-r border-github-border select-none align-top relative",children:e.oldLineNumber||""}),y.jsxs("td",{className:"w-[var(--line-number-width)] min-w-[var(--line-number-width)] max-w-[var(--line-number-width)] px-2 text-right text-github-text-muted bg-github-bg-secondary border-r border-github-border select-none align-top relative overflow-visible",children:[y.jsx("span",{children:e.newLineNumber||""}),E&&y.jsxs(y.Fragment,{children:[b&&y.jsx(tu,{onClick:b}),y.jsx(eu,{onMouseDown:p,onMouseUp:g})]})]}),y.jsx("td",{className:"p-0 w-full relative align-top",children:y.jsx(N1,{line:e,syntaxTheme:v,filename:S,diffSegments:w})})]})});dv.displayName="DiffLineRow";const Lx=e=>e!==void 0&&"isExpanded"in e&&e.isExpanded===!0,Dx=(e,r)=>r?"bg-github-bg-tertiary/80":e?.type==="delete"?"bg-diff-deletion-bg":e?.type==="add"?"bg-diff-addition-bg":e?.type==="normal"?"bg-transparent":"bg-github-bg-secondary";function I8({chunk:e,chunkIndex:r,comments:i,onAddComment:l,onGeneratePrompt:o,onRemoveComment:u,onUpdateComment:c,syntaxTheme:f,cursor:h=null,fileIndex:p=0,onLineClick:g,commentTrigger:b,onCommentTriggerHandled:v,filename:x,onOpenInEditor:S}){const[w,N]=A.useState(null),[E,C]=A.useState(null),[j,z]=A.useState(!1),[I,L]=A.useState(null),[O,Z]=A.useState(null);A.useEffect(()=>{if(b?.lineIndex!==void 0){const M=e.lines[b.lineIndex];if(M&&M.type!=="delete"){const V=M.newLineNumber;V&&(L({side:"new",lineNumber:V}),v?.())}}},[b,e.lines,v]),A.useEffect(()=>{if(j){const M=()=>{z(!1),N(null),C(null)};return document.addEventListener("mouseup",M),()=>{document.removeEventListener("mouseup",M)}}},[j]);const $=A.useCallback((M,V)=>{I?.side===M&&I?.lineNumber===V?L(null):L({side:M,lineNumber:V})},[I]),F=A.useCallback(()=>{L(null)},[]),H=A.useCallback(()=>{if(!I)return"";const{side:M,lineNumber:V}=I,R=e.lines;if(typeof V=="number")return R.find(q=>M==="old"?q.oldLineNumber===V:q.newLineNumber===V)?.content?.replace(/^[+-]/,"")||"";{const[D,q]=V;return R.filter(te=>{const ie=M==="old"?te.oldLineNumber:te.newLineNumber;return ie!==void 0&&ie>=D&&ie<=q}).map(te=>te.content?.replace(/^[+-]/,"")||"").join(`
|
|
64
|
+
`)}},[I,e.lines]),G=A.useCallback(async M=>{if(I!==null){const V=H();await l(I.lineNumber,M,V||void 0,I.side),L(null)}},[I,l,H]),Q=(M,V)=>i.filter(R=>{const D=Array.isArray(R.line)?R.line[1]===M:R.line===M,q=!R.side||R.side===V;return D&&q}),U=M=>M.oldLine?.type==="delete"&&M.newLine?.type==="add"?M.newLineNumber?"right":"left":M.oldLine?.type==="delete"?"left":M.newLine?.type==="add"?"right":"full",Y=(M,V)=>{const R=M==="old"?V.oldLineNumber:V.newLineNumber;if(!R)return"";if(j&&w&&E&&w.side===M&&E.side===M){const D=Math.min(w.lineNumber,E.lineNumber),q=Math.max(w.lineNumber,E.lineNumber);if(R>=D&&R<=q){let T="after:bg-blue-100 after:absolute after:inset-0 after:opacity-30 after:border-l-4 after:border-blue-500 after:pointer-events-none";return R===D&&(T+=" after:border-t-2"),R===q&&(T+=" after:border-b-2"),T}}if(I&&I.side===M){const D=Array.isArray(I.lineNumber)?I.lineNumber:[I.lineNumber,I.lineNumber],q=D[0],T=D[1];if(q!==void 0&&T!==void 0&&R>=q&&R<=T)return"after:bg-diff-selected-bg after:absolute after:inset-0 after:border-l-5 after:border-l-diff-selected-border after:pointer-events-none"}return""},B=A.useCallback(M=>{const V=[];let R=e.oldStart,D=e.newStart,q=0;for(;q<M.length;){const T=M[q];if(!T){q++;continue}if(T.type==="normal")V.push({oldLine:T,newLine:{...T},oldLineNumber:T.oldLineNumber??R,newLineNumber:T.newLineNumber??D,oldLineOriginalIndex:q,newLineOriginalIndex:q}),R++,D++,q++;else if(T.type==="delete"){let te=q+1;for(;te<M.length&&M[te]?.type==="delete";)te++;const ie=M.slice(q,te),fe=q,ge=[],ye=te;for(;te<M.length&&M[te]?.type==="add";){const me=M[te];me&&ge.push(me),te++}const pe=Math.max(ie.length,ge.length);for(let me=0;me<pe;me++){const xe=ie[me],de=ge[me];let we;xe&&de&&cv(xe.content,de.content)&&(we=uv(xe.content,de.content)),V.push({oldLine:xe,newLine:de,oldLineNumber:xe?xe.oldLineNumber??R+me:void 0,newLineNumber:de?de.newLineNumber??D+me:void 0,oldLineOriginalIndex:xe?fe+me:void 0,newLineOriginalIndex:de?ye+me:void 0,wordLevelDiff:we})}R+=ie.length,D+=ge.length,q=te}else T.type==="add"&&(V.push({newLine:T,newLineNumber:T.newLineNumber??D,newLineOriginalIndex:q}),D++,q++)}return V},[e.oldStart,e.newStart]),X=A.useMemo(()=>B(e.lines),[e.lines,B]);return y.jsx("div",{className:"bg-github-bg-primary overflow-hidden",children:y.jsx("table",{className:"w-full table-fixed border-collapse font-mono text-sm leading-5",children:y.jsx("tbody",{children:X.map((M,V)=>{const R=M.oldLineNumber?Q(M.oldLineNumber,"old"):[],D=M.newLineNumber?Q(M.newLineNumber,"new"):[],q=[...R,...D],T=M.oldLineOriginalIndex??-1,te=M.newLineOriginalIndex??-1,ie=h?h.side==="left"&&T>=0?h.chunkIndex===r&&h.lineIndex===T:h.side==="right"&&te>=0?h.chunkIndex===r&&h.lineIndex===te:!1:!1,fe=T>=0?`file-${p}-chunk-${r}-line-${T}-left`:void 0,ge=te>=0?`file-${p}-chunk-${r}-line-${te}-right`:void 0,ye=ie&&h?.side==="left",pe=ie&&h?.side==="right",me="keyboard-cursor";return y.jsxs(Qt.Fragment,{children:[y.jsxs("tr",{className:"group cursor-pointer",onClick:xe=>{if(!j){const de=xe.target;if(!(de instanceof HTMLElement))return;const we=de.closest("td:nth-child(1)")||de.closest("td:nth-child(2)"),Ee=de.closest("td:nth-child(3)")||de.closest("td:nth-child(4)");we&&T>=0?g?.(p,r,T,"left"):Ee&&te>=0&&g?.(p,r,te,"right")}},onMouseEnter:xe=>{const de=xe.target;if(!(de instanceof HTMLElement))return;const we=de.closest("td:nth-child(1)")||de.closest("td:nth-child(2)"),Ee=de.closest("td:nth-child(3)")||de.closest("td:nth-child(4)");we&&M.oldLineNumber?Z({side:"old",lineNumber:M.oldLineNumber}):Ee&&M.newLineNumber&&Z({side:"new",lineNumber:M.newLineNumber})},onMouseMove:xe=>{const de=xe.target;if(!(de instanceof HTMLElement))return;const we=de.closest("td:nth-child(1)")||de.closest("td:nth-child(2)"),Ee=de.closest("td:nth-child(3)")||de.closest("td:nth-child(4)");we&&M.oldLineNumber?(O?.side!=="old"||O?.lineNumber!==M.oldLineNumber)&&Z({side:"old",lineNumber:M.oldLineNumber}):Ee&&M.newLineNumber&&(O?.side!=="new"||O?.lineNumber!==M.newLineNumber)&&Z({side:"new",lineNumber:M.newLineNumber}),j&&w&&(w.side==="old"&&M.oldLineNumber?C({side:"old",lineNumber:M.oldLineNumber}):w.side==="new"&&M.newLineNumber&&C({side:"new",lineNumber:M.newLineNumber}))},onMouseLeave:()=>Z(null),children:[y.jsxs("td",{id:fe,className:`w-[var(--line-number-width)] min-w-[var(--line-number-width)] max-w-[var(--line-number-width)] px-2 text-right text-github-text-muted bg-github-bg-secondary border-r border-github-border select-none align-top relative overflow-visible ${ye?me:""}`,children:[y.jsx("span",{children:M.oldLineNumber||""}),O?.side==="old"&&O?.lineNumber===M.oldLineNumber&&y.jsxs(y.Fragment,{children:[S&&x&&M.oldLine?.type!=="delete"&&M.newLineNumber!==void 0&&y.jsx(tu,{onClick:()=>{const xe=M.newLineNumber;!x||xe===void 0||S(x,xe)}}),y.jsx(eu,{onMouseDown:xe=>{xe.stopPropagation(),M.oldLineNumber&&(N({side:"old",lineNumber:M.oldLineNumber}),C({side:"old",lineNumber:M.oldLineNumber}),z(!0))},onMouseUp:xe=>{if(xe.stopPropagation(),!M.oldLineNumber||!w){z(!1),N(null),C(null);return}const de=E&&E.side==="old"?E.lineNumber:M.oldLineNumber;if(w.side!=="old"||w.lineNumber===de)$("old",M.oldLineNumber);else{const we=Math.min(w.lineNumber,de),Ee=Math.max(w.lineNumber,de);$("old",[we,Ee])}z(!1),N(null),C(null)}})]})]}),y.jsx("td",{className:`w-1/2 p-0 align-top border-r border-github-border relative ${Dx(M.oldLine,Lx(M.oldLine))} ${Y("old",M)} ${ye?me:""}`,children:M.oldLine&&y.jsx("div",{className:"flex items-center relative min-h-[20px] px-3",children:M.wordLevelDiff?y.jsx(Ad,{segments:M.wordLevelDiff.oldSegments,className:"flex-1 text-github-text-primary whitespace-pre-wrap break-all overflow-wrap-break-word select-text"}):y.jsx(Va,{code:M.oldLine.content,className:"flex-1 text-github-text-primary whitespace-pre-wrap break-all overflow-wrap-break-word select-text [&_pre]:m-0 [&_pre]:p-0 [&_pre]:!bg-transparent [&_pre]:font-inherit [&_pre]:text-inherit [&_pre]:leading-inherit [&_code]:!bg-transparent [&_code]:font-inherit [&_code]:text-inherit [&_code]:leading-inherit",syntaxTheme:f,filename:x})})}),y.jsxs("td",{id:ge,className:`w-[var(--line-number-width)] min-w-[var(--line-number-width)] max-w-[var(--line-number-width)] px-2 text-right text-github-text-muted bg-github-bg-secondary border-r border-github-border select-none align-top relative overflow-visible ${pe?me:""}`,children:[y.jsx("span",{children:M.newLineNumber||""}),O?.side==="new"&&O?.lineNumber===M.newLineNumber&&y.jsxs(y.Fragment,{children:[S&&x&&M.newLineNumber!==void 0&&y.jsx(tu,{onClick:()=>{const xe=M.newLineNumber;!x||xe===void 0||S(x,xe)}}),y.jsx(eu,{onMouseDown:xe=>{xe.stopPropagation(),M.newLineNumber&&(N({side:"new",lineNumber:M.newLineNumber}),C({side:"new",lineNumber:M.newLineNumber}),z(!0))},onMouseUp:xe=>{if(xe.stopPropagation(),!M.newLineNumber||!w){z(!1),N(null),C(null);return}const de=E&&E.side==="new"?E.lineNumber:M.newLineNumber;if(w.side!=="new"||w.lineNumber===de)$("new",M.newLineNumber);else{const we=Math.min(w.lineNumber,de),Ee=Math.max(w.lineNumber,de);$("new",[we,Ee])}z(!1),N(null),C(null)}})]})]}),y.jsx("td",{className:`w-1/2 p-0 align-top relative ${Dx(M.newLine,Lx(M.newLine))} ${Y("new",M)} ${pe?me:""}`,children:M.newLine&&y.jsx("div",{className:"flex items-center relative min-h-[20px] px-3",children:M.wordLevelDiff?y.jsx(Ad,{segments:M.wordLevelDiff.newSegments,className:"flex-1 text-github-text-primary whitespace-pre-wrap break-all overflow-wrap-break-word select-text"}):y.jsx(Va,{code:M.newLine.content,className:"flex-1 text-github-text-primary whitespace-pre-wrap break-all overflow-wrap-break-word select-text [&_pre]:m-0 [&_pre]:p-0 [&_pre]:!bg-transparent [&_pre]:font-inherit [&_pre]:text-inherit [&_pre]:leading-inherit [&_code]:!bg-transparent [&_code]:font-inherit [&_code]:text-inherit [&_code]:leading-inherit",syntaxTheme:f,filename:x})})})]}),q.length>0&&y.jsx("tr",{className:"bg-github-bg-secondary",children:y.jsx("td",{colSpan:4,className:"p-0 border-t border-github-border",children:q.map(xe=>{const de=xe.side||"new";let we;return de==="old"&&M.oldLineNumber?we="left":de==="new"&&M.newLineNumber?we="right":we=U(M),y.jsx("div",{className:`flex ${we==="left"?"justify-start":we==="right"?"justify-end":"justify-center"}`,children:y.jsx("div",{className:`${we==="full"?"w-full":"w-1/2"}`,children:y.jsx("div",{className:"m-2 mx-3",children:y.jsx(vh,{comment:xe,onGeneratePrompt:o,onRemoveComment:u,onUpdateComment:c,syntaxTheme:f})})})},xe.id)})})}),I&&(I.side==="old"&&I.lineNumber===M.oldLineNumber||I.side==="new"&&I.lineNumber===M.newLineNumber||Array.isArray(I.lineNumber)&&(I.side==="new"&&I.lineNumber[1]===M.newLineNumber||I.side==="old"&&I.lineNumber[1]===M.oldLineNumber))&&y.jsx("tr",{className:"bg-github-bg-secondary",children:y.jsx("td",{colSpan:4,className:"p-0",children:y.jsx("div",{className:`flex ${I.side==="old"?"justify-start":I.side==="new"?"justify-end":"justify-center"}`,children:y.jsx("div",{className:"w-1/2",children:y.jsx(fv,{onSubmit:G,onCancel:F,selectedCode:H(),syntaxTheme:f,filename:x})})})})})]},V)})})})})}const U8=A.memo(function({chunk:r,chunkIndex:i,comments:l,onAddComment:o,onGeneratePrompt:u,onRemoveComment:c,onUpdateComment:f,mode:h=Ka,syntaxTheme:p,cursor:g=null,fileIndex:b=0,onLineClick:v,commentTrigger:x,onCommentTriggerHandled:S,filename:w,onOpenInEditor:N}){const[E,C]=A.useState(null),[j,z]=A.useState(null),[I,L]=A.useState(!1),[O,Z]=A.useState(null),[$,F]=A.useState(null);A.useEffect(()=>{if(x?.lineIndex!==void 0){const V=r.lines[x.lineIndex];if(V){const R=V.newLineNumber||V.oldLineNumber,D=V.type==="delete"?"old":"new";R&&(Z({side:D,lineNumber:R}),S?.())}}},[x,r.lines,S]),A.useEffect(()=>{if(I){const V=()=>{L(!1),C(null),z(null)};return document.addEventListener("mouseup",V),()=>{document.removeEventListener("mouseup",V)}}},[I]);const H=A.useCallback((V,R)=>{O?.side===V&&O?.lineNumber===R?Z(null):Z({side:V,lineNumber:R})},[O]),G=A.useCallback(()=>{Z(null)},[]),Q=A.useCallback(()=>{if(!O)return"";const{side:V,lineNumber:R}=O,D=r.lines;if(typeof R=="number")return D.find(T=>V==="old"?T.oldLineNumber===R:T.newLineNumber===R)?.content?.replace(/^[+-]/,"")||"";{const[q,T]=R;return D.filter(ie=>{const fe=V==="old"?ie.oldLineNumber:ie.newLineNumber;return fe!==void 0&&fe>=q&&fe<=T}).map(ie=>ie.content?.replace(/^[+-]/,"")||"").join(`
|
|
65
|
+
`)}},[O,r.lines]),U=A.useCallback(async V=>{if(O!==null){const R=Q();await o(O.lineNumber,V,R||void 0,O.side),Z(null)}},[O,o,Q]),Y=(V,R)=>l.filter(D=>{const q=Array.isArray(D.line)?D.line[1]===V:D.line===V,T=!D.side||D.side===R;return q&&T}),B=V=>{if(h==="unified")return"full";switch(V.type){case"delete":return"left";case"add":return"right";default:return"full"}},X=(V,R)=>{if(!V)return"";if(I&&E&&j){const D=Math.min(E,j),q=Math.max(E,j);if(V>=D&&V<=q){let T="after:bg-blue-100 after:absolute after:inset-0 after:opacity-30 after:border-l-4 after:border-blue-500 after:pointer-events-none";return V===D&&(T+=" after:border-t-2"),V===q&&(T+=" after:border-b-2"),T}}if(O&&O.side===R){const D=Array.isArray(O.lineNumber)?O.lineNumber[0]:O.lineNumber,q=Array.isArray(O.lineNumber)?O.lineNumber[1]:O.lineNumber;if(V>=D&&V<=q)return"after:bg-diff-selected-bg after:absolute after:inset-0 after:border-l-5 after:border-l-diff-selected-border after:pointer-events-none"}return""},M=A.useMemo(()=>{const V=new Map,R=r.lines;let D=0;for(;D<R.length;){const q=R[D];if(!q){D++;continue}if(q.type==="delete"){let T=D+1;for(;T<R.length&&R[T]?.type==="delete";)T++;const te=R.slice(D,T),ie=D,fe=[];for(;T<R.length&&R[T]?.type==="add";){const ye=R[T];ye&&fe.push({line:ye,index:T}),T++}const ge=Math.max(te.length,fe.length);for(let ye=0;ye<ge;ye++){const pe=te[ye],me=fe[ye];if(pe&&me&&cv(pe.content,me.line.content)){const xe=uv(pe.content,me.line.content);V.set(ie+ye,xe.oldSegments),V.set(me.index,xe.newSegments)}}D=T}else D++}return V},[r.lines]);return h==="split"?y.jsx(I8,{chunk:r,chunkIndex:i,comments:l,onAddComment:o,onGeneratePrompt:u,onRemoveComment:c,onUpdateComment:f,onOpenInEditor:N,syntaxTheme:p,cursor:g,fileIndex:b,onLineClick:v,filename:w,commentTrigger:x,onCommentTriggerHandled:S}):y.jsx("div",{className:"bg-github-bg-primary",children:y.jsx("table",{className:"w-full table-fixed border-collapse font-mono text-sm leading-5",children:y.jsx("tbody",{children:r.lines.map((V,R)=>{const D=V.newLineNumber||V.oldLineNumber||0,q=V.type==="delete"?"old":"new",T=O?Array.isArray(O.lineNumber)?O.lineNumber[1]:O.lineNumber:null,te=V.type==="delete"?V.oldLineNumber:V.newLineNumber,ie=V.type==="delete"?"old":"new",fe=te?Y(te,ie):[],ge=`file-${b}-chunk-${i}-line-${R}`,ye=g&&g.chunkIndex===i&&g.lineIndex===R;return y.jsxs(Qt.Fragment,{children:[y.jsx(dv,{line:V,index:R,lineId:ge,isCurrentLine:ye||!1,hoveredLineIndex:$,selectedLineStyle:X(V.newLineNumber||V.oldLineNumber,V.type==="delete"?"old":"new"),onMouseEnter:()=>{F(R)},onMouseLeave:()=>F(null),onMouseMove:()=>{if(I&&E){const pe=V.newLineNumber||V.oldLineNumber;pe&&z(pe)}},onCommentButtonMouseDown:pe=>{pe.stopPropagation();const me=V.newLineNumber||V.oldLineNumber;me&&(C(me),z(me),L(!0))},onCommentButtonMouseUp:pe=>{pe.stopPropagation();const me=V.newLineNumber||V.oldLineNumber,xe=V.type==="delete"?"old":"new";if(!me||!E){L(!1),C(null),z(null);return}const de=j||me;if(E===de)H(xe,me);else{const we=Math.min(E,de),Ee=Math.max(E,de);H(xe,[we,Ee])}L(!1),C(null),z(null)},onOpenInEditor:N&&w&&V.type!=="delete"&&(V.newLineNumber||V.oldLineNumber)?()=>{const pe=V.newLineNumber||V.oldLineNumber;pe&&w&&N(w,pe)}:void 0,syntaxTheme:p,filename:w,diffSegments:M.get(R),onClick:()=>{const pe=V.type==="delete"?"left":"right";v?.(b,i,R,pe)}}),fe.map(pe=>{const me=B(V);return y.jsx("tr",{className:"bg-github-bg-secondary",children:y.jsx("td",{colSpan:3,className:"p-0 border-t border-github-border",children:y.jsx("div",{className:`flex ${me==="left"?"justify-start":me==="right"?"justify-end":"justify-center"}`,children:y.jsx("div",{className:`${me==="full"?"w-full":"w-1/2"} m-2 mx-4`,children:y.jsx(vh,{comment:pe,onGeneratePrompt:u,onRemoveComment:c,onUpdateComment:f,syntaxTheme:p})})})})},pe.id)}),O&&O.side===q&&T===D&&y.jsx("tr",{className:"bg-[var(--bg-secondary)]",children:y.jsx("td",{colSpan:3,className:"p-0",children:y.jsx("div",{className:`flex ${B(V)==="left"?"justify-start":B(V)==="right"?"justify-end":"justify-center"}`,children:y.jsx("div",{className:`${B(V)==="full"?"w-full":"w-1/2"}`,children:y.jsx(fv,{onSubmit:U,onCancel:G,selectedCode:Q(),syntaxTheme:p,filename:w})})})})})]},R)})})})})}),gd=20,bd=A.memo(function({direction:r,hiddenLines:i,onExpandUp:l,onExpandDown:o,onExpandAll:u,isLoading:c=!1}){if(i<=0)return null;const f=`${i} ${i===1?"line":"lines"}`,h=i<=gd,p="grid-cols-[var(--line-number-width)_1fr]",g="flex flex-1 w-full items-center justify-center py-1 text-github-text-primary hover:bg-github-bg-secondary hover:text-github-text-muted transition-all duration-200 disabled:opacity-50 disabled:cursor-not-allowed",b=[];return h?b.push({key:"all",onClick:u,ariaLabel:`Expand all ${i} hidden lines`,icon:y.jsx(kk,{size:16,"aria-hidden":"true"})}):((r==="up"||r==="both")&&b.push({key:"up",onClick:l,ariaLabel:`Expand ${gd} hidden lines above`,icon:y.jsx(E2,{size:12,"aria-hidden":"true",className:"translate-y-0.5"})}),(r==="down"||r==="both")&&b.push({key:"down",onClick:o,ariaLabel:`Expand ${gd} hidden lines below`,icon:y.jsx(S2,{size:12,"aria-hidden":"true",className:"-translate-y-0.5"})})),y.jsxs("div",{className:`grid w-full border-l border-r border-github-border bg-github-bg-tertiary text-sm ${p}`,children:[y.jsx("div",{className:"flex flex-col items-stretch justify-center gap-0.5 border-r border-github-border",children:c?y.jsx(lk,{size:14,className:"animate-spin text-github-text-muted self-center","aria-hidden":"true"}):b.map(v=>y.jsx("button",{type:"button",onClick:v.onClick,disabled:c||!v.onClick,className:g,title:v.ariaLabel,"aria-label":v.ariaLabel,children:v.icon},v.key))}),y.jsx("div",{className:"flex items-center justify-start px-3 py-1.5 font-mono text-github-text-muted select-none",children:f})]})});function nu({file:e,comments:r,diffMode:i,syntaxTheme:l,cursor:o,fileIndex:u,mergedChunks:c,isExpandLoading:f,expandHiddenLines:h,expandAllBetweenChunks:p,onAddComment:g,onGeneratePrompt:b,onRemoveComment:v,onUpdateComment:x,onLineClick:S,onOpenInEditor:w,commentTrigger:N,onCommentTriggerHandled:E}){const C=(j,z,I,L)=>j==="top"&&z.hiddenLinesBefore>0?y.jsx(bd,{direction:"down",hiddenLines:z.hiddenLinesBefore,onExpandDown:()=>h(e,I,"up"),onExpandAll:()=>p(e,I,z.hiddenLinesBefore),isLoading:f}):j==="middle"&&z.hiddenLinesBefore>0?y.jsx(bd,{direction:"both",hiddenLines:z.hiddenLinesBefore,onExpandUp:()=>h(e,I-1,"down"),onExpandDown:()=>h(e,I,"up"),onExpandAll:()=>p(e,I,z.hiddenLinesBefore),isLoading:f}):j==="bottom"&&z.hiddenLinesAfter>0?y.jsx(bd,{direction:"up",hiddenLines:z.hiddenLinesAfter,onExpandUp:()=>h(e,L,"down"),onExpandAll:()=>h(e,L,"down",z.hiddenLinesAfter),isLoading:f}):null;return y.jsx(y.Fragment,{children:c.map((j,z)=>{const I=z===0,L=z===c.length-1,O=j.originalIndices[0]??0,Z=j.originalIndices[j.originalIndices.length-1]??0;return y.jsxs(Qt.Fragment,{children:[I&&C("top",j,O,Z),!I&&C("middle",j,O,Z),y.jsx("div",{id:`chunk-${e.path.replace(/[^a-zA-Z0-9]/g,"-")}-${z}`,children:y.jsx(U8,{chunk:j,chunkIndex:z,comments:r,onAddComment:g,onGeneratePrompt:b,onRemoveComment:v,onUpdateComment:x,onOpenInEditor:w,mode:i,syntaxTheme:l,cursor:o&&o.chunkIndex===z?o:null,fileIndex:u,onLineClick:S,commentTrigger:N&&N.chunkIndex===z?N:null,onCommentTriggerHandled:E,filename:e.path})}),L&&C("bottom",j,O,Z)]},z)})})}const H8=e=>!!(e&&e!=="stdin"),El=["text-[26px] font-semibold","text-[22px] font-semibold","text-xl font-semibold","text-lg font-semibold","text-base font-semibold uppercase tracking-wide","text-base font-semibold"],q8=e=>e.type==="delete"||e.type==="remove",$8=e=>e.type==="normal"||e.type==="context",ru=e=>/^(https?:|mailto:|#|\.{0,2}\/|\/)/i.test(e.trim()),ah=(e,r,i)=>{const l=e[e.length-1];if(l&&l.type===r){l.lines.push(i);return}e.push({type:r,lines:[i]})},yd=(e,r)=>{r.forEach(i=>ah(e,"delete",i)),r.length=0},P8=e=>{const r=[],i=[];let l=!1;return e.forEach(o=>{o.lines.forEach(u=>{if(!(u.type==="header"||u.type==="hunk")){if(q8(u)){i.push(u.content);return}if(u.type==="add"){i.length>0&&(yd(r,i),l=!0),ah(r,l?"change":"add",u.content);return}$8(u)&&(yd(r,i),l=!1,ah(r,"context",u.content))}}),yd(r,i),l=!1}),r},V8=e=>Qt.isValidElement(e),G8=e=>Qt.isValidElement(e),oh=e=>e==null||typeof e=="boolean"?"":typeof e=="string"||typeof e=="number"?String(e):Array.isArray(e)?e.map(oh).join(""):V8(e)?oh(e.props.children):"",hv=e=>({h1:({children:r})=>y.jsx("h1",{className:`${El[0]} mt-6 mb-2 first:mt-0`,children:r}),h2:({children:r})=>y.jsx("h2",{className:`${El[1]} mt-6 mb-2 first:mt-0`,children:r}),h3:({children:r})=>y.jsx("h3",{className:`${El[2]} mt-6 mb-2 first:mt-0`,children:r}),h4:({children:r})=>y.jsx("h4",{className:`${El[3]} mt-6 mb-2 first:mt-0`,children:r}),h5:({children:r})=>y.jsx("h5",{className:`${El[4]} mt-6 mb-2 first:mt-0`,children:r}),h6:({children:r})=>y.jsx("h6",{className:`${El[5]} mt-6 mb-2 first:mt-0`,children:r}),p:({children:r})=>y.jsx("p",{className:"text-base leading-7",children:r}),ul:({children:r})=>y.jsx("ul",{className:"list-disc pl-6 text-base space-y-1",children:r}),ol:({children:r})=>y.jsx("ol",{className:"list-decimal pl-6 text-base space-y-1",children:r}),li:({children:r})=>y.jsx("li",{children:r}),blockquote:({children:r})=>y.jsx("blockquote",{className:"border-l-4 border-github-border pl-4 text-github-text-muted italic",children:r}),hr:()=>y.jsx("hr",{className:"border-github-border"}),a:({href:r,children:i})=>{const l=r??"";if(!l||!ru(l))return y.jsx("span",{children:i});const o=l.startsWith("http");return y.jsx("a",{href:l,target:o?"_blank":void 0,rel:o?"noreferrer":void 0,className:"text-sky-400 hover:text-sky-300 underline underline-offset-4",children:i})},img:({src:r,alt:i})=>{const l=r??"";return!l||!ru(l)?null:y.jsx("img",{src:l,alt:i??"",loading:"lazy",className:"max-w-full rounded border border-github-border"})},pre:({children:r})=>{const l=(Array.isArray(r)?r:[r]).find(G8),o=oh(l??r),c=/language-(\S+)/.exec(l?.props.className??"")?.[1],f=o.replace(/\n$/,"");return c==="mermaid"&&f.trim()?y.jsx(C8,{chart:f}):o.trim()?y.jsx("pre",{className:"markdown-preview-code border border-github-border bg-github-bg-secondary p-3 overflow-x-auto text-sm",children:y.jsx(xh,{code:f,language:c,syntaxTheme:e,className:"font-mono text-github-text-primary"})}):y.jsx("pre",{className:"markdown-preview-code border border-github-border bg-github-bg-secondary p-3 overflow-x-auto text-sm",children:r})},code:({className:r,children:i})=>r?y.jsx("code",{className:r,children:i}):y.jsx("code",{className:"px-1 py-0.5 rounded bg-github-bg-tertiary border border-github-border text-sm font-mono",children:i})}),Y8=e=>{switch(e){case"add":return"border-l-4 border-diff-addition-border";case"delete":return"border-l-4 border-diff-deletion-border";case"change":return"border-l-4 border-diff-addition-border";default:return"border-l-4 border-transparent"}},X8=e=>/^\s*\[[^\]]+\]:\s+\S+/.test(e),Z8=e=>/^\s*\[\^[^\]]+\]:\s+/.test(e),K8=e=>/^\s*<!--.*-->\s*$/.test(e),Q8=e=>e.trim()===""||X8(e)||Z8(e)||K8(e),J8=e=>e.every(Q8),W8=({blocks:e,syntaxTheme:r})=>{const i=A.useMemo(()=>hv(r),[r]);return y.jsx("div",{className:"space-y-4",children:e.map((l,o)=>{const c=l.lines.join(`
|
|
66
|
+
`).trim();if(!c)return null;const f=J8(l.lines);return y.jsx("div",{className:`px-4 ${Y8(l.type)}`,children:f?y.jsx("pre",{className:"whitespace-pre-wrap text-sm text-github-text-primary font-mono",children:c}):y.jsx(Ph,{remarkPlugins:[Xh],urlTransform:h=>ru(h)?h:"",components:i,children:c})},`preview-block-${o}`)})})},ej=({content:e,syntaxTheme:r})=>{const i=A.useMemo(()=>hv(r),[r]);return y.jsx("div",{className:"space-y-4",children:y.jsx(Ph,{remarkPlugins:[Xh],urlTransform:l=>ru(l)?l:"",components:i,children:e})})};function tj(e){const{file:r,baseCommitish:i,targetCommitish:l,mergedChunks:o,syntaxTheme:u}=e,[c,f]=A.useState("diff"),[h,p]=A.useState(null),[g,b]=A.useState(!1),[v,x]=A.useState(null),[S,w]=A.useState(null),N=A.useMemo(()=>P8(o),[o]),E=A.useMemo(()=>!i&&!l?null:r.status==="added"?l?{path:r.path,ref:l}:null:r.status==="deleted"?i?{path:r.oldPath||r.path,ref:i}:null:l?{path:r.path,ref:l}:i?{path:r.oldPath||r.path,ref:i}:null,[i,l,r.path,r.oldPath,r.status]),C=A.useMemo(()=>E?`${E.ref}:${E.path}`:null,[E]);A.useEffect(()=>{if(!E||!C||!H8(E.ref)){p(null),w(null),x(null),b(!1);return}let z=!1;return(C!==S||h===null)&&(async()=>{C!==S&&p(null),b(!0),x(null);try{const L=encodeURIComponent(E.path),O=await fetch(`/api/blob/${L}?ref=${encodeURIComponent(E.ref)}`);if(!O.ok)throw new Error(`Failed to fetch preview: ${O.statusText}`);const Z=await O.text();z||(p(Z),w(C))}catch(L){z||(p(null),w(null),x(L instanceof Error?L.message:"Failed to load preview"))}finally{z||b(!1)}})(),()=>{z=!0}},[h,S,E,C]);const j=A.useMemo(()=>C===S&&h!==null,[h,S,C]);return A.useEffect(()=>{c==="full-preview"&&!j&&f("diff-preview")},[j,c]),y.jsxs("div",{className:"bg-github-bg-primary",children:[y.jsx("div",{className:"flex items-center justify-between border-b border-github-border px-4 py-2",children:y.jsxs("div",{className:"flex items-center gap-1.5",children:[y.jsxs("button",{onClick:()=>f("diff"),className:`px-2 py-1 text-xs font-medium rounded transition-colors duration-200 flex items-center gap-1 cursor-pointer ${c==="diff"?"text-github-text-primary":"text-github-text-secondary hover:text-github-text-primary"}`,title:"Code Diff",children:[y.jsx(au,{size:14}),"Diff"]}),y.jsxs("button",{onClick:()=>f("diff-preview"),className:`px-2 py-1 text-xs font-medium rounded transition-colors duration-200 flex items-center gap-1 cursor-pointer ${c==="diff-preview"?"text-github-text-primary":"text-github-text-secondary hover:text-github-text-primary"}`,title:"Diff Preview",children:[y.jsx(zs,{size:14}),"Diff Preview"]}),j&&y.jsxs("button",{onClick:()=>f("full-preview"),className:`px-2 py-1 text-xs font-medium rounded transition-colors duration-200 flex items-center gap-1 cursor-pointer ${c==="full-preview"?"text-github-text-primary":"text-github-text-secondary hover:text-github-text-primary"}`,title:"Full Preview",children:[y.jsx(zs,{size:14}),"Full Preview"]})]})}),c==="diff"&&y.jsx(nu,{...e}),c==="diff-preview"&&y.jsx("div",{className:"p-4",children:y.jsx(W8,{blocks:N,syntaxTheme:u})}),c==="full-preview"&&y.jsxs("div",{className:"p-4",children:[g&&y.jsx("div",{className:"text-sm text-github-text-muted mb-3",children:"Loading preview..."}),v&&y.jsx("div",{className:"text-sm text-github-danger mb-3",children:v}),!g&&!v&&h!==null&&y.jsx(ej,{content:h,syntaxTheme:u}),!g&&!v&&h===null&&y.jsx("div",{className:"text-sm text-github-text-muted",children:"Preview unavailable."})]})]})}const Cl=["text-2xl font-semibold","text-xl font-semibold","text-lg font-semibold","text-base font-semibold","text-sm font-semibold uppercase tracking-wide","text-sm font-semibold"],pv={markdown:"Markdown",code:"Code",raw:"Raw",unknown:"Cell"},nj=/"cell_type"\s*:\s*"([^"]+)"/,Ox=/"source"\s*:/,rj=/"execution_count"\s*:\s*(null|[0-9]+)/,ij=/"id"\s*:\s*"([^"]+)"/,lj=e=>e.type==="delete"||e.type==="remove",aj=e=>e.type==="normal"||e.type==="context",mv=e=>e.type==="add"?"add":lj(e)?"delete":aj(e)?"context":null,gv=e=>e==="markdown"||e==="code"||e==="raw"?e:"unknown",oj=e=>{const r=e.trim();if(!r.startsWith('"'))return null;let i=r;i.endsWith(",")&&(i=i.slice(0,-1));try{const l=JSON.parse(i);return typeof l=="string"?l:null}catch{return i.replace(/^"/,"").replace(/"$/,"").replace(/\\n/g,`
|
|
67
|
+
`).replace(/\\t/g," ").replace(/\\"/g,'"').replace(/\\\\/g,"\\")}},sj=e=>{const r=e.indexOf('"source"');if(r===-1)return null;const i=e.indexOf(":",r);if(i===-1)return null;let l=e.slice(i+1).trim();if(!l)return null;if(l.endsWith(",")&&(l=l.slice(0,-1).trim()),l.startsWith("[")){const o=l.lastIndexOf("]");if(o===-1)return null;const u=l.slice(0,o+1);try{const c=JSON.parse(u);if(Array.isArray(c))return c.filter(f=>typeof f=="string")}catch{return null}return[]}if(l.startsWith('"'))try{const o=JSON.parse(l);return typeof o=="string"?[o]:null}catch{return null}return null},uj=e=>{const r=cj(e);if(r)return r;const i=[];let l=null,o=!1,u=!1,c=!1;const f=()=>{l&&(l.status=o&&u?"change":o?"add":u?"delete":"context",i.push(l),l=null,o=!1,u=!1,c=!1)},h=p=>{f(),l={cellType:p,sourceLines:[],status:"context"}};return e.forEach(p=>{p.lines.forEach(g=>{const b=mv(g);if(!b)return;const v=g.content.match(nj);if(v?h(gv(v[1]??"")):!l&&Ox.test(g.content)&&h("unknown"),!l)return;if(b==="add"&&(o=!0),b==="delete"&&(u=!0),!l.id){const w=g.content.match(ij);w&&(l.id=w[1])}if(l.executionCount===void 0){const w=g.content.match(rj);w&&(l.executionCount=w[1]==="null"?null:w[1])}if(Ox.test(g.content)){const w=sj(g.content);if(w){w.forEach(N=>{l?.sourceLines.push({type:b,content:N})}),c=!1;return}c=!0;return}if(!c)return;if(g.content.trim().startsWith("]")){c=!1;return}const S=oj(g.content);S!==null&&l.sourceLines.push({type:b,content:S})})}),f(),{cells:i}},cj=e=>{const r=Mx(e,["add","context"]),i=Mx(e,["delete","context"]),l=qa(r),o=qa(i);if(!l&&!o||l&&l.cells.length===0&&!o)return null;const u=l?.language??o?.language;return{cells:bv(o?.cells??[],l?.cells??[]),language:u}},Mx=(e,r)=>e.flatMap(i=>i.lines).map(i=>{const l=mv(i);return!l||!r.includes(l)?null:i.content}).filter(i=>i!==null).join(`
|
|
68
|
+
`),qa=e=>{if(!e.trim())return null;try{const r=JSON.parse(e);if(!r||typeof r!="object"||!("cells"in r))return null;const i=r.cells;if(!Array.isArray(i))return null;const l=r.metadata,o=fj(l);return{cells:i.map(u=>dj(u)),language:o}}catch{return null}},fj=e=>{if(!e||typeof e!="object")return;const r=e,i=r.language_info;if(i&&typeof i=="object"){const o=i.name;if(typeof o=="string"&&o.trim())return o}const l=r.kernelspec;if(l&&typeof l=="object"){const o=l.language;if(typeof o=="string"&&o.trim())return o}},dj=e=>{const r=typeof e=="object"&&e?e:{},i=typeof r.cell_type=="string"?r.cell_type:"",l=gv(i),o=typeof r.id=="string"?r.id:void 0,u=r.execution_count,c=u===null?null:typeof u=="number"?String(u):typeof u=="string"?u:void 0,f=hj(r.source);return{cellType:l,sourceText:f,id:o,executionCount:c}},hj=e=>typeof e=="string"?e:Array.isArray(e)?e.filter(r=>typeof r=="string").join(""):"",bv=(e,r)=>{const i=[];if(e.some(u=>!!u.id)||r.some(u=>!!u.id)){const u=new Map;e.forEach((f,h)=>{f.id&&u.set(f.id,{cell:f,index:h})});const c=new Set;return r.forEach(f=>{const h=f.id?u.get(f.id):void 0;h&&c.add(h.index),i.push(xd(h?.cell??null,f))}),e.forEach((f,h)=>{c.has(h)||i.push(xd(f,null))}),i}const o=Math.max(e.length,r.length);for(let u=0;u<o;u+=1){const c=e[u]??null,f=r[u]??null;i.push(xd(c,f))}return i},xd=(e,r)=>{if(!r&&e)return{cellType:e.cellType,sourceLines:Fa(e.sourceText,"delete"),status:"delete",id:e.id,executionCount:e.executionCount};if(r&&!e)return{cellType:r.cellType,sourceLines:Fa(r.sourceText,"add"),status:"add",id:r.id,executionCount:r.executionCount};const i=e?.sourceText??"",l=r?.sourceText??"",o=r?.cellType??e?.cellType??"unknown",u=r?.id??e?.id,c=r?.executionCount??e?.executionCount;return i===l&&(e?.cellType??"")===(r?.cellType??"")?{cellType:o,sourceLines:Fa(l,"context"),status:"context",id:u,executionCount:c}:{cellType:o,sourceLines:[...Fa(i,"delete"),...Fa(l,"add")],status:"change",id:u,executionCount:c}},Fa=(e,r)=>e?[{type:r,content:e}]:[],vd=e=>!!(e&&e!=="stdin"),wd=async(e,r)=>{const i=encodeURIComponent(e),l=await fetch(`/api/blob/${i}?ref=${encodeURIComponent(r)}`);return l.ok?l.text():null},Ol=(e,r)=>e.filter(i=>r.includes(i.type)).map(i=>i.content).join(""),Sd=e=>{if(!e)return[];const r=e.split(`
|
|
69
|
+
`);return r.length>0&&r[r.length-1]===""&&r.pop(),r},yv=(e,r)=>!e&&!r?[]:e?r?z8(e,r).flatMap(i=>{const l=i.added?"add":i.removed?"delete":"context";return Sd(i.value).map(o=>({type:l,content:o}))}):Sd(e).map(i=>({type:"delete",content:i})):Sd(r).map(i=>({type:"add",content:i})),pj=e=>Qt.isValidElement(e),mj=e=>Qt.isValidElement(e),sh=e=>e==null||typeof e=="boolean"?"":typeof e=="string"||typeof e=="number"?String(e):Array.isArray(e)?e.map(sh).join(""):pj(e)?sh(e.props.children):"",gj=e=>{switch(e){case"add":return"border-l-4 border-diff-addition-border";case"delete":return"border-l-4 border-diff-deletion-border";case"change":return"border-l-4 border-diff-addition-border";default:return"border-l-4 border-transparent"}},zx=e=>{switch(e){case"before":return"border-l-4 border-diff-deletion-border";case"after":return"border-l-4 border-diff-addition-border";default:return"border-l-4 border-transparent"}},bj=e=>{switch(e){case"add":return"bg-diff-addition-bg";case"delete":return"bg-diff-deletion-bg";default:return"bg-transparent"}},yj=e=>{switch(e){case"add":return"+";case"delete":return"-";default:return" "}},xj=e=>{switch(e){case"add":return"text-github-accent";case"delete":return"text-github-danger";default:return"text-github-text-muted"}},uh=e=>/^(https?:|mailto:|#|\.{0,2}\/|\/)/i.test(e.trim()),vj=e=>({h1:({children:r})=>y.jsx("h1",{className:`${Cl[0]} mb-2`,children:r}),h2:({children:r})=>y.jsx("h2",{className:`${Cl[1]} mb-2`,children:r}),h3:({children:r})=>y.jsx("h3",{className:`${Cl[2]} mb-2`,children:r}),h4:({children:r})=>y.jsx("h4",{className:`${Cl[3]} mb-2`,children:r}),h5:({children:r})=>y.jsx("h5",{className:`${Cl[4]} mb-2`,children:r}),h6:({children:r})=>y.jsx("h6",{className:`${Cl[5]} mb-2`,children:r}),p:({children:r})=>y.jsx("p",{className:"text-sm leading-7",children:r}),ul:({children:r})=>y.jsx("ul",{className:"list-disc pl-6 text-sm space-y-1",children:r}),ol:({children:r})=>y.jsx("ol",{className:"list-decimal pl-6 text-sm space-y-1",children:r}),li:({children:r})=>y.jsx("li",{children:r}),blockquote:({children:r})=>y.jsx("blockquote",{className:"border-l-4 border-github-border pl-4 text-github-text-muted italic",children:r}),hr:()=>y.jsx("hr",{className:"border-github-border"}),a:({href:r,children:i})=>{const l=r??"";if(!l||!uh(l))return y.jsx("span",{children:i});const o=l.startsWith("http");return y.jsx("a",{href:l,target:o?"_blank":void 0,rel:o?"noreferrer":void 0,className:"text-sky-400 hover:text-sky-300 underline underline-offset-4",children:i})},img:({src:r,alt:i})=>{const l=r??"";return!l||!uh(l)?null:y.jsx("img",{src:l,alt:i??"",loading:"lazy",className:"max-w-full rounded border border-github-border"})},pre:({children:r})=>{const l=(Array.isArray(r)?r:[r]).find(mj),o=sh(l??r),c=/language-(\S+)/.exec(l?.props.className??"")?.[1];return o.trim()?y.jsx("pre",{className:"border border-github-border bg-github-bg-secondary p-3 overflow-x-auto text-xs",children:y.jsx(xh,{code:o.replace(/\n$/,""),language:c,syntaxTheme:e,className:"font-mono text-github-text-primary [&_.token-line]:block [&_.token-line]:whitespace-pre"})}):y.jsx("pre",{className:"border border-github-border bg-github-bg-secondary p-3 overflow-x-auto text-xs",children:r})},code:({className:r,children:i})=>r?y.jsx("code",{className:r,children:i}):y.jsx("code",{className:"px-1 py-0.5 rounded bg-github-bg-tertiary border border-github-border text-xs font-mono",children:i}),table:({children:r})=>y.jsx("div",{className:"overflow-x-auto",children:y.jsx("table",{className:"min-w-full border border-github-border",children:r})}),th:({children:r})=>y.jsx("th",{className:"border border-github-border px-2 py-1 bg-github-bg-tertiary text-sm",children:r}),td:({children:r})=>y.jsx("td",{className:"border border-github-border px-2 py-1 text-sm",children:r})}),wj=e=>{const r=Ol(e.sourceLines,["context","delete"]),i=Ol(e.sourceLines,["context","add"]),l=[];return e.status==="change"?(r.trim()&&l.push({label:"Before",content:r,tone:"before"}),i.trim()&&l.push({label:"After",content:i,tone:"after"}),l.length===0&&l.push({label:"After",content:i,tone:"after"}),l):e.status==="delete"?(l.push({label:"Before",content:r||i,tone:"before"}),l):(l.push({label:"After",content:i||r,tone:"after"}),l)},xv=(e,r,i,l)=>{if(!r.trim())return y.jsx("span",{className:"text-xs text-github-text-muted",children:"Empty cell"});if(e==="markdown"){const o=vj(i);return y.jsx(Ph,{remarkPlugins:[Xh],urlTransform:u=>uh(u)?u:"",components:o,children:r})}return e==="raw"?y.jsx("pre",{className:"whitespace-pre-wrap break-words text-xs font-mono text-github-text-primary",children:r}):y.jsx("pre",{className:"overflow-x-auto text-xs",children:y.jsx(Va,{code:r.replace(/\n$/,""),language:l||"python",syntaxTheme:i,className:"font-mono text-github-text-primary [&_.token-line]:block [&_.token-line]:whitespace-pre"})})},Sj=({lines:e,syntaxTheme:r,language:i})=>e.length===0?y.jsx("span",{className:"text-xs text-github-text-muted",children:"Empty cell"}):y.jsx("div",{className:"overflow-x-auto",children:y.jsx("div",{className:"font-mono text-xs",children:e.map((l,o)=>y.jsxs("div",{className:`flex items-start min-h-[16px] ${bj(l.type)}`,children:[y.jsx("span",{className:`w-5 text-center flex-shrink-0 select-none ${xj(l.type)}`,children:yj(l.type)}),y.jsx(Va,{code:l.content||" ",language:i||"python",syntaxTheme:r,className:"flex-1 px-3 text-github-text-primary whitespace-pre-wrap break-all overflow-wrap-break-word select-text [&_pre]:m-0 [&_pre]:p-0 [&_pre]:!bg-transparent [&_pre]:font-inherit [&_pre]:text-inherit [&_pre]:leading-inherit [&_code]:!bg-transparent [&_code]:font-inherit [&_code]:text-inherit [&_code]:leading-inherit"})]},`notebook-code-line-${o}`))})}),kj=({cells:e,syntaxTheme:r,language:i})=>y.jsx("div",{className:"space-y-4",children:e.map((l,o)=>{const u=wj(l),c=l.cellType==="code"&&l.executionCount!==void 0?`In[${l.executionCount??" "}]`:null,f=l.cellType==="code",h=f?yv(Ol(l.sourceLines,["context","delete"]),Ol(l.sourceLines,["context","add"])).filter(p=>p.type!=="context"):[];return f&&h.length===0?null:y.jsxs("div",{className:`rounded border border-github-border bg-github-bg-secondary/40 p-4 ${gj(l.status)}`,children:[y.jsx("div",{className:"flex flex-wrap items-center justify-between gap-2 mb-3",children:y.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y.jsx("span",{className:"text-xs font-semibold uppercase tracking-wide text-github-text-muted",children:pv[l.cellType]}),c&&y.jsx("span",{className:"text-xs font-mono text-github-text-secondary",children:c}),l.id&&y.jsx("span",{className:"text-xs font-mono text-github-text-muted",children:l.id})]})}),y.jsx("div",{className:"space-y-3",children:f?y.jsx("div",{className:`px-4 py-3 ${zx(l.status==="delete"?"before":"after")}`,children:y.jsx(Sj,{lines:h,syntaxTheme:r,language:i})}):u.map((p,g)=>y.jsx("div",{className:`px-4 py-3 ${zx(p.tone)}`,children:y.jsx("div",{className:"text-sm text-github-text-primary",children:xv(l.cellType,p.content,r,i)})},`notebook-cell-${o}-section-${g}`))})]},`notebook-cell-${o}`)})}),Ej=({cells:e,syntaxTheme:r,language:i})=>y.jsx("div",{className:"space-y-4",children:e.map((l,o)=>{const u=l.cellType==="code"&&l.executionCount!==void 0?`In[${l.executionCount??" "}]`:null;return y.jsxs("div",{className:"rounded border border-github-border bg-github-bg-secondary/40 p-4",children:[y.jsxs("div",{className:"flex flex-wrap items-center gap-2 mb-3",children:[y.jsx("span",{className:"text-xs font-semibold uppercase tracking-wide text-github-text-muted",children:pv[l.cellType]}),u&&y.jsx("span",{className:"text-xs font-mono text-github-text-secondary",children:u}),l.id&&y.jsx("span",{className:"text-xs font-mono text-github-text-muted",children:l.id})]}),y.jsx("div",{className:"text-sm text-github-text-primary",children:xv(l.cellType,l.sourceText,r,i)})]},`notebook-full-cell-${o}`)})});function Cj(e){const{file:r,baseCommitish:i,targetCommitish:l}=e,[o,u]=A.useState("diff"),c=A.useMemo(()=>uj(e.mergedChunks),[e.mergedChunks]),[f,h]=A.useState({status:"idle",cells:c.cells,language:c.language}),p=A.useMemo(()=>f.cells.filter(L=>L.status==="context"?!1:L.cellType!=="code"?!0:yv(Ol(L.sourceLines,["context","delete"]),Ol(L.sourceLines,["context","add"])).filter(Z=>Z.type!=="context").length>0),[f.cells]),[g,b]=A.useState(null),[v,x]=A.useState(c.language),[S,w]=A.useState(!1),[N,E]=A.useState(null),[C,j]=A.useState(null),z=A.useMemo(()=>!i&&!l?null:r.status==="added"?l?{path:r.path,ref:l}:null:r.status==="deleted"?i?{path:r.oldPath||r.path,ref:i}:null:l?{path:r.path,ref:l}:i?{path:r.oldPath||r.path,ref:i}:null,[i,l,r.oldPath,r.path,r.status]),I=A.useMemo(()=>z?`${z.ref}:${z.path}`:null,[z]);return A.useEffect(()=>{let L=!1;return(async()=>{const Z=i||"HEAD~1",$=l||"HEAD",F=r.oldPath||r.path,H=r.status!=="added"&&vd(Z),G=r.status!=="deleted"&&vd($);if(!H&&!G){h({status:"ready",cells:c.cells,language:c.language,source:"diff",message:"Notebook content could not be loaded, falling back to diff preview."});return}h(Q=>({...Q,status:"loading"}));try{const[Q,U]=await Promise.all([H?wd(F,Z):Promise.resolve(null),G?wd(r.path,$):Promise.resolve(null)]),Y=Q?qa(Q):null,B=U?qa(U):null;if(!Y&&!B){L||h({status:"ready",cells:c.cells,language:c.language,source:"diff",message:"Notebook content could not be parsed, falling back to diff preview."});return}const X=B?.language??Y?.language??c.language,M=bv(Y?.cells??[],B?.cells??[]);L||h({status:"ready",cells:M,source:"blob",language:X})}catch(Q){L||h({status:"error",cells:c.cells,language:c.language,source:"diff",message:Q instanceof Error?Q.message:"Failed to load notebook preview."})}})(),()=>{L=!0}},[i,r.oldPath,r.path,r.status,e.mergedChunks,l,c]),A.useEffect(()=>{if(o!=="full-preview")return;if(!z||!I||!vd(z.ref)){b(null),j(null),E(null),w(!1);return}let L=!1;return(I!==C||!g)&&(async()=>{I!==C&&b(null),w(!0),E(null);try{const Z=await wd(z.path,z.ref);if(!Z)throw new Error("Failed to load preview.");const $=qa(Z);if(!$)throw new Error("Notebook content could not be parsed.");L||(b($.cells),x($.language??c.language),j(I))}catch(Z){L||(b(null),j(null),E(Z instanceof Error?Z.message:"Failed to load preview"))}finally{L||w(!1)}})(),()=>{L=!0}},[c.language,g,C,o,z,I]),y.jsxs("div",{className:"bg-github-bg-primary",children:[y.jsx("div",{className:"flex items-center justify-between border-b border-github-border px-4 py-2",children:y.jsxs("div",{className:"flex items-center gap-1.5",children:[y.jsxs("button",{onClick:()=>u("diff"),className:`px-2 py-1 text-xs font-medium rounded transition-colors duration-200 flex items-center gap-1 cursor-pointer ${o==="diff"?"text-github-text-primary":"text-github-text-secondary hover:text-github-text-primary"}`,title:"Code Diff",children:[y.jsx(au,{size:14}),"Diff"]}),y.jsxs("button",{onClick:()=>u("diff-preview"),className:`px-2 py-1 text-xs font-medium rounded transition-colors duration-200 flex items-center gap-1 cursor-pointer ${o==="diff-preview"?"text-github-text-primary":"text-github-text-secondary hover:text-github-text-primary"}`,title:"Diff Preview",children:[y.jsx(zs,{size:14}),"Diff Preview"]}),y.jsxs("button",{onClick:()=>u("full-preview"),className:`px-2 py-1 text-xs font-medium rounded transition-colors duration-200 flex items-center gap-1 cursor-pointer ${o==="full-preview"?"text-github-text-primary":"text-github-text-secondary hover:text-github-text-primary"}`,title:"Full Preview",children:[y.jsx(zs,{size:14}),"Full Preview"]})]})}),o==="diff"&&y.jsx(nu,{...e}),o==="diff-preview"&&y.jsxs("div",{className:"p-4",children:[f.status==="loading"&&y.jsx("div",{className:"text-xs text-github-text-muted mb-3",children:"Loading notebook preview…"}),f.message&&y.jsx("div",{className:"text-xs text-github-text-muted mb-3",children:f.message}),p.length===0?y.jsxs("div",{children:[y.jsx("div",{className:"text-xs text-github-text-muted mb-3",children:"No changed notebook cells were found. Showing raw diff instead."}),y.jsx(nu,{...e})]}):y.jsx(kj,{cells:p,syntaxTheme:e.syntaxTheme,language:f.language})]}),o==="full-preview"&&y.jsxs("div",{className:"p-4",children:[S&&y.jsx("div",{className:"text-sm text-github-text-muted mb-3",children:"Loading preview..."}),N&&y.jsx("div",{className:"text-sm text-github-danger mb-3",children:N}),!S&&!N&&g&&y.jsx(Ej,{cells:g,syntaxTheme:e.syntaxTheme,language:v??c.language}),!S&&!N&&!g&&y.jsx("div",{className:"text-sm text-github-text-muted",children:"Preview unavailable."})]})]})}const kd=[{id:"image",match:e=>Z3(e.path),Component:e4,canExpandHiddenLines:()=>!1},{id:"markdown",match:e=>Q3(e.path),Component:tj,canExpandHiddenLines:e=>e.status!=="added"&&e.status!=="deleted"},{id:"notebook",match:e=>W3(e.path),Component:Cj,canExpandHiddenLines:e=>e.status!=="added"&&e.status!=="deleted"},{id:"default",match:()=>!0,Component:nu,canExpandHiddenLines:e=>e.status!=="added"&&e.status!=="deleted"}],Nj=e=>{const r=kd[kd.length-1];if(!r)throw new Error("No diff viewers registered");return kd.find(i=>i.match(e))??r},Aj=e=>{switch(e){case"added":return y.jsx(c1,{size:16,className:"text-github-accent"});case"deleted":return y.jsx(f1,{size:16,className:"text-github-danger"});case"renamed":return y.jsx(u1,{size:16,className:"text-github-warning"});default:return y.jsx(au,{size:16,className:"text-github-text-secondary"})}},Tj=({file:e,isCollapsed:r,isReviewed:i,onToggleCollapsed:l,onToggleAllCollapsed:o,onToggleReviewed:u})=>{const[c,f]=A.useState(!1);return y.jsxs("div",{className:"bg-github-bg-secondary border-t-2 border-t-github-accent border-b border-github-border px-5 py-4 flex items-center justify-between flex-wrap gap-3 sticky top-0 z-10",children:[y.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[y.jsx("button",{onClick:h=>{h.altKey?o(!r):l(e.path)},className:"text-github-text-muted hover:text-github-text-primary transition-colors cursor-pointer",title:r?"Expand file (Alt+Click to expand all)":"Collapse file (Alt+Click to collapse all)",children:r?y.jsx(o1,{size:16}):y.jsx(_l,{size:16})}),Aj(e.status),y.jsx("h2",{className:"text-sm font-mono text-github-text-primary m-0 overflow-hidden text-ellipsis whitespace-nowrap",children:e.path}),y.jsx("button",{className:`bg-transparent border-none cursor-pointer px-1.5 py-1 rounded text-sm transition-all hover:bg-github-bg-tertiary ${c?"text-github-accent":"text-github-text-secondary hover:text-github-text-primary"}`,onClick:()=>{navigator.clipboard.writeText(e.path).then(()=>{console.log("File path copied to clipboard:",e.path),f(!0),setTimeout(()=>f(!1),2e3)}).catch(h=>{console.error("Failed to copy file path:",h)})},title:"Copy file path",children:c?y.jsx(Pa,{size:14}):y.jsx(s1,{size:14})}),e.oldPath&&e.oldPath!==e.path&&y.jsxs("span",{className:"text-xs text-github-text-muted italic",children:["(renamed from ",e.oldPath,")"]})]}),y.jsxs("div",{className:"flex items-center gap-3",children:[y.jsxs("div",{className:"flex items-center gap-2 text-xs",children:[y.jsxs("span",{className:"font-medium px-1 py-0.5 rounded text-github-accent bg-green-100/10",children:["+",e.additions]}),y.jsxs("span",{className:"font-medium px-1 py-0.5 rounded text-github-danger bg-red-100/10",children:["-",e.deletions]})]}),y.jsxs("button",{onClick:()=>u(e.path),className:`flex items-center gap-2 px-3 py-1.5 rounded-md text-sm font-medium transition-all duration-200 ${i?"bg-github-accent text-white":"dark:bg-slate-600 dark:text-white dark:border-slate-500 dark:hover:bg-slate-500 dark:hover:border-slate-400 bg-github-bg-secondary text-github-text-primary border border-github-border hover:bg-github-bg-tertiary hover:border-github-text-muted"}`,title:i?"Mark as not reviewed":"Mark as reviewed",children:[i?y.jsx(Pa,{size:14}):y.jsx(xk,{size:14}),"Viewed"]})]})]})},jj=e=>{const r={old:[],new:[]};return e.forEach(i=>{const l=i.side??"new",[o,u]=Array.isArray(i.line)?[i.line[0],i.line[1]]:[i.line,i.line];o<=0||u<=0||r[l].push({start:Math.min(o,u),end:Math.max(o,u)})}),r},Rj=(e,r)=>e.chunks.map((i,l)=>{const o=r==="old"?i.oldStart:i.newStart,u=r==="old"?i.oldLines:i.newLines;return!o||u<=0?null:{start:o,end:o+u-1,index:l}}).filter(i=>!!i),_j=e=>{const r=[],i=e[0];if(!i)return r;i.start>1&&r.push({type:"before",start:1,end:i.start-1,nextChunkIndex:i.index});for(let o=1;o<e.length;o+=1){const u=e[o-1],c=e[o];!u||!c||c.start>u.end+1&&r.push({type:"between",start:u.end+1,end:c.start-1,prevChunkIndex:u.index,nextChunkIndex:c.index})}const l=e[e.length-1];return l&&r.push({type:"after",start:l.end+1,end:Number.POSITIVE_INFINITY,prevChunkIndex:l.index}),r},Lj=e=>{const r=new Map;return e.forEach(i=>{const l=i.originalIndices[0];l!==void 0&&r.set(l,i)}),r},Dj=e=>{const r=e[e.length-1];return r?.originalIndices[r.originalIndices.length-1]??null},Oj=A.memo(function({file:r,comments:i,diffMode:l,reviewedFiles:o,onToggleReviewed:u,collapsedFiles:c,onToggleCollapsed:f,onToggleAllCollapsed:h,onAddComment:p,onGeneratePrompt:g,onRemoveComment:b,onUpdateComment:v,onOpenInEditor:x,syntaxTheme:S,baseCommitish:w,targetCommitish:N,cursor:E=null,fileIndex:C=0,onLineClick:j,commentTrigger:z,onCommentTriggerHandled:I,mergedChunks:L,expandLines:O,expandAllBetweenChunks:Z,prefetchFileContent:$,isExpandLoading:F}){const H=c.has(r.path),G=A.useRef(null),[Q,U]=A.useState(!1),Y=Nj(r),B=Y.canExpandHiddenLines?.(r)??!1;A.useEffect(()=>{if(!B)return;const D=G.current;if(!D)return;const q=new IntersectionObserver(([T])=>{T?.isIntersecting&&U(!0)},{rootMargin:"200px"});return q.observe(D),()=>q.disconnect()},[B]),A.useEffect(()=>{Q&&!H&&B&&$(r)},[Q,H,B,r,$]);const X=A.useCallback(async(D,q,T,te)=>{try{await p(r.path,D,q,T,te)}catch(ie){console.error("Failed to add comment:",ie)}},[r.path,p]);A.useEffect(()=>{if(H||F||!B||i.length===0||r.chunks.length===0||L.length===0)return;const D=jj(i),q=Lj(L),T=Dj(L),te=L[L.length-1],ie=new Set,fe=(ge,ye)=>{ie.has(ge)||(ie.add(ge),ye())};["old","new"].forEach(ge=>{const ye=D[ge];if(ye.length===0)return;const pe=Rj(r,ge);_j(pe).forEach(xe=>{if(!ye.some(Pe=>Pe.start<=xe.end&&Pe.end>=xe.start))return;if(xe.type==="after"&&te&&T!==null){te.hiddenLinesAfter>0&&fe(`after-${T}`,()=>{O(r,T,"down",te.hiddenLinesAfter)});return}const we=xe.nextChunkIndex;if(we===void 0)return;const Ee=q.get(we);!Ee||Ee.hiddenLinesBefore<=0||(xe.type==="before"?fe(`before-${we}`,()=>{O(r,we,"up",Ee.hiddenLinesBefore)}):xe.type==="between"&&fe(`between-${we}`,()=>{Z(r,we,Ee.hiddenLinesBefore)}))})})},[i,Z,O,r,H,F,L,B]);const M="4em",V=Y.Component,R={file:r,comments:i,diffMode:l,syntaxTheme:S,baseCommitish:w,targetCommitish:N,cursor:E,fileIndex:C,mergedChunks:L,isExpandLoading:F,expandHiddenLines:O,expandAllBetweenChunks:Z,onAddComment:X,onGeneratePrompt:g,onRemoveComment:b,onUpdateComment:v,onOpenInEditor:x,onLineClick:j,commentTrigger:z,onCommentTriggerHandled:I};return y.jsxs("div",{ref:G,className:"bg-github-bg-primary",style:{"--line-number-width":M},children:[y.jsx(Tj,{file:r,isCollapsed:H,isReviewed:o.has(r.path),onToggleCollapsed:f,onToggleAllCollapsed:h,onToggleReviewed:u}),!H&&y.jsx("div",{className:"overflow-y-auto",children:y.jsx(V,{...R})})]})});function ch(e){if(!e.isDirectory||!e.children)return[];const r=[];return e.path&&r.push(e.path),e.children.forEach(i=>{r.push(...ch(i))}),r}function Mj(e){const r={name:"",path:"",isDirectory:!0,children:[]};e.forEach(l=>{const o=l.path.split("/");let u=r;for(let c=0;c<o.length;c++){const f=o[c];if(!f)continue;const h=c===o.length-1,p=o.slice(0,c+1).join("/");u.children||(u.children=[]);let g=u.children.find(b=>b.name===f);g||(g={name:f,path:p,isDirectory:!h,children:h?void 0:[],file:h?l:void 0},u.children.push(g)),u=g}});const i=l=>{if(!l.isDirectory||!l.children)return l;if(l.children=l.children.map(i),l.children.length===1&&l.children[0]?.isDirectory&&l.children[0]?.children){const o=l.children[0];if(o)return l.name?{...l,name:`${l.name}/${o.name}`,path:o.path,children:o.children}:l}return l};return i(r)}function zj({files:e,onScrollToFile:r,onFileSelected:i,comments:l,reviewedFiles:o,onToggleReviewed:u,selectedFileIndex:c}){const f=A.useMemo(()=>Mj(e),[e]),h=A.useRef(null),p=A.useRef(new Map),g={"--dir-row-height":"calc(var(--spacing, 0.25rem) * 9)"},[b,v]=A.useState(()=>new Set(ch(f))),[x,S]=A.useState(""),w=A.useMemo(()=>{const $=new Map;return l.forEach(F=>{$.set(F.file,($.get(F.file)??0)+1)}),$},[l]),N=A.useMemo(()=>{const $=new Map;return e.forEach((F,H)=>{$.set(F.path,H)}),$},[e]),E=A.useMemo(()=>{const $=x.trim().toLowerCase(),F=H=>{if(!$)return H;if(H.isDirectory&&H.children){const G=H.children.map(Q=>F(Q)).filter(Q=>Q!==null);return G.length>0?{...H,children:G}:null}else if(H.file)return H.file.path.toLowerCase().includes($)?H:null;return null};return F(f)||{...f,children:[]}},[f,x]),C=$=>{switch($){case"added":return y.jsx(c1,{size:16,className:"text-github-accent"});case"deleted":return y.jsx(f1,{size:16,className:"text-github-danger"});case"renamed":return y.jsx(u1,{size:16,className:"text-github-warning"});default:return y.jsx(au,{size:16,className:"text-github-text-secondary"})}},j=$=>{v(F=>{const H=new Set(F);return H.has($)?H.delete($):H.add($),H})},z=A.useMemo(()=>ch(f),[f]),I=b.size===z.length&&z.length>0,L=()=>{v(I?new Set:new Set(z))},O=($,F)=>{const H=h.current,G=$.currentTarget;if(!H){j(F);return}const Q=H.getBoundingClientRect(),U=G.getBoundingClientRect(),Y=Number.parseFloat(getComputedStyle(G).top||"0");if(U.top-Q.top<=Y+1){const V=p.current.get(F)?.querySelector('[data-tree-row="true"]:not([data-dir-header="true"])'),R=G.getBoundingClientRect().height||0,D=V??G,q=Number.parseInt(D.dataset.depth||G.dataset.depth||"0",10),T=R*q,te=Math.max(0,D.offsetTop-T);if(Math.abs(H.scrollTop-te)<=1){j(F);return}H.scrollTo({top:te,behavior:"smooth"});return}j(F)},Z=($,F=0)=>{if($.isDirectory&&$.children){const H=b.has($.path);return y.jsxs("div",{"data-dir-container":$.path||void 0,ref:G=>{$.path&&(G?p.current.set($.path,G):p.current.delete($.path))},children:[$.name&&y.jsxs("div",{className:"sticky flex h-9 items-center gap-2 bg-github-bg-secondary px-4 hover:bg-github-bg-tertiary cursor-pointer","data-dir-header":"true","data-tree-row":"true","data-depth":F,style:{paddingLeft:`${F*16+16}px`,top:`calc(${F} * var(--dir-row-height))`,zIndex:1e3-F},onClick:G=>O(G,$.path),children:[H?y.jsx(_l,{size:16}):y.jsx(o1,{size:16}),H?y.jsx(Z2,{size:16,className:"text-github-text-secondary"}):y.jsx(Q2,{size:16,className:"text-github-text-secondary"}),y.jsx("span",{className:"text-sm text-github-text-primary font-medium flex-1 overflow-hidden text-ellipsis whitespace-nowrap",title:$.name,children:$.name})]}),(H||!$.name)&&$.children.map(G=>Z(G,$.name?F+1:F))]},$.path)}else if($.file){const H=$.file,G=w.get(H.path)??0,Q=o.has(H.path),U=N.get(H.path)??-1,Y=c!==null&&c===U;return y.jsxs("div",{className:`flex items-center gap-2 px-4 py-2 hover:bg-github-bg-tertiary cursor-pointer transition-colors ${Q?"opacity-70":""} ${Y?"bg-github-bg-tertiary":""}`,"data-file-row":"true","data-tree-row":"true","data-depth":F,style:{paddingLeft:`${F*16+16}px`},onClick:()=>{r(H.path),i?.()},children:[y.jsx(p1,{checked:Q,onChange:()=>{u(H.path)},title:Q?"Mark as not reviewed":"Mark as reviewed",className:"z-10"}),C($.file.status),y.jsx("span",{className:`text-sm text-github-text-primary flex-1 overflow-hidden text-ellipsis whitespace-nowrap ${Q?"line-through text-github-text-muted":""}`,title:$.file.path,children:$.name}),G>0&&y.jsxs("span",{className:"text-github-warning text-sm font-medium ml-auto flex items-center gap-1",children:[y.jsx(d1,{size:14}),G]})]},H.path)}return null};return y.jsxs("div",{className:"h-full flex flex-col",children:[y.jsxs("div",{className:"px-4 py-3 border-b border-github-border bg-github-bg-tertiary",children:[y.jsxs("div",{className:"flex items-center justify-between mb-3",children:[y.jsxs("h3",{className:"text-sm font-semibold text-github-text-primary m-0",children:["Files changed (",e.length,")"]}),y.jsx("button",{onClick:L,className:"p-1 hover:bg-github-bg-primary rounded transition-colors",title:I?"Collapse all":"Expand all",children:I?y.jsx(_2,{size:16,className:"text-github-text-secondary"}):y.jsx(D2,{size:16,className:"text-github-text-secondary"})})]}),y.jsxs("div",{className:"relative",children:[y.jsx(gk,{size:16,className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-github-text-muted"}),y.jsx("input",{type:"text",placeholder:"Filter files...",value:x,onChange:$=>S($.target.value),className:"w-full pl-9 pr-3 py-2 text-sm bg-github-bg-primary border border-github-border rounded-md focus:outline-none focus:border-github-accent text-github-text-primary placeholder-github-text-muted"})]})]}),y.jsx("div",{className:"flex-1 overflow-y-auto relative z-0",style:g,ref:h,children:E.children?.map($=>Z($))})]})}function Fj({style:e}){return y.jsx("svg",{width:"98",height:"96",viewBox:"0, 0, 98, 96",style:e,xmlns:"http://www.w3.org/2000/svg","aria-label":"GitHub",role:"img",children:y.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M48.854 0C21.839 0 0 22 0 49.217c0 21.756 13.993 40.172 33.405 46.69 2.427.49 3.316-1.059 3.316-2.362 0-1.141-.08-5.052-.08-9.127-13.59 2.934-16.42-5.867-16.42-5.867-2.184-5.704-5.42-7.17-5.42-7.17-4.448-3.015.324-3.015.324-3.015 4.934.326 7.523 5.052 7.523 5.052 4.367 7.496 11.404 5.378 14.235 4.074.404-3.178 1.699-5.378 3.074-6.6-10.839-1.141-22.243-5.378-22.243-24.283 0-5.378 1.94-9.778 5.014-13.2-.485-1.222-2.184-6.275.486-13.038 0 0 4.125-1.304 13.426 5.052a46.97 46.97 0 0 1 12.214-1.63c4.125 0 8.33.571 12.213 1.63 9.302-6.356 13.427-5.052 13.427-5.052 2.67 6.763.97 11.816.485 13.038 3.155 3.422 5.015 7.822 5.015 13.2 0 18.905-11.404 23.06-22.324 24.283 1.78 1.548 3.316 4.481 3.316 9.126 0 6.6-.08 11.897-.08 13.526 0 1.304.89 2.853 3.316 2.364 19.412-6.52 33.405-24.935 33.405-46.691C97.707 22 75.788 0 48.854 0z",fill:"currentColor"})})}function Bj({isOpen:e,onClose:r}){const{enableScope:i,disableScope:l}=Za();return lt("escape",()=>r(),{enabled:e},[r,e]),A.useEffect(()=>(e?l("navigation"):i("navigation"),()=>{i("navigation")}),[e,i,l]),e?y.jsxs("div",{className:"fixed inset-0 z-50 flex items-center justify-center",children:[y.jsx("div",{className:"absolute inset-0 bg-black/50",onClick:r}),y.jsxs("div",{className:"relative bg-github-bg-primary border border-github-border rounded-lg shadow-lg max-w-4xl w-full mx-4 max-h-[80vh] overflow-y-auto",children:[y.jsxs("div",{className:"sticky top-0 bg-github-bg-primary border-b border-github-border px-6 py-4 flex items-center justify-between",children:[y.jsx("h2",{className:"text-lg font-semibold text-github-text-primary",children:"Keyboard Shortcuts"}),y.jsx("button",{onClick:r,className:"text-github-text-secondary hover:text-github-text-primary transition-colors","aria-label":"Close help modal",children:y.jsx(ou,{size:20})})]}),y.jsxs("div",{className:"px-6 py-4 grid grid-cols-1 lg:grid-cols-2 gap-6",children:[y.jsxs("section",{children:[y.jsx("h3",{className:"text-sm font-semibold text-github-text-primary mb-2",children:"Line Navigation"}),y.jsxs("div",{className:"space-y-1",children:[y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"j"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"↓"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Next line"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"k"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"↑"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Previous line"})]})]})]}),y.jsxs("section",{children:[y.jsx("h3",{className:"text-sm font-semibold text-github-text-primary mb-2",children:"File Navigation"}),y.jsxs("div",{className:"space-y-1",children:[y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"]"}),y.jsx("span",{className:"text-github-text-secondary",children:"Next file"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"["}),y.jsx("span",{className:"text-github-text-secondary",children:"Previous file"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex items-center gap-1",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"Shift"}),y.jsx("span",{className:"text-github-text-muted",children:"+"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"["})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Jump to first file"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex items-center gap-1",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"Shift"}),y.jsx("span",{className:"text-github-text-muted",children:"+"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"]"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Jump to last file"})]})]})]}),y.jsxs("section",{children:[y.jsx("h3",{className:"text-sm font-semibold text-github-text-primary mb-2",children:"Chunk Navigation"}),y.jsxs("div",{className:"space-y-1",children:[y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"n"}),y.jsx("span",{className:"text-github-text-secondary",children:"Next change chunk (added/deleted lines)"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"p"}),y.jsx("span",{className:"text-github-text-secondary",children:"Previous change chunk (added/deleted lines)"})]})]})]}),y.jsxs("section",{children:[y.jsx("h3",{className:"text-sm font-semibold text-github-text-primary mb-2",children:"Comment Navigation"}),y.jsxs("div",{className:"space-y-1",children:[y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"N"}),y.jsx("span",{className:"text-github-text-secondary",children:"Next comment"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"P"}),y.jsx("span",{className:"text-github-text-secondary",children:"Previous comment"})]})]})]}),y.jsxs("section",{children:[y.jsx("h3",{className:"text-sm font-semibold text-github-text-primary mb-2",children:"Side Navigation (Side-by-side mode)"}),y.jsxs("div",{className:"space-y-1",children:[y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"h"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"←"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Focus left side"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"l"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"→"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Focus right side"})]})]})]}),y.jsxs("section",{children:[y.jsx("h3",{className:"text-sm font-semibold text-github-text-primary mb-2",children:"Comment Management"}),y.jsxs("div",{className:"space-y-1",children:[y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex items-center gap-1",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"Shift"}),y.jsx("span",{className:"text-github-text-muted",children:"+"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"L"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"View all comments list"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex items-center gap-1",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"Shift"}),y.jsx("span",{className:"text-github-text-muted",children:"+"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"C"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Copy all comments prompt"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex items-center gap-1",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"Shift"}),y.jsx("span",{className:"text-github-text-muted",children:"+"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"D"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Delete all comments"})]})]})]}),y.jsxs("section",{children:[y.jsx("h3",{className:"text-sm font-semibold text-github-text-primary mb-2",children:"Actions"}),y.jsxs("div",{className:"space-y-1",children:[y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"v"}),y.jsx("span",{className:"text-github-text-secondary",children:"Toggle viewed state of current file"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsxs("div",{className:"flex items-center gap-1",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"Shift"}),y.jsx("span",{className:"text-github-text-muted",children:"+"}),y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"R"})]}),y.jsx("span",{className:"text-github-text-secondary",children:"Refresh diff when changes detected"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"c"}),y.jsx("span",{className:"text-github-text-secondary",children:"Add comment at current line"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"."}),y.jsx("span",{className:"text-github-text-secondary",children:"Move cursor to center of viewport"})]}),y.jsxs("div",{className:"flex justify-between text-sm",children:[y.jsx("kbd",{className:"px-2 py-1 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary font-mono",children:"?"}),y.jsx("span",{className:"text-github-text-secondary",children:"Show/hide this help"})]})]})]}),y.jsx("div",{className:"pt-4 border-t border-github-border lg:col-span-2",children:y.jsx("p",{className:"text-xs text-github-text-secondary",children:"Shortcuts are disabled when typing in input fields."})})]})]})]}):null}function Ij({style:e}){return y.jsxs("svg",{style:e,viewBox:"0 0 720 190",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-label":"difit",role:"img",children:[y.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M440.487 5.90627C432.164 9.01695 427.318 16.2817 427.318 25.649C427.318 35.9474 433.206 43.6458 442.714 45.7819C451.336 47.7188 459.606 44.3893 464.84 36.8737C466.923 33.8843 467.35 32.4073 467.606 27.3105C467.773 23.9957 467.492 20.0154 466.983 18.4654C465.699 14.5629 460.869 9.13088 456.854 7.07513C452.57 4.88086 444.73 4.32102 440.487 5.90627ZM596.658 6.653C588.927 9.55794 584.572 15.4908 583.887 24.0465C583.17 33.0212 586.83 39.8868 594.382 43.7278C603.739 48.4877 615.574 44.5081 620.482 34.9515C625.35 25.4728 622.15 13.4916 613.37 8.32678C608.986 5.74808 601.154 4.96365 596.658 6.653ZM368.585 7.68006C367.464 8.80629 367.302 12.903 367.302 40.2286V71.4878L363.832 68.1329C353.432 58.0787 335.595 52.668 319.246 54.6082C310.542 55.641 299.81 59.1369 293.3 63.0607C278.56 71.9427 266.453 89.5576 263.139 106.945C261.765 114.155 261.602 129.431 262.825 136.365C265.723 152.796 274.795 168.36 286.716 177.355C298.275 186.077 310.237 190 325.274 190C340.687 190 353.943 185.273 362.869 176.594L367.302 172.284V178.215C367.302 186.902 366.946 186.724 384.303 186.709C392.243 186.702 399.29 186.347 399.964 185.919C401.04 185.236 401.189 174.47 401.189 97.1224C401.189 23.7236 401.003 8.87842 400.068 7.74809C398.433 5.77021 370.547 5.71037 368.585 7.68006ZM526.937 7.94153C519.783 10.0325 515.359 12.5834 510.029 17.6867C501.959 25.4129 498.766 34.4597 498.766 49.5975V58.8517H490.659C484.378 58.8517 482.263 59.1418 481.268 60.1394C480.214 61.1976 479.986 63.6558 479.986 73.91C479.986 82.5264 480.289 86.6977 480.966 87.3764C481.601 88.0141 484.903 88.36 490.356 88.36H498.766V136.692C498.766 183.638 498.811 185.048 500.345 185.873C502.433 186.994 529.394 186.994 531.482 185.873C533.016 185.048 533.061 183.638 533.061 136.692V88.36H549.334C563.038 88.36 565.809 88.1568 566.89 87.0723C568.782 85.1723 568.782 62.0394 566.89 60.1394C565.808 59.0541 563.029 58.8517 549.231 58.8517H532.856L533.216 51.9721C533.604 44.5499 534.721 41.9147 538.546 39.3958C540.377 38.1901 543.049 37.904 554.661 37.6737C562.626 37.5155 569.018 37.0343 569.602 36.5483C570.892 35.4761 571.046 10.3579 569.777 7.9776C568.978 6.47923 567.918 6.39562 550.384 6.45054C535.269 6.49808 530.93 6.77431 526.937 7.94153ZM654.931 26.4834C653.136 27.7662 653.094 28.1572 653.094 43.3245V58.8517H644.567C633.342 58.8517 633.497 58.6443 633.497 73.6059C633.497 88.5674 633.342 88.36 644.567 88.36H653.094V122.636C653.094 159.998 653.439 163.935 657.362 171.354C661.848 179.838 669.111 184.99 680.857 188.022C687.996 189.866 707.647 189.269 714.309 187.007C719.756 185.158 719.86 184.87 719.969 171.298C720.082 157.364 720.441 157.791 709.174 158.48C695.386 159.324 689.341 156.938 687.388 149.883C686.927 148.214 686.58 134.435 686.577 117.663L686.572 88.36H702.068H717.564L718.87 86.3592C719.946 84.7108 720.129 82.3461 719.91 72.9575C719.719 64.8279 719.321 61.1689 718.522 60.2041C717.553 59.0345 715.315 58.8517 701.987 58.8517H686.572L686.546 43.8926C686.526 31.8556 686.28 28.613 685.288 27.2941C684.156 25.7884 682.945 25.6351 670.412 25.4129C658.94 25.2088 656.476 25.3793 654.931 26.4834ZM431.459 60.1394C430.316 61.2877 430.178 68.0001 430.188 121.82C430.197 168.838 430.429 182.667 431.232 184.262L432.264 186.311L446.657 186.535C458.941 186.725 461.242 186.567 462.353 185.452C463.521 184.279 463.655 177.845 463.655 122.786C463.655 68.0985 463.515 61.2877 462.372 60.1394C460.469 58.2287 433.362 58.2287 431.459 60.1394ZM587.799 60.4369C587.238 61.4894 586.954 82.56 586.954 123.084C586.954 177.502 587.093 184.285 588.236 185.434C590.138 187.342 616.431 187.342 618.333 185.434C619.476 184.285 619.615 177.447 619.615 122.482C619.615 75.6149 619.38 60.5828 618.636 59.8353C617.947 59.1443 613.344 58.8517 603.15 58.8517C589.644 58.8517 588.586 58.9607 587.799 60.4369ZM347.956 87.3469C362.023 93.9543 369.138 107.306 367.775 124.535C366.623 139.097 359.678 149.866 347.83 155.463C337.073 160.544 325.541 160.523 315.049 155.403C293.381 144.83 288.765 112.315 306.417 94.5961C313.92 87.0641 322.021 84.1412 334.301 84.5354C341.49 84.7666 343.224 85.124 347.956 87.3469Z",fill:"currentColor"}),y.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9.42299 0.744751C4.61699 2.15275 2.03999 5.66375 0.956994 12.2768C-0.369006 20.3728 -0.294006 170.791 1.03899 176.572C2.29699 182.031 4.81699 185.308 9.65399 187.774C13.265 189.615 16.865 189.684 108.63 189.684C163.129 189.684 204.095 189.304 204.41 188.795C206 188.5 206 188.795 207.5 188C211.167 187.079 216.779 180.138 218.005 175.584C218.682 173.068 218.939 143.952 218.756 90.4718C218.487 11.7478 218.417 9.10275 216.535 6.62675C215.466 5.22075 213.441 3.19575 212.035 2.12675C209.546 0.23575 206.839 0.17975 110.978 0.0167504C55.373 -0.0782496 11.148 0.239751 9.42299 0.744751ZM203.778 14.8838C205.558 16.6638 205.509 172.577 203.728 175.005C202.577 176.574 198.865 176.688 156.978 176.446L111.478 176.184L111.226 138.684L110.974 101.184H84.059C69.255 101.184 56.808 101.52 56.397 101.931C55.986 102.343 60.674 107.82 66.814 114.104C72.954 120.388 77.978 126.202 77.978 127.026C77.978 129.577 74.769 134.267 71.896 135.916C69.609 137.229 68.75 137.278 66.704 136.217C63.533 134.572 28.705 99.1448 27.757 96.5998C27.36 95.5348 27.491 93.4308 28.049 91.9238C28.955 89.4768 68.498 49.6838 70.024 49.6838C70.366 49.6838 72.356 51.1627 74.447 52.9697C77.589 55.6867 78.118 56.6658 77.498 58.6198C77.086 59.9198 72.075 65.8308 66.363 71.7568C60.651 77.6818 55.978 83.0148 55.978 83.6068C55.978 84.3488 64.068 84.6838 81.952 84.6838H107.927H110.666C111.144 82.5 110.978 73.4537 110.978 46.2337V13.6838H156.778C191.067 13.6838 202.88 13.9858 203.778 14.8838ZM148.803 52.7217C146.51 54.0597 144.845 59.5997 145.74 62.9107C146.146 64.4107 150.657 69.9308 155.764 75.1788C161.411 80.9788 164.547 84.8988 163.764 85.1788C163.057 85.4318 151.549 85.7608 138.19 85.9108C117.896 86.1388 113.747 86.4308 112.956 87.6838C112.435 88.5088 112.002 91.7228 111.993 94.8268C111.982 99.0598 112.373 100.622 113.56 101.077C114.43 101.411 126.13 101.684 139.56 101.684C156.121 101.684 163.978 102.026 163.978 102.746C163.978 103.33 160.187 107.607 155.554 112.251C146.244 121.582 144.276 125.371 146.069 130.514C147.321 134.107 149.576 135.684 153.463 135.684C155.522 135.684 159.843 131.902 173.778 117.904C191.699 99.9008 194.978 96.0678 194.978 93.1208C194.978 91.1338 157.422 53.8238 154.163 52.5728C151.322 51.4818 150.908 51.4937 148.803 52.7217Z",fill:"currentColor"})]})}function Uj({shouldReload:e,isReloading:r,onReload:i,changeType:l,className:o="",compact:u=!1}){if(!e)return null;const c=()=>{switch(l){case"commit":return"New commits available";case"staging":return"Staging changes detected";case"file":return"File changes detected";default:return"Changes detected"}};return y.jsxs("button",{onClick:i,disabled:r,className:`
|
|
70
|
+
flex items-center gap-1.5 text-xs rounded-md border ${o} ${u?"px-2 py-2":"px-3 py-1.5"}
|
|
71
|
+
${r?"bg-github-text-primary text-github-bg-primary border-github-text-primary cursor-not-allowed":"bg-github-text-primary text-github-bg-primary border-github-text-primary"}
|
|
72
|
+
`,title:`${c()} - Click to refresh`,"aria-label":u?"Refresh":void 0,children:[y.jsx(pk,{size:12,className:`${r?"animate-spin":""}`}),u?y.jsx("span",{className:"sr-only",children:"Refresh"}):"Refresh"]})}function Fx({label:e,value:r,resolvedValue:i,onChange:l,options:o,disabledValues:u=[]}){const[c,f]=A.useState(!1),{refs:h,floatingStyles:p,context:g}=$d({open:c,onOpenChange:f,middleware:[zd(4),Bd(),Fd({padding:8})],whileElementsMounted:Md}),b=Id(g,{handleClose:Gd()}),v=Hd(g),x=H3(g),S=qd(g),w=Vd(g),{getReferenceProps:N,getFloatingProps:E}=Pd([b,v,x,S,w]),C=r==="working"&&u.includes("staged")||r==="staged"&&u.includes("working"),j=()=>{const $=o.specialOptions.find(G=>G.value===r);if($)return $.label;const F=o.branches.find(G=>G.name===r);if(F)return`${F.name}${F.current?" (current)":""}`;const H=o.commits.find(G=>G.shortHash===r||G.hash===r);return H?`${H.shortHash} - ${H.message}`:r||"Select..."},z=$=>{l($),f(!1)},I=$=>u.includes($),L=($,F)=>["w-full text-left px-3 py-2 text-xs focus:outline-none transition-colors",$?"hover:bg-diff-selected-bg focus:bg-diff-selected-bg":"hover:bg-github-bg-tertiary focus:bg-github-bg-tertiary",$?"bg-diff-selected-bg border-l-4 border-l-diff-selected-border font-semibold pl-2":"",F?"opacity-50 cursor-not-allowed":"cursor-pointer"].join(" "),O=($,F)=>$===r||F===r?!0:i?$===i||F===i:!1,Z=()=>{let $=0;const F=o.specialOptions.findIndex(H=>H.value===r);if(F!==-1)return F;if($+=o.specialOptions.length,!C){const H=o.commits.findIndex(Q=>Q.shortHash===r);if(H!==-1)return $+H;$+=o.commits.length;const G=o.branches.findIndex(Q=>Q.name===r);if(G!==-1)return $+G}return 0};return y.jsxs(y.Fragment,{children:[y.jsxs("button",{ref:h.setReference,type:"button",className:"flex items-center gap-1.5 cursor-pointer group","aria-haspopup":"listbox","aria-expanded":c,...N(),children:[y.jsxs("span",{className:"text-xs text-github-text-secondary",children:[e,":"]}),y.jsxs("div",{className:"flex items-center gap-1 px-2 py-1 bg-github-bg-tertiary border border-github-border rounded hover:border-github-text-secondary transition-colors",children:[y.jsx("code",{className:"text-xs text-github-text-primary max-w-[150px] truncate",children:j()}),y.jsx(_l,{size:12,className:"text-github-text-secondary group-hover:text-github-text-primary transition-colors"})]})]}),c&&y.jsx(Ud,{children:y.jsx(z3,{context:g,modal:!1,initialFocus:Z(),children:y.jsxs("div",{ref:h.setFloating,style:p,className:"bg-github-bg-secondary border border-github-border rounded shadow-lg z-50 w-[360px] max-h-[400px] overflow-y-auto",...E(),children:[o.specialOptions.length>0&&y.jsxs("div",{className:"border-b border-github-border",children:[y.jsx("div",{className:"px-3 py-2 text-xs font-semibold text-github-text-secondary bg-github-bg-tertiary",children:"Special"}),o.specialOptions.map($=>y.jsx("button",{onClick:()=>z($.value),disabled:I($.value),className:L($.value===r,I($.value)),children:$.label},$.value))]}),!C&&o.commits.length>0&&y.jsxs("div",{className:"border-b border-github-border",children:[y.jsx("div",{className:"px-3 py-2 text-xs font-semibold text-github-text-secondary bg-github-bg-tertiary",children:"Recent Commits"}),o.commits.map($=>y.jsx("button",{onClick:()=>z($.shortHash),disabled:I($.shortHash),className:L(O($.shortHash,$.hash),I($.shortHash)),children:y.jsxs("div",{className:"flex items-start gap-2",children:[y.jsx("code",{className:"text-xs text-github-text-primary font-mono whitespace-nowrap",children:$.shortHash}),y.jsx("span",{className:"text-xs text-github-text-secondary flex-1 break-words",children:$.message})]})},$.hash))]}),!C&&o.branches.length>0&&y.jsxs("div",{children:[y.jsx("div",{className:"px-3 py-2 text-xs font-semibold text-github-text-secondary bg-github-bg-tertiary",children:"Branches"}),o.branches.map($=>y.jsx("button",{onClick:()=>z($.name),disabled:I($.name),className:L($.name===r,I($.name)),children:y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("span",{className:"text-github-text-primary",children:$.name}),$.current&&y.jsx("span",{className:"text-xs text-github-text-muted",children:"(current)"})]})},$.name))]})]})})})]})}function Hj({isOpen:e,onClose:r,options:i,baseRevision:l,targetRevision:o,resolvedBaseRevision:u,resolvedTargetRevision:c,onApply:f}){const[h,p]=A.useState(l),[g,b]=A.useState(o),{enableScope:v,disableScope:x}=Za();A.useEffect(()=>(e?x("navigation"):v("navigation"),()=>{v("navigation")}),[e,v,x]);const S=A.useMemo(()=>{const E=c||g,C=i.commits.findIndex(z=>z.shortHash===E||z.hash===E);if(C===-1)return g?[g]:[];const j=i.commits.slice(0,C+1).map(z=>z.shortHash);return g&&!j.includes(g)&&j.push(g),j.includes("working")||j.push("working"),j},[g,c,i.commits]),w=A.useMemo(()=>{const E=u||h,C=i.commits.findIndex(z=>z.shortHash===E||z.hash===E);if(C===-1)return h?[h]:[];const j=i.commits.slice(C).map(z=>z.shortHash);return h&&!j.includes(h)&&j.push(h),j},[h,u,i.commits]);if(!e)return null;const N=()=>{f(h,g),r()};return y.jsxs("div",{className:"fixed inset-0 z-50 flex items-center justify-center",children:[y.jsx("div",{className:"absolute inset-0 bg-black/40",onClick:r}),y.jsxs("div",{className:"relative bg-github-bg-secondary border border-github-border rounded-lg shadow-lg w-full max-w-lg mx-4",children:[y.jsxs("div",{className:"flex items-center justify-between p-4 border-b border-github-border",children:[y.jsx("h2",{className:"text-lg font-semibold text-github-text-primary",children:"Detailed Diff"}),y.jsx("button",{onClick:r,className:"text-github-text-secondary hover:text-github-text-primary p-1","aria-label":"Close detailed diff",children:y.jsx(ou,{size:18})})]}),y.jsxs("div",{className:"p-4 space-y-4",children:[y.jsxs("div",{className:"flex items-center justify-center gap-3",children:[y.jsx(Fx,{label:"Base",value:h,resolvedValue:u,onChange:p,options:i,disabledValues:S}),y.jsx("span",{className:"text-github-text-muted",children:"..."}),y.jsx(Fx,{label:"Target",value:g,resolvedValue:c,onChange:b,options:i,disabledValues:w})]}),y.jsxs("div",{className:"flex justify-end gap-2",children:[y.jsx("button",{onClick:r,className:"px-3 py-1.5 text-xs font-medium rounded border border-github-border text-github-text-secondary hover:text-github-text-primary transition-colors",type:"button",children:"Cancel"}),y.jsx("button",{onClick:N,className:"px-3 py-1.5 text-xs font-medium rounded bg-github-accent text-white hover:bg-github-accent/90 transition-colors",type:"button",children:"Apply"})]})]})]})]})}const qj=[{id:"vscode",label:"VS Code",protocol:"vscode",cliCommand:"code",cliArgs:[],lineFormat:"goto-flag",aliases:["vscode","code"]},{id:"cursor",label:"Cursor",protocol:"cursor",cliCommand:"cursor",cliArgs:[],lineFormat:"goto-flag",aliases:["cursor"]},{id:"zed",label:"Zed",protocol:"zed",cliCommand:"zed",cliArgs:[],lineFormat:"path-suffix",aliases:["zed"]},{id:"none",label:"Hide “Open in editor” button",protocol:null,cliCommand:null,cliArgs:[],lineFormat:"goto-flag",aliases:["none","disabled","off"]}],vv="vscode",Bx=[{id:"github",label:"GitHub Light"},{id:"vsLight",label:"VS Light"},{id:"oneLight",label:"One Light"},{id:"gruvboxMaterialLight",label:"Gruvbox Material Light"},{id:"nightOwlLight",label:"Night Owl Light"}],Ix=[{id:"vsDark",label:"VS Dark"},{id:"oneDark",label:"One Dark"},{id:"gruvboxMaterialDark",label:"Gruvbox Material Dark"},{id:"nightOwl",label:"Night Owl"},{id:"dracula",label:"Dracula"},{id:"okaidia",label:"Okaidia"}],$j={fontSize:14,fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif',theme:"dark",syntaxTheme:"vsDark",editor:vv},Pj=[{name:"System Font",value:'-apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif'},{name:"Menlo",value:'Menlo, Monaco, "Courier New", monospace'},{name:"SF Mono",value:'SF Mono, Consolas, "Liberation Mono", monospace'},{name:"Fira Code",value:'"Fira Code", "Courier New", monospace'},{name:"JetBrains Mono",value:'"JetBrains Mono", "Courier New", monospace'}];function Vj({isOpen:e,onClose:r,settings:i,onSettingsChange:l}){const[o,u]=A.useState(i),{enableScope:c,disableScope:f}=Za();A.useEffect(()=>{u(i)},[i]),A.useEffect(()=>{l(o)},[o,l]),A.useEffect(()=>(e?f("navigation"):c("navigation"),()=>{c("navigation")}),[e,c,f]);const h=()=>o.theme==="auto"?window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":o.theme,p=()=>h()==="light"?Bx:Ix,g=v=>{const x={...o,theme:v},w=(v==="auto"?window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":v)==="light"?Bx:Ix;if(!w.some(E=>E.id===o.syntaxTheme)&&w.length>0){const E=w[0];E&&(x.syntaxTheme=E.id)}u(x)},b=()=>{u($j)};return e?y.jsx("div",{className:"fixed inset-0 flex items-center justify-center z-50 pointer-events-none",children:y.jsxs("div",{className:"bg-github-bg-secondary border border-github-border rounded-lg w-full max-w-md mx-4 pointer-events-auto",children:[y.jsxs("div",{className:"flex items-center justify-between p-4 border-b border-github-border",children:[y.jsxs("h2",{className:"text-lg font-semibold text-github-text-primary flex items-center gap-2",children:[y.jsx(h1,{size:20}),"Appearance Settings"]}),y.jsx("button",{onClick:r,className:"text-github-text-secondary hover:text-github-text-primary p-1",children:y.jsx(ou,{size:18})})]}),y.jsxs("div",{className:"p-4 space-y-6",children:[y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-github-text-primary mb-2",children:"Font Size"}),y.jsxs("div",{className:"flex items-center gap-3",children:[y.jsx("input",{type:"range",min:"10",max:"20",step:"1",value:o.fontSize,onChange:v=>u({...o,fontSize:parseInt(v.target.value)}),className:"flex-1 accent-github-accent"}),y.jsxs("span",{className:"text-sm text-github-text-secondary w-8 text-right",children:[o.fontSize,"px"]})]})]}),y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-github-text-primary mb-2",children:"Font Family"}),y.jsx("select",{value:o.fontFamily,onChange:v=>u({...o,fontFamily:v.target.value}),className:"w-full p-2 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary text-sm",children:Pj.map(v=>y.jsx("option",{value:v.value,children:v.name},v.value))})]}),y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-github-text-primary mb-2",children:"Theme"}),y.jsx("div",{className:"flex gap-2",children:["light","dark","auto"].map(v=>y.jsx("button",{onClick:()=>g(v),className:`px-3 py-2 text-sm rounded border transition-colors ${o.theme===v?"bg-github-accent text-white border-github-accent":"bg-github-bg-tertiary text-github-text-secondary border-github-border hover:text-github-text-primary"}`,children:v.charAt(0).toUpperCase()+v.slice(1)},v))})]}),y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-github-text-primary mb-2",children:"Syntax Highlighting Theme"}),y.jsx("select",{value:o.syntaxTheme,onChange:v=>u({...o,syntaxTheme:v.target.value}),className:"w-full p-2 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary text-sm",children:p().map(v=>y.jsx("option",{value:v.id,children:v.label},v.id))})]}),y.jsxs("div",{children:[y.jsx("label",{className:"block text-sm font-medium text-github-text-primary mb-2",children:"Open In Editor"}),y.jsx("select",{value:o.editor,onChange:v=>u({...o,editor:v.target.value}),className:"w-full p-2 bg-github-bg-tertiary border border-github-border rounded text-github-text-primary text-sm",children:qj.map(v=>y.jsx("option",{value:v.id,children:v.label},v.id))})]})]}),y.jsxs("div",{className:"flex items-center justify-between p-4 border-t border-github-border",children:[y.jsx("button",{onClick:b,className:"px-3 py-2 text-sm text-github-text-secondary hover:text-github-text-primary",children:"Reset to Default"}),y.jsx("button",{onClick:r,className:"px-4 py-2 text-sm bg-github-accent text-white rounded hover:bg-green-600",children:"Close"})]})]})}):null}const Ux={position:"absolute",fontSize:"16px",pointerEvents:"none",zIndex:100,transform:"translateY(20px) scale(0.5)",opacity:0},Gj=({isActive:e})=>e?y.jsxs(y.Fragment,{children:[y.jsx("div",{className:"animate-sparkle-rise",style:{...Ux,left:"-12px",animationDelay:"0s"},children:"✨"}),y.jsx("div",{className:"animate-sparkle-rise",style:{...Ux,right:"-12px",animationDelay:"0.3s"},children:"✨"})]}):null,Hx={fontSize:14,fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif',theme:"dark",syntaxTheme:"vsDark",editor:vv};function Yj(){const[e,r]=A.useState(()=>{try{const o=localStorage.getItem(Nd);if(o)return{...Hx,...JSON.parse(o)}}catch(o){console.warn("Failed to load appearance settings from localStorage:",o)}return Hx}),i=A.useCallback(o=>{Kx(o)},[]);return A.useEffect(()=>{const o=document.documentElement;if(o.style.setProperty("--app-font-size",`${e.fontSize}px`),o.style.setProperty("--app-font-family",e.fontFamily),e.theme==="auto"){const u=window.matchMedia("(prefers-color-scheme: dark)");i(Ms("auto",u.matches?"dark":"light"));const c=f=>{i(Ms("auto",f.matches?"dark":"light"))};return u.addEventListener("change",c),()=>u.removeEventListener("change",c)}else{i(e.theme);return}},[e,i]),{settings:e,updateSettings:o=>{r(o);try{localStorage.setItem(Nd,JSON.stringify(o))}catch(u){console.warn("Failed to save appearance settings to localStorage:",u)}}}}function wv(e,r,i,l){const o=typeof r=="number"?`L${r}`:Array.isArray(r)?`L${r[0]}-L${r[1]}`:"",u=e||"<unknown file>";if(m1(i)){const c=g1(i);if(c.length>0){let f=`${u}:${o}`,h=0;for(const g of c){const b=i.slice(h,g.startIndex).trim();b&&(f+=`
|
|
73
|
+
${b}`),l&&(f+=`
|
|
74
|
+
ORIGINAL:
|
|
75
|
+
\`\`\`
|
|
76
|
+
${l}
|
|
77
|
+
\`\`\``),f+=`
|
|
78
|
+
SUGGESTED:
|
|
79
|
+
\`\`\`
|
|
80
|
+
${g.suggestedCode}
|
|
81
|
+
\`\`\``,h=g.endIndex}const p=i.slice(h).trim();return p&&(f+=`
|
|
82
|
+
${p}`),f}}return`${u}:${o}
|
|
83
|
+
${i}`}function Xj(e){return e.length===0?"":e.map(i=>wv(i.file,i.line,i.body,i.codeContent)).join(`
|
|
84
|
+
=====
|
|
85
|
+
`)}const _s="difit-storage-v1";class Zj{generateStorageKey(r,i){const l=o=>o.replace(/[^a-zA-Z0-9-_]/g,u=>`_${u.charCodeAt(0).toString(16)}_`);return`${l(r)}-${l(i)}`}normalizeCommitish(r,i,l){if(r==="."||r==="working")return"WORKING";if(r==="staged")return"STAGED";if((r==="HEAD"||r==="@")&&i)return i;if(l?.has(r)){const o=l.get(r);if(o)return o}return(r.startsWith("@")||r.includes("^")||r.includes("~")||r.includes("HEAD"))&&console.warn(`[StorageService] Cannot normalize symbolic ref '${r}' - may cause key collision. currentCommitHash=${i}`),r}getStorageKey(r,i,l,o,u){let c,f;i==="."||i==="working"?(c=l||r,f="WORKING"):i==="staged"?(c=l||r,f="STAGED"):(c=this.normalizeCommitish(r,l,o),f=this.normalizeCommitish(i,l,o));const h=this.generateStorageKey(c,f);return u?`${_s}/${u}/${h}`:`${_s}/${h}`}getDiffContextData(r,i,l,o,u){try{const c=this.getStorageKey(r,i,l,o,u),f=localStorage.getItem(c);if(!f)return null;const h=JSON.parse(f);return h.version!==1?(console.warn(`Unknown storage version: ${h.version}`),null):h}catch(c){return console.error("Error reading diff context data:",c),null}}saveDiffContextData(r,i,l,o,u,c){try{const f=this.getStorageKey(r,i,o,u,c),h={...l,baseCommitish:r,targetCommitish:i,lastModifiedAt:new Date().toISOString()};localStorage.setItem(f,JSON.stringify(h))}catch(f){f instanceof DOMException&&f.name==="QuotaExceededError"?console.error("localStorage quota exceeded"):console.error("Error saving diff context data:",f)}}getComments(r,i,l,o,u){return this.getDiffContextData(r,i,l,o,u)?.comments||[]}saveComments(r,i,l,o,u,c){const h=this.getDiffContextData(r,i,o,u,c)||{version:1,baseCommitish:r,targetCommitish:i,createdAt:new Date().toISOString(),lastModifiedAt:new Date().toISOString(),comments:[],viewedFiles:[]};h.comments=l,this.saveDiffContextData(r,i,h,o,u,c)}getViewedFiles(r,i,l,o,u){return this.getDiffContextData(r,i,l,o,u)?.viewedFiles||[]}saveViewedFiles(r,i,l,o,u,c){const h=this.getDiffContextData(r,i,o,u,c)||{version:1,baseCommitish:r,targetCommitish:i,createdAt:new Date().toISOString(),lastModifiedAt:new Date().toISOString(),comments:[],viewedFiles:[]};h.viewedFiles=l,this.saveDiffContextData(r,i,h,o,u,c)}cleanupOldData(r){const i=new Date;i.setDate(i.getDate()-r);const l=i.getTime(),o=[];for(let u=0;u<localStorage.length;u++){const c=localStorage.key(u);if(c?.startsWith(_s))try{const f=localStorage.getItem(c);if(!f)continue;const h=JSON.parse(f);new Date(h.lastModifiedAt).getTime()<l&&o.push(c)}catch{}}o.forEach(u=>localStorage.removeItem(u))}getStorageSize(){let r=0;for(let i=0;i<localStorage.length;i++){const l=localStorage.key(i);if(!l?.startsWith(_s))continue;const o=localStorage.getItem(l);o&&(r+=(l.length+o.length)*2)}return r}}const $a=new Zj;async function qx(e){try{const i=new TextEncoder().encode(e),l=await crypto.subtle.digest("SHA-256",i);return Array.from(new Uint8Array(l)).map(u=>u.toString(16).padStart(2,"0")).join("")}catch{return console.warn("Crypto API not available, using fallback hash"),Kj(e)}}function Kj(e){let r=0;for(let i=0;i<e.length;i++){const l=e.charCodeAt(i);r=(r<<5)-r+l,r=r&r}return Math.abs(r).toString(16)}function $x(e){const r=e.chunks.map(i=>{const l=i.lines.filter(o=>o.type!=="hunk"&&o.type!=="header").map(o=>`${o.type}:${o.content}`).join(`
|
|
86
|
+
`);return`${i.header}
|
|
87
|
+
${l}`}).join(`
|
|
88
|
+
|
|
89
|
+
`);return`${e.path}
|
|
90
|
+
${e.status}
|
|
91
|
+
${r}`}function Qj(e,r,i,l,o){const[u,c]=A.useState([]);A.useEffect(()=>{if(!e||!r)return;const S=$a.getComments(e,r,i,l,o);c(S)},[e,r,i,l,o]);const f=A.useCallback(S=>{!e||!r||($a.saveComments(e,r,S,i,l,o),c(S))},[e,r,i,l,o]),h=A.useCallback(S=>{const w={id:crypto.randomUUID(),filePath:S.filePath,body:S.body,createdAt:new Date().toISOString(),updatedAt:new Date().toISOString(),position:{side:S.side,line:S.line},codeSnapshot:S.codeSnapshot||{content:"",language:PE(S.filePath)}},N=[...u,w];return f(N),w},[u,f]),p=A.useCallback(S=>{const w=u.filter(N=>N.id!==S);f(w)},[u,f]),g=A.useCallback((S,w)=>{const N=u.map(E=>E.id===S?{...E,body:w,updatedAt:new Date().toISOString()}:E);f(N)},[u,f]),b=A.useCallback(()=>{f([])},[f]),v=A.useCallback(S=>{const w=u.find(E=>E.id===S);if(!w)return"";const N=typeof w.position.line=="number"?w.position.line:[w.position.line.start,w.position.line.end];return wv(w.filePath,N,w.body,w.codeSnapshot?.content)},[u]),x=A.useCallback(()=>{const S=u.map(w=>({id:w.id,file:w.filePath,line:typeof w.position.line=="number"?w.position.line:[w.position.line.start,w.position.line.end],body:w.body,timestamp:w.createdAt,codeContent:w.codeSnapshot?.content}));return Xj(S)},[u]);return{comments:u,addComment:h,removeComment:p,updateComment:g,clearAllComments:b,generatePrompt:v,generateAllCommentsPrompt:x}}const Jj=20;async function Px(e,r){const i=encodeURIComponent(e),l=await fetch(`/api/blob/${i}?ref=${encodeURIComponent(r)}`);if(!l.ok)throw new Error(`Failed to fetch file content: ${l.statusText}`);const u=(await l.text()).split(`
|
|
92
|
+
`);return u.length>0&&u[u.length-1]===""&&u.pop(),{lines:u,totalLines:u.length}}async function Wj(e,r,i,l){const o=encodeURIComponent(e),u=new URLSearchParams;r&&u.set("oldRef",r),i&&u.set("newRef",i),l&&l!==e&&u.set("oldPath",l);const c=await fetch(`/api/line-count/${o}?${u}`);if(!c.ok)throw new Error(`Failed to fetch line count: ${c.statusText}`);return c.json()}function eR({baseCommitish:e,targetCommitish:r}){const[i,l]=A.useState({}),[o,u]=A.useState(!1),[c,f]=A.useState(null),[h,p]=A.useState(0),g=A.useRef(new Map),b=A.useRef({});b.current=i;const v=A.useCallback(async L=>{const O=g.current.get(L.path);if(O)return O;const Z=(async()=>{const $=b.current[L.path];if($?.oldContent&&$?.newContent)return $;const F={...$,expandedRanges:$?.expandedRanges||[]};if(L.status!=="added"&&e){const H=L.oldPath||L.path;try{const{lines:G,totalLines:Q}=await Px(H,e);F.oldContent=G,F.oldTotalLines=Q}catch(G){console.error("Failed to fetch old file content:",G),F.oldContent=[],F.oldTotalLines=0}}if(L.status!=="deleted"&&r)try{const{lines:H,totalLines:G}=await Px(L.path,r);F.newContent=H,F.newTotalLines=G}catch(H){console.error("Failed to fetch new file content:",H),F.newContent=[],F.newTotalLines=0}return F})();g.current.set(L.path,Z);try{return await Z}finally{g.current.delete(L.path)}},[e,r]),x=A.useCallback(L=>{f(L),p(O=>O+1)},[]),S=A.useCallback(async(L,O,Z,$=Jj)=>{u(!0);try{const F=await v(L);l(H=>{const G=H[L.path],Q=G?.expandedRanges||F.expandedRanges||[],U=Q.findIndex(B=>B.chunkIndex===O&&B.direction===Z),Y=[...Q];if(U>=0&&Y[U]){const B=Y[U];Y[U]={chunkIndex:B.chunkIndex,direction:B.direction,count:B.count+$}}else Y.push({chunkIndex:O,direction:Z,count:$});return{...H,[L.path]:{oldContent:G?.oldContent??F.oldContent,newContent:G?.newContent??F.newContent,oldTotalLines:G?.oldTotalLines??F.oldTotalLines,newTotalLines:G?.newTotalLines??F.newTotalLines,expandedRanges:Y}}}),x(L.path)}finally{u(!1)}},[v,x]),w=A.useCallback(async(L,O,Z)=>{u(!0);try{const $=await v(L);l(F=>{const H=F[L.path],Q=[...H?.expandedRanges||$.expandedRanges||[]],U=Q.findIndex(D=>D.chunkIndex===O&&D.direction==="up"),Y=Q.findIndex(D=>D.chunkIndex===O-1&&D.direction==="down");let B=0,X=0;U>=0&&Q[U]&&(B=Q[U].count),Y>=0&&Q[Y]&&(X=Q[Y].count);const M=B+X+Z,V=Q.filter(D=>!(D.chunkIndex===O-1&&D.direction==="down")),R=V.findIndex(D=>D.chunkIndex===O&&D.direction==="up");return R>=0&&V[R]?V[R]={chunkIndex:O,direction:"up",count:M}:V.push({chunkIndex:O,direction:"up",count:M}),{...F,[L.path]:{oldContent:H?.oldContent??$.oldContent,newContent:H?.newContent??$.newContent,oldTotalLines:H?.oldTotalLines??$.oldTotalLines,newTotalLines:H?.newTotalLines??$.newTotalLines,expandedRanges:V}}}),x(L.path)}finally{u(!1)}},[v,x]),N=A.useCallback(async L=>{const O=b.current[L.path];if(O?.oldTotalLines!==void 0||O?.newTotalLines!==void 0)return;const Z=L.status!=="added"?e:void 0,$=L.status!=="deleted"?r:void 0;if(!(!Z&&!$))try{const{oldLineCount:F,newLineCount:H}=await Wj(L.path,Z,$,L.oldPath);l(G=>{const Q=G[L.path];return Q?.oldTotalLines!==void 0||Q?.newTotalLines!==void 0?G:{...G,[L.path]:{...Q,expandedRanges:Q?.expandedRanges||[],oldTotalLines:F,newTotalLines:H}}}),x(L.path)}catch(F){console.error("Failed to prefetch line count:",F)}},[e,r,x]),E=A.useCallback((L,O,Z)=>{const $=i[L];return $&&$.expandedRanges.find(H=>H.chunkIndex===O&&H.direction===Z)?.count||0},[i]),C=A.useCallback((L,O,Z)=>{if(L.status==="added"||L.status==="deleted")return 0;const $=L.chunks[Z-1];let F;if(!$)F=O.oldStart-1;else{const Q=$.oldStart+$.oldLines;F=O.oldStart-Q}const H=E(L.path,Z,"up"),G=Z>0?E(L.path,Z-1,"down"):0;return Math.max(0,F-H-G)},[E]),j=A.useCallback((L,O,Z)=>{if(L.status==="added"||L.status==="deleted")return 0;const $=i[L.path],F=$?.oldTotalLines||$?.newTotalLines;if(F===void 0)return L.chunks[Z+1]?0:-1;if(L.chunks[Z+1])return 0;const G=O.oldStart+O.oldLines-1,Q=F-G,U=E(L.path,Z,"down");return Math.max(0,Q-U)},[i,E]),z=A.useCallback((L,O,Z)=>{const $=i[L.path];if(!$)return O;const F=E(L.path,Z,"up"),H=E(L.path,Z,"down");if(F===0&&H===0)return O;const G=$.oldContent||[],Q=$.newContent||[],U=[];if(F>0){const X=L.chunks[Z-1];let M;X?M=X.oldStart+X.oldLines-1:M=Math.max(0,O.oldStart-1-F);const V=O.oldStart-1,R=O.newStart-1,D=Math.min(F,V-M),q=V-D,T=R-D;for(let te=0;te<D;te++){const ie=q+te+1,fe=T+te+1,ge=G[ie-1]??Q[fe-1]??"";U.push({type:"normal",content:ge,oldLineNumber:ie,newLineNumber:fe,isExpanded:!0})}}if(U.push(...O.lines),H>0){const X=O.oldStart+O.oldLines-1,M=O.newStart+O.newLines-1,V=L.chunks[Z+1],R=V?V.oldStart-1:$.oldTotalLines||X,D=Math.min(H,R-X);for(let q=0;q<D;q++){const T=X+q+1,te=M+q+1,ie=G[T-1]??Q[te-1]??"";U.push({type:"normal",content:ie,oldLineNumber:T,newLineNumber:te,isExpanded:!0})}}const Y=U[0],B=U[U.length-1];return{...O,lines:U,oldStart:Y?.oldLineNumber??O.oldStart,newStart:Y?.newLineNumber??O.newStart,oldLines:(B?.oldLineNumber??O.oldStart+O.oldLines-1)-(Y?.oldLineNumber??O.oldStart)+1,newLines:(B?.newLineNumber??O.newStart+O.newLines-1)-(Y?.newLineNumber??O.newStart)+1}},[i,E]),I=A.useCallback(L=>{const O=[];for(let Z=0;Z<L.chunks.length;Z++){const $=L.chunks[Z];if(!$)continue;const F=z(L,$,Z),H=C(L,$,Z),G=j(L,$,Z),Q=O[O.length-1];if(Q&&H===0){Q.lines=[...Q.lines,...F.lines],Q.originalIndices.push(Z),Q.hiddenLinesAfter=G;const U=Q.lines[Q.lines.length-1];Q.oldLines=(U?.oldLineNumber??Q.oldStart+Q.oldLines-1)-Q.oldStart+1,Q.newLines=(U?.newLineNumber??Q.newStart+Q.newLines-1)-Q.newStart+1}else O.push({...F,originalIndices:[Z],hiddenLinesBefore:H,hiddenLinesAfter:G})}return O},[z,C,j]);return{expandedState:i,isLoading:o,lastUpdatedFilePath:c,lastUpdatedAt:h,expandLines:S,expandAllBetweenChunks:w,prefetchFileContent:N,getMergedChunks:I,getHiddenLinesBefore:C,getHiddenLinesAfter:j}}var Sv=(e=>(e.DEFAULT="default",e.WORKING="working",e.STAGED="staged",e.DOT="dot",e.SPECIFIC="specific",e))(Sv||{});function tR(e){const r=A.useRef(null),i=A.useRef(null),l=A.useRef(0),o=5,u=3e3,[c,f]=A.useState({isWatchEnabled:!1,diffMode:Sv.DEFAULT,shouldReload:!1,isReloading:!1,lastChangeTime:null,lastChangeType:null,connectionStatus:"disconnected"}),[h,p]=A.useState(null),g=A.useCallback(()=>{if(!r.current)try{const x=new EventSource("/api/watch");r.current=x,x.onopen=()=>{console.log("Connected to file watch service"),f(S=>({...S,connectionStatus:"connected"})),l.current=0,p(null)},x.onmessage=S=>{try{const w=JSON.parse(S.data);switch(w.type){case"connected":f(N=>({...N,isWatchEnabled:!0,diffMode:w.diffMode,connectionStatus:"connected"}));break;case"reload":console.log("File changes detected, showing reload button:",w.changeType),f(N=>({...N,shouldReload:!0,lastChangeTime:new Date,lastChangeType:w.changeType}));break;case"error":console.error("File watch error:",w.message),p(w.message||"File watch error occurred");break}}catch(w){console.error("Error parsing watch event:",w)}},x.onerror=()=>{console.log("File watch connection lost"),f(S=>({...S,connectionStatus:"disconnected"})),r.current&&(r.current.close(),r.current=null),l.current<o?(f(S=>({...S,connectionStatus:"reconnecting"})),l.current+=1,i.current=setTimeout(()=>{console.log(`Attempting to reconnect to file watch service (${l.current}/${o})...`),g()},u)):(console.error("Max reconnection attempts reached"),p("Lost connection to file watch service"))}}catch(x){console.error("Failed to connect to file watch service:",x),p("Failed to connect to file watch service")}},[o,u]),b=A.useCallback(async()=>{if(!c.isReloading){f(x=>({...x,isReloading:!0}));try{e&&await e(),f(x=>({...x,shouldReload:!1,isReloading:!1,lastChangeTime:null,lastChangeType:null}))}catch(x){console.error("Reload failed:",x),p("Failed to reload diff data"),f(S=>({...S,isReloading:!1}))}}},[e,c.isReloading]),v=()=>{r.current&&(r.current.close(),r.current=null),i.current&&(clearTimeout(i.current),i.current=null)};return A.useEffect(()=>(g(),v),[g]),A.useEffect(()=>v,[]),{shouldReload:c.shouldReload,isConnected:c.connectionStatus==="connected",error:h,reload:b,watchState:c}}const fh={SCROLL_CONTAINER:"main.overflow-y-auto"};function ri(e,r){const i=`file-${e.fileIndex}-chunk-${e.chunkIndex}-line-${e.lineIndex}`;return r==="split"?`${i}-${e.side}`:i}function kv(e,r){return`${e}:${r}`}function nR(e,r){const i=r[e.fileIndex]?.chunks[e.chunkIndex]?.lines[e.lineIndex];return i&&(i.type==="add"||i.type==="delete"||i.type==="normal")?i.type:null}function Sn(e,r){const i=nR(e,r);return i?i==="normal"?!0:i==="delete"?e.side==="left":i==="add"?e.side==="right":!1:!1}function Ev(e,r){return Sn(e,r)?e:{...e,side:e.side==="left"?"right":"left"}}const Vx={VIEWPORT_OFFSET_RATIO:1/3};function rR(e,r,i,l){return{line:o=>{const u=e[o.fileIndex];return!u||l?.has(u.path)?!1:i==="unified"||Sn(o,e)},chunk:o=>{const u=e[o.fileIndex];if(!u||l?.has(u.path))return!1;const c=u.chunks[o.chunkIndex]?.lines[o.lineIndex];if(!c||c.type==="normal")return!1;if(o.lineIndex===0)return!0;const f=u.chunks[o.chunkIndex]?.lines[o.lineIndex-1];return!f||f.type==="normal"},comment:o=>{const u=e[o.fileIndex];if(!u||l?.has(u.path))return!1;const c=u.chunks[o.chunkIndex]?.lines[o.lineIndex];if(!c||c.type==="delete")return!1;const f=c.newLineNumber;if(!f)return!1;const h=kv(u.path,f);return r.has(h)},file:o=>o.chunkIndex===0&&o.lineIndex===0}}function iR(){return e=>{const r=document.getElementById(e);if(!r)return;const i=document.querySelector(fh.SCROLL_CONTAINER);if(!i)throw new Error(`Scrollable container (${fh.SCROLL_CONTAINER}) not found`);const l=r.getBoundingClientRect(),o=i.getBoundingClientRect(),u=i.clientHeight,c=i.scrollTop,f=Math.max(o.top,0),h=Math.min(o.bottom,window.innerHeight);if(!(l.top>=f&&l.bottom<=h)){const w=lR(r,i)-u*Vx.VIEWPORT_OFFSET_RATIO;i.scrollTop=Math.max(0,w);return}const g=l.bottom>Math.min(o.bottom,window.innerHeight),v=r.offsetTop-i.offsetTop-u*Vx.VIEWPORT_OFFSET_RATIO,x=v>c;g&&x&&(i.scrollTop=Math.max(0,v))}}function lR(e,r){let i=e,l=0;for(;i&&i!==r&&i.offsetParent;)l+=i.offsetTop,i=i.offsetParent;return i&&i!==r&&(l+=i.offsetTop),l}function aR(e){return e||{fileIndex:0,chunkIndex:0,lineIndex:-1,side:"right"}}function oR(e,r,i){return i&&e.fileIndex===r.fileIndex&&e.chunkIndex===r.chunkIndex&&e.lineIndex===r.lineIndex}function sR(e,r,i){let{fileIndex:l,chunkIndex:o,lineIndex:u}=e;const c=i.length;let f=0;if(r==="next")for(u++;f<c;){if(i[l]?.chunks[o]?.lines[u])return{...e,fileIndex:l,chunkIndex:o,lineIndex:u};o++,u=0,i[l]?.chunks[o]||(l++,o=0,u=0,l>=c&&(l=0,f++))}else for(u--;f<c;){if(u<0)if(o--,o<0){l--,l<0&&(l=c-1,f++);const h=i[l];if(h&&h.chunks.length>0){o=h.chunks.length-1;const p=h.chunks[o];u=p&&p.lines.length>0?p.lines.length-1:-1}else o=-1,u=-1}else{const h=i[l]?.chunks[o];u=h&&h.lines.length>0?h.lines.length-1:-1}if(u>=0&&i[l]?.chunks[o]?.lines[u])return{...e,fileIndex:l,chunkIndex:o,lineIndex:u};u<0||u--}return null}function uR(e,r,i,l,o){let u=e,c=!1;for(;u;){const f=sR(u,r,l);if(!f||(u=f,oR(u,e,c)))break;if(c=!0,i(u,l)){const h=Ev(u,l);return{position:h,scrollTarget:ri(h,o)}}}return{position:null,scrollTarget:null}}function cR({files:e,comments:r,viewMode:i=Ka,reviewedFiles:l,onToggleReviewed:o,onCreateComment:u,onCopyAllComments:c,onDeleteAllComments:f,onShowCommentsList:h,onRefresh:p}){const[g,b]=A.useState(null),[v,x]=A.useState(!1),S=A.useMemo(()=>iR(),[]),w=A.useMemo(()=>{const H=new Map;return r.forEach(G=>{const Q=Array.isArray(G.line)?G.line[0]:G.line,U=kv(G.file,Q);H.has(U)||H.set(U,[]),H.get(U)?.push(G)}),H},[r]),N=A.useMemo(()=>rR(e,w,i,l),[e,w,i,l]),E=A.useCallback((H,G)=>{if(e.length===0)return{position:null,scrollTarget:null};const Q=aR(g);return uR(Q,H,G,e,i)},[g,e,i]),C=A.useCallback(H=>G=>{const Q=E(G,H);Q.position&&(b(Q.position),Q.scrollTarget&&S(Q.scrollTarget))},[E,S]),j=A.useMemo(()=>C(N.line),[C,N.line]),z=A.useMemo(()=>C(N.chunk),[C,N.chunk]),I=A.useMemo(()=>C(N.file),[C,N.file]),L=A.useMemo(()=>C(N.comment),[C,N.comment]),O=A.useCallback(H=>{if(!g||i!=="split")return;let G={...g,side:H};const Q=e[g.fileIndex]?.chunks[g.chunkIndex]?.lines[g.lineIndex];if(Q){if(H==="left"&&Q.type==="add"&&g.lineIndex>0){if(e[g.fileIndex]?.chunks[g.chunkIndex]?.lines[g.lineIndex-1]?.type==="delete"){G={...G,lineIndex:g.lineIndex-1},b(G),S(ri(G,i));return}}else if(H==="right"&&Q.type==="delete"&&e[g.fileIndex]?.chunks[g.chunkIndex]?.lines[g.lineIndex+1]?.type==="add"){G={...G,lineIndex:g.lineIndex+1},b(G),S(ri(G,i));return}}if(!Sn(G,e)){const U=e[g.fileIndex];if(!U)return;const Y=U.chunks[g.chunkIndex];if(Y){for(let B=g.lineIndex+1;B<Y.lines.length;B++){const X={...G,lineIndex:B};if(Sn(X,e)){G=X;break}}if(!Sn(G,e))for(let B=g.lineIndex-1;B>=0;B--){const X={...G,lineIndex:B};if(Sn(X,e)){G=X;break}}}if(!Sn(G,e)){for(let B=g.chunkIndex+1;B<U.chunks.length;B++){const X=U.chunks[B];if(X){for(let M=0;M<X.lines.length;M++){const V={...G,chunkIndex:B,lineIndex:M};if(Sn(V,e)){G=V;break}}if(Sn(G,e))break}}if(!Sn(G,e))for(let B=g.chunkIndex-1;B>=0;B--){const X=U.chunks[B];if(X){for(let M=X.lines.length-1;M>=0;M--){const V={...G,chunkIndex:B,lineIndex:M};if(Sn(V,e)){G=V;break}}if(Sn(G,e))break}}}}b(G),S(ri(G,i))},[g,i,S,e]),Z=A.useCallback(()=>{const H=document.querySelector(fh.SCROLL_CONTAINER);if(!H)return;const G=H.getBoundingClientRect(),Q=G.top+G.height/2;let U=1/0,Y=null;e.forEach((B,X)=>{B.chunks.forEach((M,V)=>{M.lines.forEach((R,D)=>{const q=i==="split"?["left","right"]:["right"];for(const T of q){const te={fileIndex:X,chunkIndex:V,lineIndex:D,side:T};if(i==="split"&&!Sn(te,e))continue;const ie=ri(te,i),fe=document.getElementById(ie);if(fe){const ge=fe.getBoundingClientRect(),ye=ge.top+ge.height/2,pe=Math.abs(ye-Q);ge.top<G.bottom&&ge.bottom>G.top&&pe<U&&(U=pe,Y=te)}}})})}),Y&&b(Y)},[e,i,b]),$=A.useCallback(H=>{if(!H){b(null);return}const G=Ev(H,e);b(G),S(ri(G,i))},[e,i,S]),F={scopes:"navigation",enableOnFormTags:!1,preventDefault:!0};return lt("j, down",()=>j("next"),F,[j]),lt("k, up",()=>j("prev"),F,[j]),lt("n",()=>z("next"),F,[z]),lt("p",()=>z("prev"),F,[z]),lt("shift+n",()=>L("next"),F,[L]),lt("shift+p",()=>L("prev"),F,[L]),lt("]",()=>I("next"),{...F,useKey:!0},[I]),lt("[",()=>I("prev"),{...F,useKey:!0},[I]),lt("{",()=>{e.length>0&&(b({fileIndex:0,chunkIndex:0,lineIndex:0,side:i==="split"?"left":"right"}),S(ri({fileIndex:0,chunkIndex:0,lineIndex:0,side:i==="split"?"left":"right"},i)))},{...F,useKey:!0},[e,i,S]),lt("}",()=>{if(e.length>0){const H=e.length-1,G=e[H];G&&G.chunks.length>0&&(b({fileIndex:H,chunkIndex:0,lineIndex:0,side:i==="split"?"left":"right"}),S(ri({fileIndex:H,chunkIndex:0,lineIndex:0,side:i==="split"?"left":"right"},i)))}},{...F,useKey:!0},[e,i,S]),lt("h, left",()=>O("left"),{...F,enabled:i==="split"},[O,i]),lt("l, right",()=>O("right"),{...F,enabled:i==="split"},[O,i]),lt("v",()=>{if(g){const H=e[g.fileIndex];H&&o(H.path)}},F,[g,e,o]),lt("shift+r",()=>{p&&p()},F,[p]),lt("c",()=>{if(g&&u){const H=e[g.fileIndex]?.chunks[g.chunkIndex]?.lines[g.lineIndex];H&&H.type!=="delete"&&u()}},F,[g,e,u]),lt("?",()=>x(!v),{...F,useKey:!0},[v]),lt(".",H=>{H.ctrlKey||H.altKey||H.shiftKey||H.metaKey||(Z(),H.preventDefault())},{...F,useKey:!0,preventDefault:!1},[Z]),lt("shift+c",()=>{c&&c()},{...F,scopes:["navigation","comments-list"]},[c]),lt("shift+d",()=>{f&&f()},{...F,scopes:["navigation","comments-list"]},[f]),lt("shift+l",()=>{h&&h()},F,[h]),{cursor:g,isHelpOpen:v,setIsHelpOpen:x,setCursorPosition:$}}const Ed=new Map;let fR=0;function Os(e){return Ed.has(e)||Ed.set(e,`file-${++fR}`),Ed.get(e)??""}const dR=8,hR="1200px 0px",Gx=60,pR=180;function mR({diffData:e,diffScrollContainerRef:r,setDiffData:i}){const[l,o]=A.useState(new Set),u=A.useRef(new Set),c=A.useRef(null),f=A.useRef(new Map),h=A.useRef(new Set),p=A.useRef(null),g=A.useRef(0);A.useEffect(()=>{if(!e){const C=new Set;u.current=C,o(C),h.current.clear(),p.current=null;return}const w=`${e.requestedBaseCommitish??""}:${e.requestedTargetCommitish??""}`;if(p.current===w)return;p.current=w;const N=e.files.slice(0,dR).map(C=>C.path),E=new Set(N);u.current=E,o(E),h.current.clear()},[e]);const b=A.useCallback(w=>{const N=f.current.get(w);N&&c.current&&c.current.unobserve(N),o(E=>{if(E.has(w))return E;const C=new Set(E);return C.add(w),u.current=C,C})},[]),v=A.useCallback((w,N)=>{const E=c.current,C=f.current.get(w);if(C&&E&&E.unobserve(C),!N){f.current.delete(w);return}f.current.set(w,N),!(u.current.has(w)||!E)&&E.observe(N)},[]);A.useEffect(()=>{if(c.current&&c.current.disconnect(),!e){c.current=null;return}const w=new IntersectionObserver(N=>{o(E=>{let C=!1;const j=new Set(E);return N.forEach(z=>{if(!z.isIntersecting)return;const I=z.target.dataset.filePath;!I||j.has(I)||(j.add(I),w.unobserve(z.target),C=!0)}),C&&(u.current=j),C?j:E})},{root:r.current,rootMargin:hR});return c.current=w,f.current.forEach((N,E)=>{u.current.has(E)||w.observe(N)}),()=>{w.disconnect(),c.current=null}},[e,r]);const x=A.useCallback(w=>{if(!e)return;const N=e.files.findIndex(C=>C.path===w);if(N<0)return;const E=c.current;o(C=>{let j=!1;const z=new Set(C);for(let I=0;I<=N;I++){const L=e.files[I]?.path;if(L&&!z.has(L)){z.add(L),j=!0;const O=f.current.get(L);O&&E&&E.unobserve(O)}}return j&&(u.current=z),j?z:C})},[e]),S=A.useCallback(w=>{x(w);const N=e?.files.findIndex(O=>O.path===w)??-1,E=e&&N>=0?e.files.slice(0,N+1).map(O=>Os(O.path)):[Os(w)],C=g.current+1;g.current=C;const j=()=>{for(const O of E){const Z=document.getElementById(O);if(!Z||Z.dataset.rendered!=="true")return!1}return!0},z=O=>{const Z=r.current,$=document.getElementById(Os(w));if(!Z||!$)return!1;const F=Z.getBoundingClientRect(),H=$.getBoundingClientRect(),G=Z.scrollTop+(H.top-F.top);return Z.scrollTo({top:Math.max(0,G),behavior:O}),!0};let I=0;const L=()=>{requestAnimationFrame(()=>{if(g.current===C){if(!j()){I<Gx&&(I++,L());return}if(!z("smooth")){I<Gx&&(I++,L());return}window.setTimeout(()=>{g.current===C&&z("smooth")},pR)}})};L()},[e,r,x]);return A.useEffect(()=>{if(!e||e.targetCommitish==="stdin")return;const w=e.targetCommitish||"HEAD",N=`${e.requestedBaseCommitish??""}...${e.requestedTargetCommitish??""}`;e.files.forEach(E=>{if(!l.has(E.path)||E.isGenerated!==!1||E.status==="deleted")return;const C=`${N}:${w}:${E.path}`;if(h.current.has(C))return;h.current.add(C);const j=encodeURIComponent(E.path);fetch(`/api/generated-status/${j}?ref=${encodeURIComponent(w)}`).then(z=>z.ok?z.json():null).then(z=>{!z||z.isGenerated!==!0||i(I=>{if(!I||I.requestedBaseCommitish!==e.requestedBaseCommitish||I.requestedTargetCommitish!==e.requestedTargetCommitish)return I;let L=!1;const O=I.files.map(Z=>Z.path!==E.path||Z.isGenerated?Z:(L=!0,{...Z,isGenerated:!0}));return L?{...I,files:O}:I})}).catch(()=>{})})},[e,l,i]),{renderedFilePaths:l,ensureFileRendered:b,ensureFilesRenderedUpTo:x,registerLazyFileContainer:v,scrollFileIntoDiffContainer:S}}function gR(e,r,i,l,o,u){const[c,f]=A.useState([]),[h,p]=A.useState(new Map);A.useEffect(()=>{if(!e||!r)return;const E=$a.getViewedFiles(e,r,i,l,u);(async()=>{if(o&&o.length>0){const j=[],z=new Set(E.map(I=>I.filePath));for(const I of o)if((I.isGenerated||I.status==="deleted")&&!z.has(I.path))try{const L=$x(I),O=await qx(L),Z={filePath:I.path,viewedAt:new Date().toISOString(),diffContentHash:O};j.push(Z)}catch(L){console.error("Failed to generate hash for auto-collapsed file:",L)}if(j.length>0){const I=[...E,...j];$a.saveViewedFiles(e,r,I,i,l,u),f(I);return}}f(E)})()},[e,r,i,l,u]);const g=A.useCallback(E=>{!e||!r||($a.saveViewedFiles(e,r,E,i,l,u),f(E))},[e,r,i,l,u]),b=A.useMemo(()=>new Set(c.map(E=>E.filePath)),[c]),v=A.useCallback(E=>c.find(C=>C.filePath===E),[c]),x=A.useCallback(async E=>{const C=h.get(E.path);if(C)return C;const j=$x(E),z=await qx(j);return p(I=>new Map(I).set(E.path,z)),z},[h]),S=A.useCallback(async(E,C)=>{const j=v(E);if(!j)return!1;const z=await x(C);return j.diffContentHash!==z},[v,x]),w=A.useCallback(async(E,C)=>{if(v(E)){const z=c.filter(I=>I.filePath!==E);g(z)}else{const z=await x(C),I={filePath:E,viewedAt:new Date().toISOString(),diffContentHash:z},L=[...c,I];g(L)}},[c,v,x,g]),N=A.useCallback(()=>{g([]),p(new Map)},[g]);return{viewedFiles:b,toggleFileViewed:w,isFileContentChanged:S,getViewedFileRecord:v,clearViewedFiles:N}}const Yx={mobileMax:767,desktopMin:1024},iu={mobile:`(max-width: ${Yx.mobileMax}px)`,desktop:`(min-width: ${Yx.desktopMin}px)`},bR=()=>typeof window>"u"?{isMobile:!1,isDesktop:!0}:{isMobile:window.matchMedia(iu.mobile).matches,isDesktop:window.matchMedia(iu.desktop).matches};function yR(){const[e,r]=A.useState(()=>bR());return A.useEffect(()=>{if(typeof window>"u")return;const i=window.matchMedia(iu.mobile),l=window.matchMedia(iu.desktop),o=()=>{r({isMobile:i.matches,isDesktop:l.matches})};return o(),i.addEventListener("change",o),l.addEventListener("change",o),()=>{i.removeEventListener("change",o),l.removeEventListener("change",o)}},[]),e}function xR(e,r,i){for(let l=0;l<e.chunks.length;l++){const o=e.chunks[l];if(o)for(let u=0;u<o.lines.length;u++){const c=o.lines[u];if(!c)continue;if((c.newLineNumber||c.oldLineNumber)===i)return{fileIndex:r,chunkIndex:l,lineIndex:u,side:c.newLineNumber?"right":"left"}}}return null}function vR(e,r){const i=r.findIndex(u=>u.path===e.file);if(i===-1)return null;const l=r[i];if(!l)return null;const o=Array.isArray(e.line)?e.line[1]:e.line;return xR(l,i,o)}const wR=[],SR=[],Cv="difit.sidebarWidth",Nv="difit.sidebarOpen",Av=200,Tv=600,Cd=280,kR=()=>{if(typeof window>"u")return Cd;const e=window.localStorage.getItem(Cv);if(!e)return Cd;const r=Number.parseInt(e,10);return Number.isFinite(r)?Math.min(Tv,Math.max(Av,r)):Cd},ER=()=>{if(typeof window>"u")return!0;const e=window.localStorage.getItem(Nv);return e===null||e==="true"?!0:e!=="false"};function CR(){const[e,r]=A.useState(null),[i,l]=A.useState(Ka),o=A.useRef(!1),[u,c]=A.useState(!0),[f,h]=A.useState(!0),[p,g]=A.useState(null),[b,v]=A.useState(!1),[x,S]=A.useState(kR),[w,N]=A.useState(!1),[E,C]=A.useState(ER),[j,z]=A.useState(!1),[I,L]=A.useState(!1),[O,Z]=A.useState(!1),[$,F]=A.useState(!1),[H,G]=A.useState(!1),[Q,U]=A.useState(new Set),Y=A.useRef(!1),B=A.useRef(null),[X,M]=A.useState(null),[V,R]=A.useState(""),[D,q]=A.useState(""),[T,te]=A.useState(""),[ie,fe]=A.useState(""),ge=A.useRef(!1),{settings:ye,updateSettings:pe}=Yj(),{isMobile:me,isDesktop:xe}=yR(),{comments:de,addComment:we,removeComment:Ee,updateComment:Pe,clearAllComments:Ke,generatePrompt:Me,generateAllCommentsPrompt:It}=Qj(e?.baseCommitish,e?.targetCommitish,e?.commit,void 0,e?.repositoryId),pt=A.useMemo(()=>de.map(re=>({id:re.id,file:re.filePath,line:typeof re.position.line=="number"?re.position.line:[re.position.line.start,re.position.line.end],body:re.body,timestamp:re.createdAt,codeContent:re.codeSnapshot?.content,side:re.position.side})),[de]),mt=A.useMemo(()=>de.map(re=>({id:re.id,file:re.filePath,line:typeof re.position.line=="number"?re.position.line:[re.position.line.start,re.position.line.end],body:re.body,timestamp:re.createdAt,side:re.position.side})),[de]),Gt=A.useMemo(()=>{const re=new Map;return pt.forEach(ve=>{const Se=re.get(ve.file);Se?Se.push(ve):re.set(ve.file,[ve])}),re},[pt]),Yt=me&&de.length>0,{viewedFiles:tt,toggleFileViewed:at,clearViewedFiles:nr}=gR(e?.baseCommitish,e?.targetCommitish,e?.commit,void 0,e?.files,e?.repositoryId);A.useEffect(()=>{Y.current=!1},[e?.repositoryId,e?.commit]),A.useEffect(()=>{Y.current||(U(new Set(tt)),Y.current=!0)},[tt]);const{renderedFilePaths:ae,ensureFileRendered:be,ensureFilesRenderedUpTo:Te,registerLazyFileContainer:Oe,scrollFileIntoDiffContainer:Ve}=mR({diffData:e,diffScrollContainerRef:B,setDiffData:r}),Dt=A.useCallback(async re=>{if(!e)return;const ve=e.files.find(Qe=>Qe.path===re);if(!ve)return;const Se=tt.has(re);await at(re,ve),U(Qe=>{const Ie=new Set(Qe);return Se?Ie.delete(re):Ie.add(re),Ie}),Se||setTimeout(()=>{Ve(re)},100)},[e,Ve,at,tt]),zn=A.useCallback(re=>{U(ve=>{const Se=new Set(ve);return Se.has(re)?Se.delete(re):Se.add(re),Se})},[]),Ot=A.useCallback(re=>{e&&U(re?new Set(e.files.map(ve=>ve.path)):new Set)},[e]),gt=A.useCallback(re=>{o.current=!0,l(re)},[]),{isLoading:Ut,expandLines:Je,expandAllBetweenChunks:$n,prefetchFileContent:fn,getMergedChunks:Fl,lastUpdatedFilePath:Ar,lastUpdatedAt:Ii}=eR({baseCommitish:e?.baseCommitish,targetCommitish:e?.targetCommitish}),Tr=A.useRef(Fl);A.useEffect(()=>{Tr.current=Fl},[Fl]);const[Fn,jr]=A.useState(new Map),Pn=A.useMemo(()=>{const re=new Map;return e?.files.forEach(ve=>{re.set(ve.path,ve)}),re},[e]);A.useEffect(()=>{if(!e){jr(new Map);return}jr(re=>{let ve=!1;const Se=new Map(re),Qe=new Set(e.files.map(Ie=>Ie.path));return Se.forEach((Ie,St)=>{Qe.has(St)||(Se.delete(St),ve=!0)}),ae.forEach(Ie=>{if(Se.has(Ie))return;const St=Pn.get(Ie);St&&(Se.set(Ie,Tr.current(St)),ve=!0)}),ve?Se:re})},[e,Pn,ae]),A.useEffect(()=>{if(!e||!Ar)return;const re=Pn.get(Ar);re&&jr(ve=>{if(!ve.has(re.path))return ve;const Se=new Map(ve);return Se.set(re.path,Tr.current(re)),Se})},[e,Pn,Ar,Ii]);const Eu=A.useMemo(()=>e?e.files.map(re=>({...re,chunks:Fn.get(re.path)||re.chunks})):[],[e,Fn]),[Bl,fi]=A.useState(null),{shouldReload:di,reload:ro,watchState:Il}=tR(async()=>{await wt()}),{cursor:Jt,isHelpOpen:io,setIsHelpOpen:Ui,setCursorPosition:Vn}=cR({files:Eu,comments:pt,viewMode:i,reviewedFiles:tt,onToggleReviewed:Dt,onCreateComment:()=>{Jt&&fi({fileIndex:Jt.fileIndex,chunkIndex:Jt.chunkIndex,lineIndex:Jt.lineIndex})},onCopyAllComments:()=>{de.length>0&&Ul()},onDeleteAllComments:()=>{de.length>0&&confirm("Delete all comments?")&&Ke()},onShowCommentsList:()=>{F(!0)},onRefresh:()=>{ro()}});A.useEffect(()=>{if(!e||!Jt)return;const re=e.files[Jt.fileIndex]?.path;!re||ae.has(re)||(Te(re),requestAnimationFrame(()=>{Vn(Jt)}))},[Jt,e,Te,ae,Vn]);const lo=A.useCallback((re,ve,Se,Qe)=>{Vn({fileIndex:re,chunkIndex:ve,lineIndex:Se,side:Qe})},[Vn]),ao=A.useCallback(()=>{fi(null)},[fi]),Gn=A.useCallback(re=>Me(re.id),[Me]),Tt=re=>{re.preventDefault(),z(!0);const ve=re.clientX,Se=x,Qe=St=>{const Bn=Math.max(Av,Math.min(Tv,Se+(St.clientX-ve)));S(Bn)},Ie=()=>{z(!1),document.removeEventListener("mousemove",Qe),document.removeEventListener("mouseup",Ie)};document.addEventListener("mousemove",Qe),document.addEventListener("mouseup",Ie)},wt=A.useCallback(async(re,ve)=>{try{const Se=new URLSearchParams({ignoreWhitespace:String(u)});re&&Se.set("base",re),ve&&Se.set("target",ve);const Qe=await fetch(`/api/diff?${Se}`);if(!Qe.ok)throw new Error("Failed to fetch diff data");const Ie=await Qe.json();if(r(Ie),Ie.baseCommitish&&te(Ie.baseCommitish),Ie.targetCommitish&&fe(Ie.targetCommitish),!ge.current){const St=Ie.requestedBaseCommitish??Ie.baseCommitish,Bn=Ie.requestedTargetCommitish??Ie.targetCommitish;St&&R(St),Bn&&q(Bn)}Ie.mode&&!o.current&&l(Ck(Ie.mode))}catch(Se){g(Se instanceof Error?Se.message:"Unknown error")}finally{h(!1)}},[u]);A.useEffect(()=>{wt()},[wt]),A.useEffect(()=>{me&&i!=="unified"&&l("unified")},[i,me]),A.useEffect(()=>{try{window.localStorage.setItem(Cv,String(x))}catch{}},[x]),A.useEffect(()=>{try{window.localStorage.setItem(Nv,String(E))}catch{}},[E]),A.useEffect(()=>{fetch("/api/revisions").then(re=>re.ok?re.json():null).then(re=>{M(re),re?.resolvedBase&&te(ve=>ve||re.resolvedBase||""),re?.resolvedTarget&&fe(ve=>ve||re.resolvedTarget||"")}).catch(()=>M(null))},[]);const rr=A.useCallback(async(re,ve)=>{re===V&&ve===D||(ge.current=!0,R(re),q(ve),h(!0),g(null),await wt(re,ve))},[V,D,wt]),Hi=A.useRef(!1);A.useEffect(()=>{e?.clearComments&&!Hi.current&&(Hi.current=!0,Ke(),nr(),console.log("✅ All existing comments and viewed files cleared as requested via --clean flag"))},[e?.clearComments,Ke,nr]),A.useEffect(()=>{e&&(tt.size<e.files.length?Z(!1):tt.size===e.files.length&&!O&&(L(!0),Z(!0),setTimeout(()=>{L(!1)},1e3)))},[tt.size,e,O]),A.useEffect(()=>{const re=JSON.stringify({comments:mt});fetch("/api/comments",{method:"POST",headers:{"Content-Type":"application/json"},body:re}).catch(Se=>{console.error("Failed to sync comments:",Se)});const ve=()=>{navigator.sendBeacon("/api/comments",re)};return window.addEventListener("beforeunload",ve),()=>{window.removeEventListener("beforeunload",ve)}},[mt]),A.useEffect(()=>{const re=new EventSource("/api/heartbeat");return re.onopen=()=>{console.log("Connected to server heartbeat")},re.onerror=()=>{console.log("Server connection lost"),re.close()},()=>{re.close()}},[]);const Cu=A.useCallback((re,ve,Se,Qe,Ie)=>(we({filePath:re,body:Se,side:Ie||"new",line:typeof ve=="number"?ve:{start:ve[0],end:ve[1]},codeSnapshot:Qe?{content:Qe,language:void 0}:void 0}),Promise.resolve()),[we]),Ul=async()=>{try{const re=It();await navigator.clipboard.writeText(re),v(!0),setTimeout(()=>v(!1),2e3)}catch(re){console.error("Failed to copy all comments prompt:",re)}},oo=re=>{if(!e)return;const ve=vR(re,e.files);ve&&Vn(ve)},hi=A.useCallback(async(re,ve)=>{try{const Se=await fetch("/api/open-in-editor",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filePath:re,line:ve,editor:ye.editor})});if(!Se.ok){const Qe=await Se.json().catch(()=>null);let Ie=Se.statusText;Qe&&typeof Qe=="object"&&"error"in Qe&&typeof Qe.error=="string"&&(Ie=Qe.error),console.error("Failed to open file in editor:",Ie)}}catch(Se){console.error("Failed to open file in editor:",Se)}},[ye.editor]),Hl=re=>{Vn(null);const ve=re.target,Se=ve.closest('[data-comment-button="true"]'),Qe=ve.closest('[data-open-in-editor-button="true"]');!Se&&!Qe&&Rr(re)},Rr=re=>{document.querySelectorAll('form[data-empty="true"]').forEach(Se=>{Se.contains(re.target)||Se.querySelector('button[type="button"]')?.click()})};if(f)return y.jsx("div",{className:"flex items-center justify-center h-screen bg-github-bg-primary",children:y.jsx("div",{className:"text-github-text-secondary text-base",children:"Loading diff..."})});if(p)return y.jsxs("div",{className:"flex flex-col items-center justify-center h-screen bg-github-bg-primary text-center gap-2",children:[y.jsx("h2",{className:"text-github-danger text-2xl mb-2",children:"Error"}),y.jsx("p",{className:"text-github-text-secondary text-base",children:p})]});if(!e)return y.jsxs("div",{className:"flex flex-col items-center justify-center h-screen bg-github-bg-primary text-center gap-2",children:[y.jsx("h2",{className:"text-github-danger text-2xl mb-2",children:"No data"}),y.jsx("p",{className:"text-github-text-secondary text-base",children:"No diff data available"})]});const _r=ye.editor!=="none"&&e.openInEditorAvailable!==!1;return y.jsx(_k,{children:y.jsxs("div",{className:"h-screen flex flex-col",onClickCapture:Hl,children:[y.jsxs("header",{className:`bg-github-bg-secondary border-b border-github-border flex ${me?"flex-col":"flex-row items-center"}`,children:[y.jsxs("div",{className:`flex items-center justify-between w-full ${me?"px-3 py-2 gap-3":"px-4 py-3 gap-4 w-auto"} ${j?"":"!transition-all !duration-300 !ease-in-out"}`,style:{width:me?"100%":E?`${x}px`:"auto",minWidth:me?"0px":E?"200px":"auto",maxWidth:me?"none":E?"600px":"none"},children:[y.jsx("h1",{children:y.jsx(Ij,{style:{height:"18px",color:"var(--color-github-text-secondary)"}})}),y.jsxs("div",{className:"flex items-center gap-1",children:[y.jsx("button",{onClick:()=>C(!E),className:"p-2 text-github-text-secondary hover:text-github-text-primary hover:bg-github-bg-tertiary rounded transition-colors",title:E?"Collapse file tree":"Expand file tree","aria-expanded":E,"aria-controls":"file-tree-panel","aria-label":"Toggle file tree panel",children:E?y.jsx(sk,{size:18}):y.jsx(ck,{size:18})}),y.jsx("button",{onClick:()=>N(!0),className:"p-2 text-github-text-secondary hover:text-github-text-primary hover:bg-github-bg-tertiary rounded transition-colors",title:"Appearance Settings",children:y.jsx(h1,{size:18})})]})]}),!me&&y.jsx("div",{className:`border-r border-github-border ${j?"":"!transition-all !duration-300 !ease-in-out"}`,style:{width:E?"4px":"0px",height:"calc(100% - 16px)",margin:"8px 0",transform:"translateX(-2px)"}}),y.jsxs("div",{className:`flex-1 flex flex-wrap items-center justify-between ${me?"px-3 pb-2 gap-3":"px-4 py-3 gap-4"}`,children:[y.jsxs("div",{className:`flex flex-wrap items-center ${me?"gap-2":"gap-3"}`,children:[!me&&y.jsxs("div",{className:"flex bg-github-bg-tertiary border border-github-border rounded-md p-1",children:[y.jsxs("button",{onClick:()=>gt("split"),className:`px-3 py-1.5 text-xs font-medium rounded transition-all duration-200 flex items-center gap-1.5 cursor-pointer ${i==="split"?"bg-github-bg-primary text-github-text-primary shadow-sm":"text-github-text-secondary hover:text-github-text-primary"}`,children:[y.jsx(F2,{size:14}),"Split"]}),y.jsxs("button",{onClick:()=>gt("unified"),className:`px-3 py-1.5 text-xs font-medium rounded transition-all duration-200 flex items-center gap-1.5 cursor-pointer ${i==="unified"?"bg-github-bg-primary text-github-text-primary shadow-sm":"text-github-text-secondary hover:text-github-text-primary"}`,children:[y.jsx(wk,{size:14}),"Unified"]})]}),y.jsx(p1,{checked:u,onChange:c,label:"Ignore Whitespace",title:u?"Show whitespace changes":"Ignore whitespace changes"}),y.jsx(Uj,{shouldReload:di,isReloading:Il.isReloading,onReload:ro,changeType:Il.lastChangeType,compact:me})]}),y.jsxs("div",{className:`flex flex-wrap items-center text-sm text-github-text-secondary ${me?"gap-3":"gap-4"}`,children:[!me&&de.length>0&&y.jsx(Kb,{commentsCount:de.length,isCopiedAll:b,onCopyAll:Ul,onDeleteAll:Ke,onViewAll:()=>F(!0)}),y.jsxs("div",{className:"flex flex-col gap-1 items-center",children:[y.jsxs("div",{className:"text-xs relative",children:[tt.size===e.files.length?"All diffs difit-ed!":`${tt.size} / ${e.files.length} files viewed`,y.jsx(Gj,{isActive:I})]}),y.jsx("div",{className:"relative h-2 bg-github-bg-tertiary rounded-full overflow-hidden",style:{width:"90px",border:"1px solid var(--color-github-border)"},children:y.jsx("div",{className:"absolute top-0 right-0 h-full transition-all duration-300 ease-out",style:{width:`${(e.files.length-tt.size)/e.files.length*100}%`,backgroundColor:(()=>{const re=(e.files.length-tt.size)/e.files.length*100;return re>50?"var(--color-github-accent)":re>20?"var(--color-github-warning)":"var(--color-github-danger)"})()}})})]}),X?y.jsx(Y3,{options:X,baseRevision:V,targetRevision:D,resolvedBaseRevision:T,resolvedTargetRevision:ie,onSelectDiff:(re,ve)=>{rr(re,ve)},onOpenAdvanced:()=>G(!0),compact:!xe}):y.jsxs("span",{className:"text-xs",children:["Reviewing:"," ",y.jsx("code",{className:"bg-github-bg-tertiary px-1.5 py-0.5 rounded text-xs text-github-text-primary",children:e.commit.includes("...")?y.jsxs(y.Fragment,{children:[y.jsxs("span",{className:"text-github-text-secondary font-medium",children:[e.commit.split("...")[0],"..."]}),y.jsx("span",{className:"font-medium",children:e.commit.split("...")[1]})]}):e.commit})]})]})]})]}),X&&y.jsx(Hj,{isOpen:H,onClose:()=>G(!1),options:X,baseRevision:V,targetRevision:D,resolvedBaseRevision:T,resolvedTargetRevision:ie,onApply:(re,ve)=>{rr(re,ve)}},H?`${V}:${D}`:"closed"),me&&E&&y.jsx("button",{type:"button","aria-label":"Close file tree",className:"fixed inset-0 bg-black/40 z-30",onClick:()=>C(!1)}),y.jsxs("div",{className:"flex flex-1 overflow-hidden relative",children:[y.jsx("div",{className:`relative overflow-hidden ${j?"":"!transition-all !duration-300 !ease-in-out"}`,style:{width:me?"0px":E?`${x}px`:"0px"},children:y.jsxs("aside",{id:"file-tree-panel",className:`bg-github-bg-secondary overflow-y-auto flex flex-col ${me?"fixed inset-y-0 right-0 z-40 w-[min(85vw,360px)] border-l border-github-border transition-transform duration-300 ease-out":"relative border-r border-github-border"}`,style:{width:me?"min(85vw, 360px)":`${x}px`,minWidth:me?"0px":"200px",maxWidth:me?"none":"600px",height:"100%",transform:me?E?"translateX(0)":"translateX(100%)":void 0},children:[y.jsx("div",{className:"flex-1 overflow-y-auto",children:y.jsx(zj,{files:e.files,onScrollToFile:Ve,onFileSelected:me?()=>C(!1):void 0,comments:de.map(re=>({id:re.id,file:re.filePath,line:typeof re.position.line=="number"?re.position.line:[re.position.line.start,re.position.line.end],body:re.body,timestamp:re.createdAt,codeContent:re.codeSnapshot?.content})),reviewedFiles:tt,onToggleReviewed:Dt,selectedFileIndex:Jt?.fileIndex??null})}),!me&&y.jsxs("div",{className:"p-4 border-t border-github-border flex justify-between items-center",children:[y.jsxs("button",{onClick:()=>Ui(!0),className:"flex items-center gap-1.5 text-github-text-secondary hover:text-github-text-primary transition-colors",title:"Keyboard shortcuts (Shift+?)",children:[y.jsx(tk,{size:16}),y.jsx("span",{className:"text-sm",children:"Shortcuts"})]}),y.jsxs("a",{href:"https://github.com/yoshiko-pg/difit",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-github-text-secondary hover:text-github-text-primary transition-colors",title:"View on GitHub",children:[y.jsx("span",{className:"text-sm",children:"Star on GitHub"}),y.jsx(Fj,{style:{height:"18px",width:"18px"}})]})]})]})}),!me&&y.jsx("div",{className:`bg-github-border hover:bg-github-text-muted cursor-col-resize ${j?"":"!transition-all !duration-300 !ease-in-out"}`,style:{width:E?"4px":"0px"},onMouseDown:Tt,title:"Drag to resize file list"}),y.jsx("main",{ref:B,className:`flex-1 overflow-y-auto ${Yt?"pb-16":""}`,children:e.files.map((re,ve)=>{const Se=Gt.get(re.path)??wR,Qe=Fn.get(re.path)??SR,Ie=ae.has(re.path);return y.jsx("div",{id:Os(re.path),"data-file-path":re.path,"data-rendered":Ie?"true":"false",ref:St=>Oe(re.path,St),className:"mb-6",children:Ie?y.jsx(Oj,{file:re,comments:Se,diffMode:i,reviewedFiles:tt,onToggleReviewed:Dt,collapsedFiles:Q,onToggleCollapsed:zn,onToggleAllCollapsed:Ot,onAddComment:Cu,onGeneratePrompt:Gn,onRemoveComment:Ee,onUpdateComment:Pe,onOpenInEditor:_r?hi:void 0,syntaxTheme:ye.syntaxTheme,baseCommitish:e.baseCommitish,targetCommitish:e.targetCommitish,cursor:Jt?.fileIndex===ve?Jt:null,fileIndex:ve,onLineClick:lo,commentTrigger:Bl?.fileIndex===ve?Bl:null,onCommentTriggerHandled:ao,mergedChunks:Qe,expandLines:Je,expandAllBetweenChunks:$n,prefetchFileContent:fn,isExpandLoading:Ut}):y.jsx("div",{className:"bg-github-bg-secondary border border-github-border rounded-md px-4 py-3",children:y.jsxs("div",{className:"flex items-center justify-between gap-3",children:[y.jsxs("div",{className:"min-w-0",children:[y.jsx("div",{className:"text-xs uppercase tracking-wide text-github-text-muted",children:"Deferred Rendering"}),y.jsx("div",{className:"text-sm font-mono text-github-text-primary truncate",children:re.path})]}),y.jsx("button",{type:"button",onClick:()=>be(re.path),className:"px-3 py-1.5 text-xs rounded border border-github-border text-github-text-secondary hover:text-github-text-primary hover:bg-github-bg-tertiary",children:"Load now"})]})})},re.path)})})]}),Yt&&y.jsx("div",{className:"fixed bottom-0 left-0 right-0 z-20 bg-github-bg-secondary border-t border-github-border px-4 py-2 flex justify-end",children:y.jsx(Kb,{commentsCount:de.length,isCopiedAll:b,onCopyAll:Ul,onDeleteAll:Ke,onViewAll:()=>F(!0),direction:"up",compact:!0})}),y.jsx(Vj,{isOpen:w,onClose:()=>N(!1),settings:ye,onSettingsChange:pe}),y.jsx(Bj,{isOpen:io,onClose:()=>Ui(!1)}),y.jsx(WE,{isOpen:$,onClose:()=>F(!1),onNavigate:oo,comments:de.map(re=>({id:re.id,file:re.filePath,line:typeof re.position.line=="number"?re.position.line:[re.position.line.start,re.position.line.end],body:re.body,timestamp:re.createdAt,codeContent:re.codeSnapshot?.content})),onRemoveComment:Ee,onGeneratePrompt:re=>Me(re.id),onUpdateComment:Pe,syntaxTheme:ye.syntaxTheme})]})})}const jv=document.getElementById("root");if(!jv)throw new Error("Root element not found");t2.createRoot(jv).render(y.jsx(Qt.StrictMode,{children:y.jsx(h2,{initiallyActiveScopes:["navigation"],children:y.jsx(CR,{})})}));export{Lt as _,NR as a,lu as g};
|