@loicngr/kobo 1.11.41 → 1.11.43
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/AGENTS.md +31 -0
- package/CHANGELOG.md +8 -0
- package/dist/server/routes/workspaces.js +4 -3
- package/dist/server/services/activity-service.js +3 -0
- package/dist/server/services/agent/engines/claude-code/engine.js +2 -0
- package/dist/server/services/agent/orchestrator.js +5 -11
- package/dist/server/services/settings-service.js +13 -0
- package/package.json +1 -1
- package/src/client/dist/pwa/assets/{ActivityFeed-DTIe6O9o.js → ActivityFeed-D1e-zV3O.js} +1 -1
- package/src/client/dist/pwa/assets/{ChangelogPage-BWeu0YeI.js → ChangelogPage-DX1WGFea.js} +1 -1
- package/src/client/dist/pwa/assets/{ComparisonPanel-o_EHlTwV.js → ComparisonPanel-B4ne55Xj.js} +1 -1
- package/src/client/dist/pwa/assets/CreatePage-Bx_GpUni.js +2 -0
- package/src/client/dist/pwa/assets/CreatePage-TY9g3hZb.css +1 -0
- package/src/client/dist/pwa/assets/{DashboardPage-CIo_gesD.js → DashboardPage-Cv6HJEcO.js} +1 -1
- package/src/client/dist/pwa/assets/{DiffViewer-DEcf48KI.js → DiffViewer-COwGxPt6.js} +3 -3
- package/src/client/dist/pwa/assets/{DocumentsPanel-D9vcB91W.js → DocumentsPanel-DCXpLLb7.js} +1 -1
- package/src/client/dist/pwa/assets/{DrawerToggleButton-Ca0_CxSl.js → DrawerToggleButton-DRL3RCkM.js} +1 -1
- package/src/client/dist/pwa/assets/GitPanel-C9mz4GXF.js +3 -0
- package/src/client/dist/pwa/assets/{HealthPage-_q3vy_xn.js → HealthPage-XrOuMoDJ.js} +1 -1
- package/src/client/dist/pwa/assets/{MainLayout-DxMVVA6f.css → MainLayout-BwV89R-l.css} +1 -1
- package/src/client/dist/pwa/assets/MainLayout-CwWavQjV.js +2 -0
- package/src/client/dist/pwa/assets/{QBtnDropdown-BeiZIHVA.js → QBtnDropdown-163oM6T_.js} +1 -1
- package/src/client/dist/pwa/assets/{QDrawer-Fj3M9QGD.js → QDrawer-DNEj8wLZ.js} +1 -1
- package/src/client/dist/pwa/assets/{QSelect-DtSUuK8t.js → QSelect-BUlOQe5k.js} +1 -1
- package/src/client/dist/pwa/assets/{QTooltip-DwkX8eQ6.js → QTooltip-BQWY7aeM.js} +1 -1
- package/src/client/dist/pwa/assets/{SchedulePanel-BlZDd7TK.js → SchedulePanel-Bos94OyR.js} +1 -1
- package/src/client/dist/pwa/assets/{SearchPage-BGi1yRxU.js → SearchPage-DOHkP5lj.js} +1 -1
- package/src/client/dist/pwa/assets/SettingsPage-DtGsd0XH.js +9 -0
- package/src/client/dist/pwa/assets/SettingsPage-W6N01tGz.css +1 -0
- package/src/client/dist/pwa/assets/{SplitWorkspacePage-vz6jN1DM.js → SplitWorkspacePage-DL4kp9Ah.js} +1 -1
- package/src/client/dist/pwa/assets/{TerminalPanel-IdPIGp2_.js → TerminalPanel-DHDnyiYh.js} +1 -1
- package/src/client/dist/pwa/assets/{TouchPan-DTJqxVp9.js → TouchPan-BnHXDR6F.js} +1 -1
- package/src/client/dist/pwa/assets/{TourReplayButton-Bj2GGyhU.js → TourReplayButton-ClVcB6mO.js} +1 -1
- package/src/client/dist/pwa/assets/{WorkspaceAttentionLabels-BBaGZlwv.js → WorkspaceAttentionLabels-Bxe6oIJI.js} +1 -1
- package/src/client/dist/pwa/assets/{WorkspacePage-Dy0spsfi.js → WorkspacePage-Clc4Fl3B.js} +3 -3
- package/src/client/dist/pwa/assets/{browser-BFj5wwbS.js → browser-Bkx4fbxl.js} +1 -1
- package/src/client/dist/pwa/assets/{build-path-tree-C-HSiySk.js → build-path-tree-BpSY7N5O.js} +1 -1
- package/src/client/dist/pwa/assets/{de-BdLe7apJ.js → de-BU0dILBs.js} +2 -2
- package/src/client/dist/pwa/assets/{documents-C2Xnjh9Z.js → documents-BIlWh3o-.js} +1 -1
- package/src/client/dist/pwa/assets/{editor.api-BbKfnNmv.js → editor.api-DreEG0If.js} +1 -1
- package/src/client/dist/pwa/assets/{efforts-BM7fdaaL.js → efforts-D_yTzymv.js} +1 -1
- package/src/client/dist/pwa/assets/{engineFeatures-b74YRODT.js → engineFeatures-C33LTVkK.js} +1 -1
- package/src/client/dist/pwa/assets/{es-C1LM-3aq.js → es-CNp0s9na.js} +2 -2
- package/src/client/dist/pwa/assets/{expand-template-DiDWiIkx.js → expand-template-wRhAXT-1.js} +1 -1
- package/src/client/dist/pwa/assets/{format-CnbUxAmw.js → format-B7z3F-Mw.js} +1 -1
- package/src/client/dist/pwa/assets/{formatters-B2uUIbAY.js → formatters-BTBiU0v3.js} +1 -1
- package/src/client/dist/pwa/assets/{fr-KCK6r5ga.js → fr-RqJyWSdm.js} +2 -2
- package/src/client/dist/pwa/assets/{freemarker2-Cu1vGY0x.js → freemarker2-BZNTVQ3K.js} +1 -1
- package/src/client/dist/pwa/assets/{handlebars-CETuqLyz.js → handlebars-k8tN0dI3.js} +1 -1
- package/src/client/dist/pwa/assets/{html-BTNpr39P.js → html-iZL3bbXq.js} +1 -1
- package/src/client/dist/pwa/assets/i18n--PCet00a.js +1 -0
- package/src/client/dist/pwa/assets/{index-mvh5w1cM.js → index-CPfrY38K.js} +3 -3
- package/src/client/dist/pwa/assets/{it-BM6t0IGU.js → it-DSxNuCwL.js} +2 -2
- package/src/client/dist/pwa/assets/{javascript-C7Ncb6V7.js → javascript-TV6gg0MO.js} +1 -1
- package/src/client/dist/pwa/assets/{liquid-D0hUdg4x.js → liquid-Cifa5ujF.js} +1 -1
- package/src/client/dist/pwa/assets/{mdx-BK5H1Xst.js → mdx-Bnj_8yGE.js} +1 -1
- package/src/client/dist/pwa/assets/{monaco-contributions-BBW6JNgz.js → monaco-contributions-pEh0n9Wk.js} +1 -1
- package/src/client/dist/pwa/assets/monaco.contribution-D7NmJUJH.js +2 -0
- package/src/client/dist/pwa/assets/{network-auth-CVGS__6a.js → network-auth-3_5p4fdc.js} +1 -1
- package/src/client/dist/pwa/assets/{notify-theme-DIKLxr8F.js → notify-theme-D_nf9AeF.js} +1 -1
- package/src/client/dist/pwa/assets/{pending-diff-open-B02zuH1j.js → pending-diff-open-CUnxC1xw.js} +1 -1
- package/src/client/dist/pwa/assets/{permissionModes-C3otN1Vk.js → permissionModes-DC51Pz84.js} +1 -1
- package/src/client/dist/pwa/assets/{project-color-BUcW_eZA.js → project-color-CihwpDAA.js} +1 -1
- package/src/client/dist/pwa/assets/{python-DEeUVvnp.js → python-DOoNBSNL.js} +1 -1
- package/src/client/dist/pwa/assets/{razor-CG6cL8ya.js → razor-Bvq5vVpJ.js} +1 -1
- package/src/client/dist/pwa/assets/{render-chat-markdown-Ct_T5TPN.js → render-chat-markdown-BQ_saiy5.js} +1 -1
- package/src/client/dist/pwa/assets/{typescript-CSQAg5UC.js → typescript-VVzxoeyM.js} +1 -1
- package/src/client/dist/pwa/assets/{use-tours-_6HwJ_Rp.js → use-tours-BKeYrJaQ.js} +1 -1
- package/src/client/dist/pwa/assets/{workspace-templates-B8WWsWEI.js → workspace-templates-1ui80Kqo.js} +1 -1
- package/src/client/dist/pwa/assets/{xml-BSB4-DXR.js → xml-CzGFIxQa.js} +1 -1
- package/src/client/dist/pwa/assets/{yaml-CSGKph85.js → yaml-Bl7nDJeC.js} +1 -1
- package/src/client/dist/pwa/index.html +1 -1
- package/src/client/dist/pwa/sw.js +1 -1
- package/src/client/dist/pwa/assets/CreatePage-CGi88k6z.css +0 -1
- package/src/client/dist/pwa/assets/CreatePage-DbY5gBv8.js +0 -2
- package/src/client/dist/pwa/assets/GitPanel-DCmB2R5i.js +0 -3
- package/src/client/dist/pwa/assets/MainLayout-Duwnq3cc.js +0 -2
- package/src/client/dist/pwa/assets/SettingsPage-DnO-ImWE.js +0 -9
- package/src/client/dist/pwa/assets/SettingsPage-sVlsJQ0b.css +0 -1
- package/src/client/dist/pwa/assets/i18n-BkUirOzl.js +0 -1
- package/src/client/dist/pwa/assets/monaco.contribution-1LZrAlY4.js +0 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
import{v as e}from"./reactivity.esm-bundler-DEJj9cFv.js";import{J as t,O as n,P as r,b as i,j as a}from"./runtime-core.esm-bundler-CDnVUfeZ.js";import{J as o,Y as s,tt as c,y as l}from"./QBtn-CZaBclNw.js";import{n as u}from"./pinia-BKqmoVru.js";import{It as d,Lt as f,Nt as p,Pt as m}from"./index-
|
|
1
|
+
import{v as e}from"./reactivity.esm-bundler-DEJj9cFv.js";import{J as t,O as n,P as r,b as i,j as a}from"./runtime-core.esm-bundler-CDnVUfeZ.js";import{J as o,Y as s,tt as c,y as l}from"./QBtn-CZaBclNw.js";import{n as u}from"./pinia-BKqmoVru.js";import{It as d,Lt as f,Nt as p,Pt as m}from"./index-CPfrY38K.js";var h=c({name:`QResizeObserver`,props:{debounce:{type:[String,Number],default:100}},emits:[`resize`],setup(e,{emit:t}){let o=null,c,l={width:-1,height:-1};function u(t){t===!0||e.debounce===0||e.debounce===`0`?d():o===null&&(o=setTimeout(d,e.debounce))}function d(){if(o!==null&&(clearTimeout(o),o=null),c){let{offsetWidth:e,offsetHeight:n}=c;(e!==l.width||n!==l.height)&&(l={width:e,height:n},t(`resize`,l))}}let{proxy:f}=i();f.trigger=u;let p,m=!1,h=e=>{m||(c=f.$el.parentNode,c?(p=new ResizeObserver(u),p.observe(c),d()):e||n(()=>{h(!0)}))};return r(()=>{h()}),a(()=>{m=!0,o!==null&&clearTimeout(o),p&&=(p.disconnect(),null)}),s}}),{passive:g}=o,_=[`both`,`horizontal`,`vertical`],v=c({name:`QScrollObserver`,props:{axis:{type:String,validator:e=>_.includes(e),default:`vertical`},debounce:[String,Number],scrollTarget:f},emits:[`scroll`],setup(e,{emit:n}){let o={position:{top:0,left:0},direction:`down`,directionChanged:!1,delta:{top:0,left:0},inflectionPoint:{top:0,left:0}},c=null,u,f;t(()=>e.scrollTarget,()=>{v(),_()});function h(){c?.();let t=Math.max(0,d(u)),r=p(u),i={top:t-o.position.top,left:r-o.position.left};if(e.axis===`vertical`&&i.top===0||e.axis===`horizontal`&&i.left===0)return;let a=Math.abs(i.top)>=Math.abs(i.left)?i.top<0?`up`:`down`:i.left<0?`left`:`right`;o.position={top:t,left:r},o.directionChanged=o.direction!==a,o.delta=i,o.directionChanged&&(o.direction=a,o.inflectionPoint=o.position),n(`scroll`,{...o})}function _(){u=m(f,e.scrollTarget),u.addEventListener(`scroll`,y,g),y(!0)}function v(){u!==void 0&&(u.removeEventListener(`scroll`,y,g),u=void 0)}function y(t){if(t===!0||e.debounce===0||e.debounce===`0`)h();else if(c===null){let[t,n]=e.debounce?[setTimeout(h,e.debounce),clearTimeout]:[requestAnimationFrame(h),cancelAnimationFrame];c=()=>{n(t),c=null}}}let{proxy:b}=i(),x=l();return t(()=>x.lang.rtl,h),r(()=>{f=b.$el.parentNode,_()}),a(()=>{c?.(),v()}),Object.assign(b,{trigger:y,getPosition:()=>o}),s}});function y(){let e=null;return{begin(){return e?.abort(),e=new AbortController,e.signal},isCurrent(t){return e!==null&&e.signal===t&&!t.aborted},abort(){e?.abort(),e=null}}}function b(e){return(e instanceof DOMException||typeof e==`object`&&!!e)&&e.name===`AbortError`}var x=u(`documents`,()=>{let t=e({}),n=e(!1),r=e(!1),i=e(null),a=e(0),o=y();function s(e){return t.value[e]??[]}async function c(e){n.value=!0;try{let n=await fetch(`/api/workspaces/${e}/documents`);if(!n.ok)throw Error(`HTTP ${n.status}`);let r=await n.json();t.value[e]=r.documents}catch(n){console.error(`[documents-store] fetchDocuments failed:`,n),t.value[e]=[]}finally{n.value=!1}}async function l(e,t){await u(e,t,o.begin())}async function u(e,t,n){r.value=!0;try{let r=await fetch(`/api/workspaces/${e}/document?path=${encodeURIComponent(t.path)}`,{signal:n});if(!r.ok)throw Error(`HTTP ${r.status}`);let a=await r.json();return o.isCurrent(n)?(i.value={path:a.path,name:t.name,content:a.content},!0):!1}catch(e){if(b(e)||!o.isCurrent(n))return!1;throw console.error(`[documents-store] openDocument failed:`,e),e}finally{o.isCurrent(n)&&(r.value=!1)}}async function d(e,n){let i=o.begin();try{let r=()=>(t.value[e]??[]).find(e=>e.path===n)??null,s=r();return s||=(await c(e),r()),!s||!o.isCurrent(i)||!await u(e,s,i)||!o.isCurrent(i)?!1:(a.value++,!0)}finally{o.isCurrent(i)&&(r.value=!1)}}function f(){o.abort(),r.value=!1,i.value=null}function p(e){delete t.value[e],f()}return{documentsByWorkspace:t,loadingList:n,loadingContent:r,selected:i,requestOpen:a,documentsFor:s,fetchDocuments:c,openDocument:l,openDocumentByPath:d,closeDocument:f,clearForWorkspace:p}});export{h as a,v as i,y as n,b as r,x as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{$a as e,$f as t,$i as n,$l as r,$m as i,$n as a,$o as o,$p as s,$t as c,Am as l,An as u,Ap as d,Ar as f,At as ee,B as te,Ba as p,Bc as m,Bd as h,Bi as g,Bl as _,Bp as ne,Bs as v,Bu as y,Cf as re,Ch as ie,Ci as ae,Cn as oe,Cp as se,Cr as ce,Cs as le,Cu as ue,D as de,Dc as fe,Dp as pe,Ec as me,Ef as he,Eh as ge,Ei as _e,El as ve,Em as ye,En as be,Ep as xe,Es as Se,Eu as Ce,Fc as b,Fd as we,Ff as Te,Fh as Ee,Fl as De,Fm as x,Fs as Oe,Fu as S,G as ke,Gd as Ae,Gf as je,Gh as Me,Gm as Ne,Gn as Pe,Gr as Fe,Gu as Ie,H as Le,Hd as Re,Hl as ze,Hm as C,Hn as Be,Hs as Ve,Hu as He,I as Ue,Ia as We,Ic as w,If as Ge,Ih as Ke,Il as qe,Im as T,Is as Je,Iu as Ye,J as Xe,Ja as Ze,Jd as Qe,Jf as $e,Jh as et,Jl as tt,Jm as nt,Jn as rt,Jr as it,K as at,Kd as ot,Kf as st,Kh as ct,Kl as lt,Kn as ut,Kp as dt,Kr as ft,Kt as pt,Ku as mt,La as ht,Lc as gt,Ld as _t,Lf as vt,Lh as yt,Li as bt,Lm as xt,Ln as St,Ls as Ct,Lt as wt,Lu as Tt,Mc as Et,Mi as Dt,Mn as Ot,Mo as kt,Mp as At,Mr as jt,Ms as Mt,Mu as E,N as Nt,Na as Pt,Nc as D,Nh as Ft,Nm as It,Nn as Lt,Np as Rt,Nr as zt,Ns as Bt,Oc as Vt,Oi as Ht,Ol as Ut,Op as Wt,Os as Gt,Ot as Kt,Pa as qt,Pc as Jt,Pd as Yt,Pm as Xt,Pn as Zt,Pp as Qt,Ps as $t,Pt as en,Qa as tn,Qc as nn,Qf as rn,Qh as an,Qi as on,Ql as sn,Qm as cn,Qr as ln,Qt as un,Qu as dn,Ra as fn,Rc as pn,Rd as O,Rf as mn,Rh as hn,Ri as gn,Rl as k,Rm as _n,Rn as vn,Rt as yn,Ru as bn,Sf as xn,Si as Sn,Sl as Cn,Sm as wn,Sn as Tn,So as En,Sp as Dn,Sr as On,Ss as kn,Su as An,Tc as jn,Th as Mn,Ti as Nn,Tl as Pn,Tn as Fn,Tp as In,Tt as Ln,Uc as Rn,Uf as zn,Ul as Bn,Um as A,Un as Vn,Va as Hn,Vf as Un,Vl as Wn,Vm as Gn,Vn as Kn,Vs as qn,Vu as Jn,W as Yn,Wa as Xn,Wc as Zn,Wd as Qn,Wf as $n,Wl as er,Wm as tr,Wt as nr,Wu as rr,Xa as ir,Xf as ar,Xi as or,Xm as j,Xo as sr,Xp as cr,Xr as lr,Xu as ur,Y as dr,Ya as fr,Yf as pr,Yh as mr,Yi as hr,Yl as gr,Ym as _r,Yr as vr,Za as yr,Zd as br,Zf as xr,Zh as Sr,Zl as Cr,Zm as wr,Zo as Tr,Zr as Er,_c as Dr,_d as M,_h as Or,_m as kr,_n as Ar,_o as jr,_p as Mr,_r as Nr,_t as Pr,_u as Fr,ac as Ir,af as Lr,al as Rr,am as zr,an as Br,ap as Vr,ar as Hr,bc as Ur,bd as Wr,bp as Gr,bu as Kr,cf as qr,ch as Jr,ci as Yr,cl as Xr,cm as Zr,cn as Qr,cp as $r,ct as ei,cu as ti,dd as ni,df as ri,dh as ii,di as ai,dl as oi,dn as si,dp as ci,dr as li,ds as ui,dt as di,ea as fi,ed as pi,eg as mi,eh as hi,ei as gi,em as N,en as _i,eo as vi,ep as yi,er as bi,eu as P,f as xi,fd as F,ff as Si,fh as I,fi as Ci,fm as wi,fn as Ti,fp as Ei,fr as Di,ft as Oi,fu as ki,g as Ai,gc as ji,gd as Mi,gh as Ni,gm as Pi,gn as Fi,gp as Ii,gs as Li,gt as Ri,hh as zi,hm as Bi,ho as Vi,hp as Hi,hr as Ui,hs as Wi,ht as Gi,hu as L,ia as Ki,if as qi,il as Ji,im as Yi,ip as Xi,ir as Zi,is as Qi,it as $i,iu as ea,jc as ta,ji as na,jl as ra,jm as ia,jp as aa,jr as oa,jt as sa,ju as R,kc as ca,ki as la,kl as ua,kp as da,kr as fa,kt as pa,ld as ma,lf as ha,lh as ga,lm as z,ln as _a,lp as va,lr as ya,lt as ba,lu as B,m as xa,md as Sa,mh as Ca,mm as wa,mn as Ta,mp as Ea,mr as Da,ms as Oa,mt as ka,mu as Aa,na as ja,nf as Ma,nn as Na,np as Pa,nr as Fa,nt as Ia,nu as La,of as Ra,oi as za,om as Ba,op as Va,or as Ha,ot as Ua,ou as V,pc as Wa,pf as Ga,pn as Ka,po as qa,pp as Ja,pr as Ya,pt as Xa,pu as Za,q as Qa,qc as $a,qd as eo,qf as to,ql as no,qm as ro,qt as io,qu as ao,rf as oo,rh as so,ri as co,rl as lo,rp as uo,rr as fo,ru as po,sd as mo,sf as ho,sl as go,sm as _o,sp as vo,sr as H,ss as yo,su as bo,t as xo,ta as So,td as Co,th as wo,ti as To,tm as Eo,tn as Do,to as Oo,tp as ko,tt as Ao,tu as jo,u as Mo,uc as No,uf as Po,uh as Fo,ul as Io,um as Lo,un as Ro,up as zo,ur as Bo,us as Vo,ut as Ho,uu as Uo,v as Wo,vc as Go,vl as Ko,vm as qo,vn as Jo,vp as Yo,vr as Xo,vs as Zo,vu as U,wc as Qo,wf as $o,wh as es,wi as ts,wl as ns,wm as rs,wn as is,wp as as,wr as os,ws as ss,wt as cs,xf as ls,xm as us,xn as ds,xp as fs,xs as ps,xu as ms,yd as hs,yi as gs,ym as _s,yn as vs,yp as ys,yt as bs,yu as xs,za as Ss,zc as Cs,zd as ws,zf as Ts,zl as W,zm as Es,zn as Ds,zp as Os,zs as G,zt as ks,zu as As}from"./format-CnbUxAmw.js";import{n as js}from"./SettingsPage-DnO-ImWE.js";function Ms(e,t,n){return new Ns(e,t,n)}var Ns=class extends Ct{constructor(e,t,n){super(n.worker,n.keepIdleModels||!1,e,t),this._foreignModuleHost=n.host||null,this._foreignProxy=this._getProxy().then(e=>new Proxy({},{get(t,n,r){if(n!==`then`){if(typeof n!=`string`)throw Error(`Not supported`);return(...t)=>e.$fmr(n,t)}}}))}fhr(e,t){if(!this._foreignModuleHost||typeof this._foreignModuleHost[e]!=`function`)return Promise.reject(Error(`Missing method `+e+` or missing main thread foreign host.`));try{return Promise.resolve(this._foreignModuleHost[e].apply(this._foreignModuleHost,t))}catch(e){return Promise.reject(e)}}getProxy(){return this._foreignProxy}withSyncedResources(e){return this.workerWithSyncedResources(e).then(e=>this.getProxy())}};function Ps(e){return Array.isArray(e)}function Fs(e){return!Ps(e)}function Is(e){return typeof e==`string`}function Ls(e){return!Is(e)}function Rs(e){return!e}function zs(e,t){return e.ignoreCase&&t?t.toLowerCase():t}function Bs(e){return e.replace(/[&<>'"_]/g,`-`)}function Vs(e,t){console.log(`${e.languageId}: ${t}`)}function K(e,t){return Error(`${e.languageId}: ${t}`)}function Hs(e,t,n,r,i){let a=/\$((\$)|(#)|(\d\d?)|[sS](\d\d?)|@(\w+))/g,o=null;return t.replace(a,function(t,a,s,c,l,u,d,f,ee){return Rs(s)?Rs(c)?!Rs(l)&&l<r.length?zs(e,r[l]):!Rs(d)&&e&&typeof e[d]==`string`?e[d]:(o===null&&(o=i.split(`.`),o.unshift(i)),!Rs(u)&&u<o.length?zs(e,o[u]):``):zs(e,n):`$`})}function Us(e,t,n){let r=/\$[sS](\d\d?)/g,i=null;return t.replace(r,function(t,r){return i===null&&(i=n.split(`.`),i.unshift(n)),!Rs(r)&&r<i.length?$o(zs(e,i[r])):``})}function Ws(e,t){let n=t;for(;n&&n.length>0;){let t=e.tokenizer[n];if(t)return t;let r=n.lastIndexOf(`.`);n=r<0?null:n.substr(0,r)}return null}function Gs(e,t){let n=t;for(;n&&n.length>0;){if(e.stateNames[n])return!0;let t=n.lastIndexOf(`.`);n=t<0?null:n.substr(0,t)}return!1}var Ks,qs,Js=function(e,t,n,r){var i=arguments.length,a=i<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,o;if(typeof Reflect==`object`&&typeof Reflect.decorate==`function`)a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a},Ys=function(e,t){return function(n,r){t(n,r,e)}},Xs,Zs=5,Qs=class{static create(e,t){return this._INSTANCE.create(e,t)}constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}create(e,t){if(e!==null&&e.depth>=this._maxCacheDepth)return new $s(e,t);let n=$s.getStackElementId(e);n.length>0&&(n+=`|`),n+=t;let r=this._entries[n];return r||(r=new $s(e,t),this._entries[n]=r,r)}};Ks=Qs,Ks._INSTANCE=new Ks(Zs);var $s=class e{constructor(e,t){this.parent=e,this.state=t,this.depth=(this.parent?this.parent.depth:0)+1}static getStackElementId(e){let t=``;for(;e!==null;)t.length>0&&(t+=`|`),t+=e.state,e=e.parent;return t}static _equals(e,t){for(;e!==null&&t!==null;){if(e===t)return!0;if(e.state!==t.state)return!1;e=e.parent,t=t.parent}return e===null&&t===null}equals(t){return e._equals(this,t)}push(e){return Qs.create(this,e)}pop(){return this.parent}popall(){let e=this;for(;e.parent;)e=e.parent;return e}switchTo(e){return Qs.create(this.parent,e)}},ec=class e{constructor(e,t){this.languageId=e,this.state=t}equals(e){return this.languageId===e.languageId&&this.state.equals(e.state)}clone(){return this.state.clone()===this.state?this:new e(this.languageId,this.state)}},tc=class{static create(e,t){return this._INSTANCE.create(e,t)}constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}create(e,t){if(t!==null||e!==null&&e.depth>=this._maxCacheDepth)return new nc(e,t);let n=$s.getStackElementId(e),r=this._entries[n];return r||(r=new nc(e,null),this._entries[n]=r,r)}};qs=tc,qs._INSTANCE=new qs(Zs);var nc=class e{constructor(e,t){this.stack=e,this.embeddedLanguageData=t}clone(){return(this.embeddedLanguageData?this.embeddedLanguageData.clone():null)===this.embeddedLanguageData?this:tc.create(this.stack,this.embeddedLanguageData)}equals(t){return!(t instanceof e)||!this.stack.equals(t.stack)?!1:this.embeddedLanguageData===null&&t.embeddedLanguageData===null?!0:this.embeddedLanguageData===null||t.embeddedLanguageData===null?!1:this.embeddedLanguageData.equals(t.embeddedLanguageData)}},rc=class{constructor(){this._tokens=[],this._languageId=null,this._lastTokenType=null,this._lastTokenLanguage=null}enterLanguage(e){this._languageId=e}emit(e,t){(this._lastTokenType!==t||this._lastTokenLanguage!==this._languageId)&&(this._lastTokenType=t,this._lastTokenLanguage=this._languageId,this._tokens.push(new s(e,t,this._languageId)))}nestedLanguageTokenize(e,t,n,r){let i=n.languageId,a=n.state,o=N.get(i);if(!o)return this.enterLanguage(i),this.emit(r,``),a;let c=o.tokenize(e,t,a);if(r!==0)for(let e of c.tokens)this._tokens.push(new s(e.offset+r,e.type,e.language));else this._tokens=this._tokens.concat(c.tokens);return this._lastTokenType=null,this._lastTokenLanguage=null,this._languageId=null,c.endState}finalize(e){return new Eo(this._tokens,e)}},ic=class e{constructor(e,t){this._languageService=e,this._theme=t,this._prependTokens=null,this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0}enterLanguage(e){this._currentLanguageId=this._languageService.languageIdCodec.encodeLanguageId(e)}emit(e,t){let n=this._theme.match(this._currentLanguageId,t)|1024;this._lastTokenMetadata!==n&&(this._lastTokenMetadata=n,this._tokens.push(e),this._tokens.push(n))}static _merge(e,t,n){let r=e===null?0:e.length,i=t.length,a=n===null?0:n.length;if(r===0&&i===0&&a===0)return new Uint32Array;if(r===0&&i===0)return n;if(i===0&&a===0)return e;let o=new Uint32Array(r+i+a);e!==null&&o.set(e);for(let e=0;e<i;e++)o[r+e]=t[e];return n!==null&&o.set(n,r+i),o}nestedLanguageTokenize(t,n,r,i){let a=r.languageId,o=r.state,s=N.get(a);if(!s)return this.enterLanguage(a),this.emit(i,``),o;let c=s.tokenizeEncoded(t,n,o);if(i!==0)for(let e=0,t=c.tokens.length;e<t;e+=2)c.tokens[e]+=i;return this._prependTokens=e._merge(this._prependTokens,this._tokens,c.tokens),this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0,c.endState}finalize(t){return new Os(e._merge(this._prependTokens,this._tokens,null),[],t)}},ac=Xs=class extends C{constructor(e,t,n,r,i){super(),this._configurationService=i,this._languageService=e,this._standaloneThemeService=t,this._languageId=n,this._lexer=r,this._embeddedLanguages=Object.create(null),this.embeddedLoaded=Promise.resolve(void 0);let a=!1;this._register(N.onDidChange(e=>{if(a)return;let t=!1;for(let n=0,r=e.changedLanguages.length;n<r;n++){let r=e.changedLanguages[n];if(this._embeddedLanguages[r]){t=!0;break}}t&&(a=!0,N.handleChange([this._languageId]),a=!1)})),this._maxTokenizationLineLength=this._configurationService.getValue(`editor.maxTokenizationLineLength`,{overrideIdentifier:this._languageId}),this._register(this._configurationService.onDidChangeConfiguration(e=>{e.affectsConfiguration(`editor.maxTokenizationLineLength`)&&(this._maxTokenizationLineLength=this._configurationService.getValue(`editor.maxTokenizationLineLength`,{overrideIdentifier:this._languageId}))}))}getLoadStatus(){let e=[];for(let t in this._embeddedLanguages){let n=N.get(t);if(n){if(n instanceof Xs){let t=n.getLoadStatus();t.loaded===!1&&e.push(t.promise)}continue}N.isResolved(t)||e.push(N.getOrCreate(t))}return e.length===0?{loaded:!0}:{loaded:!1,promise:Promise.all(e).then(e=>void 0)}}getInitialState(){let e=Qs.create(null,this._lexer.start);return tc.create(e,null)}tokenize(e,t,n){if(e.length>=this._maxTokenizationLineLength)return $t(this._languageId,n);let r=new rc,i=this._tokenize(e,t,n,r);return r.finalize(i)}tokenizeEncoded(e,t,n){if(e.length>=this._maxTokenizationLineLength)return Oe(this._languageService.languageIdCodec.encodeLanguageId(this._languageId),n);let r=new ic(this._languageService,this._standaloneThemeService.getColorTheme().tokenTheme),i=this._tokenize(e,t,n,r);return r.finalize(i)}_tokenize(e,t,n,r){return n.embeddedLanguageData?this._nestedTokenize(e,t,n,0,r):this._myTokenize(e,t,n,0,r)}_findLeavingNestedLanguageOffset(e,t){let n=this._lexer.tokenizer[t.stack.state];if(!n&&(n=Ws(this._lexer,t.stack.state),!n))throw K(this._lexer,`tokenizer state is not defined: `+t.stack.state);let r=-1,i=!1;for(let a of n){if(!Ls(a.action)||!(a.action.nextEmbedded===`@pop`||a.action.hasEmbeddedEndInCases))continue;i=!0;let n=a.resolveRegex(t.stack.state),o=n.source;if(o.substr(0,4)===`^(?:`&&o.substr(o.length-1,1)===`)`){let e=(n.ignoreCase?`i`:``)+(n.unicode?`u`:``);n=new RegExp(o.substr(4,o.length-5),e)}let s=e.search(n);s===-1||s!==0&&a.matchOnlyAtLineStart||(r===-1||s<r)&&(r=s)}if(!i)throw K(this._lexer,`no rule containing nextEmbedded: "@pop" in tokenizer embedded state: `+t.stack.state);return r}_nestedTokenize(e,t,n,r,i){let a=this._findLeavingNestedLanguageOffset(e,n);if(a===-1){let a=i.nestedLanguageTokenize(e,t,n.embeddedLanguageData,r);return tc.create(n.stack,new ec(n.embeddedLanguageData.languageId,a))}let o=e.substring(0,a);o.length>0&&i.nestedLanguageTokenize(o,!1,n.embeddedLanguageData,r);let s=e.substring(a);return this._myTokenize(s,t,n,r+a,i)}_safeRuleName(e){return e?e.name:`(unknown)`}_myTokenize(e,t,n,r,i){i.enterLanguage(this._languageId);let a=e.length,o=t&&this._lexer.includeLF?e+`
|
|
1
|
+
import{$a as e,$f as t,$i as n,$l as r,$m as i,$n as a,$o as o,$p as s,$t as c,Am as l,An as u,Ap as d,Ar as f,At as ee,B as te,Ba as p,Bc as m,Bd as h,Bi as g,Bl as _,Bp as ne,Bs as v,Bu as y,Cf as re,Ch as ie,Ci as ae,Cn as oe,Cp as se,Cr as ce,Cs as le,Cu as ue,D as de,Dc as fe,Dp as pe,Ec as me,Ef as he,Eh as ge,Ei as _e,El as ve,Em as ye,En as be,Ep as xe,Es as Se,Eu as Ce,Fc as b,Fd as we,Ff as Te,Fh as Ee,Fl as De,Fm as x,Fs as Oe,Fu as S,G as ke,Gd as Ae,Gf as je,Gh as Me,Gm as Ne,Gn as Pe,Gr as Fe,Gu as Ie,H as Le,Hd as Re,Hl as ze,Hm as C,Hn as Be,Hs as Ve,Hu as He,I as Ue,Ia as We,Ic as w,If as Ge,Ih as Ke,Il as qe,Im as T,Is as Je,Iu as Ye,J as Xe,Ja as Ze,Jd as Qe,Jf as $e,Jh as et,Jl as tt,Jm as nt,Jn as rt,Jr as it,K as at,Kd as ot,Kf as st,Kh as ct,Kl as lt,Kn as ut,Kp as dt,Kr as ft,Kt as pt,Ku as mt,La as ht,Lc as gt,Ld as _t,Lf as vt,Lh as yt,Li as bt,Lm as xt,Ln as St,Ls as Ct,Lt as wt,Lu as Tt,Mc as Et,Mi as Dt,Mn as Ot,Mo as kt,Mp as At,Mr as jt,Ms as Mt,Mu as E,N as Nt,Na as Pt,Nc as D,Nh as Ft,Nm as It,Nn as Lt,Np as Rt,Nr as zt,Ns as Bt,Oc as Vt,Oi as Ht,Ol as Ut,Op as Wt,Os as Gt,Ot as Kt,Pa as qt,Pc as Jt,Pd as Yt,Pm as Xt,Pn as Zt,Pp as Qt,Ps as $t,Pt as en,Qa as tn,Qc as nn,Qf as rn,Qh as an,Qi as on,Ql as sn,Qm as cn,Qr as ln,Qt as un,Qu as dn,Ra as fn,Rc as pn,Rd as O,Rf as mn,Rh as hn,Ri as gn,Rl as k,Rm as _n,Rn as vn,Rt as yn,Ru as bn,Sf as xn,Si as Sn,Sl as Cn,Sm as wn,Sn as Tn,So as En,Sp as Dn,Sr as On,Ss as kn,Su as An,Tc as jn,Th as Mn,Ti as Nn,Tl as Pn,Tn as Fn,Tp as In,Tt as Ln,Uc as Rn,Uf as zn,Ul as Bn,Um as A,Un as Vn,Va as Hn,Vf as Un,Vl as Wn,Vm as Gn,Vn as Kn,Vs as qn,Vu as Jn,W as Yn,Wa as Xn,Wc as Zn,Wd as Qn,Wf as $n,Wl as er,Wm as tr,Wt as nr,Wu as rr,Xa as ir,Xf as ar,Xi as or,Xm as j,Xo as sr,Xp as cr,Xr as lr,Xu as ur,Y as dr,Ya as fr,Yf as pr,Yh as mr,Yi as hr,Yl as gr,Ym as _r,Yr as vr,Za as yr,Zd as br,Zf as xr,Zh as Sr,Zl as Cr,Zm as wr,Zo as Tr,Zr as Er,_c as Dr,_d as M,_h as Or,_m as kr,_n as Ar,_o as jr,_p as Mr,_r as Nr,_t as Pr,_u as Fr,ac as Ir,af as Lr,al as Rr,am as zr,an as Br,ap as Vr,ar as Hr,bc as Ur,bd as Wr,bp as Gr,bu as Kr,cf as qr,ch as Jr,ci as Yr,cl as Xr,cm as Zr,cn as Qr,cp as $r,ct as ei,cu as ti,dd as ni,df as ri,dh as ii,di as ai,dl as oi,dn as si,dp as ci,dr as li,ds as ui,dt as di,ea as fi,ed as pi,eg as mi,eh as hi,ei as gi,em as N,en as _i,eo as vi,ep as yi,er as bi,eu as P,f as xi,fd as F,ff as Si,fh as I,fi as Ci,fm as wi,fn as Ti,fp as Ei,fr as Di,ft as Oi,fu as ki,g as Ai,gc as ji,gd as Mi,gh as Ni,gm as Pi,gn as Fi,gp as Ii,gs as Li,gt as Ri,hh as zi,hm as Bi,ho as Vi,hp as Hi,hr as Ui,hs as Wi,ht as Gi,hu as L,ia as Ki,if as qi,il as Ji,im as Yi,ip as Xi,ir as Zi,is as Qi,it as $i,iu as ea,jc as ta,ji as na,jl as ra,jm as ia,jp as aa,jr as oa,jt as sa,ju as R,kc as ca,ki as la,kl as ua,kp as da,kr as fa,kt as pa,ld as ma,lf as ha,lh as ga,lm as z,ln as _a,lp as va,lr as ya,lt as ba,lu as B,m as xa,md as Sa,mh as Ca,mm as wa,mn as Ta,mp as Ea,mr as Da,ms as Oa,mt as ka,mu as Aa,na as ja,nf as Ma,nn as Na,np as Pa,nr as Fa,nt as Ia,nu as La,of as Ra,oi as za,om as Ba,op as Va,or as Ha,ot as Ua,ou as V,pc as Wa,pf as Ga,pn as Ka,po as qa,pp as Ja,pr as Ya,pt as Xa,pu as Za,q as Qa,qc as $a,qd as eo,qf as to,ql as no,qm as ro,qt as io,qu as ao,rf as oo,rh as so,ri as co,rl as lo,rp as uo,rr as fo,ru as po,sd as mo,sf as ho,sl as go,sm as _o,sp as vo,sr as H,ss as yo,su as bo,t as xo,ta as So,td as Co,th as wo,ti as To,tm as Eo,tn as Do,to as Oo,tp as ko,tt as Ao,tu as jo,u as Mo,uc as No,uf as Po,uh as Fo,ul as Io,um as Lo,un as Ro,up as zo,ur as Bo,us as Vo,ut as Ho,uu as Uo,v as Wo,vc as Go,vl as Ko,vm as qo,vn as Jo,vp as Yo,vr as Xo,vs as Zo,vu as U,wc as Qo,wf as $o,wh as es,wi as ts,wl as ns,wm as rs,wn as is,wp as as,wr as os,ws as ss,wt as cs,xf as ls,xm as us,xn as ds,xp as fs,xs as ps,xu as ms,yd as hs,yi as gs,ym as _s,yn as vs,yp as ys,yt as bs,yu as xs,za as Ss,zc as Cs,zd as ws,zf as Ts,zl as W,zm as Es,zn as Ds,zp as Os,zs as G,zt as ks,zu as As}from"./format-B7z3F-Mw.js";import{n as js}from"./SettingsPage-DtGsd0XH.js";function Ms(e,t,n){return new Ns(e,t,n)}var Ns=class extends Ct{constructor(e,t,n){super(n.worker,n.keepIdleModels||!1,e,t),this._foreignModuleHost=n.host||null,this._foreignProxy=this._getProxy().then(e=>new Proxy({},{get(t,n,r){if(n!==`then`){if(typeof n!=`string`)throw Error(`Not supported`);return(...t)=>e.$fmr(n,t)}}}))}fhr(e,t){if(!this._foreignModuleHost||typeof this._foreignModuleHost[e]!=`function`)return Promise.reject(Error(`Missing method `+e+` or missing main thread foreign host.`));try{return Promise.resolve(this._foreignModuleHost[e].apply(this._foreignModuleHost,t))}catch(e){return Promise.reject(e)}}getProxy(){return this._foreignProxy}withSyncedResources(e){return this.workerWithSyncedResources(e).then(e=>this.getProxy())}};function Ps(e){return Array.isArray(e)}function Fs(e){return!Ps(e)}function Is(e){return typeof e==`string`}function Ls(e){return!Is(e)}function Rs(e){return!e}function zs(e,t){return e.ignoreCase&&t?t.toLowerCase():t}function Bs(e){return e.replace(/[&<>'"_]/g,`-`)}function Vs(e,t){console.log(`${e.languageId}: ${t}`)}function K(e,t){return Error(`${e.languageId}: ${t}`)}function Hs(e,t,n,r,i){let a=/\$((\$)|(#)|(\d\d?)|[sS](\d\d?)|@(\w+))/g,o=null;return t.replace(a,function(t,a,s,c,l,u,d,f,ee){return Rs(s)?Rs(c)?!Rs(l)&&l<r.length?zs(e,r[l]):!Rs(d)&&e&&typeof e[d]==`string`?e[d]:(o===null&&(o=i.split(`.`),o.unshift(i)),!Rs(u)&&u<o.length?zs(e,o[u]):``):zs(e,n):`$`})}function Us(e,t,n){let r=/\$[sS](\d\d?)/g,i=null;return t.replace(r,function(t,r){return i===null&&(i=n.split(`.`),i.unshift(n)),!Rs(r)&&r<i.length?$o(zs(e,i[r])):``})}function Ws(e,t){let n=t;for(;n&&n.length>0;){let t=e.tokenizer[n];if(t)return t;let r=n.lastIndexOf(`.`);n=r<0?null:n.substr(0,r)}return null}function Gs(e,t){let n=t;for(;n&&n.length>0;){if(e.stateNames[n])return!0;let t=n.lastIndexOf(`.`);n=t<0?null:n.substr(0,t)}return!1}var Ks,qs,Js=function(e,t,n,r){var i=arguments.length,a=i<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,o;if(typeof Reflect==`object`&&typeof Reflect.decorate==`function`)a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a},Ys=function(e,t){return function(n,r){t(n,r,e)}},Xs,Zs=5,Qs=class{static create(e,t){return this._INSTANCE.create(e,t)}constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}create(e,t){if(e!==null&&e.depth>=this._maxCacheDepth)return new $s(e,t);let n=$s.getStackElementId(e);n.length>0&&(n+=`|`),n+=t;let r=this._entries[n];return r||(r=new $s(e,t),this._entries[n]=r,r)}};Ks=Qs,Ks._INSTANCE=new Ks(Zs);var $s=class e{constructor(e,t){this.parent=e,this.state=t,this.depth=(this.parent?this.parent.depth:0)+1}static getStackElementId(e){let t=``;for(;e!==null;)t.length>0&&(t+=`|`),t+=e.state,e=e.parent;return t}static _equals(e,t){for(;e!==null&&t!==null;){if(e===t)return!0;if(e.state!==t.state)return!1;e=e.parent,t=t.parent}return e===null&&t===null}equals(t){return e._equals(this,t)}push(e){return Qs.create(this,e)}pop(){return this.parent}popall(){let e=this;for(;e.parent;)e=e.parent;return e}switchTo(e){return Qs.create(this.parent,e)}},ec=class e{constructor(e,t){this.languageId=e,this.state=t}equals(e){return this.languageId===e.languageId&&this.state.equals(e.state)}clone(){return this.state.clone()===this.state?this:new e(this.languageId,this.state)}},tc=class{static create(e,t){return this._INSTANCE.create(e,t)}constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}create(e,t){if(t!==null||e!==null&&e.depth>=this._maxCacheDepth)return new nc(e,t);let n=$s.getStackElementId(e),r=this._entries[n];return r||(r=new nc(e,null),this._entries[n]=r,r)}};qs=tc,qs._INSTANCE=new qs(Zs);var nc=class e{constructor(e,t){this.stack=e,this.embeddedLanguageData=t}clone(){return(this.embeddedLanguageData?this.embeddedLanguageData.clone():null)===this.embeddedLanguageData?this:tc.create(this.stack,this.embeddedLanguageData)}equals(t){return!(t instanceof e)||!this.stack.equals(t.stack)?!1:this.embeddedLanguageData===null&&t.embeddedLanguageData===null?!0:this.embeddedLanguageData===null||t.embeddedLanguageData===null?!1:this.embeddedLanguageData.equals(t.embeddedLanguageData)}},rc=class{constructor(){this._tokens=[],this._languageId=null,this._lastTokenType=null,this._lastTokenLanguage=null}enterLanguage(e){this._languageId=e}emit(e,t){(this._lastTokenType!==t||this._lastTokenLanguage!==this._languageId)&&(this._lastTokenType=t,this._lastTokenLanguage=this._languageId,this._tokens.push(new s(e,t,this._languageId)))}nestedLanguageTokenize(e,t,n,r){let i=n.languageId,a=n.state,o=N.get(i);if(!o)return this.enterLanguage(i),this.emit(r,``),a;let c=o.tokenize(e,t,a);if(r!==0)for(let e of c.tokens)this._tokens.push(new s(e.offset+r,e.type,e.language));else this._tokens=this._tokens.concat(c.tokens);return this._lastTokenType=null,this._lastTokenLanguage=null,this._languageId=null,c.endState}finalize(e){return new Eo(this._tokens,e)}},ic=class e{constructor(e,t){this._languageService=e,this._theme=t,this._prependTokens=null,this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0}enterLanguage(e){this._currentLanguageId=this._languageService.languageIdCodec.encodeLanguageId(e)}emit(e,t){let n=this._theme.match(this._currentLanguageId,t)|1024;this._lastTokenMetadata!==n&&(this._lastTokenMetadata=n,this._tokens.push(e),this._tokens.push(n))}static _merge(e,t,n){let r=e===null?0:e.length,i=t.length,a=n===null?0:n.length;if(r===0&&i===0&&a===0)return new Uint32Array;if(r===0&&i===0)return n;if(i===0&&a===0)return e;let o=new Uint32Array(r+i+a);e!==null&&o.set(e);for(let e=0;e<i;e++)o[r+e]=t[e];return n!==null&&o.set(n,r+i),o}nestedLanguageTokenize(t,n,r,i){let a=r.languageId,o=r.state,s=N.get(a);if(!s)return this.enterLanguage(a),this.emit(i,``),o;let c=s.tokenizeEncoded(t,n,o);if(i!==0)for(let e=0,t=c.tokens.length;e<t;e+=2)c.tokens[e]+=i;return this._prependTokens=e._merge(this._prependTokens,this._tokens,c.tokens),this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0,c.endState}finalize(t){return new Os(e._merge(this._prependTokens,this._tokens,null),[],t)}},ac=Xs=class extends C{constructor(e,t,n,r,i){super(),this._configurationService=i,this._languageService=e,this._standaloneThemeService=t,this._languageId=n,this._lexer=r,this._embeddedLanguages=Object.create(null),this.embeddedLoaded=Promise.resolve(void 0);let a=!1;this._register(N.onDidChange(e=>{if(a)return;let t=!1;for(let n=0,r=e.changedLanguages.length;n<r;n++){let r=e.changedLanguages[n];if(this._embeddedLanguages[r]){t=!0;break}}t&&(a=!0,N.handleChange([this._languageId]),a=!1)})),this._maxTokenizationLineLength=this._configurationService.getValue(`editor.maxTokenizationLineLength`,{overrideIdentifier:this._languageId}),this._register(this._configurationService.onDidChangeConfiguration(e=>{e.affectsConfiguration(`editor.maxTokenizationLineLength`)&&(this._maxTokenizationLineLength=this._configurationService.getValue(`editor.maxTokenizationLineLength`,{overrideIdentifier:this._languageId}))}))}getLoadStatus(){let e=[];for(let t in this._embeddedLanguages){let n=N.get(t);if(n){if(n instanceof Xs){let t=n.getLoadStatus();t.loaded===!1&&e.push(t.promise)}continue}N.isResolved(t)||e.push(N.getOrCreate(t))}return e.length===0?{loaded:!0}:{loaded:!1,promise:Promise.all(e).then(e=>void 0)}}getInitialState(){let e=Qs.create(null,this._lexer.start);return tc.create(e,null)}tokenize(e,t,n){if(e.length>=this._maxTokenizationLineLength)return $t(this._languageId,n);let r=new rc,i=this._tokenize(e,t,n,r);return r.finalize(i)}tokenizeEncoded(e,t,n){if(e.length>=this._maxTokenizationLineLength)return Oe(this._languageService.languageIdCodec.encodeLanguageId(this._languageId),n);let r=new ic(this._languageService,this._standaloneThemeService.getColorTheme().tokenTheme),i=this._tokenize(e,t,n,r);return r.finalize(i)}_tokenize(e,t,n,r){return n.embeddedLanguageData?this._nestedTokenize(e,t,n,0,r):this._myTokenize(e,t,n,0,r)}_findLeavingNestedLanguageOffset(e,t){let n=this._lexer.tokenizer[t.stack.state];if(!n&&(n=Ws(this._lexer,t.stack.state),!n))throw K(this._lexer,`tokenizer state is not defined: `+t.stack.state);let r=-1,i=!1;for(let a of n){if(!Ls(a.action)||!(a.action.nextEmbedded===`@pop`||a.action.hasEmbeddedEndInCases))continue;i=!0;let n=a.resolveRegex(t.stack.state),o=n.source;if(o.substr(0,4)===`^(?:`&&o.substr(o.length-1,1)===`)`){let e=(n.ignoreCase?`i`:``)+(n.unicode?`u`:``);n=new RegExp(o.substr(4,o.length-5),e)}let s=e.search(n);s===-1||s!==0&&a.matchOnlyAtLineStart||(r===-1||s<r)&&(r=s)}if(!i)throw K(this._lexer,`no rule containing nextEmbedded: "@pop" in tokenizer embedded state: `+t.stack.state);return r}_nestedTokenize(e,t,n,r,i){let a=this._findLeavingNestedLanguageOffset(e,n);if(a===-1){let a=i.nestedLanguageTokenize(e,t,n.embeddedLanguageData,r);return tc.create(n.stack,new ec(n.embeddedLanguageData.languageId,a))}let o=e.substring(0,a);o.length>0&&i.nestedLanguageTokenize(o,!1,n.embeddedLanguageData,r);let s=e.substring(a);return this._myTokenize(s,t,n,r+a,i)}_safeRuleName(e){return e?e.name:`(unknown)`}_myTokenize(e,t,n,r,i){i.enterLanguage(this._languageId);let a=e.length,o=t&&this._lexer.includeLF?e+`
|
|
2
2
|
`:e,s=o.length,c=n.embeddedLanguageData,l=n.stack,u=0,d=null,f=!0;for(;f||u<s;){let n=u,ee=l.depth,te=d?d.groups.length:0,p=l.state,m=null,h=null,g=null,_=null,ne=null;if(d){m=d.matches;let e=d.groups.shift();h=e.matched,g=e.action,_=d.rule,d.groups.length===0&&(d=null)}else{if(!f&&u>=s)break;f=!1;let e=this._lexer.tokenizer[p];if(!e&&(e=Ws(this._lexer,p),!e))throw K(this._lexer,`tokenizer state is not defined: `+p);let t=o.substr(u);for(let n of e)if((u===0||!n.matchOnlyAtLineStart)&&(m=t.match(n.resolveRegex(p)),m)){h=m[0],g=n.action;break}}if(m||(m=[``],h=``),g||=(u<s&&(m=[o.charAt(u)],h=m[0]),this._lexer.defaultToken),h===null)break;for(u+=h.length;Fs(g)&&Ls(g)&&g.test;)g=g.test(h,m,p,u===s);let v=null;if(typeof g==`string`||Array.isArray(g))v=g;else if(g.group)v=g.group;else if(g.token!==null&&g.token!==void 0){if(v=g.tokenSubst?Hs(this._lexer,g.token,h,m,p):g.token,g.nextEmbedded){if(g.nextEmbedded===`@pop`){if(!c)throw K(this._lexer,`cannot pop embedded language if not inside one`);c=null}else if(c)throw K(this._lexer,`cannot enter embedded language from within an embedded language`);else ne=Hs(this._lexer,g.nextEmbedded,h,m,p)}if(g.goBack&&(u=Math.max(0,u-g.goBack)),g.switchTo&&typeof g.switchTo==`string`){let e=Hs(this._lexer,g.switchTo,h,m,p);if(e[0]===`@`&&(e=e.substr(1)),Ws(this._lexer,e))l=l.switchTo(e);else throw K(this._lexer,`trying to switch to a state '`+e+`' that is undefined in rule: `+this._safeRuleName(_))}else if(g.transform&&typeof g.transform==`function`)throw K(this._lexer,`action.transform not supported`);else if(g.next){if(g.next===`@push`){if(l.depth>=this._lexer.maxStack)throw K(this._lexer,`maximum tokenizer stack size reached: [`+l.state+`,`+l.parent.state+`,...]`);l=l.push(p)}else if(g.next===`@pop`){if(l.depth<=1)throw K(this._lexer,`trying to pop an empty stack in rule: `+this._safeRuleName(_));l=l.pop()}else if(g.next===`@popall`)l=l.popall();else{let e=Hs(this._lexer,g.next,h,m,p);if(e[0]===`@`&&(e=e.substr(1)),Ws(this._lexer,e))l=l.push(e);else throw K(this._lexer,`trying to set a next state '`+e+`' that is undefined in rule: `+this._safeRuleName(_))}}g.log&&typeof g.log==`string`&&Vs(this._lexer,this._lexer.languageId+`: `+Hs(this._lexer,g.log,h,m,p))}if(v===null)throw K(this._lexer,`lexer rule has no well-defined action in rule: `+this._safeRuleName(_));let y=n=>{let a=this._languageService.getLanguageIdByLanguageName(n)||this._languageService.getLanguageIdByMimeType(n)||n,o=this._getNestedEmbeddedLanguageData(a);if(u<s){let n=e.substr(u);return this._nestedTokenize(n,t,tc.create(l,o),r+u,i)}return tc.create(l,o)};if(Array.isArray(v)){if(d&&d.groups.length>0)throw K(this._lexer,`groups cannot be nested: `+this._safeRuleName(_));if(m.length!==v.length+1)throw K(this._lexer,`matched number of groups does not match the number of actions in rule: `+this._safeRuleName(_));let e=0;for(let t=1;t<m.length;t++)e+=m[t].length;if(e!==h.length)throw K(this._lexer,`with groups, all characters should be matched in consecutive groups in rule: `+this._safeRuleName(_));d={rule:_,matches:m,groups:[]};for(let e=0;e<v.length;e++)d.groups[e]={action:v[e],matched:m[e+1]};u-=h.length;continue}{if(v===`@rematch`&&(u-=h.length,h=``,m=null,v=``,ne!==null))return y(ne);if(h.length===0){if(s===0||ee!==l.depth||p!==l.state||(d?d.groups.length:0)!==te)continue;throw K(this._lexer,`no progress in tokenizer in rule: `+this._safeRuleName(_))}let e=null;if(Is(v)&&v.indexOf(`@brackets`)===0){let t=v.substr(9),n=oc(this._lexer,h);if(!n)throw K(this._lexer,`@brackets token returned but no bracket defined as: `+h);e=Bs(n.token+t)}else e=Bs(v===``?``:v+this._lexer.tokenPostfix);n<a&&i.emit(n+r,e)}if(ne!==null)return y(ne)}return tc.create(l,c)}_getNestedEmbeddedLanguageData(e){if(!this._languageService.isRegisteredLanguageId(e))return new ec(e,Bt);e!==this._languageId&&(this._languageService.requestBasicLanguageFeatures(e),N.getOrCreate(e),this._embeddedLanguages[e]=!0);let t=N.get(e);return t?new ec(e,t.getInitialState()):new ec(e,Bt)}};ac=Xs=Js([Ys(4,w)],ac);function oc(e,t){if(!t)return null;t=zs(e,t);let n=e.brackets;for(let e of n)if(e.open===t)return{token:e.token,bracketType:1};else if(e.close===t)return{token:e.token,bracketType:-1};return null}var sc=Mt(`standaloneColorizer`,{createHTML:e=>e}),cc=class{static colorizeElement(e,t,n,r){r||={};let i=r.theme||`vs`,a=r.mimeType||n.getAttribute(`lang`)||n.getAttribute(`data-lang`);if(!a)return console.error(`Mode not detected`),Promise.resolve();let o=t.getLanguageIdByMimeType(a)||a;e.setTheme(i);let s=n.firstChild?n.firstChild.nodeValue:``;return n.className+=` `+i,this.colorize(t,s||``,o,r).then(e=>{n.innerHTML=sc?.createHTML(e)??e},e=>console.error(e))}static async colorize(e,t,n,r){let i=e.languageIdCodec,a=4;r&&typeof r.tabSize==`number`&&(a=r.tabSize),Ts(t)&&(t=t.substr(1));let o=mn(t);if(!e.isRegisteredLanguageId(n))return uc(o,a,i);let s=await N.getOrCreate(n);return s?lc(o,a,s,i):uc(o,a,i)}static colorizeLine(e,t,n,r,i=4){let a=le.isBasicASCII(e,t),o=le.containsRTL(e,a,n);return Se(new ss(!1,!0,e,!1,a,o,0,r,[],i,0,0,0,0,-1,`none`,!1,!1,null,null,0)).html}static colorizeModelLine(e,t,n=4){let r=e.getLineContent(t);e.tokenization.forceTokenization(t);let i=e.tokenization.getLineTokens(t).inflate();return this.colorizeLine(r,e.mightContainNonBasicASCII(),e.mightContainRTL(),i,n)}};function lc(e,t,n,r){return new Promise((i,a)=>{let o=()=>{let s=dc(e,t,n,r);if(n instanceof ac){let e=n.getLoadStatus();if(e.loaded===!1){e.promise.then(o,a);return}}i(s)};o()})}function uc(e,t,n){let r=[],i=new Uint32Array(2);i[0]=0,i[1]=33587200;for(let a=0,o=e.length;a<o;a++){let o=e[a];i[0]=o.length;let s=new Gt(i,o,n),c=le.isBasicASCII(o,!0),l=le.containsRTL(o,c,!0),u=Se(new ss(!1,!0,o,!1,c,l,0,s,[],t,0,0,0,0,-1,`none`,!1,!1,null,null,0));r=r.concat(u.html),r.push(`<br/>`)}return r.join(``)}function dc(e,t,n,r){let i=[],a=n.getInitialState();for(let o=0,s=e.length;o<s;o++){let s=e[o],c=n.tokenizeEncoded(s,!0,a);Gt.convertToEndOffset(c.tokens,s.length);let l=new Gt(c.tokens,s,r),u=le.isBasicASCII(s,!0),d=le.containsRTL(s,u,!0),f=Se(new ss(!1,!0,s,!1,u,d,0,l.inflate(),[],t,0,0,0,0,-1,`none`,!1,!1,null,null,0));i=i.concat(f.html),i.push(`<br/>`),a=c.endState}return i.join(``)}var fc=function(e,t,n,r){var i=arguments.length,a=i<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,o;if(typeof Reflect==`object`&&typeof Reflect.decorate==`function`)a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a},pc=function(e,t){return function(n,r){t(n,r,e)}},mc=V,hc=class extends fn{get _targetWindow(){return R(this._target.targetElements[0])}get _targetDocumentElement(){return R(this._target.targetElements[0]).document.documentElement}get isDisposed(){return this._isDisposed}get isMouseIn(){return this._lockMouseTracker.isMouseIn}get domNode(){return this._hover.containerDomNode}get onDispose(){return this._onDispose.event}get onRequestLayout(){return this._onRequestLayout.event}get anchor(){return this._hoverPosition===2?0:1}get x(){return this._x}get y(){return this._y}get isLocked(){return this._isLocked}set isLocked(e){this._isLocked!==e&&(this._isLocked=e,this._hoverContainer.classList.toggle(`locked`,this._isLocked))}addMouseTrackingElement(e){return this._lockMouseTracker.addElement(e)}constructor(e,t,n,r,i){if(super(),this._keybindingService=t,this._configurationService=n,this._markdownRenderer=r,this._accessibilityService=i,this._messageListeners=new A,this._isDisposed=!1,this._forcePosition=!1,this._x=0,this._y=0,this._isLocked=!1,this._enableFocusTraps=!1,this._addedFocusTrap=!1,this._maxHeightRatioRelativeToWindow=.5,this._onDispose=this._register(new x),this._onRequestLayout=this._register(new x),this._linkHandler=e.linkHandler,this._target=`targetElements`in e.target?e.target:new _c(e.target),e.style)switch(e.style){case 1:e.appearance??={},e.appearance.compact??=!0,e.appearance.showPointer??=!0;break;case 2:e.appearance??={},e.appearance.compact??=!0}this._hoverPointer=e.appearance?.showPointer?mc(`div.workbench-hover-pointer`):void 0,this._hover=this._register(new ft(!e.appearance?.skipFadeInAnimation)),this._hover.containerDomNode.classList.add(`workbench-hover`),e.appearance?.compact&&this._hover.containerDomNode.classList.add(`workbench-hover`,`compact`),this._hoverPointer&&this._hover.containerDomNode.classList.add(`with-pointer`),e.additionalClasses&&this._hover.containerDomNode.classList.add(...e.additionalClasses),e.position?.forcePosition&&(this._forcePosition=!0),e.trapFocus&&(this._enableFocusTraps=!0);let a=e.appearance?.maxHeightRatio;a!==void 0&&a>0&&a<=1&&(this._maxHeightRatioRelativeToWindow=a),this._hoverPosition=e.position?.hoverPosition===void 0?3:es(e.position.hoverPosition)?e.position.hoverPosition:2,this.onmousedown(this._hover.containerDomNode,e=>e.stopPropagation()),this.onkeydown(this._hover.containerDomNode,e=>{e.equals(9)&&this.dispose()}),this._register(L(this._targetWindow,`blur`,()=>this.dispose()));let o=mc(`div.hover-row.markdown-hover`),s=mc(`div.hover-contents`);if(typeof e.content==`string`)s.textContent=e.content,s.style.whiteSpace=`pre-wrap`;else if(y(e.content)){s.appendChild(e.content),s.classList.add(`html-hover-contents`);let t=new ResizeObserver(()=>{this.layout(),this._onRequestLayout.fire()});t.observe(s),this._register(j(()=>t.disconnect()))}else{let t=e.content,{element:n}=this._register(this._markdownRenderer.render(t,{actionHandler:this._linkHandler,asyncRenderCallback:()=>{s.classList.add(`code-hover-contents`),this.layout(),this._onRequestLayout.fire()}}));s.appendChild(n)}if(o.appendChild(s),this._hover.contentsDomNode.appendChild(o),e.actions&&e.actions.length>0){let t=mc(`div.hover-row.status-bar`),n=mc(`div.actions`);e.actions.forEach(e=>{let t=this._keybindingService.lookupKeybinding(e.commandId),r=t?t.getLabel():null;this._register(Fe.render(n,{label:e.label,commandId:e.commandId,run:t=>{e.run(t),this.dispose()},iconClass:e.iconClass},r))}),t.appendChild(n),this._hover.containerDomNode.appendChild(t)}this._hoverContainer=mc(`div.workbench-hover-container`),this._hoverPointer&&this._hoverContainer.appendChild(this._hoverPointer),this._hoverContainer.appendChild(this._hover.containerDomNode);let c;if(c=e.actions&&e.actions.length>0?!1:e.persistence?.hideOnHover===void 0?typeof e.content==`string`||fa(e.content)&&!e.content.value.includes(`](`)&&!e.content.value.includes(`</a>`):e.persistence.hideOnHover,e.appearance?.showHoverHint){let e=mc(`div.hover-row.status-bar`),t=mc(`div.info`);t.textContent=I(1761,`Hold {0} key to mouse over`,so?`Option`:`Alt`),e.appendChild(t),this._hover.containerDomNode.appendChild(e)}let l=[...this._target.targetElements];c||l.push(this._hoverContainer);let u=this._mouseTracker=this._register(new gc(l));if(this._register(u.onMouseOut(()=>{this._isLocked||this.dispose()})),c){let e=[...this._target.targetElements,this._hoverContainer];this._lockMouseTracker=this._register(new gc(e)),this._register(this._lockMouseTracker.onMouseOut(()=>{this._isLocked||this.dispose()}))}else this._lockMouseTracker=u}addFocusTrap(){if(!this._enableFocusTraps||this._addedFocusTrap)return;this._addedFocusTrap=!0;let e=this._hover.containerDomNode,t=this.findLastFocusableChild(this._hover.containerDomNode);if(t){let n=mt(this._hoverContainer,mc(`div`)),r=U(this._hoverContainer,mc(`div`));n.tabIndex=0,r.tabIndex=0,this._register(L(r,`focus`,t=>{e.focus(),t.preventDefault()})),this._register(L(n,`focus`,e=>{t.focus(),e.preventDefault()}))}}findLastFocusableChild(e){if(e.hasChildNodes())for(let t=0;t<e.childNodes.length;t++){let n=e.childNodes.item(e.childNodes.length-t-1);if(n.nodeType===n.ELEMENT_NODE){let e=n;if(typeof e.tabIndex==`number`&&e.tabIndex>=0)return e}let r=this.findLastFocusableChild(n);if(r)return r}}render(e){e.appendChild(this._hoverContainer);let t=this._hoverContainer.contains(this._hoverContainer.ownerDocument.activeElement)&&it(this._configurationService.getValue(`accessibility.verbosity.hover`)===!0&&this._accessibilityService.isScreenReaderOptimized(),this._keybindingService.lookupKeybinding(`editor.action.accessibleView`)?.getAriaLabel());t&&kn(t),this.layout(),this.addFocusTrap()}layout(){this._mouseTracker?.suppressPendingMouseOut(),this._lockMouseTracker!==this._mouseTracker&&this._lockMouseTracker?.suppressPendingMouseOut(),this._hover.containerDomNode.classList.remove(`right-aligned`),this._hover.contentsDomNode.style.maxHeight=``;let e=e=>{let t=Ce(e),n=e.getBoundingClientRect();return{top:n.top*t,bottom:n.bottom*t,right:n.right*t,left:n.left*t}},{top:t,right:n,bottom:r,left:i}=this._target.targetElements.map(t=>e(t))[0],a=n-i,o=r-t,s={top:t,right:n,bottom:r,left:i,width:a,height:o,center:{x:i+a/2,y:t+o/2}};if(this.adjustHorizontalHoverPosition(s),this.adjustVerticalHoverPosition(s),this.adjustHoverMaxHeight(s),this._hoverContainer.style.padding=``,this._hoverContainer.style.margin=``,this._hoverPointer){switch(this._hoverPosition){case 1:s.left+=3,s.right+=3,this._hoverContainer.style.paddingLeft=`3px`,this._hoverContainer.style.marginLeft=`-3px`;break;case 0:s.left-=3,s.right-=3,this._hoverContainer.style.paddingRight=`3px`,this._hoverContainer.style.marginRight=`-3px`;break;case 2:s.top+=3,s.bottom+=3,this._hoverContainer.style.paddingTop=`3px`,this._hoverContainer.style.marginTop=`-3px`;break;case 3:s.top-=3,s.bottom-=3,this._hoverContainer.style.paddingBottom=`3px`,this._hoverContainer.style.marginBottom=`-3px`}s.center.x=s.left+a/2,s.center.y=s.top+o/2}this.computeXCordinate(s),this.computeYCordinate(s),this._hoverPointer&&(this._hoverPointer.classList.remove(`top`),this._hoverPointer.classList.remove(`left`),this._hoverPointer.classList.remove(`right`),this._hoverPointer.classList.remove(`bottom`),this.setHoverPointerPosition(s)),this._hover.onContentsChanged()}computeXCordinate(e){let t=this._hover.containerDomNode.clientWidth+2;this._target.x===void 0?this._hoverPosition===1?this._x=e.right:this._hoverPosition===0?this._x=e.left-t:(this._x=this._hoverPointer?e.center.x-this._hover.containerDomNode.clientWidth/2:e.left,this._x+t>=this._targetDocumentElement.clientWidth&&(this._hover.containerDomNode.classList.add(`right-aligned`),this._x=Math.max(this._targetDocumentElement.clientWidth-t-2,this._targetDocumentElement.clientLeft))):this._x=this._target.x,this._x<this._targetDocumentElement.clientLeft&&(this._x=e.left+2)}computeYCordinate(e){this._y=this._target.y===void 0?this._hoverPosition===3?e.top:this._hoverPosition===2?e.bottom-2:this._hoverPointer?e.center.y+this._hover.containerDomNode.clientHeight/2:e.bottom:this._target.y,this._y>this._targetWindow.innerHeight&&(this._y=e.bottom)}adjustHorizontalHoverPosition(e){if(this._target.x!==void 0)return;let t=this._hoverPointer?3:0;if(this._forcePosition){let n=t+2;this._hoverPosition===1?this._hover.containerDomNode.style.maxWidth=`${this._targetDocumentElement.clientWidth-e.right-n}px`:this._hoverPosition===0&&(this._hover.containerDomNode.style.maxWidth=`${e.left-n}px`);return}this._hoverPosition===1?this._targetDocumentElement.clientWidth-e.right<this._hover.containerDomNode.clientWidth+t&&(this._hoverPosition=e.left>=this._hover.containerDomNode.clientWidth+t?0:2):this._hoverPosition===0&&(e.left<this._hover.containerDomNode.clientWidth+t&&(this._hoverPosition=this._targetDocumentElement.clientWidth-e.right>=this._hover.containerDomNode.clientWidth+t?1:2),e.left-this._hover.containerDomNode.clientWidth-t<=this._targetDocumentElement.clientLeft&&(this._hoverPosition=1))}adjustVerticalHoverPosition(e){if(this._target.y!==void 0||this._forcePosition)return;let t=this._hoverPointer?3:0;this._hoverPosition===3?e.top-this._hover.containerDomNode.clientHeight-t<0&&(this._hoverPosition=2):this._hoverPosition===2&&e.bottom+this._hover.containerDomNode.offsetHeight+t>this._targetWindow.innerHeight&&(this._hoverPosition=3)}adjustHoverMaxHeight(e){let t=this._targetWindow.innerHeight*this._maxHeightRatioRelativeToWindow;if(this._forcePosition){let n=(this._hoverPointer?3:0)+2;this._hoverPosition===3?t=Math.min(t,e.top-n):this._hoverPosition===2&&(t=Math.min(t,this._targetWindow.innerHeight-e.bottom-n))}if(this._hover.containerDomNode.style.maxHeight=`${t}px`,this._hover.contentsDomNode.clientHeight<this._hover.contentsDomNode.scrollHeight){let e=`${this._hover.scrollbar.options.verticalScrollbarSize}px`;this._hover.contentsDomNode.style.paddingRight!==e&&(this._hover.contentsDomNode.style.paddingRight=e)}}setHoverPointerPosition(e){if(this._hoverPointer)switch(this._hoverPosition){case 0:case 1:{this._hoverPointer.classList.add(this._hoverPosition===0?`right`:`left`);let t=this._hover.containerDomNode.clientHeight;t>e.height?this._hoverPointer.style.top=`${e.center.y-(this._y-t)-3}px`:this._hoverPointer.style.top=`${Math.round(t/2)-3}px`;break}case 3:case 2:{this._hoverPointer.classList.add(this._hoverPosition===3?`bottom`:`top`);let t=this._hover.containerDomNode.clientWidth,n=Math.round(t/2)-3,r=this._x+n;(r<e.left||r>e.right)&&(n=e.center.x-this._x-3),this._hoverPointer.style.left=`${n}px`;break}}}focus(){this._hover.containerDomNode.focus()}dispose(){this._isDisposed||(this._onDispose.fire(),this._target.dispose?.(),this._hoverContainer.remove(),this._messageListeners.dispose(),super.dispose()),this._isDisposed=!0}};hc=fc([pc(1,na),pc(2,w),pc(3,Ui),pc(4,Wi)],hc);var gc=class extends fn{get onMouseOut(){return this._onMouseOut.event}get isMouseIn(){return this._isMouseIn}constructor(e,t=200){super(),this._elements=e,this._eventDebounceDelay=t,this._isMouseIn=!0,this._suppressNextMouseOut=!1,this._mouseTimer=this._register(new Ne),this._onMouseOut=this._register(new x);for(let e of this._elements)this.onmouseover(e,()=>this._onTargetMouseOver()),this.onmouseleave(e,()=>this._onTargetMouseLeave())}_onTargetMouseOver(){this._isMouseIn=!0,this._suppressNextMouseOut=!1,this._mouseTimer.clear()}_onTargetMouseLeave(){this._isMouseIn=!1,this._mouseTimer.value=new Qe(()=>this._fireIfMouseOutside(),this._eventDebounceDelay)}_fireIfMouseOutside(){!this._isMouseIn&&!this._suppressNextMouseOut&&this._onMouseOut.fire()}suppressPendingMouseOut(){this._isMouseIn||(this._suppressNextMouseOut=!0)}addElement(e){if(this._elements.includes(e))return C.None;this._elements.push(e);let t=new A;return t.add(L(e,B.MOUSE_OVER,()=>this._onTargetMouseOver())),t.add(L(e,B.MOUSE_LEAVE,()=>this._onTargetMouseLeave())),t.add(j(()=>{let t=this._elements.indexOf(e);t>=0&&this._elements.splice(t,1)})),t}},_c=class{constructor(e){this._element=e,this.targetElements=[this._element]}dispose(){}};function vc(e){let t=e;return typeof t==`object`&&`markdown`in t&&`markdownNotSupportedFallback`in t}var yc=class{constructor(e,t,n){this.hoverDelegate=e,this.target=t,this.fadeInAnimation=n}async update(e,t,n){if(this._cancellationTokenSource&&=(this._cancellationTokenSource.dispose(!0),void 0),this.isDisposed)return;let r;if(ge(e)||y(e)||e===void 0)r=e;else{this._cancellationTokenSource=new _s;let i=this._cancellationTokenSource.token,a;if(a=vc(e)?ie(e.markdown)?e.markdown(i).then(t=>t??e.markdownNotSupportedFallback):e.markdown??e.markdownNotSupportedFallback:e.element(i),a instanceof Promise?(this._hoverWidget||this.show(I(1762,`Loading...`),t,n),r=await a):r=a,this.isDisposed||i.isCancellationRequested)return}this.show(r,t,n)}show(e,t,n){let r=this._hoverWidget;if(this.hasContent(e)){let i={content:e,target:this.target,actions:n?.actions,linkHandler:n?.linkHandler,trapFocus:n?.trapFocus,appearance:{showPointer:this.hoverDelegate.placement===`element`,skipFadeInAnimation:!this.fadeInAnimation||!!r,showHoverHint:n?.appearance?.showHoverHint},position:{hoverPosition:2}};this._hoverWidget=this.hoverDelegate.showHover(i,t)}r?.dispose()}hasContent(e){return e?!fa(e)||!!e.value:!1}get isDisposed(){return this._hoverWidget?.isDisposed}dispose(){this._hoverWidget?.dispose(),this._cancellationTokenSource?.dispose(!0),this._cancellationTokenSource=void 0}},bc=function(e,t,n,r){var i=arguments.length,a=i<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,o;if(typeof Reflect==`object`&&typeof Reflect.decorate==`function`)a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a},xc=function(e,t){return function(n,r){t(n,r,e)}},Sc=3,Cc=class extends C{get _currentHover(){return this._hoverStack.at(-1)?.hover}get _currentHoverOptions(){return this._hoverStack.at(-1)?.options}_getContainingHoverIndex(e){let t=y(e)?[e]:e.targetElements;for(let e=this._hoverStack.length-1;e>=0;e--)for(let n of t)if(S(n,this._hoverStack[e].hover.domNode))return e;return-1}constructor(e,t,n,r,i,a){super(),this._instantiationService=e,this._configurationService=t,this._keybindingService=r,this._layoutService=i,this._accessibilityService=a,this._hoverStack=[],this._currentDelayedHoverWasShown=!1,this._delayedHovers=new Map,this._managedHovers=new Map,this._register(n.onDidShowContextMenu(()=>this.hideHover())),this._register(De.registerCommandAndKeybindingRule({id:`workbench.action.showHover`,weight:0,primary:Bi(2089,2087),handler:()=>{this._showAndFocusHoverForActiveElement()}}))}showInstantHover(e,t,n,r){let i=this._createHover(e,n);if(i)return this._showHover(i,e,t),i.hover}showDelayedHover(e,t){if(e.id===void 0&&(e.id=Tc(e.content)),!this._currentDelayedHover||this._currentDelayedHoverWasShown){if(this._currentHover?.isLocked&&this._getContainingHoverIndex(e.target)<0)return;if(wc(this._currentHoverOptions)===wc(e))return this._currentHover;if(this._currentHover&&!this._currentHover.isDisposed&&this._currentDelayedHoverGroupId!==void 0&&this._currentDelayedHoverGroupId===t?.groupId)return this.showInstantHover({...e,appearance:{...e.appearance,skipFadeInAnimation:!0}})}else if(this._currentDelayedHover&&wc(this._currentHoverOptions)===wc(e))return this._currentDelayedHover;let n=this._createHover(e,void 0);if(!n){this._currentDelayedHover=void 0,this._currentDelayedHoverWasShown=!1,this._currentDelayedHoverGroupId=void 0;return}this._currentDelayedHover=n.hover,this._currentDelayedHoverWasShown=!1,this._currentDelayedHoverGroupId=t?.groupId;let r=t?.reducedDelay?this._configurationService.getValue(`workbench.hover.reducedDelay`):this._configurationService.getValue(`workbench.hover.delay`);return Ma(r).then(()=>{n.hover&&!n.hover.isDisposed&&(this._currentDelayedHoverWasShown=!0,this._showHover(n,e))}),n.hover}setupDelayedHover(e,t,n){return this._setupDelayedHover(e,n=>{let r={...typeof t==`function`?t():t,target:e};return r.style===2&&n&&(r.target=jc(e,n)),r},n)}setupDelayedHoverAtMouse(e,t,n){return this._setupDelayedHover(e,n=>({...typeof t==`function`?t():t,target:n?jc(e,n):e}),n)}_setupDelayedHover(e,t,n){let r=new A;return r.add(L(e,B.MOUSE_OVER,e=>{this.showDelayedHover(t(e),{groupId:n?.groupId,reducedDelay:n?.reducedDelay})})),n?.setupKeyboardEvents&&r.add(L(e,B.KEY_DOWN,e=>{let n=new qi(e);(n.equals(10)||n.equals(3))&&this.showInstantHover(t(),!0)})),this._delayedHovers.set(e,{show:e=>{this.showInstantHover(t(),e)}}),r.add(j(()=>this._delayedHovers.delete(e))),r}_createHover(e,t){if(this._currentDelayedHover?.dispose(),this._currentDelayedHover=void 0,e.content===``)return;if(e.id===void 0&&(e.id=Tc(e.content)),this._getContainingHoverIndex(e.target)>=0){if(this._hoverStack.length>=Sc)return}else if(this._currentHover?.isLocked||wc(this._currentHoverOptions)===wc(e))return;this._lastHoverOptions=e;let n=e.trapFocus||this._accessibilityService.isScreenReaderOptimized(),r=ms(),i;t||n&&r&&(r.classList.contains(`monaco-hover`)||(i=r));let a=new A,o=this._instantiationService.createInstance(hc,e);if(e.persistence?.sticky&&(o.isLocked=!0),e.position?.hoverPosition&&!es(e.position.hoverPosition)&&(e.target={targetElements:y(e.target)?[e.target]:e.target.targetElements,x:e.position.hoverPosition.x+10}),o.onDispose(()=>{let e=this._hoverStack.findIndex(e=>e.hover===o);if(e>=0){let t=this._hoverStack[e];for(Ye(o.domNode)&&t.lastFocusedElementBeforeOpen&&t.lastFocusedElementBeforeOpen.focus();this._hoverStack.length>e+1;){let e=this._hoverStack.pop();e.contextView.dispose(),e.hover.dispose()}this._hoverStack.splice(e,1),t.contextView.dispose()}a.dispose()},void 0,a),!e.container){let t=y(e.target)?e.target:e.target.targetElements[0];e.container=this._layoutService.getContainer(R(t))}if(a.add(L(R(e.container).document,B.MOUSE_DOWN,e=>{S(e.target,o.domNode)||this._hideHoverAndDescendants(o)})),!e.persistence?.sticky){if(`targetElements`in e.target)for(let t of e.target.targetElements)a.add(L(t,B.CLICK,()=>this._hideHoverAndDescendants(o)));else a.add(L(e.target,B.CLICK,()=>this._hideHoverAndDescendants(o)));let t=ms();if(t){let n=R(t).document;a.add(L(t,B.KEY_DOWN,t=>this._keyDown(t,o,!!e.persistence?.hideOnKeyDown))),a.add(L(n,B.KEY_DOWN,t=>this._keyDown(t,o,!!e.persistence?.hideOnKeyDown))),a.add(L(t,B.KEY_UP,e=>this._keyUp(e,o))),a.add(L(n,B.KEY_UP,e=>this._keyUp(e,o)))}}if(`IntersectionObserver`in zn){let t=new IntersectionObserver(e=>this._intersectionChange(e,o),{threshold:0}),n=`targetElements`in e.target?e.target.targetElements[0]:e.target;t.observe(n),a.add(j(()=>t.disconnect()))}return{hover:o,lastFocusedElementBeforeOpen:i,store:a}}_showHover(e,t,n){let{hover:r,lastFocusedElementBeforeOpen:i,store:a}=e,o=this._getContainingHoverIndex(t.target),s=o>=0;if(!s)this._hideAllHovers();else{for(let e=this._hoverStack.length-1;e>o;e--)this._hoverStack[e].hover.dispose();this._hoverStack.length=o+1}if(s)for(let e=0;e<=o;e++)a.add(this._hoverStack[e].hover.addMouseTrackingElement(r.domNode));let c=t.container??this._layoutService.getContainer(R(y(t.target)?t.target:t.target.targetElements[0])),l=new li(c,1),u={hover:r,options:t,contextView:l,lastFocusedElementBeforeOpen:i};this._hoverStack.push(u);let d=new Oc(r,n,this._hoverStack.length);if(l.show(d),a.add(r.onRequestLayout(()=>l.layout())),n||t.persistence?.sticky){let e=R(c);a.add(L(e,B.RESIZE,()=>l.layout()))}if(t.onDidHide){let e=t.onDidHide;a.add(j(()=>e()))}t.onDidShow?.()}_hideHoverAndDescendants(e){let t=this._hoverStack.findIndex(t=>t.hover===e);if(!(t<0)){for(let e=this._hoverStack.length-1;e>=t;e--)this._hoverStack[e].hover.dispose();this._hoverStack.length=t}}_hideAllHovers(){for(let e=this._hoverStack.length-1;e>=0;e--)this._hoverStack[e].hover.dispose();this._hoverStack.length=0}hideHover(e){this._hoverStack.length!==0&&(e||!this._currentHover?.isLocked)&&this.doHideHover()}doHideHover(){let e=this._hoverStack.length;this._hoverStack[e-1]?.hover.dispose(),this._hoverStack.length=e-1}_intersectionChange(e,t){e[e.length-1].isIntersecting||t.dispose()}showAndFocusLastHover(){this._lastHoverOptions&&this.showInstantHover(this._lastHoverOptions,!0,!0)}_showAndFocusHoverForActiveElement(){let e=ms();for(;e;){let t=this._delayedHovers.get(e)??this._managedHovers.get(e);if(t){t.show(!0);return}e=e.parentElement}}_keyDown(e,t,n){if(e.key===`Alt`){for(let e of this._hoverStack)e.hover.isLocked=!0;return}let r=new qi(e);if(!(this._keybindingService.resolveKeyboardEvent(r).getSingleModifierDispatchChords().some(e=>!!e)||this._keybindingService.softDispatch(r,r.target).kind!==0)&&n&&(!this._currentHoverOptions?.trapFocus||e.key!==`Tab`)){let e=this._hoverStack.find(e=>e.hover===t);this._hideHoverAndDescendants(t),e?.lastFocusedElementBeforeOpen?.focus()}}_keyUp(e,t){if(e.key===`Alt`){for(let e of this._hoverStack)e.options.persistence?.sticky||(e.hover.isLocked=!1);if(!this._hoverStack.some(e=>e.hover.isMouseIn)){let e=this._hoverStack[this._hoverStack.length-1];this._hideAllHovers(),e?.lastFocusedElementBeforeOpen?.focus()}}}setupManagedHover(e,t,n,r){if(e.showNativeHover)return Dc(t,n);t.setAttribute(`custom-hover`,`true`),t.title!==``&&(console.warn(`HTML element already has a title attribute, which will conflict with the custom hover. Please remove the title attribute.`),t.title=``);let i,a,o=(t,n)=>{let r=a!==void 0;t&&(a?.dispose(),a=void 0),n&&(i?.dispose(),i=void 0),r&&(e.onDidHideHover?.(),a=void 0)},s=(i,o,s,c)=>new Qe(async()=>{(!a||a.isDisposed)&&(a=new yc(e,s||t,i>0),await a.update(typeof n==`function`?n():n,o,{...r,trapFocus:c}))},i),c=new A,l=!1;c.add(L(t,B.MOUSE_DOWN,()=>{l=!0,o(!0,!0)},!0)),c.add(L(t,B.MOUSE_UP,()=>{l=!1},!0)),c.add(L(t,B.MOUSE_LEAVE,e=>{l=!1,o(!1,e.fromElement===t)},!0)),c.add(L(t,B.MOUSE_OVER,r=>{if(i)return;let a=new A,c={targetElements:[t],dispose:()=>{}};(e.placement===void 0||e.placement===`mouse`)&&a.add(L(t,B.MOUSE_MOVE,e=>{c.x=e.x+10,kc(e,t)||o(!0,!0)},!0)),i=a,kc(r,t)&&a.add(s(typeof e.delay==`function`?e.delay(n):e.delay,!1,c))},!0)),Tt(t)||c.add(L(t,B.FOCUS,r=>{if(l||i||(a?.isDisposed&&(a=void 0),y(r.relatedTarget)&&r.relatedTarget.closest(`.monaco-hover`)||!r.relatedTarget)||!kc(r,t))return;let c={targetElements:[t],dispose:()=>{}},u=new A;u.add(L(t,B.BLUR,()=>o(!0,!0),!0)),u.add(s(typeof e.delay==`function`?e.delay(n):e.delay,!1,c)),i=u},!0));let u={show:e=>{o(!1,!0),s(0,e,void 0,e)},hide:()=>{o(!0,!0)},update:async(e,t)=>{n=e,await a?.update(n,void 0,t)},dispose:()=>{this._managedHovers.delete(t),c.dispose(),o(!0,!0)}};return this._managedHovers.set(t,u),u}showManagedHover(e){let t=this._managedHovers.get(e);t&&t.show(!0)}dispose(){this._managedHovers.forEach(e=>e.dispose()),super.dispose()}};Cc=bc([xc(0,P),xc(1,w),xc(2,vr),xc(3,na),xc(4,Bo),xc(5,Wi)],Cc);function wc(e){if(e!==void 0)return e?.id??e}function Tc(e){if(!y(e))return typeof e==`string`?e.toString():e.value}function Ec(e){let t=typeof e==`function`?e():e;if(ge(t))return zt(t);if(vc(t))return t.markdownNotSupportedFallback}function Dc(e,t){function n(t){t?e.setAttribute(`title`,t):e.removeAttribute(`title`)}return n(Ec(t)),{update:e=>n(Ec(e)),show:()=>{},hide:()=>{},dispose:()=>n(void 0)}}var Oc=class{get anchorPosition(){return this._hover.anchor}constructor(e,t=!1,n=1){this._hover=e,this._focus=t,this.layer=n}render(e){return this._hover.render(e),this._focus&&this._hover.focus(),this._hover}getAnchor(){return{x:this._hover.x,y:this._hover.y}}layout(){this._hover.layout()}};function kc(e,t){return y(e.target)&&Ac(e.target,t)===t}function Ac(e,t){for(t??=R(e).document.body;!e.hasAttribute(`custom-hover`)&&e!==t;)e=e.parentElement;return e}function jc(e,t){return{targetElements:[e],x:t.x+10}}D(Er,Cc,1),So((e,t)=>{let n=e.getColor(kt);n&&(t.addRule(`.monaco-hover.workbench-hover .hover-row:not(:first-child):not(:empty) { border-top: 1px solid ${n.transparent(.5)}; }`),t.addRule(`.monaco-hover.workbench-hover hr { border-top: 1px solid ${n.transparent(.5)}; }`))});var Mc=function(e,t,n,r){var i=arguments.length,a=i<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,o;if(typeof Reflect==`object`&&typeof Reflect.decorate==`function`)a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a},Nc=function(e,t){return function(n,r){t(n,r,e)}};function Pc(e){return e.scheme===O.file?e.fsPath:e.path}var Fc=0,Ic=class{constructor(e,t,n,r,i,a,o){this.id=++Fc,this.type=0,this.actual=e,this.label=e.label,this.confirmBeforeUndo=e.confirmBeforeUndo||!1,this.resourceLabel=t,this.strResource=n,this.resourceLabels=[this.resourceLabel],this.strResources=[this.strResource],this.groupId=r,this.groupOrder=i,this.sourceId=a,this.sourceOrder=o,this.isValid=!0}setValid(e){this.isValid=e}toString(){return`[id:${this.id}] [group:${this.groupId}] [${this.isValid?` VALID`:`INVALID`}] ${this.actual.constructor.name} - ${this.actual}`}},Lc=class{constructor(e,t){this.resourceLabel=e,this.reason=t}},Rc=class{constructor(){this.elements=new Map}createMessage(){let e=[],t=[];for(let[,n]of this.elements)(n.reason===0?e:t).push(n.resourceLabel);let n=[];return e.length>0&&n.push(I(2099,`The following files have been closed and modified on disk: {0}.`,e.join(`, `))),t.length>0&&n.push(I(2100,`The following files have been modified in an incompatible way: {0}.`,t.join(`, `))),n.join(`
|
|
3
3
|
`)}get size(){return this.elements.size}has(e){return this.elements.has(e)}set(e,t){this.elements.set(e,t)}delete(e){return this.elements.delete(e)}},zc=class{constructor(e,t,n,r,i,a,o){this.id=++Fc,this.type=1,this.actual=e,this.label=e.label,this.confirmBeforeUndo=e.confirmBeforeUndo||!1,this.resourceLabels=t,this.strResources=n,this.groupId=r,this.groupOrder=i,this.sourceId=a,this.sourceOrder=o,this.removedResources=null,this.invalidatedResources=null}canSplit(){return typeof this.actual.split==`function`}removeResource(e,t,n){this.removedResources||=new Rc,this.removedResources.has(t)||this.removedResources.set(t,new Lc(e,n))}setValid(e,t,n){n?this.invalidatedResources&&(this.invalidatedResources.delete(t),this.invalidatedResources.size===0&&(this.invalidatedResources=null)):(this.invalidatedResources||=new Rc,this.invalidatedResources.has(t)||this.invalidatedResources.set(t,new Lc(e,0)))}toString(){return`[id:${this.id}] [group:${this.groupId}] [${this.invalidatedResources?`INVALID`:` VALID`}] ${this.actual.constructor.name} - ${this.actual}`}},Bc=class{constructor(e,t){this.resourceLabel=e,this.strResource=t,this._past=[],this._future=[],this.locked=!1,this.versionId=1}dispose(){for(let e of this._past)e.type===1&&e.removeResource(this.resourceLabel,this.strResource,0);for(let e of this._future)e.type===1&&e.removeResource(this.resourceLabel,this.strResource,0);this.versionId++}toString(){let e=[];e.push(`* ${this.strResource}:`);for(let t=0;t<this._past.length;t++)e.push(` * [UNDO] ${this._past[t]}`);for(let t=this._future.length-1;t>=0;t--)e.push(` * [REDO] ${this._future[t]}`);return e.join(`
|
|
4
4
|
`)}flushAllElements(){this._past=[],this._future=[],this.versionId++}_setElementValidFlag(e,t){e.type===1?e.setValid(this.resourceLabel,this.strResource,t):e.setValid(t)}setElementsValidFlag(e,t){for(let n of this._past)t(n.actual)&&this._setElementValidFlag(n,e);for(let n of this._future)t(n.actual)&&this._setElementValidFlag(n,e)}pushElement(e){for(let e of this._future)e.type===1&&e.removeResource(this.resourceLabel,this.strResource,1);this._future=[],this._past.push(e),this.versionId++}createSnapshot(e){let t=[];for(let e=0,n=this._past.length;e<n;e++)t.push(this._past[e].id);for(let e=this._future.length-1;e>=0;e--)t.push(this._future[e].id);return new ae(e,t)}restoreSnapshot(e){let t=e.elements.length,n=!0,r=0,i=-1;for(let a=0,o=this._past.length;a<o;a++,r++){let o=this._past[a];n&&(r>=t||o.id!==e.elements[r])&&(n=!1,i=a),!n&&o.type===1&&o.removeResource(this.resourceLabel,this.strResource,0)}let a=-1;for(let i=this._future.length-1;i>=0;i--,r++){let o=this._future[i];n&&(r>=t||o.id!==e.elements[r])&&(n=!1,a=i),!n&&o.type===1&&o.removeResource(this.resourceLabel,this.strResource,0)}i!==-1&&(this._past=this._past.slice(0,i)),a!==-1&&(this._future=this._future.slice(a+1)),this.versionId++}getElements(){let e=[],t=[];for(let t of this._past)e.push(t.actual);for(let e of this._future)t.push(e.actual);return{past:e,future:t}}getClosestPastElement(){return this._past.length===0?null:this._past[this._past.length-1]}getSecondClosestPastElement(){return this._past.length<2?null:this._past[this._past.length-2]}getClosestFutureElement(){return this._future.length===0?null:this._future[this._future.length-1]}hasPastElements(){return this._past.length>0}hasFutureElements(){return this._future.length>0}splitPastWorkspaceElement(e,t){for(let n=this._past.length-1;n>=0;n--)if(this._past[n]===e){t.has(this.strResource)?this._past[n]=t.get(this.strResource):this._past.splice(n,1);break}this.versionId++}splitFutureWorkspaceElement(e,t){for(let n=this._future.length-1;n>=0;n--)if(this._future[n]===e){t.has(this.strResource)?this._future[n]=t.get(this.strResource):this._future.splice(n,1);break}this.versionId++}moveBackward(e){this._past.pop(),this._future.push(e),this.versionId++}moveForward(e){this._future.pop(),this._past.push(e),this.versionId++}},Vc=class{constructor(e){this.editStacks=e,this._versionIds=[];for(let e=0,t=this.editStacks.length;e<t;e++)this._versionIds[e]=this.editStacks[e].versionId}isValid(){for(let e=0,t=this.editStacks.length;e<t;e++)if(this._versionIds[e]!==this.editStacks[e].versionId)return!1;return!0}},Hc=new Bc(``,``);Hc.locked=!0;var Uc=class{constructor(e,t){this._dialogService=e,this._notificationService=t,this._editStacks=new Map,this._uriComparisonKeyComputers=[]}getUriComparisonKey(e){for(let t of this._uriComparisonKeyComputers)if(t[0]===e.scheme)return t[1].getComparisonKey(e);return e.toString()}_print(e){console.log(`------------------------------------`),console.log(`AFTER ${e}: `);let t=[];for(let e of this._editStacks)t.push(e[1].toString());console.log(t.join(`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{v as e}from"./reactivity.esm-bundler-DEJj9cFv.js";import{C as t,J as n,b as r,i,l as a}from"./runtime-core.esm-bundler-CDnVUfeZ.js";import{J as o,Q as s,S as c,X as l,Y as u,at as d,ct as f,et as p,h as m,nt as h,q as g,y as _}from"./QBtn-CZaBclNw.js";import{C as ee}from"./use-id-BIuaWKkB.js";import{N as v}from"./index-
|
|
1
|
+
import{v as e}from"./reactivity.esm-bundler-DEJj9cFv.js";import{C as t,J as n,b as r,i,l as a}from"./runtime-core.esm-bundler-CDnVUfeZ.js";import{J as o,Q as s,S as c,X as l,Y as u,at as d,ct as f,et as p,h as m,nt as h,q as g,y as _}from"./QBtn-CZaBclNw.js";import{C as ee}from"./use-id-BIuaWKkB.js";import{N as v}from"./index-CPfrY38K.js";import{a as y,o as b}from"./QSelect-BUlOQe5k.js";import{u as x}from"./permissionModes-DC51Pz84.js";import{p as S}from"./use-tours-BKeYrJaQ.js";x(`superpowers`);function C(e,t){let n=["1. Call `kobo__list_tasks` FIRST to inspect any pre-existing tasks (they may have been seeded from Notion, a template, or the CreatePage form).","2. If tasks already exist: DO NOT delete or recreate them from scratch. Read each one, judge whether it is atomic and implementable in one session with clear completion criteria. Improve them in place:\n - Use `kobo__update_task` to rename unclear titles, add completion criteria, or flip `is_acceptance_criterion` when needed.\n - Use `kobo__create_task` to SPLIT a task that is too large into smaller atomic pieces (keep the original only if it still makes sense, otherwise update it to one of the split pieces and create the rest).\n - Use `kobo__create_task` to ADD missing acceptance criteria or missing implementation steps the plan requires.","3. If no tasks exist:\n - If a plan file exists in `docs/superpowers/plans/` or similar, read it and derive the task list from it.\n - If no plan exists, ask the user what the workspace goal is and propose tasks accordingly.\n - Create the tasks via `kobo__create_task`. For each task, decide `is_acceptance_criterion` appropriately."],r=4;if(e.framework){let t=e.skill?`Use the \`${e.skill}\` skill for this task. `:``,i=e.prompt?`Additional guidance: ${e.prompt}`:``;n.push(`${r}. **E2E review**: walk the task list and identify which tasks produce user-visible behavior (UI flows, form submissions, page renders, etc.). For each one that warrants regression coverage, INSERT a follow-up sub-task with title prefixed \`[E2E] \` describing the test to write. Place it in \`sort_order\` directly after the parent task. Skip tasks that don't produce user-visible behavior (refactors, infra, internal services) and briefly justify your choices in chat. The project uses \`${e.framework}\`. ${t}${i}`.trim()),r++}return t.prompt&&(n.push(`${r}. **Finalization task**: create ONE task with title prefixed \`[FINAL] <descriptive title>\`. Place it at the END of the task list (sort_order = max + 1, AFTER any [E2E] tasks). The agent will execute this task using the project's finalization prompt — do NOT inline the prompt content into the task title or description.`),r++),n.push(`${r}. Call \`kobo__mark_auto_loop_ready\`. This will automatically start the auto-loop, which will pick up the tasks one by one in fresh sessions.`),n.join(`
|
|
2
2
|
`)}var w=C({framework:``,skill:``,prompt:``},{prompt:``}),T="Hard rules:\n- Do NOT touch any source file. No Edit, no Write, no Bash that changes the repo.\n- Do NOT run `kill`, `pkill`, `killall`, `pgrep -k`, or any process-killing command — you may tear down the Kōbō server itself or sibling dev servers.\n- Do NOT start implementation even if a plan is ready — auto-loop will drive that afterwards, one task per iteration.\n- If the user asks for changes, re-apply via MCP and re-check. Do NOT mark ready until they approve.",E=`Review your progress on the tasks and acceptance criteria. Use the kobo-tasks MCP server: call list_tasks() to check the current status, then update any tasks you have completed using mark_task_done(). Report what is done and what remains.
|
|
3
3
|
|
|
4
4
|
Then suggest concrete next actions. Format them exactly like this so I can click on them:
|
package/src/client/dist/pwa/assets/{engineFeatures-b74YRODT.js → engineFeatures-C33LTVkK.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as e,ut as t}from"./reactivity.esm-bundler-DEJj9cFv.js";import{L as n,Y as r,_ as i,d as a,f as o,g as s,l as c,y as l}from"./runtime-core.esm-bundler-CDnVUfeZ.js";import{y as u}from"./QBtn-CZaBclNw.js";import{Tt as d,f,p}from"./index-
|
|
1
|
+
import{j as e,ut as t}from"./reactivity.esm-bundler-DEJj9cFv.js";import{L as n,Y as r,_ as i,d as a,f as o,g as s,l as c,y as l}from"./runtime-core.esm-bundler-CDnVUfeZ.js";import{y as u}from"./QBtn-CZaBclNw.js";import{Tt as d,f,p}from"./index-CPfrY38K.js";import{t as m}from"./QTooltip-BQWY7aeM.js";import{t as h}from"./QChip-owciRuZu.js";var g=l({__name:`AutoLoopChip`,props:{workspace:{default:null}},setup(l){let u=l,{t:f}=d(),g=p(),_=c(()=>u.workspace??g.selectedWorkspace),v=c(()=>_.value?.id??null),y=c(()=>v.value?g.autoLoopStates[v.value]??null:null),b=c(()=>!!y.value?.auto_loop),x=c(()=>!!y.value?.auto_loop_ready),S=c(()=>v.value!==null&&g.selectedWorkspaceId===v.value),C=c(()=>S.value?g.tasks.filter(e=>e.status===`done`).length:y.value?.tasks_done??0),w=c(()=>S.value?g.tasks.length:y.value?.tasks_total??0);return(c,l)=>b.value&&!x.value?(n(),a(h,{key:0,dense:``,square:``,size:`sm`,color:`primary`,"text-color":`white`,icon:`hourglass_top`,class:`q-ml-sm`},{default:r(()=>[s(t(e(f)(`autoLoop.preparing`))+` `,1),i(m,null,{default:r(()=>[s(t(e(f)(`autoLoop.preparingTooltip`)),1)]),_:1})]),_:1})):b.value?(n(),a(h,{key:1,dense:``,square:``,size:`sm`,color:`amber-9`,"text-color":`white`,icon:`autorenew`,class:`q-ml-sm`},{default:r(()=>[s(t(e(f)(`autoLoop.progress`,{done:C.value,total:w.value})),1)]),_:1})):o(``,!0)}});function _(e,t){if(e===``)return 0;let n=e.toLowerCase(),r=t.toLowerCase(),i=0,a=0,o=-2;for(let e of n){let t=-1;for(let n=a;n<r.length;n++)if(r[n]===e){t=n;break}if(t===-1)return null;i+=t===o+1?5:1;let n=t>0?r[t-1]:``;(t===0||n===`/`||n===`-`||n===`_`||n===`.`)&&(i+=2),o=t,a=t+1}return i-t.length*.01}function v(e,t,n,r=_){if(n<=0)return[];let i=[];for(let a of t){let t=r(e,a);if(t===null||i.length===n&&t<=i[n-1].score)continue;let o=i.length;for(;o>0&&i[o-1].score<t;)o--;i.splice(o,0,{item:a,score:t}),i.length>n&&i.pop()}return i.map(e=>e.item)}var y=new Set([`not-found`,`not-purged`,`workspace-busy`,`worktree-not-owned`,`project-unavailable`,`path-conflict`,`branch-in-use`,`recovery-source-unavailable`,`git-failed`]),b=`https://github.com/loicngr/kobo/blob/develop/CONFIGURATION.md#restoring-a-purged-workspace`;function x(){let e=p(),t=u(),{t:n}=d();async function r(r){if(!e.restoringWorktreeIds.includes(r))try{await e.restoreWorktree(r),t.notify({type:`positive`,message:n(`workspacePage.worktreeRestoreSuccess`),position:`top`})}catch(e){let r=e instanceof f&&e.code&&y.has(e.code)?e.code:`git-failed`;t.notify({type:`negative`,message:n(`workspacePage.restoreError.${r}`),position:`top`,actions:[{label:n(`common.details`),handler:()=>window.open(b,`_blank`,`noopener,noreferrer`)}]})}}return{restoreWorktree:r}}var S={"claude-code":!0,codex:!0};function C(e){return e?S[e]??!0:!0}var w={"claude-code":!0,codex:!0};function T(e){return e?w[e]??!0:!0}var E={"claude-code":!0,codex:!0};function D(e){return e?E[e]??!1:!1}export{_ as a,x as i,T as n,v as o,C as r,g as s,D as t};
|