@intent-hq/web 2.338.1 → 2.339.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/web/app/immutable/chunks/{CLQIdYtf.js → 0I_7-xCo.js} +1 -1
- package/web/app/immutable/chunks/{DTHIPERj.js → 5v9ikv92.js} +1 -1
- package/web/app/immutable/chunks/{Cf-4o0C1.js → Au0hWtsL.js} +1 -1
- package/web/app/immutable/chunks/{Bfrvy6-f.js → B1uiVPQp.js} +2 -2
- package/web/app/immutable/chunks/{CbQcBewU.js → B2oKa_KL.js} +1 -1
- package/web/app/immutable/chunks/{CNgujfRJ.js → B2ptswXi.js} +1 -1
- package/web/app/immutable/chunks/{BQyc6weN.js → B3lXfAYB.js} +1 -1
- package/web/app/immutable/chunks/{H4zMohfU.js → B5G6wWuw.js} +1 -1
- package/web/app/immutable/chunks/{Cp5oSwWa.js → BGkX168r.js} +1 -1
- package/web/app/immutable/chunks/{BF684udf.js → BHKtyyrU.js} +1 -1
- package/web/app/immutable/chunks/{BQBn6AXu.js → BMmnZrRK.js} +1 -1
- package/web/app/immutable/chunks/{19loSN7h.js → BNzcEYAv.js} +1 -1
- package/web/app/immutable/chunks/{BuszvIDw.js → BQFWbnKX.js} +1 -1
- package/web/app/immutable/chunks/{xp5T-On2.js → BSz7iMh-.js} +1 -1
- package/web/app/immutable/chunks/{tf5aM7kX.js → BXI_q7iH.js} +1 -1
- package/web/app/immutable/chunks/{BNcfl1rp.js → BXq8MrK-.js} +1 -1
- package/web/app/immutable/chunks/{BFVWCDsZ.js → B_KZeZEK.js} +2 -2
- package/web/app/immutable/chunks/{RXyByhXK.js → BaKsq-M0.js} +1 -1
- package/web/app/immutable/chunks/{Dj6MdpEs.js → BdexDGZC.js} +1 -1
- package/web/app/immutable/chunks/{--TzVA3S.js → BeWkh8MM.js} +1 -1
- package/web/app/immutable/chunks/{BzDIseIS.js → BgxG-ZbY.js} +1 -1
- package/web/app/immutable/chunks/{iqon4GjF.js → BjVpFYQh.js} +1 -1
- package/web/app/immutable/chunks/{BiO4t-Qa.js → Bn9hbI2n.js} +1 -1
- package/web/app/immutable/chunks/{DshMjQEH.js → BoZi94dx.js} +1 -1
- package/web/app/immutable/chunks/{DtMeGqJv.js → BppC6mQ0.js} +1 -1
- package/web/app/immutable/chunks/{Cuhz8j8n.js → Bq9XUSeR.js} +4 -4
- package/web/app/immutable/chunks/{sxMN8r-q.js → BwSUsmgc.js} +1 -1
- package/web/app/immutable/chunks/{CTUI81dg.js → BydiG0d-.js} +1 -1
- package/web/app/immutable/chunks/{w0BZ2tS8.js → Bzy3H4Dj.js} +1 -1
- package/web/app/immutable/chunks/{DhR-694R.js → C-kqAJdN.js} +1 -1
- package/web/app/immutable/chunks/{zUhkglmS.js → C0ty6diA.js} +1 -1
- package/web/app/immutable/chunks/{DbH_I5Yv.js → C1_Eiy41.js} +1 -1
- package/web/app/immutable/chunks/{CwjLA5I0.js → C470clpb.js} +1 -1
- package/web/app/immutable/chunks/{UGomc4DU.js → C6twmamI.js} +1 -1
- package/web/app/immutable/chunks/{CzrNrMOH.js → C8ZgE3Ef.js} +1 -1
- package/web/app/immutable/chunks/{Cry81AGu.js → CBbjFbMl.js} +1 -1
- package/web/app/immutable/chunks/{BHgKzDXJ.js → CHHRcO0U.js} +1 -1
- package/web/app/immutable/chunks/{CJvgWPEf.js → CHp1eiAD.js} +1 -1
- package/web/app/immutable/chunks/{D1PC1f77.js → CJDL5KAB.js} +1 -1
- package/web/app/immutable/chunks/{CUSDRtYF.js → CLmtrtu0.js} +3 -3
- package/web/app/immutable/chunks/{pwxUJrVV.js → CM--21b-.js} +1 -1
- package/web/app/immutable/chunks/{HzVNNtmZ.js → CM5jTQWQ.js} +1 -1
- package/web/app/immutable/chunks/{Bf86mLwh.js → CRfzx8hN.js} +1 -1
- package/web/app/immutable/chunks/{EjidVmY8.js → CSNmB1dB.js} +1 -1
- package/web/app/immutable/chunks/{DgFO9ngQ.js → CSbOZFUW.js} +4 -4
- package/web/app/immutable/chunks/{CG3d-0wy.js → CUGYrTNR.js} +1 -1
- package/web/app/immutable/chunks/{CmEf5a2p.js → CUdOnH55.js} +1 -1
- package/web/app/immutable/chunks/{DKcu5hwj.js → CUgHPOMw.js} +1 -1
- package/web/app/immutable/chunks/{BKx8D0hn.js → CV6ag4Z2.js} +3 -3
- package/web/app/immutable/chunks/{zKR5Yxu0.js → CVvPXkN9.js} +2 -2
- package/web/app/immutable/chunks/{Dihy2CGH.js → CWM1MkmG.js} +1 -1
- package/web/app/immutable/chunks/{BtAXkZJT.js → CWVZSsAO.js} +1 -1
- package/web/app/immutable/chunks/{9yebF5CG.js → CXEX3XJ7.js} +1 -1
- package/web/app/immutable/chunks/{Di_7c3Tz.js → CXqW8uvQ.js} +1 -1
- package/web/app/immutable/chunks/{CGFLlGKK.js → CdTX9MRt.js} +1 -1
- package/web/app/immutable/chunks/{D_E5w2vv.js → CefRoQA0.js} +2 -2
- package/web/app/immutable/chunks/{DnQqagmU.js → Cgtq62ns.js} +1 -1
- package/web/app/immutable/chunks/{QvSCvTgk.js → Cl5hJcBq.js} +1 -1
- package/web/app/immutable/chunks/{DgLaHMxU.js → CmRtKL7J.js} +2 -2
- package/web/app/immutable/chunks/{BBKBzeRB.js → Cr7oi_6d.js} +1 -1
- package/web/app/immutable/chunks/{BbxpiJV6.js → CtphhU9t.js} +1 -1
- package/web/app/immutable/chunks/{Dqq-QSMH.js → D-B0TDhB.js} +1 -1
- package/web/app/immutable/chunks/{DPkSGZl0.js → D0ZiBlxX.js} +1 -1
- package/web/app/immutable/chunks/{B7gpxSl6.js → D0ng0Qp3.js} +1 -1
- package/web/app/immutable/chunks/{c8OT2QUl.js → D17l7Hau.js} +1 -1
- package/web/app/immutable/chunks/{5v54BHUZ.js → D3gmaT9B.js} +2 -2
- package/web/app/immutable/chunks/{BaGPGwll.js → D3jGrF5f.js} +3 -3
- package/web/app/immutable/chunks/{DbIbkjr8.js → D4s1qtHE.js} +1 -1
- package/web/app/immutable/chunks/{DEIrZl-Q.js → D6t30n2k.js} +1 -1
- package/web/app/immutable/chunks/{BUHv-UKO.js → D8zipqK_.js} +1 -1
- package/web/app/immutable/chunks/{CpFmVP7v.js → DC9Z7l0D.js} +1 -1
- package/web/app/immutable/chunks/{CX7SaBcR.js → DDPajkKX.js} +1 -1
- package/web/app/immutable/chunks/{CAPelkZT.js → DKNImvko.js} +1 -1
- package/web/app/immutable/chunks/{DOcgdSXI.js → DOpgcKBl.js} +6 -6
- package/web/app/immutable/chunks/{vQ36nGYg.js → DQeJX3H2.js} +1 -1
- package/web/app/immutable/chunks/{DK5D4USl.js → DR5dualt.js} +1 -1
- package/web/app/immutable/chunks/{C_NbS-4j.js → DRETniPr.js} +1 -1
- package/web/app/immutable/chunks/{BD_WUy--.js → DReItNQ0.js} +1 -1
- package/web/app/immutable/chunks/{ertp7R3g.js → DSgf6WrM.js} +1 -1
- package/web/app/immutable/chunks/{WFVUS5Q2.js → DWBKmRqH.js} +3 -3
- package/web/app/immutable/chunks/{BabqdlUh.js → DZ9d4A89.js} +4 -4
- package/web/app/immutable/chunks/{D_B1cb64.js → D_MKhcgw.js} +2 -2
- package/web/app/immutable/chunks/{BC1IkzkM.js → DadKxQy4.js} +1 -1
- package/web/app/immutable/chunks/{Al5gKQhw.js → DdoNwoDc.js} +1 -1
- package/web/app/immutable/chunks/{DLwZ6u1z.js → DeE7Yu-u.js} +1 -1
- package/web/app/immutable/chunks/{QJ_UUVDw.js → Dgm9ZcOJ.js} +1 -1
- package/web/app/immutable/chunks/{wQ_gAJ8i.js → DiuUmAWK.js} +1 -1
- package/web/app/immutable/chunks/{CGL8_8zk.js → Diuox4Sk.js} +1 -1
- package/web/app/immutable/chunks/{dMMe6A0k.js → Dj-qJwHy.js} +1 -1
- package/web/app/immutable/chunks/{CCV8VTnq.js → DjgC2hXz.js} +1 -1
- package/web/app/immutable/chunks/{DPa-xfh8.js → DlHVJdRv.js} +1 -1
- package/web/app/immutable/chunks/{D00ZK3dW.js → DnReg1PV.js} +1 -1
- package/web/app/immutable/chunks/{-SRhLsfH.js → DnWiFr9y.js} +1 -1
- package/web/app/immutable/chunks/{QGaLfYnp.js → DogMW9-Y.js} +1 -1
- package/web/app/immutable/chunks/{CMgSs0m0.js → Dok3ev9f.js} +1 -1
- package/web/app/immutable/chunks/{QKfrd0hZ.js → DqNIHAkl.js} +1 -1
- package/web/app/immutable/chunks/{DibpUDFe.js → DsZcS3OV.js} +1 -1
- package/web/app/immutable/chunks/{C-U2Q_Ce.js → DtnhWRE7.js} +1 -1
- package/web/app/immutable/chunks/{B1_E9UBq.js → DuwE_WBW.js} +4 -4
- package/web/app/immutable/chunks/{CiQFOdPb.js → DyW-BzQH.js} +1 -1
- package/web/app/immutable/chunks/{Cg_TEGFC.js → EBBQIyEf.js} +1 -1
- package/web/app/immutable/chunks/{Cne24NXp.js → G_2OlhiX.js} +1 -1
- package/web/app/immutable/chunks/{l29U7LvB.js → HSOdfHfb.js} +1 -1
- package/web/app/immutable/chunks/{BgKtz5kX.js → Kb-14YoE.js} +1 -1
- package/web/app/immutable/chunks/{SO2ToTkD.js → L37ZHoZh.js} +1 -1
- package/web/app/immutable/chunks/{_mh_sREE.js → QiD34aXw.js} +1 -1
- package/web/app/immutable/chunks/{xE-qM4CT.js → THFf66AG.js} +1 -1
- package/web/app/immutable/chunks/{D15wv8Vo.js → Ul4pEuWS.js} +1 -1
- package/web/app/immutable/chunks/{jl7iZe2q.js → VPFPPS8j.js} +1 -1
- package/web/app/immutable/chunks/{DgnjMBuV.js → WFvI6B2R.js} +1 -1
- package/web/app/immutable/chunks/ZRfsqjSU.js +2 -0
- package/web/app/immutable/chunks/{BilYWCw8.js → a8iZfK0N.js} +1 -1
- package/web/app/immutable/chunks/{C0Md8A5J.js → aS_R0HPI.js} +12 -12
- package/web/app/immutable/chunks/{CvUjaEmJ.js → afGYXIhs.js} +1 -1
- package/web/app/immutable/chunks/{8UJuJS22.js → aure5QjZ.js} +3 -3
- package/web/app/immutable/chunks/{Dg7D-dnV.js → b6EhU_ki.js} +1 -1
- package/web/app/immutable/chunks/{DTmJTNN7.js → bjz7ui-s.js} +1 -1
- package/web/app/immutable/chunks/{CEsQleDv.js → cLU7lz0Y.js} +1 -1
- package/web/app/immutable/chunks/{vcNfRBrL.js → cfwIe6eK.js} +1 -1
- package/web/app/immutable/chunks/{DiqFqdjd.js → mXFQPvv9.js} +1 -1
- package/web/app/immutable/chunks/{DJ0y2dBB.js → sy_-vAI4.js} +1 -1
- package/web/app/immutable/chunks/{BsyYcfIA.js → u3DUtYLR.js} +1 -1
- package/web/app/immutable/entry/{app.BXrls4Qh.js → app.B_KnlZ7_.js} +2 -2
- package/web/app/immutable/entry/start.CeDpeSwJ.js +1 -0
- package/web/app/immutable/nodes/{0.Bdj8ZT8c.js → 0._RPyfxd1.js} +1 -1
- package/web/app/immutable/nodes/{1.Zl0F2Sz6.js → 1.D8xhl6AX.js} +1 -1
- package/web/app/immutable/nodes/{10.CNUk2b9P.js → 10.CarKEdYv.js} +1 -1
- package/web/app/immutable/nodes/{14.BiNIXgP0.js → 14.CyhsTzXV.js} +1 -1
- package/web/app/immutable/nodes/{17.DsIjUuTv.js → 17.DK0wbfgZ.js} +2 -2
- package/web/app/immutable/nodes/{2.DZVP3Lrs.js → 2.7MZhaj2M.js} +13 -13
- package/web/app/immutable/nodes/{3.DmYudxdL.js → 3.D-VEkgrC.js} +1 -1
- package/web/app/immutable/nodes/{4.C0P9sF9-.js → 4.DIJC3xOT.js} +1 -1
- package/web/app/immutable/nodes/5.C4j-D4y5.js +5 -0
- package/web/app/immutable/nodes/{6.CG_NYMUH.js → 6.BSD5IhCt.js} +1 -1
- package/web/app/immutable/nodes/{7.DEl0Oxtl.js → 7.VlQW7gKS.js} +1 -1
- package/web/app/immutable/nodes/{8.urQBqjSm.js → 8.BGFmcLEu.js} +4 -4
- package/web/app/immutable/nodes/{9.B_Whvp9_.js → 9.Bam4xxeU.js} +4 -4
- package/web/app/version.json +1 -1
- package/web/index.html +9 -9
- package/web/app/immutable/chunks/DccmXxha.js +0 -2
- package/web/app/immutable/entry/start.BvzRKINi.js +0 -1
- package/web/app/immutable/nodes/5.C8gznsC_.js +0 -5
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var $l=Object.defineProperty;var Ol=(r,t,n)=>t in r?$l(r,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):r[t]=n;var kn=(r,t,n)=>Ol(r,typeof t!="symbol"?t+"":t,n);import{t as It,br as g,a_ as B,bz as St,b as Tt,bp as f,bt as Kn,bv as dr,bu as ql,bs as ha}from"./Cv-W__h8.js";import{ai as aa,bs as Ct,ca as sr,aD as e,bH as j,ay as xe,bS as T,a7 as Rt,W as u,a5 as z,bA as R,bn as At,c9 as s,bV as we,aA as m,b_ as $,aj as Sr,aB as I,be as gr,b$ as Or,bO as J,bf as or,c0 as Cn,bl as oe,bj as jn,c6 as Dl,bo as za,br as Yr,am as Dn,ax as Bn,bk as as,aw as va,bz as ss,cb as ms,c5 as Ha,aC as xr,cd as _o,bv as Bl}from"./DYhIMPy1.js";import{n as Tr,u as te,v as ze,g as _n,s as ps,w as _a,j as kt,l as ar,p as Yn,I as Fl,i as ya,r as zl,o as eo,X as _i,q as Wl,S as Hl,C as Ul}from"./DPvDLGgX.js";import{I as Kt,F as qa,c as ea,j as jl,s as yi,p as to,y as Vl,u as Kl,t as $r,g as oa,B as ws,E as os,S as Gl}from"./j0KL2ItM.js";import{b as cn}from"./BaIAhI85.js";import{f as Xe,bj as Ql,am as ro,bt as Zl,bx as xs,bL as Jl}from"./BePtUMMB.js";import"./9s3slwY6.js";import"./Dj_1qKAG.js";import"./DUGj7TPr.js";import{s as Ln}from"./ClsZrb8B.js";import{F as jt,a0 as zs,bc as Tn,cF as no,aq as bi,aV as wi,aG as Xl,c4 as Yl,a2 as is,aJ as ed,cI as td,cH as rd,$ as vs,as as ao,I as yo,af as nd,bq as ad,aO as sd,aT as od,bF as id,ak as ld,cx as dd,ay as bo,aL as wo,bX as ks,aE as Ua,cR as cd,c6 as ud,bj as fd,b as gd,ck as md,ac as pd,b6 as Is,cm as xa,cA as vd,a as hd}from"./BKpkoMuv.js";import{c as xi,A as _d,x as yd}from"./D2pEu7en.js";import{b as Ss,V as xo}from"./CsScj5_e.js";import{a as ki,b7 as Pr,A as Ga,ao as Ii,s as bd,n as Si,d as wd,I as xd,R as kd,ax as Id,a0 as Sd}from"./BabqdlUh.js";import{bX as Ti,j as Qa,a6 as Ws,al as ls,F as Td,au as Za,aN as Cd,aQ as ko}from"./wQ_gAJ8i.js";import{t as ia,o as Ad}from"./2_iuLgF6.js";import{c3 as Ja,aC as Da,cQ as Ci,cS as Vn,bU as hs,j as Md,cJ as Ai,cP as _s,cO as Mi,cM as Pi,g as Nn,aa as Pd,ab as Rd,ax as Ed,s as Nd,K as Ld,W as Io,v as Ri,dO as $d,at as Od,k as qd,u as Ts,a6 as Dd,n as Bd,O as Fd,o as zd,S as Wd,R as Hd,a0 as Ud,q as Ei,r as Ni,l as jd,cT as Vd,a4 as Kd,D as Gd,x as Qd,V as So}from"./B10dK85Q.js";import{Ir as yt,oA as Zd,t8 as Xa,np as To,uY as Li,u_ as $i,rm as Jd,xU as ds,uf as Oi,nk as qi,be as Ya,xV as Xd,q0 as Yd,sF as ec,uR as Di,nj as tc,mq as rc,g as nc,yl as ac,yi as sc,yk as oc}from"./DBkMUdAo.js";import{a2 as ic,x as Cs,a0 as lc,O as As,V as dc,_ as cc,j as uc,o as ka,M as fa,p as fc,F as gc,u as mc,s as pc,L as Ms,J as vc,y as hc,K as _c,Z as Ma,Q as ja,N as Co,m as Ao,E as yc,c as Ps,B as Mo,z as bc,v as Po,H as Pa,P as wc,G as xc,i as kc,R as Ic,T as Sc,A as Tc,g as Cc,b as Ac,D as Mc,f as Pc,e as Rc,a as Ec,C as Nc,h as Lc,U as Bi,a3 as $c,t as Oc,k as qc,d as Ro}from"./8UJuJS22.js";import{i as Dc,e as Bc}from"./1o85IiDb.js";import{g as Rs}from"./BvFAWM27.js";import{M as Ia,C as Ra}from"./Cuhz8j8n.js";import{C as Eo}from"./BC1IkzkM.js";import"./CmEf5a2p.js";import{P as Fc}from"./DK5D4USl.js";import"./C9iBDSZ7.js";import{c as Fi}from"./ChTqQfQN.js";import{S as zc}from"./CvUjaEmJ.js";import{D as No,M as Wc}from"./B1_E9UBq.js";import{b as Hc,s as na,c as cs}from"./BQBn6AXu.js";import{O as es,y as Es,E as Ns,B as Ls,N as Uc,m as jc,l as Vc,d as us,C as Lo,f as Kc,e as Gc,g as Qc}from"./Dg7D-dnV.js";import{a as zi,s as $o}from"./BsieX9dN.js";import{f as Zc}from"./BdWqymET.js";import{c as dn}from"./CueFizU8.js";import{P as Jc}from"./BvDMLNjQ.js";import{q as $s,p as Os,z as Oo,h as Xc}from"./CGFLlGKK.js";import{R as Hs,C as ys,k as Yc,h as eu,g as tu,i as qo,P as ru}from"./DTDbZc--.js";import"./CgCdkhNg.js";import{R as Do,x as Na,o as Wi}from"./zKR5Yxu0.js";import{B as nu}from"./BlXsb3Tb.js";import{o as Hi,r as au,e as su}from"./D00ZK3dW.js";import{o as Ui}from"./DgLaHMxU.js";import{g as so}from"./CmUwI5cU.js";import{a as ou,M as iu}from"./BiLjH_HB.js";import{c as Sa}from"./D4os-974.js";import{A as lu}from"./D1PC1f77.js";import{f as du,d as cu}from"./pwxUJrVV.js";import{a8 as uu,N as fu,Y as gu,K as Bo,X as mu,v as pu}from"./WFVUS5Q2.js";import{a as vu}from"./CC7to1B5.js";import{G as hu}from"./GdlMbZRO.js";import{S as _u}from"./m03ON1WT.js";import{u as yu,a as bu,c as Fo,S as wu}from"./DfxQWSVU.js";import{T as Us}from"./BN_moS2U.js";import"./Czzc8yNT.js";import{g as xu}from"./B8IFnCn1.js";import{a as ku}from"./CkjMOvWd.js";import{b as Iu}from"./DAZ23kin.js";import{b as zo}from"./p7znhYIU.js";import{g as Su,i as Tu,a as Cu}from"./BZeUwBn0.js";import{n as Wo,o as Ho,b as ma,s as Ta,_ as qs,e as Au}from"./CIyUrgF0.js";import{aW as Un,B as Mu}from"./CUrYTyIw.js";import{y as Pu}from"./C3BW_tmx.js";import{c as Ru}from"./DOcgdSXI.js";function Eu(r){if(!r||typeof r!="object")return null;const t=r;if(t.type!=="script_monitor_wake"||t.source!=="system")return null;const{scriptName:n,scriptId:a,runId:o,monitorId:i,workspaceId:d,reason:c}=t;if(typeof n!="string"||typeof a!="string"||!a||typeof o!="string"||!o||typeof i!="string"||!i||typeof d!="string"||!d||c!=="finished"&&c!=="ttl-expired"&&c!=="output-match"&&c!=="line-count")return null;const v=t.trigger;return{scriptName:n,scriptId:a,runId:o,monitorId:i,workspaceId:d,reason:c,...c==="output-match"&&typeof v?.matchedLine=="string"?{matchedLine:v.matchedLine}:{}}}function Nu(r){return r?.type==="script_monitor_wake"&&!("remoteAgentId"in r)}function Lu(r,t,n,a=!1){if(!r||!t)return{edit:!1,remove:!1,sendNow:!1};const o=r.messageMetadata?.fromPrincipalId??r.author?.principalId,i=uu(r)&&r.author?.principalId!==null&&o===t;return{edit:i,remove:i||t===n||a,sendNow:(i||a)&&!ji(r)}}function Ca(r,t){if(t)return r.find(n=>n.editing&&n.editingMessageId?n.editingMessageId===t:n.id===t)}function ji(r){return Nu(r.messageMetadata)&&typeof r.messageMetadata?.monitorId=="string"}function Uo(r,t=Date.now()){const n=r.messageMetadata,a=n?.fromPrincipalId,o=n&&Object.hasOwn(n,"humanAuthor")&&!(typeof a=="string"&&a.length>0),i=r.holdKind!==void 0&&Date.parse(r.holdUntil??"")>t;return!r.editing&&!i&&!o&&!ji(r)}const j_="pl-3.5! pr-2!";var $u=I('<span class="tile-remove-slot svelte-d8pwpf"><!></span>'),jo=I('<span class="attachment-status svelte-d8pwpf"> </span>'),Ou=I('<div class="file-image tile svelte-d8pwpf" data-kind="file"><!> <!> <div class="tile-actions svelte-d8pwpf"><!> <!></div></div>'),qu=I("<!><span> </span>",1),Du=I('<img alt="" draggable="false"/>'),Bu=I('<span class="summary svelte-d8pwpf" data-clip-summary=""> </span>'),Fu=I('<span class="clip svelte-d8pwpf"><span class="record-dot svelte-d8pwpf" aria-hidden="true"></span><span class="duration svelte-d8pwpf"> </span><!></span>'),zu=I('<div class="tile svelte-d8pwpf"><!> <!> <div class="tile-actions svelte-d8pwpf"><!> <!></div></div>'),Wu=I('<div class="attachment-row svelte-d8pwpf" role="group" data-dock-media-attachments=""></div>'),Hu=I("<!> <!> <!>",1),Uu=I('<img draggable="false" class="svelte-d8pwpf"/>'),ju=I('<video controls="" playsinline="" class="svelte-d8pwpf"></video>',2),Vu=I('<div class="media-viewer svelte-d8pwpf"><!></div>'),Ku=I("<!> <!>",1);function Gu(r,t){if(new.target)return It({component:Gu,...r});Ct(t,!0);const n=(O,ye=or,pe=or)=>{var A=$u(),ge=z(A);Xe(ge,{variant:"secondary",size:"icon-sm",class:"tile-action tile-remove",get disabled(){return i()},get"aria-label"(){return pe()},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return pe()},onclick:()=>q(ye()),children:(Te,Be)=>{Ss(Te,{glyph:"x"})},$$slots:{default:!0}}),R(A),u(O,A)};let a=g(t,"items",7),o=g(t,"labels",7),i=g(t,"disabled",7,!1),d=g(t,"onMarkUp",7),c=g(t,"onEdit",7),v=g(t,"onRemove",7),h=g(t,"onRetry",7),b=g(t,"onCopy",7),k=g(t,"onMenu",7);const N=O=>O.owner==="attachment"?2:{image:0,clip:1,file:2}[O.kind],Y=s(()=>[...a()].sort((O,ye)=>N(O)-N(ye)));let S=we(null),D=we(!1),ie=we(null),X=null;const M=s(()=>a().find(O=>O.id===e(ie)));sr(()=>{(!e(M)||e(M).kind==="image"&&!W(e(M)))&&j(D,!1)});function W(O){return O.kind==="image"&&O.status!=="placing"&&O.status!=="failed"&&O.url.trim().length>0}function E(O){return O.kind==="image"?o().image(O.markCount):O.kind==="clip"?O.summary?`${o().clip(O.duration)} ${O.summary}`:o().clip(O.duration):O.name}function ne(O,ye){if(!(i()||O.kind==="file"||O.kind==="image"&&!W(O)||O.kind==="clip"&&(!O.url||O.recording))){if((O.kind==="clip"||O.kind==="image")&&c()){c()(O.id);return}X=ye,j(ie,O.id,!0),j(D,!0)}}async function q(O){i()||(e(ie)===O&&j(D,!1),v()(O),await Cn(),(!document.activeElement||document.activeElement===document.body)&&e(S)?.querySelector("button:not(:disabled)")?.focus())}function F(O){const ye=a().find(pe=>pe.id===O);i()||!ye||!W(ye)||(j(D,!1),c()?c()(O):d()(O))}function ae(O,ye){O.key!=="Delete"||i()||(O.preventDefault(),O.stopPropagation(),q(ye))}function C(O){return O.status==="placing"||O.status==="failed"?!1:O.kind==="image"?!!O.file||W(O):O.kind==="clip"&&!O.recording&&!!O.url}function ee(O,ye){const pe=Ql()?O.metaKey:O.ctrlKey,A=O.key.toLowerCase();if(pe&&!O.shiftKey&&!O.altKey&&(A==="c"||A==="x")){if(!b()||!C(ye)||(O.preventDefault(),O.stopPropagation(),A==="x"&&i()))return;b()(ye.id,A==="x");return}ae(O,ye.id)}function le(O,ye){!k()||!C(ye)||(O.preventDefault(),k()(ye.id))}var me={get items(){return a()},set items(O){a(O),m()},get labels(){return o()},set labels(O){o(O),m()},get disabled(){return i()},set disabled(O=!1){i(O),m()},get onMarkUp(){return d()},set onMarkUp(O){d(O),m()},get onEdit(){return c()},set onEdit(O){c(O),m()},get onRemove(){return v()},set onRemove(O){v(O),m()},get onRetry(){return h()},set onRetry(O){h(O),m()},get onCopy(){return b()},set onCopy(O){b(O),m()},get onMenu(){return k()},set onMenu(O){k(O),m()},$set:St,$on:(O,ye)=>Tt(t,O,ye)},_e=Ku(),Re=xe(_e);{var Le=O=>{var ye=Wu();Tr(ye,21,()=>e(Y),pe=>pe.id,(pe,A)=>{var ge=Rt(),Te=xe(ge);{var Be=P=>{var Q=Ou(),re=z(Q);{let G=s(()=>i()||e(A).status==="placing");ki(re,{get id(){return e(A).id},get name(){return e(A).file.name},get type(){return e(A).file.imageMimeType},get imageData(){return e(A).file.imageData},get imageMimeType(){return e(A).file.imageMimeType},variant:"thumbnail",thumbnailClass:"size-full",class:"size-full",get disabled(){return e(G)},get placementStatus(){return e(A).status},get placementError(){return e(A).error}})}var se=T(re,2);{var ce=G=>{var Ee=jo(),De=oe(Ee,!0);$(()=>{te(Ee,"data-failed",e(A).status==="failed"||void 0),te(Ee,"role",e(A).status==="failed"?"alert":"status"),te(Ee,"title",e(A).error),J(De,e(A).status==="failed"?e(A).error??o().attachmentFailed:o().attachmentPending)}),u(G,Ee)};B(se,G=>{e(A).status&&G(ce)})}var w=T(se,2),Se=z(w);{var Ae=G=>{Xe(G,{variant:"primary",size:"icon-sm",class:"tile-action",get disabled(){return i()},get"aria-label"(){return o().retry},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return o().retry},onclick:()=>h()?.(e(A).id),children:(Ee,De)=>{jt(Ee,{get icon(){return zs},size:16})},$$slots:{default:!0}})};B(Se,G=>{e(A).status==="failed"&&h()&&G(Ae)})}var L=T(Se,2);{let G=s(()=>f.chat_attachmentPreview_remove_ariaLabel({name:e(A).file.name}));n(L,()=>e(A).id,()=>e(G))}R(w),R(Q),$(()=>te(Q,"data-attachment-id",e(A).id)),Sr("keydown",Q,G=>ee(G,e(A))),Sr("contextmenu",Q,G=>le(G,e(A))),Kt(1,Q,()=>qa,()=>({tier:"fast",y:3,scale:.98})),Kt(2,Q,()=>ea,()=>({tier:"fast"})),u(P,Q)},Ce=P=>{const Q=s(()=>e(A).kind==="image"&&!W(e(A))&&e(A).status!=="failed");var re=zu(),se=z(re);{var ce=ve=>{Xe(ve,{type:"button",variant:"ghost",wrapContent:!1,class:"open-tile file",get"aria-label"(){return e(A).name},get disabled(){return i()},onkeydown:Oe=>ae(Oe,e(A).id),children:(Oe,U)=>{var ue=qu(),ot=xe(ue);jt(ot,{get icon(){return Tn},size:20});var xt=T(ot),mt=oe(xt,!0);$(()=>J(mt,e(A).name)),u(Oe,ue)},$$slots:{default:!0}})},w=ve=>{{let Oe=s(()=>E(e(A))),U=s(()=>i()||e(A).kind==="clip"&&(e(A).recording||!e(A).url));Xe(ve,{type:"button",variant:"ghost",wrapContent:!1,class:"open-tile",get"aria-label"(){return e(Oe)},get disabled(){return e(U)},onkeydown:ue=>ee(ue,e(A)),onclick:ue=>{ue.currentTarget instanceof HTMLElement&&ne(e(A),ue.currentTarget)},children:(ue,ot)=>{var xt=Rt(),mt=xe(xt);{var Ft=je=>{var bt=Du();$(()=>te(bt,"src",e(A).url)),u(je,bt)},pt=je=>{var bt=Fu(),at=T(z(bt)),dt=oe(at,!0),$e=T(at);{var ft=K=>{var _=Bu(),he=oe(_,!0);$(()=>J(he,e(A).summary)),u(K,_)};B($e,K=>{e(A).summary&&K(ft)})}R(bt),$(()=>J(dt,e(A).duration)),u(je,bt)};B(mt,je=>{e(A).kind==="image"?je(Ft):je(pt,-1)})}u(ue,xt)},$$slots:{default:!0}})}},Se=s(()=>e(A).kind!=="image"||W(e(A)));B(se,ve=>{e(A).kind==="file"?ve(ce):e(Se)&&ve(w,1)})}var Ae=T(se,2);{var L=ve=>{var Oe=jo(),U=oe(Oe,!0);$(()=>{te(Oe,"data-failed",e(A).status==="failed"||void 0),te(Oe,"role",e(A).status==="failed"?"alert":"status"),te(Oe,"title",e(A).error),J(U,e(A).status==="failed"?e(A).error??o().attachmentFailed:o().attachmentPending)}),u(ve,Oe)};B(Ae,ve=>{(e(A).status||e(Q))&&ve(L)})}var G=T(Ae,2),Ee=z(G);{var De=ve=>{Xe(ve,{variant:"primary",size:"icon-sm",class:"tile-action",get disabled(){return i()},get"aria-label"(){return o().retry},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return o().retry},onclick:()=>h()?.(e(A).id),children:(Oe,U)=>{jt(Oe,{get icon(){return zs},size:16})},$$slots:{default:!0}})},Je=ve=>{{let Oe=s(()=>c()?o().edit:o().markUp),U=s(()=>c()?o().edit:o().markUp);Xe(ve,{variant:"primary",size:"icon-sm",class:"tile-action",get disabled(){return i()},get"aria-label"(){return e(Oe)},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return e(U)},onclick:()=>F(e(A).id),children:(ue,ot)=>{Ss(ue,{glyph:"pencil"})},$$slots:{default:!0}})}},Ge=s(()=>W(e(A))),Bt=ve=>{{let Oe=s(()=>c()?o().edit:o().play),U=s(()=>c()?o().edit:o().play);Xe(ve,{variant:"primary",size:"icon-sm",class:"tile-action",get disabled(){return i()},get"aria-label"(){return e(Oe)},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return e(U)},onclick:ue=>{ue.currentTarget instanceof HTMLElement&&ne(e(A),ue.currentTarget)},children:(ue,ot)=>{{let xt=s(()=>c()?"pencil":"play");Ss(ue,{get glyph(){return e(xt)}})}},$$slots:{default:!0}})}};B(Ee,ve=>{e(A).status==="failed"&&h()?ve(De):e(Ge)?ve(Je,1):e(A).kind==="clip"&&!e(A).recording&&e(A).url&&ve(Bt,2)})}var ke=T(Ee,2);n(ke,()=>e(A).id,()=>o().remove),R(G),R(re),$(()=>{te(re,"data-kind",e(A).kind),te(re,"data-attachment-id",e(A).id),te(re,"aria-busy",e(Q)||void 0)}),Sr("contextmenu",re,ve=>le(ve,e(A))),Kt(1,re,()=>qa,()=>({tier:"fast",y:3,scale:.98})),Kt(2,re,()=>ea,()=>({tier:"fast"})),u(P,re)};B(Te,P=>{e(A).kind==="image"&&e(A).file?P(Be):P(Ce,-1)})}u(pe,ge)}),R(ye),cn(ye,pe=>j(S,pe),()=>e(S)),$(()=>te(ye,"aria-label",o().attachments)),u(O,ye)};B(Re,O=>{e(Y).length&&O(Le)})}var Ke=T(Re,2);{const O=pe=>{var A=Rt(),ge=xe(A);{var Te=Be=>{var Ce=Hu(),P=xe(Ce);{var Q=w=>{Xe(w,{variant:"primary",get disabled(){return i()},onclick:()=>e(M)&&F(e(M).id),children:(Se,Ae)=>{gr();var L=Or();$(()=>J(L,o().markUp)),u(Se,L)},$$slots:{default:!0}})},re=s(()=>W(e(M)));B(P,w=>{e(re)&&w(Q)})}var se=T(P,2);Xe(se,{variant:"secondary",get disabled(){return i()},onclick:()=>e(M)&&q(e(M).id),children:(w,Se)=>{gr();var Ae=Or();$(()=>J(Ae,o().remove)),u(w,Ae)},$$slots:{default:!0}});var ce=T(se,2);Xe(ce,{variant:"ghost-light",onclick:()=>{j(D,!1)},children:(w,Se)=>{gr();var Ae=Or();$(()=>J(Ae,o().done)),u(w,Ae)},$$slots:{default:!0}}),u(Be,Ce)};B(ge,Be=>{e(M)&&e(M).kind!=="file"&&Be(Te)})}u(pe,A)};let ye=s(()=>e(M)?E(e(M)):o().attachments);xi(Ke,{get title(){return e(ye)},size:"wide",showCloseButton:!1,onCloseAutoFocus:pe=>{pe.preventDefault(),X?.isConnected?X.focus():e(S)?.querySelector("button:not(:disabled)")?.focus()},get open(){return e(D)},set open(pe){j(D,pe,!0)},footer:O,children:(pe,A)=>{var ge=Rt(),Te=xe(ge);{var Be=Ce=>{var P=Vu(),Q=z(P);{var re=w=>{var Se=Uu();$(Ae=>{te(Se,"src",e(M).url),te(Se,"alt",Ae)},[()=>E(e(M))]),u(w,Se)},se=s(()=>e(M).kind==="image"&&W(e(M))),ce=w=>{var Se=ju();$(Ae=>{te(Se,"src",e(M).url),te(Se,"aria-label",Ae)},[()=>E(e(M))]),u(w,Se)};B(Q,w=>{e(se)?w(re):e(M).kind==="clip"&&e(M).url&&w(ce,1)})}R(P),u(Ce,P)};B(Te,Ce=>{e(M)&&e(M).kind!=="file"&&Ce(Be)})}u(pe,ge)},$$slots:{footer:!0,default:!0}})}return u(r,_e),At(me)}aa(["keydown","contextmenu"]);var Qu=I("<!> ",1),Zu=I('<div class="flex flex-col gap-2 px-4 py-3 bg-muted/30 border border-border rounded-lg my-4"><div class="flex items-center justify-between gap-2"><div class="flex items-center gap-2"><div class="shrink-0 text-subtle"><!></div> <div class="font-medium text-sm"> </div></div> <div class="flex items-center gap-1"><!> <!></div></div> <div class="text-xs text-subtle"> </div> <pre class="text-xs bg-background/50 rounded p-2 overflow-x-auto max-h-40 overflow-y-auto font-mono"> </pre></div>');function Vi(r,t){if(new.target)return It({component:Vi,...r});Ct(t,!0);let n=g(t,"name",7),a=g(t,"description",7),o=g(t,"content",7),i=g(t,"onUseScript",7),d=we(!1);function c(){navigator.clipboard.writeText(o()),j(d,!0),setTimeout(()=>{j(d,!1)},2e3)}function v(){i()?.({name:n(),description:a(),content:o()})}var h={get name(){return n()},set name(C){n(C),m()},get description(){return a()},set description(C){a(C),m()},get content(){return o()},set content(C){o(C),m()},get onUseScript(){return i()},set onUseScript(C){i(C),m()},$set:St,$on:(C,ee)=>Tt(t,C,ee)},b=Zu(),k=z(b),N=z(k),Y=z(N),S=z(Y);jt(S,{get icon(){return no},size:"sm"}),R(Y);var D=T(Y,2),ie=oe(D,!0);R(N);var X=T(N,2),M=z(X);Xe(M,{variant:"ghost-light",size:"sm",onclick:c,class:"h-7 px-2",children:(C,ee)=>{var le=Qu(),me=xe(le);{let Re=s(()=>e(d)?bi:wi);jt(me,{get icon(){return e(Re)},class:"mr-1"})}var _e=T(me);$(Re=>J(_e,` ${Re??""}`),[()=>e(d)?f.chat_shared_copied_label():f.chat_shared_copy_label()]),u(C,le)},$$slots:{default:!0}});var W=T(M,2);{var E=C=>{Xe(C,{variant:"ghost-light",size:"sm",onclick:v,class:"h-7 px-2",children:(ee,le)=>{gr();var me=Or();$(_e=>J(me,_e),[()=>f.chat_setupScriptCard_useScript_label()]),u(ee,me)},$$slots:{default:!0}})};B(W,C=>{i()&&C(E)})}R(X),R(k);var ne=T(k,2),q=oe(ne,!0),F=T(ne,2),ae=oe(F,!0);return R(b),$(()=>{J(ie,n()),J(q,a()),J(ae,o())}),u(r,b),At(h)}const wr={toolStart:/(?:\x1B\[\d+m)?🔧\s+(?:Tool call:\s+)?(.+?)(?:\x1B\[0m)?$/,toolDetail:/(?:[└├]─\s+(.+)$|^\s{3,}(.+)$)/,toolResult:/(?:\x1B\[\d+m)?📋\s+Tool result:\s+(.+?)(?:\x1B\[0m)?$/,toolSuccess:/[✓✔✅]\s+(.+)$/,toolError:/[❌✗❎]\s+(.+)$/,sessionInfo:/[Ss]ession:\s*([a-f0-9-]+)/,resumedSession:/📂?\s*Resumed session/i,assistantMarker:/🤖/,systemMarker:/💻/,userMarker:/👤/,thinkingMarker:/🤔\s*Thinking/i,waitingMarker:/^⏳\s+Running/i,indexingProgress:/^Indexing:\s*\[.*\]\s*\d+%/,agentDigest:/<agent_digest>([\s\S]*?)<\/agent_digest>/,setupScript:/<setup_script\s+name="([^"]+)"\s+description="([^"]+)">([\s\S]*?)<\/setup_script>/};class Ju{constructor(){kn(this,"buffer","");kn(this,"currentToolName",null);kn(this,"currentToolId",null);kn(this,"lastToolId",null);kn(this,"currentToolParams",[]);kn(this,"currentToolResultContent",[]);kn(this,"inToolResult",!1);kn(this,"inCodeBlock",!1);kn(this,"codeBlockLanguage","");kn(this,"codeBlockContent","");kn(this,"characterBuffer","");kn(this,"inCharacterMode",!1);kn(this,"emittedToolIds",new Set)}parseChunk(t){if(this.isMarkerLine(t.trim())){const o=[];if(this.inToolResult&&this.currentToolResultContent.length>0){const c=this.currentToolResultContent.some(h=>h.startsWith("❌")||h.startsWith("Error:")),v=this.currentToolResultContent.map(h=>h.replace(/^❌\s*/,"").replace(/^Error:\s*/,"")).join(`
|
|
1
|
+
var $l=Object.defineProperty;var Ol=(r,t,n)=>t in r?$l(r,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):r[t]=n;var kn=(r,t,n)=>Ol(r,typeof t!="symbol"?t+"":t,n);import{t as It,br as g,a_ as B,bz as St,b as Tt,bp as f,bt as Kn,bv as dr,bu as ql,bs as ha}from"./Cv-W__h8.js";import{ai as aa,bs as Ct,ca as sr,aD as e,bH as j,ay as xe,bS as T,a7 as Rt,W as u,a5 as z,bA as R,bn as At,c9 as s,bV as we,aA as m,b_ as $,aj as Sr,aB as I,be as gr,b$ as Or,bO as J,bf as or,c0 as Cn,bl as oe,bj as jn,c6 as Dl,bo as za,br as Yr,am as Dn,ax as Bn,bk as as,aw as va,bz as ss,cb as ms,c5 as Ha,aC as xr,cd as _o,bv as Bl}from"./DYhIMPy1.js";import{n as Tr,u as te,v as ze,g as _n,s as ps,w as _a,j as kt,l as ar,p as Yn,I as Fl,i as ya,r as zl,o as eo,X as _i,q as Wl,S as Hl,C as Ul}from"./DPvDLGgX.js";import{I as Kt,F as qa,c as ea,j as jl,s as yi,p as to,y as Vl,u as Kl,t as $r,g as oa,B as ws,E as os,S as Gl}from"./j0KL2ItM.js";import{b as cn}from"./BaIAhI85.js";import{f as Xe,bj as Ql,am as ro,bt as Zl,bx as xs,bL as Jl}from"./BePtUMMB.js";import"./9s3slwY6.js";import"./Dj_1qKAG.js";import"./DUGj7TPr.js";import{s as Ln}from"./ClsZrb8B.js";import{F as jt,a0 as zs,bc as Tn,cF as no,aq as bi,aV as wi,aG as Xl,c4 as Yl,a2 as is,aJ as ed,cI as td,cH as rd,$ as vs,as as ao,I as yo,af as nd,bq as ad,aO as sd,aT as od,bF as id,ak as ld,cx as dd,ay as bo,aL as wo,bX as ks,aE as Ua,cR as cd,c6 as ud,bj as fd,b as gd,ck as md,ac as pd,b6 as Is,cm as xa,cA as vd,a as hd}from"./BKpkoMuv.js";import{c as xi,A as _d,x as yd}from"./D2pEu7en.js";import{b as Ss,V as xo}from"./CsScj5_e.js";import{a as ki,b7 as Pr,A as Ga,ao as Ii,s as bd,n as Si,d as wd,I as xd,R as kd,ax as Id,a0 as Sd}from"./DZ9d4A89.js";import{bX as Ti,j as Qa,a6 as Ws,al as ls,F as Td,au as Za,aN as Cd,aQ as ko}from"./DiuUmAWK.js";import{t as ia,o as Ad}from"./2_iuLgF6.js";import{c3 as Ja,aC as Da,cQ as Ci,cS as Vn,bU as hs,j as Md,cJ as Ai,cP as _s,cO as Mi,cM as Pi,g as Nn,aa as Pd,ab as Rd,ax as Ed,s as Nd,K as Ld,W as Io,v as Ri,dO as $d,at as Od,k as qd,u as Ts,a6 as Dd,n as Bd,O as Fd,o as zd,S as Wd,R as Hd,a0 as Ud,q as Ei,r as Ni,l as jd,cT as Vd,a4 as Kd,D as Gd,x as Qd,V as So}from"./B10dK85Q.js";import{Ir as yt,oA as Zd,t8 as Xa,np as To,uY as Li,u_ as $i,rm as Jd,xU as ds,uf as Oi,nk as qi,be as Ya,xV as Xd,q0 as Yd,sF as ec,uR as Di,nj as tc,mq as rc,g as nc,yl as ac,yi as sc,yk as oc}from"./DBkMUdAo.js";import{a2 as ic,x as Cs,a0 as lc,O as As,V as dc,_ as cc,j as uc,o as ka,M as fa,p as fc,F as gc,u as mc,s as pc,L as Ms,J as vc,y as hc,K as _c,Z as Ma,Q as ja,N as Co,m as Ao,E as yc,c as Ps,B as Mo,z as bc,v as Po,H as Pa,P as wc,G as xc,i as kc,R as Ic,T as Sc,A as Tc,g as Cc,b as Ac,D as Mc,f as Pc,e as Rc,a as Ec,C as Nc,h as Lc,U as Bi,a3 as $c,t as Oc,k as qc,d as Ro}from"./aure5QjZ.js";import{i as Dc,e as Bc}from"./1o85IiDb.js";import{g as Rs}from"./BvFAWM27.js";import{M as Ia,C as Ra}from"./Bq9XUSeR.js";import{C as Eo}from"./DadKxQy4.js";import"./CUdOnH55.js";import{P as Fc}from"./DR5dualt.js";import"./C9iBDSZ7.js";import{c as Fi}from"./ChTqQfQN.js";import{S as zc}from"./afGYXIhs.js";import{D as No,M as Wc}from"./DuwE_WBW.js";import{b as Hc,s as na,c as cs}from"./BMmnZrRK.js";import{O as es,y as Es,E as Ns,B as Ls,N as Uc,m as jc,l as Vc,d as us,C as Lo,f as Kc,e as Gc,g as Qc}from"./b6EhU_ki.js";import{a as zi,s as $o}from"./BsieX9dN.js";import{f as Zc}from"./BdWqymET.js";import{c as dn}from"./CueFizU8.js";import{P as Jc}from"./BvDMLNjQ.js";import{q as $s,p as Os,z as Oo,h as Xc}from"./CdTX9MRt.js";import{R as Hs,C as ys,k as Yc,h as eu,g as tu,i as qo,P as ru}from"./DTDbZc--.js";import"./CgCdkhNg.js";import{R as Do,x as Na,o as Wi}from"./CVvPXkN9.js";import{B as nu}from"./BlXsb3Tb.js";import{o as Hi,r as au,e as su}from"./DnReg1PV.js";import{o as Ui}from"./CmRtKL7J.js";import{g as so}from"./CmUwI5cU.js";import{a as ou,M as iu}from"./BiLjH_HB.js";import{c as Sa}from"./D4os-974.js";import{A as lu}from"./CJDL5KAB.js";import{f as du,d as cu}from"./CM--21b-.js";import{a8 as uu,N as fu,Y as gu,K as Bo,X as mu,v as pu}from"./DWBKmRqH.js";import{a as vu}from"./CC7to1B5.js";import{G as hu}from"./GdlMbZRO.js";import{S as _u}from"./m03ON1WT.js";import{u as yu,a as bu,c as Fo,S as wu}from"./DfxQWSVU.js";import{T as Us}from"./BN_moS2U.js";import"./Czzc8yNT.js";import{g as xu}from"./B8IFnCn1.js";import{a as ku}from"./CkjMOvWd.js";import{b as Iu}from"./DAZ23kin.js";import{b as zo}from"./p7znhYIU.js";import{g as Su,i as Tu,a as Cu}from"./BZeUwBn0.js";import{n as Wo,o as Ho,b as ma,s as Ta,_ as qs,e as Au}from"./CIyUrgF0.js";import{aW as Un,B as Mu}from"./CUrYTyIw.js";import{y as Pu}from"./C3BW_tmx.js";import{c as Ru}from"./DOpgcKBl.js";function Eu(r){if(!r||typeof r!="object")return null;const t=r;if(t.type!=="script_monitor_wake"||t.source!=="system")return null;const{scriptName:n,scriptId:a,runId:o,monitorId:i,workspaceId:d,reason:c}=t;if(typeof n!="string"||typeof a!="string"||!a||typeof o!="string"||!o||typeof i!="string"||!i||typeof d!="string"||!d||c!=="finished"&&c!=="ttl-expired"&&c!=="output-match"&&c!=="line-count")return null;const v=t.trigger;return{scriptName:n,scriptId:a,runId:o,monitorId:i,workspaceId:d,reason:c,...c==="output-match"&&typeof v?.matchedLine=="string"?{matchedLine:v.matchedLine}:{}}}function Nu(r){return r?.type==="script_monitor_wake"&&!("remoteAgentId"in r)}function Lu(r,t,n,a=!1){if(!r||!t)return{edit:!1,remove:!1,sendNow:!1};const o=r.messageMetadata?.fromPrincipalId??r.author?.principalId,i=uu(r)&&r.author?.principalId!==null&&o===t;return{edit:i,remove:i||t===n||a,sendNow:(i||a)&&!ji(r)}}function Ca(r,t){if(t)return r.find(n=>n.editing&&n.editingMessageId?n.editingMessageId===t:n.id===t)}function ji(r){return Nu(r.messageMetadata)&&typeof r.messageMetadata?.monitorId=="string"}function Uo(r,t=Date.now()){const n=r.messageMetadata,a=n?.fromPrincipalId,o=n&&Object.hasOwn(n,"humanAuthor")&&!(typeof a=="string"&&a.length>0),i=r.holdKind!==void 0&&Date.parse(r.holdUntil??"")>t;return!r.editing&&!i&&!o&&!ji(r)}const j_="pl-3.5! pr-2!";var $u=I('<span class="tile-remove-slot svelte-d8pwpf"><!></span>'),jo=I('<span class="attachment-status svelte-d8pwpf"> </span>'),Ou=I('<div class="file-image tile svelte-d8pwpf" data-kind="file"><!> <!> <div class="tile-actions svelte-d8pwpf"><!> <!></div></div>'),qu=I("<!><span> </span>",1),Du=I('<img alt="" draggable="false"/>'),Bu=I('<span class="summary svelte-d8pwpf" data-clip-summary=""> </span>'),Fu=I('<span class="clip svelte-d8pwpf"><span class="record-dot svelte-d8pwpf" aria-hidden="true"></span><span class="duration svelte-d8pwpf"> </span><!></span>'),zu=I('<div class="tile svelte-d8pwpf"><!> <!> <div class="tile-actions svelte-d8pwpf"><!> <!></div></div>'),Wu=I('<div class="attachment-row svelte-d8pwpf" role="group" data-dock-media-attachments=""></div>'),Hu=I("<!> <!> <!>",1),Uu=I('<img draggable="false" class="svelte-d8pwpf"/>'),ju=I('<video controls="" playsinline="" class="svelte-d8pwpf"></video>',2),Vu=I('<div class="media-viewer svelte-d8pwpf"><!></div>'),Ku=I("<!> <!>",1);function Gu(r,t){if(new.target)return It({component:Gu,...r});Ct(t,!0);const n=(O,ye=or,pe=or)=>{var A=$u(),ge=z(A);Xe(ge,{variant:"secondary",size:"icon-sm",class:"tile-action tile-remove",get disabled(){return i()},get"aria-label"(){return pe()},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return pe()},onclick:()=>q(ye()),children:(Te,Be)=>{Ss(Te,{glyph:"x"})},$$slots:{default:!0}}),R(A),u(O,A)};let a=g(t,"items",7),o=g(t,"labels",7),i=g(t,"disabled",7,!1),d=g(t,"onMarkUp",7),c=g(t,"onEdit",7),v=g(t,"onRemove",7),h=g(t,"onRetry",7),b=g(t,"onCopy",7),k=g(t,"onMenu",7);const N=O=>O.owner==="attachment"?2:{image:0,clip:1,file:2}[O.kind],Y=s(()=>[...a()].sort((O,ye)=>N(O)-N(ye)));let S=we(null),D=we(!1),ie=we(null),X=null;const M=s(()=>a().find(O=>O.id===e(ie)));sr(()=>{(!e(M)||e(M).kind==="image"&&!W(e(M)))&&j(D,!1)});function W(O){return O.kind==="image"&&O.status!=="placing"&&O.status!=="failed"&&O.url.trim().length>0}function E(O){return O.kind==="image"?o().image(O.markCount):O.kind==="clip"?O.summary?`${o().clip(O.duration)} ${O.summary}`:o().clip(O.duration):O.name}function ne(O,ye){if(!(i()||O.kind==="file"||O.kind==="image"&&!W(O)||O.kind==="clip"&&(!O.url||O.recording))){if((O.kind==="clip"||O.kind==="image")&&c()){c()(O.id);return}X=ye,j(ie,O.id,!0),j(D,!0)}}async function q(O){i()||(e(ie)===O&&j(D,!1),v()(O),await Cn(),(!document.activeElement||document.activeElement===document.body)&&e(S)?.querySelector("button:not(:disabled)")?.focus())}function F(O){const ye=a().find(pe=>pe.id===O);i()||!ye||!W(ye)||(j(D,!1),c()?c()(O):d()(O))}function ae(O,ye){O.key!=="Delete"||i()||(O.preventDefault(),O.stopPropagation(),q(ye))}function C(O){return O.status==="placing"||O.status==="failed"?!1:O.kind==="image"?!!O.file||W(O):O.kind==="clip"&&!O.recording&&!!O.url}function ee(O,ye){const pe=Ql()?O.metaKey:O.ctrlKey,A=O.key.toLowerCase();if(pe&&!O.shiftKey&&!O.altKey&&(A==="c"||A==="x")){if(!b()||!C(ye)||(O.preventDefault(),O.stopPropagation(),A==="x"&&i()))return;b()(ye.id,A==="x");return}ae(O,ye.id)}function le(O,ye){!k()||!C(ye)||(O.preventDefault(),k()(ye.id))}var me={get items(){return a()},set items(O){a(O),m()},get labels(){return o()},set labels(O){o(O),m()},get disabled(){return i()},set disabled(O=!1){i(O),m()},get onMarkUp(){return d()},set onMarkUp(O){d(O),m()},get onEdit(){return c()},set onEdit(O){c(O),m()},get onRemove(){return v()},set onRemove(O){v(O),m()},get onRetry(){return h()},set onRetry(O){h(O),m()},get onCopy(){return b()},set onCopy(O){b(O),m()},get onMenu(){return k()},set onMenu(O){k(O),m()},$set:St,$on:(O,ye)=>Tt(t,O,ye)},_e=Ku(),Re=xe(_e);{var Le=O=>{var ye=Wu();Tr(ye,21,()=>e(Y),pe=>pe.id,(pe,A)=>{var ge=Rt(),Te=xe(ge);{var Be=P=>{var Q=Ou(),re=z(Q);{let G=s(()=>i()||e(A).status==="placing");ki(re,{get id(){return e(A).id},get name(){return e(A).file.name},get type(){return e(A).file.imageMimeType},get imageData(){return e(A).file.imageData},get imageMimeType(){return e(A).file.imageMimeType},variant:"thumbnail",thumbnailClass:"size-full",class:"size-full",get disabled(){return e(G)},get placementStatus(){return e(A).status},get placementError(){return e(A).error}})}var se=T(re,2);{var ce=G=>{var Ee=jo(),De=oe(Ee,!0);$(()=>{te(Ee,"data-failed",e(A).status==="failed"||void 0),te(Ee,"role",e(A).status==="failed"?"alert":"status"),te(Ee,"title",e(A).error),J(De,e(A).status==="failed"?e(A).error??o().attachmentFailed:o().attachmentPending)}),u(G,Ee)};B(se,G=>{e(A).status&&G(ce)})}var w=T(se,2),Se=z(w);{var Ae=G=>{Xe(G,{variant:"primary",size:"icon-sm",class:"tile-action",get disabled(){return i()},get"aria-label"(){return o().retry},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return o().retry},onclick:()=>h()?.(e(A).id),children:(Ee,De)=>{jt(Ee,{get icon(){return zs},size:16})},$$slots:{default:!0}})};B(Se,G=>{e(A).status==="failed"&&h()&&G(Ae)})}var L=T(Se,2);{let G=s(()=>f.chat_attachmentPreview_remove_ariaLabel({name:e(A).file.name}));n(L,()=>e(A).id,()=>e(G))}R(w),R(Q),$(()=>te(Q,"data-attachment-id",e(A).id)),Sr("keydown",Q,G=>ee(G,e(A))),Sr("contextmenu",Q,G=>le(G,e(A))),Kt(1,Q,()=>qa,()=>({tier:"fast",y:3,scale:.98})),Kt(2,Q,()=>ea,()=>({tier:"fast"})),u(P,Q)},Ce=P=>{const Q=s(()=>e(A).kind==="image"&&!W(e(A))&&e(A).status!=="failed");var re=zu(),se=z(re);{var ce=ve=>{Xe(ve,{type:"button",variant:"ghost",wrapContent:!1,class:"open-tile file",get"aria-label"(){return e(A).name},get disabled(){return i()},onkeydown:Oe=>ae(Oe,e(A).id),children:(Oe,U)=>{var ue=qu(),ot=xe(ue);jt(ot,{get icon(){return Tn},size:20});var xt=T(ot),mt=oe(xt,!0);$(()=>J(mt,e(A).name)),u(Oe,ue)},$$slots:{default:!0}})},w=ve=>{{let Oe=s(()=>E(e(A))),U=s(()=>i()||e(A).kind==="clip"&&(e(A).recording||!e(A).url));Xe(ve,{type:"button",variant:"ghost",wrapContent:!1,class:"open-tile",get"aria-label"(){return e(Oe)},get disabled(){return e(U)},onkeydown:ue=>ee(ue,e(A)),onclick:ue=>{ue.currentTarget instanceof HTMLElement&&ne(e(A),ue.currentTarget)},children:(ue,ot)=>{var xt=Rt(),mt=xe(xt);{var Ft=je=>{var bt=Du();$(()=>te(bt,"src",e(A).url)),u(je,bt)},pt=je=>{var bt=Fu(),at=T(z(bt)),dt=oe(at,!0),$e=T(at);{var ft=K=>{var _=Bu(),he=oe(_,!0);$(()=>J(he,e(A).summary)),u(K,_)};B($e,K=>{e(A).summary&&K(ft)})}R(bt),$(()=>J(dt,e(A).duration)),u(je,bt)};B(mt,je=>{e(A).kind==="image"?je(Ft):je(pt,-1)})}u(ue,xt)},$$slots:{default:!0}})}},Se=s(()=>e(A).kind!=="image"||W(e(A)));B(se,ve=>{e(A).kind==="file"?ve(ce):e(Se)&&ve(w,1)})}var Ae=T(se,2);{var L=ve=>{var Oe=jo(),U=oe(Oe,!0);$(()=>{te(Oe,"data-failed",e(A).status==="failed"||void 0),te(Oe,"role",e(A).status==="failed"?"alert":"status"),te(Oe,"title",e(A).error),J(U,e(A).status==="failed"?e(A).error??o().attachmentFailed:o().attachmentPending)}),u(ve,Oe)};B(Ae,ve=>{(e(A).status||e(Q))&&ve(L)})}var G=T(Ae,2),Ee=z(G);{var De=ve=>{Xe(ve,{variant:"primary",size:"icon-sm",class:"tile-action",get disabled(){return i()},get"aria-label"(){return o().retry},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return o().retry},onclick:()=>h()?.(e(A).id),children:(Oe,U)=>{jt(Oe,{get icon(){return zs},size:16})},$$slots:{default:!0}})},Je=ve=>{{let Oe=s(()=>c()?o().edit:o().markUp),U=s(()=>c()?o().edit:o().markUp);Xe(ve,{variant:"primary",size:"icon-sm",class:"tile-action",get disabled(){return i()},get"aria-label"(){return e(Oe)},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return e(U)},onclick:()=>F(e(A).id),children:(ue,ot)=>{Ss(ue,{glyph:"pencil"})},$$slots:{default:!0}})}},Ge=s(()=>W(e(A))),Bt=ve=>{{let Oe=s(()=>c()?o().edit:o().play),U=s(()=>c()?o().edit:o().play);Xe(ve,{variant:"primary",size:"icon-sm",class:"tile-action",get disabled(){return i()},get"aria-label"(){return e(Oe)},tooltipContentClass:"dock-chrome-tooltip",get tooltip(){return e(U)},onclick:ue=>{ue.currentTarget instanceof HTMLElement&&ne(e(A),ue.currentTarget)},children:(ue,ot)=>{{let xt=s(()=>c()?"pencil":"play");Ss(ue,{get glyph(){return e(xt)}})}},$$slots:{default:!0}})}};B(Ee,ve=>{e(A).status==="failed"&&h()?ve(De):e(Ge)?ve(Je,1):e(A).kind==="clip"&&!e(A).recording&&e(A).url&&ve(Bt,2)})}var ke=T(Ee,2);n(ke,()=>e(A).id,()=>o().remove),R(G),R(re),$(()=>{te(re,"data-kind",e(A).kind),te(re,"data-attachment-id",e(A).id),te(re,"aria-busy",e(Q)||void 0)}),Sr("contextmenu",re,ve=>le(ve,e(A))),Kt(1,re,()=>qa,()=>({tier:"fast",y:3,scale:.98})),Kt(2,re,()=>ea,()=>({tier:"fast"})),u(P,re)};B(Te,P=>{e(A).kind==="image"&&e(A).file?P(Be):P(Ce,-1)})}u(pe,ge)}),R(ye),cn(ye,pe=>j(S,pe),()=>e(S)),$(()=>te(ye,"aria-label",o().attachments)),u(O,ye)};B(Re,O=>{e(Y).length&&O(Le)})}var Ke=T(Re,2);{const O=pe=>{var A=Rt(),ge=xe(A);{var Te=Be=>{var Ce=Hu(),P=xe(Ce);{var Q=w=>{Xe(w,{variant:"primary",get disabled(){return i()},onclick:()=>e(M)&&F(e(M).id),children:(Se,Ae)=>{gr();var L=Or();$(()=>J(L,o().markUp)),u(Se,L)},$$slots:{default:!0}})},re=s(()=>W(e(M)));B(P,w=>{e(re)&&w(Q)})}var se=T(P,2);Xe(se,{variant:"secondary",get disabled(){return i()},onclick:()=>e(M)&&q(e(M).id),children:(w,Se)=>{gr();var Ae=Or();$(()=>J(Ae,o().remove)),u(w,Ae)},$$slots:{default:!0}});var ce=T(se,2);Xe(ce,{variant:"ghost-light",onclick:()=>{j(D,!1)},children:(w,Se)=>{gr();var Ae=Or();$(()=>J(Ae,o().done)),u(w,Ae)},$$slots:{default:!0}}),u(Be,Ce)};B(ge,Be=>{e(M)&&e(M).kind!=="file"&&Be(Te)})}u(pe,A)};let ye=s(()=>e(M)?E(e(M)):o().attachments);xi(Ke,{get title(){return e(ye)},size:"wide",showCloseButton:!1,onCloseAutoFocus:pe=>{pe.preventDefault(),X?.isConnected?X.focus():e(S)?.querySelector("button:not(:disabled)")?.focus()},get open(){return e(D)},set open(pe){j(D,pe,!0)},footer:O,children:(pe,A)=>{var ge=Rt(),Te=xe(ge);{var Be=Ce=>{var P=Vu(),Q=z(P);{var re=w=>{var Se=Uu();$(Ae=>{te(Se,"src",e(M).url),te(Se,"alt",Ae)},[()=>E(e(M))]),u(w,Se)},se=s(()=>e(M).kind==="image"&&W(e(M))),ce=w=>{var Se=ju();$(Ae=>{te(Se,"src",e(M).url),te(Se,"aria-label",Ae)},[()=>E(e(M))]),u(w,Se)};B(Q,w=>{e(se)?w(re):e(M).kind==="clip"&&e(M).url&&w(ce,1)})}R(P),u(Ce,P)};B(Te,Ce=>{e(M)&&e(M).kind!=="file"&&Ce(Be)})}u(pe,ge)},$$slots:{footer:!0,default:!0}})}return u(r,_e),At(me)}aa(["keydown","contextmenu"]);var Qu=I("<!> ",1),Zu=I('<div class="flex flex-col gap-2 px-4 py-3 bg-muted/30 border border-border rounded-lg my-4"><div class="flex items-center justify-between gap-2"><div class="flex items-center gap-2"><div class="shrink-0 text-subtle"><!></div> <div class="font-medium text-sm"> </div></div> <div class="flex items-center gap-1"><!> <!></div></div> <div class="text-xs text-subtle"> </div> <pre class="text-xs bg-background/50 rounded p-2 overflow-x-auto max-h-40 overflow-y-auto font-mono"> </pre></div>');function Vi(r,t){if(new.target)return It({component:Vi,...r});Ct(t,!0);let n=g(t,"name",7),a=g(t,"description",7),o=g(t,"content",7),i=g(t,"onUseScript",7),d=we(!1);function c(){navigator.clipboard.writeText(o()),j(d,!0),setTimeout(()=>{j(d,!1)},2e3)}function v(){i()?.({name:n(),description:a(),content:o()})}var h={get name(){return n()},set name(C){n(C),m()},get description(){return a()},set description(C){a(C),m()},get content(){return o()},set content(C){o(C),m()},get onUseScript(){return i()},set onUseScript(C){i(C),m()},$set:St,$on:(C,ee)=>Tt(t,C,ee)},b=Zu(),k=z(b),N=z(k),Y=z(N),S=z(Y);jt(S,{get icon(){return no},size:"sm"}),R(Y);var D=T(Y,2),ie=oe(D,!0);R(N);var X=T(N,2),M=z(X);Xe(M,{variant:"ghost-light",size:"sm",onclick:c,class:"h-7 px-2",children:(C,ee)=>{var le=Qu(),me=xe(le);{let Re=s(()=>e(d)?bi:wi);jt(me,{get icon(){return e(Re)},class:"mr-1"})}var _e=T(me);$(Re=>J(_e,` ${Re??""}`),[()=>e(d)?f.chat_shared_copied_label():f.chat_shared_copy_label()]),u(C,le)},$$slots:{default:!0}});var W=T(M,2);{var E=C=>{Xe(C,{variant:"ghost-light",size:"sm",onclick:v,class:"h-7 px-2",children:(ee,le)=>{gr();var me=Or();$(_e=>J(me,_e),[()=>f.chat_setupScriptCard_useScript_label()]),u(ee,me)},$$slots:{default:!0}})};B(W,C=>{i()&&C(E)})}R(X),R(k);var ne=T(k,2),q=oe(ne,!0),F=T(ne,2),ae=oe(F,!0);return R(b),$(()=>{J(ie,n()),J(q,a()),J(ae,o())}),u(r,b),At(h)}const wr={toolStart:/(?:\x1B\[\d+m)?🔧\s+(?:Tool call:\s+)?(.+?)(?:\x1B\[0m)?$/,toolDetail:/(?:[└├]─\s+(.+)$|^\s{3,}(.+)$)/,toolResult:/(?:\x1B\[\d+m)?📋\s+Tool result:\s+(.+?)(?:\x1B\[0m)?$/,toolSuccess:/[✓✔✅]\s+(.+)$/,toolError:/[❌✗❎]\s+(.+)$/,sessionInfo:/[Ss]ession:\s*([a-f0-9-]+)/,resumedSession:/📂?\s*Resumed session/i,assistantMarker:/🤖/,systemMarker:/💻/,userMarker:/👤/,thinkingMarker:/🤔\s*Thinking/i,waitingMarker:/^⏳\s+Running/i,indexingProgress:/^Indexing:\s*\[.*\]\s*\d+%/,agentDigest:/<agent_digest>([\s\S]*?)<\/agent_digest>/,setupScript:/<setup_script\s+name="([^"]+)"\s+description="([^"]+)">([\s\S]*?)<\/setup_script>/};class Ju{constructor(){kn(this,"buffer","");kn(this,"currentToolName",null);kn(this,"currentToolId",null);kn(this,"lastToolId",null);kn(this,"currentToolParams",[]);kn(this,"currentToolResultContent",[]);kn(this,"inToolResult",!1);kn(this,"inCodeBlock",!1);kn(this,"codeBlockLanguage","");kn(this,"codeBlockContent","");kn(this,"characterBuffer","");kn(this,"inCharacterMode",!1);kn(this,"emittedToolIds",new Set)}parseChunk(t){if(this.isMarkerLine(t.trim())){const o=[];if(this.inToolResult&&this.currentToolResultContent.length>0){const c=this.currentToolResultContent.some(h=>h.startsWith("❌")||h.startsWith("Error:")),v=this.currentToolResultContent.map(h=>h.replace(/^❌\s*/,"").replace(/^Error:\s*/,"")).join(`
|
|
2
2
|
`);o.push({type:"tool_result",content:v,metadata:{toolId:this.currentToolId,isError:c}}),this.lastToolId=this.currentToolId,this.currentToolId=null,this.inToolResult=!1,this.currentToolResultContent=[]}const i=t.indexOf("🤖"),d=t.substring(i+2);if(this.inCharacterMode=!0,this.characterBuffer="",d&&d.trim()&&d!==`
|
|
3
3
|
`){const c=d.replace(/^\n/,"");c&&(this.characterBuffer=c)}return o}if(this.inCharacterMode){if(t.trim()===""&&this.characterBuffer==="")return[];if(t.includes(`
|
|
4
4
|
`)&&this.characterBuffer.length>0){const o=t.substring(0,t.indexOf(`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var vo=Object.defineProperty;var bo=(e,t,i)=>t in e?vo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i;var v=(e,t,i)=>bo(e,typeof t!="symbol"?t+"":t,i);import{t as ir,br as M,a_ as we,bz as nr,b as rr,bv as dn,bt as So,bp as $e}from"./Cv-W__h8.js";import{bs as or,a5 as De,ay as hn,bS as Xe,aD as C,bA as ke,b_ as Me,bO as rt,W as le,bl as Xt,be as Hi,bn as sr,c9 as ne,aA as I,b$ as ar,aB as ge,ai as yo,bV as Te,br as Co,ca as je,bH as Y,c5 as dt,bk as xo,bj as Lo,aj as wo,c0 as fn}from"./DYhIMPy1.js";import{n as ko,p as Eo,v as un,w as pi,u as cn}from"./DPvDLGgX.js";import{b as Ro}from"./p7znhYIU.js";import{b as pn}from"./BaIAhI85.js";import{h as Ao,c as Ye,w as lr,N as O,O as Jt,b2 as Qe,a as dr,j as hr,P as Je,H as fr,i as ur,ab as cr,U as Ho,f as To,e as pr,T as Do,g as Mo,S as Io,a4 as Ze,a3 as Ve,C as Fo,G as gr,F as No,I as Po,A as At,ah as zo,$ as Ht,ad as Tt,v as St,a1 as Ti,s as J,r as Ue,an as wt,D as Uo,d as _o,aa as mr,b as gn,u as mn,aI as Oo,ap as ct,ac as Bo,K as Le,M as Ut,L as Vo,a0 as Dt,E as Wo,al as vr,a6 as Go,a2 as vn,t as br,af as ft,a5 as kt,ae as ot,ag as Sr,B as gi,a9 as mi,k as $o,aH as bn}from"./
|
|
1
|
+
var vo=Object.defineProperty;var bo=(e,t,i)=>t in e?vo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i;var v=(e,t,i)=>bo(e,typeof t!="symbol"?t+"":t,i);import{t as ir,br as M,a_ as we,bz as nr,b as rr,bv as dn,bt as So,bp as $e}from"./Cv-W__h8.js";import{bs as or,a5 as De,ay as hn,bS as Xe,aD as C,bA as ke,b_ as Me,bO as rt,W as le,bl as Xt,be as Hi,bn as sr,c9 as ne,aA as I,b$ as ar,aB as ge,ai as yo,bV as Te,br as Co,ca as je,bH as Y,c5 as dt,bk as xo,bj as Lo,aj as wo,c0 as fn}from"./DYhIMPy1.js";import{n as ko,p as Eo,v as un,w as pi,u as cn}from"./DPvDLGgX.js";import{b as Ro}from"./p7znhYIU.js";import{b as pn}from"./BaIAhI85.js";import{h as Ao,c as Ye,w as lr,N as O,O as Jt,b2 as Qe,a as dr,j as hr,P as Je,H as fr,i as ur,ab as cr,U as Ho,f as To,e as pr,T as Do,g as Mo,S as Io,a4 as Ze,a3 as Ve,C as Fo,G as gr,F as No,I as Po,A as At,ah as zo,$ as Ht,ad as Tt,v as St,a1 as Ti,s as J,r as Ue,an as wt,D as Uo,d as _o,aa as mr,b as gn,u as mn,aI as Oo,ap as ct,ac as Bo,K as Le,M as Ut,L as Vo,a0 as Dt,E as Wo,al as vr,a6 as Go,a2 as vn,t as br,af as ft,a5 as kt,ae as ot,ag as Sr,B as gi,a9 as mi,k as $o,aH as bn}from"./D3jGrF5f.js";import{F as vi,c4 as jo,be as qo,at as Ko,as as Xo}from"./BKpkoMuv.js";import{f as Di}from"./BePtUMMB.js";import{g as Yo}from"./1o85IiDb.js";import{c as Qo}from"./CgCdkhNg.js";import{P as Jo}from"./DZ9d4A89.js";import{t as Sn}from"./j0KL2ItM.js";class Zo extends Ao{constructor(){super(...arguments),this.tokenize=ts}equals(t,i,n){return n.ignoreWhitespace?((!n.newlineIsToken||!t.includes(`
|
|
2
2
|
`))&&(t=t.trim()),(!n.newlineIsToken||!i.includes(`
|
|
3
3
|
`))&&(i=i.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(t.endsWith(`
|
|
4
4
|
`)&&(t=t.slice(0,-1)),i.endsWith(`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{b as p,ay as C,aX as H,W as _,r as q,a6 as G,B as U,aV as j,X as K}from"./
|
|
1
|
+
import{b as p,ay as C,aX as H,W as _,r as q,a6 as G,B as U,aV as j,X as K}from"./DuwE_WBW.js";var A="",M="",O="",D=[],b=new Map,v=p(e=>j(e,K()),"sanitizeText"),y=p(e=>{switch(e.type){case"terminal":return{...e,value:v(e.value)};case"nonterminal":return{...e,name:v(e.name)};case"sequence":return{...e,elements:e.elements.map(y)};case"choice":return{...e,alternatives:e.alternatives.map(y)};case"optional":return{...e,element:y(e.element)};case"repetition":return{...e,element:y(e.element),separator:e.separator?y(e.separator):void 0};case"special":return{...e,text:v(e.text)}}},"sanitizeAstNode"),J=p(()=>{A="",M="",O="",D.length=0,b.clear(),q(),C.debug("[Railroad] Database cleared")},"clear"),Y=p(e=>{A=v(e),C.debug("[Railroad] Title set:",e)},"setTitle"),P=p(()=>A,"getTitle"),Q=p(e=>{const i={...e,name:v(e.name),definition:y(e.definition),comment:e.comment?v(e.comment):void 0};C.debug("[Railroad] Adding rule:",i.name),b.has(i.name)&&C.warn(`[Railroad] Rule '${i.name}' is already defined. Overwriting.`),D.push(i),b.set(i.name,i)},"addRule"),Z=p(()=>D,"getRules"),V=p(e=>b.get(e),"getRule"),ee=p(e=>{M=v(e).replace(/^\s+/g,""),C.debug("[Railroad] Accessibility title set:",e)},"setAccTitle"),te=p(()=>M,"getAccTitle"),re=p(e=>{O=v(e).replace(/\n\s+/g,`
|
|
2
2
|
`),C.debug("[Railroad] Accessibility description set:",e)},"setAccDescription"),ie=p(()=>O,"getAccDescription"),ae=Y,ne=P,oe={clear:J,setTitle:Y,getTitle:P,addRule:Q,getRules:Z,getRule:V,setAccTitle:ee,getAccTitle:te,setAccDescription:re,getAccDescription:ie,setDiagramTitle:ae,getDiagramTitle:ne},f={compactMode:!1,padding:10,verticalSeparation:8,horizontalSeparation:10,arcRadius:10,fontSize:14,fontFamily:"monospace",terminalFill:"#FFFFC0",terminalStroke:"#000000",terminalTextColor:"#000000",nonTerminalFill:"#FFFFFF",nonTerminalStroke:"#000000",nonTerminalTextColor:"#000000",lineColor:"#000000",strokeWidth:2,markerFill:"#000000",commentFill:"#E8E8E8",commentStroke:"#888888",commentTextColor:"#666666",specialFill:"#F0E0FF",specialStroke:"#8800CC",ruleNameColor:"#000066",showMarkers:!0,markerRadius:5},le=/^#(?:[\da-f]{3,4}|[\da-f]{6}|[\da-f]{8})$|^(?:rgb|rgba|hsl|hsla|hwb|lab|lch|oklab|oklch)\([\d\s%+,./-]+\)$|^[a-z]+$/i,se=/^[\w "',.-]+$/,de=new Set(["compactMode","padding","verticalSeparation","horizontalSeparation","arcRadius","fontSize","fontFamily","terminalFill","terminalStroke","terminalTextColor","nonTerminalFill","nonTerminalStroke","nonTerminalTextColor","lineColor","strokeWidth","markerFill","commentFill","commentStroke","commentTextColor","specialFill","specialStroke","ruleNameColor","showMarkers","markerRadius"]),L=p(e=>e?Object.keys(e).every(i=>i==="railroad"||de.has(i)):!1,"isRailroadStyleOptions"),ce=p(e=>e?"railroad"in e&&e.railroad?e.railroad:L(e)?e:{}:{},"extractRailroadOverrides"),me=p(e=>{if(!e||L(e))return{};const{railroad:i,svgId:n,theme:a,look:t,...r}=e;return r},"extractThemeOverrides"),m=p((e,i)=>{if(typeof e!="string")return i;const n=e.trim();return le.test(n)?n:i},"sanitizeColorValue"),X=p((e,i)=>{if(typeof e!="string")return i;const n=e.trim();return se.test(n)?n:i},"sanitizeFontFamilyValue"),F=p((e,i)=>{const n=typeof e=="number"?e:typeof e=="string"?Number.parseFloat(e):Number.NaN;return Number.isFinite(n)&&n>=0?n:i},"sanitizeNumberValue"),he=p(e=>{const i=typeof e=="number"?e:typeof e=="string"?Number.parseFloat(e):Number.NaN;return Number.isFinite(i)&&i>0?i:void 0},"parseThemeFontSize"),pe=p(e=>{const i=X(e.fontFamily,f.fontFamily),n=he(e.fontSize)??f.fontSize;return{...f,fontFamily:i,fontSize:n,terminalFill:m(e.secondBkg??e.secondaryColor,f.terminalFill),terminalStroke:m(e.secondaryBorderColor??e.lineColor,f.terminalStroke),terminalTextColor:m(e.secondaryTextColor??e.textColor,f.terminalTextColor),nonTerminalFill:m(e.mainBkg??e.background,f.nonTerminalFill),nonTerminalStroke:m(e.primaryBorderColor??e.lineColor,f.nonTerminalStroke),nonTerminalTextColor:m(e.primaryTextColor??e.textColor,f.nonTerminalTextColor),lineColor:m(e.lineColor,f.lineColor),markerFill:m(e.lineColor,f.markerFill),commentFill:m(e.labelBackground??e.tertiaryColor,f.commentFill),commentStroke:m(e.tertiaryBorderColor??e.lineColor,f.commentStroke),commentTextColor:m(e.tertiaryTextColor??e.textColor,f.commentTextColor),specialFill:m(e.tertiaryColor??e.secondaryColor,f.specialFill),specialStroke:m(e.tertiaryBorderColor??e.secondaryBorderColor,f.specialStroke),ruleNameColor:m(e.titleColor??e.textColor,f.ruleNameColor)}},"buildThemeDefaults"),E=p(e=>{const i=_(),n={...G(),...i.themeVariables??{},...me(e)},a=pe(n),t={...i.railroad??{},...ce(e)};return{compactMode:t.compactMode??a.compactMode,padding:F(t.padding,a.padding),verticalSeparation:F(t.verticalSeparation,a.verticalSeparation),horizontalSeparation:F(t.horizontalSeparation,a.horizontalSeparation),arcRadius:F(t.arcRadius,a.arcRadius),fontSize:F(t.fontSize,a.fontSize),fontFamily:X(t.fontFamily,a.fontFamily),terminalFill:m(t.terminalFill,a.terminalFill),terminalStroke:m(t.terminalStroke,a.terminalStroke),terminalTextColor:m(t.terminalTextColor,a.terminalTextColor),nonTerminalFill:m(t.nonTerminalFill,a.nonTerminalFill),nonTerminalStroke:m(t.nonTerminalStroke,a.nonTerminalStroke),nonTerminalTextColor:m(t.nonTerminalTextColor,a.nonTerminalTextColor),lineColor:m(t.lineColor,a.lineColor),strokeWidth:F(t.strokeWidth,a.strokeWidth),markerFill:m(t.markerFill,a.markerFill),commentFill:m(t.commentFill,a.commentFill),commentStroke:m(t.commentStroke,a.commentStroke),commentTextColor:m(t.commentTextColor,a.commentTextColor),specialFill:m(t.specialFill,a.specialFill),specialStroke:m(t.specialStroke,a.specialStroke),ruleNameColor:m(t.ruleNameColor,a.ruleNameColor),showMarkers:t.showMarkers??a.showMarkers,markerRadius:F(t.markerRadius,a.markerRadius)}},"buildRailroadStyleOptions"),Te=p(e=>{const{fontFamily:i,fontSize:n,terminalFill:a,terminalStroke:t,terminalTextColor:r,nonTerminalFill:o,nonTerminalStroke:g,nonTerminalTextColor:l,lineColor:s,strokeWidth:h,markerFill:u,commentFill:c,commentStroke:w,commentTextColor:d,specialFill:T,specialStroke:z,ruleNameColor:S}=E(e);return`
|
|
3
3
|
.railroad-diagram {
|
|
4
4
|
font-family: ${i};
|